:root {
  --fond: #fdf8f6;
  --texte: #231917;
  --attenue: #53433f;
  --accent: #8f4c38;
  --sur-accent: #ffffff;
  --carte: #fff1ec;
  --bordure: #e8d3cd;
  --voile: rgba(143, 76, 56, 0.06);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --fond: #1a1110;
    --texte: #f1dfda;
    --attenue: #d8c2bc;
    --accent: #ffb5a0;
    --sur-accent: #561f0c;
    --carte: #2b201d;
    --bordure: #53433f;
    --voile: rgba(255, 181, 160, 0.07);
  }
}
:root[data-theme="dark"] {
  --fond: #1a1110;
  --texte: #f1dfda;
  --attenue: #d8c2bc;
  --accent: #ffb5a0;
  --sur-accent: #561f0c;
  --carte: #2b201d;
  --bordure: #53433f;
  --voile: rgba(255, 181, 160, 0.07);
}
* { box-sizing: border-box; }
body {
  margin: 0;
  padding: 0 16px 64px;
  background: var(--fond);
  color: var(--texte);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  line-height: 1.65;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
main { max-width: 720px; margin: 0 auto; }

/* Les deux langues sont dans le document, une seule s'affiche. */
html[data-lang="fr"] [lang="en"] { display: none; }
html[data-lang="en"] [lang="fr"] { display: none; }

.barre {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 20px;
}
.retour {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
}
.retour svg {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  flex-shrink: 0;
}
.retour span { text-decoration: underline; }
.langues { display: flex; gap: 4px; }
.langues button {
  font: inherit;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--attenue);
  background: none;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 4px 12px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.langues button:hover { background: var(--voile); }
.langues button[aria-pressed="true"] {
  background: var(--accent);
  color: var(--sur-accent);
}

header { padding: 36px 0 8px; }
h1 { font-size: 1.8rem; line-height: 1.2; margin: 0 0 8px; color: var(--accent); }
h2 { font-size: 1.15rem; margin: 40px 0 10px; }
h3 { font-size: 1rem; margin: 24px 0 6px; }
p, li { color: var(--texte); }
.date { color: var(--attenue); font-size: 0.9rem; margin: 0; }
.resume {
  background: var(--carte);
  border: 1px solid var(--bordure);
  border-left: 4px solid var(--accent);
  border-radius: 16px;
  padding: 18px 20px;
  margin: 28px 0;
}
.resume p { margin: 0 0 10px; }
.resume p:last-child { margin-bottom: 0; }
ul { padding-left: 22px; }
li { margin-bottom: 8px; }
a { color: var(--accent); }
code {
  background: var(--carte);
  border: 1px solid var(--bordure);
  border-radius: 5px;
  padding: 1px 5px;
  font-size: 0.9em;
}
footer {
  margin-top: 56px;
  padding-top: 20px;
  border-top: 1px solid var(--bordure);
  color: var(--attenue);
  font-size: 0.9rem;
}
footer a { margin-right: 18px; }
strong { font-weight: 600; }
