:root {
  --bg-rgb: 5, 5, 5;
  --ink-rgb: 242, 242, 242;
  --acc-rgb: 255, 77, 31;
  --green-rgb: 120, 196, 156;
  --blue-rgb: 201, 201, 201;
  --amber-rgb: 255, 77, 31;
  --purple-rgb: 168, 168, 168;
  --crimson-rgb: 222, 222, 222;
  --bg: #050505;
  --bg-2: #0b0b0b;
  --surface: #08090b;
  --surface-hover: #0e1015;
  --panel: #0c0d11;
  --ink: #f2f2f2;
  --ink-2: rgba(var(--ink-rgb), 0.85);
  --dim: rgba(var(--ink-rgb), 0.64);
  --faint: rgba(var(--ink-rgb), 0.13);
  --hair: rgba(var(--ink-rgb), 0.07);
  --accent: #ff4d1f;
  --accent-dim: rgba(var(--acc-rgb), 0.22);
  --on-accent: #050505;
  --blue: #c9c9c9;
  --green: #78c49c;
  --amber: #ff4d1f;
  --purple: #a8a8a8;
  --crimson: #dedede;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --dot: "Doto", "IBM Plex Mono", monospace;
  --gutter: clamp(16px, 3.8vw, 48px);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  color-scheme: dark;
}

:root[data-theme="light"] {
  --bg-rgb: 244, 244, 243;
  --ink-rgb: 20, 22, 26;
  --acc-rgb: 220, 62, 14;
  --green-rgb: 46, 122, 88;
  --blue-rgb: 60, 63, 69;
  --amber-rgb: 220, 62, 14;
  --purple-rgb: 90, 93, 99;
  --crimson-rgb: 42, 44, 48;
  --bg: #f4f4f3;
  --bg-2: #ececeb;
  --surface: #f0f0ef;
  --surface-hover: #e6e6e5;
  --panel: #ebebea;
  --ink: #14161a;
  --ink-2: rgba(var(--ink-rgb), 0.84);
  --dim: rgba(var(--ink-rgb), 0.64);
  --faint: rgba(var(--ink-rgb), 0.2);
  --hair: rgba(var(--ink-rgb), 0.085);
  --accent: #dc3e0e;
  --accent-dim: rgba(var(--acc-rgb), 0.2);
  --on-accent: #ffffff;
  --blue: #3c3f45;
  --green: #2e7a58;
  --amber: #dc3e0e;
  --purple: #5a5d63;
  --crimson: #2a2c30;
  color-scheme: light;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--sans);
  font-weight: 300;
  background-color: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  background-image:
    linear-gradient(to right, rgba(var(--ink-rgb), 0.016) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(var(--ink-rgb), 0.016) 1px, transparent 1px);
  background-size: 64px 64px;
}

.mono { font-family: var(--mono); }
.dim-text { color: var(--dim); font-size: 11px; letter-spacing: 0.08em; }
.accent-text { color: var(--accent); }
.green-text { color: var(--green); }
.blue-text { color: var(--blue); }
.amber-text { color: var(--amber); }

/* Mouse ambient glow (GPU-composited layer) */
.fx-glow {
  position: fixed;
  left: 0;
  top: 0;
  width: 560px;
  height: 560px;
  margin: -280px 0 0 -280px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  opacity: 0;
  will-change: transform;
  contain: strict;
  transition: opacity 0.5s ease;
  background: radial-gradient(circle, rgba(var(--acc-rgb), 0.08), transparent 62%);
}

.fx-glow.on { opacity: 1; }

@media (pointer: coarse) {
  .fx-glow { display: none !important; }
}

/* ============================================================================
   TOPBAR
   ============================================================================ */
.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 11px var(--gutter);
  background: rgba(var(--bg-rgb), 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--faint);
}

.topbar-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  background: rgba(var(--ink-rgb), 0.06);
  pointer-events: none;
  overflow: hidden;
}

.topbar-progress-bar {
  height: 100%;
  width: 100%;
  transform-origin: left center;
  transform: scaleX(0.08);
  will-change: transform;
  background: linear-gradient(90deg, rgba(var(--acc-rgb), 0.35), var(--accent));
}

.brand {
  text-decoration: none;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  line-height: 1.1;
  flex: none;
}

.brand-mark {
  font-family: var(--dot);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: 0.04em;
}

.brand-sub {
  font-family: var(--mono);
  font-size: 9px;
  color: var(--dim);
  letter-spacing: 0.14em;
  margin-top: 3px;
}

.tabs {
  display: flex;
  gap: 2px;
  overflow-x: auto;
  scrollbar-width: none;
  margin-inline-start: auto;
  padding: 2px 0;
}

.tabs::-webkit-scrollbar { display: none; }

.tab {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--dim);
  padding: 7px 11px;
  border: 1px solid transparent;
  white-space: nowrap;
  display: flex;
  gap: 6px;
  align-items: center;
  transition: all 0.2s ease;
}

.tab .n { font-size: 9.5px; color: var(--dim); }

.tab:hover {
  color: var(--ink);
  background: rgba(var(--ink-rgb), 0.04);
}

.tab[aria-current="page"] {
  color: var(--ink);
  background: rgba(var(--acc-rgb), 0.07);
  border-color: rgba(var(--ink-rgb), 0.18);
}

.tab[aria-current="page"] .n {
  color: var(--accent);
  font-weight: 500;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: none;
}

.bio-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 10.5px;
  letter-spacing: 0.08em;
  padding: 6px 10px;
  border: 1px solid rgba(var(--green-rgb), 0.45);
  background: rgba(var(--green-rgb), 0.08);
  color: var(--green);
  white-space: nowrap;
  transition: color 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}

.bio-pill.warn {
  border-color: rgba(var(--amber-rgb), 0.45);
  background: rgba(var(--amber-rgb), 0.08);
  color: var(--amber);
}

.bio-pill.warn .pulse-dot {
  background: var(--amber);
  box-shadow: 0 0 8px var(--amber);
}

.bio-pill.older {
  border-color: rgba(var(--acc-rgb), 0.5);
  background: rgba(var(--acc-rgb), 0.1);
  color: var(--accent);
}

.bio-pill.older .pulse-dot {
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent);
}

.pulse-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
  animation: pulseGlow 2s infinite;
}

@keyframes pulseGlow {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(0.85); }
}

/* ============================================================================
   PAGE CONTAINER & TYPOGRAPHY
   ============================================================================ */
.page {
  max-width: 1380px;
  margin: 0 auto;
  padding: 44px var(--gutter) 96px;
  position: relative;
  z-index: 1;
}

.kicker {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  color: var(--dim);
  text-transform: uppercase;
  display: flex;
  gap: 12px;
  align-items: center;
}

.kicker::before {
  content: "";
  width: 24px;
  height: 1px;
  background: var(--accent);
}

h1 {
  font-weight: 200;
  font-size: clamp(38px, 5.2vw, 72px);
  line-height: 0.98;
  letter-spacing: -0.035em;
  margin: 14px 0 0;
}

h2 {
  font-weight: 300;
  font-size: clamp(25px, 2.8vw, 36px);
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 10px 0 12px;
}

h3 {
  font-weight: 400;
  font-size: 18.5px;
  letter-spacing: -0.01em;
  margin: 0 0 6px;
}

p {
  margin: 0 0 12px;
  color: var(--ink-2);
}

.lead {
  font-size: 16px;
  color: var(--ink-2);
  max-width: 60ch;
  margin-top: 16px;
}

.mt-xs { margin-top: 10px; }
.mt-s { margin-top: 16px; }
.mt-m { margin-top: 26px; }
.mb-m { margin-bottom: 24px; }

/* CAD FRAME WITH SUBTLE + CORNER CROSSHAIRS */
.frame {
  position: relative;
  border: 1px solid var(--faint);
  background: rgba(var(--bg-rgb), 0.84);
}

.frame::before,
.frame::after {
  content: "+";
  position: absolute;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--dim);
  opacity: 0.45;
  line-height: 1;
  pointer-events: none;
  z-index: 4;
}

.frame::before { top: -6px; left: -4px; }
.frame::after { bottom: -6px; right: -4px; }

/* CLEAN 3-PILLAR INFORMATION ARCHITECTURE (IA) DIRECTORY */
.ia-architecture {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  background: var(--surface);
}

.ia-pillar {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 20px 24px;
  text-decoration: none;
  color: var(--ink);
  border-inline-end: 1px solid var(--faint);
  transition: background-color 0.2s ease;
}

.ia-pillar:last-child {
  border-inline-end: none;
}

.ia-pillar:hover {
  background: var(--surface-hover);
}

.ia-pillar-num {
  font-size: 10px;
  letter-spacing: 0.14em;
}

.ia-pillar strong {
  font-size: 16.5px;
  font-weight: 400;
  letter-spacing: -0.01em;
}

.ia-pillar span:last-child {
  font-size: 12.5px;
  color: var(--dim);
}

@media (max-width: 860px) {
  .ia-architecture {
    grid-template-columns: minmax(0, 1fr);
  }
  .ia-pillar {
    border-inline-end: none;
    border-bottom: 1px solid var(--faint);
  }
  .ia-pillar:last-child {
    border-bottom: none;
  }
}

/* ============================================================================
   HERO & OPTIONAL BIOMETRIC TELEMETRY PANEL
   ============================================================================ */
.hero {
  display: grid;
  grid-template-columns: minmax(0, 5.8fr) minmax(0, 6.2fr);
  gap: 28px;
  align-items: start;
  margin-bottom: 52px;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.hero-right-col {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.control-panel {
  padding: 20px;
  background: linear-gradient(180deg, rgba(var(--ink-rgb), 0.025), rgba(var(--ink-rgb), 0.005));
}

.control-row {
  display: grid;
  grid-template-columns: 1fr 1.25fr;
  gap: 18px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--faint);
}

.ctrl-label {
  display: block;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--dim);
  text-transform: uppercase;
  margin-bottom: 8px;
}

.ctrl-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.ctrl-head .ctrl-label { margin-bottom: 0; }

.age-readout {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 1px solid var(--accent);
  background: rgba(var(--acc-rgb), 0.09);
  padding: 2px 8px;
  font-size: 11px;
  color: var(--accent);
}

#age-input {
  width: 42px;
  background: transparent;
  border: none;
  color: var(--ink);
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 500;
  text-align: center;
  outline: none;
}

.slider-box {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 10.5px;
  color: var(--dim);
  background: rgba(var(--bg-rgb), 0.85);
  padding: 6px 10px;
  border: 1px solid var(--faint);
}

input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 2px;
  background: var(--faint);
  outline: none;
  cursor: pointer;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg);
  box-shadow: 0 0 0 1px var(--accent), 0 0 10px rgba(var(--acc-rgb), 0.6);
  cursor: pointer;
  transition: transform 0.15s ease;
}

input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.2);
}

/* Optional Wearable Telemetry Block */
.optional-telemetry {
  padding: 16px 0;
  border-bottom: 1px solid var(--faint);
}

.opt-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.opt-title-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
}

.opt-sub {
  font-size: 12px;
  color: var(--dim);
  margin: 2px 0 0;
}

.opt-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.opt-item {
  border: 1px solid var(--faint);
  background: rgba(var(--bg-rgb), 0.65);
  padding: 10px 12px;
}

.opt-item-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 10.5px;
  letter-spacing: 0.08em;
  margin-bottom: 6px;
}

.opt-scale {
  display: flex;
  justify-content: space-between;
  font-size: 9.5px;
  color: var(--dim);
  margin-top: 5px;
}

.control-footer {
  padding-top: 14px;
}

/* ============================================================================
   BIOLOGICAL AGE ENGINE CARD
   ============================================================================ */
.bio-age-card {
  padding: 22px 24px;
  background:
    radial-gradient(circle at 90% 10%, rgba(var(--green-rgb), 0.08), transparent 55%),
    linear-gradient(180deg, rgba(var(--ink-rgb), 0.03), rgba(var(--ink-rgb), 0.005));
}

.bio-age-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--faint);
}

.bio-age-title-group {
  display: flex;
  align-items: center;
  gap: 14px;
}

.bio-age-Title-group h3 {
  margin: 2px 0 0;
}

.bio-age-numbers {
  display: grid;
  grid-template-columns: 1fr auto 1fr 1fr;
  align-items: center;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--faint);
}

.bio-num-block {
  display: flex;
  flex-direction: column;
}

.bio-big-val {
  font-weight: 200;
  font-size: clamp(36px, 4vw, 54px);
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--green);
  margin-top: 4px;
}

.bio-big-val.warn { color: var(--amber); }
.bio-big-val.older { color: var(--accent); }

.bio-big-val.dim {
  color: var(--ink-2);
}

.bio-big-val small,
.bio-pace-val small {
  font-size: 0.36em;
  letter-spacing: 0.05em;
  color: var(--dim);
  margin-left: 4px;
}

.bio-vs-divider {
  font-size: 11px;
  color: var(--dim);
  padding: 4px 8px;
  border: 1px solid var(--faint);
}

.pace-block {
  border-left: 1px solid var(--faint);
  padding-left: 16px;
}

.bio-pace-val {
  font-weight: 200;
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1;
  color: var(--ink);
  margin-top: 4px;
}

/* Bio Spectrum Bar */
.bio-spectrum {
  padding: 14px 0;
  border-bottom: 1px solid var(--faint);
}

.bio-spectrum-labels {
  display: flex;
  justify-content: space-between;
  font-size: 9.5px;
  color: var(--dim);
  letter-spacing: 0.08em;
  margin-bottom: 6px;
}

.bio-spectrum-track {
  position: relative;
  height: 8px;
  background: linear-gradient(90deg, rgba(var(--green-rgb), 0.35) 0%, rgba(var(--ink-rgb), 0.1) 50%, rgba(var(--acc-rgb), 0.4) 100%);
  border: 1px solid var(--faint);
}

.bio-spectrum-center {
  position: absolute;
  left: 50%;
  top: -3px;
  bottom: -3px;
  width: 2px;
  background: var(--ink);
}

.bio-spectrum-marker {
  position: absolute;
  top: -5px;
  width: 10px;
  height: 16px;
  background: var(--green);
  border: 2px solid var(--bg);
  box-shadow: 0 0 10px var(--green);
  transform: translateX(-50%);
  transition: left 0.35s var(--ease-out), background-color 0.35s ease;
}

/* 4 Bio Drivers Breakdown */
.bio-drivers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  padding-top: 14px;
}

.bio-driver-item {
  font-size: 11.5px;
  padding: 8px 10px;
  border: 1px solid var(--hair);
  background: rgba(var(--bg-rgb), 0.5);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.bio-driver-item .drv-name {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--dim);
}

.bio-driver-item .drv-impact {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 500;
}

/* CHIPS & TAGS */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.chip {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: transparent;
  color: var(--dim);
  border: 1px solid var(--faint);
  padding: 7px 11px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.chip:hover {
  color: var(--ink);
  border-color: var(--dim);
}

.chip[aria-pressed="true"],
.chip.on {
  color: var(--bg);
  background: var(--ink);
  border-color: var(--ink);
}

.chip.accent[aria-pressed="true"],
.chip.accent.on {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--on-accent);
  font-weight: 500;
}

.tag {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: 1px solid var(--faint);
  padding: 3px 8px;
  color: var(--dim);
  display: inline-block;
}

.tag.red {
  color: var(--accent);
  border-color: var(--accent-dim);
  background: rgba(var(--acc-rgb), 0.08);
}

.tag.green {
  color: var(--green);
  border-color: rgba(var(--green-rgb), 0.35);
  background: rgba(var(--green-rgb), 0.08);
}

/* ============================================================================
   HAIRLINE GRIDS & STAT CELLS
   ============================================================================ */
.grid {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--faint);
  border-inline-start: 1px solid var(--faint);
}

.grid > * {
  background: var(--bg);
  border-inline-end: 1px solid var(--faint);
  border-bottom: 1px solid var(--faint);
}

.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }

.cell {
  padding: 22px;
  position: relative;
  transition: background-color 0.2s ease;
}

.cell:hover {
  background: var(--surface-hover);
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stat .stat-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.stat .stat-code {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--accent);
  letter-spacing: 0.1em;
}

.stat .v {
  font-weight: 200;
  font-size: clamp(30px, 3.2vw, 44px);
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--ink);
}

.stat .v small {
  font-size: 0.42em;
  letter-spacing: 0;
  color: var(--dim);
  margin-inline-start: 4px;
}

.stat .k {
  font-size: 12.5px;
  color: var(--dim);
  border-top: 1px solid var(--faint);
  padding-top: 8px;
  margin-top: 8px;
}

/* ============================================================================
   HERO CAD STAGE
   ============================================================================ */
.hero-stage {
  position: relative;
  min-height: 440px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 45%, rgba(var(--acc-rgb), 0.06), transparent 65%),
    var(--surface);
}

.scan {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(var(--acc-rgb), 0.6), transparent);
  animation: scanline 5.5s linear infinite;
  pointer-events: none;
  z-index: 2;
}

@keyframes scanline {
  0% { top: 6%; opacity: 0; }
  15% { opacity: 1; }
  85% { opacity: 1; }
  100% { top: 92%; opacity: 0; }
}

.pulse-node {
  animation: nodePulse 2.4s ease-in-out infinite;
}

@keyframes nodePulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.hud-ring {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hud-ring svg { width: 100%; height: 100%; }

.hero-mode {
  position: absolute;
  top: 12px;
  left: 14px;
  z-index: 3;
}

.hero-coords {
  position: absolute;
  top: 12px;
  right: 14px;
  text-align: right;
  font-size: 10px;
  color: var(--dim);
  letter-spacing: 0.1em;
  line-height: 1.5;
  z-index: 3;
}

.cad-canvas {
  width: 100%;
  padding: 40px 14px 38px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cad-svg {
  max-height: 390px;
  width: 100%;
}

.hero-spec {
  position: absolute;
  left: 14px;
  bottom: 12px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--dim);
  letter-spacing: 0.08em;
  line-height: 1.6;
  pointer-events: none;
}

.hero-spec b { color: var(--ink); font-weight: 400; }

/* SVG LINEART CLASSES */
svg.lineart {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}

svg.lineart text {
  font-family: var(--mono);
  fill: var(--dim);
  font-size: 10px;
  letter-spacing: 0.06em;
}

svg.lineart text.ink { fill: var(--ink); font-weight: 500; }
svg.lineart .ln { fill: none; stroke: var(--ink); stroke-width: 1; vector-effect: non-scaling-stroke; }
svg.lineart .ln2 { fill: none; stroke: var(--dim); stroke-width: 1; vector-effect: non-scaling-stroke; }
svg.lineart .ln3 { fill: none; stroke: var(--faint); stroke-width: 1; vector-effect: non-scaling-stroke; }
svg.lineart .dash { fill: none; stroke: var(--dim); stroke-width: 1; stroke-dasharray: 3 4; vector-effect: non-scaling-stroke; }
svg.lineart .acc { fill: none; stroke: var(--accent); stroke-width: 1.4; vector-effect: non-scaling-stroke; }
svg.lineart .accf { fill: var(--accent); stroke: none; }
svg.lineart .s-bold { fill: none; stroke: var(--ink); stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; transition: d 0.35s ease; }
svg.lineart .s-med { fill: none; stroke: var(--ink-2); stroke-width: 1; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
svg.lineart .s-dim { fill: none; stroke: var(--dim); stroke-width: 0.9; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
svg.lineart .s-faint { fill: none; stroke: var(--faint); stroke-width: 0.75; vector-effect: non-scaling-stroke; }

/* MARQUEE */
.marquee {
  overflow: hidden;
  border-top: 1px solid var(--faint);
  border-bottom: 1px solid var(--faint);
  padding: 15px 0;
  margin-bottom: 20px;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.marquee .row {
  display: flex;
  gap: 44px;
  width: max-content;
  will-change: transform;
  animation: marq 55s linear infinite;
}

.marquee .row > span {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--dim);
  letter-spacing: 0.1em;
  white-space: nowrap;
}

@keyframes marq { to { transform: translateX(-50%); } }

/* ============================================================================
   NUMBERED SECTIONS (.sec)
   ============================================================================ */
.sec {
  display: grid;
  grid-template-columns: 68px minmax(0, 1fr);
  gap: 0 28px;
  padding: 56px 0;
  border-top: 1px solid var(--faint);
  position: relative;
  content-visibility: auto;
  contain-intrinsic-size: auto 720px;
}

.sec > .sec-n {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--dim);
  position: relative;
  padding-inline-start: 14px;
}

.sec > .sec-n::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  bottom: 0;
  width: 8px;
  border: 1px solid var(--faint);
  border-inline-end: none;
}

.sec-title {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 32px;
  align-items: end;
  margin-bottom: 28px;
}

.sec-title p { margin: 0; }

/* ============================================================================
   SECTION 02: INTERACTIVE LONGEVITY GRAPHS
   ============================================================================ */
.chart-frame {
  padding: 22px;
  background: var(--surface);
}

.chart-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--faint);
  margin-bottom: 18px;
}

.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--ink-2);
  letter-spacing: 0.06em;
}

.legend span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.legend i {
  width: 12px;
  height: 3px;
  display: inline-block;
}

.chart-stage {
  position: relative;
  min-height: 340px;
}

.chart-footer-readout {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--faint);
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.chart-Readout-box {
  padding: 12px 14px;
  border: 1px solid var(--faint);
  background: rgba(var(--bg-rgb), 0.65);
}

.chart-Readout-box .mono-lbl {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--dim);
  letter-spacing: 0.08em;
  display: block;
}

.chart-Readout-box .mono-val {
  font-family: var(--mono);
  font-size: 18px;
  color: var(--ink);
  font-weight: 500;
  margin-top: 4px;
  display: block;
}

/* ============================================================================
   SECTION 03: FASTING & AUTOPHAGY SIMULATOR
   ============================================================================ */
.fasting-sim {
  padding: 24px;
  background: var(--surface);
}

.fasting-controls {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--faint);
}

.fasting-split {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: 24px;
  padding-top: 22px;
  align-items: center;
}

.fasting-cell-box {
  border: 1px solid var(--faint);
  background: rgba(var(--bg-rgb), 0.7);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.cell-diagram-wrap {
  border-bottom: 1px solid var(--faint);
  padding-bottom: 12px;
}

/* Explanation Cards with iOS Icons */
.exp-card {
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
}

.exp-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
}

.exp-card h3 {
  font-size: 19px;
  font-weight: 400;
  margin: 6px 0 6px;
}

.exp-card p {
  font-size: 13.5px;
  color: var(--ink-2);
  margin: 0;
}

.exp-meta {
  border-top: 1px solid var(--faint);
  padding-top: 10px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--accent);
  letter-spacing: 0.06em;
}

/* ============================================================================
   SECTION 04: PROTEIN & mTOR DASHBOARD
   ============================================================================ */
.protein-dashboard {
  background: var(--surface);
}

.protein-wave-split {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
  gap: 24px;
  padding: 24px;
  align-items: center;
}

.protein-sources-panel {
  border: 1px solid var(--faint);
  background: rgba(var(--bg-rgb), 0.75);
  padding: 20px;
}

/* ============================================================================
   SECTION 05: KARVONEN HR ZONES & HEAVY LIFTING BENCHMARKS
   ============================================================================ */
.hr-zones-frame,
.lifting-frame {
  background: var(--surface);
}

.hr-zones-head {
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.zone-cell {
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 10px;
}

.zone-bpm {
  font-weight: 200;
  font-size: clamp(24px, 2.5vw, 34px);
  letter-spacing: -0.03em;
  color: var(--ink);
  line-height: 1.1;
}

/* ============================================================================
   SECTION 06: ORGAN SYSTEMS & PROTOCOLS
   ============================================================================ */
.note {
  border: 1px solid var(--faint);
  border-inline-start: 2px solid var(--accent);
  padding: 15px 18px;
  font-size: 14px;
  color: var(--ink-2);
  background: rgba(var(--acc-rgb), 0.04);
}

.note b {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--accent);
  font-weight: 500;
  margin-right: 8px;
}

.sys-explorer {
  display: grid;
  grid-template-columns: 320px minmax(0, 1fr);
}

.sys-tabs {
  border-inline-end: 1px solid var(--faint);
  display: flex;
  flex-direction: column;
}

.sys-tab-btn {
  display: grid;
  grid-template-columns: 34px 1fr auto;
  gap: 8px;
  align-items: center;
  width: 100%;
  text-align: left;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--faint);
  color: var(--ink-2);
  padding: 16px 18px;
  cursor: pointer;
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 300;
  transition: background 0.18s ease, color 0.18s ease;
}

.sys-tab-btn:last-child { border-bottom: none; }
.sys-tab-btn .n { font-family: var(--mono); font-size: 10.5px; color: var(--dim); }
.sys-tab-btn .sys-tag { font-family: var(--mono); font-size: 9.5px; color: var(--dim); text-transform: uppercase; letter-spacing: 0.08em; }
.sys-tab-btn:hover { background: var(--surface-hover); color: var(--ink); }

.sys-tab-btn.active {
  background: rgba(var(--acc-rgb), 0.08);
  color: var(--ink);
  border-inline-start: 2px solid var(--accent);
}

.sys-tab-btn.active .n,
.sys-tab-btn.active .sys-tag { color: var(--accent); }

.sys-detail {
  padding: 26px 30px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
}

.sys-detail-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  border-bottom: 1px solid var(--faint);
  padding-bottom: 16px;
}

.sys-detail-head .pn {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--accent);
  letter-spacing: 0.12em;
  display: block;
  margin-bottom: 6px;
}

.sys-detail-head h3 { font-size: 23px; font-weight: 300; margin: 0; }

.sys-why {
  font-size: 13.5px;
  color: var(--ink);
  border-top: 1px solid var(--faint);
  padding-top: 14px;
}

.sys-why::before {
  content: "CLINICAL ACTION PROTOCOL — ";
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--accent);
  letter-spacing: 0.1em;
}

.protocol-card {
  padding: 26px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.protocol-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.protocol-top .n {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--accent);
  letter-spacing: 0.1em;
}

.protocol-sub {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--dim);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 16px;
  display: block;
}

.arrow-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.arrow-list li {
  font-size: 13.8px;
  color: var(--ink-2);
  padding-left: 20px;
  position: relative;
}

.arrow-list li::before {
  content: "→";
  position: absolute;
  left: 0;
  top: 0;
  font-family: var(--mono);
  color: var(--accent);
}

.arrow-list li strong { color: var(--ink); font-weight: 500; }

/* ============================================================================
   TABLE & CHECKLIST
   ============================================================================ */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--faint);
  background: var(--bg);
}

table.t {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
}

table.t th {
  font-family: var(--mono);
  font-weight: 400;
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--dim);
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid var(--faint);
  background: rgba(var(--ink-rgb), 0.02);
}

table.t td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--hair);
  vertical-align: top;
  color: var(--ink-2);
}

table.t tr:last-child td { border-bottom: none; }
table.t td:first-child { font-family: var(--mono); font-size: 11px; color: var(--accent); white-space: nowrap; }
table.t td:nth-child(2) { color: var(--ink); font-weight: 400; }
table.t td:nth-child(3) { font-family: var(--mono); font-size: 12px; color: var(--green); white-space: nowrap; }
table.t td:nth-child(4) { font-family: var(--mono); font-size: 11.5px; color: var(--dim); white-space: nowrap; }

.checklist-bar {
  padding: 14px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.checklist-meta { display: flex; align-items: center; gap: 14px; }

.check-cell {
  padding: 20px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  user-select: none;
}

.check-cell.done { background: rgba(var(--green-rgb), 0.06); }
.check-cell-top { display: flex; justify-content: space-between; align-items: center; }
.check-code { font-family: var(--mono); font-size: 10.5px; color: var(--dim); letter-spacing: 0.1em; }
.check-box-indicator { font-family: var(--mono); font-size: 11px; padding: 2px 8px; border: 1px solid var(--faint); color: var(--dim); }
.check-cell.done .check-box-indicator { border-color: var(--green); color: var(--green); background: rgba(var(--green-rgb), 0.12); }
.check-cell h3 { font-size: 16.5px; font-weight: 400; margin: 0 0 4px; }
.check-cell p { font-family: var(--mono); font-size: 11.5px; color: var(--dim); margin: 0; }

/* FOOTER */
.foot {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 24px var(--gutter);
  border-top: 1px solid var(--faint);
  font-size: 12px;
  color: var(--dim);
}

.foot-credit {
  flex: 1 0 100%;
  margin: 8px 0 0;
  padding-top: 14px;
  border-top: 1px solid var(--hair);
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  color: var(--dim);
}

.foot-credit::before { content: "● "; color: var(--accent); }

/* RESPONSIVE */
@media (max-width: 1120px) {
  .hero,
  .fasting-split,
  .protein-wave-split {
    grid-template-columns: minmax(0, 1fr);
  }
  .g5 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .chart-footer-readout { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sys-explorer { grid-template-columns: minmax(0, 1fr); }
  .sys-tabs {
    border-inline-end: none;
    border-bottom: 1px solid var(--faint);
    flex-direction: row;
    overflow-x: auto;
  }
  .sys-tab-btn {
    border-bottom: none;
    border-inline-end: 1px solid var(--faint);
    min-width: 195px;
  }
}

@media (max-width: 780px) {
  .sec { grid-template-columns: minmax(0, 1fr); padding: 36px 0; }
  .sec > .sec-n { margin-bottom: 12px; }
  .sec-title,
  .control-row,
  .opt-grid,
  .bio-age-numbers,
  .bio-drivers,
  .g2, .g3, .g4, .g5 {
    grid-template-columns: minmax(0, 1fr);
  }
  .bio-pill { display: none; }
}

@media print {
  .topbar, .marquee, .fx-glow, .hero-mode { display: none !important; }
  body { background: #fff; color: #000; }
}


/* ============================================================================
   TRUE APPLE iOS SUPERELLIPSE SQUIRCLE SVG ICONS (.ios)
   ============================================================================ */
.ios {
  display: inline-block;
  width: var(--s, 44px);
  height: var(--s, 44px);
  flex: none;
  vertical-align: middle;
  contain: layout style;
  transition: transform 0.25s var(--ease-out);
}

.ios svg {
  display: block;
  width: 100%;
  height: 100%;
}

.ios-tile {
  stroke: rgba(255, 255, 255, 0.22);
  stroke-width: 1;
}

.ios-shine {
  fill: rgba(255, 255, 255, 0.18);
  pointer-events: none;
}

.ios-glyph {
  fill: none;
  stroke: #ffffff;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cell:hover .ios,
.topic-card:hover .ios {
  transform: translateY(-2px) scale(1.05);
}

/* ============================================================================
   SECTION 02: AI-WORLD-2050 STYLE ACTION PLAYBOOK MATRIX
   ============================================================================ */
.advice-col {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.advice-col-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--faint);
}

.advice-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.advice-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 13.8px;
  color: var(--ink-2);
  line-height: 1.5;
}

.advice-list li strong {
  color: var(--ink);
  font-weight: 500;
}

.week-step-box {
  margin-top: auto;
  border: 1px solid rgba(var(--acc-rgb), 0.45);
  background: rgba(var(--acc-rgb), 0.06);
  padding: 14px 16px;
}

.week-step-box .ctrl-label {
  color: var(--accent);
  margin-bottom: 4px;
}

.week-step-box p {
  margin: 0;
  font-size: 13.5px;
  color: var(--ink);
}

/* ============================================================================
   SECTION 07: ESSENTIAL-LAWS STYLE 12 TOPIC CARDS (.topic-dir & .topic-card)
   ============================================================================ */
.topic-dir {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.topic-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 22px 22px 20px;
  background: var(--surface);
  border: 1px solid var(--faint);
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: background-color 0.25s ease, transform 0.25s var(--ease-out), border-color 0.25s ease;
}

.topic-card:hover {
  background: var(--surface-hover);
  transform: translateY(-3px);
  border-color: rgba(var(--acc-rgb), 0.55);
}

.tc-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.tc-top .tx {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--accent);
  letter-spacing: 0.12em;
}

.topic-card h3 {
  font-size: 20px;
  font-weight: 400;
  margin: 0 0 6px;
}

.tc-tag {
  font-size: 13px;
  color: var(--dim);
  margin: 0 0 16px;
  line-height: 1.45;
}

.tc-ch {
  list-style: none;
  padding: 0;
  margin: 0 0 18px;
  border-top: 1px solid var(--hair);
  padding-top: 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.tc-ch li {
  font-size: 12.5px;
  color: var(--ink-2);
  display: flex;
  align-items: center;
  gap: 8px;
}

.tc-ch li b {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--accent);
  width: 18px;
  height: 18px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(var(--acc-rgb), 0.35);
  background: rgba(var(--acc-rgb), 0.06);
  flex: none;
}

.tc-foot {
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--faint);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  color: var(--dim);
}

.tc-foot .acc {
  color: var(--accent);
  transition: transform 0.2s ease;
}

.topic-card:hover .tc-foot .acc {
  transform: translateX(4px);
}

/* ============================================================================
   SECTION 08: SCIENCE OR MYTH INTERACTIVE CARDS
   ============================================================================ */
.quiz-toolbar-frame {
  padding: 14px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.myth-card {
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  cursor: pointer;
}

.myth-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.verdict-pill {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  padding: 3px 9px;
  border: 1px solid var(--faint);
  font-weight: 500;
}

.verdict-pill.SCIENCE {
  color: var(--green);
  border-color: rgba(var(--green-rgb), 0.45);
  background: rgba(var(--green-rgb), 0.09);
}

.verdict-pill.MYTH {
  color: var(--crimson);
  border-color: rgba(var(--crimson-rgb), 0.45);
  background: rgba(var(--crimson-rgb), 0.09);
}

.verdict-pill.NUANCED {
  color: var(--amber);
  border-color: rgba(var(--amber-rgb), 0.45);
  background: rgba(var(--amber-rgb), 0.09);
}

.myth-card h3 {
  font-size: 17px;
  font-weight: 400;
  line-height: 1.35;
  margin: 4px 0;
}

.myth-cite {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--dim);
  border-top: 1px solid var(--hair);
  padding-top: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

/* ============================================================================
   MODALS (DEEP-DIVE DOSSIER & INSTANT SEARCH)
   ============================================================================ */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.modal-backdrop[hidden] {
  display: none !important;
}

.modal-panel {
  width: 100%;
  max-width: 920px;
  max-height: 86vh;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.75);
}

.modal-head {
  padding: 20px 24px;
  border-bottom: 1px solid var(--faint);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  background: var(--surface);
}

.modal-head-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.modal-body {
  padding: 24px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.chapter-block {
  border: 1px solid var(--faint);
  background: var(--surface);
  padding: 18px 20px;
}

.chapter-block-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}

.chapter-block h4 {
  font-family: var(--sans);
  font-size: 17px;
  font-weight: 400;
  color: var(--ink);
  margin: 0;
}

.chapter-cite {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--accent);
}

/* Search Modal */
.search-panel {
  max-width: 720px;
}

.search-bar-top {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--faint);
  background: var(--surface);
}

#search-input {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  outline: none;
}

.search-results {
  max-height: 65vh;
  overflow-y: auto;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.search-hit {
  padding: 12px 16px;
  border: 1px solid var(--faint);
  background: var(--surface);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
}

.search-hit:hover {
  border-color: var(--accent);
  background: var(--surface-hover);
}

@media (max-width: 1080px) {
  .topic-dir {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .topic-dir {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ============================================================================
   SEMANTIC CLINICAL FAQ ACCORDION (#longevity-faq)
   ============================================================================ */
.mb-s { margin-bottom: 14px; }

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.faq-item {
  background: var(--surface);
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.faq-item[open] {
  border-color: rgba(var(--acc-rgb), 0.45);
}

.faq-q {
  padding: 16px 20px;
  cursor: pointer;
  font-size: 15.5px;
  font-weight: 400;
  color: var(--ink);
  list-style: none;
  display: flex;
  align-items: center;
  gap: 10px;
  user-select: none;
}

.faq-q::-webkit-details-marker {
  display: none;
}

.faq-q::after {
  content: "+";
  margin-inline-start: auto;
  font-family: var(--mono);
  color: var(--accent);
  font-size: 16px;
}

.faq-item[open] .faq-q::after {
  content: "−";
}

.faq-a {
  padding: 0 20px 18px;
  font-size: 13.8px;
  color: var(--ink-2);
  line-height: 1.6;
  border-top: 1px solid var(--hair);
  padding-top: 14px;
}

/* ============================================================================
   LINEAR TELEMETRY ANIMATIONS, WAVEFORMS & CARD SCHEMATICS
   ============================================================================ */
.bio-spectrum-marker {
  transition: left 0.45s var(--ease-out), background-color 0.3s ease, box-shadow 0.3s ease;
}

.bio-driver-item {
  flex-direction: column;
  align-items: stretch !important;
  gap: 6px;
}

.bio-driver-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.drv-bar-track {
  height: 3px;
  background: rgba(var(--ink-rgb), 0.08);
  position: relative;
  overflow: hidden;
}

.drv-bar-fill {
  height: 100%;
  transition: width 0.45s var(--ease-out);
}

#advice-lifespan-schematic {
  padding: 16px 22px 14px;
  background: var(--surface);
}

#advice-lifespan-schematic svg {
  display: block;
  width: 100%;
  height: auto;
}

.exp-card-viz,
.zone-wave-viz,
.tc-viz,
.sys-viz,
.modal-viz {
  margin-top: 14px;
  border: 1px solid var(--hair);
  background: rgba(var(--ink-rgb), 0.015);
  padding: 10px 12px;
  overflow: hidden;
}

.tc-viz {
  margin: 0 0 16px;
}

.sys-viz {
  margin-top: 4px;
  padding: 14px 16px;
}

.modal-viz {
  margin: 0 0 10px;
  padding: 16px 18px;
}

.exp-card-viz svg,
.zone-wave-viz svg,
.tc-viz svg,
.sys-viz svg,
.modal-viz svg {
  display: block;
  width: 100%;
  height: auto;
}

@keyframes dashFlow {
  to {
    stroke-dashoffset: -28;
  }
}

.flow-dash {
  stroke-dasharray: 5 4;
  animation: dashFlow 1.8s linear infinite;
}

@keyframes drawLine {
  from {
    stroke-dashoffset: 900;
  }
  to {
    stroke-dashoffset: 0;
  }
}

.draw-line {
  stroke-dasharray: 900;
  animation: drawLine 1.1s var(--ease-out) forwards;
}

/* ============================================================================
   TIDY STEP-BY-STEP TOOL HEADERS, PLAIN-ENGLISH BANNERS & HELPER SUBTITLES
   ============================================================================ */
.tool-step-header {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.step-badge {
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 3px 8px;
  background: rgba(var(--acc-rgb), 0.12);
  border: 1px solid rgba(var(--acc-rgb), 0.45);
  color: var(--accent);
  font-weight: 500;
}

.step-badge.optional {
  background: rgba(var(--blue-rgb), 0.1);
  border-color: rgba(var(--blue-rgb), 0.4);
  color: var(--blue);
}

.step-title {
  font-size: 14.5px;
  font-weight: 500;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.step-hint {
  margin-inline-start: auto;
  font-size: 9.5px;
  color: var(--dim);
  letter-spacing: 0.1em;
}

.opt-helper {
  display: block;
  font-size: 11.5px;
  color: var(--dim);
  margin: -2px 0 8px;
  line-height: 1.35;
}

.tool-plain-banner {
  border-top: 1px solid var(--faint);
  background: rgba(var(--green-rgb), 0.04);
  padding: 12px 18px;
  margin-top: 14px;
  font-size: 13px;
  color: var(--ink-2);
  line-height: 1.5;
}

.tool-plain-banner strong {
  color: var(--ink);
  font-weight: 500;
}

/* Collapsible Smartwatch Drawer in Hero */
.opt-drawer {
  margin-top: 14px;
  border-top: 1px solid var(--faint);
  padding-top: 12px;
}

.opt-drawer-summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  padding: 6px 4px;
  user-select: none;
  transition: opacity 0.18s ease;
}

.opt-drawer-summary::-webkit-details-marker {
  display: none;
}

.opt-drawer-summary:hover {
  opacity: 0.9;
}

.opt-drawer-body {
  padding-top: 14px;
  margin-top: 10px;
  border-top: 1px dashed var(--faint);
}

/* Compact 4-Pill Bio-Age Drivers Row */
.bio-drivers-compact {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--faint);
}

.bio-drv-pill {
  border: 1px solid var(--faint);
  background: rgba(var(--bg-rgb), 0.55);
  padding: 8px 10px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.bio-drv-pill .lbl {
  font-family: var(--mono);
  font-size: 9.5px;
  color: var(--dim);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.bio-drv-pill .val {
  font-family: var(--mono);
  font-size: 12.5px;
  font-weight: 500;
}

/* Collapsible Deep-Dive Science Drawers under Tools */
.tool-drawer {
  border: 1px solid var(--faint);
  background: var(--surface);
}

.tool-drawer-summary {
  list-style: none;
  padding: 13px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  font-size: 13.5px;
  font-weight: 400;
  color: var(--ink-2);
  user-select: none;
  transition: background 0.18s ease, color 0.18s ease;
}

.tool-drawer-summary::-webkit-details-marker {
  display: none;
}

.tool-drawer-summary:hover {
  background: var(--surface-hover);
  color: var(--ink);
}

.tool-drawer[open] .tool-drawer-summary {
  border-bottom: 1px solid var(--faint);
  color: var(--ink);
}

.tool-drawer-body {
  padding: 18px;
}

.fasting-inline-note {
  margin-top: 16px;
}

.training-unified-frame,
.labs-unified-frame {
  padding: 22px 24px;
}

.training-unified-frame .hr-zones-head {
  padding: 14px 4px 16px;
}

.fasting-practical-bar {
  margin-top: 16px;
}

.fasting-practical-bar .cell {
  padding: 14px 18px;
}

.zone-meta-list {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--hair);
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-size: 12px;
  color: var(--ink-2);
}

.zone-meta-list span {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.zone-meta-list b {
  font-family: var(--mono);
  font-size: 10px;
  color: var(--dim);
  font-weight: 400;
  text-transform: uppercase;
}

.meal-builder-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.meal-card-item {
  border: 1px solid var(--faint);
  background: rgba(var(--bg-rgb), 0.6);
  padding: 11px 13px;
  font-size: 12.8px;
  line-height: 1.45;
}

.meal-card-item strong {
  display: block;
  color: var(--ink);
  font-weight: 500;
  margin-bottom: 3px;
}

/* ============================================================================
   UNIFIED 4-TOOL STUDIO SWITCHER & HIGH-PERFORMANCE RENDERING RULES
   ============================================================================ */
.sec {
  content-visibility: auto;
  contain-intrinsic-size: auto 560px;
}

.scan {
  display: none !important;
}

.pulse-node,
.flow-dash {
  animation: none !important;
}

.tool-studio-bar {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding: 0;
  overflow: hidden;
}

.tool-studio-btn {
  appearance: none;
  background: transparent;
  border: none;
  border-inline-end: 1px solid var(--faint);
  padding: 16px 20px;
  text-align: left;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-family: var(--sans);
  color: var(--ink-2);
  transition: background 0.16s ease, color 0.16s ease;
}

.tool-studio-btn:last-child {
  border-inline-end: none;
}

.tool-studio-btn:hover {
  background: var(--surface-hover);
  color: var(--ink);
}

.tool-studio-btn.on {
  background: rgba(var(--acc-rgb), 0.08);
  color: var(--ink);
  box-shadow: inset 0 -2px 0 var(--accent);
}

.tool-studio-num {
  font-size: 9.5px;
  letter-spacing: 0.12em;
}

.tool-studio-btn strong {
  font-size: 14.5px;
  font-weight: 500;
  color: var(--ink);
}

.tool-studio-btn span:last-child {
  font-size: 11.8px;
  color: var(--dim);
  line-height: 1.35;
}

/* ============================================================================
   CLEAN SYMMETRICAL FIRST FOLD (ZERO EMPTY SPACE 3-ROW LAYOUT)
   ============================================================================ */
.page {
  padding-top: 22px !important;
}

.hero {
  display: flex !important;
  flex-direction: column !important;
  gap: 16px !important;
  margin-bottom: 42px !important;
}

.hero-header-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr);
  gap: 18px;
  align-items: stretch;
}

.hero-intro-block {
  border: 1px solid var(--faint);
  background: var(--surface);
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
}

.hero-header-bar h1 {
  font-size: clamp(30px, 3.3vw, 46px);
  line-height: 1.05;
  margin: 4px 0 0;
}

.hero-header-bar .lead {
  margin: 4px 0 0;
  font-size: 13.8px;
  line-height: 1.5;
  color: var(--ink-2);
  max-width: none;
}

.hero-header-bar .bio-age-card {
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.hero-header-bar .bio-age-top {
  padding-bottom: 10px;
}

.hero-header-bar .bio-age-numbers {
  padding: 10px 0;
}

.hero-header-bar .bio-big-val {
  font-size: clamp(28px, 2.8vw, 38px);
}

.hero-header-bar .bio-pace-val {
  font-size: clamp(22px, 2.2vw, 30px);
}

.hero-header-bar .bio-spectrum {
  padding: 8px 0 4px;
  border-bottom: none;
}

.hero-header-bar .bio-drivers-compact {
  margin-top: 6px;
  padding-top: 8px;
}

.hero-main-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr);
  gap: 18px;
  align-items: stretch;
}

.hero-main-grid .control-panel {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 18px 22px;
}

.hero-main-grid .hero-stage {
  min-height: 380px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-main-grid .cad-canvas {
  padding: 36px 10px 30px;
  flex: 1;
}

.hero-main-grid .cad-svg {
  max-height: 350px;
  width: 100%;
}

.hero-metrics-strip {
  width: 100%;
}

.hero-metrics-strip .cell.stat {
  padding: 16px 20px;
}

@media (max-width: 960px) {
  .hero-header-bar,
  .hero-main-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .hero-metrics-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .tool-studio-bar {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .tool-studio-btn:nth-child(1),
  .tool-studio-btn:nth-child(2) {
    border-bottom: 1px solid var(--faint);
  }
}

@media (max-width: 780px) {
  .bio-drivers-compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .hero-metrics-strip,
  .tool-studio-bar,
  .meal-builder-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .tool-studio-btn {
    border-inline-end: none;
    border-bottom: 1px solid var(--faint);
  }
  .tool-studio-btn:last-child {
    border-bottom: none;
  }
}

/* ============================================================================
   REDESIGN: CLEAR PAGE STRUCTURE, LIVE BIO-AGE TOP BAR & LINE-ART SYSTEM
   ============================================================================ */
[id] { scroll-margin-top: calc(var(--topbar-h, 72px) + 12px); }

/* --- Top bar ------------------------------------------------------------- */
.topbar {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  grid-template-areas: "brand tabs bio actions";
  gap: 14px;
  padding: 8px var(--gutter);
}
.brand { grid-area: brand; flex-direction: row; align-items: center; gap: 10px; }
.brand-logo {
  width: 34px; height: 34px; flex: none;
  fill: none; stroke: var(--accent); stroke-width: 1.6;
  stroke-linecap: round; stroke-linejoin: round;
}
.brand-logo .brand-ecg { stroke: var(--ink); stroke-width: 1.4; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-mark { font-family: var(--sans); font-weight: 600; font-size: 16px; letter-spacing: -0.01em; }
.brand-sub { font-size: 9.5px; letter-spacing: 0.08em; text-transform: uppercase; }

.tabs { grid-area: tabs; margin-inline: auto; gap: 4px; min-width: 0; position: relative; }
.tab {
  font-family: var(--sans);
  font-size: 13px;
  letter-spacing: 0;
  text-transform: none;
  padding: 6px 12px 6px 7px;
  border-radius: 999px;
  gap: 8px;
}
.tab .n { display: none; }
.tab .line-icon { --s: 26px; }
.tab[aria-current="page"] {
  background: rgba(var(--acc-rgb), 0.09);
  border-color: rgba(var(--acc-rgb), 0.35);
}

/* Live biological age widget (gauge + number + delta) */
.bio-live {
  grid-area: bio;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 14px 5px 8px;
  border: 1.5px solid rgba(var(--green-rgb), 0.55);
  background: rgba(var(--green-rgb), 0.08);
  border-radius: 14px;
  color: var(--green);
  text-decoration: none;
  white-space: nowrap;
  transition: border-color 0.3s ease, background-color 0.3s ease, color 0.3s ease;
}
.bio-live.warn { color: var(--amber); border-color: rgba(var(--amber-rgb), 0.55); background: rgba(var(--amber-rgb), 0.08); }
.bio-live.older { color: var(--accent); border-color: rgba(var(--acc-rgb), 0.55); background: rgba(var(--acc-rgb), 0.08); }
.bio-live:hover { background: rgba(var(--ink-rgb), 0.05); }
.bio-live.bump .bio-live-val b { animation: bioBump 0.5s var(--ease-out); }
@keyframes bioBump {
  0% { transform: scale(1); }
  35% { transform: scale(1.14); }
  100% { transform: scale(1); }
}
.bio-gauge {
  width: 46px; height: 29px; flex: none;
  fill: none; stroke-width: 3; stroke-linecap: round;
}
.bio-gauge .g-young { stroke: var(--green); }
.bio-gauge .g-mid { stroke: rgba(var(--ink-rgb), 0.25); }
.bio-gauge .g-old { stroke: var(--accent); }
.bio-gauge .g-ticks { stroke: var(--dim); stroke-width: 1.2; }
.bio-gauge .g-needle {
  stroke: currentColor; stroke-width: 2; fill: currentColor;
  transform-origin: 24px 26px;
  transform-box: view-box;
  transition: transform 0.6s var(--ease-out);
}
.bio-live-text { display: flex; flex-direction: column; line-height: 1.05; }
.bio-live-label {
  font-family: var(--mono); font-size: 9.5px; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--dim);
}
.bio-live-val { font-family: var(--sans); color: inherit; }
.bio-live-val b { display: inline-block; font-size: 26px; font-weight: 500; letter-spacing: -0.03em; }
.bio-live-val small { font-size: 11px; color: var(--dim); margin-left: 3px; }
.bio-live-side {
  display: flex; flex-direction: column; gap: 2px;
  padding-left: 10px; border-left: 1px solid rgba(var(--ink-rgb), 0.15);
  font-size: 12px; line-height: 1.2;
}
.bio-live-delta { font-weight: 600; }
.bio-live-real { color: var(--dim); font-size: 11px; }

.topbar-actions { grid-area: actions; gap: 6px; }
.icon-btn {
  display: inline-flex; align-items: center; gap: 6px;
  height: 36px; padding: 0 11px;
  border: 1px solid var(--faint); border-radius: 10px;
  background: transparent; color: var(--ink-2);
  font: 500 12.5px var(--sans); cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}
.icon-btn:hover { background: rgba(var(--ink-rgb), 0.05); border-color: rgba(var(--ink-rgb), 0.3); }
.icon-btn svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; }

@media (max-width: 1240px) {
  .brand-sub { display: none; }
  .tab { padding: 5px 9px 5px 6px; font-size: 12.5px; }
  .icon-btn-label { display: none; }
}
@media (max-width: 1400px) {
  .topbar {
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-areas: "brand bio actions" "tabs tabs tabs";
    row-gap: 6px;
  }
  .bio-live { justify-self: end; }
  .tabs { margin: 0; justify-content: flex-start; }
}
@media (max-width: 560px) {
  .topbar { gap: 8px; padding: 6px 12px; }
  .brand-text { display: none; }
  .brand-logo { width: 30px; height: 30px; }
  .bio-live { justify-self: stretch; padding: 4px 10px 4px 6px; gap: 8px; }
  .bio-live-val b { font-size: 22px; }
  .bio-gauge { width: 38px; height: 24px; }
  .bio-live-side { padding-left: 8px; font-size: 11px; }
  .icon-btn { height: 32px; padding: 0 8px; }
  .theme-btn span { font-size: 11.5px; }
  .tab { font-size: 12px; }
  .tab .line-icon { --s: 22px; }
}

/* --- Line icons ------------------------------------------------------------ */
.line-icon {
  --ic: var(--accent);
  display: inline-grid;
  place-items: center;
  width: var(--s, 42px);
  height: var(--s, 42px);
  padding: calc(var(--s, 42px) * 0.2);
  border-radius: calc(var(--s, 42px) * 0.3);
  border: 1.2px solid color-mix(in srgb, var(--ic) 45%, transparent);
  background: color-mix(in srgb, var(--ic) 9%, transparent);
  color: var(--ic);
}
.line-icon svg { width: 100%; height: 100%; overflow: visible; }
.line-icon .ios-glyph {
  fill: none;
  stroke: var(--ic);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* --- Hero: intro + how it works ------------------------------------------- */
.hero-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
}
.hero-intro .hero-intro-block {
  border: 1px solid var(--faint);
  background: var(--surface);
  padding: 22px 26px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
}
.hero-intro h1 { font-size: clamp(30px, 3.6vw, 50px); line-height: 1.05; margin: 6px 0 0; font-weight: 300; }
.hero-intro h1 em { font-style: normal; color: var(--accent); }
.hero-intro .lead { margin: 8px 0 0; font-size: 15px; line-height: 1.55; }
.hero-intro .lead strong { color: var(--green); font-weight: 600; }

.how-steps {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-rows: repeat(3, 1fr);
  border: 1px solid var(--faint); background: var(--surface);
  counter-reset: how;
}
.how-steps li { counter-increment: how; border-bottom: 1px dashed var(--faint); }
.how-steps li:last-child { border-bottom: none; }
.how-steps a {
  display: flex; align-items: center; gap: 14px;
  height: 100%; padding: 12px 18px;
  color: var(--ink); text-decoration: none;
  transition: background-color 0.2s ease;
}
.how-steps a:hover { background: var(--surface-hover); }
.how-steps a::after {
  content: counter(how);
  margin-left: auto; font-family: var(--mono); font-size: 11px; color: var(--dim);
  width: 22px; height: 22px; display: grid; place-items: center;
  border: 1px solid var(--faint); border-radius: 50%;
}
.how-steps b { display: block; font-weight: 500; font-size: 15px; }
.how-steps small { display: block; color: var(--dim); font-size: 12.5px; margin-top: 2px; }
.how-ico { display: contents; }

/* --- Hero: inputs | results ----------------------------------------------- */
.hero-main-grid {
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  align-items: start;
}
.hero-main-grid .control-panel {
  position: sticky;
  top: calc(var(--topbar-h, 72px) + 14px);
  justify-content: flex-start;
  gap: 4px;
}
.panel-head {
  display: flex; align-items: center; gap: 12px;
  padding-bottom: 14px; margin-bottom: 14px;
  border-bottom: 1px solid var(--faint);
}
.panel-head-ico { display: contents; }
.panel-title { font-size: 20px; font-weight: 500; margin: 0; letter-spacing: -0.01em; }
.panel-sub { margin: 2px 0 0; font-size: 13px; color: var(--dim); }
.opt-badge {
  font-size: 9px; padding: 1px 6px; margin-left: 6px;
  border: 1px solid var(--faint); border-radius: 999px; color: var(--dim);
}
.opt-hint { font-size: 12.5px; color: var(--dim); margin: 0 0 10px; }

.hero-results { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.hero-results .bio-age-card { padding: 18px 22px; }
.hero-results .bio-age-top { padding-bottom: 12px; }
.hero-results .bio-age-numbers { padding: 12px 0; }
.hero-results .bio-big-val { font-size: clamp(32px, 3.4vw, 46px); }
.hero-results .bio-pace-val { font-size: clamp(24px, 2.4vw, 32px); }
.hero-results .bio-spectrum { padding: 10px 0 4px; border-bottom: none; }
.hero-results .hero-stage { min-height: 400px; }
.hero-results .cad-canvas { padding: 46px 10px 40px; }

.targets-head {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 16px;
  padding-top: 6px;
}
.targets-lead { margin: 6px 0 0; font-size: 14px; color: var(--ink-2); max-width: 90ch; }

@media (max-width: 960px) {
  .hero-intro,
  .hero-main-grid { grid-template-columns: minmax(0, 1fr); }
  .hero-main-grid .control-panel { position: static; }
}
@media (max-width: 560px) {
  .hero-intro .hero-intro-block { padding: 18px; }
  .how-steps a { padding: 10px 14px; }
  .hero-results .hero-stage { min-height: 0; }
  .hero-results .bio-age-numbers { grid-template-columns: 1fr 1fr; }
  .hero-results .bio-vs-divider { display: none; }
  .hero-results .pace-block { grid-column: 1 / -1; border-left: none; padding-left: 0; border-top: 1px solid var(--faint); padding-top: 10px; }
  .hero-mode { position: static; margin: 12px 12px 0; flex-wrap: wrap; }
  .hero-coords { display: none; }
  .hero-results .cad-canvas { padding: 10px 0 44px; }
}

/* --- Section headers: number icon + line-art scene ------------------------ */
.sec > .sec-n {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 0;
  position: sticky; top: calc(var(--topbar-h, 72px) + 18px); align-self: start;
}
.sec > .sec-n::before { display: none; }
.sec > .sec-n > span:not(.line-icon) {
  font-family: var(--mono); font-size: 11px; color: var(--dim);
  width: 22px; height: 22px; display: grid; place-items: center;
  border: 1px solid var(--faint); border-radius: 50%;
}
.sec-title { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); align-items: center; }
.sec-side { display: flex; align-items: center; gap: 18px; }
.sec-side p { margin: 0; font-size: 15px; }
.scene-art { flex: none; width: 190px; }
.scene-svg { display: block; width: 100%; height: auto; overflow: visible; }
.scene-svg .scene-ground { fill: none; stroke: var(--faint); stroke-width: 1.2; stroke-linecap: round; }
.scene-svg .scene-ground.dashed { stroke-dasharray: 2 6; }
.scene-svg .scene-halo { fill: rgba(var(--acc-rgb), 0.04); stroke: var(--faint); stroke-dasharray: 3 6; }
.scene-svg .scene-spark { fill: none; stroke: var(--dim); stroke-width: 1.1; stroke-linecap: round; opacity: 0.6; }
.scene-obj {
  fill: none;
  stroke: var(--ic);
  stroke-linecap: round;
  stroke-linejoin: round;
}
.scene-art .scene-obj { opacity: 0; transition: opacity 0.7s ease, translate 0.9s var(--ease-out); translate: 0 10px; }
.scene-art.drawn .scene-obj { opacity: 1; translate: 0 0; }
.scene-art.drawn .scene-obj:nth-of-type(2) { transition-delay: 0.15s; }
.scene-art.drawn .scene-obj:nth-of-type(3) { transition-delay: 0.3s; }
.scene-art.drawn .scene-obj:nth-of-type(n+4) { transition-delay: 0.45s; }
.scene-art .scene-halo { transform-origin: center; transform-box: fill-box; animation: haloBreath 6s ease-in-out infinite; }
@keyframes haloBreath { 50% { transform: scale(1.06); } }
@media (prefers-reduced-motion: reduce) {
  .scene-art .scene-obj { opacity: 1; translate: none; transition: none; }
  .scene-art .scene-halo { animation: none; }
  .bio-live.bump .bio-live-val b { animation: none; }
}

.foot { position: relative; flex-direction: column; align-items: center; text-align: center; }
.foot-art { flex: 0 0 100%; max-width: 420px; margin: 0 auto 6px; }

@media (max-width: 780px) {
  .sec-title { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .sec > .sec-n { position: static; flex-direction: row; }
  .sec-side { flex-direction: row-reverse; justify-content: space-between; }
  .scene-art { width: 130px; }
}
@media (max-width: 480px) {
  .sec-side { flex-direction: column-reverse; align-items: flex-start; }
  .scene-art { width: 160px; }
}

@media print {
  .scene-art, .bio-live { display: none !important; }
}

.hero { align-items: stretch !important; }
.hero-results .hero-coords { top: auto; bottom: 12px; }

/* Sections render eagerly so menu jumps land on the right section */
.sec { content-visibility: visible; contain-intrinsic-size: none; }
.theme-btn #theme-label { display: inline-flex; gap: 6px; align-items: center; }
@media (max-width: 560px) {
  .bio-live { min-width: 0; }
  .bio-live-side { min-width: 0; }
  .bio-live-delta, .bio-live-real { overflow: hidden; text-overflow: ellipsis; }
}

/* Corner "+" marks on full-width frames must not cause sideways scroll on phones */
html, body { overflow-x: clip; }

/* ============================================================================
   LINE-ART PASS 2: CARD DRAWINGS, SECTION DOODLES & HEARTBEAT DIVIDERS
   ============================================================================ */
.card-art { display: inline-block; width: 92px; flex: none; }
.card-art svg { display: block; width: 100%; height: auto; overflow: visible; }
.card-art-halo { fill: color-mix(in srgb, var(--ic) 8%, transparent); stroke: color-mix(in srgb, var(--ic) 35%, transparent); stroke-dasharray: 2 4; }
.card-art-ground { stroke: var(--faint); fill: none; stroke-linecap: round; }
.card-art-spark { stroke: var(--dim); fill: none; stroke-linecap: round; opacity: 0.6; }
.card-art .scene-obj { transition: transform 0.4s var(--ease-out); transform-box: fill-box; }
.cell:hover .card-art .scene-obj:nth-of-type(1),
.advice-col:hover .card-art .scene-obj:nth-of-type(1) { animation: artBob 1.2s ease-in-out; }
@keyframes artBob { 50% { translate: 0 -2px; } }

.hero-metrics-strip .stat .stat-top { align-items: flex-start; margin-bottom: 2px; }
.advice-col-head { gap: 12px; }
.advice-col-head > div:first-child { flex: 1; }
.advice-col-head .tag { display: none; }

/* Tool tabs: drawing on the left, text on the right */
.tool-studio-btn {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  column-gap: 14px;
  align-content: center;
}
.tool-studio-btn > .line-icon { --s: 46px; grid-row: 1 / 4; align-self: center; }
.tool-studio-btn > :not(.line-icon) { grid-column: 2; }
.tool-studio-btn:hover > .line-icon { animation: artBob 1s ease-in-out; }

/* Blood test rows and checklist */
.bio-row-name { display: inline-flex; align-items: center; gap: 10px; }
.bio-row-name .line-icon { --s: 26px; }
.check-cell .line-icon { transition: transform 0.3s var(--ease-out); }
.check-cell:hover .line-icon { transform: rotate(-6deg) scale(1.05); }
.check-cell.done h3 { text-decoration: line-through; text-decoration-color: rgba(var(--green-rgb), 0.6); }

/* Hero scene inside the intro card */
.hero-intro .hero-intro-block { position: relative; padding-right: 210px; }
.hero-scene { position: absolute; right: 18px; bottom: 16px; width: 180px; }
@media (max-width: 1100px) {
  .hero-intro .hero-intro-block { padding-right: 26px; }
  .hero-scene { position: static; width: 170px; order: -1; }
}

/* Big faint doodles behind each section */
.sec-deco { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; }
.sec-deco svg {
  position: absolute;
  fill: none;
  stroke: var(--ic);
  stroke-width: 0.14;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0.32;
}
.sec-deco-a { width: 260px; height: 260px; right: -40px; top: 40px; transform: rotate(12deg); }
.sec-deco-b { width: 200px; height: 200px; left: -70px; bottom: 30px; transform: rotate(-14deg); }
.sec > :not(.sec-deco):not(.sec-n) { position: relative; z-index: 1; }
.sec > .sec-n { z-index: 1; }
.hero { position: relative; }
#sec-profile > .sec-deco .sec-deco-a { top: auto; bottom: 120px; right: -60px; }
#sec-profile > .sec-deco .sec-deco-b { bottom: auto; top: 10px; }
@media (max-width: 780px) {
  .sec-deco svg { opacity: 0.2; }
  .sec-deco-a { width: 180px; height: 180px; right: -50px; }
  .sec-deco-b { display: none; }
}

/* Heartbeat line instead of a flat rule between sections */
.sec { border-top: none; }
.sec::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -12px;
  height: 24px;
  background: linear-gradient(90deg, rgba(var(--acc-rgb), 0.55), var(--faint) 30%, var(--faint) 70%, rgba(var(--green-rgb), 0.55));
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='24'%3E%3Cpath d='M0 12H160l5-7 6 15 6-17 5 13 3-4H260' fill='none' stroke='%23000' stroke-width='1.3' stroke-linejoin='round'/%3E%3C/svg%3E") repeat-x left center / 260px 24px;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='24'%3E%3Cpath d='M0 12H160l5-7 6 15 6-17 5 13 3-4H260' fill='none' stroke='%23000' stroke-width='1.3' stroke-linejoin='round'/%3E%3C/svg%3E") repeat-x left center / 260px 24px;
  z-index: 1;
}

@media (prefers-reduced-motion: reduce) {
  .card-art .scene-obj, .tool-studio-btn > .line-icon { animation: none !important; }
}
@media print { .sec-deco, .card-art { display: none !important; } }

@media (max-width: 560px) {
  .bio-live-delta .yrs { display: none; }
}

/* Body map on phones: labels don't fit beside the figure, so show just the figure and organ dots */
@media (max-width: 560px) {
  #cad-organs text,
  #cad-organs use[href^="#call-path"] { display: none; }
}

/* ===== SLIDERS + DETAILS PANEL (pass 3) ===== */
input[type="range"] {
  --p: 50%;
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 28px;
  background: transparent;
  cursor: grab;
  touch-action: pan-y;
  margin: 0;
}
input[type="range"]:active { cursor: grabbing; }
input[type="range"]::-webkit-slider-runnable-track {
  height: 8px;
  border-radius: 999px;
  background:
    linear-gradient(90deg, var(--accent) 0 var(--p), rgba(var(--ink-rgb), 0.12) var(--p) 100%);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.12);
}
input[type="range"]::-moz-range-track {
  height: 8px; border-radius: 999px; background: rgba(var(--ink-rgb), 0.12);
}
input[type="range"]::-moz-range-progress {
  height: 8px; border-radius: 999px; background: var(--accent);
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 24px;
  height: 24px;
  margin-top: -8px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--accent);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.22), 0 0 0 0 rgba(var(--acc-rgb), 0.18);
  transition: transform 0.15s var(--ease-out), box-shadow 0.15s var(--ease-out);
  cursor: grab;
}
input[type="range"]::-moz-range-thumb {
  width: 20px; height: 20px; border-radius: 50%;
  background: #fff; border: 2px solid var(--accent);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.22);
  transition: transform 0.15s var(--ease-out), box-shadow 0.15s var(--ease-out);
  cursor: grab;
}
input[type="range"]:hover::-webkit-slider-thumb { transform: scale(1.08); box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25), 0 0 0 6px rgba(var(--acc-rgb), 0.14); }
input[type="range"]:active::-webkit-slider-thumb { transform: scale(1.18); box-shadow: 0 3px 10px rgba(0, 0, 0, 0.28), 0 0 0 10px rgba(var(--acc-rgb), 0.16); }
input[type="range"]:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 4px var(--bg), 0 0 0 6px var(--accent); }
input[type="range"]:hover::-moz-range-thumb { box-shadow: 0 0 0 6px rgba(var(--acc-rgb), 0.14); }
input[type="range"]:active::-moz-range-thumb { transform: scale(1.15); box-shadow: 0 0 0 10px rgba(var(--acc-rgb), 0.16); }
input[type="range"]:focus-visible { outline: none; }
@media (pointer: coarse) {
  input[type="range"] { height: 36px; }
  input[type="range"]::-webkit-slider-thumb { width: 28px; height: 28px; margin-top: -10px; }
}

.slider-box {
  gap: 12px;
  padding: 4px 12px;
  border-radius: 12px;
  background: var(--bg);
  border: 1px solid rgba(var(--ink-rgb), 0.1);
}
.slider-box > .mono { font-size: 11px; white-space: nowrap; }
.opt-item { border-radius: 12px; }

/* Your details: a clearly separate, raised card */
#profile-inputs.control-panel {
  background: var(--panel-raised);
  border: 1px solid rgba(var(--ink-rgb), 0.14);
  border-top: 3px solid var(--accent);
  border-radius: 16px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 12px 32px -12px rgba(0, 0, 0, 0.18);
}
:root { --panel-raised: #15161a; }
:root[data-theme="light"] { --panel-raised: #ffffff; }

/* ===== IMPACT EXPLORER ===== */
.impact { margin-bottom: 40px; }
.impact-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 14px; }
.impact-head p { max-width: 380px; margin: 0; color: var(--dim); font-size: 14px; line-height: 1.5; }
.impact-h { font-family: var(--sans); font-weight: 400; font-size: clamp(22px, 2.6vw, 30px); letter-spacing: -0.02em; margin: 6px 0 0; }
.impact-tabs { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px 2px 12px; scroll-snap-type: x proximity; }
.impact-tabs::-webkit-scrollbar { display: none; }
.ix-tab {
  flex: none; display: inline-flex; align-items: center; gap: 8px; scroll-snap-align: start;
  font: 500 13.5px var(--sans); color: var(--ink-2); cursor: pointer;
  padding: 6px 14px 6px 6px; border-radius: 999px;
  background: var(--panel-raised); border: 1px solid rgba(var(--ink-rgb), 0.14);
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
}
.ix-tab:hover { border-color: rgba(var(--ink-rgb), 0.35); transform: translateY(-1px); }
.ix-tab.on { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.ix-tab.on .line-icon { --ic: var(--bg) !important; background: transparent; border-color: rgba(var(--bg-rgb), 0.35); }
.ix-tab:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.impact-panel { padding: 26px; border-radius: 16px; background: var(--panel-raised); overflow: hidden; }
.ix-main { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 32px; }
.ix-titlerow { display: flex; gap: 14px; align-items: flex-start; }
.ix-titlerow h3 { font: 500 21px/1.25 var(--sans); letter-spacing: -0.015em; margin: 2px 0 6px; }
.ix-lead { margin: 0; color: var(--dim); font-size: 14px; line-height: 1.55; }
.ix-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 22px 0 18px; }
.ix-stat { display: flex; flex-direction: column; gap: 6px; padding: 14px 12px; border-radius: 12px; background: var(--bg); border: 1px solid rgba(var(--ink-rgb), 0.1); }
.ix-stat b { font: 400 28px/1 var(--sans); letter-spacing: -0.03em; color: var(--accent); font-variant-numeric: tabular-nums; }
.ix-stat span { font-size: 12.5px; line-height: 1.4; color: var(--ink-2); }
.ix-stat small { font: 10px/1.35 var(--mono); color: var(--dim); margin-top: auto; }
.ix-findings { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.ix-findings li { position: relative; padding-left: 22px; font-size: 13.5px; line-height: 1.55; color: var(--ink-2); }
.ix-findings li::before { content: ""; position: absolute; left: 2px; top: 8px; width: 10px; height: 1.5px; background: var(--accent); }
.ix-side { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.ix-chart-card { border-radius: 12px; border: 1px solid rgba(var(--ink-rgb), 0.1); background: var(--bg); padding: 10px 10px 8px; }
.ix-chart { width: 100%; height: auto; display: block; overflow: visible; }
.ix-note { margin: 4px 6px 2px; font: 10.5px/1.45 var(--mono); color: var(--dim); }
.ix-grid { stroke: rgba(var(--ink-rgb), 0.08); stroke-width: 1; stroke-dasharray: 2 4; }
.ix-axis { stroke: rgba(var(--ink-rgb), 0.35); stroke-width: 1; }
.ix-tick { font: 10px var(--mono); fill: var(--dim); }
.ix-axl { font: 10.5px var(--sans); fill: var(--dim); }
.ix-tag { font: 500 10.5px var(--sans); fill: var(--ink-2); }
.ix-tag.ix-acc { fill: var(--accent); }
.ix-line { fill: none; stroke: var(--ink); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.ix-line.ix-muted { stroke: rgba(var(--ink-rgb), 0.4); stroke-dasharray: 5 4; }
.ix-chart .ix-line:not(.ix-muted):last-of-type { stroke: var(--accent); }
.ix-area { fill: rgba(var(--ink-rgb), 0.05); stroke: none; }
.ix-band { fill: rgba(var(--ink-rgb), 0.06); }
.ix-dot { fill: var(--bg); stroke: var(--accent); stroke-width: 2; }
.ix-you line { stroke: var(--accent); stroke-width: 1.2; stroke-dasharray: 3 3; }
.ix-you circle { fill: var(--accent); }
.ix-you .ix-you-ring { fill: rgba(var(--acc-rgb), 0.18); animation: ixPulse 2s ease-out infinite; transform-box: fill-box; transform-origin: center; }
.ix-you text { font: 600 11px var(--sans); fill: var(--accent); }
.ix-do { border-radius: 12px; padding: 14px 16px; border: 1px solid rgba(var(--ink-rgb), 0.12); }
.ix-do-h { display: flex; align-items: center; gap: 8px; font: 600 13px var(--sans); margin-bottom: 8px; }
.ix-do ol { margin: 0; padding-left: 20px; display: grid; gap: 6px; font-size: 13.5px; line-height: 1.45; color: var(--ink-2); }

/* animations */
.ix-anim .ix-line { stroke-dasharray: var(--len, 1) calc(var(--len, 1) * 2); stroke-dashoffset: calc(var(--len, 1) * 1.05); animation: ixDraw 1.3s var(--ease-out) 0.15s forwards; }
.ix-anim .ix-area, .ix-anim .ix-band, .ix-anim .ix-tag { opacity: 0; animation: ixFade 0.6s ease 0.9s forwards; }
.ix-anim .ix-dot { opacity: 0; animation: ixPop 0.4s var(--ease-out) forwards; animation-delay: calc(0.35s + var(--i) * 0.14s); transform-box: fill-box; transform-origin: center; }
.ix-anim .ix-you { opacity: 0; animation: ixFade 0.5s ease 1.2s forwards; }
.ix-enter .ix-stat, .ix-enter .ix-findings li { opacity: 0; transform: translateY(8px); animation: ixUp 0.5s var(--ease-out) forwards; animation-delay: calc(0.08s + var(--i) * 0.08s); }
.ix-enter .ix-findings li { animation-delay: calc(0.35s + var(--i) * 0.08s); }
.ix-enter .ix-side { animation: ixFade 0.4s ease both; }
@keyframes ixDraw { to { stroke-dashoffset: 0; } }
@keyframes ixFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes ixUp { to { opacity: 1; transform: none; } }
@keyframes ixPop { from { opacity: 0; transform: scale(0.2); } to { opacity: 1; transform: scale(1); } }
@keyframes ixPulse { 0% { transform: scale(0.6); opacity: 0.9; } 100% { transform: scale(2); opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .ix-anim .ix-line, .ix-anim .ix-area, .ix-anim .ix-band, .ix-anim .ix-tag, .ix-anim .ix-dot, .ix-anim .ix-you,
  .ix-enter .ix-stat, .ix-enter .ix-findings li, .ix-you .ix-you-ring { animation: none; opacity: 1; transform: none; stroke-dashoffset: 0; }
}
@media (max-width: 960px) {
  .ix-main { grid-template-columns: 1fr; gap: 22px; }
  .impact-head { flex-direction: column; align-items: flex-start; gap: 8px; }
}
@media (max-width: 560px) {
  .impact-panel { padding: 16px; }
  .ix-stats { grid-template-columns: 1fr; }
  .ix-stat { flex-direction: row; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
  .ix-stat b { font-size: 24px; min-width: 76px; }
  .ix-stat span { flex: 1; min-width: 0; }
  .ix-stat small { flex-basis: 100%; }
  .ix-titlerow .line-icon { display: none; }
}


/* topic groups, evidence badge, bar charts and animated line art */
.ix-cats { display: flex; flex-wrap: wrap; gap: 4px; padding: 4px; margin-bottom: 12px; border-radius: 999px; border: 1px solid rgba(var(--ink-rgb), 0.12); width: fit-content; max-width: 100%; }
.ix-cat { appearance: none; border: 0; background: transparent; color: var(--dim); font: 500 13px var(--sans); padding: 7px 14px; border-radius: 999px; cursor: pointer; display: inline-flex; align-items: center; gap: 7px; transition: background 0.2s, color 0.2s; }
.ix-cat span { font: 10.5px var(--mono); opacity: 0.7; }
.ix-cat:hover { color: var(--ink); }
.ix-cat.on { background: rgba(var(--ink-rgb), 0.09); color: var(--ink); }
.ix-cat.on span { color: var(--accent); opacity: 1; }
.ix-cat:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.ix-ev { display: inline-flex; align-items: center; gap: 3px; font: 500 10.5px var(--mono); letter-spacing: 0.04em; text-transform: uppercase; color: var(--dim); margin-bottom: 4px; cursor: help; }
.ix-ev i { width: 6px; height: 10px; border-radius: 2px; border: 1px solid rgba(var(--ink-rgb), 0.35); }
.ix-ev i:last-of-type { margin-right: 6px; }
.ix-ev-strong i, .ix-ev-good i:nth-child(-n+2), .ix-ev-early i:first-child { background: var(--green); border-color: var(--green); }
.ix-ev-strong { color: var(--green); }
.ix-art { flex: none; width: 92px; height: 92px; border-radius: 18px; border: 1px solid rgba(var(--ink-rgb), 0.12); background: var(--bg); display: grid; place-items: center; }
.ix-art svg { width: 76px; height: 76px; overflow: visible; fill: none; stroke: var(--ink-2); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.ix-art .acc { stroke: var(--accent); }
.ix-art .a-dim { opacity: 0.45; }
.ix-art * { transform-box: fill-box; transform-origin: center; }
.ix-art .a-breathe { animation: aBreathe 4s ease-in-out infinite; transform-origin: 50% 30%; }
.ix-art .a-flow { stroke-dasharray: 4 6; animation: aFlow 1.2s linear infinite; }
.ix-art .a-beat { animation: aBeat 1.1s ease-in-out infinite; }
.ix-art .a-ecg { stroke-dasharray: var(--len, 1) calc(var(--len, 1) * 2); stroke-dashoffset: calc(var(--len, 1) * 1.05); animation: aDrawLoop 2.4s ease-in-out infinite; }
.ix-art .a-spike { stroke-dasharray: 0.03 0.03; opacity: 0.5; }
.ix-art .a-scroll { animation: aScroll 3s linear infinite; }
.ix-art svg:has(.a-scroll) { clip-path: inset(0 round 4px); }
.ix-art .a-hop { animation: aHop 0.9s ease-in-out infinite; transform-origin: 50% 100%; }
.ix-art .a-ground { stroke-dasharray: 10 8; animation: aGround 0.6s linear infinite; }
.ix-art .a-needle { transform-origin: 50% 100%; animation: aNeedle 3.2s ease-in-out infinite; }
.ix-art .a-lift { animation: aLift 2s ease-in-out infinite; }
.ix-art .a-arrow { animation: aArrow 2s ease-in-out infinite; }
.ix-art .a-sway { transform-origin: 50% 100%; animation: aSway 3s ease-in-out infinite; }
.ix-art .a-tape { stroke-dasharray: 6 4; animation: aGround 1.4s linear infinite; }
.ix-art .a-z { opacity: 0; animation: aZ 3s ease-out infinite; }
.ix-art .a-z2 { animation-delay: 1s; } .ix-art .a-z3 { animation-delay: 2s; }
.ix-art .a-spin { animation: aSpin 14s linear infinite; }
.ix-art .a-in { animation: aIn 3.2s ease-in infinite; }
.ix-art .a-in1 { --dx: 34px; --dy: 20px; } .ix-art .a-in2 { --dx: -34px; --dy: 16px; animation-delay: 0.8s; }
.ix-art .a-in3 { --dx: 20px; --dy: -32px; animation-delay: 1.6s; } .ix-art .a-in4 { --dx: -28px; --dy: -28px; animation-delay: 2.4s; }
.ix-art .a-rise { transform-origin: 50% 100%; animation: aRise 3s ease-in-out infinite; }
.ix-art .a-wave { stroke-dasharray: 6 5; animation: aWave 1.6s linear infinite; opacity: 0.6; }
.ix-art .a-w2 { animation-delay: 0.8s; }
.ix-art .a-leaf { transform-origin: 0% 100%; animation: aLeaf 3s ease-in-out infinite; }
.ix-art .a-bob { animation: aBob 2.4s ease-in-out infinite; }
.ix-art .a-b2 { animation-delay: 0.4s; } .ix-art .a-b3 { animation-delay: 0.8s; }
.ix-art .a-link { stroke-dasharray: 3 5; animation: aFlow 1.4s linear infinite; }
.ix-art .a-blink { transform-origin: 50% 50%; animation: aBlink 4.5s ease-in-out infinite; }
@keyframes aBlink { 0%, 44%, 52%, 100% { transform: scaleY(1); } 48% { transform: scaleY(0.08); } }
@keyframes aBreathe { 0%, 100% { transform: scale(0.94); } 50% { transform: scale(1.04); } }
@keyframes aFlow { to { stroke-dashoffset: -20; } }
@keyframes aBeat { 0%, 100% { transform: scale(1); } 14% { transform: scale(1.08); } 28% { transform: scale(0.98); } 42% { transform: scale(1.05); } }
@keyframes aDrawLoop { 0% { stroke-dashoffset: calc(var(--len, 1) * 1.05); } 55%, 80% { stroke-dashoffset: 0; opacity: 1; } 100% { stroke-dashoffset: 0; opacity: 0; } }
@keyframes aScroll { from { transform: translateX(0); } to { transform: translateX(-62px); } }
@keyframes aHop { 0%, 100% { transform: translateY(0) rotate(0); } 40% { transform: translateY(-10px) rotate(-6deg); } }
@keyframes aGround { to { stroke-dashoffset: -18; } }
@keyframes aNeedle { 0%, 100% { transform: rotate(-38deg); } 50% { transform: rotate(22deg); } }
@keyframes aLift { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes aArrow { 0%, 100% { opacity: 0.2; transform: translateY(4px); } 50% { opacity: 1; transform: translateY(-2px); } }
@keyframes aSway { 0%, 100% { transform: rotate(-4deg); } 50% { transform: rotate(4deg); } }
@keyframes aZ { 0% { opacity: 0; transform: translate(-6px, 8px) scale(0.7); } 30% { opacity: 1; } 100% { opacity: 0; transform: translate(4px, -8px) scale(1.1); } }
@keyframes aSpin { to { transform: rotate(360deg); } }
@keyframes aIn { 0% { opacity: 0; transform: none; } 20% { opacity: 1; } 85% { opacity: 1; transform: translate(var(--dx), var(--dy)) scale(0.6); } 100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(0.2); } }
@keyframes aRise { 0%, 100% { transform: scaleY(0.35); } 60% { transform: scaleY(1); } }
@keyframes aWave { to { stroke-dashoffset: 22; } }
@keyframes aLeaf { 0%, 100% { transform: rotate(-5deg); } 50% { transform: rotate(5deg); } }
@keyframes aBob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
.ix-ref { stroke: rgba(var(--ink-rgb), 0.3); stroke-dasharray: 4 3; }
.ix-bar { fill: rgba(var(--ink-rgb), 0.06); stroke: var(--ink-2); stroke-width: 1.6; }
.ix-hi .ix-bar { fill: rgba(var(--green-rgb), 0.16); stroke: var(--green); }
.ix-val { font: 600 11px var(--mono); fill: var(--ink-2); }
.ix-hi .ix-val { fill: var(--green); }
.ix-tick.ix-barlbl { font: 500 10.5px var(--sans); }
.ix-anim .ix-bar { transform-box: fill-box; transform-origin: 50% 100%; transform: scaleY(0); animation: ixGrow 0.8s var(--ease-out) forwards; animation-delay: calc(0.15s + var(--i) * 0.12s); }
.ix-anim .ix-val { opacity: 0; animation: ixFade 0.4s ease forwards; animation-delay: calc(0.6s + var(--i) * 0.12s); }
@keyframes ixGrow { to { transform: scaleY(1); } }
@media (prefers-reduced-motion: reduce) {
  .ix-art *, .ix-anim .ix-bar, .ix-anim .ix-val { animation: none !important; opacity: 1; transform: none; stroke-dashoffset: 0; }
}
@media (max-width: 560px) {
  .ix-art { width: 64px; height: 64px; border-radius: 14px; }
  .ix-art svg { width: 52px; height: 52px; }
  .ix-cats { border-radius: 14px; width: auto; }
  .ix-cat { padding: 6px 10px; font-size: 12.5px; }
}

/* ===== PHONE PASS ===== */
@media (max-width: 600px) {
  /* section headers: compact, no decorative scenes */
  .sec-side .scene-art, .hero-scene { display: none !important; }
  .sec { padding-top: 36px; }
  .sec-title h2 { font-size: 27px; line-height: 1.15; }
  .sec-side p { font-size: 14.5px; }

  /* hero: tighter intro, compact "how it works" row */
  .hero-intro-block { padding: 20px 18px; }
  .hero-intro h1 { font-size: 34px; }
  .how-steps li a { padding: 12px 14px; gap: 12px; }
  .how-steps small { display: none; }

  /* daily targets: 2×2 grid */
  #hero-metrics { display: grid; grid-template-columns: 1fr 1fr; }
  #hero-metrics .stat { padding: 14px; min-width: 0; }
  #hero-metrics .stat .card-art, #hero-metrics .stat-top > :not(.stat-code) { display: none; }
  #hero-metrics .stat .v { font-size: 28px; }
  #hero-metrics .stat .k { font-size: 12px; line-height: 1.4; }

  /* blood tests: table → stacked cards */
  #biomarker-table, #biomarker-table tbody, #biomarker-table tr, #biomarker-table td { display: block; width: 100%; }
  #biomarker-table thead { display: none; }
  #biomarker-table { min-width: 0 !important; }
  .table-wrap { overflow: visible !important; }
  #biomarker-table tr {
    position: relative; padding: 14px 14px 12px; margin-bottom: 10px;
    border: 1px solid rgba(var(--ink-rgb), 0.12); border-radius: 12px; background: var(--bg);
  }
  #biomarker-table td { padding: 0 !important; border: 0 !important; height: auto !important; }
  #biomarker-table td:first-child { position: absolute; top: 14px; right: 14px; width: auto; font-size: 10.5px; }
  #biomarker-table td:nth-child(2) { font-size: 15px; font-weight: 500; padding-right: 60px !important; margin-bottom: 10px; }
  #biomarker-table td[data-l] { display: grid; grid-template-columns: 96px 1fr; gap: 8px; font-size: 13px; line-height: 1.45; padding: 6px 0 !important; border-top: 1px dashed rgba(var(--ink-rgb), 0.1) !important; }
  #biomarker-table td[data-l]::before { content: attr(data-l); font: 10px/1.6 var(--mono); text-transform: uppercase; letter-spacing: 0.06em; color: var(--dim); }

  /* tool tabs and buttons: comfortable tap targets */
  .chip { min-height: 38px; }
  .impact-tabs { margin-inline: -16px; padding-inline: 16px; }
}

/* ============================================================================
   CALM LAYER: a quieter, editorial look (plain text menu, light display type,
   hairline cards, no tinted boxes, no background doodles). Loaded last on
   purpose so it wins over the earlier passes above.
   ============================================================================ */
:root {
  --bg-rgb: 5, 5, 6;
  --ink-rgb: 236, 235, 230;
  --acc-rgb: 255, 106, 61;
  --amber-rgb: 255, 106, 61;
  --bg: #050506;
  --bg-2: #08080a;
  --surface: transparent;
  --surface-hover: rgba(var(--ink-rgb), 0.035);
  --panel: #09090b;
  --panel-raised: #0a0a0d;
  --ink: #ecebe6;
  --ink-2: #c9c7c0;
  --dim: #8f8d87;
  --faint: rgba(var(--ink-rgb), 0.13);
  --hair: rgba(var(--ink-rgb), 0.07);
  --line-2: rgba(var(--ink-rgb), 0.3);
  --accent: #ff6a3d;
  --amber: #ff6a3d;
  --display: "Bricolage Grotesque", "Inter", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --radius: 4px;
}
:root[data-theme="light"] {
  --bg-rgb: 245, 244, 240;
  --ink-rgb: 22, 22, 24;
  --acc-rgb: 214, 72, 28;
  --amber-rgb: 214, 72, 28;
  --bg: #f5f4f0;
  --bg-2: #efeee9;
  --surface: transparent;
  --surface-hover: rgba(var(--ink-rgb), 0.04);
  --panel: #f0efea;
  --panel-raised: #fbfaf7;
  --ink: #161618;
  --ink-2: #3c3b38;
  --dim: #6e6c66;
  --faint: rgba(var(--ink-rgb), 0.14);
  --hair: rgba(var(--ink-rgb), 0.07);
  --line-2: rgba(var(--ink-rgb), 0.32);
  --accent: #d6481c;
  --amber: #d6481c;
}

body {
  font-size: 15px;
  font-weight: 400;
  background-image:
    linear-gradient(rgba(var(--ink-rgb), 0.022) 1px, transparent 1px),
    linear-gradient(90deg, rgba(var(--ink-rgb), 0.022) 1px, transparent 1px);
  background-size: 48px 48px;
  background-attachment: fixed;
}

/* Decoration that made the page feel busy */
.fx-glow,
.sec-deco,
.frame::before,
.frame::after,
.sec::before,
.scene-svg .scene-halo,
.scene-svg .scene-spark,
.card-art-halo,
.card-art-spark { display: none !important; }

/* --- Type ------------------------------------------------------------------ */
h1, h2, .panel-title, .impact-h {
  font-family: var(--display);
  font-weight: 300;
  font-variation-settings: "opsz" 96;
}
h1 {
  font-size: clamp(40px, 5.4vw, 76px);
  line-height: 1;
  letter-spacing: -0.03em;
  text-wrap: balance;
}
h2 { letter-spacing: -0.025em; line-height: 1.05; text-wrap: balance; }
.sec-title h2 { font-size: clamp(32px, 4vw, 54px); }
h1 em, h2 em { font-family: inherit; font-style: normal; color: var(--dim); }
h3 { font-weight: 500; letter-spacing: -0.012em; }
.lead, .sec-side p { color: var(--dim); font-size: 17px; line-height: 1.6; }
.lead strong { color: var(--ink); font-weight: 500; }
.kicker { font-size: 12px; letter-spacing: 0.06em; gap: 10px; }
.kicker::before { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }

/* --- Top bar: brand, plain text menu, quiet bio-age readout ---------------- */
.topbar {
  background: rgba(var(--bg-rgb), 0.82);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--hair);
  box-shadow: none;
  padding: 12px var(--gutter);
  gap: 24px;
}
.brand-logo { width: 24px; height: 24px; }
.brand-mark { font-size: 14px; font-weight: 600; }
.brand-sub { display: none; }
.tabs { gap: 22px; }
.tab,
.tab:hover,
.tab[aria-current="page"] {
  background: none;
  border: none;
  box-shadow: none;
  border-radius: 0;
  padding: 6px 0;
}
.tab {
  font: 400 13px var(--sans);
  color: var(--dim);
  position: relative;
  transition: color 0.2s ease;
}
.tab:hover, .tab[aria-current="page"] { color: var(--ink); }
.tab[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--accent);
}
.tab .line-icon, .tab .ios, .tab .n { display: none !important; }

.bio-live,
.bio-live.warn,
.bio-live.older {
  border: 1px solid var(--faint);
  background: transparent;
  border-radius: 2px;
  padding: 4px 12px 4px 8px;
  gap: 10px;
  color: var(--ink);
}
.bio-live:hover { background: var(--surface-hover); }
.bio-gauge { width: 34px; height: 22px; stroke-width: 2.4; }
.bio-gauge .g-young { stroke: rgba(var(--ink-rgb), 0.3); }
.bio-gauge .g-mid { stroke: rgba(var(--ink-rgb), 0.18); }
.bio-gauge .g-old { stroke: rgba(var(--ink-rgb), 0.3); }
.bio-gauge .g-needle { stroke: var(--accent); fill: var(--accent); }
.bio-live-label { font-size: 9.5px; letter-spacing: 0.08em; }
.bio-live-val b { font: 400 20px var(--mono); letter-spacing: -0.03em; }
.bio-live-side { border-left-color: var(--faint); }
.bio-live-delta { font-weight: 500; color: var(--green); }
.bio-live.warn .bio-live-delta, .bio-live.older .bio-live-delta { color: var(--accent); }

.icon-btn {
  height: 34px;
  border-radius: 2px;
  border-color: var(--faint);
  font: 400 11px var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--dim);
}
.icon-btn:hover { color: var(--ink); background: transparent; border-color: var(--line-2); }
.topbar-progress { height: 1px; }

/* --- Sections: more air, one quiet rule between them ----------------------- */
.page { max-width: 1180px; }
.sec {
  grid-template-columns: minmax(0, 1fr);
  padding: 120px 0 40px;
  border-top: 1px solid var(--hair) !important;
}
.sec > .sec-n { display: none !important; }
.sec-title { gap: 40px; margin-bottom: 44px; align-items: end; }
.sec-side { gap: 24px; }

/* --- Cards: hairline borders, no fills, no shadows ------------------------- */
.frame,
.cell,
.advice-col,
.impact-panel,
.ix-stat,
.ix-chart-card,
.ix-do,
.opt-item,
.faq-item,
.hero-intro-block,
.how-steps,
#profile-inputs.control-panel {
  background: rgba(var(--bg-rgb), 0.55);
  border: 1px solid var(--faint);
  border-radius: var(--radius);
  box-shadow: none;
}
#profile-inputs.control-panel { border-top: 1px solid var(--faint); }
.cell:hover, .ix-tab:hover { transform: none; }
.cell:hover { background: var(--surface-hover); }

/* Hero intro: just the headline and lead, no box */
.hero-intro .hero-intro-block {
  background: none;
  border: none;
  padding: 40px 0 8px;
}
.how-steps { background: none; }
.how-steps li { border-bottom-style: solid; border-bottom-color: var(--hair); }

/* Tinted callouts become plain notes with a thin accent rule */
.note,
.tool-plain-banner {
  background: transparent !important;
  border: none !important;
  border-left: 1px solid var(--accent) !important;
  border-radius: 0 !important;
  padding: 4px 0 4px 16px !important;
}

/* --- Line icons: just the drawing, no tile behind it ----------------------- */
.line-icon,
.ios.line-icon {
  border: none !important;
  background: none !important;
  box-shadow: none !important;
  padding: calc(var(--s, 42px) * 0.08);
}
.line-icon .ios-glyph { stroke-width: 1.4; }

/* --- Controls: square chips, ink fill when selected ------------------------ */
.chip {
  border-radius: 2px;
  border-color: var(--faint);
  background: transparent;
  font-family: var(--mono);
  letter-spacing: 0.04em;
  color: var(--dim);
}
.chip:hover { color: var(--ink); border-color: var(--line-2); }
.chip.on,
.chip[aria-pressed="true"],
.chip.accent.on,
.chip.accent[aria-pressed="true"] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--bg);
}
.ix-tab { border-radius: 2px; }
.tool-studio-btn.on { background: transparent; box-shadow: inset 0 -1px 0 var(--accent); }
.tag { border-radius: 2px; background: transparent !important; }

/* --- Footer ---------------------------------------------------------------- */
.foot { border-top: 1px solid var(--hair); }
.foot-art { display: none; }

/* --- Phones: brand + bio-age on one row, the five links on the next -------- */
@media (max-width: 1400px) {
  .tabs { gap: 20px; }
}
@media (max-width: 760px) {
  .topbar { padding: 10px 16px 0; row-gap: 4px; gap: 10px; }
  .tabs {
    gap: 18px;
    overflow-x: auto;
    scrollbar-width: none;
    margin-inline: -16px;
    padding: 2px 16px 0;
    mask-image: linear-gradient(90deg, transparent 0, #000 12px, #000 calc(100% - 20px), transparent 100%);
  }
  .tab { font-size: 13px; padding: 8px 0 10px; white-space: nowrap; flex: none; }
  .sec { padding: 72px 0 24px; }
  .sec-title { gap: 16px; margin-bottom: 28px; }
  .hero-intro .hero-intro-block { padding: 20px 0 0; }
  .lead, .sec-side p { font-size: 16px; }
}
@media (max-width: 560px) {
  .bio-live { padding: 3px 10px 3px 6px; }
  .bio-live-val b { font-size: 18px; }
  .icon-btn { height: 32px; }
}

/* Calm layer, part 2: one-row top bar on wide screens, fewer orange labels */
@media (min-width: 1000px) {
  .topbar {
    grid-template-columns: auto minmax(0, 1fr) auto auto;
    grid-template-areas: "brand tabs bio actions";
  }
  .tabs { margin-inline: auto; justify-content: center; }
}
.hero-intro h1 em { color: var(--dim); }
.hero-scene { display: none !important; }
.hero-intro .hero-intro-block { padding-right: 0; }
.ctrl-label { letter-spacing: 0.08em; }

.stat-code,
.tc-top .tx,
.tc-ch b,
.tc-foot .acc,
.tool-studio-num.accent-text,
#biomarker-table td:first-child,
.note > b:first-child { color: var(--dim) !important; }
.tc-ch b { background: transparent !important; border-color: var(--faint) !important; }
.tc-foot .acc { color: var(--ink) !important; }
.week-step-box {
  border: none;
  border-left: 1px solid var(--accent);
  background: transparent;
  padding: 4px 0 4px 16px;
}
.topic-card { border-radius: var(--radius); box-shadow: none; }
.tc-viz { background: none; border-color: var(--hair); }

/* ---- Topics menu in the top bar: every research page, one tap away ---- */
.tmenu { position: relative; }
.tmenu > summary { list-style: none; cursor: pointer; }
.tmenu > summary::-webkit-details-marker { display: none; }
.tmenu-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.tmenu[open] .tmenu-btn { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.tmenu-panel {
  position: fixed; z-index: 60; top: calc(var(--tm-top, 64px) + 6px); right: max(12px, calc((100vw - 1380px) / 2 + 12px));
  width: min(640px, calc(100vw - 24px)); max-height: calc(100vh - var(--tm-top, 64px) - 20px); overflow-y: auto; overscroll-behavior: contain;
  padding: 14px; border-radius: 18px; border: 1px solid var(--faint);
  background: var(--bg); box-shadow: 0 18px 50px rgba(0, 0, 0, 0.22);
  animation: tmIn 0.22s var(--ease-out, ease-out);
}
@keyframes tmIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.tmenu-all { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--faint); color: var(--ink); text-decoration: none; font: 500 14px var(--sans); }
.tmenu-all span:nth-child(2) { flex: 1; }
.tmenu-all:hover { border-color: var(--ink); }
.tmenu-cat { font: 500 10.5px var(--mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim); margin: 14px 4px 6px; }
.tmenu-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; }
.tmenu-grid a { display: flex; align-items: center; gap: 8px; padding: 7px 8px; border-radius: 10px; color: var(--ink-2); text-decoration: none; font-size: 13.5px; line-height: 1.25; }
.tmenu-grid a:hover { background: rgba(var(--ink-rgb), 0.06); color: var(--ink); }
.tmenu-grid a.on { background: var(--ink); color: var(--bg); }
.tmenu-grid a.on .line-icon { --ic: var(--bg) !important; background: transparent; border-color: rgba(var(--bg-rgb), 0.35); }
@media (max-width: 560px) { .tmenu-grid { grid-template-columns: 1fr; } .tmenu-btn .icon-btn-label { display: none; } }
@media (prefers-reduced-motion: reduce) { .tmenu-panel { animation: none; } }
.topbar:has(.tmenu[open]) { z-index: 70; }

/* ============================================================================
   CALM LAYER, PART 3: a cleaner pass. One type scale, one spacing rhythm,
   no paper grid, no boxes inside boxes, one drawing per card, simpler menus.
   ============================================================================ */
:root {
  --sp-1: 8px;
  --sp-2: 16px;
  --sp-3: 24px;
  --sp-4: 40px;
  --sp-5: 64px;
  --sp-6: 112px;
}

/* Plain background, steadier reading rhythm */
body { background-image: none; line-height: 1.6; }
p { text-wrap: pretty; }

/* Type scale: display, section, card, body, label */
h1 { font-size: clamp(40px, 5vw, 68px); }
.sec-title h2 { font-size: clamp(30px, 3.6vw, 48px); line-height: 1.08; }
.panel-title, .impact-h, .advice-col h3, #bio-age-status-title { font-size: 20px; line-height: 1.25; font-weight: 400; }
.impact-h { font-size: clamp(22px, 2.2vw, 28px); font-weight: 300; }
.ctrl-label, .opt-item-head, .bio-num-block > .mono, .bio-spectrum-labels,
.tool-drawer-summary .mono, .kicker { font-size: 11px; letter-spacing: 0.08em; }

/* Sections: same air above every step, one hairline between */
.sec { padding: var(--sp-6) 0 var(--sp-4); }
.sec-title { gap: var(--sp-5); margin-bottom: var(--sp-4); align-items: start; }
.sec-side { display: block; max-width: 38ch; padding-top: 30px; }
.sec-side .scene-art { display: none !important; }
.sec-side p { margin: 0; }

/* Hero: headline on the left, the three steps as a quiet list on the right */
.hero-intro { gap: var(--sp-5); align-items: end; margin-bottom: var(--sp-4); }
.how-steps { border: none; border-top: 1px solid var(--hair); border-radius: 0; }
.how-steps li, .how-steps li:last-child { border-bottom: 1px solid var(--hair); }
.how-steps a { padding: 14px 0; }
.how-steps a:hover { background: none; }
.how-steps a:hover b { color: var(--accent); }
.how-steps a::after { border: none; width: auto; font-size: 11px; }
.hero-main-grid { gap: 20px; }
.advice-col { padding: var(--sp-3); }

/* No boxes inside boxes: inner items sit on hairlines instead */
.opt-item,
.bio-drv-pill,
.slider-box {
  background: none !important;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}
.opt-item { border-top: 1px solid var(--hair) !important; padding: 12px 0 4px; }
.slider-box { padding: 0; }
.bio-drv-pill { border-left: 1px solid var(--hair) !important; padding: 2px 0 2px 12px; }
#bio-age-delta-badge { border: none; padding: 0; }
.bio-vs-divider { border: none; background: none; }

/* One drawing per card, and no internal codes like MET-01 */
.card-art .scene-obj ~ .scene-obj,
.card-art-ground { display: none; }
.stat-code { display: none; }
.hero-metrics-strip .stat .stat-top { justify-content: flex-end; }
.targets-head { margin-top: var(--sp-5); }
.targets-lead { max-width: 70ch; color: var(--dim); }

/* Learn: the topic grid and Topics menu already list every page, so the
   duplicate scrolling chip row goes */
.rs-libtabs { display: none !important; }

/* Drawers and footnotes: a single quiet line */
.tool-drawer { border-radius: var(--radius); }
.tool-drawer-summary { padding: 14px var(--sp-3); }

@media (max-width: 760px) {
  .sec { padding: 80px 0 var(--sp-3); }
  .sec-title { gap: var(--sp-2); margin-bottom: var(--sp-3); }
  .hero-intro { gap: var(--sp-3); }
  /* On phones the form and score read as open lists, not framed boxes */
  #profile-inputs.control-panel,
  #bio-age-card {
    border: none !important;
    border-top: 1px solid var(--hair) !important;
    border-radius: 0;
    background: none;
    padding-inline: 0;
  }
  .advice-col { padding: 18px; }
  .sec-side { padding-top: 0; }
  .targets-head { margin-top: var(--sp-4); }
}
@media (max-width: 560px) {
  /* Top bar: keep the number, drop the side note that got cut off */
  .bio-live-side { display: none; }
}
