/* Токены и раскладка как у Tilda Pragmaticus */
:root {
  --bg-dark: #15181c;
  --bg-header: #2c2d33;
  --bg-light: #fefefe;
  --bg-card-dark: #1c1f24;
  --bg-chip: #15181c;
  --text-light: #fefefe;
  --text-muted-light: #cacad4;
  --text-dark: #15181c;
  --text-muted-dark: #3b3f45;
  --text-gray: #a1a9aa;
  --accent: #c8386d;
  --accent-soft: #ffe4ee;
  --btn-secondary: rgba(44, 45, 51, 0.8);
  --border-dark: #3b3f45;
  --max: 1200px;
  --font: "Roboto", Arial, sans-serif;
  --header-h: 80px;
  --radius-pill: 30px;
  --radius-card: 16px;
  --hero-curve: 130px;
  --content: 1200px;
}

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

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

body {
  margin: 0;
  font-family: var(--font);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.5;
  color: var(--text-dark);
  background: var(--bg-light);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: #ff8562;
  text-decoration: none;
}

a:hover {
  opacity: 0.85;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.wrap {
  width: min(100% - 40px, var(--max));
  margin-inline: auto;
}

/* ——— Header ——— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: var(--bg-header);
  display: flex;
  align-items: center;
}

.site-header__inner {
  position: relative;
  width: min(100% - 40px, 1200px);
  max-width: 1200px;
  margin-inline: auto;
  height: 100%;
}

.nav {
  position: absolute;
  left: 113px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav a {
  color: var(--text-light);
  font-size: 14px;
  font-weight: 400;
  text-decoration: none;
}

.brand-logo {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
}

.brand-logo img {
  width: 173px;
  height: 32px;
  display: block;
}

.btn--header {
  position: absolute;
  right: 127px;
  top: 50%;
  transform: translateY(-50%);
  width: 210px;
  height: 42px;
  padding: 0 20px;
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--accent);
  border: 0;
  color: #fff;
  font-size: 0;
  cursor: pointer;
  position: relative;
}

.nav-toggle::before {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  top: 15px;
  height: 2px;
  background: #fff;
  box-shadow: 0 6px 0 #fff, 0 12px 0 #fff;
}

/* ——— Buttons ——— */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 42px;
  padding: 0 28px;
  border-radius: var(--radius-pill);
  font-family: var(--font);
  font-size: 14px;
  font-weight: 400;
  text-decoration: none;
  border: 0;
  cursor: pointer;
  white-space: nowrap;
}

.btn--lg {
  height: 55px;
  min-width: 250px;
  padding: 0 32px;
}

.btn--primary {
  background: var(--accent);
  color: #fff;
}

.btn--primary:hover {
  color: #fff;
  opacity: 0.92;
}

.btn--secondary {
  background: var(--btn-secondary);
  color: #fff;
  border: 1px solid var(--border-dark);
}

.btn--secondary:hover {
  color: #fff;
  opacity: 0.92;
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  justify-content: center;
}

/* ——— Sections ——— */
.section {
  padding: 70px 0;
}

.section--dark {
  background: var(--bg-dark);
  color: var(--text-light);
}

.section--light {
  background: var(--bg-light);
  color: var(--text-dark);
}

.section--header-pad {
  padding-top: 40px;
}

.section__title {
  margin: 0 0 16px;
  font-size: 32px;
  font-weight: 600;
  line-height: 1.25;
  text-align: center;
}

.section__title--left {
  text-align: left;
}

.section__lead {
  margin: 0 auto 40px;
  max-width: 610px;
  font-size: 18px;
  line-height: 1.5;
  text-align: center;
  color: var(--text-gray);
}

.section--dark .section__lead {
  color: var(--text-muted-light);
}

.section--light .section__lead {
  color: var(--text-gray);
}

.section__lead--left {
  margin-left: 0;
  text-align: left;
}

/* ——— Hero ——— */
.hero {
  background: var(--bg-light);
  padding: 0;
  overflow: hidden;
}

.hero__shell {
  position: relative;
  background: var(--bg-dark);
  color: var(--text-light);
  border-radius: 0 0 var(--hero-curve) var(--hero-curve);
  padding: 139px 20px 0;
  overflow: hidden;
  min-height: 730px;
}

.hero__glow {
  position: absolute;
  left: 50%;
  top: 420px;
  width: 797px;
  height: 307px;
  transform: translateX(-50%);
  background: var(--accent);
  opacity: 0.25;
  filter: blur(80px);
  pointer-events: none;
}

.hero__deco {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.35;
  background:
    url("/assets/Abstract_Spiral_Wind.svg") left -120px center / 520px no-repeat;
  filter: grayscale(1) brightness(1.4);
}

.hero__inner {
  position: relative;
  z-index: 1;
  width: min(100%, 980px);
  margin: 0 auto;
  text-align: center;
}

.hero h1 {
  margin: 0 auto 16px;
  max-width: 734px;
  font-size: 32px;
  font-weight: 600;
  line-height: 40px;
  color: var(--text-light);
}

.hero__sub {
  margin: 0 auto 28px;
  max-width: 734px;
  font-size: 18px;
  line-height: 23px;
  color: var(--text-muted-light);
}

.hero .btn-row {
  margin-bottom: 40px;
}

.hero__visual {
  position: relative;
  width: min(100%, 709px);
  margin: 0 auto;
}

.hero__visual .mock {
  width: 100%;
  height: auto;
  border-radius: 8px 8px 0 0;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
  position: relative;
  z-index: 1;
}

.chip {
  margin: 0;
  font-size: 16px;
  line-height: 1.3;
  display: flex;
  align-items: center;
  gap: 8px;
}

.chip img {
  width: 20px;
  height: 20px;
}

.chip--on-dark {
  color: var(--text-light);
  position: absolute;
  width: 200px;
  z-index: 2;
}

.chip--on-light {
  color: var(--text-dark);
  width: 202px;
}

.chip--left {
  text-align: left;
  justify-content: flex-start;
}

.chip--right {
  text-align: right;
  justify-content: flex-end;
}

.hero__visual .chip--left {
  left: -220px;
  top: 90px;
}

.hero__visual .chip--right {
  right: -220px;
  top: 170px;
}

.hero__below {
  background: var(--bg-light);
  padding: 28px 20px 48px;
}

.hero__below-inner {
  width: min(100%, 980px);
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 0 24px;
}

/* ——— About (light) ——— */
.about-grid {
  display: grid;
  gap: 24px;
  margin-top: 36px;
}

@media (min-width: 800px) {
  .about-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.about-card h3 {
  margin: 0 0 10px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-dark);
}

.about-card p {
  margin: 0;
  font-size: 16px;
  color: var(--text-muted-dark);
}

.about-top {
  display: grid;
  gap: 24px;
  align-items: start;
}

@media (min-width: 900px) {
  .about-top {
    grid-template-columns: 1fr 1fr;
  }

  .about-top .section__title,
  .about-top .section__lead {
    text-align: left;
    margin-left: 0;
  }
}

.about-ill {
  justify-self: center;
  max-width: 420px;
}

/* ——— Steps ——— */
.steps {
  display: grid;
  gap: 16px;
  margin-top: 36px;
}

@media (min-width: 900px) {
  .steps {
    grid-template-columns: repeat(3, 1fr);
  }
}

.step {
  background: #fff;
  border: 1px solid #ececec;
  border-radius: var(--radius-card);
  padding: 24px;
  box-shadow: 0 8px 24px rgba(21, 24, 28, 0.04);
}

.step__num {
  margin: 0 0 12px;
  font-size: 24px;
  font-weight: 600;
  color: var(--accent);
}

.step h3 {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-dark);
}

.step p {
  margin: 0;
  font-size: 16px;
  color: var(--text-muted-dark);
}

/* ——— Feature cards (dark) ——— */
.feat-grid {
  display: grid;
  gap: 16px;
  margin-top: 36px;
}

@media (min-width: 800px) {
  .feat-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.feat-card {
  background: var(--bg-card-dark);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-card);
  padding: 24px;
}

.feat-card h3 {
  margin: 0 0 10px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-light);
}

.feat-card p {
  margin: 0;
  font-size: 16px;
  color: var(--text-muted-light);
}

.feat-card--accent h3 {
  color: var(--accent);
}

/* ——— Use cases / security / roles ——— */
.use-grid,
.sec-grid {
  display: grid;
  gap: 20px;
  margin-top: 36px;
}

@media (min-width: 800px) {
  .use-grid,
  .sec-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.use-item h3,
.sec-item h3 {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 600;
}

.use-item p,
.sec-item p {
  margin: 0;
  font-size: 16px;
  color: var(--text-muted-dark);
}

.sec-item__icon {
  width: 40px;
  height: 40px;
  margin-bottom: 12px;
}

.roles {
  display: grid;
  gap: 12px;
  margin-top: 32px;
}

.role {
  display: grid;
  gap: 4px;
  padding: 18px 20px;
  border: 1px solid #ececec;
  border-radius: 12px;
  background: #fff;
}

@media (min-width: 700px) {
  .role {
    grid-template-columns: 120px 1fr;
    align-items: baseline;
  }
}

.role strong {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-dark);
}

.role span {
  font-size: 16px;
  color: var(--text-muted-dark);
}

/* ——— FAQ ——— */
.faq {
  max-width: 720px;
  margin: 36px auto 0;
  display: grid;
  gap: 10px;
}

.faq-item {
  border-bottom: 1px solid #e6e6e6;
}

.faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 16px 8px;
  font-size: 16px;
  font-weight: 600;
  color: var(--text-dark);
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  color: var(--accent);
  font-size: 20px;
  line-height: 1;
}

.faq-item[open] summary::after {
  content: "–";
}

.faq-item__body {
  padding: 0 8px 16px;
  font-size: 16px;
  color: var(--text-muted-dark);
}

.faq-item__body p {
  margin: 0;
}

.faq-badge {
  display: inline-block;
  margin-bottom: 12px;
  padding: 6px 12px;
  background: var(--accent-soft);
  border-radius: 8px;
  font-size: 13px;
  color: var(--text-dark);
}

/* ——— CTA band ——— */
.cta-band {
  text-align: center;
  padding: 80px 0;
  background: var(--bg-light);
}

.cta-band h2 {
  margin: 0 0 16px;
  font-size: 32px;
  font-weight: 600;
}

.cta-band p {
  margin: 0 auto 28px;
  max-width: 560px;
  font-size: 18px;
  color: var(--text-gray);
}

/* ——— Footer ——— */
.site-footer {
  background: var(--bg-header);
  color: var(--text-muted-light);
  padding: 28px 0;
  font-size: 14px;
}

.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
}

.site-footer a {
  color: var(--text-light);
  font-size: 14px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

/* ——— Legal ——— */
.legal-header {
  padding: 48px 0 28px;
  background: var(--bg-light);
  border-bottom: 1px solid #ececec;
}

.legal-header .wrap {
  width: min(100% - 40px, 720px);
}

.legal-header h1 {
  margin: 0;
  font-size: 32px;
  font-weight: 600;
  line-height: 1.25;
  color: var(--text-dark);
  text-align: left;
}

.legal-header .meta {
  margin: 10px 0 0;
  color: var(--text-gray);
  font-size: 15px;
  text-align: left;
}

.legal-main {
  width: min(100% - 40px, 720px);
  margin: 0 auto;
  padding: 32px 0 64px;
}

.legal-main section {
  margin: 0 0 20px;
  padding: 20px;
  border: 1px solid #ececec;
  border-radius: 12px;
  background: #fff;
}

.legal-main h2 {
  margin: 0 0 10px;
  font-size: 18px;
  font-weight: 600;
  color: var(--text-dark);
}

.legal-main p,
.legal-main li {
  color: var(--text-muted-dark);
}

.legal-main ul {
  padding-left: 20px;
}

body.page-legal {
  background: var(--bg-light);
}

@media (max-width: 820px) {
  .nav-toggle {
    display: block;
    position: absolute;
    right: 0;
    left: auto;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
  }

  .btn--header {
    display: none;
  }

  .brand-logo {
    left: 50%;
  }

  .nav {
    position: fixed;
    inset: var(--header-h) 0 auto 0;
    left: 0;
    top: var(--header-h);
    transform: none;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 12px 20px 16px;
    background: var(--bg-header);
    border-bottom: 1px solid var(--border-dark);
    z-index: 40;
  }

  .nav.is-open {
    display: flex;
  }

  .nav a {
    padding: 12px 0;
    border-bottom: 1px solid var(--border-dark);
  }

  .hero__visual .chip--left,
  .hero__visual .chip--right {
    position: static;
    width: auto;
    margin: 8px 0;
  }

  .hero__visual {
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .hero__visual .mock {
    order: -1;
    border-radius: 8px;
  }

  .hero__shell {
    border-radius: 0 0 60px 60px;
    padding-top: 36px;
  }

  .hero__below-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .btn--lg {
    min-width: 0;
    width: 100%;
  }

  .hero h1 {
    font-size: 28px;
    line-height: 34px;
  }
}
