/* Ofisbop — Hujjat muharriri uslublari. Copyright (c) 2026 "VIJDON" MChJ. Barcha huquqlar himoyalangan. */
.doc-area { flex: 1; overflow: auto; background: var(--bg); padding: 24px 0 60px; position: relative; }
.page-wrap { position: relative; margin: 0 auto; width: max-content; }
.page {
  --pw: 794px; --ph: 1123px; --mt: 96px; --mr: 96px; --mb: 96px; --ml: 96px;
  width: var(--pw); min-height: var(--ph); background: #fff; box-shadow: 0 1px 4px rgba(0, 0, 0, .18);
  padding: var(--mt) var(--mr) var(--mb) var(--ml); outline: none; position: relative;
  font-family: "Times New Roman", Times, serif; font-size: 12pt; line-height: 1.15; color: #000;
  word-wrap: break-word; overflow-wrap: break-word;
}
.page p, .page div:not(.page-break) { margin: 0 0 8pt; }
.page h1 { font-size: 20pt; margin: 12pt 0 6pt; font-weight: bold; color: #1f3864; }
.page h2 { font-size: 16pt; margin: 10pt 0 4pt; font-weight: bold; color: #2f5496; }
.page h3 { font-size: 13pt; margin: 8pt 0 4pt; font-weight: bold; color: #1f3763; }
.page h4 { font-size: 12pt; margin: 6pt 0 2pt; font-weight: bold; font-style: italic; }
.page h5 { font-size: 11pt; margin: 6pt 0 2pt; font-weight: bold; color: #2f5496; }
.page h6 { font-size: 11pt; margin: 6pt 0 2pt; font-weight: bold; font-style: italic; color: #1f3763; }
.page .title { font-size: 28pt; font-weight: normal; margin: 0 0 8pt; color: #000; }
.page blockquote { margin: 6pt 36pt; padding-left: 10pt; border-left: 3px solid #bfc6d1; color: #404040; font-style: italic; }
.page ul, .page ol { margin: 0 0 8pt; padding-left: 28pt; }
.page li { margin: 0 0 2pt; }
/* Koʻp darajali raqamlash: 1. / 1.1. / 1.1.1. (raqam — osilgan chekinishda, matn bir chiziqda) */
.page ol.ml { list-style: none; counter-reset: ml; padding-left: 0; --mlw: 1.8em; }
.page ol.ml ol.ml { padding-left: 1.2em; --mlw: 2.6em; }
.page ol.ml ol.ml ol.ml { --mlw: 3.3em; }
.page ol.ml ol.ml ol.ml ol.ml { --mlw: 4em; }
.page ol.ml > li { counter-increment: ml; padding-left: var(--mlw); text-indent: calc(-1 * var(--mlw)); }
.page ol.ml > li > * { text-indent: 0; }
.page ol.ml > li::before { content: counters(ml, ".") "."; display: inline-block; min-width: var(--mlw); text-indent: 0; }
/* Izohlar: belgi raqami — hisoblagich (sahifa ostidagi 1, 2, 3; hujjat oxiridagi i, ii, iii) */
.page { counter-reset: fn en; }
.page .fn-ref, .page .en-ref { counter-increment: fn; cursor: pointer; padding: 0 1px; color: inherit; font-size: .7em; vertical-align: super; line-height: 0; }
.page .en-ref { counter-increment: en; }
.page .fn-ref::after { content: counter(fn); }
.page .en-ref::after { content: counter(en, lower-roman); }
.page .fn-ref:hover, .page .en-ref:hover { background: var(--accent-soft); }
.page .notes { margin-top: 18pt; padding-top: 4pt; position: relative; font-size: 10pt; counter-reset: fnb enb; cursor: default; }
.page .notes::before { content: ""; display: block; width: 33%; border-top: 1px solid #000; margin-bottom: 4pt; }
.page .notes::after { content: var(--fn-label); position: absolute; right: 0; top: -14px; font: 10px "Segoe UI", sans-serif; color: #8a929c; }
.page .en-area::after { content: var(--en-label); }
.page .fn-body, .page .en-body { counter-increment: fnb; outline: none; cursor: text; border-radius: 2px; }
.page .en-body { counter-increment: enb; }
.page .fn-body:focus-within, .page .en-body:focus-within { background: rgba(79, 70, 229, .04); }
.page .fn-body > :first-child::before { content: counter(fnb) " "; font-size: .7em; vertical-align: super; line-height: 0; }
.page .en-body > :first-child::before { content: counter(enb, lower-roman) " "; font-size: .7em; vertical-align: super; line-height: 0; }
.page .fn-body p, .page .en-body p { margin: 0 0 2pt; }
/* Mundarija (sarlavhalardan; matni "yangilash" bilan quriladi) */
.page .toc { margin: 0 0 12pt; position: relative; cursor: default; border-radius: 2px; }
.page .toc:hover { outline: 1px dashed #c8cdd4; outline-offset: 4px; }
.page .toc p { display: flex; align-items: baseline; margin: 0 0 4pt; }
.page .toc .toc-title { display: block; font-size: 16pt; font-weight: bold; color: #1f3864; margin: 0 0 8pt; }
.page .toc .toc-empty { display: block; color: #8a929c; font-style: italic; }
.page .toc p[data-bm] { cursor: pointer; }
.page .toc p[data-bm]:hover .toc-t { text-decoration: underline; }
.page .toc p[data-bm]::after { content: ""; flex: 1 1 auto; order: 1; margin: 0 4px; border-bottom: 1.5px dotted currentColor; transform: translateY(-.25em); min-width: 12px; }
.page .toc .toc-n { order: 2; flex: none; }
.page .toc .toc-2 { padding-left: 1.5em; } .page .toc .toc-3 { padding-left: 3em; } .page .toc .toc-4 { padding-left: 4.5em; }
.page .toc .toc-5 { padding-left: 6em; } .page .toc .toc-6 { padding-left: 7.5em; }
/* Rasm/jadval nomi; avtomatik raqam va maydonlar */
.page .caption { margin: 4pt 0 10pt; }
.page .seq, .page .fld { border-radius: 2px; }
.page .seq:hover, .page .fld:hover { background: #e8ebf0; }
/* Tuzatishlar va sharhlar */
.page ins { color: #13703a; text-decoration: underline; text-decoration-color: #13703a; }
.page del { color: #b3261e; text-decoration: line-through; }
.page span.cmt { background: #fff1bf; border-bottom: 1.5px solid #e8b931; }
.page .cmt-store { display: none !important; }
::highlight(cmt-on) { background-color: #ffd54f; }
/* Jadval ustuni kengligini sudrab oʻzgartirish */
.page.col-resize, .page.col-resize td, .page.col-resize th { cursor: col-resize !important; }
/* Ommaviy xat maydoni */
.page .mf { background: #e6efff; color: #1d4ed8; border-radius: 2px; padding: 0 1px; }
/* Sahifalash (Paragraf oynasi): keyingisi bilan birga, qatorlarni ajratmaslik, yangi sahifadan */
.page .kwn { break-after: avoid; }
.page .kl { break-inside: avoid; }
.page .pbb { break-before: page; }
.page table { border-collapse: collapse; width: 100%; margin: 0 0 8pt; }
.page td, .page th { border: 1px solid #000; padding: 3pt 6pt; vertical-align: top; min-width: 20px; }
.page table.nb td, .page table.nb th { border: 1px dotted #c8cdd4; }
.page td > p:last-child, .page th > p:last-child { margin-bottom: 0; }
.page img { max-width: 100%; height: auto; max-height: var(--ch, none); object-fit: contain; } /* rasm sahifadan baland boʻlmasin (Word ham kichraytiradi) */
.page img.selected { outline: 2px solid var(--accent); }
.page img[style*="float"] { max-width: 60%; }
.page hr { border: 0; border-top: 1px solid #000; margin: 6pt 0; }
/* Word'dan kelgan elementlar */
.page .tab { display: inline-block; min-width: 2px; }
.page .tab.dot { background: radial-gradient(circle, currentColor 0.7px, transparent 1px) 0 calc(100% - 0.18em) / 4px 4px repeat-x; }
.page .tab.ul, .page .tab.line { border-bottom: 1px solid currentColor; }
.page .txbx { border: 1px dotted #c8cdd4; padding: 4pt 6pt; margin: 6pt 0; }
.page ul, .page ol { margin-top: 0; margin-bottom: 0; }
.page img { max-width: 100%; }

.page a { color: #0563c1; text-decoration: underline; }
.page .page-break {
  height: 0; border-top: 1px dashed #9aa3af; margin: 18px 0; position: relative; user-select: none; page-break-after: always; break-after: page;
}
.page .page-break::after {
  content: var(--pb-label, "Sahifa uzilishi"); position: absolute; left: 50%; top: -8px; transform: translateX(-50%);
  background: #fff; color: #8a929c; font: 10px "Segoe UI", sans-serif; padding: 0 6px;
}
.hf-note { position: absolute; left: 0; right: 0; z-index: 3; color: #000; opacity: .55; font-size: 10pt; line-height: 1.2; cursor: default; overflow: hidden; max-height: 64px; border: 1px dashed transparent; border-radius: 2px; }
.hf-note:hover { opacity: .8; border-color: #c8cdd4; }
.hf-note p { margin: 0; }
.hf-note:not(.hf-bottom) { top: 0; }
.hf-note.hf-bottom { bottom: 0; }
/* Kolontitul tahrirlash oynasi */
.hf-dlg { min-width: 520px; max-width: 640px; }
.hf-bar { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; margin-bottom: 8px; }
.hf-bar .btn { width: 30px; height: 28px; padding: 0; }
.hf-bar .pbtn { padding: 4px 8px; font-size: 12px; }
.hf-sec { margin-bottom: 8px; }
.hf-lbl { font-size: 12px; color: var(--muted); margin-bottom: 2px; }
.hf-ed { border: 1px solid var(--border); border-radius: 4px; padding: 6px 8px; min-height: 34px; background: #fff; color: #000; font-size: 11pt; outline: none; }
.hf-ed:focus { border-color: var(--accent); }
.hf-ed p { margin: 0; }
.hf-ed .fld, .hf-note .fld { background: #e8ebf0; border-radius: 2px; padding: 0 2px; }
.hf-warn { color: #a15c00; margin-bottom: 8px; }
@media (max-width: 600px) { .hf-dlg { min-width: 0; } }
.page-marks { position: absolute; inset: 0; pointer-events: none; z-index: 2; }
.page-marks .pm { position: absolute; left: -30px; right: -30px; border-top: 1px dashed #b3bac4; }
.page-marks .pm span { position: absolute; right: 0; top: 2px; font-size: 10px; color: #8a929c; }
.page-marks.off { display: none; }

.styles-gallery { gap: 4px !important; align-items: stretch !important; }
.style-item {
  width: 88px; height: 58px; border: 1px solid var(--border); background: #fff; border-radius: 4px; cursor: pointer;
  display: flex; flex-direction: column; justify-content: space-between; padding: 5px 7px; overflow: hidden; text-align: left;
}
.style-item:hover { border-color: var(--accent); background: var(--accent-soft); }
.style-item.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.style-item .sp { white-space: nowrap; overflow: hidden; }
.style-item .sn { font-size: 10px; color: var(--muted); font-family: "Segoe UI", sans-serif; }
.style-more { width: 22px; border: 1px solid var(--border); background: #fff; border-radius: 4px; cursor: pointer; display: flex; align-items: center; justify-content: center; padding: 0; color: var(--muted); }
.style-more:hover { border-color: var(--accent); background: var(--accent-soft); }
.style-more svg { width: 14px; height: 14px; }
.menu .mi .st-prev { font-family: "Times New Roman", serif; }

.findbar {
  position: fixed; top: 168px; right: 24px; z-index: 800; background: #fff; border: 1px solid var(--border);
  border-radius: 8px; box-shadow: var(--shadow); padding: 10px; display: flex; flex-direction: column; gap: 6px; width: 380px;
}
.findbar .grow { display: flex; gap: 4px; align-items: center; }
.findbar .inp { flex: 1; height: 28px; }
.findbar .fcount { color: var(--muted); font-size: 12px; min-width: 50px; text-align: right; }
.findbar .fopt { font-size: 12px; color: var(--muted); display: flex; gap: 6px; align-items: center; }
.findbar .fopts { display: flex; flex-wrap: wrap; gap: 2px 14px; }
.findbar .pbtn { padding: 4px 10px; }

.img-tools {
  position: absolute; z-index: 700; background: #fff; border: 1px solid var(--border); border-radius: 6px;
  box-shadow: var(--shadow); padding: 3px; display: flex; gap: 2px; align-items: center;
}
.img-tools .sep { width: 1px; height: 20px; background: var(--border); margin: 0 3px; }
.img-tools .btn.on { background: var(--accent-soft); color: var(--accent-dark); }
.img-handle { position: absolute; z-index: 701; width: 11px; height: 11px; background: #fff; border: 2px solid var(--accent); border-radius: 2px; cursor: nwse-resize; }
.img-handle.hidden { display: none; }

.tgrid { display: grid; grid-template-columns: repeat(10, 16px); gap: 2px; padding: 6px; }
.tgrid span { width: 16px; height: 16px; border: 1px solid #c3c9d2; background: #fff; }
.tgrid span.on { background: var(--accent-soft); border-color: var(--accent); }
.tgrid-label { text-align: center; padding: 2px 0 6px; color: var(--muted); font-size: 12px; }
.sym-grid { display: grid; grid-template-columns: repeat(10, 28px); gap: 2px; padding: 6px; }
.sym-grid span { width: 28px; height: 28px; display: flex; align-items: center; justify-content: center; border-radius: 3px; cursor: pointer; font-size: 16px; }
.sym-grid span:hover { background: var(--accent-soft); }

::highlight(matn-err) { text-decoration: underline wavy #e02424; text-decoration-skip-ink: none; text-underline-offset: 3px; }
.st-spell { cursor: pointer; }
.st-spell.bad { color: #c0392b; }
.st-spell.ok { color: #0f766e; }
.spell-sug { font-weight: 600; }

@media print {
  .doc-area { overflow: visible; padding: 0; background: #fff; }
  .page-wrap { width: auto; zoom: 1 !important; } /* ekrandagi masshtab (telefonda 43%...) qogʻozga oʻtmasin */
  .page { box-shadow: none; padding: 0 !important; width: auto !important; min-height: 0 !important; zoom: 1 !important; }
  .page-marks, .findbar, .img-tools, .hf-note { display: none !important; }
  .page .page-break { border: 0; margin: 0; }
  .page .page-break::after { display: none; }
  .page img.selected { outline: none; }
  .img-handle { display: none !important; }
  .page table.nb td, .page table.nb th { border: 0; }
  .page .txbx { border: 0; }
  .page .toc:hover { outline: none; }
  .page span.cmt { background: none; border: 0; }
  .page .mf { background: none; color: inherit; }
  .cmt-pane { display: none !important; }
  .nav-pane { display: none !important; }
  .page .notes::after { display: none; }
  .page .fn-ref:hover, .page .en-ref:hover { background: none; }
  ::highlight(matn-err) { text-decoration: none; }
  .page, .page * { -webkit-print-color-adjust: exact; print-color-adjust: exact; } /* jadval fonlari telefonda ham chiqsin */
}

/* Chop etish varaqlari (doc-print.js, doc.js → printPrepare): ekrandan tashqarida yigʻiladi va oʻlchanadi; chop etishda faqat ular.
   Har .pr-sheet — bitta qogʻoz (@page hoshiyasi 0), ichida matn maydoni (.pr-body) aynan ekrandagi sahifa qismi bilan. */
#docPrint { position: absolute; left: -100000px; top: 0; visibility: hidden; pointer-events: none; counter-reset: fn en; }
/* contain: varaq bitta yaxlit sahifa — brauzer ichini (masalan, yashirin qatorli jadvalni) yana boʻlishga urinmaydi; style emas — izoh raqamlari varaqlar boʻylab davom etsin */
.pr-sheet { position: relative; overflow: hidden; background: #fff; break-after: page; break-inside: avoid; contain: size layout paint; }
.pr-sheet:last-child { break-after: auto; }
.pr-body.page { position: absolute; width: var(--prw) !important; min-height: 0 !important; padding: 0 !important; box-shadow: none; counter-reset: none; display: flow-root; outline: none; zoom: 1 !important; }
.pr-body .page-break { page-break-after: auto !important; break-after: auto !important; }
.pr-body .page-break::after { display: none; }
.pr-body .pbb, .pr-body .kwn, .pr-body .kl { break-before: auto; break-after: auto; break-inside: auto; }
.pr-body tr.pr-hide { visibility: collapse; }
.pr-body .pr-cont { margin-top: 0 !important; padding-top: 0 !important; border-top-width: 0 !important; }
.pr-body .pr-first { margin-top: 0 !important; }
.pr-body li.pr-cont { list-style-type: none; }
.pr-body li.pr-cont::marker { content: none; }
.pr-body ol.ml > li.pr-cont { text-indent: 0; }
.pr-body ol.ml > li.pr-cont::before { content: none; }
.pr-body .fn-body.pr-cont > :first-child::before, .pr-body .en-body.pr-cont > :first-child::before { content: none; }
.pr-hf { position: absolute; z-index: 1; color: #000; font-size: 10pt; line-height: 1.2; overflow: hidden; max-height: 64px; }
.pr-hf p { margin: 0; }
@media print {
  html.pr-on body { display: block !important; }
  html.pr-on body > :not(#docPrint) { display: none !important; }
  html.pr-on #docPrint { position: static; visibility: visible; }
}

/* Telefonda ikki koʻrinish (doc-mobile.js):
   - "Sahifa" (sukut boʻyicha): varaq Word fayldagi kabi, ekran kengligida; ikki barmoq bilan 25–400%;
   - "Telefon" (<html class="m-reflow">): varaq ekran kengligiga oqib turadi, masshtab matn oʻlchamini oʻzgartiradi.
   Faylga eksport har doim sahifa sozlamasi (A4...) bilan. */
@media screen and (max-width: 760px), screen and (max-height: 500px) and (pointer: coarse) {
  .doc-area { padding: 8px 0 40px; }
  .img-tools .sep { display: none !important; }
  .page-marks .pm { left: 0; right: 0; } /* varaqdan chiqib, ekranni yon tomonga surilmaydigan qilmasin */
  .m-reflow .doc-area { padding: 6px 0 40px; }
  .m-reflow .page-wrap { width: 100% !important; zoom: 1 !important; }
  .m-reflow .page { width: auto !important; min-height: calc(100vh - 230px) !important; padding: 18px 14px !important; margin: 0 6px; box-shadow: 0 1px 3px rgba(0,0,0,.15); }
  .m-reflow .page table { width: 100% !important; }
  .m-reflow .page-marks, .m-reflow .hf-note { display: none !important; }
}
/* Sensorli ekran: brauzerning oʻz masshtabi emas — ikki barmoq harakatini dastur oʻzi bajaradi (touch.js) */
.t-coarse .doc-area { touch-action: pan-x pan-y; }

/* ---------- Telefon: masshtab va sahifa tugmasi, oʻqish rejimi, tanlov paneli (doc-mobile.js) ---------- */
.dm-chip, .dm-sel { display: none; }
.m-ui .dm-chip {
  display: flex; align-items: center; gap: 6px; position: fixed; right: 10px; z-index: 40; height: 36px; padding: 0 12px;
  border: 0; border-radius: 18px; background: rgba(32, 38, 48, .82); color: #fff; font: 600 13px/1 "Segoe UI", Roboto, sans-serif;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .2); transition: opacity .2s; -webkit-tap-highlight-color: transparent;
}
.m-ui .dm-chip::before { content: ""; position: absolute; inset: -6px -4px; } /* barmoq uchun kattaroq joy (48 dp) */
.m-ui .dm-chip i { width: 1px; height: 14px; background: rgba(255, 255, 255, .35); }
.m-ui .dm-chip:active { background: rgba(32, 38, 48, .95); }
.m-ui.m-kb .dm-chip, .m-ui body:has(> .menu, > .modal-back, > .m-tip) :is(.dm-chip, .dm-sel) { display: none; }
/* Koʻrish rejimi (mobile.js m-view → doc-mobile.js dm-read): matn tasodifan oʻzgarmaydi; ✎ tugmasi — mobile.css .m-edit-fab */
.dm-read .page { caret-color: transparent; }
.dm-read .page [contenteditable] { -webkit-user-modify: read-only; } /* izoh matnlari — alohida tahrirlanadigan joylar */
.m-ui .m-bar .m-ib.on { color: var(--accent-dark); background: var(--accent-soft); }
/* Belgilangan matn ustidagi kichik panel */
.m-ui .dm-sel {
  display: flex; position: fixed; z-index: 45; left: 8px; padding: 3px; gap: 1px; background: #fff; border-radius: 14px;
  box-shadow: 0 4px 18px rgba(15, 23, 42, .25), 0 0 0 1px rgba(15, 23, 42, .06); animation: m-fade .12s;
}
.m-ui .dm-sel.hidden { display: none; }
.m-ui .dm-sel button {
  flex: none; width: 46px; height: 46px; border: 0; border-radius: 11px; background: none; color: var(--text); padding: 0;
  display: inline-flex; align-items: center; justify-content: center; font: 20px/1 Georgia, "Times New Roman", serif;
}
.m-ui .dm-sel button svg { width: 22px; height: 22px; }
.m-ui .dm-sel button sup { font-size: 11px; }
.m-ui .dm-sel button:active { background: var(--pressed); }
.m-ui .dm-sel button.on { background: var(--accent-soft); color: var(--accent-dark); }
/* Sharhlar paneli: telefonda pastdan chiqadigan varaq (yuqori qismida hujjat koʻrinib turadi) */
.m-ui .cmt-pane {
  top: auto !important; left: 0; right: 0; bottom: 0; width: auto; height: 58% !important; z-index: 60;
  border: 0; border-radius: 18px 18px 0 0; box-shadow: 0 -8px 30px rgba(0, 0, 0, .22); padding-bottom: env(safe-area-inset-bottom);
  animation: m-up .18s ease-out;
}
.m-ui.m-kb .cmt-pane { height: 72% !important; }
.m-ui .cmt-pane .np-head { font-size: 16px; padding: 4px 4px 4px 18px; }
.m-ui .cmt-pane .np-head .btn { width: 44px; height: 44px; }
.m-ui .cmt-card { padding: 10px 12px; border-radius: 12px; }
.m-ui .cmt-meta { font-size: 13px; }
.m-ui .cmt-text { font-size: 16px; }
.m-ui .cmt-btn { min-height: 40px; padding: 6px 14px; font-size: 14px; border-radius: 10px; }
.m-ui .nav-pane .np-item { padding: 12px 14px; font-size: 15px; }
.m-ui .nav-pane .np-head .btn { width: 44px; height: 44px; }
/* Rasm oʻlchami tutqichi: barmoq uchun kattaroq, atrofida koʻrinmas joy */
.t-coarse .img-handle { width: 22px; height: 22px; margin: -5px 0 0 -5px; border-radius: 50%; touch-action: none; }
.t-coarse .img-handle::after { content: ""; position: absolute; inset: -12px; border-radius: 50%; }
/* Oynalardagi belgilash katakchalari (Kolontitul, Paragraf...): katakcha matn yonida, barmoq uchun kattaroq */
.m-ui .modal .pd-chk { display: flex; align-items: center; gap: 10px; min-height: 44px; font-size: 15px; color: var(--text); }
.m-ui .modal .pd-chk input[type="checkbox"] { flex: none; width: 22px; height: 22px; min-height: 0; margin: 0; }

/* Paragraf sozlamalari oynasi */
.pd { min-width: 380px; }
.pd-h { font-weight: 600; margin: 12px 0 4px; }
.pd-h:first-child { margin-top: 0; }
.pd-row { display: flex; align-items: center; gap: 8px; margin: 4px 0; }
.pd-row > span { width: 180px; color: var(--muted); }
.pd-row .inp { width: 90px; height: 28px; }
.pd-row .sel { width: 150px; }
.pd-chk { display: flex; gap: 6px; align-items: center; margin: 4px 0; }
.pd-note { font-size: 12px; color: var(--muted); margin-bottom: 4px; }
@media (max-width: 520px) { .pd { min-width: 0; } .pd-row > span { width: 130px; } }

/* Navigatsiya paneli (sarlavhalar) — hujjat maydonining chap tomonida */
.nav-pane { position: fixed; left: 0; width: 250px; z-index: 30; background: var(--panel, #fff); border-right: 1px solid var(--border); display: flex; flex-direction: column; }
.nav-pane.hidden { display: none; }
body.nav-open .doc-area { padding-left: 250px; }
.np-head { display: flex; align-items: center; justify-content: space-between; padding: 8px 8px 8px 14px; font-weight: 600; border-bottom: 1px solid var(--border); }
.np-head .btn { width: 26px; height: 26px; padding: 0; }
.np-list { flex: 1; overflow: auto; padding: 6px 0; }
.np-item { padding: 5px 10px; cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 13px; border-left: 3px solid transparent; }
.np-item.np-top { font-weight: 600; }
.np-item:hover { background: var(--accent-soft); }
.np-item.on { border-left-color: var(--accent); background: var(--accent-soft); }
.np-empty { padding: 12px 14px; color: var(--muted); font-size: 12.5px; line-height: 1.5; }
@media (max-width: 760px) { .nav-pane { width: 82vw; box-shadow: var(--shadow); } body.nav-open .doc-area { padding-left: 0; } }

/* Sharhlar paneli — hujjat maydonining oʻng tomonida */
.cmt-pane { position: fixed; right: 0; width: 290px; z-index: 30; background: var(--panel, #fff); border-left: 1px solid var(--border); display: flex; flex-direction: column; }
.cmt-pane.hidden { display: none; }
body.cmt-open .doc-area { padding-right: 290px; }
.cmt-card { margin: 6px 8px; padding: 8px; border: 1px solid var(--border); border-left: 3px solid #e8b931; border-radius: 6px; background: #fff; cursor: pointer; }
.cmt-card.on { box-shadow: 0 0 0 2px var(--accent-soft); border-color: var(--accent); border-left-color: var(--accent); }
.cmt-card.done { opacity: .6; border-left-color: #8bc34a; }
.cmt-card.orphan { border-style: dashed; }
.cmt-entry.reply { margin-top: 6px; padding-left: 10px; border-left: 2px solid var(--border); }
.cmt-meta { display: flex; gap: 6px; align-items: baseline; font-size: 12px; margin-bottom: 3px; }
.cmt-meta span { color: var(--muted); font-size: 11px; }
.cmt-text { width: 100%; border: 1px solid transparent; border-radius: 4px; resize: none; font: 13px/1.35 inherit; font-family: inherit; padding: 3px 4px; background: transparent; color: var(--text); overflow: hidden; box-sizing: border-box; }
.cmt-text:hover { border-color: var(--border); }
.cmt-text:focus { border-color: var(--accent); background: #fff; outline: none; }
.cmt-acts { display: flex; gap: 4px; margin-top: 6px; flex-wrap: wrap; }
.cmt-btn { border: 1px solid var(--border); background: #fff; border-radius: 4px; padding: 2px 8px; font-size: 12px; cursor: pointer; color: var(--text); }
.cmt-btn:hover { border-color: var(--accent); background: var(--accent-soft); }
@media (max-width: 760px) { .cmt-pane { width: 86vw; box-shadow: var(--shadow); } body.cmt-open .doc-area { padding-right: 0; } }

/* Ommaviy xat oynasi */
.mm { min-width: 460px; max-width: 620px; }
.mm-chips { display: flex; flex-wrap: wrap; gap: 4px; }
.mm-nav { display: flex; align-items: center; gap: 8px; margin: 4px 0 6px; }
.mm-preview.page { width: auto !important; min-height: 0 !important; max-height: 260px; overflow: auto; padding: 14px 18px !important; box-shadow: none; border: 1px solid var(--border); zoom: .8; }
@media (max-width: 600px) { .mm { min-width: 0; } }
