/* TAWA – màu lấy từ logo chính thức (Tawa1.svg): xanh rêu #164f37, vàng #f8c647, nền kem */
:root {
  --green: #164f37; --green-2: #1f6a4b; --green-soft: #e6efe9;
  --yellow: #f8c647; --yellow-soft: #fdf1cf;
  --cream: #fbf7ee; --card: #ffffff; --line: #ece5d6;
  --ink: #1d2420; --muted: #6b726d; --danger: #c0392b; --ok: #1f7a4d;
  --radius: 14px; --shadow: 0 2px 10px rgba(22, 79, 55, .08);
  font-family: "Be Vietnam Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: #efe9dc; color: var(--ink); }
body { font-size: 15px; line-height: 1.4; }
button { font: inherit; cursor: pointer; }
input, textarea, select { font: inherit; }
img { display: block; }
.app { max-width: 480px; margin: 0 auto; min-height: 100vh; background: var(--cream); position: relative; padding-bottom: 96px; }

/* ---------- Header ---------- */
.topbar { position: sticky; top: 0; z-index: 30; background: var(--green); color: #fff; display: flex; align-items: center; gap: 10px; padding: 10px 14px; }
.topbar .logo { height: 30px; }
.topbar .title { font-weight: 700; font-size: 16px; flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.icon-btn { background: rgba(255,255,255,.14); border: 0; color: #fff; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-size: 18px; }
.icon-btn.dark { background: #fff; color: var(--green); box-shadow: var(--shadow); }

/* ---------- Home ---------- */
.hero { background: var(--green); color: #fff; padding: 6px 16px 20px; border-radius: 0 0 22px 22px; }
.hero h1 { font-size: 20px; margin: 6px 0 12px; font-weight: 800; }
.hero h1 em { color: var(--yellow); font-style: normal; }
.seg { display: flex; background: rgba(255,255,255,.14); border-radius: 999px; padding: 4px; }
.seg button { flex: 1; border: 0; background: transparent; color: #fff; padding: 9px 6px; border-radius: 999px; font-weight: 600; }
.seg button.on { background: var(--yellow); color: var(--green); }
.seg.light { background: var(--green-soft); }
.seg.light button { color: var(--green); }
.addr-box { margin-top: 12px; background: #fff; color: var(--ink); border-radius: 12px; padding: 10px 12px; display: flex; gap: 8px; align-items: center; }
.addr-box input { border: 0; outline: 0; flex: 1; font-size: 15px; background: transparent; }
.section { padding: 16px; }
.section h2 { font-size: 17px; margin: 0 0 10px; }
.banner { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow); }
.reorder { background: var(--yellow-soft); border: 1px solid #f3dc97; border-radius: var(--radius); padding: 12px; display: flex; gap: 12px; align-items: center; }
.reorder img { width: 56px; height: 56px; object-fit: cover; border-radius: 10px; }
.reorder .grow { flex: 1; min-width: 0; }
.reorder .small { font-size: 14px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.store-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 12px; display: flex; gap: 12px; align-items: center; margin-bottom: 10px; border: 0; width: 100%; text-align: left; color: inherit; }
.store-card .pin { width: 44px; height: 44px; border-radius: 12px; background: var(--green-soft); display: grid; place-items: center; font-size: 20px; flex: none; }
.store-card.off { opacity: .55; }
.store-card .name { font-weight: 700; }
.store-card .addr { font-size: 14px; color: var(--muted); }

/* ---------- Badges / tags ---------- */
.badge { display: inline-block; font-size: 11.5px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--green-soft); color: var(--green); }
.badge.y { background: var(--yellow); color: var(--green); }
.badge.grey { background: #eee; color: #777; }
.assume { display: inline-block; font-size: 11.5px; font-weight: 700; letter-spacing: .2px; color: #8a5a00; background: #fff4d6; border: 1px dashed #e0b44a; padding: 1px 6px; border-radius: 6px; vertical-align: middle; }
.note-box { font-size: 13.5px; color: #6d5a2a; background: #fff8e4; border: 1px dashed #e7c66d; border-radius: 10px; padding: 8px 10px; margin-top: 8px; }

/* ---------- Store / menu ---------- */
.store-hero { position: relative; }
.store-hero picture { display: block; }
.store-hero img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 1; object-fit: contain; background: var(--cream); } /* banner 1200x400: hiện đủ, không cắt */
/* Nút "Đơn của tôi" trên banner: chữ rõ + icon nét, nền trắng đặc để đọc được trên ảnh; vùng chạm 44px (khung ngoài), viên thuốc 36px bên trong; nằm góc phải, không che chữ TAWA bên trái */
/* Dòng Hotline ở ô thông tin quán (trang đơn): cả dòng là liên kết gọi, cao tối thiểu 44px (QA-010) */
.kv.tel-row { min-height: 44px; align-items: center; margin-top: 6px; color: inherit; text-decoration: none; }
.kv.tel-row b { color: var(--green); }
.mode-one { margin-top: 8px; font-size: 14px; font-weight: 700; color: var(--green); background: var(--green-soft); border-radius: 999px; padding: 6px 12px; display: inline-block; }
/* Món / tuỳ chọn quán đang tắt (hết món) */
.item.off .pic img { filter: grayscale(1); opacity: .55; }
.item.off .name, .item.off .price { color: var(--muted); }
.soldout { font-size: 13.5px; font-weight: 700; color: #8a6d1c; background: #f4eee0; border-radius: 999px; padding: 6px 12px; margin-right: 7px; white-space: nowrap; }
.opt.off { opacity: .5; }
.opt.off b { color: #8a6d1c; }
.store-info { background: var(--card); margin: 10px 14px 0; position: relative; border-radius: var(--radius); box-shadow: var(--shadow); padding: 10px 12px 12px; }
.store-info h1 { font-size: 18px; margin: 0 0 2px; line-height: 1.25; }
.store-info .meta { font-size: 13.5px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 2px 10px; }
.store-info .addr1 { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.store-info #mode { margin-top: 8px; }
.search { margin: 10px 14px 0; background: #fff; border-radius: 12px; border: 1px solid var(--line); display: flex; align-items: center; gap: 8px; padding: 9px 12px; }
.search input { border: 0; outline: 0; flex: 1; background: transparent; }
.menu-head { position: sticky; top: 0; z-index: 20; background: var(--cream); margin-top: 6px; border-bottom: 1px solid var(--line); transition: box-shadow .15s; }
.menu-head.stuck { box-shadow: 0 4px 10px rgba(22, 79, 55, .10); }
.tabs { display: flex; gap: 6px; overflow-x: auto; padding: 6px 14px; scrollbar-width: none; overscroll-behavior-x: contain; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: none; min-height: 44px; border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 0 14px; font-weight: 600; color: var(--muted); }
.tabs button.on { background: var(--green); border-color: var(--green); color: #fff; }
.cat { padding: 2px 14px 4px; scroll-margin-top: 60px; }
.cat h3 { font-size: 17px; margin: 14px 0 2px; }
.cat .sub { font-size: 12.5px; color: var(--muted); margin-bottom: 6px; }
/* Mục cuối đủ cao để mọi mục cuộn được lên sát thanh danh mục (cao 57px + 8px). Thay cho padLast() đo bằng JS (QA-PERF-002, 16/11). */
#menu.done > .cat:last-of-type { min-height: calc(100vh - 65px); min-height: calc(100dvh - 65px); }
/* Dòng món kiểu food app: ảnh vuông bên trái, chữ bên phải, giá + nút ở cuối cột chữ */
.item { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); cursor: pointer; align-items: stretch; }
.item .pic { flex: none; width: 100px; }
.item .pic img { width: 100px; height: 100px; object-fit: contain; border-radius: 12px; background: var(--cream); } /* thấy trọn món kể cả ảnh không vuông */
.item .txt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.item .name { font-weight: 700; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.item .zh { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item .badge { align-self: flex-start; margin-top: 3px; }
.item .desc { font-size: 13.5px; color: var(--muted); line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 3px; }
.item .save { font-size: 12.5px; color: var(--ok); font-weight: 600; margin-top: 3px; }
.item .buy { margin-top: auto; padding-top: 4px; display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 44px; }
.item .price { font-weight: 800; color: var(--green); font-size: 15.5px; white-space: nowrap; }
.item .ctl { flex: none; display: flex; margin-right: -7px; } /* bù khoảng đệm của vùng bấm 44px để vòng tròn thẳng mép phải */
/* Vùng bấm 44×44px, vòng tròn nhìn thấy 30px */
.add, .ictl button { width: 44px; height: 44px; border: 0; padding: 0; background: transparent; display: grid; place-items: center; }
.add i, .ictl button i { font-style: normal; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-size: 20px; line-height: 1; font-weight: 700; }
.add i, .ictl [data-plus] i { background: var(--green); color: #fff; }
.ictl [data-minus] i { background: #fff; color: var(--green); border: 1.5px solid var(--green); }
.ictl { display: flex; align-items: center; }
.ictl b { min-width: 22px; text-align: center; font-size: 15px; }
.add:focus-visible i, .ictl button:focus-visible i { outline: 2px solid var(--yellow); outline-offset: 2px; }
.empty { text-align: center; color: var(--muted); padding: 30px 10px; }

/* ---------- Bottom sheet ---------- */
.overlay { position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 50; display: flex; align-items: flex-end; justify-content: center; animation: fade .15s; }
.sheet { background: var(--cream); width: 100%; max-width: 480px; max-height: 92vh; overflow-y: auto; border-radius: 20px 20px 0 0; animation: up .2s ease-out; padding-bottom: 90px; }
.sheet .pic { display: block; width: 100%; height: auto; aspect-ratio: 1 / 1; max-height: 55vh; object-fit: contain; background: var(--cream) center / contain no-repeat; } /* popup: hiện ĐỦ ảnh; giữ sẵn khung vuông + ảnh nhỏ làm nền trong lúc ảnh lớn đang tải */
.sheet .body { padding: 14px 16px; }
.sheet h2 { margin: 0; font-size: 20px; }
.sheet { position: relative; overscroll-behavior: contain; }
/* Thanh trên cùng dính đỉnh khung cuộn, cao 0: nút X và thanh kéo luôn nằm trên ảnh dù cuộn tới đâu */
.sheet .sheet-top { position: sticky; top: 0; height: 0; z-index: 5; }
.sheet .grab { position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: 120px; height: 28px; display: grid; place-items: center; touch-action: none; }
.sheet .grab::before { content: ""; width: 44px; height: 5px; border-radius: 3px; background: rgba(255,255,255,.95); box-shadow: 0 1px 4px rgba(0,0,0,.35); }
.sheet .close { position: absolute; top: 10px; right: 10px; width: 48px; height: 48px; border-radius: 50%; background: rgba(255,255,255,.96); color: var(--ink, #222); font-size: 22px; font-weight: 700; box-shadow: 0 2px 10px rgba(0,0,0,.28); border: 1px solid rgba(0,0,0,.06); display: grid; place-items: center; }
.sheet .close::after { content: ""; position: absolute; inset: -6px; } /* vùng chạm rộng thêm */
.sheet.dragging { transition: none; }
.sheet.snap { transition: transform .18s ease-out; }
.group { background: #fff; border-radius: var(--radius); padding: 12px 14px; margin-top: 12px; }
.group .gh { display: flex; justify-content: space-between; align-items: baseline; font-weight: 700; margin-bottom: 6px; }
.group .gh small { font-weight: 500; color: var(--muted); }
.opt { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); }
.opt:first-of-type { border-top: 0; }
.opt input { width: 20px; height: 20px; accent-color: var(--green); }
.opt span { flex: 1; }
textarea, .field input, .field select { width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; background: #fff; outline-color: var(--green); }
textarea { resize: vertical; min-height: 60px; }
.sheet-foot { position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); width: 100%; max-width: 480px; background: #fff; border-top: 1px solid var(--line); padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); display: flex; gap: 12px; align-items: center; z-index: 60; }
.stepper { display: flex; align-items: center; gap: 10px; }
.stepper button { width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--green); background: #fff; color: var(--green); font-size: 18px; line-height: 1; }
.stepper b { min-width: 18px; text-align: center; }
.btn { border: 0; border-radius: 12px; padding: 13px 16px; font-weight: 700; background: var(--green); color: #fff; }
.btn.block { width: 100%; }
.btn.y { background: var(--yellow); color: var(--green); }
.btn.ghost { background: #fff; color: var(--green); border: 1px solid var(--green); }
.btn.danger { background: #fff; color: var(--danger); border: 1px solid #e8b4ad; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.grow { flex: 1; }

/* ---------- Cart bar ---------- */
.cartbar { position: fixed; bottom: 12px; left: 50%; transform: translateX(-50%); width: calc(100% - 24px); max-width: 456px; z-index: 40; background: var(--green); color: #fff; border: 0; border-radius: 14px; padding: 12px 16px; display: flex; align-items: center; gap: 10px; box-shadow: 0 6px 18px rgba(22,79,55,.35); }
.cartbar .count { background: var(--yellow); color: var(--green); font-weight: 800; border-radius: 8px; padding: 2px 8px; }
.cartbar .lbl { flex: 1; text-align: left; font-weight: 700; }
.cartbar .sum { font-weight: 800; }

/* ---------- Checkout ---------- */
.card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px; margin: 12px 14px; }
.card h3 { margin: 0 0 10px; font-size: 16px; display: flex; align-items: center; gap: 8px; }
.field { margin-bottom: 10px; }
.field label { display: block; font-size: 14px; color: var(--muted); margin-bottom: 4px; }
.err { color: var(--danger); font-size: 14px; margin-top: 4px; }
.line { display: flex; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); }
.line:first-of-type { border-top: 0; }
.line img { width: 54px; height: 54px; border-radius: 10px; object-fit: cover; }
.line .opts { font-size: 13.5px; color: var(--muted); }
.line .edit { font-size: 13.5px; color: var(--green-2); font-weight: 600; background: none; border: 0; padding: 0; }
.radio-row { display: flex; align-items: center; gap: 10px; padding: 11px 0; border-top: 1px solid var(--line); }
.radio-row:first-of-type { border-top: 0; }
.radio-row input { width: 20px; height: 20px; accent-color: var(--green); }
.radio-row .grow small { display: block; color: var(--muted); font-size: 13.5px; }
.sumrow { display: flex; justify-content: space-between; padding: 4px 0; }
.sumrow.total { font-weight: 800; font-size: 17px; border-top: 1px dashed var(--line); margin-top: 6px; padding-top: 10px; }
.upsell { display: flex; gap: 10px; align-items: center; background: var(--green-soft); border-radius: 12px; padding: 10px; }
.upsell img { width: 46px; height: 46px; border-radius: 8px; object-fit: cover; }
.switch { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.switch input { width: 44px; height: 24px; accent-color: var(--green); }

/* ---------- Tracking ---------- */
.track-head { background: var(--green); color: #fff; padding: 18px 16px 26px; border-radius: 0 0 22px 22px; }
.track-head .code { opacity: .8; font-size: 14px; }
.track-head h1 { margin: 4px 0 2px; font-size: 22px; }
.track-head .eta { color: var(--yellow); font-weight: 700; }
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { position: relative; padding: 0 0 18px 32px; color: var(--muted); }
.timeline li::before { content: ""; position: absolute; left: 7px; top: 18px; bottom: -2px; width: 2px; background: var(--line); }
.timeline li:last-child::before { display: none; }
.timeline li .dot { position: absolute; left: 0; top: 2px; width: 16px; height: 16px; border-radius: 50%; border: 2px solid var(--line); background: #fff; }
.timeline li.done { color: var(--ink); }
.timeline li.done .dot { background: var(--green); border-color: var(--green); }
.timeline li.done::before { background: var(--green); }
.timeline li.cur .dot { background: var(--yellow); border-color: var(--green); box-shadow: 0 0 0 4px rgba(248,198,71,.35); }
.timeline li.cur b { color: var(--green); }
.timeline time { font-size: 12.5px; color: var(--muted); margin-left: 6px; }

/* ---------- QR ---------- */
.qr { width: 220px; height: 220px; margin: 8px auto; border: 2px dashed #c9bfa6; border-radius: 12px; display: grid; place-items: center; text-align: center; color: #8a7a55; background: repeating-linear-gradient(45deg, #faf6ea, #faf6ea 10px, #f3ecda 10px, #f3ecda 20px); font-weight: 700; padding: 12px; }
.kv { display: flex; justify-content: space-between; padding: 7px 0; border-top: 1px solid var(--line); }
.kv:first-of-type { border-top: 0; }
.copy { background: var(--green-soft); color: var(--green); border: 0; border-radius: 8px; padding: 3px 8px; font-size: 12.5px; font-weight: 700; margin-left: 6px; }

/* ---------- Rating ---------- */
.stars { display: flex; justify-content: center; gap: 8px; font-size: 38px; margin: 8px 0; }
.stars button { background: none; border: 0; color: #d9d2c0; padding: 0; font-size: 38px; line-height: 1; }
.stars button.on { color: var(--yellow); text-shadow: 0 1px 0 #c99a1a; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips button { border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 7px 12px; color: var(--ink); }
.chips button.on { background: var(--green-soft); border-color: var(--green); color: var(--green); font-weight: 600; }

/* ---------- Misc ---------- */
.toast { pointer-events: none;  position: fixed; left: 50%; bottom: 90px; transform: translateX(-50%); background: #222; color: #fff; padding: 10px 16px; border-radius: 10px; z-index: 100; font-size: 15px; max-width: 90%; animation: fade .15s; }
.demo-ribbon { background: var(--yellow); color: var(--green); font-size: 12.5px; font-weight: 700; text-align: center; padding: 4px 8px; }
.foot { text-align: center; font-size: 12.5px; color: var(--muted); padding: 18px 14px 8px; }
.foot a { color: var(--green-2); }
@keyframes up { from { transform: translateY(40px); opacity: .6; } to { transform: none; opacity: 1; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Chuẩn chạm trên điện thoại (bổ sung 14/11): mọi vùng bấm ≥ 44px, không cuộn ngang ---------- */
/* Lỗi bắt được trên Redmi thật 14/11: overflow-x:hidden trên cả html+body biến body thành khung cuộn riêng,
   cộng overscroll-behavior:none thì vuốt ngón tay KHÔNG cuộn được trang. Dùng clip (không tạo khung cuộn), bỏ overscroll. */
html, body { overflow-x: clip; max-width: 100%; }
@supports not (overflow-x: clip) { html { overflow-x: hidden; } body { overflow-x: visible; } }
body { -webkit-text-size-adjust: 100%; }
.icon-btn { width: 44px; height: 44px; font-size: 22px; }
.seg button, .tabs button, .chips button { min-height: 44px; }
.stepper button { width: 44px; height: 44px; font-size: 20px; }
.btn { min-height: 48px; }
.copy { min-height: 36px; padding: 6px 12px; position: relative; }
.copy::after { content: ""; position: absolute; inset: -4px; }
.line .edit { min-height: 44px; padding: 0 12px 0 0; }
.opt, .radio-row { min-height: 48px; }
.store-card { min-height: 72px; }
.stars button { min-width: 48px; min-height: 48px; }
input, select, textarea { font-size: 16px !important; } /* tránh Chrome/Safari tự phóng to khi gõ */
.cartbar { min-height: 56px; bottom: calc(12px + env(safe-area-inset-bottom)); }
.app { padding-bottom: calc(96px + env(safe-area-inset-bottom)); }
.sheet { padding-bottom: calc(90px + env(safe-area-inset-bottom)); }
@media (max-width: 360px) { .item .pic { width: 88px; } .item .pic img { width: 88px; height: 88px; } .item { gap: 10px; } .hero h1 { font-size: 18px; } }
@media (min-width: 720px) { body { padding: 16px 0; } .app { border-radius: 20px; box-shadow: 0 8px 30px rgba(0,0,0,.12); } }
.line .edit { min-width: 44px; text-align: left; }
.copy { min-height: 44px; min-width: 56px; }
label.switch { cursor: pointer; min-height: 48px; gap: 12px; }

/* ---------- Bổ sung sau bóc tách hành trình (14/11) ---------- */
.group .req { font-size: 12.5px; font-weight: 700; padding: 3px 9px; border-radius: 999px; background: #fdecea; color: var(--danger); }
.group .req.ok { background: var(--green-soft); color: var(--ok); }
.group .hint { font-size: 12.5px; color: var(--muted); margin-top: 6px; }
.cart-store { font-size: 14px; color: var(--muted); margin: -4px 0 6px; }
.overlay.center { align-items: center; padding: 20px; z-index: 90; } /* phải nằm trên thanh nút cố định (z 60) */
.ask { background: #fff; border-radius: 16px; padding: 18px 16px 14px; width: 100%; max-width: 340px; box-shadow: 0 10px 30px rgba(0,0,0,.2); animation: fade .15s; }
.ask .msg { font-weight: 700; font-size: 16px; text-align: center; margin-bottom: 14px; }
.ask .row { display: flex; gap: 10px; }
.ask .row .btn { flex: 1; }

/* QA-006: bàn phím ảo đang mở → ẩn hẳn thanh cố định đáy (không để bị che nửa chừng) */
html.kb-open .sheet-foot, html.kb-open .cartbar { display: none; }

/* Chuyển khoản VietQR thật: ảnh mã từ vietqr.app, giữ nguyên tỉ lệ, nền trắng để app ngân hàng quét được */
.qr-img { display: block; width: 260px; max-width: 100%; height: auto; aspect-ratio: 1; margin: 8px auto; border-radius: 12px; background: #fff; border: 1px solid #e6dcc2; object-fit: contain; }
.pay-wait { display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 14.5px; color: var(--muted); margin: 2px 0 8px; }
.pay-wait .spin { width: 14px; height: 14px; border-radius: 50%; border: 2px solid #d9cfb3; border-top-color: #8a5a00; animation: payspin 0.9s linear infinite; }
@keyframes payspin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .pay-wait .spin { animation: none; } }
/* Nhóm bắt buộc chưa chọn: bấm nút thì nhóm nổi lên (viền đỏ + rung nhẹ) */
.btn.need { opacity: .62; }
.group.attn { box-shadow: 0 0 0 2px var(--danger) inset; background: #fff6f5; animation: tw-shake .42s ease; }
.group.attn .req { background: var(--danger); color: #fff; }
@keyframes tw-shake { 0%, 100% { transform: translateX(0); } 20% { transform: translateX(-6px); } 40% { transform: translateX(6px); } 60% { transform: translateX(-4px); } 80% { transform: translateX(3px); } }
@media (prefers-reduced-motion: reduce) { .group.attn { animation: none; } }
.opt input[type=radio] { border-radius: 50%; }
/* Nút dạng liên kết (gọi quán, chỉ đường): ra khối, căn giữa, không gạch chân, không tràn ở khổ 360 */
a.btn { display: flex; align-items: center; justify-content: center; text-align: center; text-decoration: none; box-sizing: border-box; max-width: 100%; }

/* Phí giao theo khoảng cách: chọn vị trí, bản đồ kéo ghim */
.loc-box { border: 1px solid var(--line); border-radius: 12px; padding: 10px; margin-bottom: 10px; background: #fff; }
.loc-box.need { border-color: #e7c66d; background: #fffaf0; }
.loc-now { font-size: 15px; line-height: 1.35; margin-bottom: 8px; overflow-wrap: anywhere; }
.loc-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.loc-btns .btn { min-height: 44px; padding: 8px 6px; font-size: 15px; white-space: normal; line-height: 1.2; }
.loc-fee { margin-top: 8px; font-size: 15px; }
.loc-fee b { color: var(--green); }
.out-box { border: 1px solid #f0b4a8; background: #fff0ec; color: #8f2318; border-radius: 12px; padding: 10px 12px; margin-bottom: 10px; font-size: 15px; line-height: 1.4; }
.sumrow .free { color: var(--green); font-weight: 700; }
.free-hint { font-size: 13.5px; color: #8a5a00; margin: -2px 0 4px; text-align: right; }
.sur-note { font-size: 12px; color: var(--muted); margin: -2px 0 4px; text-align: right; }
.linkbtn { background: none; border: 0; padding: 0; color: var(--green); font-weight: 700; text-decoration: underline; font-size: inherit; min-height: 0; }
.overlay.mapo { align-items: stretch; z-index: 95; }
.mapsheet { background: var(--cream); width: 100%; max-width: 480px; height: 100%; display: flex; flex-direction: column; animation: up .2s ease-out; }
.map-top { display: flex; align-items: center; justify-content: space-between; padding: 8px 8px 8px 16px; padding-top: calc(8px + env(safe-area-inset-top)); }
.map-top b { font-size: 17px; }
.map-x { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: #fff; font-size: 20px; font-weight: 700; }
.map-search { display: flex; gap: 8px; padding: 0 12px 8px; }
.map-search input { flex: 1; min-width: 0; height: 44px; border: 1px solid var(--line); border-radius: 10px; padding: 0 12px; font-size: 16px; background: #fff; }
.map-search .btn { min-height: 44px; padding: 0 16px; }
.map-res { max-height: 38vh; overflow-y: auto; margin: 0 12px 8px; background: #fff; border: 1px solid var(--line); border-radius: 10px; }
.map-r { display: block; width: 100%; text-align: left; padding: 11px 12px; border: 0; border-top: 1px solid var(--line); background: none; font-size: 15px; line-height: 1.35; min-height: 44px; }
.map-r:first-child { border-top: 0; }
.map-r.muted { color: var(--muted); }
.map-box { position: relative; flex: 1; min-height: 200px; }
#lmap { position: absolute; inset: 0; }
.map-load { position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); }
.map-foot { background: #fff; border-top: 1px solid var(--line); padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); }
.map-label { font-size: 14.5px; line-height: 1.35; margin-bottom: 8px; overflow-wrap: anywhere; }
.pin-me span { display: block; width: 30px; height: 30px; margin: 0 auto; background: var(--green); border: 3px solid #fff; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); box-shadow: 0 2px 6px rgba(0,0,0,.4); }
.pin-store span { display: block; background: var(--yellow); color: var(--green); font-size: 11.5px; font-weight: 700; line-height: 18px; text-align: center; border-radius: 11px; border: 2px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,.35); }

/* ---- 15/11 đợt 2: gọi quán ở trang chủ, ô "Giao tới đâu?", mã đơn, Tìm đơn của bạn ---- */
.addr-field { position: relative; }
.addr-sug { margin-top: 6px; border: 1px solid var(--line); border-radius: 12px; background: #fff; overflow: hidden; box-shadow: 0 6px 18px rgba(0,0,0,.08); }
.sug-r { display: flex; gap: 6px; align-items: flex-start; width: 100%; min-height: 48px; padding: 10px 12px; border: 0; border-bottom: 1px solid var(--line); background: #fff; text-align: left; font: inherit; font-size: 15.5px; line-height: 1.35; color: inherit; cursor: pointer; }
.sug-r:last-child { border-bottom: 0; }
.sug-r:active, .sug-r:hover { background: var(--green-soft); }
.sug-r.muted { color: var(--muted); cursor: default; }
.sug-r.map { color: var(--green); font-weight: 600; align-items: center; }
.loc-box .loc-btns { margin-top: 8px; }
.code-card { text-align: center; }
.code-card .code-lbl { font-size: 14px; color: var(--muted); }
.big-code { font-size: 26px; font-weight: 800; letter-spacing: .5px; margin: 2px 0 6px; user-select: all; -webkit-user-select: all; }
.code-hint { font-size: 14px; color: var(--muted); line-height: 1.4; margin-bottom: 10px; }
.code-card .btn { min-height: 48px; }
.copy-box { margin-top: 8px; }
.copy-box input { width: 100%; border: 1px dashed var(--line); border-radius: 10px; padding: 10px; font-size: 14px; background: #fafafa; }
.lk-toggle { display: block; width: calc(100% - 28px); margin: 12px 14px 0; min-height: 48px; border: 1px dashed var(--line); border-radius: 12px; background: #fff; font: inherit; font-size: 15px; font-weight: 600; color: var(--green); cursor: pointer; }
.lookup .lk-hint { font-size: 14.5px; color: var(--muted); line-height: 1.45; margin-bottom: 10px; }
.lookup .btn { min-height: 48px; margin-top: 4px; }
.lookup .err { margin: 0 0 8px; }
.lk-top { margin: 12px 14px 0; }
.order-card .who { font-size: 14px; color: var(--muted); }

/* ---- 15/11: hàng nút dưới thông tin quán (Đặt đơn nhóm · Hẹn giờ giao · Chia sẻ) ---- */
.store-acts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; margin-top: 10px; }
.store-acts a { text-decoration: none; -webkit-tap-highlight-color: transparent; }
.store-acts button, .store-acts a { min-height: 58px; border: 1px solid var(--line); background: #fff; border-radius: 12px; color: var(--green); font-weight: 700; font-size: 13.5px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 6px 2px; line-height: 1.2; text-align: center; }
.store-acts > * > span:last-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; font-size: 14px; }
.store-acts .ic { position: relative; display: inline-flex; }
.store-acts .dot { position: absolute; top: -2px; right: -4px; width: 9px; height: 9px; border-radius: 50%; background: #d93025; box-shadow: 0 0 0 2px #fff; }
.store-acts .dot[hidden] { display: none; }
.store-acts a:focus-visible, .store-acts button:focus-visible { outline: 3px solid var(--yellow); outline-offset: 1px; }
.store-acts button.on { background: var(--green-soft); border-color: var(--green); }
.store-acts button:active, .store-acts a:active { background: var(--green-soft); }
@media (max-width: 340px) { .store-acts { gap: 4px; } .store-acts button, .store-acts a { padding: 6px 1px; } .store-acts > * > span:last-child { font-size: 11.5px; letter-spacing: -0.1px; } }
.grp-banner { margin: 10px 14px 0; background: var(--yellow-soft); border: 1px solid #f3dc97; border-radius: 12px; padding: 10px 12px; font-size: 14.5px; color: var(--ink); }
.gb-acts { display: flex; gap: 18px; margin-top: 6px; align-items: center; }
.gb-acts a { color: var(--green); font-weight: 700; }
.gb-acts a, .gb-acts .linkbtn { min-height: 32px; display: inline-flex; align-items: center; }

/* ---- Ưu đãi hôm nay ---- */
.promos h3, .foryou h3 { margin: 0; font-size: 16px; }
.pr-row { display: flex; gap: 10px; overflow-x: auto; padding: 8px 0 4px; scrollbar-width: none; }
.pr-row::-webkit-scrollbar { display: none; }
.pchip { display: inline-block; align-self: flex-start; font-size: 11.5px; font-weight: 700; color: #9a3b12; background: #fde9dc; border-radius: 6px; padding: 2px 6px; margin-top: 4px; }
.pchip.flash { color: #fff; background: #c2410c; }
.pchip .cd, .pr-until .cd { font-variant-numeric: tabular-nums; }
.price.promo { display: inline-flex; align-items: baseline; gap: 6px; }
.price.promo s { font-weight: 500; font-size: 13.5px; color: var(--muted); }
.cartbar .sum s { font-weight: 500; opacity: .7; margin-right: 6px; font-size: 14px; }

/* ---- Dành cho bạn ---- */
.foryou { margin: 14px 0 0; }
.fy-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; padding: 0 14px; }
.fy-head .sub { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.fy-again { flex: none; padding: 8px 12px; font-size: 14px; min-height: 40px; }

/* ---- Nhắc ưu đãi trên nút giỏ hàng ---- */
.promo-bar, .nprog { position: fixed; left: 50%; transform: translateX(-50%); width: calc(100% - 24px); max-width: 456px; z-index: 39; bottom: calc(76px + env(safe-area-inset-bottom)); border-radius: 12px; }
.promo-bar { background: var(--yellow-soft); border: 1px solid #f3dc97; color: var(--ink); font-size: 14px; padding: 8px 12px; text-align: center; }
.promo-bar.done { background: var(--green-soft); border-color: #bcd6c7; color: var(--green); }
.nprog { background: #fff; box-shadow: 0 6px 18px rgba(0,0,0,.18); padding: 10px 12px; z-index: 41; animation: fade .15s; }
.np-top { display: flex; align-items: center; justify-content: space-between; font-size: 15px; }
.np-x { border: 0; background: none; font-size: 16px; color: var(--muted); min-width: 36px; min-height: 36px; }
.np-slots { display: flex; gap: 6px; margin: 4px 0 6px; flex-wrap: wrap; }
.np-slots span { width: 28px; height: 28px; border-radius: 50%; border: 1.5px dashed #c9c2b2; color: var(--muted); font-size: 12.5px; font-weight: 700; display: grid; place-items: center; }
.np-slots span.on { border: 0; background: var(--green); color: #fff; }
.np-txt { font-size: 14px; }
.nprog.done .np-txt { color: var(--green); }
html.kb-open .promo-bar, html.kb-open .nprog { display: none; }
.sumrow.disc span:last-child, .kv.disc span:last-child { color: var(--ok); font-weight: 700; }
.promo-hint { font-size: 14px; background: var(--yellow-soft); border-radius: 10px; padding: 8px 10px; margin: 6px 0; display: grid; gap: 4px; }

/* ---- Bảng nhỏ trượt từ đáy ---- */
.psheet { background: #fff; width: 100%; max-width: 480px; max-height: 86vh; display: flex; flex-direction: column; border-radius: 20px 20px 0 0; animation: up .2s ease-out; padding: 6px 16px calc(16px + env(safe-area-inset-bottom)); }
.ps-top { display: flex; align-items: center; justify-content: space-between; padding: 8px 0; font-size: 16px; }
.ps-x { border: 0; background: none; font-size: 18px; min-width: 44px; min-height: 44px; color: var(--muted); }
.ps-body { overflow-y: auto; }
.ps-list { max-height: 46vh; overflow-y: auto; border-top: 1px solid var(--line); }
.ps-hint { font-size: 13.5px; color: var(--muted); margin: 8px 0; line-height: 1.4; }

/* ---- Trang đơn nhóm ---- */
.grp-head h3 { margin-bottom: 4px; }
.grp-st { font-size: 15px; }
.grp-sub { font-size: 13.5px; color: var(--muted); margin-top: 4px; }
.grp-qr { width: 190px; height: 190px; margin: 4px auto 6px; background: #fff; }
.grp-qr svg { width: 100%; height: 100%; display: block; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; }
.grp-unsaved { margin: 12px 14px; }
.gm { border-top: 1px solid var(--line); padding: 10px 0; }
.gm:first-of-type { border-top: 0; }
.gm.me { background: #fbfdfb; }
.gm-h { display: flex; align-items: center; gap: 6px; font-size: 15px; }
.gm-l { display: flex; justify-content: space-between; gap: 10px; font-size: 14px; padding: 3px 0 0 2px; }
.gm-l small { color: var(--muted); }
.gm-l.bad { color: var(--muted); text-decoration: line-through; }
.gm-l.bad small.err { text-decoration: none; display: inline; }
.gm-l.muted { color: var(--muted); }

/* ---------- Ưu đãi tự lấy (nhãn cạnh nút Tự đến lấy) & mã giảm giá ở giỏ hàng ---------- */
.mode-tag { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px; background: var(--danger); color: #fff; font-size: 12.5px; font-weight: 700; line-height: 18px; vertical-align: 1px; white-space: nowrap; }
.seg button.on .mode-tag { background: var(--green); color: var(--yellow); }
.cp-row { display: flex; gap: 8px; }
.cp-row input { flex: 1; min-width: 0; min-height: 44px; border: 1px solid var(--line); border-radius: 10px; padding: 0 12px; text-transform: uppercase; letter-spacing: .5px; background: #fff; }
.cp-row .btn { flex: none; }
.cp-on { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.cp-code { font-weight: 800; letter-spacing: .5px; border: 1.5px dashed var(--green); color: var(--green); border-radius: 8px; padding: 4px 10px; background: var(--green-soft); }
.cp-st { font-size: 14px; color: #8a5a00; }
.cp-st.ok { color: var(--ok); font-weight: 700; }
.cp-on .linkbtn { min-height: 44px; }

/* Thẻ món ưu đãi: ảnh thật bên trái, chữ Hán rõ, điều khiển nằm dưới cột chữ. */
.deal-count { color: var(--muted); font-size: 14px; font-weight: 500; }
.pr-row { scroll-snap-type: x proximity; }
.item.deal-card { flex: 0 0 315px; max-width: calc(100vw - 48px); padding: 10px; gap: 10px; border: 1px solid var(--line); border-radius: 14px; background: #fff; scroll-snap-align: start; align-items: flex-start; }
.item.deal-card .pic, .item.deal-card .pic img { width: 104px; height: 104px; }
.item.deal-card .pic { flex: 0 0 104px; }
.item.deal-card .pic img { object-fit: contain; border-radius: 10px; }
.item.deal-card .txt { min-width: 0; flex: 1; }
.item.deal-card .name { font-size: 15px; line-height: 1.35; margin-top: 4px; }
.item.deal-card .zh { font-size: 15px; color: var(--ink); line-height: 1.4; white-space: normal; overflow: visible; }
.item.deal-card .pchip { margin-top: 0; }
.item.deal-card .price { font-size: 15px; flex-wrap: wrap; margin-top: 6px; }
.deal-controls { display: flex; justify-content: flex-end; margin-top: 6px; }
#store-hotline, #call-store { min-height: 44px; }

#receive-scheduled label { display: block; line-height: 1.5; }
#receive-scheduled select { display: block; width: 100%; min-height: 44px; border: 1px solid var(--line); border-radius: 8px; padding: 8px; background: white; color: var(--ink); font: inherit; }
.schedule-confirm { margin-top: 8px; font-weight: 700; color: var(--green); }
/* Tự đến lấy trong giờ: Lấy ngay / Hẹn giờ đến lấy (15/11) — mỗi lựa chọn và ô chọn giờ cao ≥ 44px */
#receive-pick .radio-row { min-height: 48px; cursor: pointer; }
#receive-pick #receive-scheduled { margin: 2px 0 4px 30px; }
#receive-pick #receive-scheduled select { min-height: 48px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ---------- Nhãn trên góc ảnh món (15/11) ---------- */
/* Viên bo tròn nhỏ, chữ trắng đậm trên nền đặc, nằm góc trên-trái ảnh. Màu theo bảng TAWA (cam đậm đạt tương phản 4,5:1 với chữ trắng). */
.item .pic, .sheet-pic { position: relative; }
.ibadge { position: absolute; top: 4px; left: 4px; z-index: 2; max-width: calc(100% - 8px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-size: 11px; line-height: 14px; font-weight: 800; letter-spacing: .1px; padding: 1px 6px; border-radius: 999px; color: #fff; background: #c9501a;
  box-shadow: 0 0 0 1.5px rgba(255, 255, 255, .92), 0 1px 3px rgba(0, 0, 0, .25); pointer-events: none; }
.ibadge.c-red { background: #b3261e; }
.ibadge.c-green { background: var(--green); }
.ibadge.c-yellow { background: var(--yellow); color: var(--green); }
.sheet-pic .ibadge { top: 12px; left: 12px; font-size: 12.5px; line-height: 16px; padding: 3px 10px; max-width: calc(100% - 90px); }
.item.off .ibadge, .sheet-pic.off .ibadge { filter: grayscale(1); opacity: .55; }
/* Hotline chân trang (15/11): chữ nhỏ như .foot, chỉ nới vùng bấm. */
.foot #foot-hotline { display: inline-block; padding: 6px 4px; font-weight: 600; text-decoration: none; }

/* ---- Flash sale (15/11): khối riêng dưới ô tìm kiếm, trên "Ưu đãi hôm nay". Màu cam/đỏ chỉ cho khối này. ---- */
.flash { margin: 12px 14px 0; background: #fff; border: 1px solid #fed7c3; border-radius: 14px; padding: 8px 10px 2px; }
.fl-head { display: flex; align-items: center; gap: 8px; min-height: 36px; }
.fl-title { margin: 0; font-size: 17px; font-weight: 900; font-style: italic; letter-spacing: .2px; color: #e03b12; white-space: nowrap; }
.cdbox { display: inline-flex; align-items: center; gap: 2px; font-variant-numeric: tabular-nums; }
.cdbox b { min-width: 24px; height: 22px; padding: 0 3px; display: inline-grid; place-items: center; background: #1d2420; color: #fff; border-radius: 5px; font-size: 14px; font-weight: 700; }
.cdbox i { font-style: normal; font-weight: 800; color: #1d2420; font-size: 14px; }
.fl-more { margin-left: auto; border: 0; background: none; color: #e03b12; font-weight: 700; font-size: 14.5px; min-height: 44px; padding: 0 2px 0 8px; white-space: nowrap; }
.fl-list { display: grid; }
.item.fl-card { gap: 10px; padding: 10px 0; align-items: stretch; }
.fl-list .item.fl-card:last-child { border-bottom: 0; }
.item.fl-card .pic { position: relative; width: 88px; height: 88px; align-self: flex-start; }
.item.fl-card .pic img { width: 88px; height: 88px; }
/* Nhãn -X% góc trên-PHẢI ảnh; nhãn món (Bán chạy, tự gõ…) trong thẻ flash xuống góc dưới-trái nên hai nhãn không đè nhau */
.fl-off { position: absolute; top: 4px; right: 4px; z-index: 2; background: #fff3c4; color: #c81e1e; font-size: 11.5px; font-weight: 800; line-height: 15px; padding: 1px 5px; border-radius: 6px; box-shadow: 0 0 0 1px rgba(200, 30, 30, .18); pointer-events: none; }
.item.fl-card .ibadge { top: auto; bottom: 4px; max-width: calc(100% - 8px); } /* ảnh flash 76–88px không đủ chỗ cho 2 nhãn cùng hàng trên: nhãn món xuống góc dưới-trái, -X% giữ góc trên-phải */
.item.fl-card .name { font-size: 15.5px; -webkit-line-clamp: 1; }
.item.fl-card .desc { -webkit-line-clamp: 1; margin-top: 1px; font-size: 12.5px; }
.fl-left { font-size: 12.5px; font-weight: 700; color: #c81e1e; margin-top: 2px; }
.fl-buy { display: flex; align-items: flex-end; justify-content: space-between; gap: 6px; margin-top: auto; }
.fl-price { display: flex; flex-direction: column; line-height: 1.15; min-width: 0; padding-top: 2px; }
.fl-price s { font-size: 12.5px; color: var(--muted); }
.fl-price b { font-size: 17px; font-weight: 800; color: #d62d0f; white-space: nowrap; }
.fl-price b.reg { font-size: 15px; color: var(--muted); }
.fl-gone { font-size: 13.5px; font-weight: 800; color: #6b726d; }
.item.fl-card .ctl { margin-right: -7px; margin-bottom: -6px; }
.item.fl-card .add i, .item.fl-card .ictl [data-plus] i { background: #ee5a1f; }
.item.fl-card .ictl [data-minus] i { color: #c2410c; border-color: #ee5a1f; }
.fl-bar { position: relative; height: 18px; border-radius: 999px; background: #ffe6d5; overflow: hidden; margin-top: 6px; }
.fl-bar i { position: absolute; inset: 0 auto 0 0; background: linear-gradient(90deg, #fdba74, #fb923c); border-radius: 999px; }
.fl-bar span { position: relative; display: block; text-align: center; font-size: 11.5px; line-height: 18px; font-weight: 800; letter-spacing: .3px; color: #7c2d12; }
.fl-bar.open i { background: #fed7aa; }
.fl-bar.low { background: #fee2e2; }
.fl-bar.low i { background: linear-gradient(90deg, #fca5a5, #f87171); }
.fl-bar.low span { color: #7f1d1d; }
.fl-bar.gone { background: #e5e7eb; }
.fl-bar.gone i { background: #d1d5db; }
.fl-bar.gone span { color: #4b5563; }
.item.fl-card.gone .pic, .item.fl-card.gone .name, .item.fl-card.gone .desc { opacity: .5; }
.item.fl-card.gone .pic img { filter: grayscale(.6); }
.fl-sheet .fl-head { margin-bottom: 2px; }
.fl-list.in-sheet { border-top: 1px solid var(--line); }
/* Máy 360–380px (Redmi, Galaxy A): thu gọn hàng tiêu đề để "Xem thêm ›" không sát mép */
@media (max-width: 380px) {
  .fl-head { gap: 6px; }
  .fl-title { font-size: 16px; letter-spacing: 0; }
  .cdbox b { min-width: 22px; padding: 0 2px; }
  .fl-more { font-size: 14px; padding-left: 2px; }
}
@media (max-width: 340px) {
  .flash { padding: 8px 8px 2px; }
  .fl-head { gap: 5px; }
  .fl-title { font-size: 15px; }
  .cdbox b { min-width: 20px; font-size: 12.5px; }
  .fl-more { font-size: 13.5px; }
  .item.fl-card .pic, .item.fl-card .pic img { width: 76px; height: 76px; }
  .item.fl-card .pic img { height: 76px; }
  .fl-price b { font-size: 15.5px; }
}

/* Dòng "X đã bán | Y lượt thích" dưới mô tả món (15/11 21:49) */
/* 18/11 08:54 (đính chính 08:56: giữ dấu "|"): dòng "đã bán | lượt thích" nâu vàng ấm (#8a6d1c, đúng tông NÊN MUA/.soldout; 4.58:1 trên kem, 4.9:1 trên trắng, đạt AA), đậm 600, không lớn hơn mô tả */
.item .istat { font-size: 12.5px; font-weight: 600; color: #8a6d1c; line-height: 1.3; margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item.fl-card .istat { font-size: 12.5px; margin-top: 2px; }
.item.fl-card.gone .istat { opacity: .5; }

/* ---- Dòng ưu đãi cấp đơn dưới hàng 3 nút (15/11): thẻ ngang, thẻ cuối ló ra để khách biết còn ---- */
.ostrip { display: flex; gap: 8px; overflow-x: auto; padding: 10px 14px 2px; scroll-padding-inline: 14px; scrollbar-width: none; overscroll-behavior-x: contain; } /* 16/11 QA-PERF-003: bỏ snap, vuốt theo tay */
.ostrip::-webkit-scrollbar { display: none; }
/* 16/11: bề rộng thẻ theo % khung (không theo vw): 2 thẻ trọn + ~30% thẻ thứ 3 ở mọi bề rộng (khung tối đa 480px). */
.ostrip .oc { flex: 0 0 auto; width: calc((100% - 2px) / 2.3); min-width: 0; min-height: 56px; display: flex; align-items: center; gap: 7px; padding: 8px 8px 8px 7px; text-align: left;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; color: var(--ink); scroll-snap-align: start; -webkit-tap-highlight-color: transparent; }
.ostrip.few .oc { flex: 1 1 0; width: auto; }
.ostrip .oc:active { background: var(--green-soft); }
.ostrip .oc:focus-visible { outline: 3px solid var(--yellow); outline-offset: 1px; }
.oc-ic { flex: none; width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; background: var(--green-soft); color: var(--green); }
/* Màu icon theo loại ưu đãi (kiểu Grab), nền nhạt cùng tông */
.oc-ic.ic-ship { color: #1d8a4e; background: #e2f3e8; }
.oc-ic.ic-tag { color: #e06d0b; background: #fdeedc; }
.oc-ic.ic-ticket { color: #dc4a2c; background: #fde6e0; }
.oc-ic.ic-clock { color: #2b6bd0; background: #e4edfb; }
.oc-ic.ic-stack { color: #7a4cc9; background: #eee7fa; }
.oc-ic.ic-bag { color: #b57a00; background: #fcf0cf; }
.oc-ic.ic-group { color: #d23f7c; background: #fce5ee; }
.oc-t { min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.oc-t b, .oc-t small { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; overflow-wrap: anywhere; }
.oc-t b { font-size: 14px; }
.oc-t small { font-size: 12.5px; color: var(--muted); margin-top: 1px; }
.oc-sheet { padding-bottom: 4px; }
.oc-sh-top { display: flex; align-items: center; gap: 10px; font-size: 17px; }
.oc-cond { margin: 10px 0 14px; padding-left: 18px; font-size: 15px; line-height: 1.5; }
.oc-cond li + li { margin-top: 4px; color: var(--muted); font-size: 14px; }

/* ---- Tiêu đề khối có nút → (Ưu đãi hôm nay, Mọi người nhận xét) ---- */
.dg-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.dg-head h3 { margin: 0; font-size: 16px; }
.dg-arrow { flex: none; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); background: #fff; color: var(--green); font-size: 18px; font-weight: 700;
  display: grid; place-items: center; text-decoration: none; line-height: 1; }

/* ---- Mockup C (16/11): "Ưu đãi hôm nay" một hàng ngang vuốt + "Dành cho bạn" lưới 2 cột, chung một kiểu thẻ ---- */
.promos { margin: 14px 0 0; }
.promos .dg-head { padding: 0 14px; }
.mgrid { display: grid; gap: 14px 10px; padding: 8px 14px 4px; }
.mgrid.one { grid-auto-flow: column; grid-auto-columns: 146px; overflow-x: auto; overscroll-behavior-x: contain; scroll-padding: 0 14px; scrollbar-width: none; }
.mgrid.one::-webkit-scrollbar { display: none; }
.mgrid.fx { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.mgrid.in-sheet { padding: 4px 0 8px; }
.item.mc { display: flex; flex-direction: column; gap: 0; padding: 0; border: 0; border-radius: 0; background: transparent; min-width: 0; max-width: none; scroll-snap-align: start; }
.item.mc .pic { position: relative; width: 100%; flex: none; aspect-ratio: 1 / 1; }
.item.mc .pic img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 14px; background: var(--cream); }
.item.mc .ibadge { top: 6px; left: 6px; max-width: calc(100% - 58px); }
.mc-off { position: absolute; top: 6px; right: 6px; z-index: 2; background: var(--danger); color: #fff; font-size: 11.5px; font-weight: 800; line-height: 15px; padding: 1px 5px; border-radius: 6px; pointer-events: none; }
.item.mc .ctl { position: absolute; right: 0; bottom: 0; z-index: 2; margin: 0; }
.item.mc .add i { background: var(--green); box-shadow: 0 0 0 2px #fff, 0 1px 4px rgba(0, 0, 0, .25); }
.item.mc .ictl { background: #fff; border-radius: 999px; margin: 0 4px 4px 0; box-shadow: 0 1px 4px rgba(0, 0, 0, .2); }
.item.mc .ictl button { width: 36px; height: 36px; }
.item.mc .ictl b { min-width: 18px; }
.item.mc .soldout { background: #fff; border-radius: 8px; padding: 2px 6px; margin: 0 6px 6px 0; display: inline-block; }
.item.mc .name { font-size: 14.5px; line-height: 1.3; margin-top: 6px; min-height: 2.6em; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.mc-price { display: flex; flex-wrap: wrap; align-items: center; gap: 0 5px; margin-top: 2px; }
.mc-price b { font-size: 15.5px; color: var(--ink); font-weight: 800; }
.mc-price s { font-size: 12.5px; color: var(--muted); }
.mc-tag { flex: none; color: #c9501a; }
.foryou .mgrid.fx { padding-top: 8px; }
.dg-sheet .ps-body { overflow-x: hidden; }

/* ---- Dòng sao cạnh tên quán (15/11) ---- */
.si-title { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 10px; margin-bottom: 2px; }
.si-title h1 { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.srating { display: inline-flex; align-items: center; gap: 4px; min-height: 32px; padding: 0 2px; font-size: 14.5px; color: var(--ink); text-decoration: none; white-space: nowrap; }
.srating b { color: #b7791f; font-weight: 800; }
.srating span { color: var(--muted); }
.srating i { font-style: normal; color: var(--muted); font-size: 16px; }

/* ---- "Mọi người nhận xét" (15/11) ---- */
.rv-block { margin: 8px 0 4px; padding: 4px 14px 2px; }
.rv-row { display: flex; align-items: flex-start; gap: 10px; overflow-x: auto; padding: 8px 14px 6px; margin: 0 -14px; scroll-padding-inline: 14px; scroll-snap-type: x proximity; scrollbar-width: none; overscroll-behavior-x: contain; }
.rv-row::-webkit-scrollbar { display: none; }
/* 20/11: thẻ cao theo nội dung (không kéo giãn theo thẻ cao nhất): sao + tên → chữ 2 dòng → ảnh nhỏ → nguồn · ngày */
.rv-card { flex: 0 0 auto; width: clamp(220px, 72vw, 280px); background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; scroll-snap-align: start;
  display: flex; flex-direction: column; gap: 4px; position: relative; }
.rv-go { position: absolute; inset: 0; border-radius: 12px; z-index: 0; }
.rv-go:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
.rv-card .rv-ph { pointer-events: none; } /* khe/khoảng trống hàng ảnh vẫn bấm trúng link thẻ */
.rv-card .rv-ph button { pointer-events: auto; z-index: 1; }
.rv-card.full { width: auto; content-visibility: auto; contain-intrinsic-size: auto 96px; }
.rv-more { height: 1px; }
.rv-top { display: flex; align-items: center; gap: 6px; font-size: 14px; min-width: 0; }
.rv-stars { color: #f2b01e; letter-spacing: 1px; font-size: 15px; flex: none; }
.rv-stars i { font-style: normal; color: #ddd; }
.rv-name { color: var(--muted); min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rv-text { font-size: 14.5px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; white-space: pre-line; }
.rv-card.full .rv-text { -webkit-line-clamp: unset; display: block; }
.rv-ph { display: flex; gap: 6px; min-width: 0; margin-top: 2px; }
.rv-ph button { position: relative; flex: 0 0 60px; width: 60px; height: 60px; min-width: 0; border: 0; padding: 0; background: var(--cream); border-radius: 8px; overflow: hidden; }
.rv-ph img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rv-ph-n { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: rgba(0, 0, 0, .5); color: #fff; font-weight: 700; font-size: 16px; }
.rv-meta { font-size: 12.5px; color: var(--muted); }
.rv-card.full .rv-ph button { flex-basis: 72px; width: 72px; height: 72px; }
.rv-chips { display: flex; gap: 8px; padding: 6px 14px 0; }
.rv-chip { min-height: 36px; display: inline-flex; align-items: center; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; background: #fff; color: var(--muted); font-weight: 600; font-size: 14.5px; text-decoration: none; }
.rv-chip.on { background: var(--green); border-color: var(--green); color: #fff; }
.rv-list { display: grid; gap: 10px; padding: 10px 14px; }
.rv-sum { display: flex; align-items: baseline; gap: 10px; }
.rv-sum b { font-size: 22px; color: #b7791f; }
.rv-sum span { color: var(--muted); }
.rv-lb { background: rgba(0, 0, 0, .88); touch-action: none; }
.rv-lb img { max-width: 94vw; max-height: 84vh; object-fit: contain; border-radius: 8px; transition: transform .12s ease-out; }
.rv-lb .ps-x { position: absolute; top: 10px; right: 10px; color: #fff; }
.rv-lb-n { position: absolute; top: 20px; left: 0; right: 0; text-align: center; color: #fff; font-size: 15px; pointer-events: none; }
.rv-lb-go { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 64px; border: 0; border-radius: 8px; background: rgba(0, 0, 0, .35); color: #fff; font-size: 28px; padding: 0; }
.rv-lb-go.prev { left: 6px; }
.rv-lb-go.next { right: 6px; }

/* ---- Form đánh giá + xu (15/11) ---- */
.rate-card { text-align: center; }
.rv-coin-hint { background: #fff8e1; border-radius: 10px; padding: 8px 10px; font-size: 14.5px; margin: 4px 0 10px; }
.rv-count { text-align: right; font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.rv-photos { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.rv-pv { position: relative; width: 72px; height: 72px; border-radius: 10px; overflow: hidden; background: var(--cream); }
.rv-pv img { width: 100%; height: 100%; object-fit: cover; }
.rv-pv .spin { position: absolute; inset: 0; margin: auto; }
.rv-pv button { position: absolute; top: 2px; right: 2px; width: 28px; height: 28px; border: 0; border-radius: 50%; background: rgba(0, 0, 0, .6); color: #fff; font-size: 14px; padding: 0; }
.rv-add { width: 72px; height: 72px; border: 1.5px dashed var(--line); border-radius: 10px; display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 12.5px; color: var(--green); font-weight: 600; cursor: pointer; line-height: 1.2; }
.rv-add small { color: var(--muted); font-weight: 500; }
.rv-earned { font-size: 14px; color: #8a5a00; font-weight: 600; margin-top: 6px; }
.coin-box { display: flex; align-items: center; gap: 10px; background: #fff8e1; }
.cb-ic { font-size: 24px; }
.cb-sub { font-size: 13.5px; color: var(--muted); margin-top: 2px; }
.rate-in-list { margin-top: 8px; min-height: 42px; }
@media (max-width: 340px) { .mgrid.fx { gap: 12px 8px; } .item.mc .name { font-size: 14px; } .srating { font-size: 13.5px; } }

/* ---- Thanh tab đáy + thanh giỏ gộp ưu đãi (18/11) ----
   --tb-h: chiều cao thanh tab (không tính vùng an toàn iPhone). --lift: thanh giỏ nhấc lên ngay trên thanh tab khi thanh tab đang hiện.
   --tier: phần cao thêm của thanh giỏ khi có dòng "Đặt thêm … để giảm …". Đáy màn hình tối đa 2 lớp: thanh giỏ + thanh tab. */
:root { --tb-h: 58px; --lift: 0px; --tier: 0px; }
html.tabs-on:not(.tb-hide):not(.kb-open) { --lift: calc(var(--tb-h) - 4px); }
html.cb-tier { --tier: 22px; }
.tabbar { display: none; }
html.tabs-on .tabbar { display: flex; position: fixed; left: 50%; bottom: 0; transform: translateX(-50%); width: 100%; max-width: 480px; min-height: var(--tb-h); z-index: 45;
  background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -2px 12px rgba(0,0,0,.06); padding: 3px 4px env(safe-area-inset-bottom); transition: transform .22s ease; will-change: transform; }
html.tabs-on.tb-hide .tabbar { transform: translate(-50%, 100%); }
.tabbar button { flex: 1; min-width: 0; min-height: 52px; background: none; border: 0; padding: 4px 0 2px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; color: var(--muted); font: inherit; font-size: 11.5px; font-weight: 600; -webkit-tap-highlight-color: transparent; }
.tabbar button.on { color: var(--green); font-weight: 800; }
.tabbar .ti { position: relative; display: block; height: 26px; }
.tabbar .te { font-size: 21px; line-height: 26px; filter: grayscale(.35); }
.tabbar button.on .te { filter: none; }
.tabbar .tl { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.tabbar .tdot { position: absolute; top: 1px; right: -6px; width: 9px; height: 9px; border-radius: 50%; background: #e53935; border: 1.5px solid #fff; }
.tabbar .tbadge { position: absolute; top: -3px; left: 15px; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 9px; background: #e53935; color: #fff; border: 1.5px solid #fff; font-size: 11px; font-weight: 800; line-height: 15px; text-align: center; font-style: normal; }
.tabbar .tdot[hidden], .tabbar .tbadge[hidden] { display: none; }
html.kb-open .tabbar { display: none; }
/* Thanh giỏ: luôn hiện; thanh tab hiện thì nhấc lên ngay trên, thanh tab thu thì hạ xuống đáy */
.cartbar { transition: transform .22s ease; }
html.tabs-on .cartbar { transform: translate(-50%, calc(-1 * var(--lift))); }
.cartbar.has-tier { flex-wrap: wrap; row-gap: 5px; padding-top: 9px; padding-bottom: 9px; }
.cartbar .cb-tier { order: 9; flex: 0 0 100%; font-size: 12.5px; font-weight: 500; line-height: 17px; text-align: left; background: rgba(255,255,255,.13); border-radius: 8px; padding: 2px 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cartbar .cb-tier b { color: var(--yellow); font-weight: 800; }
.cartbar .cb-tier.done { color: #d9f2e3; }
/* Bảng "mua đủ N món", thông báo nhỏ: luôn nằm trên thanh giỏ (đã tính dòng ưu đãi và thanh tab) */
.nprog { bottom: calc(76px + var(--tier) + var(--lift) + env(safe-area-inset-bottom)); transition: bottom .22s ease; }
html.tabs-on .toast { bottom: calc(90px + var(--tier) + var(--lift) + env(safe-area-inset-bottom)); }
/* Chừa chỗ đáy để món cuối menu / chân trang không bị thanh giỏ + thanh tab che */
html.tabs-on .app { padding-bottom: calc(96px + var(--tb-h) + 22px + env(safe-area-inset-bottom)); }
@media (max-width: 340px) { .tabbar button { font-size: 11.5px; } }

/* ---- Chữ nhỏ trang khách +1px (18/11/2026): chỗ chật sau khi tăng chữ ---- */
.mgrid.one { grid-auto-columns: 156px; } /* "Ưu đãi hôm nay": giá 15.5px + giá gạch + nhãn ưu đãi nằm 1 dòng (thẻ cũ 146px làm xuống dòng) */
.store-info .addr1 { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; } /* địa chỉ tối đa 2 dòng thay vì cắt "Hà …" */
@media (max-width: 380px) and (min-width: 341px) { .store-acts { gap: 4px; } .store-acts button, .store-acts a { padding: 6px 0; } } /* "Đặt đơn nhóm" 14px vừa nút ở 360px */

/* ---------- TICKET-373 (18/11/2026): phần đầu màn đơn kiểu "theo dõi đơn" (track.js) ---------- */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.trk { background: #fff; padding: 12px 16px 16px; border-radius: 0 0 22px 22px; box-shadow: var(--shadow); }
.trk-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.trk-top .icon-btn { background: var(--cream); color: var(--green); width: 40px; height: 40px; font-size: 20px; }
.trk-acts { display: flex; align-items: center; gap: 8px; }
.trk-help { display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; border-radius: 999px; background: var(--cream); color: var(--green); font-weight: 600; font-size: 14.5px; text-decoration: none; }
.trk-main { display: flex; align-items: center; gap: 12px; margin-top: 12px; }
.trk-txt { flex: 1; min-width: 0; }
.trk-mode { display: inline-block; font-size: 12.5px; font-weight: 600; color: var(--green); background: var(--green-soft); border-radius: 999px; padding: 2px 10px; }
.trk-wlabel { margin-top: 8px; font-size: 13.5px; color: var(--muted); }
.trk-window { font-size: 26px; line-height: 1.15; font-weight: 800; color: var(--ink); letter-spacing: -.3px; }
.trk-line { margin-top: 4px; font-size: 15px; color: var(--ink); }
.trk-ok { color: var(--ok); }
.trk-late { color: #b26a00; }
.trk-img { flex: none; width: 80px; height: 80px; border-radius: 50%; object-fit: cover; background: var(--cream); }
.trk-bar { display: flex; align-items: center; gap: 6px; margin-top: 14px; }
.trk-ic { flex: none; display: grid; place-items: center; width: 28px; height: 28px; }
.trk-ic svg { display: block; }
.trk-seg { position: relative; flex: 1; height: 6px; border-radius: 3px; background: #e7e2d7; overflow: hidden; }
.trk-seg i { position: absolute; inset: 0 auto 0 0; width: var(--f, 0%); background: var(--green); border-radius: 3px; transition: width .6s ease; }
.trk-seg.todo i { width: 0; }
.trk-seg.run i::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255,255,255,.55), transparent); transform: translateX(-100%); animation: trk-shine 1.8s ease-in-out infinite; }
@keyframes trk-shine { to { transform: translateX(100%); } }
.trk-sub { margin: 10px 0 0; font-size: 14px; color: var(--muted); }
.trk-hist-card summary { cursor: pointer; font-weight: 600; color: var(--green); padding: 2px 0 10px; }
.trk-hist-card details:not([open]) summary { padding-bottom: 6px; }
.tr-in { animation: trk-in .28s ease-out; }
@keyframes trk-in { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .tr-in { animation: none; } .trk-seg.run i::after { animation: none; display: none; } .trk-seg i { transition: none; } }

/* Footer pháp lý (19/11/2026, SPEC qa-evidence/2026-11-19/phap-ly-bct/SPEC.md): nằm NGOÀI #app nên không bị xoá khi vẽ lại màn.
   Vẽ đè lên vùng đệm trống dưới đáy .app và tự chừa đúng khoảng đệm đó, nên thanh giỏ/tab/nút đặt cố định không che chữ. */
:root { --app-pb: calc(96px + env(safe-area-inset-bottom)); }
html.tabs-on { --app-pb: calc(96px + var(--tb-h) + 22px + env(safe-area-inset-bottom)); }
.app, html.tabs-on .app { padding-bottom: var(--app-pb); }
/* LEGAL-FOOT:START (TICKET-518): footer chuẩn TMĐT 3 cột. Nền xanh thương hiệu (cùng tông thanh đầu trang), chữ sáng; huy hiệu BCT (PNG trong suốt) đặt thẳng lên nền, KHÔNG khung/viền/bóng. */
.legal-foot { position: relative; z-index: 1; max-width: 480px; margin: calc(-1 * var(--app-pb)) auto 0; padding: 28px 20px calc(80px + env(safe-area-inset-bottom));
  background: var(--green); color: rgba(255, 255, 255, .85); font-size: 13px; line-height: 1.6; overflow-wrap: anywhere; }
.legal-foot .lg-grid { display: grid; gap: 22px; align-items: start; }
.legal-foot p { margin: 0 0 4px; }
.legal-foot a { color: #fff; font-weight: 600; text-decoration: none; }
.legal-foot a:hover { text-decoration: underline; }
.legal-foot .lg-h { margin: 0 0 10px; font-size: 11.5px; line-height: 1.4; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--yellow); }
.legal-foot .lg-logo { display: block; width: 104px; height: 43px; margin: 0 0 8px; }
.legal-foot .lg-brand-name { margin: 0 0 6px; font-size: 17px; line-height: 1.3; font-weight: 800; color: #fff; }
.legal-foot .lg-intro { margin: 0 0 8px; }
.legal-foot .lg-name { font-weight: 700; color: #fff; }
.legal-foot .lg-links { display: none; flex-direction: column; padding-bottom: 6px; }
.legal-foot .lg-links a { display: block; padding: 12px 0; color: rgba(255, 255, 255, .92); font-weight: 500; }
.legal-foot .lg-pol { border-top: 1px solid rgba(255, 255, 255, .16); border-bottom: 1px solid rgba(255, 255, 255, .16); }
.legal-foot .lg-pol .lg-h { margin: 0; }
.legal-foot .lg-pol .lg-h label { display: flex; align-items: center; justify-content: space-between; min-height: 48px; cursor: pointer; }
.legal-foot .lg-pol .lg-h label::after { content: ""; width: 7px; height: 7px; margin-right: 4px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); transition: transform .2s; }
.legal-foot .lg-tg { position: absolute; width: 1px; height: 1px; margin: 0; opacity: 0; pointer-events: none; }
.legal-foot .lg-tg:checked ~ .lg-links { display: flex; }
.legal-foot .lg-tg:checked ~ .lg-h label::after { transform: rotate(-135deg); }
.legal-foot .lg-tg:focus-visible ~ .lg-h label { outline: 2px solid var(--yellow); outline-offset: 2px; }
.legal-foot .lg-bct:empty { display: none; }
.legal-foot .lg-bct { margin-top: 12px; }
.legal-foot .lg-bct a { display: inline-block; }
.legal-foot .lg-bct img { display: block; width: 150px; height: auto; aspect-ratio: 230 / 86; margin-left: calc(-11 / 230 * 150px); } /* PNG có lề trong suốt trái 11/230: bù để mép hình thẳng mép chữ */
.legal-foot .lg-bar { margin-top: 24px; padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, .16); font-size: 12px; color: rgba(255, 255, 255, .7); }
.legal-foot .lg-bar p { margin: 0; }
/* TICKET-520: dòng "Hệ thống N cơ sở" + link mở bảng (cột Thương hiệu & Liên hệ). Vùng chạm cao 44px. */
.legal-foot .lg-sys { margin: 10px 0 0; }
.legal-foot .lg-more-p { margin: 0; }
.legal-foot .lg-more { display: inline-flex; align-items: center; min-height: 44px; color: var(--yellow); font-weight: 700; }
.legal-foot .lg-more:hover { text-decoration: underline; }
.legal-foot .lg-more:focus-visible { outline: 2px solid #fff; outline-offset: 2px; border-radius: 4px; }
/* TICKET-520: bảng "Tất cả cơ sở" (JS thuần, app.js CO-SO). Điện thoại: bottom sheet cùng kiểu .psheet; máy tính (≥ 720px): hộp giữa màn hình 560px. Không dùng <dialog>/::backdrop (WebView 91). */
.cs-ov { position: fixed; top: 0; right: 0; bottom: 0; left: 0; z-index: 1000; display: flex; align-items: flex-end; justify-content: center; background: rgba(0, 0, 0, .5); animation: fade .15s; touch-action: none; }
/* Các lớp cố định dưới đáy (thanh tab z 45, giỏ 40, ưu đãi 39/41) KHÔNG hiện xuyên nền tối khi bảng mở; .cs-ov z 1000 > mọi lớp (cao nhất hiện có: bản đồ 95) */
html.cs-open .tabbar, html.cs-open .cartbar, html.cs-open .promo-bar, html.cs-open .nprog { visibility: hidden; }
.cs-sheet { display: flex; flex-direction: column; width: 100%; max-width: 480px; max-height: 85vh; background: #fff; color: var(--ink); border-radius: 20px 20px 0 0; box-shadow: 0 -8px 32px rgba(0, 0, 0, .22); animation: up .22s ease-out; outline: 0; overscroll-behavior: contain; touch-action: auto; }
.cs-head { flex: none; padding: 8px 8px 0 20px; touch-action: none; }
.cs-grip { display: block; width: 40px; height: 4px; margin: 0 auto 2px; border-radius: 2px; background: #d3ccbb; }
.cs-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.cs-t { margin: 0; font-size: 18px; line-height: 1.3; font-weight: 800; color: var(--green); }
.cs-x { flex: none; min-width: 44px; min-height: 44px; border: 0; border-radius: 50%; background: none; color: var(--muted); font-size: 28px; line-height: 1; cursor: pointer; }
.cs-x:hover { background: var(--green-soft); color: var(--green); }
.cs-list-wrap { flex: 1 1 auto; min-height: 0; overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; padding: 0 12px calc(16px + env(safe-area-inset-bottom)); }
.cs-g { margin: 14px 8px 6px; font-size: 12px; line-height: 1.4; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--green); }
.cs-list { list-style: none; margin: 0; padding: 0; }
.cs-item { position: relative; display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 8px; border-radius: 12px; color: var(--ink); text-decoration: none; }
.cs-item:hover { background: var(--green-soft); }
.cs-item:focus-visible, .cs-x:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
.cs-pin { flex: none; color: var(--green); }
.cs-txt { display: block; min-width: 0; overflow-wrap: anywhere; }
.cs-item b { margin-right: 8px; font-size: 15px; line-height: 1.4; font-weight: 700; }
.cs-tag { display: inline-block; padding: 2px 8px; border-radius: 999px; background: var(--yellow); color: var(--green); font-size: 11.5px; line-height: 1.4; font-style: normal; font-weight: 700; vertical-align: 1px; }
.cs-item small { display: block; margin-top: 2px; font-size: 13.5px; line-height: 1.4; color: #5a625d; }
.cs-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@keyframes cs-pop { from { opacity: 0; transform: scale(.97); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .cs-ov, .cs-sheet { animation: none; } }
@media (min-width: 720px) {
  html:not(.sub-page) body { padding-bottom: 0; }
  .legal-foot { max-width: none; margin-left: 0; margin-right: 0; padding: 40px 24px 24px; }
  .legal-foot .legal { max-width: 1040px; margin: 0 auto; }
  .legal-foot .lg-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, .95fr) minmax(0, 1.2fr); gap: 48px; }
  .legal-foot .lg-pol { border: 0; }
  .legal-foot .lg-tg { display: none; } /* nhóm Chính sách luôn mở: bỏ ô tích khỏi thứ tự Tab */
  .legal-foot .lg-pol .lg-h { margin-bottom: 10px; }
  .legal-foot .lg-pol .lg-h label { min-height: 0; cursor: default; pointer-events: none; }
  .legal-foot .lg-pol .lg-h label::after { display: none; }
  .legal-foot .lg-links { display: flex; padding-bottom: 0; }
  .legal-foot .lg-links a { padding: 2px 0; }
  .cs-ov { align-items: center; padding: 24px; }
  .cs-sheet { width: 560px; max-width: 100%; border-radius: 20px; box-shadow: 0 20px 60px rgba(0, 0, 0, .3); animation: cs-pop .18s ease-out; }
  .cs-grip { display: none; }
  .cs-head { padding: 14px 12px 0 24px; }
  .cs-list-wrap { padding: 0 16px 20px; }
}
/* LEGAL-FOOT:END */
/* 29/11: footer pháp lý CHỈ hiện ở trang chủ. Lớp sub-page do index.html (lúc mở trang) và route() trong app.js đặt. */
html.sub-page .legal-foot { display: none; }
/* Khung chờ trang chủ (29/11, sửa CLS): có sẵn trong index.html dưới banner, trang chủ vẽ xong là mất. Cao ít nhất 1 màn hình để
   footer pháp lý nằm dưới màn đầu trong lúc tải, không bị đẩy đi khi thực đơn hiện ra. Chỉ là khối màu: không ảnh, không chữ. */
.home-skel { min-height: 100vh; padding: 10px 14px 0; }
.home-skel i { display: block; margin-bottom: 10px; border-radius: var(--radius); }
.home-skel .sk-info { height: 272px; box-shadow: var(--shadow);
  background: linear-gradient(var(--line), var(--line)) 12px 14px / 72% 18px no-repeat, linear-gradient(var(--line), var(--line)) 12px 46px / 88% 12px no-repeat,
    linear-gradient(var(--line), var(--line)) 12px 68px / 56% 12px no-repeat, linear-gradient(var(--green-soft), var(--green-soft)) 12px 142px / calc(100% - 24px) 44px no-repeat, var(--card); }
.home-skel .sk-strip { height: 77px; border-radius: 12px; background: linear-gradient(90deg, var(--card) 0 42%, transparent 42% 45%, var(--card) 45% 87%, transparent 87% 90%, var(--card) 90%); }
.home-skel .sk-club { height: 56px; border-radius: 12px; background: var(--yellow-soft); }
.home-skel .sk-search { height: 44px; border-radius: 12px; background: var(--card); border: 1px solid var(--line); }
.home-skel .sk-card { height: 200px; background: linear-gradient(90deg, var(--card) 0 calc(50% - 5px), transparent calc(50% - 5px) calc(50% + 5px), var(--card) calc(50% + 5px)); }
.consent { margin: 10px 2px 0; font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.consent a { color: var(--green); }

/* ---------- TAWA CLUB (29/11): lối vào ở trang chủ + trang giới thiệu #/tawa-club, chỉ hiển thị (tawa-club.js) ----------
   Icon là file SVG trong icons/club/, tô theo màu chữ (currentColor) bằng mask. */
.club-ic { flex: none; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--green-soft); color: var(--green); }
.club-ic::before { content: ""; width: 24px; height: 24px; background: currentColor; -webkit-mask: var(--m) center / contain no-repeat; mask: var(--m) center / contain no-repeat; }
.club-ic.i-gift { --m: url(/icons/club/gift.svg); }
.club-ic.i-tag { --m: url(/icons/club/tag.svg); }
.club-ic.i-coins { --m: url(/icons/club/coins.svg); }
.club-ic.i-truck { --m: url(/icons/club/truck.svg); }
.club-ic.i-utensils { --m: url(/icons/club/utensils.svg); }
.club-entry { display: flex; align-items: center; gap: 10px; margin: 10px 14px 0; min-height: 56px; padding: 7px 14px 7px 8px; background: var(--yellow-soft); border: 1px solid #f3dc97; border-radius: 12px; color: var(--ink); text-decoration: none; }
.club-entry .club-ic { background: var(--green); color: var(--yellow); }
.club-entry-t { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.3; }
.club-entry-top { display: flex; align-items: center; flex-wrap: wrap; gap: 2px 8px; }
.club-entry-t b { font-size: 14.5px; color: var(--green); letter-spacing: .3px; }
.club-entry-t small { font-size: 13px; color: var(--muted); }
.club-entry > i { font-style: normal; font-size: 22px; font-weight: 700; color: var(--green); line-height: 1; }
.club-entry:focus-visible { outline: 3px solid var(--yellow); outline-offset: 1px; }
.club-soon { display: inline-block; padding: 1px 8px; border-radius: 999px; background: var(--yellow); color: var(--green); font-size: 11.5px; font-weight: 800; white-space: nowrap; }
.club-hero { margin: 12px 14px 0; padding: 20px 18px 18px; background: var(--green); color: #fff; border-radius: var(--radius); box-shadow: var(--shadow); }
.club-tags { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.club-label { color: var(--yellow); font-size: 14px; font-weight: 800; letter-spacing: 1px; }
.club-hero .club-soon { font-size: 12.5px; padding: 3px 10px; }
.club-hero h1 { margin: 12px 0 6px; font-size: 28px; line-height: 1.2; font-weight: 800; }
.club-hero p { margin: 0; font-size: 15.5px; line-height: 1.45; color: #fbf7ee; }
.club-site { margin-top: 12px; font-size: 13px; color: #cfe0d5; }
.club-list { list-style: none; margin: 12px 14px 0; padding: 0 14px; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); }
.club-list li { display: flex; gap: 12px; align-items: flex-start; padding: 14px 0; border-top: 1px solid var(--line); }
.club-list li:first-child { border-top: 0; }
.club-list h2 { margin: 0 0 2px; font-size: 16px; line-height: 1.35; }
.club-list p { margin: 0; font-size: 13.5px; line-height: 1.45; color: var(--muted); }
/* Dòng hạn xu (TICKET-488) vẽ sau khi tải xong menu: cao TRÒN px để đẩy các mục dưới đúng số nguyên. Cao lẻ (19,575px) thì Chrome đo mục dưới cao hơn 1px, tính lại LCP: mobile 2,4s → 4,1s */
.club-list p + p { line-height: 20px; }
.club-note { margin: 14px 24px 0; text-align: center; font-size: 13px; line-height: 1.45; color: var(--muted); }

/* Nhiều cơ sở (29/11, Đợt 1): thanh + bảng chọn quán. Chỉ vẽ khi máy chủ báo ≥ 2 quán đang mở (mới 1 quán: không có phần tử nào) */
.branch-bar { display: flex; align-items: center; gap: 6px; font-size: 14px; margin: 0 0 2px; }
.branch-bar .bb-t { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.branch-bar .bb-btn { flex: none; border: 1px solid var(--green); background: #fff; color: var(--green); border-radius: 999px; padding: 6px 12px; font-weight: 700; font-size: 13.5px; min-height: 40px; }
.branch-bar .bb-btn:disabled { opacity: .55; cursor: not-allowed; }
.bb-sub { font-size: 12.5px; color: var(--muted); margin: 0 0 6px 22px; }
.bb-thu { color: #8a5a00; font-weight: 700; }
.bp-f { display: flex; gap: 8px; margin: 10px 0 6px; }
.bp-f input { flex: 1; min-width: 0; border: 1px solid #d9cfbd; border-radius: 12px; padding: 10px 12px; background: #fff; }
.bp-res { display: grid; gap: 6px; }
.bp-addr { text-align: left; background: #fff; border: 1px solid #e5dccb; border-radius: 10px; padding: 10px 12px; font-size: 14px; min-height: 44px; }
.bp-msg { font-size: 14px; margin: 8px 0; line-height: 1.45; }
.bp-msg .row, .bd-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.bp-act { text-decoration: none; display: inline-flex; align-items: center; }
.bp-row { display: flex; gap: 10px; align-items: center; padding: 10px 0; border-top: 1px solid #eee3cf; }
.bp-row.on b { color: var(--green); }
.bp-sub { font-size: 13px; color: var(--muted); margin-top: 2px; }
.bp-tag { background: var(--yellow); color: var(--green); border-radius: 999px; padding: 1px 8px; font-size: 12px; font-weight: 700; }
.bp-st { font-weight: 700; color: var(--danger); }
.bp-st.st-open { color: var(--ok); }
.bd-note { font-size: 14px; margin: 4px 0 6px; }
.bd-row { display: flex; justify-content: space-between; gap: 10px; padding: 8px 0; border-top: 1px solid #eee3cf; font-size: 14px; }
.bd-row span:last-child { text-align: right; }
.bd-out span:last-child { color: var(--danger); }
.bd-acts .btn { flex: 1 1 140px; }
