/* Orbitrix Inventory demo — styles */
:root {
  --bg: #F3F5F9;
  --surface: #FFFFFF;
  --surface-2: #F8FAFC;
  --ink: #0E1726;
  --ink-2: #475467;
  --ink-3: #8A94A6;
  --line: #E5E9F0;
  --line-2: #EEF1F6;
  --brand: #4F46E5;
  --brand-2: #6366F1;
  --brand-soft: #EEF0FF;
  --cyan: #22D3EE;
  --ok: #059669;
  --ok-soft: #E7F8F1;
  --low: #D97706;
  --low-soft: #FFF5E5;
  --out: #DC2626;
  --out-soft: #FDECEC;
  --info: #0284C7;
  --info-soft: #E6F4FB;
  --side: #0B1220;
  --side-2: #131C2E;
  --radius: 16px;
  --radius-sm: 11px;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .05);
  --shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 4px 16px -4px rgba(16, 24, 40, .08);
  --shadow-lg: 0 24px 60px -12px rgba(15, 23, 42, .28);
  --ease: cubic-bezier(.2, .8, .2, 1);
  --spring: cubic-bezier(.34, 1.4, .5, 1);
  --sidebar: 268px;
  --bnav-h: 70px;
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: auto; }
body { margin: 0; background: var(--bg); color: var(--ink); font-size: 14.5px; line-height: 1.45; min-height: 100vh; overflow-x: hidden; }
body.locked { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; text-align: inherit; }
input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; letter-spacing: -.02em; }
p { margin: 0; }
b { font-weight: 650; }
small { font-size: .82em; }
.ic { width: 18px; height: 18px; flex: none; }
.logo { display: block; flex: none; border-radius: 28%; background: #040612; box-shadow: 0 0 0 1px rgba(255, 255, 255, .1); }
.muted { color: var(--ink-3); }
.pos { color: var(--ok); }
.neg { color: var(--out); }
b.ok, .q.ok { color: var(--ink); }
b.low, .q.low { color: var(--low); }
b.out, .q.out { color: var(--out); }
:focus-visible { outline: 2.5px solid var(--brand-2); outline-offset: 2px; border-radius: 8px; }
.noscript { padding: 40px; text-align: center; }

/* ---------- sidebar ---------- */
.sidebar {
  position: fixed; inset: 0 auto 0 0; width: var(--sidebar); background: var(--side); color: #CBD5E1;
  display: flex; flex-direction: column; padding: 20px 14px 16px; overflow-y: auto; z-index: 30;
  background-image: radial-gradient(120% 50% at 0% 0%, rgba(99, 102, 241, .22), transparent 60%);
}
.sb-brand { display: flex; align-items: center; gap: 11px; padding: 4px 8px 18px; }
.sb-brand b { display: block; color: #fff; font-size: 17px; letter-spacing: -.02em; }
.sb-brand span { display: block; font-size: 12px; color: #94A3B8; margin-top: -1px; }
.biz { display: flex; gap: 11px; align-items: center; padding: 11px; border-radius: 13px; background: var(--side-2); border: 1px solid rgba(255, 255, 255, .06); margin-bottom: 14px; }
.biz-av { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; font-weight: 800; font-size: 13px; color: #fff; background: linear-gradient(135deg, #F59E0B, #EA580C); flex: none; }
.biz b { display: block; color: #fff; font-size: 13px; line-height: 1.25; }
.biz span { font-size: 11.5px; color: #94A3B8; }
.snav { display: flex; flex-direction: column; gap: 2px; }
.snav a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; font-weight: 550; font-size: 14px; color: #A9B4C7; transition: background .2s, color .2s; position: relative; }
.snav a:hover { background: rgba(255, 255, 255, .05); color: #fff; }
.snav a.on { background: linear-gradient(90deg, rgba(99, 102, 241, .28), rgba(99, 102, 241, .08)); color: #fff; }
.snav a.on::before { content: ''; position: absolute; left: -14px; top: 9px; bottom: 9px; width: 3px; border-radius: 0 3px 3px 0; background: linear-gradient(var(--brand-2), var(--cyan)); }
.badge { margin-left: auto; min-width: 22px; height: 22px; padding: 0 7px; border-radius: 11px; background: var(--out); color: #fff; font-size: 11.5px; font-weight: 700; font-style: normal; display: inline-grid; place-items: center; }
.badge[hidden] { display: none; }
.badge.pulse { animation: pulse 1.4s var(--ease) 2; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(220, 38, 38, .6); transform: scale(1); } 30% { transform: scale(1.25); } 100% { box-shadow: 0 0 0 12px rgba(220, 38, 38, 0); transform: scale(1); } }
.side-sec { margin-top: 18px; display: flex; flex-direction: column; gap: 1px; }
.side-h { display: block; font-size: 10.5px; letter-spacing: .09em; text-transform: uppercase; font-weight: 700; color: #64748B; padding: 6px 12px; }
.side-lock { display: flex; align-items: center; gap: 12px; padding: 8px 12px; border-radius: 9px; font-size: 13px; color: #8391A7; transition: background .2s, color .2s; }
.side-lock:hover { background: rgba(255, 255, 255, .05); color: #E2E8F0; }
.side-lock .ic { width: 16px; height: 16px; }
.side-lock .lk { margin-left: auto; width: 13px; height: 13px; opacity: .6; }
.side-cta { margin-top: auto; padding: 16px; border-radius: 14px; background: linear-gradient(140deg, rgba(99, 102, 241, .3), rgba(34, 211, 238, .12)); border: 1px solid rgba(129, 140, 248, .3); }
.side-cta b { color: #fff; display: block; font-size: 14px; }
.side-cta p { font-size: 12.5px; color: #B4C0D3; margin: 3px 0 12px; }
.side-cta .btn { font-size: 12.5px; padding: 10px 10px; }
.side-reset { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 10px; padding: 9px; border-radius: 10px; font-size: 12.5px; color: #8391A7; transition: color .2s, background .2s; }
.side-reset:hover { color: #fff; background: rgba(255, 255, 255, .05); }
.side-reset .ic { width: 15px; height: 15px; }

/* ---------- main ---------- */
.main { margin-left: var(--sidebar); min-height: 100vh; display: flex; flex-direction: column; }
.demo-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 32px; font-size: 12.5px; color: #3730A3; background: linear-gradient(90deg, #EEF0FF, #E8FAFD); border-bottom: 1px solid #E0E4FF; }
.demo-bar a { display: inline-flex; align-items: center; gap: 4px; font-weight: 650; color: var(--brand); }
.demo-bar a .ic { width: 14px; height: 14px; }
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 32px; background: rgba(243, 245, 249, .82); backdrop-filter: saturate(1.6) blur(14px); -webkit-backdrop-filter: saturate(1.6) blur(14px); border-bottom: 1px solid transparent; }
.tb-search { flex: 1; max-width: 460px; display: flex; align-items: center; gap: 10px; padding: 0 12px; height: 40px; border-radius: 11px; background: var(--surface); border: 1px solid var(--line); color: var(--ink-3); transition: border-color .2s, box-shadow .2s; }
.tb-search:focus-within { border-color: var(--brand-2); box-shadow: 0 0 0 4px rgba(99, 102, 241, .12); }
.tb-search input { flex: 1; border: 0; outline: 0; background: none; height: 100%; color: var(--ink); min-width: 0; }
.tb-search kbd { font: 600 10.5px 'Inter', sans-serif; padding: 2px 6px; border-radius: 5px; border: 1px solid var(--line); color: var(--ink-3); }
.tb-r { display: flex; align-items: center; gap: 10px; }
.live { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--ink-2); font-weight: 550; padding: 0 6px; font-variant-numeric: tabular-nums; }
.live i { width: 8px; height: 8px; border-radius: 50%; background: #10B981; box-shadow: 0 0 0 0 rgba(16, 185, 129, .5); animation: live 2s infinite; }
@keyframes live { 70% { box-shadow: 0 0 0 7px rgba(16, 185, 129, 0); } 100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); } }
.who-chip { display: flex; align-items: center; gap: 9px; padding: 4px 12px 4px 4px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); transition: box-shadow .2s; }
.who-chip:hover { box-shadow: var(--shadow); }
.who-chip b { display: block; font-size: 12.5px; line-height: 1.1; }
.who-chip small { color: var(--ink-3); font-size: 11px; }
.av { width: 30px; height: 30px; border-radius: 50%; display: inline-grid; place-items: center; flex: none; font-size: 11px; font-weight: 700; color: #fff; background: var(--c, var(--brand)); letter-spacing: .02em; }
.view { flex: 1; padding: 8px 32px 40px; width: 100%; max-width: 1320px; }
.foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 18px 32px 26px; color: var(--ink-3); font-size: 12.5px; max-width: 1320px; }
.foot div { display: flex; align-items: center; gap: 10px; }
.foot b { color: var(--ink-2); font-weight: 600; }
.foot a { font-weight: 650; color: var(--brand); }
.mtop, .bnav { display: none; }

/* ---------- page + animations ---------- */
.page > * { animation: rise .55s var(--ease) both; animation-delay: calc(var(--i, 0) * 55ms); }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.ph { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin: 14px 0 22px; flex-wrap: wrap; }
.ph h1 { font-size: 28px; font-weight: 750; line-height: 1.15; }
.ph p { color: var(--ink-2); margin-top: 5px; max-width: 720px; }
.ph-r { display: flex; gap: 10px; flex-wrap: wrap; }
.ph-back { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 600; color: var(--ink-3); margin-bottom: 6px; transition: color .2s; }
.ph-back:hover { color: var(--brand); }
.ph-back .ic { width: 15px; height: 15px; }
.eyebrow { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--brand); }
.eyebrow .ic { width: 13px; height: 13px; }
.eyebrow.light { color: #A5B4FC; }
.sec-h { display: flex; align-items: center; gap: 8px; font-size: 13px; text-transform: uppercase; letter-spacing: .07em; color: var(--ink-3); font-weight: 700; margin: 26px 0 12px; }
.sec-h:first-of-type { margin-top: 4px; }
.sec-h span { background: var(--brand-soft); color: var(--brand); padding: 1px 8px; border-radius: 999px; font-size: 11.5px; letter-spacing: 0; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 11px; font-weight: 600; font-size: 14px; white-space: nowrap; background: var(--surface); border: 1px solid var(--line); color: var(--ink); box-shadow: var(--shadow-sm); transition: transform .18s var(--ease), box-shadow .2s, background .2s, border-color .2s, filter .2s; user-select: none; }
.btn:hover { box-shadow: var(--shadow); border-color: #D5DBE6; }
.btn:active { transform: scale(.97); }
.btn.primary { background: linear-gradient(180deg, #5B54F0, var(--brand)); border-color: transparent; color: #fff; box-shadow: 0 1px 0 rgba(255, 255, 255, .2) inset, 0 6px 16px -6px rgba(79, 70, 229, .6); }
.btn.primary:hover { filter: brightness(1.07); }
.btn.ok { background: linear-gradient(180deg, #10B981, var(--ok)); border-color: transparent; color: #fff; box-shadow: 0 1px 0 rgba(255, 255, 255, .2) inset, 0 6px 16px -6px rgba(5, 150, 105, .55); }
.btn.ok:hover { filter: brightness(1.06); }
.btn.ghost { background: var(--surface); }
.btn.light { background: #fff; color: var(--brand); border-color: transparent; }
.btn.sm { height: 34px; padding: 0 12px; font-size: 13px; border-radius: 9px; }
.btn.sm .ic { width: 16px; height: 16px; }
.btn.lg { height: 48px; padding: 0 20px; font-size: 15px; border-radius: 13px; }
.btn.xl { height: 56px; font-size: 16px; border-radius: 14px; }
.btn.block { width: 100%; display: flex; }
.btn.shake { animation: shake .45s; }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.icon-btn { width: 38px; height: 38px; border-radius: 10px; display: inline-grid; place-items: center; color: var(--ink-2); transition: background .2s, color .2s, transform .15s; flex: none; }
.icon-btn:hover { background: var(--line-2); color: var(--ink); }
.icon-btn:active { transform: scale(.92); }
.lnk { display: inline-flex; align-items: center; gap: 3px; color: var(--brand); font-weight: 600; font-size: 13px; white-space: nowrap; }
.lnk .ic { width: 15px; height: 15px; transition: transform .2s; }
.lnk:hover .ic { transform: translateX(2px); }

/* ---------- cards & grid ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; min-width: 0; }
.card.flush { padding: 0; overflow: hidden; }
.card.flush.only-desk { overflow-x: auto; }
.card-h { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.card-h > div:first-child { flex: 1 1 220px; min-width: 0; }
.card-h h3 { font-size: 16px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.card-h h3 .ic { color: var(--ink-3); }
.card-h p { color: var(--ink-3); font-size: 13px; margin-top: 2px; }
.card-h-r { display: flex; gap: 8px; flex: none; }
.grid { display: grid; gap: 18px; margin-bottom: 18px; }
.g-21 { grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); }
.g-11 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }

/* KPIs */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 18px; }
.kpis.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.kpi { position: relative; overflow: hidden; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 6px; transition: transform .25s var(--ease), box-shadow .25s; }
a.kpi:hover { transform: translateY(-3px); box-shadow: 0 14px 30px -14px rgba(16, 24, 40, .25); }
.kpi::after { content: ''; position: absolute; right: -40px; top: -40px; width: 120px; height: 120px; border-radius: 50%; background: var(--kc, var(--brand)); opacity: .07; }
.kpi-top { display: flex; justify-content: space-between; align-items: center; color: var(--ink-2); font-size: 13px; font-weight: 600; }
.kpi-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--ks, var(--brand-soft)); color: var(--kc, var(--brand)); }
.kpi-v { font-size: 30px; font-weight: 780; letter-spacing: -.03em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.kpi-sub { font-size: 12.5px; color: var(--ink-3); }
.kpi.brand { --kc: var(--brand); --ks: var(--brand-soft); }
.kpi.danger { --kc: var(--out); --ks: var(--out-soft); }
.kpi.danger .kpi-v { color: var(--out); }
.kpi.warn { --kc: var(--low); --ks: var(--low-soft); }
.kpi.good { --kc: var(--ok); --ks: var(--ok-soft); }
.kpi.info { --kc: var(--info); --ks: var(--info-soft); }
.kpi.neutral { --kc: #475569; --ks: #EEF2F6; }

/* status bits */
.sdot { width: 9px; height: 9px; border-radius: 50%; flex: none; background: var(--ok); }
.sdot.low { background: var(--low); box-shadow: 0 0 0 4px var(--low-soft); }
.sdot.out { background: var(--out); box-shadow: 0 0 0 4px var(--out-soft); animation: blink 1.8s infinite; }
@keyframes blink { 50% { box-shadow: 0 0 0 7px rgba(220, 38, 38, .08); } }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px 3px 8px; border-radius: 999px; font-size: 12px; font-weight: 650; white-space: nowrap; background: var(--ok-soft); color: var(--ok); }
.pill i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.pill.low { background: var(--low-soft); color: #B45309; }
.pill.out { background: var(--out-soft); color: var(--out); }
.tag { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 8px; font-size: 12px; font-weight: 600; background: var(--line-2); color: var(--ink-2); white-space: nowrap; }
.tag .ic { width: 13px; height: 13px; }
.tag.ok { background: var(--ok-soft); color: var(--ok); }
.tag.low { background: var(--low-soft); color: #B45309; }
.tag.out { background: var(--out-soft); color: var(--out); }
.tag.idle { background: #F1F3F7; color: var(--ink-2); }
.meter { position: relative; height: 6px; border-radius: 6px; background: var(--line-2); margin-top: 7px; overflow: visible; }
.meter i { position: absolute; inset: 0 auto 0 0; width: var(--w); border-radius: 6px; background: linear-gradient(90deg, #34D399, var(--ok)); transform-origin: left; animation: grow .9s var(--ease) both; }
.meter.low i { background: linear-gradient(90deg, #FBBF24, var(--low)); }
.meter.out i { background: var(--out); }
.meter s { position: absolute; left: 40%; top: -3px; bottom: -3px; width: 2px; border-radius: 2px; background: #94A3B8; opacity: .7; }
@keyframes grow { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.bar { display: block; height: 8px; border-radius: 8px; background: var(--line-2); overflow: hidden; }
.bar i { display: block; height: 100%; width: var(--w); border-radius: 8px; background: linear-gradient(90deg, var(--brand-2), var(--cyan)); transform-origin: left; animation: grow 1s var(--ease) both; animation-delay: calc(var(--d, 0ms) + 200ms); }

.empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; padding: 44px 20px; color: var(--ink-3); }
.empty .ic { width: 36px; height: 36px; padding: 8px; border-radius: 12px; background: var(--ok-soft); color: var(--ok); margin-bottom: 4px; }
.empty b { color: var(--ink); font-size: 15px; }
.empty .btn { margin-top: 10px; }
.empty.sm { padding: 22px 12px; }

/* banners */
.banner { display: flex; align-items: center; gap: 12px; width: 100%; padding: 13px 16px; border-radius: 13px; margin-bottom: 16px; font-size: 14px; text-align: left; }
.banner > .ic:last-child { margin-left: auto; }
.banner.warn { background: var(--low-soft); color: #92400E; border: 1px solid #FBE3B8; transition: transform .2s; }
.banner.warn:hover { transform: translateY(-1px); }
.banner.warn > .ic:first-child { color: var(--low); }
.banner.info { background: var(--info-soft); color: #075985; border: 1px solid #CDE8F6; }

/* ---------- summary ---------- */
.rlist { display: flex; flex-direction: column; }
.rrow { display: grid; grid-template-columns: auto minmax(0, 1.6fr) 104px minmax(0, 1fr) 130px; gap: 16px; align-items: center; padding: 14px 10px; margin: 0 -10px; border-radius: 12px; cursor: pointer; transition: background .2s; border-top: 1px solid var(--line-2); }
.rrow:first-child { border-top: 0; }
.rrow:hover { background: var(--surface-2); }
.rrow-main { min-width: 0; }
.rrow-main b, .rrow-main span { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rrow-main span { font-size: 12.5px; color: var(--ink-3); }
.rrow-qty b { font-size: 22px; font-weight: 780; font-variant-numeric: tabular-nums; display: block; line-height: 1.1; }
.rrow-qty span, .rrow-sug span, .rrow-sug em { display: block; font-size: 12px; color: var(--ink-3); font-style: normal; }
.rrow-sug b { display: block; font-size: 14px; }
.rrow-sug em { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rrow-act { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.rrow-act small { color: var(--ink-3); font-size: 11.5px; }
.inc-list { display: flex; flex-direction: column; gap: 10px; }
.inc { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 13px; border: 1px solid var(--line); transition: border-color .2s, transform .2s var(--ease), box-shadow .2s; }
.inc:hover { border-color: #C7CCF8; transform: translateX(2px); box-shadow: var(--shadow); }
.inc-ic { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; background: var(--info-soft); color: var(--info); flex: none; }
.inc-ic.today { background: var(--ok-soft); color: var(--ok); }
.inc-main { flex: 1; min-width: 0; }
.inc-main b { display: block; font-size: 14px; }
.inc-main span { display: block; font-size: 12.5px; color: var(--ink-3); }
.inc-main em { display: inline-flex; align-items: center; gap: 5px; margin-top: 4px; font-style: normal; font-size: 12px; font-weight: 600; color: var(--info); }
.inc-main em.today { color: var(--ok); }
.inc-main em .ic { width: 13px; height: 13px; }
.chv { color: var(--ink-3); }
.cats { display: flex; flex-direction: column; gap: 4px; }
.cat-row { display: grid; grid-template-columns: 150px minmax(0, 1fr) 92px 38px; gap: 12px; align-items: center; padding: 7px 8px; margin: 0 -8px; border-radius: 9px; font-size: 13px; transition: background .2s; }
.cat-row:hover { background: var(--surface-2); }
.cat-n { font-weight: 550; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cat-v { text-align: right; font-weight: 650; font-variant-numeric: tabular-nums; }
.cat-p { text-align: right; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.slow-tease { display: flex; align-items: center; gap: 16px; transition: transform .25s var(--ease), box-shadow .25s; }
.slow-tease:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -14px rgba(16, 24, 40, .25); }
.slow-tease b { display: block; font-size: 19px; margin: 3px 0; letter-spacing: -.02em; }
.slow-tease p { color: var(--ink-2); font-size: 13.5px; }
.st-ic { width: 52px; height: 52px; border-radius: 15px; display: grid; place-items: center; background: var(--low-soft); color: var(--low); flex: none; }
.st-ic .ic { width: 24px; height: 24px; transform: scaleY(-1); }
.cta-card { display: flex; flex-direction: column; justify-content: space-between; gap: 16px; color: #fff; border: 0; background: radial-gradient(120% 140% at 100% 0%, rgba(34, 211, 238, .35), transparent 50%), linear-gradient(135deg, #1E1B4B, #312E81 60%, #4338CA); }
.cta-card b { display: block; font-size: 20px; margin: 4px 0; letter-spacing: -.02em; }
.cta-card p { color: #C7D2FE; font-size: 13.5px; max-width: 460px; }
.cta-card .btn { align-self: flex-start; }

/* feed / movements */
.feed { display: flex; flex-direction: column; }
.mv { display: flex; gap: 12px; padding: 12px 4px; border-top: 1px solid var(--line-2); cursor: pointer; transition: background .2s; }
.mv:first-child { border-top: 0; }
.card.flush .mv { padding: 14px 18px; }
.mv:hover { background: var(--surface-2); }
.mv.fresh { animation: freshbg 2.6s var(--ease); }
@keyframes freshbg { 0%, 40% { background: #EEF0FF; } 100% { background: transparent; } }
.mv-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex: none; }
.mv-ic .ic { width: 17px; height: 17px; }
.k-in { background: var(--ok-soft); color: var(--ok); }
.k-out { background: #FFF1EC; color: #EA580C; }
.k-adj { background: #F3EEFF; color: #7C3AED; }
.mv-main { flex: 1; min-width: 0; }
.mv-top { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.mv-top b { font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mv-q { font-weight: 750; font-variant-numeric: tabular-nums; white-space: nowrap; }
.mv-q small { font-weight: 500; color: var(--ink-3); }
.mv-sub { font-size: 13px; color: var(--ink-2); margin-top: 1px; }
.mv-sub .rs { font-weight: 600; color: var(--ink); }
.mv-sub .ref { font-variant-numeric: tabular-nums; color: var(--ink-3); }
.mv-note { font-size: 12.5px; color: var(--ink-2); background: var(--surface-2); border-left: 3px solid var(--line); padding: 4px 9px; border-radius: 0 7px 7px 0; margin-top: 6px; }
.mv-meta { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin-top: 6px; font-size: 12px; color: var(--ink-3); }
.mv-meta .av { width: 20px; height: 20px; font-size: 8.5px; }
.mv-meta b { color: var(--ink-2); }
.dotsep { width: 3px; height: 3px; border-radius: 50%; background: #CBD2DC; }

/* ---------- toolbars ---------- */
.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.tl-l { font-size: 13px; font-weight: 600; color: var(--ink-3); }
.search { flex: 1; min-width: 220px; display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 14px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); color: var(--ink-3); transition: border-color .2s, box-shadow .2s; }
.search:focus-within { border-color: var(--brand-2); box-shadow: 0 0 0 4px rgba(99, 102, 241, .12); }
.search input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: none; color: var(--ink); font-size: 14.5px; }
.search.big { height: 52px; margin-bottom: 8px; }
.seg { display: inline-flex; padding: 4px; gap: 2px; border-radius: 12px; background: #E9ECF2; }
.seg .chip { border: 0; background: none; box-shadow: none; height: 36px; }
.seg .chip.on { background: var(--surface); box-shadow: var(--shadow-sm); color: var(--ink); }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 9px; font-size: 13px; font-weight: 600; color: var(--ink-2); white-space: nowrap; border: 1px solid var(--line); background: var(--surface); transition: background .2s, color .2s, border-color .2s, transform .15s; }
.chip:active { transform: scale(.96); }
.chip .ic { width: 15px; height: 15px; }
.chip em { font-style: normal; font-size: 11px; background: var(--out); color: #fff; padding: 0 6px; border-radius: 99px; line-height: 17px; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 14px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chips .chip.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.sel { position: relative; display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 12px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); color: var(--ink-3); }
.sel select { border: 0; outline: 0; background: none; color: var(--ink); font-weight: 550; font-size: 13.5px; cursor: pointer; max-width: 230px; }
.list-meta { font-size: 13px; color: var(--ink-3); margin: 4px 2px 10px; }
.list-meta b { color: var(--ink); }

/* table */
.tbl { width: 100%; border-collapse: collapse; }
.tbl th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); font-weight: 650; padding: 12px 16px; background: var(--surface-2); border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl td { padding: 13px 16px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.tbl tbody tr { cursor: pointer; transition: background .2s; }
.tbl tbody tr:hover { background: #F7F8FC; }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl .n { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tbl td.n .meter { width: 90px; margin-left: auto; }
.tbl tr.r-low { background: linear-gradient(90deg, rgba(255, 245, 229, .7), transparent 40%); }
.tbl tr.r-out { background: linear-gradient(90deg, rgba(253, 236, 236, .8), transparent 40%); }
.it-n { display: flex; align-items: center; gap: 12px; min-width: 240px; }
.it-n b { display: block; font-size: 14px; }
.it-n span { font-size: 12px; color: var(--ink-3); }
.loc { font-size: 12.5px; color: var(--ink-2); white-space: nowrap; }
.loc .ic { width: 14px; height: 14px; color: var(--ink-3); vertical-align: -2px; margin-right: 5px; }
.q { font-size: 16px; font-weight: 750; }
.flash-in { animation: flashIn 2.4s var(--ease); }
.flash-out { animation: flashOut 2.4s var(--ease); }
.flash-adj { animation: flashAdj 2.4s var(--ease); }
@keyframes flashIn { 0%, 35% { background-color: #D8F5E8; } 100% { background-color: transparent; } }
@keyframes flashOut { 0%, 35% { background-color: #FFE7D6; } 100% { background-color: transparent; } }
@keyframes flashAdj { 0%, 35% { background-color: #EDE5FF; } 100% { background-color: transparent; } }
.only-mob { display: none; }
.scards { display: flex; flex-direction: column; gap: 10px; }
.scard { display: block; width: 100%; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px; box-shadow: var(--shadow-sm); transition: transform .15s; }
.scard:active { transform: scale(.985); }
.scard.r-low { border-left: 4px solid var(--low); }
.scard.r-out { border-left: 4px solid var(--out); }
.sc-top { display: flex; justify-content: space-between; gap: 12px; }
.sc-top b { display: block; font-size: 14.5px; line-height: 1.3; }
.sc-top span { display: block; font-size: 12px; color: var(--ink-3); margin-top: 2px; }
.sc-q { text-align: right; flex: none; }
.sc-q .q { display: block; font-size: 22px; line-height: 1.1; }
.sc-q small { color: var(--ink-3); }
.sc-bot { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; font-size: 12.5px; color: var(--ink-2); font-weight: 550; }

/* ---------- modals ---------- */
.mb { position: fixed; inset: 0; z-index: 60; display: flex; align-items: center; justify-content: center; padding: 20px; }
.mb-bg { position: absolute; inset: 0; background: rgba(11, 18, 32, .5); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); opacity: 0; transition: opacity .28s var(--ease); }
.mb-panel { position: relative; background: var(--surface); border-radius: 20px; box-shadow: var(--shadow-lg); width: min(520px, 100%); max-height: calc(100vh - 40px); overflow-y: auto; opacity: 0; transform: translateY(16px) scale(.97); transition: opacity .28s var(--ease), transform .38s var(--spring); }
.mb.in .mb-bg { opacity: 1; }
.mb.in .mb-panel { opacity: 1; transform: none; }
.mb.out .mb-panel { transition-duration: .22s; transform: translateY(10px) scale(.98); }
.mb.drawer { justify-content: flex-end; padding: 0; }
.mb.drawer .mb-panel { width: min(500px, 100%); height: 100%; max-height: 100vh; border-radius: 22px 0 0 22px; transform: translateX(40px); }
.mb.drawer.in .mb-panel { transform: none; }
.mb.sheet .mb-panel { padding: 18px 20px 22px; }
.mb.succ-modal .mb-panel { width: min(560px, 100%); }
.mb-x { position: absolute; right: 14px; top: 14px; }
.sheet-h { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.sheet-h b { font-size: 18px; }

/* full-version + confirm */
.fv { padding: 30px 28px 26px; text-align: center; }
.fv-ic { width: 60px; height: 60px; margin: 0 auto 16px; border-radius: 18px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--brand-2), var(--cyan)); box-shadow: 0 12px 26px -10px rgba(79, 70, 229, .65); animation: pop .5s var(--spring) .1s both; }
.fv-ic .ic { width: 28px; height: 28px; }
.fv-ic.warn { background: linear-gradient(135deg, #FBBF24, #EA580C); box-shadow: 0 12px 26px -10px rgba(234, 88, 12, .5); }
@keyframes pop { from { transform: scale(.5); opacity: 0; } to { transform: none; opacity: 1; } }
.fv h2 { font-size: 22px; margin: 8px 0 8px; }
.fv p { color: var(--ink-2); max-width: 400px; margin: 0 auto; }
.fv-list { list-style: none; padding: 0; margin: 18px auto 0; max-width: 380px; text-align: left; display: flex; flex-direction: column; gap: 9px; }
.fv-list li { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; }
.fv-list .ic { color: var(--ok); width: 18px; height: 18px; margin-top: 1px; }
.fv-act { display: flex; flex-direction: column; gap: 10px; margin-top: 24px; }

/* drawer */
.dr-head { position: sticky; top: 0; z-index: 2; display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 22px 22px 16px; background: rgba(255, 255, 255, .92); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line-2); }
.dr-head h2 { font-size: 20px; margin: 8px 0 2px; line-height: 1.25; }
.dr-head p { color: var(--ink-3); font-size: 13px; }
.dr-body { padding: 18px 22px 28px; display: flex; flex-direction: column; gap: 16px; }
.dr-body > * { animation: rise .5s var(--ease) both; }
.dr-body > *:nth-child(2) { animation-delay: 40ms; } .dr-body > *:nth-child(3) { animation-delay: 80ms; } .dr-body > *:nth-child(4) { animation-delay: 120ms; } .dr-body > *:nth-child(5) { animation-delay: 160ms; } .dr-body > *:nth-child(n+6) { animation-delay: 200ms; }
.dr-qty { display: flex; justify-content: space-between; align-items: flex-end; }
.dr-qty b { font-size: 44px; font-weight: 800; letter-spacing: -.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.dr-qty span { display: block; color: var(--ink-3); font-size: 13px; margin-top: 4px; }
.dr-val { text-align: right; }
.dr-val b { font-size: 20px; letter-spacing: -.02em; }
.dr-body .meter { height: 8px; margin-top: -6px; }
.meter-leg { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--ink-3); margin-top: -8px; }
.meter-leg b { color: var(--ink-2); }
.sug { display: flex; gap: 12px; padding: 14px; border-radius: 14px; background: var(--low-soft); border: 1px solid #FBE3B8; }
.sug.out { background: var(--out-soft); border-color: #F8CFCF; }
.sug-ic { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: #fff; color: var(--low); flex: none; }
.sug.out .sug-ic { color: var(--out); }
.sug-b b { display: block; font-size: 14.5px; }
.sug-b p { font-size: 13px; color: var(--ink-2); margin: 3px 0 10px; }
.kv { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--line-2); border: 1px solid var(--line-2); border-radius: 14px; overflow: hidden; }
.kv > div { background: var(--surface); padding: 11px 13px; }
.kv span { display: block; font-size: 11.5px; color: var(--ink-3); font-weight: 550; }
.kv b { font-size: 13.5px; }
.spark-box { padding: 14px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--line-2); }
.sb-h { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; font-size: 13px; }
.sb-h span { color: var(--ink-3); font-size: 12px; }
.spark { width: 100%; height: 64px; display: block; }
.spark rect { fill: url(#none); fill: var(--brand-2); opacity: .85; transform-box: fill-box; transform-origin: bottom; animation: growY .6s var(--ease) both; animation-delay: calc(var(--d) + 150ms); }
.spark rect:last-child { fill: var(--cyan); }
@keyframes growY { from { transform: scaleY(0); } to { transform: scaleY(1); } }
.dr-act { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.dr-sec .feed .mv { cursor: default; }
.dr-foot { display: flex; gap: 8px; flex-wrap: wrap; padding-top: 4px; border-top: 1px dashed var(--line); }
.dr-foot .btn { margin-top: 12px; }

/* more sheet */
.more-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.more-list > a, .more-list > button { display: flex; align-items: center; gap: 14px; padding: 14px; border-radius: 13px; border: 1px solid var(--line); width: 100%; }
.more-list > * > .ic:first-child { width: 22px; height: 22px; color: var(--brand); }
.more-list span { flex: 1; }
.more-list b { display: block; }
.more-list small { color: var(--ink-3); }
.more-list > * > .ic:last-child { color: var(--ink-3); width: 16px; height: 16px; }
.more-list.compact > * { padding: 11px 14px; border-style: dashed; color: var(--ink-2); }
.more-list.compact > * > .ic:first-child { color: var(--ink-3); }
.mb.sheet .btn.block + .btn.block { margin-top: 8px; }

/* ---------- forms (receive / release / count) ---------- */
.form-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 18px; align-items: start; }
.card.side { position: sticky; top: 80px; display: flex; flex-direction: column; gap: 16px; }
.field label { display: block; font-size: 12.5px; font-weight: 650; color: var(--ink-2); margin-bottom: 7px; }
.field label small { font-weight: 500; color: var(--ink-3); }
.input { width: 100%; min-height: 46px; padding: 11px 13px; border-radius: 11px; border: 1px solid var(--line); background: var(--surface); outline: 0; transition: border-color .2s, box-shadow .2s; font-size: 15px; }
.input:focus { border-color: var(--brand-2); box-shadow: 0 0 0 4px rgba(99, 102, 241, .12); }
textarea.input { resize: vertical; min-height: 64px; }
select.input { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%238A94A6' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 6 4 4 4-4'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px; cursor: pointer; }
select.input.need { border-color: #F5C57A; background-color: #FFFBF3; }
.static { padding: 11px 13px; border-radius: 11px; background: var(--surface-2); border: 1px solid var(--line-2); font-weight: 600; }
.static small { display: block; font-weight: 500; color: var(--ink-3); }
.hint { font-size: 12.5px; color: var(--ink-3); }
.hint-lnk { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; font-size: 12px; color: var(--brand); font-weight: 600; }
.hint-lnk .ic { width: 13px; height: 13px; }
.sumbox { display: grid; grid-template-columns: repeat(3, 1fr); border-radius: 13px; background: var(--surface-2); border: 1px solid var(--line-2); }
.sumbox > div { padding: 11px 12px; border-left: 1px solid var(--line-2); }
.sumbox > div:first-child { border-left: 0; }
.sumbox span { display: block; font-size: 11.5px; color: var(--ink-3); font-weight: 550; }
.sumbox b { font-size: 15px; font-variant-numeric: tabular-nums; }
.staff { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.who { display: flex; align-items: center; gap: 9px; padding: 8px; min-height: 52px; border-radius: 12px; border: 1.5px solid var(--line); transition: border-color .2s, background .2s, transform .15s; }
.who:active { transform: scale(.97); }
.who b { display: block; font-size: 13px; line-height: 1.2; }
.who small { display: block; font-size: 11px; color: var(--ink-3); line-height: 1.2; }
.who .av { width: 32px; height: 32px; }
.who.on { border-color: var(--brand-2); background: var(--brand-soft); box-shadow: 0 0 0 3px rgba(99, 102, 241, .12); }
.lines { display: flex; flex-direction: column; }
.line { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "info qty" "prev prev"; gap: 10px 16px; padding: 16px 44px 16px 0; border-top: 1px solid var(--line-2); animation: rise .4s var(--ease) both; }
.line:first-child { border-top: 0; }
.line.added { animation: lineIn 1.6s var(--ease); }
@keyframes lineIn { 0% { background: #EEF0FF; } 100% { background: transparent; } }
.line-info { grid-area: info; min-width: 0; }
.line-info b { display: block; font-size: 14.5px; }
.line-info span { display: block; font-size: 12.5px; color: var(--ink-3); }
.line-info .ord { display: inline-block; margin-top: 4px; padding: 1px 8px; border-radius: 6px; background: var(--info-soft); color: var(--info); font-weight: 600; font-size: 12px; }
.line-qty { grid-area: qty; display: flex; align-items: center; gap: 8px; }
.line-qty .unit { font-size: 12.5px; color: var(--ink-3); min-width: 40px; }
.line-prev { grid-area: prev; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 13px; }
.ba { color: var(--ink-2); font-variant-numeric: tabular-nums; }
.ba i { font-style: normal; color: var(--ink-3); margin: 0 3px; }
.ba b { font-size: 14px; }
.up { color: var(--ok); }
.down { color: #EA580C; }
.bad { color: var(--out); }
.line .rm { position: absolute; right: 0; top: 14px; width: 34px; height: 34px; color: var(--ink-3); }
.stepper { display: flex; align-items: center; border-radius: 13px; border: 1px solid var(--line); background: var(--surface); overflow: hidden; }
.stepper button { width: 46px; height: 48px; display: grid; place-items: center; color: var(--ink-2); transition: background .15s, color .15s; }
.stepper button:hover { background: var(--surface-2); color: var(--brand); }
.stepper button:active { background: var(--brand-soft); }
.stepper input { width: 74px; height: 48px; border: 0; border-left: 1px solid var(--line-2); border-right: 1px solid var(--line-2); text-align: center; font-size: 18px; font-weight: 700; outline: 0; font-variant-numeric: tabular-nums; -moz-appearance: textfield; }
.stepper input::-webkit-outer-spin-button, .stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.stepper:focus-within { border-color: var(--brand-2); box-shadow: 0 0 0 4px rgba(99, 102, 241, .12); }

/* PO cards */
.po-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.po-card { position: relative; display: flex; flex-direction: column; gap: 4px; padding: 18px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); transition: transform .25s var(--ease), box-shadow .25s, border-color .25s; }
.po-card:hover { transform: translateY(-3px); box-shadow: 0 16px 34px -16px rgba(16, 24, 40, .3); border-color: #C7CCF8; }
.po-card.today { border-color: #A7E8CF; background: linear-gradient(180deg, #F2FBF7, #fff 40%); }
.po-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 8px; }
.eta { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 650; color: var(--info); background: var(--info-soft); padding: 3px 9px; border-radius: 7px; }
.eta .ic { width: 13px; height: 13px; }
.po-card.today .eta { color: var(--ok); background: var(--ok-soft); }
.po-id { font-size: 12px; font-weight: 650; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.po-sup { font-size: 16px; }
.po-meta { font-size: 12.5px; color: var(--ink-3); }
.po-card ul { list-style: none; padding: 10px 0 0; margin: 8px 0 0; border-top: 1px dashed var(--line); display: flex; flex-direction: column; gap: 5px; font-size: 13px; }
.po-card li { display: flex; justify-content: space-between; gap: 10px; }
.po-card li span { color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.po-card li b { white-space: nowrap; font-variant-numeric: tabular-nums; }
.po-flag { display: inline-flex; align-items: center; gap: 6px; margin-top: 10px; font-size: 12px; font-weight: 600; color: #B45309; }
.po-flag .ic { width: 14px; height: 14px; }
.po-cta { display: flex; align-items: center; gap: 4px; margin-top: auto; padding-top: 14px; font-weight: 650; color: var(--brand); font-size: 14px; }
.po-cta .ic { width: 16px; height: 16px; transition: transform .2s; }
.po-card:hover .po-cta .ic { transform: translateX(3px); }
.po-card.new { border-style: dashed; box-shadow: none; background: transparent; }
.new-ic { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); margin-bottom: 8px; }
.recent { display: flex; flex-direction: column; }
.rec { display: flex; align-items: center; gap: 12px; padding: 13px 18px; border-top: 1px solid var(--line-2); transition: background .2s; }
.rec:first-child { border-top: 0; }
.rec:hover { background: var(--surface-2); }
.rec > div:nth-child(2) { flex: 1; min-width: 0; }
.rec b { display: block; font-size: 14px; }
.rec span { font-size: 12.5px; color: var(--ink-3); }
.rec-r { display: flex; align-items: center; gap: 8px; }
.rec-r .av { width: 24px; height: 24px; font-size: 9px; }
.rec-r small { color: var(--ink-3); white-space: nowrap; }

/* release */
.ord-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; margin-bottom: 18px; }
.ord { display: flex; flex-direction: column; gap: 3px; padding: 14px 16px; border-radius: 14px; background: var(--surface); border: 1.5px solid var(--line); box-shadow: var(--shadow-sm); transition: border-color .2s, transform .2s var(--ease), box-shadow .2s; }
.ord:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.ord.on { border-color: var(--brand-2); background: var(--brand-soft); }
.ord-top { display: flex; justify-content: space-between; align-items: center; }
.ord-t { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; color: var(--ink-2); }
.ord-t .ic { width: 14px; height: 14px; }
.ord b { font-size: 15px; }
.ord > span:not(.ord-top) { font-size: 12.5px; color: var(--ink-2); }
.ord em { display: inline-flex; align-items: center; gap: 4px; font-style: normal; font-size: 12.5px; font-weight: 650; color: var(--brand); margin-top: 6px; }
.ord em .ic { width: 14px; height: 14px; }
.rtypes { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 18px; }
.rtype { display: flex; align-items: center; justify-content: center; gap: 9px; height: 54px; border-radius: 14px; background: var(--surface); border: 1.5px solid var(--line); font-weight: 650; color: var(--ink-2); transition: all .2s var(--ease); }
.rtype:hover { border-color: #C7CCF8; }
.rtype:active { transform: scale(.97); }
.rtype.on { border-color: var(--brand); color: var(--brand); background: var(--brand-soft); box-shadow: 0 0 0 3px rgba(99, 102, 241, .12); }

/* picker */
.mb.picker .mb-panel { width: min(560px, 100%); }
.scan-row { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; padding: 10px; border-radius: 11px; border: 1px dashed var(--line); color: var(--ink-2); font-size: 13px; font-weight: 600; margin-bottom: 10px; }
.pick-list { display: flex; flex-direction: column; max-height: 55vh; overflow-y: auto; margin: 0 -8px; }
.pick { display: flex; align-items: center; gap: 12px; padding: 12px; min-height: 60px; border-radius: 12px; transition: background .15s; }
.pick:hover { background: var(--surface-2); }
.pick:disabled { opacity: .45; cursor: not-allowed; }
.pk-main { flex: 1; min-width: 0; }
.pk-main b { display: block; font-size: 14px; }
.pk-main small { color: var(--ink-3); }
.pk-q { text-align: right; }
.pk-q b { display: block; font-variant-numeric: tabular-nums; }
.pk-q small { color: var(--ink-3); }
.pk-add { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); flex: none; }
.pick.added .pk-add { background: var(--ok-soft); color: var(--ok); }

/* success */
.succ { padding: 30px 26px 24px; text-align: center; }
.succ h2 { font-size: 23px; margin-top: 12px; }
.succ > p { margin-top: 5px; font-size: 13.5px; }
.succ-ic { width: 76px; height: 76px; margin: 0 auto; }
.succ-ic svg { width: 100%; height: 100%; }
.succ-ic circle { fill: var(--ok-soft); stroke: var(--ok); stroke-width: 2.5; stroke-dasharray: 150; stroke-dashoffset: 150; animation: draw .6s var(--ease) .1s forwards; }
.succ-ic path { fill: none; stroke: var(--ok); stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 40; stroke-dashoffset: 40; animation: draw .4s var(--ease) .55s forwards; }
.succ-ic.rel circle { fill: var(--brand-soft); stroke: var(--brand); }
.succ-ic.rel path { stroke: var(--brand); }
.succ-ic.cnt circle { fill: #F3EEFF; stroke: #7C3AED; }
.succ-ic.cnt path { stroke: #7C3AED; }
@keyframes draw { to { stroke-dashoffset: 0; } }
.succ-rows { margin-top: 18px; border: 1px solid var(--line); border-radius: 14px; text-align: left; overflow: hidden; }
.sr { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 14px; border-top: 1px solid var(--line-2); animation: rise .45s var(--ease) both; }
.sr:nth-child(1) { animation-delay: .25s; } .sr:nth-child(2) { animation-delay: .32s; } .sr:nth-child(3) { animation-delay: .39s; } .sr:nth-child(n+4) { animation-delay: .46s; }
.sr:first-child { border-top: 0; }
.sr-i { min-width: 0; }
.sr-i b { display: block; font-size: 14px; }
.sr-i span { display: block; font-size: 12px; color: var(--ink-3); margin-bottom: 4px; }
.sr-n { display: flex; align-items: baseline; gap: 6px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.sr-n span { color: var(--ink-3); text-decoration: line-through; text-decoration-color: rgba(138, 148, 166, .5); }
.sr-n i { font-style: normal; color: var(--ink-3); }
.sr-n b { font-size: 22px; font-weight: 800; }
.sr-n em { font-style: normal; font-size: 12px; color: var(--ink-3); }
.succ-act { display: flex; flex-direction: column; gap: 10px; margin-top: 20px; }
.alert-card { display: flex; gap: 12px; text-align: left; margin-top: 18px; padding: 14px; border-radius: 14px; background: linear-gradient(180deg, #FFF7EA, #FFF1DB); border: 1px solid #F9D59A; animation: alertIn .7s var(--spring) .5s both; }
.alert-card + .alert-card { margin-top: 10px; }
@keyframes alertIn { 0% { opacity: 0; transform: translateY(8px) scale(.96); } 100% { opacity: 1; transform: none; } }
.ac-ic { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; background: var(--low); color: #fff; flex: none; animation: ring 1.2s ease 1.1s 2; }
@keyframes ring { 0%, 100% { transform: rotate(0); } 15% { transform: rotate(-12deg); } 30% { transform: rotate(10deg); } 45% { transform: rotate(-6deg); } 60% { transform: rotate(3deg); } }
.alert-card b { display: block; color: #7C2D12; font-size: 14.5px; }
.alert-card p { font-size: 13px; color: #92400E; margin-top: 3px; }
.alert-card p b { display: inline; color: #7C2D12; font-size: inherit; }

/* trace */
.trace { margin-bottom: 18px; border-color: #D5D9FB; background: linear-gradient(180deg, #F7F7FF, #fff 120px); }
.tr-h { display: flex; align-items: flex-start; gap: 14px; }
.tr-h > div:nth-child(2) { flex: 1; min-width: 0; }
.tr-h h3 { font-size: 19px; margin-top: 2px; }
.tr-h p { color: var(--ink-3); font-size: 13px; }
.tr-ic { width: 46px; height: 46px; border-radius: 14px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--brand-2), var(--cyan)); flex: none; }
.tr-ic .ic { width: 22px; height: 22px; }
.tr-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-top: 18px; }
.tr-stats > div { padding: 12px 14px; border-radius: 13px; background: var(--surface); border: 1px solid var(--line-2); display: flex; flex-direction: column; gap: 2px; align-items: flex-start; }
.tr-stats span { font-size: 12px; color: var(--ink-3); font-weight: 550; }
.tr-stats b { font-size: 22px; font-weight: 780; font-variant-numeric: tabular-nums; }
.tr-stats b small { font-size: 12px; color: var(--ink-3); font-weight: 500; }
.tr-stats > div > small { color: var(--ink-3); }
.tr-where { margin-top: 18px; display: flex; flex-direction: column; gap: 10px; }
.tr-where > b { font-size: 14px; }
.tw { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) 100px; gap: 14px; align-items: center; font-size: 13.5px; }
.tw-n { font-weight: 600; min-width: 0; }
.tw-n small { display: block; font-weight: 500; color: var(--ink-3); font-size: 12px; }
.tw-q { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
.tw .bar i { background: linear-gradient(90deg, #FB923C, #EA580C); }
.day { margin-bottom: 18px; }
.day-h { display: flex; align-items: baseline; gap: 10px; margin: 0 2px 8px; }
.day-h b { font-size: 15px; }
.day-h span { font-size: 12.5px; color: var(--ink-3); }
.more-btn { margin-top: 4px; }

/* movers */
.mvr { display: flex; flex-direction: column; }
.mvr-row { display: flex; align-items: center; gap: 14px; padding: 12px 8px; margin: 0 -8px; border-radius: 12px; border-top: 1px solid var(--line-2); transition: background .2s; width: calc(100% + 16px); }
.mvr-row:first-child { border-top: 0; }
.mvr-row:hover { background: var(--surface-2); }
.rank { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; font-weight: 750; font-size: 13px; background: var(--brand-soft); color: var(--brand); flex: none; }
.rank.slow { background: #F1F3F7; color: var(--ink-3); }
.rank .ic { width: 16px; height: 16px; }
.mvr-n { flex: 1; min-width: 0; }
.mvr-n b { display: block; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mvr-n small { display: block; color: var(--ink-3); margin-bottom: 6px; }
.mvr-n .bar { height: 6px; }
.mvr-r { display: flex; flex-direction: column; align-items: flex-end; gap: 5px; flex: none; }
.mvr-r b { font-variant-numeric: tabular-nums; }
.tip { display: flex; gap: 10px; margin-top: 14px; padding: 13px 14px; border-radius: 13px; background: var(--brand-soft); color: #3730A3; font-size: 13px; }
.tip .ic { color: var(--brand); margin-top: 1px; }

/* count */
.crows { display: flex; flex-direction: column; }
.crow { display: grid; grid-template-columns: minmax(0, 1fr) 80px 120px 120px; grid-template-areas: "i sys cnt var" "rs rs rs rs"; gap: 6px 14px; align-items: center; padding: 14px 10px; margin: 0 -10px; border-top: 1px solid var(--line-2); border-radius: 12px; }
.crow:first-child { border-top: 0; }
.crow.focus { animation: lineIn 2.4s var(--ease) .3s; }
.cr-i { grid-area: i; min-width: 0; }
.cr-i b { display: block; font-size: 14px; }
.cr-i span { display: block; font-size: 12px; color: var(--ink-3); }
.cr-sys { grid-area: sys; text-align: right; }
.cr-sys span, .cr-cnt span { display: block; font-size: 11px; color: var(--ink-3); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.cr-sys b { font-size: 17px; font-variant-numeric: tabular-nums; }
.cr-sys small { color: var(--ink-3); margin-left: 3px; }
.cr-cnt { grid-area: cnt; }
.cr-cnt .input { text-align: center; font-size: 17px; font-weight: 700; min-height: 48px; padding: 8px; -moz-appearance: textfield; }
.cr-cnt .input::-webkit-outer-spin-button, .cr-cnt .input::-webkit-inner-spin-button { -webkit-appearance: none; }
.cr-var { grid-area: var; text-align: right; }
.var { display: inline-flex; flex-direction: column; align-items: flex-end; font-weight: 700; font-size: 14px; font-variant-numeric: tabular-nums; }
.var small { font-weight: 550; font-size: 12px; }
.var.none { color: var(--ink-3); font-weight: 500; font-size: 12.5px; }
.var.ok { color: var(--ok); flex-direction: row; gap: 4px; align-items: center; }
.var.ok .ic { width: 15px; height: 15px; }
.var.neg { color: var(--out); }
.var.pos { color: var(--ok); }
.cr-rs { grid-area: rs; }
.cr-rs:empty { display: none; }
.cr-rs .input { animation: rise .3s var(--ease) both; }
.switch { display: inline-flex; align-items: center; gap: 10px; font-size: 13.5px; font-weight: 600; cursor: pointer; margin-left: auto; }
.switch small { color: var(--ink-3); font-weight: 500; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch span { width: 42px; height: 24px; border-radius: 12px; background: #D5DAE3; position: relative; transition: background .2s; }
.switch span::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .2); transition: transform .25s var(--spring); }
.switch input:checked + span { background: var(--brand); }
.switch input:checked + span::after { transform: translateX(18px); }
.switch input:focus-visible + span { outline: 2.5px solid var(--brand-2); outline-offset: 2px; }

/* toasts */
.toasts { position: fixed; right: 22px; bottom: 22px; z-index: 90; display: flex; flex-direction: column; gap: 10px; width: min(400px, calc(100vw - 32px)); pointer-events: none; }
.toast { pointer-events: auto; display: flex; gap: 12px; align-items: flex-start; padding: 14px; border-radius: 15px; background: #0F172A; color: #E2E8F0; box-shadow: var(--shadow-lg); opacity: 0; transform: translateY(16px) scale(.96); transition: opacity .3s var(--ease), transform .45s var(--spring); }
.toast.in { opacity: 1; transform: none; }
.toast.out { opacity: 0; transform: translateX(30px); transition-duration: .3s; }
.t-ic { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; flex: none; background: rgba(16, 185, 129, .18); color: #34D399; }
.toast.warn { background: #FFFBF3; color: #7C2D12; border: 1px solid #F9D59A; }
.toast.warn .t-ic { background: var(--low); color: #fff; }
.toast.info .t-ic { background: rgba(129, 140, 248, .2); color: #A5B4FC; }
.t-b { flex: 1; min-width: 0; }
.t-b b { display: block; font-size: 14px; color: inherit; }
.toast:not(.warn) .t-b b { color: #fff; }
.t-b p { font-size: 13px; margin-top: 2px; opacity: .88; }
.t-a { display: inline-flex; align-items: center; gap: 3px; margin-top: 8px; font-weight: 700; font-size: 13px; color: var(--brand); }
.toast:not(.warn) .t-a { color: #A5B4FC; }
.t-a .ic { width: 14px; height: 14px; }
.t-x { width: 26px; height: 26px; border-radius: 7px; display: grid; place-items: center; opacity: .6; flex: none; }
.t-x:hover { opacity: 1; }
.t-x .ic { width: 15px; height: 15px; }

/* ---------- responsive ---------- */
@media (max-width: 1280px) {
  .rrow { grid-template-columns: auto minmax(0, 1fr) 96px 130px; }
  .rrow-sug { display: none; }
}
@media (max-width: 1180px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-21, .g-11 { grid-template-columns: minmax(0, 1fr); }
  .form-grid { grid-template-columns: minmax(0, 1fr); }
  .card.side { position: static; display: grid; grid-template-columns: 1fr 1fr; gap: 16px 20px; align-items: start; }
  .card.side .sumbox, .card.side .submit, .card.side .hint { grid-column: 1 / -1; }
  .tbl th:nth-child(2), .tbl td:nth-child(2), .tbl th:nth-child(4), .tbl td:nth-child(4) { display: none; }
  .it-n { min-width: 200px; }
}
@media (max-width: 1023px) {
  :root { --sidebar: 0px; }
  .sidebar, .topbar { display: none; }
  .main { margin-left: 0; padding-bottom: calc(var(--bnav-h) + env(safe-area-inset-bottom)); }
  .mtop { display: flex; position: sticky; top: 0; z-index: 25; align-items: center; gap: 8px; padding: 10px 16px; padding-top: calc(10px + env(safe-area-inset-top)); background: rgba(11, 18, 32, .94); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); color: #fff; }
  .mt-brand { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; }
  .mt-brand b { display: block; font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .mt-brand span { display: block; font-size: 11.5px; color: #94A3B8; }
  .mtop .icon-btn { color: #CBD5E1; }
  .mtop .icon-btn:hover { background: rgba(255, 255, 255, .08); color: #fff; }
  .mtop .btn { height: 36px; }
  .demo-bar { padding: 7px 16px; font-size: 11.5px; }
  .view, .foot { padding-left: 16px; padding-right: 16px; }
  .bnav { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; height: calc(var(--bnav-h) + env(safe-area-inset-bottom)); padding: 6px 8px env(safe-area-inset-bottom); background: rgba(255, 255, 255, .94); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-top: 1px solid var(--line); }
  .bnav > a, .bnav > button { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: 11px; font-weight: 650; color: var(--ink-3); border-radius: 14px; transition: color .2s, transform .15s; }
  .bnav > *:active { transform: scale(.94); }
  .bnav .ic { width: 22px; height: 22px; }
  .bnav > .on { color: var(--brand); }
  .bnav .bn-in .ic, .bnav .bn-out .ic { width: 42px; height: 34px; padding: 6px 10px; border-radius: 12px; color: #fff; }
  .bnav .bn-in .ic { background: linear-gradient(180deg, #10B981, var(--ok)); box-shadow: 0 6px 14px -6px rgba(5, 150, 105, .6); }
  .bnav .bn-out .ic { background: linear-gradient(180deg, #5B54F0, var(--brand)); box-shadow: 0 6px 14px -6px rgba(79, 70, 229, .6); }
  .bnav .bn-in.on, .bnav .bn-out.on { color: var(--ink); }
  .bnav .badge { position: absolute; top: 2px; left: calc(50% + 6px); min-width: 18px; height: 18px; font-size: 10px; padding: 0 5px; }
  .toasts { left: 16px; right: 16px; width: auto; bottom: calc(var(--bnav-h) + 12px + env(safe-area-inset-bottom)); }
  .card.side { position: static; }
  .card.side .submit { position: sticky; bottom: calc(var(--bnav-h) + 10px + env(safe-area-inset-bottom)); z-index: 5; box-shadow: 0 10px 28px -8px rgba(15, 23, 42, .45); }
}
@media (max-width: 760px) {
  body { font-size: 14px; }
  .ph { margin: 12px 0 16px; align-items: stretch; }
  .ph h1 { font-size: 23px; }
  .ph-r { width: 100%; }
  .ph-r .btn { flex: 1; }
  .kpis, .kpis.three { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .kpis.three .kpi:first-child { grid-column: 1 / -1; }
  .kpi { padding: 14px; }
  .kpi-v { font-size: 23px; }
  .kpi-top { font-size: 12px; }
  .kpi-ic { width: 28px; height: 28px; }
  .kpi-ic .ic { width: 15px; height: 15px; }
  .card { padding: 16px; border-radius: 15px; }
  .card-h { flex-wrap: wrap; }
  .rrow { grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px 12px; }
  .rrow-act { grid-column: 2 / -1; flex-direction: row; justify-content: space-between; align-items: center; }
  .rrow-act .btn { order: 2; }
  .rrow-qty { text-align: right; }
  .rrow-qty span { max-width: 90px; }
  .cat-row { grid-template-columns: 110px minmax(0, 1fr) 82px; }
  .cat-p { display: none; }
  .only-desk { display: none; }
  .only-mob { display: flex; }
  .toolbar { gap: 8px; }
  .toolbar .seg { width: 100%; }
  .toolbar .seg .chip { flex: 1; justify-content: center; padding: 0 8px; }
  .search, .sel { width: 100%; min-width: 0; }
  .sel select { max-width: none; flex: 1; }
  .switch { margin-left: 0; }
  .rtypes { grid-template-columns: repeat(2, 1fr); }
  .rtype { height: 58px; }
  .line { grid-template-areas: "info" "qty" "prev"; grid-template-columns: minmax(0, 1fr); padding-right: 40px; }
  .line-qty { justify-content: flex-start; }
  .stepper button { width: 56px; height: 54px; }
  .stepper input { width: 92px; height: 54px; font-size: 20px; }
  .staff { grid-template-columns: 1fr 1fr; }
  .card.side { display: flex; }
  .po-grid, .ord-row { grid-template-columns: minmax(0, 1fr); }
  .crow { grid-template-columns: minmax(0, 1fr) 1fr 1fr; grid-template-areas: "i i i" "sys cnt var" "rs rs rs"; gap: 8px 12px; }
  .cr-sys { text-align: left; }
  .tr-stats { grid-template-columns: 1fr 1fr; }
  .tw { grid-template-columns: minmax(0, 1fr) 90px; }
  .tw .bar { grid-column: 1 / -1; grid-row: 2; }
  .tr-h { flex-wrap: wrap; }
  .tr-h .btn { width: 100%; }
  .mv-meta span:last-child { flex-basis: 100%; }
  .demo-bar > a { display: none; }
  .demo-bar { justify-content: center; }
  .foot { flex-direction: column; align-items: flex-start; }
  .slow-tease { align-items: flex-start; }
  .slow-tease > .chv { display: none; }
  /* modals become bottom sheets */
  .mb { padding: 0; align-items: flex-end; }
  .mb-panel { width: 100% !important; max-height: 92vh; border-radius: 22px 22px 0 0; transform: translateY(100%); transition: transform .42s cubic-bezier(.2, .9, .25, 1), opacity .2s; padding-bottom: env(safe-area-inset-bottom); }
  .mb-panel::before { content: ''; display: block; width: 40px; height: 4px; border-radius: 4px; background: #D5DAE3; margin: 8px auto 0; }
  .mb.out .mb-panel { transform: translateY(100%); }
  .mb.drawer .mb-panel { height: auto; max-height: 94vh; border-radius: 22px 22px 0 0; transform: translateY(100%); }
  .mb.drawer.in .mb-panel { transform: none; }
  .dr-head { padding: 12px 18px 14px; }
  .dr-body { padding: 16px 18px 28px; }
  .dr-qty b { font-size: 38px; }
  .fv { padding: 22px 20px 22px; }
  .succ { padding: 18px 18px 22px; }
  .pick-list { max-height: 58vh; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0ms !important; transition-duration: .01ms !important; }
}
