/* Quảng Bình Ơi — giao diện khách hàng (mobile-first).
   Màu và bo góc đặt ở biến CSS bên dưới để chủ quán đổi khi có bộ nhận diện thương hiệu. */

:root {
  --c-brand: #b84f0a;
  --c-brand-dark: #8f3b05;
  --c-brand-soft: #fff1e0;
  --c-bg: #faf7f2;
  --c-surface: #ffffff;
  --c-text: #2b2420;
  --c-muted: #6f655d;
  --c-line: #e8e0d6;
  --c-ok: #2f7d4a;
  --c-ok-bg: #e7f4ec;
  --c-warn: #8a5a00;
  --c-warn-bg: #fff4d6;
  --c-danger: #b42318;
  --c-danger-bg: #fdecea;
  --c-info-bg: #eef3f8;
  --c-info: #274a6b;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 3px rgba(43, 36, 32, .08), 0 4px 14px rgba(43, 36, 32, .06);
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --tap: 44px;
  --cartbar-h: 68px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 120px; }
body {
  margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.5;
  color: var(--c-text); background: var(--c-bg); overflow-x: hidden;
  min-height: 100vh; display: flex; flex-direction: column;
}
body.modal-open { overflow: hidden; }
img { max-width: 100%; height: auto; }
a { color: var(--c-brand-dark); }
h1, h2, h3 { line-height: 1.25; margin: 0 0 .5rem; }
h1 { font-size: 1.5rem; }
h2 { font-size: 1.2rem; }
h3 { font-size: 1.05rem; }
p { margin: 0 0 .75rem; }
ul { margin: 0; padding: 0; list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid #1b6ec2; outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.container { width: 100%; max-width: 980px; margin: 0 auto; padding: 0 16px; }
.container.narrow { max-width: 640px; }
.center { text-align: center; }
.muted { color: var(--c-muted); }
.small { font-size: .875rem; }
.mt { margin-top: 1rem; }
.nowrap { white-space: nowrap; }
main { flex: 1 0 auto; padding: 16px 0 32px; }
body.has-cartbar main { padding-bottom: calc(var(--cartbar-h) + 28px); }

/* ---------- Header ---------- */
.site-header { background: var(--c-surface); border-bottom: 1px solid var(--c-line); position: sticky; top: 0; z-index: 30; }
.site-header .container { display: flex; align-items: center; justify-content: space-between; min-height: 56px; gap: 12px; }
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: var(--tap); text-decoration: none; color: var(--c-brand-dark); font-weight: 800; font-size: 1.25rem; letter-spacing: .01em; }
.nav { display: flex; align-items: center; gap: 4px; }
.nav a { display: inline-flex; align-items: center; justify-content: center; min-height: var(--tap); padding: 0 12px; border-radius: var(--radius-sm); color: var(--c-text); text-decoration: none; font-weight: 600; }
.nav a:hover { background: var(--c-brand-soft); }
.cart-link { position: relative; gap: 6px; }
.cart-link svg { width: 24px; height: 24px; }
.cart-badge { position: absolute; top: 2px; right: 0; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; background: var(--c-brand); color: #fff; font-size: .75rem; font-weight: 700; line-height: 20px; text-align: center; }

/* ---------- Banner trạng thái quán ---------- */
.avail { border-bottom: 1px solid transparent; padding: 10px 0; font-size: .95rem; }
.avail .container { display: flex; gap: 10px; align-items: flex-start; }
.avail-dot { flex: 0 0 10px; height: 10px; border-radius: 50%; margin-top: 7px; background: currentColor; }
.avail strong { display: block; }
.avail--open { background: var(--c-ok-bg); color: var(--c-ok); border-color: #c5e3d0; }
.avail--partial { background: var(--c-warn-bg); color: var(--c-warn); border-color: #f1dfa6; }
.avail--closed { background: var(--c-danger-bg); color: var(--c-danger); border-color: #f4c7c2; }
.avail p { margin: 0; color: var(--c-text); }

/* ---------- Footer ---------- */
.site-footer { background: #2b2420; color: #e9e1d8; padding: 24px 0 28px; font-size: .95rem; }
.site-footer a { color: #f3d9c6; }
.site-footer h2 { font-size: 1rem; color: #fff; }
.footer-links { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-top: 12px; }
.footer-links a { display: inline-flex; align-items: center; min-height: var(--tap); }

/* ---------- Nút ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: var(--tap);
  padding: 8px 18px; border: 1px solid var(--c-line); border-radius: var(--radius-sm); background: var(--c-surface);
  color: var(--c-text); font-weight: 700; text-decoration: none; cursor: pointer; text-align: center; line-height: 1.25;
}
.btn:hover { border-color: var(--c-brand); }
.btn-primary { background: var(--c-brand); border-color: var(--c-brand); color: #fff; }
.btn-primary:hover { background: var(--c-brand-dark); border-color: var(--c-brand-dark); }
.btn-danger { background: var(--c-danger); border-color: var(--c-danger); color: #fff; }
.btn-danger:hover { background: #8f1c12; border-color: #8f1c12; }
.btn-outline-danger { background: #fff; border-color: var(--c-danger); color: var(--c-danger); }
.btn-outline-danger:hover { background: var(--c-danger-bg); border-color: var(--c-danger); }
.cancel-box > summary { list-style: none; cursor: pointer; }
.cancel-box > summary::-webkit-details-marker { display: none; }
.btn-block { display: flex; width: 100%; }
.btn-sm { min-height: 40px; padding: 4px 12px; font-size: .9rem; }
.btn-link { background: none; border: 0; color: var(--c-brand-dark); text-decoration: underline; padding: 8px 4px; min-height: var(--tap); cursor: pointer; font-weight: 600; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; pointer-events: none; }
.btn-primary[disabled], .btn-primary[aria-disabled="true"] { background: #8c7f75; border-color: #8c7f75; opacity: .75; }

/* ---------- Thẻ / khối ---------- */
.card { background: var(--c-surface); border: 1px solid var(--c-line); border-radius: var(--radius); padding: 16px; margin-bottom: 16px; box-shadow: var(--shadow); }
.card > :last-child { margin-bottom: 0; }
.card h2 { margin-bottom: .75rem; }
.alert { border-radius: var(--radius-sm); padding: 12px 14px; margin-bottom: 14px; border: 1px solid; }
.alert > :last-child { margin-bottom: 0; }
.alert-warn { background: var(--c-warn-bg); border-color: #f1dfa6; color: #5e3d00; }
.alert-danger { background: var(--c-danger-bg); border-color: #f4c7c2; color: #7a1a12; }
.alert-ok { background: var(--c-ok-bg); border-color: #c5e3d0; color: #1d4f2f; }
.alert-info { background: var(--c-info-bg); border-color: #cfdceb; color: var(--c-info); }
.alert ul { list-style: disc; padding-left: 20px; }
.alert-strong { border-width: 2px; font-weight: 600; }
.badge { display: inline-block; padding: 2px 10px; border-radius: 999px; background: var(--c-line); font-size: .8rem; font-weight: 700; }
.badge-off { background: #5b5148; color: #fff; }

/* ---------- Trang chủ ---------- */
.hero { padding: 20px 0 8px; }
.hero h1 { font-size: 1.75rem; color: var(--c-brand-dark); margin-bottom: .25rem; }
.hero p { color: var(--c-muted); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.methods { display: grid; gap: 12px; grid-template-columns: 1fr; margin: 12px 0 16px; }
.method { background: var(--c-surface); border: 2px solid var(--c-line); border-radius: var(--radius); padding: 16px; display: flex; gap: 12px; }
.method svg { flex: 0 0 32px; width: 32px; height: 32px; color: var(--c-brand); }
.method h2 { margin: 0 0 .25rem; font-size: 1.1rem; }
.method p { margin: 0; color: var(--c-muted); font-size: .95rem; }
.method.is-on { border-color: var(--c-brand); }
.method.is-off { opacity: .55; background: #f0ebe4; }
.method .state { margin-top: 6px; font-weight: 700; font-size: .9rem; }
.method.is-on .state { color: var(--c-ok); }
.method.is-off .state { color: var(--c-danger); }
.section-title { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin: 22px 0 10px; }
.section-title h2 { margin: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; min-height: var(--tap); padding: 0 16px; border: 1px solid var(--c-line); border-radius: 999px; background: var(--c-surface); text-decoration: none; color: var(--c-text); font-weight: 600; }
.chip:hover, .chip.is-active { background: var(--c-brand); border-color: var(--c-brand); color: #fff; }
.hours-table { width: 100%; border-collapse: collapse; }
.hours-table th, .hours-table td { text-align: left; padding: 8px 4px; border-bottom: 1px solid var(--c-line); font-weight: 400; }
.hours-table th { width: 40%; }
.hours-table tr.is-today { background: var(--c-brand-soft); font-weight: 700; }
.hours-table tr.is-today th { font-weight: 700; }
.addr-line { margin: 0 0 4px; }

/* ---------- Món (lưới + thẻ) ---------- */
.item-grid { display: grid; gap: 12px; grid-template-columns: 1fr; }
.item {
  display: grid; grid-template-columns: 96px 1fr; gap: 12px; background: var(--c-surface);
  border: 1px solid var(--c-line); border-radius: var(--radius); padding: 12px; position: relative;
}
.item.is-unavailable .item-media, .item.is-unavailable .item-body > *:not(.item-state) { opacity: .5; }
.item.is-unavailable { background: #f3eee7; }
.item:target { outline: 3px solid var(--c-brand); outline-offset: 2px; }
.item-media { width: 96px; height: 96px; border-radius: var(--radius-sm); overflow: hidden; background: var(--c-brand-soft); display: flex; align-items: center; justify-content: center; color: var(--c-brand); }
.item-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.item-media svg { width: 40px; height: 40px; opacity: .6; }
.item-body { min-width: 0; display: flex; flex-direction: column; }
a.item { text-decoration: none; color: inherit; }
a.item:hover { border-color: var(--c-brand); }
.item-name { display: block; font-weight: 700; font-size: 1.05rem; margin: 0 0 2px; overflow-wrap: anywhere; }
.item-desc { color: var(--c-muted); font-size: .9rem; margin: 0 0 4px; overflow-wrap: anywhere; }
.item-meta { color: var(--c-muted); font-size: .85rem; margin: 0 0 4px; }
.item-state { display: inline-block; align-self: flex-start; margin-bottom: 4px; padding: 2px 10px; border-radius: 999px; background: #5b5148; color: #fff; font-size: .8rem; font-weight: 700; }
.item-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.price { font-weight: 800; color: var(--c-brand-dark); font-size: 1.05rem; }
.price small { font-weight: 400; color: var(--c-muted); font-size: .85rem; }
.btn-add { min-width: 96px; }
.menu-tabs { position: sticky; top: 56px; z-index: 20; background: var(--c-bg); border-bottom: 1px solid var(--c-line); margin: 0 -16px 12px; padding: 8px 16px; display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.menu-tabs::-webkit-scrollbar { display: none; }
.menu-tabs .chip { flex: 0 0 auto; }
.menu-cat { margin-bottom: 24px; }
.menu-cat > h2 { margin: 8px 0 10px; }

/* ---------- Thanh giỏ hàng dính đáy ---------- */
.cartbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; background: var(--c-surface); border-top: 1px solid var(--c-line); box-shadow: 0 -4px 16px rgba(43, 36, 32, .12); padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); }
.cartbar-inner { max-width: 980px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.cartbar-info { min-width: 0; }
.cartbar-info strong { display: block; font-size: 1.05rem; }
.cartbar-info span { color: var(--c-muted); font-size: .9rem; }

/* ---------- Toast ---------- */
.toast-region { position: fixed; left: 0; right: 0; bottom: 16px; z-index: 80; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; padding: 0 16px; }
body.has-cartbar .toast-region { bottom: calc(var(--cartbar-h) + 20px); }
.toast { pointer-events: auto; max-width: 560px; width: 100%; padding: 12px 16px; border-radius: var(--radius-sm); background: #2b2420; color: #fff; box-shadow: var(--shadow); font-weight: 600; animation: toast-in .18s ease-out; }
.toast-error { background: var(--c-danger); }
.toast-ok { background: var(--c-ok); }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---------- Modal chọn tùy chọn ---------- */
.modal { position: fixed; inset: 0; z-index: 70; display: flex; align-items: flex-end; justify-content: center; background: rgba(30, 24, 20, .55); }
.modal-panel { background: var(--c-surface); width: 100%; max-width: 520px; max-height: 92vh; display: flex; flex-direction: column; border-radius: 16px 16px 0 0; overflow: hidden; }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; padding: 14px 16px 8px; }
.modal-head h2 { margin: 0; font-size: 1.15rem; overflow-wrap: anywhere; }
.modal-close { flex: 0 0 var(--tap); width: var(--tap); height: var(--tap); border: 0; background: none; font-size: 1.6rem; line-height: 1; cursor: pointer; border-radius: 50%; }
.modal-close:hover { background: var(--c-brand-soft); }
.modal-body { padding: 0 16px 8px; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.modal-foot { padding: 10px 16px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--c-line); }
.opt-group { border: 0; padding: 0; margin: 0 0 14px; min-width: 0; }
.opt-group legend { padding: 0; font-weight: 700; margin-bottom: 4px; }
.opt-group legend small { font-weight: 400; color: var(--c-muted); }
.opt-row { display: flex; align-items: center; gap: 12px; min-height: var(--tap); padding: 6px 10px; border: 1px solid var(--c-line); border-radius: var(--radius-sm); margin-bottom: 6px; cursor: pointer; }
.opt-row:has(input:checked) { border-color: var(--c-brand); background: var(--c-brand-soft); }
.opt-row input { width: 22px; height: 22px; flex: 0 0 22px; accent-color: var(--c-brand); margin: 0; }
.opt-row .opt-name { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.opt-row .opt-delta { color: var(--c-muted); white-space: nowrap; }
.opt-row.is-disabled { opacity: .5; cursor: not-allowed; }
.field-error { color: var(--c-danger); font-size: .9rem; font-weight: 600; margin: 4px 0 0; }

/* ---------- Biểu mẫu ---------- */
.field { margin-bottom: 14px; }
.field label, .field .label { display: block; font-weight: 700; margin-bottom: 4px; }
.field .hint { color: var(--c-muted); font-size: .875rem; margin: 4px 0 0; }
.input, .field input[type="text"], .field input[type="tel"], .field input[type="search"], .field textarea {
  width: 100%; min-height: var(--tap); padding: 10px 12px; font-size: 16px; border: 1px solid #b9ada1;
  border-radius: var(--radius-sm); background: #fff;
}
.field textarea { min-height: 88px; resize: vertical; }
.field.has-error input, .field.has-error textarea { border-color: var(--c-danger); border-width: 2px; }
.check { display: flex; align-items: flex-start; gap: 12px; padding: 8px 0; min-height: var(--tap); cursor: pointer; }
.check input { width: 24px; height: 24px; flex: 0 0 24px; margin: 0; accent-color: var(--c-brand); }
.check span { flex: 1; min-width: 0; }
.check.has-error { background: var(--c-danger-bg); border-radius: var(--radius-sm); padding: 8px; }
.check input:disabled + span { opacity: .55; }
.phone-norm { margin: 6px 0 0; font-weight: 700; color: var(--c-ok); }
.phone-norm.is-bad { color: var(--c-danger); }

/* ---------- Giỏ hàng ---------- */
.cart-lines { display: block; }
.cart-line { display: grid; grid-template-columns: 64px 1fr; gap: 6px 12px; padding: 14px 0; border-bottom: 1px solid var(--c-line); }
.cart-line:last-child { border-bottom: 0; }
.cart-line .item-media { width: 64px; height: 64px; }
.cart-line .item-media svg { width: 28px; height: 28px; }
.cart-line.has-issue { background: var(--c-danger-bg); margin: 0 -16px; padding-left: 16px; padding-right: 16px; }
.line-name { font-weight: 700; margin: 0; overflow-wrap: anywhere; }
.line-opts, .line-note { color: var(--c-muted); font-size: .9rem; margin: 2px 0 0; overflow-wrap: anywhere; }
.line-issues { color: var(--c-danger); font-weight: 600; font-size: .9rem; margin: 4px 0 0; }
.line-ctrl { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.qty { display: inline-flex; align-items: center; border: 1px solid #b9ada1; border-radius: var(--radius-sm); overflow: hidden; background: #fff; }
.qty button { width: var(--tap); height: var(--tap); border: 0; background: var(--c-brand-soft); font-size: 1.4rem; font-weight: 700; cursor: pointer; line-height: 1; }
.qty button:hover:not([disabled]) { background: #f6d9c6; }
.qty button[disabled] { opacity: .5; cursor: wait; }
.qty output { min-width: 56px; text-align: center; font-weight: 700; padding: 0 6px; }
.line-total { font-weight: 800; }
.line-right { display: flex; align-items: center; gap: 8px; }
.totals { margin-top: 8px; }
.totals-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 4px 0; }
.totals-row.total { border-top: 1px solid var(--c-line); margin-top: 6px; padding-top: 10px; font-size: 1.2rem; font-weight: 800; }
.empty-state { text-align: center; padding: 28px 8px; }
.empty-state svg { width: 56px; height: 56px; color: var(--c-brand); opacity: .6; }

/* ---------- Thanh toán (checkout) ---------- */
.mini-lines li { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border-bottom: 1px dashed var(--c-line); }
.mini-lines li:last-child { border-bottom: 0; }
.mini-lines .ml-main { min-width: 0; overflow-wrap: anywhere; }
.mini-lines .ml-sub { display: block; color: var(--c-muted); font-size: .875rem; }
.ful-options { display: grid; gap: 10px; grid-template-columns: 1fr; }
.ful-option { position: relative; display: block; }
.ful-option input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.ful-box { display: block; border: 2px solid var(--c-line); border-radius: var(--radius); padding: 14px 14px 14px 48px; background: var(--c-surface); position: relative; min-height: 72px; }
.ful-box::before { content: ""; position: absolute; left: 14px; top: 18px; width: 22px; height: 22px; border-radius: 50%; border: 2px solid #b9ada1; background: #fff; }
.ful-option input:checked + .ful-box { border-color: var(--c-brand); background: var(--c-brand-soft); }
.ful-option input:checked + .ful-box::before { border-color: var(--c-brand); background: radial-gradient(circle, var(--c-brand) 0 45%, #fff 50%); }
.ful-option input:focus-visible + .ful-box { outline: 3px solid #1b6ec2; outline-offset: 2px; }
.ful-option input:disabled { cursor: not-allowed; }
.ful-option input:disabled + .ful-box { opacity: .55; background: #f0ebe4; }
.ful-box strong { display: block; font-size: 1.05rem; }
.ful-box .ful-sub { display: block; color: var(--c-muted); font-size: .9rem; }
.ful-box .ful-off { display: block; color: var(--c-danger); font-weight: 700; font-size: .9rem; margin-top: 4px; }
.addr-wrap { position: relative; }
.addr-results { position: absolute; left: 0; right: 0; top: 100%; z-index: 10; background: #fff; border: 1px solid #b9ada1; border-radius: var(--radius-sm); box-shadow: var(--shadow); max-height: 260px; overflow-y: auto; margin-top: 2px; }
.addr-results button { display: block; width: 100%; text-align: left; border: 0; border-bottom: 1px solid var(--c-line); background: #fff; padding: 10px 12px; min-height: var(--tap); cursor: pointer; font-size: .95rem; }
.addr-results button:last-child { border-bottom: 0; }
.addr-results button:hover, .addr-results button:focus-visible { background: var(--c-brand-soft); }
.addr-results .addr-msg { padding: 10px 12px; color: var(--c-muted); font-size: .9rem; }
.map-box { height: 280px; border: 1px solid #b9ada1; border-radius: var(--radius-sm); overflow: hidden; margin: 8px 0; background: #e9e4dc; z-index: 0; position: relative; }
.map-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.quote-box { border: 1px solid var(--c-line); border-radius: var(--radius-sm); padding: 12px; background: #fdfaf6; margin: 8px 0 12px; }
.quote-box.is-ok { border-color: #c5e3d0; background: var(--c-ok-bg); }
.quote-box.is-error { border-color: #f4c7c2; background: var(--c-danger-bg); }
.quote-fee { font-size: 1.1rem; font-weight: 800; }
.spinner { display: inline-block; width: 16px; height: 16px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; vertical-align: -3px; }
@keyframes spin { to { transform: rotate(360deg); } }
.pay-notice { border: 2px solid var(--c-warn); background: var(--c-warn-bg); border-radius: var(--radius); padding: 14px; margin: 12px 0; font-weight: 700; color: #5e3d00; }
.missing-hints { color: var(--c-muted); font-size: .9rem; margin: 8px 0 0; }
.missing-hints ul { list-style: disc; padding-left: 20px; margin-top: 4px; }
.leaflet-container { font-family: var(--font); }

/* ---------- Trang đơn ---------- */
.order-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.status-pill { display: inline-block; padding: 4px 14px; border-radius: 999px; background: var(--c-brand-soft); color: var(--c-brand-dark); font-weight: 800; }
.pay-big { text-align: center; padding: 12px; border-radius: var(--radius); background: var(--c-brand-soft); border: 2px solid var(--c-brand); margin-bottom: 12px; }
.pay-big .label { display: block; font-size: .9rem; color: var(--c-muted); font-weight: 700; text-transform: uppercase; letter-spacing: .03em; }
.pay-big .value { display: block; font-size: 1.9rem; font-weight: 900; color: var(--c-brand-dark); overflow-wrap: anywhere; line-height: 1.2; margin: 2px 0 8px; }
.pay-big .value.mono { font-family: ui-monospace, "SFMono-Regular", Consolas, monospace; letter-spacing: .08em; }
.qr-wrap { text-align: center; margin: 8px 0 14px; }
.qr-wrap img { width: 100%; max-width: 280px; height: auto; border: 1px solid var(--c-line); border-radius: var(--radius-sm); background: #fff; padding: 6px; }
.countdown { font-size: 1.4rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.countdown.is-low { color: var(--c-danger); }
.bank-list { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 0 0 8px; }
.bank-list dt { color: var(--c-muted); }
.bank-list dd { margin: 0; font-weight: 700; overflow-wrap: anywhere; }
.copy-row { display: flex; gap: 8px; align-items: stretch; }
.copy-row input { flex: 1; min-width: 0; padding: 8px 10px; border: 1px solid #b9ada1; border-radius: var(--radius-sm); font-size: 16px; min-height: var(--tap); background: #fff; }
.stepper { counter-reset: step; margin: 14px 0 6px; padding: 0; list-style: none; }
.stepper li { position: relative; padding: 0 0 18px 40px; min-height: 36px; color: var(--c-muted); }
.stepper li::before { counter-increment: step; content: counter(step); position: absolute; left: 0; top: 0; width: 28px; height: 28px; border-radius: 50%; background: var(--c-line); color: var(--c-muted); font-weight: 700; text-align: center; line-height: 28px; font-size: .9rem; }
.stepper li::after { content: ""; position: absolute; left: 13px; top: 30px; bottom: 2px; width: 2px; background: var(--c-line); }
.stepper li:last-child { padding-bottom: 0; }
.stepper li:last-child::after { display: none; }
.stepper li.is-done { color: var(--c-text); }
.stepper li.is-done::before { background: var(--c-ok); color: #fff; content: "\2713"; }
.stepper li.is-done::after { background: var(--c-ok); }
.stepper li.is-current { color: var(--c-brand-dark); font-weight: 800; }
.stepper li.is-current::before { background: var(--c-brand); color: #fff; box-shadow: 0 0 0 4px var(--c-brand-soft); }
.pickup-code { text-align: center; padding: 14px; border: 2px dashed var(--c-brand); border-radius: var(--radius); background: var(--c-brand-soft); margin: 12px 0; }
.pickup-code .code { display: block; font-size: 2.6rem; font-weight: 900; letter-spacing: .25em; font-family: ui-monospace, Consolas, monospace; color: var(--c-brand-dark); padding-left: .25em; }
.timeline li { display: flex; gap: 12px; padding: 6px 0; border-bottom: 1px dashed var(--c-line); }
.timeline li:last-child { border-bottom: 0; }
.timeline time { flex: 0 0 auto; color: var(--c-muted); font-size: .9rem; min-width: 110px; font-variant-numeric: tabular-nums; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 4px 14px; margin: 0; }
.kv dt { color: var(--c-muted); }
.kv dd { margin: 0; overflow-wrap: anywhere; }
.poll-note { color: var(--c-muted); font-size: .875rem; text-align: center; }

/* ---------- Chính sách ---------- */
.policy-nav { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.policy h2 { margin-top: 1.4rem; font-size: 1.1rem; }
.policy ul { list-style: disc; padding-left: 22px; margin-bottom: .75rem; }
.policy li { margin-bottom: 4px; }

/* ---------- Màn hình rộng ---------- */
@media (min-width: 720px) {
  h1 { font-size: 1.75rem; }
  .methods { grid-template-columns: 1fr 1fr; }
  .item-grid { grid-template-columns: 1fr 1fr; }
  .ful-options { grid-template-columns: 1fr 1fr; }
  .modal { align-items: center; }
  .modal-panel { border-radius: 16px; max-height: 86vh; }
  .menu-tabs { margin: 0 0 12px; padding: 8px 0; }
  .map-box { height: 340px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .toast, .spinner { animation: none; }
}
