/* Страница продажи. Весь визуальный язык взят у самого продукта:
   чёрный экран, тонкие белые цифры, серые клавиши-капсулы и один оранжевый цвет знака «=». */
@font-face{font-family:'Onest';font-style:normal;font-weight:200 800;font-display:swap;src:url(fonts/onest-cyrillic.woff2) format('woff2');unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116}
@font-face{font-family:'Onest';font-style:normal;font-weight:200 800;font-display:swap;src:url(fonts/onest-latin-ext.woff2) format('woff2');unicode-range:U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF}
@font-face{font-family:'Onest';font-style:normal;font-weight:200 800;font-display:swap;src:url(fonts/onest-latin.woff2) format('woff2');unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD}

:root {
  --bg: #000;
  --ink: #fff;
  --soft: #c9c9ce;
  --mute: #8e8e93;
  --line: #262628;
  --key: #343434;
  --fn: #5e5e5e;
  --op: #ff9302;
  --panel: #121214;
  --w: 1120px;
  --pad: clamp(20px, 5vw, 48px);
  --font: 'Onest', -apple-system, 'Segoe UI', system-ui, sans-serif;
}
* { box-sizing: border-box; margin: 0; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { background: var(--bg); color: var(--ink); font: 400 17px/1.55 var(--font); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--op); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { font-weight: 500; letter-spacing: -.02em; text-wrap: balance; }
h1 { font-size: clamp(34px, 5.1vw, 58px); line-height: 1.06; }
h2 { font-size: clamp(25px, 3vw, 34px); line-height: 1.14; }
h3 { font-size: 19px; line-height: 1.3; letter-spacing: -.01em; font-weight: 600; }
p { max-width: 62ch; }

/* шапка */
.top { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  max-width: var(--w); margin: 0 auto; padding: 12px var(--pad); background: rgba(0,0,0,.82); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.mark { width: 34px; height: 32px; border-radius: 999px; background: var(--op); color: #000; display: grid; place-items: center; text-decoration: none; font-size: 22px; font-weight: 500; line-height: 1; }
.mark span { transform: translateY(-1px); }
.langs { display: flex; gap: 2px; margin-left: auto; }
.langs a { padding: 6px 9px; border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--mute); text-decoration: none; }
.langs a:hover { color: var(--ink); }
.langs a[aria-current] { color: var(--ink); background: var(--key); }
.top-buy { padding: 8px 16px; border-radius: 999px; background: var(--key); font-size: 14px; font-weight: 500; text-decoration: none; }
.top-buy:hover { background: var(--fn); }

/* первый экран */
.hero { max-width: var(--w); margin: 0 auto; padding: clamp(28px, 6vw, 72px) var(--pad) clamp(48px, 8vw, 96px);
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(28px, 6vw, 80px); align-items: center; }
.sub { margin-top: 22px; font-size: clamp(18px, 1.6vw, 21px); line-height: 1.45; color: var(--soft); max-width: 46ch; }
.cta { display: inline-flex; align-items: center; justify-content: center; margin-top: 32px; min-height: 62px; padding: 0 34px; border-radius: 999px;
  background: var(--op); color: #000; font-size: 19px; font-weight: 600; text-decoration: none; transition: filter .2s, transform .12s; }
.cta:hover { filter: brightness(1.1); }
.cta:active { transform: scale(.98); }
.under { margin-top: 14px; font-size: 14.5px; color: var(--mute); max-width: 44ch; }
.hero-demo { display: grid; justify-items: center; }
.clock { margin-top: 22px; font-size: 15px; color: var(--mute); }
.clock b { color: var(--ink); font-weight: 500; font-variant-numeric: tabular-nums; }
.demo-note { margin-top: 6px; font-size: 13.5px; color: var(--mute); text-align: center; max-width: 34ch; }

/* макет телефона: те же пропорции, что у настоящего калькулятора (экран 402x874) */
.phone { width: min(292px, 72vw); aspect-ratio: 402 / 874; container-type: inline-size; border-radius: 15.5% / 7.2%;
  background: #000; box-shadow: 0 0 0 1.5px #3a3a3c, 0 0 0 9px #0e0e10, 0 0 0 10.5px #2a2a2c; }
.p-screen { --u: calc(100cqw / 402); height: 100%; display: flex; flex-direction: column; justify-content: flex-end; padding-bottom: calc(58 * var(--u)); }
.p-display { padding: 0 calc(15 * var(--u)) calc(15 * var(--u)); text-align: right; overflow: hidden; }
.p-expr { min-height: calc(26 * var(--u)); font-size: calc(21 * var(--u)); line-height: calc(26 * var(--u)); color: rgba(235,235,245,.6); white-space: nowrap; }
.p-out { font: 400 calc(66 * var(--u))/1 -apple-system, 'Onest', system-ui, sans-serif; letter-spacing: calc(-.4 * var(--u)); white-space: nowrap; transform-origin: right center; }
.p-keys { display: grid; grid-template-columns: repeat(4, 1fr); column-gap: calc(7.4 * var(--u)); row-gap: calc(7.9 * var(--u)); padding: 0 calc(14.4 * var(--u)); }
.p-k { height: calc(81.6 * var(--u)); border-radius: 999px; display: grid; place-items: center; background: var(--key);
  font: 400 calc(35 * var(--u))/1 -apple-system, 'Onest', system-ui, sans-serif; transition: filter .3s ease; user-select: none; }
.p-k.fn { background: var(--fn); font-size: calc(32 * var(--u)); }
.p-k.op { background: var(--op); font-size: calc(44 * var(--u)); padding-bottom: calc(4 * var(--u)); }
.p-k.hit { filter: brightness(1.7); transition: none; }
.p-k.op.hit { filter: brightness(1.3); }

/* разделы: заголовок слева, содержание справа */
.band { max-width: var(--w); margin: 0 auto; padding: clamp(40px, 6vw, 72px) var(--pad); border-top: 1px solid var(--line);
  display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(20px, 5vw, 64px); align-items: start; }
.prose p + p { margin-top: 14px; }
.prose p, .plain li, .values p, .faq p { color: var(--soft); }

/* шаги: это настоящая последовательность, цифры оформлены как клавиши */
.steps { list-style: none; padding: 0; counter-reset: s; display: grid; gap: 14px; }
.steps li { counter-increment: s; position: relative; min-height: 43px; padding: 8px 0 8px 62px; max-width: 56ch; }
.steps li::before { content: counter(s); position: absolute; left: 0; top: 0; width: 46px; height: 43px; border-radius: 999px; background: var(--key); color: var(--ink); display: grid; place-items: center; font-size: 20px; }
.values { margin-top: 44px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 36px; }
.values > div { padding: 22px 0; border-top: 1px solid var(--line); }
.values p { margin-top: 8px; font-size: 16px; }
.plain { list-style: none; padding: 0; display: grid; gap: 12px; }
.plain li { padding-left: 22px; position: relative; max-width: 58ch; }
.plain li::before { content: ""; position: absolute; left: 0; top: .62em; width: 9px; height: 2px; background: var(--op); }

/* покупка */
.buy { max-width: var(--w); margin: clamp(24px, 4vw, 48px) auto; padding: clamp(28px, 5vw, 56px); background: var(--panel); border-radius: clamp(24px, 4vw, 40px);
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 420px); gap: clamp(24px, 5vw, 64px); align-items: start; scroll-margin-top: 80px; }
.buy-info p { margin-top: 14px; color: var(--soft); }
.buy-info .under { color: var(--mute); }
.price { font-size: clamp(64px, 9vw, 96px); font-weight: 300; line-height: 1; letter-spacing: -.03em; text-align: right; font-variant-numeric: tabular-nums; margin-bottom: 22px; }
.methods { display: grid; gap: 10px; }
.pill { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 56px; padding: 8px 22px; border: 0; border-radius: 999px;
  background: var(--key); color: var(--ink); font: 500 17px var(--font); text-align: center; text-decoration: none; cursor: pointer; transition: filter .2s, transform .12s; }
.pill:hover { filter: brightness(1.2); }
.pill:active { transform: scale(.985); }
.pill.primary { background: var(--op); color: #000; font-weight: 600; }
.pill.small { width: auto; min-height: 40px; padding: 0 16px; font-size: 14px; }
.pill[disabled] { opacity: .55; cursor: default; }
.method-note { margin: -2px 0 6px; padding: 0 22px; font-size: 13px; color: var(--mute); text-align: center; max-width: none; }
.link { background: none; border: 0; padding: 10px; color: var(--mute); font: 400 14.5px var(--font); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; justify-self: center; }
.card-form, .wait, .paid { display: grid; gap: 12px; }
.card-form[hidden], .wait[hidden], .paid[hidden] { display: none; }
.card-form label { font-size: 14px; color: var(--mute); }
.card-form input[type="email"], .card-form input[type="text"] { width: 100%; height: 54px; padding: 0 18px; border-radius: 16px; border: 1px solid #333336; background: #000; color: var(--ink); font: 400 17px var(--font); }
.card-form input:focus { outline: none; border-color: var(--op); }
.check { display: grid; grid-template-columns: 22px 1fr; gap: 10px; align-items: start; line-height: 1.4; }
.check input { width: 20px; height: 20px; margin-top: 1px; accent-color: var(--op); }
.wait p { color: var(--soft); }
.paid-title { font-size: 19px; font-weight: 500; }
.keyline { display: flex; align-items: center; gap: 10px; padding: 12px 12px 12px 18px; border-radius: 18px; background: #000; border: 1px solid #333336; }
.keyline code { flex: 1; font: 500 clamp(15px, 4.2vw, 19px) ui-monospace, 'SF Mono', Menlo, monospace; letter-spacing: .5px; overflow-wrap: anywhere; user-select: all; }
.paid .steps { margin: 6px 0; gap: 10px; }
.paid .steps li { min-height: 36px; padding: 6px 0 6px 50px; font-size: 15.5px; color: var(--soft); }
.paid .steps li::before { width: 38px; height: 36px; font-size: 17px; }
.msg { min-height: 22px; margin-top: 10px; font-size: 14.5px; color: #ff7a6b; }

/* вопросы */
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 18px 40px 18px 0; position: relative; font-size: 18px; font-weight: 500; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); font-size: 26px; font-weight: 300; color: var(--mute); transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq p { padding: 0 0 20px; }

.foot { max-width: var(--w); margin: 0 auto; padding: 36px var(--pad) 56px; border-top: 1px solid var(--line); display: grid; gap: 8px; font-size: 14px; color: var(--mute); }
.foot p { max-width: none; }

/* текстовые страницы: инструкция и политика */
.doc { max-width: 760px; margin: 0 auto; padding: clamp(24px, 5vw, 56px) var(--pad) 80px; }
.doc h1 { font-size: clamp(30px, 4.4vw, 44px); }
.doc h2 { margin-top: 48px; padding-top: 28px; border-top: 1px solid var(--line); font-size: clamp(22px, 2.6vw, 28px); }
.doc p, .doc li, .doc dd { color: var(--soft); }
.doc .lead { margin-top: 18px; font-size: 20px; line-height: 1.45; color: var(--ink); }
.doc p { margin-top: 14px; }
.doc ol, .doc ul { margin-top: 16px; padding-left: 0; list-style: none; display: grid; gap: 12px; }
.doc ol { counter-reset: s; }
.doc ol li { counter-increment: s; position: relative; min-height: 38px; padding: 6px 0 6px 54px; }
.doc ol li::before { content: counter(s); position: absolute; left: 0; top: 0; width: 40px; height: 38px; border-radius: 999px; background: var(--key); color: var(--ink); display: grid; place-items: center; font-size: 17px; }
.doc ul li { padding-left: 22px; position: relative; }
.doc ul li::before { content: ""; position: absolute; left: 0; top: .62em; width: 9px; height: 2px; background: var(--op); }
.doc b { color: var(--ink); font-weight: 600; }
.doc dl { margin-top: 16px; }
.doc dt { margin-top: 18px; font-weight: 600; color: var(--ink); }
.doc dd { margin: 6px 0 0; }
.doc a { color: var(--op); text-underline-offset: 3px; }
.doc .card-form { margin-top: 28px; max-width: 420px; }

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; }
  .hero-demo { order: 2; margin-top: 8px; }
  .band, .buy { grid-template-columns: 1fr; }
  .buy { margin-left: var(--pad); margin-right: var(--pad); }
  .price { text-align: left; }
  .values { grid-template-columns: 1fr; }
  .top-buy { display: none; }
}
@media (max-width: 420px) {
  .langs a { padding: 6px 7px; }
  .cta { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
