/* ==========================================================================
   CaloriC — AI Calorie Counter by Photo (Telegram Bot + Web App)
   Visual Direction: CDM Moscow ultra-rounded editorial light canvas
   Brand Palette: Mascot Emerald -> Lime Green + Vibrant Orange
   ========================================================================== */

:root {
  --bg-page: #ffffff;
  --bg-soft: #f5f7f6;
  --bg-mint: #ebf8f0;
  --bg-peach: #fff4ea;
  --bg-dark: #0e2119;
  --bg-dark-card: #152e23;

  --ink: #0e2019;
  --ink-secondary: #495e55;
  --ink-muted: #72877d;
  --border: rgba(14, 32, 25, 0.08);
  --border-strong: rgba(14, 32, 25, 0.14);

  --green-deep: #00865a;
  --green-mid: #1fb854;
  --green-lime: #8be02c;
  --green-grad: linear-gradient(135deg, #00865a 0%, #24bd53 56%, #8ce229 100%);

  --orange: #ff6b00;
  --orange-warm: #ffa800;
  --orange-grad: linear-gradient(135deg, #ff6b00 0%, #ffa800 100%);

  --tg-blue: #229ed9;
  --tg-blue-dark: #1a88be;

  --radius-xl: 36px;
  --radius-lg: 26px;
  --radius-md: 20px;
  --radius-sm: 14px;
  --radius-pill: 100px;

  --shadow-soft: 0 12px 32px rgba(14, 32, 25, 0.06);
  --shadow-card: 0 18px 48px rgba(14, 32, 25, 0.09);
  --shadow-green: 0 12px 28px rgba(0, 134, 90, 0.22);
  --shadow-orange: 0 12px 28px rgba(255, 107, 0, 0.24);

  --container: 1180px;
  --transition: 0.22s cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
  overflow-x: clip;
}

body {
  margin: 0;
  font-family: 'Onest', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: var(--ink);
  background: var(--bg-page);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

img {
  max-width: 100%;
  display: block;
}

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

button {
  font-family: inherit;
  cursor: pointer;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* Prevent flex/grid children from ever causing horizontal overflow */
.hero-grid > *,
.showcase-panel > *,
.cabinet-body > *,
.cta-banner > *,
.calc-layout > *,
.pricing-grid > *,
.cards-3 > *,
.steps-grid > *,
.bento-grid > *,
.reviews-grid > *,
.metrics-strip > * {
  min-width: 0;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 12px 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--border);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.03em;
  flex-shrink: 0;
}

.brand-logo {
  width: 38px;
  height: 38px;
  object-fit: contain;
  transition: transform var(--transition);
}

.brand:hover .brand-logo {
  transform: scale(1.07) rotate(-4deg);
}

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

.nav-link {
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--ink-secondary);
  transition: background var(--transition), color var(--transition);
  white-space: nowrap;
}

.nav-link:hover,
.nav-link.active {
  background: var(--bg-soft);
  color: var(--ink);
}

.nav-link--highlight {
  color: var(--green-deep);
  background: var(--bg-mint);
  font-weight: 600;
}

.nav-link--highlight:hover {
  background: #dcf3e5;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-strong);
  background: #fff;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  color: var(--ink);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 13px 24px;
  border-radius: var(--radius-pill);
  font-weight: 700;
  font-size: 0.95rem;
  border: none;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition), border-color var(--transition);
  text-align: center;
  line-height: 1.25;
}

.btn:active {
  transform: translateY(1px) scale(0.99);
}

.btn-primary {
  background: var(--green-grad);
  color: #fff;
  box-shadow: var(--shadow-green);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 34px rgba(0, 134, 90, 0.3);
}

.btn-telegram {
  background: var(--tg-blue);
  color: #fff;
  box-shadow: 0 10px 24px rgba(34, 158, 217, 0.24);
}

.btn-telegram:hover {
  background: var(--tg-blue-dark);
  transform: translateY(-2px);
}

.btn-orange {
  background: var(--orange-grad);
  color: #fff;
  box-shadow: var(--shadow-orange);
}

.btn-orange:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px rgba(255, 107, 0, 0.32);
}

.btn-outline {
  background: #fff;
  color: var(--ink);
  border: 1.5px solid var(--border-strong);
}

.btn-outline:hover {
  border-color: var(--green-deep);
  background: var(--bg-mint);
  color: var(--green-deep);
}

.btn-white {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.14);
}

.btn-white:hover {
  transform: translateY(-2px);
  background: #f6fff9;
}

.btn-glass {
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  border: 1.5px solid rgba(255, 255, 255, 0.34);
}

.btn-glass:hover {
  background: rgba(255, 255, 255, 0.26);
}

.btn-sm {
  padding: 9px 17px;
  font-size: 0.86rem;
}

.btn-lg {
  padding: 15px 28px;
  font-size: 1rem;
}

/* ---------- Pills & Badges ---------- */
.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 13px;
  border-radius: var(--radius-pill);
  font-size: 0.82rem;
  font-weight: 600;
  background: var(--bg-soft);
  color: var(--ink-secondary);
}

.pill--green {
  background: var(--bg-mint);
  color: var(--green-deep);
}

.pill--orange {
  background: var(--bg-peach);
  color: #cc5200;
}

.pill--dark {
  background: var(--bg-dark);
  color: #fff;
}

.section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 15px;
  border-radius: var(--radius-pill);
  background: var(--bg-mint);
  color: var(--green-deep);
  font-size: 0.84rem;
  font-weight: 700;
  margin-bottom: 16px;
}

/* ---------- Typography Helpers ---------- */
.section {
  padding: 76px 0;
}

.section--tight {
  padding: 52px 0;
}

.section-header {
  max-width: 680px;
  margin-bottom: 40px;
}

.section-header--center {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.section-title {
  margin: 0 0 12px;
  font-size: clamp(1.85rem, 3.8vw, 2.95rem);
  font-weight: 800;
  line-height: 1.09;
  letter-spacing: -0.03em;
}

.section-subtitle {
  margin: 0;
  font-size: 1.05rem;
  color: var(--ink-secondary);
  line-height: 1.58;
}

.text-gradient {
  background: var(--green-grad);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ---------- Lightweight Airy Hero ---------- */
.hero {
  position: relative;
  padding: 44px 0 56px;
  background: radial-gradient(circle at 84% 18%, rgba(139, 224, 44, 0.14) 0%, rgba(0, 134, 90, 0.04) 36%, transparent 62%),
              radial-gradient(circle at 12% 82%, rgba(255, 107, 0, 0.07) 0%, transparent 48%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 48px;
  align-items: center;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--green-deep);
  background: var(--bg-mint);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  margin-bottom: 18px;
}

.hero-title {
  margin: 0 0 18px;
  font-size: clamp(2.2rem, 4.6vw, 3.6rem);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.035em;
}

.hero-desc {
  margin: 0 0 26px;
  font-size: 1.08rem;
  color: var(--ink-secondary);
  max-width: 520px;
}

.hero-cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 14px;
}

.hero-note {
  margin: 0 0 20px;
  font-size: 0.85rem;
  color: var(--ink-muted);
  max-width: 480px;
}

.hero-sub-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 20px;
  font-size: 0.9rem;
}

.hero-calc-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  color: var(--green-deep);
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  background: var(--bg-soft);
  transition: background var(--transition), transform var(--transition);
}

.hero-calc-link:hover {
  background: var(--bg-mint);
  transform: translateX(2px);
}

.hero-platforms {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 0.82rem;
  color: var(--ink-muted);
}

.platform-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.84rem;
  font-weight: 700;
  text-decoration: none;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--ink-primary);
  box-shadow: 0 2px 8px rgba(14, 32, 25, 0.04);
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition), background var(--transition), color var(--transition);
}

.platform-btn:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-soft);
}

.platform-btn--tg {
  color: #1682c2;
  border-color: rgba(34, 158, 217, 0.28);
  background: rgba(34, 158, 217, 0.08);
}

.platform-btn--tg:hover {
  background: rgba(34, 158, 217, 0.14);
  border-color: rgba(34, 158, 217, 0.48);
}

.platform-btn--web {
  color: var(--green-deep);
  border-color: rgba(0, 134, 90, 0.25);
  background: var(--bg-mint);
}

.platform-btn--web:hover {
  background: #d8f5ea;
  border-color: rgba(0, 134, 90, 0.45);
}

/* Lightweight Hero Dish Card */
.scanner-card {
  background: #fff;
  border-radius: 30px;
  padding: 16px;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border);
}

.scanner-photo-wrap {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: #e9efec;
}

.scanner-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.scanner-card:hover .scanner-photo {
  transform: scale(1.03);
}

.scan-tag {
  position: absolute;
  padding: 5px 11px;
  border-radius: var(--radius-pill);
  background: rgba(14, 32, 25, 0.78);
  color: #fff;
  backdrop-filter: blur(8px);
  font-size: 0.76rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.scan-tag--tl { top: 12px; left: 12px; }
.scan-tag--br { bottom: 12px; right: 12px; background: rgba(0, 134, 90, 0.92); }

.scan-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #8be02c;
}

.scanner-result {
  padding: 16px 4px 4px;
}

.scanner-dish-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.scanner-dish-name {
  font-weight: 800;
  font-size: 1.06rem;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.scanner-dish-weight {
  font-size: 0.8rem;
  color: var(--ink-muted);
  margin-top: 3px;
}

.scanner-kcal-pill {
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  background: var(--orange-grad);
  color: #fff;
  font-weight: 800;
  font-size: 0.98rem;
  white-space: nowrap;
  flex-shrink: 0;
}

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

.macro-chip {
  background: var(--bg-soft);
  border-radius: 14px;
  padding: 9px 10px;
  text-align: center;
}

.macro-chip strong {
  display: block;
  font-size: 1rem;
  font-weight: 800;
}

.macro-chip span {
  font-size: 0.74rem;
  color: var(--ink-muted);
  font-weight: 600;
}

.day-mini-bar {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 14px;
  background: var(--bg-mint);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--green-deep);
}

.demo-switcher {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-top: 12px;
}

.demo-chip {
  padding: 8px 8px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-strong);
  background: #fff;
  font-size: 0.77rem;
  font-weight: 600;
  color: var(--ink-secondary);
  transition: all var(--transition);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.demo-chip.active,
.demo-chip:hover {
  background: var(--bg-dark);
  color: #fff;
  border-color: var(--bg-dark);
}

/* ---------- CDM-Style Big Metrics Strip ---------- */
.metrics-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 40px;
}

.metric-card {
  background: var(--bg-soft);
  border-radius: var(--radius-lg);
  padding: 26px;
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.metric-card--green {
  background: var(--bg-mint);
  border-color: rgba(0, 134, 90, 0.14);
}

.metric-card--peach {
  background: var(--bg-peach);
  border-color: rgba(255, 107, 0, 0.16);
}

.metric-big {
  font-size: clamp(2.1rem, 3.6vw, 3rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.04em;
}

.metric-card--green .metric-big { color: var(--green-deep); }
.metric-card--peach .metric-big { color: var(--orange); }

.metric-title {
  font-size: 1rem;
  font-weight: 700;
}

.metric-desc {
  font-size: 0.9rem;
  color: var(--ink-secondary);
  margin: 0;
}

/* ---------- Cards Grid ---------- */
.cards-3,
.steps-grid,
.bento-grid,
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.card,
.step-card,
.review-card {
  background: var(--bg-soft);
  border-radius: var(--radius-lg);
  padding: 28px;
  border: 1px solid var(--border);
  transition: transform var(--transition), box-shadow var(--transition);
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-soft);
}

.card-icon {
  width: 50px;
  height: 50px;
  border-radius: 16px;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.45rem;
  margin-bottom: 16px;
  box-shadow: 0 6px 14px rgba(14, 32, 25, 0.05);
}

.card h3,
.step-card h3 {
  margin: 0 0 8px;
  font-size: 1.18rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.card p,
.step-card p {
  margin: 0;
  color: var(--ink-secondary);
  font-size: 0.94rem;
}

.step-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.step-num {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: var(--green-grad);
  color: #fff;
  font-size: 1.2rem;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
}

.step-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
  padding-top: 6px;
}

/* ---------- Cabinet & Telegram Bot Screenshots Showcase ---------- */
.showcase-shell {
  background: var(--bg-dark);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: 48px 40px;
  position: relative;
  overflow: hidden;
}

.showcase-shell::before {
  content: '';
  position: absolute;
  top: -120px;
  right: -80px;
  width: 440px;
  height: 440px;
  background: radial-gradient(circle, rgba(139, 224, 44, 0.18) 0%, transparent 65%);
  pointer-events: none;
}

.showcase-shell .section-subtitle {
  color: rgba(255, 255, 255, 0.76);
}

.showcase-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  background: rgba(255, 255, 255, 0.08);
  padding: 6px;
  border-radius: 22px;
  margin-bottom: 30px;
  width: fit-content;
  max-width: 100%;
}

.showcase-tab {
  padding: 10px 18px;
  border-radius: var(--radius-pill);
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.78);
  font-weight: 700;
  font-size: 0.9rem;
  transition: all var(--transition);
}

.showcase-tab.active {
  background: #fff;
  color: var(--ink);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.showcase-panel {
  display: none;
  animation: fadeSlide 0.3s ease;
}

.showcase-panel.active {
  display: grid;
  grid-template-columns: 1.32fr 0.68fr;
  gap: 24px;
  align-items: stretch;
}

.showcase-panel--single.active {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: center;
}

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

.browser-frame {
  background: #f6f8f7;
  color: var(--ink);
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 24px 56px rgba(0, 0, 0, 0.38);
}

.browser-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 16px;
  background: #e9efec;
  border-bottom: 1px solid rgba(14, 32, 25, 0.08);
}

.browser-dots {
  display: flex;
  gap: 6px;
  flex-shrink: 0;
}

.browser-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.browser-dots span:nth-child(1) { background: #ff5f57; }
.browser-dots span:nth-child(2) { background: #febc2e; }
.browser-dots span:nth-child(3) { background: #28c840; }

.browser-url {
  background: #fff;
  padding: 4px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--ink-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cabinet-body {
  display: grid;
  grid-template-columns: 176px 1fr;
  min-height: 410px;
}

.cabinet-sidebar {
  background: #fff;
  padding: 16px 12px;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.cab-brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  font-size: 0.94rem;
  margin-bottom: 12px;
  padding: 0 6px;
}

.cab-brand img {
  width: 24px;
  height: 24px;
}

.cab-nav-item {
  padding: 8px 10px;
  border-radius: 12px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink-secondary);
}

.cab-nav-item.active {
  background: var(--bg-mint);
  color: var(--green-deep);
}

.cab-sync-badge {
  margin-top: auto;
  padding: 10px;
  border-radius: 14px;
  background: #eaf6fd;
  color: #1474a4;
  font-size: 0.74rem;
  font-weight: 700;
  line-height: 1.35;
}

.cabinet-main {
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.cab-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.cab-date {
  font-weight: 800;
  font-size: 1.02rem;
}

.cab-upload-pill {
  padding: 7px 13px;
  border-radius: var(--radius-pill);
  background: var(--green-grad);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  white-space: nowrap;
}

.cab-summary-card {
  background: #fff;
  border-radius: 18px;
  padding: 16px;
  display: grid;
  grid-template-columns: 106px 1fr;
  gap: 16px;
  align-items: center;
  border: 1px solid var(--border);
}

.kcal-ring-wrap {
  position: relative;
  width: 102px;
  height: 102px;
}

.kcal-ring-wrap svg {
  transform: rotate(-90deg);
  width: 102px;
  height: 102px;
}

.kcal-ring-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.kcal-ring-center strong {
  font-size: 1.12rem;
  font-weight: 900;
  line-height: 1;
}

.kcal-ring-center span {
  font-size: 0.68rem;
  color: var(--ink-muted);
  margin-top: 3px;
}

.cab-bars {
  display: grid;
  gap: 9px;
}

.cab-bar-head {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  font-weight: 700;
  margin-bottom: 3px;
}

.cab-bar-track {
  height: 7px;
  border-radius: 100px;
  background: #edf2ef;
  overflow: hidden;
}

.cab-bar-fill { height: 100%; border-radius: 100px; }
.cab-bar-fill--p { background: #00865a; }
.cab-bar-fill--f { background: #ff8a00; }
.cab-bar-fill--c { background: #229ed9; }

.cab-meals {
  display: grid;
  gap: 9px;
}

.cab-meal-row {
  background: #fff;
  border-radius: 15px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 11px;
  border: 1px solid var(--border);
}

.cab-meal-thumb {
  width: 48px;
  height: 48px;
  border-radius: 11px;
  object-fit: cover;
  flex-shrink: 0;
}

.cab-meal-info {
  flex: 1;
  min-width: 0;
}

.cab-meal-title {
  font-weight: 700;
  font-size: 0.85rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cab-meal-meta {
  font-size: 0.74rem;
  color: var(--ink-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cab-meal-kcal {
  font-weight: 800;
  font-size: 0.86rem;
  color: var(--green-deep);
  white-space: nowrap;
  flex-shrink: 0;
}

/* Telegram Phone Mockup */
.phone-frame {
  background: #17212b;
  color: #fff;
  border-radius: 28px;
  padding: 12px;
  border: 2px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 24px 56px rgba(0, 0, 0, 0.42);
  display: flex;
  flex-direction: column;
}

.tg-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 11px;
  background: #212d3b;
  border-radius: 18px 18px 8px 8px;
}

.tg-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #fff;
  padding: 4px;
  object-fit: contain;
}

.tg-name {
  font-weight: 700;
  font-size: 0.88rem;
  line-height: 1.2;
}

.tg-status {
  font-size: 0.72rem;
  color: #6ab3f3;
}

.tg-chat {
  padding: 12px 8px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.tg-msg {
  max-width: 92%;
  border-radius: 15px;
  padding: 10px 12px;
  font-size: 0.79rem;
  line-height: 1.42;
}

.tg-msg--user {
  align-self: flex-end;
  background: #2b5278;
  border-bottom-right-radius: 4px;
}

.tg-msg--user img {
  width: 100%;
  height: 118px;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 6px;
}

.tg-msg--bot {
  align-self: flex-start;
  background: #232f3d;
  border-bottom-left-radius: 4px;
}

.tg-msg--bot strong {
  color: #9be84d;
}

.tg-inline-btns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-top: 8px;
}

.tg-inline-btn {
  padding: 7px 6px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.08);
  text-align: center;
  font-size: 0.72rem;
  font-weight: 600;
  color: #d8ecff;
}

/* Analytics Mockup */
.analytics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.chart-card {
  background: #fff;
  border-radius: 18px;
  padding: 16px;
  border: 1px solid var(--border);
}

.chart-card h4 {
  margin: 0 0 10px;
  font-size: 0.88rem;
  font-weight: 800;
}

.bars-week {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
  align-items: end;
  height: 114px;
  padding-top: 10px;
}

.bar-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  height: 100%;
  justify-content: flex-end;
}

.bar-stick {
  width: 100%;
  border-radius: 8px 8px 4px 4px;
  background: var(--green-grad);
}

.bar-stick--over { background: var(--orange-grad); }

.bar-col span {
  font-size: 0.7rem;
  color: var(--ink-muted);
  font-weight: 600;
}

/* ---------- Pricing / Tariffs (Caloria Structure, CaloriC Visual Identity) ---------- */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 24px;
}

.plan-card {
  background: var(--bg-soft);
  border-radius: var(--radius-lg);
  padding: 26px 22px;
  border: 1.5px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.plan-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-soft);
  border-color: var(--border-strong);
}

.plan-card--popular {
  background: var(--bg-mint);
  border-color: rgba(0, 134, 90, 0.28);
}

.plan-card--best {
  background: var(--bg-dark);
  color: #fff;
  border-color: var(--bg-dark);
  box-shadow: var(--shadow-card);
}

.plan-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 28px;
}

.plan-tag {
  font-size: 0.74rem;
  font-weight: 800;
  padding: 5px 11px;
  border-radius: var(--radius-pill);
  background: #fff;
  color: var(--ink-secondary);
}

.plan-tag--start {
  background: var(--bg-peach);
  color: #c24b00;
}

.plan-tag--popular {
  background: var(--green-deep);
  color: #fff;
}

.plan-tag--best {
  background: var(--orange-grad);
  color: #fff;
}

.plan-name {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.plan-period {
  font-size: 0.88rem;
  color: var(--ink-muted);
  margin-top: -6px;
}

.plan-card--best .plan-period {
  color: rgba(255, 255, 255, 0.68);
}

.plan-price-row {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin: 6px 0 2px;
}

.plan-price {
  font-size: 2.35rem;
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.04em;
}

.plan-currency {
  font-size: 1.2rem;
  font-weight: 800;
}

.plan-per-day {
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--ink-secondary);
}

.plan-card--best .plan-per-day {
  color: #9be84d;
}

.plan-trial {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  align-self: flex-start;
  font-size: 0.8rem;
  font-weight: 700;
  padding: 5px 11px;
  border-radius: var(--radius-pill);
  background: rgba(0, 134, 90, 0.1);
  color: var(--green-deep);
  margin-top: 2px;
}

.plan-card--best .plan-trial {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.plan-cta {
  margin-top: auto;
  padding-top: 10px;
}

.plan-cta .btn {
  width: 100%;
}

.pricing-footnote {
  background: var(--bg-soft);
  border-radius: 22px;
  padding: 20px 24px;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.pricing-footnote p {
  margin: 0;
  font-size: 0.84rem;
  color: var(--ink-secondary);
  max-width: 780px;
  line-height: 1.55;
}

/* ---------- Reviews ---------- */
.review-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.review-stars {
  color: #ff9800;
  font-size: 1rem;
  letter-spacing: 2px;
}

.review-text {
  margin: 0;
  font-size: 0.94rem;
  color: var(--ink);
  line-height: 1.58;
}

.review-author {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.review-name {
  font-weight: 700;
  font-size: 0.88rem;
}

.review-result {
  padding: 4px 11px;
  border-radius: var(--radius-pill);
  background: var(--bg-mint);
  color: var(--green-deep);
  font-size: 0.76rem;
  font-weight: 700;
}

/* ---------- FAQ ---------- */
.faq-list {
  display: grid;
  gap: 10px;
  max-width: 840px;
  margin: 0 auto;
}

.faq-item {
  background: var(--bg-soft);
  border-radius: 20px;
  border: 1px solid var(--border);
  overflow: hidden;
}

.faq-q {
  width: 100%;
  padding: 20px 22px;
  background: transparent;
  border: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  text-align: left;
  font-size: 1.02rem;
  font-weight: 700;
  color: var(--ink);
}

.faq-plus {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  flex-shrink: 0;
  transition: transform var(--transition), background var(--transition), color var(--transition);
}

.faq-item.open .faq-plus {
  transform: rotate(45deg);
  background: var(--green-deep);
  color: #fff;
}

.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq-a-inner {
  padding: 0 22px 20px;
  color: var(--ink-secondary);
  font-size: 0.94rem;
  line-height: 1.62;
}

/* ---------- Final CTA Banner ---------- */
.cta-banner {
  background: var(--green-grad);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: 48px 44px;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 28px;
  align-items: center;
}

.cta-banner h2 {
  margin: 0 0 12px;
  font-size: clamp(1.85rem, 3.6vw, 2.8rem);
  font-weight: 900;
  line-height: 1.07;
  letter-spacing: -0.03em;
}

.cta-banner p {
  margin: 0 0 24px;
  font-size: 1.04rem;
  color: rgba(255, 255, 255, 0.92);
  max-width: 520px;
}

.cta-banner-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.cta-mascot-wrap {
  display: flex;
  justify-content: center;
}

.cta-mascot-card {
  width: 210px;
  height: 210px;
  background: #fff;
  border-radius: 40px;
  padding: 18px;
  box-shadow: 0 22px 48px rgba(0, 62, 41, 0.26);
  display: flex;
  align-items: center;
  justify-content: center;
}

.cta-mascot-card img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* ---------- Calculator Page ---------- */
.calc-hero {
  padding: 32px 0 20px;
}

.calc-layout {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 24px;
  align-items: start;
}

.calc-card {
  background: var(--bg-soft);
  border-radius: var(--radius-xl);
  padding: 32px;
  border: 1px solid var(--border);
}

.calc-result-card {
  background: var(--bg-dark);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: 32px;
  position: sticky;
  top: 86px;
}

.form-group { margin-bottom: 20px; }

.form-label {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 700;
  font-size: 0.92rem;
  margin-bottom: 9px;
}

.segmented {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  background: #fff;
  padding: 5px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border);
}

.seg-btn {
  padding: 11px 14px;
  border-radius: var(--radius-pill);
  border: none;
  background: transparent;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--ink-secondary);
  transition: all var(--transition);
}

.seg-btn.active {
  background: var(--green-grad);
  color: #fff;
  box-shadow: 0 6px 16px rgba(0, 134, 90, 0.22);
}

.inputs-row-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.num-input-box {
  background: #fff;
  border: 1.5px solid var(--border-strong);
  border-radius: 16px;
  padding: 11px 14px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.num-input-box:focus-within { border-color: var(--green-deep); }

.num-input-box label {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--ink-muted);
}

.num-input-box input {
  border: none;
  outline: none;
  font-family: inherit;
  font-size: 1.24rem;
  font-weight: 800;
  color: var(--ink);
  width: 100%;
  background: transparent;
}

.choice-grid { display: grid; gap: 8px; }

.choice-btn {
  width: 100%;
  text-align: left;
  padding: 13px 16px;
  border-radius: 16px;
  border: 1.5px solid var(--border);
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  transition: all var(--transition);
}

.choice-btn strong { display: block; font-size: 0.92rem; color: var(--ink); }
.choice-btn small { color: var(--ink-muted); font-size: 0.8rem; }
.choice-btn.active { border-color: var(--green-deep); background: var(--bg-mint); }

.choice-badge {
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: var(--bg-soft);
  font-size: 0.76rem;
  font-weight: 800;
  color: var(--ink-secondary);
  white-space: nowrap;
}

.choice-btn.active .choice-badge { background: var(--green-deep); color: #fff; }

.result-kcal-big {
  font-size: clamp(2.5rem, 5vw, 3.8rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.04em;
  background: linear-gradient(135deg, #ffffff 0%, #9be84d 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 8px 0 6px;
}

.result-sub-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  font-size: 0.86rem;
  color: rgba(255, 255, 255, 0.74);
  margin-bottom: 20px;
}

.result-macros {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 18px;
}

.result-macro-box {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 14px 8px;
  text-align: center;
}

.result-macro-box strong { display: block; font-size: 1.3rem; font-weight: 900; }
.result-macro-box span { display: block; font-size: 0.78rem; color: rgba(255, 255, 255, 0.74); margin-top: 2px; }
.result-macro-box em { font-style: normal; font-size: 0.73rem; color: #9be84d; font-weight: 700; }

.macro-bar-visual {
  display: flex;
  height: 10px;
  border-radius: var(--radius-pill);
  overflow: hidden;
  gap: 3px;
  margin-bottom: 18px;
}

.mb-p { background: #2ed46a; }
.mb-f { background: #ff9800; }
.mb-c { background: #38b6ff; }

.result-tip {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 14px;
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.88);
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.result-tip img {
  width: 48px;
  height: 48px;
  background: #fff;
  border-radius: 12px;
  padding: 4px;
  flex-shrink: 0;
}

/* ---------- Footer ---------- */
.site-footer {
  padding: 48px 0 32px;
  border-top: 1px solid var(--border);
  margin-top: 32px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 28px;
  margin-bottom: 30px;
}

.footer-col h4 {
  margin: 0 0 12px;
  font-size: 0.94rem;
  font-weight: 800;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 8px;
}

.footer-links a {
  font-size: 0.88rem;
  color: var(--ink-secondary);
}

.footer-links a:hover { color: var(--green-deep); }

.footer-bottom {
  padding-top: 20px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.82rem;
  color: var(--ink-muted);
}

/* ==========================================================================
   Responsive & Mobile Polish (Tablet <= 1024px, Mobile <= 768px, Small <= 480px)
   ========================================================================== */
@media (max-width: 1024px) {
  .hero-grid,
  .showcase-panel.active,
  .showcase-panel--single.active,
  .cta-banner,
  .calc-layout {
    grid-template-columns: 1fr;
  }

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

  .metrics-strip,
  .cards-3,
  .steps-grid,
  .bento-grid,
  .reviews-grid,
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .calc-result-card {
    position: static;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 16px;
  }

  .section {
    padding: 48px 0;
  }

  .section--tight {
    padding: 36px 0;
  }

  .hero {
    padding: 24px 0 36px;
  }

  .hero-grid {
    gap: 28px;
  }

  .main-nav {
    display: none;
  }

  .main-nav.open {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    position: fixed;
    top: 66px;
    left: 16px;
    right: 16px;
    background: #fff;
    padding: 14px;
    border-radius: 22px;
    box-shadow: 0 20px 50px rgba(14, 32, 25, 0.16);
    border: 1px solid var(--border);
    z-index: 120;
    gap: 4px;
  }

  .main-nav.open .nav-link {
    padding: 12px 16px;
    font-size: 1rem;
  }

  .header-actions .btn-outline {
    display: none;
  }

  .menu-toggle {
    display: inline-flex;
  }

  .pricing-grid,
  .metrics-strip,
  .cards-3,
  .steps-grid,
  .bento-grid,
  .reviews-grid,
  .analytics-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .showcase-shell {
    padding: 28px 16px;
    border-radius: 26px;
  }

  .showcase-tabs {
    width: 100%;
    border-radius: 18px;
    gap: 6px;
  }

  .showcase-tab {
    flex: 1 1 auto;
    padding: 9px 12px;
    font-size: 0.82rem;
    text-align: center;
  }

  .cabinet-body {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .cabinet-sidebar {
    display: none;
  }

  .cabinet-main {
    padding: 14px;
  }

  .cab-summary-card {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .cab-bars {
    width: 100%;
  }

  .cta-banner {
    padding: 32px 20px;
    border-radius: 26px;
    text-align: center;
  }

  .cta-banner-actions {
    justify-content: center;
  }

  .cta-mascot-card {
    width: 156px;
    height: 156px;
    border-radius: 30px;
  }

  .calc-card,
  .calc-result-card {
    padding: 22px 16px;
    border-radius: 24px;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 2rem;
  }

  .hero-cta-group .btn,
  .cta-banner-actions .btn {
    width: 100%;
  }

  .header-actions .btn-sm {
    padding: 8px 13px;
    font-size: 0.82rem;
  }

  .scanner-card {
    padding: 12px;
    border-radius: 24px;
  }

  .scanner-dish-row {
    flex-direction: column;
    gap: 8px;
  }

  .demo-chip {
    font-size: 0.72rem;
    padding: 7px 5px;
  }

  .cab-meal-row {
    flex-wrap: wrap;
  }

  .cab-meal-kcal {
    margin-left: auto;
  }

  .inputs-row-3 {
    grid-template-columns: 1fr;
  }

  .faq-q {
    padding: 16px 16px;
    font-size: 0.95rem;
  }

  .faq-a-inner {
    padding: 0 16px 16px;
  }
}
