:root {
  color-scheme: light dark;
  --page: #f6f5f3;
  --surface: #ffffff;
  --surface-soft: #f1eeeb;
  --ink: #221c1d;
  --muted: #62595b;
  --line: #ddd5d1;
  --brand: #7a2131;
  --brand-strong: #531521;
  --accent: #b88a3b;
  --noc: #0e52a7;
  --success: #24704f;
  --code: #f2efed;
  /* Focus indicator: drawn outside the element over the page background, so a
     high-contrast ink ring plus a light halo clears 3:1 (WCAG 1.4.11) on every
     surface including the filled brand buttons. --accent does not (2.9:1). */
  --focus-ring: #221c1d;
  --focus-halo: #ffffff;
  --shadow: 0 10px 30px rgb(63 35 39 / 0.08);
  --radius: 0.6rem;
  --content: 60rem;

  /* Type scale. --text-base stays at 1rem so the reader's own browser font
     size is honoured (WCAG 1.4.4); nothing here drops below --text-xs and no
     size is declared in px, so a 200% zoom or a raised default reflows without
     loss. The clamp() preferred values mix rem with vw so they also grow when
     the reader raises the default size, not only when the viewport widens. */
  --text-xs: 0.8125rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-md: 0.9375rem;
  --text-lead: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  --text-h3: 1.0625rem;
  --text-h2: clamp(1.15rem, 1.05rem + 0.5vw, 1.35rem);
  --text-h1: clamp(1.5rem, 1.28rem + 1.1vw, 1.95rem);
  /* Interior pages sit a step under the landing hero, as before the rescale. */
  --text-h1-page: clamp(1.4rem, 1.22rem + 0.9vw, 1.75rem);

  --space-section: clamp(1.75rem, 1.45rem + 1.4vw, 2.5rem);
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 88% -8%, rgb(122 33 49 / 0.11), transparent 26rem),
    var(--page);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  font-size: var(--text-base);
  /* Kept at or above 1.5 so a reader override under WCAG 1.4.12 changes little. */
  line-height: 1.55;
}

img, svg { max-width: 100%; }

a {
  color: var(--brand);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.16em;
}

a:hover { color: var(--brand-strong); }

a:focus-visible,
button:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
  border-radius: 0.25rem;
  box-shadow: 0 0 0 4px var(--focus-halo);
}

.skip-link {
  position: fixed;
  z-index: 20;
  top: 0.65rem;
  left: 0.65rem;
  translate: 0 -160%;
  padding: 0.55rem 0.8rem;
  border-radius: 0.45rem;
  background: var(--ink);
  color: var(--surface);
  font-size: var(--text-sm);
  font-weight: 700;
}

.skip-link:focus { translate: 0; }

.container {
  width: min(calc(100% - 2rem), var(--content));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  z-index: 10;
  top: 0;
  border-bottom: 1px solid rgb(221 213 209 / 0.9);
  background: rgb(255 255 255 / 0.94);
  box-shadow: 0 2px 12px rgb(56 35 38 / 0.04);
  backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  min-height: 3.25rem;
  align-items: center;
  justify-content: space-between;
  gap: 1.1rem;
}

.brand {
  display: inline-flex;
  min-width: 15rem;
  align-items: center;
  gap: 0.6rem;
  color: var(--ink);
  text-decoration: none;
}

.brand-logo-frame {
  display: grid;
  width: 2.25rem;
  height: 2.25rem;
  flex: 0 0 2.25rem;
  place-items: center;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 0.4rem;
  background: #fff;
  box-shadow: 0 3px 12px rgb(63 35 39 / 0.08);
}

.brand-logo {
  width: 100%;
  height: 100%;
  padding: 0.15rem;
  object-fit: contain;
}

.brand-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  line-height: 1.2;
}

.brand-institution {
  color: var(--muted);
  /* Was 0.68rem (0.59rem on small screens), below any legible floor for a
     letter-spaced uppercase string. --text-xs is the floor for the whole site. */
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.brand-service {
  margin-top: 0.1rem;
  color: var(--brand-strong);
  font-size: var(--text-md);
  font-weight: 800;
  letter-spacing: -0.01em;
}

.nav-list {
  display: flex;
  margin: 0;
  padding: 0;
  align-items: center;
  gap: 0.2rem;
  list-style: none;
}

.nav-list a {
  display: block;
  /* Padding keeps the hit area past the 24px minimum target size (WCAG 2.5.8). */
  padding: 0.42rem 0.55rem;
  border-radius: 0.4rem;
  color: var(--muted);
  font-size: var(--text-sm);
  font-weight: 700;
  text-decoration: none;
}

.nav-list a:hover,
.nav-list a[aria-current="page"] {
  background: var(--surface-soft);
  color: var(--brand-strong);
}

main { min-height: calc(100vh - 12rem); }

.hero {
  padding-block: var(--space-section) clamp(1.5rem, 1.3rem + 0.9vw, 2rem);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(15rem, 0.78fr);
  align-items: center;
  gap: clamp(1.5rem, 1.1rem + 1.8vw, 2.75rem);
}

.eyebrow {
  margin: 0 0 0.55rem;
  color: var(--brand);
  font-size: var(--text-xs);
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

h1, h2, h3 {
  margin-top: 0;
  line-height: 1.25;
  /* Tracking loosened from -0.025em: at this smaller display scale the tighter
     value closed up the Greek diacritics. */
  letter-spacing: -0.012em;
}

h1 {
  max-width: 26ch;
  margin-bottom: 0.8rem;
  font-size: var(--text-h1);
}

h2 { font-size: var(--text-h2); }
h3 { font-size: var(--text-h3); }

.lead {
  /* Measure capped so a line stays inside the 80-character comfort range. */
  max-width: 60ch;
  color: var(--muted);
  font-size: var(--text-lead);
}

.actions {
  display: flex;
  margin-top: 1.1rem;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.button {
  display: inline-flex;
  /* 2.5rem = 40px tall, comfortably past the 24px minimum target size. */
  min-height: 2.5rem;
  padding: 0.5rem 0.8rem;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--brand);
  border-radius: 0.55rem;
  background: var(--brand);
  color: white;
  font-size: var(--text-md);
  font-weight: 700;
  text-decoration: none;
  box-shadow: 0 6px 18px rgb(63 35 39 / 0.16);
}

.button:hover { background: var(--brand-strong); color: white; }
.button.secondary { background: transparent; color: var(--brand); box-shadow: none; }
.button.secondary:hover { background: var(--surface-soft); color: var(--brand-strong); }

.address-card {
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.address-card .label {
  display: block;
  margin-bottom: 0.3rem;
  color: var(--muted);
  font-size: var(--text-sm);
  font-weight: 700;
}

.address-card code {
  display: block;
  overflow-wrap: anywhere;
  color: var(--brand-strong);
  font-size: var(--text-md);
  font-weight: 700;
}

.address-card p { margin-bottom: 0; color: var(--muted); font-size: var(--text-md); }

.section { padding-block: var(--space-section); }
.section.tinted { border-block: 1px solid var(--line); background: var(--surface-soft); }
.section-heading { max-width: 40rem; margin-bottom: 1.25rem; }
.section-heading p { color: var(--muted); }

.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.85rem;
}

.card {
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 5px 18px rgb(63 35 39 / 0.05);
}

.feature-icon {
  display: grid;
  width: 2rem;
  height: 2rem;
  margin-bottom: 0.65rem;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--brand) 22%, var(--line));
  border-radius: 0.55rem;
  background: color-mix(in srgb, var(--brand) 8%, var(--surface));
  color: var(--brand);
}

.feature-icon svg { width: 1.1rem; height: 1.1rem; }

.page-kicker {
  display: flex;
  margin-bottom: 0.6rem;
  align-items: center;
  gap: 0.5rem;
}

.page-kicker .eyebrow { margin: 0; }

.page-icon {
  width: 1.15rem;
  height: 1.15rem;
  color: var(--brand);
}

.standalone-icon {
  width: 1.75rem;
  height: 1.75rem;
  margin-bottom: 0.6rem;
  color: var(--brand);
}

.card p:last-child { margin-bottom: 0; }

.page-hero {
  padding-block: clamp(1.5rem, 1.25rem + 1.2vw, 2.25rem) 1.1rem;
}

.page-hero h1 { font-size: var(--text-h1-page); }

.prose {
  max-width: 46rem;
  padding-bottom: 2.75rem;
}

.prose h2 { margin-top: 1.9rem; }
.prose h3 { margin-top: 1.4rem; }
.prose p, .prose li { color: var(--muted); }
/* Running text keeps a readable measure even where the block itself is wider. */
.prose p, .prose li { max-width: 68ch; }
.prose strong { color: var(--ink); }

.steps {
  margin: 1rem 0;
  padding: 0;
  counter-reset: step;
  list-style: none;
}

.steps > li {
  position: relative;
  margin-bottom: 0.6rem;
  padding: 0.85rem 0.9rem 0.85rem 3.15rem;
  border: 1px solid var(--line);
  border-radius: 0.7rem;
  background: var(--surface);
  counter-increment: step;
}

.steps > li::before {
  position: absolute;
  top: 0.8rem;
  left: 0.85rem;
  display: grid;
  width: 1.6rem;
  height: 1.6rem;
  place-items: center;
  border-radius: 50%;
  background: var(--brand);
  color: white;
  content: counter(step);
  font-size: var(--text-sm);
  font-weight: 800;
}

.steps h3 { margin: 0 0 0.3rem; }
.steps p { margin: 0; }

.callout {
  margin-block: 1.25rem;
  padding: 0.85rem 1rem;
  border-inline-start: 0.25rem solid var(--accent);
  border-radius: 0 0.6rem 0.6rem 0;
  background: color-mix(in srgb, var(--accent) 12%, var(--surface));
}

.callout.success { border-color: var(--success); background: color-mix(in srgb, var(--success) 10%, var(--surface)); }
.callout p:last-child { margin-bottom: 0; }

code, kbd {
  padding: 0.12em 0.35em;
  border: 1px solid var(--line);
  border-radius: 0.3rem;
  background: var(--code);
  color: var(--ink);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  /* em, not rem: monospace runs small, so this tracks whatever text it sits in. */
  font-size: 0.9375em;
}

.specs {
  display: grid;
  margin-block: 1.25rem;
  grid-template-columns: minmax(8rem, 0.34fr) 1fr;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 0.7rem;
  background: var(--surface);
}

.specs dt, .specs dd { margin: 0; padding: 0.65rem 0.85rem; border-bottom: 1px solid var(--line); }
.specs dt { color: var(--muted); font-weight: 700; }
.specs dd { overflow-wrap: anywhere; }
.specs > :nth-last-child(-n + 2) { border-bottom: 0; }

.status-list { padding: 0; list-style: none; }
.status-list li { display: grid; grid-template-columns: 8.5rem 1fr; gap: 0.85rem; padding-block: 0.8rem; border-bottom: 1px solid var(--line); }
.status-list strong { color: var(--ink); }

.site-footer {
  padding-block: 1.15rem;
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.noc-logo {
  width: 2rem;
  height: 2rem;
  flex: 0 0 2rem;
}

.footer-brand span {
  display: flex;
  flex-direction: column;
  line-height: 1.35;
}

.footer-brand strong { font-size: var(--text-md); }
/* Was 0.78rem; raised to the secondary-text size like every other small label. */
.footer-brand small { color: var(--muted); font-size: var(--text-sm); }
.footer-links { display: flex; flex-wrap: wrap; gap: 0.8rem; }
.footer-links a { padding-block: 0.2rem; font-size: var(--text-sm); font-weight: 700; text-decoration: none; }

.starter {
  display: grid;
  min-height: 50vh;
  place-items: center;
  padding: clamp(1.5rem, 1.2rem + 1.4vw, 2.5rem) 1rem;
}

.starter .card { max-width: 36rem; }
.starter-card { width: 100%; }

.starter-brand {
  display: flex;
  margin-bottom: 0.85rem;
  align-items: center;
  gap: 0.5rem;
  color: var(--muted);
  font-size: var(--text-sm);
  font-weight: 700;
}

.starter-brand img { width: 1.75rem; height: 1.75rem; }

@media (max-width: 58rem) {
  .header-inner {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.5rem;
    padding-block: 0.6rem;
  }
  .site-header { position: static; }
  .brand { min-width: 0; }
  .nav-list { width: 100%; overflow-x: auto; padding-bottom: 0.15rem; }
  .hero-grid, .grid { grid-template-columns: 1fr; }
  .hero { padding-top: 1.75rem; }
}

@media (max-width: 38rem) {
  .container { width: min(calc(100% - 1.25rem), var(--content)); }
  /* No font-size overrides here: the header stacks at this width, so the brand
     copy and nav fit without shrinking any label below --text-xs. */
  .specs { grid-template-columns: 1fr; }
  .specs dt { padding-bottom: 0.15rem; border-bottom: 0; }
  .specs dd { padding-top: 0.15rem; }
  .specs > :nth-last-child(-n + 2) { border-bottom: 1px solid var(--line); }
  .specs > :last-child { border-bottom: 0; }
  .status-list li { grid-template-columns: 1fr; gap: 0.3rem; }
  .footer-inner { align-items: flex-start; flex-direction: column; }
}

@media (prefers-color-scheme: dark) {
  :root {
    --page: #151112;
    --surface: #1e181a;
    --surface-soft: #2a2023;
    --ink: #f6f1ef;
    --muted: #c4b6b8;
    --line: #493a3e;
    --brand: #e6a2ad;
    --brand-strong: #f4c8cf;
    --accent: #d4ad67;
    --noc: #72a8e8;
    --success: #76cba6;
    --code: #2b2224;
    --focus-ring: #f6f1ef;
    --focus-halo: #151112;
    --shadow: 0 12px 34px rgb(0 0 0 / 0.3);
  }

  .site-header { background: rgb(21 17 18 / 0.94); border-color: rgb(73 58 62 / 0.9); }
  .brand-logo-frame { border-color: #6f6064; background: #fff; }
  .button { color: #201012; }
  .button:hover { color: #201012; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
