/* ===== Палитра ===== */
:root, [data-theme="light"] {
  --bg: #FFFFFF;
  --bg-alt: #F4F7FA;
  --card: #FFFFFF;
  --card-border: #E2E8F0;
  --text: #1E293B;
  --muted: #475569;          /* 7.6:1 на белом */
  --primary: #0EA5E9;        /* иконки, плашки, декор */
  --primary-text: #0369A1;   /* цены и акценты текстом: #0EA5E9 на белом = 2.8:1, не проходит AA */
  --primary-soft: rgba(14,165,233,.12);
  --accent: #F97316;         /* кнопки CTA */
  --accent-ink: #1E293B;     /* текст на оранжевом: 5.2:1 (белый = 2.8:1) */
  --accent-text: #C2410C;    /* оранжевый текстом на белом: 5.2:1 */
  --accent-glow: rgba(249,115,22,.45);
  --hero-bg: radial-gradient(1200px 600px at 85% -10%, rgba(14,165,233,.22), transparent 60%),
             radial-gradient(900px 500px at -10% 110%, rgba(249,115,22,.12), transparent 60%),
             linear-gradient(180deg, #F4F7FA 0%, #FFFFFF 100%);
  --header-bg: rgba(255,255,255,.82);
  --shadow: 0 10px 30px -12px rgba(15,23,42,.18), 0 2px 6px rgba(15,23,42,.05);
  --shadow-hover: 0 24px 50px -18px rgba(14,165,233,.45);
  --footer-bg: #1E293B;
  --footer-text: #E2E8F0;
  --bubble: 14,165,233;
  --bubble-core: .55;
  color-scheme: light;
}
[data-theme="dark"] {
  --bg: #0B1120;
  --bg-alt: #0F172A;
  --card: #1E293B;
  --card-border: rgba(56,189,248,.14);
  --text: #F8FAFC;
  --muted: #CBD5E1;          /* 9.9:1 на #1E293B */
  --primary: #38BDF8;
  --primary-text: #38BDF8;   /* 8.8:1 на #0B1120, 6.8:1 на #1E293B */
  --primary-soft: rgba(56,189,248,.12);
  --accent: #FB923C;
  --accent-ink: #0B1120;     /* 8.3:1 */
  --accent-text: #FB923C;
  --accent-glow: rgba(251,146,60,.5);
  --hero-bg: radial-gradient(1200px 600px at 85% -10%, rgba(56,189,248,.20), transparent 60%),
             radial-gradient(900px 500px at -10% 110%, rgba(251,146,60,.10), transparent 60%),
             linear-gradient(180deg, #0B1120 0%, #0B1120 100%);
  --header-bg: rgba(11,17,32,.78);
  --shadow: 0 10px 30px -12px rgba(0,0,0,.6);
  --shadow-hover: 0 24px 50px -18px rgba(56,189,248,.45), 0 0 0 1px rgba(56,189,248,.35);
  --footer-bg: #060A14;
  --footer-text: #CBD5E1;
  --bubble: 56,189,248;
  --bubble-core: .10;
  color-scheme: dark;
}

/* ===== База ===== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
html, body { overflow-x: hidden; }
body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 17px; line-height: 1.55;
  background: var(--bg); color: var(--text);
}
/* плавная смена темы */
body, .header, .card, .section, .hero, .contacts, .footer, .btn, .chip, .row, .theme-toggle {
  transition: background-color .45s ease, color .45s ease, border-color .45s ease, box-shadow .35s ease;
}
h1, h2, h3 { line-height: 1.15; margin: 0; letter-spacing: -.01em; }
p { margin: 0; }
a { color: inherit; }
ul, ol { margin: 0; padding: 0; list-style: none; }
.container { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.ico { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ===== Кнопки ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 700; text-decoration: none; white-space: nowrap;
  padding: 12px 22px; border-radius: 999px; border: 2px solid transparent; cursor: pointer;
  transition: transform .2s ease, box-shadow .3s ease, background-color .45s, color .45s, border-color .45s;
}
.btn:active { transform: scale(.97); }
.btn--sm { padding: 8px 16px; font-size: 15px; }
.btn--xl { padding: 18px 38px; font-size: 19px; }
.btn--accent { background: var(--accent); color: var(--accent-ink); }
.btn--accent:hover { box-shadow: 0 10px 28px -6px var(--accent-glow); transform: translateY(-2px); }
.btn--ghost { color: var(--primary-text); border-color: var(--primary); background: transparent; }
.btn--ghost:hover { background: var(--primary-soft); }
.btn--outline { color: var(--text); border-color: var(--card-border); background: transparent; }
.btn--outline:hover { border-color: var(--primary); color: var(--primary-text); }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 3px; }

/* «дыхание» CTA */
.btn--pulse { position: relative; animation: breathe 2.6s ease-in-out infinite; }
.btn--pulse::after {
  content: ""; position: absolute; inset: -2px; border-radius: inherit;
  box-shadow: 0 0 0 0 var(--accent-glow); animation: ring 2.6s ease-out infinite; pointer-events: none;
}
@keyframes breathe { 0%,100% { transform: scale(1); } 50% { transform: scale(1.045); } }
@keyframes ring { 0% { box-shadow: 0 0 0 0 var(--accent-glow); } 70%,100% { box-shadow: 0 0 0 18px rgba(0,0,0,0); } }

/* ===== Шапка ===== */
.header {
  position: sticky; top: 0; z-index: 50;
  background: var(--header-bg); backdrop-filter: saturate(160%) blur(12px); -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--card-border);
}
.header__inner { display: flex; align-items: center; gap: 20px; height: 68px; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 800; font-size: 20px; }
.logo__mark { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--primary); }
.logo__mark svg { width: 22px; height: 22px; fill: #fff; stroke: none; }
.logo__spark { fill: none !important; stroke: var(--primary); stroke-width: 2; stroke-linecap: round; }
.logo__text { display: flex; flex-direction: column; line-height: 1.05; }
.logo__text small { font-size: 11px; font-weight: 500; color: var(--muted); }
.header__phone { margin-left: auto; font-weight: 700; text-decoration: none; color: var(--text); white-space: nowrap; }
.header__phone::after { content: " · заглушка"; font-weight: 400; font-size: 12px; color: var(--muted); }
.header__actions { display: flex; align-items: center; gap: 10px; }
.theme-toggle {
  width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--card-border); background: var(--card);
  color: var(--primary-text); cursor: pointer; display: grid; place-items: center; position: relative; overflow: hidden;
}
.theme-toggle .ico { position: absolute; transition: transform .5s cubic-bezier(.6,-0.3,.3,1.4), opacity .3s; }
[data-theme="light"] .ico--moon, [data-theme="dark"] .ico--sun { transform: translateY(30px) rotate(90deg); opacity: 0; }
.show-xs { display: none; }

/* ===== Первый экран ===== */
.hero { position: relative; overflow: hidden; background: var(--hero-bg); padding: 72px 0 84px; isolation: isolate; }
.hero__bubbles { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
.hero__shine {
  position: absolute; inset: 0; pointer-events: none; z-index: 2;
  background: linear-gradient(105deg, transparent 35%, rgba(255,255,255,.0) 40%, rgba(255,255,255,.55) 48%, rgba(255,255,255,.85) 50%, rgba(255,255,255,.55) 52%, transparent 60%);
  transform: translateX(-120%); mix-blend-mode: soft-light;
}
[data-theme="dark"] .hero__shine { mix-blend-mode: overlay; }
.hero.is-shining .hero__shine { animation: shine 1.6s cubic-bezier(.4,0,.2,1) forwards; }
@keyframes shine { to { transform: translateX(120%); } }
.hero__inner { position: relative; text-align: center; }
.hero__kicker {
  display: inline-block; font-size: 14px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  color: var(--primary-text); background: var(--primary-soft); padding: 6px 14px; border-radius: 999px; margin-bottom: 20px;
}
.hero__title { font-size: clamp(34px, 6vw, 68px); font-weight: 900; max-width: 920px; margin: 0 auto; text-wrap: balance; }
.hero__title .w { display: inline-block; white-space: nowrap; }
.hero__title .ch { display: inline-block; opacity: 0; transform: translateY(.5em) rotateX(-90deg) scale(.6); filter: blur(6px); }
.hero__title.is-typed .ch { animation: chIn .55s cubic-bezier(.2,.9,.3,1.3) forwards; animation-delay: calc(var(--i) * 32ms); }
@keyframes chIn { to { opacity: 1; transform: none; filter: none; } }
.hero__title .accent { color: var(--primary-text); }
.hero__lead { margin: 20px auto 0; max-width: 46ch; font-size: 19px; color: var(--muted); }

.adv { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin: 44px auto 40px; max-width: 980px; text-align: left; }
.adv__card { display: flex; gap: 16px; align-items: flex-start; padding: 22px; }
.adv__card h3 { font-size: 20px; margin-bottom: 4px; }
.adv__card p { color: var(--muted); font-size: 16px; }
.adv__icon, .plan__icon {
  flex: none; width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center;
  background: var(--primary-soft); color: var(--primary);
}
.adv__icon svg, .plan__icon svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
[data-theme="dark"] .adv__icon, [data-theme="dark"] .plan__icon { box-shadow: 0 0 18px -4px rgba(56,189,248,.6); }
.hero__cta { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.hero__more { color: var(--primary-text); font-weight: 600; text-decoration: none; }

/* ===== Карточки ===== */
.card {
  background: var(--card); border: 1px solid var(--card-border); border-radius: 20px; box-shadow: var(--shadow);
}
.tilt { transform-style: preserve-3d; will-change: transform; }
.tilt.is-tilting { transition: transform .08s linear, box-shadow .3s; box-shadow: var(--shadow-hover); }
.tilt .tilt__glare {
  position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .3s;
  background: radial-gradient(circle at var(--gx,50%) var(--gy,50%), rgba(255,255,255,.35), transparent 55%);
}
.tilt.is-tilting .tilt__glare { opacity: 1; }
.tilt { position: relative; }

/* появление при прокрутке */
.js .reveal { opacity: 0; transform: translateY(40px) scale(.96); }
.js .reveal.is-in {
  opacity: 1; transform: none;
  transition: opacity .7s ease, transform .8s cubic-bezier(.2,.8,.2,1.15);
  transition-delay: var(--d, 0ms);
}
.js .tilt.reveal.is-in.is-tilting { transition: transform .08s linear, box-shadow .3s; transition-delay: 0ms; }

/* ===== Секции ===== */
.section { padding: 88px 0; background: var(--bg); }
.section--alt { background: var(--bg-alt); }
.section__head { text-align: center; margin-bottom: 44px; }
.section__tag {
  display: inline-block; font-size: 13px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent-text); margin-bottom: 10px;
}
.section__head h2 { font-size: clamp(28px, 4vw, 44px); font-weight: 900; }
.section__note {
  display: inline-block; margin-top: 14px; padding: 6px 14px; border-radius: 999px;
  background: var(--primary-soft); color: var(--text); font-size: 15px;
}

/* тарифы */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; align-items: stretch; }
.plan { padding: 32px 28px; display: flex; flex-direction: column; gap: 14px; }
.plan h3 { font-size: 23px; }
.plan__desc { color: var(--muted); flex: 1; }
.plan__price { font-size: 54px; font-weight: 900; color: var(--primary-text); line-height: 1; font-variant-numeric: tabular-nums; white-space: nowrap; }
.plan__price small { font-size: 20px; font-weight: 700; color: var(--muted); margin-left: 4px; }
[data-theme="dark"] .plan__price { text-shadow: 0 0 24px rgba(56,189,248,.45); }
.plan .btn { align-self: flex-start; }
.plan--hot { border: 2px solid var(--accent); }
.plan__badge {
  position: absolute; top: -14px; right: 24px; background: var(--accent); color: var(--accent-ink);
  font-size: 13px; font-weight: 800; padding: 4px 12px; border-radius: 999px;
}

/* прайс строками */
.price-list { max-width: 860px; margin: 0 auto; padding: 10px 32px; }
.price-list__legend {
  display: grid; grid-template-columns: 1fr 150px 150px; gap: 16px; padding: 14px 0 6px;
  font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); text-align: right;
}
.price-list__sep { height: 18px; }
.row {
  display: grid; grid-template-columns: 1fr auto; gap: 16px; align-items: center;
  padding: 18px 0; border-bottom: 1px dashed var(--card-border);
}
.row:last-child { border-bottom: 0; }
.row--dual { grid-template-columns: 1fr 150px 150px; }
.row__name { font-weight: 700; font-size: 18px; }
.row__name small { display: block; font-weight: 400; font-size: 14px; color: var(--muted); }
.row__price, .row__opt b { font-weight: 800; font-size: 21px; color: var(--primary-text); white-space: nowrap; text-align: right; font-variant-numeric: tabular-nums; }
.row__opt { text-align: right; }
.row__label { display: none; }
.row__extra {
  grid-column: 1 / -1; font-size: 15px; color: var(--text);
  background: var(--primary-soft); border-radius: 10px; padding: 8px 12px; margin-top: -4px;
}
.row__extra b { color: var(--accent-text); }

/* шаги */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; counter-reset: s; position: relative; }
.step { padding: 30px 26px; }
.step__num {
  display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%;
  background: var(--accent); color: var(--accent-ink); font-weight: 900; font-size: 24px; margin-bottom: 18px;
  box-shadow: 0 0 0 8px var(--primary-soft);
}
.step h3 { font-size: 21px; margin-bottom: 8px; }
.step p { color: var(--muted); }

/* контакты */
.contacts { padding: 88px 0; background: var(--footer-bg); color: #F8FAFC; position: relative; overflow: hidden; }
.contacts::before {
  content: ""; position: absolute; width: 600px; height: 600px; right: -200px; top: -250px; border-radius: 50%;
  background: radial-gradient(circle, rgba(56,189,248,.25), transparent 65%); pointer-events: none;
}
.contacts__inner { display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px; align-items: center; position: relative; }
.contacts h2 { font-size: clamp(30px, 4vw, 46px); font-weight: 900; margin-bottom: 14px; }
.contacts__text p { color: #CBD5E1; margin-bottom: 28px; font-size: 19px; }
.contacts .btn--accent { background: var(--accent); }
.contacts__list { display: grid; gap: 18px; }
.contacts__list li { display: flex; flex-direction: column; gap: 4px; padding-bottom: 16px; border-bottom: 1px solid rgba(255,255,255,.12); }
.contacts__list a { text-decoration: none; font-weight: 700; font-size: 20px; }
.contacts__label { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: #7DD3FC; font-weight: 700; }
.contacts__list em { font-size: 13px; color: #94A3B8; font-style: normal; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { padding: 6px 14px; border-radius: 999px; border: 1px solid rgba(125,211,252,.5); font-size: 15px !important; }
.chip:hover { background: rgba(125,211,252,.12); }

.footer { background: var(--footer-bg); color: var(--footer-text); border-top: 1px solid rgba(255,255,255,.08); font-size: 14px; }
.footer__inner { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 22px 24px; }

/* ===== Адаптив ===== */
@media (max-width: 960px) {
  .adv, .plans, .steps { grid-template-columns: 1fr; }
  .adv { max-width: 520px; }
  .plans, .steps { max-width: 520px; margin: 0 auto; }
  .contacts__inner { grid-template-columns: 1fr; }
  .header__phone { display: none; }
  .header__actions { margin-left: auto; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .container { padding: 0 16px; }
  .header__inner { height: 60px; gap: 10px; }
  .logo { font-size: 18px; }
  .logo__mark { width: 32px; height: 32px; }
  .logo__text small { display: none; }
  .header__actions { gap: 6px; }
  .hide-xs { display: none; }
  .show-xs { display: block; }
  .btn--ghost.btn--sm { padding: 8px; width: 38px; height: 38px; }
  .btn--sm { padding: 8px 12px; }
  .theme-toggle { width: 38px; height: 38px; }
  .hero { padding: 44px 0 56px; }
  .hero__kicker { font-size: 11px; letter-spacing: .03em; padding: 5px 12px; }
  .hero__lead { font-size: 17px; }
  .adv { margin: 30px auto 30px; gap: 12px; }
  .adv__card { padding: 16px; }
  .btn--xl { padding: 16px 28px; font-size: 18px; width: 100%; max-width: 340px; }
  .section, .contacts { padding: 60px 0; }
  .section__head { margin-bottom: 30px; }
  .plan { padding: 26px 22px; }
  .plan__price { font-size: 46px; }
  .price-list { padding: 4px 18px; }
  .price-list__legend { display: none; }
  .row--dual { grid-template-columns: 1fr 1fr; row-gap: 10px; }
  .row--dual .row__name { grid-column: 1 / -1; }
  .row__opt {
    text-align: left; background: var(--bg-alt); border-radius: 12px; padding: 8px 12px;
    display: flex; flex-direction: column;
  }
  [data-theme="dark"] .row__opt { background: rgba(56,189,248,.07); }
  .row__opt b { text-align: left; font-size: 20px; }
  .row__label { display: block; font-size: 12px; color: var(--muted); font-weight: 600; }
  .row__extra { margin-top: 0; }
  .row__name { font-size: 17px; }
  .row__price { font-size: 19px; }
  .footer__inner { padding: 20px 16px; flex-direction: column; }
}

/* ===== Без анимаций ===== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
.no-motion *, .no-motion *::before, .no-motion *::after { animation: none !important; transition: none !important; }
.no-motion .hero__title .ch, .no-motion .reveal { opacity: 1 !important; transform: none !important; filter: none !important; }
