/* Веббук — лендинг. Бумага, чернила, киноварь; шрифт книги — Old Standard (SIL OFL). */
@font-face { font-family: 'Old Standard'; src: url('/m/f/OldStandard-Regular.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'Old Standard'; src: url('/m/f/OldStandard-Italic.woff2') format('woff2'); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: 'Old Standard'; src: url('/m/f/OldStandard-Bold.woff2') format('woff2'); font-weight: 700; font-style: normal; font-display: swap; }

:root {
  --paper: #f3ede1;
  --paper-2: #ebe3d3;
  --ink: #1d1a16;
  --ink-2: #4a433a;
  --muted: #7a7062;
  --line: #d6ccb9;
  --red: #8a2d1c;
  --red-2: #a5432f;
  --night: #16130f;
  --night-2: #221d17;
  --candle: #d9b779;
  --serif: 'Old Standard', 'Iowan Old Style', 'Palatino Linotype', Georgia, serif;
  --sans: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --gut: 16px;
  --max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 18px/1.6 var(--serif);
  /* лёгкое зерно бумаги */
  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='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .3 0 0 0 0 .25 0 0 0 0 .2 0 0 0 .05 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  overflow-x: hidden;
}
img, video { display: block; max-width: 100%; }
a { color: var(--red); text-underline-offset: 3px; }
em { font-style: italic; }
code { font: .85em/1 ui-monospace, Consolas, monospace; background: rgba(0,0,0,.05); padding: .1em .35em; border-radius: 4px; }
h1, h2, h3 { font-weight: 400; margin: 0; letter-spacing: -.01em; }

/* --- шапка --- */
.top {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 20px;
  padding: 10px var(--gut); background: rgba(243,237,225,.92); backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
.mark { font: 26px/1 var(--serif); color: var(--ink); text-decoration: none; letter-spacing: -.02em; }
.mark-i { font-style: italic; color: var(--red); }
.nav { display: none; gap: 22px; margin-left: auto; font: 14px/1 var(--sans); letter-spacing: .02em; }
.nav a { color: var(--ink-2); text-decoration: none; }
.nav a:hover { color: var(--red); }
.top .btn-sm { margin-left: auto; }
@media (min-width: 900px) { .nav { display: flex; } .top .btn-sm { margin-left: 8px; } .top { padding: 12px 32px; } }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 24px; border-radius: 999px; background: var(--red); color: #fbf6ec;
  font: 500 16px/1.1 var(--sans); text-decoration: none; border: 0; cursor: pointer;
  transition: background .2s, transform .2s;
}
.btn:hover { background: var(--red-2); }
.btn:active { transform: translateY(1px); }
.btn-sm { padding: 9px 16px; font-size: 14px; }
.link-arrow { font: 500 16px/1 var(--sans); color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--ink); padding-bottom: 3px; }
.link-arrow::after { content: ' →'; }
.link-arrow:hover { color: var(--red); border-color: var(--red); }

/* номера разделов — римские, как строфы */
.num, .kicker .num {
  font: italic 400 15px/1 var(--serif); color: var(--red); letter-spacing: .08em; margin: 0;
}
.kicker { display: flex; gap: 14px; align-items: baseline; font: 500 13px/1 var(--sans); text-transform: uppercase; letter-spacing: .14em; color: var(--muted); margin: 0 0 22px; }

/* --- I. первый экран --- */
.hero {
  max-width: var(--max); margin: 0 auto; padding: 40px var(--gut) 72px;
  display: grid; gap: 48px; align-items: center;
}
.hero h1 { font-size: clamp(42px, 10.5vw, 88px); line-height: .98; }
.hero h1 em { color: var(--red); }
.lead { font-size: 20px; line-height: 1.55; color: var(--ink-2); max-width: 34em; margin: 26px 0 30px; }
.cta { display: flex; flex-wrap: wrap; gap: 22px 28px; align-items: center; }
.hero-note { margin: 28px 0 0; font: 14px/1.5 var(--sans); color: var(--muted); max-width: 30em; }
.hero-phone { margin: 0; justify-self: center; }
.hero-phone figcaption { margin-top: 16px; font: 13px/1.4 var(--sans); color: var(--muted); text-align: center; max-width: 300px; }
@media (min-width: 900px) {
  .hero { grid-template-columns: 1.15fr .85fr; padding: 72px 32px 110px; }
}

/* телефон */
.phone {
  width: min(300px, 78vw); aspect-ratio: 9 / 19.2; border-radius: 46px; padding: 11px;
  background: linear-gradient(145deg, #2c2620, #0f0d0b); position: relative;
  box-shadow: 0 1px 0 rgba(255,255,255,.15) inset, 0 30px 60px -20px rgba(40,25,10,.45), 0 12px 24px -12px rgba(40,25,10,.4);
}
.phone::before { /* вырез камеры */
  content: ''; position: absolute; top: 20px; left: 50%; transform: translateX(-50%); width: 84px; height: 22px;
  background: #0b0a09; border-radius: 20px; z-index: 3;
}
.phone-screen { width: 100%; height: 100%; border-radius: 36px; overflow: hidden; background: #f4efe4; position: relative; }

/* лента в телефоне: едет вверх сама */
.strip { animation: feed 38s linear infinite; padding-top: 40px; }
.hero-phone:hover .strip, .hero-phone.paused .strip { animation-play-state: paused; }
@keyframes feed { from { transform: translateY(0); } to { transform: translateY(calc(-100% + 560px)); } }
@media (prefers-reduced-motion: reduce) { .strip { animation: none; } }
.strip img { width: 100%; height: auto; }
.s-title { height: 150px; display: grid; place-items: center; font: italic 22px/1 var(--serif); color: var(--ink-2); }
.s-title span { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 10px 18px; }
.s-stanza { padding: 18px 20px 22px; font: 14.5px/1.55 var(--serif); color: var(--ink); }
.s-stanza p { margin: 0; }
.s-dim { color: var(--muted); text-align: center; }
.s-label { font: italic 12px/1.3 var(--serif); color: var(--red); margin: 0 0 8px !important; letter-spacing: .04em; }
.s-panel { position: relative; }
.bubble {
  position: absolute; left: 14px; bottom: 18px; background: #fffaf0; color: var(--ink);
  font: italic 14px/1.2 var(--serif); padding: 8px 12px; border-radius: 16px 16px 16px 4px; box-shadow: 0 4px 12px rgba(0,0,0,.25);
}

/* --- общие разделы --- */
.sec { max-width: var(--max); margin: 0 auto; padding: 72px var(--gut); border-top: 1px solid var(--line); }
.sec-head { margin-bottom: 36px; }
.sec-head .num { margin-bottom: 14px; }
.sec h2 { font-size: clamp(32px, 6.4vw, 56px); line-height: 1.05; max-width: 15em; }
.sec h2 em { color: var(--red); }
.sec-sub { font: 16px/1.5 var(--sans); color: var(--muted); margin: 16px 0 0; max-width: 40em; }
.big { font-size: clamp(21px, 3.3vw, 28px); line-height: 1.45; margin: 0 0 40px; max-width: 32em; }
.big.narrow { max-width: 28em; }
.sec-body p { max-width: 38em; }
@media (min-width: 900px) {
  .sec { display: grid; grid-template-columns: 220px 1fr; gap: 0 48px; padding: 110px 32px; }
  .sec-head { margin: 0; }
  .sec-head .num { position: sticky; top: 90px; }
  .sec > .sec-head { grid-column: 1 / -1; display: grid; grid-template-columns: 220px 1fr; gap: 0 48px; margin-bottom: 52px; }
  .sec > .sec-head .num { grid-row: 1 / 3; padding-top: 14px; }
  .sec > .sec-head h2, .sec > .sec-head .sec-sub { grid-column: 2; }
  .sec > :not(.sec-head) { grid-column: 2; }
}

/* II. состав */
.parts { margin: 0; display: grid; gap: 0; border-top: 1px solid var(--ink); }
.parts div { display: grid; gap: 6px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.parts dt { font: 600 13px/1.4 var(--sans); text-transform: uppercase; letter-spacing: .14em; color: var(--red); }
.parts dd { margin: 0; color: var(--ink-2); }
@media (min-width: 700px) { .parts div { grid-template-columns: 180px 1fr; gap: 24px; } }

/* III. тёмный раздел */
.dark { background: var(--night); color: #efe6d4; border: 0; max-width: none; }
.dark > * { max-width: calc(var(--max) - 64px); }
@media (min-width: 900px) {
  .dark { padding-left: max(32px, calc((100vw - var(--max)) / 2 + 32px)); padding-right: max(32px, calc((100vw - var(--max)) / 2 + 32px)); }
}
.dark .num { color: var(--candle); }
.dark h2 em { color: var(--candle); }
.dark .big { color: #f3ead8; }

.compare { display: grid; gap: 28px; margin: 8px 0 48px; }
.compare figure { margin: 0; display: grid; grid-template-columns: 96px 1fr; gap: 18px; align-items: center; }
.compare figcaption { font: 15px/1.5 var(--sans); color: #b9ad98; }
.compare figcaption b { display: block; font: 400 21px/1.2 var(--serif); color: #f3ead8; margin-bottom: 4px; }
.compare .ours figcaption b { color: var(--candle); }
@media (min-width: 760px) {
  .compare { grid-template-columns: repeat(3, 1fr); gap: 36px; }
  .compare figure { grid-template-columns: 1fr; }
}
.mini {
  width: 96px; height: 196px; border-radius: 18px; border: 2px solid #4a4036; padding: 16px 9px; position: relative;
  display: flex; flex-direction: column; gap: 5px; overflow: hidden; background: #1f1a15;
}
.mini i { display: block; height: 4px; border-radius: 2px; background: #6b5f50; }
.mini i:nth-child(3n) { width: 78%; }
.mini-page { transform: scale(.62); transform-origin: top left; width: 160%; display: flex; flex-direction: column; gap: 3px; }
.mini-page i { height: 3px; }
.pinch { position: absolute; right: 10px; bottom: 10px; color: var(--candle); font: 22px/1 var(--sans); }
.mini-wall i { height: 3px; }
.mini-wb { gap: 6px; }
.mini-wb .pic { display: block; height: 52px; border-radius: 4px; background: linear-gradient(160deg, #8c7a5c, #3a3026); flex: none; }
.mini-wb .pic2 { background: linear-gradient(160deg, #6f6a80, #2c2a35); }
.mini-wb i { background: #d9cbb0; }
.ours .mini { border-color: var(--candle); animation: scroll-mini 6s ease-in-out infinite; }
@keyframes scroll-mini { 0%, 100% { padding-top: 16px; } 50% { padding-top: 0; } }

.facts { list-style: none; padding: 0; margin: 0; display: grid; gap: 18px; }
.facts li { color: #c9bda7; border-left: 2px solid #4a4036; padding-left: 16px; max-width: 36em; }
.facts b { color: #f3ead8; font-weight: 400; font-style: italic; }
@media (min-width: 760px) { .facts { grid-template-columns: 1fr 1fr; gap: 26px 40px; } }

/* IV. лента */
.feed { display: grid; gap: 64px; }
.beat { display: grid; gap: 22px; align-items: center; }
.beat-img { width: 100%; max-width: 420px; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 6px; background: var(--paper-2);
  box-shadow: 0 24px 40px -24px rgba(40,25,10,.5); }
blockquote { margin: 0; font-size: clamp(20px, 3vw, 26px); line-height: 1.45; }
.beat-text .s-label { font-size: 14px; }
.aside, .plain { color: var(--ink-2); font-size: 17px; }
.aside { font: 15px/1.5 var(--sans); color: var(--muted); margin-top: 16px; }
@media (min-width: 760px) {
  .beat { grid-template-columns: minmax(0, 420px) 1fr; gap: 48px; }
  .beat.flip { grid-template-columns: 1fr minmax(0, 420px); }
  .beat.flip .beat-img { order: 2; }
}
.seq { position: relative; overflow: hidden; }
.seq img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; }
.seq img.on { opacity: 1; }

.listen {
  margin-top: 22px; display: inline-flex; align-items: center; gap: 12px; padding: 10px 16px 10px 10px;
  border: 1px solid var(--ink); border-radius: 999px; background: transparent; color: var(--ink); cursor: pointer;
  font: 500 14px/1 var(--sans);
}
.listen:hover { border-color: var(--red); color: var(--red); }
.listen .ico { width: 28px; height: 28px; border-radius: 50%; background: var(--ink); position: relative; flex: none; }
.listen .ico::after { content: ''; position: absolute; left: 11px; top: 8px; border-style: solid; border-width: 6px 0 6px 9px; border-color: transparent transparent transparent var(--paper); }
.listen.playing .ico { background: var(--red); }
.listen.playing .ico::after { left: 9px; top: 9px; width: 10px; height: 10px; border: 0; background:
  linear-gradient(90deg, var(--paper) 0 3px, transparent 3px 7px, var(--paper) 7px 10px); }
.listen .bar { width: 64px; height: 2px; background: var(--line); position: relative; }
.listen .bar span { position: absolute; inset: 0 auto 0 0; width: 0; background: var(--red); }

/* V. три манеры */
.triptych { display: grid; gap: 24px; grid-template-columns: 1fr; }
.triptych figure { margin: 0; }
.triptych img { width: 100%; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 4px; }
.triptych figcaption { margin-top: 12px; font: 15px/1.45 var(--sans); color: var(--muted); }
.triptych figcaption b { display: block; font: italic 400 20px/1.2 var(--serif); color: var(--ink); margin-bottom: 2px; }
@media (min-width: 600px) { .triptych { grid-template-columns: repeat(3, 1fr); } }

/* VI. поколение */
.accent { background: var(--paper-2); max-width: none; border-top: 0; }
@media (min-width: 900px) {
  .accent { padding-left: max(32px, calc((100vw - var(--max)) / 2 + 32px)); padding-right: max(32px, calc((100vw - var(--max)) / 2 + 32px)); }
}
.two { display: grid; gap: 40px; }
@media (min-width: 1000px) { .two { grid-template-columns: 1.05fr 1fr; gap: 64px; } }
.reasons, .steps { margin: 0; padding: 0; list-style: none; counter-reset: r; display: grid; gap: 20px; }
.reasons li, .steps li { counter-increment: r; position: relative; padding-left: 44px; color: var(--ink-2); }
.reasons li::before, .steps li::before {
  content: counter(r, upper-roman); position: absolute; left: 0; top: 2px; font: italic 15px/1.4 var(--serif); color: var(--red);
}
.reasons b, .steps b { color: var(--ink); font-weight: 700; }

/* VII. Онегин */
.onegin { display: grid; gap: 48px; }
@media (min-width: 1000px) { .onegin { grid-template-columns: 1fr auto; align-items: start; } }
.stats { margin: 0; display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--ink); }
.stats div { padding: 18px 14px 18px 0; border-bottom: 1px solid var(--line); }
.stats dt { font-size: clamp(30px, 5vw, 46px); line-height: 1.05; color: var(--ink); }
.stats div:nth-child(3) dt { color: var(--red); }
.stats dd { margin: 6px 0 0; font: 14px/1.4 var(--sans); color: var(--muted); }
.live { display: grid; justify-items: center; gap: 16px; }
.phone-live .phone-screen { display: grid; place-items: center; background: #ece5d6; }
.live-cover { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .9; }
.live-btn { position: relative; z-index: 2; box-shadow: 0 10px 24px -8px rgba(0,0,0,.5); }
.phone-live iframe { position: absolute; inset: 34px 0 0; width: 100%; height: calc(100% - 34px); border: 0; background: #f4efe4; }
.phone-live .phone-screen:has(iframe) { background: #f4efe4; }
.live-note { font: 14px/1.5 var(--sans); color: var(--muted); max-width: 300px; text-align: center; margin: 0; }

/* VIII. как сделано */
.wbz { border: 1px solid var(--ink); padding: 26px 24px; border-radius: 4px; background: rgba(255,255,255,.25); }
.wbz h3 { font-size: 26px; margin-bottom: 10px; }
.wbz ul { padding-left: 1.1em; color: var(--ink-2); }
.wbz li { margin: 6px 0; }
.next { margin: 22px 0 0; font-style: italic; color: var(--red); }

/* IX. сотрудничество */
.together .big { max-width: 26em; }
.partners { list-style: none; padding: 0; margin: 0 0 56px; display: grid; gap: 0; border-top: 1px solid #4a4036; }
.partners li { padding: 18px 0; border-bottom: 1px solid #3a322a; color: #b9ad98; font: 15px/1.5 var(--sans); display: grid; gap: 4px; }
.partners b { font: 400 22px/1.25 var(--serif); color: #f3ead8; }
@media (min-width: 760px) { .partners li { grid-template-columns: 340px 1fr; gap: 24px; align-items: baseline; } }
.contact p { font: 15px/1.4 var(--sans); color: #b9ad98; margin: 0 0 10px; }
.mail {
  font-size: clamp(26px, 6.5vw, 58px); line-height: 1.1; color: var(--candle); text-decoration: none; word-break: break-all;
  border-bottom: 1px solid rgba(217,183,121,.4);
}
.mail:hover { color: #f0d39d; border-color: currentColor; }

/* подвал */
.foot { max-width: var(--max); margin: 0 auto; padding: 48px var(--gut) 64px; font: 13px/1.6 var(--sans); color: var(--muted); }
.foot p { max-width: 52em; margin: 0 0 10px; }
.foot .mark { font-size: 22px; margin-bottom: 16px; }
.foot a { color: var(--ink-2); }
@media (min-width: 900px) { .foot { padding: 56px 32px 72px; } }

/* появление при прокрутке */
.rv { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.rv.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .rv { opacity: 1; transform: none; transition: none; } html { scroll-behavior: auto; } }
