/* Foxy Network : thème sombre, orange du renard */
:root {
  --bg: #120d0a;
  --bg-2: #1a1310;
  --card: #1f1714;
  --card-2: #271d18;
  --line: #3a2b23;
  --text: #f6ece4;
  --muted: #b9a497;
  --orange: #ff8a1f;
  --orange-2: #ffb13b;
  --orange-dark: #c95f07;
  --ok: #4fd18b;
  --warn: #ffc24a;
  --error: #ff6b5b;
  --discord: #5865f2;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(0, 0, 0, .35);
  color-scheme: dark;
}
* { box-sizing: border-box; scrollbar-width: thin; scrollbar-color: rgba(255, 138, 31, .35) transparent; }
/* Barres de défilement aux couleurs du site (la page : orange foncé sur le fond) */
html { scrollbar-color: var(--orange-dark) var(--bg-2); }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: radial-gradient(1200px 600px at 80% -10%, rgba(255, 138, 31, .16), transparent 60%), var(--bg);
  color: var(--text);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, Ubuntu, "Helvetica Neue", Arial, sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
a { color: var(--orange-2); }
img { max-width: 100%; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .6em; }
h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); letter-spacing: -.02em; }
h2 { font-size: 1.35rem; }
h3 { font-size: 1.1rem; }
code { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }
.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.main { flex: 1; padding-top: 28px; padding-bottom: 56px; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.warn-text { color: var(--warn); }

/* ----- Accessibilité ----- */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; padding: 10px 16px; border-radius: 10px; background: var(--orange-2); color: #2a1400; font-weight: 800; text-decoration: none; }
.skip-link:focus { top: 12px; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 3px solid var(--orange-2); outline-offset: 2px; }
main:focus { outline: none; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; } }

/* ----- En-tête ----- */
.top { position: sticky; top: 0; z-index: 10; background: rgba(18, 13, 10, .86); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.top-in { display: flex; align-items: center; gap: 20px; min-height: 64px; flex-wrap: wrap; padding-top: 8px; padding-bottom: 8px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 800; font-size: 1.15rem; }
.brand img { border-radius: 10px; }
.brand b { color: var(--orange); margin-left: 4px; }
.nav { display: flex; gap: 4px; flex-wrap: wrap; }
.nav a { color: var(--muted); text-decoration: none; padding: 8px 12px; border-radius: 10px; font-weight: 600; font-size: .95rem; }
.nav a:hover { color: var(--text); background: var(--card); }
.nav a[aria-current="page"] { color: var(--text); background: var(--card-2); box-shadow: inset 0 -2px 0 var(--orange); }
.top-right { margin-left: auto; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.langs { display: flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.langs a { padding: 5px 9px; font-size: .8rem; font-weight: 700; color: var(--muted); text-decoration: none; }
.langs a[aria-current="true"] { background: var(--orange); color: #241200; }
.user { display: flex; align-items: center; gap: 8px; }
.user form { margin: 0; }
.user-name { font-weight: 600; max-width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.avatar { width: 28px; height: 28px; border-radius: 50%; }
.avatar-empty { display: inline-block; background: var(--card-2); }
.link-btn { background: none; border: 0; color: var(--muted); cursor: pointer; font: inherit; font-size: .875rem; padding: 4px; }
.link-btn:hover { color: var(--text); text-decoration: underline; }

/* ----- Boutons ----- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 18px; border-radius: 12px; border: 1px solid transparent;
  font: inherit; font-weight: 700; text-decoration: none; cursor: pointer; color: var(--text);
  transition: transform .08s ease, background .15s ease, border-color .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn svg { width: 20px; height: 20px; }
.btn-sm { padding: 7px 12px; font-size: .875rem; border-radius: 10px; }
.btn-lg { padding: 14px 24px; font-size: 1.05rem; }
.btn-primary { background: linear-gradient(180deg, var(--orange-2), var(--orange)); color: #2a1400; box-shadow: 0 6px 18px rgba(255, 138, 31, .35); }
.btn-primary:hover { background: linear-gradient(180deg, #ffc061, #ff9a38); }
.btn-primary:disabled { opacity: .5; cursor: not-allowed; }
.btn-ghost { background: var(--card-2); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--orange); }
.btn-danger { background: transparent; border-color: rgba(255, 107, 91, .5); color: var(--error); }
.btn-danger:hover { background: rgba(255, 107, 91, .1); }
.btn-discord { background: var(--discord); color: #fff; }
.btn-discord:hover { background: #4752c4; }
.text-link { font-weight: 700; text-decoration: none; }
.text-link:hover { text-decoration: underline; }

/* ----- Blocs ----- */
.card { background: linear-gradient(180deg, var(--card-2), var(--card)); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); margin-bottom: 18px; }
.section { margin: 36px 0; }
.grid { display: grid; gap: 16px; }
.split { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 18px; }
.split > .card { margin-bottom: 0; }
.split + * { margin-top: 18px; }
.page-head { margin: 10px 0 24px; }
.page-head.center { text-align: center; margin: 40px auto; max-width: 640px; }
.lead { font-size: 1.1rem; color: var(--muted); }
.notice { border-radius: 12px; padding: 12px 16px; margin-bottom: 18px; border: 1px solid; font-weight: 600; }
.notice-ok { background: rgba(79, 209, 139, .1); border-color: rgba(79, 209, 139, .4); color: #b8f3d2; }
.notice-warn { background: rgba(255, 194, 74, .1); border-color: rgba(255, 194, 74, .4); color: #ffe2a6; }
.notice-error { background: rgba(255, 107, 91, .1); border-color: rgba(255, 107, 91, .4); color: #ffc4bc; }
.tag { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: .78rem; font-weight: 700; background: var(--card-2); border: 1px solid var(--line); white-space: nowrap; }
.tag-ok { color: var(--ok); border-color: rgba(79, 209, 139, .4); }
.tag-warn { color: var(--warn); border-color: rgba(255, 194, 74, .4); }
.tag-error { color: var(--error); border-color: rgba(255, 107, 91, .4); }
.tag-mvp { color: #2a1400; background: var(--orange-2); border-color: var(--orange-2); }
.tag-grade { color: var(--orange-2); border-color: rgba(255, 177, 59, .45); font-size: .85rem; }
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--ok); margin-right: 8px; box-shadow: 0 0 0 4px rgba(79, 209, 139, .18); vertical-align: middle; }

/* ----- Accueil ----- */
.hero { display: grid; grid-template-columns: 1.3fr 1fr; gap: 32px; align-items: center; padding: 24px 0 8px; }
.kicker { color: var(--orange); font-weight: 800; text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; margin: 0 0 10px; }
.hero-art { display: flex; justify-content: center; }
.hero-art img { width: min(320px, 70vw); height: auto; border-radius: 32px; box-shadow: 0 30px 80px rgba(255, 138, 31, .28); transform: rotate(-3deg); }
.ip-box { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; margin: 22px 0; }
.ip-box .label, .tile .label { display: block; color: var(--muted); font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; }
.ip-box code { font-size: 1.15rem; font-weight: 700; color: var(--orange-2); }
.ip-box .btn { margin-left: auto; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.online { margin-top: 18px; color: var(--muted); font-weight: 600; }
.games { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.game { margin: 0; }
.game h3 { color: var(--orange-2); }
.game p { margin: 0; color: var(--muted); }

/* ----- Boutique ----- */
.grades { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.coins-grid { grid-template-columns: repeat(auto-fill, minmax(135px, 1fr)); }
.product { --accent: var(--orange); position: relative; display: flex; flex-direction: column; gap: 12px; margin: 0; cursor: pointer; transition: border-color .15s ease, transform .15s ease; }
.product:hover { transform: translateY(-2px); border-color: var(--accent); }
.product input[type="radio"] { position: absolute; opacity: 0; pointer-events: none; }
.product:has(input:checked) { border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent), var(--shadow); }
.product:has(input:focus-visible) { outline: 3px solid var(--orange-2); outline-offset: 3px; }
.product-head { display: flex; flex-direction: column; gap: 4px; }
.grade-name { font-size: 1.4rem; font-weight: 800; color: var(--accent); }
.price { font-size: 1.25rem; font-weight: 800; }
.price small { color: var(--muted); font-weight: 600; font-size: .85rem; }
.perks { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: .92rem; color: var(--muted); }
.perks li { display: flex; gap: 8px; align-items: flex-start; }
.perks svg { width: 18px; height: 18px; flex: none; color: var(--accent); margin-top: 2px; }
.coin-card { align-items: center; text-align: center; padding: 38px 12px 20px; }
.coins { display: flex; align-items: center; gap: 8px; font-size: 1.35rem; color: var(--orange-2); }
.coins svg, .coin-text svg { width: 26px; height: 26px; color: var(--orange-2); }
.coin-text { display: inline-flex; align-items: center; gap: 8px; }
.bonus { position: absolute; top: 10px; right: 10px; background: var(--ok); color: #062615; font-weight: 800; font-size: .75rem; padding: 2px 8px; border-radius: 999px; }
fieldset.mode { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin: 18px 0 0; display: grid; gap: 10px; transition: opacity .15s ease; }
fieldset.mode.dimmed { opacity: .45; }
fieldset.mode legend { padding: 0 6px; font-weight: 700; color: var(--muted); }
.radio, .check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.radio span, .check span { display: flex; flex-direction: column; }
.radio small { color: var(--muted); }
.radio.disabled { opacity: .55; cursor: not-allowed; }
.radio input, .check input { margin-top: 4px; accent-color: var(--orange); width: 18px; height: 18px; flex: none; }
.check { margin: 12px 0; }
.check span { display: inline; }
.check.compact { margin: 0; align-items: center; }
.check.compact input { margin-top: 0; }
.checkout .btn-lg { margin-top: 8px; width: 100%; }
.fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; margin-bottom: 8px; }
.fields-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.field { display: flex; flex-direction: column; gap: 6px; }
.field > span:first-child { font-weight: 700; }
.field small { color: var(--muted); font-size: .85rem; }
.inline { display: flex; gap: 8px; align-items: center; }
.inline input { flex: 1; min-width: 70px; }
.inline select { width: auto; flex: none; }
input[type="text"], input[type="number"], select {
  background: var(--bg-2); border: 1px solid var(--line); color: var(--text); border-radius: 10px;
  padding: 10px 12px; font: inherit; width: 100%;
}
input:focus, select:focus { outline: 2px solid var(--orange); outline-offset: 1px; border-color: transparent; }
input:disabled { opacity: .5; }
.field-error { color: var(--error); font-weight: 600; margin: 4px 0 0; }
.field-ok { color: var(--ok); font-weight: 600; margin: 4px 0 0; }

/* ----- Commande ----- */
.receipt { max-width: 560px; margin: 0 auto; }
.status { font-size: 1.2rem; font-weight: 800; display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.status-ok { color: var(--ok); }
.status-wait { color: var(--orange-2); }
.status-warn { color: var(--warn); }
.status-error { color: var(--error); }
.spinner { width: 18px; height: 18px; border-radius: 50%; border: 3px solid rgba(255, 177, 59, .3); border-top-color: var(--orange-2); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 8px 18px; margin: 0 0 16px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-weight: 600; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; }

/* ----- Compte ----- */
.profile { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.profile h2 { margin: 0; }
.profile p { margin: 2px 0 0; }
.profile .btn { margin-left: auto; }
.avatar-lg { width: 64px; height: 64px; border-radius: 50%; display: inline-block; }
.tiles { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); margin-bottom: 18px; }
.tile { margin: 0; padding: 16px 18px; }
.tile .big { display: block; font-size: 1.2rem; margin-top: 4px; }
.tile .big.coin-text { display: flex; }
.grades-list, .subs, .ranked { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 10px; }
.grades-list li { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: center; }
.sub { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding: 10px 0; border-bottom: 1px solid var(--line); }
.sub form { margin: 0; }
.ranked li { display: flex; gap: 14px; align-items: baseline; flex-wrap: wrap; }
.ranked b { color: var(--orange-2); font-size: 1.2rem; }
.steps { padding-left: 22px; display: grid; gap: 8px; }
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; font-size: .92rem; }
th, td { text-align: left; padding: 9px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { color: var(--muted); font-weight: 700; font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; }
td form { margin: 0; }

/* ----- Classements ----- */
.board-card { scroll-margin-top: 90px; }
.board-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.board-head h2 { margin: 0; }
.board-tabs { display: flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; flex-wrap: wrap; }
.board-tabs a { padding: 7px 12px; font-size: .88rem; font-weight: 700; color: var(--muted); text-decoration: none; }
.board-tabs a:hover { color: var(--text); background: var(--card-2); }
.board-tabs a[aria-current="true"] { background: var(--orange); color: #241200; }
.board-sorts { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.board-sorts .muted { margin-right: 4px; }
.chip { padding: 4px 11px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg-2); color: var(--muted); font-size: .84rem; font-weight: 700; text-decoration: none; }
.chip:hover { color: var(--text); border-color: var(--orange); }
.chip[aria-current="true"] { color: #2a1400; background: var(--orange-2); border-color: var(--orange-2); }
table.board th a { color: inherit; text-decoration: none; }
table.board th a:hover { color: var(--text); }
table.board .sorted { color: var(--orange-2); font-weight: 800; }
table.board th.sorted a { color: var(--orange-2); }
td.rank { width: 44px; font-weight: 800; color: var(--muted); font-variant-numeric: tabular-nums; }
td.rank-1 { color: #ffd257; } td.rank-2 { color: #d9dee6; } td.rank-3 { color: #e09a5a; }
tr.gap-row td { color: var(--muted); text-align: center; padding: 2px; border-bottom: 0; }

/* ----- Statistiques UHC ----- */
.uhc-card { border-color: rgba(255, 138, 31, .35); background: radial-gradient(600px 220px at 100% 0, rgba(255, 138, 31, .12), transparent 70%), linear-gradient(180deg, var(--card-2), var(--card)); }
.uhc-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.uhc-head .kicker { margin-bottom: 4px; }
.uhc-head h2 { margin: 0; }
.uhc-rate { display: grid; grid-template-columns: 160px auto; grid-template-rows: auto auto; column-gap: 12px; align-items: center; }
.uhc-rate-bar { grid-row: 1 / 3; height: 10px; border-radius: 999px; background: var(--bg-2); border: 1px solid var(--line); overflow: hidden; }
.uhc-rate-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--orange-dark), var(--orange-2)); }
.uhc-rate b { font-size: 1.35rem; color: var(--orange-2); line-height: 1; }
.uhc-rate small { color: var(--muted); font-size: .78rem; }
.w-0 { width: 0; } .w-5 { width: 5%; } .w-10 { width: 10%; } .w-15 { width: 15%; } .w-20 { width: 20%; } .w-25 { width: 25%; } .w-30 { width: 30%; }
.w-35 { width: 35%; } .w-40 { width: 40%; } .w-45 { width: 45%; } .w-50 { width: 50%; } .w-55 { width: 55%; } .w-60 { width: 60%; } .w-65 { width: 65%; }
.w-70 { width: 70%; } .w-75 { width: 75%; } .w-80 { width: 80%; } .w-85 { width: 85%; } .w-90 { width: 90%; } .w-95 { width: 95%; } .w-100 { width: 100%; }
.uhc-key { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; margin-bottom: 20px; }
.uhc-num { background: var(--bg-2); padding: 14px 16px; display: flex; flex-direction: column; gap: 2px; }
.uhc-num .label { color: var(--muted); font-size: .74rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; }
.uhc-num b { font-size: 1.6rem; line-height: 1.15; font-variant-numeric: tabular-nums; }
.uhc-num small { color: var(--muted); font-size: .8rem; }
.uhc-lists { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 12px 28px; margin-bottom: 18px; }
.uhc-list h3, .uhc-sub { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--orange); margin: 0 0 6px; }
.uhc-list dl { margin: 0; }
.uhc-list dl > div { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px dashed var(--line); }
.uhc-list dt { color: var(--muted); display: flex; align-items: center; gap: 8px; }
.uhc-list dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }
.ore { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.ore-diamond { background: #5ee6e0; } .ore-gold { background: #f6c945; } .ore-iron { background: #d8cbbf; }
.uhc-sub { margin-top: 4px; }
/* ----- Statistiques Practice : grades (couleurs de ceux du jeu) ----- */
.practice-card { border-color: rgba(237, 66, 69, .35); background: radial-gradient(600px 220px at 100% 0, rgba(237, 66, 69, .12), transparent 70%), linear-gradient(180deg, var(--card-2), var(--card)); }
.practice-card .uhc-sub { margin-top: 16px; }
.prank { font-size: .8rem; white-space: nowrap; }
.prank-plastic { color: #e3d4d1; border-color: rgba(227, 212, 209, .4); }
.prank-silver { color: #c6c6c6; border-color: rgba(198, 198, 198, .4); }
.prank-gold { color: #ddd605; border-color: rgba(221, 214, 5, .4); }
.prank-platinum { color: #55ffff; border-color: rgba(85, 255, 255, .4); }
.prank-diamond { color: #2cbaa8; border-color: rgba(44, 186, 168, .4); }
.prank-elite { color: #ff5b5b; border-color: rgba(255, 91, 91, .4); }
.prank-champion { color: #c77dff; border-color: rgba(199, 125, 255, .4); }
.prank-prominence { color: #241200; background: linear-gradient(90deg, #ff6b5b, var(--orange-2)); border-color: transparent; }

/* ----- Historique des parties ----- */
tr.row-link { cursor: pointer; transition: background .12s ease; }
tr.row-link:hover, tr.row-link:focus-within { background: rgba(255, 138, 31, .07); }
tr.row-link a { color: var(--text); text-decoration: none; font-weight: 600; }
tr.row-link a:hover { color: var(--orange-2); }
.game-head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; }
.game-head .kicker { width: 100%; margin: 0; }
.game-head h1 { margin: 0; }
.tag-big { font-size: .95rem; padding: 4px 12px; }
.team-card h2 { margin: 0; font-size: 1.15rem; }
.team-card table { table-layout: fixed; min-width: 520px; }
.team-card th:first-child, .team-card td:first-child { width: 38%; overflow: hidden; text-overflow: ellipsis; }
.team-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.team-dot { width: 14px; height: 14px; border-radius: 4px; background: var(--muted); box-shadow: inset 0 0 0 2px rgba(0, 0, 0, .25); flex: none; }
tr.me-row td { background: rgba(255, 138, 31, .09); }
.dye-white { background: #f0f0f0; } .dye-orange { background: #f9801d; } .dye-magenta { background: #c74ebd; }
.dye-light_blue { background: #3ab3da; } .dye-yellow { background: #fed83d; } .dye-lime { background: #80c71f; }
.dye-pink { background: #f38baa; } .dye-gray { background: #474f52; } .dye-light_gray { background: #9d9d97; }
.dye-cyan { background: #169c9c; } .dye-purple { background: #8932b8; } .dye-blue { background: #3c44aa; }
.dye-brown { background: #835432; } .dye-green { background: #5e7c16; } .dye-red { background: #b02e26; } .dye-black { background: #1d1d21; }

/* ----- Joueurs et profils ----- */
.profile-actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }
.profile .profile-actions .btn { margin-left: 0; }
a.plink { color: inherit; text-decoration: none; }
a.plink:hover { color: var(--orange-2); text-decoration: underline; }
.search { margin-bottom: 16px; }
.search .inline { max-width: 560px; }
.profile-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.profile-head h1 { margin: 0; overflow-wrap: anywhere; }
.profile-head .kicker { margin: 0 0 4px; }
.profile-grades { display: flex; gap: 6px; flex-wrap: wrap; margin: 10px 0 0; }
.pager { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin-top: 16px; }
td.wrap { white-space: normal; min-width: 180px; overflow-wrap: anywhere; }
.staff { margin: 8px 0 26px; padding: 18px; border: 1px dashed rgba(255, 138, 31, .45); border-radius: var(--radius); }
.staff-title { margin: 0 0 14px; font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; color: var(--orange); }
.staff h3 { margin: 0 0 12px; font-size: 1.05rem; }
.staff > .card:last-child { margin-bottom: 0; }
.manage { border-color: rgba(255, 107, 91, .45); scroll-margin-top: 90px; }
.manage h2 { margin-top: 0; }
.manage-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 18px 28px; }
.manage-grid h3 { margin: 14px 0 8px; font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--orange-2); }
.manage-grid section > h3:first-child { margin-top: 0; }
.manage-form { margin: 0 0 8px; }
.manage-form small { display: block; margin-top: 6px; font-size: .82rem; }
.manage-form input[type="number"] { max-width: 140px; }
.manage-form .inline { flex-wrap: wrap; }
/* Listes de la gestion : environ 5 lignes visibles, le reste en faisant défiler */
.scroll-list { max-height: 232px; overflow-y: auto; overscroll-behavior: contain; padding-right: 6px; scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.scroll-list li { padding: 6px 0; border-bottom: 1px solid var(--line); }
.scroll-list li:last-child { border-bottom: 0; }
.scroll-list:focus-visible { outline: 2px solid var(--orange); outline-offset: 2px; }
/* Cosmétiques de la gestion : sa colonne descend jusqu'en bas de la boîte (deux rangées), la liste prend toute la place
   libre (flex-basis 0 : elle ne grandit pas la boîte, elle remplit ce que les autres colonnes laissent) */
.manage-cosmetics { grid-row: span 2; display: flex; flex-direction: column; min-height: 0; }
.manage-cosmetics .scroll-list { flex: 1 1 0; min-height: 200px; max-height: none; margin-bottom: 12px; }
@media (max-width: 1000px) { .manage-cosmetics { grid-row: auto; } .manage-cosmetics .scroll-list { flex: none; max-height: 320px; } }
/* Message d'une action faite sans quitter la page (site.js) : en bas de l'écran, puis il disparaît */
.notice-toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); z-index: 50; width: max-content; max-width: calc(100% - 32px); box-shadow: var(--shadow); background-color: var(--card); backdrop-filter: blur(6px); transition: opacity .4s ease, transform .4s ease; }
.notice-toast.notice-hide { opacity: 0; transform: translate(-50%, 12px); pointer-events: none; }
.manage-form .inline select { flex: 1 1 130px; }
@media (max-width: 600px) { .staff { padding: 10px; } }
.grades-list li form { margin: 0; }
.admin-links { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.admin-links h2 { margin: 0 0 4px; }
.admin-links p { margin: 0; }

/* ----- Admin ----- */
.admin-form .btn { margin-top: 6px; }

/* ----- Textes légaux ----- */
.prose { max-width: 820px; }
.prose h2 { margin-top: 1.4em; font-size: 1.15rem; color: var(--orange-2); }
.prose h2:first-child { margin-top: 0; }
.prose p { color: #e4d6cc; }

/* ----- Pied de page ----- */
.foot { border-top: 1px solid var(--line); background: var(--bg-2); padding: 26px 0; }
.foot-in { display: flex; flex-wrap: wrap; gap: 14px 28px; align-items: center; }
.foot-brand { display: flex; align-items: center; gap: 10px; font-weight: 700; }
.foot-brand img { border-radius: 8px; }
.foot-links { display: flex; gap: 18px; flex-wrap: wrap; margin-left: auto; }
.foot-links a { color: var(--muted); text-decoration: none; font-size: .9rem; }
.foot-links a:hover { color: var(--text); }
.foot-small { width: 100%; margin: 0; color: #a39083; font-size: .8rem; }

@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; }
  .hero-art { order: -1; }
  .hero-art img { width: 180px; }
  .top-right { margin-left: 0; width: 100%; justify-content: space-between; }
  .nav { width: 100%; overflow-x: auto; flex-wrap: nowrap; }
  .nav a { white-space: nowrap; }
  .ip-box .btn { margin-left: 0; }
  .profile .btn { margin-left: 0; }
  .foot-links { margin-left: 0; }
  .uhc-rate { grid-template-columns: 1fr auto; width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

/* Fenêtre : jour ou nuit (heure de Paris) */
/* Les bots respirent ; plus vite et voyant allumé quand ils travaillent */
/* Machines : voyants, écrans de surveillance, courbes, écrans des bureaux */
/* Lampe de l'admin : halo au sol allumé quand il travaille, ampoule qui chauffe */
/* Bac à sable : vitre et mini-bots animés pendant un test */
/* Le chat */
/* Fiches des bots, échanges, anomalies */
