:root {
  --bg: #FFFFFF;
  --surface: #F5F5F3;
  --text: #1A1A1A;
  --muted: #6B6B6B;
  --line: #E6E6E3;
  --accent: #1F7A4D;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111214;
    --surface: #1C1C1E;
    --text: #F2F2F2;
    --muted: #9A9A9A;
    --line: #2A2A2D;
    --accent: #4CC38A;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Sans", "Noto Sans JP", Roboto, sans-serif;
}
main { max-width: 680px; margin: 0 auto; padding: 32px 16px 64px; }
header { display: flex; justify-content: space-between; align-items: baseline; gap: 16px;
  padding-bottom: 16px; border-bottom: 1px solid var(--line); margin-bottom: 32px; }
header a.brand { font-weight: 700; font-size: 20px; color: var(--text); text-decoration: none; }
nav a { color: var(--muted); margin-left: 16px; font-size: 15px; }
a { color: var(--accent); }
h1 { font-size: 28px; line-height: 1.25; margin: 0 0 8px; }
h2 { font-size: 20px; margin: 32px 0 8px; }
p, li { margin: 0 0 12px; }
ul { padding-left: 20px; }
.muted { color: var(--muted); }
.card { background: var(--surface); border-radius: 12px; padding: 16px 20px; margin: 24px 0; }
table { width: 100%; border-collapse: collapse; margin: 8px 0 16px; font-size: 15px; }
th, td { text-align: left; vertical-align: top; padding: 8px 8px 8px 0; border-bottom: 1px solid var(--line); }
footer { margin-top: 48px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
footer a { color: var(--muted); }
.lead { font-size: 17px; }
.scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.num td, table.num th { white-space: nowrap; padding-right: 12px; }
table.num td:not(:first-child), table.num th:not(:first-child) { text-align: right; }
nav.langs a { margin-left: 8px; }
nav a[aria-current] { color: var(--text); font-weight: 600; text-decoration: none; }
h3 { font-size: 17px; margin: 20px 0 4px; }
/* калькулятор «сдал или нет» (launch/build_guides.py) */
.calc label { display: block; font-size: 15px; margin-bottom: 4px; }
.calc input, .calc select { width: 100%; font: inherit; color: var(--text); background: var(--bg);
  border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; }
.calc input { max-width: 140px; }
.calc select { max-width: 140px; }
.calc .pass { color: var(--accent); }
.calc .fail { color: #C0392B; }
@media (prefers-color-scheme: dark) { .calc .fail { color: #FF6B5E; } }
.more { font-size: 15px; }
/* списки слов (launch/build_guides.py, wordlist) */
.lvnav { font-size: 15px; margin: 0 0 12px; }
.lvnav a { margin: 0 4px; }
a.dl { display: inline-block; background: var(--accent); color: var(--bg); text-decoration: none; font-weight: 600;
  border-radius: 8px; padding: 8px 16px; }
table.words td:first-child { font-size: 13px; width: 1%; padding-right: 12px; }
table.words td:nth-child(2) { width: 34%; padding-right: 12px; }
table.words small { color: var(--muted); font-size: 14px; }
