@font-face {
  font-family: "Arial Geo";
  src: url("../arial_geo.ttf") format("truetype");
  font-style: normal;
  font-weight: normal;
  font-display: swap;
}

:root {
  --bg: #f5f5f5;
  --surface: #ffffff;
  --surface-muted: #f0f0f0;
  --ink: #111111;
  --ink-muted: #666666;
  --line: #e0e0e0;
  --line-strong: #c8c8c8;
  --accent: #00783C;
  --accent-dark: #005A2D;
  --accent-light: #E5F2EC;
  --danger: #dc2626;
  --radius-xl: 12px;
  --radius-lg: 8px;
  --radius-md: 6px;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.07);
  --shadow-md: 0 2px 10px rgba(0, 0, 0, 0.09);
  --shadow-lg: 0 6px 24px rgba(0, 0, 0, 0.11);
  --font-sans: "Arial Geo", Arial, sans-serif;
  --text-body: 15px;
  --text-title-xl: clamp(1.6rem, 5vw, 2.45rem);
  --text-title: clamp(1rem, 2.8vw, 1.36rem);
  --text-subtitle: 0.93rem;
  --text-meta: 0.84rem;
  --text-label: 0.75rem;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--text-body);
  line-height: 1.45;
  color: var(--ink);
  background: var(--bg);
  min-height: 100%;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  margin: 0;
}

h1,
h2,
h3,
h4,
.brand-word {
  margin: 0;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

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

.site-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

[data-shared-header],
[data-shared-footer] {
  display: contents;
}

.page-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: #ffffff;
  border-bottom: 1px solid #e0e0e0;
  box-shadow: none;
}

.header-inner,
.main-inner,
.footer-inner,
.flow-inner {
  width: min(1100px, calc(100vw - 24px));
  margin: 0 auto;
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.94rem;
  font-weight: 800;
}

.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 6px;
  background: #00783C;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: none;
  font-size: 0.88rem;
  font-weight: 900;
  color: #ffffff;
  letter-spacing: -0.02em;
}

.brand-mark::after {
  content: 'M';
}

.top-nav,
.nav-link {
  display: none;
}

.header-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.header-actions > .btn.btn-inline,
.header-actions > .cart-chip,
.header-actions .session-profile-link {
  min-height: 36px;
  height: 36px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 0 12px;
}

.nav-back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.cart-chip {
  min-width: 58px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.cart-icon {
  width: 17px;
  height: 17px;
}

.cart-count {
  min-width: 18px;
  height: 18px;
  border-radius: 999px;
  background: var(--surface-muted);
  border: 1px solid var(--line);
  font-size: 0.71rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

.session {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.session-badge {
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface-muted);
  color: #414754;
  font-size: 0.76rem;
  font-weight: 800;
  padding: 6px 10px;
}

.session-badge.is-clickable {
  cursor: pointer;
}

.session-profile-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 58px;
}

.session-profile-link .icon {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
}

.flow-strip {
  position: sticky;
  top: 74px;
  z-index: 49;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
}

.flow-inner {
  min-height: 46px;
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
}

.flow-step {
  white-space: nowrap;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  cursor: pointer;
  transition: opacity 0.15s ease;
  color: var(--ink-muted);
  font-size: 0.78rem;
  font-weight: 800;
  padding: 6px 10px;
}

.flow-step.done {
  color: var(--accent);
  border-color: #bbddd0;
  background: #f0faf5;
}

.flow-step.done:hover {
  background: #d8f2e7;
}

.flow-step.active {
  color: #fff;
  border-color: var(--accent);
  background: var(--accent);
}

.flow-step.active:hover {
  opacity: 0.88;
}

.flow-step:not(.done):not(.active):hover {
  background: var(--surface-muted);
  border-color: var(--line-strong);
}

.page-main {
  padding: 28px 0 60px;
  flex: 1;
}

.grid {
  display: grid;
  gap: 16px;
}

.hero {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  padding: 28px;
  box-shadow: none;
  display: grid;
  gap: 12px;
}

.page-home {
  background: #fff;
}

.page-home .hero {
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--ink);
}

.page-home .hero p {
  color: var(--ink-muted);
}

.page-home .home-hero {
  padding: 0;
  border: 0;
  background: transparent;
  border-radius: 0;
}

.home-hero-eyebrow-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 14px 7px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(8px);
  width: fit-content;
}

.home-hero-eyebrow-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 6px #4ade80;
  flex-shrink: 0;
  animation: pulse-dot 2.5s ease infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.home-hero-eyebrow-text {
  font-size: 0.84rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.92);
  letter-spacing: 0.02em;
}

/* deprecated — kept for i18n safety */
.home-hero-eyebrow {
  margin: 0;
  font-size: 0.84rem;
  font-weight: 700;
  color: rgba(255,255,255,0.8);
  letter-spacing: 0.04em;
}

/* Scroll hint indicator at bottom of hero */
.home-hero-scroll-hint {
  position: absolute;
  bottom: 36px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.home-hero-scroll-line {
  display: block;
  width: 1.5px;
  height: 48px;
  background: linear-gradient(to bottom, rgba(255,255,255,0.7), rgba(255,255,255,0));
  animation: scroll-pulse 2s ease-in-out infinite;
}

@keyframes scroll-pulse {
  0%, 100% { opacity: 0.8; transform: scaleY(1); }
  50% { opacity: 0.3; transform: scaleY(0.6); }
}

.home-hero-title {
  color: #fff;
  text-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.home-hero-sub {
  margin: 0;
  color: rgba(255,255,255,0.9);
  font-size: clamp(1rem, 1.8vw, 1.14rem);
  line-height: 1.5;
  max-width: 42ch;
}

/* How It Works Section */
.home-steps-section {
  padding: 80px 0;
  background: var(--bg);
}

.home-steps-header {
  text-align: center;
  margin-bottom: 56px;
  display: grid;
  gap: 12px;
}

.home-steps-eyebrow {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.home-steps-title {
  margin: 0;
  font-size: clamp(1.8rem, 3.5vw, 3rem);
  font-weight: 800;
  color: var(--ink);
  letter-spacing: -0.03em;
  line-height: 1.05;
}

.step-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: var(--accent-light);
  border: none;
  display: grid;
  place-items: center;
  color: var(--accent);
  margin-bottom: 10px;
}

.step-icon svg {
  width: 26px;
  height: 26px;
}

.step-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 800;
  color: var(--accent);
  text-decoration: none;
  margin-top: 8px;
  padding: 8px 16px;
  border-radius: 6px;
  background: var(--accent-light);
  border: 1px solid #c0ddd0;
  transition: background 0.16s ease, gap 0.16s ease;
}

.step-link:hover {
  color: var(--accent-dark);
  background: #d4ede3;
  gap: 10px;
}

.page-home .home-hero-media {
  position: relative;
  min-height: 68svh;
  min-height: 68vh;
  overflow: hidden;
  display: grid;
  align-items: center;
  background:
    linear-gradient(120deg, rgba(0, 55, 22, 0.91) 0%, rgba(0, 80, 32, 0.70) 42%, rgba(0, 110, 50, 0.22) 100%),
    url("../img/bg.jpeg") center 45% / cover no-repeat;
}

.page-home .home-hero-content {
  position: relative;
  z-index: 2;
  max-width: min(780px, 92vw);
  padding: clamp(40px, 5vh, 60px) clamp(28px, 6vw, 96px) clamp(40px, 5vh, 60px) clamp(48px, 15vw, 280px);
  color: #fff;
  display: grid;
  gap: 24px;
}

.page-home .home-hero-content .title-xl {
  font-size: clamp(1.9rem, 3.4vw, 2.9rem);
  line-height: 1.08;
  max-width: none;
  letter-spacing: -0.03em;
}

.page-home .home-hero-content p {
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(1rem, 1.8vw, 1.2rem);
  line-height: 1.5;
  max-width: 42ch;
}

.page-home .home-hero-actions {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.page-home .home-hero-btn {
  min-height: 56px;
  height: 56px;
  border-width: 1px;
}

a.home-hero-btn {
  box-sizing: border-box !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: 56px !important;
  padding: 0 34px !important;
  border-radius: 999px !important;
  border: 1.5px solid transparent !important;
  font-family: var(--font-sans) !important;
  font-size: 0.94rem !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  white-space: nowrap !important;
  cursor: pointer !important;
  text-decoration: none !important;
  letter-spacing: 0.01em !important;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease !important;
}

a.home-hero-btn.btn-primary {
  background: #ffffff !important;
  border-color: #ffffff !important;
  color: var(--accent) !important;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.22) !important;
}

a.home-hero-btn.btn-primary:hover {
  background: #f0f9f4 !important;
  transform: translateY(-2px) !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28) !important;
}

a.home-hero-btn.btn-secondary {
  background: rgba(255, 255, 255, 0.12) !important;
  border-color: rgba(255, 255, 255, 0.65) !important;
  color: #fff !important;
  backdrop-filter: blur(6px) !important;
}

a.home-hero-btn.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.22) !important;
  transform: translateY(-2px) !important;
}

.page-home .home-step-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.page-home .home-step-card {
  border-radius: 10px;
  padding: 32px 28px 28px;
  position: relative;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
  overflow: hidden;
}

.page-home .home-step-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}

.page-home .home-step-card::before {
  content: attr(data-step);
  position: absolute;
  top: 24px;
  right: 24px;
  width: 40px;
  height: 40px;
  border-radius: 6px;
  background: var(--accent);
  color: #fff;
  font-size: 1rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: none;
}

.page-home .home-step-card .section-title {
  font-size: clamp(1.3rem, 2vw, 1.75rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.page-home .home-step-card .section-subtitle {
  margin-top: 10px;
  font-size: 0.95rem;
  line-height: 1.55;
}

.hero p {
  margin: 0;
  max-width: 64ch;
  color: var(--ink-muted);
  font-size: var(--text-subtitle);
  line-height: 1.5;
}

.page-hero {
  background: #ffffff;
  border-radius: 8px;
  border: 1px solid #e0e0e0;
  padding: 32px 28px;
  position: relative;
  overflow: hidden;
}

.page-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(to bottom, var(--accent), var(--accent-dark));
  border-radius: 4px 0 0 4px;
}

.page-hero .title-xl {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  line-height: 1.08;
  letter-spacing: -0.025em;
}

.page-hero-eyebrow {
  margin: 0 0 8px;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
}

.title-xl {
  font-size: var(--text-title-xl);
  line-height: 0.98;
}

.section-title {
  font-size: var(--text-title);
  line-height: 1.1;
  letter-spacing: -0.015em;
}

.section-subtitle {
  margin: 6px 0 0;
  color: var(--ink-muted);
  font-size: var(--text-subtitle);
  line-height: 1.42;
}

.actions-row,
.controls-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

/* ===== ICONS ===== */
.icon {
  display: inline-block;
  width: 1em;
  height: 1em;
  vertical-align: -0.14em;
  flex-shrink: 0;
}

/* Icon inside buttons — flex layout */
.btn {
  border: none;
  border-radius: 6px;
  padding: 12px 18px;
  font-family: inherit;
  font-size: 0.88rem;
  font-weight: 800;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: background 0.15s ease, transform 0.15s ease;
}

.btn:disabled {
  opacity: 0.56;
  cursor: not-allowed;
}

.btn-primary {
  background: #00783C;
  color: #fff;
  border: none;
  transition: background 0.16s ease;
}

.btn-primary:hover:not(:disabled) {
  background: #005A2D;
  transform: none;
  box-shadow: none;
}

.btn-secondary {
  background: #fff;
  color: var(--ink);
  border: 1.5px solid var(--line-strong);
  transition: border-color 0.18s ease, background 0.18s ease;
}

.btn-secondary:hover:not(:disabled) {
  border-color: var(--accent);
  background: var(--accent-light);
}

.btn-danger {
  background: #fff1ef;
  color: #a92d21;
  border: 1px solid #efc1bb;
}

.btn-inline {
  padding: 7px 10px;
  border-radius: 9px;
  font-size: 0.78rem;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 14px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.box-card {
  display: grid;
  gap: 10px;
  cursor: pointer;
}

.page-box #boxTypeGrid {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 28px;
}

.page-box .box-card {
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 10px;
  padding: 32px 24px 24px;
  gap: 0;
  box-shadow: none;
  cursor: pointer;
  text-align: center;
  position: relative;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
  position: relative;
  overflow: hidden;
}

.page-box .box-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 80% 55% at 50% -5%, rgba(21,145,90,0.07) 0%, transparent 70%);
  pointer-events: none;
}

.page-box .box-card:hover {
  border-color: var(--accent);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.10);
  transform: translateY(-4px);
}

.page-box .box-card:hover .box-carton {
  filter: drop-shadow(0 18px 36px rgba(36, 16, 2, 0.42));
}

.box-carton {
  position: relative;
  height: 240px;
  perspective: 700px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  filter: drop-shadow(0 12px 24px rgba(36, 16, 2, 0.32));
  transition: filter 0.28s ease;
}

.box-3d {
  --bw: 170px;
  --bh: 126px;
  --bd: 118px;
  width: var(--bw);
  height: var(--bh);
  position: relative;
  transform-style: preserve-3d;
  transform: rotateX(-22deg) rotateY(42deg);
  transition: transform 0.3s ease;
}

.box-face {
  position: absolute;
  box-sizing: border-box;
  border: 1px solid rgba(50, 20, 2, 0.3);
  transform-style: preserve-3d;
}

.box-face-front {
  width: var(--bw);
  height: var(--bh);
  transform: translateZ(calc(var(--bd) / 2));
  background:
    repeating-linear-gradient(
      0deg,
      rgba(255,255,255,0.055) 0px, rgba(255,255,255,0.055) 1px,
      rgba(0,0,0,0.055) 1px, rgba(0,0,0,0.055) 2px,
      transparent 2px, transparent 6px
    ),
    linear-gradient(180deg, #d4a460 0%, #ae8040 100%);
  padding: 14px 14px 12px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.box-face-top {
  width: var(--bw);
  height: var(--bh);
  transform: rotateY(180deg) translateZ(calc(var(--bd) / 2));
  background: linear-gradient(180deg, #a87038 0%, #7e5018 100%);
}

.box-right {
  width: var(--bd);
  height: var(--bh);
  transform: rotateY(90deg) translateZ(calc(var(--bw) / 2));
  left: calc((var(--bw) - var(--bd)) / 2);
  background:
    repeating-linear-gradient(
      0deg,
      rgba(255,255,255,0.03) 0px, rgba(255,255,255,0.03) 1px,
      rgba(0,0,0,0.08) 1px, rgba(0,0,0,0.08) 2px,
      transparent 2px, transparent 6px
    ),
    linear-gradient(180deg, #7a5220 0%, #4e3008 100%);
}

.box-left {
  width: var(--bd);
  height: var(--bh);
  transform: rotateY(-90deg) translateZ(calc(var(--bw) / 2));
  left: calc((var(--bw) - var(--bd)) / 2);
  background:
    repeating-linear-gradient(
      0deg,
      rgba(255,255,255,0.055) 0px, rgba(255,255,255,0.055) 1px,
      rgba(0,0,0,0.055) 1px, rgba(0,0,0,0.055) 2px,
      transparent 2px, transparent 6px
    ),
    linear-gradient(180deg, #d4a460 0%, #ae8040 100%);
}

.box-bottom {
  width: var(--bw);
  height: var(--bd);
  transform: rotateX(-90deg) translateZ(calc(var(--bh) / 2));
  top: calc((var(--bh) - var(--bd)) / 2);
  background: linear-gradient(180deg, #6e4a1a 0%, #4a2e08 100%);
}

.box-flap {
  position: absolute;
  width: 100%;
  height: calc(var(--bd) / 2);
  bottom: 100%;
  left: 0;
  transform-origin: bottom center;
  box-sizing: border-box;
  border: 1px solid rgba(50, 20, 2, 0.3);
  border-bottom: none;
}

.box-face-front .box-flap {
  transform: rotateX(50deg);
  background:
    repeating-linear-gradient(
      0deg,
      rgba(255,255,255,0.07) 0px, rgba(255,255,255,0.07) 1px,
      rgba(0,0,0,0.05) 1px, rgba(0,0,0,0.05) 2px,
      transparent 2px, transparent 6px
    ),
    linear-gradient(180deg, #d4a460 0%, #ae8040 100%);
}

.box-face-top .box-flap {
  transform: rotateX(50deg);
  background: linear-gradient(180deg, #bc9048 0%, #966c28 100%);
}

.box-name {
  font-size: 1.16rem;
  font-weight: 800;
  color: #fff8e4;
  line-height: 1.1;
  letter-spacing: -0.01em;
  text-shadow: 0 1px 3px rgba(42, 18, 1, 0.45);
  overflow-wrap: anywhere;
}

.box-marks {
  display: flex;
  gap: 14px;
}

.box-mark-list {
  display: flex;
  flex-wrap: nowrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 14px;
}

.box-stamp {
  align-self: flex-start;
  padding: 4px 8px;
  border: 1px solid rgba(71, 28, 4, 0.36);
  border-radius: 999px;
  color: rgba(255, 247, 218, 0.9);
  font-size: 0.56rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.box-mark {
  display: grid;
  gap: 1px;
  min-width: 0;
}

.box-mark-label {
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 240, 196, 0.5);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.box-mark-value {
  font-size: 0.84rem;
  font-weight: 800;
  color: rgba(255, 247, 218, 0.92);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  overflow-wrap: anywhere;
}

.page-box .box-caption {
  margin-top: 20px;
  padding: 20px 4px 0;
  border-top: 1px solid #e4ede8;
  display: grid;
  gap: 6px;
}

.page-box .box-caption .section-title {
  font-size: 1.22rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.page-box .box-caption .section-subtitle {
  margin: 0;
  font-size: 0.88rem;
  color: var(--ink-muted);
  line-height: 1.45;
}

/* Price badge — top-left green pill */
.box-price-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--accent);
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.01em;
  padding: 5px 10px;
  border-radius: 999px;
  z-index: 1;
}

.box-price-badge .icon {
  width: 12px;
  height: 12px;
  opacity: 0.9;
}

/* Spec grid below box name */
.box-spec-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 12px;
  margin-top: 12px;
  justify-items: center;
}

.box-spec {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--ink-muted);
}

.box-spec .icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  color: var(--accent);
  opacity: 0.85;
}

/* "Select" affordance — green arrow pill shown on hover */
.page-box .box-caption::after {
  content: '';
  display: block;
  width: 36px;
  height: 4px;
  border-radius: 999px;
  background: var(--accent);
  margin: 10px auto 0;
  opacity: 0;
  transform: scaleX(0.5);
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.page-box .box-card:hover .box-caption::after {
  opacity: 1;
  transform: scaleX(1);
}

.page-box .box-card:hover .box-3d,
.page-box .box-card:focus-visible .box-3d {
  transform: rotateX(-22deg) rotateY(47deg);
}

.box-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--ink-muted);
  font-size: 0.78rem;
}

.metric-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  padding: 5px 10px;
}

.metric-pill .icon {
  width: 0.95rem;
  height: 0.95rem;
  flex: 0 0 auto;
}

.inline-message {
  min-height: 20px;
  margin-top: 8px;
  font-size: 0.84rem;
  font-weight: 700;
}

.inline-error {
  color: #9c2317;
}

.inline-success {
  color: #276d4a;
}

.inline-info {
  color: #4f5863;
}

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

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

label {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: var(--text-label);
  font-weight: 800;
  color: #59616d;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

label .icon {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
  color: var(--accent);
  opacity: 0.8;
}

input,
select,
textarea {
  width: 100%;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  padding: 10px 12px;
  font-family: inherit;
  font-size: 0.88rem;
}

input:focus,
select:focus,
textarea:focus {
  outline: 2px solid rgba(21, 145, 90, 0.18);
  border-color: rgba(21, 145, 90, 0.42);
}

.footer {
  background: #1a2e1a;
  border-top: none;
  color: #d1d5db;
  margin-top: auto;
}

.footer-inner {
  padding: 72px 0 36px;
  font-size: 0.88rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 60px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.footer-brand {
  display: grid;
  gap: 12px;
}

.footer-brand-name {
  font-size: 1.1rem;
  font-weight: 800;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-brand-mark {
  width: 30px;
  height: 30px;
  border-radius: 6px;
  background: #00783C;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.78rem;
  font-weight: 900;
  color: rgba(255,255,255,0.92);
}

.footer-brand-mark::after {
  content: 'M';
}

.footer-tagline {
  color: #9ca3af;
  line-height: 1.65;
  max-width: 28ch;
  font-size: 0.9rem;
}

.footer-col-title {
  font-weight: 800;
  color: #fff;
  font-size: 0.84rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin: 0 0 14px;
}

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

.footer-links a {
  color: #9ca3af;
  text-decoration: none;
  transition: color 0.15s ease;
  font-size: 0.88rem;
}

.footer-links a:hover {
  color: #6ee7b7;
}

.footer-contact-item {
  color: #9ca3af;
  font-size: 0.88rem;
  line-height: 1.5;
}

.footer-bottom {
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  color: #6b7280;
  font-size: 0.8rem;
}

/* ----- Features strip ----- */
.features-strip {
  background: #fff;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.features-strip-inner {
  width: min(1100px, 92vw);
  margin: 0 auto;
  padding: 56px 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px;
}

.feature-item {
  display: flex;
  align-items: flex-start;
  gap: 18px;
}

.feature-icon {
  width: 56px;
  height: 56px;
  border-radius: 10px;
  background: var(--accent-light);
  border: none;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: var(--accent);
  transition: background 0.2s ease, transform 0.2s ease;
}

.feature-item:hover .feature-icon {
  background: #d0f0e3;
  transform: scale(1.05);
}

.feature-icon svg {
  width: 28px;
  height: 28px;
}

.feature-text {
  display: grid;
  gap: 6px;
  padding-top: 4px;
}

.feature-title {
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--ink);
  letter-spacing: -0.01em;
}

.feature-desc {
  font-size: 0.9rem;
  color: var(--ink-muted);
  line-height: 1.45;
}

/* ----- CTA Banner ----- */
.cta-banner {
  background: linear-gradient(135deg, #003D20 0%, #00783C 60%, #009A4D 100%);
  color: #fff;
  position: relative;
  overflow: hidden;
}

.cta-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 80% at 80% 50%, rgba(255,255,255,0.07) 0%, transparent 70%);
  pointer-events: none;
}

.cta-banner-inner {
  width: min(1100px, 92vw);
  margin: 0 auto;
  padding: 72px 0;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 40px;
  position: relative;
  z-index: 1;
}

.cta-banner-copy {
  display: grid;
  gap: 12px;
}

.cta-banner-title {
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 800;
  line-height: 1.05;
  color: #fff;
  letter-spacing: -0.03em;
}

.cta-banner-subtitle {
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.05rem;
  line-height: 1.5;
  max-width: 44ch;
}

.cta-banner .btn {
  background: #fff;
  color: var(--accent);
  font-weight: 800;
  padding: 16px 32px;
  border-radius: 6px;
  white-space: nowrap;
  border: none;
  font-size: 0.96rem;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.18);
  transition: background 0.16s ease, transform 0.16s ease;
}

.cta-banner .btn:hover {
  background: #f0f9f4;
  transform: translateY(-2px);
}

.bottom-sheet-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(12, 13, 15, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 109;
}

.bottom-sheet {
  position: fixed;
  inset: auto 0 0;
  max-height: min(90vh, 980px);
  padding-bottom: env(safe-area-inset-bottom);
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  border-radius: 22px 22px 0 0;
  border-top: 1px solid var(--line);
  background: #fff;
  box-shadow: 0 -18px 40px rgba(0, 0, 0, 0.22);
  transform: translateY(100%);
  transition: transform 0.23s ease;
  z-index: 110;
}

.bottom-sheet.open {
  transform: translateY(0);
}

.bottom-sheet.open + .bottom-sheet-backdrop {
  opacity: 1;
  pointer-events: all;
}

.image-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(10, 12, 18, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px;
  opacity: 0;
  pointer-events: none;
  z-index: 120;
}

.image-lightbox.open {
  opacity: 1;
  pointer-events: all;
}

.image-lightbox img {
  max-width: min(92vw, 960px);
  max-height: 82vh;
  border-radius: 18px;
  object-fit: contain;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.35);
}

.image-lightbox-close {
  position: absolute;
  top: 18px;
  right: 18px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border-radius: 999px;
  padding: 10px 14px;
  cursor: pointer;
}

.sheet-inner {
  width: min(700px, 94vw);
  margin: 0 auto;
  padding: 20px 0 26px;
}

.product-details-skeleton {
  padding: 20px;
  text-align: center;
}

.product-details-layout {
  display: grid;
  gap: 16px;
}

.product-details-gallery {
  display: grid;
  gap: 10px;
}

.product-details-main-image,
.product-details-single-image {
  width: 100%;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  padding: 0;
  background: #fff;
  display: block;
  cursor: zoom-in;
  touch-action: manipulation;
  appearance: none;
  -webkit-appearance: none;
}

.product-details-main-image {
  max-width: min(420px, 90vw);
  margin: 0 auto;
  aspect-ratio: 1 / 1;
}

.product-details-main-image img,
.product-details-single-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  padding: 14px;
  display: block;
}

.product-details-thumbs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
}

.product-details-thumb {
  width: 64px;
  height: 64px;
  flex: 0 0 64px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #fff;
  padding: 0;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.product-details-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 6px;
}

.product-details-thumb.is-active {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-light);
}

.product-details-single-image {
  width: 100%;
  max-width: min(360px, 88vw);
  margin: 0 auto;
}

.product-details-single-image .product-media {
  min-height: 200px;
  height: 220px;
  border: 0;
}

.product-details-single-image .product-media img {
  object-fit: contain;
  padding: 14px;
}

.product-details-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  flex-wrap: wrap;
}

.product-details-brand {
  font-size: 1rem;
  margin-bottom: 4px;
}

.product-details-price-stack {
  text-align: right;
  align-items: flex-end;
}

.product-details-price-stack .price-main,
.product-details-price-stack .price-sale {
  font-size: 1.4rem;
}

.product-details-price-stack .price-old {
  font-size: 1rem;
}

.product-details-cta {
  margin-top: 2px;
}

.product-details-cta .btn {
  width: 100%;
  min-height: 48px;
  font-size: 1rem;
  padding: 13px 14px;
}

.product-details-section {
  border-top: 1px solid var(--line);
  padding-top: 16px;
  display: grid;
  gap: 10px;
}

.product-details-section-title {
  margin: 0;
  font-size: 1.1rem;
  line-height: 1.3;
}

.product-details-section-body {
  margin: 0;
  color: var(--ink-muted);
  line-height: 1.55;
  word-break: break-word;
}

.product-details-params {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 10px;
}

.product-details-param {
  display: grid;
  grid-template-columns: minmax(130px, 1fr) minmax(0, 1.4fr);
  align-items: start;
  gap: 12px;
  font-size: 0.9rem;
}

.product-details-param-key {
  color: var(--ink-muted);
}

.product-details-param-value {
  text-align: right;
  font-weight: 600;
  word-break: break-word;
}

.product-details-similar {
  margin-top: 10px;
}

.similar-products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.similar-product-card {
  min-width: 0;
  max-width: none;
  cursor: pointer;
}

.similar-product-name {
  cursor: pointer;
  font-size: 0.95rem;
  line-height: 1.3;
}

.similar-product-meta {
  margin-top: 6px;
}

.similar-product-bottom {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line-strong);
}

.similar-product-old-price {
  font-size: 0.8rem;
}

.similar-product-price {
  font-size: 1.1rem;
}

.similar-product-add-btn {
  min-width: 42px;
  padding: 8px;
}

.product-details-muted {
  margin: 0;
  color: var(--ink-muted);
  font-size: 0.9rem;
}

.product-details-error {
  padding: 40px 20px;
}

.product-details-error-text {
  color: var(--danger);
  font-weight: 600;
  margin: 0 0 16px;
}

.sheet-tabs {
  display: inline-flex;
  gap: 4px;
  border: 1px solid var(--line);
  background: var(--surface-muted);
  border-radius: 999px;
  padding: 4px;
}

.sheet-tab {
  border: none;
  background: transparent;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 800;
  padding: 8px 13px;
  cursor: pointer;
}

.sheet-tab.active {
  background: #fff;
}

.sheet-pane {
  display: none;
  margin-top: 14px;
}

.sheet-pane.active {
  display: block;
}

.sheet-social {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 8px;
}

.sheet-social .section-subtitle {
  margin: 0;
  font-size: 0.82rem;
}

.google-signin-mount {
  display: flex;
  justify-content: center;
}

.sheet-guest {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 8px;
}

.sheet-guest .section-title {
  font-size: 0.95rem;
}

.sheet-guest .section-subtitle {
  margin: 0;
  font-size: 0.82rem;
}

.slider {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.slider-track {
  display: flex;
  transition: transform 0.34s ease;
}

.slide {
  min-width: 100%;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 14px;
}

.slide-media img,
.product-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 12px;
}

.slide-media,
.product-media,
.photo-fallback {
  min-height: 120px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #f4f6f9;
}

.photo-fallback {
  display: grid;
  place-items: center;
  color: var(--ink-muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.slide-price {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-top: 8px;
}

.price-main {
  font-weight: 800;
}

.price-old {
  color: var(--danger);
  text-decoration: line-through;
}

.price-sale {
  color: var(--danger);
  font-weight: 800;
}

.slider-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 10px;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #d8dde4;
}

.dot.active {
  background: #707988;
}

.pill-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.pill {
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: #fff;
  padding: 8px 16px;
  white-space: nowrap;
  font-size: 0.78rem;
  font-weight: 800;
  cursor: pointer;
  transition: border-color 0.16s ease, background 0.16s ease, color 0.16s ease, transform 0.16s ease;
}

.pill:hover {
  border-color: #b8d8c8;
  background: #f6fbf8;
}

.pill.active {
  border-color: #00783C;
  background: #00783C;
  color: #fff;
  box-shadow: none;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
}

.page-catalog .catalog-shell {
  display: grid;
  gap: 24px;
}

.page-catalog .catalog-stage-card {
  position: relative;
  display: grid;
  grid-template-columns: 1fr minmax(0, 380px);
  align-items: center;
  gap: 24px;
  padding: 24px 28px;
  border-radius: 8px;
  background:
    linear-gradient(115deg, rgba(0, 18, 8, 0.84) 0%, rgba(0, 30, 15, 0.72) 48%, rgba(0, 50, 25, 0.50) 100%),
    url("../img/bg.jpeg") center 60% / cover no-repeat;
  border: none;
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.page-catalog .catalog-stage-copy {
  position: relative;
  z-index: 2;
  display: grid;
  gap: 8px;
}

.page-catalog .catalog-eyebrow {
  margin: 0;
  color: #7ddfaa;
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.page-catalog .catalog-stage-card .section-title {
  font-size: clamp(1.4rem, 4vw, 2rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: #ffffff;
}

.page-catalog .catalog-stage-copy p:not(.catalog-eyebrow) {
  color: rgba(255, 255, 255, 0.75);
}

.page-catalog .catalog-box-summary {
  position: relative;
  z-index: 2;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 16px 18px;
  display: grid;
  gap: 12px;
  box-shadow: var(--shadow-sm);
}

.page-catalog .catalog-box-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.page-catalog .catalog-box-copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.page-catalog .catalog-box-label {
  margin: 0;
  color: #66707d;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.page-catalog .catalog-box-name {
  margin: 0;
  font-size: 1.05rem;
  line-height: 1.12;
}

.page-catalog .catalog-box-note {
  margin: 0;
  color: var(--ink-muted);
  font-size: var(--text-meta);
  line-height: 1.4;
}

.page-catalog .catalog-box-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.page-catalog .catalog-box-metrics .metric-pill {
  max-width: 100%;
  min-width: 0;
  white-space: normal;
  overflow-wrap: anywhere;
}

/* Parcel label under box name */
.page-catalog .catalog-box-parcel-label {
  font-size: 0.75rem;
  color: var(--ink-muted);
  margin: 2px 0 0;
}

/* Parcel selector chips (shown when 2+ parcels) */
.page-catalog .catalog-parcel-selector {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.page-catalog .catalog-parcel-chip {
  display: grid;
  gap: 2px;
  justify-items: start;
  padding: 6px 12px;
  border: 1.5px solid var(--line);
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--ink);
  white-space: nowrap;
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.page-catalog .catalog-parcel-chip:hover {
  border-color: var(--accent);
  background: var(--accent-light);
}

.page-catalog .catalog-parcel-chip.is-active {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.page-catalog .catalog-parcel-chip-label {
  font-size: 0.78rem;
  font-weight: 800;
  color: inherit;
  white-space: nowrap;
}

.page-catalog .catalog-parcel-chip-meta {
  font-size: 0.68rem;
  color: var(--ink-muted);
  white-space: nowrap;
}

.page-catalog .catalog-parcel-chip.is-active .catalog-parcel-chip-meta {
  color: rgba(255,255,255,0.75);
}

/* Add new box — picker */
.page-catalog .catalog-add-parcel {
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

.page-catalog .catalog-add-parcel-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.page-catalog .catalog-add-parcel-trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--accent);
  background: none;
  border: none;
  padding: 2px 0;
  cursor: pointer;
  font-family: var(--font-sans);
}

.page-catalog .catalog-add-parcel-trigger:hover {
  color: var(--accent-dark);
}

.page-catalog .catalog-add-parcel-trigger .icon,
.page-catalog [data-action="remove-parcel"] .icon {
  width: 0.95rem;
  height: 0.95rem;
  flex: 0 0 auto;
}

.page-catalog .catalog-box-picker {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding-top: 8px;
}

.page-catalog .catalog-box-picker-item {
  font-size: 0.78rem;
  font-weight: 700;
  padding: 6px 12px;
  border: 1.5px solid var(--accent);
  border-radius: 6px;
  background: #fff;
  color: var(--accent);
  cursor: pointer;
  font-family: var(--font-sans);
  transition: background 0.15s ease, color 0.15s ease;
}

.page-catalog .catalog-box-picker-item:hover {
  background: var(--accent);
  color: #fff;
}

.page-catalog .catalog-box-picker-empty {
  font-size: 0.75rem;
  color: var(--ink-muted);
}

.page-catalog .catalog-box-empty {
  text-align: left;
  padding: 0;
  border: 0;
  background: transparent;
}

.page-catalog .catalog-box-empty .btn {
  margin-top: 4px;
}

/* ===== CATALOG SIDEBAR LAYOUT ===== */
.page-catalog .catalog-layout {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}

.page-catalog .catalog-sidebar {
  position: sticky;
  top: 130px;
  max-height: calc(100vh - 150px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  padding: 8px 0;
  box-shadow: none;
}

.page-catalog .catalog-toolbar {
  display: grid;
}

.sidebar-section {
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
}

.sidebar-section:last-child {
  border-bottom: none;
}

.sidebar-title {
  margin: 0 0 10px;
  font-size: 0.68rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.11em;
  color: var(--ink-muted);
}

.sidebar-input {
  width: 100%;
  min-height: 40px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  padding: 0 12px;
  font-size: 0.88rem;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--bg);
  transition: border-color 0.15s, background 0.15s;
  box-sizing: border-box;
}

.sidebar-input:focus {
  outline: none;
  border-color: var(--accent);
  background: #fff;
}

.sidebar-select {
  width: 100%;
  min-height: 40px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  padding: 0 12px;
  font-size: 0.88rem;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--bg);
  cursor: pointer;
  transition: border-color 0.15s;
  box-sizing: border-box;
}

.sidebar-select:focus {
  outline: none;
  border-color: var(--accent);
}

/* Vertical category list */
.catalog-cat-shell {
  width: 100%;
}

.catalog-cat-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.catalog-cat-list .pill {
  display: flex;
  align-items: center;
  gap: 7px;
  text-align: left;
  width: 100%;
  border-radius: 6px;
  padding: 9px 12px;
  font-size: 0.94rem;
  font-weight: 600;
  border: 1.5px solid transparent;
  background: transparent;
  cursor: pointer;
  color: var(--ink);
  white-space: normal;
  transition: background 0.14s, color 0.14s;
}

.catalog-cat-list .pill:hover {
  background: var(--accent-light);
  color: var(--accent-dark);
  border-color: transparent;
}

.catalog-cat-list .pill.active {
  background: #00783C;
  color: #fff;
  border-color: #00783C;
  font-weight: 700;
  box-shadow: none;
}

/* API image icon inside category pills */
.pill-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  object-fit: contain;
  border-radius: 2px;
}

/* SVG icon inside pills inherits currentColor */
.catalog-cat-list .pill .icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  opacity: 0.75;
}

.catalog-cat-list .pill.active .icon {
  opacity: 1;
}

.page-catalog .catalog-shop {
  display: grid;
  gap: 20px;
}

/* ===== CATALOG PRODUCT GRID — VERTICAL CARDS ===== */
.page-catalog .catalog-products {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.page-catalog .product-card {
  padding: 0;
  overflow: hidden;
  border-radius: 6px;
  border: 1px solid #e0e0e0;
  background: #fff;
  box-shadow: none;
  display: grid;
  height: 100%;
  align-content: start;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.page-catalog .product-card:hover {
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.10);
  transform: translateY(-2px);
  border-color: #c0c0c0;
}

/* Image on top — full width */
.page-catalog .product-card-main {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.page-catalog .product-media {
  height: 210px;
  min-height: 210px;
  border: 0;
  border-bottom: 1px solid #efefef;
  border-radius: 0;
  background: #ffffff;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.page-catalog .product-media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  padding: 18px;
  border-radius: 0;
  transition: transform 0.4s ease;
  box-sizing: border-box;
}

.page-catalog .product-card:hover .product-media img {
  transform: scale(1.04);
}

.page-catalog .product-media .photo-fallback {
  width: 100%;
  min-height: 210px;
  height: 210px;
  border: 0;
  border-radius: 0;
  background: linear-gradient(135deg, #f4f7f5 0%, #eaeeed 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.76rem;
  color: var(--ink-muted);
}

/* Text area below image */
.page-catalog .product-copy {
  min-width: 0;
  padding: 16px 18px 0;
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  gap: 6px;
  align-content: start;
}

.page-catalog .product-copy-top {
  display: grid;
  gap: 4px;
  min-height: calc(4.9rem + 4px);
}

.page-catalog .product-brand {
  margin: 0;
  color: var(--accent);
  font-size: 0.68rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.page-catalog .product-name {
  margin: 0;
  font-size: 0.93rem;
  line-height: 1.3;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.page-catalog .product-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 2px;
}

.page-catalog .product-stat {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border-radius: 999px;
  background: var(--bg);
  border: 1px solid var(--line);
  padding: 3px 9px;
  font-size: 0.72rem;
  color: var(--ink-muted);
}

.page-catalog .product-stat .icon {
  width: 11px;
  height: 11px;
  opacity: 0.7;
}

/* Price + button stacked at bottom */
.page-catalog .product-card-bottom {
  display: grid;
  gap: 10px;
  margin-top: auto;
  padding: 12px 18px 18px;
}

.page-catalog .product-price-stack {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.page-catalog .product-price-stack .price-main {
  font-size: 1.28rem;
  font-weight: 900;
  color: #111111;
  letter-spacing: -0.02em;
}

.page-catalog .product-price-stack .price-sale {
  font-size: 1.22rem;
  font-weight: 900;
  color: var(--danger);
  letter-spacing: -0.02em;
}

.page-catalog .product-price-stack .price-old {
  font-size: 0.82rem;
  color: var(--ink-muted);
  text-decoration: line-through;
}

.page-catalog .product-card .btn-primary {
  width: 100%;
  min-height: 44px;
  border-radius: 6px;
  font-size: 0.8rem;
  white-space: nowrap;
  padding: 10px 10px;
  font-weight: 700;
  margin-top: 0;
  letter-spacing: 0.01em;
  background: #00783C;
}

.page-catalog .product-card .btn-primary:hover {
  background: #005A2D;
  box-shadow: none;
  transform: none;
}

.product-card {
  display: grid;
  gap: 9px;
  align-content: start;
}

.product-card .btn-primary {
  margin-top: auto;
}

.product-meta {
  display: flex;
  gap: 8px;
  color: var(--ink-muted);
  font-size: 0.75rem;
}

.split {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 16px;
}

.page-cart .cart-layout {
  grid-template-columns: minmax(0, 1.3fr) minmax(300px, 0.7fr);
  align-items: start;
  gap: 26px;
}

.page-cart .cart-layout > section {
  gap: 18px;
}

.page-cart .cart-intro,
.page-cart .cart-create {
  padding: 24px;
}

.page-cart .cart-intro {
  border-radius: 20px;
}

.page-cart .cart-intro .section-subtitle {
  margin-top: 8px;
}

.page-cart .cart-create .form-grid {
  gap: 12px;
}

.page-cart .cart-create-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.page-cart .cart-create .section-subtitle {
  margin-top: 8px;
  margin-bottom: 2px;
}

.page-cart .parcel-stack {
  gap: 16px;
}

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

.page-cart .parcel-card {
  border-radius: 20px;
  padding: 22px;
  gap: 13px;
}

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

.page-cart .parcel-header {
  margin-bottom: 4px;
}

.page-cart .parcel-header .actions-row {
  justify-content: flex-end;
  gap: 8px;
}

.parcel-id {
  font-size: 0.98rem;
}

.progress {
  display: grid;
  gap: 5px;
}

.page-cart .progress {
  margin-top: 2px;
  gap: 7px;
}

.progress-label {
  display: flex;
  justify-content: space-between;
  color: var(--ink-muted);
  font-size: 0.72rem;
}

.progress-track {
  height: 8px;
  border-radius: 999px;
  background: #eceff3;
  overflow: hidden;
}

.page-cart .progress-track {
  height: 10px;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #8fd5b1, #60be8d);
}

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

.page-cart .item-list {
  margin-top: 6px;
  gap: 12px;
}

.item-row {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  padding: 10px;
  display: grid;
  gap: 7px;
}

.page-cart .item-row {
  padding: 14px;
  border-radius: 14px;
  background: #fcfcfd;
  gap: 10px;
}

.page-cart .item-top.item-top-media {
  align-items: flex-start;
  gap: 10px;
}

.page-cart .item-media {
  width: 48px;
  height: 48px;
  flex: 0 0 48px;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  background: #f4f6f9;
}

.page-cart .item-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.page-cart .item-media .photo-fallback,
.page-checkout .checkout-line-media .photo-fallback {
  min-height: 100%;
  border: 0;
  border-radius: 0;
  background: #eef1f5;
  font-size: 0.58rem;
}

.page-cart .item-main {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.item-top {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.page-cart .item-top strong {
  font-size: 0.84rem;
  line-height: 1.2;
}

.page-cart .item-meta-line {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--ink-muted);
  font-size: 0.74rem;
}

.page-cart .item-meta-line span {
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.page-cart .item-meta-line .icon {
  width: 11px;
  height: 11px;
  opacity: 0.65;
}

.page-cart .item-price {
  margin-left: auto;
  font-weight: 800;
  white-space: nowrap;
}

.page-cart .item-row .controls-row {
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
}

.page-cart .item-row .controls-row > span {
  color: var(--ink-muted);
  font-size: 0.77rem;
}

.qty-controls {
  display: inline-flex;
  gap: 6px;
}

.page-cart .qty-controls {
  margin-left: auto;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.page-cart .qty-controls .btn-inline {
  min-width: 40px;
  padding: 8px 10px;
}

.page-cart .cart-summary {
  padding: 24px;
  border-radius: 20px;
  position: sticky;
  top: 124px;
}

.page-cart .cart-summary .summary-table {
  gap: 11px;
  margin-top: 8px;
}

.page-cart .cart-summary-actions {
  margin-top: 18px;
  display: grid;
  gap: 10px;
}

.page-cart .cart-summary-actions .btn {
  width: 100%;
}

.page-checkout .checkout-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(330px, 0.88fr);
  align-items: start;
  gap: 22px;
}

.page-checkout .checkout-left,
.page-checkout .checkout-right {
  display: grid;
  gap: 16px;
  align-content: start;
}

.page-checkout .checkout-hero,
.page-checkout .checkout-review-card,
.page-checkout .checkout-address-card,
.page-checkout .checkout-form-card,
.page-checkout .checkout-submit-card {
  border-radius: 20px;
  padding: 22px;
}

.page-checkout .checkout-hero {
  background: linear-gradient(180deg, #ffffff 0%, #fbfcfe 100%);
}

.page-checkout .checkout-hero .section-title {
  font-size: clamp(1.52rem, 3vw, 2.2rem);
  line-height: 0.98;
}

.page-checkout .checkout-hero .section-subtitle {
  margin-top: 10px;
}

.page-checkout .checkout-hero-pills {
  margin-top: 15px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.page-checkout .checkout-pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: #48515e;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 6px 11px;
}

.page-checkout .checkout-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.page-checkout .checkout-review-list,
.page-checkout .checkout-address-list,
.page-checkout .checkout-result {
  display: grid;
  gap: 10px;
}

.page-checkout .checkout-parcel,
.page-checkout .checkout-address-item,
.page-checkout .checkout-success {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fcfcfd;
  padding: 14px;
  display: grid;
  gap: 10px;
}

.page-checkout .checkout-address-item.is-default {
  border-color: rgba(21, 145, 90, 0.34);
  background: linear-gradient(180deg, #ffffff 0%, #f3faf6 100%);
  box-shadow: inset 0 0 0 1px rgba(21, 145, 90, 0.08);
}

.page-checkout .checkout-address-item.is-default .status-chip {
  border-color: rgba(21, 145, 90, 0.28);
  background: #e9f7ef;
  color: #216847;
}

.page-checkout .checkout-address-copy {
  display: grid;
  gap: 4px;
}

/* Icon rows inside address items */
.address-detail-list {
  display: grid;
  gap: 6px;
}

.address-detail-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.84rem;
  color: var(--ink-muted);
  line-height: 1.4;
}

.address-detail-row .icon {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  margin-top: 1px;
  color: var(--accent);
  opacity: 0.75;
}

.page-checkout .checkout-address-note {
  margin: 0;
  color: #216847;
  font-size: 0.78rem;
  font-weight: 700;
}

.page-checkout .checkout-parcel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.page-checkout .checkout-parcel-id {
  margin: 0;
  font-size: 1rem;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.page-checkout .checkout-lines .summary-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.84rem;
}

.page-checkout .checkout-line-main {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.page-checkout .checkout-line-media {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  border: 1px solid var(--line);
  border-radius: 9px;
  overflow: hidden;
  background: #f4f6f9;
}

.page-checkout .checkout-line-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.page-checkout .checkout-lines .summary-row span:last-child {
  color: #222830;
  font-weight: 700;
}

.page-checkout .checkout-address-item .section-subtitle {
  margin: 0;
  line-height: 1.45;
}

.page-checkout .checkout-form-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.page-checkout .checkout-form-copy {
  min-width: 0;
}

.page-checkout .checkout-form-toggle {
  flex: 0 0 auto;
}

.page-checkout .checkout-address-form {
  gap: 12px;
}

.address-map-tools {
  display: grid;
  gap: 8px;
}

.address-map-trigger {
  width: fit-content;
}

.address-map-status {
  margin: 0;
  min-height: 1.2em;
  color: var(--ink-muted);
  font-size: 0.8rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.map-picker-modal {
  position: fixed;
  inset: 0;
  z-index: 130;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 12px;
}

.map-picker-modal.open {
  display: flex;
}

.map-picker-backdrop {
  position: fixed;
  inset: 0;
  z-index: 129;
  background: rgba(7, 12, 18, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.map-picker-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.map-picker-sheet {
  width: min(860px, calc(100vw - 24px));
  max-height: calc(100vh - 24px);
  max-height: calc(100dvh - 24px);
  border-radius: 14px;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: var(--shadow-lg);
  padding: 14px;
  display: grid;
  gap: 10px;
  overflow: hidden;
}

.map-picker-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.map-picker-canvas {
  min-height: 300px;
  height: min(50vh, 430px);
  height: min(50dvh, 430px);
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--line);
  overflow: hidden;
}

.map-picker-coords {
  margin: 0;
  min-height: 1.2em;
  color: var(--ink-muted);
  font-size: 0.8rem;
}

body.map-picker-open {
  overflow: hidden;
}

.page-profile .profile-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.9fr);
  align-items: start;
  gap: 18px;
}

.page-profile .profile-layout > aside {
  align-content: start;
}

.page-profile .profile-hero {
  padding: 24px;
}

.page-profile .profile-account-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
}

.page-profile .profile-account-actions .btn {
  min-width: 160px;
}

.page-profile .checkout-address-list {
  display: grid;
  gap: 10px;
}

.page-profile .profile-orders-list {
  gap: 12px;
}

.order-card .actions-row .btn {
  flex: 1 1 170px;
}

.page-checkout .checkout-form-card.is-collapsed {
  padding: 16px 18px;
}

.page-checkout .checkout-form-card.is-collapsed .checkout-form-intro,
.page-checkout .checkout-form-card.is-collapsed .checkout-address-form {
  display: none;
}

.page-checkout .checkout-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.page-checkout .checkout-submit-btn {
  width: 100%;
  min-height: 48px;
  border-radius: 12px;
}

.page-checkout .checkout-invoice-shell {
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
}

.page-checkout .checkout-invoice-head {
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  background: #f8f9fc;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.page-checkout .checkout-invoice-head .section-title {
  font-size: 1.15rem;
  line-height: 1.2;
}

.page-checkout .checkout-invoice-body {
  min-height: 200px;
}

.page-checkout .checkout-invoice-frame {
  width: 100%;
  min-height: 640px;
  border: 0;
  background: #fff;
}

.page-checkout .checkout-success .actions-row {
  margin-top: 2px;
}

.page-checkout .checkout-success .actions-row .btn {
  flex: 1 1 170px;
}

.page-checkout .checkout-message {
  margin-top: 14px;
}

.page-checkout .empty-state {
  border-style: solid;
  background: #fafbfc;
  text-align: left;
  padding: 18px;
}

.page-checkout .empty-state h3 {
  font-size: 1.02rem;
}

.page-checkout .empty-state p {
  margin-top: 7px;
  font-size: 0.91rem;
}

.summary-table {
  display: grid;
  gap: 7px;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.9rem;
  color: #48515e;
}

.summary-row.total {
  border-top: 1px dashed var(--line);
  margin-top: 6px;
  padding-top: 8px;
  color: var(--ink);
  font-size: 0.94rem;
  font-weight: 800;
}

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

.order-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.status-chip {
  display: inline-flex;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface-muted);
  color: #505864;
  font-size: 0.74rem;
  font-weight: 800;
  padding: 5px 10px;
}

.is-hidden {
  display: none !important;
}

.empty-state {
  border: 1px dashed var(--line);
  border-radius: var(--radius-md);
  background: #fff;
  text-align: center;
  padding: 22px;
}

.empty-state h3 {
  font-size: 1.08rem;
}

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

.toast-container {
  position: fixed;
  top: 80px;
  left: 50%;
  transform: translateX(-50%);
  display: grid;
  gap: 8px;
  z-index: 200;
  pointer-events: none;
}

.toast {
  min-width: 220px;
  max-width: 360px;
  border-radius: 10px;
  background: #21242a;
  color: #fff;
  font-size: 0.82rem;
  padding: 10px 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.28);
  pointer-events: auto;
  text-align: center;
}

.toast-success {
  background: #0f6e41;
}

.toast-error {
  background: #8f2a1f;
}

.floating-next-cart {
  position: fixed;
  right: 16px;
  bottom: calc(18px + env(safe-area-inset-bottom));
  z-index: 95;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 8px 18px rgba(16, 17, 20, 0.22);
}

.floating-count {
  min-width: 18px;
  height: 18px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.35);
  font-size: 0.71rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}

.fade-out {
  opacity: 0;
  transform: translateY(6px);
  transition: 0.26s ease;
}

@media (max-width: 1100px) {
  .session-badge {
    display: none;
  }

  .session-profile-link .session-profile-link-text {
    display: none;
  }

  .header-actions {
    gap: 6px;
  }

  .page-home .home-hero-content {
    max-width: min(720px, 94vw);
    padding: clamp(34px, 4vh, 52px) clamp(20px, 4vw, 52px);
  }

  .page-home .home-hero-content .title-xl {
    font-size: clamp(1.7rem, 3vw, 2.5rem);
  }

  .features-strip-inner {
    width: min(1100px, calc(100vw - 24px));
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px;
  }

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

@media (max-width: 920px) {
  .split,
  .slide {
    grid-template-columns: 1fr;
  }

  .header-inner,
  .main-inner,
  .footer-inner,
  .flow-inner {
    width: calc(100vw - 16px);
  }

  .header-inner {
    min-height: 56px;
    padding: 0;
    flex-direction: row;
    align-items: center;
    gap: 8px;
  }

  .header-actions {
    gap: 6px;
    flex-wrap: nowrap;
  }

  .actions-row {
    width: 100%;
  }

  /* Only context buttons go full-width, not nav buttons */
  .page-main .btn:not(.btn-inline) {
    width: 100%;
  }

  .btn-inline {
    width: auto;
  }

  .header-actions > .btn.btn-inline,
  .header-actions > .cart-chip,
  .header-actions .session-profile-link {
    min-width: 48px;
    padding: 0 10px;
  }

  /* Hide email badge on mobile — saves header space */
  .session-badge {
    display: none;
  }

  .session {
    gap: 6px;
  }

  .session-profile-link {
    justify-content: center;
  }

  .session-profile-link .session-profile-link-text {
    display: none;
  }

  .floating-next-cart {
    right: 12px;
    left: 12px;
    bottom: calc(12px + env(safe-area-inset-bottom));
    justify-content: center;
  }

  .page-main {
    padding: 20px 0 76px;
  }

  .sheet-inner {
    width: calc(100vw - 16px);
    padding: 16px 0 calc(20px + env(safe-area-inset-bottom));
  }

  .product-details-layout {
    gap: 14px;
  }

  .product-details-gallery {
    gap: 8px;
  }

  .product-details-main-image,
  .product-details-single-image {
    max-width: 100%;
    min-height: 240px;
  }

  .product-details-main-image {
    height: min(44vh, 320px);
    height: min(44dvh, 320px);
    aspect-ratio: auto;
  }

  .product-details-single-image {
    height: min(44vh, 320px);
    height: min(44dvh, 320px);
  }

  .product-details-main-image img,
  .product-details-single-image img {
    padding: 12px;
  }

  .product-details-thumbs {
    justify-content: flex-start;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .product-details-thumb {
    width: 56px;
    height: 56px;
    flex: 0 0 56px;
  }

  .product-details-param {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .product-details-param-value {
    text-align: left;
  }

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

  .page-box #boxTypeGrid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .page-box .hero {
    padding: 22px;
  }

  .page-box .box-carton {
    height: 210px;
    filter: drop-shadow(0 8px 18px rgba(36, 16, 2, 0.24));
  }

  .page-box .box-3d {
    --bw: 148px;
    --bh: 110px;
    --bd: 104px;
    transform: rotateX(-18deg) rotateY(34deg);
  }

  .page-box .box-card:hover .box-3d,
  .page-box .box-card:focus-visible .box-3d {
    transform: rotateX(-18deg) rotateY(38deg);
  }

  .box-stamp {
    display: none;
  }

  .page-box .box-caption {
    padding: 16px 4px 0;
  }

  .page-catalog .catalog-stage-card {
    grid-template-columns: 1fr;
    padding: 18px 20px;
    gap: 14px;
  }

  .page-catalog .catalog-stage-copy {
    display: none;
  }

  .page-catalog .catalog-box-summary {
    padding: 14px 16px;
    gap: 8px;
    border-radius: 14px;
  }

  .page-catalog .catalog-box-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .page-catalog .catalog-box-metrics {
    gap: 6px;
  }

  .page-catalog .catalog-box-note {
    display: block;
  }

  .page-catalog .catalog-parcel-chip {
    min-width: 120px;
  }

  .flow-strip {
    top: 63px;
  }

  /* Sidebar collapses above products */
  .page-catalog .catalog-layout {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  /* Mobile box card — always show green outline */
  .page-box .box-card {
    border-color: var(--accent);
    box-shadow: 0 0 0 2px var(--accent-light);
  }

  /* Compact 2-column filter bar on mobile */
  .page-catalog .catalog-sidebar {
    position: static;
    max-height: none;
    overflow: visible;
    border-radius: 8px;
    padding: 12px 14px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 12px;
  }

  .page-catalog .catalog-toolbar {
    display: contents;
  }

  .page-catalog .catalog-sidebar .sidebar-section {
    padding: 0;
    border-bottom: none;
    min-width: 0;
  }

  /* Categories row spans full width */
  .page-catalog .catalog-sidebar .sidebar-section:last-child {
    grid-column: 1 / -1;
  }

  /* Hide labels — inputs are self-evident on mobile */
  .page-catalog .catalog-sidebar .sidebar-title {
    display: none;
  }

  .catalog-cat-shell {
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
  }

  .catalog-cat-list {
    flex-direction: row;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 6px;
    padding-bottom: 2px;
  }

  .catalog-cat-list .pill {
    width: auto;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    border: 1.5px solid var(--line);
    border-radius: 999px;
    background: #fff;
    white-space: nowrap;
    padding: 7px 14px;
  }

  .catalog-cat-list .pill:hover {
    background: var(--accent-light);
  }

  .catalog-cat-list .pill.active {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
    box-shadow: 0 2px 8px rgba(21, 145, 90, 0.22);
  }

  /* 2-column vertical cards on tablet/mobile */
  .page-catalog .catalog-products {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .page-catalog .product-media {
    height: 160px;
    min-height: 160px;
  }

  .page-catalog .product-media .photo-fallback {
    min-height: 160px;
    height: 160px;
  }

  .page-catalog .product-copy {
    padding: 12px 13px 0;
    gap: 5px;
  }

  .page-catalog .product-card-bottom {
    padding: 0 13px 13px;
    gap: 8px;
  }

  .page-catalog .product-price-stack .price-main,
  .page-catalog .product-price-stack .price-sale {
    font-size: 1.05rem;
  }

  .page-cart .cart-layout {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .page-checkout .checkout-layout {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .page-profile .profile-layout {
    grid-template-columns: 1fr;
  }

  .page-profile .profile-account-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .page-home .home-hero-media {
    min-height: 75svh;
    min-height: 75vh;
    background:
      linear-gradient(120deg, rgba(0, 55, 22, 0.93) 0%, rgba(0, 80, 32, 0.74) 42%, rgba(0, 110, 50, 0.26) 100%),
      url("../img/bg.jpeg") center 55% / cover no-repeat;
  }

  .page-home .home-hero-content {
    padding: 32px 24px;
    gap: 18px;
    max-width: 100%;
  }

  .page-home .home-step-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .page-home .home-step-card {
    padding: 28px 24px 24px;
  }

  .page-home .home-step-card .section-title {
    font-size: clamp(1.26rem, 5vw, 1.8rem);
  }

  .page-checkout .checkout-section-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .page-checkout .checkout-form-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .page-checkout .checkout-form-row {
    grid-template-columns: 1fr;
  }

  .address-map-trigger {
    width: 100%;
  }

  .map-picker-sheet {
    width: calc(100vw - 16px);
    max-height: calc(100vh - 16px);
    max-height: calc(100dvh - 16px);
    padding: 12px;
  }

  .map-picker-canvas {
    min-height: 250px;
    height: 42vh;
    height: 42dvh;
  }

  .page-checkout .checkout-parcel-id {
    font-size: 1.05rem;
  }

  .page-checkout .checkout-invoice-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .page-checkout .checkout-invoice-frame {
    min-height: 500px;
  }

  .page-cart .parcel-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .page-cart .parcel-header .actions-row {
    width: auto;
  }

  .page-cart .cart-create-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .page-cart .item-row .controls-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .page-cart .qty-controls {
    margin-left: 0;
    justify-content: flex-start;
  }

  .page-cart .cart-summary {
    position: static;
    top: auto;
  }

  .home-steps-section {
    padding: 64px 0;
  }

  .features-strip-inner {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 48px 0;
  }

  .cta-banner-inner {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 64px 0;
  }

  .cta-banner-subtitle {
    margin: 0 auto;
  }

  .cta-banner .btn {
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
  }

  .footer-inner {
    padding: 56px 0 32px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 8px;
  }
}

@media (max-width: 760px) {
  .similar-products-grid {
    grid-template-columns: 1fr;
  }
}

/* Very small phones */
@media (max-width: 480px) {
  .flow-inner {
    min-height: auto;
    flex-wrap: wrap;
    overflow-x: visible;
    row-gap: 6px;
    padding: 6px 0;
  }

  .flow-step {
    font-size: 0.72rem;
    padding: 5px 9px;
  }

  .page-catalog .catalog-sidebar {
    grid-template-columns: 1fr;
  }

  .page-catalog .catalog-sidebar .sidebar-section:last-child {
    grid-column: 1;
  }

  .page-catalog .catalog-box-metrics {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
  }

  .catalog-cat-list {
    flex-wrap: nowrap;
    overflow-x: auto;
  }

  .page-catalog .catalog-products {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .page-catalog .product-media,
  .page-catalog .product-media .photo-fallback {
    height: 130px;
    min-height: 130px;
  }

  .page-catalog .product-copy {
    padding: 10px 10px 0;
  }

  .page-catalog .product-name {
    overflow-wrap: anywhere;
  }

  .page-catalog .product-card-bottom {
    padding: 0 10px 10px;
  }

  .page-catalog .product-price-stack .price-main,
  .page-catalog .product-price-stack .price-sale {
    font-size: 0.95rem;
  }

  .page-catalog .product-card .btn-primary {
    min-height: 40px;
    font-size: 0.72rem;
    padding: 8px 6px;
    white-space: normal;
    line-height: 1.2;
  }

  .page-box #boxTypeGrid {
    grid-template-columns: 1fr;
  }

  .page-box .box-carton {
    height: 186px;
  }

  .page-box .box-3d {
    --bw: 126px;
    --bh: 96px;
    --bd: 90px;
  }

  .box-price-badge {
    top: 10px;
    left: 10px;
    font-size: 0.72rem;
    padding: 4px 8px;
  }

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

@media (max-width: 360px) {
  .header-inner,
  .main-inner,
  .footer-inner,
  .flow-inner {
    width: calc(100vw - 8px);
  }

  .page-catalog .catalog-stage-card {
    padding: 12px 10px;
    gap: 10px;
  }

  .page-catalog .catalog-box-summary {
    padding: 10px 10px;
    gap: 6px;
  }

  .page-catalog .catalog-box-metrics {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .page-catalog .catalog-box-metrics .metric-pill {
    font-size: 0.73rem;
    padding: 4px 8px;
    border-radius: 12px;
    gap: 5px;
  }

  .catalog-cat-list .pill {
    padding: 6px 10px;
    font-size: 0.8rem;
  }
}

@media (max-width: 320px) {
  .box-spec-grid {
    grid-template-columns: 1fr;
  }

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

@media (prefers-reduced-motion: reduce) {
  * {
    transition-duration: 0.01ms !important;
  }
}
