/* Logotip shrifti (Depos oilasi bilan bir xil): Manrope 800, faqat lotin to'plami. O'z serverimizdan —
   tashqi so'rov yo'q (CSP font-src 'self'). Litsenziya: SIL OFL 1.1, fonts/Manrope-OFL.txt */
@font-face {
  font-family: 'Manrope';
  src: url("../fonts/manrope-latin-800-normal.63c74bc8894a.woff2") format('woff2');
  font-weight: 800; font-style: normal; font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074,
    U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* =========================================================
   DESIGN TOKENS
   ========================================================= */
:root {
  --bg: #F7F8FA;
  --surface: #FFFFFF;
  --surface-2: #F0F1F5;
  --text: #111318;
  --text-2: #6B7280;
  --border: #E7E9EE;
  --border-strong: #D7DAE2;

  --brand: #0D9488;
  --brand-hover: #0B7A70;
  --brand-soft: #E6F7F5;

  --success: #16A34A;
  --success-soft: #EAF7EE;
  --warning: #F59E0B;
  --warning-soft: #FEF4E3;
  --danger: #EF4444;
  --danger-soft: #FDECEC;

  --telegram: #229ED9;
  --instagram: #C13584;

  --dark: #111318;

  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 16px;

  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px;
  --space-5: 20px; --space-6: 24px; --space-8: 32px; --space-10: 40px; --space-12: 48px;

  --shadow-xs: 0 1px 2px rgba(17,19,24,.04);
  --shadow-sm: 0 2px 8px rgba(17,19,24,.06);
  --shadow-md: 0 8px 24px rgba(17,19,24,.08);
  --shadow-focus: 0 0 0 3px rgba(13,148,136,.16);

  --ease: cubic-bezier(.2,.8,.2,1);
  --fast: 160ms;

  --header-h: 68px;
  --bottomnav-h: 60px;
}

* { box-sizing: border-box; min-width: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: hidden; max-width: 100vw; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', 'Noto Sans', Arial, sans-serif;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  max-width: 100vw;
}
h1, h2, h3, h4 { font-weight: 700; letter-spacing: -.01em; margin: 0; overflow-wrap: break-word; }
p { margin: 0; overflow-wrap: break-word; }
a { color: var(--brand); text-decoration: none; transition: color var(--fast) var(--ease); }
a:hover { color: var(--brand-hover); }
button { font-family: inherit; }
img, svg { max-width: 100%; display: block; }

/* =========================================================
   LAYOUT
   ========================================================= */
.container { max-width: 1200px; margin: 0 auto; padding: 0 var(--space-6); }
.page { padding-bottom: var(--space-12); }
@media (max-width: 640px) {
  .container { padding: 0 var(--space-4); }
}

/* =========================================================
   HEADER (desktop)
   ========================================================= */
.site-header {
  position: sticky; top: 0; z-index: 200;
  height: var(--header-h);
  background: rgba(247,248,250,.92);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center;
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; gap: var(--space-6); width: 100%; }
.header-left { display: flex; align-items: center; gap: var(--space-8); min-width: 0; }
/* Logotip — Depos oilasi uslubi: kichik harfli so'z-belgisi, oxirida brend rangidagi nuqta ("delot.") */
.logo {
  font-family: 'Manrope', 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  font-weight: 800; font-size: 27px; line-height: 1; letter-spacing: -0.5px; color: #17202B;
  display: inline-flex; align-items: baseline; flex-shrink: 0; text-decoration: none;
}
.logo:hover { color: #17202B; }
.logo-dot { color: var(--brand); }
.main-nav { display: flex; align-items: center; gap: var(--space-2); }
.main-nav a {
  color: var(--text-2); font-size: 14.5px; font-weight: 600; padding: 8px 12px;
  border-radius: var(--radius-sm); transition: all var(--fast) var(--ease);
}
.main-nav a:hover { color: var(--text); background: var(--surface-2); }

.header-right { display: flex; align-items: center; gap: var(--space-3); flex-shrink: 0; }
.header-search {
  display: flex; align-items: center; gap: 8px;
  width: 260px; height: 40px; padding: 0 12px;
  background: var(--surface-2); border: 1px solid transparent; border-radius: 999px;
  transition: all var(--fast) var(--ease);
}
.header-search:focus-within { background: var(--surface); border-color: var(--brand); box-shadow: var(--shadow-focus); }
.header-search input { border: none; background: transparent; padding: 0; margin: 0; font-size: 14px; }
.header-search input:focus { box-shadow: none; }
.icon { width: 18px; height: 18px; flex-shrink: 0; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.icon-sm { width: 16px; height: 16px; }

/* =========================================================
   BUTTONS
   ========================================================= */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 20px; border-radius: var(--radius);
  font-weight: 600; font-size: 14.5px; cursor: pointer; border: 1px solid transparent;
  transition: background var(--fast) var(--ease), border-color var(--fast) var(--ease), transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
  white-space: nowrap;
}
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-hover); color: #fff; }
.btn-secondary { background: var(--surface); color: var(--text); border-color: var(--border-strong); }
.btn-secondary:hover { background: var(--surface-2); border-color: var(--border-strong); color: var(--text); }
.btn-ghost { background: transparent; color: var(--text-2); }
.btn-ghost:hover { background: var(--surface-2); color: var(--text); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #dc2f2f; color: #fff; }
.btn-sm { height: 36px; padding: 0 14px; font-size: 13.5px; border-radius: var(--radius-sm); }
.btn-lg { height: 52px; padding: 0 26px; font-size: 15.5px; }
.btn-block { width: 100%; }
form.inline { display: inline; }

/* =========================================================
   INPUTS
   ========================================================= */
label { font-size: 13.5px; color: var(--text); font-weight: 600; display: block; margin-bottom: 6px; }
input, select, textarea {
  width: 100%; height: 48px; padding: 0 14px; border-radius: var(--radius);
  border: 1px solid var(--border-strong); background: var(--surface); color: var(--text);
  margin-bottom: var(--space-4); font-family: inherit; font-size: 15px;
  transition: border-color var(--fast) var(--ease), box-shadow var(--fast) var(--ease);
}
textarea { height: auto; padding: 12px 14px; min-height: 96px; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: var(--shadow-focus); }
input::placeholder, textarea::placeholder { color: #9CA2AE; }
.field-error { color: var(--danger); font-size: 13px; margin-top: -10px; margin-bottom: 12px; }
.field-hint { color: var(--text-2); font-size: 12.5px; margin-top: -10px; margin-bottom: 12px; }

/* =========================================================
   BADGES
   ========================================================= */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 600;
  background: var(--surface-2); color: var(--text-2); border: 1px solid var(--border);
}
.badge-brand { background: var(--brand-soft); color: var(--brand); border-color: transparent; }
.badge-success { background: var(--success-soft); color: var(--success); border-color: transparent; }
.badge-warning { background: var(--warning-soft); color: #B45309; border-color: transparent; }
.badge-danger { background: var(--danger-soft); color: var(--danger); border-color: transparent; }

.platform-badge { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--text-2); }
.platform-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.platform-dot.telegram { background: var(--telegram); }
.platform-dot.instagram { background: var(--instagram); }

.verified-badge { display: inline-flex; align-items: center; justify-content: center; width: 18px; height: 18px; border-radius: 50%; background: var(--brand); color: #fff; flex-shrink: 0; }
.verified-badge svg { width: 11px; height: 11px; stroke: #fff; stroke-width: 3; }

/* =========================================================
   CARDS
   ========================================================= */
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: var(--space-5); box-shadow: var(--shadow-xs);
}

/* =========================================================
   MESSAGES / TOASTS
   ========================================================= */
.messages { list-style: none; padding: 0; margin: var(--space-4) 0; display: flex; flex-direction: column; gap: 8px; }
.messages li {
  padding: 12px 16px; border-radius: var(--radius); font-size: 14px; font-weight: 500;
  background: var(--brand-soft); border: 1px solid transparent; color: #4338CA;
  animation: toastIn 200ms var(--ease) both;
}
.messages li.error { background: var(--danger-soft); color: #B91C1C; }
.messages li.warning { background: var(--warning-soft); color: #92600F; }
.messages li.success { background: var(--success-soft); color: #15803D; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: translateY(0); } }

/* =========================================================
   EMPTY STATE
   ========================================================= */
.empty-state { text-align: center; padding: var(--space-12) var(--space-4); color: var(--text-2); }
.empty-state .icon-wrap {
  width: 56px; height: 56px; border-radius: 50%; background: var(--surface-2);
  display: flex; align-items: center; justify-content: center; margin: 0 auto var(--space-4);
}
.empty-state .icon-wrap .icon { width: 26px; height: 26px; color: var(--text-2); }
.empty-state h3 { font-size: 16px; color: var(--text); margin-bottom: 6px; }
.empty-state p { font-size: 14px; max-width: 320px; margin: 0 auto; }

/* =========================================================
   TABLES
   ========================================================= */
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px 10px; border-bottom: 1px solid var(--border); font-size: 14px; }
th { color: var(--text-2); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }
.table-wrap { overflow-x: auto; }

/* =========================================================
   MOBILE BOTTOM NAV
   ========================================================= */
.bottom-nav {
  display: none;
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 250;
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(10px);
  border-top: 1px solid var(--border);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.bottom-nav-inner { display: flex; align-items: stretch; height: var(--bottomnav-h); }
.bottom-nav a {
  flex: 1; display: flex; align-items: center; justify-content: center;
  color: var(--text-2);
}
.bottom-nav a.active { color: var(--brand); }
.bottom-nav a .icon { width: 23px; height: 23px; }
/* Yorliqlar ko'zga ko'rinmaydi (faqat ikonalar) — skrin-riderlar uchun matn saqlanadi */
.nav-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; }
.bottom-nav a.sell-action .icon-wrap {
  width: 40px; height: 40px; border-radius: 50%; background: var(--brand); color: #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 12px rgba(13,148,136,.35);
}
.bottom-nav a.sell-action .icon { width: 19px; height: 19px; }

/* =========================================================
   FOOTER
   ========================================================= */
.site-footer { margin-top: var(--space-12); border-top: 1px solid var(--border); background: var(--surface); }
.footer-inner {
  display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: var(--space-6);
  padding: var(--space-8) var(--space-6);
}
.footer-brand p { color: var(--text-2); font-size: 13.5px; line-height: 1.6; margin: var(--space-3) 0 var(--space-4); max-width: 280px; }
.footer-platforms { display: flex; gap: 8px; }
.footer-col h5 { font-size: 12.5px; color: var(--text-2); text-transform: uppercase; letter-spacing: .04em; margin-bottom: var(--space-3); }
.footer-col { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.footer-col a { color: var(--text); font-size: 14px; font-weight: 500; }
.footer-col a:hover { color: var(--brand); }
.footer-static { color: var(--text-2); font-size: 14px; }
.footer-bottom {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: var(--space-4) var(--space-6); border-top: 1px solid var(--border);
  color: var(--text-2); font-size: 13px;
}
.footer-dot { opacity: .5; }
.footer-bottom a { color: var(--text-2); overflow-wrap: anywhere; }
.footer-bottom a:hover { color: var(--text); }
@media (max-width: 1000px) and (min-width: 761px) {
  .footer-inner { grid-template-columns: repeat(4, 1fr); }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .footer-inner { grid-template-columns: 1fr 1fr; padding: var(--space-6) var(--space-4); }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  .site-footer { margin-top: var(--space-8); }
}

/* =========================================================
   RESPONSIVE — mobile header
   ========================================================= */
.mobile-search-bar { display: none; }

/* Torroq desktop/planshet kenglikda avval qidiruv qisqaradi, keyin asosiy menyu yashiriladi —
   hech qachon tugmalar bir-birining ustiga tushib, matn kesilib qolmasligi uchun. */
@media (max-width: 1180px) {
  .header-search { width: 200px; }
  .header-left { gap: var(--space-5); }
}
@media (max-width: 1020px) {
  .header-search { display: none; }
}
@media (max-width: 860px) {
  .main-nav { display: none; }
  .header-right .desktop-only { display: none; }
}
.cta-sell .short { display: none; }
@media (max-width: 640px) {
  .bottom-nav { display: block; }
  body.no-bottom-nav .bottom-nav { display: none; }
  .page { padding-bottom: calc(var(--bottomnav-h) + env(safe-area-inset-bottom, 0px) + 24px); }
  body.no-bottom-nav .page { padding-bottom: var(--space-8); }
  .site-header { height: 52px; }
  .logo { font-size: 21px; }
  .header-right { gap: 6px; }
  .header-right .btn { height: 40px; padding: 0 11px; font-size: 12.5px; border-radius: 9px; }

  /* ---------- Ilova uslubidagi zich tipografiya/interfeys ---------- */
  h1 { font-size: 21px; }
  h2 { font-size: 17px; }
  h3 { font-size: 15px; }
  h4 { font-size: 13.5px; }
  body { font-size: 13.5px; }
  label { font-size: 12.5px; }
  input, select, textarea { height: 42px; font-size: 14px; padding: 0 12px; border-radius: 10px; margin-bottom: var(--space-3); }
  textarea { height: auto; padding: 10px 12px; }
  .btn { height: 40px; padding: 0 16px; font-size: 13.5px; border-radius: 10px; }
  .btn-lg { height: 46px; font-size: 14px; }
  .btn-sm { height: 40px; padding: 0 12px; font-size: 12.5px; }
  .card { padding: var(--space-3); border-radius: 14px; }
  .container { padding: 0 12px; }
  table { font-size: 12.5px; }
  th, td { padding: 9px 6px; }
  .badge { font-size: 10.5px; padding: 2px 8px; }
  .platform-badge { font-size: 12px; }
}
@media (max-width: 380px) {
  .cta-sell .full { display: none; }
  .cta-sell .short { display: inline; }
}
.lang-switch { display: inline-flex; border: 1px solid var(--border-strong); border-radius: 9px; overflow: hidden; flex-shrink: 0; }
.lang-switch button { background: none; border: none; padding: 0 9px; height: 32px; font: inherit; font-size: 12px; font-weight: 700; color: var(--text-2); cursor: pointer; }
.lang-switch button.active { background: var(--brand-soft); color: var(--brand); }
.footer-col a.footer-cat { display: flex; align-items: center; gap: 6px; }
/* Mobilda jadval qatorlari kartochkaga aylanadi: har katakda data-label sarlavhasi ko'rinadi */
@media (max-width: 640px) {
  .stack-table, .stack-table tbody, .stack-table tr, .stack-table td { display: block; width: 100%; }
  .stack-table tr:has(th) { display: none; }
  .stack-table tr { padding: 10px 12px; border-bottom: 1px solid var(--border); }
  .stack-table tr:last-child { border-bottom: none; }
  .stack-table td { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 3px 0; border: none; text-align: right; font-size: 13px; }
  .stack-table td::before { content: attr(data-label); color: var(--text-2); font-size: 12px; font-weight: 500; text-align: left; flex-shrink: 0; }
  .stack-table td.stack-main { display: block; text-align: left; font-size: 14px; padding-bottom: 6px; }
  .stack-table td.stack-main::before, .stack-table td[data-label=""]::before { content: none; }
  .stack-table td.stack-actions { justify-content: flex-start; flex-wrap: wrap; padding-top: 6px; }
  .stack-table td:not([data-label]):not(.stack-main) { justify-content: flex-start; text-align: left; }
}
/* Mobil klaviatura ochiq: pastki menyu va yopishqoq panellar yashirinadi (maydonni to'smasin) */
body.kb-open .bottom-nav, body.kb-open .mobile-sticky-bar { display: none !important; }
[hidden] { display: none !important; }
.footer-link-btn { background: none; border: none; padding: 0; font: inherit; font-size: 14px; color: var(--text-2); cursor: pointer; text-align: left; }
.footer-link-btn:hover { color: var(--text); }
.bell-btn { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 32px; border-radius: 9px; border: 1px solid var(--border-strong); color: var(--text-2); flex-shrink: 0; }
.bell-btn:hover { color: var(--text); }
.bell-count { position: absolute; top: -6px; right: -6px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--danger); color: #fff; font-size: 10.5px; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.link-btn { background: none; border: none; padding: 0; font: inherit; color: var(--danger); cursor: pointer; }
.empty-state.compact { padding: 20px 0; }

/* =========================================================
   TAP TARGETS (mobil) - bosiladigan elementlar kamida 40px.
   Faqat tor ekranlarda; desktop ko'rinishi o'zgarmaydi.
   ========================================================= */
@media (max-width: 640px) {
  .logo { min-height: 40px; }
  .lang-switch button { height: 40px; min-width: 40px; }
  .bell-btn { width: 40px; height: 40px; }
  .footer-col { gap: 0; }
  .footer-col h5 { margin-bottom: 4px; }
  .footer-col a, .footer-col a.footer-cat, .footer-link-btn { display: flex; align-items: center; min-height: 40px; }
  .footer-link-btn { width: 100%; }
  .footer-bottom a { display: inline-flex; align-items: center; min-height: 40px; }
  .link-btn { min-height: 40px; }
  .stack-table td.stack-actions a { display: inline-flex; align-items: center; min-width: 40px; min-height: 40px; }
}
