/* NIARB Labs — Enterprise design system */

:root {
  --font-sans: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: 'IBM Plex Serif', Georgia, serif;
  --font-mono: 'IBM Plex Mono', Consolas, monospace;

  --ink: #0f172a;
  --ink-soft: #334155;
  --ink-muted: #64748b;
  --ink-faint: #94a3b8;

  --accent: #0f766e;
  --accent-deep: #0c4a6e;
  --accent-light: #ecfdf5;
  --accent-subtle: rgba(15, 118, 110, 0.08);

  --bg: #ffffff;
  --bg-muted: #f8fafc;
  --bg-subtle: #f1f5f9;
  --bg-dark: #0f172a;
  --border: #e2e8f0;
  --border-strong: #cbd5e1;

  --header-h: 72px;
  --header-offset: 72px;
  --container: 1140px;
  --container-narrow: 760px;
  --radius: 8px;
  --radius-lg: 12px;
  --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 4px 20px rgba(15, 23, 42, 0.07);
  --shadow-lg: 0 12px 40px rgba(15, 23, 42, 0.06);
  --transition: 0.2s ease;
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  min-width: 0;
  max-width: 100%;
  padding-top: var(--header-offset, var(--header-h));
  -webkit-tap-highlight-color: transparent;
}

a { color: var(--accent-deep); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Icons */
.icon {
  display: block;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
}

.icon--sm { width: 16px; height: 16px; }
.icon--info { width: 18px; height: 18px; color: var(--accent); }

/* Layout */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 32px;
}

.container--narrow { max-width: var(--container-narrow); }

#main-content {
  overflow-x: clip;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-sans);
  font-size: 14px;
  font-weight: 500;
  padding: 11px 22px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  text-decoration: none;
  transition: all var(--transition);
  cursor: pointer;
}

.btn:hover { text-decoration: none; }

.btn--sm { padding: 9px 18px; font-size: 13px; }

.btn--primary {
  background: var(--accent-deep);
  color: #fff;
  border-color: var(--accent-deep);
}

.btn--primary:hover {
  background: #082f49;
  border-color: #082f49;
  color: #fff;
  box-shadow: 0 2px 8px rgba(12, 74, 110, 0.25);
}

.btn--outline {
  background: var(--bg);
  color: var(--ink);
  border-color: var(--border-strong);
}

.btn--outline:hover {
  border-color: var(--accent-deep);
  color: var(--accent-deep);
  background: var(--bg-muted);
}

/* Typography utilities */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.eyebrow--light { color: rgba(255, 255, 255, 0.55); }

/* ========== HEADER ========== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 100;
  padding-top: env(safe-area-inset-top);
  padding-left: max(0px, env(safe-area-inset-left));
  padding-right: max(0px, env(safe-area-inset-right));
  background: transparent;
  pointer-events: none;
  transition: padding 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.site-header.is-scrolled {
  padding-top: calc(4px + env(safe-area-inset-top));
  padding-left: max(24px, env(safe-area-inset-left));
  padding-right: max(24px, env(safe-area-inset-right));
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 32px;
  gap: 20px;
  pointer-events: auto;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid transparent;
  border-bottom-color: var(--border);
  border-radius: 0;
  box-shadow: none;
  transition:
    padding 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    border-radius 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    box-shadow 0.35s cubic-bezier(0.4, 0, 0.2, 1),
    border-color 0.35s ease,
    gap 0.35s ease,
    max-width 0.35s ease;
}

/* Pill: shorter via padding only — logo stays same size */
.site-header.is-scrolled .site-header__inner {
  padding: 0 20px;
  border-radius: 999px;
  border-color: var(--border);
  box-shadow: var(--shadow-sm);
  gap: 14px;
  max-width: min(960px, calc(100% - 16px));
  margin-inline: auto;
  line-height: 1;
}

.site-header.is-scrolled .site-header__nav a {
  font-size: 13px;
  line-height: 1.2;
  padding-bottom: 0;
}

.site-header.is-scrolled .site-header__nav {
  gap: 20px;
}

.site-header.is-scrolled .site-header__actions .btn--sm {
  padding: 4px 12px;
  font-size: 12px;
  min-height: 0;
  line-height: 1.2;
}

.site-header__brand {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: inherit;
  flex-shrink: 0;
  transition: gap 0.35s ease;
}

.site-header.is-scrolled .site-header__brand {
  gap: 0;
}

.site-header__brand:hover { text-decoration: none; }

.site-header__logo {
  height: 52px;
  width: auto;
  max-width: 280px;
  object-fit: contain;
  object-position: left center;
  flex-shrink: 0;
  display: block;
  line-height: 0;
}

.site-header__divider {
  width: 1px;
  height: 40px;
  flex-shrink: 0;
  background: linear-gradient(
    180deg,
    transparent 0%,
    var(--border-strong) 20%,
    rgba(12, 74, 110, 0.35) 50%,
    var(--border-strong) 80%,
    transparent 100%
  );
  transition: opacity 0.3s ease, width 0.3s ease, margin 0.3s ease;
}

.site-header.is-scrolled .site-header__divider {
  opacity: 0;
  width: 0;
  margin: 0;
}

.site-header__expansion {
  display: flex;
  flex-direction: column;
  gap: 5px;
  min-width: 0;
  overflow: hidden;
  transition: opacity 0.3s ease, max-width 0.35s ease, margin 0.3s ease;
}

.site-header.is-scrolled .site-header__expansion {
  opacity: 0;
  max-width: 0;
  margin: 0;
  pointer-events: none;
}

.site-header__expansion-rule {
  display: block;
  width: 100%;
  max-width: 220px;
  height: 1px;
  background: linear-gradient(
    90deg,
    var(--accent-deep) 0%,
    rgba(15, 118, 110, 0.45) 55%,
    transparent 100%
  );
}

.site-header__fullform {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin: 0;
}

.site-header__fullform-line {
  display: block;
  font-size: 11px;
  font-weight: 500;
  line-height: 1.35;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
}

.site-header__fullform-line--accent {
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-deep);
}

@media (max-width: 600px) {
  .site-header__brand {
    flex-direction: row;
    align-items: center;
    gap: 8px;
  }

  .site-header__divider {
    display: none;
  }

  .site-header__logo {
    height: 44px;
    max-width: 210px;
  }

  .site-header__expansion-rule {
    max-width: 160px;
  }

  .site-header__fullform-line {
    font-size: 9.5px;
  }

  .site-header__fullform-line--accent {
    font-size: 8.5px;
    letter-spacing: 0.09em;
  }
}

.site-header__nav {
  display: flex;
  align-items: center;
  gap: 32px;
  margin-left: auto;
}

.site-header__nav a {
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-muted);
  text-decoration: none;
  transition: color var(--transition);
  position: relative;
  padding-bottom: 2px;
}

.site-header__nav a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 1.5px;
  background: var(--accent-deep);
  transition: width var(--transition);
}

.site-header__nav a:hover {
  color: var(--ink);
  text-decoration: none;
}

.site-header__nav a:hover::after { width: 100%; }

.site-header__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.site-header__actions .btn--sm {
  transition: padding 0.35s ease, font-size 0.35s ease;
}

.site-header__toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  border: none;
  background: none;
  cursor: pointer;
}

.site-header__toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--ink);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

@media (max-width: 900px) {
  .site-header.is-scrolled {
    padding-left: max(20px, env(safe-area-inset-left));
    padding-right: max(20px, env(safe-area-inset-right));
  }

  .site-header__inner {
    padding: 6px 20px;
    gap: 10px;
    align-items: center;
    position: relative;
    z-index: 2;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .site-header.is-scrolled .site-header__inner {
    padding: 0 14px;
    border-radius: 999px;
    max-width: calc(100% - 16px);
  }

  .site-header.is-scrolled .site-header__toggle {
    min-width: 34px;
    min-height: 34px;
    padding: 4px;
  }

  .site-header__nav {
    position: fixed;
    top: var(--header-offset, var(--header-h));
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg);
    flex-direction: column;
    align-items: stretch;
    padding: 16px 20px;
    padding-bottom: max(24px, env(safe-area-inset-bottom));
    gap: 0;
    border-top: 1px solid var(--border);
    border-bottom: none;
    box-shadow: var(--shadow-md);
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.25s ease, opacity 0.25s ease, visibility 0.25s ease;
    margin-left: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    z-index: 1;
    pointer-events: none;
  }

  .site-header__nav.open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .site-header__nav a:not(.site-header__nav-cta) {
    font-size: 16px;
    padding: 14px 8px;
    min-height: 48px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--border);
  }

  .site-header__nav a::after { display: none; }

  .site-header__nav-cta {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    margin-top: 16px;
    padding: 12px 22px !important;
    min-height: 48px;
    background: var(--accent-deep);
    color: #fff !important;
    border-radius: var(--radius);
    font-weight: 500;
    text-align: center;
  }

  .site-header__nav-cta:hover {
    background: #082f49;
    text-decoration: none;
  }

  .site-header__toggle {
    display: flex;
    min-width: 44px;
    min-height: 44px;
    align-items: center;
    justify-content: center;
  }

  .site-header__toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
  .site-header__toggle.active span:nth-child(2) { opacity: 0; }
  .site-header__toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

  .site-header__actions .btn { display: none; }
}

.site-header__nav-cta { display: none; }

.site-header__backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.4);
  z-index: 0;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.site-header__backdrop.is-visible {
  display: block;
  opacity: 1;
  pointer-events: auto;
}

/* ========== HERO ========== */
.hero {
  position: relative;
  padding: 88px 0 96px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, var(--accent-deep) 0%, var(--accent) 100%);
}

.hero__bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 70% 20%, rgba(12, 74, 110, 0.04) 0%, transparent 70%),
    radial-gradient(ellipse 50% 40% at 20% 80%, rgba(15, 118, 110, 0.03) 0%, transparent 60%);
  pointer-events: none;
}

.hero__grid {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 64px;
  align-items: start;
}

.hero__title {
  font-family: var(--font-serif);
  font-size: clamp(2.25rem, 4vw, 3rem);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.025em;
  color: var(--ink);
  margin-bottom: 20px;
}

.hero__lead {
  font-size: 1.0625rem;
  color: var(--ink-soft);
  line-height: 1.75;
  max-width: 540px;
  margin-bottom: 32px;
}

.hero__actions { display: flex; gap: 12px; flex-wrap: wrap; }

.hero__panel-inner {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-md);
}

.hero__panel-label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: 20px;
}

.hero__stats { display: flex; flex-direction: column; gap: 0; }

.hero__stat {
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}

.hero__stat:last-child { border-bottom: none; padding-bottom: 0; }
.hero__stat:first-child { padding-top: 0; }

.hero__stat dt {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: 2px;
}

.hero__stat dd {
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
}

@media (max-width: 900px) {
  .hero { padding: 56px 0 64px; }
  .hero__grid { grid-template-columns: 1fr; gap: 40px; }
}

/* ========== SECTIONS ========== */
.section { padding: 80px 0; }

.section--muted { background: var(--bg-muted); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }

.section--dark {
  background: linear-gradient(165deg, #0f172a 0%, #1e293b 100%);
  color: #f8fafc;
  position: relative;
}

.section--dark::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 50% at 80% 20%, rgba(15, 118, 110, 0.08) 0%, transparent 70%);
  pointer-events: none;
}

.section--dark .container { position: relative; }

.section-head { margin-bottom: 48px; max-width: 640px; }

.section-head--light .section-head__title { color: #fff; }

.section-head__title {
  font-family: var(--font-serif);
  font-size: clamp(1.625rem, 2.5vw, 2rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin-bottom: 12px;
}

.section-head__desc {
  font-size: 1rem;
  color: var(--ink-muted);
  line-height: 1.7;
}

/* ========== CARDS ========== */
.card-grid { display: grid; gap: 24px; }
.card-grid--2 { grid-template-columns: repeat(2, 1fr); }
.card-grid--4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  transition: box-shadow var(--transition), border-color var(--transition), transform var(--transition);
}

.card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}

.card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius);
  background: var(--accent-subtle);
  color: var(--accent-deep);
  margin-bottom: 20px;
}

.card__icon--muted {
  background: var(--bg-subtle);
  color: var(--ink-muted);
}

.card--accent { border-top: 3px solid var(--accent-deep); }

.card--accent .card__icon {
  background: rgba(12, 74, 110, 0.08);
  color: var(--accent-deep);
}

.card--flat {
  padding: 24px;
  background: var(--bg);
}

.card__title {
  font-family: var(--font-serif);
  font-size: 1.0625rem;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 12px;
}

.card__fee {
  font-family: var(--font-serif);
  font-size: 1.75rem;
  font-weight: 500;
  color: var(--accent-deep);
  margin-bottom: 16px;
}

.card__body {
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.65;
  margin-bottom: 8px;
}

.card__note {
  font-size: 13px;
  color: var(--ink-muted);
  margin-top: 12px;
}

.card__list {
  list-style: none;
  margin-top: 16px;
  border-top: 1px solid var(--border);
  padding-top: 12px;
}

.card__list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: var(--ink-soft);
  padding: 8px 0;
  position: relative;
}

.card__list li .icon {
  color: var(--accent);
  margin-top: 2px;
}

.card__list li::before { display: none; }

@media (max-width: 900px) {
  .card-grid--2, .card-grid--4 { grid-template-columns: 1fr; }
}

@media (min-width: 601px) and (max-width: 900px) {
  .card-grid--4 { grid-template-columns: repeat(2, 1fr); }
}

/* ========== OUTLINE TABLE ========== */
.curriculum-phase {
  margin-bottom: 40px;
}

.curriculum-phase:last-child {
  margin-bottom: 0;
}

.curriculum-phase__head {
  margin-bottom: 20px;
  max-width: 720px;
}

.curriculum-phase__badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-deep);
  background: var(--accent-light);
  border: 1px solid rgba(15, 118, 110, 0.2);
  padding: 4px 10px;
  border-radius: 100px;
  margin-bottom: 12px;
}

.curriculum-phase__title {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 8px;
}

.curriculum-phase__desc {
  font-size: 14px;
  color: var(--ink-muted);
  line-height: 1.65;
}

.outline-table {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg);
  box-shadow: var(--shadow-sm);
}

.outline-row {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 32px;
  padding: 20px 28px;
  border-bottom: 1px solid var(--border);
  align-items: baseline;
  transition: background var(--transition);
}

.outline-row:last-child { border-bottom: none; }
.outline-row:hover { background: var(--bg-muted); }

.outline-row__phase {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
}

.outline-row__topics {
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.6;
}

@media (max-width: 640px) {
  .outline-row { grid-template-columns: 1fr; gap: 6px; }
}

/* ========== PROCESS STEPS ========== */
.process-steps {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  padding: 36px 28px;
  margin-bottom: 28px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  position: relative;
}

.process-steps::before {
  content: '';
  position: absolute;
  top: 56px;
  left: 14%;
  right: 14%;
  height: 1px;
  background: var(--border-strong);
  z-index: 0;
}

.process-steps__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  position: relative;
  z-index: 1;
}

.process-steps__num {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent-deep);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 3px solid var(--bg);
  box-shadow: 0 0 0 1px var(--border-strong);
}

.process-steps__label {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-soft);
  line-height: 1.45;
  max-width: 140px;
}

@media (max-width: 900px) {
  .process-steps {
    grid-template-columns: repeat(2, 1fr);
    gap: 28px 20px;
    padding: 28px 24px;
  }

  .process-steps::before {
    display: none;
  }
}

@media (max-width: 520px) {
  .process-steps {
    grid-template-columns: 1fr;
    gap: 0;
    padding: 8px 0;
  }

  .process-steps__item {
    flex-direction: row;
    align-items: center;
    text-align: left;
    gap: 16px;
    padding: 16px 24px;
    border-bottom: 1px solid var(--border);
  }

  .process-steps__item:last-child {
    border-bottom: none;
  }

  .process-steps__label {
    max-width: none;
  }

  .process-steps__num {
    border-color: var(--bg);
    box-shadow: none;
  }
}

/* ========== INFO PANEL ========== */
.info-panel {
  padding: 24px 28px;
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  background: var(--bg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.info-panel__header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.info-panel__label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-deep);
}

.info-panel p {
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.75;
}

.info-panel__meta {
  margin-top: 12px;
  font-size: 13px;
  color: var(--ink-muted);
}

.info-panel a { font-weight: 500; }

/* ========== MISSION ========== */
.mission-quote {
  max-width: 800px;
  border: none;
  padding: 0 0 0 28px;
  border-left: 2px solid rgba(15, 118, 110, 0.4);
}

.mission-quote p {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  line-height: 1.75;
  color: rgba(248, 250, 252, 0.85);
}

/* ========== FOUNDER ========== */
.founder-card {
  display: flex;
  gap: 28px;
  align-items: flex-start;
  padding: 36px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  max-width: 800px;
  box-shadow: var(--shadow-sm);
}

.founder-card__avatar {
  width: 56px;
  height: 56px;
  border-radius: var(--radius);
  background: var(--accent-deep);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.02em;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.founder-card__body p {
  font-size: 1rem;
  color: var(--ink-soft);
  line-height: 1.75;
}

.founder-card__meta {
  font-size: 13px;
  color: var(--ink-muted);
  margin-top: 16px;
}

/* ========== FAQ ========== */
.faq { border-top: 1px solid var(--border); }

.faq__item {
  padding: 24px 0;
  border-bottom: 1px solid var(--border);
  transition: background var(--transition);
}

.faq__q {
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.faq__a {
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.7;
}

/* ========== FOOTER ========== */
.site-footer {
  background: var(--bg-dark);
  color: rgba(248, 250, 252, 0.8);
  padding-top: 64px;
}

.site-footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1.5fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 48px;
}

.site-footer__brand {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.site-footer__logo {
  width: 28px;
  height: 28px;
  object-fit: contain;
  margin-bottom: 10px;
  display: block;
}

.site-footer__name {
  font-family: var(--font-serif);
  font-size: 1.0625rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 6px;
}

.site-footer__full {
  font-size: 13px;
  color: rgba(248, 250, 252, 0.5);
  margin-bottom: 12px;
  line-height: 1.4;
}

.site-footer__domain {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: rgba(248, 250, 252, 0.85);
  text-decoration: none;
  margin-bottom: 6px;
  transition: color var(--transition);
}

.site-footer__domain:hover { color: #fff; text-decoration: none; }

.site-footer__email {
  font-size: 14px;
  color: rgba(248, 250, 252, 0.75);
  text-decoration: none;
}

.site-footer__email:hover { color: #fff; text-decoration: underline; }

.site-footer__company {
  font-size: 14px;
  font-weight: 500;
  color: rgba(248, 250, 252, 0.85);
  margin-bottom: 8px;
}

.site-footer__address {
  font-size: 13px;
  color: rgba(248, 250, 252, 0.55);
  line-height: 1.5;
  margin-bottom: 12px;
}

.site-footer__contact-link {
  display: block;
  font-size: 14px;
  color: rgba(248, 250, 252, 0.75);
  text-decoration: none;
  margin-bottom: 6px;
  transition: color var(--transition);
}

.site-footer__contact-link:hover { color: #fff; text-decoration: underline; }

.site-footer__officer {
  font-size: 13px;
  color: rgba(248, 250, 252, 0.5);
  margin-top: 8px;
  margin-bottom: 0;
}

.site-footer__heading {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(248, 250, 252, 0.45);
  margin-bottom: 16px;
}

.site-footer__col a {
  display: block;
  font-size: 14px;
  color: rgba(248, 250, 252, 0.7);
  text-decoration: none;
  margin-bottom: 8px;
  transition: color var(--transition);
}

.site-footer__col a:hover { color: #fff; text-decoration: none; }

.site-footer__bar {
  border-top: 1px solid rgba(248, 250, 252, 0.1);
  padding: 20px 0;
  padding-bottom: max(20px, env(safe-area-inset-bottom));
}

.site-footer__bar p {
  font-size: 13px;
  color: rgba(248, 250, 252, 0.4);
}

@media (max-width: 768px) {
  .site-footer__grid { grid-template-columns: 1fr; }
}

/* ========== LEGAL ========== */
.legal-section { padding: 48px 32px 80px; max-width: var(--container-narrow); margin: 0 auto; }

.legal-section h1 {
  font-family: var(--font-serif);
  font-size: 1.75rem;
  font-weight: 500;
  margin-bottom: 8px;
}

.legal-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 2rem;
  color: var(--ink-muted);
  text-decoration: none;
  font-size: 14px;
  transition: color var(--transition);
}

.legal-back:hover { color: var(--ink); text-decoration: none; }
.legal-back .icon { color: currentColor; }

.legal-section .legal-updated { font-size: 13px; color: var(--ink-muted); margin-bottom: 2rem; }

.legal-section h2 { font-size: 1rem; font-weight: 600; margin: 2rem 0 0.5rem; }

.legal-section p { font-size: 14px; color: var(--ink-soft); line-height: 1.75; margin-bottom: 0.75rem; }

.legal-section ul {
  font-size: 14px;
  color: var(--ink-soft);
  line-height: 1.75;
  margin: 0 0 0.75rem 1.25rem;
  padding: 0;
}

.legal-section li { margin-bottom: 0.75rem; }

.legal-section a { font-weight: 500; overflow-wrap: anywhere; }

.apply-section a { overflow-wrap: anywhere; }

/* Apply / registration form */
.apply-section {
  padding: 48px 0 80px;
  background: var(--bg-muted);
  min-height: 60vh;
}

.apply-section__inner {
  max-width: var(--container-narrow);
}

.apply-header { margin-bottom: 2rem; }

.apply-header__title {
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 3vw, 1.875rem);
  font-weight: 500;
  margin-bottom: 0.75rem;
}

.apply-header__lead {
  font-size: 15px;
  color: var(--ink-soft);
  line-height: 1.7;
}

.apply-errors {
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  margin-bottom: 1.5rem;
  font-size: 14px;
  color: #991b1b;
}

.apply-errors__title { font-weight: 600; margin-bottom: 0.5rem; }

.apply-errors ul { padding-left: 1.25rem; }

.apply-errors li { margin-bottom: 0.25rem; }

.apply-form {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 2rem;
}

.apply-form__section {
  border: none;
  margin: 0 0 2rem;
  padding: 0 0 2rem;
  border-bottom: 1px solid var(--border);
}

.apply-form__section:last-of-type { border-bottom: none; padding-bottom: 0; }

.apply-form__legend {
  font-family: var(--font-serif);
  font-size: 1.0625rem;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 1.25rem;
  padding: 0;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem 1.25rem;
}

@media (max-width: 640px) {
  .form-row { grid-template-columns: 1fr; }
  .apply-form { padding: 1.25rem; }

  .form-input,
  .form-select,
  .form-textarea {
    font-size: 16px;
  }
}

.form-group { margin-bottom: 1rem; }

.form-row .form-group { margin-bottom: 0; }

.form-row + .form-group,
.form-row + .form-row { margin-top: 1rem; }

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-soft);
  margin-bottom: 6px;
}

.form-required { color: #b91c1c; }

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  font-family: var(--font-sans);
  font-size: 15px;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 10px 12px;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.12);
}

.form-textarea { resize: vertical; min-height: 88px; }

.form-hint {
  font-size: 12px;
  color: var(--ink-muted);
  margin-top: 6px;
  line-height: 1.5;
}

.form-hint--above {
  margin-top: 0;
  margin-bottom: 8px;
}

.form-char-count {
  display: flex;
  justify-content: flex-end;
  align-items: baseline;
  gap: 6px;
  font-size: 12px;
  color: var(--ink-muted);
  margin-top: 6px;
  font-variant-numeric: tabular-nums;
}

.form-char-count__min { color: var(--ink-faint); }

.form-char-count.is-under { color: #b45309; }

.form-char-count.is-near-max { color: #b45309; }

.form-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  color: var(--ink-soft);
  margin-bottom: 0.75rem;
  cursor: pointer;
}

.form-check input {
  margin-top: 3px;
  flex-shrink: 0;
  accent-color: var(--accent);
}

.apply-form__section--legal { margin-bottom: 1.5rem; }

.apply-form__actions {
  padding-top: 0.5rem;
}

.apply-form__fee-note { margin-top: 0.75rem; }

.apply-success__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--accent-light);
  color: var(--accent);
  margin-bottom: 1.25rem;
}

.apply-success__title {
  font-family: var(--font-serif);
  font-size: 1.75rem;
  font-weight: 500;
  margin-bottom: 0.75rem;
}

.apply-success__lead {
  font-size: 15px;
  color: var(--ink-soft);
  line-height: 1.7;
  margin-bottom: 1.5rem;
}

.apply-success__panel { margin-bottom: 1rem; }

.apply-success__meta {
  font-size: 14px;
  color: var(--ink-muted);
}

/* ========== MOBILE — global refinements ========== */
@media (max-width: 768px) {
  :root {
    --header-h: 60px;
  }

  .container {
    padding-left: max(16px, env(safe-area-inset-left));
    padding-right: max(16px, env(safe-area-inset-right));
  }

  .section { padding: 48px 0; }

  .section-head { margin-bottom: 32px; }

  .card { padding: 24px 20px; }

  .card--flat { padding: 20px; }

  .card__fee { font-size: 1.5rem; }

  .hero { padding: 40px 0 48px; }

  .hero__title { font-size: clamp(1.75rem, 6vw, 2.25rem); }

  .hero__lead { font-size: 1rem; margin-bottom: 24px; }

  .hero__panel-inner { padding: 20px; }

  .hero__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero__actions .btn {
    width: 100%;
    min-height: 48px;
    font-size: 15px;
  }

  .outline-row { padding: 16px 18px; gap: 4px; }

  .info-panel { padding: 18px 20px; }

  .founder-card {
    flex-direction: column;
    padding: 24px 20px;
    gap: 20px;
  }

  .mission-quote {
    padding-left: 18px;
    margin-left: 0;
  }

  .mission-quote p { font-size: 1.0625rem; }

  .faq__item { padding: 20px 0; }

  .faq__q { font-size: 14px; }

  .site-footer { padding-top: 48px; }

  .site-footer__grid { gap: 28px; padding-bottom: 36px; }

  .legal-section {
    padding: 32px 16px 56px;
    padding-left: max(16px, env(safe-area-inset-left));
    padding-right: max(16px, env(safe-area-inset-right));
  }

  .legal-section h1 { font-size: 1.5rem; }

  .apply-section {
    padding: 32px 0 56px;
  }

  .apply-header__lead { font-size: 14px; }

  .apply-form__actions .btn {
    width: 100%;
    min-height: 48px;
    font-size: 15px;
  }

  .apply-success__title { font-size: 1.5rem; }

  .btn {
    min-height: 44px;
  }
}

@media (max-width: 480px) {
  .site-header__brand {
    gap: 8px;
    max-width: calc(100% - 56px);
  }

  .site-header__logo {
    height: 40px;
    max-width: 185px;
  }

  .site-header__fullform-line { font-size: 9px; }

  .site-header__fullform-line--accent {
    font-size: 8px;
    letter-spacing: 0.08em;
  }

  .site-header__expansion-rule { max-width: 140px; }

  .section { padding: 40px 0; }

  .card-grid { gap: 16px; }

  .process-steps__item { padding: 14px 18px; }

  .form-input,
  .form-select,
  .form-textarea {
    font-size: 16px;
    padding: 12px 14px;
  }

  .form-char-count {
    flex-wrap: wrap;
    justify-content: flex-start;
  }
}

@media (max-width: 360px) {
  .site-header__expansion { display: none; }

  .site-header__logo {
    height: 36px;
    max-width: 165px;
  }
}
