/* Vaqtinchalik brend (BRD 6-bo'lim). Telegram mavzusi ranglari app.js'da fon va matnga qo'llanadi. */
:root {
  --brand: #0E7C66;
  --brand-2: #12A182;
  --brand-soft: #E3F2EE;
  --accent: #F5B83D;
  --text: #14201C;
  --muted: #5B6B66;
  --bg: #F6F8F7;
  --card: #FFFFFF;
  --line: #E1E8E5;
  --danger: #C2412D;
  --radius: 16px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --brand-soft: #143029; --text: #E8F0ED; --muted: #94A6A0; --bg: #0F1513; --card: #18211E; --line: #26332F; --danger: #F07A66;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --brand-soft: #143029; --text: #E8F0ED; --muted: #94A6A0; --bg: #0F1513; --card: #18211E; --line: #26332F; --danger: #F07A66;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-weight: 500;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
[hidden] { display: none !important; }
button { font: inherit; color: inherit; cursor: pointer; }
a { color: var(--brand-2); }
h1, h2 { margin: 0; font-weight: 800; letter-spacing: -0.01em; }
h2 { font-size: 17px; margin-bottom: 12px; }

.screen { max-width: 520px; margin: 0 auto; padding: 12px 16px 104px; }

/* Header */
.header { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; }
.logo { display: flex; align-items: center; gap: 8px; }
.logo-mark { width: 30px; height: 30px; }
.logo-text { font-weight: 800; font-size: 17px; }
.lang { display: flex; background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 2px; }
.lang button { border: 0; background: none; padding: 6px 10px; border-radius: 8px; font-weight: 700; font-size: 13px; color: var(--muted); }
.lang button.active { background: var(--brand); color: #fff; }

.badge { display: inline-flex; align-items: center; gap: 8px; margin-top: 8px; padding: 6px 12px; border-radius: 999px; background: var(--card); border: 1px solid var(--line); font-size: 13px; font-weight: 600; color: var(--muted); }
.badge .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.badge.online .dot { background: #22C55E; animation: pulse 1.6s infinite; }

/* Hero */
.hero { margin-top: 14px; padding: 22px 20px; border-radius: 22px; color: #fff; background: radial-gradient(120% 120% at 100% 0%, var(--brand-2) 0%, var(--brand) 55%, #0A5A4A 100%); position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; right: -40px; bottom: -40px; width: 160px; height: 160px; border-radius: 50%; background: rgba(245, 184, 61, 0.18); }
.hero-label { display: inline-block; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; background: rgba(255,255,255,0.16); }
.hero-amount { font-size: 32px; line-height: 1.1; margin-top: 12px; }
.hero-amount::after { content: ""; display: block; width: 56px; height: 4px; border-radius: 2px; background: var(--accent); margin-top: 10px; }
.hero-sub { margin: 12px 0 0; font-size: 15px; opacity: 0.92; line-height: 1.4; }
.hero-trust { display: flex; align-items: center; gap: 6px; margin-top: 14px; font-size: 12px; opacity: 0.85; }
.hero-trust svg { width: 16px; height: 16px; flex: none; }

/* Cards */
.card { margin-top: 12px; padding: 18px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }

.tabs { display: flex; gap: 6px; padding: 4px; background: var(--bg); border-radius: 12px; margin-bottom: 16px; }
.tabs button { flex: 1; border: 0; background: none; padding: 9px 6px; border-radius: 9px; font-weight: 700; font-size: 14px; color: var(--muted); }
.tabs button[aria-selected="true"] { background: var(--card); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,0.08); }

.slider { display: block; margin-bottom: 18px; }
.slider-head { display: flex; justify-content: space-between; align-items: baseline; font-size: 14px; color: var(--muted); }
.slider-head b { font-size: 20px; color: var(--text); font-variant-numeric: tabular-nums; }
.slider-scale { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); }
input[type="range"] { width: 100%; margin: 10px 0 6px; appearance: none; -webkit-appearance: none; height: 6px; border-radius: 3px; background: linear-gradient(to right, var(--brand) var(--p, 50%), var(--line) var(--p, 50%)); outline: none; }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 26px; height: 26px; border-radius: 50%; background: #fff; border: 3px solid var(--brand); box-shadow: 0 2px 6px rgba(0,0,0,0.2); }
input[type="range"]::-moz-range-thumb { width: 20px; height: 20px; border-radius: 50%; background: #fff; border: 3px solid var(--brand); }
input[type="range"]:focus-visible::-webkit-slider-thumb { outline: 3px solid var(--accent); }

.result { background: var(--brand-soft); border-radius: 12px; padding: 14px; }
.result-main { display: flex; flex-direction: column; gap: 2px; font-size: 14px; }
.result-main b { font-size: 26px; white-space: nowrap; color: var(--brand); font-variant-numeric: tabular-nums; }
:root[data-theme="dark"] .result-main b { color: var(--brand-2); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .result-main b { color: var(--brand-2); } }
.result-row { display: flex; justify-content: space-between; margin-top: 8px; font-size: 14px; color: var(--muted); font-variant-numeric: tabular-nums; }
.result-row span:last-child { color: var(--text); font-weight: 600; }
.note { font-size: 12px; color: var(--muted); line-height: 1.45; margin: 10px 0 0; }

/* Social proof */
.proof-count { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 15px; }
.pulse { width: 10px; height: 10px; border-radius: 50%; background: #22C55E; animation: pulse 1.6s infinite; flex: none; }
.demo-tag { margin-left: auto; font-size: 11px; font-weight: 700; color: var(--danger); border: 1px solid currentColor; border-radius: 6px; padding: 2px 6px; }
.feed { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 10px; }
.feed li { display: flex; gap: 10px; align-items: center; font-size: 13px; animation: slide-in .4s ease both; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; font-weight: 800; flex: none; }
.feed small { display: block; color: var(--muted); margin-top: 2px; }

/* Product */
.params { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 0; }
.params div { background: var(--bg); border-radius: 12px; padding: 10px 12px; }
.params dt { font-size: 12px; color: var(--muted); }
.params dd { margin: 4px 0 0; font-weight: 700; font-size: 14px; }

.trust p { margin: 6px 0 0; font-size: 13px; color: var(--muted); line-height: 1.45; }
.trust h2 { margin-bottom: 4px; }

.footer { margin-top: 16px; font-size: 11px; color: var(--muted); line-height: 1.5; }
.footer p { margin: 0 0 6px; }

/* CTA */
.sticky { position: fixed; left: 0; right: 0; bottom: 0; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); background: linear-gradient(to top, var(--bg) 70%, transparent); }
.sticky .cta { display: block; max-width: 488px; margin: 0 auto; }
.cta { width: 100%; border: 0; border-radius: 14px; padding: 17px; font-size: 17px; font-weight: 800; color: #fff; background: linear-gradient(135deg, var(--brand-2), var(--brand)); position: relative; overflow: hidden; box-shadow: 0 6px 18px rgba(14,124,102,0.35); }
.cta::after { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,0.35) 50%, transparent 70%); transform: translateX(-100%); animation: shimmer 2.8s infinite; }
.cta:disabled { opacity: 0.6; }
.cta:disabled::after { animation: none; }
.cta.secondary { background: var(--card); color: var(--text); border: 1px solid var(--line); box-shadow: none; }
.cta.secondary::after { display: none; }
body.tg-main .sticky { display: none; }
body.tg-main .screen { padding-bottom: 24px; }

/* Form */
.back { border: 0; background: var(--card); width: 40px; height: 40px; border-radius: 12px; font-size: 26px; line-height: 1; border: 1px solid var(--line); }
.form-title { font-size: 18px; }
.form-sub { color: var(--muted); font-size: 14px; line-height: 1.45; margin: 12px 0; }
.choice { display: flex; justify-content: space-between; align-items: center; gap: 12px; background: var(--brand-soft); border-radius: 12px; padding: 12px 14px; }
.choice-label { font-size: 12px; color: var(--muted); }
.choice-value { font-weight: 700; font-size: 14px; margin-top: 2px; }
.link { border: 0; background: none; color: var(--brand-2); font-weight: 700; padding: 6px 0; }

.field { margin-top: 18px; }
.field label, .label { display: block; font-size: 14px; font-weight: 700; margin-bottom: 8px; }
.label i { font-style: normal; font-weight: 500; color: var(--muted); }
input:not([type]), input[type="tel"], select {
  width: 100%; font: inherit; font-size: 16px; color: var(--text); background: var(--card);
  border: 1.5px solid var(--line); border-radius: 12px; padding: 13px 14px; outline: none; appearance: none;
}
select { background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; }
input:focus, select:focus { border-color: var(--brand); }
.invalid input, .invalid select { border-color: var(--danger); }
.err { color: var(--danger); font-size: 12px; margin-top: 6px; min-height: 0; }
.err:empty { display: none; }
.share { width: 100%; display: flex; align-items: center; justify-content: center; gap: 8px; border: 1.5px solid var(--brand); color: var(--brand); background: var(--brand-soft); border-radius: 12px; padding: 13px; font-weight: 700; }
.share svg { width: 18px; height: 18px; }
.or { text-align: center; color: var(--muted); font-size: 12px; margin: 10px 0; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips button { border: 1.5px solid var(--line); background: var(--card); border-radius: 999px; padding: 9px 14px; font-size: 14px; font-weight: 600; }
.chips button[aria-pressed="true"] { border-color: var(--brand); background: var(--brand-soft); color: var(--brand); }
:root[data-theme="dark"] .chips button[aria-pressed="true"] { color: var(--brand-2); }

.consent { display: flex; gap: 10px; align-items: flex-start; margin-top: 20px; font-size: 13px; line-height: 1.45; color: var(--muted); }
.consent input { width: 20px; height: 20px; margin: 0; accent-color: var(--brand); flex: none; }
.send-err { margin-top: 14px; }

/* Done */
.done { text-align: center; padding-top: 72px; }
.done-icon svg { width: 72px; height: 72px; }
.done h1 { margin-top: 20px; font-size: 24px; }
.done p { color: var(--muted); font-size: 15px; line-height: 1.5; margin: 12px auto 0; max-width: 340px; }

@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(34,197,94,0.5); } 70% { box-shadow: 0 0 0 8px rgba(34,197,94,0); } 100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); } }
@keyframes shimmer { 0%, 40% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }
@keyframes slide-in { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { *, *::after { animation: none !important; } }
