/* gcreport dashboard v3 — dizayn tizimi.
   Mavzular: oq (standart yorug'), iliq (qum/sepiya, ko'k nuri kam), tungi (ko'k-kulrang qorong'i),
   neon (chuqur sovuq fon + nozik cyan/magenta chegara, faol elementda porlash), aura (klub brendi, to'q sariq).
   "Avtomatik" — JS <html data-theme> ni telefon sozlamasiga qarab oq/tungi qiladi.
   Har mavzuda: fon/matn/chiziq + 6 bo'lim aksenti + 3 rol rangi — WCAG AA tekshirilgan
   (matn ≥4.5:1, belgi/chiziq ≥3:1). Grafik seriyasi --series-1 — dataviz palitrasidan
   (#2a78d6 / #256abf / #3987e5), har mavzu yuzasiga validate_palette.js bilan tekshirilgan.
   Status ranglari (good/warn/crit) dataviz'dagi qat'iy qiymatlar — faqat holat uchun, belgi + so'z bilan. */

/* ===== MAVZULAR (tokens) ===== */
:root, [data-theme="oq"] {
  color-scheme: light;
  --page: #f3f3ef; --surface: #fcfcfb; --surface-2: #f0efea; --surface-3: #e8e7e1;
  --ink: #141413; --ink-2: #4f4e4a; --muted: #6c6a64;
  --grid: #e3e2db; --axis: #c3c2b7; --ring: rgba(20,20,19,.09); --ring-2: rgba(20,20,19,.2);
  --series-1: #2a78d6; --series-1-hover: #1c5cab; --track: #cde2fb;
  --good: #0ca30c; --good-ink: #006300; --good-bg: #e9f5e9;
  --crit: #d03b3b; --crit-ink: #b42f2f; --crit-bg: #fcefef; --warn: #fab219; --warn-bg: #fff5da;
  --link: #1c5cab; --shadow: 0 12px 32px rgba(30,30,20,.14); --backdrop: rgba(20,20,19,.42);
  --crit-on: #ffffff;
  --stats: #2a78d6; --stats-ink: #1c5cab; --stats-bg: #e7f0fb; --stats-solid: #256abf; --stats-on: #ffffff;
  --kassa: #0e9f6e; --kassa-ink: #047857; --kassa-bg: #e2f4ec; --kassa-solid: #047857; --kassa-on: #ffffff;
  --rasxod: #e8590c; --rasxod-ink: #b0450a; --rasxod-bg: #fcebdf; --rasxod-solid: #c2410c; --rasxod-on: #ffffff;
  --qarz: #7c4ddb; --qarz-ink: #6334c4; --qarz-bg: #efe9fb; --qarz-solid: #6d3fd0; --qarz-on: #ffffff;
  --pos: #0891a8; --pos-ink: #0b6f82; --pos-bg: #e0f2f5; --pos-solid: #0b7285; --pos-on: #ffffff;
  --ega: #a97900; --ega-ink: #835c00; --ega-bg: #faf0d2; --ega-solid: #e0a400; --ega-on: #1b1500;
  --zal: #c2255c; --zal-ink: #a61e4d; --zal-bg: #fdeaf0; --zal-solid: #b02150; --zal-on: #ffffff;
  --manager: #5b57d9; --manager-ink: #4541b8; --manager-bg: #ecebfb; --manager-solid: #4f4bc9; --manager-on: #ffffff;
  --admin: #0e9f6e; --admin-ink: #047857; --admin-bg: #e2f4ec; --admin-solid: #047857; --admin-on: #ffffff;
  --brand: #fd3501; --brand-ink: #c42800; --brand-solid: #e02e00; --brand-press: #c42800; --brand-on: #ffffff;
}
[data-theme="iliq"] {
  color-scheme: light;
  --page: #e9e0cc; --surface: #f6efdf; --surface-2: #eee4cf; --surface-3: #e5d9c0;
  --ink: #2a2117; --ink-2: #56483a; --muted: #6d5d4b;
  --grid: #e0d4bb; --axis: #c4b294; --ring: rgba(70,45,10,.12); --ring-2: rgba(70,45,10,.26);
  --series-1: #256abf; --series-1-hover: #1c5cab; --track: #b7d3f6;
  --good: #0ca30c; --good-ink: #1f5f1f; --good-bg: #e4ecd4;
  --crit: #d03b3b; --crit-ink: #a3302a; --crit-bg: #f6e2d8; --warn: #fab219; --warn-bg: #f6e7c2;
  --link: #8a4b12; --shadow: 0 12px 32px rgba(70,45,10,.18); --backdrop: rgba(40,28,12,.45);
  --crit-on: #ffffff;
  --stats: #3a6fb0; --stats-ink: #2c568c; --stats-bg: #e3e5e3; --stats-solid: #2f5f9c; --stats-on: #ffffff;
  --kassa: #3f8a4f; --kassa-ink: #2a6638; --kassa-bg: #e2e8d2; --kassa-solid: #2f6e3d; --kassa-on: #ffffff;
  --rasxod: #c05a1c; --rasxod-ink: #9a4512; --rasxod-bg: #f3dcc4; --rasxod-solid: #a84c14; --rasxod-on: #ffffff;
  --qarz: #8656b0; --qarz-ink: #6a3f92; --qarz-bg: #ebdfe3; --qarz-solid: #6e4399; --qarz-on: #ffffff;
  --pos: #2b7f86; --pos-ink: #1f6168; --pos-bg: #dde6d9; --pos-solid: #22686f; --pos-on: #ffffff;
  --ega: #9a6e00; --ega-ink: #7a5700; --ega-bg: #f1e2b8; --ega-solid: #c99200; --ega-on: #1e1600;
  --zal: #b03a63; --zal-ink: #8f2a4d; --zal-bg: #f2dcdf; --zal-solid: #9c2d52; --zal-on: #ffffff;
  --manager: #6258b8; --manager-ink: #4c4396; --manager-bg: #e6e0e6; --manager-solid: #51479e; --manager-on: #ffffff;
  --admin: #3f8a4f; --admin-ink: #2a6638; --admin-bg: #e2e8d2; --admin-solid: #2f6e3d; --admin-on: #ffffff;
  --brand: #fd3501; --brand-ink: #b02400; --brand-solid: #e02e00; --brand-press: #c42800; --brand-on: #ffffff;
}
[data-theme="tungi"] {
  color-scheme: dark;
  --page: #0e131a; --surface: #161d27; --surface-2: #1d2531; --surface-3: #252f3d;
  --ink: #e7ecf2; --ink-2: #b1bccb; --muted: #95a1b1;
  --grid: #243040; --axis: #35414f; --ring: rgba(200,215,235,.09); --ring-2: rgba(200,215,235,.2);
  --series-1: #3987e5; --series-1-hover: #6da7ec; --track: #184f95;
  --good: #0ca30c; --good-ink: #4cc47f; --good-bg: #12291f;
  --crit: #d03b3b; --crit-ink: #ef8a8a; --crit-bg: #34191c; --warn: #fab219; --warn-bg: #2c2410;
  --link: #86b6ef; --shadow: 0 14px 36px rgba(0,0,0,.5); --backdrop: rgba(3,6,10,.62);
  --crit-on: #ffffff;
  --stats: #5b9be8; --stats-ink: #8dbbf0; --stats-bg: #1b2d45; --stats-solid: #2a6fc9; --stats-on: #ffffff;
  --kassa: #3cc08e; --kassa-ink: #79d8b1; --kassa-bg: #15332a; --kassa-solid: #0b7a55; --kassa-on: #ffffff;
  --rasxod: #f08a4b; --rasxod-ink: #f8b48a; --rasxod-bg: #38251a; --rasxod-solid: #b9460f; --rasxod-on: #ffffff;
  --qarz: #a58bf2; --qarz-ink: #c4b4f7; --qarz-bg: #29243f; --qarz-solid: #6a45c9; --qarz-on: #ffffff;
  --pos: #35bfd4; --pos-ink: #80d7e4; --pos-bg: #133340; --pos-solid: #0c7487; --pos-on: #ffffff;
  --ega: #e3b22a; --ega-ink: #f0cc62; --ega-bg: #342b12; --ega-solid: #e0a400; --ega-on: #1b1500;
  --zal: #f06595; --zal-ink: #f7a1bd; --zal-bg: #351c28; --zal-solid: #b02150; --zal-on: #ffffff;
  --manager: #8f8cf0; --manager-ink: #b6b4f6; --manager-bg: #25264a; --manager-solid: #5652cf; --manager-on: #ffffff;
  --admin: #3cc08e; --admin-ink: #79d8b1; --admin-bg: #15332a; --admin-solid: #0b7a55; --admin-on: #ffffff;
  --brand: #fd3501; --brand-ink: #ff7a52; --brand-solid: #e02e00; --brand-press: #c42800; --brand-on: #ffffff;
}
[data-theme="neon"] {
  /* Tungi'dan farqi: fon chuqurroq va sovuqroq, chegaralar nozik firuza/binafsha neon, faol elementda
     yengil porlash (pastda). Katta neon fon yo'q. Aksentlar neon palitrada: ko'k→cyan, yashil→lime,
     binafsha→magenta, firuza→yalpiz. Hammasi AA: matn ≥4.5 (surface, surface-2, *-bg), belgi ≥3. */
  color-scheme: dark;
  --page: #06080f; --surface: #0b0f1c; --surface-2: #10162a; --surface-3: #172038;
  --ink: #e6f0ff; --ink-2: #a8b6cf; --muted: #8b99b5;
  --grid: #19223a; --axis: #2b3654; --ring: rgba(34,211,238,.13); --ring-2: rgba(192,132,252,.30);
  --neon-c: #22d3ee; --neon-m: #c084fc;
  --series-1: #3987e5; --series-1-hover: #6da7ec; --track: #184f95;
  --good: #0ca30c; --good-ink: #4ade80; --good-bg: #0d2418;
  --crit: #d03b3b; --crit-ink: #ff8098; --crit-bg: #2e1020; --warn: #fab219; --warn-bg: #2a220c;
  --link: #67e8f9; --shadow: 0 14px 40px rgba(0,0,0,.65), 0 0 0 1px rgba(34,211,238,.06); --backdrop: rgba(1,2,8,.7);
  --crit-on: #ffffff;
  --stats: #22d3ee; --stats-ink: #7ae8f7; --stats-bg: #0a2230; --stats-solid: #22d3ee; --stats-on: #041016;
  --kassa: #a3e635; --kassa-ink: #c6f27a; --kassa-bg: #16220a; --kassa-solid: #a3e635; --kassa-on: #0a1002;
  --rasxod: #ff9f43; --rasxod-ink: #ffc48a; --rasxod-bg: #2a1a0c; --rasxod-solid: #ff9f43; --rasxod-on: #140a02;
  --qarz: #e879f9; --qarz-ink: #f3b2fb; --qarz-bg: #2a1030; --qarz-solid: #e879f9; --qarz-on: #16041a;
  --pos: #3ee8b5; --pos-ink: #8ef3d3; --pos-bg: #0a2a22; --pos-solid: #3ee8b5; --pos-on: #03140e;
  --ega: #facc15; --ega-ink: #fde68a; --ega-bg: #29220a; --ega-solid: #facc15; --ega-on: #141002;
  --zal: #ff4d8d; --zal-ink: #ff9ec0; --zal-bg: #2e0f1d; --zal-solid: #ff4d8d; --zal-on: #16040c;
  --manager: #a78bfa; --manager-ink: #cbbcfd; --manager-bg: #1d1838; --manager-solid: #a78bfa; --manager-on: #0c0820;
  --admin: #a3e635; --admin-ink: #c6f27a; --admin-bg: #16220a; --admin-solid: #a3e635; --admin-on: #0a1002;
  --brand: #fd3501; --brand-ink: #ff7a52; --brand-solid: #e02e00; --brand-press: #c42800; --brand-on: #ffffff;
}
/* ===== KABINET — Telegram kabineti uslubi (oq kartalar, mayin soya, ko'k urg'u).
   Telefon sozlamasiga qarab yorug'/qorong'i (Telegram mavzusi kabi). ===== */
[data-theme="kabinet"] {
  color-scheme: light;
  --page: #f2f3f5; --surface: #ffffff; --surface-2: #f7f8fa; --surface-3: #eceef1;
  --ink: #0b0b0b; --ink-2: #6b6f76; --muted: #9aa0a6;
  --grid: #e7e9ec; --axis: #c7cbd1; --ring: rgba(11,11,11,.10); --ring-2: rgba(11,11,11,.2);
  --series-1: #2a78d6; --series-1-hover: #1c5cab; --track: #d7e6f9;
  --good: #0ca30c; --good-ink: #006300; --good-bg: #e8f5e8;
  --crit: #d03b3b; --crit-ink: #b42f2f; --crit-bg: #fcefef; --warn: #fab219; --warn-bg: #fff5da;
  --link: #2a78d6; --shadow: 0 1px 2px rgba(0,0,0,.05), 0 16px 40px -16px rgba(0,0,0,.28);
  --backdrop: rgba(11,11,11,.4); --crit-on: #ffffff;
  --stats: #2a78d6; --stats-ink: #1c5cab; --stats-bg: #e8f1fc; --stats-solid: #2a78d6; --stats-on: #ffffff;
  --kassa: #0e9f6e; --kassa-ink: #047857; --kassa-bg: #e3f5ed; --kassa-solid: #0e9f6e; --kassa-on: #ffffff;
  --rasxod: #e8590c; --rasxod-ink: #b0450a; --rasxod-bg: #fcece1; --rasxod-solid: #e8590c; --rasxod-on: #ffffff;
  --qarz: #7c4ddb; --qarz-ink: #6334c4; --qarz-bg: #f0eafc; --qarz-solid: #7c4ddb; --qarz-on: #ffffff;
  --pos: #0891a8; --pos-ink: #0b6f82; --pos-bg: #e1f3f6; --pos-solid: #0891a8; --pos-on: #ffffff;
  --ega: #a97900; --ega-ink: #835c00; --ega-bg: #fbf1d6; --ega-solid: #c08b00; --ega-on: #1b1500;
  --zal: #d6336c; --zal-ink: #b02150; --zal-bg: #fceaf0; --zal-solid: #d6336c; --zal-on: #ffffff;
  --manager: #5b57d9; --manager-ink: #4541b8; --manager-bg: #ededfc; --manager-solid: #5b57d9; --manager-on: #ffffff;
  --admin: #0e9f6e; --admin-ink: #047857; --admin-bg: #e3f5ed; --admin-solid: #0e9f6e; --admin-on: #ffffff;
  --brand: #fd3501; --brand-ink: #c42800; --brand-solid: #e02e00; --brand-press: #c42800; --brand-on: #ffffff;
}
@media (prefers-color-scheme: dark) {
  [data-theme="kabinet"] {
    color-scheme: dark;
    --page: #17212b; --surface: #1f2c3a; --surface-2: #232e3c; --surface-3: #2b3847;
    --ink: #ffffff; --ink-2: #aebdcc; --muted: #8494a6;
    --grid: #2c3a49; --axis: #3d4c5c; --ring: rgba(255,255,255,.10); --ring-2: rgba(255,255,255,.22);
    --series-1: #5288c1; --series-1-hover: #7ba7d4; --track: #2a4661;
    --good: #4bc94b; --good-ink: #7fe07f; --good-bg: #16311d;
    --crit: #e66767; --crit-ink: #f09a9a; --crit-bg: #3a1f22; --warn: #f5c451; --warn-bg: #352b12;
    --link: #7ba7d4; --shadow: 0 1px 2px rgba(0,0,0,.4), 0 18px 44px -18px rgba(0,0,0,.75);
    --backdrop: rgba(0,0,0,.6); --crit-on: #2a1214;
    --stats: #5288c1; --stats-ink: #9cc0e2; --stats-bg: #1c3346; --stats-solid: #4a7fb8; --stats-on: #ffffff;
    --kassa: #3fc79a; --kassa-ink: #7fdcbd; --kassa-bg: #143a30; --kassa-solid: #17916c; --kassa-on: #06231a;
    --rasxod: #f38b4c; --rasxod-ink: #f8b183; --rasxod-bg: #3c2416; --rasxod-solid: #cf6420; --rasxod-on: #2a1305;
    --qarz: #a98bec; --qarz-ink: #c5b0f4; --qarz-bg: #2b2347; --qarz-solid: #7f5fd6; --qarz-on: #ffffff;
    --pos: #3fb6cd; --pos-ink: #86d3e2; --pos-bg: #133440; --pos-solid: #158da6; --pos-on: #04222a;
    --ega: #e0b048; --ega-ink: #eecb84; --ega-bg: #3a2e12; --ega-solid: #c2921f; --ega-on: #241a04;
    --zal: #e77b9f; --zal-ink: #f0a9c2; --zal-bg: #3b2029; --zal-solid: #c2456e; --zal-on: #ffffff;
    --manager: #8b87ee; --manager-ink: #b3b0f5; --manager-bg: #262447; --manager-solid: #6a66d8; --manager-on: #ffffff;
    --admin: #3fc79a; --admin-ink: #7fdcbd; --admin-bg: #143a30; --admin-solid: #17916c; --admin-on: #06231a;
    --brand: #ff5a2b; --brand-ink: #ff8a63; --brand-solid: #e63e0e; --brand-press: #c43209; --brand-on: #ffffff;
  }
  [data-theme="kabinet"] .logo-l { display: none; }
  [data-theme="kabinet"] .logo-d { display: block; }
}
/* Kabinet shakli: chegara o'rniga mayin ko'tarilish (Telegram kartalari kabi) */
[data-theme="kabinet"] .card, [data-theme="kabinet"] .tile, [data-theme="kabinet"] .empty:not(.sm),
[data-theme="kabinet"] .hero-fig, [data-theme="kabinet"] .dlg-in, [data-theme="kabinet"] .menu {
  border-color: transparent; box-shadow: 0 1px 2px rgba(0,0,0,.05), 0 10px 28px -14px rgba(0,0,0,.22);
}
[data-theme="kabinet"] .hdr, [data-theme="kabinet"] .nav-bot { background: var(--surface); }

/* ===== GEYMER — klub afishalari uslubi: qora fon, neon yashil, qiya kesilgan "banner"
   shakllar, yo'g'on BOSH HARFLI sarlavhalar, yumshoq yashil porlash. AA: matn ≥4.5, belgi ≥3. ===== */
[data-theme="geymer"] {
  color-scheme: dark;
  --page: #060806; --surface: #0e130f; --surface-2: #141b15; --surface-3: #1d271e;
  --ink: #ecf8e8; --ink-2: #b3c9ad; --muted: #90a78b;
  --grid: #1b241c; --axis: #2c3a2d; --ring: rgba(142,227,42,.16); --ring-2: rgba(142,227,42,.34);
  --lime: #8ee32a; --lime-ink: #b6f25f;
  --series-1: #8ee32a; --series-1-hover: #b6f25f; --track: #24400f;
  --good: #0ca30c; --good-ink: #7ce07c; --good-bg: #0f2a10;
  --crit: #d03b3b; --crit-ink: #ff8f8f; --crit-bg: #2c1212; --warn: #fab219; --warn-bg: #2a2109;
  --link: #b6f25f; --shadow: 0 16px 44px rgba(0,0,0,.7), 0 0 0 1px rgba(142,227,42,.07);
  --backdrop: rgba(2,4,2,.72); --crit-on: #ffffff;
  /* Afishadagi kabi YAGONA neon yashil: hamma bo'lim bitta rangda, farq belgi va nom bilan */
  --stats: #8ee32a; --stats-ink: #b6f25f; --stats-bg: #17240c; --stats-solid: #8ee32a; --stats-on: #08120b;
  --kassa: #8ee32a; --kassa-ink: #b6f25f; --kassa-bg: #17240c; --kassa-solid: #8ee32a; --kassa-on: #08120b;
  --rasxod: #8ee32a; --rasxod-ink: #b6f25f; --rasxod-bg: #17240c; --rasxod-solid: #8ee32a; --rasxod-on: #08120b;
  --qarz: #8ee32a; --qarz-ink: #b6f25f; --qarz-bg: #17240c; --qarz-solid: #8ee32a; --qarz-on: #08120b;
  --pos: #8ee32a; --pos-ink: #b6f25f; --pos-bg: #17240c; --pos-solid: #8ee32a; --pos-on: #08120b;
  --ega: #8ee32a; --ega-ink: #b6f25f; --ega-bg: #17240c; --ega-solid: #8ee32a; --ega-on: #08120b;
  --zal: #8ee32a; --zal-ink: #b6f25f; --zal-bg: #17240c; --zal-solid: #8ee32a; --zal-on: #08120b;
  --manager: #8ee32a; --manager-ink: #b6f25f; --manager-bg: #17240c; --manager-solid: #8ee32a; --manager-on: #08120b;
  --admin: #8ee32a; --admin-ink: #b6f25f; --admin-bg: #17240c; --admin-solid: #8ee32a; --admin-on: #08120b;
  --brand: #fd3501; --brand-ink: #ff7a52; --brand-solid: #e02e00; --brand-press: #c42800; --brand-on: #ffffff;
  --cut: 18px; --cut-s: 11px;
  --glow: 0 0 14px color-mix(in srgb, var(--acc, var(--lime)) 34%, transparent);
}
[data-theme="geymer"] .logo-l { display: none; }
[data-theme="geymer"] .logo-d { display: block; }
/* fonda yumshoq yashil yorug'lik (afishadagi kabi) */
[data-theme="geymer"] body, body[data-theme="geymer"] {
  background-image: radial-gradient(58% 38% at 10% 6%, rgba(142,227,42,.11), transparent 62%),
                    radial-gradient(52% 34% at 92% 78%, rgba(142,227,42,.08), transparent 60%);
  background-attachment: fixed; }
/* qiya kesilgan "banner" shakl: yuqori-chap va past-o'ng burchak */
[data-theme="geymer"] .card, [data-theme="geymer"] .tile, [data-theme="geymer"] .empty:not(.sm),
[data-theme="geymer"] .hero-fig, [data-theme="geymer"] .dlg-in, [data-theme="geymer"] .menu, [data-theme="geymer"] .diffbox {
  border-radius: 4px;
  clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, var(--cut) 100%, 0 calc(100% - var(--cut)));
  background-image: linear-gradient(135deg, color-mix(in srgb, var(--lime) 6%, transparent), transparent 45%); }
[data-theme="geymer"] .btn, [data-theme="geymer"] .chip, [data-theme="geymer"] .inp, [data-theme="geymer"] .tag,
[data-theme="geymer"] .dk-prow, [data-theme="geymer"] .item, [data-theme="geymer"] .sk {
  border-radius: 3px;
  clip-path: polygon(0 0, calc(100% - var(--cut-s)) 0, 100% var(--cut-s), 100% 100%, var(--cut-s) 100%, 0 calc(100% - var(--cut-s))); }
[data-theme="geymer"] .btn.primary { background: var(--acc, var(--lime)); color: var(--acc-on, #08120b);
  border-color: transparent; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; box-shadow: var(--glow); }
[data-theme="geymer"] .btn.primary:hover { filter: brightness(1.08); }
/* sarlavhalar — yo'g'on, bosh harfli, keng oraliq (afishadagi kabi) */
[data-theme="geymer"] .page-t, [data-theme="geymer"] .card-h .t, [data-theme="geymer"] .sec-t,
[data-theme="geymer"] .tile .lbl, [data-theme="geymer"] .dlg-h .t {
  text-transform: uppercase; letter-spacing: .07em; font-weight: 800; }
[data-theme="geymer"] .tile .val, [data-theme="geymer"] .hero-fig .val { letter-spacing: -.01em; }
[data-theme="geymer"] .tile.hero .val, [data-theme="geymer"] .hero-fig .val {
  text-shadow: 0 0 16px color-mix(in srgb, var(--acc, var(--lime)) 30%, transparent); }
/* faol elementlar — yashil chiziq va porlash */
[data-theme="geymer"] .tab-ind { box-shadow: 0 0 12px color-mix(in srgb, var(--acc, var(--lime)) 75%, transparent); }
[data-theme="geymer"] .tabs-top a[aria-current="page"], [data-theme="geymer"] .chip[aria-current="page"],
[data-theme="geymer"] .chip[aria-checked="true"], [data-theme="geymer"] .chip.on,
[data-theme="geymer"] .seg > [aria-checked="true"], [data-theme="geymer"] .seg > [aria-current="page"] {
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--acc, var(--lime)) 60%, transparent), var(--glow); }
[data-theme="geymer"] .inp:focus { box-shadow: 0 0 0 1px var(--lime), var(--glow); }
[data-theme="geymer"] .btn:focus-visible, [data-theme="geymer"] .chip:focus-visible { box-shadow: var(--glow); }
[data-theme="geymer"] .hdr { border-bottom-color: transparent; position: relative; }
[data-theme="geymer"] .hdr::after, [data-theme="geymer"] .tabbar::before { content: ""; position: absolute; left: 0; right: 0; height: 2px;
  pointer-events: none; background: linear-gradient(90deg, transparent, var(--lime) 20%, var(--lime) 80%, transparent); opacity: .55; }
[data-theme="geymer"] .hdr::after { bottom: -1px; }
[data-theme="geymer"] .tabbar { border-top-color: transparent; position: relative; }
[data-theme="geymer"] .tabbar::before { top: -1px; }

[data-theme="aura"] {
  color-scheme: dark;
  --page: #0b0b0c; --surface: #151516; --surface-2: #1c1c1e; --surface-3: #252528;
  --ink: #f2f0ed; --ink-2: #bdb9b3; --muted: #9a968f;
  --grid: #262628; --axis: #3a3a3d; --ring: rgba(255,240,230,.09); --ring-2: rgba(255,240,230,.2);
  --series-1: #3987e5; --series-1-hover: #6da7ec; --track: #184f95;
  --good: #0ca30c; --good-ink: #3fcf6f; --good-bg: #12261a;
  --crit: #d03b3b; --crit-ink: #ff9aa2; --crit-bg: #331720; --warn: #fab219; --warn-bg: #2c2410;
  --link: #ff8a66; --shadow: 0 14px 40px rgba(0,0,0,.6); --backdrop: rgba(0,0,0,.66);
  --crit-on: #ffffff;
  /* AURA: asosiy (Statistika) aksenti ham brend to'q sariq — ko'k faqat grafik seriyasida (dataviz) */
  --stats: #fd3501; --stats-ink: #ff7a52; --stats-bg: #2a1a13; --stats-solid: #e02e00; --stats-on: #ffffff;
  --kassa: #3cc08e; --kassa-ink: #79d8b1; --kassa-bg: #132a22; --kassa-solid: #0b7a55; --kassa-on: #ffffff;
  --rasxod: #f5a524; --rasxod-ink: #f8c46b; --rasxod-bg: #33270f; --rasxod-solid: #f5a524; --rasxod-on: #141005;
  --qarz: #a58bf2; --qarz-ink: #c4b4f7; --qarz-bg: #262236; --qarz-solid: #6a45c9; --qarz-on: #ffffff;
  --pos: #35bfd4; --pos-ink: #80d7e4; --pos-bg: #122b31; --pos-solid: #0c7487; --pos-on: #ffffff;
  --ega: #fd3501; --ega-ink: #ff7a52; --ega-bg: #2a1a13; --ega-solid: #e02e00; --ega-on: #ffffff;
  --zal: #ff5c8a; --zal-ink: #ff93b0; --zal-bg: #2d1620; --zal-solid: #d92f5e; --zal-on: #ffffff;
  --manager: #8f8cf0; --manager-ink: #b6b4f6; --manager-bg: #222340; --manager-solid: #5652cf; --manager-on: #ffffff;
  --admin: #3cc08e; --admin-ink: #79d8b1; --admin-bg: #132a22; --admin-solid: #0b7a55; --admin-on: #ffffff;
  --brand: #fd3501; --brand-ink: #ff7a52; --brand-solid: #e02e00; --brand-press: #c42800; --brand-on: #ffffff;
}

/* Bo'lim aksenti: body[data-sec] va har navigatsiya havolasi o'z data-sec'ini oladi.
   --acc — belgi/chiziq (≥3:1), --acc-ink — matn (≥4.5:1), --acc-bg — yumshoq fon,
   --acc-solid/--acc-on — asosiy tugma. GRAFIK seriyasi DOIM --series-1 (bo'lim rangi emas). */
.viz-root, [data-sec="stats"] { --acc: var(--stats); --acc-ink: var(--stats-ink); --acc-bg: var(--stats-bg); --acc-solid: var(--stats-solid); --acc-on: var(--stats-on); }
[data-sec="kassa"]  { --acc: var(--kassa);  --acc-ink: var(--kassa-ink);  --acc-bg: var(--kassa-bg);  --acc-solid: var(--kassa-solid);  --acc-on: var(--kassa-on); }
[data-sec="rasxod"] { --acc: var(--rasxod); --acc-ink: var(--rasxod-ink); --acc-bg: var(--rasxod-bg); --acc-solid: var(--rasxod-solid); --acc-on: var(--rasxod-on); }
[data-sec="qarz"]   { --acc: var(--qarz);   --acc-ink: var(--qarz-ink);   --acc-bg: var(--qarz-bg);   --acc-solid: var(--qarz-solid);   --acc-on: var(--qarz-on); }
[data-sec="pos"]    { --acc: var(--pos);    --acc-ink: var(--pos-ink);    --acc-bg: var(--pos-bg);    --acc-solid: var(--pos-solid);    --acc-on: var(--pos-on); }
[data-sec="ega"], [data-sec="xodim"], [data-sec="users"] { --acc: var(--ega); --acc-ink: var(--ega-ink); --acc-bg: var(--ega-bg); --acc-solid: var(--ega-solid); --acc-on: var(--ega-on); }
[data-sec="zal"]    { --acc: var(--zal);    --acc-ink: var(--zal-ink);    --acc-bg: var(--zal-bg);    --acc-solid: var(--zal-solid);    --acc-on: var(--zal-on); }
/* Rol ranglari (yorliq, avatar, kirish kartalari) */
.role-owner   { --r: var(--ega);     --r-ink: var(--ega-ink);     --r-bg: var(--ega-bg);     --r-solid: var(--ega-solid);     --r-on: var(--ega-on); }
.role-manager { --r: var(--manager); --r-ink: var(--manager-ink); --r-bg: var(--manager-bg); --r-solid: var(--manager-solid); --r-on: var(--manager-on); }
.role-admin   { --r: var(--admin);   --r-ink: var(--admin-ink);   --r-bg: var(--admin-bg);   --r-solid: var(--admin-solid);   --r-on: var(--admin-on); }

/* ===== BASE ===== */
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 72px; scroll-padding-bottom: 24px; background: var(--page); }
@media (max-width: 640px) { html { scroll-padding-bottom: calc(92px + env(safe-area-inset-bottom)); } }
html, body { margin: 0; }
body { background: var(--page); color: var(--ink); min-height: 100vh; min-height: 100dvh;
       font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
       -webkit-tap-highlight-color: transparent; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--link); }
:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--muted); }
.ink2 { color: var(--ink-2); }
.num { font-variant-numeric: tabular-nums; }
h2.page-t { font-size: 21px; font-weight: 650; margin: 4px 0 14px; letter-spacing: -.01em; }
h3.sec-t { font-size: 15px; font-weight: 650; margin: 0; display: flex; align-items: center; gap: 8px; }
h3.sec-t::before { content: ""; width: 8px; height: 8px; border-radius: 3px; background: var(--acc); flex: none; }

/* Mavzu almashishi — qisqa silliq o'tish (JS 450 ms ga qo'yadi) */
html.theme-anim, html.theme-anim *, html.theme-anim *::before, html.theme-anim *::after {
  transition: background-color .35s ease, color .35s ease, border-color .35s ease, fill .35s ease, stroke .35s ease, box-shadow .35s ease !important; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .38s; }

/* ===== SARLAVHA ===== */
.hdr { position: sticky; top: 0; z-index: 30; padding-top: env(safe-area-inset-top);
       background: color-mix(in srgb, var(--page) 86%, transparent);
       -webkit-backdrop-filter: saturate(1.4) blur(14px); backdrop-filter: saturate(1.4) blur(14px);
       border-bottom: 1px solid var(--ring); }
.hdr-in { max-width: 1240px; margin: 0 auto; display: flex; align-items: center; gap: 12px; min-height: 58px; padding: 6px 16px; }
.brand { min-width: 0; display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; }
.brand .bt { display: flex; flex-direction: column; min-width: 0; }
/* Logotip: yorug' mavzuda qora matnli, qorong'ida oq matnli; tor ekranda faqat emblema */
.logo-img { display: block; height: 36px; width: auto; flex: none; }
.logo-d, .logo-m { display: none; }
:is([data-theme="tungi"], [data-theme="neon"], [data-theme="aura"]) .logo-l { display: none; }
:is([data-theme="tungi"], [data-theme="neon"], [data-theme="aura"]) .logo-d { display: block; }
@media (max-width: 360px) { .logo-l, .logo-d { display: none !important; } .logo-m { display: block; height: 34px; } }
.brand-txt { display: none; }
.nologo .brand .logo-img { display: none !important; }
.nologo .brand-txt { display: flex; }
.brand .t { font-size: 15px; font-weight: 800; line-height: 1.15; white-space: nowrap; letter-spacing: .14em; }
.brand .club { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.club-sel { height: 36px; border-radius: 10px; border: 1px solid var(--ring-2); background: var(--surface); padding: 0 8px; max-width: 160px; font-size: 14px; }
.hdr .grow { flex: 1; }
.tabs-top { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; margin-left: 6px; position: relative; padding-bottom: 4px; margin-bottom: -4px; }
.tab-ind { position: absolute; left: 0; height: 3px; border-radius: 3px; background: var(--acc); pointer-events: none; opacity: 0; will-change: transform; }
.tab-ind.ready { transition: transform .34s cubic-bezier(.3,.9,.25,1), width .34s cubic-bezier(.3,.9,.25,1), background-color .34s, opacity .2s; }
.tabs-top .tab-ind { bottom: 3px; }
.tabbar .tab-ind { top: 0; height: 3px; border-radius: 0 0 3px 3px; }
.tabs-top::-webkit-scrollbar { display: none; }
.tabs-top a { display: inline-flex; align-items: center; gap: 7px; height: 40px; padding: 0 12px; border-radius: 11px; position: relative;
              color: var(--ink-2); text-decoration: none; white-space: nowrap; font-weight: 500; transition: background .18s, color .18s; }
.tabs-top a svg { color: color-mix(in srgb, var(--acc) 70%, var(--muted)); transition: color .18s, transform .18s; }
.tabs-top a:hover { background: var(--surface-2); color: var(--ink); }
.tabs-top a:hover svg { color: var(--acc); }
.tabs-top a[aria-current="page"] { background: var(--acc-bg); color: var(--acc-ink); font-weight: 650; }
.tabs-top a[aria-current="page"] svg { color: var(--acc); }

/* Foydalanuvchi menyusi */
.user { position: relative; margin-left: auto; flex: none; }
.user-btn { display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 10px 0 5px; border-radius: 999px;
            border: 1px solid var(--ring); background: var(--surface); cursor: pointer; max-width: 230px; transition: background .15s; }
.user-btn:hover { background: var(--surface-2); }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--r-bg, var(--surface-2)); color: var(--r-ink, var(--ink-2));
          display: grid; place-items: center; font-weight: 700; font-size: 14px; flex: none;
          box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--r, var(--muted)) 55%, transparent); }
.user-btn .nmw { display: flex; flex-direction: column; min-width: 0; text-align: left; line-height: 1.15; }
.user-btn .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; font-weight: 600; }
.user-btn .rl { font-size: 11px; color: var(--r-ink, var(--muted)); font-weight: 600; white-space: nowrap; }
.user-btn .chev { color: var(--muted); flex: none; }
.menu { position: absolute; right: 0; top: calc(100% + 8px); width: min(340px, calc(100vw - 24px)); background: var(--surface);
        border: 1px solid var(--ring); border-radius: 18px; box-shadow: var(--shadow); padding: 8px; z-index: 40;
        max-height: calc(100vh - 90px); max-height: calc(100dvh - 90px); overflow-y: auto; overscroll-behavior: contain;
        transform-origin: top right; animation: popIn .18s cubic-bezier(.2,.8,.2,1); }
.menu .who { display: flex; gap: 12px; align-items: center; padding: 10px 10px 12px; border-bottom: 1px solid var(--grid); margin-bottom: 6px; }
.menu .who .avatar { width: 42px; height: 42px; font-size: 17px; }
.menu .who b { display: block; font-size: 15px; overflow-wrap: anywhere; }
.menu .who .lg { font-size: 12px; color: var(--muted); }
.menu .lbl { font-size: 12px; color: var(--muted); padding: 8px 10px 6px; font-weight: 600; letter-spacing: .02em; text-transform: uppercase; }
.menu [role="menuitem"] { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 46px; padding: 0 12px; border: 0;
  background: transparent; border-radius: 12px; cursor: pointer; text-align: left; }
.menu [role="menuitem"]:hover, .menu [role="menuitem"]:focus-visible { background: var(--surface-2); outline: none; }
.menu .sep { height: 1px; background: var(--grid); margin: 8px 0; }
.menu .danger { color: var(--crit-ink); font-weight: 600; }
/* Mavzu tanlash — har karta o'z mavzusining jonli namunasi */
.themes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; padding: 0 2px 4px; }
.th { border: 0; padding: 0; background: none; cursor: pointer; text-align: left; border-radius: 14px; position: relative; }
.th .pv { display: block; border-radius: 13px; padding: 8px; background: var(--page); color: var(--ink);
          box-shadow: inset 0 0 0 1px var(--ring-2); transition: box-shadow .18s, transform .18s; overflow: hidden; }
.th .pv .cardx { display: block; background: var(--surface); border-radius: 8px; padding: 7px 8px; box-shadow: inset 0 0 0 1px var(--ring); }
.th .pv .l1 { display: flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 700; }
.th .pv .l1 i { width: 3px; height: 11px; border-radius: 2px; background: var(--stats); }
.th .pv .l2 { display: block; height: 5px; width: 70%; border-radius: 3px; background: var(--grid); margin-top: 6px; }
.th .pv .dots { display: flex; gap: 4px; margin-top: 7px; }
.th .pv .dots i { width: 10px; height: 10px; border-radius: 50%; }
.th .pv .btnx { display: block; height: 9px; width: 42%; border-radius: 5px; background: var(--kassa-solid); margin-top: 7px; }
.th .pv-split { display: grid; grid-template-columns: 1fr 1fr; border-radius: 13px; overflow: hidden; box-shadow: inset 0 0 0 1px var(--ring-2); transition: transform .18s; }
.th .pv-split .pv { border-radius: 0; box-shadow: none; padding: 8px 4px 8px 8px; }
.th .pv-split .pv + .pv { padding: 8px 8px 8px 4px; }
.th .pv-split .pv .dots i:nth-child(n+4) { display: none; }
.th[aria-checked="true"] .pv-split { box-shadow: inset 0 0 0 1px var(--ring-2), 0 0 0 2px var(--surface), 0 0 0 4px var(--acc); }
.th:hover .pv-split { transform: translateY(-1px); }
.th .pv .aura-l1 { letter-spacing: .16em; font-weight: 800; font-size: 11px; }
.th .pv .aura-l1 img { width: 14px; height: 14px; }
.th .nmx { display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 6px 4px 2px; font-size: 13px; font-weight: 600; color: var(--ink); }
.th .nmx small { font-weight: 500; color: var(--muted); font-size: 11px; }
.th:hover .pv { transform: translateY(-1px); }
.th[aria-checked="true"] .pv { box-shadow: inset 0 0 0 1px var(--ring-2), 0 0 0 2px var(--surface), 0 0 0 4px var(--acc); }
.th[aria-checked="true"] .nmx::after { content: "✓"; color: var(--acc-ink); font-weight: 800; }
.th:focus-visible { outline: 2px solid var(--acc); outline-offset: 3px; }

/* ===== PASTKI PANEL (mobil) ===== */
.tabbar { display: none; position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; justify-content: center;
          background: color-mix(in srgb, var(--surface) 90%, transparent);
          -webkit-backdrop-filter: saturate(1.4) blur(16px); backdrop-filter: saturate(1.4) blur(16px);
          border-top: 1px solid var(--ring); padding: 4px 2px env(safe-area-inset-bottom); }
.tabbar a { flex: 1 1 0; min-width: 0; max-width: 140px; min-height: 60px; display: flex; flex-direction: column; align-items: center;
            justify-content: center; gap: 3px; color: var(--muted); text-decoration: none; font-size: 11px; font-weight: 550; position: relative; }
.tabbar a .pill { display: grid; place-items: center; width: 52px; height: 30px; border-radius: 999px; transition: background .2s, transform .2s; }
/* Ikonka rangi: avval oddiy qiymat (eski Safari uchun zaxira), keyin color-mix.
   Panel `backdrop-filter` bilan chiziladi — bolalar alohida qatlamda (iOS repaint xatosi). */
.tabbar a svg { color: var(--muted); transition: color .2s; }
@supports (color: color-mix(in srgb, red 50%, blue)) {
  .tabbar a svg { color: color-mix(in srgb, var(--acc) 55%, var(--muted)); }
}
.tabbar a { isolation: isolate; }
.tabbar a .pill, .tabbar a svg, .tabbar a .lb { position: relative; z-index: 1; }
.tabbar a span.lb { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 0 1px; font-size: 10.5px; letter-spacing: -.01em; }
.tabbar a[aria-current="page"] { color: var(--acc-ink); font-weight: 650; }
.tabbar a[aria-current="page"] .pill { background: var(--acc-bg); }
.tabbar a[aria-current="page"] svg { color: var(--acc); }
.tabbar a[aria-current="page"] .pill { animation: pillIn .28s cubic-bezier(.3,1.4,.5,1); }
.tabbar a:active .pill { transform: scale(.92); }
.tabbar a:focus-visible { outline-offset: -3px; border-radius: 12px; }
.tabbar.few a { max-width: 160px; }
/* 7+ bo'lim (Zallar qo'shilgandan keyin): yozuv kichikroq, belgi toraroq — nomlar kesilmasin */
.tabbar.many a { max-width: 96px; }
.tabbar.many a .pill { width: 44px; }
.tabbar.many a span.lb { font-size: 9.5px; letter-spacing: -.02em; }

/* ===== LAYOUT ===== */
.wrap { max-width: 1240px; margin: 0 auto; padding: 18px 16px 48px; }
.wrap:focus { outline: none; }
.view-in { animation: viewIn .22s cubic-bezier(.2,.7,.2,1) backwards; }
@media (max-width: 640px) {
  .tabs-top { display: none; }
  .tabbar { display: flex; }
  .wrap { padding: 12px 12px calc(92px + env(safe-area-inset-bottom)); }
  .hdr-in { padding: 6px 12px; gap: 8px; min-height: 54px; }
  .user-btn .nm { max-width: 104px; }
  .user-btn .rl { display: none; }
}
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-bottom: 12px; }
.toolbar .grow { flex: 1; }
.stack { display: grid; gap: 12px; }
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-bottom: 12px; }
.grid .wide { grid-column: 1 / -1; }
@media (max-width: 860px) { .grid { grid-template-columns: minmax(0, 1fr); } }
.cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; align-items: start; }
@media (max-width: 860px) { .cols { grid-template-columns: minmax(0, 1fr); } }

/* Sahifa sarlavhasi: rangli bo'lim belgisi */
.page-h { display: flex; align-items: center; gap: 12px; margin: 2px 0 16px; min-width: 0; }
.pbadge { width: 42px; height: 42px; border-radius: 13px; flex: none; display: grid; place-items: center;
          background: var(--acc-bg); color: var(--acc); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--acc) 26%, transparent); }
.page-h .pt { min-width: 0; flex: 1; }
.page-h h1 { font-size: 21px; font-weight: 700; margin: 0; letter-spacing: -.015em; line-height: 1.2; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.page-h .sub { font-size: 13px; color: var(--muted); margin-top: 1px; overflow-wrap: anywhere; }
.page-h .tools { display: flex; gap: 8px; align-items: center; flex: none; }

/* ===== BOSHQARUV ELEMENTLARI ===== */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 16px;
       border-radius: 12px; border: 1px solid var(--ring-2); background: var(--surface); color: var(--ink);
       cursor: pointer; white-space: nowrap; font-weight: 550; text-decoration: none; position: relative;
       touch-action: manipulation; transition: background .15s, transform .12s cubic-bezier(.2,.8,.2,1), box-shadow .15s, filter .15s; }
.btn:hover { background: var(--surface-2); }
.btn:active:not([disabled]) { transform: scale(.97); }
.btn svg { flex: none; }
.btn.primary { background: var(--acc-solid); border-color: transparent; color: var(--acc-on); font-weight: 650;
               box-shadow: 0 1px 2px rgba(0,0,0,.08), 0 4px 14px color-mix(in srgb, var(--acc-solid) 22%, transparent); }
.btn.primary:hover { filter: brightness(1.07) saturate(1.05); background: var(--acc-solid); }
.btn.danger { background: var(--crit); border-color: transparent; color: var(--crit-on); font-weight: 650; }
.btn.danger:hover { filter: brightness(1.07); background: var(--crit); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--ink-2); }
.btn.ghost:hover { background: var(--surface-2); color: var(--ink); }
.btn.soft { background: var(--acc-bg); border-color: transparent; color: var(--acc-ink); font-weight: 600; }
.btn.soft:hover { background: color-mix(in srgb, var(--acc-bg) 80%, var(--acc)); }
.btn.soft svg, .btn.act svg { color: var(--acc); }
.btn.sm { min-height: 36px; padding: 0 12px; border-radius: 10px; font-size: 14px; }
.btn.big { min-height: 54px; width: 100%; font-size: 17px; border-radius: 14px; }
.btn.icon { padding: 0; width: 44px; }
.btn.act { justify-content: flex-start; }
.btn[disabled] { opacity: .55; cursor: default; }
.btn.is-busy { color: transparent !important; }
.btn.is-busy > * { visibility: hidden; }
.btn.is-busy::after { content: ""; position: absolute; left: 50%; top: 50%; width: 18px; height: 18px; margin: -9px 0 0 -9px;
                      border-radius: 50%; border: 2px solid var(--ink-2); border-right-color: transparent; animation: spin .8s linear infinite; }
.btn.primary.is-busy::after { border-color: var(--acc-on); border-right-color: transparent; }
.btn.danger.is-busy::after { border-color: var(--crit-on); border-right-color: transparent; }
.btn.is-busy { opacity: 1; }
@keyframes spin { to { transform: rotate(360deg); } }
.link-btn { border: 0; background: none; padding: 0; color: var(--link); cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.back { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; color: var(--ink-2); text-decoration: none;
        border: 0; background: none; padding: 0 8px 0 0; cursor: pointer; font-size: 15px; margin-bottom: 2px; }
.back svg { color: var(--acc); transition: transform .15s; }
.back:hover { color: var(--ink); }
.back:hover svg { transform: translateX(-2px); }

.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding: 2px 2px 4px; margin: -2px -2px 0; }
.chips.scroll::-webkit-scrollbar { display: none; }
.chip { min-height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--ring-2); background: var(--surface);
        color: var(--ink-2); cursor: pointer; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px;
        text-decoration: none; font-size: 14px; touch-action: manipulation; transition: background .15s, color .15s, border-color .15s, transform .12s; }
.chip:hover { background: var(--surface-2); }
.chip:active { transform: scale(.96); }
.chip.on, .chip[aria-checked="true"], .chip[aria-pressed="true"], .chip[aria-current="page"] {
  background: var(--acc-bg); color: var(--acc-ink); border-color: color-mix(in srgb, var(--acc) 55%, transparent); font-weight: 650; }
.chip .x { font-size: 16px; line-height: 1; opacity: .7; }
.seg { display: flex; padding: 3px; border-radius: 13px; background: var(--surface-2); gap: 3px; box-shadow: inset 0 0 0 1px var(--ring); }
.seg > * { flex: 1 1 0; min-height: 40px; border: 0; border-radius: 10px; background: transparent; color: var(--ink-2);
           cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 6px; text-align: center;
           text-decoration: none; font-weight: 550; padding: 0 10px; font-size: 14px; line-height: 1.2; transition: background .18s, color .18s, box-shadow .18s; }
.seg > :hover { color: var(--ink); }
.seg > [aria-checked="true"], .seg > [aria-current="page"], .seg > [aria-selected="true"] {
  background: var(--surface); color: var(--acc-ink); font-weight: 700; box-shadow: 0 1px 3px rgba(0,0,0,.12), 0 0 0 1px var(--ring); }
.seg.wrap-seg { margin-bottom: 14px; }
@media (min-width: 641px) { .seg.wrap-seg { max-width: 560px; } }

.field { display: grid; gap: 6px; margin: 0 0 14px; }
.field > label, .field > .flabel { font-size: 14px; color: var(--ink-2); font-weight: 550; }
.field .hint { font-size: 13px; color: var(--muted); }
.field .ferr { font-size: 13px; color: var(--crit-ink); font-weight: 550; }
.field .ferr:empty { display: none; }
.inp { width: 100%; min-height: 48px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--ring-2);
       background: var(--surface); color: var(--ink); font-size: 16px; transition: border-color .15s, box-shadow .15s; }
.inp::placeholder { color: var(--muted); opacity: .85; }
textarea.inp { padding: 12px 14px; min-height: 76px; resize: vertical; line-height: 1.4; }
.inp:focus { border-color: var(--acc); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--acc) 24%, transparent); }
.inp[aria-invalid="true"] { border-color: var(--crit); }
.inp.money { font-size: 24px; font-weight: 650; min-height: 56px; letter-spacing: .01em; font-variant-numeric: tabular-nums; }
.money-wrap { position: relative; }
.money-wrap .cur { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; font-size: 15px; }
.money-wrap .inp.money { padding-right: 62px; }
.quick { display: flex; gap: 6px; flex-wrap: wrap; }
.quick .chip { min-height: 34px; font-size: 13px; }
.switch { display: flex; align-items: center; gap: 12px; min-height: 48px; cursor: pointer; }
.switch input, input.sw { appearance: none; -webkit-appearance: none; width: 50px; height: 30px; border-radius: 999px; flex: none;
                background: var(--axis); position: relative; cursor: pointer; margin: 0; transition: background .2s; }
.switch input::after, input.sw::after { content: ""; position: absolute; left: 3px; top: 3px; width: 24px; height: 24px; border-radius: 50%;
                       background: #fff; transition: transform .22s cubic-bezier(.3,1.3,.5,1); box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.switch input:checked, input.sw:checked { background: var(--acc-solid); }
.switch input:checked::after, input.sw:checked::after { transform: translateX(20px); background: var(--acc-on); }
input.sw[disabled] { opacity: .5; cursor: default; }
.switch .st { display: grid; }
.switch .st small { color: var(--muted); font-size: 13px; }
.form-err { color: var(--crit-ink); font-size: 14px; font-weight: 550; margin: 4px 0 10px; }
.form-err:empty { display: none; }

/* ===== KARTALAR / PLITKALAR ===== */
.card { background: var(--surface); border: 1px solid var(--ring); border-radius: 18px; padding: 16px; margin: 0; min-width: 0;
        box-shadow: 0 1px 2px rgba(0,0,0,.03); }
.card + .card { margin-top: 12px; }
.stack > .card + .card, .grid > .card + .card, .cols > .card + .card, .cols .card + .card { margin-top: 0; }
.cols > div > .card + .card { margin-top: 12px; }
.card-h { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 12px; }
.card-h .t { font-size: 15px; font-weight: 650; display: flex; align-items: center; gap: 8px; }
.card-h .t::before { content: ""; width: 3px; height: 15px; border-radius: 2px; background: var(--acc); flex: none; }
.card-h .s { font-size: 13px; color: var(--muted); margin-top: 1px; }
.card-h .grow { flex: 1; min-width: 0; }
.toggle { min-height: 32px; padding: 0 10px; border-radius: 9px; border: 1px solid var(--ring-2); background: transparent;
          color: var(--ink-2); cursor: pointer; font-size: 13px; flex: none; }
.toggle:hover { background: var(--surface-2); }
.toggle[aria-pressed="true"] { background: var(--acc-bg); color: var(--acc-ink); border-color: transparent; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin-bottom: 12px; }
@media (min-width: 1000px) { .kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); } .kpis.k3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 640px) { .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } }
.tile { background: var(--surface); border: 1px solid var(--ring); border-radius: 18px; padding: 14px 16px; min-width: 0; position: relative; }
.tile .lbl { font-size: 13px; color: var(--ink-2); font-weight: 550; }
.tile .val { font-size: 24px; font-weight: 700; margin-top: 4px; letter-spacing: -.015em; overflow-wrap: anywhere; line-height: 1.2; }
.tile .val .u { font-size: 14px; font-weight: 500; color: var(--ink-2); margin-left: 4px; letter-spacing: 0; display: inline-block; white-space: nowrap; overflow-wrap: normal; }
.tile .sub { font-size: 12px; color: var(--muted); margin-top: 3px; }
.tile.hero { grid-column: span 2; border-color: color-mix(in srgb, var(--acc) 30%, var(--ring));
             background: linear-gradient(135deg, var(--acc-bg), var(--surface) 72%); }
.tile.hero .lbl { color: var(--acc-ink); font-weight: 650; }
.tile.hero .val { font-size: clamp(36px, 10vw, 50px); line-height: 1.08; letter-spacing: -.025em; }
@media (max-width: 560px) { .tile.hero { grid-column: 1 / -1; } .tile .val { font-size: 21px; } .tile.hero .val { font-size: clamp(36px, 11vw, 48px); } }
a.tile, button.tile { text-align: left; color: inherit; text-decoration: none; cursor: pointer; font: inherit; }
button.tile[aria-pressed="true"], a.tile[aria-current="true"] { box-shadow: inset 0 0 0 2px var(--acc); }
.meter { height: 8px; border-radius: 999px; background: var(--track); margin-top: 10px; overflow: hidden; }
.meter i { display: block; height: 100%; background: var(--series-1); border-radius: 999px; transition: width .6s cubic-bezier(.2,.8,.2,1); }

.hero-fig { margin: 4px 0 2px; padding: 14px 16px; border-radius: 16px; background: linear-gradient(135deg, var(--acc-bg), transparent 80%);
            box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--acc) 22%, transparent); }
.hero-fig .lbl { font-size: 14px; color: var(--acc-ink); font-weight: 650; }
.hero-fig .val { font-size: clamp(36px, 10vw, 52px); font-weight: 700; letter-spacing: -.025em; line-height: 1.1; overflow-wrap: anywhere; }
.hero-fig .val .u { font-size: 18px; font-weight: 500; color: var(--ink-2); margin-left: 6px; letter-spacing: 0; }
.hero-fig .sub { font-size: 13px; color: var(--muted); margin-top: 4px; }

/* Hisob-kitob qatorlari */
.ledger { display: grid; margin: 8px 0 0; }
.lrow { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; padding: 10px 0; border-bottom: 1px solid var(--grid); align-items: baseline; }
.lrow:last-child { border-bottom: 0; }
.lrow .n { color: var(--ink); }
.lrow .v { font-variant-numeric: tabular-nums; font-weight: 650; text-align: right; white-space: nowrap; }
.lrow .d { grid-column: 1 / -1; font-size: 12px; color: var(--muted); }
.lrow.off .v, .lrow.off .n { color: var(--muted); font-weight: 500; }
.lrow.total { border-top: 2px solid var(--axis); border-bottom: 0; padding-top: 12px; }
.lrow.total .n { font-weight: 700; }
.lrow.total .v { font-size: 19px; font-weight: 750; color: var(--acc-ink); }
.lrow.warn { background: var(--warn-bg); margin: 0 -10px; padding-left: 10px; padding-right: 10px; border-radius: 10px; }
.tag { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 650; padding: 2px 9px; border-radius: 999px;
       border: 1px solid var(--ring-2); color: var(--ink-2); white-space: nowrap; vertical-align: 1px; line-height: 1.4; }
.tag.warn { background: var(--warn-bg); border-color: color-mix(in srgb, var(--warn) 60%, transparent); color: var(--ink); }
.tag.good { background: var(--good-bg); border-color: transparent; color: var(--good-ink); }
.tag.crit { background: var(--crit-bg); border-color: transparent; color: var(--crit-ink); }
.tag.info { background: var(--acc-bg); border-color: transparent; color: var(--acc-ink); }
.tag.acc { background: var(--acc-bg); border-color: color-mix(in srgb, var(--acc) 35%, transparent); color: var(--acc-ink); }
.tag .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.tag.info .dot { background: var(--acc); }
.rtag { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; padding: 2px 10px 2px 8px; border-radius: 999px;
        background: var(--r-bg); color: var(--r-ink); white-space: nowrap; line-height: 1.5;
        box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--r) 35%, transparent); }
.rtag svg { color: var(--r); }

/* Farq (kamomad/ortiqcha) — rang + belgi + so'z */
.diff { display: inline-flex; flex-wrap: wrap; justify-content: flex-end; align-items: baseline; gap: 0 6px; font-weight: 700; font-variant-numeric: tabular-nums; }
.diff > span { white-space: nowrap; }
.tile .diff { justify-content: flex-start; }
.diff.neg { color: var(--crit-ink); }
.diff.pos { color: var(--good-ink); }
.diff.zero { color: var(--ink-2); }
.diff .k { font-size: .8em; font-weight: 650; }
.diffbox { border-radius: 16px; padding: 14px 16px; background: var(--surface-2); margin: 4px 0 16px; border: 1px solid var(--ring); transition: background .25s, border-color .25s; }
.diffbox.neg { background: var(--crit-bg); border-color: color-mix(in srgb, var(--crit) 45%, transparent); }
.diffbox.pos { background: var(--good-bg); border-color: color-mix(in srgb, var(--good) 45%, transparent); }
.diffbox .row { display: flex; justify-content: space-between; gap: 12px; padding: 3px 0; }
.diffbox .row .v { font-variant-numeric: tabular-nums; font-weight: 650; }
.diffbox .big { font-size: 22px; }

/* Ogohlantirish */
.banner { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 14px; background: var(--warn-bg);
          border: 1px solid color-mix(in srgb, var(--warn) 65%, transparent); margin: 0 0 12px; font-size: 14px; color: var(--ink); }
.banner .ic { flex: none; color: var(--warn); margin-top: 1px; }
.banner.crit { background: var(--crit-bg); border-color: color-mix(in srgb, var(--crit) 45%, transparent); }
.banner.crit .ic { color: var(--crit); }
.banner.info { background: var(--acc-bg); border-color: color-mix(in srgb, var(--acc) 28%, transparent); }
.banner.info .ic { color: var(--acc); }
.banner ul { margin: 0; padding-left: 18px; }
.banner .bt { flex: 1; min-width: 0; overflow-wrap: anywhere; }

/* Ro'yxatlar */
.list { display: grid; }
.item { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; padding: 12px 0; border-bottom: 1px solid var(--grid); align-items: start; }
.item:last-child { border-bottom: 0; }
.item .main { min-width: 0; }
.item .ttl { font-weight: 650; overflow-wrap: anywhere; }
.item .note { color: var(--ink-2); font-size: 14px; overflow-wrap: anywhere; white-space: pre-wrap; }
.item .meta { color: var(--muted); font-size: 12px; margin-top: 2px; }
.item .side { text-align: right; display: grid; justify-items: end; gap: 6px; }
.item .side.wide { min-width: 180px; }
.item .amt { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; font-size: 16px; }
.item.deleted .ttl, .item.deleted .amt { text-decoration: line-through; color: var(--muted); }
.item .acts { grid-column: 1 / -1; display: flex; gap: 8px; flex-wrap: wrap; margin-top: 6px; }
.list > .item { animation: itemIn .24s cubic-bezier(.2,.7,.2,1) backwards; }
.list > .item:nth-child(2) { animation-delay: .02s; } .list > .item:nth-child(3) { animation-delay: .04s; }
.list > .item:nth-child(4) { animation-delay: .06s; } .list > .item:nth-child(5) { animation-delay: .08s; }
.list > .item:nth-child(n+6) { animation-delay: .1s; }
a.item, button.item { color: inherit; text-decoration: none; background: none; border: 0; border-bottom: 1px solid var(--grid);
                      width: 100%; text-align: left; font: inherit; cursor: pointer; border-radius: 0; transition: background .15s; }
a.item:hover, button.item:hover { background: var(--surface-2); }
a.item:last-child, button.item:last-child { border-bottom: 0; }
.list-foot { display: flex; justify-content: center; padding-top: 10px; }
.sum-line { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 10px 0 6px; border-bottom: 1px solid var(--grid); margin: 4px 0 2px; }
.sum-line b { font-size: 19px; font-variant-numeric: tabular-nums; color: var(--acc-ink); }
.kv { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 7px 12px; margin: 0; }
.kv dt { color: var(--ink-2); }
.kv dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; font-weight: 650; overflow-wrap: anywhere; }
.pays { margin: 8px 0 0; padding: 8px 12px; border-radius: 12px; background: var(--surface-2); font-size: 14px; grid-column: 1 / -1; }
.pays .p { display: flex; justify-content: space-between; gap: 10px; padding: 5px 0; border-bottom: 1px solid var(--grid); }
.pays .p:last-child { border-bottom: 0; }

/* Band kompyuterlar */
.pcs { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 8px; }
.pc { border-radius: 12px; background: var(--surface-2); padding: 8px 10px; min-width: 0; box-shadow: inset 0 0 0 1px var(--ring); position: relative; }
.pc::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 0 3px 3px 0; background: var(--acc); }
.pc b { font-size: 16px; }
.pc .tf { font-size: 12px; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pc .tm { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.pc.pp { box-shadow: inset 0 0 0 1px var(--warn); }
.pp-sum { margin-top: 6px; display: inline-block; padding: 4px 10px; border-radius: 8px; font-size: 13px;
  background: var(--warn-bg); color: var(--ink); box-shadow: inset 0 0 0 1px var(--warn); font-variant-numeric: tabular-nums; }
.pc .pp-tag { display: inline-block; margin: 2px 0; padding: 1px 6px; border-radius: 6px; font-size: 11px; font-weight: 600;
  background: var(--warn-bg); color: var(--ink); box-shadow: inset 0 0 0 1px var(--warn); }

/* Holat (agent) */
.status { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; color: var(--ink-2); min-height: 32px;
          padding: 0 12px; border-radius: 999px; border: 1px solid var(--ring); background: var(--surface); }
.status .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); flex: none; }
.status.on .dot { background: var(--good); box-shadow: 0 0 0 3px color-mix(in srgb, var(--good) 22%, transparent); animation: pulse 2.4s ease-in-out infinite; }
.status.off .dot { background: var(--crit); }
.status.warn .dot { background: var(--warn); }
.meta-t { color: var(--muted); font-size: 13px; }
.msg { font-size: 13px; color: var(--ink-2); }
.msg.err { color: var(--crit-ink); }

/* ===== GRAFIKLAR (dataviz: bitta seriya --series-1, hairline to'r) ===== */
.plot { position: relative; }
.plot svg { display: block; width: 100%; overflow: visible; }
.plot .hit { fill: transparent; cursor: default; }
.plot .hit:focus { outline: none; }
.plot .bar { transition: fill .12s; }
.plot .bar.on { fill: var(--series-1-hover); }
.plot text { fill: var(--muted); font-size: 11px; font-family: inherit; }
.plot text.lab { fill: var(--ink-2); font-weight: 650; }
.plot.grow-in .bar { transform-origin: 0 100%; transform-box: fill-box; animation: barIn .5s cubic-bezier(.2,.8,.2,1) backwards; }
.hbars { display: grid; gap: 2px; }
.hrow { display: grid; grid-template-columns: minmax(70px, 34%) 1fr auto; align-items: center; gap: 10px; min-height: 32px; border-radius: 8px; padding: 0 4px; }
.hrow:hover, .hrow:focus-visible { background: var(--surface-2); }
.hrow .n { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); }
.hrow .tr, .hrow .b { display: block; }
.hrow .tr { height: 16px; }
.hrow .b { height: 16px; background: var(--series-1); border-radius: 0 4px 4px 0; min-width: 2px; transform-origin: 0 50%; }
.hbars.grow-in .hrow .b { animation: hbarIn .5s cubic-bezier(.2,.8,.2,1) backwards; }
.hrow .v { font-variant-numeric: tabular-nums; color: var(--ink); font-size: 13px; text-align: right; }
.is-loading { opacity: .55; transition: opacity .2s; }

/* Jadvallar */
.tbl-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { text-align: left; padding: 8px 8px; border-bottom: 1px solid var(--grid); white-space: nowrap; }
th { color: var(--muted); font-weight: 600; font-size: 12px; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
td.name { max-width: 220px; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 640px) { .hide-sm { display: none; } td.name { max-width: 46vw; } }
td.wrap { white-space: normal; min-width: 160px; overflow-wrap: anywhere; }
tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: var(--surface-2); }
.empty-row { color: var(--muted); padding: 14px 8px; }

/* Tooltip */
.tip { position: fixed; z-index: 60; pointer-events: none; background: var(--surface); color: var(--ink);
       border: 1px solid var(--ring-2); border-radius: 12px; padding: 8px 10px; font-size: 12px; box-shadow: var(--shadow); max-width: 260px; }
.tip .tv { font-size: 15px; font-weight: 700; }
.tip .tl { color: var(--ink-2); }
.tip .key { display: inline-block; width: 12px; height: 3px; border-radius: 2px; background: var(--series-1); vertical-align: middle; margin-right: 6px; }

/* Bo'sh holat */
.empty { text-align: center; padding: 44px 20px; color: var(--ink-2); background: var(--surface); border: 1px solid var(--ring); border-radius: 18px; }
.empty .ic { color: var(--acc); background: var(--acc-bg); width: 64px; height: 64px; border-radius: 20px; margin-bottom: 12px;
             display: inline-grid; place-items: center; }
.empty b { display: block; color: var(--ink); font-size: 17px; margin-bottom: 6px; }
.empty p { margin: 0 auto; max-width: 420px; }
.empty .acts { margin-top: 16px; display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.empty.sm { padding: 22px 12px; border: 0; background: transparent; }
.empty.sm .ic { width: 52px; height: 52px; border-radius: 16px; }

/* Yuklanish: skeleton shimmer */
.loading-box { padding: 40px 0; display: grid; place-items: center; color: var(--muted); gap: 10px; }
.spinner { width: 26px; height: 26px; border-radius: 50%; border: 3px solid var(--grid); border-top-color: var(--acc); animation: spin .8s linear infinite; }
.skel { display: grid; gap: 12px; }
.sk { display: block; border-radius: 12px; min-height: 14px;
      background: linear-gradient(100deg, var(--surface-2) 30%, color-mix(in srgb, var(--surface-3) 70%, var(--surface)) 50%, var(--surface-2) 70%);
      background-size: 220% 100%; animation: shimmer 1.25s linear infinite; }
.skel .sk-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
@media (max-width: 640px) { .skel .sk-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } }
.skel .sk-kpis .sk { height: 92px; border-radius: 18px; }
.skel .sk-kpis .sk:first-child { grid-column: span 2; height: 112px; }
.skel .sk-card { height: 180px; border-radius: 18px; }
.skel .sk-row { display: grid; grid-template-columns: 1fr 80px; gap: 12px; align-items: center; padding: 8px 0; }
.skel .sk-row .sk:first-child { height: 34px; }
.skel .sk-row .sk:last-child { height: 18px; }
.skel .sk-line { height: 14px; }
.skel .sk-line.w60 { width: 60%; } .skel .sk-line.w80 { width: 80%; } .skel .sk-line.w40 { width: 40%; }

/* ===== OYNA (dialog) ===== */
dialog.dlg { border: 0; padding: 0; background: transparent; color: var(--ink); width: min(460px, calc(100% - 24px));
             max-width: none; max-height: calc(100% - 24px); overflow: visible; }
dialog.dlg::backdrop { background: var(--backdrop); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
dialog.dlg[open] .dlg-in { animation: dlgIn .22s cubic-bezier(.2,.8,.2,1); }
dialog.dlg[open]::backdrop { animation: fadeIn .2s ease-out; }
.dlg-in { background: var(--surface); border: 1px solid var(--ring); border-radius: 20px; box-shadow: var(--shadow);
          display: flex; flex-direction: column; max-height: calc(100vh - 24px); max-height: calc(100dvh - 24px); position: relative; overflow: hidden; }
.dlg-in::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--acc); opacity: .9; }
.dlg.alert.danger-dlg .dlg-in::before { background: var(--crit); }
.dlg-h { padding: 20px 20px 6px; }
.dlg-h h2 { margin: 0; font-size: 18px; font-weight: 700; }
.dlg-b { padding: 8px 20px 4px; overflow-y: auto; overscroll-behavior: contain; }
.dlg-b > p { margin: 0 0 14px; color: var(--ink-2); }
.dlg-f { display: flex; gap: 10px; padding: 12px 20px 18px; }
.dlg-f .btn { flex: 1 1 0; min-height: 48px; }
.dlg.alert .dlg-h { padding-top: 24px; }

/* Toast */
.toasts { position: fixed; left: 50%; transform: translateX(-50%); bottom: 20px; z-index: 70; display: grid; gap: 8px;
          width: min(420px, calc(100% - 24px)); pointer-events: none; }
@media (max-width: 640px) { .toasts { bottom: calc(80px + env(safe-area-inset-bottom)); } }
.toast { display: flex; align-items: center; gap: 10px; background: var(--surface); color: var(--ink); border: 1px solid var(--ring-2);
         border-radius: 14px; padding: 11px 14px; box-shadow: var(--shadow); font-size: 14px; font-weight: 550;
         animation: toastIn .26s cubic-bezier(.2,.9,.3,1.2); }
.toast .ti { flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; }
.toast.ok .ti { background: var(--good-bg); color: var(--good-ink); }
.toast.info .ti { background: var(--acc-bg); color: var(--acc); }
.toast.err { background: var(--crit-bg); color: var(--ink); border-color: color-mix(in srgb, var(--crit) 45%, transparent); }
.toast.err .ti { color: var(--crit-ink); }
.toast.out { animation: toastOut .2s ease-in forwards; }

/* Muvaffaqiyat belgisi (✓ chiziladi) */
.okmark { display: inline-grid; place-items: center; color: var(--good-ink); }
.okmark circle { stroke: var(--good); stroke-dasharray: 76; stroke-dashoffset: 76; animation: draw .5s cubic-bezier(.6,0,.3,1) forwards; }
.okmark path { stroke-dasharray: 30; stroke-dashoffset: 30; animation: draw .32s .34s cubic-bezier(.6,0,.3,1) forwards; }
.okmark.big { width: 72px; height: 72px; border-radius: 50%; background: var(--good-bg); animation: pop .45s cubic-bezier(.3,1.5,.5,1); }
.done-hero { text-align: center; padding: 8px 0 14px; }
.done-hero h2 { margin: 12px 0 4px; font-size: 21px; }
.done-hero p { margin: 0; color: var(--ink-2); }

/* ===== ROLLAR VA RUXSATLAR ===== */
.perm-sec { padding: 0; overflow: hidden; }
.perm-sec > .ph { display: flex; align-items: center; gap: 10px; padding: 14px 16px; background: linear-gradient(90deg, var(--acc-bg), transparent 85%);
                  border-bottom: 1px solid var(--grid); }
.perm-sec > .ph .pbadge { width: 34px; height: 34px; border-radius: 10px; }
.perm-sec > .ph b { font-size: 15px; }
.perm-sec > .ph .cnt { margin-left: auto; }
.perm { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 14px; align-items: center; padding: 12px 16px; border-bottom: 1px solid var(--grid); }
.perm:last-child { border-bottom: 0; }
.perm label { font-weight: 600; cursor: pointer; display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; }
.perm .help { grid-column: 1; font-size: 13px; color: var(--muted); }
.perm .sw { grid-column: 2; grid-row: 1 / span 2; }
.perm.changed { background: color-mix(in srgb, var(--acc-bg) 55%, transparent); }
.perm.dim label, .perm.dim .help { opacity: .6; }
.perm .chg { font-size: 11px; font-weight: 700; color: var(--acc-ink); background: var(--acc-bg); border-radius: 999px; padding: 1px 8px;
             box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--acc) 40%, transparent); }
.perm .saving { font-size: 12px; color: var(--muted); }
.roles-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; align-items: start; }
.roles-grid > .card + .card { margin-top: 0; }
@media (max-width: 860px) { .roles-grid { grid-template-columns: minmax(0, 1fr); } }
.roles-top { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 12px; }
.roles-top .seg { flex: 1 1 320px; max-width: 520px; }
.seg .cnt { font-size: 11px; font-weight: 700; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; display: inline-grid; place-items: center;
            background: var(--acc-bg); color: var(--acc-ink); }


/* ===== AURA mavzusi: logotip uslubi — kesik burchak, keng harf oralig'i, qiya chiziq, nozik porlash ===== */
[data-theme="aura"] { --cut: 12px; --cut-s: 8px;
  --aura-pat: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='56' viewBox='0 0 64 56'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='.026' stroke-width='5' stroke-linejoin='miter'%3E%3Cpath d='M8 22l10-12 10 12M36 46l10-12 10 12'/%3E%3C/g%3E%3C/svg%3E"); }
[data-theme="aura"] .hdr { background-image: var(--aura-pat); border-bottom-color: color-mix(in srgb, var(--brand) 22%, var(--ring)); }
[data-theme="aura"] .hdr::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--brand) 70%, transparent) 30%, transparent 75%); }
[data-theme="aura"] .card, [data-theme="aura"] .tile, [data-theme="aura"] .empty:not(.sm), [data-theme="aura"] .dlg-in,
[data-theme="aura"] .hero-fig, [data-theme="aura"] .menu, [data-theme="aura"] .diffbox {
  border-radius: 3px; clip-path: polygon(0 0, calc(100% - var(--cut)) 0, 100% var(--cut), 100% 100%, 0 100%); }
[data-theme="aura"] .card::after, [data-theme="aura"] .tile::after {
  content: ""; position: absolute; top: -1px; left: calc(100% - var(--cut)); width: calc(var(--cut) * 1.42); height: 2px;
  background: color-mix(in srgb, var(--acc) 55%, var(--ring-2)); transform-origin: 0 0; transform: rotate(45deg); pointer-events: none; }
[data-theme="aura"] .card { position: relative; }
[data-theme="aura"] .btn, [data-theme="aura"] .pbadge, [data-theme="aura"] .toast {
  border-radius: 3px; clip-path: polygon(0 0, calc(100% - var(--cut-s)) 0, 100% var(--cut-s), 100% 100%, 0 100%); }
[data-theme="aura"] .btn.primary, [data-theme="aura"] .btn.danger { box-shadow: none; }
[data-theme="aura"] .btn.primary:hover { filter: none; box-shadow: inset 0 0 0 1px color-mix(in srgb, #fff 30%, transparent); }
[data-theme="aura"] .btn:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--brand), inset 0 0 12px color-mix(in srgb, var(--brand) 35%, transparent); }
[data-theme="aura"] :focus-visible { outline-color: var(--brand); }
[data-theme="aura"] .inp, [data-theme="aura"] .chip, [data-theme="aura"] .seg, [data-theme="aura"] .seg > *, [data-theme="aura"] .toggle,
[data-theme="aura"] .status, [data-theme="aura"] .user-btn, [data-theme="aura"] .club-sel, [data-theme="aura"] .tabs-top a,
[data-theme="aura"] .tag, [data-theme="aura"] .rtag, [data-theme="aura"] .pc, [data-theme="aura"] .pays, [data-theme="aura"] .banner { border-radius: 3px; }
[data-theme="aura"] .inp:focus { border-color: var(--brand); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 20%, transparent), 0 0 14px color-mix(in srgb, var(--brand) 18%, transparent); }
[data-theme="aura"] .page-h h1 { text-transform: uppercase; letter-spacing: .12em; font-size: 18px; font-weight: 800; }
[data-theme="aura"] .card-h .t, [data-theme="aura"] .tile .lbl, [data-theme="aura"] .hero-fig .lbl, [data-theme="aura"] h3.sec-t,
[data-theme="aura"] .dlg-h h2, [data-theme="aura"] .menu .lbl, [data-theme="aura"] th, [data-theme="aura"] .perm-sec > .ph b {
  text-transform: uppercase; letter-spacing: .1em; }
[data-theme="aura"] .card-h .t, [data-theme="aura"] h3.sec-t { font-size: 13px; font-weight: 800; }
[data-theme="aura"] .tile .lbl, [data-theme="aura"] .hero-fig .lbl { font-size: 11.5px; font-weight: 750; letter-spacing: .13em; }
[data-theme="aura"] .dlg-h h2 { font-size: 16px; font-weight: 800; }
[data-theme="aura"] .tile .val, [data-theme="aura"] .hero-fig .val, [data-theme="aura"] .kv dd, [data-theme="aura"] .item .amt,
[data-theme="aura"] .sum-line b, [data-theme="aura"] .lrow .v { font-variant-numeric: tabular-nums; }
[data-theme="aura"] .card-h .t::before, [data-theme="aura"] h3.sec-t::before { width: 4px; border-radius: 0; transform: skewX(-22deg); }
[data-theme="aura"] .tab-ind { border-radius: 0; transform-origin: 50% 50%; clip-path: polygon(4px 0, 100% 0, calc(100% - 4px) 100%, 0 100%);
  box-shadow: 0 0 10px color-mix(in srgb, var(--acc) 60%, transparent); height: 3px; }
[data-theme="aura"] .tabs-top a[aria-current="page"] { background: transparent; }
[data-theme="aura"] .tabs-top a { text-transform: uppercase; letter-spacing: .08em; font-size: 12.5px; font-weight: 700; }
[data-theme="aura"] .tabbar a .pill { border-radius: 4px; }
[data-theme="aura"] .tabbar a .lb { letter-spacing: .02em; }
[data-theme="aura"] .tile.hero { border-color: color-mix(in srgb, var(--acc) 35%, var(--ring)); }
[data-theme="aura"] .avatar { border-radius: 4px; clip-path: polygon(0 0, calc(100% - 7px) 0, 100% 7px, 100% 100%, 0 100%); }
[data-theme="aura"] .menu { clip-path: none; }
[data-theme="aura"] .view-in { animation-name: viewClip; animation-duration: .26s; }
[data-theme="aura"] .view-in.rev { animation-name: viewClipBack; }
@keyframes viewClip { from { opacity: 0; transform: translate3d(var(--dx, 0px), 0, 0); clip-path: polygon(0 0, 0 0, 0 100%, 0 100%); }
                      60% { opacity: 1; } to { clip-path: polygon(0 0, 130% 0, 100% 100%, 0 100%); } }
@keyframes viewClipBack { from { opacity: 0; transform: translate3d(var(--dx, 0px), 0, 0); clip-path: polygon(100% 0, 100% 0, 100% 100%, 100% 100%); }
                          60% { opacity: 1; } to { clip-path: polygon(-30% 0, 100% 0, 100% 100%, 0 100%); } }


/* Qo'shimcha holatlar */
.tile.hero-lite { border-color: color-mix(in srgb, var(--acc) 30%, var(--ring)); background: linear-gradient(135deg, var(--acc-bg), var(--surface) 75%); }
.tile.hero-lite .lbl { color: var(--acc-ink); font-weight: 650; }
.btn.flash-ok { animation: flashOk .9s ease-out; }
@keyframes flashOk { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--good) 55%, transparent); } 100% { box-shadow: 0 0 0 14px transparent; } }
.seg > [class*="role-"] svg { color: var(--r); }
.seg > [class*="role-"][aria-checked="true"] { color: var(--r-ink); }
.chips .chip svg { color: var(--acc); }


/* Neon: katta neon to'ldirilgan tugma ko'zni charchatadi — qorong'i fon + neon hoshiya + yengil porlash.
   Porlash faqat faol/fokus elementda (0 0 12px, 35%); kartalarda — nozik firuza→binafsha tepa chiziq. */
[data-theme="neon"] { --glow: 0 0 12px color-mix(in srgb, var(--acc) 35%, transparent); }
[data-theme="neon"] .btn.primary { background: color-mix(in srgb, var(--acc) 14%, var(--surface)); color: var(--acc-ink);
  border: 1px solid color-mix(in srgb, var(--acc) 70%, transparent); box-shadow: var(--glow); }
[data-theme="neon"] .btn.primary:hover { filter: none; background: color-mix(in srgb, var(--acc) 22%, var(--surface)); }
[data-theme="neon"] .btn.primary.is-busy::after { border-color: var(--acc-ink); border-right-color: transparent; }
[data-theme="neon"] .tab-ind { box-shadow: 0 0 10px color-mix(in srgb, var(--acc) 70%, transparent); }
[data-theme="neon"] .card, [data-theme="neon"] .tile:not(.hero):not(.hero-lite), [data-theme="neon"] .empty:not(.sm), [data-theme="neon"] .menu {
  border-color: rgba(34,211,238,.2);
  background-image: linear-gradient(90deg, color-mix(in srgb, var(--neon-c) 75%, transparent), color-mix(in srgb, var(--neon-m) 60%, transparent) 70%, transparent);
  background-size: 100% 1px; background-repeat: no-repeat; background-position: top; }
[data-theme="neon"] .dlg-in { border-color: rgba(192,132,252,.28); }
[data-theme="neon"] .tile.hero, [data-theme="neon"] .tile.hero-lite, [data-theme="neon"] .hero-fig {
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--acc) 34%, transparent), 0 0 18px color-mix(in srgb, var(--acc) 10%, transparent); }
[data-theme="neon"] .tile.hero .val, [data-theme="neon"] .hero-fig .val, [data-theme="neon"] .lrow.total .v, [data-theme="neon"] .sum-line b {
  text-shadow: 0 0 10px color-mix(in srgb, var(--acc) 28%, transparent); }
[data-theme="neon"] .tabs-top a[aria-current="page"], [data-theme="neon"] .tabbar a[aria-current="page"] .pill,
[data-theme="neon"] .chip[aria-current="page"], [data-theme="neon"] .chip[aria-checked="true"], [data-theme="neon"] .chip.on,
[data-theme="neon"] .seg > [aria-checked="true"], [data-theme="neon"] .seg > [aria-current="page"] {
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--acc) 55%, transparent), var(--glow); }
[data-theme="neon"] .pbadge { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--acc) 45%, transparent), 0 0 10px color-mix(in srgb, var(--acc) 22%, transparent); }
[data-theme="neon"] .inp:focus { box-shadow: 0 0 0 1px var(--acc), var(--glow); }
[data-theme="neon"] .btn:focus-visible, [data-theme="neon"] .chip:focus-visible, [data-theme="neon"] .tabbar a:focus-visible { box-shadow: var(--glow); }
[data-theme="neon"] .hdr { border-bottom-color: transparent; }
[data-theme="neon"] .hdr::after, [data-theme="neon"] .tabbar::before { content: ""; position: absolute; left: 0; right: 0; height: 1px; pointer-events: none;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--neon-c) 70%, transparent) 25%, color-mix(in srgb, var(--neon-m) 70%, transparent) 75%, transparent); }
[data-theme="neon"] .hdr::after { bottom: -1px; }
[data-theme="neon"] .tabbar { border-top-color: transparent; }
[data-theme="neon"] .tabbar::before { top: -1px; }
[data-theme="neon"] .seg { box-shadow: inset 0 0 0 1px rgba(34,211,238,.16); }
[data-theme="neon"] input.sw:checked, [data-theme="neon"] .switch input:checked { box-shadow: 0 0 10px color-mix(in srgb, var(--acc) 40%, transparent); }


/* Fokus halqasi aylantiriladigan konteynerlarda kesilmasin */
.tabs-top a:focus-visible, .chips.scroll .chip:focus-visible, .seg > :focus-visible { outline-offset: -2px; }
[data-theme="aura"] .th[aria-checked="true"] .pv, [data-theme="aura"] .th[aria-checked="true"] .pv-split { box-shadow: inset 0 0 0 1px var(--ring-2), 0 0 0 2px var(--surface), 0 0 0 4px var(--brand); }
[data-theme="aura"] .th[aria-checked="true"] .nmx::after { color: var(--brand-ink); }
[data-theme="aura"] .lrow.warn, [data-theme="aura"] .sk, [data-theme="aura"] .th .pv, [data-theme="aura"] .th .pv-split { border-radius: 3px; }

/* ===== ANIMATSIYALAR ===== */
@keyframes viewIn { from { opacity: 0; transform: translate3d(var(--dx, 0px), 8px, 0); } }
@keyframes itemIn { from { opacity: 0; transform: translateY(6px); } }
@keyframes fadeIn { from { opacity: 0; } }
@keyframes popIn { from { opacity: 0; transform: translateY(-6px) scale(.97); } }
@keyframes dlgIn { from { opacity: 0; transform: translateY(12px) scale(.97); } }
@keyframes toastIn { from { opacity: 0; transform: translateY(14px) scale(.96); } }
@keyframes toastOut { to { opacity: 0; transform: translateY(10px) scale(.97); } }
@keyframes shimmer { from { background-position: 120% 0; } to { background-position: -120% 0; } }
@keyframes pillIn { from { transform: scale(.6); opacity: .3; } }
@keyframes barIn { from { transform: scaleY(0); } }
@keyframes hbarIn { from { transform: scaleX(0); } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes pop { from { transform: scale(.5); opacity: 0; } }
@keyframes pulse { 50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--good) 0%, transparent); } }
@keyframes shake { 10%, 90% { transform: translateX(-2px); } 20%, 80% { transform: translateX(4px); } 30%, 50%, 70% { transform: translateX(-7px); } 40%, 60% { transform: translateX(7px); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .okmark circle, .okmark path { stroke-dashoffset: 0 !important; }
  ::view-transition-old(root), ::view-transition-new(root) { animation: none !important; }
}
@media (forced-colors: active) {
  .chip.on, .chip[aria-checked="true"], .seg > [aria-checked="true"], .seg > [aria-current="page"],
  .tabs-top a[aria-current="page"], .tabbar a[aria-current="page"] { outline: 2px solid CanvasText; }
}

/* ===== DO'KON (Mahsulot bo'limi: sotuv, katalog, ombor, suratdan qo'shish) — dokon.js ===== */
.dk-tabs { overflow-x: auto; scrollbar-width: none; }
.dk-tabs::-webkit-scrollbar { display: none; }
.dk-tabs a { flex: 1 0 auto; min-width: 92px; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
             text-decoration: none; }
.dk-tabs .cnt { font-size: 11px; font-weight: 800; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px;
                display: inline-grid; place-items: center; background: var(--crit); color: var(--crit-on); }

/* rasm / harf */
.dk-th { width: 40px; height: 40px; border-radius: 10px; flex: none; overflow: hidden; display: grid; place-items: center;
         background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--ring); }
/* Rasm TO'LIQ ko'rinsin (qirqilmasin): contain + yengil fon va ichki bo'shliq */
.dk-th img { width: 100%; height: 100%; object-fit: contain; display: block; padding: 2px;
             background: var(--surface); }
.dk-th.big img { padding: 3px; }
.dk-th .ltr { font-weight: 800; color: var(--acc-ink); font-size: 16px; }
.dk-th.sm { width: 34px; height: 34px; border-radius: 9px; }
.dk-th.big { width: 64px; height: 64px; border-radius: 14px; }
.dk-th.big .ltr { font-size: 24px; }

/* qidiruv / skaner maydoni */
.dk-find { margin-bottom: 12px; }
.dk-find-in { position: relative; display: flex; align-items: center; gap: 8px; }
.dk-find-in.grow { flex: 1; }
.dk-find-ic { position: absolute; left: 14px; color: var(--acc); pointer-events: none; display: grid; }
.dk-find-in .inp { padding-left: 46px; }
.dk-scan { min-height: 54px; font-size: 17px; }
.dk-scan.big { min-height: 64px; font-size: 20px; font-weight: 600; border-width: 2px; border-color: var(--acc);
               box-shadow: 0 0 0 4px color-mix(in srgb, var(--acc) 12%, transparent); }
.dk-cam-b { flex: none; }
.dk-msg { font-size: 13px; color: var(--muted); min-height: 18px; margin-top: 4px; }
.dk-msg.err { color: var(--crit-ink); font-weight: 550; }
.dk-res { margin-top: 8px; border: 1px solid var(--ring); border-radius: 14px; overflow: hidden; background: var(--surface); }
.dk-ri { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; border: 0; background: transparent;
         padding: 8px 12px; min-height: 56px; border-bottom: 1px solid var(--grid); cursor: pointer; color: inherit; }
.dk-ri:last-child { border-bottom: 0; }
.dk-ri:hover, .dk-ri:focus-visible { background: var(--surface-2); }
.dk-ri .nm { flex: 1; min-width: 0; display: grid; }
.dk-ri .nm b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dk-ri .mt { font-size: 12px; color: var(--muted); }
.dk-ri .pr { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }

/* sotuv: ikki ustun */
.dk-sell { display: grid; grid-template-columns: minmax(0, 1fr) minmax(320px, 420px); gap: 12px; align-items: start; }
.dk-right { position: sticky; top: 74px; display: grid; gap: 12px; }
.dk-favt { font-size: 13px; color: var(--ink-2); font-weight: 600; margin: 4px 0 8px; }
.dk-fav { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 8px; }
.dk-fi { display: grid; justify-items: center; gap: 4px; padding: 10px 6px; border-radius: 14px; border: 1px solid var(--ring);
         background: var(--surface); cursor: pointer; color: inherit; min-height: 118px; align-content: start;
         transition: transform .14s, border-color .14s, background .14s; }
.dk-fi:hover { border-color: var(--acc); background: var(--surface-2); }
.dk-fi:active { transform: scale(.96); }
.dk-fi .nm { font-size: 12.5px; line-height: 1.25; text-align: center; overflow: hidden; display: -webkit-box;
             -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.dk-fi .pr { font-weight: 750; font-variant-numeric: tabular-nums; }
.dk-fi .zero { font-size: 11px; color: var(--crit-ink); font-weight: 650; }

/* savat */
.dk-lines { display: grid; }
.dk-line { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 6px 8px; align-items: center;
           grid-template-areas: "th nm sum" "qty qty acts";
           padding: 8px 0; border-bottom: 1px solid var(--grid); }
.dk-line > .dk-th { grid-area: th; }
.dk-line .nm { grid-area: nm; }
.dk-line .sum { grid-area: sum; }
.dk-line .qty { grid-area: qty; }
.dk-line .acts { grid-area: acts; justify-content: flex-end; }
.dk-line:last-child { border-bottom: 0; }
.dk-line .nm { min-width: 0; display: grid; }
.dk-line .nm b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dk-line .mt { font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dk-line .qty { display: flex; align-items: center; gap: 2px; }
.dk-line .pm { width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--ring-2); background: var(--surface);
               display: grid; place-items: center; cursor: pointer; color: var(--ink); flex: none; }
.dk-line .pm:hover { background: var(--surface-2); }
.dk-line .pm:active { transform: scale(.92); }
.dk-line .q { min-width: 42px; height: 34px; padding: 0 6px; border: 0; background: transparent; font-weight: 700;
              font-variant-numeric: tabular-nums; cursor: pointer; color: var(--ink); border-radius: 8px; }
.dk-line .q:hover { background: var(--surface-2); }
.dk-line .sum { font-variant-numeric: tabular-nums; text-align: right; min-width: 64px; }
.dk-line .acts { display: flex; gap: 2px; }
.ib { width: 34px; height: 34px; border-radius: 9px; border: 0; background: transparent; display: grid; place-items: center;
      cursor: pointer; color: var(--ink-2); flex: none; }
.ib:hover { background: var(--surface-2); color: var(--ink); }
.ib.del:hover { color: var(--crit-ink); }
.ib[disabled] { opacity: .4; cursor: default; }
.dk-tot, .dk-total { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 12px 0 2px;
                     border-top: 2px solid var(--axis); margin-top: 8px; font-weight: 650; }
.dk-tot b, .dk-total b { font-size: 24px; font-variant-numeric: tabular-nums; color: var(--acc-ink); }
.dk-total { border-top: 0; padding-top: 6px; }

/* to'lov */
.dk-pay .chips { margin-bottom: 12px; }
.dk-split { display: grid; gap: 8px; margin-bottom: 10px; }
.dk-splitrow { display: grid; grid-template-columns: 72px minmax(0, 1fr) auto; gap: 8px; align-items: center; }
.dk-splitrow .l { font-size: 14px; color: var(--ink-2); font-weight: 550; }
.dk-splitrow .inp.money { font-size: 18px; min-height: 46px; }
.dk-rest { font-size: 13px; font-weight: 650; margin-bottom: 10px; }
.dk-rest.ok { color: var(--good-ink); }
.dk-rest.warn { color: var(--crit-ink); }
.dk-change { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-top: 8px;
             padding: 10px 12px; border-radius: 12px; background: var(--surface-2); font-weight: 650; }
.dk-change.ok { background: var(--good-bg); color: var(--good-ink); }
.dk-change.warn { background: var(--crit-bg); color: var(--crit-ink); }
.dk-change b { font-size: 22px; font-variant-numeric: tabular-nums; }
.dk-sellbtn { margin-top: 10px; min-height: 62px; font-size: 19px; font-weight: 800; letter-spacing: .02em; }

/* "Arxiv" tugmasi yoqilganda ko'rinib tursin (katalogdan boshqa rejimdamiz) */
.dk-archb.on { border-color: var(--acc); color: var(--acc); background: var(--surface-2); }

/* guruh oynasidagi ro'yxat (133 ta mahsulot ham bo'lishi mumkin) — o'zi aylanadi */
.dk-glist { max-height: min(46vh, 380px); overflow-y: auto; margin-top: 10px;
            border-top: 1px solid var(--grid); -webkit-overflow-scrolling: touch; }
.dk-glist .item { padding: 10px 0; }

/* hisobotdagi "O'zgarishlar tarixi": eski qiymat chizilgan, yangisi qalin.
   Qiymat (nom, shtrix-kodlar) uzun bo'lishi mumkin — shuning uchun yorliq tepada,
   qiymat ostida alohida qatorda (bir qatorga tiqilsa ustma-ust tushib ketardi). */
.dk-diff .lrow { grid-template-columns: minmax(0, 1fr); gap: 3px; }
.dk-diff .n { color: var(--muted); font-size: 12.5px; }
.dk-diff .v { display: flex; gap: 6px; align-items: baseline; flex-wrap: wrap;
              justify-content: flex-start; text-align: left; white-space: normal; overflow-wrap: anywhere; }
.dk-diff .old, .dk-diff .ar { color: var(--muted); font-weight: 500; }

/* sotuvning 2-bosqichi: alohida tasdiqlash bo'limi (savat + to'lov + TASDIQLASH) */
.dk-check { display: grid; gap: 12px; max-width: 620px; margin: 0 auto; align-content: start; }
.dk-check .dk-back { justify-self: start; }

/* pastdagi tez chiziq (telefon) */
.dk-bar { display: none; }
.dk-chg { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 16px; margin: 0 0 14px;
          border-radius: 18px; background: var(--good-bg); color: var(--good-ink); }
.dk-chg .l { font-size: 14px; font-weight: 650; }
.dk-chg b { font-size: clamp(34px, 9vw, 46px); font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.dk-done { max-width: 560px; margin: 0 auto; }
.dk-done .btn.big { margin-top: 14px; }

/* katalog */
.dk-tools { display: flex; gap: 10px; align-items: center; margin-bottom: 12px; }
.dk-tools .grow { flex: 1; min-width: 0; }
.dk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.dk-card { display: grid; justify-items: center; gap: 3px; padding: 12px 8px; border-radius: 16px; border: 1px solid var(--ring);
           background: var(--surface); cursor: pointer; color: inherit; text-align: center; align-content: start;
           transition: transform .14s, border-color .14s; }
.dk-card:hover { border-color: var(--acc); }
.dk-card:active { transform: scale(.97); }
.dk-card.arch { opacity: .55; }
.dk-card .nm { font-size: 13.5px; font-weight: 600; line-height: 1.25; margin-top: 4px; overflow: hidden;
               display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.dk-card .pr { font-weight: 750; font-variant-numeric: tabular-nums; }
.dk-card .qt { font-size: 12px; color: var(--muted); }
.dk-card .qt.low { color: var(--warn); font-weight: 650; }
.dk-card .qt.zero { color: var(--crit-ink); font-weight: 650; }
.dk-card .ex { font-size: 11px; color: var(--muted); }
.dk-card .ex.warn { color: var(--warn); font-weight: 650; }
.dk-card .ex.bad { color: var(--crit-ink); font-weight: 650; }
/* katalog ro'yxati — ixcham qatorlar */
.dk-list { display: grid; gap: 6px; }
.dk-prow { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; align-items: center; gap: 10px;
           width: 100%; min-height: 52px; padding: 6px 12px 6px 8px; border-radius: 12px; border: 1px solid var(--ring);
           background: var(--surface); cursor: pointer; color: inherit; text-align: left;
           transition: border-color .14s, background .14s; }
.dk-prow:hover { border-color: var(--acc); }
.dk-prow:active { background: var(--surface-2); }
.dk-prow.arch { opacity: .55; }
.dk-prow .nm { min-width: 0; display: grid; gap: 1px; }
.dk-prow .nm b { font-size: 14px; font-weight: 600; line-height: 1.25; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dk-prow .nm .sub { font-size: 11.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dk-prow .nm .sub.warn { color: var(--warn); }
.dk-prow .nm .sub.bad { color: var(--crit-ink); }
.dk-prow .rt { display: grid; justify-items: end; gap: 1px; }
.dk-prow .pr { font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.dk-prow .pr.none { font-weight: 600; font-size: 12.5px; color: var(--warn); }
.dk-prow .qt { font-size: 11.5px; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.dk-prow .qt.low { color: var(--warn); font-weight: 650; }
.dk-prow .qt.zero { color: var(--crit-ink); font-weight: 650; }
/* ===== TURKUMLAR + KO'P TANLASH (Mahsulotlar tabi, DOKON_API.md §8) ===== */
/* Qidiruv va turkum chiplari sahifa tepasiga yopishadi — katalog uzun bo'lsa ham qo'l ostida turadi */
.dk-cathead { position: sticky; top: calc(58px + env(safe-area-inset-top)); z-index: 14;
              background: var(--page); margin: 0 -16px 10px; padding: 10px 16px 6px;
              border-bottom: 1px solid var(--ring); }
.dk-cathead .dk-tools { margin-bottom: 8px; }
.dk-catrow { display: flex; gap: 8px; align-items: center; }
.dk-catrow[hidden] { display: none; }
.dk-catrow .chips { flex: 1 1 auto; min-width: 0; }
.dk-catrow .dk-catmg { flex: none; }
.chip .cnt { font-size: 11.5px; font-weight: 700; min-width: 20px; height: 19px; padding: 0 5px; border-radius: 999px;
             display: inline-grid; place-items: center; background: var(--surface-2); color: var(--muted);
             font-variant-numeric: tabular-nums; }
.chip[aria-checked="true"] .cnt, .chip[aria-pressed="true"] .cnt {
             background: color-mix(in srgb, var(--acc) 26%, transparent); color: var(--acc-ink); }
.chips .chip.none { font-style: italic; }
.btn.icon.sm { width: 44px; min-height: 44px; }
/* natija soni / tanlash chizig'i */
.dk-stat { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; min-height: 40px; }
.dk-stat .n { flex: 1 1 auto; font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.dk-stat .n.sel { flex: none; color: var(--acc-ink); font-size: 14px; font-weight: 700; }
.dk-stat .n.sel + .btn { margin-right: auto; }
.dk-stat .btn { flex: none; }
.dk-stat .btn.sm { min-height: 40px; }
@media (pointer: coarse) { .dk-stat .btn.sm { min-height: 44px; } }
@media (max-width: 400px) { .dk-stat .btn.sm { padding: 0 9px; font-size: 13px; } .dk-stat .btn.sm.icon { padding: 0; } }
/* "Tanlash" rejimi: qatorda belgilash katakchasi */
.dk-list.pick .dk-prow { grid-template-columns: 22px 34px minmax(0, 1fr) auto; cursor: pointer; user-select: none; }
.dk-prow.sel:hover { border-color: var(--acc); }
.dk-prow.sel:has(.dk-ck:checked) { border-color: var(--acc); background: var(--acc-bg); }
.dk-ck { appearance: none; -webkit-appearance: none; width: 22px; height: 22px; margin: 0; flex: none; border-radius: 7px;
         border: 2px solid var(--ring-2); background: var(--surface); cursor: pointer; display: grid; place-items: center;
         transition: background .15s, border-color .15s; }
.dk-ck:checked { background: var(--acc-solid); border-color: var(--acc-solid); }
.dk-ck:checked::after { content: ""; width: 11px; height: 6px; border-left: 2.5px solid var(--acc-on);
         border-bottom: 2.5px solid var(--acc-on); transform: rotate(-45deg) translate(1px, -1px); }
/* turkumlarni boshqarish oynasi */
.dk-catmgl { display: grid; gap: 6px; max-height: 52vh; overflow-y: auto; }
.dk-catmgr { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 10px;
             width: 100%; min-height: 48px; padding: 0 10px 0 12px; border-radius: 12px; border: 1px solid var(--ring);
             background: var(--surface); color: inherit; text-align: left; cursor: pointer;
             transition: border-color .14s, background .14s; }
.dk-catmgr:hover { border-color: var(--acc); background: var(--surface-2); }
.dk-catmgr .n { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dk-catmgr .c { font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.dk-catmgr svg { color: var(--muted); }
/* mahsulot formasidagi turkum tanlagich */
.dk-catpick { margin-top: 8px; }
@media (pointer: coarse) { .dk-catrow .chip, .dk-catpick .chip { min-height: 44px; } }
@media (prefers-reduced-motion: reduce) { .dk-ck, .dk-catmgr, .dk-prow.sel { transition: none; } }

.dk-recside { display: flex; align-items: center; gap: 10px; }
.dk-det { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.dk-det .nm { font-size: 17px; }
.dk-det .pr { font-weight: 750; font-size: 17px; margin-top: 2px; }

/* forma qo'shimchalari */
.dk-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.dk-row .inp { flex: 1; min-width: 140px; }
.inp.sm { min-height: 40px; padding: 0 10px; border-radius: 10px; font-size: 15px; }
.inp.num { text-align: right; font-variant-numeric: tabular-nums; }
.inp.money.sm { font-size: 16px; min-height: 40px; font-weight: 600; }
.dk-codes { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.dk-code { display: inline-flex; align-items: center; gap: 4px; padding: 4px 4px 4px 10px; border-radius: 999px;
           background: var(--acc-bg); color: var(--acc-ink); font-weight: 650; font-variant-numeric: tabular-nums; font-size: 13px; }
.dk-code .x { width: 22px; height: 22px; border-radius: 50%; border: 0; background: transparent; color: inherit;
              display: grid; place-items: center; cursor: pointer; }
.dk-code .x:hover { background: color-mix(in srgb, var(--acc) 22%, transparent); }
.dk-imgrow { display: flex; gap: 12px; align-items: center; }
.dk-imgprev { width: 84px; height: 84px; border-radius: 14px; overflow: hidden; background: var(--surface-2); flex: none;
              display: grid; place-items: center; box-shadow: inset 0 0 0 1px var(--ring); }
.dk-imgprev img { width: 100%; height: 100%; object-fit: cover; }
.dk-imgprev .ph { color: var(--muted); }
.dk-imgacts { display: flex; flex-wrap: wrap; gap: 6px; }
.dk-fp { display: inline-flex; }
.dk-camwrap .scanbox { height: min(58vh, 340px); }

/* ombor: qator tahriri */
.dk-inline { display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto auto; gap: 8px; align-items: end;
             padding: 10px 0; border-bottom: 1px solid var(--grid); }
.dk-inline:last-child { border-bottom: 0; }
.dk-inline .nm { min-width: 0; display: grid; align-self: center; }
.dk-inline .nm b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dk-inline .mt { font-size: 12px; color: var(--muted); }
.dk-inline .f { display: grid; gap: 3px; }
.dk-inline .f > span { font-size: 11px; color: var(--muted); font-weight: 600; }
.dk-inline .f .inp { width: 104px; }

/* suratdan qo'shish (AI qoralama) */
.dk-shot { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 4px 0 14px; }
.dk-shot .btn.big { width: auto; min-width: 260px; }
.dk-wait { display: flex; gap: 12px; align-items: center; padding: 14px; border-radius: 14px; background: var(--acc-bg);
           margin-bottom: 12px; }
.dk-shotimg { margin-top: 12px; }
.dk-shotimg button { border: 1px solid var(--ring); background: var(--surface-2); border-radius: 14px; padding: 0;
                     overflow: hidden; cursor: zoom-in; display: block; max-width: 100%; }
.dk-shotimg img { display: block; max-width: 100%; max-height: 260px; object-fit: contain; }
.dk-bigimg { display: block; max-width: 100%; max-height: 70vh; margin: 0 auto; border-radius: 12px; }
.dk-draft { display: grid; grid-template-columns: minmax(0, 1fr) minmax(200px, 300px); gap: 14px; align-items: start; }
.dk-draft-rows { display: grid; gap: 10px; }
.dk-drow { border: 1px solid var(--ring); border-radius: 14px; padding: 10px; background: var(--surface); }
.dk-drow.low { border-color: color-mix(in srgb, var(--warn) 60%, transparent); background: var(--warn-bg); }
.dk-drow.skip { opacity: .5; }
.dk-drow.skip .h .inp { text-decoration: line-through; }
.dk-drow .h { display: flex; gap: 8px; align-items: center; }
.dk-drow .h .n { font-size: 12px; font-weight: 700; color: var(--muted); min-width: 26px; }
.dk-drow .tags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 8px 0 6px; }
.dk-drow .fs { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 8px; }
.dk-drow .f { display: grid; gap: 3px; min-width: 0; }
.dk-drow .f > span { font-size: 11px; color: var(--muted); font-weight: 600; }
.dk-drow .f .inp { min-width: 0; }
.dk-drow .f .inp[type="date"] { padding: 0 8px; font-size: 13.5px; }
/* sana maydoni ostidagi ko'rsatkich: brauzer mm/dd/yyyy chizsa ham foydalanuvchi kun.oy.yil ko'radi */
.dk-dhint { font-size: 11px; color: var(--muted); letter-spacing: .02em; }
.dk-dhint.set { color: var(--fg); font-weight: 600; }

@media (max-width: 980px) {
  .dk-sell { grid-template-columns: minmax(0, 1fr); }
  .dk-right { position: static; }
  .dk-draft { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .dk-cathead { top: calc(56px + env(safe-area-inset-top)); margin: 0 -12px 8px; padding: 8px 12px 4px; }
  .dk-scan.big { min-height: 56px; font-size: 18px; }
  .dk-fav { grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); }
  .dk-grid { grid-template-columns: repeat(auto-fill, minmax(46%, 1fr)); }
  .dk-inline { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dk-inline .nm { grid-column: 1 / -1; }
  .dk-inline .f .inp { width: 100%; }
  .dk-inline > .ib { grid-column: 2; justify-self: end; }
  .dk-shot .btn.big { width: 100%; min-width: 0; }
  /* savat to'lganda pastdagi tez chiziq: jami + "Sotish" (tabbar ustida) */
  .dk-bar { display: block; position: fixed; left: 0; right: 0; bottom: calc(64px + env(safe-area-inset-bottom)); z-index: 25;
            background: var(--surface); border-top: 1px solid var(--ring-2); box-shadow: 0 -8px 24px rgba(0,0,0,.10);
            padding: 8px 12px calc(8px); animation: barUp .22s cubic-bezier(.2,.7,.2,1); }
  .dk-bar .in { display: flex; gap: 10px; align-items: center; max-width: 1240px; margin: 0 auto; }
  .dk-bar .sm { flex: 1; min-width: 0; display: grid; }
  .dk-bar .sm .l { font-size: 12px; color: var(--muted); }
  .dk-bar .sm b { font-size: 19px; font-variant-numeric: tabular-nums; }
  .dk-bar .btn { min-height: 46px; padding: 0 22px; }
  .dk-bar .btn.ghost { padding: 0 14px; }
  .dk-sell, .dk-check { padding-bottom: 74px; }
  /* shu kenglikda pastdagi chiziqda "Sotish" bor — savat ichidagisi ortiqcha bo'lib qoladi
     (kompyuterda esa chiziq YO'Q, shuning uchun u yerda savat ichidagisi yagona yo'l) */
  .dk-cart .dk-sellbtn { display: none; }
}
@keyframes barUp { from { transform: translateY(100%); opacity: 0; } }

/* ===== ZALLAR (klub xonalari, o'rin xaritasi, masofadan quvvat) — zal.js =====
   Holat ranglari YOLG'IZ emas: har plitkada belgi (● ▮ ○ ?) va so'z ham bor.
   bo'sh+yoqiq — yashil (--good), band — amber (--warn) + qolgan vaqt,
   o'chiq — kulrang (--muted), noma'lum — punktir hoshiya + "?". */
.zwrap { display: grid; gap: 12px; align-items: start; }
@media (min-width: 1100px) { .zwrap { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* KPI qatori: katta "Hozir band" + 3 ta kichik (mobilda 3 ustun) */
@media (min-width: 1000px) { .kpis.zkpi { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
@media (max-width: 640px) { .kpis.zkpi { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .kpis.zkpi .tile.hero { grid-column: 1 / -1; } .kpis.zkpi .tile .val { font-size: 22px; }
  .kpis.zkpi .tile:not(.hero) { padding: 12px 10px; } }
.ztop { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.zleg { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; font-size: 12px; color: var(--ink-2); }
.zleg .li { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px 3px 8px; border-radius: 999px;
            background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--ring); white-space: nowrap; }
.zleg .li .d { width: 9px; height: 9px; border-radius: 3px; flex: none; }
.zleg .li.bosh .d { background: var(--good); }
.zleg .li.band .d { background: var(--warn); }
.zleg .li.off .d { background: var(--axis); }
.zleg .li.unk .d { background: transparent; box-shadow: inset 0 0 0 1.5px var(--axis); }

/* Zona kartasi */
.zroom { padding: 14px 14px 16px; }
.zroom > .card-h { margin-bottom: 10px; }
.zroom .zh { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; }
.zroom .zn { font-size: 16px; font-weight: 700; letter-spacing: -.01em; }
.zroom .zs { font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }
.zroom > .card-h { flex-wrap: wrap; align-items: center; }
.zacts { display: flex; gap: 8px; flex: none; }
.zacts .btn { min-height: 36px; padding: 0 11px; border-radius: 10px; font-size: 13.5px; }
@media (max-width: 560px) { .zacts { flex: 1 0 100%; } .zacts .btn { flex: 1 1 0; min-width: 0; } }

/* O'rin xaritasi */
.zmap { display: grid; grid-template-columns: repeat(auto-fill, minmax(66px, 1fr)); gap: 8px; }
@media (max-width: 400px) { .zmap { grid-template-columns: repeat(auto-fill, minmax(60px, 1fr)); gap: 7px; } }
@media (min-width: 900px) { .zmap { grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); } }
.zpc { position: relative; display: grid; align-content: start; justify-items: center; gap: 1px; padding: 7px 4px 9px;
       min-height: 76px; border-radius: 14px; border: 1px solid var(--ring-2); background: var(--surface-2);
       color: var(--ink); font: inherit; cursor: pointer; overflow: hidden; text-align: center;
       transition: transform .14s cubic-bezier(.2,.8,.2,1), box-shadow .18s, background-color .35s, border-color .35s, color .35s; }
.zpc .n { font-size: 21px; font-weight: 750; line-height: 1.05; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.zpc .zst { display: flex; align-items: center; gap: 4px; font-size: 10.5px; font-weight: 700; line-height: 1.2; letter-spacing: .01em; }
.zpc .zst .d { width: 7px; height: 7px; border-radius: 50%; flex: none; background: currentColor; }
.zpc .ztm { font-size: 11.5px; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.2; }
.zpc .vip { position: absolute; top: 3px; right: 4px; color: var(--ega); display: grid; place-items: center; }
.zpc .qm { position: absolute; top: 4px; left: 6px; font-size: 11px; font-weight: 800; color: var(--muted); }
.zpc .zbar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: color-mix(in srgb, var(--ink) 10%, transparent); }
.zpc .zbar i { display: block; height: 100%; background: var(--warn); transition: width .6s cubic-bezier(.2,.8,.2,1); }
.zpc:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,.13); }
.zpc:active { transform: scale(.96); }
.zpc:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }
.zpc[data-st="bosh"] { background: var(--good-bg); border-color: color-mix(in srgb, var(--good) 45%, transparent); }
.zpc[data-st="bosh"] .zst { color: var(--good-ink); }
.zpc[data-st="band"] { background: var(--warn-bg); border-color: color-mix(in srgb, var(--warn) 70%, transparent); }
.zpc[data-st="band"] .zst, .zpc[data-st="band"] .ztm { color: var(--ink); }
.zpc[data-st="off"] { background: var(--surface-2); border-color: var(--ring-2); }
.zpc[data-st="off"] .n { color: var(--ink-2); }
.zpc[data-st="off"] .zst { color: var(--muted); }
.zpc[data-st="unk"] { background: transparent; border-style: dashed; border-color: var(--axis); }
.zpc[data-st="unk"] .n, .zpc[data-st="unk"] .zst { color: var(--muted); }
.zpc.busywork { box-shadow: inset 0 0 0 2px var(--acc); }
.zpc.busywork::after { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, transparent 35%,
  color-mix(in srgb, var(--acc) 26%, transparent) 50%, transparent 65%); background-size: 260% 100%;
  animation: shimmer 1.1s linear infinite; pointer-events: none; }
/* holat o'zgarganda — yumshoq "puls" (reduced-motion'da o'chadi) */
.zpc.chg { animation: zpop .55s cubic-bezier(.3,1.25,.5,1); }
@keyframes zpop { 0% { transform: scale(.9); } 55% { transform: scale(1.05); } }
.zmap.in .zpc { animation: zIn .34s cubic-bezier(.2,.75,.2,1) backwards; animation-delay: calc(var(--i, 0) * 11ms); }
@keyframes zIn { from { opacity: 0; transform: translateY(8px) scale(.94); } }

/* Kompyuter oynasi (pastdan chiqadi) */
.zhead { display: flex; align-items: center; gap: 12px; margin: 0 0 12px; }
.zhead .big { width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; flex: none;
              font-size: 24px; font-weight: 800; font-variant-numeric: tabular-nums;
              background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--ring-2); }
.zhead[data-st="bosh"] .big { background: var(--good-bg); color: var(--good-ink); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--good) 45%, transparent); }
.zhead[data-st="band"] .big { background: var(--warn-bg); color: var(--ink); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--warn) 60%, transparent); }
.zhead[data-st="unk"] .big { border: 1px dashed var(--axis); box-shadow: none; color: var(--muted); }
.zhead .hx { min-width: 0; display: grid; gap: 3px; }
.zhead .hx b { font-size: 16px; }
.zhead .hx .r { font-size: 13px; color: var(--muted); }
.zmini { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 2px; }

/* Buyruq oqimi: yuborildi → kutilmoqda → natija */
.zsteps { display: flex; gap: 8px; margin: 2px 0 14px; }
.zstep { flex: 1 1 0; display: grid; gap: 5px; justify-items: center; font-size: 11.5px; color: var(--muted); text-align: center; }
.zstep .b { height: 5px; width: 100%; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.zstep.done { color: var(--ink-2); font-weight: 600; }
.zstep.done .b { background: var(--acc); }
.zstep.on { color: var(--acc-ink); font-weight: 700; }
.zstep.on .b i { display: block; height: 100%; width: 45%; border-radius: 999px; background: var(--acc); animation: zslide 1.2s ease-in-out infinite; }
@keyframes zslide { 0% { transform: translateX(-100%); } 100% { transform: translateX(230%); } }
.zres { display: grid; margin-top: 4px; }
@media (min-width: 641px) { .zres { max-height: 46vh; overflow-y: auto; overscroll-behavior: contain; } }
.zrow { display: grid; grid-template-columns: 58px minmax(0, 1fr) auto; gap: 10px; align-items: center;
        padding: 9px 2px; border-bottom: 1px solid var(--grid); }
.zrow .nn { white-space: nowrap; }
.zrow:last-child { border-bottom: 0; }
.zrow .nn { font-weight: 750; font-size: 15px; font-variant-numeric: tabular-nums; }
.zrow .tx { font-size: 13px; color: var(--ink-2); overflow-wrap: anywhere; }
.zrow .ic { display: grid; place-items: center; color: var(--muted); }
.zrow.ok .ic { color: var(--good-ink); }
.zrow.fail .ic { color: var(--crit-ink); }
.zrow.fail .tx { color: var(--crit-ink); }
.zrow.wait .ic { animation: pulse2 1.4s ease-in-out infinite; }
@keyframes pulse2 { 50% { opacity: .35; } }
.zsum { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 2px; }
.zjob-chip { display: inline-flex; align-items: center; gap: 8px; min-height: 32px; padding: 0 12px; border-radius: 999px;
             background: var(--acc-bg); color: var(--acc-ink); border: 0; font-size: 13px; font-weight: 650; cursor: pointer; }
.zjob-chip .sp { width: 13px; height: 13px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent;
                 animation: spin .8s linear infinite; flex: none; }

/* Tariflar */
.ztar { display: grid; gap: 10px; }
.ztrow { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; padding: 11px 0; border-bottom: 1px solid var(--grid); }
.ztrow:last-child { border-bottom: 0; }
.ztrow .tn { font-weight: 650; overflow-wrap: anywhere; }
.ztrow .tg { font-size: 12px; color: var(--muted); }
.ztrow .tp { text-align: right; display: grid; gap: 2px; font-variant-numeric: tabular-nums; }
.ztrow .tp b { font-size: 15px; white-space: nowrap; }
.ztrow .tp span { font-size: 12px; color: var(--muted); white-space: nowrap; }

/* ===== PASTDAN CHIQADIGAN OYNA (mobil) ===== */
@media (max-width: 640px) {
  dialog.dlg.sheet { width: 100%; max-width: 100%; max-height: 92dvh; margin: auto auto 0; }
  .dlg.sheet .dlg-in { border-radius: 22px 22px 0 0; max-height: 92dvh; padding-bottom: env(safe-area-inset-bottom); }
  dialog.dlg.sheet[open] .dlg-in { animation: sheetIn .28s cubic-bezier(.2,.85,.25,1); }
  .dlg.sheet .dlg-h { padding-top: 12px; }
  .dlg.sheet .dlg-h::before { content: ""; display: block; width: 38px; height: 4px; border-radius: 999px;
                              background: var(--ring-2); margin: 0 auto 12px; }
}
@keyframes sheetIn { from { transform: translateY(100%); } }
.zpc .zst span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.zpc[data-st="unk"] .zst { font-size: 9.5px; letter-spacing: -.01em; }
/* "Noma'lum" uzun so'z — kichik plitkaga sig'sin: punktir hoshiya belgi vazifasini bajaradi */
.zpc[data-st="unk"] .zst .d { display: none; }
.zpc[data-st="off"] .zst .d { background: var(--axis); }
/* Kompyuter oynasidagi uchta amal: Yoqish · Qayta yuklash · O'chirish */
.zacts3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 14px 0 2px; }
.zacts3 .btn { flex-direction: column; gap: 3px; min-height: 62px; padding: 8px 4px; font-size: 12.5px;
               white-space: normal; line-height: 1.15; text-align: center; }

/* ===== SEANS (bizning tizim): o'rin xaritasi holatlari, seans oynasi, sozlama — zal.js ===== */
/* Ko'k "GameClass" yorlig'i (barcha mavzularda solid chip — o'z bg+text) */
.zgc { background: #2f6fed; color: #fff; border-color: transparent; }
.zpc .gcm { position: absolute; top: 3px; left: 4px; font-size: 8.5px; font-weight: 800; letter-spacing: .02em;
            background: #2f6fed; color: #fff; border-radius: 5px; padding: 0 3px; line-height: 1.5; }
.zpc[data-st="unk"] .gcm, .zpc[data-st="off"] .gcm { opacity: .8; }

/* Bizning seans (band) = amber, kuchli hoshiya; qolgan vaqt jonli */
.zpc[data-st="oseans"] { background: var(--warn-bg); border-color: var(--warn); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--warn) 55%, transparent); }
.zpc[data-st="oseans"] .zst, .zpc[data-st="oseans"] .ztm { color: var(--ink); }
.zpc[data-st="oseans"] .zst .d { background: var(--warn); }
.zpc[data-st="oseans"] .zbar i { background: var(--warn); }
/* Bo'sh + ulangan = yashil (bizniki, o'yinga tayyor) */
.zpc[data-st="ofree"] { background: var(--good-bg); border-color: var(--good); }
.zpc[data-st="ofree"] .zst { color: var(--good-ink); }
.zpc[data-st="ofree"] .zst .d { background: var(--good); }
/* Ulangan, o'chiq/qulf = kulrang */
.zpc[data-st="ooff"] { background: var(--surface-2); border-color: var(--ring-2); }
.zpc[data-st="ooff"] .n { color: var(--ink-2); }
.zpc[data-st="ooff"] .zst { color: var(--muted); }
.zpc[data-st="ooff"] .zst .d { background: var(--axis); }
/* VIP = oltin ring */
.zpc.isvip { box-shadow: inset 0 0 0 1.6px var(--ega-solid); }
.zpc[data-st="oseans"].isvip { box-shadow: inset 0 0 0 1.6px var(--ega-solid), inset 0 0 0 2.4px color-mix(in srgb, var(--warn) 40%, transparent); }
/* Kam qolgan vaqt (≤5 daq) — plitka ogohlantiradi */
.zpc.warn { border-color: var(--crit); }
.zpc.warn .ztm { color: var(--crit-ink); font-weight: 800; }
.zpc.warn:not(.busywork) { animation: zwarn 1.6s ease-in-out infinite; }
@keyframes zwarn { 0%, 100% { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--crit) 55%, transparent); }
                   50% { box-shadow: inset 0 0 0 2px var(--crit), 0 0 0 3px color-mix(in srgb, var(--crit) 22%, transparent); } }
@media (prefers-reduced-motion: reduce) { .zpc.warn:not(.busywork) { animation: none; box-shadow: inset 0 0 0 2px var(--crit); } }

/* Legenda: yangi holatlar */
.zleg .li.oseans .d { background: var(--warn); }
.zleg .li.ofree .d { background: var(--good); }

/* Seans oynasi (sheet) sarlavha ranglari */
.zhead[data-st="oseans"] .big { background: var(--warn-bg); color: var(--ink); box-shadow: inset 0 0 0 1px var(--warn); }
.zhead[data-st="ofree"] .big { background: var(--good-bg); color: var(--good-ink); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--good) 55%, transparent); }
.zhead[data-st="ooff"] .big { background: var(--surface-2); color: var(--ink-2); box-shadow: inset 0 0 0 1px var(--ring-2); }
/* Jonli qolgan vaqt (sheet) */
.zlive { font-variant-numeric: tabular-nums; font-size: 16px; font-weight: 800; letter-spacing: .01em; }
.zlive.warn { color: var(--crit-ink); }
/* Seans amallari (Ochish / Vaqt qo'shish / Yakunlash) */
.zseans-acts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 14px 0 2px; }
.zseans-acts .btn { min-height: 48px; }
.zseans-acts .btn.big { grid-column: 1 / -1; }
.zacts3.sub { margin-top: 8px; }
.zacts3.sub .btn { min-height: 48px; font-size: 12px; }
.zacts3.sub .btn svg { width: 18px; height: 18px; }
/* Paket ma'lumoti (seans ochish oynasi) */
.zpk { font-weight: 650; font-variant-numeric: tabular-nums; }
.zsum-note { color: var(--acc-ink); }

/* ===== SEANS SOZLAMASI: kompyuterlarni ulash to'ri ===== */
.zpc-cfg { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.zpc-cfg-i { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 12px; cursor: pointer;
             background: var(--surface-2); border: 1px solid var(--ring-2); min-height: 46px; }
.zpc-cfg-i.on { background: var(--good-bg); border-color: color-mix(in srgb, var(--good) 45%, transparent); }
.zpc-cfg-i .zc-main { flex: 1; min-width: 0; display: grid; gap: 1px; }
.zpc-cfg-i .zc-n { display: inline-flex; align-items: center; gap: 3px; font-weight: 800; font-size: 15px;
                   font-variant-numeric: tabular-nums; }
.zpc-cfg-i .zc-n .v { color: var(--ega-solid); display: inline-grid; place-items: center; }
.zpc-cfg-i .zc-r { min-width: 0; font-size: 11px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.zpc-cfg-i input { margin-left: auto; flex: none; }
@media (max-width: 640px) { .zpc-cfg { grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); } }

/* ===== TELEFON UCHUN UMUMIY TUZATISHLAR (2026-09-15) =====
   Muammo: ba'zi bo'limlarda qator ekrandan kengroq bo'lib, sahifa yonga suriladi va
   yozuvlar kesilib qolardi (pastki panel ham sahifa kengligiga cho'zilib ketardi). */
@media (max-width: 640px) {
  /* Gorizontal aylanish bo'lmasin. `clip` — `hidden` dan farqli, sticky sarlavhani buzmaydi. */
  body { overflow-x: clip; }
  /* Pastki panel har doim EKRAN kengligida (sahifa kengayib ketsa ham cho'zilmasin) */
  .tabbar { width: 100vw; max-width: 100vw; }
  .tabbar a { overflow: hidden; }       /* yozuv paneldan kengaytirmasin */
  .tabbar.many a span.lb { font-size: 9px; letter-spacing: -.03em; }
  /* Karta sarlavhasi + yonidagi boshqaruv: joy yetmasa pastga tushadi (sarlavha siqilib qolmasin) */
  .card-h { flex-wrap: wrap; }
  .card-h > .grow { flex: 1 1 190px; }
  /* Ro'yxat qatoridagi keng maydon (masalan chat ID) — pastga, butun kenglikda */
  .item .side.wide { grid-column: 1 / -1; min-width: 0; justify-items: stretch; text-align: left; }
  .item .side.wide .inp { width: 100%; }
  /* Uzun jadval — karta ichida yonga suriladi (sahifani emas) */
  .card .tblw, .card .tbl-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  /* Ichki tab qatori (Kirim/Suratdan/Inventarizatsiya…) — sig'masa o'zi yonga suriladi */
  .seg.wrap-seg { overflow-x: auto; scrollbar-width: none; }
  .seg.wrap-seg::-webkit-scrollbar { display: none; }
  .seg.wrap-seg > * { flex: 1 0 auto; min-width: 84px; padding-left: 10px; padding-right: 10px; }
}
@media (max-width: 560px) {
  /* Zal amallari: uch tugma bir qatorga sig'masa — pastki qatorga o'tadi */
  .zacts { min-width: 0; flex-wrap: wrap; }
  .zacts .btn { flex: 1 1 auto; }
}
@media (max-width: 380px) {
  .wrap { padding-left: 10px; padding-right: 10px; }
  .card { padding-left: 12px; padding-right: 12px; }
  .tabbar.many a .pill { width: 38px; }
}

/* ===== EGA KASSASI: hammasini qabul qilish (kassa.js viewOwnerAccept) ===== */
.ega-cta { display: grid; gap: 6px; padding: 12px 0 2px; border-top: 1px solid var(--grid); margin-top: 10px; }
/* Matn dinamik (smenalar soni + summa) — uzun bo'lsa qatorga sig'masdan chetga chiqib ketardi
   (flex elementning standart min-width:auto o'ramni to'sib qo'yadi). */
.ega-cta .btn.big { width: 100%; white-space: normal; height: auto; padding: 12px 16px; line-height: 1.3; text-align: left; }
.ega-cta .btn.big span { min-width: 0; white-space: normal; }
.ega-cta .meta-t { margin: 0; }
.ega-list { display: grid; gap: 12px; }
.ega-shift .card-h .t { color: inherit; text-decoration: none; }
.ega-shift .kv dt { white-space: pre; }            /* "  · GameClass" kabi ichki qatorlar */
/* ochiladigan rasxod/qarz ro'yxati — sahifa uzayib ketmasin */
.ega-det { border-top: 1px solid var(--grid); margin-top: 10px; }
.ega-det > summary { display: flex; justify-content: space-between; align-items: baseline; gap: 12px;
                     padding: 10px 0; cursor: pointer; font-size: 14px; color: var(--ink-2); }
.ega-det > summary::-webkit-details-marker { display: none; }
.ega-det > summary::after { content: '▾'; color: var(--muted); margin-left: 4px; }
.ega-det[open] > summary::after { content: '▴'; }
.ega-det > summary b { font-variant-numeric: tabular-nums; color: var(--ink); }
.ega-pay { margin-top: 14px; }
.ega-pay .btn.big { width: 100%; margin-top: 4px; }
.ega-sum { margin-top: 12px; }
.ega-sum .lrow.head { padding: 14px 0 4px; border-bottom: 0; }
.ega-sum .lrow.head .n { font-size: 12px; font-weight: 700; letter-spacing: .06em;
                         text-transform: uppercase; color: var(--muted); }
.ega-sum .lrow.head + .lrow { border-top: 1px solid var(--grid); }
/* jami qatorini bosib ochiladigan ro'yxat (Click to'lovlari, rasxodlar, qarzlar) */
.ega-lines { max-height: min(50vh, 420px); overflow-y: auto; -webkit-overflow-scrolling: touch; }
.lrow.pick { width: 100%; text-align: left; background: none; border: 0; font: inherit; color: inherit;
             cursor: pointer; border-bottom: 1px solid var(--grid); transition: background .15s; }
.lrow.pick:hover { background: var(--surface-2); }
.lrow.pick .n .pk { color: var(--muted); margin-left: 6px; font-weight: 700; }
