/* Direction artistique reprise de « Humains vs Bots 2 » : papier blanc quadrillé, bandeau gris,
   typo arrondie M PLUS Rounded 1c, étiquettes pixel DotGothic16, cartes et boutons en relief doux.
   Orange = camp humain, bleu acier = camp bot. Un seul thème clair, comme dans le jeu. */
/* Polices hébergées sur le site (sous-ensemble latin), licence SIL OFL : voir /fonts */
@font-face { font-family: "M PLUS Rounded 1c"; src: url("/fonts/mplusrounded1c-500.woff") format("woff"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "M PLUS Rounded 1c"; src: url("/fonts/mplusrounded1c-700.woff") format("woff"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "M PLUS Rounded 1c"; src: url("/fonts/mplusrounded1c-800.woff") format("woff"); font-weight: 800; font-style: normal; font-display: swap; }
@font-face { font-family: "DotGothic16"; src: url("/fonts/dotgothic16-400.woff") format("woff"); font-weight: 400; font-style: normal; font-display: swap; }

:root {
  --paper: #FFFFFF;
  --sheet: #F3F3EF;
  --sheet-2: #E9E9E3;
  --rule: #D8D8D1;
  --grid: rgba(60, 60, 50, .06);
  --ink: #2A2A28;
  --mute: #86867F;
  --edge: #B9B9B1;
  --human: #F07E1E;
  --human-hi: #FFB067;
  --human-deep: #B85A0A;
  --bot: #3C78C8;
  --bot-deep: #24508C;
  --f-display: "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", ui-rounded, "Arial Rounded MT Bold", system-ui, sans-serif;
  --f-ui: "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", ui-rounded, system-ui, sans-serif;
  --f-bot: "DotGothic16", ui-monospace, "SF Mono", Menlo, monospace;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  color: var(--ink);
  font: 500 16px/1.65 var(--f-ui);
  background:
    linear-gradient(var(--grid) 1px, transparent 1px) 0 0 / 22px 22px,
    linear-gradient(90deg, var(--grid) 1px, transparent 1px) 0 0 / 22px 22px,
    var(--paper);
}
a { color: var(--bot); font-weight: 700; text-underline-offset: 3px; }
a:hover { color: var(--bot-deep); text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--bot); outline-offset: 3px; border-radius: 6px; }

.wrap { max-width: 760px; margin: 0 auto; padding: 0 16px; }

/* Bandeau du haut, comme la barre du jeu */
header.site { background: var(--sheet); border-bottom: 2px solid var(--rule); }
header.site .wrap {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px;
  padding-top: 12px; padding-bottom: 12px;
}
.brand {
  margin-right: auto; text-decoration: none;
  font: 800 23px/1 var(--f-display); letter-spacing: .02em;
}
.brand .h { color: var(--human); }
.brand .b { color: var(--bot); }
nav.main { display: flex; flex-wrap: wrap; gap: 6px; }
nav.main a {
  display: inline-flex; align-items: center; height: 34px; padding: 0 12px; border-radius: 99px;
  color: var(--mute); text-decoration: none; font: 700 14px/1 var(--f-ui);
}
nav.main a:hover { color: var(--ink); }
nav.main a[aria-current="page"] { background: var(--paper); color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--rule); }

.lang-switch {
  display: inline-flex; padding: 3px; border-radius: 99px;
  background: var(--paper); box-shadow: inset 0 0 0 1.5px var(--rule);
}
.lang-switch button {
  height: 28px; padding: 0 11px; border: 0; border-radius: 99px; cursor: pointer;
  background: transparent; color: var(--mute); font: 800 13px/1 var(--f-display); letter-spacing: .04em;
}
.lang-switch button[aria-pressed="true"] { background: var(--human); color: #fff; text-shadow: 0 1px 0 var(--human-deep); }

/* Contenu */
main { padding: 36px 0 64px; }
h1 { margin: 0 0 6px; font: 800 clamp(30px, 7vw, 40px)/1.1 var(--f-display); letter-spacing: .01em; text-wrap: balance; }
h2 {
  margin: 38px 0 12px; padding-bottom: 6px; border-bottom: 2px solid var(--rule);
  font: 800 19px/1.25 var(--f-display); letter-spacing: .03em;
}
h3 { margin: 22px 0 4px; font: 800 16px/1.3 var(--f-ui); }
p, ul { margin: 0 0 12px; }
ul { padding-left: 22px; }
li { margin-bottom: 6px; }
li::marker { color: var(--human); }
strong { font-weight: 800; }
.lede { font-size: 18px; color: var(--mute); max-width: 36ch; text-wrap: balance; }
.updated, .tag { font: 400 13px/1.3 var(--f-bot); color: var(--mute); }
.updated { margin-bottom: 24px; }

/* Cartes : bord gris, ombre portée nette, liseré coloré en tête */
.card {
  position: relative; overflow: hidden; margin: 18px 0; padding: 20px 18px 16px;
  border-radius: 16px; background: var(--paper);
  box-shadow: inset 0 0 0 2px var(--rule), 0 4px 0 var(--rule);
}
.card::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 5px; background: var(--c, var(--human)); }
.card.bot { --c: var(--bot); }
.card h2 { margin-top: 0; border: 0; padding: 0; }

/* Accueil */
.hero { display: grid; justify-items: center; text-align: center; gap: 10px; padding: 12px 0 8px; }
.logo { margin: 0; font: 800 clamp(42px, 12vw, 64px)/1 var(--f-display); letter-spacing: .02em; }
.logo .h { color: var(--human); }
.logo .b { color: var(--bot); }
.hero .lede { margin: 0 auto; }
.hero .tag { margin: 0; }

/* Boutons en relief doux */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 56px; padding: 0 24px; border-radius: 16px; text-decoration: none; white-space: nowrap;
  background: linear-gradient(#FFFFFF, #E4E4DE); color: var(--ink);
  font: 800 17px/1 var(--f-display); letter-spacing: .03em;
  box-shadow: inset 0 0 0 2px var(--edge), 0 5px 0 var(--edge), 0 8px 18px rgba(0, 0, 0, .08);
  transition: transform .08s ease, box-shadow .08s ease;
}
.btn:hover { color: var(--ink); }
.btn:active { transform: translateY(4px); box-shadow: inset 0 0 0 2px var(--edge), 0 1px 0 var(--edge); }
.btn.big {
  background: linear-gradient(#FFA14A, var(--human)); color: #fff; text-shadow: 0 2px 0 var(--human-deep);
  box-shadow: inset 0 0 0 2px var(--human-deep), 0 5px 0 var(--human-deep), 0 10px 22px rgba(240, 126, 30, .28);
}
.btn.big:hover { color: #fff; }
.btn.big:active { box-shadow: inset 0 0 0 2px var(--human-deep), 0 1px 0 var(--human-deep); }
.btns { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 6px; }

/* Pied de page */
footer.site { background: var(--sheet); border-top: 2px solid var(--rule); }
footer.site .wrap {
  display: flex; flex-wrap: wrap; gap: 8px 18px; padding-top: 18px; padding-bottom: 26px;
  font: 500 14px/1.4 var(--f-ui); color: var(--mute);
}
footer.site a { color: var(--mute); font-weight: 700; }
footer.site .copy { font-family: var(--f-bot); }

/* Langues : sans JavaScript les deux s'affichent ; avec, seule la langue choisie */
html[data-lang="en"] [lang="fr"].l { display: none; }
html[data-lang="fr"] [lang="en"].l { display: none; }

@media (max-width: 560px) {
  .brand { width: 100%; }
  nav.main { order: 2; width: 100%; }
  .lang-switch { position: absolute; right: 16px; top: 10px; }
  header.site .wrap { position: relative; }
  .btns .btn { width: 100%; }
}
