/* ══════════════════════════════════════════════════════════════════════
   NUTRIFELL — AAA × Apple · Dark Glassmorphism · 2035
   Display: Space Grotesk · Body: Inter · Data: JetBrains Mono
   ══════════════════════════════════════════════════════════════════════ */

/* ── 0. BASE RESET ────────────────────────────────────────────────────── */
/* The HTML `hidden` attribute must always win. Several component classes set
   `display:` (e.g. .celebrate uses display:grid, .btn-primary uses
   inline-flex), which would otherwise override the UA `[hidden]{display:none}`
   rule and leave a hidden element rendered — including full-screen overlays
   that silently swallow every click. This guarantees `hidden` means hidden. */
[hidden] { display: none !important; }

/* ── 1. DESIGN TOKENS ─────────────────────────────────────────────────── */
:root {
  --bg-primary:    #080c14;
  --bg-secondary:  #0d1117;
  --bg-card:       rgba(255,255,255,0.03);
  --bg-card-hover: rgba(255,255,255,0.06);

  --border-subtle: rgba(255,255,255,0.06);
  --border-mid:    rgba(255,255,255,0.12);
  --border-active: rgba(34,197,94,0.5);

  --green:       #22c55e;
  --green-glow:  rgba(34,197,94,0.15);
  --green-dim:   rgba(34,197,94,0.10);
  --gold:        #f59e0b;
  --gold-dim:    rgba(245,158,11,0.10);
  --red:         #ef4444;
  --amber:       #f59e0b;
  --blue:        #38bdf8;
  --purple:      #a78bfa;

  --text-1: #f8fafc;
  --text-2: #94a3b8;
  --text-3: #475569;

  --font-display: 'Space Grotesk', -apple-system, sans-serif;
  --font-body:    'Inter', -apple-system, sans-serif;
  --font-mono:    'JetBrains Mono', 'Courier New', monospace;

  --r-sm: 6px;  --r-md: 12px;  --r-lg: 16px;  --r-xl: 22px;  --r-pill: 999px;

  --t:        all 0.25s cubic-bezier(0.4,0,0.2,1);
  --t-fast:   all 0.15s cubic-bezier(0.4,0,0.2,1);
  --t-spring: all 0.5s cubic-bezier(0.34,1.56,0.64,1);
}

/* ── 2. RESET ─────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
button { font: inherit; border: none; cursor: pointer; background: none; }
ul { list-style: none; }
a { text-decoration: none; color: inherit; }
img, canvas { display: block; max-width: 100%; }

::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--bg-primary); }
::-webkit-scrollbar-thumb { background: rgba(34,197,94,0.2); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(34,197,94,0.4); }

::selection { background: rgba(34,197,94,0.3); color: var(--text-1); }

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-1);
  background-color: var(--bg-primary);
  min-height: 100dvh;
  overflow-x: hidden;
}

/* ── 3. CUSTOM CURSOR ─────────────────────────────────────────────────── */
.cursor-dot {
  position: fixed;
  top: 0; left: 0;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 12px rgba(34,197,94,0.7);
  pointer-events: none;
  z-index: 99999;
  opacity: 0;
  transition: width 0.2s ease, height 0.2s ease, opacity 0.3s ease, background 0.2s ease;
  mix-blend-mode: screen;
}
.cursor-dot.grow {
  width: 36px; height: 36px;
  background: rgba(34,197,94,0.18);
  box-shadow: 0 0 24px rgba(34,197,94,0.35);
}
@media (hover: none), (pointer: coarse) {
  .cursor-dot { display: none; }
}

/* ── 4. NAVBAR ────────────────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(8,12,20,0.55);
  backdrop-filter: blur(22px) saturate(160%);
  -webkit-backdrop-filter: blur(22px) saturate(160%);
  border-bottom: 1px solid var(--border-subtle);
  transition: var(--t);
}
.navbar.scrolled {
  background: rgba(8,12,20,0.88);
  border-bottom-color: rgba(34,197,94,0.12);
}
.navbar-inner {
  display: flex;
  align-items: center;
  gap: 28px;
  max-width: 1320px;
  margin: 0 auto;
  padding: 14px 32px;
}

.logo { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.logo-mark {
  width: 32px; height: 32px;
  background: linear-gradient(135deg, var(--green) 0%, #16a34a 100%);
  border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 0 16px rgba(34,197,94,0.4);
}
.logo-wordmark { display: flex; flex-direction: column; line-height: 1.1; }
.logo-name {
  font-family: var(--font-display);
  font-size: 13px; font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--text-1);
}
.logo-geo {
  font-family: var(--font-mono);
  font-size: 9px; font-weight: 400;
  letter-spacing: 0.30em;
  color: var(--green);
}

.navbar-nav { display: flex; gap: 6px; margin-left: auto; }
.nav-link {
  font-family: var(--font-display);
  font-size: 13px; font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--text-2);
  padding: 6px 14px;
  border-radius: var(--r-pill);
  transition: var(--t-fast);
}
.nav-link:hover { color: var(--text-1); background: rgba(255,255,255,0.06); }

.navbar-badges { display: flex; flex-shrink: 0; }
.nav-badge {
  display: flex; align-items: center; gap: 7px;
  font-family: var(--font-mono);
  font-size: 10px; letter-spacing: 0.14em;
  color: var(--green);
  padding: 5px 12px;
  border-radius: var(--r-pill);
  background: var(--green-dim);
  border: 1px solid rgba(34,197,94,0.25);
}
.nav-badge-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
  animation: pulse-glow 2s ease-in-out infinite;
}

/* ── 5. HERO ──────────────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 110px 24px 110px;
  overflow: hidden;
}

.hero-bg { position: absolute; inset: 0; pointer-events: none; }

/* Animated mesh gradient */
.mesh-gradient {
  position: absolute;
  inset: -20%;
  background:
    radial-gradient(38% 42% at 22% 28%, rgba(34,197,94,0.13) 0%, transparent 100%),
    radial-gradient(40% 44% at 78% 24%, rgba(56,189,248,0.09) 0%, transparent 100%),
    radial-gradient(46% 48% at 50% 86%, rgba(245,158,11,0.07) 0%, transparent 100%),
    radial-gradient(30% 34% at 84% 72%, rgba(167,139,250,0.07) 0%, transparent 100%);
  animation: mesh-drift 26s ease-in-out infinite alternate;
}
@keyframes mesh-drift {
  0%   { transform: translate(0%, 0%) rotate(0deg) scale(1); }
  50%  { transform: translate(-3%, 2%) rotate(2deg) scale(1.06); }
  100% { transform: translate(3%, -2%) rotate(-2deg) scale(1.03); }
}

.hero-grid-lines {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(34,197,94,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(34,197,94,0.03) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 65% at 50% 45%, black 0%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 70% 65% at 50% 45%, black 0%, transparent 100%);
}

/* Floating particles (populated by JS) */
.hero-particles { position: absolute; inset: 0; }
.hp {
  position: absolute;
  border-radius: 50%;
  background: var(--green);
  opacity: 0.25;
  animation: hp-float linear infinite;
}
@keyframes hp-float {
  0%   { transform: translateY(0); opacity: 0; }
  10%  { opacity: 0.3; }
  90%  { opacity: 0.3; }
  100% { transform: translateY(-110vh); opacity: 0; }
}

/* Hero content */
.hero-content {
  position: relative; z-index: 2;
  max-width: 860px;
  display: flex; flex-direction: column; align-items: center;
  gap: 28px;
}

.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.22em;
  color: var(--green);
  background: var(--green-dim);
  border: 1px solid rgba(34,197,94,0.25);
  padding: 7px 16px;
  border-radius: var(--r-pill);
  animation: fade-up 0.8s 0.2s ease backwards;
}
.eyebrow-pulse {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 10px var(--green);
  animation: pulse-glow 2s ease-in-out infinite;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(56px, 11vw, 132px);
  font-weight: 700;
  line-height: 0.95;
  letter-spacing: -0.03em;
  animation: fade-up 0.8s 0.4s ease backwards;
  user-select: none;
}
.title-outline {
  color: transparent;
  -webkit-text-stroke: 2px rgba(34,197,94,0.85);
  text-shadow: 0 0 50px rgba(34,197,94,0.18);
}
.title-filled {
  color: var(--text-1);
  background: linear-gradient(160deg, #ffffff 30%, #94a3b8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-sub {
  font-family: var(--font-body);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.7;
  color: var(--text-2);
  max-width: 540px;
  animation: fade-up 0.8s 0.6s ease backwards;
}

.hero-stats {
  display: flex; align-items: center;
  background: rgba(255,255,255,0.025);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-lg);
  backdrop-filter: blur(12px);
  animation: fade-up 0.8s 0.8s ease backwards;
}
.hero-stat {
  display: flex; flex-direction: column; align-items: center;
  padding: 18px 36px;
}
.hero-stat-num {
  font-family: var(--font-mono);
  font-size: 30px; font-weight: 700;
  color: var(--text-1);
  line-height: 1;
}
.hero-stat-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-top: 6px;
}
.hero-stat-sep { width: 1px; height: 44px; background: var(--border-subtle); }

.hero-cta {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display);
  font-size: 14px; font-weight: 600;
  letter-spacing: 0.12em;
  color: #051008;
  background: linear-gradient(135deg, var(--green) 0%, #16a34a 100%);
  padding: 16px 36px;
  border-radius: var(--r-pill);
  box-shadow: 0 0 36px rgba(34,197,94,0.35), 0 6px 20px rgba(34,197,94,0.25);
  transition: var(--t-spring);
  animation: fade-up 0.8s 1.0s ease backwards;
}
.hero-cta:hover {
  transform: translateY(-3px) scale(1.04);
  box-shadow: 0 0 56px rgba(34,197,94,0.5), 0 10px 28px rgba(34,197,94,0.35);
}
.hero-cta:active { transform: translateY(-1px) scale(1.01); }

/* Infinite ticker */
.ticker {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  border-top: 1px solid var(--border-subtle);
  background: rgba(8,12,20,0.5);
  backdrop-filter: blur(8px);
  overflow: hidden;
  padding: 14px 0;
  z-index: 2;
}
.ticker-track {
  display: flex;
  gap: 0;
  width: max-content;
  animation: ticker-scroll 48s linear infinite;
}
.ticker-item {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--text-3);
  white-space: nowrap;
  padding: 0 22px;
  display: flex; align-items: center; gap: 22px;
}
.ticker-item::after { content: '◆'; font-size: 7px; color: rgba(34,197,94,0.5); }
@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ── 6. GALLERY ───────────────────────────────────────────────────────── */
.gallery {
  padding: 96px 28px 120px;
  max-width: 1320px;
  margin: 0 auto;
}
.gallery-header { text-align: center; margin-bottom: 64px; }
.gallery-label {
  display: flex; align-items: center; justify-content: center; gap: 14px;
  margin-bottom: 16px;
}
.label-line {
  height: 1px; width: 56px;
  background: linear-gradient(90deg, transparent, rgba(34,197,94,0.5), transparent);
}
.label-text {
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.26em;
  color: var(--text-3);
}
.gallery-title {
  font-family: var(--font-display);
  font-size: clamp(36px, 5vw, 60px);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-1);
}
.gallery-title em {
  font-style: normal;
  background: linear-gradient(135deg, var(--green), #4ade80);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── 7. ASYMMETRIC BENTO GRID ─────────────────────────────────────────── */
.bento-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-flow: dense;
  gap: 16px;
}

.bento-loading {
  grid-column: 1 / -1;
  display: flex; flex-direction: column; align-items: center; gap: 18px;
  padding: 90px;
  color: var(--text-3);
  font-family: var(--font-mono);
  font-size: 12px; letter-spacing: 0.18em;
}
.loading-ring {
  width: 38px; height: 38px;
  border: 2px solid rgba(34,197,94,0.12);
  border-top-color: var(--green);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}

/* Cards */
.bento-item {
  --glow: rgba(34,197,94,0.12);
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-xl);
  padding: 24px;
  cursor: pointer;
  overflow: hidden;
  display: flex; flex-direction: column; gap: 10px;
  min-height: 220px;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 4px 24px rgba(0,0,0,0.45), inset 0 1px 0 rgba(255,255,255,0.05);
  transition: border-color 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
  animation: card-in 0.6s ease backwards;
  will-change: transform;
}
/* Asymmetric pattern: every 7th card spans 2 columns */
.bento-item:nth-child(7n+1) { grid-column: span 2; }

/* Stagger entrance */
.bento-item:nth-child(4n+1) { animation-delay: 0.05s; }
.bento-item:nth-child(4n+2) { animation-delay: 0.11s; }
.bento-item:nth-child(4n+3) { animation-delay: 0.17s; }
.bento-item:nth-child(4n+4) { animation-delay: 0.23s; }

/* Food-colored ambient glow on hover */
.bento-item::after {
  content: '';
  position: absolute;
  inset: -40%;
  background: radial-gradient(40% 40% at 50% 50%, var(--glow) 0%, transparent 70%);
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
}
.bento-item:hover::after { opacity: 1; }
.bento-item:hover {
  border-color: var(--border-mid);
  background: var(--bg-card-hover);
  box-shadow: 0 20px 52px rgba(0,0,0,0.6), 0 0 0 1px var(--border-active), 0 0 36px var(--glow);
}

.card-top {
  display: flex; align-items: center; justify-content: space-between;
}
.card-num {
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.14em;
  color: var(--text-3);
}
.card-badge {
  font-family: var(--font-mono);
  font-size: 9px; font-weight: 600;
  letter-spacing: 0.16em;
  padding: 3px 9px;
  border-radius: var(--r-pill);
  border: 1px solid;
}
.card-badge.fruit     { color: #f87171; border-color: rgba(248,113,113,0.35); background: rgba(248,113,113,0.07); }
.card-badge.protein   { color: #38bdf8; border-color: rgba(56,189,248,0.35);  background: rgba(56,189,248,0.07);  }
.card-badge.vegetable { color: #4ade80; border-color: rgba(74,222,128,0.35);  background: rgba(74,222,128,0.07);  }
.card-badge.nut       { color: #fbbf24; border-color: rgba(251,191,36,0.35);  background: rgba(251,191,36,0.07);  }
.card-badge.grain     { color: #d4c5a0; border-color: rgba(212,197,160,0.35); background: rgba(212,197,160,0.07); }
.card-badge.legume    { color: #34d399; border-color: rgba(52,211,153,0.35);  background: rgba(52,211,153,0.07);  }
.card-badge.treat     { color: #a78bfa; border-color: rgba(167,139,250,0.35); background: rgba(167,139,250,0.07); }

.card-emoji {
  font-size: 50px; line-height: 1;
  filter: drop-shadow(0 6px 14px rgba(0,0,0,0.45));
  transition: transform 0.3s cubic-bezier(0.34,1.56,0.64,1);
}
.bento-item:hover .card-emoji { transform: scale(1.14) translateY(-3px) rotate(-4deg); }

.card-name {
  font-family: var(--font-display);
  font-size: 19px; font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text-1);
  margin-top: auto;
}
.card-cal {
  font-family: var(--font-mono);
  font-size: 12px; font-weight: 600;
  color: var(--green);
}
.card-cal-unit {
  color: var(--text-3);
  font-weight: 400;
  letter-spacing: 0.04em;
}
.card-macros {
  display: flex; gap: 12px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--text-3);
  letter-spacing: 0.04em;
}
.card-macros b { color: var(--text-2); font-weight: 600; }

/* ── 8. DETAIL VIEW ───────────────────────────────────────────────────── */
.view-detail { min-height: 100dvh; padding-top: 61px; }

.detail-bar {
  display: flex; align-items: center; gap: 18px;
  padding: 13px 32px;
  border-bottom: 1px solid var(--border-subtle);
  background: rgba(8,12,20,0.6);
  backdrop-filter: blur(14px);
  position: sticky;
  top: 61px;
  z-index: 100;
}
.back-btn {
  display: flex; align-items: center; gap: 7px;
  padding: 8px 16px;
  border-radius: var(--r-pill);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-2);
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.12em;
  transition: var(--t-fast);
}
.back-btn:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-active);
  color: var(--green);
}
.back-icon { display: flex; align-items: center; }

.breadcrumb {
  display: flex; align-items: center; gap: 9px;
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.12em;
  color: var(--text-3);
}
.bc-sep { opacity: 0.4; }
.bc-current { color: var(--green); font-weight: 600; }

.detail-layout {
  display: grid;
  grid-template-columns: 55fr 45fr;
  gap: 26px;
  max-width: 1320px;
  margin: 0 auto;
  padding: 30px 32px 70px;
}

/* ── 9. 3D VIEWER ─────────────────────────────────────────────────────── */
.viewer-col { display: flex; flex-direction: column; gap: 20px; }

.canvas-card { border-radius: var(--r-xl); overflow: hidden; position: relative; }
.canvas-frame {
  position: relative;
  aspect-ratio: 1;
  background: #080c14;
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-xl);
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(34,197,94,0.06), 0 36px 90px rgba(0,0,0,0.65);
}
.canvas-frame canvas {
  width: 100% !important;
  height: 100% !important;
  position: relative;
  z-index: 1;
}

/* Holographic grid behind the model */
.holo-grid {
  position: absolute; inset: 0; z-index: 0;
  background-image:
    linear-gradient(rgba(34,197,94,0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(34,197,94,0.055) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: radial-gradient(ellipse 75% 75% at 50% 50%, black 0%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 75% 75% at 50% 50%, black 0%, transparent 100%);
}


/* ── 10. MACRO PILLS ──────────────────────────────────────────────────── */
.macro-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.macro-chip {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-lg);
  padding: 16px 18px;
  display: flex; flex-direction: column; gap: 9px;
  backdrop-filter: blur(12px);
  transition: var(--t-fast);
}
.macro-chip:hover { background: var(--bg-card-hover); border-color: var(--border-mid); }
.macro-chip.protein { box-shadow: inset 0 2px 0 var(--blue); }
.macro-chip.carbs   { box-shadow: inset 0 2px 0 var(--gold); }
.macro-chip.fat     { box-shadow: inset 0 2px 0 var(--purple); }

.macro-chip-value {
  font-family: var(--font-mono);
  font-size: 26px; font-weight: 700;
  color: var(--text-1);
  line-height: 1;
}
.macro-chip-unit {
  font-family: var(--font-mono);
  font-size: 12px; font-weight: 400;
  color: var(--text-3);
  margin-left: 2px;
}
.macro-chip-label {
  font-family: var(--font-mono);
  font-size: 9.5px; letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--text-3);
}
.macro-bar {
  height: 3px;
  background: rgba(255,255,255,0.06);
  border-radius: 2px;
  overflow: hidden;
}
.macro-bar-fill { height: 100%; border-radius: 2px; width: 0; transition: width 1.2s cubic-bezier(0.4,0,0.2,1); }
.macro-bar-fill.protein { background: var(--blue);   box-shadow: 0 0 8px rgba(56,189,248,0.5); }
.macro-bar-fill.carbs   { background: var(--gold);   box-shadow: 0 0 8px rgba(245,158,11,0.5); }
.macro-bar-fill.fat     { background: var(--purple); box-shadow: 0 0 8px rgba(167,139,250,0.5); }

/* ── 11. INFO PANEL ───────────────────────────────────────────────────── */
.info-col { min-width: 0; }
.info-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-xl);
  padding: 30px;
  backdrop-filter: blur(16px);
  box-shadow: 0 4px 36px rgba(0,0,0,0.45), inset 0 1px 0 rgba(255,255,255,0.04);
}

.food-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 18px;
  margin-bottom: 26px;
}
.food-tag {
  display: inline-flex; align-items: center; gap: 7px;
  font-family: var(--font-mono);
  font-size: 9.5px; letter-spacing: 0.22em;
  color: var(--green);
  background: var(--green-dim);
  border: 1px solid rgba(34,197,94,0.28);
  padding: 5px 11px;
  border-radius: var(--r-pill);
  margin-bottom: 10px;
}
.food-tag-dot {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
}
.food-name {
  font-family: var(--font-display);
  font-size: clamp(28px, 3vw, 38px);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-1);
  line-height: 1.05;
}
.food-serving {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.06em;
  color: var(--text-3);
  margin-top: 8px;
}

/* Appetizing specimen description — sits below the name, above the data.
   Italic, muted, and fades up just after the header for a staggered entrance. */
.food-description {
  margin: 18px 0 4px;
  font-style: italic;
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-2);
  max-width: 60ch;
  opacity: 0;
  animation: fade-up 0.6s cubic-bezier(0.22, 1, 0.36, 1) 0.12s forwards;
}
@media (prefers-reduced-motion: reduce) {
  .food-description { animation: none; opacity: 1; }
}

.calorie-box {
  display: flex; flex-direction: column; align-items: flex-end;
  flex-shrink: 0;
}
.calorie-num {
  font-family: var(--font-mono);
  font-size: clamp(56px, 6vw, 92px);
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 0.9;
  background: linear-gradient(160deg, var(--green) 20%, #86efac 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  filter: drop-shadow(0 0 24px rgba(34,197,94,0.25));
}
.calorie-label {
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.30em;
  color: var(--green);
  opacity: 0.65;
  margin-top: 6px;
}

/* Energy bar */
.energy-bar-wrap { margin-bottom: 22px; }
.energy-bar-header {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 9px;
}
.energy-bar-label, .energy-bar-max {
  font-family: var(--font-mono);
  font-size: 10px; letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-3);
}
.energy-bar-track {
  height: 6px;
  background: rgba(255,255,255,0.06);
  border-radius: 3px;
  overflow: hidden;
}
.energy-bar-fill {
  height: 100%; width: 0;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--green), #4ade80);
  box-shadow: 0 0 12px rgba(34,197,94,0.5);
  transition: width 1.2s cubic-bezier(0.4,0,0.2,1);
}

.panel-divider { height: 1px; background: var(--border-subtle); margin: 22px 0; }

.section-label-sm {
  font-family: var(--font-mono);
  font-size: 10px; font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 16px;
}
.section-label-sm .accent { color: var(--green); }

/* Nutrient grid */
.nutrient-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.nutrient-item {
  display: flex; flex-direction: column; gap: 6px;
  padding: 12px 14px;
  background: rgba(255,255,255,0.02);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-md);
  transition: var(--t-fast);
}
.nutrient-item:hover { background: rgba(255,255,255,0.04); border-color: rgba(34,197,94,0.2); }
.nutrient-label {
  font-family: var(--font-mono);
  font-size: 9.5px; letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-3);
}
.nutrient-value {
  font-family: var(--font-mono);
  font-size: 16px; font-weight: 700;
  color: var(--text-1);
  line-height: 1;
}
.nutrient-unit {
  font-family: var(--font-mono);
  font-size: 10px; font-weight: 400;
  color: var(--text-3);
  margin-left: 2px;
}
.nutrient-bar {
  height: 2px;
  background: rgba(255,255,255,0.06);
  border-radius: 1px;
  overflow: hidden;
}
.nutrient-bar-fill {
  height: 100%; width: 0;
  border-radius: 1px;
  background: var(--green);
  box-shadow: 0 0 6px rgba(34,197,94,0.6);
  transition: width 1s cubic-bezier(0.4,0,0.2,1);
}

/* Benefits / drawbacks */
.bl-list { display: flex; flex-direction: column; gap: 9px; }
.bl-item {
  display: flex; align-items: flex-start; gap: 12px;
  font-family: var(--font-body);
  font-size: 13.5px; line-height: 1.6;
  color: var(--text-2);
  padding: 10px 14px;
  border-radius: var(--r-md);
  background: rgba(255,255,255,0.015);
}
.bl-item.benefit  { border-left: 2px solid var(--green); }
.bl-item.drawback { border-left: 2px solid var(--amber); }
.bl-icon {
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 12px; font-weight: 700;
  margin-top: 2px;
}
.bl-icon.plus  { color: var(--green); }
.bl-icon.minus { color: var(--amber); }

/* ── 12. GALLERY CONTROLS (search + filter) ──────────────────────────── */
.gallery-controls {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 28px;
}
.gallery-search-wrap {
  position: relative;
  max-width: 420px;
}
.gallery-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-3);
  pointer-events: none;
}
.gallery-search {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-md);
  color: var(--text-1);
  font-family: var(--font-body);
  font-size: 13.5px;
  padding: 10px 14px 10px 38px;
  transition: var(--t);
}
.gallery-search::placeholder { color: var(--text-3); }
.gallery-search:focus {
  outline: none;
  border-color: var(--border-active);
  background: rgba(255,255,255,0.04);
}
.gallery-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.filter-btn {
  font-family: var(--font-mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-pill);
  padding: 6px 14px;
  cursor: pointer;
  transition: var(--t);
}
.filter-btn:hover {
  color: var(--text-1);
  border-color: var(--border-mid);
  background: rgba(255,255,255,0.06);
}
.filter-btn.active {
  color: var(--green);
  border-color: rgba(34,197,94,0.4);
  background: var(--green-dim);
}
.bento-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 20px;
  color: var(--text-3);
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.05em;
}

/* ── 13. PWA INSTALL BANNER ───────────────────────────────────────────── */
.install-banner {
  display: none;
  align-items: center;
  gap: 12px;
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(13,17,23,0.96);
  border: 1px solid var(--border-mid);
  border-radius: var(--r-xl);
  padding: 12px 16px;
  backdrop-filter: blur(20px);
  z-index: 9999;
  box-shadow: 0 8px 32px rgba(0,0,0,0.5), 0 0 0 1px rgba(34,197,94,0.1);
  max-width: calc(100vw - 32px);
  white-space: nowrap;
}
.install-banner.show { display: flex; }
.install-banner-text {
  font-family: var(--font-body);
  font-size: 13.5px;
  color: var(--text-2);
  flex: 1;
}
.install-btn {
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #080c14;
  background: var(--green);
  border-radius: var(--r-pill);
  padding: 7px 18px;
  transition: var(--t);
  flex-shrink: 0;
}
.install-btn:hover { background: #16a34a; }
.install-dismiss {
  font-size: 14px;
  color: var(--text-3);
  padding: 4px 6px;
  border-radius: var(--r-sm);
  transition: var(--t);
  flex-shrink: 0;
}
.install-dismiss:hover { color: var(--text-1); background: rgba(255,255,255,0.06); }

/* ── 14. LOG MACRO INPUTS ─────────────────────────────────────────────── */
.log-macros-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}
@media (max-width: 480px) {
  .log-macros-row { grid-template-columns: 1fr 1fr; }
}

/* ── 14. FOOTER ───────────────────────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border-subtle);
  background: linear-gradient(180deg, transparent, rgba(0,0,0,0.35));
  padding: 48px 24px 30px;
}
.footer-inner {
  display: flex; flex-direction: column; align-items: center; gap: 14px;
  text-align: center;
  max-width: 640px; margin: 0 auto;
}
.footer-brand { display: flex; align-items: baseline; gap: 9px; }
.footer-name {
  font-family: var(--font-display);
  font-size: 15px; font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--text-1);
}
.footer-geo {
  font-family: var(--font-mono);
  font-size: 10px; letter-spacing: 0.30em;
  color: var(--green);
}
.footer-note {
  font-family: var(--font-body);
  font-size: 12.5px;
  color: var(--text-3);
}
.footer-meta { display: flex; align-items: center; gap: 8px; }
.footer-tag {
  font-family: var(--font-mono);
  font-size: 9.5px; letter-spacing: 0.14em;
  color: var(--text-3);
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border-subtle);
  padding: 4px 11px;
  border-radius: var(--r-pill);
}
.footer-sep { color: var(--text-3); font-size: 10px; }
.footer-copy {
  font-family: var(--font-mono);
  font-size: 10px; letter-spacing: 0.10em;
  color: var(--text-3);
  opacity: 0.55;
}

/* ── 13. PAGE OVERLAY ─────────────────────────────────────────────────── */
.page-overlay {
  position: fixed; inset: 0;
  background: var(--bg-primary);
  z-index: 9999;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.page-overlay.active { opacity: 1; pointer-events: all; }

/* ── 14. KEYFRAMES ────────────────────────────────────────────────────── */
@keyframes fade-up {
  from { opacity: 0; transform: translateY(22px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes card-in {
  from { opacity: 0; transform: translateY(26px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes pulse-glow {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.45; }
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── 15. RESPONSIVE ───────────────────────────────────────────────────── */
@media (max-width: 1100px) {
  .detail-layout { grid-template-columns: 1fr; padding: 22px 22px 56px; }
  .canvas-frame { max-width: 480px; margin: 0 auto; }
  .bento-grid { grid-template-columns: repeat(3, 1fr); }
  .bento-item:nth-child(7n+1) { grid-column: span 2; }
}

@media (max-width: 768px) {
  .navbar-badges { display: none; }
  .navbar-inner { padding: 12px 20px; }

  .hero-title { font-size: clamp(48px, 14vw, 88px); }
  .hero-stats { flex-direction: column; width: 100%; max-width: 320px; }
  .hero-stat { flex-direction: row; justify-content: space-between; width: 100%; padding: 13px 24px; }
  .hero-stat-sep { width: 80%; height: 1px; }

  .bento-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .bento-item:nth-child(7n+1) { grid-column: span 2; }
  .gallery { padding: 56px 16px 70px; }

  .detail-bar { padding: 11px 18px; }
  .detail-layout { padding: 16px 16px 44px; }
  .macro-row { gap: 9px; }
  .macro-chip { padding: 13px; }
  .macro-chip-value { font-size: 20px; }
  .nutrient-grid { grid-template-columns: 1fr; }
  .info-panel { padding: 22px; }
}

@media (max-width: 480px) {
  .bento-grid { grid-template-columns: 1fr; }
  .bento-item:nth-child(7n+1) { grid-column: span 1; }
  .macro-row { grid-template-columns: 1fr; }
  .calorie-num { font-size: 52px; }
}

/* ── 17. MOBILE HAMBURGER + OVERLAY NAV ──────────────────────────────── */
.desktop-nav { display: flex; align-items: center; gap: 6px; }

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px; height: 44px;
  border-radius: var(--r-md);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-subtle);
  padding: 11px;
  flex-shrink: 0;
  transition: var(--t-fast);
}
.hamburger:hover { border-color: var(--border-mid); background: rgba(255,255,255,0.08); }
.hamburger span {
  display: block; height: 2px; border-radius: 1px;
  background: var(--text-2);
  transition: transform 0.3s ease, opacity 0.2s ease;
}
.hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-nav-overlay {
  position: fixed; inset: 0; z-index: 9100;
  background: rgba(0,0,0,0.65);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s ease;
}
.mobile-nav-overlay.open { opacity: 1; pointer-events: all; }

.mobile-nav-sheet {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  background: var(--bg-secondary);
  border: 1px solid var(--border-mid);
  border-bottom: none;
  border-radius: 24px 24px 0 0;
  padding: 0 20px max(24px, env(safe-area-inset-bottom));
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.34,1.15,0.64,1);
  box-shadow: 0 -20px 60px rgba(0,0,0,0.6);
}
.mobile-nav-overlay.open .mobile-nav-sheet { transform: translateY(0); }

.mobile-nav-handle {
  width: 36px; height: 4px; border-radius: 2px;
  background: rgba(255,255,255,0.14);
  margin: 14px auto 0;
}
.mobile-nav-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 0 16px;
}
.mobile-nav-brand {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-display);
  font-size: 16px; font-weight: 700; color: var(--text-1);
}
.mobile-nav-brand .logo-mark {
  background: linear-gradient(135deg, var(--green) 0%, #16a34a 100%);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.mobile-nav-close {
  width: 36px; height: 36px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-3);
  border: 1px solid var(--border-subtle);
  background: rgba(255,255,255,0.03);
  transition: var(--t-fast);
}
.mobile-nav-close:hover { color: var(--text-1); border-color: var(--border-mid); }

.mobile-nav-links { display: flex; flex-direction: column; gap: 3px; padding-bottom: 8px; }
.mobile-nav-item {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--font-body);
  font-size: 16px; font-weight: 500;
  color: var(--text-2);
  padding: 14px 16px;
  border-radius: var(--r-md);
  min-height: 52px;
  border: 1px solid transparent;
  transition: var(--t-fast);
  -webkit-tap-highlight-color: transparent;
}
.mobile-nav-item:active {
  color: var(--text-1);
  background: rgba(255,255,255,0.05);
  border-color: var(--border-subtle);
}
.mobile-nav-item.highlight {
  color: var(--green);
  background: var(--green-dim);
  border-color: rgba(34,197,94,0.25);
}
.mobile-nav-item.danger:active { color: #f87171; background: rgba(239,68,68,0.08); }
.mobile-nav-divider { height: 1px; background: var(--border-subtle); margin: 8px 0; }

@media (max-width: 768px) {
  .hamburger { display: flex; }
  .desktop-nav { display: none; }
  .logo-wordmark { display: none; }
  .navbar-badges { display: none; }
  .navbar-inner { padding: 10px 16px; gap: 0; justify-content: space-between; }
}

/* ── 18. PWA SMART INSTALL SHEETS ────────────────────────────────────── */
.pwa-sheet {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 8500;
  background: rgba(11,15,22,0.98);
  border-top: 1px solid var(--border-mid);
  border-radius: 24px 24px 0 0;
  padding: 0 20px max(24px, env(safe-area-inset-bottom));
  transform: translateY(110%);
  transition: transform 0.45s cubic-bezier(0.34,1.1,0.64,1);
  box-shadow: 0 -12px 48px rgba(0,0,0,0.55);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
}
.pwa-sheet.show { transform: translateY(0); }
.pwa-sheet::before {
  content: '';
  display: block;
  width: 36px; height: 4px; border-radius: 2px;
  background: rgba(255,255,255,0.14);
  margin: 14px auto 20px;
}
.pwa-sheet-inner {
  display: flex; align-items: center; gap: 16px;
  margin-bottom: 18px;
}
.pwa-sheet-icon img {
  width: 60px; height: 60px;
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.5), 0 0 0 1px rgba(34,197,94,0.25);
}
.pwa-sheet-title {
  font-family: var(--font-display);
  font-size: 18px; font-weight: 700;
  color: var(--text-1); margin-bottom: 4px;
}
.pwa-sheet-sub {
  font-family: var(--font-body);
  font-size: 13.5px; color: var(--text-2);
}
.pwa-sheet-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 18px;
}
.pwa-close {
  width: 32px; height: 32px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-3); font-size: 15px;
  border: 1px solid var(--border-subtle);
  background: rgba(255,255,255,0.03);
  transition: var(--t-fast);
}
.pwa-close:hover { color: var(--text-1); }
.pwa-install-btn {
  display: flex; align-items: center; justify-content: center;
  width: 100%; min-height: 54px;
  font-family: var(--font-display);
  font-size: 15px; font-weight: 600; letter-spacing: 0.04em;
  color: #051008;
  background: linear-gradient(135deg, var(--green), #16a34a);
  border-radius: var(--r-pill);
  box-shadow: 0 4px 22px rgba(34,197,94,0.4);
  transition: var(--t);
  -webkit-tap-highlight-color: transparent;
}
.pwa-install-btn:active { transform: scale(0.98); box-shadow: 0 2px 12px rgba(34,197,94,0.3); }
.pwa-dismiss {
  display: block; width: 100%; text-align: center;
  font-family: var(--font-body); font-size: 14px;
  color: var(--text-3); padding: 16px;
  transition: var(--t-fast);
  -webkit-tap-highlight-color: transparent;
}
.pwa-dismiss:active { color: var(--text-2); }

/* iOS steps */
.pwa-steps { display: flex; flex-direction: column; gap: 10px; margin-bottom: 18px; }
.pwa-step {
  display: flex; align-items: center; gap: 14px;
  padding: 13px 14px;
  background: rgba(255,255,255,0.025);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-md);
}
.pwa-step-icon {
  width: 40px; height: 40px; flex-shrink: 0;
  border-radius: var(--r-sm);
  background: rgba(34,197,94,0.1);
  border: 1px solid rgba(34,197,94,0.25);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px;
}
.pwa-step-text {
  font-family: var(--font-body); font-size: 14px;
  color: var(--text-2); line-height: 1.45;
}
.pwa-step-text b { color: var(--text-1); }

/* ── 19. ENHANCED MOBILE BREAKPOINTS ─────────────────────────────────── */
@media (max-width: 768px) {
  /* Hero */
  .hero { padding: 88px 20px 70px; }
  .hero-sub { font-size: 15px; max-width: 100%; }
  .hero-cta { padding: 14px 28px; font-size: 13px; width: 100%; justify-content: center; }

  /* Gallery search + filter */
  .gallery-controls { gap: 12px; }
  .gallery-search-wrap { max-width: 100%; }
  .gallery-filters { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; -webkit-overflow-scrolling: touch; }
  .gallery-filters::-webkit-scrollbar { height: 0; }

  /* Bento: 2 cols, disable nth-child span */
  .bento-item:nth-child(7n+1) { grid-column: span 1; }
  .bento-item { min-height: 180px; padding: 18px; }
  .card-emoji { font-size: 40px; }
  .card-name { font-size: 16px; }

  /* Detail view */
  .detail-layout { grid-template-columns: 1fr; }
  .food-header { flex-direction: column; gap: 10px; }
  .calorie-box { align-items: flex-start; flex-direction: row; gap: 16px; align-items: center; }

  /* 3D viewer: fixed height on mobile */
  .canvas-frame { aspect-ratio: unset; height: 300px; max-width: 100%; }
}

@media (max-width: 480px) {
  /* Single column gallery */
  .bento-grid { grid-template-columns: 1fr; }
  .bento-item { min-height: 150px; padding: 16px; }
  .card-emoji { font-size: 36px; }
  .card-name { font-size: 15px; }

  /* Hero */
  .hero-stats { display: none; }
  .hero-eyebrow { font-size: 10px; }

  /* Hide logo wordmark on tiny screens */
  .logo-name, .logo-geo { display: none; }

  /* Filter tabs single scroll */
  .filter-btn { white-space: nowrap; }

  /* Detail  */
  .info-panel { padding: 16px; }
  .macro-chip-value { font-size: 20px; }
  .nutrient-grid { grid-template-columns: 1fr; }
}

/* Touch device improvements */
@media (hover: none), (pointer: coarse) {
  .cursor-dot { display: none; }

  /* Suppress desktop-only hover effects */
  .bento-item:hover { border-color: var(--border-subtle); background: var(--bg-card); box-shadow: 0 4px 24px rgba(0,0,0,0.45), inset 0 1px 0 rgba(255,255,255,0.05); }
  .bento-item:hover::after { opacity: 0; }
  .bento-item:hover .card-emoji { transform: none; }
  .macro-chip:hover { background: var(--bg-card); border-color: var(--border-subtle); }

  /* Active tap feedback */
  .bento-item:active { transform: scale(0.98); background: var(--bg-card-hover); border-color: var(--border-mid); transition: transform 0.1s ease; }
  .filter-btn:active { color: var(--green); border-color: rgba(34,197,94,0.4); background: var(--green-dim); }
  .btn-primary:active { transform: scale(0.97) !important; }
  .back-btn:active { background: var(--bg-card-hover); border-color: var(--border-active); }

  /* Bigger touch targets */
  .filter-btn { min-height: 40px; padding: 8px 16px; }
  .back-btn { min-height: 44px; }
}

/* ── 16. REDUCED MOTION ───────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .ticker-track, .hp { animation: none !important; }
}

/* ── 20. NEW NAVBAR (v2) ──────────────────────────────────────────────── */
.nb-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding: 0 16px;
  position: relative;
}

.nb-logo {
  position: absolute;
  left: 50%; transform: translateX(-50%);
  font-family: var(--font-display);
  font-size: 16px; font-weight: 600;
  color: var(--text-1);
  white-space: nowrap;
  letter-spacing: 0.01em;
  text-decoration: none;
}
.nb-logo span { color: var(--green); }

.nb-hamburger {
  display: flex; flex-direction: column; justify-content: center;
  gap: 5px;
  width: 40px; height: 40px;
  border-radius: 10px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-subtle);
  padding: 10px;
  flex-shrink: 0;
  transition: var(--t-fast);
  z-index: 1;
}
.nb-hamburger:hover { background: rgba(255,255,255,0.08); border-color: var(--border-mid); }
.nb-hamburger span {
  display: block; width: 100%; height: 2px; border-radius: 1px;
  background: var(--text-2);
  transition: transform 0.3s ease, opacity 0.2s ease;
}
.nb-hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nb-hamburger.active span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nb-hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.nb-right { display: flex; align-items: center; gap: 8px; z-index: 1; }

.nb-avatar-btn {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--green); color: #fff;
  font-family: var(--font-display); font-size: 14px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  transition: var(--t-fast); flex-shrink: 0;
}
.nb-avatar-btn:hover { transform: scale(1.06); box-shadow: 0 0 0 2px rgba(34,197,94,0.3); }

.nb-login-link {
  font-family: var(--font-body); font-size: 14px; font-weight: 500;
  color: var(--text-2);
  padding: 7px 14px;
  border-radius: 8px;
  border: 1px solid var(--border-subtle);
  transition: var(--t-fast);
}
.nb-login-link:hover { color: var(--text-1); border-color: var(--border-mid); }

/* ── 21. SIDEBAR ──────────────────────────────────────────────────────── */
.nb-sidebar-overlay {
  position: fixed; inset: 0; z-index: 9200;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s ease;
}
.nb-sidebar-overlay.open { opacity: 1; pointer-events: all; }

.nb-sidebar {
  position: absolute; top: 0; left: 0; bottom: 0;
  width: 280px;
  background: #0d1117;
  border-right: 1px solid rgba(255,255,255,0.06);
  display: flex; flex-direction: column;
  transform: translateX(-100%);
  transition: transform 0.35s cubic-bezier(0.4,0,0.2,1);
  overflow-y: auto; overflow-x: hidden;
}
.nb-sidebar-overlay.open .nb-sidebar { transform: translateX(0); }

@media (max-width: 480px) { .nb-sidebar { width: 85vw; } }

.nb-sidebar-head { flex-shrink: 0; }

.nb-sidebar-user {
  padding: 32px 20px 24px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.nb-sidebar-avatar {
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--green); color: #fff;
  font-family: var(--font-display); font-size: 22px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 12px;
}
.nb-sidebar-name { font-family: var(--font-display); font-size: 17px; font-weight: 600; color: var(--text-1); }
.nb-sidebar-email { font-size: 13px; color: var(--text-3); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nb-sidebar-goal {
  display: inline-block; margin-top: 10px;
  font-size: 12px; font-weight: 600; color: var(--green);
  background: var(--green-dim); border: 1px solid rgba(34,197,94,0.25);
  border-radius: 20px; padding: 4px 10px;
}

.nb-sidebar-welcome {
  padding: 32px 20px 24px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  display: flex; flex-direction: column;
}
.nb-welcome-title { font-family: var(--font-display); font-size: 18px; font-weight: 600; color: var(--text-1); margin-bottom: 4px; }
.nb-welcome-sub { font-size: 13px; color: var(--text-3); margin-bottom: 16px; }
.nb-sidebar-cta { display: block; text-align: center; padding: 11px; font-size: 14px; border-radius: 10px; margin-bottom: 10px; }
.nb-register-link { text-align: center; font-size: 13px; color: var(--text-3); transition: var(--t-fast); }
.nb-register-link:hover { color: var(--green); }

.nb-sidebar-nav { flex: 1; padding: 12px 10px; display: flex; flex-direction: column; gap: 2px; }
.nb-nav-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 10px;
  font-size: 15px; font-weight: 500; color: var(--text-2);
  transition: var(--t-fast); cursor: pointer;
  -webkit-tap-highlight-color: transparent; text-decoration: none;
}
.nb-nav-item:hover { color: var(--text-1); background: rgba(255,255,255,0.05); }
.nb-nav-item.active { color: var(--green); background: var(--green-dim); }
.nb-nav-disabled { opacity: 0.4; cursor: default; pointer-events: none; }
.nb-soon {
  font-size: 10px; font-weight: 700; color: var(--text-3);
  background: rgba(255,255,255,0.06); border-radius: 4px;
  padding: 2px 5px; margin-left: auto; letter-spacing: 0.05em; text-transform: uppercase;
}

.nb-sidebar-foot {
  flex-shrink: 0; padding: 14px 16px max(20px, env(safe-area-inset-bottom));
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex; flex-direction: column; gap: 10px;
}
.nb-logout-btn {
  display: flex; align-items: center; gap: 8px;
  padding: 11px 14px; border-radius: 10px;
  font-size: 14px; font-weight: 500; color: #f87171;
  background: rgba(239,68,68,0.06); border: 1px solid rgba(239,68,68,0.12);
  width: 100%; transition: var(--t-fast);
}
.nb-logout-btn:hover { background: rgba(239,68,68,0.12); }
.nb-version { font-size: 11px; color: var(--text-3); text-align: center; font-family: var(--font-mono); letter-spacing: 0.05em; }

/* ── 22. FLOATING INSTALL POPUP ───────────────────────────────────────── */
.install-popup {
  position: fixed; top: -180px; right: 20px;
  width: 320px; z-index: 10000;
  background: rgba(13,17,23,0.97);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.07);
  border-left: 3px solid var(--green);
  border-radius: 16px; padding: 16px;
  box-shadow: 0 24px 64px rgba(0,0,0,0.7), 0 0 0 1px rgba(34,197,94,0.08);
  transition: top 0.5s cubic-bezier(0.34,1.2,0.64,1), opacity 0.3s ease;
  opacity: 0; pointer-events: none;
}
.install-popup.show { top: 72px; opacity: 1; pointer-events: all; }

@media (max-width: 480px) {
  .install-popup { left: 12px; right: 12px; width: auto; }
  .install-popup.show { top: 68px; }
}

.ip-header { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 10px; }
.ip-title-row { display: flex; align-items: center; gap: 10px; }
.ip-icon { font-size: 26px; line-height: 1; }
.ip-brand { font-family: var(--font-display); font-size: 15px; font-weight: 700; color: var(--text-1); }
.ip-brand span { color: var(--green); }
.ip-close {
  color: var(--text-3); font-size: 14px; padding: 4px 8px;
  border-radius: 6px; transition: var(--t-fast); flex-shrink: 0;
}
.ip-close:hover { color: var(--text-1); background: rgba(255,255,255,0.06); }
.ip-body { margin-bottom: 12px; }
.ip-headline { font-size: 13px; font-weight: 500; color: var(--text-2); margin-bottom: 4px; }
.ip-benefits { font-size: 12px; color: var(--text-3); }
.ip-ios-steps { flex-direction: column; gap: 8px; margin-bottom: 12px; }
.ip-step { display: flex; align-items: flex-start; gap: 10px; font-size: 13px; color: var(--text-2); line-height: 1.45; }
.ip-step-n {
  width: 20px; height: 20px; border-radius: 50%;
  background: var(--green); color: #000;
  font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.ip-actions { display: flex; flex-direction: column; gap: 6px; }
.ip-install-btn {
  background: var(--green); color: #000;
  font-weight: 700; font-size: 14px;
  padding: 10px; border-radius: 10px;
  transition: var(--t-fast); text-align: center; display: block; width: 100%;
}
.ip-install-btn:hover { filter: brightness(1.1); }
.ip-later { font-size: 13px; color: var(--text-3); text-align: center; padding: 4px; transition: var(--t-fast); display: block; width: 100%; }
.ip-later:hover { color: var(--text-2); }

/* ── 23. GLB LOAD SPINNER ─────────────────────────────────────────────── */
.glb-spinner {
  position: absolute; inset: 0; z-index: 50;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 14px; background: rgba(8,12,20,0.82); border-radius: inherit;
  backdrop-filter: blur(4px);
}
.glb-spinner-ring {
  width: 44px; height: 44px; border-radius: 50%;
  border: 3px solid rgba(34,197,94,0.18);
  border-top-color: var(--green);
  animation: glb-spin 0.9s linear infinite;
}
@keyframes glb-spin { to { transform: rotate(360deg); } }
.glb-spinner-label {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em;
  color: var(--text-3); text-transform: uppercase;
}

/* ── 24. HOME STRIPS · FOOD OF THE DAY + RECENTLY VIEWED ──────────────── */
.home-strips {
  max-width: 1320px;
  margin: 0 auto;
  padding: 8px 28px 0;
  display: grid;
  gap: 34px;
}
.strip-label {
  display: flex; align-items: center; gap: 14px;
  margin-bottom: 18px;
}
.strip-label.center { justify-content: center; }
.strip-label .label-line { width: 40px; }

/* Food of the Day */
.fotd-card {
  --glow: rgba(34,197,94,0.16);
  display: flex; align-items: center; gap: 24px;
  width: 100%; text-align: left;
  padding: 26px 30px;
  border-radius: var(--r-xl);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: var(--t);
  position: relative; overflow: hidden;
}
.fotd-card::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(120% 140% at 0% 0%, var(--glow), transparent 60%);
  opacity: 0; transition: opacity 0.35s ease; pointer-events: none;
}
.fotd-card:hover, .fotd-card:focus-visible {
  border-color: var(--border-active);
  transform: translateY(-3px);
  box-shadow: 0 18px 50px rgba(0,0,0,0.35);
}
.fotd-card:hover::before, .fotd-card:focus-visible::before { opacity: 1; }
.fotd-card:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }
.fotd-emoji {
  font-size: 64px; line-height: 1; flex-shrink: 0;
  filter: drop-shadow(0 6px 16px rgba(0,0,0,0.4));
}
.fotd-body { min-width: 0; }
.fotd-name {
  font-family: var(--font-display);
  font-size: clamp(22px, 3vw, 30px); font-weight: 700;
  letter-spacing: -0.01em; color: var(--text-1);
  margin-bottom: 6px;
}
.fotd-note {
  font-size: 14.5px; line-height: 1.6; color: var(--text-2);
  max-width: 62ch; margin-bottom: 14px;
}
.fotd-meta { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.fotd-cal {
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.1em;
  color: var(--text-3);
}
.fotd-cta {
  display: inline-flex; align-items: center; gap: 7px;
  font-family: var(--font-mono); font-size: 12px; font-weight: 600;
  letter-spacing: 0.06em; color: var(--green);
}
.fotd-cta svg { transition: transform 0.25s ease; }
.fotd-card:hover .fotd-cta svg { transform: translateX(4px); }

/* Recently viewed */
.recent-row {
  display: flex; gap: 12px; overflow-x: auto;
  padding-bottom: 6px; scroll-snap-type: x proximity;
  -ms-overflow-style: none; scrollbar-width: thin;
}
.recent-chip {
  --glow: rgba(34,197,94,0.16);
  display: flex; align-items: center; gap: 10px;
  flex-shrink: 0; scroll-snap-align: start;
  min-height: 48px; padding: 10px 16px;
  border-radius: var(--r-pill);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  transition: var(--t-fast);
}
.recent-chip:hover, .recent-chip:focus-visible {
  background: var(--bg-card-hover);
  border-color: var(--border-active);
  transform: translateY(-2px);
}
.recent-chip:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
.recent-emoji { font-size: 22px; line-height: 1; }
.recent-name { font-size: 13.5px; font-weight: 600; color: var(--text-1); white-space: nowrap; }
.recent-cal {
  font-family: var(--font-mono); font-size: 11px; color: var(--text-3);
  padding-left: 8px; border-left: 1px solid var(--border-mid);
}

/* ── 25. HOW IT WORKS ─────────────────────────────────────────────────── */
.howto {
  max-width: 1320px; margin: 0 auto;
  padding: 70px 28px 20px; text-align: center;
}
.section-title {
  font-family: var(--font-display);
  font-size: clamp(32px, 5vw, 56px);
  font-weight: 700; letter-spacing: -0.02em; color: var(--text-1);
  margin-bottom: 52px;
}
.section-title em {
  font-style: normal;
  background: linear-gradient(135deg, var(--green), #4ade80);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.howto-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
  text-align: left;
}
.howto-step {
  padding: 30px 26px;
  border-radius: var(--r-lg);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  transition: var(--t);
}
.howto-step:hover { border-color: var(--border-mid); background: var(--bg-card-hover); }
.howto-num {
  display: inline-block;
  font-family: var(--font-mono); font-size: 13px; font-weight: 700;
  color: var(--green); letter-spacing: 0.1em;
  padding-bottom: 14px; opacity: 0.9;
}
.howto-step-title {
  font-family: var(--font-display); font-size: 19px; font-weight: 600;
  color: var(--text-1); margin-bottom: 10px;
}
.howto-step-desc { font-size: 14.5px; line-height: 1.65; color: var(--text-2); }

/* ── 26. TRUST STRIP ──────────────────────────────────────────────────── */
.trust {
  max-width: 1320px; margin: 0 auto; padding: 44px 28px;
}
.trust-row {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px;
  background: var(--border-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-lg); overflow: hidden;
}
.trust-item {
  display: flex; flex-direction: column; gap: 7px;
  padding: 22px 22px;
  background: var(--bg-secondary);
}
.trust-key {
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  letter-spacing: 0.14em; color: var(--green);
}
.trust-val { font-size: 13.5px; line-height: 1.5; color: var(--text-2); }

/* ── 27. FAQ ──────────────────────────────────────────────────────────── */
.faq {
  max-width: 880px; margin: 0 auto;
  padding: 60px 28px 110px; text-align: center;
}
.faq-list { text-align: left; display: grid; gap: 12px; }
.faq-item {
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-md);
  background: var(--bg-card);
  overflow: hidden; transition: border-color 0.25s ease;
}
.faq-item.open { border-color: var(--border-active); }
.faq-q {
  width: 100%; min-height: 56px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 22px; text-align: left;
  font-family: var(--font-display); font-size: 16px; font-weight: 500;
  color: var(--text-1); transition: color 0.2s ease;
}
.faq-q:hover { color: var(--green); }
.faq-q:focus-visible { outline: 2px solid var(--green); outline-offset: -2px; }
.faq-chevron {
  width: 11px; height: 11px; flex-shrink: 0;
  border-right: 2px solid var(--text-3); border-bottom: 2px solid var(--text-3);
  transform: rotate(45deg); transition: transform 0.3s ease, border-color 0.2s ease;
  margin-top: -4px;
}
.faq-item.open .faq-chevron { transform: rotate(-135deg); margin-top: 3px; border-color: var(--green); }
.faq-a {
  max-height: 0; overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.4,0,0.2,1);
}
.faq-a p {
  padding: 0 22px 20px; font-size: 14.5px; line-height: 1.7; color: var(--text-2);
  max-width: 70ch;
}

/* ── 28. SCROLL REVEAL ────────────────────────────────────────────────── */
[data-reveal] {
  opacity: 0; transform: translateY(18px);
  transition: opacity 0.55s ease, transform 0.55s cubic-bezier(0.16,1,0.3,1);
}
[data-reveal].is-in { opacity: 1; transform: none; }
.howto-step[data-reveal]:nth-child(2) { transition-delay: 0.08s; }
.howto-step[data-reveal]:nth-child(3) { transition-delay: 0.16s; }
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1; transform: none; transition: none; }
  .fotd-card, .recent-chip, .howto-step { transition: none; }
}

/* ── 29. HOME SECTIONS · RESPONSIVE ───────────────────────────────────── */
@media (max-width: 860px) {
  .howto-grid { grid-template-columns: 1fr; }
  .trust-row { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .home-strips { padding: 8px 16px 0; gap: 26px; }
  .fotd-card { flex-direction: column; align-items: flex-start; gap: 16px; padding: 22px; }
  .fotd-emoji { font-size: 52px; }
  .howto { padding: 52px 16px 12px; }
  .howto-step { padding: 24px 20px; }
  .trust { padding: 32px 16px; }
  .trust-row { grid-template-columns: 1fr; }
  .faq { padding: 44px 16px 80px; }
}

/* ── 30. SHARED POLISH PRIMITIVES (used across all pages) ─────────────── */

/* Skeleton shimmer — replaces blunt "Loading…" text while data fetches */
.skeleton {
  position: relative; overflow: hidden;
  background: rgba(255,255,255,0.05);
  border-radius: var(--r-md);
}
.skeleton::after {
  content: ""; position: absolute; inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.07), transparent);
  animation: skeleton-sweep 1.3s ease-in-out infinite;
}
.skeleton-line { height: 14px; margin: 9px 0; }
.skeleton-line.sh { width: 60%; }
.skeleton-block { height: 64px; margin: 10px 0; }
@keyframes skeleton-sweep { 100% { transform: translateX(100%); } }
@media (prefers-reduced-motion: reduce) { .skeleton::after { animation: none; } }

/* Assurance microbar — compact, factual trust row for feature/app pages */
.assure-row {
  display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 22px;
  max-width: 1180px; margin: 0 auto 26px; padding: 0 20px;
}
.assure {
  display: inline-flex; align-items: center; gap: 7px;
  font-family: var(--font-mono); font-size: 11.5px; letter-spacing: 0.04em;
  color: var(--text-3);
}
.assure b { color: var(--text-2); font-weight: 600; }
.assure .dot {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--green); box-shadow: 0 0 8px rgba(34,197,94,0.6); flex-shrink: 0;
}

/* Empty-state CTA — gives empty states a way forward, not just a message */
.empty-cta {
  display: inline-flex; align-items: center; gap: 7px;
  margin-top: 16px; min-height: 42px; padding: 10px 20px;
  font-family: var(--font-display); font-weight: 600; font-size: 14px;
  color: #051008; background: linear-gradient(135deg, var(--green), #16a34a);
  border-radius: var(--r-pill); transition: var(--t-spring);
}
.empty-cta:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(34,197,94,0.32); }
.empty-cta:active { transform: scale(0.97); }
.empty-cta:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }
.empty-hint { display: block; margin-top: 6px; font-size: 12.5px; color: var(--text-3); }

/* ── 31. PROMO VIDEO SECTION ──────────────────────────────────────────── */
.promo { max-width: 1080px; margin: 0 auto; padding: 64px 28px 8px; text-align: center; }
.promo-frame {
  position: relative; border-radius: var(--r-xl); overflow: hidden;
  border: 1px solid var(--border-mid);
  box-shadow: 0 26px 80px rgba(0,0,0,0.55), 0 0 0 1px rgba(34,197,94,0.06);
  background: var(--bg-secondary);
}
.promo-video {
  display: block; width: 100%; aspect-ratio: 16 / 9;
  background: var(--bg-primary);
}
@media (max-width: 640px) {
  .promo { padding: 46px 16px 4px; }
}

/* ── 32. STREAK CHIP + BADGES ─────────────────────────────────────────── */
.nb-streak {
  display: flex; align-items: center; gap: 9px;
  margin: 2px 18px 12px; padding: 11px 14px;
  border-radius: var(--r-md);
  background: linear-gradient(135deg, rgba(245,158,11,0.13), rgba(34,197,94,0.08));
  border: 1px solid rgba(245,158,11,0.28);
}
.nb-streak-ico { font-size: 18px; line-height: 1; }
.nb-streak-n { font-family: var(--font-display); font-weight: 700; font-size: 14px; color: var(--text-1); }
.nb-streak-name {
  font-family: var(--font-mono); font-size: 9.5px; letter-spacing: 0.08em;
  text-transform: uppercase; color: var(--gold); margin-left: auto;
}

.streak-badges { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.sb-badge {
  text-align: center; padding: 16px 8px; border-radius: var(--r-md);
  border: 1px solid var(--border-subtle); background: rgba(255,255,255,0.02);
  transition: var(--t);
}
.sb-badge.on { border-color: rgba(245,158,11,0.4); background: rgba(245,158,11,0.07); }
.sb-badge.off { opacity: 0.38; filter: grayscale(1); }
.sb-ico { font-size: 28px; line-height: 1; }
.sb-name { font-family: var(--font-display); font-weight: 600; font-size: 12px; color: var(--text-1); margin-top: 7px; }
.sb-days { font-family: var(--font-mono); font-size: 10px; color: var(--text-3); margin-top: 2px; }
@media (max-width: 480px) { .streak-badges { grid-template-columns: repeat(2, 1fr); } }

/* ── 33. FOOD FACT CALLOUT + TRENDING RANK ────────────────────────────── */
.food-fact {
  display: flex; align-items: center; gap: 10px;
  margin: 16px 0 4px; padding: 13px 16px;
  border-radius: var(--r-md);
  background: rgba(245,158,11,0.07);
  border: 1px solid rgba(245,158,11,0.22);
  font-size: 13.5px; line-height: 1.5; color: var(--text-2);
}
.food-fact b { color: var(--text-1); }
.food-fact-ico { font-size: 18px; line-height: 1; flex-shrink: 0; }

.trend-rank {
  width: 20px; height: 20px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono); font-size: 11px; font-weight: 700;
  color: var(--gold); background: rgba(245,158,11,0.12);
  border: 1px solid rgba(245,158,11,0.3);
}

/* ── 34. TIP OF THE DAY BANNER ────────────────────────────────────────── */
.tip-banner {
  display: flex; align-items: center; gap: 12px;
  max-width: 1180px; margin: 0 auto 22px; padding: 14px 18px;
  border-radius: var(--r-lg);
  background: rgba(34,197,94,0.06); border: 1px solid rgba(34,197,94,0.22);
}
.tip-banner .tip-ico { font-size: 22px; line-height: 1; flex-shrink: 0; }
.tip-banner .tip-text { font-size: 14px; color: var(--text-2); line-height: 1.5; flex: 1; }
.tip-banner .tip-text b { color: var(--green); font-family: var(--font-display); font-weight: 600; }
.tip-banner .tip-close {
  color: var(--text-3); font-size: 15px; padding: 6px 8px; border-radius: 6px;
  transition: var(--t-fast); flex-shrink: 0;
}
.tip-banner .tip-close:hover { color: var(--text-1); background: rgba(255,255,255,0.06); }

/* ── 35. UNIFIED TOASTS + OFFLINE BANNER ──────────────────────────────── */
.nf-toasts {
  position: fixed; top: 16px; right: 16px; z-index: 4000;
  display: flex; flex-direction: column; gap: 10px;
  max-width: min(360px, calc(100vw - 32px)); pointer-events: none;
}
.nf-toast {
  pointer-events: auto;
  display: flex; align-items: flex-start; gap: 10px;
  padding: 13px 14px; border-radius: 12px;
  background: #0d1320; border: 1px solid rgba(255,255,255,0.10);
  box-shadow: 0 12px 34px rgba(0,0,0,0.45);
  color: var(--text-1, #f8fafc); font-size: 14px; line-height: 1.45;
  transform: translateX(120%); opacity: 0;
  transition: transform .32s cubic-bezier(.2,.8,.2,1), opacity .32s ease;
  border-left: 3px solid var(--green, #22c55e);
}
.nf-toast.in { transform: translateX(0); opacity: 1; }
.nf-toast.out { transform: translateX(120%); opacity: 0; }
.nf-toast-ico {
  flex-shrink: 0; width: 20px; height: 20px; border-radius: 50%;
  display: grid; place-items: center; font-size: 12px; font-weight: 700; margin-top: 1px;
  color: #04130a;
}
.nf-toast-msg { flex: 1; word-break: break-word; }
.nf-toast-x {
  flex-shrink: 0; color: var(--text-3, #64748b); font-size: 12px;
  padding: 2px 4px; border-radius: 5px; transition: var(--t-fast, .15s);
  background: transparent; border: 0; cursor: pointer;
}
.nf-toast-x:hover { color: var(--text-1, #f8fafc); background: rgba(255,255,255,0.08); }
.nf-toast.success { border-left-color: #22c55e; }
.nf-toast.success .nf-toast-ico { background: #22c55e; }
.nf-toast.error   { border-left-color: #ef4444; }
.nf-toast.error   .nf-toast-ico { background: #ef4444; color: #fff; }
.nf-toast.info    { border-left-color: #3b82f6; }
.nf-toast.info    .nf-toast-ico { background: #3b82f6; color: #fff; }
.nf-toast.warning { border-left-color: #f59e0b; }
.nf-toast.warning .nf-toast-ico { background: #f59e0b; }

.nf-offline {
  position: fixed; left: 50%; bottom: -60px; transform: translateX(-50%);
  z-index: 3900; display: flex; align-items: center; gap: 8px;
  padding: 10px 18px; border-radius: 999px; font-size: 13px; font-weight: 500;
  background: #1c1207; color: #fde68a; border: 1px solid rgba(245,158,11,0.4);
  box-shadow: 0 10px 30px rgba(0,0,0,0.4);
  transition: bottom .35s cubic-bezier(.2,.8,.2,1); white-space: nowrap; max-width: calc(100vw - 24px);
}
.nf-offline.show { bottom: 18px; }
.nf-offline-dot {
  width: 8px; height: 8px; border-radius: 50%; background: #f59e0b; flex-shrink: 0;
  animation: nfPulse 1.4s ease-in-out infinite;
}
@keyframes nfPulse { 0%,100% { opacity: 1; } 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) {
  .nf-toast { transition: opacity .2s ease; transform: none; }
  .nf-toast.in { transform: none; } .nf-toast.out { transform: none; }
  .nf-offline-dot { animation: none; }
}

/* ── 36. ONBOARDING · WELCOME OVERLAY + SHARED BUTTONS ─────────────────── */
.nf-btn-primary {
  background: var(--green, #22c55e); color: #04130a; border: 0; cursor: pointer;
  font-family: var(--font-display, inherit); font-weight: 600; font-size: 14px;
  padding: 12px 22px; border-radius: 12px; transition: transform .15s ease, box-shadow .15s ease;
}
.nf-btn-primary:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(34,197,94,0.28); }
.nf-btn-ghost {
  background: rgba(255,255,255,0.06); color: var(--text-1, #f8fafc);
  border: 1px solid rgba(255,255,255,0.14); cursor: pointer;
  font-family: var(--font-display, inherit); font-weight: 600; font-size: 14px;
  padding: 12px 22px; border-radius: 12px; transition: var(--t-fast, .15s);
}
.nf-btn-ghost:hover { background: rgba(255,255,255,0.10); }

.nf-welcome {
  position: fixed; inset: 0; z-index: 5000;
  display: grid; place-items: center; text-align: center; padding: 24px;
  background: rgba(4,8,14,0.86); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  opacity: 0; transition: opacity .35s ease;
}
.nf-welcome.in { opacity: 1; }
.nf-welcome-skip {
  position: absolute; right: 18px; bottom: 16px; background: transparent; border: 0; cursor: pointer;
  color: var(--text-3, #64748b); font-size: 13px; padding: 8px 10px; border-radius: 8px;
}
.nf-welcome-skip:hover { color: var(--text-1, #f8fafc); }
.nf-welcome-card {
  max-width: 440px; transform: translateY(16px) scale(.98); opacity: 0;
  transition: transform .4s cubic-bezier(.2,.8,.2,1), opacity .4s ease;
}
.nf-welcome.in .nf-welcome-card { transform: none; opacity: 1; }
.nf-welcome-logo { position: relative; display: inline-grid; place-items: center; margin-bottom: 28px; }
.nf-wl-ring {
  position: absolute; width: 92px; height: 92px; border-radius: 50%;
  border: 2px solid rgba(34,197,94,0.4); border-top-color: var(--green, #22c55e);
  animation: nfSpin 2.6s linear infinite;
}
.nf-wl-mark { font-family: var(--font-display, inherit); font-weight: 700; font-size: 22px; letter-spacing: -0.02em; }
.nf-wl-mark span { color: var(--green, #22c55e); }
@keyframes nfSpin { to { transform: rotate(360deg); } }
.nf-welcome-title { font-family: var(--font-display, inherit); font-size: clamp(28px, 7vw, 40px); margin: 0 0 8px; }
.nf-welcome-sub { color: var(--text-2, #94a3b8); font-size: 16px; margin: 0 0 30px; }
.nf-welcome-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.nf-welcome-actions button { min-width: 150px; }

/* ── 37. ONBOARDING · SPOTLIGHT FEATURE TOUR ──────────────────────────── */
.nf-tour { position: fixed; inset: 0; z-index: 6000; opacity: 0; transition: opacity .3s ease; }
.nf-tour.in { opacity: 1; }
.nf-tour-mask {
  position: fixed; border-radius: 14px; pointer-events: none;
  box-shadow: 0 0 0 9999px rgba(4,8,14,0.74);
  border: 2px solid var(--green, #22c55e);
  transition: top .3s ease, left .3s ease, width .3s ease, height .3s ease;
  animation: nfTourPulse 1.8s ease-in-out infinite;
}
@keyframes nfTourPulse {
  0%,100% { box-shadow: 0 0 0 9999px rgba(4,8,14,0.74), 0 0 0 0 rgba(34,197,94,0.45); }
  50%     { box-shadow: 0 0 0 9999px rgba(4,8,14,0.74), 0 0 0 6px rgba(34,197,94,0); }
}
.nf-tour-pop {
  position: fixed; width: min(330px, calc(100vw - 32px));
  background: #0d1320; border: 1px solid rgba(255,255,255,0.12); border-radius: 16px;
  padding: 20px; box-shadow: 0 18px 50px rgba(0,0,0,0.5); pointer-events: auto;
}
.nf-tour-pop.place-bottom {
  left: 50% !important; top: auto !important; bottom: 20px; transform: translateX(-50%);
}
.nf-tour-step { font-family: var(--font-mono, monospace); font-size: 11px; letter-spacing: .08em; color: var(--green, #22c55e); text-transform: uppercase; margin-bottom: 8px; }
.nf-tour-title { font-family: var(--font-display, inherit); font-size: 19px; margin: 0 0 8px; color: var(--text-1, #f8fafc); }
.nf-tour-body { color: var(--text-2, #94a3b8); font-size: 14px; line-height: 1.55; margin: 0 0 16px; }
.nf-tour-dots { display: flex; gap: 7px; margin-bottom: 16px; }
.nf-tour-dot { width: 7px; height: 7px; border-radius: 50%; background: rgba(255,255,255,0.18); transition: var(--t-fast, .2s); }
.nf-tour-dot.active { background: var(--green, #22c55e); width: 22px; border-radius: 999px; }
.nf-tour-dot.done { background: rgba(34,197,94,0.5); }
.nf-tour-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.nf-tour-skip { background: transparent; border: 0; cursor: pointer; color: var(--text-3, #64748b); font-size: 13px; padding: 8px 4px; }
.nf-tour-skip:hover { color: var(--text-1, #f8fafc); }
.nf-tour-next { padding: 10px 20px; }
@media (prefers-reduced-motion: reduce) {
  .nf-tour-mask { animation: none; transition: none; }
  .nf-wl-ring { animation: none; }
}

/* ── 38. PROFILE WIZARD ───────────────────────────────────────────────── */
.wizard-progress { margin: 0 0 22px; }
.wizard-bar { height: 6px; border-radius: 999px; background: rgba(255,255,255,0.08); overflow: hidden; }
.wizard-bar-fill {
  display: block; height: 100%; width: 33.33%; border-radius: 999px;
  background: linear-gradient(90deg, #22c55e, #0f766e);
  transition: width .4s cubic-bezier(.2,.8,.2,1);
}
.wizard-steplabel {
  margin-top: 9px; font-family: var(--font-mono, monospace); font-size: 11px;
  letter-spacing: .08em; text-transform: uppercase; color: var(--text-3, #64748b);
}
.wizard-step { animation: wizFade .3s ease; }
@keyframes wizFade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.wizard-encourage {
  margin: 14px 0 0; font-size: 13.5px; line-height: 1.6; color: var(--text-2, #94a3b8);
}
.wizard-nav { display: flex; align-items: center; gap: 12px; margin-top: 22px; }
.wizard-nav .wizard-next, .wizard-nav .wizard-save { margin-left: auto; }
.btn-ghost {
  background: rgba(255,255,255,0.06); color: var(--text-1, #f8fafc);
  border: 1px solid rgba(255,255,255,0.14); cursor: pointer;
  font-weight: 600; font-size: 14px; padding: 12px 20px; border-radius: 12px;
  transition: var(--t-fast, .15s);
}
.btn-ghost:hover { background: rgba(255,255,255,0.10); }

/* ── 39. TOOLTIPS ─────────────────────────────────────────────────────── */
.nf-tip {
  position: relative; display: inline-flex; align-items: center; gap: 3px;
  color: var(--green, #22c55e); cursor: help; border-bottom: 1px dotted rgba(34,197,94,0.5);
}
.nf-tip-ico { font-size: 11px; opacity: .8; }
.nf-tip::after {
  content: attr(data-tip);
  position: absolute; bottom: calc(100% + 9px); left: 50%; transform: translateX(-50%) translateY(4px);
  width: max-content; max-width: 230px; padding: 9px 12px; border-radius: 10px;
  background: #0d1320; border: 1px solid rgba(255,255,255,0.12); color: var(--text-1, #f8fafc);
  font-size: 12.5px; font-weight: 400; line-height: 1.45; text-align: left;
  box-shadow: 0 10px 28px rgba(0,0,0,0.45); white-space: normal;
  opacity: 0; pointer-events: none; transition: opacity .18s ease, transform .18s ease; z-index: 50;
}
.nf-tip::before {
  content: ''; position: absolute; bottom: calc(100% + 3px); left: 50%; transform: translateX(-50%);
  border: 6px solid transparent; border-top-color: #0d1320; opacity: 0; transition: opacity .18s ease; z-index: 51;
}
.nf-tip:hover::after, .nf-tip:focus::after, .nf-tip.show::after { opacity: 1; transform: translateX(-50%) translateY(0); }
.nf-tip:hover::before, .nf-tip:focus::before, .nf-tip.show::before { opacity: 1; }

/* ── 40. CELEBRATION SCREEN + CONFETTI ────────────────────────────────── */
.celebrate {
  /* Hidden by default. Only `.active` reveals it — this prevents the overlay
     (a full-screen z-index:5200 layer) from silently blocking clicks on the
     profile wizard when it should be dormant. */
  position: fixed; inset: 0; z-index: 5200; display: none; place-items: center; padding: 24px; overflow: hidden;
  background: rgba(4,8,14,0.92); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  opacity: 0; transition: opacity .4s ease;
}
.celebrate.active { display: grid; }
.celebrate.in { opacity: 1; }
.celebrate-card {
  text-align: center; max-width: 420px; position: relative; z-index: 2;
  transform: scale(.94) translateY(10px); opacity: 0; transition: transform .45s cubic-bezier(.2,.8,.2,1), opacity .45s ease;
}
.celebrate.in .celebrate-card { transform: none; opacity: 1; }
.celebrate-emoji { font-size: 54px; animation: celebPop .6s cubic-bezier(.2,1.4,.4,1) both; }
@keyframes celebPop { 0% { transform: scale(0); } 100% { transform: scale(1); } }
.celebrate-title { font-family: var(--font-display, inherit); font-size: clamp(26px, 6vw, 36px); margin: 10px 0 6px; }
.celebrate-sub { color: var(--text-2, #94a3b8); font-size: 15px; margin: 0 0 24px; }
.celebrate-target {
  display: inline-flex; align-items: baseline; gap: 8px; margin: 0 auto 28px; padding: 18px 30px;
  border-radius: 16px; background: rgba(34,197,94,0.08); border: 1px solid rgba(34,197,94,0.28);
}
.celebrate-target-num { font-family: var(--font-display, inherit); font-weight: 700; font-size: 42px; color: var(--green, #22c55e); }
.celebrate-target-label { color: var(--text-2, #94a3b8); font-size: 14px; }
.celebrate-cta { display: inline-block; text-decoration: none; }
.celebrate-confetti { position: absolute; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.confetti-bit {
  position: absolute; top: -16px; border-radius: 2px; opacity: .9;
  animation-name: confettiFall; animation-timing-function: linear; animation-iteration-count: 1; animation-fill-mode: forwards;
}
@keyframes confettiFall {
  0% { transform: translateY(-10vh) rotate(0deg); opacity: 1; }
  100% { transform: translateY(108vh) rotate(720deg); opacity: .9; }
}
@media (prefers-reduced-motion: reduce) {
  .celebrate-card, .celebrate-emoji { animation: none; transition: opacity .2s ease; transform: none; }
  .confetti-bit { display: none; }
}

/* ── 41. MOBILE HARDENING (loads on every page) ───────────────────────── */
/* Kill any horizontal scroll without the blunt `*{max-width:100vw}` hammer
   (which would break the ticker and other intentionally-wide children). */
html, body { max-width: 100%; overflow-x: hidden; }

/* The short button label is hidden by default; mobile swaps it in. */
.short-text { display: none; }

@media (max-width: 768px) {
  /* iOS zooms when a focused input's font is < 16px. Belt-and-suspenders with
     the viewport flag so a focused field never triggers a zoom jump. */
  input, select, textarea { font-size: 16px; }

  /* Comfortable, tappable primary actions; block buttons span the column. */
  .btn-primary, .btn-ghost, .generate-btn, .panic-btn {
    min-height: 48px; font-size: 15px;
  }
  .btn-block, .generate-btn, .panic-btn { width: 100%; }

  /* Shorten the meal-plan button text on narrow screens. */
  #generateBtn .full-text { display: none; }
  #generateBtn .short-text { display: inline; }

  /* Touch targets — every interactive control reaches ~44px. */
  .nb-nav-item, .filter-btn, .rcp-tab, .faq-q { min-height: 44px; }
  .ip-close, .nb-avatar-btn, .nb-toast-x, .nf-toast-x {
    min-width: 44px; min-height: 44px;
    display: inline-flex; align-items: center; justify-content: center;
  }
  /* Hamburger must KEEP its vertical (column) layout so the 3 lines stay
     visible — only grow the hit target. Do not switch it to inline-flex/row. */
  .nb-hamburger {
    min-width: 44px; min-height: 44px; width: 44px; height: 44px;
    display: flex; flex-direction: column; align-items: stretch; justify-content: center;
  }

  /* Water progress ring: smaller so it never overflows the card. */
  .water-ring-wrap, .water-ring { width: 200px !important; height: 200px !important; }

  /* Feature-page panels stack to one column edge-to-edge. */
  .health-ring-wrap { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
  /* Extra-small phones: tighten buttons and ensure 2-up stat grids. */
  .btn-primary, .btn-ghost, .generate-btn { font-size: 14px; padding: 12px 16px; }
  .stats-grid, .quit-stats, .plan-targets { grid-template-columns: 1fr 1fr; }
  /* Keep the food gallery readable at 2 columns rather than cramped 3. */
  .bento-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  h1 { font-size: clamp(24px, 7vw, 34px); }
}

/* ══════════════════════════════════════════════════════════════════════
   §42. LEGAL PAGES · COOKIE BANNER · FOOTER · MEDICAL NOTE
   ══════════════════════════════════════════════════════════════════════ */

/* ── Legal page layout ──────────────────────────────────────────────── */
.legal-page { min-height: 100dvh; padding: 88px 24px 120px; }

.legal-wrap { max-width: 800px; margin: 0 auto; }

.legal-badge {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--green);
  border: 1px solid rgba(34,197,94,0.3);
  border-radius: var(--r-pill);
  padding: 3px 12px;
  margin-bottom: 16px;
  text-transform: uppercase;
}

.legal-header {
  margin-bottom: 48px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--border-subtle);
}

.legal-title {
  font-family: var(--font-display);
  font-size: clamp(26px, 4.5vw, 40px);
  font-weight: 700;
  color: var(--text-1);
  line-height: 1.2;
  margin-bottom: 10px;
}

.legal-meta { font-size: 13px; color: var(--text-3); font-family: var(--font-mono); }
.legal-meta a { color: var(--green); }

.legal-toc {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-lg);
  padding: 20px 24px;
  margin-bottom: 48px;
}

.legal-toc-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 12px;
}

.legal-toc ol { list-style: decimal; padding-left: 20px; display: grid; gap: 6px; }
.legal-toc a { font-size: 14px; color: var(--text-2); transition: color 0.15s; }
.legal-toc a:hover { color: var(--green); }

.legal-section { margin-bottom: 52px; scroll-margin-top: 80px; }

.legal-section h2 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  color: var(--text-1);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
  gap: 10px;
}

.legal-num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--green);
  background: var(--green-dim);
  padding: 2px 8px;
  border-radius: var(--r-sm);
  flex-shrink: 0;
}

.legal-section p { color: var(--text-2); font-size: 15px; line-height: 1.85; margin-bottom: 14px; }
.legal-section p:last-child { margin-bottom: 0; }

.legal-section ul,
.legal-section ol {
  padding-left: 22px;
  color: var(--text-2);
  font-size: 15px;
  line-height: 1.85;
  margin-bottom: 14px;
  display: grid;
  gap: 6px;
}

.legal-section ul { list-style: disc; }
.legal-section ol { list-style: decimal; }
.legal-section a { color: var(--green); text-decoration: underline; text-underline-offset: 3px; }
.legal-section h3 { font-family: var(--font-display); font-size: 15px; font-weight: 600; color: var(--text-1); margin: 20px 0 8px; }

.legal-highlight {
  background: rgba(34,197,94,0.05);
  border: 1px solid rgba(34,197,94,0.2);
  border-radius: var(--r-md);
  padding: 16px 20px;
  margin: 16px 0;
}
.legal-highlight p { margin-bottom: 0; }

.legal-warn {
  background: rgba(239,68,68,0.05);
  border-left: 3px solid var(--red);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  padding: 14px 18px;
  margin: 16px 0;
}
.legal-warn p { margin-bottom: 0; }

.cookie-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  margin: 16px 0;
  border-radius: var(--r-md);
  overflow: hidden;
  border: 1px solid var(--border-subtle);
}
.cookie-table th,
.cookie-table td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--border-subtle); color: var(--text-2); }
.cookie-table th { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.07em; text-transform: uppercase; color: var(--text-3); background: var(--bg-card); }
.cookie-table tr:last-child td { border-bottom: none; }
.cookie-table td:first-child { font-family: var(--font-mono); font-size: 12px; color: var(--green); }

/* ── Cookie consent banner ──────────────────────────────────────────── */
.nf-cookie-banner {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 8500;
  background: rgba(8,12,20,0.97);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-top: 1px solid var(--border-subtle);
  padding: 14px 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.4,0,0.2,1);
}
.nf-cookie-banner.show { transform: translateY(0); }
.nf-cookie-text { flex: 1; font-size: 13px; color: var(--text-2); min-width: 200px; }
.nf-cookie-text a { color: var(--green); text-decoration: underline; }
.nf-cookie-actions { display: flex; gap: 10px; flex-shrink: 0; }
.nf-cookie-accept {
  background: var(--green); color: #fff; font-size: 13px; font-weight: 600;
  padding: 7px 20px; border-radius: var(--r-pill); transition: opacity 0.15s;
}
.nf-cookie-accept:hover { opacity: 0.88; }
.nf-cookie-more {
  font-size: 13px; color: var(--text-2); border: 1px solid var(--border-mid);
  padding: 7px 16px; border-radius: var(--r-pill); transition: var(--t-fast);
  display: inline-flex; align-items: center;
}
.nf-cookie-more:hover { color: var(--text-1); border-color: var(--text-2); }

/* ── Site-wide footer ───────────────────────────────────────────────── */
.nf-footer { border-top: 1px solid var(--border-subtle); background: var(--bg-secondary); padding: 44px 24px 36px; margin-top: 80px; }
.nf-footer-inner { max-width: 860px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; gap: 20px; text-align: center; }
.nf-footer-brand { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.nf-footer-logo { font-family: var(--font-display); font-size: 17px; font-weight: 700; color: var(--text-1); letter-spacing: -0.02em; }
.nf-footer-logo span { color: var(--green); }
.nf-footer-tagline { font-size: 12px; color: var(--text-3); }
.nf-footer-disclaimer {
  font-size: 12px; color: var(--text-3); font-style: italic; max-width: 560px;
  padding: 10px 18px; background: rgba(245,158,11,0.04); border: 1px solid rgba(245,158,11,0.12);
  border-radius: var(--r-md); line-height: 1.6;
}
.nf-footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 20px; }
.nf-footer-links a { font-size: 13px; color: var(--text-2); transition: color 0.15s; }
.nf-footer-links a:hover { color: var(--green); }
.nf-footer-copy { font-size: 12px; color: var(--text-3); font-family: var(--font-mono); }
.nf-footer-copy a { color: var(--green); }

/* Sidebar legal mini-nav */
.nb-sidebar-legal { display: flex; flex-wrap: wrap; gap: 4px 12px; padding: 10px 20px 6px; border-top: 1px solid var(--border-subtle); }
.nb-sidebar-legal a { font-size: 11px; color: var(--text-3); transition: color 0.15s; }
.nb-sidebar-legal a:hover { color: var(--green); }

/* ── Medical disclaimer note ────────────────────────────────────────── */
.nf-medical-note {
  display: flex; align-items: flex-start; gap: 8px; font-size: 12px; color: var(--text-3);
  padding: 10px 14px; background: rgba(245,158,11,0.04); border: 1px solid rgba(245,158,11,0.12);
  border-radius: var(--r-md); margin-top: 16px; line-height: 1.5;
}
.nf-medical-note a { color: var(--amber); text-decoration: underline; text-underline-offset: 2px; }

@media (max-width: 640px) {
  .legal-page { padding: 80px 16px 80px; }
  .nf-cookie-banner { flex-direction: column; align-items: flex-start; gap: 10px; }
  .nf-cookie-actions { width: 100%; }
  .nf-cookie-accept, .nf-cookie-more { flex: 1; justify-content: center; text-align: center; }
  .cookie-table th, .cookie-table td { padding: 8px 10px; }
  .legal-section h2 { font-size: 16px; }
  .nf-footer { padding: 32px 16px 24px; margin-top: 48px; }
}

@media print {
  .navbar, .nf-cookie-banner, .nf-footer, #nbSidebarOverlay { display: none !important; }
  .legal-page { padding-top: 20px; }
  body { background: #fff; color: #000; }
  .legal-title, .legal-section h2 { color: #000; }
  .legal-section p, .legal-section li { color: #333; }
  .legal-num { background: #eee; color: #000; }
}

/* §43 — Age checkbox + health modal */
.form-group--checkbox { margin-top: 4px; margin-bottom: 8px; }
.form-label--checkbox {
  display: flex; align-items: flex-start; gap: 10px;
  font-size: 0.875rem; color: var(--text-secondary); cursor: pointer; line-height: 1.5;
}
.form-checkbox {
  flex-shrink: 0; width: 18px; height: 18px; margin-top: 1px;
  accent-color: var(--green); cursor: pointer; border-radius: 4px;
}
.form-checkbox.error { outline: 2px solid var(--red, #f87171); }

/* ── Minimal one-line footer ──────────────────────────────────────────── */
.nf-footer-mini {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 16px;
  font-size: 12px;
  color: var(--text-3);
  border-top: 1px solid rgba(255,255,255,0.06);
}
.nf-footer-mini a {
  color: var(--text-3);
  text-decoration: none;
}
.nf-footer-mini a:hover { color: var(--green); }
.footer-divider { opacity: 0.3; }
