/* =========================================================
   Арт-спринт «14 дней без алгоритмов» — стили лендинга
   Палитра: тёплая бумага + пастельные акценты + приглушённый зелёный
   ========================================================= */

:root {
  --bg: #fdfbf7;
  --bg-alt: #f6f3ec;
  --surface: #ffffff;
  --ink: #26241f;
  --ink-soft: #6d675d;
  --line: #e7e1d5;

  --accent: #3f6b5a;
  --accent-strong: #33584a;
  --accent-soft: #dce7e0;

  --blush: #f6e7e0;
  --blush-line: #ecd6cb;
  --sky: #e4ecf3;
  --butter: #f6ecd6;
  --sand: #efe9df;

  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 18px 44px -28px rgba(38, 36, 31, .38);
  --shadow-soft: 0 10px 30px -22px rgba(38, 36, 31, .45);

  --font-body: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-display: "Playfair Display", "Times New Roman", Georgia, serif;

  --container: 1140px;
  --header-h: 72px;
}

/* ---------- База ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { max-width: 100%; }

h1, h2, h3 { font-family: var(--font-display); font-weight: 700; line-height: 1.18; letter-spacing: -.01em; margin: 0 0 .6em; }
h1 { font-size: clamp(32px, 4.4vw, 50px); }
h2.section-title { font-size: clamp(27px, 3.3vw, 38px); margin-bottom: .75em; }
h3 { font-size: 20px; }

p { margin: 0 0 1em; }
a { color: var(--accent-strong); text-underline-offset: 3px; }

.container { width: min(100% - 40px, var(--container)); margin-inline: auto; }
.container-narrow { max-width: 860px; }
.center { text-align: center; }

.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--accent); color: #fff; padding: 10px 16px; z-index: 100; border-radius: 0 0 10px 0;
}
.skip-link:focus { left: 0; }

:focus-visible { outline: 3px solid #7fa897; outline-offset: 2px; border-radius: 6px; }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 600 16px/1 var(--font-body);
  padding: 16px 28px;
  border: 1px solid transparent;
  border-radius: 999px;
  cursor: pointer;
  text-decoration: none;
  transition: transform .18s ease, background-color .18s ease, box-shadow .18s ease;
}
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 14px 26px -18px rgba(63, 107, 90, .9); }
.btn-primary:hover { background: var(--accent-strong); transform: translateY(-2px); }
.btn-primary:active { transform: translateY(0); }
.btn-primary[disabled] { opacity: .65; cursor: progress; transform: none; }
.btn-block { width: 100%; }
.btn-sm { padding: 11px 20px; font-size: 15px; }

/* ---------- Шапка ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(253, 251, 247, .88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.site-header.is-stuck { border-bottom-color: var(--line); box-shadow: 0 10px 30px -28px rgba(38, 36, 31, .6); }

.header-inner { display: flex; align-items: center; gap: 22px; height: var(--header-h); }

.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; }
.logo-mark { display: grid; place-items: center; }
.logo-text { display: flex; flex-direction: column; font-weight: 700; font-size: 17px; line-height: 1.1; letter-spacing: -.01em; }
.logo-text em { font-style: normal; font-weight: 500; font-size: 11.5px; color: var(--ink-soft); letter-spacing: .04em; text-transform: uppercase; }

.nav { display: flex; gap: 20px; margin-left: auto; }
.nav a { color: var(--ink-soft); text-decoration: none; font-size: 15.5px; font-weight: 500; transition: color .16s ease; }
.nav a:hover { color: var(--ink); }

.burger { display: none; flex-direction: column; gap: 5px; background: none; border: 0; padding: 8px; cursor: pointer; }
.burger span { width: 22px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform .2s ease, opacity .2s ease; }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Первый экран ---------- */
.hero {
  position: relative;
  padding: clamp(40px, 6vw, 76px) 0 clamp(48px, 7vw, 88px);
  background:
    radial-gradient(760px 420px at 82% 6%, rgba(246, 231, 224, .85), transparent 62%),
    radial-gradient(620px 420px at 4% 84%, rgba(228, 236, 243, .8), transparent 60%),
    var(--bg);
  overflow: hidden;
}
.hero::after {
  content: ""; position: absolute; inset-inline: 0; bottom: 0; height: 1px; background: var(--line);
}

.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(30px, 5vw, 64px); align-items: start; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: 13px; font-weight: 600; letter-spacing: .09em; text-transform: uppercase;
  color: var(--ink-soft);
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 8px 16px; border-radius: 999px;
  margin: 0 0 22px;
}
.eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: #c4876b; box-shadow: 0 0 0 4px rgba(196, 135, 107, .2); }
.eyebrow.center { display: flex; width: max-content; margin-inline: auto; margin-bottom: 18px; }

.hero-sub {
  font-family: var(--font-body);
  font-size: clamp(17px, 1.5vw, 20px);
  font-weight: 500;
  line-height: 1.5;
  color: var(--ink-soft);
  margin-bottom: 18px;
}

.utp {
  background: var(--accent-soft);
  border-left: 4px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 16px 20px;
  font-size: 16px;
  color: #33463d;
}
.utp strong { color: var(--accent-strong); }

.hero-badges { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0; margin: 24px 0 0; }
.hero-badges li {
  font-size: 14px; font-weight: 600; color: var(--ink-soft);
  background: var(--surface); border: 1px solid var(--line);
  padding: 8px 15px; border-radius: 999px;
}

.hero-side { display: grid; gap: 22px; }
.hero-art { padding: 4px 6px 0; }
.hero-art svg { display: block; width: 100%; height: auto; filter: drop-shadow(0 24px 40px rgba(38, 36, 31, .12)); }

/* ---------- Форма регистрации ---------- */
.reg-form {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(22px, 3vw, 30px);
}
.reg-form h3 { font-size: 21px; margin-bottom: 18px; }

.field { display: block; margin-bottom: 16px; }
.field span { display: block; font-size: 14px; font-weight: 600; margin-bottom: 7px; color: var(--ink); }
.field span em { font-style: normal; font-weight: 400; color: var(--ink-soft); }
.field input {
  width: 100%;
  font: 400 16px/1.4 var(--font-body);
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 13px 15px;
  transition: border-color .16s ease, background-color .16s ease, box-shadow .16s ease;
}
.field input::placeholder { color: #a9a294; }
.field input:focus { outline: none; background: #fff; border-color: var(--accent); box-shadow: 0 0 0 4px rgba(63, 107, 90, .13); }
.field input[aria-invalid="true"] { border-color: #c06a5a; box-shadow: 0 0 0 4px rgba(192, 106, 90, .12); }

.hp { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

.form-note { font-size: 13px; line-height: 1.55; color: var(--ink-soft); margin: 14px 0 0; }

.form-status {
  margin: 14px 0 0;
  font-size: 14.5px; font-weight: 600;
  padding: 12px 15px; border-radius: var(--radius-sm);
}
.form-status[data-type="ok"] { background: var(--accent-soft); color: var(--accent-strong); }
.form-status[data-type="error"] { background: var(--blush); color: #9a4b3b; }

/* ---------- Секции ---------- */
.section { padding: clamp(56px, 8vw, 96px) 0; }
.section-alt { background: var(--bg-alt); border-block: 1px solid var(--line); }

.section-title { max-width: 830px; }
.section-title.center { margin-inline: auto; }

.block-subtitle { font-size: clamp(20px, 2.2vw, 25px); margin-bottom: 20px; }

.cards { display: grid; gap: 20px; }
.cards-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 24px 24px;
  transition: transform .22s ease, box-shadow .22s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-soft); }
.card h3 { font-family: var(--font-body); font-size: 17.5px; font-weight: 650; line-height: 1.4; margin-bottom: 12px; }
.card p { font-size: 15.5px; margin: 0; color: var(--ink-soft); }

.card-num {
  display: inline-grid; place-items: center;
  width: 44px; height: 44px; margin-bottom: 16px;
  font: 700 15px/1 var(--font-body); letter-spacing: .04em;
  border-radius: 14px;
}
.card-pain { background: #fffdfc; border-color: var(--blush-line); }
.card-pain .card-num { background: var(--blush); color: #8c4433; }
.card-pain .card-effect { color: #7d5748; }

.card-solution { background: #fff; border-color: #d7e2db; }
.card-icon {
  display: inline-grid; place-items: center;
  width: 46px; height: 46px; margin-bottom: 16px;
  background: var(--accent-soft); color: var(--accent-strong);
  border-radius: 14px;
}
.card-icon svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.card-solution .card-effect { color: #3f5a4e; }
.card-feature { background: var(--surface); }

.divider { display: grid; place-items: center; padding: clamp(30px, 5vw, 48px) 0 clamp(18px, 3vw, 26px); }
.divider svg { overflow: visible; }

/* ---------- Шаги ---------- */
.steps {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px;
  counter-reset: step;
}
.step {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 22px 24px;
}
.step::after {
  content: ""; position: absolute; top: 46px; right: -21px;
  width: 21px; height: 1px; background: repeating-linear-gradient(90deg, var(--line) 0 5px, transparent 5px 10px);
}
.step:last-child::after { display: none; }
.step-num {
  display: grid; place-items: center;
  width: 42px; height: 42px; margin-bottom: 16px;
  border-radius: 50%;
  background: var(--butter); color: #8a6a2c;
  font: 700 17px/1 var(--font-body);
}
.step h3 { font-family: var(--font-body); font-size: 17px; font-weight: 650; margin-bottom: 10px; }
.step p { font-size: 15px; color: var(--ink-soft); margin: 0; }

.cta-inline { text-align: center; margin-top: clamp(34px, 5vw, 52px); }
.cta-inline .form-note { max-width: 520px; margin-inline: auto; }

/* ---------- Призы ---------- */
.prizes { margin-top: clamp(38px, 5vw, 56px); }
.prize {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 26px 24px;
  transition: transform .22s ease, box-shadow .22s ease;
}
.prize:hover { transform: translateY(-4px); box-shadow: var(--shadow-soft); }
.prize-label {
  display: inline-block; font-size: 12.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink-soft); background: var(--sand); border-radius: 999px; padding: 6px 13px; margin-bottom: 14px;
}
.prize-value { font-family: var(--font-display); font-size: clamp(24px, 2.6vw, 30px); font-weight: 700; margin: 0 0 8px; }
.prize p:last-child { margin: 0; font-size: 15.5px; color: var(--ink-soft); }
.prize-main { background: linear-gradient(160deg, #eef3f0, #ffffff 65%); border-color: #cfe0d7; }
.prize-main .prize-label { background: var(--accent-soft); color: var(--accent-strong); }
.prize-main .prize-value { color: var(--accent-strong); }

.transparency {
  margin-top: clamp(38px, 5vw, 56px);
  display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  gap: clamp(24px, 4vw, 48px);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(26px, 4vw, 40px);
}
.transparency-copy p { color: var(--ink-soft); font-size: 16px; }
.callout-lite {
  background: var(--butter); border-radius: var(--radius-sm);
  padding: 13px 17px; color: #6f5a2e; font-weight: 600; font-size: 15px !important;
}

.criteria { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; align-content: center; }
.criteria-row { display: flex; justify-content: space-between; align-items: baseline; font-size: 15.5px; margin-bottom: 8px; }
.criteria-row strong { font-family: var(--font-display); font-size: 18px; color: var(--accent-strong); }
.bar { height: 10px; background: var(--sand); border-radius: 999px; overflow: hidden; }
.bar i { display: block; height: 100%; width: var(--w); border-radius: 999px; background: linear-gradient(90deg, var(--accent), #7fa897); }

/* ---------- Таймлайн ---------- */
.timeline { list-style: none; margin: 0 auto; padding: 0; max-width: 780px; position: relative; }
.timeline::before {
  content: ""; position: absolute; left: 116px; top: 8px; bottom: 8px; width: 2px;
  background: repeating-linear-gradient(180deg, var(--line) 0 7px, transparent 7px 14px);
}
.timeline li {
  position: relative;
  display: grid; grid-template-columns: 116px 1fr; gap: 30px; align-items: start;
  padding: 13px 0;
}
.timeline li::before {
  content: ""; position: absolute; left: 111px; top: 21px;
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--bg); border: 3px solid var(--accent);
}
.tl-date { text-align: right; font-weight: 700; font-size: 15.5px; color: var(--accent-strong); }
.tl-text { font-size: 16.5px; padding-left: 4px; }

.rule {
  display: flex; gap: 18px; align-items: flex-start;
  max-width: 780px; margin: clamp(34px, 5vw, 50px) auto 0;
  background: var(--blush); border: 1px solid var(--blush-line);
  border-radius: var(--radius); padding: 24px 26px;
}
.rule-icon { flex: none; display: grid; place-items: center; width: 46px; height: 46px; background: #fff; border-radius: 14px; color: #a15744; }
.rule-icon svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.rule h3 { font-family: var(--font-body); font-size: 17px; margin-bottom: 8px; }
.rule p { margin: 0; font-size: 15.5px; color: #6f5145; }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 14px; }
.faq-item {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: box-shadow .2s ease;
}
.faq-item[open] { box-shadow: var(--shadow-soft); }
.faq-item summary {
  list-style: none;
  cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 19px 22px;
  font-weight: 650; font-size: 16.5px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: ""; flex: none;
  width: 12px; height: 12px;
  border-right: 2px solid var(--accent); border-bottom: 2px solid var(--accent);
  transform: rotate(45deg) translateY(-3px);
  transition: transform .2s ease;
}
.faq-item[open] summary::after { transform: rotate(-135deg) translateY(-3px); }
.faq-answer { padding: 0 22px 20px; color: var(--ink-soft); font-size: 16px; }
.faq-answer p { margin: 0; }

/* ---------- Финальный блок ---------- */
.final {
  background:
    radial-gradient(700px 380px at 12% 10%, rgba(220, 231, 224, .8), transparent 60%),
    radial-gradient(640px 400px at 88% 90%, rgba(246, 236, 214, .7), transparent 62%),
    var(--bg);
}
.final-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(30px, 5vw, 60px); align-items: center; }
.final-copy p { font-size: 17.5px; color: var(--ink-soft); max-width: 560px; }
.final-copy strong { color: var(--ink); }

.countdown { display: flex; gap: 14px; margin-top: 26px; }
.countdown div {
  min-width: 86px; text-align: center;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 12px 10px;
}
.countdown span { display: block; font-family: var(--font-display); font-size: 30px; font-weight: 700; color: var(--accent-strong); line-height: 1; }
.countdown small { font-size: 12px; color: var(--ink-soft); text-transform: uppercase; letter-spacing: .07em; }

/* ---------- Подвал ---------- */
.site-footer { background: #2a2822; color: #d9d3c7; padding: clamp(38px, 5vw, 56px) 0 24px; }
.footer-grid { display: grid; grid-template-columns: 1.2fr .8fr 1fr; gap: 34px; align-items: start; }
.footer-brand .logo-text { color: #fff; margin-bottom: 12px; }
.footer-brand .logo-text em { color: #b0a99b; }
.footer-brand p { font-size: 15px; color: #a9a294; max-width: 340px; margin: 0; }
.footer-links { display: grid; gap: 12px; }
.footer-links a { color: #e8e3d8; text-decoration: none; font-size: 15.5px; }
.footer-links a:hover { color: #fff; text-decoration: underline; }
.footer-contacts p { margin: 0 0 10px; font-size: 15.5px; }
.footer-contacts span { display: block; color: #a9a294; font-size: 13.5px; margin-bottom: 3px; }
.footer-contacts a { color: #fff; }
.footer-contacts .muted { color: #a9a294; font-size: 14px; }
.footer-bottom { margin-top: 30px; padding-top: 18px; border-top: 1px solid #3d3a33; color: #a8a196; font-size: 13.5px; }

/* ---------- Внутренние страницы ---------- */
.page-hero { padding: clamp(36px, 5vw, 64px) 0 clamp(20px, 3vw, 34px); }
.page-body { padding-bottom: clamp(48px, 7vw, 88px); }
.doc h2 { font-size: clamp(22px, 2.4vw, 27px); margin-top: 1.6em; }
.doc h3 { font-family: var(--font-body); font-size: 17.5px; font-weight: 650; margin-top: 1.4em; }
.doc p, .doc li { color: var(--ink-soft); font-size: 16.5px; }
.doc li { margin-bottom: 8px; }
.doc .back { display: inline-block; margin-bottom: 18px; font-weight: 600; font-size: 15px; text-decoration: none; }

/* ---------- Анимация появления ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .card, .prize { transition: none; }
}

/* ---------- Адаптив ---------- */
@media (max-width: 1020px) {
  .hero-grid, .final-grid { grid-template-columns: 1fr; }
  .hero-side { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; }
  .hero-art { order: 2; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .step::after { display: none; }
  .cards-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cards-3 > :last-child:nth-child(odd) { grid-column: span 2; }
  .transparency { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .nav {
    position: fixed; inset: var(--header-h) 0 auto 0;
    flex-direction: column; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line);
    padding: 8px 20px 16px;
    transform: translateY(-140%); transition: transform .25s ease;
    box-shadow: 0 24px 40px -30px rgba(38, 36, 31, .7);
  }
  .nav.is-open { transform: translateY(0); }
  .nav a { padding: 14px 4px; border-bottom: 1px solid var(--line); font-size: 16px; }
  .nav a:last-child { border-bottom: 0; }
  .burger { display: flex; margin-left: auto; }
  .header-cta { display: none; }
}

@media (max-width: 700px) {
  body { font-size: 16px; }
  .hero-side { grid-template-columns: 1fr; }
  .hero-art { order: 0; max-width: 440px; margin-inline: auto; }
  .cards-3, .steps { grid-template-columns: 1fr; }
  .cards-3 > :last-child:nth-child(odd) { grid-column: auto; }
  .timeline::before { left: 8px; }
  .timeline li { grid-template-columns: 1fr; gap: 4px; padding-left: 30px; }
  .timeline li::before { left: 3px; top: 20px; }
  .tl-date { text-align: left; font-size: 14.5px; }
  .rule { flex-direction: column; padding: 22px; }
  .footer-grid { grid-template-columns: 1fr; gap: 26px; }
  .countdown div { min-width: 0; flex: 1; }
}
