body {
    font-family: Arial, sans-serif;
    margin: 20;
    padding: 20;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background-color: #c3c9cd;   
    }
     h1 {
        position:fixed;
        display:top;
        justify-content: center;
        align-items: center;
        width: 100vw;
        height: 10vh;
        max-height: 10vh; /* toegevoegd */
        margin: 0;
        animation: scaleTitle 8s;
        z-index: 1;
        overflow:hidden; /* toegevoegd */
    }
             
            
            @keyframes scaleTitle {
            0% { font-size: 1rem; opacity: 1; }
            50% { font-size: 5rem; opacity: 0; }
            100% { font-size: 1rem; opacity: 1; }
            }
            .popup {
                display: none;
                position: fixed;
                top: 50%;
                left: 50%;
                transform: translate(-50%, -50%);
                background: white;
                padding: 20px;
                box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.5);
            }
          
            .popup {
                display: none;
                position: fixed;
                top: 50%;
                left: 50%;
                transform: translate(-50%, -50%);
                width: 90%;
                height: 90%;
                background: white;
                box-shadow: 8px 3px 30px rgba(0, 0, 0, 0.9);
                z-index: 1000;
                border-radius: 20px;
                overflow: hidden;
                padding: 10px;
            }
            .popup-content {
                width: 100%;
                height: 100%;
                display: flex;
                flex-direction: column;
                justify-content: center;
                align-items: center;
            }
            .popup img {
                max-width: 100%;
                max-height: 80vh;
                object-fit: contain;
                border-radius: 10px;
            }
           
            .overlay {
                display: none;
                position: fixed;
                top: 0;
                left: 0;
                width: 100%;
                height: 100%;
                background: rgba(0, 0, 0, 0.6);
                z-index: 999;
            }
/* Extra schaalbaarheid voor kleine schermen */
@media (max-width: 900px) {
    .slice {
        width: 10vmin;
        height: 10vmin;
        line-height: 10vmin;
        font-size: 4vmin;
    }
    @keyframes scaleTitle {
        0% { font-size: 0.5rem; opacity: 1; }
        50% { font-size: 2.5rem; opacity: 0; }
        100% { font-size: 0.5rem; opacity: 1; }
        } 
        .popup img {
            max-width:300px;
            height: auto; /* Hoogte past zich automatisch aan */
            max-height: 80vh; /* Beperkt de maximale hoogte */
            display: block; /* Voorkomt extra ruimte rondom */
            margin: auto; /* Centreert de afbeelding */
        }
      
        
}

    .bottom-container {
        position:absolute;
        bottom: 20px; /* Afstand vanaf de onderkant */
        left: 50%;
        transform: translateX(-50%);
        text-align: center;
    }
    .home-link {
        margin-bottom: 10px; /* Ruimte tussen HOME en de footer */
    }
    .home-link a {
        font-size: 1.5rem;
        font-weight: bold;
        color: #3b404d;
        text-decoration: none;
    }
    .home-link a:hover {
        text-decoration: underline;
    }
    footer {
        font-size: 0.7rem;
        color: #363434;
    }
    .home-link a {
        font-size: 1.5rem;
        font-weight: bold;
        color: #3b404d;
        text-decoration: none;
    } 
    .home-link a:hover {
        text-decoration: underline;
    }


    .puzzle-wrapper {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 10px; /* Ruimte tussen puzzel en knop */
    }
    .puzzle-container {
        display: grid;
        background-color: antiquewhite;
        grid-template-columns: repeat(3, 1fr);
        grid-template-rows: repeat(3, 1fr);
        gap: 2%;
        
        width: 75vmin; /* Grotere container */
        height: 75vmin;
        max-width: 90vw;
        max-height: 90vh;
        
        padding: 4%; /* Extra ruimte aan alle kanten */
        border-radius: 20px; /* Mooie afgeronde hoeken */
        box-shadow: 10px 20px 30px rgba(101, 107, 109, 0.9);
        box-sizing: border-box;
        position: relative;
    }
            .tile {
                background-color: #3498db;
                color: white;
                display: flex;
                align-items: center;
                justify-content: center;
                font-size: 5vmin;
                font-weight: bold;
                cursor: pointer;
                border-radius: 20px;
                box-shadow: 5px 5px 10px rgba(0, 0, 0, 0.6);
                background-size: cover;
                background-position: center;
            }
            .empty {
                background-color: #bbb; /* Grijze kleur bij start */
            }
            .popup {
                display: none;
                position: fixed;
                top: 50%;
                left: 50%;
                transform: translate(-50%, -50%);
                width: 98%;
                height: 98%;
                background: white;
                box-shadow: 8px 3px 30px rgba(0, 0, 0, 10);
                z-index: 1000;
                border-radius: 10px;
                overflow: hidden;
            }
            
            .popup-content {
                width: 100%;
                height: 100%;
                display: flex;
                flex-direction: column;
            }
            .popup img {
                
                height: auto; /* Hoogte past zich automatisch aan */
                max-height: 80vh; /* Beperkt de maximale hoogte */
                display: block; /* Voorkomt extra ruimte rondom */
                margin: auto; /* Centreert de afbeelding */
            }
            
            
            
            .close {
                position: absolute;
                top: 10px;
                left: 10px;
                background: rgb(119, 120, 122);
                color: white;
                border: none;
                cursor: pointer;
                width: 50px;
                height: 30px;
                text-align: center;
                font-size: 0.8rem;
                border-radius: 8px;
                display: flex;
                justify-content: center;
                align-items: center;
            }
            
            .overlay {
                display: none;
                position: fixed;
                top: 0;
                left: 0;
                width: 100%;
                height: 100%;
                background: rgba(0, 0, 0, 0.1);
                z-index: 999;
            }
            

  

