:root {
    --bluey-light: #4FC3F7;
    --bluey-dark: #1E88E5;
    --space-bg: #0D1B2A;
    --bingo-orange: #FF8C42;
    --star-yellow: #FFD700;
    --cosmic-purple: #7B2FBE;
    --white: #F0F8FF;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    background-color: var(--space-bg);
    color: var(--white);
    font-family: 'Quicksand', sans-serif;
    overflow-x: hidden;
    line-height: 1.6;
}

h1, h2, h3 { font-family: 'Fredoka', sans-serif; }

.hidden { display: none !important; }

/* Navigation */
.main-nav {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    background: rgba(13, 27, 42, 0.6);
    backdrop-filter: blur(10px);
    padding: 10px 20px;
    border-radius: 50px;
    border: 1px solid rgba(79, 195, 247, 0.3);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 25px;
    height: 18px;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 3100;
    padding: 0;
}

.menu-toggle .bar {
    width: 100%;
    height: 3px;
    background-color: var(--bluey-light);
    border-radius: 10px;
    transition: all 0.3s ease;
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 20px;
}

.nav-link {
    text-decoration: none;
    color: var(--white);
    font-weight: 600;
    font-size: 0.9rem;
    transition: color 0.3s, transform 0.2s;
    display: inline-block;
}

.nav-link:hover {
    color: var(--bluey-light);
    transform: translateY(-2px);
}

.nav-link.active {
    color: var(--bluey-light);
    border-bottom: 2px solid var(--bluey-light);
}

@media (max-width: 768px) {
    .main-nav {
        background: transparent;
        border: none;
        box-shadow: none;
        padding: 0;
        top: 15px;
        right: 15px;
        border-radius: 0;
        backdrop-filter: none;
        z-index: 3100;
    }

    .menu-toggle { 
        display: flex; 
        background: rgba(13, 27, 42, 0.8);
        padding: 10px;
        width: 45px;
        height: 45px;
        border-radius: 10px;
        border: 1px solid var(--bluey-light);
        justify-content: space-around;
    }

    .main-nav ul {
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background: rgba(13, 27, 42, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: transform 0.4s cubic-bezier(0.77,0.2,0.05,1.0), opacity 0.3s ease;
        z-index: 3000;
        margin: 0;
        padding: 0;
        border: none;
        border-radius: 0;
        visibility: hidden;
        opacity: 0;
        transform: translateX(100%);
    }

    .main-nav ul.active {
        visibility: visible;
        opacity: 1;
        transform: translateX(0);
    }

    .main-nav ul li {
        margin: 15px 0;
    }

    .nav-link {
        font-size: 1.5rem;
    }

    /* Animation du burger */
    .menu-toggle.active .bar:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
    .menu-toggle.active .bar:nth-child(2) { opacity: 0; }
    .menu-toggle.active .bar:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
}

/* Background Espace */
#star-field {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: -1;
    overflow: hidden;
}

.star {
    position: absolute;
    background: white;
    border-radius: 50%;
    animation: twinkle var(--duration) infinite ease-in-out;
}

@keyframes twinkle {
    0%, 100% { opacity: 0.3; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.2); }
}

/* Auth Screen */
#auth-screen {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.auth-card-premium {
    background: rgba(13, 27, 42, 0.8);
    backdrop-filter: blur(20px);
    padding: 40px;
    border-radius: 40px;
    text-align: center;
    max-width: 500px;
    border: 2px solid var(--bluey-light);
    box-shadow: 0 0 50px rgba(79, 195, 247, 0.3);
    animation: fadeInScale 0.8s ease-out;
}

.auth-image-container {
    position: relative;
    margin-bottom: 30px;
    border-radius: 20px;
    overflow: hidden;
    border: 3px solid var(--bluey-light);
}

.auth-welcome-img {
    width: 100%;
    display: block;
}

.auth-glow {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.5);
}

.auth-hint {
    margin-top: 15px;
    font-style: italic;
    opacity: 0.8;
}

@keyframes fadeInScale {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.bluey-svg { width: 100px; margin-bottom: 20px; animation: bounce 2s infinite; }

.input-group { margin-top: 20px; display: flex; flex-direction: column; gap: 10px; }

input {
    padding: 15px;
    border-radius: 15px;
    border: none;
    font-size: 1rem;
    text-align: center;
    background: var(--white);
    color: var(--space-bg);
}

.auth-case-hint {
    margin-top: 5px;
    font-size: 0.85rem;
    color: var(--bluey-light);
    font-style: italic;
    opacity: 0.9;
}

button {
    padding: 15px;
    border-radius: 15px;
    border: none;
    background: var(--bluey-light);
    color: var(--space-bg);
    font-weight: bold;
    cursor: pointer;
    transition: transform 0.2s, background 0.2s;
}

button:hover { background: var(--bluey-dark); }
button:active { transform: scale(0.95); }


/* Main Content */
.hero {
    text-align: center;
    padding: 60px 20px;
    position: relative;
}

.hero h1 { font-size: 3rem; margin-bottom: 10px; color: var(--bluey-light); }
.hero h1 span { color: var(--bingo-orange); }

.subtitle { font-size: 1.2rem; opacity: 0.9; }

/* Hero Interactive */
.hero-interactive {
    position: relative;
    height: 85vh;
    min-height: 500px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 60px; /* Redescendu un peu */
    text-align: center;
    overflow: hidden;
    margin-bottom: 40px;
    border-bottom: 2px solid rgba(79, 195, 247, 0.3);
}

.hero-bg-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-bg-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 35%; /* Remonté un peu pour mieux voir les bustes */
    filter: brightness(0.9) contrast(1.1);
    animation: slowZoom 20s infinite alternate ease-in-out;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Gradient ajusté pour être plus sombre en haut (derrière le texte) et s'éclaircir au milieu */
    background: linear-gradient(to bottom, rgba(13, 27, 42, 0.7) 0%, transparent 50%, var(--space-bg) 100%);
    z-index: 0;
}

.hero-content {
    z-index: 1;
    padding: 20px 30px;
    max-width: 700px;
    background: rgba(13, 27, 42, 0.5);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    border: 1px solid rgba(79, 195, 247, 0.4);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
}

.hero-content h1 {
    font-size: 4.5rem;
    text-shadow: 0 4px 30px rgba(0, 0, 0, 0.8);
    margin-bottom: 10px;
}
.card-link {
    display: inline-block;
    margin-top: auto;
    color: var(--bluey-light);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    border: 1px solid var(--bluey-light);
    padding: 5px 15px;
    border-radius: 20px;
    transition: all 0.3s;
}

.card-link:hover {
    background: var(--bluey-light);
    color: white;
}

.hero-actions {
    margin: 25px 0;
}

.btn-programme {
    background: var(--bluey-light);
    color: var(--space-bg);
    font-size: 1.2rem;
    padding: 18px 40px;
    box-shadow: 0 10px 20px rgba(79, 195, 247, 0.3);
}

.btn-programme:hover {
    background: white;
    transform: scale(1.05) rotate(-2deg);
}

.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    cursor: pointer;
    z-index: 2;
    animation: bounceIndicator 2s infinite;
    background: rgba(79, 195, 247, 0.2);
    padding: 15px;
    border-radius: 50%;
    backdrop-filter: blur(5px);
    border: 1px solid var(--bluey-light);
    color: var(--bluey-light);
    display: flex;
    align-items: center;
    justify-content: center;
}

@keyframes slowZoom {
    from { transform: scale(1); }
    to { transform: scale(1.1); }
}

@keyframes bounceIndicator {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
    40% { transform: translateX(-50%) translateY(-10px); }
    60% { transform: translateX(-50%) translateY(-5px); }
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    border-bottom: 5px solid var(--bluey-light);
    transition: transform 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.card:hover { transform: translateY(-10px); }

.card .icon { font-size: 3.5rem; margin-bottom: 15px; }
.card h3 { font-size: 1.8rem; margin-bottom: 5px; color: var(--white); }
.card p { font-size: 1.4rem; opacity: 0.9; }

.map-section { padding: 40px 20px; text-align: center; max-width: 800px; margin: 0 auto; }
.address { margin-top: 20px; font-weight: bold; color: var(--bluey-light); font-size: 1.4rem; }

.rsvp-section {
    background: var(--bluey-light);
    color: var(--space-bg);
    padding: 50px 20px;
    text-align: center;
    border-radius: 50px 50px 0 0;
    margin-top: 50px;
}

.actions { display: flex; justify-content: center; gap: 15px; margin-top: 20px; flex-wrap: wrap; }

.btn {
    text-decoration: none;
    padding: 15px 30px;
    border-radius: 50px;
    font-weight: bold;
    color: white;
    transition: transform 0.2s;
}

.btn:hover { transform: scale(1.05); }

.rsvp-wa { background: #25D366; }
.rsvp-mail { background: var(--space-bg); }

.allergy-notice {
    font-size: 0.9rem;
    margin-top: 15px;
    background: rgba(13, 27, 42, 0.1);
    padding: 10px 20px;
    border-radius: 15px;
    display: inline-block;
    border: 1px dashed var(--space-bg);
}

/* Animations */
@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.planet {
    position: absolute;
    border-radius: 50%;
    z-index: -1;
    opacity: 0.6;
}
.planet-bluey { width: 100px; height: 100px; background: radial-gradient(circle, var(--bluey-light), var(--bluey-dark)); top: 10%; right: 10%; }
.planet-bingo { width: 60px; height: 60px; background: radial-gradient(circle, var(--bingo-orange), #E65100); bottom: 20%; left: 5%; }

/* Programme Page */
.programme-header {
    padding: 60px 20px;
    text-align: center;
    background: linear-gradient(to bottom, var(--space-bg), transparent);
}

.programme-header h1 {
    font-size: 3.5rem;
    color: var(--bluey-light);
    margin-bottom: 10px;
}

.parents-note {
    max-width: 800px;
    margin: 0 auto 60px auto;
    padding: 0 20px;
}

.note-card {
    background: rgba(123, 47, 190, 0.15);
    border: 2px dashed var(--cosmic-purple);
    border-radius: 25px;
    padding: 30px;
    display: flex;
    gap: 25px;
    align-items: flex-start;
    backdrop-filter: blur(5px);
}

.note-icon {
    font-size: 2.5rem;
    background: var(--cosmic-purple);
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
}

.note-text h3 {
    color: var(--cosmic-purple);
    margin-bottom: 15px;
    font-size: 1.5rem;
}

.note-text ul {
    list-style: none;
}

.note-text li {
    margin-bottom: 12px;
    position: relative;
    padding-left: 25px;
    line-height: 1.4;
}

.note-text li::before {
    content: "🚀";
    position: absolute;
    left: 0;
    font-size: 0.9rem;
}

.timeline {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 20px;
}

.timeline-item {
    display: flex;
    align-items: center;
    gap: 40px;
    margin-bottom: 80px;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.timeline-item.visible {
    opacity: 1;
    transform: translateY(0);
}

.timeline-item:nth-child(even) {
    flex-direction: row-reverse;
}

.timeline-img {
    flex: 1;
    border-radius: 30px;
    overflow: hidden;
    border: 5px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}

.timeline-img img {
    width: 100%;
    display: block;
    transition: transform 0.5s;
}

.timeline-item:hover .timeline-img img {
    transform: scale(1.05);
}

.timeline-content {
    flex: 1;
    padding: 20px;
}

.time-tag {
    display: inline-block;
    background: var(--bluey-light);
    color: var(--space-bg);
    padding: 5px 15px;
    border-radius: 10px;
    font-weight: bold;
    font-family: 'Fredoka', sans-serif;
    margin-bottom: 15px;
}

.timeline-content h2 {
    font-size: 2.2rem;
    margin-bottom: 15px;
    color: var(--star-yellow);
}

.timeline-content p {
    font-size: 1.1rem;
    color: var(--white);
    opacity: 0.9;
}

.back-container {
    text-align: center;
    padding: 40px;
}

.btn-back {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--bluey-light);
}

/* Footer */
.site-footer {
    padding: 40px 20px;
    text-align: center;
    border-top: 1px solid rgba(79, 195, 247, 0.2);
    margin-top: 40px;
    opacity: 0.7;
    font-size: 0.9rem;
}

.ai-mention {
    margin-top: 5px;
    font-size: 0.8rem;
    font-style: italic;
    color: var(--bluey-light);
}

/* Floating Contact - Style Blocky */
.floating-contact {
    position: fixed;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2000;
    display: flex;
    flex-direction: column;
}

.contact-item {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    color: white;
    text-decoration: none;
    height: 60px;
    min-width: 60px;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow: hidden;
    margin-bottom: 2px;
}

.contact-item.wa { background: #25D366; } /* Vert officiel WhatsApp */
.contact-item.mail { background: #D32F2F; } /* Rouge comme le screenshot */
.contact-item.phone { background: #1976D2; } /* Bleu pour l'appel */

.contact-text {
    max-width: 0;
    opacity: 0;
    font-weight: bold;
    font-size: 1rem;
    white-space: nowrap;
    transition: all 0.4s ease;
    padding-left: 0;
}

.contact-item:hover {
    padding-left: 20px;
}

.contact-item:hover .contact-text {
    max-width: 250px;
    opacity: 1;
    padding-right: 15px;
}

.contact-icon {
    font-size: 1.8rem;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    background: rgba(0,0,0,0.1);
}

@media (max-width: 768px) {
    .floating-contact {
        top: auto;
        bottom: 100px;
    }
}

/* Invitation Generator */
.invitation-generator {
    max-width: 800px;
    margin: 60px auto;
    padding: 0 20px;
}

.generator-card {
    background: rgba(13, 27, 42, 0.8);
    border: 3px solid var(--bluey-light);
    border-radius: 30px;
    padding: 40px;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.generator-form {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    text-align: left;
}

.form-group label {
    font-family: 'Fredoka', sans-serif;
    font-size: 1.2rem;
    color: var(--bluey-light);
}

.form-group input[type="text"] {
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(79, 195, 247, 0.3);
    border-radius: 15px;
    padding: 15px;
    color: white;
    font-size: 1.1rem;
    font-family: 'Quicksand', sans-serif;
}

.version-selector {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.version-option {
    cursor: pointer;
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    border: 3px solid transparent;
    transition: all 0.3s;
    background: rgba(0,0,0,0.3);
    padding-bottom: 10px;
}

.version-option input {
    display: none;
}

.version-option img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    margin-bottom: 10px;
}

.version-option span {
    display: block;
    font-size: 0.9rem;
    text-align: center;
}

.version-option:has(input:checked) {
    border-color: var(--bluey-light);
    background: rgba(79, 195, 247, 0.2);
}

.btn-generate {
    background: linear-gradient(45deg, var(--bluey-light), var(--cosmic-purple));
    color: white;
    border: none;
    padding: 20px;
    font-size: 1.2rem;
    font-family: 'Fredoka', sans-serif;
    border-radius: 20px;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
}

.btn-generate:hover:not(:disabled) {
    transform: scale(1.05);
    box-shadow: 0 0 20px var(--bluey-light);
}

.btn-generate:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.status-msg {
    margin-top: 15px;
    font-weight: bold;
}

@media (max-width: 768px) {
    .timeline-item, .timeline-item:nth-child(even) {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    .hero-content h1 { font-size: 2rem; }
    .hero-content .subtitle { font-size: 1.2rem; }
    .hero-content { padding: 15px 20px; }
    .hero-bg-image { object-position: center 25%; }
}

@media (max-width: 480px) {
    .hero-content h1 { font-size: 1.5rem; }
    .hero-content .subtitle { font-size: 0.8rem; }
    .hero-content { padding: 10px 15px; width: 90%; }
    .hero-actions { margin: 15px 0; }
    .btn-programme { font-size: 1rem; padding: 12px 25px; }
    .card { padding: 20px; }
    .timeline-content h2 { font-size: 1.8rem; }
    .main-nav { padding: 5px 10px; }
    .nav-link { font-size: 0.75rem; gap: 8px; }
}
