/* Til tanlagich (O'zbekcha / Русский / English) — js/i18n.js chizadi. Saytning asl uslubida: shisha fon, olovrang urg'u */
.til-tanla { position: relative; display: inline-flex; flex: none; }
.tt-btn {
  display: inline-flex; align-items: center; gap: 7px; height: 40px; min-height: 40px; padding: 0 10px 0 11px;
  border: 1px solid var(--line); border-radius: 12px; background: var(--well); color: var(--soft);
  font: 700 13px/1 var(--f-ui); letter-spacing: .06em; cursor: pointer; overflow: visible;
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  transition: border-color .2s, color .2s, background .2s, box-shadow .25s var(--ease);
}
.tt-btn:hover:not(:disabled) { background: var(--raise); border-color: var(--edge2); color: var(--head); }
.til-tanla.och .tt-btn { border-color: var(--accent-line); color: var(--head); background: var(--raise); box-shadow: 0 0 0 3px var(--accent-soft); }
.tt-btn:active:not(:disabled) { transform: scale(.97); }
.tt-btn .rip { display: none; }
.tt-ic { width: 17px; height: 17px; color: var(--accent); flex: none; }
.tt-k { min-width: 18px; text-align: left; }
.tt-chev { width: 14px; height: 14px; opacity: .6; transition: transform .25s var(--ease), opacity .2s; }
.til-tanla.och .tt-chev { transform: rotate(180deg); opacity: 1; }
:root[data-til-yuk] .tt-ic { animation: tt-ayl 1s linear infinite; }
@keyframes tt-ayl { to { transform: rotate(360deg); } }

.tt-menu {
  position: absolute; top: calc(100% + 8px); right: 0; z-index: 500; width: 214px; padding: 6px;
  background: var(--panel-solid); border: 1px solid var(--line); border-radius: 16px;
  box-shadow: var(--sh-pop), 0 0 0 1px var(--hair);
  transform-origin: top right; animation: tt-och .18s var(--ease) both;
}
.tt-menu.chap { right: auto; left: 0; transform-origin: top left; }
.tt-menu[hidden] { display: none; }
@keyframes tt-och { from { opacity: 0; transform: translateY(-6px) scale(.97); } }
.tt-h { padding: 8px 10px 6px; font: 600 10.5px/1.2 var(--f-ui); letter-spacing: .12em; text-transform: uppercase; color: var(--faint); }
.tt-menu button {
  display: flex; align-items: center; gap: 11px; width: 100%; min-height: 44px; padding: 7px 10px; margin: 0;
  border: 0; border-radius: 11px; background: none; color: var(--ink);
  font: 500 14.5px/1.2 var(--f-ui); text-align: left; cursor: pointer; overflow: visible;
}
.tt-menu button .rip { display: none; }
.tt-menu button:hover:not(:disabled), .tt-menu button:focus-visible { background: var(--well); color: var(--head); outline: none; }
.tt-kod {
  display: inline-grid; place-items: center; width: 34px; height: 26px; flex: none; border-radius: 8px;
  background: var(--well); border: 1px solid var(--hair); color: var(--muted); font: 700 11px/1 var(--f-ui); letter-spacing: .06em;
}
.tt-nom { flex: 1; min-width: 0; }
.tt-ok { width: 16px; height: 16px; flex: none; color: var(--accent); opacity: 0; transform: scale(.6); transition: opacity .2s, transform .25s var(--ease-spring); }
.tt-menu button[aria-checked="true"] { color: var(--head); font-weight: 650; background: var(--accent-soft); }
.tt-menu button[aria-checked="true"] .tt-kod { background: var(--accent-grad); border-color: transparent; color: var(--accent-ink); }
.tt-menu button[aria-checked="true"] .tt-ok { opacity: 1; transform: none; }

/* Yon menyu: rejim va til — bitta ixcham qator, yozuvlarsiz (rejim tugmasi o'zi ko'rsatadi, tilda qisqa kod: UZ) */
.side-q { display: contents; }
.side-q-l, .side .tgl-lbl { display: none; }
@media (min-width: 861px) {
  .side .side-tools { flex-direction: row; align-items: center; justify-content: space-between; gap: 8px; padding: 7px 8px; border-radius: 14px; }
  .side-tools .til-tanla { margin-left: 0; }
  .side-tools .tt-btn { height: 34px; min-height: 34px; }
}
/* Joylashuv */
.auth-tools { display: inline-flex; align-items: center; gap: 8px; }
.side-tools .til-tanla { margin-left: auto; }
.side-tools .tt-btn { height: 38px; min-height: 38px; }
.sx-til { display: flex; justify-content: flex-end; width: min(100% - 24px, 720px); margin: 10px auto -2px; }
.ld-nav-r { gap: 10px; }
.ld-nav-r .tt-btn { height: 42px; min-height: 42px; }
/* Tanishtiruv menyusi: havola ostida nozik olovrang chiziq */
.ld-links a { position: relative; }
.ld-links a::after {
  content: ""; position: absolute; left: 14px; right: 14px; bottom: 3px; height: 2px; border-radius: 2px;
  background: var(--accent-grad); transform: scaleX(0); transform-origin: center; transition: transform .28s var(--ease);
}
.ld-links a:hover::after, .ld-links a:focus-visible::after { transform: scaleX(1); }
@media (max-width: 760px) {
  .tt-btn, .ld-nav-r .tt-btn { height: 38px; min-height: 38px; padding: 0 9px; gap: 5px; }
  .ld-nav-r .tt-chev { display: none; }
}
.lg-til { float: right; }
/* O'quvchi faqat natijasini ko'radi: "javoblarni ko'rsatish" tanlovi olib tashlandi (07ze) */
label:has(#on-show), label:has(#sd-show) { display: none !important; }
/* Natijalar: qayta yechishga ruxsat tugmasi */
.r-amal { white-space: nowrap; }
.r-amal [data-act="qayta"][aria-pressed="true"] { border-color: var(--good); color: var(--good); }
/* CSS ichidagi yozuvlar (style.css dagi content: "...") — tilga qarab */
@media (min-width: 861px) { /* telefondagi pastki menyuda bu yozuv ko'rinmaydi */
  html[lang="ru"] .side nav::before { content: "Разделы"; }
  html[lang="en"] .side nav::before { content: "Sections"; }
}
@media (max-width: 420px) { /* tor telefonda "TestTuz" nomi kesilmasin */
  .side-top { flex: 0 0 auto; }
  .side-top .logo { width: 34px; height: 34px; flex-basis: 34px; }
  .side-top .brand-t b { font-size: 15px; }
  .side-tools { gap: 6px; min-width: 0; }
  .side-tools .tt-chev { display: none; }
  .side-tools .tt-btn { padding: 0 7px; gap: 4px; }
}
html[lang="ru"] .sw.locked .sw-t small::after { content: " · с тарифа Plus"; }
html[lang="en"] .sw.locked .sw-t small::after { content: " · from the Plus plan"; }
/* Sayqal: rus/ingliz yozuvlari uzunroq — menyu va tugmalar sig'ishi uchun (asl dizayn o'zgarmaydi) */
.ld-links a { white-space: nowrap; }
@media (max-width: 1220px) { html:not([lang="uz"]) .ld-links a { padding: 8px 10px; font-size: 14px; } }
@media (max-width: 1100px) { html:not([lang="uz"]) .ld-links { display: none; } }
.side-tools { align-items: center; }
.tgl-lbl { flex: 1; min-width: 0; }
html:not([lang="uz"]) .side nav button .nl { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
html:not([lang="uz"]) .ld-btn, html:not([lang="uz"]) .seg button { white-space: nowrap; }
.side .side-tools { z-index: 5; }
.ld-nav { z-index: 60; }

/* Minimal bosh sahifa: bitta asosiy amal, keyingi qadam, so'nggi testlar (asl ranglar va tokenlar) */
[data-view="home"] .hero { padding: 32px 36px; }
[data-view="home"] .hero h1 { font-size: clamp(30px, 3.6vw, 42px); margin-bottom: 8px; }
.onb-qisqa { margin-bottom: 0; }
.onb-qisqa .onb-ht h2 { font-size: 19px; }
.onb-qisqa + .onb-list { margin-top: 16px; }
.onb-amal { display: flex; align-items: center; gap: 8px; flex: none; }
.onb-amal .onb-x { align-self: center; }
.h-tests { padding: 22px 24px; animation: card-in .5s .1s var(--ease) both; }
.h-tests .card-h { margin-bottom: 8px; }
.h-test { display: flex; align-items: center; gap: 10px; padding: 12px 0; border-top: 1px solid var(--hair); }
.h-test:first-child { border-top: 0; }
.h-test-t { flex: 1; min-width: 0; }
.h-test-t b { display: block; overflow: hidden; color: var(--head); font-size: 15px; text-overflow: ellipsis; white-space: nowrap; }
.h-test-t small { display: block; margin-top: 2px; color: var(--muted); font-size: 13px; }
.h-test-t small span + span::before { content: " · "; }
.h-test .pill { flex: none; }
/* Bosh sahifa: amaldagi tarif belgisi (salomlashuv blokida, hamma qurilmada) */
.h-tarif { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 2px 0; margin-top: 14px; min-height: 0; padding: 6px 14px; border: 1px solid rgba(255, 255, 255, .28); border-radius: 99px; background: rgba(255, 255, 255, .1); color: #fff; font: 600 13px/1.35 var(--f-ui); text-align: left; cursor: pointer; animation: rise .7s .25s var(--ease) both; }
.h-tarif[hidden] { display: none; }
.h-tarif:hover:not(:disabled) { background: rgba(255, 255, 255, .18); border-color: rgba(255, 255, 255, .5); color: #fff; }
.h-tarif:focus-visible { outline: 2px solid #f8e6c6; outline-offset: 2px; }
.h-tarif i { margin-right: 7px; font-style: normal; font-size: 10px; color: #f8bf5e; }
.h-tarif span + span::before { content: "·"; margin: 0 7px; opacity: .6; }
.h-tarif em { margin-left: 10px; font-style: normal; color: #f8e6c6; text-decoration: underline; text-underline-offset: 3px; }
.h-tarif.oz { border-color: #f8bf5e; background: rgba(248, 191, 94, .2); }
.h-tarif .h-qoldi { margin-left: 10px; padding: 1px 8px; border-radius: 99px; background: #f8bf5e; color: #2a1a06; font-size: 12px; font-weight: 700; }
/* Bosh sahifa: So'nggi testlar va So'nggi natijalar yonma-yon (keng ekranda) */
.h-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.h-grid > [hidden] { display: none; }
.h-grid:has(> .card[hidden]) { grid-template-columns: minmax(0, 1fr); }
@media (max-width: 1100px) { .h-grid { grid-template-columns: minmax(0, 1fr); } }
.h-rrow { width: 100%; min-height: 0; margin: 0; border: 0; border-top: 1px solid var(--hair); border-radius: 0; background: transparent; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.h-rrow:first-child { border-top: 0; }
.h-rrow:hover:not(:disabled) { background: var(--well); border-color: var(--hair); }
.h-rrow:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; border-radius: 10px; }
.h-rrow .h-test-t b .pill { margin-left: 6px; font-size: 11px; vertical-align: 1px; }
.h-rball { flex: none; color: var(--head); font-weight: 700; font-variant-numeric: tabular-nums; }
.h-rrow .r-grade { flex: none; }
@media (max-width: 760px) { .h-rrow { flex-wrap: nowrap; } .h-rrow .h-test-t { flex: 1 1 auto; } }
.h-test button { flex: none; }
@media (max-width: 760px) {
  [data-view="home"] .hero { padding: 24px 20px; }
  [data-view="home"] .hero-btns, [data-view="home"] .hero-pri { width: 100%; }
  .onb-qisqa { flex-wrap: wrap; }
  .onb-qisqa .onb-ht { flex: 1 1 calc(100% - 70px); }
  .onb-amal { width: 100%; flex-wrap: wrap; }
  .onb-amal .pri { flex: 1 1 100%; }
  .onb-amal .ghost:not(.onb-x) { flex: 1; }
  .h-tests { padding: 18px 16px; }
  .h-test { flex-wrap: wrap; }
  .h-test-t { flex: 1 1 100%; }
  .h-test:has(.pill) .h-test-t { flex-basis: calc(100% - 100px); } /* "ochiq" belgisi nom yonida, tugmalar keyingi qatorda */
  .h-test button { flex: 1 1 0; min-width: 0; min-height: 44px; }
}
@media (max-width: 860px) { .app { align-content: start; } } /* kam ma'lumotli sahifada yuqori panel cho'zilmasin */

/* Minimal savollar bazasi: qidiruv, kartochka bilan tanlash, bosilganda ochiladigan savollar */
[data-view="bank"] .head-row { align-items: center; }
#bank-stat:empty { display: none; }
[data-view="bank"] .filters { flex-wrap: nowrap; }
[data-view="bank"] .filters > [hidden], #bk-nav[hidden], .bk-crumb[hidden], #bk-fold[hidden] { display: none; }
[data-view="bank"] .filters input { flex: 1 1 auto; min-width: 0; }
.bk-diff { flex: none; }
.bk-wrap { grid-template-columns: minmax(0, 1fr); }
.bk-bar:not(:has(.bk-crumb:not([hidden]))):not(:has(#bk-fold:not([hidden]))) { display: none; }
.bk-pick h2 { margin: 0 0 16px; }
.q-list .bk-grp:only-of-type .bk-chev { display: none; }
.q-list .bk-grp:only-of-type .bk-gh { cursor: default; }
.bk-gact .sm svg { flex: none; }
.bk-gb { padding-left: 0; margin-left: 0; border-left: 0; }
.q-list.compact .q-card { position: relative; padding: 12px 42px 12px 16px; cursor: pointer; transition: border-color .18s, background .18s; }
.q-list.compact .q-card:hover { border-color: var(--edge2); }
.q-list.compact .q-card:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.q-list.compact .q-card::after { content: ""; position: absolute; top: 20px; right: 18px; width: 7px; height: 7px; border-right: 2px solid var(--faint); border-bottom: 2px solid var(--faint); transform: rotate(45deg); transition: transform .2s var(--ease); }
.q-list.compact .q-card.och::after { top: 23px; transform: rotate(-135deg); }
.q-list.compact .q-card:not(.och) .q-meta .sm,
.q-list.compact .q-card:not(.och) .pill.pub,
.q-list.compact .q-card:not(.och) .pill.sc-pill,
.q-list.compact .q-card:not(.och) .q-who { display: none; }
.q-list.compact .q-card.och { cursor: default; padding-bottom: 16px; }
.q-list.compact .q-card.och .q-meta .sm { opacity: 1; }
.q-list.compact .q-card.och .q-ans { display: none; }
.q-list.compact .q-card.och .q-body { display: block; overflow: visible; -webkit-line-clamp: unset; }
.q-list.compact .q-card.och .q-opts { display: grid; }
.q-list.compact .q-card.och .q-sol { display: block; }
.q-list.compact .q-card.och .q-img { display: block; }
@media (max-width: 760px) {
  [data-view="bank"] .head-btns { width: 100%; }
  [data-view="bank"] .head-btns button { flex: 1 1 0; min-width: 0; padding-left: 8px; padding-right: 8px; white-space: nowrap; }
  [data-view="bank"] .filters { flex-wrap: wrap; }
  [data-view="bank"] .filters input { flex: 1 1 100%; }
  [data-view="bank"] .filters .seg { flex: 1 1 100%; }
  [data-view="bank"] .filters .seg button { flex: 1; }
  .bk-diff, .bk-diff .dd { width: 100%; }
  .bk-gact .sm[data-gact="ren"] { flex: 0 0 44px; }
}
/* Minimal test tuzish: mavzu → test ko'rinishi → yuklab olish; qo'shimcha sozlamalar yopiq */
[data-view="build"] .head-row { align-items: center; }
.b-tanlov .b-mode { margin-bottom: 16px; }
.b-tanlov:has(#b-fs[hidden]) .b-mode { margin-bottom: 0; } /* blok rejimida ostida fan/sinf yo'q */
.b-tanlov .dd-btn .dd-val em { display: none; } /* fan nomi kesilmasin: savollar soni ro'yxat ichida ko'rinadi */
.build-side { position: static; max-height: none; overflow: visible; padding: 0; margin-right: 0; } /* ichki aylantirish yo'q, faqat sahifa aylanadi */
.b-tanlov .grid2 { margin-bottom: 0; }
.b-tanlov .fld { margin-bottom: 0; }
.b-note:empty, .ex-file:empty { display: none; }
.build-grid.bosh .b-sozlama, .build-grid.bosh .b-export, .build-grid.bosh .sheet-bar { display: none; }
.build-grid.bosh .sh-empty { min-height: 200px; }
.b-topics:has(#b-file:not([hidden])) #b-one { display: none; }
.b-more { margin-top: 12px; border-top: 1px solid var(--hair); padding-top: 10px; }
.b-more > summary { display: flex; align-items: center; justify-content: space-between; min-height: 32px; color: var(--soft); font-size: 13.5px; font-weight: 600; cursor: pointer; list-style: none; border-radius: 8px; }
.b-more > summary::-webkit-details-marker { display: none; }
.b-more > summary::after { content: ""; width: 7px; height: 7px; margin-right: 5px; border-right: 2px solid var(--faint); border-bottom: 2px solid var(--faint); transform: rotate(45deg); transition: transform .2s var(--ease); }
.b-more[open] > summary { margin-bottom: 10px; }
.b-more[open] > summary::after { transform: rotate(-135deg); }
.b-more > summary:hover { color: var(--head); }
.b-more > summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.b-more .b-row:last-child, .b-more .ex-sw:last-child { margin-bottom: 0; }
.b-export .ex-format button { display: flex; flex-direction: row; align-items: center; gap: 10px; min-height: 52px; padding: 8px 34px 8px 10px; }
.b-export .ex-format .fi { flex: none; margin: 0; transform: scale(.78); transform-origin: left center; margin-right: -6px; }
.t-row .q-meta { gap: 2px 0; }
.t-row .pill:not(.on-pill):not(.pub) { padding: 0; border: 0; background: none; color: var(--muted); font-size: 13px; font-weight: 500; }
.t-row .pill:not(.on-pill):not(.pub):not(:first-child)::before { content: "·"; margin: 0 6px; color: var(--faint); }
.t-row .pill.on-pill, .t-row .pill.pub { margin-left: 8px; }
.t-row .t-date { margin-left: 8px; font-size: 13px; }
/* Ixcham blok test: har blok ikki qator, sinf va Word so'ralganda ochiladi */
.b-blok-bar { display: none; }
.b-blok-top { margin-bottom: 12px; }
.b-blok-tot b { font-size: 26px; }
.b-blok-tot small { margin-top: 0; }
.b-bloklar { gap: 6px; }
.b-bl { gap: 6px; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--well); }
.b-bl.yoq, .b-bl.kam { border-color: var(--accent-line); }
.b-bl-r1 { grid-template-columns: 22px minmax(0, 1fr) 28px 28px; gap: 4px; }
.b-bl-n { width: 22px; height: 22px; background: none; color: var(--muted); font-size: 12.5px; font-weight: 700; }
.b-bl-x, .b-bl-more { width: 28px; height: 28px; min-height: 0; padding: 0; border: 0; border-radius: 8px; background: transparent; color: var(--faint); }
.b-bl-more { display: grid; place-items: center; cursor: pointer; }
.b-bl-more::before { content: ""; width: 6px; height: 6px; margin-top: -3px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); transition: transform .2s var(--ease); }
.b-bl.och .b-bl-more::before { margin-top: 3px; transform: rotate(-135deg); }
.b-bl-more:hover:not(:disabled) { background: var(--raise); color: var(--head); border: 0; }
.b-bl-r2, .b-bl-r3, .b-bl-r4 { padding-left: 26px; }
.b-bl-r3 { margin-top: 0; }
.b-bl-r4 { gap: 5px; }
.b-bl-r4 .b-bl-num { display: inline-flex; align-items: center; gap: 4px; width: auto; }
.b-bl-num input { width: 50px; min-height: 34px; padding: 4px 3px 4px 7px; }
.b-bl-num small { position: static; font-size: 12px; line-height: 1; white-space: nowrap; }
.b-bl-tot { margin-left: auto; }
.b-bl-tot b { font-size: 14px; }
/* Minimal natijalar: 3 ta asosiy tugma + menyu, ixcham ko'rsatkichlar, telefonda asosiy ustunlar */
[data-view="results"] .head-row { align-items: center; }
.r-omr { align-items: center; }
.r-amallar { position: relative; }
.r-amallar > summary { display: inline-flex; align-items: center; gap: 8px; min-height: 42px; padding: 0 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--well); color: var(--soft); font-weight: 600; font-size: 14px; cursor: pointer; list-style: none; white-space: nowrap; }
.r-amallar > summary::-webkit-details-marker { display: none; }
.r-amallar > summary::after { content: ""; width: 6px; height: 6px; margin-top: -3px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); transition: transform .2s var(--ease); }
.r-amallar[open] > summary { border-color: var(--accent-line); color: var(--head); }
.r-amallar[open] > summary::after { margin-top: 3px; transform: rotate(-135deg); }
.r-amallar > summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.r-menu { position: absolute; right: 0; top: calc(100% + 6px); z-index: 60; display: flex; flex-direction: column; gap: 2px; min-width: 230px; padding: 6px; border: 1px solid var(--line); border-radius: 14px; background: var(--panel-solid); box-shadow: var(--sh-pop); }
.r-menu button { justify-content: flex-start; width: 100%; min-height: 40px; border: 0; background: transparent; text-align: left; white-space: nowrap; }
.r-menu button:hover:not(:disabled) { background: var(--well); border: 0; }
.r-menu button[hidden] { display: none; }
.r-filters #r-src[hidden] { display: none; }
@media (max-width: 1000px) { .r-table .r-opt2, .r-table .r-bar { display: none; } .r-table .r-name { white-space: normal; } }
@media (max-width: 360px) { .r-table .r-score small { display: none; } }
@media (max-width: 340px) { .side-top .brand-t { display: none; } } /* 320 px telefonda nom tugmalar ostida qolmasin, logotip qoladi */
.r-kpis, .sc-kpis { gap: 10px; }
.r-kpis .kpi, .sc-kpis .kpi { padding: 14px 16px; }
.r-kpis .kpi::before, .r-kpis .kpi::after, .sc-kpis .kpi::before, .sc-kpis .kpi::after { display: none; }
.r-kpis .kpi:hover, .sc-kpis .kpi:hover { transform: none; box-shadow: none; }
.r-kpis .kpi-l, .sc-kpis .kpi-l { font-size: 12.5px; color: var(--muted); margin-bottom: 2px; }
.r-kpis .num, .sc-kpis .num { font-size: 28px; }
.r-kpis .kpi small, .sc-kpis .kpi small { margin-top: 2px; font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Sozlamalar: ichidagi yashirin ro'yxat sahifani yonga surmasin; taklif kodi kataklari torayadi */
.st-card { overflow-x: clip; }
.tk-card .kod-k { flex-wrap: nowrap; gap: 4px; }
.tk-card .kod-c { flex: 1 1 0; width: auto; min-width: 0; max-width: 40px; }
@media (max-width: 420px) {
  .tk-card .on-link { flex-wrap: wrap; }
  .tk-card .on-link > button { flex: 1 1 100%; }
}
.st-row > button { flex: none; white-space: nowrap; }
@media (max-width: 560px) { /* "Juda katta" kabi uzun tanlovlar tor telefonda sig'sin */
  .st-row { flex-wrap: wrap; }
  .st-row .seg { width: 100%; }
  [data-view="settings"] .st-row .seg button { flex: 1 1 0; min-width: 0; white-space: normal; line-height: 1.2; } /* rus/ingliz "nowrap" qoidasidan kuchliroq */
}
@media (max-width: 360px) {
  [data-view="settings"] .st-row .seg button { padding-left: 4px; padding-right: 4px; font-size: 12px; }
}
/* Birinchi kirish tanishtiruvi (js/tour.js): qorong'i fon, yoritilgan joy, kartochka */
.tn { position: fixed; inset: 0; z-index: 250; }
.tn-bg { position: absolute; inset: 0; background: rgba(5, 10, 22, .62); }
.tn:not(.markaz) .tn-bg { background: transparent; }
.tn-hole { position: fixed; border-radius: 14px; box-shadow: 0 0 0 9999px rgba(5, 10, 22, .62), 0 0 0 2px var(--accent); pointer-events: none; transition: left .25s var(--ease), top .25s var(--ease), width .25s var(--ease), height .25s var(--ease); }
.tn-hole[hidden] { display: none; }
.tn-card { position: fixed; z-index: 1; padding: 20px 22px; border: 1px solid var(--line); border-radius: 18px; background: var(--panel-solid); box-shadow: var(--sh-pop); color: var(--ink); animation: card-in .3s var(--ease) both; }
.tn.markaz .tn-card { left: 50%; top: 50%; width: min(560px, calc(100% - 24px)); max-height: calc(100% - 24px); overflow-y: auto; transform: translate(-50%, -50%); animation: none; }
.tn-eyebrow { font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.tn-card h2 { margin: 4px 0 6px; font: 700 26px/1.2 var(--f-disp); color: var(--head); }
.tn-card h3 { margin: 6px 0 4px; font: 700 19px/1.25 var(--f-disp); color: var(--head); }
.tn-p { margin: 0 0 14px; color: var(--muted); font-size: 14px; line-height: 1.5; }
.tn-l { margin: 12px 0 8px; color: var(--soft); font-size: 13.5px; font-weight: 600; }
.tn-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.tn-btns { display: flex; align-items: center; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.tn-btns .sp { flex: 1; }
.tn-top { display: flex; align-items: center; justify-content: space-between; }
.tn-n { color: var(--muted); font-size: 12.5px; font-weight: 600; }
.tn-dots { display: inline-flex; gap: 5px; }
.tn-dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--line); }
.tn-dots i.on { width: 18px; border-radius: 4px; background: var(--accent); }
.tn-cup { display: block; font-size: 40px; text-align: center; }
.tn.markaz .tn-card h2, .tn.markaz .tn-card .tn-cup + h2 { text-align: left; }
@media (max-width: 760px) {
  .tn-card { padding: 16px; }
  .tn.markaz .tn-card { top: auto; bottom: 12px; transform: translateX(-50%); max-height: calc(100% - 24px); }
  .tn-card h2 { font-size: 22px; }
  .tn-btns { flex-wrap: wrap; }
  .tn-btns > .pri { flex: 1 1 auto; }
}
@media (prefers-reduced-motion: reduce) { .tn-hole, .tn-card { transition: none; animation: none; } }
:root[data-motion="off"] .tn-hole, :root[data-motion="off"] .tn-card { transition: none; animation: none; }
/* Menyu: hali ochilmagan oyna yonida olovrang nuqta (yangi o'qituvchi) */
.side nav button.yangi-n { position: relative; }
.nav-nuqta { position: absolute; top: 50%; right: 14px; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent); pointer-events: none; }
.side nav button[aria-current="page"] .nav-nuqta { display: none; }
@media (max-width: 860px) { .nav-nuqta { top: 8px; right: auto; left: calc(50% + 9px); margin-top: 0; width: 7px; height: 7px; } }
.tn-n b { color: var(--head); font-weight: 700; }
/* Profil: saqlangan fan va sinflar bitta qisqa qatorda */
.st-xulosa { display: flex; align-items: center; gap: 12px; margin: 4px 0 16px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--well); }
.st-xulosa[hidden], #pf-tanlov[hidden] { display: none; }
.st-xulosa-t { flex: 1; min-width: 0; }
.st-xulosa-t .st-lbl { display: block; margin-bottom: 2px; }
.st-xulosa-v { color: var(--head); font-size: 14px; font-weight: 600; line-height: 1.5; }
.st-xulosa-v span + span::before { content: "·"; margin: 0 6px; color: var(--faint); font-weight: 400; }
.st-xulosa > button { flex: none; }
/* Planshetda ham bo'limlar menyusi tepada (yon ustun torayib ketmasin) */
@media (max-width: 1000px) and (min-width: 861px) {
  .st-wrap { grid-template-columns: minmax(0, 1fr); }
  .st-nav { position: static; flex-direction: row; flex-wrap: wrap; }
  .st-nav button { width: auto; flex: 1 1 auto; }
}
/* Sozlamalar: telefonda bo'limlar 3 ustunli tugmalar (yashirinib qolmaydi) */
@media (max-width: 860px) {
  .st-nav { position: static; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); overflow: visible; gap: 4px; padding: 6px; }
  .st-nav button { flex-direction: column; justify-content: center; gap: 4px; width: 100%; min-height: 58px; padding: 8px 4px; white-space: normal; text-align: center; font-size: 12.5px; line-height: 1.2; }
  .st-nav button span { overflow-wrap: anywhere; }
  .st-nav button[aria-selected="true"] { box-shadow: inset 0 0 0 1px var(--accent-line); }
}

/* Minimal maktab: ixcham kirish qismi; adminda o'qituvchilar va taklif yuqorida; telefonda o'qituvchilar kartochka */
.sc-hero { padding: 26px 30px; gap: 22px; }
.sc-hero h2 { font-size: clamp(24px, 2.6vw, 30px); }
.sc-feats { gap: 6px; }
.sc-feats li { padding: 8px 12px; }
.sc-feats i { flex-basis: 32px; width: 32px; height: 32px; border-radius: 10px; }
.sc-feats svg { width: 17px; height: 17px; }
.sc-opt { padding: 22px; }
.sc-opt h2 { font-size: 19px; }
/* Yanada ixcham maktab: admin uchun ikki bo'lim, yopiladigan izoh va "chiqish" qismlari */
.sc-head .q-meta { gap: 4px 0; }
.sc-head .pill:not(.sc-adm):not(.pub) { padding: 0; border: 0; background: none; color: var(--muted); font-size: 13px; font-weight: 500; }
.sc-head .pill:not(.sc-adm):not(.pub)::before { content: "·"; margin: 0 7px; color: var(--faint); }
.sc-tabs { display: inline-flex; margin-bottom: 14px; max-width: 100%; }
.sc-tabs button { flex: 0 0 auto; min-width: 0; padding-left: 16px; padding-right: 16px; white-space: nowrap; overflow: visible; }
.sc-tabs[hidden], .sc-tab[hidden] { display: none; }
.sc-tab > .card { margin-bottom: 14px; }
.sc-tab .sc-kpis { margin-bottom: 14px; }
.sc-xavf { padding: 0; }
.sc-xavf > summary { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; color: var(--muted); font-size: 14px; font-weight: 600; cursor: pointer; list-style: none; }
.sc-xavf > summary::-webkit-details-marker, .sc-nima > summary::-webkit-details-marker, .sc-feats-d > summary::-webkit-details-marker { display: none; }
.sc-xavf > summary::after, .sc-nima > summary::after, .sc-feats-d > summary::after { content: ""; flex: none; width: 7px; height: 7px; margin-left: 10px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); transition: transform .2s var(--ease); opacity: .7; }
.sc-xavf[open] > summary::after, .sc-nima[open] > summary::after, .sc-feats-d[open] > summary::after { transform: rotate(-135deg); }
.sc-xavf > summary:hover { color: var(--bad); }
.sc-xavf > div, .sc-xavf > p, .sc-xavf > button { margin: 0 20px 16px; }
.sc-xavf > div > p { margin: 0 0 12px; }
.sc-azo { display: grid; gap: 14px; max-width: 760px; }
.sc-nima > summary { display: flex; align-items: center; justify-content: space-between; cursor: pointer; list-style: none; margin-bottom: 4px; }
.sc-nima > summary h2 { margin: 0; }
.sc-nima[open] > summary { margin-bottom: 12px; }
.sc-tip > .pri { margin-top: 14px; }
.sc-hero { grid-template-columns: minmax(0, 1fr); }
.sc-feats-d { margin-top: 14px; }
.sc-feats-d > summary { display: inline-flex; align-items: center; color: #f6e3c4; font-size: 14px; font-weight: 600; cursor: pointer; list-style: none; }
.sc-feats-d[open] .sc-feats { margin-top: 12px; }
.sc-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); }
.sc-grid.yakka { grid-template-columns: minmax(0, 1fr); }
.sc-grid > [hidden] { display: none; }
.sc-table td { white-space: normal; }
.sc-table .sc-who small { overflow-wrap: anywhere; }
.sc-table .r-bar { width: 48px; }
.sc-table .pill { white-space: nowrap; }
.sc-acts { min-width: 150px; }
.sc-acts .sm { margin: 2px 0 2px 4px; white-space: nowrap; }
@media (max-width: 1180px) { .sc-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) { .sc-hero { padding: 22px 18px; } }
@media (max-width: 1000px) { /* tor ekranda o'qituvchilar jadvali kartochkaga aylanadi */
  .sc-teachers { padding: 16px 12px; }
  .sc-teachers .tw { border: 0; overflow: visible; }
  .sc-table thead { display: none; }
  .sc-table, .sc-table tbody { display: block; }
  .sc-table tr { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 10px; padding: 12px; margin-bottom: 8px; border: 1px solid var(--line); border-radius: 14px; background: var(--well); }
  .sc-table td { display: block; padding: 0; border: 0; white-space: normal; background: none !important; }
  .sc-table td:first-child, .sc-table td.sc-acts { grid-column: 1 / -1; }
  .sc-table td[data-l]::before { content: attr(data-l); display: block; margin-bottom: 2px; font-size: 11px; font-weight: 500; color: var(--muted); }
  .sc-table td.sc-acts { display: flex; flex-wrap: wrap; gap: 6px; text-align: left; }
  .sc-table td.sc-acts .sm { flex: 1 1 auto; min-height: 40px; margin: 0; white-space: nowrap; }
  .sc-table .r-score .r-bar { flex: 1; }
}
@media (max-width: 760px) {
  [data-view="results"] .r-omr { width: 100%; }
  [data-view="results"] .r-omr > button, .r-amallar { flex: 1 1 calc(50% - 4px); min-width: 0; }
  [data-view="results"] #r-scan { flex-basis: 100%; }
  .r-amallar > summary { width: 100%; justify-content: center; padding: 0 8px; }
  [data-view="results"] .r-omr > button { padding-left: 8px; padding-right: 8px; white-space: nowrap; }
  .r-menu { left: auto; right: 0; min-width: min(260px, calc(100vw - 40px)); }
  .r-table .r-opt { display: none; }
  .r-table td, .r-table th { padding-left: 6px; padding-right: 6px; }
  .r-table-card { padding: 14px 10px; }
  .r-table .r-name { white-space: normal; }
  .r-table .r-bar { display: none; }
  .r-table .r-amal .sm { min-width: 32px; min-height: 32px; padding: 0 6px; }
  .r-kpis .num { font-size: 24px; }
}
@media (max-width: 1180px) { /* bitta ustun: test ko'rinishi yuklab olishdan oldin turadi */
  .build-side { display: contents; }
  .b-tanlov { order: 1; }
  .b-topics, .b-blok { order: 2; }
  .b-sozlama { order: 3; }
  .build-main { order: 4; }
  .b-export { order: 5; }
  .build-grid.bosh .build-main { display: none; }
}
@media (max-width: 760px) {
  [data-view="build"] .head-btns { width: 100%; }
  [data-view="build"] .head-btns button { flex: 1 1 0; min-width: 0; padding-left: 8px; padding-right: 8px; white-space: nowrap; }
  .t-row .t-info { flex: 1 1 100%; }
  .t-row > button { flex: 1 1 0; min-height: 44px; }
}
@media (max-width: 360px) { /* tor telefonda uzun rus/ingliz yozuvlari kesilmasin */
  [data-view="build"] .head-btns { flex-direction: column; }
  [data-view="build"] .head-btns button { flex: none; width: 100%; }
  .b-topics .card-h { flex-wrap: wrap; }
  .b-topics .card-h h2 { flex: 1 1 100%; }
  .b-topics .card-h .sp { display: none; }
  .b-topics .card-h .sm { flex: 1 1 0; white-space: nowrap; }
  .t-row > button { padding-left: 3px; padding-right: 3px; font-size: 12.5px; }
  .b-bl-r2, .b-bl-r3, .b-bl-r4 { padding-left: 0; }
  .b-bl-r4 { flex-wrap: wrap; }
  [data-view="bank"] .head-btns { flex-direction: column; }
  [data-view="bank"] .head-btns button { flex: none; width: 100%; }
  .bk-gact { flex-wrap: wrap; }
  .bk-gact .sm[data-gact="test"] { flex: 1 1 100%; order: -1; }
}
