:root {
  color-scheme: light;
  --bg: #f7fafc;
  --bg-blue: #eef7ff;
  --surface: #ffffff;
  --surface-soft: #f3f8ff;
  --text: #172033;
  --heading: #102653;
  --muted: #5b667a;
  --border: #d9e2ec;
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --accent: #14b8a6;
  --healthy: #22c55e;
  --underweight: #3b82f6;
  --overweight: #f59e0b;
  --obesity: #f97316;
  --danger: #ef4444;
  /* Darkened text-only variants: the plain category colors above stay bright
     for decorative use (gauge fill) but fail 3:1 against a white surface when
     used as text, so result text uses these instead. */
  --healthy-text: #15803d;
  --underweight-text: var(--underweight);
  --overweight-text: #b45309;
  --obesity-text: #c2410c;
  --shadow: 0 18px 42px rgba(16, 38, 83, 0.08);
  --shadow-soft: 0 12px 28px rgba(16, 38, 83, 0.06);
  --radius: 8px;
  --max-width: 1160px;
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0d1b2f;
  --bg-blue: #10243c;
  --surface: #14243a;
  --surface-soft: #18304e;
  --text: #e8eef7;
  --heading: #f5f9ff;
  --muted: #b8c4d6;
  --border: #29415f;
  --shadow: 0 16px 36px rgba(0, 0, 0, 0.2);
  --shadow-soft: 0 10px 24px rgba(0, 0, 0, 0.16);
  /* Bright category colors already meet 3:1 against the dark surface, so
     dark theme uses them directly instead of the light-theme darkened text variants. */
  --healthy-text: var(--healthy);
  --underweight-text: var(--underweight);
  --overweight-text: var(--overweight);
  --obesity-text: var(--obesity);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.5;
  /* Safety net: nothing on the page should legitimately be wider than the
     viewport. This clips any future stray/decorative element without
     hiding real content, instead of letting it create a horizontal scrollbar. */
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 10;
  background: var(--primary);
  color: #ffffff;
  padding: 10px 14px;
  border-radius: var(--radius);
}

.skip-link:focus {
  top: 12px;
}

.container {
  width: min(100% - 32px, var(--max-width));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(14px);
}

[data-theme="dark"] .site-header {
  background: rgba(13, 27, 47, 0.9);
}

.header-inner {
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--heading);
  font-size: 1.28rem;
  font-weight: 800;
  white-space: nowrap;
}

.brand-icon {
  width: 52px;
  height: 52px;
  flex: 0 0 52px;
  display: block;
  object-fit: contain;
}

.mobile-nav-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--heading);
  font-size: 0.9rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(16, 38, 83, 0.06);
}

.mobile-nav-toggle-lines,
.mobile-nav-toggle-lines::before,
.mobile-nav-toggle-lines::after {
  width: 16px;
  height: 2px;
  display: block;
  border-radius: 999px;
  background: currentColor;
}

.mobile-nav-toggle-lines {
  position: relative;
}

.mobile-nav-toggle-lines::before,
.mobile-nav-toggle-lines::after {
  content: "";
  position: absolute;
  left: 0;
}

.mobile-nav-toggle-lines::before {
  top: -5px;
}

.mobile-nav-toggle-lines::after {
  top: 5px;
}

.mobile-nav-toggle:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.main-nav,
.header-actions,
.language-switcher,
.footer-inner nav {
  display: flex;
  align-items: center;
}

.main-nav {
  gap: 32px;
  color: var(--heading);
  font-size: 0.95rem;
}

.main-nav a {
  padding: 25px 0 21px;
  border-bottom: 2px solid transparent;
}

.main-nav a.active,
.main-nav a:hover,
.main-nav a:focus-visible {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.header-actions {
  gap: 10px;
}

.theme-toggle {
  width: 46px;
  min-width: 46px;
  height: 40px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--heading);
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(16, 38, 83, 0.06);
}

.theme-toggle svg {
  display: block;
}

/* Light mode shows the moon (switch to dark); dark mode shows the sun. */
.theme-toggle .theme-icon-sun {
  display: none;
}

[data-theme="dark"] .theme-toggle .theme-icon-moon {
  display: none;
}

[data-theme="dark"] .theme-toggle .theme-icon-sun {
  display: block;
}

.language-switcher:hover {
  border-color: #bfd3ea;
  box-shadow: 0 4px 14px rgba(16, 38, 83, 0.07);
}

.theme-toggle:hover svg {
  color: var(--primary);
}

.theme-toggle:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.language-switcher {
  gap: 8px;
  min-height: 36px;
  padding: 0 13px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
  white-space: nowrap;
}

.language-switcher .active {
  color: var(--primary);
}

.language-switcher a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  min-height: 24px;
  padding: 4px;
  margin: -4px;
  border-radius: 999px;
}

.lang-icon {
  position: relative;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  border: 2px solid var(--heading);
  border-radius: 50%;
}

.lang-icon::before,
.lang-icon::after {
  content: "";
  position: absolute;
  inset: 2px;
  border-left: 1px solid var(--heading);
  border-right: 1px solid var(--heading);
  border-radius: 50%;
}

.lang-icon::after {
  inset: 6px -3px;
  border: 0;
  border-top: 1px solid var(--heading);
}

.hero-section {
  position: relative;
  overflow: hidden;
  padding: 34px 0 18px;
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-blue) 100%);
}

.hero-bg {
  position: absolute;
  pointer-events: none;
  opacity: 0.75;
}

.hero-bg-left {
  left: -70px;
  bottom: -120px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: #dff1ff;
}

.hero-bg-right {
  right: -70px;
  bottom: -80px;
  width: 240px;
  height: 320px;
  border-radius: 120px 120px 0 0;
  background: #dcefff;
}

.hero-bg-right::before,
.hero-bg-right::after {
  content: "";
  position: absolute;
  width: 70px;
  height: 18px;
  border-radius: 999px 0 999px 0;
  background: rgba(20, 184, 166, 0.32);
  transform-origin: left center;
}

.hero-bg-right::before {
  left: 92px;
  top: 128px;
  transform: rotate(58deg);
}

.hero-bg-right::after {
  left: 132px;
  top: 168px;
  transform: rotate(-62deg);
}

.hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(640px, 1.48fr);
  grid-template-areas: "copy calc" "badges calc";
  align-items: center;
  gap: 46px;
}

.hero-grid .hero-copy {
  grid-area: copy;
}

.hero-grid .calculator-shell {
  grid-area: calc;
}

.hero-grid .trust-badges {
  grid-area: badges;
}

.hero-copy h1 {
  max-width: 520px;
  margin: 0 0 16px;
  color: var(--heading);
  font-size: clamp(2.8rem, 5.8vw, 4.65rem);
  line-height: 0.98;
  letter-spacing: 0;
}

.hero-copy > p {
  max-width: 470px;
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.trust-badges {
  margin-top: 38px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  max-width: 440px;
}

.trust-badge {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.35;
}

.trust-badge strong {
  color: var(--heading);
  font-size: 0.98rem;
}

.badge-icon {
  width: 46px;
  height: 46px;
  display: block;
  object-fit: contain;
}

.calculator-shell {
  display: grid;
  grid-template-columns: 0.88fr 1.02fr;
  background: var(--surface);
  border: 1px solid #cfddeb;
  border-radius: 16px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.calculator-banner {
  grid-column: 1 / -1;
  padding: 18px 28px;
  background: linear-gradient(135deg, #2f73f6, var(--primary-dark));
  color: #ffffff;
  text-align: center;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0;
}

.calculator-card,
.result-card {
  padding: 24px 30px 28px;
}

.calculator-card {
  border-right: 1px solid var(--border);
}

.calculator-card h2,
.result-card h2,
.healthy-range-card h2,
.ideal-weight-card h2,
.important-section h2,
.info-card h2,
.section-block h2,
.limitation-strip h2 {
  margin: 0;
  color: var(--heading);
  line-height: 1.2;
}

.calculator-card h2,
.result-card h2 {
  font-size: 1.05rem;
}

.unit-selector {
  display: inline-grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  margin: 16px 0 2px;
  padding: 4px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-soft);
}

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

.unit-selector label {
  display: block;
  margin: 0;
  cursor: pointer;
}

.unit-selector input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.unit-selector span {
  min-width: 92px;
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 800;
}

.unit-selector input:checked + span {
  background: #ffffff;
  color: var(--primary);
  box-shadow: 0 5px 14px rgba(16, 38, 83, 0.12);
}

.unit-selector input:focus-visible + span {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.field-group {
  margin-top: 14px;
}

label {
  display: block;
  margin-bottom: 7px;
  color: var(--heading);
  font-weight: 700;
}

.input-with-unit {
  display: flex;
  min-height: 50px;
  border: 1px solid #cdd8e5;
  border-radius: var(--radius);
  background: var(--surface);
  overflow: hidden;
}

.input-with-unit:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

.input-with-unit input {
  width: 100%;
  min-width: 0;
  border: 0;
  background: transparent;
  color: var(--text);
  padding: 0 16px;
  outline: 0;
}

.input-with-unit span {
  min-width: 68px;
  display: grid;
  place-items: center;
  border-left: 1px solid var(--border);
  color: var(--heading);
  font-weight: 700;
}

.imperial-height-inputs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.field-help,
.field-error,
.privacy-note {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 0.84rem;
}

.field-error {
  min-height: 1.1em;
  color: #b45309;
  font-weight: 700;
}

.primary-button {
  width: 100%;
  min-height: 50px;
  margin-top: 10px;
  border: 0;
  border-radius: var(--radius);
  background: linear-gradient(180deg, #2f73f6, var(--primary));
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 10px 18px rgba(37, 99, 235, 0.24);
}

.primary-button:hover,
.primary-button:focus-visible {
  background: var(--primary-dark);
}

.privacy-note {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 18px;
}

.privacy-icon {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  margin-top: 1px;
  color: var(--primary);
}

.result-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.example-pill,
.reset-button {
  padding: 5px 12px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #e3f1ff;
  color: var(--primary);
  font-size: 0.82rem;
  font-weight: 800;
}

.reset-button {
  cursor: pointer;
}

.reset-button:hover,
.reset-button:focus-visible {
  border-color: var(--primary);
  background: #dbeafe;
}

.reset-button:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.result-kicker {
  margin: 24px 0 0;
  text-align: center;
  color: var(--heading);
  font-weight: 700;
}

.bmi-number {
  margin: 4px 0 0;
  color: var(--healthy-text);
  text-align: center;
  font-size: clamp(4rem, 7vw, 5.8rem);
  line-height: 1;
  font-weight: 800;
}

.category-label {
  margin: 4px 0;
  text-align: center;
  color: var(--healthy-text);
  font-size: 1.48rem;
  font-weight: 800;
}

.category-label.underweight,
.bmi-number.underweight {
  color: var(--underweight-text);
}

.category-label.overweight,
.bmi-number.overweight {
  color: var(--overweight-text);
}

.category-label.obesity,
.bmi-number.obesity {
  color: var(--obesity-text);
}

.category-label.neutral,
.bmi-number.neutral {
  color: var(--muted);
}

.result-copy {
  max-width: 390px;
  margin: 0 auto;
  color: var(--muted);
  text-align: center;
}

.scale-wrap {
  position: relative;
  margin-top: 52px;
}

.bmi-scale {
  height: 13px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--underweight) 0 20%, #2bb6d9 27%, var(--accent) 36%, var(--healthy) 54%, #a3d644 66%, #facc15 76%, var(--overweight) 85%, var(--danger) 100%);
}

.scale-indicator {
  position: absolute;
  top: -17px;
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-top: 12px solid var(--heading);
  transform: translateX(-50%);
}

.scale-numbers,
.scale-labels {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 0.82rem;
}

.scale-numbers {
  margin-top: 18px;
  color: var(--heading);
  font-weight: 700;
}

.scale-numbers span {
  position: relative;
  min-width: 28px;
  text-align: center;
}

.scale-numbers span::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -15px;
  width: 2px;
  height: 10px;
  border-radius: 999px;
  background: #aeb8c7;
  transform: translateX(-50%);
}

.scale-labels {
  margin-top: 4px;
}

.result-dashboard {
  position: relative;
  z-index: 1;
  margin-top: 32px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
  gap: 20px;
}

.healthy-range-card,
.ideal-weight-card,
.important-section {
  background: var(--surface);
  border: 1px solid #d5e1ed;
  border-radius: 14px;
  box-shadow: var(--shadow-soft);
}

.healthy-range-card {
  display: grid;
  align-content: start;
  gap: 14px;
  padding: 22px;
}

.healthy-range-card p,
.ideal-weight-card p {
  margin: 6px 0 0;
  color: var(--muted);
}

.dashboard-card-heading,
.important-note {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: start;
}

.dashboard-icon,
.target-icon,
.guidance-icon {
  width: 52px;
  height: 52px;
  flex: 0 0 52px;
  border-radius: 12px;
}

.dashboard-icon {
  display: grid;
  place-items: center;
}

.dashboard-icon svg {
  width: 30px;
  height: 30px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.range-icon {
  border-radius: 12px;
  background: #dcfce7;
  color: #16a34a;
}

.reference-icon {
  background: #e3f1ff;
  color: var(--primary);
}

.target-icon {
  background-color: #dcfce7;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2316a34a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='2.5' y='8' width='19' height='8.5' rx='2.2'/%3E%3Cpath d='M6.4 8v3.4'/%3E%3Cpath d='M10.1 8v4.8'/%3E%3Cpath d='M13.9 8v3.4'/%3E%3Cpath d='M17.6 8v4.8'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 30px 30px;
}

.guidance-icon {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background-color: #e3f1ff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath stroke='%232563eb' d='M8.3 4.6H7a2 2 0 0 0-2 2V19a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V6.6a2 2 0 0 0-2-2h-1.3'/%3E%3Crect stroke='%2314b8a6' x='8.6' y='2.5' width='6.8' height='3.8' rx='1.2'/%3E%3Cpath stroke='%232563eb' d='M9 11.5h6'/%3E%3Cpath stroke='%232563eb' d='M9 15.5h4'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 30px 30px;
}

.range-result,
.guidance-result {
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface-soft);
}

.range-result strong,
.guidance-result strong {
  display: block;
  font-size: clamp(1.55rem, 3vw, 2rem);
  line-height: 1.2;
}

.range-result strong {
  color: #16a34a;
}

.range-result span {
  color: var(--muted);
}

.ideal-weight-card {
  display: grid;
  align-content: start;
  gap: 14px;
  padding: 22px;
}

.guidance-result strong {
  color: var(--primary);
}

.guidance-result span {
  display: block;
  margin-top: 6px;
  color: var(--heading);
  font-weight: 700;
}

.guidance-note {
  padding-left: 14px;
  border-left: 3px solid #bfdbfe;
  font-size: 0.92rem;
}

.range-support {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 700;
}

.range-support span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.range-support span::before {
  content: "";
  width: 8px;
  height: 8px;
  flex: 0 0 8px;
  border-radius: 50%;
  background: #16a34a;
}

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

.important-section {
  margin-top: 26px;
  padding: 24px;
}

.important-section > div:first-child p {
  margin: 8px 0 0;
  color: var(--muted);
}

.important-notes {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.important-note {
  padding: 16px 18px;
  border: 1px solid rgba(248, 113, 113, 0.35);
  border-left: 4px solid rgba(239, 68, 68, 0.65);
  border-radius: 12px;
  background:
    linear-gradient(135deg, rgba(254, 242, 242, 0.96), rgba(255, 247, 247, 0.98), rgba(255, 241, 242, 0.92));
  color: var(--text);
  box-shadow: 0 10px 24px rgba(127, 29, 29, 0.06);
}

.important-note.adult-note {
  border-color: rgba(251, 113, 133, 0.38);
  border-left-color: rgba(225, 29, 72, 0.62);
  background:
    linear-gradient(135deg, rgba(255, 241, 242, 0.96), rgba(255, 247, 247, 0.98), rgba(255, 228, 230, 0.82));
  color: var(--heading);
}

.important-note span {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #fee2e2;
  color: #b91c1c;
  font-weight: 800;
}

.important-note.adult-note span {
  background: #ffe4e6;
  color: #be123c;
}

.important-note p {
  margin: 0;
}

.info-card,
.limitation-strip {
  margin-top: 26px;
  background: var(--surface);
  border: 1px solid #d5e1ed;
  border-radius: 12px;
  box-shadow: var(--shadow-soft);
}

.limitation-strip {
  border-color: rgba(248, 113, 113, 0.45);
  border-left: 4px solid rgba(239, 68, 68, 0.55);
  box-shadow: var(--shadow-soft);
}

.what-is-bmi {
  display: grid;
  grid-template-columns: 0.68fr 1fr;
  align-items: center;
  gap: 44px;
  padding: 32px 44px;
}

.what-is-bmi p {
  margin: 12px 0 0;
  color: var(--text);
}

.illustration-card {
  border-radius: 18px;
  overflow: hidden;
  background: #eef7ff;
}

.illustration-card img {
  display: block;
  width: 100%;
  height: auto;
}

.info-note {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  margin-top: 16px;
  padding: 12px 14px;
  border: 1px solid rgba(248, 113, 113, 0.35);
  border-left: 4px solid rgba(239, 68, 68, 0.65);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(254, 242, 242, 0.96), rgba(255, 247, 247, 0.98), rgba(255, 241, 242, 0.92));
  box-shadow: 0 10px 24px rgba(127, 29, 29, 0.05);
}

.info-note span {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #fee2e2;
  color: #b91c1c;
  font-weight: 800;
}

.info-note p {
  margin: 0;
}

.section-block {
  margin-top: 26px;
}

.bmi-infographic-section {
  width: min(100% - 32px, 1280px);
  margin-top: 40px;
  padding: 12px;
  border-radius: 18px;
}

.bmi-infographic {
  display: block;
  width: min(100%, 1024px);
  height: auto;
  margin-inline: auto;
  border-radius: 14px;
  box-shadow: var(--shadow-soft);
}

.learn-hero {
  position: relative;
  overflow: hidden;
  padding: 58px 0 36px;
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-blue) 100%);
}

.learn-hero::before,
.learn-hero::after {
  content: "";
  position: absolute;
  z-index: 0;
  pointer-events: none;
  border-radius: 999px;
  background: #dff1ff;
  opacity: 0.75;
}

.learn-hero::before {
  left: -80px;
  bottom: -84px;
  width: 230px;
  height: 230px;
}

.learn-hero::after {
  right: -92px;
  top: 58px;
  width: 280px;
  height: 220px;
}

.learn-hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(440px, 1fr);
  align-items: center;
  gap: 44px;
}

.learn-hero-copy h1 {
  max-width: 620px;
  margin: 0 0 18px;
  color: var(--heading);
  font-size: clamp(2.8rem, 5vw, 3.75rem);
  line-height: 1;
  letter-spacing: 0;
}

.learn-hero-copy > p {
  max-width: 560px;
  margin: 0;
  color: var(--text);
  font-size: 1.2rem;
}

.learn-hero-button {
  display: inline-flex;
  width: auto;
  align-items: center;
  justify-content: center;
  margin-top: 28px;
  padding: 0 22px;
}

.learn-trust-line {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 0;
  padding-top: 18px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.learn-trust-line img {
  display: block;
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  object-fit: contain;
}

.learn-hero-art img {
  display: block;
  width: 100%;
  height: auto;
}

.learn-section {
  margin-top: 34px;
}

.learn-section h2 {
  margin: 0 0 18px;
  color: var(--heading);
  line-height: 1.2;
  font-size: clamp(1.45rem, 2.4vw, 1.85rem);
}

.learn-card {
  background: var(--surface);
  border: 1px solid #d5e1ed;
  border-radius: 14px;
  box-shadow: var(--shadow-soft);
}

.learn-topic-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.topic-card {
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: auto auto 1fr auto;
  justify-items: center;
  gap: 12px;
  align-items: start;
  min-height: 252px;
  padding: 22px;
  text-align: center;
}

.topic-card h3,
.factor-card h3,
.small-card h3,
.step-card h3 {
  margin: 0;
  color: var(--heading);
  font-size: 1.02rem;
  line-height: 1.25;
}

.topic-card h3,
.topic-card p,
.topic-card a {
  grid-column: 1;
}

.topic-card p,
.factor-card p,
.small-card p,
.step-card p {
  margin: 8px 0 0;
  color: var(--text);
  font-size: 0.9rem;
}

.topic-card a {
  grid-column: 1;
  align-self: end;
  color: var(--primary);
  font-size: 0.9rem;
  font-weight: 800;
}

.learn-icon {
  width: 114px;
  height: 87px;
  display: grid;
  place-items: center;
}

.learn-icon img {
  width: 114px;
  height: 87px;
  display: block;
  object-fit: contain;
}

.topic-card .learn-icon {
  grid-row: 1;
}

.icon-apple,
.icon-heart {
  color: #16a34a;
}

.icon-shoe {
  color: var(--primary);
}

.icon-moon {
  color: #8b5cf6;
}

.habit-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 38px;
}

.step-card {
  position: relative;
  min-height: 206px;
  padding: 20px;
}

.step-card:not(:last-child)::after {
  content: "→";
  position: absolute;
  right: -28px;
  top: 50%;
  color: #9bb5d5;
  font-size: 2rem;
  font-weight: 800;
  transform: translateY(-50%);
}

.step-number {
  width: 26px;
  height: 26px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-top: 1px;
  border-radius: 50%;
  background: #22c55e;
  color: #ffffff;
  font-size: 0.86rem;
  font-weight: 800;
  line-height: 1;
  text-align: center;
}

.step-number.blue {
  background: var(--primary);
}

.step-number.purple {
  background: #8b5cf6;
}

.step-illustration {
  width: 114px;
  height: 87px;
  display: block;
  margin: 10px auto 16px;
  position: relative;
  object-fit: contain;
}

.step-illustration.bowl {
  border-radius: 8px 8px 32px 32px;
  background: linear-gradient(180deg, #a7f3d0, #38bdf8);
}

.step-illustration.bowl::before {
  content: "";
  position: absolute;
  left: 12px;
  top: -12px;
  width: 52px;
  height: 26px;
  background:
    radial-gradient(circle at 8px 16px, #ef4444 0 5px, transparent 6px),
    radial-gradient(circle at 24px 10px, #22c55e 0 7px, transparent 8px),
    radial-gradient(circle at 40px 16px, #f59e0b 0 5px, transparent 6px);
}

.step-illustration.shoe {
  background: var(--primary);
  border-radius: 10px 24px 10px 18px;
  clip-path: polygon(12% 62%, 38% 18%, 66% 38%, 96% 68%, 88% 88%, 9% 88%);
}

.step-illustration.moon::before {
  content: "";
  position: absolute;
  inset: 3px 16px 3px 12px;
  border-radius: 50%;
  background: #8b5cf6;
  box-shadow: 16px -5px 0 0 var(--surface);
}

.step-illustration.moon::after {
  content: "zZ";
  position: absolute;
  right: 7px;
  top: 0;
  color: #8b5cf6;
  font-weight: 800;
}

.step-illustration.checklist {
  width: 54px;
  border: 3px solid #22c55e;
  border-radius: 8px;
  background:
    linear-gradient(#22c55e, #22c55e) 14px 15px / 26px 3px no-repeat,
    linear-gradient(#22c55e, #22c55e) 14px 29px / 26px 3px no-repeat,
    linear-gradient(#22c55e, #22c55e) 14px 43px / 20px 3px no-repeat;
}

.factor-grid,
.small-change-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 18px;
}

.factor-card,
.small-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: start;
  min-width: 0;
  min-height: 108px;
  padding: 18px;
}

.factor-card {
  grid-template-columns: 1fr;
  justify-items: center;
  text-align: center;
}

.small-card {
  grid-template-columns: 1fr;
  justify-items: center;
  text-align: center;
}

.mini-icon {
  position: relative;
  width: 114px;
  height: 87px;
  display: grid;
  place-items: center;
}

.mini-icon.image-icon::before,
.mini-icon.image-icon::after,
.limitations-icon.image-icon::before,
.limitations-icon.image-icon::after {
  content: none;
}

.mini-icon img,
.limitations-icon img {
  display: block;
  width: 114px;
  height: 87px;
  object-fit: contain;
}

.mini-icon::before,
.mini-icon::after {
  content: "";
  position: absolute;
}

.mini-icon.body::before,
.mini-icon.walk::before,
.mini-icon.activity::before {
  left: 20px;
  top: 8px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
}

.mini-icon.body::after,
.mini-icon.walk::after,
.mini-icon.activity::after {
  left: 18px;
  top: 18px;
  width: 12px;
  height: 22px;
  border-radius: 999px;
  background: #22c55e;
}

.mini-icon.age::before {
  left: 11px;
  top: 15px;
  width: 10px;
  height: 22px;
  border-radius: 999px;
  background: var(--primary);
  box-shadow: 16px 0 0 var(--primary);
}

.mini-icon.age::after {
  left: 13px;
  top: 8px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 16px 0 0 var(--primary);
}

.mini-icon.muscle::before {
  left: 10px;
  top: 16px;
  width: 28px;
  height: 18px;
  border-radius: 16px 16px 10px 10px;
  background: var(--primary);
  transform: rotate(-18deg);
}

.mini-icon.pulse::before {
  left: 9px;
  top: 13px;
  width: 28px;
  height: 22px;
  border: 3px solid #8b5cf6;
  border-radius: 50%;
}

.mini-icon.pulse::after {
  left: 15px;
  top: 23px;
  width: 18px;
  height: 8px;
  border-left: 3px solid #8b5cf6;
  border-bottom: 3px solid #8b5cf6;
  transform: rotate(-35deg);
}

.mini-icon.meal::before {
  left: 10px;
  top: 24px;
  width: 28px;
  height: 14px;
  border-radius: 0 0 18px 18px;
  background: #22c55e;
}

.mini-icon.meal::after {
  left: 13px;
  top: 10px;
  width: 22px;
  height: 18px;
  background:
    radial-gradient(circle at 5px 12px, #16a34a 0 4px, transparent 5px),
    radial-gradient(circle at 12px 6px, #f59e0b 0 4px, transparent 5px),
    radial-gradient(circle at 19px 12px, #ef4444 0 4px, transparent 5px);
}

.mini-icon.dumbbell::before {
  left: 8px;
  top: 21px;
  width: 32px;
  height: 6px;
  background: #8b5cf6;
}

.mini-icon.dumbbell::after {
  left: 5px;
  top: 16px;
  width: 7px;
  height: 16px;
  border-radius: 3px;
  background: #8b5cf6;
  box-shadow: 31px 0 0 #8b5cf6;
}

.mini-icon.water::before {
  left: 13px;
  top: 7px;
  width: 22px;
  height: 32px;
  border: 3px solid #38bdf8;
  border-radius: 16px 16px 18px 18px;
  transform: rotate(45deg);
}

.mini-icon.support::before {
  left: 13px;
  top: 9px;
  width: 22px;
  height: 26px;
  border: 3px solid #22c55e;
  border-top: 0;
  border-radius: 0 0 14px 14px;
}

.mini-icon.support::after {
  left: 10px;
  top: 7px;
  width: 8px;
  height: 8px;
  border: 3px solid #22c55e;
  border-radius: 50%;
  box-shadow: 18px 0 0 -1px #22c55e;
}

.learn-info-strip,
.learn-disclaimer-strip {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: center;
  margin-top: 18px;
  padding: 14px 22px;
  border: 1px solid rgba(248, 113, 113, 0.45);
  border-left: 4px solid rgba(239, 68, 68, 0.55);
  border-radius: 10px;
  background: var(--surface);
  color: var(--heading);
  box-shadow: var(--shadow-soft);
}

.learn-info-strip {
  border-color: rgba(248, 113, 113, 0.35);
  border-left-color: rgba(239, 68, 68, 0.65);
  background:
    linear-gradient(135deg, rgba(254, 242, 242, 0.96), rgba(255, 247, 247, 0.98), rgba(255, 241, 242, 0.92));
  box-shadow: 0 10px 24px rgba(127, 29, 29, 0.05);
}

.learn-info-strip span {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #fee2e2;
  color: #b91c1c;
  font-weight: 800;
}

.learn-info-strip p,
.learn-disclaimer-strip p {
  margin: 0;
}

.learn-limitations-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 24px;
  align-items: center;
  padding: 24px 34px;
  border: 1px solid rgba(248, 113, 113, 0.45);
  border-left: 4px solid rgba(239, 68, 68, 0.55);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.learn-limitations-card p {
  margin: 0;
  color: var(--text);
}

.limitations-icon {
  position: relative;
  width: 114px;
  height: 87px;
  display: grid;
  place-items: center;
}

.limitations-icon img {
  width: 114px;
  height: 87px;
}

.limitations-icon::before {
  content: "";
  position: absolute;
  left: 28px;
  top: 12px;
  width: 4px;
  height: 34px;
  border-radius: 999px;
  background: var(--primary);
}

.limitations-icon::after {
  content: "";
  position: absolute;
  left: 14px;
  top: 22px;
  width: 34px;
  height: 22px;
  border: 3px solid var(--primary);
  border-top: 0;
  border-radius: 0 0 18px 18px;
  box-shadow: 0 -14px 0 -11px var(--primary);
}

.learn-faq {
  margin-top: 0;
}

.learn-disclaimer-strip {
  margin-top: 28px;
  margin-bottom: 26px;
}

.learn-disclaimer-strip img {
  display: block;
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.guide-hero {
  padding: 48px 0 28px;
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg-blue) 100%);
}

.guide-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 360px);
  gap: 38px;
  align-items: center;
}

.guide-eyebrow {
  margin: 0 0 10px;
  color: var(--primary);
  font-size: 0.84rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.guide-hero h1 {
  max-width: 680px;
  margin: 0;
  color: var(--heading);
  font-size: clamp(2.25rem, 5vw, 3.35rem);
  line-height: 1.05;
  letter-spacing: 0;
}

.guide-hero-copy > p {
  max-width: 650px;
  margin: 16px 0 0;
  color: var(--text);
  font-size: 1.08rem;
}

.guide-hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 24px;
}

.guide-hero-actions .primary-button,
.guide-hero-actions .secondary-button {
  width: auto;
  min-height: 52px;
  margin-top: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 26px;
  border-radius: 12px;
  line-height: 1;
  text-decoration: none;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, border-color 180ms ease;
}

.guide-hero-actions .primary-button {
  background: linear-gradient(135deg, #2f73f6, var(--primary-dark));
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.26);
}

.guide-hero-actions .primary-button:hover,
.guide-hero-actions .primary-button:focus-visible {
  background: linear-gradient(135deg, #3b82f6, var(--primary-dark));
  box-shadow: 0 18px 34px rgba(37, 99, 235, 0.32);
  transform: translateY(-1px);
}

.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #b9cff0;
  border-radius: 8px;
  background: var(--surface);
  color: var(--primary);
  font-weight: 800;
}

.guide-hero-actions .secondary-button:hover {
  background: var(--bg-blue);
  border-color: var(--primary);
  transform: translateY(-1px);
}

.guide-hero-actions .primary-button:focus-visible,
.guide-hero-actions .secondary-button:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

.guide-hero-icon {
  justify-self: center;
  width: min(100%, 260px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px solid #d5e1ed;
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.guide-hero-icon img {
  width: 72%;
  height: 72%;
  object-fit: contain;
}

.nutrition-hero-visual {
  width: min(100%, 380px);
  aspect-ratio: 1;
  padding: 16px;
}

.nutrition-hero-visual img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.move-hero-visual,
.sleep-hero-visual,
.habits-hero-visual {
  width: min(100%, 380px);
  padding: 0;
  overflow: hidden;
}

.move-hero-visual img,
.sleep-hero-visual img,
.habits-hero-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

.guide-section {
  margin-top: 30px;
}

.guide-section h2 {
  margin: 0 0 16px;
  color: var(--heading);
  font-size: clamp(1.35rem, 2.4vw, 1.8rem);
  line-height: 1.2;
}

.guide-section-intro {
  max-width: 760px;
  margin: -6px 0 16px;
  color: var(--text);
  font-size: 1rem;
}

.guide-card {
  padding: 22px;
}

.guide-card p,
.guide-card li {
  color: var(--text);
}

.guide-overview {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 18px;
  align-items: center;
}

.guide-overview img {
  width: 82px;
  height: 82px;
  object-fit: contain;
}

.guide-overview p {
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.65;
}

.infographic-grid,
.tips-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.tips-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.info-tile,
.tip-card {
  min-width: 0;
  padding: 18px;
  border: 1px solid #d5e1ed;
  border-radius: 12px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.info-tile strong,
.tip-card strong {
  display: block;
  color: var(--heading);
}

.info-tile p,
.tip-card p {
  margin: 8px 0 0;
  color: var(--text);
  font-size: 0.92rem;
}

.visual-dot {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  margin-bottom: 12px;
  border-radius: 50%;
  background: #dbeafe;
  color: var(--primary);
  font-weight: 900;
}

.visual-dot.green {
  background: #dcfce7;
  color: #16a34a;
}

.visual-dot.purple {
  background: #ede9fe;
  color: #8b5cf6;
}

.movement-ladder,
.sleep-cycle,
.habit-loop {
  padding: 22px;
  border: 1px solid #cfe0f4;
  border-radius: 16px;
  background: var(--surface-soft);
}

.ladder-steps,
.routine-cards,
.loop-steps {
  display: grid;
  gap: 14px;
}

.ladder-steps {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  align-items: end;
}

.ladder-step {
  display: grid;
  align-content: end;
  min-height: calc(92px + (var(--level) * 18px));
  padding: 14px;
  border-radius: 12px;
  background: linear-gradient(180deg, #dbeafe, #dcfce7);
  color: var(--heading);
  font-weight: 800;
  text-align: center;
}

.routine-cards,
.loop-steps {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.routine-card,
.loop-card {
  padding: 16px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid #d5e1ed;
}

.routine-card strong,
.loop-card strong {
  color: var(--heading);
}

.routine-card p,
.loop-card p {
  margin: 8px 0 0;
  color: var(--text);
}

.guide-context {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 16px;
  align-items: start;
  padding: 20px 22px;
  border: 1px solid rgba(248, 113, 113, 0.45);
  border-left: 4px solid rgba(239, 68, 68, 0.55);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.guide-context img {
  width: 48px;
  height: 48px;
  object-fit: contain;
}

.guide-context p {
  margin: 0;
  color: var(--text);
}

.nutrition-infographic-card {
  padding: 14px;
  border: 1px solid #d5e1ed;
  border-radius: 20px;
  background: var(--surface);
  box-shadow:
    0 24px 56px rgba(15, 92, 190, 0.12),
    0 10px 26px rgba(12, 32, 67, 0.08);
}

.nutrition-infographic-card img {
  display: block;
  width: min(100%, 1040px);
  height: auto;
  margin-inline: auto;
  border-radius: 12px;
}

.nutrition-infographic-card p {
  max-width: 760px;
  margin: 14px auto 0;
  color: var(--muted);
  font-size: 0.92rem;
  text-align: center;
}

.nutrition-transition-note {
  max-width: 980px;
  margin: 34px auto 38px;
  padding: 22px 24px;
  border: 1px solid #d5e1ed;
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(239, 246, 255, 0.92), rgba(255, 255, 255, 0.98), rgba(240, 253, 244, 0.82));
  box-shadow:
    0 18px 42px rgba(12, 32, 67, 0.08),
    0 8px 20px rgba(15, 92, 190, 0.08);
}

.nutrition-transition-note p {
  margin: 0;
  color: var(--text);
  font-size: clamp(1rem, 1.5vw, 1.08rem);
  line-height: 1.75;
}

[data-theme="dark"] .nutrition-transition-note {
  background: var(--surface);
  border-color: var(--border);
}

.nutrition-closing-card p {
  max-width: 850px;
  margin: 0;
  font-size: 1rem;
  line-height: 1.7;
}

.move-infographic-card,
.sleep-infographic-card,
.habits-infographic-card {
  padding: 14px;
  border: 1px solid #d5e1ed;
  border-radius: 20px;
  background: var(--surface);
  box-shadow:
    0 24px 56px rgba(15, 92, 190, 0.12),
    0 10px 26px rgba(12, 32, 67, 0.08);
}

.pt-visual-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.pt-visual-summary article,
.pt-summary-card {
  min-height: 132px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background:
    linear-gradient(135deg, rgba(239, 246, 255, 0.94), rgba(255, 255, 255, 0.98));
}

.pt-visual-summary article > span {
  display: inline-grid;
  width: 30px;
  height: 30px;
  place-items: center;
  margin-bottom: 12px;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.1);
  color: var(--primary);
  font-size: 0.76rem;
  font-weight: 900;
}

.pt-visual-summary article strong,
.pt-summary-card strong {
  display: block;
  color: var(--heading);
  font-size: 1rem;
}

.pt-visual-summary article p,
.pt-summary-card p {
  margin: 8px 0 0;
  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.6;
  text-align: left;
}

.pt-visual-summary-note,
.pt-summary-note {
  grid-column: 1 / -1;
  margin: 2px 0 0;
  padding: 14px 16px;
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-left: 4px solid rgba(37, 99, 235, 0.55);
  border-radius: 12px;
  background: var(--surface-soft);
  color: var(--text);
  font-size: 0.94rem;
  text-align: left;
}

.move-infographic-card img,
.sleep-infographic-card img,
.habits-infographic-card img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 14px;
}

.move-infographic-card p,
.sleep-infographic-card p,
.habits-infographic-card p {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
  text-align: center;
}

.move-display-case {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr);
  align-items: stretch;
  gap: 16px;
}

.move-display-feature {
  grid-row: span 2;
  display: grid;
  align-content: center;
  gap: 14px;
  padding: 32px 30px;
  border: 1px solid #cfe0f5;
  border-radius: 22px;
  background:
    radial-gradient(circle at 84% 14%, rgba(47, 191, 113, 0.16) 0 80px, transparent 92px),
    radial-gradient(circle at 8% 92%, rgba(47, 115, 246, 0.1) 0 70px, transparent 82px),
    linear-gradient(150deg, rgba(226, 239, 255, 0.95) 0%, rgba(255, 255, 255, 0.98) 55%, rgba(236, 253, 243, 0.9) 100%);
  box-shadow:
    0 20px 44px rgba(12, 32, 67, 0.1),
    0 8px 20px rgba(15, 92, 190, 0.08);
}

.move-display-eyebrow {
  margin: 0;
  color: var(--primary);
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.move-display-feature h3 {
  margin: 0;
  color: var(--heading);
  font-size: 1.32rem;
  line-height: 1.25;
}

.move-display-feature > p:not(.move-display-eyebrow) {
  margin: 0;
  max-width: 400px;
  color: var(--text);
  line-height: 1.7;
}

.move-display-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: start;
  padding: 20px;
  border: 1px solid #d9e4f2;
  border-radius: 18px;
  background:
    linear-gradient(160deg, rgba(239, 246, 255, 0.9) 0%, rgba(255, 255, 255, 0.98) 60%, rgba(240, 253, 244, 0.75) 100%);
  box-shadow:
    0 14px 30px rgba(12, 32, 67, 0.07),
    0 5px 14px rgba(15, 92, 190, 0.06);
}

.move-display-item-wide {
  grid-column: 1 / -1;
  align-items: center;
}

.move-display-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(47, 115, 246, 0.18);
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(47, 115, 246, 0.12), rgba(47, 191, 113, 0.14));
  color: var(--primary);
}

.move-display-item:nth-of-type(odd) .move-display-icon {
  border-color: rgba(47, 191, 113, 0.26);
  color: #16915c;
}

.move-display-icon svg {
  width: 24px;
  height: 24px;
}

.move-display-item strong {
  display: block;
  margin-bottom: 6px;
  color: var(--heading);
  font-size: 1.02rem;
}

.move-display-item p {
  margin: 0;
  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.65;
}

.sleep-display-case {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.2fr);
  align-items: stretch;
  gap: 16px;
}

.sleep-display-feature {
  grid-column: 3;
  grid-row: 1 / span 2;
  display: grid;
  align-content: center;
  gap: 14px;
  padding: 32px 30px;
  border: 1px solid #d7dcf5;
  border-radius: 22px;
  background:
    radial-gradient(circle at 16% 14%, rgba(139, 92, 246, 0.14) 0 80px, transparent 92px),
    radial-gradient(circle at 88% 90%, rgba(47, 191, 113, 0.12) 0 70px, transparent 82px),
    linear-gradient(150deg, rgba(233, 235, 255, 0.95) 0%, rgba(255, 255, 255, 0.98) 55%, rgba(238, 251, 250, 0.92) 100%);
  box-shadow:
    0 20px 44px rgba(30, 27, 75, 0.1),
    0 8px 20px rgba(99, 102, 241, 0.08);
}

.sleep-display-eyebrow {
  margin: 0;
  color: #5b5bd6;
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.sleep-display-feature h3 {
  margin: 0;
  color: var(--heading);
  font-size: 1.32rem;
  line-height: 1.25;
}

.sleep-display-feature > p:not(.sleep-display-eyebrow) {
  margin: 0;
  max-width: 400px;
  color: var(--text);
  line-height: 1.7;
}

.sleep-display-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: start;
  padding: 20px;
  border: 1px solid #dde2f4;
  border-radius: 18px;
  background:
    linear-gradient(160deg, rgba(238, 240, 255, 0.9) 0%, rgba(255, 255, 255, 0.98) 60%, rgba(240, 253, 249, 0.78) 100%);
  box-shadow:
    0 14px 30px rgba(30, 27, 75, 0.07),
    0 5px 14px rgba(99, 102, 241, 0.06);
}

.sleep-display-item-wide {
  grid-column: 1 / -1;
  align-items: center;
}

.sleep-display-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(99, 102, 241, 0.2);
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(47, 191, 113, 0.12));
  color: #5b5bd6;
}

.sleep-display-item:nth-of-type(odd) .sleep-display-icon {
  border-color: rgba(47, 191, 113, 0.26);
  color: #16915c;
}

.sleep-display-icon svg {
  width: 24px;
  height: 24px;
}

.sleep-display-item strong {
  display: block;
  margin-bottom: 6px;
  color: var(--heading);
  font-size: 1.02rem;
}

.sleep-display-item p {
  margin: 0;
  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.65;
}

.habits-display-case {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr);
  align-items: stretch;
  gap: 16px;
}

.habits-display-feature {
  grid-row: span 2;
  display: grid;
  align-content: center;
  gap: 14px;
  padding: 32px 30px;
  border: 1px solid #cfe8d8;
  border-radius: 22px;
  background:
    radial-gradient(circle at 84% 14%, rgba(47, 115, 246, 0.1) 0 80px, transparent 92px),
    radial-gradient(circle at 10% 88%, rgba(47, 191, 113, 0.15) 0 70px, transparent 82px),
    linear-gradient(150deg, rgba(230, 249, 238, 0.95) 0%, rgba(255, 255, 255, 0.98) 55%, rgba(235, 244, 255, 0.92) 100%);
  box-shadow:
    0 20px 44px rgba(6, 78, 59, 0.1),
    0 8px 20px rgba(22, 145, 92, 0.08);
}

.habits-display-eyebrow {
  margin: 0;
  color: #16915c;
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.habits-display-feature h3 {
  margin: 0;
  color: var(--heading);
  font-size: 1.32rem;
  line-height: 1.25;
}

.habits-display-feature > p:not(.habits-display-eyebrow) {
  margin: 0;
  max-width: 400px;
  color: var(--text);
  line-height: 1.7;
}

.habits-display-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  align-items: start;
  padding: 20px;
  border: 1px solid #d4e8dc;
  border-radius: 18px;
  background:
    linear-gradient(160deg, rgba(236, 250, 242, 0.9) 0%, rgba(255, 255, 255, 0.98) 60%, rgba(239, 246, 255, 0.78) 100%);
  box-shadow:
    0 14px 30px rgba(6, 78, 59, 0.07),
    0 5px 14px rgba(22, 145, 92, 0.06);
}

.habits-display-item-wide {
  grid-column: 1 / -1;
  align-items: center;
}

.habits-display-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(47, 191, 113, 0.26);
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(47, 191, 113, 0.13), rgba(47, 115, 246, 0.1));
  color: #16915c;
}

.habits-display-item:nth-of-type(odd) .habits-display-icon {
  border-color: rgba(47, 115, 246, 0.2);
  color: var(--primary);
}

.habits-display-icon svg {
  width: 24px;
  height: 24px;
}

.habits-display-item strong {
  display: block;
  margin-bottom: 6px;
  color: var(--heading);
  font-size: 1.02rem;
}

.habits-display-item p {
  margin: 0;
  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.65;
}

.move-safety-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

[data-theme="dark"] .move-infographic-card,
[data-theme="dark"] .move-display-feature,
[data-theme="dark"] .move-display-item,
[data-theme="dark"] .sleep-infographic-card,
[data-theme="dark"] .sleep-display-feature,
[data-theme="dark"] .sleep-display-item,
[data-theme="dark"] .habits-infographic-card,
[data-theme="dark"] .habits-display-feature,
[data-theme="dark"] .habits-display-item {
  background: var(--surface);
  border-color: var(--border);
}

[data-theme="dark"] .move-display-icon,
[data-theme="dark"] .sleep-display-icon,
[data-theme="dark"] .habits-display-icon {
  border-color: var(--border);
  background: rgba(96, 165, 250, 0.12);
}

[data-theme="dark"] .habits-display-eyebrow {
  color: #6ee7b7;
}

[data-theme="dark"] .habits-display-icon {
  color: #6ee7b7;
}

[data-theme="dark"] .habits-display-item:nth-of-type(odd) .habits-display-icon {
  color: #93c5fd;
}

[data-theme="dark"] .sleep-display-eyebrow {
  color: #a5b4fc;
}

[data-theme="dark"] .sleep-display-icon {
  color: #a5b4fc;
}

[data-theme="dark"] .sleep-display-item:nth-of-type(odd) .sleep-display-icon {
  color: #6ee7b7;
}

.nutrition-cta-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 28px 32px;
  border: 1px solid #d5e1ed;
  border-radius: 20px;
  background:
    linear-gradient(135deg, rgba(239, 246, 255, 0.92) 0%, rgba(255, 255, 255, 0.98) 55%, rgba(240, 253, 244, 0.85) 100%);
  box-shadow:
    0 18px 42px rgba(12, 32, 67, 0.08),
    0 8px 20px rgba(15, 92, 190, 0.08);
}

.nutrition-cta-copy {
  max-width: 560px;
}

.nutrition-cta-copy h2 {
  margin: 0 0 8px;
}

.nutrition-cta-copy p {
  margin: 0;
  color: var(--text);
}

.nutrition-cta-card .guide-hero-actions {
  margin-top: 0;
  flex-shrink: 0;
}

[data-theme="dark"] .nutrition-cta-card {
  background: var(--surface);
  border-color: var(--border);
}

.faq-hero {
  position: relative;
  overflow: hidden;
  padding: 54px 0 36px;
  background:
    radial-gradient(circle at 5% 88%, rgba(191, 219, 254, 0.55) 0 120px, transparent 122px),
    radial-gradient(circle at 94% 24%, rgba(187, 247, 208, 0.42) 0 116px, transparent 118px),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-blue) 100%);
}

.faq-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 340px);
  gap: 42px;
  align-items: center;
}

.faq-hero h1 {
  max-width: 720px;
  margin: 0;
  color: var(--heading);
  font-size: clamp(2.65rem, 5.4vw, 4rem);
  line-height: 1;
  letter-spacing: 0;
}

.faq-hero-copy > p {
  max-width: 650px;
  margin: 16px 0 0;
  color: var(--text);
  font-size: 1.12rem;
}

.faq-hero-visual {
  position: relative;
  justify-self: center;
  width: min(100%, 260px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border: 1px solid #d5e1ed;
  border-radius: 26px;
  background:
    radial-gradient(circle at 28% 24%, #dbeafe 0 22px, transparent 23px),
    radial-gradient(circle at 76% 72%, #dcfce7 0 34px, transparent 35px),
    var(--surface);
  box-shadow: var(--shadow-soft);
}

.faq-hero-visual span {
  position: absolute;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-weight: 900;
}

.faq-hero-visual span:first-child {
  width: 112px;
  height: 112px;
  background: linear-gradient(135deg, #3b82f6, var(--primary-dark));
  color: #ffffff;
  font-size: 4rem;
}

.faq-hero-visual span:nth-child(2) {
  right: 38px;
  bottom: 38px;
  width: 46px;
  height: 46px;
  background: #dcfce7;
  color: #16a34a;
  font-size: 1.35rem;
}

.faq-hero-visual span:nth-child(3) {
  left: 36px;
  top: 42px;
  width: 42px;
  height: 42px;
  background: #eff6ff;
  color: var(--primary);
  font-size: 1.2rem;
}

.faq-hero-visual img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: inherit;
}

.about-trio-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

@media (max-width: 820px) {
  .about-trio-grid {
    grid-template-columns: 1fr;
  }
}

.faq-page-section {
  margin-top: 30px;
}

.faq-section-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.faq-section-heading span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #dbeafe;
  color: var(--primary);
  font-weight: 900;
}

.faq-section-heading h2 {
  margin: 0;
  color: var(--heading);
  font-size: clamp(1.35rem, 2.2vw, 1.75rem);
}

.faq-accordion-list {
  overflow: hidden;
  border: 1px solid #d5e1ed;
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.faq-accordion-list details {
  border-bottom: 1px solid var(--border);
}

.faq-accordion-list details:last-child {
  border-bottom: 0;
}

.faq-accordion-list summary {
  min-height: 62px;
  padding: 0 22px;
  font-size: 1rem;
}

.faq-accordion-list details p {
  padding: 0 22px 20px;
  color: var(--text);
}

.faq-context-callout {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 22px;
  align-items: center;
  padding: 26px 30px;
  border: 1px solid rgba(96, 165, 250, 0.42);
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(239, 246, 255, 0.92), rgba(255, 255, 255, 0.98));
  box-shadow: var(--shadow-soft);
}

.faq-context-callout img {
  width: 92px;
  height: 92px;
  object-fit: contain;
}

.faq-context-callout h2 {
  margin: 0 0 8px;
  color: var(--heading);
}

.faq-context-callout p {
  margin: 0;
  color: var(--text);
}

[data-theme="dark"] .faq-hero-visual,
[data-theme="dark"] .faq-accordion-list,
[data-theme="dark"] .faq-context-callout {
  border-color: var(--border);
  background: var(--surface);
}

.bmi-categories-hero {
  position: relative;
  overflow: hidden;
  padding: 54px 0 34px;
  background:
    radial-gradient(circle at 2% 94%, rgba(191, 219, 254, 0.55) 0 138px, transparent 140px),
    radial-gradient(circle at 97% 32%, rgba(187, 247, 208, 0.42) 0 118px, transparent 120px),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-blue) 100%);
}

.bmi-categories-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 430px);
  gap: 42px;
  align-items: center;
}

.bmi-categories-hero h1 {
  max-width: 600px;
  margin: 0;
  color: var(--heading);
  font-size: clamp(2.65rem, 5.6vw, 4.2rem);
  line-height: 1;
  letter-spacing: 0;
}

.bmi-categories-hero-copy > p {
  max-width: 650px;
  margin: 16px 0 0;
  color: var(--text);
  font-size: 1.12rem;
}

.bmi-categories-hero-visual {
  justify-self: center;
  width: min(100%, 430px);
  overflow: hidden;
  border: 1px solid #d5e1ed;
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.bmi-categories-hero-visual img {
  display: block;
  width: 100%;
  height: auto;
}

.bmi-range-panel,
.obesity-classes-panel,
.bmi-context-panel {
  border: 1px solid #d5e1ed;
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.bmi-range-panel {
  padding: 30px 32px 28px;
}

.bmi-range-heading {
  display: flex;
  justify-content: space-between;
  gap: 24px;
}

.bmi-range-heading h2,
.obesity-classes-panel h2 {
  margin: 0 0 8px;
  color: var(--heading);
}

.bmi-range-heading p,
.obesity-classes-panel p {
  max-width: 760px;
  margin: 0;
  color: var(--text);
}

.category-scale {
  margin-top: 28px;
}

.category-scale-track {
  position: relative;
  min-height: 20px;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    #5d9ff8 0%,
    #54a8ef 5%,
    #3fbd85 16%,
    #34c178 30%,
    #e5c355 42%,
    #f0aa4e 52%,
    #ec8757 64%,
    #e3646c 78%,
    #da4f5c 100%
  );
  box-shadow:
    inset 0 0 0 1px rgba(16, 38, 83, 0.08),
    0 10px 22px rgba(16, 38, 83, 0.1);
}

.category-scale-track::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0) 55%);
}

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

.category-scale-labels div {
  position: relative;
  min-width: 0;
  padding: 14px 16px 14px 20px;
  border: 1px solid color-mix(in srgb, var(--label-color, var(--border)) 26%, var(--border));
  border-radius: 14px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--label-color, var(--border)) 8%, var(--surface)), var(--surface));
  box-shadow: 0 6px 14px rgba(16, 38, 83, 0.05);
}

.category-scale-labels div::before {
  content: "";
  position: absolute;
  left: 0;
  top: 14px;
  bottom: 14px;
  width: 4px;
  border-radius: 999px;
  background: var(--label-color, var(--border));
}

.category-scale-labels .underweight {
  --label-color: #60a5fa;
}

.category-scale-labels .healthy {
  --label-color: #22c55e;
}

.category-scale-labels .overweight {
  --label-color: #fbbf24;
}

.category-scale-labels .obesity {
  --label-color: #fb7185;
}

.category-scale-labels strong,
.category-scale-labels span {
  display: block;
}

.category-scale-labels strong {
  color: var(--heading);
  font-size: 0.94rem;
}

.category-scale-labels span {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 700;
}

.category-scale-thresholds {
  position: relative;
  height: 42px;
  margin-top: 8px;
  font-size: 0.82rem;
  font-weight: 800;
}

.category-scale-thresholds span {
  position: absolute;
  top: 13px;
  transform: translateX(-50%);
  padding: 3px 9px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface-soft);
  color: var(--heading);
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
}

.category-scale-thresholds span::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -13px;
  width: 2px;
  height: 9px;
  border-radius: 999px;
  background: var(--muted);
  opacity: 0.55;
  transform: translateX(-50%);
}

.category-scale-thresholds span:first-child {
  transform: none;
}

.category-scale-thresholds span:first-child::before {
  left: 2px;
  transform: none;
}

.category-scale-thresholds span:last-child {
  transform: translateX(-100%);
}

.category-scale-thresholds span:last-child::before {
  left: auto;
  right: 2px;
  transform: none;
}

.category-scale-caption {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.85rem;
}

.bmi-range-note {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 12px;
  align-items: center;
  margin-top: 20px;
  padding: 14px 16px;
  border: 1px solid #bfdbfe;
  border-radius: 12px;
  background: #eff6ff;
  color: var(--heading);
}

.bmi-range-note span {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #dbeafe;
  color: var(--primary);
  font-weight: 800;
}

.bmi-range-note p {
  margin: 0;
}

.bmi-category-card-grid,
.next-step-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.bmi-category-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 260px;
  padding: 26px 24px 24px;
  border: 1px solid color-mix(in srgb, var(--category-color) 24%, var(--border));
  border-radius: 20px;
  background: radial-gradient(120% 72% at 50% 0%, color-mix(in srgb, var(--category-color) 9%, var(--surface)) 0%, var(--surface) 62%);
  box-shadow: 0 14px 30px rgba(16, 38, 83, 0.07);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.bmi-category-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 38px rgba(16, 38, 83, 0.11);
}

.bmi-category-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  background: linear-gradient(90deg, transparent, var(--category-color) 22%, var(--category-color) 78%, transparent);
}

.bmi-category-card.underweight {
  --category-color: #60a5fa;
}

.bmi-category-card.healthy {
  --category-color: #22c55e;
}

.bmi-category-card.overweight {
  --category-color: #fbbf24;
}

.bmi-category-card.obesity {
  --category-color: #fb7185;
}

.category-dot {
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: color-mix(in srgb, var(--category-color) 15%, var(--surface));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--category-color) 32%, transparent);
}

.category-dot::before {
  content: "";
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--category-color);
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--category-color) 22%, transparent);
}

.bmi-category-card h3,
.next-step-card h3 {
  margin: 16px 0 0;
  color: var(--heading);
  font-size: 1.08rem;
}

.category-range {
  align-self: flex-start;
  margin: 8px 0 14px;
  padding: 4px 11px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--category-color) 13%, var(--surface));
  color: color-mix(in srgb, var(--category-color) 70%, var(--heading));
  font-size: 0.85rem;
  font-weight: 800;
}

.bmi-category-card p:not(.category-range),
.next-step-card p {
  margin: 0;
  color: var(--text);
  font-size: 0.94rem;
}

.obesity-classes-panel {
  display: grid;
  grid-template-columns: minmax(220px, 0.72fr) minmax(0, 1fr);
  gap: 24px;
  align-items: center;
  padding: 24px;
}

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

.obesity-class-grid article {
  position: relative;
  padding: 18px 18px 18px 24px;
  border: 1px solid color-mix(in srgb, #fb7185 24%, var(--border));
  border-radius: 14px;
  background: linear-gradient(180deg, color-mix(in srgb, #fb7185 7%, var(--surface)), var(--surface));
}

.obesity-class-grid article::before {
  content: "";
  position: absolute;
  left: 0;
  top: 16px;
  bottom: 16px;
  width: 4px;
  border-radius: 999px;
  background: #fb7185;
}

.obesity-class-grid strong,
.obesity-class-grid span {
  display: block;
}

.obesity-class-grid strong {
  color: var(--heading);
}

.obesity-class-grid span {
  margin-top: 6px;
  color: #be123c;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.bmi-context-panel {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 22px;
  align-items: center;
  padding: 24px 30px;
  border-color: rgba(96, 165, 250, 0.42);
  background: linear-gradient(135deg, rgba(239, 246, 255, 0.92), rgba(255, 255, 255, 0.98));
}

.bmi-context-panel img {
  width: 92px;
  height: 92px;
  object-fit: contain;
}

.bmi-context-panel ul {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  color: var(--text);
  list-style: none;
}

.bmi-context-panel li {
  position: relative;
  padding-left: 24px;
}

.bmi-context-panel li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--primary);
  opacity: 0.5;
}

.next-step-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.next-step-card {
  min-height: 174px;
  padding: 24px;
  border: 1px solid #d5e1ed;
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.next-step-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 32px rgba(16, 38, 83, 0.1);
}

.next-step-card span {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(135deg, #dbeafe, #eff6ff);
  color: var(--primary);
  font-weight: 800;
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.16);
}

[data-theme="dark"] .bmi-categories-hero-visual,
[data-theme="dark"] .bmi-range-panel,
[data-theme="dark"] .obesity-classes-panel,
[data-theme="dark"] .next-step-card {
  border-color: var(--border);
  background: var(--surface);
}

[data-theme="dark"] .bmi-range-note,
[data-theme="dark"] .bmi-context-panel {
  border-color: var(--border);
  background: var(--surface-soft);
}

[data-theme="dark"] .bmi-range-note span {
  background: rgba(96, 165, 250, 0.2);
  color: #93c5fd;
}

[data-theme="dark"] .next-step-card span {
  background: rgba(96, 165, 250, 0.16);
  color: #93c5fd;
  box-shadow: inset 0 0 0 1px rgba(96, 165, 250, 0.28);
}

[data-theme="dark"] .obesity-class-grid span {
  color: #fda4af;
}

[data-theme="dark"] .category-scale-track {
  box-shadow:
    inset 0 0 0 1px rgba(0, 0, 0, 0.25),
    0 10px 22px rgba(0, 0, 0, 0.28);
}

[data-theme="dark"] .category-scale-track::after {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0) 55%);
}

.nutrition-footer-grid {
  gap: 28px;
  padding: 36px 0 30px;
}

.nutrition-footer-brand strong {
  display: block;
  margin-bottom: 8px;
  color: var(--heading);
  font-size: 1.08rem;
}

.nutrition-footer-brand p {
  margin: 0;
  max-width: 280px;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.6;
}

.nutrition-footer-col {
  gap: 7px;
}

.nutrition-footer-heading {
  margin-bottom: 1px;
}

.nutrition-footer-col a {
  line-height: 1.35;
}

.nutrition-footer-col a:hover,
.nutrition-footer-col a:focus-visible {
  color: var(--primary);
}

.nutrition-footer-col a.active {
  color: var(--primary);
  font-weight: 700;
}

.nutrition-footer-legal {
  color: var(--muted);
  font-size: 0.84rem;
}

.nutrition-footer-legal span {
  color: var(--text);
  font-weight: 700;
}

.nutrition-footer-legal p {
  margin: 6px 0 0;
  line-height: 1.5;
}

@media (max-width: 860px) {
  .site-footer-grid,
  .nutrition-footer-grid {
    grid-template-columns: 1fr 1fr;
    row-gap: 28px;
  }
}

@media (max-width: 560px) {
  .nutrition-cta-card {
    justify-content: center;
    text-align: center;
    padding: 26px 22px;
  }

  .nutrition-cta-copy {
    max-width: none;
  }

  .site-footer-grid,
  .nutrition-footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 32px 0 28px;
  }

  .footer-brand p,
  .nutrition-footer-brand p {
    margin-inline: auto;
  }

  .footer-col,
  .nutrition-footer-col {
    align-items: center;
  }

  .footer-bottom-bar {
    flex-direction: column;
    text-align: center;
  }

  .footer-brand-note {
    margin-inline: auto;
  }
}

.nutrition-feature-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.75fr);
  gap: 28px;
  align-items: start;
}

.nutrition-carousel-column {
  min-width: 0;
}

.nutrition-tips-column {
  min-width: 0;
}

.nutrition-tips-column h2 {
  margin-bottom: 16px;
}

.nutrition-tips-stack {
  display: grid;
  gap: 22px;
  padding-top: 34px;
  counter-reset: tip-counter;
}

.tip-card {
  position: relative;
  padding: 28px 24px 28px 64px;
  border: 1px solid #d9e4f2;
  border-radius: 16px;
  background: linear-gradient(160deg, rgba(239, 246, 255, 0.9) 0%, rgba(255, 255, 255, 0.98) 60%);
  box-shadow:
    0 16px 34px rgba(12, 32, 67, 0.08),
    0 6px 16px rgba(15, 92, 190, 0.07);
  counter-increment: tip-counter;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.tip-card::before {
  content: counter(tip-counter, decimal-leading-zero);
  position: absolute;
  left: 20px;
  top: 20px;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #2f73f6, var(--primary-dark));
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  box-shadow: 0 6px 14px rgba(37, 99, 235, 0.28);
}

.tip-card:hover {
  transform: translateY(-2px);
  box-shadow:
    0 20px 42px rgba(12, 32, 67, 0.11),
    0 8px 20px rgba(15, 92, 190, 0.1);
}

.nutrition-tips-stack .tip-card::before {
  content: none;
}

.tip-icon {
  position: absolute;
  left: 20px;
  top: 20px;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #2f73f6, var(--primary-dark));
  color: #ffffff;
  box-shadow: 0 6px 14px rgba(37, 99, 235, 0.28);
}

.tip-icon svg {
  width: 16px;
  height: 16px;
}

.tip-card strong {
  margin-bottom: 6px;
  font-size: 1.04rem;
  letter-spacing: -0.01em;
}

.tip-card p {
  margin: 0;
  line-height: 1.7;
}

.tips-grid {
  counter-reset: tip-counter;
}

.bmi-nutrition-carousel-wrap {
  min-width: 0;
  max-width: 820px;
  margin: 0;
  padding: 18px;
  border-radius: 22px;
  background:
    linear-gradient(135deg, rgba(239, 246, 255, 0.96), rgba(255, 255, 255, 0.98), rgba(240, 253, 244, 0.94));
  border: 1px solid #d5e1ed;
  box-shadow:
    0 24px 60px rgba(15, 92, 190, 0.14),
    0 12px 28px rgba(12, 32, 67, 0.09);
}

.bmi-nutrition-carousel {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 8px 4px 18px;
  -webkit-overflow-scrolling: touch;
}

.bmi-nutrition-carousel::-webkit-scrollbar {
  height: 10px;
}

.bmi-nutrition-carousel::-webkit-scrollbar-track {
  background: rgba(148, 163, 184, 0.22);
  border-radius: 999px;
}

.bmi-nutrition-carousel::-webkit-scrollbar-thumb {
  background: linear-gradient(90deg, #2563eb, #22c55e);
  border-radius: 999px;
}

.bmi-nutrition-slide {
  flex: 0 0 min(760px, 86vw);
  max-width: 760px;
  margin: 0;
  scroll-snap-align: center;
  border-radius: 20px;
  overflow: hidden;
  background: #ffffff;
  border: 1px solid rgba(148, 163, 184, 0.28);
  box-shadow:
    0 18px 42px rgba(12, 32, 67, 0.18),
    0 8px 18px rgba(15, 92, 190, 0.10);
}

.bmi-nutrition-slide img {
  display: block;
  width: 100%;
  height: auto;
  user-select: none;
  -webkit-user-drag: none;
}

.footer-guide-group {
  display: grid;
  gap: 8px;
  justify-items: center;
}

.footer-guide-group > span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.footer-guide-group nav {
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  font-size: 0.82rem;
}

.limitation-strip {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 24px;
  padding: 24px 34px;
  background: var(--surface-soft);
}

.balance-icon {
  position: relative;
  width: 70px;
  height: 70px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #dbeafe;
  color: var(--primary);
}

.balance-icon::before {
  content: "";
  position: absolute;
  width: 38px;
  height: 30px;
  border-top: 3px solid var(--primary);
  border-bottom: 3px solid var(--primary);
}

.balance-icon::after {
  content: "";
  position: absolute;
  width: 3px;
  height: 42px;
  background: var(--primary);
}

.limitation-strip p {
  margin: 8px 0 0;
}

.faq-list {
  margin-top: 12px;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid #d5e1ed;
  border-radius: 12px;
  box-shadow: var(--shadow-soft);
}

details {
  border-bottom: 1px solid var(--border);
}

details:last-child {
  border-bottom: 0;
}

summary {
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 0 18px;
  color: var(--heading);
  font-weight: 800;
  cursor: pointer;
}

.summary-label {
  min-width: 0;
}

.summary-chevron {
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
  display: grid;
  place-items: center;
  color: var(--primary);
  transition: transform 0.18s ease;
}

.summary-chevron svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

details[open] .summary-chevron {
  transform: rotate(180deg);
}

details p {
  margin: 0;
  padding: 0 18px 16px;
  color: var(--muted);
}

.site-footer {
  margin-top: 26px;
  border-top: 1px solid #d5e1ed;
  background:
    linear-gradient(135deg, rgba(219, 234, 254, 0.95), rgba(255, 255, 255, 0.98), rgba(220, 252, 231, 0.9));
}

.footer-brand-icon {
  width: 40px;
  height: 40px;
  display: block;
  margin-bottom: 10px;
  object-fit: contain;
}

.footer-brand-note {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  max-width: 280px;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.5;
}

.footer-brand-note svg {
  flex: 0 0 15px;
  width: 15px;
  height: 15px;
  margin-top: 2px;
  color: var(--primary);
}

.footer-bottom-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 0 24px;
  border-top: 1px solid color-mix(in srgb, var(--border) 70%, transparent);
}

.footer-bottom-legal {
  color: var(--muted);
  font-size: 0.84rem;
}

.footer-bottom-legal span {
  color: var(--text);
  font-weight: 700;
}

.footer-bottom-legal p {
  margin: 4px 0 0;
  line-height: 1.5;
}

.footer-bottom-langs {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 0.86rem;
}

.footer-bottom-langs a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  min-height: 24px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
}

.footer-bottom-langs a.active,
.footer-bottom-langs a:hover,
.footer-bottom-langs a:focus-visible {
  color: var(--primary);
}

.footer-inner {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  color: var(--muted);
  font-size: 0.88rem;
}

.footer-inner strong {
  color: var(--heading);
  font-size: 1.05rem;
}

.footer-inner nav {
  gap: 24px;
  color: var(--heading);
}

.site-footer-grid,
.nutrition-footer-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr;
  gap: 28px;
  padding: 36px 0 30px;
}

.footer-brand strong,
.nutrition-footer-brand strong {
  display: block;
  margin-bottom: 8px;
  color: var(--heading);
  font-size: 1.08rem;
}

.footer-brand p,
.nutrition-footer-brand p {
  margin: 0;
  max-width: 280px;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.55;
}

.footer-col,
.nutrition-footer-col {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.footer-heading,
.nutrition-footer-heading {
  margin-bottom: 1px;
  color: var(--heading);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.footer-col a,
.nutrition-footer-col a {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.35;
  text-decoration: none;
}

.footer-col a:hover,
.footer-col a:focus-visible,
.nutrition-footer-col a:hover,
.nutrition-footer-col a:focus-visible {
  color: var(--primary);
}

.footer-col a.active,
.nutrition-footer-col a.active {
  color: var(--primary);
  font-weight: 700;
}

.footer-legal,
.nutrition-footer-legal {
  color: var(--muted);
  font-size: 0.84rem;
}

.footer-legal span,
.nutrition-footer-legal span {
  color: var(--text);
  font-weight: 700;
}

.footer-legal p,
.nutrition-footer-legal p {
  margin: 6px 0 0;
  line-height: 1.5;
}

[data-theme="dark"] .site-footer {
  border-color: var(--border);
  background: var(--surface);
}

.placeholder-main {
  min-height: calc(100vh - 151px);
  display: grid;
  place-items: center;
  padding: 56px 0;
  background:
    radial-gradient(circle at 8% 18%, #dff1ff 0 90px, transparent 92px),
    radial-gradient(circle at 94% 75%, #dff1ff 0 130px, transparent 132px),
    var(--bg);
}

.placeholder-card {
  width: min(100%, 720px);
  padding: 42px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow);
  text-align: center;
}

.placeholder-card h1 {
  margin: 0;
  color: var(--heading);
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1.05;
}

.placeholder-card p {
  margin: 14px auto 0;
  max-width: 540px;
  color: var(--muted);
}

.placeholder-card .primary-button {
  display: inline-flex;
  width: auto;
  align-items: center;
  justify-content: center;
  margin-top: 24px;
  padding: 0 22px;
}

[data-theme="dark"] .hero-bg-left,
[data-theme="dark"] .hero-bg-right {
  opacity: 0.25;
}

[data-theme="dark"] .language-switcher:hover {
  border-color: var(--border);
  box-shadow: var(--shadow-soft);
}

[data-theme="dark"] .example-pill,
[data-theme="dark"] .reset-button,
[data-theme="dark"] .info-note span,
[data-theme="dark"] .balance-icon {
  background: #203a5d;
}

[data-theme="dark"] .unit-selector input:checked + span {
  background: var(--surface);
}

[data-theme="dark"] .calculator-shell,
[data-theme="dark"] .healthy-range-card,
[data-theme="dark"] .ideal-weight-card,
[data-theme="dark"] .learn-card,
[data-theme="dark"] .important-section,
[data-theme="dark"] .info-card,
[data-theme="dark"] .faq-list {
  border-color: var(--border);
}

[data-theme="dark"] .target-icon,
[data-theme="dark"] .important-note.adult-note span {
  background-color: #143d31;
}

[data-theme="dark"] .range-icon {
  background: #143d31;
  color: #6ee7b7;
}

[data-theme="dark"] .reference-icon {
  background: #17365d;
  color: #93c5fd;
}

[data-theme="dark"] .range-result,
[data-theme="dark"] .guidance-result {
  background: var(--surface-soft);
  border-color: var(--border);
}

[data-theme="dark"] .learn-info-strip,
[data-theme="dark"] .learn-limitations-card,
[data-theme="dark"] .guide-context,
[data-theme="dark"] .movement-ladder,
[data-theme="dark"] .sleep-cycle,
[data-theme="dark"] .habit-loop {
  background: var(--surface-soft);
  border-color: var(--border);
}

[data-theme="dark"] .guide-hero-icon,
[data-theme="dark"] .info-tile,
[data-theme="dark"] .tip-card,
[data-theme="dark"] .nutrition-infographic-card,
[data-theme="dark"] .routine-card,
[data-theme="dark"] .loop-card,
[data-theme="dark"] .secondary-button {
  background: var(--surface);
  border-color: var(--border);
}

[data-theme="dark"] .bmi-infographic-section {
  background: linear-gradient(135deg, rgba(20, 36, 58, 0.96), rgba(24, 48, 78, 0.88));
  border: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
}

[data-theme="dark"] .bmi-infographic,
[data-theme="dark"] .nutrition-infographic-card img,
[data-theme="dark"] .move-infographic-card img,
[data-theme="dark"] .sleep-infographic-card img,
[data-theme="dark"] .habits-infographic-card img {
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
}

[data-theme="dark"] .pt-visual-summary article,
[data-theme="dark"] .pt-summary-card {
  background: linear-gradient(135deg, rgba(24, 48, 78, 0.94), rgba(20, 36, 58, 0.98));
  border-color: var(--border);
}

[data-theme="dark"] .pt-visual-summary article > span {
  background: rgba(147, 197, 253, 0.14);
  color: #93c5fd;
}

[data-theme="dark"] .pt-visual-summary-note,
[data-theme="dark"] .pt-summary-note {
  background: var(--surface-soft);
  border-color: rgba(147, 197, 253, 0.32);
  border-left-color: rgba(147, 197, 253, 0.68);
}

[data-theme="dark"] .bmi-nutrition-carousel-wrap {
  background:
    linear-gradient(135deg, rgba(15, 23, 42, 0.96) 0%, rgba(30, 41, 59, 0.98) 52%, rgba(20, 83, 45, 0.72) 100%);
  border-color: var(--border);
}

[data-theme="dark"] .bmi-nutrition-slide {
  background: var(--surface);
  border-color: var(--border);
}

[data-theme="dark"] .learn-disclaimer-strip {
  background: #102f28;
  border-color: #1d6b52;
}

[data-theme="dark"] .step-illustration.moon::before {
  box-shadow: 16px -5px 0 0 var(--surface);
}

[data-theme="dark"] .important-note,
[data-theme="dark"] .important-note.adult-note {
  background: var(--surface-soft);
  border-color: var(--border);
}

[data-theme="dark"] .important-note.adult-note {
  background: #102f28;
  border-color: #1d6b52;
}

[data-theme="dark"] .important-note,
[data-theme="dark"] .important-note.adult-note,
[data-theme="dark"] .info-note,
[data-theme="dark"] .learn-info-strip {
  border-color: rgba(248, 113, 113, 0.34);
  border-left-color: rgba(248, 113, 113, 0.72);
  background:
    linear-gradient(135deg, rgba(69, 10, 10, 0.9), rgba(76, 29, 29, 0.86), rgba(63, 18, 28, 0.9));
  color: #fee2e2;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.24);
}

[data-theme="dark"] .learn-disclaimer-strip,
[data-theme="dark"] .learn-limitations-card,
[data-theme="dark"] .guide-context,
[data-theme="dark"] .limitation-strip {
  border-color: rgba(248, 113, 113, 0.4);
  border-left-color: rgba(248, 113, 113, 0.66);
  background: var(--surface-soft);
  color: var(--text);
}

[data-theme="dark"] .important-note span,
[data-theme="dark"] .important-note.adult-note span,
[data-theme="dark"] .info-note span,
[data-theme="dark"] .learn-info-strip span {
  background: rgba(254, 202, 202, 0.16);
  color: #fecaca;
}

[data-theme="dark"] .important-note p,
[data-theme="dark"] .info-note p,
[data-theme="dark"] .learn-info-strip p {
  color: #fee2e2;
}

[data-theme="dark"] .illustration-card {
  background:
    radial-gradient(circle at 18% 24%, #214a72 0 10px, transparent 11px),
    radial-gradient(circle at 64% 16%, #214a72 0 6px, transparent 7px),
    radial-gradient(circle at 78% 42%, #1d3f62 0 70px, transparent 72px),
    var(--surface-soft);
}

@media (max-width: 1060px) {
  .header-inner {
    flex-wrap: nowrap;
    padding: 14px 0;
  }

  .main-nav {
    gap: 18px;
  }

  .main-nav a {
    padding: 5px 0 7px;
  }

  .hero-grid,
  .learn-hero-grid,
  .guide-hero-grid,
  .faq-hero-grid,
  .bmi-categories-hero-grid,
  .calculator-shell,
  .result-dashboard,
  .what-is-bmi {
    grid-template-columns: 1fr;
  }

  /* Stacked single-column layout: put the calculator right after the short
     intro so a mobile visitor reaches the tool within the first viewport,
     instead of scrolling past the trust badges first. */
  .hero-grid {
    grid-template-areas: "copy" "calc" "badges";
  }

  .hero-copy,
  .learn-hero-copy,
  .guide-hero-copy,
  .faq-hero-copy,
  .bmi-categories-hero-copy {
    text-align: center;
  }

  .hero-copy h1,
  .hero-copy > p,
  .learn-hero-copy h1,
  .learn-hero-copy > p,
  .faq-hero h1,
  .faq-hero-copy > p,
  .bmi-categories-hero h1,
  .bmi-categories-hero-copy > p,
  .learn-trust-line,
  .trust-badges {
    margin-inline: auto;
  }

  .learn-hero-button {
    margin-inline: auto;
  }

  .guide-hero-actions {
    justify-content: center;
  }

  .nutrition-feature-layout {
    grid-template-columns: 1fr;
  }

  .learn-topic-grid,
  .habit-steps,
  .factor-grid,
  .small-change-grid,
  .bmi-category-card-grid,
  .obesity-classes-panel,
  .infographic-grid,
  .tips-grid,
  .pt-visual-summary,
  .ladder-steps {
    grid-template-columns: repeat(2, 1fr);
  }

  .move-display-case,
  .sleep-display-case,
  .habits-display-case {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .move-display-feature,
  .sleep-display-feature,
  .habits-display-feature {
    grid-row: auto;
    grid-column: 1 / -1;
    padding: 28px 26px;
  }

  .step-card:not(:last-child)::after {
    display: none;
  }

  .calculator-card {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .calculator-banner {
    text-align: center;
  }

}

@media (min-width: 921px) and (max-width: 1200px) {
  /* Just above the mobile-menu breakpoint, the full-size desktop nav (32px
     gaps, 52px logo, default type scale) doesn't fit the five-item label
     set on one line for every language, so labels were wrapping to a
     second line and the header grew taller than its steady 72px. This
     band tightens header spacing, the logo, and nav type size together so
     the longest (PT/ES) label set stays on one line without wrapping,
     clipping, or overlapping the theme toggle / language switcher. */
  .header-inner {
    gap: 8px;
    padding: 0;
  }

  .brand {
    font-size: 1.05rem;
    gap: 8px;
  }

  .brand-icon {
    width: 40px;
    height: 40px;
    flex-basis: 40px;
  }

  .main-nav {
    gap: 14px;
    font-size: 0.85rem;
  }

  .main-nav a {
    padding: 25px 0 21px;
    white-space: nowrap;
  }

  .header-actions {
    gap: 6px;
  }

  .language-switcher {
    padding: 0 8px;
    gap: 5px;
  }
}

@media (max-width: 920px) {
  /* Raised from 860px: the full inline nav must fit the longest label set
     across all three languages (Spanish/Portuguese labels run longer than
     English), otherwise header-actions can be pushed a few pixels past the
     viewport edge in the 861-920px range on those locales. Collapsing to
     the mobile menu earlier removes the collision for every language. */
  .header-inner {
    position: relative;
    min-height: 62px;
    justify-content: space-between;
    gap: 10px;
  }

  .brand {
    font-size: 1.1rem;
  }

  .brand-icon {
    width: 44px;
    height: 44px;
    flex-basis: 44px;
  }

  .mobile-nav-toggle {
    display: inline-flex;
    order: 2;
  }

  .theme-toggle {
    width: 46px;
    min-width: 46px;
    height: 40px;
  }

  .theme-toggle svg {
    width: 24px;
    height: 24px;
  }

  .header-actions {
    width: auto;
    justify-content: flex-end;
    order: 3;
  }

  .main-nav {
    position: absolute;
    top: calc(100% - 4px);
    left: 0;
    right: 0;
    z-index: 6;
    order: 4;
    width: 100%;
    display: none;
    grid-template-columns: 1fr;
    gap: 0;
    padding: 8px;
    border: 1px solid var(--border);
    border-radius: 14px;
    background: var(--surface);
    box-shadow: var(--shadow);
    font-size: 0.9rem;
  }

  .main-nav.is-open {
    display: grid;
  }

  .main-nav a {
    min-height: 42px;
    display: flex;
    align-items: center;
    padding: 0 12px;
    border: 0;
    border-radius: 10px;
  }

  .main-nav a.active,
  .main-nav a:hover,
  .main-nav a:focus-visible {
    background: var(--surface-soft);
    border-bottom-color: transparent;
  }
}

@media (max-width: 720px) {
  .container {
    width: min(100% - 24px, var(--max-width));
  }

  .hero-section {
    padding-top: 28px;
  }

  .learn-hero {
    padding: 42px 0 30px;
  }

  .learn-hero-copy h1 {
    font-size: clamp(2.35rem, 13vw, 3.35rem);
  }

  .learn-hero-copy > p {
    font-size: 1rem;
  }

  .trust-badges,
  .learn-topic-grid,
  .habit-steps,
  .factor-grid,
  .small-change-grid,
  .bmi-category-card-grid,
  .obesity-classes-panel,
  .infographic-grid,
  .tips-grid,
  .ladder-steps,
  .pt-visual-summary,
  .routine-cards,
  .loop-steps,
  .limitation-strip,
  .dashboard-card-heading,
  .guide-overview,
  .guide-context,
  .faq-context-callout,
  .move-display-case,
  .sleep-display-case,
  .habits-display-case,
  .move-safety-grid,
  .learn-limitations-card,
  .important-note {
    grid-template-columns: 1fr;
  }

  .sleep-display-feature,
  .habits-display-feature {
    grid-column: auto;
  }

  .guide-hero {
    padding: 34px 0 24px;
  }

  .faq-hero {
    padding: 34px 0 24px;
  }

  .guide-hero-icon {
    width: min(100%, 210px);
  }

  .faq-hero-visual {
    width: min(100%, 220px);
  }

  .nutrition-hero-visual {
    width: min(100%, 260px);
  }

  .move-hero-visual,
  .sleep-hero-visual,
  .habits-hero-visual {
    width: min(100%, 300px);
  }

  .guide-hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .guide-hero-actions .primary-button,
  .guide-hero-actions .secondary-button {
    width: 100%;
  }

  .nutrition-infographic-card {
    padding: 8px;
  }

  .move-infographic-card,
  .sleep-infographic-card,
  .habits-infographic-card {
    padding: 8px;
  }

  .topic-card,
  .factor-card {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .topic-card h3,
  .topic-card p,
  .topic-card a {
    grid-column: 1;
  }

  .learn-icon,
  .mini-icon,
  .limitations-icon {
    margin-inline: auto;
  }

  .learn-info-strip,
  .learn-disclaimer-strip,
  .guide-overview,
  .guide-context,
  .faq-context-callout,
  .bmi-range-note,
  .bmi-context-panel {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .learn-info-strip span,
  .learn-disclaimer-strip img,
  .guide-overview img,
  .guide-context img,
  .faq-context-callout img,
  .bmi-range-note span,
  .bmi-context-panel img {
    margin-inline: auto;
  }

  .trust-badge {
    justify-items: center;
    text-align: center;
  }

  .calculator-card,
  .result-card,
  .what-is-bmi,
  .placeholder-card {
    padding: 24px;
  }

  .unit-selector {
    width: 100%;
  }

  .unit-selector span {
    width: 100%;
    min-width: 0;
  }

  .imperial-height-inputs {
    grid-template-columns: 1fr;
  }

  .bmi-categories-hero {
    padding: 34px 0 24px;
  }

  .bmi-categories-hero-grid {
    gap: 24px;
  }

  .bmi-categories-hero-visual {
    width: min(100%, 430px);
    margin-inline: auto;
  }

  .bmi-range-panel,
  .obesity-classes-panel,
  .bmi-context-panel {
    padding: 22px;
  }

  .category-scale-track {
    min-height: 18px;
  }

  .category-scale-labels,
  .obesity-class-grid,
  .next-step-grid {
    grid-template-columns: 1fr;
  }

  .category-scale-thresholds {
    font-size: 0.78rem;
  }

  .category-scale-thresholds span:first-child {
    display: none;
  }

  .category-scale-caption {
    text-align: center;
  }

  .bmi-context-panel li {
    padding-left: 0;
  }

  .bmi-context-panel li::before {
    display: none;
  }

  .healthy-range-card,
  .ideal-weight-card {
    text-align: center;
  }

  .target-icon,
  .guidance-icon,
  .balance-icon {
    margin-inline: auto;
  }

  .range-result,
  .guidance-result {
    text-align: center;
  }

  .important-note {
    text-align: center;
  }

  .important-note span {
    margin-inline: auto;
  }

  .footer-inner {
    padding: 24px 0;
    flex-direction: column;
    text-align: center;
  }

  .footer-inner nav {
    flex-wrap: wrap;
    justify-content: center;
  }

  .site-footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 32px 0 28px;
  }

  .footer-brand p {
    margin-inline: auto;
  }

  .footer-col {
    align-items: center;
  }
}

@media (max-width: 768px) {
  .bmi-nutrition-carousel-wrap {
    padding: 18px;
    border-radius: 18px;
  }

  .bmi-nutrition-slide {
    flex-basis: 90vw;
  }
}

@media (max-width: 520px) {
  .header-inner {
    flex-wrap: wrap;
    row-gap: 8px;
  }

  .brand {
    flex: 1 1 auto;
    min-width: 0;
  }

  .brand span {
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .mobile-nav-toggle {
    order: 2;
  }

  .header-actions {
    width: 100%;
    order: 3;
    justify-content: center;
  }

  .main-nav {
    top: calc(100% - 2px);
  }
}

@media (max-width: 520px) {
  .bmi-nutrition-carousel-wrap {
    padding: 14px;
  }

  .bmi-nutrition-slide {
    flex-basis: 90vw;
    border-radius: 16px;
  }
}

/* ==========================================================================
   EDITORIAL / TRUST BLOCK (Phase 4) — new, self-contained classes.
   Uses theme variables so it adapts to dark mode automatically.
   ========================================================================== */
.editorial-note {
  margin-top: 30px;
  padding: 22px 26px;
  border: 1px solid var(--border);
  border-left: 4px solid var(--primary);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.editorial-note h2 {
  margin: 0 0 10px;
  color: var(--heading);
  font-size: 1.15rem;
  line-height: 1.25;
}

.editorial-note > p {
  margin: 0 0 12px;
  color: var(--text);
  font-size: 0.95rem;
  line-height: 1.6;
}

.editorial-note .references-heading {
  margin: 0 0 6px;
  color: var(--heading);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.editorial-note .page-references {
  margin: 0 0 12px;
  padding-left: 18px;
}

.editorial-note .page-references li {
  margin: 4px 0;
  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.5;
}

.editorial-note .page-references a {
  color: var(--primary);
  font-weight: 600;
  text-decoration: none;
}

.editorial-note .page-references a:hover {
  text-decoration: underline;
}

.editorial-note .last-reviewed {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
}

.formula-block {
  margin: 20px 0 0;
  padding: 18px 20px;
  border: 1px solid #d5e1ed;
  border-radius: 14px;
  background: var(--surface-soft);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--heading);
  overflow-x: auto;
}

.formula-block strong {
  color: var(--primary);
}

[data-theme="dark"] .formula-block {
  border-color: var(--border);
  background: var(--surface-soft);
}

/* BMI limitations guide — hero hierarchy and card refinement (EN/PT/ES) */
#limitations-main .bmi-categories-hero h1 {
  display: flex;
  flex-direction: column;
  gap: 8px;
  line-height: 1.05;
}

#limitations-main .limitations-hero-title {
  font-size: clamp(2.5rem, 5.4vw, 4.1rem);
  line-height: 1;
  color: var(--heading);
}

#limitations-main .limitations-hero-subtitle {
  font-size: clamp(1.15rem, 2.3vw, 1.6rem);
  font-weight: 600;
  line-height: 1.3;
  color: var(--text);
}

@media (min-width: 1061px) {
  #limitations-main section[aria-labelledby="compare-title"] .bmi-category-card-grid,
  #limitations-main section[aria-labelledby="life-stages-title"] .bmi-category-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

#limitations-main .bmi-category-card-grid .learn-card.small-card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: stretch;
  text-align: left;
  padding: 24px 26px;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 18px;
  background: var(--surface-soft);
  box-shadow: var(--shadow-soft);
}

#limitations-main .bmi-category-card-grid .learn-card.small-card h3 {
  margin: 0 0 10px;
  font-size: 1.12rem;
  text-align: left;
}

#limitations-main .bmi-category-card-grid .learn-card.small-card p {
  margin: 0;
  text-align: left;
}

#limitations-main .bmi-category-card-grid .learn-card.small-card ul {
  margin: 0;
  padding-left: 20px;
  text-align: left;
}

#limitations-main .bmi-category-card-grid .learn-card.small-card li {
  margin: 0 0 8px;
  color: var(--text);
}

#limitations-main .bmi-category-card-grid .learn-card.small-card li:last-child {
  margin-bottom: 0;
}

@media (max-width: 720px) {
  #limitations-main .limitations-hero-subtitle {
    font-size: clamp(1.05rem, 4.6vw, 1.35rem);
  }
}

/* BMI vs body fat percentage guide — hero hierarchy and card refinement (EN/PT/ES) */
#body-fat-comparison-main .bmi-categories-hero h1 {
  display: flex;
  flex-direction: column;
  gap: 8px;
  line-height: 1.05;
}

#body-fat-comparison-main .bodyfat-hero-title {
  font-size: clamp(2.3rem, 4.8vw, 3.7rem);
  line-height: 1;
  color: var(--heading);
}

#body-fat-comparison-main .bodyfat-hero-subtitle {
  font-size: clamp(1.1rem, 2.2vw, 1.55rem);
  font-weight: 600;
  line-height: 1.3;
  color: var(--text);
}

@media (min-width: 1061px) {
  #body-fat-comparison-main section[aria-labelledby="compare-title"] .bmi-category-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #body-fat-comparison-main section[aria-labelledby="methods-title"] .bmi-category-card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

#body-fat-comparison-main .bmi-category-card-grid .learn-card.small-card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: stretch;
  text-align: left;
  padding: 24px 26px;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 18px;
  background: var(--surface-soft);
  box-shadow: var(--shadow-soft);
}

#body-fat-comparison-main .bmi-category-card-grid .learn-card.small-card h3 {
  margin: 0 0 10px;
  font-size: 1.12rem;
  text-align: left;
}

#body-fat-comparison-main .bmi-category-card-grid .learn-card.small-card p {
  margin: 0;
  text-align: left;
}

#body-fat-comparison-main .bmi-category-card-grid .learn-card.small-card ul {
  margin: 0;
  padding-left: 20px;
  text-align: left;
}

#body-fat-comparison-main .bmi-category-card-grid .learn-card.small-card li {
  margin: 0 0 8px;
  color: var(--text);
}

#body-fat-comparison-main .bmi-category-card-grid .learn-card.small-card li:last-child {
  margin-bottom: 0;
}

@media (max-width: 720px) {
  #body-fat-comparison-main .bodyfat-hero-subtitle {
    font-size: clamp(1.02rem, 4.4vw, 1.3rem);
  }
}

/* Healthy recipes guide — hero, quicknav and recipe cards (EN/PT/ES) */
#healthy-recipes-main .bmi-categories-hero-grid {
  grid-template-columns: 1fr;
}

#healthy-recipes-main .bmi-categories-hero-copy {
  max-width: 760px;
}

#healthy-recipes-main .bmi-categories-hero h1 {
  display: flex;
  flex-direction: column;
  gap: 8px;
  line-height: 1.05;
  max-width: none;
}

#healthy-recipes-main .recipes-hero-title {
  font-size: clamp(2.3rem, 4.8vw, 3.7rem);
  line-height: 1;
  color: var(--heading);
}

#healthy-recipes-main .recipes-hero-subtitle {
  font-size: clamp(1.1rem, 2.2vw, 1.55rem);
  font-weight: 600;
  line-height: 1.3;
  color: var(--text);
}

#healthy-recipes-main .recipes-quicknav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 24px auto 0;
  padding-bottom: 4px;
}

#healthy-recipes-main .recipes-quicknav a {
  padding: 8px 18px;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 999px;
  background: var(--surface-soft);
  color: var(--primary);
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
}

#healthy-recipes-main .recipe-section-icon {
  display: inline-block;
  vertical-align: -6px;
  margin-right: 10px;
  color: var(--primary);
}

/* Shared recipe-card grid + image card (scoped to the healthy-recipes hub, recipe-detail and recipe-category wrappers only) */
#healthy-recipes-main .recipe-grid,
#recipe-detail-main .recipe-grid,
#recipe-category-main .recipe-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-top: 20px;
}

@media (min-width: 641px) {
  #healthy-recipes-main .recipe-grid,
  #recipe-detail-main .recipe-grid,
  #recipe-category-main .recipe-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1100px) {
  #healthy-recipes-main .recipe-grid,
  #recipe-detail-main .recipe-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

#healthy-recipes-main .recipe-card,
#recipe-detail-main .recipe-card,
#recipe-category-main .recipe-card {
  display: flex;
  flex-direction: column;
  text-align: left;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 18px;
  background: var(--surface-soft);
  box-shadow: var(--shadow-soft);
}

#healthy-recipes-main .recipe-card-media,
#recipe-detail-main .recipe-card-media,
#recipe-category-main .recipe-card-media {
  display: block;
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--surface);
}

#healthy-recipes-main .recipe-card-media img,
#recipe-detail-main .recipe-card-media img,
#recipe-category-main .recipe-card-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

#healthy-recipes-main .recipe-card-media:hover img,
#healthy-recipes-main .recipe-card-media:focus-visible img,
#recipe-detail-main .recipe-card-media:hover img,
#recipe-detail-main .recipe-card-media:focus-visible img,
#recipe-category-main .recipe-card-media:hover img,
#recipe-category-main .recipe-card-media:focus-visible img {
  filter: brightness(1.04);
}

#healthy-recipes-main .recipe-card-media:focus-visible,
#recipe-detail-main .recipe-card-media:focus-visible,
#recipe-category-main .recipe-card-media:focus-visible {
  outline: 3px solid var(--primary);
  outline-offset: -3px;
}

#healthy-recipes-main .recipe-card:has(.recipe-card-media:hover),
#healthy-recipes-main .recipe-card:has(.recipe-card-media:focus-visible),
#recipe-detail-main .recipe-card:has(.recipe-card-media:hover),
#recipe-detail-main .recipe-card:has(.recipe-card-media:focus-visible),
#recipe-category-main .recipe-card:has(.recipe-card-media:hover),
#recipe-category-main .recipe-card:has(.recipe-card-media:focus-visible) {
  border-color: var(--primary);
  box-shadow: var(--shadow);
}

#healthy-recipes-main .recipe-card-body,
#recipe-detail-main .recipe-card-body,
#recipe-category-main .recipe-card-body {
  padding: 20px 22px 22px;
}

#healthy-recipes-main .recipe-card h3,
#recipe-detail-main .recipe-card h3,
#recipe-category-main .recipe-card h3 {
  margin: 10px 0 8px;
  font-size: 1.12rem;
  line-height: 1.3;
}

#healthy-recipes-main .recipe-card h3 a,
#recipe-detail-main .recipe-card h3 a,
#recipe-category-main .recipe-card h3 a {
  color: var(--heading);
  text-decoration: none;
}

#healthy-recipes-main .recipe-card h3 a:hover,
#healthy-recipes-main .recipe-card h3 a:focus-visible,
#recipe-detail-main .recipe-card h3 a:hover,
#recipe-detail-main .recipe-card h3 a:focus-visible,
#recipe-category-main .recipe-card h3 a:hover,
#recipe-category-main .recipe-card h3 a:focus-visible {
  text-decoration: underline;
}

#healthy-recipes-main .recipe-card-desc,
#recipe-detail-main .recipe-card-desc,
#recipe-category-main .recipe-card-desc {
  margin: 0 0 10px;
  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.45;
}

#healthy-recipes-main .recipe-meta,
#recipe-detail-main .recipe-meta,
#recipe-category-main .recipe-meta {
  margin: 0;
  color: var(--text);
  font-size: 0.85rem;
  opacity: 0.85;
}

#healthy-recipes-main .recipe-badge,
#recipe-detail-main .recipe-badge,
#recipe-category-main .recipe-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #fff;
  width: fit-content;
}

#healthy-recipes-main .badge-breakfast,
#recipe-detail-main .badge-breakfast,
#recipe-category-main .badge-breakfast {
  background: #d97706;
}

#healthy-recipes-main .badge-lunch,
#recipe-detail-main .badge-lunch,
#recipe-category-main .badge-lunch {
  background: #16a34a;
}

#healthy-recipes-main .badge-dinner,
#recipe-detail-main .badge-dinner,
#recipe-category-main .badge-dinner {
  background: #7c3aed;
}

#healthy-recipes-main .badge-tea,
#recipe-detail-main .badge-tea,
#recipe-category-main .badge-tea {
  background: #0d9488;
}

#healthy-recipes-main .badge-dessert,
#recipe-detail-main .badge-dessert,
#recipe-category-main .badge-dessert {
  background: #db2777;
}

#healthy-recipes-main .badge-smoothie,
#recipe-detail-main .badge-smoothie,
#recipe-category-main .badge-smoothie {
  background: #0891b2;
}

#healthy-recipes-main .recipe-note,
#recipe-detail-main .recipe-note {
  margin: 14px 0 0;
  padding-top: 12px;
  border-top: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.5;
}

#healthy-recipes-main .recipes-detox-callout {
  margin-top: 24px;
  padding: 24px 26px;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 18px;
  background: var(--surface-soft);
  box-shadow: var(--shadow-soft);
}

#healthy-recipes-main .recipes-detox-callout h3 {
  margin: 0 0 10px;
  color: var(--heading);
}

#healthy-recipes-main .recipes-detox-callout p {
  margin: 0;
  color: var(--text);
}

@media (max-width: 720px) {
  #healthy-recipes-main .recipes-hero-subtitle {
    font-size: clamp(1.02rem, 4.4vw, 1.3rem);
  }
}

/* Individual recipe detail pages */
#recipe-detail-main {
  display: block;
  padding: 40px 0 8px;
}

#recipe-detail-main .recipe-detail-shell {
  max-width: 980px;
}

#recipe-detail-main .recipe-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  color: var(--text);
  font-size: 0.88rem;
}

#recipe-detail-main .recipe-breadcrumb a {
  color: var(--primary);
  text-decoration: none;
}

#recipe-detail-main .recipe-breadcrumb a:hover,
#recipe-detail-main .recipe-breadcrumb a:focus-visible {
  text-decoration: underline;
}

#recipe-detail-main .recipe-breadcrumb span[aria-hidden] {
  opacity: 0.5;
}

#recipe-detail-main .recipe-breadcrumb span[aria-current] {
  color: var(--heading);
  font-weight: 600;
}

#recipe-detail-main h1 {
  margin: 14px 0 10px;
  color: var(--heading);
  font-size: clamp(1.9rem, 3.6vw, 2.6rem);
  line-height: 1.15;
}

#recipe-detail-main .recipe-detail-summary {
  margin: 0 0 24px;
  max-width: 70ch;
  color: var(--text);
  font-size: 1.08rem;
  line-height: 1.55;
}

#recipe-detail-main .recipe-detail-hero {
  margin: 0 0 22px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

#recipe-detail-main .recipe-detail-hero img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: center;
}

#recipe-detail-main .recipe-info-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 28px;
  margin: 0 0 28px;
  padding: 16px 20px;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 14px;
  background: var(--surface-soft);
  list-style: none;
}

#recipe-detail-main .recipe-info-row li {
  color: var(--text);
  font-size: 0.95rem;
}

#recipe-detail-main .recipe-info-row strong {
  color: var(--heading);
}

#recipe-detail-main .recipe-detail-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
  margin-bottom: 36px;
}

@media (min-width: 861px) {
  #recipe-detail-main .recipe-detail-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr);
    align-items: start;
  }
}

#recipe-detail-main .recipe-ingredients-panel,
#recipe-detail-main .recipe-steps-panel {
  padding: 24px 26px;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 18px;
  background: var(--surface-soft);
  box-shadow: var(--shadow-soft);
}

#recipe-detail-main .recipe-ingredients-panel h2,
#recipe-detail-main .recipe-steps-panel h2 {
  margin: 0 0 14px;
  color: var(--heading);
  font-size: 1.2rem;
}

#recipe-detail-main .recipe-ingredients-panel ul {
  margin: 0;
  padding-left: 20px;
  color: var(--text);
}

#recipe-detail-main .recipe-ingredients-panel li {
  margin: 0 0 10px;
  line-height: 1.4;
}

#recipe-detail-main .recipe-steps-panel ol {
  margin: 0;
  padding-left: 22px;
  color: var(--text);
}

#recipe-detail-main .recipe-steps-panel li {
  margin: 0 0 12px;
  line-height: 1.5;
}

#recipe-detail-main .recipe-related {
  margin: 8px 0 32px;
}

#recipe-detail-main .recipe-related h2 {
  margin: 0 0 4px;
  color: var(--heading);
}

#recipe-detail-main .recipe-grid-related {
  margin-top: 16px;
}

#recipe-detail-main .recipe-back-link {
  margin: 0 0 32px;
}

#recipe-detail-main .recipe-back-link a {
  color: var(--primary);
  font-weight: 700;
  text-decoration: none;
}

#recipe-detail-main .recipe-back-link a:hover,
#recipe-detail-main .recipe-back-link a:focus-visible {
  text-decoration: underline;
}

#recipe-detail-main .recipe-trust-note {
  margin-bottom: 40px;
}

#recipe-detail-main .recipe-category-link {
  margin: 0 0 28px;
}

#recipe-detail-main .recipe-category-link a {
  color: var(--primary);
  font-weight: 700;
  text-decoration: none;
}

#recipe-detail-main .recipe-category-link a:hover,
#recipe-detail-main .recipe-category-link a:focus-visible {
  text-decoration: underline;
}

/* "See more X recipes" action links on the hub pages (below each 3-card category group) */
#healthy-recipes-main .recipe-see-more {
  margin: 22px 0 0;
  text-align: center;
}

#healthy-recipes-main .recipe-see-more-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 20px;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 999px;
  background: var(--surface-soft);
  color: var(--primary);
  font-weight: 700;
  font-size: 0.9rem;
  text-decoration: none;
}

#healthy-recipes-main .recipe-see-more-btn:hover,
#healthy-recipes-main .recipe-see-more-btn:focus-visible {
  border-color: var(--primary);
  background: color-mix(in srgb, var(--primary) 10%, var(--surface-soft));
}

#healthy-recipes-main .recipe-see-more-arrow {
  transition: transform 0.15s ease;
}

#healthy-recipes-main .recipe-see-more-btn:hover .recipe-see-more-arrow,
#healthy-recipes-main .recipe-see-more-btn:focus-visible .recipe-see-more-arrow {
  transform: translateX(2px);
}

/* Simplified hub hero: short lead paragraph beneath the H1 */
#healthy-recipes-main .recipe-hub-hero-lead {
  margin: 14px 0 0;
  max-width: 640px;
  color: var(--text);
  font-size: 1.05rem;
  line-height: 1.55;
}

/* Category quicknav chips: restrained inline icons + clear hover/focus/active feedback */
#healthy-recipes-main .recipes-quicknav a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

#healthy-recipes-main .quicknav-icon {
  flex-shrink: 0;
  color: var(--primary);
}

#healthy-recipes-main .recipes-quicknav a:hover,
#healthy-recipes-main .recipes-quicknav a:focus-visible {
  border-color: var(--primary);
  background: color-mix(in srgb, var(--primary) 10%, var(--surface-soft));
}

#healthy-recipes-main .recipes-quicknav a:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* "Useful information about these recipes" — 3 large info cards with collapsible details */
#healthy-recipes-main .recipe-info-section {
  margin-top: 48px;
}

#healthy-recipes-main .recipe-info-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
  margin-top: 20px;
}

@media (min-width: 641px) {
  #healthy-recipes-main .recipe-info-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1000px) {
  #healthy-recipes-main .recipe-info-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

#healthy-recipes-main .recipe-info-card {
  padding: 26px 24px;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 20px;
  background: var(--surface-soft);
  box-shadow: var(--shadow-soft);
}

#healthy-recipes-main .recipe-info-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: 14px;
  border-radius: 14px;
  background: color-mix(in srgb, var(--primary) 14%, transparent);
  color: var(--primary);
}

#healthy-recipes-main .recipe-info-card h3 {
  margin: 0 0 8px;
  color: var(--heading);
  font-size: 1.08rem;
}

#healthy-recipes-main .recipe-info-card > p {
  margin: 0 0 14px;
  color: var(--text);
  font-size: 0.94rem;
  line-height: 1.5;
}

#healthy-recipes-main .recipe-info-card details {
  padding-top: 12px;
  border-top: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
}

#healthy-recipes-main .recipe-info-card details[open] {
  padding-bottom: 2px;
}

#healthy-recipes-main .recipe-info-card summary {
  cursor: pointer;
  color: var(--primary);
  font-weight: 700;
  font-size: 0.9rem;
  list-style: none;
}

#healthy-recipes-main .recipe-info-card summary::-webkit-details-marker {
  display: none;
}

#healthy-recipes-main .recipe-info-card summary::after {
  content: "▾";
  display: inline-block;
  margin-left: 6px;
  transition: transform 0.15s ease;
}

#healthy-recipes-main .recipe-info-card details[open] summary::after {
  transform: rotate(-180deg);
}

#healthy-recipes-main .recipe-info-card summary:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

#healthy-recipes-main .recipe-info-card details p,
#healthy-recipes-main .recipe-info-card details ul {
  margin: 12px 0 0;
  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.55;
}

#healthy-recipes-main .recipe-info-card details ul {
  padding-left: 20px;
}

#healthy-recipes-main .recipe-info-card details li {
  margin: 0 0 6px;
}

/* "What to consider next" — balanced 4-card clickable display case */
#healthy-recipes-main .recipe-next-steps-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  margin-top: 20px;
}

@media (min-width: 641px) {
  #healthy-recipes-main .recipe-next-steps-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1100px) {
  #healthy-recipes-main .recipe-next-steps-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

#healthy-recipes-main .recipe-next-step-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 22px 20px;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 18px;
  background: var(--surface-soft);
  box-shadow: var(--shadow-soft);
  color: inherit;
  text-decoration: none;
}

#healthy-recipes-main .recipe-next-step-card:hover,
#healthy-recipes-main .recipe-next-step-card:focus-visible {
  border-color: var(--primary);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

#healthy-recipes-main .recipe-next-step-card:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

#healthy-recipes-main .recipe-next-step-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--primary) 14%, transparent);
  color: var(--primary);
}

#healthy-recipes-main .recipe-next-step-body {
  flex: 1;
}

#healthy-recipes-main .recipe-next-step-body h3 {
  margin: 0 0 6px;
  color: var(--heading);
  font-size: 1rem;
}

#healthy-recipes-main .recipe-next-step-body p {
  margin: 0;
  color: var(--text);
  font-size: 0.88rem;
  line-height: 1.45;
}

#healthy-recipes-main .recipe-next-step-arrow {
  align-self: flex-end;
  color: var(--primary);
  transition: transform 0.15s ease;
}

#healthy-recipes-main .recipe-next-step-card:hover .recipe-next-step-arrow,
#healthy-recipes-main .recipe-next-step-card:focus-visible .recipe-next-step-arrow {
  transform: translateX(3px);
}

/* "Common questions about these recipes" — native details/summary accordion */
#healthy-recipes-main .recipe-faq-accordion {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 780px;
  margin-top: 20px;
}

#healthy-recipes-main .recipe-faq-item {
  padding: 18px 22px;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 16px;
  background: var(--surface-soft);
}

#healthy-recipes-main .recipe-faq-item summary {
  cursor: pointer;
  padding-right: 28px;
  position: relative;
  color: var(--heading);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.4;
  list-style: none;
}

#healthy-recipes-main .recipe-faq-item summary::-webkit-details-marker {
  display: none;
}

#healthy-recipes-main .recipe-faq-item summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 0;
  color: var(--primary);
  font-size: 1.2rem;
  font-weight: 700;
}

#healthy-recipes-main .recipe-faq-item[open] summary::after {
  content: "\2212";
}

#healthy-recipes-main .recipe-faq-item summary:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

#healthy-recipes-main .recipe-faq-item p {
  margin: 12px 0 0;
  color: var(--text);
  font-size: 0.94rem;
  line-height: 1.55;
}

/* ------------------------------------------------------------------ */
/* Recipe category archive pages (sidebar + 2-column grid)             */
/* ------------------------------------------------------------------ */
#recipe-category-main {
  display: block;
  padding: 40px 0 8px;
}

#recipe-category-main .recipe-category-shell {
  max-width: 1180px;
}

#recipe-category-main .recipe-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  color: var(--text);
  font-size: 0.88rem;
}

#recipe-category-main .recipe-breadcrumb a {
  color: var(--primary);
  text-decoration: none;
}

#recipe-category-main .recipe-breadcrumb a:hover,
#recipe-category-main .recipe-breadcrumb a:focus-visible {
  text-decoration: underline;
}

#recipe-category-main .recipe-breadcrumb span[aria-hidden] {
  opacity: 0.5;
}

#recipe-category-main .recipe-breadcrumb span[aria-current] {
  color: var(--heading);
  font-weight: 600;
}

#recipe-category-main h1 {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 14px 0 24px;
  line-height: 1.05;
  max-width: none;
}

#recipe-category-main .category-hero-title {
  font-size: clamp(2.1rem, 4.4vw, 3.2rem);
  line-height: 1;
  color: var(--heading);
}

#recipe-category-main .category-hero-subtitle {
  font-size: clamp(1.05rem, 2vw, 1.4rem);
  font-weight: 600;
  line-height: 1.3;
  color: var(--text);
}

/* Mobile <details> recipe menu — visible below ~1000px, above the card grid */
#recipe-category-main .category-mobile-menu {
  display: block;
  margin: 0 0 24px;
  padding: 16px 20px;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 14px;
  background: var(--surface-soft);
}

#recipe-category-main .category-mobile-menu summary {
  cursor: pointer;
  color: var(--heading);
  font-weight: 700;
  font-size: 1rem;
}

#recipe-category-main .category-mobile-menu-body {
  margin-top: 16px;
}

@media (min-width: 1000px) {
  #recipe-category-main .category-mobile-menu {
    display: none;
  }
}

/* Desktop sidebar + main content split */
#recipe-category-main .category-layout {
  display: block;
}

#recipe-category-main .category-sidebar {
  display: none;
}

@media (min-width: 1000px) {
  #recipe-category-main .category-layout {
    display: grid;
    grid-template-columns: minmax(250px, 290px) minmax(0, 1fr);
    gap: 36px;
    align-items: start;
  }

  #recipe-category-main .category-sidebar {
    display: block;
    position: sticky;
    top: 96px;
    max-height: calc(100vh - 116px);
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
    padding: 22px;
    border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
    border-radius: 18px;
    background: var(--surface-soft);
    box-shadow: var(--shadow-soft);
    scrollbar-width: thin;
    scrollbar-color: color-mix(in srgb, var(--border) 60%, var(--heading) 40%) transparent;
  }

  #recipe-category-main .category-sidebar::-webkit-scrollbar {
    width: 8px;
  }

  #recipe-category-main .category-sidebar::-webkit-scrollbar-track {
    background: transparent;
  }

  #recipe-category-main .category-sidebar::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: color-mix(in srgb, var(--border) 60%, var(--heading) 40%);
  }
}

#recipe-category-main .category-switcher {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 0 0 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
}

#recipe-category-main .category-switcher-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  color: var(--text);
  font-weight: 600;
  font-size: 0.94rem;
  text-decoration: none;
}

#recipe-category-main .category-switcher-icon {
  flex-shrink: 0;
  color: var(--muted);
}

#recipe-category-main .category-switcher-link:hover,
#recipe-category-main .category-switcher-link:focus-visible {
  background: var(--surface);
  text-decoration: underline;
}

#recipe-category-main .category-switcher-link:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 1px;
}

#recipe-category-main .category-switcher-link.is-active {
  background: color-mix(in srgb, var(--primary) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--primary) 35%, transparent);
  color: var(--primary);
  font-weight: 700;
}

#recipe-category-main .category-switcher-link.is-active .category-switcher-icon {
  color: var(--primary);
}

#recipe-category-main .category-sidebar-heading {
  margin: 0 0 10px;
  color: var(--heading);
  font-size: 1rem;
}

#recipe-category-main .category-recipe-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}

#recipe-category-main .category-recipe-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 10px;
  border-radius: 10px;
  color: var(--text);
  font-size: 0.92rem;
  line-height: 1.4;
  text-decoration: none;
}

#recipe-category-main .category-recipe-list a::after {
  content: "\2192";
  flex-shrink: 0;
  color: var(--primary);
  opacity: 0;
  transform: translateX(-3px);
  transition: opacity 0.15s ease, transform 0.15s ease;
}

#recipe-category-main .category-recipe-list a:hover,
#recipe-category-main .category-recipe-list a:focus-visible {
  background: var(--surface);
  color: var(--primary);
  text-decoration: underline;
}

#recipe-category-main .category-recipe-list a:hover::after,
#recipe-category-main .category-recipe-list a:focus-visible::after {
  opacity: 1;
  transform: translateX(0);
}

#recipe-category-main .category-recipe-list a:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 1px;
}

#recipe-category-main .category-sidebar > p {
  margin: 0 0 14px;
  color: var(--text);
  font-size: 0.88rem;
  line-height: 1.5;
}

#recipe-category-main .category-back-link a {
  color: var(--primary);
  font-weight: 700;
  font-size: 0.88rem;
  text-decoration: none;
}

#recipe-category-main .category-back-link a:hover,
#recipe-category-main .category-back-link a:focus-visible {
  text-decoration: underline;
}

/* 2-column recipe grid beside the sidebar (never 3 columns, even on wide screens) */
#recipe-category-main .recipe-grid-category {
  margin-top: 0;
}

/* Tea/infusion evidence + FAQ block (tea category archives only) */
#recipe-category-main .tea-evidence {
  margin: 32px 0 8px;
  padding: 24px 26px;
  border: 1px solid color-mix(in srgb, var(--border) 85%, var(--heading) 15%);
  border-radius: 18px;
  background: var(--surface-soft);
  box-shadow: var(--shadow-soft);
}

#recipe-category-main .tea-evidence h2 {
  margin: 0 0 12px;
  color: var(--heading);
  font-size: 1.2rem;
}

#recipe-category-main .tea-evidence > p {
  margin: 0 0 16px;
  color: var(--text);
  line-height: 1.55;
}

#recipe-category-main .tea-evidence .references-heading {
  margin: 0 0 8px;
  color: var(--heading);
  font-weight: 700;
  font-size: 0.92rem;
}

#recipe-category-main .tea-evidence-refs {
  margin: 0 0 20px;
  padding-left: 20px;
  color: var(--text);
}

#recipe-category-main .tea-evidence-refs li {
  margin: 0 0 8px;
  line-height: 1.4;
}

#recipe-category-main .tea-evidence-refs a {
  color: var(--primary);
}

#recipe-category-main .tea-evidence h3 {
  margin: 20px 0 12px;
  color: var(--heading);
  font-size: 1.05rem;
}

#recipe-category-main .tea-faq-item {
  margin: 0 0 16px;
}

#recipe-category-main .tea-faq-q {
  margin: 0 0 4px;
  color: var(--heading);
}

#recipe-category-main .tea-faq-item p {
  margin: 0 0 4px;
  color: var(--text);
  line-height: 1.5;
}
