:root {
  --bg: #060a09;
  --panel: #0d1412;
  --panel-2: #141d19;
  --line: rgba(52, 211, 153, 0.24);
  --accent: #34d399;
  --accent-soft: #6ee7b7;
  --accent-deep: #0f9f6e;
  --text: #eaf4ef;
  --muted: #8fa39a;
  --ok: #5eead4;
  --danger: #f2555a;
  --accent-grad: linear-gradient(180deg, #a7f3d0 0%, #34d399 48%, #0f9f6e 100%);
  --safe: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  margin: 0;
  padding: 0;
  background: #040706;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

body { overscroll-behavior-y: none; }

button {
  font: inherit;
  color: inherit;
  border: 0;
  background: none;
  cursor: pointer;
}

img { display: block; }

.phone {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 430px;
  min-height: 100dvh;
  margin: 0 auto;
  background:
    radial-gradient(120% 55% at 50% -10%, #08211a 0%, rgba(5, 10, 9, 0) 60%),
    var(--bg);
  overflow: hidden;
}

/* --- coupon ticker ---------------------------------------------------- */
.ticker {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid rgba(52, 211, 153, 0.32);
  background: linear-gradient(90deg, rgba(16, 185, 129, 0.22), rgba(6, 15, 12, 0.97) 30%, rgba(6, 15, 12, 0.97) 70%, rgba(16, 185, 129, 0.22));
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.28);
}

.ticker[hidden] { display: none; }

.ticker-track {
  display: flex;
  width: max-content;
  animation: ticker-scroll 32s linear infinite;
}

.ticker-group {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 38px;
  padding: 9px 22px;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 600;
  color: #eef8f3;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

.ticker-item { display: inline-flex; align-items: baseline; gap: 7px; }
.ticker-item b { color: #a7f3d0; font-weight: 800; }
.ticker-dot { color: #6ee7b7; opacity: 0.85; font-size: 10px; }

@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
  .ticker-track { animation: none; }
}

/* --- title bar -------------------------------------------------------- */
.titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px 8px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 17px;
  font-weight: 800;
  letter-spacing: 0.16em;
  color: #e8f2ec;
}

.brand-mark {
  width: 26px;
  height: 26px;
  filter: drop-shadow(0 2px 6px rgba(52, 211, 153, 0.35));
}

.brand b {
  color: #6ee7b7;
  font-weight: 800;
}

.dots { color: #7f9389; font-size: 18px; letter-spacing: 2px; }

/* --- balance bar ------------------------------------------------------- */
.wallet {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 2px 12px 12px;
  padding: 8px 12px;
  min-height: 58px;
  border: 1px solid rgba(52, 211, 153, 0.34);
  border-radius: 14px;
  background: linear-gradient(180deg, #0c1613 0%, #0a100e 100%);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(167, 243, 208, 0.07);
}

.wallet-text { display: flex; flex-direction: column; line-height: 1.1; }

.wallet-label {
  font-size: 11px;
  letter-spacing: 0.04em;
  color: #c3d6cd;
  opacity: 0.85;
}

.wallet-amount {
  display: flex;
  align-items: baseline;
  gap: 4px;
  margin-top: 2px;
  color: var(--accent);
}

.wallet-amount b { font-size: 21px; font-weight: 800; }

.wallet-amount em {
  font-style: normal;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #6ee7b7;
}

.wallet-topup {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 5px;
  padding: 9px 11px;
  border-radius: 999px;
  background: var(--accent-grad);
  color: #04231a;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 5px 16px rgba(52, 211, 153, 0.2);
}

.wallet-topup svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
}

.wallet-topup:active { transform: translateY(1px); }

/* --- layout ------------------------------------------------------------ */
.view {
  flex: 1;
  padding: 0 12px 104px;
}

.section-title {
  margin: 18px 4px 10px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #9db3a9;
}

.muted { color: var(--muted); }

/* --- hero carousel ----------------------------------------------------- */
.hero {
  position: relative;
  border: 1px solid rgba(52, 211, 153, 0.16);
  border-radius: 16px;
  overflow: hidden;
  background: #080e0c;
  aspect-ratio: 4 / 3.05;
}

.slide {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  opacity: 0;
  transition: opacity 0.45s ease;
  background:
    radial-gradient(80% 70% at 50% 45%, rgba(52, 211, 153, 0.1) 0%, rgba(0, 0, 0, 0) 65%),
    linear-gradient(180deg, #0b1210 0%, #050908 100%);
}

.slide.is-active { opacity: 1; }

.slide-mark {
  width: clamp(66px, 22vw, 94px);
  height: auto;
  filter: drop-shadow(0 8px 22px rgba(16, 185, 129, 0.28));
}

.slide::after {
  content: "";
  position: absolute;
  inset: -40% -20% auto -20%;
  height: 70%;
  background: linear-gradient(115deg, transparent 42%, rgba(167, 243, 208, 0.07) 50%, transparent 58%);
  pointer-events: none;
}

.wordmark {
  text-align: center;
  line-height: 0.86;
  font-weight: 900;
  letter-spacing: 0.03em;
  transform: perspective(600px) rotateX(9deg);
}

.wordmark .big {
  display: block;
  font-size: clamp(30px, 12.6vw, 54px);
  letter-spacing: 0.02em;
  background: linear-gradient(180deg, #d1fae5 0%, #34d399 52%, #065f46 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 3px 0 rgba(0, 0, 0, 0.65));
}

.wordmark .small {
  display: block;
  margin-top: 6px;
  font-size: clamp(17px, 6.4vw, 26px);
  letter-spacing: 0.26em;
  color: transparent;
  -webkit-text-stroke: 1.4px rgba(52, 211, 153, 0.85);
}

.hero-meta {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 14px;
  text-align: center;
  font-size: 11px;
  letter-spacing: 0.05em;
  color: #c3d6cd;
  line-height: 1.5;
  text-shadow: 0 2px 10px #000;
}

.hero-meta .cities { color: var(--accent-soft); font-weight: 700; }

.dots-nav {
  display: flex;
  justify-content: center;
  gap: 7px;
  margin: 12px 0 16px;
}

.dots-nav button {
  width: 22px;
  height: 5px;
  border-radius: 4px;
  background: #1f2a26;
  transition: background 0.25s ease, width 0.25s ease;
}

.dots-nav button.is-active { background: var(--accent); }

/* --- buttons ----------------------------------------------------------- */
.cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  height: 52px;
  border-radius: 12px;
  background: var(--accent-grad);
  color: #04231a;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  box-shadow: 0 8px 22px rgba(52, 211, 153, 0.18);
}

.cta:active { transform: translateY(1px); }

.cta.ghost {
  background: transparent;
  color: var(--accent);
  border: 1px solid rgba(52, 211, 153, 0.5);
  box-shadow: none;
}

.cta.small { height: 42px; font-size: 12.5px; }

.support-fab {
  position: fixed;
  bottom: calc(76px + env(safe-area-inset-bottom, 0px));
  /* Pinned to the bottom-right corner on every screen: never flipped by a
     parent's text direction or a stray `left`. */
  right: 14px;
  left: auto;
  z-index: 40;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 0;
  display: grid;
  place-items: center;
  background: var(--accent-grad);
  color: #04231a;
  box-shadow: 0 8px 22px rgba(52, 211, 153, 0.25);
  cursor: pointer;
}

.support-fab svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linejoin: round;
}

/* The button belongs to the window corner on every screen: right of the screen
   on a phone, right of the screen on a desktop too — not at the edge of the
   phone-width column in the middle of a wide window. */
.support-fab { right: 16px; left: auto; }

@media (min-width: 900px) {
  /* On wide screens the tab bar moves to the top, so nothing is in the way. */
  .support-fab { right: 24px; bottom: 24px; width: 52px; height: 52px; }
}

.howto-steps {
  list-style: none;
  margin: 14px 0;
  padding: 0;
  display: grid;
  gap: 12px;
  counter-reset: step;
}

.howto-steps li {
  display: grid;
  gap: 2px;
  padding-left: 34px;
  position: relative;
  font-size: 13px;
  line-height: 1.4;
}

.howto-steps li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--accent-grad);
  color: #04231a;
  font-weight: 800;
  font-size: 12px;
  display: grid;
  place-items: center;
}

.howto-steps li span {
  color: var(--muted, #9aa5a0);
}

.home-help {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 10px;
}

.cta:disabled { opacity: 0.55; }

/* "No crypto yet?" on the home screen: one quiet line under the two cards. */
.home-crypto {
  margin-top: 10px;
  font-size: 12px;
  text-transform: none;
  letter-spacing: 0.01em;
}

/* --- product grid ------------------------------------------------------ */
.category-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 12px 0 4px;
  scrollbar-width: none;
}

.category-row::-webkit-scrollbar { display: none; }

.chip {
  flex: 0 0 auto;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: #0f1614;
  color: #a9bdb3;
  font-size: 12.5px;
  font-weight: 600;
}

.chip.is-active {
  border-color: rgba(52, 211, 153, 0.6);
  background: linear-gradient(180deg, rgba(52, 211, 153, 0.18), rgba(52, 211, 153, 0.04));
  color: var(--accent);
}

.grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 10px;
}

.card {
  position: relative;
  aspect-ratio: 0.84;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: #0e1513;
  text-align: left;
}

.card > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.05) brightness(0.92);
}

.card .shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.05) 35%, rgba(0, 0, 0, 0.88) 100%);
}

.card .name {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 38px;
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.25;
  color: #e8f2ec;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.7);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card .price {
  position: absolute;
  left: 9px;
  bottom: 9px;
  padding: 3px 9px;
  border-radius: 8px;
  background: rgba(5, 10, 9, 0.72);
  border: 1px solid rgba(52, 211, 153, 0.2);
  color: var(--accent);
  font-size: 12.5px;
  font-weight: 800;
}

.card .add {
  position: absolute;
  right: 8px;
  bottom: 8px;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--accent-grad);
  color: #04231a;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

.card .add svg { width: 17px; height: 17px; }

.card .price i { font-style: normal; font-weight: 600; font-size: 10.5px; opacity: 0.72; }

.card-stock {
  position: absolute;
  top: 8px;
  left: 8px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(5, 10, 9, 0.92);
  border: 1px solid rgba(52, 211, 153, 0.5);
  color: var(--accent);
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.2px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45);
}

/* A lit dot makes the number read as "available" at a glance, not as a label. */
.card-stock::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 8px currentColor;
}

.card-stock.is-out {
  border-color: rgba(255, 255, 255, 0.25);
  color: #c3d6cd;
}

/* --- amount picker (grams / pieces) ------------------------------------ */
.stock-note {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 600;
  color: #9fe8c9;
}

.stock-note.is-out { color: #ff9d9d; }

.qty-input-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 0 0 10px;
  padding: 10px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: #0a100e;
}

.qty-input-row:focus-within { border-color: rgba(52, 211, 153, 0.65); }

.qty-input-row input {
  flex: 1;
  min-width: 0;
  border: 0;
  padding: 0;
  background: none;
  color: var(--text);
  font-size: 26px;
  font-weight: 900;
  outline: none;
}

.qty-input-row .unit {
  font-size: 13px;
  font-weight: 800;
  color: var(--accent-soft);
}

.qty-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 12px;
}

.qty-total {
  margin: 0;
  font-size: 22px;
  font-weight: 900;
  color: var(--accent);
}

.qty-hint {
  margin: 2px 0 14px;
  font-size: 12px;
  color: #8fa79b;
}

.price-tiers {
  margin: 12px 0 14px;
  padding: 10px 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
}

.tier-title {
  margin-bottom: 3px;
  color: var(--accent);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.tier-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1px 12px;
  padding: 6px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
}

.tier-row:first-of-type { border-top: 0; }

.tier-row span { color: #d6e6de; font-size: 11.5px; }
.tier-row b { color: var(--accent); font-size: 12px; font-weight: 800; }

.tier-row small {
  grid-column: 1 / -1;
  color: #8fa79b;
  font-size: 10.5px;
}

/* --- cart -------------------------------------------------------------- */
.line {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 12px;
  margin-bottom: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: linear-gradient(180deg, #101816, #0b1210);
}

.line > img {
  width: 44px;
  height: 44px;
  border-radius: 9px;
  object-fit: cover;
  background: #16201c;
}

.line h4 { margin: 0 0 3px; font-size: 12.5px; font-weight: 700; }

.line .where { font-size: 11px; color: #84998f; }

.line .remove {
  align-self: start;
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 10.5px;
  color: #c3d6cd;
}

.line .bottom-row {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 2px;
}

.line .line-price { font-size: 14px; font-weight: 800; color: var(--accent); }

/* Pack price under the line total: "18.50 EUR / 250 g" — the line total alone
   does not say what one pack costs, and a bare amount would read like grams. */
.line .line-price small {
  display: block;
  margin-top: 1px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #84998f;
}

.stepper {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.stepper button {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(52, 211, 153, 0.45);
  color: var(--accent);
  font-size: 15px;
  line-height: 1;
}

.stepper span { min-width: 14px; text-align: center; font-weight: 700; }

.total-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin: 18px 2px 12px;
}

.total-row span { font-size: 17px; font-weight: 800; }
.total-row b { font-size: 20px; font-weight: 900; }
.total-row b i { font-style: normal; font-size: 12px; color: var(--accent-soft); margin-left: 3px; }
.packaging-pick { margin: 14px 0 6px; padding: 12px 14px; border: 1px solid var(--line);
  border-radius: 14px; background: rgba(255,255,255,.02); }
.packaging-title { display: flex; flex-direction: column; gap: 2px; font-size: 14px;
  font-weight: 800; }
.packaging-title small { color: var(--muted); font-size: 11.5px; font-weight: 500;
  line-height: 1.35; }
.packaging-options { display: grid; grid-template-columns: 1fr 1fr; gap: 8px;
  margin-top: 9px; }
.packaging-option { padding: 10px 8px; border: 1px solid var(--line); border-radius: 10px;
  background: var(--panel-2); color: var(--text); font-size: 12.5px; font-weight: 700;
  line-height: 1.25; }
.packaging-option.is-active { border-color: rgba(52,211,153,.7);
  background: rgba(52,211,153,.12); color: var(--accent); }
/* A wrapping the shelf does not allow: visible, greyed out, not clickable. */
.packaging-option.is-locked { opacity: .38; cursor: not-allowed;
  border-style: dashed; text-decoration: line-through; }
.packaging-lock { display: block; margin-top: 8px; color: var(--muted);
  font-size: 11.5px; line-height: 1.45; }
.packaging-note { margin: 0 0 12px; color: var(--muted); font-size: 13px; }
.packaging-note b { color: var(--text); }
@media (max-width: 360px) { .packaging-options { grid-template-columns: 1fr; } }

.empty {
  padding: 44px 18px;
  text-align: center;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.6;
}

/* --- account ----------------------------------------------------------- */
.account-block { padding: 6px 2px 2px; }

.row-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.big-balance {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-top: 2px;
  font-size: 30px;
  font-weight: 900;
  color: var(--accent);
}

.big-balance em {
  font-style: normal;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: #6ee7b7;
}

.refresh {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid rgba(52, 211, 153, 0.55);
  color: var(--accent);
  font-size: 12.5px;
  font-weight: 700;
}

.refresh svg { width: 14px; height: 14px; }

.user-id {
  margin-top: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: #cfded7;
}

.copy-mini {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  color: #e6f1eb;
}

.copy-mini svg { width: 15px; height: 15px; color: #9db3a9; }

.copy-dot {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  margin-left: 8px;
  border-radius: 50%;
  background: var(--accent-grad);
  color: #04231a;
}

.copy-dot svg { width: 14px; height: 14px; }

.panel {
  margin-top: 16px;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid rgba(52, 211, 153, 0.34);
  background: linear-gradient(180deg, rgba(9, 35, 27, 0.55) 0%, rgba(6, 14, 12, 0.9) 100%);
  box-shadow: inset 0 1px 0 rgba(167, 243, 208, 0.06);
}

.panel h3 {
  margin: 0 0 14px;
  font-size: 14px;
  font-weight: 700;
  text-align: center;
  color: #e8f2ec;
}

.intro {
  margin: 18px 0 0;
  text-align: center;
  font-size: 12.5px;
  color: #c3d6cd;
}

/* Language picker: first visit and the Account entry. */
.language-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-bottom: 14px;
}

.language-btn {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 12px 13px;
  border-radius: 11px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: linear-gradient(180deg, #17211d, #0c1311);
  color: #e6f1eb;
  text-align: left;
}

.language-btn span { font-size: 14px; font-weight: 700; }

.language-btn small {
  color: #84998f;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
}

.language-btn.is-active {
  border-color: rgba(52, 211, 153, 0.72);
  background: linear-gradient(180deg, rgba(52, 211, 153, 0.18), rgba(52, 211, 153, 0.04));
  color: var(--accent);
}

.language-panel h3 {
  margin: 0;
  text-align: start;
}

.language-current { margin: 2px 0 0; font-size: 12px; }

.currency-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.currency-btn {
  padding: 12px 10px;
  border-radius: 11px;
  border: 1px solid rgba(52, 211, 153, 0.35);
  background: linear-gradient(180deg, #17211d, #0c1311);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #e6f1eb;
}

.currency-btn small {
  display: block;
  margin-top: 2px;
  font-size: 10px;
  font-weight: 500;
  color: #84998f;
}

.notes {
  margin: 14px 2px 4px;
  padding-left: 16px;
  font-size: 11.5px;
  line-height: 1.65;
  color: #93a79d;
}

.notes li { margin-bottom: 8px; }
.notes li::marker { color: var(--accent); }
.notes b { color: var(--accent); font-weight: 700; }
.notes a { color: var(--accent-soft); text-decoration: none; }

/* Top-up helper: card-free ways to get the crypto for an invoice. */
.crypto-help {
  margin: 14px 0 0;
  overflow: hidden;
  text-align: start;
  border: 1px solid rgba(52, 211, 153, 0.24);
  border-radius: 12px;
  background: rgba(52, 211, 153, 0.055);
}

.crypto-help summary {
  display: flex;
  gap: 9px;
  align-items: center;
  padding: 11px 12px;
  color: #dff0e7;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
  list-style: none;
  cursor: pointer;
}

.crypto-help summary::-webkit-details-marker { display: none; }

.crypto-help summary::after {
  content: "+";
  margin-inline-start: auto;
  color: var(--accent);
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
}

.crypto-help[open] summary::after { content: "−"; }

.crypto-help-q {
  display: inline-grid;
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  place-items: center;
  border: 1px solid rgba(52, 211, 153, 0.6);
  border-radius: 50%;
  color: var(--accent);
  font-size: 11px;
}

.crypto-help-body {
  padding: 0 12px 12px;
  color: #a9bdb3;
  font-size: 11.5px;
  line-height: 1.55;
}

.crypto-help-intro { margin: 0 0 4px; }

.crypto-help-option {
  padding: 10px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.crypto-help-title {
  margin-bottom: 4px;
  color: #e6f1eb;
  font-size: 12px;
  font-weight: 800;
}

.crypto-help-option p { margin: 0 0 7px; }

.crypto-shops {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.crypto-shop {
  display: inline-flex;
  gap: 4px;
  align-items: center;
  padding: 6px 9px;
  border: 1px solid rgba(52, 211, 153, 0.35);
  border-radius: 8px;
  color: #a7f3d0;
  font-size: 11px;
  font-weight: 700;
  text-decoration: none;
}

.crypto-shop:active { transform: translateY(1px); }

.crypto-help-accepted {
  margin-top: 7px;
  color: #6ee7b7;
  font-weight: 700;
}

.crypto-help-warning {
  margin: 0;
  padding: 9px 10px;
  border-radius: 8px;
  background: rgba(255, 180, 80, 0.08);
  color: #e8d4b0;
  font-size: 11px;
}

.history-row {
  display: grid;
  grid-template-columns: 52px 1fr auto auto;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  margin-bottom: 8px;
  border-radius: 999px;
  border: 1px solid rgba(52, 211, 153, 0.3);
  background: linear-gradient(180deg, #0d1512, #080e0c);
  font-size: 12px;
}

.history-row .cur { font-weight: 800; color: var(--accent); }
.history-row .when { color: #93a79d; font-size: 11px; }
.history-row .state { font-size: 11.5px; font-weight: 700; }
.history-row .state.pending { color: #60a5fa; }
.history-row .state.completed { color: var(--ok); }
.history-row .state.expired,
.history-row .state.deleted { color: var(--danger); }
.history-row .sum { font-weight: 800; color: #e8f2ec; }

/* --- customer orders --------------------------------------------------- */
.order-row {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 11px 14px;
  margin-bottom: 8px;
  text-align: left;
  border-radius: 12px;
  border: 1px solid rgba(52, 211, 153, 0.3);
  background: linear-gradient(180deg, #0d1512, #080e0c);
  font-size: 12px;
}

.order-row .ref {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.order-row .ref b { font-weight: 800; color: var(--accent); font-size: 12.5px; }
.order-row .ref small {
  color: #93a79d;
  font-size: 11px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.order-row .when { color: #93a79d; font-size: 11px; }
.order-row .state { font-size: 11.5px; font-weight: 700; }
.order-row .state.pending { color: #60a5fa; }
.order-row .state.completed { color: var(--ok); }
.order-row .state.cancelled { color: var(--danger); }
.order-row .sum { font-weight: 800; color: #e8f2ec; }

.order-status {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  margin: 0 0 14px;
  font-size: 11.5px;
  color: #93a79d;
}

.order-status b {
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.order-status.pending b { color: #60a5fa; border-color: rgba(96, 165, 250, 0.45); }
.order-status.completed b { color: var(--ok); border-color: rgba(94, 234, 212, 0.45); }
.order-status.cancelled b { color: var(--danger); border-color: rgba(242, 85, 90, 0.45); }

.order-pickup {
  margin: 0 0 12px;
  text-align: center;
  font-size: 12px;
  color: #9db3a9;
}

.order-pickup b { color: var(--accent-soft); }

.order-items {
  border-radius: 12px;
  border: 1px solid rgba(52, 211, 153, 0.22);
  background: rgba(8, 16, 13, 0.7);
  overflow: hidden;
}

.order-line {
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: baseline;
  gap: 10px;
  padding: 9px 12px;
  font-size: 12px;
  border-bottom: 1px solid rgba(52, 211, 153, 0.12);
}

.order-line:last-child { border-bottom: 0; }
.order-line .what { font-weight: 700; color: #eaf4ef; }
.order-line .qty { color: var(--accent-soft); font-size: 11.5px; }
.order-line .sum { font-weight: 800; }

.order-note {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(52, 211, 153, 0.32);
  background: rgba(9, 35, 27, 0.55);
  font-size: 12px;
  line-height: 1.55;
  color: #dcece4;
}

.order-note b { color: var(--accent); }
.order-note.is-off {
  border-color: rgba(242, 85, 90, 0.4);
  background: rgba(60, 14, 16, 0.4);
}

.order-note.is-off b { color: var(--danger); }

.order-photo {
  margin-top: 12px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(52, 211, 153, 0.32);
}

.order-photo img { width: 100%; }

/* --- cart coupon ------------------------------------------------------- */
.coupon-box {
  margin: 14px 0 4px;
  padding: 12px;
  border: 1px dashed rgba(52, 211, 153, 0.28);
  border-radius: 12px;
  background: rgba(9, 25, 20, 0.55);
}

.coupon-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.coupon-form { display: flex; gap: 8px; margin-top: 8px; }

.coupon-form input {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid rgba(52, 211, 153, 0.22);
  border-radius: 9px;
  background: #08110e;
  color: var(--text);
  font: inherit;
  /* 16px avoids the automatic zoom iOS applies to smaller form fields. */
  font-size: 16px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.coupon-form input:focus { outline: none; border-color: var(--accent); }

.coupon-form button {
  padding: 0 14px;
  border-radius: 9px;
  background: var(--accent);
  color: #04110c;
  font-size: 12px;
  font-weight: 800;
}

.coupon-box.is-applied {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-style: solid;
}

.coupon-copy { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.coupon-code { font-size: 13px; font-weight: 800; letter-spacing: 0.08em; color: var(--accent); }
.coupon-meta { font-size: 11.5px; color: var(--muted); }
.coupon-remove { color: var(--muted); font-size: 11px; text-decoration: underline; }
.total-row.discount-row { color: var(--accent); }

/* --- orders ------------------------------------------------------------ */
.orders-page { width: 100%; max-width: 780px; margin: 0 auto; }

.orders-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 6px 2px 0;
}

.orders-head h1 {
  margin: 0;
  font-size: 21px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.orders-head p { margin: 5px 0 0; font-size: 12.5px; line-height: 1.5; }
.orders-head .refresh { flex: 0 0 auto; margin-top: 2px; }
.orders-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  margin-top: 2px;
}
.orders-head-actions .refresh { margin-top: 0; }
.orders-manage {
  flex: 0 0 auto;
  padding: 9px 12px;
  border-radius: 11px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
}
.orders-manage:hover {
  color: var(--text);
  border-color: rgba(52, 211, 153, 0.45);
}
.clear-orders-options { display: grid; gap: 8px; margin: 0 0 14px; }
.clear-orders-options .cta { width: 100%; }
/* Search over the order list, with its own clear button underneath/next to it. */
.orders-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
}

.orders-search {
  position: relative;
  flex: 1 1 auto;
  display: block;
}

.orders-search svg {
  position: absolute;
  left: 12px;
  top: 50%;
  width: 16px;
  height: 16px;
  transform: translateY(-50%);
  color: #6ee7b7;
  pointer-events: none;
}

.orders-search input {
  box-sizing: border-box;
  width: 100%;
  padding: 11px 12px 11px 36px;
  border-radius: 11px;
  border: 1px solid rgba(52, 211, 153, 0.28);
  background: #0a100e;
  color: var(--text);
  font-family: inherit;
  /* 16px stops iOS/Telegram WebView from zooming on focus. */
  font-size: 16px;
  outline: none;
}

.orders-search input:focus { border-color: rgba(52, 211, 153, 0.6); }

.orders-clear {
  flex: 0 0 auto;
  padding: 10px 14px;
  border-radius: 11px;
  border: 1px solid rgba(248, 113, 113, 0.45);
  background: rgba(248, 113, 113, 0.1);
  color: #fca5a5;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
}

.orders-clear[hidden] { display: none; }

.orders-panel { margin-top: 16px; }
.orders-empty { padding: 24px 6px; }

/* --- tab bar ----------------------------------------------------------- */
.tabbar {
  position: fixed;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 100%;
  max-width: 430px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  padding: 8px 6px calc(10px + var(--safe));
  background: linear-gradient(180deg, rgba(5, 10, 9, 0.86), #040706 60%);
  border-top: 1px solid rgba(52, 211, 153, 0.16);
  backdrop-filter: blur(14px);
  z-index: 40;
}

.tab {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 4px 0;
  min-width: 0;
  color: #7e9a8d;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.tab span {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tab svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tab.is-active { color: var(--accent); }
.tab.is-active svg { filter: drop-shadow(0 0 6px rgba(52, 211, 153, 0.45)); }

.badge {
  position: absolute;
  top: 0;
  left: calc(50% + 7px);
  min-width: 15px;
  height: 15px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--accent);
  color: #04231a;
  font-size: 9.5px;
  font-style: normal;
  font-weight: 800;
  line-height: 15px;
  text-align: center;
}

/* A red dot marks orders the customer has not looked at yet. */
.badge--alert {
  background: var(--danger);
  color: #fff;
  box-shadow: 0 0 0 2px rgba(6, 10, 9, 0.9);
}

/* --- sheets ------------------------------------------------------------ */
.overlay {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(0, 0, 0, 0.62);
  backdrop-filter: blur(7px);
  animation: fade 0.18s ease;
}

.overlay[hidden] { display: none; }

/* Full-screen view for the content photos beside the description. */
.photo-viewer {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: clamp(16px, 4vw, 36px);
  background: rgba(2, 8, 6, 0.94);
  backdrop-filter: blur(10px);
  animation: fade 0.18s ease;
}

.photo-viewer[hidden] { display: none; }

.photo-viewer-image {
  display: block;
  flex: 0 1 auto;
  min-width: 0;
  min-height: 0;
  max-width: min(74vw, 360px);
  max-height: 52vh;
  max-height: 52dvh;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.55);
}

.photo-viewer-close {
  position: absolute;
  top: clamp(12px, 3vw, 24px);
  right: clamp(12px, 3vw, 24px);
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  background: rgba(4, 10, 8, 0.8);
  color: #e8f2ec;
  backdrop-filter: blur(8px);
}

.photo-viewer-close svg { width: 16px; height: 16px; }

[dir="rtl"] .photo-viewer-close { right: auto; left: clamp(12px, 3vw, 24px); }

@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.sheet {
  position: relative;
  width: min(94vw, 390px);
  max-height: 86dvh;
  overflow-y: auto;
  padding: 22px 16px 18px;
  border-radius: 18px;
  border: 1px solid rgba(52, 211, 153, 0.32);
  background: linear-gradient(180deg, #121a17 0%, #090f0d 100%);
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.8), inset 0 1px 0 rgba(167, 243, 208, 0.05);
  animation: pop 0.2s ease;
}

@keyframes pop {
  from { transform: translateY(10px) scale(0.98); opacity: 0; }
  to { transform: none; opacity: 1; }
}

/* Back out of a sheet that was opened from another one. It stays pinned to the
   top of the sheet while the text scrolls, so it never scrolls out of reach. */
.sheet-back {
  position: sticky;
  top: 0;
  left: 0;
  z-index: 6;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin: 0 0 10px;
  padding: 4px 11px 4px 6px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(12, 20, 17, 0.94);
  backdrop-filter: blur(6px);
  color: #c8d9d0;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}

.sheet-back:active { transform: scale(0.97); }

[dir="rtl"] .sheet-back { left: auto; right: 0; }

.sheet-back[hidden] { display: none; }
.sheet-back svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sheet.has-back { padding-top: 14px; }

.sheet-x {
  position: absolute;
  top: 8px;
  right: 12px;
  padding: 4px;
  color: #a9bdb3;
  font-size: 18px;
  line-height: 1;
}

.sheet-x svg {
  display: block;
  width: 15px;
  height: 15px;
}

.sheet h2 {
  margin: 4px 0 16px;
  font-size: 14px;
  font-weight: 700;
  text-align: center;
  color: #e8f2ec;
}

/* Product detail: a cover or a gallery with a vertical thumbnail rail. */
.product-detail { margin: -22px -16px -18px; }

.product-detail .sheet-x {
  top: 12px;
  right: 12px;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 50%;
  background: rgba(4, 10, 8, 0.78);
  color: #e8f2ec;
  backdrop-filter: blur(8px);
}

.product-detail .sheet-x svg { width: 14px; height: 14px; }

/* Parent product: its gallery and description photos, then the flavour cards. */
.variant-picker-hint {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.variant-picker .variant-grid { padding: 8px 0 22px; }

.product-cover {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-bottom: 1px solid rgba(52, 211, 153, 0.16);
  background: linear-gradient(145deg, #15211d, #080e0c);
}

.product-cover img { width: 100%; height: 100%; object-fit: cover; }

.product-cover.is-empty::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 72px;
  height: 72px;
  transform: translate(-50%, -50%);
  background: url("/static/logo-mark.png") center / contain no-repeat;
  opacity: 0.5;
}

.product-gallery {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr) auto;
  gap: 10px;
  aspect-ratio: 4 / 3;
  padding: 10px;
  overflow: hidden;
  border-bottom: 1px solid rgba(52, 211, 153, 0.16);
  background: #080e0c;
}

.gallery-frame {
  position: relative;
  grid-column: 1;
  grid-row: 1;
  min-width: 0;
  min-height: 0;
  height: 100%;
  overflow: hidden;
  border-radius: 10px;
  background: linear-gradient(145deg, #15211d, #080e0c);
  touch-action: pan-y;
}

.gallery-slide {
  display: none;
  width: 100%;
  height: 100%;
  position: relative;
}

.gallery-slide.is-active { display: block; }

.gallery-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-slide.is-empty::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 72px;
  height: 72px;
  transform: translate(-50%, -50%);
  background: url("/static/logo-mark.png") center / contain no-repeat;
  opacity: 0.5;
}

.gallery-arrow {
  position: absolute;
  top: 50%;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  padding: 0 0 3px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  background: rgba(4, 10, 8, 0.72);
  color: #e8f2ec;
  font: 25px/1 Georgia, serif;
  transform: translateY(-50%);
  backdrop-filter: blur(8px);
}

.gallery-arrow.prev { left: 10px; }
.gallery-arrow.next { right: 10px; }

.gallery-count {
  position: absolute;
  right: 10px;
  bottom: 10px;
  padding: 3px 8px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  background: rgba(4, 10, 8, 0.72);
  color: #d8e8e0;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.4;
  backdrop-filter: blur(8px);
}

.gallery-count b { color: var(--accent); }

/* Thumbnail rail under the main photo, so every product photo is one tap away. */
.gallery-thumbs {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 54px;
  gap: 8px;
  overflow-x: auto;
  padding: 2px 0;
  scrollbar-width: none;
}

.gallery-thumbs::-webkit-scrollbar { display: none; }

.gallery-thumb {
  width: 54px;
  height: 54px;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: #0b1210;
  cursor: pointer;
}

.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-thumb.is-active {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
}

.product-body { padding: 16px; }

/* Product page header: back to the shelf, category line, then the title. */
.product-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: var(--accent);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.product-back:hover { text-decoration: underline; }

.variant-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin: 18px 0 10px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.variant-head h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 800;
  color: #e8f2ec;
}

.variant-head span {
  font-size: 11.5px;
  color: var(--muted);
}

.variant-card.is-selected {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent), 0 10px 24px rgba(0, 0, 0, 0.35);
}

/* Rating, facts and the buy row: the right column of the product mock-up. */
.product-rating {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 14px;
}

.rating-stars {
  color: #f5c451;
  font-size: 13px;
  letter-spacing: 0.08em;
}

.product-rating b { font-size: 12.5px; font-weight: 800; }
.product-rating small { font-size: 11.5px; color: var(--muted); }

/* Real reviews on the product sheet: one per completed order, so each card can
   honestly say "verified purchase". */
.product-reviews {
  margin: 16px 0 4px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.reviews-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.reviews-head h3 { margin: 0; font-size: 14px; font-weight: 800; }
.reviews-head span { font-size: 11.5px; color: var(--muted); }

.review {
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.review:last-child { border-bottom: 0; }

.review-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.review-head b { font-size: 12px; font-weight: 800; }
.review-date { margin-left: auto; font-size: 11px; color: var(--muted); }
.review-text { margin: 0 0 6px; font-size: 13px; line-height: 1.5; }

.review-verified {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(62, 207, 142, 0.12);
  color: #3ecf8e;
  font-size: 10.5px;
  font-weight: 700;
}

.review-reply {
  margin-top: 8px;
  padding: 8px 10px;
  border-left: 2px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.03);
}

.review-reply b { display: block; font-size: 11px; opacity: 0.75; }
.review-reply p { margin: 3px 0 0; font-size: 12.5px; line-height: 1.45; }

.product-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0 4px;
  padding: 12px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.product-facts .fact b { display: block; font-size: 14px; font-weight: 800; }

.product-facts .fact small {
  display: block;
  margin-top: 2px;
  font-size: 10.5px;
  color: var(--muted);
}

.product-buy {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}

.product-buy .product-price {
  flex: 1 1 140px;
  min-width: 0;
  margin: 0;
  padding-top: 0;
  border-top: 0;
}

.product-buy .product-price small {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.product-buy .cta { flex: 1 1 190px; min-width: 0; margin: 0; }

.product-note { margin: 12px 0 0; font-size: 10.5px; color: var(--muted); }

.product-backrow { display: flex; padding: 14px 16px 0; }

/* Category and stock pill laid over the big product photo. */
.gallery-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 2;
  padding: 6px 11px;
  border: 1px solid rgba(52, 211, 153, 0.55);
  border-radius: 999px;
  background: rgba(6, 14, 11, 0.86);
  color: var(--accent);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  backdrop-filter: blur(8px);
}

.product-body h2 {
  margin: 0 0 9px;
  text-align: left;
  font-size: 20px;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.product-meta {
  margin-bottom: 8px;
  color: #9db3a9;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.product-category {
  padding: 4px 9px;
  border: 1px solid rgba(52, 211, 153, 0.5);
  border-radius: 999px;
  background: rgba(52, 211, 153, 0.1);
  color: var(--accent);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.product-stock { font-size: 11.5px; color: #9db3a9; }
.product-stock.is-out { color: #ff9d9d; }

.product-description {
  margin: 0 0 14px;
  text-align: left;
  display: grid;
  gap: 6px;
  font-size: 12.5px;
  line-height: 1.45;
  color: #c8d9d1;
}

.product-description .desc-row {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 10px;
  align-items: baseline;
}

.product-description .desc-label {
  color: #8ea99d;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
}

.product-description .desc-value { color: #d6e6de; }

.product-description .desc-text { margin: 0; }

/* A description line written as "# Titel" heads the sheet: the brand or line
   name sits above the facts, so the article name stays the article name. */
.product-description .desc-title {
  margin: 0 0 10px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--text);
}

/* Phone: a label/value pair squeezed into two columns leaves the value a narrow
   ribbon that wraps every other word. Stacking the label above the value gives
   the text the full width and keeps long descriptions scannable. */
@media (max-width: 600px) {
  .product-description {
    gap: 0;
    font-size: 13.5px;
    line-height: 1.5;
  }

  .product-description .desc-row {
    grid-template-columns: minmax(0, 1fr);
    gap: 2px;
    padding: 9px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
  }

  .product-description .desc-row:first-child {
    padding-top: 0;
    border-top: 0;
  }

  .product-description .desc-label {
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #7f9c8f;
  }

  .product-description .desc-value {
    color: var(--text);
    overflow-wrap: break-word;
  }
}

/* Content and close-up photos in the description column. They are not part
   of the gallery; multiple photos form a three-column row. */
.product-detail-photos {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 14px;
}

.product-detail-photo {
  display: block;
  min-width: 0;
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: #0b1210;
  cursor: zoom-in;
  overflow: hidden;
}

.product-detail-photo:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.product-detail-photos img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  background: #0b1210;
  transition: transform 0.2s ease;
}

.product-detail-photo:hover img,
.product-detail-photo:focus-visible img { transform: scale(1.03); }

.product-detail-photos.is-single .product-detail-photo {
  grid-column: 1 / -1;
}

.product-detail-photos.is-single img {
  grid-column: 1 / -1;
  aspect-ratio: 4 / 3;
}

.sheet-product .product-detail-photos {
  gap: 12px;
  margin: 4px 0 20px;
}

.sheet-product .product-detail-photos img { border-radius: 12px; }

.flag-emoji {
  display: inline-block;
  position: static;
  inset: auto;
  width: auto;
  height: 0.74em;
  /* A stray `img { width: 100% }` rule must never blow a flag up to a poster. */
  max-width: 2.4em;
  max-height: 1em;
  object-fit: contain;
  filter: none;
  vertical-align: -0.04em;
  border-radius: 2px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.product-price {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px;
  margin: 2px 0 12px;
  padding-top: 13px;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
}

.product-price b {
  font-size: 26px;
  font-weight: 900;
  line-height: 1;
  color: var(--accent);
}

.product-price em {
  font-style: normal;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--accent-soft);
}

.product-price small {
  flex-basis: 100%;
  margin-top: 3px;
  font-size: 11.5px;
  color: var(--muted);
}

/* Flavour picker: one photo per flavour, two per row on a phone. */
.variant-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 4px;
}

.variant-card {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 7px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  background: #0d1512;
  color: var(--text);
  text-align: start;
}

/* The cover only: a country flag inside the name is an image as well. */
.variant-card > img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 9px;
  background: #16201c;
}

.variant-card span {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.3;
}
.variant-card small { color: var(--accent); font-size: 10.5px; font-weight: 700; }
/* The remaining count of this flavour, quieter than its price. */
.variant-card em { font-style: normal; font-size: 10px; font-weight: 600; color: var(--muted); }
.variant-card.is-selected em { color: rgba(255, 255, 255, 0.7); }
.variant-card:active { border-color: rgba(52, 211, 153, 0.65); }

.product-stock { margin: 6px 0 0; font-size: 13.5px; font-weight: 800; color: var(--accent); }
.product-stock.is-out { color: #ff9d9d; }

.sheet .stack { display: grid; gap: 10px; }

.city-btn {
  padding: 12px;
  border-radius: 11px;
  border: 1px solid rgba(52, 211, 153, 0.4);
  background: linear-gradient(180deg, #16201c, #0d1412);
  font-size: 13px;
  font-weight: 700;
  color: #e6f1eb;
}

.area-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.area-btn {
  padding: 11px 8px;
  border-radius: 11px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  background: #141d19;
  font-size: 12.5px;
  color: #cfded7;
}

.area-btn.is-active {
  border-color: rgba(52, 211, 153, 0.75);
  color: var(--accent);
}

.location-search {
  position: relative;
  display: block;
  margin: 2px 0 4px;
}

.location-search svg {
  position: absolute;
  left: 13px;
  top: 50%;
  width: 16px;
  height: 16px;
  transform: translateY(-50%);
  color: #6ee7b7;
  pointer-events: none;
}

.location-search input {
  box-sizing: border-box;
  width: 100%;
  padding: 12px 14px 12px 38px;
  border-radius: 11px;
  border: 1px solid rgba(52, 211, 153, 0.28);
  background: #0a100e;
  color: var(--text);
  font-family: inherit;
  /* 16px stops iOS/Telegram WebView from zooming the sheet on focus. */
  font-size: 16px;
  outline: none;
}

.location-search input:focus {
  border-color: rgba(52, 211, 153, 0.72);
  box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.12);
}

.location-search input::placeholder { color: #70877c; }

.location-group {
  display: grid;
  gap: 9px;
  margin-top: 12px;
}

.location-group-title {
  padding: 0 2px;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #8fb8a6;
}

.location-area-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.location-area-btn {
  display: flex;
  min-height: 48px;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 2px;
  text-align: left;
  line-height: 1.25;
  word-break: break-word;
}

.location-area-btn small {
  font-size: 10px;
  font-weight: 600;
  color: #7f9a8e;
}

.location-no-results { margin: 14px 0 0; text-align: center; }

.location-group[hidden],
[data-location-row][hidden],
[data-location-empty][hidden] {
  display: none;
}

.amount-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 9px;
}

.amount-row input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 11px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: #0a100e;
  color: var(--text);
  font-size: 14px;
  outline: none;
}

.amount-row input:focus { border-color: rgba(52, 211, 153, 0.65); }

.amount-row input::placeholder { color: #6f857a; }

.amount-row .go {
  padding: 0 18px;
  border-radius: 11px;
  background: var(--accent-grad);
  color: #04231a;
  font-size: 12.5px;
  font-weight: 800;
}

.warn {
  margin-top: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-size: 12px;
  font-weight: 600;
  color: #dff0e7;
}

.warn i { color: var(--accent); font-style: normal; }

/* Cart: the order total is under the shop's minimum order value. */
.warn.min-order {
  justify-content: flex-start;
  margin: 0 2px 10px;
  padding: 9px 12px;
  border-radius: 10px;
  border: 1px solid rgba(52, 211, 153, 0.35);
  background: rgba(52, 211, 153, 0.07);
  font-size: 11.5px;
}

.qr-box {
  width: 156px;
  margin: 4px auto 16px;
  padding: 8px;
  border-radius: 12px;
  background: #fff;
}

.qr-box img { width: 100%; height: auto; }

.field {
  margin-bottom: 14px;
  text-align: center;
}

.field .label { font-size: 12px; color: #c3d6cd; margin-bottom: 7px; }

.field .value {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 700;
  color: #e6f1eb;
  word-break: break-all;
}

.field .value code {
  font-family: ui-monospace, "SF Mono", Consolas, monospace;
  font-size: 11.5px;
  color: #a7f3d0;
  background: #081713;
  border: 1px solid rgba(52, 211, 153, 0.28);
  border-radius: 8px;
  padding: 4px 8px;
}

.icon-btn {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--accent-grad);
  color: #04231a;
}

.icon-btn svg { width: 13px; height: 13px; }

.danger-btn {
  width: 100%;
  padding: 13px;
  border-radius: 12px;
  background: linear-gradient(180deg, #ef5b60, #b02a30);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
}

.check {
  width: 66px;
  height: 66px;
  margin: 6px auto 16px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--ok);
  color: #052b26;
}

.check svg { width: 32px; height: 32px; }

.sheet-text {
  text-align: center;
  font-size: 13px;
  line-height: 1.5;
  color: #e2efe8;
  margin: 0 0 18px;
}

.sheet-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.sheet-actions.single { grid-template-columns: 1fr; }

/* --- support chat ------------------------------------------------------ */
.support-head {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 26px;
}

.support-head h2 { margin: 4px 0 6px; }

.support-status {
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid rgba(52, 211, 153, 0.36);
  background: rgba(52, 211, 153, 0.1);
  color: var(--accent);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.support-status.closed {
  border-color: rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
  color: #9db3a9;
}

.support-intro {
  margin: 0 0 12px;
  font-size: 12px;
  color: #9db3a9;
}

.support-thread {
  display: flex;
  flex-direction: column;
  gap: 9px;
  max-height: 42dvh;
  margin-bottom: 12px;
  padding: 2px 2px 8px;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.support-msg {
  max-width: 88%;
  padding: 9px 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  background: #101a16;
  color: #dfece5;
  font-size: 13px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.support-msg.mine {
  align-self: flex-end;
  border-color: rgba(52, 211, 153, 0.36);
  background: rgba(52, 211, 153, 0.12);
}

.support-msg.shop { align-self: flex-start; }

.support-who {
  display: block;
  margin-bottom: 4px;
  color: #84a496;
  font-size: 10px;
  font-weight: 600;
}

.support-body {
  display: block;
  white-space: pre-wrap;
}

.support-empty { padding: 22px 10px; margin: 0; }

.support-closed {
  margin: 4px 0 0;
  color: #9db3a9;
  font-size: 11px;
  line-height: 1.45;
  text-align: center;
}

.support-compose { display: grid; gap: 8px; }

.support-compose textarea {
  width: 100%;
  min-height: 76px;
  max-height: 150px;
  padding: 10px 12px;
  resize: vertical;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 11px;
  outline: none;
  background: #0a100e;
  color: var(--text);
  font: inherit;
  font-size: 13px;
  line-height: 1.4;
}

.support-compose textarea:focus { border-color: rgba(52, 211, 153, 0.65); }
.support-compose textarea::placeholder { color: #6f857a; }
.support-compose .cta { height: 46px; }

.countdown {
  text-align: center;
  font-size: 11px;
  color: #9db3a9;
  margin-bottom: 14px;
}

.countdown b { color: var(--accent); }

/* --- toast ------------------------------------------------------------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(84px + var(--safe));
  transform: translate(-50%, 12px);
  z-index: 80;
  max-width: 86vw;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid rgba(52, 211, 153, 0.3);
  background: rgba(8, 20, 16, 0.96);
  color: #eaf4ef;
  font-size: 12.5px;
  font-weight: 600;
  text-align: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* The brand greeting should be seen before it fades: put only that toast in
   the upper content area instead of letting it hide near the bottom bar. */
.toast.toast--welcome {
  top: calc(96px + env(safe-area-inset-top, 0px));
  bottom: auto;
  transform: translate(-50%, -12px);
  z-index: 90;
  padding: 12px 18px;
  border-color: rgba(52, 211, 153, 0.48);
  background: rgba(8, 20, 16, 0.98);
  font-size: 14px;
}

.toast.toast--welcome.is-on { transform: translate(-50%, 0); }

.skeleton {
  height: 12px;
  border-radius: 6px;
  background: linear-gradient(90deg, #141d19, #1b2521, #141d19);
  background-size: 200% 100%;
  animation: shimmer 1.2s infinite;
}

@keyframes shimmer {
  from { background-position: 200% 0; }
  to { background-position: -200% 0; }
}

/* Arabic is right-to-left; mirror the controls that are pinned to a side. */
[dir="rtl"] .sheet-x { right: auto; left: 12px; }
[dir="rtl"] .badge { left: auto; right: calc(50% + 7px); }
[dir="rtl"] .wallet-text { margin-left: 44px; }
[dir="rtl"] .coin { right: auto; left: 8px; }
[dir="rtl"] .stepper { margin-left: 0; margin-right: auto; }
[dir="rtl"] .copy-dot { margin-left: 0; margin-right: 8px; }
[dir="rtl"] .notes { padding-left: 0; padding-right: 16px; }
[dir="rtl"] .order-row,
[dir="rtl"] .history-row { text-align: right; }
[dir="rtl"] .card { text-align: right; }
[dir="rtl"] .total-row b i { margin-left: 0; margin-right: 3px; }
[dir="rtl"] .language-btn { align-items: flex-end; text-align: right; }

@media (min-width: 520px) {
  .phone { border-left: 1px solid #121a17; border-right: 1px solid #121a17; }
}

/* The Mini App still owns the phone layout, but a desktop client is a website:
   full-width header, a real navigation row and a content canvas that grows with
   the window. Nothing below this breakpoint changes the phone experience. */
@media (min-width: 900px) {
  body {
    background:
      radial-gradient(80rem 40rem at 50% -20%, rgba(8, 33, 26, 0.55), transparent 65%),
      #040706;
  }

  .phone {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-rows: auto auto auto 1fr;
    width: 100%;
    max-width: none;
    min-height: 100dvh;
    margin: 0;
    border: 0;
    overflow: visible;
    background: transparent;
  }

  .ticker {
    grid-column: 1 / -1;
    grid-row: 1;
    /* Match the centered content column instead of spanning wide monitors. */
    width: 100%;
    max-width: 1320px;
    justify-self: center;
    border-radius: 0 0 14px 14px;
  }

  .ticker-group { min-height: 42px; font-size: 13.5px; }

  .titlebar {
    grid-column: 1;
    grid-row: 2;
    align-self: center;
    padding: 24px clamp(24px, 4.5vw, 64px) 10px;
  }

  .brand { gap: 11px; font-size: 21px; }
  .brand-mark { width: 32px; height: 32px; }
  .dots { display: none; }

  .wallet {
    grid-column: 2;
    grid-row: 2;
    align-self: center;
    width: 310px;
    min-height: 66px;
    margin: 18px clamp(24px, 4.5vw, 64px) 10px 18px;
    padding: 10px 18px;
    border-radius: 16px;
  }

  .wallet-label { font-size: 12px; }
  .wallet-amount b { font-size: 25px; }
  .wallet-amount em { font-size: 12px; }

  .tabbar {
    grid-column: 1 / -1;
    grid-row: 3;
    position: sticky;
    top: 0;
    left: auto;
    bottom: auto;
    transform: none;
    width: 100%;
    max-width: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px clamp(24px, 4.5vw, 64px);
    border-top: 1px solid rgba(52, 211, 153, 0.1);
    border-bottom: 1px solid rgba(52, 211, 153, 0.16);
    background: rgba(4, 7, 6, 0.78);
    backdrop-filter: blur(18px);
    z-index: 40;
  }

  .tab {
    flex-direction: row;
    gap: 8px;
    padding: 9px 18px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
  }

  .tab svg { width: 19px; height: 19px; }

  .tab.is-active {
    background: rgba(52, 211, 153, 0.1);
    box-shadow: inset 0 0 0 1px rgba(52, 211, 153, 0.2);
  }

  .tabbar .badge {
    position: static;
    min-width: 18px;
    height: 18px;
    margin-left: 2px;
    font-size: 10px;
    line-height: 18px;
  }

  .view {
    grid-column: 1 / -1;
    grid-row: 4;
    width: 100%;
    max-width: 1320px;
    margin: 0 auto;
    padding: 34px clamp(24px, 4.5vw, 64px) 84px;
  }

  .view[data-tab="cart"],
  .view[data-tab="account"],
  .view[data-tab="orders"] { max-width: 1080px; }

  .section-title { margin: 24px 4px 12px; font-size: 14px; }

  .empty {
    max-width: 620px;
    margin: 0 auto;
    padding: 80px 24px;
    font-size: 15px;
  }

  .hero {
    height: clamp(320px, 31vw, 460px);
    aspect-ratio: auto;
    border-radius: 24px;
  }

  .slide-mark { width: clamp(96px, 9.5vw, 148px); }

  .wordmark .big { font-size: clamp(72px, 7.5vw, 118px); }

  .wordmark .small {
    margin-top: 10px;
    font-size: clamp(28px, 3vw, 46px);
    letter-spacing: 0.32em;
  }

  .hero-meta { bottom: 22px; font-size: 13px; }

  .dots-nav { gap: 9px; margin: 18px 0 0; }
  .dots-nav button { width: 32px; height: 6px; }

  .hero + .dots-nav + .cta {
    max-width: 360px;
    height: 58px;
    margin: 22px auto 0;
    font-size: 15px;
  }

  .cta { border-radius: 14px; }

  .category-row { flex-wrap: wrap; gap: 10px; padding: 16px 0 8px; }
  .chip { padding: 9px 18px; font-size: 13px; }

  .grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-top: 18px;
  }

  .card {
    aspect-ratio: 0.94;
    border-radius: 18px;
    cursor: pointer;
    transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  }

  .card .name { left: 14px; right: 14px; bottom: 44px; font-size: 15px; }

  .card .price {
    left: 12px;
    bottom: 12px;
    padding: 5px 12px;
    border-radius: 10px;
    font-size: 14px;
  }

  .card .price i { font-size: 11px; }

  .card .add { right: 12px; bottom: 12px; width: 42px; height: 42px; }
  .card .add svg { width: 20px; height: 20px; }

  .card-stock { top: 12px; left: 12px; padding: 6px 12px; font-size: 13px; }

  .view[data-tab="account"] .account-block { padding: 8px 4px 4px; }
  .big-balance { font-size: 42px; }
  .big-balance em { font-size: 14px; }

  .panel { margin-top: 20px; padding: 24px; border-radius: 20px; }
  .panel h3 { margin-bottom: 18px; font-size: 17px; }

  .intro { margin-top: 24px; font-size: 14px; }
  .notes { font-size: 13px; line-height: 1.7; }

  .currency-grid { grid-template-columns: repeat(3, 1fr); gap: 12px; }

  .currency-btn {
    padding: 16px 14px;
    border-radius: 14px;
    font-size: 15px;
  }

  .language-grid { grid-template-columns: repeat(2, 1fr); }
  .language-btn { padding: 16px; border-radius: 14px; }
  .language-btn span { font-size: 15px; }

  .order-row {
    grid-template-columns: minmax(0, 1fr) auto auto auto;
    padding: 15px 18px;
    border-radius: 14px;
    font-size: 13px;
  }

  .order-row .ref b { font-size: 14px; }
  .order-row .when,
  .order-row .ref small { font-size: 12px; }

  .history-row {
    padding: 12px 18px;
    border-radius: 14px;
    font-size: 13px;
  }

  .view[data-tab="account"] .panel .cta {
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
  }

  .view[data-tab="account"] .account-block + .panel > p { text-align: center; }

  .line {
    grid-template-columns: 64px 1fr auto;
    gap: 14px;
    padding: 16px;
    border-radius: 18px;
  }

  /* Direct child only: the flag badges inside the title are images too and
     must keep their 0.74em height. */
  .line > img { width: 64px; height: 64px; border-radius: 12px; }
  .line h4 { font-size: 15px; }
  .line .where { font-size: 12px; }
  .line .remove { padding: 5px 12px; font-size: 11.5px; }
  .line .line-price { font-size: 18px; }
  .line .line-price small { font-size: 11px; }
  .stepper button { width: 32px; height: 32px; font-size: 17px; }

  .total-row { margin: 24px 2px 16px; }
  .total-row span { font-size: 20px; }
  .total-row b { font-size: 30px; }

  .view[data-tab="cart"] > .cta {
    max-width: 420px;
    height: 56px;
    margin-left: auto;
  }

  .overlay { padding: 32px; }

  .sheet {
    width: min(92vw, 560px);
    max-height: 88dvh;
    padding: 30px 26px 26px;
    border-radius: 22px;
  }

  .sheet-x { top: 14px; right: 16px; font-size: 20px; }
  .sheet h2 { margin-bottom: 18px; font-size: 18px; }
  .sheet-text { font-size: 14px; }
  .sheet .cta { height: 54px; }

  .support-thread { max-height: 50dvh; }
  .support-msg { font-size: 14px; }

  .qr-box { width: 190px; }
  .city-btn { padding: 15px; font-size: 14px; }
  .area-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .area-btn { padding: 14px 10px; font-size: 13.5px; }
  .location-search { margin: 4px 0 8px; }
  .location-search svg { left: 15px; width: 17px; height: 17px; }
  .location-search input { padding: 13px 16px 13px 42px; font-size: 15px; }
  .location-group { gap: 10px; margin-top: 14px; }
  .location-group-title { font-size: 11px; }
  .location-area-btn { padding: 12px 10px; font-size: 13.5px; }

  .amount-row input { padding: 14px 16px; font-size: 15px; }

  .sheet-product {
    width: min(94vw, 1080px);
    padding: 28px;
  }

  .sheet-product .product-detail {
    display: grid;
    grid-template-columns: minmax(0, 1.06fr) minmax(0, 0.94fr);
    align-items: start;
    min-height: 0;
    margin: -28px;
  }

  .sheet-product .product-detail > .product-backrow {
    grid-column: 1 / -1;
    padding: 18px 18px 2px;
  }

  .sheet-product .variant-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .sheet-product .product-detail.variant-picker {
    display: block;
    min-height: 0;
  }

  .sheet-product .variant-picker .product-body {
    display: block;
    padding: 0;
  }

  .sheet-product .variant-picker-head { padding: 46px 40px 14px; }

  .sheet-product .variant-picker-thumb {
    width: 110px;
    height: 110px;
  }

  .sheet-product .variant-picker .variant-grid {
    padding: 0 40px 36px;
  }

  .sheet-product .product-cover {
    height: auto;
    min-height: 0;
    max-height: 340px;
    aspect-ratio: 4 / 3;
    border-right: 1px solid rgba(52, 211, 153, 0.16);
    border-bottom: 0;
  }

  .sheet-product .product-gallery {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    /* The photo takes all the height the right column uses, so the left side
       never ends in a big empty block. The thumbnails stay pinned at the
       bottom of that column. */
    grid-template-rows: minmax(0, 1fr) auto;
    align-self: stretch;
    gap: 12px;
    height: 100%;
    min-height: 0;
    max-height: calc(88dvh - 130px);
    padding: 18px;
    aspect-ratio: auto;
    border-right: 1px solid rgba(52, 211, 153, 0.16);
    border-bottom: 0;
  }

  .sheet-product .gallery-frame {
    grid-column: 1;
    grid-row: 1;
    height: 100%;
    /* A short article (no description, no flavours) must not shrink the photo
       into a strip, so the frame keeps a minimum height. */
    min-height: 340px;
    max-height: none;
    aspect-ratio: auto;
    border-radius: 12px;
  }

  .sheet-product .product-body {
    display: flex;
    flex-direction: column;
    padding: 46px 40px 36px;
  }

  .sheet-product .product-body h2 {
    margin-bottom: 14px;
    font-size: 32px;
    line-height: 1.15;
  }

  .sheet-product .product-description { font-size: 13.5px; line-height: 1.55; gap: 7px; }

  .sheet-product .product-description .desc-row {
    grid-template-columns: 110px 1fr;
    gap: 14px;
  }

  .sheet-product .product-description .desc-label { font-size: 11.5px; }
  .sheet-product .product-meta { margin-bottom: 18px; }

  .sheet-product .product-price {
    margin-top: auto;
    padding-top: 24px;
  }

  .sheet-product .product-price b { font-size: 38px; }
  .sheet-product .product-price small { font-size: 12.5px; }

  .sheet-product .variant-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
  }

  .sheet-product .variant-card { padding: 10px; border-radius: 14px; }
  .sheet-product .variant-card span { font-size: 14px; }
  .sheet-product .variant-card small { font-size: 12px; }

  .product-detail .sheet-x {
    top: 16px;
    right: 16px;
    width: 40px;
    height: 40px;
  }
}

@media (min-width: 1280px) {
  .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
}

@media (hover: hover) and (pointer: fine) and (min-width: 900px) {
  .card:hover {
    transform: translateY(-4px);
    border-color: rgba(52, 211, 153, 0.35);
    box-shadow: 0 18px 36px rgba(0, 0, 0, 0.38);
  }

  .tab:hover { color: var(--text); background: rgba(255, 255, 255, 0.04); }
  .chip:hover { border-color: rgba(52, 211, 153, 0.45); }
  .cta:hover { filter: brightness(1.06); }
}

/* A PC screen is wide and short. The product sheet therefore takes the height
   of the window and packs everything a customer needs into it: photo left,
   facts in two columns, flavours in one row, volume prices in two columns and
   the buy row at the bottom. Only a window that is too small to hold this
   still scrolls, so nothing can ever be cut off. */
@media (min-width: 900px) {
  .sheet-product {
    width: min(96vw, 1200px);
    /* As tall as its content, never taller than the window: the sheet hugs the
       article instead of leaving a half-empty frame, and nothing scrolls. */
    height: auto;
    max-height: min(calc(100dvh - 64px), 820px);
    padding: 0;
  }

  .sheet-product .product-detail {
    height: auto;
    min-height: 0;
    margin: 0;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    grid-template-rows: auto minmax(0, 1fr);
    align-items: stretch;
  }

  .sheet-product .product-detail > .product-backrow { padding: 12px 20px 8px; }

  .sheet-product .product-gallery {
    height: 100%;
    max-height: none;
    min-height: 0;
    padding: 14px;
    gap: 8px;
  }

  /* The photo fills the frame instead of dictating its height: a portrait shot
     must not make the sheet taller than the window. */
  .sheet-product .gallery-slide img { position: absolute; inset: 0; }

  .sheet-product .gallery-thumbs { grid-auto-columns: 46px; }

  .sheet-product .product-body {
    min-height: 0;
    padding: 10px 28px 16px;
  }

  /* Leave room for the close button in the top right corner. */
  .sheet-product .product-meta { margin-bottom: 6px; padding-right: 46px; }
  .sheet-product .product-body h2 { margin: 0 0 6px; font-size: 24px; line-height: 1.12; padding-right: 46px; }
  .sheet-product .product-rating { margin-bottom: 6px; }

  .sheet-product .product-description {
    margin: 0 0 8px;
    display: block;
    column-count: 2;
    column-gap: 20px;
    font-size: 12px;
    line-height: 1.38;
  }

  .sheet-product .product-description .desc-row {
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 8px;
    padding: 3px 0;
    break-inside: avoid;
  }

  .sheet-product .product-description .desc-label { font-size: 11px; }

  .sheet-product .product-facts { margin: 8px 0 0; padding: 8px 0; }
  .sheet-product .product-facts .fact b { font-size: 12.5px; }
  .sheet-product .product-facts .fact small { font-size: 10px; }

  .sheet-product .variant-head { margin: 10px 0 6px; }
  .sheet-product .variant-head h3 { font-size: 13px; }
  .sheet-product .variant-head span { font-size: 10.5px; }

  /* One row, however many flavours the product has: the cards share the width
     instead of wrapping onto a second row that would need scrolling. */
  .sheet-product .variant-grid {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: minmax(0, 1fr);
    gap: 8px;
    margin-top: 0;
  }

  .sheet-product .variant-card { gap: 2px; padding: 6px; border-radius: 11px; }
  .sheet-product .variant-card > img { height: 74px; aspect-ratio: auto; }
  .sheet-product .variant-card span { font-size: 11.5px; }
  .sheet-product .variant-card small { font-size: 10.5px; }

  .sheet-product .price-tiers {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 20px;
    margin: 8px 0 10px;
    padding: 8px 10px;
  }

  .sheet-product .tier-title { grid-column: 1 / -1; }
  /* Label, price and gram price share one line, so six steps stay short. */
  .sheet-product .tier-row {
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 0 10px;
    padding: 3px 0;
  }

  .sheet-product .tier-row small { grid-column: auto; }

  /* Price and button sit on the bottom edge, so spare height stays between the
     volume prices and the buy row instead of under the button. */
  .sheet-product .product-buy { margin-top: auto; }
  .sheet-product .product-buy .product-price b { font-size: 27px; }
  .sheet-product .product-buy .cta { height: 46px; }
  .sheet-product .product-note { display: none; }
}

/* Short window (a laptop with browser bars): the facts block steps aside and
   the rest tightens up, so the sheet still fits on one screen. Long windows
   above keep the extra facts. */
@media (min-width: 900px) and (max-height: 820px) {
  .sheet-product .product-facts { display: none; }

  .sheet-product .product-body { padding: 8px 26px 8px; }
  .sheet-product .product-body h2 { font-size: 22px; margin-bottom: 4px; }
  .sheet-product .product-meta { margin-bottom: 4px; }

  .sheet-product .product-description { font-size: 11.5px; line-height: 1.32; }
  .sheet-product .product-description .desc-row { padding: 1px 0; }
  .sheet-product .product-description .desc-label { font-size: 10.5px; }

  .sheet-product .variant-head { margin: 8px 0 4px; }
  .sheet-product .variant-card > img { height: 64px; }
  .sheet-product .variant-card span { font-size: 11px; }

  .sheet-product .price-tiers { margin: 6px 0 8px; padding: 6px 8px; }
  .sheet-product .tier-row { padding: 2px 0; }
  .sheet-product .tier-row span { font-size: 11px; }
  .sheet-product .tier-row b { font-size: 11.5px; }
  .sheet-product .tier-row small { font-size: 10px; }

  .sheet-product .product-buy { gap: 10px; }
  .sheet-product .product-buy .product-price b { font-size: 24px; }
  .sheet-product .product-buy .cta { height: 44px; }
  .sheet-product .product-gallery { padding: 10px; }
}

/* Narrow desktop window: the fact rows need less label room, so the values get
   the space and stop wrapping into extra lines. */
@media (min-width: 900px) and (max-width: 1080px) {
  .sheet-product .product-description { font-size: 11px; line-height: 1.3; }
  .sheet-product .product-description .desc-row {
    grid-template-columns: 82px minmax(0, 1fr);
    gap: 6px;
  }
  .sheet-product .product-body { padding: 6px 20px 6px; }
  .sheet-product .product-buy .cta { height: 42px; }
  .sheet-product .variant-card > img { height: 54px; }
  .sheet-product .price-tiers { margin: 4px 0 6px; padding: 5px 8px; }
  .sheet-product .tier-row { padding: 1px 0; }
}

/* --- sold out ----------------------------------------------------------- */
/* Out of stock has to be unmistakable: a red badge, a red exclamation mark and
   a red-tinged button instead of the muted grey one. */
.card-stock.is-out {
  border-color: rgba(242, 85, 90, 0.8);
  background: rgba(64, 12, 14, 0.92);
  color: #ffb4b7;
  font-weight: 800;
}

/* The warning already carries its own mark; a glowing dot would read as stock. */
.card-stock.is-out::before {
  display: none;
}

.gallery-badge.is-out {
  border-color: rgba(242, 85, 90, 0.85);
  background: rgba(64, 12, 14, 0.94);
  color: #ffb4b7;
}

.cta.cta--out,
.cta.cta--out:disabled {
  opacity: 1;
  border: 1px solid rgba(242, 85, 90, 0.65);
  background: rgba(242, 85, 90, 0.16);
  color: #ffc9cb;
  box-shadow: none;
}

.variant-card.is-out {
  border-color: rgba(242, 85, 90, 0.45);
  background: rgba(60, 12, 14, 0.55);
}

.variant-card.is-out img { opacity: 0.42; }
.variant-card small.is-out { color: #ff9297; font-weight: 800; }
