:root {
  --bg: #fbf7f4; --bg-alt: #f5ede7; --card: #ffffff; --text: #2b211d; --muted: #8a7b74;
  --line: #eee3dc; --accent: #e0674c; --accent-dark: #c9553b; --accent-text: #ffffff; --accent-soft: #fbe3da;
  --radius: 16px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1c1715; --bg-alt: #221c19; --card: #27201d; --text: #f3ebe6; --muted: #a8988f;
    --line: #3a2f2a; --accent: #f08a6c; --accent-dark: #f59e84; --accent-text: #1c1715; --accent-soft: #4a2c23;
  }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 17px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); }
img { max-width: 100%; display: block; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 760px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }

/* шапка */
.top { position: sticky; top: 0; z-index: 5; background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.top-row { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 20px; color: var(--text); text-decoration: none; }
.logo-mark { width: 26px; height: 26px; border-radius: 8px; background: var(--accent); position: relative; flex: none; }
.logo-mark::after { content: ""; position: absolute; inset: 7px; border-radius: 3px; background: var(--bg); }
.top-nav { display: flex; gap: 22px; align-items: center; font-size: 15px; }
.top-nav a { color: var(--muted); text-decoration: none; }
.top-nav a:hover { color: var(--text); }
.top-nav .nav-cabinet { color: var(--accent); font-weight: 600; }
@media (max-width: 720px) { .top-nav a:not(.nav-cabinet) { display: none; } }

/* кнопки */
.btn {
  display: inline-block; padding: 15px 26px; border-radius: 14px; background: var(--accent); color: var(--accent-text);
  font-weight: 700; text-decoration: none; transition: background .15s, transform .15s;
}
.btn:hover { background: var(--accent-dark); }
.btn:active { transform: scale(.98); }
.btn.ghost { background: transparent; color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn.ghost:hover { background: var(--accent-soft); }
.btn.light { background: #fff; color: #c9553b; }

/* первый экран */
.hero { padding: 56px 0 40px; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.eyebrow { color: var(--accent); font-weight: 700; font-size: 14px; text-transform: uppercase; letter-spacing: .06em; margin: 0 0 12px; }
h1 { font-size: clamp(32px, 5vw, 50px); line-height: 1.12; margin: 0 0 18px; letter-spacing: -.02em; }
.lead { font-size: 19px; color: var(--muted); margin: 0 0 28px; max-width: 34em; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.note { font-size: 14px; color: var(--muted); margin-top: 16px; }
.phones { position: relative; height: 560px; }
.phone {
  position: absolute; width: 250px; height: auto; border-radius: 30px; border: 8px solid #2b211d;
  box-shadow: 0 24px 60px rgba(60, 30, 20, .22); background: #fbf7f4;
}
.phone.back { right: 170px; top: 40px; transform: rotate(-5deg); opacity: .96; }
.phone.front { right: 10px; top: 0; transform: rotate(3deg); }
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; }
  .phones { height: 430px; max-width: 420px; margin: 0 auto; width: 100%; }
  .phone { width: 200px; }
  .phone.back { right: auto; left: 0; top: 30px; }
  .phone.front { right: 0; }
}

.who { padding: 8px 0 24px; }
.who p { text-align: center; color: var(--muted); max-width: 46em; margin: 0 auto; }

/* секции */
.section { padding: 64px 0; }
.section.alt { background: var(--bg-alt); }
h2 { font-size: clamp(26px, 3.4vw, 36px); margin: 0 0 28px; letter-spacing: -.01em; }
h3 { font-size: 19px; margin: 0 0 6px; }

.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.steps li { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.steps p { margin: 0; color: var(--muted); }
.step-num {
  display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 50%;
  background: var(--accent-soft); color: var(--accent); font-weight: 800; margin-bottom: 12px;
}
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.feature { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.feature p { margin: 0; color: var(--muted); }
@media (max-width: 860px) { .steps, .features { grid-template-columns: 1fr; } }

.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.gallery figure { margin: 0; }
.gallery img { border-radius: 22px; border: 6px solid #2b211d; box-shadow: 0 12px 30px rgba(60, 30, 20, .14); background: #fbf7f4; }
.gallery figcaption { text-align: center; color: var(--muted); font-size: 15px; margin-top: 10px; }
@media (max-width: 860px) {
  .gallery { grid-template-columns: repeat(4, 220px); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; }
  .gallery figure { scroll-snap-align: start; }
}

.price-card {
  max-width: 520px; background: var(--card); border: 2px solid var(--accent); border-radius: 22px; padding: 28px;
}
.price-badge { display: inline-block; margin: 0 0 8px; padding: 3px 10px; border-radius: 8px; background: var(--accent-soft); color: var(--accent); font-weight: 700; font-size: 13px; }
.price-value { font-size: 40px; font-weight: 800; margin: 0 0 8px; }
.price-card p { color: var(--muted); }
.price-card .btn { margin-top: 8px; }

details { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 0 20px; margin-bottom: 10px; }
summary { cursor: pointer; padding: 16px 0; font-weight: 600; list-style: none; position: relative; padding-right: 28px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; position: absolute; right: 0; top: 13px; font-size: 22px; color: var(--accent); }
details[open] summary::after { content: "–"; }
details p { margin: 0 0 16px; color: var(--muted); }

.final { background: var(--accent); color: #fff; text-align: center; padding: 60px 0; }
.final h2 { color: #fff; }

.foot { padding: 36px 0 48px; border-top: 1px solid var(--line); }
.foot-grid { display: grid; grid-template-columns: 1fr 1fr 1.3fr; gap: 24px; }
.foot-links { display: flex; flex-direction: column; gap: 8px; font-size: 15px; }
.foot-links a { color: var(--text); }
@media (max-width: 720px) { .foot-grid { grid-template-columns: 1fr; } }

/* текстовые страницы (политика) */
.doc { padding: 40px 0 64px; }
.doc h1 { font-size: clamp(28px, 4vw, 38px); }
.doc h2 { font-size: 22px; margin: 32px 0 10px; }
.doc p, .doc li { color: var(--text); }
.doc .meta { color: var(--muted); font-size: 15px; }

/* шапка: кнопка «Создать кабинет» */
.top-nav .nav-cta { background: var(--accent); color: var(--accent-text); padding: 8px 14px; border-radius: 10px; font-weight: 700; }
.top-nav .nav-cta:hover { background: var(--accent-dark); color: var(--accent-text); }
@media (max-width: 720px) {
  .top-nav a:not(.nav-cabinet) { display: revert; }
  .top-nav a[href^="#"], .top-nav a[href="/"]:not(.nav-cabinet) { display: none; }
  .top-nav { gap: 14px; }
}

/* страница «Создать кабинет» */
.start { padding: 48px 0 64px; }
.start .lead { margin-bottom: 32px; }
.start-grid { display: grid; grid-template-columns: 1.3fr .9fr; gap: 32px; align-items: start; }
.start-steps { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 14px; }
.start-steps li { display: flex; gap: 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.start-steps .step-num { flex: none; margin: 0; }
.start-steps p { margin: 0; color: var(--muted); }
.qr-card { position: sticky; top: 84px; background: var(--card); border: 1px solid var(--line); border-radius: 22px; padding: 28px; text-align: center; }
.qr { width: 220px; height: 220px; margin: 0 auto; border-radius: 12px; border: 1px solid var(--line); background: #fff; }
.qr-caption { font-weight: 700; margin: 14px 0 2px; }
.qr-card .btn { display: block; margin-top: 18px; }
.qr-note { margin: 14px 0 0; }
.start-after { margin-top: 48px; max-width: 640px; }
.start-after h2 { margin-bottom: 10px; }
.start-after p { color: var(--muted); }
.only-mobile { display: none; }
@media (max-width: 860px) {
  .start-grid { grid-template-columns: 1fr; }
  .qr-card { position: static; order: -1; }
  .start-grid .qr-card { grid-row: 1; }
  .only-desktop { display: none; }
  .only-mobile { display: block; }
  .qr-card .btn { margin-top: 0; }
}
.start-grid > * { min-width: 0; }
.start-steps b { overflow-wrap: anywhere; }
