/* Kontent Factory — "Yumshoq premium" dizayn tizimi.
   Iliq oq fon, oq kartalar va yumshoq soyalar, bitta brend rangi (marjon-qizil), pill tugmalar. Shrift: Onest.
   CSP inline style'ga ruxsat bermaydi: hamma narsa shu faylda, qiymatlar tokenlardan. */

@font-face {
  font-family: "Onest";
  src: url("fonts/onest-latin-wght.woff2") format("woff2");
  font-weight: 100 900; font-display: swap;
}

/* ---------- 1. Tokenlar ---------- */
:root {
  /* neytral (60%) */
  --bg: #fafaf7;
  --bg-2: #f3f2ee;
  --surface: #ffffff;
  --track: #ecebe6;
  --text: #14161f;
  --muted: #585d6c;
  --line: #eceae4;
  --line-strong: #d9d7d0;
  --line-input: #8a8e99;          /* forma chegarasi >= 3:1 (WCAG 1.4.11) */
  /* brend: marjon-qizil (10%) */
  --brand-50: #fff4f2;
  --brand-100: #ffe9e6;
  --brand-200: #ffd0c9;
  --brand-400: #ff7a6b;
  --brand-500: #ff4d3d;           /* bezak: chiziqlar, ikonkalar */
  --brand-600: #d42f22;           /* tugma va matn: oq bilan 4.97:1 */
  --brand-700: #b4261b;
  --brand-text: #d42f22;          /* brend rangidagi matn (AA) */
  --on-brand: #ffffff;
  /* ikkilamchi: siyoh-ko'k panel */
  --ink: #171a2b;
  --on-ink: #ffffff;
  --on-ink-muted: #b4b8c7;
  /* semantik */
  --ok: #15803d;   --ok-soft: #e8f7ee;
  --warn: #a4520a; --warn-soft: #fdf1e1;
  --err: #c2281d;  --err-soft: #fdeceb;
  --info: #1d4ed8; --info-soft: #eaf1fe;
  --focus-ring: 0 0 0 4px rgb(255 77 61 / .28);
  /* tipografika: 1.25 shkala */
  --font: "Onest", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --fs-14: .875rem; --fs-16: 1rem; --fs-18: 1.125rem; --fs-20: 1.25rem; --fs-25: 1.5625rem;
  --fs-31: 1.9375rem; --fs-39: 2.4375rem; --fs-49: 3.0625rem; --fs-61: 3.8125rem;
  /* bo'shliq: 4/8 tizimi */
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 24px; --s-6: 32px; --s-7: 48px; --s-8: 64px;
  --s-9: 96px; --s-10: 128px;
  --section: clamp(64px, 9vw, 120px);
  /* shakl */
  --r-sm: 12px; --r-md: 20px; --r-lg: 32px; --r-pill: 999px;
  --sh-sm: 0 1px 2px rgb(20 22 31 / .04), 0 2px 6px rgb(20 22 31 / .04);
  --sh-md: 0 2px 4px rgb(20 22 31 / .04), 0 12px 32px rgb(20 22 31 / .08);
  --sh-lg: 0 4px 10px rgb(20 22 31 / .05), 0 28px 64px rgb(20 22 31 / .14);
  --sh-brand: 0 10px 28px rgb(212 47 34 / .30);
  /* harakat */
  --t-fast: 150ms; --t-base: 250ms; --t-slow: 400ms;
  --ease: cubic-bezier(.2, .8, .2, 1);
  /* ikonkalar: mask sifatida, rangi currentColor'dan (tungi rejimda ham to'g'ri) */
  --icon-check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3.5 8.4l3 3 6-6.3' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  --icon-chevron: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 6l4 4 4-4' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  --icon-video: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Crect x='3' y='5' width='18' height='14' rx='3' fill='none' stroke='black' stroke-width='2'/%3E%3Cpath d='M10 9.2v5.6l4.6-2.8z' fill='black'/%3E%3C/svg%3E");
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1015;
    --bg-2: #15161d;
    --surface: #1a1c24;
    --track: #2a2c36;
    --text: #f2f3f6;
    --muted: #a0a5b4;
    --line: #262833;
    --line-strong: #3a3d4a;
    --line-input: #646879;
    --brand-50: #2a1613;
    --brand-100: #3a1b17;
    --brand-200: #5a2620;
    --brand-500: #ff6a5b;
    --brand-600: #d93a2b;
    --brand-700: #c2311f;
    --brand-text: #ff6a5b;
    --ink: #1e2130;
    --ok: #6ee7a0;   --ok-soft: #11291c;
    --warn: #fbbf72; --warn-soft: #2e2210;
    --err: #ff8f84;  --err-soft: #341614;
    --info: #93b4ff; --info-soft: #152038;
    --sh-sm: none;
    --sh-md: 0 12px 32px rgb(0 0 0 / .35);
    --sh-lg: 0 28px 64px rgb(0 0 0 / .45);
    --sh-brand: 0 10px 28px rgb(217 58 43 / .35);
    color-scheme: dark;
  }
}

/* ---------- 2. Asos ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 400 var(--fs-16)/1.6 var(--font);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, svg, video { max-width: 100%; }
a { color: inherit; text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--brand-text); }
:focus-visible { outline: 2px solid var(--brand-600); outline-offset: 3px; border-radius: 6px; }
p { margin: 0 0 var(--s-4); }
h1, h2, h3 { margin: 0 0 var(--s-4); font-weight: 800; color: var(--text); }
h1 { font-size: clamp(var(--fs-39), 1.8rem + 2.6vw, var(--fs-61)); line-height: 1.06; letter-spacing: -.035em; }
h2 { font-size: clamp(var(--fs-31), 1.5rem + 1.6vw, var(--fs-49)); line-height: 1.1; letter-spacing: -.03em; }
h3 { font-size: var(--fs-20); font-weight: 700; line-height: 1.3; letter-spacing: -.015em; }
.wrap { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 var(--s-4); }
@media (min-width: 768px) { .wrap { padding: 0 var(--s-5); } }
@media (min-width: 1024px) { .wrap { padding: 0 var(--s-6); } }
[hidden] { display: none !important; }  /* .btn kabi display beradigan klasslar hidden'ni bekor qilmasin */
.sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: var(--s-4); top: var(--s-2); z-index: 50; padding: 10px var(--s-4); border-radius: var(--r-pill);
  background: var(--ink); color: var(--on-ink); font-weight: 600; text-decoration: none; transform: translateY(-200%);
}
.skip-link:focus { transform: none; color: var(--on-ink); }
main:focus { outline: none; }
.muted { color: var(--muted); }
.small { font-size: var(--fs-14); }
.inline { display: inline; }
.mt-12 { margin-top: var(--s-3); }
.card-title { font-size: var(--fs-20); font-weight: 700; letter-spacing: -.015em; }
.hl { color: var(--brand-text); }
.eyebrow {
  display: inline-flex; align-items: center; gap: var(--s-2); margin-bottom: var(--s-5);
  padding: 6px 14px 6px 12px; border-radius: var(--r-pill); background: var(--brand-50); color: var(--brand-text);
  font-size: var(--fs-14); font-weight: 600;
}
.rec { position: relative; width: 8px; height: 8px; border-radius: var(--r-pill); background: var(--brand-500); flex: none; }
.rec::after { content: ""; position: absolute; inset: 0; border-radius: inherit; background: inherit; animation: ping 2s var(--ease) infinite; }
@keyframes ping { 70%, 100% { transform: scale(2.6); opacity: 0; } }

/* ---------- 3. Header / footer ---------- */
.topbar {
  position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid var(--line);
}
.topbar-in { display: flex; align-items: center; justify-content: space-between; gap: var(--s-4); min-height: 68px; }
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: var(--fs-20); letter-spacing: -.03em; text-decoration: none; }
.logo:hover { color: inherit; }
.logo-mark {
  display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px;
  background: linear-gradient(135deg, var(--brand-400), var(--brand-600)); color: #fff; box-shadow: 0 4px 12px rgb(212 47 34 / .25);
}
.logo-mark svg { width: 14px; height: 14px; }
.topbar nav { display: flex; align-items: center; gap: var(--s-4); }
@media (min-width: 768px) { .topbar nav { gap: var(--s-5); } }
@media (max-width: 359px) {
  .topbar nav { gap: var(--s-3); }
  /* admin uchun 3 havola (Admin, Kabinet, Chiqish): logotipda faqat belgi qoladi, nomi havolaning aria-label'ida */
  .topbar-in:has(nav a[href="/admin"]) .logo { gap: 0; font-size: 0; }
}
.topbar nav a:not(.btn), .topbar button.link { color: var(--muted); font-weight: 600; text-decoration: none; font-size: var(--fs-14); }
.topbar nav a:not(.btn):hover, .topbar button.link:hover { color: var(--text); }
.topbar nav a[aria-current="page"] {
  color: var(--text); text-decoration: underline; text-decoration-color: var(--brand-500);
  text-decoration-thickness: 2px; text-underline-offset: 8px;
}
.nav-anchors { display: none; gap: var(--s-5); }
@media (min-width: 768px) { .nav-anchors { display: flex; } }

.footer { border-top: 1px solid var(--line); padding: var(--s-7) 0; color: var(--muted); font-size: var(--fs-14); }
.footer-in { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-3) var(--s-5); }
.footer-in .logo { color: var(--text); font-size: var(--fs-18); margin-right: auto; }
.footer-in .logo-mark { width: 28px; height: 28px; border-radius: 8px; }
.footer a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
.footer a:hover, .footer a[aria-current="page"] { color: var(--text); }
@media (max-width: 599px) {
  .footer-in { flex-direction: column; align-items: flex-start; gap: 0; }
  .footer-in .logo { margin: 0 0 var(--s-2); }
}

/* ---------- 4. Tugmalar ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 var(--s-5); border: 1px solid transparent; border-radius: var(--r-pill);
  background: var(--brand-600); color: var(--on-brand); font: 600 var(--fs-16)/1 var(--font);
  text-decoration: none; cursor: pointer; white-space: nowrap;
  box-shadow: inset 0 1px 0 rgb(255 255 255 / .18), 0 1px 2px rgb(20 22 31 / .12);
  transition: background-color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease),
              transform var(--t-fast) var(--ease), box-shadow var(--t-base) var(--ease), color var(--t-fast) var(--ease);
}
.btn:hover { background: var(--brand-700); color: var(--on-brand); transform: translateY(-1px); box-shadow: var(--sh-brand); }
.btn:active { transform: translateY(0); box-shadow: none; }
.btn:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; transform: none; box-shadow: none; }
.btn-sm { min-height: 40px; padding: 0 18px; font-size: var(--fs-14); }
.btn-lg { min-height: 56px; padding: 0 28px; font-size: var(--fs-18); }
.btn-block { width: 100%; }
/* ikkilamchi: oq, chegarali */
.btn-ghost, .btn-secondary {
  background: var(--surface); color: var(--text); border-color: var(--line-strong); box-shadow: var(--sh-sm);
}
.btn-ghost:hover, .btn-secondary:hover { background: var(--bg-2); color: var(--text); border-color: var(--line-input); box-shadow: var(--sh-sm); }
.btn-danger { background: var(--surface); color: var(--err); border-color: color-mix(in srgb, var(--err) 45%, transparent); box-shadow: none; }
.btn-danger:hover { background: var(--err-soft); color: var(--err); box-shadow: none; }
/* Google: brend rangida (asosiy CTA) yoki oq; "G" doim rasmiy ranglarda, oq doira ichida */
.btn-google { background: #fff; color: #1f1f1f; border-color: #747775; box-shadow: var(--sh-sm); }
.btn-google:hover { background: #f6f6f4; color: #1f1f1f; box-shadow: var(--sh-md); }
.btn-google-brand { padding-left: 7px; }
.btn-google-brand .g-icon { width: 34px; height: 34px; padding: 7px; border-radius: var(--r-pill); background: #fff; }
.btn-google-brand.btn-lg { padding-left: 9px; }
.btn-google-brand.btn-lg .g-icon { width: 38px; height: 38px; padding: 8px; }
.g-icon { width: 20px; height: 20px; flex: none; }
button.link { background: none; border: 0; padding: 0; font: inherit; cursor: pointer; }
.text-link { display: inline-flex; align-items: center; gap: var(--s-2); font-weight: 600; text-decoration: none; color: var(--text); }
.text-link:hover { color: var(--brand-text); }
.text-link svg { width: 16px; height: 16px; transition: transform var(--t-base) var(--ease); }
.text-link:hover svg { transform: translateX(3px); }

/* ---------- 5. Komponentlar ---------- */
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md);
  padding: var(--s-5); box-shadow: var(--sh-sm);
}
@media (min-width: 768px) { .card { padding: var(--s-6); } }
.card > :last-child { margin-bottom: 0; }
.grid { display: grid; gap: var(--s-4); }
@media (min-width: 768px) { .grid { gap: var(--s-5); } }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); }

.badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: var(--r-pill);
  font-size: 13px; font-weight: 600; line-height: 1.3; background: var(--bg-2); color: var(--muted); white-space: nowrap;
}
.badge::before { content: ""; width: 6px; height: 6px; border-radius: var(--r-pill); background: currentColor; }
.badge-active, .badge-published, .badge-yt-done { background: var(--ok-soft); color: var(--ok); }
.badge-pending, .badge-rendering, .badge-yt-queued, .badge-yt-uploading { background: var(--warn-soft); color: var(--warn); }
.badge-draft, .badge-scheduled { background: var(--info-soft); color: var(--info); }
.badge-cancelled, .badge-expired, .badge-failed, .badge-yt-failed { background: var(--err-soft); color: var(--err); }
.badge-best { background: var(--brand-50); color: var(--brand-text); }

.flashes { padding-top: var(--s-4); display: grid; gap: var(--s-2); }
.flash, .notice { position: relative; padding: 14px var(--s-4) 14px 36px; border-radius: var(--r-sm); background: var(--info-soft); color: var(--info); font-weight: 500; }
.flash::before, .notice::before { content: ""; position: absolute; left: 16px; top: 22px; width: 8px; height: 8px; border-radius: var(--r-pill); background: currentColor; }
.flash-success { background: var(--ok-soft); color: var(--ok); }
.flash-error { background: var(--err-soft); color: var(--err); }
.notice { background: var(--warn-soft); color: var(--warn); margin-bottom: var(--s-5); }
.notice a { font-weight: 700; }
.notice-tight { margin: var(--s-3) 0; }

.field { display: grid; gap: 6px; margin-bottom: var(--s-4); }
.field label { font-weight: 600; font-size: var(--fs-14); }
input[type=text], input[type=number], input[type=datetime-local], select, input[type=file], textarea {
  width: 100%; min-height: 48px; padding: 10px 14px; border-radius: var(--r-sm); border: 1px solid var(--line-input);
  background: var(--surface); color: var(--text); font: inherit; font-size: var(--fs-16);
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
input:hover, select:hover, textarea:hover { border-color: var(--text); }
input:focus-visible, select:focus-visible, textarea:focus-visible,
input[type=datetime-local]:focus, input[type=datetime-local]:focus-within { outline: none; border-color: var(--brand-text); box-shadow: var(--focus-ring); }
textarea { resize: vertical; min-height: 96px; line-height: 1.5; }
.other-field[hidden] { display: none; }
.check { display: flex; align-items: center; gap: var(--s-2); margin-bottom: var(--s-2); cursor: pointer; font-size: var(--fs-14); }
.check input { width: 18px; height: 18px; accent-color: var(--brand-text); }

/* FAQ va admin tahrir */
.faq { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--sh-sm); padding: var(--s-2) var(--s-5); }
@media (min-width: 768px) { .faq { padding: var(--s-2) var(--s-6); } }
.faq details + details { border-top: 1px solid var(--line); }
.faq summary {
  display: flex; justify-content: space-between; align-items: center; gap: var(--s-4);
  padding: 20px 0; cursor: pointer; list-style: none; font-size: var(--fs-18); font-weight: 600; letter-spacing: -.01em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { color: var(--brand-text); }
.faq summary::after {
  content: ""; flex: none; width: 32px; height: 32px; border-radius: var(--r-pill); transition: transform var(--t-base) var(--ease);
  background:
    linear-gradient(var(--brand-text), var(--brand-text)) center / 12px 2px no-repeat,
    linear-gradient(var(--brand-text), var(--brand-text)) center / 2px 12px no-repeat,
    var(--brand-50);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0 0 20px; max-width: 68ch; color: var(--muted); }
details.edit { border: 1px solid var(--line); border-radius: var(--r-sm); padding: var(--s-2) var(--s-3); }
details.edit summary { cursor: pointer; font-size: var(--fs-14); font-weight: 600; }
details.edit[open] summary { margin-bottom: var(--s-3); }

/* progress (CSP: foiz <progress> orqali) */
.progress-row { margin-bottom: var(--s-5); }
.progress-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-1) var(--s-3); font-size: var(--fs-14); margin-bottom: var(--s-2); }
.progress-label { display: inline-flex; flex-wrap: wrap; align-items: center; gap: var(--s-1) var(--s-2); font-weight: 600; }
.progress-value { color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.progress-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 0 6px; margin-top: var(--s-2); font-size: var(--fs-14); color: var(--muted); font-variant-numeric: tabular-nums; }
.progress-pct { font-weight: 700; color: var(--text); }
.progress-done { display: inline-flex; align-items: center; gap: 6px; color: var(--ok); font-weight: 700; }
.progress-done::before, .stepper-item.is-done .stepper-dot::after {
  content: ""; width: 16px; height: 16px; flex: none; background: currentColor;
  -webkit-mask: var(--icon-check) center / contain no-repeat; mask: var(--icon-check) center / contain no-repeat;
}
progress.bar {
  -webkit-appearance: none; appearance: none; display: block; width: 100%; height: 10px;
  border: 0; border-radius: var(--r-pill); background: var(--track); overflow: hidden; color: var(--brand-text);
}
progress.bar::-webkit-progress-bar { background: var(--track); border-radius: var(--r-pill); }
progress.bar::-webkit-progress-value { background: linear-gradient(90deg, var(--brand-400), var(--brand-600)); border-radius: var(--r-pill); }
progress.bar::-moz-progress-bar { background: linear-gradient(90deg, var(--brand-400), var(--brand-600)); border-radius: var(--r-pill); }
progress.bar.done { color: var(--ok); }
progress.bar.done::-webkit-progress-value { background: var(--ok); }
progress.bar.done::-moz-progress-bar { background: var(--ok); }
.or { display: flex; align-items: center; gap: var(--s-3); margin: calc(-1 * var(--s-2)) 0 var(--s-4); color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }

.kv { display: grid; grid-template-columns: fit-content(45%) minmax(0, 1fr); gap: var(--s-2) var(--s-4); margin: 0; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.row-actions { display: flex; flex-wrap: wrap; gap: var(--s-2); align-items: center; }
.row-actions input[type=number], .row-actions select { width: auto; min-height: 40px; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--surface); box-shadow: var(--sh-sm); }
table { width: 100%; border-collapse: collapse; font-size: var(--fs-14); }
th, td { text-align: left; padding: 14px var(--s-4); border-bottom: 1px solid var(--line); white-space: nowrap; }
th { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); background: var(--bg-2); }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: var(--brand-50); }
td a { font-weight: 600; text-decoration: none; }
.empty { text-align: center; padding: var(--s-7) var(--s-4); color: var(--muted); }
.disclaimer { font-size: var(--fs-14); color: var(--muted); margin-top: var(--s-5); max-width: 72ch; }

/* ikonka plitkasi */
.icon-tile { display: grid; place-items: center; width: 44px; height: 44px; border-radius: var(--r-sm); background: var(--brand-50); color: var(--brand-text); flex: none; }
.icon-tile svg { width: 22px; height: 22px; }

/* ---------- 6. Landing ---------- */
.section { padding: var(--section) 0; }
.section-soft { background: var(--bg-2); }
.section:not(.section-soft) + .section:not(.section-soft) { padding-top: 0; }  /* bir xil fonli bo'limlar orasida ikki baravar bo'shliq bo'lmasin */
.section-head { display: grid; gap: var(--s-3); margin-bottom: var(--s-7); max-width: 720px; }
.section-head h2, .section-head p { margin: 0; }
.section-head p { font-size: var(--fs-18); color: var(--muted); }
.lead { font-size: clamp(var(--fs-16), 1rem + .35vw, var(--fs-20)); line-height: 1.6; color: var(--muted); max-width: 52ch; }

.hero { position: relative; padding: clamp(40px, 6vw, 96px) 0 clamp(64px, 8vw, 112px); overflow: hidden; isolation: isolate; }
.hero::before {
  content: ""; position: absolute; z-index: -1; top: -30%; right: -20%; width: 80vw; max-width: 960px; aspect-ratio: 1;
  background: radial-gradient(closest-side, rgb(255 77 61 / .13), transparent 72%);
}
.hero-grid { display: grid; gap: var(--s-8); align-items: center; }
.hero-grid > * { min-width: 0; }
@media (min-width: 1024px) { .hero-grid { grid-template-columns: 6fr 5fr; } }
.hero h1 { margin-bottom: var(--s-5); }
@media (min-width: 768px) { .hero h1 { max-width: 13ch; } }
.hero-cta { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-3); margin-top: var(--s-6); }
.hero-note { display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-5); margin: var(--s-5) 0 0; color: var(--muted); font-size: var(--fs-14); }
.hero-note span { display: inline-flex; align-items: center; gap: var(--s-2); }
.hero-note span::before {
  content: ""; width: 18px; height: 18px; border-radius: var(--r-pill); flex: none;
  background: var(--ok-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 18 18'%3E%3Cpath d='M5 9.2l2.6 2.6L13 6.4' fill='none' stroke='%2315803d' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 18px no-repeat;
}

/* "Google nimani so'raydi?": JS'siz <details> */
.perm { margin-top: var(--s-3); max-width: 560px; }
.perm summary {
  display: inline-flex; align-items: center; gap: var(--s-2); min-height: 44px; cursor: pointer; list-style: none;
  font-weight: 600; color: var(--text); border-radius: var(--r-pill);
}
.perm summary::-webkit-details-marker { display: none; }
.perm summary:hover { color: var(--brand-text); }
.perm summary svg { width: 20px; height: 20px; color: var(--brand-text); flex: none; }
.perm summary::after {
  content: ""; width: 16px; height: 16px; background: currentColor; transition: transform var(--t-base) var(--ease);
  -webkit-mask: var(--icon-chevron) center / contain no-repeat; mask: var(--icon-chevron) center / contain no-repeat;
}
.perm[open] summary::after { transform: rotate(180deg); }
.perm-body { margin-top: var(--s-2); padding: var(--s-5); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--sh-md); }
.perm-intro { font-size: var(--fs-14); color: var(--muted); }
.perm-list { list-style: none; counter-reset: perm; margin: 0 0 var(--s-4); padding: 0; display: grid; gap: var(--s-4); }
.perm-list li { counter-increment: perm; position: relative; padding-left: 40px; }
.perm-list li::before {
  content: counter(perm); position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 28px; height: 28px;
  border-radius: var(--r-pill); background: var(--brand-50); color: var(--brand-text); font-size: var(--fs-14); font-weight: 800;
}
.perm-list strong { display: block; line-height: 1.4; }
.perm-en { display: block; font-size: 12px; color: var(--muted); line-height: 1.4; }
.perm-list p { margin: var(--s-1) 0 0; font-size: var(--fs-14); color: var(--muted); }
.perm-warn { padding: 10px 14px; border-radius: var(--r-sm); background: var(--warn-soft); color: var(--warn); font-size: var(--fs-14); font-weight: 600; }
.perm-note { margin: 0; font-size: var(--fs-14); color: var(--muted); }
.perm-note b { color: var(--text); }

/* imzo elementi: kabinet namunasi + suzib chiqadigan bildirishnoma */
.tablo { position: relative; margin: 0 0 var(--s-5); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: var(--s-5); box-shadow: var(--sh-lg); }
@media (min-width: 768px) { .tablo { padding: var(--s-6); } }
.tablo-head { display: flex; align-items: center; justify-content: space-between; gap: var(--s-3); margin-bottom: var(--s-2); }
.tablo-title { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; }
.tag { display: inline-block; padding: 4px 10px; border-radius: var(--r-pill); background: var(--bg-2); color: var(--muted); font-size: 12px; font-weight: 600; }
.meter { padding: var(--s-4) 0; }
.meter + .meter { border-top: 1px solid var(--line); }
.meter-top { display: flex; align-items: baseline; justify-content: space-between; gap: var(--s-3); margin-bottom: 10px; }
.meter-label { font-size: var(--fs-14); color: var(--muted); }
.meter-value { font-size: var(--fs-25); font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.meter-value small { font-size: var(--fs-14); font-weight: 600; color: var(--muted); letter-spacing: 0; }
@media (max-width: 479px) { .meter-top { flex-direction: column; align-items: flex-start; gap: 2px; } }
.track { height: 10px; border-radius: var(--r-pill); background: var(--track); overflow: hidden; }
.fill { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--brand-400), var(--brand-600)); transform-origin: left; animation: fill 1.4s var(--ease) .3s both; }
.w-43 { width: 43%; } .w-64 { width: 64%; } .w-71 { width: 71%; }
@keyframes fill { from { transform: scaleX(0); } }
.queue { margin: var(--s-3) 0 0; padding: var(--s-4); list-style: none; display: grid; gap: 10px; background: var(--bg-2); border-radius: var(--r-sm); }
.queue-title { font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.queue li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: var(--s-1) var(--s-3); font-size: var(--fs-14); }
.queue li > span:first-child { white-space: nowrap; }  /* "12:00 Uzun video" bo'linmaydi: tor ekranda belgi pastga tushadi */
.queue .time { font-weight: 700; font-variant-numeric: tabular-nums; margin-right: var(--s-2); }
.toast {
  position: absolute; left: var(--s-4); bottom: -28px; display: flex; align-items: center; gap: var(--s-3);
  padding: 10px 20px 10px 10px; border-radius: var(--r-pill); background: var(--surface); border: 1px solid var(--line);
  box-shadow: var(--sh-md); font-size: var(--fs-14); font-weight: 600; line-height: 1.3; animation: rise .6s var(--ease) 1.2s both;
}
.toast-icon { display: grid; place-items: center; width: 32px; height: 32px; border-radius: var(--r-pill); background: var(--ok); color: #fff; flex: none; }
.toast-icon svg { width: 14px; height: 14px; }
.toast small { display: block; font-weight: 400; color: var(--muted); font-size: 12px; }
@media (min-width: 1024px) { .toast { left: -36px; } }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } }

/* ishonch qatori */
.trust { padding-bottom: var(--section); }
.trust-card { display: grid; gap: var(--s-5); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--sh-sm); padding: var(--s-5); }
@media (min-width: 600px) { .trust-card { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .trust-card { grid-template-columns: repeat(4, 1fr); padding: var(--s-6); } }
.trust-item { display: flex; gap: var(--s-3); align-items: flex-start; }
.trust-item strong { display: block; font-size: var(--fs-16); line-height: 1.35; }
.trust-item span { font-size: var(--fs-14); color: var(--muted); line-height: 1.5; }

/* namuna videolar: mobilda gorizontal scroll-snap qator, kengroq ekranda grid */
.trust + .samples { padding-top: 0; }
.samples-row {
  list-style: none; margin: 0 calc(-1 * var(--s-4)); padding: 0 var(--s-4) var(--s-2);
  display: grid; grid-auto-flow: column; grid-auto-columns: min(74%, 260px); gap: var(--s-3);
  overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: var(--s-4); overscroll-behavior-x: contain;
}
.sample { scroll-snap-align: start; min-width: 0; }
.sample-media { position: relative; aspect-ratio: 9 / 16; border-radius: var(--r-md); overflow: hidden; background: #000; box-shadow: var(--sh-md); }
.sample-media video { display: block; width: 100%; height: 100%; object-fit: cover; }
.sample-flag {
  position: absolute; top: var(--s-2); left: var(--s-2); max-width: calc(100% - var(--s-4)); padding: 4px 10px; border-radius: var(--r-pill);
  background: color-mix(in srgb, var(--ink) 80%, transparent); color: var(--on-ink); font-size: 12px; font-weight: 600; line-height: 1.4; pointer-events: none;
}
.sample-meta { display: grid; justify-items: start; gap: var(--s-2); padding: var(--s-3) var(--s-1) 0; }
.sample-title { margin: 0; font-weight: 600; line-height: 1.4; }
.chip { display: inline-block; padding: 4px 10px; border-radius: var(--r-pill); background: var(--brand-50); color: var(--brand-text); font-size: 13px; font-weight: 600; }
@media (min-width: 768px) {
  .samples-row { margin: 0; padding: 0; grid-auto-flow: row; grid-auto-columns: auto; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: var(--s-5); overflow: visible; }
}

/* muammo -> yechim */
.versus { display: grid; gap: var(--s-4); }
@media (min-width: 900px) { .versus { grid-template-columns: 1fr 1fr; gap: var(--s-5); } }
.versus-col { border-radius: var(--r-md); padding: var(--s-6); border: 1px solid var(--line); }
.versus-col h3 { margin-bottom: var(--s-5); }
.versus-old { background: var(--bg-2); color: var(--muted); }
.versus-new { background: var(--surface); box-shadow: var(--sh-md); border-color: var(--brand-200); }
.ticks { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s-4); }
.ticks li { position: relative; padding-left: 38px; }
.ticks li::before {
  content: ""; position: absolute; left: 0; top: 0; width: 26px; height: 26px; border-radius: var(--r-pill);
  background: var(--brand-600) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 26 26'%3E%3Cpath d='M8 13.4l3.4 3.4L18.5 9.6' fill='none' stroke='white' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 26px no-repeat;
}
.ticks.cross li::before {
  background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 26 26'%3E%3Cpath d='M9.5 9.5l7 7m0-7l-7 7' fill='none' stroke='%23858a98' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E") center / 26px no-repeat;
  border: 1px solid var(--line-strong);
}

/* foydalar: 2x2 kartalar */
.benefits { display: grid; gap: var(--s-4); }
@media (min-width: 768px) { .benefits { grid-template-columns: repeat(2, 1fr); gap: var(--s-5); } }
.benefit {
  display: grid; gap: var(--s-2); align-content: start; padding: var(--s-6); background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--sh-sm);
  transition: transform var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease);
}
.benefit:hover { transform: translateY(-2px); box-shadow: var(--sh-md); }
.benefit-num {
  display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: var(--s-3); border-radius: var(--r-sm);
  background: var(--brand-50); color: var(--brand-text); font-weight: 800; font-variant-numeric: tabular-nums;
}
.benefit h3 { font-size: var(--fs-20); margin: 0; }
.benefit p { margin: 0; color: var(--muted); }

/* qadamlar */
.steps { display: grid; gap: var(--s-4); list-style: none; padding: 0; margin: 0; }
@media (min-width: 900px) { .steps { grid-template-columns: repeat(3, 1fr); gap: var(--s-5); } }
.step { position: relative; padding: var(--s-6); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--sh-sm); }
.step-num {
  display: grid; place-items: center; width: 48px; height: 48px; margin-bottom: var(--s-5); border-radius: var(--r-pill);
  background: linear-gradient(135deg, var(--brand-400), var(--brand-600)); color: #fff; font-weight: 800; font-size: var(--fs-20);
  box-shadow: 0 6px 16px rgb(212 47 34 / .25);
}
.step h3 { margin-bottom: var(--s-2); }
.step p { color: var(--muted); margin: 0; }

/* narxlar. Karta 5 qismdan iborat (bosh, narx, imkoniyatlar, izoh, tugma). >= 768px da subgrid: yonma-yon kartalarning
   narx qatorlari va tugmalari bir chiziqda turadi. 2 ustunda toq oxirgi karta to'liq kenglikda (yolg'iz yarim karta yo'q). */
.plan { position: relative; display: flex; flex-direction: column; transition: transform var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease); }
.plans { display: grid; gap: var(--s-4); align-items: stretch; }
@media (min-width: 768px) {
  .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-5); }
  .plan { padding: 40px; }
  .plan:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .plan:last-child:nth-child(odd) .plan-features { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: var(--s-6); }
}
@supports (grid-template-rows: subgrid) {
  @media (min-width: 768px) { .plan { display: grid; grid-row: span 5; grid-template-rows: subgrid; row-gap: 0; } }
}
@media (min-width: 1100px) {
  .plans { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .plan { padding: var(--s-6); }
  .plan:last-child:nth-child(odd) { grid-column: auto; }
  .plan:last-child:nth-child(odd) .plan-features { grid-template-columns: minmax(0, 1fr); }
}
.plan:hover { transform: translateY(-2px); box-shadow: var(--sh-md); }
.plan-head { margin-bottom: var(--s-5); }
.plan-tags { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-bottom: var(--s-5); }
.plan-tag, .plan-flag { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: var(--r-pill); font-size: 13px; font-weight: 600; line-height: 1.3; }
.plan-tag { background: var(--bg-2); color: var(--muted); }
.plan-flag::before { content: ""; width: 14px; height: 14px; flex: none; background: currentColor; -webkit-mask: var(--icon-check) center / contain no-repeat; mask: var(--icon-check) center / contain no-repeat; }
.plan-flag-chosen { background: var(--brand-50); color: var(--brand-text); box-shadow: inset 0 0 0 1px var(--brand-200); }
.plan-flag-fit { background: var(--info-soft); color: var(--info); }
.plan-flag-current { background: var(--ok-soft); color: var(--ok); }
.plan-name { font-size: var(--fs-25); font-weight: 800; letter-spacing: -.025em; margin: 0; }
.plan-audience { color: var(--muted); margin: var(--s-1) 0 0; }
.plan-price { font-size: clamp(1.75rem, 1rem + 1.6vw, var(--fs-39)); font-weight: 800; line-height: 1; letter-spacing: -.04em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.plan-period { color: var(--muted); font-size: var(--fs-14); margin-top: var(--s-2); }
.plan ul { list-style: none; padding: var(--s-5) 0 0; margin: var(--s-5) 0 0; display: grid; gap: var(--s-3); align-content: start; flex: 1; border-top: 1px solid var(--line); }
.plan-action { padding-top: var(--s-6); }
.plan li { position: relative; padding-left: 32px; }
.plan li::before {
  content: ""; position: absolute; left: 0; top: 1px; width: 22px; height: 22px; border-radius: var(--r-pill);
  background: var(--brand-50) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 22'%3E%3Cpath d='M6.5 11.3l3 3 6-6.2' fill='none' stroke='%23d42f22' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 22px no-repeat;
}
.plan .btn { width: 100%; white-space: normal; text-align: center; line-height: 1.25; padding-block: var(--s-2); }
.plan.featured { border: 2px solid var(--brand-500); box-shadow: var(--sh-lg); }
.plan.featured .plan-tag { background: var(--brand-600); color: #fff; }
.plan-tag-beta { background: var(--ink); color: #fff; letter-spacing: .04em; }
.plan-note { margin: var(--s-5) 0 0; padding: 10px 14px; border-radius: var(--r-sm); background: var(--bg-2); color: var(--muted); font-size: var(--fs-14); }
.plan.current { border: 2px solid var(--ok); }
.plan[data-scroll-to] { scroll-margin-top: 96px; }

/* YPP: monetizatsiya shartlari */
.ypp-board { display: grid; gap: var(--s-3); align-items: stretch; }
@media (min-width: 900px) { .ypp-board { grid-template-columns: 1fr auto 1fr auto 1fr; gap: var(--s-4); } }
.ypp-cell { padding: var(--s-6); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--sh-sm); }
.ypp-num { font-size: clamp(var(--fs-49), 2.2rem + 2.4vw, 4.5rem); font-weight: 800; line-height: 1; letter-spacing: -.045em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ypp-cell span { display: block; margin-top: var(--s-3); color: var(--muted); }
.ypp-join { align-self: center; justify-self: center; padding: 6px 14px; border-radius: var(--r-pill); background: var(--brand-50); color: var(--brand-text); font-weight: 700; font-size: var(--fs-14); text-transform: uppercase; letter-spacing: .06em; }

.faq-wrap { display: grid; gap: var(--s-6); }
@media (min-width: 1024px) { .faq-wrap { grid-template-columns: 4fr 8fr; gap: var(--s-7); } }
.faq-wrap .section-head { align-self: start; margin-bottom: 0; }

/* yakuniy CTA: yumaloq siyoh panel */
.final-panel {
  position: relative; overflow: hidden; isolation: isolate; border-radius: var(--r-lg); padding: clamp(40px, 6vw, 88px) clamp(24px, 6vw, 88px);
  background: var(--ink); color: var(--on-ink); box-shadow: var(--sh-lg);
}
.final-panel::before {
  content: ""; position: absolute; z-index: -1; right: -15%; top: -60%; width: 70%; aspect-ratio: 1;
  background: radial-gradient(closest-side, rgb(255 77 61 / .45), transparent 70%);
}
.final-panel h2 { color: var(--on-ink); max-width: 16ch; }
.final-panel .lead { color: var(--on-ink-muted); }
.final-panel .row-actions { gap: var(--s-4) var(--s-6); margin-top: var(--s-6); }
.final-panel .text-link { color: var(--on-ink); }
.final-panel .text-link:hover { color: var(--brand-200); }
.final-panel .hl { color: var(--brand-400); }
.final-panel :focus-visible { outline-color: #fff; }

/* ---------- 7. Ilova sahifalari ---------- */
.page { padding-block: var(--s-7) var(--s-9); }  /* .wrap yon bo'shlig'iga tegmaydi */
.page-narrow { max-width: 820px; }
.page-head { margin-bottom: var(--s-6); max-width: 760px; }
.page-head h1 { font-size: clamp(var(--fs-31), 1.5rem + 1.6vw, var(--fs-49)); }
.page-head p { color: var(--muted); font-size: var(--fs-18); margin: 0; }
.page-head .eyebrow { font-size: var(--fs-14); color: var(--brand-text); margin-bottom: var(--s-4); }
.section-title { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: var(--s-1) var(--s-3); margin: var(--s-7) 0 var(--s-4); }
.section-title h2 { margin: 0; font-size: var(--fs-25); }

/* bosqichlar: Kirish ✓ · Yo'nalish · Tarif · To'lov */
.stepper { list-style: none; margin: 0 0 var(--s-6); padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); max-width: 560px; }
.stepper-item { position: relative; display: grid; justify-items: start; gap: 6px; font-size: var(--fs-14); font-weight: 600; line-height: 1.3; color: var(--muted); }
.stepper-item:not(:last-child)::after { content: ""; position: absolute; top: 13px; left: 36px; right: var(--s-2); height: 2px; border-radius: var(--r-pill); background: var(--line-strong); }
.stepper-item.is-done::after { background: var(--brand-500); }
.stepper-dot {
  display: grid; place-items: center; width: 28px; height: 28px; border-radius: var(--r-pill); border: 2px solid var(--line-strong);
  background: var(--surface); font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums;
}
.stepper-item.is-done .stepper-dot { background: var(--brand-600); border-color: var(--brand-600); color: var(--on-brand); }
.stepper-item.is-current { color: var(--text); }
.stepper-item.is-current .stepper-dot { border-color: var(--brand-600); background: var(--brand-50); color: var(--brand-text); box-shadow: var(--focus-ring); }

.niches { display: grid; gap: var(--s-3); grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr)); margin: 0 0 var(--s-5); }
.niche { position: relative; }
.niche input { position: absolute; opacity: 0; pointer-events: none; }
.niche label {
  position: relative; display: block; height: 100%; padding: 18px 48px 18px 18px; border-radius: var(--r-md); cursor: pointer;
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--sh-sm);
  transition: border-color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease), box-shadow var(--t-base) var(--ease), transform var(--t-fast) var(--ease);
}
.niche label::after {
  content: ""; position: absolute; top: 18px; right: 16px; width: 20px; height: 20px; border-radius: var(--r-pill);
  border: 1.5px solid var(--line-input); background: var(--surface);
}
.niche label:hover { border-color: var(--brand-200); box-shadow: var(--sh-md); transform: translateY(-1px); }
.niche label strong { display: block; margin-bottom: 2px; }
.niche label span { font-size: var(--fs-14); color: var(--muted); }
.niche input:checked + label { border-color: var(--brand-500); background: var(--brand-50); box-shadow: 0 0 0 1px var(--brand-500); }
.niche input:checked + label::after {
  border-color: var(--brand-text);
  background: var(--brand-600) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M6 10.3l2.6 2.6L14 7.6' fill='none' stroke='white' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 20px no-repeat;
}
.niche input:focus-visible + label { box-shadow: var(--focus-ring); }
.niches-set { border: 0; margin: 0; padding: 0; min-width: 0; }
@media (max-width: 599px) {
  /* 16 ta yo'nalish 2 ustunda: faqat nomi, izoh ekran o'quvchi uchun qoladi; belgi faqat tanlanganda */
  .niches { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s-2); }
  .niche label { display: flex; align-items: center; min-height: 56px; padding: var(--s-3); border-radius: var(--r-sm); font-size: var(--fs-14); line-height: 1.35; }
  .niche label strong { margin: 0; font-weight: 600; }
  .niche label::after { display: none; }
  .niche input:checked + label::after { display: block; top: -7px; right: -7px; }
  .niche-hint {
    position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
  }
}
.sticky-actions {
  position: sticky; bottom: 0; z-index: 10; margin: var(--s-5) calc(-1 * var(--s-4)) 0;
  padding: var(--s-3) var(--s-4) calc(var(--s-3) + env(safe-area-inset-bottom));
  background: color-mix(in srgb, var(--bg) 90%, transparent); backdrop-filter: saturate(1.4) blur(14px); border-top: 1px solid var(--line);
}
.sticky-actions .btn { width: 100%; }
@media (min-width: 600px) {
  .sticky-actions { margin-inline: 0; padding-inline: 0; }
  .sticky-actions .btn { width: auto; min-width: 240px; }
}

.dash-head { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-4); margin-bottom: var(--s-6); }
.avatar { width: 64px; height: 64px; border-radius: var(--r-pill); object-fit: cover; background: var(--bg-2); flex: none; box-shadow: 0 0 0 4px var(--surface), 0 0 0 5px var(--line); }
.dash-title { flex: 1; min-width: 200px; }
.dash-title h1 { margin: 0 0 var(--s-1); font-size: clamp(var(--fs-25), 1.4rem + 1.2vw, var(--fs-39)); }
/* statistika: mobilda bitta kartada 3 ustun (progress birinchi ekranga yaqin), >= 768px da alohida kartalar */
.stats {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin-bottom: var(--s-4);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--sh-sm);
}
.stat { min-width: 0; padding: var(--s-3) var(--s-2); text-align: center; }
.stat + .stat { border-left: 1px solid var(--line); }
.stat-label { color: var(--muted); font-size: 12px; font-weight: 600; line-height: 1.3; }
.stat-value { font-size: var(--fs-20); font-weight: 800; line-height: 1.1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; margin-top: var(--s-1); white-space: nowrap; }
@media (min-width: 768px) {
  .stats { gap: var(--s-4); margin-bottom: var(--s-5); background: none; border: 0; box-shadow: none; }
  .stat { padding: var(--s-5); text-align: left; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--sh-sm); }
  .stat + .stat { border-left: 1px solid var(--line); }
  .stat-label { font-size: var(--fs-14); }
  .stat-value { font-size: var(--fs-39); letter-spacing: -.04em; margin-top: var(--s-2); }
}
.dash-first { margin-bottom: var(--s-5); }
.sub-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-2) var(--s-3); margin-bottom: var(--s-2); }
.sub-top .card-title { margin: 0; }
.sub-plan { color: var(--muted); }
.sub-plan strong { color: var(--text); }
.sub-days strong { font-size: var(--fs-25); letter-spacing: -.02em; }
.sub-card .btn { white-space: normal; text-align: center; line-height: 1.25; padding-block: var(--s-2); }
.pay { border-color: var(--brand-200); }
.pay-steps { list-style: none; counter-reset: pay; margin: var(--s-5) 0; padding: 0; display: grid; gap: var(--s-4); }
.pay-steps li { counter-increment: pay; position: relative; display: grid; align-content: start; gap: var(--s-1); padding-left: 44px; min-width: 0; }
.pay-steps li::before {
  content: counter(pay); position: absolute; left: 0; top: -3px; display: grid; place-items: center; width: 30px; height: 30px;
  border-radius: var(--r-pill); background: var(--brand-50); color: var(--brand-text); font-size: var(--fs-14); font-weight: 800;
}
.pay-steps li > span { color: var(--muted); font-size: var(--fs-14); }
@media (min-width: 900px) { .pay-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-5); } }
.pay-order { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-2); color: var(--muted); font-size: var(--fs-14); }
.order { display: inline-flex; flex-wrap: wrap; align-items: center; gap: var(--s-2) var(--s-3); }
.order-id { font-size: var(--fs-20); font-weight: 800; color: var(--text); font-variant-numeric: tabular-nums; letter-spacing: -.01em; }
.copy-btn.is-done, .copy-btn.is-done:hover { background: var(--surface); color: var(--ok); border-color: var(--ok); }
.pay-cta { display: grid; justify-items: start; gap: var(--s-2); margin-bottom: var(--s-4); }
.pay-phone { margin: 0; color: var(--muted); font-size: var(--fs-14); }
.pay-phone a { color: var(--text); font-weight: 600; white-space: nowrap; }
.pay-refund { padding: 10px 14px; border-radius: var(--r-sm); background: var(--ok-soft); color: var(--ok); font-size: var(--fs-14); font-weight: 600; }
@media (max-width: 599px) {
  .pay .btn:not(.copy-btn), .sub-card .btn:not(.copy-btn) { width: 100%; }
  .pay-cta { justify-items: stretch; }
}

.video-section { margin-top: var(--s-7); }
.video-section .section-title { margin: 0 0 var(--s-2); }
.section-sub { margin: 0 0 var(--s-4); }
.video-section .empty { margin-top: var(--s-4); }
.queue-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s-3); grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); }
.q-item {
  display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: var(--s-4); align-items: start; padding: var(--s-3);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--sh-sm);
}
.q-item.long { grid-template-columns: 148px minmax(0, 1fr); }
.q-media video, .q-media .video-ph { border-radius: var(--r-sm); }
.q-body { display: grid; gap: var(--s-2); align-content: start; min-width: 0; padding-top: var(--s-1); }
.q-when { display: grid; font-size: var(--fs-18); font-weight: 800; line-height: 1.25; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.q-when .muted { font-size: 12px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; }
.q-badges { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-2); }
.q-badges .badge { white-space: normal; }
@media (max-width: 479px) {
  /* uzun video (16:9) tor ekranda tepada to'liq kenglikda: ko'rish qulay, matn siqilmaydi */
  .q-item.long { grid-template-columns: minmax(0, 1fr); gap: var(--s-3); }
}
.videos { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s-4); align-items: start; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); }
/* kabinet "Chiqqanlar": mobilda 2 ustun, uzun video 2 ustun egallaydi (admin sahifasidagi .videos ga tegmaydi) */
.video-section .videos { gap: var(--s-3); grid-template-columns: repeat(2, minmax(0, 1fr)); }
.video-section .video-card.long { grid-column: span 2; }
@media (min-width: 768px) { .video-section .videos { gap: var(--s-4); grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); } }
.video-card { min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md); box-shadow: var(--sh-sm); overflow: hidden; display: flex; flex-direction: column; }
.video-card video, .q-media video, .video-ph, .video-thumb { display: block; width: 100%; aspect-ratio: 9 / 16; background: #000; object-fit: contain; }
.video-card.long video, .video-card.long .video-ph, .video-card.long .video-thumb,
.q-item.long video, .q-item.long .video-ph { aspect-ratio: 16 / 9; }
.video-ph {
  display: grid; place-items: center; align-content: center; gap: var(--s-2); padding: var(--s-2); text-align: center;
  color: var(--muted); font-size: 13px; line-height: 1.35; background: var(--bg-2); overflow-wrap: anywhere;
}
.video-ph::before {
  content: ""; width: 24px; height: 24px; background: currentColor;
  -webkit-mask: var(--icon-video) center / contain no-repeat; mask: var(--icon-video) center / contain no-repeat;
}
.q-media .video-ph { padding: var(--s-2) 6px; font-size: 12px; }
.video-thumb { position: relative; overflow: hidden; }
.video-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.video-thumb::after {
  content: ""; position: absolute; inset: 0; margin: auto; width: 44px; height: 44px; border-radius: var(--r-pill);
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M5.5 3.5v9l7-4.5z' fill='white'/%3E%3C/svg%3E") center / 18px no-repeat, color-mix(in srgb, var(--ink) 75%, transparent);
}
.video-meta { padding: var(--s-4); display: grid; gap: var(--s-2); }
@media (max-width: 767px) { .video-section .video-meta { padding: var(--s-3); gap: 6px; } }
.video-title { font-weight: 700; line-height: 1.35; }
.video-section .video-title { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.video-link { font-weight: 600; color: var(--brand-text); }
.danger { margin-top: var(--s-8); border-top: 1px solid var(--line); padding-top: var(--s-5); }
.danger .card-title { font-size: var(--fs-16); }

.prose { max-width: 72ch; }
.prose h1 { margin-bottom: var(--s-5); font-size: clamp(var(--fs-31), 1.5rem + 1.6vw, var(--fs-49)); }
.prose h2 { font-size: var(--fs-25); margin: var(--s-7) 0 var(--s-3); }
.prose ul { padding-left: 1.2em; }
.prose li { margin-bottom: var(--s-2); }
.prose a { color: var(--brand-text); }

/* ---------- 8. Harakat va qulaylik ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .rec::after { display: none; }
}

/* Footer: Instagram ikonkasi */
.footer-ig { display: inline-flex; align-items: center; gap: 6px; }
.footer-ig .ig { width: 16px; height: 16px; flex: none; }
