:root {
  --bg: #f7f8f4;
  --surface: #ffffff;
  --surface-2: #eef3ed;
  --text: #172019;
  --muted: #5d6a61;
  --line: #dce5dd;
  --accent: #1f6f4a;
  --accent-2: #174f37;
  --accent-soft: #dff0e6;
  --shadow: 0 18px 50px rgba(27, 48, 35, .08);
  --header-bg: rgba(247, 248, 244, .88);
  --radius: 22px;
  --max: 1180px;
}

html[data-theme="dark"] {
  --bg: #0f1411;
  --surface: #151d18;
  --surface-2: #1b261f;
  --text: #ecf4ee;
  --muted: #a8b7ac;
  --line: #29372e;
  --accent: #73d39f;
  --accent-2: #a8e8c3;
  --accent-soft: #173225;
  --shadow: 0 18px 50px rgba(0, 0, 0, .25);
  --header-bg: rgba(15, 20, 17, .88);
}

@media (prefers-color-scheme: dark) {
  html[data-theme="auto"] {
    --bg: #0f1411;
    --surface: #151d18;
    --surface-2: #1b261f;
    --text: #ecf4ee;
    --muted: #a8b7ac;
    --line: #29372e;
    --accent: #73d39f;
    --accent-2: #a8e8c3;
    --accent-soft: #173225;
    --shadow: 0 18px 50px rgba(0, 0, 0, .25);
    --header-bg: rgba(15, 20, 17, .88);
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 92px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 17px;
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
  transition: background .2s ease, color .2s ease;
}
a { color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
.shell { width: min(calc(100% - 40px), var(--max)); margin: 0 auto; }
.skip-link { position: fixed; left: 16px; top: -80px; z-index: 99; background: var(--text); color: var(--bg); padding: 10px 14px; border-radius: 10px; text-decoration: none; }
.skip-link:focus { top: 12px; }

.site-header { position: sticky; top: 0; z-index: 50; border-bottom: 1px solid color-mix(in srgb, var(--line) 78%, transparent); background: var(--header-bg); backdrop-filter: blur(14px); }
.header-inner { min-height: 72px; display: flex; align-items: center; gap: 28px; }
.brand { display: flex; align-items: center; gap: 11px; text-decoration: none; margin-right: auto; }
.brand-mark { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 13px; background: var(--accent); color: var(--bg); font-weight: 850; letter-spacing: -.04em; }
html[data-theme="dark"] .brand-mark { color: #0f1411; }
.brand-copy { display: flex; flex-direction: column; line-height: 1.1; }
.brand-copy strong { font-size: 14px; }
.brand-copy small { color: var(--muted); margin-top: 4px; }
.top-nav { display: flex; gap: 22px; font-size: 14px; font-weight: 650; }
.top-nav a { text-decoration: none; color: var(--muted); }
.top-nav a:hover { color: var(--text); }
.theme-toggle { width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); color: var(--text); display: grid; place-items: center; cursor: pointer; box-shadow: 0 4px 14px rgba(0,0,0,.04); }
.icon { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-moon { display: none; }
html[data-theme="dark"] .icon-sun { display: none; }
html[data-theme="dark"] .icon-moon { display: block; }
@media (prefers-color-scheme: dark) {
  html[data-theme="auto"] .icon-sun { display: none; }
  html[data-theme="auto"] .icon-moon { display: block; }
}

.hero { position: relative; overflow: hidden; padding: 92px 0 82px; border-bottom: 1px solid var(--line); }
.hero::before { content: ""; position: absolute; inset: -35% auto auto 58%; width: 620px; height: 620px; border-radius: 50%; background: radial-gradient(circle, color-mix(in srgb, var(--accent) 18%, transparent), transparent 66%); pointer-events: none; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(280px, .6fr); gap: 72px; align-items: end; position: relative; }
.eyebrow, .section-kicker { text-transform: uppercase; letter-spacing: .12em; font-size: 12px; font-weight: 800; color: var(--accent); margin: 0 0 12px; }
h1, h2, h3 { line-height: 1.08; letter-spacing: -.035em; margin: 0; }
h1 { font-size: clamp(3rem, 7vw, 6.2rem); max-width: 980px; }
.lead { font-size: clamp(1.12rem, 1.6vw, 1.35rem); line-height: 1.55; color: var(--muted); max-width: 760px; margin: 28px 0 0; }
.hero-actions { display: flex; gap: 12px; margin-top: 34px; flex-wrap: wrap; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 18px; border-radius: 13px; text-decoration: none; font-weight: 750; font-size: 15px; }
.button.primary { background: var(--accent); color: var(--bg); }
html[data-theme="dark"] .button.primary { color: #0f1411; }
.button.secondary { border: 1px solid var(--line); background: var(--surface); }
.candidate-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); display: flex; gap: 16px; align-items: center; }
.candidate-monogram { min-width: 64px; width: 64px; height: 64px; display: grid; place-items: center; border-radius: 20px; background: var(--accent-soft); color: var(--accent-2); font-weight: 850; font-size: 22px; }
.candidate-name { font-weight: 850; margin: 0 0 4px; }
.candidate-role { color: var(--muted); font-size: 14px; line-height: 1.45; margin: 0; }

.content-layout { display: grid; grid-template-columns: 220px minmax(0, 780px); gap: 76px; justify-content: center; padding-top: 72px; }
.toc { position: sticky; top: 108px; align-self: start; display: flex; flex-direction: column; gap: 5px; font-size: 13px; }
.toc-title { font-size: 12px; font-weight: 850; text-transform: uppercase; letter-spacing: .11em; color: var(--muted); margin: 0 0 12px; }
.toc a { text-decoration: none; color: var(--muted); padding: 6px 0; border-left: 2px solid transparent; padding-left: 12px; }
.toc a:hover, .toc a.active { color: var(--text); border-color: var(--accent); }
.article { min-width: 0; }
.article-section { padding: 0 0 76px; }
.article-section + .article-section { border-top: 1px solid var(--line); padding-top: 72px; }
.article h2 { font-size: clamp(2.1rem, 4vw, 3.5rem); margin-bottom: 28px; }
.article h3 { font-size: clamp(1.5rem, 3vw, 2.1rem); margin-bottom: 22px; }
.article p { margin: 0 0 20px; }
.article p:last-child { margin-bottom: 0; }
.major-section { position: relative; }
.subsection { margin-top: 52px; padding-top: 42px; border-top: 1px solid var(--line); }
.number-badge { display: inline-flex; padding: 6px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-2); font-size: 12px; font-weight: 850; margin-bottom: 14px; }

.quote-card, .promise-card, .web-card { border-radius: var(--radius); padding: 26px 28px; margin: 30px 0; }
.quote-card { background: var(--surface-2); border: 1px solid var(--line); }
.quote-card p { font-size: 1.12em; line-height: 1.6; margin: 0; }
.quote-card.emphasis { border-left: 4px solid var(--accent); }
.promise-card { background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 26%, var(--line)); }
.promise-label { display: block; text-transform: uppercase; letter-spacing: .12em; font-size: 11px; font-weight: 850; color: var(--accent-2); margin-bottom: 8px; }
.promise-card p { margin: 0; font-weight: 650; }
.web-card { background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 4px; }
.web-card strong { font-size: clamp(1.6rem, 4vw, 2.5rem); letter-spacing: -.04em; color: var(--accent); }
.web-card small { color: var(--muted); margin-top: 6px; }

.callout-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 32px 0 36px; }
.callout { padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); display: flex; flex-direction: column; gap: 5px; }
.callout strong { font-size: 14px; }
.callout span { color: var(--muted); font-size: 13px; line-height: 1.45; }

.letter-list { list-style: none; counter-reset: alpha; display: grid; gap: 10px; padding: 0; margin: 26px 0 30px; }
.letter-list li { counter-increment: alpha; display: grid; grid-template-columns: 34px 1fr; gap: 12px; align-items: start; }
.letter-list li::before { content: counter(alpha, upper-alpha); width: 30px; height: 30px; border-radius: 10px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent-2); font-size: 12px; font-weight: 850; }
.check-list { list-style: none; padding: 0; margin: 22px 0 28px; display: grid; gap: 10px; }
.check-list li { position: relative; padding-left: 28px; }
.check-list li::before { content: "✓"; position: absolute; left: 0; top: 0; color: var(--accent); font-weight: 900; }
.metric-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 28px 0 34px; }
.metric-grid span { padding: 14px 16px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); font-weight: 650; font-size: 14px; }
.ranking-card { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 28px 0 34px; }
.ranking-card div { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 20px; display: flex; align-items: baseline; gap: 12px; }
.ranking-card strong { font-size: 28px; color: var(--accent); }
.ranking-card span { font-weight: 800; }
.closing-section { padding-bottom: 100px; }
.signature { margin-top: 34px; display: flex; flex-direction: column; gap: 3px; }
.signature strong { font-size: 20px; }
.signature span { color: var(--muted); font-size: 14px; }

.site-footer { border-top: 1px solid var(--line); padding: 28px 0; color: var(--muted); font-size: 13px; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.footer-inner a { text-decoration: none; color: var(--text); font-weight: 700; }

@media (max-width: 980px) {
  .top-nav { display: none; }
  .hero { padding: 70px 0 62px; }
  .hero-grid { grid-template-columns: 1fr; gap: 36px; }
  .candidate-card { max-width: 520px; }
  .content-layout { grid-template-columns: 1fr; gap: 0; }
  .toc { display: none; }
  .article { max-width: 780px; margin: 0 auto; }
}

@media (max-width: 700px) {
  body { font-size: 16px; }
  .shell { width: min(calc(100% - 28px), var(--max)); }
  .header-inner { min-height: 64px; }
  .brand-copy strong { font-size: 13px; }
  .hero { padding: 54px 0 48px; }
  h1 { font-size: clamp(2.75rem, 13vw, 4rem); }
  .lead { font-size: 1.06rem; }
  .candidate-card { padding: 18px; border-radius: 18px; }
  .candidate-monogram { width: 54px; height: 54px; min-width: 54px; border-radius: 16px; }
  .content-layout { padding-top: 52px; }
  .article-section { padding-bottom: 58px; }
  .article-section + .article-section { padding-top: 56px; }
  .article h2 { font-size: 2.15rem; }
  .article h3 { font-size: 1.55rem; }
  .quote-card, .promise-card, .web-card { padding: 21px; border-radius: 18px; }
  .callout-grid, .ranking-card, .metric-grid { grid-template-columns: 1fr; }
  .footer-inner { align-items: flex-start; flex-direction: column; }
}

@media print {
  .site-header, .toc, .hero-actions, .theme-toggle, .site-footer { display: none !important; }
  body { background: #fff; color: #111; font-size: 11pt; }
  .hero { padding: 0 0 28px; }
  .hero::before { display: none; }
  .hero-grid, .content-layout { display: block; }
  .candidate-card { box-shadow: none; margin-top: 20px; }
  .article { max-width: none; }
  .article-section { break-inside: avoid-page; }
  .subsection { break-inside: auto; }
  .quote-card, .promise-card, .web-card, .metric-grid span, .ranking-card div, .callout { background: #fff !important; color: #111 !important; box-shadow: none !important; }
}
