/* MyoMed Prep — shared brand tokens and chrome.
   Canonical: shared/brand/myomed-brand.css
   Copied into each app so independently deployed sites stay one family.
   Inter is self-hosted (../fonts/, SIL OFL 1.1) — no third-party font CDN. */

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/InterVariable.woff2?v=s2610") format("woff2");
}
@font-face {
  font-family: "Inter";
  font-style: italic;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/InterVariable-Italic.woff2?v=s2610") format("woff2");
}

:root {
  --navy: #12303f;
  --navy-2: #1c4759;
  --teal: #0e7c86;
  --teal-hover: #0b6a73;
  --teal-light: #e3f2f3;
  --accent: #f0a441;
  --accent-ink: #3a2a08;
  --ink: #211d1a;
  --muted: #6b6259;  /* >= 4.5:1 on --surface-2 as well as --card */
  --line: #e7e1da;
  --bg: #faf8f6;
  --card: #ffffff;
  --heading: #1b1714;
  --on-navy: #ffffff;
  --on-teal: #ffffff;
  /* Chrome (top bar, sidebar, footer) follows the page: white in light, obsidian
     in dark. --chrome-ink/-muted/-line are the text/border on that surface. */
  --chrome-ink: #1b1714;
  --chrome-muted: #6b6259;
  --chrome-line: #e7e1da;
  --nav-link: #4a423c;
  --footer-muted: #6b6259;
  --footer-legal: #6b6259;
  /* Score / status colours. Navy and teal stay brand; these are reserved for
     correct / partial / incorrect and system state so a score never reads as
     a brand chip. */
  --good: #1b7f5a;
  --good-bg: #e6f4ee;
  --warn: #b86e00;
  --warn-bg: #fdf3e3;
  --bad: #b42318;
  --bad-bg: #fdecea;
  --info: #0e7c86;
  --info-bg: #e3f2f3;
  --surface-1: #f4efe9;
  --surface-2: #f2ede7;
  --surface-3: #e7e1da;
  /* Text-on-tint inks and component surfaces. They exist so dark mode can
     re-map them in one place (myomed-dark.css) instead of per component. */
  --heading-2: #3a332c;
  --pill-ink: #0b6a73;
  --pill-warn-ink: #8a5200;
  --good-ink: #166a4b;
  --gold-bg: #fdf3e3;
  --gold-ink: #7a5410;
  --highlight-bg: #fff3cd;
  --input-bg: #ffffff;
  --panel-bg: #ffffff;
  --panel-ink: #1b1714;
  --panel-hover: #f0ebe4;
  --panel-ring: var(--product-accent);
  /* Product accent (direction B): one identity colour per product, defaulting to
     the corporate teal. Each app overrides --product-accent; soft/strong derive
     from it so pills and tinted text stay readable in both themes. */
  --product-accent: var(--teal);
  --product-accent-ink: var(--on-teal);
  --product-accent-soft: color-mix(in srgb, var(--product-accent) 14%, var(--card));
  --product-accent-strong: color-mix(in srgb, var(--product-accent) 78%, var(--heading));
  /* Dark surfaces (hero) read as dark in both themes; the chrome follows the page. */
  --chrome-bg: #faf8f6;
  --hero-from: var(--navy);
  --hero-mid: var(--navy-2);
  --hero-to: var(--teal);
  color-scheme: light;

  /* Radii scale. --radius / --radius-sm are the legacy names; keep them. */
  --radius-xs: 4px;
  --radius-sm: 8px;
  --radius: 12px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  /* Cards and stat tiles share one radius, a touch rounder than --radius. */
  --radius-card: 14px;
  --radius-pill: 999px;

  /* Elevation. Layered, low-alpha navy so it reads as depth, not dirt.
     --shadow / --shadow-lg are the legacy names and alias the middle steps. */
  --elev-0: none;
  --elev-1: 0 1px 2px rgba(18, 48, 63, 0.08), 0 1px 1px rgba(18, 48, 63, 0.04);
  --elev-2: 0 1px 3px rgba(18, 48, 63, 0.10), 0 4px 14px rgba(18, 48, 63, 0.06);
  --elev-3: 0 2px 6px rgba(18, 48, 63, 0.10), 0 10px 28px rgba(18, 48, 63, 0.12);
  --elev-4: 0 6px 16px rgba(18, 48, 63, 0.14), 0 24px 56px rgba(18, 48, 63, 0.18);
  --shadow: var(--elev-2);
  --shadow-lg: var(--elev-3);

  /* Spacing scale, 4px base. */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;

  /* Type. Fluid steps (minor third at 320px → major third at 1280px). */
  --max: 1120px;
  --max-narrow: 760px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-md: clamp(1.05rem, 1rem + 0.25vw, 1.125rem);
  --text-lg: 1.125rem;
  --text-xl: 1.25rem;
  --text-2xl: 1.5rem;
  --text-3xl: 1.875rem;
  --text-4xl: 2.25rem;
  --font-normal: 400;
  --font-medium: 500;
  --font-semibold: 600;
  --font-bold: 700;
  --leading-tight: 1.25;
  --leading-normal: 1.5;
  --leading-relaxed: 1.75;
  --leading-snug: 1.3;
  --leading-body: 1.55;
  --tracking-tight: -0.015em;
  --tracking-caps: 0.06em;

  /* Motion. One duration set, one easing set; reduced-motion zeroes them. */
  --dur-fast: 120ms;
  --dur-base: 200ms;
  --dur-slow: 320ms;
  --ease-out: cubic-bezier(0.2, 0.8, 0.2, 1);
  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Focus ring — one look everywhere, never removed. */
  --ring: 0 0 0 3px color-mix(in srgb, var(--product-accent) 35%, transparent);
  --ring-on-dark: 0 0 0 3px rgba(255, 255, 255, 0.45);
  /* Synapsis AI — coach brand (child of MyoMed Prep, not a second company).
     Fuchsia accent (#a21caf light / #e879f9 dark), its own colour since Oct 2026.
     --syn-accent / --syn-glow sit on the charcoal coach chrome; --syn-ink is
     Synapsis text on the page and flips with the theme. */
  --syn-charcoal: #1f1724;
  --syn-silver: #c5d0d8;
  --syn-accent: #a21caf;
  --syn-glow: #e879f9;
  --syn-ink: #a21caf;
  --syn-on-ink: #ffffff;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-feature-settings: "kern" 1, "liga" 1, "calt" 1, "cv11" 1;
}
h1, h2, h3, h4 {
  letter-spacing: var(--tracking-tight);
  line-height: var(--leading-tight);
  text-wrap: balance;
}
h1 { font-size: var(--text-3xl); font-weight: 800; }
h2 { font-size: var(--text-2xl); font-weight: 800; }
h3 { font-size: var(--text-xl); font-weight: 700; }
h4 { font-size: var(--text-md); font-weight: 700; }
p, li { text-wrap: pretty; }
p { font-size: var(--text-base); line-height: var(--leading-normal); }
caption, figcaption, .caption { font-size: var(--text-sm); color: var(--color-text-secondary, var(--muted)); }
nav a { font-size: var(--text-sm); font-weight: var(--font-medium); }
button, .btn { font-size: var(--text-sm); font-weight: var(--font-semibold); }
code, kbd, samp, pre { font-size: var(--text-sm); font-family: var(--font-mono, 'JetBrains Mono', monospace); }
@media (max-width: 640px) {
  h1 { font-size: var(--text-2xl); }
  h2 { font-size: var(--text-xl); }
  h3 { font-size: var(--text-lg); }
}
.tabular { font-variant-numeric: tabular-nums; }

:focus-visible { outline: 2px solid var(--product-accent); outline-offset: 2px; }
.btn:focus-visible,
.card.clickable:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible { outline: none; box-shadow: var(--ring); }

/* ---------- Sticky topbar / brand / network ---------- */
.topbar {
  background: var(--chrome-bg);
  color: var(--chrome-ink);
  border-bottom: 1px solid var(--chrome-line);
  position: sticky;
  top: 0;
  z-index: 200;
  box-shadow: var(--shadow);
}
.topbar-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0.65rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.85rem;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--chrome-ink);
  font-weight: 800;
  font-size: var(--text-lg);
  flex-shrink: 0;
}
.brand-mark {
  background: var(--product-accent);
  width: 36px;
  height: 36px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: var(--text-lg);
  color: var(--on-teal);
}
/* The lockup is a transparent PNG, so it needs no plate: a radius and a box
   shadow would draw the corners of a rectangle that is not there. */
.brand-banner {
  height: 48px;
  width: auto;
  max-width: 220px;
  object-fit: contain;
}
.brand-text { font-weight: 800; line-height: 1.15; }
.brand-text small {
  display: block;
  font-size: var(--text-xs);
  font-weight: 500;
  color: var(--chrome-muted);
  letter-spacing: 0.04em;
}

.nav-toggle {
  display: none;
  margin-left: auto;
  background: transparent;
  color: var(--chrome-ink);
  border: 1px solid var(--chrome-line);
  border-radius: var(--radius-sm);
  padding: 0.4rem 0.75rem;
  font-weight: 700;
  font-size: var(--text-sm);
  cursor: pointer;
}
.nav-toggle:hover,
.nav-toggle[aria-expanded="true"] {
  background: color-mix(in srgb, var(--chrome-ink) 10%, transparent);
  color: var(--chrome-ink);
}

nav.main,
.main-nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.15rem;
  flex-wrap: wrap;
}
nav.main a,
.main-nav a,
nav.main .nav-more > summary {
  color: var(--chrome-ink);
  text-decoration: none;
  padding: 0.42rem 0.7rem;
  border-radius: 7px;
  font-size: var(--text-base);
  background: transparent;
  border: 0;
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}
nav.main a:hover,
.main-nav a:hover,
nav.main .nav-more > summary:hover,
nav.main a:focus-visible,
.main-nav a:focus-visible,
nav.main .nav-more > summary:focus-visible {
  background: color-mix(in srgb, var(--chrome-ink) 12%, transparent);
  color: var(--chrome-ink);
  outline: 2px solid var(--product-accent);
  outline-offset: 2px;
}
nav.main a.active,
.main-nav a.active,
nav.main .nav-more.has-active > summary {
  background: var(--product-accent);
  color: var(--product-accent-ink);
}
nav.main a.nav-cta {
  background: var(--accent);
  color: var(--accent-ink);
  font-weight: 800;
  margin-left: 0.25rem;
}
nav.main a.nav-cta:hover { filter: brightness(1.05); color: var(--accent-ink); }

.nav-more { position: relative; z-index: 1; }
.nav-more[open] { z-index: 400; }
.nav-more > summary::-webkit-details-marker { display: none; }
.nav-more:not([open]) .nav-more-panel { display: none; }
.nav-more-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  min-width: 200px;
  background: var(--panel-bg);
  color: var(--panel-ink);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 0.4rem;
  z-index: 400;
}
/* White panel: never inherit pale --nav-link (#e8f2f5) from the navy bar.
   Inactive items stay navy-on-white; hover/focus keep the same ink. */
nav.main .nav-more-panel a,
nav.main .nav-more-panel a:link,
nav.main .nav-more-panel a:visited,
nav.main .nav-more-panel a:not(.active),
.main-nav .nav-more-panel a,
.main-nav .nav-more-panel a:link,
.main-nav .nav-more-panel a:visited,
.main-nav .nav-more-panel a:not(.active) {
  display: block;
  color: var(--panel-ink);
  background: transparent;
  padding: 0.5rem 0.7rem;
  border-radius: 7px;
  font-weight: 700;
}
nav.main .nav-more-panel a:hover,
nav.main .nav-more-panel a:focus,
nav.main .nav-more-panel a:focus-visible,
.main-nav .nav-more-panel a:hover,
.main-nav .nav-more-panel a:focus,
.main-nav .nav-more-panel a:focus-visible {
  background: var(--panel-hover);
  color: var(--panel-ink);
  outline: 2px solid var(--panel-ring);
  outline-offset: 1px;
}
nav.main .nav-more-panel a.active,
.main-nav .nav-more-panel a.active {
  background: var(--panel-hover);
  color: var(--panel-ink);
  font-weight: 800;
}

.network-links {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  flex-wrap: wrap;
}
.network-links a {
  color: var(--chrome-muted);
  text-decoration: none;
  font-size: var(--text-sm);
  font-weight: 600;
  padding: 0.3rem 0.55rem;
  border-radius: 7px;
}
.network-links a:hover { background: color-mix(in srgb, var(--chrome-ink) 10%, transparent); color: var(--chrome-ink); }
.network-links a.here { color: var(--chrome-ink); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  border-radius: 9px;
  padding: 0.65rem 1.2rem;
  font-weight: 700;
  text-decoration: none;
  font-size: var(--text-base);
  border: 1px solid transparent;
  cursor: pointer;
  font-family: inherit;
  line-height: 1.25;
  transition:
    background-color var(--dur-fast) var(--ease-out),
    border-color var(--dur-fast) var(--ease-out),
    color var(--dur-fast) var(--ease-out),
    box-shadow var(--dur-fast) var(--ease-out),
    transform var(--dur-fast) var(--ease-out);
}
.btn:active { transform: translateY(1px); }
.btn[disabled],
.btn[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; pointer-events: none; }
.btn-primary { background: var(--accent); color: var(--accent-ink); box-shadow: var(--elev-1); }
.btn-primary:hover { filter: brightness(1.05); box-shadow: var(--elev-2); }
.btn-teal { background: var(--teal); color: var(--on-teal); box-shadow: var(--elev-1); }
.btn-teal:hover { background: var(--teal-hover); box-shadow: var(--elev-2); }
.btn-secondary {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.4);
}
.btn-secondary:hover { background: rgba(255, 255, 255, 0.2); }
.btn-outline { background: var(--card); border-color: var(--line); color: var(--heading); }
.btn-outline:hover { border-color: var(--teal); color: var(--teal); }
.btn-ghost {
  background: transparent;
  color: var(--nav-link);
  border-color: rgba(255, 255, 255, 0.25);
}
.btn-ghost:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }
.btn-lg { padding: 0.75rem 1.35rem; font-size: var(--text-base); }
.btn-sm { padding: 0.4rem 0.8rem; font-size: var(--text-sm); border-radius: 7px; }
.btn-quiet { background: transparent; color: var(--teal); border-color: transparent; }
.btn-quiet:hover { background: var(--teal-light); }
.btn-block { display: flex; width: 100%; }

/* ---------- Cards / grid / pills ---------- */
.grid { display: grid; gap: 1.1rem; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
/* One card look platform-wide: a soft 1px border, a light resting shadow that
   deepens and lifts on hover, and one radius token. A card may be a <div> or an
   <a class="card"> (keyboard-operable tiles), so neutral ink and no underline are
   part of the base rule — an anchor card must read as a card, not a link. */
.card {
  position: relative;
  background: var(--card);
  color: inherit;
  border: 1px solid var(--line);
  border-top: 3px solid var(--product-accent);
  border-radius: var(--radius-card);
  padding: 1.35rem 1.45rem;
  box-shadow: var(--elev-1);
  text-decoration: none;
}
.card h3 { margin-top: 0; }
.card.clickable {
  cursor: pointer;
  transition:
    transform var(--dur-base) var(--ease-out),
    border-color var(--dur-base) var(--ease-out),
    box-shadow var(--dur-base) var(--ease-out);
}
.card.clickable:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--teal) 60%, var(--line));
  box-shadow: var(--elev-3);
}
.card-flat { box-shadow: none; }
.card-raised { box-shadow: var(--elev-3); border-color: transparent; }
.card-tight { padding: 0.9rem 1rem; }
.card-accent { border-top: 3px solid var(--product-accent); }
.card-gold { border-top: 3px solid var(--accent); }
/* Optional media well and header row so cards with an image or a chip read the
   same across apps. The media well bleeds to the card's edges. */
.card-media {
  margin: -1.35rem -1.45rem 1rem;
  border-radius: calc(var(--radius-card) - 1px) calc(var(--radius-card) - 1px) 0 0;
  overflow: hidden;
  background: var(--surface-2);
}
.card-media img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
.card-head { display: flex; align-items: center; gap: 0.55rem; flex-wrap: wrap; margin-bottom: 0.5rem; }

.pill {
  display: inline-block;
  background: var(--product-accent-soft);
  color: var(--product-accent-strong);
  font-size: var(--text-xs);
  font-weight: 700;
  padding: 0.18rem 0.65rem;
  border-radius: 999px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1.5;
}
.pill.gold { background: var(--gold-bg); color: var(--gold-ink); }
.pill.good { background: var(--good-bg); color: var(--good-ink); }
.pill.warn { background: var(--warn-bg); color: var(--pill-warn-ink); }
.pill.bad { background: var(--bad-bg); color: var(--bad); }
.pill.neutral { background: var(--surface-2); color: var(--muted); }

/* ---------- Text primitives ---------- */
.eyebrow {
  display: block;
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: var(--tracking-caps);
  text-transform: uppercase;
  color: var(--product-accent-strong);
  margin-bottom: 0.35rem;
}
.lede { font-size: var(--text-md); color: var(--muted); max-width: 62ch; }
.muted { color: var(--muted); }
.kbd {
  font-family: var(--font-mono);
  font-size: calc(var(--text-base) * 0.8);
  padding: 0.1em 0.4em;
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: var(--radius-xs);
  background: var(--surface-2);
}
.divider { border: 0; border-top: 1px solid var(--line); margin: var(--space-6) 0; }

/* ---------- Stats ---------- */
.stat-row { display: grid; gap: 0.9rem; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.stat {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 1rem 1.1rem;
  box-shadow: var(--elev-1);
}
.stat .num {
  font-size: var(--text-2xl);
  font-weight: 800;
  color: var(--product-accent-strong);
  line-height: 1.05;
  font-variant-numeric: tabular-nums;
  letter-spacing: var(--tracking-tight);
}
.stat .lbl { color: var(--muted); font-size: var(--text-sm); margin-top: 0.25rem; }

/* ---------- Progress ---------- */
.progress-track {
  height: 8px;
  background: var(--surface-2);
  border-radius: var(--radius-pill);
  overflow: hidden;
}
.progress-fill {
  height: 100%;
  background: var(--product-accent);
  border-radius: var(--radius-pill);
  transition: width var(--dur-slow) var(--ease-out);
}
.progress-fill.good { background: var(--good); }
.progress-fill.warn { background: var(--warn); }
.progress-fill.bad { background: var(--bad); }

/* ---------- Skeletons (loading) ---------- */
.skeleton {
  position: relative;
  overflow: hidden;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
  color: transparent !important;
  min-height: 1em;
}
.skeleton::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.55), transparent);
  animation: skeleton-sweep 1.4s var(--ease-in-out) infinite;
}
@keyframes skeleton-sweep { to { transform: translateX(100%); } }
.skeleton-text { height: 0.9em; margin: 0.35em 0; width: 100%; }
.skeleton-text.short { width: 55%; }
.skeleton-card { min-height: 120px; border-radius: var(--radius); }

/* ---------- Enter motion ---------- */
@keyframes rise-in {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}
.rise-in { animation: rise-in var(--dur-slow) var(--ease-out) both; }
.stagger > * { animation: rise-in var(--dur-slow) var(--ease-out) both; }
.stagger > *:nth-child(2) { animation-delay: 40ms; }
.stagger > *:nth-child(3) { animation-delay: 80ms; }
.stagger > *:nth-child(4) { animation-delay: 120ms; }
.stagger > *:nth-child(5) { animation-delay: 160ms; }
.stagger > *:nth-child(n + 6) { animation-delay: 200ms; }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(135deg, var(--hero-from), var(--hero-mid) 55%, var(--hero-to));
  color: #fff;
  border-radius: 16px;
  padding: 3rem 2.2rem;
  margin-bottom: 1.6rem;
}
.hero h1 { color: #fff; font-size: var(--text-4xl); margin: 0 0 0.6rem; max-width: 820px; }
.hero p { color: #dcebef; max-width: 700px; font-size: var(--text-lg); }
.hero .actions { margin-top: 1.4rem; display: flex; gap: 0.7rem; flex-wrap: wrap; }
.hero .slogan { color: var(--accent); font-weight: 700; }

/* ---------- Footer ---------- */
footer.site,
.footer {
  background: var(--chrome-bg);
  color: var(--footer-muted);
  margin-top: 3rem;
}
.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 2.2rem 1rem 0.6rem;
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}
.footer-inner-slim {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  padding-bottom: 1.2rem;
}
.footer-inner strong,
.footer-col strong {
  color: var(--chrome-ink);
  display: block;
  margin-bottom: 0.5rem;
}
.footer-inner a,
.footer-col a {
  display: block;
  color: var(--footer-muted);
  text-decoration: none;
  padding: 0.16rem 0;
  font-size: var(--text-base);
}
.footer-inner a:hover,
.footer-col a:hover { color: var(--chrome-ink); }
/* Column headings are <strong> directly inside a footer column and stack above
   their links. A <strong> inside a footer sentence (e.g. "<strong>MyoMed
   Rescue</strong> is part of MyoMed Prep…") is emphasis and stays in the line. */
.footer-inner p strong,
.footer-col p strong { display: inline; margin: 0; }
/* Same for links inside a footer sentence (e.g. "<a>help.myomed@…</a> — accounts"):
   they stay in the line at the sentence's size. Stacked nav links are direct
   children of a column, and .footer-links rows are flex, so neither changes. */
.footer-inner p:not(.footer-links) a,
.footer-col p:not(.footer-links) a { display: inline; padding: 0; font-size: inherit; }
/* Company-site Contact column: one paragraph of "address — role" lines at the
   column's link size; each role is bound to its dash so it wraps as a unit. */
.footer-inner .footer-contact { font-size: var(--text-base); }
.footer-legal {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.15rem 1rem 1.4rem;
  font-size: var(--text-sm);
  line-height: 1.55;
  border-top: 1px solid var(--chrome-line);
  color: var(--footer-legal);
}
.footer-legal p {
  margin: 0 0 0.75rem;
  max-width: 72ch;
}
.footer-legal p:last-child { margin-bottom: 0; }
.footer-meta { margin-top: 0.85rem; }
.footer-meta a {
  color: var(--chrome-muted);
  text-decoration: none;
  border-bottom: 1px dotted var(--chrome-line);
}
.footer-meta a:hover,
.footer-meta a:focus-visible { color: var(--chrome-ink); border-bottom-color: var(--chrome-ink); }
.slogan { color: var(--product-accent-strong); font-weight: 700; letter-spacing: 0.01em; }
.footer-inner .slogan { display: block; color: var(--chrome-muted); font-size: var(--text-sm); margin-top: 0.35rem; }
/* Publisher seal in the footer: circular, alpha art with a cream field, tinted
   to each product's accent at build time (see shared/brand/myomed-seal-*.png). */
.footer-seal {
  height: 44px;
  width: 44px;
  display: inline-block;
  vertical-align: middle;
  margin: 0 0.6rem;
  object-fit: contain;
}
.footer-seal-row { display: flex; align-items: center; justify-content: center; gap: 0.75rem; margin: 0.35rem 0; flex-wrap: wrap; }
/* Seal + company line: the seal sits beside ONE text block, so the address and
   phone wrap inside that block on narrow screens instead of running under the
   seal. Markup: <p class="footer-seal-line"><img class="footer-seal">
   <span class="footer-seal-text">MyoMed Prep LLC · … · <a href="tel:…">…</a></span></p> */
.footer-seal-line { display: flex; align-items: center; gap: 0.6rem; }
.footer-seal-line > .footer-seal { flex: 0 0 auto; margin: 0; }
.footer-seal-line > .footer-seal-text { flex: 1 1 auto; min-width: 0; }
/* Company-site variant (built by chrome.js): <div class="footer-seal-line
   footer-seal-block"> holding the seal and one .footer-seal-text block with the
   company line and the (c) line, so both wrap inside the block beside the seal
   and keep the same 72ch measure as the paragraphs above. */
.footer-seal-block { margin: 0 0 0.75rem; max-width: 72ch; }
.footer-seal-block:last-child { margin-bottom: 0; }
.footer-seal-block > .footer-seal-text > p { margin: 0 0 0.35rem; max-width: none; }
.footer-seal-block > .footer-seal-text > p:last-child { margin-bottom: 0; }
/* The company phone in a footer sentence is part of that sentence, not a stacked
   footer nav link (.footer-inner a is display:block at 0.92rem): same font, size,
   colour and flow as the address around it; hover matches the footer links. */
footer p a[href^="tel:"],
.footer p a[href^="tel:"],
.footer-legal p a[href^="tel:"] {
  display: inline;
  padding: 0;
  border: 0;
  font: inherit;
  color: inherit;
  text-decoration: none;
  white-space: nowrap;
}
footer p a[href^="tel:"]:hover,
footer p a[href^="tel:"]:focus-visible,
.footer p a[href^="tel:"]:hover,
.footer p a[href^="tel:"]:focus-visible,
.footer-legal p a[href^="tel:"]:hover,
.footer-legal p a[href^="tel:"]:focus-visible { color: var(--chrome-ink); }

/* ---------- Mobile drawer ---------- */
@media (max-width: 860px) {
  .nav-toggle { display: inline-flex; align-items: center; }
  nav.main,
  .main-nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    margin: 0;
    padding: 0.4rem 0 0.6rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }
  .topbar-inner.is-open nav.main,
  .topbar-inner.is-open .main-nav,
  nav.main.is-open,
  .main-nav.is-open {
    display: flex;
  }
  .topbar-inner { flex-wrap: wrap; }
  nav.main a.nav-cta { margin: 0.4rem 0 0; text-align: center; }
  .nav-more-panel {
    position: static;
    box-shadow: none;
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.12);
    margin-top: 0.25rem;
  }
  nav.main .nav-more-panel a,
  nav.main .nav-more-panel a:link,
  nav.main .nav-more-panel a:visited,
  .main-nav .nav-more-panel a,
  .main-nav .nav-more-panel a:link,
  .main-nav .nav-more-panel a:visited { color: #e8f2f5; }
  nav.main .nav-more-panel a:hover,
  nav.main .nav-more-panel a:focus,
  nav.main .nav-more-panel a:focus-visible,
  .main-nav .nav-more-panel a:hover,
  .main-nav .nav-more-panel a:focus,
  .main-nav .nav-more-panel a:focus-visible {
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    outline-color: rgba(255, 255, 255, 0.55);
  }
  .hero { padding: 2rem 1.4rem; }
}

@media (max-width: 640px) {
  .brand-banner { max-width: 160px; height: 36px; }
  .hero h1 { font-size: var(--text-2xl); }
}

/* ---------- Synapsis AI coach chrome ---------- */
.synapsis-lockup {
  background: var(--syn-charcoal);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(232, 121, 249, 0.22);
}
.synapsis-lockup img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 220px;
  object-fit: cover;
  object-position: center;
}
.synapsis-mark {
  width: 36px; height: 36px; border-radius: 9px;
  box-shadow: 0 0 12px rgba(232, 121, 249, 0.35);
}
.synapsis-head {
  display: flex; align-items: center; gap: 0.85rem; flex-wrap: wrap;
  margin-bottom: 0.8rem;
}
.synapsis-head h1, .synapsis-head h2 { margin: 0; }
.synapsis-kicker {
  display: block; font-size: var(--text-xs); font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--syn-ink);
}
.synapsis-chips { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0.6rem 0 0.2rem; }
.synapsis-chip {
  display: inline-block; font-size: var(--text-xs); font-weight: 700;
  padding: 0.2rem 0.65rem; border-radius: 999px;
  background: var(--syn-charcoal); color: var(--syn-silver);
  border: 1px solid rgba(232, 121, 249, 0.35);
}
.synapsis-chip.standby { color: #9aa8b0; border-style: dashed; }
.synapsis-chip.ready { color: var(--syn-glow); border-color: var(--syn-accent); }
.synapsis-panel {
  background: linear-gradient(180deg, var(--syn-charcoal) 0%, #2a1533 100%);
  color: #dce6ec;
  border-radius: var(--radius);
  padding: 1.3rem 1.4rem;
  border: 1px solid rgba(232, 121, 249, 0.28);
  box-shadow: 0 0 0 1px rgba(42, 21, 51, 0.4), 0 8px 28px rgba(42, 21, 51, 0.18);
}
.synapsis-panel h2, .synapsis-panel h3 { color: #fff; }
.synapsis-panel p { color: #c5d0d8; }
/* Text links glow; a .btn in the panel keeps its own (readable) button colours. */
.synapsis-panel a:not(.btn) { color: var(--syn-glow); }
/* A Synapsis section on a product or company page: everything inside that
   reads the product accent (card top edge, .pill, links, focus ring, the
   primary button) turns Synapsis fuchsia. Tokens only, so it flips with the
   theme through --syn-ink / --syn-on-ink. */
.syn-surface {
  --product-accent: var(--syn-ink);
  --product-accent-ink: var(--syn-on-ink);
  --product-accent-soft: color-mix(in srgb, var(--syn-ink) 14%, var(--card));
  --product-accent-strong: color-mix(in srgb, var(--syn-ink) 78%, var(--heading));
  --ring: 0 0 0 3px color-mix(in srgb, var(--syn-ink) 35%, transparent);
  --teal: var(--syn-ink);
  --teal-light: color-mix(in srgb, var(--syn-ink) 14%, var(--card));
}

/* ---------- Dark theme (tokens only) ----------
   One palette for every themable surface. Nothing below this line styles a
   component: it re-maps the tokens above, so a component that uses tokens is
   dark-ready with no per-component override. Three states, in cascade order:
     1. :root                                   light, always defined
     2. prefers-color-scheme: dark              follows the OS, but only while
                                                no explicit choice is stored
                                                (<html> has no data-theme)
     3. [data-theme="dark"] / html.theme-dark   an explicit choice wins
   An explicit data-theme="light" is never touched. Always-dark products
   (RadMatrix, the operator dashboard) declare data-theme="night" and keep
   their own palette; this layer ignores that value.
   --navy / --navy-2 stay dark surfaces in both themes; text that used to read
   var(--navy) must use var(--heading), which flips.
   shared/brand/checks/dark-tokens.js asserts contrast (>= 4.5:1) for every
   text/surface pair and that the two blocks below never drift apart. */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --syn-ink: #e879f9;
    --syn-on-ink: #2e0533;
    --ink: #e9e6df;
    --muted: #a2a7af;
    --heading: #efece6;
    --heading-2: #c9c4bc;
    --line: #2c313a;
    --bg: #0e1013;
    --card: #171a1f;
    --surface-1: #121418;
    --surface-2: #22262c;
    --surface-3: #2c313a;
    --teal: #3ba7b2;
    --teal-hover: #7fd3dc;
    --teal-light: #14323a;
    --on-teal: #06212a;
    --pill-ink: #8fdce4;
    --pill-warn-ink: #e6c877;
    --good: #3aa67a;
    --good-bg: #143023;
    --good-ink: #6fd0a6;
    --warn: #d4891a;
    --warn-bg: #33280f;
    --bad: #ef6b61;
    --bad-bg: #351d1a;
    --info: #3ba7b2;
    --info-bg: #14323a;
    --gold-bg: #33280f;
    --gold-ink: #e6c877;
    --highlight-bg: #3a3218;
    --input-bg: #171a1f;
    --panel-bg: #1b1e24;
    --panel-ink: #e9e6df;
    --panel-hover: #262b33;
    --panel-ring: var(--product-accent);
    --chrome-bg: #0a0c0f;
    --chrome-ink: #e9e6df;
    --chrome-muted: #a2a7af;
    --chrome-line: #23272e;
    --nav-link: #c9c4bc;
    --footer-muted: #a2a7af;
    --footer-legal: #a2a7af;
    --hero-from: #0e2a37;
    --hero-mid: #123b4c;
    --hero-to: #0b6770;
    --elev-1: 0 1px 2px rgba(0, 0, 0, 0.5);
    --elev-2: 0 1px 3px rgba(0, 0, 0, 0.5), 0 4px 14px rgba(0, 0, 0, 0.35);
    --elev-3: 0 2px 6px rgba(0, 0, 0, 0.5), 0 10px 28px rgba(0, 0, 0, 0.45);
    --elev-4: 0 6px 16px rgba(0, 0, 0, 0.55), 0 24px 56px rgba(0, 0, 0, 0.5);
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.5), 0 4px 14px rgba(0, 0, 0, 0.35);
    --shadow-lg: 0 2px 6px rgba(0, 0, 0, 0.5), 0 10px 28px rgba(0, 0, 0, 0.45);
    --ring: 0 0 0 3px rgba(127, 211, 220, 0.45);
    color-scheme: dark;
  }
}
:root[data-theme="dark"],
html.theme-dark {
  --syn-ink: #e879f9;
  --syn-on-ink: #2e0533;
  --ink: #e9e6df;
  --muted: #a2a7af;
  --heading: #efece6;
  --heading-2: #c9c4bc;
  --line: #2c313a;
  --bg: #0e1013;
  --card: #171a1f;
  --surface-1: #121418;
  --surface-2: #22262c;
  --surface-3: #2c313a;
  --teal: #3ba7b2;
  --teal-hover: #7fd3dc;
  --teal-light: #14323a;
  --on-teal: #06212a;
  --pill-ink: #8fdce4;
  --pill-warn-ink: #e6c877;
  --good: #3aa67a;
  --good-bg: #143023;
  --good-ink: #6fd0a6;
  --warn: #d4891a;
  --warn-bg: #33280f;
  --bad: #ef6b61;
  --bad-bg: #351d1a;
  --info: #3ba7b2;
  --info-bg: #14323a;
  --gold-bg: #33280f;
  --gold-ink: #e6c877;
  --highlight-bg: #3a3218;
  --input-bg: #171a1f;
  --panel-bg: #1b1e24;
  --panel-ink: #e9e6df;
  --panel-hover: #262b33;
  --panel-ring: var(--product-accent);
  --chrome-bg: #0a0c0f;
    --chrome-ink: #e9e6df;
    --chrome-muted: #a2a7af;
    --chrome-line: #23272e;
    --nav-link: #c9c4bc;
    --footer-muted: #a2a7af;
    --footer-legal: #a2a7af;
  --hero-from: #0e2a37;
  --hero-mid: #123b4c;
  --hero-to: #0b6770;
  --elev-1: 0 1px 2px rgba(0, 0, 0, 0.5);
  --elev-2: 0 1px 3px rgba(0, 0, 0, 0.5), 0 4px 14px rgba(0, 0, 0, 0.35);
  --elev-3: 0 2px 6px rgba(0, 0, 0, 0.5), 0 10px 28px rgba(0, 0, 0, 0.45);
  --elev-4: 0 6px 16px rgba(0, 0, 0, 0.55), 0 24px 56px rgba(0, 0, 0, 0.5);
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.5), 0 4px 14px rgba(0, 0, 0, 0.35);
  --shadow-lg: 0 2px 6px rgba(0, 0, 0, 0.5), 0 10px 28px rgba(0, 0, 0, 0.45);
  --ring: 0 0 0 3px rgba(127, 211, 220, 0.45);
  color-scheme: dark;
}
:root[data-theme="dark"] img { opacity: 0.94; }
:root[data-theme="dark"] img:hover { opacity: 1; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) img { opacity: 0.94; }
  :root:not([data-theme]) img:hover { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  :root { --dur-fast: 0ms; --dur-base: 0ms; --dur-slow: 0ms; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* WCAG 2.4.1 Bypass Blocks: first tab stop on every page. */
.skip-link {
  position: absolute; left: 0.75rem; top: -4rem; z-index: 1000;
  background: var(--product-accent); color: var(--product-accent-ink); padding: 0.6rem 1rem;
  border-radius: 8px; font-weight: 700; text-decoration: none;
}
.skip-link:focus, .skip-link:focus-visible { top: 0.75rem; outline: 3px solid var(--chrome-ink); outline-offset: 2px; }
main:focus { outline: none; }

/* Whole footer: one font, one size, even spacing. Inter's cv11 (single-storey a)
   looked like a second typeface at footer sizes, and hinted glyph advances at ~11-13px
   produced uneven gaps ("Myo Med", "18 27"). */
footer, footer * {
  font-feature-settings: normal;
  font-variant-numeric: normal;
  letter-spacing: normal;
  word-spacing: normal;
  text-rendering: geometricPrecision;
}
