/* --------------------------------------------------------------
   NAVBAR — pill flottant épuré
   -------------------------------------------------------------- */
.navbar {
    position: fixed;
    top: 22px;
    left: 0;
    right: 0;
    height: auto;
    background: transparent;
    border: none;
    z-index: 1000;
    pointer-events: none;
}
.navbar-container {
    max-width: 1180px;
    height: 70px;
    margin: 0 auto;
    padding: 0 10px 0 18px;
    display: flex;
    align-items: center;
    gap: 18px;
    position: relative;
    pointer-events: auto;
    background: rgba(13, 27, 46, 0.48);
    backdrop-filter: blur(26px) saturate(170%);
    -webkit-backdrop-filter: blur(26px) saturate(170%);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: var(--radius-pill);
    box-shadow:
        0 10px 30px rgba(0, 0, 0, 0.42),
        inset 0 1px 0 rgba(255, 255, 255, 0.10),
        inset 0 -1px 0 rgba(0, 0, 0, 0.25);
}
/* Liseré doré dégradé — matière "verre" autour de la pill (refresh) */
.navbar-container::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    pointer-events: none;
    background: linear-gradient(120deg,
        rgba(255, 184, 74, 0.35),
        transparent 35%,
        transparent 65%,
        rgba(255, 138, 31, 0.18));
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
            mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
            mask-composite: exclude;
    transition: opacity .4s ease;
}

/* Logo simple — déborde légèrement en haut */
.navbar-logo {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    line-height: 0;
}
.navbar-logo a {
    display: block;
    line-height: 0;
    transition: transform .25s ease;
}
.navbar-logo a:hover {
    transform: scale(1.05);
}
.navbar-logo-img {
    height: 72px;
    width: auto;
    object-fit: contain;
    display: block;
    margin: -7px 0;
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.5));
}

/* Menu */
.navbar-menu {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    width: 500px;
    pointer-events: none;
    transition: gap .4s cubic-bezier(.16,1,.3,1);
}
.navbar-menu > * {
    pointer-events: auto;
}
.nav-link {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 6px 14px;
    font-size: 11px;
    font-weight: 500;
    line-height: 1.1;
    color: var(--c-text-2);
    border-radius: var(--radius-md);
    transition:
        color .18s ease,
        background .18s ease,
        gap .4s cubic-bezier(.16,1,.3,1),
        padding .4s cubic-bezier(.16,1,.3,1);
    position: relative;
    cursor: pointer;
    user-select: none;
    white-space: nowrap;
    text-align: center;
}
.nav-link-icon {
    display: block;
    flex-shrink: 0;
}
.nav-link-label {
    display: block;
    font-size: 11px;
    line-height: 1.1;
    max-height: 16px;
    opacity: 1;
    transform: translateY(0);
    overflow: hidden;
    transition:
        font-size .4s cubic-bezier(.16,1,.3,1),
        max-height .4s cubic-bezier(.16,1,.3,1),
        opacity .25s ease,
        transform .4s cubic-bezier(.16,1,.3,1);
}
/* Séparateur subtil entre icônes — visible uniquement au scroll */
.nav-link::before {
    content: "";
    position: absolute;
    left: -24px;
    top: 22%;
    bottom: 22%;
    width: 1px;
    background: rgba(255, 255, 255, 0.10);
    opacity: 0;
    pointer-events: none;
    transition: opacity .35s ease;
}
.navbar-menu > .nav-link:first-of-type::before {
    display: none;
}
.nav-link:hover {
    color: var(--c-text);
    background: rgba(255, 255, 255, 0.05);
}
.nav-link.active {
    color: var(--c-primary);
    background: rgba(255, 184, 0, 0.10);
}

/* Bouton Arcade : accès casino, détaché du menu et collé au profil (contour doré) */
.btn-nav-arcade {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    font-size: 12.5px;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
    color: var(--c-primary);
    background: transparent;
    border-radius: var(--radius-pill);
    box-shadow: inset 0 0 0 1.5px rgba(255, 184, 0, 0.55);
    cursor: pointer;
    transition: color .18s ease, background .18s ease, box-shadow .18s ease, transform .18s ease;
}
.btn-nav-arcade svg { flex-shrink: 0; }
.btn-nav-arcade:hover {
    color: var(--c-primary-light);
    background: rgba(255, 184, 0, 0.10);
    box-shadow: inset 0 0 0 1.5px rgba(255, 184, 0, 0.85), 0 4px 16px rgba(255, 184, 0, 0.18);
}
.btn-nav-arcade.active {
    color: var(--c-bg);
    background: linear-gradient(180deg, var(--c-primary-light), var(--c-primary));
    box-shadow: 0 4px 14px rgba(255, 184, 0, 0.30);
}

/* Dropdown Jeux */
.nav-dropdown-jeux {
    position: relative;
}
.nav-link-jeux {
    gap: 4px;
}
.nav-jeux-arrow {
    transition: transform 0.2s ease;
    opacity: 0.7;
}
.nav-dropdown-jeux:hover .nav-jeux-arrow {
    transform: rotate(180deg);
}
.nav-dropdown-jeux-menu {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    min-width: 200px;
    background: var(--c-surface);
    border: 1px solid var(--c-border);
    border-radius: var(--radius-md);
    padding: 6px;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition: var(--transition);
    z-index: 1001;
}
.nav-dropdown-jeux:hover .nav-dropdown-jeux-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.nav-dropdown-jeux-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    font-size: 13px;
    color: var(--c-text-2);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}
.nav-dropdown-jeux-item:hover {
    background: var(--c-primary-bg);
    color: var(--c-primary);
}

/* Hamburger — <button> natif : reset d'apparence + cible tactile 44px */
.hamburger {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    cursor: pointer;
    padding: 6px;
    min-width: 44px;
    min-height: 44px;
    background: none;
    border: none;
}
.hamburger span {
    width: 22px;
    height: 2px;
    background: var(--c-text);
    border-radius: 2px;
    transition: var(--transition);
}
.hamburger.open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.hamburger.open span:nth-child(2) {
    opacity: 0;
}
.hamburger.open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Actions */
.navbar-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    margin-left: auto;
}
.btn-nav-login {
    display: inline-flex;
    align-items: center;
    padding: 8px 20px;
    font-size: 13px;
    font-weight: 600;
    color: var(--c-primary);
    background: transparent;
    border: 1.5px solid var(--c-primary);
    border-radius: var(--radius-pill);
    transition: var(--transition);
}
.btn-nav-login:hover {
    background: var(--c-primary);
    /* Texte sombre sur or : blanc sur #FFB800 = 1.73:1, illisible */
    color: var(--c-bg);
    box-shadow: 0 0 18px rgba(255, 184, 0, 0.45);
    transform: translateY(-1px);
}
.btn-nav-profile {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px 6px 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--c-text);
    background: var(--c-surface2);
    border: 1px solid var(--c-border);
    border-radius: var(--radius-pill);
    transition: var(--transition), gap .4s cubic-bezier(.16,1,.3,1), padding .4s cubic-bezier(.16,1,.3,1), border-radius .4s cubic-bezier(.16,1,.3,1), width .4s cubic-bezier(.16,1,.3,1), height .4s cubic-bezier(.16,1,.3,1);
}
.nav-profile-username {
    overflow: hidden;
    white-space: nowrap;
    max-width: 120px;
    opacity: 1;
    transition: max-width .4s cubic-bezier(.16,1,.3,1), opacity .25s ease;
}
body.is-scrolled .nav-profile-username {
    max-width: 0;
    opacity: 0;
}
.btn-nav-profile:hover {
    border-color: var(--c-primary-border);
    background: var(--c-surface3);
}
.nav-dropdown-arrow {
    opacity: 0.6;
    transition: transform 0.2s ease, opacity .3s ease, width .4s cubic-bezier(.16,1,.3,1);
    width: 12px;
    flex-shrink: 0;
    overflow: hidden;
}

/* User dropdown */
.nav-user-dropdown {
    position: relative;
}
.nav-user-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 220px;
    background: var(--c-surface);
    border: 1px solid var(--c-border);
    border-radius: var(--radius-md);
    padding: 6px;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition: var(--transition);
    z-index: 1001;
}
.nav-user-dropdown:hover .nav-user-dropdown-menu,
.nav-user-dropdown:focus-within .nav-user-dropdown-menu,
.nav-user-dropdown.open .nav-user-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}
.nav-user-dropdown:hover .nav-dropdown-arrow,
.nav-user-dropdown.open .nav-dropdown-arrow {
    transform: rotate(180deg);
}
.nav-dropdown-header {
    padding: 10px 12px 8px;
    font-size: 12px;
    font-weight: 700;
    color: var(--c-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.nav-dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    font-size: 13px;
    color: var(--c-text-2);
    border-radius: var(--radius-sm);
    transition: var(--transition);
}
.nav-dropdown-item:hover {
    background: var(--c-surface2);
    color: var(--c-text);
}
.nav-dropdown-admin {
    color: var(--c-warning);
}
.nav-dropdown-admin:hover {
    background: var(--c-warning-bg);
    color: var(--c-warning);
}
.nav-dropdown-logout {
    color: var(--c-danger);
}
.nav-dropdown-logout:hover {
    background: var(--c-danger-bg);
    color: var(--c-danger);
}
.nav-dropdown-divider {
    height: 1px;
    background: var(--c-border);
    margin: 6px 2px;
}

/* Carte solde Luvpoints en tête du dropdown profil → ouvre /wallet */
.nav-dropdown-wallet {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 10px 12px;
    margin: 2px 2px 0;
    border-radius: var(--radius-sm);
    background: linear-gradient(180deg, rgba(255, 184, 0, 0.12), rgba(255, 184, 0, 0.05));
    box-shadow: inset 0 0 0 1px rgba(255, 184, 0, 0.28);
    transition: var(--transition);
}
.nav-dropdown-wallet:hover {
    background: linear-gradient(180deg, rgba(255, 184, 0, 0.20), rgba(255, 184, 0, 0.09));
    box-shadow: inset 0 0 0 1px rgba(255, 184, 0, 0.5);
}
.nav-wallet-coin {
    display: inline-flex;
    flex-shrink: 0;
}
.nav-wallet-coin img {
    width: 22px;
    height: 22px;
    filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.4));
}
.nav-wallet-body {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
    min-width: 0;
    flex: 1;
}
.nav-wallet-label {
    font-size: 10.5px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--c-text-muted);
}
.nav-wallet-amount {
    font-size: 15px;
    font-weight: 700;
    color: var(--c-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.nav-wallet-amount--muted {
    font-size: 12.5px;
    font-weight: 600;
    color: var(--c-text-2);
}
.nav-wallet-popout {
    flex-shrink: 0;
    color: var(--c-primary);
    opacity: 0.75;
    transition: var(--transition);
}
.nav-dropdown-wallet:hover .nav-wallet-popout {
    opacity: 1;
    transform: translate(1px, -1px);
}

/* --------------------------------------------------------------
   FOOTER
   -------------------------------------------------------------- */
.footer {
    margin-top: 64px;
    padding-top: 48px;
    background: var(--c-bg-2);
    border-top: 1px solid var(--c-border);
    position: relative;
}
.footer::before {
    /* Liseré doré subtil sur le top — relie le footer au reste du theme. */
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--c-primary), transparent);
    opacity: 0.6;
}
.footer-top {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 12px 24px 36px;
    display: grid;
    grid-template-columns: minmax(240px, 1.5fr) repeat(3, minmax(160px, 1fr));
    gap: 40px;
    align-items: start;
}

/* Brand block (1ère colonne) */
.footer-brand { min-width: 0; }
.footer-brand-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--c-text);
    margin-bottom: 14px;
}
.footer-brand-logo img {
    height: 44px;
    width: auto;
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.4));
}
.footer-brand-name {
    font-family: 'Bowlby One', 'Impact', sans-serif;
    font-size: 22px;
    letter-spacing: 0.04em;
    color: var(--c-text);
}
.footer-tagline {
    margin: 0 0 16px;
    font-size: 13.5px;
    line-height: 1.65;
    color: var(--c-text-muted);
    max-width: 340px;
}
.footer-tagline strong { color: var(--c-text); font-weight: 700; }

.footer-socials {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.footer-socials a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--c-border);
    border-radius: var(--radius-pill);
    font-size: 12px;
    font-weight: 600;
    color: var(--c-text-muted);
    text-decoration: none;
    transition: color .15s ease, background .15s ease, border-color .15s ease, transform .15s ease;
}
.footer-socials a:hover {
    color: var(--c-primary);
    border-color: var(--c-primary);
    background: rgba(255, 184, 0, 0.08);
    transform: translateY(-1px);
}
.footer-socials a svg,
.footer-socials a img { flex-shrink: 0; display: block; }

/* Sections */
.footer-section { min-width: 0; }
.footer-section h4 {
    font-size: 12px;
    font-weight: 700;
    color: var(--c-text);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    margin: 0 0 16px;
    position: relative;
    padding-bottom: 10px;
}
.footer-section h4::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 24px;
    height: 2px;
    background: var(--c-primary);
    border-radius: 2px;
}
.footer-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 9px;
}
.footer-section a {
    font-size: 13px;
    color: var(--c-text-muted);
    text-decoration: none;
    transition: color .15s ease, padding-left .15s ease;
    position: relative;
}
.footer-section a:hover {
    color: var(--c-primary);
    padding-left: 4px;
}
.footer-section p,
.footer-section address {
    font-size: 13px;
    color: var(--c-text-muted);
    margin: 0 0 8px;
    font-style: normal;
    line-height: 1.55;
}
.footer-contact address a,
.footer-contact a {
    color: var(--c-text);
    font-weight: 600;
    text-decoration: none;
    border-bottom: 1px dashed transparent;
    transition: color .15s ease, border-color .15s ease;
}
.footer-contact address a:hover,
.footer-contact a:hover {
    color: var(--c-primary);
    border-bottom-color: currentColor;
}

/* 18+ / jeu responsable — bandeau pleine largeur, au-dessus du séparateur.
   Devenu cliquable : redirige vers /responsible (sélecteur de région + aide locale). */
.footer-age {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 12px 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 12.5px;
    line-height: 1.55;
    color: var(--c-text-muted);
    border-top: 1px solid var(--c-border);
    border-bottom: 1px solid var(--c-border);
    background: linear-gradient(180deg, rgba(230, 57, 70, 0.05), transparent);
    text-decoration: none;
    transition: background 0.2s ease, color 0.2s ease;
}
.footer-age:hover {
    background: linear-gradient(180deg, rgba(230, 57, 70, 0.10), rgba(255, 138, 31, 0.04));
    color: var(--c-text-2);
}
.footer-age:hover .footer-age-link {
    text-decoration: underline;
}
.footer-age-text {
    min-width: 0;
    flex: 1;
}
.footer-age-link {
    margin-left: 4px;
    color: var(--c-primary);
    font-weight: 700;
    white-space: nowrap;
}
.footer-age-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 22px;
    border-radius: 6px;
    background: #e63946;
    color: #fff;
    font-weight: 800;
    font-size: 11px;
    letter-spacing: 0.04em;
    flex-shrink: 0;
}
.footer-age a {
    color: var(--c-primary);
    font-weight: 600;
    text-decoration: none;
}
.footer-age a:hover { text-decoration: underline; }
.footer-age strong { color: var(--c-text); font-variant-numeric: tabular-nums; }

/* Bottom bar */
.footer-bottom {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 18px 24px 22px;
    border-top: 1px solid var(--c-border);
    font-size: 12px;
    /* muted (5.0:1) — faint (#5e5e67) ne faisait que 2.7:1 sur les mentions légales */
    color: var(--c-text-muted);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}
.footer-bottom p { margin: 0; }
.footer-bottom-links {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}
.footer-bottom-links span {
    color: var(--c-text-faint);
    opacity: 0.6;
}
.footer-bottom a {
    color: var(--c-primary) !important;
    text-decoration: none !important;
    font-weight: 600;
}
.footer-bottom a:hover {
    color: var(--c-primary-light) !important;
    text-decoration: underline !important;
}

/* Responsive footer */
@media (max-width: 900px) {
    .footer-top {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
    }
    .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 560px) {
    .footer { margin-top: 48px; padding-top: 36px; }
    .footer-top {
        grid-template-columns: 1fr;
        gap: 28px;
        padding: 8px 18px 28px;
    }
    .footer-tagline { max-width: none; }
    .footer-age {
        padding: 12px 18px;
        font-size: 12px;
    }
    .footer-bottom {
        flex-direction: column;
        text-align: center;
        padding: 16px 18px 22px;
    }
    .footer-bottom-links { justify-content: center; }
}

/* --------------------------------------------------------------
   RESPONSIVE
   -------------------------------------------------------------- */
@media (max-width: 960px) {
    .navbar {
        top: 0;
    }
    .navbar-container {
        margin: 0;
        max-width: none;
        padding: 0 14px;
        border-radius: 0;
        border-left: none;
        border-right: none;
        border-top: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
        background: rgba(11, 22, 38, 0.92);
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
    }
    .navbar-logo-img {
        height: 48px;
        margin: -2px 0;
    }
    .hamburger {
        display: flex;
        order: 3;
        margin-left: 0;
    }
    .navbar-actions {
        order: 2;
        margin-left: auto;
    }
    .nav-profile-username,
    .nav-dropdown-arrow {
        display: none;
    }
    .btn-nav-profile {
        padding: 6px;
        gap: 0;
        border-radius: 50%;
        width: 34px;
        height: 34px;
        justify-content: center;
    }
    /* Arcade : icône seule (cercle) sur mobile */
    .btn-nav-arcade {
        padding: 0;
        gap: 0;
        width: 34px;
        height: 34px;
        justify-content: center;
    }
    .btn-nav-arcade span {
        display: none;
    }
    .navbar-menu,
    body.is-scrolled .navbar-menu {
        position: absolute;
        top: calc(100% + 10px);
        left: 0;
        right: 0;
        width: auto;
        transform: none;
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-start;
        /* Quand fermé : aucune décoration (sinon le 1px de bordure + le bg
           laissent un petit trait visible juste sous la navbar). */
        background: transparent;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        border: 0 solid transparent;
        border-radius: var(--radius-lg);
        padding: 0;
        gap: 2px;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease, padding 0.3s ease;
        pointer-events: none;
        box-shadow: none;
    }
    .navbar-menu > * {
        pointer-events: auto;
    }
    .navbar-menu.open,
    body.is-scrolled .navbar-menu.open {
        max-height: 80vh;
        overflow-y: auto;
        padding: 10px;
        pointer-events: auto;
        /* Fond quasi-opaque pour garantir un contraste lisible sur mobile,
           même sur les navigateurs où backdrop-filter n'est pas appliqué
           (anciens iOS Safari, certains contextes de stacking). Le blur
           reste un nice-to-have visuel pour les navigateurs compatibles. */
        background: rgba(11, 22, 38, 0.96);
        backdrop-filter: blur(28px) saturate(180%);
        -webkit-backdrop-filter: blur(28px) saturate(180%);
        border: 1px solid var(--c-border-strong);
        box-shadow: 0 18px 40px rgba(0, 0, 0, 0.55);
    }
    .nav-link,
    body.is-scrolled .nav-link {
        width: 100%;
        flex-direction: row;
        justify-content: flex-start;
        gap: 10px;
        padding: 10px 14px;
        font-size: 13px;
        text-align: left;
        border-radius: var(--radius-md);
    }
    .nav-link-icon {
        width: 16px;
        height: 16px;
    }
    .nav-link-label,
    body.is-scrolled .nav-link-label {
        font-size: inherit;
        max-height: none;
        max-width: none;
        opacity: 1;
        transform: none;
        overflow: visible;
    }
    .nav-link::before,
    body.is-scrolled .nav-link::before {
        display: none;
    }
    .nav-dropdown-jeux-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        background: transparent;
        border: none;
        padding-left: 16px;
    }
}
@media (max-width: 600px) {
    .navbar-container {
        margin: 0;
        padding: 0 12px;
        gap: 10px;
        height: 56px;
    }
    .navbar-logo-img {
        height: 40px;
        margin: 0;
    }
    .btn-nav-login {
        padding: 6px 14px;
        font-size: 12px;
    }
    .btn-nav-profile {
        width: 30px;
        height: 30px;
        padding: 5px;
    }
}
@media (max-width: 400px) {
    .navbar-container {
        padding: 0 10px;
        gap: 8px;
        height: 52px;
    }
    .navbar-logo-img {
        height: 34px;
    }
    .btn-nav-login {
        padding: 5px 10px;
        font-size: 11px;
    }
    .btn-nav-profile {
        width: 28px;
        height: 28px;
        padding: 4px;
    }
}

/* ============================================================
   ANIMATIONS — Navbar morph au scroll + reveal-on-scroll + parallaxe hero
   Pilotées par anim.js (chargé depuis navbar.html).
   `body.is-scrolled` est posé dès que scrollY > 24px.
   ============================================================ */

/* Navbar — transitions de morph */
.navbar {
    transition: top .45s cubic-bezier(.16,1,.3,1);
}
.navbar-container {
    transition:
        max-width .55s cubic-bezier(.16,1,.3,1),
        height .4s cubic-bezier(.16,1,.3,1),
        background-color .4s ease,
        border-color .4s ease,
        box-shadow .4s ease,
        padding .4s cubic-bezier(.16,1,.3,1);
    will-change: max-width, height, background-color, box-shadow;
}
.navbar-logo a {
    transition: transform .45s cubic-bezier(.16,1,.3,1);
}
.navbar-logo-img {
    transition:
        height .45s cubic-bezier(.16,1,.3,1),
        margin .45s cubic-bezier(.16,1,.3,1),
        filter .35s ease;
}

/* Scrolled state — pill se compacte, accent doré subtil sur la bordure */
body.is-scrolled .navbar { top: 14px; }
body.is-scrolled .navbar-container {
    max-width: 920px;
    height: 54px;
    background: rgba(11, 24, 41, 0.55);
    border-color: rgba(255, 184, 0, 0.22);
    box-shadow:
        0 14px 32px rgba(0, 0, 0, 0.50),
        0 0 0 1px rgba(255, 184, 0, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.06);
    padding: 0 8px 0 14px;
}
body.is-scrolled .navbar-menu {
    gap: 47px;
}
body.is-scrolled .nav-link {
    gap: 0;
    padding: 8px 12px;
}
body.is-scrolled .nav-link-label {
    font-size: 0;
    max-height: 0;
    opacity: 0;
    transform: translateY(-8px);
}
body.is-scrolled .nav-link::before {
    opacity: 1;
}
body.is-scrolled .navbar-logo a {
    transform: scale(0.85);
    transform-origin: left center;
}
body.is-scrolled .navbar-logo-img {
    filter: drop-shadow(0 2px 6px rgba(0,0,0,0.55)) drop-shadow(0 0 10px rgba(255,184,0,0.30));
}
body.is-scrolled .nav-dropdown-arrow {
    opacity: 0;
    width: 0;
    overflow: hidden;
}
body.is-scrolled .btn-nav-profile {
    padding: 6px;
    gap: 0;
    border-radius: 50%;
}
/* Arcade : au scroll, on retire le label et le contour doré → icône seule */
body.is-scrolled .btn-nav-arcade {
    padding: 6px;
    gap: 0;
    box-shadow: none;
}
body.is-scrolled .btn-nav-arcade span {
    font-size: 0;
    max-width: 0;
    opacity: 0;
    overflow: hidden;
}
body.is-scrolled .btn-nav-arcade:hover {
    background: rgba(255, 184, 0, 0.10);
    box-shadow: none;
}

/* Mobile : navbar 100% statique — pas de morph au scroll
   (l'animation desktop fait des sauts de hauteur / scale / opacity
   pénibles sur téléphone). On neutralise tous les overrides .is-scrolled
   et on coupe les transitions. */
@media (max-width: 960px) {
    .navbar,
    .navbar-container,
    .navbar-logo a,
    .navbar-logo-img,
    .navbar-menu,
    .nav-link,
    .nav-link-label {
        transition: none !important;
    }

    body.is-scrolled .navbar { top: 0; }
    body.is-scrolled .navbar-container {
        /* Identique à l'état non-scrolled mobile : aucune morphose visible.
           (height non défini = hérite de la base mobile : 70px @ ≤960, 58px @ ≤600). */
        max-width: none;
        margin: 0;
        padding: 0 14px;
        border-radius: 0;
        border-left: none;
        border-right: none;
        border-top: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.08);
        background: rgba(11, 22, 38, 0.92);
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
    }
    body.is-scrolled .navbar-logo a { transform: none; }
    body.is-scrolled .navbar-logo-img {
        filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.5));
        /* height non défini = hérite de la base mobile (cf. .navbar-logo-img @media). */
    }
    /* Reset des overrides desktop-scrolled pour le menu hamburger mobile */
    body.is-scrolled .navbar-menu { gap: 2px; }
    body.is-scrolled .nav-link {
        gap: 10px;
        padding: 10px 14px;
    }
    body.is-scrolled .nav-link-label {
        font-size: inherit;
        max-height: none;
        opacity: 1;
        transform: none;
    }
    body.is-scrolled .nav-link::before { opacity: 0; }
    body.is-scrolled .btn-nav-profile {
        padding: 6px;
        gap: 0;
        border-radius: 50%;
        width: 34px;
        height: 34px;
        justify-content: center;
    }
    body.is-scrolled .nav-profile-username {
        display: none;
    }
    body.is-scrolled .nav-dropdown-arrow {
        display: none;
    }
}

/* ============================================================
   ENTRANCE — quand on arrive sur une page depuis une page scrollée
   (body.nav-entering posée par le script inline dans navbar.html),
   la navbar morph depuis l'état compact vers l'état full.
   Desktop seulement (mobile a un layout différent).
   ============================================================ */
@media (min-width: 961px) {
    body.nav-entering .navbar-container {
        animation: nav-enter-container 0.7s cubic-bezier(.16, 1, .3, 1) backwards;
    }
    @keyframes nav-enter-container {
        from {
            max-width: 920px;
            height: 54px;
            background: rgba(11, 24, 41, 0.55);
            border-color: rgba(255, 184, 0, 0.22);
            box-shadow:
                0 14px 32px rgba(0, 0, 0, 0.50),
                0 0 0 1px rgba(255, 184, 0, 0.08),
                inset 0 1px 0 rgba(255, 255, 255, 0.06);
            padding: 0 8px 0 14px;
        }
    }
    body.nav-entering .navbar {
        animation: nav-enter-top 0.7s cubic-bezier(.16, 1, .3, 1) backwards;
    }
    @keyframes nav-enter-top {
        from { top: 14px; }
    }
    body.nav-entering .navbar-logo a {
        animation: nav-enter-logo 0.7s cubic-bezier(.16, 1, .3, 1) backwards;
    }
    @keyframes nav-enter-logo {
        from { transform: scale(0.85); transform-origin: left center; }
    }
    body.nav-entering .navbar-logo-img {
        animation: nav-enter-logo-img 0.7s cubic-bezier(.16, 1, .3, 1) backwards;
    }
    @keyframes nav-enter-logo-img {
        from { filter: drop-shadow(0 2px 6px rgba(0,0,0,0.55)) drop-shadow(0 0 10px rgba(255,184,0,0.30)); }
    }
    body.nav-entering .navbar-menu {
        animation: nav-enter-menu 0.7s cubic-bezier(.16, 1, .3, 1) backwards;
    }
    @keyframes nav-enter-menu {
        from { gap: 47px; }
    }
    body.nav-entering .nav-link {
        animation: nav-enter-link 0.7s cubic-bezier(.16, 1, .3, 1) backwards;
    }
    @keyframes nav-enter-link {
        from { gap: 0; padding: 8px 12px; }
    }
    body.nav-entering .nav-link-label {
        animation: nav-enter-label 0.7s cubic-bezier(.16, 1, .3, 1) backwards;
    }
    @keyframes nav-enter-label {
        from {
            font-size: 0;
            max-height: 0;
            opacity: 0;
            transform: translateY(-8px);
        }
    }
    body.nav-entering .nav-link::before {
        animation: nav-enter-sep 0.7s cubic-bezier(.16, 1, .3, 1) backwards;
    }
    @keyframes nav-enter-sep {
        from { opacity: 1; }
    }
    body.nav-entering .btn-nav-profile {
        animation: nav-enter-profile 0.7s cubic-bezier(.16, 1, .3, 1) backwards;
    }
    @keyframes nav-enter-profile {
        from { padding: 6px; gap: 0; border-radius: 50%; }
    }
    body.nav-entering .nav-profile-username {
        animation: nav-enter-username 0.7s cubic-bezier(.16, 1, .3, 1) backwards;
    }
    @keyframes nav-enter-username {
        from { max-width: 0; opacity: 0; }
    }
    body.nav-entering .nav-dropdown-arrow {
        animation: nav-enter-arrow 0.7s cubic-bezier(.16, 1, .3, 1) backwards;
    }
    @keyframes nav-enter-arrow {
        from { opacity: 0; width: 0; }
    }
}

/* ============================================================
   REVEAL-ON-SCROLL — opt-in via [data-reveal]
   Variantes : data-reveal="up|left|right|fade|scale"
   Stagger   : data-reveal-delay="120" (ms) ou auto-staggered par anim.js
   ============================================================ */
[data-reveal] {
    opacity: 0;
    transform: translate3d(0, 28px, 0);
    transition:
        opacity .85s cubic-bezier(.16,1,.3,1),
        transform .85s cubic-bezier(.16,1,.3,1);
    transition-delay: var(--reveal-delay, 0ms);
    will-change: opacity, transform;
}
[data-reveal="left"]  { transform: translate3d(-32px, 0, 0); }
[data-reveal="right"] { transform: translate3d(32px, 0, 0); }
[data-reveal="fade"]  { transform: none; }
[data-reveal="scale"] { transform: scale(0.94); }
[data-reveal].is-visible {
    opacity: 1;
    transform: none;
}

/* ============================================================
   HERO PARALLAX — JS pose --hero-shift (px) en fonction du scroll
   ============================================================ */
body.theme-luv .home-hero-logo-wrap {
    transform: translateY(calc(var(--hero-shift, 0px) * 0.18));
    transition: transform .1s linear;
    will-change: transform;
}
body.theme-luv .home-hero-headline {
    transform: translateY(calc(var(--hero-shift, 0px) * -0.08));
    transition: transform .1s linear;
    will-change: transform;
}
/* Mobile : pas de parallax (rendu saccadé sur téléphone). */
@media (max-width: 960px) {
    body.theme-luv .home-hero-logo-wrap,
    body.theme-luv .home-hero-headline {
        transform: none !important;
        transition: none !important;
        will-change: auto;
    }
}

/* ============================================================
   prefers-reduced-motion — on aplatit tout
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
    .navbar-container,
    .navbar-logo a,
    .navbar-logo-img,
    [data-reveal],
    body.theme-luv .home-hero-logo-wrap,
    body.theme-luv .home-hero-headline {
        transition: none !important;
        transform: none !important;
    }
    [data-reveal] { opacity: 1 !important; }
}

/* ============================================================
   Toast global (window.luvToast — anim.js)
   Remplace les alert() natifs : non bloquant, auto-dismiss 4s.
   ============================================================ */
.luv-toast-wrap {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    z-index: 5000;
    pointer-events: none;
}
.luv-toast {
    max-width: min(92vw, 480px);
    background: var(--c-surface2);
    border: 1px solid var(--c-border-strong);
    border-left-width: 3px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    color: var(--c-text);
    font-size: 14px;
    line-height: 1.45;
    padding: 12px 18px;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity .25s ease, transform .25s ease;
}
.luv-toast.is-visible {
    opacity: 1;
    transform: translateY(0);
}
.luv-toast--error { border-left-color: var(--c-danger); }
.luv-toast--success { border-left-color: var(--c-success); }
