/* Quỹ Đội Bóng - giao diện. Màu sân cỏ + vàng thẻ phạt. */
:root {
  --pitch: #0E3B2C; --pitch-2: #15513D; --pitch-3: #1C6248; --pitch-line: #1F5A45;
  --green: #15603F;
  --ground: #F3F6F4; --surface: #FFFFFF;
  --ink: #14211B; --ink-2: #3D4C45; --muted: #5B6B63;
  --line: #DCE4DF; --line-2: #EAF0EC; --field: #C9D6CF;
  --amber: #E0A100; --amber-soft: #F2C94C;
  --in: #1B7A45; --out: #B3361F;
  --paid-bg: #D6F0DF; --paid-fg: #145A32;
  --half-bg: #FCEBC2; --half-fg: #6E4A00;
  --owe-bg: #FBE0DC; --owe-fg: #9B2C1F; --owe-line: #E9A79C;
  --na-bg: #EEF2F0; --na-fg: #66756D;
  --display: 'Barlow Condensed', 'Arial Narrow', system-ui, sans-serif;
  --body: 'Be Vietnam Pro', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  color-scheme: light;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; font-family: var(--body); font-size: 14px; line-height: 1.45; color: var(--ink); background: var(--ground); }
a { color: var(--green); }
a:hover { color: var(--pitch); }
h1 { margin: 4px 0 0; font-family: var(--display); font-size: 40px; font-weight: 700; line-height: 1.05; text-wrap: balance; }
h2 { margin: 0; font-size: 16px; font-weight: 700; }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 2px; }
[hidden] { display: none !important; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.num { font-variant-numeric: tabular-nums; }
.strong { font-weight: 700; }
.small { font-size: 13px; }
.nw { white-space: nowrap; }
.grow { flex: 1; min-width: 0; }
.c-in { color: var(--in); } .c-out { color: var(--out); } .c-owe { color: var(--owe-fg); } .c-muted { color: var(--muted); }

/* ---- Khung trang ---- */
.shell { min-height: 100vh; display: flex; }
.side { width: 240px; flex: none; background: var(--pitch); color: #E8F1EC; padding: 24px 16px; display: flex; flex-direction: column; gap: 28px; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.brand { display: flex; align-items: center; gap: 12px; padding: 0 8px; color: #FFFFFF; text-decoration: none; }
.brand:hover { color: #FFFFFF; }
.brand .logo { width: 52px; height: 52px; flex: none; border-radius: 50%; }
.login-brand .logo-lg { width: 88px; height: 88px; flex: none; }
.brand > span { display: flex; flex-direction: column; min-width: 0; }
.brand-name { font-family: var(--display); font-size: 24px; font-weight: 700; letter-spacing: .03em; line-height: 1; text-transform: uppercase; }
.brand-sub { font-size: 12px; color: #9DBFAE; margin-top: 4px; }
.nav { display: flex; flex-direction: column; gap: 4px; }
.nav a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; min-height: 44px; border-radius: 8px; color: #CFE2D8; text-decoration: none; font-weight: 500; }
.nav a:hover { background: var(--pitch-2); color: #FFFFFF; }
.nav a.on { background: var(--pitch-3); color: #FFFFFF; }
.me { margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 12px 0 0 8px; border-top: 1px solid var(--pitch-line); }
.me-text { min-width: 0; }
.me-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.me-role { font-size: 12px; color: #9DBFAE; }
.me form { margin-left: auto; }
.avatar { width: 36px; height: 36px; flex: none; border-radius: 50%; background: var(--amber); color: var(--pitch); display: flex; align-items: center; justify-content: center; font-weight: 700; }
.icon-btn { width: 40px; height: 40px; border: 0; border-radius: 8px; background: none; color: #CFE2D8; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; flex: none; }
.icon-btn:hover { background: var(--pitch-2); color: #FFFFFF; }
.icon-btn.dark { color: var(--ink-2); }
.icon-btn.dark:hover { background: var(--line-2); color: var(--ink); }
.main { flex: 1; min-width: 0; padding: 28px 32px 56px; display: flex; flex-direction: column; gap: 20px; }

.head { display: flex; flex-wrap: wrap; gap: 16px; justify-content: space-between; align-items: flex-end; }
.eyebrow { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.eyebrow a { color: inherit; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }

/* ---- Nút ---- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 16px; border-radius: 8px; border: 1px solid transparent; font: 600 14px var(--body); text-decoration: none; cursor: pointer; white-space: nowrap; }
.btn-p { background: var(--green); border-color: var(--green); color: #FFFFFF; }
.btn-p:hover { background: var(--pitch); color: #FFFFFF; }
.btn-o { background: var(--surface); border-color: var(--field); color: var(--ink); }
.btn-o:hover { background: var(--line-2); color: var(--ink); }
.btn-d { background: var(--owe-fg); border-color: var(--owe-fg); color: #FFFFFF; }
.btn-d:hover { background: #7E2318; }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: 13px; }
.btn.block { width: 100%; }

/* ---- Thẻ, số liệu ---- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 20px; }
.card.flush { padding: 8px; }
.card.narrow { max-width: 480px; }
.pad { padding: 12px 12px 8px; }
.card-head { display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; align-items: center; }
.stack { display: flex; flex-direction: column; gap: 16px; }
.top-line { border-top: 1px solid var(--line-2); margin-top: 20px; padding-top: 20px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; }
.stat { display: flex; flex-direction: column; gap: 8px; }
.stat-label { font-size: 13px; color: var(--muted); }
.stat-value { font-family: var(--display); font-size: 36px; font-weight: 700; line-height: 1; font-variant-numeric: tabular-nums; }
.stat-value.sm { font-size: 30px; }
.stat-of { font-size: 22px; color: var(--muted); }
.stat-sub { font-size: 13px; color: var(--muted); }
.stat.dark { background: var(--pitch); border-color: var(--pitch); color: #FFFFFF; }
.stat.dark .stat-label { color: #B9D4C6; }
.stat.dark .stat-sub { color: var(--amber-soft); }
.progress { height: 8px; border-radius: 4px; background: var(--line-2); overflow: hidden; }
.progress > span { display: block; height: 100%; background: var(--green); }

.cols { display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-start; }
.col-main { flex: 2 1 480px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.col-main.wide { flex: 3 1 600px; gap: 0; }
.col-side { flex: 1 1 300px; min-width: 0; }
.col-side.card { display: flex; flex-direction: column; gap: 12px; }

/* ---- Bảng ---- */
.tbl-wrap { overflow-x: auto; }
.tbl { border-collapse: collapse; width: 100%; }
.tbl th { text-align: left; font-size: 12px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; padding: 10px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl td { padding: 12px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl .r { text-align: right; }
.tbl td.desc { min-width: 220px; }
.tbl tr.cancelled td { color: var(--muted); }
.tbl tr.cancelled td:nth-child(2) { text-decoration: line-through; }
.tbl tr.cancelled .nostrike { text-decoration: none; display: block; }
.tbl tr.cancelled .c-in, .tbl tr.cancelled .c-out { color: var(--muted); text-decoration: line-through; }
.dim { opacity: .7; }
.empty { padding: 28px 16px; text-align: center; color: var(--muted); }

.chip { display: inline-block; font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 999px; white-space: nowrap; }
.chip-in { background: var(--paid-bg); color: var(--paid-fg); }
.chip-out { background: var(--half-bg); color: var(--half-fg); }
.chip-na { background: var(--na-bg); color: #4F5E57; }
.pos { font-size: 12px; font-weight: 700; letter-spacing: .04em; padding: 3px 8px; border-radius: 6px; }
.pos-GK { background: var(--half-bg); color: var(--half-fg); }
.pos-DF { background: #DCE8F7; color: #1D4A7A; }
.pos-MF { background: var(--paid-bg); color: var(--paid-fg); }
.pos-FW { background: var(--owe-bg); color: var(--owe-fg); }
.jersey { font-family: var(--display); font-size: 22px; font-weight: 700; color: var(--pitch); }
.jersey-sm { display: inline-block; width: 28px; font-family: var(--display); font-size: 17px; font-weight: 700; color: var(--muted); }

/* ---- Bảng đóng quỹ ---- */
.dues th, .dues td { text-align: center; }
.dues td { padding: 6px; }
.dues .who { text-align: left; white-space: nowrap; padding-left: 12px; position: sticky; left: 0; z-index: 1; background: var(--surface); }
.dues .r { text-align: right; padding-right: 12px; }
.dues tfoot td { border-top: 1px solid var(--line); padding-top: 12px; padding-bottom: 12px; }
.cell { display: flex; align-items: center; justify-content: center; width: 100%; min-width: 56px; height: 40px; border-radius: 6px; border: 1px solid transparent; font: 700 13px var(--body); font-variant-numeric: tabular-nums; }
button.cell { cursor: pointer; }
button.cell:hover { filter: brightness(.95); box-shadow: 0 0 0 2px var(--pitch) inset; }
.paid { background: var(--paid-bg); color: var(--paid-fg); }
.half { background: var(--half-bg); color: var(--half-fg); }
.owe { background: var(--surface); color: var(--owe-fg); border-color: var(--owe-line); }
.future { background: var(--na-bg); color: var(--na-fg); }
.na { background: transparent; color: #A3B1AA; }
.dues th .yr { display: block; font-size: 10px; font-weight: 500; letter-spacing: 0; color: var(--muted); }
.dues th.now { color: var(--pitch); }
.dues th.now::after { content: ""; display: block; width: 18px; height: 3px; margin: 3px auto 0; border-radius: 2px; background: var(--amber); }
.h1-sub { font-size: .55em; font-weight: 600; color: var(--muted); letter-spacing: .01em; white-space: nowrap; }
.range-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; padding: 10px 12px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); }
.range-label { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.range-bar select { min-height: 40px; }

/* Ô tháng để tích chọn trong hộp thoại đóng quỹ */
.mchips { display: flex; flex-wrap: wrap; gap: 6px; }
.mchip { position: relative; cursor: pointer; }
.mchip input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.mchip span { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 62px; min-height: 48px; padding: 4px 8px; border: 1px solid var(--field); border-radius: 8px; background: var(--surface); line-height: 1.2; }
.mchip b { font-size: 14px; }
.mchip small { font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.mchip.is-owe span { border-color: var(--owe-line); }
.mchip.is-owe small { color: var(--owe-fg); }
.mchip input:checked + span { background: var(--pitch); border-color: var(--pitch); color: #FFFFFF; }
.mchip input:checked + span small { color: #CFE2D8; }
.mchip input:disabled { cursor: default; }
.mchip input:disabled + span { background: var(--paid-bg); border-color: transparent; color: var(--paid-fg); }
.mchip input:disabled + span small { color: var(--paid-fg); }
.mchip input:focus-visible + span { outline: 2px solid var(--amber); outline-offset: 2px; }

.legend { display: flex; flex-wrap: wrap; gap: 8px 16px; font-size: 13px; color: var(--ink-2); align-items: center; }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { display: inline-block; width: 18px; height: 14px; border-radius: 3px; }
.cell-sw.owe { border: 1px solid var(--owe-line); }
.cell-sw.na { border: 1px dashed #C2CEC8; }
.sw-in { background: var(--green); }
.sw-out { background: var(--amber); }

/* ---- Biểu đồ ---- */
.chart { display: flex; gap: 10px; margin-top: 16px; }
.chart-y { display: flex; flex-direction: column; justify-content: space-between; height: 168px; margin-top: -6px; width: 34px; font-size: 11px; color: var(--muted); text-align: right; }
.chart-plot { flex: 1; min-width: 0; }
.chart-bars { height: 160px; display: flex; align-items: flex-end; justify-content: space-around; border-bottom: 1px solid var(--field); background: repeating-linear-gradient(to top, transparent 0 39px, var(--line-2) 39px 40px); }
.chart-bars .g { display: flex; align-items: flex-end; gap: 4px; height: 100%; }
.chart-bars .b { width: 18px; min-height: 1px; border-radius: 3px 3px 0 0; }
.chart-x { display: flex; justify-content: space-around; margin-top: 8px; font-size: 12px; color: var(--muted); }
.chart-x span { width: 44px; text-align: center; }

.cat-group { margin-top: 4px; font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.opening-now { padding: 10px 12px; border-radius: 8px; background: var(--ground); }
.debtors { display: flex; flex-direction: column; }
.debtor { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line-2); }
.debtor:last-child { border-bottom: 0; }
.badge-no { width: 34px; height: 34px; flex: none; border-radius: 8px; background: var(--line-2); color: var(--pitch); display: flex; align-items: center; justify-content: center; font-family: var(--display); font-size: 18px; font-weight: 700; }

/* ---- Form ---- */
.form { display: flex; flex-direction: column; gap: 14px; }
.row2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--ink-2); min-width: 0; }
.hint { font-size: 12px; font-weight: 400; color: var(--muted); }
input:not([type=radio]):not([type=checkbox]):not([type=file]), select, textarea {
  width: 100%; min-height: 44px; padding: 0 12px; border: 1px solid var(--field); border-radius: 8px;
  font: 500 15px var(--body); color: var(--ink); background: var(--surface);
}
select.auto, .filters select, .actions select { width: auto; font-size: 14px; }
textarea { padding: 10px 12px; min-height: 72px; resize: vertical; }
input[type=file] { font: 500 14px var(--body); padding: 8px 0; }
input:disabled, select:disabled { background: var(--ground); color: var(--ink-2); }
input[type=radio], input[type=checkbox] { width: 18px; height: 18px; accent-color: var(--green); margin: 0; }
.check { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-weight: 500; color: var(--ink); cursor: pointer; }
.seg { display: flex; gap: 6px; }
.seg label { flex: 1; position: relative; cursor: pointer; }
.seg input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; cursor: pointer; }
.seg span { display: flex; align-items: center; justify-content: center; min-height: 44px; border: 1px solid var(--field); border-radius: 8px; font-size: 14px; font-weight: 600; color: var(--ink-2); background: var(--surface); }
.seg input:checked + span { background: var(--pitch); border-color: var(--pitch); color: #FFFFFF; }
.seg input:focus-visible + span { outline: 2px solid var(--amber); outline-offset: 2px; }
.seg.kind .in input:checked + span { background: var(--paid-bg); border-color: var(--in); color: var(--paid-fg); }
.seg.kind .out input:checked + span { background: var(--owe-bg); border-color: var(--out); color: var(--owe-fg); }
.filters { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; }
.search { position: relative; flex: 1 1 260px; min-width: 0; }
.search svg { position: absolute; left: 12px; top: 13px; color: var(--muted); }
.search input { padding-left: 40px !important; }
.tabs { display: inline-flex; gap: 4px; padding: 4px; border-radius: 10px; background: var(--line-2); }
.tabs a { display: inline-flex; align-items: center; min-height: 36px; padding: 0 14px; border-radius: 8px; font-weight: 600; color: var(--ink-2); text-decoration: none; }
.tabs a.on { background: var(--surface); color: var(--pitch); box-shadow: 0 1px 2px rgba(14, 59, 44, .15); }

.flash { padding: 12px 16px; border-radius: 8px; font-weight: 500; }
.flash-ok { background: var(--paid-bg); color: var(--paid-fg); }
.flash-err { background: var(--owe-bg); color: var(--owe-fg); }

/* ---- Hộp thoại ---- */
dialog { width: min(460px, calc(100vw - 32px)); max-height: calc(100vh - 32px); overflow-y: auto; padding: 0; border: 0; border-radius: 14px; color: var(--ink); background: var(--surface); box-shadow: 0 20px 60px rgba(14, 59, 44, .3); }
dialog::backdrop { background: rgba(14, 33, 27, .5); }
.dlg { padding: 20px; }
.dlg-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.dlg-title { font-size: 18px; font-weight: 700; margin-top: 4px; }
.pay-list { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px; border-radius: 8px; background: var(--ground); }
.pay-row { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.pay-row form { margin-left: auto; }
.qr { display: flex; gap: 12px; align-items: center; padding: 12px; border-radius: 8px; background: var(--ground); }
.qr img { width: 120px; height: 120px; flex: none; border-radius: 6px; background: #FFFFFF; object-fit: contain; }

/* ---- Lịch thi đấu ---- */
.col-side > .card { display: flex; flex-direction: column; gap: 12px; }
.page-tabs { align-self: flex-start; }
.page-tabs a { gap: 8px; min-height: 40px; }
.next-match { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; padding: 16px 20px; border-radius: 12px; background: var(--pitch); color: #FFFFFF; }
.nm-label { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--pitch); background: var(--amber); padding: 4px 10px; border-radius: 999px; }
.nm-main { flex: 1 1 260px; min-width: 0; }
.nm-date { font-size: 13px; color: #B9D4C6; }
.nm-vs { font-family: var(--display); font-size: 28px; font-weight: 700; line-height: 1.1; text-transform: uppercase; letter-spacing: .02em; }
.nm-vs em, .nc-vs em, .vs-preview em { font-style: normal; font-size: .6em; color: var(--amber-soft); margin: 0 6px; vertical-align: middle; }
.nm-meta { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 14px; color: #E8F1EC; }
.nm-meta span, .m-meta span, .m-goals { display: inline-flex; align-items: center; gap: 6px; }
.next-match .kit { color: #FFFFFF; }
.next-match .btn-o { background: transparent; color: #FFFFFF; border-color: #3E7A63; }
.month-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.month-title { font-family: var(--display); font-size: 24px; font-weight: 700; min-width: 140px; text-align: center; }
.month-gen { margin-left: auto; }
.match-list { display: flex; flex-direction: column; gap: 10px; }
.match { display: flex; align-items: center; gap: 16px; padding: 14px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; }
.match.is-empty { background: transparent; border-style: dashed; }
.match.is-cancel { opacity: .65; }
.match.is-cancel .m-team { text-decoration: line-through; }
.m-date { display: flex; flex-direction: column; align-items: center; width: 62px; flex: none; padding: 6px 0; border-radius: 10px; background: var(--ground); line-height: 1.1; }
.match.is-empty .m-date { background: var(--line-2); }
.m-wd { font-size: 11px; font-weight: 700; text-transform: uppercase; color: var(--muted); }
.m-day { font-family: var(--display); font-size: 28px; font-weight: 700; color: var(--pitch); }
.m-mon { font-size: 11px; color: var(--muted); }
.m-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.m-vs { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; font-size: 17px; }
.m-team { font-weight: 700; }
.m-x { font-size: 13px; font-weight: 600; color: var(--muted); }
.m-score { font-family: var(--display); font-size: 22px; font-weight: 700; padding: 0 8px; border-radius: 6px; background: var(--pitch); color: #FFFFFF; }
.m-meta { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 13px; color: var(--ink-2); }
.m-meta svg, .m-goals svg { color: var(--muted); flex: none; }
.m-goals { font-size: 13px; color: var(--ink); }
.m-side { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; flex: none; }
.kit { display: inline-flex; align-items: center; gap: 6px; }
.kit i, .kit-pick i { display: inline-block; width: 14px; height: 14px; border-radius: 50%; border: 1px solid rgba(20, 33, 27, .35); }
.res { display: inline-flex; align-items: center; justify-content: center; min-width: 26px; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; font-style: normal; }
.res-thang { background: var(--paid-bg); color: var(--paid-fg); }
.res-hoa { background: var(--na-bg); color: #3F4D46; }
.res-thua { background: var(--owe-bg); color: var(--owe-fg); }
.form-row { display: inline-flex; gap: 4px; margin-left: 4px; vertical-align: middle; }
.form-row .res { min-width: 24px; padding: 2px 6px; }
.wdl-bar { display: flex; height: 8px; border-radius: 4px; overflow: hidden; background: #24533F; }
.wdl-bar .w { background: #5BC48A; } .wdl-bar .d { background: #B9D4C6; } .wdl-bar .l { background: #E8826F; }
.result-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; }
.result-line .m-score { font-size: 17px; }
.tbl tr.top td { background: #FFF8E1; }
.show-sm { display: none; }
.next-card { text-decoration: none; color: var(--ink); gap: 6px !important; border-color: var(--amber); }
.next-card:hover { background: #FFFCF2; color: var(--ink); }
.nc-date { font-size: 13px; color: var(--muted); }
.nc-vs { font-family: var(--display); font-size: 22px; font-weight: 700; text-transform: uppercase; line-height: 1.15; }
.nc-vs em { color: var(--muted); }
/* Form trận */
.vs-preview { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px; padding: 12px 14px; border-radius: 10px; background: var(--ground); font-family: var(--display); font-size: 24px; font-weight: 700; text-transform: uppercase; }
.vs-preview em { color: var(--muted); }
.kit-pick { display: flex; flex-wrap: wrap; gap: 6px; }
.kit-pick label { position: relative; cursor: pointer; }
.kit-pick input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.kit-pick span { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; border: 1px solid var(--field); border-radius: 8px; background: var(--surface); font-weight: 600; color: var(--ink-2); }
.kit-pick input:checked + span { border-color: var(--pitch); box-shadow: inset 0 0 0 1px var(--pitch); color: var(--pitch); background: var(--paid-bg); }
.kit-pick input:focus-visible + span { outline: 2px solid var(--amber); outline-offset: 2px; }
.score-box { display: grid; grid-template-columns: minmax(0, 1fr) 64px auto 64px minmax(0, 1fr); align-items: center; gap: 8px; }
.sb-team { font-weight: 700; font-size: 14px; text-align: center; overflow-wrap: anywhere; }
.score-in { text-align: center; font-family: var(--display) !important; font-size: 28px !important; font-weight: 700 !important; min-height: 56px !important; padding: 0 !important; }
.sb-dash { font-family: var(--display); font-size: 28px; font-weight: 700; color: var(--muted); }
.goal-list { display: flex; flex-direction: column; gap: 8px; counter-reset: goal; }
/* Mỗi bàn thắng 2 dòng: [số] [người ghi bàn — trọn dòng, đủ họ tên] [xóa] / [kiến tạo] [phút] */
.goal-row { display: grid; grid-template-columns: 24px minmax(0, 1fr) 64px 40px; align-items: center; gap: 6px; padding-bottom: 8px; border-bottom: 1px solid var(--line-2); }
.goal-row .goal-no { grid-column: 1; grid-row: 1; }
.goal-row select[name="g_ghi[]"] { grid-column: 2 / 4; grid-row: 1; font-weight: 700 !important; }
.goal-row [data-goal-remove] { grid-column: 4; grid-row: 1; }
.goal-row select[name="g_kt[]"] { grid-column: 2; grid-row: 2; }
.goal-row input[name="g_phut[]"] { grid-column: 3; grid-row: 2; }
.goal-row select, .goal-row input { min-height: 40px !important; font-size: 14px !important; padding: 0 8px !important; }
.goal-no::before { counter-increment: goal; content: counter(goal); display: flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 50%; background: var(--pitch); color: #FFFFFF; font-size: 12px; font-weight: 700; }
/* Nhãn nổi bật: giờ đá, sân, màu áo */
.m-meta { gap: 8px; font-size: 15px; margin-top: 2px; }
.m-meta > span, .nm-meta > span { display: inline-flex; align-items: center; gap: 7px; padding: 5px 12px; border-radius: 999px; font-weight: 700; line-height: 1.2; }
.m-meta .mt-time { background: var(--pitch); color: #FFFFFF; font-size: 16px; }
.m-meta .mt-time svg { color: var(--amber-soft); }
.m-meta .mt-venue { background: var(--paid-bg); color: var(--paid-fg); }
.m-meta .mt-venue svg { color: var(--paid-fg); }
.m-meta .mt-kit { background: var(--surface); color: var(--ink); border: 1px solid var(--field); }
.m-meta .mt-kit svg { color: var(--ink-2); }
.m-meta.is-muted .mt-time { background: var(--na-bg); color: var(--ink-2); }
.m-meta.is-muted .mt-time svg { color: var(--muted); }
.m-meta.is-muted .mt-venue { background: var(--na-bg); color: var(--ink-2); }
.mt-kit .kit { gap: 6px; }
.mt-kit .kit i { width: 16px; height: 16px; }
.nm-meta { gap: 10px; font-size: 18px; }
.nm-meta .mt-time { background: var(--amber); color: var(--pitch); font-size: 20px; }
.nm-meta .mt-venue, .nm-meta .mt-kit { background: rgba(255, 255, 255, .12); color: #FFFFFF; }
.nm-meta .mt-kit .kit i { width: 18px; height: 18px; border-color: rgba(255, 255, 255, .6); }
.m-vs { font-size: 19px; }
.m-date { width: 66px; }
.m-day { font-size: 30px; }
.next-card .m-meta > span { font-size: 14px; }

/* ---- Tiêu điểm (trang chủ) ---- */
.spotlight { display: flex; flex-direction: column; gap: 12px; }
.sp-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-bottom: 8px; border-bottom: 2px solid var(--pitch); }
.sp-head h2 { display: flex; align-items: center; gap: 8px; font-family: var(--display); font-size: 24px; font-weight: 700; text-transform: uppercase; letter-spacing: .02em; color: var(--pitch); }
.sp-head h2 svg { color: var(--amber); }
#sp-title svg { fill: var(--amber); }
.sp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; align-items: start; }
.sp-card { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.sp-img { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--ground); }
.sp-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.sp-body { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px 16px; }
.sp-kicker { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--half-fg); }
.sp-title { margin: 0; font-size: 17px; font-weight: 700; line-height: 1.3; text-wrap: balance; }
.sp-text { font-size: 14px; color: var(--ink-2); max-height: 7.3em; overflow: hidden; overflow-wrap: anywhere; }
.sp-text.open { max-height: none; }
.sp-text a { font-weight: 600; }
.sp-more { align-self: flex-start; padding: 0; border: 0; background: none; color: var(--green); font: 600 13px var(--body); cursor: pointer; min-height: 32px; }
.sp-date a { font-weight: 600; }
.sp-empty { display: flex; align-items: center; gap: 8px; color: var(--ink-2); text-decoration: none; border-style: dashed; }
.sp-empty:hover { background: var(--surface); color: var(--pitch); }
.sp-bday { padding: 16px; gap: 12px; background: linear-gradient(160deg, #FFF8E1, #FFFFFF 70%); border-color: var(--amber); }
.sp-bday-head { display: flex; align-items: center; gap: 12px; color: var(--half-fg); }
.sp-bday-head .sp-title { color: var(--ink); }
.bd-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.bd-list li { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 8px; }
.bd-list li.is-past { opacity: .6; }
.bd-list li.is-today { background: var(--amber); }
.bd-day { min-width: 44px; font-family: var(--display); font-size: 18px; font-weight: 700; color: var(--pitch); }
.bd-name { flex: 1; min-width: 0; font-weight: 600; }
.bd-now { font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; padding: 2px 8px; border-radius: 999px; background: var(--pitch); color: #FFFFFF; }
/* Đầu trang chủ: Tiêu điểm (trái) | Trận sắp tới + Sinh nhật (phải) */
/* Hai cột cao bằng nhau: Tiêu điểm (2 phần) | Sắp diễn ra (1 phần) */
.top-row { display: grid; grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr); gap: 20px; align-items: stretch; }
.top-row .spotlight { min-width: 0; }
.top-side { min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.top-side .nx-card { flex: 1; }
.top-row.no-spot { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.top-row.no-spot .top-side { display: contents; }
/* Thẻ tiêu điểm nổi bật: ảnh hiện trọn (thu nhỏ vừa khung) bên trái, chữ bên phải */
.sp-feature { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); min-height: 260px; border-radius: 18px; overflow: hidden; color: #FFFFFF; text-decoration: none;
  background: radial-gradient(120% 140% at 100% 0%, #2A7A59 0%, #15513D 45%, #0B2E22 100%); box-shadow: 0 12px 32px rgba(14, 59, 44, .28); }
.sp-feature.has-img { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); }
.sp-feature::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 5px; z-index: 2; background: linear-gradient(90deg, var(--amber), #F2C94C, var(--amber)); }
.spf-media { position: relative; display: block; min-height: 260px; overflow: hidden; background: #081E16; }
.spf-backdrop { position: absolute; inset: -20px; background-size: cover; background-position: center; filter: blur(18px) brightness(.55); }
.spf-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.sp-feature.has-img .spf-body { align-self: center; }
.spf-star { position: absolute; right: -24px; top: -28px; color: var(--amber); opacity: .16; transform: rotate(14deg); }
.spf-star svg { fill: currentColor; }
.spf-body { position: relative; z-index: 1; display: flex; flex-direction: column; justify-content: flex-end; gap: 10px; padding: 26px 28px 24px; max-width: 680px; }
.spf-kicker { align-self: flex-start; display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px; background: var(--amber); color: var(--pitch); font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.spf-kicker svg { fill: currentColor; }
.spf-title { margin: 0; font-family: var(--display); font-size: 34px; font-weight: 700; line-height: 1.04; letter-spacing: .01em; text-transform: uppercase; text-wrap: balance; text-shadow: 0 2px 12px rgba(0, 0, 0, .25); }
.spf-text { font-size: 15px; line-height: 1.55; color: #E8F1EC; max-height: 4.7em; overflow: hidden; overflow-wrap: anywhere; }
.spf-text.open { max-height: none; }
.spf-text a { color: var(--amber-soft); }
.sp-feature .sp-more { color: var(--amber-soft); }
.spf-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; font-size: 13px; color: #B9D4C6; }
.spf-foot a { display: inline-flex; align-items: center; gap: 5px; color: #FFFFFF; font-weight: 600; }
.sp-feature.is-empty { min-height: 220px; border: 2px dashed rgba(224, 161, 0, .6); }
.sp-feature.is-empty:hover { filter: brightness(1.08); }
/* Các tin khác: thẻ nhỏ */
.sp-mini-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.sp-mini { display: flex; gap: 12px; padding: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; }
.spm-thumb { position: relative; width: 84px; height: 72px; flex: none; border-radius: 8px; overflow: hidden; background: var(--ground); display: flex; align-items: center; justify-content: center; }
.spm-thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.spm-thumb.is-icon { color: var(--amber); }
.spm-thumb.is-icon svg { fill: currentColor; }
.spm-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.spm-title { margin: 0; display: flex; align-items: center; gap: 4px; font-size: 15px; font-weight: 700; line-height: 1.3; }
.spm-text { font-size: 13px; color: var(--ink-2); max-height: 4.4em; overflow: hidden; overflow-wrap: anywhere; }
.spm-text.open { max-height: none; }
/* Thẻ trận sắp tới */
.nx-card { display: flex; flex-direction: column; gap: 10px; padding: 18px; border-radius: 16px; background: #FFF8E1; border: 2px solid var(--amber); box-shadow: 0 8px 22px rgba(224, 161, 0, .2); color: var(--ink); text-decoration: none; }
.nx-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.nx-label { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px; background: var(--pitch); color: #FFFFFF; font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.nx-count { font-family: var(--display); font-size: 20px; font-weight: 700; color: var(--half-fg); }
.nx-count.is-soon { color: var(--owe-fg); }
.nx-date { font-size: 14px; font-weight: 600; color: var(--ink-2); }
.nx-vs { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; font-family: var(--display); font-size: 30px; font-weight: 700; line-height: 1.05; text-transform: uppercase; color: var(--pitch); }
.nx-vs em { font-style: normal; font-size: .55em; color: var(--muted); }
.nx-btn { align-self: flex-start; }
.nx-card.is-empty { background: var(--surface); border-style: dashed; box-shadow: none; }
.top-side .sp-bday { box-shadow: none; }

@media (max-width: 1180px) {
  .top-row { grid-template-columns: minmax(0, 1fr); }
  .top-side .nx-card { flex: none; }
}
@media (max-width: 640px) {
  .sp-feature.has-img { grid-template-columns: minmax(0, 1fr); }
  .spf-media { min-height: 0; aspect-ratio: 4 / 3; }
}

/* Link "Xem trang khách" ở menu trái, mục Kiểm tra hệ thống */
.guest-link { display: flex; align-items: center; gap: 8px; margin-top: auto; padding: 10px 12px; border-radius: 8px; border: 1px dashed #3E7A63; color: #CFE2D8; text-decoration: none; font-size: 13px; font-weight: 600; }
.guest-link:hover { background: var(--pitch-2); color: #FFFFFF; }
.guest-link + .me { margin-top: 0; }
.syscheck { display: flex; flex-direction: column; gap: 12px; }
.syscheck.is-bad { border: 2px solid var(--owe-line); }
.sys-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.sys-grid > div { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 8px; background: var(--ground); }
@media (max-width: 900px) { .guest-link { order: 4; width: 100%; margin-top: 0; } }

/* ---- Trang khách (công khai) ---- */
.guest { min-height: 100vh; display: flex; flex-direction: column; background: var(--ground); }
.g-wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding-left: max(24px, env(safe-area-inset-left, 0px)); padding-right: max(24px, env(safe-area-inset-right, 0px)); }
.g-top { background: var(--pitch); position: sticky; top: 0; z-index: 20; }
.g-top-in { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 28px; padding-block: 12px; }
.g-brand { display: flex; align-items: center; gap: 12px; color: #FFFFFF; text-decoration: none; font-family: var(--display); font-size: 24px; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; }
.g-brand:hover { color: #FFFFFF; }
.g-nav { flex: 1; display: flex; flex-wrap: wrap; gap: 2px 20px; }
.g-nav a { color: #CFE2D8; text-decoration: none; font-weight: 600; padding: 8px 2px; }
.g-nav a:hover { color: #FFFFFF; }
.g-cta { background: var(--amber); color: var(--pitch); min-height: 40px; }
.g-cta:hover { background: #F2C94C; color: var(--pitch); }
.g-hero { background: radial-gradient(120% 160% at 100% 0%, #2A7A59 0%, #15513D 40%, #0B2E22 100%); color: #FFFFFF; }
.g-hero-in { display: flex; flex-wrap: wrap; align-items: center; gap: 32px; padding-block: 48px 56px; }
.g-hero-main { flex: 3 1 520px; min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 28px; }
.g-hero-logo { width: 180px; height: 180px; flex: none; filter: drop-shadow(0 10px 24px rgba(0, 0, 0, .35)); }
.g-hero-text { flex: 1 1 280px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.g-kicker { align-self: flex-start; padding: 4px 12px; border-radius: 999px; background: var(--amber); color: var(--pitch); font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.g-hero h1 { margin: 0; font-family: var(--display); font-size: 54px; line-height: 1; text-transform: uppercase; letter-spacing: .02em; }
.g-hero-text p { margin: 0; max-width: 540px; font-size: 16px; line-height: 1.6; color: #E8F1EC; }
.g-login p { margin: 0; line-height: 1.5; }
.g-facts { display: flex; flex-wrap: wrap; gap: 8px 22px; font-size: 14px; color: #CFE2D8; }
.g-facts strong { font-family: var(--display); font-size: 22px; color: var(--amber-soft); }
.g-login { flex: 1 1 300px; min-width: 0; max-width: 380px; padding: 24px; color: var(--ink); box-shadow: 0 18px 40px rgba(0, 0, 0, .3); display: flex; flex-direction: column; gap: 14px; }
.g-login-title { margin: 4px 0 0; font-size: 22px; font-weight: 800; }
.g-main { display: flex; flex-direction: column; gap: 40px; padding-block: 40px 48px; }
.g-main .sp-head { margin-bottom: 14px; }
.g-row { display: flex; flex-wrap: wrap; gap: 20px; align-items: stretch; }
.g-next { flex: 1 1 340px; min-width: 0; }
.g-list { flex: 1.4 1 420px; min-width: 0; padding: 4px 18px; }
.g-item { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line-2); }
.g-item:last-child { border-bottom: 0; }
.g-item.is-cancel { opacity: .6; }
.g-item.is-next .g-date { background: var(--amber); }
.g-date { width: 58px; flex: none; padding: 4px 0; border-radius: 10px; background: var(--ground); text-align: center; line-height: 1.1; }
.g-date span { display: block; font-size: 11px; font-weight: 700; text-transform: uppercase; color: var(--muted); }
.g-date strong { font-family: var(--display); font-size: 24px; color: var(--pitch); }
.g-vs { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; font-weight: 700; font-size: 16px; }
.g-vs .m-score { font-size: 18px; }
.mini-stats.g-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-bottom: 16px; }
.g-results { flex: 3 1 480px; }
.g-scorers { flex: 2 1 320px; min-width: 0; padding: 16px 18px; display: flex; flex-direction: column; gap: 4px; }
.g-scorers h3 { margin: 0 0 6px; display: flex; align-items: center; gap: 6px; font-size: 16px; }
.g-scorer { display: flex; align-items: center; gap: 10px; padding: 9px 8px; border-radius: 8px; }
.g-scorer.top { background: #FFF8E1; }
.g-rank { width: 22px; font-family: var(--display); font-size: 18px; font-weight: 700; color: var(--pitch); }
.g-minis { margin-top: 12px; }
.g-contact { display: flex; flex-wrap: wrap; align-items: center; gap: 18px 32px; padding: 22px 24px; border: 2px solid var(--pitch); }
.g-contact-text { flex: 1 1 320px; min-width: 0; }
.g-contact-text h2 { margin: 0; font-family: var(--display); font-size: 26px; text-transform: uppercase; color: var(--pitch); }
.g-contact-text p { margin: 6px 0 0; color: var(--ink-2); }
.g-people { display: flex; flex-wrap: wrap; gap: 14px; }
.g-person { display: flex; flex-direction: column; gap: 4px; min-width: 200px; padding: 12px 16px; border-radius: 12px; background: var(--ground); }
.g-phone { font-size: 18px; font-weight: 700; color: var(--pitch); }
.g-foot { margin-top: auto; background: var(--pitch); color: #9DBFAE; font-size: 13px; }
.g-foot-in { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding-block: 18px; }
.g-contact-row { grid-template-columns: 1fr 1.4fr 1.2fr; }
@media (max-width: 760px) {
  .g-nav { display: none; }
  .g-brand { font-size: 20px; flex: 1; }
  .g-cta { min-height: 38px; padding: 0 12px; font-size: 13px; }
  .g-hero-in { padding-block: 28px 32px; gap: 24px; }
  .g-hero-main { flex-direction: column; text-align: center; gap: 14px; }
  .g-hero-logo { width: 128px; height: 128px; }
  .g-kicker { align-self: center; }
  .g-hero h1 { font-size: 38px; }
  .g-facts { justify-content: center; }
  .g-login { max-width: none; }
  .mini-stats.g-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-main { gap: 28px; padding-block: 24px 32px; }
  .g-wrap { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
  .g-contact-row { grid-template-columns: 1fr; }
  .g-person { flex: 1 1 100%; }
}

/* Trang quản lý tiêu điểm */
.hl-row { display: flex; align-items: center; gap: 14px; padding: 12px 14px; }
.hl-thumb { width: 72px; height: 54px; flex: none; border-radius: 8px; overflow: hidden; background: var(--ground); display: flex; align-items: center; justify-content: center; color: var(--amber); }
.hl-thumb img { width: 100%; height: 100%; object-fit: cover; }
.hl-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.hl-title { display: flex; align-items: center; gap: 6px; font-weight: 700; font-size: 15px; }
.hl-pin { color: var(--half-fg); display: inline-flex; }
.hl-excerpt { font-size: 13px; color: var(--ink-2); }
.hl-actions { display: flex; align-items: center; gap: 6px; flex: none; }
.bd-toggle { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; border-radius: 8px; background: var(--ground); font-size: 14px; }
.debtor.bd-today { background: #FFF8E1; border-radius: 8px; padding-left: 6px; }
.hl-img-box { display: flex; flex-direction: column; gap: 8px; }
.hl-img-box img { max-width: 100%; max-height: 280px; width: auto; border-radius: 10px; object-fit: contain; align-self: flex-start; background: var(--ground); }

/* Trận sắp tới: tô nổi bật ngay trong danh sách lịch */
.match.is-next { border: 2px solid var(--amber); background: #FFF8E1; box-shadow: 0 4px 14px rgba(224, 161, 0, .18); }
.match.is-next .m-date { background: var(--amber); }
.match.is-next .m-wd, .match.is-next .m-mon { color: var(--pitch); }
.next-badge { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; background: var(--amber); color: var(--pitch); font-size: 13px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; }
.next-jump { display: inline-flex; align-items: center; padding: 4px 12px; border-radius: 999px; background: #FFF1C2; color: var(--pitch); font-size: 13px; font-weight: 700; text-decoration: none; }
.next-jump:hover { background: var(--amber); color: var(--pitch); }

/* Trang lịch thi đấu: lịch (trái) + kết quả & thống kê (phải) cùng lúc */
.matches-page { display: flex; flex-wrap: wrap; gap: 20px 24px; align-items: flex-start; }
.sched-col { flex: 3 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.stats-col { flex: 2 1 360px; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.col-title { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; min-height: 52px; padding-bottom: 8px; box-sizing: border-box; border-bottom: 2px solid var(--pitch); }
.col-title h2 { display: flex; align-items: center; gap: 8px; font-family: var(--display); font-size: 24px; font-weight: 700; text-transform: uppercase; letter-spacing: .02em; color: var(--pitch); }
.col-title h2 svg { color: var(--amber); }
.year-pick { display: flex; margin: 0; }
.year-pick select { min-height: 0; height: 40px; }
.month-note { display: flex; align-items: flex-start; gap: 8px; margin-top: 12px; padding: 12px 16px; border: 1px solid var(--amber-soft); border-radius: 10px; background: #FFF8E1; color: #5C3F00; font-size: 15px; font-weight: 500; }
.month-note strong { font-weight: 700; color: #6E4A00; }
.mini-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ms { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px; }
.ms.dark { background: var(--pitch); border-color: var(--pitch); color: #FFFFFF; }
.ms-label { font-size: 12px; font-weight: 600; color: var(--muted); }
.ms.dark .ms-label { color: #B9D4C6; }
.ms-value { font-family: var(--display); font-size: 30px; font-weight: 700; line-height: 1; }
.ms-value small { font-size: 16px; color: var(--muted); font-weight: 600; }
.ms.dark .ms-value small { color: #B9D4C6; }
.ms-sub { font-size: 12px; color: var(--muted); }
.ms.dark .ms-sub { color: var(--amber-soft); }
.side-card { display: flex; flex-direction: column; gap: 10px; padding: 16px; }
.side-card h3 { margin: 0; display: flex; align-items: center; gap: 6px; font-size: 15px; font-weight: 700; }
.side-card .tbl th, .side-card .tbl td { padding: 9px 8px; }
.side-card .empty { padding: 16px 8px; }
.res-list { display: flex; flex-direction: column; }
.res-item { position: relative; display: flex; flex-direction: column; gap: 4px; padding: 10px 0; border-bottom: 1px solid var(--line-2); }
.res-item:last-child { border-bottom: 0; }
.ri-top { display: flex; align-items: center; gap: 8px; }
.ri-date { font-size: 12px; color: var(--muted); }
.ri-edit { position: absolute; right: 0; top: 10px; }
.res-item .res { padding: 2px 8px; }
.more summary { cursor: pointer; font-weight: 600; color: var(--green); min-height: 36px; display: flex; align-items: center; }

/* Sửa cả tháng */
.apply-all { display: flex; flex-direction: column; gap: 12px; border-color: var(--amber); background: #FFFCF2; }
.aa-title { display: flex; align-items: center; gap: 8px; font-weight: 700; }
.aa-fields { display: grid; grid-template-columns: 120px minmax(0, 220px) minmax(0, 1fr); gap: 12px; align-items: end; }
.kit-pick.sm span { min-height: 40px; padding: 0 12px; font-size: 14px; }
.kit-pick.sm i { width: 16px; height: 16px; }
.bulk-list { display: flex; flex-direction: column; gap: 10px; }
.bulk-row { display: flex; align-items: flex-start; gap: 16px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; }
.bulk-row.is-cancel { opacity: .65; }
.bulk-fields { flex: 1; min-width: 0; display: grid; grid-template-columns: minmax(0, 2fr) 130px 90px minmax(0, 1.2fr); gap: 10px 12px; }
.bf-kit { grid-column: 1 / -1; }
.bf-opp input { font-weight: 700; font-size: 16px !important; }
.bulk-note { flex: none; }
.sticky-actions { position: sticky; bottom: 0; z-index: 5; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px)); margin: 0 -4px; border-radius: 12px 12px 0 0; background: var(--surface); border: 1px solid var(--line); box-shadow: 0 -6px 18px rgba(14, 59, 44, .08); }
.applied { animation: applied 1s ease-out; }
@keyframes applied { from { background: #FFF1C2; } to { background: transparent; } }
@media (prefers-reduced-motion: reduce) { .applied { animation: none; } }

.form-actions { flex: 1 1 100%; }
.push-right { margin-left: auto; }

/* ---- Đăng nhập, cài đặt ---- */
.login { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px 16px; background: var(--pitch); }
.login-card { width: min(400px, 100%); padding: 28px; }
.login-brand { display: flex; align-items: center; gap: 12px; }
.login-brand .brand-name { color: var(--pitch); }
.install { max-width: 640px; margin: 0 auto; padding: 32px 16px 56px; display: flex; flex-direction: column; gap: 16px; }

/* ---- Điện thoại ---- */
@media (max-width: 900px) {
  .shell { flex-direction: column; }
  .side { width: auto; height: auto; position: static; padding: 14px 16px 10px; gap: 10px; flex-direction: row; flex-wrap: wrap; align-items: center; overflow: visible; }
  .brand-name { font-size: 22px; }
  .brand .logo { width: 40px; height: 40px; }
  .brand-sub { display: none; }
  .me { margin: 0 0 0 auto; padding: 0; border: 0; }
  .me-text { display: none; }
  .nav { order: 3; flex: 1 1 100%; min-width: 0; flex-direction: row; overflow-x: auto; scrollbar-width: none; }
  .nav a { flex: none; padding: 8px 12px; }
  .main { padding: 20px 16px 48px; }
  h1 { font-size: 32px; }
  .stat-value { font-size: 30px; }
  .hide-sm { display: none; }
  .show-sm { display: block; }
  .match { flex-wrap: wrap; padding: 12px 14px; gap: 12px; }
  .m-date { width: 54px; }
  .m-side { flex-direction: row; align-items: center; width: 100%; justify-content: space-between; }
  .month-gen { margin-left: 0; }
  .goal-row { grid-template-columns: 24px minmax(0, 1fr) 56px 40px; }
  .aa-fields { grid-template-columns: 1fr 1fr; }
  .hl-row { flex-wrap: wrap; }
  .hl-actions { width: 100%; justify-content: flex-end; }
  .sp-grid { grid-template-columns: 1fr; }
  .sp-feature { min-height: 260px; border-radius: 14px; }
  .spf-body { padding: 20px 18px 18px; }
  .spf-title { font-size: 28px; }
  .nx-vs { font-size: 26px; }
  .aa-fields .field:last-child { grid-column: 1 / -1; }
  .bulk-row { flex-direction: column; gap: 10px; }
  .bulk-row .m-date { flex-direction: row; gap: 6px; width: auto; padding: 4px 12px; align-items: baseline; }
  .bulk-row .m-day { font-size: 22px; }
  .bulk-fields { grid-template-columns: 1fr 1fr; width: 100%; }
  .bf-opp, .bf-venue { grid-column: 1 / -1; }
  .m-meta { font-size: 14px; }
  .m-meta .mt-time { font-size: 15px; }
  .nm-meta { font-size: 16px; }
  .nm-meta .mt-time { font-size: 18px; }
  .tbl td, .tbl th { padding-left: 8px; padding-right: 8px; }
  .stat.dark .stat-value { font-size: 34px; }
}

/* ---- Đóng quỹ: thành viên tự chuyển khoản bằng mã VietQR ---- */
.me-dues { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; padding: 16px 20px; }
.me-dues.is-owe { border-color: var(--owe-line); background: #FFF7F5; }
.me-amount { font-family: var(--display); font-size: 30px; font-weight: 700; line-height: 1.1; }
.chip-me { background: var(--amber); color: #2B1E00; font-weight: 700; }
.dues tr.is-me td { background: #FFF8E1; }
.dues tr.is-me td.who { box-shadow: inset 4px 0 0 var(--amber); }
.qr-big { display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-start; padding: 14px; border-radius: 10px; background: var(--ground); }
.qr-big img { width: 200px; max-width: 100%; height: auto; aspect-ratio: 1; flex: none; border-radius: 8px; background: #FFFFFF; object-fit: contain; }
.qr-info { display: flex; flex-direction: column; gap: 12px; min-width: 0; flex: 1 1 180px; }
.qr-amount { font-family: var(--display); font-size: 28px; font-weight: 700; color: var(--pitch); }
.copy-line { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.copy-line strong { overflow-wrap: anywhere; }
@media (max-width: 520px) { .qr-big img { width: 100%; } }
