/* ===== Tokenlar: ikki mavzu (kunduzgi / tungi) ===== */
:root,
:root[data-theme="light"] {
  --bg: #fafaf7;
  --bg-elev: #ffffff;
  --surface: #f2f2ec;
  --text: #14161c;
  --text-muted: #565c6c;
  --border: #e2e2d9;
  --accent: #2447e8;
  --accent-soft: rgba(36, 71, 232, 0.09);
  --accent-contrast: #ffffff;
  --shadow: 0 1px 2px rgba(20, 22, 28, 0.06), 0 10px 30px rgba(20, 22, 28, 0.06);
  --live-bg: #e2f4e9;
  --live-fg: #0f6a37;
  --dev-bg: #fdf0d5;
  --dev-fg: #8a5300;
  --mute-bg: #ebebe4;
  --mute-fg: #4b5060;
  --img-filter: none;
  color-scheme: light;
}

:root[data-theme="dark"] {
  --bg: #0b0f17;
  --bg-elev: #111826;
  --surface: #161e2e;
  --text: #e9edf5;
  --text-muted: #9ba7bd;
  --border: #232d42;
  --accent: #7c9cff;
  --accent-soft: rgba(124, 156, 255, 0.12);
  --accent-contrast: #0b0f17;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 34px rgba(0, 0, 0, 0.35);
  --live-bg: rgba(110, 231, 160, 0.13);
  --live-fg: #6ee7a0;
  --dev-bg: rgba(251, 191, 77, 0.14);
  --dev-fg: #fbbf4d;
  --mute-bg: #1d2638;
  --mute-fg: #a6b1c6;
  --img-filter: brightness(0.92);
  color-scheme: dark;
}

:root {
  --radius: 16px;
  --radius-sm: 10px;
  --font-display: 'Manrope', 'Inter', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;
  --nav-h: 68px;
}

/* ===== Asos ===== */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 16px); }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background-color .2s ease, color .2s ease;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.15; letter-spacing: -0.01em; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.icon { width: 1.15em; height: 1.15em; flex-shrink: 0; vertical-align: -0.2em; }
.container { width: min(1120px, 100% - 32px); margin-inline: auto; }
.center { text-align: center; }
.muted { color: var(--text-muted); font-size: 14px; }

.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 300;
  background: var(--accent); color: var(--accent-contrast);
  padding: 10px 16px; border-radius: var(--radius-sm); font-weight: 600;
}
.skip-link:focus { top: 12px; }

/* ===== Tugmalar ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 10px 22px; border-radius: 999px;
  font-weight: 600; font-size: 15px; line-height: 1.2;
  border: 1px solid transparent; cursor: pointer;
  transition: transform .2s ease, background-color .2s ease, border-color .2s ease, color .2s ease;
}
.btn-sm { min-height: 44px; padding: 8px 18px; font-size: 14px; }
.btn-primary { background: var(--accent); color: var(--accent-contrast); }
.btn-primary:hover { transform: translateY(-2px); }
.btn-outline { border-color: var(--border); background: var(--bg-elev); color: var(--text); }
.btn-outline:hover { border-color: var(--accent); color: var(--accent); }
.btn-ghost { color: var(--text-muted); }
.btn-ghost:hover { color: var(--accent); }

/* ===== Navigatsiya ===== */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  width: min(1120px, 100% - 32px); margin-inline: auto; min-height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.nav-brand { font-family: var(--font-display); font-weight: 800; font-size: 20px; letter-spacing: 0.5px; }
.nav-links { display: flex; gap: 24px; font-size: 14.5px; font-weight: 500; }
.nav-links a { color: var(--text-muted); padding: 6px 0; transition: color .2s; }
.nav-links a:hover { color: var(--text); }
.nav-right { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.nav-toggle { display: none; }
.lang-switch-mobile { display: none; }

.lang-switch { display: flex; gap: 2px; font-family: var(--font-mono); font-size: 12px; }
.lang-switch a {
  min-width: 36px; min-height: 36px; display: inline-flex; align-items: center; justify-content: center;
  border-radius: 999px; color: var(--text-muted); transition: color .2s, background-color .2s;
}
.lang-switch a:hover { color: var(--text); }
.lang-switch a.active { background: var(--accent-soft); color: var(--accent); font-weight: 500; }

.theme-toggle {
  position: relative; width: 44px; height: 44px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--bg-elev); border: 1px solid var(--border); color: var(--text); cursor: pointer;
  transition: border-color .2s, color .2s;
}
.theme-toggle:hover { border-color: var(--accent); color: var(--accent); }
.theme-toggle .icon { position: absolute; width: 20px; height: 20px; transition: transform .35s ease, opacity .25s ease; }
:root[data-theme="light"] .theme-toggle .icon-sun { opacity: 0; transform: rotate(-90deg) scale(.5); }
:root[data-theme="light"] .theme-toggle .icon-moon { opacity: 1; transform: none; }
:root[data-theme="dark"] .theme-toggle .icon-moon { opacity: 0; transform: rotate(90deg) scale(.5); }
:root[data-theme="dark"] .theme-toggle .icon-sun { opacity: 1; transform: none; }

.hire-menu { position: relative; }
.hire-menu summary { list-style: none; cursor: pointer; }
.hire-menu summary::-webkit-details-marker { display: none; }
.hire-menu[open] summary .icon { transform: rotate(180deg); }
.hire-menu summary .icon { transition: transform .2s; }
.hire-dropdown {
  position: absolute; right: 0; top: calc(100% + 10px); min-width: 240px; z-index: 60;
  display: flex; flex-direction: column; gap: 2px; padding: 8px;
  background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.hire-dropdown a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--radius-sm); min-height: 44px; }
.hire-dropdown a:hover { background: var(--accent-soft); }
.hire-dropdown strong { display: block; font-size: 14px; }
.hire-dropdown small { display: block; color: var(--text-muted); font-family: var(--font-mono); font-size: 12px; }
.hire-dropdown .icon { color: var(--accent); width: 20px; height: 20px; }

/* ===== Bo'limlar ===== */
.section { padding: 96px 0; border-top: 1px solid var(--border); }
.section-alt { background: var(--surface); }
.route {
  display: flex; align-items: center; gap: 10px; margin-bottom: 14px;
  font-family: var(--font-mono); font-size: 13px; color: var(--accent); letter-spacing: .4px;
}
.route::before { content: ''; width: 26px; height: 1px; background: currentColor; opacity: .5; }
.route a:hover { text-decoration: underline; }
.route-center { justify-content: center; }
.section h2, .page-title { font-weight: 800; font-size: clamp(28px, 4vw, 40px); margin-bottom: 18px; }
.section-intro { color: var(--text-muted); max-width: 680px; font-size: 17px; margin-bottom: 36px; }
.center .section-intro { margin-inline: auto; }
.block-title { font-size: 20px; font-weight: 700; margin: 40px 0 18px; }
.block-title:first-of-type { margin-top: 8px; }
.projects-more { text-align: center; margin-top: 40px; }

/* ===== Hero ===== */
.hero { padding: 72px 0 40px; position: relative; overflow: hidden; }
.hero::before {
  content: ''; position: absolute; inset: -20% -10% auto auto; width: 620px; height: 620px; z-index: -1;
  background: radial-gradient(circle, var(--accent-soft), transparent 65%);
  pointer-events: none;
}
.hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: 48px; align-items: center; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: 22px;
  padding: 7px 16px; border-radius: 999px; border: 1px solid var(--border); background: var(--bg-elev);
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .6px; color: var(--text-muted);
}
.hero-badge .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--live-fg); box-shadow: 0 0 0 4px var(--live-bg); }
.hero-name { font-weight: 800; font-size: clamp(42px, 7vw, 76px); line-height: 1.02; letter-spacing: -0.03em; margin-bottom: 14px; }
.hero-name span { color: var(--accent); }
.hero-role { font-family: var(--font-display); font-weight: 700; font-size: clamp(20px, 2.6vw, 26px); margin-bottom: 16px; }
.hero-tagline { color: var(--text-muted); font-size: 18px; max-width: 560px; margin-bottom: 30px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.hero-card {
  background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden; font-family: var(--font-mono); font-size: 13px;
}
.hero-card-bar {
  display: flex; align-items: center; gap: 6px; padding: 12px 16px;
  border-bottom: 1px solid var(--border); background: var(--surface);
}
.hero-card-bar span { width: 10px; height: 10px; border-radius: 50%; background: var(--border); }
.hero-card-bar b { margin-left: 8px; font-weight: 500; color: var(--accent); }
.hero-card-bar i { margin-left: auto; font-style: normal; color: var(--live-fg); }
.hero-card pre { padding: 18px 20px; line-height: 1.75; color: var(--text-muted); overflow-x: auto; white-space: pre; }

.stats {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 56px;
}
.stat {
  background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px 22px; display: flex; flex-direction: column-reverse; gap: 2px;
}
.stat dd { font-family: var(--font-display); font-weight: 800; font-size: 34px; line-height: 1; }
.stat dt { color: var(--text-muted); font-size: 13.5px; }

/* ===== Men haqimda ===== */
.about-text { color: var(--text-muted); max-width: 760px; font-size: 17px; margin-bottom: 30px; }
.about-edu {
  background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 22px; max-width: 460px;
}
.edu-title { font-family: var(--font-mono); color: var(--accent); font-size: 13px; margin-bottom: 8px; }

/* ===== Loyiha kartalari ===== */
.project-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr)); gap: 24px; margin-bottom: 8px; }
.project-grid-3 { margin-top: 8px; }
.project-card {
  position: relative; display: flex; flex-direction: column; overflow: hidden;
  background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius);
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease, opacity .6s ease;
}
.project-card:hover { transform: translateY(-4px); border-color: var(--accent); box-shadow: var(--shadow); }
.project-cover { aspect-ratio: 16 / 10; background: var(--surface); overflow: hidden; }
.project-cover img { width: 100%; height: 100%; object-fit: cover; filter: var(--img-filter); transition: transform .5s ease; }
.project-card:hover .project-cover img { transform: scale(1.03); }
.project-cover-fallback {
  width: 100%; height: 100%; display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 800; font-size: 64px; color: var(--accent); background: var(--accent-soft);
}
.project-body { padding: 20px 22px 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.project-body .card-title { font-size: 21px; font-weight: 700; }
.stretched::after { content: ''; position: absolute; inset: 0; z-index: 1; }
.project-short { color: var(--text-muted); font-size: 15px; }
.card-link { margin-top: auto; padding-top: 6px; display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 14.5px; color: var(--accent); }
.card-link .icon { transition: transform .2s; }
.project-card:hover .card-link .icon { transform: translateX(4px); }

.badges { display: flex; flex-wrap: wrap; gap: 8px; }
.badge {
  display: inline-block; padding: 3px 11px; border-radius: 999px;
  font-size: 12px; font-weight: 600; font-family: var(--font-mono); letter-spacing: .2px;
  background: var(--mute-bg); color: var(--mute-fg);
}
.badge-kind-work { background: var(--accent-soft); color: var(--accent); }
.badge-status-live { background: var(--live-bg); color: var(--live-fg); }
.badge-status-in_development { background: var(--dev-bg); color: var(--dev-fg); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 5px 12px; border-radius: 999px; border: 1px solid var(--border); background: var(--bg-elev);
  font-family: var(--font-mono); font-size: 12.5px; color: var(--text-muted);
}
.project-body .chip { padding: 3px 10px; font-size: 12px; }

/* ===== Ko'nikmalar ===== */
.skills-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 32px 40px; }
.skill-cat { font-family: var(--font-mono); font-size: 13px; color: var(--accent); margin-bottom: 14px; }
.skills-soft { margin-top: 36px; color: var(--text-muted); font-size: 15px; }

/* ===== Xizmatlar ===== */
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.service-card {
  background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px;
  transition: border-color .25s, transform .25s, opacity .6s ease;
}
.service-card:hover { border-color: var(--accent); transform: translateY(-3px); }
.service-icon {
  display: inline-flex; width: 44px; height: 44px; align-items: center; justify-content: center;
  border-radius: 12px; background: var(--accent-soft); color: var(--accent);
}
.service-icon .icon { width: 24px; height: 24px; }
.service-card h3 { font-size: 19px; margin: 16px 0 8px; font-weight: 700; }
.service-card p { color: var(--text-muted); font-size: 15px; }
.group-cta {
  display: flex; align-items: center; gap: 20px; margin-top: 24px; padding: 22px 26px;
  background: var(--bg-elev); border: 1px solid var(--accent); border-radius: var(--radius);
  transition: transform .25s, opacity .6s ease;
}
.group-cta:hover { transform: translateY(-3px); }
.group-cta-icon { color: var(--accent); }
.group-cta-icon .icon { width: 30px; height: 30px; }
.group-cta-text { flex: 1; display: flex; flex-direction: column; gap: 4px; }
.group-cta-text strong { font-family: var(--font-display); font-size: 18px; }
.group-cta-text span { color: var(--text-muted); font-size: 14.5px; }

/* ===== Tajriba ===== */
.timeline { border-left: 2px solid var(--border); padding-left: 32px; display: flex; flex-direction: column; gap: 38px; }
.timeline-item { position: relative; }
.timeline-marker {
  position: absolute; left: -41px; top: 6px; width: 16px; height: 16px; border-radius: 50%;
  background: var(--bg); border: 3px solid var(--accent);
}
.timeline-work .timeline-marker { background: var(--accent); }
.timeline-period { font-family: var(--font-mono); font-size: 13px; color: var(--accent); margin-bottom: 6px; }
.timeline-content h3 { font-size: 20px; margin-bottom: 4px; font-weight: 700; }
.timeline-org { color: var(--text-muted); font-size: 15px; margin-bottom: 8px; }
.timeline-desc { color: var(--text-muted); font-size: 15px; max-width: 680px; }
.timeline-sub { margin: 18px 0 10px; font-family: var(--font-mono); font-size: 12.5px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .6px; }
.timeline-projects { display: grid; gap: 10px; max-width: 760px; }
.timeline-projects a {
  display: flex; flex-direction: column; gap: 2px; padding: 14px 18px;
  background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius-sm);
  transition: border-color .2s, transform .2s;
}
.timeline-projects a:hover { border-color: var(--accent); transform: translateX(3px); }
.timeline-projects strong { font-size: 15.5px; }
.timeline-projects span { color: var(--text-muted); font-size: 14px; }

/* ===== Aloqa ===== */
.contact-headline { font-size: clamp(30px, 5vw, 50px); font-weight: 800; margin-bottom: 18px; }
.contact-headline em { font-style: normal; color: var(--accent); }
/* ===== Aloqa: CTA paneli ===== */
.cta-section { padding: 88px 0; }
.cta-panel {
  text-align: center; padding: clamp(32px, 6vw, 72px) clamp(20px, 5vw, 56px);
  background: var(--accent); color: var(--accent-contrast); border-radius: 28px;
  box-shadow: var(--shadow);
}
.cta-panel .route { color: inherit; opacity: .85; margin-bottom: 14px; }
.cta-panel .route::before { background: currentColor; }
.cta-panel .contact-headline { margin-bottom: 14px; }
.cta-panel .contact-headline em { color: inherit; font-style: italic; text-decoration: underline; text-decoration-thickness: 3px; text-underline-offset: 8px; }
.cta-desc { max-width: 560px; margin: 0 auto 34px; font-size: 17px; opacity: .9; }
.cta-grid { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; text-align: left; max-width: 780px; margin: 0 auto; }
.cta-item {
  display: flex; align-items: center; gap: 14px; min-height: 76px; height: 100%; padding: 16px 18px;
  border-radius: var(--radius); color: inherit;
  background: color-mix(in srgb, var(--accent-contrast) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent-contrast) 28%, transparent);
  transition: transform .25s ease, background-color .25s ease;
}
.cta-item:hover, .cta-item:focus-visible { transform: translateY(-3px); background: color-mix(in srgb, var(--accent-contrast) 22%, transparent); }
.cta-item:focus-visible { outline-color: var(--accent-contrast); }
.cta-item .icon { width: 26px; height: 26px; }
.cta-item-text { display: flex; flex-direction: column; min-width: 0; }
.cta-item-text small { font-size: 12.5px; opacity: .8; }
.cta-item-text strong { font-size: 15px; font-weight: 600; overflow-wrap: anywhere; }

/* ===== Men haqimda: Resume va GitHub ===== */
.about-links { margin-top: 26px; }
.about-links-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ===== Footer (4 ustun) ===== */
.footer { padding: 72px 0 32px; border-top: 1px solid var(--border); background: var(--surface); }
.footer-grid { display: grid; grid-template-columns: 1.1fr .8fr 1.5fr 1.2fr; gap: 40px; }
.footer-logo { font-family: var(--font-display); font-weight: 800; font-size: 22px; margin-bottom: 12px; }
.footer-about { color: var(--text-muted); font-size: 15px; max-width: 320px; }
.footer-title { font-family: var(--font-mono); font-size: 12px; letter-spacing: 1.6px; text-transform: uppercase; color: var(--text-muted); margin-bottom: 18px; }
.footer-plain { list-style: none; display: grid; gap: 4px; }
.footer-plain a { display: inline-block; padding: 8px 0; font-size: 15px; transition: color .2s; overflow-wrap: break-word; }
.footer-plain a:hover, .footer-plain a:focus-visible { color: var(--accent); }
.footer-location { padding: 8px 0; font-size: 14px; color: var(--text-muted); font-family: var(--font-mono); }
.footer-social { list-style: none; }
.footer .link-row { min-height: 52px; padding: 12px 4px; font-size: 15.5px; font-weight: 500; }
.footer .link-row-arrow { margin-left: auto; }
.link-row {
  position: relative; display: flex; align-items: center; gap: 14px; border-bottom: 1px solid var(--border);
  cursor: pointer; transition: color .2s ease, padding .25s ease;
}
.link-row::after { content: ''; position: absolute; left: 0; bottom: -1px; height: 2px; width: 0; background: var(--accent); transition: width .3s ease; }
.link-row-icon { width: 20px; height: 20px; color: var(--text-muted); transition: color .2s; }
.link-row-arrow { width: 16px; height: 16px; color: var(--text-muted); transition: transform .25s ease, color .2s; }
.link-row:hover, .link-row:focus-visible { color: var(--accent); padding-left: 10px; }
.link-row:hover::after, .link-row:focus-visible::after { width: 100%; }
.link-row:hover .link-row-icon, .link-row:hover .link-row-arrow,
.link-row:focus-visible .link-row-icon, .link-row:focus-visible .link-row-arrow { color: var(--accent); }
.link-row:hover .link-row-arrow, .link-row:focus-visible .link-row-arrow { transform: translate(3px, -3px); }
.link-row:focus-visible { outline-offset: -2px; }
.footer-bottom { margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--border); color: var(--text-muted); font-size: 14px; }

/* ===== Loyihalar ro'yxati ===== */
.page-head { padding-top: 56px; border-top: 0; }
.page-title .count {
  display: inline-block; vertical-align: middle; margin-left: 10px; padding: 2px 12px; border-radius: 999px;
  background: var(--accent-soft); color: var(--accent); font-size: 18px; font-family: var(--font-mono); font-weight: 500;
}
.filters { display: flex; flex-direction: column; gap: 12px; margin-bottom: 32px; }
.filter-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.filter-label { width: 96px; font-family: var(--font-mono); font-size: 12.5px; color: var(--text-muted); }
.filter-chip {
  display: inline-flex; align-items: center; min-height: 44px; padding: 6px 16px; border-radius: 999px;
  border: 1px solid var(--border); background: var(--bg-elev); font-size: 14px; font-weight: 500;
  transition: border-color .2s, color .2s, background-color .2s;
}
.filter-chip:hover { border-color: var(--accent); color: var(--accent); }
.filter-chip.active { background: var(--accent); border-color: var(--accent); color: var(--accent-contrast); }
.empty { padding: 40px 0; color: var(--text-muted); }
.learning-title { margin-top: 56px; }
.learning-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr)); gap: 14px; }
.learning-list a {
  display: flex; flex-direction: column; gap: 8px; height: 100%; padding: 16px 18px;
  background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius-sm);
  transition: border-color .2s;
}
.learning-list a:hover { border-color: var(--accent); }
.learning-list strong { font-size: 16px; }
.learning-list a > span { color: var(--text-muted); font-size: 14px; }

/* ===== Keys sahifasi ===== */
.case .badges { margin-bottom: 16px; }
.case-lead { font-size: 19px; color: var(--text-muted); max-width: 760px; margin-bottom: 28px; }
.case-meta { display: flex; flex-wrap: wrap; gap: 14px 40px; margin-bottom: 26px; }
.case-meta div { display: flex; flex-direction: column; }
.case-meta dt { font-family: var(--font-mono); font-size: 12px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .6px; }
.case-meta dd { font-weight: 600; }
.case-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-bottom: 36px; }
.note { padding: 8px 14px; border-radius: var(--radius-sm); background: var(--mute-bg); color: var(--mute-fg); font-size: 14px; }
.case-cover { margin-bottom: 48px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); box-shadow: var(--shadow); }
.case-cover img { width: 100%; filter: var(--img-filter); }
.case-grid { display: grid; grid-template-columns: 1fr 320px; gap: 48px; align-items: start; }
.case-main section { margin-bottom: 34px; }
.case-main h2, .case-side h2, .gallery-section h2 { font-size: 22px; margin-bottom: 12px; }
.case-main p { color: var(--text-muted); font-size: 17px; max-width: 720px; }
.highlights { display: grid; gap: 10px; }
.highlights li { position: relative; padding-left: 26px; color: var(--text-muted); font-size: 16px; }
.highlights li::before { content: ''; position: absolute; left: 0; top: 10px; width: 12px; height: 2px; background: var(--accent); }
.case-side { position: sticky; top: calc(var(--nav-h) + 24px); padding: 22px; background: var(--bg-elev); border: 1px solid var(--border); border-radius: var(--radius); }
.gallery-section { margin-top: 56px; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.gallery a { display: block; border-radius: var(--radius-sm); overflow: hidden; border: 1px solid var(--border); }
.gallery img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; filter: var(--img-filter); transition: transform .4s; }
.gallery a:hover img { transform: scale(1.04); }
.case-nav { display: flex; justify-content: space-between; gap: 16px; margin-top: 64px; padding-top: 28px; border-top: 1px solid var(--border); }
.case-nav a { display: flex; flex-direction: column; gap: 2px; padding: 12px 0; max-width: 46%; transition: color .2s; }
.case-nav a:hover { color: var(--accent); }
.case-nav-next { text-align: right; margin-left: auto; }
.case-nav small { font-family: var(--font-mono); font-size: 12px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .6px; }
.case-nav strong { font-family: var(--font-display); font-size: 18px; }

.lightbox { border: 0; padding: 0; background: transparent; max-width: 100vw; max-height: 100vh; width: 100%; height: 100%; }
.lightbox::backdrop { background: rgba(5, 8, 14, 0.9); }
.lightbox[open] { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 24px; }
.lightbox img { max-width: min(1200px, 80vw); max-height: 86vh; border-radius: var(--radius-sm); object-fit: contain; }
.lightbox-btn {
  width: 48px; height: 48px; border-radius: 50%; border: 1px solid rgba(255,255,255,.25);
  background: rgba(255,255,255,.08); color: #fff; cursor: pointer; display: inline-flex; align-items: center; justify-content: center;
}
.lightbox-btn:hover { background: rgba(255,255,255,.18); }
.lightbox-btn .icon { width: 22px; height: 22px; }
.lightbox-prev .icon { transform: rotate(180deg); }
.lightbox-close { position: absolute; top: 20px; right: 20px; }

.error-page { padding: 140px 0; }

/* ===== Reveal: faqat JS ishlayotganda yashiriladi (JS yo'q bo'lsa kontent ko'rinaveradi) ===== */
.js-reveal .reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.js-reveal .reveal.visible { opacity: 1; transform: none; }

/* ===== Moslashuvchanlik ===== */
@media (max-width: 960px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px 32px; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-card { max-width: 520px; }
  .case-grid { grid-template-columns: 1fr; gap: 28px; }
  .case-side { position: static; }
  .stats { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 1080px) {
  .nav-toggle {
    display: flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 44px; height: 44px; background: none; border: none; cursor: pointer; padding: 0 10px;
  }
  .nav-toggle span { display: block; height: 2px; background: var(--text); border-radius: 2px; transition: transform .25s, opacity .25s; }
  .nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle.open span:nth-child(2) { opacity: 0; }
  .nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .nav-links {
    position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--border);
    max-height: 0; overflow: hidden; visibility: hidden;
    transition: max-height .3s ease, visibility .3s;
  }
  .nav-links.open { max-height: 520px; visibility: visible; }
  .nav-links a { padding: 14px 24px; min-height: 44px; }
  /* Mobil sarlavha: bitta qator — chapda logo, o'ngda mavzu, "Menga yozing" va menyu */
  .nav-inner { flex-wrap: nowrap; }
  .nav-brand { order: 0; }
  .nav-right { order: 1; margin-left: auto; gap: 8px; }
  .nav-toggle { order: 2; margin-right: -8px; }
  .lang-switch-desktop { display: none; }
  .lang-switch-mobile { display: flex; justify-content: center; gap: 8px; padding: 14px 24px 18px; }
  .nav-links .lang-switch-mobile a { width: auto; min-width: 52px; min-height: 44px; padding: 0 14px; border: 1px solid var(--border); }
  .nav-links .lang-switch-mobile a.active { border-color: var(--accent); }
}
@media (max-width: 760px) {
  .section { padding: 64px 0; }
  .group-cta { flex-direction: column; align-items: flex-start; }
  .filter-label { width: 100%; }
}
@media (max-width: 560px) {
  .cta-grid { grid-template-columns: minmax(0, 1fr); }
  .footer-grid { grid-template-columns: minmax(0, 1fr); }
  .cta-section { padding: 56px 0; }
  .nav-inner { gap: 4px; }
  .nav-right { gap: 6px; }
  .hire-menu summary { padding-inline: 14px; }
  .hero { padding-top: 40px; }
  .case-nav a { max-width: 48%; }
  .lightbox[open] { padding: 12px; gap: 4px; }
  .lightbox img { max-width: 78vw; }
  .lightbox-btn { width: 40px; height: 40px; }
}
@media (max-width: 380px) {
  .hire-menu summary .icon { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .js-reveal .reveal { opacity: 1; transform: none; }
}
