:root {
  --bg: #ffffff;
  --text: #1c1b1f;
  --muted: #5f5c66;
  --accent: #3657c8;
  --rule: #e3e1e8;
  --surface: #ffffff;
  --hover: #f0eef4;
  --shadow: rgba(20, 18, 30, 0.14);
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #131316;
    --text: #e6e1e9;
    --muted: #a8a3b0;
    --accent: #a9bbff;
    --rule: #2c2b31;
    --surface: #1d1c21;
    --hover: #2a2930;
    --shadow: rgba(0, 0, 0, 0.5);
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
main { max-width: 70ch; margin: 0 auto; padding: 24px 16px 64px; }
header { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 8px; }
.brand { font-weight: 600; color: var(--text); text-decoration: none; }
.lang { position: relative; font-size: 15px; }
.lang summary {
  display: flex; align-items: center; gap: 6px;
  padding: 5px 10px 5px 8px; border: 1px solid var(--rule); border-radius: 999px;
  list-style: none; cursor: pointer; user-select: none; white-space: nowrap;
}
.lang summary::-webkit-details-marker { display: none; }
.lang summary::after {
  content: ""; width: 6px; height: 6px; margin: 0 2px 3px 2px;
  border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg); transition: transform 0.15s;
}
.lang[open] summary::after { margin-bottom: -3px; transform: rotate(-135deg); }
.lang summary:hover { background: var(--hover); }
.lang summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.lang .globe { color: var(--muted); }
.lang ul {
  position: absolute; right: 0; top: calc(100% + 6px); z-index: 10;
  min-width: 180px; max-width: calc(100vw - 32px); margin: 0; padding: 6px; list-style: none;
  background: var(--surface); border: 1px solid var(--rule); border-radius: 12px;
  box-shadow: 0 8px 24px var(--shadow);
}
.lang li { margin: 0; }
.lang li a, .lang li span { display: flex; justify-content: space-between; gap: 16px; padding: 7px 12px; border-radius: 8px; }
.lang li a { color: var(--text); text-decoration: none; }
.lang li a:hover, .lang li a:focus-visible { background: var(--hover); outline: none; }
.lang li[aria-current] span { font-weight: 600; }
.lang li[aria-current] span::after { content: "✓"; color: var(--accent); }
h1 { font-size: 1.9em; line-height: 1.25; margin: 24px 0 4px; }
h2 { font-size: 1.2em; margin: 32px 0 8px; }
.updated { color: var(--muted); margin: 0 0 24px; }
a { color: var(--accent); }
ul { padding-left: 1.2em; }
li { margin: 4px 0; }
footer { margin-top: 48px; padding-top: 16px; border-top: 1px solid var(--rule); color: var(--muted); font-size: 15px; }
.button {
  display: inline-block; padding: 12px 24px; border-radius: 999px;
  background: var(--accent); color: var(--bg); font-weight: 600; text-decoration: none;
}
.button:hover, .button:focus-visible { opacity: 0.9; outline: none; }
.button.secondary { background: transparent; color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 16px 0; }
.hint { color: var(--muted); font-size: 15px; }
[hidden] { display: none !important; }
