/* смэш — landing site layout. Soft, paper-like, generous whitespace. */

html, body {
  margin: 0; padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100%;
}
body { display: flex; flex-direction: column; min-height: 100vh; }

a { color: inherit; text-decoration: none; }
button { font-family: inherit; }

h1, h2, h3 { text-wrap: balance; }
p { text-wrap: pretty; }

/* ---- reveal on scroll (fx.js) ------------------------------------------
   Hidden state is gated on html.js + motion preference, so no-JS and
   reduced-motion visitors always see the page fully rendered. */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity .65s var(--ease), transform .65s var(--ease);
    transition-delay: calc(var(--rd, 0) * 90ms);
  }
  .js [data-reveal].is-in { opacity: 1; transform: none; }
}

/* ---- container --------------------------------------------------------- */
.wrap {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 28px;
}

/* ---- navbar ------------------------------------------------------------ */
.nav {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  background: var(--chrome);
  border-bottom: 1px solid var(--separator);
  transition: box-shadow .25s var(--ease);
}
.nav.is-scrolled { box-shadow: var(--shadow-nav); }
.nav-inner {
  display: flex; align-items: center; gap: 20px;
  height: 68px;
}
.brand {
  display: flex; align-items: center; gap: 12px;
}
.brand-text {
  display: flex; flex-direction: column; line-height: 1;
}
.brand-name {
  font-family: var(--font-display);
  font-size: 19px; font-weight: 800; letter-spacing: -0.4px;
  color: var(--text);
}
.brand-sub {
  margin-top: 3px;
  font-size: 11.5px; font-weight: 600; color: var(--secondary);
  letter-spacing: 0.02em;
}
.nav-links {
  display: flex; align-items: center; gap: 4px;
  margin-left: 32px;
}
.nav-link {
  padding: 8px 14px;
  border-radius: var(--r-pill);
  font-size: 14px; font-weight: 600; color: var(--secondary);
  transition: background .18s var(--ease), color .18s var(--ease);
}
.nav-link:hover { background: var(--hover); color: var(--text); }
.nav-link.active {
  background: var(--accent-soft);
  color: var(--accent);
}
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.icon-btn {
  display: grid; place-items: center;
  width: 38px; height: 38px;
  border-radius: var(--r-pill);
  background: transparent; border: 1px solid transparent;
  color: var(--secondary); cursor: pointer;
  transition: background .18s var(--ease), color .18s var(--ease), border-color .18s var(--ease);
}
.icon-btn:hover { background: var(--hover); color: var(--text); border-color: var(--separator); }

/* Theme toggle shows the icon of the mode you'd switch TO: moon while light,
   sun while dark — reflecting the real current theme, system pref included. */
#themeBtn .ico-sun { display: none; }
#themeBtn .ico-moon { display: block; }
:root[data-theme="dark"] #themeBtn .ico-sun { display: block; }
:root[data-theme="dark"] #themeBtn .ico-moon { display: none; }
:root[data-theme="light"] #themeBtn .ico-sun { display: none; }
:root[data-theme="light"] #themeBtn .ico-moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) #themeBtn .ico-sun { display: block; }
  :root:not([data-theme]) #themeBtn .ico-moon { display: none; }
}

/* ---- hamburger / mobile menu ----------------------------------------- */
.nav-toggle {
  display: none;
  position: relative;
  width: 40px; height: 40px;
  padding: 0;
  border-radius: var(--r-pill);
  background: transparent; border: 1px solid transparent;
  color: var(--text); cursor: pointer;
  transition: background .18s var(--ease), border-color .18s var(--ease);
}
.nav-toggle:hover { background: var(--hover); border-color: var(--separator); }
.nav-toggle-bars {
  position: absolute; left: 50%; top: 50%;
  width: 18px; height: 12px;
  transform: translate(-50%, -50%);
}
.nav-toggle-bars i {
  position: absolute; left: 0; right: 0;
  height: 2px; border-radius: 2px;
  background: currentColor;
  transition: transform .22s var(--ease), opacity .18s var(--ease), top .22s var(--ease);
}
.nav-toggle-bars i:nth-child(1) { top: 0; }
.nav-toggle-bars i:nth-child(2) { top: 5px; }
.nav-toggle-bars i:nth-child(3) { top: 10px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars i:nth-child(1) {
  top: 5px; transform: rotate(45deg);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bars i:nth-child(2) {
  opacity: 0; transform: scaleX(0);
}
.nav-toggle[aria-expanded="true"] .nav-toggle-bars i:nth-child(3) {
  top: 5px; transform: rotate(-45deg);
}

.mobile-menu {
  position: fixed; left: 0; right: 0;
  top: 68px;
  bottom: 0;
  z-index: 49;
  display: none;
  flex-direction: column;
  padding: 14px 22px 28px;
  background: var(--bg);
  border-top: 1px solid var(--separator);
  overflow-y: auto;
}
.mobile-menu[data-open="true"] { display: flex; }
.mobile-menu .nav-link {
  display: flex; align-items: center;
  padding: 14px 16px;
  border-radius: var(--r-md);
  font-size: 17px;
  color: var(--text);
}
.mobile-menu .nav-link.active {
  background: var(--accent-soft);
  color: var(--accent);
}
.mobile-menu .nav-link + .nav-link { margin-top: 2px; }
.mobile-menu .mobile-cta {
  margin-top: 18px;
  width: 100%;
}
body.menu-open { overflow: hidden; }

/* ---- buttons ----------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 22px;
  border-radius: var(--r-pill);
  font-size: 14.5px; font-weight: 700;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .12s var(--ease), background .18s var(--ease), border-color .18s var(--ease), color .18s var(--ease), box-shadow .18s var(--ease);
}
.btn-primary {
  background: var(--accent); color: var(--on-accent);
  box-shadow: var(--shadow-accent);
}
.btn-primary svg { transition: transform .18s var(--ease); }
.btn-primary:hover { background: var(--accent-hover); }
.btn-primary:hover svg { transform: translateY(2px); }
.btn-primary:active { background: var(--accent-press); transform: translateY(1px); }
.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border-strong);
}
.btn-ghost:hover { background: var(--hover); }
.btn-sm { height: 38px; padding: 0 16px; font-size: 13.5px; }
.btn-lg { height: 52px; padding: 0 28px; font-size: 15.5px; }

/* ---- main / footer skeleton ------------------------------------------- */
main { flex: 1 0 auto; }
.section { padding: 64px 0; }
.section-tight { padding: 40px 0; }

/* ---- hero / two-column with reserved GIF space ------------------------ */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}
.split-text { max-width: 560px; }

/* Browser marker — recognisable store logos, no pill, no pulsing dot. */
.browser-badge {
  display: inline-flex; align-items: center; gap: 11px;
  margin-bottom: 24px;
  font-size: 13.5px; font-weight: 700;
  color: var(--text); letter-spacing: 0.01em;
}
.browser-logos { display: inline-flex; align-items: center; }
.browser-logos .b-logo {
  width: 22px; height: 22px;
  border-radius: 50%;
  box-shadow: 0 0 0 2px var(--bg);
}
.browser-logos .b-logo + .b-logo { margin-left: -7px; }
.b-logo text { font-family: var(--font-display); }

/* Editorial overline — quiet, deliberate, not a badge. */
.overline {
  display: inline-flex; align-items: center; gap: 12px;
  margin-bottom: 22px;
  font-size: 12px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.16em;
  color: var(--accent);
}
.overline::before {
  content: ""; width: 26px; height: 2px; border-radius: 2px;
  background: var(--accent); opacity: 0.85;
}
h1.display {
  font-family: var(--font-display);
  font-size: clamp(38px, 5vw, 56px);
  font-weight: 700;
  letter-spacing: -0.6px;
  line-height: 1.06;
  margin: 0 0 22px;
}
/* Highlighter swipe — like a marker run over the key words in a notebook.
   box-decoration-break keeps the wash intact when the phrase wraps. */
.display em {
  font-style: normal;
  font-weight: 700;
  color: var(--accent);
  background: linear-gradient(100deg,
    transparent 0.5%, var(--accent-soft-strong) 4%,
    var(--accent-soft) 96%, transparent 99.5%);
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
  padding: 0.04em 0.14em 0.1em;
  margin: 0 -0.14em;
  border-radius: 0.25em 0.4em 0.3em 0.45em;
}
.lede {
  font-size: 18px; color: var(--secondary);
  margin: 0 0 32px;
}
.cta-row { display: flex; gap: 12px; flex-wrap: wrap; }
.meta-row {
  display: flex; gap: 22px; flex-wrap: wrap;
  margin-top: 28px;
  font-size: 13px; color: var(--tertiary);
}
.meta-row span { display: inline-flex; align-items: center; gap: 6px; }

/* ---- home hero (stacked: copy, then wide browser video) --------------- */
.hero { position: relative; padding-bottom: 56px; }
.hero > .wrap { position: relative; }
/* Two soft ambient washes — one behind the video, one low-left behind the
   copy — so the hero feels lit rather than flat. Theme-aware via tokens. */
.hero::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(46% 60% at 84% 18%, var(--hero-glow) 0%, transparent 100%),
    radial-gradient(40% 52% at 6% 88%, var(--hero-glow) 0%, transparent 100%);
  pointer-events: none;
}
/* Stacked mobile hero: one quiet wash behind the video only, so the copy
   sits on clean paper. */
@media (max-width: 880px) {
  .hero::before {
    background: radial-gradient(80% 42% at 50% 96%, var(--hero-glow) 0%, transparent 100%);
    opacity: 0.75;
  }
}
.hero-copy { max-width: 690px; }
.hero-media { margin-top: 52px; }

/* Staggered entrance on load (JS-gated so no-JS visitors see everything;
   skipped entirely for reduced-motion). */
@media (prefers-reduced-motion: no-preference) {
  .js .hero-copy > *,
  .js .hero-media {
    opacity: 0;
    animation: hero-rise 0.7s var(--ease) forwards;
  }
  .js .hero-copy > *:nth-child(2) { animation-delay: 0.08s; }
  .js .hero-copy > *:nth-child(3) { animation-delay: 0.16s; }
  .js .hero-copy > *:nth-child(4) { animation-delay: 0.24s; }
  .js .hero-copy > *:nth-child(5) { animation-delay: 0.32s; }
  .js .hero-media { animation-delay: 0.2s; animation-duration: 0.85s; }
  @keyframes hero-rise {
    from { opacity: 0; transform: translateY(18px); }
    to { opacity: 1; transform: none; }
  }
}

/* Teal-tinted light spilling from under the journal video. */
.hero .browser {
  box-shadow: var(--shadow-card),
    0 50px 90px -50px rgba(40, 33, 20, 0.4),
    0 42px 110px -48px var(--accent-glow);
}

/* Soft ambient wash behind the hero video so it feels embedded, not pasted */
.hero-media-wrap { position: relative; }
.hero-media-wrap::before {
  content: ""; position: absolute; z-index: 0;
  left: 50%; top: 8%; transform: translateX(-50%);
  width: 86%; height: 90%;
  background: radial-gradient(60% 60% at 50% 40%, var(--hero-glow-strong), transparent 70%);
  filter: blur(46px); opacity: 0.8; pointer-events: none;
}
.hero-media-wrap > .browser { position: relative; z-index: 1; }

/* Floating UI chips pinned to the hero video — echo the extension's own
   toasts. They sit on the floating wrapper so they move with the frame. */
.hero-chip {
  position: absolute; z-index: 2;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 14px;
  border-radius: var(--r-md);
  background: var(--card);
  border: 1px solid var(--separator);
  box-shadow: var(--shadow-pop);
  font-size: 13px; font-weight: 700; color: var(--text);
  white-space: nowrap; pointer-events: none;
}
.hero-chip svg { width: 15px; height: 15px; color: var(--accent); }
.hero-chip--done {
  left: -18px; bottom: 26px;
  transform: rotate(-1.6deg);
}
.hero-chip--done svg { color: var(--green); }
.hero-chip--file {
  right: -14px; top: 68px;
  transform: rotate(1.2deg);
}
@media (max-width: 880px) {
  .hero-chip { display: none; }
}

/* Desktop only: stand the copy and the journal video side by side so the
   video is in view the moment the page opens, instead of sitting a full
   screen below the fold. Everything at <=880px keeps the original stacked
   layout untouched (mobile is intentionally left as-is). */
@media (min-width: 881px) {
  .hero { padding-top: 48px; padding-bottom: 28px; }
  .hero .wrap {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.02fr);
    align-items: center;
    gap: 52px;
  }
  .hero-copy { max-width: 560px; }
  .hero .display { font-size: clamp(40px, 3.6vw, 54px); }
  .hero .lede { margin-bottom: 26px; }
  .hero-media { margin-top: 0; }
  /* The side-by-side hero is short, so the old 64px section padding left a
     dead band before "Что умеет смэш AI". Pull that section up to close it
     (desktop only); the heading + cards now fill the lower part of the
     screen at any viewport height instead of leaving a void. */
  .hero + .section { padding-top: 32px; }
}

/* ---- browser-framed media (the wide journal video) ------------------- */
.browser {
  border-radius: var(--r-2xl);
  background: var(--card);
  border: 1px solid var(--separator);
  box-shadow: var(--shadow-card), 0 50px 90px -50px rgba(40, 33, 20, 0.4);
  overflow: hidden;
}
.browser-bar {
  display: grid; grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 12px 16px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--separator);
}
.browser-dots { display: inline-flex; gap: 8px; justify-self: start; }
.browser-dots i { width: 11px; height: 11px; border-radius: 50%; }
.browser-dots i:nth-child(1) { background: #f0655a; }
.browser-dots i:nth-child(2) { background: #f2bd42; }
.browser-dots i:nth-child(3) { background: #54c25a; }
.browser-url {
  justify-self: center;
  display: inline-flex; align-items: center; gap: 8px;
  min-width: 200px; max-width: 360px;
  padding: 7px 18px;
  border-radius: var(--r-pill);
  background: var(--bg); border: 1px solid var(--separator);
  color: var(--tertiary); font-size: 12.5px; font-weight: 600;
}
.browser-url svg { width: 13px; height: 13px; opacity: 0.75; }
.browser video, .browser img { display: block; width: 100%; height: auto; }

/* ---- portrait device frame (the popup video) ------------------------- */
.device {
  position: relative; z-index: 1;
  width: 100%; max-width: 340px; margin: 0 auto;
  border-radius: var(--r-2xl);
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--separator);
  box-shadow: var(--shadow-card), 0 44px 80px -44px rgba(40, 33, 20, 0.42);
}
.device video { display: block; width: 100%; height: auto; }
.device-wrap { position: relative; display: grid; place-items: center; }
.device-wrap::before {
  content: ""; position: absolute; inset: 6% 12%;
  background: radial-gradient(60% 60% at 50% 45%, var(--accent-soft-strong), transparent 70%);
  filter: blur(44px); opacity: 0.85; pointer-events: none;
}

/* Gentle float — only when motion is welcome */
@media (prefers-reduced-motion: no-preference) {
  .float { animation: floaty 7s var(--ease) infinite; }
  @keyframes floaty {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
  }
}

/* Tap-to-play: on touch devices or when the user prefers reduced motion,
   the hero clips stay on their poster behind a play button until tapped. */
.browser.tap-to-play, .device.tap-to-play, .frame.tap-to-play { cursor: pointer; }
.browser.tap-to-play::after, .device.tap-to-play::after, .frame.tap-to-play::after {
  content: ""; position: absolute; inset: 0; z-index: 3;
  background-color: rgba(20, 18, 14, 0.18);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'%3E%3Ccircle cx='32' cy='32' r='30' fill='white' fill-opacity='0.94'/%3E%3Cpath d='M26 20l20 12-20 12z' fill='%231f8f8b'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: center;
  background-size: 58px 58px;
  transition: opacity 0.25s var(--ease);
}
.browser.tap-to-play.is-playing::after,
.device.tap-to-play.is-playing::after,
.frame.tap-to-play.is-playing::after {
  opacity: 0; pointer-events: none;
}

@media (max-width: 880px) {
  .split { grid-template-columns: 1fr; gap: 36px; }
  .nav-links { display: none; }
  .nav-toggle { display: inline-grid; }
  .nav-right .btn { display: none; }
  .hero-media { margin-top: 40px; }
}

@media (max-width: 640px) {
  .wrap { padding: 0 18px; }
  .nav-inner { height: 60px; gap: 12px; }
  .mobile-menu { top: 60px; }
  .brandmark { width: 30px; height: 30px; font-size: 16px; }
  .brand-name { font-size: 17px; }
  .section { padding: 44px 0; }
  .hero { padding-bottom: 36px; }
  .hero-media { margin-top: 28px; }
  h1.display { font-size: clamp(30px, 8.6vw, 38px); letter-spacing: -0.8px; }
  .lede { font-size: 16px; margin-bottom: 24px; }
  .meta-row { gap: 10px 16px; margin-top: 22px; }
  .cta-row .btn { flex: 1 1 auto; }
  .btn { height: 46px; padding: 0 18px; }
  .browser-bar { padding: 9px 12px; }
  .browser-url {
    min-width: 0; max-width: 100%;
    padding: 6px 12px; font-size: 11.5px;
  }
  .browser-dots i { width: 9px; height: 9px; }
  .cards-3 { gap: 14px; }
  .card { padding: 18px; }
  .card-media { margin: -18px -18px 14px; }
  .section-head { margin-bottom: 32px; }
  .section-head h1, .section-head h2 { font-size: clamp(24px, 6.6vw, 30px); }
  .tier { padding: 22px; }
  .tier-price { font-size: 34px; }
  .step { grid-template-columns: 38px 1fr; gap: 12px; }
  .step::before { left: 18px; top: 44px; }
  .step-num { width: 38px; height: 38px; font-size: 15px; }
  .footer { padding: 32px 0 22px; margin-top: 48px; }
  .install-hero { padding: 56px 0 28px; }
  .install-hero p { font-size: 16px; }
  .legal-wrap { padding: 44px 18px 64px; }
}

@media (max-width: 560px) {
  /* keep the sticky header compact — the longer tagline would wrap */
  .brand-sub { display: none; }
  .browser-badge { flex-wrap: wrap; gap: 8px 10px; }
}

/* ---- section heading -------------------------------------------------- */
.section-head {
  text-align: center; margin-bottom: 48px;
}
.section-head .eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  margin-bottom: 16px;
  font-size: 12px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.16em;
  color: var(--accent);
}
.section-head .eyebrow::before,
.section-head .eyebrow::after {
  content: ""; width: 22px; height: 2px; border-radius: 2px;
  background: var(--accent); opacity: 0.8;
}

/* ---- subjects ticker (quiet divider between hero and features) -------- */
.ticker {
  overflow: hidden;
  border-top: 1px solid var(--separator);
  border-bottom: 1px solid var(--separator);
  padding: 15px 0;
}
.ticker-track {
  display: flex; width: max-content;
}
.ticker-track span {
  display: inline-flex; align-items: center;
  font-family: var(--font-display);
  font-size: 11.5px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--tertiary);
  white-space: nowrap;
}
.ticker-track span::after {
  content: ""; width: 5px; height: 5px; border-radius: 50%;
  background: var(--accent); opacity: 0.55;
  margin: 0 22px;
}
@media (prefers-reduced-motion: no-preference) {
  .ticker-track { animation: ticker-roll 56s linear infinite; }
  .ticker:hover .ticker-track { animation-play-state: paused; }
  @keyframes ticker-roll {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
  }
}
.section-head h1,
.section-head h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.4vw, 38px);
  font-weight: 700; letter-spacing: -0.6px;
  margin: 0 0 12px;
}
.section-head p {
  margin: 0 auto; max-width: 560px;
  color: var(--secondary); font-size: 16px;
}

/* ---- feature cards ---------------------------------------------------- */
.cards-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.card {
  background: var(--card);
  border: 1px solid var(--separator);
  border-radius: var(--r-xl);
  padding: 22px;
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease);
}
.card:hover {
  transform: translateY(-4px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-card), 0 26px 48px -26px rgba(40, 33, 20, 0.32);
}
/* video sits flush to the top edge of the card */
.card-media {
  position: relative;
  margin: -22px -22px 18px;
  aspect-ratio: 7 / 5;
  background: var(--surface-2);
  border-bottom: 1px solid var(--separator);
  overflow: hidden;
}
.card-media video {
  display: block; width: 100%; height: 100%; object-fit: cover;
}
/* hover-to-play hint pill */
.play-hint {
  position: absolute; z-index: 2;
  left: 50%; bottom: 12px; transform: translateX(-50%);
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px 6px 10px; border-radius: 999px;
  background: rgba(20, 18, 14, 0.62);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  color: #fff; font-size: 12.5px; font-weight: 600; line-height: 1;
  white-space: nowrap; pointer-events: none;
  box-shadow: 0 4px 14px -6px rgba(0,0,0,0.45);
  transition: opacity .25s var(--ease), transform .25s var(--ease);
  animation: hint-bob 2.2s var(--ease) infinite;
}
.play-hint svg { width: 13px; height: 13px; }
/* Show the right verb: hover on fine-pointer devices, tap on touch.
   The query is the De Morgan negation of the JS check
   `(hover: hover) and (pointer: fine)`, so label and behaviour stay in sync. */
.play-hint .hint-tap { display: none; }
@media (hover: none), (pointer: coarse) {
  .play-hint .hint-hover { display: none; }
  .play-hint .hint-tap { display: inline; }
}
@keyframes hint-bob {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(-3px); }
}
/* hide the hint once the clip is playing on hover */
.card-media--hover.is-playing .play-hint {
  opacity: 0; transform: translateX(-50%) translateY(6px); animation: none;
}
@media (prefers-reduced-motion: reduce) {
  .play-hint { animation: none; }
}
.card-num {
  position: absolute; top: 12px; left: 12px; z-index: 2;
  display: grid; place-items: center;
  width: 26px; height: 26px; border-radius: var(--r-sm);
  background: var(--accent); color: var(--on-accent);
  font-family: var(--font-display);
  font-weight: 800; font-size: 13px; line-height: 1;
  box-shadow: var(--shadow-accent);
}
.card-icon {
  display: grid; place-items: center;
  width: 40px; height: 40px;
  border-radius: var(--r-md);
  background: var(--accent-soft);
  color: var(--accent);
  margin-bottom: 16px;
}
.card h3 {
  font-family: var(--font-display);
  font-size: 17px; font-weight: 700; margin: 0 0 8px;
  letter-spacing: -0.2px;
}
.card p { margin: 0; color: var(--secondary); font-size: 14.5px; }

@media (max-width: 880px) {
  .cards-3 { grid-template-columns: 1fr; }
}

/* ---- feature showcase: alternating copy + framed demo video ----------- */
.features { display: flex; flex-direction: column; gap: 88px; }
.feature {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}
.feature-copy { max-width: 460px; }
.feature--rev .feature-copy { justify-self: end; }
.feature--rev .feature-media { order: -1; }
.feature-kicker {
  display: block; margin-bottom: 12px;
  font-family: var(--font-display);
  font-size: 12px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.15em;
  color: var(--accent);
}
.feature-copy h3 {
  font-family: var(--font-display);
  font-size: clamp(24px, 2.8vw, 31px);
  font-weight: 700; letter-spacing: -0.5px; line-height: 1.12;
  margin: 0 0 14px;
}
.feature-copy > p {
  color: var(--secondary); font-size: 16.5px; line-height: 1.6;
  margin: 0 0 20px;
}
.feature-points { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 11px; }
.feature-points li {
  display: flex; gap: 10px; align-items: start;
  font-size: 14.5px; color: var(--text);
}
.feature-points svg { color: var(--accent); margin-top: 3px; flex: none; }

/* Framed screen: a real-looking device for the demo, with a soft teal wash */
.feature-media { position: relative; }
.feature-media::before {
  content: ""; position: absolute; z-index: 0;
  inset: 4% 6%;
  background: radial-gradient(58% 58% at 50% 45%, var(--accent-soft-strong), transparent 70%);
  filter: blur(48px); opacity: 0.7; pointer-events: none;
}
.frame {
  position: relative; z-index: 1;
  border-radius: var(--r-2xl);
  background: var(--card);
  border: 1px solid var(--separator);
  box-shadow: var(--shadow-card), 0 40px 80px -52px rgba(40, 33, 20, 0.36);
  overflow: hidden;
}
.frame video, .frame img { display: block; width: 100%; height: auto; }

/* Demo frames rest at a slight paper-on-desk tilt and straighten when the
   visitor leans in. Desktop only — the tilt reads as clutter on small cards. */
@media (min-width: 881px) {
  .feature .frame {
    transform: rotate(-0.7deg);
    transition: transform .4s var(--ease);
  }
  .feature--rev .frame { transform: rotate(0.7deg); }
  .feature:hover .frame { transform: rotate(0); }
}

/* Desktop shows the alternating showcases; mobile keeps the tap-to-play card
   grid (it's tighter and more thumb-friendly there). One layout is hidden at
   each width via the toggle below — both stay in the DOM but only one renders. */
@media (max-width: 880px) {
  .features-desktop { display: none; }
}
@media (min-width: 881px) {
  .cards-mobile { display: none; }
}

/* ---- safety band (privacy story, set on a quiet surface) -------------- */
.safety { background: var(--surface-2); }
.safety-inner { max-width: 880px; margin: 0 auto; }
.safety-head { text-align: center; max-width: 620px; margin: 0 auto 44px; }
.safety-head h2 {
  font-family: var(--font-display);
  font-size: clamp(26px, 3vw, 34px);
  font-weight: 700; letter-spacing: -0.5px;
  margin: 0 0 14px;
}
.safety-head p { color: var(--secondary); font-size: 16.5px; line-height: 1.6; margin: 0; }
.safety-points { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px 28px; }

/* Each point is a sticky note pinned at its own slight angle, with a folded
   bottom-right corner. Notes straighten under the cursor. */
.safety-point {
  position: relative;
  display: flex; flex-direction: column; gap: 10px;
  padding: 22px 22px 26px;
  background: var(--note-2);
  border-radius: 2px;
  box-shadow: var(--note-shadow);
  transform: rotate(-1deg);
  transition: transform .3s var(--ease);
}
.safety-point:nth-child(2) { background: var(--note-1); transform: rotate(0.8deg); }
.safety-point:nth-child(3) { background: var(--note-3); transform: rotate(-0.5deg); }
.safety-point:hover { transform: rotate(0); }
.safety-point::after {
  content: ""; position: absolute; right: 0; bottom: 0;
  width: 22px; height: 22px;
  background: linear-gradient(to top left,
    var(--surface-2) 0 50%, var(--note-fold) 50% 58%, transparent 100%);
}
.safety-point .sp-ico {
  display: grid; place-items: center;
  width: 42px; height: 42px;
  border-radius: var(--r-md);
  background: var(--accent-soft); color: var(--accent);
}
.safety-point h3 {
  font-family: var(--font-sans);
  font-size: 15.5px; font-weight: 700; letter-spacing: -0.2px;
  margin: 0;
}
.safety-point p { margin: 0; color: var(--secondary); font-size: 14px; line-height: 1.55; }
@media (max-width: 760px) {
  .safety-points { grid-template-columns: 1fr; gap: 22px; }
  .safety-point { max-width: 420px; }
}

/* ---- closing call to action: dark "chalkboard" panel ------------------ */
.cta-final {
  position: relative; overflow: hidden;
  text-align: center;
  padding: clamp(48px, 7vw, 76px) 32px;
  border-radius: var(--r-2xl);
  background:
    radial-gradient(52% 70% at 50% 0%, rgba(79, 209, 197, 0.13), transparent 72%)
    var(--panel);
  border: 1px solid var(--panel-line);
  color: var(--panel-text);
}
/* faint chalk grain */
.cta-final::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.055;
}
.cta-final > * { position: relative; }
.cta-final h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.4vw, 40px);
  font-weight: 700; letter-spacing: -0.6px;
  margin: 0 0 14px;
}
.cta-final p {
  color: var(--panel-muted); font-size: 17px; line-height: 1.55;
  max-width: 560px; margin: 0 auto 28px;
}
.cta-final .cta-row { justify-content: center; }
.cta-final .btn-ghost {
  color: var(--panel-text);
  border-color: var(--panel-line);
}
.cta-final .btn-ghost:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--panel-muted);
}

/* ---- "how it works" steps -------------------------------------------- */
.steps { display: flex; flex-direction: column; gap: 18px; }
.step {
  position: relative;
  display: grid; grid-template-columns: 44px 1fr; gap: 16px;
  align-items: start;
}
/* dotted thread linking one step's number to the next */
.step::before {
  content: ""; position: absolute; z-index: 0;
  left: 21px; top: 50px; bottom: -24px;
  border-left: 2px dotted var(--border-strong);
}
.step:last-child::before { display: none; }
.step-num {
  position: relative; z-index: 1;
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: var(--r-md);
  background: var(--accent-soft);
  color: var(--accent);
  font-family: var(--font-display);
  font-weight: 800; font-size: 17px;
  letter-spacing: -0.3px;
}
.step h3 {
  margin: 4px 0 6px;
  font-family: var(--font-display);
  font-size: 17px; font-weight: 700; letter-spacing: -0.2px;
}
.step p { margin: 0; color: var(--secondary); font-size: 14.5px; }

/* ---- pricing ---------------------------------------------------------- */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  align-items: stretch;
}
.tier {
  background: var(--card);
  border: 1px solid var(--separator);
  border-radius: var(--r-2xl);
  padding: 28px;
  display: flex; flex-direction: column;
  box-shadow: var(--shadow-card);
  position: relative;
}
.tier.featured {
  border-color: var(--accent);
  box-shadow: var(--shadow-card), 0 0 0 1px var(--accent) inset;
}
.tier-badge {
  position: absolute; top: -10px; left: 24px;
  background: var(--accent); color: var(--on-accent);
  font-size: 11.5px; font-weight: 700; letter-spacing: 0.04em;
  padding: 4px 10px; border-radius: var(--r-pill);
  text-transform: uppercase;
}
.tier-name {
  font-family: var(--font-display);
  font-size: 15px; font-weight: 700;
  color: var(--secondary);
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.tier-price {
  font-family: var(--font-display);
  font-size: 40px; font-weight: 800;
  margin: 14px 0 2px;
  letter-spacing: -1px;
  line-height: 1;
}
.tier-price small {
  font-size: 14px; font-weight: 600;
  color: var(--secondary);
  letter-spacing: 0;
}
.tier-desc {
  color: var(--secondary);
  font-size: 14px;
  margin: 0 0 22px;
}
.tier ul {
  list-style: none; padding: 0; margin: 0 0 28px;
  display: flex; flex-direction: column; gap: 10px;
}
.tier li {
  display: flex; gap: 10px; align-items: start;
  font-size: 14.5px; color: var(--text);
}
.tier li svg { color: var(--accent); margin-top: 3px; }
.tier .btn { margin-top: auto; width: 100%; }

@media (max-width: 880px) {
  .pricing-grid { grid-template-columns: 1fr; }
}

/* ---- FAQ (pricing page) ------------------------------------------------ */
.faq-list {
  max-width: 720px; margin: 0 auto;
  display: flex; flex-direction: column; gap: 10px;
}
.faq-item {
  background: var(--card);
  border: 1px solid var(--separator);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-btn);
  transition: border-color .18s var(--ease);
}
.faq-item[open] { border-color: var(--border-strong); }
.faq-item summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 17px 20px;
  cursor: pointer;
  list-style: none;
  font-size: 15px; font-weight: 700;
  border-radius: var(--r-lg);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: ""; flex: none;
  width: 9px; height: 9px; margin-right: 4px;
  border-right: 2px solid var(--tertiary);
  border-bottom: 2px solid var(--tertiary);
  transform: rotate(45deg) translateY(-2px);
  transition: transform .22s var(--ease);
}
.faq-item[open] summary::after { transform: rotate(225deg) translateY(-2px); }
.faq-item p {
  margin: 0; padding: 0 20px 18px;
  color: var(--secondary); font-size: 14.5px; line-height: 1.65;
}

/* ---- footer ----------------------------------------------------------- */
.footer {
  flex-shrink: 0;
  border-top: 1px solid var(--separator);
  background: var(--surface-2);
  padding: 44px 0 26px;
  margin-top: 72px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 32px 40px;
  padding-bottom: 30px;
  border-bottom: 1px solid var(--separator);
}
.footer-about .brand { display: inline-flex; margin-bottom: 12px; }
.footer-about p {
  margin: 0; max-width: 300px;
  color: var(--secondary); font-size: 13.5px; line-height: 1.6;
}
.footer-col h4 {
  margin: 0 0 12px;
  font-size: 11.5px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--tertiary);
}
.footer-col a {
  display: block;
  padding: 5px 0;
  font-size: 14px; font-weight: 600;
  color: var(--secondary);
  transition: color .18s var(--ease);
}
.footer-col a:hover { color: var(--text); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  gap: 8px 20px; flex-wrap: wrap;
  padding-top: 18px;
  color: var(--tertiary); font-size: 12.5px;
}
@media (max-width: 760px) {
  .footer-grid { grid-template-columns: 1fr; gap: 26px; }
  .footer-bottom { flex-direction: column; text-align: center; }
}

/* ---- legal pages ------------------------------------------------------ */
.legal-wrap {
  max-width: 760px;
  margin: 0 auto;
  padding: 64px 28px 96px;
}
.legal-wrap h1 {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.6vw, 40px);
  font-weight: 800; letter-spacing: -0.6px;
  margin: 0 0 10px;
}
.legal-wrap .muted { color: var(--secondary); font-size: 15px; }
.legal-meta { color: var(--tertiary); font-size: 13px; margin: 0 0 18px; }
.legal-lede {
  color: var(--secondary); font-size: 16px; line-height: 1.65;
  margin: 0 0 4px;
}

.legal-callout {
  margin: 26px 0 4px;
  padding: 20px 22px;
  border: 1px solid var(--border-strong);
  border-left: 3px solid var(--accent);
  border-radius: var(--r-lg);
  background: var(--accent-soft);
}
.legal-callout p { margin: 0; color: var(--secondary); font-size: 14.5px; line-height: 1.65; }
.legal-callout p + p { margin-top: 10px; }
.legal-callout strong { color: var(--text); font-weight: 700; }

.legal-body { margin-top: 8px; }
.legal-body h2 {
  font-family: var(--font-display);
  font-size: 20px; font-weight: 800; letter-spacing: -0.3px;
  margin: 38px 0 12px; scroll-margin-top: 84px;
}
.legal-body h3 { font-size: 15.5px; font-weight: 700; margin: 22px 0 6px; }
.legal-body p { color: var(--secondary); font-size: 15px; line-height: 1.72; margin: 0 0 14px; }
.legal-body ul { margin: 0 0 14px; padding-left: 22px; }
.legal-body li { color: var(--secondary); font-size: 15px; line-height: 1.7; margin-bottom: 7px; }
.legal-body li::marker { color: var(--tertiary); }
.legal-body strong { color: var(--text); font-weight: 700; }
.legal-body a { color: var(--accent); text-decoration: none; }
.legal-body a:hover { text-decoration: underline; }
.legal-body code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.88em; padding: 1px 6px;
  background: var(--input-bg); border-radius: var(--r-xs);
  color: var(--text);
}
.legal-body hr { border: 0; border-top: 1px solid var(--separator); margin: 36px 0; }

/* ---- install page ----------------------------------------------------- */
.install-hero {
  text-align: center;
  padding: 80px 0 40px;
}
.install-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(34px, 4.4vw, 48px);
  font-weight: 800; letter-spacing: -1px;
  margin: 0 0 16px;
}
.install-hero p {
  color: var(--secondary); font-size: 17px;
  max-width: 520px; margin: 0 auto 32px;
}
.notfound-code {
  position: relative;
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 800; font-size: clamp(72px, 14vw, 132px);
  line-height: 1; letter-spacing: -3px;
  color: var(--accent);
  margin-bottom: 8px;
  padding: 0.08em 0.18em;
}
/* teacher's red pen: an ellipse drawn around the mark */
.notfound-circle {
  position: absolute; inset: -8% -6%;
  width: 112%; height: 116%;
  color: var(--danger);
  transform: rotate(-2deg);
  pointer-events: none;
}
.notfound-circle path {
  stroke-dasharray: 1; stroke-dashoffset: 0;
}
@media (prefers-reduced-motion: no-preference) {
  .js .notfound-circle path {
    stroke-dashoffset: 1;
    animation: pen-draw 0.9s var(--ease) 0.35s forwards;
  }
  @keyframes pen-draw { to { stroke-dashoffset: 0; } }
}
.install-steps {
  max-width: 640px; margin: 32px auto 0;
  display: flex; flex-direction: column; gap: 14px;
  text-align: left;
}

/* ---- browser picker (install page) ------------------------------------
   Three tabs — Edge / Chrome / Яндекс — each opening its own store link
   and step-by-step instructions. */
.store-tabs {
  display: flex; flex-wrap: wrap; gap: 10px;
  justify-content: center;
  margin: 4px 0 32px;
}
.store-tab {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 11px 16px;
  border-radius: var(--r-md);
  background: var(--card);
  border: 1px solid var(--border-strong);
  box-shadow: var(--shadow-btn);
  color: var(--text);
  font-size: 14.5px; font-weight: 700;
  cursor: pointer;
  transition: transform .14s var(--ease), border-color .18s var(--ease),
    background .18s var(--ease), box-shadow .18s var(--ease);
}
.store-tab:hover { transform: translateY(-1px); border-color: var(--accent); }
.store-tab.is-active {
  border-color: var(--accent);
  background: var(--accent-soft);
  box-shadow: 0 0 0 1px var(--accent) inset, var(--shadow-btn);
}
.store-logo { flex: none; width: 22px; height: 22px; display: block; }
.store-tag {
  padding: 3px 8px;
  border-radius: var(--r-pill);
  background: var(--hover); color: var(--secondary);
  font-size: 11px; font-weight: 700; letter-spacing: 0.03em;
}
.store-tag--live { background: rgba(76, 175, 110, 0.16); color: var(--green); }

.store-panel { max-width: 620px; margin: 0 auto; }
.panel-cta {
  display: flex; flex-direction: column; align-items: center; gap: 12px;
}
.store-note { margin: 0; max-width: 460px; color: var(--tertiary); font-size: 13px; line-height: 1.55; }
.btn.is-soon { opacity: 0.55; pointer-events: none; user-select: none; }
.store-panel .install-steps { margin-top: 36px; }

@media (max-width: 560px) {
  .store-tab { flex: 1 1 100%; justify-content: center; }
}
