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

:root {
  --forest: #08321d;
  --forest-2: #0c4a2a;
  --emerald: #0e8a45;
  --neon: #35e27a;
  --neon-ink: #05301a;
  --paper: #f1f4ec;
  --card: #ffffff;
  --ink: #0d1f15;
  --muted: #5a6b60;
  --faint: #87958b;
  --line: #e3e9dc;
  --soft: #e4f3e6;
  --danger: #c8372d;
  --on-dark: rgba(255, 255, 255, .72);
  --glass: rgba(255, 255, 255, .1);
  --glass-line: rgba(255, 255, 255, .16);
  --shadow: 0 1px 2px rgba(10, 40, 22, .05), 0 12px 28px -20px rgba(10, 40, 22, .3);
  --r-lg: 26px;
  --r: 20px;
  --r-sm: 15px;
  --gutter: 18px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  --ease: cubic-bezier(.2, .8, .2, 1);
  --display: "Bricolage", "Onest", system-ui, sans-serif;
  color-scheme: light;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--paper); }
body {
  font-family: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--ink); font-size: 15px; line-height: 1.45; font-weight: 450;
  -webkit-font-smoothing: antialiased; overscroll-behavior-y: none;
}
#sprite { display: none; }
button, input { font: inherit; color: inherit; }
button { background: none; border: 0; padding: 0; cursor: pointer; touch-action: manipulation; }
h1, h2, h3, p { margin: 0; }
:focus-visible { outline: 2.5px solid var(--emerald); outline-offset: 2px; }
.ic { width: 1.2em; height: 1.2em; flex: none; display: block; }
.logo { display: block; height: auto; }
.logo.white { filter: brightness(0) invert(1); }

.app { position: relative; max-width: 430px; min-height: 100dvh; margin: 0 auto; background: var(--paper); overflow-x: clip; }
@media (min-width: 500px) {
  html, body { background: #dfe6d8; }
}
.boot { min-height: 100dvh; display: grid; place-items: center; }
.boot-logo { width: 96px; animation: pulse 1.2s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .35; transform: translateX(4px); } }

/* Tugmalar */
.btn {
  display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 58px; padding: 0 22px;
  border-radius: 18px; font-family: var(--display); font-weight: 700; font-size: 17px; letter-spacing: -.01em;
  transition: transform .15s var(--ease), background .2s, opacity .2s;
}
.btn:active { transform: scale(.975); }
.btn[disabled] { opacity: .5; }
.btn-primary { background: var(--forest); color: #fff; }
.btn-neon { background: var(--neon); color: var(--neon-ink); box-shadow: 0 14px 34px -14px rgba(53, 226, 122, .9); }
.btn-glass { background: var(--glass); color: #fff; box-shadow: inset 0 0 0 1.5px var(--glass-line); }
.btn-ghost { background: var(--paper); color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.icon-btn { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 15px; font-size: 18px; transition: background .2s, opacity .2s; }
.icon-btn.glass { background: var(--glass); color: #fff; box-shadow: inset 0 0 0 1px var(--glass-line); }
.icon-btn.plain { background: var(--paper); color: var(--ink); }
.icon-btn[disabled] { opacity: .3; }

/* To'q yashil asosiy blok */
.band {
  position: relative; isolation: isolate; overflow: hidden; color: #fff; padding: calc(var(--safe-t) + 10px) var(--gutter) 24px; border-radius: 0 0 34px 34px;
  background: radial-gradient(130% 70% at 50% 26%, #14713f 0%, var(--forest-2) 46%, var(--forest) 100%);
}
.band::before {
  content: ""; position: absolute; z-index: -1; inset: 0; pointer-events: none; opacity: .9;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='430' height='520' fill='none' stroke='white' stroke-opacity='.055'%3E%3Cellipse cx='380' cy='40' rx='70' ry='48'/%3E%3Cellipse cx='380' cy='40' rx='120' ry='84'/%3E%3Cellipse cx='380' cy='40' rx='178' ry='128'/%3E%3Cellipse cx='380' cy='40' rx='244' ry='180'/%3E%3Cellipse cx='20' cy='470' rx='64' ry='44'/%3E%3Cellipse cx='20' cy='470' rx='116' ry='84'/%3E%3Cellipse cx='20' cy='470' rx='176' ry='130'/%3E%3C/svg%3E") top center / 100% auto no-repeat;
}
.bar-top { display: flex; align-items: center; justify-content: space-between; height: 50px; margin-bottom: 12px; }
.brand { display: flex; align-items: center; gap: 9px; font-family: var(--display); font-weight: 800; font-size: 19px; letter-spacing: -.015em; }
.brand .logo { width: 40px; }
.segment { display: grid; grid-template-columns: repeat(3, 1fr); padding: 4px; border-radius: 16px; background: rgba(0, 0, 0, .2); }
.segment button { height: 40px; border-radius: 12px; font-family: var(--display); font-weight: 700; font-size: 15px; color: var(--on-dark); transition: background .2s, color .2s; }
.segment button[aria-selected="true"] { background: #fff; color: var(--forest); }

/* Halqa */
.ring-box { position: relative; width: min(72vw, 276px); aspect-ratio: 1; margin: 22px auto 0; }
.ring-box canvas { position: absolute; inset: -9%; width: 118%; height: 118%; pointer-events: none; }
.ring-box svg.ring { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.ring circle { fill: none; stroke-linecap: round; }
.ring .track { stroke: rgba(255, 255, 255, .1); stroke-width: 17; }
.ring .glow { stroke: var(--neon); stroke-width: 20; opacity: .5; filter: blur(12px); transition: stroke-dashoffset .7s var(--ease); }
.ring .bar { stroke: url(#ringGrad); stroke-width: 17; transition: stroke-dashoffset .7s var(--ease); }
.ring-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.ring-today { font-weight: 600; font-size: 13px; letter-spacing: .02em; color: var(--on-dark); }
.count { font-family: var(--display); font-size: clamp(54px, 17.5vw, 68px); line-height: 1.04; font-weight: 700; letter-spacing: -.035em; font-variant-numeric: tabular-nums; }
.ring-goal { font-weight: 600; font-size: 13px; color: var(--on-dark); margin-top: 2px; }
.ring-badge { position: absolute; top: 5%; right: 6%; width: 44px; height: 44px; border-radius: 50%; display: none; place-items: center; background: var(--neon); color: var(--neon-ink); font-size: 19px; }
.ring-badge.show { display: grid; }
.ring-badge.live::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--neon); animation: ping 1.6s ease-out infinite; }
@keyframes ping { to { transform: scale(1.7); opacity: 0; } }

.next { margin: 20px 0 14px; padding: 13px 15px; border-radius: 17px; background: var(--glass); box-shadow: inset 0 0 0 1px var(--glass-line); }
.next-row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-size: 13.5px; font-weight: 500; color: var(--on-dark); margin-bottom: 9px; }
.next-row b { color: var(--neon); font-family: var(--display); font-weight: 700; font-size: 15px; white-space: nowrap; }
.line-bar { height: 6px; border-radius: 6px; background: var(--paper); overflow: hidden; }
.line-bar i { display: block; height: 100%; border-radius: 6px; background: var(--emerald); transition: width .5s var(--ease); }
.next .line-bar { background: rgba(255, 255, 255, .14); }
.next .line-bar i { background: var(--neon); }
.hint { text-align: center; color: var(--on-dark); font-size: 12.5px; margin-top: 12px; }

/* Davr jami */
.range-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-top: 22px; }
.range-total { font-family: var(--display); font-size: 46px; line-height: 1.04; font-weight: 700; letter-spacing: -.035em; }
.range-sub { color: var(--on-dark); font-weight: 500; font-size: 13.5px; margin-top: 3px; }
.range-nav { display: flex; gap: 6px; flex: none; }

/* Sahifa tanasi */
.view { animation: fade .28s ease; padding-bottom: calc(var(--safe-b) + 116px); }
.quiet .view, .quiet .bar-fill { animation: none; }
@keyframes fade { from { opacity: 0; } }
.body { padding: 18px var(--gutter) 0; }
.section { margin-top: 28px; }
.section:first-child { margin-top: 0; }
.section-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; min-height: 28px; }
.section-head h2 { font-family: var(--display); font-size: 22px; line-height: 1.15; font-weight: 700; letter-spacing: -.025em; }
.section-head .link { color: var(--emerald); font-weight: 650; font-size: 14px; min-height: 44px; margin: -8px 0; }
.panel { background: var(--card); border-radius: var(--r-lg); padding: 18px; box-shadow: var(--shadow); }
.mt { margin-top: 14px; }

/* Kashelok kartasi: o'lchami container bo'yicha, har qanday kenglikda bir xil ko'rinadi */
.wcard {
  position: relative; display: block; width: 100%; aspect-ratio: 1.586; container-type: inline-size; text-align: left; color: #fff; overflow: hidden; isolation: isolate; border-radius: 5.5cqw;
  background: radial-gradient(90% 120% at 12% 0%, #1f9a58 0%, transparent 62%), linear-gradient(140deg, #0f6a3a 0%, #0a4627 52%, #062b18 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14), 0 2px 3px rgba(6, 30, 18, .3), 0 24px 40px -24px rgba(6, 40, 22, .85);
  transition: transform .2s var(--ease);
}
button.wcard:active { transform: scale(.985); }
@supports (container-type: inline-size) { .wcard { border-radius: 18px; } .wc-in { border-radius: 5cqw; } }
.wc-lines { position: absolute; z-index: -1; inset: 0; width: 100%; height: 100%; }
.wc-lines path { fill: none; stroke: #fff; stroke-opacity: .07; stroke-width: .8; }
.wc-in { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: space-between; padding: 6.2cqw 6.6cqw 5.8cqw; }
.wc-row { display: flex; align-items: center; justify-content: space-between; gap: 3cqw; }
.wc-brand { display: flex; align-items: center; gap: 2cqw; font-family: var(--display); font-weight: 800; font-size: 4.6cqw; letter-spacing: .02em; }
.wc-brand .logo { width: 10.5cqw; }
.wc-nfc { width: 6.4cqw; height: 6.4cqw; opacity: .85; }
.wc-label { display: block; font-size: 3.4cqw; font-weight: 500; color: rgba(255, 255, 255, .7); margin-bottom: .4cqw; }
.wc-amount { display: block; font-family: var(--display); font-size: 11.6cqw; line-height: 1.05; font-weight: 700; letter-spacing: -.03em; white-space: nowrap; }
.wc-amount small { font-size: .44em; font-weight: 600; letter-spacing: 0; color: rgba(255, 255, 255, .78); margin-left: .25em; }
.chip { position: relative; flex: none; width: 11.6cqw; height: 8.8cqw; border-radius: 1.8cqw; background: linear-gradient(135deg, #f4e5b3 0%, #cfae68 52%, #ecd898 100%); box-shadow: inset 0 0 0 .3cqw rgba(110, 80, 20, .35); }
.chip svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.chip path { fill: none; stroke: rgba(100, 72, 18, .5); stroke-width: 1; }
.wc-foot { font-size: 3.5cqw; font-weight: 600; letter-spacing: .06em; color: rgba(255, 255, 255, .88); }
.wc-foot span:first-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-transform: uppercase; }
.wc-foot span:last-child { flex: none; font-variant-numeric: tabular-nums; }
.wcard.shine::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .3) 50%, transparent 65%); animation: shine .9s ease-out forwards; }
@keyframes shine { from { transform: translateX(-100%); } to { transform: translateX(100%); } }

/* Yutuqlar */
.ch-count { font-family: var(--display); font-weight: 700; font-size: 14px; color: var(--emerald); background: var(--soft); padding: 4px 12px; border-radius: 20px; }
.ch-list { display: grid; gap: 10px; }
.ch { display: flex; align-items: center; gap: 13px; padding: 13px 14px; background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); }
.ch.ready { box-shadow: inset 0 0 0 2px var(--emerald), var(--shadow); }
.ch-ic { flex: none; position: relative; width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center; font-size: 18px; color: var(--emerald); background: conic-gradient(var(--emerald) var(--p, 0%), var(--line) 0); }
.ch-ic::before { content: ""; position: absolute; inset: 5px; border-radius: 50%; background: #fff; }
.ch-ic .ic { position: relative; }
.ch-main { flex: 1; min-width: 0; }
.ch-main b { display: block; font-family: var(--display); font-weight: 700; font-size: 16.5px; line-height: 1.2; letter-spacing: -.015em; }
.ch-reward { display: block; color: var(--emerald); font-weight: 650; font-size: 13.5px; margin-top: 2px; }
.ch-left { flex: none; color: var(--muted); font-size: 12.5px; font-weight: 550; white-space: nowrap; }
.ch-claim { flex: none; min-height: 44px; padding: 0 20px; border-radius: 14px; background: var(--forest); color: #fff; font-family: var(--display); font-weight: 700; font-size: 15px; transition: transform .15s var(--ease), opacity .2s; }
.ch-claim:active { transform: scale(.95); }
.ch-claim[disabled] { opacity: .5; }
.ch-done { flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--neon); color: var(--neon-ink); font-size: 15px; }
.ch.claimed .ch-main b { color: var(--muted); }
.ch.claimed .ch-reward { color: var(--muted); }
.ch-note { color: var(--muted); font-size: 12.5px; margin-top: 10px; padding: 0 2px; }

/* Ko'rsatkichlar */
.stats3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.stat { background: var(--card); border-radius: var(--r); padding: 13px 12px 14px; box-shadow: var(--shadow); min-width: 0; }
.stat-ic { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; font-size: 14px; background: var(--soft); color: var(--emerald); margin-bottom: 11px; }
.stat-val { font-family: var(--display); font-weight: 700; font-size: 21px; line-height: 1.1; letter-spacing: -.025em; white-space: nowrap; margin-bottom: 9px; }
.stat-val small { font-family: "Onest", sans-serif; font-weight: 500; color: var(--muted); font-size: 11.5px; letter-spacing: 0; margin-left: 3px; }
.stat .line-bar { height: 4px; }

/* Grafik */
.curve-wrap svg { display: block; width: 100%; height: auto; overflow: visible; }
.curve-labels { display: flex; justify-content: space-between; margin-bottom: 10px; }
.curve-labels span { width: 34px; text-align: center; padding: 2px 0; font-size: 11.5px; font-weight: 600; color: var(--faint); }
.curve-labels span.on { color: #fff; background: var(--forest); border-radius: 10px; }
.curve-labels span:first-child { margin-left: -6px; }
.curve-labels span:last-child { margin-right: -6px; }

/* Hafta va oy */
.weekdays { display: grid; grid-template-columns: repeat(7, 1fr); text-align: center; font-size: 12px; font-weight: 600; color: var(--faint); }
.weekdays .on { color: var(--emerald); font-weight: 750; }
.bars { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; height: 250px; margin-bottom: 10px; }
.bar-col { position: relative; height: 100%; }
.bar-track { position: absolute; left: 0; right: 0; bottom: 0; top: 24px; background: var(--paper); border-radius: 14px; overflow: hidden; }
.bar-fill { position: absolute; left: 0; right: 0; bottom: 0; border-radius: 14px; background: linear-gradient(180deg, #33b86c, var(--emerald)); animation: grow .7s var(--ease) both; transform-origin: bottom; }
.bar-fill.hit { background: linear-gradient(180deg, var(--emerald), var(--forest-2)); }
@keyframes grow { from { transform: scaleY(0); } }
.bar-val { position: absolute; left: -4px; right: -4px; text-align: center; font-family: var(--display); font-size: 11.5px; font-weight: 700; letter-spacing: -.02em; }
.bar-star { position: absolute; bottom: 6px; left: 0; right: 0; margin: auto; width: 22px; height: 22px; border-radius: 50%; background: var(--neon); color: var(--neon-ink); display: grid; place-items: center; font-size: 12px; }
.cal { display: grid; grid-template-columns: repeat(7, 1fr); row-gap: 6px; margin-top: 12px; justify-items: center; }
.cal-day { position: relative; width: 40px; height: 40px; display: grid; place-items: center; font-size: 13.5px; font-weight: 600; border-radius: 50%; }
.cal-day svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.cal-day circle { fill: none; stroke-width: 3; stroke-linecap: round; }
.cal-day .t { stroke: var(--line); }
.cal-day .p { stroke: var(--emerald); }
.cal-day span { position: relative; }
.cal-day.hit { background: var(--emerald); color: #fff; font-weight: 700; }
.cal-day.hit svg { display: none; }
.cal-day.today:not(.hit) { color: var(--emerald); font-weight: 800; }
.cal-day.future { color: var(--faint); }
.day-detail { min-height: 46px; display: flex; align-items: center; justify-content: space-between; margin-top: 14px; padding: 0 14px; background: var(--paper); border-radius: var(--r-sm); font-size: 14px; font-weight: 550; color: var(--muted); }
.day-detail b { color: var(--ink); font-family: var(--display); font-weight: 700; }

/* Reyting */
.rank { display: flex; align-items: center; gap: 12px; min-height: 58px; }
.rank + .rank { border-top: 1px solid var(--line); }
.rank-n { width: 16px; text-align: center; font-family: var(--display); font-weight: 700; color: var(--faint); font-size: 15px; }
.avatar { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-family: var(--display); font-weight: 700; font-size: 14px; background: var(--soft); color: var(--emerald); }
.avatar.me { background: var(--forest); color: #fff; }
.rank-name { flex: 1; min-width: 0; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.me-tag { font-size: 11px; font-weight: 700; color: var(--emerald); background: var(--soft); padding: 2px 7px; border-radius: 7px; margin-left: 6px; }
.rank-val { font-family: var(--display); font-weight: 700; font-size: 17px; letter-spacing: -.02em; }
.empty { color: var(--muted); font-size: 14px; padding: 12px 0; }

.test-panel { margin-top: 26px; border: 1.5px dashed #c8d3c0; border-radius: var(--r-sm); padding: 12px; }
.test-panel p { font-size: 12px; font-weight: 600; color: var(--muted); margin-bottom: 9px; }
.test-row { display: flex; gap: 8px; }
.test-row button { flex: 1; height: 42px; border-radius: 11px; background: var(--card); font-weight: 650; font-size: 13.5px; box-shadow: inset 0 0 0 1px var(--line); }

/* Profil */
.pf-head { display: flex; align-items: center; gap: 14px; padding: 6px 0 8px; }
.pf-avatar { flex: none; width: 68px; height: 68px; border-radius: 50%; display: grid; place-items: center; font-family: var(--display); font-size: 24px; font-weight: 700; background: #fff; color: var(--forest); }
.pf-info { flex: 1; min-width: 0; }
.pf-name { font-family: var(--display); font-size: 25px; line-height: 1.1; font-weight: 700; letter-spacing: -.025em; overflow-wrap: anywhere; }
.pf-since { color: var(--on-dark); font-size: 13px; font-weight: 500; margin-top: 4px; }
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; margin-top: 14px; }
.tile { background: var(--card); border-radius: var(--r); padding: 14px 12px; min-width: 0; box-shadow: var(--shadow); }
.tile b { display: block; font-family: var(--display); font-size: 22px; line-height: 1.15; font-weight: 700; letter-spacing: -.025em; white-space: nowrap; }
.tile span { color: var(--muted); font-size: 12px; font-weight: 500; }
.rows { background: var(--card); border-radius: var(--r-lg); padding: 2px 18px; box-shadow: var(--shadow); }
.row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 56px; }
.row + .row { border-top: 1px solid var(--line); }
.row-l { display: flex; align-items: center; gap: 12px; color: var(--muted); font-weight: 500; }
.row-l .ic { font-size: 15px; color: var(--emerald); }
.row-v { font-weight: 650; text-align: right; }
.row-v.good { color: var(--emerald); }
.code-box { display: flex; align-items: center; justify-content: space-between; background: var(--paper); border-radius: var(--r-sm); padding: 6px 6px 6px 16px; }
.code-box b { font-family: var(--display); font-size: 21px; letter-spacing: .1em; font-weight: 700; }
a.btn { text-decoration: none; }
.link-box span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; font-size: 14.5px; margin-right: 10px; }
.code-box .icon-btn { background: var(--card); color: var(--ink); box-shadow: var(--shadow); }
.tx { display: flex; align-items: center; gap: 12px; min-height: 62px; }
.tx + .tx { border-top: 1px solid var(--line); }
.tx-ic { flex: none; width: 40px; height: 40px; border-radius: 13px; display: grid; place-items: center; font-size: 15px; background: var(--soft); color: var(--emerald); }
.tx-t { flex: 1; min-width: 0; }
.tx-t b { display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tx-t span { color: var(--muted); font-size: 12.5px; }
.tx-v { font-family: var(--display); font-weight: 700; color: var(--emerald); white-space: nowrap; letter-spacing: -.01em; }
.note { color: var(--muted); margin-bottom: 14px; }

/* Home */
.home-hero { position: relative; margin-bottom: 76px; }
.home-hero .band { padding-bottom: 0; }
.hero-title { font-family: var(--display); font-size: clamp(38px, 11.4vw, 48px); line-height: 1; font-weight: 700; letter-spacing: -.04em; margin-top: 12px; }
.hero-title em { font-style: normal; color: var(--neon); }
.hero-sub { color: var(--on-dark); font-size: 16px; margin: 14px 0 20px; max-width: 30ch; }
.stage { position: relative; height: 226px; margin-top: 28px; }
.device {
  position: absolute; left: 11%; top: 0; width: 172px; height: 356px; padding: 5px; border-radius: 35px;
  background: linear-gradient(140deg, #5d6b62, #1a241e 30%, #0b120e 70%, #48554c);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .12), 0 30px 50px -14px rgba(0, 0, 0, .65);
}
.device i { position: absolute; width: 2.5px; border-radius: 2px; background: #2d3831; }
.device i:nth-child(1) { left: -2px; top: 62px; height: 14px; }
.device i:nth-child(2) { left: -2px; top: 88px; height: 28px; }
.device i:nth-child(3) { left: -2px; top: 124px; height: 28px; }
.device i:nth-child(4) { right: -2px; top: 98px; height: 44px; }
.screen { position: relative; height: 100%; border-radius: 30px; overflow: hidden; background: var(--paper); }
.s-band { position: relative; padding: 7px 10px 12px; color: #fff; border-radius: 0 0 16px 16px; background: radial-gradient(130% 70% at 50% 30%, #14713f, var(--forest)); }
.s-status { display: flex; justify-content: space-between; align-items: center; font-size: 8.5px; font-weight: 700; padding: 0 7px; height: 14px; }
.s-status span:last-child { display: flex; gap: 2px; align-items: center; }
.s-status u { display: block; width: 13px; height: 6.5px; border-radius: 2px; background: #fff; }
.s-island { position: absolute; left: 50%; top: 6px; width: 46px; height: 13px; margin-left: -23px; border-radius: 8px; background: #000; }
.s-seg { display: grid; grid-template-columns: repeat(3, 1fr); padding: 2px; margin: 10px 0 8px; border-radius: 7px; background: rgba(0, 0, 0, .2); font-size: 7.5px; font-weight: 700; text-align: center; color: var(--on-dark); }
.s-seg span { padding: 2.5px 0; border-radius: 5px; }
.s-seg span:first-child { background: #fff; color: var(--forest); }
.s-ring { position: relative; width: 106px; height: 106px; margin: 0 auto 8px; }
.s-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); overflow: visible; }
.s-ring circle { fill: none; stroke-width: 8; stroke-linecap: round; }
.s-ring .a { stroke: rgba(255, 255, 255, .12); }
.s-ring .b { stroke: var(--neon); }
.s-ring .c { stroke: var(--neon); filter: blur(5px); opacity: .55; }
.s-num { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.s-num b { font-family: var(--display); font-size: 23px; line-height: 1; font-weight: 700; letter-spacing: -.03em; }
.s-num span { font-size: 7px; color: var(--on-dark); margin-top: 2px; }
.s-cta { background: var(--neon); color: var(--neon-ink); text-align: center; font-family: var(--display); font-size: 8.5px; font-weight: 700; padding: 6px; border-radius: 7px; }
.s-tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 7px 8px; }
.s-tiles div { background: #fff; border-radius: 7px; padding: 6px 5px; font-family: var(--display); font-size: 9.5px; font-weight: 700; }
.s-tiles small { display: block; font-size: 6.5px; font-weight: 500; color: var(--muted); }
.home-hero .wcard { position: absolute; right: var(--gutter); bottom: -54px; width: 212px; transform: rotate(-5deg); pointer-events: none; }
.rule { display: flex; align-items: baseline; justify-content: center; flex-wrap: wrap; gap: 0 10px; text-align: center; padding: 22px 16px; border-radius: var(--r-lg); background: var(--neon); color: var(--neon-ink); font-family: var(--display); font-size: 24px; line-height: 1.15; font-weight: 700; letter-spacing: -.03em; }
.h-title { font-family: var(--display); font-size: 31px; line-height: 1.06; font-weight: 700; letter-spacing: -.035em; margin-bottom: 8px; }
.h-sub { color: var(--muted); margin-bottom: 16px; }
.h-section { margin-top: 42px; }
.calc { background: var(--forest); color: #fff; border-radius: var(--r-lg); padding: 22px 20px 14px; }
.calc-label { color: var(--on-dark); font-weight: 500; font-size: 13.5px; }
.calc-out { font-family: var(--display); font-size: 46px; line-height: 1.08; font-weight: 700; letter-spacing: -.035em; color: var(--neon); margin-top: 2px; white-space: nowrap; }
.calc-out small { font-size: .4em; letter-spacing: 0; font-weight: 600; color: var(--on-dark); margin-left: 4px; }
.calc-steps { display: flex; justify-content: space-between; align-items: baseline; margin: 20px 0 6px; font-weight: 500; color: var(--on-dark); font-size: 13.5px; }
.calc-steps b { color: #fff; font-family: var(--display); font-size: 18px; font-weight: 700; }
input[type=range] { -webkit-appearance: none; appearance: none; display: block; width: 100%; height: 44px; background: none; margin: 0; }
input[type=range]::-webkit-slider-runnable-track { height: 8px; border-radius: 8px; background: linear-gradient(90deg, var(--neon) var(--p, 30%), rgba(255, 255, 255, .16) var(--p, 30%)); }
input[type=range]::-moz-range-track { height: 8px; border-radius: 8px; background: rgba(255, 255, 255, .16); }
input[type=range]::-moz-range-progress { height: 8px; border-radius: 8px; background: var(--neon); }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 30px; height: 30px; margin-top: -11px; border-radius: 50%; background: #fff; box-shadow: 0 3px 10px rgba(0, 0, 0, .4); }
input[type=range]::-moz-range-thumb { width: 30px; height: 30px; border: 0; border-radius: 50%; background: #fff; }
.how { display: grid; gap: 10px; margin-top: 14px; }
.how-item { display: flex; gap: 14px; padding: 16px; background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); }
.how-n { flex: none; width: 34px; font-family: var(--display); font-size: 38px; line-height: .95; font-weight: 700; letter-spacing: -.04em; color: var(--emerald); }
.how-item b { display: block; font-family: var(--display); font-size: 17.5px; font-weight: 700; letter-spacing: -.015em; margin-bottom: 2px; }
.how-item p { color: var(--muted); font-size: 14px; }
.final { position: relative; overflow: hidden; isolation: isolate; color: #fff; padding: 30px 20px 20px; border-radius: 30px; background: radial-gradient(120% 90% at 80% 0%, #14713f, var(--forest)); }
.final .logo { position: absolute; z-index: -1; right: -26px; top: -6px; width: 170px; opacity: .1; }
.final h2 { font-family: var(--display); font-size: 31px; line-height: 1.04; font-weight: 700; letter-spacing: -.035em; margin-bottom: 20px; }
.btn-stack { display: grid; gap: 10px; margin-top: 14px; }

/* Kirish sahifasi */
.onb { position: relative; isolation: isolate; min-height: 100dvh; display: flex; flex-direction: column; justify-content: center; padding: calc(var(--safe-t) + 24px) var(--gutter) calc(var(--safe-b) + 24px); color: #fff; background: radial-gradient(120% 60% at 50% 12%, #15793f 0%, var(--forest-2) 48%, var(--forest) 100%); overflow: hidden; }
.onb::before { content: ""; position: absolute; z-index: -1; inset: 0; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='430' height='800' fill='none' stroke='white' stroke-opacity='.05'%3E%3Cellipse cx='400' cy='60' rx='80' ry='56'/%3E%3Cellipse cx='400' cy='60' rx='140' ry='100'/%3E%3Cellipse cx='400' cy='60' rx='208' ry='152'/%3E%3Cellipse cx='400' cy='60' rx='284' ry='212'/%3E%3Cellipse cx='10' cy='760' rx='90' ry='60'/%3E%3Cellipse cx='10' cy='760' rx='160' ry='112'/%3E%3Cellipse cx='10' cy='760' rx='240' ry='170'/%3E%3C/svg%3E") top center / 100% auto no-repeat; }
.onb-top { display: flex; flex-direction: column; align-items: center; text-align: center; margin-bottom: 22px; }
.onb-badge { width: 76px; height: 76px; border-radius: 24px; display: grid; place-items: center; background: #fff; box-shadow: 0 16px 34px -14px rgba(0, 0, 0, .55); margin-bottom: 12px; }
.onb-badge .logo { width: 56px; }
.onb-word { font-family: var(--display); font-weight: 800; font-size: 25px; line-height: 1.1; letter-spacing: -.02em; }
.onb-tag { color: var(--on-dark); font-size: 14px; margin-top: 2px; }
.onb-card { color: var(--ink); background: #fff; border-radius: 30px; padding: 24px 20px 20px; box-shadow: 0 30px 60px -28px rgba(0, 0, 0, .7); animation: rise .45s var(--ease); }
@keyframes rise { from { opacity: 0; transform: translateY(16px); } }
.onb-steps { display: flex; align-items: center; gap: 6px; margin-bottom: 16px; }
.onb-steps i { flex: 1; height: 5px; border-radius: 5px; background: var(--line); }
.onb-steps i.on { background: var(--emerald); }
.onb-steps span { flex: none; font-family: var(--display); font-weight: 700; font-size: 13px; color: var(--muted); margin-left: 6px; }
.onb-card h1 { font-family: var(--display); font-size: 31px; line-height: 1.06; font-weight: 700; letter-spacing: -.035em; }
.onb-sub { color: var(--muted); margin: 6px 0 20px; }
.ref-pill { display: flex; gap: 10px; align-items: center; background: var(--soft); color: var(--emerald); padding: 10px 13px; border-radius: 13px; font-weight: 600; font-size: 13.5px; margin-bottom: 16px; }
.field { display: block; margin-bottom: 13px; }
.field-label { display: block; font-weight: 600; font-size: 13.5px; color: var(--ink); margin-bottom: 7px; }
.input-wrap { position: relative; display: block; }
.input { width: 100%; height: 58px; padding: 0 16px; border-radius: var(--r-sm); background: var(--paper); border: 2px solid transparent; font-size: 17px; font-weight: 600; outline: 0; transition: border-color .2s, background .2s; appearance: none; }
.input:focus { border-color: var(--emerald); background: #fff; }
.input::placeholder { color: var(--faint); font-weight: 450; }
.input.has-unit { padding-right: 70px; }
.input.invalid { border-color: var(--danger); background: #fff; }
.unit { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); color: var(--muted); font-weight: 550; font-size: 14px; pointer-events: none; }
.err { color: var(--danger); font-size: 13px; font-weight: 550; margin-top: 6px; }
.err:empty { display: none; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 4px; }
.gender { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.gender button { display: flex; align-items: center; justify-content: center; gap: 9px; height: 58px; border-radius: var(--r-sm); background: var(--paper); border: 2px solid transparent; font-weight: 650; font-size: 16px; color: var(--muted); transition: all .18s; }
.gender button .ic { font-size: 18px; }
.gender button[aria-pressed="true"] { background: var(--soft); border-color: var(--emerald); color: var(--forest); }
.ntile { display: block; padding: 10px 6px 8px; border-radius: var(--r-sm); background: var(--paper); border: 2px solid transparent; text-align: center; transition: border-color .2s, background .2s; cursor: text; }
.ntile:focus-within { border-color: var(--emerald); background: #fff; }
.ntile.invalid-w { border-color: var(--danger); }
.ntile span { display: block; font-size: 12.5px; font-weight: 550; color: var(--muted); }
.ntile input { width: 100%; height: 40px; border: 0; background: none; outline: 0; padding: 0; text-align: center; font-family: var(--display); font-size: 25px; font-weight: 700; letter-spacing: -.02em; }
.ntile input::placeholder { color: #bcc7bd; }
.onb-actions { display: flex; gap: 10px; margin-top: 16px; }
.onb-actions .back { flex: 0 0 58px; width: 58px; padding: 0; }
.onb-note { text-align: center; color: var(--on-dark); font-size: 12.5px; margin-top: 16px; }
.sheet .onb-note { color: var(--muted); }

/* Suzuvchi menyu */
.nav {
  position: fixed; z-index: 20; left: 50%; bottom: calc(var(--safe-b) + 12px); transform: translateX(-50%); width: calc(100% - 28px); max-width: 402px;
  display: grid; grid-template-columns: 1fr 96px 1fr; height: 68px; border-radius: 26px; background: var(--forest); box-shadow: 0 18px 36px -14px rgba(5, 40, 20, .75);
}
.nav button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: rgba(255, 255, 255, .58); font-size: 12px; font-weight: 600; transition: color .2s; }
.nav button .ic { font-size: 20px; }
.nav button[aria-current="page"] { color: var(--neon); }
.nav .nav-main { justify-content: flex-end; padding-bottom: 8px; }
.nav-orb { position: relative; width: 66px; height: 66px; margin-top: -32px; border-radius: 50%; background: #fff; display: grid; place-items: center; box-shadow: 0 8px 18px -6px rgba(5, 40, 20, .6), 0 0 0 4px var(--paper); }
.nav-orb svg.o { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.nav-orb circle { fill: none; stroke-width: 4; stroke-linecap: round; }
.nav-orb .t { stroke: var(--line); }
.nav-orb .p { stroke: var(--emerald); transition: stroke-dashoffset .6s var(--ease); }
.nav-orb .logo { width: 44px; }

/* Pastdan chiquvchi oyna */
.backdrop { position: fixed; z-index: 40; inset: 0; background: rgba(5, 30, 16, .55); animation: fade .2s ease; }
.sheet { position: fixed; z-index: 41; left: 50%; bottom: 0; transform: translateX(-50%); width: 100%; max-width: 430px; max-height: 88dvh; overflow-y: auto; overscroll-behavior: contain; background: #fff; border-radius: 30px 30px 0 0; padding: 10px var(--gutter) calc(var(--safe-b) + 22px); animation: up .32s var(--ease); }
@keyframes up { from { transform: translate(-50%, 100%); } }
.sheet-grip { width: 42px; height: 5px; border-radius: 5px; background: var(--line); margin: 0 auto 10px; }
.sheet-head { display: flex; justify-content: space-between; align-items: center; margin: 0 -8px 10px 0; }
.sheet-head h2 { font-family: var(--display); font-size: 25px; line-height: 1.1; font-weight: 700; letter-spacing: -.03em; }
.sheet-head .icon-btn { color: var(--muted); }
.sheet p.lead { color: var(--muted); margin-bottom: 16px; }
.sheet .wcard { margin-bottom: 20px; }
.sheet .section-head h2 { font-size: 20px; }

.toast { position: fixed; z-index: 60; left: 50%; top: calc(var(--safe-t) + 12px); transform: translate(-50%, -140%); padding: 12px 18px; border-radius: 40px; background: var(--neon); color: var(--neon-ink); font-family: var(--display); font-weight: 700; font-size: 14.5px; white-space: nowrap; max-width: calc(100vw - 32px); overflow: hidden; text-overflow: ellipsis; box-shadow: 0 14px 30px -12px rgba(5, 40, 20, .7); transition: transform .35s var(--ease), opacity .2s; pointer-events: none; opacity: 0; }
.toast.show { transform: translate(-50%, 0); opacity: 1; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Pul yechib olish */
.btn[disabled].btn-primary { opacity: .45; }
.wd-note { color: var(--muted); font-size: 13px; text-align: center; margin-top: 9px; }
.wd-side { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; flex: none; }
.wd-amount { color: var(--ink); }
.wd-status { font-size: 12px; font-weight: 650; padding: 2px 8px; border-radius: 20px; }
.wd-status.pending { background: #fbf1d6; color: #8a5f00; }
.wd-status.paid { background: var(--soft); color: var(--emerald); }
.wd-status.cancelled { background: #fbe6e4; color: var(--danger); }
.wd-amount-box { text-align: center; padding: 6px 0 2px; }
.wd-amount-box > span { display: block; color: var(--muted); font-size: 13.5px; }
.wd-amount-box b { font-family: var(--display); font-size: 40px; line-height: 1.15; font-weight: 700; letter-spacing: -.035em; color: var(--forest); }
.wd-amount-box small { font-size: .42em; font-weight: 600; letter-spacing: 0; color: var(--muted); }
input.range-light::-webkit-slider-runnable-track { background: linear-gradient(90deg, var(--emerald) var(--p, 100%), var(--line) var(--p, 100%)); }
input.range-light::-moz-range-track { background: var(--line); }
input.range-light::-moz-range-progress { background: var(--emerald); }
input.range-light::-webkit-slider-thumb { box-shadow: 0 2px 8px rgba(5, 40, 20, .35), 0 0 0 1px var(--line); }
.wd-limits { display: flex; justify-content: space-between; color: var(--muted); font-size: 12.5px; font-weight: 500; margin: -4px 0 14px; }

.face-box { position: relative; width: min(66vw, 240px); aspect-ratio: 1; margin: 0 auto 12px; border-radius: 50%; overflow: hidden; background: var(--forest); }
.face-box video { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); display: block; }
.face-ring { position: absolute; inset: 0; border-radius: 50%; box-shadow: inset 0 0 0 4px var(--line); transition: box-shadow .2s; }
.face-ring.good { box-shadow: inset 0 0 0 5px var(--neon); }
.face-status { text-align: center; font-weight: 550; color: var(--ink); min-height: 42px; }
.face-status.good { color: var(--emerald); }

.modal-wrap { position: fixed; z-index: 50; inset: 0; display: grid; place-items: center; padding: 20px; background: rgba(5, 30, 16, .62); animation: fade .2s ease; }
.modal { width: 100%; max-width: 360px; background: #fff; border-radius: 30px; padding: 28px 22px 22px; text-align: center; animation: rise .35s var(--ease); }
.modal-ic { width: 66px; height: 66px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto 16px; background: var(--neon); color: var(--neon-ink); font-size: 26px; }
.modal h2 { font-family: var(--display); font-size: 25px; line-height: 1.1; font-weight: 700; letter-spacing: -.03em; margin-bottom: 8px; }
.modal p { color: var(--muted); font-size: 16px; margin-bottom: 20px; }

/* Yurak urishi */
.heart { display: flex; align-items: center; gap: 13px; padding: 14px; background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); }
.heart-ic { flex: none; width: 46px; height: 46px; border-radius: 15px; display: grid; place-items: center; font-size: 19px; background: #fde9e7; color: #d33f33; }
.heart-main { flex: 1; min-width: 0; }
.heart-label { display: block; font-size: 12.5px; color: var(--muted); font-weight: 500; }
.heart-main b { display: block; font-family: var(--display); font-size: 22px; line-height: 1.15; font-weight: 700; letter-spacing: -.025em; }
.heart-main b small { font-family: "Onest", sans-serif; font-size: 12px; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.heart-main b.heart-none { font-size: 16.5px; color: var(--muted); }
.heart-when { font-size: 12px; color: var(--muted); }
.heart-btn { flex: none; min-height: 44px; padding: 0 17px; border-radius: 14px; background: var(--forest); color: #fff; font-family: var(--display); font-weight: 700; font-size: 14.5px; }
.heart-gauge { position: relative; width: 170px; height: 170px; margin: 0 auto 12px; }
.heart-gauge svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.heart-gauge circle { fill: none; stroke-width: 7; stroke-linecap: round; }
.heart-gauge .t { stroke: var(--line); }
.heart-gauge .p { stroke: #d33f33; transition: stroke-dashoffset .3s linear; }
.heart-gauge-in { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; color: #d33f33; font-size: 36px; }
.heart-gauge-in b { display: block; font-family: var(--display); font-size: 46px; line-height: 1; font-weight: 700; color: var(--ink); letter-spacing: -.03em; }
.heart-gauge-in small { display: block; font-size: 12px; color: var(--muted); }
.heart-disclaimer { text-align: center; color: var(--muted); font-size: 12px; margin-top: 12px; }
