/* ==========================================================================
   04. SECTIONS & PAGES (consolidé : 04, 04a-04k, 08, stats profil)
   Issu du découpage par domaine de l'ancien custom.css monolithique
   (2947 lignes) — voir AUDIT_REFONTE_2026.md / CLAUDE.md. Ordre de chargement
   des fichiers dans base.html : base, layout, components, pages, utilities,
   animations, footer — NE PAS réordonner les <link> sans revérifier la
   cascade (des règles de spécificité égale peuvent se chevaucher entre fichiers).
   ========================================================================== */

/* ==========================================================================
   04. SECTIONS & PAGES
   ========================================================================== */

/* ─────────────────────────────────────────────────────────────────────
   HEADER / NAVBAR — Command Bridge
   ───────────────────────────────────────────────────────────────────── */

/* ── Base ─────────────────────────────────────────────────────────────── */
.kaiba-navbar {
    position: relative;
    background: rgba(0, 4, 8, 0.82);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid rgba(0, 170, 255, 0.28);
    padding: 0;
    transition: background 0.4s ease, box-shadow 0.4s ease;
    animation: navbarFadeIn 0.6s ease-out forwards;
    z-index: 1030;
}

/* Scrolled — plus opaque, ombre portée plus forte */
.kaiba-navbar.nav-scrolled {
    background: rgba(0, 2, 6, 0.97);
    box-shadow: 0 4px 28px rgba(0, 170, 255, 0.38), 0 1px 0 rgba(0, 170, 255, 0.5);
}

/* Ligne de base néon continue */
.kaiba-navbar::before {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(0, 170, 255, 0.45) 20%,
        rgba(0, 170, 255, 0.45) 80%,
        transparent 100%
    );
    pointer-events: none;
}


/* ── Container ────────────────────────────────────────────────────────── */
.kaiba-navbar .container-fluid {
    height: 62px;
    padding: 0 20px;
    transition: height 0.3s ease;
}
.kaiba-navbar.nav-scrolled .container-fluid { height: 56px; }

/* ── Brand ────────────────────────────────────────────────────────────── */
.kaiba-navbar .navbar-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0;
    text-decoration: none;
    transition: opacity 0.2s;
    flex-shrink: 0;
}
.kaiba-navbar .navbar-brand:hover { opacity: 0.85; }

.brand-logo {
    height: 46px;
    filter: drop-shadow(0 0 8px rgba(0, 170, 255, 0.7));
    transition: filter 0.3s, height 0.3s;
}
.kaiba-navbar.nav-scrolled .brand-logo { height: 40px; }
.kaiba-navbar .navbar-brand:hover .brand-logo {
    filter: drop-shadow(0 0 12px rgba(0, 170, 255, 1));
}

.brand-text-group {
    display: flex;
    flex-direction: column;
    line-height: 1;
    gap: 3px;
}

/* Override du logo-text global dans le contexte navbar */
.kaiba-navbar .logo-text {
    font-size: 1.55rem;
    letter-spacing: 2px;
}

.brand-subtitle {
    font-family: 'Exo 2', sans-serif;
    font-size: 0.50rem;
    font-weight: 600;
    letter-spacing: 2.8px;
    text-transform: uppercase;
    color: rgba(0, 170, 255, 0.65);
    white-space: nowrap;
}

/* ── Nav links ────────────────────────────────────────────────────────── */
.kaiba-navbar .navbar-nav { align-items: center; }

.kaiba-navbar .nav-link {
    font-family: 'Exo 2', sans-serif;
    font-size: 0.80rem;
    font-weight: 600;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    color: var(--kaiba-text-light);
    padding: 0.45rem 1rem;
    position: relative;
    white-space: nowrap;
    transition: color 0.22s ease;
    background: none !important;
    border: none !important;
}

/* Supprime le border-box de l'ancien active */
.kaiba-navbar .nav-link.active {
    color: var(--kaiba-gold) !important;
    text-shadow: 0 0 10px var(--kaiba-gold-glow);
}

.kaiba-navbar .nav-link:hover { color: var(--kaiba-gold); }

/* Indicateur actif — ligne dorée glissante (non-dropdown seulement) */
.kaiba-navbar .nav-link:not(.dropdown-toggle)::after {
    content: '';
    position: absolute;
    bottom: 3px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--kaiba-gold);
    box-shadow: 0 0 8px var(--kaiba-gold-glow), 0 0 16px var(--kaiba-gold-glow);
    border-radius: 1px;
    transition: width 0.28s ease, left 0.28s ease;
}
.kaiba-navbar .nav-link:not(.dropdown-toggle):hover::after,
.kaiba-navbar .nav-link:not(.dropdown-toggle).active::after {
    width: calc(100% - 2rem);
    left: 1rem;
}

/* ── Dropdown toggle caret ────────────────────────────────────────────── */
.kaiba-navbar .dropdown-toggle::after {
    display: inline-block;
    margin-left: 5px;
    vertical-align: 2px;
    border-top: 4px solid currentColor;
    border-right: 4px solid transparent;
    border-left: 4px solid transparent;
    border-bottom: 0;
    transition: transform 0.25s ease;
    content: '';
}
.kaiba-navbar .dropdown.show > .dropdown-toggle::after { transform: rotate(180deg); }

/* ── Admin button ─────────────────────────────────────────────────────── */
.nav-admin-btn {
    color: rgba(0, 170, 255, 0.55) !important;
    padding: 4px 8px !important;
}
.nav-admin-btn:hover,
.nav-admin-btn.show { color: var(--kaiba-blue) !important; }
/* Pas de caret sur une icône seule */
.nav-admin-btn.dropdown-toggle::after { display: none !important; }
.nav-admin-btn .fa-cog {
    font-size: 1rem;
    transition: transform 0.5s ease;
}
.nav-admin-btn:hover .fa-cog,
.nav-admin-btn.show .fa-cog { transform: rotate(90deg); }

/* ── Collapse flex container — centrage vertical explicite ───────────── */
@media (min-width: 992px) {
    #navbarNav {
        align-items: center;
    }
}

/* ── Groupe droit : wrapper flex [search + nav-right] ────────────────── */
@media (min-width: 992px) {
    .nav-right-group {
        display: flex;
        align-items: center;
        align-self: center;
        flex-shrink: 0;
        gap: 0;
    }
}

/* ── Séparateur vertical avant les contrôles utilisateur ─────────────── */
.nav-right {
    gap: 2px;
}
@media (min-width: 992px) {
    .nav-right {
        border-left: 1px solid rgba(0, 170, 255, 0.15);
        padding-left: 12px;
        flex-shrink: 0;
    }
}

/* ── IKM subscription dot (navbar avatar) ────────────────────────────── */
.nav-user-avatar-wrap {
    position: relative;
    flex-shrink: 0;
    display: inline-flex;
}
.nav-abo-dot {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 9px;
    height: 9px;
    background: #00c864;
    border-radius: 50%;
    border: 1.5px solid rgba(0, 2, 6, 0.97);
    box-shadow: 0 0 6px rgba(0, 200, 100, 0.75);
    pointer-events: none;
}

/* ── IKM status card (profil page) ───────────────────────────────────── */
.ikm-status-card .ikm-status-icon {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 0.88rem;
}
.ikm-status-card.ikm-active  .ikm-status-icon {
    background: rgba(0, 200, 100, 0.1);
    border: 1px solid rgba(0, 200, 100, 0.35);
    color: #00c864;
}
.ikm-status-card.ikm-inactive .ikm-status-icon {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--kaiba-text-muted);
}

/* ── User avatar trigger ──────────────────────────────────────────────── */
.nav-user-trigger {
    display: flex !important;
    align-items: center;
    gap: 7px;
    padding: 4px 8px !important;
    border-radius: 6px;
    transition: background 0.2s !important;
}
.nav-user-trigger:hover { background: rgba(0, 170, 255, 0.07) !important; }

/* Masquer le caret Bootstrap — on a notre propre .nav-chevron */
.nav-user-trigger.dropdown-toggle::after { display: none !important; }

.nav-user-avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0077cc, #003a6e);
    border: 1.5px solid rgba(0, 170, 255, 0.55);
    box-shadow: 0 0 8px rgba(0, 170, 255, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.70rem;
    font-weight: 700;
    color: #fff;
    flex-shrink: 0;
    transition: box-shadow 0.25s, border-color 0.25s;
}
.nav-user-trigger:hover .nav-user-avatar {
    box-shadow: 0 0 14px rgba(0, 170, 255, 0.8);
    border-color: var(--kaiba-blue);
}

.nav-user-name {
    font-family: 'Exo 2', sans-serif;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--kaiba-text-light);
    max-width: 90px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.nav-chevron {
    font-size: 0.58rem;
    color: var(--kaiba-text-muted);
    transition: transform 0.25s ease;
    flex-shrink: 0;
}
.dropdown.show .nav-chevron { transform: rotate(180deg); }

/* ── Bouton Connexion ─────────────────────────────────────────────────── */
.nav-login-btn {
    border: 1px solid rgba(0, 170, 255, 0.4) !important;
    border-radius: 5px !important;
    padding: 5px 14px !important;
    color: var(--kaiba-blue) !important;
    transition: background 0.25s, border-color 0.25s, box-shadow 0.25s !important;
}
.nav-login-btn:hover {
    background: rgba(0, 170, 255, 0.10) !important;
    border-color: var(--kaiba-blue) !important;
    box-shadow: 0 0 10px rgba(0, 170, 255, 0.25) !important;
    color: var(--kaiba-blue) !important;
}
/* Pas d'underline dorée sur ce bouton */
.nav-login-btn::after { display: none !important; }

/* ── Dropdowns ────────────────────────────────────────────────────────── */
.kaiba-dropdown-menu {
    background: rgba(1, 6, 16, 0.97);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(0, 170, 255, 0.22);
    border-top: 2px solid rgba(0, 170, 255, 0.55);
    border-radius: 0 0 8px 8px;
    padding: 6px 0;
    min-width: 190px;
    max-width: calc(100vw - 24px);
    box-shadow:
        0 10px 40px rgba(0, 0, 0, 0.75),
        0 0 20px rgba(0, 170, 255, 0.10);
    /* Animation d'ouverture */
    animation: dropdownReveal 0.20s ease forwards;
}

@keyframes dropdownReveal {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}

.kaiba-dropdown-item {
    font-family: 'Exo 2', sans-serif;
    font-size: 0.80rem;
    font-weight: 500;
    letter-spacing: 0.2px;
    color: var(--kaiba-text-light) !important;
    padding: 9px 18px;
    position: relative;
    transition: background 0.15s, color 0.15s, padding-left 0.2s;
}
/* Barre latérale bleue au hover */
.kaiba-dropdown-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 55%;
    background: var(--kaiba-blue);
    border-radius: 0 2px 2px 0;
    transition: width 0.18s ease;
}
.kaiba-dropdown-item:hover {
    background: rgba(0, 170, 255, 0.07) !important;
    color: #fff !important;
    padding-left: 22px;
}
.kaiba-dropdown-item:hover::before { width: 3px; }

.kaiba-dropdown-item .fas,
.kaiba-dropdown-item .fab { opacity: 0.5; }

.kaiba-dropdown-item.active {
    background: rgba(0, 170, 255, 0.1) !important;
    color: var(--kaiba-gold) !important;
}

/* Déconnexion — rouge */
.kaiba-dropdown-item--danger { color: #f87171 !important; }
.kaiba-dropdown-item--danger:hover {
    background: rgba(248, 113, 113, 0.08) !important;
    color: #fca5a5 !important;
}
.kaiba-dropdown-item--danger::before { background: #f87171; }

.kaiba-divider { border-color: rgba(0, 170, 255, 0.12) !important; margin: 4px 0; }

/* En-tête de section dans les dropdowns */
.kaiba-dropdown-header {
    display: block;
    font-family: 'Exo 2', sans-serif;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(0, 170, 255, 0.45);
    padding: 8px 18px 4px;
    pointer-events: none;
    user-select: none;
}

/* Petite icône dans les nav-links desktop */
.nav-icon-sm { width: 1em; text-align: center; }

/* ── Hamburger CSS pur ────────────────────────────────────────────────── */
.nav-hamburger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 38px;
    height: 38px;
    padding: 8px;
    background: transparent;
    border: 1px solid rgba(0, 170, 255, 0.35);
    border-radius: 5px;
    cursor: pointer;
    flex-shrink: 0;
    transition: border-color 0.25s, box-shadow 0.25s;
}
.nav-hamburger:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 170, 255, 0.4);
}
.nav-hamburger:hover {
    border-color: var(--kaiba-blue);
    box-shadow: 0 0 10px rgba(0, 170, 255, 0.3);
}
.nav-hamburger span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--kaiba-blue);
    border-radius: 2px;
    transform-origin: center;
    transition: transform 0.3s ease, opacity 0.25s ease, width 0.3s ease;
}
/* Barre du milieu plus courte (asymétrique = détail expert) */
.nav-hamburger span:nth-child(2) { width: 65%; align-self: flex-end; }

/* État ouvert → croix */
.nav-hamburger[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}
.nav-hamburger[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}
.nav-hamburger[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* ── Recherche globale (navbar) ───────────────────────────────────────── */
.kaiba-navbar .nav-search-form {
    display: flex;
    align-items: center;
    margin-right: 0.5rem;
    flex-shrink: 0;
}
.kaiba-navbar .nav-search-input {
    background-color: var(--kaiba-input-bg);
    border: 1px solid var(--kaiba-input-border);
    color: var(--kaiba-input-text-color);
    border-radius: 20px 0 0 20px;
    padding: 0.35rem 0.9rem;
    font-size: 0.8rem;
    width: 160px;
    transition: width 0.25s ease, box-shadow 0.25s ease;
}
.kaiba-navbar .nav-search-input::placeholder {
    color: var(--kaiba-input-placeholder-color);
}
.kaiba-navbar .nav-search-input:focus {
    outline: none;
    border-color: var(--kaiba-input-focus-border);
    box-shadow: var(--kaiba-input-focus-shadow);
    width: 220px;
}
.kaiba-navbar .nav-search-btn {
    background-color: var(--kaiba-input-bg);
    border: 1px solid var(--kaiba-input-border);
    border-left: none;
    color: var(--kaiba-text-light);
    border-radius: 0 20px 20px 0;
    padding: 0.35rem 0.7rem;
    font-size: 0.8rem;
    cursor: pointer;
    transition: color 0.2s ease;
}
.kaiba-navbar .nav-search-btn:hover { color: var(--kaiba-gold); }

/* ── Mobile collapse panel ────────────────────────────────────────────── */
@media (max-width: 991.98px) {
    .kaiba-navbar .nav-search-form  { margin: 10px 20px; width: calc(100% - 40px); }
    .kaiba-navbar .nav-search-input,
    .kaiba-navbar .nav-search-input:focus { width: 100%; }

    .kaiba-navbar .brand-logo     { height: 34px; }
    .kaiba-navbar .logo-text      { font-size: 1.3rem; letter-spacing: 3px; }
    .brand-subtitle               { display: none; }

    .navbar-collapse {
        background: rgba(0, 3, 10, 0.97);
        backdrop-filter: blur(18px);
        border-top: 1px solid rgba(0, 170, 255, 0.18);
        padding-bottom: 16px;
        max-height: calc(100vh - 62px);
        overflow-y: auto;
    }

    /* Étiquettes de section dans le menu mobile */
    .mobile-nav-section-label {
        font-family: 'Exo 2', sans-serif;
        font-size: 0.58rem;
        font-weight: 700;
        letter-spacing: 2.5px;
        text-transform: uppercase;
        color: rgba(0, 170, 255, 0.4);
        padding: 14px 20px 5px;
    }

    .kaiba-navbar .nav-link {
        padding: 12px 20px;
        font-size: 0.84rem;
        border-bottom: 1px solid rgba(0, 170, 255, 0.06);
        border-radius: 0;
    }
    /* Pas d'underline dorée sur mobile */
    .kaiba-navbar .nav-link:not(.dropdown-toggle)::after { display: none; }

    /* Active sur mobile : barre gauche dorée */
    .kaiba-navbar .nav-link.active {
        background: rgba(0, 170, 255, 0.06) !important;
        border-left: 2px solid var(--kaiba-gold);
        padding-left: 18px;
    }

    /* Dropdown mobile : affichage inline, pas de popup */
    .kaiba-navbar .dropdown-menu {
        position: static !important;
        float: none;
        background: transparent;
        border: none;
        border-radius: 0;
        backdrop-filter: none;
        box-shadow: none;
        animation: none;
        padding: 0;
        min-width: auto;
    }
    .kaiba-dropdown-item {
        padding: 12px 28px 12px 36px;
        border-bottom: 1px solid rgba(0, 170, 255, 0.05);
        border-left: 2px solid rgba(0, 170, 255, 0.18);
    }
    .kaiba-dropdown-item::before    { display: none; }
    .kaiba-dropdown-item:hover      { padding-left: 36px; }

    /* User trigger sur mobile */
    .nav-user-trigger {
        padding: 12px 20px !important;
        border-radius: 0;
    }
    .nav-user-trigger:hover { background: transparent !important; }

    /* Supprimer le séparateur vertical sur mobile */
    .nav-right {
        border-left: none;
        padding-left: 0;
        margin-left: 0;
    }

    /* Bouton connexion */
    .nav-login-btn {
        border: none !important;
        border-radius: 0 !important;
        padding: 12px 20px !important;
        display: block;
    }
}


/* --- User Profile --- */
.profile-card {
    position: relative;
    background-color: var(--kaiba-dark-secondary);
    border: 2px solid var(--kaiba-blue);
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 170, 255, 0.3);
    color: var(--kaiba-text-light);
    margin-top: 90px; 
}

.profile-header {
    height: 150px;
    background-image: linear-gradient(45deg, var(--kaiba-dark-secondary) 0%, var(--kaiba-blue) 100%);
}

.profile-picture {
    position: absolute;
    top: 60px;
    left: 50%;
    transform: translateX(-50%);
    width: clamp(100px, 45vw, 180px);
    height: clamp(100px, 45vw, 180px);
    border-radius: 50%;
    border: 5px solid var(--kaiba-dark-primary);
    background-color: var(--kaiba-dark-primary);
    box-shadow: 0 0 20px var(--kaiba-blue-glow);
    padding: 5px;
}
.profile-picture img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.profile-body {
    padding: 100px 30px 30px 30px;
    text-align: center;
}

.profile-name {
    font-size: 2.5em;
    font-weight: 900;
    color: #ffffff;
}

.join-date {
    font-family: 'Exo 2', sans-serif;
    font-size: 0.9em;
    color: var(--kaiba-text-light);
    opacity: 0.6;
    margin-top: -10px;
}

.profile-stats {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-top: 20px;
}
.stat-item .stat-value {
    font-size: 2em;
    font-weight: bold;
    color: var(--kaiba-gold);
}
.stat-item .stat-label {
    display: block;
    font-size: 0.9em;
    text-transform: uppercase;
    color: var(--kaiba-text-light);
    opacity: 0.7;
}

.profile-divider {
    border-color: rgba(0, 170, 255, 0.3);
    margin: 30px auto;
    width: 80%;
}

.section-divider {
    border-color: rgba(0, 170, 255, 0.15);
    margin: 2.5rem 0;
}

.section-gap {
    margin-top: 3rem;
    margin-bottom: 3rem;
}

.profile-details {
    text-align: left;
    font-family: 'Exo 2', sans-serif;
    line-height: 1.8;
    margin: 20px 0;
}
.profile-details p {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 15px;
    border-bottom: 1px solid rgba(0, 170, 255, 0.1);
    padding-bottom: 10px;
    margin-bottom: 10px;
}
.profile-details p strong {
    font-family: 'Orbitron', sans-serif;
    color: var(--kaiba-blue);
    opacity: 0.8;
}

.profile-form-container {
    margin-top: 30px;
    text-align: left;
    background: rgba(0, 4, 8, 0.5);
    padding: 20px;
    border-radius: 10px;
    border: 1px solid rgba(0, 170, 255, 0.2);
}


/* --- Top Cut Bracket --- */
.top-cut-simple-container {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 20px;
    gap: 40px;
    overflow-x: auto;
    min-height: 200px;
}

.top-cut-simple-round {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    flex-shrink: 0;
    min-width: 250px;
}

.top-cut-simple-title {
    color: var(--kaiba-gold);
    font-family: 'Orbitron', sans-serif;
    font-size: 1.3rem;
    text-shadow: 0 0 5px var(--kaiba-gold-glow);
}

.top-cut-simple-matches {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
    align-items: center;
}

.top-cut-simple-match {
    display: flex;
    flex-direction: column;
    background-color: var(--kaiba-dark-secondary);
    border: 1px solid var(--kaiba-blue);
    border-radius: 5px;
    padding: 8px 12px;
    width: 100%;
    max-width: 220px;
    box-shadow: 0 0 8px rgba(0, 170, 255, 0.2);
    transition: all 0.2s ease-in-out;
}
.top-cut-simple-match:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 12px rgba(0, 170, 255, 0.4);
}

.top-cut-simple-player {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2px 0;
    font-family: 'Aldrich', sans-serif;
    font-size: 0.9rem;
}
.top-cut-simple-player.winner {
    color: var(--kaiba-gold);
    font-weight: bold;
    text-shadow: 0 0 3px rgba(255, 215, 0, 0.4);
}
.top-cut-simple-player input[type="number"] {
    width: 45px;
    padding: 2px 5px;
    margin-left: 10px;
    background-color: var(--kaiba-input-bg);
    border: 1px solid var(--kaiba-blue);
    color: var(--kaiba-text-light);
    text-align: center;
    border-radius: 3px;
}
.top-cut-simple-player input[type="number"]::-webkit-outer-spin-button,
.top-cut-simple-player input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

@media (max-width: 768px) {
    .top-cut-simple-container {
        flex-direction: column;
        align-items: center;
        gap: 30px;
    }
}



/* ==========================================================================
   04a. STANDINGS TABLE + PANTHEON TABLE
   Base commune partagée, puis modificateurs spécifiques.
   ========================================================================== */

/* ── Base partagée ───────────────────────────────────────────────────────── */
.standings-table,
.pantheon-table {
    border: 1px solid var(--kaiba-blue);
}
.standings-table thead th,
.pantheon-table thead th {
    font-family: 'Aldrich', sans-serif;
    color: var(--kaiba-blue);
    text-transform: uppercase;
}
.standings-table tbody td,
.pantheon-table tbody td {
    color: var(--kaiba-text-light);
    font-size: 1.1em;
}
.standings-table tbody th,
.pantheon-table tbody th {
    font-family: 'Aldrich', sans-serif;
    color: var(--kaiba-text-light);
    border-right: 1px solid rgba(0, 170, 255, 0.4);
}
.standings-table .player-cell,
.pantheon-table .player-cell {
    text-align: left;
    font-weight: bold;
}
.standings-table .player-cell a,
.pantheon-table .player-cell a {
    text-decoration: none;
}
.standings-table .player-cell-inner,
.pantheon-table .player-cell-inner {
    display: flex;
    align-items: center;
}
.standings-table .player-cell-inner > :not(img),
.pantheon-table .player-cell-inner > :not(img) {
    min-width: 0;
    overflow-wrap: break-word;
}

/* ── standings-table ─────────────────────────────────────────────────────── */
.standings-table {
    box-shadow: 0 0 20px rgba(0, 170, 255, 0.4);
    text-align: center;
}
.standings-table thead th {
    font-size: 1.1em;
    letter-spacing: 1px;
    text-shadow: 0 0 8px var(--kaiba-blue-glow);
}
.standings-table tbody td {
    font-family: 'Exo 2', sans-serif;
    font-weight: 500;
}
.standings-table .player-cell .list-profile-pic {
    width: 32px;
    height: 32px;
    border-width: 2px;
    margin-right: 12px;
    flex-shrink: 0;
}
.standings-table tbody th {
    font-size: 2.5em;
    font-weight: 900;
    width: 120px;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
    vertical-align: middle;
}

/* Podium Top 3 dans le tableau */
.standings-table tbody tr:first-child {
    background: linear-gradient(90deg, rgba(255, 215, 0, 0.15), rgba(255, 215, 0, 0.05) 50%, transparent 80%);
}
.standings-table tbody tr:first-child th {
    color: var(--kaiba-gold);
    text-shadow: 0 0 15px var(--kaiba-gold-glow);
}
.standings-table tbody tr:first-child .player-cell a { color: var(--kaiba-gold); }

.standings-table tbody tr:nth-child(2) {
    background: linear-gradient(90deg, rgba(192, 192, 192, 0.15), rgba(192, 192, 192, 0.05) 50%, transparent 80%);
}
.standings-table tbody tr:nth-child(2) th {
    color: var(--kaiba-silver);
    text-shadow: 0 0 15px rgba(192, 192, 192, 0.7);
}
.standings-table tbody tr:nth-child(2) .player-cell a { color: var(--kaiba-silver); }

.standings-table tbody tr:nth-child(3) {
    background: linear-gradient(90deg, rgba(205, 127, 50, 0.15), rgba(205, 127, 50, 0.05) 50%, transparent 80%);
}
.standings-table tbody tr:nth-child(3) th {
    color: var(--kaiba-bronze);
    text-shadow: 0 0 15px rgba(205, 127, 50, 0.6);
}
.standings-table tbody tr:nth-child(3) .player-cell a { color: var(--kaiba-bronze); }
/* ==========================================================================
   04b. USER PROFILE - AMÉLIORATIONS "WOUAAAH"
   ========================================================================== */

.profile-card {
    position: relative;
    background-color: transparent; 
    border: none; 
    box-shadow: none; 
    margin-top: 90px;
    padding: 0; 
}

.profile-card::before,
.profile-card::after {
    content: '';
    position: absolute;
    left: -2px;
    top: -2px;
    background: linear-gradient(45deg, var(--kaiba-gold), var(--kaiba-blue), #00ffc8, #7a00ff, var(--kaiba-blue), var(--kaiba-gold));
    background-size: 400%;
    width: calc(100% + 4px);
    height: calc(100% + 4px);
    z-index: -1;
    animation: holographic-glow 20s linear infinite;
    border-radius: 15px;
}
.profile-card::after {
    filter: blur(20px); 
}

.profile-body {
    background: linear-gradient(145deg, var(--kaiba-dark-primary), var(--kaiba-dark-secondary));
    border-radius: 15px;
    padding: 100px 30px 30px 30px;
    text-align: center;
}

.profile-picture {
    width: clamp(100px, 45vw, 180px);
    height: clamp(100px, 45vw, 180px);
    border: 5px solid var(--kaiba-dark-primary);
    box-shadow:
        0 0 15px 5px rgba(255, 255, 255, 0.2),
        0 0 35px 10px var(--kaiba-blue-glow);
}
.profile-picture img {
    border: 3px solid var(--kaiba-blue); 
}

.stat-item .stat-value {
    font-family: 'Aldrich', sans-serif;
    font-size: 3em; 
    text-shadow: 0 0 15px var(--kaiba-gold-glow);
}
.stat-item .stat-label {
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 1px;
}

.profile-divider {
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--kaiba-blue), transparent);
    border: 0;
    opacity: 0.8;
}

.list-group-item.kaiba-list-item-tournament {
    background-color: rgba(0, 4, 8, 0.7);
    border-color: rgba(0, 170, 255, 0.2);
    transition: all 0.3s ease;
    padding: 1rem 1.5rem;
}
.list-group-item.kaiba-list-item-tournament:hover {
    background-color: rgba(0, 170, 255, 0.1);
    border-color: var(--kaiba-blue);
    transform: translateX(5px); 
}
.list-group-item.kaiba-list-item-tournament strong {
    font-family: 'Aldrich', sans-serif;
    font-size: 1.1em;
    color: #fff;
}
.badge.kaiba-badge-gold {
    background: linear-gradient(45deg, var(--kaiba-gold), #ffec80);
    color: #000;
    font-size: 1em;
    font-weight: bold;
    border: 1px solid var(--kaiba-gold);
    box-shadow: 0 0 10px var(--kaiba-gold-glow);
}
.badge-champion-saison {
    background: linear-gradient(135deg, #b8750a 0%, var(--kaiba-gold) 45%, #f5d87a 65%, #b8750a 100%);
    color: #000;
    font-size: 0.8em;
    font-weight: bold;
    padding: 0.4em 0.8em;
    border-radius: 0.35rem;
    border: 1px solid var(--kaiba-gold);
    box-shadow: 0 0 12px var(--kaiba-gold-glow), 0 2px 6px rgba(0,0,0,0.4);
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

@keyframes holographic-glow {
    0% { background-position: 0 0; }
    50% { background-position: 400% 0; }
    100% { background-position: 0 0; }
}
/* ==========================================================================
   04c. PANTHEON TABLE — modificateurs spécifiques (base dans 04a)
   ========================================================================== */

.pantheon-table {
    max-width: 800px;
    margin: 30px auto;
    box-shadow: 0 0 20px rgba(0, 170, 255, 0.3);
}
.pantheon-table thead th {
    text-align: center;
}
.pantheon-table tbody th {
    font-size: 1.8em;
    font-weight: 700;
    text-align: center;
}
.pantheon-table .player-cell a {
    color: #fff;
}
.pantheon-table .player-cell a:hover {
    color: var(--kaiba-gold);
}
.pantheon-table .list-profile-pic {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 15px;
    border: 2px solid var(--kaiba-blue);
    box-shadow: 0 0 8px rgba(0, 123, 255, 0.5);
    vertical-align: middle;
    flex-shrink: 0;
}
.pantheon-table .points-cell {
    font-family: 'Aldrich', sans-serif;
    font-size: 1.3em;
    font-weight: bold;
    color: var(--kaiba-gold);
    text-shadow: 0 0 8px var(--kaiba-gold-glow);
    text-align: center;
}
/* ==========================================================================
   04d. FINANCE PAGES
   ========================================================================== */

.finance-summary-card .stat-label {
    font-family: 'Orbitron', sans-serif;
    text-transform: uppercase;
    color: var(--kaiba-text-muted);
}
.finance-summary-card .stat-value {
    font-family: 'Aldrich', sans-serif;
    font-weight: 900;
}

.debit-cell, .credit-cell {
    font-family: 'Aldrich', sans-serif;
    font-weight: bold;
    font-size: 1.1em;
}
/* ==========================================================================
   04e. DASHBOARD HOME PAGE
   ========================================================================== */
.dashboard-hero {
    /* L'URL de fond est injectée via --hero-bg-url depuis le template Django
       ({% static %} ne fonctionne pas dans les fichiers CSS statiques) */
    background-color: rgba(10, 14, 20, 0.95);
    background-image: linear-gradient(rgba(10, 14, 20, 0.8), rgba(10, 14, 20, 0.8)),
                      var(--hero-bg-url, none);
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
    border: 1px solid var(--kaiba-gold);
    position: relative;
    overflow: hidden;
    /* backdrop-filter hérité de .kaiba-card désactivé — le fond est opaque */
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}

/* ── Duel Field SVG Rings ─────────────────────────────────── */
#duelFieldRings {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    overflow: visible;
    /* Un seul drop-shadow CSS sur le SVG entier — GPU-composité,
       remplace les 3 feGaussianBlur SVG qui étaient rendus sur le CPU */
    filter: drop-shadow(0 0 4px rgba(0, 170, 255, 0.38))
            drop-shadow(0 0 10px rgba(0, 170, 255, 0.14));
}

/* Chaque <g> tourne — transform-box + transform-origin pour SVG */
.rf-group {
    transform-box: fill-box;
    transform-origin: center;
    will-change: transform; /* préalloue une couche GPU */
}

.rf-group-1 { animation: rfRotate 24s linear infinite; }
.rf-group-2 { animation: rfRotate 17s linear infinite reverse; }
.rf-group-3 { animation: rfRotate 11s linear infinite; }

/* Chaque <circle> fait couler les tirets indépendamment de la rotation */
.rf-ring-1 { animation: rfFlow1 15s linear infinite; }
.rf-ring-2 { animation: rfFlow2 10s linear infinite reverse; }
.rf-ring-3 { animation: rfFlow3  6s linear infinite; }

/* Centre pulsant */
.rf-pulse {
    transform-box: fill-box;
    transform-origin: center;
    animation: rfPulse 3.5s ease-in-out infinite;
}

/* Rotation commune (durée définie par .rf-group-N) */
@keyframes rfRotate {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

/* Flux des tirets — valeurs = circonférence de chaque anneau (2πr) */
@keyframes rfFlow1 {   /* r=44 → C≈276.5 */
    from { stroke-dashoffset: 0; }
    to   { stroke-dashoffset: -276.5; }
}
@keyframes rfFlow2 {   /* r=35 → C≈219.9 */
    from { stroke-dashoffset: 0; }
    to   { stroke-dashoffset: 219.9; }
}
@keyframes rfFlow3 {   /* r=24 → C≈150.8 */
    from { stroke-dashoffset: 0; }
    to   { stroke-dashoffset: -150.8; }
}

@keyframes rfPulse {
    0%, 100% { opacity: 0.06; transform: scale(1);    }
    50%      { opacity: 0.28; transform: scale(1.20); }
}

.dashboard-hero .card-body {
    position: relative;
    z-index: 2;
}

.tournament-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.9rem;
    border-radius: 20px;
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--kaiba-text-light);
}

.tournament-badge-tier {
    border-color: rgba(0, 170, 255, 0.4);
    color: var(--kaiba-blue);
}

.tournament-badge-fee {
    border-color: rgba(255, 215, 0, 0.4);
    color: var(--kaiba-gold);
}

#countdown {
    font-family: 'Aldrich', sans-serif;
    font-size: 2.5em;
    font-weight: 700;
    letter-spacing: 5px;
    color: var(--kaiba-gold);
    text-shadow: 0 0 15px var(--kaiba-gold-glow);
}
#countdown span {
    display: inline-block;
    padding: 0 10px;
}

/* ── Animation 3 : Holographic Card Borders (CSS @property) ── */

/*
 * @property permet d'animer --holo-angle comme un vrai <angle>.
 * Sans cette déclaration, le browser traite la custom property comme
 * une string et saute d'une valeur à l'autre sans interpolation.
 */
@property --holo-angle {
    syntax: '<angle>';
    inherits: false;
    initial-value: 0deg;
}

.top-player-card {
    padding: 15px;
    position: relative;
    border-radius: 12px;
    border: 2px solid transparent;
    /*
     * Deux couches de background :
     *  1. padding-box  → remplit l'intérieur de la carte (fond sombre)
     *  2. border-box   → remplit border + padding + content
     * Le conic-gradient n'est visible que dans la zone du border (2px).
     */
    background:
        linear-gradient(#09111f, #0d1529) padding-box,
        conic-gradient(
            from var(--holo-angle),
            #ff0080  0%,
            #ff8c00 14%,
            #ffd700 28%,
            #00ff88 42%,
            #00aaff 57%,
            #8b5cf6 71%,
            #ff0080 85%,
            #ff0080 100%
        ) border-box;
    animation: holoAngle 4s linear infinite;
    overflow: hidden;
    transition: box-shadow 0.35s ease;
}

.top-player-card:hover {
    box-shadow:
        0 0 22px rgba(0, 170, 255, 0.30),
        0 0 50px rgba(0, 170, 255, 0.12);
}

/* Balayage lumineux — imite la lumière qui glisse sur une carte holographique */
.top-player-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(
        108deg,
        transparent 36%,
        rgba(255, 255, 255, 0.06) 50%,
        transparent 64%
    );
    background-size: 280% 100%;
    animation: holoShimmer 5s ease-in-out infinite;
    animation-delay: var(--shimmer-delay, 0s);
    pointer-events: none;
}

@keyframes holoAngle {
    to { --holo-angle: 360deg; }
}

@keyframes holoShimmer {
    0%   { background-position: -100% center; }
    100% { background-position: 260% center; }
}

/* ── Animation 5 — 3D Magnetic Card Tilt ───────────────────────────────────
 * Technique :
 *   - perspective() dans le transform JS (pas la propriété CSS perspective)
 *     → chaque carte a son propre point de fuite, pas besoin de toucher le DOM
 *   - Spring physics JS : force = stiffness × (target − current)
 *     → retour organique sans transition CSS qui entrerait en conflit
 *   - will-change: transform → GPU layer dès le chargement
 *   - ::before avec radial-gradient dynamique via --mouse-x / --mouse-y
 *     (custom properties mises à jour en JS, opacity gérée par :hover CSS)
 *   - Désactivé sur tactile (hover: none media query)
 * ────────────────────────────────────────────────────────────────────────── */

/* hint GPU layer pour les transforms JS */
.top-player-card { will-change: transform; }

/* Highlight lumineux elliptique qui suit le curseur */
.top-player-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    background: radial-gradient(
        ellipse 90px 70px at var(--mouse-x, 50%) var(--mouse-y, 50%),
        rgba(255, 255, 255, 0.20) 0%,
        rgba(255, 255, 255, 0.06) 40%,
        transparent 70%
    );
    opacity: 0;
    transition: opacity 0.25s ease;
    z-index: 1;
}

.top-player-card:hover::before { opacity: 1; }

/* Aucun tilt ni highlight sur les appareils tactiles */
@media (hover: none) {
    .top-player-card { will-change: auto; }
    .top-player-card::before { display: none; }
}

/* ── Animation 4 — Glitch Text Effect ──────────────────────────────────────
 * Technique :
 *   - 2 pseudo-éléments (::before ::after) avec content: attr(data-text)
 *     → copie du texte sans JS
 *   - clip-path: polygon() animé → tranche horizontale aléatoire (artefact VHS)
 *   - animation-play-state: paused/running contrôlé par JS (pas animation:none
 *     qui causerait un flash en resettant l'animation)
 *   - Canaux rouge + cyan décalés → aberration chromatique
 * ────────────────────────────────────────────────────────────────────────── */
.glitch-title {
    position: relative;
    hyphens: none;
    word-break: normal;
    overflow-wrap: normal;
}
@media (max-width: 575px) {
    .glitch-title { font-size: 1.4rem !important; }
}
@media (max-width: 350px) {
    .glitch-title { font-size: 1.15rem !important; }
}

.glitch-title::before,
.glitch-title::after {
    content: attr(data-text);
    position: absolute;
    inset: 0;
    pointer-events: none;
    text-shadow: none;
    /* Invisible par défaut : polygon de hauteur zéro */
    clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
    animation-fill-mode: both;
    animation-play-state: paused;
}

/* Canal rouge — décalé vers la gauche */
.glitch-title::before {
    color: #ff2d55;
    animation: glitchRed 0.4s linear infinite;
    animation-play-state: paused;
}

/* Canal cyan — décalé vers la droite */
.glitch-title::after {
    color: #00d4ff;
    animation: glitchCyan 0.4s linear infinite;
    animation-play-state: paused;
}

/* JS ajoute .is-glitching pendant 400 ms toutes les 6 s */
.glitch-title.is-glitching::before { animation-play-state: running; }
.glitch-title.is-glitching::after  { animation-play-state: running; }

@keyframes glitchRed {
    0%   { clip-path: polygon(0 0,   100% 0,   100% 0,   0 0);   transform: translateX(0);    }
    6%   { clip-path: polygon(0 8%,  100% 8%,  100% 20%, 0 20%); transform: translateX(-4px); }
    16%  { clip-path: polygon(0 55%, 100% 55%, 100% 70%, 0 70%); transform: translateX(4px);  }
    26%  { clip-path: polygon(0 28%, 100% 28%, 100% 41%, 0 41%); transform: translateX(-3px); }
    36%  { clip-path: polygon(0 72%, 100% 72%, 100% 85%, 0 85%); transform: translateX(5px);  }
    46%  { clip-path: polygon(0 15%, 100% 15%, 100% 28%, 0 28%); transform: translateX(-4px); }
    56%  { clip-path: polygon(0 42%, 100% 42%, 100% 55%, 0 55%); transform: translateX(3px);  }
    66%  { clip-path: polygon(0 80%, 100% 80%, 100% 92%, 0 92%); transform: translateX(-5px); }
    76%  { clip-path: polygon(0 35%, 100% 35%, 100% 48%, 0 48%); transform: translateX(4px);  }
    86%  { clip-path: polygon(0 62%, 100% 62%, 100% 74%, 0 74%); transform: translateX(-2px); }
    96%  { clip-path: polygon(0 5%,  100% 5%,  100% 17%, 0 17%); transform: translateX(3px);  }
    100% { clip-path: polygon(0 0,   100% 0,   100% 0,   0 0);   transform: translateX(0);    }
}

@keyframes glitchCyan {
    0%   { clip-path: polygon(0 0,   100% 0,   100% 0,   0 0);   transform: translateX(0);    }
    6%   { clip-path: polygon(0 62%, 100% 62%, 100% 76%, 0 76%); transform: translateX(4px);  }
    16%  { clip-path: polygon(0 20%, 100% 20%, 100% 33%, 0 33%); transform: translateX(-4px); }
    26%  { clip-path: polygon(0 45%, 100% 45%, 100% 58%, 0 58%); transform: translateX(3px);  }
    36%  { clip-path: polygon(0 8%,  100% 8%,  100% 22%, 0 22%); transform: translateX(-5px); }
    46%  { clip-path: polygon(0 75%, 100% 75%, 100% 88%, 0 88%); transform: translateX(4px);  }
    56%  { clip-path: polygon(0 32%, 100% 32%, 100% 45%, 0 45%); transform: translateX(-3px); }
    66%  { clip-path: polygon(0 52%, 100% 52%, 100% 65%, 0 65%); transform: translateX(5px);  }
    76%  { clip-path: polygon(0 18%, 100% 18%, 100% 30%, 0 30%); transform: translateX(-4px); }
    86%  { clip-path: polygon(0 85%, 100% 85%, 100% 97%, 0 97%); transform: translateX(2px);  }
    96%  { clip-path: polygon(0 40%, 100% 40%, 100% 52%, 0 52%); transform: translateX(-3px); }
    100% { clip-path: polygon(0 0,   100% 0,   100% 0,   0 0);   transform: translateX(0);    }
}

/* ── Animation 6 — Scroll-Driven Section Reveals ───────────────────────────
 * Technique :
 *   - CSS animation-timeline: view() (Chrome/Edge 115+) — l'animation est
 *     pilotée par la progression du scroll, pas par le temps.
 *     animation-range: entry 0% entry 50% → ne joue que lors de l'entrée
 *     dans le viewport (pas pendant tout le scroll)
 *   - Fallback IntersectionObserver pour Firefox / Safari sans support.
 *     JS ajoute .is-revealed → CSS transition prend le relai.
 *   - overflow-x: clip sur le conteneur parent → évite un scrollbar horizontal
 *     pendant le translateX, sans créer de BFC (contrairement à overflow: hidden)
 * ────────────────────────────────────────────────────────────────────────── */

/* Clip le débordement horizontal du translateX sans affecter la mise en page */
.scroll-anim-wrap { overflow-x: clip; }

/* ── Fallback : browsers sans animation-timeline (Firefox, Safari < 18) ── */
@supports not (animation-timeline: view()) {
    .scroll-reveal-left,
    .scroll-reveal-right {
        opacity: 0;
        transition:
            opacity  0.65s ease,
            transform 0.65s cubic-bezier(0.22, 1, 0.36, 1);
    }
    .scroll-reveal-left  { transform: translateX(-45px); }
    .scroll-reveal-right { transform: translateX(45px);  }

    .scroll-reveal-left.is-revealed,
    .scroll-reveal-right.is-revealed {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ── Natif scroll-driven (Chrome/Edge 115+) ── */
@supports (animation-timeline: view()) {
    .scroll-reveal-left {
        animation: revealFromLeft linear both;
        animation-timeline: view();
        animation-range: entry 0% entry 50%;
    }
    .scroll-reveal-right {
        animation: revealFromRight linear both;
        animation-timeline: view();
        animation-range: entry 0% entry 50%;
    }
}

@keyframes revealFromLeft {
    from { opacity: 0; transform: translateX(-45px); }
    to   { opacity: 1; transform: translateX(0);     }
}

@keyframes revealFromRight {
    from { opacity: 0; transform: translateX(45px); }
    to   { opacity: 1; transform: translateX(0);    }
}

/* ── Accessibilité : désactive toutes les animations du hero ── */
@media (prefers-reduced-motion: reduce) {
    .rf-group-1, .rf-group-2, .rf-group-3,
    .rf-ring-1,  .rf-ring-2,  .rf-ring-3,
    .rf-pulse {
        animation: none;
    }
    .glitch-title::before,
    .glitch-title::after {
        display: none;
    }
    .scroll-reveal-left,
    .scroll-reveal-right {
        opacity: 1 !important;
        transform: none !important;
        animation: none !important;
    }
}

.top-player-rank {
    font-family: 'Aldrich', sans-serif;
    font-size: 2.5em;
    font-weight: 900;
    margin-bottom: -15px;
}
.top-player-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    border: 4px solid;
    object-fit: cover;
    margin-bottom: 10px;
}
.top-player-name a {
    font-family: 'Aldrich', sans-serif;
    font-size: 1.2em;
    color: #fff;
    text-decoration: none;
}
.top-player-name a:hover {
    color: var(--kaiba-gold);
}
.top-player-points {
    font-family: 'Orbitron', sans-serif;
    color: var(--kaiba-text-muted);
}

.rank-1, .rank-badge.rank-1 { color: var(--kaiba-gold); border-color: var(--kaiba-gold); }
.rank-2, .rank-badge.rank-2 { color: var(--kaiba-silver); border-color: var(--kaiba-silver); }
.rank-3, .rank-badge.rank-3 { color: var(--kaiba-bronze); border-color: var(--kaiba-bronze); }
.rank-4 { color: var(--kaiba-blue); }

.rank-badge {
    display: inline-block;
    width: 28px;
    height: 28px;
    line-height: 24px;
    text-align: center;
    border-radius: 50%;
    font-weight: bold;
    font-family: 'Aldrich', sans-serif;
    border: 2px solid;
    margin-right: 10px;
}

.kpi-card {
    text-align: center;
    padding: 10px 0;
}
.kpi-value {
    font-family: 'Aldrich', sans-serif;
    font-size: 2.2em;
    font-weight: 700;
    color: #fff;
}
.kpi-label {
    font-family: 'Orbitron', sans-serif;
    text-transform: uppercase;
    font-size: 0.9em;
    color: var(--kaiba-text-muted);
}
/* ==========================================================================
   04f. PODIUM FINAL (AVEC AVATARS INTÉGRÉS)
   ========================================================================== */

.podium-container {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    margin: 60px auto 80px auto;
    height: 320px;
    position: relative;
    max-width: 900px;
}

.podium-step {
    position: relative;
    width: 33.3%;
    text-align: center;
    color: white;
    animation: fadeInSlideUp 1s ease-out forwards;
    opacity: 0;
    transform-style: preserve-3d;
    
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 10px;
}

.podium-step::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 10%;
    width: 80%;
    height: 100%;
    background: linear-gradient(rgba(1, 10, 20, 0.9), rgba(8, 33, 62, 0.9));
    border: 2px solid;
    transform: skewY(-5deg);
    transform-origin: bottom left;
    border-radius: 8px;
    z-index: -1;
}

.podium-step::after {
    content: '';
    position: absolute;
    top: -2px;
    left: 10%;
    width: 80%;
    height: 5px;
    filter: blur(5px);
    border-radius: 5px;
}

.podium-rank {
    font-size: 4em;
    font-weight: 900;
    line-height: 1;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
    margin-bottom: 10px; 
}

.podium-avatar {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 15px; 
    border: 4px solid;
    z-index: 2; 
}

.podium-player {
    font-size: 1.6em;
    font-weight: bold;
    word-wrap: break-word;
    text-decoration: none;
    color: #fff;
}
.podium-player:hover {
    color: var(--kaiba-gold);
}

.podium-points {
    font-size: 1.1em;
    color: var(--kaiba-text-light);
    opacity: 0.8;
}

.podium-step.gold { height: 300px; animation-delay: 0.4s; order: 2; }
.podium-step.gold::before {
    border-color: var(--kaiba-gold);
    box-shadow: 0 0 40px var(--kaiba-gold-glow), inset 0 0 20px rgba(255, 215, 0, 0.08);
}
.podium-step.gold::after {
    background: var(--kaiba-gold);
    box-shadow: 0 0 30px var(--kaiba-gold), 0 0 60px var(--kaiba-gold-glow);
}
.podium-step.gold .podium-rank {
    color: var(--kaiba-gold);
    text-shadow: 0 0 20px var(--kaiba-gold-glow), 0 0 40px rgba(255, 215, 0, 0.3);
}
.podium-step.gold .podium-avatar {
    border-color: var(--kaiba-gold);
    box-shadow: 0 0 20px var(--kaiba-gold-glow), 0 0 40px rgba(255, 215, 0, 0.2);
}

.podium-step.silver { height: 250px; animation-delay: 0.2s; order: 1; }
.podium-step.silver::before { border-color: var(--kaiba-silver); }
.podium-step.silver::after { background: var(--kaiba-silver); box-shadow: 0 0 20px var(--kaiba-silver); }
.podium-step.silver .podium-rank { color: var(--kaiba-silver); }
.podium-step.silver .podium-avatar { border-color: var(--kaiba-silver); }

.podium-step.bronze { height: 200px; animation-delay: 0.6s; order: 3; }
.podium-step.bronze::before { border-color: var(--kaiba-bronze); }
.podium-step.bronze::after { background: var(--kaiba-bronze); box-shadow: 0 0 20px var(--kaiba-bronze); }
.podium-step.bronze .podium-rank { color: var(--kaiba-bronze); }
.podium-step.bronze .podium-avatar { border-color: var(--kaiba-bronze); }

/* ==========================================================================
   04g. TOURNAMENT LIST CARDS
   ========================================================================== */

.tournament-card {
    display: flex;
    flex-direction: column; 
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.tournament-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 170, 255, 0.5);
}

.tournament-card.is-completed {
    opacity: 0.8; 
}

.tournament-card-header .card-title a {
    color: #fff;
    text-decoration: none;
    transition: color 0.3s ease;
}
.tournament-card-header .card-title a:hover {
    color: var(--kaiba-gold);
}

.tournament-card-details p {
    margin-bottom: 0.75rem;
    font-family: 'Exo 2', sans-serif;
    color: var(--kaiba-text-light);
}
.tournament-card-details p i {
    color: var(--kaiba-blue);
    width: 20px; 
}
.tournament-card-details p strong {
    color: var(--kaiba-text-light);
    opacity: 0.8;
}

.tournament-card .card-body {
    flex-grow: 1;
}

.tournament-card .card-footer {
    background-color: rgba(8, 33, 62, 0.5);
    border-top: 1px solid rgba(0, 170, 255, 0.2);
}

.tier-badge {
    font-size: 0.9em;
    padding: 0.5em 0.75em;
    color: #000;
}
.tier-badge.tier-major { background-color: var(--kaiba-gold); color: #000; }
/* ==========================================================================
   04h. TOURNAMENT DETAIL PAGE
   ========================================================================== */

.tournament-header-card h1 {
    text-shadow: 0 0 15px var(--kaiba-gold-glow);
    color: var(--kaiba-gold);
}

.tournament-meta-details {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 30px; 
    font-family: 'Exo 2', sans-serif;
    color: var(--kaiba-text-light);
    margin-top: 15px;
}
.tournament-meta-details i {
    color: var(--kaiba-blue);
}

.status-badge {
    font-size: 1em;
    padding: 0.6em 0.9em;
    color: #fff;
}
.status-badge.status-upcoming { background-color: #0d6efd; } 
.status-badge.status-in_progress { background-color: #ffc107; color: #000; } 
.status-badge.status-completed { background-color: #198754; } 

/* Style pour les onglets */
.kaiba-nav-tabs .nav-link {
    background-color: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    color: var(--kaiba-text-muted);
    font-family: 'Aldrich', sans-serif;
    text-transform: uppercase;
}
.kaiba-nav-tabs .nav-link.active,
.kaiba-nav-tabs .nav-link:hover {
    color: var(--kaiba-blue);
    border-bottom: 3px solid var(--kaiba-blue);
    /* Bootstrap met un fond blanc par défaut sur l'onglet actif — jamais
       surchargé jusqu'ici, ce qui rendait le texte bleu illisible (2.56:1). */
    background-color: transparent;
}
/* ==========================================================================
   04i. TOURNAMENT MANAGE PAGE ACCORDION
   ========================================================================== */

.kaiba-accordion .accordion-item {
    background-color: rgba(1, 10, 20, 0.75);
    border: 1px solid rgba(0, 170, 255, 0.4);
    margin-bottom: 1rem;
    border-radius: 8px;
}

.kaiba-accordion .accordion-header {
    border-bottom: 1px solid rgba(0, 170, 255, 0.2);
}

.kaiba-accordion .accordion-button {
    background-color: transparent;
    color: var(--kaiba-text-light);
    font-family: 'Aldrich', sans-serif;
    font-size: 1.2em;
    box-shadow: none;
}

.kaiba-accordion .accordion-button:not(.collapsed) {
    color: var(--kaiba-gold);
    background-color: rgba(0, 170, 255, 0.1);
    box-shadow: inset 0 -2px 0 var(--kaiba-gold);
}

.kaiba-accordion .accordion-button:focus {
    box-shadow: 0 0 10px var(--kaiba-blue-glow);
}

.kaiba-accordion .accordion-body {
    background-color: var(--kaiba-dark-secondary);
    border-radius: 0 0 8px 8px;
}
/* ==========================================================================
   04j. OBJECTIVE WCQ PAGE
   ========================================================================== */
.wcq-progress-bar {
    background-color: var(--kaiba-dark-secondary);
    border: 1px solid var(--kaiba-blue);
    padding: 4px;
    border-radius: 8px;
}
.wcq-progress-bar .progress-bar {
    background: linear-gradient(45deg, var(--kaiba-blue), var(--kaiba-gold));
    font-size: 1.1em;
    font-family: 'Aldrich', sans-serif;
}
/* ==========================================================================
   04k. CHAMPIONS GALLERY
   ========================================================================== */

.champion-card-link {
    text-decoration: none;
    display: block;
    height: 100%;
}

.champion-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.champion-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 10px 40px var(--kaiba-blue-glow);
}

.champion-card-img-container {
    height: 300px;
    background-color: var(--kaiba-dark-secondary);
}

.champion-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover; 
}
.champion-card-img.is-avatar {
    object-fit: contain; 
    padding: 1rem;
}

.champion-card-img-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Aldrich', sans-serif;
    font-size: 3rem;
    color: var(--kaiba-blue);
    opacity: 0.65; /* 0.5 tombait sous le contraste minimum (grand texte, 3:1) */
}

.champion-card .card-body {
    text-align: center;
}

.champion-card .tournament-name {
    color: #fff;
    font-family: 'Aldrich', sans-serif;
}

.champion-card .card-footer {
    display: flex;
    align-items: center;
    background-color: rgba(8, 33, 62, 0.7);
    border-top: 1px solid rgba(0, 170, 255, 0.2);
}

.champion-card .winner-name {
    color: var(--kaiba-text-light);
    font-weight: bold;
}

.champion-card .deck-name {
    color: var(--kaiba-text-muted);
    font-size: 0.9em;
}
/* ── IKM ticket buttons & badges (tournament_manage.html) ── */
.btn-abo-abonne {
    background: rgba(0,170,255,.12);
    color: #00aaff;
    border: 1px solid rgba(0,170,255,.3);
    font-size: .72rem;
    padding: .2rem .5rem;
    white-space: nowrap;
}
.btn-abo-abonne:hover { background: rgba(0,170,255,.22); color: #fff; }
.btn-abo-visiteur {
    background: rgba(240,165,0,.08);
    color: #f0a500;
    border: 1px solid rgba(240,165,0,.25);
    font-size: .72rem;
    padding: .2rem .5rem;
    white-space: nowrap;
}
.btn-abo-visiteur:hover { background: rgba(240,165,0,.2); color: #fff; }
.badge-abo-abonne { background: rgba(0,170,255,.15); color: #00aaff; font-size: .75rem; }
.badge-abo-visiteur { background: rgba(240,165,0,.15); color: #f0a500; font-size: .75rem; }
.label-abonne { font-size: .7rem; color: #00aaff; }

/* ==========================================================================
   PROFILE PAGE - PALMARES
   ========================================================================== */

.rank-badge-lg {
    display: inline-block;
    min-width: 40px;
    padding: 5px 10px;
    font-size: 1.2em;
    font-weight: bold;
    font-family: 'Aldrich', sans-serif;
    text-align: center;
    border-radius: 8px;
    border: 2px solid;
    color: var(--kaiba-text-light);
    border-color: var(--kaiba-blue);
}

.rank-badge-lg.rank-gold {
    color: var(--kaiba-gold);
    border-color: var(--kaiba-gold);
    box-shadow: 0 0 10px var(--kaiba-gold-glow);
}
.rank-badge-lg.rank-silver {
    color: var(--kaiba-silver);
    border-color: var(--kaiba-silver);
    box-shadow: 0 0 8px rgba(192, 192, 192, 0.7);
}
.rank-badge-lg.rank-bronze {
    color: var(--kaiba-bronze);
    border-color: var(--kaiba-bronze);
    box-shadow: 0 0 8px rgba(205, 127, 50, 0.6);
}
/* ==========================================================================
   PANTHEON - CORRECTION FINALE TAILLE TEXTE PODIUM
   ========================================================================== */

.podium-step.silver .podium-player,
.podium-step.bronze .podium-player {
    font-size: 1.1em; 
    line-height: 1.2; 
    word-wrap: break-word; 
}

.podium-step.silver .podium-rank,
.podium-step.bronze .podium-rank {
    font-size: 3.5em;
}

.podium-step.silver .podium-points,
.podium-step.bronze .podium-points {
    font-size: 0.9em;
}
/* ==========================================================================
   PANTHEON - AJUSTEMENT FINAL PODIUM BRONZE (TAILLE)
   ========================================================================== */

.podium-step.bronze .podium-rank {
    font-size: 2.1em; 
    margin-bottom: 5px;
}

.podium-step.bronze .podium-avatar {
    width: 70px; 
    height: 70px;
    border-width: 3px;
    margin-bottom: 10px;
}

.podium-step.bronze .podium-player {
    font-size: 1em; 
}

.podium-step.bronze .podium-points {
    font-size: 0.9em;
}
.table > tbody > tr > th {
    color: #e9ecef; 
    font-weight: normal; 
}
/* ============================================= */
/* --- STYLE AVANCÉ POUR LE GRAPHIQUE METAGAME --- */
/* ============================================= */

#metagameChart-container {
    position: relative;
}

#metagameChart {
    filter: drop-shadow(0 0 10px rgba(0, 150, 255, 0.3));
    transition: filter 0.3s ease-in-out;
}

#metagameChart:hover {
    filter: drop-shadow(0 0 20px rgba(0, 150, 255, 0.6));
}

/* --- Pagination Kaiba Corp --- */
.kaiba-pagination .page-item .kaiba-link {
    background-color: var(--kaiba-dark-secondary);
    border: 1px solid var(--kaiba-blue);
    color: var(--kaiba-text-light);
    transition: all 0.2s;
}

.kaiba-pagination .page-item.disabled .kaiba-link {
    opacity: 0.5;
}

.kaiba-pagination .page-item .kaiba-link:hover {
    background-color: rgba(0, 170, 255, 0.1);
    color: var(--kaiba-gold);
    box-shadow: 0 0 5px var(--kaiba-blue-glow);
}

.kaiba-pagination .page-item .kaiba-active-link {
    background-color: var(--kaiba-blue);
    border-color: var(--kaiba-blue);
    color: var(--kaiba-dark-primary); 
    font-weight: bold;
}
/* ============================================= */
/* === NOUVEAU STYLE POUR LE CAMEMBERT METAGAME === */
/* ============================================= */

.pie-chart-container {
    width: 350px;
    height: 350px;
    position: relative;
    border-radius: 50%;
    background: conic-gradient(
        from 0deg,
        #00BCD4, #FF9800, #8BC34A, #FFC107, #9C27B0, #03A9F4, #E91E63, #00BCD4
    );
    overflow: hidden;
    border: 3px solid #182138;
    flex-shrink: 0;
}


/* Astuce pour les parts de plus de 180 degrés */
.pie-slice[style*="--angle: calc(180"] { /* un peu hacky mais fonctionne */
    clip-path: polygon(0 50%, 50% 50%, 50% 0, 100% 0, 100% 50%);
}


/* Légende personnalisée */
.pie-legend {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    max-width: 100%;
    padding: 0 10px;
}

.legend-item {
    display: flex;
    align-items: center;
    font-size: 0.9rem;
    color: #e9ecef;
}

.legend-color-box {
    width: 16px;
    height: 16px;
    margin-right: 8px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    border-radius: 3px;
    background-image: var(--bg-image);
    background-size: cover;
    background-position: center;
    flex-shrink: 0;
}
/* AJOUTE CE STYLE POUR SÉPARER LES PARTS AVEC UNE LIGNE */
.pie-slice::after {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    width: 2px; /* Épaisseur de la ligne de séparation */
    height: 50%;
    background: #182138; /* Couleur du fond de la carte */
    transform-origin: bottom center;
}
/* REMPLACE L'ANCIEN .pie-slice PAR CELUI-CI */
.pie-slice {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    
    background-image: var(--bg-image);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    
    transform-origin: center center;
    transform: rotate(var(--rotation));
    
    /* On utilise une découpe beaucoup plus simple et fiable */
    clip-path: polygon(50% 0%, 100% 0%, 100% 50%, 50% 50%);
}

/* ==========================================================================
   08. STYLES SPÉCIFIQUES AUX PAGES
   ========================================================================== */

/* Améliore la lisibilité pour les pages avec beaucoup de texte */
.readable-text-content p, 
.readable-text-content li {
    font-family: 'Exo 2', sans-serif;
    font-size: 1.05rem; /* Un peu plus grand pour le confort */
    line-height: 1.8;   /* Plus d'espace entre les lignes */
    color: var(--kaiba-text-light);
}

.readable-text-content a {
    text-decoration: underline; /* On souligne les liens dans le texte pour bien les voir */
}

.readable-text-content a:hover {
    color: var(--kaiba-gold);
}
/* ============================================= */
/* ==  Style Hologramme/Glitch pour le logo   == */
/* ============================================= */

/* --- Style du texte du logo "YGOMADA" --- */
.logo-text {
    /* Mise en forme du texte */
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    font-size: 2.2rem; /* N'hésite pas à ajuster la taille */
    text-transform: uppercase;
    letter-spacing: 3px;
    color: #e5faff; /* Un blanc-bleuté très clair */

    /* Positionnement et transition */
    position: relative; /* Indispensable pour l'effet glitch */
    transition: all 0.2s ease-in-out;
    
    /* On s'assure qu'il est bien aligné avec l'image */
    vertical-align: middle;

    /* --- EFFET HOLOGRAMME PAR DÉFAUT ---
       Flou volontairement léger : un flou trop large efface le trait
       vertical plat du "D" et le fait lire comme un "O" (YGOMADA ne pose pas ce problème). */
    text-shadow:
        0 0 1px rgba(255, 255, 255, 0.9),
        0 0 3px rgba(0, 170, 255, 0.6),
        0 0 6px rgba(0, 170, 255, 0.4);
}

/* --- PRÉPARATION DE L'EFFET GLITCH (caché par défaut) --- */
.logo-text::before,
.logo-text::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000408; /* correspond au fond glassmorphism de la navbar */
    overflow: hidden;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

/* --- DÉCLENCHEMENT AU SURVOL DE LA SOURIS (HOVER) --- */
.logo-text:hover {
    /* On intensifie légèrement l'hologramme de base, sans revenir au flou large */
    text-shadow:
        0 0 2px rgba(255, 255, 255, 1),
        0 0 6px rgba(0, 225, 255, 0.8),
        0 0 12px rgba(0, 225, 255, 0.7);
}

.logo-text:hover::before {
    left: 2px;
    text-shadow: -2px 0 #ff00c1; /* Couleur du premier glitch (magenta) */
    opacity: 1;
    animation: glitch-effect 1.5s linear infinite reverse;
}

.logo-text:hover::after {
    left: -2px;
    text-shadow: -2px 0 #00fff9; /* Couleur du second glitch (cyan) */
    opacity: 1;
    animation: glitch-effect 2s linear infinite reverse;
}

/* --- L'ANIMATION DU GLITCH --- */
@keyframes glitch-effect {
    0% { clip-path: inset(45% 0 52% 0); }
    5% { clip-path: inset(79% 0 1% 0); }
    10% { clip-path: inset(4% 0 35% 0); }
    15% { clip-path: inset(99% 0 1% 0); }
    20% { clip-path: inset(25% 0 45% 0); }
    25% { clip-path: inset(5% 0 95% 0); }
    30% { clip-path: inset(35% 0 5% 0); }
    35% { clip-path: inset(1% 0 99% 0); }
    40% { clip-path: inset(80% 0 10% 0); }
    45% { clip-path: inset(45% 0 52% 0); }
    50% { clip-path: inset(10% 0 70% 0); }
    55% { clip-path: inset(95% 0 2% 0); }
    60% { clip-path: inset(20% 0 80% 0); }
    65% { clip-path: inset(1% 0 99% 0); }
    70% { clip-path: inset(60% 0 30% 0); }
    75% { clip-path: inset(90% 0 5% 0); }
    80% { clip-path: inset(30% 0 60% 0); }
    85% { clip-path: inset(5% 0 95% 0); }
    90% { clip-path: inset(70% 0 10% 0); }
    95% { clip-path: inset(1% 0 90% 0); }
    100% { clip-path: inset(45% 0 52% 0); }
}
/* ============================================= */
/* ==       Style Page Metagame             == */
/* ============================================= */

.metagame-list {
    display: flex;
    flex-direction: column;
    gap: 1.2rem; /* Espace entre chaque archétype */
}

.metagame-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 10px;
    background-color: rgba(13, 26, 46, 0.6); /* Fond sombre transparent */
    border-radius: 8px;
    border: 1px solid #2a4d7a;
    transition: all 0.3s ease;
}

.metagame-item:hover {
    background-color: rgba(42, 77, 122, 0.7);
    border-color: #e0b21a; /* Bordure dorée au survol */
    transform: translateY(-3px);
    box-shadow: 0 4px 15px rgba(0, 170, 255, 0.2);
}

.archetype-rank {
    font-size: 1.2rem;
    font-weight: bold;
    color: #e0b21a;
    min-width: 30px;
    text-align: center;
}

.archetype-image {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: 50%; /* Image ronde */
    border: 2px solid #2a4d7a;
}

.archetype-info {
    flex-grow: 1; /* Prend tout l'espace restant */
}

.archetype-name {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #e9ecef;
}

.progress {
    background-color: #182138; /* Fond de la barre de progression */
    border: 1px solid #2a4d7a;
    border-radius: 5px; /* Coins arrondis */
}

.progress-bar {
    background: linear-gradient(90deg, #00BCD4, #007bff); /* Dégradé stylé */
    font-weight: bold;
    color: #fff;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.7);
    font-size: 0.85rem;
}

/* ==========================================================================
   STATS PROFIL — KPI Cards & Charts
   ========================================================================== */

.kpi-card {
    background: linear-gradient(135deg, #0d1529 0%, #121e38 100%);
    border: 1px solid rgba(var(--kaiba-gold-warm-rgb), 0.25);
    border-radius: 12px;
    padding: 1.2rem 0.8rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.kpi-card:hover {
    border-color: rgba(var(--kaiba-gold-warm-rgb), 0.6);
    box-shadow: 0 0 18px rgba(var(--kaiba-gold-warm-rgb), 0.15);
}

.kpi-card-sm {
    padding: 0.9rem 0.6rem;
}

.kpi-icon {
    font-size: 1.4rem;
    margin-bottom: 0.4rem;
    color: var(--kaiba-silver);
}

.kpi-value {
    font-family: 'Aldrich', sans-serif;
    font-size: 1.8rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.1;
}

.kpi-value-sm {
    font-size: 1.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.kpi-label {
    font-size: 0.72rem;
    color: var(--kaiba-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 0.25rem;
}

.chart-container-inner {
    background: rgba(13, 21, 41, 0.5);
    border: 1px solid rgba(var(--kaiba-gold-warm-rgb), 0.15);
    border-radius: 10px;
    padding: 1rem;
}

.chart-title {
    color: var(--kaiba-gold);
    font-family: 'Aldrich', sans-serif;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    text-align: center;
}

/* Anneaux SVG W/L/D */
.wld-ring-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 1.1rem 0.5rem 0.9rem;
    background: linear-gradient(145deg, #07091200, #0d152900);
    border-radius: 16px;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.wld-ring-card:hover {
    transform: translateY(-5px);
}

.wld-ring-wrap {
    position: relative;
    width: 100%;
    max-width: 150px;
}

.wld-ring {
    display: block;
    width: 100%;
    height: auto;
    transform: rotate(-90deg);
    overflow: visible;
}

.ring-track {
    fill: none;
    stroke: rgba(255, 255, 255, 0.06);
    stroke-width: 7;
}

.ring-fill {
    fill: none;
    stroke-width: 7;
    stroke-linecap: round;
    transition: stroke-dashoffset 1.5s cubic-bezier(0.22, 1, 0.36, 1);
}

.ring-win  {
    stroke: #22c55e;
    filter: url(#glow-win) drop-shadow(0 0 5px rgba(34, 197, 94, 0.7));
}
.ring-draw {
    stroke: #f59e0b;
    filter: url(#glow-draw) drop-shadow(0 0 5px rgba(245, 158, 11, 0.7));
}
.ring-loss {
    stroke: #ef4444;
    filter: url(#glow-loss) drop-shadow(0 0 5px rgba(239, 68, 68, 0.7));
}

.ring-center {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.ring-pct {
    font-family: 'Aldrich', sans-serif;
    font-size: clamp(1.1rem, 3.5vw, 1.75rem);
    font-weight: 700;
    color: #ffffff;
    line-height: 1;
    text-shadow: 0 0 14px rgba(255, 255, 255, 0.25);
}

.ring-count {
    font-size: clamp(0.55rem, 1.5vw, 0.68rem);
    color: rgba(255, 255, 255, 0.32);
    margin-top: 4px;
    letter-spacing: 0.02em;
}

.ring-label {
    margin-top: 0.75rem;
    font-size: clamp(0.62rem, 1.8vw, 0.76rem);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.09em;
}

.ring-win-label  { color: #22c55e; }
.ring-draw-label { color: #f59e0b; }
.ring-loss-label { color: #ef4444; }


/* ==========================================================================
   04l. ARENA - FORMULAIRE DE CREATION/MODIFICATION
   Absorbé depuis le <style> inline de templates/arena/arena_create.html
   (réorganisation custom.css, AUDIT_REFONTE_2026.md 4.2).
   ========================================================================== */

/* ── Page ── */
.arena-form-wrap { max-width: 720px; margin: 0 auto; }

/* ── Header ── */
.arena-form-header {
    background: linear-gradient(135deg, rgba(0,18,12,.95), rgba(5,15,30,.98));
    border: 1px solid rgba(0,200,120,.3);
    border-radius: 10px 10px 0 0;
    padding: 1.75rem 2rem 1.5rem;
    position: relative;
    overflow: hidden;
}
.arena-form-header::before {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, #00c878 40%, #00c878 60%, transparent);
    opacity: .5;
}
.arena-form-header-icon {
    width: 48px; height: 48px;
    border-radius: 10px;
    background: rgba(0,200,120,.12);
    border: 1px solid rgba(0,200,120,.3);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.3rem; color: #00c878;
    flex-shrink: 0;
}
.arena-form-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.1rem; font-weight: 700;
    color: #00c878; margin: 0;
    letter-spacing: .04em;
}
.arena-form-subtitle {
    font-size: .8rem;
    color: rgba(160,200,180,.55);
    margin: .25rem 0 0;
}

/* ── Body ── */
.arena-form-body {
    background: rgba(5,12,20,.97);
    border: 1px solid rgba(0,200,120,.15);
    border-top: none;
    border-radius: 0 0 10px 10px;
    padding: 2rem;
}

/* ── Section labels ── */
.arena-form-section {
    margin-bottom: 1.75rem;
}
.arena-form-section + .arena-form-section {
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255,255,255,.05);
}
.arena-form-section-label {
    font-family: 'Orbitron', sans-serif;
    font-size: .62rem;
    letter-spacing: .22em;
    text-transform: uppercase;
    color: rgba(0,200,120,.6);
    margin-bottom: 1.1rem;
    display: flex; align-items: center; gap: .5rem;
}
.arena-form-section-label::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(0,200,120,.12);
}

/* ── Champs ── */
.arena-form-label {
    font-size: .82rem;
    font-weight: 600;
    color: #b8cfc8;
    margin-bottom: .4rem;
    display: block;
}
.arena-form-label .required { color: rgba(0,200,120,.8); margin-left: 2px; }
.arena-form-hint {
    font-size: .75rem;
    color: rgba(140,170,160,.5);
    margin-top: .3rem;
}

/* ── Toggle switch Top Cut ── */
.arena-toggle-wrap {
    display: flex; align-items: center; gap: .85rem;
    padding: .85rem 1rem;
    background: rgba(255,255,255,.025);
    border: 1px solid rgba(255,255,255,.06);
    border-radius: 6px;
    cursor: pointer;
    transition: border-color .2s, background .2s;
}
.arena-toggle-wrap:has(input:checked) {
    border-color: rgba(0,200,120,.3);
    background: rgba(0,200,120,.05);
}
.form-switch .form-check-input {
    width: 2.5em; height: 1.3em; cursor: pointer;
    background-color: rgba(255,255,255,.1);
    border-color: rgba(255,255,255,.2);
}
.form-switch .form-check-input:checked {
    background-color: #00c878;
    border-color: #00c878;
}
.form-switch .form-check-input:focus { box-shadow: 0 0 0 .2rem rgba(0,200,120,.25); }
.arena-toggle-label {
    font-size: .85rem;
    font-weight: 600;
    color: #b8cfc8;
    margin: 0;
    user-select: none;
}
.arena-toggle-desc {
    font-size: .75rem;
    color: rgba(140,170,160,.5);
    margin: .1rem 0 0;
}

/* ── Boutons ── */
.arena-form-actions {
    display: flex; gap: .75rem; justify-content: flex-end;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255,255,255,.05);
    margin-top: .5rem;
}
.btn-arena-submit {
    background: linear-gradient(135deg, #009f60, #00c878);
    border: none; color: #001a0e;
    font-family: 'Orbitron', sans-serif;
    font-size: .78rem; font-weight: 700;
    letter-spacing: .06em; text-transform: uppercase;
    padding: .65rem 1.75rem; border-radius: 5px;
    box-shadow: 0 4px 18px rgba(0,200,120,.25);
    transition: transform .18s, box-shadow .18s;
}
.btn-arena-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(0,200,120,.4);
    color: #001a0e;
}

#custom-rules-section { display: none; }
#top-cut-size-section  { display: none; }

/* ── Breadcrumb ── */
.breadcrumb { background: transparent; padding: 0; margin: 0; }
.breadcrumb-item { font-size: .82rem; line-height: 1.4; }
.breadcrumb-item a { color: rgba(0,200,120,.7); text-decoration: none; }
.breadcrumb-item a:hover { color: #00c878; }
.breadcrumb-item.active { color: rgba(180,210,200,.55); }
.breadcrumb-item + .breadcrumb-item::before { color: rgba(255,255,255,.2); }

/* ── Titre principal de la page détail arena ── */
.arena-detail-title {
    font-family: 'Orbitron', sans-serif;
    color: var(--kaiba-gold-warm);
}

/* ==========================================================================
   04m. DECK VIEWER — styles .dv-* partagés
   Utilisé par : arena/arena_decklist.html, arena/arena_ydk_update.html,
   tournaments/decklist_detail.html. Règle de source unique — ne pas dupliquer.
   ========================================================================== */

  /* ── Deck viewer ── */
  .dv-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: .6rem;
  }
  .dv-section-title {
    font-family: 'Orbitron', sans-serif;
    font-size: .85rem;
    color: var(--kaiba-gold-warm);
    text-transform: uppercase;
    letter-spacing: .05em;
  }
  .dv-section-count {
    font-size: .75rem;
    color: #7a8090;
    background: rgba(255,255,255,.05);
    padding: 2px 8px;
    border-radius: 12px;
  }
  .dv-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
  }
  .dv-card {
    width: 64px;
    height: 93px;
    cursor: pointer;
    border-radius: 3px;
    overflow: hidden;
    transition: transform .35s ease, box-shadow .2s, border-color .2s;
    will-change: transform;
    border: 1px solid rgba(var(--kaiba-gold-warm-rgb),.15);
    background: linear-gradient(90deg,
        rgba(255,255,255,.04) 25%,
        rgba(255,255,255,.10) 37%,
        rgba(255,255,255,.04) 63%
    );
    background-size: 200% 100%;
    animation: dv-shimmer 1.5s ease-in-out infinite;
  }
  .dv-card.dv-loaded {
    background: rgba(var(--kaiba-gold-warm-rgb),.05);
    animation: none;
  }
  @keyframes dv-shimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
  }
  @media (prefers-reduced-motion: reduce) {
    .dv-card { animation: none; background: rgba(var(--kaiba-gold-warm-rgb),.05); }
  }
  .dv-card:hover {
    box-shadow: 0 8px 24px rgba(var(--kaiba-gold-warm-rgb),.45);
    border-color: rgba(var(--kaiba-gold-warm-rgb),.6);
    z-index: 2;
  }
  /* Fallback sans JS ou sur tactile : translateY simple */
  @media (hover: none) {
    .dv-card:hover { transform: translateY(-3px) scale(1.04); }
  }
  .dv-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    opacity: 0;
    transition: opacity .2s ease;
  }
  .dv-card img.dv-loaded { opacity: 1; }
  @media (max-width: 576px) {
    .dv-card { width: clamp(52px, 14vw, 64px); height: clamp(76px, 20vw, 93px); }
  }

/* ==========================================================================
   04o. STATS DE MÉTA (tournaments/meta_stats.html)
   ========================================================================== */

.meta-section { margin-bottom: 3.5rem; }

.meta-podium {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.25rem;
    margin: 1.5rem auto 2.5rem;
}

.meta-podium-card {
    flex: 1 1 220px;
    max-width: 280px;
    background: rgba(10, 14, 20, 0.6);
    border: 1px solid rgba(0, 170, 255, 0.25);
    border-radius: 10px;
    padding: 1.4rem 1.2rem;
    text-align: center;
    position: relative;
    transition: transform 0.2s ease;
}
.meta-podium-card:hover { transform: translateY(-4px); }

.meta-podium-card .meta-podium-rank {
    width: 42px; height: 42px;
    line-height: 42px;
    margin: 0 auto 0.7rem;
    border-radius: 50%;
    font-family: 'Aldrich', sans-serif;
    font-weight: 700;
    font-size: 1.1rem;
}
.meta-podium-card.gold   .meta-podium-rank { background: var(--kaiba-gold);   color: #0a0e14; box-shadow: 0 0 14px var(--kaiba-gold-glow); }
.meta-podium-card.silver .meta-podium-rank { background: var(--kaiba-silver); color: #0a0e14; box-shadow: 0 0 14px rgba(192, 192, 192, 0.5); }
.meta-podium-card.bronze .meta-podium-rank { background: var(--kaiba-bronze); color: #0a0e14; box-shadow: 0 0 14px rgba(205, 127, 50, 0.5); }

.meta-podium-card.gold   { border-color: var(--kaiba-gold); }
.meta-podium-card.silver { border-color: var(--kaiba-silver); }
.meta-podium-card.bronze { border-color: var(--kaiba-bronze); }

.meta-podium-name {
    font-family: 'Aldrich', sans-serif;
    font-size: 1.15rem;
    color: #fff;
    margin-bottom: 0.5rem;
    word-break: break-word;
}
.meta-podium-stat { font-size: 0.85rem; color: var(--kaiba-text-muted); }
.meta-podium-stat strong { color: var(--kaiba-text-light); }

.meta-search-wrap { max-width: 360px; margin: 0 auto 1.25rem; position: relative; }
.meta-search-wrap .fa-magnifying-glass {
    position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
    color: var(--kaiba-text-muted); pointer-events: none;
}
.meta-search-input {
    width: 100%;
    padding: 0.5rem 0.9rem 0.5rem 2.2rem;
    background: var(--kaiba-input-bg);
    border: 1px solid var(--kaiba-input-border);
    border-radius: 6px;
    color: var(--kaiba-input-text-color);
}
.meta-search-input:focus {
    outline: none;
    border-color: var(--kaiba-input-focus-border);
    box-shadow: var(--kaiba-input-focus-shadow);
}
.meta-search-input::placeholder { color: var(--kaiba-input-placeholder-color); }

.meta-table .deck-cell { text-align: left; font-weight: bold; color: #fff; }

.meta-bar-wrap {
    display: flex; align-items: center; gap: 0.5rem;
    min-width: 140px;
}
.meta-bar-track {
    flex: 1;
    height: 8px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.08);
    overflow: hidden;
}
.meta-bar-fill {
    height: 100%;
    border-radius: 4px;
    background: linear-gradient(90deg, var(--kaiba-blue), var(--kaiba-gold));
}
.meta-bar-value { font-size: 0.85rem; color: var(--kaiba-text-light); min-width: 2ch; text-align: right; }

.meta-champion-count { color: var(--kaiba-gold); font-weight: bold; }
.meta-champion-count .fa-trophy { margin-right: 0.25rem; }
.meta-no-champion { color: var(--kaiba-text-muted); }

.winrate-badge {
    display: inline-block;
    min-width: 4.2em;
    padding: 0.2em 0.6em;
    border-radius: 999px;
    font-weight: bold;
    font-size: 0.9em;
}
.winrate-badge.high { background: rgba(46, 204, 113, 0.18); color: #4fdc84; }
.winrate-badge.mid  { background: rgba(241, 196, 15, 0.18); color: #f1c40f; }
.winrate-badge.low  { background: rgba(231, 76, 60, 0.18); color: #ff6b5e; }
.winrate-badge.none { background: rgba(255, 255, 255, 0.06); color: var(--kaiba-text-muted); }

.meta-low-sample {
    display: inline-block;
    margin-left: 0.3em;
    color: var(--kaiba-text-muted);
    font-weight: bold;
    cursor: help;
}
.meta-low-sample-note {
    text-align: center;
    color: var(--kaiba-text-muted);
    font-size: 0.85rem;
    margin: 0.75rem 0 0;
}
.meta-low-sample-note .meta-low-sample { margin-left: 0; margin-right: 0.2em; }

.meta-row-hidden { display: none; }

.meta-show-more {
    display: block;
    margin: 1.25rem auto 0;
    background: transparent;
    border: 1px solid var(--kaiba-blue);
    color: var(--kaiba-blue);
    border-radius: 6px;
    padding: 0.5rem 1.5rem;
    font-family: 'Aldrich', sans-serif;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.04em;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}
.meta-show-more:hover { background: var(--kaiba-blue); color: #0a0e14; }

.meta-empty-row { text-align: center; color: var(--kaiba-text-muted); padding: 1.5rem 0; }

.meta-tier-list-title { color: var(--kaiba-text-light); text-align: center; margin: 0 0 1rem; }

.meta-tier-list {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin-bottom: 0.75rem;
}

.meta-tier-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: rgba(10, 14, 20, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-left-width: 5px;
    border-radius: 8px;
    padding: 0.7rem 1rem;
}

.meta-tier-badge {
    flex: 0 0 auto;
    width: 36px; height: 36px;
    line-height: 36px;
    text-align: center;
    border-radius: 8px;
    font-family: 'Aldrich', sans-serif;
    font-weight: 700;
    font-size: 1.1rem;
    color: #0a0e14;
}

.meta-tier-row.meta-tier-s { border-left-color: var(--kaiba-gold); }
.meta-tier-row.meta-tier-s .meta-tier-badge { background: var(--kaiba-gold); box-shadow: 0 0 12px var(--kaiba-gold-glow); }

.meta-tier-row.meta-tier-a { border-left-color: var(--kaiba-blue); }
.meta-tier-row.meta-tier-a .meta-tier-badge { background: var(--kaiba-blue); box-shadow: 0 0 12px var(--kaiba-blue-glow); }

.meta-tier-row.meta-tier-b { border-left-color: var(--kaiba-silver); }
.meta-tier-row.meta-tier-b .meta-tier-badge { background: var(--kaiba-silver); }

.meta-tier-row.meta-tier-c { border-left-color: var(--kaiba-text-muted); }
.meta-tier-row.meta-tier-c .meta-tier-badge { background: var(--kaiba-text-muted); }

.meta-tier-decks {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.meta-tier-deck-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    padding: 0.25rem 0.7rem;
    font-size: 0.85rem;
    color: var(--kaiba-text-light);
}

.meta-tier-chip-winrate { color: var(--kaiba-text-muted); font-size: 0.8em; }

.meta-tier-note {
    text-align: center;
    color: var(--kaiba-text-muted);
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
}

@media (max-width: 576px) {
    .meta-podium-card { flex: 1 1 100%; max-width: 100%; }
    .meta-bar-wrap { min-width: 90px; }
    .meta-tier-row { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
}

/* ─────────────────────────────────────────────────────────────────────
   EXPORT VISUEL MÉTA — bouton + poster caché capturé par html2canvas
   (voir _meta_poster.html). Dimensions en px fixes volontairement : le
   poster est capturé à sa taille réelle pour un visuel Facebook net, pas
   affiché en responsive.
   ───────────────────────────────────────────────────────────────────── */

.meta-poster-export-wrap { text-align: center; margin-bottom: 2rem; }

.meta-poster-export-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
    border: 1px solid var(--kaiba-gold-warm);
    color: var(--kaiba-gold-warm);
    border-radius: 6px;
    padding: 0.6rem 1.5rem;
    font-family: 'Aldrich', sans-serif;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.04em;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}
.meta-poster-export-btn:hover:not(:disabled) { background: var(--kaiba-gold-warm); color: #0a0e14; }
.meta-poster-export-btn:disabled { opacity: 0.6; cursor: wait; }

/* Jamais affiché dans la mise en page normale : positionné hors écran
   (pas display:none, qui donnerait des dimensions nulles et empêcherait
   html2canvas de le capturer) mais toujours réellement rendu par le
   navigateur. */
.meta-poster {
    position: fixed;
    top: 0;
    left: -10000px;
    width: 1080px;
    background: linear-gradient(160deg, #05070c 0%, #0a0e17 55%, #0d1220 100%);
    padding: 60px;
    box-sizing: border-box;
    font-family: 'Exo 2', sans-serif;
}

.meta-poster-header { display: flex; align-items: center; gap: 28px; margin-bottom: 50px; }
.meta-poster-logo { width: 110px; height: 110px; border-radius: 50%; box-shadow: 0 0 30px var(--kaiba-gold-warm-glow); }
.meta-poster-title {
    font-family: 'Orbitron', sans-serif; font-weight: 800; font-size: 52px;
    color: var(--kaiba-gold); letter-spacing: 0.03em; text-shadow: 0 0 24px var(--kaiba-gold-glow);
}
.meta-poster-subtitle { font-size: 26px; color: var(--kaiba-text-light); margin-top: 6px; }
.meta-poster-date { font-size: 16px; color: var(--kaiba-text-muted); margin-top: 4px; }

.meta-poster-podium { display: flex; gap: 24px; margin-bottom: 56px; }
.meta-poster-podium-card {
    flex: 1;
    background: rgba(10, 14, 20, 0.65);
    border: 2px solid rgba(0, 170, 255, 0.25);
    border-radius: 16px;
    padding: 32px 20px;
    text-align: center;
}
.meta-poster-podium-card.gold   { border-color: var(--kaiba-gold); }
.meta-poster-podium-card.silver { border-color: var(--kaiba-silver); }
.meta-poster-podium-card.bronze { border-color: var(--kaiba-bronze); }

.meta-poster-podium-rank {
    width: 60px; height: 60px; line-height: 60px;
    margin: 0 auto 18px;
    border-radius: 50%;
    font-family: 'Aldrich', sans-serif;
    font-weight: 700;
    font-size: 26px;
    color: #0a0e14;
}
.meta-poster-podium-card.gold   .meta-poster-podium-rank { background: var(--kaiba-gold);   box-shadow: 0 0 24px var(--kaiba-gold-glow); }
.meta-poster-podium-card.silver .meta-poster-podium-rank { background: var(--kaiba-silver); box-shadow: 0 0 24px rgba(192, 192, 192, 0.5); }
.meta-poster-podium-card.bronze .meta-poster-podium-rank { background: var(--kaiba-bronze); box-shadow: 0 0 24px rgba(205, 127, 50, 0.5); }

.meta-poster-podium-name { font-family: 'Aldrich', sans-serif; font-size: 26px; color: #fff; margin-bottom: 10px; }
.meta-poster-podium-stat { font-size: 18px; color: var(--kaiba-text-muted); }

.meta-poster-tierlist-title {
    font-family: 'Orbitron', sans-serif; text-align: center;
    color: var(--kaiba-text-light); font-size: 30px; margin-bottom: 24px;
}

.meta-poster-tier-row {
    display: flex;
    align-items: center;
    gap: 20px;
    background: rgba(10, 14, 20, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-left-width: 8px;
    border-radius: 12px;
    padding: 18px 22px;
    margin-bottom: 16px;
}
.meta-poster-tier-badge {
    flex: 0 0 auto;
    width: 56px; height: 56px; line-height: 56px;
    text-align: center;
    border-radius: 10px;
    font-family: 'Aldrich', sans-serif;
    font-weight: 700;
    font-size: 26px;
    color: #0a0e14;
}
.meta-poster-tier-row.meta-poster-tier-s { border-left-color: var(--kaiba-gold); }
.meta-poster-tier-row.meta-poster-tier-s .meta-poster-tier-badge { background: var(--kaiba-gold); box-shadow: 0 0 18px var(--kaiba-gold-glow); }
.meta-poster-tier-row.meta-poster-tier-a { border-left-color: var(--kaiba-blue); }
.meta-poster-tier-row.meta-poster-tier-a .meta-poster-tier-badge { background: var(--kaiba-blue); box-shadow: 0 0 18px var(--kaiba-blue-glow); }
.meta-poster-tier-row.meta-poster-tier-b { border-left-color: var(--kaiba-silver); }
.meta-poster-tier-row.meta-poster-tier-b .meta-poster-tier-badge { background: var(--kaiba-silver); }
.meta-poster-tier-row.meta-poster-tier-c { border-left-color: var(--kaiba-text-muted); }
.meta-poster-tier-row.meta-poster-tier-c .meta-poster-tier-badge { background: var(--kaiba-text-muted); }

.meta-poster-tier-decks { display: flex; flex-wrap: wrap; gap: 10px; }
.meta-poster-tier-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    padding: 8px 16px;
    font-size: 20px;
    color: var(--kaiba-text-light);
}
.meta-poster-tier-chip b { color: var(--kaiba-text-muted); font-size: 0.85em; font-weight: 600; }
.meta-poster-tier-chip-more { color: var(--kaiba-text-muted); }

.meta-poster-footer {
    text-align: center;
    margin-top: 56px;
    padding-top: 32px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.meta-poster-footer-brand { font-family: 'Orbitron', sans-serif; font-weight: 700; font-size: 28px; color: var(--kaiba-gold-warm); letter-spacing: 0.15em; }
.meta-poster-footer-tagline { font-size: 18px; color: var(--kaiba-text-muted); margin-top: 6px; }
.meta-poster-footer-url { font-size: 22px; color: var(--kaiba-blue); margin-top: 10px; font-family: 'Aldrich', sans-serif; }

/* ─────────────────────────────────────────────────────────────────────
   HALL OF FAME — Archives des saisons
   ───────────────────────────────────────────────────────────────────── */

.hof-title {
    font-size: clamp(1.75rem, 4vw, 2.75rem);
    font-weight: 800;
    color: var(--kaiba-gold);
    text-shadow: 0 0 28px rgba(255, 200, 50, 0.35);
    letter-spacing: 0.04em;
}

.hof-season-card {
    background: var(--kaiba-card-bg);
    border: 1px solid rgba(0, 170, 255, 0.18);
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow 0.2s;
}
.hof-season-card:hover {
    box-shadow: 0 4px 24px rgba(0, 170, 255, 0.14);
}

.hof-season-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.9rem 1.25rem;
    background: rgba(0, 170, 255, 0.05);
    border-bottom: 1px solid rgba(0, 170, 255, 0.12);
    flex-wrap: wrap;
    gap: 0.5rem;
}

.hof-season-badge {
    display: inline-block;
    background: var(--kaiba-gold);
    color: #000;
    font-weight: 800;
    font-size: 0.8rem;
    padding: 0.15rem 0.55rem;
    border-radius: 5px;
    letter-spacing: 0.06em;
}

.hof-season-label {
    color: var(--kaiba-light);
    font-weight: 600;
    font-size: 1rem;
}

.hof-season-dates {
    color: var(--kaiba-light-muted);
    font-size: 0.82rem;
}

.hof-season-body {
    display: flex;
}

/* Champion spotlight */
.hof-champion-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1.75rem 2rem;
    border-right: 1px solid rgba(0, 170, 255, 0.12);
    min-width: 160px;
    background: rgba(255, 200, 50, 0.025);
    gap: 0.25rem;
}

.hof-champion-crown {
    font-size: 1.4rem;
    color: var(--kaiba-gold);
    text-shadow: 0 0 10px rgba(255, 200, 50, 0.55);
    margin-bottom: 0.5rem;
}

.hof-champion-link {
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}
.hof-champion-link:hover .hof-champion-avatar {
    box-shadow: 0 0 0 3px var(--kaiba-gold);
}

.hof-champion-avatar {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 200, 50, 0.55);
    transition: box-shadow 0.2s;
}

.hof-champion-pseudo {
    color: var(--kaiba-gold);
    font-weight: 700;
    font-size: 0.95rem;
    text-align: center;
    max-width: 130px;
    word-break: break-word;
}

.hof-champion-label {
    color: var(--kaiba-light-muted);
    font-size: 0.7rem;
    letter-spacing: 0.1em;
}

/* Standings table */
.hof-standings {
    flex: 1;
    overflow-x: auto;
}

.hof-standings .table {
    margin-bottom: 0;
    font-size: 0.9rem;
}

.hof-standings .table thead th {
    border-bottom-color: rgba(0, 170, 255, 0.2);
    color: var(--kaiba-light-muted);
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.hof-row-champion {
    background: rgba(255, 200, 50, 0.06) !important;
}
.hof-row-top3 {
    background: rgba(255, 255, 255, 0.02) !important;
}

@media (max-width: 767px) {
    .hof-season-body { flex-direction: column; }
    .hof-champion-block {
        border-right: none;
        border-bottom: 1px solid rgba(0, 170, 255, 0.12);
        padding: 1.25rem;
    }
}

/* ── Classement de Ligue ── */
.ligue-countdown-banner {
    background: rgba(0, 200, 120, 0.08);
    border: 1px solid rgba(0, 200, 120, 0.25);
    border-radius: 8px;
    color: #d4f5e9;
}
.ligue-countdown-banner .countdown-days {
    font-size: 1.5rem;
    font-weight: 700;
    color: #3dffa0;
}
.ligue-countdown-banner .countdown-label {
    font-size: 0.8rem;
    color: rgba(212, 245, 233, 0.65);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.ligue-q-badge {
    display: inline-block;
    font-size: 0.65rem;
    font-weight: 700;
    color: #fff;
    background: #198754;
    border-radius: 3px;
    padding: 1px 4px;
    vertical-align: middle;
    letter-spacing: 0.04em;
    margin-left: 4px;
}
.ligue-row-qualified {
    border-left: 2px solid rgba(25, 135, 84, 0.5);
}
.ligue-row-gold,
.ligue-row-silver,
.ligue-row-bronze {
    border-left-width: 3px;
    border-left-style: solid;
}
.ligue-row-gold > td {
    background: linear-gradient(90deg, rgba(255, 215, 0, 0.22) 0%, rgba(255, 215, 0, 0.06) 100%) !important;
    color: #fff !important;
    border-left-color: #FFD700;
    box-shadow: inset 0 0 12px rgba(255, 215, 0, 0.12);
}
.ligue-row-silver > td {
    background: linear-gradient(90deg, rgba(210, 220, 235, 0.16) 0%, rgba(210, 220, 235, 0.04) 100%) !important;
    color: #fff !important;
    border-left-color: #cfd8e3;
}
.ligue-row-bronze > td {
    background: linear-gradient(90deg, rgba(205, 127, 50, 0.18) 0%, rgba(205, 127, 50, 0.05) 100%) !important;
    color: #fff !important;
    border-left-color: #cd7f32;
}
.ligue-row-gold a,
.ligue-row-silver a,
.ligue-row-bronze a {
    color: #fff !important;
}
.ligue-cutoff-row td {
    padding: 0.35rem 0;
    background: transparent !important;
}
.ligue-cutoff-line {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.3);
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.ligue-cutoff-line::before,
.ligue-cutoff-line::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255, 255, 255, 0.15);
}
.ligue-rank-cell {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2px;
}

@media (max-width: 575px) {
    .ligue-cutoff-line { font-size: 0.65rem; }
    .ligue-countdown-banner .countdown-days { font-size: 1.2rem; }
}

/* ── Course à la Finale Annuelle ── */
.cf-board {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}
@media (max-width: 767px) {
    .cf-board { grid-template-columns: 1fr; }
}

.cf-panel {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    overflow: hidden;
}
.cf-panel-header {
    padding: 0.6rem 1rem;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}
.cf-panel-header--champions {
    background: rgba(255, 200, 50, 0.07);
    color: #ffd700;
    border-bottom-color: rgba(255, 200, 50, 0.15);
}
.cf-panel-header--reguliers {
    background: rgba(25, 135, 84, 0.08);
    color: #3dffa0;
    border-bottom-color: rgba(25, 135, 84, 0.18);
}

.cf-slot {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.6rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    min-height: 3.2rem;
}
.cf-slot:last-child { border-bottom: none; }

.cf-slot-seed {
    font-size: 0.65rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.3);
    min-width: 1.6rem;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.cf-slot--filled .cf-slot-seed { color: #ffd700; }
.cf-slot--regulier-filled .cf-slot-seed { color: #3dffa0; }

.cf-slot-body { flex: 1; min-width: 0; }
.cf-slot-name {
    font-weight: 600;
    font-size: 0.9rem;
    color: #e8eaf0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.cf-slot-sub {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 1px;
}
.cf-slot-sub--active { color: #4fc3f7; }
.cf-slot-sub--avenir { color: rgba(255, 255, 255, 0.25); }

.cf-slot-badge {
    font-size: 0.65rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    white-space: nowrap;
    flex-shrink: 0;
}
.cf-slot-badge--champion {
    background: rgba(255, 200, 50, 0.15);
    color: #ffd700;
    border: 1px solid rgba(255, 200, 50, 0.3);
}
.cf-slot-badge--active {
    background: rgba(79, 195, 247, 0.12);
    color: #4fc3f7;
    border: 1px solid rgba(79, 195, 247, 0.25);
    animation: cf-pulse 2s infinite;
}
.cf-slot-badge--avenir {
    background: rgba(255, 255, 255, 0.04);
    color: rgba(255, 255, 255, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.08);
}
.cf-slot-badge--regulier {
    background: rgba(25, 135, 84, 0.15);
    color: #3dffa0;
    border: 1px solid rgba(25, 135, 84, 0.3);
}
.cf-slot-badge--vide {
    background: rgba(255, 255, 255, 0.03);
    color: rgba(255, 255, 255, 0.2);
    border: 1px dashed rgba(255, 255, 255, 0.1);
}
.cf-slot-badge--bye {
    background: rgba(255, 165, 0, 0.12);
    color: #ffb74d;
    border: 1px solid rgba(255, 165, 0, 0.25);
}

@keyframes cf-pulse {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.55; }
}

/* Tableau des réguliers */
.cf-reguliers-table th {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: rgba(255, 255, 255, 0.45);
    font-weight: 600;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
}
.cf-reguliers-table td { font-size: 0.9rem; }
.cf-row-qualified { border-left: 2px solid rgba(25, 135, 84, 0.5); }
.cf-cutoff-row td {
    padding: 0.3rem 0;
    background: transparent !important;
}
.cf-cutoff-line {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.28);
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}
.cf-cutoff-line::before,
.cf-cutoff-line::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255, 255, 255, 0.12);
}

.cf-multi-warning {
    background: rgba(255, 165, 0, 0.07);
    border: 1px solid rgba(255, 165, 0, 0.2);
    border-radius: 8px;
    color: #ffcc80;
    font-size: 0.85rem;
}

.cf-empty-state {
    color: rgba(255, 255, 255, 0.3);
    font-size: 0.85rem;
    text-align: center;
    padding: 1.5rem 0;
}

@media (max-width: 575px) {
    .cf-slot-name { font-size: 0.82rem; }
    .cf-reguliers-table td { font-size: 0.82rem; }
}

/* ── Bande calendrier home (playoffs + intersaison) ── */
.calendar-pill {
    display: inline-flex;
    align-items: center;
    gap: 0;
    padding: 0.35rem 0.85rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    white-space: nowrap;
}
.calendar-pill--playoffs {
    background: rgba(255, 200, 50, 0.08);
    border: 1px solid rgba(255, 200, 50, 0.22);
    color: #ffd75e;
}
.calendar-pill--playoffs:hover {
    background: rgba(255, 200, 50, 0.14);
    color: #ffe07a;
}
.calendar-pill--intersaison {
    background: rgba(130, 100, 255, 0.08);
    border: 1px solid rgba(130, 100, 255, 0.22);
    color: #b39dff;
}
.calendar-pill__aside {
    margin-left: 0.45rem;
    font-size: 0.72rem;
    font-weight: 600;
    opacity: 0.75;
    font-style: italic;
}

/* ==========================================================================
   CIRCUIT EXPLICATIF — page /ligue/circuit/
   Utilise les vraies couleurs du thème Kaiba Corp (pas de variables custom).
   ========================================================================== */

/* --- Hero --- */
.circuit-hero { padding: 2.5rem 1rem 1.5rem; }
.circuit-hero__label {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    color: var(--kaiba-text-muted);
    text-transform: uppercase;
    margin-bottom: 0.4rem;
}
.circuit-hero__title {
    font-size: clamp(1.8rem, 5vw, 2.8rem);
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 0.5rem;
}
.circuit-hero__sub {
    color: var(--kaiba-text-muted);
    font-size: 1.05rem;
    max-width: 560px;
    margin: 0 auto;
}

/* --- Section wrapper --- */
.circuit-section {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 1.75rem 1.5rem;
}
.circuit-section__title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--kaiba-blue);
    margin-bottom: 0.75rem;
}
.circuit-section__intro {
    color: var(--kaiba-text-light);
    margin-bottom: 1.25rem;
}
.circuit-subsection-title {
    font-size: 1rem;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 0.6rem;
    margin-top: 1.25rem;
}

/* --- Flow diagram --- */
.circuit-flow {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.75rem 0;
}
.circuit-flow__step {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    background: rgba(0, 170, 255, 0.07);
    border: 1px solid rgba(0, 170, 255, 0.22);
    border-radius: 8px;
    padding: 0.6rem 0.85rem;
    min-width: 110px;
}
.circuit-flow__step--playoff { background: rgba(255,165,0,0.08);  border-color: rgba(255,165,0,0.26); }
.circuit-flow__step--finale  { background: rgba(255,215,0,0.09);  border-color: rgba(255,215,0,0.32); }
.circuit-flow__step--muted   { background: rgba(255,255,255,0.04); border-color: rgba(255,255,255,0.1); }
.circuit-flow__icon { font-size: 1.1rem; color: var(--kaiba-blue); flex-shrink: 0; }
.circuit-flow__step--playoff .circuit-flow__icon { color: #ffa500; }
.circuit-flow__step--finale  .circuit-flow__icon { color: #ffd700; }
.circuit-flow__step--muted   .circuit-flow__icon { color: var(--kaiba-text-muted); }
.circuit-flow__name { font-size: 0.82rem; font-weight: 700; color: #ffffff; line-height: 1.2; }
.circuit-flow__desc { font-size: 0.7rem; color: var(--kaiba-text-muted); }
.circuit-flow__arrow { color: var(--kaiba-text-muted); font-size: 0.85rem; flex-shrink: 0; }

/* --- LP cards --- */
.circuit-lp-card {
    border-radius: 10px;
    padding: 1rem 0.75rem;
    text-align: center;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.03);
}
.circuit-lp-card--win   { background: rgba(40,200,80,0.09);   border-color: rgba(40,200,80,0.25); }
.circuit-lp-card--draw  { background: rgba(100,180,255,0.09); border-color: rgba(100,180,255,0.25); }
.circuit-lp-card--loss  { background: rgba(255,80,80,0.07);   border-color: rgba(255,80,80,0.2); }
.circuit-lp-card--clean { background: rgba(255,215,0,0.09);   border-color: rgba(255,215,0,0.25); }
.circuit-lp-card__pts { font-size: 2rem; font-weight: 800; color: #fff; line-height: 1.1; }
.circuit-lp-card--win   .circuit-lp-card__pts { color: #4cde7f; }
.circuit-lp-card--draw  .circuit-lp-card__pts { color: #7dc8ff; }
.circuit-lp-card--loss  .circuit-lp-card__pts { color: #ff6b6b; }
.circuit-lp-card--clean .circuit-lp-card__pts { color: #ffd700; }
.circuit-lp-card__label { font-size: 0.78rem; color: var(--kaiba-text-muted); margin-top: 0.3rem; }

/* --- Info box --- */
.circuit-info-box {
    background: rgba(0, 170, 255, 0.07);
    border: 1px solid rgba(0, 170, 255, 0.22);
    border-radius: 8px;
    padding: 0.85rem 1rem;
    color: var(--kaiba-text-light);
    font-size: 0.9rem;
}

/* --- Rule cards --- */
.circuit-rule-card {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 1rem;
    height: 100%;
}
.circuit-rule-card__head { font-weight: 700; color: var(--kaiba-blue); margin-bottom: 0.6rem; }
.circuit-rule-card__list {
    padding-left: 1.15rem;
    color: var(--kaiba-text-light);
    font-size: 0.88rem;
    margin: 0;
}
.circuit-rule-card__list li + li { margin-top: 0.35rem; }

/* --- GF panels --- */
.circuit-gf-panel {
    border-radius: 10px;
    overflow: hidden;
    height: 100%;
    border: 1px solid rgba(255,255,255,0.08);
}
.circuit-gf-panel--champ { border-color: rgba(255,215,0,0.28); }
.circuit-gf-panel--reg   { border-color: rgba(0,170,255,0.22); }
.circuit-gf-panel__head {
    padding: 0.65rem 1rem;
    font-weight: 700;
    font-size: 0.92rem;
    color: #fff;
}
.circuit-gf-panel--champ .circuit-gf-panel__head { background: rgba(255,215,0,0.08); color: #ffd700; }
.circuit-gf-panel--reg   .circuit-gf-panel__head { background: rgba(0,170,255,0.07); color: var(--kaiba-blue); }
.circuit-gf-panel__body {
    padding: 0.85rem 1rem;
    font-size: 0.88rem;
    color: var(--kaiba-text-light);
    background: rgba(255,255,255,0.02);
}
.circuit-gf-panel__body p  { margin-bottom: 0.6rem; }
.circuit-gf-panel__body ul { padding-left: 1.1rem; margin: 0; }
.circuit-gf-panel__body li + li { margin-top: 0.3rem; }

/* --- Shared table --- */
.circuit-table {
    color: var(--kaiba-text-light);
    font-size: 0.88rem;
    border-color: rgba(255,255,255,0.08);
}
.circuit-table thead th {
    color: var(--kaiba-text-muted);
    border-color: rgba(255,255,255,0.08);
    background: rgba(255,255,255,0.03);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 600;
}
.circuit-table td, .circuit-table th {
    border-color: rgba(255,255,255,0.08);
    vertical-align: middle;
}

/* --- Format cards (intersaison) --- */
.circuit-format-card {
    background: rgba(130,100,255,0.07);
    border: 1px solid rgba(130,100,255,0.22);
    border-radius: 10px;
    padding: 1.25rem 1rem;
    text-align: center;
    height: 100%;
}
.circuit-format-card__icon  { font-size: 1.5rem; color: #b39dff; margin-bottom: 0.5rem; }
.circuit-format-card__name  { font-weight: 700; color: #fff; margin-bottom: 0.25rem; font-size: 0.95rem; }
.circuit-format-card__desc  { font-size: 0.8rem; color: var(--kaiba-text-muted); }

/* --- Calendrier --- */
.circuit-calendar { display: flex; flex-direction: column; gap: 0.75rem; }
.circuit-cal-row {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 0.85rem 1rem;
}
.circuit-cal-row--active {
    border-color: rgba(0,170,255,0.35);
    background: rgba(0,170,255,0.06);
}
.circuit-cal-row--done { opacity: 0.65; }
.circuit-cal-num {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--kaiba-blue);
    letter-spacing: 0.06em;
    min-width: 28px;
    padding-top: 0.15rem;
    text-transform: uppercase;
}
.circuit-cal-body { flex: 1; }
.circuit-cal-name {
    font-weight: 600;
    color: #fff;
    font-size: 0.95rem;
    margin-bottom: 0.2rem;
}
.circuit-cal-dates { font-size: 0.8rem; color: var(--kaiba-text-muted); }
.circuit-cal-champion { font-size: 0.82rem; color: var(--kaiba-text-light); margin-top: 0.25rem; }
.circuit-cal-status { flex-shrink: 0; padding-top: 0.1rem; }
.circuit-cal-status__icon--done   { color: #4cde7f; font-size: 1.1rem; }
.circuit-cal-status__icon--active { color: var(--kaiba-blue); font-size: 1.1rem; }
.circuit-cal-status__icon--future { color: var(--kaiba-text-muted); font-size: 1.1rem; }

.circuit-badge--active {
    background: rgba(0,170,255,0.15);
    color: var(--kaiba-blue);
    font-size: 0.7rem;
    font-weight: 600;
    border: 1px solid rgba(0,170,255,0.3);
}
.circuit-badge--done {
    background: rgba(40,200,80,0.12);
    color: #4cde7f;
    font-size: 0.7rem;
    font-weight: 600;
    border: 1px solid rgba(40,200,80,0.25);
}

/* --- CTA --- */
.circuit-cta { padding: 2rem 1rem; }
.circuit-cta__title { font-size: 1.4rem; font-weight: 700; color: #fff; margin-bottom: 0.5rem; }
.circuit-cta__sub   { color: var(--kaiba-text-muted); margin-bottom: 1.2rem; }


/* ==========================================================================
   TABLEAU DE BORD FINANCIER (P2-B)
   ========================================================================== */
.tdb-kpi {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: .5rem;
    padding: 1rem 1.2rem;
    height: 100%;
}
.tdb-kpi__val {
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.tdb-kpi__label {
    font-size: 0.78rem;
    color: rgba(201,209,217,0.6);
}
.tdb-kpi--ok  { border-color: rgba(76,222,127,0.25); }
.tdb-kpi--warn { border-color: rgba(255,193,7,0.3); }

/* ─────────────────────────────────────────────────────────────────────
   RÉALISATIONS — article détail
   ───────────────────────────────────────────────────────────────────── */
.realisations-contenu h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #e0e6f0;
    margin-top: 2rem;
    margin-bottom: .75rem;
    padding-bottom: .4rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}
.realisations-contenu p,
.realisations-contenu li {
    color: #c8cfd8;
    line-height: 1.75;
}
.realisations-contenu strong { color: #e8ecf2; }

/* Tableau de résultats intégré via CKEditor */
.realisations-contenu table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.25rem 0;
}
.realisations-contenu th {
    background: rgba(255,255,255,0.06);
    color: #9baab8;
    font-size: .75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .06em;
    padding: .6rem 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    text-align: left;
}
.realisations-contenu td {
    padding: .75rem 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    color: #c8cfd8;
    vertical-align: middle;
}
.realisations-contenu tr:last-child td { border-bottom: none; }
.realisations-contenu tr:hover td { background: rgba(255,255,255,0.03); }

/* Bloc palmares (résultats de tournoi) */
.palmares {
    margin: 1.25rem 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.palmares__item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: .8rem 1.1rem;
    border-radius: 6px;
    background: rgba(255,255,255,0.04);
    border-left: 3px solid transparent;
    transition: background .15s;
}
.palmares__item:hover { background: rgba(255,255,255,0.07); }
.palmares__item--1 { border-color: #f5c842; background: rgba(245,200,66,0.07); }
.palmares__item--2 { border-color: #b0b8c4; }
.palmares__item--3 { border-color: #cd7f32; }
.palmares__rank {
    font-weight: 700;
    font-size: .85rem;
    min-width: 2rem;
    color: #9baab8;
}
.palmares__item--1 .palmares__rank { color: #f5c842; }
.palmares__item--2 .palmares__rank { color: #b0b8c4; }
.palmares__item--3 .palmares__rank { color: #cd7f32; }
.palmares__player { font-weight: 600; color: #e0e6f0; flex: 1; }
.palmares__deck {
    font-size: .85rem;
    color: #7a8a9a;
    font-style: italic;
}

/* ==========================================================================
   HOMEPAGE — styles spécifiques (déplacés depuis home.html <style> inline)
   ========================================================================== */
/* ── Bloc IKM homepage ─────────────────────────────────────── */
.ikm-home-card {
    border-color: rgba(0,170,255,.2);
}
.ikm-home-eyebrow {
    font-family: 'Orbitron', sans-serif;
    font-size: .58rem; letter-spacing: .22em;
    text-transform: uppercase; color: var(--kaiba-blue);
    opacity: .8;
}
.ikm-home-loc {
    font-size: .72rem; color: rgba(201,209,217,.45);
}
.ikm-home-title {
    font-family: 'Orbitron', sans-serif;
    font-size: .9rem; font-weight: 700;
    color: var(--kaiba-text-light);
}
.ikm-plan-pill {
    border-radius: 10px;
    padding: .65rem .75rem;
    text-align: center;
}
.ikm-plan-pill--abonne {
    background: rgba(0,170,255,.07);
    border: 1px solid rgba(0,170,255,.22);
}
.ikm-plan-pill--visiteur {
    background: rgba(240,165,0,.06);
    border: 1px solid rgba(240,165,0,.2);
}
.ikm-plan-name {
    font-size: .65rem; text-transform: uppercase;
    letter-spacing: .1em;
    color: rgba(201,209,217,.5);
    margin-bottom: .2rem;
}
.ikm-plan-price {
    font-family: 'Orbitron', sans-serif;
    font-size: .9rem; font-weight: 800;
    line-height: 1.1;
}
.ikm-plan-pill--abonne .ikm-plan-price { color: #00aaff; }
.ikm-plan-pill--visiteur .ikm-plan-price { color: #f0a500; }
.ikm-plan-price span {
    font-family: inherit;
    font-size: .62rem; font-weight: 400;
    color: rgba(201,209,217,.55);
}
.ikm-plan-sub {
    font-size: .68rem;
    color: rgba(201,209,217,.45);
    margin-top: .15rem;
}
.ikm-home-note {
    font-size: .75rem; color: rgba(201,209,217,.5);
}
.ikm-home-note i { color: #f0a500; }
.ikm-home-cta {
    background: rgba(0,170,255,.1);
    border: 1px solid rgba(0,170,255,.3);
    color: #00aaff;
    font-size: .78rem;
    transition: background .2s, color .2s;
}
.ikm-home-cta:hover {
    background: rgba(0,170,255,.22);
    color: #fff;
    border-color: rgba(0,170,255,.55);
}

/* ── Hero membre ───────────────────────────────────────────── */
.home-hero { position: relative; overflow: hidden; }
.home-hero::before {
    content: '';
    position: absolute; inset: 0;
    background-image: var(--hero-bg-url);
    background-size: cover; background-position: center;
    opacity: 0.12;
    pointer-events: none;
}
.hero-rings {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    pointer-events: none; z-index: 0;
}
.home-hero .card-body { position: relative; z-index: 1; }
.hero-overline {
    font-family: 'Orbitron', sans-serif;
    font-size: .65rem; letter-spacing: .3em;
    text-transform: uppercase; color: var(--kaiba-blue);
    opacity: .85; margin-bottom: .25rem;
}

/* XP bar */
.xp-widget {}
.xp-level-label { font-family: 'Orbitron', sans-serif; font-size: .8rem; color: #FFD700; font-weight: 700; }
.xp-counter { font-size: .72rem; color: rgba(201,209,217,.6); }
.xp-bar-track {
    height: 8px; border-radius: 4px;
    background: rgba(255,255,255,.08);
    overflow: hidden;
}
.xp-bar-fill {
    height: 100%; border-radius: 4px;
    background: linear-gradient(90deg, #00aaff 0%, #FFD700 100%);
    transition: width .6s cubic-bezier(.4,0,.2,1);
    box-shadow: 0 0 8px rgba(255,215,0,.4);
}

/* Kintana badge */
.kintana-badge {
    display: inline-flex; align-items: center;
    background: rgba(var(--kaiba-gold-warm-rgb),.15);
    border: 1px solid rgba(var(--kaiba-gold-warm-rgb),.35);
    color: #FFD700; border-radius: 20px;
    font-size: .75rem; font-weight: 700;
    padding: 3px 10px;
}
.kintana-badge--lg { font-size: .85rem; padding: 5px 14px; }

/* ── Boutique Kintana card (home sidebar) ── */
.boutique-kintana-card { border-color: rgba(var(--kaiba-gold-warm-rgb),.3); }
.boutique-kintana-header { background: rgba(var(--kaiba-gold-warm-rgb),.07); border-bottom-color: rgba(var(--kaiba-gold-warm-rgb),.2); }
.boutique-kintana-title {
    font-size: .85rem; text-transform: uppercase; letter-spacing: .05em;
    color: #FFD700; font-family: 'Orbitron', sans-serif;
}
.boutique-kintana-price {
    background: rgba(var(--kaiba-gold-warm-rgb),.15); color: #FFD700;
    border: 1px solid rgba(var(--kaiba-gold-warm-rgb),.3); font-size: .7rem;
}
.boutique-kintana-cta {
    background: rgba(var(--kaiba-gold-warm-rgb),.15);
    border: 1px solid rgba(var(--kaiba-gold-warm-rgb),.4);
    color: #FFD700;
}
.boutique-kintana-cta:hover { background: rgba(var(--kaiba-gold-warm-rgb),.28); color: #fff; }

/* Titre badge */
.titre-badge {
    display: inline-flex; align-items: center;
    background: rgba(0,170,255,.12);
    border: 1px solid rgba(0,170,255,.3);
    color: #00aaff; border-radius: 20px;
    font-size: .72rem; padding: 3px 10px;
}

/* Mécène badge */
.mecene-badge {
    display: inline-flex; align-items: center;
    background: rgba(var(--kaiba-gold-warm-rgb),.2);
    border: 1px solid rgba(var(--kaiba-gold-warm-rgb),.4);
    color: #FFD700; border-radius: 4px;
    font-size: .65rem; font-weight: 700;
    letter-spacing: .08em; text-transform: uppercase;
    padding: 2px 8px; vertical-align: middle;
}

/* Hero mini cards */
.hero-mini-card {
    background: rgba(255,255,255,.05);
    border: 1px solid rgba(255,255,255,.09);
    border-radius: 10px; padding: .9rem .8rem;
    text-align: center;
    transition: border-color .2s, background .2s;
}
.hero-mini-card--link:hover {
    border-color: rgba(255,215,0,.3);
    background: rgba(255,215,0,.05);
}
.hero-mini-label { font-size: .65rem; text-transform: uppercase; letter-spacing: .1em; color: rgba(201,209,217,.55); margin-bottom: .3rem; }
.hero-mini-value { font-family: 'Orbitron', sans-serif; font-size: 1.5rem; font-weight: 900; line-height: 1.1; }
.hero-mini-sub   { font-size: .65rem; color: rgba(201,209,217,.45); margin-top: .25rem; }

/* Quête active widget */
.hero-quest-card {
    background: rgba(0,170,255,.07);
    border: 1px solid rgba(0,170,255,.2);
    border-radius: 10px; padding: .85rem 1rem;
}
.quest-label { font-family: 'Orbitron', sans-serif; font-size: .58rem; letter-spacing: .2em; text-transform: uppercase; color: rgba(0,170,255,.7); display: block; margin-bottom: .25rem; }
.quest-title { font-size: .85rem; font-weight: 700; color: #c9d8e8; }
.quest-desc  { font-size: .72rem; color: rgba(201,209,217,.5); margin-top: .15rem; line-height: 1.4; }
.quest-reward { font-size: .8rem; }

/* ── Hero visiteur ─────────────────────────────────────────── */
.hero-stats-strip {
    display: flex; align-items: center; justify-content: center;
    flex-wrap: wrap; gap: .5rem 1rem;
    font-size: .85rem; color: rgba(201,209,217,.7);
}
.hero-stats-strip .sep { color: rgba(201,209,217,.3); }

/* ── Bande prochain événement ──────────────────────────────── */
.upcoming-strip {
    position: relative; overflow: hidden;
    background: linear-gradient(135deg, rgba(8,12,4,.97) 0%, rgba(18,15,3,.97) 100%);
    border: 1px solid rgba(var(--kaiba-gold-warm-rgb),.3);
    border-radius: 12px;
    box-shadow: 0 0 28px rgba(var(--kaiba-gold-warm-rgb),.08), 0 4px 20px rgba(0,0,0,.4);
}
.upcoming-strip--has-prizes { border-color: rgba(var(--kaiba-gold-warm-rgb),.45); box-shadow: 0 0 40px rgba(var(--kaiba-gold-warm-rgb),.12), 0 4px 24px rgba(0,0,0,.5); }
.upcoming-strip.upcoming-strip--has-image {
    background-image: linear-gradient(115deg, rgba(6,10,3,.94) 0%, rgba(6,10,3,.82) 40%, rgba(6,10,3,.55) 100%), var(--upcoming-strip-img);
    background-size: cover;
    background-position: center;
}
.upcoming-strip__tier-glow {
    position: absolute; top: -60px; right: -60px;
    width: 300px; height: 300px;
    background: radial-gradient(circle, rgba(var(--kaiba-gold-warm-rgb),.09) 0%, transparent 65%);
    pointer-events: none;
}
.upcoming-strip::before {
    content: '';
    position: absolute; top: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, transparent 0%, rgba(var(--kaiba-gold-warm-rgb),.45) 30%, rgba(255,200,60,.7) 50%, rgba(var(--kaiba-gold-warm-rgb),.45) 70%, transparent 100%);
}
.upcoming-strip__body {
    display: flex; align-items: center; justify-content: space-between;
    flex-wrap: wrap; gap: .75rem 2rem;
    padding: 1.1rem 1.5rem;
    position: relative; z-index: 1;
}
.upcoming-strip__left { display: flex; flex-direction: column; gap: .3rem; flex: 1; min-width: 0; }
.upcoming-strip__label {
    display: inline-flex; align-items: center; gap: .5rem;
    font-family: 'Orbitron', sans-serif;
    font-size: .58rem; letter-spacing: .28em; text-transform: uppercase;
    color: rgba(var(--kaiba-gold-warm-rgb),.7);
}
.upcoming-strip__dot {
    width: 6px; height: 6px; border-radius: 50%; background: #FFD700;
    box-shadow: 0 0 6px #FFD700;
    animation: upstrip-dot 2s ease-in-out infinite;
    flex-shrink: 0;
}
@keyframes upstrip-dot { 0%,100%{opacity:1;box-shadow:0 0 6px #FFD700} 50%{opacity:.3;box-shadow:0 0 2px #FFD700} }
.upcoming-strip__name {
    font-weight: 800; font-size: 1.1rem; color: #f5e8cc;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.upcoming-strip__meta {
    display: flex; flex-wrap: wrap; align-items: center; gap: .2rem .5rem;
    font-size: .75rem; color: rgba(201,209,217,.5);
}
.upcoming-strip__meta-item { display: inline-flex; align-items: center; gap: .3rem; white-space: nowrap; }
.upcoming-strip__meta-item i { color: rgba(var(--kaiba-gold-warm-rgb),.5); font-size: .72rem; }
.upcoming-strip__sep { color: rgba(201,209,217,.2); }
.upcoming-strip__tier-badge {
    display: inline-block;
    font-family: 'Orbitron', sans-serif; font-size: .6rem; font-weight: 700;
    letter-spacing: .08em; padding: 1px 7px; border-radius: 20px;
    white-space: nowrap;
}
.upcoming-strip__tier-major { background:rgba(var(--kaiba-gold-warm-rgb),.15); color:#FFD700; border:1px solid rgba(var(--kaiba-gold-warm-rgb),.35); }
.upcoming-strip__prizes {
    font-size: .77rem; color: rgba(var(--kaiba-gold-warm-rgb),.75);
    background: rgba(var(--kaiba-gold-warm-rgb),.05); border: 1px solid rgba(var(--kaiba-gold-warm-rgb),.12);
    border-radius: 6px; padding: .35rem .7rem;
    line-height: 1.5; margin-top: .1rem;
}
.upcoming-strip__prizes i { opacity: .7; }
.upcoming-strip__right { display: flex; flex-direction: column; align-items: flex-end; gap: .6rem; flex-shrink: 0; }
.upcoming-strip__countdown-block { text-align: right; }
.upcoming-strip__countdown-label { font-size: .6rem; text-transform: uppercase; letter-spacing: .2em; color: rgba(201,209,217,.35); margin-bottom: .1rem; }
.upcoming-strip__countdown {
    font-family: 'Orbitron', sans-serif;
    font-size: 1rem; color: #FFD700;
    font-weight: 900; white-space: nowrap;
    text-shadow: 0 0 12px rgba(255,215,0,.4);
}
.upcoming-strip__cta {
    display: inline-flex; align-items: center;
    padding: .5rem 1.2rem;
    background: linear-gradient(135deg, rgba(var(--kaiba-gold-warm-rgb),.2) 0%, rgba(var(--kaiba-gold-warm-rgb),.3) 100%);
    border: 1px solid rgba(var(--kaiba-gold-warm-rgb),.5);
    border-radius: 6px; color: #FFD700;
    font-family: 'Orbitron', sans-serif; font-size: .72rem; font-weight: 700;
    letter-spacing: .06em; text-transform: uppercase;
    text-decoration: none; white-space: nowrap;
    transition: background .2s, box-shadow .2s, color .2s;
}
.upcoming-strip__cta:hover { background: rgba(var(--kaiba-gold-warm-rgb),.45); box-shadow: 0 4px 16px rgba(var(--kaiba-gold-warm-rgb),.3); color: #fff; }

/* ── LP badge dans la liste saison ────────────────────────── */
.ligue-lp-badge {
    font-family: 'Orbitron', sans-serif;
    font-size: .72rem; font-weight: 700;
    color: #FFD700;
    background: rgba(var(--kaiba-gold-warm-rgb),.12);
    border: 1px solid rgba(var(--kaiba-gold-warm-rgb),.25);
    border-radius: 20px; padding: 2px 10px;
    white-space: nowrap;
}

/* ── Deck name badge ────────────────────────────────────────── */
.deck-name-badge {
    font-size: .72rem; color: rgba(201,209,217,.55);
    font-style: italic; white-space: nowrap;
    overflow: hidden; text-overflow: ellipsis;
    max-width: 140px;
}

/* ── WCQ jauge ─────────────────────────────────────────────── */
.wcq-bar-track {
    height: 12px; border-radius: 6px;
    background: rgba(255,255,255,.07);
    overflow: hidden;
}
.wcq-bar-fill {
    height: 100%; border-radius: 6px;
    background: linear-gradient(90deg, #1a6b2a 0%, #FFD700 100%);
    transition: width .8s cubic-bezier(.4,0,.2,1);
    box-shadow: 0 0 10px rgba(255,215,0,.3);
}
.wcq-pct-badge {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.1rem; font-weight: 900; color: #FFD700;
}

/* ── Arena Gate, Sponsors, Affiches (conservés) ─────────────── */
.arena-gate {
    position: relative; overflow: hidden;
    padding: 5rem 1.5rem; margin-top: 2.5rem;
    background: linear-gradient(180deg, rgba(0,5,3,0) 0%, rgba(0,14,9,.96) 12%, rgba(0,14,9,.96) 88%, rgba(0,5,3,0) 100%);
    border-top: 1px solid rgba(0,200,120,.1); border-bottom: 1px solid rgba(0,200,120,.1);
    isolation: isolate;
}
.arena-gate::before, .arena-gate::after {
    content: ''; position: absolute; left: 8%; right: 8%; height: 1px; pointer-events: none;
}
.arena-gate::before { top: 0; background: linear-gradient(90deg, transparent, #00c878 25%, rgba(var(--kaiba-gold-warm-rgb),.5) 50%, #00c878 75%, transparent); opacity: .75; }
.arena-gate::after  { bottom: 0; background: linear-gradient(90deg, transparent, rgba(0,200,120,.45) 30%, rgba(var(--kaiba-gold-warm-rgb),.25) 50%, rgba(0,200,120,.45) 70%, transparent); opacity: .55; }
.arena-gate__scanlines { position: absolute; inset: 0; background: repeating-linear-gradient(0deg, transparent 0px, transparent 3px, rgba(0,200,120,.011) 3px, rgba(0,200,120,.011) 4px); animation: gate-scan 14s linear infinite; pointer-events: none; z-index: 0; }
@keyframes gate-scan { to { background-position: 0 -80px; } }
.arena-gate__glow { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); width: 900px; height: 420px; background: radial-gradient(ellipse, rgba(0,200,120,.11) 0%, transparent 68%); pointer-events: none; animation: gate-breathe 5s ease-in-out infinite; z-index: 0; }
@keyframes gate-breathe { 0%,100%{opacity:.6;transform:translate(-50%,-50%) scale(1)} 50%{opacity:1;transform:translate(-50%,-50%) scale(1.12)} }
.arena-gate__corner { position: absolute; width: 56px; height: 56px; z-index: 1; }
.arena-gate__corner--tl{top:1.25rem;left:1.25rem}.arena-gate__corner--tr{top:1.25rem;right:1.25rem}
.arena-gate__corner--bl{bottom:1.25rem;left:1.25rem}.arena-gate__corner--br{bottom:1.25rem;right:1.25rem}
.gate-path-anim { animation: gate-draw 1.6s cubic-bezier(.4,0,.2,1) forwards; animation-delay: .4s; }
@keyframes gate-draw { to { stroke-dashoffset: 0; } }
.arena-gate__bg-text { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); font-family: 'Orbitron', sans-serif; font-size: clamp(5rem,20vw,15rem); font-weight: 900; color: transparent; -webkit-text-stroke: 1px rgba(0,200,120,.055); white-space: nowrap; pointer-events: none; user-select: none; letter-spacing: .12em; z-index: 0; animation: bg-drift 22s ease-in-out infinite; }
@keyframes bg-drift { 0%,100%{transform:translate(-50%,-50%) scale(1)} 50%{transform:translate(-50%,-51.5%) scale(1.025)} }
.arena-gate__inner { position: relative; z-index: 2; max-width: 660px; margin: 0 auto; text-align: center; }
.arena-gate__badge { display: inline-flex; align-items: center; gap: .5rem; font-family: 'Orbitron', sans-serif; font-size: .62rem; letter-spacing: .28em; text-transform: uppercase; color: rgba(0,200,120,.75); margin-bottom: 1.4rem; }
.arena-gate__badge-dot { width: 7px; height: 7px; border-radius: 50%; background: #00c878; box-shadow: 0 0 8px #00c878; animation: dot-blink 2.2s ease-in-out infinite; }
@keyframes dot-blink { 0%,100%{opacity:1;box-shadow:0 0 10px #00c878,0 0 20px rgba(0,200,120,.4)} 50%{opacity:.35;box-shadow:0 0 3px #00c878} }
.arena-gate__title { font-family: 'Orbitron', sans-serif; font-size: clamp(2.2rem,5.5vw,3.8rem); font-weight: 900; line-height: 1.1; margin-bottom: 1.3rem; letter-spacing: .02em; }
.arena-gate__title-line1 { display: block; color: #ddeee6; }
.arena-gate__title-line2 { display: block; color: #00c878; text-shadow: 0 0 28px rgba(0,200,120,.55),0 0 64px rgba(0,200,120,.2); }
.arena-gate__sub { font-size: .93rem; color: rgba(175,210,192,.62); line-height: 1.8; margin-bottom: 2.2rem; max-width: 500px; margin-left: auto; margin-right: auto; }
.arena-gate__cta { position: relative; display: inline-flex; align-items: center; justify-content: center; padding: .9rem 2.8rem; border: 1px solid rgba(0,200,120,.55); border-radius: 3px; color: #00e890; font-family: 'Orbitron', sans-serif; font-size: .82rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; text-decoration: none; overflow: hidden; background: rgba(0,200,120,.04); transition: color .28s,border-color .28s,box-shadow .28s; }
.arena-gate__cta:hover { color: #001a0e; border-color: #00c878; box-shadow: 0 6px 28px rgba(0,200,120,.35); }
.arena-gate__cta-sweep { position: absolute; inset: 0; background: #00c878; transform: translateX(-102%); transition: transform .38s cubic-bezier(.4,0,.2,1); z-index: 0; }
.arena-gate__cta:hover .arena-gate__cta-sweep { transform: translateX(0); }
.arena-gate__cta-text { position: relative; z-index: 1; }
.arena-gate__formats { display: flex; gap: .45rem; justify-content: center; flex-wrap: wrap; margin-top: 1.6rem; }
.arena-gate__formats span { font-family: 'Orbitron', sans-serif; font-size: .58rem; letter-spacing: .18em; text-transform: uppercase; color: rgba(0,200,120,.38); border: 1px solid rgba(0,200,120,.14); border-radius: 2px; padding: 3px 9px; transition: color .2s,border-color .2s; }
.arena-gate__formats span:hover { color: rgba(0,200,120,.75); border-color: rgba(0,200,120,.4); }

/* Arena home widget */
.arena-home-card { border-color: rgba(0,200,120,.35); background: linear-gradient(135deg, rgba(0,20,15,.6) 0%, rgba(5,15,30,.85) 100%); }
.arena-home-card .card-header { border-bottom-color: rgba(0,200,120,.25); background: rgba(0,200,120,.07); }
.arena-home-title { font-family: 'Orbitron', sans-serif; font-size: .8rem; color: #00c878; text-transform: uppercase; letter-spacing: .05em; }
.arena-home-btn-all { font-size: .72rem; color: #00c878; border: 1px solid rgba(0,200,120,.4); background: transparent; padding: 2px 10px; border-radius: 20px; text-decoration: none; }
.arena-home-btn-all:hover { background: rgba(0,200,120,.15); color: #00e890; border-color: rgba(0,200,120,.7); }
.arena-home-item { background: transparent; border-color: rgba(0,200,120,.12); padding: .65rem 1rem; transition: background .18s; }
.arena-home-item:hover { background: rgba(0,200,120,.07); }
.arena-home-name { font-size: .85rem; font-weight: 600; color: #c9d8cf; }
.arena-home-meta { color: rgba(160,200,180,.6); font-size: .72rem; }
.arena-home-status-badge { font-size: .65rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; padding: 3px 8px; border-radius: 20px; white-space: nowrap; }
.badge-open { background: rgba(0,200,120,.18); color: #00c878; border: 1px solid rgba(0,200,120,.4); }
.badge-live { background: rgba(255,120,0,.18); color: #ff8c00; border: 1px solid rgba(255,120,0,.4); }

/* Carrousel Réalisations (dashboard) */
.real-carousel-slide {
    display: block; text-decoration: none;
    height: 400px;
    background: #080c14 center/cover no-repeat;
    position: relative;
}
.real-carousel-overlay {
    position: absolute; inset: 0;
    display: flex; flex-direction: column; justify-content: flex-end;
    padding: 1.1rem 1.25rem 1rem;
    background: linear-gradient(to top, rgba(0,0,0,.90) 0%, rgba(0,0,0,.25) 60%, transparent 100%);
}
.real-carousel-date {
    font-size: .62rem; color: rgba(245,200,66,.7);
    text-transform: uppercase; letter-spacing: .08em; margin-bottom: .3rem;
}
.real-carousel-title {
    font-size: 1rem; font-weight: 700; color: #eef3fa;
    line-height: 1.35; margin-bottom: .55rem;
}
.real-carousel-cta {
    display: inline-flex; align-items: center; gap: .35rem;
    font-size: .7rem; font-weight: 600; color: #f5c842;
    text-transform: uppercase; letter-spacing: .06em;
    transition: gap .18s;
}
.real-carousel-slide:hover .real-carousel-cta { gap: .6rem; }
/* Points de navigation */
.real-carousel-dots { bottom: .55rem; margin: 0; }
.real-carousel-dots [data-bs-target] {
    width: 7px; height: 7px; border-radius: 50%;
    background: rgba(245,200,66,.3); border: none;
    margin: 0 3px; opacity: 1; transition: background .2s;
}
.real-carousel-dots .active { background: #f5c842; }
/* Flèches — visibles au survol seulement */
.real-carousel-ctrl {
    width: 10%; opacity: 0; transition: opacity .2s;
}
#carouselRealisations:hover .real-carousel-ctrl { opacity: .85; }

/* Sponsors */
.partenaires-section { margin-top: 2.5rem; padding: 3.5rem 0 3rem; background: linear-gradient(180deg, rgba(0,10,20,0) 0%, rgba(0,20,40,.55) 40%, rgba(0,10,20,0) 100%); border-top: 1px solid rgba(0,170,255,.18); border-bottom: 1px solid rgba(0,170,255,.12); position: relative; overflow: hidden; }
.partenaires-section::before { content: ''; position: absolute; top: 0; left: 10%; right: 10%; height: 1px; background: linear-gradient(90deg, transparent, #00aaff 30%, #FFD700 50%, #00aaff 70%, transparent); opacity: .6; }
.partenaires-inner { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.partenaires-header { text-align: center; margin-bottom: 2.5rem; }
.partenaires-overline { font-family: 'Orbitron', sans-serif; font-size: .7rem; letter-spacing: .3em; color: #00aaff; text-transform: uppercase; margin-bottom: .5rem; opacity: .85; }
.partenaires-title { font-family: 'Orbitron', sans-serif; font-size: clamp(1.3rem,3vw,2rem); color: #e8f4ff; margin-bottom: .75rem; letter-spacing: .04em; }
.partenaires-tagline { color: rgba(201,209,217,.65); font-size: .9rem; max-width: 560px; margin: 0 auto; line-height: 1.7; }
.partenaires-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 1.25rem; }
.partenaire-card { position: relative; width: 160px; height: 120px; background: rgba(5,15,30,.7); border: 1px solid rgba(0,170,255,.15); border-radius: 12px; overflow: hidden; cursor: pointer; transform: perspective(700px) rotateX(var(--rx)) rotateY(var(--ry)); transition: transform .1s ease,box-shadow .35s ease,border-color .35s ease; will-change: transform; }
.partenaire-card:hover { border-color: rgba(0,170,255,.55); box-shadow: 0 0 18px rgba(0,170,255,.25),0 0 40px rgba(0,170,255,.12),0 8px 32px rgba(0,0,0,.5); }
.partenaire-link { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .5rem; width: 100%; height: 100%; padding: 1rem .75rem; text-decoration: none; color: inherit; }
.partenaire-logo { max-width: 100%; max-height: 64px; width: auto; height: auto; object-fit: contain; transition: transform .35s ease,filter .35s ease; filter: brightness(.85) saturate(.9); }
.partenaire-card:hover .partenaire-logo { filter: brightness(1) saturate(1.1); transform: scale(1.06); }
.partenaire-nom { font-size: .68rem; font-family: 'Exo 2',sans-serif; color: rgba(201,209,217,.5); text-align: center; letter-spacing: .04em; text-transform: uppercase; transition: color .3s; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.partenaire-card:hover .partenaire-nom { color: rgba(201,209,217,.9); }
.partenaire-shimmer { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(110deg, transparent 20%, rgba(255,255,255,.13) 45%, rgba(255,255,255,.08) 50%, rgba(255,255,255,.13) 55%, transparent 80%); background-size: 250% 100%; background-position: 200% center; transition: background-position 0s; border-radius: inherit; }
.partenaire-card:hover .partenaire-shimmer { background-position: -100% center; transition: background-position .55s ease; }

/* Événements & affiches */
.evenements-section { margin-top: 2.5rem; padding: 3.5rem 0 3rem; background: linear-gradient(180deg, rgba(0,10,20,0) 0%, rgba(10,5,0,.55) 40%, rgba(0,10,20,0) 100%); border-top: 1px solid rgba(var(--kaiba-gold-warm-rgb),.18); border-bottom: 1px solid rgba(var(--kaiba-gold-warm-rgb),.12); position: relative; overflow: hidden; }
.evenements-section::before { content: ''; position: absolute; top: 0; left: 10%; right: 10%; height: 1px; background: linear-gradient(90deg, transparent, #FFD700 30%, #FFA500 50%, #FFD700 70%, transparent); opacity: .55; }
.evenements-inner { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.evenements-header { text-align: center; margin-bottom: 2.5rem; }
.evenements-overline { font-family: 'Orbitron', sans-serif; font-size: .7rem; letter-spacing: .3em; color: #FFD700; text-transform: uppercase; margin-bottom: .5rem; opacity: .85; }
.evenements-title { font-family: 'Orbitron', sans-serif; font-size: clamp(1.3rem,3vw,2rem); color: #f5e8cc; margin-bottom: 0; letter-spacing: .04em; }
.evenements-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 2rem; }
.affiche-card { position: relative; width: 260px; border-radius: 12px; overflow: hidden; cursor: pointer; border: 1px solid rgba(var(--kaiba-gold-warm-rgb),.2); box-shadow: 0 4px 24px rgba(0,0,0,.5); transition: transform .3s,box-shadow .3s,border-color .3s; will-change: transform; }
.affiche-card:hover { transform: translateY(-6px) scale(1.02); border-color: rgba(var(--kaiba-gold-warm-rgb),.6); box-shadow: 0 12px 40px rgba(0,0,0,.6),0 0 20px rgba(var(--kaiba-gold-warm-rgb),.2); }
.affiche-img { display: block; width: 100%; height: auto; border-radius: 12px; transition: filter .3s; }
.affiche-card:hover .affiche-img { filter: brightness(.88); }
.affiche-date-badge { position: absolute; bottom: 0; left: 0; right: 0; padding: .75rem 1rem .65rem; background: linear-gradient(to top, rgba(0,0,0,.85) 0%, transparent 100%); color: #FFD700; font-size: .75rem; font-family: 'Orbitron', sans-serif; letter-spacing: .06em; text-align: center; text-transform: uppercase; backdrop-filter: blur(2px); }
.affiche-hover-overlay { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity .25s; pointer-events: none; }
.affiche-hover-overlay i { font-size: 2.5rem; color: rgba(255,255,255,.9); text-shadow: 0 0 20px rgba(255,215,0,.7); filter: drop-shadow(0 0 8px rgba(255,215,0,.5)); }
.affiche-card:hover .affiche-hover-overlay { opacity: 1; }

/* Lightbox */
.affiche-lightbox { position: fixed; inset: 0; background: rgba(0,0,0,0); z-index: 9999; display: flex; align-items: center; justify-content: center; padding: 1.5rem; opacity: 0; pointer-events: none; transition: background .3s,opacity .3s; backdrop-filter: blur(0px); }
.affiche-lightbox.is-open { opacity: 1; pointer-events: all; background: rgba(0,0,0,.88); backdrop-filter: blur(6px); transition: background .3s,opacity .3s,backdrop-filter .3s; }
.affiche-lightbox-content { position: relative; display: flex; flex-direction: column; align-items: center; gap: 1.25rem; max-height: 90vh; transform: scale(.75); opacity: 0; transition: none; }
.affiche-lightbox.is-open .affiche-lightbox-content { animation: lightbox-spring .38s cubic-bezier(.34,1.56,.64,1) forwards; }
@keyframes lightbox-spring { from{transform:scale(.75);opacity:0} to{transform:scale(1);opacity:1} }
#affiche-lightbox-img { max-height: 80vh; max-width: min(480px,90vw); width: auto; height: auto; border-radius: 10px; box-shadow: 0 0 0 1px rgba(var(--kaiba-gold-warm-rgb),.3),0 30px 80px rgba(0,0,0,.8),0 0 60px rgba(var(--kaiba-gold-warm-rgb),.08); display: block; }
.affiche-lightbox-close { position: fixed; top: 1.25rem; right: 1.5rem; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.15); color: #fff; font-size: 1.8rem; line-height: 1; width: 44px; height: 44px; border-radius: 50%; cursor: pointer; transition: background .2s,transform .2s; display: flex; align-items: center; justify-content: center; z-index: 10000; }
.affiche-lightbox-close:hover { background: rgba(255,255,255,.18); transform: rotate(90deg); }
.affiche-lightbox-btn { display: inline-flex; align-items: center; padding: .6rem 1.8rem; background: transparent; border: 1px solid rgba(var(--kaiba-gold-warm-rgb),.55); border-radius: 4px; color: #FFD700; font-family: 'Orbitron', sans-serif; font-size: .75rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; text-decoration: none; transition: background .25s,color .25s,box-shadow .25s; }
.affiche-lightbox-btn:hover { background: rgba(var(--kaiba-gold-warm-rgb),.15); color: #fff; box-shadow: 0 0 20px rgba(var(--kaiba-gold-warm-rgb),.25); }

/* Responsive */
@media (max-width: 575px) {
.partenaire-card { width: 130px; height: 100px; }
    .partenaires-grid { gap: .875rem; }
    .affiche-card { width: 220px; }
    #affiche-lightbox-img { max-width: 94vw; }
    .arena-gate { padding: 3.5rem 1rem; }
    .arena-gate__corner { width: 38px; height: 38px; }
    .upcoming-strip__body { flex-direction: column; gap: .75rem; }
    .upcoming-strip__right { width: 100%; flex-direction: row; align-items: center; justify-content: space-between; }
    .upcoming-strip__countdown { font-size: .85rem; }
    .upcoming-strip__countdown-block { text-align: left; }
}

/* ==========================================================================
   PWA INSTALL BANNER
   ========================================================================== */
.pwa-install-banner {
    position: fixed;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1055;
    background: #141e33;
    border: 1px solid #d4af37;
    border-radius: .75rem;
    padding: .875rem 1rem;
    display: flex;
    flex-direction: column;
    gap: .625rem;
    width: calc(100% - 2rem);
    max-width: 360px;
    box-shadow: 0 8px 32px rgba(0,0,0,.65);
}
.pwa-install-header {
    display: flex;
    align-items: center;
    gap: .625rem;
}
.pwa-install-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    flex-shrink: 0;
}
.pwa-install-text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: .1rem;
}
.pwa-install-text strong {
    font-size: .9rem;
    color: #e8d98a;
    line-height: 1.2;
}
.pwa-install-text small {
    font-size: .75rem;
    color: #7a8fa8;
    line-height: 1.3;
}
.pwa-dismiss-btn {
    flex-shrink: 0;
    align-self: flex-start;
    background: none;
    border: none;
    color: #6a7a8a;
    font-size: 1.25rem;
    line-height: 1;
    cursor: pointer;
    padding: .15rem .3rem;
    transition: color .15s;
}
.pwa-dismiss-btn:hover { color: #aabbcc; }
.pwa-install-btn {
    width: 100%;
    padding: .575rem 1rem;
    background: linear-gradient(90deg, #c9a227, #e8c840);
    color: #0a0e14;
    font-weight: 700;
    font-size: .9rem;
    border: none;
    border-radius: .5rem;
    cursor: pointer;
    transition: opacity .15s;
    letter-spacing: .02em;
}
.pwa-install-btn:hover { opacity: .85; }

/* ==========================================================================
   TOURNAMENT MANAGE — @media print (appariements)
   ========================================================================== */
@media print {
    nav.navbar,
    .site-footer,
    .kaiba-nav-tabs,
    .card-header,
    .score-counter,
    .alert,
    select,
    button,
    .btn { display: none !important; }

    /* Masquer toutes les rondes sauf la ronde active */
    .round-block { display: none !important; }
    .round-block--current { display: block !important; }

    /* Fond blanc, texte noir */
    body, html { background: #fff !important; color: #000 !important; }
    .kaiba-card, .card-body, .tab-pane, .tab-content {
        background: #fff !important;
        box-shadow: none !important;
        border: none !important;
    }

    /* Table lisible */
    .table { color: #000 !important; width: 100%; border-collapse: collapse; }
    .table th, .table td { border: 1px solid #bbb !important; padding: .35rem .6rem !important; }
    .table thead th { background: #eee !important; font-weight: bold; }

    /* Supprimer les marges de page inutiles */
    .container, .row, [class^="col-"] { max-width: 100% !important; padding: 0 !important; margin: 0 !important; }
}

/* ==========================================================================
   P1 — CORRECTIONS MOBILE CRITIQUES — tournament_manage (2026-06-27)
   ========================================================================== */
@media (max-width: 575.98px) {

    /* P1-1 : Sélect résultat compressé sur mobile
       Le style inline garde min-width:130px sur desktop ; on l'écrase ici. */
    .match-score-select {
        min-width: 80px !important;
        max-width: 100% !important;
        font-size: 0.78rem !important;
    }

    /* P1-2 : Onglets de gestion — scroll horizontal au lieu d'empiler
       #manageTab  = circuit/arena  |  #manageTabs = LDD */
    #manageTab,
    #manageTabs {
        overflow-x: auto;
        flex-wrap: nowrap !important;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    #manageTab::-webkit-scrollbar,
    #manageTabs::-webkit-scrollbar { display: none; }
    #manageTab .nav-item,
    #manageTabs .nav-item          { flex-shrink: 0; }
    #manageTab .nav-link,
    #manageTabs .nav-link {
        font-size: 0.78rem;
        padding: 0.5rem 0.875rem;
        white-space: nowrap;
    }

    /* P1-3 : .btn-sm — tap target minimum 44 px (WCAG 2.5.5) */
    .btn-sm {
        min-height: 44px;
        padding-top: 0.5rem;
        padding-bottom: 0.5rem;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    /* P2-13 : row g-4 — gutter trop large sur 320 px */
    .row.g-4 {
        --bs-gutter-x: 0.75rem;
        --bs-gutter-y: 0.75rem;
    }

    /* P2-14 : backdrop-filter réduit sur mobile (perf Android bas de gamme) */
    .kaiba-navbar,
    .navbar-collapse {
        backdrop-filter: blur(6px);
        -webkit-backdrop-filter: blur(6px);
    }

    /* P3-18 : standings-table — font-sizes adaptées sur mobile */
    .standings-table thead th {
        font-size: clamp(0.8rem, 2.5vw, 1.1rem);
        letter-spacing: 0;
    }
    .standings-table tbody th {
        font-size: clamp(1.2rem, 5vw, 2.5rem);
        width: auto;
    }
}

/* ==========================================================================
   LDD — CORRECTIONS MOBILE
   ========================================================================== */
@media (max-width: 575.98px) {

    /* M-1 : Tableau de matchs → mise en page "carte" sur mobile
       HTML order: td1=J1, td2=Score/Select, td3=J2, td4=Gagnant
       Rendu mobile: [J1 gauche — J2 droite] puis [Score/Select centré] puis [Gagnant] */
    .ldd-match-table thead { display: none; }

    .ldd-match-table tbody tr {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        padding: 0.5rem 0.25rem;
        border-bottom: 1px solid rgba(0, 170, 255, 0.1);
    }

    .ldd-match-table tbody td {
        display: block;
        padding: 0.15rem 0.3rem;
        border: none !important;
    }

    /* Joueur 1 — moitié gauche */
    .ldd-match-table tbody td:nth-child(1) {
        width: 50%;
        order: 1;
        font-weight: 600;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    /* Joueur 2 — moitié droite */
    .ldd-match-table tbody td:nth-child(3) {
        width: 50%;
        order: 2;
        text-align: right;
        font-weight: 600;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    /* Score / Select résultat — pleine largeur, 2e ligne */
    .ldd-match-table tbody td:nth-child(2) {
        width: 100%;
        order: 3;
        text-align: center;
    }

    /* Gagnant (colonne 4, rounds terminés) — pleine largeur, 3e ligne */
    .ldd-match-table tbody td:nth-child(4) {
        width: 100%;
        order: 4;
        text-align: center;
        font-size: 0.78rem;
        color: rgba(201, 209, 217, 0.6);
    }

    /* Select résultat : pleine largeur dans le layout carte */
    .ldd-match-table .match-score-select {
        width: 100% !important;
        min-width: unset !important;
        max-width: 100% !important;
        margin: 0 !important;
    }
}
