/* Главная страница продукта. Опирается на переменные и компоненты app.css. */

html { scroll-behavior: smooth; scroll-padding-top: 64px; }
body.site { background: var(--surface); font-size: 17px; line-height: 1.47; }
.site a { color: var(--link); }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 22px; }
.narrow-wrap { max-width: 640px; }
.center { text-align: center; }

/* тёмный раздел: те же компоненты на чёрном */
.on-dark {
  --bg: #000000; --surface: #1c1c1e; --surface-2: #2c2c2e; --elevated: #2c2c2e; --fill: rgba(120, 120, 128, .24); --fill-2: rgba(120, 120, 128, .36);
  --label: #f5f5f7; --label-2: rgba(235, 235, 245, .62); --label-3: rgba(235, 235, 245, .3); --sep: rgba(84, 84, 88, .6);
  --blue: #0a84ff; --blue-fill: #0071e3; --link: #3d9fff; --green: #30d158; --green-text: #30d158; --red: #ff453a; --red-text: #ff6961;
  --orange: #ff9f0a; --orange-text: #ffb340; --gray: #8e8e93; --gray-3: #48484a; --seg-thumb: #636366;
  background: #000; color: var(--label);
}

/* верхняя панель */
.gnav { position: sticky; top: 0; z-index: 50; height: 52px; background: color-mix(in srgb, var(--surface) 78%, transparent); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); border-bottom: .5px solid transparent; transition: border-color .25s; view-transition-name: gnav; }
.gnav.is-scrolled { border-bottom-color: var(--sep); }
.gnav-in { max-width: 1040px; height: 100%; margin: 0 auto; padding: 0 22px; display: flex; align-items: center; gap: 28px; }
.gnav .logo { color: var(--label); }
.gnav-links { display: none; gap: 28px; margin-left: auto; }
.gnav-links a, .gnav-login { color: var(--label); font-size: 14px; opacity: .82; transition: opacity .15s; }
.gnav-links a:hover, .gnav-login:hover { opacity: 1; }
.gnav-end { display: flex; align-items: center; gap: 16px; margin-left: auto; }
@media (min-width: 860px) { .gnav-links { display: flex; } .gnav-end { margin-left: 0; } }
@media (max-width: 420px) { .gnav .logo-note { display: none; } }

.pill-btn { display: inline-flex; align-items: center; justify-content: center; padding: 7px 15px; border-radius: 980px; background: var(--blue-fill); color: #fff !important; font-size: 14px; line-height: 20px; white-space: nowrap; transition: transform .4s var(--spring), opacity .15s; }
.pill-btn:hover { opacity: .88; }
.pill-btn:active { transform: scale(.95); }
.pill-btn.big { padding: 12px 24px; font-size: 17px; line-height: 22px; }
.more-link { font-size: 17px; }
.more-link::after { content: " ›"; }
.more-link:hover { text-decoration: underline; }

/* первый экран */
.hero-s { padding: 64px 0 0; text-align: center; overflow: hidden; }
.eyebrow { margin: 0 0 10px; font-size: 17px; line-height: 22px; font-weight: 600; color: var(--label-2); }
.display { max-width: 880px; margin: 0 auto; font-size: clamp(38px, 7vw, 76px); line-height: 1.06; font-weight: 700; letter-spacing: -.022em; }
.display span { color: var(--label-2); }
.lead { max-width: 640px; margin: 20px auto 0; font-size: clamp(18px, 2.1vw, 22px); line-height: 1.42; color: var(--label-2); }
.lead.left { margin-left: 0; }
.cta { display: flex; flex-wrap: wrap; gap: 14px 24px; justify-content: center; align-items: center; margin-top: 30px; }
.hero-phone { display: flex; justify-content: center; margin-top: 56px; }
.hero-phone .phone { margin-bottom: -150px; }
@media (min-width: 760px) { .hero-s { padding-top: 96px; } .hero-phone .phone { --s: .86; margin-bottom: -190px; } }

.rise { animation: site-rise 1s var(--ease) both; animation-delay: calc(var(--d, 0) * 90ms + 80ms); }
@keyframes site-rise { from { opacity: 0; transform: translateY(26px); } }

/* разделы */
.sec { padding: 88px 0; }
.sec-gray { background: var(--bg); }
.h2-big { font-size: clamp(32px, 5.2vw, 56px); line-height: 1.08; font-weight: 700; letter-spacing: -.018em; }
.h3-big { font-size: clamp(24px, 3vw, 32px); line-height: 1.15; font-weight: 700; letter-spacing: -.012em; margin-bottom: 20px; }
.split { display: grid; gap: 48px; align-items: center; justify-items: center; }
.split > :first-child { justify-self: stretch; }
@media (min-width: 900px) { .split { grid-template-columns: 1.1fr .9fr; gap: 64px; } .sec { padding: 120px 0; } }
.points { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 18px; }
.points li { padding-left: 16px; border-left: 2px solid var(--blue); font-size: 17px; line-height: 1.42; }
.points b { display: block; font-weight: 600; }
.points span { color: var(--label-2); }
.fine { margin: 28px auto 0; max-width: 640px; text-align: center; font-size: 13px; line-height: 18px; color: var(--label-2); }

/* появление при прокрутке */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s ease, transform 1s var(--ease); }
.reveal[data-d="1"] { transition-delay: .1s; } .reveal[data-d="2"] { transition-delay: .2s; }
.reveal.in { opacity: 1; transform: none; }
.bento .reveal:nth-child(2) { transition-delay: .08s; } .bento .reveal:nth-child(3) { transition-delay: .04s; } .bento .reveal:nth-child(4) { transition-delay: .12s; } .bento .reveal:nth-child(5) { transition-delay: .2s; } .bento .reveal:nth-child(7) { transition-delay: .08s; }

/* телефон */
.phone { --s: .76; flex: none; width: calc(390px * var(--s) + 22px); padding: 11px; border-radius: calc(58px * var(--s) + 8px); background: #1d1d1f; box-shadow: inset 0 0 0 1.500px #48484a, 0 40px 80px -30px rgba(0, 0, 0, .45); }
.on-dark .phone { box-shadow: inset 0 0 0 1.500px #5a5a5e, 0 0 0 1px #000; }
.phone-screen { position: relative; width: calc(390px * var(--s)); height: calc(800px * var(--s)); border-radius: calc(46px * var(--s)); overflow: hidden; background: var(--bg); }
.phone-in { position: relative; width: 390px; height: 800px; transform: scale(var(--s)); transform-origin: 0 0; text-align: left; color: var(--label); font-size: 17px; line-height: 1.3; overflow: hidden; }
.island { position: absolute; top: calc(11px * var(--s)); left: 50%; z-index: 5; width: calc(112px * var(--s)); height: calc(32px * var(--s)); border-radius: 20px; background: #000; transform: translateX(-50%); }
.m-pad { padding: 58px 16px 0; }
.m-title { font-size: 34px; line-height: 41px; font-weight: 700; margin: 0 0 14px; }
.m-title.sm { font-size: 28px; line-height: 34px; margin-top: 8px; }
.m-pad .kicker { display: block; }
.m-pad .section-title { margin-top: 22px; }
.m-pad .section-title h2 { font-size: 20px; line-height: 25px; }
.m-tabbar { position: absolute; left: 0; right: 0; bottom: 0; display: flex; padding: 0 2px 18px; background: var(--tabbar); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-top: .5px solid var(--sep); }
.phone .btn, .phone .tab-item { pointer-events: none; }
.phone .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 380px) { .phone { --s: .7; } }

/* живая демонстрация итога урока */
.demo { position: relative; height: 100%; }
.demo-stage { position: absolute; left: 16px; right: 16px; top: 190px; bottom: 34px; display: flex; flex-direction: column; opacity: 0; transform: translateY(18px) scale(.98); transition: opacity .45s ease, transform .7s var(--ease); pointer-events: none; }
.demo[data-state="rec"] .demo-rec, .demo[data-state="think"] .demo-rec, .demo[data-state="review"] .demo-review, .demo[data-state="done"] .demo-done { opacity: 1; transform: none; }
.demo .rec { padding: 20px 16px 18px; margin-bottom: 12px; }
.demo .rec-time { font-size: 38px; line-height: 44px; margin-bottom: 10px; }
.demo .rec-btn { width: 60px; height: 60px; }
.demo .rec-btn::before { width: 22px; height: 22px; border-radius: 6px; }
.demo-text { flex: 1; min-height: 118px; margin-bottom: 14px; font-size: 21px; line-height: 29px; letter-spacing: -.01em; }
.demo-text p { margin: 0; }
.demo-text p::after { content: ""; display: inline-block; width: 2px; height: 23px; margin-left: 2px; vertical-align: -4px; background: var(--blue); animation: caret 1s steps(1) infinite; }
@keyframes caret { 50% { opacity: 0; } }
.demo-progress { margin: 0; opacity: 0; transition: opacity .3s; }
.demo[data-state="think"] .demo-progress { opacity: 1; }
.demo[data-state="think"] .rec-wave i { animation: none; height: 4px; background: var(--gray-3); }
.demo[data-state="think"] .rec-btn::before { width: 46px; height: 46px; border-radius: 23px; }
.demo[data-state="think"] .demo-text p::after { display: none; }
/* без диктовки: первый шаг — заметка текстом и кнопка разбора, как на настоящем экране итога */
.demo-typed .demo-text { flex: none; min-height: 236px; }
.demo-typed .demo-rec .btn { transition: transform .4s var(--spring), opacity .3s ease; }
.demo-typed[data-state="rec"].is-pressing .demo-rec .btn:not(.btn-ghost) { transform: scale(.95); opacity: .75; }
.demo-typed[data-state="think"] .demo-rec .btn { opacity: .4; }
.demo-typed .demo-progress { margin: 14px 0 2px; }
.demo-review .card { margin-bottom: 10px; padding: 14px 16px; opacity: 0; transform: translateY(14px); transition: opacity .5s ease, transform .7s var(--ease); }
.demo-review .rs-head { margin-bottom: 10px; }
.demo-review .rs-head h2 { font-size: 17px; line-height: 22px; }
.demo-review .kv dt, .demo-review .kv dd { padding: 7px 0; font-size: 15px; line-height: 20px; }
.demo-review .btn { margin-top: auto; opacity: 0; transition: opacity .5s ease .5s, transform .4s var(--spring); }
.demo[data-state="review"] .demo-review .card { opacity: 1; transform: none; }
.demo[data-state="review"] .demo-review .card:nth-child(2) { transition-delay: .12s; } .demo[data-state="review"] .demo-review .card:nth-child(3) { transition-delay: .24s; }
.demo[data-state="review"] .demo-review .btn { opacity: 1; }
.demo[data-state="review"].is-pressing .demo-review .btn { transform: scale(.95); opacity: .75; transition-delay: 0s; }
.demo-done { justify-content: center; padding-bottom: 70px; }
.demo .success-ico, .demo .success-ico .ico { animation: none; }
.demo .success-ico .ico { stroke-dashoffset: 24; }
.demo[data-state="done"] .success-ico { animation: pop .7s var(--spring) both; }
.demo[data-state="done"] .success-ico .ico { animation: draw .45s .3s ease-out forwards; }
.demo-wrap { justify-self: center; }

/* кому: переключатель и панели */
.aud { margin-top: 36px; }
.aud-seg { max-width: 420px; margin: 0 auto 44px; }
.aud-seg span { min-height: 36px; }
.aud-panel { display: none; }
.aud:has(#aud-t:checked) .aud-t, .aud:has(#aud-s:checked) .aud-s, .aud:has(#aud-p:checked) .aud-p { display: grid; animation: aud-in .7s var(--ease) both; }
@keyframes aud-in { from { opacity: 0; transform: translateY(18px); } }

/* возможности */
.bento { display: grid; gap: 16px; margin-top: 48px; }
.tile-b { padding: 28px; border-radius: 22px; background: var(--surface); }
.tile-b h3 { margin: 18px 0 6px; font-size: 21px; line-height: 26px; font-weight: 600; }
.tile-b p { margin: 0; color: var(--label-2); font-size: 17px; line-height: 1.42; }
@media (min-width: 760px) { .bento { grid-template-columns: repeat(6, minmax(0, 1fr)); } .tile-b { grid-column: span 2; } .tile-b.wide { grid-column: span 3; } }
.row-ico.big { width: 44px; height: 44px; border-radius: 10px; }
.row-ico.big .ico { width: 26px; height: 26px; }
.trio { display: grid; gap: 36px; margin-top: 48px; }
.trio h3 { margin: 16px 0 6px; font-size: 21px; line-height: 26px; font-weight: 600; }
.trio p { margin: 0; color: var(--label-2); }
@media (min-width: 760px) { .trio { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* заявка и вопросы */
.access-form { margin-top: 36px; padding: 24px; border-radius: 22px; }
.access-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.access-form > .field-error { margin: -4px 2px 14px; font-size: 15px; line-height: 20px; }
#access .success { margin-top: 36px; border-radius: 22px; }
.faqs { margin-top: 36px; border-top: .5px solid var(--sep); }
.faq { border-bottom: .5px solid var(--sep); interpolate-size: allow-keywords; }
.faq summary { list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 20px 2px; font-size: 19px; line-height: 24px; font-weight: 600; cursor: pointer; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 10px; height: 10px; border: 2px solid var(--label-2); border-top: 0; border-left: 0; transform: rotate(45deg) translate(-3px, -3px); transition: transform .35s var(--ease); }
.faq[open] summary::after { transform: rotate(-135deg) translate(-3px, -3px); }
.faq p { margin: 0; padding: 0 2px 22px; max-width: 58ch; color: var(--label-2); }
.faq::details-content { block-size: 0; overflow: clip; transition: block-size .45s var(--ease), content-visibility .45s allow-discrete; }
.faq[open]::details-content { block-size: auto; }

.foot { padding: 28px 0 40px; border-top: .5px solid var(--sep); font-size: 13px; color: var(--label-2); }
.foot-in { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; }
.foot-links { display: flex; gap: 20px; }

@media (prefers-reduced-motion: reduce) { .reveal, .rise { opacity: 1 !important; transform: none !important; } html { scroll-behavior: auto; } }
