:root {
  color-scheme: light dark;
  --surface: #fcfcfb;
  --surface-2: #f1f0ea;
  --border: #dedcd3;
  --text: #17171a;
  --text-2: #52514e;
  --accent: #16352a;
  --link: #2a78d6;
  --flag: #b26a00;
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
}

@media (prefers-color-scheme: dark) {
  :root {
    --surface: #131414;
    --surface-2: #1d1f1e;
    --border: #35383a;
    --text: #f3f3f1;
    --text-2: #bcbcb5;
    --accent: #8fc79f;
    --link: #7fb2f0;
    --flag: #e0a44a;
  }
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--surface);
  color: var(--text);
  padding: 0 20px env(safe-area-inset-bottom, 24px);
}
main, .page-head, footer { max-width: 42rem; margin: 0 auto; }

.page-head {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px 0; border-bottom: 1px solid var(--border); flex-wrap: wrap;
}
.brand { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; color: var(--text); text-decoration: none; }
.page-head nav { display: flex; gap: 14px; font-size: 15px; }

a { color: var(--link); }
h1 { font-size: 30px; line-height: 1.2; margin: 28px 0 8px; }
h2 { font-size: 20px; margin: 32px 0 8px; }
h3 { font-size: 17px; margin: 22px 0 6px; }
p, li { color: var(--text); }
.lead { font-size: 18px; color: var(--text-2); }
.meta { color: var(--text-2); font-size: 14px; margin-top: 0; }
.flag { color: var(--flag); font-weight: 600; }
ul { padding-left: 20px; }
li { margin: 6px 0; }

table { width: 100%; border-collapse: collapse; margin: 12px 0; font-size: 15px; }
th, td { text-align: left; vertical-align: top; padding: 8px 10px 8px 0; border-bottom: 1px solid var(--border); }
th { color: var(--text-2); font-weight: 600; }

.note, .callout {
  background: var(--surface-2); border: 1px solid var(--border); border-left: 4px solid var(--accent);
  border-radius: 8px; padding: 12px 14px; margin: 24px 0; color: var(--text-2); font-size: 15px;
}
.callout strong { color: var(--text); }

footer {
  border-top: 1px solid var(--border); margin-top: 40px; padding: 20px 0 40px;
  color: var(--text-2); font-size: 14px;
}
