/* ==========================================================
   NAIROX GAMING — Espace staff
   ========================================================== */
.admin { font-size: 15px; }
.admin-wrap { width: min(1320px, 100% - 32px); margin-inline: auto; }
.admin-main { padding: 2rem 0 4rem; }
.small { font-size: .82rem; margin-top: 1rem; }
.nowrap { white-space: nowrap; }

.admin-top { position: sticky; top: 0; z-index: 40; background: rgba(11,11,18,.88); backdrop-filter: blur(14px); border-bottom: 1px solid var(--border); }
.admin-top__inner { display: flex; align-items: center; gap: 2rem; height: 68px; }
.admin-nav { display: flex; gap: .3rem; flex: 1; }
.admin-nav a { padding: .55rem .9rem; border-radius: 10px; color: var(--muted); font-weight: 500; font-size: .92rem; transition: .2s; }
.admin-nav a:hover { color: var(--text); background: rgba(255,255,255,.04); }
.admin-nav a.is-active { color: var(--text); background: rgba(139,92,246,.15); }
.admin-user { display: flex; align-items: center; gap: .7rem; }
.admin-user strong { display: block; font-size: .9rem; line-height: 1.2; }
.admin-user small { color: var(--muted); font-size: .75rem; }
.admin-user form { margin-left: .5rem; }
@media (max-width: 900px) {
    .admin-top__inner { flex-wrap: wrap; height: auto; padding: .8rem 0; gap: .8rem; }
    .admin-nav { order: 3; flex-basis: 100%; overflow-x: auto; }
    .admin-user { margin-left: auto; }
    .admin-user > div { display: none; }
}

.avatar { flex: none; width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; font: 700 1rem/1 var(--font-head); color: #fff; background: var(--grad-ui); }
.avatar--sm { width: 32px; height: 32px; font-size: .85rem; border-radius: 9px; }
.avatar--lg { width: 68px; height: 68px; font-size: 1.8rem; border-radius: 18px; }

/* ---------- Login ---------- */
.login { min-height: calc(100vh - 6rem); display: grid; place-items: center; }
.login__card { width: min(420px, 100%); background: var(--surface); border: 1px solid var(--border); border-radius: 22px; padding: 2.4rem 2rem; box-shadow: var(--shadow); text-align: center; }
.login__card .field { text-align: left; }
.login__logo { width: 76px; height: 76px; margin: 0 auto 1.2rem; display: grid; place-items: center; border-radius: 20px; background: var(--bg-2); border: 1px solid var(--border); box-shadow: 0 0 40px -8px rgba(139,92,246,.6); }
.login__card h1 { font-size: 1.7rem; margin-bottom: .3rem; }
.login__card > .muted { margin-bottom: 1.6rem; }
.login__back { display: inline-block; margin-top: 1.3rem; color: var(--muted); font-size: .9rem; }
.login__back:hover { color: var(--text); }

/* ---------- En-tête de page ---------- */
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.6rem; }
.page-head h1 { font-size: 2rem; margin-bottom: .2rem; }
.page-head p { margin: 0; }
.page-head__actions { display: flex; gap: .6rem; }
.btn--excel { background: #107c41; color: #fff; box-shadow: 0 10px 25px -12px rgba(16,124,65,.9); }
.btn--excel:hover { background: #0e6b38; }

/* ---------- KPIs ---------- */
.kpis { display: grid; grid-template-columns: repeat(5, 1fr); gap: 1rem; margin-bottom: 1.2rem; }
.kpi { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 1.2rem 1.3rem; display: flex; flex-direction: column; position: relative; overflow: hidden; transition: transform .2s, border-color .2s; }
a.kpi:hover { transform: translateY(-3px); }
.kpi::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--primary); }
.kpi__label { color: var(--muted); font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; font-weight: 600; }
.kpi strong { font: 700 2.2rem/1.1 var(--font-head); margin: .35rem 0 .1rem; }
.kpi small { color: var(--muted); font-size: .8rem; }
.kpi--warn::before { background: var(--warn); } a.kpi--warn:hover { border-color: rgba(245,158,11,.5); }
.kpi--info::before { background: var(--info); } a.kpi--info:hover { border-color: rgba(59,130,246,.5); }
.kpi--ok::before { background: var(--ok); } a.kpi--ok:hover { border-color: rgba(34,197,94,.5); }
.kpi--ko::before { background: var(--ko); } a.kpi--ko:hover { border-color: rgba(239,68,68,.5); }
@media (max-width: 1000px) { .kpis { grid-template-columns: repeat(2, 1fr); } .kpis .kpi:first-child { grid-column: span 2; } }

.split-bar { display: flex; height: 8px; border-radius: 8px; overflow: hidden; background: var(--surface-2); gap: 2px; }
.split-bar__seg--youtube { background: var(--yt); }
.split-bar__seg--discord { background: var(--discord); }
.split-bar__seg--les_deux { background: var(--accent); }
.split-legend { display: flex; gap: 1.4rem; flex-wrap: wrap; color: var(--muted); font-size: .85rem; margin: .6rem 0 1.8rem; }
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: .3rem; }
.dot--youtube { background: var(--yt); } .dot--discord { background: var(--discord); } .dot--les_deux { background: var(--accent); }

/* ---------- Filtres ---------- */
.filters { display: flex; gap: .6rem; flex-wrap: wrap; margin-bottom: 1rem; }
.filters input[type=search] { flex: 1 1 280px; }
.filters select { flex: 0 1 200px; }
.input { width: auto; background: var(--surface); color: var(--text); border: 1px solid var(--border); border-radius: 10px; padding: .7rem .9rem; font: inherit; font-size: .92rem; }
.input--sm { padding: .45rem .6rem; font-size: .85rem; }
.input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(139,92,246,.18); }

/* ---------- Tableau ---------- */
.table-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; overflow: hidden; }
.table-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .8rem 1.1rem; border-bottom: 1px solid var(--border); min-height: 56px; flex-wrap: wrap; }
.bulk { display: flex; align-items: center; gap: .6rem; font-size: .88rem; }
.bulk #bulkCount { font-weight: 700; color: var(--primary-2); }
.table-scroll { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.table th { text-align: left; font-weight: 600; font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); padding: .85rem 1rem; background: var(--bg-2); border-bottom: 1px solid var(--border); white-space: nowrap; }
.table th a:hover { color: var(--text); }
.table td { padding: .8rem 1rem; border-bottom: 1px solid var(--border); vertical-align: middle; }
.table tbody tr { transition: background .15s; cursor: pointer; }
.table tbody tr:hover { background: rgba(139,92,246,.06); }
.table tbody tr.is-selected { background: rgba(139,92,246,.1); }
.table tbody tr:last-child td { border-bottom: 0; }
.col-check { width: 40px; }
.col-check input { width: 17px; height: 17px; accent-color: var(--primary); cursor: pointer; }
.who { display: flex; align-items: center; gap: .65rem; }
.who strong { display: block; line-height: 1.25; }
.who small { color: var(--muted); font-size: .8rem; }
.yes { color: #86efac; font-weight: 600; }
.empty { text-align: center; color: var(--muted); padding: 3.5rem 1rem !important; cursor: default; }
.empty__icon { font-size: 2.4rem; margin-bottom: .5rem; }

.badge { display: inline-block; padding: .3rem .65rem; border-radius: 999px; font-size: .78rem; font-weight: 600; white-space: nowrap; border: 1px solid; }
.badge--en_attente { background: rgba(245,158,11,.12); color: #fcd34d; border-color: rgba(245,158,11,.35); }
.badge--en_cours { background: rgba(59,130,246,.12); color: #93c5fd; border-color: rgba(59,130,246,.35); }
.badge--acceptee { background: rgba(34,197,94,.12); color: #86efac; border-color: rgba(34,197,94,.35); }
.badge--refusee { background: rgba(239,68,68,.12); color: #fca5a5; border-color: rgba(239,68,68,.35); }
.poste { display: inline-block; font-size: .82rem; font-weight: 600; white-space: nowrap; padding: .25rem .55rem; border-radius: 7px; }
.poste--youtube { background: rgba(255,0,51,.12); color: #ff7a93; }
.poste--discord { background: rgba(88,101,242,.15); color: #a5adff; }
.poste--les_deux { background: rgba(34,211,238,.12); color: #67e8f9; }

.pager { display: flex; justify-content: center; gap: .35rem; padding: 1rem; border-top: 1px solid var(--border); }
.pager a { padding: .45rem .8rem; border-radius: 8px; border: 1px solid var(--border); font-size: .88rem; color: var(--muted); }
.pager a:hover { color: var(--text); border-color: var(--primary); }
.pager a.is-active { background: var(--grad-ui); color: #fff; border-color: transparent; }

/* ---------- Détail candidature ---------- */
.crumbs { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; gap: 1rem; flex-wrap: wrap; }
.crumbs > a { color: var(--muted); }
.crumbs > a:hover { color: var(--text); }
.crumbs__nav { display: flex; gap: .5rem; }
.profile { display: flex; align-items: center; gap: 1.2rem; margin-bottom: 1.8rem; }
.profile h1 { font-size: 2rem; margin-bottom: .45rem; }
.profile__tags { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; font-size: .88rem; }

.detail-grid { display: grid; grid-template-columns: 1fr 340px; gap: 1.4rem; align-items: start; }
@media (max-width: 1000px) { .detail-grid { grid-template-columns: 1fr; } .detail-side { order: -1; } }
.detail-col { display: flex; flex-direction: column; gap: 1.2rem; }
.detail-side { display: flex; flex-direction: column; gap: 1rem; position: sticky; top: 90px; }

.panel { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 1.5rem; }
.panel h2 { font-size: 1.15rem; margin-bottom: 1.1rem; }
.panel p { margin: 0 0 .9rem; }
.panel p:last-child { margin-bottom: 0; }
.panel--yt { border-left: 3px solid var(--yt); }
.panel--dc { border-left: 3px solid var(--discord); }
.q { color: var(--primary-2); font-weight: 600; font-size: .88rem; margin-bottom: .35rem !important; margin-top: 1.1rem !important; }
.q:first-of-type { margin-top: 0 !important; }
.level { display: inline-block; padding: .3rem .7rem; border-radius: 8px; background: var(--bg-2); border: 1px solid var(--border); font-weight: 600; font-size: .88rem; }
.dl { display: grid; grid-template-columns: 150px 1fr; gap: .7rem 1rem; margin: 0; }
.dl dt { color: var(--muted); font-size: .88rem; }
.dl dd { margin: 0; word-break: break-word; }
.dl a { color: var(--primary-2); }
.copy { background: var(--bg-2); border: 1px solid var(--border); padding: .2rem .5rem; border-radius: 6px; cursor: pointer; font-size: .9rem; }
.copy.copied::after { content: ' ✓ copié'; color: #86efac; font-family: var(--font-body); font-size: .8rem; }

.status-pick { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; margin-bottom: 1.2rem; }
.status-opt input { position: absolute; opacity: 0; pointer-events: none; }
.status-opt span { display: block; text-align: center; padding: .65rem .4rem; border-radius: 10px; border: 1px solid var(--border); background: var(--bg-2); font-size: .85rem; font-weight: 600; cursor: pointer; transition: .15s; }
.status-opt span:hover { border-color: var(--muted); }
.status-opt--en_attente input:checked + span { background: rgba(245,158,11,.15); border-color: var(--warn); color: #fcd34d; }
.status-opt--en_cours input:checked + span { background: rgba(59,130,246,.15); border-color: var(--info); color: #93c5fd; }
.status-opt--acceptee input:checked + span { background: rgba(34,197,94,.15); border-color: var(--ok); color: #86efac; }
.status-opt--refusee input:checked + span { background: rgba(239,68,68,.15); border-color: var(--ko); color: #fca5a5; }

.narrow { max-width: 520px; }
.narrow h1 { font-size: 1.8rem; }

/* ---------- Comptes ---------- */
.row-actions { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; }
.inline-form { display: flex; gap: .4rem; }
.inline-form .input { width: 130px; }
.accounts { display: flex; flex-direction: column; gap: 1rem; }
.account__head { display: flex; align-items: center; gap: .9rem; flex-wrap: wrap; margin-bottom: 1.1rem; }
.account__who { flex: 1; min-width: 160px; }
.account__who strong { display: block; font-size: 1.05rem; }
.account__poste { display: inline-block; margin-top: .25rem; font-size: .8rem; font-weight: 600; padding: .2rem .6rem; border-radius: 999px; background: rgba(163,230,53,.12); color: var(--lime); border: 1px solid rgba(163,230,53,.3); }
.account__dates { font-size: .8rem; text-align: right; }
.account__form { display: grid; grid-template-columns: 1fr 1fr auto; gap: .8rem; align-items: end; }
.account__form .field { margin: 0; }
.account__form .field label { font-size: .8rem; color: var(--muted); }
.account__form input { padding: .6rem .8rem !important; font-size: .9rem !important; }
.account__delete { margin-top: .9rem; padding-top: .9rem; border-top: 1px solid var(--border); text-align: right; }
@media (max-width: 700px) { .account__form { grid-template-columns: 1fr; } .account__dates { text-align: left; } }

/* ---------- Espace modération ---------- */
.kpis--3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 800px) { .kpis--3 { grid-template-columns: 1fr; } .kpis--3 .kpi:first-child { grid-column: auto; } }
.modo-section { margin-top: 2.6rem; }
.modo-title { font-size: 1.4rem; margin-bottom: .6rem; }
.annonces { display: flex; flex-direction: column; gap: .9rem; margin-top: 1rem; }
.annonce__head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; margin-bottom: .6rem; }
.annonce__head h3 { font-size: 1.1rem; margin: 0; }
.annonce__head .muted { font-size: .8rem; }
.annonce--important { border-color: rgba(163,230,53,.45); background: linear-gradient(135deg, rgba(163,230,53,.08), transparent 60%), var(--surface); }
.annonce form { margin-top: .4rem; }
.annonce__foot { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; }
.recidive { display: inline-block; margin-left: .35rem; font-size: .72rem; font-weight: 700; padding: .1rem .4rem; border-radius: 6px; background: rgba(239,68,68,.15); color: #fca5a5; border: 1px solid rgba(239,68,68,.4); }
.guide { display: grid; grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); gap: 1rem; margin-top: 1rem; }
.guide h3 { font-size: 1.15rem; margin-bottom: 1rem; }
.guide .checks { margin-top: 1rem; }
.bareme { width: 100%; border-collapse: collapse; font-size: .86rem; }
.bareme th { text-align: left; color: var(--muted); font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; padding: .5rem .4rem; border-bottom: 1px solid var(--border); }
.bareme td { padding: .55rem .4rem; border-bottom: 1px solid var(--border); vertical-align: top; }
.bareme b { color: #fca5a5; }
