/* ADHD 笔记 — plain static site */

:root {
  --bg: #faf8f5;
  --surface: #ffffff;
  --text: #1c1917;
  --muted: #57534e;
  --border: #e7e5e4;
  --accent: #0f766e;
  --accent-soft: #ccfbf1;
  --en: #44403c;
  --zh: #1c1917;
  --link: #0f766e;
  --link-hover: #115e59;
  --max: 40rem;
  --pad: 1.25rem;
  --radius: 0.5rem;
  --font: "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei",
    system-ui, -apple-system, sans-serif;
  --font-en: "Source Serif 4", "Georgia", "Times New Roman", serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
}

a {
  color: var(--link);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.15em;
}

a:hover {
  color: var(--link-hover);
}

.wrap {
  max-width: calc(var(--max) + 2 * var(--pad));
  margin: 0 auto;
  padding: 0 var(--pad);
}

/* Header */
.site-header {
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  padding: 1rem 0;
}

.site-header .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1.5rem;
  justify-content: space-between;
}

.brand {
  text-decoration: none;
  color: var(--text);
}

.brand:hover {
  color: var(--accent);
}

.brand-title {
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.brand-sub {
  display: block;
  font-size: 0.8125rem;
  color: var(--muted);
  font-weight: 400;
  margin-top: 0.1rem;
}

.nav {
  display: flex;
  gap: 1rem;
  font-size: 0.9375rem;
}

.nav a {
  text-decoration: none;
  color: var(--muted);
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--accent);
}

/* Main */
main {
  padding: 2rem 0 3rem;
}

h1 {
  font-size: 1.75rem;
  line-height: 1.3;
  margin: 0 0 0.75rem;
  font-weight: 700;
}

h2 {
  font-size: 1.25rem;
  margin: 2rem 0 0.75rem;
  font-weight: 650;
}

.lead {
  font-size: 1.0625rem;
  color: var(--muted);
  margin: 0 0 1.5rem;
}

.meta {
  font-size: 0.875rem;
  color: var(--muted);
  margin: 0 0 1.5rem;
}

/* Cards / callouts */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.35rem;
  margin: 1.25rem 0;
}

.card h2:first-child,
.card p:first-child {
  margin-top: 0;
}

.disclaimer {
  background: var(--accent-soft);
  border: 1px solid #99f6e4;
  border-radius: var(--radius);
  padding: 1rem 1.15rem;
  font-size: 0.9375rem;
  color: #134e4a;
  margin: 1.5rem 0;
}

.disclaimer strong {
  display: block;
  margin-bottom: 0.35rem;
}

.article-list {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
}

.article-list li {
  margin: 0 0 1rem;
}

.article-list a {
  font-weight: 600;
  font-size: 1.0625rem;
  text-decoration: none;
}

.article-list a:hover {
  text-decoration: underline;
}

.article-list .desc {
  display: block;
  font-size: 0.875rem;
  color: var(--muted);
  font-weight: 400;
  margin-top: 0.25rem;
}

/* Bilingual article */
.article-header {
  margin-bottom: 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}

.article-header .title-en {
  font-family: var(--font-en);
  font-size: 1.5rem;
  font-weight: 600;
  margin: 0 0 0.35rem;
  line-height: 1.35;
}

.article-header .title-zh {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 1rem;
  color: var(--accent);
}

.byline {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.6;
}

.byline .en {
  font-family: var(--font-en);
  display: block;
  margin-bottom: 0.35rem;
}

.source-note {
  font-size: 0.8125rem;
  color: var(--muted);
  margin: 1rem 0 0;
  line-height: 1.55;
}

.pair {
  margin: 0 0 1.75rem;
  padding-bottom: 1.75rem;
  border-bottom: 1px dashed var(--border);
}

.pair:last-of-type {
  border-bottom: none;
}

.pair .en {
  font-family: var(--font-en);
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--en);
  margin: 0 0 0.85rem;
}

.pair .zh {
  font-size: 1.05rem;
  line-height: 1.85;
  color: var(--zh);
  margin: 0;
}

.pair .label {
  display: inline-block;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.35rem;
  font-family: var(--font);
}

.footnotes {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  font-size: 0.875rem;
  color: var(--muted);
}

.footnotes h2 {
  font-size: 1rem;
  margin: 0 0 0.75rem;
}

.footnotes ol {
  padding-left: 1.25rem;
  margin: 0;
}

.footnotes li {
  margin-bottom: 0.5rem;
}

.editor-note {
  margin-top: 2rem;
  font-size: 0.875rem;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.15rem;
}

.editor-note h2 {
  font-size: 0.9375rem;
  margin: 0 0 0.5rem;
  color: var(--text);
}

.back {
  margin: 0 0 1.5rem;
  font-size: 0.9375rem;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 0 2.5rem;
  font-size: 0.8125rem;
  color: var(--muted);
}

.site-footer p {
  margin: 0 0 0.5rem;
}

@media (min-width: 640px) {
  h1 {
    font-size: 2rem;
  }

  .article-header .title-en {
    font-size: 1.75rem;
  }

  .article-header .title-zh {
    font-size: 1.5rem;
  }

  main {
    padding: 2.5rem 0 4rem;
  }
}
