body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background-color: #e0e0e0;
}

.background-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    grid-template-rows: repeat(auto-fill, minmax(200px, 1fr));
    z-index: -1;
   
    
}

.background-grid div {
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, calc(var(--gray) / 255));
    
  
}
.info-button {
    padding: 10px 20px;
    background-color: black;
    color: white;
    cursor: pointer;
    display: inline-block;
    margin-top: 20px;
}

/* Popup Stijl */
.popup-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: center;
   
}

.popup-content {
    background: white;
    padding: 20px;
    width: 60%;
    max-width: 1200px;
    border-radius: 5px;
    position: relative;
  
    
}

.close-popup {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 20px;
    cursor: pointer;
}

.button {
    padding: 10px 20px;
    border: none;
    cursor: pointer;
    margin-top: 10px;
}

.red-button {
    background-color: red;
    color: white;
}

/* Volledig scherm popup */
#externalPopup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: white;
    z-index: 1000;
    font-size:small;
}
#externalPopup iframe {
    width: 100%;
    height: 90vh;
    border: none;
}
.back-button {
    display: block;
    width: 100%;
    text-align: center;
    background-color: black;
    color: white;
    padding: 15px;
    cursor: pointer;
    font-size: 16px;
    border: none;
}


/* Animatie fix */
@keyframes fadeInGridItems {
    0% { background-color: rgba(0, 0, 0, 0.05); }
    100% { background-color: rgba(0, 0, 0, 0.2); }
}

@keyframes fadeInGrid {
    0% { background-color: lightgray; }
    50% { background-color: lightgray; }
    100% { background-color: transparent; }
}

@keyframes fadeInGridItems {
    0% { background-color: rgba(0, 0, 0, 0); }
    100% { background-color: rgba(0, 0, 0, calc(var(--gray) / 255)); }
}

h1 {
position: relative;
display: flex;
justify-content: center;
align-items: center;
width: 100vw; /* Volledige breedte */
height: 20vh; /* Hoogte aanpassen indien nodig */
margin: 0;
animation: scaleTitle 10s infinite alternate ease-in-out;

}

@keyframes scaleTitle {
0% { font-size: 1rem; opacity: 1; }
50% { font-size: 5rem; opacity: 0; }
100% { font-size: 3rem; opacity: 1; }
}

/* Grote, schaalbare tekst */
.title-big {
font-size: 15vw; /* Schaalbaar: 12% van de viewport breedte */
color: darkslategray;
font-weight: bold;
text-align: center;
white-space: nowrap; /* Voorkomt afbreken */
}

/* Kleinere naam, gecentreerd over de grote tekst */
.title-small {
position: absolute;
font-size: 5vw; /* Schaalbaar: 3% van de viewport breedte */
color: rgb(251, 248, 248);
font-weight:bold;
text-align: center;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
background-color: rgb(159, 169, 169, 0.6);
white-space: nowrap; /* Voorkomt afbreken */

}

.square-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
    margin-top: -20px;
    max-width: 70%;
}

.square {
display: flex;
align-items: center;
justify-content: center;
text-decoration: none;  /* Verwijdert standaard onderstreping van links */
color: white;  /* Zorgt ervoor dat de tekst wit blijft */
width: 300px;
height: 300px;
background: rgb(89, 91, 91);
border-radius: 20%;
background-color: lightgray; /* Start als effen lichtgrijs */
animation: fadeInGrid 6s infinite alternate ease-in-out;
    
font-size: 1.2rem;
font-weight: bold;
transition: transform 0.3s ease-in-out, background 0.3s;
}

.square:hover {
transform: rotate(90deg);
background: darkgray;
}
.square span {
    position: absolute;
    transform: rotate(0deg); /* Voorkomt meedraaien */
    transition: color 1s ease-in-out;
    animation: titleAnimation 8s infinite alternate ease-in-out;
}

@keyframes titleAnimation {
    0% { color: white; transform: rotate(0deg); }
    50% { color: rgb(93, 99, 100); }
    100% { color: lightblue; transform: rotate(360deg); }
}
.hidden-image {
    width: 100%;
    max-width: 600px;
    margin-top: 20px;
    opacity: 1;
    transition: opacity 2s ease-in-out;
}

h1:hover ~ .hidden-image {
    opacity: 0;
}

footer {

color: white;
text-align: center;
padding: 10px;
font-size:small;
width: 100%;
}

@media (max-width: 800px) {
    h1 { font-size: 0.5rem;  }
    .square-container { gap: 15px; }
    .square-container { max-width: 800px; }
    .square { width: 100px; height: 100px; font-size: 0.6rem; }
    
    .background-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(50px, 1fr));
    grid-template-rows: repeat(auto-fill, minmax(50px, 1fr));
    z-index: -1;
}
@keyframes scaleTitle {
    0% { font-size: 1rem; opacity: 1; }
    50% { font-size: 3rem; opacity: 0; }
    100% { font-size: 1rem; opacity: 1; color:darkslategray; }
}
.popup-content {
    font-family: Arial, sans-serif;
    font-size: 10px;
    position: relative; /* Dit is cruciaal zodat de sluitknop goed gepositioneerd wordt */
    background-color: rgb(252, 249, 249);
    padding: 20px;
    border-radius: 10px;
    width: min(400px, 80%);
    text-align: left;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.3);
}
}
.bottom-container {
    position:absolute;
    bottom: 20px; /* Afstand vanaf de onderkant */
    
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
}


@keyframes fadeInfoButton {
    0% {
        background-color: #080808; /* Donkergrijs */
    }
    50% {
        background-color: #ff6600; /* Fel oranje */
    }
    100% {
        background-color: #080808; /* Terug naar donkergrijs */
    }
}

.info-button {
    position: fixed;
    top: 10px;
    right: 10px;
    width: min(90px, 12vmin);
    height: min(90px, 12vmin);
    color: white;
    font-size: min(20px, 2vmin);
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 10px;
    box-shadow: 10px 10px 10px rgba(0, 0, 0, 0.9);
    z-index: 1;
    animation: fadeInfoButton 6s infinite alternate ease-in-out;
}

/* Popup achtergrond */
.popup-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(154, 160, 167, 0.9);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

/* Popup venster */
.popup-content {
    font-family: Arial, sans-serif;
    font-size: 8;
    position: relative; /* Dit is cruciaal zodat de sluitknop goed gepositioneerd wordt */
    background-color: rgb(252, 250, 250);
    padding: 20px;
    border-radius: 10px;
    width: 70%;
    text-align: left;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.3);
}

/* Sluitknop */
.close-popup {
    position: absolute;
    top: 10px;
    right: 10px; /* Kleinere afstand zodat het netjes blijft */
    font-size: 60px;
    cursor: pointer;
    color: rgb(244, 4, 4);
    font-weight: bold;
}
    #small-screen-warning {
      position: fixed;
      top: 20%;
      left: 50%;
      transform: translateX(-50%);
      background: rgba(105, 102, 102, 0.85);
      color: white;
      padding: 1em 1.5em;
      border-radius: 10px;
      font-size: 1em;
      text-align: center;
      z-index: 9999;
      opacity: 1;
      transition: opacity 2s ease;
      pointer-events: none;
    }

    @media (min-width: 768px) {
      #small-screen-warning {
        display: none;
      }
    }

    #surprise-hint {
      position: fixed;
      width: 220px;
      height: 220px;
      background: radial-gradient(circle, #ccc, #222);
      border-radius: 50%;
      clip-path: polygon(
        50% 0%, 60% 15%, 75% 10%, 80% 25%, 95% 25%,
        90% 40%, 100% 50%, 90% 60%, 95% 75%, 80% 75%,
        75% 90%, 60% 85%, 50% 100%, 40% 85%, 25% 90%,
        20% 75%, 5% 75%, 10% 60%, 0% 50%, 10% 40%,
        5% 25%, 20% 25%, 25% 10%, 40% 15%
      );
      display: flex;
      justify-content: center;
      align-items: center;
      color: white;
      font-family: sans-serif;
      font-size: 1.1em;
      text-align: center;
      padding: 20px;
      z-index: 9999;
      opacity: 1;
      transition: opacity 2s ease;
    }

    @media (max-width: 767px) {
      #surprise-hint {
        width: 140px;
        height: 140px;
        font-size: 0.85em;
        bottom: 80px;
        left: 50%;
        top: auto;
        transform: translateX(-50%);
      }
    }

    /* Style als de ster bovenin links moet staan (bij herhaalbezoek) */
    #surprise-hint.top-left {
      top: 15px;
      left: 15px;
      transform: none;
      width: 100px;
      height: 100px;
      font-size: 0.7em;
      padding: 10px;
    }
   