/* ==========================================================================
   PAGES DE LA SECTION COMMUNAUTAIRE : V2
   Classements, giveaways, anniversaires, suggestion, documents, changelog,
   sites et bots, jeux. Chaque page change de FORME, pas seulement de couleur :
   - Classements : un vrai podium étagé et un registre en lignes ;
   - Giveaways : affiches larges, onglets soulignés ;
   - Anniversaires : tuiles de membres, calendrier flottant ;
   - Suggestion : fiches avec barre de votes ;
   - Documents : sommaire en lignes numérotées ;
   - Changelog : une frise verticale ;
   - Sites et bots : trois grands panneaux.
   Chargé après da2026.css et communaute-v2.css.
   ========================================================================== */

/* ── Briques communes ── */
/* Onglets : du texte avec un trait qui marque l'actif. */
body .rl-tabs, body .gw-onglets {
    display: flex; gap: clamp(1rem, 2.4vw, 2rem); flex-wrap: wrap;
    border-bottom: 1px solid var(--border-color); margin-bottom: 1.6rem;
}
body .rl-tab, body .gw-onglet {
    position: relative; display: inline-flex; align-items: center; gap: 0.45rem;
    padding: 0.75rem 0; border: 0; border-radius: 0; background: none; cursor: pointer;
    font: inherit; font-size: 0.98rem; font-weight: 600; letter-spacing: -0.01em;
    color: var(--text-tertiary); transition: color 0.25s ease;
}
body .rl-tab:hover, body .gw-onglet:hover { color: var(--text-primary); border: 0; }
body .rl-tab.active, body .gw-onglet.active { color: var(--text-primary); background: none; }
body .rl-tab::after, body .gw-onglet::after {
    content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; border-radius: 2px;
    background: var(--primary-color); transform: scaleX(0); transform-origin: left;
    transition: transform 0.45s var(--ease-out);
}
body .rl-tab.active::after, body .gw-onglet.active::after { transform: scaleX(1); }
body .gw-compte { border-radius: 999px; padding: 0.1rem 0.5rem; background: var(--primary-color); color: #fff; font-size: 0.72rem; font-weight: 700; }

body .commu-pastille { border-radius: 999px; }

/* ==========================================================================
   CLASSEMENTS
   ========================================================================== */
body .rl-search {
    border: 0; border-radius: 999px; max-width: 460px;
    background: var(--background-secondary);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
body .rl-search:focus-within { box-shadow: 0 0 0 2px var(--primary-color); }

/* Podium étagé : le 1er au centre, plus haut ; le 2e à gauche, le 3e à droite. */
body .rl-podium { align-items: end; gap: 0.6rem; margin: 1.2rem 0 2.4rem; }
body .rl-pod {
    border: 0; border-radius: 30px 30px 8px 8px;
    padding: 1.6rem 1rem 1.4rem;
    background: var(--background-secondary);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07), var(--shadow-sm);
    display: flex; flex-direction: column; align-items: center; justify-content: flex-end;
}
body .rl-pod.argent { order: 1; min-height: 210px; background: linear-gradient(180deg, rgba(203, 213, 225, 0.16), var(--background-secondary) 70%); }
body .rl-pod.or { order: 2; min-height: 290px; padding-top: 2.4rem; background: linear-gradient(180deg, rgba(241, 196, 15, 0.22), var(--background-secondary) 75%); }
body .rl-pod.bronze { order: 3; min-height: 170px; background: linear-gradient(180deg, rgba(205, 127, 50, 0.18), var(--background-secondary) 70%); }
body .rl-pod-medaille { font-size: clamp(1.8rem, 3vw, 2.6rem); margin-bottom: auto; }
body .rl-pod .rl-avatar { width: 64px; height: 64px; border: 0; box-shadow: 0 10px 24px rgba(0, 0, 0, 0.4); }
body .rl-pod.or .rl-avatar { width: 88px; height: 88px; }
body .rl-pod-nom { font-size: 1.02rem; font-weight: 600; letter-spacing: -0.02em; max-width: 100%; }
body .rl-pod-val { font-size: clamp(1.2rem, 2vw, 1.7rem); font-weight: 700; letter-spacing: -0.03em; color: var(--text-primary); }
body .rl-pod.cliquable { transition: transform 0.45s var(--ease-out); }
body .rl-pod.cliquable:hover { transform: translateY(-6px); }

/* Registre : des lignes séparées par un trait, pas des cartes. */
body .rl-rows { gap: 0; }
body .rl-row {
    border: 0; border-bottom: 1px solid var(--border-color); border-radius: 0; background: none;
    padding: 0.85rem 0.6rem; gap: 1rem;
    transition: background-color 0.3s ease, border-radius 0.3s ease, padding-left 0.4s var(--ease-out);
}
body .rl-row.cliquable:hover { background: var(--background-secondary); border-radius: 20px; padding-left: 1.1rem; border-color: transparent; }
body .rl-rang { width: 2.4rem; font-size: 1rem; font-variant-numeric: tabular-nums; color: var(--text-tertiary); }
body .rl-row .rl-avatar { width: 44px; height: 44px; border: 0; border-radius: 14px; }
body .rl-nom { font-size: 1rem; font-weight: 600; letter-spacing: -0.015em; }
body .rl-val { font-size: 1rem; font-weight: 600; color: var(--text-primary); font-variant-numeric: tabular-nums; }
body .rl-row.moi, body .rl-pod.moi, body .rl-mini.moi {
    background: linear-gradient(90deg, rgba(76, 141, 255, 0.18), transparent); border-color: transparent; box-shadow: none; border-radius: 20px;
}
body .rl-carte { border: 0; border-radius: 32px; padding: 1.4rem; background: var(--background-secondary); box-shadow: inset 0 1px 0 rgba(255,255,255,.06), var(--shadow-sm); }
body .rl-carte-btn { padding: 0.35rem 0.8rem; border-radius: 999px; background: var(--background-card); color: var(--text-primary); }
body .rl-carte-btn:hover { text-decoration: none; background: var(--background-card-hover); }
body .rl-page-btn, body .rl-page-aller input { border: 0; border-radius: 999px; background: var(--background-secondary); }
body .rl-page-btn.active { background: var(--primary-color); }

/* ==========================================================================
   GIVEAWAYS
   ========================================================================== */
body .gw-liste { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 420px), 1fr)); gap: 1rem; }
body .gw-carte {
    border: 0; border-radius: 34px; overflow: hidden;
    background: var(--background-secondary);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), var(--shadow-sm);
    transition: transform 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out);
}
body .gw-carte:hover { transform: translateY(-5px); box-shadow: inset 0 1px 0 rgba(255,255,255,.09), var(--shadow-lg); }
body .gw-carte.vedette { box-shadow: inset 0 0 0 1px rgba(76, 141, 255, 0.5), var(--shadow-md); }
body .gw-banniere { min-height: 170px; }
body .gw-corps { padding: clamp(1.2rem, 2.2vw, 1.8rem); }
body .gw-titre { font-size: clamp(1.25rem, 1.9vw, 1.6rem); font-weight: 700; letter-spacing: -0.03em; }
body .gw-lot {
    display: inline-block; margin-top: 0.4rem; padding: 0.3rem 0.8rem; border-radius: 999px;
    background: rgba(241, 196, 15, 0.14); color: #f5cf47; font-weight: 600; font-size: 0.9rem;
}
body .gw-puce { border: 0; border-radius: 999px; background: var(--background-card); padding: 0.35rem 0.75rem; }
body .gw-puce.vif { background: rgba(76, 141, 255, 0.18); color: var(--text-primary); }
body .gw-btn {
    border: 0; border-radius: 14px; padding: 0.7rem 1.2rem; font-weight: 600;
    background: var(--primary-color); color: #fff;
    box-shadow: 0 3px 0 #2557b8, 0 8px 16px rgba(30, 90, 220, 0.25);
    transition: transform 0.2s var(--ease-out), box-shadow 0.2s ease;
}
body .gw-btn:active { transform: translateY(3px); box-shadow: none; }
body .gw-btn.actif { background: rgba(48, 209, 88, 0.16); color: var(--success); box-shadow: none; }
body .gw-btn.secondaire { background: var(--background-card); color: var(--text-primary); box-shadow: none; }
body .gw-palmares { gap: 0; }
body .gw-rang { border: 0; border-bottom: 1px solid var(--border-color); border-radius: 0; background: none; }
body .gw-rang:hover { background: var(--background-secondary); border-radius: 20px; border-color: transparent; }

/* ==========================================================================
   ANNIVERSAIRES
   ========================================================================== */
body .an-grid { grid-template-columns: minmax(0, 1fr) minmax(300px, 380px); gap: clamp(1rem, 2.4vw, 2.4rem); }
body .an-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 0.8rem; }
body .an-card {
    border: 0; border-radius: 30px; padding: 1.1rem 1.2rem; gap: 1rem;
    background: var(--background-secondary);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), var(--shadow-sm);
    transition: transform 0.45s var(--ease-out), box-shadow 0.45s var(--ease-out);
}
body .an-card:hover { transform: translateY(-4px); border: 0; box-shadow: inset 0 1px 0 rgba(255,255,255,.1), var(--shadow-lg); }
body .an-card.today {
    background: radial-gradient(300px 140px at 100% 0%, rgba(249, 115, 22, 0.28), transparent 70%), var(--background-secondary);
    box-shadow: inset 0 0 0 1px rgba(249, 115, 22, 0.5), var(--shadow-md);
}
body .an-avatar { width: 58px; height: 58px; border-radius: 20px; }
body .an-nom { font-size: 1.05rem; font-weight: 600; letter-spacing: -0.02em; }
body .an-jour { font-size: 0.86rem; }
body .an-cal {
    border: 0; border-radius: 32px; background: var(--background-secondary);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), var(--shadow-md);
}
body .an-arrow { border: 0; border-radius: 50%; background: var(--background-card); }
body .an-jour-case { border-radius: 14px; }
body .an-aside-title { text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.74rem; color: var(--text-tertiary); }
body .an-next-row { border: 0; border-radius: 22px; }
@media (max-width: 980px) { body .an-grid { grid-template-columns: 1fr; } }

/* ==========================================================================
   SUGGESTION
   ========================================================================== */
body .sg-intro { align-items: center; padding: 0 0.2rem; margin-bottom: 1.4rem; }
body .sg-intro p { font-size: 1.1rem; color: var(--text-secondary); max-width: 52ch; }
body .sg-btn {
    border: 0; border-radius: 999px; padding: 0.85rem 1.4rem; font-weight: 600;
    background: var(--text-primary); color: var(--background-primary);
    transition: background-color 0.4s ease, color 0.4s ease, transform 0.25s var(--ease-out);
}
body .sg-btn:hover { background: var(--primary-color); color: #fff; }
body .sg-btn:active { transform: scale(0.96); }
body .sg-liste { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 460px), 1fr)); gap: 1rem; }
body .sg-carte {
    border: 0; border-radius: 34px; padding: clamp(1.2rem, 2.2vw, 1.8rem);
    background: var(--background-secondary);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), var(--shadow-sm);
}
body .sg-outil { text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.7rem; color: var(--text-tertiary); font-weight: 600; }
body .sg-titre { font-size: clamp(1.15rem, 1.8vw, 1.45rem); font-weight: 700; letter-spacing: -0.03em; }
body .sg-pastille { border-radius: 999px; padding: 0.3rem 0.8rem; }
body .sg-desc { color: var(--text-secondary); }
body .sg-imgs img { border-radius: 20px; }
body .sg-echeance { color: var(--text-tertiary); font-size: 0.82rem; }
body .sg-modal { border: 1px solid var(--border-strong); border-radius: 34px; background: var(--background-elevated); box-shadow: var(--shadow-xl); }
body .sg-modal-fond { -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); }
body .sg-vide { border: 0; border-radius: 32px; background: var(--background-secondary); }

/* ==========================================================================
   DOCUMENTS : un sommaire en lignes numérotées
   ========================================================================== */
body .doc-grille { display: block; counter-reset: doc; border-bottom: 1px solid var(--border-color); margin-bottom: 1.4rem; }
body .doc-carte {
    counter-increment: doc;
    display: grid; grid-template-columns: 2.2rem 56px minmax(0, 1fr) minmax(0, 1.5fr) auto;
    align-items: center; gap: clamp(0.8rem, 2vw, 1.6rem);
    padding: clamp(1rem, 1.8vw, 1.4rem) clamp(0.6rem, 1.4vw, 1.1rem);
    border: 0; border-top: 1px solid var(--border-color); border-radius: 0;
    background: none; box-shadow: none; text-decoration: none; color: inherit;
    transition: background-color 0.4s ease, padding-left 0.5s var(--ease-out), border-radius 0.4s ease;
}
body .doc-carte::before {
    content: counter(doc, decimal-leading-zero); grid-column: 1; grid-row: 1;
    font-size: 0.8rem; font-weight: 600; letter-spacing: 0.08em; color: var(--text-tertiary);
}
body .doc-carte:first-child { border-top: 0; }
body .doc-carte:not(.vide):hover { background: var(--background-secondary); border-radius: 26px; padding-left: clamp(1.2rem, 2.4vw, 2rem); transform: none; }
body .doc-icone { grid-column: 2; grid-row: 1; width: 52px; height: 52px; border-radius: 17px; margin: 0; }
body .doc-carte h3 { grid-column: 3; grid-row: 1; font-size: clamp(1.15rem, 1.8vw, 1.5rem); font-weight: 600; letter-spacing: -0.03em; margin: 0; }
body .doc-carte p { grid-column: 4; grid-row: 1; margin: 0; font-size: 0.92rem; color: var(--text-tertiary); }
body .doc-pied { grid-column: 5; grid-row: 1; margin: 0; padding: 0; border: 0; display: flex; align-items: center; gap: 0.5rem; }
body .doc-compte { font-size: 0.8rem; color: var(--text-tertiary); }
body .doc-carte.vide { opacity: 0.55; }
body .doc-aide { border: 0; border-radius: 28px; background: var(--background-secondary); }
@media (max-width: 760px) {
    body .doc-carte { grid-template-columns: 1.6rem 48px minmax(0, 1fr) auto; }
    body .doc-carte h3 { grid-column: 3; }
    body .doc-carte p { grid-column: 3; grid-row: 2; }
    body .doc-pied { grid-column: 4; }
}

/* Lecteur de document */
body .lc-entete { padding: 0.4rem 0 1.4rem; margin-bottom: 1.6rem; border-bottom: 1px solid var(--border-color); }
body .lc-retour { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.4rem 0.9rem; border-radius: 999px; background: var(--background-card); text-decoration: none; margin-bottom: 1.2rem; font-weight: 600; font-size: 0.86rem; }
body .lc-entete h1 { font-size: clamp(2.4rem, 5.4vw, 4.4rem); font-weight: 700; letter-spacing: -0.045em; line-height: 1.02; }
body .lc-entete p { font-size: 1.1rem; color: var(--text-secondary); max-width: 60ch; }
body .lc-texte { border: 0; background: none; box-shadow: none; padding: 0; font-size: 1.06rem; line-height: 1.85; max-width: 78ch; }
body .lc-sommaire { border: 0; border-left: 1px solid var(--border-color); border-radius: 0; background: none; padding-left: 1.2rem; }

/* ==========================================================================
   CHANGELOG : une frise verticale
   ========================================================================== */
body .cg-liste { position: relative; padding-left: clamp(1.4rem, 3vw, 2.4rem); border-left: 1px solid var(--border-strong); max-width: 860px; }
body .cg-carte {
    position: relative; border: 0; border-radius: 0; background: none; box-shadow: none;
    padding: 0 0 clamp(1.8rem, 3.4vw, 3rem);
}
body .cg-carte::before {
    content: ''; position: absolute; left: calc(clamp(1.4rem, 3vw, 2.4rem) * -1 - 6px); top: 0.55rem;
    width: 11px; height: 11px; border-radius: 50%; background: var(--primary-color);
    box-shadow: 0 0 0 5px var(--background-primary), 0 0 18px rgba(76, 141, 255, 0.5);
}
body .cg-date { font-size: 0.78rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.14em; color: var(--text-tertiary); }
body .cg-titre { font-size: clamp(1.5rem, 2.8vw, 2.3rem); font-weight: 700; letter-spacing: -0.04em; line-height: 1.1; margin: 0.35rem 0 0.7rem; }
body .cg-corps { color: var(--text-secondary); font-size: 1.02rem; line-height: 1.75; }
body .cg-corps img { border-radius: 24px; max-width: 100%; }

/* ==========================================================================
   SITES ET BOTS : trois grands panneaux
   ========================================================================== */
body .sb-grille { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 1rem; }
body .sb-carte {
    position: relative; overflow: hidden; isolation: isolate;
    min-height: clamp(260px, 36vh, 380px);
    display: flex; flex-direction: column; justify-content: flex-end; gap: 0.5rem;
    border: 0; border-radius: 36px; padding: clamp(1.4rem, 2.6vw, 2.2rem);
    background: var(--background-secondary);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), var(--shadow-sm);
    transition: transform 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out);
}
body .sb-carte::before {
    content: ''; position: absolute; inset: auto -20% -50% -20%; height: 80%; z-index: -1;
    background: radial-gradient(50% 60% at 50% 100%, rgba(76, 141, 255, 0.4), transparent 70%);
    opacity: 0.5; transition: opacity 0.5s ease;
}
body .sb-carte:hover { transform: translateY(-6px); box-shadow: inset 0 1px 0 rgba(255,255,255,.1), 0 28px 60px -22px rgba(76, 141, 255, 0.5); }
body .sb-carte:hover::before { opacity: 1; }
body .sb-icone {
    position: absolute; top: 1.4rem; left: 1.4rem;
    width: 64px; height: 64px; display: grid; place-items: center; border-radius: 22px;
    background: rgba(76, 141, 255, 0.16); color: var(--primary-color); font-size: 1.9rem;
}
body .sb-nom { font-size: clamp(1.6rem, 2.6vw, 2.2rem); font-weight: 700; letter-spacing: -0.04em; }
body .sb-desc { color: var(--text-secondary); max-width: 32ch; }

/* ==========================================================================
   JEUX (hub)
   ========================================================================== */
body .jx-carte, body .jx-carte-jeu, body .jx-defi-carte, body .jx-diff-carte, body .jx-statbar {
    border: 0; border-radius: 30px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), var(--shadow-sm);
}
body .jx-filtre { border: 0; border-radius: 999px; background: var(--background-secondary); }
body .jx-filtre.actif { background: var(--text-primary); color: var(--background-primary); }
body .jx-modal-partage, body .jx-modal-fond > div { border-radius: 34px; }

/* Sites et bots : pleine largeur, texte à gauche. */
body .sb-grille { max-width: none; width: 100%; margin: 0; }
body .sb-carte { align-items: flex-start; text-align: left; }
body .sb-nom, body .sb-desc { text-align: left; }

/* ── Documents : aucune bordure parasite autour de la ligne survolée ── */
body .doc-grille { border-bottom: 0; }
body .doc-carte, body .doc-carte:hover { box-shadow: none; outline: 0; }
body .doc-carte:not(.vide):hover { border-color: transparent; }
body .doc-carte:hover + .doc-carte { border-top-color: transparent; }

/* ── Suggestion : le panneau s'ouvre et se ferme en douceur ── */
body .sg-modal-fond { animation: sgFondIn 0.4s ease both; }
body .sg-modal { animation: sgPanneauIn 0.6s cubic-bezier(0.22, 1, 0.36, 1) both; }
body .sg-modal-fond.sg-fermeture { animation: sgFondOut 0.38s ease both; pointer-events: none; }
body .sg-modal-fond.sg-fermeture .sg-modal { animation: sgPanneauOut 0.38s cubic-bezier(0.5, 0, 0.75, 0) both; }
@keyframes sgFondIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes sgFondOut { from { opacity: 1; } to { opacity: 0; } }
@keyframes sgPanneauIn {
    from { opacity: 0; transform: translateY(40px) scale(0.94); }
    to   { opacity: 1; transform: none; }
}
@keyframes sgPanneauOut {
    from { opacity: 1; transform: none; }
    to   { opacity: 0; transform: translateY(28px) scale(0.95); }
}
body .sg-modal { max-width: 560px; width: min(560px, calc(100vw - 2rem)); padding: clamp(1.4rem, 3vw, 2rem); }
body .sg-modal h3 { font-size: 1.5rem !important; font-weight: 700 !important; letter-spacing: -0.035em; }
body .sg-champ { margin-bottom: 0.9rem; }
body .sg-champ input[type="text"], body .sg-champ textarea, body .sg-champ select {
    width: 100%; border: 0; border-radius: 18px; padding: 1rem;
    background: var(--background-card); color: var(--text-primary); font: inherit;
}
body .sg-champ textarea { min-height: 120px; resize: vertical; }
body .sg-champ > label:not(.fl-label) { display: block; font-size: 0.8rem; font-weight: 600; color: var(--text-tertiary); margin-bottom: 0.4rem; }
@media (prefers-reduced-motion: reduce) {
    body .sg-modal-fond, body .sg-modal { animation-duration: 0.01ms; }
}

/* ── Classements : le contenu fond sous les fantômes de l'échange ── */
body .rl-apparait > * { animation: rlApparait 0.6s ease both; }
@keyframes rlApparait { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
body .rl-fantome { border-radius: 32px; background: var(--background-secondary); }

/* ==========================================================================
   GIVEAWAYS : une page vivante
   ========================================================================== */
body .gw-chiffres { display: flex; flex-wrap: wrap; gap: 0.7rem; margin: 0 0 1.6rem; }
body .gw-chiffre {
    flex: 1 1 170px; position: relative; overflow: hidden;
    display: grid; grid-template-columns: auto 1fr; align-items: center; column-gap: 0.9rem;
    padding: 1rem 1.2rem; border-radius: 28px;
    background: var(--background-secondary);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), var(--shadow-sm);
    animation: gwMonte 0.7s var(--ease-out) both; animation-delay: calc(var(--i, 0) * 90ms);
}
body .gw-chiffre .material-symbols-outlined {
    grid-row: 1 / span 2; width: 46px; height: 46px; display: grid; place-items: center;
    border-radius: 16px; background: var(--background-card); color: var(--text-secondary);
}
body .gw-chiffre.bleu .material-symbols-outlined { background: rgba(76, 141, 255, 0.18); color: var(--primary-color); }
body .gw-chiffre.rose .material-symbols-outlined { background: rgba(236, 72, 153, 0.18); color: #ec4899; }
body .gw-chiffre.or .material-symbols-outlined { background: rgba(241, 196, 15, 0.18); color: #f1c40f; }
body .gw-chiffre b { font-size: 1.7rem; font-weight: 700; letter-spacing: -0.04em; line-height: 1; font-variant-numeric: tabular-nums; }
body .gw-chiffre em { font-style: normal; font-size: 0.82rem; color: var(--text-tertiary); }

@keyframes gwMonte { from { opacity: 0; transform: translateY(18px) scale(0.97); } to { opacity: 1; transform: none; } }

/* Cartes : entrée en cascade, reflet qui passe au survol. */
body .gw-carte {
    position: relative; isolation: isolate;
    animation: gwMonte 0.8s var(--ease-out) both; animation-delay: calc(var(--i, 0) * 110ms);
}
body .gw-carte::before {
    content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
    background: radial-gradient(420px 220px at 0% 0%, color-mix(in srgb, var(--teinte, var(--primary-color)) 30%, transparent), transparent 70%);
}
body .gw-carte::after {
    content: ''; position: absolute; top: 0; bottom: 0; width: 40%; left: -60%; z-index: 2; pointer-events: none;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.07), transparent);
    transform: skewX(-18deg); transition: left 0.9s var(--ease-out);
}
body .gw-carte:hover::after { left: 120%; }
body .gw-vignette { width: 64px; height: 64px; border-radius: 22px; box-shadow: var(--shadow-md); }
body .gw-vignette-vide { display: grid; place-items: center; background: color-mix(in srgb, var(--teinte, var(--primary-color)) 22%, transparent); color: var(--teinte, var(--primary-color)); }
body .gw-vignette-vide .material-symbols-outlined { font-size: 2rem; animation: gwBalance 3.2s ease-in-out infinite; }
@keyframes gwBalance { 0%, 100% { transform: rotate(-6deg); } 50% { transform: rotate(6deg) translateY(-2px); } }

/* Compte à rebours : quatre cases qui battent. */
body .gw-rebours { display: flex; gap: 0.4rem; }
body .gw-rebours span {
    display: flex; flex-direction: column; align-items: center; min-width: 54px;
    padding: 0.45rem 0.5rem; border-radius: 16px; background: rgba(76, 141, 255, 0.14);
}
body .gw-rebours b { font-size: 1.25rem; font-weight: 700; letter-spacing: -0.03em; line-height: 1.1; font-variant-numeric: tabular-nums; }
body .gw-rebours i { font-style: normal; font-size: 0.64rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-tertiary); }
body .gw-rebours b.tic { animation: gwTic 0.4s var(--ease-out); }
@keyframes gwTic { from { transform: translateY(-6px); opacity: 0.4; } to { transform: none; opacity: 1; } }

/* Aucun concours : une scène animée plutôt qu'un cadre vide. */
body .gw-vide { border: 0; background: none; box-shadow: none; padding: clamp(2rem, 6vw, 4.5rem) 1rem; text-align: center; }
body .gw-vide-scene { position: relative; width: 150px; height: 150px; margin: 0 auto 1.4rem; }
body .gw-vide-icone {
    position: absolute; inset: 0; margin: auto; width: 112px; height: 112px; display: grid; place-items: center;
    border-radius: 38px; font-size: 3.4rem; color: var(--primary-color);
    background: linear-gradient(160deg, rgba(76, 141, 255, 0.28), rgba(76, 141, 255, 0.08));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 24px 50px -18px rgba(76, 141, 255, 0.6);
    animation: gwFlotte 4s ease-in-out infinite;
}
@keyframes gwFlotte { 0%, 100% { transform: translateY(0) rotate(-3deg); } 50% { transform: translateY(-12px) rotate(3deg); } }
body .gw-vide-scene i {
    position: absolute; width: 10px; height: 10px; border-radius: 3px; opacity: 0;
    animation: gwConfetti 3.6s ease-in-out infinite;
}
body .gw-vide-scene .c1 { left: 8%; top: 40%; background: #4c8dff; animation-delay: 0s; }
body .gw-vide-scene .c2 { left: 86%; top: 30%; background: #ec4899; animation-delay: 0.7s; }
body .gw-vide-scene .c3 { left: 20%; top: 8%; background: #f1c40f; animation-delay: 1.4s; }
body .gw-vide-scene .c4 { left: 74%; top: 6%; background: #30d158; animation-delay: 2.1s; }
body .gw-vide-scene .c5 { left: 50%; top: -4%; background: #5ac8fa; animation-delay: 2.8s; }
@keyframes gwConfetti {
    0% { opacity: 0; transform: translateY(0) rotate(0); }
    20% { opacity: 1; }
    100% { opacity: 0; transform: translateY(70px) rotate(220deg); }
}
body .gw-vide h3 { font-size: clamp(1.4rem, 2.4vw, 2rem); font-weight: 700; letter-spacing: -0.035em; margin-bottom: 0.4rem; }
body .gw-vide p { color: var(--text-secondary); max-width: 46ch; margin: 0 auto 1.4rem; }
body .gw-vide-lien {
    display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.8rem 1.3rem; border-radius: 999px;
    background: var(--text-primary); color: var(--background-primary); font-weight: 600; text-decoration: none;
    transition: background-color 0.4s ease, color 0.4s ease;
}
body .gw-vide-lien:hover { background: #5865f2; color: #fff; }

@media (prefers-reduced-motion: reduce) {
    body .gw-chiffre, body .gw-carte, body .gw-vide-icone, body .gw-vide-scene i, body .gw-vignette-vide .material-symbols-outlined { animation: none; opacity: 1; }
}

/* ==========================================================================
   ANNIVERSAIRES : plus de vie
   ========================================================================== */
body .an-card { animation: anMonte 0.7s var(--ease-out) both; position: relative; overflow: hidden; }
body .an-card:nth-child(1) { animation-delay: 0.02s; } body .an-card:nth-child(2) { animation-delay: 0.08s; }
body .an-card:nth-child(3) { animation-delay: 0.14s; } body .an-card:nth-child(4) { animation-delay: 0.2s; }
body .an-card:nth-child(5) { animation-delay: 0.26s; } body .an-card:nth-child(6) { animation-delay: 0.32s; }
body .an-card:nth-child(n+7) { animation-delay: 0.38s; }
@keyframes anMonte { from { opacity: 0; transform: translateY(20px) scale(0.97); } to { opacity: 1; transform: none; } }

/* Le jour même : halo qui respire, confettis qui tombent. */
body .an-card.today::before {
    content: ''; position: absolute; inset: -40%; z-index: 0; pointer-events: none;
    background: conic-gradient(from 0deg, transparent, rgba(249, 115, 22, 0.22), transparent 40%, rgba(236, 72, 153, 0.18), transparent 80%);
    animation: anTourne 7s linear infinite;
}
body .an-card.today > * { position: relative; z-index: 1; }
@keyframes anTourne { to { transform: rotate(360deg); } }
body .an-card.today .an-avatar { box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.8), 0 0 28px rgba(249, 115, 22, 0.55); animation: anPulse 2.4s ease-in-out infinite; }
@keyframes anPulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.06); } }

body .an-avatar { transition: transform 0.5s var(--ease-out); }
body .an-card:hover .an-avatar { transform: scale(1.08) rotate(-4deg); }
body .an-compte {
    display: inline-flex; align-items: center; padding: 0.4rem 1rem; border-radius: 999px;
    background: var(--background-secondary); font-weight: 600; font-size: 0.9rem;
}
body .an-nav { margin-bottom: 1rem; }

/* Calendrier : jours qui réagissent, marqueur qui pulse. */
body .an-jour-case { transition: transform 0.25s var(--ease-out), background-color 0.25s ease; }
body .an-jour-case:not(.hors):hover { transform: scale(1.18); background: var(--background-card-hover); }
body .an-jour-case.fete::after { animation: anPoint 2.2s ease-in-out infinite; }
@keyframes anPoint { 0%, 100% { transform: translateX(-50%) scale(1); opacity: 1; } 50% { transform: translateX(-50%) scale(1.7); opacity: 0.6; } }
body .an-jour-case.aujourdhui { box-shadow: 0 0 0 2px rgba(236, 72, 153, 0.7); }
body .an-next-row { transition: transform 0.4s var(--ease-out), background-color 0.3s ease; animation: anMonte 0.6s var(--ease-out) both; }
body .an-next-row:hover { transform: translateX(6px); background: var(--background-card-hover); }
body .an-today-title { font-size: 1.1rem; font-weight: 700; letter-spacing: -0.02em; }
@media (prefers-reduced-motion: reduce) {
    body .an-card, body .an-card.today::before, body .an-card.today .an-avatar, body .an-jour-case.fete::after, body .an-next-row { animation: none; }
}

/* ==========================================================================
   JEUX : un vrai hub
   ========================================================================== */
body .jx-hero { margin-bottom: 1.2rem; }
body .jx-filtres { gap: 0.4rem; padding: 0.3rem; border-radius: 999px; background: var(--background-card); width: max-content; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
body .jx-filtre {
    border: 0; background: none; padding: 0.55rem 1.1rem; font-weight: 600;
    transition: background-color 0.3s ease, color 0.3s ease;
}
body .jx-filtre.actif { background: var(--background-secondary); color: var(--text-primary); box-shadow: inset 0 1px 0 rgba(255,255,255,.1), 0 4px 12px rgba(0,0,0,.3); }

body .jx-grille { grid-template-columns: repeat(auto-fill, minmax(min(100%, 290px), 1fr)); gap: 1rem; perspective: 1200px; }
body .jx-carte {
    --t: 76, 141, 255;
    min-height: 230px; border: 0; border-radius: 34px; padding: 1.5rem;
    background:
        radial-gradient(340px 200px at 100% 0%, rgba(var(--t), 0.2), transparent 70%),
        var(--background-secondary);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07), var(--shadow-sm);
    animation: jxMonte 0.7s var(--ease-out) both;
    transition: transform 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out);
}
body .jx-carte:nth-child(6n+1) { --t: 76, 141, 255; animation-delay: 0.02s; }
body .jx-carte:nth-child(6n+2) { --t: 236, 72, 153; animation-delay: 0.07s; }
body .jx-carte:nth-child(6n+3) { --t: 241, 196, 15; animation-delay: 0.12s; }
body .jx-carte:nth-child(6n+4) { --t: 48, 209, 88; animation-delay: 0.17s; }
body .jx-carte:nth-child(6n+5) { --t: 168, 85, 247; animation-delay: 0.22s; }
body .jx-carte:nth-child(6n) { --t: 249, 115, 22; animation-delay: 0.27s; }
@keyframes jxMonte { from { opacity: 0; transform: translateY(24px) rotateX(8deg) scale(0.96); } to { opacity: 1; transform: none; } }
body .jx-carte:hover {
    transform: translateY(-8px) rotateX(2deg); border: 0;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 30px 60px -22px rgba(var(--t), 0.55);
}
body .jx-carte::before { background: radial-gradient(260px 160px at 50% 110%, rgba(var(--t), 0.35), transparent 70%); }
body .jx-carte .icone-tuile {
    width: 64px; height: 64px; border-radius: 22px;
    background: rgba(var(--t), 0.18);
    transition: transform 0.5s var(--ease-out);
}
body .jx-carte:hover .icone-tuile { transform: rotate(-8deg) scale(1.1); }
body .jx-carte .icone-tuile .material-symbols-outlined { color: rgb(var(--t)); font-size: 2.1rem; }
body .jx-carte h3 { font-size: 1.35rem; font-weight: 700; letter-spacing: -0.03em; }
body .jx-carte p { font-size: 0.9rem; color: var(--text-tertiary); }
body .jx-carte .jx-cat { border-radius: 999px; background: rgba(var(--t), 0.14); color: rgb(var(--t)); }
body .jx-carte .jx-jouer {
    opacity: 1; transform: none; align-self: flex-start;
    padding: 0.5rem 0.95rem; border-radius: 999px; background: var(--text-primary); color: var(--background-primary);
    transition: background-color 0.35s ease, color 0.35s ease, transform 0.4s var(--ease-out);
}
body .jx-carte:hover .jx-jouer { background: rgb(var(--t)); color: #fff; transform: translateX(4px); }

body .jx-panneau { border: 0; border-radius: clamp(28px, 3vw, 44px); background: var(--background-secondary); box-shadow: inset 0 1px 0 rgba(255,255,255,.06), var(--shadow-md); }
body .jx-retour { padding: 0.5rem 1rem; border-radius: 999px; background: var(--background-card); transition: background-color 0.3s ease, transform 0.35s var(--ease-out); }
body .jx-retour:hover { background: var(--background-card-hover); transform: translateX(-4px); color: var(--text-primary); }
@media (prefers-reduced-motion: reduce) { body .jx-carte { animation: none; } }

/* ==========================================================================
   GIVEAWAYS V2 : billets, panneau gagnant, état vide statique
   ========================================================================== */
body .gw-liste { grid-template-columns: repeat(auto-fill, minmax(min(100%, 520px), 1fr)); }

body .gw-ticket {
    --teinte: var(--primary-color);
    position: relative; display: grid; grid-template-columns: minmax(150px, 34%) minmax(0, 1fr);
    min-height: 250px; border-radius: 34px; overflow: hidden;
    background: var(--background-secondary);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07), var(--shadow-sm);
    transition: transform 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out);
}
body .gw-ticket:hover { transform: translateY(-5px); box-shadow: inset 0 1px 0 rgba(255,255,255,.1), var(--shadow-lg); }
body .gw-ticket.vedette { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--teinte) 60%, transparent), var(--shadow-md); }

/* La souche : la partie détachable du billet, aux couleurs du concours. */
body .gw-souche {
    position: relative; display: flex; flex-direction: column; justify-content: flex-end; gap: 0.35rem;
    padding: 1.4rem; color: #fff;
    background: linear-gradient(160deg, color-mix(in srgb, var(--teinte) 85%, #fff 0%), color-mix(in srgb, var(--teinte) 45%, #000));
    border-right: 2px dashed rgba(255, 255, 255, 0.28);
}
body .gw-souche::before, body .gw-souche::after {
    content: ''; position: absolute; right: -13px; width: 24px; height: 24px; border-radius: 50%;
    background: var(--background-primary);
}
body .gw-souche::before { top: -12px; }
body .gw-souche::after { bottom: -12px; }
body .gw-souche-ic { font-size: 2.4rem; margin-bottom: auto; opacity: 0.95; }
body .gw-souche-lbl { font-size: 0.7rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; opacity: 0.8; }
body .gw-souche-lot { font-size: clamp(1.05rem, 1.6vw, 1.35rem); font-weight: 700; letter-spacing: -0.02em; line-height: 1.2; overflow-wrap: anywhere; }

body .gw-ticket .gw-corps { padding: clamp(1.1rem, 2vw, 1.6rem); display: flex; flex-direction: column; gap: 0.7rem; }
body .gw-ticket .gw-titre { font-size: clamp(1.25rem, 1.9vw, 1.65rem); font-weight: 700; letter-spacing: -0.035em; line-height: 1.15; }
body .gw-ticket .gw-desc { color: var(--text-secondary); font-size: 0.95rem; line-height: 1.55; }
body .gw-ticket .gw-meta { display: flex; flex-wrap: wrap; gap: 0.4rem; }
body .gw-ticket .gw-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-top: auto; }
body .gw-ticket .gw-gagnants { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: auto; }
@media (max-width: 560px) {
    body .gw-ticket { grid-template-columns: 1fr; }
    body .gw-souche { border-right: 0; border-bottom: 2px dashed rgba(255,255,255,.28); min-height: 120px; }
    body .gw-souche::before, body .gw-souche::after { display: none; }
}

/* Gagnants : des pastilles qu'on peut ouvrir. */
body button.gw-gagnant {
    display: inline-flex; align-items: center; gap: 0.55rem; padding: 0.35rem 0.8rem 0.35rem 0.35rem;
    border: 0; border-radius: 999px; cursor: pointer; font: inherit; color: var(--text-primary);
    background: var(--background-card);
    transition: background-color 0.3s ease, transform 0.4s var(--ease-out);
}
body button.gw-gagnant:hover { background: var(--background-card-hover); transform: translateY(-2px); }
body .gw-gagnant .gw-avatar { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; }
body .gw-gagnant-nom { font-weight: 600; font-size: 0.9rem; }
body .gw-gagnant-ic { font-size: 1.1rem; color: #f1c40f; }
body button.gw-rang { width: 100%; text-align: left; font: inherit; color: inherit; cursor: pointer; }

/* Panneau d'un gagnant */
.gw-panneau-fond {
    position: fixed; inset: 0; z-index: 3000; display: grid; place-items: center; padding: 1.2rem;
    background: rgba(0, 0, 0, 0.55); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
}
.gw-panneau {
    position: relative; width: min(480px, 100%); max-height: 86vh; overflow-y: auto;
    padding: clamp(1.4rem, 3vw, 2rem); border-radius: 36px;
    border: 1px solid var(--border-strong); background: var(--background-elevated);
    box-shadow: var(--shadow-xl);
}
.gw-panneau-x {
    position: absolute; top: 1rem; right: 1rem; width: 40px; height: 40px; border: 0; border-radius: 50%;
    display: grid; place-items: center; cursor: pointer; background: var(--background-card); color: var(--text-secondary);
    transition: background-color 0.25s ease, transform 0.4s var(--ease-out);
}
.gw-panneau-x:hover { background: var(--background-card-hover); transform: rotate(90deg); color: var(--text-primary); }
.gw-panneau-tete { display: flex; align-items: center; gap: 1.1rem; margin-bottom: 1.4rem; padding-right: 3rem; }
.gw-panneau-avatar { width: 84px; height: 84px; border-radius: 28px; object-fit: cover; box-shadow: var(--shadow-md); }
.gw-panneau-nom { font-size: clamp(1.4rem, 3vw, 1.9rem); font-weight: 700; letter-spacing: -0.04em; line-height: 1.1; }
.gw-panneau-sous { display: inline-flex; align-items: center; gap: 0.35rem; margin-top: 0.3rem; color: #f1c40f; font-weight: 600; font-size: 0.9rem; }
.gw-panneau-corps { display: flex; flex-direction: column; gap: 0.5rem; margin-bottom: 1.2rem; }
.gw-panneau-gain {
    display: flex; align-items: center; gap: 0.9rem; padding: 0.85rem 1rem; border-radius: 22px;
    background: var(--background-card);
}
.gw-panneau-gain > .material-symbols-outlined {
    width: 44px; height: 44px; display: grid; place-items: center; flex: none; border-radius: 15px;
    background: rgba(241, 196, 15, 0.16); color: #f1c40f;
}
.gw-panneau-gain strong { display: block; font-weight: 600; letter-spacing: -0.015em; }
.gw-panneau-gain em { font-style: normal; font-size: 0.82rem; color: var(--text-tertiary); }
.gw-panneau-profil { width: 100%; justify-content: center; text-decoration: none; }

/* Aucun concours : un logo fixe, rien d'autre qui bouge. */
body .gw-vide-logo {
    width: 104px; height: 104px; display: grid; place-items: center; margin: 0 auto 1.3rem;
    border-radius: 36px; font-size: 3.2rem; color: var(--primary-color);
    background: linear-gradient(160deg, rgba(76, 141, 255, 0.26), rgba(76, 141, 255, 0.08));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

/* ==========================================================================
   Documents : aucune animation au survol ; liste de navigation dans le lecteur
   ========================================================================== */
body .doc-carte, body .doc-carte:hover, body .doc-carte:not(.vide):hover {
    background: none !important; padding-left: clamp(0.6rem, 1.4vw, 1.1rem) !important;
    border-radius: 0 !important; transform: none !important; box-shadow: none !important;
    transition: none !important;
}
body .doc-carte:hover h3 { color: var(--text-primary); }
body .doc-carte:hover .doc-icone, body .doc-carte:hover .doc-icone * { transform: none !important; }

body .dv-page { display: grid; grid-template-columns: minmax(180px, 250px) minmax(0, 1fr); gap: clamp(1rem, 3vw, 3rem); align-items: start; }
body .dv-nav {
    position: sticky; top: calc(var(--nav-height) + 1rem);
    display: flex; flex-direction: column; gap: 0.3rem; padding: 0.7rem;
    border-radius: 28px; background: var(--background-secondary);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), var(--shadow-sm);
}
body .dv-retour {
    display: flex; align-items: center; gap: 0.5rem; padding: 0.55rem 0.8rem; margin-bottom: 0.3rem;
    border-radius: 999px; text-decoration: none; font-size: 0.82rem; font-weight: 600; color: var(--text-tertiary);
    transition: color 0.25s ease, transform 0.4s var(--ease-out);
}
body .dv-retour:hover { color: var(--text-primary); transform: translateX(-3px); }
body .dv-item {
    display: flex; align-items: center; gap: 0.7rem; padding: 0.65rem 0.8rem; border-radius: 18px;
    text-decoration: none; color: var(--text-secondary); font-weight: 500; font-size: 0.92rem;
    transition: background-color 0.3s ease, color 0.3s ease;
}
body .dv-item .material-symbols-outlined { font-size: 1.25rem; }
body .dv-item:hover { background: var(--background-card); color: var(--text-primary); }
body .dv-item.actif { background: var(--primary-color); color: #fff; font-weight: 600; }
@media (max-width: 900px) {
    body .dv-page { grid-template-columns: 1fr; }
    body .dv-nav { position: static; flex-direction: row; overflow-x: auto; scrollbar-width: none; }
    body .dv-item { white-space: nowrap; }
}

/* ==========================================================================
   SUGGESTION V2 : filtres animés, barre de votes
   ========================================================================== */
body .sg-filtres {
    position: relative; display: inline-flex; gap: 0.2rem; padding: 0.3rem; margin-bottom: 1.2rem;
    border-radius: 999px; background: var(--background-card); max-width: 100%; overflow-x: auto; scrollbar-width: none;
}
body .sg-ind {
    position: absolute; top: 0.3rem; bottom: 0.3rem; left: 0; width: 0; border-radius: 999px;
    background: var(--background-secondary); box-shadow: inset 0 1px 0 rgba(255,255,255,.1), 0 4px 12px rgba(0,0,0,.3);
    transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1), width 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}
body .sg-filtre {
    position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 0.45rem;
    padding: 0.6rem 1.05rem; border: 0; border-radius: 999px; background: none; cursor: pointer;
    font: inherit; font-weight: 600; font-size: 0.9rem; color: var(--text-tertiary); white-space: nowrap;
    transition: color 0.3s ease;
}
body .sg-filtre:hover, body .sg-filtre.actif { color: var(--text-primary); }
body .sg-filtre .material-symbols-outlined { font-size: 1.15rem; }
body .sg-filtre em { font-style: normal; font-size: 0.74rem; padding: 0.05rem 0.45rem; border-radius: 999px; background: var(--background-card); }

body .sg-carte { animation: sgCarteIn 0.6s var(--ease-out) both; animation-delay: calc(var(--i, 0) * 50ms); }
@keyframes sgCarteIn { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
body .sg-barre {
    display: flex; height: 10px; border-radius: 999px; overflow: hidden; margin-top: 1rem;
    background: var(--background-card);
}
body .sg-barre i { display: block; height: 100%; transition: width 0.8s var(--ease-out); }
body .sg-barre .pour { background: #30d158; }
body .sg-barre .neutre { background: #8e8e93; }
body .sg-barre .contre { background: #ff453a; }
body .sg-legende { display: flex; gap: 1rem; margin-top: 0.5rem; font-size: 0.82rem; color: var(--text-tertiary); flex-wrap: wrap; }
body .sg-legende b { color: var(--text-primary); font-weight: 600; margin-right: 0.15rem; }
body .sg-legende .pour b { color: #30d158; } body .sg-legende .contre b { color: #ff453a; }
body .sg-echeance { display: flex; align-items: center; gap: 0.4rem; margin-top: 0.8rem; }
body .sg-echeance .material-symbols-outlined { font-size: 1.05rem; }
body .sg-validee { box-shadow: inset 0 0 0 1px rgba(48, 209, 88, 0.4), var(--shadow-sm); }
body .sg-refusee { opacity: 0.85; }
@media (prefers-reduced-motion: reduce) { body .sg-carte { animation: none; } }

/* ==========================================================================
   ANNIVERSAIRES V3 : une frise du mois, sans rotation, très fluide
   ========================================================================== */
body .an-card.today .an-avatar, body .an-card:hover .an-avatar { animation: none; transform: none; }
body .an-card.today::before { animation: none; }

body .an-frise { display: flex; flex-direction: column; }
body .an-frise.va-droite { animation: anVaDroite 0.7s var(--ease-out) both; }
body .an-frise.va-gauche { animation: anVaGauche 0.7s var(--ease-out) both; }
@keyframes anVaDroite { from { opacity: 0; transform: translateX(60px); } to { opacity: 1; transform: none; } }
@keyframes anVaGauche { from { opacity: 0; transform: translateX(-60px); } to { opacity: 1; transform: none; } }

body .an-jr {
    display: grid; grid-template-columns: clamp(72px, 9vw, 120px) 22px minmax(0, 1fr);
    gap: clamp(0.6rem, 1.6vw, 1.4rem); padding-bottom: clamp(1rem, 2vw, 1.6rem);
    animation: anJour 0.7s var(--ease-out) both; animation-delay: calc(var(--i, 0) * 60ms);
}
@keyframes anJour { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
body .an-jr-num { text-align: right; line-height: 1; padding-top: 0.2rem; }
body .an-jr-num b { display: block; font-size: clamp(2.4rem, 5vw, 4.2rem); font-weight: 700; letter-spacing: -0.06em; font-variant-numeric: tabular-nums; }
body .an-jr-num span { font-size: 0.78rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-tertiary); }
body .an-jr-rail { position: relative; display: flex; justify-content: center; }
body .an-jr-rail::before { content: ''; position: absolute; top: 0.9rem; bottom: -1.6rem; width: 1px; background: var(--border-strong); }
body .an-jr:last-child .an-jr-rail::before { bottom: 0; }
body .an-jr-rail i {
    position: relative; margin-top: 0.8rem; width: 12px; height: 12px; border-radius: 50%;
    background: var(--background-primary); box-shadow: 0 0 0 2px var(--border-strong);
}
body .an-jr.now .an-jr-rail i { background: #f97316; box-shadow: 0 0 0 2px #f97316, 0 0 18px rgba(249, 115, 22, 0.8); }
body .an-jr-gens { display: flex; flex-wrap: wrap; gap: 0.6rem; align-content: flex-start; padding-top: 0.1rem; }
body .an-jr-fete {
    flex-basis: 100%; display: flex; align-items: center; gap: 0.4rem; font-weight: 700; color: #f97316; font-size: 0.9rem;
}
body .an-gens {
    display: inline-flex; align-items: center; gap: 0.7rem; padding: 0.4rem 1rem 0.4rem 0.4rem; border-radius: 999px;
    text-decoration: none; color: var(--text-primary); font-weight: 600; letter-spacing: -0.01em;
    background: var(--background-secondary);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
    transition: transform 0.5s var(--ease-out), background-color 0.3s ease, box-shadow 0.4s ease;
}
body .an-gens img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; transition: transform 0.5s var(--ease-out); }
body .an-gens:hover { transform: translateY(-3px); background: var(--background-card-hover); box-shadow: var(--shadow-md); }
body .an-gens:hover img { transform: scale(1.06); }
body .an-jr.now .an-gens { background: linear-gradient(120deg, rgba(249, 115, 22, 0.28), var(--background-secondary)); }
@media (prefers-reduced-motion: reduce) { body .an-jr, body .an-frise { animation: none; } }

/* ==========================================================================
   JEUX V3 : une salle de jeu immersive
   ========================================================================== */
/* Filtres : contraste net, le filtre actif est plein. */
body .jx-filtres { background: var(--background-secondary); padding: 0.35rem; gap: 0.25rem; }
body .jx-filtre { color: var(--text-primary); opacity: 0.8; font-weight: 600; font-size: 0.92rem; padding: 0.6rem 1.15rem; }
body .jx-filtre:hover { opacity: 1; background: var(--background-card-hover); }
body .jx-filtre.actif { opacity: 1; background: var(--primary-color); color: #fff; box-shadow: 0 6px 18px -6px rgba(76, 141, 255, 0.7); }

/* Le défi du jour : une carte plus large, en tête. */
body .jx-carte.jx-vedette { grid-column: span 2; background:
    radial-gradient(500px 260px at 100% 0%, rgba(76, 141, 255, 0.34), transparent 70%), var(--background-secondary); }
@media (max-width: 640px) { body .jx-carte.jx-vedette { grid-column: span 1; } }

/* La salle : plein écran sous la barre de navigation. */
body #jxPlay:not([hidden]) {
    position: fixed; inset: 0; z-index: 900; overflow-y: auto;
    padding: calc(var(--nav-height) + 1rem) clamp(1rem, 4vw, 4rem) 3rem;
    display: flex; flex-direction: column; gap: 1rem;
    background:
        radial-gradient(900px 480px at 50% -5%, rgba(76, 141, 255, 0.2), transparent 70%),
        var(--background-primary);
}
body .jx-hud { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
body .jx-hud-titre { display: inline-flex; align-items: center; gap: 0.6rem; font-size: 1.15rem; font-weight: 700; letter-spacing: -0.03em; flex: 1; justify-content: center; }
body .jx-hud-titre .material-symbols-outlined { color: var(--primary-color); }
body .jx-rejouer {
    display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.55rem 1rem; border: 0; border-radius: 999px; cursor: pointer;
    background: var(--background-card); color: var(--text-primary); font: inherit; font-weight: 600; font-size: 0.88rem;
    transition: background-color 0.3s ease, transform 0.4s var(--ease-out);
}
body .jx-rejouer:hover { background: var(--primary-color); color: #fff; transform: rotate(-2deg) scale(1.03); }
body #jxJeuZone { max-width: 1100px; width: 100%; margin: 0 auto; }
body #jxJeuZone .jx-panneau { background: transparent; box-shadow: none; padding-top: 0.5rem; }

/* La carte devient la salle (View Transitions). */
::view-transition-group(jeu-salle) { animation-duration: 0.6s; animation-timing-function: cubic-bezier(0.22, 1, 0.36, 1); }
::view-transition-old(jeu-salle), ::view-transition-new(jeu-salle) { height: 100%; object-fit: cover; }

/* ==========================================================================
   V7 (pages) : onglets glissants, documents, jeux, giveaways
   ========================================================================== */
.onglet-ind {
    position: absolute; left: 0; bottom: -1px; height: 2px; border-radius: 2px;
    background: var(--primary-color); pointer-events: none;
}
body .rl-tab::after, body .gw-onglet::after, body .rl-tab.active::after, body .gw-onglet.active::after { display: none; }

/* Documents : le surlignage actif n'apparaît qu'une fois les lignes en place. */
body .dv-item.actif { background: transparent; color: var(--text-secondary); font-weight: 500; }
body .dv-nav.pret .dv-item.actif {
    background: var(--primary-color); color: #fff; font-weight: 600;
    animation: dvActif 0.55s var(--ease-out) both;
}
@keyframes dvActif { from { opacity: 0; transform: scale(0.94); } to { opacity: 1; transform: none; } }

/* Jeux : plus de petite rotation du logo. */
body .jx-carte:hover .icone-tuile, body .jx-rejouer:hover { transform: none !important; }
body .jx-carte:hover .icone-tuile { transform: scale(1.04) !important; }

/* Giveaways : le logo du cadeau est centré, et les billets deviennent des affiches. */
body .gw-vide-logo { display: flex; align-items: center; justify-content: center; line-height: 1; padding: 0; }
body .gw-liste { grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); }
body .gw-ticket {
    display: flex; flex-direction: column; min-height: 0; border-radius: 36px;
}
body .gw-souche {
    flex: none; border-right: 0; flex-direction: column; justify-content: flex-end; gap: 0.3rem;
    min-height: 170px; padding: 1.4rem 1.4rem 1.2rem; overflow: hidden;
    background:
        radial-gradient(260px 160px at 100% 0%, rgba(255, 255, 255, 0.28), transparent 70%),
        linear-gradient(160deg, color-mix(in srgb, var(--teinte) 90%, #fff 0%), color-mix(in srgb, var(--teinte) 40%, #000));
}
body .gw-souche::before, body .gw-souche::after { display: none; }
body .gw-souche-ic {
    position: absolute; right: -0.4rem; top: -0.6rem; margin: 0; font-size: 8.5rem; opacity: 0.18; line-height: 1;
}
body .gw-souche-lbl { position: absolute; top: 1.2rem; left: 1.4rem; padding: 0.3rem 0.7rem; border-radius: 999px; background: rgba(0,0,0,.28); }
body .gw-souche-lot { font-size: clamp(1.4rem, 2.2vw, 1.9rem); line-height: 1.12; position: relative; }
body .gw-ticket .gw-corps { padding: 1.2rem 1.4rem 1.4rem; flex: 1; }
body .gw-ticket .gw-titre { font-size: 1.1rem; font-weight: 600; color: var(--text-secondary); letter-spacing: -0.015em; }
body .gw-ticket .gw-actions .gw-btn { flex: 1; justify-content: center; }
body .gw-ticket.fini .gw-souche { filter: saturate(0.6); }

/* Cadeau : un vrai SVG, centré par construction (plus de glyphe de police). */
body .gw-vide-logo svg { display: block; margin: auto; }

/* Recherche du classement : un seul cadre, celui de la boîte (pas de second anneau sur le champ). */
body .rl-search input, body .rl-search input:focus, body .rl-search input:focus-visible {
    border: 0 !important; outline: 0 !important; box-shadow: none !important; background: transparent !important;
}

.sg-pied { display: flex; align-items: center; justify-content: space-between; gap: 0.8rem; flex-wrap: wrap; }
.sg-suppr { display: inline-flex; align-items: center; gap: 0.4rem; border: 0; border-radius: 999px; padding: 0.4rem 0.9rem; background: var(--background-card); color: var(--text-secondary);
    font: inherit; font-size: 0.82rem; font-weight: 700; cursor: pointer; transition: background 0.3s, color 0.3s; }
.sg-suppr:hover { background: rgba(255,69,58,0.18); color: #ff6b61; } .sg-suppr .material-symbols-outlined { font-size: 1.1rem; }
