@import url('https://fonts.googleapis.com/css2?family=Fredoka+One&family=Nunito:wght@400;700&display=swap');

/* --- BASIS INSTELLINGEN --- */
body {
    margin: 0;
    padding: 0;
    font-family: 'Nunito', sans-serif;
    /* NIEUW: Lichte, frisse achtergrond zodat het logo opvalt */
    background: #f0f4f8; 
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    color: #333; /* Donkere tekst voor leesbaarheid */
}

/* --- LOGO LINKSBOVEN --- */
#brand-logo {
    position: absolute;
    bottom: 50px;
    right: 50px;
    width: 300px;
    height: auto;
    z-index: 30; /* Bovenop de confetti en container */
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.1));
}

#confetti-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
}

/* --- DE WITTE KAART (CONTAINER) --- */
.container {
    text-align: center;
    background: #ffffff; /* Wit vlak */
    padding: 3rem;
    border-radius: 20px;
    /* Mooie zachte schaduw voor diepte */
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1); 
    width: 80%;
    max-width: 800px;
    position: relative;
    z-index: 20;
    border: 1px solid rgba(0,0,0,0.05);
}

/* Screens toggling */
.screen {
    display: none;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.screen.active {
    display: flex;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

h1 {
    font-family: 'Fredoka One', cursive;
    font-size: 3rem;
    margin-bottom: 20px;
    /* CodeFever-achtig Cyaan/Blauw */
    color: #00a0c6; 
    text-shadow: none;
}

h2 {
    color: #007791;
    font-family: 'Fredoka One', cursive;
}

/* --- KLAS KEUZE KNOPPEN --- */
.class-buttons {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.class-buttons button {
    padding: 20px 40px;
    font-size: 1.5rem;
    border: 3px solid #00a0c6; /* Gekleurde rand */
    border-radius: 15px;
    background: #fff;
    color: #00a0c6;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: 'Fredoka One', cursive;
}

.class-buttons button:hover {
    transform: translateY(-5px);
    background: #00a0c6; /* Inkleuren bij hover */
    color: white;
    box-shadow: 0 10px 20px rgba(0, 160, 198, 0.25);
}

/* --- NAAM WEERGAVE --- */
.name-box {
    font-family: 'Fredoka One', cursive;
    font-size: 4rem; 
    min-height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2c3e50; /* Donkerblauw/Grijs */
    margin: 20px 0;
}

.animating {
    animation: pulse 0.1s infinite;
    color: #ff9f43; /* Oranje flitsen */
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* --- PROFICIAT BERICHT --- */
#congrats-msg {
    font-size: 2rem;
    color: #f1c40f; /* Goud */
    text-shadow: 1px 1px 0 #d35400;
    font-weight: bold;
    margin-bottom: 20px;
    animation: popIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes popIn {
    from { transform: scale(0); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* --- GROTE ACTIE KNOP --- */
.big-btn {
    padding: 20px 60px;
    font-size: 2rem;
    /* Mooie verloopkleur van CodeFever blauw naar cyaan */
    background: linear-gradient(135deg, #00a0c6 0%, #007791 100%);
    color: white;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    font-family: 'Fredoka One', cursive;
    box-shadow: 0 5px 15px rgba(0, 119, 145, 0.3);
    transition: all 0.3s ease;
}

.big-btn:hover {
    filter: brightness(1.1);
    transform: scale(1.05);
    box-shadow: 0 8px 20px rgba(0, 119, 145, 0.4);
}

.big-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* --- FOOTER KNOPPEN (RESET & TERUG) --- */
.footer-controls {
    margin-top: 40px;
    display: flex;
    gap: 15px;
    justify-content: center;
}

.reset-btn, .back-btn {
    padding: 10px 20px;
    background: transparent;
    border: 2px solid #ddd; /* Lichte rand */
    color: #888; /* Grijze tekst */
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: bold;
    transition: all 0.2s;
}

.reset-btn:hover, .back-btn:hover {
    border-color: #00a0c6;
    color: #00a0c6;
    background: #f9fcff;
}

.hidden {
    display: none !important;
}

/* --- RESPONSIVE VOOR MOBIEL --- */
@media (max-width: 600px) {
    .container {
        padding: 1.5rem;
        width: 90%;
    }
    
    h1 {
        font-size: 2rem;
    }

    .name-box {
        font-size: 2.5rem;
        min-height: 100px;
    }

    .big-btn {
        font-size: 1.5rem;
        padding: 15px 40px;
    }
    
    #brand-logo {
        width: 120px;
        top: 15px;
        left: 15px;
    }
}