@font-face {
  font-family: "Onest";
  src: url("fonts/onest-cyrillic.woff2") format("woff2");
  font-weight: 400 800;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Onest";
  src: url("fonts/onest-latin.woff2") format("woff2");
  font-weight: 400 800;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Onest";
  src: url("fonts/onest-latin-ext.woff2") format("woff2");
  font-weight: 400 800;
  font-display: swap;
  unicode-range: U+20BD;
}

:root {
  --bg: #F7F7F9;
  --ink: #17171C;
  --muted: #5B5B66;
  --faint: #8A8A97;
  --line: #ECECF1;
  --line-strong: #E3E3EC;
  --accent: #4C4DDC;
  --accent-dark: #3A3BC0;
  --accent-soft: #E9E9FB;
  --night: #17163A;
  --night-muted: #C9C9DE;
  --night-accent: #A5A6F6;
  --shadow: 0 2px 12px rgba(23, 23, 28, .05);
  --section: clamp(40px, 6vw, 80px);
  color-scheme: light;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  font-family: "Onest", sans-serif;
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dark); }
a:focus-visible, button:focus-visible { outline: 3px solid var(--night-accent); outline-offset: 3px; }
input, textarea, button { font-family: inherit; }
img { display: block; }
h1, h2, p { margin: 0; }

@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: 0 50%;
  z-index: 50;
}

.page { max-width: 1240px; margin: 0 auto; padding: 0 clamp(20px, 5vw, 40px); }

.btn {
  display: inline-block;
  border-radius: 999px;
  font-weight: 700;
  background: var(--accent);
  color: #FFFFFF;
}
.btn:hover { background: var(--accent-dark); color: #FFFFFF; }
.btn-lg { padding: 18px 40px; font-size: 18px; }
.btn-md { padding: 16px 34px; font-size: 17px; white-space: nowrap; }
.btn-outline { padding: 16px 38px; font-size: 18px; background: #FFFFFF; color: var(--ink); border: 2px solid var(--line-strong); }
.btn-outline:hover { background: #FFFFFF; border-color: var(--accent); color: var(--accent); }

.eyebrow { font-size: 15px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.heading { font-size: clamp(28px, 3.6vw, 44px); font-weight: 800; letter-spacing: -0.02em; line-height: 1.2; }
.section { padding: var(--section) 0; display: flex; flex-direction: column; gap: 44px; }
.section-head { display: flex; flex-direction: column; gap: 14px; }
.card { background: #FFFFFF; border-radius: 28px; padding: 36px; display: flex; flex-direction: column; box-shadow: var(--shadow); }
.card-night { background: var(--night); color: #FFFFFF; box-shadow: none; }

.site-header { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 28px 0; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 14px; }
.brand img { width: 48px; height: 48px; border-radius: 50%; }
.brand span { font-size: 19px; font-weight: 800; }
.nav { display: flex; align-items: center; gap: clamp(16px, 2.5vw, 32px); flex-wrap: wrap; }
.nav > a:not(.btn) { font-size: 17px; font-weight: 600; color: var(--muted); }
.nav > a:not(.btn):hover { color: var(--accent); }
.nav .btn { padding: 12px 26px; font-size: 17px; }

.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr));
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
  padding: clamp(48px, 7vw, 90px) 0;
}
.hero-copy { display: flex; flex-direction: column; gap: 28px; }
.hero h1 { font-size: clamp(38px, 5.2vw, 62px); font-weight: 800; line-height: 1.08; letter-spacing: -0.02em; text-wrap: pretty; }
.hero h1 .tint { color: var(--accent); }
.hero-lead { font-size: clamp(18px, 2vw, 22px); font-weight: 500; color: var(--muted); line-height: 1.5; max-width: 560px; }
.hero-actions, .chips { display: flex; gap: 16px; flex-wrap: wrap; }
.chips { gap: 12px; padding-top: 8px; }
.chip { background: #FFFFFF; border-radius: 999px; padding: 10px 22px; font-size: 16px; font-weight: 700; box-shadow: var(--shadow); }
.chip-tint { background: var(--accent-soft); color: var(--accent); box-shadow: none; }
.stage {
  position: relative;
  background: var(--accent);
  border-radius: 36px;
  padding: clamp(32px, 4vw, 52px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  color: #FFFFFF;
  text-align: center;
  overflow: hidden;
  min-height: clamp(400px, 44vw, 520px);
}
.stage img {
  width: clamp(140px, 18vw, 190px);
  height: clamp(140px, 18vw, 190px);
  border-radius: 50%;
  border: 8px solid rgba(255, 255, 255, .32);
  box-shadow: 0 20px 60px rgba(20, 20, 60, .35);
}
.stage-title { font-size: clamp(24px, 3vw, 32px); font-weight: 800; line-height: 1.2; }
.stage-sub { font-size: 18px; font-weight: 600; color: #DEDEFF; }

.about h2 { max-width: 900px; }
.about p { font-size: clamp(17px, 1.8vw, 21px); color: var(--muted); line-height: 1.55; max-width: 820px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; }
.stat { background: #FFFFFF; border-radius: 24px; padding: 32px; display: flex; flex-direction: column; gap: 8px; box-shadow: var(--shadow); }
.stat-value { font-size: clamp(34px, 4vw, 46px); font-weight: 800; color: var(--accent); }
.stat-label { font-size: 17px; color: var(--muted); }
.clients { display: flex; flex-direction: column; gap: 18px; }
.clients-label { font-size: 17px; font-weight: 600; color: var(--faint); }
.marquee { background: var(--accent); color: #FFFFFF; border-radius: 28px; padding: clamp(22px, 2.6vw, 32px) 0; overflow: hidden; }
.marquee-track {
  display: flex;
  gap: clamp(40px, 6vw, 80px);
  width: max-content;
  padding-left: clamp(40px, 6vw, 80px);
  animation: marquee 26s linear infinite;
}
.marquee-track span { font-size: clamp(26px, 3vw, 38px); font-weight: 800; }

.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(270px, 100%), 1fr)); gap: 24px; }
.service { gap: 18px; }
.service-meta { font-size: 15px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }
.service-title { font-size: 26px; font-weight: 800; line-height: 1.2; }
.service-lead { font-size: 17px; color: var(--muted); line-height: 1.45; flex: 1; }
.service-list { border-top: 2px solid var(--line); padding-top: 18px; display: flex; flex-direction: column; gap: 10px; }
.service-list span { font-size: 16px; line-height: 1.35; }
.card-night .service-meta { color: var(--night-accent); }
.card-night .service-lead { color: var(--night-muted); }
.card-night .service-list { border-top-color: rgba(255, 255, 255, .18); }

.prices { padding: 12px clamp(24px, 3vw, 36px); }
.price-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 32px;
  flex-wrap: wrap;
  padding: 24px 0;
  border-bottom: 2px solid var(--line);
}
.price-row:last-child { border-bottom: 0; }
.price-name { font-size: clamp(19px, 2vw, 23px); font-weight: 800; line-height: 1.25; }
.price-value { font-size: clamp(26px, 3vw, 36px); font-weight: 800; color: var(--accent); white-space: nowrap; }
.note {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  background: var(--accent-soft);
  border-radius: 24px;
  padding: 28px 36px;
  flex-wrap: wrap;
}
.note span { flex: 1 1 320px; font-size: 19px; font-weight: 600; color: var(--accent-dark); line-height: 1.4; }

.process {
  padding: var(--section) 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}
.process-head { position: sticky; top: 60px; display: flex; flex-direction: column; gap: 18px; }
.process-head h2 { line-height: 1.15; }
.process-head p { font-size: 18px; color: var(--muted); line-height: 1.55; max-width: 380px; }
.steps { display: flex; flex-direction: column; gap: 20px; }
.step { gap: 14px; }
.step-num { font-size: 44px; font-weight: 800; color: var(--accent); }
.step-title { font-size: 23px; font-weight: 800; }
.step-text { font-size: 17px; color: var(--muted); line-height: 1.5; }
.card-night .step-num { color: var(--night-accent); }
.card-night .step-text { color: var(--night-muted); }

.cases-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); gap: 24px; }
.case { padding: clamp(28px, 3.5vw, 44px); gap: 20px; }
.case-role { font-size: 15px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--night-accent); }
.case-result { font-size: clamp(28px, 3.4vw, 40px); font-weight: 800; line-height: 1.15; }
.case-text { font-size: 17px; color: var(--night-muted); line-height: 1.5; }

.telegram { padding: var(--section) 0; }
.telegram-panel {
  background: var(--accent);
  color: #FFFFFF;
  border-radius: 36px;
  padding: clamp(32px, 4.5vw, 64px);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
}
.telegram-copy { display: flex; flex-direction: column; gap: 20px; }
.telegram-copy .eyebrow { color: #D9D9FB; }
.telegram-copy h2 { font-size: clamp(26px, 3.2vw, 40px); font-weight: 800; line-height: 1.2; }
.telegram-copy a { background: #FFFFFF; color: var(--accent); border-radius: 999px; padding: 16px 36px; font-size: 18px; font-weight: 800; align-self: flex-start; }
.telegram-copy a:hover { background: var(--accent-soft); color: var(--accent-dark); }
.qr-wrap { display: flex; justify-content: center; }
.qr { background: #FFFFFF; border-radius: 32px; padding: 28px 28px 20px; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.qr img { width: clamp(160px, 20vw, 220px); height: auto; }
.qr span { font-size: 16px; font-weight: 800; color: var(--night); letter-spacing: .06em; }

.faq { gap: 36px; }
.faq-list { display: flex; flex-direction: column; gap: 16px; }
.faq-item { background: #FFFFFF; border-radius: 20px; padding: 28px 32px; display: flex; flex-direction: column; gap: 10px; box-shadow: 0 2px 12px rgba(23, 23, 28, .04); }
.faq-q { font-size: 20px; font-weight: 800; }
.faq-a { font-size: 17px; color: var(--muted); line-height: 1.5; }

.contact { padding: var(--section) 0 clamp(56px, 7vw, 100px); }
.contact-panel {
  background: var(--night);
  color: #FFFFFF;
  border-radius: 36px;
  padding: clamp(32px, 4.5vw, 64px);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  gap: clamp(28px, 4vw, 56px);
}
.contact-copy { display: flex; flex-direction: column; gap: 20px; }
.contact-copy .eyebrow { color: var(--night-accent); }
.contact-copy h2 { font-size: clamp(26px, 3.2vw, 40px); font-weight: 800; line-height: 1.2; }
.contact-copy p { font-size: 18px; color: var(--night-muted); line-height: 1.55; }
.person { display: flex; align-items: center; gap: 16px; padding-top: 8px; }
.person img { width: 56px; height: 56px; border-radius: 50%; }
.person div { display: flex; flex-direction: column; gap: 2px; }
.person span { font-size: 17px; font-weight: 800; }
.person a { font-size: 16px; font-weight: 600; color: var(--night-accent); }
.form { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.field {
  width: 100%;
  background: rgba(255, 255, 255, .08);
  border: 2px solid rgba(255, 255, 255, .18);
  border-radius: 16px;
  padding: 18px 22px;
  font-size: 17px;
  color: #FFFFFF;
  outline: none;
}
.field::placeholder { color: var(--night-muted); opacity: 1; }
.field:focus { border-color: var(--night-accent); }
textarea.field { resize: vertical; }
.submit { background: var(--accent); color: #FFFFFF; border: 0; border-radius: 999px; padding: 20px 36px; font-size: 18px; font-weight: 800; cursor: pointer; }
.submit:hover { background: #5F60E8; }
.form-note { font-size: 14px; color: #A9A9C4; line-height: 1.4; }

.site-footer { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px 40px; padding: 32px 0 48px; border-top: 2px solid var(--line-strong); flex-wrap: wrap; }
.footer-info { display: flex; flex-direction: column; gap: 8px; }
.footer-info span { font-size: 16px; color: #6F6F7C; line-height: 1.4; }
.footer-links { display: flex; gap: 8px 28px; flex-wrap: wrap; }
.footer-links a { font-size: 16px; font-weight: 700; line-height: 1.4; }
.projects-link {
  padding: 0;
  background: none;
  border: 0;
  color: var(--accent);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.4;
  cursor: pointer;
}
.projects-link:hover { color: var(--accent-dark); }

@keyframes dialog-in { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

html:has(.projects-dialog[open]) { overflow: hidden; }
.projects-dialog {
  width: min(720px, calc(100vw - 32px));
  max-height: calc(100dvh - 32px);
  padding: clamp(24px, 4vw, 40px);
  border: 0;
  border-radius: 28px;
  background: var(--bg);
  color: var(--ink);
  box-shadow: 0 20px 60px rgba(20, 20, 60, .35);
}
.projects-dialog[open] { animation: dialog-in .25s ease-out; }
.projects-dialog::backdrop { background: rgba(23, 22, 58, .6); }
.projects-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 28px; }
.projects-close {
  display: flex;
  flex-shrink: 0;
  padding: 12px;
  background: #FFFFFF;
  border: 2px solid var(--line-strong);
  border-radius: 50%;
  color: var(--ink);
  cursor: pointer;
}
.projects-close:hover { border-color: var(--accent); color: var(--accent); }
.projects-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); gap: 20px; }
.project {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #FFFFFF;
  border: 2px solid transparent;
  border-radius: 24px;
  color: var(--ink);
  box-shadow: var(--shadow);
}
.project:hover { border-color: var(--accent); color: var(--ink); }
.project img { width: 100%; height: auto; }
.project-body { display: flex; flex-direction: column; gap: 10px; padding: 24px; }
.project-name { font-size: 23px; font-weight: 800; }
.project-text { font-size: 17px; color: var(--muted); line-height: 1.5; }
.project-action { padding-top: 4px; font-size: 17px; font-weight: 700; color: var(--accent); }
.legal { flex-basis: 100%; }

@media (prefers-reduced-motion: reduce) {
  .marquee-track { animation: none; }
  .projects-dialog[open] { animation: none; }
}
