:root {
  --bg: #f4f6fa;
  --card: #ffffff;
  --line: #e4e9f2;
  --ink: #172033;
  --muted: #667085;
  --muted-2: #98a2b3;
  --primary: #d71920;
  --primary-dark: #b31217;
  --primary-soft: #fdecec;
  --ok: #047857;
  --ok-bg: #ecfdf5;
  --warn: #b45309;
  --warn-bg: #fffbeb;
  --danger: #b91c1c;
  --danger-bg: #fef2f2;
  --sidebar: #0b1f45;
  --sidebar-2: #071632;
  --navy: #16305e;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 8px 24px -18px rgba(16, 24, 40, .22);
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "PingFang SC", "Microsoft YaHei", "Segoe UI", system-ui, -apple-system, sans-serif;
  font-size: 14px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4, p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }

/* ------------------------------- Auth page ------------------------------ */

body.is-auth {
  background:
    radial-gradient(1200px 600px at 12% 8%, rgba(215, 25, 32, .28), transparent 55%),
    radial-gradient(900px 500px at 88% 92%, rgba(30, 64, 175, .30), transparent 55%),
    linear-gradient(135deg, #071632 0%, #0b1f45 55%, #122a52 100%);
}

.auth-wrap {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(380px, .9fr);
  align-items: center;
  gap: 48px;
  padding: 56px 8vw;
}

.auth-hero { color: #e7eefc; max-width: 560px; }

.auth-hero .eyebrow {
  display: inline-block;
  font-size: 12px;
  letter-spacing: .16em;
  color: #ffc2c4;
  border: 1px solid rgba(255, 194, 196, .38);
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 22px;
}

.auth-hero h1 {
  font-size: clamp(28px, 3.4vw, 42px);
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: .01em;
}

.auth-hero p {
  margin-top: 16px;
  color: #a7b4cc;
  font-size: 15px;
  line-height: 1.8;
}

.auth-points {
  margin-top: 34px;
  display: grid;
  gap: 14px;
}

.auth-points div {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  color: #c9d4e6;
  font-size: 14px;
}

.auth-points i {
  flex: none;
  width: 22px;
  height: 22px;
  border-radius: 7px;
  background: rgba(215, 25, 32, .30);
  color: #ffd2d3;
  font-style: normal;
  font-size: 12px;
  display: grid;
  place-items: center;
  margin-top: 1px;
}

.auth-card {
  background: #fff;
  border-radius: 20px;
  padding: 38px 36px 34px;
  box-shadow: 0 30px 80px -30px rgba(2, 8, 23, .65);
  border: 1px solid rgba(255, 255, 255, .5);
  width: 100%;
  max-width: 430px;
  justify-self: end;
}

.auth-logo {
  display: block;
  width: 190px;
  max-width: 100%;
  height: auto;
  margin: 0 auto 18px;
}

.auth-card h2 { font-size: 22px; font-weight: 700; }
.auth-card .auth-sub { color: var(--muted); margin-top: 6px; font-size: 13px; }

.auth-form { margin-top: 26px; display: grid; gap: 16px; }

.auth-card .btn { width: 100%; padding: 11px 16px; font-size: 15px; }

.auth-hint {
  margin-top: 22px;
  border-top: 1px dashed var(--line);
  padding-top: 16px;
  color: var(--muted-2);
  font-size: 12px;
  line-height: 1.7;
}

.auth-hint strong { color: var(--muted); font-weight: 600; }

/* -------------------------------- Layout -------------------------------- */

.app { display: flex; min-height: 100vh; }

.sidebar {
  width: 238px;
  flex: none;
  background: linear-gradient(180deg, var(--sidebar) 0%, var(--sidebar-2) 100%);
  color: #c7d2e5;
  display: flex;
  flex-direction: column;
  padding: 22px 14px 18px;
  position: sticky;
  top: 0;
  height: 100vh;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 4px 10px 22px;
}

.brand-logo {
  width: 66px;
  height: 40px;
  flex: none;
  border-radius: 10px;
  background: #fff;
  padding: 5px 6px;
  display: grid;
  place-items: center;
  box-shadow: 0 6px 16px -10px rgba(0, 0, 0, .55);
}

.brand-logo img {
  display: block;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.brand-text { display: flex; flex-direction: column; line-height: 1.35; }
.brand-text strong { color: #f2f6ff; font-size: 15px; font-weight: 600; letter-spacing: .02em; }
.brand-text span { color: #7c8db0; font-size: 11px; letter-spacing: .14em; margin-top: 2px; }

.nav { flex: 1; display: flex; flex-direction: column; gap: 3px; margin-top: 4px; overflow-y: auto; }

.nav-label {
  color: #5d6f94;
  font-size: 11px;
  letter-spacing: .16em;
  padding: 18px 12px 7px;
}

.nav-item {
  color: #b8c5dc;
  padding: 9px 12px;
  border-radius: 9px;
  font-size: 13.5px;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: background .15s, color .15s;
}

.nav-item::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #33415c;
  transition: background .15s;
}

.nav-item:hover { background: rgba(255, 255, 255, .06); color: #eaf1ff; text-decoration: none; }
.nav-item.active { background: rgba(215, 25, 32, .20); color: #fff; font-weight: 600; }
.nav-item.active::before { background: #f87171; box-shadow: 0 0 0 3px rgba(248, 113, 113, .20); }

.sidebar-foot {
  margin-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  padding: 14px 12px 2px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #7c8db0;
  font-size: 11.5px;
}

.sidebar-foot strong { color: #c7d2e5; font-weight: 600; }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

.topbar {
  background: rgba(255, 255, 255, .88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  padding: 16px 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  position: sticky;
  top: 0;
  z-index: 30;
}

.topbar-title h1 { font-size: 20px; font-weight: 700; letter-spacing: .01em; }
.topbar-title p { color: var(--muted); font-size: 12.5px; margin-top: 3px; min-height: 18px; }

.user-chip { display: flex; align-items: center; gap: 10px; }

.avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary-soft);
  color: var(--primary-dark);
  font-weight: 700;
  display: grid;
  place-items: center;
  font-size: 15px;
  flex: none;
}

.user-meta { display: flex; flex-direction: column; line-height: 1.3; }
.user-name { font-size: 13px; font-weight: 600; color: var(--ink); }
.user-role { font-size: 11.5px; color: var(--muted-2); }

.content {
  padding: 26px 34px 36px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  flex: 1;
}

.page-footer {
  margin-top: auto;
  padding-top: 18px;
  color: var(--muted-2);
  font-size: 11.5px;
  text-align: center;
}

/* -------------------------------- Flashes ------------------------------- */

.flashes { display: grid; gap: 10px; }

.flash {
  border-radius: 10px;
  padding: 11px 15px;
  font-size: 13px;
  border: 1px solid transparent;
  line-height: 1.6;
}

.flash-success { background: var(--ok-bg); border-color: #a7f3d0; color: #065f46; }
.flash-error { background: var(--danger-bg); border-color: #fecaca; color: #991b1b; }
.flash-warning { background: var(--warn-bg); border-color: #fde68a; color: #92400e; }
.flash-info { background: #eef2fa; border-color: #c9d5ea; color: #1b3a63; }

/* --------------------------------- Cards -------------------------------- */

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
}

.card-head h2 { font-size: 15px; font-weight: 650; }
.card-head .hint { color: var(--muted-2); font-size: 12px; }
.card-body { padding: 20px; }
.card-body.tight { padding: 0; }

.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }

/* ------------------------------- Stat cards ----------------------------- */

.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.stat {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 20px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.stat::after {
  content: "";
  position: absolute;
  left: 0;
  top: 16px;
  bottom: 16px;
  width: 3px;
  border-radius: 3px;
  background: var(--primary);
  opacity: .85;
}

.stat.accent-ok::after { background: #10b981; }
.stat.accent-warn::after { background: #f59e0b; }
.stat.accent-danger::after { background: #ef4444; }

.stat .label { color: var(--muted); font-size: 12.5px; }
.stat .value { font-size: 25px; font-weight: 700; letter-spacing: .01em; margin-top: 7px; font-variant-numeric: tabular-nums; }
.stat .value small { font-size: 13px; font-weight: 500; color: var(--muted-2); margin-left: 5px; }
.stat .sub { color: var(--muted-2); font-size: 12px; margin-top: 5px; }

/* --------------------------------- Tables ------------------------------- */

.table-wrap { width: 100%; overflow-x: auto; }

table.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  min-width: 640px;
}

.table th {
  text-align: left;
  font-size: 11.5px;
  letter-spacing: .04em;
  color: var(--muted);
  font-weight: 600;
  background: #f8fafc;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

.table td {
  padding: 12px 14px;
  border-bottom: 1px solid #eef2f8;
  vertical-align: middle;
}

.table tbody tr:last-child td { border-bottom: none; }
.table tbody tr:hover { background: #fafcff; }

.table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table .nowrap { white-space: nowrap; }
.table .muted { color: var(--muted); }
.table .strong { font-weight: 600; }

.table-foot {
  display: flex;
  justify-content: flex-end;
  gap: 22px;
  padding: 13px 16px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  background: #fbfcfe;
}

.table-foot strong { font-variant-numeric: tabular-nums; }

.month-section { border-top: 1px solid var(--line); }
.month-section:first-child { border-top: none; }
.month-section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 14px;
  padding: 12px 16px;
  background: #f8fafc;
  font-size: 12.5px;
  color: var(--muted);
}
.month-section-head > span:first-child { font-weight: 600; color: var(--ink); }

.plan-block { border-bottom: 1px solid var(--line); }
.plan-block:last-child { border-bottom: none; }
.plan-block .month-section-head { border-bottom: none; }
.plan-note {
  padding: 9px 16px 11px;
  font-size: 12.5px;
  color: var(--muted);
  background: #fdf7f7;
  border-top: 1px dashed var(--line);
  border-bottom: 1px solid var(--line);
  line-height: 1.7;
}

/* --------------------------------- Badges ------------------------------- */

.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: .02em;
  white-space: nowrap;
}

.badge-ok { background: var(--ok-bg); color: var(--ok); }
.badge-warn { background: var(--warn-bg); color: var(--warn); }
.badge-danger { background: var(--danger-bg); color: var(--danger); }
.badge-gray { background: #f2f4f7; color: var(--muted); }
.badge-blue { background: #e8edf7; color: #1e3a5f; }

.dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; display: inline-block; margin-right: 5px; }

/* --------------------------------- Forms -------------------------------- */

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(165px, 1fr));
  gap: 14px;
}

.form-grid .span-2 { grid-column: span 2; }
.form-grid .span-all { grid-column: 1 / -1; }

.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 12px; color: var(--muted); font-weight: 500; }
.field label .req { color: var(--danger); margin-left: 2px; }

.input, .select, .textarea {
  width: 100%;
  border: 1px solid #d5dce8;
  border-radius: 9px;
  padding: 8px 11px;
  background: #fff;
  font-size: 13px;
  transition: border-color .15s, box-shadow .15s;
  min-height: 38px;
}

.textarea { resize: vertical; min-height: 72px; }

.input:focus, .select:focus, .textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(215, 25, 32, .12);
}

.input-file {
  font-size: 12.5px;
  color: var(--muted);
  padding: 6px 8px;
  border: 1px dashed #cdd6e5;
  border-radius: 9px;
  background: #fbfcff;
  width: 100%;
}

.form-actions { display: flex; align-items: center; gap: 12px; margin-top: 16px; flex-wrap: wrap; }

.check-line { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink); cursor: pointer; }
.check-line input[type="checkbox"] { width: 15px; height: 15px; accent-color: var(--primary); margin: 0; }

.invoice-picker {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 240px;
  overflow-y: auto;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fbfcff;
}
.invoice-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 10px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
}
.invoice-option:hover { background: #fdf1f1; }
.invoice-option[hidden] { display: none; }
.invoice-option input[type="checkbox"] { width: 15px; height: 15px; accent-color: var(--primary); margin: 0; flex: none; }
.invoice-option .invoice-no { font-weight: 600; }
.invoice-option .invoice-meta { color: var(--muted); font-size: 12px; margin-left: auto; white-space: nowrap; }
#checkAllWrap { margin-top: 8px; }

.form-inline { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

.form-inline .input { width: auto; min-width: 130px; }

.filter-bar {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}

.filter-bar .field { min-width: 150px; }

/* -------------------------------- Buttons ------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid transparent;
  border-radius: 9px;
  padding: 8px 15px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s, border-color .15s, color .15s, box-shadow .15s;
  text-decoration: none;
}

.btn:hover { text-decoration: none; }

.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 6px 16px -8px rgba(215, 25, 32, .55); }
.btn-primary:hover { background: var(--primary-dark); }

.btn-ghost { background: #fff; color: var(--muted); border-color: #d5dce8; }
.btn-ghost:hover { color: var(--ink); border-color: #b9c4d6; background: #f8fafc; }

.btn-soft { background: var(--primary-soft); color: var(--primary-dark); }
.btn-soft:hover { background: #fbd9da; }

.btn-danger { background: #fff; color: var(--danger); border-color: #f3c0c0; }
.btn-danger:hover { background: var(--danger-bg); }

.btn-ok { background: var(--ok); color: #fff; }
.btn-ok:hover { background: #036c4e; }

.btn-sm { padding: 5px 10px; font-size: 12px; border-radius: 8px; }
.btn-block { width: 100%; }

.btn-row { display: flex; gap: 8px; flex-wrap: wrap; }

/* ------------------------------ Misc pieces ----------------------------- */

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
}

.hint-text { color: var(--muted-2); font-size: 12px; }
.muted { color: var(--muted); }
.strong { font-weight: 600; }
.money { font-variant-numeric: tabular-nums; white-space: nowrap; }
.text-right { text-align: right; }
.mt-0 { margin-top: 0; }
.flex { display: flex; gap: 10px; align-items: center; }
.flex-wrap { flex-wrap: wrap; }
.spread { justify-content: space-between; }

.empty {
  padding: 44px 20px;
  text-align: center;
  color: var(--muted-2);
  font-size: 13px;
}

.empty strong { display: block; color: var(--muted); font-size: 14px; margin-bottom: 4px; font-weight: 600; }

.progress {
  height: 8px;
  background: #eef2f8;
  border-radius: 999px;
  overflow: hidden;
}
.progress > span { display: block; height: 100%; background: linear-gradient(90deg, #34d399, #10b981); border-radius: 999px; }

.list { display: grid; }
.list-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 13px 20px;
  border-bottom: 1px solid #eef2f8;
}
.list-item:last-child { border-bottom: none; }
.list-item .title { font-weight: 600; font-size: 13px; }
.list-item .meta { color: var(--muted-2); font-size: 12px; margin-top: 2px; }

.notice {
  border: 1px solid #c9d5ea;
  background: #eef2fa;
  color: #17345f;
  border-radius: 10px;
  padding: 11px 15px;
  font-size: 12.5px;
  line-height: 1.7;
}

.notice.warn { border-color: #fde68a; background: var(--warn-bg); color: #92400e; }

.claim-block { display: grid; gap: 10px; }
.claim-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
  display: grid;
  gap: 10px;
  background: #fff;
}
.claim-card .claim-head { display: flex; justify-content: space-between; gap: 14px; align-items: flex-start; }
.claim-card .claim-title { font-weight: 600; font-size: 14px; }
.claim-card .claim-meta { color: var(--muted-2); font-size: 12px; margin-top: 3px; }
.claim-card .claim-amount { font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.claim-card .claim-note { background: #f8fafc; border-radius: 8px; padding: 9px 12px; font-size: 12.5px; color: var(--muted); }
.claim-actions { display: flex; gap: 8px; align-items: flex-start; flex-wrap: wrap; }
.claim-actions .textarea { min-height: 38px; flex: 1; min-width: 200px; }

.attachment-list {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid var(--line);
}
.attachment-heading { font-size: 12px; color: var(--muted); font-weight: 600; }
.attachment-row { display: flex; align-items: center; gap: 8px; font-size: 12.5px; min-width: 0; }
.attachment-link {
  color: var(--primary);
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 200px;
}
.attachment-link:hover { text-decoration: underline; }
.attachment-tag {
  flex: none;
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 999px;
  background: #e8eefb;
  color: #35509a;
}
.attachment-row form { margin-left: auto; flex: none; }
.link-danger {
  border: none;
  background: none;
  padding: 0;
  color: var(--danger);
  font-size: 12px;
  cursor: pointer;
}
.link-danger:hover { text-decoration: underline; }
.attach-form { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.attach-form .input-file { flex: 1; min-width: 180px; }

.recon-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 20px;
  align-items: stretch;
}

.recon-summary {
  background: linear-gradient(135deg, #071632 0%, #0b1f45 55%, #1a3566 100%);
  color: #eaf2ff;
  border-radius: var(--radius);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: relative;
  overflow: hidden;
}

.recon-summary::after {
  content: "";
  position: absolute;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  border: 32px solid rgba(255, 255, 255, .06);
  right: -80px;
  top: -90px;
}

.recon-summary .kicker { color: #ffb3b6; font-size: 12px; letter-spacing: .12em; }
.recon-summary .net { font-size: 34px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: .01em; }
.recon-summary .breakdown { display: grid; gap: 7px; font-size: 12.5px; color: #c3d8f7; position: relative; z-index: 1; }
.recon-summary .breakdown div { display: flex; justify-content: space-between; gap: 20px; }
.recon-summary .breakdown strong { color: #fff; font-weight: 600; font-variant-numeric: tabular-nums; }

.recon-side { display: flex; flex-direction: column; gap: 14px; }
.recon-side .card { flex: 1; }
.recon-status-line { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.recon-deadline { color: var(--muted-2); font-size: 12px; line-height: 1.7; }

.doc-icon {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: var(--primary-soft);
  color: var(--primary-dark);
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 700;
  flex: none;
  text-transform: uppercase;
}

.row-title { display: flex; align-items: center; gap: 10px; }
.sub-meta { color: var(--muted-2); font-size: 11.5px; margin-top: 2px; }

.error-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 30px;
  background: var(--bg);
}

.error-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 44px;
  text-align: center;
  max-width: 420px;
  width: 100%;
  box-shadow: var(--shadow);
}

.error-card .code { font-size: 52px; font-weight: 800; color: #c9d6ea; letter-spacing: .05em; line-height: 1; }
.error-card h1 { font-size: 18px; margin: 16px 0 8px; }
.error-card p { color: var(--muted); font-size: 13px; margin-bottom: 22px; }

/* ------------------------------ Responsive ------------------------------ */

@media (max-width: 1200px) {
  .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 960px) {
  .auth-wrap { grid-template-columns: 1fr; gap: 30px; padding: 36px 22px; }
  .auth-hero { display: none; }
  .auth-card { justify-self: center; }

  .app { flex-direction: column; }
  .sidebar {
    width: 100%;
    height: auto;
    position: static;
    flex-direction: row;
    align-items: center;
    padding: 12px 14px;
    gap: 10px;
    overflow-x: auto;
  }
  .brand { padding: 0 8px 0 0; flex: none; }
  .brand-text span { display: none; }
  .nav { flex-direction: row; margin: 0; gap: 4px; overflow-x: auto; flex: 1; }
  .nav-label { display: none; }
  .nav-item { white-space: nowrap; padding: 7px 10px; }
  .nav-item::before { display: none; }
  .sidebar-foot { display: none; }
  .topbar { padding: 13px 18px; flex-wrap: wrap; }
  .content { padding: 18px; }
  .grid-2, .grid-3, .recon-hero { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .stat-grid { grid-template-columns: 1fr; }
  .user-meta { display: none; }
  .topbar-title h1 { font-size: 17px; }
  .form-grid { grid-template-columns: 1fr; }
  .auth-card { padding: 28px 22px; border-radius: 16px; }
  .claim-card .claim-head { flex-direction: column; }
}
