/* BKBN: KryUI "Midnight Gold" dùng chung với bengoan. Vàng = 1 hành động chính mỗi màn. Xanh lá = đã xong, đỏ = nợ, huỷ. */
:root {
  --bg: #0c0e12; --surface: #14171d; --surface2: #191d24; --line: #242932; --line2: #2f3540;
  --ink: #f3f5f8; --ink-soft: #8b94a3; --ink-faint: #5b636f;
  --gold: #e7b866; --gold2: #c99544; --gold-hi: #f2d79a; --action-ink: #1a1206; --gold-bg: #2b2416;
  --teal: #34d8c4; --teal-bg: #12332f;
  --ok: #4ade80; --ok-bg: #14321f; --warn: #fbbf24; --warn-bg: #33290f; --bad: #f87171; --bad-bg: #3a1c1c;
  --ring: rgba(231,184,102,.55);
  --r: 16px; --r-sm: 10px;
  --safe-b: env(safe-area-inset-bottom, 0px); --safe-t: env(safe-area-inset-top, 0px);
  --font: 'Be Vietnam Pro', system-ui, -apple-system, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font); font-size: 15px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
body { min-height: 100dvh; background:
  radial-gradient(900px 420px at 85% -10%, rgba(231,184,102,.09), transparent 60%),
  radial-gradient(700px 380px at -10% 10%, rgba(52,216,196,.07), transparent 60%), var(--bg); background-attachment: fixed; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--ring); outline-offset: 2px; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.soft { color: var(--ink-soft); }
.faint { color: var(--ink-faint); }

.app { max-width: 680px; margin: 0 auto; padding: calc(var(--safe-t) + 8px) 16px calc(var(--safe-b) + 110px); }

/* ---------- top bar ---------- */
.bar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 10px; padding: calc(var(--safe-t) + 10px) 16px 10px; margin: calc(-1 * var(--safe-t) - 8px) -16px 0;
  background: rgba(12,14,18,.78); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid rgba(36,41,50,.6); }
.bar h1 { font-size: 20px; font-weight: 800; letter-spacing: -.02em; margin: 0; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; text-decoration: none; }
.brand-mark { width: 34px; height: 34px; border-radius: 10px; flex: none; }
.brand b { display: block; font-size: 18px; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; }
.brand small { display: block; font-size: 12px; color: var(--ink-soft); }
.icon-btn { width: 40px; height: 40px; flex: none; display: grid; place-items: center; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); }
.icon-btn:active { transform: scale(.96); }
.icon-btn svg, .btn svg, .chip svg { width: 18px; height: 18px; }
.me-chip { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px 0 4px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); max-width: 46%; }
.me-chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; font-size: 14px; }

/* ---------- avatar ---------- */
.av { width: 30px; height: 30px; border-radius: 50%; display: inline-grid; place-items: center; font-size: 12px; font-weight: 700; color: #0c0e12; flex: none; border: 2px solid var(--surface); }
.av-stack { display: flex; }
.av-stack .av { margin-left: -8px; }
.av-stack .av:first-child { margin-left: 0; }
.av-more { background: var(--surface2) !important; color: var(--ink-soft); }

/* ---------- section + cards ---------- */
.section { margin-top: 22px; }
.section-h { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin: 0 2px 10px; }
.section-h h2 { margin: 0; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 14px; }
.card + .card { margin-top: 10px; }
a.card { display: block; text-decoration: none; transition: border-color .15s, transform .15s; }
a.card:hover { border-color: var(--line2); }
a.card:active { transform: scale(.99); }
.ev-top { display: flex; gap: 12px; align-items: flex-start; }
.sport { width: 44px; height: 44px; flex: none; border-radius: 12px; display: grid; place-items: center; font-size: 22px; background: var(--surface2); border: 1px solid var(--line); }
.ev-title { font-weight: 700; font-size: 16px; line-height: 1.3; margin: 0; }
.ev-meta { font-size: 13px; color: var(--ink-soft); margin-top: 2px; display: flex; flex-wrap: wrap; gap: 4px 10px; }
.ev-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 12px; padding-top: 12px; border-top: 1px dashed var(--line); font-size: 13px; }

.badge { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.b-vote { background: var(--teal-bg); color: var(--teal); }
.b-lock { background: var(--ok-bg); color: var(--ok); }
.b-warn { background: var(--warn-bg); color: var(--warn); }
.b-bad { background: var(--bad-bg); color: var(--bad); }
.b-muted { background: var(--surface2); color: var(--ink-soft); }
.dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.pulse { animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .35; } }

/* ---------- timeline ---------- */
.tl { position: relative; }
.tl-day { display: grid; grid-template-columns: 58px 1fr; gap: 12px; position: relative; }
.tl-day + .tl-day { margin-top: 14px; }
.tl-date { text-align: center; padding-top: 6px; position: relative; }
.tl-date .wd { font-size: 12px; font-weight: 700; color: var(--ink-soft); text-transform: uppercase; }
.tl-date .d { font-family: var(--mono); font-size: 20px; font-weight: 700; line-height: 1.1; }
.tl-date .m { font-size: 11px; color: var(--ink-faint); }
.tl-day::before { content: ''; position: absolute; left: 28px; top: 64px; bottom: -14px; width: 2px; background: var(--line); }
.tl-day:last-child::before { bottom: 0; }
.tl-day.today .tl-date .d { color: var(--teal); }
.tl-items .card + .card { margin-top: 8px; }
.tl-time { font-family: var(--mono); font-weight: 700; font-size: 14px; color: var(--ink); }

/* ---------- progress ---------- */
.meter { height: 6px; border-radius: 99px; background: var(--surface2); overflow: hidden; position: relative; }
.meter > i { position: absolute; inset: 0 auto 0 0; border-radius: inherit; background: var(--teal); transition: width .35s cubic-bezier(.2,.8,.2,1); }
.meter.full > i { background: var(--ok); }
.meter .min-mark { position: absolute; top: -2px; bottom: -2px; width: 2px; background: var(--ink-faint); }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 16px; border-radius: 12px; border: 1px solid var(--line2); background: var(--surface2); color: var(--ink); font-weight: 600; font-size: 15px; text-decoration: none; white-space: nowrap; }
.btn:active { transform: scale(.98); }
.btn[disabled] { opacity: .5; pointer-events: none; }
.btn-gold { background: linear-gradient(180deg, var(--gold-hi), var(--gold) 40%, var(--gold2)); border-color: transparent; color: var(--action-ink); font-weight: 700; }
.btn-ghost { background: transparent; border-color: var(--line); }
.btn-danger { background: var(--bad-bg); border-color: transparent; color: var(--bad); }
.btn-sm { height: 34px; padding: 0 12px; font-size: 13px; border-radius: 10px; }
.btn-block { width: 100%; }
.row { display: flex; gap: 8px; align-items: center; }
.row.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }

.fab { position: fixed; right: max(16px, calc(50vw - 340px + 16px)); bottom: calc(var(--safe-b) + 20px); z-index: 30; height: 56px; padding: 0 22px 0 18px; border-radius: 18px; font-size: 16px; box-shadow: 0 10px 30px rgba(231,184,102,.25), 0 2px 0 rgba(255,255,255,.25) inset; }
.fab svg { width: 22px; height: 22px; }

/* ---------- forms ---------- */
.field { display: block; margin-top: 16px; }
.field > span { display: block; font-size: 13px; font-weight: 600; color: var(--ink-soft); margin-bottom: 6px; }
.input, textarea.input { width: 100%; height: 46px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line2); background: var(--bg); outline: none; font-size: 16px; }
textarea.input { height: auto; min-height: 76px; padding: 10px 14px; resize: vertical; }
.input:focus { border-color: var(--gold2); box-shadow: 0 0 0 3px rgba(231,184,102,.15); }
input[type=date].input, input[type=time].input, input[type=datetime-local].input { color-scheme: dark; min-width: 0; }
.hint { font-size: 12px; color: var(--ink-faint); margin-top: 6px; }

.sports { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 6px; margin: 0 -2px; scrollbar-width: none; }
.sports::-webkit-scrollbar { display: none; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line2); background: var(--surface); white-space: nowrap; font-weight: 600; font-size: 14px; flex: none; }
.chip[aria-pressed=true] { border-color: var(--teal); background: var(--teal-bg); color: var(--teal); }

.stepper { display: flex; align-items: center; border: 1px solid var(--line2); border-radius: 12px; background: var(--bg); height: 46px; overflow: hidden; }
.stepper button { width: 44px; height: 100%; border: 0; background: transparent; font-size: 20px; color: var(--ink-soft); }
.stepper input { width: 100%; min-width: 0; text-align: center; border: 0; background: transparent; outline: none; font-family: var(--mono); font-size: 17px; font-weight: 700; }
.stepper input::placeholder { font-family: var(--font); font-size: 13px; font-weight: 500; color: var(--ink-faint); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* ---------- event page ---------- */
.hero { padding: 18px; }
.hero h1 { font-size: 22px; font-weight: 800; letter-spacing: -.02em; line-height: 1.25; margin: 10px 0 6px; }
.hero .note { white-space: pre-wrap; margin-top: 10px; color: var(--ink-soft); font-size: 14px; }
.facts { display: flex; flex-wrap: wrap; gap: 8px 16px; font-size: 14px; color: var(--ink-soft); }
.facts span { display: inline-flex; align-items: center; gap: 6px; }
.facts svg { width: 16px; height: 16px; flex: none; }

.slot { padding: 14px; }
.slot.best { border-color: rgba(52,216,196,.45); }
.slot.chosen { border-color: rgba(74,222,128,.55); background: linear-gradient(180deg, rgba(74,222,128,.06), transparent 60%), var(--surface); }
.slot-h { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.slot-when b { display: block; font-size: 16px; font-weight: 700; }
.slot-when .mono { font-size: 14px; color: var(--ink-soft); }
.count { text-align: right; flex: none; }
.count b { font-family: var(--mono); font-size: 24px; font-weight: 700; line-height: 1; }
.count small { display: block; font-size: 11px; color: var(--ink-soft); }
.slot .meter { margin: 12px 0 10px; }
.vote3 { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 6px; }
.vote3 button { height: 42px; border-radius: 11px; border: 1px solid var(--line2); background: var(--bg); font-weight: 600; font-size: 14px; display: flex; align-items: center; justify-content: center; gap: 6px; }
.vote3 button svg { width: 16px; height: 16px; }
.vote3 button.btn-gold { background: linear-gradient(180deg, var(--gold-hi), var(--gold) 40%, var(--gold2)); font-weight: 700; }
.vote3 button[aria-pressed=true].v-yes { background: var(--ok-bg); border-color: var(--ok); color: var(--ok); }
.vote3 button[aria-pressed=true].v-maybe { background: var(--warn-bg); border-color: var(--warn); color: var(--warn); }
.vote3 button[aria-pressed=true].v-no { background: var(--bad-bg); border-color: var(--bad); color: var(--bad); }
.who { margin-top: 10px; display: flex; flex-wrap: wrap; gap: 6px; }
.who-chip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px 3px 3px; border-radius: 999px; background: var(--surface2); font-size: 13px; }
.who-chip .av { width: 22px; height: 22px; font-size: 10px; border: 0; }
.who-chip.maybe { opacity: .7; }
.who-chip.me { outline: 1px solid var(--gold2); }
.who-chip em { font-style: normal; color: var(--ink-soft); font-family: var(--mono); font-size: 12px; }
.slot-admin { display: flex; gap: 8px; margin-top: 12px; }

.roster { counter-reset: r; }
.roster li { counter-increment: r; display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line); list-style: none; }
.roster li:last-child { border-bottom: 0; }
.roster li::before { content: counter(r); font-family: var(--mono); font-size: 13px; color: var(--ink-faint); width: 22px; text-align: right; }
.roster ol { margin: 0; padding: 0; }
.big-when { font-size: 26px; font-weight: 800; letter-spacing: -.02em; line-height: 1.15; margin: 6px 0 2px; }

.cmt { display: flex; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.cmt:last-child { border-bottom: 0; }
.cmt p { margin: 2px 0 0; white-space: pre-wrap; word-break: break-word; font-size: 14px; }
.cmt .x { margin-left: auto; background: none; border: 0; color: var(--ink-faint); font-size: 12px; align-self: flex-start; }

.guests { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.guests .stepper { width: 140px; height: 40px; }

.empty { text-align: center; padding: 40px 20px; }
.empty .art { font-size: 44px; }
.empty h3 { margin: 10px 0 4px; font-size: 18px; }

/* ---------- sheet + toast ---------- */
.sheet-bg { position: fixed; inset: 0; z-index: 50; background: rgba(5,6,8,.6); backdrop-filter: blur(3px); display: flex; align-items: flex-end; justify-content: center; animation: fade .15s ease; }
.sheet { width: 100%; max-width: 680px; background: var(--surface); border: 1px solid var(--line2); border-bottom: 0; border-radius: 22px 22px 0 0; padding: 10px 18px calc(var(--safe-b) + 18px); animation: up .22s cubic-bezier(.2,.8,.2,1); max-height: 90dvh; overflow-y: auto; }
.sheet .grab { width: 40px; height: 4px; border-radius: 9px; background: var(--line2); margin: 0 auto 14px; }
.sheet h3 { margin: 0 0 4px; font-size: 19px; font-weight: 800; }
@keyframes up { from { transform: translateY(40px); opacity: 0; } }
@keyframes fade { from { opacity: 0; } }
.toast { position: fixed; left: 50%; bottom: calc(var(--safe-b) + 92px); transform: translate(-50%, 20px); z-index: 60; background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 12px; font-weight: 600; font-size: 14px; opacity: 0; pointer-events: none; transition: .2s; max-width: calc(100vw - 32px); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.err { background: var(--bad); color: #fff; }

.skeleton { height: 92px; border-radius: var(--r); background: linear-gradient(90deg, var(--surface) 0, var(--surface2) 50%, var(--surface) 100%); background-size: 200% 100%; animation: sk 1.2s linear infinite; }
.skeleton + .skeleton { margin-top: 10px; }
@keyframes sk { to { background-position: -200% 0; } }

details.past summary { cursor: pointer; list-style: none; color: var(--ink-soft); font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; margin: 0 2px 10px; }
details.past summary::-webkit-details-marker { display: none; }

/* ================= BKBN thêm ================= */
.small { font-size: 12px; }
.neg { color: var(--bad); }
.pos { color: var(--ok); }
.strike { text-decoration: line-through; }
.stack { display: flex; flex-direction: column; gap: 8px; }
.stack > .card + .card { margin-top: 0; }
.app { padding-bottom: calc(var(--safe-b) + 150px); }
.boot { padding-top: 70px; }

.bar-title { flex: 1; min-width: 0; }
.bar-title h1 { flex: none; }
.bar-title small { display: block; font-size: 12px; color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.icon-btn { position: relative; text-decoration: none; }
.icon-btn.sm { width: 32px; height: 32px; border-radius: 9px; }
.icon-btn.sm svg { width: 15px; height: 15px; }
.bubble { position: absolute; top: -5px; right: -5px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 99px; background: var(--bad); color: #fff; font: 700 11px/18px var(--font); text-align: center; font-style: normal; }
.bubble.static { position: static; }

/* tab dưới */
.tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 25; display: grid; grid-template-columns: repeat(4, 1fr); max-width: 680px; margin: 0 auto;
  padding: 6px 8px calc(var(--safe-b) + 6px); background: rgba(12,14,18,.92); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid var(--line); }
.tab { position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 0; border-radius: 12px; color: var(--ink-faint); text-decoration: none; font-size: 11px; font-weight: 600; }
.tab svg { width: 22px; height: 22px; }
.tab.on { color: var(--gold); }
.tab .bubble { top: 0; right: calc(50% - 22px); }
.fab { bottom: calc(var(--safe-b) + 84px); }

/* dòng danh sách */
.list-row { display: flex; align-items: center; gap: 12px; text-decoration: none; width: 100%; text-align: left; color: inherit; font: inherit; }
button.list-row { cursor: pointer; }
button.list-row[disabled] { cursor: default; opacity: 1; }
.list-row > svg { width: 20px; height: 20px; color: var(--ink-soft); flex: none; }
.list-row b { font-weight: 700; }
.tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; align-items: center; }
.line { padding: 10px 0; border-bottom: 1px solid var(--line); gap: 10px; }
.line:last-child { border-bottom: 0; }
.line.me { background: linear-gradient(90deg, rgba(231,184,102,.08), transparent); margin: 0 -14px; padding-left: 14px; padding-right: 14px; }

/* banner */
.banner { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: var(--r); text-decoration: none; font-size: 14px; border: 1px solid transparent; margin-top: 12px; }
.banner > span { flex: 1; }
.banner svg { width: 20px; height: 20px; flex: none; }
.banner.bad { background: var(--bad-bg); color: var(--bad); border-color: rgba(248,113,113,.3); }
.banner.warn { background: var(--warn-bg); color: var(--warn); border-color: rgba(251,191,36,.3); }

/* chào */
.welcome { padding-top: 60px; text-align: center; }
.welcome .brand-mark { width: 72px; height: 72px; border-radius: 20px; }
.welcome h1 { font-size: 30px; font-weight: 800; letter-spacing: -.03em; margin: 18px 0 8px; }
.welcome .lead { color: var(--ink-soft); font-size: 16px; margin: 0 auto 22px; max-width: 460px; }
.ticks { list-style: none; padding: 0; margin: 0 auto 26px; max-width: 420px; text-align: left; }
.ticks li { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; }
.ticks svg { width: 18px; height: 18px; color: var(--ok); flex: none; margin-top: 3px; }
.pin { letter-spacing: .6em; font-size: 22px; text-align: center; }

/* kèo */
.ev.cancelled { opacity: .55; }
.ev.cancelled .ev-title { text-decoration: line-through; }
.status { padding: 16px; }
.status-label { font-size: 16px; }
.status.cancelled { border-color: rgba(248,113,113,.4); }
.me-state { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; font-weight: 600; }
.me-state svg { width: 18px; height: 18px; }
.me-state.ok { color: var(--ok); }
.me-state.warn { color: var(--warn); }
.offer { background: var(--gold-bg); border: 1px solid rgba(231,184,102,.45); border-radius: 12px; padding: 12px; margin-bottom: 12px; display: flex; flex-direction: column; gap: 2px; }
.vote3 button:disabled { opacity: .45; }
.guests { margin-top: 12px; }
.facts a { color: var(--ink-soft); display: inline-flex; align-items: center; gap: 6px; text-decoration: underline dotted; text-underline-offset: 3px; }
.roster li.me { background: linear-gradient(90deg, rgba(231,184,102,.1), transparent); }
.roster .grow { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.roster.wait li::before { content: '#' counter(r); }
.who-chip.faint { color: var(--ink-faint); padding-left: 10px; }
.warn-line { color: var(--warn); font-size: 12px; margin: 4px 0 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.chip-sm { height: 32px; padding: 0 12px; font-size: 13px; }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; background: var(--bg); border: 1px solid var(--line2); border-radius: 12px; }
.seg button { height: 38px; border: 0; border-radius: 9px; background: transparent; font-weight: 600; font-size: 14px; color: var(--ink-soft); }
.seg button[aria-pressed=true] { background: var(--surface2); color: var(--ink); box-shadow: 0 0 0 1px var(--line2); }
.switch { display: flex; align-items: center; gap: 10px; margin-top: 14px; font-size: 14px; cursor: pointer; }
.switch input { width: 20px; height: 20px; accent-color: var(--gold); flex: none; }
.mini { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--ink-soft); }
.mini input { accent-color: var(--gold); }
#ef .card + .card { margin-top: 10px; }
select.input { appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--ink-soft) 50%), linear-gradient(135deg, var(--ink-soft) 50%, transparent 50%); background-position: calc(100% - 18px) 20px, calc(100% - 13px) 20px; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 34px; }

/* tiền */
.balance { display: flex; flex-direction: column; gap: 2px; padding: 18px; }
.balance > b { font-size: 34px; font-weight: 700; letter-spacing: -.02em; line-height: 1.15; }
.balance.bad > b { color: var(--bad); }
.balance.ok > b { color: var(--ok); }
.balance.warn > b { color: var(--warn); }
.qr { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.qr img { width: 100%; max-width: 280px; height: auto; aspect-ratio: 1; border-radius: 12px; background: #fff; }
.qr-rows { width: 100%; }
.qr-rows > div { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.qr-rows > div:last-child { border-bottom: 0; }
.qr-rows span { width: 110px; flex: none; font-size: 13px; }
.qr-rows b { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.thumb { width: 44px; height: 44px; flex: none; border-radius: 8px; overflow: hidden; display: block; background: var(--surface2); }
.thumb img, .proof-big img { width: 100%; height: 100%; object-fit: cover; display: block; }
.proof-big { display: block; width: 100%; max-height: 340px; border-radius: 12px; overflow: hidden; background: var(--surface2); }
.proof-big img { max-height: 340px; object-fit: contain; }
.proof-preview { width: 100%; max-height: 320px; object-fit: contain; border-radius: 12px; margin-bottom: 10px; background: var(--surface2); }
.zoom { width: 100%; max-height: 72dvh; object-fit: contain; border-radius: 12px; background: #000; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
.stats .card + .card { margin-top: 0; }
.stats .card { display: flex; flex-direction: column; gap: 2px; }
.stats b { font-size: 20px; }
.transfer + .transfer { margin-top: 10px; }
.transfer.confirmed { border-color: rgba(74,222,128,.4); }
.transfer.sent { border-color: rgba(251,191,36,.4); }
.review + .review { margin-top: 10px; }

/* ảnh */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.tile { padding: 0; border: 0; background: var(--surface2); aspect-ratio: 1; overflow: hidden; border-radius: 6px; }
.tile img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tile.hidden-photo { opacity: .35; }

.notice { display: block; }
.notice p { margin: 0 0 4px; }
.notice.unread { border-color: rgba(231,184,102,.45); }
.steps { padding-left: 20px; }
.steps li { margin: 8px 0; }
.toast { display: flex; align-items: center; gap: 12px; pointer-events: none; }
.toast.show { pointer-events: auto; }
.toast button { border: 0; background: transparent; color: var(--gold2); font-weight: 800; padding: 0; }
.toast.err button { color: #fff; text-decoration: underline; }
body.offline .vote3 button, body.offline .btn-gold { opacity: .45; pointer-events: none; }
body.offline::after { content: 'Mất mạng, đang xem bản lưu gần nhất'; position: fixed; top: 0; left: 0; right: 0; z-index: 70; text-align: center; font-size: 12px; padding: calc(var(--safe-t) + 4px) 0 4px; background: var(--warn-bg); color: var(--warn); }

@media (min-width: 720px) {
  .app { padding-top: 20px; }
  .hero h1 { font-size: 26px; }
  .grid { grid-template-columns: repeat(4, 1fr); }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
.bar .brand { flex: none; }
.bar-title h1 { font-size: 19px; }
a.card.list-row, .card.list-row { display: flex; }
.big-when { font-size: 17px; font-weight: 700; color: var(--teal); letter-spacing: 0; margin: 0 0 8px; }
.hero h1 { margin: 12px 0 2px; }
[hidden] { display: none !important; }
body.loading::before { content: ''; position: fixed; top: 0; left: 0; height: 3px; width: 40%; z-index: 80; background: var(--gold); animation: load 1s ease-in-out infinite; }
@keyframes load { from { left: -40%; } to { left: 100%; } }
