/*
 * PTH ZoneForge — style.css
 * Shared stylesheet for EN and DE entry points.
 *
 * Fonts: Epilogue + IBM Plex Mono
 * Self-hosted woff2 files live in /zoneforge/fonts/
 * Download from: https://fonts.google.com/specimen/Epilogue
 *                https://fonts.google.com/specimen/IBM+Plex+Mono
 * Required weights: Epilogue 400/500/600/700/800, IBM Plex Mono 400/500
 *
 * @font-face declarations below reference the self-hosted files.
 * Until font files are placed in /fonts/, the Google Fonts fallback
 * link in index.html will serve them. Remove that link once fonts are local.
 */

@font-face {
  font-family: 'Epilogue';
  src: url('/zoneforge/fonts/epilogue/epilogue-400.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Epilogue';
  src: url('/zoneforge/fonts/epilogue/epilogue-500.woff2') format('woff2');
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Epilogue';
  src: url('/zoneforge/fonts/epilogue/epilogue-600.woff2') format('woff2');
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Epilogue';
  src: url('/zoneforge/fonts/epilogue/epilogue-700.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Epilogue';
  src: url('/zoneforge/fonts/epilogue/epilogue-800.woff2') format('woff2');
  font-weight: 800; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Mono';
  src: url('/zoneforge/fonts/ibm-plex-mono/ibm-plex-mono-400.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'IBM Plex Mono';
  src: url('/zoneforge/fonts/ibm-plex-mono/ibm-plex-mono-500.woff2') format('woff2');
  font-weight: 500; font-style: normal; font-display: swap;
}


:root {
  /* PT&H Brand Colours */
  --brand-green: #a8c800;
  --brand-green-dark: #8aaa00;
  --brand-green-light: #eef5c0;
  --brand-green-mid: #d4e96a;
  --brand-purple: #6b3fa0;
  --brand-purple-dark: #52307c;
  --brand-purple-light: #ede5f7;
  --brand-purple-mid: #b89fd4;
  /* Layout */
  --bg: #f5f7e8;
  --surface: #ffffff;
  --surface2: #f9fbf0;
  --border: #dde8a0;
  --text: #1a1230;
  --muted: #6b5f8a;
  /* Primary = brand purple */
  --primary: #6b3fa0;
  --primary-light: #ede5f7;
  --primary-dark: #52307c;
  /* Zone colours — keep red/amber/green logic, tinted to brand */
  --z1: #4a8c00;          /* deep lime green  */
  --z1-light: #eef5c0;
  --z1-border: #c2db5a;
  --z2: #c47a00;          /* amber */
  --z2-light: #fef3c7;
  --z2-border: #f5cc6a;
  --z3: #b91c1c;          /* red — kept for danger signal */
  --z3-light: #fee2e2;
  --z3-border: #fca5a5;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(107,63,160,.08), 0 4px 12px rgba(107,63,160,.06);
}

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

body {
  font-family: 'Epilogue', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ── HEADER ── */
header {
  background: var(--brand-purple);
  padding: 0.75rem 1.75rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 12px rgba(107,63,160,.35);
}

.brand-logo {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  flex-shrink: 0;
  border: 2px solid rgba(168,200,0,.6);
  box-shadow: 0 0 0 3px rgba(168,200,0,.15);
}

.header-text {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
}

header h1 {
  font-size: 1.2rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: white;
  line-height: 1;
}

header h1 span { color: var(--brand-green); }

.header-sub {
  font-size: 0.65rem;
  color: var(--brand-purple-mid);
  letter-spacing: 0.5px;
  font-weight: 500;
  text-transform: uppercase;
}

.version {
  margin-left: auto;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.72rem;
  color: var(--brand-purple-mid);
  background: var(--brand-purple-dark);
  padding: 0.25rem 0.65rem;
  border-radius: 20px;
}

/* ── STEP TABS ── */
.steps {
  background: var(--surface);
  border-bottom: 2px solid var(--brand-green);
  padding: 0 1.5rem;
  display: flex;
  overflow-x: auto;
}

.step-tab {
  padding: 0.9rem 1.25rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted);
  border-bottom: 3px solid transparent;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: color 0.15s;
  margin-bottom: -2px;
  cursor: pointer;
  user-select: none;
}
.step-tab:hover {
  color: var(--brand-purple);
}

.step-tab.active {
  color: var(--brand-purple);
  border-bottom-color: var(--brand-purple);
}

.step-tab.done { color: var(--z1); }

.step-num {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--border);
  color: var(--muted);
  font-size: 0.7rem;
  display: flex; align-items: center; justify-content: center;
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 500;
  flex-shrink: 0;
}

.step-tab.active .step-num { background: var(--brand-purple); color: white; }
.step-tab.done .step-num { background: var(--z1); color: white; }

/* ── MAIN ── */
main {
  max-width: 1280px;
  margin: 2rem auto;
  padding: 0 1.5rem 4rem;
}

/* ── TWO-COLUMN LAYOUT ── */
.pth-cols {
  display: grid;
  gap: 1.5rem;
  align-items: start;
}
.pth-cols-55-45 { grid-template-columns: 55fr 45fr; }
.pth-cols-60-40 { grid-template-columns: 60fr 40fr; }
.pth-cols-40-60 { grid-template-columns: 40fr 60fr; }
@media (max-width: 900px) {
  .pth-cols { grid-template-columns: 1fr !important; }
}

.panel { display: none; }
.panel.active { display: block; animation: fadeUp .25s ease; }

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── CARDS ── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  border-top: 3px solid var(--brand-green);
  padding: 1.75rem;
  margin-bottom: 1.25rem;
  box-shadow: var(--shadow);
}

.card-title {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.25rem;
}

/* ── FORM ── */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-group { display: flex; flex-direction: column; gap: 0.35rem; }
.form-group.full { grid-column: 1 / -1; }

label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--muted);
}

input[type="text"],
input[type="number"] {
  padding: 0.65rem 0.9rem;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.9rem;
  color: var(--text);
  background: var(--surface2);
  width: 100%;
  transition: border-color 0.15s, background 0.15s;
}

input:focus {
  outline: none;
  border-color: var(--brand-purple);
  background: white;
}

.threshold-block {
  border-radius: 10px;
  padding: 1.25rem;
  margin-bottom: 0.75rem;
}

.lt1-block { background: #f0fdf4; border: 1.5px solid var(--z1-border); }
.lt2-block { background: #fff5f5; border: 1.5px solid var(--z3-border); }

.threshold-label {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.85rem;
}

.lt1-block .threshold-label { color: var(--z1); }
.lt2-block .threshold-label { color: var(--z3); }

#validationMsg {
  color: var(--z3);
  font-size: 0.82rem;
  margin-top: 0.5rem;
  display: none;
  padding: 0.5rem 0.75rem;
  background: var(--z3-light);
  border-radius: 6px;
}

/* ── BUTTONS ── */
.btn {
  padding: 0.7rem 1.5rem;
  border-radius: 8px;
  border: none;
  font-family: 'Epilogue', sans-serif;
  font-weight: 700;
  font-size: 0.88rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  transition: all 0.15s;
  text-decoration: none;
}

.btn-primary { background: var(--brand-purple); color: white; }
.btn-primary:hover { background: var(--brand-purple-dark); transform: translateY(-1px); }

.btn-orange { background: var(--brand-green-dark); color: #1a1230; }
.btn-orange:hover { background: var(--brand-green); transform: translateY(-1px); }

.btn-green { background: var(--z1); color: white; }
.btn-green:hover { background: #15803d; transform: translateY(-1px); }

.btn-ghost {
  background: transparent;
  color: var(--muted);
  border: 1.5px solid var(--border);
}
.btn-ghost:hover { background: var(--surface2); color: var(--text); }

.btn-row {
  display: flex;
  gap: 0.65rem;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 1.5rem;
}

/* ── ZONE CARDS ── */
.zones-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0.875rem;
  margin-bottom: 1.5rem;
}

.zone-card {
  border-radius: 10px;
  padding: 1.1rem;
}

.zone-card.z1 { background: var(--z1-light); border: 1.5px solid var(--z1-border); }
.zone-card.z2 { background: var(--z2-light); border: 1.5px solid var(--z2-border); }
.zone-card.z3 { background: var(--z3-light); border: 1.5px solid var(--z3-border); }

.zone-badge {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border-radius: 20px;
}

.z1 .zone-badge { background: var(--z1); color: white; }
.z2 .zone-badge { background: var(--z2); color: white; }
.z3 .zone-badge { background: var(--z3); color: white; }

.zone-range {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.75rem;
  color: var(--muted);
  line-height: 1.7;
  margin-bottom: 0.65rem;
}

.zone-pct {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text);
  line-height: 1;
}

.zone-hours {
  font-size: 0.78rem;
  color: var(--muted);
  margin-top: 0.2rem;
}

/* ── DISTRIBUTION BAR ── */
.dist-bar-wrap { margin-bottom: 1.25rem; }

.dist-bar {
  display: flex;
  height: 28px;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 0.5rem;
}

.dist-seg {
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.72rem;
  font-weight: 500;
  color: white;
  transition: width 0.6s cubic-bezier(.4,0,.2,1);
  white-space: nowrap;
  overflow: hidden;
}

.dist-seg.s1 { background: var(--brand-green-dark); }
.dist-seg.s2 { background: var(--z2); }
.dist-seg.s3 { background: var(--brand-purple); }

.dist-legend {
  display: flex;
  gap: 1.25rem;
  font-size: 0.78rem;
  color: var(--muted);
  flex-wrap: wrap;
}

.ldot {
  width: 8px; height: 8px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 4px;
  flex-shrink: 0;
}

/* ── REC SUMMARY ── */
.rec-rows { display: flex; flex-direction: column; gap: 0.6rem; }

.rec-row {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  font-size: 0.9rem;
}

.rec-row.r1 { background: var(--z1-light); }
.rec-row.r2 { background: var(--z2-light); }
.rec-row.r3 { background: var(--z3-light); }

.rec-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.r1 .rec-dot { background: var(--z1); }
.r2 .rec-dot { background: var(--z2); }
.r3 .rec-dot { background: var(--z3); }

.rec-label { font-weight: 700; flex: 1; }
.rec-val { font-family: 'IBM Plex Mono', monospace; font-weight: 500; font-size: 0.88rem; }
.rec-note { font-size: 0.78rem; color: var(--muted); margin-left: 0.5rem; }

/* ── UPLOAD ── */
.upload-area {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  padding: 3rem 2rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
}

.upload-area:hover, .upload-area.drag {
  border-color: var(--brand-purple);
  background: var(--brand-purple-light);
}

.upload-icon { font-size: 2.25rem; margin-bottom: 0.65rem; }
.upload-title { font-weight: 700; margin-bottom: 0.25rem; }
.upload-sub { font-size: 0.82rem; color: var(--muted); }

/* ── COMPLIANCE ── */
.compliance-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0.875rem;
  margin-bottom: 1.25rem;
}

.comp-card {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1rem;
}

.comp-label {
  font-size: 0.67rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--muted);
  margin-bottom: 0.4rem;
}

.comp-val {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--text);
}

.comp-target {
  font-size: 0.73rem;
  color: var(--muted);
  margin-top: 0.2rem;
}

/* ── FEEDBACK ── */
.feedback {
  background: var(--brand-purple-light);
  border: 1.5px solid var(--brand-purple-mid);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.25rem;
}

.feedback h3 {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--brand-purple);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 0.65rem;
}

.feedback-items { display: flex; flex-direction: column; gap: 0.65rem; }

.feedback-item {
  font-size: 0.88rem;
  line-height: 1.55;
  padding: 0.6rem 0.85rem;
  border-radius: 7px;
  background: white;
  border-left: 3px solid var(--border);
}

.feedback-item.good { border-left-color: var(--z1); }
.feedback-item.warn { border-left-color: var(--z2); }
.feedback-item.bad  { border-left-color: var(--z3); }

.tag-good { color: var(--z1); font-weight: 700; }
.tag-warn { color: var(--z2); font-weight: 700; }
.tag-bad  { color: var(--z3); font-weight: 700; }

/* ── INFO ── */
.info-note {
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.65;
  margin-top: 1rem;
  padding: 0.85rem 1rem;
  background: var(--brand-green-light);
  border-radius: 8px;
  border: 1px solid var(--brand-green);
}

.mono { font-family: 'IBM Plex Mono', monospace; }



/* ── DISCLAIMER BANNER ── */
.disclaimer-banner {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  background: #b91c1c;
  border: 1.5px solid #ef444466;
  border-left: 4px solid #ef4444;
  border-radius: 10px;
  padding: 1rem 1.1rem;
  margin: 0 0 1.25rem 0;
  font-size: 0.8rem;
  line-height: 1.6;
  color: #cbd5e1;
  position: relative;
  transition: all 0.25s;
}

.disclaimer-banner.minimised {
  padding: 0.6rem 1.1rem;
  align-items: center;
}

.disclaimer-banner.minimised .disc-detail,
.disclaimer-banner.minimised .disc-toggle {
  display: none;
}

.disclaimer-banner.minimised .disc-body strong {
  display: inline;
}

.disc-icon {
  font-size: 1.35rem;
  flex-shrink: 0;
  margin-top: 1px;
}

.disc-body {
  flex: 1;
}

.disc-body strong {
  display: block;
  color: #ffffff;
  margin-bottom: 0.3rem;
  font-size: 0.82rem;
}

.disc-detail {
  display: block;
  margin-top: 0.45rem;
  color: rgba(255,255,255,0.88);
  font-size: 0.75rem;
  line-height: 1.65;
}

.disc-toggle {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.7rem;
  color: var(--brand-purple-mid);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.disc-close {
  background: none;
  border: 1px solid rgba(255,255,255,0.4);
  border-radius: 5px;
  color: rgba(255,255,255,0.75);
  font-size: 0.7rem;
  cursor: pointer;
  padding: 0.15rem 0.4rem;
  flex-shrink: 0;
  align-self: flex-start;
  transition: all 0.15s;
}

.disc-close:hover { border-color: white; color: white; }

/* ── CATEGORY MEDICAL ALERT ── */
.cat-medical-alert {
  margin-top: 0.85rem;
  padding: 0.85rem 1rem;
  border-radius: 8px;
  font-size: 0.79rem;
  line-height: 1.65;
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
}

.cat-medical-alert.cat-alert-orange {
  background: #fff7ed;
  border: 1.5px solid #f97316;
  border-left: 4px solid #f97316;
  color: #7c2d12;
}

.cat-medical-alert.cat-alert-red {
  background: #fef2f2;
  border: 1.5px solid #ef4444;
  border-left: 4px solid #ef4444;
  color: #dc2626;
}

.cat-medical-alert strong { display: block; margin-bottom: 0.2rem; }

/* ── INTENSITY SAFETY NOTE ── */
.intensity-safety-note {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  padding: 0.85rem 1rem;
  border-radius: 9px;
  margin-bottom: 1rem;
  background: #fffbeb;
  border: 1.5px solid #fbbf24;
  border-left: 4px solid #f59e0b;
  font-size: 0.79rem;
  line-height: 1.65;
  color: #78350f;
}

.isn-icon { font-size: 1.1rem; flex-shrink: 0; margin-top: 1px; }
.isn-body strong { display: block; margin-bottom: 0.2rem; color: #92400e; }



/* ══════════════════════════════════════════
   PAR-Q+ MODAL
══════════════════════════════════════════ */
.parq-overlay {
  position: fixed;
  inset: 0;
  background: rgba(10,5,20,.72);
  z-index: 1000;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 2rem 1rem;
  overflow-y: auto;
  backdrop-filter: blur(3px);
}

.parq-modal {
  background: var(--surface);
  border-radius: 14px;
  width: 100%;
  max-width: 680px;
  box-shadow: 0 24px 64px rgba(0,0,0,.55);
  overflow: hidden;
  margin: auto;
}

.parq-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 1.25rem 1.5rem 1rem;
  background: linear-gradient(135deg, #b91c1c 0%, #dc2626 100%);
  border-bottom: 2px solid #ef4444;
}

.parq-header-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #e2d9f3;
  letter-spacing: -0.3px;
}

.parq-version {
  font-size: 0.65rem;
  font-weight: 600;
  background: var(--brand-purple);
  color: white;
  padding: 0.1rem 0.45rem;
  border-radius: 10px;
  vertical-align: middle;
  margin-left: 0.4rem;
}

.parq-header-sub {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.82);
  margin-top: 0.15rem;
}

.parq-close-btn {
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.2);
  color: #e2d9f3;
  border-radius: 6px;
  padding: 0.2rem 0.5rem;
  cursor: pointer;
  font-size: 0.8rem;
  flex-shrink: 0;
  margin-top: 2px;
  transition: background 0.15s;
}
.parq-close-btn:hover { background: rgba(255,255,255,.22); }

.parq-scroll-body {
  padding: 1.25rem 1.5rem 1.5rem;
  max-height: 80vh;
  overflow-y: auto;
}

.parq-preamble {
  background: #dc2626;
  border-radius: 8px;
  padding: 0.9rem 1rem;
  font-size: 0.78rem;
  line-height: 1.6;
  color: #ffffff;
  margin-bottom: 1.25rem;
  border-left: 3px solid rgba(255,255,255,0.4);
}
.parq-preamble p { margin: 0 0 0.4rem; }
.parq-preamble p:last-child { margin: 0; }

.parq-section-title {
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--brand-purple-mid);
  margin-bottom: 0.75rem;
}

/* Questions */
.parq-questions { display: flex; flex-direction: column; gap: 0.6rem; }

.parq-q {
  display: flex;
  gap: 0.85rem;
  padding: 0.85rem 1rem;
  border: 1.5px solid var(--border);
  border-radius: 9px;
  background: var(--surface2);
  transition: border-color 0.2s, background 0.2s;
}

.parq-q.answered-yes { border-color: #f97316; background: #fff7ed; }
.parq-q.answered-no  { border-color: #22c55e55; background: #f0fdf455; }

.parq-q-num {
  font-weight: 800;
  font-size: 0.8rem;
  color: var(--brand-purple);
  min-width: 20px;
  padding-top: 0.1rem;
  flex-shrink: 0;
}

.parq-q-body { flex: 1; }

.parq-q-text {
  font-size: 0.82rem;
  line-height: 1.55;
  margin-bottom: 0.55rem;
  color: var(--text);
}

.parq-btns {
  display: flex;
  gap: 0.5rem;
}

.parq-yn {
  padding: 0.3rem 1.1rem;
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.78rem;
  cursor: pointer;
  border: 1.5px solid var(--border);
  background: white;
  transition: all 0.15s;
}

.parq-yn.yes.selected { background: #f97316; border-color: #ea580c; color: white; }
.parq-yn.no.selected  { background: #22c55e; border-color: #16a34a; color: white; }
.parq-yn.yes:hover:not(.selected) { border-color: #f97316; color: #ea580c; }
.parq-yn.no:hover:not(.selected)  { border-color: #22c55e; color: #16a34a; }

.parq-detail-input {
  margin-top: 0.5rem;
  width: 100%;
  padding: 0.45rem 0.7rem;
  border: 1.5px solid #f97316;
  border-radius: 6px;
  font-size: 0.78rem;
  font-family: inherit;
  background: white;
}

/* Part 2 sub-questions */
.parq-p2-block {
  background: #fde8e8;
  border-radius: 8px;
  padding: 0.85rem 1rem;
  margin-bottom: 0.65rem;
  border-left: 4px solid #b91c1c;
}

.parq-p2-title {
  font-weight: 700;
  font-size: 0.79rem;
  color: #7f1d1d;
  margin-bottom: 0.55rem;
}

.parq-p2-sub {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.4rem 0;
  font-size: 0.77rem;
  line-height: 1.5;
  color: #3b0808;
  border-top: 1px solid rgba(185,28,28,.18);
}
.parq-p2-sub:first-of-type { border-top: none; }
.parq-p2-sub { border-top-color: rgba(185,28,28,.2); }

.parq-p2-sub input[type=checkbox] {
  margin-top: 2px;
  flex-shrink: 0;
  accent-color: var(--brand-purple);
  width: 14px;
  height: 14px;
}

/* Result block */
.parq-result-box {
  border-radius: 10px;
  padding: 1.1rem 1.25rem;
  font-size: 0.81rem;
  line-height: 1.65;
}

.parq-result-box.cleared    { background: #dcfce7; border: 2px solid #22c55e; color: #14532d; }
.parq-result-box.conditions { background: #fff7ed; border: 2px solid #f97316; color: #7c2d12; }
.parq-result-box.not-cleared{ background: #fef2f2; border: 2px solid #ef4444; color: #dc2626; }

.parq-result-title {
  font-size: 1rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.parq-result-items { margin-top: 0.65rem; }
.parq-result-item  { padding: 0.25rem 0; border-top: 1px solid rgba(0,0,0,.08); font-size: 0.78rem; }
.parq-result-item:first-child { border-top: none; }

.parq-print-summary {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin-top: 0.85rem;
  font-size: 0.73rem;
  color: var(--muted);
  line-height: 1.6;
}

/* Footer */
.parq-footer {
  display: flex;
  gap: 0.75rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  margin-top: 1rem;
  flex-wrap: wrap;
}

/* Status badge in Step 1 */
.parq-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.2rem 0.65rem;
  border-radius: 20px;
  cursor: pointer;
}
.parq-status-badge.cleared    { background: #dcfce7; color: #14532d; border: 1px solid #22c55e; }
.parq-status-badge.conditions { background: #fff7ed; color: #7c2d12; border: 1px solid #f97316; }
.parq-status-badge.not-cleared{ background: #fef2f2; color: #dc2626; border: 1px solid #ef4444; }
.parq-status-badge.incomplete { background: var(--surface2); color: var(--muted); border: 1px solid var(--border); }

/* disc-parq-btn */
.disc-parq-btn {
  display: inline-block;
  margin-top: 0.5rem;
  margin-left: 0.25rem;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--brand-green);
  background: rgba(168,200,0,.12);
  border: 1px solid rgba(168,200,0,.35);
  border-radius: 6px;
  padding: 0.2rem 0.65rem;
  cursor: pointer;
  transition: all 0.15s;
}
.disc-parq-btn:hover { background: rgba(168,200,0,.22); }

@media (max-width: 580px) {
  .parq-scroll-body { padding: 1rem; }
  .parq-header { padding: 1rem; }
  .parq-q { flex-direction: column; gap: 0.5rem; }
}

/* ── AEROBIC BASE CHECK ── */
.abc-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.abc-confound-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.abc-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 0.65rem;
  margin-bottom: 1rem;
}

.abc-stat {
  background: var(--surface2);
  border-radius: 8px;
  padding: 0.6rem 0.85rem;
  text-align: center;
  border: 1px solid var(--border);
}

.abc-stat-val {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--brand-purple);
  display: block;
}

.abc-stat-lbl {
  font-size: 0.65rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  margin-top: 0.15rem;
  display: block;
}

.abc-meter-wrap {
  margin: 0.85rem 0;
}

.abc-meter-bar {
  height: 14px;
  border-radius: 7px;
  background: linear-gradient(to right, #22c55e 0%, #22c55e 33%, #eab308 33%, #eab308 55%, #f97316 55%, #f97316 75%, #ef4444 75%);
  position: relative;
  overflow: visible;
  margin-bottom: 0.3rem;
}

.abc-meter-needle {
  position: absolute;
  top: -4px;
  width: 4px;
  height: 22px;
  background: #1e1b2e;
  border-radius: 2px;
  transform: translateX(-50%);
  transition: left 0.5s cubic-bezier(.4,0,.2,1);
  box-shadow: 0 0 0 2px white;
}

.abc-meter-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.62rem;
  color: var(--muted);
  margin-top: 0.25rem;
}

.abc-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.9rem;
  border-radius: 20px;
  font-weight: 700;
  font-size: 0.82rem;
  margin-bottom: 0.75rem;
}

.abc-badge.excellent { background:#dcfce7; color:#14532d; border:1.5px solid #22c55e; }
.abc-badge.good      { background:#ecfccb; color:#365314; border:1.5px solid #84cc16; }
.abc-badge.caution   { background:#fef9c3; color:#713f12; border:1.5px solid #eab308; }
.abc-badge.poor      { background:#fff7ed; color:#7c2d12; border:1.5px solid #f97316; }
.abc-badge.critical  { background:#fef2f2; color:#dc2626; border:1.5px solid #ef4444; }

.abc-rec-box {
  padding: 0.85rem 1rem;
  border-radius: 8px;
  font-size: 0.79rem;
  line-height: 1.65;
  margin-top: 0.75rem;
}

.abc-rec-box.adjusted { background: #fffbeb; border: 1.5px solid #f59e0b; border-left: 4px solid #f59e0b; color: #78350f; }
.abc-rec-box.confirm  { background: var(--z1-light); border: 1.5px solid var(--z1-border); border-left: 4px solid var(--z1); }
.abc-rec-box.advance  { background: var(--brand-purple-light); border: 1.5px solid var(--brand-purple-mid); border-left: 4px solid var(--brand-purple); }

.abc-confound-warn {
  font-size: 0.72rem;
  color: #b45309;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 6px;
  padding: 0.5rem 0.75rem;
  margin-top: 0.6rem;
}

.abc-ef-row {
  display: flex;
  gap: 1.5rem;
  font-size: 0.78rem;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
}

.abc-ef-item { display: flex; flex-direction: column; }
.abc-ef-val  { font-family: 'IBM Plex Mono', monospace; font-weight: 700; font-size: 0.88rem; color: var(--text); }
.abc-ef-lbl  { font-size: 0.65rem; color: var(--muted); }

.abc-trend-note {
  font-size: 0.72rem;
  color: var(--muted);
  margin-top: 0.5rem;
  border-top: 1px solid var(--border);
  padding-top: 0.5rem;
  line-height: 1.55;
}

@media (max-width:580px) {
  .abc-summary-grid { grid-template-columns: repeat(3,1fr); }
}

/* ── DAILY READINESS ── */
.dr-how-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}

.dr-how-item {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
  font-size: 0.8rem;
  line-height: 1.55;
  padding: 0.75rem;
  background: var(--surface2);
  border-radius: 8px;
  border: 1px solid var(--border);
}

.dr-how-icon { font-size: 1.35rem; flex-shrink: 0; }

.dr-sliders { display: flex; flex-direction: column; gap: 0.9rem; }

.dr-row {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 1rem;
  align-items: start;
  padding: 0.9rem 1rem;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  background: var(--surface2);
}

.dr-signal-name {
  font-weight: 700;
  font-size: 0.85rem;
  margin-bottom: 0.2rem;
}

.dr-signal-sub {
  font-size: 0.72rem;
  color: var(--muted);
  line-height: 1.5;
}

.dr-input { width: 100%; }

.dr-hint {
  font-size: 0.72rem;
  color: var(--muted);
  margin-top: 0.35rem;
  min-height: 1rem;
  line-height: 1.4;
}

.dr-hint.ok   { color: var(--z1); }
.dr-hint.warn { color: var(--z2); }
.dr-hint.bad  { color: var(--z3); }

.dr-slider-wrap {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.dr-slider {
  flex: 1;
  accent-color: var(--brand-purple);
}

.dr-slider-val {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--brand-purple);
  min-width: 36px;
}

/* Likert scale */
.dr-likert {
  display: flex;
  gap: 0.35rem;
}

.dr-lk-opt {
  flex: 1;
  text-align: center;
  padding: 0.45rem 0.2rem;
  border-radius: 7px;
  border: 1.5px solid var(--border);
  background: white;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  line-height: 1.3;
  transition: all 0.15s;
}

.dr-lk-opt span {
  display: block;
  font-size: 0.6rem;
  font-weight: 400;
  color: var(--muted);
  margin-top: 1px;
}

.dr-lk-opt:hover { border-color: var(--brand-purple); background: var(--brand-purple-light); }
.dr-lk-opt.selected { border-color: var(--brand-purple); background: var(--brand-purple); color: white; }
.dr-lk-opt.selected span { color: rgba(255,255,255,.75); }

/* Session prescription output */
.dr-session-box {
  border-radius: 10px;
  padding: 1.25rem;
  margin-bottom: 0.85rem;
}

.dr-session-box.green  { background: var(--z1-light);  border: 2px solid var(--z1-border); }
.dr-session-box.yellow { background: var(--z2-light);  border: 2px solid var(--z2-border); }
.dr-session-box.red    { background: var(--z3-light);  border: 2px solid var(--z3-border); }
.dr-session-box.purple { background: var(--brand-purple-light); border: 2px solid var(--brand-purple-mid); }

/* Daily Readiness output grid */
.dr-rx-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin: 0.65rem 0;
}
.dr-rx-item {
  background: var(--bg-page);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 0.55rem 0.75rem;
}
.dr-rx-label {
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--text-muted);
  margin-bottom: 0.2rem;
}
.dr-rx-val {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-main);
  font-family: 'IBM Plex Mono', monospace;
}
@media (max-width: 480px) {
  .dr-rx-grid { grid-template-columns: 1fr; }
}

.dr-session-title {
  font-size: 1rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
}

.dr-session-details {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.dr-detail-row {
  display: flex;
  gap: 0.65rem;
  font-size: 0.82rem;
  align-items: baseline;
}

.dr-detail-label {
  font-weight: 700;
  min-width: 110px;
  flex-shrink: 0;
  color: var(--muted);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.dr-detail-val {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.82rem;
  font-weight: 500;
}

.dr-rationale {
  margin-top: 0.85rem;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(0,0,0,.08);
  font-size: 0.78rem;
  line-height: 1.65;
  color: var(--text);
}

.dr-evidence-box {
  background: #dc2626;
  border-radius: 8px;
  padding: 0.85rem 1rem;
  margin-top: 0.75rem;
  font-size: 0.73rem;
  color: #ffffff;
  line-height: 1.6;
}

.dr-evidence-box strong { color: #ffffff; font-weight: 700; }

@media (max-width: 580px) {
  .dr-how-grid  { grid-template-columns: 1fr; }
  .dr-row       { grid-template-columns: 1fr; }
  .dr-likert    { gap: 0.2rem; }
  .dr-lk-opt    { padding: 0.35rem 0.1rem; font-size: 0.72rem; }
}


/* ── DISTRIBUTION EXPLAINER ── */
.de-context {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.de-cat-badge, .de-phase-badge, .de-age-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.2rem 0.6rem;
  border-radius: 20px;
}

.de-cat-badge   { background: var(--brand-purple); color: white; }
.de-phase-badge { background: var(--brand-green-dark); color: white; }
.de-age-badge   { background: #e2e8f0; color: var(--text); }

.de-rows { display: flex; flex-direction: column; gap: 0.65rem; }

.de-row {
  display: flex;
  gap: 0.85rem;
  padding: 0.85rem 1rem;
  border-radius: 8px;
  font-size: 0.8rem;
  line-height: 1.65;
}

.de-icon { font-size: 1.1rem; flex-shrink: 0; margin-top: 1px; }

.de-z1      { background: var(--z1-light);          border-left: 3px solid var(--z1); }
.de-thr     { background: var(--brand-purple-light); border-left: 3px solid var(--brand-purple); }
.de-z3      { background: var(--z3-light);           border-left: 3px solid var(--z3); }
.de-grey    { background: var(--z2-light);           border-left: 3px solid var(--z2); }
.de-balance { background: #f0f9ff;                   border-left: 3px solid #0ea5e9; }

.de-row strong { display: block; margin-bottom: 0.2rem; }
.de-row em { color: var(--muted); font-style: normal; font-size: 0.75rem; }

/* ── SESSION QUALITY QUESTIONNAIRE ── */
.sq-questions { display: flex; flex-direction: column; gap: 1.1rem; }

.sq-q {
  display: flex;
  gap: 0.85rem;
  padding: 1rem;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  background: var(--surface2);
  transition: border-color 0.2s;
}

.sq-q.answered { border-color: var(--brand-green); background: #f9fbf2; }

.sq-qnum {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: var(--brand-purple);
  color: white;
  font-size: 0.72rem;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
}

.sq-qbody { flex: 1; }

.sq-qtitle {
  font-weight: 700;
  font-size: 0.88rem;
  margin-bottom: 0.2rem;
  line-height: 1.35;
}

.sq-qsub {
  font-size: 0.73rem;
  color: var(--muted);
  margin-bottom: 0.75rem;
  line-height: 1.5;
}

.sq-options { display: flex; flex-direction: column; gap: 0.35rem; }

.sq-opt {
  padding: 0.5rem 0.85rem;
  border-radius: 7px;
  border: 1.5px solid var(--border);
  background: white;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.15s;
  line-height: 1.4;
}

.sq-opt:hover { border-color: var(--brand-purple); background: var(--brand-purple-light); }
.sq-opt.selected { border-color: var(--brand-purple); background: var(--brand-purple-light); font-weight: 600; }

/* Score badge */
.sq-score-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.65rem 1rem;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.88rem;
  margin-bottom: 1rem;
}

.sqb-green  { background: var(--z1-light); border: 1.5px solid var(--z1-border); color: var(--z1); }
.sqb-yellow { background: var(--z2-light); border: 1.5px solid var(--z2-border); color: var(--z2); }
.sqb-orange { background: #fff3e0; border: 1.5px solid #ffcc80; color: #e65100; }
.sqb-red    { background: var(--z3-light); border: 1.5px solid var(--z3-border); color: var(--z3); }

.sq-signals { display: flex; flex-direction: column; gap: 0.5rem; margin-top: 0.5rem; }

.sq-signal {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  font-size: 0.8rem;
  padding: 0.55rem 0.75rem;
  border-radius: 7px;
  line-height: 1.55;
}

.sq-signal.sig-ok   { background: var(--z1-light); }
.sq-signal.sig-warn { background: var(--z2-light); }
.sq-signal.sig-bad  { background: var(--z3-light); }

.sq-signal-icon { font-size: 1rem; flex-shrink: 0; }

/* Daily Session Questionnaire feedback */
.dq-feedback {
  display:flex; flex-direction:column; gap:.4rem;
  margin-top:.85rem; padding:.75rem .85rem;
  border:1px solid var(--border); border-radius:9px;
  background:var(--bg-main);
}
.dq-feedback-title { font-size:.78rem; font-weight:700; margin-bottom:.2rem; }
.dq-coupling-alert {
  margin-top:.6rem; padding:.5rem .75rem;
  border-radius:8px; font-size:.78rem; line-height:1.55;
  border:1px solid rgba(230,126,34,.4); background:rgba(230,126,34,.09);
}

/* Adaptation note */
.adaptation-note {
  background: var(--brand-purple-light);
  border: 1.5px solid var(--brand-purple-mid);
  border-radius: 8px;
  padding: 0.85rem 1rem;
  font-size: 0.82rem;
  line-height: 1.65;
  margin-bottom: 1rem;
  color: var(--brand-purple-dark);
}

.adaptation-note strong { display: block; margin-bottom: 0.3rem; color: var(--brand-purple); }

/* ── HR DRIFT & DFA BLOCKS ── */
.drift-block {
  border: 1.5px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 1rem;
}

.drift-header {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  padding: 0.85rem 1rem;
  background: var(--surface2);
  border-bottom: 1px solid var(--border);
}

.drift-num {
  width: 26px; height: 26px;
  border-radius: 50%;
  background: var(--brand-purple);
  color: white;
  font-size: 0.78rem;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
}

.drift-title {
  font-weight: 700;
  font-size: 0.88rem;
  line-height: 1.3;
}

.drift-sub {
  font-size: 0.68rem;
  color: var(--muted);
  font-style: italic;
  margin-top: 0.15rem;
}

.drift-body {
  padding: 1rem;
  font-size: 0.82rem;
  line-height: 1.65;
  color: var(--text);
}

.drift-rules {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0.6rem;
  margin: 0.85rem 0;
}

.drift-rule {
  border-radius: 8px;
  padding: 0.65rem 0.75rem;
}

.drift-rule.ok   { background: var(--z1-light); border: 1px solid var(--z1-border); }
.drift-rule.warn { background: var(--z2-light); border: 1px solid var(--z2-border); }
.drift-rule.bad  { background: var(--z3-light); border: 1px solid var(--z3-border); }

.dr-label {
  font-size: 0.75rem;
  font-weight: 700;
  margin-bottom: 0.3rem;
}

.dr-desc {
  font-size: 0.73rem;
  color: var(--muted);
  line-height: 1.55;
}

.drift-formula {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  background: var(--brand-purple);
  border-radius: 7px;
  padding: 0.55rem 0.9rem;
  margin: 0.85rem 0 0.25rem;
}

.df-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--brand-green);
  white-space: nowrap;
}

.df-val {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.75rem;
  color: white;
}

/* DFA Scale */
.dfa-scale {
  display: flex;
  gap: 0.3rem;
  margin: 0.85rem 0 0.5rem;
  flex-wrap: wrap;
}

.dfa-seg {
  flex: 1;
  min-width: 80px;
  border-radius: 8px;
  padding: 0.55rem 0.6rem;
  text-align: center;
}

.dfa-z1  { background: var(--z1-light); border: 1px solid var(--z1-border); }
.dfa-lt1 { background: var(--brand-purple-light); border: 1px solid var(--brand-purple-mid); }
.dfa-z2  { background: var(--z2-light); border: 1px solid var(--z2-border); }
.dfa-lt2 { background: #fdf2f8; border: 1px solid #fbcfe8; }
.dfa-z3  { background: var(--z3-light); border: 1px solid var(--z3-border); }

.dfa-val {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.72rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.dfa-zone {
  font-size: 0.65rem;
  color: var(--muted);
  line-height: 1.4;
}

/* Summary table */
.drift-summary {
  background: #b91c1c;
  border-radius: 10px;
  padding: 1.1rem;
  margin-top: 0.5rem;
}

.ds-title {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--brand-green-mid);
  margin-bottom: 0.85rem;
}

.ds-rows { display: flex; flex-direction: column; gap: 0.35rem; }

.ds-row {
  display: grid;
  grid-template-columns: 1.5fr 2fr 2fr;
  gap: 0.75rem;
  font-size: 0.75rem;
  color: #ffffff;
  padding: 0.5rem 0.65rem;
  border-radius: 6px;
  line-height: 1.5;
}

.ds-row.ds-head {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--brand-green-mid);
  background: transparent;
  padding-bottom: 0.25rem;
  border-bottom: 1px solid rgba(255,255,255,0.25);
}

.ds-row:not(.ds-head) { background: rgba(255,255,255,.06); }
.ds-row:not(.ds-head):nth-child(even) { background: rgba(255,255,255,.12); }

@media (max-width: 580px) {
  .drift-rules { grid-template-columns: 1fr; }
  .ds-row { grid-template-columns: 1fr; }
  .dfa-scale { flex-direction: column; }
}

/* ── ZONE MONITORING ── */
.mz-alert {
  background: #fff7ed;
  border: 1.5px solid #fed7aa;
  border-left: 4px solid #f97316;
  border-radius: 10px;
  padding: 1rem 1.15rem;
  margin-bottom: 1.25rem;
  font-size: 0.82rem;
  line-height: 1.65;
  color: var(--text);
}

.mz-alert-title {
  font-weight: 700;
  font-size: 0.82rem;
  color: #c2410c;
  margin-bottom: 0.5rem;
}

.mz-map {
  background: #f8fafc;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1rem 1.15rem;
  margin-bottom: 1.25rem;
}

.mz-map-title {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--muted);
  margin-bottom: 0.85rem;
}

.mz-map-rows { display: flex; flex-direction: column; gap: 0.35rem; }

.mz-map-row {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.8rem;
}

.mz-map-cue {
  flex: 0 0 220px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.73rem;
  color: var(--text);
}

.mz-map-arrow { color: var(--muted); flex-shrink: 0; }

.mz-map-zone {
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.18rem 0.65rem;
  border-radius: 20px;
}

.z1-tag  { background: var(--z1-light); color: #15803d; }
.lt1-tag { background: var(--brand-purple-light); color: var(--brand-purple-dark); }
.z2-tag  { background: var(--z2-light); color: #b45309; }
.lt2-tag { background: #fdf2f8; color: #9d174d; }
.z3-tag  { background: var(--z3-light); color: #b91c1c; }

.mz-map-source {
  font-size: 0.68rem;
  color: var(--muted);
  margin-top: 0.75rem;
  padding-top: 0.6rem;
  border-top: 1px solid var(--border);
  line-height: 1.5;
}

.cue-warn {
  background: #fff7ed;
  border-left: 3px solid #f97316;
  padding: 0.4rem 0.6rem;
  border-radius: 0 6px 6px 0;
  font-size: 0.78rem !important;
  margin-top: 0.2rem;
}
.monitor-zones {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.mz-row {
  border-radius: 10px;
  overflow: hidden;
  border: 1.5px solid var(--border);
}

.mz-row.mz-z1  { border-color: var(--z1-border); }
.mz-row.mz-lt1 { border-color: var(--brand-purple-mid); }
.mz-row.mz-z2  { border-color: var(--z2-border); }
.mz-row.mz-z3  { border-color: var(--z3-border); }

.mz-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 1rem;
}

.mz-row.mz-z1  .mz-header { background: #f0fdf4; }
.mz-row.mz-lt1 .mz-header { background: var(--brand-purple-light); }
.mz-row.mz-z2  .mz-header { background: #fffbeb; }
.mz-row.mz-z3  .mz-header { background: #fff1f2; }

.mz-badge {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 0.2rem 0.65rem;
  border-radius: 20px;
  white-space: nowrap;
}

.mz-badge.z1  { background: var(--z1); color: white; }
.mz-badge.lt1 { background: var(--brand-purple); color: white; }
.mz-badge.z2  { background: var(--z2); color: white; }
.mz-badge.z3  { background: var(--z3); color: white; }

.mz-range {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.75rem;
  color: var(--muted);
}

.mz-cues {
  padding: 0.85rem 1rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0.85rem;
  background: var(--surface);
}

.mz-cue-group {}

.mz-cue-title {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.45rem;
}

.mz-cue-items { display: flex; flex-direction: column; gap: 0.3rem; }

.mz-cue-item {
  font-size: 0.78rem;
  line-height: 1.55;
  color: var(--text);
  padding-left: 0.25rem;
}

.mz-note {
  font-size: 0.75rem;
  color: var(--muted);
  line-height: 1.6;
  padding: 0.7rem 1rem;
  background: #f8fafc;
  border-top: 1px solid var(--border);
}

.mz-science-box {
  background: #dc2626;
  border-radius: 10px;
  padding: 1.25rem;
  margin-top: 0.5rem;
  color: #ffffff;
}

.mz-sci-title {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: #ffffff;
  margin-bottom: 1rem;
}

.mz-sci-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

.mz-sci-item {
  font-size: 0.78rem;
  line-height: 1.6;
  color: rgba(255,255,255,0.9);
  padding: 0.75rem;
  background: rgba(255,255,255,.1);
  border-radius: 7px;
  border-left: 3px solid rgba(255,255,255,0.35);
}

.mz-sci-item strong { color: var(--brand-green); display: block; margin-bottom: 0.25rem; }

@media (max-width: 580px) {
  .mz-sci-grid { grid-template-columns: 1fr; }
}

/* ── HIT PROTOCOLS ── */
.hit-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.hit-filter-row {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.filter-pill {
  padding: 0.3rem 0.85rem;
  border-radius: 20px;
  border: 1.5px solid var(--border);
  background: var(--surface2);
  font-size: 0.73rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: all 0.15s;
}
.filter-pill.active, .filter-pill:hover {
  background: var(--brand-purple);
  border-color: var(--brand-purple);
  color: white;
}

.protocols-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.9rem;
}

.proto-card {
  background: var(--surface2);
  border: 1.5px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  transition: box-shadow 0.15s, transform 0.15s;
  cursor: pointer;
  position: relative;
}

.proto-card:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,.1);
  transform: translateY(-2px);
}

.proto-card.selected {
  border-color: var(--brand-purple);
  box-shadow: 0 0 0 3px var(--brand-purple-light);
}

.proto-top {
  padding: 0.85rem 1rem 0.65rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
}

.proto-icon {
  font-size: 1.4rem;
  flex-shrink: 0;
  line-height: 1;
}

.proto-name {
  font-weight: 700;
  font-size: 0.88rem;
  line-height: 1.3;
  margin-bottom: 0.15rem;
}

.proto-author {
  font-size: 0.68rem;
  color: var(--muted);
  font-style: italic;
}

.proto-badges {
  display: flex;
  gap: 0.3rem;
  flex-wrap: wrap;
  margin-top: 0.4rem;
}

.badge {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  padding: 0.12rem 0.45rem;
  border-radius: 20px;
}

.badge-level-beginner { background: #dcfce7; color: #15803d; }
.badge-level-intermediate { background: #fef3c7; color: #b45309; }
.badge-level-advanced { background: #fee2e2; color: #b91c1c; }
.badge-focus-vo2 { background: #ede9fe; color: #7c3aed; }
.badge-focus-threshold { background: #e0f2fe; color: #0369a1; }
.badge-focus-neuromuscular { background: #fce7f3; color: #be185d; }

.proto-body {
  padding: 0.85rem 1rem;
}

.proto-formula {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.78rem;
  font-weight: 500;
  background: var(--brand-purple);
  color: var(--brand-green);
  border-radius: 6px;
  padding: 0.45rem 0.75rem;
  margin-bottom: 0.75rem;
  letter-spacing: 0.3px;
}

.proto-blocks {
  display: flex;
  gap: 0.35rem;
  align-items: stretch;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

.proto-block {
  flex: 1;
  min-width: 0;
  border-radius: 6px;
  padding: 0.4rem 0.5rem;
  font-size: 0.7rem;
  text-align: center;
}

.pb-work { background: #fee2e2; border: 1px solid var(--z3-border); }
.pb-rest  { background: #dcfce7; border: 1px solid var(--z1-border); }
.pb-total { background: #e0f2fe; border: 1px solid #7dd3fc; }

.proto-block .pb-label { font-weight: 700; margin-bottom: 0.1rem; font-size: 0.65rem; text-transform: uppercase; letter-spacing: 0.4px; color: var(--muted); }
.proto-block .pb-val   { font-family: 'IBM Plex Mono', monospace; font-weight: 500; font-size: 0.78rem; }

.proto-desc {
  font-size: 0.78rem;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 0.6rem;
}

.proto-intensities {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.6rem;
}

.intensity-tag {
  font-size: 0.7rem;
  padding: 0.18rem 0.55rem;
  border-radius: 5px;
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 500;
}

.it-work { background: var(--z3-light); color: var(--z3); }
.it-rest { background: var(--z1-light); color: var(--z1); }
.it-hr   { background: var(--brand-purple-light); color: var(--brand-purple-dark); }

.proto-evidence {
  font-size: 0.7rem;
  color: var(--muted);
  border-top: 1px solid var(--border);
  padding-top: 0.55rem;
  margin-top: 0.5rem;
  line-height: 1.55;
}

.proto-evidence strong { color: var(--text); }

.selected-check {
  position: absolute;
  top: 0.55rem;
  right: 0.55rem;
  width: 20px; height: 20px;
  background: var(--brand-purple);
  border-radius: 50%;
  display: none;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 0.7rem;
}

.proto-card.selected .selected-check { display: flex; }

.hit-week-plan {
  margin-top: 1.25rem;
  padding: 1rem;
  background: #dc2626;
  border-radius: 10px;
  color: #ffffff;
}

.hwp-title {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.85);
  margin-bottom: 0.75rem;
}

.hwp-rows { display: flex; flex-direction: column; gap: 0.5rem; }

.hwp-row {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  font-size: 0.82rem;
  padding: 0.45rem 0.6rem;
  border-radius: 6px;
  background: rgba(255,255,255,.08);
}

.hwp-session {
  width: 80px;
  flex-shrink: 0;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.72rem;
  font-weight: 500;
}

.hwp-session.s-hard { color: #d4a0f5; }
.hwp-session.s-easy { color: var(--brand-green); }

.hwp-detail { font-size: 0.78rem; line-height: 1.5; color: #94a3b8; }
.hwp-detail strong { color: #e2e8f0; }

/* ── RESPONSIVE ── */
@media (max-width: 580px) {
  .form-grid,
  .zones-grid,
  .compliance-grid,
  .protocols-grid { grid-template-columns: 1fr; }
  .btn-row { flex-direction: column; align-items: stretch; }
  .btn { justify-content: center; }
  main { padding: 1rem 1rem 3rem; }
}

/* ═══════════════════════════════════════════
   PLANNING HORIZON  (Step 1)
═══════════════════════════════════════════ */
.horizon-opts { display:flex; flex-direction:column; gap:.6rem; margin-bottom:.9rem; }
.horizon-opt {
  display:flex; align-items:flex-start; gap:.75rem;
  border:1.5px solid var(--border); border-radius:10px;
  padding:.75rem .9rem; cursor:pointer;
  transition:border-color .18s, background .18s;
}
.horizon-opt:hover { border-color:var(--brand-purple); background:rgba(107,63,160,.04); }
.horizon-opt.selected { border-color:var(--brand-purple); background:rgba(107,63,160,.07); }
.horizon-opt input[type=radio] { margin-top:.2rem; accent-color:var(--brand-purple); flex-shrink:0; }
.horizon-opt-body strong { display:block; font-size:.88rem; margin-bottom:.2rem; }
.horizon-opt-body span { font-size:.78rem; color:var(--muted); line-height:1.5; }
.horizon-cycle-inputs {
  display:none; margin-top:.75rem;
  padding:.85rem; background:var(--bg-card);
  border:1px solid var(--border); border-radius:9px;
}
.horizon-cycle-inputs.open { display:block; }

/* ═══════════════════════════════════════════
   MID-WEEK STATUS CARD
═══════════════════════════════════════════ */
.mws-card { }
.mws-header {
  display:flex; align-items:center; gap:.65rem; margin-bottom:.9rem;
}
.mws-status-badge {
  display:inline-flex; align-items:center; gap:.4rem;
  padding:.3rem .85rem; border-radius:20px;
  font-size:.78rem; font-weight:700; flex-shrink:0;
}
.mws-ok   { background:rgba(168,200,0,.15);  color:#5a7800;   border:1px solid rgba(168,200,0,.5); }
.mws-warn { background:rgba(230,126,34,.12); color:#b35c00;   border:1px solid rgba(230,126,34,.4); }
.mws-alert{ background:rgba(192,57,43,.10);  color:#8b1a0e;   border:1px solid rgba(192,57,43,.3); }
.mws-days { font-size:.75rem; color:var(--muted); margin-left:auto; }

.mws-section-title {
  font-size:.72rem; font-weight:700; text-transform:uppercase;
  letter-spacing:.05em; color:var(--muted); margin:.85rem 0 .45rem;
}
.mws-zone-rows { display:flex; flex-direction:column; gap:.35rem; }
.mws-zone-row {
  display:grid; grid-template-columns:90px 1fr auto;
  align-items:center; gap:.5rem; font-size:.8rem;
}
.mws-zone-label { font-weight:600; }
.mws-zone-bar-wrap { height:8px; background:var(--border); border-radius:4px; overflow:hidden; }
.mws-zone-bar     { height:100%; border-radius:4px; transition:width .4s ease; }
.mws-zone-val     { font-size:.75rem; color:var(--muted); white-space:nowrap; text-align:right; min-width:80px; }

.mws-remain-grid {
  display:grid; grid-template-columns:repeat(auto-fit, minmax(130px,1fr));
  gap:.55rem; margin-top:.45rem;
}
.mws-remain-box {
  background:var(--bg-main); border:1px solid var(--border);
  border-radius:9px; padding:.6rem .75rem;
}
.mws-remain-label { font-size:.69rem; color:var(--muted); margin-bottom:.2rem; }
.mws-remain-val   { font-size:1rem; font-weight:700; color:var(--text-main); }
.mws-remain-sub   { font-size:.69rem; color:var(--muted); margin-top:.1rem; }

.mws-flags { display:flex; flex-direction:column; gap:.4rem; margin-top:.45rem; }
.mws-flag {
  display:flex; gap:.5rem; align-items:flex-start;
  font-size:.78rem; line-height:1.5; padding:.45rem .65rem;
  border-radius:8px;
}
.mws-flag-warn { background:rgba(230,126,34,.09); border:1px solid rgba(230,126,34,.3); }
.mws-flag-info { background:rgba(107,63,160,.07); border:1px solid rgba(107,63,160,.22); }
.mws-flag-ok   { background:rgba(168,200,0,.09);  border:1px solid rgba(168,200,0,.35); }
.mws-flag-icon { flex-shrink:0; font-size:.9rem; }

/* ═══════════════════════════════════════════
   NEW LT TEST MODAL
═══════════════════════════════════════════ */
.lt-modal-overlay {
  display:none; position:fixed; inset:0;
  background:rgba(0,0,0,.45); z-index:2000;
  align-items:center; justify-content:center;
  padding:1rem;
}
.lt-modal-overlay.open { display:flex; }
.lt-modal {
  background:var(--bg-card); border-radius:14px;
  padding:1.5rem; max-width:480px; width:100%;
  box-shadow:0 12px 40px rgba(0,0,0,.25);
  max-height:90vh; overflow-y:auto;
}
.lt-modal-title {
  font-size:1rem; font-weight:700; color:var(--text-main);
  margin-bottom:.3rem;
}
.lt-modal-sub { font-size:.78rem; color:var(--muted); margin-bottom:1.1rem; line-height:1.55; }
.lt-stage {
  border:1px solid var(--border); border-radius:9px;
  padding:.85rem .9rem; margin-bottom:.85rem;
}
.lt-stage-num {
  display:inline-flex; align-items:center; justify-content:center;
  width:1.4rem; height:1.4rem; border-radius:50%;
  background:var(--brand-purple); color:white;
  font-size:.7rem; font-weight:700; margin-right:.45rem;
}
.lt-stage-title { font-size:.84rem; font-weight:700; }
.lt-stage-body { margin-top:.6rem; font-size:.79rem; color:var(--muted); line-height:1.55; }
.lt-upload-area {
  border:2px dashed var(--border); border-radius:8px;
  padding:.85rem; text-align:center; cursor:pointer;
  font-size:.79rem; color:var(--muted); margin-top:.55rem;
  transition:border-color .18s, background .18s;
}
.lt-upload-area:hover { border-color:var(--brand-purple); background:rgba(107,63,160,.04); }
.lt-upload-area.loaded { border-color:var(--brand-green); background:rgba(168,200,0,.06); color:var(--text-main); }
.lt-modal-btns { display:flex; gap:.65rem; margin-top:1rem; }

/* ── Return-visit restore widget ── */
.restore-upload-area {
  display:flex; align-items:center; gap:.85rem; flex-wrap:wrap;
  padding:.75rem 1rem; border-radius:10px;
  border:1.5px dashed var(--border);
  background:var(--surface2); cursor:pointer;
  transition:border-color .18s, background .18s;
}
.restore-upload-area:hover { border-color:var(--brand-purple); background:rgba(107,63,160,.04); }
.restore-banner {
  display:none; align-items:flex-start; gap:.6rem;
  padding:.65rem .9rem; border-radius:8px; font-size:.8rem; line-height:1.55;
  margin-top:.65rem;
}
.restore-ok  { background:rgba(168,200,0,.1);  border:1px solid rgba(168,200,0,.4);  color:var(--text-main); }
.restore-err { background:rgba(192,57,43,.08); border:1px solid rgba(192,57,43,.35); color:#c0392b; }

/* ═══════════════════════════════════════════
   PERIODISATION BLOCK PLANNER  (Step 1 + Step 3)
═══════════════════════════════════════════ */
.period-toggle-btn {
  display: flex; align-items: center; gap: .55rem;
  background: none; border: 1.5px solid var(--brand-purple);
  color: var(--brand-purple); border-radius: 8px;
  padding: .5rem 1rem; font-size: .82rem; font-weight: 600;
  cursor: pointer; transition: all .18s;
}
.period-toggle-btn:hover { background: var(--brand-purple-light); }
.period-toggle-btn .pt-arrow { transition: transform .25s; font-size:.7rem; }
.period-toggle-btn.open .pt-arrow { transform: rotate(180deg); }

.period-planner-wrap {
  display: none; margin-top: 1.1rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius); overflow: hidden;
}
.period-planner-wrap.open { display: block; animation: fadeUp .22s ease; }

.pp-header {
  background: var(--brand-purple-light);
  padding: .75rem 1.1rem;
  display: flex; align-items: flex-start; gap: 1.2rem; flex-wrap: wrap;
}
.pp-field { display: flex; flex-direction: column; gap: .25rem; }
.pp-field label { font-size: .7rem; font-weight: 700; color: var(--brand-purple); text-transform: uppercase; letter-spacing: .4px; }
.pp-field input, .pp-field select {
  padding: .35rem .6rem; border: 1.5px solid var(--brand-purple-mid);
  border-radius: 6px; font-size: .8rem; color: var(--text);
  background: white; font-family: inherit;
}
.pp-field input:focus, .pp-field select:focus { outline: none; border-color: var(--brand-purple); }

.pp-generate-btn {
  align-self: flex-end; background: var(--brand-purple);
  color: white; border: none; border-radius: 7px;
  padding: .42rem 1rem; font-size: .8rem; font-weight: 700;
  cursor: pointer; transition: background .15s; white-space: nowrap;
}
.pp-generate-btn:hover { background: var(--brand-purple-dark); }

/* Timeline */
.pp-body { padding: 1rem 1.1rem; }

.pp-science-note {
  font-size: .73rem; color: var(--muted); line-height: 1.6;
  background: var(--surface2); border-radius: 7px;
  padding: .6rem .85rem; margin-bottom: 1rem;
  border-left: 3px solid var(--brand-green);
}

.pp-legend {
  display: flex; gap: .85rem; flex-wrap: wrap;
  margin-bottom: .85rem;
}
.pp-leg-item { display: flex; align-items: center; gap: .35rem; font-size: .72rem; color: var(--text); font-weight: 600; }
.pp-leg-dot { width: 12px; height: 12px; border-radius: 3px; flex-shrink: 0; }

.pp-timeline {
  display: grid; gap: 4px;
}
.pp-week-row {
  display: grid; grid-template-columns: 52px 1fr 78px 80px 76px;
  align-items: center; gap: 6px; min-height: 30px;
}
.pp-week-row.header { font-size: .66rem; font-weight: 700; color: var(--muted);
  text-transform: uppercase; letter-spacing: .4px; border-bottom: 1.5px solid var(--border); padding-bottom: 4px; }
.pp-wnum  { font-size: .72rem; font-weight: 700; color: var(--muted); font-family: 'IBM Plex Mono', monospace; }
.pp-block-bar {
  border-radius: 5px; height: 22px;
  display: flex; align-items: center; padding: 0 8px;
  font-size: .68rem; font-weight: 700; color: white; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis;
}
.pp-block-accum   { background: #2d7d32; }
.pp-block-transm  { background: #b45309; }
.pp-block-real    { background: #1565c0; }
.pp-block-deload  { background: #6b3fa0; }
.pp-vol  { font-size: .75rem; font-weight: 700; color: var(--text); font-family: 'IBM Plex Mono', monospace; text-align: right; }
.pp-acwr { font-size: .72rem; font-weight: 700; font-family: 'IBM Plex Mono', monospace; text-align: center; }
.pp-acwr.ok   { color: #2d7d32; }
.pp-acwr.warn { color: #b45309; }
.pp-acwr.bad  { color: #b91c1c; }
.pp-week-row.current-week { background: var(--brand-green-light); border-radius: 6px; }
.pp-phase-badge { font-size: .65rem; font-weight: 700; color: var(--muted); text-align: center; }

/* Week prescription expand button */
.pp-expand-btn {
  background: none; border: none; cursor: pointer;
  font-size: .65rem; font-weight: 700; color: var(--brand-purple);
  padding: 2px 5px; border-radius: 4px; white-space: nowrap;
  transition: background .15s;
}
.pp-expand-btn:hover { background: var(--brand-purple-light); }

/* Per-week prescription panel */
.pp-prescription {
  display: none;
  grid-column: 1 / -1;
  background: var(--surface2);
  border: 1.5px solid var(--border);
  border-radius: 8px;
  padding: .75rem 1rem;
  margin: 2px 0 4px;
  font-size: .75rem;
  animation: fadeUp .18s ease;
}
.pp-prescription.open { display: block; }

.pp-rx-top {
  display: flex; gap: .75rem; flex-wrap: wrap; align-items: flex-start;
  margin-bottom: .65rem;
}
.pp-rx-badge {
  font-size: .65rem; font-weight: 800; padding: .2rem .55rem;
  border-radius: 20px; white-space: nowrap;
}
.pp-rx-badge.accum  { background: #e8f5e9; color: #2d7d32; border: 1px solid #a5d6a7; }
.pp-rx-badge.transm { background: #fff3e0; color: #b45309; border: 1px solid #ffcc80; }
.pp-rx-badge.real   { background: #e3f2fd; color: #1565c0; border: 1px solid #90caf9; }
.pp-rx-badge.deload { background: var(--brand-purple-light); color: var(--brand-purple); border: 1px solid var(--brand-purple-mid); }

.pp-rx-label { font-size: .72rem; color: var(--muted); line-height: 1.5; }

.pp-rx-zones {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 6px; margin-bottom: .65rem;
}
.pp-rx-zone {
  border-radius: 6px; padding: .35rem .55rem;
  font-size: .7rem; line-height: 1.4;
}
.pp-rx-zone .rxz-val { font-size: 1rem; font-weight: 800; font-family: 'IBM Plex Mono', monospace; }
.pp-rx-zone .rxz-lbl { font-weight: 700; margin-bottom: 2px; }
.pp-rx-zone.z1 { background: var(--z1-light); border: 1px solid var(--z1-border); color: #1a3a00; }
.pp-rx-zone.z2 { background: var(--z2-light); border: 1px solid var(--z2-border); color: #4a2800; }
.pp-rx-zone.z3 { background: var(--z3-light); border: 1px solid var(--z3-border); color: #5c0000; }

.pp-rx-sessions {
  display: flex; gap: .5rem; flex-wrap: wrap; margin-bottom: .65rem;
}
.pp-rx-session-pill {
  font-size: .68rem; font-weight: 700; padding: .2rem .6rem;
  border-radius: 20px; display: flex; align-items: center; gap: .3rem;
}
.pp-rx-session-pill.z1-pill  { background: var(--z1-light); color: var(--z1); border: 1px solid var(--z1-border); }
.pp-rx-session-pill.thr-pill { background: var(--z2-light); color: #78350f; border: 1px solid var(--z2-border); }
.pp-rx-session-pill.z3-pill  { background: var(--z3-light); color: var(--z3); border: 1px solid var(--z3-border); }

.pp-rx-dist-bar { display: flex; height: 8px; border-radius: 4px; overflow: hidden; margin-bottom: .65rem; }
.pp-rx-dist-bar .db-z1 { background: var(--z1); }
.pp-rx-dist-bar .db-z2 { background: var(--z2); }
.pp-rx-dist-bar .db-z3 { background: var(--z3); }

.pp-rx-rationale {
  font-size: .72rem; color: var(--muted); line-height: 1.65;
  border-top: 1px solid var(--border); padding-top: .55rem;
}
.pp-rx-rationale strong { color: var(--text); }

/* Periodisation Excel download */
.pp-dl-area {
  margin-top: 1.1rem;
  border: 1.5px solid var(--brand-green);
  border-radius: 9px;
  padding: .85rem 1rem;
  background: var(--brand-green-light);
}
.pp-dl-title {
  font-size: .78rem; font-weight: 800; color: var(--brand-purple);
  margin-bottom: .55rem; display: flex; align-items: center; gap: .4rem;
}
.pp-dl-desc {
  font-size: .72rem; color: var(--muted); margin-bottom: .75rem; line-height: 1.6;
}
.pp-dl-options {
  display: flex; gap: .55rem; flex-wrap: wrap; margin-bottom: .75rem;
}
.pp-dl-opt {
  flex: 1; min-width: 140px;
  border: 2px solid var(--border); border-radius: 8px;
  background: white; padding: .5rem .7rem;
  cursor: pointer; transition: all .15s; text-align: left;
  font-family: inherit;
}
.pp-dl-opt:hover { border-color: var(--brand-purple); background: var(--brand-purple-light); }
.pp-dl-opt.selected { border-color: var(--brand-purple); background: var(--brand-purple-light); }
.pp-dl-opt .opt-icon { font-size: 1rem; }
.pp-dl-opt .opt-title { font-size: .75rem; font-weight: 800; color: var(--brand-purple); display: block; margin-top: 2px; }
.pp-dl-opt .opt-sub   { font-size: .65rem; color: var(--muted); line-height: 1.4; display: block; margin-top: 2px; }
.pp-dl-btn {
  background: var(--brand-purple); color: white;
  border: none; border-radius: 7px; padding: .45rem 1.1rem;
  font-size: .8rem; font-weight: 700; cursor: pointer;
  font-family: inherit; transition: background .15s;
  display: flex; align-items: center; gap: .4rem;
}
.pp-dl-btn:hover { background: var(--brand-purple-dark); }
.pp-dl-btn:disabled { opacity: .5; cursor: not-allowed; }

/* ── Plan-change proposal modal ── */
.pc-overlay {
  position: fixed; inset: 0; background: rgba(26,18,48,.55);
  z-index: 9000; display: flex; align-items: center; justify-content: center;
  padding: 1rem; animation: fadeUp .2s ease;
}
.pc-modal {
  background: white; border-radius: 14px; width: 100%; max-width: 640px;
  max-height: 90vh; overflow-y: auto;
  box-shadow: 0 8px 40px rgba(107,63,160,.35);
  padding: 1.5rem 1.5rem 1.25rem;
}
.pc-modal-title {
  font-size: 1rem; font-weight: 800; color: var(--brand-purple);
  margin-bottom: .3rem; display: flex; align-items: center; gap: .5rem;
}
.pc-modal-sub {
  font-size: .75rem; color: var(--muted); line-height: 1.6; margin-bottom: 1rem;
  padding-bottom: .85rem; border-bottom: 1.5px solid var(--border);
}
.pc-context {
  display: flex; gap: .4rem; flex-wrap: wrap; margin-bottom: .85rem;
}
.pc-ctx-pill {
  font-size: .68rem; font-weight: 700; padding: .2rem .6rem;
  border-radius: 20px; background: var(--brand-purple-light);
  color: var(--brand-purple); border: 1px solid var(--brand-purple-mid);
}
.pc-change-list {
  display: flex; flex-direction: column; gap: .55rem; margin-bottom: 1rem;
}
.pc-change-card {
  border: 1.5px solid var(--border); border-radius: 9px;
  padding: .65rem .85rem;
  display: grid; grid-template-columns: 1fr auto;
  align-items: start; gap: .75rem;
  transition: border-color .15s, background .15s;
}
.pc-change-card.accepted  { border-color: var(--brand-green); background: var(--brand-green-light); }
.pc-change-card.ignored   { border-color: var(--border); background: var(--surface2); opacity: .65; }
.pc-change-header {
  font-size: .78rem; font-weight: 800; color: var(--text);
  display: flex; align-items: center; gap: .4rem; margin-bottom: .2rem;
}
.pc-change-type {
  font-size: .62rem; font-weight: 800; padding: .15rem .45rem;
  border-radius: 20px; text-transform: uppercase; letter-spacing: .3px;
}
.pc-type-volume   { background: #e8f5e9; color: #2d7d32; }
.pc-type-intensity{ background: #fff3e0; color: #b45309; }
.pc-type-deload   { background: var(--brand-purple-light); color: var(--brand-purple); }
.pc-type-retest   { background: #e3f2fd; color: #1565c0; }
.pc-type-zones    { background: #fce4ec; color: #c62828; }
.pc-change-body   { font-size: .73rem; color: var(--muted); line-height: 1.6; }
.pc-change-evidence { font-size: .67rem; color: var(--muted); margin-top: .25rem; font-style: italic; }
.pc-toggle-wrap   { display: flex; flex-direction: column; gap: .3rem; align-items: flex-end; flex-shrink: 0; }
.pc-toggle-btn {
  font-size: .7rem; font-weight: 700; border-radius: 6px; padding: .25rem .65rem;
  cursor: pointer; border: 1.5px solid; font-family: inherit; transition: all .15s;
  white-space: nowrap;
}
.pc-accept-btn { border-color: var(--brand-green); color: var(--brand-green-dark); background: white; }
.pc-accept-btn.active { background: var(--brand-green); color: white; }
.pc-ignore-btn { border-color: var(--border); color: var(--muted); background: white; }
.pc-ignore-btn.active { background: var(--muted); color: white; }
.pc-footer {
  display: flex; gap: .65rem; justify-content: flex-end;
  border-top: 1.5px solid var(--border); padding-top: .85rem;
}
.pc-apply-btn {
  background: var(--brand-purple); color: white; border: none;
  border-radius: 8px; padding: .5rem 1.25rem; font-size: .85rem;
  font-weight: 700; cursor: pointer; font-family: inherit;
}
.pc-apply-btn:hover { background: var(--brand-purple-dark); }
.pc-cancel-btn {
  background: white; color: var(--muted); border: 1.5px solid var(--border);
  border-radius: 8px; padding: .5rem 1rem; font-size: .82rem;
  font-weight: 600; cursor: pointer; font-family: inherit;
}
.pc-source-tag {
  font-size: .63rem; color: var(--muted); margin-top: .2rem;
  display: flex; align-items: center; gap: .3rem;
}
.pc-no-changes {
  text-align: center; padding: 1.2rem; font-size: .8rem;
  color: var(--muted); background: var(--surface2); border-radius: 8px;
}


/* ACWR card in Step 3 */
.acwr-card-body { padding: .85rem 0 .25rem; }

.acwr-gauge-wrap {
  display: flex; align-items: center; gap: 1rem;
  margin-bottom: 1rem;
}
.acwr-gauge {
  flex: 1; height: 20px; border-radius: 20px;
  background: linear-gradient(to right, #d1fae5 0%, #a8c800 30%, #fef3c7 60%, #fee2e2 80%, #fca5a5 100%);
  position: relative; overflow: visible;
}
.acwr-needle {
  position: absolute; top: 50%; transform: translate(-50%, -50%);
  width: 12px; height: 28px; border-radius: 3px;
  background: var(--text); box-shadow: 0 1px 4px rgba(0,0,0,.3);
  transition: left .5s cubic-bezier(.34,1.56,.64,1);
}
.acwr-val-big {
  font-size: 2rem; font-weight: 800; font-family: 'IBM Plex Mono', monospace;
  line-height: 1; min-width: 90px; text-align: center;
}
.acwr-val-big.acwr-ok   { color: #2d7d32; }
.acwr-val-big.acwr-warn { color: #b45309; }
.acwr-val-big.acwr-bad  { color: #b91c1c; }

.acwr-zone-labels {
  display: flex; justify-content: space-between;
  font-size: .63rem; color: var(--muted); margin-top: 2px; padding: 0 2px;
}

.acwr-history {
  display: grid; gap: 4px; margin-top: .85rem;
}
.acwr-hist-row {
  display: grid; grid-template-columns: 52px 1fr 72px;
  align-items: center; gap: 6px;
}
.acwr-hist-label { font-size: .7rem; color: var(--muted); font-weight: 600; }
.acwr-hist-bar-wrap { background: var(--surface2); border-radius: 4px; height: 14px; overflow: hidden; position: relative; }
.acwr-hist-bar { height: 100%; border-radius: 4px; transition: width .4s ease; min-width: 2px; }
.acwr-hist-val { font-size: .7rem; font-family: 'IBM Plex Mono', monospace; font-weight: 700; text-align: right; }

.acwr-interpretation {
  margin-top: .85rem; padding: .65rem .85rem;
  border-radius: 8px; font-size: .78rem; line-height: 1.6; font-weight: 500;
}
.acwr-interpretation.ok   { background: #f0fdf4; border-left: 3px solid #2d7d32; color: #14532d; }
.acwr-interpretation.warn { background: #fffbeb; border-left: 3px solid #b45309; color: #78350f; }
.acwr-interpretation.bad  { background: #fef2f2; border-left: 3px solid #b91c1c; color: #7f1d1d; }

.trimp-detail {
  display: flex; gap: .65rem; flex-wrap: wrap; margin-top: .65rem;
}
.trimp-pill {
  font-size: .7rem; font-weight: 700; padding: .25rem .65rem;
  border-radius: 20px; font-family: 'IBM Plex Mono', monospace;
}
.trimp-pill.z1 { background: var(--z1-light); color: var(--z1); border: 1px solid var(--z1-border); }
.trimp-pill.z2 { background: var(--z2-light); color: var(--z2); border: 1px solid var(--z2-border); }
.trimp-pill.z3 { background: var(--z3-light); color: var(--z3); border: 1px solid var(--z3-border); }
.trimp-pill.total { background: var(--brand-purple-light); color: var(--brand-purple); border: 1px solid var(--brand-purple-mid); }

/* ── HOW TO USE ── */
.how-to-wrap {
  max-width: 1280px; margin: 0 auto 1.25rem; padding: 0 1.5rem;
}
.how-to-card {
  background: var(--card-bg);
  border: 1.5px solid var(--brand-purple-mid);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(107,63,160,.07);
}
.how-to-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: .85rem 1.2rem; cursor: pointer;
  background: linear-gradient(90deg, rgba(107,63,160,.06) 0%, transparent 100%);
  user-select: none;
}
.how-to-header:hover { background: linear-gradient(90deg, rgba(107,63,160,.11) 0%, transparent 100%); }
.how-to-header h3 {
  margin: 0; font-size: .92rem; font-weight: 700;
  color: var(--brand-purple); letter-spacing: .01em;
  display: flex; align-items: center; gap: .5rem;
}
.how-to-chevron {
  font-size: .8rem; color: var(--brand-purple);
  transition: transform .25s ease;
}
.how-to-chevron.open { transform: rotate(180deg); }
.how-to-body {
  display: none; padding: 1rem 1.2rem 1.2rem;
  border-top: 1px solid var(--border-color);
}
.how-to-body.open { display: block; }
.how-to-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: .8rem; margin: 0 0 .9rem;
}
.how-to-step {
  background: var(--bg-page);
  border: 1px solid var(--border-color);
  border-radius: 10px; padding: .75rem .9rem;
}
.how-to-step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 1.5rem; height: 1.5rem; border-radius: 50%;
  background: var(--brand-purple); color: #fff;
  font-size: .72rem; font-weight: 800; margin-bottom: .4rem;
}
.how-to-step h4 { margin: 0 0 .25rem; font-size: .8rem; font-weight: 700; color: var(--text-main); }
.how-to-step p { margin: 0; font-size: .75rem; color: var(--text-muted); line-height: 1.45; }
.how-to-tips {
  background: rgba(168,200,0,.08); border: 1px solid rgba(168,200,0,.3);
  border-radius: 8px; padding: .65rem .85rem;
}
.how-to-tips p { margin: 0; font-size: .75rem; color: var(--text-muted); line-height: 1.5; }
.how-to-tips strong { color: var(--brand-green); }

/* ── 3-ZONE MODEL EXPLAINER ── */
.zm-card {
  background: var(--card-bg);
  border: 1.5px solid var(--brand-purple-mid);
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 1rem;
}
.zm-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: .8rem 1.1rem; cursor: pointer; user-select: none;
  background: linear-gradient(90deg, rgba(107,63,160,.07) 0%, transparent 100%);
}
.zm-header:hover { background: linear-gradient(90deg, rgba(107,63,160,.13) 0%, transparent 100%); }
.zm-header h3 {
  margin: 0; font-size: .88rem; font-weight: 700;
  color: var(--brand-purple); display: flex; align-items: center; gap: .5rem;
}
.zm-chevron { font-size: .78rem; color: var(--brand-purple); transition: transform .25s ease; }
.zm-chevron.open { transform: rotate(180deg); }
.zm-body {
  display: none; padding: 1rem 1.1rem 1.2rem;
  border-top: 1px solid var(--border-color);
  font-size: .8rem; line-height: 1.65; color: var(--text-muted);
}
.zm-body.open { display: block; }
.zm-body h4 {
  font-size: .8rem; font-weight: 700; color: var(--text-main);
  margin: .9rem 0 .3rem;
}
.zm-body h4:first-child { margin-top: 0; }
.zm-body p { margin: 0 0 .5rem; }
.zm-body strong { color: var(--text-main); }
.zm-compare {
  display: grid; grid-template-columns: 1fr 1fr 1fr; gap: .5rem;
  margin: .75rem 0;
}
.zm-col { background: var(--bg-page); border: 1px solid var(--border-color); border-radius: 8px; padding: .6rem .75rem; }
.zm-col-head {
  font-size: .72rem; font-weight: 800; text-transform: uppercase;
  letter-spacing: .05em; margin-bottom: .4rem;
}
.zm-col-head.c3 { color: var(--brand-purple); }
.zm-col-head.c5 { color: var(--z2); }
.zm-col-head.c7 { color: #64748b; }
.zm-col ul { margin: 0; padding-left: 1rem; }
.zm-col li { margin-bottom: .2rem; }
.zm-map {
  background: rgba(107,63,160,.06);
  border: 1px solid var(--brand-purple-mid);
  border-radius: 9px; padding: .65rem .85rem;
  margin: .75rem 0 .4rem;
}
.zm-map table { width: 100%; border-collapse: collapse; font-size: .77rem; }
.zm-map th {
  text-align: left; font-weight: 700; color: var(--text-main);
  padding: .25rem .4rem; border-bottom: 1px solid var(--border-color);
  font-size: .72rem; text-transform: uppercase; letter-spacing: .04em;
}
.zm-map td { padding: .28rem .4rem; vertical-align: top; }
.zm-map tr:not(:last-child) td { border-bottom: 1px solid rgba(0,0,0,.05); }
.zm-map .z1c { color: var(--z1); font-weight: 700; }
.zm-map .z2c { color: var(--z2); font-weight: 700; }
.zm-map .z3c { color: var(--z3); font-weight: 700; }
@media (max-width:540px) { .zm-compare { grid-template-columns: 1fr; } }


.storage-notice {
  max-width: 1280px; margin: 0 auto .9rem; padding: 0 1.5rem;
}
.storage-notice-inner {
  display: flex; align-items: flex-start; gap: .65rem;
  background: rgba(168,200,0,.08);
  border: 1px solid rgba(168,200,0,.35);
  border-radius: 10px;
  padding: .65rem .9rem;
  font-size: .75rem; color: var(--text-muted); line-height: 1.55;
}
.storage-notice-inner .sn-icon { font-size: 1rem; flex-shrink: 0; margin-top: .05rem; }
.storage-notice-inner strong { color: var(--text-main); }
.storage-notice-inner a { color: var(--brand-purple); text-decoration: none; }
.storage-notice-inner a:hover { text-decoration: underline; }

/* ── LEGAL FOOTER ── */
.legal-footer {
  max-width: 1280px; margin: 1.5rem auto 2rem; padding: 0 1.5rem;
  display: flex; flex-direction: column; gap: .6rem;
}
.legal-section {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 11px; overflow: hidden;
}
.legal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: .7rem 1rem; cursor: pointer; user-select: none;
}
.legal-header:hover { background: rgba(107,63,160,.04); }
.legal-header h4 {
  margin: 0; font-size: .8rem; font-weight: 700;
  color: var(--text-muted); letter-spacing: .04em; text-transform: uppercase;
  display: flex; align-items: center; gap: .4rem;
}
.legal-chevron {
  font-size: .72rem; color: var(--text-muted);
  transition: transform .25s ease;
}
.legal-chevron.open { transform: rotate(180deg); }
.legal-body {
  display: none; padding: .9rem 1rem 1rem;
  border-top: 1px solid var(--border-color);
  font-size: .76rem; color: var(--text-muted); line-height: 1.65;
}
.legal-body.open { display: block; }
.legal-body h5 { margin: .7rem 0 .25rem; font-size: .77rem; font-weight: 700; color: var(--text-main); }
.legal-body p { margin: 0 0 .5rem; }
.legal-body ul { margin: .3rem 0 .5rem; padding-left: 1.1rem; }
.legal-body li { margin-bottom: .2rem; }
.legal-body a { color: var(--brand-purple); text-decoration: none; }
.legal-body a:hover { text-decoration: underline; }
.legal-divider { border: none; border-top: 1px solid var(--border-color); margin: .6rem 0; }
