/* Степан Новиков — личный сайт. Без внешних зависимостей. */

:root {
  --ink: #0f2137;
  --ink-soft: #22344b;
  --muted: #5b6b80;
  --line: #dbe4ef;
  --bg: #ffffff;
  --tint: #f4f7fb;
  --card: #ffffff;
  --accent: #1f6feb;
  --accent-dark: #1554b8;
  --accent-soft: #e8f0fe;
  --teal: #0fa3a3;
  --radius: 16px;
  --shadow: 0 1px 2px rgba(15, 33, 55, .06), 0 12px 32px rgba(15, 33, 55, .07);
  --shadow-hover: 0 2px 4px rgba(15, 33, 55, .08), 0 18px 40px rgba(15, 33, 55, .12);
  --wrap: 1120px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}

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

img, svg { max-width: 100%; display: block; }
h1, h2, h3 { line-height: 1.15; margin: 0 0 .5em; letter-spacing: -.02em; }
h1 { font-size: clamp(1.6rem, 4.2vw, 2.75rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.6vw, 2.4rem); font-weight: 750; }
h3 { font-size: 1.15rem; font-weight: 700; }
p { margin: 0 0 1em; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid rgba(31, 111, 235, .35);
  outline-offset: 2px;
  border-radius: 8px;
}

.wrap { width: min(100% - 40px, var(--wrap)); margin-inline: auto; }
.skip {
  position: absolute; left: -9999px; top: 0; background: var(--ink); color: #fff;
  padding: 12px 18px; border-radius: 0 0 10px 0; z-index: 100;
}
.skip:focus { left: 0; }

/* ---------- header ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .86);
  backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid rgba(219, 228, 239, .8);
}
.topbar__inner { display: flex; align-items: center; gap: 20px; min-height: 68px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand__mark {
  width: 40px; height: 40px; border-radius: 12px; flex: none;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--accent), var(--teal));
  color: #fff; font-weight: 800; font-size: .95rem; letter-spacing: .04em;
}
.brand__text { display: flex; flex-direction: column; line-height: 1.2; }
.brand__text strong { font-size: 1rem; }
.brand__text small { color: var(--muted); font-size: .78rem; }

.nav { display: flex; gap: 4px; margin-left: auto; }
.nav a {
  color: var(--ink-soft); font-size: .95rem; font-weight: 500;
  padding: 8px 12px; border-radius: 10px;
}
.nav a:hover { background: var(--tint); text-decoration: none; color: var(--ink); }
.topbar__actions { display: flex; align-items: center; gap: 10px; }
.burger { display: none; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 600; line-height: 1;
  padding: 14px 22px; border-radius: 12px; border: 1px solid transparent;
  cursor: pointer; transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: none; }
.btn--primary { background: var(--accent); color: #fff; box-shadow: 0 8px 20px rgba(31, 111, 235, .25); }
.btn--primary:hover { background: var(--accent-dark); }
.btn--ghost { background: var(--ink); color: #fff; }
.btn--ghost:hover { background: #0a1929; }
.btn--line { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--line:hover { border-color: var(--ink); }
.btn--sm { padding: 10px 16px; font-size: .92rem; border-radius: 10px; }
.btn--block { width: 100%; }

/* ---------- hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(900px 420px at 85% -10%, rgba(15, 163, 163, .18), transparent 60%),
    radial-gradient(700px 380px at 10% 0%, rgba(31, 111, 235, .14), transparent 55%),
    linear-gradient(180deg, #f7faff 0%, #ffffff 70%);
  padding: clamp(40px, 7vw, 84px) 0 clamp(40px, 6vw, 72px);
  border-bottom: 1px solid var(--line);
}
.hero__inner {
  display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .85fr);
  gap: clamp(24px, 4vw, 56px); align-items: center;
}
.eyebrow {
  display: inline-block; margin: 0 0 12px;
  font-size: .8rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--teal);
}
.accent { color: var(--accent); }
.lead { font-size: clamp(1.02rem, 1.6vw, 1.18rem); color: var(--muted); max-width: 34em; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin: 26px 0 22px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0; }
.chips li {
  font-size: .85rem; font-weight: 600; color: var(--ink-soft);
  background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 7px 13px;
}

.hero__card {
  background: #fff; border: 1px solid var(--line); border-radius: 22px;
  padding: 26px; box-shadow: var(--shadow);
}
.hero__card-title { font-weight: 700; margin-bottom: 14px; }
.steps { list-style: none; padding: 0; margin: 0 0 18px; display: grid; gap: 10px; }
.steps li { display: flex; gap: 12px; align-items: flex-start; font-size: .96rem; color: var(--ink-soft); }
.steps span {
  flex: none; width: 26px; height: 26px; border-radius: 50%;
  display: grid; place-items: center; font-size: .8rem; font-weight: 700;
  background: var(--accent-soft); color: var(--accent);
}
.hero__note {
  display: grid; gap: 4px; padding: 14px 16px; border-radius: 14px;
  background: var(--tint); border: 1px dashed var(--line);
}
.hero__note strong { font-size: .98rem; }
.hero__note span { font-size: .88rem; color: var(--muted); }

/* ---------- sections ---------- */
.section { padding: clamp(48px, 7vw, 88px) 0; }
.section--tint { background: var(--tint); border-block: 1px solid var(--line); }
.section__lead { color: var(--muted); max-width: 46em; margin-bottom: 26px; }

.split { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(24px, 4vw, 48px); align-items: start; }
.split--form { grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); }

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

.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; box-shadow: var(--shadow);
}
.card--soft { background: linear-gradient(180deg, #fbfdff, #f4f8fd); }
.svc { display: flex; flex-direction: column; transition: box-shadow .18s ease, transform .18s ease; }
a.svc { color: inherit; text-decoration: none; }
a.svc:hover { text-decoration: none; }
.svc:hover { box-shadow: var(--shadow-hover); transform: translateY(-2px); }
.svc p { color: var(--muted); font-size: .95rem; flex: 1; }
.price {
  align-self: flex-start; margin-top: 6px;
  font-weight: 800; font-size: .95rem; color: var(--accent);
  background: var(--accent-soft); border-radius: 999px; padding: 6px 12px;
}
.card--link { display: grid; gap: 10px; color: var(--ink); }
.card--link:hover { text-decoration: none; box-shadow: var(--shadow-hover); transform: translateY(-2px); }
.card--link, .svc { will-change: transform; }
.card__go { color: var(--accent); font-weight: 600; font-size: .92rem; }

.ticks { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.ticks li { position: relative; padding-left: 28px; color: var(--ink-soft); font-size: .96rem; }
.ticks li::before {
  content: ""; position: absolute; left: 0; top: .35em;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--teal);
  clip-path: polygon(14% 44%, 0 65%, 40% 100%, 100% 16%, 84% 0%, 39% 62%);
}
.fineprint { color: var(--muted); font-size: .87rem; margin: 18px 0 0; }
.fineprint--center { text-align: center; }

/* ---------- referral ---------- */
.ref { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.ref__item {
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  padding: 12px 18px; font-weight: 600; color: var(--ink-soft);
  box-shadow: 0 1px 2px rgba(15, 33, 55, .04);
}

/* ---------- contacts ---------- */
.contact {
  display: grid; gap: 4px; padding: 20px 22px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  color: var(--ink); box-shadow: var(--shadow);
  transition: box-shadow .18s ease, transform .18s ease, border-color .18s ease;
}
.contact:hover { text-decoration: none; border-color: rgba(31, 111, 235, .35); box-shadow: var(--shadow-hover); transform: translateY(-2px); }
.contact__label { font-size: .78rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.contact__value { font-size: 1.08rem; font-weight: 650; }

/* ---------- form ---------- */
.form { display: grid; gap: 14px; padding: 24px; }
.form label { display: grid; gap: 6px; font-size: .9rem; font-weight: 600; color: var(--ink-soft); }
.form input, .form select, .form textarea {
  font: inherit; font-size: .98rem; color: var(--ink);
  padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px;
  background: #fbfdff; width: 100%;
  transition: border-color .15s ease, background .15s ease;
}
.form input:hover, .form select:hover, .form textarea:hover { border-color: #c3d0e0; }
.form input:focus, .form select:focus, .form textarea:focus { background: #fff; border-color: var(--accent); }
.form textarea { resize: vertical; min-height: 84px; }
.form .hp { position: absolute; left: -9999px; opacity: 0; height: 0; padding: 0; border: 0; }
.form__status { margin: 0; font-size: .92rem; font-weight: 600; min-height: 1.2em; }
.form__status.ok { color: #0b7a4b; }
.form__status.err { color: #c02626; }
.btn[disabled] { opacity: .6; cursor: progress; transform: none; }

/* ---------- footer ---------- */
.footer { border-top: 1px solid var(--line); background: #fff; padding: 26px 0; }
.footer__inner { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; }
.footer p { margin: 0; color: var(--muted); font-size: .9rem; }
.footer__links { display: flex; gap: 18px; }
.footer__links a { color: var(--muted); }
.footer__links a:hover { color: var(--ink); }

/* ---------- responsive ---------- */
@media (max-width: 960px) {
  .hero__inner, .split, .split--form { grid-template-columns: 1fr; }
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .nav {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; gap: 2px; padding: 12px 20px 18px;
    background: #fff; border-bottom: 1px solid var(--line);
    box-shadow: 0 18px 30px rgba(15, 33, 55, .08);
    display: none;
  }
  .nav.is-open { display: flex; }
  .nav a { padding: 12px; font-size: 1rem; }
  .topbar { position: sticky; }
  .topbar__inner { position: relative; }
  .burger {
    display: inline-grid; gap: 4px; place-content: center;
    width: 42px; height: 42px; border-radius: 10px;
    background: #fff; border: 1px solid var(--line); cursor: pointer;
  }
  .burger span { display: block; width: 18px; 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(6px) rotate(45deg); }
  .burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
  .brand__text small { display: none; }
}

@media (max-width: 620px) {
  body { font-size: 16px; }
  h1 { font-size: 1.6rem; }
  .grid--3, .grid--2 { grid-template-columns: 1fr; }
  .hero { padding-top: 28px; }
  .hero__card { padding: 20px; }
  .hero__cta .btn { width: 100%; }
  .topbar__actions .btn--ghost { display: none; }
  .footer__inner { flex-direction: column; align-items: flex-start; }
}

/* ---------- страницы услуг ---------- */
.page { padding: clamp(28px, 5vw, 56px) 0 clamp(48px, 7vw, 84px); }
.crumbs { font-size: .85rem; color: var(--muted); margin-bottom: 18px; display: flex; gap: 8px; flex-wrap: wrap; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--accent); }
.article { max-width: 820px; }
.article > h1 { margin-bottom: .4em; }
.article h2 { margin: 1.9em 0 .6em; font-size: clamp(1.25rem, 2.6vw, 1.6rem); }
.article p, .article li { color: var(--ink-soft); }
.article a { text-decoration: underline; text-decoration-color: rgba(31,111,235,.35); text-underline-offset: 3px; }
.article a:hover { text-decoration-color: var(--accent); }
.list { padding-left: 1.2em; margin: 0 0 1.2em; display: grid; gap: .45em; }
.list--num { padding-left: 1.4em; }
.price-table { width: 100%; border-collapse: collapse; margin: 0 0 1.2em; font-size: .97rem; }
.price-table th, .price-table td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.price-table th { background: var(--tint); font-weight: 700; }
.price-table td:last-child { font-weight: 700; white-space: nowrap; }
.faq { display: grid; gap: 10px; margin-bottom: 1.4em; }
.faq details { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 0 18px; }
.faq summary { cursor: pointer; font-weight: 650; padding: 15px 0; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--accent); font-weight: 700; font-size: 1.2rem; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: 0 0 16px; color: var(--muted); font-size: .96rem; }
.cta-box {
  display: flex; flex-wrap: wrap; gap: 20px; align-items: center; justify-content: space-between;
  background: linear-gradient(135deg, #f2f7ff, #eefafa);
  border: 1px solid var(--line); border-radius: 18px; padding: 26px; margin-top: 2.2em;
}
.cta-box h2 { margin: 0 0 6px; font-size: 1.3rem; }
.cta-box p { margin: 0; color: var(--muted); font-size: .95rem; }
.cta-box__actions { display: flex; flex-wrap: wrap; gap: 10px; }
@media (max-width: 620px) {
  .cta-box { padding: 20px; }
  .cta-box__actions .btn { width: 100%; }
  .price-table th, .price-table td { padding: 10px 8px; font-size: .92rem; }
}
