/* Fakultet, kafedra, xodimlar bo'limi va xodim profili sahifalari.
   Karta: spec 5.4 (bitta karta, ikki holat). Maket: Kafedra-A.dc.html. Oddiy CSS (Tailwind emas). */

.stf-page { font-family: 'Inter', system-ui, sans-serif; color: #0F172A; background: #F4F6FB; }
.stf-page h1, .stf-page h2, .stf-page h3, .stf-display { font-family: 'Outfit', sans-serif; }
.stf-page a { text-decoration: none; }
.stf-wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.stf-top { padding-top: 128px !important; }
.stf-page main h1 { color: #0B1A30; }
.stf-h2 { margin: 0; font-size: 28px; font-weight: 800; color: #0B1A30; }
.stf-muted { color: #475569; }
.stf-link { color: #2563EB; font-weight: 600; font-size: 14px; }
.stf-link:hover { color: #1D4ED8; }
.stf-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

@keyframes stf-up { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes stf-grow { from { width: 0; } }
@keyframes stf-ring { from { stroke-dashoffset: 327; } }
@keyframes stf-drift { 0%, 100% { transform: translate(0, 0); } 50% { transform: translate(24px, -18px); } }
.stf-au { animation: stf-up .65s cubic-bezier(.2, .8, .2, 1) backwards; }

/* Bosh qism: to'q ko'k, nuqtali naqsh, suzuvchi yorug'lik dog'lari */
/* padding-top: sayt sarlavhasi (fixed header) ostidan boshlanadi — xalqaro_hamkorlik pt-32 namunasi */
.stf-hero { position: relative; overflow: hidden; color: #FFFFFF; background-color: #0B1A30; padding-top: 96px;
    background-image: radial-gradient(rgba(255, 255, 255, .07) 1px, transparent 1px); background-size: 22px 22px; }
.stf-hero h1 { margin: 0; font-weight: 800; line-height: 1.08; color: #FFFFFF; font-size: clamp(30px, 4.4vw, 44px); }
.stf-hero p { margin: 0; color: #CBD5E1; line-height: 1.6; }
.stf-orb { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .55; pointer-events: none;
    animation: stf-drift 12s ease-in-out infinite; }
.stf-crumbs { font-size: 13px; color: #CBD5E1; display: flex; gap: 8px; flex-wrap: wrap; }
.stf-crumbs a { color: #93C5FD; }
.stf-crumbs a:hover { color: #FFFFFF; }
.stf-tag { align-self: flex-start; padding: 5px 12px; border-radius: 999px; background: rgba(147, 197, 253, .16);
    color: #BFDBFE; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.stf-glass { background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .14);
    backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.stf-stat { border-radius: 20px; padding: 16px 20px; display: flex; flex-direction: column; gap: 4px; }
.stf-stat b { font-family: 'Outfit', sans-serif; font-size: 36px; font-weight: 800; line-height: 1; }
.stf-stat span { font-size: 13px; color: #CBD5E1; }
.stf-ring { animation: stf-ring 1.6s cubic-bezier(.2, .8, .2, 1) both .3s; }

/* Ilmiy daraja belgisi */
.stf-badge { flex: 0 0 auto; }

/* ---- Xodim kartasi (.stf-card) ---- */
.stf-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(178px, 1fr)); gap: 16px; }
.stf-card { position: relative; display: block; aspect-ratio: 3 / 4.45; border-radius: 26px; overflow: hidden;
    background: #FFFFFF; color: #0F172A; text-decoration: none;
    box-shadow: 0 1px 2px rgba(15, 23, 42, .05), 0 12px 30px -14px rgba(15, 23, 42, .25);
    transition: transform .55s cubic-bezier(.2, .8, .2, 1), box-shadow .55s; }
.stf-card .stf-ph { position: absolute; top: 0; left: 0; right: 0; bottom: 0; overflow: hidden; border-radius: 26px;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(165deg, #EDF2F9 0%, #CBD5E1 100%);
    transition: top .55s cubic-bezier(.2, .8, .2, 1), left .55s cubic-bezier(.2, .8, .2, 1),
        right .55s cubic-bezier(.2, .8, .2, 1), bottom .55s cubic-bezier(.2, .8, .2, 1), border-radius .55s; }
.stf-card .stf-ph img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; }
.stf-initials { transform: translateY(-36px); font-family: 'Outfit', sans-serif; font-weight: 800; font-size: 44px;
    color: #94A3B8; letter-spacing: .02em; transition: transform .55s cubic-bezier(.2, .8, .2, 1); }
.stf-card .stf-bd { position: absolute; left: 0; right: 0; bottom: 0; height: 41%; box-sizing: border-box;
    padding: 0 13px 12px; display: flex; flex-direction: column; justify-content: flex-end; }
.stf-card .stf-bgg { position: absolute; left: 0; right: 0; bottom: 0; top: -48px;
    background: linear-gradient(to top, rgba(255, 255, 255, .11) 62%, rgba(255, 255, 255, 0));
    backdrop-filter: blur(1px); -webkit-backdrop-filter: blur(1px);
    -webkit-mask-image: linear-gradient(to top, #000 72%, transparent); mask-image: linear-gradient(to top, #000 72%, transparent);
    transition: opacity .45s; }
.stf-card .stf-ct { position: relative; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.stf-role { font-size: 10.5px; font-weight: 700; color: #2563EB; text-transform: uppercase; letter-spacing: .05em; }
.stf-nm { display: flex; align-items: center; gap: 5px; min-width: 0; }
.stf-nm span { font-family: 'Outfit', sans-serif; font-size: 15.5px; font-weight: 700; line-height: 1.25; }
.stf-ds { font-size: 12px; line-height: 1.45; color: #334155; transition: color .45s; }
.stf-fr { display: flex; align-items: center; gap: 8px; margin-top: 5px; min-height: 20px; }
.stf-fan { flex: 1 1 auto; min-width: 0; font: 600 12.5px/1.35 'Inter', sans-serif; color: #1E3A8A; transition: color .45s;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block !important; }
.stf-arr { flex: 0 0 auto; margin-left: auto; color: #0F172A;
    transition: transform .45s cubic-bezier(.2, .8, .2, 1), color .45s; }
.stf-card[hidden] { display: none; }
.stf-kt { position: absolute; top: 10px; left: 10px; z-index: 1; width: max-content;
    max-width: calc(100% - 20px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
    padding: 4px 9px; border-radius: 999px; font: 700 10.5px 'Inter', sans-serif; color: #FFFFFF; letter-spacing: .02em;
    transition: opacity .45s; }
.stf-pt { position: absolute; top: 10px; right: 10px; z-index: 1; padding: 4px 9px; border-radius: 999px;
    background: rgba(11, 26, 48, .78); color: #FFFFFF; font: 700 10.5px 'Inter', sans-serif; }
.stf-clamp1 { display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.stf-clamp2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* Suratli karta: shaffof shisha ustida matn oq va soyali (hover'da oq ramkada odatiy rangga qaytadi) */
.stf-card.stf-has-photo .stf-ct { color: #FFFFFF; text-shadow: 0 1px 2px rgba(0, 0, 0, .6), 0 0 14px rgba(0, 0, 0, .45);
    transition: color .45s, text-shadow .45s; }
.stf-card.stf-has-photo .stf-role, .stf-card.stf-has-photo .stf-ds, .stf-card.stf-has-photo .stf-fan { color: #FFFFFF; }
.stf-card.stf-has-photo .stf-arr { color: #FFFFFF; filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .6)); }

/* Hover / klaviatura fokusi: surat oq ramka ichiga torayadi (telefonda hover yo'q) */
@media (hover: hover) {
    .stf-card:hover { transform: translateY(-4px); color: #0F172A;
        box-shadow: 0 2px 4px rgba(15, 23, 42, .06), 0 28px 48px -18px rgba(15, 23, 42, .32); }
    .stf-card:hover .stf-ph { top: 7px; left: 7px; right: 7px; bottom: 41%; border-radius: 20px; }
    .stf-card:hover .stf-initials { transform: none; }
    .stf-card:hover .stf-bgg { opacity: 0; }
    .stf-card:hover .stf-ct { color: inherit; text-shadow: none; }
    .stf-card:hover .stf-role { color: #2563EB; }
    .stf-card:hover .stf-arr { filter: none; }
    .stf-card:hover .stf-ds { color: #64748B; }
    .stf-card:hover .stf-fan { color: #2563EB; }
    .stf-card:hover .stf-arr { transform: translate(2px, -2px); color: #2563EB; }
}
.stf-card:focus-visible { outline: none; transform: translateY(-4px); color: #0F172A;
    box-shadow: 0 0 0 3px #2563EB, 0 28px 48px -18px rgba(15, 23, 42, .32); }
.stf-card:focus-visible .stf-ph { top: 7px; left: 7px; right: 7px; bottom: 41%; border-radius: 20px; }
.stf-card:focus-visible .stf-initials { transform: none; }
.stf-card:focus-visible .stf-bgg { opacity: 0; }
.stf-card:focus-visible .stf-ct { color: inherit; text-shadow: none; }
.stf-card:focus-visible .stf-role { color: #2563EB; }
.stf-card:focus-visible .stf-ds { color: #64748B; }
.stf-card:focus-visible .stf-arr { filter: none; }
.stf-card:focus-visible .stf-fan, .stf-card:focus-visible .stf-arr { color: #2563EB; }

/* ---- Katta karta (dekan, kafedra mudiri) ---- */
.stf-pc { position: relative; display: flex; flex-wrap: wrap; gap: 6px; background: #FFFFFF; border-radius: 26px; padding: 7px;
    color: #0F172A; box-shadow: 0 1px 2px rgba(15, 23, 42, .05), 0 14px 34px -14px rgba(15, 23, 42, .22);
    transition: transform .45s cubic-bezier(.2, .8, .2, 1), box-shadow .45s; }
.stf-pc:hover { transform: translateY(-6px); color: #0F172A;
    box-shadow: 0 2px 4px rgba(15, 23, 42, .06), 0 28px 50px -18px rgba(37, 99, 235, .38); }
.stf-pc:focus-visible { outline: none; box-shadow: 0 0 0 3px #2563EB, 0 28px 50px -18px rgba(37, 99, 235, .38); }
.stf-pc .stf-pph { position: relative; flex: 0 0 200px; aspect-ratio: 3 / 4; overflow: hidden; border-radius: 20px;
    display: flex; align-items: center; justify-content: center; background: linear-gradient(165deg, #EDF2F9 0%, #CBD5E1 100%); }
.stf-pc .stf-pph img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%;
    transition: transform .7s cubic-bezier(.2, .8, .2, 1); }
.stf-pc:hover .stf-pph img { transform: scale(1.05); }
.stf-pc .stf-pph .stf-initials { margin: 0; transform: none; font-size: 52px; }
.stf-rtag { position: absolute; top: 12px; left: 12px; padding: 5px 11px; border-radius: 999px; background: #7A1324;
    color: #FFFFFF; font-size: 12px; font-weight: 700; }
.stf-pb { flex: 1 1 220px; padding: 16px 14px 12px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.stf-pb .stf-pn { font-family: 'Outfit', sans-serif; font-size: 24px; font-weight: 700; line-height: 1.2; }
.stf-st { display: inline-flex; align-items: center; gap: 5px; font: 600 13px 'Inter', sans-serif; color: #334155; }
.stf-st svg { color: #94A3B8; }
.stf-pill { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 16px; border-radius: 999px;
    background: #F1F5F9; font: 600 13px 'Inter', sans-serif; color: #0F172A; transition: background .3s, color .3s; }
.stf-pc:hover .stf-pill { background: #0B1A30; color: #FFFFFF; }
.stf-pc.stf-small .stf-pph { flex-basis: 120px; }
.stf-pc.stf-small .stf-pn { font-size: 18px; }

/* ---- Kafedra kartasi (fakultet sahifasida) ---- */
.stf-kgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; }
.stf-kc { display: flex; flex-direction: column; background: #FFFFFF; border-radius: 24px; overflow: hidden; color: #0F172A;
    box-shadow: 0 1px 2px rgba(15, 23, 42, .05), 0 14px 34px -16px rgba(15, 23, 42, .2);
    transition: transform .45s cubic-bezier(.2, .8, .2, 1), box-shadow .45s; }
.stf-kc:hover { transform: translateY(-6px); color: #0F172A; box-shadow: 0 28px 50px -20px rgba(15, 23, 42, .35); }
.stf-kc:focus-visible { outline: 3px solid #2563EB; outline-offset: 2px; }
.stf-kh { position: relative; overflow: hidden; padding: 20px 20px 18px; color: #FFFFFF; display: flex; flex-direction: column; gap: 14px; }
.stf-kh::after { content: ''; position: absolute; width: 140px; height: 140px; border-radius: 50%;
    border: 22px solid rgba(255, 255, 255, .10); right: -40px; top: -50px; }
.stf-kh h3 { margin: 0; font-size: 19px; font-weight: 700; line-height: 1.25; min-height: 48px; color: #FFFFFF; }
.stf-kb { padding: 16px 20px 20px; display: flex; flex-direction: column; gap: 14px; }
.stf-go { transition: transform .35s; }
.stf-kc:hover .stf-go { transform: translateX(5px); }
.stf-bar-bg { height: 8px; border-radius: 999px; background: #EEF2F7; overflow: hidden; }
.stf-bar { height: 100%; border-radius: 999px; animation: stf-grow 1.4s cubic-bezier(.2, .8, .2, 1) both .4s; }
.stf-avs { display: flex; padding-left: 8px; }
.stf-av { width: 30px; height: 30px; border-radius: 50%; border: 2px solid #FFFFFF; margin-left: -8px; overflow: hidden;
    display: flex; align-items: center; justify-content: center; background: linear-gradient(165deg, #EDF2F9, #CBD5E1);
    font: 700 10px 'Inter', sans-serif; color: #64748B; }
.stf-av img { width: 100%; height: 100%; object-fit: cover; }
.stf-av.stf-more { background: #0B1A30; color: #FFFFFF; }

/* ---- Filtr, qidiruv ---- */
.stf-chip { min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1px solid #CBD5E1; background: #FFFFFF;
    color: #0F172A; font: 600 14px 'Inter', sans-serif; cursor: pointer; display: inline-flex; align-items: center; gap: 6px;
    transition: background .25s, color .25s, border-color .25s, transform .2s; }
.stf-chip:active { transform: scale(.96); }
.stf-chip[aria-pressed="true"], .stf-chip.is-on { background: #0B1A30; border-color: #0B1A30; color: #FFFFFF; }
.stf-chip small { opacity: .65; font-size: 13px; }
.stf-search { position: relative; display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 16px;
    border-radius: 999px; background: #FFFFFF; border: 1px solid #E2E8F0;
    box-shadow: 0 6px 20px -12px rgba(15, 23, 42, .25); transition: border-color .25s, box-shadow .25s; }
.stf-search:focus-within { border-color: #2563EB; box-shadow: 0 0 0 4px rgba(37, 99, 235, .15); }
.stf-search input { border: 0; outline: 0; background: transparent; font: 500 15px 'Inter', sans-serif; color: #0F172A;
    width: 100%; padding: 0; box-shadow: none; }
.stf-search input:focus { box-shadow: none; }
.stf-search.stf-big { min-height: 58px; padding: 0 8px 0 20px; border: 0; box-shadow: 0 18px 40px -16px rgba(0, 0, 0, .5); }
.stf-search.stf-big:focus-within { box-shadow: 0 0 0 5px rgba(96, 165, 250, .45), 0 18px 40px -16px rgba(0, 0, 0, .5); }
.stf-search button { min-height: 44px; padding: 0 20px; border-radius: 999px; border: 0; background: #2563EB; color: #FFFFFF;
    font: 700 14px 'Inter', sans-serif; cursor: pointer; }
.stf-search button:hover { background: #1D4ED8; }
.stf-filters { display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-end; background: #FFFFFF; border-radius: 22px;
    padding: 18px 20px; box-shadow: 0 10px 30px -18px rgba(15, 23, 42, .25); }
.stf-sel { display: flex; flex-direction: column; gap: 6px; font: 600 12px 'Inter', sans-serif; color: #475569; }
.stf-sel select { min-height: 44px; padding: 0 36px 0 14px; border-radius: 14px; border: 1px solid #CBD5E1; background-color: #FFFFFF;
    font: 500 14px 'Inter', sans-serif; color: #0F172A; }
.stf-empty { margin: 0; padding: 40px; text-align: center; color: #64748B; background: #FFFFFF; border-radius: 20px; }
.stf-pager { display: flex; gap: 8px; justify-content: center; align-items: center; flex-wrap: wrap; }
.stf-pager a, .stf-pager span { min-width: 44px; min-height: 44px; padding: 0 14px; border-radius: 999px; display: inline-flex;
    align-items: center; justify-content: center; font: 600 14px 'Inter', sans-serif; background: #FFFFFF; color: #0F172A;
    border: 1px solid #E2E8F0; }
.stf-pager a:hover { border-color: #2563EB; color: #2563EB; }
.stf-pager .is-on { background: #0B1A30; color: #FFFFFF; border-color: #0B1A30; }

/* ---- Profil ---- */
.stf-box { background: #FFFFFF; border: 1px solid #E2E8F0; border-radius: 20px; padding: 22px; }
.stf-box h2 { margin: 0 0 14px; font-size: 18px; font-weight: 700; color: #0B1A30; }
.stf-photo { position: relative; aspect-ratio: 3 / 4; overflow: hidden; border-radius: 24px; display: flex; align-items: center;
    justify-content: center; background: linear-gradient(165deg, #EDF2F9 0%, #CBD5E1 100%); }
.stf-photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; }
.stf-photo .stf-initials { margin: 0; transform: none; font-size: 72px; }
.stf-chipline { display: flex; gap: 8px; flex-wrap: wrap; }
.stf-label { padding: 6px 12px; border-radius: 999px; font-size: 13px; font-weight: 600; background: #F1F5F9; color: #334155; }
.stf-label.dsc { background: #FCE7EA; color: #7A1324; font-weight: 700; }
.stf-label.phd { background: #DBEAFE; color: #1E40AF; font-weight: 700; }
.stf-label.kaf { background: #DBEAFE; color: #1E40AF; }
.stf-row { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.stf-row > :first-child { color: #64748B; flex: 0 0 auto; }
.stf-row > :last-child { text-align: right; overflow-wrap: anywhere; }
.stf-extlink { display: flex; justify-content: space-between; align-items: center; min-height: 44px; padding: 0 14px;
    border: 1px solid #E2E8F0; border-radius: 12px; color: #0F172A; font-weight: 600; font-size: 14px; transition: border-color .25s, color .25s; }
.stf-extlink:hover { border-color: #2563EB; color: #2563EB; }
.stf-metric { padding: 18px; display: flex; flex-direction: column; gap: 2px; }
.stf-metric b { font-family: 'Outfit', sans-serif; font-size: 32px; font-weight: 800; color: #0B1A30; }
.stf-metric span { font-size: 13px; color: #475569; }
.stf-area { padding: 8px 14px; border-radius: 12px; background: #F1F5F9; font-size: 14px; color: #0F172A; }

/* ---- Tungi rejim ---- */
html.dark .stf-page, html[data-theme="dark"] .stf-page { background: #0F172A; color: #E2E8F0; }
html.dark .stf-h2, html.dark .stf-box h2, html.dark .stf-metric b, html.dark .stf-page main h1 { color: #FFFFFF; }
html.dark .stf-muted, html.dark .stf-metric span { color: #94A3B8; }
html.dark .stf-link { color: #60A5FA; }
html.dark .stf-card, html.dark .stf-pc, html.dark .stf-kc, html.dark .stf-box, html.dark .stf-filters,
html.dark .stf-empty, html.dark .stf-search:not(.stf-big), html.dark .stf-pager a, html.dark .stf-pager span {
    background: #1E293B; color: #E2E8F0; border-color: #334155; }
html.dark .stf-card .stf-bgg { background: linear-gradient(to top, rgba(30, 41, 59, .11) 62%, rgba(30, 41, 59, 0)); }
html.dark .stf-card .stf-ph, html.dark .stf-pph, html.dark .stf-photo, html.dark .stf-av { background: linear-gradient(165deg, #334155 0%, #1E293B 100%); }
html.dark .stf-initials { color: #64748B; }
html.dark .stf-ds, html.dark .stf-st { color: #CBD5E1; }
html.dark .stf-fan { color: #93C5FD; }
html.dark .stf-arr { color: #E2E8F0; }
html.dark .stf-card:hover, html.dark .stf-pc:hover, html.dark .stf-kc:hover { color: #E2E8F0; }
html.dark .stf-pill, html.dark .stf-area, html.dark .stf-label { background: #334155; color: #E2E8F0; }
html.dark .stf-label.dsc { background: rgba(122, 19, 36, .45); color: #FECDD3; }
html.dark .stf-label.phd, html.dark .stf-label.kaf { background: rgba(37, 99, 235, .3); color: #BFDBFE; }
html.dark .stf-chip { background: #1E293B; border-color: #475569; color: #E2E8F0; }
html.dark .stf-chip[aria-pressed="true"], html.dark .stf-chip.is-on, html.dark .stf-pager .is-on { background: #2563EB; border-color: #2563EB; color: #FFFFFF; }
html.dark .stf-sel { color: #CBD5E1; }
html.dark .stf-sel select, html.dark .stf-search input { background-color: #0F172A; color: #E2E8F0; border-color: #475569; }
html.dark .stf-search:not(.stf-big) input { background: transparent; }
html.dark .stf-bar-bg { background: #334155; }
html.dark .stf-av { border-color: #1E293B; }
html.dark .stf-extlink { border-color: #334155; color: #E2E8F0; }
html.dark .stf-row > :first-child { color: #94A3B8; }

@media (max-width: 640px) {
    .stf-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .stf-card { border-radius: 22px; }
    .stf-pc .stf-pph { flex-basis: 100%; aspect-ratio: 4 / 3; }
    .stf-pc.stf-small .stf-pph { flex-basis: 110px; aspect-ratio: 3 / 4; }
    .stf-nm span { font-size: 14px; }
}

@media (prefers-reduced-motion: reduce) {
    .stf-page *, .stf-page *::before, .stf-page *::after { animation: none !important; transition: none !important; }
}
