:root {
    --primary: #4f8ef7;
    --primary-hover: #3a6ec7;
    --dark: #1a1a2e;
    --text: #333;
    --text-light: #666;
    --bg-light: #f8f9fa;
    --white: #ffffff;
    --shadow-soft: 0 4px 15px rgba(0, 0, 0, 0.05);
    --shadow-hover: 0 8px 25px rgba(0, 0, 0, 0.1);
    --radius: 12px;
    --transition: 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    scroll-padding-top: 5rem;
}

body {
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text);
    background: linear-gradient(to bottom right, #f0f2f5, #e0e5ec);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: hidden;
}

header {
    background: var(--dark);
    color: white;
    padding: 1.2rem 2rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    width: 100%;
    position: sticky;
    top: 0;
    z-index: 100;
}

nav {
    display: flex;
    gap: 1rem;
    justify-content: center;
    align-items: center;
    max-width: 1180px;
    margin: 0 auto;
}

nav a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    padding: 0.6rem 1.2rem;
    border-radius: 8px;
    font-weight: 500;
    transition: var(--transition);
    white-space: nowrap;
}

nav a:hover,
nav a.active {
    color: white;
    background: rgba(255, 255, 255, 0.1);
}

nav a.active {
    color: white;
}

.container {
    flex: 1;
    padding: 2.5rem clamp(1rem, 4vw, 1.5rem);
    max-width: 1100px;
    width: 100%;
    margin: 0 auto;
}

section {
    width: 100%;
    text-align: center;
}

.bouton {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 1.5rem;
    padding: 0.8rem 1.6rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 600;
    transition: var(--transition);
    min-height: 44px;
    text-align: center;
}

.bouton:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(79, 142, 247, 0.3);
}

h1 {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 1rem;
    letter-spacing: -0.02em;
}

h1 span {
    color: var(--primary);
}

p {
    font-size: 1.1rem;
    color: var(--text-light);
}

.feedback-banner {
    margin-bottom: 1rem;
    padding: 1rem 1.1rem;
    border-radius: 10px;
    font-size: 0.95rem;
    text-align: left;
}

.feedback-banner.error {
    background: #fff5f5;
    color: #c53030;
    border: 1px solid #fed7d7;
}

footer {
    background: var(--dark);
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
    padding: 1.5rem;
    font-size: 0.9rem;
}

input[type="date"]::-webkit-calendar-picker-indicator {
    display: none;
    -webkit-appearance: none;
}

.note-vide {
    grid-column: 1 / -1;
    padding: 4rem 2rem;
    background: var(--white);
    border-radius: var(--radius);
    border: 2px dashed #ddd;
    color: var(--text-light);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.2rem;
    text-align: center;
    width: 100%;
}

.note-vide i {
    color: #cbd5e0;
}

.note-vide p {
    font-size: 1.1rem;
    max-width: 400px;
    margin: 0 auto;
}

.toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--dark);
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 50px;
    font-weight: 500;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    z-index: 1000;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.toast.show {
    transform: translateX(-50%) translateY(0);
}

.toast i {
    color: #10b981;
}

:focus-visible {
    outline: 3px solid rgba(79, 142, 247, 0.35);
    outline-offset: 3px;
}

@media (max-width: 720px) {
    html {
        scroll-padding-top: 4.5rem;
    }

    header {
        padding: 0.65rem max(0.75rem, env(safe-area-inset-left)) 0.7rem;
    }

    nav {
        flex-wrap: nowrap;
        justify-content: flex-start;
        gap: 0.5rem;
        overflow-x: auto;
        padding: 0.15rem 0.1rem 0.25rem;
        scrollbar-width: none;
        scroll-snap-type: x proximity;
        -webkit-overflow-scrolling: touch;
    }

    nav::-webkit-scrollbar {
        display: none;
    }

    nav a {
        flex: 0 0 auto;
        scroll-snap-align: start;
        min-height: 42px;
        padding: 0.6rem 0.85rem;
        font-size: 0.92rem;
        border-radius: 999px;
        background: rgba(255, 255, 255, 0.04);
    }

    nav a.active {
        background: rgba(255, 255, 255, 0.16);
        box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
    }

    .container {
        padding: 1.15rem 0.9rem 1.75rem;
    }

    h1 {
        font-size: 1.9rem;
        line-height: 1.08;
        margin-bottom: 0.65rem;
    }

    p {
        font-size: 1rem;
    }

    .bouton {
        width: 100%;
        padding: 0.85rem 1.2rem;
        border-radius: 12px;
    }

    .note-vide {
        padding: 2.5rem 1.25rem;
    }

    .toast {
        left: 1rem;
        right: 1rem;
        bottom: 1rem;
        transform: translateY(100px);
        border-radius: 18px;
        justify-content: center;
        text-align: center;
    }

    .toast.show {
        transform: translateY(0);
    }
}
