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

:root {
  --bg: #dbe4d2;
  --bg-deep: #cbd8c0;
  --surface: rgba(252, 249, 241, 0.94);
  --surface-strong: #fffdf7;
  --surface-soft: #f1ecdf;
  --line: rgba(74, 88, 67, 0.12);
  --line-strong: rgba(74, 88, 67, 0.2);
  --text: #283226;
  --muted: #687466;
  --muted-strong: #465243;
  --accent: #7f9777;
  --accent-strong: #546a50;
  --accent-soft: #e4eddb;
  --accent-soft-strong: #d0ddc5;
  --warn: #b6864b;
  --danger: #c5746a;
  --shadow: 0 24px 80px rgba(78, 91, 63, 0.18);
  --radius-xl: 30px;
  --radius-lg: 24px;
  --radius: 18px;
  --radius-sm: 12px;
  --font-body: "Avenir Next", "Segoe UI", "Trebuchet MS", sans-serif;
  --font-display: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
  --night-bg: #2e3a35;
  --afternoon-bg: #e8dfc8;
  --morning-bg: #d0ddc5;
}

html {
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.85), transparent 38%),
    radial-gradient(circle at top right, rgba(182, 206, 171, 0.42), transparent 32%),
    linear-gradient(180deg, var(--bg) 0%, #e6ece0 100%);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  padding: 28px 16px 40px;
  position: relative;
}

body::before,
body::after {
  content: "";
  position: fixed;
  border-radius: 999px;
  filter: blur(12px);
  pointer-events: none;
  opacity: 0.65;
  z-index: 0;
}

body::before {
  width: 320px;
  height: 320px;
  left: -120px;
  top: -60px;
  background: radial-gradient(circle, rgba(231, 238, 223, 0.95), transparent 70%);
}

body::after {
  width: 380px;
  height: 380px;
  right: -110px;
  bottom: -120px;
  background: radial-gradient(circle, rgba(196, 213, 186, 0.7), transparent 72%);
}

a {
  color: inherit;
}

button,
input,
textarea,
select {
  font: inherit;
}

/* ═══════════════════════════════════════════════════════════════
   APP SHELL
   ═══════════════════════════════════════════════════════════════ */

.app-shell {
  position: relative;
  z-index: 1;
  max-width: 1320px;
  margin: 0 auto;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.28), transparent 14%),
    var(--surface);
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
  overflow: hidden;
  backdrop-filter: blur(18px);
}

/* ═══════════════════════════════════════════════════════════════
   HEADER / NAV
   ═══════════════════════════════════════════════════════════════ */

.app-header {
  padding: 18px 28px 16px;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(228, 237, 219, 0.7), rgba(252, 249, 241, 0.45)),
    rgba(255, 255, 255, 0.3);
}

.top-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, var(--accent-soft), #f4f7ee);
  border: 1px solid rgba(84, 106, 80, 0.12);
  color: var(--accent-strong);
  font-size: 18px;
  font-weight: 700;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.brand-mark svg {
  width: 20px;
  height: 20px;
}

.logo {
  font-size: 20px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--accent-strong);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

.nav-link {
  padding: 8px 14px;
  border-radius: 999px;
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
  transition: background 0.18s ease, color 0.18s ease;
}

.nav-link:hover,
.nav-link.is-active {
  background: rgba(127, 151, 119, 0.14);
  color: var(--accent-strong);
}

/* ═══════════════════════════════════════════════════════════════
   MAIN LAYOUT
   ═══════════════════════════════════════════════════════════════ */

.landing-main,
.protocol-main {
  padding: 28px;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(290px, 0.9fr);
  gap: 20px;
  margin-bottom: 24px;
}

/* ═══════════════════════════════════════════════════════════════
   SHARED CARD STYLES
   ═══════════════════════════════════════════════════════════════ */

.hero-card,
.hero-side-card,
.input-card,
.summary-card,
.lead-finding-card,
.why-card,
.timeline-shell,
.focus-card,
.email-capture,
.unlock-cta,
.feedback-card,
.info-card,
.access-banner,
.loading,
.score-card,
.sidebar-widget {
  background: var(--surface-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: 0 16px 30px rgba(86, 95, 69, 0.08);
}

/* ═══════════════════════════════════════════════════════════════
   HERO
   ═══════════════════════════════════════════════════════════════ */

.hero-card {
  padding: 28px;
  background:
    radial-gradient(circle at top right, rgba(228, 237, 219, 0.85), transparent 42%),
    var(--surface-strong);
}

.hero-card--dashboard {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
}

.hero-card--dashboard .hero-content {
  flex: 1;
}

.hero-side-card {
  padding: 22px;
  display: grid;
  gap: 16px;
}

.hero-kicker,
.section-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-strong);
}

.hero-kicker {
  margin-bottom: 14px;
}

h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4.8vw, 3rem);
  line-height: 1.06;
  letter-spacing: -0.04em;
  color: var(--text);
}

h2,
h3 {
  letter-spacing: -0.03em;
  color: var(--text);
}

.subtitle,
.section-note,
.loading,
.summary-card p,
.info-card p,
.feedback-card p,
.access-banner {
  color: var(--muted);
}

.subtitle {
  margin-top: 12px;
  font-size: 15px;
  max-width: 58ch;
}

.hero-proof {
  margin-top: 14px;
  color: var(--muted);
  font-size: 13px;
}

.hero-proof strong {
  color: var(--text);
}

/* ═══════════════════════════════════════════════════════════════
   DONUT HERO (inline score ring in hero)
   ═══════════════════════════════════════════════════════════════ */

.donut-hero {
  flex-shrink: 0;
}

.donut-hero .score-ring {
  width: 100px;
  aspect-ratio: 1;
  padding: 8px;
}

.donut-hero .score-num {
  font-size: 28px;
}

.donut-hero .score-ring-caption {
  font-size: 10px;
  margin-top: 2px;
}

/* ═══════════════════════════════════════════════════════════════
   SIDEBAR WIDGETS (Upcoming Doses, Streak, Weekly)
   ═══════════════════════════════════════════════════════════════ */

.sidebar-widget {
  padding: 18px;
}

.sidebar-widget .section-label {
  margin-bottom: 12px;
}

.widget-dose-list {
  display: grid;
  gap: 0;
}

.widget-dose-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}

.widget-dose-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.widget-dose-name {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
}

.widget-dose-icon {
  width: 24px;
  height: 24px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: 11px;
}

.widget-dose-count {
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(228, 237, 219, 0.7);
  font-size: 12px;
  font-weight: 700;
  color: var(--accent-strong);
}

.widget-dose-arrow {
  color: var(--muted);
  font-size: 14px;
  cursor: pointer;
}

.widget-streak {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.03em;
}

.widget-streak-icon {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-size: 16px;
}

.widget-calendar {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  text-align: center;
}

.widget-cal-header {
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  padding: 4px 0;
}

.widget-cal-day {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  margin: 0 auto;
}

.widget-cal-day.today {
  background: var(--accent-strong);
  color: #fff;
}

.widget-cal-day.done {
  background: var(--accent-soft);
  color: var(--accent-strong);
}

/* ═══════════════════════════════════════════════════════════════
   TIMELINE VISUAL BAR (mockup-style horizontal strip)
   ═══════════════════════════════════════════════════════════════ */

.timeline-visual-bar {
  --timeline-gap: 16px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--timeline-gap);
  margin-bottom: 8px;
}

.timeline-zone {
  border-radius: 18px;
  padding: 14px 16px;
  display: grid;
  gap: 6px;
  min-height: 72px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.78);
}

.timeline-zone--morning {
  background: linear-gradient(180deg, rgba(208, 221, 197, 0.72), rgba(255, 253, 247, 0.92));
}

.timeline-zone--afternoon {
  background: linear-gradient(180deg, rgba(232, 223, 200, 0.72), rgba(255, 253, 247, 0.92));
}

.timeline-zone--night {
  background: linear-gradient(180deg, rgba(236, 241, 232, 0.92), rgba(255, 253, 247, 0.92));
}

.timeline-zone-label {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.timeline-zone--morning .timeline-zone-label,
.timeline-zone--afternoon .timeline-zone-label {
  color: var(--muted-strong);
}

.timeline-zone--night .timeline-zone-label {
  color: var(--muted-strong);
}

.timeline-zone-stat {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.timeline-zone-number {
  font-size: 28px;
  line-height: 1;
  font-weight: 800;
  color: var(--text);
  font-family: var(--font-display);
}

.timeline-zone-meta {
  font-size: 13px;
  color: var(--muted);
}

/* ═══════════════════════════════════════════════════════════════
   TIMELINE CONNECTOR
   ═══════════════════════════════════════════════════════════════ */

.timeline-connector-wrap {
  position: relative;
  height: 26px;
  margin: 0 0 10px;
}

.timeline-connector-wrap::before {
  content: "";
  position: absolute;
  left: calc((100% - (var(--timeline-gap) * 2)) / 6);
  right: calc((100% - (var(--timeline-gap) * 2)) / 6);
  top: 6px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(127, 151, 119, 0.18), rgba(127, 151, 119, 0.38), rgba(127, 151, 119, 0.18));
}

.timeline-connector-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--timeline-gap);
  height: 100%;
}

.timeline-connector-node {
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.timeline-connector-dot {
  width: 14px;
  height: 14px;
  border-radius: 999px;
  border: 3px solid rgba(255, 253, 247, 0.98);
  box-shadow: 0 0 0 1px rgba(84, 106, 80, 0.12);
}

.timeline-connector-node--morning .timeline-connector-dot {
  background: #bfd1b1;
}

.timeline-connector-node--afternoon .timeline-connector-dot {
  background: #deceb0;
}

.timeline-connector-node--night .timeline-connector-dot {
  background: #2f3b35;
}

/* ═══════════════════════════════════════════════════════════════
   FIT / SUMMARY
   ═══════════════════════════════════════════════════════════════ */

.fit-card {
  display: grid;
  gap: 12px;
}

.fit-block {
  padding: 16px 18px;
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(244, 247, 238, 0.95), rgba(251, 249, 241, 0.85));
  border: 1px solid var(--line);
}

.fit-title {
  margin: 0 0 8px 0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-strong);
}

.fit-block p,
.info-card p,
.summary-card p {
  font-size: 14px;
}

.fit-block strong,
.summary-stat strong,
.summary-card strong,
.summary-list strong,
.score-label strong {
  color: var(--text);
}

.summary-card,
.info-card,
.access-banner,
.loading {
  padding: 20px;
}

.summary-card {
  display: grid;
  gap: 0;
}

.summary-card > * + * {
  margin-top: 12px;
}

.guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  margin: 24px 0;
}

.guide-card {
  display: grid;
  gap: 10px;
  padding: 22px;
  background: var(--card, #fff);
  border: 1px solid var(--line, #e5e7eb);
  border-radius: 14px;
  text-decoration: none;
  color: inherit;
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.guide-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent, #8a9f82);
  box-shadow: 0 6px 20px rgba(45, 74, 45, 0.08);
}

.guide-card-kicker {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  color: var(--accent-strong, #2d4a2d);
}

.guide-card h2 {
  margin: 0;
  font-size: 18px;
  line-height: 1.35;
  color: var(--text);
}

.guide-card p {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-muted, var(--text));
}

.guide-card-cta {
  margin-top: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--accent-strong, #2d4a2d);
}

.summary-card h2 {
  margin: 0;
  font-size: 20px;
  line-height: 1.35;
  color: var(--text);
}

.summary-card h3 {
  margin: 0;
  font-size: 15px;
  line-height: 1.4;
  color: var(--text);
  font-weight: 600;
}

.summary-card p {
  margin: 0;
  line-height: 1.6;
  color: var(--text-muted, var(--text));
}

.summary-card ul,
.summary-card ol {
  margin: 0;
  padding-left: 22px;
  display: grid;
  gap: 8px;
}

.summary-card ul li,
.summary-card ol li {
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-muted, var(--text));
  padding-left: 4px;
}

.summary-card ul li::marker {
  color: var(--accent, #8a9f82);
}

.summary-card ol li::marker {
  color: var(--accent, #8a9f82);
  font-weight: 600;
}

.summary-card a {
  color: var(--accent-strong, #2d4a2d);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.summary-card a:hover {
  text-decoration-thickness: 2px;
}

.summary-card em {
  font-style: italic;
  color: var(--text-muted, var(--text));
}

.summary-card .section-label {
  margin-bottom: 4px;
}

.summary-stat {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.summary-stat:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.summary-stat span {
  color: var(--muted);
  font-size: 13px;
}

.summary-stat strong {
  max-width: 60%;
  text-align: right;
  font-size: 14px;
}

/* ═══════════════════════════════════════════════════════════════
   INPUT CARD
   ═══════════════════════════════════════════════════════════════ */

.input-card {
  padding: 24px;
  margin-bottom: 18px;
}

.input-card label,
.diet-label,
.feedback-field > label,
.quick-search-label span:last-child {
  font-size: 12px;
}

.input-card label,
.diet-label,
.feedback-field > label {
  display: block;
  margin-bottom: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-strong);
}

.cohort-banner,
.cohort-access-card,
.disclaimer,
.pro-tip,
.gap-item {
  border-radius: var(--radius);
  border: 1px solid var(--line);
}

.cohort-banner {
  display: none;
  margin-bottom: 16px;
  padding: 14px 16px;
  background: rgba(228, 237, 219, 0.8);
  font-size: 13px;
  line-height: 1.6;
}

.cohort-banner strong,
.access-banner strong,
.disclaimer strong,
.cohort-access-copy strong {
  color: var(--accent-strong);
}

.cohort-banner a,
.cohort-links a,
.footer-links a,
.app-footer a,
.back-link,
.feedback-card a,
.supp-sources a,
.interaction-source a,
.gap-item a {
  color: var(--accent-strong);
  text-decoration: none;
  border-bottom: 1px dotted rgba(84, 106, 80, 0.35);
}

.cohort-access-card {
  margin-bottom: 18px;
  padding: 18px;
  background: linear-gradient(180deg, rgba(228, 237, 219, 0.8), rgba(255, 253, 247, 0.9));
}

.cohort-section {
  margin-top: 24px;
}

.cohort-access-card--secondary {
  margin-bottom: 0;
}

.cohort-access-copy {
  display: grid;
  gap: 4px;
  margin-bottom: 14px;
}

.cohort-access-copy span,
.stack-hint,
.cohort-status,
.quick-search-label span:last-child {
  color: var(--muted);
  line-height: 1.5;
}

.cohort-access-row,
.stack-actions,
.stack-action-group,
.email-row,
.feedback-options,
.export-bar,
.share-morning,
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.cohort-access-row {
  align-items: center;
}

/* ═══════════════════════════════════════════════════════════════
   FORM INPUTS
   ═══════════════════════════════════════════════════════════════ */

.cohort-input,
.stack-textarea,
.search-input,
.email-input,
.feedback-input,
.feedback-textarea {
  width: 100%;
  border-radius: 16px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.cohort-input,
.search-input,
.email-input,
.feedback-input {
  padding: 12px 14px;
}

.stack-textarea,
.feedback-textarea {
  resize: vertical;
  min-height: 118px;
  padding: 14px 16px;
}

.cohort-input:focus,
.stack-textarea:focus,
.search-input:focus,
.email-input:focus,
.feedback-input:focus,
.feedback-textarea:focus {
  border-color: rgba(84, 106, 80, 0.45);
  box-shadow: 0 0 0 4px rgba(127, 151, 119, 0.13);
}

.stack-textarea::placeholder,
.cohort-input::placeholder,
.search-input::placeholder,
.email-input::placeholder,
.feedback-input::placeholder,
.feedback-textarea::placeholder {
  color: #8a9686;
}

.input-intro {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
}

.input-intro p {
  font-size: 14px;
  color: var(--muted);
}

/* ═══════════════════════════════════════════════════════════════
   PILLS & BADGES
   ═══════════════════════════════════════════════════════════════ */

.price-pill,
.badge,
.timeline-column-count,
.supp-dose,
.supp-category,
.goal-btn,
.diet-btn,
.feedback-option,
.chip {
  border-radius: 999px;
}

.price-pill {
  padding: 9px 12px;
  flex-shrink: 0;
  background: rgba(228, 237, 219, 0.85);
  border: 1px solid rgba(84, 106, 80, 0.14);
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.price-pill--btn {
  cursor: pointer;
  transition: background 0.18s, border-color 0.18s, transform 0.18s;
}

.price-pill--btn:hover,
.price-pill--btn:focus-visible {
  background: rgba(84, 106, 80, 0.22);
  border-color: rgba(84, 106, 80, 0.35);
  transform: translateY(-1px);
}

/* ═══════════════════════════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════════════════════════ */

.ghost-btn,
.cohort-btn,
.cohort-clear-btn,
.analyze-btn,
.email-submit,
.feedback-submit,
.unlock-btn,
.rec-btn,
.share-morning-btn,
.export-btn,
.share-btn {
  border-radius: 14px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease, color 0.16s ease, box-shadow 0.16s ease;
}

.ghost-btn,
.cohort-clear-btn,
.share-morning-btn,
.export-btn,
.share-btn {
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.74);
  border-color: var(--line);
  color: var(--muted-strong);
  font-size: 13px;
  font-weight: 700;
}

.ghost-btn:hover,
.cohort-clear-btn:hover,
.share-morning-btn:hover,
.export-btn:hover,
.share-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(84, 106, 80, 0.26);
  color: var(--accent-strong);
}

.ghost-btn.soft {
  background: rgba(228, 237, 219, 0.9);
}

.cohort-btn,
.analyze-btn,
.email-submit,
.feedback-submit,
.unlock-btn,
.rec-btn {
  background: linear-gradient(180deg, #8ea785, #738c6d);
  box-shadow: 0 14px 26px rgba(84, 106, 80, 0.18);
  color: #fdfcf7;
}

.cohort-btn,
.cohort-clear-btn {
  padding: 11px 14px;
  font-size: 13px;
  font-weight: 800;
}

.cohort-btn:hover,
.analyze-btn:hover:not(:disabled),
.email-submit:hover,
.feedback-submit:hover,
.unlock-btn:hover,
.rec-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 30px rgba(84, 106, 80, 0.22);
}

.cohort-status {
  display: none;
  margin-top: 12px;
  font-size: 13px;
}

.cohort-status.success {
  color: var(--accent-strong);
}

.cohort-status.error,
.feedback-status.error,
.paste-feedback.error {
  color: var(--warn);
}

.cohort-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 12px;
}

.paste-feedback {
  display: none;
  margin-top: 12px;
  font-size: 13px;
  color: var(--muted);
}

/* ═══════════════════════════════════════════════════════════════
   SEARCH
   ═══════════════════════════════════════════════════════════════ */

.quick-search-label {
  margin-top: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.search-wrapper {
  position: relative;
}

.search-input {
  padding: 13px 14px 13px 42px;
}

.search-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
  font-size: 15px;
}

.search-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 60;
  display: none;
  max-height: min(320px, calc(100vh - 240px));
  overflow-y: auto;
  overscroll-behavior: contain;
  background: rgba(255, 253, 247, 0.98);
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  box-shadow: 0 18px 34px rgba(82, 90, 64, 0.15);
}

.search-dropdown.open {
  display: block;
}

.dropdown-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  cursor: pointer;
  border-bottom: 1px solid rgba(84, 106, 80, 0.08);
}

.dropdown-item:last-child {
  border-bottom: none;
}

.dropdown-item:hover,
.dropdown-item.focused {
  background: rgba(228, 237, 219, 0.45);
}

.di-name {
  font-size: 14px;
  font-weight: 700;
}

.di-cat {
  margin-top: 2px;
  font-size: 11px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.di-add {
  flex-shrink: 0;
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 700;
}

.dropdown-empty {
  padding: 14px;
  color: var(--muted);
  text-align: center;
  font-size: 13px;
}

/* ═══════════════════════════════════════════════════════════════
   CHIPS
   ═══════════════════════════════════════════════════════════════ */

.selected-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  background: rgba(228, 237, 219, 0.86);
  border: 1px solid rgba(84, 106, 80, 0.16);
  color: var(--muted-strong);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.chip:hover {
  border-color: rgba(193, 116, 106, 0.28);
  color: #8f4e48;
}

.chip-warn {
  background: rgba(182, 134, 75, 0.12);
}

.chip-x {
  color: var(--muted);
  font-size: 15px;
}

/* ═══════════════════════════════════════════════════════════════
   GOALS / DIET
   ═══════════════════════════════════════════════════════════════ */

.goal-row,
.diet-options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.goal-btn,
.diet-btn,
.feedback-option {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.7);
  color: var(--muted-strong);
  padding: 9px 14px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.goal-btn.active,
.diet-btn.active,
.feedback-option:hover {
  border-color: rgba(84, 106, 80, 0.22);
  background: rgba(228, 237, 219, 0.92);
  color: var(--accent-strong);
}

.diet-selector {
  margin-top: 18px;
}

.analyze-btn,
.unlock-btn {
  width: 100%;
  margin-top: 20px;
  padding: 15px 18px;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.analyze-btn:disabled,
.feedback-submit:disabled {
  opacity: 0.72;
  cursor: not-allowed;
  box-shadow: none;
}

.analyze-btn.loading::after {
  content: "";
  display: inline-block;
  margin-left: 10px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.45);
  border-top-color: rgba(255, 255, 255, 0.95);
  vertical-align: -2px;
  animation: spin 0.72s linear infinite;
}

/* ─── Labour Illusion Widget ─────────────────────────────────────────────── */

.analysis-loader {
  padding: 64px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
}

.analysis-loader-ring {
  position: relative;
  width: 48px;
  height: 48px;
}

.analysis-loader-ring::before,
.analysis-loader-ring::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2.5px solid transparent;
}

.analysis-loader-ring::before {
  border-top-color: var(--accent-strong);
  animation: spin 0.9s linear infinite;
}

.analysis-loader-ring::after {
  border-bottom-color: var(--accent);
  opacity: 0.4;
  animation: spin 1.4s linear infinite reverse;
}

.analysis-loader-steps {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 220px;
}

.analysis-loader-step {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--muted);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.35s ease, transform 0.35s ease, color 0.3s ease;
}

.analysis-loader-step.visible {
  opacity: 1;
  transform: translateY(0);
}

.analysis-loader-step.done {
  color: var(--accent-strong);
}

.analysis-loader-step-icon {
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.analysis-loader-step-icon .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse-dot 1s ease-in-out infinite;
}

.analysis-loader-step.done .dot {
  animation: none;
  width: 18px;
  height: 18px;
  background: none;
}

.analysis-loader-step.done .dot::after {
  content: "✓";
  font-size: 12px;
  font-weight: 800;
  color: var(--accent-strong);
}

@keyframes pulse-dot {
  0%, 100% { opacity: 0.4; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.4); }
}

.disclaimer {
  margin-bottom: 18px;
  padding: 15px 18px;
  background: rgba(255, 247, 232, 0.72);
  color: #7a6a51;
}

#results {
  margin-top: 22px;
}

/* ═══════════════════════════════════════════════════════════════
   PROTOCOL DASHBOARD
   ═══════════════════════════════════════════════════════════════ */

.protocol-dashboard {
  display: grid;
  grid-template-columns: minmax(0, 1.62fr) minmax(280px, 0.9fr);
  gap: 20px;
}

.protocol-dashboard--preview {
  grid-template-columns: minmax(0, 1fr);
}

.dashboard-main,
.dashboard-side,
.detail-stack {
  display: grid;
  gap: 18px;
  align-content: start;
}

.detail-stack--preview {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: 0 16px 30px rgba(86, 95, 69, 0.08);
  background:
    radial-gradient(circle at top right, rgba(228, 237, 219, 0.8), transparent 46%),
    linear-gradient(180deg, rgba(255, 252, 244, 0.92), rgba(255, 253, 247, 0.98)),
    var(--surface-strong);
}

.lead-insight-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.14fr) minmax(280px, 0.88fr);
  gap: 18px;
}

.lead-insight-grid--single {
  grid-template-columns: minmax(0, 1fr);
}

/* ═══════════════════════════════════════════════════════════════
   TIMELINE
   ═══════════════════════════════════════════════════════════════ */

.timeline-shell {
  --timeline-gap: 16px;
  padding: 24px;
}

.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.timeline-header h2,
.focus-header h2,
.feedback-card h2,
.score-heading h2 {
  font-size: 28px;
  line-height: 1.1;
  font-family: var(--font-display);
}

.timeline-title {
  margin-top: 10px;
  font-size: 28px;
  font-family: var(--font-display);
  line-height: 1.08;
}

.timeline-subtitle {
  font-size: 13px;
  color: var(--muted);
  margin-top: 4px;
}

.timeline-board {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--timeline-gap);
}

.timeline-board::before {
  content: "";
  position: absolute;
  left: 28px;
  right: 28px;
  top: 38px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(127, 151, 119, 0.16), rgba(127, 151, 119, 0.42), rgba(127, 151, 119, 0.14));
}

.timeline-column {
  position: relative;
  z-index: 1;
  border-radius: 22px;
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(228, 237, 219, 0.32), rgba(255, 253, 247, 0.86) 32%),
    var(--surface-strong);
  padding: 18px;
  min-height: 100%;
}

.timeline-column::before {
  content: "";
  position: absolute;
  left: 18px;
  top: 28px;
  width: 11px;
  height: 11px;
  border-radius: 999px;
  background: var(--accent-strong);
  box-shadow: 0 0 0 8px rgba(127, 151, 119, 0.18);
}

.timeline-column.locked::before {
  background: rgba(104, 116, 102, 0.55);
  box-shadow: 0 0 0 8px rgba(104, 116, 102, 0.12);
}

.timeline-column-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  padding-left: 26px;
  margin-bottom: 16px;
}

.timeline-column-header h3 {
  font-size: 18px;
  line-height: 1.15;
  font-family: var(--font-display);
}

.timeline-column-header p {
  margin-top: 2px;
  color: var(--muted);
  font-size: 13px;
}

.timeline-column-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  padding: 6px 10px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--line);
  color: var(--muted-strong);
  font-size: 12px;
  font-weight: 800;
}

.timeline-window {
  display: grid;
  gap: 10px;
  margin-bottom: 16px;
}

.timeline-window:last-child {
  margin-bottom: 0;
}

.protocol-header {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding-left: 4px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-strong);
}

.protocol-header .time {
  color: var(--muted);
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
}

.timeline-empty,
.lock-count,
.unmatched-list,
.share-feedback,
.share-feedback-inline,
.unlock-note,
.score-helper {
  color: var(--muted);
  font-size: 13px;
}

.locked-column-shell {
  opacity: 0.55;
}

.timeline-lock {
  margin-top: 16px;
  padding: 16px;
  border-radius: 18px;
  background: rgba(240, 235, 223, 0.9);
  border: 1px dashed rgba(104, 116, 102, 0.26);
  text-align: center;
}

.lock-icon {
  font-size: 18px;
  margin-bottom: 8px;
}

.lock-label {
  font-size: 14px;
  color: var(--muted-strong);
}

/* ═══════════════════════════════════════════════════════════════
   SUPPLEMENT CARDS
   ═══════════════════════════════════════════════════════════════ */

.supp-item {
  padding: 14px;
  border-radius: 18px;
  border: 1px solid rgba(84, 106, 80, 0.12);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 14px 22px rgba(86, 95, 69, 0.08);
}

/* Horizontal row variant (mockup style) */
.supp-item--row {
  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 10px 12px;
  padding: 12px 44px 12px 14px;
  position: relative;
}

.supp-row-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 26px;
  height: 26px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid rgba(120, 120, 120, 0.18);
  background: rgba(255, 255, 255, 0.9);
  color: var(--muted);
  font-size: 18px;
  line-height: 1;
  font-weight: 600;
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: all 0.15s;
  z-index: 2;
}

.supp-row-remove:hover {
  background: rgba(250, 238, 238, 0.98);
  border-color: rgba(168, 88, 88, 0.55);
  color: #6e3737;
}

.supp-row-remove:focus-visible {
  outline: 2px solid var(--accent, #8a9f82);
  outline-offset: 2px;
}

.supp-row-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(228, 237, 219, 0.96), rgba(208, 221, 197, 0.84));
  color: var(--accent-strong);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
  flex-shrink: 0;
}

.supp-row-icon svg {
  width: 18px;
  height: 18px;
}

.supp-row-info {
  flex: 1 1 160px;
  min-width: 0;
}

.supp-row-info .supp-name {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
}

.supp-row-info .supp-category {
  margin-top: 6px;
}

.supp-row-dose,
.supp-row-time {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  max-width: 100%;
  min-width: 0;
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: 1.25;
  text-align: left;
}

.supp-row-dose {
  flex: 1 1 140px;
  background: rgba(228, 237, 219, 0.72);
  color: var(--accent-strong);
}

.supp-row-time {
  flex: 0 1 auto;
  background: rgba(245, 241, 232, 0.95);
  border: 1px solid rgba(84, 106, 80, 0.1);
  color: var(--muted-strong);
}

.supp-row-btn {
  flex-shrink: 0;
}

.supp-item--row .supp-icon {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: var(--accent-soft);
  color: var(--accent-strong);
  flex-shrink: 0;
  font-size: 18px;
}

.supp-item--row .supp-info {
  flex: 1;
  min-width: 0;
}

.supp-item--row .supp-name {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
}

.supp-item--row .supp-meta-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 8px;
  margin-top: 2px;
  font-size: 12px;
  color: var(--muted);
}

.supp-item--row .supp-action {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.supp-action-btn--remove {
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid rgba(168, 88, 88, 0.28);
  background: rgba(255, 250, 250, 0.9);
  color: #8c4a4a;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s;
}

.supp-action-btn--remove:hover {
  border-color: rgba(168, 88, 88, 0.55);
  background: rgba(250, 240, 240, 0.95);
  color: #6e3737;
}

.supp-action-btn {
  padding: 7px 12px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.8);
  color: var(--muted-strong);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s;
}

.supp-action-btn:hover {
  border-color: rgba(84, 106, 80, 0.25);
  color: var(--accent-strong);
}

.supp-action-btn--details {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 36px;
  padding: 8px 10px 8px 14px;
  border-radius: 999px;
  border-color: rgba(84, 106, 80, 0.14);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(244, 247, 238, 0.96));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.92), 0 6px 14px rgba(86, 95, 69, 0.08);
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.supp-action-btn--details::after {
  content: "›";
  width: 18px;
  height: 18px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(228, 237, 219, 0.9);
  color: var(--accent-strong);
  font-size: 14px;
  line-height: 1;
  transition: transform 0.16s ease, background 0.16s ease;
}

.supp-action-btn--details:hover {
  transform: translateY(-1px);
  border-color: rgba(84, 106, 80, 0.24);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.95), 0 10px 18px rgba(86, 95, 69, 0.1);
}

.supp-action-btn--details[aria-expanded="true"] {
  background: linear-gradient(180deg, rgba(228, 237, 219, 0.98), rgba(235, 242, 228, 0.92));
}

.supp-action-btn--details[aria-expanded="true"]::after {
  transform: rotate(90deg);
  background: rgba(255, 255, 255, 0.84);
}

.supp-action-btn--complete {
  background: var(--accent-soft);
  border-color: rgba(84, 106, 80, 0.18);
  color: var(--accent-strong);
}

.supp-action-btn--taken {
  background: linear-gradient(180deg, #8ea785, #738c6d);
  border-color: transparent;
  color: #fdfcf7;
}

/* Original vertical card style */
.supp-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.supp-badge {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(228, 237, 219, 0.95), rgba(208, 221, 197, 0.86));
  color: var(--accent-strong);
  font-weight: 800;
  font-size: 14px;
}

.supp-category {
  padding: 5px 9px;
  border: 1px solid rgba(84, 106, 80, 0.12);
  background: rgba(228, 237, 219, 0.55);
  color: var(--muted-strong);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.supp-name-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.supp-name {
  font-size: 16px;
  line-height: 1.2;
  font-weight: 700;
}

.supp-dose {
  padding: 4px 8px;
  background: rgba(228, 237, 219, 0.72);
  color: var(--accent-strong);
  font-size: 11px;
  font-weight: 800;
  white-space: nowrap;
}

.supp-meta {
  margin-top: 8px;
  color: var(--muted);
  font-size: 13px;
}

.supp-details {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(84, 106, 80, 0.1);
}

.supp-details summary {
  list-style: none;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
  color: var(--accent-strong);
  letter-spacing: 0.02em;
}

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

.supp-details summary::after {
  content: "+";
  float: right;
}

.supp-details[open] summary::after {
  content: "-";
}

/* ═══════════════════════════════════════════════════════════════
   SUPPLEMENT DETAIL POPUP
   ═══════════════════════════════════════════════════════════════ */

.supp-detail-popup {
  animation: fadeSlideUp 0.18s ease;
}

.supp-detail-popup h3 {
  font-size: 24px;
  font-family: var(--font-display);
  margin-top: 8px;
  margin-bottom: 4px;
}

.supp-detail-popup .detail-dosage {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 14px;
}

.details-modal[hidden] {
  display: none;
}

.details-modal {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: grid;
  place-items: center;
  padding: 20px 16px;
}

.details-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(40, 50, 38, 0.28);
  backdrop-filter: blur(8px);
}

.details-modal-panel {
  position: relative;
  width: min(720px, 100%);
  max-height: min(82vh, 900px);
  overflow: auto;
  overscroll-behavior: contain;
  padding: 18px;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.4), rgba(255, 253, 247, 0.98) 18%),
    var(--surface-strong);
  box-shadow: 0 28px 80px rgba(52, 62, 48, 0.22);
  z-index: 1;
}

.details-modal-close {
  position: sticky;
  top: 0;
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.88);
  color: var(--muted-strong);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  z-index: 1;
}

.details-modal-header {
  margin-bottom: 14px;
  padding-right: 56px;
}

.supp-detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
}

.details-locked-body {
  padding: 28px 20px;
  text-align: center;
}

.details-locked-msg {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.details-locked-msg p {
  max-width: 300px;
  line-height: 1.5;
}

.supp-detail-section {
  margin: 0;
  padding: 14px;
  border-radius: 16px;
  border: 1px solid rgba(84, 106, 80, 0.1);
  background: rgba(248, 246, 239, 0.88);
}

.supp-detail-section h4 {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-strong);
  margin-bottom: 6px;
}

.supp-detail-section p,
.supp-detail-section ul {
  font-size: 13px;
  color: var(--muted-strong);
  line-height: 1.6;
}

.supp-detail-section ul {
  list-style: none;
  padding: 0;
}

.supp-detail-section ul li {
  padding: 2px 0 2px 16px;
  position: relative;
}

.supp-detail-section ul li::before {
  content: "•";
  position: absolute;
  left: 0;
  color: var(--accent);
}

/* ═══════════════════════════════════════════════════════════════
   SUPPLEMENT NOTES & DETAIL BLOCKS
   ═══════════════════════════════════════════════════════════════ */

.supp-note,
.supp-circadian,
.supp-absorption,
.diet-warning,
.supp-sources,
.interaction-loss,
.interaction-magnitude,
.interaction-fix,
.interaction-mechanism,
.interaction-source {
  margin-top: 10px;
  font-size: 12px;
  line-height: 1.55;
}

.supp-sources {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  margin-top: 8px;
}

.supp-sources a {
  display: inline-flex;
  align-items: center;
}

body.details-modal-open {
  overflow: hidden;
}

.supp-note {
  color: var(--muted);
}

.supp-circadian {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(228, 237, 219, 0.55);
  color: #56705a;
}

.supp-absorption {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 247, 232, 0.7);
  color: #86653f;
}

.diet-warning {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(182, 134, 75, 0.12);
  color: #8e6637;
}

.vegan-badge {
  display: inline-flex;
  align-items: center;
  margin-left: 8px;
  padding: 3px 7px;
  border-radius: 999px;
  background: rgba(228, 237, 219, 0.85);
  color: var(--accent-strong);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.supp-sources a + a::before,
.interaction-source a + a::before,
.gap-item a + a::before {
  content: " · ";
  color: var(--muted);
}

.supp-placeholder {
  display: grid;
  gap: 10px;
}

.placeholder-row,
.placeholder-pill {
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(223, 229, 214, 0.8), rgba(239, 243, 235, 0.95), rgba(223, 229, 214, 0.8));
  background-size: 180% 100%;
  animation: shimmer 2.4s linear infinite;
}

.placeholder-pill {
  width: 40px;
  height: 40px;
  border-radius: 14px;
}

.placeholder-row {
  height: 12px;
}

.placeholder-row.short {
  width: 42%;
}

.placeholder-row.medium {
  width: 70%;
}

.placeholder-row.long {
  width: 88%;
}

/* ═══════════════════════════════════════════════════════════════
   SCORE
   ═══════════════════════════════════════════════════════════════ */

.score-card {
  padding: 20px;
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
}

.score-heading {
  display: grid;
  gap: 6px;
}

.score-label {
  font-size: 13px;
  color: var(--muted);
}

.score-ring {
  width: 118px;
  aspect-ratio: 1;
  border-radius: 999px;
  background: conic-gradient(var(--accent-strong) calc(var(--score-progress, 0) * 1%), rgba(127, 151, 119, 0.14) 0);
  padding: 10px;
  display: grid;
  place-items: center;
}

.score-ring-inner {
  width: 100%;
  height: 100%;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--surface-strong);
  text-align: center;
  padding: 8px;
}

.score-num {
  font-size: 34px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.06em;
  color: var(--accent-strong);
}

.score-num.locked {
  color: var(--muted);
}

.score-ring-caption {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.score-breakdown {
  margin-top: 10px;
  display: grid;
  gap: 8px;
}

.score-row {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
}

.score-row-label {
  width: 118px;
  flex-shrink: 0;
  color: var(--muted);
}

.score-bar-wrap {
  flex: 1;
  height: 7px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(84, 106, 80, 0.1);
}

.score-bar {
  height: 100%;
  border-radius: inherit;
}

.score-bar-green {
  background: linear-gradient(90deg, #95b08b, var(--accent-strong));
}

.score-bar-locked {
  background: rgba(84, 106, 80, 0.26);
}

.score-row-val {
  width: 52px;
  text-align: right;
  color: var(--muted);
  font-size: 12px;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 8px;
  background: rgba(228, 237, 219, 0.76);
  border: 1px solid rgba(84, 106, 80, 0.12);
  color: var(--accent-strong);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.badge-warn {
  background: rgba(255, 247, 232, 0.92);
  color: #8b6437;
}

.badge-free {
  background: rgba(228, 237, 219, 0.9);
}

/* ═══════════════════════════════════════════════════════════════
   DETAIL GRID & FOCUS
   ═══════════════════════════════════════════════════════════════ */

.dashboard-detail-grid,
.feedback-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, 1fr);
  gap: 18px;
}

.lead-finding-card,
.why-card {
  padding: 24px;
}

.lead-finding-card {
  background:
    linear-gradient(180deg, rgba(193, 116, 106, 0.09), rgba(255, 253, 247, 0.94) 36%),
    var(--surface-strong);
}

.lead-finding-card h2,
.why-card h3 {
  margin-top: 10px;
  font-size: 28px;
  line-height: 1.08;
  font-family: var(--font-display);
}

.lead-finding-impact {
  display: grid;
  gap: 6px;
  margin: 18px 0;
  padding: 16px 18px;
  border-radius: var(--radius);
  border: 1px solid rgba(193, 116, 106, 0.22);
  background: rgba(193, 116, 106, 0.08);
}

.lead-finding-impact span,
.lead-finding-fix h4,
.upgrade-label {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.lead-finding-impact span,
.lead-finding-fix h4 {
  color: #9f534b;
}

.lead-finding-impact strong {
  font-size: 16px;
  color: #9f534b;
}

.lead-finding-fix {
  padding: 16px 18px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--line);
}

.lead-finding-locked {
  margin-top: 16px;
  padding: 20px;
  border-radius: var(--radius);
  background: rgba(0, 0, 0, 0.04);
  border: 1px dashed var(--line);
  text-align: center;
}

.lead-finding-locked-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.lead-finding-unlock-btn {
  margin-top: 6px;
  padding: 8px 18px;
  border-radius: 10px;
  border: 1px solid rgba(84, 106, 80, 0.2);
  background: rgba(84, 106, 80, 0.08);
  color: var(--accent-strong);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.18s, border-color 0.18s;
}

.lead-finding-unlock-btn:hover {
  background: rgba(84, 106, 80, 0.16);
  border-color: rgba(84, 106, 80, 0.35);
}

.lead-finding-fix p,
.lead-why-copy,
.upgrade-change,
.upgrade-reason {
  margin-top: 6px;
  font-size: 13px;
  color: var(--muted);
}

.why-card {
  display: grid;
  align-content: start;
  gap: 10px;
}

.focus-card {
  padding: 22px;
}

.focus-card--spotlight {
  background:
    radial-gradient(circle at top right, rgba(228, 237, 219, 0.82), transparent 42%),
    var(--surface-strong);
}

.focus-header {
  display: grid;
  gap: 10px;
  margin-bottom: 18px;
}

.focus-title-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  margin-top: 10px;
}

.focus-mark {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(228, 237, 219, 0.96), rgba(208, 221, 197, 0.84));
  color: var(--accent-strong);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.92);
  font-size: 20px;
}

.focus-pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.focus-pill {
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(244, 247, 238, 0.82);
  border: 1px solid rgba(84, 106, 80, 0.12);
  color: var(--accent-strong);
  font-size: 12px;
  font-weight: 800;
}

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

.focus-block {
  padding: 14px;
  border-radius: var(--radius);
  background: rgba(244, 247, 238, 0.7);
  border: 1px solid var(--line);
}

.focus-block--wide {
  grid-column: 1 / -1;
}

.focus-block h4 {
  margin-bottom: 6px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-strong);
}

.focus-block p,
.focus-block div {
  font-size: 13px;
  color: var(--muted-strong);
}

.focus-block .supp-sources,
.focus-block .diet-warning,
.focus-block .supp-circadian,
.focus-block .supp-absorption,
.focus-block .supp-note {
  margin-top: 0;
  padding: 0;
  background: transparent;
  border-radius: 0;
  color: inherit;
}

.focus-block .supp-sources {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
}

/* ═══════════════════════════════════════════════════════════════
   PRO TIPS / RECS / CONFLICTS / SYNERGIES
   ═══════════════════════════════════════════════════════════════ */

.insight-panel {
  display: grid;
  gap: 12px;
}

.insight-panel + .insight-panel {
  padding-top: 6px;
  border-top: 1px solid rgba(84, 106, 80, 0.08);
}

.insight-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.insight-preview-pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(244, 247, 238, 0.86);
  border: 1px solid rgba(84, 106, 80, 0.12);
  color: var(--accent-strong);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.pro-tips,
.recommendations,
.upgrade-list {
  display: grid;
  gap: 10px;
}

.pro-tip,
.rec-card,
.upgrade-card,
.conflict-card,
.synergy-card,
.gap-item {
  padding: 16px 18px;
  border-radius: var(--radius);
}

.pro-tip {
  background: rgba(228, 237, 219, 0.72);
}

.pro-tip--featured {
  border: 1px solid rgba(84, 106, 80, 0.14);
  background:
    linear-gradient(180deg, rgba(228, 237, 219, 0.78), rgba(255, 255, 255, 0.92));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.pro-tip-kicker {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-strong);
}

.pro-tip-title,
.rec-name,
.conflict-card .title,
.synergy-card .title,
.gap-name {
  font-size: 14px;
  font-weight: 800;
}

.pro-tip-body,
.rec-why,
.card-body,
.gap-reason {
  margin-top: 6px;
  font-size: 13px;
  color: var(--muted);
}

.pro-tip-note {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(84, 106, 80, 0.1);
  font-size: 13px;
  color: var(--muted-strong);
}

.conflict-card {
  border: 1px solid rgba(193, 116, 106, 0.22);
  background: rgba(193, 116, 106, 0.08);
}

.conflict-card .title,
.interaction-loss {
  color: #9f534b;
}

.synergy-card {
  border: 1px solid rgba(84, 106, 80, 0.16);
  background: rgba(228, 237, 219, 0.76);
}

.synergy-card .title,
.interaction-magnitude {
  color: var(--accent-strong);
}

.rec-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
}

.upgrade-card {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.92);
}

.upgrade-card--cleanup {
  border-color: rgba(193, 116, 106, 0.2);
  background: rgba(193, 116, 106, 0.06);
}

.upgrade-card--pairing {
  border-color: rgba(84, 106, 80, 0.16);
  background: rgba(228, 237, 219, 0.52);
}

.upgrade-card--swap {
  border-color: rgba(182, 134, 75, 0.2);
  background: rgba(255, 247, 232, 0.7);
}

.upgrade-card--locked {
  border-color: var(--line);
  background: rgba(0, 0, 0, 0.02);
}

.upgrade-card--locked .rec-name {
  opacity: 0.5;
}

.upgrade-locked-overlay {
  margin-top: 8px;
  font-size: 12px;
  color: var(--muted);
}

.upgrade-copy {
  flex: 1;
  min-width: 0;
}

.upgrade-label {
  color: var(--accent-strong);
}

.upgrade-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin-top: 10px;
  font-size: 12px;
}

.upgrade-impact {
  color: var(--muted-strong);
  font-weight: 700;
}

.upgrade-source a {
  color: var(--accent-strong);
  text-decoration: none;
  border-bottom: 1px dotted rgba(84, 106, 80, 0.35);
}

.upgrade-btn {
  flex-shrink: 0;
  align-self: center;
}

.insight-empty-card {
  padding: 16px 18px;
  border-radius: var(--radius);
  border: 1px dashed rgba(84, 106, 80, 0.2);
  background: rgba(255, 255, 255, 0.72);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.insight-footnote {
  font-size: 13px;
  color: var(--muted);
  padding-left: 2px;
}

.rec-info {
  flex: 1;
}

.rec-btn {
  flex-shrink: 0;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 800;
}

.gap-item {
  border: 1px solid rgba(182, 134, 75, 0.18);
  background: rgba(255, 247, 232, 0.74);
}

.gap-name {
  color: #8d6231;
}

/* ═══════════════════════════════════════════════════════════════
   EMAIL / UNLOCK / FEEDBACK
   ═══════════════════════════════════════════════════════════════ */

.email-capture,
.unlock-cta,
.feedback-card {
  padding: 24px;
}

.protocol-main > .hero-card,
.landing-main > .hero-card {
  margin-bottom: 20px;
}

/* Guide page card spacing — ensures summary-cards that are direct children
   of .landing-main (used on SEO guide pages) have vertical breathing room
   and slightly more generous inner padding. */
.landing-main > .summary-card {
  padding: 28px;
  margin-top: 20px;
}

.landing-main > .summary-card:first-of-type {
  margin-top: 24px;
}

@media (max-width: 640px) {
  .landing-main > .summary-card {
    padding: 22px;
    margin-top: 16px;
  }
}

.email-capture p,
.unlock-cta p {
  font-size: 14px;
}

.email-input {
  flex: 1;
}

.email-submit {
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
}

.email-success,
.share-feedback,
.share-feedback-inline,
.feedback-status {
  display: none;
}

.unlock-list {
  list-style: none;
  display: grid;
  gap: 8px;
  margin: 18px 0;
}

.unlock-list li {
  font-size: 14px;
  color: var(--muted);
}

.unlock-list li::before {
  content: "+ ";
  color: var(--accent-strong);
  font-weight: 800;
}

.feedback-card h2 {
  margin-bottom: 8px;
}

.feedback-card p {
  margin-bottom: 16px;
}

.feedback-grid {
  gap: 16px;
}

.feedback-field {
  display: grid;
  gap: 8px;
}

.feedback-option input {
  accent-color: var(--accent-strong);
}

.feedback-submit {
  margin-top: 18px;
  padding: 12px 18px;
  font-size: 14px;
  font-weight: 800;
}

.feedback-status {
  margin-top: 12px;
  font-size: 13px;
  color: var(--accent-strong);
}

.export-bar {
  margin: 2px 0;
}

.export-btn,
.share-btn {
  font-size: 13px;
  font-weight: 800;
}

/* ═══════════════════════════════════════════════════════════════
   NEXT DOSE BAR
   ═══════════════════════════════════════════════════════════════ */

.next-dose-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  border-top: 1px solid var(--line);
  background: rgba(252, 249, 241, 0.96);
  font-size: 14px;
  color: var(--muted);
  margin-top: 18px;
  border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}

.next-dose-bar strong {
  color: var(--text);
}

.next-dose-bar .profile-link {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--muted-strong);
  font-weight: 600;
  font-size: 13px;
}

.next-dose-bar .profile-link .avatar-sm {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  background: var(--accent-soft);
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 800;
  color: var(--accent-strong);
}

/* ═══════════════════════════════════════════════════════════════
   LOADING / MISC
   ═══════════════════════════════════════════════════════════════ */

.loading {
  text-align: center;
  margin-bottom: 20px;
  padding: 48px 24px;
}

.access-banner {
  display: none;
  margin: 0 0 20px;
}

.spinner {
  width: 34px;
  height: 34px;
  margin: 0 auto 16px;
  border-radius: 999px;
  border: 3px solid rgba(84, 106, 80, 0.14);
  border-top-color: var(--accent-strong);
  animation: spin 0.78s linear infinite;
}

.back-link {
  display: inline-flex;
  align-items: center;
  margin-top: 20px;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.74);
  font-size: 13px;
  font-weight: 700;
}

/* ═══════════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════════ */

.app-footer {
  padding: 0 28px 28px;
  border-top: 1px solid var(--line);
}

.footer-guides {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  padding-top: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 10px;
}

.footer-guides-label {
  width: 100%;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 2px;
}

.footer-guides a {
  font-size: 13px;
}

.footer-links {
  padding-top: 10px;
  margin-bottom: 10px;
}

.app-footer p,
.footer-disclaimer {
  color: var(--muted);
  font-size: 12px;
}

.unmatched-list span {
  display: inline-block;
  margin: 4px 4px 0 0;
  padding: 4px 9px;
  border-radius: 999px;
  background: rgba(255, 247, 232, 0.84);
  border: 1px solid rgba(182, 134, 75, 0.16);
}

/* ═══════════════════════════════════════════════════════════════
   CONTENT PAGE (privacy, terms, feedback standalone)
   ═══════════════════════════════════════════════════════════════ */

.content-main {
  padding: 28px;
  max-width: 760px;
}

.content-main h1 {
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  margin-bottom: 6px;
}

.content-main .updated {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 24px;
}

.content-section {
  margin-bottom: 28px;
}

.content-section h2 {
  font-size: 17px;
  font-weight: 700;
  color: var(--accent-strong);
  margin-bottom: 10px;
}

.content-section p {
  color: var(--muted-strong);
  font-size: 15px;
  margin-bottom: 10px;
  line-height: 1.65;
}

.content-section strong {
  color: var(--text);
}

.content-section code {
  color: var(--text);
  background: rgba(228, 237, 219, 0.5);
  padding: 0.1em 0.35em;
  border-radius: 4px;
  font-size: 0.9em;
}

.content-section ul {
  list-style: none;
  padding: 0;
  margin-bottom: 10px;
}

.content-section li {
  color: var(--muted-strong);
  font-size: 15px;
  padding: 3px 0 3px 18px;
  position: relative;
  line-height: 1.65;
}

.content-section li::before {
  content: '–';
  position: absolute;
  left: 0;
  color: var(--accent);
}

.content-card {
  padding: 18px 22px;
  margin-bottom: 24px;
  border-radius: var(--radius);
  background: rgba(228, 237, 219, 0.5);
  border: 1px solid var(--line);
}

.content-card p {
  margin-bottom: 0;
  font-size: 14px;
}

/* Feedback form page (standalone) */
.feedback-standalone .field {
  margin-bottom: 16px;
}

.feedback-standalone .field > label {
  display: block;
  margin-bottom: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-strong);
}

.feedback-standalone .select {
  width: 100%;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  outline: none;
  font-size: 14px;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.feedback-standalone .select:focus {
  border-color: rgba(84, 106, 80, 0.45);
  box-shadow: 0 0 0 4px rgba(127, 151, 119, 0.13);
}

.feedback-standalone .options {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.feedback-standalone .option {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted-strong);
  font-size: 13px;
  cursor: pointer;
  font-weight: 600;
}

.feedback-standalone .option input {
  accent-color: var(--accent-strong);
}

.feedback-standalone .option:hover {
  border-color: rgba(84, 106, 80, 0.3);
  background: var(--accent-soft);
}

.feedback-standalone .submit-btn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: 12px 18px;
  border: none;
  border-radius: 14px;
  background: linear-gradient(180deg, #8ea785, #738c6d);
  box-shadow: 0 14px 26px rgba(84, 106, 80, 0.18);
  color: #fdfcf7;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}

.feedback-standalone .submit-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 18px 30px rgba(84, 106, 80, 0.22);
}

.feedback-standalone .submit-btn:disabled {
  opacity: 0.72;
  cursor: not-allowed;
}

.feedback-standalone .status {
  display: none;
  margin-top: 12px;
  font-size: 13px;
  color: var(--accent-strong);
}

.feedback-standalone .status.error {
  color: var(--warn);
}

.feedback-standalone .saved-stack {
  display: none;
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: rgba(228, 237, 219, 0.5);
  border: 1px solid rgba(84, 106, 80, 0.14);
  color: var(--muted-strong);
  font-size: 13px;
  line-height: 1.5;
}

.feedback-standalone .saved-stack strong {
  color: var(--accent-strong);
}

/* Admin page */
.admin-main {
  padding: 28px;
}

.admin-main .admin-auth-card {
  padding: 20px;
  border-radius: var(--radius-lg);
  background: var(--surface-strong);
  border: 1px solid var(--line);
  box-shadow: 0 16px 30px rgba(86, 95, 69, 0.08);
}

.admin-main .admin-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

.admin-main .admin-input {
  flex: 1 1 260px;
  min-width: 0;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  outline: none;
}

.admin-main .admin-btn {
  padding: 12px 16px;
  border: none;
  border-radius: 14px;
  background: linear-gradient(180deg, #8ea785, #738c6d);
  color: #fdfcf7;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

.admin-status {
  display: none;
  margin-top: 10px;
  font-size: 13px;
  color: var(--muted);
}

.admin-status.error {
  color: var(--warn);
}

.admin-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 10px;
  margin-top: 16px;
}

.admin-stat {
  padding: 14px;
  border-radius: var(--radius-sm);
  background: rgba(228, 237, 219, 0.4);
  border: 1px solid var(--line);
}

.admin-stat strong {
  display: block;
  font-size: 22px;
  color: var(--text);
}

.admin-stat span {
  color: var(--muted);
  font-size: 12px;
}

.admin-list {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.admin-item {
  padding: 18px;
  border-radius: var(--radius);
  background: var(--surface-strong);
  border: 1px solid var(--line);
}

.admin-item .meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.admin-pill {
  font-size: 12px;
  color: var(--accent-strong);
  background: var(--accent-soft);
  border: 1px solid rgba(84, 106, 80, 0.14);
  border-radius: 999px;
  padding: 4px 8px;
}

.admin-item h2 {
  font-size: 15px;
  margin-bottom: 8px;
}

.admin-block {
  margin-top: 10px;
}

.admin-block strong {
  display: block;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.admin-block div {
  font-size: 14px;
  white-space: pre-wrap;
  word-break: break-word;
}

.admin-empty {
  color: var(--muted);
  font-size: 14px;
  margin-top: 16px;
}

/* ═══════════════════════════════════════════════════════════════
   ANIMATIONS
   ═══════════════════════════════════════════════════════════════ */

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes shimmer {
  0% {
    background-position: 180% 0;
  }
  100% {
    background-position: -180% 0;
  }
}

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

.reveal-card {
  opacity: 0;
  animation: fadeSlideUp 0.42s ease forwards;
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════ */

@media (max-width: 1024px) {
  .hero-grid,
  .protocol-dashboard,
  .dashboard-detail-grid,
  .feedback-grid {
    grid-template-columns: 1fr;
  }

  .hero-side-card,
  .dashboard-side {
    order: 2;
  }

  .dashboard-main {
    order: 1;
  }
}

@media (max-width: 980px) {
  .landing-main,
  .protocol-main,
  .content-main,
  .admin-main,
  .app-header,
  .app-footer {
    padding-left: 20px;
    padding-right: 20px;
  }
}

@media (max-width: 720px) {
  body {
    padding: 14px 8px 24px;
  }

  .app-shell {
    border-radius: 24px;
  }

  .landing-main,
  .protocol-main,
  .content-main,
  .admin-main,
  .app-header,
  .app-footer {
    padding-left: 16px;
    padding-right: 16px;
  }

  .hero-card,
  .hero-side-card,
  .input-card,
  .lead-finding-card,
  .why-card,
  .timeline-shell,
  .focus-card,
  .email-capture,
  .unlock-cta,
  .feedback-card,
  .summary-card,
  .info-card,
  .access-banner,
  .loading,
  .score-card,
  .sidebar-widget {
    border-radius: 20px;
  }

  .hero-card--dashboard {
    flex-direction: column;
  }

  .timeline-board {
    grid-template-columns: 1fr;
  }

  .timeline-board::before {
    display: none;
  }

  .timeline-visual-bar {
    grid-template-columns: 1fr;
  }

  .timeline-connector-wrap {
    display: none;
  }

  .score-card {
    grid-template-columns: 1fr;
  }

  .focus-grid {
    grid-template-columns: 1fr;
  }

  .lead-insight-grid {
    grid-template-columns: 1fr;
  }

  .top-nav,
  .input-intro,
  .quick-search-label,
  .cohort-access-row,
  .stack-actions,
  .email-row,
  .rec-card,
  .upgrade-card {
    flex-direction: column;
    align-items: flex-start;
  }

  .nav-links {
    width: 100%;
  }

  .nav-link {
    flex: 1 1 auto;
    text-align: center;
  }

  .cohort-btn,
  .cohort-clear-btn,
  .ghost-btn,
  .email-submit,
  .rec-btn,
  .upgrade-btn,
  .export-btn,
  .share-btn,
  .share-morning-btn {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .hero-kicker,
  .section-label {
    letter-spacing: 0.1em;
  }

  h1 {
    font-size: clamp(1.8rem, 9vw, 2.6rem);
  }

  .timeline-title,
  .timeline-header h2,
  .focus-header h2,
  .feedback-card h2 {
    font-size: 24px;
  }

  .score-row {
    flex-wrap: wrap;
  }

  .score-row-label,
  .score-row-val {
    width: auto;
  }

  .next-dose-bar {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }

  .share-score-card {
    padding: 20px;
  }

  .share-score-header {
    flex-direction: column;
    gap: 12px;
    text-align: center;
  }

  .share-score-stats {
    grid-template-columns: 1fr;
  }

  .social-share-bar {
    flex-direction: column;
  }
}

/* ═══════════════════════════════════════════════════════════════
   SHARE SCORE CARD
   ═══════════════════════════════════════════════════════════════ */

.share-score-card {
  background:
    linear-gradient(135deg, rgba(46, 58, 53, 0.97), rgba(40, 50, 38, 0.98)),
    var(--surface-strong);
  border: 1px solid rgba(127, 151, 119, 0.25);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin: 20px 0;
  color: #e8ece4;
  position: relative;
  overflow: hidden;
  min-width: 0;
}

.share-score-card::before {
  content: "";
  position: absolute;
  top: -40px;
  right: -40px;
  width: 180px;
  height: 180px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(127, 151, 119, 0.15), transparent 70%);
  pointer-events: none;
}

.share-score-header {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 20px;
  min-width: 0;
}

.share-score-ring {
  width: 80px;
  height: 80px;
  border-radius: 999px;
  background: conic-gradient(#7f9777 calc(var(--score-progress, 0) * 1%), rgba(127, 151, 119, 0.2) 0);
  padding: 6px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.share-score-ring-inner {
  width: 100%;
  height: 100%;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(40, 50, 38, 0.95);
  text-align: center;
}

.share-score-ring-num {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: #7f9777;
  line-height: 1;
}

.share-score-ring-label {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(127, 151, 119, 0.7);
  margin-top: 2px;
}

.share-score-info h3 {
  font-size: 18px;
  font-weight: 700;
  color: #e8ece4;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}

.share-score-info p {
  font-size: 13px;
  color: rgba(232, 236, 228, 0.6);
  line-height: 1.4;
}

.share-score-info {
  min-width: 0;
}

.share-score-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 20px;
  min-width: 0;
}

.share-score-stat {
  padding: 12px;
  border-radius: 12px;
  background: rgba(127, 151, 119, 0.1);
  border: 1px solid rgba(127, 151, 119, 0.15);
  text-align: center;
  min-width: 0;
}

.share-score-stat-val {
  font-size: 20px;
  font-weight: 800;
  color: #7f9777;
  letter-spacing: -0.03em;
}

.share-score-stat-label {
  font-size: 11px;
  color: rgba(232, 236, 228, 0.5);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 2px;
  overflow-wrap: anywhere;
}

.share-score-ring-num.locked {
  filter: blur(6px);
  opacity: 0.5;
  user-select: none;
}

.share-score-stat--clickable {
  cursor: pointer;
  transition: background 0.18s, transform 0.12s;
}

.share-score-stat--clickable:hover,
.share-score-stat--clickable:focus-visible {
  background: rgba(127, 151, 119, 0.18);
  transform: translateY(-1px);
}

.share-score-detail {
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.15);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.share-score-detail[hidden] { display: none; }

.share-score-detail-item {
  font-size: 13px;
  padding: 6px 10px;
  border-radius: 8px;
  background: rgba(127, 151, 119, 0.08);
  color: rgba(232, 236, 228, 0.85);
}

.share-score-detail-item--conflict { border-left: 3px solid #f87171; }
.share-score-detail-item--synergy  { border-left: 3px solid #7f9777; }

.share-score-detail-empty {
  font-size: 13px;
  color: rgba(232, 236, 228, 0.5);
  text-align: center;
  padding: 8px;
}

.share-score-detail-locked {
  font-size: 13px;
  color: rgba(232, 236, 228, 0.6);
  text-align: center;
  padding: 10px 8px;
}

.lock-icon-inline {
  font-size: 14px;
  margin-right: 4px;
}

.share-score-unlock-btn {
  display: inline-block;
  margin-top: 8px;
  padding: 6px 14px;
  border-radius: 8px;
  border: 1px solid rgba(127, 151, 119, 0.3);
  background: rgba(127, 151, 119, 0.12);
  color: #c5d1b8;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.18s;
}

.share-score-unlock-btn:hover {
  background: rgba(127, 151, 119, 0.25);
}

.share-score-watermark {
  font-size: 11px;
  color: rgba(127, 151, 119, 0.4);
  text-align: right;
  letter-spacing: 0.04em;
}

.social-share-bar {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
  min-width: 0;
}

.social-share-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 12px;
  border: 1px solid rgba(127, 151, 119, 0.25);
  background: rgba(127, 151, 119, 0.12);
  color: #c0ceba;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.12s;
  min-width: 0;
}

.social-share-btn:hover {
  background: rgba(127, 151, 119, 0.22);
  border-color: rgba(127, 151, 119, 0.4);
  transform: translateY(-1px);
}

.social-share-btn svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.share-score-feedback {
  display: none;
  margin-top: 10px;
  font-size: 13px;
  color: #7f9777;
  font-weight: 600;
}

.email-protocol-panel {
  display: grid;
  gap: 14px;
  margin-top: 20px;
  padding: 22px;
  border-radius: var(--radius);
  border: 1px solid rgba(127, 151, 119, 0.28);
  background: linear-gradient(180deg, rgba(48, 61, 54, 0.88), rgba(39, 49, 37, 0.94));
}

.email-protocol-copy h3 {
  margin: 0;
  font-size: 22px;
  line-height: 1.2;
  color: #f3f5ee;
}

.email-protocol-copy p {
  margin: 8px 0 0;
  color: #c9d3c5;
}

.email-protocol-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 54px;
  padding: 14px 18px;
  border: none;
  border-radius: 14px;
  background: linear-gradient(180deg, #95ab8d, #7f9777);
  color: #fff;
  font-size: 16px;
  font-weight: 800;
  font-family: inherit;
  cursor: pointer;
  transition: transform 0.12s ease, filter 0.15s ease;
}

.email-protocol-toggle:hover {
  filter: brightness(1.05);
  transform: translateY(-1px);
}

.email-protocol-form {
  display: none;
  gap: 8px;
  align-items: stretch;
}
.email-protocol-form.is-open { display: grid; }
.email-protocol-row {
  display: flex;
  gap: 8px;
  align-items: stretch;
}
.email-protocol-row input {
  flex: 1;
  min-width: 0;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid rgba(127, 151, 119, 0.3);
  background: rgba(255, 255, 255, 0.04);
  color: #e8eade;
  font-size: 13px;
  font-family: inherit;
}
.email-protocol-row input:focus {
  outline: none;
  border-color: rgba(127, 151, 119, 0.6);
}
.email-protocol-row button {
  padding: 10px 18px;
  border-radius: 10px;
  border: none;
  background: #7f9777;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
}
.email-protocol-row button:hover { background: #8fa888; }
.email-protocol-row button:disabled { opacity: 0.6; cursor: wait; }
.email-protocol-disclaimer {
  font-size: 12px;
  line-height: 1.45;
  color: #a9b7a3;
}
@media (max-width: 720px) {
  .email-protocol-panel {
    padding: 18px;
  }

  .email-protocol-copy h3 {
    font-size: 20px;
  }

  .email-protocol-row {
    flex-direction: column;
  }
}

@media (max-width: 720px) {
  .details-modal {
    padding: 12px;
  }

  .details-modal-panel {
    width: min(680px, calc(100vw - 24px));
    max-height: min(84vh, 760px);
    padding: 16px;
    border-radius: 22px;
  }

  .supp-detail-grid {
    grid-template-columns: 1fr;
  }

  .details-modal-close {
    top: -2px;
  }

  .share-score-card {
    padding: 18px 16px;
  }

  .share-score-header {
    flex-direction: column;
    align-items: center;
    gap: 14px;
    text-align: center;
  }

  .share-score-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .social-share-bar {
    display: grid;
    grid-template-columns: 1fr;
  }

  .social-share-btn {
    width: 100%;
    justify-content: center;
    text-align: center;
  }
}

/* ═══════════════════════════════════════════════════════════════
   SHARE LINK BANNER (for ?s= param visitors)
   ═══════════════════════════════════════════════════════════════ */

.share-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 22px;
  margin-bottom: 20px;
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(228, 237, 219, 0.95), rgba(208, 221, 197, 0.9));
  border: 1px solid rgba(84, 106, 80, 0.18);
}

.share-banner-text {
  font-size: 14px;
  color: var(--text);
  line-height: 1.45;
}

.share-banner-text strong {
  color: var(--accent-strong);
}

.share-banner-btn {
  flex-shrink: 0;
  padding: 10px 18px;
  border-radius: 12px;
  border: 1px solid var(--accent-strong);
  background: var(--accent-strong);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.12s, box-shadow 0.12s;
  white-space: nowrap;
}

.share-banner-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(84, 106, 80, 0.25);
}


/* ═══════════════════════════════════════════════════════════════
   CURATED PROTOCOL LIBRARY
   ═══════════════════════════════════════════════════════════════ */

.protocol-library {
  margin-top: 10px;
  margin-bottom: 28px;
}

.protocol-library-header {
  margin-bottom: 16px;
}

.protocol-library-header h2 {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}

.protocol-library-header p {
  font-size: 14px;
  color: var(--muted);
}

.protocol-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

@media (max-width: 900px) {
  .protocol-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
  .protocol-grid { grid-template-columns: 1fr; }

  .protocol-card-top { flex-wrap: wrap; }
}

.protocol-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  cursor: pointer;
  transition: transform 0.18s, box-shadow 0.18s, border-color 0.18s;
  position: relative;
  overflow: hidden;
}

.protocol-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.protocol-card-top .protocol-card-badge {
  margin-bottom: 0;
}

.protocol-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-strong));
  opacity: 0;
  transition: opacity 0.18s;
}

.protocol-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(78, 91, 63, 0.14);
  border-color: var(--accent);
}

.protocol-card:focus-visible {
  outline: 2px solid rgba(84, 106, 80, 0.3);
  outline-offset: 2px;
}

.protocol-card:hover::before {
  opacity: 1;
}

.protocol-card-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 6px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  margin-bottom: 10px;
}

.protocol-card-badge--cta {
  margin-bottom: 0;
  border: 1px solid rgba(84, 106, 80, 0.18);
  background: rgba(84, 106, 80, 0.08);
  color: var(--accent-strong);
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.18s, border-color 0.18s, transform 0.18s;
}

.protocol-card-badge--cta:hover,
.protocol-card-badge--cta:focus-visible {
  background: rgba(84, 106, 80, 0.14);
  border-color: rgba(84, 106, 80, 0.28);
  transform: translateY(-1px);
}

.protocol-card h3 {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}

.protocol-card-desc {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.protocol-card-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.protocol-card-pill {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 8px;
  background: var(--surface-soft);
  color: var(--muted-strong);
  border: 1px solid var(--line);
  white-space: nowrap;
}

.protocol-card-count {
  font-size: 12px;
  color: var(--muted);
  margin-top: 10px;
  font-weight: 600;
}

.protocol-card-cta {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 700;
  color: var(--accent-strong);
  margin-top: 12px;
  transition: gap 0.15s;
}

.protocol-card:hover .protocol-card-cta {
  gap: 8px;
}


/* ═══════════════════════════════════════════════════════════════
   INTERACTION MAP
   ═══════════════════════════════════════════════════════════════ */

.interaction-map-section {
  margin: 28px 0;
}

.interaction-map-section .section-label {
  margin-bottom: 4px;
}

.interaction-map-section h2 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 6px;
}

.interaction-map-section > p {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 16px;
}

.interaction-map-wrap {
  position: relative;
  background: linear-gradient(145deg, var(--surface-strong), var(--surface-soft));
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
}

.interaction-map-canvas {
  display: block;
  width: 100%;
  height: auto;
  cursor: grab;
}

.interaction-map-canvas:active {
  cursor: grabbing;
}

.interaction-map-legend {
  display: flex;
  gap: 20px;
  padding: 12px 18px;
  background: var(--surface-soft);
  border-top: 1px solid var(--line);
}

.interaction-map-legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted-strong);
}

.legend-line {
  width: 24px;
  height: 3px;
  border-radius: 2px;
}

.legend-line--conflict {
  background: #e07a6e;
  box-shadow: 0 0 6px rgba(224, 122, 110, 0.5);
}

.legend-line--synergy {
  background: #8ec282;
  box-shadow: 0 0 6px rgba(142, 194, 130, 0.5);
}

.legend-line--neutral {
  background: rgba(255, 255, 255, 0.2);
}

.interaction-map-tooltip {
  position: absolute;
  background: var(--surface-strong);
  border: 1px solid var(--line-strong);
  color: var(--text);
  font-size: 12px;
  padding: 8px 12px;
  border-radius: 8px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s;
  z-index: 10;
  max-width: 220px;
  line-height: 1.45;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.interaction-map-tooltip.visible {
  opacity: 1;
}

.interaction-map-empty {
  padding: 40px 20px;
  text-align: center;
  color: var(--muted);
  font-size: 14px;
}


/* ═══════════════════════════════════════════════════════════════
   ABSORPTION TIMELINE
   ═══════════════════════════════════════════════════════════════ */

.absorption-section {
  margin: 28px 0;
}

.absorption-section .section-label {
  margin-bottom: 4px;
}

.absorption-section h2 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 6px;
}

.absorption-section > p {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 16px;
}

.absorption-timeline {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 20px 20px 14px;
  overflow-x: auto;
}

.absorption-axis {
  display: flex;
  justify-content: space-between;
  padding: 0 0 10px;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--line);
  position: relative;
}

.absorption-axis span {
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.absorption-rows {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-top: 8px;
}

.absorption-row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 28px;
}

.absorption-label {
  flex-shrink: 0;
  width: 130px;
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: right;
}

.absorption-track {
  flex: 1;
  position: relative;
  height: 22px;
  background: var(--surface-soft);
  border-radius: 11px;
  overflow: hidden;
}

.absorption-bar {
  position: absolute;
  top: 2px;
  bottom: 2px;
  border-radius: 9px;
  transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1), left 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.absorption-bar--metabolic,
.absorption-bar--vitamin { background: linear-gradient(90deg, #f0c96e, #e8b84a); }
.absorption-bar--mineral { background: linear-gradient(90deg, #8ab8d4, #6da4c4); }
.absorption-bar--performance { background: linear-gradient(90deg, #e88a6e, #d97050); }
.absorption-bar--amino { background: linear-gradient(90deg, #c094d0, #a87abc); }
.absorption-bar--adaptogen { background: linear-gradient(90deg, #8ec282, #6db560); }
.absorption-bar--sleep { background: linear-gradient(90deg, #7a8ec2, #5c74b0); }
.absorption-bar--antioxidant { background: linear-gradient(90deg, #d498a0, #c47e88); }
.absorption-bar--fatty_acid { background: linear-gradient(90deg, #e8c48a, #d4a86e); }
.absorption-bar--hormonal { background: linear-gradient(90deg, #d0a0d8, #be88c8); }
.absorption-bar--general { background: linear-gradient(90deg, #9ec2a0, #82b086); }
.absorption-bar--probiotic { background: linear-gradient(90deg, #a0c8b8, #84b8a4); }
.absorption-bar--electrolyte { background: linear-gradient(90deg, #b0c8e0, #96b4d0); }
.absorption-bar--protein { background: linear-gradient(90deg, #d4a888, #c49070); }
.absorption-bar--default { background: linear-gradient(90deg, #b8b8b8, #a0a0a0); }

.absorption-period-markers {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
}

.absorption-period-marker {
  position: absolute;
  top: 0;
  bottom: 0;
  border-left: 1px dashed var(--line);
}

.absorption-bar-label {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 9px;
  font-weight: 700;
  color: rgba(0, 0, 0, 0.5);
  white-space: nowrap;
  pointer-events: none;
}

@media (max-width: 640px) {
  .absorption-label { width: 80px; font-size: 11px; }
  .absorption-axis span { font-size: 10px; }
}


/* ═══════════════════════════════════════════════════════════════
   ENHANCED SHARE CARD
   ═══════════════════════════════════════════════════════════════ */

.share-score-card {
  position: relative;
  overflow: hidden;
}

.share-score-card::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -50%;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle, rgba(127, 151, 119, 0.08), transparent 70%);
  pointer-events: none;
}

.share-card-download-row {
  display: flex;
  justify-content: center;
  padding-top: 8px;
}

.share-card-download-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--surface-soft);
  color: var(--muted-strong);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.12s;
}

.share-card-download-btn:hover {
  background: var(--accent-soft);
  border-color: var(--accent);
  transform: translateY(-1px);
}

.share-card-download-btn svg {
  width: 14px;
  height: 14px;
}


/* ═══════════════════════════════════════════════════════════════
   PUBMED CITATION TOOLTIPS
   ═══════════════════════════════════════════════════════════════ */

.pubmed-tip {
  position: fixed;
  z-index: 9999;
  background: var(--surface-strong);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  max-width: 320px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
  pointer-events: none;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.18s, transform 0.18s;
  font-family: var(--font-body);
  line-height: 1.5;
}

.pubmed-tip.visible {
  opacity: 1;
  transform: translateY(0);
}

.pubmed-tip-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
  line-height: 1.4;
}

.pubmed-tip-meta {
  font-size: 11px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 8px;
}

.pubmed-tip-meta .pubmed-badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 6px;
  border-radius: 4px;
  background: #326599;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.pubmed-tip-meta .pubmed-year {
  font-weight: 700;
  color: var(--muted-strong);
}

/* ─── Dose Disclaimer Info Icon & Tooltip ────────────────────────────────── */

.dose-info-btn {
  all: unset;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  margin-left: 5px;
  color: var(--muted);
  cursor: pointer;
  vertical-align: middle;
  border-radius: 50%;
  transition: color 0.15s, background 0.15s;
  flex-shrink: 0;
  position: relative;
  top: -0.5px;
}

.dose-info-btn:hover {
  color: var(--accent-strong);
  background: rgba(84, 106, 80, 0.08);
}

.supp-row-dose,
.detail-dosage {
  position: relative;
}

.dose-disclaimer {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  width: max-content;
  max-width: 270px;
  padding: 10px 14px;
  background: var(--surface, #fff);
  border: 1px solid rgba(84, 106, 80, 0.14);
  border-radius: 10px;
  box-shadow: 0 6px 24px rgba(30, 40, 28, 0.12), 0 1px 4px rgba(30, 40, 28, 0.06);
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--muted-strong, #555);
  z-index: 1100;
  animation: doseDiscFadeIn 0.14s ease;
  pointer-events: auto;
}

.dose-disclaimer::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: var(--surface, #fff);
  filter: drop-shadow(0 1px 1px rgba(30, 40, 28, 0.08));
}

/* Inside cards and detail modal, open downward instead */
.supp-row-dose .dose-disclaimer,
.detail-dosage .dose-disclaimer {
  bottom: auto;
  top: calc(100% + 8px);
}

.supp-row-dose .dose-disclaimer::after,
.detail-dosage .dose-disclaimer::after {
  top: auto;
  bottom: 100%;
  border-top-color: transparent;
  border-bottom-color: var(--surface, #fff);
}

@keyframes doseDiscFadeIn {
  from { opacity: 0; transform: translateX(-50%) translateY(3px); }
  to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}

/* Mobile: anchor left instead of center to prevent overflow */
@media (max-width: 600px) {
  .dose-disclaimer {
    left: 0;
    transform: none;
    max-width: 240px;
  }
  .dose-disclaimer::after {
    left: 14px;
    transform: none;
  }
  @keyframes doseDiscFadeIn {
    from { opacity: 0; transform: translateY(3px); }
    to   { opacity: 1; transform: translateY(0); }
  }
}
