@font-face{font-family:Control Display;font-style:normal;font-weight:1 1000;font-display:swap;src:url(/admin-assets/fonts/control-display-0.woff2)format("woff2");unicode-range:U+301,U+400-45F,U+490-491,U+4B0-4B1,U+2116}
@font-face{font-family:Control Display;font-style:normal;font-weight:1 1000;font-display:swap;src:url(/admin-assets/fonts/control-display-1.woff2)format("woff2");unicode-range:U+??,U+131,U+152-153,U+2BB-2BC,U+2C6,U+2DA,U+2DC,U+304,U+308,U+329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}
@font-face{font-family:Control Inter;font-style:normal;font-weight:400;font-display:swap;src:url('/admin-assets/fonts/inter-400.ttf') format('truetype');}
@font-face{font-family:Control Inter;font-style:normal;font-weight:500;font-display:swap;src:url('/admin-assets/fonts/inter-500.ttf') format('truetype');}
@font-face{font-family:Control Inter;font-style:normal;font-weight:600;font-display:swap;src:url('/admin-assets/fonts/inter-600.ttf') format('truetype');}
@font-face{font-family:Control Inter;font-style:normal;font-weight:700;font-display:swap;src:url('/admin-assets/fonts/inter-700.ttf') format('truetype');}
/* I LOVE REDHEAD admin — I LOVE REDHEAD CONTROL — оформление по Olympia */

:root {
  --bg: #0a0a0a;
  --ink: #f5f5f5;
  --ink-2: rgba(245, 245, 245, .66);
  --ink-3: rgba(245, 245, 245, .42);
  --glass: rgba(20, 20, 20, .62);
  --glass-2: rgba(36, 36, 36, .55);
  --glass-hi: rgba(255, 255, 255, .06);
  --line: rgba(255, 255, 255, .08);
  --line-2: rgba(255, 255, 255, .14);
  --amber: #f2f2f2;
  --amber-2: #bdbdbd;
  --amber-ink: #0a0a0a;
  --green: #7ddc9a;
  --red: #ff8a7a;
  --blue: #9ec5ff;
  --violet: #c9a7ff;
  --r: 26px;
  --r-s: 16px;
  --blur: blur(26px) saturate(150%);
  --shadow: 0 20px 60px -20px rgba(0, 0, 0, .65), inset 0 1px 0 rgba(255, 255, 255, .07);
  --ease: cubic-bezier(.2, .8, .2, 1);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; background: var(--bg); color: var(--ink); font: 400 14px/1.45 'Control Inter', Arial, sans-serif; font-feature-settings: 'tnum' 1; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
.bg { position: fixed; inset: -60px; z-index: -1; background:
  radial-gradient(1200px 700px at 12% -10%, rgba(255, 255, 255, .22), transparent 60%),
  radial-gradient(900px 600px at 110% 20%, rgba(255, 255, 255, .18), transparent 60%),
  linear-gradient(180deg, rgba(10, 10, 10, .55), rgba(10, 10, 10, .9)),
  url('/media/hero-desktop.jpg') center 35% / cover no-repeat; filter: blur(30px) grayscale(1) brightness(.8); transform: scale(1.06); }
.bg::after { content: ''; position: absolute; inset: 0; background: radial-gradient(transparent 40%, rgba(0, 0, 0, .55)); }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
img { display: block; max-width: 100%; }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 2px; }
::selection { background: rgba(255, 255, 255, .35); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.boot { min-height: 100vh; display: grid; place-items: center; }
.boot img { width: 54px; filter: invert(1); opacity: .5; animation: pulse 1.4s var(--ease) infinite; }
@keyframes pulse { 50% { opacity: .15; transform: scale(.92); } }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ---------- стекло ---------- */
.glass { background: var(--glass); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); }
.card { background: var(--glass); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 22px; position: relative; min-width: 0; animation: rise .5s var(--ease) both; }
.card--warm { background: linear-gradient(150deg, rgba(255, 255, 255, .16), rgba(255, 255, 255, .05) 60%); border-color: rgba(255, 255, 255, .22); }
.card--flat { animation: none; }
.card__h { display: flex; align-items: center; gap: 10px; margin: -2px 0 16px; min-height: 34px; }
.card__h h2, .card__h h3 { margin: 0; font-size: 15px; font-weight: 500; letter-spacing: .01em; }
.card__h small { color: var(--ink-3); font-size: 12.5px; }
.card__h .sp { flex: 1; }
.grid { stroke: rgba(255, 255, 255, .06); stroke-width: 1; vector-effect: non-scaling-stroke; }

/* ---------- каркас ---------- */
.shell { display: grid; grid-template-columns: 84px minmax(0, 1fr); min-height: 100vh; }
.rail { position: sticky; top: 0; height: 100vh; padding: 16px 12px; display: flex; flex-direction: column; align-items: center; gap: 8px; }
.rail__logo { width: 52px; height: 52px; border-radius: 18px; display: grid; place-items: center; background: linear-gradient(145deg, var(--amber), var(--amber-2)); box-shadow: 0 10px 30px -8px rgba(255, 255, 255, .7); margin-bottom: 10px; }
.rail__logo img { width: 28px; filter: brightness(0) saturate(100%) invert(9%) sepia(32%) saturate(1500%) hue-rotate(350deg); }
.rail nav { display: flex; flex-direction: column; gap: 6px; padding: 8px; border-radius: 30px; background: var(--glass); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); border: 1px solid var(--line); }
.rail a { position: relative; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; color: var(--ink-2); transition: background .2s, color .2s; }
.rail a:hover { background: var(--glass-hi); color: var(--ink); }
.rail a.is-on { background: var(--ink); color: #0a0a0a; box-shadow: 0 6px 20px -6px rgba(255, 255, 255, .5); }
.rail a svg { width: 20px; height: 20px; }
.rail a .dot { position: absolute; top: 6px; right: 6px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: var(--amber); color: var(--amber-ink); font-size: 10px; font-weight: 700; display: grid; place-items: center; }
.rail a::after { content: attr(data-tip); position: absolute; left: calc(100% + 14px); top: 50%; transform: translate(-4px, -50%); white-space: nowrap; padding: 6px 10px; border-radius: 10px; background: rgba(14, 14, 14, .92); border: 1px solid var(--line); font-size: 12.5px; color: var(--ink); opacity: 0; pointer-events: none; transition: .18s var(--ease); z-index: 30; }
.rail a:hover::after { opacity: 1; transform: translate(0, -50%); }
.rail .sp { flex: 1; }
.rail__me { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-2); background: var(--glass-2); display: grid; place-items: center; font-weight: 600; }

.main { padding: 18px 26px 60px 8px; min-width: 0; }
.top { display: flex; align-items: center; gap: 12px; margin-bottom: 22px; position: sticky; top: 0; z-index: 20; padding: 8px 0; }
.crumbs { display: flex; align-items: center; gap: 4px; padding: 6px 16px 6px 6px; border-radius: 999px; background: var(--glass); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); border: 1px solid var(--line); white-space: nowrap; min-width: 0; }
.crumbs b { display: flex; align-items: center; gap: 8px; font-weight: 500; padding: 4px 10px 4px 4px; }
.crumbs b i { width: 30px; height: 30px; border-radius: 50%; background: linear-gradient(145deg, var(--amber), var(--amber-2)); display: grid; place-items: center; font-style: normal; color: var(--amber-ink); font-family: Unbounded, sans-serif; font-size: 11px; font-weight: 800; }
.crumbs span { color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; }
.crumbs span::before { content: '›'; margin: 0 8px 0 2px; }
.search { flex: 1; max-width: 520px; margin: 0 auto; display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 8px 0 18px; border-radius: 999px; background: var(--glass); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); border: 1px solid var(--line); color: var(--ink-3); cursor: text; transition: border-color .2s; }
.search:hover { border-color: var(--line-2); }
.search span { flex: 1; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.search kbd { font: 500 11px/1 'Control Inter'; padding: 6px 8px; border-radius: 999px; background: var(--glass-hi); border: 1px solid var(--line); color: var(--ink-2); }
.top__r { display: flex; align-items: center; gap: 10px; }

/* ---------- кнопки и поля ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 42px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--glass-2); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); color: var(--ink); font-weight: 500; white-space: nowrap; transition: transform .15s var(--ease), background .2s, border-color .2s, box-shadow .2s; }
.btn:hover { background: rgba(255, 255, 255, .1); border-color: rgba(255, 255, 255, .22); }
.btn:active { transform: scale(.97); }
.btn svg { width: 17px; height: 17px; flex: none; }
.btn--amber { background: #f5f5f5; border-color: transparent; color: var(--amber-ink); box-shadow: 0 10px 30px -14px rgba(255, 255, 255, .5); }
.btn--amber:hover { background: #ffffff; }
.btn--light { background: var(--ink); color: #0a0a0a; border-color: transparent; }
.btn--light:hover { background: #fff; }
.btn--ghost { background: transparent; border-color: transparent; backdrop-filter: none; }
.btn--danger { color: var(--red); }
.btn--sm { height: 34px; padding: 0 13px; font-size: 13px; }
.btn--icon { width: 42px; padding: 0; }
.btn--sm.btn--icon { width: 34px; }
.btn[disabled] { opacity: .45; pointer-events: none; }
.btn.is-busy { position: relative; color: transparent !important; pointer-events: none; }
.btn.is-busy::after { content: ''; position: absolute; width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-color: var(--ink) transparent var(--ink) transparent; animation: spin .7s linear infinite; }
.btn--amber.is-busy::after { border-color: var(--amber-ink) transparent var(--amber-ink) transparent; }
@keyframes spin { to { transform: rotate(360deg); } }
.arrow { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line-2); display: grid; place-items: center; color: var(--ink-2); background: rgba(255, 255, 255, .03); transition: .2s; flex: none; }
.arrow:hover { background: var(--ink); color: #0a0a0a; }
.arrow svg { width: 15px; height: 15px; }
.card--warm .arrow { background: var(--ink); color: #0a0a0a; border-color: transparent; }

.field { display: grid; gap: 6px; min-width: 0; }
.field > span { font-size: 12.5px; color: var(--ink-3); letter-spacing: .02em; }
.field > small { font-size: 12px; color: var(--ink-3); }
.input, .select, .textarea { width: 100%; height: 44px; padding: 0 16px; border-radius: 14px; border: 1px solid var(--line); background: rgba(0, 0, 0, .22); outline: none; transition: border-color .2s, background .2s; min-width: 0; }
.textarea { height: auto; min-height: 96px; padding: 12px 16px; resize: vertical; line-height: 1.5; }
.input:hover, .select:hover, .textarea:hover { border-color: var(--line-2); }
.input:focus, .select:focus, .textarea:focus { border-color: rgba(255, 255, 255, .7); background: rgba(0, 0, 0, .3); }
.select { appearance: none; padding-right: 38px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none' stroke='%23f6efe8' stroke-opacity='.6' stroke-width='1.6'%3E%3Cpath d='M1 1.5l5 5 5-5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 15px center; }
.select option { background: #1d1612; }
.input--sm, .select--sm { height: 36px; border-radius: 11px; padding: 0 12px; font-size: 13px; }
.select--sm { padding-right: 32px; background-position: right 11px center; }
.input--num { text-align: center; padding: 0 6px; }
input[type=number]::-webkit-inner-spin-button { opacity: .3; }
input[type=color] { width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 14px; background: rgba(0, 0, 0, .22); padding: 6px; cursor: pointer; }
input[type=color]::-webkit-color-swatch-wrapper { padding: 0; }
input[type=color]::-webkit-color-swatch { border: 0; border-radius: 9px; }
.row { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
.row > .field { flex: 1 1 160px; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; }
.check { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; }
.check input { appearance: none; width: 42px; height: 24px; border-radius: 999px; background: rgba(255, 255, 255, .12); position: relative; cursor: pointer; transition: background .2s; flex: none; margin: 0; }
.check input::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: var(--ink); transition: transform .25s var(--ease); }
.check input:checked { background: var(--amber); }
.check input:checked::after { transform: translateX(18px); background: #fff; }
.box { appearance: none; width: 18px; height: 18px; border-radius: 6px; border: 1.5px solid var(--line-2); background: rgba(0, 0, 0, .2); display: inline-grid; place-items: center; cursor: pointer; margin: 0; vertical-align: middle; }
.box:checked { background: var(--amber); border-color: var(--amber); }
.box:checked::after { content: ''; width: 9px; height: 5px; border: 2px solid var(--amber-ink); border-top: 0; border-right: 0; transform: rotate(-45deg) translate(1px, -1px); }

/* ---------- плитки и пилюли ---------- */
.pill { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 11px; border-radius: 999px; font-size: 12px; font-weight: 500; white-space: nowrap; background: rgba(255, 255, 255, .08); color: var(--ink-2); border: 1px solid var(--line); }
.pill::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .9; }
.pill--plain::before { display: none; }
.st-new { color: #ffffff; background: rgba(255, 255, 255, .14); border-color: rgba(255, 255, 255, .3); }
.st-awaiting_payment { color: #e9d48b; background: rgba(233, 212, 139, .1); }
.st-paid { color: var(--green); background: rgba(125, 220, 154, .12); border-color: rgba(125, 220, 154, .25); }
.st-processing { color: var(--blue); background: rgba(158, 197, 255, .12); border-color: rgba(158, 197, 255, .25); }
.st-shipped { color: var(--violet); background: rgba(201, 167, 255, .12); border-color: rgba(201, 167, 255, .25); }
.st-delivered { color: #d8f5e2; background: rgba(125, 220, 154, .2); }
.st-canceled { color: var(--ink-3); background: rgba(255, 255, 255, .05); }
.st-returned { color: var(--red); background: rgba(255, 138, 122, .1); border-color: rgba(255, 138, 122, .25); }
.seg-vip { color: #ffffff; background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .35); }
.seg-loyal { color: var(--green); background: rgba(125, 220, 154, .12); }
.seg-new { color: var(--blue); background: rgba(158, 197, 255, .12); }
.seg-sleeping { color: var(--violet); background: rgba(201, 167, 255, .1); }
.seg-lead, .seg-lost { color: var(--ink-3); }
.delta { display: inline-flex; align-items: center; gap: 3px; height: 26px; padding: 0 10px; border-radius: 999px; font-size: 12px; font-weight: 600; border: 1px solid; }
.delta--up { color: var(--green); border-color: rgba(125, 220, 154, .35); background: rgba(125, 220, 154, .08); }
.delta--down { color: var(--red); border-color: rgba(255, 138, 122, .35); background: rgba(255, 138, 122, .08); }
.delta--flat { color: var(--ink-3); border-color: var(--line-2); }
.card--warm .delta--up { color: #ffffff; border-color: rgba(255, 255, 255, .35); background: rgba(255, 255, 255, .12); }
.tag { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 8px; background: rgba(255, 255, 255, .07); font-size: 12px; }
.tag button { border: 0; background: none; padding: 0; color: var(--ink-3); font-size: 15px; line-height: 1; }
.muted { color: var(--ink-3); }
.ink2 { color: var(--ink-2); }
.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.empty { color: var(--ink-3); text-align: center; padding: 30px 10px; margin: 0; }
.empty-state { text-align: center; padding: 60px 20px; color: var(--ink-2); }
.empty-state b { display: block; font-size: 18px; color: var(--ink); margin-bottom: 6px; font-weight: 500; }

/* ---------- заголовок страницы ---------- */
.ph { display: flex; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin: 4px 0 22px; }
.ph h1 { margin: 0; font-size: clamp(26px, 3vw, 36px); font-weight: 500; letter-spacing: -.01em; line-height: 1.1; }
.ph p { margin: 6px 0 0; color: var(--ink-2); }
.ph .sp { flex: 1; }
.ph__r { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.seg { display: inline-flex; padding: 4px; gap: 2px; border-radius: 999px; background: var(--glass); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); border: 1px solid var(--line); overflow-x: auto; max-width: 100%; scrollbar-width: none; }
.seg::-webkit-scrollbar { display: none; }
.seg button { height: 34px; padding: 0 14px; border-radius: 999px; border: 0; background: none; color: var(--ink-2); white-space: nowrap; font-size: 13px; transition: .2s; display: inline-flex; align-items: center; gap: 6px; }
.seg button:hover { color: var(--ink); }
.seg button.is-on { background: var(--ink); color: #0a0a0a; font-weight: 500; }
.seg button em { font-style: normal; font-size: 11px; opacity: .6; }

/* ---------- KPI ---------- */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 16px; }
.kpi { display: flex; flex-direction: column; min-height: 168px; }
.kpi__t { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.kpi__t span { color: var(--ink-2); font-size: 13.5px; }
.card--warm .kpi__t span { color: rgba(255, 255, 255, .82); }
.kpi__v { margin-top: auto; display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.kpi__v b { font-size: clamp(26px, 2.4vw, 36px); font-weight: 500; letter-spacing: -.02em; line-height: 1; }
.kpi small { display: block; margin-top: 8px; color: var(--ink-3); font-size: 12px; }
.card--warm .kpi small { color: rgba(255, 255, 255, .7); }
.kpi .spark { width: 100%; height: 30px; margin-top: 10px; opacity: .85; }

/* ---------- сетки страниц ---------- */
.g { display: grid; gap: 16px; margin-bottom: 16px; }
.g-dash { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr); }
.g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g-21 { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.g-12 { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); }
.span-2 { grid-column: span 2; }
.big-stat { display: flex; flex-direction: column; justify-content: space-between; min-height: 300px; }
.big-stat__ico { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .1); border: 1px solid var(--line-2); }
.big-stat__ico svg { width: 18px; height: 18px; }
.big-stat b { font-size: 40px; font-weight: 500; letter-spacing: -.02em; line-height: 1; }
.big-stat b small { font-size: 18px; color: var(--ink-2); font-weight: 400; margin-left: 6px; }
.big-stat p { margin: 10px 0 0; color: var(--ink-3); }
.big-stat p em { color: var(--amber); font-style: normal; }
.stack { display: flex; flex-direction: column; gap: 16px; }

/* ---------- графики ---------- */
.chart { position: relative; height: var(--h); margin-bottom: 26px; touch-action: pan-y; }
.chart svg { width: 100%; height: 100%; display: block; overflow: visible; }
.chart .bar { transition: opacity .2s, filter .2s; }
.chart .bar.is-zero { opacity: .25; }
.chart:hover .bar:not(.is-on) { opacity: .55; }
.chart .bar.is-on { filter: brightness(1.4); }
.chart .cursor { stroke: rgba(255, 255, 255, .35); stroke-width: 1; vector-effect: non-scaling-stroke; stroke-dasharray: 3 4; }
.chart__x { position: absolute; left: 0; right: 0; bottom: -24px; height: 18px; }
.chart__x span { position: absolute; transform: translateX(-50%); font-size: 11px; color: var(--ink-3); white-space: nowrap; }
.chart__tip { position: absolute; top: -10px; transform: translate(-50%, -100%); padding: 7px 12px; border-radius: 12px; background: var(--ink); color: #0a0a0a; font-size: 12.5px; font-weight: 500; white-space: nowrap; pointer-events: none; z-index: 5; box-shadow: 0 8px 24px rgba(0, 0, 0, .4); }
.chart__tip.is-left { transform: translate(-100%, -100%); }
.chart__tip.is-right { transform: translate(0, -100%); }
.chart script { display: none; }
.legend-inline { display: flex; gap: 16px; font-size: 12.5px; color: var(--ink-2); flex-wrap: wrap; }
.legend-inline i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }

.donut-wrap { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 20px; align-items: center; }
.donut { position: relative; width: 170px; aspect-ratio: 1; }
.donut svg { width: 100%; height: 100%; }
.donut__track { fill: none; stroke: rgba(255, 255, 255, .06); stroke-width: 18; }
.donut__c { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.donut__c b { font-size: 26px; font-weight: 500; line-height: 1; }
.donut__c small { color: var(--ink-3); font-size: 12px; margin-top: 4px; }
.legend { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.legend li { display: grid; grid-template-columns: 10px minmax(0, 1fr) auto 42px; gap: 10px; align-items: center; font-size: 13px; }
.legend i { width: 10px; height: 10px; border-radius: 3px; }
.legend span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); }
.legend em { font-style: normal; color: var(--ink-3); text-align: right; font-size: 12px; }
.gauge { position: relative; width: 100%; max-width: 240px; margin: 0 auto; }
.gauge svg { width: 100%; display: block; }
.gauge__track { fill: none; stroke: rgba(255, 255, 255, .07); stroke-width: 14; stroke-linecap: round; }
.gauge__c { position: absolute; left: 0; right: 0; bottom: 0; text-align: center; }
.gauge__c b { display: block; font-size: 30px; font-weight: 500; line-height: 1; }
.gauge__c small { color: var(--ink-3); font-size: 12px; }
.funnel { display: grid; gap: 12px; }
.funnel__label { display: flex; justify-content: space-between; font-size: 13px; color: var(--ink-2); margin-bottom: 5px; }
.funnel__label em { font-style: normal; color: var(--amber); font-size: 12px; }
.funnel__bar { position: relative; height: 34px; border-radius: 12px; background: rgba(255, 255, 255, .04); overflow: hidden; }
.funnel__bar i { position: absolute; inset: 0 auto 0 0; border-radius: 12px; background: linear-gradient(90deg, rgba(255, 255, 255, .85), rgba(255, 255, 255, .25)); transition: width .8s var(--ease); }
.funnel__bar b { position: relative; line-height: 34px; padding-left: 12px; font-weight: 500; font-size: 13.5px; }
.heat { display: grid; gap: 4px; font-size: 10.5px; color: var(--ink-3); overflow-x: auto; }
.heat__h, .heat__r { display: grid; grid-template-columns: 26px repeat(24, minmax(12px, 1fr)); gap: 4px; align-items: center; }
.heat__r i { aspect-ratio: 1; border-radius: 5px; background: rgba(255, 255, 255, var(--a)); outline: 1px solid rgba(255, 255, 255, .04); min-width: 12px; }
.hbars { list-style: none; margin: 0; padding: 0; display: grid; gap: 13px; }
.hbars div { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; margin-bottom: 6px; }
.hbars div span { color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hbars i { display: block; height: 7px; border-radius: 99px; background: rgba(255, 255, 255, .06); overflow: hidden; }
.hbars s { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--amber-2), #ffffff); }
.hbars small { display: block; color: var(--ink-3); font-size: 11.5px; margin-top: 4px; }

/* ---------- списки и таблицы ---------- */
.tbl-wrap { overflow-x: auto; margin: 0 -22px -22px; padding: 0 22px 10px; }
.tbl { width: 100%; border-collapse: separate; border-spacing: 0; min-width: 760px; }
.tbl th { text-align: left; font-weight: 400; font-size: 12px; color: var(--ink-3); padding: 0 12px 12px; white-space: nowrap; letter-spacing: .02em; }
.tbl th button { border: 0; background: none; padding: 0; color: inherit; font: inherit; display: inline-flex; gap: 4px; align-items: center; }
.tbl th button.is-on { color: var(--ink); }
.tbl td { padding: 12px; border-top: 1px solid var(--line); vertical-align: middle; }
.tbl tbody tr { transition: background .15s; }
.tbl tbody tr.is-link { cursor: pointer; }
.tbl tbody tr:hover td { background: rgba(255, 255, 255, .035); }
.tbl tbody tr:hover td:first-child { border-radius: 14px 0 0 14px; }
.tbl tbody tr:hover td:last-child { border-radius: 0 14px 14px 0; }
.tbl .r { text-align: right; }
.tbl .c { text-align: center; }
.tbl .w1 { width: 1%; white-space: nowrap; }
.who { display: flex; align-items: center; gap: 12px; min-width: 0; }
.who > div { min-width: 0; }
.who b { display: block; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 240px; }
.who small { display: block; color: var(--ink-3); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 240px; }
.av { width: 38px; height: 38px; border-radius: 50%; flex: none; display: grid; place-items: center; font-weight: 600; font-size: 13px; color: #0a0a0a; background: linear-gradient(145deg, hsl(var(--hue, 28) 80% 78%), hsl(var(--hue, 28) 60% 58%)); }
.av--lg { width: 72px; height: 72px; font-size: 24px; }
.thumbs { display: flex; }
.thumbs img, .thumb { width: 40px; height: 48px; border-radius: 10px; object-fit: cover; background: #e6e6e6; border: 2px solid rgba(14, 14, 14, .9); flex: none; }
.thumbs img + img { margin-left: -14px; }
.thumbs em { margin-left: -14px; width: 40px; height: 48px; border-radius: 10px; border: 2px solid rgba(14, 14, 14, .9); background: #2a211b; display: grid; place-items: center; font-style: normal; font-size: 12px; }
.thumb--lg { width: 64px; height: 78px; border-radius: 14px; }
.list { list-style: none; margin: 0; padding: 0; }
.list > li { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-top: 1px solid var(--line); }
.list > li:first-child { border-top: 0; padding-top: 0; }
.list > li > .sp { flex: 1; min-width: 0; }
.list a.li-link { display: contents; }
.list b { font-weight: 500; }
.bulk { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); z-index: 40; display: flex; gap: 10px; align-items: center; padding: 8px 8px 8px 20px; border-radius: 999px; background: rgba(28, 21, 17, .9); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); border: 1px solid var(--line-2); box-shadow: 0 20px 60px rgba(0, 0, 0, .5); animation: rise .3s var(--ease); }
.pager { display: flex; gap: 8px; justify-content: center; align-items: center; margin-top: 18px; color: var(--ink-3); font-size: 13px; }

/* ---------- канбан ---------- */
.kanban { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(260px, 1fr); gap: 14px; overflow-x: auto; padding-bottom: 12px; }
.kcol { display: flex; flex-direction: column; gap: 10px; padding: 14px; min-height: 420px; border-radius: var(--r); background: rgba(14, 14, 14, .35); border: 1px solid var(--line); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); transition: background .2s, border-color .2s; }
.kcol.is-over { background: rgba(255, 255, 255, .12); border-color: rgba(255, 255, 255, .45); }
.kcol__h { display: flex; justify-content: space-between; align-items: center; padding: 2px 4px 6px; }
.kcol__h small { color: var(--ink-3); }
.kcard { padding: 14px; border-radius: 18px; background: var(--glass-2); border: 1px solid var(--line); cursor: grab; transition: transform .15s var(--ease), border-color .2s; }
.kcard:hover { border-color: var(--line-2); }
.kcard.is-drag { opacity: .4; }
.kcard__t { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 8px; font-size: 13px; }
.kcard__t b { font-weight: 500; }
.kcard p { margin: 8px 0 0; font-size: 12.5px; color: var(--ink-3); }

/* ---------- заказ ---------- */
.o-lines .list > li { padding: 14px 0; }
.totals { display: grid; gap: 8px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }
.totals div { display: flex; justify-content: space-between; color: var(--ink-2); }
.totals div:last-child { color: var(--ink); font-size: 18px; font-weight: 500; padding-top: 6px; }
.status-pick { display: flex; flex-wrap: wrap; gap: 8px; }
.status-pick button { height: 34px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: rgba(255, 255, 255, .03); color: var(--ink-2); font-size: 13px; transition: .2s; }
.status-pick button:hover { border-color: var(--line-2); color: var(--ink); }
.status-pick button.is-on { background: var(--ink); color: #0a0a0a; border-color: transparent; font-weight: 500; }
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline li { position: relative; padding: 0 0 18px 26px; }
.timeline li::before { content: ''; position: absolute; left: 5px; top: 8px; bottom: -6px; width: 1px; background: var(--line-2); }
.timeline li:last-child::before { display: none; }
.timeline li::after { content: ''; position: absolute; left: 0; top: 4px; width: 11px; height: 11px; border-radius: 50%; background: var(--glass-2); border: 2px solid var(--amber); }
.timeline li.is-note::after { border-color: var(--blue); }
.timeline b { font-weight: 500; }
.timeline small { display: block; color: var(--ink-3); font-size: 12px; }
.timeline p { margin: 6px 0 0; padding: 10px 14px; border-radius: 14px; background: rgba(255, 255, 255, .05); white-space: pre-wrap; color: var(--ink-2); }
.kv { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 9px 18px; margin: 0; font-size: 13.5px; }
.kv dt { color: var(--ink-3); }
.kv dd { margin: 0; overflow-wrap: anywhere; }
.copy { border: 0; background: none; padding: 0 0 0 6px; color: var(--ink-3); vertical-align: middle; }
.copy:hover { color: var(--amber); }
.copy svg { width: 13px; height: 13px; }

/* ---------- клиент ---------- */
.profile { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.profile h2 { margin: 0; font-size: 24px; font-weight: 500; }
.profile .acts { display: flex; gap: 8px; margin-left: auto; flex-wrap: wrap; }
.minis { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 12px; margin-top: 20px; }
.mini { padding: 14px 16px; border-radius: 18px; background: rgba(255, 255, 255, .04); border: 1px solid var(--line); }
.mini span { display: block; font-size: 12px; color: var(--ink-3); }
.mini b { display: block; margin-top: 6px; font-size: 20px; font-weight: 500; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.tags input { width: 140px; }

/* ---------- товары ---------- */
.pgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; }
.pcard { padding: 12px; display: flex; flex-direction: column; gap: 12px; cursor: pointer; transition: transform .25s var(--ease), border-color .2s; }
.pcard:hover { transform: translateY(-3px); border-color: var(--line-2); }
.pcard__img { position: relative; aspect-ratio: 4 / 5; border-radius: 18px; overflow: hidden; background: var(--tone, #eee); }
.pcard__img img { width: 100%; height: 100%; object-fit: cover; }
.pcard__img .pill { position: absolute; left: 10px; top: 10px; backdrop-filter: blur(10px); background: rgba(14, 14, 14, .6); }
.pcard__img .dots { position: absolute; right: 10px; bottom: 10px; display: flex; gap: 4px; padding: 5px; border-radius: 99px; background: rgba(14, 14, 14, .55); backdrop-filter: blur(8px); }
.pcard__img .dots i { width: 12px; height: 12px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .4); }
.pcard h3 { margin: 0; font-size: 14.5px; font-weight: 500; line-height: 1.3; }
.pcard__m { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.pcard__m s { color: var(--ink-3); font-size: 12.5px; margin-left: 6px; }
.pcard__s { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.pcard__s div { padding: 8px 6px; border-radius: 12px; background: rgba(255, 255, 255, .04); text-align: center; }
.pcard__s span { display: block; font-size: 10.5px; color: var(--ink-3); }
.pcard__s b { font-size: 14px; font-weight: 500; }
.pcard.is-hidden .pcard__img img { opacity: .4; filter: grayscale(1); }
.stockbar { height: 6px; border-radius: 99px; background: rgba(255, 255, 255, .07); overflow: hidden; }
.stockbar i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--amber-2), #ffffff); }

.editor { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 16px; align-items: start; }
.editor__side { position: sticky; top: 90px; display: flex; flex-direction: column; gap: 16px; }
.sec h3 { margin: 0 0 16px; font-size: 15px; font-weight: 500; display: flex; align-items: center; gap: 10px; }
.sec h3 small { color: var(--ink-3); font-weight: 400; font-size: 12.5px; }
.sec + .sec { margin-top: 16px; }
.sizes-ed { display: grid; gap: 8px; }
.sizes-ed > div { display: grid; grid-template-columns: 110px minmax(0, 1fr) auto auto; gap: 8px; align-items: center; }
.color-ed { padding: 16px; border-radius: 20px; background: rgba(0, 0, 0, .18); border: 1px solid var(--line); }
.color-ed + .color-ed { margin-top: 12px; }
.color-ed__h { display: grid; grid-template-columns: 44px minmax(0, 1fr) minmax(0, 1fr) 110px auto; gap: 8px; align-items: center; }
.imgs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.imgs figure { position: relative; margin: 0; width: 76px; height: 94px; border-radius: 12px; overflow: hidden; background: #ddd; cursor: grab; }
.imgs figure img { width: 100%; height: 100%; object-fit: cover; }
.imgs figure button { position: absolute; top: 4px; right: 4px; width: 22px; height: 22px; border-radius: 50%; border: 0; background: rgba(14, 14, 14, .75); color: #fff; font-size: 14px; line-height: 1; opacity: 0; transition: .15s; }
.imgs figure:hover button { opacity: 1; }
.imgs figure em { position: absolute; left: 4px; bottom: 4px; font-style: normal; font-size: 10px; padding: 2px 6px; border-radius: 6px; background: rgba(14, 14, 14, .75); }
.imgs .add { width: 76px; height: 94px; border-radius: 12px; border: 1.5px dashed var(--line-2); background: none; color: var(--ink-3); display: grid; place-items: center; font-size: 22px; }
.imgs .add:hover { border-color: var(--amber); color: var(--amber); }
.stock-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; align-items: center; }
.stock-row label { display: grid; gap: 4px; text-align: center; font-size: 11.5px; color: var(--ink-3); width: 64px; }
.margin-box { display: flex; justify-content: space-between; padding: 12px 16px; border-radius: 14px; background: rgba(125, 220, 154, .08); color: var(--green); font-size: 13px; }

.matrix { border-collapse: separate; border-spacing: 6px; }
.matrix th { font-weight: 400; font-size: 12px; color: var(--ink-3); padding: 0 4px; }
.matrix th:first-child { text-align: left; }
.matrix td input { width: 64px; height: 38px; border-radius: 11px; text-align: center; border: 1px solid var(--line); background: rgba(0, 0, 0, .22); outline: none; transition: .2s; }
.matrix td input:focus { border-color: var(--amber); }
.matrix td input.is-low { border-color: rgba(255, 255, 255, .55); background: rgba(255, 255, 255, .1); }
.matrix td input.is-out { border-color: rgba(255, 138, 122, .45); background: rgba(255, 138, 122, .08); color: var(--red); }
.matrix td input.is-changed { box-shadow: 0 0 0 2px var(--amber); }
.matrix td.cname { padding-right: 14px; white-space: nowrap; }
.matrix td.cname i { display: inline-block; width: 12px; height: 12px; border-radius: 50%; margin-right: 8px; vertical-align: -1px; border: 1px solid rgba(255, 255, 255, .3); }
.stock-block { display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 18px; padding: 18px 0; border-top: 1px solid var(--line); }
.stock-block:first-of-type { border-top: 0; padding-top: 0; }
.stock-block > img { width: 90px; height: 110px; border-radius: 14px; object-fit: cover; background: #e6e6e6; }
.stock-block h3 { margin: 0 0 8px; font-weight: 500; font-size: 15px; }
.stock-block .matrix-wrap { overflow-x: auto; }

/* ---------- модалка, палитра, тосты ---------- */
.modal { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 20px; background: rgba(8, 6, 5, .6); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); animation: fade .2s; }
@keyframes fade { from { opacity: 0; } }
.modal__box { width: min(640px, 100%); max-height: calc(100vh - 40px); overflow: auto; padding: 26px; border-radius: 28px; background: rgba(32, 25, 20, .92); border: 1px solid var(--line-2); box-shadow: 0 40px 100px rgba(0, 0, 0, .6); animation: rise .3s var(--ease); }
.modal__box--wide { width: min(980px, 100%); }
.modal__h { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.modal__h h2 { margin: 0; font-size: 20px; font-weight: 500; flex: 1; }
.modal__f { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; flex-wrap: wrap; }
.lib { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 10px; }
.lib button { position: relative; padding: 0; border: 2px solid transparent; border-radius: 14px; overflow: hidden; background: #ddd; aspect-ratio: 4 / 5; transition: border-color .15s; }
.lib button img { width: 100%; height: 100%; object-fit: cover; }
.lib button.is-on { border-color: var(--amber); }
.lib button.is-on::after { content: '✓'; position: absolute; top: 6px; right: 6px; width: 22px; height: 22px; border-radius: 50%; background: var(--amber); color: var(--amber-ink); font-size: 12px; font-weight: 700; display: grid; place-items: center; }
.lib button span { position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 6px 4px; font-size: 10px; color: #fff; background: linear-gradient(transparent, rgba(0, 0, 0, .7)); text-align: left; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.drop { display: grid; place-items: center; gap: 6px; padding: 22px; border-radius: 18px; border: 1.5px dashed var(--line-2); color: var(--ink-3); text-align: center; margin-bottom: 16px; transition: .2s; cursor: pointer; }
.drop.is-over, .drop:hover { border-color: var(--amber); color: var(--ink); background: rgba(255, 255, 255, .06); }
.palette { position: fixed; inset: 0; z-index: 70; background: rgba(8, 6, 5, .55); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); display: flex; justify-content: center; align-items: flex-start; padding: 12vh 16px 16px; animation: fade .15s; }
.palette__box { width: min(640px, 100%); border-radius: 26px; background: rgba(32, 25, 20, .94); border: 1px solid var(--line-2); box-shadow: 0 40px 100px rgba(0, 0, 0, .6); overflow: hidden; animation: rise .25s var(--ease); }
.palette__in { display: flex; align-items: center; gap: 12px; padding: 0 20px; border-bottom: 1px solid var(--line); }
.palette__in input { flex: 1; height: 60px; border: 0; background: none; outline: none; font-size: 17px; }
.palette__res { max-height: 60vh; overflow: auto; padding: 8px; }
.palette__res h4 { margin: 10px 12px 6px; font-size: 11px; font-weight: 500; color: var(--ink-3); text-transform: uppercase; letter-spacing: .08em; }
.palette__res a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 14px; }
.palette__res a:hover, .palette__res a.is-sel { background: rgba(255, 255, 255, .07); }
.palette__res a .sp { flex: 1; min-width: 0; }
.palette__res a small { display: block; color: var(--ink-3); font-size: 12px; }
.toasts { position: fixed; right: 20px; bottom: 20px; z-index: 90; display: grid; gap: 10px; }
.toast { padding: 12px 18px; border-radius: 16px; background: var(--ink); color: #0a0a0a; font-weight: 500; box-shadow: 0 16px 40px rgba(0, 0, 0, .45); animation: rise .3s var(--ease); max-width: 360px; }
.toast--err { background: #ffb1a6; }

/* ---------- вход ---------- */
.login { min-height: 100vh; display: grid; place-items: center; padding: 20px; }
.login__box { width: min(420px, 100%); padding: 34px; }
.login__logo { display: flex; align-items: center; gap: 12px; margin-bottom: 28px; }
.login__logo .rail__logo { margin: 0; }
.login__logo b { font-family: Unbounded, sans-serif; font-weight: 800; font-size: 20px; letter-spacing: .04em; }
.login__logo small { display: block; color: var(--ink-3); font-size: 12.5px; }
.login form { display: grid; gap: 14px; }
.login .err { color: var(--red); margin: 0; font-size: 13px; }

/* ---------- настройки ---------- */
.set-nav { display: flex; flex-direction: column; gap: 4px; }
.set-nav button { text-align: left; border: 0; background: none; padding: 11px 14px; border-radius: 14px; color: var(--ink-2); display: flex; gap: 10px; align-items: center; }
.set-nav button:hover { background: rgba(255, 255, 255, .05); color: var(--ink); }
.set-nav button.is-on { background: rgba(255, 255, 255, .09); color: var(--ink); }
.set-nav svg { width: 17px; height: 17px; }
.int { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-top: 1px solid var(--line); }
.int:first-child { border-top: 0; }
.int b { font-weight: 500; }
.int .sp { flex: 1; }
.banner-ed { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 16px; padding: 16px; border-radius: 20px; background: rgba(0, 0, 0, .18); border: 1px solid var(--line); }
.banner-ed + .banner-ed { margin-top: 12px; }
.banner-ed__img { display: flex; gap: 4px; height: 120px; border-radius: 14px; overflow: hidden; }
.banner-ed__img img { flex: 1; min-width: 0; object-fit: cover; }

@media print {
  body { background: #fff; color: #000; }
  .bg, .rail, .top, .no-print, .toasts { display: none !important; }
  .shell { display: block; }
  .main { padding: 0; }
  .card { background: none; border: 1px solid #ccc; box-shadow: none; backdrop-filter: none; color: #000; animation: none; }
  .muted, .kv dt { color: #555; }
}

/* ---------- адаптив ---------- */
@media (max-width: 1280px) {
  .g-dash { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .g-dash > :first-child { grid-column: span 2; }
  .editor { grid-template-columns: minmax(0, 1fr); }
  .editor__side { position: static; }
}
@media (max-width: 1080px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g-3 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .g-21, .g-12 { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 760px) {
  body { font-size: 14.5px; }
  .shell { grid-template-columns: minmax(0, 1fr); }
  .rail { position: fixed; top: auto; bottom: 0; left: 0; right: 0; height: auto; z-index: 50; padding: 0 10px calc(10px + env(safe-area-inset-bottom)); flex-direction: row; justify-content: center; }
  .rail .rail__logo, .rail .sp, .rail .rail__me { display: none; }
  .rail nav { flex-direction: row; gap: 2px; padding: 6px; overflow-x: auto; max-width: 100%; scrollbar-width: none; background: rgba(30, 23, 19, .82); }
  .rail nav::-webkit-scrollbar { display: none; }
  .rail a { width: 46px; height: 46px; flex: none; }
  .rail a::after { display: none; }
  .main { padding: 10px 16px 120px; }
  .top { gap: 8px; margin-bottom: 14px; }
  .crumbs { display: none; }
  .search { height: 44px; }
  .search kbd { display: none; }
  .top__r .btn span, .top__r .hide-sm { display: none; }
  .top__r .btn--amber { width: 44px; padding: 0; }
  .kpis { gap: 10px; }
  .kpi { min-height: 140px; padding: 16px; }
  .kpi__v b { font-size: 24px; }
  .card { padding: 18px; --r: 22px; }
  .tbl-wrap { margin: 0 -18px -18px; padding: 0 18px 10px; }
  .g-dash, .g-2, .g-3 { grid-template-columns: minmax(0, 1fr); }
  .g-dash > :first-child, .span-2 { grid-column: auto; }
  .big-stat { min-height: 200px; }
  .donut-wrap { grid-template-columns: minmax(0, 1fr); justify-items: center; }
  .donut-wrap .legend { width: 100%; }
  .ph { margin-bottom: 16px; }
  .ph__r { width: 100%; }
  .color-ed__h { grid-template-columns: 44px minmax(0, 1fr) auto; }
  .color-ed__h .hide-sm { display: none; }
  .sizes-ed > div { grid-template-columns: 80px minmax(0, 1fr) auto auto; }
  .banner-ed { grid-template-columns: minmax(0, 1fr); }
  .stock-block { grid-template-columns: minmax(0, 1fr); }
  .stock-block > img { display: none; }
  .bulk { bottom: 92px; left: 16px; right: 16px; transform: none; justify-content: space-between; }
  .toasts { left: 16px; right: 16px; bottom: 96px; }
  .modal { padding: 0; align-items: end; }
  .modal__box { border-radius: 26px 26px 0 0; max-height: 92vh; padding: 22px 18px calc(22px + env(safe-area-inset-bottom)); }
  .chart__x span:nth-child(even) { display: none; }
}

[hidden] { display: none !important; }

/* ================= телефон: удобная админка ================= */
.nav-t, .nav-more { display: none; }
.more-nav { display: grid; gap: 4px; margin: 4px 0 8px; }
.more-nav a { display: flex; align-items: center; gap: 14px; min-height: 50px; padding: 0 14px; border-radius: 16px; color: var(--ink-2); }
.more-nav a svg { width: 20px; height: 20px; flex: none; }
.more-nav a.is-on, .more-nav a:active { background: rgba(255, 255, 255, .08); color: var(--ink); }
.o-sum { display: flex; align-items: baseline; gap: 14px; margin-left: auto; white-space: nowrap; }
.o-sum b { min-width: 90px; text-align: right; }

@media (max-width: 760px) {
  /* без зума: поля ввода не меньше 16px — иначе iPhone приближает страницу при фокусе */
  input, select, textarea, .input, .select, .textarea { font-size: 16px !important; }
  html { touch-action: manipulation; }
  html, body { overflow-x: hidden; max-width: 100%; }
  @supports (overflow: clip) { html, body { overflow-x: clip; } }

  /* нижняя панель: 4 главных раздела + «Ещё», с подписями */
  .rail nav { overflow: visible; gap: 0; padding: 6px; width: 100%; max-width: 460px; justify-content: space-between; }
  .rail nav > .nav-x { display: none; }
  .rail nav > a, .rail nav > .nav-more { position: relative; display: grid; place-items: center; align-content: center; gap: 3px; flex: 1 1 0; width: auto; height: 56px; border-radius: 18px; }
  .rail nav > .nav-more { border: 0; background: none; color: var(--ink-2); font: inherit; cursor: pointer; }
  .rail nav svg { width: 21px; height: 21px; }
  .nav-t { display: block; font-style: normal; font-size: 10.5px; line-height: 1; letter-spacing: .01em; }
  .rail nav .dot { top: 6px; right: calc(50% - 20px); }

  /* верх: только поиск и «+» */
  .top { position: sticky; top: 0; z-index: 40; margin: 0 -16px 14px; padding: 10px 16px; background: linear-gradient(rgba(10, 10, 10, .92), rgba(10, 10, 10, .6) 70%, transparent); }
  .ph h1 { font-size: 26px; }

  /* переключатели периода и фильтры — листаются пальцем, без обрезанных краёв */
  .seg, .tabs-row, [data-tabs] { max-width: calc(100% + 32px); margin-left: -16px; margin-right: -16px; padding-left: 16px; padding-right: 16px; border-radius: 0; background: none; border: 0; backdrop-filter: none; -webkit-backdrop-filter: none; overflow-x: auto; scroll-snap-type: x proximity; }
  .seg button { flex: none; scroll-snap-align: start; background: var(--glass); border: 1px solid var(--line); }
  .seg button.is-on { border-color: transparent; }
  .seg { gap: 6px; }

  /* заказы — карточками */
  .tbl--orders thead, .tbl--cust thead { display: none; }
  .tbl--orders, .tbl--orders tbody, .tbl--cust, .tbl--cust tbody { display: block; width: 100%; min-width: 0; }
  .tbl-wrap:has(.tbl--orders), .tbl-wrap:has(.tbl--cust) { margin: 0; padding: 0; overflow: visible; }
  .tbl--orders tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "id st" "who sum" "th sum"; gap: 8px 12px; padding: 14px 2px; border-bottom: 1px solid var(--line); }
  .tbl--orders tr:last-child { border-bottom: 0; }
  .tbl--orders td { display: block; padding: 0 !important; border: 0 !important; min-width: 0; }
  .tbl--orders .c-sel, .tbl--orders .c-del { display: none; }
  .tbl--orders .c-id { grid-area: id; }
  .tbl--orders .c-st { grid-area: st; justify-self: end; }
  .tbl--orders .c-who { grid-area: who; }
  .tbl--orders .c-th { grid-area: th; }
  .tbl--orders .c-sum { grid-area: sum; align-self: center; text-align: right; }
  .tbl--orders .c-sum b { font-size: 16px; }
  .tbl--orders .who b, .tbl--cust .who b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

  /* клиенты — карточками */
  .tbl--cust tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "who sum" "meta seg"; gap: 6px 12px; padding: 14px 2px; border-bottom: 1px solid var(--line); }
  .tbl--cust tr:last-child { border-bottom: 0; }
  .tbl--cust td { display: block; padding: 0 !important; border: 0 !important; min-width: 0; text-align: left; }
  .tbl--cust .c-who { grid-area: who; }
  .tbl--cust .c-sum { grid-area: sum; text-align: right; align-self: center; }
  .tbl--cust .c-city { grid-area: meta; font-size: 13px; padding-left: 50px !important; }
  .tbl--cust .c-seg { grid-area: seg; justify-self: end; }
  .tbl--cust .c-ord, .tbl--cust .c-aov, .tbl--cust .c-last { display: none; }

  /* остальные таблицы листаются вбок внутри карточки, а не тянут страницу */
  .tbl-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain; }

  /* заказ: товар на всю ширину, сумма под названием */
  .o-lines .list > li { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 4px 14px; align-items: start; }
  .o-lines .list > li > img { grid-row: span 2; }
  .o-sum { grid-column: 2; margin: 0; justify-content: space-between; }
  .o-sum b { min-width: 0; }
  .kv { grid-template-columns: 96px minmax(0, 1fr); }
  .kv dd { min-width: 0; overflow-wrap: anywhere; }
  .note-form { flex-direction: column; align-items: stretch; }
  .note-form .btn { width: 100%; }

  /* настройки: разделы — горизонтальными вкладками */
  .set-nav { flex-direction: row; overflow-x: auto; scrollbar-width: none; padding: 6px; margin-bottom: 14px; position: sticky; top: 64px; z-index: 30; }
  .set-nav::-webkit-scrollbar { display: none; }
  .set-nav button { flex: none; white-space: nowrap; padding: 10px 14px; min-height: 44px; }

  /* кнопки и поля — под палец */
  .btn { min-height: 44px; }
  .btn--sm { min-height: 38px; }
  .ph__r { display: flex; flex-wrap: wrap; gap: 8px; }
  .modal__box { max-height: 88dvh; overflow-y: auto; overscroll-behavior: contain; }
  .modal__f { position: sticky; bottom: calc(-22px - env(safe-area-inset-bottom)); margin: 18px -18px calc(-22px - env(safe-area-inset-bottom)); padding: 14px 18px calc(14px + env(safe-area-inset-bottom)); background: rgba(24, 18, 15, .96); }
  .modal__f .btn { flex: 1; }
}

/* ---------- поддержка ---------- */
.sup { display: grid; grid-template-columns: minmax(280px, 360px) minmax(0, 1fr); gap: 16px; height: calc(100vh - 210px); min-height: 520px; }
.sup__list, .sup__chat { padding: 0; display: flex; flex-direction: column; overflow: hidden; }
.sup__tools { display: grid; gap: 10px; padding: 14px; border-bottom: 1px solid var(--line); }
.seg--sm button { padding: 6px 10px; font-size: 12.5px; }
.seg--sm em { font-style: normal; color: var(--amber); }
.sup__items { overflow-y: auto; flex: 1; padding: 6px; }
.sup__item { display: flex; gap: 10px; padding: 10px; border-radius: 16px; transition: background .15s; }
.sup__item:hover { background: var(--glass-hi); }
.sup__item.is-on { background: rgba(255, 255, 255, .14); }
.sup__item.is-wait .av { box-shadow: 0 0 0 2px var(--amber); }
.sup__it { flex: 1; min-width: 0; display: grid; gap: 3px; }
.sup__row { display: flex; align-items: center; gap: 6px; min-width: 0; }
.sup__row b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.sup__last { flex: 1; min-width: 0; color: var(--ink-2); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sup__badge { font-style: normal; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--amber); color: var(--amber-ink); font-size: 11.5px; font-weight: 600; display: grid; place-items: center; }
.sup__row .pill { height: 22px; font-size: 11px; padding: 0 8px; }
.sup-waiting { background: rgba(255, 255, 255, .18); color: var(--amber); border-color: rgba(255, 255, 255, .35); }
.sup-operator { background: rgba(158, 197, 255, .14); color: var(--blue); }
.sup-bot { background: rgba(201, 167, 255, .12); color: var(--violet); }
.sup-closed { opacity: .7; }
.sup__head { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.sup__who { display: grid; min-width: 0; }
.sup__who b { font-weight: 500; font-size: 16px; }
.sup__who small { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.sup__who a { color: var(--amber); }
.sup__acts { display: flex; gap: 6px; flex-wrap: wrap; }
.sup__orders { padding: 10px 16px; border-bottom: 1px solid var(--line); font-size: 13px; }
.sup__orders summary { cursor: pointer; display: flex; align-items: center; gap: 6px; color: var(--ink-2); }
.sup__order { padding: 8px 0 0; }
.sup__order a { color: var(--amber); }
.sup__msgs { flex: 1; overflow-y: auto; padding: 18px 16px; display: flex; flex-direction: column; gap: 8px; }
.sup__msg { max-width: min(78%, 560px); padding: 10px 14px 6px; border-radius: 18px; background: var(--glass-2); border: 1px solid var(--line); align-self: flex-start; overflow-wrap: anywhere; line-height: 1.45; }
.sup__msg.is-out { align-self: flex-end; background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .25); border-bottom-right-radius: 6px; }
.sup__msg.is-in { border-bottom-left-radius: 6px; }
.sup__msg.from-bot { background: rgba(201, 167, 255, .1); border-color: rgba(201, 167, 255, .2); }
.sup__msg.is-del { opacity: .5; }
.sup__msg a { color: var(--amber); text-decoration: underline; }
.sup__by { display: block; font-size: 11px; color: var(--ink-3); margin-bottom: 2px; }
.sup__t { display: block; font-size: 11px; color: var(--ink-3); margin-top: 4px; text-align: right; }
.sup__img { max-width: 260px; max-height: 320px; border-radius: 12px; margin: 2px 0 6px; object-fit: cover; }
.sup__file { display: inline-block; margin-bottom: 4px; }
.sup__ev { align-self: center; font-size: 12px; color: var(--ink-3); padding: 2px 10px; }
.sup__compose { border-top: 1px solid var(--line); padding: 10px 12px 12px; display: grid; gap: 8px; }
.sup__meta { display: flex; align-items: center; gap: 8px; }
.sup__meta .select { width: auto; max-width: 220px; }
.sup__row2 { display: flex; gap: 8px; align-items: flex-end; }
.sup__row2 .textarea { min-height: 48px; max-height: 220px; resize: none; }
.sup__row2 .btn { flex: none; width: 48px; height: 48px; }
.sup__savebar { display: flex; align-items: center; gap: 10px; position: sticky; bottom: 12px; z-index: 5; margin-top: 16px; }
.faq-item { display: grid; gap: 10px; margin-bottom: 12px; }
@media (max-width: 760px) {
  .sup { grid-template-columns: minmax(0, 1fr); height: calc(100svh - 190px); min-height: 0; }
  .sup--open .sup__list { display: none; }
  .sup:not(.sup--open) .sup__chat { display: none; }
  .sup__head { padding: 10px 12px; gap: 8px; }
  .sup__acts { width: 100%; }
  .sup__acts .btn { flex: 1; }
  .sup__msg { max-width: 88%; }
  .sup__meta .select { max-width: 60%; }
}
@media (max-width: 760px) {
  #view:has(.sup--open) > .ph { display: none; }
  .sup { height: calc(100svh - 250px); }
  .sup--open { height: calc(100svh - 150px); }
  .sup__head .av--lg { width: 40px; height: 40px; font-size: 15px; }
  .sup__who { flex: 1; }
  .sup__head .sp { display: none; }
  .sup__acts .btn { height: 36px; }
  .sup__msgs { padding: 12px 10px; }
  .sup__meta small { font-size: 11px; }
}

/* I LOVE REDHEAD CONTROL: Olympia design system, 18.11.2026. */
:root { --bg:#0a0a0a; --ink:#f5f5f5; --ink-2:#a3a3a3; --ink-3:#a3a3a3; --glass:#141414; --glass-2:#141414; --glass-hi:#202020; --line:#2a2a2a; --line-2:#3d3d3d; --amber:#c9a06a; --amber-2:#e3c08f; --amber-ink:#0a0a0a; --green:#a8c9af; --red:#e6a29d; --blue:#b2c5d9; --violet:#bcb0d2; --r:14px; --r-s:8px; --blur:none; --shadow:none; color-scheme:dark; }
body { font-family:'Control Inter',Inter,Arial,sans-serif; background:#0a0a0a; color:#f5f5f5; font-size:14px; line-height:1.5; }
.bg { display:none; }
.shell { display:block; min-height:100svh; }
.main { padding:0; min-width:0; }
#view { max-width:1680px; margin:0 auto; padding:28px 20px 60px; }
.top { position:sticky; top:0; display:flex; justify-content:space-between; gap:16px; margin:0; min-height:72px; padding:14px 24px; background:#141414; border-bottom:1px solid var(--line); z-index:40; }
.control-top-left,.control-account { display:flex; align-items:center; gap:20px; }
.control-title { color:var(--ink-2); font-size:13px; letter-spacing:.04em; white-space:nowrap; }
.control-account a { text-align:right; font-size:13px; }
.control-account b { display:block; font-weight:600; }
.control-account small { display:block; color:var(--ink-2); font-size:12px; text-transform:uppercase; }
.control-account .btn { text-transform:uppercase; font-size:12px; }
.control-burger { display:grid; align-content:center; gap:5px; width:28px; height:36px; border:0; background:transparent; padding:4px; color:var(--ink); }
.control-burger span { height:1px; background:currentColor; width:24px; display:block; }
.rail { position:fixed; z-index:81; top:0; bottom:0; left:0; width:min(300px,85vw); height:100svh; display:flex; flex-direction:column; align-items:stretch; gap:20px; padding:20px 16px; border-right:1px solid var(--line); background:#141414; transform:translateX(-100%); transition:transform .2s ease; overflow-y:auto; visibility:hidden; }
.admin-menu-open .rail { transform:translateX(0); visibility:visible; }
.admin-scrim { position:fixed; inset:0; z-index:80; border:0; border-radius:0; background:rgba(0,0,0,.6); width:100%; height:100%; }
.control-brand { display:flex; justify-content:space-between; align-items:center; color:var(--ink-2); font-size:13px; letter-spacing:.04em; }
.rail nav { display:flex; flex-direction:column; align-items:stretch; gap:4px; border:0; background:none; padding:0; border-radius:0; }
.rail nav a { width:100%; min-height:44px; height:auto; padding:12px; display:flex; justify-content:flex-start; align-items:center; gap:12px; border-radius:8px; color:var(--ink-2); font-size:14px; }
.rail nav a svg { width:18px; height:18px; flex:none; }
.rail nav a.is-on { background:#fff; color:#111; box-shadow:none; }
.rail nav a:hover { background:#232323; color:#fff; text-decoration:none; }
.rail nav a.is-on:hover { background:#eee; color:#111; }
.rail a::after { display:none; }
.rail a .dot { position:static; margin-left:auto; background:var(--amber); color:#000; }
.control-site { display:flex; gap:12px; align-items:center; margin-top:auto; padding:12px; color:var(--ink-2); }
.control-site svg { width:18px; height:18px; }
.ph { margin:0 0 24px; gap:20px; }
.ph h1 { font-family:'Control Display','Arial Narrow',Arial,sans-serif; font-size:40px; font-weight:800; letter-spacing:.01em; line-height:1; text-transform:uppercase; }
.ph p { margin-top:12px; color:var(--ink-2); font-size:14px; line-height:1.6; }
.ph:has(.control-period) { display:block; }
.ph .ph__r:has(.control-period) { display:block; width:100%; margin-top:24px; }
.card,.glass,.mini,.kcol,.kcard,.color-ed,.banner-ed { background:#141414; border:1px solid var(--line); border-radius:14px; box-shadow:none; backdrop-filter:none; animation:none; }
.card { padding:20px; }
.card--warm { background:#141414; border-color:var(--line); }
.card--warm .kpi__t span,.card--warm .kpi small { color:var(--ink-2); }
.card--warm .delta--up { background:none; color:var(--ink-2); border:0; }
.card__h { margin:0 0 20px; }
.card__h h2,.card__h h3,.sec h3 { font-size:14px; font-weight:600; }
.card__h > a { font-size:12px; text-transform:uppercase; }
.btn,.input,.select,.textarea,.arrow,.search,.search kbd,.seg button,.status-pick button,.set-nav button,.tag { border-radius:8px; }
.btn { background:#141414; border:1px solid var(--line-2); color:var(--ink); box-shadow:none; font-weight:500; font-size:13px; }
.btn:hover { background:#202020; border-color:#666; }
.btn--light,.btn--amber { background:#fff; color:#111; border-color:#fff; box-shadow:none; }
.btn--light:hover,.btn--amber:hover { background:#e5e5e5; border-color:#e5e5e5; }
.btn--ghost { background:transparent; border-color:transparent; }
.btn--danger { color:var(--red); }
.btn.is-busy { color:transparent!important; }
.btn--light.is-busy::after,.btn--amber.is-busy::after { border-color:#111 transparent #111 transparent; }
.input,.select,.textarea,input[type=color],.matrix td input { background:#141414; border-color:var(--line-2); color:var(--ink); color-scheme:dark; }
.input:focus,.select:focus,.textarea:focus { background:#141414; border-color:#aaa; }
.input::placeholder,.textarea::placeholder { color:#777; opacity:1; }
.select option { background:#141414; color:#f5f5f5; }
.field > span,.field > small { color:var(--ink-2); }
.seg { background:transparent; border:1px solid var(--line-2); border-radius:0; padding:0; gap:0; }
.seg button { border:0; background:none; color:var(--ink); font-size:12px; font-weight:600; text-transform:uppercase; padding:10px 14px; height:auto; min-height:34px; }
.seg button.is-on { background:#fff; color:#111; box-shadow:none; }
.control-period { margin-bottom:20px; }
.control-period .seg { display:inline-flex; max-width:100%; }
.control-period-fields { display:flex; align-items:center; gap:10px; margin-top:14px; flex-wrap:wrap; }
.control-period-fields .input { width:130px; }
.control-period-fields .select { width:170px; }
.control-period-fields [type=date] { width:160px; }
.control-period-fields label { display:grid; gap:6px; color:var(--ink-2); font-size:12px; }
.control-period-fields .btn { flex:none; }
.control-period-fields:has(label) { align-items:end; }
.kpis { grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; margin-bottom:20px; }
.kpi { min-height:164px; justify-content:flex-start; }
.kpi__t span { color:var(--ink-2); font-size:14px; }
.kpi__v { margin-top:14px; display:flex; flex-direction:column; align-items:flex-start; gap:10px; }
.kpi__v b,.mini > b,.big-stat b { font-family:'Control Display','Arial Narrow',Arial,sans-serif; font-size:48px; font-weight:800; letter-spacing:0; line-height:1; }
.kpi small { margin-top:10px; font-size:12px; }
.delta { border:0; background:none; padding:0; height:auto; color:var(--ink-2); font-size:12px; font-weight:400; }
.delta--up,.delta--down { color:var(--ink-2); background:none; border:0; }
.control-chart { margin-bottom:20px; }
.control-task-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; }
.control-task { display:flex; justify-content:space-between; gap:16px; padding:16px; border:1px solid var(--line); border-radius:8px; }
.control-task > b { font-family:'Control Display',Arial,sans-serif; font-size:36px; line-height:1; font-weight:800; }
.control-task small { display:block; color:var(--ink-2); }
.control-tasks { margin-bottom:20px; }
.control-delivery { display:flex; flex-wrap:wrap; gap:10px; }
.control-delivery .btn { height:auto; min-height:36px; padding:10px 14px; text-transform:uppercase; font-size:11px; }
.mini { padding:20px; }
.mini > b { display:block; margin-top:16px; }
.mini small { display:block; margin-top:8px; color:var(--ink-2); }
.g { gap:16px; margin-bottom:20px; }
.tbl th { color:var(--ink-2); font-size:11px; font-weight:500; text-transform:uppercase; letter-spacing:.02em; }
.tbl td { padding-top:15px; padding-bottom:15px; }
.tbl-wrap { margin:0 -20px -20px; padding:0 20px 16px; }
.tbl tbody tr:hover td { background:#1c1c1c; }
.pill { border-radius:6px; }
.st-new,.st-awaiting_payment,.seg-vip { color:var(--amber-2); background:rgba(201,160,106,.08); border-color:rgba(201,160,106,.25); }
.st-delivered { color:var(--green); }
.av { background:#292929; border:1px solid var(--line-2); color:var(--ink); }
.grid { stroke:#2a2a2a; }
.chart .cursor { stroke:#777; }
.chart__tip { background:#fff; color:#111; border-radius:8px; box-shadow:none; }
.funnel__bar i { background:linear-gradient(90deg,rgba(201,160,106,.6),rgba(201,160,106,.15)); }
.hbars s,.stockbar i { background:var(--amber); }
.pcard { padding:14px; gap:14px; }
.pcard:hover { transform:none; }
.pcard__img { aspect-ratio:1; background:#fff; border-radius:8px; }
.pcard__img img { object-fit:contain; padding:12px; }
.thumb,.thumbs img,.stock-block > img,.imgs figure img { object-fit:contain; background:#fff; }
.pcard__s div { border-radius:8px; }
.control-product-wrap { display:flex; flex-direction:column; min-width:0; }
.control-product-wrap > .pcard { flex:1; }
.control-product-actions { display:flex; gap:6px; flex-wrap:wrap; padding:10px 0; }
.control-product-actions .btn { font-size:10px; padding:0 8px; }
.control-product-lifecycle { margin-bottom:20px; max-width:100%; overflow:auto; }
.control-order-filters { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin-bottom:16px; }
.control-fulfillment { margin-bottom:20px; }
.control-fulfillment summary { cursor:pointer; font-size:13px; }
.control-fulfillment[open] summary { margin-bottom:24px; }
.control-photo { display:flex; flex-direction:column; gap:14px; min-width:0; }
.control-photo > img { width:100%; height:220px; object-fit:contain; background:#0a0a0a; border:1px solid var(--line); border-radius:8px; }
.modal__box,.palette__box { background:#141414; border-color:var(--line-2); border-radius:14px; box-shadow:none; }
.modal,.palette { background:rgba(0,0,0,.7); }
.modal__h h2 { font-family:'Control Display',Arial,sans-serif; font-size:30px; text-transform:uppercase; }
.modal__f { background:#141414; }
.toast { background:#fff; color:#111; border-radius:8px; box-shadow:none; }
.toast--err { background:#e6a29d; }
.login__logo b { font-family:'Control Display',Arial,sans-serif; font-size:32px; font-weight:800; }
.login__logo .rail__logo { background:#fff; }
.set-nav { align-self:start; }
.set-nav button.is-on { background:#fff; color:#111; }
.set-nav button:hover { background:#232323; }
.banner-ed__img img { background:#fff; object-fit:contain; }
.sup__msg.is-out { background:#232323; border-color:var(--line-2); }
.sup__msg.from-bot { background:#1d1a16; border-color:var(--line-2); }
@media(max-width:1200px) { .kpis,.control-task-grid { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media(max-width:760px) {
 #view { padding:24px 16px 40px; }
 .top { margin:0; padding:12px 16px; min-height:72px; background:#141414; }
 .control-top-left,.control-account { gap:12px; }
 .control-title { font-size:11px; letter-spacing:.02em; }
 .control-account a { font-size:11px; }
 .control-account small { font-size:9px; }
 .control-account .btn { height:36px; min-height:36px; padding:0 10px; font-size:10px; }
 .ph h1 { font-size:36px; }
 .ph p { font-size:12px; }
 .rail { padding:20px 16px; width:min(300px,85vw); height:100svh; top:0; bottom:0; left:0; right:auto; justify-content:flex-start; flex-direction:column; }
 .rail nav { width:100%; max-width:none; flex-direction:column; padding:0; overflow:visible; gap:4px; }
 .rail nav > a { display:flex; flex:none; width:100%; height:auto; min-height:44px; border-radius:8px; gap:12px; padding:12px; }
 .rail nav a span { font-size:14px; }
 .rail nav .dot { position:static; font-size:10px; }
 .rail nav svg { width:18px; height:18px; }
 .control-period .seg { margin:0; padding:0; border:1px solid var(--line-2); border-radius:0; width:100%; max-width:100%; }
 .control-period .seg button { flex:1; font-size:10px; padding:10px 8px; background:transparent; border:0; border-radius:8px; }
 .control-period .seg button.is-on { background:#fff; color:#111; }
 .control-period-fields { gap:8px; }
 .control-period-fields .select { width:145px; }
 .control-period-fields .input { width:105px; }
 .control-period-fields [type=date] { width:145px; }
 .control-order-filters { grid-template-columns:repeat(2,minmax(0,1fr)); }
 .control-product-lifecycle { margin:0 0 20px; padding:0; max-width:100%; border:1px solid var(--line-2); }
 .control-product-lifecycle button { font-size:10px; padding:10px; }
 .card { padding:16px; }
 .kpi { min-height:150px; }
 .kpi__v b,.mini > b { font-size:42px; }
 .tbl-wrap { margin:0 -16px -16px; padding:0 16px 14px; }
 .bulk { bottom:16px; border-radius:12px; background:#141414; }
 .toasts { bottom:20px; }
 .modal__box { border-radius:14px 14px 0 0; }
 .modal__f { background:#141414; }
 .set-nav { background:#141414; padding:6px; }
 .g { gap:14px; }
}
@media(max-width:560px) { .kpis,.control-task-grid { grid-template-columns:minmax(0,1fr); } .control-account a { display:none; } .control-order-filters { grid-template-columns:1fr; } }
@media(min-width:1500px) { #view { padding:32px 40px 60px; } }
@media(prefers-reduced-motion:reduce) { .rail { transition:none; } }
@media print { .rail,.top,.admin-scrim { display:none!important; } body,.card { background:#fff; color:#000; } #view { padding:0; } }
@media(max-width:560px) {
 .control-period-fields .select { width:120px; flex:1; min-width:95px; }
 .control-period-fields .input { width:82px; }
 .control-period-fields .btn { min-width:36px; padding-left:10px; padding-right:10px; }
 .control-period-fields [type=date] { width:145px; }
}
.control-period-fields input[type=number] { appearance:textfield; -moz-appearance:textfield; }
.control-period-fields input[type=number]::-webkit-inner-spin-button { appearance:none; margin:0; }
/* Каталог: табличное управление в общей тёмной палитре I LOVE REDHEAD. */
body.tilda-products { --ink:#f5f5f5; --ink-2:#a3a3a3; --ink-3:#777; --line:#2a2a2a; --line-2:#3d3d3d; --bg:#0a0a0a; --surface:#141414; background:#0a0a0a; color:#f5f5f5; }
.tilda-products #view { max-width:none; padding:0 0 48px; }
.tilda-products .top,.tilda-products .rail { --ink:#fff; --ink-2:#aaa; --line:#333; color:#fff; background:#141414; }
.tilda-products .top .btn { color:#fff; background:transparent; border-color:#444; }
.tilda-products .control-burger { color:#fff; }
.tilda-products .tc-head { position:relative; display:flex; align-items:center; justify-content:space-between; gap:24px; padding:28px 40px; min-height:120px; border-bottom:1px solid #252525; background:#0a0a0a; }
.tc-head>div:first-child { display:flex; align-items:center; gap:16px; font-size:13px; letter-spacing:.04em; color:#888; }
.tc-head h1 { font:500 28px/1.25 'Control Inter',Arial,sans-serif; text-transform:none; color:#f5f5f5; margin:0; letter-spacing:0; }
.tc-head>div>span { color:#454545; font-size:24px; font-weight:300; }
.tc-head-actions { display:flex; gap:10px; align-items:center; }
.tc-round,.tc-add { border:0; display:inline-flex; justify-content:center; align-items:center; height:48px; border-radius:10px; padding:0 22px; font-size:14px; font-weight:500; }
.tc-round { width:48px; padding:0; border:1px solid #333; background:#171717; color:#b8b8b8; letter-spacing:3px; }
.tc-add { background:#f5f5f5; color:#111; }
.tc-add:hover { background:#ddd; text-decoration:none; color:#111; }
.tc-menu { position:absolute; right:40px; top:96px; background:#181818; z-index:12; padding:8px; box-shadow:0 12px 40px #0006; border:1px solid #333; border-radius:12px; width:240px; }
.tc-menu button,.tc-menu a { display:block; width:100%; text-align:left; padding:14px 12px; background:transparent; border:0; color:#f5f5f5; font-size:14px; }
.tc-menu button:hover,.tc-menu a:hover { background:#252525; text-decoration:none; }
.tc-content { padding:28px 40px 0; max-width:1800px; margin:auto; }
.tc-tools { display:flex; align-items:stretch; gap:12px; margin-bottom:20px; }
.tc-category { flex:1; min-width:0; display:flex; align-items:center; border:1px solid #303030; border-radius:6px; padding:0 18px; gap:12px; background:transparent; }
.tc-category>span { font-size:22px; }
.tc-category select { border:0; width:100%; min-width:0; background:transparent; padding:14px 0; font-size:14px; color:#e6e6e6; outline:none; }
.tc-tool,.tc-sort { background:#141414; color:#aaa; border:1px solid #303030; border-radius:6px; min-height:52px; }
.tc-tool { width:52px; display:grid; place-items:center; }
.tc-tool svg { width:21px; height:21px; }
.tc-sort { padding:0 12px; width:152px; font-size:13px; }
.tc-search { margin-bottom:16px; }
.tc-search input { width:100%; border:1px solid #333; padding:14px 16px; background:#141414; color:#f5f5f5; border-radius:4px; font-size:15px; }
.tc-tabs { display:flex; align-items:center; gap:22px; flex-wrap:wrap; margin:4px 0 18px; }
.tc-tabs button { background:none; border:0; border-bottom:1px solid transparent; color:#999; padding:6px 0; font-size:13px; }
.tc-tabs button.is-on { color:#f5f5f5; border-color:#c9a06a; }
.tc-tabs>span { margin-left:auto; font-size:12px; color:#999; }
.tc-table-wrap { overflow:auto; }
.tc-table { width:100%; border-collapse:collapse; min-width:970px; font-size:14px; font-variant-numeric:tabular-nums; }
.tc-table th { font-weight:500; color:#999; font-size:11px; letter-spacing:.05em; text-align:left; padding:18px 12px; white-space:nowrap; border-bottom:1px solid #292929; }
.tc-table th:first-child,.tc-table td:first-child { width:24px; padding-left:0; padding-right:0; }
.tc-table th:nth-child(2) { width:40px; }
.tc-table th:nth-child(3) { width:82px; }
.tc-table th:nth-child(4) { width:38%; }
.tc-table td { padding:16px 12px; border-bottom:1px solid #292929; vertical-align:middle; }
.tc-table tr.tc-product:hover { background:#1b1b1b; }
.tc-table tr.is-selected { background:#22201c; }
.tc-table tr.is-drop { outline:2px solid #c9a06a; outline-offset:-2px; }
.tc-table input[type=checkbox] { width:18px; height:18px; border-radius:0; accent-color:#e9e9e9; cursor:pointer; }
.tc-drag { color:#666; background:none; border:0; font-size:26px; padding:0; cursor:grab; }
.tc-drag:active { cursor:grabbing; }
.tc-drag[draggable=false] { cursor:default; opacity:.4; }
.tc-photo { display:grid; place-items:center; width:64px; height:64px; border:1px solid #303030; border-radius:12px; background:#fff; overflow:hidden; }
.tc-photo img { width:84%; height:84%; object-fit:contain; }
.tc-title>a { color:#eee; display:block; font-weight:500; line-height:1.4; }
.tc-title>button { background:none; border:0; border-bottom:1px dashed #555; padding:0; color:#999; font-size:12px; line-height:1.6; margin-top:4px; display:block; }
.tc-title>small { display:inline-block; font-size:10px; color:#b7a183; margin-top:6px; padding:2px 6px; border:1px solid #39332b; border-radius:4px; }
.tc-inline { width:105px; min-width:0; border:1px solid transparent; background:transparent; color:#f5f5f5; font:inherit; border-radius:0; padding:9px 5px; }
.tc-sku { width:120px; font-size:13px; }
.tc-inline:hover:not(:disabled),.tc-inline:focus { border-color:#555; background:#202020; outline:0; box-shadow:0 0 0 2px #c9a06a20; }
.tc-inline:disabled { color:#999; }
.tc-price { width:88px; appearance:textfield; -moz-appearance:textfield; }
.tc-price::-webkit-inner-spin-button { appearance:none; }
.tc-icon { padding:5px; background:none; border:0; color:#aaa; display:inline-grid; place-items:center; }
.tc-icon:hover { color:#fff; }
.tc-icon svg { width:21px; height:21px; }
.tc-switch { width:46px; height:26px; border:1px solid #414141; border-radius:25px; background:#252525; padding:2px; box-shadow:0 1px 4px #0001; display:flex; align-items:center; }
.tc-switch i { display:block; height:20px; width:20px; border-radius:50%; background:#888; box-shadow:none; transition:transform .15s; }
.tc-switch[aria-checked=true] { background:#eee; border-color:#eee; }
.tc-switch[aria-checked=true] i { transform:translateX(18px); background:#111; }
.tc-switch:disabled { opacity:.5; cursor:default; }
.tc-restore { background:none; border:0; font-size:12px; color:#c9a06a; text-decoration:underline; }
.tc-variant { background:#101010; font-size:13px; }
.tc-variant td { padding-top:8px; padding-bottom:8px; border-bottom-color:#242424; }
.tc-variant img { width:40px; height:40px; object-fit:contain; background:#fff; }
.tc-variant small { display:block; color:#999; margin-top:3px; }
.tc-variant-code { color:#999; font-size:11px; overflow-wrap:anywhere; }
.tc-variant a { color:#aaa; font-size:12px; }
.tc-quantity { width:70px; }
.tc-empty { text-align:center; color:#999; padding:60px!important; }
.tc-bulk { display:flex; flex-wrap:wrap; align-items:center; gap:12px; padding:14px; background:#1c1c1c; margin-bottom:18px; font-size:13px; }
.tc-bulk select,.tc-bulk button { border:1px solid #3d3d3d; padding:10px; color:#eee; background:#242424; border-radius:3px; }
.tc-footnote { font-size:12px; color:#999; margin-top:22px; line-height:1.6; }
.tilda-products [hidden] { display:none!important; }
.tilda-products #view:has(.editor) { padding:28px 32px 60px; }
.tilda-products .ph h1 { font-family:'Control Inter',Arial,sans-serif; font-size:26px; font-weight:500; text-transform:none; letter-spacing:0; line-height:1.3; }
.tilda-products .card,.tilda-products .color-ed,.tilda-products .modal { background:#141414; border-color:#303030; border-radius:12px; }
.tilda-products .modal__h,.tilda-products .modal__f { background:#141414; border-color:#303030; }
.tilda-products .input,.tilda-products .select,.tilda-products .textarea { background:#171717; color:#f5f5f5; border-color:#3d3d3d; }
.tilda-products .btn { background:#171717; color:#f5f5f5; border-color:#3d3d3d; }
.tilda-products .btn--amber,.tilda-products .btn--light { background:#f5f5f5; color:#111; border-color:#f5f5f5; }
.tilda-products .field>span,.tilda-products h2,.tilda-products h3 { color:#f5f5f5; }
.tilda-products .modal h2 { font-family:'Control Inter',Arial,sans-serif; text-transform:none; font-size:22px; }
.tilda-products .color-ed__head,.tilda-products .size-row,.tilda-products .margin-box,.tilda-products .photos { background:#181818; }
@media(max-width:700px) {
 .tilda-products .tc-head { padding:22px 16px; min-height:100px; gap:10px; }
 .tc-head>div:first-child { font-size:16px; gap:10px; }
 .tc-head h1 { font-size:16px; }
 .tc-round,.tc-add { height:44px; font-size:14px; padding:0 18px; }
 .tc-round { width:44px; padding:0; }
 .tc-head-actions { gap:6px; }
 .tc-content { padding:22px 16px 0; }
 .tc-tools { gap:8px; }
 .tc-category { padding:0 10px; gap:6px; }
 .tc-category select { font-size:13px; padding:14px 0; }
 .tc-tool { width:44px; min-width:44px; min-height:48px; }
 .tc-sort { width:98px; min-height:48px; padding:0 5px; font-size:11px; }
 .tc-tabs { gap:14px; }
 .tc-tabs button { font-size:12px; }
 .tc-tabs>span { width:100%; margin:0; }
 .tc-table-wrap { margin:0 -16px; padding:0 16px; }
 .tc-menu { right:16px; top:82px; }
 .tilda-products #view:has(.editor) { padding:20px 16px 48px; }
}
body.tilda-products { color-scheme:dark; }
.tilda-products .top,.tilda-products .rail { color-scheme:dark; }
.tc-table input[type=checkbox] { appearance:auto; -webkit-appearance:checkbox; background:transparent; border:1px solid #555; }
.tilda-products .check input { background:#363636; }
.tilda-products .check input::after { background:#fff; box-shadow:0 1px 3px #0002; }
.tilda-products .check input:checked { background:#c9a06a; }
.tilda-products .check input:focus-visible,.tc-switch:focus-visible,.tc-drag:focus-visible { outline:2px solid #c9a06a; outline-offset:3px; }

.tc-category { background:#141414; }
.tc-category:focus-within,.tc-sort:focus-visible,.tc-tool:focus-visible,.tc-search input:focus { border-color:#777; outline:2px solid #c9a06a30; outline-offset:2px; }
.tc-tabs button { transition:color .15s,border-color .15s; }
.tc-tabs button:hover { color:#eee; }
.tc-table-wrap { border-top:1px solid #292929; scrollbar-width:thin; scrollbar-color:#444 #141414; }
.tc-table thead { background:#101010; }
.tc-table tr.tc-product { transition:background .15s; }
.tc-table tr.is-selected { box-shadow:inset 2px 0 #c9a06a; }
.tc-inline::placeholder { color:#666; }
.tc-icon { border-radius:6px; padding:8px; }
.tc-icon:hover { background:#2a2a2a; }
.tc-icon[data-trash]:hover { color:#edaaaa; background:#3a2222; }
.tc-round:hover { background:#252525; color:#fff; }
.tc-bulk { border:1px solid #393939; border-radius:10px; }
.tc-footnote { color:#777; }
.tilda-products .btn--danger { color:#e6aaaa; border-color:#633b3b; }
.tilda-products .ph h1 { font-weight:500; letter-spacing:-.02em; }
@media(max-width:700px) {
 .tc-head>div:first-child { font-size:11px; gap:8px; }
 .tc-head h1 { font-size:21px; }
 .tc-head>div>span { font-size:20px; }
 .tc-round,.tc-add { height:42px; border-radius:9px; }
 .tc-table td { padding-top:14px; padding-bottom:14px; }
}
@media(prefers-reduced-motion:reduce) { .tc-tabs button,.tc-table tr.tc-product,.tc-switch i { transition:none; } }

/* Contained tables and quiet, consistent controls across admin screens. */
.tbl-wrap,.matrix-wrap,.tc-table-wrap { max-width:100%; min-width:0; overscroll-behavior-x:contain; scrollbar-width:thin; scrollbar-color:#777 #222; }
.tbl-wrap { margin:0; padding:0 0 12px; }
.tbl-wrap:focus-visible { outline:2px solid #aaa; outline-offset:3px; }
.table-pan { display:flex; align-items:center; gap:16px; margin:0 0 16px; color:var(--ink-2); font-size:11px; }
.table-pan[hidden] { display:none; }
.table-pan span { flex:none; }
.table-pan input { flex:1; min-width:0; height:24px; margin:0; accent-color:#aaa; cursor:ew-resize; }
.table-pan input:focus-visible { outline:2px solid #aaa; outline-offset:3px; }
.seg { max-width:100%; margin-left:0; margin-right:0; gap:4px; padding:4px; border-radius:10px; scrollbar-width:thin; scrollbar-color:#777 #222; }
.seg button { flex:0 0 auto; white-space:nowrap; border-radius:6px; min-height:36px; }
.stock-block > div { min-width:0; }
.stock-title { display:flex; align-items:center; flex-wrap:wrap; gap:8px; }
.stock-title > a { margin-right:4px; overflow-wrap:anywhere; }
.stock-block .matrix-wrap { padding-bottom:8px; }
.matrix { border-spacing:8px; margin-left:-8px; }
.matrix th { padding:4px 8px; white-space:nowrap; }
.matrix td input { width:76px; min-height:44px; padding:8px; text-align:center; font-variant-numeric:tabular-nums; appearance:textfield; -moz-appearance:textfield; }
.matrix td input::-webkit-inner-spin-button,.matrix td input::-webkit-outer-spin-button { appearance:none; margin:0; }
.stock-block { padding:24px 0; }
.control-delivery { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; }
.control-delivery .btn { display:flex; justify-content:space-between; align-items:center; padding:16px; min-height:56px; text-transform:none; font-size:13px; white-space:normal; text-align:left; }
.control-delivery b { font-size:20px; font-variant-numeric:tabular-nums; }
.list > li > .sp { min-width:0; overflow-wrap:anywhere; }
.card__h { flex-wrap:wrap; gap:10px; }
.bulk { max-width:calc(100vw - 32px); flex-wrap:wrap; }
@media (max-width:900px){
 .control-delivery { grid-template-columns:repeat(2,minmax(0,1fr)); }
}
@media (max-width:600px){
 .kpis { grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
 .kpi { padding:14px; min-height:142px; }
 .kpi__t span { font-size:12px; }
 .kpi__v b { font-size:28px; overflow-wrap:anywhere; }
 .kpi small { font-size:11px; }
 .seg,.tabs-row,[data-tabs] { max-width:100%; margin-left:0; margin-right:0; }
 .stock-title { align-items:flex-start; font-size:14px; }
 .stock-title > a { flex-basis:100%; }
 .stock-block .matrix-wrap { margin:0; }
 .matrix { font-size:12px; }
 .matrix td input { width:64px; }
 .table-pan { gap:10px; }
 .control-delivery .btn { padding:12px; font-size:12px; }
 .bulk { left:16px; right:16px; bottom:16px; transform:none; justify-content:center; padding:12px; border-radius:14px; }
 .ph__r { gap:8px; }
}
@media (prefers-reduced-motion:reduce){
 *,*::before,*::after { scroll-behavior:auto!important; animation:none!important; transition:none!important; }
}
body.admin-menu-open,body:has(.modal) { overflow-y:hidden; }
.modal__box { overscroll-behavior:contain; }
.input:focus-visible,.select:focus-visible,.matrix td input:focus-visible { outline:2px solid #aaa; outline-offset:2px; }
@media (max-width:600px){
 .o-lines .list li { flex-wrap:wrap; }
 .o-lines .o-sum { width:100%; justify-content:flex-end; padding-left:50px; }
 .status-pick { flex-wrap:wrap; }
}
.stock-savebar { position:fixed; z-index:65; bottom:20px; left:50%; transform:translateX(-50%); width:max-content; max-width:calc(100% - 32px); display:flex; align-items:center; gap:20px; padding:12px 16px; background:#202020; border:1px solid #555; border-radius:12px; box-shadow:0 6px 24px #0006; }
.stock-savebar[hidden] { display:none; }
#view:has(.stock-savebar:not([hidden])) { padding-bottom:110px; }
@media (max-width:600px){
 .tbl--orders tr:has(.c-sel) { grid-template-columns:24px minmax(0,1fr) auto; grid-template-areas:"sel id st" ". who sum" ". th sum"; }
 .tbl--orders .c-sel { display:block; grid-area:sel; padding-top:2px!important; }
 .tbl--orders .c-id b { overflow-wrap:anywhere; }
 .stock-savebar { gap:10px; font-size:12px; bottom:calc(12px + env(safe-area-inset-bottom)); }
 .stock-savebar span { max-width:150px; }
 .stock-savebar .btn { flex:none; }
}
@media (max-width:600px){
 .tbl--orders tr:has(.c-sel) { grid-template-areas:"sel id st" ". who who" ". th sum"; }
 .tbl--orders .c-who .who { width:100%; }
 .tbl--orders .c-who .who > div { flex:1; }
 .tbl--orders .c-who .who b,.tbl--orders .c-who .who small { max-width:100%; }
}
.modal,.modal__box,.palette__box { animation:none; }
.settings-layout { grid-template-columns:220px minmax(0,1fr); align-items:start; }
.set-nav { position:sticky; top:92px; }
.set-nav button { min-width:0; }
.set-nav svg { flex:none; }
@media (max-width:900px){
 .settings-layout { grid-template-columns:minmax(0,1fr); }
 .set-nav { position:static; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); width:100%; overflow:visible; gap:4px; padding:8px; margin:0; }
 .set-nav button { width:100%; white-space:normal; min-height:44px; padding:10px; }
}
.control-period-fields { min-height:68px; align-items:end; }
.tbl--simple { min-width:0; table-layout:fixed; }
.tbl--simple td,.tbl--simple th { overflow-wrap:anywhere; }
.tbl--simple th:last-child,.tbl--simple td:last-child { width:110px; text-align:right; }
@media (max-width:600px){
 .tbl--simple th:last-child,.tbl--simple td:last-child { width:90px; }
}
.chart__value { font-family:inherit; font-size:22px; font-weight:500; }
.customer-kpis { grid-template-columns:repeat(3,minmax(0,1fr)); }
@media (max-width:600px){ .customer-kpis { grid-template-columns:repeat(2,minmax(0,1fr)); } }
.chart__values { position:absolute; top:0; left:0; right:0; display:flex; flex-wrap:wrap; gap:8px 18px; }
.chart__values .chart__value { font-size:14px; color:var(--ink); }
.customer-filters { display:grid; grid-template-columns:minmax(0,1fr) 190px; }
.customer-filters [data-q] { grid-column:1; grid-row:1; max-width:none!important; }
.customer-filters [data-sort] { grid-column:2; grid-row:1; width:100%!important; }
@media (max-width:600px){
 .customer-kpis > .card:last-child { grid-column:1/-1; }
 .customer-filters { grid-template-columns:minmax(0,1fr); }
 .customer-filters [data-sort] { grid-column:1; grid-row:2; }
}

/* Primary daily work first; secondary tools remain reachable. */
.nav-primary,.nav-secondary { display:grid; gap:4px; }
.nav-secondary { margin-top:12px; padding-top:12px; border-top:1px solid var(--line); }
.nav-extra { margin-top:8px; border-top:1px solid var(--line); padding-top:8px; }
.nav-extra > summary { cursor:pointer; padding:12px; min-height:44px; color:var(--ink-2); font-size:13px; }
.nav-extra[open] > summary { color:var(--ink); }
.report-details { border:1px solid var(--line); border-radius:14px; padding:6px 20px; margin:0 0 16px; background:#141414; }
.report-details > summary,.report-subdetails > summary { cursor:pointer; min-height:48px; padding:14px 0; font-size:14px; font-weight:500; }
.report-details__body { padding:12px 0 16px; min-width:0; }
.report-details__body > :last-child { margin-bottom:0; }
.report-subdetails { border-top:1px solid var(--line); }
.report-subdetails > summary { color:var(--ink-2); }
.stock-details { margin-top:20px; }
.stock-summary { margin:0 0 20px; }
.kpi small:empty { display:none; }
@media (max-width:600px){
 .report-details { padding-left:16px; padding-right:16px; }
 .control-kpis .kpi { min-height:124px; }
}
.kanban { grid-auto-columns:minmax(260px,1fr); align-items:start; scrollbar-width:thin; scrollbar-color:#777 #222; overscroll-behavior-x:contain; }
.kcol { display:block; min-width:0; height:min(72vh,760px); min-height:360px; overflow-y:auto; overscroll-behavior-y:contain; scrollbar-width:thin; scrollbar-color:#777 #222; }
.kcol__h { position:sticky; top:-14px; z-index:2; background:#141414; padding:10px 0 16px; gap:8px; border-bottom:1px solid var(--line); margin-bottom:12px; flex-wrap:wrap; }
.kcol__h h2 { font-size:14px; font-weight:500; margin:0; }
.kcol__h h2 span { color:var(--ink-2); margin-left:6px; }
.kcol__h small { font-size:12px; white-space:nowrap; }
.kcard { margin-bottom:10px; }
.kcard__t { align-items:center; }
.kcard__t .box { flex:none; }
.kcard__t > b { margin-right:auto; }
.kcard__t .muted { white-space:nowrap; font-size:11px; }
.kcard .who b { max-width:100%; white-space:normal; overflow-wrap:anywhere; }
@media (max-width:600px){ .kanban { grid-auto-columns: minmax(280px,85vw); } }
.order-print-help { margin:0 0 16px; color:var(--ink-2); font-size:12px; }
.order-print-help > summary { cursor:pointer; padding:4px 0; }
.order-browse-controls:has([data-tabs][hidden]) { display:grid; grid-template-columns:minmax(0,1fr) 150px; gap:12px; }
.order-browse-controls:has([data-tabs][hidden]) > div[style] { display:none; }
.order-browse-controls:has([data-tabs][hidden]) [data-q] { grid-column:1; grid-row:1; max-width:none!important; }
.order-browse-controls:has([data-tabs][hidden]) [data-range] { grid-column:2; grid-row:1; width:100%!important; }
@media (max-width:600px){
 .control-order-filters { grid-template-columns:repeat(2,minmax(0,1fr)); }
 .control-order-filters .input { min-width:0; width:100%; padding:10px; font-size:13px; }
 .order-browse-controls:has([data-tabs][hidden]) { grid-template-columns:minmax(0,1fr) 140px; }
}

/* Reports adapt to their card width, including narrow desktop columns. */
.report-details__body .card { container-type:inline-size; }
@container (max-width:440px) {
 .donut-wrap { grid-template-columns:minmax(0,1fr); justify-items:center; gap:16px; }
 .donut-wrap .legend { width:100%; }
}
.legend li { grid-template-columns:10px minmax(0,1fr) auto 42px; }
.legend span,.hbars div span { white-space:normal; overflow-wrap:anywhere; }
.legend b,.hbars b { flex-shrink:0; white-space:nowrap; }
.kpi__v b.is-unavailable { font-family:inherit; font-size:20px; font-weight:500; line-height:1.3; }
.who b,.who small,.tbl--orders .who b,.tbl--cust .who b { white-space:normal; overflow:visible; overflow-wrap:anywhere; }
.tbl-wrap[data-scrollable],.matrix-wrap[data-scrollable],.tc-table-wrap[data-scrollable] { overflow-x:auto; }
.chart__tip { max-width:min(360px,calc(100vw - 48px)); white-space:normal; overflow-wrap:anywhere; }

html,body{background:#000;min-height:100%}body{min-height:100dvh;display:flow-root}.login{min-height:100svh}.login__logo img{object-fit:contain}

.boot img,.rail__logo img{filter:none!important}

/* BOX creation uses its own stock and a reviewable draft. */
.box-builder__items{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.box-builder__slot{min-width:0;border:1px solid var(--line,#2a2a2a);border-radius:12px;padding:14px}
.box-builder__results{max-height:260px;overflow:auto;margin-top:12px}
.box-builder__results button,.box-builder__chosen{display:flex;align-items:center;gap:12px;width:100%;padding:10px 0;text-align:left;background:none;border:0;border-bottom:1px solid var(--line,#2a2a2a);color:inherit}
.box-builder__results button:hover{background:#1b1b1b}
.box-builder__results img,.box-builder__chosen img{width:44px;height:56px;object-fit:contain;flex-shrink:0;background:#fff;border-radius:4px}
.box-builder__results button>span:first-of-type,.box-builder__chosen>div{flex:1;min-width:0;overflow-wrap:anywhere}
.box-builder__results small,.box-builder__chosen small{display:block;color:var(--ink-2);margin-top:5px}
.box-builder__results button>span:last-child{font-size:12px;color:var(--ink-2)}
@media(max-width:600px){.box-builder__items{grid-template-columns:1fr}.tc-head-actions{flex-wrap:wrap}.box-builder .form-grid{grid-template-columns:1fr}}

/* Intrinsic tooltip width must not shrink beside the right chart edge. */
.chart__tip{width:max-content;max-width:min(360px,calc(100vw - 32px));white-space:normal;overflow-wrap:normal;word-break:normal;line-height:1.45}
/* ARGENT adapter to the approved Control foundations. */
:root{--bg:#0a0a0a;--ink:#f5f5f5;--ink-2:#a3a3a3;--ink-3:#a3a3a3;--glass:#141414;--glass-2:#141414;--line:#2a2a2a;--line-2:#3d3d3d;--r:14px;--r-s:8px;--blur:none;--shadow:none;--amber:#f5f5f5;--amber-ink:#111;--ease:ease}
body{font:400 14px/1.5 'Control Inter',Arial,sans-serif;overflow-x:visible}.bg{display:none}.main{max-width:1760px;margin:auto;padding-bottom:60px;min-width:0}.shell,.top,.ph,.card,.g,.kpis,.main,#view{min-width:0}.top{min-height:72px;background:#141414;backdrop-filter:none}.card{background:#141414;border:1px solid #2a2a2a;box-shadow:none;border-radius:14px}.sec{padding:20px;margin-top:20px}.card--warm{background:#141414}.ph h1{font:600 40px/1.1 'Control Display','Control Inter',Arial,sans-serif;letter-spacing:-.02em}.kpi__v b{font:600 48px/1.15 'Control Display','Control Inter',Arial,sans-serif;overflow-wrap:anywhere}.kpi__v{min-height:60px}.input,.select,textarea,.matrix input{background:#141414;color:#f5f5f5;border:1px solid #3d3d3d;border-radius:8px;min-height:44px}.btn{min-height:44px;border-radius:8px}.btn--amber,.btn--light{background:#f5f5f5;color:#111;box-shadow:none}.btn:hover{filter:none;background:#202020;color:#f5f5f5}.arrow{display:none!important}.thumbs img,.stock-block>img,.product-card img{background:#fff;object-fit:contain}.table-wrap,.matrix-wrap,.kanban{max-width:100%;overflow-x:auto}.table{min-width:720px}.av{background:#202020!important;color:#f5f5f5!important}.kpis{gap:16px;grid-template-columns:repeat(4,minmax(0,1fr))}.control-user{font-size:12px;color:#a3a3a3}.login__box{width:min(440px,calc(100vw - 32px));padding:28px}.login h1{font:600 30px 'Control Display','Control Inter',Arial,sans-serif}.boot img{animation:none}.kpi__v b:has(+.unused){font-size:20px}svg .bar{fill:#c9a06a}button,input,textarea,select{font-family:inherit}.empty{font-size:20px}.main *{max-inline-size:100%}td,th{overflow-wrap:anywhere}.crumbs b i{display:none}.kpi,.card{backdrop-filter:none}.kpi small{color:#a3a3a3}
@media(max-width:900px){.kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.ph h1{font-size:28px}.kpi__v b{font-size:28px}.control-user{max-width:120px}.top .search{display:none}.sec{padding:16px}.top{gap:8px}.top__r{flex-wrap:wrap}.main{padding-bottom:100px}}
@media(prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important}}
.control-nav-open .rail{visibility:visible!important;transform:none!important;z-index:1000;background:#141414}.rail{overflow-y:auto}.rail a{min-height:44px}.rail nav{display:grid}.rail .nav-t{display:block!important;opacity:1!important;visibility:visible!important}.rail .rail__logo{display:none}.rail{padding-top:90px}.top{z-index:1001}.kpi__v b.no-data{font:400 20px/1.5 'Control Inter',Arial,sans-serif!important}.tbl-wrap{max-width:100%;overflow:auto}.kpi__v b{animation:none!important}.card,.top{background-image:none!important}.chrome-text{background:none!important;color:#f5f5f5!important;-webkit-text-fill-color:#f5f5f5!important}svg{max-width:100%}
@media(max-width:719px){.top{display:grid!important;grid-template-columns:44px minmax(0,1fr) auto;gap:8px;padding:12px 16px}.top .crumbs{display:flex!important;min-width:0}.top .crumbs b{display:block!important;max-width:105px;border:0;padding:0}.top .crumbs b em{display:block!important;font:600 10px/1.5 'Control Inter',Arial,sans-serif;letter-spacing:.08em}.top [data-crumbs]{display:none!important}.top__r{display:flex;flex-wrap:nowrap;gap:6px;min-width:0}.control-user{display:block!important;font-size:9px;max-width:58px}.top__r .btn{font-size:11px;padding:8px;min-width:44px}.top__r .btn--icon,.top__r .hide-sm{display:none!important}.rail{width:min(300px,85vw)}}
body{background:#0a0a0a!important;color:#f5f5f5!important}.main{max-width:1760px}#view{max-width:1680px;margin-inline:auto}.top__r{min-width:0}
