:root {
  --bg: #f6f8f5;
  --bg-2: #edf2ee;
  --surface: rgba(255, 255, 255, 0.9);
  --surface-solid: #ffffff;
  --surface-soft: #f3f6f4;
  --stroke: #dce3de;
  --stroke-strong: #c7d2ca;
  --ink: #171d1a;
  --muted: #66716b;
  --brand-dark: #244b38;
  --brand: #dcefe3;
  --brand-strong: #3d8a5b;
  --brand-soft: #e8f6ec;
  --accent: #0f1512;
  --danger: #b13e3e;
  --warning: #c98e28;
  --star: #e0b84e;
  --shadow-lg: 0 24px 60px rgba(19, 34, 25, 0.08);
  --shadow-md: 0 12px 30px rgba(19, 34, 25, 0.06);
  --shadow-sm: 0 8px 16px rgba(19, 34, 25, 0.04);
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --header-h: 76px;
  --dock-h: 72px;
  --content-w: 1240px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family: "Trebuchet MS", "Segoe UI", system-ui, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 6% 10%, rgba(220, 239, 227, 0.75), transparent 42%),
    radial-gradient(circle at 92% 14%, rgba(61, 138, 91, 0.10), transparent 38%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
}

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

button {
  cursor: pointer;
}

a {
  color: inherit;
}

.bg-layer {
  position: fixed;
  inset: auto auto 0 0;
  pointer-events: none;
  z-index: 0;
  filter: blur(20px);
}

.bg-layer-a {
  width: 42vw;
  height: 42vw;
  min-width: 280px;
  min-height: 280px;
  border-radius: 999px;
  left: -10vw;
  top: 28vh;
  background: rgba(220, 239, 227, 0.75);
  animation: driftA 18s ease-in-out infinite;
}

.bg-layer-b {
  width: 34vw;
  height: 34vw;
  min-width: 220px;
  min-height: 220px;
  border-radius: 999px;
  right: -8vw;
  top: 6vh;
  background: rgba(36, 75, 56, 0.07);
  position: fixed;
  animation: driftB 22s ease-in-out infinite;
}

.bg-grid {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.22;
  background-image:
    linear-gradient(rgba(36, 75, 56, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(36, 75, 56, 0.03) 1px, transparent 1px);
  background-size: 28px 28px;
  mask-image: radial-gradient(circle at center, black 45%, transparent 95%);
}

.app-root {
  position: relative;
  z-index: 1;
}

.shell {
  width: min(var(--content-w), calc(100vw - 16px));
  margin: 0 auto;
  padding: 10px 8px 120px;
}

.topbar-wrap {
  position: sticky;
  top: 0;
  z-index: 40;
  padding-top: env(safe-area-inset-top, 0px);
}

.topbar {
  background: linear-gradient(180deg, rgba(36, 75, 56, 0.98), rgba(27, 57, 42, 0.98));
  color: #fff;
  border-radius: 18px;
  box-shadow: 0 16px 40px rgba(21, 45, 33, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.topbar-main {
  min-height: var(--header-h);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto auto;
  align-items: center;
  gap: 10px;
  padding: 12px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.brand-logo {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.10);
  border: 1px solid rgba(255, 255, 255, 0.12);
  object-fit: contain;
  padding: 5px;
  flex: 0 0 auto;
}

.brand-copy {
  min-width: 0;
}

.brand-name {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.02rem;
  font-weight: 700;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-sub {
  color: rgba(232, 246, 236, 0.86);
  font-size: 0.73rem;
}

.icon-btn,
.segment-btn,
.pill-btn,
.ghost-btn,
.primary-btn,
.secondary-btn,
.outline-btn,
.nav-btn,
.step-chip,
.filter-chip,
.choice-chip,
.small-chip,
.suggest-chip {
  border: 0;
  background: none;
}

.icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: inline-grid;
  place-items: center;
  color: rgba(232, 246, 236, 0.96);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: background-color .18s ease, transform .18s ease;
  position: relative;
}

.icon-btn:hover {
  background: rgba(255, 255, 255, 0.09);
}

.icon-btn:active {
  transform: translateY(1px);
}

.icon-badge {
  position: absolute;
  top: -3px;
  right: -3px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--brand);
  color: var(--brand-dark);
  font-size: 0.68rem;
  font-weight: 700;
  display: grid;
  place-items: center;
  border: 2px solid var(--brand-dark);
}

.icon-symbol {
  font-size: 1rem;
  line-height: 1;
}

.search-panel {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, rgba(24, 49, 37, 0.96), rgba(22, 44, 34, 0.96));
  padding: 12px;
  display: grid;
  gap: 10px;
  animation: revealDown .18s ease;
}

.search-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
}

.input {
  width: 100%;
  border: 1px solid var(--stroke);
  background: rgba(255, 255, 255, 0.95);
  border-radius: 12px;
  padding: 12px 13px;
  color: var(--ink);
  outline: none;
  transition: border-color .16s ease, box-shadow .16s ease;
}

.input:focus,
.textarea:focus,
.select:focus {
  border-color: rgba(36, 75, 56, 0.45);
  box-shadow: 0 0 0 4px rgba(36, 75, 56, 0.08);
}

.search-panel .input {
  background: #fff;
}

.primary-btn,
.secondary-btn,
.outline-btn,
.ghost-btn {
  border-radius: 12px;
  padding: 10px 14px;
  font-weight: 600;
  transition: transform .16s ease, filter .16s ease, background-color .16s ease, border-color .16s ease;
}

.primary-btn {
  background: var(--brand-dark);
  color: #fff;
  border: 1px solid rgba(36, 75, 56, 0.9);
  box-shadow: var(--shadow-sm);
}

.primary-btn:hover {
  filter: brightness(1.04);
}

.primary-btn:active {
  transform: translateY(1px);
}

.primary-btn[disabled] {
  opacity: .55;
  cursor: not-allowed;
  box-shadow: none;
}

.secondary-btn {
  background: #fff;
  border: 1px solid var(--stroke);
  color: var(--ink);
}

.outline-btn {
  background: var(--surface-soft);
  border: 1px solid var(--stroke-strong);
  color: var(--ink);
}

.ghost-btn {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: #fff;
}

.section-stack {
  display: grid;
  gap: 12px;
  margin-top: 10px;
}

.card {
  background: var(--surface);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.65);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.card-soft {
  background: rgba(255, 255, 255, 0.72);
}

.card-body {
  padding: 14px;
}

.hero-card {
  overflow: hidden;
  position: relative;
  border-radius: 22px;
  aspect-ratio: 21 / 10;
  min-height: 240px;
  box-shadow: 0 18px 48px rgba(16, 32, 24, 0.18);
}

.hero-media {
  position: absolute;
  inset: 0;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transform: scale(1.01);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(10, 14, 12, 0.15), rgba(10, 14, 12, 0.45)),
    linear-gradient(120deg, rgba(13, 21, 18, 0.72), rgba(13, 21, 18, 0.18));
}

.hero-content {
  position: relative;
  z-index: 1;
  height: 100%;
  min-height: 100%;
  display: grid;
  align-content: end;
  gap: 10px;
  padding: 16px;
  color: #fff;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: fit-content;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 0.72rem;
  font-weight: 700;
  background: rgba(220, 239, 227, 0.22);
  border: 1px solid rgba(220, 239, 227, 0.28);
  color: #f2fbf5;
}

.hero-title {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.2rem, 2.2vw, 1.55rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
  max-width: 18ch;
}

.hero-subtitle {
  margin: 0;
  color: rgba(246, 250, 247, 0.92);
  font-size: 0.9rem;
  line-height: 1.4;
  max-width: 58ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.hero-dots {
  display: inline-flex;
  gap: 6px;
  margin-left: auto;
}

.hero-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.38);
  background: rgba(255, 255, 255, 0.18);
  padding: 0;
}

.hero-dot.active {
  width: 20px;
  background: rgba(220, 239, 227, 0.92);
  border-color: rgba(220, 239, 227, 0.92);
}

.info-strip,
.insight-strip,
.chip-scroll,
.category-scroll,
.quick-scroll {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  scrollbar-width: thin;
  padding-bottom: 2px;
}

.info-mini,
.insight-mini {
  min-width: 170px;
  background: #fff;
  border: 1px solid var(--stroke);
  border-radius: 16px;
  padding: 12px;
  box-shadow: var(--shadow-sm);
}

.info-mini .bar,
.insight-mini .bar {
  width: 28px;
  height: 4px;
  border-radius: 999px;
  margin-bottom: 8px;
  background: var(--brand-strong);
}

.info-mini h4,
.insight-mini h4 {
  margin: 0 0 4px;
  font-size: 0.78rem;
  color: var(--muted);
  font-weight: 600;
}

.info-mini p,
.insight-mini p {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.3;
}

.insight-mini .value {
  margin-top: 4px;
  font-weight: 700;
  color: var(--ink);
}

.category-card {
  padding: 12px;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.8);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(250, 252, 251, 0.85));
}

.category-scroll {
  gap: 8px;
}

.category-chip {
  border: 1px solid var(--stroke);
  border-radius: 14px;
  padding: 10px 14px;
  white-space: nowrap;
  background: linear-gradient(180deg, #f5f7f6, #eef2ef);
  color: var(--muted);
  font-weight: 600;
  font-size: 0.9rem;
}

.category-chip.active {
  background: linear-gradient(90deg, var(--brand), #cee9d8);
  border-color: rgba(36, 75, 56, 0.18);
  color: var(--brand-dark);
  box-shadow: 0 8px 18px rgba(36, 75, 56, 0.12);
}

.filter-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.filter-chip,
.choice-chip,
.step-chip,
.small-chip,
.suggest-chip,
.pill-btn,
.segment-btn {
  border-radius: 999px;
  border: 1px solid var(--stroke);
  background: #fff;
  color: var(--muted);
  padding: 8px 10px;
  font-size: 0.8rem;
  font-weight: 600;
  white-space: nowrap;
  transition: all .16s ease;
}

.filter-chip.active,
.choice-chip.active,
.step-chip.active,
.small-chip.active,
.segment-btn.active,
.pill-btn.active {
  background: var(--brand);
  color: var(--brand-dark);
  border-color: rgba(36, 75, 56, 0.16);
}

.step-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.products-header {
  display: grid;
  gap: 10px;
}

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

.products-header-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
}

.products-header-controls {
  display: flex;
  gap: 8px;
  margin-left: auto;
  flex-wrap: wrap;
  align-items: center;
}

.select {
  border-radius: 12px;
  border: 1px solid var(--stroke);
  background: #fff;
  padding: 10px 12px;
  min-height: 42px;
}

.segment {
  display: inline-flex;
  border-radius: 12px;
  background: var(--brand-dark);
  border: 1px solid rgba(36, 75, 56, 0.8);
  overflow: hidden;
}

.segment-btn {
  border: 0;
  border-radius: 0;
  padding: 10px 12px;
  color: rgba(232, 246, 236, 0.85);
  background: transparent;
}

.segment-btn.active {
  background: rgba(220, 239, 227, 0.14);
  color: var(--brand);
}

.active-filter-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.small-chip {
  padding: 6px 10px;
  font-size: 0.73rem;
}

.products-grid {
  display: grid;
  gap: 12px;
}

.products-grid.list {
  grid-template-columns: 1fr;
}

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

.product-card {
  border-radius: 16px;
  border: 1px solid rgba(36, 75, 56, 0.06);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}

.product-card.in-cart {
  border-color: rgba(36, 75, 56, 0.22);
  box-shadow: 0 16px 28px rgba(36, 75, 56, 0.09);
}

.product-card:hover {
  transform: translateY(-2px);
}

.product-card-inner {
  display: grid;
  gap: 10px;
  padding: 12px;
}

.product-visual {
  position: relative;
  height: 116px;
  border-radius: 12px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(220,239,227,.75), rgba(233, 237, 241, .85));
  border: 1px solid rgba(255, 255, 255, 0.55);
}

.product-card.grid .product-visual {
  height: 102px;
}

.product-visual.pistachio img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.product-visual-demo {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #fff;
  background:
    radial-gradient(circle at 20% 20%, rgba(255,255,255,.17), transparent 40%),
    radial-gradient(circle at 80% 70%, rgba(255,255,255,.12), transparent 50%),
    linear-gradient(135deg, rgba(36,75,56,.65), rgba(46,60,52,.45));
}

.product-visual-demo .demo-badge {
  border-radius: 16px;
  padding: 10px 12px;
  background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.2);
  font-weight: 700;
  letter-spacing: .01em;
  font-size: .8rem;
}

.product-visual-top,
.product-visual-bottom {
  position: absolute;
  left: 8px;
  right: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.product-visual-top { top: 8px; }
.product-visual-bottom { bottom: 8px; }

.badge-row {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  background: rgba(255,255,255,.85);
  color: var(--ink);
  padding: 4px 8px;
  font-size: .68rem;
  font-weight: 700;
  border: 1px solid rgba(255,255,255,.85);
}

.badge-pill.discount {
  background: rgba(177, 62, 62, 0.12);
  color: var(--danger);
  border-color: rgba(177, 62, 62, 0.12);
}

.badge-pill.meta {
  background: rgba(255,255,255,.72);
  font-size: .66rem;
}

.favorite-btn {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.45);
  background: rgba(255,255,255,.72);
  display: grid;
  place-items: center;
  font-size: .9rem;
  color: #5f6863;
}

.favorite-btn.active {
  color: #c03b58;
  background: rgba(255, 240, 245, 0.9);
}

.product-name-btn {
  border: 0;
  background: none;
  text-align: left;
  padding: 0;
  margin: 0;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.25;
  font-size: 0.97rem;
}

.product-card.grid .product-name-btn {
  font-size: 0.9rem;
}

.product-desc {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.35;
}

.product-meta-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  font-size: 0.74rem;
  color: var(--muted);
}

.star {
  color: var(--star);
}

.stock-low {
  color: var(--warning);
  font-weight: 700;
}

.stock-ok {
  color: var(--brand-strong);
  font-weight: 700;
}

.price-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.price-block {
  flex: 1;
  min-width: 0;
}

.price-current {
  font-weight: 800;
  font-size: 1.02rem;
  line-height: 1.15;
}

.price-old,
.price-note {
  font-size: 0.73rem;
  color: var(--muted);
}

.price-note.savings {
  color: var(--brand-strong);
  font-weight: 700;
}

.discount-text {
  color: var(--brand-strong);
  font-weight: 800;
  font-size: 0.86rem;
}

.qty-panel {
  display: grid;
  gap: 8px;
}

.qty-row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 34px;
  align-items: center;
  gap: 6px;
  border-radius: 10px;
  border: 1px solid var(--stroke);
  background: #fff;
  padding: 4px;
}

.qty-btn {
  height: 34px;
  border-radius: 8px;
  border: 1px solid var(--stroke);
  background: var(--surface-soft);
  display: grid;
  place-items: center;
  font-size: 0.95rem;
}

.qty-label {
  border-radius: 8px;
  background: var(--surface-soft);
  text-align: center;
  padding: 8px;
  font-size: 0.76rem;
  font-weight: 700;
}

.line-total {
  border-radius: 10px;
  background: rgba(220, 239, 227, 0.3);
  border: 1px solid rgba(220, 239, 227, 0.65);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 10px;
  font-size: 0.78rem;
}

.line-total strong {
  color: var(--brand-dark);
}

.empty-state {
  padding: 16px;
  color: var(--muted);
  line-height: 1.4;
}

.empty-state h3 {
  margin: 0 0 8px;
  color: var(--ink);
}

.api-card-grid {
  display: grid;
  gap: 10px;
}

.api-header {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.api-title {
  margin: 0;
  font-size: 0.98rem;
  font-weight: 700;
}

.api-status {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.35;
}

.meta-pills {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.meta-pill {
  border-radius: 999px;
  padding: 6px 10px;
  background: var(--surface-soft);
  border: 1px solid var(--stroke);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 700;
}

.meta-pill.brand {
  background: rgba(220, 239, 227, 0.5);
  color: var(--brand-dark);
  border-color: rgba(36, 75, 56, 0.08);
}

.api-config-grid {
  display: grid;
  gap: 10px;
}

.api-config-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.dual-column {
  display: grid;
  gap: 12px;
}

.panel-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
}

.panel-sub {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.35;
}

.checkout-step-row,
.checkout-choice-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.checkout-card h4 {
  margin: 0 0 8px;
  font-size: 0.92rem;
}

.form-grid {
  display: grid;
  gap: 10px;
}

.form-grid.two {
  grid-template-columns: 1fr 1fr;
}

.field {
  display: grid;
  gap: 6px;
}

.field label {
  font-size: 0.78rem;
  color: var(--muted);
  font-weight: 700;
}

.textarea {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  background: #fff;
  padding: 12px 13px;
  min-height: 86px;
  resize: vertical;
}

.helper-box {
  border-radius: 14px;
  border: 1px solid var(--stroke);
  background: var(--surface-soft);
  padding: 12px;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.35;
}

.helper-box strong {
  color: var(--ink);
}

.cart-lines {
  display: grid;
  gap: 10px;
}

.cart-line {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  border-radius: 14px;
  background: var(--surface-soft);
  border: 1px solid var(--stroke);
  padding: 10px;
}

.cart-line-tag {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(220, 239, 227, 0.55);
  color: var(--brand-dark);
  font-size: 0.72rem;
  font-weight: 800;
  border: 1px solid rgba(36, 75, 56, 0.08);
}

.cart-line-main {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.cart-line-name {
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.25;
}

.cart-line-meta {
  color: var(--muted);
  font-size: 0.75rem;
}

.cart-line-controls {
  display: grid;
  gap: 6px;
  justify-items: end;
}

.cart-line-qty {
  display: grid;
  grid-template-columns: 30px auto 30px;
  gap: 4px;
  align-items: center;
}

.mini-icon-btn {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  border: 1px solid var(--stroke);
  background: #fff;
  display: grid;
  place-items: center;
}

.mini-text-btn {
  border: 1px solid rgba(177, 62, 62, 0.18);
  color: var(--danger);
  background: rgba(177, 62, 62, 0.06);
  border-radius: 8px;
  padding: 5px 8px;
  font-size: 0.7rem;
  font-weight: 700;
}

.progress-wrap {
  display: grid;
  gap: 8px;
}

.progress-track {
  height: 8px;
  border-radius: 999px;
  background: var(--surface-soft);
  border: 1px solid var(--stroke);
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #a5d5b8, #3d8a5b);
  width: 0%;
  transition: width .22s ease;
}

.summary-rows {
  display: grid;
  gap: 8px;
}

.summary-row {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 0.86rem;
  color: var(--muted);
}

.summary-row span:last-child {
  margin-left: auto;
  color: var(--ink);
}

.summary-row.emphasis {
  color: var(--ink);
  font-weight: 700;
}

.summary-row.emphasis span:last-child {
  font-size: 1rem;
}

.checkout-footer-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin-top: 10px;
}

.checkout-footer-actions.with-back {
  grid-template-columns: 1fr 1fr;
}

.recommended-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}

.reco-card {
  border: 1px solid var(--stroke);
  background: #fff;
  border-radius: 14px;
  padding: 10px;
  display: grid;
  gap: 8px;
}

.reco-title {
  margin: 0;
  font-size: 0.83rem;
  font-weight: 700;
  line-height: 1.25;
}

.reco-meta {
  color: var(--muted);
  font-size: 0.73rem;
}

.profile-grid {
  display: grid;
  gap: 12px;
}

.menu-list {
  display: grid;
  gap: 8px;
}

.menu-item {
  border: 1px solid rgba(36, 75, 56, 0.08);
  background: rgba(220, 239, 227, 0.42);
  border-radius: 14px;
  padding: 10px 12px;
  display: flex;
  gap: 10px;
  align-items: center;
  text-align: left;
}

.menu-item-copy {
  min-width: 0;
}

.menu-item-title {
  display: block;
  font-weight: 700;
  color: var(--brand-dark);
  font-size: 0.86rem;
}

.menu-item-sub {
  display: block;
  color: var(--muted);
  font-size: 0.75rem;
  margin-top: 2px;
}

.menu-item-arrow {
  margin-left: auto;
  color: var(--brand-dark);
}

.bottom-dock {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 50;
  padding: 0 max(10px, env(safe-area-inset-left)) max(8px, env(safe-area-inset-bottom)) max(10px, env(safe-area-inset-right));
  pointer-events: none;
}

.bottom-dock-inner {
  width: min(var(--content-w), calc(100vw - 16px));
  margin: 0 auto;
  display: grid;
  gap: 8px;
  pointer-events: auto;
}

.cart-cta-bar {
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(255, 255, 255, 0.85);
  border-radius: 16px;
  box-shadow: 0 14px 28px rgba(16, 32, 24, 0.10);
  padding: 10px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
}

.cart-cta-summary {
  border: 1px solid var(--stroke);
  background: var(--surface-soft);
  border-radius: 12px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.cart-cta-copy {
  min-width: 0;
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.bottom-nav {
  background: linear-gradient(180deg, rgba(36, 75, 56, 0.99), rgba(23, 47, 35, 0.99));
  border-radius: 16px;
  padding: 6px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 4px;
  box-shadow: 0 14px 28px rgba(16, 32, 24, 0.15);
}

.nav-btn {
  position: relative;
  display: grid;
  place-items: center;
  gap: 4px;
  border-radius: 12px;
  padding: 8px 6px;
  color: rgba(232, 246, 236, 0.84);
  font-size: 0.7rem;
  font-weight: 700;
}

.nav-btn .nav-icon {
  font-size: 0.95rem;
}

.nav-btn.active {
  background: rgba(220, 239, 227, 0.12);
  color: var(--brand);
}

.nav-badge {
  position: absolute;
  top: 4px;
  right: calc(50% - 18px);
  min-width: 16px;
  height: 16px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: var(--brand);
  color: var(--brand-dark);
  font-size: 0.62rem;
  padding: 0 4px;
  border: 1px solid rgba(36, 75, 56, 0.15);
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(14, 20, 16, 0.45);
  backdrop-filter: blur(4px);
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 14px;
  animation: fadeIn .16s ease;
}

.modal {
  width: min(860px, 100%);
  max-height: min(92vh, 860px);
  overflow: auto;
  border-radius: 22px;
  background: rgba(255,255,255,.96);
  border: 1px solid rgba(255,255,255,.85);
  box-shadow: 0 26px 64px rgba(11, 21, 16, 0.24);
}

.modal-header {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: linear-gradient(180deg, rgba(36, 75, 56, 0.98), rgba(27, 57, 42, 0.98));
  color: #fff;
}

.modal-title {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 700;
  margin: 0;
  font-size: 1rem;
}

.modal-body {
  padding: 14px;
  display: grid;
  gap: 12px;
}

.modal-hero {
  border-radius: 18px;
  overflow: hidden;
  min-height: 240px;
  border: 1px solid var(--stroke);
  background: linear-gradient(135deg, #e7efe9, #f8faf9);
  position: relative;
}

.modal-hero img {
  width: 100%;
  height: 100%;
  min-height: 240px;
  object-fit: cover;
  display: block;
}

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

.modal-meta-box {
  border-radius: 14px;
  background: var(--surface-soft);
  border: 1px solid var(--stroke);
  padding: 12px;
}

.modal-meta-box .label {
  color: var(--muted);
  font-size: 0.73rem;
  font-weight: 700;
}

.modal-meta-box .value {
  margin-top: 4px;
  font-weight: 700;
}

.modal-price-bar {
  border-radius: 16px;
  background: #fff;
  border: 1px solid var(--stroke);
  padding: 12px;
  display: grid;
  gap: 10px;
}

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

.modal-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.toast-stack {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 80;
  display: grid;
  gap: 8px;
  width: min(420px, calc(100vw - 24px));
  pointer-events: none;
}

.toast {
  pointer-events: auto;
  border-radius: 14px;
  background: rgba(18, 28, 22, 0.94);
  color: #f0f7f3;
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 14px 28px rgba(16, 32, 24, 0.2);
  padding: 12px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  animation: toastIn .18s ease;
}

.toast-icon {
  width: 20px;
  height: 20px;
  border-radius: 999px;
  background: rgba(220, 239, 227, 0.2);
  display: grid;
  place-items: center;
  font-size: 0.75rem;
}

.toast-message {
  font-size: 0.82rem;
  line-height: 1.35;
}

.toast-close {
  pointer-events: auto;
  color: rgba(240,247,243,.82);
  background: transparent;
  border: 0;
  width: 22px;
  height: 22px;
  border-radius: 8px;
}

.state-note {
  color: var(--muted);
  font-size: .78rem;
  line-height: 1.35;
}

.noscript-card {
  max-width: 560px;
  margin: 40px auto;
  background: #fff;
  border: 1px solid var(--stroke);
  border-radius: 16px;
  box-shadow: var(--shadow-md);
  padding: 18px;
}

.hidden {
  display: none !important;
}

.kbd {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.6em;
  padding: 2px 6px;
  border-radius: 8px;
  border: 1px solid var(--stroke);
  background: #fff;
  font-size: .72rem;
  font-weight: 700;
  color: var(--muted);
}

@keyframes driftA {
  0%, 100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(22px, -18px, 0); }
}

@keyframes driftB {
  0%, 100% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(-18px, 20px, 0); }
}

@keyframes revealDown {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes toastIn {
  from { opacity: 0; transform: translateY(-4px) scale(.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (min-width: 860px) {
  .shell {
    padding-top: 12px;
    padding-bottom: 132px;
  }

  .section-stack {
    gap: 14px;
  }

  .hero-card {
    aspect-ratio: 3 / 1;
    min-height: 340px;
  }

  .hero-content {
    height: 100%;
    min-height: 100%;
    padding: 20px;
    gap: 12px;
  }

  .hero-title {
    font-size: clamp(1.35rem, 2vw, 1.9rem);
  }

  .hero-subtitle {
    font-size: 0.95rem;
    max-width: 64ch;
  }

  .dual-column {
    grid-template-columns: minmax(0, 1.45fr) minmax(340px, 0.95fr);
    align-items: start;
  }

  .sticky-col {
    position: sticky;
    top: 92px;
  }

  .api-card-grid {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
  }

  .bottom-dock-inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .checkout-footer-actions,
  .checkout-footer-actions.with-back {
    grid-template-columns: 1fr 1fr;
  }

  .products-grid.list .product-card-inner {
    grid-template-columns: 220px minmax(0, 1fr);
    align-items: start;
    gap: 12px;
  }

  .products-grid.list .product-card-main {
    display: grid;
    gap: 10px;
  }

  .products-grid.list .product-visual {
    height: 152px;
  }

  .form-grid.two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .modal-body {
    grid-template-columns: 1.15fr .95fr;
    align-items: start;
  }

  .modal-side {
    position: sticky;
    top: 74px;
    display: grid;
    gap: 12px;
  }
}

@media (max-width: 859px) {
  .topbar-main {
    grid-template-columns: minmax(0, 1fr) auto auto auto;
  }

  .brand-sub {
    display: none;
  }

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

  .form-grid.two,
  .modal-meta-grid {
    grid-template-columns: 1fr;
  }

  .cart-line {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .cart-line-tag {
    display: none;
  }

  .cart-line-controls {
    justify-items: stretch;
  }

  .cart-line-qty {
    grid-template-columns: 34px minmax(0, 1fr) 34px;
  }
}

@media (max-width: 640px) {
  .shell {
    width: calc(100vw - 10px);
    padding: 6px 4px 118px;
  }

  .topbar {
    border-radius: 14px;
  }

  .topbar-main {
    padding: 10px;
    gap: 8px;
  }

  .brand-name {
    font-size: .92rem;
  }

  .hero-card {
    border-radius: 18px;
    aspect-ratio: 16 / 10;
    min-height: 220px;
  }

  .hero-content {
    height: 100%;
    min-height: 100%;
    padding: 14px;
  }

  .hero-title {
    max-width: 100%;
  }

  .hero-actions {
    align-items: flex-start;
  }

  .hero-dots {
    margin-left: 0;
  }

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

  .products-header-controls {
    width: 100%;
    margin-left: 0;
  }

  .products-header-controls .select {
    flex: 1;
    min-width: 0;
  }

  .checkout-footer-actions.with-back {
    grid-template-columns: 1fr;
  }

  .cart-cta-bar {
    grid-template-columns: 1fr;
  }

  .bottom-nav {
    border-radius: 14px;
  }

  .toast-stack {
    top: auto;
    right: 10px;
    left: 10px;
    bottom: calc(86px + env(safe-area-inset-bottom, 0px));
    width: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
