/* behbudiyshunos.uz — sayt uslublari
   Ranglar: Lapis ko‘k #1F3A8A · Oltin #E8A33D · Qaymoq #FBF3E4 · Siyoh #1B1F2A · Osmon #DCE6F7 */

:root {
  --lapis: #1F3A8A; --lapis-600: #2B4BA6; --lapis-700: #182E6E; --lapis-800: #13265C; --lapis-900: #0E1C45;
  --gold: #E8A33D; --gold-600: #C9861F; --gold-700: #A86B12; --gold-100: #FCEFD9;
  --cream: #FBF3E4; --cream-200: #F4E6CB;
  --ink: #1B1F2A; --ink-2: #353B4D; --muted: #626A80; --line: #E3E7F0; --line-2: #D3DAE8;
  --sky: #DCE6F7; --sky-50: #EEF3FB; --sky-100: #E6EDF9;
  --slate: #5468A3; --slate-700: #3E5089;
  --bg: #FFFFFF; --surface: #FFFFFF;
  --ok: #1E7B4E; --ok-bg: #E3F4EA; --warn: #9A5B00; --warn-bg: #FFF2DA; --err: #B42318; --err-bg: #FDE8E6; --info-bg: #E8EEFB;
  --r-xl: 28px; --r-lg: 20px; --r: 14px; --r-sm: 10px;
  --shadow: 0 1px 2px rgba(27, 31, 42, .05), 0 10px 30px rgba(27, 31, 42, .07);
  --shadow-lg: 0 20px 60px rgba(14, 28, 69, .18);
  --font: 'Onest', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --serif: 'Lora', Georgia, 'Times New Roman', serif;
  --arabic: 'Noto Naskh Arabic', 'Amiri', serif;
  --header-h: 72px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body { margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.6; color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img, svg, video, canvas, iframe { max-width: 100%; }
img { height: auto; display: block; }
a { color: var(--lapis); text-decoration: none; }
a:hover { color: var(--lapis-600); }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; font-weight: 700; letter-spacing: -.015em; color: var(--ink); }
h1 { font-size: clamp(30px, 4.2vw, 48px); }
h2 { font-size: clamp(24px, 3vw, 32px); }
h3 { font-size: 20px; }
p { margin: 0 0 1em; }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 6px; }
.skip-link { position: absolute; left: -9999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 1000; }
.skip-link:focus { left: 8px; }
.container { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 24px; }
.ico { width: 20px; height: 20px; flex: none; vertical-align: middle; }
.ico-sm { width: 16px; height: 16px; }
.ico-lg { width: 28px; height: 28px; }
.muted { color: var(--muted); }
.mt { margin-top: 24px; }
.center { text-align: center; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
[hidden] { display: none !important; }

/* ---------- Tugmalar ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 20px; border-radius: 999px; border: 1px solid transparent; font-weight: 600; font-size: 15px; line-height: 1.2; white-space: nowrap; transition: background .18s, color .18s, border-color .18s, transform .18s; text-align: center; }
.btn:active { transform: translateY(1px); }
.btn-sm { min-height: 38px; padding: 8px 16px; font-size: 14px; }
.btn-lg { min-height: 52px; padding: 14px 26px; font-size: 16px; }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: var(--lapis-800); color: #fff; }
.btn-primary { background: var(--lapis); color: #fff; }
.btn-primary:hover { background: var(--lapis-700); color: #fff; }
.btn-gold { background: var(--gold); color: var(--ink); }
.btn-gold:hover { background: #F0B455; color: var(--ink); }
.btn-light { background: #fff; color: var(--ink); }
.btn-light:hover { background: var(--cream); color: var(--ink); }
.btn-outline-light { border-color: rgba(255, 255, 255, .85); color: #fff; background: rgba(255, 255, 255, .06); }
.btn-outline-light:hover { background: rgba(255, 255, 255, .16); color: #fff; }
.btn-ghost { border-color: var(--line-2); color: var(--ink); background: #fff; }
.btn-ghost:hover { border-color: var(--lapis); color: var(--lapis); }
.btn[disabled] { opacity: .55; pointer-events: none; }
.icon-btn { display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: #fff; color: var(--ink); transition: .18s; }
.icon-btn:hover { border-color: var(--lapis); color: var(--lapis); }
.round-btn { width: 40px; height: 40px; border-radius: 50%; border: 1.5px solid var(--ink); background: transparent; display: inline-grid; place-items: center; color: var(--ink); }
.round-btn:hover { background: var(--ink); color: #fff; }

/* ---------- Sarlavha (header) ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .94); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.site-header.scrolled { border-bottom-color: var(--line); }
.header-inner { display: flex; align-items: center; gap: 20px; height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); flex: none; }
.brand:hover { color: var(--ink); }
.logo-mark { width: 34px; height: 35px; }
.brand-text { font-weight: 800; font-size: 18px; letter-spacing: -.02em; }
.brand-text b { font-weight: 800; }
.brand-text i { font-style: normal; color: var(--gold-600); }
.main-nav { display: flex; align-items: center; gap: 2px; }
.main-nav a, .nav-more { padding: 8px 12px; border-radius: 999px; color: var(--ink-2); font-size: 14px; font-weight: 500; background: none; border: 0; display: inline-flex; align-items: center; gap: 4px; }
.main-nav a:hover, .nav-more:hover, .main-nav a.on { color: var(--lapis); background: var(--sky-50); }
.header-search { position: relative; flex: 1; max-width: 340px; margin-left: auto; }
.header-search input { width: 100%; height: 42px; border-radius: 999px; border: 1px solid var(--line); background: #F4F6FA; padding: 0 44px 0 18px; font: inherit; font-size: 14px; color: var(--ink); }
.header-search input:focus { outline: none; border-color: var(--lapis); background: #fff; }
.header-search button { position: absolute; right: 4px; top: 4px; width: 34px; height: 34px; border-radius: 50%; border: 0; background: transparent; color: var(--muted); display: grid; place-items: center; }
.header-actions { display: flex; align-items: center; gap: 8px; }
.lang-switch { position: relative; }
.lang-btn { height: 40px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line); background: #fff; display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--ink); }
.lang-menu { position: absolute; right: 0; top: 48px; background: #fff; border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 6px; min-width: 150px; z-index: 60; }
.lang-menu a { display: block; padding: 8px 12px; border-radius: 8px; color: var(--ink); font-size: 14px; }
.lang-menu a:hover, .lang-menu a.on { background: var(--sky-50); color: var(--lapis); }
.burger { display: none; }
.suggest { position: absolute; left: 0; right: 0; top: 48px; background: #fff; border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: 6px; z-index: 70; max-height: 420px; overflow: auto; }
.suggest a { display: flex; gap: 10px; align-items: baseline; padding: 8px 10px; border-radius: 8px; color: var(--ink); font-size: 14px; }
.suggest a:hover, .suggest a.active { background: var(--sky-50); }
.suggest small { color: var(--muted); font-size: 12px; margin-left: auto; white-space: nowrap; }

.mega { position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow-lg); padding: 24px 0 28px; max-height: calc(100vh - var(--header-h)); overflow: auto; }
.mega-search { display: none; align-items: center; gap: 10px; border: 1px solid var(--line); border-radius: 999px; padding: 0 16px; margin-bottom: 16px; color: var(--muted); }
.mega-search input { flex: 1; border: 0; height: 46px; font: inherit; outline: none; }
.mega-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.mega-item { display: flex; gap: 12px; padding: 12px; border-radius: var(--r); color: var(--ink); }
.mega-item:hover { background: var(--sky-50); color: var(--ink); }
.mega-item b { display: block; font-size: 15px; font-weight: 600; }
.mega-item small { display: block; color: var(--muted); font-size: 13px; line-height: 1.4; margin-top: 2px; }
.mega-ico { width: 42px; height: 42px; border-radius: 12px; background: var(--sky); color: var(--lapis); display: grid; place-items: center; flex: none; }
.mega-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--line); }
.mega-links a { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px; background: var(--sky-50); color: var(--ink-2); font-size: 14px; font-weight: 500; }
.mega-links a:hover { background: var(--sky); color: var(--lapis); }

/* ---------- Xabarlar ---------- */
.flash-wrap { padding-top: 16px; }
.alert { padding: 12px 16px; border-radius: var(--r-sm); margin-bottom: 12px; font-size: 15px; border: 1px solid transparent; }
.alert-success { background: var(--ok-bg); color: var(--ok); border-color: #BFE5CF; }
.alert-error { background: var(--err-bg); color: var(--err); border-color: #F6C8C3; }
.alert-info { background: var(--info-bg); color: var(--lapis-700); border-color: #CBD8F3; }
.alert-warning { background: var(--warn-bg); color: var(--warn); border-color: #F3D9A8; }

/* ---------- Hero ---------- */
.hero-wrap { padding: 12px 0 0; }
.hero { position: relative; border-radius: var(--r-xl); overflow: hidden; min-height: clamp(460px, 62vh, 620px); display: flex; align-items: flex-end; color: #fff; background: var(--lapis-800); isolation: isolate; }
.hero-bg { position: absolute; inset: 0; z-index: -2; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; }
.hero-bg.pattern { background:
  radial-gradient(circle at 78% 108%, #E8A33D 0 13%, rgba(232, 163, 61, .32) 13.3% 19%, rgba(232, 163, 61, .12) 19.3% 26%, transparent 26.3%),
  radial-gradient(ellipse at 80% 0%, rgba(220, 230, 247, .18), transparent 55%),
  linear-gradient(160deg, #24449A 0%, var(--lapis) 45%, var(--lapis-900) 100%); }
.hero-bg.pattern::after { content: ""; position: absolute; inset: 0; opacity: .13; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='80' height='80' viewBox='0 0 80 80'%3E%3Cg fill='none' stroke='%23FBF3E4' stroke-width='1.2'%3E%3Cpath d='M40 4l10 26 26 10-26 10-10 26-10-26L4 40l26-10z'/%3E%3Ccircle cx='40' cy='40' r='9'/%3E%3Cpath d='M0 0l16 16M80 0L64 16M0 80l16-16M80 80L64 64'/%3E%3C/g%3E%3C/svg%3E"); }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(14, 28, 69, .55) 0%, rgba(14, 28, 69, .15) 60%, rgba(14, 28, 69, 0) 100%); }
.hero.has-img::before { background: linear-gradient(180deg, rgba(14, 28, 69, .05) 0%, rgba(14, 28, 69, .25) 50%, rgba(14, 28, 69, .78) 100%); }
.hero-rays { position: absolute; left: 50%; bottom: -2px; transform: translateX(-50%); width: min(560px, 80%); z-index: -1; opacity: .9; }
.hero-content { position: relative; width: 100%; padding: clamp(28px, 5vw, 64px); padding-top: 120px; }
.hero-word { font-size: clamp(44px, 14.5vw, 210px); font-weight: 800; line-height: .82; letter-spacing: -.055em; margin: 0 0 18px; color: #fff; display: flex; align-items: flex-end; gap: 14px; text-shadow: 0 6px 40px rgba(0, 0, 0, .18); }
.hero-word small { font-size: clamp(14px, 1.6vw, 20px); letter-spacing: .02em; font-weight: 700; color: var(--gold); padding-bottom: .9em; white-space: nowrap; }
.hero-text { max-width: 560px; font-size: clamp(15px, 1.4vw, 18px); color: rgba(255, 255, 255, .92); margin-bottom: 22px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-badge { position: absolute; top: 24px; left: clamp(24px, 5vw, 64px); display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .2); font-size: 13px; font-weight: 600; backdrop-filter: blur(6px); }
.hero-badge i { width: 8px; height: 8px; border-radius: 50%; background: var(--gold); }

/* ---------- Bo'limlar ---------- */
.section { padding: clamp(48px, 7vw, 88px) 0; }
.section-tight { padding: 40px 0; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px 48px; margin-bottom: 28px; flex-wrap: wrap; }
.section-head h2 { margin: 0; max-width: 560px; }
.section-head p { max-width: 460px; color: var(--muted); margin: 0; font-size: 15px; }
.section-head .eyebrow { display: block; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--gold-700); margin-bottom: 10px; }
.eyebrow::before { content: ""; width: 18px; height: 2px; background: var(--gold); border-radius: 2px; }
.panel { background: var(--sky-50); border-radius: var(--r-xl); padding: clamp(24px, 4.5vw, 52px); }
.panel-cream { background: var(--cream); }
.panel-dark { background: var(--lapis-900); color: #fff; }
.panel-dark h2, .panel-dark h3 { color: #fff; }
.panel-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 28px; gap: 16px; flex-wrap: wrap; }
.carousel-nav { display: flex; gap: 10px; }

/* About (WANDER "Why" bloki) */
.about-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(28px, 6vw, 80px); align-items: center; }
.about-grid h2 { font-size: clamp(24px, 2.6vw, 30px); }
.about-text { color: var(--ink-2); font-size: 16px; }
.socials { display: flex; gap: 10px; margin: 18px 0 0; }
.socials a { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; color: inherit; border: 1px solid currentColor; opacity: .85; }
.socials a:hover { opacity: 1; }
.stats-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 40px; text-align: center; }
.stat-circle { width: 52px; height: 52px; border-radius: 50%; background: var(--ink); color: #fff; display: grid; place-items: center; margin: 0 auto 10px; }
.stat-num { font-size: 26px; font-weight: 700; line-height: 1.1; letter-spacing: -.02em; }
.stat-label { font-size: 13px; color: var(--muted); line-height: 1.35; }
.feature-list { display: grid; gap: 14px; }
.feature-card { display: flex; gap: 16px; align-items: stretch; padding: 12px; border-radius: var(--r-lg); background: var(--slate); color: #fff; transition: transform .2s, background .2s; }
.feature-card:hover { transform: translateY(-2px); background: var(--slate-700); color: #fff; }
.feature-card .fc-ico { width: 84px; min-height: 84px; border-radius: 14px; background: rgba(255, 255, 255, .92); color: var(--lapis-800); display: grid; place-items: center; flex: none; }
.feature-card .fc-ico .ico { width: 40px; height: 40px; stroke-width: 1.6; }
.feature-card h3 { color: #fff; font-size: 17px; margin: 6px 0 4px; }
.feature-card p { color: rgba(255, 255, 255, .86); font-size: 13.5px; line-height: 1.45; margin: 0; }

/* Kartalar */
.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.cards-3 { grid-template-columns: repeat(3, 1fr); }
.cards-2 { grid-template-columns: repeat(2, 1fr); }
.scroller { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 54px) / 4); gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding-bottom: 4px; }
.scroller::-webkit-scrollbar { display: none; }
.scroller > * { scroll-snap-align: start; }
.card-tall { position: relative; display: block; border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 3 / 4; background: var(--lapis-700); color: #fff; isolation: isolate; box-shadow: var(--shadow); }
.card-tall img, .card-tall .ph { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform .5s; }
.card-tall:hover img, .card-tall:hover .ph { transform: scale(1.04); }
.card-tall::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(14, 28, 69, 0) 35%, rgba(14, 28, 69, .88) 100%); }
.card-tall .pill { position: absolute; top: 12px; right: 12px; }
.card-tall .ct-body { position: absolute; left: 0; right: 0; bottom: 0; padding: 16px; }
.card-tall h3 { color: #fff; font-size: 17px; margin: 0 0 6px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.card-tall .ct-meta { font-size: 12.5px; color: rgba(255, 255, 255, .85); display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; }
.card-tall .ct-meta .ico { width: 14px; height: 14px; color: var(--gold); }
.card-tall:hover { color: #fff; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; border-radius: 999px; font-size: 12px; font-weight: 600; background: rgba(255, 255, 255, .88); color: var(--ink); backdrop-filter: blur(4px); }
.pill-gold { background: var(--gold); color: var(--ink); }
.pill-lapis { background: var(--lapis); color: #fff; }
.pill-soft { background: var(--sky); color: var(--lapis-700); }
.pill-cream { background: var(--cream); color: var(--gold-700); }

.ph { background: linear-gradient(150deg, var(--lapis) 0%, var(--lapis-900) 100%); display: grid; place-items: center; color: rgba(251, 243, 228, .9); position: relative; overflow: hidden; }
.ph::before { content: ""; position: absolute; inset: 0; opacity: .12; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64' viewBox='0 0 64 64'%3E%3Cg fill='none' stroke='%23FBF3E4' stroke-width='1'%3E%3Cpath d='M32 3l8 21 21 8-21 8-8 21-8-21-21-8 21-8z'/%3E%3C/g%3E%3C/svg%3E"); }
.ph .ico { width: 44px; height: 44px; stroke-width: 1.3; position: relative; }
.ph-gold { background: linear-gradient(150deg, #F1B653, var(--gold-600)); color: var(--lapis-900); }
.ph-cream { background: linear-gradient(150deg, var(--cream), var(--cream-200)); color: var(--lapis); }
.ph-cream::before { filter: invert(1); opacity: .06; }

.card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; color: var(--ink); transition: box-shadow .2s, transform .2s, border-color .2s; height: 100%; }
.card:hover { box-shadow: var(--shadow); transform: translateY(-2px); color: var(--ink); border-color: var(--line-2); }
.card-media { aspect-ratio: 16 / 10; position: relative; overflow: hidden; background: var(--sky); }
.card-media img, .card-media .ph { width: 100%; height: 100%; object-fit: cover; }
.card-media .pill { position: absolute; top: 12px; left: 12px; }
.card-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.card-body h3 { font-size: 17px; margin: 0; line-height: 1.3; }
.card-body p { color: var(--muted); font-size: 14px; margin: 0; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.card-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 13px; color: var(--muted); margin-top: auto; padding-top: 8px; }
.card-meta span { display: inline-flex; align-items: center; gap: 4px; }
.card-book .card-media { aspect-ratio: 3 / 4; }

.row-list { display: grid; gap: 12px; }
.row-item { display: flex; gap: 16px; align-items: center; padding: 14px; border-radius: var(--r); background: #fff; border: 1px solid var(--line); color: var(--ink); transition: .2s; }
.row-item:hover { border-color: var(--lapis); color: var(--ink); box-shadow: var(--shadow); }
.row-thumb { width: 72px; height: 72px; border-radius: 12px; overflow: hidden; flex: none; background: var(--sky); }
.row-thumb img, .row-thumb .ph { width: 100%; height: 100%; object-fit: cover; }
.row-thumb .ph .ico { width: 26px; height: 26px; }
.row-item h3 { font-size: 16px; margin: 0 0 4px; }
.row-item p { margin: 0; color: var(--muted); font-size: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.row-item .go { margin-left: auto; color: var(--muted); }

/* Bento */
.bento { display: grid; grid-template-columns: 1.35fr 1fr 1fr; gap: 18px; }
.bento-main { border-radius: var(--r-lg); background: var(--slate); color: #fff; padding: 28px; display: flex; flex-direction: column; min-height: 320px; }
.bento-main h3 { color: #fff; font-size: 26px; margin-bottom: 8px; }
.bento-main p { color: rgba(255, 255, 255, .86); }
.bento-main .btn { margin-top: auto; align-self: flex-start; }
.bento-card { position: relative; border-radius: var(--r-lg); overflow: hidden; color: #fff; min-height: 320px; display: flex; flex-direction: column; justify-content: flex-end; padding: 20px; isolation: isolate; background: var(--lapis-700); }
.bento-card img, .bento-card .ph { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.bento-card::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(14, 28, 69, .1) 20%, rgba(14, 28, 69, .85)); }
.bento-card .bc-ico { position: absolute; top: 18px; left: 18px; width: 44px; height: 44px; border-radius: 50%; background: rgba(255, 255, 255, .22); display: grid; place-items: center; backdrop-filter: blur(4px); }
.bento-card h3 { color: #fff; font-size: 19px; margin: 0 0 6px; }
.bento-card p { color: rgba(255, 255, 255, .88); font-size: 13.5px; margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.bento-card:hover { color: #fff; }

/* Qadamlar 1-2-3 */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; counter-reset: step; }
.step { display: flex; gap: 16px; align-items: flex-start; }
.step-num { counter-increment: step; flex: none; width: 52px; height: 52px; display: grid; place-items: center; font-weight: 800; font-size: 20px; color: var(--lapis); position: relative; }
.step-num::before { content: counter(step); }
.step-num::after { content: ""; position: absolute; inset: 0; border: 2px solid var(--lapis); border-left-color: transparent; border-right-color: transparent; border-radius: 14px; }
.step h3 { font-size: 17px; margin: 4px 0 4px; }
.step p { color: var(--muted); font-size: 14px; margin: 0; }

/* Xronologiya (bosh sahifa) */
.dates { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(200px, 1fr); gap: 0; overflow-x: auto; scrollbar-width: thin; position: relative; padding: 6px 0 4px; }
.date-item { position: relative; padding: 34px 18px 0 0; color: var(--ink); display: block; }
.date-item::before { content: ""; position: absolute; top: 14px; left: 0; right: 0; height: 2px; background: var(--line-2); }
.date-item::after { content: ""; position: absolute; top: 8px; left: 0; width: 14px; height: 14px; border-radius: 50%; background: #fff; border: 3px solid var(--gold); }
.date-item:hover::after { background: var(--gold); }
.date-year { font-size: 26px; font-weight: 800; color: var(--lapis); letter-spacing: -.02em; }
.date-item h3 { font-size: 15px; margin: 4px 0; line-height: 1.35; }
.date-item p { font-size: 13px; color: var(--muted); margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* AI blok (bosh sahifa) */
.ai-cta { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: center; }
.ai-cta form { display: flex; gap: 8px; background: #fff; border-radius: 999px; padding: 6px; }
.ai-cta input { flex: 1; border: 0; padding: 0 16px; font: inherit; min-width: 0; outline: none; }
.ai-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.ai-chips a { padding: 6px 12px; border-radius: 999px; background: rgba(255, 255, 255, .1); color: #fff; font-size: 13px; border: 1px solid rgba(255, 255, 255, .2); }
.ai-chips a:hover { background: rgba(255, 255, 255, .2); color: #fff; }

/* Statistika */
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.stat-tile { background: #fff; border-radius: var(--r-lg); padding: 20px; border: 1px solid var(--line); display: flex; gap: 14px; align-items: center; }
.stat-tile .stat-circle { margin: 0; flex: none; }
.stat-tile .stat-num { font-size: 24px; }

.mini-map { height: 380px; border-radius: var(--r-lg); overflow: hidden; background: var(--sky); }
.empty { text-align: center; padding: 48px 20px; color: var(--muted); background: var(--sky-50); border-radius: var(--r-lg); border: 1px dashed var(--line-2); }
.empty .ico { width: 40px; height: 40px; color: var(--lapis); opacity: .6; margin-bottom: 8px; }

/* ---------- Ichki sahifalar ---------- */
.page-hero { padding: 12px 0 0; }
.page-hero-box { border-radius: var(--r-xl); background: linear-gradient(150deg, var(--lapis) 0%, var(--lapis-900) 100%); color: #fff; padding: clamp(28px, 5vw, 56px); position: relative; overflow: hidden; isolation: isolate; }
.page-hero-box::after { content: ""; position: absolute; right: -60px; bottom: -120px; width: 320px; height: 320px; border-radius: 50%; background: radial-gradient(circle, rgba(232, 163, 61, .85) 0 38%, rgba(232, 163, 61, .25) 39% 55%, transparent 56%); z-index: -1; }
.page-hero-box h1 { color: #fff; margin: 0 0 10px; max-width: 820px; }
.page-hero-box p { color: rgba(255, 255, 255, .88); max-width: 680px; margin: 0; font-size: 16px; }
.page-hero-box .hero-actions { margin-top: 20px; }
.crumbs { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 13px; color: rgba(255, 255, 255, .75); margin-bottom: 14px; }
.crumbs a { color: rgba(255, 255, 255, .9); }
.crumbs a:hover { color: #fff; text-decoration: underline; }
.crumbs .sep { opacity: .5; }
.crumbs-dark { color: var(--muted); }
.crumbs-dark a { color: var(--ink-2); }

.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 14px; background: var(--sky-50); border-radius: var(--r-lg); margin-bottom: 24px; }
.filters .grow { flex: 1 1 220px; }
.filters input, .filters select { height: 42px; border: 1px solid var(--line); border-radius: 999px; padding: 0 16px; font: inherit; font-size: 14px; background: #fff; color: var(--ink); min-width: 0; }
.filters input.year { width: 96px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line); color: var(--ink-2); font-size: 14px; background: #fff; }
.chip:hover { border-color: var(--lapis); color: var(--lapis); }
.chip.on { background: var(--lapis); border-color: var(--lapis); color: #fff; }
.chip small { opacity: .7; }
.result-line { color: var(--muted); font-size: 14px; margin-bottom: 14px; }

.pager { display: flex; justify-content: center; gap: 6px; margin-top: 36px; flex-wrap: wrap; }
.pager a, .pager span { min-width: 40px; height: 40px; display: inline-grid; place-items: center; padding: 0 10px; border-radius: 999px; border: 1px solid var(--line); color: var(--ink); font-size: 14px; }
.pager a:hover { border-color: var(--lapis); color: var(--lapis); }
.pager .on { background: var(--ink); color: #fff; border-color: var(--ink); }

/* Material sahifasi */
.item-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 40px; align-items: start; }
.item-main { min-width: 0; }
.item-aside { position: sticky; top: calc(var(--header-h) + 20px); display: grid; gap: 16px; }
.box { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); padding: 20px; }
.box h3 { font-size: 16px; margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.box-soft { background: var(--sky-50); border-color: transparent; }
.box-cream { background: var(--cream); border-color: transparent; }
.meta-list { display: grid; grid-template-columns: auto 1fr; gap: 8px 14px; font-size: 14px; margin: 0; }
.meta-list dt { color: var(--muted); }
.meta-list dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }
.item-cover { border-radius: var(--r-lg); overflow: hidden; margin-bottom: 28px; background: var(--sky); }
.item-cover img { width: 100%; max-height: 560px; object-fit: cover; }
.item-cover figcaption { padding: 10px 14px; font-size: 13px; color: var(--muted); background: var(--sky-50); }
.lead { font-size: 19px; line-height: 1.6; color: var(--ink-2); font-family: var(--serif); margin-bottom: 24px; }
.prose { font-family: var(--serif); font-size: 18px; line-height: 1.8; color: #262B39; overflow-wrap: break-word; }
.prose h2, .prose h3, .prose h4 { font-family: var(--font); margin: 1.6em 0 .6em; }
.prose h2 { font-size: 26px; }
.prose h3 { font-size: 21px; }
.prose p { margin: 0 0 1.1em; }
.prose a { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.prose img { border-radius: var(--r); margin: 1.4em auto; }
.prose figure { margin: 1.6em 0; }
.prose figcaption { font-family: var(--font); font-size: 14px; color: var(--muted); text-align: center; margin-top: 8px; }
.prose blockquote { margin: 1.6em 0; padding: 18px 22px; border-left: 4px solid var(--gold); background: var(--cream); border-radius: 0 var(--r) var(--r) 0; font-style: italic; }
.prose blockquote p:last-child { margin: 0; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.1em; }
.prose li { margin-bottom: .35em; }
.prose table { width: 100%; border-collapse: collapse; font-family: var(--font); font-size: 15px; margin: 1.4em 0; display: block; overflow-x: auto; }
.prose th, .prose td { border: 1px solid var(--line); padding: 10px 12px; text-align: left; vertical-align: top; }
.prose th { background: var(--sky-50); }
.prose iframe { width: 100%; aspect-ratio: 16 / 9; height: auto; border: 0; border-radius: var(--r); }
.prose .footnote, .prose sup[data-note] { color: var(--lapis); cursor: help; font-family: var(--font); font-size: .7em; font-weight: 700; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2em 0; }
.prose [dir="rtl"], .arabic { font-family: var(--arabic); direction: rtl; text-align: right; font-size: 1.15em; line-height: 2; }
.footnotes { margin-top: 32px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 14px; color: var(--ink-2); }
.footnotes ol { padding-left: 1.2em; }

.notice { display: flex; gap: 10px; align-items: flex-start; padding: 12px 16px; border-radius: var(--r); background: var(--cream); color: var(--gold-700); font-size: 14px; margin-bottom: 20px; }
.notice-blue { background: var(--info-bg); color: var(--lapis-700); }
.sub-h { display: flex; align-items: center; gap: 10px; font-size: 20px; margin: 40px 0 16px; }
.sub-h .ico { color: var(--gold-600); }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
.gallery a { display: block; border-radius: var(--r-sm); overflow: hidden; aspect-ratio: 1; background: var(--sky); }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s; }
.gallery a:hover img { transform: scale(1.05); }
.files { display: grid; gap: 8px; }
.file-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: var(--r); border: 1px solid var(--line); background: #fff; color: var(--ink); }
.file-row:hover { border-color: var(--lapis); color: var(--ink); }
.file-ico { width: 40px; height: 40px; border-radius: 10px; background: var(--sky); color: var(--lapis); display: grid; place-items: center; flex: none; }
.file-row b { display: block; font-size: 14.5px; font-weight: 600; overflow-wrap: anywhere; }
.file-row small { color: var(--muted); font-size: 12.5px; }
.file-row .acts { margin-left: auto; display: flex; gap: 6px; }
.sources { font-size: 14.5px; color: var(--ink-2); padding-left: 1.3em; }
.sources li { margin-bottom: 6px; overflow-wrap: anywhere; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { padding: 4px 10px; border-radius: 999px; background: var(--sky-50); color: var(--lapis-700); font-size: 13px; }
.tag:hover { background: var(--sky); }
.embed { position: relative; aspect-ratio: 16 / 9; border-radius: var(--r-lg); overflow: hidden; background: #000; margin-bottom: 12px; }
.embed iframe, .embed video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
audio.audio { width: 100%; margin: 8px 0; }
.share-row { display: flex; gap: 8px; flex-wrap: wrap; }

/* Iqtibos/bibliografiya */
.cite-tabs { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 10px; }
.cite-tabs button { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: #fff; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.cite-tabs button.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.cite-text { font-size: 14px; line-height: 1.55; background: var(--sky-50); padding: 12px; border-radius: var(--r-sm); overflow-wrap: anywhere; font-family: var(--serif); }
.cite-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.cite-actions a, .cite-actions button { font-size: 13px; }

/* Zamonaviy dunyo: tarixiy fikr va tahlil */
.quote-block { background: var(--cream); border-radius: var(--r-lg); padding: 26px 28px; position: relative; margin-bottom: 28px; border: 1px solid var(--cream-200); }
.quote-block .label { display: inline-flex; gap: 6px; align-items: center; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--gold-700); margin-bottom: 10px; }
.quote-block blockquote { margin: 0; font-family: var(--serif); font-size: 21px; line-height: 1.6; font-style: italic; color: var(--ink); }
.quote-block .src { margin-top: 12px; font-size: 14px; color: var(--muted); }
.analysis-label { display: flex; gap: 10px; align-items: flex-start; padding: 12px 16px; border-radius: var(--r); background: var(--sky-50); font-size: 14px; color: var(--lapis-700); margin-bottom: 20px; }

/* ---------- Arxiv: taqqoslash ko'rinishi ---------- */
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: #fff; margin-bottom: 32px; }
.compare.fs { position: fixed; inset: 0; z-index: 200; border-radius: 0; }
.compare-pane { display: flex; flex-direction: column; min-width: 0; min-height: 560px; }
.compare-pane + .compare-pane { border-left: 1px solid var(--line); }
.pane-bar { display: flex; align-items: center; gap: 6px; padding: 8px 10px; background: var(--sky-50); border-bottom: 1px solid var(--line); flex-wrap: wrap; min-height: 54px; }
.pane-bar .ttl { font-weight: 600; font-size: 14px; margin-right: auto; padding-left: 4px; }
.tool { width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line); background: #fff; display: inline-grid; place-items: center; color: var(--ink-2); }
.tool:hover { border-color: var(--lapis); color: var(--lapis); }
.tool .ico { width: 18px; height: 18px; }
.pg-ind { font-size: 13px; color: var(--muted); padding: 0 6px; white-space: nowrap; }
.img-stage { position: relative; flex: 1; overflow: hidden; background: #2A2F3D; cursor: grab; touch-action: none; min-height: 480px; }
.img-stage.dragging { cursor: grabbing; }
.img-stage img { position: absolute; left: 50%; top: 50%; max-width: none; transform-origin: center center; user-select: none; -webkit-user-drag: none; }
.text-stage { flex: 1; overflow: auto; padding: 22px 26px; max-height: 70vh; }
.compare.fs .text-stage { max-height: none; }
.text-tabs { display: flex; gap: 4px; }
.text-tabs button { border: 0; background: transparent; padding: 7px 12px; border-radius: 8px; font-size: 13px; font-weight: 600; color: var(--muted); }
.text-tabs button.on { background: #fff; color: var(--lapis); box-shadow: 0 1px 2px rgba(0, 0, 0, .06); }
.arabic-auto { font-family: var(--arabic), var(--serif); font-size: 1.12em; line-height: 2.05; }
.thumbs { display: flex; gap: 6px; overflow-x: auto; padding: 8px; background: var(--sky-50); border-top: 1px solid var(--line); }
.thumbs button { flex: none; width: 52px; height: 66px; border-radius: 6px; overflow: hidden; border: 2px solid transparent; padding: 0; background: #ddd; }
.thumbs button.on { border-color: var(--gold); }
.thumbs img { width: 100%; height: 100%; object-fit: cover; }

/* PDF ko'ruvchi */
.pdfv { border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: #fff; margin-bottom: 24px; }
.pdfv.fs { position: fixed; inset: 0; z-index: 200; border-radius: 0; display: flex; flex-direction: column; }
.pdfv-stage { background: #E9ECF2; height: 72vh; overflow: auto; position: relative; }
.pdfv.fs .pdfv-stage { height: auto; flex: 1; }
.pdfv-page { position: relative; margin: 16px auto; box-shadow: 0 2px 10px rgba(0, 0, 0, .15); background: #fff; }
.pdfv-page canvas { display: block; }
.textLayer { position: absolute; inset: 0; overflow: hidden; opacity: 1; line-height: 1; text-size-adjust: none; forced-color-adjust: none; transform-origin: 0 0; z-index: 2; }
.textLayer span, .textLayer br { color: transparent; position: absolute; white-space: pre; cursor: text; transform-origin: 0% 0%; }
.textLayer ::selection { background: rgba(31, 58, 138, .3); }
.pdfv input.pg { width: 56px; height: 34px; border: 1px solid var(--line); border-radius: 8px; text-align: center; font: inherit; font-size: 14px; }

/* ---------- Xronologiya sahifasi ---------- */
.tl-years { display: flex; gap: 6px; overflow-x: auto; padding: 4px 0 14px; position: sticky; top: var(--header-h); background: #fff; z-index: 5; scrollbar-width: thin; }
.tl-years a { flex: none; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); color: var(--ink-2); font-weight: 600; font-size: 14px; }
.tl-years a:hover, .tl-years a.on { background: var(--lapis); color: #fff; border-color: var(--lapis); }
.timeline { position: relative; padding-left: 0; }
.timeline::before { content: ""; position: absolute; left: 120px; top: 0; bottom: 0; width: 2px; background: linear-gradient(var(--gold), var(--lapis)); border-radius: 2px; }
.tl-group { display: grid; grid-template-columns: 120px 1fr; gap: 0 36px; margin-bottom: 26px; }
.tl-year { font-size: 30px; font-weight: 800; color: var(--lapis); letter-spacing: -.03em; text-align: right; padding-right: 26px; position: sticky; top: calc(var(--header-h) + 70px); align-self: start; line-height: 1.2; }
.tl-events { display: grid; gap: 12px; }
.tl-event { position: relative; display: block; text-align: left; width: 100%; padding: 18px 20px; border-radius: var(--r-lg); background: #fff; border: 1px solid var(--line); color: var(--ink); cursor: pointer; transition: .2s; font: inherit; }
.tl-event::before { content: ""; position: absolute; left: -44px; top: 22px; width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 3px solid var(--gold); }
.tl-event:hover { border-color: var(--lapis); box-shadow: var(--shadow); color: var(--ink); }
.tl-event:hover::before { background: var(--gold); }
.tl-event .when { font-size: 13px; font-weight: 600; color: var(--gold-700); }
.tl-event h3 { font-size: 17px; margin: 2px 0 6px; }
.tl-event p { margin: 0; color: var(--muted); font-size: 14.5px; }
.tl-event .tl-thumbs { display: flex; gap: 6px; margin-top: 10px; }
.tl-event .tl-thumbs img { width: 56px; height: 56px; border-radius: 8px; object-fit: cover; }

/* ---------- Xarita ---------- */
.map-layout { display: grid; grid-template-columns: 340px 1fr; gap: 0; border-radius: var(--r-xl); overflow: hidden; border: 1px solid var(--line); height: min(78vh, 760px); min-height: 520px; background: #fff; }
.map-side { display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line); }
.map-side-head { padding: 14px; border-bottom: 1px solid var(--line); display: grid; gap: 8px; }
.map-side-head select, .map-side-head input { height: 40px; border: 1px solid var(--line); border-radius: 999px; padding: 0 14px; font: inherit; font-size: 14px; }
.map-list { overflow: auto; flex: 1; padding: 8px; }
.map-list button { display: flex; gap: 10px; width: 100%; text-align: left; padding: 10px; border-radius: 12px; border: 0; background: transparent; color: var(--ink); align-items: center; }
.map-list button:hover, .map-list button.on { background: var(--sky-50); }
.map-list .num { width: 30px; height: 30px; border-radius: 50%; background: var(--lapis); color: #fff; display: grid; place-items: center; font-size: 13px; font-weight: 700; flex: none; }
.map-list b { display: block; font-size: 14.5px; }
.map-list small { color: var(--muted); font-size: 12.5px; }
.map-canvas { position: relative; min-height: 0; }
#map { position: absolute; inset: 0; }
.map-detail { position: absolute; right: 14px; top: 14px; bottom: 14px; width: min(380px, calc(100% - 28px)); background: #fff; border-radius: var(--r-lg); box-shadow: var(--shadow-lg); z-index: 500; overflow: auto; padding: 0 0 18px; }
.map-detail .md-cover { aspect-ratio: 16 / 9; background: var(--sky); }
.map-detail .md-cover img { width: 100%; height: 100%; object-fit: cover; }
.map-detail .md-body { padding: 16px 18px 0; }
.map-detail .md-close { position: absolute; right: 10px; top: 10px; z-index: 2; }
.map-detail h2 { font-size: 22px; margin-bottom: 6px; }
.map-detail .prose { font-size: 15.5px; line-height: 1.65; }
.map-pin { width: 34px; height: 34px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); background: var(--lapis); border: 3px solid #fff; box-shadow: 0 4px 12px rgba(14, 28, 69, .35); display: grid; place-items: center; }
.map-pin span { transform: rotate(45deg); color: #fff; font-size: 12px; font-weight: 700; }
.map-pin.on { background: var(--gold); }
.map-pin.on span { color: var(--ink); }
.leaflet-tile-pane { filter: saturate(.75) sepia(.12); }
.leaflet-container { font-family: var(--font); }

/* ---------- Muzey ---------- */
.museum-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.room-card { position: relative; border-radius: var(--r-xl); overflow: hidden; min-height: 300px; display: flex; flex-direction: column; justify-content: flex-end; padding: 26px; color: #fff; isolation: isolate; }
.room-card img, .room-card .ph { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.room-card::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(14, 28, 69, .05), rgba(14, 28, 69, .85)); }
.room-card .room-n { position: absolute; top: 20px; left: 22px; font-size: 13px; font-weight: 700; letter-spacing: .08em; color: var(--gold); }
.room-card h3 { color: #fff; font-size: 24px; margin-bottom: 6px; }
.room-card p { color: rgba(255, 255, 255, .88); margin: 0; font-size: 14.5px; max-width: 480px; }
.room-card:hover { color: #fff; }
.exhibits { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
.exhibit { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; }
.exhibit .ex-media { aspect-ratio: 4 / 3; background: var(--cream); display: grid; place-items: center; cursor: zoom-in; }
.exhibit .ex-media img { width: 100%; height: 100%; object-fit: contain; }
.exhibit .ex-body { padding: 14px 16px; }
.exhibit h3 { font-size: 16px; margin: 0 0 4px; }
.exhibit p { font-size: 14px; color: var(--muted); margin: 0; }

.museum3d { position: fixed; inset: 0; z-index: 300; background: #0b1124; color: #fff; }
.museum3d canvas { display: block; width: 100%; height: 100%; touch-action: none; }
.m3-top { position: absolute; top: 0; left: 0; right: 0; display: flex; align-items: center; gap: 12px; padding: 14px 18px; background: linear-gradient(180deg, rgba(11, 17, 36, .85), transparent); pointer-events: none; }
.m3-top > * { pointer-events: auto; }
.m3-title { font-weight: 700; font-size: 17px; margin-right: auto; }
.m3-title small { display: block; font-weight: 500; font-size: 13px; color: rgba(255, 255, 255, .75); }
.m3-rooms { position: absolute; left: 18px; bottom: 18px; display: flex; gap: 6px; flex-wrap: wrap; max-width: calc(100% - 200px); }
.m3-rooms button { padding: 7px 12px; border-radius: 999px; background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .25); color: #fff; font-size: 13px; backdrop-filter: blur(6px); }
.m3-rooms button.on { background: var(--gold); color: var(--ink); border-color: var(--gold); }
.m3-help { position: absolute; left: 50%; bottom: 72px; transform: translateX(-50%); background: rgba(11, 17, 36, .7); padding: 8px 14px; border-radius: 999px; font-size: 13px; white-space: nowrap; max-width: 92vw; overflow: hidden; text-overflow: ellipsis; }
.m3-pad { position: absolute; right: 18px; bottom: 18px; display: grid; grid-template-columns: repeat(3, 48px); grid-template-rows: repeat(2, 48px); gap: 6px; }
.m3-pad button { border-radius: 12px; background: rgba(255, 255, 255, .16); border: 1px solid rgba(255, 255, 255, .25); color: #fff; display: grid; place-items: center; touch-action: none; user-select: none; }
.m3-pad button:active { background: rgba(232, 163, 61, .6); }
.m3-pad .up { grid-column: 2; }
.m3-pad .left { grid-column: 1; grid-row: 2; }
.m3-pad .down { grid-column: 2; grid-row: 2; }
.m3-pad .right { grid-column: 3; grid-row: 2; }
.m3-loading { position: absolute; inset: 0; display: grid; place-items: center; font-size: 16px; background: #0b1124; }
.m3-cross { position: absolute; left: 50%; top: 50%; width: 6px; height: 6px; margin: -3px 0 0 -3px; border-radius: 50%; background: rgba(255, 255, 255, .7); pointer-events: none; }

/* ---------- Tarmoq ---------- */
.network-box { height: min(75vh, 720px); min-height: 480px; border-radius: var(--r-xl); border: 1px solid var(--line); background: radial-gradient(circle at 50% 40%, #fff, var(--sky-50)); overflow: hidden; position: relative; }
#network { position: absolute; inset: 0; }
.network-legend { position: absolute; left: 14px; bottom: 14px; background: #fff; border-radius: 12px; padding: 10px 14px; font-size: 13px; box-shadow: var(--shadow); max-width: 280px; z-index: 2; }

/* ---------- Shaxs ---------- */
.person-head { display: grid; grid-template-columns: 220px 1fr; gap: 32px; align-items: center; margin-bottom: 32px; }
.person-photo { border-radius: var(--r-xl); overflow: hidden; aspect-ratio: 3 / 4; background: var(--cream); }
.person-photo img, .person-photo .ph { width: 100%; height: 100%; object-fit: cover; }
.person-years { font-size: 18px; color: var(--gold-700); font-weight: 600; }
.person-card { text-align: center; color: var(--ink); }
.person-card .pc-photo { aspect-ratio: 3 / 4; border-radius: var(--r-lg); overflow: hidden; background: var(--cream); margin-bottom: 10px; }
.person-card .pc-photo img, .person-card .pc-photo .ph { width: 100%; height: 100%; object-fit: cover; }
.person-card h3 { font-size: 16px; margin: 0 0 2px; }
.person-card small { color: var(--muted); }
.person-card:hover { color: var(--lapis); }

/* ---------- Qidiruv ---------- */
.search-big { display: flex; gap: 8px; background: #fff; border-radius: 999px; padding: 6px; max-width: 720px; margin-top: 20px; }
.search-big input { flex: 1; border: 0; padding: 0 18px; font: inherit; font-size: 16px; outline: none; min-width: 0; border-radius: 999px; }
.search-layout { display: grid; grid-template-columns: 260px 1fr; gap: 32px; }
.search-side { display: grid; gap: 4px; align-content: start; }
.search-side a { display: flex; justify-content: space-between; padding: 9px 12px; border-radius: 10px; color: var(--ink-2); font-size: 14.5px; }
.search-side a:hover, .search-side a.on { background: var(--sky-50); color: var(--lapis); }
.search-side a span { color: var(--muted); font-size: 13px; }
.hit { padding: 16px 0; border-bottom: 1px solid var(--line); }
.hit .hit-type { font-size: 12.5px; font-weight: 600; color: var(--gold-700); text-transform: uppercase; letter-spacing: .05em; }
.hit h3 { font-size: 18px; margin: 4px 0; }
.hit p { margin: 0; color: var(--muted); font-size: 14.5px; }
.hit mark { background: var(--gold-100); color: inherit; padding: 0 2px; border-radius: 3px; }
.photo-hits { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin-bottom: 24px; }
.photo-hits a { aspect-ratio: 1; border-radius: 10px; overflow: hidden; }
.photo-hits img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- AI chat ---------- */
.ai-page { display: grid; grid-template-columns: 260px 1fr; gap: 24px; min-height: calc(100vh - var(--header-h) - 60px); padding: 20px 0 40px; }
.ai-side { background: var(--sky-50); border-radius: var(--r-lg); padding: 14px; display: flex; flex-direction: column; gap: 8px; align-self: start; position: sticky; top: calc(var(--header-h) + 16px); max-height: calc(100vh - var(--header-h) - 40px); overflow: auto; }
.ai-side a.chat-link { display: block; padding: 9px 12px; border-radius: 10px; color: var(--ink-2); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ai-side a.chat-link:hover, .ai-side a.chat-link.on { background: #fff; color: var(--lapis); }
.ai-main { display: flex; flex-direction: column; min-width: 0; border: 1px solid var(--line); border-radius: var(--r-xl); overflow: hidden; background: #fff; min-height: 70vh; }
.ai-head { padding: 20px 24px; background: linear-gradient(150deg, var(--lapis), var(--lapis-900)); color: #fff; display: flex; gap: 14px; align-items: center; }
.ai-head h1 { font-size: 22px; color: #fff; margin: 0; }
.ai-head p { margin: 2px 0 0; font-size: 14px; color: rgba(255, 255, 255, .85); }
.ai-avatar { width: 46px; height: 46px; border-radius: 14px; background: var(--cream); display: grid; place-items: center; flex: none; }
.ai-avatar .logo-mark { width: 30px; height: 31px; }
.ai-log { flex: 1; overflow: auto; padding: 24px; display: flex; flex-direction: column; gap: 18px; background: #FAFBFD; }
.msg { max-width: 820px; display: flex; gap: 12px; }
.msg-user { align-self: flex-end; flex-direction: row-reverse; }
.msg-bubble { padding: 14px 18px; border-radius: 18px; background: #fff; border: 1px solid var(--line); font-size: 15.5px; line-height: 1.65; min-width: 0; overflow-wrap: anywhere; }
.msg-user .msg-bubble { background: var(--lapis); color: #fff; border-color: var(--lapis); border-bottom-right-radius: 6px; }
.msg-ai .msg-bubble { border-bottom-left-radius: 6px; }
.msg-bubble p:last-child, .msg-bubble ul:last-child { margin-bottom: 0; }
.msg-bubble ul { padding-left: 1.2em; margin: 0 0 1em; }
.msg-ai .ai-avatar { width: 36px; height: 36px; border-radius: 12px; }
.msg-ai .ai-avatar .logo-mark { width: 22px; height: 23px; }
.cite-ref { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 6px; background: var(--gold-100); color: var(--gold-700); font-size: 12px; font-weight: 700; vertical-align: 2px; margin: 0 1px; text-decoration: none !important; }
.cite-ref:hover { background: var(--gold); color: var(--ink); }
.msg-sources { margin-top: 12px; padding-top: 10px; border-top: 1px dashed var(--line-2); display: grid; gap: 4px; font-size: 13.5px; }
.msg-sources b { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.msg-sources a { display: flex; gap: 8px; color: var(--ink-2); }
.msg-sources a:hover { color: var(--lapis); }
.msg-sources a span { color: var(--gold-700); font-weight: 700; }
.typing { display: inline-flex; gap: 4px; align-items: center; color: var(--muted); font-size: 14px; }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--lapis); animation: blink 1.2s infinite; }
.typing i:nth-child(2) { animation-delay: .2s; }
.typing i:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 0%, 80%, 100% { opacity: .2; } 40% { opacity: 1; } }
.ai-form { display: flex; gap: 10px; padding: 16px; border-top: 1px solid var(--line); background: #fff; align-items: flex-end; }
.ai-form textarea { flex: 1; resize: none; border: 1px solid var(--line); border-radius: 16px; padding: 12px 16px; font: inherit; min-height: 50px; max-height: 180px; outline: none; }
.ai-form textarea:focus { border-color: var(--lapis); }
.ai-form .btn { height: 50px; width: 50px; padding: 0; border-radius: 50%; }
.ai-note { font-size: 12.5px; color: var(--muted); text-align: center; padding: 0 16px 12px; }
.ai-welcome { margin: auto; text-align: center; max-width: 560px; padding: 20px; }
.ai-welcome .ai-chips a { background: var(--sky-50); color: var(--ink-2); border-color: var(--line); }

/* ---------- Formalar ---------- */
.form-card { background: #fff; border: 1px solid var(--line); border-radius: var(--r-xl); padding: clamp(20px, 4vw, 36px); }
.auth-wrap { max-width: 460px; margin: 40px auto 72px; }
.auth-wrap h1 { font-size: 30px; text-align: center; }
.field { display: grid; gap: 6px; margin-bottom: 16px; }
.field label, .field .lbl { font-size: 14px; font-weight: 600; color: var(--ink-2); }
.field small, .help { color: var(--muted); font-size: 13px; }
.field input[type=text], .field input[type=email], .field input[type=password], .field input[type=tel], .field input[type=number], .field input[type=url], .field select, .field textarea, .field input[type=file] {
  width: 100%; border: 1px solid var(--line-2); border-radius: 12px; padding: 11px 14px; font: inherit; font-size: 15px; color: var(--ink); background: #fff; }
.field textarea { min-height: 120px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--lapis); box-shadow: 0 0 0 3px rgba(31, 58, 138, .12); }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; margin-bottom: 12px; cursor: pointer; }
.check input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--lapis); flex: none; }
.radio-row { display: flex; flex-wrap: wrap; gap: 8px; }
.radio-row label { display: inline-flex; gap: 6px; align-items: center; padding: 8px 14px; border: 1px solid var(--line-2); border-radius: 999px; font-size: 14px; cursor: pointer; }
.radio-row input { accent-color: var(--lapis); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.hp { position: absolute; left: -9999px; opacity: 0; }
.form-foot { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-top: 8px; font-size: 14px; }

/* Kabinet */
.cab-layout { display: grid; grid-template-columns: 240px 1fr; gap: 28px; padding: 32px 0 64px; }
.cab-nav { display: grid; gap: 4px; align-content: start; }
.cab-nav a, .cab-nav button { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 12px; color: var(--ink-2); font-size: 15px; background: none; border: 0; text-align: left; width: 100%; }
.cab-nav a:hover, .cab-nav a.on { background: var(--sky-50); color: var(--lapis); }
.progress { height: 8px; border-radius: 999px; background: var(--sky); overflow: hidden; }
.progress i { display: block; height: 100%; background: linear-gradient(90deg, var(--lapis), var(--gold)); border-radius: 999px; }
.table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.table th, .table td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.table th { color: var(--muted); font-weight: 600; font-size: 13px; }
.table-wrap { overflow-x: auto; }
.badge { display: inline-block; padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 600; background: var(--sky); color: var(--lapis-700); }
.badge-ok { background: var(--ok-bg); color: var(--ok); }
.badge-warn { background: var(--warn-bg); color: var(--warn); }
.badge-err { background: var(--err-bg); color: var(--err); }

/* Akademiya */
.course-card .card-media { aspect-ratio: 16 / 9; }
.lesson-list { display: grid; gap: 8px; }
.lesson-row { display: flex; gap: 14px; align-items: center; padding: 14px 16px; border-radius: var(--r); border: 1px solid var(--line); color: var(--ink); background: #fff; }
.lesson-row:hover { border-color: var(--lapis); color: var(--ink); }
.lesson-row .n { width: 34px; height: 34px; border-radius: 50%; background: var(--sky); color: var(--lapis); display: grid; place-items: center; font-weight: 700; font-size: 14px; flex: none; }
.lesson-row.done .n { background: var(--ok); color: #fff; }
.lesson-row .end { margin-left: auto; color: var(--muted); font-size: 13px; display: flex; gap: 8px; align-items: center; }
.quiz-q { padding: 20px; border: 1px solid var(--line); border-radius: var(--r-lg); margin-bottom: 14px; background: #fff; }
.quiz-q h3 { font-size: 17px; }
.quiz-opt { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line); margin-bottom: 8px; cursor: pointer; }
.quiz-opt:hover { border-color: var(--lapis); }
.quiz-opt input { margin-top: 4px; accent-color: var(--lapis); }
.quiz-opt.right { border-color: var(--ok); background: var(--ok-bg); }
.quiz-opt.wrong { border-color: var(--err); background: var(--err-bg); }
.quiz-timer { position: sticky; top: calc(var(--header-h) + 10px); z-index: 4; display: inline-flex; gap: 8px; align-items: center; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 999px; font-weight: 700; margin-bottom: 14px; }
.certificate { max-width: 900px; margin: 0 auto; background: var(--cream); border-radius: 18px; padding: 48px; text-align: center; position: relative; border: 12px solid #fff; outline: 2px solid var(--gold); box-shadow: var(--shadow-lg); }
.certificate .logo-mark { width: 64px; height: 66px; margin: 0 auto 10px; }
.certificate h1 { font-size: 40px; color: var(--lapis); letter-spacing: .02em; }
.certificate .cert-name { font-family: var(--serif); font-size: 34px; color: var(--ink); margin: 18px 0 8px; font-style: italic; }
.certificate .cert-course { font-size: 20px; font-weight: 600; }
.certificate .cert-meta { display: flex; justify-content: space-between; margin-top: 36px; font-size: 14px; color: var(--muted); gap: 16px; flex-wrap: wrap; }

/* Modal */
.modal { position: fixed; inset: 0; z-index: 400; display: grid; place-items: center; padding: 20px; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(14, 28, 69, .55); backdrop-filter: blur(3px); }
.modal-box { position: relative; background: #fff; border-radius: var(--r-xl); width: min(860px, 100%); max-height: calc(100vh - 40px); overflow: auto; box-shadow: var(--shadow-lg); }
.modal-close { position: sticky; float: right; top: 12px; right: 12px; margin: 12px 12px 0 0; z-index: 3; }
.modal-body { padding: 28px clamp(20px, 4vw, 36px) 32px; }
.modal-body .prose { font-size: 16.5px; }
.modal.lightbox .modal-box { background: transparent; box-shadow: none; width: auto; max-width: 96vw; }
.modal.lightbox .modal-body { padding: 0; }
.modal.lightbox img { max-height: 86vh; width: auto; border-radius: 12px; margin: 0 auto; }
.modal.lightbox .lb-cap { color: #fff; text-align: center; padding: 10px; font-size: 14px; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 10px 18px; border-radius: 999px; z-index: 500; font-size: 14px; box-shadow: var(--shadow-lg); }

/* Futer */
.site-footer { background: var(--lapis-900); color: rgba(251, 243, 228, .82); margin-top: 40px; padding: 56px 0 24px; }
.site-footer a { color: rgba(251, 243, 228, .82); }
.site-footer a:hover { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 32px; }
.site-footer h3 { color: var(--gold); font-size: 13px; text-transform: uppercase; letter-spacing: .1em; margin-bottom: 14px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; font-size: 14.5px; }
.brand-light, .brand-light:hover { color: #fff; }
.brand-light .brand-text i { color: var(--gold); }
.footer-slogan { font-family: var(--serif); font-style: italic; color: var(--gold); font-size: 17px; margin: 14px 0 6px; }
.footer-about { font-size: 14px; max-width: 360px; }
.contacts li { display: flex; gap: 8px; align-items: center; }
.footer-bottom { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 40px; padding-top: 20px; border-top: 1px solid rgba(251, 243, 228, .14); font-size: 13px; color: rgba(251, 243, 228, .6); }

.err-page { text-align: center; padding: 80px 0; }
.err-page .code { font-size: clamp(80px, 18vw, 160px); font-weight: 800; color: var(--lapis); line-height: 1; letter-spacing: -.05em; }

/* ---------- Moslashuvchanlik ---------- */
@media (max-width: 1180px) {
  .main-nav a:nth-child(n+4) { display: none; }
  .header-search { max-width: 260px; }
}
@media (max-width: 1024px) {
  :root { --header-h: 64px; }
  .main-nav, .header-search { display: none; }
  .header-actions { margin-left: auto; }
  .burger { display: inline-grid; }
  .mega-search { display: flex; }
  .mega-grid { grid-template-columns: repeat(2, 1fr); }
  .cards { grid-template-columns: repeat(3, 1fr); }
  .scroller { grid-auto-columns: calc((100% - 36px) / 3); }
  .about-grid, .ai-cta { grid-template-columns: 1fr; }
  .bento { grid-template-columns: 1fr 1fr; }
  .bento-main { grid-column: 1 / -1; min-height: 220px; }
  .item-layout { grid-template-columns: 1fr; }
  .item-aside { position: static; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .map-layout { grid-template-columns: 1fr; height: auto; }
  .map-side { border-right: 0; border-bottom: 1px solid var(--line); max-height: 260px; }
  .map-canvas { height: 60vh; min-height: 420px; }
  .search-layout, .ai-page, .cab-layout { grid-template-columns: 1fr; }
  .ai-side { position: static; max-height: none; order: 2; }
  .ai-main { min-height: 72vh; }
  .search-side { grid-auto-flow: column; overflow-x: auto; }
  .search-side a { white-space: nowrap; gap: 8px; }
}
@media (max-width: 760px) {
  .container { padding: 0 16px; }
  .hide-sm { display: none !important; }
  .brand-text { font-size: 16px; }
  .cards, .cards-3 { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .cards-2, .museum-grid { grid-template-columns: 1fr; }
  .scroller { grid-auto-columns: 72%; gap: 12px; }
  .bento { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .stats-row { gap: 8px; }
  .stat-num { font-size: 22px; }
  .page-hero-box::after { width: 170px; height: 170px; right: -70px; bottom: -80px; opacity: .75; }
  .compare { grid-template-columns: 1fr; }
  .compare-pane + .compare-pane { border-left: 0; border-top: 1px solid var(--line); }
  .compare-pane { min-height: 0; }
  .img-stage { min-height: 380px; }
  .person-head { grid-template-columns: 1fr; }
  .person-photo { max-width: 240px; }
  .timeline::before { left: 8px; }
  .tl-group { grid-template-columns: 1fr; gap: 6px; padding-left: 34px; }
  .tl-year { text-align: left; padding: 0; position: static; font-size: 24px; }
  .tl-event::before { left: -33px; }
  .grid-2 { grid-template-columns: 1fr; }
  .photo-hits { grid-template-columns: repeat(3, 1fr); }
  .feature-card .fc-ico { width: 64px; min-height: 64px; }
  .hero-content { padding-top: 90px; }
  .hero-word { flex-direction: column; align-items: flex-start; gap: 4px; }
  .hero-word small { padding: 0; }
  .prose { font-size: 17px; }
  .certificate { padding: 28px 18px; border-width: 6px; }
  .certificate h1 { font-size: 28px; }
  .certificate .cert-name { font-size: 26px; }
  .m3-rooms { max-width: calc(100% - 36px); bottom: 136px; }
  .modal { padding: 10px; }
}
@media (max-width: 480px) {
  .mega-grid { grid-template-columns: 1fr; }
  .cards, .cards-3 { grid-template-columns: 1fr 1fr; }
  .card-body { padding: 12px; }
  .card-body h3 { font-size: 15px; }
  .card-body p { display: none; }
  .footer-grid { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: 1fr; }
  .lang-btn { padding: 0 8px; }
}
@media print {
  .site-header, .site-footer, .item-aside, .no-print, .share-row { display: none !important; }
  .item-layout { display: block; }
  body { font-size: 12pt; }
  .page-hero-box { background: none; color: #000; padding: 0; }
  .page-hero-box h1, .page-hero-box p { color: #000; }
  .page-hero-box::after { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
