/* Lutra, Serveurs Minecraft. Thème clair, couleurs franches, aucune ressource externe. */

@font-face {
  font-family: "Bricolage Grotesque";
  src: url("../fonts/bricolage-grotesque-latin-wght-normal.ada540c0e24a.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}
@font-face {
  font-family: "Figtree";
  src: url("../fonts/figtree-latin-wght-normal.202cfb54d4e6.woff2") format("woff2");
  font-weight: 300 900;
  font-display: swap;
}

:root {
  --bg: #F6F3EE;
  --surface: #FFFFFF;
  --surface-2: #FBF9F6;
  --sunk: #F3EFE9;
  --border: #E8E2D9;
  --border-strong: #D8CFC3;
  --ink: #1D1A17;
  --text-2: #3D3731;
  --muted: #685F56;
  --dim: #776D63;
  --accent: #FF7A2F;
  --accent-hover: #FF8C4A;
  --accent-soft: #FFEDE1;
  --accent-text: #B8490A;
  --on-accent: #1D1A17;
  --online: #1F8F52;
  --online-dot: #22C55E;
  --danger: #B42318;
  --danger-soft: #FDECEA;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(29, 26, 23, 0.05);
  --shadow-hover: 0 10px 28px rgba(29, 26, 23, 0.09);
  --display: "Bricolage Grotesque", system-ui, sans-serif;
  --body: "Figtree", system-ui, sans-serif;
  --mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
}

/* Couleurs de catégories et de tags : fond doux, texte foncé, couleur pleine */
.tone-orange { --t-bg: #FFEBDD; --t-fg: #A9460B; --t-solid: #FF7A2F; }
.tone-vert { --t-bg: #E3F4E5; --t-fg: #1E6A32; --t-solid: #2FA052; }
.tone-bleu { --t-bg: #E1EFFC; --t-fg: #1D5F96; --t-solid: #2F86D6; }
.tone-violet { --t-bg: #EEE8FC; --t-fg: #5B3AAE; --t-solid: #7C5CE0; }
.tone-rouge { --t-bg: #FDE6E3; --t-fg: #A3301E; --t-solid: #E04A35; }
.tone-rose { --t-bg: #FCE6F1; --t-fg: #9C2E66; --t-solid: #DB4C91; }
.tone-jaune { --t-bg: #FFF3CF; --t-fg: #7A5800; --t-solid: #E3A900; }
.tone-turquoise { --t-bg: #DDF4F0; --t-fg: #13665B; --t-solid: #1FA594; }
.tone-indigo { --t-bg: #E6E9FB; --t-fg: #3742A0; --t-solid: #5563D6; }
.tone-gris { --t-bg: #EEEBE7; --t-fg: #4D4640; --t-solid: #8A8178; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--body); font-size: 15px; line-height: 1.5; font-variant-numeric: tabular-nums; }
img { max-width: 100%; }
a { color: var(--ink); }
a:hover { color: var(--accent-text); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--display); letter-spacing: -0.02em; line-height: 1.12; margin: 0; }
p { margin: 0; }
fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
blockquote { margin: 0; }
details summary { cursor: pointer; color: var(--muted); padding: 4px 0; font-size: 14px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.pixel { image-rendering: pixelated; }
.muted { color: var(--muted); }
.dim { color: var(--dim); }
.small { font-size: 14px; }
.tiny { font-size: 12px; }
.mono { font-family: var(--mono); }
.stack { display: flex; flex-direction: column; gap: 10px; }
.stack-lg { display: flex; flex-direction: column; gap: 20px; }
.row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.hidden { display: none !important; }

/* ---------------------------------------------------------------- structure */

.app { display: flex; min-height: 100vh; }
.rail {
  position: sticky; top: 0; height: 100vh; flex: 0 0 68px; width: 68px; z-index: 30;
  background: var(--surface); border-right: 1px solid var(--border);
  display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 12px 0;
}
.rail-logo { width: 46px; height: 46px; border-radius: 13px; background: var(--accent-soft); display: flex; align-items: center; justify-content: center; margin-bottom: 12px; }
.rail-logo img { width: 36px; height: 28px; object-fit: contain; }
.rail-link { position: relative; width: 58px; padding: 8px 0; border-radius: 11px; text-decoration: none; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 10.5px; font-weight: 600; }
.rail-link svg { width: 20px; height: 20px; }
.rail-link:hover { color: var(--ink); background: var(--sunk); }
.rail-link.active { color: var(--accent-text); background: var(--accent-soft); }
.badge-dot { position: absolute; top: 5px; right: 13px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: var(--accent); color: var(--on-accent); font-size: 10px; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.rail-spacer { flex: 1; }
.avatar-btn { width: 42px; height: 42px; border-radius: 50%; padding: 0; overflow: hidden; border: 2px solid var(--surface); box-shadow: 0 0 0 2px var(--accent); background: var(--accent-soft); color: var(--accent-text); font: 700 14px var(--body); display: flex; align-items: center; justify-content: center; text-decoration: none; cursor: pointer; }
.avatar-btn img { width: 100%; height: 100%; object-fit: cover; }
.avatar-btn.login { box-shadow: none; border: 1px solid var(--border); background: var(--sunk); color: var(--muted); }
.avatar-btn.login svg { width: 20px; height: 20px; }
.content { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 32px; }
main.page { flex: 1; padding: 24px 0 48px; }
@media (max-width: 760px) {
  .app { flex-direction: column; }
  .rail { position: sticky; top: 0; height: auto; width: 100%; flex: none; flex-direction: row; padding: 6px 10px; gap: 2px; border-right: 0; border-bottom: 1px solid var(--border); overflow-x: auto; }
  .rail-logo { width: 40px; height: 40px; margin: 0 6px 0 0; flex: none; }
  .rail-link { width: 56px; flex: none; }
  .rail-spacer { flex: 1 0 8px; }
  .avatar-btn { width: 38px; height: 38px; flex: none; }
  .wrap { padding: 0 16px; }
}

/* ---------------------------------------------------------------- boutons et champs */

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 40px; padding: 0 16px; border-radius: 10px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--ink); font: 700 14px var(--body); text-decoration: none; cursor: pointer; white-space: nowrap; }
.btn:hover { color: var(--ink); background: var(--sunk); }
.btn svg { width: 17px; height: 17px; flex: none; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--on-accent); }
.btn-dark { background: var(--ink); border-color: var(--ink); color: #FFFFFF; }
.btn-dark:hover { background: #33302C; color: #FFFFFF; }
.btn-ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn-ghost:hover { background: var(--sunk); color: var(--ink); }
.btn-danger { background: var(--surface); border-color: #F0B8B0; color: var(--danger); }
.btn-danger:hover { background: var(--danger-soft); color: var(--danger); }
.btn-lg { min-height: 46px; font-size: 15px; padding: 0 22px; border-radius: 12px; }
.btn-block { width: 100%; }
.btn-sm { min-height: 34px; padding: 0 12px; font-size: 13px; border-radius: 9px; }
.btn-icon { width: 38px; min-height: 38px; padding: 0; background: transparent; border-color: transparent; color: var(--dim); }
.btn-icon:hover { background: var(--sunk); color: var(--ink); }

label { font-weight: 600; font-size: 13.5px; }
input[type=text], input[type=search], input[type=url], input[type=number], input[type=password], input[type=date], input:not([type]), select, textarea {
  width: 100%; min-height: 40px; padding: 8px 12px; border-radius: 10px; border: 1px solid var(--border-strong);
  background: var(--surface); color: var(--ink); font: 400 14.5px var(--body);
}
textarea { resize: vertical; line-height: 1.5; }
input::placeholder, textarea::placeholder { color: #9A9087; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: -1px; border-color: transparent; }
input[type=checkbox], input[type=radio] { width: 17px; height: 17px; accent-color: var(--accent); }
input[type=color] { width: 44px; height: 36px; padding: 2px; border: 1px solid var(--border-strong); border-radius: 8px; background: var(--surface); }
input[type=file] { color: var(--muted); font: 400 13.5px var(--body); }
input[type=file]::file-selector-button { margin-right: 10px; padding: 7px 12px; border-radius: 9px; border: 1px solid var(--border-strong); background: var(--sunk); color: var(--ink); font: 600 13px var(--body); cursor: pointer; }
.field { display: flex; flex-direction: column; gap: 5px; }
.field .help { font-size: 12.5px; color: var(--dim); }
.field .error, .errorlist { color: var(--danger); font-size: 12.5px; margin: 0; padding: 0; list-style: none; }
.check { display: flex; align-items: center; gap: 9px; min-height: 36px; font-weight: 500; font-size: 14px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 700px) { .form-grid { grid-template-columns: 1fr; } }

/* ---------------------------------------------------------------- éléments */

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.card-tight { padding: 14px 16px; }
.card h2 { font-size: 19px; font-weight: 700; }
.section-title { font-size: 24px; font-weight: 700; }
.eyebrow { font-size: 11.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--dim); }
.card h2.eyebrow { font-family: var(--body); font-size: 11.5px; letter-spacing: 0.08em; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; border: 1px solid transparent; background: var(--t-bg, var(--sunk)); color: var(--t-fg, var(--ink)); font-size: 13px; font-weight: 700; text-decoration: none; line-height: 1.2; }
.chip:hover { color: var(--t-fg, var(--ink)); border-color: var(--t-solid, var(--border-strong)); }
.chip.active { background: var(--t-solid, var(--ink)); color: #FFFFFF; }
.chip.active:hover { color: #FFFFFF; }
.chip .dot-c { width: 7px; height: 7px; border-radius: 50%; background: var(--t-solid); }
.chip.active .dot-c { background: #FFFFFF; }
.pill { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 700; background: var(--t-bg, var(--sunk)); color: var(--t-fg, var(--text-2)); white-space: nowrap; }
.pill-open { background: var(--sunk); color: var(--text-2); }
.pill-progress { background: #E1EFFC; color: #1D5F96; }
.pill-ok { background: #E3F4E5; color: #1E6A32; }
.pill-bad { background: var(--danger-soft); color: var(--danger); }
.count { font-size: 11px; padding: 1px 7px; border-radius: 999px; background: var(--sunk); color: var(--muted); margin-left: 6px; font-weight: 700; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #B9AFA5; flex: none; display: inline-block; }
.dot.on { background: var(--online-dot); box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.18); }
.verified { width: 17px; height: 17px; flex: none; }
.notice { border-radius: 12px; padding: 12px 14px; background: var(--surface-2); border: 1px solid var(--border); font-size: 14px; }
.notice-warn { border-color: #F3D9A8; background: #FFF8E8; }
.notice-error { border-color: #F3C3BC; background: var(--danger-soft); color: #7A1A11; }
.notice-ok { border-color: #BFE3C8; background: #EFF9F1; color: #164D27; }
.code-box { display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px; border-radius: 10px; background: var(--accent-soft); border: 1px dashed var(--accent); font: 700 20px var(--mono); color: var(--accent-text); }
.empty { border: 1px dashed var(--border-strong); border-radius: var(--radius); padding: 32px 20px; display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; color: var(--muted); background: var(--surface-2); }
.empty-icon { width: 42px; height: 42px; border-radius: 50%; background: var(--sunk); color: var(--dim); display: flex; align-items: center; justify-content: center; font: 800 20px var(--display); }
.empty strong { color: var(--ink); font-size: 15px; }

.messages { position: fixed; right: 18px; bottom: 18px; z-index: 80; display: flex; flex-direction: column; gap: 8px; max-width: min(400px, calc(100vw - 36px)); }
.message { padding: 12px 14px; border-radius: 12px; background: var(--ink); color: #FFFFFF; font-size: 14px; display: flex; gap: 10px; align-items: flex-start; box-shadow: 0 12px 30px rgba(29, 26, 23, 0.25); }
.message.error { background: #7A1A11; }
.message button { margin-left: auto; background: none; border: 0; color: #CFC6BD; cursor: pointer; font-size: 18px; line-height: 1; }

.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.tabs a, .tabs button { display: flex; align-items: center; min-height: 40px; padding: 0 12px; margin-bottom: -1px; border: 0; border-bottom: 2px solid transparent; background: none; color: var(--muted); font: 600 14px var(--body); text-decoration: none; cursor: pointer; }
.tabs a:hover { color: var(--ink); }
.tabs a.active, .tabs button.active { color: var(--ink); border-bottom-color: var(--accent); }
.pagination { display: flex; gap: 8px; justify-content: center; margin-top: 20px; align-items: center; }

/* ---------------------------------------------------------------- en-tête d'accueil */

.hero { position: relative; overflow: hidden; background: var(--surface); border-bottom: 1px solid var(--border); }
.hero-media { position: absolute; inset: 0 0 0 30%; pointer-events: none; }
.hero-media img, .hero-media video {
  width: 100%; height: 100%; object-fit: cover; display: block;
  /* Fondu : invisible à gauche, de plus en plus visible vers la droite */
  -webkit-mask-image: linear-gradient(to right, transparent 0%, rgba(0, 0, 0, 0.45) 35%, #000 80%);
  mask-image: linear-gradient(to right, transparent 0%, rgba(0, 0, 0, 0.45) 35%, #000 80%);
}
.hero-inner { position: relative; padding-top: 40px; padding-bottom: 40px; display: flex; flex-wrap: wrap; gap: 32px; align-items: center; }
.hero-text { flex: 1 1 480px; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.hero-brand { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: 13px; color: var(--accent-text); background: var(--accent-soft); border-radius: 999px; padding: 5px 12px 5px 6px; align-self: flex-start; }
.hero-brand img { width: 22px; height: 17px; object-fit: contain; }
.hero h1 { font-size: clamp(34px, 4.4vw, 50px); font-weight: 800; letter-spacing: -0.035em; line-height: 1; }
.hero h1 span { color: var(--accent); }
.hero-sub { font-size: 16.5px; color: var(--muted); max-width: 520px; }
.hero-search { display: flex; gap: 8px; max-width: 540px; background: var(--surface); border: 1px solid var(--border-strong); border-radius: 13px; padding: 5px; box-shadow: var(--shadow-hover); }
.hero-search input { border: 0; min-height: 40px; background: transparent; }
.hero-search input:focus { outline: none; }
.hero-chips { display: flex; gap: 6px; flex-wrap: wrap; max-width: 620px; }
.hero-card { flex: 0 1 340px; background: rgba(255, 255, 255, 0.96); border: 1px solid var(--border); border-radius: 16px; padding: 22px; display: flex; flex-direction: column; gap: 10px; box-shadow: var(--shadow-hover); }
.hero-card h2 { font-size: 21px; font-weight: 800; }
.hero-card p { color: var(--muted); font-size: 14px; }
.hero-stats { display: flex; gap: 18px; margin-top: 4px; }
.hero-stats div { display: flex; flex-direction: column; }
.hero-stats strong { font: 800 20px var(--display); }
.hero-stats span { font-size: 12px; color: var(--dim); }

/* ---------------------------------------------------------------- liste et cartes */

.listing { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; }
.filters { flex: 1 1 220px; max-width: 232px; display: flex; flex-direction: column; gap: 10px; position: sticky; top: 16px; }
.filters .card { display: flex; flex-direction: column; gap: 8px; padding: 14px; }
.listing-main { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
@media (max-width: 860px) { .filters { position: static; max-width: none; } }
.grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 24px 16px; padding-top: 8px; }

.card-banner { position: relative; height: 108px; background: var(--sunk); overflow: hidden; }
.card-banner > img { width: 100%; height: 108px; object-fit: cover; display: block; }
.banner-fallback { position: absolute; inset: 0; background: var(--t-bg, var(--sunk)); overflow: hidden; }
.banner-fallback img { position: absolute; right: -14px; bottom: -26px; width: 120px; height: 120px; opacity: 0.35; transform: rotate(-10deg); border-radius: 18px; }
.card-banner .pill { position: absolute; left: 10px; top: 10px; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08); }
.card-status { position: absolute; right: 10px; top: 10px; padding: 3px 9px; border-radius: 999px; background: rgba(255, 255, 255, 0.95); font-size: 11.5px; font-weight: 700; display: flex; align-items: center; gap: 6px; color: var(--ink); }
.card-body { padding: 0 14px 14px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.card-head { display: flex; align-items: flex-end; gap: 10px; margin-top: -24px; position: relative; }
.card-logo { width: 54px; height: 54px; border-radius: 13px; border: 3px solid var(--surface); background: var(--surface); object-fit: cover; flex: none; box-shadow: 0 2px 6px rgba(29, 26, 23, 0.12); }
.card-version { font-size: 11.5px; font-weight: 600; color: var(--dim); padding-bottom: 3px; }
.card-rank { margin-left: auto; font: 800 16px var(--display); color: var(--accent-text); padding-bottom: 2px; }
.card-name { display: flex; align-items: center; gap: 6px; }
.card-name a { font: 700 17.5px var(--display); text-decoration: none; letter-spacing: -0.01em; }
.card-desc { font-size: 13.5px; color: var(--muted); flex: 1; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-tags { display: flex; gap: 5px; flex-wrap: wrap; }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; border-top: 1px solid var(--border); padding-top: 9px; }
.stat { display: flex; flex-direction: column; gap: 0; }
.stat span:first-child { font-size: 11px; font-weight: 600; color: var(--dim); }
.stat span:last-child { font-weight: 700; font-size: 14.5px; }
.card-actions { display: flex; gap: 6px; }
.card-actions .btn { flex: 1; min-height: 38px; font-size: 13.5px; }

.partners { margin-top: 18px; background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 18px; display: flex; flex-direction: column; gap: 12px; }
.partners h2 { font-size: 19px; }
.partner-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; }
.partner { display: flex; align-items: center; gap: 12px; padding: 10px; text-decoration: none; border-radius: 12px; border: 1px solid var(--border); background: var(--surface-2); }
.partner:hover { border-color: var(--border-strong); background: var(--surface); }
.partner img { width: 44px; height: 44px; border-radius: 10px; object-fit: cover; }
.partner .txt { display: flex; flex-direction: column; }
.partner .txt span:first-child { font-weight: 700; color: var(--ink); }

.rank-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.rank-row { display: flex; align-items: center; gap: 14px; background: var(--surface); border: 1px solid var(--border); border-radius: 13px; padding: 10px 14px; flex-wrap: wrap; box-shadow: var(--shadow); }
.rank-num { width: 40px; text-align: center; font: 800 22px var(--display); color: var(--dim); }
.rank-row:nth-child(1) .rank-num { color: #D99A00; }
.rank-row:nth-child(2) .rank-num { color: #8A9099; }
.rank-row:nth-child(3) .rank-num { color: #B8682E; }
.rank-logo { width: 50px; height: 50px; border-radius: 11px; object-fit: cover; }
.rank-info { flex: 1 1 240px; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.rank-info a { font-weight: 700; font-size: 16.5px; text-decoration: none; }
.rank-stats { display: flex; gap: 20px; align-items: center; }

/* ---------------------------------------------------------------- fiche serveur */

.detail-banner { height: 250px; border-radius: 18px; overflow: hidden; border: 1px solid var(--border); background: var(--sunk); position: relative; }
.detail-banner > img { width: 100%; height: 100%; object-fit: cover; display: block; }
.detail-banner .banner-fallback img { width: 240px; height: 240px; right: 6%; bottom: -60px; }
.detail-head { display: flex; gap: 20px; align-items: flex-end; flex-wrap: wrap; padding: 0 22px; }
.detail-logo { width: 112px; height: 112px; margin-top: -56px; border-radius: 22px; border: 4px solid var(--bg); position: relative; object-fit: cover; flex: none; background: var(--surface); box-shadow: 0 4px 14px rgba(29, 26, 23, 0.15); }
.detail-title { flex: 1 1 320px; min-width: 0; display: flex; flex-direction: column; gap: 6px; padding-top: 12px; }
.detail-title h1 { font-size: 38px; font-weight: 800; letter-spacing: -0.035em; line-height: 1; }
.detail-actions { display: flex; gap: 8px; flex-wrap: wrap; padding-top: 12px; }
.copy-btn { font-family: var(--mono); font-weight: 500; }
.detail-layout { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; margin-top: 26px; }
.detail-main { flex: 999 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 18px; }
.detail-side { flex: 1 1 260px; max-width: 320px; display: flex; flex-direction: column; gap: 12px; }
@media (max-width: 860px) { .detail-side { max-width: none; } .detail-banner { height: 170px; } .detail-logo { width: 88px; height: 88px; margin-top: -44px; } .detail-title h1 { font-size: 30px; } }
.prose { font-size: 15px; line-height: 1.65; color: var(--text-2); white-space: pre-line; overflow-wrap: anywhere; }
.side-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 0; }
.side-stats dt { font-size: 11.5px; font-weight: 600; color: var(--dim); }
.side-stats dd { margin: 1px 0 0; font-weight: 700; font-size: 16px; }
.chart { width: 100%; height: 52px; display: block; }
.chart rect { fill: #F6D7C2; }
.chart rect.last { fill: var(--accent); }
.ann { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.ann-images { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2px; }
.ann-images img { width: 100%; height: 140px; object-fit: cover; display: block; }
.ann-body { padding: 16px 18px; display: flex; flex-direction: column; gap: 5px; }
.review { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 18px; display: flex; flex-direction: column; gap: 10px; }
.review-head { display: flex; align-items: center; gap: 10px; }
.review-avatar { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; background: var(--accent-soft); flex: none; display: flex; align-items: center; justify-content: center; color: var(--accent-text); font-weight: 700; font-size: 13px; }
.stars { color: var(--accent-text); font-weight: 800; white-space: nowrap; }
.reply { background: var(--sunk); border-radius: 12px; padding: 12px 14px; display: flex; gap: 10px; }
.reply img { width: 30px; height: 30px; border-radius: 8px; object-fit: cover; flex: none; }
.reply strong { font-size: 13.5px; }
.rating-input { display: flex; gap: 6px; flex-wrap: wrap; }
.rating-input input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.rating-input label { display: flex; align-items: center; justify-content: center; min-width: 44px; height: 40px; border-radius: 10px; border: 1px solid var(--border-strong); background: var(--surface); cursor: pointer; font-weight: 700; }
.rating-input input:checked + label { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.rating-input input:focus-visible + label { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------------------------------------------------------------- vote */

.narrow { max-width: 540px; margin: 0 auto; }
.vote-card { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; overflow: hidden; box-shadow: var(--shadow-hover); }
.vote-card .card-banner, .vote-card .card-banner > img { height: 130px; }
.vote-inner { padding: 0 20px 22px; display: flex; flex-direction: column; gap: 16px; }
.vote-head { display: flex; align-items: flex-end; gap: 12px; margin-top: -30px; position: relative; }
.vote-head img { width: 70px; height: 70px; border-radius: 16px; border: 4px solid var(--surface); object-fit: cover; background: var(--surface); box-shadow: 0 2px 8px rgba(29, 26, 23, 0.12); }
.vote-head h1 { font-size: 27px; font-weight: 800; }
.success-box { display: flex; gap: 12px; align-items: center; background: #EFF9F1; border: 1px solid #BFE3C8; border-radius: 12px; padding: 12px; }
.success-box .ic { width: 36px; height: 36px; border-radius: 50%; background: var(--online); color: #FFFFFF; display: flex; align-items: center; justify-content: center; flex: none; }

/* ---------------------------------------------------------------- étapes d'ajout */

.steps { display: flex; gap: 6px; flex-wrap: wrap; list-style: none; padding: 0; margin: 0; }
.steps li { display: flex; align-items: center; gap: 7px; padding: 6px 12px 6px 6px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); color: var(--dim); font-size: 13px; font-weight: 600; }
.steps li.done { color: var(--online); }
.steps li.current { border-color: var(--accent); color: var(--ink); }
.steps .n { width: 20px; height: 20px; border-radius: 50%; background: var(--sunk); display: flex; align-items: center; justify-content: center; font-size: 11px; }
.steps li.current .n { background: var(--accent); color: var(--on-accent); }
.steps li.done .n { background: #E3F4E5; }

/* ---------------------------------------------------------------- choix par étapes (signalement, ticket) */

.picker { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; box-shadow: var(--shadow-hover); overflow: hidden; }
.picker-head { padding: 20px 22px 14px; display: flex; flex-direction: column; gap: 6px; border-bottom: 1px solid var(--border); }
.picker-head h1 { font-size: 22px; font-weight: 800; }
.trail { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; font-size: 13px; color: var(--dim); }
.trail a { color: var(--muted); }
.options { list-style: none; margin: 0; padding: 8px; display: flex; flex-direction: column; gap: 2px; }
.option { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 12px; text-decoration: none; color: var(--ink); }
.option:hover { background: var(--sunk); color: var(--ink); }
.option .ic { width: 34px; height: 34px; border-radius: 10px; background: var(--t-bg); color: var(--t-fg); display: flex; align-items: center; justify-content: center; flex: none; font: 800 14px var(--display); }
.option .txt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.option .txt strong { font-size: 14.5px; }
.option .txt span { font-size: 13px; color: var(--dim); }
.option .chev { color: var(--dim); font-size: 18px; }
.picker-body { padding: 18px 22px 22px; display: flex; flex-direction: column; gap: 14px; }
.picker-foot { padding: 12px 22px; border-top: 1px solid var(--border); background: var(--surface-2); display: flex; justify-content: space-between; align-items: center; gap: 10px; }

/* ---------------------------------------------------------------- support : chat */

.support { display: grid; grid-template-columns: 290px minmax(0, 1fr); gap: 14px; height: calc(100vh - 110px); min-height: 520px; }
.support-list { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; display: flex; flex-direction: column; overflow: hidden; }
.support-list-head { padding: 14px; display: flex; flex-direction: column; gap: 10px; border-bottom: 1px solid var(--border); }
.support-list-head h1 { font-size: 20px; font-weight: 800; }
.channels { list-style: none; margin: 0; padding: 6px; overflow-y: auto; flex: 1; display: flex; flex-direction: column; gap: 2px; }
.channel { display: flex; gap: 10px; align-items: flex-start; padding: 10px; border-radius: 11px; text-decoration: none; color: var(--ink); }
.channel:hover { background: var(--sunk); color: var(--ink); }
.channel.active { background: var(--accent-soft); }
.channel .hash { width: 30px; height: 30px; border-radius: 9px; background: var(--sunk); color: var(--dim); display: flex; align-items: center; justify-content: center; font: 800 14px var(--display); flex: none; }
.channel.active .hash { background: var(--surface); color: var(--accent-text); }
.channel .txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.channel .txt strong { font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.channel .txt span { font-size: 12px; color: var(--dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.channel .unread { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); margin-top: 6px; flex: none; }
.chat { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; display: flex; flex-direction: column; overflow: hidden; min-width: 0; }
.split > .chat { height: calc(100vh - 60px); min-height: 520px; }
.chat-head { padding: 12px 16px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.chat-head .hash { width: 34px; height: 34px; border-radius: 10px; background: var(--accent-soft); color: var(--accent-text); display: flex; align-items: center; justify-content: center; font: 800 16px var(--display); flex: none; }
.chat-head h2 { font-size: 17px; font-weight: 700; }
.chat-scroll { flex: 1; overflow-y: auto; padding: 16px 4px 8px; }
.chat-intro { margin: 0 16px 14px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface-2); padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; }
.chat-intro dl { margin: 0; display: flex; flex-direction: column; gap: 8px; }
.chat-intro dt { font-size: 12px; font-weight: 700; color: var(--dim); }
.chat-intro dd { margin: 0; font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.msg { display: flex; gap: 12px; padding: 4px 16px; }
.msg:hover { background: var(--surface-2); }
.msg.first { margin-top: 10px; }
.msg .av { width: 36px; height: 36px; border-radius: 50%; flex: none; background: var(--sunk); color: var(--muted); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; overflow: hidden; }
.msg .av img { width: 100%; height: 100%; object-fit: cover; }
.msg.is-staff .av { background: var(--accent); color: var(--on-accent); }
.msg:not(.first) .av { visibility: hidden; height: 0; }
.msg .bd { flex: 1; min-width: 0; }
.msg .meta { display: flex; align-items: baseline; gap: 8px; }
.msg .meta strong { font-size: 14px; }
.msg.is-staff .meta strong { color: var(--accent-text); }
.msg .meta .tag-staff { font-size: 10px; font-weight: 800; letter-spacing: 0.05em; background: var(--accent); color: var(--on-accent); padding: 1px 5px; border-radius: 4px; }
.msg .meta time { font-size: 11.5px; color: var(--dim); }
.msg:not(.first) .meta { display: none; }
.msg .text { font-size: 14.5px; line-height: 1.5; white-space: pre-wrap; overflow-wrap: anywhere; color: var(--text-2); }
.day-sep { display: flex; align-items: center; gap: 10px; margin: 14px 16px 4px; font-size: 11.5px; font-weight: 700; color: var(--dim); }
.day-sep::before, .day-sep::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.composer { padding: 10px 14px 14px; }
.composer form { display: flex; gap: 8px; align-items: flex-end; background: var(--sunk); border-radius: 13px; padding: 6px 6px 6px 12px; }
.composer textarea { border: 0; background: transparent; min-height: 38px; max-height: 180px; resize: none; padding: 9px 0; }
.composer textarea:focus { outline: none; }
.composer .hint { font-size: 11.5px; color: var(--dim); margin: 6px 4px 0; }
.chat-closed { margin: 10px 14px 14px; padding: 12px; border-radius: 12px; background: var(--sunk); text-align: center; font-size: 14px; color: var(--muted); }
.chat-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; color: var(--muted); text-align: center; padding: 30px; }
@media (max-width: 860px) {
  .support { grid-template-columns: 1fr; height: auto; }
  .support.has-chat .support-list { display: none; }
  .chat { height: calc(100vh - 120px); }
}

/* ---------------------------------------------------------------- panneau compte */

.drawer-backdrop { position: fixed; inset: 0; background: rgba(29, 26, 23, 0.35); z-index: 40; }
.drawer { position: fixed; top: 0; bottom: 0; left: 68px; width: min(440px, calc(100vw - 68px)); z-index: 50; background: var(--surface); border-right: 1px solid var(--border); display: flex; flex-direction: column; box-shadow: 24px 0 60px rgba(29, 26, 23, 0.15); }
@media (max-width: 760px) { .drawer { left: 0; width: 100vw; } }
.drawer-head { padding: 18px 18px 14px; display: flex; align-items: center; gap: 12px; border-bottom: 1px solid var(--border); }
.drawer-head .av { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; background: var(--accent-soft); flex: none; display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--accent-text); }
.drawer-head .name { font: 800 19px var(--display); }
.drawer .tabs { padding: 6px 12px 0; }
.drawer-inner { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.drawer-body { flex: 1; overflow: auto; padding: 16px; display: flex; flex-direction: column; gap: 8px; background: var(--surface-2); }
.panel-page { max-width: 700px; }
.item { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 12px; display: flex; gap: 10px; align-items: center; }
.item.col { flex-direction: column; align-items: stretch; }
a.item, a.kpi { text-decoration: none; color: var(--ink); }
a.item:hover { border-color: var(--border-strong); }
.item-logo { width: 42px; height: 42px; border-radius: 10px; object-fit: cover; flex: none; background: var(--sunk); }
.item-title { font-weight: 700; }
.item-meta { font-size: 12.5px; color: var(--dim); }
.ok-text { color: var(--online); font-weight: 600; font-size: 13px; }
.warn-text { color: var(--accent-text); font-weight: 600; font-size: 13px; }
.danger-zone { border: 1px solid #F3C3BC; background: #FFF8F7; border-radius: 12px; padding: 14px; display: flex; flex-direction: column; gap: 8px; }

/* ---------------------------------------------------------------- pages (règlement, légal) */

.doc-head { background: var(--surface); border-bottom: 1px solid var(--border); }
.doc-head .wrap { padding-top: 34px; padding-bottom: 30px; display: flex; flex-direction: column; gap: 8px; }
.doc-head h1 { font-size: 38px; font-weight: 800; letter-spacing: -0.03em; }
.doc-head p { color: var(--muted); font-size: 16px; max-width: 640px; }
.doc { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 28px; align-items: start; }
.doc-nav { position: sticky; top: 16px; display: flex; flex-direction: column; gap: 16px; }
.doc-nav nav { display: flex; flex-direction: column; gap: 2px; }
.doc-nav a { padding: 7px 10px; border-radius: 9px; text-decoration: none; font-size: 14px; color: var(--muted); }
.doc-nav a:hover { background: var(--sunk); color: var(--ink); }
.doc-nav a.active { background: var(--accent-soft); color: var(--accent-text); font-weight: 700; }
.doc-nav .toc a { font-size: 13px; padding: 5px 10px; border-left: 2px solid var(--border); border-radius: 0; }
.doc-body { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 30px 36px; box-shadow: var(--shadow); }
@media (max-width: 860px) { .doc { grid-template-columns: 1fr; } .doc-nav { position: static; } .doc-body { padding: 22px 18px; } }
.rich { font-size: 15.5px; line-height: 1.7; color: var(--text-2); max-width: 760px; }
.rich h2 { font-size: 22px; margin: 30px 0 10px; color: var(--ink); scroll-margin-top: 20px; }
.rich h2:first-child { margin-top: 0; }
.rich h3 { font-size: 17px; margin: 20px 0 8px; color: var(--ink); }
.rich p { margin: 0 0 12px; }
.rich ul, .rich ol { margin: 0 0 14px; padding-left: 22px; }
.rich li { margin: 4px 0; }
.rich li::marker { color: var(--accent); }
.rich strong { color: var(--ink); }
.rich a { color: var(--accent-text); }
.callout { margin: 4px 0 16px; padding: 12px 16px; border-radius: 12px; background: var(--accent-soft); color: #5C2A0A; }
.c-orange { color: #C2510D; } .c-vert { color: #1E7A3A; } .c-bleu { color: #1D5F96; } .c-violet { color: #5B3AAE; }
.c-rouge { color: #B42318; } .c-rose { color: #A8306D; } .c-jaune { color: #8A6400; } .c-turquoise { color: #13665B; }
.c-gris { color: #6E655C; } .c-indigo { color: #3742A0; }

/* ---------------------------------------------------------------- pied de page */

.footer { border-top: 1px solid var(--border); background: var(--surface); }
.footer .wrap { padding-top: 20px; padding-bottom: 20px; display: flex; flex-wrap: wrap; gap: 16px; justify-content: space-between; align-items: center; }
.footer nav { display: flex; gap: 18px; flex-wrap: wrap; font-size: 13.5px; }
.footer nav a { color: var(--muted); text-decoration: none; }
.footer nav a:hover { color: var(--ink); }
.footer p { font-size: 13.5px; color: var(--dim); }

/* ---------------------------------------------------------------- tableaux, code */

code { font-family: var(--mono); font-size: 0.9em; background: var(--sunk); padding: 1px 6px; border-radius: 6px; color: var(--accent-text); }
pre { background: var(--ink); border-radius: 12px; padding: 14px 16px; overflow-x: auto; font: 13px/1.6 var(--mono); color: #F3EFE9; }
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
th, td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--border); vertical-align: top; }
th { font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--dim); background: var(--surface-2); }
tr:last-child td { border-bottom: 0; }
tr.unread td:first-child { box-shadow: inset 3px 0 0 var(--accent); }

/* ---------------------------------------------------------------- fenêtre de connexion staff */

.modal-backdrop { position: fixed; inset: 0; background: rgba(29, 26, 23, 0.55); z-index: 90; display: flex; align-items: center; justify-content: center; padding: 20px; }
.modal { width: min(380px, 100%); background: var(--surface); border-radius: 16px; padding: 22px; display: flex; flex-direction: column; gap: 12px; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.3); }
.modal h2 { font: 700 14px var(--mono); letter-spacing: 0.04em; color: var(--accent-text); }

/* ---------------------------------------------------------------- terminal staff */

.staff-body { background: var(--bg); }
.staff { display: flex; min-height: 100vh; }
.staff-side { flex: 0 0 220px; background: var(--ink); color: #E9E3DB; padding: 16px 10px; display: flex; flex-direction: column; gap: 1px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.staff-brand { font: 700 13px var(--mono); color: var(--accent); padding: 6px 10px 14px; letter-spacing: 0.05em; }
.staff-brand span { display: block; color: #A79D93; font-weight: 400; font-size: 11.5px; margin-top: 4px; }
.staff-side a { display: flex; justify-content: space-between; align-items: center; padding: 8px 10px; border-radius: 8px; text-decoration: none; color: #CFC6BD; font-size: 13.5px; font-weight: 600; }
.staff-side a:hover { background: #2C2824; color: #FFFFFF; }
.staff-side a.active { background: #3A342E; color: #FFFFFF; }
.staff-side .sep { height: 1px; background: #3A342E; margin: 8px 6px; }
.staff-side .grp { font-size: 10.5px; letter-spacing: 0.08em; text-transform: uppercase; color: #8F857B; padding: 8px 10px 4px; }
.staff-side .btn { background: transparent; color: #CFC6BD; border-color: #3A342E; }
.staff-main { flex: 1; min-width: 0; padding: 22px 28px 56px; display: flex; flex-direction: column; gap: 16px; }
.staff-main h1 { font-size: 25px; }
.kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
.kpi { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 2px; }
.kpi span:first-child { font-size: 12px; color: var(--dim); font-weight: 600; }
.kpi span:last-child { font: 800 26px var(--display); }
.kpi.hot span:last-child { color: var(--accent-text); }
.staff-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(310px, 1fr)); gap: 14px; align-items: start; }
.toolbar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.toolbar input, .toolbar select { width: auto; min-width: 200px; }
.row select { width: auto; }
.logline { font: 12.5px/1.55 var(--mono); color: var(--text-2); }
.logline .who { color: var(--accent-text); }
.note { padding: 8px 12px; background: #FFF8E8; border: 1px solid #F3D9A8; border-radius: 10px; }
.role { font: 700 10.5px var(--mono); padding: 2px 7px; border-radius: 6px; background: var(--sunk); color: var(--text-2); text-transform: uppercase; }
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.media-grid .item img { width: 100%; height: 100px; object-fit: cover; border-radius: 8px; }
.tree { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.tree li a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; background: var(--surface); border: 1px solid var(--border); border-radius: 10px; text-decoration: none; color: var(--ink); }
.tree li a:hover { border-color: var(--border-strong); }
.editor-bar { display: flex; gap: 4px; flex-wrap: wrap; padding: 6px; background: var(--sunk); border: 1px solid var(--border-strong); border-bottom: 0; border-radius: 10px 10px 0 0; }
.editor-bar button { min-height: 30px; min-width: 30px; padding: 0 8px; border-radius: 7px; border: 1px solid transparent; background: transparent; font: 700 13px var(--body); cursor: pointer; color: var(--ink); }
.editor-bar button:hover { background: var(--surface); border-color: var(--border); }
.editor-bar .sw { width: 22px; min-width: 22px; height: 22px; min-height: 22px; padding: 0; border-radius: 50%; background: var(--t-solid); align-self: center; }
.editor-area { border-radius: 0 0 10px 10px; font: 14px/1.6 var(--mono); min-height: 420px; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 340px); gap: 14px; align-items: start; }
.split.even { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
@media (max-width: 1100px) { .split { grid-template-columns: 1fr; } }
@media (max-width: 860px) {
  .staff { flex-direction: column; }
  .staff-side { position: static; height: auto; flex: none; flex-direction: row; flex-wrap: wrap; }
  .staff-main { padding: 16px 14px 40px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
.support-back { display: none; }
@media (max-width: 860px) { .support-back { display: inline-flex; } }
.picker-body h2 { font-size: 18px; }
.tree li.d1 { margin-left: 26px; }
.tree li.d2 { margin-left: 52px; }
.tree li.d3 { margin-left: 78px; }
.item > .row { flex: 1; min-width: 0; flex-wrap: nowrap; }
.drawer .tabs a { padding: 0 9px; font-size: 13.5px; }

/* ================================================================ thème sombre (par défaut) */

.ic-moon, .t-light { display: none; }
html[data-theme="light"] .ic-sun, html[data-theme="light"] .t-dark { display: none; }
html[data-theme="light"] .ic-moon, html[data-theme="light"] .t-light { display: inline; }
.theme-toggle { border: 0; background: transparent; cursor: pointer; font-family: var(--body); }
html[data-theme="light"] { color-scheme: light; }

/* ---------------------------------------------------------------- cartes de serveurs */
.server-card { position: relative; isolation: isolate; display: flex; flex-direction: column; gap: 10px; padding: 18px 18px 14px; min-height: 218px; border-radius: 16px; background: var(--surface); border: 1.5px solid color-mix(in srgb, var(--t-solid, var(--border-strong)) 45%, var(--border)); box-shadow: var(--shadow); transition: box-shadow 0.15s, transform 0.15s, border-color 0.15s; }
.server-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); border-color: color-mix(in srgb, var(--t-solid, var(--accent)) 80%, transparent); }
.server-card.no-banner { background: var(--sunk); }
.sc-bg { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; border-radius: 15px; opacity: 0.22; }
.server-card.has-banner::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: 15px; background: linear-gradient(100deg, var(--surface) 25%, color-mix(in srgb, var(--surface) 55%, transparent) 70%, color-mix(in srgb, var(--surface) 25%, transparent)); }
.sc-rating { position: absolute; top: -12px; left: 14px; display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px 2px 7px; border-radius: 999px; background: var(--surface); border: 1.5px solid color-mix(in srgb, var(--t-solid, var(--border-strong)) 45%, var(--border)); font-size: 12px; white-space: nowrap; box-shadow: var(--shadow); }
.sc-rating strong { color: #D99A00; font-size: 12.5px; }
.sc-count { color: var(--dim); font-size: 11.5px; }
.sc-stars { display: inline-flex; gap: 1px; }
.st { display: block; }
.st-bg { fill: var(--border-strong); }
.st-fg { fill: #F5B800; }
.sc-corner { position: absolute; top: -1.5px; right: -1.5px; width: 46px; height: 46px; border-top-right-radius: 16px; background: linear-gradient(225deg, var(--t-solid, var(--accent)) 50%, transparent 50%); color: #FFFFFF; overflow: hidden; }
.sc-corner svg { position: absolute; top: 5px; right: 5px; width: 16px; height: 16px; fill: #FFFFFF; }
.sc-corner.sc-top { background: linear-gradient(225deg, #E3A900 50%, transparent 50%); font: 800 11px var(--display); text-align: right; padding: 6px 6px 0 0; }
.sc-head { display: flex; gap: 14px; align-items: flex-start; padding-right: 26px; }
.sc-logo { position: relative; flex: none; width: 64px; height: 64px; }
.sc-logo img { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; display: block; background: var(--surface); box-shadow: 0 0 0 2px var(--surface), 0 3px 10px rgba(0, 0, 0, 0.18); }
.sc-dot { position: absolute; right: 1px; bottom: 1px; width: 15px; height: 15px; border-radius: 50%; background: #8A8178; border: 3px solid var(--surface); }
.sc-dot.on { background: var(--online-dot); }
.sc-id { min-width: 0; display: flex; flex-direction: column; gap: 4px; padding-top: 2px; }
.sc-name { display: flex; align-items: center; gap: 6px; min-width: 0; }
.sc-name a { font: 700 17px var(--display); letter-spacing: -0.01em; text-decoration: none; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc-name a::after { content: ""; position: absolute; inset: 0; z-index: 0; }
.sc-name svg { flex: none; width: 17px; height: 17px; }
.sc-rank { font: 800 13px var(--display); color: var(--accent-text); }
.sc-meta { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; font-size: 12.5px; color: var(--muted); }
.sc-meta svg { width: 14px; height: 14px; }
.sc-meta strong { color: var(--ink); }
.sc-meta .sep { color: var(--dim); }
.sc-pills { display: flex; gap: 5px; flex-wrap: wrap; }
.sc-pills:empty { display: none; }
.spill { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 700; border: 1px solid; }
.spill-on { color: var(--online); border-color: color-mix(in srgb, var(--online-dot) 55%, transparent); background: color-mix(in srgb, var(--online-dot) 12%, transparent); }
.spill .d { width: 6px; height: 6px; border-radius: 50%; background: var(--online-dot); }
.sc-tags { display: flex; gap: 5px; flex-wrap: wrap; align-items: center; }
.sc-cat { padding: 3px 10px; border-radius: 7px; font-size: 12px; font-weight: 700; background: var(--t-bg); color: var(--t-fg); border: 1px solid color-mix(in srgb, var(--t-solid) 35%, transparent); }
.sc-tag { padding: 2px 7px; border-radius: 6px; font-size: 11px; font-weight: 600; background: color-mix(in srgb, var(--ink) 7%, transparent); color: var(--text-2); }
.sc-tag.is-colored { background: var(--t-bg); color: var(--t-fg); }
.sc-desc { font-size: 13.5px; color: var(--text-2); flex: 1; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.sc-foot { display: flex; justify-content: flex-end; gap: 6px; position: relative; z-index: 1; }
.sc-foot .btn { min-width: 86px; }
.sc-see { background: color-mix(in srgb, var(--surface) 70%, transparent); }
.server-card.no-banner .sc-dot, .server-card.no-banner .sc-logo img { box-shadow: 0 0 0 2px var(--sunk), 0 3px 10px rgba(0, 0, 0, 0.18); }
.server-card.no-banner .sc-dot { border-color: var(--sunk); }
@media (max-width: 420px) { .grid-cards { grid-template-columns: 1fr; } }

/* ---------------------------------------------------------------- statistiques */
.stats-page { display: flex; flex-direction: column; gap: 16px; }
.stats-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.seg { display: inline-flex; padding: 3px; gap: 2px; background: var(--sunk); border-radius: 10px; }
.seg a { padding: 6px 12px; border-radius: 8px; font-size: 13px; font-weight: 700; color: var(--muted); text-decoration: none; }
.seg a:hover { color: var(--ink); }
.seg a.active { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.stats-main { padding: 0; overflow: hidden; }
.kpi-tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-bottom: 1px solid var(--border); }
.kpi-tab { position: relative; display: flex; flex-direction: column; gap: 2px; padding: 14px 16px 13px; text-decoration: none; color: var(--ink); border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); margin-bottom: -1px; }
.kpi-tab:nth-child(4n) { border-right: 0; }
.kpi-tab:hover { background: var(--surface-2); color: var(--ink); }
.kpi-tab.active { background: var(--surface-2); }
.kpi-tab.active::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--accent); }
.kpi-label { font-size: 12px; font-weight: 600; color: var(--dim); }
.kpi-value { font: 800 24px var(--display); letter-spacing: -0.02em; }
.delta { align-self: flex-start; font-size: 11.5px; font-weight: 700; padding: 1px 7px; border-radius: 999px; background: var(--sunk); color: var(--muted); display: inline-flex; gap: 4px; align-items: center; }
.delta span { font-size: 8px; }
.delta.up { background: #E3F4E5; color: #1E6A32; }
.delta.down { background: #FDE6E3; color: #A3301E; }
.chart-wrap { position: relative; padding: 14px 16px 10px; }
.chart-fig { margin: 0; }
.lchart { width: 100%; height: auto; display: block; overflow: visible; }
.lchart .grid { stroke: var(--border); stroke-width: 1; vector-effect: non-scaling-stroke; }
.lchart .axis { fill: var(--dim); font: 600 9px var(--body); }
.lchart .line { fill: none; stroke: var(--accent); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.lchart .prev { fill: none; stroke: var(--border-strong); stroke-width: 2; stroke-dasharray: 5 5; vector-effect: non-scaling-stroke; }
.lchart .area { fill: var(--accent); opacity: 0.1; }
.lchart .pt { fill: var(--surface); stroke: var(--accent); stroke-width: 2; vector-effect: non-scaling-stroke; }
.lchart .hit { fill: transparent; cursor: crosshair; }
.lchart .hit.on { fill: var(--ink); opacity: 0.05; }
.c-rank .line { stroke: #7C5CE0; }
.c-rank .pt { stroke: #7C5CE0; }
.chart-legend { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.lg { display: inline-block; width: 16px; height: 3px; border-radius: 2px; background: var(--accent); }
.lg-prev { margin-left: 12px; background: none; border-top: 2px dashed var(--border-strong); height: 0; }
.chart-tip { position: absolute; top: 6px; pointer-events: none; display: flex; flex-direction: column; gap: 1px; padding: 7px 10px; border-radius: 9px; background: var(--ink); color: var(--bg); font-size: 12px; white-space: nowrap; box-shadow: var(--shadow-hover); }
.chart-tip strong { font-size: 15px; }
.chart-tip .tip-d, .chart-tip .tip-p { opacity: 0.75; }
.stats-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.stats-grid .span-2 { grid-column: span 2; }
.h-card { font-size: 17px; }
.src-list, .funnel { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 11px; }
.hbar { display: block; width: 100%; height: 6px; margin-top: 5px; }
.hbar-lg { height: 10px; }
.hbar .bg { fill: var(--sunk); }
.hbar .fg { fill: var(--accent); }
.src_search .hbar .fg { fill: #2F86D6; }
.src_ai .hbar .fg { fill: #7C5CE0; }
.src_discord .hbar .fg { fill: #5563D6; }
.src_social .hbar .fg { fill: #DB4C91; }
.src_direct .hbar .fg { fill: #1FA594; }
.src_other .hbar .fg { fill: #8A8178; }
.funnel li:nth-child(2) .hbar .fg { fill: #FF9A5C; }
.funnel li:nth-child(3) .hbar .fg { fill: #1FA594; }
.funnel li:nth-child(4) .hbar .fg { fill: #2FA052; }
.stats-table { width: 100%; border-collapse: collapse; }
.stats-table th { text-align: left; font-size: 12px; color: var(--dim); font-weight: 600; padding: 0 0 6px; }
.stats-table td { padding: 8px 0; border-top: 1px solid var(--border); }
.stats-how summary { font-weight: 700; color: var(--ink); }
.stats-how ul { margin: 10px 0 0; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }
.mini-kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.mini-kpi { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); }
.mini-kpi .kpi-value { font-size: 20px; }
.mini-spark .lchart .axis { display: none; }
.mini-spark .lchart .pt { display: none; }
@media (max-width: 900px) {
  .kpi-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpi-tab:nth-child(2n) { border-right: 0; }
  .kpi-tab:nth-child(4n) { border-right: 0; }
  .stats-grid { grid-template-columns: 1fr; }
  .stats-grid .span-2 { grid-column: auto; }
  .lchart .axis { font-size: 15px; }
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #121117;
  --surface: #1B1A22;
  --surface-2: #17161D;
  --sunk: #24222C;
  --border: #2D2B36;
  --border-strong: #3B3846;
  --ink: #F3F1F8;
  --text-2: #D9D5E3;
  --muted: #ABA6BA;
  --dim: #918BA2;
  --accent: #FF7A2F;
  --accent-hover: #FF8C4A;
  --accent-soft: rgba(255, 122, 47, 0.14);
  --accent-text: #FF9F63;
  --on-accent: #1D1A17;
  --online: #4ADE80;
  --danger: #FF8A7A;
  --danger-soft: rgba(224, 74, 53, 0.14);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-hover: 0 12px 32px rgba(0, 0, 0, 0.45);
}
html[data-theme="dark"] .tone-orange { --t-bg: rgba(255, 122, 47, 0.16); --t-fg: #FFA670; }
html[data-theme="dark"] .tone-vert { --t-bg: rgba(47, 160, 82, 0.18); --t-fg: #6FD98A; }
html[data-theme="dark"] .tone-bleu { --t-bg: rgba(47, 134, 214, 0.18); --t-fg: #7DB8F2; }
html[data-theme="dark"] .tone-violet { --t-bg: rgba(124, 92, 224, 0.2); --t-fg: #B9A2FF; }
html[data-theme="dark"] .tone-rouge { --t-bg: rgba(224, 74, 53, 0.18); --t-fg: #FF8A78; }
html[data-theme="dark"] .tone-rose { --t-bg: rgba(219, 76, 145, 0.18); --t-fg: #F48CC0; }
html[data-theme="dark"] .tone-jaune { --t-bg: rgba(227, 169, 0, 0.16); --t-fg: #F5CC4E; }
html[data-theme="dark"] .tone-turquoise { --t-bg: rgba(31, 165, 148, 0.18); --t-fg: #5ED8C5; }
html[data-theme="dark"] .tone-indigo { --t-bg: rgba(85, 99, 214, 0.2); --t-fg: #9EA8FF; }
html[data-theme="dark"] .tone-gris { --t-bg: rgba(138, 129, 120, 0.2); --t-fg: #C9C3BC; }
.tone-jaune.chip.active, .tone-jaune.chip.active:hover { color: #1D1A17; }
.tone-jaune.chip.active .dot-c { background: #1D1A17; }

html[data-theme="dark"] input::placeholder, html[data-theme="dark"] textarea::placeholder { color: #7D7790; }
html[data-theme="dark"] .hero { background: var(--bg); }
html[data-theme="dark"] .hero-card { background: rgba(27, 26, 34, 0.9); }
html[data-theme="dark"] .card-status { background: rgba(18, 17, 23, 0.85); color: var(--ink); }
html[data-theme="dark"] .card-logo, html[data-theme="dark"] .vote-head img { box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5); }
html[data-theme="dark"] .btn-dark { background: #F3F1F8; border-color: #F3F1F8; color: #121117; }
html[data-theme="dark"] .btn-dark:hover { background: #FFFFFF; color: #121117; }
html[data-theme="dark"] .btn-danger { border-color: #6A2A22; }
html[data-theme="dark"] .message { background: #2A2833; border: 1px solid var(--border-strong); }
html[data-theme="dark"] .message.error { background: #4A1C16; }
html[data-theme="dark"] pre { background: #0B0A0F; border: 1px solid var(--border); }
html[data-theme="dark"] .chart rect { fill: #4A3326; }
html[data-theme="dark"] .notice-warn { border-color: #5C4716; background: rgba(227, 169, 0, 0.1); }
html[data-theme="dark"] .notice-error { border-color: #6A2A22; background: var(--danger-soft); color: #FFC3B8; }
html[data-theme="dark"] .notice-ok, html[data-theme="dark"] .success-box { border-color: #1F5A36; background: rgba(47, 160, 82, 0.12); color: #B6F0C8; }
html[data-theme="dark"] .success-box .ic { color: #0F2A1C; }
html[data-theme="dark"] .danger-zone { border-color: #6A2A22; background: rgba(224, 74, 53, 0.06); }
html[data-theme="dark"] .note { background: rgba(227, 169, 0, 0.08); border-color: #5C4716; }
html[data-theme="dark"] .pill-progress { background: rgba(47, 134, 214, 0.2); color: #7DB8F2; }
html[data-theme="dark"] .pill-ok { background: rgba(47, 160, 82, 0.2); color: #6FD98A; }
html[data-theme="dark"] .callout { color: var(--text-2); }
html[data-theme="dark"] .c-orange { color: #FFA670; }
html[data-theme="dark"] .c-vert { color: #6FD98A; }
html[data-theme="dark"] .c-bleu { color: #7DB8F2; }
html[data-theme="dark"] .c-violet { color: #B9A2FF; }
html[data-theme="dark"] .c-rouge { color: #FF8A78; }
html[data-theme="dark"] .c-rose { color: #F48CC0; }
html[data-theme="dark"] .c-jaune { color: #F5CC4E; }
html[data-theme="dark"] .c-turquoise { color: #5ED8C5; }
html[data-theme="dark"] .c-gris { color: #B3ADBF; }
html[data-theme="dark"] .c-indigo { color: #9EA8FF; }
html[data-theme="dark"] .staff-side { background: #0B0A0F; border-right: 1px solid var(--border); }
html[data-theme="dark"] .drawer-backdrop { background: rgba(0, 0, 0, 0.55); }
html[data-theme="dark"] .rank-row:nth-child(1) .rank-num { color: #F5C542; }
html[data-theme="dark"] .rank-row:nth-child(2) .rank-num { color: #C3C8D0; }
html[data-theme="dark"] .rank-row:nth-child(3) .rank-num { color: #E39A5F; }
.card-banner .pill { background: var(--surface); color: var(--t-fg); }
html[data-theme="dark"] .chart rect.last { fill: var(--accent); }

/* ---------------------------------------------------------------- classification */
.card-tags:empty { display: none; }
.rating-card { text-decoration: none; color: var(--ink); }
.rating-card:hover { border-color: var(--border-strong); }
.rating-pictos { display: flex; gap: 6px; flex-wrap: wrap; }
.rating-pictos img { width: 56px; height: auto; }
.rating-box { display: flex; flex-direction: column; gap: 8px; padding: 12px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--border); }
.picto-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; margin-top: 8px; }
.picto-item { display: flex; gap: 12px; align-items: center; padding: 10px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--border); }
.picto-item img { width: 54px; height: auto; flex: none; }
.picto-item p { margin: 2px 0 0; font-size: 13.5px; color: var(--muted); line-height: 1.45; }
.picto-pick { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px; }
.picto-opt { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border: 1px solid var(--border); border-radius: 10px; font-weight: 600; font-size: 13px; cursor: pointer; background: var(--surface); }
.picto-opt:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.picto-opt img { width: 28px; height: auto; }
.picto-thumb { width: 54px; height: auto; }
pre code { background: none; padding: 0; border-radius: 0; color: inherit; font-size: inherit; }
.rich pre { margin: 0 0 14px; }
html[data-theme="dark"] .delta.up { background: rgba(47, 160, 82, 0.18); color: #6FD98A; }
html[data-theme="dark"] .delta.down { background: rgba(224, 74, 53, 0.18); color: #FF8A78; }

.chip.active:not([class*="tone-"]), .chip.active:not([class*="tone-"]):hover { color: var(--bg); }
html[data-theme="dark"] .sc-bg { opacity: 0.32; }
html[data-theme="dark"] .server-card.no-banner { background: #202027; }
html[data-theme="dark"] .server-card.no-banner .sc-dot { border-color: #202027; }
