/* ==========================================================================
   Public sayt dizayn tizimi — "zamonaviy minimal" uslub
   Oq fon, neytral (zinc) matn, yagona aksent — to'q zumrad (brand), o'tkir burchaklar.
   Sarlavhalar va interfeys — Inter; maqola matni — Source Serif 4.
   Ranglar Tailwind mavzusi bilan bir xil (static/js/tailwind-config.js: brand + zinc).
   Komponent klasslari shu yerda, joylashuv (grid, spacing) — shablonlarda Tailwind utility'lari bilan.
   ========================================================================== */

:root {
    --bg: #ffffff;
    --surface: #f6f7f7;
    --surface-2: #eef0f0;
    --fg: #16181b;
    --fg-2: #3c4148;
    --muted: #6b7079;
    --faint: #9aa0a8;
    --line: #e3e5e8;
    --line-soft: #eef0f2;

    --brand-50: #effaf8;
    --brand-100: #d5f2ec;
    --brand-200: #aee4da;
    --brand-300: #79cfc1;
    --brand-500: #2a9688;
    --brand: #1e786e;          /* brand-600 */
    --brand-strong: #1b6159;   /* brand-700 */
    --brand-ink: #19413d;      /* brand-900 */

    --dark: #111315;
    --dark-2: #1b1e21;

    --ok: #157a4a;
    --ok-bg: #eaf7ef;

    --radius-sm: 4px;
    --radius: 6px;
    --radius-lg: 10px;
    --shadow: 0 1px 2px rgba(17, 19, 21, .04), 0 6px 20px -10px rgba(17, 19, 21, .16);
    --shadow-lg: 0 2px 4px rgba(17, 19, 21, .04), 0 18px 40px -18px rgba(17, 19, 21, .28);

    --header-h: 64px;
    --header-total: 64px;
    --sans: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
    --serif: 'Source Serif 4', Georgia, Cambria, 'Times New Roman', serif;
}

html { scroll-padding-top: calc(var(--header-total) + 16px); }

body.site {
    font-family: var(--sans);
    background: var(--bg);
    color: var(--fg);
    font-size: 15px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    font-feature-settings: "cv11", "ss01";
}
body.site ::selection { background: var(--brand-100); color: var(--fg); }
body.site a { text-underline-offset: 3px; }

/* Ichki sahifalar kontenti header ostidan boshlanadi */
.pt-header { padding-top: calc(var(--header-total) + 2rem); }

/* Konteynerlar */
.wrap { width: 100%; max-width: 1200px; margin-inline: auto; padding-inline: 16px; }
.wrap-narrow { width: 100%; max-width: 860px; margin-inline: auto; padding-inline: 16px; }
@media (min-width: 640px) { .wrap, .wrap-narrow { padding-inline: 24px; } }
@media (min-width: 1024px) { .wrap, .wrap-narrow { padding-inline: 32px; } }

/* ---------- Tipografiya ---------- */
.font-display { font-family: var(--sans); letter-spacing: -0.022em; }
.font-serif-text { font-family: var(--serif); }

.kicker {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    font-size: .72rem;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--brand);
}
.kicker--light { color: var(--brand-300); }

.h1 {
    font-weight: 700;
    font-size: clamp(2rem, 1.35rem + 2.6vw, 3.5rem);
    line-height: 1.06;
    letter-spacing: -0.035em;
    color: var(--fg);
}
/* Uzun sarlavha (masalan, universitetning to'liq nomi ruscha) — kichikroq o'lcham */
.h1--long { font-size: clamp(1.85rem, 1.25rem + 2vw, 2.85rem); line-height: 1.1; }
.h2, .section-title {
    font-weight: 700;
    font-size: clamp(1.4rem, 1.1rem + 1vw, 1.9rem);
    line-height: 1.2;
    letter-spacing: -0.025em;
    color: var(--fg);
}
.h3 { font-weight: 650; font-size: 1.125rem; line-height: 1.35; letter-spacing: -0.015em; color: var(--fg); }
.lead { font-size: 1.075rem; line-height: 1.65; color: var(--fg-2); max-width: 44rem; }
.muted { color: var(--muted); }

.link { color: var(--brand); font-weight: 500; }
.link:hover { text-decoration: underline; }

.link-arrow {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    font-size: .875rem;
    font-weight: 600;
    color: var(--brand);
    transition: gap .2s;
}
.link-arrow:hover { gap: .6rem; }
.link-arrow svg { width: 1rem; height: 1rem; }

.title-link { color: var(--fg); transition: color .15s; }
.title-link:hover { color: var(--brand); }

.author-link { color: var(--fg-2); transition: color .15s; }
.author-link:hover { color: var(--brand); text-decoration: underline; }

/* ---------- Tugmalar ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    height: 2.5rem;
    padding: 0 1rem;
    border-radius: var(--radius);
    font-size: .875rem;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
    border: 1px solid transparent;
    transition: background-color .15s, color .15s, border-color .15s, box-shadow .15s;
    cursor: pointer;
}
.btn:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.btn svg { width: 1rem; height: 1rem; }
.btn-sm { height: 2.125rem; padding: 0 .8rem; font-size: .8125rem; }
.btn-lg { height: 3rem; padding: 0 1.4rem; font-size: .95rem; }

.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-strong); }
.btn-dark { background: var(--fg); color: #fff; }
.btn-dark:hover { background: #2c3036; }
.btn-outline { background: var(--bg); color: var(--fg); border-color: var(--line); }
.btn-outline:hover { border-color: var(--fg); }
.btn-ghost { background: transparent; color: var(--fg-2); }
.btn-ghost:hover { background: var(--surface); color: var(--fg); }
.btn-light { background: #fff; color: var(--fg); }
.btn-light:hover { background: var(--brand-50); }
.btn-ghost-light { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .28); }
.btn-ghost-light:hover { border-color: #fff; background: rgba(255, 255, 255, .06); }
.btn-danger { color: #b42318; }
.btn-danger:hover { background: #fef3f2; }
.btn-disabled, .btn[aria-disabled="true"] { background: var(--surface); color: var(--faint); border-color: var(--line); cursor: not-allowed; }

.icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: var(--radius);
    border: 1px solid var(--line);
    background: var(--bg);
    color: var(--fg-2);
    transition: border-color .15s, color .15s, background-color .15s;
}
.icon-btn:hover { border-color: var(--fg); color: var(--fg); }
.icon-btn svg { width: 1rem; height: 1rem; }

/* ---------- Kartalar, teglar ---------- */
.card {
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
}
.card-hover { transition: border-color .2s, box-shadow .2s; }
.card-hover:hover { border-color: #c9cdd2; box-shadow: var(--shadow); }
.panel { background: var(--surface); border-radius: var(--radius-lg); }

.tag {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    height: 1.5rem;
    padding: 0 .5rem;
    border-radius: var(--radius-sm);
    font-size: .72rem;
    font-weight: 600;
    line-height: 1;
    white-space: nowrap;
    background: var(--surface);
    color: var(--fg-2);
    border: 1px solid var(--line);
}
.tag svg { width: .8rem; height: .8rem; }
.tag-brand { background: var(--brand-50); color: var(--brand-strong); border-color: var(--brand-100); }
.tag-dark { background: var(--fg); color: #fff; border-color: var(--fg); }
.tag-ok { background: var(--ok-bg); color: var(--ok); border-color: #cdebd9; }
.tag-plain { background: transparent; border-color: transparent; padding: 0; color: var(--muted); }
a.tag:hover { border-color: var(--brand-300); color: var(--brand-strong); }
a.tag-dark:hover { color: #fff; }

.divider { height: 1px; background: var(--line); }

/* Metadata juftligi */
.meta-label {
    font-size: .72rem;
    font-weight: 600;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--muted);
}
.meta-value { font-size: .9375rem; font-weight: 600; color: var(--fg); }

/* ---------- Forma elementlari ---------- */
.field {
    appearance: none;
    width: 100%;
    height: 2.5rem;
    padding: 0 .85rem;
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    font-size: .875rem;
    color: var(--fg);
    transition: border-color .15s, box-shadow .15s;
}
textarea.field { height: auto; padding: .6rem .85rem; }
.field:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(30, 120, 110, .15); }
.field::placeholder { color: var(--faint); }
select.field {
    padding-right: 2.2rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7079' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right .7rem center;
    background-size: 1rem;
    cursor: pointer;
}
.field-icon { position: relative; display: block; }
.field-icon > svg, .field-icon > i {
    position: absolute;
    left: .85rem;
    top: 50%;
    transform: translateY(-50%);
    width: 1rem;
    height: 1rem;
    color: var(--faint);
    pointer-events: none;
}
.field-icon > .field { padding-left: 2.4rem; }

/* Katta qidiruv maydoni (bosh sahifa, 404) */
.search-xl { position: relative; display: flex; align-items: center; }
.search-xl > svg, .search-xl > i { position: absolute; left: 1.1rem; width: 1.25rem; height: 1.25rem; color: var(--faint); pointer-events: none; }
.search-xl input {
    width: 100%;
    height: 3.5rem;
    padding: 0 8.5rem 0 3.2rem;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: var(--bg);
    font-size: 1rem;
    color: var(--fg);
    box-shadow: var(--shadow);
    transition: border-color .15s, box-shadow .15s;
}
.search-xl input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 4px rgba(30, 120, 110, .14); }
.search-xl .btn { position: absolute; right: .45rem; height: 2.6rem; }

/* Filtr paneli */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .5rem;
    padding: .75rem;
    background: var(--surface);
    border-radius: var(--radius-lg);
}
.filter-bar select.field { width: auto; min-width: 9rem; flex: 1 1 9rem; }
@media (min-width: 768px) { .filter-bar select.field { flex: 0 1 auto; } }

/* ---------- Sahifa sarlavhasi (ichki sahifalar) ---------- */
.page-head {
    position: relative;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
    padding: calc(var(--header-total) + 2.25rem) 0 2.5rem;
}
.page-head .h1 { font-size: clamp(1.85rem, 1.3rem + 2.2vw, 3rem); }
.page-head .lead { margin-top: .9rem; }

.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; font-size: .8125rem; color: var(--muted); margin-bottom: 1.25rem; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--brand); }
.crumbs svg { width: .8rem; height: .8rem; opacity: .6; }
.crumbs [aria-current] { color: var(--fg); font-weight: 500; }

/* ---------- Header ---------- */
.site-header {
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 50;
    background: rgba(255, 255, 255, .96);
    backdrop-filter: saturate(1.6) blur(12px);
    -webkit-backdrop-filter: saturate(1.6) blur(12px);
    border-bottom: 1px solid var(--line);
    transition: box-shadow .2s;
}
.site-header.is-scrolled { box-shadow: 0 6px 24px -20px rgba(17, 19, 21, .55); }
.site-header .bar { height: var(--header-h); }

.brand-mark {
    width: 34px;
    height: 34px;
    border-radius: var(--radius);
    overflow: hidden;
    display: grid;
    place-items: center;
    flex-shrink: 0;
}
.brand-name { font-weight: 700; font-size: 1.05rem; line-height: 1.1; letter-spacing: -0.02em; color: var(--fg); }
.brand-sub { font-size: .72rem; line-height: 1.2; color: var(--muted); }

.nav-link {
    position: relative;
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    height: var(--header-h);
    padding: 0 .7rem;
    font-size: .875rem;
    font-weight: 500;
    color: var(--fg-2);
    transition: color .15s;
}
@media (min-width: 1024px) and (max-width: 1279px) { .nav-link { padding: 0 .5rem; } .nav-link::after { left: .5rem !important; right: .5rem !important; } }
.nav-link::after {
    content: "";
    position: absolute;
    left: .7rem;
    right: .7rem;
    bottom: -1px;
    height: 2px;
    background: var(--brand);
    transform: scaleX(0);
    transition: transform .2s;
}
.nav-link:hover { color: var(--fg); }
.nav-link.is-active { color: var(--fg); font-weight: 600; }
.nav-link.is-active::after { transform: scaleX(1); }

/* Dropdown */
.dropdown { position: relative; }
.dropdown-menu {
    position: absolute;
    right: 0;
    top: calc(100% + .4rem);
    min-width: 11rem;
    padding: .3rem;
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(4px);
    transition: opacity .15s, transform .15s, visibility .15s;
    z-index: 60;
}
.dropdown:hover .dropdown-menu, .dropdown:focus-within .dropdown-menu, .dropdown.is-open .dropdown-menu { opacity: 1; visibility: visible; transform: none; }
.dropdown-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
    width: 100%;
    padding: .5rem .65rem;
    border-radius: var(--radius);
    font-size: .875rem;
    color: var(--fg-2);
    text-align: left;
}
.dropdown-item:hover { background: var(--surface); color: var(--fg); }
.dropdown-item.is-active { color: var(--brand); font-weight: 600; }
.dropdown-item .code { font-size: .7rem; font-weight: 600; letter-spacing: .06em; color: var(--faint); }
.dropdown-label { padding: .4rem .65rem .3rem; }

/* Mobil menyu */
.mobile-overlay {
    position: fixed;
    inset: 0;
    z-index: 90;
    background: rgba(17, 19, 21, .45);
    opacity: 0;
    visibility: hidden;
    transition: opacity .25s, visibility .25s;
}
.mobile-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 100;
    width: min(88vw, 360px);
    display: flex;
    flex-direction: column;
    background: var(--bg);
    transform: translateX(100%);
    visibility: hidden;
    transition: transform .3s cubic-bezier(.2, .8, .2, 1), visibility .3s;
    overflow-y: auto;
}
body.menu-open .mobile-overlay { opacity: 1; visibility: visible; }
body.menu-open .mobile-drawer { transform: none; visibility: visible; box-shadow: -20px 0 60px -30px rgba(17, 19, 21, .6); }
body.menu-open { overflow: hidden; }
.drawer-link {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .7rem .75rem;
    border-radius: var(--radius);
    font-weight: 500;
    color: var(--fg-2);
    transition: background-color .15s;
}
.drawer-link:hover { background: var(--surface); color: var(--fg); }
.drawer-link.is-active { background: var(--brand-50); color: var(--brand-strong); font-weight: 600; }
.drawer-link svg { width: 1.05rem; height: 1.05rem; flex-shrink: 0; }
.lang-pill {
    flex: 1;
    text-align: center;
    height: 2.25rem;
    line-height: 2.25rem;
    border-radius: var(--radius);
    font-size: .8rem;
    font-weight: 600;
    background: var(--bg);
    border: 1px solid var(--line);
    color: var(--fg-2);
}
.lang-pill.is-active { background: var(--fg); border-color: var(--fg); color: #fff; }

/* Yon navigatsiya (siyosatlar, API sahifasi) */
.side-nav a {
    display: flex;
    align-items: center;
    gap: .6rem;
    padding: .5rem .75rem;
    border-left: 2px solid transparent;
    font-size: .875rem;
    color: var(--fg-2);
    transition: color .15s, border-color .15s, background-color .15s;
}
.side-nav a svg { width: 1rem; height: 1rem; color: var(--faint); flex-shrink: 0; }
.side-nav a:hover { color: var(--fg); background: var(--surface); }
.side-nav a.is-active { border-left-color: var(--brand); color: var(--brand-strong); font-weight: 600; background: var(--brand-50); }
.side-nav a.is-active svg { color: var(--brand); }

/* ---------- Jurnal identifikatsiyasi (rang — jurnal ID bo'yicha, cover_theme) ---------- */
.jt-0 { --j: #1e786e; --j-soft: #effaf8; --j-deep: #0f3f3a; }
.jt-1 { --j: #3b5bdb; --j-soft: #eef2ff; --j-deep: #1c2d6b; }
.jt-2 { --j: #b5552b; --j-soft: #fdf2ec; --j-deep: #5a2510; }
.jt-3 { --j: #6b4fbb; --j-soft: #f4f0fd; --j-deep: #31205f; }
.jt-4 { --j: #0e7490; --j-soft: #ecfeff; --j-deep: #0b3a4a; }

.j-dot { width: .6rem; height: .6rem; border-radius: 2px; background: var(--j, var(--brand)); flex-shrink: 0; }

.journal-card {
    position: relative;
    display: flex;
    flex-direction: column;
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: border-color .2s, box-shadow .2s;
}
.journal-card::before { content: ""; height: 4px; background: var(--j, var(--brand)); }
.journal-card:hover { border-color: #c9cdd2; box-shadow: var(--shadow); }
.journal-card .jc-name { font-weight: 700; font-size: 1.15rem; line-height: 1.25; letter-spacing: -0.02em; color: var(--fg); }
.journal-card:hover .jc-name { color: var(--j, var(--brand)); }

/* Jurnal sahifasi sarlavhasi */
.journal-head {
    position: relative;
    background: var(--j-deep, var(--brand-ink));
    color: #fff;
    padding: calc(var(--header-total) + 2.5rem) 0 2.75rem;
    overflow: hidden;
    isolation: isolate;
}
.journal-head::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background-image:
        linear-gradient(rgba(255, 255, 255, .05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .05) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: linear-gradient(90deg, transparent 35%, #000);
    -webkit-mask-image: linear-gradient(90deg, transparent 35%, #000);
}
.journal-head .crumbs, .journal-head .crumbs a { color: rgba(255, 255, 255, .65); }
.journal-head .crumbs a:hover, .journal-head .crumbs [aria-current] { color: #fff; }
.journal-head .lead { color: rgba(255, 255, 255, .78); }
.journal-head .tag { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .18); color: #fff; }

/* Jurnal ichki menyusi (yopishqoq) */
.subnav {
    position: sticky;
    top: var(--header-total);
    z-index: 30;
    background: rgba(255, 255, 255, .97);
    border-bottom: 1px solid var(--line);
}
.subnav a {
    display: inline-flex;
    align-items: center;
    height: 3rem;
    padding: 0 .9rem;
    font-size: .875rem;
    font-weight: 500;
    color: var(--fg-2);
    border-bottom: 2px solid transparent;
    white-space: nowrap;
}
.subnav a:hover { color: var(--fg); border-bottom-color: var(--line); }

/* ---------- Muqovalar ---------- */
.cover {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    border-radius: var(--radius-sm);
    background: var(--surface-2);
    box-shadow: 0 1px 2px rgba(0, 0, 0, .06), 0 10px 24px -14px rgba(17, 19, 21, .45);
}
.cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s cubic-bezier(.2, .8, .2, 1); }
a:hover .cover img, .group:hover .cover img { transform: scale(1.03); }

/* Generatsiya qilingan muqova (partials/cover.html): jurnal rangi + oq tipografiya */
.cover-gen { container-type: inline-size; color: #fff; background: var(--j-deep, var(--brand-ink)); }
.cover-gen .cv { position: absolute; inset: 0; display: flex; flex-direction: column; }
/* Yuqori rangli qism: sayt nomi + jurnal nomi */
.cover-gen .cv-band {
    height: 56%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 9% 9% 7%;
    background: var(--j, var(--brand));
}
.cover-gen .cv-top { font-size: 9px; font-size: 5cqw; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; opacity: .85; line-height: 1.3; }
.cover-gen .cv-title {
    font-weight: 700;
    font-size: 16px;
    font-size: 9.4cqw;
    line-height: 1.08;
    letter-spacing: -0.03em;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-word;
}
/* Pastki to'q qism: son, yil, ISSN */
.cover-gen .cv-foot { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; padding: 7% 9% 8%; }
.cover-gen .cv-bottom { display: flex; align-items: flex-end; justify-content: space-between; gap: 6%; }
.cover-gen .cv-issue { font-size: 10px; font-size: 5.6cqw; font-weight: 600; line-height: 1.25; }
.cover-gen .cv-year { font-size: 26px; font-size: 17cqw; font-weight: 700; line-height: .85; letter-spacing: -0.04em; }
.cover-gen .cv-issn { margin-top: 5%; font-size: 8px; font-size: 4.2cqw; letter-spacing: .04em; opacity: .6; }
.cover-sm .cv-issn, .cover-sm .cv-top { display: none; }

/* ---------- Statistika ---------- */
.stat-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
@media (min-width: 768px) { .stat-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.stat-grid > * { padding: 1.25rem 1.25rem 1.1rem; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stat-num { font-weight: 700; font-size: clamp(1.6rem, 1.2rem + 1.5vw, 2.4rem); line-height: 1; letter-spacing: -0.04em; color: var(--fg); font-variant-numeric: tabular-nums; }
.stat-label { margin-top: .45rem; font-size: .8rem; color: var(--muted); }
a.stat:hover .stat-num { color: var(--brand); }

/* ---------- Maqola matni ---------- */
.prose-article { font-family: var(--serif); font-size: 1.0625rem; line-height: 1.75; color: #24282d; }
.prose-article p + p { margin-top: 1em; }
.prose-article a { color: var(--brand); text-decoration: underline; }
.abstract-block { font-family: var(--serif); font-size: 1.0625rem; line-height: 1.75; color: #24282d; }

/* Tablar (pastki chiziqli) */
.tabs { display: flex; gap: .25rem; border-bottom: 1px solid var(--line); }
.tab {
    padding: .6rem .8rem;
    margin-bottom: -1px;
    border-bottom: 2px solid transparent;
    font-size: .875rem;
    font-weight: 500;
    color: var(--muted);
    transition: color .15s, border-color .15s;
}
.tab:hover { color: var(--fg); }
.tab[aria-selected="true"] { color: var(--fg); font-weight: 600; border-bottom-color: var(--brand); }

/* ---------- Ro'yxatlar ---------- */
.list-row { display: grid; gap: 1rem; padding: 1.25rem 0; border-top: 1px solid var(--line); }
.list-row:first-child { border-top: 0; }
.list-rows--boxed .list-row { padding-inline: 1.25rem; }
.list-rows--boxed .list-row:hover { background: var(--surface); }
@media (min-width: 640px) { .list-rows--boxed .list-row { padding-inline: 1.5rem; } }

.art-title { font-weight: 600; font-size: 1.0625rem; line-height: 1.4; letter-spacing: -0.012em; color: var(--fg); }
.art-title a { color: inherit; transition: color .15s; }
.art-title a:hover { color: var(--brand); }
.art-authors { margin-top: .35rem; font-size: .875rem; line-height: 1.5; color: var(--fg-2); }
.art-meta { margin-top: .6rem; display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .9rem; font-size: .8125rem; color: var(--muted); }
.art-meta > * { display: inline-flex; align-items: center; gap: .3rem; }
.art-meta svg { width: .85rem; height: .85rem; }
.num { font-weight: 600; font-size: .8125rem; color: var(--faint); font-variant-numeric: tabular-nums; }

/* ---------- Sahifalash ---------- */
.pagination { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .3rem; }
.page-link {
    min-width: 2.25rem;
    height: 2.25rem;
    padding: 0 .6rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius);
    font-size: .875rem;
    font-weight: 500;
    color: var(--fg-2);
    border: 1px solid var(--line);
    transition: border-color .15s;
}
.page-link:hover { border-color: var(--fg); }
.page-link.is-current { background: var(--fg); border-color: var(--fg); color: #fff; }
.page-link svg { width: 1rem; height: 1rem; }

/* ---------- Bo'sh holat ---------- */
.empty-state { padding: 4rem 1rem; text-align: center; color: var(--muted); }
.empty-state .ico {
    width: 3.25rem;
    height: 3.25rem;
    margin: 0 auto 1rem;
    border-radius: var(--radius-lg);
    display: grid;
    place-items: center;
    background: var(--surface);
    color: var(--faint);
}
.empty-state .ico svg { width: 1.4rem; height: 1.4rem; }

/* ---------- Avatar ---------- */
.avatar {
    display: grid;
    place-items: center;
    overflow: hidden;
    border-radius: 50%;
    background: var(--brand-50);
    color: var(--brand-strong);
    font-weight: 600;
    letter-spacing: -0.02em;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }

.orcid-badge {
    display: inline-grid;
    place-items: center;
    width: .95rem;
    height: .95rem;
    border-radius: 50%;
    background: #a6ce39;
    color: #fff;
    font-size: .5rem;
    font-weight: 700;
    line-height: 1;
}

/* ---------- Ogohlantirish bloklari ---------- */
.notice { display: flex; gap: .75rem; padding: 1rem 1.1rem; border-radius: var(--radius-lg); border: 1px solid var(--line); background: var(--surface); font-size: .875rem; line-height: 1.55; color: var(--fg-2); }
.notice svg { width: 1.1rem; height: 1.1rem; flex-shrink: 0; margin-top: .1rem; color: var(--brand); }
.notice-warn { background: #fffaeb; border-color: #fde68a; color: #7a4a06; }
.notice-warn svg { color: #b45309; }

/* ---------- Footer ---------- */
.site-footer { background: var(--dark); color: #a7adb5; font-size: .875rem; }
.site-footer h4 { font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: #fff; }
.site-footer a:hover { color: #fff; }
.footer-link { display: inline-flex; align-items: flex-start; gap: .5rem; line-height: 1.45; transition: color .15s; }
.social-btn {
    width: 2.25rem;
    height: 2.25rem;
    display: grid;
    place-items: center;
    border-radius: var(--radius);
    border: 1px solid rgba(255, 255, 255, .14);
    color: #d4d8dd;
    transition: background-color .15s, border-color .15s, color .15s;
}
.social-btn:hover { background: #fff; border-color: #fff; color: var(--dark) !important; }
.social-btn svg { width: 1rem; height: 1rem; }
.footer-input {
    flex: 1;
    min-width: 0;
    height: 2.5rem;
    padding: 0 .85rem;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .14);
    color: #fff;
    font-size: .875rem;
}
.footer-input::placeholder { color: #7d848d; }
.footer-input:focus { outline: none; border-color: var(--brand-300); }

/* Qorong'i CTA bloki */
.cta-dark { background: var(--dark); color: #fff; border-radius: var(--radius-lg); }
.cta-dark .muted { color: #a7adb5; }

/* ---------- Karusel / marquee ---------- */
.hide-scrollbar { scrollbar-width: none; -ms-overflow-style: none; }
.hide-scrollbar::-webkit-scrollbar { display: none; }
.custom-scrollbar::-webkit-scrollbar { width: 6px; height: 6px; }
.custom-scrollbar::-webkit-scrollbar-thumb { background: var(--line); border-radius: 6px; }

@keyframes marquee-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.animate-marquee { animation: marquee-scroll 50s linear infinite; }
.marquee:hover .animate-marquee { animation-play-state: paused; }
.marquee-mask { mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }

/* ==========================================================================
   Animatsiyalar
   Hammasi transform/opacity orqali (GPU, layout'ga ta'sir qilmaydi); prefers-reduced-motion'da o'chadi.
   ========================================================================== */
:root { --ease-out: cubic-bezier(.2, .8, .2, 1); }

@keyframes fade-up { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes cover-in { from { opacity: 0; transform: translateY(28px) rotate(-4deg) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes float-y { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }
@keyframes blob-drift {
    0% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(40px, -30px) scale(1.08); }
    66% { transform: translate(-30px, 20px) scale(.95); }
    100% { transform: translate(0, 0) scale(1); }
}
@keyframes shine { from { transform: translateX(-120%) skewX(-20deg); } to { transform: translateX(220%) skewX(-20deg); } }
@keyframes grow-x { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* Sahifa ochilganda: ketma-ket paydo bo'lish (style="--d:N" — N-chi navbat) */
.anim-in { animation: fade-up .8s var(--ease-out) both; animation-delay: calc(var(--d, 0) * 90ms + 60ms); }
.anim-cover { animation: cover-in 1s var(--ease-out) both; animation-delay: calc(var(--d, 0) * 110ms + 150ms); }
/* Ichki sahifalar sarlavhasi — shablonni o'zgartirmasdan */
.page-head .wrap > *, .page-head .wrap-narrow > * { animation: fade-up .7s var(--ease-out) both; }
.page-head .wrap > :nth-child(2), .page-head .wrap-narrow > :nth-child(2) { animation-delay: 80ms; }
.page-head .wrap > :nth-child(3), .page-head .wrap-narrow > :nth-child(3) { animation-delay: 160ms; }
.page-head .wrap > :nth-child(n+4), .page-head .wrap-narrow > :nth-child(n+4) { animation-delay: 240ms; }

/* Muqovalarning yengil "suzishi" */
.float-y { animation: float-y 6s ease-in-out infinite; }
.float-y.f2 { animation-delay: -2s; animation-duration: 7s; }
.float-y.f3 { animation-delay: -4s; animation-duration: 6.5s; }

/* Scroll paytida paydo bo'lish (public.js: IntersectionObserver). [data-stagger] ichidagilar navbat bilan (--i).
   animation (transition emas) — tugagach hover transform'lari erkin ishlaydi. */
.reveal { opacity: 0; }
.reveal.is-visible { opacity: 1; animation: fade-up .7s var(--ease-out) backwards; animation-delay: calc(var(--i, 0) * 70ms); }
.no-js .reveal { opacity: 1; }

/* Bosh sahifa hero foni: nozik to'r + sekin siljuvchi rangli dog'lar */
.hero { position: relative; overflow: hidden; isolation: isolate; }
.hero-bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hero-bg::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(17, 19, 21, .045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(17, 19, 21, .045) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: radial-gradient(ellipse 70% 60% at 75% 30%, #000 10%, transparent 75%);
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at 75% 30%, #000 10%, transparent 75%);
    animation: fade-in 1.2s ease both;
}
.hero-blob { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .5; animation: blob-drift 22s ease-in-out infinite; }
.hero-blob.b1 { width: 420px; height: 420px; right: 4%; top: -80px; background: var(--brand-100); }
.hero-blob.b2 { width: 320px; height: 320px; right: 26%; top: 180px; background: #e0e7ff; animation-delay: -8s; animation-duration: 26s; }

/* Muqova hover: 3D egilish */
a:hover > .cover, .group:hover .cover:not(.cover-sm), .float-y:hover .cover { transform: perspective(900px) rotateY(-9deg) translateY(-4px); box-shadow: 0 2px 4px rgba(0, 0, 0, .06), 18px 22px 40px -18px rgba(17, 19, 21, .5); }
.cover { transition: transform .5s var(--ease-out), box-shadow .5s var(--ease-out); transform-origin: left center; }

/* Haqiqiy muqova rasmi + son belgisi */
.cover-img { background: var(--surface-2); }
.cv-badge {
    position: absolute;
    left: 6%;
    right: 6%;
    bottom: 5%;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: .4rem;
    padding: .35em .55em;
    border-radius: var(--radius-sm);
    background: rgba(17, 19, 21, .78);
    backdrop-filter: blur(4px);
    color: #fff;
    font-size: 11px;
    line-height: 1.2;
}
.cv-badge-issue { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cv-badge-year { font-weight: 700; letter-spacing: -0.02em; }
.cover-sm .cv-badge { font-size: 9px; padding: .25em .4em; }

/* Jurnal kartasi hover: ko'tariladi, rangli chiziq qalinlashadi, strelka suriladi */
.journal-card { transition: border-color .25s, box-shadow .25s, transform .35s var(--ease-out); }
.journal-card::before { transform-origin: left; transition: height .25s var(--ease-out); }
.journal-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.journal-card:hover::before { height: 6px; }
.journal-card.is-visible::before { animation: grow-x .9s var(--ease-out) backwards; animation-delay: calc(var(--i, 0) * 70ms + 200ms); }
.journal-card .jc-arrow { transition: transform .25s var(--ease-out), color .25s; }
.journal-card:hover .jc-arrow { transform: translateX(4px); color: var(--j, var(--brand)); }
.journal-card .jc-cover .cover { transition: transform .45s var(--ease-out); }
.journal-card:hover .jc-cover .cover { transform: rotate(-3deg) translateY(-3px) scale(1.03); }

/* Kartalar va ro'yxat qatorlari */
.card-hover { transition: border-color .25s, box-shadow .25s, transform .35s var(--ease-out); }
.card-hover:hover { transform: translateY(-2px); }
.list-row .art-title a { background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .35s var(--ease-out), color .15s; }
.list-row .art-title a:hover { background-size: 100% 1px; }

/* Tugmalar: strelka suriladi, asosiy tugmada "yaltirash" */
.btn svg.lucide-arrow-right, .link-arrow svg.lucide-arrow-right { transition: transform .25s var(--ease-out); }
.btn:hover svg.lucide-arrow-right { transform: translateX(3px); }
.btn-primary, .btn-light { position: relative; overflow: hidden; isolation: isolate; }
.btn-primary::after, .btn-light::after {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 40%;
    z-index: -1;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .28), transparent);
    transform: translateX(-120%) skewX(-20deg);
}
.btn-light::after { background: linear-gradient(90deg, transparent, rgba(30, 120, 110, .14), transparent); }
.btn-primary:hover::after, .btn-light:hover::after { animation: shine .8s ease; }

/* Statistika: raqam ostidagi chiziq paydo bo'ladi */
.stat { position: relative; }
.stat::after { content: ""; position: absolute; left: 1.25rem; bottom: -1px; width: 2.5rem; height: 2px; background: var(--brand); transform: scaleX(0); transform-origin: left; transition: transform .6s var(--ease-out); }
.stat.is-visible::after, a.stat:hover::after { transform: scaleX(1); }

/* Jurnal ichki menyusi: scroll-spy (public.js) */
.subnav a.is-active { color: var(--fg); font-weight: 600; border-bottom-color: var(--brand); }

/* Maqola sahifasi: o'qish jarayoni chizig'i */
.read-progress { position: fixed; left: 0; right: 0; top: var(--header-total); z-index: 49; height: 2px; background: var(--brand); transform: scaleX(0); transform-origin: left; pointer-events: none; }

/* Header pastga tushganda yengil "ixchamlashadi" */
.site-header .brand-mark { transition: transform .3s var(--ease-out); }
.site-header.is-scrolled .brand-mark { transform: scale(.9); }

@media (prefers-reduced-motion: reduce) {
    .reveal, .reveal.is-visible { opacity: 1; animation: none; }
    .anim-in, .anim-cover, .page-head .wrap > *, .page-head .wrap-narrow > *,
    .float-y, .hero-blob, .hero-bg::before, .journal-card.is-visible::before { animation: none !important; }
    .btn-primary::after, .btn-light::after { display: none; }
    .journal-card:hover, .card-hover:hover, a:hover > .cover, .group:hover .cover, .journal-card:hover .jc-cover .cover { transform: none; }
    .read-progress { display: none; }
    .animate-marquee { animation: none; }
    * { scroll-behavior: auto !important; }
}

/* Yuqoriga qaytish tugmasi */
.to-top {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    z-index: 40;
    width: 2.5rem;
    height: 2.5rem;
    display: grid;
    place-items: center;
    border-radius: var(--radius);
    background: var(--fg);
    color: #fff;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity .2s, transform .2s, visibility .2s, background-color .15s;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--brand); }
.to-top svg { width: 1.05rem; height: 1.05rem; }

/* Toastr ranglarini mavzuga moslash */
#toast-container > div { border-radius: var(--radius-lg); opacity: 1; box-shadow: var(--shadow-lg); }
#toast-container > .toast-success { background-color: var(--brand); }
#toast-container > .toast-info { background-color: var(--fg); }

/* ---------- Tarjimalardagi HTML (translations.json: <span class='hl'> yoki eski text-indigo-*) ---------- */
.tr-html .hl,
.tr-html span[class*="indigo"] { color: var(--brand) !important; text-decoration: none !important; }
.tr-html--dark .hl,
.tr-html--dark span[class*="indigo"] { color: var(--brand-300) !important; text-decoration: none !important; }
