/* Import centralized design tokens */
@import '_tokens.css';

:root {
  /* Font stacks */
  --mono:
    "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

:focus-visible {
  outline: 2px solid rgba(26, 188, 156, 0.7);
  outline-offset: 3px;
  border-radius: 3px;
}

/* ============================================
   UNIFIED TOGGLE BUTTON
   ============================================ */
.toggle-btn {
  padding: 10px 24px;
  min-height: 44px;
  border: 1px solid var(--accent);
  background: transparent;
  border-radius: 999px;
  color: var(--text-muted);
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

@media (hover: hover) {
  .toggle-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
  }
}

.toggle-btn.active {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(26, 188, 156, 0.08);
}

/* ============================================
   GENDER SELECTOR (Separate Component)
   ============================================ */
.gender-btn {
  padding: 10px 24px;
  min-height: 44px;
  border: 1px solid var(--accent);
  background: transparent;
  border-radius: 999px;
  color: var(--text-muted);
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

@media (hover: hover) {
  .gender-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
  }
}

.gender-btn.active {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(26, 188, 156, 0.08);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

html,
body {
  background: var(--bg);
  color: var(--text);
  font-family:
    "Manrope",
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    sans-serif;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.5;
  letter-spacing: -0.005em;
  min-height: 100vh;
}

/* subtle dot grid + radial accent — tech feel without noise */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    radial-gradient(
      circle at 50% -10%,
      rgba(26, 188, 156, 0.1),
      transparent 55%
    ),
    radial-gradient(rgba(94, 234, 212, 0.05) 1px, transparent 1px);
  background-size:
    auto,
    22px 22px;
  background-position:
    0 0,
    0 0;
}

.container {
  position: relative;
  z-index: 1;
}

/* ============================================
   LANGUAGE TOGGLE — fixed top-right
   ============================================ */
/* Single-pill language picker */
.lang-picker {
  position: fixed;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 50;
}

.lang-pill {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(15, 24, 25, 0.72);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 9px 22px 9px 16px;
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-faint);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 6px 18px -8px rgba(0, 0, 0, 0.6);
  transition: border-color 0.2s, color 0.2s;
  min-height: 42px;
  white-space: nowrap;
  min-width: 320px;
}

.lang-globe {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  opacity: 0.55;
}

.lang-pill-word {
  color: var(--text-faint);
  letter-spacing: 0.01em;
}

.lang-pill-sep {
  color: var(--border-strong);
  font-weight: 400;
}

.lang-pill-active {
  color: var(--text);
  font-weight: 700;
}

.lang-pill-chevron {
  opacity: 0.5;
  transition: transform 0.22s var(--ease-out);
}

.lang-pill[aria-expanded="true"] .lang-pill-chevron {
  transform: rotate(180deg);
}

@media (hover: hover) {
  .lang-pill:hover {
    border-color: rgba(26, 188, 156, 0.35);
    color: var(--text-muted);
  }
}

/* Dropdown */
.lang-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(-4px) scale(0.96);
  min-width: 320px;
  max-width: 90vw;
  background: rgba(13, 20, 22, 0.96);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 5px;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 16px 36px -10px rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  gap: 1px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s var(--ease-out), transform 0.2s var(--ease-out);
  z-index: 60;
}

.lang-dropdown.is-open {
  opacity: 1;
  transform: translateX(-50%) translateY(0) scale(1);
  pointer-events: auto;
}

.lang-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  padding: 10px 14px;
  border-radius: 8px;
  cursor: pointer;
  font-family: inherit;
  font-size: 13px;
  font-weight: 500;
  text-align: left;
  width: 100%;
  transition: color 0.15s, background 0.15s;
}

.lang-option:disabled {
  cursor: default;
  opacity: 0.6;
}

.lang-option--active {
  color: var(--text);
  background: var(--accent-dim);
  font-weight: 700;
}

@media (hover: hover) {
  .lang-option:not(:disabled):hover {
    color: var(--text);
    background: rgba(94, 234, 212, 0.08);
  }
}

/* "Coming soon" badge */
.lang-soon {
  flex-shrink: 0;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.03em;
  color: var(--text-faint);
  white-space: nowrap;
}

/* ============================================
   TOP INSTAGRAM FOLLOW BUTTON
   ============================================ */
.top-ig {
  position: fixed;
  top: 18px;
  right: 18px;
  z-index: 50;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(15, 24, 25, 0.72);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 7px 14px;
  color: var(--text-muted);
  text-decoration: none;
  font-family: inherit;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.01em;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 6px 18px -8px rgba(0, 0, 0, 0.6);
  transition:
    color 0.3s var(--ease-out),
    background 0.3s var(--ease-out),
    border-color 0.3s var(--ease-out),
    transform 0.3s var(--ease-out);
}

.top-ig .ig-icon {
  transition: transform 0.4s var(--ease-spring);
}

@media (hover: hover) {
  .top-ig:hover {
    color: var(--accent-soft);
    background: rgba(26, 188, 156, 0.1);
    border-color: var(--border-strong);
    transform: translateY(-1px);
  }
  .top-ig:hover .ig-icon {
    transform: rotate(-8deg) scale(1.1);
  }
}

@media (max-width: 540px) {
  /* Icon-only on mobile so the centered lang toggle has room */
  .top-ig {
    padding: 8px;
    gap: 0;
  }
  .top-ig span {
    display: none;
  }
  .top-ig .ig-icon {
    width: 16px;
    height: 16px;
  }
}

.container {
  max-width: 660px;
  margin: 0 auto;
  padding: 130px 22px 40px;
  display: flex;
  flex-direction: column;
  gap: 56px;
}

/* ============================================
   MOTION: reveal-on-scroll
   ============================================ */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.8s var(--ease-out),
    transform 0.8s var(--ease-out);
  will-change: opacity, transform;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .logo-circle,
  .protein-circle img,
  .macros-chart img {
    animation: none !important;
  }
  * {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}

/* ============================================
   HERO
   ============================================ */
.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 4px;
  padding-top: 12px;
}

.logo-circle {
  position: relative;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
  margin-bottom: 14px;
  animation: float 4.5s ease-in-out infinite, breathe 2.5s ease-in-out infinite;
}

/* soft teal halo sitting behind the logo */
.logo-circle::before {
  content: "";
  position: absolute;
  inset: -22%;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(26, 188, 156, 0.45) 0%,
    rgba(26, 188, 156, 0.18) 40%,
    transparent 70%
  );
  filter: blur(10px);
  z-index: -1;
  animation: glow-enhanced 2.5s ease-in-out infinite;
  pointer-events: none;
}

.logo-circle img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  border-radius: 50%;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-6px);
  }
}

@keyframes glow-pulse {
  0%,
  100% {
    opacity: 0.7;
    transform: scale(1);
  }
  50% {
    opacity: 1;
    transform: scale(1.08);
  }
}

@keyframes breathe {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.06);
  }
}

@keyframes glow-enhanced {
  0%,
  100% {
    opacity: 0.45;
  }
  50% {
    opacity: 0.65;
  }
}

.brand-title {
  background: linear-gradient(180deg, #5eead4 0%, #1abc9c 70%, #0c5a4a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: 42px;
  font-weight: 800;
  letter-spacing: -1.4px;
  line-height: 1.1;
  margin-bottom: 4px;
  filter: drop-shadow(0 0 24px rgba(26, 188, 156, 0.25));
}

.brand-subtitle {
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 400;
  font-style: italic;
  letter-spacing: 0.01em;
}

/* ============================================
   CARDS
   ============================================ */
.card {
  position: relative;
  background:
    linear-gradient(180deg, rgba(94, 234, 212, 0.03), transparent 30%),
    var(--card-bg);
  border-radius: 20px;
  padding: 40px 34px;
  border: 1px solid var(--border);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.03) inset,
    0 24px 60px -28px rgba(0, 0, 0, 0.6);
  transition:
    transform 0.4s var(--ease-out),
    box-shadow 0.4s var(--ease-out),
    border-color 0.4s var(--ease-out);
}

/* hairline accent at top edge of every card */
.card::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 24px;
  right: 24px;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--border-strong),
    transparent
  );
  pointer-events: none;
}

.card-title {
  font-size: 24px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 8px;
  letter-spacing: -0.4px;
}

.card-subtitle {
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 400;
  margin-bottom: 20px;
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.5;
}

/* ============================================
   UNIT TOGGLE (Metric / Imperial)
   ============================================ */
.unit-toggle {
  display: flex;
  width: fit-content;
  background: var(--input-bg);
  border-radius: 999px;
  padding: 3px;
  margin: 0 auto 32px;
}


/* ============================================
   REC CARD SHIMMER — rotating conic-gradient border
   ============================================ */
@property --shimmer-angle {
  syntax: "<angle>";
  initial-value: 0deg;
  inherits: false;
}

@keyframes shimmer-spin {
  to { --shimmer-angle: 360deg; }
}

@keyframes shimmer-fade {
  0%, 80% { opacity: 1; }
  100%     { opacity: 0; }
}

@keyframes rec-glow-in {
  0%   {
    box-shadow: 0 0 0 0 rgba(94,234,212,0), 0 24px 60px -28px rgba(0,0,0,.6);
    border-color: var(--border);
  }
  25%  {
    box-shadow: 0 0 0 2px rgba(94,234,212,.7), 0 0 36px rgba(26,188,156,.45), 0 24px 60px -28px rgba(0,0,0,.6);
    border-color: rgba(94,234,212,.55);
  }
  75%  {
    box-shadow: 0 0 0 2px rgba(94,234,212,.7), 0 0 36px rgba(26,188,156,.45), 0 24px 60px -28px rgba(0,0,0,.6);
    border-color: rgba(94,234,212,.55);
  }
  100% {
    box-shadow: 0 0 0 1px rgba(94,234,212,.22), 0 0 18px rgba(26,188,156,.14), 0 24px 60px -28px rgba(0,0,0,.6);
    border-color: rgba(94,234,212,.22);
  }
}

/* ============================================
   PROGRESSIVE DISCLOSURE
   ============================================ */
@keyframes slide-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.slide-in {
  animation: slide-in 0.5s var(--ease-out) both;
}

/* ============================================
   BMI CARD: INPUTS
   ============================================ */
.field {
  text-align: center;
  margin-bottom: 26px;
}

.field:last-of-type {
  margin-bottom: 8px;
}

.field-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 12px;
  letter-spacing: 0.005em;
}

.unit-toggle--inline {
  margin: 0 auto 16px;
}

.input-row {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.input-pill {
  background: var(--input-bg);
  border-radius: 999px;
  padding: 6px 6px 6px 20px;
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 140px;
  transition:
    background 0.2s var(--ease-out),
    box-shadow 0.2s var(--ease-out);
}

.input-pill:focus-within {
  background: #243031;
  box-shadow: 0 0 0 2px rgba(26, 188, 156, 0.25);
}

.input-pill input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text);
  font-family: inherit;
  font-size: 15px;
  font-weight: 500;
  width: 42px;
  -moz-appearance: textfield;
}

.input-pill input::-webkit-outer-spin-button,
.input-pill input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.input-pill input::placeholder {
  color: var(--text-faint);
  font-weight: 400;
}

.input-pill .unit {
  background: var(--card-bg-alt);
  color: var(--text-muted);
  padding: 7px 16px;
  border-radius: 999px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.04em;
  margin-left: auto;
}

/* gender buttons */
.gender-row {
  gap: 10px;
  width: fit-content;
  margin: 0 auto;
}


/* ============================================
   BMI RESULT
   ============================================ */
.bmi-result {
  text-align: center;
  margin-top: 28px;
  margin-bottom: 28px;
}

.bmi-result-label {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 6px;
  letter-spacing: 0.01em;
}

.bmi-result-value {
  font-size: 64px;
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -2px;
  transition: transform 0.4s var(--ease-spring);
  display: inline-block;
}

.bmi-result-value.pulse {
  transform: scale(1.08);
}

/* ============================================
   BMI SCALE
   ============================================ */
.bmi-scale {
  margin-top: 12px;
}

.bmi-pointer-container {
  position: relative;
  height: 20px;
  margin-bottom: 8px;
}

.bmi-pointer-head {
  position: absolute;
  left: 30%;
  top: 0;
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 7px solid var(--pointer);
  transform: translateX(-50%);
  transition: left 0.7s var(--ease-spring);
}

.bmi-pointer {
  position: absolute;
  left: 30%;
  top: 7px;
  width: 2px;
  height: 13px;
  background: var(--pointer);
  transform: translateX(-50%);
  transition: left 0.7s var(--ease-spring);
}

.bmi-scale-bar {
  display: flex;
  gap: 4px;
  height: 10px;
  width: 100%;
}

.bmi-segment {
  flex: 1;
  border-radius: 3px;
  transition:
    filter 0.3s var(--ease-out),
    transform 0.3s var(--ease-out);
}

/* Zone color coding */
.seg-1 {
  background: #3d7d75;
}
.seg-2 {
  background: #1abc9c;
}
.seg-3 {
  background: #d4a04a;
}
.seg-4 {
  background: #d65656;
}

.bmi-scale-labels {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
  margin-top: 12px;
}

.scale-label {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 12px;
}

.scale-name {
  color: var(--text);
  font-weight: 600;
  letter-spacing: 0.005em;
}

.scale-range {
  color: var(--text-faint);
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.02em;
}

.bmi-reset-btn[hidden] { display: none; }

/* BMI plan loader — shown once after first valid weight */
.bmi-loader {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 24px 0 8px;
}

.bmi-loader[hidden] { display: none; }

.bmi-loader-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  animation: cond-fade-up 0.35s var(--ease-out) both;
}

.bmi-loader-dots {
  display: flex;
  gap: 7px;
  align-items: center;
}

.bmi-loader-dots span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.5;
  animation: cond-dot-bounce 1.1s ease-in-out infinite;
}

.bmi-loader-dots span:nth-child(2) { animation-delay: 0.18s; }
.bmi-loader-dots span:nth-child(3) { animation-delay: 0.36s; }

.bmi-reset-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 16px auto 0;
  background: transparent;
  border: none;
  padding: 12px 20px;
  min-height: 44px;
  cursor: pointer;
  color: var(--text-faint);
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s;
}

@media (hover: hover) {
  .bmi-reset-btn:hover {
    color: var(--text-muted);
  }
}

.bmi-cta {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.bmi-cta[hidden] {
  display: none;
}

.bmi-cta-text {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  text-align: center;
  line-height: 1.5;
}

.bmi-cta-category {
  color: #1abc9c;
  font-weight: 800;
}

.bmi-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 20px;
  min-height: 44px;
  border-radius: 999px;
  border: 1.5px solid var(--border-strong);
  background: transparent;
  color: var(--accent);
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, transform 0.2s var(--ease-out);
}

.bmi-cta-btn svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  transition: transform 0.3s var(--ease-out);
}

@media (hover: hover) {
  .bmi-cta-btn:hover {
    background: rgba(26, 188, 156, 0.08);
    border-color: var(--accent);
    transform: translateY(1px);
  }
  .bmi-cta-btn:hover svg {
    transform: translateY(3px);
  }
}

/* ============================================
   PROTEIN STATS CARD
   ============================================ */
.protein-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 16px;
}

.stat-block {
  text-align: center;
}

.stat-label {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.stat-value {
  font-size: 38px;
  font-weight: 700;
  letter-spacing: -0.8px;
  transition: transform 0.4s var(--ease-spring);
  display: inline-block;
}

.stat-value.pulse {
  transform: scale(1.08);
}

.stat-sublabel {
  font-size: 12px;
  color: var(--text-faint);
  margin-top: 3px;
  font-weight: 500;
}

/* ============================================
   RECOMMENDATIONS SECTION (stacked cards)
   ============================================ */
.recommendations {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 8px 0;
}

.recommendations .section-title {
  text-align: center;
  margin-bottom: 6px;
}

/* Gradient-text section title with flanking sparkles */
.section-title--shine {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
}

.section-title--shine > span {
  background: linear-gradient(180deg, #5eead4 0%, #1abc9c 70%, #0c5a4a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 18px rgba(26, 188, 156, 0.22));
}

.sparkle {
  width: 18px;
  height: 18px;
  color: var(--accent);
  flex-shrink: 0;
  filter: drop-shadow(0 0 6px currentColor);
  transform-origin: center;
  animation: sparkle-twinkle 2.8s ease-in-out infinite;
}

.sparkle--left {
  animation-delay: 0s;
}
.sparkle--right {
  animation-delay: 1.4s;
}

@keyframes sparkle-twinkle {
  0%,
  100% {
    transform: rotate(0deg) scale(0.85);
    opacity: 0.55;
  }
  50% {
    transform: rotate(180deg) scale(1.15);
    opacity: 1;
  }
}

.rec-card {
  padding: 26px 30px;
  isolation: isolate;
}

/* Smooth unlock transition */
.recommendations .rec-card {
  transition: opacity 0.6s var(--ease-out), box-shadow 0.4s var(--ease-out), border-color 0.4s var(--ease-out);
}

/* Live state: glow-in animation + persistent subtle border */
.rec-card--live {
  animation: rec-glow-in 2.4s var(--ease-out) forwards;
}

/* Rotating shimmer stroke via ::after */
.rec-card--live::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 21px;
  background: conic-gradient(
    from var(--shimmer-angle),
    transparent 0%,
    rgba(94, 234, 212, .45) 12%,
    rgba(26, 188, 156, .75) 22%,
    transparent 40%
  );
  z-index: -1;
  animation:
    shimmer-spin 1.5s linear 2,
    shimmer-fade 3.2s var(--ease-out) forwards;
}

/* Locked state — before BMI is calculated */
.recommendations--locked .rec-card {
  opacity: 0.3;
  pointer-events: none;
  user-select: none;
}

.rec-unlock-hint {
  display: none;
  text-align: center;
  font-size: 13px;
  color: var(--text-faint);
  margin-top: -8px;
  margin-bottom: 16px;
  letter-spacing: 0.01em;
}

.recommendations--locked .rec-unlock-hint {
  display: block;
}

.rec-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
}

.rec-icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  filter: drop-shadow(0 0 6px currentColor);
  transform-origin: center;
}

/* All three rec icons animate simultaneously, each with a full-cycle keyframe */

/* PROTEIN — continuous dumbbell curl */
.rec-icon--protein {
  color: #1abc9c;
  filter: drop-shadow(0 0 5px currentColor);
  animation: rec-curl 3s ease-in-out infinite;
}
@keyframes rec-curl {
  0%    { transform: rotate(0deg)   scale(1);    filter: drop-shadow(0 0 5px currentColor); }
  20%   { transform: rotate(-14deg) scale(0.92); filter: drop-shadow(0 0 4px currentColor); }
  45%   { transform: rotate(14deg)  scale(1.18); filter: drop-shadow(0 0 13px currentColor); }
  70%   { transform: rotate(-12deg) scale(0.94); filter: drop-shadow(0 0 4px currentColor); }
  90%   { transform: rotate(0deg)   scale(1);    filter: drop-shadow(0 0 5px currentColor); }
  100%  { transform: rotate(0deg)   scale(1);    filter: drop-shadow(0 0 5px currentColor); }
}

/* WATER — continuous drip morph */
.rec-icon--water {
  color: #5eead4;
  filter: drop-shadow(0 0 5px currentColor);
  animation: rec-drip 3s ease-in-out infinite;
}
@keyframes rec-drip {
  0%    { transform: scaleX(1)    scaleY(1)    translateY(0);    filter: drop-shadow(0 0 5px currentColor); }
  22%   { transform: scaleX(0.82) scaleY(1.22) translateY(-4px); filter: drop-shadow(0 0 12px currentColor); }
  50%   { transform: scaleX(1.18) scaleY(0.82) translateY(4px);  filter: drop-shadow(0 0 8px currentColor); }
  78%   { transform: scaleX(0.96) scaleY(1.06) translateY(-2px); filter: drop-shadow(0 0 6px currentColor); }
  100%  { transform: scaleX(1)    scaleY(1)    translateY(0);    filter: drop-shadow(0 0 5px currentColor); }
}

/* MOVEMENT — continuous marching feet */
.rec-icon--movement {
  color: #d4a04a;
}
.rec-icon--movement .foot {
  transform-origin: center;
}
.rec-icon--movement .foot-left {
  animation: rec-march 2.4s ease-in-out infinite;
  animation-delay: 0s;
}
.rec-icon--movement .foot-right {
  animation: rec-march 2.4s ease-in-out infinite;
  animation-delay: 0.4s;
}
@keyframes rec-march {
  0%    { transform: translateY(0)    scale(1);    opacity: 0.35; }
  20%   { transform: translateY(-6px) scale(1.14); opacity: 1;    filter: drop-shadow(0 0 7px #d4a04a); }
  40%   { transform: translateY(0)    scale(1);    opacity: 0.35; }
  60%   { transform: translateY(-6px) scale(1.14); opacity: 1;    filter: drop-shadow(0 0 7px #d4a04a); }
  80%   { transform: translateY(0)    scale(1);    opacity: 0.35; }
  100%  { transform: translateY(0)    scale(1);    opacity: 0.35; }
}

.rec-tag {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

/* Slim variant of stat values inside rec cards */
.rec-card .stat-value {
  font-size: 32px;
}

/* Combined single rec card — remove water unit row bottom border gap */
.rec-bmi {
  text-align: center;
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px dashed var(--border);
}

.rec-bmi .stat-label {
  margin-bottom: 6px;
}

.rec-combined-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
}

.rec-stat-col {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px 8px;
}

.rec-stat-col .rec-header {
  flex-direction: column;
  align-items: center;
  gap: 6px;
  margin-bottom: 12px;
}

.rec-stat-col .stat-label {
  margin-bottom: 4px;
}


/* ============================================
   GOAL SLIDER (Lose / Maintain / Gain)
   ============================================ */
.goal-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px dashed var(--border);
}

.goal-prompt {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  flex-shrink: 0;
}

.goal-slider {
  position: relative;
  display: flex;
  align-items: center;
  background: var(--input-bg);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 5px 8px;
  flex: 1;
  max-width: 360px;
  isolation: isolate;
}

.goal-dot {
  flex-shrink: 0;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-faint);
  opacity: 0.55;
  transition:
    background 0.3s var(--ease-out),
    opacity 0.3s var(--ease-out);
}

.goal-dot--left {
  margin-right: 6px;
}
.goal-dot--right {
  margin-left: 6px;
}

/* Goal slider buttons use .toggle-btn with custom positioning below */
.goal-slider .toggle-btn {
  position: relative;
  z-index: 2;
  flex: 1;
  padding: 10px 6px;
  border: none;
  background: transparent;
  color: var(--text-faint);
  white-space: nowrap;
  transition: color 0.35s var(--ease-out);
}

.goal-slider .toggle-btn:hover {
  border-color: transparent;
  color: var(--text-muted);
}

.goal-slider .toggle-btn.active {
  border-color: transparent;
  background: transparent;
  color: var(--text);
  font-weight: 600;
}

.goal-thumb {
  position: absolute;
  z-index: 1;
  top: 5px;
  bottom: 5px;
  background: linear-gradient(
    180deg,
    var(--accent-dim) 0%,
    var(--accent-deep) 100%
  );
  border-radius: 999px;
  box-shadow:
    0 0 0 1px rgba(94, 234, 212, 0.18) inset,
    0 4px 14px rgba(26, 188, 156, 0.28);
  transition:
    left 0.45s var(--ease-spring),
    width 0.45s var(--ease-spring);
  pointer-events: none;
}

/* ============================================
   PROTEIN SOURCES GRID (How to get 25g)
   ============================================ */
.protein-sources {
  text-align: center;
  padding: 8px 0;
}

.diet-filter-toggle {
  margin-bottom: 28px;
}

.sources-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  text-align: left;
}

.source-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--card-bg);
  border-radius: 12px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.03);
  transition:
    transform 0.35s var(--ease-out),
    box-shadow 0.35s var(--ease-out);
}


@media (hover: hover) {
  .source-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 22px rgba(26, 188, 156, 0.18);
  }
  .source-card:hover .source-image img {
    transform: scale(1.06);
  }
}

.source-image {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 8px;
  overflow: hidden;
  background: var(--card-bg-alt);
}

.source-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s var(--ease-out);
}

.source-card figcaption {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 0 2px 4px;
}

.source-amount {
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
  line-height: 1.25;
}

.source-name {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  letter-spacing: 0.01em;
  line-height: 1.3;
}

/* ============================================
   SECTION TITLES (used by food macros)
   ============================================ */
.section-title {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 32px;
  letter-spacing: -0.4px;
}

.section-title.big {
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -0.8px;
  margin-bottom: 6px;
}

/* ============================================
   FOOD MACROS
   ============================================ */
.macros-section {
  text-align: center;
  padding: 8px 0;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 400;
  margin-bottom: 0;
}

.macros-chart {
  width: 180px;
  margin: 0 auto 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  transition: transform 0.6s var(--ease-spring);
}

.macros-chart-caption {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  font-style: italic;
}

.macros-pie {
  width: 180px;
  height: 180px;
  filter: drop-shadow(0 8px 20px rgba(26, 188, 156, 0.22));
}

.pie-slice {
  cursor: pointer;
  transition: opacity 0.18s ease, transform 0.18s ease;
  transform-origin: 100px 100px;
}

@media (hover: hover) {
  .pie-slice:hover {
    opacity: 0.82;
    transform: scale(1.06);
  }
}

.macros-intro {
  text-align: center;
  color: var(--text);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.65;
  margin-bottom: 16px;
  padding: 0 12px;
  max-width: 540px;
  margin-left: auto;
  margin-right: auto;
}

.macros-see-all {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin: 0 auto 0;
  padding: 10px 22px;
  min-height: 44px;
  border: 1.5px solid var(--border);
  border-radius: 999px;
  background: none;
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  letter-spacing: 0.01em;
  transition: border-color 0.2s, color 0.2s;
}

.macros-see-all svg {
  width: 14px;
  height: 14px;
  transition: transform 0.25s ease;
}

.macros-see-all--open svg {
  transform: rotate(180deg);
}

@media (hover: hover) {
  .macros-see-all:hover {
    border-color: var(--accent);
    color: var(--accent);
  }
}

.macros-collapsible {
  margin-top: 28px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.macros-collapsible[hidden] { display: none; }

.macros-why {
  text-align: center;
  color: var(--text-muted);
  font-size: 13.5px;
  font-weight: 400;
  line-height: 1.7;
  margin-bottom: 24px;
  padding: 14px 20px;
  max-width: 540px;
  margin-left: auto;
  margin-right: auto;
  border-left: 3px solid rgba(26, 188, 156, 0.4);
  background: rgba(26, 188, 156, 0.04);
  border-radius: 0 10px 10px 0;
  text-align: left;
}

.macros-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
  text-align: left;
}

.macro-card {
  position: relative;
  background:
    linear-gradient(180deg, rgba(94, 234, 212, 0.025), transparent 35%),
    var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 26px 28px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  box-shadow: 0 18px 40px -28px rgba(0, 0, 0, 0.6);
}

.macro-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.macro-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 12px currentColor;
}

.macro-dot--protein {
  background: #1abc9c;
  color: rgba(26, 188, 156, 0.5);
}
.macro-dot--carbs {
  background: #5eead4;
  color: rgba(94, 234, 212, 0.5);
}
.macro-dot--fats {
  background: #3d7d75;
  color: rgba(61, 125, 117, 0.5);
}
.macro-dot--micro {
  background: #f59e0b;
  color: rgba(245, 158, 11, 0.5);
}

.macro-micro-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}


/* Detail panels */
.micro-details {
  overflow: hidden;
}

.micro-detail-panel {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.35s var(--ease-out), opacity 0.25s ease;
}

.micro-detail-panel.open {
  max-height: 700px;
  opacity: 1;
}

/* Nutrient table */
.micro-table-wrap {
  overflow-x: auto;
  margin-top: 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
}

.micro-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  line-height: 1.5;
  table-layout: fixed;
}

.micro-table th {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-faint);
  background: var(--card-bg-alt);
  padding: 8px 12px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.micro-table td {
  padding: 9px 12px;
  color: var(--text-muted);
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  vertical-align: top;
}

.micro-table tbody tr:last-child td {
  border-bottom: none;
}

.micro-table td:first-child {
  font-weight: 700;
  color: var(--text);
  width: 28%;
}

.micro-table td:nth-child(2) {
  width: 38%;
}

.micro-table td:nth-child(3) {
  width: 34%;
}

/* Water panel */
.micro-water {
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  text-align: center;
}

.micro-body-svg {
  height: 210px;
  width: auto;
  display: block;
}

.micro-water-pct-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  justify-content: center;
}

.micro-water-pct {
  font-size: 28px;
  font-weight: 800;
  color: #1abc9c;
  letter-spacing: -1px;
  line-height: 1;
}

.micro-water-pct-text {
  font-size: 13px;
  color: var(--text-muted);
}

.micro-water-intake {
  padding-top: 12px;
  border-top: 1px dashed var(--border);
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.micro-water-intake-num {
  font-size: 22px;
  font-weight: 800;
  color: #1abc9c;
  letter-spacing: -0.5px;
}

.micro-water-intake-text {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.6;
  margin: 0;
}

/* Wave animation */
@keyframes water-wave-anim {
  0%, 100% { transform: translateX(0); }
  50%       { transform: translateX(-180px); }
}

.water-wave {
  animation: water-wave-anim 4s ease-in-out infinite;
}

.macro-titles {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.macro-name {
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.3px;
  margin: 0;
}

.macro-tagline {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  color: var(--text-faint);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.macro-text {
  font-size: 14px;
  font-weight: 400;
  color: var(--text);
  line-height: 1.6;
  opacity: 0.88;
  margin: 0;
}

.macro-examples {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  padding-top: 6px;
}

.example {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: left;
  margin: 0;
  background: var(--card-bg);
  border-radius: 10px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.03);
}

.example-image {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 6px;
  overflow: hidden;
  background: var(--card-bg-alt);
}

.example-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.example figcaption {
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
  line-height: 1.25;
  padding: 0 1px 2px;
}

/* ============================================
   NEWSLETTER
   ============================================ */
.newsletter-card {
  text-align: center;
}

.newsletter-card .card-title {
  margin-bottom: 24px;
}

.newsletter-icon {
  display: block;
  width: 26px;
  height: 26px;
  margin: 0 auto 12px;
  color: var(--accent);
  filter: drop-shadow(0 0 8px rgba(26, 188, 156, 0.35));
  animation: nl-hover 3.5s ease-in-out infinite;
}

@keyframes nl-hover {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-3px);
  }
}

.newsletter-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 380px;
  margin: 0 auto;
}

.newsletter-contact {
  background: var(--input-bg);
  border: none;
  border-radius: 999px;
  outline: none;
  color: var(--text);
  font-family: inherit;
  font-size: 14px;
  font-weight: 400;
  padding: 13px 20px;
  transition: box-shadow 0.2s var(--ease-out);
}

.newsletter-contact::placeholder {
  color: var(--text-faint);
}

.newsletter-contact:focus {
  box-shadow: 0 0 0 2px rgba(26, 188, 156, 0.25);
}

.newsletter-row {
  display: flex;
  justify-content: center;
  align-items: center;
  background: var(--input-bg);
  border-radius: 999px;
  padding: 5px;
  transition: box-shadow 0.2s var(--ease-out);
}

.newsletter-row:focus-within {
  box-shadow: 0 0 0 2px rgba(26, 188, 156, 0.25);
}

.newsletter-row input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text);
  font-family: inherit;
  font-size: 14px;
  font-weight: 400;
  padding: 11px 20px;
}

.newsletter-row input::placeholder {
  color: var(--text-faint);
}

.newsletter-form button {
  background: var(--accent-dim);
  color: var(--text);
  border: none;
  padding: 11px 26px;
  border-radius: 999px;
  cursor: pointer;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  transition:
    background 0.3s var(--ease-out),
    transform 0.15s var(--ease-out);
}

@media (hover: hover) {
  .newsletter-form button:hover {
    background: var(--accent);
  }
}

.newsletter-form button:active {
  transform: scale(0.96);
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
  text-align: center;
  padding: 20px 0 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}

.disclaimer {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 8px 24px 8px 24px;
  margin: -20px 0 0 0;
  position: relative;
  z-index: 2;
}

.disclaimer-icon {
  flex-shrink: 0;
  width: 14px;
  height: 14px;
  margin-top: 2px;
  color: var(--text-muted);
  opacity: 0.6;
}

.disclaimer-body {
  display: flex;
  flex-direction: column;
  gap: 0;
  text-align: center;
}

/* ============================================
   DISCLAIMERS SECTION (Consolidated Bottom)
   ============================================ */
.disclaimers-section {
  padding: 32px 20px;
}

.disclaimers-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.disclaimers-container .disclaimer {
  margin: 0;
  padding: 12px 24px;
  max-width: 600px;
}

.disclaimers-container .disclaimer-body p {
  font-size: 13px;
  line-height: 1.4;
}

.disclaimer p,
.disclaimer-edu {
  font-size: var(--type-xs);
  font-weight: 500;
  line-height: 1.4;
  color: var(--text);
  opacity: 0.6;
  letter-spacing: 0.005em;
  margin: 0;
  white-space: nowrap;
}

.disclaimer-edu {
  opacity: 0.55;
  font-style: italic;
}

/* Inline variant — contextual disclaimers within sections */
.disclaimer--inline {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  justify-content: center;
  gap: 8px;
  max-width: 100%;
  margin: -20px 0 0 0;
  padding: 0 24px 0 24px;
  background: transparent;
  border: none;
  border-radius: 0;
  font-size: var(--type-xs);
  position: relative;
  z-index: 2;
}

.disclaimer--inline .disclaimer-icon {
  width: 14px;
  height: 14px;
  margin-top: 2px;
  color: var(--text-muted);
  opacity: 0.6;
}

.disclaimer--inline .disclaimer-body {
  gap: 0;
  text-align: center;
}

/* Questions disclaimer — inside wrapper, no negative margin needed */
#condQuestionsDisclaimer {
  margin: 0;
  padding: 12px 24px 0 24px;
}

/* Disclaimer link */
.disclaimer-link {
  background: none;
  border: none;
  color: var(--primary);
  font-size: inherit;
  font-weight: inherit;
  cursor: pointer;
  text-decoration: underline;
  padding: 0;
  margin: 0;
  opacity: 0.8;
  transition: opacity var(--transition-fast);
}

.disclaimer-link:hover {
  opacity: 1;
}

.disclaimer-link:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Disclaimer modal */
dialog#bmiDisclaimerModal,
dialog#nutritionDisclaimerModal,
dialog#questionsDisclaimerModal,
dialog#resultsDisclaimerModal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 90vw;
  max-width: 540px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--card-bg);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
  z-index: 200;
}

dialog#bmiDisclaimerModal::backdrop,
dialog#nutritionDisclaimerModal::backdrop,
dialog#questionsDisclaimerModal::backdrop,
dialog#resultsDisclaimerModal::backdrop {
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(2px);
}

.disclaimer-modal-box {
  position: relative;
  padding: 32px 28px;
}

.disclaimer-close-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  padding: 8px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  transition: background var(--transition-fast);
}

.disclaimer-close-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
}

.disclaimer-close-btn:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.disclaimer-modal-title {
  font-size: var(--type-md);
  font-weight: 700;
  color: var(--text);
  margin: 0 0 16px 0;
  padding-right: 32px;
}

.disclaimer-modal-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.disclaimer-modal-body p {
  font-size: var(--type-sm);
  font-weight: 500;
  line-height: 1.6;
  color: var(--text);
  margin: 0;
}

.disclaimer--inline p {
  font-size: var(--type-xs);
  font-weight: 500;
  line-height: 1.5;
  color: var(--text);
  opacity: 0.6;
  margin: 0;
}

.ig-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  padding: 8px 14px;
  border-radius: 999px;
  transition:
    color 0.3s var(--ease-out),
    background 0.3s var(--ease-out),
    transform 0.3s var(--ease-out);
}

.ig-icon {
  transition: transform 0.4s var(--ease-spring);
}

@media (hover: hover) {
  .ig-link:hover {
    color: var(--accent-soft);
    background: rgba(26, 188, 156, 0.08);
    transform: translateY(-1px);
  }

  .ig-link:hover .ig-icon {
    transform: rotate(-8deg) scale(1.1);
  }
}

/* ============================================
   SHARE PLAN SECTION
   ============================================ */
.plan-share {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px dashed var(--border);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.plan-share--cond {
  margin-top: 32px;
  padding-top: 28px;
}

.plan-share-headline {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.1px;
}

.plan-share-sub {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.55;
}

.plan-share-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  min-height: 44px;
  border-radius: 999px;
  border: 1.5px solid var(--accent);
  background: rgba(26, 188, 156, 0.08);
  color: var(--accent);
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  letter-spacing: 0.01em;
  transition: background 0.2s, border-color 0.2s, transform 0.15s var(--ease-out);
}

@media (hover: hover) {
  .plan-share-btn:not([disabled]):hover {
    background: rgba(26, 188, 156, 0.15);
    border-color: var(--accent-soft);
  }
}

.plan-share-btn:active {
  transform: scale(0.97);
}

.plan-share-btn[disabled] {
  opacity: 0.38;
  cursor: not-allowed;
  border-color: var(--border);
  background: transparent;
  color: var(--text-faint);
}

.plan-share-coming {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-dim);
  background: rgba(26, 188, 156, 0.07);
  border: 1px solid rgba(26, 188, 156, 0.18);
  border-radius: 20px;
  padding: 4px 12px;
}

/* ============================================
   SHARE MODAL (native <dialog>)
   ============================================ */
#shareNameModal {
  border: none;
  border-radius: 20px;
  padding: 0;
  background: var(--card-bg);
  color: var(--text);
  max-width: 380px;
  width: calc(100vw - 40px);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.7);
  outline: none;
  /* Explicit centering — native dialog auto-center is inconsistent */
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
}

#shareNameModal::backdrop {
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.share-modal-box {
  padding: 44px 28px 36px;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.share-modal-title {
  font-size: 22px;
  font-weight: 800;
  text-align: center;
  letter-spacing: -0.3px;
  margin-bottom: 8px;
  line-height: 1.3;
}

.share-modal-sub {
  font-size: 13.5px;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.6;
  margin-bottom: 24px;
}

/* Input row — clean field, no inline button */
.share-input-row {
  display: flex;
  align-items: center;
  background: var(--input-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 4px 16px;
  transition: border-color 0.2s, box-shadow 0.2s;
  margin-bottom: 14px;
}

.share-input-row:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(26, 188, 156, 0.15);
}

.share-name-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 16px;
  font-weight: 500;
  color: var(--text);
  padding: 13px 0;
  min-width: 0;
}

.share-name-input::placeholder {
  color: var(--text-faint);
  font-weight: 400;
}

/* Standalone Next CTA */
.share-next-btn {
  width: 100%;
  min-height: 50px;
  border-radius: 999px;
  border: none;
  background: var(--accent);
  color: #fff;
  font-family: inherit;
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.01em;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, opacity 0.2s, transform 0.15s var(--ease-out);
}

.share-next-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

@media (hover: hover) {
  .share-next-btn:not(:disabled):hover {
    background: var(--accent-soft, #1abc9c);
    transform: translateY(-1px);
  }
}

.share-close-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-faint);
  padding: 8px;
  min-height: 36px;
  min-width: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: color 0.15s, background 0.15s;
}

.share-close-btn:hover {
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.06);
}

#shareStateReady {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}

#shareStateReady[hidden] { display: none; }

#shareStateReady .share-modal-sub {
  margin-bottom: 28px;
}

#shareStateReady .plan-share-btn {
  width: 100%;
  justify-content: center;
  min-height: 50px;
  font-size: 15px;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 540px) {
  .container {
    padding: 100px 18px 28px;
    gap: 40px;
  }

  .brand-title {
    font-size: 34px;
  }

  .card {
    padding: 30px 22px;
    border-radius: 18px;
  }

  .card-title {
    font-size: 21px;
  }

  .macros-grid {
    gap: 16px;
  }
  .macro-card {
    padding: 22px 20px;
    gap: 14px;
  }
  .macro-name {
    font-size: 18px;
  }
  .macro-text {
    font-size: 13px;
  }
  .macro-examples {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .rec-card {
    padding: 22px 20px;
  }
  .rec-card .stat-value {
    font-size: 26px;
  }
  .rec-stat-col {
    padding: 12px 4px;
  }
  .rec-combined-stats {
    gap: 2px;
  }

  .sparkle {
    width: 14px;
    height: 14px;
  }
  .section-title--shine {
    gap: 10px;
  }

  .lang-dropdown {
    min-width: 160px;
  }

  .macros-chart {
    width: 160px;
    height: 160px;
  }

  .sources-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
  .source-amount {
    font-size: 13px;
  }
  .source-name {
    font-size: 12px;
  }

  .goal-row {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  .goal-prompt {
    text-align: center;
  }
  .goal-slider {
    max-width: none;
  }

  .scale-label {
    font-size: 11px;
  }
  .scale-range {
    font-size: 10px;
  }

  .bmi-result-value {
    font-size: 54px;
  }
  .section-title.big {
    font-size: 28px;
  }
  .stat-value {
    font-size: 32px;
  }

  /* Prevent iOS Safari from zooming on input focus */
  .input-pill input,
  .newsletter-row input,
  .newsletter-contact {
    font-size: 16px;
  }

  /* Slightly larger tap targets */
  .toggle-btn {
    padding: 11px 32px;
  }
  .newsletter-form button {
    padding: 12px 26px;
  }
}

/* =========================================================
   CONDITIONS SECTION
   ========================================================= */

.cond-section-title {
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
  text-align: center;
  margin-top: 64px;
  margin-bottom: 6px;
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.cond-section-icon {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
  color: var(--accent-soft);
  opacity: 0.7;
}

/* Subtle tint + border to differentiate from the generic rec-card above */
.rec-card--cond {
  border-color: rgba(26, 188, 156, 0.2);
  background:
    linear-gradient(180deg, rgba(26, 188, 156, 0.04) 0%, transparent 30%),
    var(--card-bg);
  position: relative;
  overflow: visible;
}


/* .cond-edu-note removed — now rendered as .disclaimer-edu inside the disclaimer footer */

.rec-meta-context {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 12px;
  letter-spacing: 0.01em;
}

.conditions-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
  justify-content: center;
}

.meta-chip {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  background: var(--card-bg-alt);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 6px 14px;
  color: var(--text-muted);
  cursor: default;
  user-select: none;
}

.meta-chip--empty {
  color: var(--text-faint);
  opacity: 0.5;
}

/* Answer pills accumulate here as user answers each question */
.cond-answer-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  align-items: center;
  min-height: 36px;
  margin-bottom: 12px;
}

/* Interactive answer pill — tap to go back and change */
.cond-answer-pill {
  cursor: pointer;
  border-color: rgba(26, 188, 156, 0.3);
  color: var(--accent-soft);
  transition: border-color 0.2s, background 0.2s, transform 0.15s;
  position: relative;
}


@media (hover: hover) {
  .cond-answer-pill:hover {
    border-color: var(--accent);
    background: rgba(26, 188, 156, 0.08);
    transform: translateY(-1px);
  }
}

.cond-answer-pill:active {
  transform: scale(0.96);
}

/* Fixed-height area — one question shown at a time, no layout jump */
/* Disabled state callout — centre-aligned, flat (no nested card styling) */
.cond-disabled-callout {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 12px;
  padding: var(--space-5) var(--space-4);
  margin-bottom: var(--space-4);
  border-bottom: 1px solid var(--border);
  background: none;
  border-radius: 0;
  animation: cond-fade-up 0.35s var(--ease-out) both;
  opacity: 1;
}

.empty-icon {
  width: 20px;
  height: 20px;
  color: var(--primary);
  flex-shrink: 0;
}

.empty-title {
  font-size: var(--type-md);
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
  margin: 0;
}

.empty-text {
  font-size: var(--type-sm);
  font-weight: 400;
  color: var(--text-muted);
  line-height: 1.4;
  margin: 0;
}

.cond-question-wrapper {
  min-height: 160px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: min-height 0.3s ease, opacity 0.3s ease;
}

/* Disabled state: visual feedback without removing from tab order */
.cond-question-wrapper--disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.cond-question-wrapper--disabled .toggle-btn {
  cursor: not-allowed;
  opacity: 0.65;
  pointer-events: none;
}

.cond-question-wrapper--done {
  min-height: 0;
}

.cond-question {
  width: 100%;
  text-align: center;
  transition: opacity 0.28s ease, transform 0.28s ease;
}

.cond-question--fading {
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
}

.cond-q-text {
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 20px;
  line-height: 1.35;
  letter-spacing: -0.2px;
}

.cond-btns {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: center;
}

/* Condition buttons use .toggle-btn with .selected alias for active state */
.cond-btns .toggle-btn.selected {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(26, 188, 156, 0.08);
}

/* cond-answers tombstone removed — answers now surface as live pills in .cond-answer-cloud */

/* Loading state */
.cond-loader {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 28px 0 20px;
}

.cond-loader[hidden] { display: none; }

.cond-loader-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  animation: cond-fade-up 0.35s var(--ease-out) both;
}

@keyframes cond-fade-up {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.cond-loader-dots {
  display: flex;
  gap: 7px;
  align-items: center;
}

.cond-loader-dots span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  animation: cond-dot-bounce 1.1s ease-in-out infinite;
  opacity: 0.5;
}

.cond-loader-dots span:nth-child(2) { animation-delay: 0.18s; }
.cond-loader-dots span:nth-child(3) { animation-delay: 0.36s; }

@keyframes cond-dot-bounce {
  0%, 80%, 100% { transform: translateY(0);    opacity: 0.4; }
  40%           { transform: translateY(-9px); opacity: 1;   }
}

/* Horizontal matrix */
.cond-matrix {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
}

.cond-matrix[hidden] { display: none; }

/* ============================================
   TIMELINE — daily / weekly / monthly / periodic
   ============================================ */

/* Frequency badge pill */
.tl-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  flex-shrink: 0;
}
.tl-badge svg { width: 12px; height: 12px; }
.tl-badge--daily    { background: rgba(26,188,156,0.12);  color: var(--accent);       border: 1px solid rgba(26,188,156,0.25); }
.tl-badge--weekly   { background: rgba(100,180,255,0.1);  color: #64b4ff;             border: 1px solid rgba(100,180,255,0.2); }
.tl-badge--monthly  { background: rgba(255,180,60,0.1);   color: #e6a535;             border: 1px solid rgba(255,180,60,0.2);  }
.tl-badge--periodic { background: rgba(180,140,255,0.1);  color: #b48cff;             border: 1px solid rgba(180,140,255,0.2); }

/* Hero daily card */
.cond-filter-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 20px 0 24px;
  opacity: 0.6;
}
.cond-filter-divider[hidden] { display: none; }

.tl-hero {
  padding: 4px 0 0;
  margin-bottom: 0;
}

.tl-hero-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  margin-bottom: 16px;
  text-align: center;
}

.tl-hero-title,
.tl-card-title {
  font-size: 22px;
  font-weight: 800;
  color: var(--text);
  margin: 0;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.tl-hero-sub, .tl-card-sub {
  font-size: 11.5px;
  color: var(--text-faint);
  margin: 0;
}

.tl-item-examples,
.cond-item-examples {
  display: block;
  font-size: 11px;
  font-style: italic;
  color: var(--accent);
  margin-top: 3px;
  line-height: 1.4;
  opacity: 0.85;
}

/* Visual stats row (protein / steps / water) */
.tl-stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px dashed var(--border);
}

.tl-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-align: center;
}

.tl-stat-icon {
  width: 20px;
  height: 20px;
  opacity: 0.75;
}
.tl-stat-icon--protein { color: #4ecdc4; }
.tl-stat-icon--steps   { color: #4ecdc4; }
.tl-stat-icon--water   { color: #4ecdc4; }

.tl-stat-value {
  font-size: 17px;
  font-weight: 800;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.tl-stat-label {
  font-size: 9.5px;
  color: var(--text-faint);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  font-weight: 700;
}

/* Habit list shared by hero and freq cards */
.tl-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.tl-item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 0 7px 12px;
  border-left: 2px solid var(--border);
  background: none;
  border-radius: 0;
}

.tl-item--hidden { display: none; }

.tl-item-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
  flex: 1;
  min-width: 0;
}

.tl-item-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.35;
}

.tl-item-detail {
  font-size: 11.5px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Source condition tag */
.tl-src-tag {
  flex-shrink: 0;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  padding: 3px 7px;
  border-radius: 20px;
  background: rgba(26,188,156,0.07);
  color: var(--accent-soft);
  border: 1px solid rgba(26,188,156,0.16);
  align-self: flex-start;
  margin-top: 2px;
  white-space: nowrap;
}

/* See more button */
.tl-see-more {
  display: block;
  width: 100%;
  margin-top: 10px;
  padding: 8px 0;
  text-align: center;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--accent);
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
}

/* Frequency sections — plain divider style, no card nesting */
.tl-card {
  background: none;
  border: none;
  border-radius: 0;
  border-top: 1px solid var(--border);
  margin-bottom: 0;
  overflow: visible;
}

.tl-card-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  text-align: left;
  min-height: 44px;
}

.tl-card-toggle-left {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  text-align: center;
}

.tl-card-count {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-faint);
  white-space: nowrap;
  flex-shrink: 0;
}

.tl-card-chevron {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  color: var(--text-faint);
  transition: transform 0.2s ease;
}

.tl-list--inner {
  padding: 0 12px 12px;
  gap: 7px;
}

.tl-list--inner[hidden] { display: none; }

/* Special concerns collapsible section */
.tl-concerns {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px dashed var(--border);
}

.tl-concerns-toggle {
  width: 100%;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  text-align: left;
  padding: 0;
  min-height: 44px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.tl-concerns-toggle-inner {
  display: flex;
  align-items: center;
  gap: 8px;
}

.tl-concerns-icon {
  width: 20px;
  height: 20px;
  color: var(--accent-soft);
  flex-shrink: 0;
}

.tl-concerns-toggle-inner > span {
  flex: 1;
  font-size: 14px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.1px;
}

.tl-concerns-chevron {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  color: var(--text-faint);
  transition: transform 0.2s ease;
}

.tl-concerns-sub {
  font-size: 11.5px;
  color: var(--text-faint);
  margin: 2px 0 0;
  line-height: 1.5;
  padding-left: 28px;
}

.tl-concerns-deep {
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.tl-concerns-deep[hidden] { display: none; }

/* ── Condition Tabs ───────────────────────────────────────────────────────── */

.cond-tabs { margin-top: 10px; }

.cond-tabs-bar {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding-bottom: 10px;
}
.cond-tabs-bar::-webkit-scrollbar { display: none; }

.cond-tab-btn {
  flex-shrink: 0;
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  min-height: 32px;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.cond-tab-btn--active {
  background: var(--accent-dim);
  color: var(--accent);
  border-color: rgba(26,188,156,0.35);
}

.cond-tab-panel[hidden] { display: none; }

/* Pillar section (Nutrition / Movement / Rest) */
.cond-pillar-section { margin-bottom: 4px; }

.cond-pillar-section-label {
  font-size: 9.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--text-faint);
  margin: 14px 0 7px;
}
.cond-pillar-section:first-child .cond-pillar-section-label { margin-top: 6px; }

.cond-pillar-section-items {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

/* Flat recommendation row — left border accent, no card background */
.cond-tab-item {
  padding: 6px 0 6px 12px;
  border-left: 2px solid rgba(26,188,156,0.35);
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.cond-tab-item-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
}

.cond-tab-item-detail {
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Subtle condition source label — e.g. "PCOS" or "Preconception" */
.cond-item-source {
  font-size: 9.5px;
  color: var(--text-faint);
  font-style: italic;
  margin-top: 2px;
  opacity: 0.8;
}

/* "What not to do" section */
.cond-avoid-section {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px dashed rgba(214,86,86,0.25);
}

.cond-avoid-label {
  font-size: 9.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: rgba(214,86,86,0.65);
  margin-bottom: 8px;
}

.cond-tab-item--avoid {
  border-left-color: rgba(214,86,86,0.45);
}

/* "See full plan" — subtle right-aligned text link */
.cond-tabs-see-more {
  display: block;
  margin-top: 12px;
  margin-left: auto;
  padding: 0;
  background: none;
  border: none;
  color: var(--accent);
  font-size: 11px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  text-align: right;
  transition: opacity 0.15s;
}
.cond-tabs-see-more:hover,
.cond-tabs-see-more:active { opacity: 0.75; }

/* Weekly/monthly/periodic freq items — same flat style as daily */
.tl-freq-items {
  display: flex;
  flex-direction: column;
  gap: 9px;
  padding: 12px 0 8px;
}

/* ── Condition Popup (bottom-sheet) ──────────────────────────────────────── */

.cond-popup-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0);
  z-index: 200;
  display: flex;
  align-items: flex-end;
  transition: background 0.25s ease;
  pointer-events: none;
}
.cond-popup-overlay--open {
  background: rgba(0,0,0,0.65);
  pointer-events: all;
}

.cond-popup-panel {
  width: 100%;
  max-height: 82vh;
  background: var(--card-bg-alt);
  border-radius: 22px 22px 0 0;
  border-top: 1px solid rgba(26,188,156,0.18);
  display: flex;
  flex-direction: column;
  transform: translateY(100%);
  transition: transform 0.32s cubic-bezier(0.32, 0.72, 0, 1);
  overflow: hidden;
}
.cond-popup-overlay--open .cond-popup-panel { transform: translateY(0); }

.cond-popup-drag {
  width: 36px;
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  margin: 10px auto 0;
  flex-shrink: 0;
}

.cond-popup-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px 13px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.cond-popup-header-left { display: flex; flex-direction: column; gap: 2px; }

.cond-popup-headline {
  font-size: 16px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: -0.02em;
}

.cond-popup-sub {
  font-size: 11px;
  color: var(--text-faint);
}

.cond-popup-close {
  width: 32px;
  height: 32px;
  min-width: 32px;
  border-radius: 50%;
  background: var(--input-bg);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.cond-popup-close svg { width: 14px; height: 14px; color: var(--text-muted); }

.cond-popup-list {
  list-style: none;
  padding: 14px 18px 32px;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.cond-popup-item {
  padding: 8px 0 8px 12px;
  border-left: 2px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 3px;
  background: none;
  border-radius: 0;
}

.cond-popup-item-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 2px;
}

.cond-popup-item-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.3;
  flex: 1;
}

.cond-popup-item-detail {
  font-size: 11.5px;
  color: var(--text-muted);
  line-height: 1.45;
}

.cond-popup-item .tl-item-examples {
  font-size: 10.5px;
  margin-top: 2px;
}

/* Bigger icons inside the special concern pillar cards */
.tl-concerns-deep .cond-pillar-icon {
  width: 28px;
  height: 28px;
}

.cond-pillar {
  background: var(--card-bg-alt);
  border-radius: 10px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  border: 1px solid rgba(255, 255, 255, 0.03);
}

.cond-pillar-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--accent);
  padding-bottom: 11px;
  border-bottom: 1px solid var(--border);
}

.cond-pillar-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  stroke: var(--accent);
}

/* Micro-animations per pillar icon type */
.cond-pillar-icon--nutrition {
  animation: icon-bounce 2.8s ease-in-out infinite;
}
.cond-pillar-icon--movement {
  animation: icon-step 2.2s ease-in-out infinite;
}
.cond-pillar-icon--rest {
  animation: icon-sway 4s ease-in-out infinite;
}
.cond-pillar-icon--monitor {
  animation: icon-beat 1.9s ease-in-out infinite;
}

@keyframes icon-bounce {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  35%       { transform: translateY(-3px) rotate(-5deg); }
  65%       { transform: translateY(-2px) rotate(3deg); }
}
@keyframes icon-step {
  0%, 100% { transform: translateX(0) rotate(0deg); }
  30%      { transform: translateX(2px) rotate(6deg); }
  60%      { transform: translateX(-2px) rotate(-6deg); }
}
@keyframes icon-sway {
  0%, 100% { transform: rotate(0deg) scale(1); }
  50%      { transform: rotate(-15deg) scale(1.06); }
}
@keyframes icon-beat {
  0%, 100% { transform: scaleX(1); opacity: 0.9; }
  30%      { transform: scaleX(1.1); opacity: 1; }
  50%      { transform: scaleX(0.95); opacity: 0.8; }
  70%      { transform: scaleX(1.06); opacity: 1; }
}

.cond-pillar-items {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.cond-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cond-item-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.35;
}

.cond-item-detail {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.55;
}

@media (max-width: 520px) {
  .cond-pillar-items {
    grid-template-columns: 1fr;
  }
}

/* Age-based recommendation section (TTC / perimenopause / post-menopause) */
.cond-age-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 10px;
}

.cond-age-section[hidden] { display: none; }

.cond-age-heading {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-faint);
  text-align: center;
  padding-top: 14px;
  padding-bottom: 2px;
  border-top: 1px dashed var(--border);
  margin-top: 4px;
}

/* "Add more" chip button — sits with the filter pills above questions */
.cond-add-more {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.03em;
  background: transparent;
  border: 1px dashed var(--border-strong);
  border-radius: 20px;
  padding: 10px 14px;
  min-height: 36px;
  display: flex;
  align-items: center;
  width: fit-content;
  margin: 0 auto;
  color: var(--accent);
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s, border-color 0.2s;
}

@media (hover: hover) {
  .cond-add-more:hover {
    background: rgba(26, 188, 156, 0.08);
    border-color: var(--accent);
  }
}

.cond-add-more[hidden] { display: none; }

/* Extra conditions form */
.cond-extras-form {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px dashed var(--border);
  margin-bottom: 8px;
}

.cond-extras-form[hidden] { display: none; }

.cond-extras-form-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 14px;
}

.cond-extras-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 18px;
}

.cond-extra-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  background: var(--card-bg-alt);
  border-radius: 10px;
  border: 1px solid var(--border);
  gap: 12px;
}

.cond-extra-row-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
  flex: 1;
}

.cond-extra-row-btns {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.cond-extra-row-btn {
  padding: 10px 16px;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  border: 1.5px solid var(--border-strong);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.cond-extra-row-btn.selected {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(26, 188, 156, 0.08);
}

.cond-extras-submit {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  padding: 13px 28px;
  min-height: 44px;
  border-radius: 999px;
  border: 1.5px solid var(--border-strong);
  background: transparent;
  color: var(--accent);
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
  font-family: inherit;
  letter-spacing: 0.02em;
  transition: background 0.2s, border-color 0.2s;
}

@media (hover: hover) {
  .cond-extras-submit:hover {
    background: rgba(26, 188, 156, 0.08);
    border-color: var(--accent);
  }
}

/* Extra recommendations section */
.cond-extras-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
}

.cond-extras-section[hidden] { display: none; }

.cond-extra-card {
  background: var(--card-bg-alt);
  border-radius: 10px;
  padding: 14px 16px;
  border: 1px solid rgba(255, 255, 255, 0.03);
}

.cond-extra-card-header {
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--accent-soft);
  padding-bottom: 10px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.cond-extra-items {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

@media (max-width: 400px) {
  .cond-extra-items { grid-template-columns: 1fr; }
}

/* ========================================================= */

@media (max-width: 360px) {
  .scale-label {
    font-size: 10px;
  }
  .scale-range {
    display: none;
  }
}
