/* ============================================================
   Fitness Experts Alliance guides
   Visual system borrowed from the Balance Protocol GPS site
   ("The Midnight Wellness Lab"): deep ink-green ground, off-white
   type, one luminous jade accent, Sora display + Source Sans 3 body.
   Sized for readers 65+.
   ============================================================ */
@font-face { font-family: 'Sora'; src: url('fonts/sora-latin-wght-normal.woff2') format('woff2'); font-weight: 100 800; font-display: swap; }
@font-face { font-family: 'Source Sans 3'; src: url('fonts/source-sans-3-latin-wght-normal.woff2') format('woff2'); font-weight: 200 900; font-display: swap; }
@font-face { font-family: 'Source Sans 3'; src: url('fonts/source-sans-3-latin-wght-italic.woff2') format('woff2'); font-weight: 200 900; font-style: italic; font-display: swap; }

:root {
  --ink: oklch(20% 0.028 168);
  --ink-deep: oklch(16% 0.026 168);
  --surface: oklch(25.5% 0.032 168);
  --surface-2: oklch(29% 0.034 168);
  --line: oklch(42% 0.022 168 / 0.7);
  --line-soft: oklch(42% 0.022 168 / 0.4);
  --paper: oklch(96.5% 0.012 150);
  --muted: oklch(82% 0.018 160);
  --jade: oklch(82% 0.155 158);
  --jade-ink: oklch(24% 0.07 165);
  --jade-glow: oklch(82% 0.155 158 / 0.30);
  --warn: oklch(83% 0.11 80);
  --fail: oklch(74% 0.13 28);
  --font-display: 'Sora', system-ui, sans-serif;
  --font-body: 'Source Sans 3', 'Segoe UI', Arial, system-ui, sans-serif;
  --radius: 18px;
  --shadow-lift: 0 1px 0 oklch(100% 0 0 / 0.04) inset, 0 18px 50px -28px oklch(0% 0 0 / 0.65);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 20px; -webkit-text-size-adjust: 100%; background: var(--ink); }
body { font-family: var(--font-body); color: var(--paper); background: var(--ink); line-height: 1.6; letter-spacing: 0.005em; font-weight: 420; -webkit-font-smoothing: antialiased; }
a { color: var(--jade); }
.wrap { max-width: 880px; margin: 0 auto; padding: 0 24px; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.02em; text-wrap: balance; line-height: 1.12; }
p { text-wrap: pretty; margin-bottom: 14px; }

/* header */
header.top { border-bottom: 1px solid var(--line-soft); background: var(--ink-deep); }
header.top .wrap { display: flex; align-items: center; gap: 16px; padding-top: 20px; padding-bottom: 18px; }
header.top svg { flex: none; }
.org { font-family: var(--font-display); font-weight: 600; font-size: 1.25rem; line-height: 1.15; letter-spacing: -0.02em; }
.org .acc { color: var(--jade); }
.dir { font-size: 0.95rem; color: var(--muted); margin-top: 3px; }

main.wrap { padding-top: 44px; padding-bottom: 10px; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 500; font-size: 0.9rem; color: var(--jade); margin-bottom: 12px; }
.eyebrow::before { content: ""; width: 26px; height: 2px; background: var(--jade); opacity: .75; }
h1 { font-size: clamp(2rem, 1.6rem + 2vw, 2.9rem); }
.lede { font-size: 1.15rem; color: var(--muted); margin-top: 14px; max-width: 60ch; }
h2 { font-size: 1.55rem; margin: 52px 0 14px; }
h3 { font-size: 1.2rem; margin-bottom: 8px; }
.note { font-size: 0.95rem; color: var(--muted); margin-top: 12px; }
ul.big { padding-left: 1.1em; } ul.big li { margin-bottom: 10px; } ul.big li::marker { color: var(--jade); }
b, strong { font-weight: 700; color: var(--paper); }

.panel, .credit, .pick, .tbl, .chart, .mech .card, .take div { background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius); box-shadow: var(--shadow-lift); }
.credit { margin-top: 26px; padding: 18px 20px; font-size: 0.98rem; color: var(--muted); border-left: 3px solid var(--jade); }
.credit b { color: var(--paper); }

.picks { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.pick { padding: 18px 20px; }
.pick .lab { font-family: var(--font-display); font-size: 0.85rem; font-weight: 500; color: var(--muted); }
.pick.germ { box-shadow: 0 0 0 1px oklch(82% 0.155 158 / 0.35), 0 14px 44px -20px var(--jade-glow); }
.pick.germ .lab { color: var(--jade); }
.pick .name { font-weight: 700; font-size: 1.08rem; margin: 6px 0 8px; line-height: 1.3; }
.pick .score { font-family: var(--font-display); font-size: 2.1rem; font-weight: 600; line-height: 1.05; color: var(--jade); }
.pick .score small { font-family: var(--font-body); font-size: 1rem; color: var(--muted); font-weight: 400; }
.pick .note { margin-top: 6px; }

.tbl { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; font-size: 1rem; }
th { text-align: left; padding: 12px 14px; font-family: var(--font-display); font-weight: 500; font-size: 0.88rem; color: var(--muted); background: var(--surface-2); white-space: nowrap; }
td { padding: 11px 14px; border-top: 1px solid var(--line-soft); vertical-align: top; }
.n { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.rk { color: var(--muted); width: 2em; }
.ok { color: var(--jade); font-weight: 700; } .mid { color: var(--warn); font-weight: 700; } .bad { color: var(--fail); font-weight: 700; }
.pill { display: inline-block; padding: 3px 13px; border-radius: 999px; font-size: 0.88rem; font-weight: 700; white-space: nowrap; }
.pill.ok { background: var(--jade); color: var(--jade-ink); }
.pill.mid { background: oklch(83% 0.11 80 / 0.16); color: var(--warn); box-shadow: inset 0 0 0 1px oklch(83% 0.11 80 / 0.5); }
.pill.bad { background: oklch(74% 0.13 28 / 0.16); color: var(--fail); box-shadow: inset 0 0 0 1px oklch(74% 0.13 28 / 0.55); }

.callout { margin: 26px 0 6px; padding: 20px 22px; border-radius: var(--radius); background: linear-gradient(180deg, oklch(82% 0.155 158 / 0.10), oklch(82% 0.155 158 / 0.04)); box-shadow: inset 0 0 0 1px oklch(82% 0.155 158 / 0.35); font-size: 1.1rem; }
.callout b:first-child { color: var(--jade); }

.take { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 14px; }
.take div { padding: 16px 18px; color: var(--muted); }
.take b { display: block; color: var(--paper); font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; margin-bottom: 4px; }

/* size chart */
.chart { padding: 20px 20px 14px; }
.row { margin-bottom: 18px; }
.row .lbl { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.row .lbl b { font-size: 1.05rem; }
.row .lbl span { color: var(--muted); }
.track { position: relative; height: 26px; border-radius: 8px; margin-top: 5px; background: linear-gradient(90deg, oklch(83% 0.11 80 / 0.10) 0 33.3%, oklch(82% 0.155 158 / 0.10) 33.3% 100%); }
.track i { position: absolute; top: 4px; bottom: 4px; border-radius: 10px; }
.track::after { content: ''; position: absolute; left: 33.3%; top: -5px; bottom: -5px; border-left: 2px dashed var(--paper); opacity: .8; }
.axis { position: relative; height: 26px; font-size: 0.85rem; color: var(--muted); }
.axis span { position: absolute; transform: translateX(-50%); white-space: nowrap; }
.axis span:first-child { transform: none; } .axis span:last-child { transform: translateX(-100%); }
.legend { display: flex; gap: 18px; flex-wrap: wrap; font-size: 0.95rem; color: var(--muted); margin-top: 8px; }
.legend span::before { content: ''; display: inline-block; width: 16px; height: 16px; border-radius: 4px; vertical-align: -2px; margin-right: 7px; }
.legend .l1::before { background: oklch(83% 0.11 80 / 0.25); box-shadow: inset 0 0 0 1px var(--warn); }
.legend .l2::before { background: oklch(82% 0.155 158 / 0.25); box-shadow: inset 0 0 0 1px var(--jade); }
.legend .l3::before { border-left: 2px dashed var(--paper); width: 0; border-radius: 0; }

.mech { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; }
.mech .card { padding: 16px 18px; }
.mech .card p { color: var(--muted); }
.mech svg { width: 100%; height: auto; display: block; margin-bottom: 10px; }

.logs { display: grid; grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); gap: 10px; margin-top: 10px; }
.logs div { border-radius: 14px; padding: 14px 8px; text-align: center; font-size: 0.95rem; color: var(--muted); background: var(--surface); border: 1px solid var(--line-soft); }
.logs b { display: block; font-family: var(--font-display); font-weight: 600; font-size: 1.5rem; line-height: 1.2; }
.logs .r b { color: var(--fail); } .logs .a b { color: var(--warn); }
.logs .g { box-shadow: 0 0 0 1px oklch(82% 0.155 158 / 0.45), 0 12px 36px -18px var(--jade-glow); } .logs .g b { color: var(--jade); }
.std { margin-top: 14px; color: var(--muted); }

.btn { display: inline-flex; align-items: center; gap: 10px; background: var(--jade); color: var(--jade-ink); font-family: var(--font-display); font-weight: 600; text-decoration: none; padding: 14px 26px; border-radius: 999px; min-height: 52px; box-shadow: 0 0 0 1px oklch(82% 0.155 158 / 0.25), 0 14px 44px -16px var(--jade-glow); margin-top: 10px; }

/* home cards */
a.card { display: block; text-decoration: none; color: var(--paper); padding: 20px 22px; margin-bottom: 14px; background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius); box-shadow: var(--shadow-lift); }
a.card b { font-family: var(--font-display); font-weight: 600; font-size: 1.15rem; display: block; }
a.card span { color: var(--muted); display: block; margin-top: 4px; }
a.card:hover { box-shadow: 0 0 0 1px oklch(82% 0.155 158 / 0.4), var(--shadow-lift); }

footer.bot { border-top: 1px solid var(--line-soft); background: var(--ink-deep); color: var(--muted); margin-top: 52px; font-size: 0.95rem; }
footer.bot .wrap { padding-top: 22px; padding-bottom: 28px; }
footer.bot b { color: var(--paper); }

@media (max-width: 600px) {
  html { font-size: 18px; }
  .hide-sm { display: none; }
  th, td { padding: 9px 10px; }
  .stack, .stack tbody, .stack tr, .stack td { display: block; width: 100%; }
  .stack tr:first-child { display: none; }
  .stack tr { border-top: 1px solid var(--line-soft); padding: 10px 4px; }
  .stack tr:first-child + tr { border-top: 0; }
  .stack td { border: 0; padding: 3px 12px; text-align: left; display: flex; justify-content: space-between; gap: 10px; }
  .stack td:first-child { font-size: 1.1rem; }
  .stack td[data-label]:not([data-label=""])::before { content: attr(data-label); color: var(--muted); font-weight: 400; }
  .stack td.hide-sm { display: flex; }
  .stack td:empty { display: none; }
  .axis span:first-child, .axis span:last-child { display: none; }
}

@media print {
  @page { size: Letter; margin: 0; }
  body { padding: 0 0.6in; }
  table.pw { width: 100%; border-collapse: collapse; table-layout: fixed; }
  table.pw > thead td { height: 0.5in; padding: 0; border: 0; }
  table.pw > tfoot td { height: 0.62in; padding: 0; border: 0; vertical-align: middle; font-size: 9pt; color: var(--muted); }
  table.pw > tbody > tr > td { padding: 0; border: 0; }
  table.pw > tfoot .pf { display: flex; justify-content: space-between; border-top: 1px solid var(--line-soft); padding-top: 8px; }
  * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  html { font-size: 13.5pt; }
  .wrap { max-width: none; padding: 0; }
  header.top { background: transparent; }
  header.top .wrap { padding: 0 0 14px; }
  main.wrap { padding-top: 0; padding-bottom: 0; }
  h1 { font-size: 1.9rem; }
  h2 { margin-top: 28px; break-after: avoid; }
  h3 { break-after: avoid; }
  .panel, .credit, .pick, .tbl, .chart, .mech .card, .take div, .logs div { box-shadow: none; }
  .tbl { overflow: visible; }
  .pick, .take div, .row, .mech .card, .logs, .callout, tr, .chart { break-inside: avoid; }
  .picks, .take, .mech { display: flex; flex-wrap: wrap; }
  .picks .pick { width: calc(50% - 7px); }
  .take div { width: calc(50% - 7px); }
  .mech .card { width: calc(50% - 8px); }
  .mech .card p { font-size: 0.92rem; }
  .logs { display: flex; } .logs div { flex: 1; padding: 10px 4px; } .logs b { font-size: 1.2rem; }
  .pgbreak { break-before: page; }
  .noprint, footer.bot { display: none; }
}
