/* «Приток» — clean water: light foam, deep navy text, one stream down the page. */
:root {
  --foam: #F5FAFD;
  --ice: #E4F1FA;
  --deep: #0E2A47;
  --current: #1C7ED6;
  --current-dark: #145FA6;
  --teal: #22C3D6;
  --silt: #5A7891;
  --line: rgba(28, 126, 214, 0.16);
  --glass: rgba(255, 255, 255, 0.62);
  --river-x: 22px;
  --gutter: 20px;
  --content: 1120px;
  --radius-s: 10px;
  --radius-l: 28px;
  font-family: "Onest", system-ui, sans-serif;
  color: var(--deep);
  background: var(--foam);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--foam); line-height: 1.55; font-size: 17px; overflow-x: hidden; }
img, svg, canvas { display: block; }
h1, h2, p { margin: 0; }
b { font-weight: 600; }
a { color: var(--current); }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; border-radius: 6px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 50; background: var(--deep); color: #fff; padding: 8px 14px; border-radius: 8px; }
.skip:focus { left: 8px; }

/* ---------- the river ---------- */
.river, .river-drops { position: absolute; left: 0; top: 0; width: 100%; pointer-events: none; z-index: 0; }
.river__bed { fill: none; stroke: var(--ice); stroke-width: 14; stroke-linecap: round; }
.river__glow { fill: none; stroke: var(--teal); stroke-opacity: 0.35; stroke-width: 2; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 22px;
  border-radius: 999px; font: 600 16px/1.2 inherit; font-family: inherit; text-decoration: none; cursor: pointer; text-align: center;
  border: 1.5px solid transparent; transition: background-color .2s, color .2s, transform .1s;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--current); color: #fff; box-shadow: 0 10px 26px -12px rgba(28, 126, 214, .7); }
.btn--primary:hover { background: var(--current-dark); }
.btn--ghost { background: transparent; color: var(--deep); border-color: rgba(14, 42, 71, .18); }
.btn--ghost:hover { border-color: var(--current); color: var(--current); }

/* ---------- header ---------- */
.top {
  position: relative; z-index: 3; display: flex; align-items: center; gap: 16px;
  max-width: var(--content); margin: 0 auto; padding: 18px var(--gutter) 0 calc(var(--river-x) + 22px);
}
.logo { font-weight: 800; font-size: 22px; letter-spacing: -0.03em; color: var(--deep); text-decoration: none; }
.top__nav { display: none; gap: 22px; margin-left: auto; }
.top__nav a { color: var(--silt); text-decoration: none; font-weight: 500; }
.top__nav a:hover { color: var(--current); }
.top__contact { display: none; min-height: 42px; }

/* ---------- hero ---------- */
main { position: relative; z-index: 1; }
.hero {
  position: relative; display: grid; grid-template-columns: minmax(0, 1fr); gap: 36px; max-width: var(--content); margin: 0 auto;
  padding: 36px var(--gutter) 40px calc(var(--river-x) + 22px);
}
.hero__flow { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.hero__text, .phone { position: relative; z-index: 1; }
.hero__kicker { color: var(--current); font-weight: 600; margin-bottom: 14px; }
h1 { font-size: clamp(32px, 8vw, 56px); line-height: 1.05; letter-spacing: -0.035em; font-weight: 800; max-width: 18ch; }
.hero__sub { margin-top: 16px; font-size: clamp(20px, 4.6vw, 26px); font-weight: 600; color: var(--current); letter-spacing: -0.01em; }
.hero__lead { margin-top: 14px; color: var(--silt); max-width: 36em; }
.hero__actions { display: flex; flex-direction: column; gap: 10px; margin-top: 26px; }
.hero__sources { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 22px 0 0; list-style: none; }
.hero__sources li { font-size: 14px; color: var(--silt); background: rgba(228, 241, 250, .8); border-radius: 999px; padding: 5px 12px; }

/* ---------- phone with the live chat ---------- */
.phone { width: 100%; max-width: 400px; justify-self: center; }
.phone__screen {
  display: flex; flex-direction: column; height: 560px; border-radius: 36px; padding: 12px;
  background: var(--glass); backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%);
  border: 1px solid rgba(255, 255, 255, .9);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .9) inset, 0 30px 70px -30px rgba(14, 42, 71, .45), 0 0 0 8px rgba(255, 255, 255, .45);
}
.phone__tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; background: rgba(228, 241, 250, .9); border-radius: 999px; }
.phone__tabs button { border: 0; border-radius: 999px; padding: 9px 6px; font: 600 14px inherit; font-family: inherit; color: var(--silt); background: transparent; cursor: pointer; }
.phone__tabs button[aria-selected="true"] { background: #fff; color: var(--deep); box-shadow: 0 2px 8px rgba(14, 42, 71, .1); }
.phone__head { display: flex; align-items: center; gap: 10px; padding: 12px 6px 10px; border-bottom: 1px solid var(--line); }
.phone__head small { display: block; color: var(--teal); font-size: 13px; }
.phone__avatar { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(140deg, var(--teal), var(--current)); color: #fff; font-weight: 800; }
.chat { flex: 1; overflow-y: auto; padding: 14px 4px; display: flex; flex-direction: column; gap: 8px; scroll-behavior: smooth; }
.msg { max-width: 86%; padding: 9px 13px; border-radius: 18px; font-size: 15px; line-height: 1.42; white-space: pre-line; animation: drop .25s ease-out; }
.msg--bot { align-self: flex-start; background: #fff; border-bottom-left-radius: 6px; box-shadow: 0 1px 2px rgba(14, 42, 71, .06); }
.msg--me { align-self: flex-end; background: var(--current); color: #fff; border-bottom-right-radius: 6px; }
.msg--typing { color: var(--silt); }
.msg--typing::after { content: "…"; animation: blink 1s infinite; }
.chips { display: flex; gap: 6px; overflow-x: auto; padding: 4px 2px 8px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chips button { flex: none; border: 1px solid var(--line); background: rgba(255, 255, 255, .85); color: var(--current-dark); border-radius: 999px; padding: 7px 12px; font: 500 14px inherit; font-family: inherit; cursor: pointer; }
.chips button:hover { border-color: var(--current); }
.composer { display: flex; gap: 8px; align-items: center; background: #fff; border-radius: 999px; padding: 5px 5px 5px 16px; border: 1px solid var(--line); }
.composer input { flex: 1; min-width: 0; border: 0; outline: 0; font: 16px inherit; font-family: inherit; color: var(--deep); background: transparent; }
.composer button { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; border: 0; background: var(--current); color: #fff; cursor: pointer; }
.composer button:disabled { opacity: .5; cursor: default; }
.phone__note { margin-top: 10px; text-align: center; font-size: 13px; color: var(--silt); }

/* ---------- sections: each one joins the river as a tributary ---------- */
.block { position: relative; max-width: var(--content); margin: 0 auto; padding: 56px var(--gutter) 56px calc(var(--river-x) + 22px); }
.block h2 { position: relative; font-size: clamp(26px, 6vw, 42px); line-height: 1.1; letter-spacing: -0.03em; font-weight: 800; max-width: 22ch; margin-bottom: 22px; }
.block h2::before {
  /* the tributary: a curve from the heading into the main stream */
  content: ""; position: absolute; top: .55em; left: calc(-22px - 2px); width: 18px; height: 22px;
  border-top: 2px solid var(--teal); border-left: 2px solid var(--teal); border-top-left-radius: 18px; opacity: .55;
}
.block > p { max-width: 40em; color: var(--silt); }
.block > p + p { margin-top: 10px; }
.note { font-size: 15px; color: var(--silt); margin-top: 14px !important; }

.pain__cases { display: grid; gap: 16px; }
.pain__cases p { max-width: 34em; padding-left: 16px; border-left: 3px solid var(--ice); color: var(--silt); }
.pain__cases b { color: var(--deep); }

.skills__list, .knows__list, .owner__list { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; max-width: 46em; }
.skills__list li, .knows__list li, .owner__list li { color: var(--silt); padding-left: 24px; position: relative; }
.skills__list li::before, .knows__list li::before, .owner__list li::before {
  content: ""; position: absolute; left: 2px; top: .62em; width: 10px; height: 10px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff 0 18%, var(--teal) 40%, var(--current) 100%);
}
.skills__list b, .knows__list b, .owner__list b { color: var(--deep); }

.knows__grid, .owner__grid { display: grid; gap: 26px; align-items: start; }
.pricelist { background: #fff; border-radius: var(--radius-s); padding: 18px 20px; box-shadow: 0 18px 40px -28px rgba(14, 42, 71, .4); max-width: 420px; }
.pricelist p { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px dashed var(--line); font-size: 15px; }
.pricelist p:last-child { border-bottom: 0; }
.pricelist p span:last-child { font-weight: 600; white-space: nowrap; }
.pricelist .pricelist__title { display: block; border: 0; font-weight: 800; padding-top: 0; }
.knows__fast { margin-top: 22px !important; color: var(--deep) !important; font-weight: 600; font-size: 19px; }

.missed__flow { display: grid; gap: 10px; max-width: 420px; margin-bottom: 18px; }
.missed__call { justify-self: start; font-weight: 600; color: #C2410C; background: #FFF4ED; border-radius: 999px; padding: 6px 14px; font-size: 15px; }
.missed__msg { background: #fff; border-radius: 18px 18px 18px 6px; padding: 12px 15px; box-shadow: 0 10px 30px -22px rgba(14, 42, 71, .5); font-size: 15px; }

.hot__story { display: grid; gap: 18px; margin-bottom: 22px; }
.hot__who { font-size: 14px; color: var(--silt); margin-bottom: 6px; font-weight: 500; }
.bubble { background: #fff; border-radius: 16px; padding: 11px 14px; font-size: 15px; max-width: 380px; box-shadow: 0 10px 30px -24px rgba(14, 42, 71, .5); }
.bubble--you { background: var(--deep); color: #fff; }
.bubble--you code { font-family: inherit; font-weight: 600; }
.bubble--card { border-left: 3px solid var(--teal); border-radius: 6px 16px 16px 6px; }
.bubble__button { display: inline-block; margin-top: 6px; background: var(--ice); color: var(--current-dark); font-weight: 600; font-size: 14px; border-radius: 10px; padding: 6px 12px; }
.hot__step { opacity: 1; transform: none; }
.js .hot:not(.is-shown) .hot__step { opacity: 0; transform: translateY(10px); }
.js .hot .hot__step { transition: opacity .5s, transform .5s; }
.js .hot.is-shown .hot__step:nth-child(2) { transition-delay: .7s; }
.js .hot.is-shown .hot__step:nth-child(3) { transition-delay: 1.6s; }

.table-wrap { overflow-x: auto; margin: 0 calc(var(--gutter) * -1) 0 0; }
table { border-collapse: collapse; min-width: 520px; width: 100%; max-width: 860px; font-size: 15px; }
th, td { text-align: left; padding: 13px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { font-weight: 600; color: var(--silt); font-size: 14px; }
tbody th { font-weight: 600; width: 30%; }
td:last-child { color: var(--current-dark); font-weight: 600; }
thead th:last-child { color: var(--current); }

.group { background: linear-gradient(180deg, #EAF4FB, #F5FAFD); border-radius: var(--radius-s); padding: 16px; display: grid; gap: 10px; max-width: 420px; }
.group__title { font-weight: 800; }
.group__hint { font-size: 13px; color: var(--silt); }

.steps__list { margin: 0; padding: 0; list-style: none; counter-reset: step; display: grid; gap: 18px; max-width: 46em; }
.steps__list li { counter-increment: step; position: relative; padding-left: 52px; color: var(--silt); min-height: 38px; }
.steps__list li::before {
  content: counter(step); position: absolute; left: 0; top: -2px; width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center; font-weight: 800; color: var(--current); background: var(--ice);
}
.steps__list b { color: var(--deep); display: block; }

.price__grid { display: grid; gap: 16px; }
.price__item {
  border-radius: var(--radius-l); padding: 24px; background: var(--glass); border: 1px solid rgba(255, 255, 255, .9);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: 0 24px 60px -36px rgba(14, 42, 71, .45);
}
.price__name { font-weight: 600; color: var(--silt); }
.price__sum { font-size: clamp(28px, 6vw, 38px); font-weight: 800; letter-spacing: -0.03em; margin: 4px 0 10px; }
.price__sum small { display: block; font-size: 15px; font-weight: 500; color: var(--silt); letter-spacing: 0; }
.price__item > p:last-child { color: var(--silt); font-size: 15px; }
.price__deal { margin-top: 18px !important; font-weight: 600; color: var(--current-dark) !important; }

.faq details { max-width: 46em; border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; padding: 16px 30px 16px 0; font-weight: 600; list-style: none; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 9px; height: 9px; border-right: 2px solid var(--current); border-bottom: 2px solid var(--current); transform: translateY(-70%) rotate(45deg); transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.faq details p { padding-bottom: 16px; color: var(--silt); }

.lead { display: grid; gap: 14px; max-width: 520px; margin-top: 22px; }
.lead label { display: grid; gap: 6px; font-weight: 600; font-size: 15px; }
.lead label span { font-weight: 400; color: var(--silt); font-size: 14px; }
.lead input { font: 16px inherit; font-family: inherit; padding: 13px 16px; border-radius: 14px; border: 1.5px solid rgba(14, 42, 71, .14); background: #fff; color: var(--deep); }
.lead input:focus { border-color: var(--current); outline: none; box-shadow: 0 0 0 4px rgba(34, 195, 214, .2); }
.lead input[aria-invalid="true"] { border-color: #C2410C; }
.lead__trap { position: absolute; left: -9999px; }
.lead__status { min-height: 1.5em; font-weight: 600; }
.lead__status.is-ok { color: #0F8A6A; }
.lead__status.is-error { color: #C2410C; }
.contacts { margin-top: 34px; }
.contacts > p { color: var(--silt); margin-bottom: 10px; }
.contacts__links, .sheet__links { display: flex; flex-wrap: wrap; gap: 10px; }
.contact-link { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 0 18px; border-radius: 999px; background: #fff; border: 1px solid var(--line); color: var(--deep); font-weight: 600; text-decoration: none; }
.contact-link:hover { border-color: var(--current); color: var(--current); }
.contact-link i { width: 10px; height: 10px; border-radius: 50%; background: var(--dot, var(--current)); }

.foot { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: space-between; max-width: var(--content); margin: 0 auto; padding: 30px var(--gutter) 110px calc(var(--river-x) + 22px); color: var(--silt); font-size: 14px; }

/* the "write to the manager" button always at hand on phones */
.dock {
  position: fixed; z-index: 20; left: 16px; right: 16px; bottom: max(14px, env(safe-area-inset-bottom)); min-height: 54px;
  border: 0; border-radius: 999px; background: var(--deep); color: #fff; font: 600 16px inherit; font-family: inherit; cursor: pointer;
  box-shadow: 0 14px 34px -14px rgba(14, 42, 71, .7); transition: transform .3s, opacity .3s;
}
.dock.is-hidden { transform: translateY(140%); opacity: 0; }
.sheet { border: 0; border-radius: 24px; padding: 24px; max-width: 420px; width: calc(100% - 32px); color: var(--deep); }
.sheet::backdrop { background: rgba(14, 42, 71, .35); backdrop-filter: blur(3px); }
.sheet h2 { font-size: 22px; margin-bottom: 16px; }
.sheet .btn { margin-top: 16px; width: 100%; }

@keyframes drop { from { opacity: 0; transform: translateY(6px); } }
@keyframes blink { 50% { opacity: .2; } }

/* ---------- wider screens ---------- */
@media (min-width: 700px) {
  :root { --river-x: 40px; --gutter: 32px; }
  .hero__actions { flex-direction: row; flex-wrap: wrap; }
  .pain__cases { grid-template-columns: repeat(3, 1fr); }
  .knows__grid, .owner__grid { grid-template-columns: minmax(0, 420px) minmax(0, 1fr); gap: 40px; }
  .hot__story { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .price__grid { grid-template-columns: 1fr 1fr; max-width: 860px; }
  .table-wrap { margin: 0; }
}
@media (min-width: 1000px) {
  :root { --river-x: 56px; }
  .top__nav, .top__contact { display: flex; }
  .top__contact { margin-left: 8px; }
  .hero { grid-template-columns: minmax(0, 1fr) 400px; align-items: center; gap: 56px; padding-top: 56px; padding-bottom: 72px; min-height: min(820px, 100vh); }
  .dock { display: none; }
  .foot { padding-bottom: 30px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .hot .hot__step { opacity: 1; transform: none; }
}
