:root {
  --red: #e31d2b;
  --red-dark: #b90f1d;
  --red-soft: #fff0f2;
  --ink: #171719;
  --muted: #737376;
  --line: #e8e8ea;
  --soft: #f5f5f6;
  --paper: #ffffff;
  --green: #137a48;
  --shadow: 0 18px 54px rgba(26, 26, 30, .16);
  --tg-bg: var(--tg-theme-bg-color, #ffffff);
  --tg-text: var(--tg-theme-text-color, #171719);
}

* { box-sizing: border-box; }
html { background: #ececee; scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: #ececee;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input, textarea, select { font: inherit; }
button { color: inherit; }
button, [role="button"] { -webkit-tap-highlight-color: transparent; }
button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible, [role="button"]:focus-visible {
  outline: 3px solid rgba(227, 29, 43, .25);
  outline-offset: 2px;
}
.hidden { display: none !important; }
.app-shell {
  position: relative;
  z-index: 1;
  width: min(100%, 460px);
  min-height: 100vh;
  margin: 0 auto;
  padding: env(safe-area-inset-top) 0 calc(104px + env(safe-area-inset-bottom));
  overflow: hidden;
  background: var(--tg-bg);
  box-shadow: var(--shadow);
}
.topbar {
  position: sticky;
  z-index: 18;
  top: 0;
  display: grid;
  grid-template-columns: 1fr auto auto;
  align-items: center;
  gap: 10px;
  min-height: 68px;
  padding: 12px 18px 8px;
  border-bottom: 1px solid rgba(232,232,234,.7);
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(18px);
}
.brand { display: flex; align-items: center; gap: 9px; width: fit-content; padding: 0; border: 0; background: none; cursor: pointer; text-align: left; }
.brand-mark { display: grid; width: 36px; height: 36px; place-items: center; border-radius: 11px 11px 11px 4px; color: #fff; background: var(--red); box-shadow: 0 6px 16px rgba(227,29,43,.28); font-size: 1.25rem; font-weight: 950; font-style: italic; }
.brand-copy { display: grid; line-height: .95; }
.brand-copy strong { color: var(--red); font-size: 1.2rem; font-weight: 900; letter-spacing: -.04em; }
.brand-copy small { margin-top: 4px; color: #777; font-size: .75rem; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; }
.language-switch { height: 34px; padding: 0 10px; border: 1px solid var(--line); border-radius: 10px; background: #fff; font-size: .75rem; font-weight: 800; cursor: pointer; }
.avatar { display: grid; width: 36px; height: 36px; place-items: center; border: 0; border-radius: 50%; color: #fff; background: #202024; font-size: .82rem; font-weight: 850; cursor: pointer; }
.delivery-bar { display: flex; align-items: center; width: calc(100% - 36px); min-height: 54px; margin: 10px 18px 14px; padding: 8px 12px; border: 1px solid #f5d9dc; border-radius: 16px; background: linear-gradient(135deg, #fff8f8, #fff); cursor: pointer; text-align: left; box-shadow: 0 5px 16px rgba(110,18,28,.04); }
.delivery-icon { display: grid; width: 32px; height: 32px; flex: 0 0 32px; place-items: center; border-radius: 10px; color: var(--red); background: #fff; font-size: 1.3rem; font-weight: 900; }
.delivery-copy { display: grid; min-width: 0; margin-left: 10px; }
.delivery-copy small { color: var(--muted); font-size: .75rem; font-weight: 700; }
.delivery-copy strong { overflow: hidden; max-width: 290px; margin-top: 2px; font-size: .9rem; text-overflow: ellipsis; white-space: nowrap; }
.chevron { margin-left: auto; color: #999; font-size: 1.6rem; font-weight: 350; }
.view { display: none; padding-bottom: 18px; }
.view.active { display: block; animation: viewIn .22s ease; }
@keyframes viewIn { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }
.search-wrap { display: flex; align-items: center; gap: 9px; height: 46px; margin: 0 18px 14px; padding: 0 13px; border: 1px solid #ededee; border-radius: 14px; background: #fff; box-shadow: 0 5px 18px rgba(20,20,23,.055); }
.search-wrap > span { color: #4f4f53; font-size: 1.5rem; line-height: 1; transform: rotate(-12deg); }
.search-wrap input { width: 100%; height: 100%; min-width: 0; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 1rem; }
.search-wrap input::placeholder { color: #a0a0a4; }
.search-wrap kbd { padding: 4px 6px; border: 0; border-radius: 6px; color: #999; background: #f4f4f5; font-family: inherit; font-size: .65rem; font-weight: 700; white-space: nowrap; }
.promo-wrap { position: relative; }
.promo-track { display: flex; gap: 12px; overflow-x: auto; padding: 0 18px 8px; scroll-behavior: smooth; scroll-snap-type: x mandatory; scrollbar-width: none; }
.promo-track::-webkit-scrollbar { display: none; }
.promo-card { position: relative; flex: 0 0 calc(100% - 18px); height: 242px; overflow: hidden; border-radius: 26px; scroll-snap-align: center; isolation: isolate; box-shadow: 0 16px 35px rgba(33,16,18,.12); }
.promo-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 55% center; z-index: -2; }
.promo-fresh::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(249,248,246,.97) 0%, rgba(249,248,246,.88) 42%, rgba(249,248,246,0) 72%); }
.promo-red { background: linear-gradient(135deg, #e31d2b 0%, #bd0e1b 100%); }
.promo-dark { background: linear-gradient(135deg, #171719, #34343a); }
.promo-copy { position: relative; z-index: 3; display: flex; width: 64%; height: 100%; flex-direction: column; align-items: flex-start; justify-content: center; padding: 25px 0 25px 23px; }
.promo-copy .eyebrow { margin-bottom: 10px; color: var(--red); font-size: .75rem; font-weight: 900; letter-spacing: .12em; }
.promo-copy h1, .promo-copy h2 { margin: 0; font-size: 2.05rem; line-height: .98; letter-spacing: -.055em; }
.promo-copy p { margin: 11px 0 16px; font-size: .9rem; line-height: 1.4; }
.light-copy { color: #fff; }
.light-copy .eyebrow { color: #fff; opacity: .76; }
.light-copy p { color: rgba(255,255,255,.78); }
.promo-button { min-height: 38px; padding: 0 15px; border: 0; border-radius: 11px; color: #fff; background: var(--ink); font-size: .82rem; font-weight: 850; cursor: pointer; box-shadow: 0 7px 15px rgba(0,0,0,.14); }
.promo-button.light { color: var(--red); background: #fff; }
.promo-orbit { position: absolute; border: 1px solid rgba(255,255,255,.22); border-radius: 50%; }
.orbit-one { width: 220px; height: 220px; right: -76px; top: -60px; }
.orbit-two { width: 140px; height: 140px; right: -22px; bottom: -45px; }
.deal-badge { position: absolute; right: 20px; top: 63px; display: grid; width: 96px; height: 96px; place-items: center; transform: rotate(7deg); border: 1px solid rgba(255,255,255,.3); border-radius: 50% 44% 51% 46%; color: #fff; background: rgba(255,255,255,.14); backdrop-filter: blur(5px); }
.deal-badge strong { margin-top: 18px; font-size: 1.5rem; letter-spacing: -.06em; }
.deal-badge span { align-self: start; margin-top: -13px; font-size: .72rem; font-weight: 900; letter-spacing: .14em; }
.deal-product { position: absolute; right: 20px; top: 54px; display: grid; justify-items: center; transform: rotate(6deg); }
.deal-product span { display: grid; width: 92px; height: 92px; place-items: center; border: 1px solid rgba(255,255,255,.14); border-radius: 25px; background: rgba(255,255,255,.1); box-shadow: 0 15px 30px rgba(0,0,0,.22); font-size: 3.4rem; backdrop-filter: blur(6px); }
.deal-product strong { margin-top: -10px; padding: 7px 10px; border-radius: 999px; color: #171719; background: #fff; font-size: .78rem; }
.promo-dots { display: flex; justify-content: center; gap: 5px; height: 30px; padding-top: 4px; }
.promo-dots button { width: 5px; height: 5px; padding: 0; border: 0; border-radius: 8px; background: #cfcfd1; transition: .2s ease; }
.promo-dots button.active { width: 20px; background: var(--red); }
.section-heading { display: flex; align-items: baseline; justify-content: space-between; padding: 0 18px; }
.section-heading h2 { margin: 0; font-size: 1.2rem; letter-spacing: -.035em; }
.section-heading button { padding: 6px 0; border: 0; color: var(--red); background: none; font-size: .82rem; font-weight: 800; cursor: pointer; }
.section-heading > span { color: var(--muted); font-size: .78rem; }
.category-row { display: flex; gap: 10px; overflow-x: auto; padding: 12px 18px 22px; scrollbar-width: none; }
.category-row::-webkit-scrollbar { display: none; }
.category-button { display: grid; flex: 0 0 74px; gap: 7px; justify-items: center; padding: 0; border: 0; background: none; cursor: pointer; }
.category-icon { display: grid; width: 58px; height: 58px; place-items: center; border: 1px solid transparent; border-radius: 18px; background: var(--cat-bg); font-size: 1.65rem; transition: .18s ease; }
.category-button span:last-child { overflow: hidden; width: 74px; font-size: .78rem; font-weight: 720; text-align: center; text-overflow: ellipsis; white-space: nowrap; }
.category-button.active .category-icon { border-color: var(--red); box-shadow: inset 0 0 0 2px #fff, 0 5px 16px rgba(227,29,43,.12); transform: translateY(-2px); }
.products-section { padding-bottom: 10px; }
.catalog-heading { align-items: center; gap: 12px; }
.catalog-actions { display: flex; gap: 7px; }
.section-heading .catalog-actions button { display: inline-flex; min-height: 34px; gap: 5px; align-items: center; padding: 0 10px; border: 1px solid var(--line); border-radius: 11px; color: var(--ink); background: #fff; box-shadow: 0 4px 13px rgba(17,17,20,.04); font-size: .76rem; }
.section-heading .catalog-actions button.active { border-color: #f0b9be; color: var(--red); background: var(--red-soft); }
.catalog-actions em { display: grid; min-width: 18px; height: 18px; place-items: center; padding: 0 4px; border-radius: 999px; color: #fff; background: var(--red); font-size: .66rem; font-style: normal; }
.catalog-summary { display: flex; min-height: 27px; align-items: center; justify-content: space-between; padding: 5px 18px 0; color: var(--muted); font-size: .76rem; }
.catalog-summary button { padding: 2px 0; border: 0; color: var(--red); background: none; font-size: .76rem; font-weight: 800; cursor: pointer; }
.product-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding: 13px 18px 20px; }
.product-card { position: relative; min-width: 0; overflow: hidden; border: 1px solid #ededee; border-radius: 19px; background: #fff; box-shadow: 0 6px 20px rgba(17,17,20,.045); }
.product-card:active { transform: scale(.99); }
.product-visual { position: relative; display: grid; height: 130px; place-items: center; overflow: hidden; background: var(--product-bg); cursor: pointer; }
.product-visual::after { content: ""; position: absolute; width: 78px; height: 18px; bottom: 18px; border-radius: 50%; background: rgba(0,0,0,.08); filter: blur(5px); }
.product-emoji { position: relative; z-index: 1; font-size: 4.3rem; filter: drop-shadow(0 12px 10px rgba(0,0,0,.11)); transform: rotate(-3deg); transition: .2s ease; }
.product-card:hover .product-emoji { transform: translateY(-3px) rotate(0); }
.product-badge { position: absolute; z-index: 2; left: 9px; top: 9px; padding: 5px 7px; border-radius: 7px; color: #fff; background: var(--red); font-size: .58rem; font-weight: 900; letter-spacing: .04em; }
.heart { position: absolute; z-index: 2; right: 8px; top: 8px; display: grid; width: 30px; height: 30px; place-items: center; border: 0; border-radius: 50%; background: rgba(255,255,255,.9); font-size: 1rem; cursor: pointer; }
.heart.active { color: var(--red); }
.product-info { padding: 11px 11px 12px; }
.product-unit { color: var(--muted); font-size: .75rem; font-weight: 650; }
.product-info h3 { min-height: 38px; margin: 4px 0 9px; font-size: .9rem; line-height: 1.32; letter-spacing: -.015em; }
.price-line { display: flex; min-height: 32px; align-items: center; gap: 5px; }
.price-line strong { font-size: 1rem; }
.old-price { color: #6d6d72; font-size: .75rem; text-decoration: line-through; }
.product-card.deal-focus { animation: dealFocus 1.2s ease; }
@keyframes dealFocus { 0%,100% { box-shadow: 0 6px 20px rgba(17,17,20,.045); } 35% { border-color: var(--red); box-shadow: 0 0 0 5px rgba(227,29,43,.13), 0 12px 28px rgba(17,17,20,.1); } }
.add-button { display: grid; width: 31px; height: 31px; margin-left: auto; place-items: center; border: 0; border-radius: 10px; color: #fff; background: var(--red); font-size: 1.25rem; line-height: 1; cursor: pointer; box-shadow: 0 5px 14px rgba(227,29,43,.24); }
.quantity-control { display: flex; margin-left: auto; align-items: center; gap: 7px; }
.quantity-control button { display: grid; width: 28px; height: 28px; place-items: center; border: 1px solid #dedee0; border-radius: 9px; background: #fff; font-size: 1rem; cursor: pointer; }
.quantity-control span { min-width: 12px; font-size: .78rem; font-weight: 850; text-align: center; }
.empty-state { padding: 60px 20px; color: var(--muted); text-align: center; }
.empty-state > span { font-size: 2.6rem; }
.empty-state h3 { margin: 12px 0 5px; color: var(--ink); }
.empty-state p { margin: 0; font-size: .85rem; }
.bottom-nav { position: fixed; z-index: 20; left: 50%; bottom: 0; display: grid; width: min(100%, 460px); grid-template-columns: repeat(4, 1fr); min-height: calc(72px + env(safe-area-inset-bottom)); padding: 8px 12px env(safe-area-inset-bottom); transform: translateX(-50%); border-top: 1px solid var(--line); background: rgba(255,255,255,.94); backdrop-filter: blur(16px); }
.bottom-nav button { display: grid; gap: 2px; place-items: center; border: 0; color: #8b8b8f; background: none; cursor: pointer; }
.bottom-nav button span { font-size: 1.35rem; line-height: 1; }
.bottom-nav button small { font-size: .75rem; font-weight: 750; }
.bottom-nav button.active { color: var(--red); }
.cart-float { position: fixed; z-index: 25; left: 50%; bottom: calc(78px + env(safe-area-inset-bottom)); display: flex; width: min(calc(100% - 36px), 424px); height: 56px; align-items: center; padding: 0 15px; transform: translateX(-50%); border: 0; border-radius: 17px; color: #fff; background: #1d1d20; box-shadow: 0 14px 32px rgba(0,0,0,.25); cursor: pointer; }
.cart-count { display: grid; width: 28px; height: 28px; margin-right: 11px; place-items: center; border-radius: 9px; color: #fff; background: var(--red); font-size: .72rem; font-weight: 900; }
.cart-float strong { font-size: .85rem; }
.cart-float > span:last-child { margin-left: auto; font-size: .88rem; font-weight: 850; }
.page-head { padding: 11px 18px 17px; }
.page-head h1 { margin: 0; font-size: 1.7rem; letter-spacing: -.055em; }
.search-large { margin-bottom: 26px; }
.search-large button { border: 0; color: #999; background: none; font-size: 1.15rem; }
.recent-searches { margin-bottom: 18px; }
.search-tags { display: flex; flex-wrap: wrap; gap: 8px; padding: 10px 18px; }
.search-tags button { padding: 8px 11px; border: 1px solid var(--line); border-radius: 10px; background: #fff; font-size: .75rem; }
.orders-list { display: grid; gap: 12px; padding: 0 18px; }
.order-card { padding: 16px; border: 1px solid var(--line); border-radius: 17px; background: #fff; }
.order-card-head { display: flex; align-items: center; justify-content: space-between; }
.order-card-head strong { font-size: .86rem; }
.order-status { padding: 5px 7px; border-radius: 8px; color: var(--green); background: #eaf7ef; font-size: .62rem; font-weight: 900; }
.order-card p { margin: 11px 0 7px; color: var(--muted); font-size: .77rem; line-height: 1.4; }
.order-card footer { display: flex; justify-content: space-between; font-size: .75rem; font-weight: 800; }
.order-card-actions { display: flex; gap: 8px; margin-top: 13px; padding-top: 12px; border-top: 1px solid var(--line); }
.order-card-actions button { min-height: 36px; flex: 1; border: 1px solid var(--line); border-radius: 10px; background: #fff; font-size: .78rem; font-weight: 800; cursor: pointer; }
.order-card-actions button.primary-small { border-color: var(--red); color: #fff; background: var(--red); }
.orders-empty { padding: 80px 28px; color: var(--muted); text-align: center; }
.orders-empty span { display: grid; width: 64px; height: 64px; margin: 0 auto 16px; place-items: center; border-radius: 20px; color: var(--red); background: #fff1f2; font-size: 1.8rem; }
.orders-empty h3 { margin: 0 0 6px; color: var(--ink); }
.orders-empty p { margin: 0; font-size: .83rem; line-height: 1.5; }
.account-card { display: flex; gap: 13px; margin: 0 18px 20px; padding: 17px; align-items: center; border-radius: 19px; color: #fff; background: linear-gradient(135deg, #202024, #3d3d43); }
.account-avatar { display: grid; width: 48px; height: 48px; place-items: center; border-radius: 50%; color: var(--red); background: #fff; font-weight: 900; }
.account-card > div:last-child { display: grid; }
.account-card strong { font-size: .96rem; }
.account-card span { margin-top: 3px; color: #bdbdc1; font-size: .7rem; }
.settings-list { margin: 0 18px; overflow: hidden; border: 1px solid var(--line); border-radius: 18px; }
.settings-list button { display: grid; width: 100%; min-height: 58px; grid-template-columns: 34px 1fr auto auto; align-items: center; padding: 0 13px; border: 0; border-bottom: 1px solid var(--line); background: #fff; cursor: pointer; text-align: left; }
.settings-list button:last-child { border-bottom: 0; }
.settings-list button > span { display: grid; width: 29px; height: 29px; place-items: center; border-radius: 9px; color: var(--red); background: #fff0f1; }
.settings-list button strong { font-size: .84rem; }
.settings-list button small { color: var(--muted); font-size: .7rem; }
.settings-list button em { margin-left: 5px; color: #aaa; font-size: 1.25rem; font-style: normal; }
.scrim { position: fixed; z-index: 40; inset: 0; visibility: hidden; opacity: 0; background: rgba(10,10,12,.48); backdrop-filter: blur(2px); transition: .23s ease; }
.scrim.active { visibility: visible; opacity: 1; }
.sheet { position: fixed; z-index: 50; left: 50%; bottom: 0; width: min(100%, 460px); max-height: 92vh; overflow-y: auto; padding: 10px 18px calc(22px + env(safe-area-inset-bottom)); transform: translate(-50%, 105%); border-radius: 25px 25px 0 0; background: #fff; box-shadow: 0 -18px 45px rgba(0,0,0,.18); transition: transform .28s cubic-bezier(.2,.76,.2,1); }
.sheet.open { transform: translate(-50%, 0); }
.tall-sheet { height: min(92vh, 840px); }
.sheet-handle { width: 40px; height: 4px; margin: 0 auto 14px; border-radius: 10px; background: #d5d5d7; }
.sheet-close { position: absolute; right: 16px; top: 17px; display: grid; width: 32px; height: 32px; place-items: center; border: 0; border-radius: 50%; background: #f2f2f3; font-size: 1.35rem; cursor: pointer; }
.sheet-title { display: flex; min-height: 38px; align-items: center; justify-content: space-between; margin-bottom: 11px; padding-right: 39px; }
.sheet-title h2 { margin: 0; font-size: 1.45rem; letter-spacing: -.045em; }
.sheet-title button { border: 0; color: var(--red); background: none; font-size: .75rem; font-weight: 800; }
.product-sheet-visual { display: grid; height: 260px; margin-bottom: 18px; place-items: center; border-radius: 22px; background: var(--product-bg); font-size: 8rem; }
.product-sheet-copy .eyebrow { color: var(--red); font-size: .65rem; font-weight: 900; letter-spacing: .08em; }
.product-sheet-copy h2 { margin: 6px 0 7px; font-size: 1.5rem; letter-spacing: -.04em; }
.product-sheet-copy p { margin: 0 0 20px; color: var(--muted); font-size: .82rem; line-height: 1.5; }
.product-sheet-footer { display: flex; align-items: center; }
.product-sheet-footer .price { display: grid; }
.product-sheet-footer .price small { color: var(--muted); font-size: .68rem; }
.product-sheet-footer .price strong { font-size: 1.45rem; }
.product-sheet-footer .primary-button { width: 54%; margin: 0 0 0 auto; }
.product-availability { display: flex; gap: 7px; align-items: center; margin: 0 0 18px; color: var(--green); font-size: .78rem; font-weight: 800; }
.product-availability::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px rgba(19,122,72,.1); }
.primary-button { width: 100%; min-height: 52px; border: 0; border-radius: 15px; color: #fff; background: var(--red); font-size: .88rem; font-weight: 850; cursor: pointer; box-shadow: 0 10px 24px rgba(227,29,43,.22); }
.secondary-button { width: 100%; min-height: 52px; border: 1px solid #d9d9dc; border-radius: 15px; color: var(--ink); background: #fff; font-size: .88rem; font-weight: 850; cursor: pointer; }
.primary-button:disabled { opacity: .45; box-shadow: none; cursor: default; }
.cart-lines { display: grid; gap: 2px; }
.cart-line { display: grid; grid-template-columns: 56px 1fr auto; gap: 10px; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--line); }
.cart-line-visual { display: grid; width: 56px; height: 56px; place-items: center; border-radius: 14px; background: var(--product-bg); font-size: 2.2rem; }
.cart-line-copy { display: grid; }
.cart-line-copy strong { font-size: .78rem; line-height: 1.25; }
.cart-line-copy small { margin-top: 4px; color: var(--muted); font-size: .68rem; }
.suggestion-block { padding: 18px 0 15px; }
.suggestion-block h3 { margin: 0 0 10px; font-size: .88rem; }
.mini-products { display: flex; gap: 9px; overflow-x: auto; scrollbar-width: none; }
.mini-product { display: grid; min-width: 145px; grid-template-columns: 42px 1fr auto; gap: 7px; align-items: center; padding: 8px; border: 1px solid var(--line); border-radius: 13px; background: #fff; }
.mini-product > span { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 11px; background: var(--product-bg); font-size: 1.7rem; }
.mini-product div { display: grid; }
.mini-product strong { overflow: hidden; max-width: 56px; font-size: .66rem; text-overflow: ellipsis; white-space: nowrap; }
.mini-product small { margin-top: 3px; font-size: .67rem; font-weight: 800; }
.mini-product button { display: grid; width: 25px; height: 25px; place-items: center; border: 0; border-radius: 8px; color: #fff; background: var(--red); }
.totals { display: grid; gap: 8px; padding: 12px 0 18px; }
.totals > div { display: flex; justify-content: space-between; color: var(--muted); font-size: .78rem; }
.totals strong { color: var(--ink); }
.totals .total-row { margin-top: 3px; padding-top: 11px; border-top: 1px dashed #d9d9db; color: var(--ink); font-size: .95rem; font-weight: 850; }
.fulfilment-selector { display:grid; grid-template-columns:1fr 1fr; gap:9px; margin:2px 0 16px; }
.fulfilment-option { position:relative; cursor:pointer; }
.fulfilment-option > input { position:absolute; width:1px; height:1px; opacity:0; pointer-events:none; }
.fulfilment-option-body { display:grid; min-height:74px; grid-template-columns:32px 1fr; gap:9px; align-items:center; padding:10px; border:1px solid var(--line); border-radius:14px; background:#fff; transition:border-color .16s ease,background .16s ease,box-shadow .16s ease; }
.fulfilment-option-body > .ui-icon { width:26px; height:26px; padding:5px; border-radius:9px; color:var(--muted); background:var(--soft); }
.fulfilment-option-body > span { display:grid; min-width:0; gap:3px; }
.fulfilment-option strong { font-size:.82rem; line-height:1.2; }
.fulfilment-option small { color:var(--muted); font-size:.68rem; line-height:1.3; }
.fulfilment-option > input:checked + .fulfilment-option-body { border-color:var(--red); background:var(--red-soft); box-shadow:inset 0 0 0 1px var(--red); }
.fulfilment-option > input:checked + .fulfilment-option-body > .ui-icon { color:#fff; background:var(--red); }
.fulfilment-option > input:focus-visible + .fulfilment-option-body { outline:3px solid rgba(227,29,43,.25); outline-offset:2px; }
.fulfilment-panel { animation:viewIn .18s ease; }
.door-order-panel { margin-bottom:4px; animation:viewIn .18s ease; }
.door-order-intro { display:grid; grid-template-columns:44px 1fr; gap:11px; align-items:start; margin-bottom:17px; padding:13px; border:1px solid #f1d9dc; border-radius:15px; background:#fff8f8; }
.door-building-icon { display:grid; width:42px; height:42px; place-items:center; border-radius:12px; color:#fff; background:var(--red); }
.door-building-icon .ui-icon { width:22px; height:22px; }
.door-order-intro h3 { margin:1px 0 4px; font-size:.95rem; letter-spacing:-.02em; }
.door-order-intro p { margin:0; color:var(--muted); font-size:.75rem; line-height:1.4; }
.number-picker { min-width:0; margin:0 0 16px; padding:0; border:0; }
.number-picker legend { margin-bottom:9px; padding:0; font-size:.84rem; font-weight:850; }
.number-choice-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:8px; }
.number-choice-grid label { position:relative; cursor:pointer; }
.number-choice-grid input { position:absolute; width:1px; height:1px; opacity:0; pointer-events:none; }
.number-choice-grid span { display:grid; min-height:48px; place-items:center; border:1px solid var(--line); border-radius:12px; background:#fff; font-size:.93rem; font-weight:850; transition:border-color .16s ease,background .16s ease,box-shadow .16s ease; }
.number-choice-grid input:checked + span { border-color:var(--red); color:var(--red); background:var(--red-soft); box-shadow:inset 0 0 0 1px var(--red); }
.number-choice-grid input:focus-visible + span { outline:3px solid rgba(227,29,43,.25); outline-offset:2px; }
.door-selection-summary { min-height:21px; margin:-2px 0 12px; color:var(--red); font-size:.78rem; font-weight:800; }
.door-service-card { display:grid; grid-template-columns:30px 1fr; gap:9px; align-items:center; margin-bottom:13px; padding:11px 12px; border:1px solid #cfe9da; border-radius:13px; background:#f4fbf7; }
.door-service-card > span { display:grid; width:27px; height:27px; place-items:center; border-radius:9px; color:#fff; background:var(--green); font-size:.75rem; font-weight:900; }
.door-service-card > div { display:grid; gap:2px; }
.door-service-card strong { font-size:.8rem; }
.door-service-card small { color:var(--muted); font-size:.71rem; line-height:1.35; }
.location-action { display: grid; width: 100%; grid-template-columns: 40px 1fr auto; gap: 10px; align-items: center; margin-bottom: 14px; padding: 12px; border: 1px solid #ffd9dd; border-radius: 15px; background: #fff7f7; text-align: left; }
.location-action > span { display: grid; width: 38px; height: 38px; place-items: center; border-radius: 12px; color: #fff; background: var(--red); }
.location-action div { display: grid; }
.location-action strong { font-size: .9rem; }
.location-action small { margin-top: 3px; color: var(--muted); font-size: .75rem; line-height: 1.35; }
.location-action em { color: #aaa; font-size: 1.2rem; font-style: normal; }
.map-search-shell { position: relative; z-index: 1002; margin-bottom: 10px; }
.map-search { display: grid; min-height: 48px; grid-template-columns: 28px 1fr auto; align-items: center; padding: 0 6px 0 11px; border: 1px solid #dedee0; border-radius: 14px; background: #fff; box-shadow: 0 6px 20px rgba(23,23,25,.07); }
.map-search > span { color: #5d5d62; font-size: 1.35rem; transform: rotate(-12deg); }
.map-search input { width: 100%; min-width: 0; height: 44px; border: 0; outline: 0; background: transparent; font-size: .9rem; }
.map-search button { min-height: 36px; padding: 0 12px; border: 0; border-radius: 10px; color: #fff; background: var(--ink); font-size: .78rem; font-weight: 850; cursor: pointer; }
.map-search button:disabled { opacity: .55; }
.map-search-results { position: absolute; z-index: 1200; top: 54px; left: 0; right: 0; max-height: 210px; overflow-y: auto; padding: 5px; border: 1px solid var(--line); border-radius: 14px; background: #fff; box-shadow: 0 16px 34px rgba(23,23,25,.18); }
.map-search-results button { display: grid; width: 100%; gap: 3px; padding: 10px; border: 0; border-bottom: 1px solid #eeeeef; background: #fff; cursor: pointer; text-align: left; }
.map-search-results button:last-child { border-bottom: 0; }
.map-search-results strong { font-size: .84rem; line-height: 1.35; }
.map-search-results small { color: var(--muted); font-size: .75rem; line-height: 1.35; }
.map-picker { position: relative; z-index: 1; height: 250px; overflow: hidden; border: 1px solid #dedee0; border-radius: 18px; background: #ecebe7; }
.map-picker .leaflet-control-zoom { overflow: hidden; border: 0; border-radius: 11px; box-shadow: 0 5px 16px rgba(0,0,0,.16); }
.map-picker .leaflet-control-zoom a { color: var(--ink); }
.map-picker .leaflet-control-attribution { padding: 3px 5px; background: rgba(255,255,255,.88); font-size: 10px; }
.map-error { display: grid; height: 100%; place-content: center; gap: 6px; padding: 28px; color: var(--ink); background: #f3f3f4; text-align: center; }
.map-error strong { font-size: .95rem; }
.map-error span { color: var(--muted); font-size: .78rem; line-height: 1.4; }
.delivery-pin { position: relative; width: 38px; height: 38px; transform: rotate(-45deg); border: 4px solid #fff; border-radius: 50% 50% 50% 8px; background: var(--red); box-shadow: 0 8px 18px rgba(0,0,0,.28); }
.delivery-pin::after { content: ""; position: absolute; width: 9px; height: 9px; left: 50%; top: 50%; transform: translate(-50%,-50%); border-radius: 50%; background: #fff; }
.store-map-dot { width: 15px; height: 15px; border: 3px solid #fff; border-radius: 50%; background: var(--ink); box-shadow: 0 3px 9px rgba(0,0,0,.22); }
.map-readout { display: grid; grid-template-columns: 24px 1fr; gap: 9px; align-items: start; padding: 11px 2px 3px; }
.pin-readout-icon { display: grid; width: 24px; height: 24px; place-items: center; color: var(--red); font-size: .66rem; }
.map-readout div { display: grid; gap: 3px; }
.map-readout strong { font-size: .84rem; line-height: 1.35; }
.map-readout small { color: var(--muted); font-size: .75rem; }
.map-credit { margin: 2px 0 13px 35px; color: #87878b; font-size: .72rem; line-height: 1.35; }
.field-label { display: block; margin: 12px 0 6px; font-size: .8rem; font-weight: 850; }
.sheet select, .sheet textarea, .sheet input[type="tel"], #phoneInput { width: 100%; min-height: 48px; padding: 11px 12px; border: 1px solid #dedee0; border-radius: 12px; outline: none; background: #fff; font-size: .9rem; }
.sheet textarea { resize: none; }
.delivery-result { display: grid; grid-template-columns: 11px 1fr auto; gap: 9px; align-items: center; margin: 15px 0; padding: 12px; border-radius: 14px; background: #f5f5f6; }
.store-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px rgba(19,122,72,.11); }
.delivery-result > div { display: grid; }
.delivery-result > div:last-child { text-align: right; }
.delivery-result small { color: var(--muted); font-size: .72rem; }
.delivery-result strong { margin-top: 2px; font-size: .8rem; }
.estimate-note { margin: -8px 2px 15px; color: var(--muted); font-size: .75rem; line-height: 1.4; }
.checkout-section { display: grid; grid-template-columns: 30px 1fr; gap: 10px; align-items: start; margin: 5px 0 16px; padding: 13px; border: 1px solid var(--line); border-radius: 14px; }
.checkout-step { display: grid; width: 28px; height: 28px; place-items: center; border-radius: 9px; color: #fff; background: var(--red); font-size: .7rem; font-weight: 900; }
.checkout-section div { display: grid; grid-template-columns: 1fr auto; }
.checkout-section small { grid-column: 1; color: var(--muted); font-size: .61rem; }
.checkout-section strong { grid-column: 1; overflow: hidden; margin-top: 3px; font-size: .75rem; text-overflow: ellipsis; white-space: nowrap; }
.checkout-section button { grid-column: 2; grid-row: 1 / 3; border: 0; color: var(--red); background: none; font-size: .68rem; font-weight: 850; }
.checkout-block { margin-bottom: 15px; }
.checkout-block h3, .note-block label { display: block; margin: 0 0 8px; font-size: .75rem; font-weight: 850; }
.choice-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.choice { display: grid; min-height: 60px; padding: 10px; border: 1px solid var(--line); border-radius: 13px; background: #fff; text-align: left; }
.choice.active { border-color: var(--red); background: #fff6f7; box-shadow: inset 0 0 0 1px var(--red); }
.choice strong { font-size: .76rem; }
.choice small { margin-top: 4px; color: var(--muted); font-size: .64rem; }
#timeSelect { margin-top: 8px; }
.payment-choice { position: relative; display: grid; min-height: 52px; grid-template-columns: 36px 1fr auto; gap: 9px; align-items: center; padding: 8px 11px; border: 1px solid var(--line); border-radius: 12px; }
.payment-choice + .payment-choice { margin-top: 7px; }
.payment-choice input { position: absolute; opacity: 0; }
.payment-choice.active { border-color: var(--red); background: #fff7f7; }
.pay-icon { display: grid; width: 32px; height: 32px; place-items: center; border-radius: 9px; color: #fff; background: #28282c; font-size: .7rem; font-weight: 900; }
.pay-icon.aba { background: #005d70; font-size: .55rem; }
.payment-choice strong { font-size: .75rem; }
.payment-choice em { visibility: hidden; color: var(--red); font-size: .55rem; font-style: normal; }
.payment-choice.active em { visibility: visible; }
.filter-sheet { min-height: 470px; }
.filter-block { padding: 8px 0 18px; border-bottom: 1px solid var(--line); }
.filter-block h3 { margin: 0 0 11px; font-size: .84rem; }
.sort-options { display: grid; gap: 8px; }
.sort-options label { position: relative; display: flex; min-height: 46px; align-items: center; padding: 0 13px; border: 1px solid var(--line); border-radius: 12px; font-size: .84rem; font-weight: 750; cursor: pointer; }
.sort-options label:has(input:checked) { border-color: var(--red); color: var(--red); background: var(--red-soft); box-shadow: inset 0 0 0 1px var(--red); }
.sort-options input { position: absolute; opacity: 0; }
.switch-row { display: grid; grid-template-columns: 1fr 46px; gap: 12px; align-items: center; cursor: pointer; }
.switch-row > span { display: grid; gap: 3px; }
.switch-row strong { font-size: .84rem; }
.switch-row small { color: var(--muted); font-size: .75rem; }
.switch-row input { position: absolute; opacity: 0; }
.switch-row i { position: relative; width: 46px; height: 27px; border-radius: 999px; background: #d7d7da; transition: .2s ease; }
.switch-row i::after { content: ""; position: absolute; width: 21px; height: 21px; left: 3px; top: 3px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0,0,0,.18); transition: .2s ease; }
.switch-row input:checked + i { background: var(--red); }
.switch-row input:checked + i::after { transform: translateX(19px); }
.filter-actions { display: grid; grid-template-columns: 1fr 1.5fr; gap: 9px; margin-top: 20px; }
.preference-options { display: grid; gap: 7px; }
.preference-choice { position: relative; display: grid; min-height: 44px; grid-template-columns: 1fr auto; align-items: center; padding: 0 12px; border: 1px solid var(--line); border-radius: 11px; cursor: pointer; }
.preference-choice input { position: absolute; opacity: 0; }
.preference-choice span { font-size: .78rem; font-weight: 750; }
.preference-choice em { visibility: hidden; color: var(--red); font-size: .58rem; font-style: normal; }
.preference-choice.active { border-color: var(--red); background: #fff7f7; }
.preference-choice.active em { visibility: visible; }
.checkout-total { display: flex; margin: 18px 0 12px; align-items: center; justify-content: space-between; font-size: .9rem; font-weight: 850; }
.checkout-total strong { font-size: 1.35rem; }
.success-sheet { min-height: 470px; padding: 44px 25px calc(30px + env(safe-area-inset-bottom)); text-align: center; }
.success-check { display: grid; width: 76px; height: 76px; margin: 0 auto 20px; place-items: center; border-radius: 50%; color: #fff; background: var(--green); box-shadow: 0 14px 28px rgba(19,122,72,.22); font-size: 2.1rem; }
.success-kicker { color: var(--green); font-size: .63rem; font-weight: 900; letter-spacing: .15em; }
.success-sheet h2 { margin: 10px auto; max-width: 290px; font-size: 1.7rem; line-height: 1.08; letter-spacing: -.05em; }
.success-sheet p { max-width: 310px; margin: 0 auto 20px; color: var(--muted); font-size: .8rem; line-height: 1.5; }
.order-code { display: grid; margin: 0 auto 22px; padding: 12px; border: 1px dashed #d5d5d7; border-radius: 13px; background: #fafafa; }
.order-code small { color: var(--muted); font-size: .62rem; }
.order-code strong { margin-top: 3px; font-size: 1.1rem; letter-spacing: .08em; }
.text-button { margin-top: 13px; border: 0; color: var(--red); background: none; font-size: .8rem; font-weight: 850; }
.toast { position: fixed; z-index: 70; left: 50%; top: 18px; visibility: hidden; max-width: min(calc(100% - 30px), 400px); padding: 11px 15px; transform: translate(-50%,-15px); border-radius: 12px; color: #fff; background: #202024; box-shadow: 0 12px 30px rgba(0,0,0,.2); opacity: 0; font-size: .75rem; font-weight: 750; text-align: center; transition: .2s ease; }
.toast.show { visibility: visible; transform: translate(-50%,0); opacity: 1; }

@media (max-width: 740px) {
  html, body { background: #fff; }
  .app-shell { width: 100%; box-shadow: none; }
}
@media (max-width: 365px) {
  .product-grid { gap: 9px; padding-inline: 13px; }
  .delivery-bar { margin-inline: 13px; width: calc(100% - 26px); }
  .search-wrap, .section-heading { margin-inline: 13px; }
  .section-heading { padding-inline: 0; }
  .promo-track, .category-row { padding-left: 13px; }
  .promo-copy h1, .promo-copy h2 { font-size: 1.7rem; }
  .catalog-actions button span:nth-child(2) { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

/* Version 4 refinement */
:root {
  --red:#dc1828; --red-dark:#b30e1b; --red-soft:#fff1f2; --ink:#171719; --muted:#68686d; --line:#e5e5e8; --green:#087443;
  --safe-top:max(env(safe-area-inset-top),var(--tg-content-safe-area-inset-top,0px));
  --safe-bottom:max(env(safe-area-inset-bottom),var(--tg-content-safe-area-inset-bottom,0px));
  --safe-left:max(env(safe-area-inset-left),var(--tg-content-safe-area-inset-left,0px));
  --safe-right:max(env(safe-area-inset-right),var(--tg-content-safe-area-inset-right,0px));
}
body { min-height:var(--tg-viewport-height,100vh); line-height:1.35; }
button,input,textarea,select { font-size:16px; }
button { touch-action:manipulation; }
.khmer { font-family:"Noto Sans Khmer","Khmer OS System",-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; }
.skip-link { position:fixed; z-index:100; left:12px; top:8px; padding:10px 14px; transform:translateY(-150%); border-radius:10px; color:#fff; background:var(--ink); font-weight:800; text-decoration:none; }
.skip-link:focus { transform:translateY(0); }
.network-banner { position:fixed; z-index:90; left:50%; top:max(8px,var(--safe-top)); display:grid; width:min(calc(100% - 24px),520px); gap:3px; padding:11px 14px; transform:translateX(-50%); border:1px solid #f2c9a0; border-radius:13px; color:#603600; background:#fff8eb; box-shadow:0 10px 30px rgba(48,30,9,.16); }
.network-banner strong { font-size:.84rem; } .network-banner span { font-size:.74rem; }
.app-shell { padding-top:var(--safe-top); padding-bottom:calc(104px + var(--safe-bottom)); }
.topbar { min-height:70px; padding-inline:max(18px,var(--safe-left)) max(18px,var(--safe-right)); }
.language-switch { min-width:48px; height:40px; font-size:.8rem; }
.avatar { width:40px; height:40px; background-position:center; background-size:cover; }
.delivery-bar { min-height:60px; margin-bottom:16px; }
.delivery-copy { flex:1; }
.delivery-copy strong { max-width:min(42vw,390px); font-size:.92rem; }
.delivery-meta { display:grid; flex:none; gap:1px; margin-left:auto; padding-left:8px; text-align:right; }
.delivery-meta strong { color:var(--red); font-size:.71rem; white-space:nowrap; }
.delivery-meta small { color:var(--muted); font-size:.62rem; white-space:nowrap; }
.delivery-bar .chevron { margin-left:7px; }
.search-wrap { position:relative; height:50px; border-radius:15px; }
.search-clear { display:grid; width:32px; height:32px; flex:0 0 32px; place-items:center; padding:0; border:0; border-radius:50%; color:#65656a; background:#f1f1f2; cursor:pointer; }
.promo-card { height:246px; }
.carousel-arrow { position:absolute; z-index:6; top:101px; display:grid; width:40px; height:40px; place-items:center; padding:0; border:1px solid rgba(255,255,255,.7); border-radius:50%; color:var(--ink); background:rgba(255,255,255,.92); box-shadow:0 8px 22px rgba(0,0,0,.16); font-size:1.65rem; cursor:pointer; backdrop-filter:blur(8px); }
.carousel-prev { left:25px; } .carousel-next { right:25px; }
.promo-dots { height:36px; gap:0; padding:0; }
.promo-dots button,.promo-dots button.active { position:relative; width:28px; min-width:28px; height:28px; min-height:28px; background:transparent; cursor:pointer; }
.promo-dots button::before { content:""; position:absolute; left:50%; top:50%; width:7px; height:7px; transform:translate(-50%,-50%); border-radius:8px; background:#cfcfd1; transition:.2s ease; }
.promo-dots button.active::before { width:21px; background:var(--red); }
.quick-section { padding:2px 0 22px; }
.quick-row { display:flex; gap:9px; overflow-x:auto; padding:0 18px 3px; scrollbar-width:none; }
.quick-row::-webkit-scrollbar { display:none; }
.quick-row button { display:inline-flex; min-height:44px; flex:none; gap:8px; align-items:center; padding:0 13px; border:1px solid var(--line); border-radius:14px; background:#fff; font-size:.78rem; box-shadow:0 3px 12px rgba(20,20,24,.04); cursor:pointer; }
.quick-row button span { display:grid; width:25px; height:25px; place-items:center; border-radius:8px; color:var(--red); background:var(--red-soft); font-weight:900; }
.quick-row button strong { white-space:nowrap; }
.quick-row button.active { border-color:var(--red); color:var(--red); background:var(--red-soft); box-shadow:inset 0 0 0 1px var(--red); }
.quick-row button.active span { color:#fff; background:var(--red); }
.category-button { grid-template-rows:58px auto 14px; }
.category-button small { color:#929297; font-size:.64rem; font-weight:700; }
.section-heading h2 { font-size:1.28rem; }
.section-heading button { min-height:38px; }
.section-heading .catalog-actions button { min-height:40px; }
.catalog-summary { min-height:34px; font-size:.79rem; }
.buy-again-section { margin-bottom:25px; }
.buy-again-card { display:grid; min-height:90px; grid-template-columns:auto 1fr auto; gap:12px; align-items:center; margin:10px 18px 0; padding:14px; border:1px solid #f0dadd; border-radius:18px; background:linear-gradient(135deg,#fff8f8,#fff); box-shadow:0 8px 24px rgba(80,15,22,.06); }
.buy-again-products { display:grid; width:64px; grid-template-columns:repeat(2,1fr); gap:3px; }
.buy-again-products span { display:grid; width:30px; height:30px; place-items:center; border-radius:9px; background:#f3f3f4; }
.buy-again-copy { display:grid; min-width:0; gap:4px; }
.buy-again-copy strong { font-size:.86rem; } .buy-again-copy small { overflow:hidden; color:var(--muted); font-size:.7rem; text-overflow:ellipsis; white-space:nowrap; }
.buy-again-card>button { min-height:40px; padding:0 13px; border:0; border-radius:11px; color:#fff; background:var(--red); font-size:.73rem; font-weight:850; cursor:pointer; }
.product-grid { gap:13px; }
.product-card { border-radius:20px; transition:.18s ease; }
.product-card:hover { border-color:#dcdce0; box-shadow:0 11px 28px rgba(17,17,20,.08); }
.product-visual { height:144px; cursor:default; }
.product-open { position:absolute; z-index:1; inset:0; display:grid; width:100%; height:100%; place-items:center; padding:0; border:0; background:transparent; cursor:pointer; }
.product-meta { display:flex; min-height:17px; align-items:center; justify-content:space-between; gap:5px; }
.stock { color:var(--green); font-size:.62rem; font-weight:800; white-space:nowrap; }
.stock.low { color:#925500; }
.product-info { padding:11px 12px 13px; }
.product-info h3 { min-height:40px; margin-bottom:4px; font-size:.91rem; }
.card-saving { display:block; min-height:17px; color:var(--green); font-size:.66rem; font-weight:800; }
.card-saving.spacer { visibility:hidden; }
.price-line { min-height:38px; margin-top:3px; }
.add-button { width:36px; height:36px; }
.add-button.disabled { color:#8d8d92; background:#ececef; box-shadow:none; }
.quantity-control button { width:34px; height:34px; }
.product-card.sold-out .product-emoji { filter:grayscale(.6); opacity:.55; }
.sold-out-label { position:absolute; z-index:3; left:50%; bottom:10px; padding:5px 9px; transform:translateX(-50%); border-radius:8px; color:#fff; background:rgba(23,23,25,.84); font-size:.64rem; font-weight:850; white-space:nowrap; }
.cart-float { height:60px; bottom:calc(80px + var(--safe-bottom)); }
.bottom-nav { min-height:calc(74px + var(--safe-bottom)); padding-bottom:var(--safe-bottom); }
.bottom-nav button { min-height:58px; border-radius:12px; }
.popular-searches { margin-bottom:18px; }
.popular-searches>span,.search-result-head { display:block; padding:0 18px; color:var(--muted); font-size:.76rem; font-weight:750; }
.search-tags button { min-height:40px; font-size:.78rem; cursor:pointer; }
.page-summary { display:flex; gap:8px; align-items:baseline; padding:0 18px 10px; color:var(--muted); font-size:.78rem; }
.page-summary strong { color:var(--ink); font-size:1.1rem; }
.order-card-head>div { display:grid; gap:3px; }
.order-card-head small { color:var(--muted); font-size:.69rem; }
.order-mini-progress,.order-progress { position:relative; display:grid; grid-template-columns:repeat(4,1fr); margin:17px 0 13px; }
.order-mini-progress::before,.order-progress::before { content:""; position:absolute; left:12.5%; right:12.5%; top:10px; height:2px; background:#e2e2e5; }
.order-mini-progress span,.order-progress span { position:relative; display:grid; justify-items:center; gap:5px; color:#99999e; }
.order-mini-progress i,.order-progress i { display:grid; width:22px; height:22px; place-items:center; border:2px solid #dddde0; border-radius:50%; background:#fff; font-size:.58rem; font-style:normal; font-weight:900; }
.order-mini-progress small,.order-progress small { font-size:.58rem; font-weight:750; text-align:center; }
.order-mini-progress span.active,.order-progress span.active { color:var(--green); }
.order-mini-progress span.active i,.order-progress span.active i { border-color:var(--green); color:#fff; background:var(--green); }
.order-card details { margin-top:12px; padding-top:11px; border-top:1px solid var(--line); }
.order-card summary { color:var(--red); font-size:.72rem; font-weight:800; cursor:pointer; }
.order-details { display:grid; gap:7px; margin-top:10px; padding:10px; border-radius:10px; background:#f7f7f8; }
.order-details span { display:flex; justify-content:space-between; color:var(--muted); font-size:.7rem; }
.account-stats { display:grid; grid-template-columns:repeat(3,1fr); gap:8px; margin:-4px 18px 18px; }
.account-stats button { display:grid; min-height:74px; gap:4px; place-items:center; padding:9px 4px; border:1px solid var(--line); border-radius:15px; background:#fff; cursor:pointer; }
.account-stats strong { font-size:1.12rem; } .account-stats span { color:var(--muted); font-size:.68rem; font-weight:750; }
.sheet { padding-bottom:calc(24px + var(--safe-bottom)); overscroll-behavior:contain; }
.sheet-close { width:40px; height:40px; right:14px; top:13px; }
.product-sheet-visual { position:relative; height:275px; }
.product-sheet-visual>span { font-size:8.2rem; filter:drop-shadow(0 18px 15px rgba(0,0,0,.14)); }
.product-sheet-visual>b { position:absolute; left:14px; top:14px; padding:6px 9px; border-radius:8px; color:#fff; background:var(--red); font-size:.65rem; }
.sheet-heart { position:absolute; right:14px; top:14px; display:grid; width:42px; height:42px; place-items:center; border:0; border-radius:50%; color:var(--red); background:rgba(255,255,255,.94); box-shadow:0 5px 15px rgba(0,0,0,.12); font-size:1.25rem; }
.product-facts { display:grid; grid-template-columns:1fr 1fr; gap:9px; margin:0 0 22px; }
.product-facts span { display:grid; gap:3px; padding:10px; border-radius:12px; background:#f6f6f7; }
.product-facts strong { color:var(--green); font-size:.78rem; } .product-facts small { color:var(--muted); font-size:.65rem; }
.product-sheet-footer .price em { color:var(--muted); font-size:.72rem; font-style:normal; text-decoration:line-through; }
.cart-line { grid-template-columns:60px 1fr auto; min-height:82px; }
.cart-line-visual { width:60px; height:60px; padding:0; border:0; }
.cart-line-copy em { margin-top:3px; color:var(--green); font-size:.65rem; font-style:normal; font-weight:800; }
.cart-line-copy em.cart-warning { color:var(--red); }
.cart-line-unavailable { border-left:3px solid var(--red); padding-left:8px; }
.compact-empty { padding:35px 20px; }
.savings-row strong,.checkout-saving strong { color:var(--green); }
.cart-delivery-card { display:grid; grid-template-columns:36px 1fr auto; gap:9px; align-items:center; margin:0 0 14px; padding:11px; border:1px solid #f0d8db; border-radius:14px; background:#fff8f8; }
.cart-delivery-card>span { display:grid; width:34px; height:34px; place-items:center; border-radius:10px; color:var(--red); background:#fff; }
.cart-delivery-card>div { display:grid; min-width:0; gap:3px; } .cart-delivery-card strong { font-size:.77rem; } .cart-delivery-card small { overflow:hidden; color:var(--muted); font-size:.66rem; text-overflow:ellipsis; white-space:nowrap; }
.cart-delivery-card button { min-height:38px; padding:0 10px; border:0; border-radius:10px; color:#fff; background:var(--ink); font-size:.67rem; font-weight:800; }
.price-options button { min-height:42px; padding:0 13px; border:1px solid var(--line); border-radius:11px; background:#fff; font-size:.76rem; font-weight:800; cursor:pointer; }
.price-options button.active { border-color:var(--red); color:var(--red); background:var(--red-soft); box-shadow:inset 0 0 0 1px var(--red); }
.price-options { display:flex; gap:8px; flex-wrap:wrap; }
.saved-home-action { border-color:#cfe9da; background:#f4fbf7; }
.saved-home-action > span { background:var(--green); }
.simple-delivery-fields { padding:1px 0 5px; }
.optional-label { display:flex; align-items:center; justify-content:space-between; gap:10px; }
.optional-label small { padding:4px 7px; border-radius:999px; color:var(--muted); background:#f1f1f3; font-size:.65rem; font-weight:750; }
.save-home-switch { min-height:64px; margin:11px 0 4px; padding:10px 12px; border:1px solid var(--line); border-radius:13px; background:#fff; }
.account-fast-card { display:grid; grid-template-columns:38px 1fr auto; gap:10px; align-items:center; margin:12px 0 15px; padding:12px; border:1px solid #f1d9dc; border-radius:15px; background:#fff8f8; }
.account-fast-icon { display:grid; width:36px; height:36px; place-items:center; border-radius:11px; color:#fff; background:var(--red); font-weight:900; }
.account-fast-card > div { display:grid; min-width:0; gap:3px; }
.account-fast-card strong { font-size:.8rem; }
.account-fast-card small { color:var(--muted); font-size:.68rem; line-height:1.35; }
.account-fast-card button { min-height:38px; padding:0 12px; border:0; border-radius:10px; color:#fff; background:var(--ink); font-size:.72rem; font-weight:850; cursor:pointer; }
.account-fast-card.created { border-color:#cfe9da; background:#f4fbf7; }
.account-fast-card.created .account-fast-icon { background:var(--green); }
#checkoutContact { margin-top:3px; color:var(--muted); font-size:.66rem; }
.delivery-facts { display:flex; gap:7px; justify-content:flex-end; margin:-10px 0 14px; }
.delivery-facts span { padding:5px 8px; border-radius:8px; color:var(--green); background:#eaf7ef; font-size:.68rem; font-weight:800; }
.checkout-order-summary { display:grid; gap:6px; margin:-4px 0 16px; padding:11px 13px; border-radius:13px; background:#f6f6f7; }
.checkout-order-summary>div { display:flex; justify-content:space-between; color:var(--muted); font-size:.72rem; }
.payment-choice { min-height:62px; }
.payment-choice>span:nth-of-type(2) { display:grid; gap:3px; }
.payment-choice small { color:var(--muted); font-size:.66rem; }
.checkout-switch { margin:6px 0 17px; padding:12px; border:1px solid var(--line); border-radius:13px; }
.confirmation-note { margin-bottom:16px; padding:12px 13px; border-left:3px solid var(--green); border-radius:5px 12px 12px 5px; background:#f0f8f4; }
.confirmation-note strong { color:var(--green); font-size:.76rem; } .confirmation-note p { margin:5px 0 0; color:#4f5f56; font-size:.69rem; line-height:1.45; }
.success-payment { padding:10px 12px; border-radius:11px; background:#f6f6f7; }

@media (max-width:420px) {
  .carousel-arrow { display:none; }
  .promo-copy { width:68%; }
  .promo-copy h1,.promo-copy h2 { font-size:1.86rem; }
  .delivery-meta small { display:none; }
  .product-grid { gap:10px; padding-inline:13px; }
  .product-visual { height:132px; }
  .product-emoji { font-size:3.9rem; }
  .product-info { padding-inline:10px; }
  .quantity-control { gap:3px; }
  .quantity-control button { width:30px; }
}

@media (min-width:741px) {
  body { padding:24px; }
  .app-shell { width:min(calc(100% - 48px),1100px); min-height:calc(100vh - 48px); border-radius:28px; padding-bottom:100px; }
  .topbar { padding-inline:28px; border-radius:28px 28px 0 0; }
  .delivery-bar { width:calc(100% - 56px); margin-inline:28px; }
  .search-wrap { margin-inline:28px; }
  .promo-track { gap:16px; padding-inline:28px; }
  .promo-card { flex-basis:430px; height:240px; }
  .promo-dots { justify-content:flex-start; padding-left:28px; }
  .quick-row,.category-row { padding-inline:28px; }
  .section-heading,.catalog-summary,.popular-searches>span,.search-result-head,.page-summary { padding-inline:28px; }
  .buy-again-card { margin-inline:28px; }
  .product-grid { grid-template-columns:repeat(4,minmax(0,1fr)); gap:16px; padding-inline:28px; }
  .product-visual { height:160px; }
  .bottom-nav { width:min(calc(100% - 96px),1044px); bottom:24px; min-height:66px; padding:6px 10px; border:1px solid var(--line); border-radius:20px; box-shadow:0 12px 35px rgba(18,18,22,.14); }
  .cart-float { width:min(calc(100% - 120px),600px); bottom:101px; }
  .orders-list { grid-template-columns:repeat(2,minmax(0,1fr)); padding-inline:28px; }
  .account-card,.account-stats,.settings-list { max-width:620px; margin-inline:auto; }
  .sheet { width:min(calc(100% - 48px),590px); max-height:calc(100vh - 48px); bottom:24px; border-radius:25px; padding-inline:24px; transform:translate(-50%,calc(100% + 48px)); }
  .sheet.open { transform:translate(-50%,0); }
  .tall-sheet { height:min(calc(100vh - 48px),850px); }
}
@media (min-width:741px) and (max-width:940px) { .product-grid { grid-template-columns:repeat(3,minmax(0,1fr)); } }

/* Version 5: research-led shopping refinement */
:root {
  --canvas:#f2f2f4;
  --surface:#ffffff;
  --surface-raised:#ffffff;
  --surface-soft:#f6f6f7;
  --nav-height:70px;
  color-scheme:light;
}
html { scroll-padding-top:76px; scroll-padding-bottom:160px; background:var(--canvas); }
body { color:var(--ink); background:var(--canvas); }
.ui-icon { width:1.25em; height:1.25em; overflow:visible; fill:none; stroke:currentColor; stroke-width:1.9; stroke-linecap:round; stroke-linejoin:round; }
.app-shell { background:var(--surface); }
.topbar { min-height:58px; padding:8px max(16px,var(--safe-right)) 6px max(16px,var(--safe-left)); box-shadow:none; }
.brand { min-height:44px; }
.brand-mark { width:34px; height:34px; border-radius:10px 10px 10px 4px; box-shadow:0 5px 13px rgba(220,24,40,.22); font-size:1.12rem; }
.brand-copy strong { font-size:1.12rem; }
.brand-copy small { margin-top:3px; font-size:.68rem; letter-spacing:.07em; }
.language-switch,.avatar { min-height:40px; }
.delivery-bar { width:calc(100% - 32px); min-height:52px; margin:7px 16px 10px; padding:7px 10px; border-radius:14px; box-shadow:none; }
.delivery-icon { width:34px; height:34px; flex-basis:34px; }
.delivery-icon .ui-icon { width:19px; height:19px; }
.delivery-copy { margin-left:9px; }
.delivery-copy small { font-size:.78rem; }
.delivery-copy strong { max-width:min(44vw,440px); font-size:.91rem; }
.delivery-meta strong { font-size:.76rem; }
.delivery-meta small { font-size:.7rem; }
.search-wrap { height:48px; gap:8px; margin:0 16px 10px; padding:0 5px 0 13px; border-radius:14px; box-shadow:none; }
.search-wrap > .search-leading { display:grid; width:22px; flex:0 0 22px; place-items:center; color:#66666b; transform:none; }
.search-leading .ui-icon { width:20px; height:20px; }
.search-wrap input { font-size:1rem; }
.search-wrap kbd { display:none; }
.search-clear { width:34px; height:34px; flex-basis:34px; font-size:1.08rem; }
.search-wrap .search-submit { display:grid; width:40px; height:40px; flex:0 0 40px; place-items:center; padding:0; border:0; border-radius:11px; color:#fff; background:var(--red); cursor:pointer; }
.search-submit .ui-icon { width:20px; height:20px; stroke-width:2.2; }
.promo-track { gap:10px; padding:0 16px 3px; }
.promo-card { flex-basis:calc(100% - 22px); height:184px; border-radius:20px; box-shadow:0 10px 25px rgba(33,16,18,.1); }
.promo-copy { width:64%; padding:18px 0 18px 19px; }
.promo-copy .eyebrow { margin-bottom:6px; font-size:.68rem; letter-spacing:.09em; }
.promo-copy h1,.promo-copy h2 { font-size:1.62rem; line-height:1.02; }
.promo-copy p { margin:7px 0 10px; font-size:.82rem; line-height:1.35; }
.promo-button { min-height:40px; padding:0 14px; border-radius:10px; font-size:.78rem; box-shadow:none; }
.deal-badge { right:15px; top:45px; width:74px; height:74px; }
.deal-badge strong { margin-top:13px; font-size:1.15rem; }
.deal-badge span { margin-top:-10px; font-size:.62rem; }
.deal-product { right:15px; top:39px; }
.deal-product span { width:72px; height:72px; border-radius:20px; font-size:2.65rem; box-shadow:0 10px 22px rgba(0,0,0,.18); }
.deal-product strong { padding:5px 8px; font-size:.7rem; }
.orbit-one { width:170px; height:170px; }
.orbit-two { width:110px; height:110px; }
.carousel-arrow { top:72px; width:38px; height:38px; }
.promo-dots { height:29px; }
.promo-dots button,.promo-dots button.active { width:26px; min-width:26px; height:26px; min-height:26px; }
.quick-section { padding:1px 0 15px; }
.quick-row { gap:8px; padding:0 16px 2px; }
.quick-row button { min-height:40px; gap:7px; padding:0 11px; border-radius:12px; font-size:.81rem; box-shadow:none; }
.quick-row button span { width:23px; height:23px; border-radius:7px; }
.section-heading { margin-inline:0; padding:0 16px; }
.section-heading h2 { font-size:1.16rem; }
.section-heading button { min-height:40px; font-size:.83rem; }
.category-row { gap:7px; padding:8px 16px 16px; }
.category-button { flex-basis:67px; grid-template-rows:48px auto; gap:5px; min-height:70px; align-content:start; }
.category-icon { width:48px; height:48px; border-radius:15px; font-size:1.42rem; }
.category-button span:last-of-type { width:67px; font-size:.79rem; }
.category-button small { display:none; }
.category-button.active .category-icon { box-shadow:inset 0 0 0 2px var(--surface),0 4px 12px rgba(220,24,40,.11); transform:none; }
.buy-again-section { margin-bottom:18px; }
.buy-again-card { min-height:82px; margin:8px 16px 0; padding:12px; border-radius:16px; box-shadow:none; }
.buy-again-copy strong { font-size:.9rem; }
.buy-again-copy small { font-size:.76rem; }
.buy-again-card > button { min-height:42px; font-size:.78rem; }
.catalog-heading { gap:8px; }
.catalog-actions { gap:6px; }
.section-heading .catalog-actions button { min-height:40px; gap:5px; padding:0 9px; border-radius:11px; font-size:.79rem; box-shadow:none; }
.catalog-actions .ui-icon { width:17px; height:17px; }
.catalog-summary { min-height:32px; padding:4px 16px 0; font-size:.82rem; }
.catalog-summary button { min-height:32px; font-size:.82rem; }
.product-grid { gap:10px; padding:10px 16px 20px; }
.product-card { border-radius:17px; box-shadow:none; }
.product-card.in-cart { border-color:#efb9be; box-shadow:inset 0 0 0 1px rgba(220,24,40,.18); }
.product-card.in-cart::after { content:"In cart"; position:absolute; z-index:4; left:8px; top:8px; padding:4px 7px; border-radius:7px; color:#fff; background:var(--ink); font-size:.68rem; font-weight:800; pointer-events:none; }
.khmer .product-card.in-cart::after { content:"ក្នុងកន្ត្រក"; }
.product-card.in-cart .product-badge { top:36px; }
.product-visual { height:132px; }
.product-visual::after { width:66px; height:14px; bottom:17px; opacity:.6; }
.product-emoji { font-size:3.8rem; filter:drop-shadow(0 9px 7px rgba(0,0,0,.1)); }
.product-badge { padding:5px 7px; font-size:.65rem; }
.heart { width:36px; height:36px; right:7px; top:7px; font-size:1.08rem; }
.product-info { padding:10px 11px 12px; }
.product-unit { font-size:.8rem; }
.stock { font-size:.73rem; }
.product-info h3 { min-height:40px; margin:4px 0 3px; font-size:.95rem; line-height:1.3; }
.card-saving { min-height:18px; font-size:.75rem; }
.price-line { min-height:42px; margin-top:2px; gap:5px; }
.price-line strong { font-size:1.05rem; }
.old-price { font-size:.78rem; }
.add-button { min-width:42px; width:auto; height:42px; padding:0 10px; border-radius:12px; box-shadow:none; font-size:.82rem; font-weight:850; }
.add-symbol { font-size:1.15rem; line-height:1; }
.add-text { margin-left:4px; }
.quantity-control { gap:4px; }
.quantity-control button { width:35px; height:35px; border-radius:10px; }
.quantity-control span { min-width:14px; font-size:.84rem; }
.bottom-nav { min-height:calc(var(--nav-height) + var(--safe-bottom)); padding:5px 10px var(--safe-bottom); }
.bottom-nav button { min-height:60px; gap:3px; }
.bottom-nav button span { display:grid; width:28px; height:28px; place-items:center; font-size:inherit; }
.bottom-nav .ui-icon { width:23px; height:23px; stroke-width:1.85; }
.bottom-nav button small { font-size:.77rem; }
.bottom-nav button.active span { border-radius:10px; background:var(--red-soft); }
.cart-float { bottom:calc(var(--nav-height) + 8px + var(--safe-bottom)); width:min(calc(100% - 28px),432px); height:58px; border-radius:16px; }
.page-head { padding:13px 16px 16px; }
.page-head h1 { font-size:1.55rem; }
.search-large { margin-bottom:20px; }
.popular-searches > span,.search-result-head,.page-summary { padding-inline:16px; font-size:.82rem; }
.search-tags { padding:9px 16px; }
.search-tags button { min-height:42px; padding:8px 12px; font-size:.82rem; }
.order-card p,.orders-empty p,.success-sheet p { font-size:.84rem; }
.order-status { font-size:.7rem; }
.order-card footer,.order-card summary { font-size:.8rem; }
.order-card-actions button { min-height:42px; font-size:.82rem; }
.order-mini-progress small,.order-progress small { font-size:.68rem; }
.account-card { margin:0 16px 17px; }
.account-card strong { font-size:1rem; }
.account-card span { font-size:.78rem; }
.account-sheet { min-height:310px; }
.account-setup-intro { margin:0 0 20px; color:var(--muted); font-size:.86rem; }
.account-contact-input { width:100%; min-height:52px; margin:7px 0 18px; padding:0 14px; border:1px solid var(--line); border-radius:13px; color:var(--ink); background:var(--surface-raised); outline:0; }
.account-contact-input:focus { border-color:var(--red); box-shadow:0 0 0 3px rgba(220,24,40,.1); }
.account-stats { margin:-2px 16px 16px; }
.account-stats button { min-height:76px; }
.account-stats span { font-size:.76rem; }
.settings-list { margin:0 16px; }
.settings-list button { min-height:62px; }
.settings-list button > span { width:34px; height:34px; }
.settings-list button .ui-icon { width:18px; height:18px; }
.settings-list button strong { font-size:.9rem; }
.settings-list button small { font-size:.78rem; }
.sheet { scroll-padding-top:70px; scroll-padding-bottom:128px; }
.sheet-title h2 { font-size:1.38rem; }
.sheet-title button { min-height:40px; font-size:.82rem; }
.field-label { font-size:.84rem; }
.location-action { min-height:64px; }
.location-action strong { font-size:.9rem; }
.location-action small { font-size:.76rem; }
.location-action > span .ui-icon { width:19px; height:19px; }
.map-search button { min-height:40px; font-size:.8rem; }
.map-readout strong,.delivery-result strong { font-size:.84rem; }
.map-readout small,.map-credit,.estimate-note,.delivery-result small { font-size:.75rem; }
.optional-label small { font-size:.72rem; }
.save-home-switch { min-height:68px; }
.switch-row strong { font-size:.88rem; }
.switch-row small { font-size:.76rem; }
.account-fast-card { margin:10px 0 13px; padding:10px 11px; }
.account-fast-icon .ui-icon { width:19px; height:19px; }
.account-fast-card strong { font-size:.86rem; }
.account-fast-card small { font-size:.75rem; }
.account-fast-card button { min-height:42px; font-size:.78rem; }
.delivery-facts span { font-size:.75rem; }
.checkout-order-summary > div { font-size:.8rem; }
.payment-choice small,#checkoutContact { font-size:.75rem; }
.preference-choice { min-height:48px; }
.preference-choice span { font-size:.84rem; }
.confirmation-note strong { font-size:.82rem; }
.confirmation-note p { font-size:.77rem; }
.checkout-privacy { margin:2px 0 10px; color:var(--muted); font-size:.75rem; line-height:1.45; text-align:center; }
.checkout-sticky { position:sticky; z-index:4; bottom:calc(-24px - var(--safe-bottom)); margin:0 -18px; padding:10px 18px calc(22px + var(--safe-bottom)); border-top:1px solid var(--line); background:rgba(255,255,255,.96); box-shadow:0 -10px 28px rgba(20,20,24,.07); backdrop-filter:blur(14px); }
.checkout-sticky .checkout-total { margin:0 0 9px; }
.checkout-sticky .primary-button { min-height:50px; }
.toast { top:max(12px,calc(var(--safe-top) + 8px)); font-size:.82rem; }

@media (hover:hover) {
  .product-card:hover { transform:translateY(-1px); }
  .product-card:hover .product-emoji { transform:translateY(-2px) rotate(0); }
}

@media (max-width:420px) {
  .promo-card { height:178px; }
  .promo-copy { width:69%; }
  .promo-copy h1,.promo-copy h2 { font-size:1.52rem; }
  .deal-badge { right:12px; }
  .product-grid { gap:9px; padding-inline:12px; }
  .product-visual { height:125px; }
  .product-emoji { font-size:3.55rem; }
  .quantity-control button { width:33px; height:34px; }
  .add-button { min-width:40px; height:40px; padding-inline:9px; }
  .product-card.in-cart .price-line { flex-wrap:wrap; }
  .product-card.in-cart .quantity-control { width:100%; margin-top:2px; justify-content:flex-end; }
}

@media (max-width:350px) {
  .delivery-meta { display:none; }
  .product-info { padding-inline:9px; }
  .add-text { display:none; }
  .add-symbol { font-size:1.2rem; }
}

@media (max-width:365px) {
  .add-text { display:none; }
  .add-symbol { font-size:1.2rem; }
}

@media (min-width:741px) {
  .app-shell { width:min(calc(100% - 48px),1120px); }
  .topbar { padding-inline:28px; }
  .delivery-bar { width:calc(100% - 56px); margin-inline:28px; }
  .search-wrap { margin-inline:28px; }
  .search-wrap kbd { display:inline-block; }
  .promo-track { padding-inline:28px; }
  .promo-card { flex-basis:390px; height:198px; }
  .carousel-arrow { top:80px; }
  .quick-row,.category-row { padding-inline:28px; }
  .section-heading,.catalog-summary,.popular-searches > span,.search-result-head,.page-summary { padding-inline:28px; }
  .buy-again-card { margin-inline:28px; }
  .product-grid { padding-inline:28px; }
  .product-visual { height:150px; }
  .bottom-nav { width:min(calc(100% - 96px),1064px); }
  .checkout-sticky { margin-inline:-24px; padding-inline:24px; }
  .account-card { max-width:620px; margin:0 auto 17px; }
  .account-stats { max-width:620px; margin:-2px auto 16px; }
  .settings-list { max-width:620px; margin:0 auto; }
}

body.telegram-dark {
  --ink:#f5f5f7;
  --muted:#aaaab1;
  --line:#35353b;
  --soft:#29292d;
  --paper:#1d1d20;
  --canvas:#101012;
  --surface:#171719;
  --surface-raised:#1f1f22;
  --surface-soft:#27272b;
  --red:#ff5867;
  --red-dark:#ff7180;
  --red-soft:#37181d;
  --green:#58d49a;
  --tg-bg:#171719;
  color-scheme:dark;
  color:var(--ink);
  background:var(--canvas);
}
.telegram-dark { scrollbar-color:#55555d var(--surface); }
html.telegram-dark { background:#101012; }
.telegram-dark .app-shell,.telegram-dark .topbar,.telegram-dark .bottom-nav,.telegram-dark .sheet { background:var(--surface); }
.telegram-dark .topbar,.telegram-dark .bottom-nav { border-color:var(--line); }
.telegram-dark .language-switch,.telegram-dark .search-wrap,.telegram-dark .quick-row button,.telegram-dark .product-card,.telegram-dark .section-heading .catalog-actions button,.telegram-dark .search-tags button,.telegram-dark .order-card,.telegram-dark .account-stats button,.telegram-dark .settings-list button,.telegram-dark .sort-options label,.telegram-dark .preference-choice,.telegram-dark .payment-choice,.telegram-dark .price-options button,.telegram-dark .save-home-switch,.telegram-dark .secondary-button,.telegram-dark .mini-product,.telegram-dark .choice,.telegram-dark .fulfilment-option-body,.telegram-dark .number-choice-grid span { color:var(--ink); border-color:var(--line); background:var(--surface-raised); }
.telegram-dark .search-wrap input,.telegram-dark .map-search input,.telegram-dark #phoneInput,.telegram-dark #deliveryNote,.telegram-dark #timeSelect { color:var(--ink); background:transparent; }
.telegram-dark .account-contact-input { color:var(--ink); border-color:var(--line); background:var(--surface-raised); }
.telegram-dark .search-wrap input::placeholder,.telegram-dark .map-search input::placeholder,.telegram-dark #phoneInput::placeholder,.telegram-dark #deliveryNote::placeholder,.telegram-dark .account-contact-input::placeholder { color:#85858d; }
.telegram-dark .delivery-bar,.telegram-dark .account-fast-card,.telegram-dark .buy-again-card,.telegram-dark .cart-delivery-card,.telegram-dark .location-action,.telegram-dark .door-order-intro { color:var(--ink); border-color:#563036; background:linear-gradient(135deg,#2a171a,var(--surface-raised)); }
.telegram-dark .delivery-icon,.telegram-dark .cart-delivery-card > span { background:#2c2022; }
.telegram-dark .category-button.active .category-icon { box-shadow:inset 0 0 0 2px var(--surface); }
.telegram-dark .product-info { background:var(--surface-raised); }
.telegram-dark .heart,.telegram-dark .quantity-control button,.telegram-dark .sheet-close,.telegram-dark .search-clear,.telegram-dark .carousel-arrow { color:var(--ink); border-color:var(--line); background:rgba(31,31,34,.94); }
.telegram-dark .search-wrap kbd { color:var(--muted); background:var(--surface-soft); }
.telegram-dark .product-card.in-cart { border-color:#81424a; }
.telegram-dark .brand-mark,.telegram-dark .search-wrap .search-submit,.telegram-dark .quick-row button.active span,.telegram-dark .catalog-actions em,.telegram-dark .product-badge,.telegram-dark .add-button,.telegram-dark .mini-product button,.telegram-dark .cart-count,.telegram-dark .buy-again-card > button,.telegram-dark .primary-button,.telegram-dark .order-card-actions button.primary-small,.telegram-dark .location-action > span,.telegram-dark .account-fast-icon { color:#fff; background:#dc1828; }
.telegram-dark .add-button.disabled { color:#9b9ba2; background:#343439; }
.telegram-dark .promo-button:not(.light) { color:#fff; background:#171719; }
.telegram-dark .promo-button.light { color:#b30e1b; background:#fff; }
.telegram-dark .account-avatar { color:#dc1828; }
.telegram-dark .product-card.in-cart::after { color:#fff; background:#202024; }
.telegram-dark .old-price { color:#aaaab1; }
.telegram-dark .account-card { background:linear-gradient(135deg,#25252a,#38383e); }
.telegram-dark .settings-list,.telegram-dark .account-stats button { border-color:var(--line); }
.telegram-dark .settings-list button > span { background:#35181d; }
.telegram-dark .map-search,.telegram-dark .map-search-results,.telegram-dark .map-search-results button,.telegram-dark .map-readout,.telegram-dark .delivery-result,.telegram-dark .checkout-order-summary,.telegram-dark .product-facts span,.telegram-dark .order-details,.telegram-dark .success-payment,.telegram-dark .order-code,.telegram-dark .order-mini-progress i,.telegram-dark .order-progress i,.telegram-dark .buy-again-products span { color:var(--ink); border-color:var(--line); background:var(--surface-soft); }
.telegram-dark .map-search button,.telegram-dark .cart-delivery-card button,.telegram-dark .account-fast-card button { color:#fff; background:#39393f; }
.telegram-dark .choice.active,.telegram-dark .payment-choice.active,.telegram-dark .preference-choice.active,.telegram-dark .quick-row button.active,.telegram-dark .fulfilment-option > input:checked + .fulfilment-option-body,.telegram-dark .number-choice-grid input:checked + span { border-color:var(--red); color:var(--red); background:#35181d; }
.telegram-dark .optional-label small { color:var(--muted); background:#2c2c31; }
.telegram-dark .saved-home-action,.telegram-dark .confirmation-note,.telegram-dark .account-fast-card.created,.telegram-dark .door-service-card { border-color:#275b44; background:#152a20; }
.telegram-dark .success-check,.telegram-dark .order-mini-progress span.active i,.telegram-dark .order-progress span.active i,.telegram-dark .saved-home-action > span,.telegram-dark .account-fast-card.created .account-fast-icon { color:#fff; border-color:#087443; background:#087443; }
.telegram-dark .order-status,.telegram-dark .delivery-facts span { color:var(--green); background:#153528; }
.telegram-dark .confirmation-note p { color:#b6c9bd; }
.telegram-dark .checkout-sticky { border-color:var(--line); background:rgba(23,23,25,.96); }
.telegram-dark .promo-fresh::after { background:linear-gradient(90deg,rgba(249,248,246,.97) 0%,rgba(249,248,246,.86) 43%,rgba(249,248,246,0) 73%); }
.telegram-dark .promo-fresh .dark-copy { color:#171719; }
.telegram-dark .promo-fresh .dark-copy p { color:#404044; }
.telegram-dark .leaflet-control-zoom a { color:#171719; }
.telegram-dark .network-banner { color:#ffe2b9; border-color:#75532b; background:#392b18; }

/* Version 6 — instruction-led checkout and catalog refinement */
body { font-size:16px; }
.app-shell { width:min(100%,760px); }
.khmer,
.khmer button,
.khmer input,
.khmer textarea,
.khmer select { font-family:"Noto Sans Khmer","Khmer OS System",system-ui,sans-serif; line-height:1.55; }

.product-grid {
  grid-template-columns:minmax(0,1fr) !important;
  max-width:720px;
  margin-inline:auto;
  gap:10px;
}
.product-card {
  display:grid;
  min-height:138px;
  grid-template-columns:112px minmax(0,1fr);
  overflow:hidden;
  border-radius:18px;
}
.product-visual {
  height:100% !important;
  min-height:138px;
  border-right:1px solid rgba(0,0,0,.035);
  cursor:default;
}
.product-visual::after { width:62px; bottom:20px; }
.product-open { width:100%; height:100%; min-height:138px; }
.product-emoji { font-size:3.75rem; }
.product-badge { left:7px; top:7px; max-width:72px; font-size:.61rem; text-align:center; }
.product-card.in-cart::after { left:7px; top:7px; }
.product-card.in-cart .product-badge { top:35px; }
.heart { width:40px; height:40px; right:5px; top:5px; }
.product-info {
  display:grid;
  min-width:0;
  align-content:center;
  padding:13px 13px 12px;
}
.product-meta { min-width:0; }
.product-unit,.stock { font-size:.78rem; }
.product-info h3 { min-height:0; margin:4px 0 2px; font-size:1rem; line-height:1.3; }
.card-saving { min-height:18px; font-size:.76rem; }
.product-info-link {
  width:max-content;
  min-height:32px;
  margin:1px 0 4px -4px;
  padding:4px;
  border:0;
  color:var(--red);
  background:transparent;
  font-size:.78rem;
  font-weight:800;
  cursor:pointer;
}
.price-line { min-height:42px; margin-top:0; }
.price-line strong { font-size:1.08rem; }
.add-button { min-width:68px; min-height:44px; height:44px; }
.quantity-control button { width:40px; height:40px; }

.cart-float {
  width:auto;
  min-width:276px;
  max-width:min(calc(100% - 28px),340px);
  height:54px;
  padding-inline:13px;
  border-radius:999px;
}

.sheet { scroll-padding-top:86px; }
.sheet-handle { margin-bottom:8px; }
.sheet-back-row { min-height:40px; display:flex; align-items:center; margin-bottom:1px; }
.sheet-back {
  display:inline-flex;
  min-height:40px;
  align-items:center;
  gap:4px;
  margin-left:-7px;
  padding:0 8px;
  border:0;
  border-radius:10px;
  color:var(--muted);
  background:transparent;
  font-size:.82rem;
  font-weight:800;
  cursor:pointer;
}
.sheet-back > span:first-child { font-size:1.35rem; line-height:1; }
.sheet-heading-row {
  display:flex;
  min-width:0;
  align-items:flex-start;
  justify-content:space-between;
  gap:14px;
  margin-bottom:16px;
}
.sheet-heading-row > div { min-width:0; }
.sheet-kicker {
  display:block;
  margin-bottom:3px;
  color:var(--red);
  font-size:.7rem;
  font-weight:900;
  letter-spacing:.1em;
}
.khmer .sheet-kicker { letter-spacing:0; }
.sheet-heading-row h2 { margin:0; font-size:clamp(1.35rem,6vw,1.72rem); line-height:1.1; letter-spacing:-.045em; }
.khmer .sheet-heading-row h2 { line-height:1.45; letter-spacing:0; }
.sheet-heading-row .sheet-close {
  position:static;
  flex:0 0 44px;
  width:44px;
  height:44px;
  margin-top:-3px;
}
.clear-order {
  display:block;
  min-height:36px;
  margin:-8px 0 10px auto;
  padding:0 4px;
  border:0;
  color:var(--red);
  background:transparent;
  font-size:.78rem;
  font-weight:800;
  cursor:pointer;
}

.contact-helper { margin:14px 0 10px; color:var(--muted); font-size:.82rem; line-height:1.45; }
.or-divider { display:flex; align-items:center; gap:10px; margin:10px 0 2px; color:var(--muted); font-size:.7rem; font-weight:900; letter-spacing:.08em; }
.or-divider::before,.or-divider::after { content:""; height:1px; flex:1; background:var(--line); }
.simple-delivery-fields input[type="tel"],
.simple-delivery-fields input[type="text"],
.account-sheet input[type="tel"],
.account-sheet input[type="text"] {
  width:100%;
  min-height:52px;
  padding:11px 13px;
  border:1px solid var(--line);
  border-radius:13px;
  outline:0;
  color:var(--ink);
  background:var(--surface-raised);
  font-size:1rem;
}
.simple-delivery-fields input:focus,
.account-sheet input:focus { border-color:var(--red); box-shadow:0 0 0 3px rgba(220,24,40,.12); }
.field-label { margin-top:12px; font-size:.88rem; }
.field-error { min-height:20px; margin:8px 2px 0; color:#b31220; font-size:.78rem; font-weight:750; }
.account-contact-input { margin:0; }
.account-setup-intro { margin-bottom:14px; }
.account-sheet .primary-button { margin-top:20px; }

.delivery-result.draft-result { border-style:dashed; }
.delivery-result.draft-result .store-dot { background:#a2a2a7; }
.map-picker { min-height:250px; }
.map-loading { display:grid; height:100%; place-content:center; gap:10px; color:var(--muted); background:var(--surface-soft); text-align:center; }
.map-loading .status-spinner { margin-inline:auto; }
.map-error button { min-height:42px; margin-top:5px; padding:0 14px; border:0; border-radius:11px; color:#fff; background:var(--ink); font-weight:800; }

.checkout-section { margin-top:0; }
.checkout-order-summary,.invoice-lines { display:grid; gap:0; }
.invoice-card { margin:18px 0; padding:14px; border:1px solid var(--line); border-radius:15px; background:var(--surface-soft); }
.invoice-card h3 { margin:0 0 10px; font-size:.9rem; }
.invoice-line { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:12px; padding:8px 0; border-bottom:1px solid var(--line); font-size:.82rem; line-height:1.35; }
.invoice-line:last-child { border-bottom:0; }
.invoice-line span { min-width:0; color:var(--muted); }
.invoice-line strong { white-space:nowrap; }
.invoice-line.total { margin-top:3px; padding-top:12px; color:var(--ink); font-size:.98rem; }
.invoice-line.total span { color:var(--ink); font-weight:850; }
.invoice-line.saving strong { color:var(--green); }

.payment-review { display:grid; gap:9px; }
.payment-review-title { margin:0 0 10px; font-size:1.08rem; letter-spacing:-.025em; }
.payment-review-card { padding:13px 14px; border:1px solid var(--line); border-radius:14px; background:var(--surface-raised); }
.payment-review-card small { display:block; margin-bottom:4px; color:var(--muted); font-size:.72rem; font-weight:750; }
.payment-review-card strong { display:block; font-size:.88rem; line-height:1.4; }
.payment-review-card span { display:block; margin-top:3px; color:var(--muted); font-size:.78rem; line-height:1.4; }
.accuracy-check {
  display:grid;
  min-height:64px;
  grid-template-columns:44px minmax(0,1fr);
  align-items:start;
  margin:6px 0 12px;
  cursor:pointer;
}
.accuracy-check input { width:20px; height:20px; margin:12px; accent-color:var(--red); }
.accuracy-check span { padding-top:9px; font-size:.73rem; line-height:1.5; }
.payment-status { display:flex; min-height:52px; align-items:center; justify-content:center; gap:10px; margin:0 0 10px; border-radius:13px; color:var(--ink); background:var(--surface-soft); font-size:.85rem; }
.status-spinner { display:inline-block; width:20px; height:20px; border:2px solid #d0d0d4; border-top-color:var(--red); border-radius:50%; animation:spin .8s linear infinite; }
@keyframes spin { to { transform:rotate(360deg); } }
.preview-payment-note { margin:0 0 10px; color:var(--muted); font-size:.75rem; text-align:center; }
.payment-sheet .primary-button:disabled { color:#96969b; background:#e2e2e5; box-shadow:none; cursor:not-allowed; }

.toast { top:max(66px,calc(var(--safe-top) + 60px)); }

@media (max-width:420px) {
  .product-grid { padding-inline:12px; }
  .product-card { grid-template-columns:102px minmax(0,1fr); }
  .product-visual,.product-open { min-height:142px; }
  .product-info { padding-inline:11px; }
  .product-emoji { font-size:3.35rem; }
  .product-card.in-cart .price-line { flex-wrap:nowrap; }
  .product-card.in-cart .quantity-control { width:auto; margin-top:0; }
}

@media (max-width:350px) {
  .product-card { grid-template-columns:94px minmax(0,1fr); }
  .product-info { padding-inline:9px; }
  .add-text { display:inline; }
  .add-button { min-width:60px; padding-inline:8px; }
  .quantity-control { gap:2px; }
  .quantity-control button { width:36px; }
  .catalog-heading { align-items:flex-start; flex-direction:column; }
}

@media (min-width:741px) {
  .app-shell { width:min(calc(100% - 48px),760px); }
  .product-grid { padding-inline:28px; }
  .product-card { grid-template-columns:128px minmax(0,1fr); }
  .product-visual,.product-open { min-height:146px; }
  .bottom-nav { width:min(calc(100% - 96px),704px); }
  .cart-float { width:330px; }
}

.telegram-dark .product-info-link,.telegram-dark .sheet-kicker,.telegram-dark .clear-order { color:var(--red); }
.telegram-dark .simple-delivery-fields input[type="tel"],
.telegram-dark .simple-delivery-fields input[type="text"],
.telegram-dark .account-sheet input[type="tel"],
.telegram-dark .account-sheet input[type="text"],
.telegram-dark .payment-review-card,
.telegram-dark .invoice-card { color:var(--ink); border-color:var(--line); background:var(--surface-raised); }
.telegram-dark .invoice-card { background:var(--surface-soft); }
.telegram-dark .payment-sheet .primary-button:disabled { color:#777780; background:#303036; }
.telegram-dark .field-error { color:#ff7b87; }

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

/* Version 7 — screenshot-led order flow */
.product-grid {
  grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  max-width:none;
  gap:12px;
}
.product-card {
  display:block;
  min-height:0;
  cursor:pointer;
}
.product-visual {
  height:138px !important;
  min-height:0;
  border-right:0;
  cursor:pointer;
}
.product-open { min-height:0; }
.product-open:focus-visible { outline-offset:-4px; border-radius:17px; }
.product-visual,
.product-info,
.product-badge,
.product-emoji,
.sold-out-label { pointer-events:none; }
.heart,
.add-button,
.quantity-control button { position:relative; z-index:3; pointer-events:auto; }
.product-info {
  display:block;
  padding:11px 12px 13px;
}
.product-info h3 {
  min-height:40px;
  margin:4px 0 3px;
  font-size:.95rem;
}
.product-info-link { display:none; }
.price-line { min-height:42px; margin-top:2px; }
.add-button { min-width:42px; height:42px; padding-inline:10px; }
.quantity-control button { width:35px; height:35px; }

.checkout-contact-block {
  margin-bottom:12px;
  padding:14px;
  border:1px solid var(--line);
  border-radius:15px;
  background:var(--surface-soft);
}
.checkout-contact-block .field-label { display:block; margin:10px 0 6px; }
.checkout-contact-block input[type="tel"],
.checkout-contact-block input[type="text"] {
  width:100%;
  min-height:52px;
  padding:11px 13px;
  border:1px solid var(--line);
  border-radius:13px;
  outline:0;
  color:var(--ink);
  background:var(--surface-raised);
  font-size:1rem;
}
.checkout-contact-block input:focus {
  border-color:var(--red);
  box-shadow:0 0 0 3px rgba(220,24,40,.12);
}
.checkout-location-card { margin-top:12px; }
.checkout-location-card.missing { border-color:#efb9be; background:var(--red-soft); }
.checkout-location-card button { min-height:40px; padding:0 4px 0 12px; cursor:pointer; }
.checkout-notes-block { margin-bottom:16px; }
.checkout-notes-block textarea { min-height:84px; resize:vertical; }

.schedule-fields {
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(0,1fr);
  gap:9px;
  margin-top:10px;
  padding:11px;
  border:1px solid var(--line);
  border-radius:14px;
  background:var(--surface-soft);
}
.schedule-fields label { display:grid; min-width:0; gap:6px; color:var(--muted); font-size:.75rem; font-weight:800; }
.schedule-fields input,
.schedule-fields select {
  width:100%;
  min-width:0;
  min-height:48px;
  margin:0 !important;
  padding:10px 11px;
  border:1px solid var(--line);
  border-radius:11px;
  color:var(--ink);
  background:var(--surface-raised);
  font-size:.86rem;
}
.schedule-fields input:focus,
.schedule-fields select:focus { border-color:var(--red); box-shadow:0 0 0 3px rgba(220,24,40,.12); }

.payment-review-section {
  overflow:hidden;
  border:1px solid var(--line);
  border-radius:15px;
  background:var(--surface-raised);
}
.payment-review-section h3 {
  margin:0;
  padding:11px 13px;
  border-bottom:1px solid var(--line);
  color:var(--ink);
  background:var(--surface-soft);
  font-size:.82rem;
}
.payment-review-row {
  display:grid;
  grid-template-columns:minmax(105px,.8fr) minmax(0,1.4fr);
  gap:12px;
  padding:10px 13px;
  border-bottom:1px solid var(--line);
  font-size:.8rem;
  line-height:1.4;
}
.payment-review-row:last-child { border-bottom:0; }
.payment-review-row > span { color:var(--muted); }
.payment-review-row > strong { min-width:0; overflow-wrap:anywhere; text-align:right; }
.payment-review-row a { color:var(--red); text-decoration:none; }

@media (max-width:420px) {
  .product-grid { gap:9px; padding-inline:12px; }
  .product-visual { height:125px !important; }
  .product-emoji { font-size:3.55rem; }
  .product-info { padding-inline:10px; }
  .product-card.in-cart .price-line { flex-wrap:wrap; }
  .product-card.in-cart .quantity-control { width:100%; margin-top:2px; justify-content:flex-end; }
}

@media (max-width:350px) {
  .product-info { padding-inline:9px; }
  .schedule-fields { grid-template-columns:minmax(0,1fr); }
}

@media (min-width:741px) {
  .product-grid { grid-template-columns:repeat(2,minmax(0,1fr)) !important; padding-inline:28px; }
  .product-visual { height:172px !important; }
}

.telegram-dark .checkout-contact-block,
.telegram-dark .schedule-fields,
.telegram-dark .payment-review-section { color:var(--ink); border-color:var(--line); background:var(--surface-raised); }
.telegram-dark .checkout-contact-block input,
.telegram-dark .schedule-fields input,
.telegram-dark .schedule-fields select { color:var(--ink); border-color:var(--line); background:var(--surface-raised); }
