:root {
  --ink: #102033;
  --heading: #12315c;
  --blue: #145fc1;
  --sky: #e5f2ff;
  --paper: #ffffff;
  --mist: #f6faff;
  --line: #c6d6e6;
  --muted: #425b76;
  --gold: #d99a22;
  --teal: #087b7d;
  --green: #1f6f4a;
  --coral: #ad3e35;
  --body-bg: linear-gradient(180deg, #ffffff 0%, #f6faff 52%, #ffffff 100%);
  --header-bg: rgba(5, 14, 28, 0.97);
  --panel-bg: #ffffff;
  --nav-active-bg: #145fc1;
  --nav-text: #f5f8ff;
  --nav-muted: #dbe9f8;
  --button-bg: #145fc1;
  --button-text: #ffffff;
  --footer-bg: #0f2647;
  --footer-text: #dbe9f8;
  --shadow: 0 18px 42px rgba(18, 49, 92, 0.13);
}

:root[data-theme="dark"] {
  --ink: #f7fbff;
  --heading: #ffffff;
  --blue: #8bd6ff;
  --sky: #10243b;
  --paper: #08182c;
  --mist: #07111f;
  --line: #3a5f84;
  --muted: #c1d0e3;
  --gold: #ffc766;
  --teal: #59d6ff;
  --green: #54df8f;
  --coral: #ff7d8d;
  --body-bg: linear-gradient(180deg, #07111f 0%, #0b1627 52%, #07111f 100%);
  --header-bg: rgba(5, 14, 28, 0.97);
  --panel-bg: #10243b;
  --nav-active-bg: #145fc1;
  --nav-text: #f5f8ff;
  --nav-muted: #dbe9f8;
  --button-bg: #7cc8ff;
  --button-text: #06101d;
  --footer-bg: #050c16;
  --footer-text: #dbe9f8;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.34);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--body-bg);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.6;
}
img, svg { max-width: 100%; }
a { color: var(--blue); text-underline-offset: 0.18em; }
a:focus-visible, button:focus-visible { outline: 3px solid rgba(20, 95, 193, 0.3); outline-offset: 3px; }
.skip-link { position: absolute; left: 1rem; top: -4rem; z-index: 100; padding: .65rem .85rem; color: #fff; background: #12315c; border-radius: 6px; }
.skip-link:focus { top: 1rem; }
.site-header { position: sticky; top: 0; z-index: 50; background: var(--header-bg); border-bottom: 1px solid #2d5f92; backdrop-filter: blur(10px); }
.nav-wrap, .container { width: min(1120px, calc(100% - 32px)); margin: 0 auto; }
.nav-wrap { min-height: 74px; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { display: inline-flex; align-items: center; gap: .6rem; color: #ffffff; font-weight: 800; text-decoration: none; white-space: nowrap; }
.brand img { width: 40px; height: 40px; }
.site-nav { display: flex; align-items: center; gap: .15rem; flex-wrap: wrap; justify-content: flex-end; }
.site-nav a { display: inline-flex; min-height: 44px; align-items: center; border: 1px solid transparent; border-radius: 8px; padding: 0 .72rem; background: transparent; color: var(--nav-text); font-size: .95rem; font-weight: 800; text-decoration: none; }
.site-nav a[aria-current="page"], .site-nav a:hover { background: var(--nav-active-bg); color: #ffffff; }
.theme-toggle { display: inline-flex; min-height: 42px; align-items: center; gap: .4rem; border: 1px solid #2d71b8; border-radius: 8px; padding: .45rem .7rem; background: rgba(20, 95, 193, .18); color: #ffffff; font: inherit; font-weight: 800; cursor: pointer; white-space: nowrap; }
.theme-toggle:hover { background: rgba(20, 95, 193, .34); }
.nav-toggle { display: none; min-width: 72px; height: 44px; border: 1px solid #2d71b8; border-radius: 8px; padding: 0 .7rem; background: rgba(20, 95, 193, .18); color: #ffffff; font: inherit; font-weight: 800; cursor: pointer; }
.hero { color: #f5f8ff; background: linear-gradient(135deg, #12315c 0%, #145fc1 56%, #087b7d 100%); padding: 5.5rem 0 4.5rem; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 470px); gap: 2rem; align-items: center; }
.eyebrow { margin: 0 0 .75rem; color: var(--gold); font-weight: 800; text-transform: uppercase; letter-spacing: .08em; font-size: .78rem; }
h1, h2, h3 { color: var(--heading); line-height: 1.15; }
.hero h1 { color: #fff; margin: 0; font-size: clamp(2.5rem, 7vw, 5.2rem); }
.hero .lead { color: #dbe9f8; font-size: 1.2rem; max-width: 690px; }
.hero-card { padding: 1rem; border-radius: 8px; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.3); box-shadow: var(--shadow); }
.hero-card img { display: block; border-radius: 6px; }
.actions, .hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.25rem; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: .72rem 1rem; border-radius: 6px; border: 1px solid var(--button-bg); background: var(--button-bg); color: var(--button-text); font-weight: 800; text-decoration: none; }
.button.gold { background: var(--gold); border-color: var(--gold); color: #221600; }
.button.secondary { background: transparent; color: inherit; border-color: currentColor; }
.status-line, .pill-row { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; }
.status-line span, .pill { display: inline-flex; align-items: center; border-radius: 999px; padding: .35rem .6rem; border: 1px solid var(--line); background: var(--panel-bg); color: var(--ink); font-size: .9rem; }
.hero .status-line span { background: rgba(255,255,255,.14); color: #fff; border-color: rgba(255,255,255,.3); }
.section { padding: 4rem 0; }
.section.compact { padding: 2.5rem 0; }
.section.alt { background: rgba(229, 242, 255, .5); }
:root[data-theme="dark"] .section.alt { background: rgba(16, 36, 59, .72); }
.section-intro, .lead { color: var(--muted); max-width: 780px; }
.hero-content { max-width: 760px; }
.page-hero, .sub-hero { padding: 4.5rem 0 4rem; }
.article-body { max-width: 820px; }
.grid { display: grid; gap: 1rem; }
.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.panel, .note { background: var(--panel-bg); border: 1px solid var(--line); border-radius: 8px; padding: 1.2rem; box-shadow: var(--shadow); }
.panel h3, .note h3 { margin-top: 0; }
.plain-list { padding-left: 1.2rem; }
.site-footer { color: var(--footer-text); background: var(--footer-bg); padding: 2.5rem 0; }
.site-footer a { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 1rem; }
.footer-links { display: flex; flex-direction: column; gap: .35rem; }
.footer-bottom { margin-top: 1.5rem; color: #bdd0e5; font-size: .95rem; }

@media (max-width: 820px) {
  .nav-toggle { display: inline-flex; align-items: center; justify-content: center; }
  .site-nav { position: absolute; left: 16px; right: 16px; top: 74px; display: none; flex-direction: column; align-items: stretch; padding: .75rem; background: var(--header-bg); border: 1px solid #2d71b8; border-radius: 8px; box-shadow: var(--shadow); }
  .site-nav.is-open { display: flex; }
  .site-nav a { justify-content: center; }
  .theme-toggle { margin-left: auto; }
  .hero-grid, .two, .three, .four, .footer-grid { grid-template-columns: 1fr; }
  .hero { padding: 4rem 0 3rem; }
}
