/* חוסכים ביחד: shared design system. Light by default, dark via OS or toggle. No external requests. */
:root {
  color-scheme: light;
  --bg: #f5f5f7;
  --bg-2: #ffffff;
  --card: rgba(255, 255, 255, 0.78);
  --card-solid: #ffffff;
  --glass: rgba(255, 255, 255, 0.68);
  --fill: rgba(118, 118, 128, 0.12);
  --fill-2: rgba(118, 118, 128, 0.08);
  --hair: rgba(0, 0, 0, 0.08);
  --hair-2: rgba(0, 0, 0, 0.14);
  --text: #1d1d1f;
  --text-2: #6e6e73;
  --text-3: #86868b;
  --accent: #0071e3;
  --accent-ink: #0066cc;
  --accent-soft: rgba(0, 113, 227, 0.1);
  --green: #34c759;
  --green-ink: #1f8a3c;
  --green-soft: rgba(52, 199, 89, 0.14);
  --orange: #ff9f0a;
  --orange-ink: #b25e00;
  --orange-soft: rgba(255, 159, 10, 0.16);
  --red: #ff3b30;
  --red-ink: #d70015;
  --red-soft: rgba(255, 59, 48, 0.12);
  --purple: #8e44ec;
  --s1: #2a78d6; --s2: #eb6834; --s3: #1baf7a;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04), 0 2px 8px rgba(0, 0, 0, 0.04);
  --shadow: 0 2px 6px rgba(0, 0, 0, 0.04), 0 12px 32px rgba(0, 0, 0, 0.07);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.08), 0 32px 80px rgba(0, 0, 0, 0.12);
  --hero-glow-1: rgba(0, 113, 227, 0.16);
  --hero-glow-2: rgba(52, 199, 89, 0.14);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "SF Hebrew", system-ui, "Heebo", "Segoe UI", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --spring: cubic-bezier(0.34, 1.36, 0.5, 1);
  --ease: cubic-bezier(0.25, 0.1, 0.25, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --r-lg: 28px; --r-md: 20px; --r-sm: 14px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #000000; --bg-2: #0f0f11; --card: rgba(28, 28, 30, 0.78); --card-solid: #1c1c1e; --glass: rgba(22, 22, 24, 0.66);
    --fill: rgba(118, 118, 128, 0.24); --fill-2: rgba(118, 118, 128, 0.16); --hair: rgba(255, 255, 255, 0.09); --hair-2: rgba(255, 255, 255, 0.16);
    --text: #f5f5f7; --text-2: #a1a1a6; --text-3: #8e8e93;
    --accent: #2997ff; --accent-ink: #4aa8ff; --accent-soft: rgba(41, 151, 255, 0.16);
    --green: #30d158; --green-ink: #4cd964; --green-soft: rgba(48, 209, 88, 0.16);
    --orange: #ff9f0a; --orange-ink: #ffb340; --orange-soft: rgba(255, 159, 10, 0.18);
    --red: #ff453a; --red-ink: #ff6961; --red-soft: rgba(255, 69, 58, 0.16);
    --s1: #3987e5; --s2: #d95926; --s3: #199e70;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.5); --shadow: 0 12px 32px rgba(0, 0, 0, 0.5); --shadow-lg: 0 32px 80px rgba(0, 0, 0, 0.6);
    --hero-glow-1: rgba(41, 151, 255, 0.22); --hero-glow-2: rgba(48, 209, 88, 0.14);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #000000; --bg-2: #0f0f11; --card: rgba(28, 28, 30, 0.78); --card-solid: #1c1c1e; --glass: rgba(22, 22, 24, 0.66);
  --fill: rgba(118, 118, 128, 0.24); --fill-2: rgba(118, 118, 128, 0.16); --hair: rgba(255, 255, 255, 0.09); --hair-2: rgba(255, 255, 255, 0.16);
  --text: #f5f5f7; --text-2: #a1a1a6; --text-3: #8e8e93;
  --accent: #2997ff; --accent-ink: #4aa8ff; --accent-soft: rgba(41, 151, 255, 0.16);
  --green: #30d158; --green-ink: #4cd964; --green-soft: rgba(48, 209, 88, 0.16);
  --orange: #ff9f0a; --orange-ink: #ffb340; --orange-soft: rgba(255, 159, 10, 0.18);
  --red: #ff453a; --red-ink: #ff6961; --red-soft: rgba(255, 69, 58, 0.16);
  --s1: #3987e5; --s2: #d95926; --s3: #199e70;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.5); --shadow: 0 12px 32px rgba(0, 0, 0, 0.5); --shadow-lg: 0 32px 80px rgba(0, 0, 0, 0.6);
  --hero-glow-1: rgba(41, 151, 255, 0.22); --hero-glow-2: rgba(48, 209, 88, 0.14);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text); font-family: var(--font);
  font-size: 17px; line-height: 1.47; letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; overflow-x: hidden;
  transition: background-color .4s var(--ease), color .4s var(--ease);
}
img, svg { display: block; max-width: 100%; }
a { color: var(--accent-ink); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 55%, transparent); outline-offset: 3px; border-radius: 12px; }
.num, .tnum { font-variant-numeric: tabular-nums; }
.ltr { direction: ltr; unicode-bidi: isolate; display: inline-block; }
[hidden] { display: none !important; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- layout ---------- */
.wrap { max-width: 1120px; margin-inline: auto; padding-inline: 24px; }
.wrap-wide { max-width: 1280px; margin-inline: auto; padding-inline: 24px; }
.section { padding-block: 96px; }
.section-sm { padding-block: 56px; }
.center { text-align: center; }
.stack > * + * { margin-top: 12px; }
.grid { display: grid; gap: 20px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.row { display: flex; align-items: center; gap: 12px; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.wrap-row { flex-wrap: wrap; }
.grow { flex: 1 1 auto; min-width: 0; }
.muted { color: var(--text-2); }
.faint { color: var(--text-3); }
.small { font-size: 14px; }
.xs { font-size: 12px; }
@media (max-width: 900px) { .g3, .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) {
  .wrap, .wrap-wide { padding-inline: 16px; }
  .section { padding-block: 64px; }
  .g2, .g3, .g4 { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- type ---------- */
.eyebrow { font-size: 15px; font-weight: 600; color: var(--accent-ink); margin: 0 0 10px; letter-spacing: 0; }
.display { font-size: clamp(42px, 7.4vw, 84px); line-height: 1.04; font-weight: 700; letter-spacing: -0.02em; margin: 0; }
.h1 { font-size: clamp(34px, 5vw, 56px); line-height: 1.08; font-weight: 700; letter-spacing: -0.015em; margin: 0; }
.h2 { font-size: clamp(28px, 3.6vw, 40px); line-height: 1.12; font-weight: 700; letter-spacing: -0.01em; margin: 0; }
.h3 { font-size: 22px; line-height: 1.25; font-weight: 650; margin: 0; }
.h4 { font-size: 17px; line-height: 1.3; font-weight: 650; margin: 0; }
.lede { font-size: clamp(19px, 2.1vw, 24px); line-height: 1.42; color: var(--text-2); font-weight: 450; margin: 16px 0 0; max-width: 34em; }
.center .lede { margin-inline: auto; }
.grad-text { background: linear-gradient(100deg, var(--accent) 0%, #5e5ce6 45%, var(--green) 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- nav ---------- */
.nav { position: sticky; top: 0; z-index: 50; background: var(--glass); -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px); border-bottom: 1px solid var(--hair); }
.nav-in { max-width: 1280px; margin-inline: auto; padding-inline: 24px; height: 52px; display: flex; align-items: center; gap: 24px; }
.brand { display: flex; align-items: center; gap: 9px; font-weight: 700; font-size: 17px; color: var(--text); white-space: nowrap; }
.brand:hover { text-decoration: none; }
.brand-mark { width: 26px; height: 26px; border-radius: 8px; background: linear-gradient(140deg, #0a84ff, #30d158); display: grid; place-items: center; box-shadow: 0 2px 8px rgba(10, 132, 255, .35); }
.brand-mark svg { width: 16px; height: 16px; }
.nav-links { display: flex; gap: 4px; margin-inline-start: auto; align-items: center; }
.nav-links a { color: var(--text); opacity: .78; font-size: 14px; padding: 6px 11px; border-radius: 999px; transition: opacity .2s, background-color .2s; white-space: nowrap; }
.nav-links a:hover { opacity: 1; text-decoration: none; background: var(--fill-2); }
.nav-links a[aria-current="page"] { opacity: 1; background: var(--fill); font-weight: 600; }
.theme-btn { width: 34px; height: 34px; border-radius: 999px; border: 0; background: var(--fill-2); display: grid; place-items: center; cursor: pointer; flex: 0 0 auto; transition: transform .35s var(--spring), background-color .2s; }
.theme-btn:hover { background: var(--fill); }
.theme-btn:active { transform: scale(.88); }
.theme-btn svg { width: 18px; height: 18px; }
.theme-btn .moon { display: none; }
:root[data-theme="dark"] .theme-btn .sun { display: none; }
:root[data-theme="dark"] .theme-btn .moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-btn .sun { display: none; }
  :root:not([data-theme="light"]) .theme-btn .moon { display: block; }
}
@media (max-width: 820px) {
  .nav-in { height: auto; flex-wrap: wrap; padding: 10px 16px 0; gap: 8px 12px; }
  .nav-in .theme-btn { margin-inline-start: auto; }
  .nav-links { order: 3; width: calc(100% + 32px); margin: 0 -16px; padding: 4px 12px 8px; overflow-x: auto; scrollbar-width: none; -webkit-mask-image: linear-gradient(to left, #000 88%, transparent); mask-image: linear-gradient(to left, #000 88%, transparent); }
  .nav-links::-webkit-scrollbar { display: none; }
}

/* ---------- surfaces ---------- */
.card { background: var(--card); border: 1px solid var(--hair); border-radius: var(--r-lg); box-shadow: var(--shadow-sm); padding: 28px; position: relative; }
.card.glass { -webkit-backdrop-filter: saturate(180%) blur(24px); backdrop-filter: saturate(180%) blur(24px); }
.card.lift { transition: transform .5s var(--spring), box-shadow .4s var(--ease); }
.card.lift:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.card-sm { padding: 18px 20px; border-radius: var(--r-md); }
.tile { background: var(--card-solid); border-radius: var(--r-md); padding: 18px 20px; border: 1px solid var(--hair); }
.hairline { height: 1px; background: var(--hair); border: 0; margin: 20px 0; }
.icon-chip { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; flex: 0 0 auto; color: #fff; }
.icon-chip svg { width: 24px; height: 24px; }
.ic-blue { background: linear-gradient(150deg, #3ea0ff, #0071e3); }
.ic-green { background: linear-gradient(150deg, #5fe08a, #1fae4a); }
.ic-purple { background: linear-gradient(150deg, #b37bff, #7d3fe0); }
.ic-orange { background: linear-gradient(150deg, #ffbe4d, #ff8a00); }
.ic-pink { background: linear-gradient(150deg, #ff7aa2, #f0336d); }
.ic-teal { background: linear-gradient(150deg, #5ad8e6, #0f9fb5); }
.ic-gray { background: linear-gradient(150deg, #a1a1a6, #6e6e73); }

/* ---------- buttons ---------- */
.btn {
  --btn-bg: var(--fill); --btn-fg: var(--text);
  appearance: none; border: 0; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 22px; border-radius: 999px; background: var(--btn-bg); color: var(--btn-fg);
  font-size: 17px; font-weight: 600; letter-spacing: 0; white-space: nowrap; text-decoration: none !important; user-select: none;
  transition: transform .45s var(--spring), filter .2s, background-color .25s, box-shadow .25s, opacity .2s;
  -webkit-tap-highlight-color: transparent;
}
.btn:hover { filter: brightness(1.06); }
.btn:active, .btn.pressed { transform: scale(.95); transition-duration: .12s; filter: brightness(.94); }
.btn-primary { --btn-bg: var(--accent); --btn-fg: #fff; box-shadow: 0 4px 14px color-mix(in srgb, var(--accent) 32%, transparent); }
.btn-green { --btn-bg: var(--green); --btn-fg: #fff; box-shadow: 0 4px 14px color-mix(in srgb, var(--green) 32%, transparent); }
.btn-tint { --btn-bg: var(--accent-soft); --btn-fg: var(--accent-ink); }
.btn-plain { --btn-bg: transparent; --btn-fg: var(--accent-ink); padding: 0 10px; }
.btn-danger { --btn-bg: var(--red-soft); --btn-fg: var(--red-ink); }
.btn-lg { min-height: 54px; padding: 0 30px; font-size: 18px; }
.btn-sm { min-height: 34px; padding: 0 15px; font-size: 15px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .4; pointer-events: none; }
.btn svg { width: 18px; height: 18px; }
.link-arrow { font-weight: 500; display: inline-flex; align-items: center; gap: 4px; }
.link-arrow::after { content: "‹"; font-size: 1.2em; line-height: 1; transition: transform .35s var(--spring); }
.link-arrow:hover::after { transform: translateX(-3px); }
.tap { cursor: pointer; -webkit-tap-highlight-color: transparent; transition: transform .45s var(--spring), background-color .2s, box-shadow .3s; }
.tap:active, .tap.pressed { transform: scale(.97); transition-duration: .12s; }

/* ---------- chips & status ---------- */
.chip { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 11px; border-radius: 999px; font-size: 13px; font-weight: 600; background: var(--fill-2); color: var(--text-2); white-space: nowrap; }
.chip::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; display: none; }
.chip.dot::before { display: block; }
.chip.ok { background: var(--green-soft); color: var(--green-ink); }
.chip.warn { background: var(--orange-soft); color: var(--orange-ink); }
.chip.bad { background: var(--red-soft); color: var(--red-ink); }
.chip.info { background: var(--accent-soft); color: var(--accent-ink); }
.chip svg { width: 13px; height: 13px; }

/* ---------- segmented control ---------- */
.seg { position: relative; display: inline-grid; grid-auto-flow: column; grid-auto-columns: 1fr; background: var(--fill); border-radius: 12px; padding: 3px; gap: 0; isolation: isolate; max-width: 100%; }
.seg button { appearance: none; border: 0; background: transparent; padding: 7px 16px; font-size: 14px; font-weight: 600; color: var(--text); opacity: .72; border-radius: 9px; cursor: pointer; white-space: nowrap; transition: opacity .2s; position: relative; z-index: 1; }
.seg button[aria-pressed="true"], .seg button[aria-selected="true"] { opacity: 1; }
.seg .thumb { position: absolute; z-index: 0; top: 3px; bottom: 3px; border-radius: 9px; background: var(--card-solid); box-shadow: 0 3px 8px rgba(0, 0, 0, .12), 0 0 0 .5px rgba(0, 0, 0, .04); transition: inset-inline-start .5s var(--spring), width .5s var(--spring), left .5s var(--spring); }
:root[data-theme="dark"] .seg .thumb { background: #636366; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .seg .thumb { background: #636366; } }
.seg-lg button { padding: 10px 22px; font-size: 15px; }

/* ---------- iOS switch ---------- */
.switch { position: relative; width: 51px; height: 31px; flex: 0 0 auto; appearance: none; -webkit-appearance: none; border-radius: 999px; background: var(--fill); cursor: pointer; transition: background-color .3s var(--ease); margin: 0; border: 0; }
.switch::after { content: ""; position: absolute; top: 2px; right: 2px; width: 27px; height: 27px; border-radius: 50%; background: #fff; box-shadow: 0 3px 8px rgba(0, 0, 0, .15), 0 1px 1px rgba(0, 0, 0, .16); transition: transform .45s var(--spring), width .2s; }
.switch:checked { background: var(--green); }
.switch:checked::after { transform: translateX(-20px); }
.switch:active::after { width: 32px; }
.switch:checked:active::after { transform: translateX(-15px); }

/* ---------- grouped list (iOS settings style) ---------- */
.list { background: var(--card-solid); border-radius: var(--r-md); overflow: hidden; border: 1px solid var(--hair); }
.list-row { display: flex; align-items: center; gap: 14px; padding: 13px 16px; position: relative; min-height: 56px; }
.list-row + .list-row::before { content: ""; position: absolute; top: 0; inset-inline-start: 72px; inset-inline-end: 0; height: 1px; background: var(--hair); }
.list-row.plain + .list-row.plain::before { inset-inline-start: 16px; }
.list-row .icon-chip { width: 36px; height: 36px; border-radius: 10px; }
.list-row .icon-chip svg { width: 20px; height: 20px; }
.list-title { font-weight: 600; font-size: 16px; }
.list-sub { font-size: 13px; color: var(--text-2); line-height: 1.35; }

/* ---------- KPI ---------- */
.kpi .k-label { font-size: 14px; color: var(--text-2); font-weight: 500; }
.kpi .k-val { font-size: 34px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.1; margin-top: 6px; font-variant-numeric: tabular-nums; }
.kpi .k-delta { font-size: 13px; font-weight: 600; margin-top: 6px; color: var(--green-ink); }
.kpi .k-delta.down { color: var(--red-ink); }

/* ---------- table ---------- */
.table-wrap { overflow-x: auto; border-radius: var(--r-md); }
table.t { width: 100%; border-collapse: collapse; font-size: 15px; }
table.t th { text-align: start; font-size: 12px; font-weight: 600; color: var(--text-3); padding: 10px 14px; border-bottom: 1px solid var(--hair); white-space: nowrap; }
table.t td { padding: 13px 14px; border-bottom: 1px solid var(--hair); vertical-align: middle; }
table.t tr:last-child td { border-bottom: 0; }
table.t tbody tr { transition: background-color .2s; }
table.t tbody tr:hover { background: var(--fill-2); }
table.t .n { text-align: end; font-variant-numeric: tabular-nums; white-space: nowrap; }

/* ---------- details / how it works ---------- */
details.how { border-radius: var(--r-md); background: var(--card); border: 1px solid var(--hair); overflow: hidden; }
details.how > summary { list-style: none; cursor: pointer; padding: 18px 22px; display: flex; align-items: center; gap: 12px; font-weight: 600; font-size: 17px; }
details.how > summary::-webkit-details-marker { display: none; }
details.how > summary::after { content: ""; margin-inline-start: auto; width: 9px; height: 9px; border-bottom: 2px solid var(--text-3); border-inline-start: 2px solid var(--text-3); transform: rotate(-45deg); transition: transform .4s var(--spring); }
details.how[open] > summary::after { transform: rotate(135deg); }
details.how .how-body { padding: 0 22px 22px; color: var(--text-2); font-size: 15px; animation: fadeUp .45s var(--ease-out); }

/* ---------- code ---------- */
pre.code { margin: 0; direction: ltr; text-align: left; font-family: var(--mono); font-size: 12.5px; line-height: 1.6; background: #1c1c1e; color: #e5e5ea; border-radius: var(--r-md); padding: 18px 20px; overflow-x: auto; white-space: pre; }
pre.code .k { color: #ff7ab2; } pre.code .s { color: #fc6a5d; } pre.code .n { color: #d0bf69; } pre.code .c { color: #7f8c98; } pre.code .p { color: #67b7a4; } pre.code .f { color: #a167e6; }
:root[data-theme="dark"] pre.code { background: #111113; border: 1px solid var(--hair); }

/* ---------- toast ---------- */
.toast-host { position: fixed; z-index: 100; top: 70px; inset-inline: 0; display: grid; justify-items: center; pointer-events: none; gap: 8px; }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 10px; background: var(--glass); -webkit-backdrop-filter: saturate(180%) blur(24px); backdrop-filter: saturate(180%) blur(24px); border: 1px solid var(--hair); box-shadow: var(--shadow); border-radius: 999px; padding: 10px 18px 10px 14px; font-size: 15px; font-weight: 600; animation: toastIn .6s var(--spring) both; max-width: calc(100vw - 32px); }
.toast.out { animation: toastOut .35s var(--ease) both; }
.toast .t-ic { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--green); color: #fff; flex: 0 0 auto; }
.toast .t-ic svg { width: 13px; height: 13px; }
.toast.warn .t-ic { background: var(--orange); }
.toast.info .t-ic { background: var(--accent); }

/* ---------- forms ---------- */
.field { display: grid; gap: 7px; }
.field label { font-size: 14px; font-weight: 600; color: var(--text-2); }
.input { appearance: none; width: 100%; height: 50px; border-radius: 14px; border: 1px solid var(--hair-2); background: var(--card-solid); color: var(--text); padding: 0 16px; font: inherit; font-size: 17px; transition: border-color .2s, box-shadow .25s; }
.input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.field.ok .input { border-color: color-mix(in srgb, var(--green) 70%, transparent); }
.field.bad .input { border-color: var(--red); box-shadow: 0 0 0 4px var(--red-soft); }
.field .hint { font-size: 13px; color: var(--text-3); min-height: 18px; display: flex; align-items: center; gap: 6px; transition: color .2s; }
.field.ok .hint { color: var(--green-ink); }
.field.bad .hint { color: var(--red-ink); }
.input-wrap { position: relative; }
.input-wrap .v-ic { position: absolute; inset-inline-end: 14px; top: 50%; width: 22px; height: 22px; margin-top: -11px; border-radius: 50%; background: var(--green); color: #fff; display: grid; place-items: center; transform: scale(0); transition: transform .5s var(--spring); }
.input-wrap .v-ic svg { width: 12px; height: 12px; }
.field.ok .v-ic { transform: scale(1); }
.field.ok .input { padding-inline-end: 46px; }

/* ---------- progress ring ---------- */
.ring { position: relative; width: 168px; height: 168px; }
.ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring .track { stroke: var(--fill); }
.ring .bar { stroke: url(#ringGrad); stroke-linecap: round; transition: stroke-dashoffset .9s var(--ease-out); }
.ring .ring-c { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.ring .ring-pct { font-size: 40px; font-weight: 700; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; line-height: 1; }
.ring .ring-l { font-size: 13px; color: var(--text-2); margin-top: 4px; }

/* ---------- check-step list ---------- */
.steps-live { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.steps-live li { display: flex; align-items: center; gap: 12px; padding: 9px 4px; font-size: 15px; color: var(--text-3); transition: color .3s; }
.steps-live .s-ic { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--hair-2); flex: 0 0 auto; display: grid; place-items: center; transition: all .5s var(--spring); }
.steps-live .s-ic svg { width: 12px; height: 12px; opacity: 0; transform: scale(.4); transition: all .45s var(--spring); color: #fff; }
.steps-live li.active { color: var(--text); font-weight: 600; }
.steps-live li.active .s-ic { border-color: var(--accent); border-top-color: transparent; animation: spin .8s linear infinite; }
.steps-live li.done { color: var(--text); }
.steps-live li.done .s-ic { background: var(--green); border-color: var(--green); animation: none; }
.steps-live li.done .s-ic svg { opacity: 1; transform: scale(1); }
.steps-live li.fail .s-ic { background: var(--red); border-color: var(--red); animation: none; }
.steps-live .s-meta { margin-inline-start: auto; font-size: 12px; color: var(--text-3); font-weight: 500; font-family: var(--mono); direction: ltr; }

/* ---------- reveal ---------- */
.js .reveal { opacity: 0; transform: translateY(18px) scale(.985); transition: opacity .8s var(--ease-out), transform 1s var(--ease-out); }
.js .reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .06s; } .reveal.d2 { transition-delay: .12s; } .reveal.d3 { transition-delay: .18s; } .reveal.d4 { transition-delay: .24s; }

/* ---------- charts ---------- */
.chart { position: relative; width: 100%; }
.chart svg { width: 100%; height: auto; overflow: visible; }
.chart .grid-l { stroke: var(--hair); stroke-width: 1; }
.chart .axis-t { fill: var(--text-3); font-size: 11px; font-family: var(--font); }
.chart .line { fill: none; stroke-width: 2.25; stroke-linejoin: round; stroke-linecap: round; }
.chart .area { opacity: .14; }
.chart .hit { fill: transparent; cursor: crosshair; }
.chart .xhair { stroke: var(--text-3); stroke-width: 1; stroke-dasharray: 3 3; opacity: 0; transition: opacity .15s; }
.chart .dotm { stroke: var(--card-solid); stroke-width: 2; opacity: 0; transition: opacity .15s; }
.chart.hovering .xhair, .chart.hovering .dotm { opacity: 1; }
.chart .barm { transition: opacity .2s; cursor: default; }
.chart .barm:hover { opacity: .8; }
.chart-tip { position: absolute; pointer-events: none; z-index: 5; background: var(--card-solid); border: 1px solid var(--hair); box-shadow: var(--shadow); border-radius: 12px; padding: 8px 12px; font-size: 13px; line-height: 1.45; white-space: nowrap; opacity: 0; transform: translateY(4px); transition: opacity .15s, transform .2s var(--ease-out); }
.chart-tip.show { opacity: 1; transform: none; }
.chart-tip b { font-variant-numeric: tabular-nums; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px; color: var(--text-2); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-inline-end: 6px; vertical-align: -1px; }
.draw { stroke-dasharray: var(--len, 2000); stroke-dashoffset: var(--len, 2000); animation: draw 1.6s var(--ease-out) forwards; }

/* ---------- footer ---------- */
.foot { border-top: 1px solid var(--hair); padding: 28px 0 40px; font-size: 13px; color: var(--text-3); }
.foot .wrap-wide { display: flex; flex-wrap: wrap; gap: 10px 24px; align-items: center; justify-content: space-between; }
.foot nav { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.foot a { color: var(--text-2); }
.demo-note { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; color: var(--text-2); }
.demo-note::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--orange); }

/* ---------- device (iPhone frame) ---------- */
.device { --dw: 372px; --dh: 790px; width: var(--dw); height: var(--dh); border-radius: 60px; padding: 12px; background: linear-gradient(145deg, #2c2c2e, #0b0b0c 60%, #2a2a2c); box-shadow: 0 0 0 1.5px #3a3a3c inset, 0 0 0 1px #000, var(--shadow-lg); position: relative; flex: 0 0 auto; }
.device::before { content: ""; position: absolute; inset-inline-end: -3px; top: 190px; width: 3px; height: 72px; border-radius: 2px; background: #2a2a2c; }
.device .screen { width: 100%; height: 100%; border-radius: 48px; overflow: hidden; position: relative; background: var(--bg); isolation: isolate; }
.device .island { position: absolute; top: 11px; left: 50%; width: 112px; height: 33px; margin-left: -56px; background: #000; border-radius: 20px; z-index: 40; transition: width .6s var(--spring), height .6s var(--spring), margin .6s var(--spring), border-radius .6s var(--spring); }
.statusbar { position: absolute; top: 0; inset-inline: 0; height: 54px; z-index: 75; display: flex; align-items: center; justify-content: space-between; padding: 6px 32px 0; font-size: 16px; font-weight: 600; direction: ltr; pointer-events: none; color: var(--text); }
.statusbar .sb-ic { display: flex; gap: 6px; align-items: center; }
.statusbar svg { height: 12px; width: auto; }
.home-ind { position: absolute; bottom: 8px; left: 50%; width: 134px; height: 5px; margin-left: -67px; border-radius: 3px; background: var(--text); opacity: .85; z-index: 40; pointer-events: none; }
@media (max-width: 560px) {
  .device.fluid { --dw: 100%; --dh: calc(100svh - 92px); min-height: 620px; border-radius: 0; padding: 0; background: none; box-shadow: none; }
  .device.fluid::before, .device.fluid .island, .device.fluid .statusbar, .device.fluid .home-ind { display: none; }
  .device.fluid .screen { border-radius: 0; }
}

/* ---------- sheet (bottom sheet) ---------- */
.scrim { position: absolute; inset: 0; background: rgba(0, 0, 0, .32); opacity: 0; pointer-events: none; transition: opacity .4s var(--ease); z-index: 60; }
.scrim.on { opacity: 1; pointer-events: auto; }
.sheet { position: absolute; inset-inline: 0; bottom: 0; z-index: 61; background: var(--card-solid); border-radius: 30px 30px 0 0; box-shadow: 0 -10px 40px rgba(0, 0, 0, .18); transform: translateY(105%); transition: transform .62s var(--spring); max-height: 92%; display: flex; flex-direction: column; }
.sheet.on { transform: none; }
.sheet .grabber { width: 38px; height: 5px; border-radius: 3px; background: var(--hair-2); margin: 8px auto 0; flex: 0 0 auto; }
.sheet .sheet-body { padding: 14px 22px 30px; overflow-y: auto; }

/* ---------- keyframes ---------- */
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes toastIn { from { opacity: 0; transform: translateY(-24px) scale(.9); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateY(-14px) scale(.96); } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes pop { 0% { transform: scale(.6); opacity: 0; } 60% { transform: scale(1.08); opacity: 1; } 100% { transform: scale(1); } }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .45; } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
@keyframes rowIn { from { opacity: 0; transform: translateY(-10px); background-color: var(--accent-soft); } to { opacity: 1; transform: none; } }
@keyframes shake { 10%, 90% { transform: translateX(-1px); } 20%, 80% { transform: translateX(2px); } 30%, 50%, 70% { transform: translateX(-4px); } 40%, 60% { transform: translateX(4px); } }
.pop { animation: pop .6s var(--spring) both; }
.shake { animation: shake .5s var(--ease); }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); display: inline-block; box-shadow: 0 0 0 0 var(--green); animation: livePulse 2s infinite; }
@keyframes livePulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--green) 60%, transparent); } 70% { box-shadow: 0 0 0 8px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}
@media print { .nav, .foot, .theme-btn { display: none; } body { background: #fff; } }

/* ---------- horizontal bars ---------- */
.hbars { display: grid; gap: 14px; }
.hb-row { display: grid; gap: 7px; }
.hb-track { height: 8px; background: var(--fill-2); border-radius: 4px; overflow: hidden; }
.hb-fill { height: 100%; width: var(--w); border-radius: 4px; animation: growW 1.1s var(--ease-out) both; }
@keyframes growW { from { width: 0; } }
@media (max-width: 640px) {
  .g4.kpis-2, .g4:has(> .kpi) { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .kpi { padding: 14px 14px; }
  .kpi .k-val { font-size: 23px; }
  .kpi .k-label { font-size: 12.5px; }
  .kpi .k-delta { font-size: 12px; }
}
