/* =============================================================
   Personality Evaluation — "calibrated instrument" design system
   Cool light UI, deep-navy hero, indigo brand, five domain hues
   for the data. Clean, precise, trustworthy.
   ============================================================= */

/* ---------- tokens ---------- */
:root {
  --bg:        #f4f6fa;
  --surface:   #ffffff;
  --surface-2: #eef1f7;
  --navy:      #0f1320;
  --navy-2:    #161b2e;

  --ink:       #151a25;
  --ink-soft:  #39414f;
  --muted:     #69717f;
  --faint:     #98a1b1;
  --border:    #e3e7ef;
  --border-2:  #d1d7e4;

  --brand:     #4338ca;
  --brand-2:   #3730a3;
  --brand-soft:#ececfb;

  /* Big Five domain hues */
  --o: #7c5cff;  --c: #2f6df0;  --e: #ef8a2a;  --a: #1fa971;  --n: #e4566e;

  --good:  #1fa971;
  --warn:  #d98a1f;

  --font-display: 'Sora', system-ui, sans-serif;
  --font-body:    'Inter', system-ui, -apple-system, sans-serif;
  --font-mono:    'IBM Plex Mono', ui-monospace, Menlo, monospace;

  --radius-1: 8px;
  --radius-2: 14px;
  --radius-pill: 999px;
  --ease: cubic-bezier(.2,.7,.2,1);
  --transition: 200ms var(--ease);
  --container: 1140px;
  --measure: 720px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink-soft);
  font-family: var(--font-body); font-size: 16.5px; line-height: 1.62;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--brand); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--brand-2); }

h1,h2,h3,h4 { font-family: var(--font-display); font-weight: 600; color: var(--ink);
  letter-spacing: -0.02em; line-height: 1.14; margin: 0 0 0.5em; }
h1 { font-size: clamp(2.3rem, 5vw, 3.7rem); font-weight: 700; letter-spacing: -0.03em; }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1.05em; }
strong { color: var(--ink); font-weight: 600; }
.muted { color: var(--muted); }
::selection { background: var(--brand); color: #fff; }

/* ---------- layout ---------- */
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }
.container--narrow { max-width: 840px; }
.section { padding: clamp(52px, 8vw, 104px) 0; position: relative; }
.section--tight { padding: clamp(36px, 5vw, 64px) 0; }
.section--surface { background: var(--surface); }
.section--soft { background: var(--surface-2); }
.section__header { max-width: var(--measure); margin-bottom: clamp(32px,5vw,52px); }
.section__header.is-center { margin: 0 auto clamp(32px,5vw,52px); text-align: center; }
.section__header p { color: var(--muted); font-size: 1.1rem; margin-bottom: 0; }

.eyebrow {
  font-family: var(--font-mono); font-size: 0.73rem; font-weight: 500;
  letter-spacing: 0.2em; text-transform: uppercase; color: var(--brand);
  display: inline-flex; align-items: center; gap: 10px; margin-bottom: 16px;
}
.eyebrow::before { content: ''; width: 22px; height: 2px; background: var(--brand); border-radius: 2px; }
.is-center .eyebrow { justify-content: center; }

.visually-hidden, .skip-link { position: absolute; left: -9999px; }
.skip-link:focus { position: fixed; left: 16px; top: 16px; z-index: 9999; background: var(--brand);
  color: #fff; padding: 10px 16px; font-family: var(--font-mono); border-radius: var(--radius-1); }

/* ---------- header / nav ---------- */
.site-header { position: sticky; top: 0; z-index: 50; backdrop-filter: blur(10px);
  background: rgba(244,246,250,0.85); border-bottom: 1px solid var(--border); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between;
  padding: 14px 0; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand__mark { color: var(--ink); display: inline-flex; }
.brand__word { font-family: var(--font-display); font-weight: 700; font-size: 1.12rem; letter-spacing: -0.02em; }
.brand__word-em { color: var(--brand); }
.site-nav__list { display: flex; align-items: center; gap: 24px; list-style: none; margin: 0; padding: 0; }
.site-nav__list > li > a { color: var(--ink-soft); font-size: 0.93rem; font-weight: 500; position: relative; padding: 4px 0; }
.site-nav__list > li > a:hover { color: var(--brand); }
.site-nav__list > li > a.is-active { color: var(--brand); }
.site-nav__list > li > a.is-active::after { content: ''; position: absolute; left: 0; right: 0; bottom: -3px; height: 2px; background: var(--brand); border-radius: 2px; }
.site-nav__cta { margin-left: 6px; }
.site-nav__toggle { display: none; width: 40px; height: 40px; background: transparent;
  border: 1px solid var(--border-2); border-radius: var(--radius-1); flex-direction: column;
  align-items: center; justify-content: center; gap: 4px; cursor: pointer; }
.site-nav__toggle-bar { width: 18px; height: 2px; background: var(--ink); border-radius: 2px; }
@media (max-width: 940px) {
  .site-nav__toggle { display: inline-flex; }
  .site-nav__list { position: fixed; inset: 0; top: 63px; background: var(--bg); flex-direction: column;
    align-items: flex-start; padding: 30px 28px; gap: 6px; border-top: 1px solid var(--border);
    transform: translateY(-110%); visibility: hidden; transition: transform var(--transition), visibility var(--transition); overflow-y: auto; }
  .site-nav.is-open .site-nav__list { transform: translateY(0); visibility: visible; }
  .site-nav__list > li { width: 100%; }
  .site-nav__list > li > a { font-family: var(--font-display); font-size: 1.4rem; display: block; padding: 12px 0; border-bottom: 1px solid var(--border); }
  .site-nav__cta { margin: 14px 0 0; }
}

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; gap: 9px; padding: 12px 22px;
  font-family: var(--font-body); font-size: 0.96rem; font-weight: 600; background: transparent;
  color: var(--ink); border: 1px solid var(--border-2); border-radius: var(--radius-pill);
  cursor: pointer; transition: all var(--transition); }
.btn--primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn--primary:hover { background: var(--brand-2); border-color: var(--brand-2); color: #fff; transform: translateY(-1px); box-shadow: 0 10px 24px -12px rgba(67,56,202,0.7); }
.btn--ghost:hover { border-color: var(--brand); color: var(--brand); }
.btn--on-navy { background: #fff; border-color: #fff; color: var(--navy); }
.btn--on-navy:hover { background: #ececfb; color: var(--brand-2); transform: translateY(-1px); }
.btn--lg { padding: 16px 30px; font-size: 1.05rem; }
.btn--block { width: 100%; justify-content: center; }
.btn .arrow { transition: transform var(--transition); }
.btn:hover .arrow { transform: translateX(3px); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; box-shadow: none; }

/* ---------- hero (dark instrument panel) ---------- */
.hero { background: var(--navy) url('/assets/images/hero-bg.jpg') center/cover no-repeat;
  color: rgba(255,255,255,0.78); padding: clamp(56px,9vw,108px) 0 clamp(48px,7vw,92px); position: relative; overflow: hidden; }
.hero::before { content: ''; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background: radial-gradient(120% 120% at 80% 0%, rgba(22,27,46,0.5), rgba(15,19,32,0.82) 68%); }
.hero::after { content: ''; position: absolute; inset: 0; pointer-events: none; z-index: 0;
  background-image: linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
  background-size: 44px 44px; mask-image: radial-gradient(ellipse at 70% 10%, #000 20%, transparent 70%); }
.hero__inner { position: relative; z-index: 1; display: grid; grid-template-columns: 1.05fr 0.95fr; gap: clamp(40px,6vw,72px); align-items: center; }
@media (max-width: 920px) { .hero__inner { grid-template-columns: 1fr; gap: 44px; } }
.hero h1 { color: #fff; }
.hero h1 em { font-style: normal; color: #b9b6f5; }
.hero .eyebrow { color: #b9b6f5; }
.hero .eyebrow::before { background: #b9b6f5; }
.hero__lede { font-size: 1.18rem; color: rgba(255,255,255,0.8); max-width: 540px; margin: 24px 0 0; }
.hero__actions { margin-top: 32px; display: flex; gap: 14px; flex-wrap: wrap; }
.hero__meta { margin-top: 38px; display: flex; gap: 32px; flex-wrap: wrap; font-family: var(--font-mono); font-size: 0.78rem; color: rgba(255,255,255,0.6); }
.hero__meta strong { display: block; color: #fff; font-family: var(--font-body); font-size: 1.5rem; font-weight: 600; margin-bottom: 2px; }

/* ---------- hero dials panel ---------- */
.dials { background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius-2); padding: 26px 28px; backdrop-filter: blur(4px); }
.dials__title { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.16em; text-transform: uppercase; color: rgba(255,255,255,0.55); margin-bottom: 18px; display: flex; justify-content: space-between; }
.dials__row { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.dials__row:last-child { margin-bottom: 0; }
.dials__label { width: 116px; flex: 0 0 auto; font-size: 0.86rem; color: rgba(255,255,255,0.82); }
.dials__track { flex: 1; height: 8px; border-radius: 999px; background: rgba(255,255,255,0.1); position: relative; overflow: hidden; }
.dials__fill { height: 100%; border-radius: 999px; }
.dials__val { width: 38px; flex: 0 0 auto; text-align: right; font-family: var(--font-mono); font-size: 0.8rem; color: rgba(255,255,255,0.7); }

/* ---------- page head ---------- */
.page-head { padding: clamp(30px,4vw,56px) 0 clamp(26px,3vw,42px); border-bottom: 1px solid var(--border); }
.page-head__inner { max-width: 840px; }
.page-head__lede { font-size: 1.16rem; color: var(--ink-soft); margin: 18px 0 0; max-width: var(--measure); }
.crumbs { font-family: var(--font-mono); font-size: 0.73rem; color: var(--faint); margin-bottom: 20px; }
.crumbs a { color: var(--muted); } .crumbs a:hover { color: var(--brand); } .crumbs span { color: var(--ink); }

/* ---------- prose ---------- */
.prose { max-width: var(--measure); }
.prose.is-wide { max-width: 880px; }
.prose > * + * { margin-top: 1.05em; }
.prose h2 { margin-top: 1.7em; margin-bottom: 0.45em; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { margin-top: 1.5em; margin-bottom: 0.35em; color: var(--ink); }
.prose p, .prose li { color: var(--ink-soft); }
.prose a { text-decoration: underline; text-decoration-color: rgba(67,56,202,0.35); text-underline-offset: 2px; }
.prose ul, .prose ol { margin: 0 0 1.05em; padding-left: 0; }
.prose ul { list-style: none; }
.prose ul > li { position: relative; padding-left: 1.6em; margin-bottom: 0.5em; }
.prose ul > li::before { content: ''; position: absolute; left: 0.1em; top: 0.62em; width: 7px; height: 7px; border-radius: 50%; background: var(--brand); opacity: 0.6; }
.prose ol { padding-left: 1.4em; } .prose ol li { margin-bottom: 0.5em; }
.prose ol li::marker { color: var(--brand); font-family: var(--font-mono); font-size: 0.9em; }
.lead { font-size: 1.2rem; color: var(--ink); line-height: 1.5; }

.toc { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-2); padding: 22px 26px; margin-bottom: 38px; }
.toc__label { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
.toc ol { margin: 0; padding-left: 1.3em; columns: 2; column-gap: 34px; }
.toc li { margin-bottom: 7px; } .toc a { color: var(--ink-soft); }
@media (max-width: 600px) { .toc ol { columns: 1; } }

.pullquote { margin: clamp(28px,4vw,44px) 0; padding-left: 26px; border-left: 3px solid var(--brand); }
.pullquote p { font-family: var(--font-display); font-size: clamp(1.3rem,2.4vw,1.7rem); font-weight: 500; color: var(--ink); line-height: 1.32; margin: 0; }
.pullquote cite { display: block; margin-top: 14px; font-family: var(--font-mono); font-style: normal; font-size: 0.78rem; color: var(--muted); }

/* ---------- callouts ---------- */
.callout { border-radius: var(--radius-2); padding: 24px 26px; margin: clamp(26px,4vw,38px) 0; border: 1px solid var(--border); background: var(--surface); }
.callout__label { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; margin-bottom: 9px; }
.callout p:last-child { margin-bottom: 0; }
.callout--note { background: var(--brand-soft); border-color: #d6d6f5; } .callout--note .callout__label { color: var(--brand); }
.callout--caution { background: #fdf3e7; border-color: #f1ddc0; } .callout--caution .callout__label { color: var(--warn); }
.callout--key { background: #eaf6f0; border-color: #c9e7d7; } .callout--key .callout__label { color: var(--good); }

/* ---------- cards ---------- */
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px,1fr)); gap: 18px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-2); padding: 28px 26px; display: flex; flex-direction: column; transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition); }
a.card:hover { transform: translateY(-3px); border-color: var(--border-2); box-shadow: 0 16px 38px -26px rgba(21,26,37,0.4); }
.card__kicker { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.13em; text-transform: uppercase; color: var(--brand); margin-bottom: 11px; }
.card h3 { font-size: 1.22rem; margin-bottom: 9px; }
.card p { color: var(--muted); font-size: 0.96rem; margin-bottom: 0; }
.card__more { margin-top: 16px; font-weight: 600; font-size: 0.92rem; color: var(--brand); display: inline-flex; align-items: center; gap: 6px; }
.card__more::after { content: '→'; transition: transform var(--transition); }
a.card:hover .card__more::after { transform: translateX(4px); }
.card__num { font-family: var(--font-mono); font-size: 0.78rem; color: var(--brand); letter-spacing: 0.1em; margin-bottom: 13px; }

/* ---------- stat grid ---------- */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px,1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radius-2); overflow: hidden; }
.stat-cell { background: var(--surface); padding: 28px 24px; }
.stat-cell__num { font-family: var(--font-display); font-size: clamp(1.9rem,3.5vw,2.6rem); font-weight: 700; color: var(--brand); line-height: 1; letter-spacing: -0.02em; }
.stat-cell__num .unit { font-size: 0.5em; color: var(--muted); }
.stat-cell__label { margin-top: 12px; font-size: 0.94rem; color: var(--ink-soft); }
.stat-cell__src { margin-top: 7px; font-family: var(--font-mono); font-size: 0.71rem; color: var(--faint); }

/* ---------- comparison table ---------- */
.table-wrap { overflow-x: auto; margin: 30px 0; border: 1px solid var(--border); border-radius: var(--radius-2); }
table.compare { width: 100%; border-collapse: collapse; min-width: 640px; font-size: 0.94rem; background: var(--surface); }
table.compare th, table.compare td { text-align: left; padding: 15px 18px; border-bottom: 1px solid var(--border); vertical-align: top; }
table.compare thead th { font-family: var(--font-mono); font-size: 0.71rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); background: var(--surface-2); font-weight: 500; }
table.compare tbody th { font-family: var(--font-display); font-weight: 600; color: var(--ink); font-size: 1rem; white-space: nowrap; }
table.compare tbody tr:last-child th, table.compare tbody tr:last-child td { border-bottom: none; }
table.compare td { color: var(--ink-soft); }
.ok { color: var(--good); font-weight: 600; } .bad { color: var(--n); font-weight: 600; }

/* ---------- consent ---------- */
.consent-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-2); padding: clamp(28px,4vw,44px); max-width: 720px; margin: 0 auto; }
.consent-list { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 14px; }
.consent-list li { display: flex; gap: 13px; align-items: flex-start; }
.consent-list svg { flex: 0 0 auto; color: var(--brand); margin-top: 3px; }
.consent-list strong { display: block; color: var(--ink); }
.consent-list span { color: var(--muted); font-size: 0.95rem; }
.demo-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 22px 0; }
@media (max-width: 560px) { .demo-row { grid-template-columns: 1fr; } }
.field label { display: block; font-family: var(--font-mono); font-size: 0.71rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.field select { width: 100%; background: var(--surface); border: 1px solid var(--border-2); color: var(--ink); padding: 12px 14px; font-family: var(--font-body); font-size: 1rem; border-radius: var(--radius-1); }
.field select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }

/* ---------- TEST UI ---------- */
.testbar { position: sticky; top: 0; z-index: 40; background: rgba(244,246,250,0.92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--border); }
.testbar__inner { display: flex; align-items: center; gap: 16px; padding: 12px 0; }
.testbar__track { flex: 1; height: 6px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.testbar__fill { height: 100%; background: var(--brand); border-radius: 999px; width: 0; transition: width 300ms var(--ease); }
.testbar__count { font-family: var(--font-mono); font-size: 0.8rem; color: var(--muted); white-space: nowrap; }

.quiz { max-width: 680px; margin: 0 auto; }
.q { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-2); padding: 26px 26px; margin-bottom: 14px; scroll-margin-top: 80px; }
.q.is-flagged { border-color: var(--n); box-shadow: 0 0 0 3px rgba(228,86,110,0.12); }
.q__num { font-family: var(--font-mono); font-size: 0.74rem; color: var(--brand); letter-spacing: 0.08em; margin-bottom: 8px; }
.q__num.is-ac { color: var(--warn); }
.q__stem { font-family: var(--font-display); font-size: 1.22rem; font-weight: 500; color: var(--ink); line-height: 1.3; margin-bottom: 18px; }
.q__stem .lead-in { color: var(--muted); font-weight: 400; font-size: 0.92rem; display: block; margin-bottom: 4px; }
.likert { display: grid; grid-template-columns: repeat(5,1fr); gap: 8px; }
.likert__opt { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 6px; padding: 12px 6px; border: 1px solid var(--border-2); border-radius: var(--radius-1); cursor: pointer; transition: all var(--transition); font-size: 0.82rem; color: var(--ink-soft); user-select: none; min-height: 76px; }
.likert__opt input { position: absolute; opacity: 0; width: 0; height: 0; }
.likert__dot { width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--border-2); transition: all var(--transition); }
.likert__opt:hover { border-color: var(--brand); }
.likert__opt:hover .likert__dot { border-color: var(--brand); }
.likert__opt:has(input:checked) { background: var(--brand); border-color: var(--brand); color: #fff; }
.likert__opt:has(input:checked) .likert__dot { background: #fff; border-color: #fff; }
.likert__opt:has(input:focus-visible) { box-shadow: 0 0 0 3px var(--brand-soft); }
@media (max-width: 560px) { .likert__opt { min-height: 64px; font-size: 0.7rem; padding: 10px 3px; } .q__stem { font-size: 1.08rem; } }
.test-actions { display: flex; justify-content: space-between; align-items: center; gap: 14px; margin-top: 22px; }
.test-note { font-family: var(--font-mono); font-size: 0.76rem; color: var(--faint); text-align: center; margin-top: 18px; }

/* ---------- RESULT report ---------- */
.result-head { background: var(--navy) url('/assets/images/hero-bg.jpg') center/cover no-repeat; color: rgba(255,255,255,0.8); padding: clamp(40px,6vw,72px) 0 clamp(36px,5vw,60px); position: relative; }
.result-head::before { content: ''; position: absolute; inset: 0; background: radial-gradient(120% 120% at 80% 0%, rgba(22,27,46,0.55), rgba(15,19,32,0.85) 68%); }
.result-head > .container { position: relative; z-index: 1; }
.result-head h1 { color: #fff; }
.result-head .eyebrow { color: #b9b6f5; } .result-head .eyebrow::before { background: #b9b6f5; }
.result-head__lede { color: rgba(255,255,255,0.78); max-width: 640px; font-size: 1.08rem; }

.domain-block { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-2); padding: clamp(24px,3vw,34px); margin-bottom: 18px; }
.domain-block__head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.domain-block__name { display: flex; align-items: center; gap: 12px; }
.domain-block__name h2 { margin: 0; font-size: 1.5rem; }
.domain-block__alt { font-size: 0.9rem; color: var(--muted); }
.domain-block__pct { font-family: var(--font-display); font-weight: 700; font-size: 2rem; line-height: 1; }
.domain-block__label { font-family: var(--font-mono); font-size: 0.74rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.domain-block__narr { color: var(--ink-soft); margin: 16px 0 0; }
.dot { width: 13px; height: 13px; border-radius: 50%; flex: 0 0 auto; }

/* score bar with CI band */
.scorebar { position: relative; height: 30px; margin: 18px 0 4px; }
.scorebar__track { position: absolute; inset: 11px 0; background: var(--surface-2); border-radius: 999px; }
.scorebar__ci { position: absolute; top: 11px; height: 8px; border-radius: 999px; opacity: 0.3; }
.scorebar__fill { position: absolute; top: 11px; height: 8px; left: 0; border-radius: 999px; opacity: 0.85; }
.scorebar__mark { position: absolute; top: 4px; width: 3px; height: 22px; border-radius: 2px; background: var(--ink); transform: translateX(-1.5px); }
.scorebar__mid { position: absolute; top: 6px; bottom: 6px; left: 50%; width: 1px; background: var(--border-2); }
.scorebar__scale { display: flex; justify-content: space-between; font-family: var(--font-mono); font-size: 0.68rem; color: var(--faint); }

/* facet grid */
.facets { margin-top: 18px; display: grid; gap: 10px; }
.facet { display: grid; grid-template-columns: 150px 1fr 42px; align-items: center; gap: 14px; }
@media (max-width: 560px) { .facet { grid-template-columns: 110px 1fr 36px; gap: 10px; } }
.facet__name { font-size: 0.9rem; color: var(--ink-soft); }
.facet__name abbr { text-decoration: none; border-bottom: 1px dotted var(--faint); cursor: help; }
.facet__bar { position: relative; height: 8px; background: var(--surface-2); border-radius: 999px; overflow: hidden; }
.facet__fill { position: absolute; inset: 0 auto 0 0; border-radius: 999px; }
.facet__pct { font-family: var(--font-mono); font-size: 0.8rem; color: var(--muted); text-align: right; }
.facet-toggle { background: none; border: none; color: var(--brand); font-family: var(--font-body); font-weight: 600; font-size: 0.9rem; cursor: pointer; padding: 6px 0; }

/* bridge card */
.bridge { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-2); padding: clamp(24px,3vw,34px); }
.bridge__type { font-family: var(--font-display); font-weight: 700; font-size: 2.4rem; letter-spacing: 0.04em; color: var(--ink); }
.bridge__dims { display: grid; grid-template-columns: repeat(auto-fit,minmax(120px,1fr)); gap: 12px; margin: 18px 0; }
.bridge__dim { background: var(--surface-2); border-radius: var(--radius-1); padding: 14px; text-align: center; }
.bridge__dim-letter { font-family: var(--font-display); font-weight: 700; font-size: 1.5rem; color: var(--brand); }
.bridge__dim-meta { font-family: var(--font-mono); font-size: 0.7rem; color: var(--muted); margin-top: 4px; }

.result-actions { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }
.share-field { display: flex; gap: 8px; flex: 1; min-width: 240px; }
.share-field input { flex: 1; background: var(--surface); border: 1px solid var(--border-2); border-radius: var(--radius-1); padding: 11px 14px; font-family: var(--font-mono); font-size: 0.85rem; color: var(--ink-soft); }

/* ---------- CTA block ---------- */
.cta-block { background: radial-gradient(120% 140% at 80% 0%, var(--navy-2), var(--navy) 65%); color: rgba(255,255,255,0.82); border-radius: var(--radius-2); padding: clamp(36px,6vw,64px); text-align: center; }
.cta-block h2 { color: #fff; margin-bottom: 12px; }
.cta-block p { max-width: 540px; margin: 0 auto 26px; }
.cta-block__actions { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; }

/* ---------- references ---------- */
.references { margin-top: clamp(44px,7vw,72px); padding-top: 30px; border-top: 1px solid var(--border); }
.references h2 { font-size: 1.25rem; }
.references ol { font-family: var(--font-mono); font-size: 0.8rem; line-height: 1.55; color: var(--muted); padding-left: 1.5em; }
.references li { margin-bottom: 9px; } .references li::marker { color: var(--faint); }

/* ---------- content meta + disclaimer + footer ---------- */
.content-meta { border-top: 1px solid var(--border); background: var(--surface); }
.content-meta__inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 22px; padding: 16px 0; font-family: var(--font-mono); font-size: 0.75rem; color: var(--faint); }
.content-meta a { color: var(--muted); }
.disclaimer-strip { background: var(--surface-2); border-top: 1px solid var(--border); }
.disclaimer-strip__inner { display: flex; align-items: flex-start; gap: 14px; padding: 22px 0; }
.disclaimer-strip svg { color: var(--warn); flex: 0 0 auto; margin-top: 2px; }
.disclaimer-strip p { margin: 0; font-size: 0.92rem; color: var(--muted); max-width: 880px; }

.site-footer { background: var(--navy); color: rgba(255,255,255,0.62); padding-top: 56px; }
.site-footer__inner { display: grid; grid-template-columns: 1.8fr 1fr 1fr 1fr; gap: 38px; padding-bottom: 48px; }
@media (max-width: 860px) { .site-footer__inner { grid-template-columns: 1fr 1fr; gap: 30px; } }
@media (max-width: 520px) { .site-footer__inner { grid-template-columns: 1fr; } }
.site-footer .brand__word { font-size: 1.25rem; color: #fff; }
.site-footer .brand__word-em { color: #b9b6f5; }
.site-footer__tag { color: rgba(255,255,255,0.8); margin-top: 8px; font-size: 0.95rem; }
.site-footer__note { color: rgba(255,255,255,0.5); font-size: 0.88rem; margin-top: 12px; max-width: 360px; }
.site-footer h3 { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: rgba(255,255,255,0.55); margin-bottom: 14px; }
.link-list { list-style: none; padding: 0; margin: 0; }
.link-list li { padding: 5px 0; }
.link-list a { color: rgba(255,255,255,0.78); font-size: 0.93rem; }
.link-list a:hover { color: #fff; }
.site-footer__base { border-top: 1px solid rgba(255,255,255,0.12); padding: 20px 0; }
.site-footer__base-inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-family: var(--font-mono); font-size: 0.74rem; color: rgba(255,255,255,0.45); }
.site-footer__base p { margin: 0; }

/* ---------- utility ---------- */
.center { text-align: center; }
.flow > * + * { margin-top: 1.05em; }
.pill { display: inline-block; padding: 4px 12px; font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.06em; border-radius: var(--radius-pill); border: 1px solid var(--border-2); color: var(--muted); }

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