/* Лендинг «Сетка». Токены, кнопки, плитки, светофор, графики и диалог - из styles.css; здесь только раскладка страницы. */

html { scroll-behavior: smooth; scroll-padding-top: 76px; }
.landing { font-size: 16px; line-height: 1.55; }
.landing p { color: var(--text-2); }

.l-wrap { width: min(1160px, 100% - 48px); margin-inline: auto; }

/* ---------- Шапка ---------- */
.l-header {
  position: sticky; top: 0; z-index: 30;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--border);
}
.l-header__in { display: flex; align-items: center; gap: var(--sp-6); min-height: 64px; }
.l-header .brand { color: var(--text); text-decoration: none; }
.l-nav { display: flex; gap: var(--sp-5); margin-left: var(--sp-4); }
.l-nav a { color: var(--text-2); text-decoration: none; font-size: 14px; font-weight: 550; padding: 6px 0; }
.l-nav a:hover { color: var(--text); }
.l-header__actions { margin-left: auto; display: flex; align-items: center; gap: var(--sp-2); }
.l-header__actions .btn { text-decoration: none; }

.btn--lg { height: 48px; padding: 0 22px; font-size: 15px; font-weight: 600; border-radius: var(--r-md); text-decoration: none; }

/* ---------- Первый экран ---------- */
.l-hero { position: relative; padding: 84px 0 44px; text-align: center; overflow: hidden; }
/* горизонтальные линии - уровни сетки */
.l-hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(var(--border) 1px, transparent 1px);
  background-size: 100% 46px;
  -webkit-mask-image: radial-gradient(ellipse 75% 90% at 50% 0%, #000 20%, transparent 72%);
  mask-image: radial-gradient(ellipse 75% 90% at 50% 0%, #000 20%, transparent 72%);
}
.l-hero > .l-wrap { position: relative; }
.l-eyebrow { margin: 0 0 var(--sp-3); font-size: 13px; font-weight: 650; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent-ink) !important; }
.l-hero__title {
  max-width: 880px; margin: 0 auto;
  font-size: clamp(34px, 5.4vw, 60px); line-height: 1.06; font-weight: 700; letter-spacing: -0.028em;
  text-wrap: balance;
}
.l-hero__lead { max-width: 700px; margin: var(--sp-5) auto 0; font-size: clamp(16px, 1.6vw, 19px); text-wrap: pretty; }
.l-hero__cta { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-3); margin-top: var(--sp-8); }
.l-hero__facts { list-style: none; margin: var(--sp-6) 0 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-2) var(--sp-6); font-size: 14px; color: var(--text-2); }
.l-hero__facts li { display: inline-flex; align-items: center; gap: 6px; }
.l-hero__facts .icon { color: var(--ok-ink); }

/* ---------- Живой пример ---------- */
.l-demo-section { padding: 0 0 72px; }
.l-demo { border: 1px solid var(--border-strong); border-radius: 18px; background: var(--surface); box-shadow: var(--shadow-pop); overflow: hidden; text-align: left; }
.l-demo__bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-2) var(--sp-5); padding: var(--sp-3) var(--sp-5); background: var(--surface-2); border-bottom: 1px solid var(--border); }
.l-demo__title { display: inline-flex; align-items: center; gap: var(--sp-2); font-size: 14px; font-weight: 650; }
.l-live-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 0 color-mix(in srgb, var(--ok) 60%, transparent); animation: l-pulse 2.2s ease-out infinite; }
.l-live-dot.is-off { background: var(--text-3); animation: none; }
@keyframes l-pulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--ok) 55%, transparent); } 70%, 100% { box-shadow: 0 0 0 8px transparent; } }
.l-demo__ticker { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px var(--sp-3); font-size: 13px; color: var(--text-2); }
.l-demo__ticker b { font-size: 18px; font-weight: 650; color: var(--text); letter-spacing: -0.01em; }
.l-demo__body { display: grid; grid-template-columns: 312px minmax(0, 1fr); }
.l-demo__controls { display: grid; align-content: start; gap: var(--sp-5); padding: var(--sp-5); border-right: 1px solid var(--border); background: color-mix(in srgb, var(--surface-2) 55%, var(--surface)); }
.l-demo__controls .field + .field { margin-top: 0; }
.l-demo__controls .field__label b { color: var(--text); font-weight: 700; }
.l-demo__range { font-size: 13px; color: var(--text-3); margin-top: 2px; }
.l-demo__range b { color: var(--text-2); font-weight: 600; }
.l-demo__note { font-size: 13px; color: var(--text-3) !important; line-height: 1.45; }
.l-demo__result { display: grid; align-content: start; gap: var(--sp-4); padding: var(--sp-5); min-width: 0; }
.l-demo__result .status { box-shadow: none; }
.l-demo__result .kpi { box-shadow: none; }
#demo-chart { --chart-h: 300px; min-width: 0; }
#demo-equity { --chart-h: 230px; min-width: 0; }
.l-demo__caption { margin-top: var(--sp-4); text-align: center; font-size: 13px; color: var(--text-3) !important; }

/* ---------- Секции ---------- */
.l-section { padding: 92px 0; }
.l-section--alt { background: var(--surface); border-block: 1px solid var(--border); }
.l-head { max-width: 760px; margin-bottom: var(--sp-8); }
.l-head--center { margin-inline: auto; text-align: center; }
.l-h2 { font-size: clamp(26px, 3.4vw, 40px); line-height: 1.12; font-weight: 700; letter-spacing: -0.022em; text-wrap: balance; }
.l-h3 { font-size: 18px; line-height: 1.25; font-weight: 650; letter-spacing: -0.01em; }
.l-lead { margin-top: var(--sp-4); font-size: 17px; text-wrap: pretty; }
.l-fine { font-size: 13px; line-height: 1.5; color: var(--text-3) !important; max-width: 900px; }

.l-card { display: grid; align-content: start; gap: var(--sp-3); padding: var(--sp-6); border: 1px solid var(--border); border-radius: var(--r-lg); background: var(--surface); box-shadow: var(--shadow-1); min-width: 0; }
.l-card p { font-size: 15px; }
.l-ico { display: grid; place-items: center; width: 40px; height: 40px; border-radius: var(--r-md); background: var(--accent-soft); color: var(--accent-ink); flex: none; }
.l-ico .icon { width: 20px; height: 20px; }

.l-live { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--sp-5); margin-bottom: var(--sp-5); }
.l-card--live { gap: var(--sp-4); }
.l-card__head { display: flex; gap: var(--sp-4); align-items: flex-start; }
.l-card__head p { margin-top: 6px; }
.l-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--sp-3); }
.l-stat { padding: var(--sp-3); border-radius: var(--r-md); background: var(--surface-2); min-width: 0; }
.l-stat__label { font-size: 12px; font-weight: 550; color: var(--text-3); }
.l-stat__value { font-size: 22px; font-weight: 650; letter-spacing: -0.015em; white-space: nowrap; font-variant-numeric: normal; }
.l-stat__sub { font-size: 12px; color: var(--text-3); }
.l-heat { overflow-x: auto; min-width: 0; padding: 2px; scrollbar-width: thin; }
.l-heat .heat { min-width: 430px; grid-auto-rows: 34px; }
.l-heat .heat-cell { min-width: 0; font-size: 11px; padding: 0; }
.l-heat .heat-axis { font-size: 11px; padding-right: 6px; }
.l-heat .heat-axis.is-corner { font-size: 10px; }
.l-card--live .past-note { margin: 0; font-size: 13px; }

.l-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--sp-5); }

/* ---------- Биржи ---------- */
.l-ex { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--sp-4); margin-bottom: var(--sp-6); }
.l-exc { display: grid; gap: var(--sp-3); padding: var(--sp-5); border: 1px solid var(--border); border-radius: var(--r-lg); background: var(--bg); min-width: 0; }
.l-exc__name { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-2); font-size: 20px; font-weight: 700; letter-spacing: -0.015em; }
.l-exc__live { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 550; color: var(--text-3); letter-spacing: 0; white-space: nowrap; }
.l-exc__live i { width: 7px; height: 7px; border-radius: 50%; background: var(--lamp-off); }
.l-exc__live.is-ok i { background: var(--ok); }
.l-exc__live.is-bad i { background: var(--bad); }
.l-exc dl { display: grid; gap: var(--sp-2); margin: 0; }
.l-exc dl > div { display: flex; justify-content: space-between; align-items: baseline; gap: var(--sp-3); padding-top: var(--sp-2); border-top: 1px solid var(--border); }
.l-exc dt { font-size: 13px; color: var(--text-3); }
.l-exc dd { margin: 0; font-size: 15px; font-weight: 650; white-space: nowrap; }
.l-exc__note { font-size: 12px; color: var(--text-3) !important; min-height: 2.9em; }

/* ---------- Шаги и границы ---------- */
.l-steps { list-style: none; margin: 0 0 var(--sp-8); padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--sp-5); counter-reset: step; }
.l-step { position: relative; display: grid; align-content: start; gap: var(--sp-2); padding-top: var(--sp-5); border-top: 2px solid var(--border-strong); }
.l-step__n { position: absolute; top: -15px; left: 0; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--accent); color: var(--on-accent); font-size: 14px; font-weight: 700; }
.l-step p { font-size: 15px; }

.l-honest { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--sp-5); padding: var(--sp-6); border: 1px solid var(--border); border-radius: var(--r-lg); background: var(--surface); }
.l-list { list-style: none; margin: var(--sp-3) 0 0; padding: 0; display: grid; gap: var(--sp-2); font-size: 15px; color: var(--text-2); }
.l-list li { display: flex; gap: var(--sp-2); align-items: flex-start; }
.l-list .icon { margin-top: 4px; }
.l-list--ok .icon { color: var(--ok-ink); }
.l-list--soon .icon { color: var(--warn-ink); }
.l-list--no .icon { color: var(--text-3); }

/* ---------- Тарифы ---------- */
.l-plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--sp-5); align-items: stretch; max-width: 1000px; margin-inline: auto; }
.l-plan { position: relative; display: grid; grid-template-rows: auto auto auto 1fr auto; gap: var(--sp-3); padding: var(--sp-6); border: 1px solid var(--border-strong); border-radius: var(--r-lg); background: var(--bg); min-width: 0; }
.l-plan.is-featured { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), var(--shadow-2); background: var(--surface); }
.l-plan__tag { position: absolute; top: -11px; left: var(--sp-6); padding: 2px 10px; border-radius: var(--r-pill); background: var(--accent); color: var(--on-accent); font-size: 12px; font-weight: 650; }
.l-plan__name { font-size: 16px; font-weight: 650; color: var(--text-2); }
.l-plan__price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 8px; font-size: 40px; font-weight: 700; letter-spacing: -0.03em; line-height: 1; font-variant-numeric: normal; }
.l-plan__price small { font-size: 15px; font-weight: 500; color: var(--text-3); letter-spacing: 0; }
.l-plan__note { font-size: 14px; min-height: 3em; }
.l-plan__save { font-size: 13px; font-weight: 600; color: var(--ok-ink) !important; min-height: 0; }
.l-plan .l-list { margin-top: 0; font-size: 14px; align-content: start; }
.l-service { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-3) var(--sp-6); max-width: 1000px; margin: var(--sp-5) auto 0; padding: var(--sp-5) var(--sp-6); border: 1px dashed var(--border-strong); border-radius: var(--r-lg); }
.l-service p { font-size: 14px; max-width: 640px; margin-top: 4px; }
.l-service__price { font-size: 15px; font-weight: 650; color: var(--text-2); white-space: nowrap; }

/* ---------- Вопросы ---------- */
.l-faq-wrap { max-width: 860px; }
.l-faq { border-top: 1px solid var(--border-strong); }
.l-q { border-bottom: 1px solid var(--border-strong); }
.l-q summary { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4); padding: var(--sp-5) 0; font-size: 18px; font-weight: 600; cursor: pointer; list-style: none; }
.l-q summary::-webkit-details-marker { display: none; }
.l-q summary .icon { width: 20px; height: 20px; color: var(--text-3); transition: transform var(--t-fast); }
.l-q[open] summary .icon { transform: rotate(45deg); }
.l-q p { padding: 0 var(--sp-8) var(--sp-5) 0; }

/* ---------- Призыв и подвал ---------- */
.l-cta-section { padding: 0 0 92px; }
.l-cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--sp-5) var(--sp-8); padding: 44px 48px; border-radius: 22px; background: var(--accent); color: #fff; }
.l-cta .l-h2 { color: #fff; }
.l-cta p { margin-top: var(--sp-2); color: rgba(255, 255, 255, 0.86); font-size: 17px; }
.l-cta__btn { background: #fff; border-color: #fff; color: #17447e; }
.l-cta__btn:hover { background: #eef4fc; border-color: #eef4fc; }
.l-footer { padding: var(--sp-8) 0 48px; border-top: 1px solid var(--border); }
.l-footer__in { display: grid; gap: var(--sp-4); }
.l-footer__nav { display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-5); font-size: 14px; }
.l-footer__nav a { color: var(--text-2); text-decoration: none; }
.l-footer__nav a:hover { color: var(--text); text-decoration: underline; }

.l-textarea { height: auto; padding-block: 8px; resize: vertical; min-height: 72px; }
.l-done { display: grid; justify-items: center; gap: var(--sp-3); padding: var(--sp-6) 0 var(--sp-4); text-align: center; }
.l-done .l-ico { background: var(--ok-soft); color: var(--ok-ink); }
.l-done b { font-size: 18px; color: var(--text); }

/* ---------- Страница входа и текстовые страницы ---------- */
.l-auth { min-height: 100dvh; display: grid; }
.l-auth__main { position: relative; display: grid; align-content: center; justify-items: center; gap: var(--sp-5); padding: var(--sp-8) var(--sp-4); }
.l-auth__main::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(var(--border) 1px, transparent 1px); background-size: 100% 46px;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 10%, transparent 70%);
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, #000 10%, transparent 70%);
}
.l-auth__main > * { position: relative; }
.l-auth__brand { color: var(--text); text-decoration: none; font-size: 20px; }
.l-auth__card { display: grid; gap: var(--sp-4); width: min(400px, 100%); padding: var(--sp-8) var(--sp-6) var(--sp-6); border: 1px solid var(--border-strong); border-radius: 18px; background: var(--surface); box-shadow: var(--shadow-pop); }
.l-auth__card .field + .field { margin-top: 0; }
.l-auth__card .input { height: 44px; font-size: 16px; }
.l-auth__title { font-size: 22px; }
.l-auth__lead { margin-top: -8px; font-size: 14px; }
.l-auth__msg { min-height: 20px; color: var(--bad-ink); font-size: 14px; }
.l-auth__foot { font-size: 14px; }
.l-auth__foot a { display: inline-flex; align-items: center; gap: 4px; }

.l-doc { max-width: 760px; padding: 56px 0 72px; display: grid; gap: var(--sp-3); }
.l-doc .l-h3 { margin-top: var(--sp-5); }
.l-doc ul { margin: 0; padding-left: 20px; display: grid; gap: var(--sp-2); color: var(--text-2); }
.l-doc b { color: var(--text); font-weight: 600; }

/* ---------- Появление при прокрутке ---------- */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.5s ease, transform 0.5s ease; }
.js .reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .l-live-dot { animation: none; }
}

/* ---------- Адаптив ---------- */
@media (max-width: 1040px) {
  .l-live { grid-template-columns: 1fr; }
  .l-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .l-ex { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .l-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: var(--sp-8); }
}
@media (max-width: 900px) {
  .l-nav { display: none; }
  .l-demo__body { grid-template-columns: 1fr; }
  .l-demo__controls { border-right: 0; border-bottom: 1px solid var(--border); }
  .l-honest { grid-template-columns: 1fr; }
  .l-plans { grid-template-columns: 1fr; max-width: 460px; }
  .l-section { padding: 68px 0; }
  .l-hero { padding-top: 60px; }
}
@media (max-width: 560px) {
  .l-wrap { width: calc(100% - 32px); }
  .l-login { display: none; }
  .l-cards, .l-ex, .l-steps { grid-template-columns: 1fr; }
  .l-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .l-hero__cta .btn { flex: 1 1 100%; }
  .l-demo { border-radius: 14px; }
  .l-demo__controls, .l-demo__result { padding: var(--sp-4); }
  #demo-chart { --chart-h: 240px; }
  .l-card { padding: var(--sp-5); }
  .l-cta { padding: 32px 24px; border-radius: 18px; }
  .l-cta__btn { width: 100%; }
  .l-q summary { font-size: 16px; }
  .l-q p { padding-right: 0; }
  .l-section { padding: 56px 0; }
}
