:root {
  --bg: #f7f2ea;
  --surface: #fffdf9;
  --text: #2b231c;
  --muted: #6e6257;
  --accent: #9a5b2e;
  --accent-soft: #ead9c6;
  --border: #e3d6c6;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1c1814;
    --surface: #26201b;
    --text: #f1e9df;
    --muted: #b3a597;
    --accent: #d99a63;
    --accent-soft: #3a2d22;
    --border: #3a3029;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
a { color: var(--accent); }
.wrap { max-width: 860px; margin: 0 auto; padding: 0 20px; }

/* Langues : seul le bloc de la langue active est visible */
[data-l] { display: none; }
html[lang="fr"] [data-l="fr"],
html[lang="de"] [data-l="de"],
html[lang="en"] [data-l="en"] { display: revert; }

header { border-bottom: 1px solid var(--border); background: var(--surface); }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 0; flex-wrap: wrap; }
.brand { font-weight: 700; font-size: 20px; letter-spacing: .02em; color: var(--text); text-decoration: none; }
.brand span { color: var(--accent); }
nav { display: flex; gap: 16px; flex-wrap: wrap; align-items: center; }
nav a { color: var(--muted); text-decoration: none; font-size: 15px; }
nav a:hover, nav a.active { color: var(--text); }
.langs { display: flex; gap: 4px; }
.langs button {
  border: 1px solid var(--border); background: transparent; color: var(--muted);
  border-radius: 6px; padding: 3px 8px; font-size: 13px; cursor: pointer;
}
.langs button.on { background: var(--accent); border-color: var(--accent); color: #fff; }

.hero { padding: 64px 0 40px; }
.hero h1 { font-size: clamp(32px, 6vw, 48px); line-height: 1.15; margin: 0 0 16px; }
.hero p { font-size: 19px; color: var(--muted); max-width: 620px; margin: 0; }

h2 { font-size: 26px; margin: 48px 0 16px; }
h3 { font-size: 20px; margin: 28px 0 8px; }
main { padding-bottom: 64px; }

.apps { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 22px;
  display: flex; flex-direction: column; gap: 8px;
}
.card h3 { margin: 0; }
.card p { margin: 0; color: var(--muted); font-size: 16px; }
.tag {
  align-self: flex-start; background: var(--accent-soft); color: var(--accent);
  font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px;
}
.links { display: flex; gap: 14px; margin-top: auto; padding-top: 8px; font-size: 15px; }

.doc { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 8px 28px 28px; margin-top: 32px; }
.doc section { scroll-margin-top: 20px; border-top: 1px solid var(--border); padding-top: 8px; margin-top: 24px; }
.doc section:first-of-type { border-top: 0; margin-top: 0; }
.updated { color: var(--muted); font-size: 14px; }
.toc { display: flex; gap: 10px; flex-wrap: wrap; margin: 16px 0 0; }
.toc a { background: var(--accent-soft); padding: 5px 12px; border-radius: 999px; text-decoration: none; font-size: 15px; }
.mail { font-size: 20px; font-weight: 600; }

footer { border-top: 1px solid var(--border); color: var(--muted); font-size: 14px; padding: 24px 0 40px; }
footer .wrap { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
footer a { color: var(--muted); }

@media (max-width: 560px) {
  body { font-size: 16px; }
  .hero { padding: 40px 0 24px; }
  .doc { padding: 4px 18px 20px; }
}
