/* =====================================================================
   Tinkah · Event Checklist — theme theo Tinkah Design Spec
   Đổi màu thương hiệu: chỉ cần sửa các biến trong :root
   ===================================================================== */
:root {
  --blue: #0019FF;
  --blue-dark: #0012C2;
  --blue-soft: #E8EBFF;
  --blue-50: #F3F5FF;
  --ink: #0A0F3D;
  --ink-80: #0A0F3DCC;
  --ink-60: #0A0F3D99;
  --ink-45: #0A0F3D73;
  --line: #0A0F3D26;
  --line-2: #0A0F3D14;
  --bg: #F4F5F9;
  --card: #FFFFFF;
  --gray-box: #F2F3F7;

  --ok: #0F8A4B;   --ok-bg: #E3F6EB;
  --warn: #A15C00; --warn-bg: #FFF2DC;
  --bad: #D93036;  --bad-bg: #FDE8E9;
  --muted-bg: #ECEDF3;

  /* màu phân loại hạng mục */
  --c-buy: #0019FF;     --c-buy-bg: #E8EBFF;
  --c-rent: #7A2EEA;    --c-rent-bg: #F1E8FF;
  --c-stock: #0E7C7B;   --c-stock-bg: #DFF4F3;
  --c-service: #C25E00; --c-service-bg: #FFEEDC;
  --c-other: #5B6178;   --c-other-bg: #ECEDF3;

  --font: 'Inter Tight', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --r: 14px;
  --r-sm: 8px;
  --pill: 40px;
  --shadow: 0 1px 2px rgba(10, 15, 61, .05), 0 6px 24px rgba(10, 15, 61, .06);
  --shadow-lg: 0 24px 64px rgba(10, 15, 61, .22);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 14px/1.5 var(--font); -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; line-height: 1.1; }
.ic { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.muted { color: var(--ink-60); }
.small { font-size: 12px; }
.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.boot { display: grid; place-items: center; min-height: 100vh; color: var(--ink-60); }
.spacer { flex: 1; }
.hidden { display: none !important; }

/* eyebrow kiểu Tinkah: "(01)  CHECKLIST" */
.eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--blue); white-space: pre; }

/* ---------- Nút ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 18px; border-radius: var(--pill); border: 1.5px solid var(--ink);
  background: transparent; color: var(--ink); cursor: pointer; white-space: nowrap;
  font-size: 12px; font-weight: 800; letter-spacing: .03em; text-transform: uppercase;
  transition: background .15s, color .15s, border-color .15s, transform .05s;
}
.btn:hover { background: var(--ink); color: #fff; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn.primary:hover { background: var(--blue-dark); border-color: var(--blue-dark); }
.btn.ok { background: var(--ok); border-color: var(--ok); color: #fff; }
.btn.ok:hover { filter: brightness(.92); }
.btn.warn { border-color: var(--warn); color: var(--warn); }
.btn.warn:hover { background: var(--warn); color: #fff; }
.btn.danger { border-color: var(--bad); color: var(--bad); }
.btn.danger:hover { background: var(--bad); color: #fff; }
.btn.soft { border-color: transparent; background: var(--blue-soft); color: var(--blue); }
.btn.soft:hover { background: var(--blue); color: #fff; }
.btn.sm { padding: 7px 13px; font-size: 11px; }
.btn.block { width: 100%; }
.icon-btn {
  display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%;
  border: 0; background: transparent; color: var(--ink-60); cursor: pointer;
}
.icon-btn:hover { background: var(--gray-box); color: var(--ink); }
.link { background: none; border: 0; padding: 0; color: var(--blue); font-weight: 700; cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }

/* ---------- Chip / Badge ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: var(--pill);
  border: 1px solid var(--line); background: var(--card); cursor: pointer; font-size: 13px; font-weight: 600;
}
.chip:hover { border-color: var(--ink); }
.chip.on { background: var(--blue); border-color: var(--blue); color: #fff; }
.chip .n { font-size: 11px; font-weight: 700; opacity: .65; }
.badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: var(--pill);
  font-size: 12px; font-weight: 700; white-space: nowrap;
}
.badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge.nodot::before { display: none; }
.s-draft    { background: var(--muted-bg); color: var(--ink-80); }
.s-pending  { background: var(--warn-bg); color: var(--warn); }
.s-changes  { background: var(--bad-bg); color: var(--bad); }
.s-approved { background: var(--ok-bg); color: var(--ok); }
.cat { display: inline-block; padding: 3px 9px; border-radius: var(--pill); font-size: 11.5px; font-weight: 700; white-space: nowrap; }
.cat-buy     { background: var(--c-buy-bg); color: var(--c-buy); }
.cat-rent    { background: var(--c-rent-bg); color: var(--c-rent); }
.cat-stock   { background: var(--c-stock-bg); color: var(--c-stock); }
.cat-service { background: var(--c-service-bg); color: var(--c-service); }
.cat-other   { background: var(--c-other-bg); color: var(--c-other); }
.role-pending { background: var(--muted-bg); color: var(--ink-60); }
.role-member  { background: var(--blue-soft); color: var(--blue); }
.role-bod     { background: var(--ok-bg); color: var(--ok); }
.role-admin   { background: var(--ink); color: #fff; }

/* ---------- Khung trang ---------- */
.demo-bar {
  background: var(--ink); color: #DCE0FF; font-size: 12.5px; padding: 8px 40px; text-align: center;
}
.demo-bar b { color: #fff; }
.demo-bar code { background: rgba(255,255,255,.12); padding: 1px 6px; border-radius: 4px; color: #fff; }
.demo-bar .link { color: #fff; margin-left: 6px; }
.topbar {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 28px;
  padding: 12px 40px; background: rgba(255,255,255,.92); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line-2);
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand img { height: 26px; width: auto; display: block; }
.brand-sub { font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-60); padding-left: 12px; border-left: 1px solid var(--line); line-height: 1.2; }
.nav { display: flex; gap: 4px; }
.nav a { padding: 8px 14px; border-radius: var(--pill); font-weight: 700; font-size: 13px; color: var(--ink-60); }
.nav a:hover { color: var(--ink); background: var(--gray-box); }
.nav a.on { color: var(--blue); background: var(--blue-soft); }
.me-btn { margin-left: auto; display: flex; align-items: center; gap: 10px; background: none; border: 0; cursor: pointer; padding: 4px 6px 4px 4px; border-radius: var(--pill); }
.me-btn:hover { background: var(--gray-box); }
.me-text { display: flex; flex-direction: column; text-align: left; line-height: 1.25; }
.me-text b { font-size: 13px; }
.me-text small { font-size: 11px; color: var(--ink-60); font-weight: 600; }
.avatar {
  display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; flex: none;
  background: var(--blue); color: #fff; font-weight: 800; font-size: 12px; letter-spacing: .02em;
}
.avatar.sm { width: 28px; height: 28px; font-size: 11px; }
.main { max-width: 1360px; margin: 0 auto; padding: 32px 40px 80px; }

.page-head { display: flex; align-items: flex-end; gap: 24px; margin-bottom: 24px; flex-wrap: wrap; }
.page-head h1 { font-size: clamp(30px, 4vw, 48px); font-weight: 900; letter-spacing: -.035em; text-transform: uppercase; margin-top: 6px; }
.page-head p { margin: 8px 0 0; color: var(--ink-80); max-width: 640px; }
.page-head .actions { margin-left: auto; display: flex; gap: 10px; flex-wrap: wrap; }

.toolbar { display: flex; gap: 12px; align-items: center; margin-bottom: 20px; flex-wrap: wrap; }
.search { position: relative; flex: 0 1 300px; }
.search .ic { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--ink-45); }
.search input {
  width: 100%; padding: 9px 14px 9px 38px; border-radius: var(--pill); border: 1px solid var(--line); background: var(--card); outline: none;
}
.search input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }

.card { background: var(--card); border: 1px solid var(--line-2); border-radius: var(--r); box-shadow: var(--shadow); }
.card-head { display: flex; align-items: center; gap: 12px; padding: 18px 22px; border-bottom: 1px solid var(--line-2); flex-wrap: wrap; }
.card-head h2 { font-size: 16px; font-weight: 800; letter-spacing: -.01em; }
.card-head .count { display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px; margin-left: 6px; border-radius: 11px; background: var(--gray-box); font-size: 12px; color: var(--ink-60); vertical-align: 2px; }
.card-body { padding: 20px 22px; }

.empty { text-align: center; padding: 56px 20px; color: var(--ink-60); }
.empty .big { font-size: 22px; font-weight: 900; color: var(--ink); letter-spacing: -.02em; margin-bottom: 6px; text-transform: uppercase; }
.loading { padding: 60px; text-align: center; color: var(--ink-60); }

/* ---------- Danh sách event ---------- */
.ev-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 20px; }
.ev-card {
  display: flex; flex-direction: column; gap: 12px; padding: 20px 22px; background: var(--card);
  border: 1px solid var(--line-2); border-radius: var(--r); box-shadow: var(--shadow);
  transition: border-color .15s, transform .15s, box-shadow .15s;
}
.ev-card:hover { border-color: var(--blue); transform: translateY(-2px); box-shadow: 0 10px 32px rgba(0, 25, 255, .12); }
.ev-card-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.ev-card h3 { font-size: 20px; font-weight: 900; letter-spacing: -.025em; }
.meta { display: flex; flex-wrap: wrap; gap: 6px 16px; color: var(--ink-60); font-size: 13px; }
.meta span { display: inline-flex; align-items: center; gap: 6px; }
.meta .ic { width: 14px; height: 14px; }
.ev-money { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.ev-money b { font-size: 22px; font-weight: 900; letter-spacing: -.02em; }
.bar { height: 6px; border-radius: 3px; background: var(--gray-box); overflow: hidden; }
.bar > span { display: block; height: 100%; background: var(--blue); border-radius: 3px; }
.bar.over > span { background: var(--bad); }
.bar.ok > span { background: var(--ok); }
.ev-foot { display: flex; justify-content: space-between; gap: 8px; font-size: 12.5px; color: var(--ink-60); border-top: 1px dashed var(--line); padding-top: 12px; }
.ev-foot b { color: var(--ink); }

/* ---------- Chi tiết event ---------- */
.back { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; font-size: 13px; color: var(--ink-60); margin-bottom: 16px; }
.back:hover { color: var(--blue); }
.hero { padding: 26px 28px; margin-bottom: 20px; }
.hero-top { display: flex; gap: 20px; align-items: flex-start; flex-wrap: wrap; }
.hero h1 { font-size: clamp(28px, 3.6vw, 44px); font-weight: 900; letter-spacing: -.035em; margin: 8px 0 12px; }
.hero .meta { font-size: 14px; }
.hero-actions { margin-left: auto; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.hero-actions .row { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.callout { display: flex; gap: 12px; align-items: flex-start; margin-top: 20px; padding: 14px 16px; border-radius: 10px; font-size: 13.5px; }
.callout .ic { width: 18px; height: 18px; margin-top: 1px; }
.callout.pending { background: var(--warn-bg); color: #6B3D00; }
.callout.changes { background: var(--bad-bg); color: #8A1C21; }
.callout.approved { background: var(--ok-bg); color: #0A5C32; }
.callout q { font-weight: 700; }

.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 20px; }
.kpi { padding: 18px 20px; display: flex; flex-direction: column; gap: 6px; }
.kpi .lbl { font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-60); }
.kpi .val { font-size: 26px; font-weight: 900; letter-spacing: -.03em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.kpi .sub { font-size: 12.5px; color: var(--ink-60); }
.kpi .sub b.ok { color: var(--ok); }
.kpi .sub b.bad { color: var(--bad); }
.kpi.accent { background: var(--blue); color: #fff; border-color: var(--blue); }
.kpi.accent .lbl, .kpi.accent .sub { color: #DCE0FF; }

.breakdown { padding: 16px 22px 18px; border-bottom: 1px solid var(--line-2); }
.stack { display: flex; height: 10px; border-radius: 5px; overflow: hidden; background: var(--gray-box); gap: 2px; }
.stack span { display: block; height: 100%; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 20px; margin-top: 12px; font-size: 12.5px; }
.legend span { display: inline-flex; align-items: center; gap: 7px; color: var(--ink-80); }
.legend i { width: 10px; height: 10px; border-radius: 3px; }
.legend b { color: var(--ink); font-variant-numeric: tabular-nums; }
.bg-buy { background: var(--c-buy); } .bg-rent { background: var(--c-rent); } .bg-stock { background: var(--c-stock); }
.bg-service { background: var(--c-service); } .bg-other { background: var(--c-other); }

.items-tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-left: auto; justify-content: flex-end; }
.items-tools .search { flex: 0 0 240px; }
.table-wrap { overflow-x: auto; }
table.items { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.items th {
  text-align: left; font-size: 11px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-60);
  padding: 10px 12px; border-bottom: 1px solid var(--line); background: #FAFAFC; white-space: nowrap;
}
table.items th.num { text-align: right; }
table.items th.c-done { text-align: center; }
table.items td { padding: 12px; border-bottom: 1px solid var(--line-2); vertical-align: top; }
table.items tbody tr { cursor: pointer; }
table.items tbody tr:hover td { background: var(--blue-50); }
table.items tr.is-done .it-name { text-decoration: line-through; text-decoration-color: var(--ink-45); color: var(--ink-60); }
table.items tfoot td { font-weight: 800; background: var(--blue-soft); border-bottom: 0; padding: 14px 12px; }
.it-name { font-weight: 700; }
.it-sub { font-size: 12px; color: var(--ink-60); margin-top: 2px; word-break: break-word; }
.it-sub a { color: var(--blue); text-decoration: underline; }
.it-note { color: var(--ink-80); font-size: 12.5px; max-width: 280px; white-space: pre-wrap; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.c-done { width: 44px; text-align: center; }
.c-idx { width: 36px; color: var(--ink-45); font-variant-numeric: tabular-nums; }
.tick { appearance: none; width: 20px; height: 20px; border: 1.5px solid var(--ink-45); border-radius: 6px; cursor: pointer; display: inline-grid; place-items: center; background: #fff; margin: 0; vertical-align: middle; }
.tick:checked { background: var(--ok); border-color: var(--ok); }
.tick:checked::after { content: ''; width: 9px; height: 5px; border: 2px solid #fff; border-top: 0; border-right: 0; transform: rotate(-45deg) translate(1px, -1px); }
.tick:disabled { cursor: not-allowed; opacity: .55; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 20px; }
.note-area {
  width: 100%; min-height: 200px; resize: vertical; border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px;
  outline: none; line-height: 1.6; background: #fff;
}
.note-area:focus { border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }
.note-area:disabled { background: var(--gray-box); color: var(--ink-80); }
.save-state { font-size: 12px; color: var(--ink-60); margin-left: auto; }

.timeline { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 16px; max-height: 420px; overflow-y: auto; }
.timeline li { display: flex; gap: 12px; }
.timeline .body { flex: 1; min-width: 0; }
.timeline .head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; font-size: 13px; }
.timeline .time { color: var(--ink-45); font-size: 12px; }
.timeline .msg { margin-top: 6px; padding: 10px 12px; background: var(--gray-box); border-radius: 4px 12px 12px 12px; white-space: pre-wrap; word-break: break-word; font-size: 13.5px; }
.act { font-size: 11.5px; font-weight: 700; padding: 2px 8px; border-radius: var(--pill); background: var(--gray-box); color: var(--ink-80); }
.act-submit { background: var(--warn-bg); color: var(--warn); }
.act-approve { background: var(--ok-bg); color: var(--ok); }
.act-changes { background: var(--bad-bg); color: var(--bad); }
.comment-form { display: flex; gap: 10px; margin-top: 18px; align-items: flex-end; }
.comment-form textarea { flex: 1; min-height: 44px; max-height: 160px; resize: vertical; border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; outline: none; }
.comment-form textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }

/* ---------- Thành viên ---------- */
table.users { width: 100%; border-collapse: collapse; }
table.users th { text-align: left; font-size: 11px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-60); padding: 12px 22px; border-bottom: 1px solid var(--line); }
table.users td { padding: 12px 22px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.user-cell { display: flex; align-items: center; gap: 12px; }
.roles-help { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 20px; }
.roles-help .card { padding: 16px 18px; font-size: 13px; color: var(--ink-80); }
.roles-help .badge { margin-bottom: 8px; }

/* ---------- Form ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; }
.f { display: flex; flex-direction: column; gap: 6px; font-size: 12px; font-weight: 700; color: var(--ink-80); }
.f.full, .full { grid-column: 1 / -1; }
.f input, .f select, .f textarea {
  width: 100%; padding: 10px 14px; border: 1px solid var(--line); border-radius: 10px; background: #fff;
  font-size: 14px; font-weight: 500; color: var(--ink); outline: none;
}
.f textarea { resize: vertical; line-height: 1.5; }
.f input:focus, .f select:focus, .f textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-soft); }
.f input:disabled, .f select:disabled, .f textarea:disabled { background: var(--gray-box); color: var(--ink-80); }
.f .hint { font-weight: 500; color: var(--ink-60); }
.chk { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; cursor: pointer; font-size: 14px; }
.total-line { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; background: var(--blue-soft); border-radius: 10px; font-weight: 700; color: var(--ink); }
.total-line b { font-size: 20px; font-weight: 900; color: var(--blue); font-variant-numeric: tabular-nums; }
.form-error { color: var(--bad); font-weight: 600; font-size: 13px; margin: 12px 0 0; }
.summary-box { display: grid; grid-template-columns: 1fr auto; gap: 6px 16px; padding: 14px 16px; background: var(--gray-box); border-radius: 10px; margin-bottom: 16px; font-size: 13.5px; }
.summary-box b { text-align: right; font-variant-numeric: tabular-nums; }

/* ---------- Hộp thoại ---------- */
.dlg {
  border: 0; padding: 0; border-radius: 18px; width: min(560px, calc(100vw - 24px)); max-height: calc(100vh - 32px);
  box-shadow: var(--shadow-lg); color: var(--ink);
}
.dlg.wide { width: min(720px, calc(100vw - 24px)); }
.dlg::backdrop { background: rgba(10, 15, 61, .45); backdrop-filter: blur(3px); }
.dlg-form { display: flex; flex-direction: column; max-height: calc(100vh - 32px); }
.dlg-head { display: flex; align-items: center; gap: 12px; padding: 20px 24px 14px; }
.dlg-head h2 { font-size: 20px; font-weight: 900; letter-spacing: -.02em; flex: 1; }
.dlg-body { padding: 4px 24px 20px; overflow-y: auto; }
.dlg-body > p { margin: 0 0 14px; color: var(--ink-80); }
.dlg-foot { display: flex; gap: 10px; align-items: center; padding: 16px 24px; border-top: 1px solid var(--line-2); background: #FAFAFC; flex-wrap: wrap; }

/* ---------- Đăng nhập ---------- */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }
.auth-art {
  background: var(--blue); color: #fff; padding: 48px 56px; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden;
}
.auth-art img { width: 180px; }
.auth-art h1 { font-size: clamp(40px, 5.6vw, 84px); font-weight: 900; letter-spacing: -.045em; line-height: 1; text-transform: uppercase; }
.auth-art p { color: #DCE0FF; max-width: 440px; font-size: 15px; }
.auth-art .spark { position: absolute; right: -40px; top: 34%; width: 260px; opacity: .14; }
.auth-side { display: grid; place-items: center; padding: 32px 24px; background: #fff; }
.auth-card { width: min(400px, 100%); }
.auth-card h2 { font-size: 28px; font-weight: 900; letter-spacing: -.03em; margin: 8px 0 6px; text-transform: uppercase; }
.auth-card > p { color: var(--ink-60); margin: 0 0 22px; }
.auth-card form { display: flex; flex-direction: column; gap: 14px; }
.tabs { display: flex; gap: 6px; padding: 4px; background: var(--gray-box); border-radius: var(--pill); margin-bottom: 22px; }
.tabs button { flex: 1; padding: 9px; border: 0; border-radius: var(--pill); background: none; font-weight: 800; font-size: 12px; text-transform: uppercase; letter-spacing: .03em; cursor: pointer; color: var(--ink-60); }
.tabs button.on { background: #fff; color: var(--ink); box-shadow: 0 1px 4px rgba(10,15,61,.12); }
.btn-google {
  display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; padding: 13px 18px;
  border: 1.5px solid var(--ink); border-radius: var(--pill); background: #fff; cursor: pointer;
  font-weight: 700; font-size: 15px; color: var(--ink); transition: background .15s, box-shadow .15s;
}
.btn-google:hover { background: var(--blue-50); box-shadow: 0 0 0 3px var(--blue-soft); }
.btn-google:disabled { opacity: .6; cursor: wait; }
.btn-google small { color: var(--ink-60); font-weight: 600; font-size: 13px; }
.divider { display: flex; align-items: center; gap: 12px; margin: 22px 0 16px; color: var(--ink-45); font-size: 12px; font-weight: 600; }
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.mail-to { margin: 14px 0 0; padding: 10px 14px; border-radius: 10px; background: var(--blue-50); color: var(--ink-80); font-size: 13px; }
.demo-users { display: flex; flex-direction: column; gap: 10px; }
.demo-user { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: #fff; cursor: pointer; text-align: left; }
.demo-user:hover { border-color: var(--blue); background: var(--blue-50); }
.demo-user .who { flex: 1; display: flex; flex-direction: column; }
.demo-user .who small { color: var(--ink-60); font-size: 12px; }

/* ---------- Thông báo ---------- */
.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 12px; font-weight: 600; font-size: 13.5px;
  box-shadow: var(--shadow-lg); transition: opacity .2s, transform .2s; z-index: 100; max-width: calc(100vw - 32px);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.error { background: var(--bad); }
.toast.ok { background: var(--ok); }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .roles-help { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
  .grid-2 { grid-template-columns: 1fr; }
  .auth { grid-template-columns: 1fr; }
  .auth-art { padding: 28px 24px; min-height: 0; gap: 28px; }
  .auth-art img { width: 120px; }
  .auth-art .spark { display: none; }
  .hero-actions { margin-left: 0; align-items: flex-start; width: 100%; }
  .hero-actions .row { justify-content: flex-start; }
}
@media (max-width: 760px) {
  .topbar { padding: 10px 16px; gap: 12px; }
  .brand-sub, .me-text { display: none; }
  .brand img { height: 22px; }
  .demo-bar { padding: 8px 16px; }
  .main { padding: 20px 16px 64px; }
  .page-head .actions { margin-left: 0; width: 100%; }
  .page-head .actions .btn { flex: 1; }
  .search { flex: 1 1 100%; }
  .ev-grid { grid-template-columns: 1fr; }
  .hero { padding: 20px; }
  .kpis { gap: 10px; }
  .kpi { padding: 14px; }
  .kpi .val { font-size: 20px; }
  .card-head { padding: 14px 16px; }
  .card-body, .breakdown { padding-left: 16px; padding-right: 16px; }
  .items-tools { margin-left: 0; width: 100%; }
  .form-grid { grid-template-columns: 1fr; }
  .roles-help { grid-template-columns: 1fr; }
  /* bảng → thẻ */
  table.items thead { display: none; }
  table.items, table.items tbody, table.items tfoot, table.items tr, table.items td { display: block; width: 100%; }
  table.items tbody tr { position: relative; padding: 12px 16px 12px 52px; border-bottom: 1px solid var(--line-2); }
  table.items td { border: 0; padding: 2px 0; }
  table.items td.c-done { position: absolute; left: 14px; top: 14px; width: auto; }
  table.items td.c-idx, table.items td.c-act { display: none; }
  table.items td[data-l]::before { content: attr(data-l) ': '; color: var(--ink-60); font-size: 12px; font-weight: 600; }
  table.items td.num { text-align: left; }
  table.items td.num[data-l] { display: inline-block; width: auto; margin-right: 14px; font-size: 13px; }
  table.items td.c-total { font-size: 15px; }
  table.items td:empty { display: none; }
  table.items tfoot tr { display: flex; justify-content: space-between; padding: 0; }
  table.items tfoot td { width: auto; }
  table.items tfoot td.hide-m { display: none; }
  table.users thead { display: none; }
  table.users, table.users tbody, table.users tr, table.users td { display: block; width: 100%; }
  table.users tr { padding: 12px 16px; border-bottom: 1px solid var(--line-2); }
  table.users td { border: 0; padding: 4px 0; }
}
