/* Lotpic — витрина. Мир программы: тёмная студия, белая рамка площадки, один лайм. */

@font-face {
  font-family: "Golos Text";
  src: url("../fonts/GolosText-wght.woff2") format("woff2");
  font-weight: 400 900;
  font-display: swap;
}

:root {
  --bg: #141414;
  --bg-2: #0f0f0f;
  --panel: #1b1b1b;
  --panel-2: #222222;
  --panel-3: #2a2a2a;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.14);
  --fg: #f3f3f1;
  --fg-2: #b5b5b0;
  --fg-3: #92928d;
  --accent: #c6f24a;
  --accent-2: #d9ff6b;
  --accent-ink: #141a05;
  --accent-dim: rgba(198, 242, 74, 0.12);
  --r-frame: 14px;
  --r-control: 12px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --gutter: clamp(16px, 4vw, 40px);
  --section: clamp(72px, 10vw, 152px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; scrollbar-color: var(--panel-3) var(--bg-2); }
body {
  margin: 0;
  background: var(--bg-2);
  color: var(--fg);
  font: 400 17px/1.5 "Golos Text", system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
::selection { background: rgba(198, 242, 74, 0.35); color: var(--fg); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3, p, ol, ul, dl, dd, figure, fieldset { margin: 0; padding: 0; }
ol, ul { list-style: none; }
fieldset { border: 0; min-width: 0; }
a { color: inherit; text-decoration: none; }
svg { display: block; }
svg text { font-family: inherit; }
.defs { position: absolute; }
.wrap { width: 100%; max-width: 1280px; margin-inline: auto; padding-inline: var(--gutter); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 10; background: var(--accent); color: var(--accent-ink); padding: 10px 14px; border-radius: 10px; font-weight: 500; }
.skip:focus { top: 12px; }

h1, h2 { font-weight: 600; letter-spacing: -0.035em; text-wrap: balance; }
h1 { font-size: clamp(2.375rem, 5.5vw, 5rem); line-height: 0.98; }
h2 { font-size: clamp(1.875rem, 4vw, 3.5rem); line-height: 1.04; max-width: 17ch; }
h3 { font-size: 1.25rem; font-weight: 600; letter-spacing: -0.02em; line-height: 1.2; }
.sub { margin-top: 20px; max-width: 46ch; color: var(--fg-2); font-size: clamp(1.0625rem, 1.4vw, 1.25rem); line-height: 1.45; text-wrap: pretty; }
strong { font-weight: 600; color: var(--fg); }

/* ---- кнопки */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 44px; padding: 0 18px; border-radius: var(--r-control);
  font-weight: 500; font-size: 1rem; letter-spacing: -0.01em; white-space: nowrap;
  transition: background-color 160ms ease, color 160ms ease, transform 160ms var(--ease);
}
.btn svg { transition: transform 240ms var(--ease); }
.btn:hover svg { transform: translateX(4px); }
.btn:active { transform: translateY(1px); }
.btn--lg { height: 60px; padding: 0 28px; font-size: 1.1875rem; border-radius: 14px; }
.btn--primary { background: var(--accent); color: var(--accent-ink); }
.btn--primary:hover { background: var(--accent-2); }
.btn--quiet { background: var(--panel-2); color: var(--fg); }
.btn--quiet:hover { background: var(--panel-3); }
.btn--ink { background: var(--accent-ink); color: var(--accent); }
.btn--ink:hover { background: #000; color: var(--accent-2); }
.start .btn:focus-visible { outline-color: var(--accent-ink); }

/* ---- шапка */
.top { display: flex; align-items: center; gap: 32px; height: 76px; position: relative; z-index: 2; }
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; font-size: 1.3125rem; letter-spacing: -0.03em; }
.top__nav { display: flex; gap: 28px; margin-left: auto; color: var(--fg-2); font-size: 0.9375rem; }
.top__nav a, .foot__links a { text-decoration: underline transparent; text-underline-offset: 5px; transition: color 160ms ease, text-decoration-color 160ms ease; }
.top__nav a:hover, .foot__links a:hover { color: var(--fg); text-decoration-color: var(--accent); }

/* ---- первый экран: «стена» и «стол» */
.hero { position: relative; padding: clamp(20px, 3vw, 44px) 0 clamp(56px, 7vw, 104px); }
.hero::before { /* стол: тональный слой под нижней частью рамки */
  content: ""; position: absolute; inset: 62% 0 0 0; background: var(--panel); border-top: 1px solid var(--line);
}
.hero__grid { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 5vw, 88px); align-items: center; }
.hero__text { padding-bottom: 4vh; }
.lead { margin-top: 28px; max-width: 34ch; font-size: clamp(1.125rem, 1.6vw, 1.375rem); line-height: 1.42; color: var(--fg-2); text-wrap: pretty; }
.hero__cta { margin-top: 40px; display: flex; flex-wrap: wrap; align-items: center; gap: 18px 24px; }
.hero__note { max-width: 26ch; color: var(--fg-3); font-size: 0.9375rem; line-height: 1.4; }
.hero__stage { justify-self: end; width: 100%; max-width: 600px; }

/* ---- рамка, снимок, шторка */
.shot { position: absolute; inset: 0; overflow: hidden; }
.shot > svg, .shot > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.shot.has-photo > svg { display: none; }
.frame, .compare { position: relative; aspect-ratio: 3 / 4; border-radius: var(--r-frame); overflow: hidden; background: var(--panel); box-shadow: 0 40px 80px -32px rgba(0, 0, 0, 0.8), 0 0 0 1px var(--line); isolation: isolate; }
.compare { --pos: 32%; }
.sweep #hero-compare { --pos: 94%; } /* начало прохода шторки; дальше положение ведёт скрипт */
.compare__after { clip-path: inset(0 0 0 var(--pos)); }
.compare__line { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 2px; margin-left: -1px; background: var(--accent); pointer-events: none; }
.compare__knob { position: absolute; top: 50%; left: 50%; width: 48px; height: 48px; margin: -24px 0 0 -24px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; box-shadow: 0 6px 18px -4px rgba(0, 0, 0, 0.55); transition: transform 200ms var(--ease); }
.compare:hover .compare__knob { transform: scale(1.08); }
.compare__range { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; touch-action: pan-y; -webkit-appearance: none; appearance: none; }
.compare__range::-webkit-slider-thumb { -webkit-appearance: none; width: 56px; height: 100vh; }
.compare__range::-moz-range-thumb { width: 56px; height: 100vh; border: 0; }
.compare:has(.compare__range:focus-visible) .compare__knob { outline: 2px solid var(--fg); outline-offset: 3px; }
.tag { position: absolute; bottom: 14px; z-index: 1; padding: 6px 11px; border-radius: 999px; font-size: 0.8125rem; font-weight: 500; line-height: 1.2; pointer-events: none; }
.tag--l { left: 14px; background: rgba(15, 15, 15, 0.78); color: var(--fg); }
.tag--r { right: 14px; background: var(--accent); color: var(--accent-ink); }
.demo__note { margin-top: 12px; color: var(--fg-3); font-size: 0.8125rem; }
.demo.is-real .demo__note { display: none; }

/* ---- как это работает */
.how { background: var(--bg); padding: var(--section) 0; }
.steps { margin-top: clamp(40px, 6vw, 80px); display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 20px; }
.step { position: relative; }
.step h3 { display: flex; align-items: center; gap: 12px; margin-top: 26px; padding-top: 26px; border-top: 1px solid var(--line-2); position: relative; }
.step:not(:last-child) h3 { margin-right: -20px; padding-right: 20px; } /* линия идёт через промежуток */
.step__n { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); font-size: 0.875rem; font-weight: 600; letter-spacing: 0; font-variant-numeric: tabular-nums; flex: none; }
.step p { margin-top: 10px; color: var(--fg-2); font-size: 0.9375rem; line-height: 1.5; max-width: 30ch; text-wrap: pretty; }

.vig { height: 188px; border-radius: var(--r-frame); background: var(--panel); border: 1px solid var(--line); padding: 16px; overflow: hidden; font-size: 0.75rem; line-height: 1.3; color: var(--fg-2); }
.vig--photo { display: grid; }
.vig__drop { border: 1.5px dashed rgba(198, 242, 74, 0.5); background: var(--accent-dim); border-radius: 10px; display: flex; align-items: center; justify-content: center; gap: 12px; }
.vig__thumb { width: 78px; height: 104px; border-radius: 6px; transform: rotate(-4deg); box-shadow: 0 10px 20px -8px rgba(0, 0, 0, 0.7); }
.vig__plus { width: 40px; height: 40px; border-radius: 10px; background: var(--panel-2); color: var(--accent); display: grid; place-items: center; }
.vig--hints dl { display: grid; gap: 8px; height: 100%; align-content: center; }
.vig--hints dl > div { background: var(--bg-2); border: 1px solid var(--line); border-radius: 8px; padding: 7px 10px; }
.vig--hints dt { color: var(--fg-3); font-size: 0.6875rem; }
.vig--hints dd { color: var(--fg); font-size: 0.8125rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vig--hints dl > div:first-child { border-color: var(--accent); }
.vig--format { display: flex; align-items: flex-end; justify-content: center; gap: 12px; padding-bottom: 36px; }
.ratio { display: grid; justify-items: center; gap: 8px; font-variant-numeric: tabular-nums; }
.ratio i { display: block; border: 1.5px solid var(--line-2); border-radius: 5px; background: var(--panel-2); }
.ratio--34 i { width: 42px; height: 56px; }
.ratio--11 i { width: 44px; height: 44px; }
.ratio--43 i { width: 52px; height: 39px; }
.ratio.is-on { color: var(--accent); }
.ratio.is-on i { border-color: var(--accent); background: var(--accent-dim); }
.vig--level { display: grid; gap: 8px; align-content: center; }
.vig--level span { height: 40px; display: flex; align-items: center; padding: 0 12px; border-radius: 9px; background: var(--panel-2); border: 1px solid transparent; font-size: 0.8125rem; color: var(--fg-2); }
.vig--level .is-on { border-color: var(--accent); background: var(--accent-dim); color: var(--fg); }
.vig--variants { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; align-items: center; padding-inline: 12px; }
.vig--variants svg { width: 100%; aspect-ratio: 3 / 4; border-radius: 5px; }
.vig--variants .is-on { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---- уровни */
.levels { padding: var(--section) 0; }
.levels__grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: clamp(32px, 6vw, 104px); align-items: center; }
.levels__stage { width: 100%; max-width: 520px; justify-self: center; }
.dial { margin-top: 40px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: 16px; max-width: 520px; }
.dial label { position: relative; cursor: pointer; }
.dial input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.dial span { display: grid; place-items: center; height: 52px; border-radius: 12px; color: var(--fg-2); font-weight: 500; font-size: clamp(0.875rem, 1.3vw, 1.0625rem); letter-spacing: -0.01em; transition: background-color 200ms ease, color 200ms ease; }
.dial label:hover span { color: var(--fg); }
.dial input:checked + span { background: var(--accent); color: var(--accent-ink); }
.dial input:focus-visible + span { outline: 2px solid var(--fg); outline-offset: 2px; }

.freedom { margin-top: 18px; display: grid; grid-template-columns: auto repeat(3, 1fr); align-items: center; gap: 6px; max-width: 520px; color: var(--fg-3); font-size: 0.8125rem; }
.freedom span { margin-right: 10px; }
.freedom i { height: 4px; border-radius: 2px; background: var(--panel-3); transition: background-color 320ms var(--ease); }
.levels:has([value="exact"]:checked) .freedom i:nth-of-type(1),
.levels:has([value="creative"]:checked) .freedom i:nth-of-type(-n+2),
.levels:has([value="premium"]:checked) .freedom i { background: var(--accent); }

.levels__desc { margin-top: 28px; min-height: 5.6em; max-width: 40ch; font-size: clamp(1.0625rem, 1.4vw, 1.25rem); line-height: 1.45; color: var(--fg-2); }
.levels__desc p { display: none; text-wrap: pretty; }
.levels:has([value="exact"]:checked) .levels__desc [data-level="exact"],
.levels:has([value="creative"]:checked) .levels__desc [data-level="creative"],
.levels:has([value="premium"]:checked) .levels__desc [data-level="premium"] { display: block; animation: settle 420ms var(--ease); }
@keyframes settle { from { opacity: 0; transform: translateY(6px); } }

.levels__stage .shot { clip-path: inset(0 0 100% 0); transition: clip-path 0s linear 620ms; z-index: 0; } /* уходящий кадр держится, пока его не закроет новый */
.levels:has([value="exact"]:checked) .shot[data-level="exact"],
.levels:has([value="creative"]:checked) .shot[data-level="creative"],
.levels:has([value="premium"]:checked) .shot[data-level="premium"] { clip-path: inset(0); z-index: 1; transition: clip-path 620ms var(--ease); }

.facts { margin-top: 36px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line-2); max-width: 620px; }
.facts li { padding: 16px 16px 0 0; color: var(--fg-3); font-size: 0.875rem; line-height: 1.4; }
.facts li + li { padding-left: 16px; border-left: 1px solid var(--line); }
.facts strong { display: block; font-size: 1.0625rem; margin-bottom: 2px; }
.facts__note { margin-top: 16px; max-width: 620px; color: var(--fg-3); font-size: 0.8125rem; }

/* ---- категории */
.cats { background: var(--bg); padding: var(--section) 0; }
.cats__head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px clamp(32px, 6vw, 104px); align-items: end; }
.cats__head .sub { margin-top: 0; }
.cats__row { margin-top: clamp(48px, 7vw, 96px); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(24px, 4vw, 64px); align-items: start; }
.cat:nth-child(2) { margin-top: clamp(0px, 5vw, 72px); }
.cat__pair { position: relative; padding: 0 0 9% 13%; }
.print { position: absolute; left: 0; bottom: 0; width: 40%; aspect-ratio: 3 / 4; background: #f3f3f1; padding: 5px 5px 18px; border-radius: 3px; transform: rotate(-5deg); box-shadow: 0 18px 30px -12px rgba(0, 0, 0, 0.75); transition: transform 420ms var(--ease); z-index: 1; }
.print .shot { position: relative; inset: auto; width: 100%; height: 100%; }
.cat:nth-child(2) .print { transform: rotate(4deg); }
.cat:hover .print { transform: rotate(-1deg) translateY(-6px); }
.cat figcaption { margin-top: 24px; padding-left: 13%; }
.cat figcaption p { margin-top: 6px; color: var(--fg-2); font-size: 0.9375rem; max-width: 30ch; text-wrap: pretty; }
.markets { margin-top: clamp(56px, 7vw, 104px); padding-top: 28px; border-top: 1px solid var(--line-2); max-width: 30ch; font-size: clamp(1.375rem, 2.6vw, 2.25rem); line-height: 1.18; letter-spacing: -0.025em; color: var(--fg-2); text-wrap: balance; max-width: 26em; }

/* ---- финал: лаймовое поле */
.start { background: var(--accent); color: var(--accent-ink); padding: clamp(64px, 9vw, 128px) 0; overflow: hidden; }
.start ::selection { background: var(--accent-ink); color: var(--accent); }
.start__grid { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: clamp(24px, 6vw, 96px); align-items: center; }
.start__num { font-size: clamp(8rem, 26vw, 21rem); font-weight: 700; line-height: 0.78; letter-spacing: -0.06em; margin-left: -0.05em; font-variant-numeric: lining-nums; }
.start h2 { max-width: 14ch; }
.start__text > p { margin-top: 20px; max-width: 40ch; font-size: clamp(1.0625rem, 1.4vw, 1.25rem); line-height: 1.45; color: #2c3a0b; }
.start__text .btn { margin-top: 32px; }
.start__text .start__apps { margin-top: 28px; font-size: 0.9375rem; color: #3a4a12; }

/* ---- подвал */
.foot { background: var(--bg-2); padding: 40px 0 48px; }
.foot__grid { display: flex; flex-wrap: wrap; align-items: center; gap: 20px 40px; }
.foot .logo { font-size: 1.125rem; }
.foot__links { display: flex; flex-wrap: wrap; gap: 12px 28px; color: var(--fg-2); font-size: 0.9375rem; }
.foot__copy { margin-left: auto; color: var(--fg-3); font-size: 0.875rem; }

/* ---- появление шагов: линия дорисовывается, когда блок входит в кадр */
.js .steps .step h3::after { content: ""; position: absolute; left: 0; right: 0; top: -1px; height: 1px; background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform 700ms var(--ease); transition-delay: calc(var(--i, 0) * 140ms); }
.js .steps.is-in .step h3::after { transform: scaleX(1); }
.step:nth-child(2) { --i: 1; } .step:nth-child(3) { --i: 2; } .step:nth-child(4) { --i: 3; } .step:nth-child(5) { --i: 4; }

/* ---- первый экран помещает кнопку и в невысокое окно ноутбука */
@media (min-width: 821px) {
  h1 { font-size: clamp(2.375rem, min(5.5vw, 9svh), 5rem); }
  .hero__grid { align-items: start; }
  .hero__text { padding: clamp(8px, 5svh, 56px) 0 0; }
  .lead { margin-top: clamp(14px, 3svh, 28px); }
  .hero__cta { margin-top: clamp(18px, 4.4svh, 40px); }
}

/* ---- планшет */
@media (max-width: 1240px) {
  .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 48px; }
  .step:nth-child(3) h3 { margin-right: 0; padding-right: 0; }
}
@media (max-width: 1080px) {
  .levels__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 0.8fr); }
}

/* ---- телефон */
@media (max-width: 820px) {
  .top { height: 64px; gap: 16px; }
  .top__nav { display: none; }
  .top .btn { margin-left: auto; }
  .hero::before { inset: 74% 0 0 0; }
  .hero__grid { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .hero__text { padding-bottom: 0; }
  .lead { margin-top: 20px; max-width: 36ch; }
  .hero__cta { margin-top: 28px; }
  .hero__stage { justify-self: center; max-width: 480px; }

  .steps { grid-template-columns: minmax(0, 1fr); row-gap: 0; position: relative; }
  .step { display: grid; grid-template-columns: 28px minmax(0, 1fr); column-gap: 16px; padding-bottom: 36px; }
  .step:last-child { padding-bottom: 0; }
  .step::before { content: ""; position: absolute; left: 13.5px; top: 34px; bottom: 0; width: 1px; background: var(--line-2); }
  .step:last-child::before { display: none; }
  .step h3 { grid-column: 1 / -1; grid-row: 1; margin: 0; padding: 0; border: 0; gap: 16px; }
  .step:not(:last-child) h3 { margin-right: 0; padding-right: 0; }
  .js .steps .step h3::after { display: none; }
  .step p { grid-column: 2; grid-row: 2; margin-top: 6px; max-width: 40ch; }
  .step .vig { grid-column: 2; grid-row: 3; margin-top: 16px; height: 168px; max-width: 360px; }

  /* порядок на телефоне: заголовок, переключатель, рамка, описание — рамка сразу под переключателем */
  .levels__grid { display: flex; flex-direction: column; align-items: stretch; gap: 0; }
  .levels__text { display: contents; }
  .dial { order: 1; margin-top: 32px; max-width: none; }
  .freedom { order: 2; max-width: none; }
  .levels__stage { order: 3; margin-top: 24px; max-width: 440px; align-self: center; }
  .levels__desc { order: 4; min-height: 6.2em; margin-top: 24px; max-width: none; }
  .facts { order: 5; margin-top: 24px; max-width: none; }
  .facts__note { order: 6; max-width: none; }

  .cats__head { grid-template-columns: minmax(0, 1fr); }
  .cats__row { grid-template-columns: minmax(0, 1fr); gap: 56px; }
  .cat { width: min(84%, 380px); }
  .cat:nth-child(2) { margin-top: 0; margin-left: auto; }

  .start__grid { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .start__num { line-height: 0.8; }
  .foot__copy { margin-left: 0; width: 100%; }
}

@media (max-width: 400px) {
  .dial span { font-size: 0.8125rem; letter-spacing: -0.02em; }
  .btn--lg { height: 56px; padding: 0 22px; }
  .hero__cta .btn { width: 100%; }
  .hero__note { max-width: none; }
  .facts { grid-template-columns: minmax(0, 1fr); }
  .facts li, .facts li + li { padding: 12px 0; border-left: 0; }
  .facts li + li { border-top: 1px solid var(--line); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; transition-delay: 0s !important; }
}
