/* Порция — лендинг. Цвета и шрифты взяты из картинки «Итог дня», которую присылает бот. */
@font-face {
  font-family: "TikTok Sans";
  src: url("TikTokSans.woff2") format("woff2");
  font-weight: 300 900;
  font-stretch: 75% 150%;
  font-display: swap;
}
@font-face {
  font-family: "Onest";
  src: url("Onest.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --night: #14102e;
  --dusk: #1f1747;
  --plum: #241c4a;
  --tile: #2f2560;
  --track: #3a2f6b;
  --lilac: #a79fd0;
  --lime: #d4ff3f;
  --paper: #f3f0ff;
  --ink: #1b1140;
  --ink-soft: #4a3f7a;
  --orange: #ffb84d;
  --pink: #ff8fb8;
  --sky: #5cc8ff;
  --violet: #5b2eff;

  --display: "TikTok Sans", "Onest", system-ui, sans-serif;
  --text: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;
  --wrap: 1120px;
  --gutter: clamp(16px, 4vw, 40px);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  /* единый фон на всю страницу: мягкие свечения + плавный переход тёмных оттенков, без полос между блоками */
  background-color: var(--night);
  background-image:
    radial-gradient(620px 420px at 88% 60px, rgba(91, 46, 255, .45), transparent 70%),
    radial-gradient(520px 380px at -5% 640px, rgba(70, 217, 255, .12), transparent 70%),
    radial-gradient(700px 520px at 105% 1500px, rgba(91, 46, 255, .18), transparent 70%),
    linear-gradient(180deg, var(--night) 0, var(--dusk) 900px, var(--night) 2200px, var(--dusk) 70%, var(--night) 100%);
  background-repeat: no-repeat;
  color: #fff;
  font-family: var(--text);
  font-size: 17px;
  line-height: 1.55;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--lime); outline-offset: 3px; border-radius: 6px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- шапка ---------- */
.top {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding-top: 22px; padding-bottom: 22px;
}
.wordmark {
  font-family: var(--display); font-stretch: 125%; font-weight: 800;
  font-size: 22px; letter-spacing: -0.01em; text-decoration: none;
  display: inline-flex; align-items: center; gap: 10px;
}
.wordmark .dot { width: 14px; height: 14px; border-radius: 50%; background: var(--lime);
  box-shadow: 0 0 0 4px rgba(212, 255, 63, .18); }
.top-link { color: var(--lilac); text-decoration: none; font-weight: 500; font-size: 15px; }
.top-link:hover { color: #fff; }

/* ---------- кнопка ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--lime); color: var(--ink);
  font-family: var(--display); font-stretch: 112%; font-weight: 700; font-size: 17px;
  padding: 16px 26px; border-radius: 999px; text-decoration: none;
  transition: transform .15s ease, box-shadow .15s ease;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 8px 24px rgba(212, 255, 63, .25); }
.btn svg { width: 20px; height: 20px; }

/* ---------- первый экран ---------- */
.hero {
  position: relative;
  padding-bottom: clamp(56px, 8vw, 96px);
}
.hero-grid {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  gap: clamp(32px, 5vw, 72px); align-items: center;
  padding-top: clamp(24px, 5vw, 64px);
}
.hero h1 {
  font-family: var(--display); font-stretch: 118%; font-weight: 800;
  font-size: clamp(38px, 6.2vw, 72px); line-height: 1.02; letter-spacing: -0.025em;
  margin: 0 0 24px; text-wrap: balance;
}
.lead { font-size: clamp(17px, 1.6vw, 20px); color: #ddd8f5; max-width: 34em; margin: 0 0 32px; }
.beta-note { margin: 18px 0 0; color: var(--lilac); font-size: 15px; }

/* ---------- чат-демо ---------- */
.chat {
  background: rgba(36, 28, 74, .72);
  border: 1px solid rgba(167, 159, 208, .16);
  border-radius: 28px; padding: 22px;
  display: flex; flex-direction: column; gap: 12px;
  max-width: 440px; justify-self: end; width: 100%;
  backdrop-filter: blur(6px);
}
.chat-head { display: flex; align-items: center; gap: 12px; padding-bottom: 12px;
  border-bottom: 1px solid rgba(167, 159, 208, .14); margin-bottom: 4px; }
.avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--lime);
  display: grid; place-items: center; color: var(--ink);
  font-family: var(--display); font-stretch: 125%; font-weight: 800; font-size: 18px; }
.chat-name { font-weight: 600; line-height: 1.2; }
.chat-name small { display: block; color: var(--lilac); font-weight: 400; font-size: 13px; }

.msg { max-width: 86%; border-radius: 18px; padding: 10px 14px; font-size: 15px; line-height: 1.45; }
.msg.me { align-self: flex-end; background: var(--violet); border-bottom-right-radius: 6px; }
.msg.bot { align-self: flex-start; background: var(--tile); border-bottom-left-radius: 6px; }
.msg.photo { padding: 6px; }
.msg.photo svg { display: block; width: 210px; height: auto; border-radius: 13px; }
.msg.photo span { display: block; padding: 6px 8px 2px; }
.msg b { font-weight: 700; }
.msg ul { list-style: none; padding: 0; margin: 8px 0; }
.msg li { color: #e6e2fa; }
.msg li::before { content: "•  "; color: var(--lilac); }
.msg .bju { color: var(--lilac); }
.msg .day { color: var(--lilac); font-size: 14px; margin-top: 8px; }
.msg .day b { color: var(--lime); font-weight: 600; }
.kbd { display: flex; gap: 6px; margin-top: -4px; max-width: 86%; }
.kbd span { flex: 1; text-align: center; font-size: 13.5px; padding: 8px 10px; border-radius: 12px;
  background: rgba(47, 37, 96, .7); color: #e6e2fa; }

/* ---------- секции ---------- */
section { padding: clamp(44px, 6vw, 80px) 0; }
.h2 {
  font-family: var(--display); font-stretch: 115%; font-weight: 800;
  font-size: clamp(30px, 4.2vw, 48px); line-height: 1.06; letter-spacing: -0.02em;
  margin: 0 0 16px; text-wrap: balance;
}
.sub { color: var(--lilac); max-width: 36em; margin: 0 0 clamp(36px, 5vw, 56px); font-size: 18px; }

/* шаги — это последовательность, поэтому с номерами */
.steps { list-style: none; margin: 0; padding: 0; display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; counter-reset: step; }
.steps li { position: relative; padding: 0 28px 0 0; counter-increment: step; }
.steps li::before {
  content: counter(step);
  display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%;
  background: var(--plum); border: 2px solid var(--track);
  font-family: var(--display); font-stretch: 125%; font-weight: 800; font-size: 22px;
  margin-bottom: 22px; position: relative; z-index: 1;
}
.steps li::after { /* линия между шагами */
  content: ""; position: absolute; top: 26px; left: 52px; right: 0; height: 2px;
  background: repeating-linear-gradient(90deg, var(--track) 0 8px, transparent 8px 14px);
}
.steps li:last-child::after { display: none; }
.steps li:last-child::before { background: var(--lime); border-color: var(--lime); color: var(--ink); }
.steps h3 { font-family: var(--display); font-stretch: 110%; font-weight: 700; font-size: 21px;
  margin: 0 0 8px; line-height: 1.2; }
.steps p { margin: 0; color: #d4cff0; font-size: 16px; }
.steps q { quotes: "«" "»"; color: #fff; }

/* ---------- итог дня ---------- */
.summary-grid { display: grid; grid-template-columns: minmax(0, 460px) minmax(0, 1fr);
  gap: clamp(32px, 6vw, 88px); align-items: center; }
.card-shot { position: relative; }
.card-shot img.shot { border-radius: 26px; box-shadow: 0 30px 80px rgba(5, 2, 20, .6);
  transform: rotate(-2.5deg); }
.card-shot img.sticker { position: absolute; width: 96px; top: -26px; right: -18px; transform: rotate(14deg); }
.callouts { list-style: none; margin: 0; padding: 0; display: grid; gap: 26px; }
.callouts li { display: grid; grid-template-columns: 14px 1fr; gap: 16px; align-items: start; }
.callouts .c { width: 14px; height: 14px; border-radius: 50%; margin-top: 7px; }
.callouts h3 { margin: 0 0 4px; font-size: 19px; font-weight: 650; line-height: 1.3; }
.callouts p { margin: 0; color: var(--lilac); font-size: 16px; }

/* ---------- что умеет ---------- */
.features { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 clamp(32px, 6vw, 80px); margin: 0; }
.features div { padding: 24px 0; border-top: 1px solid rgba(167, 159, 208, .18); }
.features dt { font-family: var(--display); font-stretch: 110%; font-weight: 700; font-size: 20px; margin-bottom: 6px; }
.features dd { margin: 0; color: var(--lilac); }
.features q { quotes: "«" "»"; color: #fff; }

/* вопросы — по центру */
.faq-section .h2 { text-align: center; margin-bottom: clamp(28px, 4vw, 40px); }
.faq { display: grid; gap: 12px; max-width: 780px; margin: 0 auto; }
.faq details { background: rgba(36, 28, 74, .72); border-radius: 18px; padding: 0 22px; border: 1px solid rgba(167, 159, 208, .16); }
.faq summary { cursor: pointer; list-style: none; padding: 20px 32px 20px 0; position: relative;
  font-weight: 650; font-size: 18px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 0; top: 50%; transform: translateY(-52%);
  font-family: var(--display); font-weight: 600; font-size: 26px; color: var(--lime); transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-52%) rotate(45deg); }
.faq details p { margin: 0 0 20px; color: var(--lilac); }
.faq q { quotes: "«" "»"; color: #fff; }
.faq a { color: #fff; }

/* ---------- финальный призыв и подвал ---------- */
.cta { text-align: center; }
/* единственный блок со своей заливкой — карточка в пределах сетки */
.cta-card {
  border-radius: 32px; padding: clamp(40px, 6vw, 72px) clamp(20px, 4vw, 48px);
  background:
    radial-gradient(420px 260px at 85% 0%, rgba(212, 255, 63, .16), transparent 70%),
    linear-gradient(135deg, #4a24d6, #2a1a78);
  border: 1px solid rgba(167, 159, 208, .2);
}
.cta .h2 { margin: 0 auto 28px; max-width: 18em; }
footer { border-top: 1px solid rgba(167, 159, 208, .14); padding: 40px 0 48px; color: var(--lilac); font-size: 15px; }
.foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px 48px; }
.foot p { margin: 0 0 6px; }
.foot a { color: #fff; }
.foot nav { display: grid; gap: 8px; align-content: start; }

/* ---------- юридические страницы ---------- */
.doc-page { background: var(--paper); color: var(--ink); }
.doc-page .top { color: var(--ink); }
.doc-page .top-link { color: var(--ink-soft); }
.doc { max-width: 760px; padding-bottom: 80px; }
.doc h1 { font-family: var(--display); font-stretch: 112%; font-weight: 800;
  font-size: clamp(30px, 4.5vw, 42px); line-height: 1.1; letter-spacing: -0.015em; margin: 24px 0 8px; }
.doc .meta { color: var(--ink-soft); margin: 0 0 36px; }
.doc h2 { font-family: var(--display); font-stretch: 108%; font-weight: 700; font-size: 22px;
  margin: 40px 0 12px; line-height: 1.25; }
.doc p, .doc li { color: #2a2152; }
.doc ul, .doc ol { padding-left: 1.3em; }
.doc li { margin-bottom: 6px; }
.doc a { color: var(--violet); }
.doc table { border-collapse: collapse; width: 100%; font-size: 15.5px; margin: 8px 0 16px; }
.doc th, .doc td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid rgba(27, 17, 64, .12); }
.doc th { font-weight: 650; background: rgba(91, 46, 255, .06); }
.doc .table-scroll { overflow-x: auto; }
.doc .box { background: #fff; border-radius: 16px; padding: 18px 22px; border: 1px solid rgba(27, 17, 64, .08); }
.doc-page footer { border-top-color: rgba(27, 17, 64, .12); color: var(--ink-soft); }
.doc-page footer a { color: var(--ink); }

/* ---------- адаптив ---------- */
@media (max-width: 900px) {
  .hero-grid, .summary-grid { grid-template-columns: 1fr; }
  .chat { justify-self: start; }
  .steps { grid-template-columns: 1fr 1fr; gap: 40px 0; }
  .steps li:nth-child(2)::after { display: none; }
  .card-shot { max-width: 420px; }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  .steps { grid-template-columns: 1fr; gap: 0; }
  .steps li { display: grid; grid-template-columns: 52px 1fr; column-gap: 18px; padding: 0 0 28px; }
  .steps li::before { margin: 0; grid-row: span 2; }
  .steps li::after { top: 52px; bottom: 0; left: 25px; right: auto; width: 2px; height: auto;
    background: repeating-linear-gradient(180deg, var(--track) 0 8px, transparent 8px 14px); }
  .steps li:nth-child(2)::after { display: block; }
  .features { grid-template-columns: 1fr; }
  .msg.photo svg { width: 180px; }
  .card-shot img.sticker { width: 72px; right: -6px; }
  .btn { width: 100%; justify-content: center; }
  .hero h1 { font-stretch: 106%; }
  .top .top-link { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
