/* HE Sales Insight */
:root {
  --navy: #0a2a66; --navy2: #0f3f98; --blue: #1e6ff0; --blue-l: #e8f1ff; --ink: #0f1f3d; --muted: #64748b; --line: #e3e9f2;
  --bg: #eef3fa; --card: #fff; --green: #16a34a; --red: #dc2626; --orange: #ea8a00; --r: 14px;
  --shadow: 0 1px 2px rgba(15,31,61,.06), 0 6px 18px rgba(15,31,61,.06);
  --safe-b: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; }
body { font: 14px/1.4 "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif; color: var(--ink); background: var(--bg); }
a { color: var(--blue); text-decoration: none; }
h2, h3, h4, h5 { margin: 0; }
.ic { width: 20px; height: 20px; flex: none; vertical-align: middle; }
.muted { color: var(--muted); }
.up { color: var(--green); } .down { color: var(--red); }
button { font: inherit; cursor: pointer; }
input, select { font: inherit; color: inherit; }

/* ---------- login ---------- */
.login { min-height: 100vh; min-height: 100dvh; display: flex; align-items: center; justify-content: center; padding: 24px 18px;
  background: radial-gradient(1200px 600px at 85% 110%, rgba(80,150,255,.45), transparent 60%), linear-gradient(170deg, #071f52 0%, #0f3f98 55%, #2466cf 100%); }
.login-card { color: #fff; text-align: center; max-width: 400px; width: 100%; }
.login-logo { display: flex; align-items: center; gap: 12px; justify-content: center; font-weight: 700; letter-spacing: .5px; text-align: left; line-height: 1.1; font-size: 18px; }
.login-logo img { width: 64px; height: 64px; border-radius: 14px; }
.login-logo span { font-weight: 400; }
.login h1 { font-size: 38px; line-height: 1.05; margin: 34px 0 14px; font-weight: 800; letter-spacing: .5px; }
.release { display: inline-block; border: 1.5px solid rgba(255,255,255,.75); border-radius: 30px; padding: 5px 18px; letter-spacing: 2px; font-size: 12.5px; margin-bottom: 30px; }
.login-box { background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.22); border-radius: 18px; padding: 22px 20px; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); box-shadow: 0 20px 50px rgba(0,0,20,.25); text-align: left; }
.login-box h2 { font-size: 17px; margin-bottom: 14px; text-align: center; font-weight: 600; }
.ms-btn { display: flex; align-items: center; justify-content: center; gap: 12px; background: #fff; color: #222; border-radius: 10px; padding: 14px 18px; font-weight: 600; font-size: 16px; box-shadow: 0 6px 20px rgba(0,0,0,.2); }
.login-hint { opacity: .85; font-size: 12.5px; margin: 8px 0 0; text-align: center; }
.login-err { background: #fee2e2; color: #991b1b; border-radius: 10px; padding: 10px 12px; margin-bottom: 16px; font-size: 13px; }
.login-or { display: flex; align-items: center; gap: 10px; margin: 16px 0; font-size: 12px; color: rgba(255,255,255,.85); }
.login-or::before, .login-or::after { content: ''; flex: 1; height: 1px; background: rgba(255,255,255,.35); }
.pw-login { display: flex; flex-direction: column; gap: 10px; }
.pw-login label { font-size: 12.5px; font-weight: 600; color: rgba(255,255,255,.9); display: flex; flex-direction: column; gap: 5px; }
.pw-login input { border: 1px solid transparent; border-radius: 10px; padding: 12px 14px; font-size: 15px; background: #fff; color: var(--ink); width: 100%; }
.pw-login input:focus { outline: none; border-color: #7db4ff; box-shadow: 0 0 0 3px rgba(125,180,255,.45); }
.pw-login button { margin-top: 4px; border: 0; background: #fff; color: var(--navy2); border-radius: 10px; padding: 13px; font-weight: 800; font-size: 15px; box-shadow: 0 6px 18px rgba(0,0,0,.18); }
.pw-login button:hover { background: #eaf2ff; }
.login-foot { margin-top: 18px; font-size: 12px; color: rgba(255,255,255,.7); }
@media (max-height: 700px) { .login h1 { margin-top: 18px; font-size: 32px; } .release { margin-bottom: 18px; } }
.boot { padding: 60px; text-align: center; color: var(--muted); }

/* ---------- header ---------- */
.top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 14px; padding: 10px 16px; padding-top: max(10px, env(safe-area-inset-top));
  background: linear-gradient(100deg, #0a2a66, #0f3f98 60%, #1752b8); color: #fff; box-shadow: 0 2px 10px rgba(0,0,0,.15); }
.brand { display: none; align-items: center; gap: 10px; color: #fff; }
.brand img { width: 40px; height: 40px; border-radius: 9px; }
.bt b { display: block; font-size: 15px; letter-spacing: .4px; } .bt span { font-size: 14px; }
.ttl h1 { font-size: 20px; font-weight: 700; } .ttl small { font-size: 12px; opacity: .85; }
.topnav { display: none; }
.userchip { margin-left: auto; display: flex; align-items: center; gap: 8px; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.3); color: #fff; border-radius: 30px; padding: 5px 12px 5px 8px; text-align: left; }
.userchip span { display: none; } .userchip b { display: block; font-size: 13px; } .userchip small { font-size: 11px; opacity: .85; }
.demo-bar { background: #fff4d6; color: #8a5a00; text-align: center; font-size: 12px; font-weight: 600; padding: 5px; }

/* ---------- filter bar ---------- */
.fbar { display: flex; gap: 8px; padding: 10px 12px; overflow-x: auto; background: #fff; border-bottom: 1px solid var(--line); align-items: center; scrollbar-width: none; }
.fbar::-webkit-scrollbar { display: none; }
.fbar.off { display: none; }
.fsel { display: inline-flex; align-items: center; gap: 6px; background: #f3f7fd; border: 1px solid #d6e2f3; border-radius: 10px; padding: 0 0 0 10px; flex: none; }
.fsel .ic { width: 17px; height: 17px; color: var(--navy2); }
.fsel b { display: none; font-size: 13px; }
.fsel select { border: 0; background: transparent; padding: 8px 8px 8px 0; max-width: 200px; outline: none; }
.fsel.wide { display: none; }
.fsel.inline { margin-bottom: 12px; background: #fff; }
.dates { display: inline-flex; gap: 6px; flex: none; } .dates input { border: 1px solid #d6e2f3; border-radius: 10px; padding: 6px 8px; }
.fbtn { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 10px; background: var(--navy2); color: #fff; flex: none; font-weight: 600; }
.fbtn .ic { width: 17px; height: 17px; }
.chips { display: inline-flex; gap: 6px; flex: none; }
.chip { border: 1px solid #c9daf5; background: var(--blue-l); color: var(--navy2); border-radius: 20px; padding: 5px 10px; font-size: 12.5px; font-weight: 600; white-space: nowrap; }

/* ---------- layout ---------- */
.view { padding: 12px 12px calc(84px + var(--safe-b)); max-width: 1680px; margin: 0 auto; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 14px; margin-bottom: 12px; min-width: 0; }
.card.err { color: #991b1b; background: #fff5f5; }
.card-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; flex-wrap: wrap; }
.card-top h3 { display: flex; align-items: center; gap: 8px; font-size: 16px; }
.card-top h3 .ic { color: var(--navy2); width: 22px; height: 22px; }
.card-top h3 small { font-weight: 400; color: var(--muted); font-size: 13px; }
.dgrid { display: grid; grid-template-columns: 1fr; gap: 0 14px; }
.skel { height: 90px; border-radius: var(--r); margin-bottom: 12px; background: linear-gradient(90deg, #e7edf6 25%, #f3f6fb 50%, #e7edf6 75%); background-size: 200% 100%; animation: sk 1.2s infinite; }
.skel.short { height: 200px; }
@keyframes sk { to { background-position: -200% 0; } }
.empty { color: var(--muted); text-align: center; padding: 20px 0; margin: 0; }
.hint { color: var(--muted); font-size: 12.5px; } .hint.center { text-align: center; }
.mono { font-family: Consolas, monospace; font-size: 12px; word-break: break-all; background: #f6f8fc; padding: 8px; border-radius: 8px; }
.row-label { display: flex; align-items: center; gap: 10px; font-weight: 600; margin-bottom: 10px; }
.row-label .seg { flex: 1; margin: 0; }

/* ---------- KPI ---------- */
.kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 12px; }
.kpis.three { grid-template-columns: 1fr 1fr; }
.kpis.three .kpi:nth-child(3):last-child { grid-column: 1 / -1; }
.kpi { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 12px; box-shadow: var(--shadow); display: flex; gap: 10px; align-items: flex-start; min-width: 0; }
.kpi > .ic { width: 26px; height: 26px; color: var(--blue); }
.kpi h4 { font-size: 13px; font-weight: 600; color: #334155; }
.kpi strong { display: block; font-size: 22px; font-weight: 800; line-height: 1.2; margin: 2px 0; white-space: nowrap; }
.kpi small { font-size: 11.5px; color: var(--muted); display: block; }
.kpi em { font-style: normal; color: var(--muted); }
.kpi.k-main { background: linear-gradient(135deg, #0f3f98, #1e6ff0); color: #fff; border-color: transparent; }
.kpi.k-main h4, .kpi.k-main small, .kpi.k-main em, .kpi.k-main > .ic { color: rgba(255,255,255,.9); }
.kpi.k-main .d-up { color: #a7f3c0; } .kpi.k-main .d-down { color: #fecaca; }
.d { font-weight: 700; white-space: nowrap; } .d-up { color: var(--green); } .d-down { color: var(--red); } .d-na { color: var(--muted); font-weight: 500; }

/* ---------- segmented tabs ---------- */
.seg { display: flex; background: #e7eef9; border-radius: 10px; padding: 3px; gap: 3px; margin-bottom: 12px; }
.seg button, .seg a { flex: 1; border: 0; background: transparent; padding: 7px 10px; border-radius: 8px; font-weight: 600; color: #334155; font-size: 13px; text-align: center; white-space: nowrap; }
.seg .on { background: var(--blue); color: #fff; box-shadow: 0 2px 6px rgba(30,111,240,.35); }
.card-top .seg { margin: 0; flex: none; }
.card-top .seg button { padding: 5px 10px; font-size: 12px; }

/* ---------- tables & lists ---------- */
.tbl-wrap { overflow-x: auto; margin: 0 -4px; }
.tbl { width: 100%; border-collapse: collapse; }
.tbl th { text-align: left; font-size: 12px; color: #334155; background: #f1f5fb; padding: 8px; font-weight: 700; white-space: nowrap; }
.tbl td { padding: 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl td small { display: block; color: var(--muted); font-size: 11.5px; }
.tbl .n { text-align: right; white-space: nowrap; }
.tbl tr.click { cursor: pointer; } .tbl tr.click:hover td { background: #f6f9ff; }
.tbl tr.total td { background: #eaf1ff; font-weight: 700; border-bottom: 0; }
.tbl.with-total tr.total td { background: var(--navy2); color: #fff; } .tbl.with-total tr.total .low { color: #fff; }
.tbl.compact td, .tbl.compact th { padding: 6px 8px; font-size: 13px; }
.tbl.lines td { font-size: 13px; }
.nmw { max-width: 260px; min-width: 0; }
.nmw b, .nmw small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nmw.wide { max-width: 420px; }
.nmw .desc { font-weight: 400; color: #475569; }
.v-dashboard .nmw { max-width: 170px; }
.tbl td.n { font-variant-numeric: tabular-nums; }
.rank { width: 30px; color: var(--muted); font-weight: 700; }
.rank.r1, .rank.r2, .rank.r3 { color: #fff; } .rank.r1::before, .rank.r2::before, .rank.r3::before { content: ''; }
.tbl .rank.r1 { background: radial-gradient(circle, #f5b301 11px, transparent 12px); text-align: center; }
.tbl .rank.r2 { background: radial-gradient(circle, #94a3b8 11px, transparent 12px); text-align: center; }
.tbl .rank.r3 { background: radial-gradient(circle, #e07a2f 11px, transparent 12px); text-align: center; }
.low { color: var(--red); font-weight: 700; }
.more-link { display: block; text-align: center; color: var(--blue); font-weight: 600; padding: 10px; background: none; border: 0; width: 100%; }
.rows, .docs, .menu, .geo { list-style: none; margin: 0; padding: 0; }
.rows li { display: flex; align-items: center; gap: 10px; padding: 10px 2px; border-bottom: 1px solid var(--line); cursor: pointer; }
.rows li:last-child { border: 0; }
.logo-dot { width: 32px; height: 32px; border-radius: 8px; display: grid; place-items: center; color: #fff; font: italic 900 17px Arial; flex: none; }
.c0 { background: #1747b5; } .c1 { background: #e0312b; } .c2 { background: #1f5fd1; } .c3 { background: #22a35a; } .c4 { background: #2b7de9; } .c5 { background: #f08c00; }
.rm { flex: 1; min-width: 0; } .rm b { display: block; } .rm small { color: #334155; }
.rv { font-weight: 700; } .chev { color: #94a3b8; }
.docs li { display: flex; align-items: center; gap: 10px; padding: 10px 2px; border-bottom: 1px solid var(--line); cursor: pointer; }
.docs li:last-child { border: 0; }
.docs .ic { width: 24px; height: 24px; } .ic.warn { color: var(--orange); } .ic.ok { color: var(--green); } .ic.bad { color: var(--red); } .ic.blue { color: var(--blue); }
.dm { flex: 1; min-width: 0; } .dm b { display: block; } .dm small { display: block; color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dr { text-align: right; } .dr b { display: block; }
.badge { display: inline-block; border-radius: 6px; padding: 2px 8px; font-size: 11.5px; font-weight: 600; background: #eef2f7; color: #475569; white-space: nowrap; }
.b-delivered { background: #dcfce7; color: #15803d; } .b-open { background: #e0edff; color: #1d4ed8; } .b-credited { background: #fde2e2; color: #b91c1c; }
.b-warn { background: #fff1d6; color: #b45309; } .b-shipped { background: #dcfce7; color: #15803d; } .b-admin { background: #ede9fe; color: #6d28d9; }

/* ---------- charts ---------- */
.chart { width: 100%; height: auto; display: block; }
.chart .grid { stroke: #e6ecf5; } .chart .ya { font-size: 11px; fill: #64748b; text-anchor: end; } .chart .ya-r { text-anchor: start; } .chart .xa { font-size: 11px; fill: #475569; text-anchor: middle; }
.trend-wrap { display: flex; gap: 10px; flex-direction: column; }
.trend-chart { min-width: 0; }
.chartbox { width: 100%; min-height: 200px; }
.trend-side { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 22px; border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; background: #f8fbff; }
.trend-side h5 { font-size: 13.5px; margin-right: 4px; }
.trend-side > div { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.trend-side small { color: var(--muted); } .trend-side b { font-size: 17px; }
.trend-side .d { font-size: 12px; } .trend-side em { font-size: 12px; font-style: normal; color: var(--muted); }
.legend-inline { display: flex; gap: 14px; font-size: 12.5px; margin-bottom: 6px; }
.legend-inline i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.legend-inline i.ring { border: 2.5px solid; border-radius: 50%; background: #fff; width: 11px; height: 11px; }
.donut-wrap { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.donut { width: 190px; flex: none; }
.donut .dc1 { font-size: 20px; font-weight: 800; text-anchor: middle; fill: var(--ink); } .donut .dc2 { font-size: 11px; text-anchor: middle; fill: var(--muted); }
.legend-t { flex: 1; min-width: 0; width: 100%; }
.legend-t td:first-child { max-width: 150px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .dot { display: inline-block; width: 11px; height: 11px; border-radius: 50%; margin-right: 8px; vertical-align: -1px; }
.geo li { display: grid; grid-template-columns: 110px 1fr auto; gap: 10px; align-items: center; padding: 7px 4px; cursor: pointer; border-radius: 8px; }
.geo li.sel { background: var(--blue-l); }
.gl { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gb { height: 14px; background: #e8eef7; border-radius: 4px; overflow: hidden; } .gb span { display: block; height: 100%; background: linear-gradient(90deg, #1747b5, #3d8bff); border-radius: 4px; }
.gv { font-weight: 700; white-space: nowrap; font-size: 13px; } .gv em { font-style: normal; color: var(--muted); font-weight: 500; margin-left: 4px; }

/* ---------- search, menu, doc ---------- */
.search { display: flex; align-items: center; gap: 8px; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 0 12px; margin-bottom: 12px; }
.search .ic { color: var(--muted); } .search input { flex: 1; border: 0; padding: 11px 0; outline: none; background: transparent; }
.menu { background: #fff; border-radius: var(--r); border: 1px solid var(--line); overflow: hidden; }
.menu a { display: flex; align-items: center; gap: 12px; padding: 14px; color: var(--ink); border-bottom: 1px solid var(--line); font-weight: 600; }
.menu .ic { color: var(--navy2); } .menu .chev { margin-left: auto; }
.back { display: inline-flex; align-items: center; gap: 4px; font-weight: 600; margin-bottom: 10px; }
.doc-h { display: flex; gap: 10px; align-items: flex-start; } .doc-h > .ic { width: 34px; height: 34px; color: var(--blue); }
.doc-h > div { flex: 1; } .doc-h small { color: var(--muted); }
.doc-tot { display: flex; gap: 20px; flex-wrap: wrap; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.doc-tot small { display: block; color: var(--muted); } .doc-tot b { font-size: 18px; }
.kv { display: grid; grid-template-columns: 120px 1fr; gap: 6px 10px; margin: 0; } .kv dt { color: var(--muted); } .kv dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }

/* ---------- forms ---------- */
.form { display: flex; flex-direction: column; gap: 12px; }
.form h3 { display: flex; align-items: center; gap: 8px; font-size: 15px; margin-top: 8px; padding-top: 10px; border-top: 1px solid var(--line); }
.form h3:first-child { border: 0; padding: 0; margin: 0; }
.form h3 .ic { color: var(--navy2); } .form h3 small { font-weight: 400; color: var(--muted); font-size: 12px; }
.form label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 600; }
.form input:not([type=checkbox]):not([type=radio]), .form select, .tbl input:not([type=checkbox]) { border: 1px solid #cfd8e6; border-radius: 9px; padding: 9px 10px; background: #fff; width: 100%; }
.two-col, .three-col { display: grid; grid-template-columns: 1fr; gap: 12px; }
.checks, .radios { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.checks label, .radios label { flex-direction: row; align-items: center; gap: 6px; font-weight: 500; }
.sp-list { max-height: 260px; overflow: auto; border: 1px solid var(--line); border-radius: 10px; padding: 8px; flex-direction: column; flex-wrap: nowrap; }
.btns { display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; } .btns.left { justify-content: flex-start; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; background: var(--blue); color: #fff; border: 0; border-radius: 10px; padding: 10px 18px; font-weight: 700; }
.btn.ghost { background: #fff; color: var(--navy2); border: 1px solid #c9d7ee; } .btn.danger { background: var(--red); }
.btn .ic { width: 17px; height: 17px; }
.note { padding: 10px 12px; border-radius: 10px; background: #f1f5fb; font-size: 13px; } .note.ok { background: #dcfce7; color: #14532d; } .note.bad { background: #fee2e2; color: #7f1d1d; }
.chiprow { display: flex; }

/* transaction lines: one compact card per line on phones */
@media (max-width: 700px) {
  .tbl.lines thead { display: none; }
  .tbl.lines, .tbl.lines tbody { display: block; width: 100%; }
  .tbl.lines tr { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px 10px; padding: 10px 2px; border-bottom: 1px solid var(--line); }
  .tbl.lines td { border: 0; padding: 0; text-align: left !important; font-size: 13px; }
  .tbl.lines td::before { content: attr(data-h); display: block; font-size: 10.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .3px; }
  .tbl.lines td:first-child { grid-column: 1 / -1; }
  .tbl.lines td:first-child::before { display: none; }
  .tbl.lines .nmw.wide { max-width: 100%; }
  .nmw { max-width: 44vw; }
  .kv { grid-template-columns: 105px 1fr; }
}

/* ---------- bottom nav (mobile) ---------- */
.bottom { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; display: flex; background: #fff; border-top: 1px solid var(--line); padding: 6px 4px calc(6px + var(--safe-b)); box-shadow: 0 -2px 12px rgba(15,31,61,.06); }
.bottom a { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; color: #64748b; font-size: 11px; font-weight: 600; }
.bottom a .ic { width: 22px; height: 22px; } .bottom a.on { color: var(--blue); }

/* ---------- overlays ---------- */
#progress { position: fixed; inset: 0; z-index: 50; background: rgba(10,25,60,.35); display: none; align-items: center; justify-content: center; padding: 20px; }
#progress.on { display: flex; }
.pbox { background: #fff; border-radius: 16px; padding: 20px; width: 100%; max-width: 380px; display: flex; flex-direction: column; gap: 8px; box-shadow: 0 10px 40px rgba(0,0,0,.25); }
.pbar { height: 10px; background: #e7eef9; border-radius: 6px; overflow: hidden; } .pbar span { display: block; height: 100%; background: var(--blue); transition: width .3s; }
.pbox small { color: #334155; } .pbox small.muted { color: var(--muted); }
#toast { position: fixed; left: 50%; bottom: calc(80px + var(--safe-b)); transform: translateX(-50%) translateY(20px); background: #0f1f3d; color: #fff; padding: 10px 16px; border-radius: 10px; opacity: 0; pointer-events: none; transition: .25s; z-index: 60; max-width: 92vw; font-size: 13px; }
#toast.on { opacity: 1; transform: translateX(-50%); }
body.plain { padding: 10px; }

/* ---------- tablet ---------- */
@media (min-width: 640px) {
  .kpis, .kpis.three { grid-template-columns: repeat(3, 1fr); }
  .kpis.three .kpi:nth-child(3):last-child { grid-column: auto; }
  .two-col { grid-template-columns: 1fr 1fr; } .three-col { grid-template-columns: repeat(3, 1fr); }
  .donut-wrap { flex-direction: row; align-items: center; }
  .dgrid.two { grid-template-columns: 1fr 1fr; }
  .userchip span { display: block; }
}

/* ---------- desktop / Windows ---------- */
@media (min-width: 1024px) {
  .top { padding: 10px 24px 0; gap: 22px; flex-wrap: wrap; }
  .ttl { white-space: nowrap; }
  .brand { display: flex; padding-right: 22px; border-right: 1px solid rgba(255,255,255,.35); }
  .ttl h1 { font-size: 26px; letter-spacing: .3px; } .ttl small { font-size: 14px; }
  .topnav { display: flex; gap: 2px; order: 10; width: 100%; margin: 4px -10px 0; overflow-x: auto; }
  .topnav a { color: rgba(255,255,255,.82); padding: 8px 12px 10px; font-weight: 600; font-size: 13.5px; border-bottom: 3px solid transparent; white-space: nowrap; }
  .topnav a:hover { color: #fff; } .topnav a.on { color: #fff; border-bottom-color: #6fb1ff; }
  .bottom { display: none; }
  .view { padding: 16px 24px 30px; }
  #toast { bottom: 30px; }
  .fbar { padding: 10px 24px; flex-wrap: wrap; overflow: visible; gap: 10px; background: #f8fbff; }
  .fsel b { display: inline; } .fsel.wide { display: inline-flex; }
  .kpis, .kpis.three { grid-template-columns: repeat(6, 1fr); gap: 14px; }
  .kpis.two { grid-template-columns: repeat(2, minmax(0, 360px)); }
  .kpis.three { grid-template-columns: repeat(3, minmax(0, 360px)); }
  .kpi { padding: 16px; } .kpi strong { font-size: 30px; } .kpi > .ic { width: 34px; height: 34px; }
  .kpi small { font-size: 12.5px; }
  .v-dashboard .dgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 14px; align-items: start; }
  .v-dashboard .donut-wrap { flex-direction: row; } .v-dashboard .donut { width: 170px; }
  .view.v-doc { max-width: 1180px; }
  .view:not(.v-dashboard) > .card, .view:not(.v-dashboard) > .seg, .view:not(.v-dashboard) > .search, .view:not(.v-dashboard) > .row-label { max-width: 1100px; }
  .view.v-admin > .card, .view.v-admin > .seg { max-width: 1100px; }
  .menu { max-width: 600px; }
}
@media (min-width: 1024px) and (max-width: 1399px) {
  .kpi strong { font-size: 24px; }
}
@media (min-width: 1700px) {
  .v-dashboard .dgrid { grid-template-columns: 1.15fr 1.15fr 0.95fr 1.1fr; }
  .v-dashboard .donut-wrap { flex-direction: column; } .v-dashboard .donut { width: 150px; }
  .v-dashboard .nmw { max-width: 130px; }
  .v-dashboard .tbl td, .v-dashboard .tbl th { padding: 7px 6px; font-size: 13px; }
}
