:root {
  --black: #0e0e10;
  --black-2: #17171a;
  --black-3: #222226;
  --gold: #c9a24a;
  --gold-light: #e8cd86;
  --gold-dark: #9c7a2c;
  --ivory: #f6f3ec;
  --paper: #ffffff;
  --ink: #1d1d20;
  --muted: #5d5d66;
  --muted-dark: #a9a6a0;
  --line: #e4ded1;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(14, 14, 16, .08);
  --font-head: "Montserrat", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body { margin: 0; font: 400 1.0625rem/1.65 var(--font-body); color: var(--ink); background: var(--paper); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--font-head); line-height: 1.2; margin: 0 0 .6em; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 4px; }

.container { width: min(1180px, 100% - 2.5rem); margin-inline: auto; }
.narrow { max-width: 820px; }
.skip { position: absolute; left: -999px; top: 0; background: var(--gold); color: var(--black); padding: .5rem 1rem; z-index: 100; }
.skip:focus { left: 1rem; }

mark.todo { background: #ffe66d; color: #3a3000; padding: .05em .4em; border-radius: 4px; font-size: .85em; font-weight: 600; }
.draft-bar { background: #ffe66d; color: #3a3000; text-align: center; font-size: .85rem; padding: .35rem 1rem; }
.draft-bar mark.todo { background: #fff6b8; }

/* Кнопки */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: .75rem 1.5rem; border-radius: 999px; font: 600 1rem var(--font-head); text-decoration: none; border: 1.5px solid transparent; cursor: pointer; transition: transform .15s ease, box-shadow .15s ease, background .15s ease; }
.btn:hover { transform: translateY(-1px); }
.btn--gold { background: linear-gradient(135deg, var(--gold-light), var(--gold) 55%, var(--gold-dark)); color: var(--black); box-shadow: 0 6px 18px rgba(201, 162, 74, .35); }
.btn--ghost { border-color: var(--gold); color: var(--gold-light); background: transparent; }
.btn--dark { background: var(--black); color: var(--gold-light); }

/* Шапка */
.header { position: sticky; top: 0; z-index: 50; background: rgba(14, 14, 16, .96); backdrop-filter: blur(8px); border-bottom: 1px solid rgba(201, 162, 74, .25); }
.header__inner { display: flex; align-items: center; gap: 1.5rem; min-height: 72px; }
.brand { display: flex; align-items: center; gap: .75rem; text-decoration: none; color: var(--gold-light); margin-right: auto; }
.brand__pulse { width: 46px; height: 24px; flex: none; }
.brand__pulse polyline, .hero__pulse polyline { fill: none; stroke: var(--gold); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.brand__text { display: flex; flex-direction: column; font-family: var(--font-head); line-height: 1.15; }
.brand__line { font-size: .72rem; letter-spacing: .06em; text-transform: uppercase; font-weight: 600; }
.brand__name { font-size: .95rem; letter-spacing: .18em; text-transform: uppercase; font-weight: 700; }
.nav { display: flex; gap: 1.4rem; }
.nav a { color: #e9e6df; text-decoration: none; font-size: .95rem; font-weight: 500; }
.nav a:hover { color: var(--gold-light); }
.header__phone { color: var(--gold-light); font: 600 1rem var(--font-head); text-decoration: none; white-space: nowrap; }
.burger { display: none; width: 44px; height: 44px; background: none; border: 0; padding: 10px; cursor: pointer; }
.burger span { display: block; height: 2px; background: var(--gold-light); margin: 5px 0; transition: transform .2s; }

/* Перший екран */
.hero { position: relative; overflow: hidden; background: radial-gradient(ellipse at 70% 30%, #26221a 0%, var(--black) 60%); color: #f1eee7; padding: 4.5rem 0 2.5rem; }
.hero__grid { position: relative; display: grid; grid-template-columns: 1fr 1.05fr; gap: 3.5rem; align-items: start; }
.hero__media { margin-top: clamp(3rem, 7vw, 6.5rem); }
.eyebrow { color: var(--gold); font: 600 .85rem var(--font-head); letter-spacing: .14em; text-transform: uppercase; margin-bottom: 1rem; }
.eyebrow--dark { color: var(--gold-dark); }
.hero h1 { font-size: clamp(1.9rem, 3.6vw, 3rem); color: #fff; }
.hero__lead { font-size: 1.15rem; color: #d7d3ca; max-width: 38em; }
.hero__cta { display: flex; flex-wrap: wrap; gap: .8rem; margin: 1.8rem 0 1rem; }
.hero__note { font-size: .92rem; color: var(--muted-dark); }
.logo { width: 100%; height: auto; overflow: visible; }
/* Живий пульс: імпульс біжить лінією, амплітуда «стресу» постійно змінюється */
.logo__beat { transform-box: fill-box; transform-origin: center; animation: stress 5.2s ease-in-out infinite; }
.logo__pulse { opacity: .55; }
.logo__spark { stroke-dasharray: 16 84; animation: run 1.9s linear infinite; filter: drop-shadow(0 0 6px rgba(241, 217, 152, .9)); }
.brand__spark { stroke: #fff4d2 !important; stroke-dasharray: 22 78; animation: run 1.9s linear infinite; }
@keyframes run { from { stroke-dashoffset: 100; } to { stroke-dashoffset: 0; } }
@keyframes stress {
  0%   { transform: scaleY(1); }
  12%  { transform: scaleY(.72); }
  25%  { transform: scaleY(1.12); }
  38%  { transform: scaleY(.86); }
  50%  { transform: scaleY(1.22); }
  63%  { transform: scaleY(.64); }
  76%  { transform: scaleY(1.05); }
  88%  { transform: scaleY(.9); }
  100% { transform: scaleY(1); }
}
.hero__pulse { position: absolute; inset: 35% 0 auto; height: 200px; overflow: hidden; opacity: .14; pointer-events: none; }
.hero__pulse svg { width: 200%; height: 100%; animation: scroll-ecg 14s linear infinite; }
@keyframes scroll-ecg { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.trust { position: relative; list-style: none; padding: 0; margin: 3rem 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.trust li { display: flex; align-items: center; gap: .8rem; padding: 1rem; border: 1px solid rgba(201, 162, 74, .3); border-radius: var(--radius); background: rgba(255, 255, 255, .03); font-size: .92rem; color: #e4e0d7; }
.trust img { width: 40px; height: 40px; flex: none; }
.trust__icon { width: 40px; height: 40px; flex: none; display: grid; place-items: center; border-radius: 50%; border: 1.5px solid var(--gold); color: var(--gold-light); font-size: 1.1rem; }

/* Секції */
.section { padding: 5rem 0; }
.section--soft { background: var(--ivory); }
.section--dark { background: var(--black); color: #ece9e2; }
.section--dark .section__title { color: #fff; }
.section--dark .section__lead { color: var(--muted-dark); }
.section__title { font-size: clamp(1.6rem, 2.6vw, 2.25rem); }
.section__title::after { content: ""; display: block; width: 56px; height: 3px; margin-top: .6rem; background: var(--gold); border-radius: 2px; }
.section__lead { color: var(--muted); font-size: 1.1rem; max-width: 46em; margin-bottom: 2.5rem; }

/* Два входи */
.paths { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-bottom: 4rem; }
.path { padding: 2rem; border-radius: var(--radius); background: var(--ivory); border: 1px solid var(--line); display: flex; flex-direction: column; align-items: flex-start; }
.path h3 { font-size: 1.35rem; }
.path p:not(.path__tag) { color: var(--muted); flex: 1; }
.path__tag { color: var(--gold-dark); font: 700 .8rem var(--font-head); letter-spacing: .14em; text-transform: uppercase; margin-bottom: .6rem; }

/* Послуги */
.group-title { font-size: 1.4rem; margin: 2.5rem 0 1rem; }
.services { display: grid; gap: .75rem; }
.service { border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow); }
.service summary { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 1.1rem 1.4rem; cursor: pointer; list-style: none; font: 600 1.05rem var(--font-head); }
.service summary::-webkit-details-marker { display: none; }
.service summary::after { content: "+"; font-size: 1.5rem; color: var(--gold-dark); margin-left: .5rem; }
.service[open] summary::after { content: "−"; }
.service__price { margin-left: auto; color: var(--gold-dark); white-space: nowrap; font-size: .95rem; }
.service > p, .service > ul { margin: 0 1.4rem 1rem; }
.service ul { padding-left: 1.2rem; color: #3a3a40; }
.service li { margin-bottom: .3rem; }
.service__hint { background: var(--ivory); padding: .6rem 1rem; border-radius: 8px; }

/* Гарантії */
.principles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.25rem; }
.principle { padding: 1.6rem; border: 1px solid rgba(201, 162, 74, .3); border-radius: var(--radius); background: var(--black-2); }
.principle h3 { color: var(--gold-light); font-size: 1.1rem; }
.principle p { color: #c9c5bc; font-size: .97rem; margin: 0; }

/* Кроки */
.process { display: grid; grid-template-columns: .8fr 1.2fr; gap: 3.5rem; align-items: start; }
.process__photo { margin: 0; position: sticky; top: 100px; }
.process__photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: 40% 50%; border-radius: var(--radius); }
.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; }
.steps li { counter-increment: step; position: relative; padding: 0 0 1.75rem 4rem; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: -.2rem; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--black); color: var(--gold-light); font: 700 1rem var(--font-head); }
.steps li:not(:last-child)::after { content: ""; position: absolute; left: 21px; top: 2.9rem; bottom: .4rem; width: 2px; background: linear-gradient(var(--gold), transparent); }
.steps h3 { font-size: 1.15rem; margin-bottom: .3rem; }
.steps p { color: var(--muted); margin: 0; }

/* Ціни */
.table-wrap { overflow-x: auto; border-radius: var(--radius); box-shadow: var(--shadow); }
.prices { width: 100%; border-collapse: collapse; background: var(--paper); }
.prices th, .prices td { padding: 1rem 1.4rem; text-align: left; border-bottom: 1px solid var(--line); }
.prices th { background: var(--black); color: var(--gold-light); font-family: var(--font-head); font-weight: 600; }
.prices td:last-child, .prices th:last-child { text-align: right; white-space: nowrap; font-weight: 600; }
.prices tr:last-child td { border-bottom: 0; }
.price-terms { margin-top: 2rem; padding: 1.5rem 1.6rem; border-radius: var(--radius); background: var(--ivory); border: 1px solid var(--line); }
.price-terms__note { color: var(--muted); margin: 0 0 1rem; }
.price-terms .discounts { margin: 0 0 1rem; }
.price-terms .terms { margin: 0; }
.discounts { list-style: none; padding: 0; margin: 1.5rem 0 2rem; display: flex; flex-wrap: wrap; gap: .75rem; }
.discounts li { padding: .6rem 1rem; border-radius: 999px; background: var(--paper); border: 1px solid var(--line); font-size: .95rem; }
.discounts strong { color: var(--gold-dark); }
.terms { list-style: none; padding: 0; margin: 0 0 2rem; color: var(--muted); }
.terms li { margin-bottom: .35rem; }
.terms strong { color: var(--ink); }

/* Про фахівця */
.about { display: grid; grid-template-columns: 1fr 1.4fr; gap: 3.5rem; align-items: start; }
.about__photo { position: sticky; top: 100px; }
.about__photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: 60% 25%; border-radius: var(--radius); box-shadow: 0 0 0 1px rgba(201, 162, 74, .45), 18px 18px 0 -2px var(--ivory); }
.vap p { margin: 0; }
.about__sub { font-size: 1.05rem; margin: 1.6rem 0 .7rem; color: var(--gold-dark); letter-spacing: .02em; }
.timeline { list-style: none; padding: 0; margin: 0; }
.timeline li { display: grid; grid-template-columns: 5.5rem 1fr; gap: 1rem; padding: .55rem 0; border-top: 1px solid var(--line); font-size: .97rem; }
.timeline li:first-child { border-top: 0; }
.timeline__year { font: 700 .95rem var(--font-head); color: var(--ink); }
.about__equip { margin-top: 1.4rem; font-size: .97rem; }
.timeline a { color: var(--gold-dark); white-space: nowrap; }

/* Законодавча база */
.law { display: grid; grid-template-columns: 1.15fr 1fr 1.15fr; gap: 1.25rem; align-items: start; }
.law__card { padding: 1.6rem; border-radius: var(--radius); border: 1px solid var(--line); background: var(--paper); box-shadow: var(--shadow); }
.law__card h3 { font-size: 1.08rem; }
.law__card ul { padding-left: 1.1rem; margin: 0; font-size: .94rem; color: #3a3a40; }
.law__card li { margin-bottom: .5rem; }
.law__tags { list-style: none; padding: 0 !important; display: flex; flex-wrap: wrap; gap: .45rem; }
.law__tags li { margin: 0; padding: .35rem .75rem; border-radius: 999px; background: var(--ivory); border: 1px solid var(--line); }
.law__tags span { color: var(--gold-dark); font-weight: 600; margin-left: .25rem; }
.law__note { font-size: .85rem; color: var(--muted); margin: 1rem 0 0; }
.vap a { color: var(--gold-dark); font-size: .92rem; }
.creds { padding-left: 1.2rem; }
.creds li { margin-bottom: .6rem; }
.vap { display: flex; align-items: center; gap: 1rem; margin-top: 1.5rem; font: 600 1rem var(--font-head); }
.vap img { width: 96px; height: 96px; }

/* Документи */
.docs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.doc { display: flex; align-items: center; gap: 1rem; padding: 1.1rem 1.25rem; border-radius: var(--radius); background: var(--paper); border: 1px solid var(--line); text-decoration: none; font-weight: 500; transition: border-color .15s, transform .15s; }
.doc:hover { border-color: var(--gold); transform: translateY(-2px); }
.doc__type { flex: none; padding: .3rem .5rem; border-radius: 6px; background: var(--black); color: var(--gold-light); font: 700 .75rem var(--font-head); }

/* Підготовка */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; }
.checks, .crosses { list-style: none; padding: 0; }
.checks li, .crosses li { position: relative; padding-left: 2rem; margin-bottom: .7rem; }
.checks li::before { content: "✓"; position: absolute; left: 0; color: var(--gold-dark); font-weight: 700; }
.crosses li::before { content: "✕"; position: absolute; left: 0; color: #a14a3b; font-weight: 700; }

/* FAQ */
.faq { border-bottom: 1px solid var(--line); }
.faq summary { padding: 1.2rem 2.5rem 1.2rem 0; cursor: pointer; list-style: none; position: relative; font: 600 1.08rem var(--font-head); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: .25rem; top: 1rem; font-size: 1.5rem; color: var(--gold-dark); }
.faq[open] summary::after { content: "−"; }
.faq p { color: var(--muted); }

/* Контакти */
.contacts { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; }
.contact-list { list-style: none; padding: 0; margin: 0; }
.contact-list li { display: grid; grid-template-columns: 9.5rem 1fr; gap: 1rem; padding: .9rem 0; border-bottom: 1px solid rgba(255, 255, 255, .1); }
.contact-list li > span:first-child { color: var(--muted-dark); font-size: .92rem; }
.contact-list a { color: var(--gold-light); font-weight: 600; text-decoration: none; }
.map { width: 100%; height: 260px; margin-top: 1.5rem; border: 0; border-radius: var(--radius); filter: grayscale(.6) contrast(1.05); }
.hero__note a { color: var(--gold-light); }
.form { background: var(--paper); color: var(--ink); padding: 2rem; border-radius: var(--radius); display: grid; gap: .5rem; }
.form h3 { font-size: 1.35rem; }
.form label { font-weight: 500; font-size: .95rem; margin-top: .4rem; }
.form input[type="text"], .form input[type="tel"], .form textarea { width: 100%; padding: .8rem 1rem; border: 1.5px solid var(--line); border-radius: 10px; font: inherit; background: #fdfcf9; }
.form input:focus, .form textarea:focus { border-color: var(--gold); outline: none; box-shadow: 0 0 0 3px rgba(201, 162, 74, .25); }
.form fieldset { border: 0; padding: 0; margin: .4rem 0 0; display: flex; flex-wrap: wrap; gap: .25rem 1.5rem; }
.form legend { font-weight: 500; font-size: .95rem; margin-bottom: .3rem; }
.radio, .consent { display: flex; gap: .5rem; align-items: flex-start; font-weight: 400 !important; }
.radio input, .consent input { width: 20px; height: 20px; accent-color: var(--gold-dark); flex: none; margin-top: .15rem; }
.consent { font-size: .88rem !important; color: var(--muted); }
.form .btn { margin-top: .8rem; width: 100%; }
.form__micro { font-size: .85rem; color: var(--muted); text-align: center; margin: .3rem 0 0; }
.form__status { margin: 0; font-weight: 600; color: #2f6b3a; text-align: center; }
.form__status.is-error { color: #a14a3b; }
.form__hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form button[disabled] { opacity: .6; cursor: progress; transform: none; }

/* Куточок споживача */
.consumer { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; font-size: .97rem; }
.consumer h3 { font-size: 1.1rem; margin-top: 1rem; }
.doc-list { padding-left: 1.2rem; }
.doc-list a { color: var(--gold-dark); font-weight: 500; }

/* Юридичні сторінки */
.legal h2 { font-size: 1.25rem; margin-top: 2.2rem; }
.legal ul { padding-left: 1.2rem; }
.legal li { margin-bottom: .35rem; }
.legal a { color: var(--gold-dark); }
.legal__back { margin-bottom: 1.5rem; }
.legal__back a { text-decoration: none; font-weight: 500; }
.legal__meta { color: var(--muted); font-size: .95rem; }

/* Підвал */
.footer { background: var(--black); color: var(--muted-dark); padding: 2rem 0 6rem; font-size: .9rem; border-top: 1px solid rgba(201, 162, 74, .25); }
.footer__inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; }
.footer p { margin: 0; }
.footer a { color: var(--gold-light); text-decoration: none; }
.social { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; }

/* Липка панель на мобільному */
.sticky-cta { display: none; }

/* Адаптивність */
.nav a { white-space: nowrap; }
@media (max-width: 1200px) {
  .nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; gap: 0; background: var(--black); padding: .5rem 1.25rem 1rem; border-bottom: 1px solid rgba(201, 162, 74, .25); }
  .nav.is-open { display: flex; }
  .nav a { padding: .85rem 0; border-bottom: 1px solid rgba(255, 255, 255, .06); }
  .burger { display: block; }
  .trust, .principles { grid-template-columns: 1fr 1fr; }
  .law { grid-template-columns: 1fr 1fr; }
  .docs { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 760px) {
  body { font-size: 1rem; }
  .header__phone { display: none; }
  .brand__line { font-size: .62rem; }
  .brand__name { font-size: .82rem; }
  .hero { padding-top: 2.5rem; }
  .hero__grid, .paths, .about, .two-col, .contacts, .consumer, .process { grid-template-columns: 1fr; }
  .process__photo, .about__photo { position: static; }
  .process__photo img { aspect-ratio: 4 / 3; object-position: 50% 45%; }
  .hero__media { display: none; }
  .trust, .principles, .docs, .law { grid-template-columns: 1fr; }
  .timeline li { grid-template-columns: 1fr; gap: .1rem; }
  .section { padding: 3.5rem 0; }
  .service summary { flex-wrap: wrap; }
  .contact-list li { grid-template-columns: 1fr; gap: .2rem; }
  .form { padding: 1.4rem; }
  .sticky-cta { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; padding: .6rem 1rem calc(.6rem + env(safe-area-inset-bottom, 0px)); background: rgba(14, 14, 16, .96); border-top: 1px solid rgba(201, 162, 74, .3); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
  .logo__beat, .logo__spark, .brand__spark, .hero__pulse svg { animation: none !important; }
  .logo__spark, .brand__spark { display: none; }
}
