/* Layout: «письмо автора» — левый столбец для чтения (~62ch) и поле справа под фото и заметки.
   Мотив из логотипа: скошенный параллелограмм (маркер секций) и срезанные углы (рамки фото). */
:root {
  --paper: #fcfbfa;          /* фон: почти белый с лёгким тёплым смещением к красному */
  --paper-2: #f5f2f0;        /* вторичная поверхность */
  --ink: #1d1a19;            /* основной текст */
  --ink-2: #5f5856;          /* второстепенный текст */
  --line: #e7e1de;           /* разделители, рамки */
  --red: #e2140c;            /* акцент — яркий красный логотипа, чуть приглушён для текста */
  --red-deep: #ad1404;       /* тёмный красный логотипа */
  --red-wash: #fbeceb;       /* очень светлая заливка акцента */
  --on-red: #ffffff;
  --font-display: "Literata", "PT Serif", Georgia, "Times New Roman", serif;
  --font-body: "Onest", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;
  --step--1: 0.875rem; --step-0: 1.0625rem; --step-1: 1.25rem; --step-2: 1.625rem; --step-3: 2.25rem; --step-4: clamp(2.25rem, 4.6vw, 3.5rem);
  --radius: 4px;
  --cut: 18px;               /* срез углов, как у логотипа */
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #141211; --paper-2: #1c1918; --ink: #eee9e7; --ink-2: #a79f9c; --line: #2d2826;
    --red: #ff4136; --red-deep: #d8261a; --red-wash: #2a1513; --on-red: #ffffff; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #141211; --paper-2: #1c1918; --ink: #eee9e7; --ink-2: #a79f9c; --line: #2d2826;
  --red: #ff4136; --red-deep: #d8261a; --red-wash: #2a1513; --on-red: #ffffff; color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body { margin: 0; }
img { max-width: 100%; }
[hidden] { display: none !important; }
body { background: var(--paper); color: var(--ink); font-family: var(--font-body); font-size: var(--step-0); line-height: 1.6; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 500; line-height: 1.15; text-wrap: balance; margin: 0; letter-spacing: -0.01em; }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }

.wrap { width: 100%; max-width: 1160px; margin-inline: auto; padding-inline: 24px; }
@media (max-width: 520px) { .wrap { padding-inline: 16px; } }

/* ---------- header ---------- */
.top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 10; background: color-mix(in srgb, var(--paper) 88%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.top .wrap { display: flex; align-items: center; gap: 24px; padding-block: 14px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--font-display); font-size: 1.3rem; font-weight: 600; letter-spacing: -0.01em; }
.brand img { width: 34px; height: auto; display: block; }
.nav { display: flex; gap: 22px; margin-left: auto; font-size: var(--step--1); color: var(--ink-2); }
.nav a { text-decoration: none; }
.nav a:hover { color: var(--ink); }
.top-actions { display: flex; gap: 10px; align-items: center; }
@media (max-width: 760px) { .nav { display: none; } .top-actions { margin-left: auto; } }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding-inline: 18px; border-radius: var(--radius); font: 500 var(--step--1)/1 var(--font-body); text-decoration: none; border: 1px solid transparent; cursor: pointer; transition: background-color .15s, border-color .15s, color .15s; white-space: nowrap; }
.btn-primary { background: var(--red); color: var(--on-red); }
.btn-primary:hover { background: var(--red-deep); }
.btn-ghost { border-color: var(--line); color: var(--ink); background: transparent; }
.btn-ghost:hover { border-color: var(--ink-2); }
.btn-link { padding-inline: 4px; color: var(--ink-2); }
.btn-link:hover { color: var(--ink); }
.btn[disabled] { opacity: .55; cursor: not-allowed; }

/* ---------- общие элементы секций ---------- */
section { padding-block: clamp(56px, 8vw, 104px); }
section + section { border-top: 1px solid var(--line); }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: 0.78rem; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }
/* скошенный маркер из формы логотипа */
.eyebrow::before { content: ""; width: 14px; height: 9px; background: var(--red); transform: skewX(-38deg); flex: none; }
.lead { font-size: var(--step-1); color: var(--ink-2); line-height: 1.55; max-width: 34em; }
.prose { display: grid; gap: 1.1em; max-width: 62ch; }
.prose p { color: var(--ink); }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.82fr); gap: clamp(32px, 6vw, 88px); align-items: start; }
@media (max-width: 880px) { .split { grid-template-columns: minmax(0, 1fr); } }
.stack { display: grid; gap: 22px; }

/* ---------- фото ---------- */
.photo { position: relative; margin: 0; }
.photo .frame { position: relative; aspect-ratio: 4 / 5; max-width: 100%; overflow: hidden; background: var(--paper-2);
  clip-path: polygon(var(--cut) 0, 100% 0, 100% calc(100% - var(--cut)), calc(100% - var(--cut)) 100%, 0 100%, 0 var(--cut)); }
.photo.wide .frame { aspect-ratio: 3 / 2; }
.photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: saturate(.85); }
.photo .fallback { position: absolute; inset: 0; display: none; place-content: start end; text-align: right; padding: 18px; gap: 4px; color: var(--ink-2); font-size: var(--step--1);
  background: repeating-linear-gradient(135deg, transparent 0 14px, color-mix(in srgb, var(--line) 70%, transparent) 14px 15px), var(--paper-2); }
.photo .fallback b { font-weight: 500; color: var(--ink); }
.photo.is-missing img { display: none; }
.photo.is-missing .fallback { display: grid; }
.photo figcaption { margin-top: 10px; font-size: 0.78rem; color: var(--ink-2); }
.photo figcaption a { text-decoration-color: var(--line); text-underline-offset: 2px; }

/* ---------- цитаты на фото ---------- */
.quote { position: absolute; left: 16px; right: 16px; bottom: 16px; margin: 0; padding: 16px 18px 14px; display: grid; gap: 10px;
  background: color-mix(in srgb, var(--paper) 86%, transparent); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border-left: 2px solid var(--red); box-shadow: 0 12px 32px -20px rgb(0 0 0 / .45); }
.quote p { font-family: var(--font-display); font-style: italic; font-size: var(--step-1); line-height: 1.32; text-wrap: balance; }
.hero .quote p { font-size: var(--step-2); }
.quote .src { display: grid; gap: 2px; font-size: 0.8rem; line-height: 1.4; color: var(--ink-2); }
.quote cite { font-style: normal; font-weight: 600; color: var(--ink); }
@media (max-width: 880px) {
  .quote { position: static; margin-top: 12px; background: var(--paper-2); backdrop-filter: none; -webkit-backdrop-filter: none; box-shadow: none; }
}

/* ---------- hero ---------- */
.hero { padding-block: clamp(40px, 7vw, 96px) clamp(56px, 8vw, 104px); }
.hero h1 { font-size: var(--step-4); margin-top: 18px; max-width: 13em; }
.hero h1 em { font-style: italic; color: var(--red); font-weight: 400; }
.hero .lead { margin-top: 22px; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero .facts { display: flex; flex-wrap: wrap; gap: 10px 28px; margin-top: 40px; padding: 0; list-style: none; font-size: var(--step--1); color: var(--ink-2); }
.hero .facts li { display: flex; align-items: center; gap: 8px; }
.hero .facts li::before { content: ""; width: 6px; height: 6px; background: var(--red); transform: skewX(-38deg); }
.hero .photo .frame { aspect-ratio: 4 / 4.6; }
@media (max-width: 880px) { .hero .photo .frame { aspect-ratio: 3 / 2; } }

/* ---------- кому подойдёт ---------- */
.fit { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 40px; }
@media (max-width: 720px) { .fit { grid-template-columns: minmax(0, 1fr); } }
.fit-card { padding: 28px; border: 1px solid var(--line); display: grid; gap: 12px; align-content: start; }
.fit-card h3 { font-size: var(--step-2); }
.fit-card p { color: var(--ink-2); }
.fit-card .tag { font-family: var(--font-mono); font-size: 0.75rem; color: var(--ink-2); }
.fit-card.yes { border-color: color-mix(in srgb, var(--red) 45%, var(--line)); background: var(--red-wash); }
.fit-card.yes .tag { color: var(--red); }
.accounts { display: flex; gap: 6px; }
.accounts span { width: 30px; height: 20px; border: 1.5px solid var(--ink-2); border-radius: 2px; }
.fit-card.yes .accounts span { border-color: var(--red); }

/* ---------- excel ---------- */
.sheet { margin-top: 8px; border: 1px solid var(--line); background: var(--paper); font-family: var(--font-mono); font-size: 0.8rem; overflow-x: auto; }
.sheet .bar { display: flex; gap: 0; border-bottom: 1px solid var(--line); min-width: 560px; }
.sheet .bar .cell { padding: 8px 12px; border-right: 1px solid var(--line); color: var(--ink-2); }
.sheet .bar .fx { font-style: italic; color: var(--ink-2); }
.sheet .bar .formula { padding: 8px 12px; color: var(--ink); white-space: nowrap; }
.sheet .formula .fn { color: var(--red); }
.sheet-cap { font-size: var(--step--1); color: var(--ink-2); }
.pains { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.pains li { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 10px; }
.pains li::before { content: "?"; font-family: var(--font-display); font-style: italic; color: var(--red); font-size: 1.2rem; line-height: 1.3; }
.conclusion { font-family: var(--font-display); font-size: var(--step-2); line-height: 1.3; padding-left: 20px; border-left: 2px solid var(--red); max-width: 26em; }

/* ---------- возможности ---------- */
.features { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin-top: 44px; border-top: 1px solid var(--line); }
@media (max-width: 980px) { .features { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .features { grid-template-columns: minmax(0, 1fr); } }
.feature { padding: 26px 24px 8px 0; display: grid; gap: 10px; align-content: start; }
.feature + .feature { padding-left: 24px; border-left: 1px solid var(--line); }
@media (max-width: 980px) { .feature:nth-child(3) { padding-left: 0; border-left: 0; } }
@media (max-width: 560px) { .feature + .feature { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); } }
.feature .ico { width: 28px; height: 28px; color: var(--red); }
.feature h3 { font-family: var(--font-body); font-size: var(--step-0); font-weight: 600; }
.feature p { color: var(--ink-2); font-size: 0.95rem; }

.own-assets { margin-top: 28px; padding: 28px; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 24px 48px; align-items: center; background: var(--paper-2); border-left: 2px solid var(--red); }
@media (max-width: 760px) { .own-assets { grid-template-columns: minmax(0, 1fr); padding: 22px; } }
.own-assets-text { display: grid; gap: 10px; }
.own-assets .ico { width: 28px; height: 28px; color: var(--red); }
.own-assets h3 { font-family: var(--font-body); font-size: var(--step-0); font-weight: 600; }
.own-assets p { color: var(--ink-2); font-size: 0.95rem; max-width: 46ch; }
.asset-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.asset-chips li { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; background: var(--paper); border: 1px solid var(--line); font-size: var(--step--1); }
.asset-chips li::before { content: ""; width: 7px; height: 5px; background: var(--red); transform: skewX(-38deg); }
.asset-chips li.more { background: transparent; border-style: dashed; color: var(--ink-2); }
.asset-chips li.more::before { background: var(--ink-2); }

/* ---------- резервы (демо, тарифы) ---------- */
.slot-label { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-mono); font-size: 0.75rem; color: var(--ink-2); padding: 4px 10px; border: 1px dashed var(--ink-2); border-radius: 999px; background: var(--paper); }
.demo-slot { position: relative; margin-top: 36px; min-height: 520px; border: 1.5px dashed color-mix(in srgb, var(--ink-2) 55%, transparent); border-radius: 6px; padding: 28px; display: grid; grid-template-rows: auto auto 1fr; gap: 24px; background: var(--paper-2); }
.demo-slot .slot-label { position: absolute; top: -13px; left: 24px; }
.sk { background: color-mix(in srgb, var(--line) 85%, transparent); border-radius: 3px; }
.demo-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
@media (max-width: 720px) { .demo-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.demo-kpi { display: grid; gap: 8px; padding: 16px; background: var(--paper); border: 1px solid var(--line); }
.demo-chart { height: 180px; position: relative; background: var(--paper); border: 1px solid var(--line); overflow: hidden; }
.demo-chart svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.demo-rows { display: grid; gap: 10px; align-content: start; }
.demo-row { display: grid; grid-template-columns: 60px 1fr 90px 70px; gap: 16px; align-items: center; }
.demo-center { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; gap: 6px; pointer-events: none; }
.demo-center strong { font-family: var(--font-display); font-weight: 500; font-size: var(--step-2); }
.demo-center span { font-size: var(--step--1); color: var(--ink-2); }
.demo-dim { opacity: .55; }

.demo-center:has(iframe) { display: block; pointer-events: auto; overflow: hidden; border-radius: inherit; }
.demo-center iframe { display: block; width: 100%; height: 100%; border: 0; background: transparent; }

.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin-top: 40px; }
@media (max-width: 880px) { .plans { grid-template-columns: minmax(0, 1fr); } }
.plan { border: 1px solid var(--line); padding: 28px; display: flex; flex-direction: column; gap: 18px; background: var(--paper); }
.plan .btn { margin-top: auto; }
.plan .lvl { display: flex; gap: 4px; }
.plan .lvl i { width: 12px; height: 7px; background: var(--line); transform: skewX(-38deg); }
.plan .lvl i.on { background: var(--red); }
.plan h3 { font-size: var(--step-2); }
.plan .price { font-family: var(--font-mono); color: var(--ink-2); font-size: var(--step-1); }
.plan .lines { display: grid; gap: 10px; }
.plan .lines .sk { height: 10px; }
.plan .btn { width: 100%; }
.plans-note { margin-top: 18px; font-size: var(--step--1); color: var(--ink-2); }

.billing-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 32px; }
@media (max-width: 760px) { .billing-facts { grid-template-columns: minmax(0, 1fr); } }
.billing-fact { display: grid; gap: 6px; padding-top: 14px; border-top: 2px solid var(--ink); }
.billing-fact b { font-weight: 600; }
.billing-fact span { color: var(--ink-2); font-size: 0.95rem; }

/* ---------- сохранность данных ---------- */
.objection { display: grid; gap: 10px; padding: 22px 24px; background: var(--paper-2); border-left: 2px solid var(--red); }
.objection .q { font-family: var(--font-display); font-style: italic; font-size: var(--step-1); }
.objection .a { color: var(--ink); }
.guarantees { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 8px; }
@media (max-width: 640px) { .guarantees { grid-template-columns: minmax(0, 1fr); } }
.guarantee { display: grid; gap: 6px; padding-top: 14px; border-top: 2px solid var(--ink); }
.guarantee b { font-weight: 600; }
.guarantee span { color: var(--ink-2); font-size: 0.95rem; }

/* ---------- финал ---------- */
.final { text-align: left; }
.final .wrap { display: grid; gap: 22px; justify-items: start; }
.final h2 { font-size: var(--step-4); max-width: 14em; }
.final h2 em { font-style: italic; color: var(--red); font-weight: 400; }

footer { border-top: 1px solid var(--line); padding-block: 32px 40px; font-size: var(--step--1); color: var(--ink-2); }
footer .wrap { display: flex; flex-wrap: wrap; gap: 14px 32px; align-items: center; }
footer .brand { font-size: 1.05rem; color: var(--ink); }
footer .brand img { width: 26px; }
footer .credits { margin-left: auto; max-width: 52ch; }
footer a { text-underline-offset: 2px; }
footer .legal { display: flex; flex-wrap: wrap; gap: 6px 20px; flex-basis: 100%; order: 3; }
footer .legal a:hover { color: var(--ink); }

/* ---------- cookie ---------- */
.cookie-banner { position: fixed; z-index: 20; left: 16px; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); max-width: 640px; margin-inline: auto; display: flex; align-items: center; gap: 16px 20px; padding: 16px 20px; background: var(--paper); color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 8px 28px rgb(0 0 0 / .12); font-size: var(--step--1); line-height: 1.5; }
.cookie-banner a { text-underline-offset: 2px; }
.cookie-banner .btn { flex-shrink: 0; }
@media (max-width: 520px) { .cookie-banner { flex-direction: column; align-items: stretch; } }

h2.section-title { font-size: var(--step-3); margin-top: 14px; max-width: 18em; }
.section-head { display: grid; gap: 0; }
.section-head .lead { margin-top: 16px; }

@media (prefers-reduced-motion: no-preference) {
  .hero .reveal { animation: rise .7s cubic-bezier(.2,.7,.2,1) both; }
  .hero .reveal:nth-child(2) { animation-delay: .06s; } .hero .reveal:nth-child(3) { animation-delay: .12s; }
  .hero .reveal:nth-child(4) { animation-delay: .18s; } .hero .reveal:nth-child(5) { animation-delay: .24s; }
  @keyframes rise { from { transform: translateY(10px); } to { transform: none; } }
}
