/* ===== Tokens ===== */
:root {
  --bg: #EBF9FF;
  --purple: #6B64E1;
  --purple-dark: #5A53C8;
  --text: #7A8082;
  --text-light: #A6A6A6;
  --black: #2C2C2C;
  --white: #FFFFFF;
  --container: 1180px;
}

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

html { scroll-behavior: smooth; }

html { overflow-x: hidden; }

body {
  background-color: var(--bg);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  max-width: 100%;
  padding-top: 72px;
}

img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.btn--primary {
  background-color: var(--purple);
  color: #fff;
  padding: 15px 28px;
}
.btn--primary:hover { background-color: var(--purple-dark); }

.btn--block { width: 100%; }
.btn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}
.btn--ghost {
  background: transparent;
  color: var(--purple);
  padding: 12px 16px;
}
.btn--ghost:hover { background-color: color-mix(in srgb, var(--purple) 8%, transparent); }

.form-status {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.4;
  color: var(--purple);
}
.form-status--error { color: #c0392b; }
.form-status[hidden] { display: none; }

/* ===== Header ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background-color: rgba(235, 249, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.header--scrolled {
  border-bottom-color: rgba(107, 100, 225, 0.12);
  box-shadow: 0 8px 24px rgba(80, 90, 150, 0.08);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  position: relative;
}

.header__logo {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--black);
  flex-shrink: 0;
}

.header__nav {
  display: flex;
  align-items: center;
  gap: 40px;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.header__link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.95rem;
  color: var(--black);
  background: none;
  border: none;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.15s ease;
}
.header__link:hover { color: var(--purple); }
.header__link--active { color: var(--purple); font-weight: 600; }

.header__actions {
  display: flex;
  align-items: center;
  gap: 22px;
  flex-shrink: 0;
}

.header__login {
  font-size: 0.95rem;
  color: var(--black);
  transition: color 0.15s ease;
}
.header__login:hover { color: var(--purple); }

.header__register {
  background-color: var(--purple);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 500;
  padding: 10px 22px;
  border-radius: 10px;
  transition: background-color 0.15s ease;
}
.header__register:hover { background-color: var(--purple-dark); }

.header__actions--mobile { display: none; }

.header__burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  width: 44px;
  height: 38px;
  background-color: var(--purple);
  border: none;
  border-radius: 10px;
  cursor: pointer;
  padding: 0 11px;
}
.header__burger span {
  display: block;
  height: 2px;
  background-color: #fff;
  border-radius: 2px;
}

/* ===== Section titles ===== */
.section-title {
  font-size: 2rem;
  font-weight: 500;
  line-height: 1.25;
  color: var(--black);
  text-align: center;
}

/* ===== Hero ===== */
.hero {
  padding-top: 60px;
}

.hero__inner {
  position: relative;
  text-align: center;
  padding-bottom: 72px;
}

.hero__title {
  font-size: 3.25rem;
  font-weight: 500;
  line-height: 1.4;
  color: var(--black);
  margin-bottom: 32px;
}

.hero__subtitle {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--text);
  margin-bottom: 42px;
}

.hero__btn { margin-top: 70px; margin-bottom: 28px; }

.hero__note {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text);
}

.hero__note-link { color: var(--purple); font-weight: 600; }
.dot-sep { color: var(--purple); }

/* Floating bubbles */
.bubble-img {
  position: absolute;
  height: auto;
  pointer-events: none;
}
.bubble-img--1 { top: 55px;  left: 4%;  width: 200px; }
.bubble-img--2 { top: 160px; left: 10%; width: 135px; }
.bubble-img--3 { top: 265px; left: 1%;  width: 195px; }
.bubble-img--4 { top: 70px;  right: 3%; width: 190px; }
.bubble-img--5 { top: 185px; right: 7%; width: 198px; }
.bubble-img--6 { top: 280px; right: -1%; width: 200px; }

/* Hero card */
.hero-card {
  display: flex;
  align-items: stretch;
  min-height: 480px;
  border-radius: 28px;
  overflow: visible;
  box-shadow: 0 30px 70px rgba(80, 90, 150, 0.12);
}
.hero-card__text {
  flex: 0 0 38%;
  padding: 56px 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: #fff;
  border-radius: 28px 0 0 28px;
  position: relative;
  z-index: 1;
}
.hero-card__title {
  font-size: 1.7rem;
  font-weight: 500;
  color: var(--black);
  line-height: 1.25;
  text-align: center;
  margin-bottom: 28px;
}
.hero-card__socials {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}
.hero-card__logo {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
}
.hero-card__media {
  flex: 1 1 auto;
  display: flex;
  align-items: stretch;
  background: var(--purple);
  border-radius: 0 28px 28px 0;
  overflow: hidden;
  position: relative;
  z-index: 2;
}
.hero-card__placeholder {
  width: 100%;
  min-height: 360px;
  background: linear-gradient(145deg, #9D97F0 0%, var(--purple) 42%, var(--purple-dark) 100%);
  border-radius: inherit;
}

/* ===== Niches ===== */
.niches { padding: 90px 0 30px; }
.tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  max-width: 720px;
  margin: 40px auto 0;
}
.tag {
  border: 1px solid rgba(107, 100, 225, 0.4);
  color: var(--purple);
  background: rgba(255, 255, 255, 0.4);
  border-radius: 9px;
  padding: 9px 16px;
  font-size: 0.88rem;
}

/* ===== Features ===== */
.features { padding: 40px 0 30px; }
.features__title { margin-bottom: 30px; }

.feature {
  display: flex;
  align-items: center;
  gap: 60px;
  margin-top: 70px;
}
.feature__text { flex: 1 1 0; min-width: 0; }
.feature__media { flex: 1 1 0; min-width: 0; }
.feature__media img { max-width: 100%; height: auto; }
.feature__placeholder {
  width: 100%;
  min-height: 320px;
  border-radius: 22px;
  background: linear-gradient(145deg, #9D97F0 0%, var(--purple) 42%, var(--purple-dark) 100%);
}

.feature__heading {
  font-size: 2rem;
  font-weight: 500;
  color: var(--black);
  line-height: 1.2;
  margin-bottom: 22px;
}
.feature__heading .accent { color: var(--purple); }
.feature__desc {
  font-size: 1rem;
  color: var(--text);
  line-height: 1.7;
}

.features__cta {
  text-align: center;
  margin-top: 70px;
}

/* ===== Tariffs ===== */
.tariffs { padding: 70px 0; }
.tariffs--stub .tariffs__title { margin-bottom: 28px; }
.tariffs__placeholder {
  width: 100%;
  min-height: 320px;
  border-radius: 22px;
  background: linear-gradient(145deg, #9D97F0 0%, var(--purple) 42%, var(--purple-dark) 100%);
}
.tariffs--page { padding-top: 56px; }
.tariffs__title { margin-bottom: 16px; }
.tariffs__note {
  text-align: center;
  color: var(--text);
  font-size: 0.95rem;
  margin-bottom: 28px;
}
.tariffs__note strong {
  color: var(--purple);
  font-weight: 600;
}
.tariffs__period {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-bottom: 48px;
  padding-top: 12px;
}
.tariffs__period-btn {
  position: relative;
  z-index: 1;
  border: none;
  border-radius: 999px;
  padding: 14px 36px;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1;
  color: var(--black);
  background: #F0F1F3;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.tariffs__period-btn.is-active {
  z-index: 2;
  background: var(--black);
  color: #fff;
}
.tariffs__period-discount {
  position: absolute;
  top: -10px;
  right: 4px;
  z-index: 3;
  padding: 4px 7px;
  border-radius: 8px;
  background: #34C759;
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1;
  pointer-events: none;
}
.tariffs__grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: stretch;
  gap: 28px;
}
.tariff-card {
  display: flex;
  flex-direction: column;
  flex: 1 1 300px;
  max-width: 360px;
  width: 100%;
  min-height: 100%;
  background: #fff;
  border: 1px solid #E3E8EF;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(80, 90, 150, 0.07);
}
.tariff-card--featured {
  box-shadow: 0 30px 70px rgba(80, 90, 150, 0.12);
}
.tariff-card__top {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-height: 142px;
  padding: 22px 22px 18px;
  background: #fff;
  border-bottom: 1px solid #E3E8EF;
  box-sizing: border-box;
}
.tariff-card--featured .tariff-card__top {
  position: relative;
  background: var(--purple);
  border-bottom: none;
}
.tariff-card__inner {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 18px 22px 32px;
  min-height: 280px;
}
.tariff-card__badge {
  position: absolute;
  top: 14px;
  right: 14px;
  display: inline-block;
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 600;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.35);
}
.tariff-card__name {
  font-size: 1.35rem;
  font-weight: 500;
  color: var(--purple);
  line-height: 1.2;
  margin-bottom: 8px;
}
.tariff-card--featured .tariff-card__name {
  color: #fff;
  margin-bottom: 10px;
  padding-right: 72px;
}
.tariff-card__free {
  font-size: 1.85rem;
  font-weight: 700;
  color: var(--black);
  line-height: 1.1;
  margin-bottom: 6px;
}
.tariff-card__sub {
  font-size: 0.82rem;
  color: var(--text);
  line-height: 1.4;
  margin-bottom: 0;
}
.tariff-card__includes {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--black);
  margin-bottom: 10px;
}
.tariff-card__pricing {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-height: 0;
  margin-top: auto;
}
.tariff-card__price {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--black);
  line-height: 1;
}
.tariff-card__price--lg {
  font-size: 1.85rem;
  font-weight: 700;
  line-height: 1.1;
}
.tariff-card__price--lg span {
  font-size: inherit;
  font-weight: inherit;
  color: inherit;
}
.tariff-card--featured .tariff-card__price { color: #fff; }
.tariff-card__price:not(.tariff-card__price--lg) span {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-light);
}
.tariff-card--featured .tariff-card__price:not(.tariff-card__price--lg) span { color: rgba(255, 255, 255, 0.75); }
.tariff-card__price-old {
  margin-top: 0;
  margin-bottom: 6px;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-light);
  text-decoration: line-through;
  line-height: 1.2;
}
.tariff-card--featured .tariff-card__price-old { color: rgba(255, 255, 255, 0.65); }
.tariff-card__price-old[hidden] { display: none; }
.tariff-card__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
  margin-bottom: 0;
}
.tariff-card__list li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.88rem;
  color: var(--black);
  line-height: 1.4;
}
.tariff-card .btn--primary {
  margin-top: auto;
  flex-shrink: 0;
  padding: 13px 20px;
  font-size: 0.9rem;
}
.tariff-card:not(.tariff-card--featured) .btn--primary {
  background-color: #ECEBFB;
  background-color: color-mix(in srgb, var(--purple) 18%, #fff);
  color: var(--purple);
}
.tariff-card:not(.tariff-card--featured) .btn--primary:hover {
  background-color: var(--purple-dark);
  color: #fff;
}

/* ===== Steps ===== */
.steps { padding: 70px 0; }
.steps__title { text-align: left; margin-bottom: 40px; }

.step {
  position: relative;
  background: #fff;
  border-radius: 22px;
  height: 190px;
  margin-bottom: 28px;
  overflow: hidden;
  box-shadow: 0 20px 50px rgba(80, 90, 150, 0.07);
  display: flex;
  align-items: center;
}
.step__num {
  position: absolute;
  left: 40px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 9rem;
  font-weight: 800;
  color: #DCEFFB;
  line-height: 1;
  pointer-events: none;
}
.step__body {
  margin-left: 48%;
}
.step__heading {
  font-size: 1.7rem;
  font-weight: 500;
  color: var(--black);
  margin-bottom: 12px;
}
.step__desc { font-size: 0.95rem; color: var(--text); line-height: 1.6; }

.steps__caption {
  text-align: center;
  color: var(--text-light);
  font-size: 0.95rem;
  margin-top: 36px;
}

/* ===== Register ===== */
.register { padding: 70px 0; }
.register__inner {
  display: flex;
  align-items: flex-start;
  gap: 80px;
}
.register__left { flex: 1 1 0; padding-top: 10px; }
.register__title {
  font-size: 2.1rem;
  font-weight: 500;
  color: var(--black);
  line-height: 1.2;
  margin-bottom: 36px;
}
.register__list { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.register__list li {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.95rem;
  line-height: 1.35;
  color: var(--black);
}
.check { color: var(--purple); font-weight: 700; }

.register__form { flex: 1 1 0; display: flex; flex-direction: column; gap: 14px; }

.field {
  width: 100%;
  background: #fff;
  border: 1px solid #E3E8EF;
  border-radius: 12px;
  padding: 16px 18px;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--black);
}
.field::placeholder { color: var(--text-light); }
.field:focus { outline: none; border-color: var(--purple); }

.agree {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.8rem;
  color: var(--text-light);
  cursor: pointer;
  line-height: 1.45;
}
.agree input {
  width: 16px;
  height: 16px;
  margin-top: 2px;
  flex-shrink: 0;
  accent-color: var(--purple);
}
.agree a,
.agree__underline {
  color: inherit;
  text-decoration: underline;
}

/* ===== Auth (login) ===== */
.auth-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.auth-header .header__inner { justify-content: space-between; }
.auth-header .header__nav {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}
.auth-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 24px 64px;
}
.auth-card {
  width: 100%;
  max-width: 420px;
  background: #fff;
  border: 1px solid #E3E8EF;
  border-radius: 16px;
  padding: 36px 32px 32px;
  box-shadow: 0 20px 50px rgba(80, 90, 150, 0.1);
}
.auth-card__title {
  font-size: 1.75rem;
  font-weight: 500;
  color: var(--black);
  margin-bottom: 10px;
}
.auth-card__subtitle {
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--text);
  margin-bottom: 28px;
}
.auth-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.auth-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.auth-field__label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--black);
}
.field-password {
  position: relative;
}
.field-password__input {
  padding-right: 48px;
}
.field-password__toggle {
  position: absolute;
  top: 50%;
  right: 14px;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  border-radius: 8px;
  background: none;
  color: var(--text-light);
  cursor: pointer;
  transition: color 0.15s ease, background-color 0.15s ease;
}
.field-password__toggle:hover {
  color: var(--purple);
  background-color: color-mix(in srgb, var(--purple) 8%, transparent);
}
.field-password__toggle:focus-visible {
  outline: 2px solid var(--purple);
  outline-offset: 2px;
}
.field-password__icon[hidden] { display: none; }
.auth-form__forgot {
  align-self: flex-start;
  font-size: 0.85rem;
  color: var(--purple);
  margin-top: -4px;
  transition: color 0.15s ease;
}
.auth-form__forgot:hover { color: var(--purple-dark); }
.auth-card__footer {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid #E3E8EF;
  text-align: center;
  font-size: 0.9rem;
  color: var(--text);
}
.auth-card__footer a {
  color: var(--purple);
  font-weight: 500;
  transition: color 0.15s ease;
}
.auth-card__footer a:hover { color: var(--purple-dark); }

.field--code {
  text-align: center;
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: 0.28em;
  padding-left: 18px;
}
.auth-verify__hint,
.auth-signed-in__text {
  margin: 0 0 8px;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--text);
}
.auth-verify__hint strong,
.auth-signed-in__text strong {
  color: var(--black);
  font-weight: 600;
}
.auth-form[hidden],
.auth-signed-in[hidden] { display: none; }
.auth-signed-in {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* ===== Knowledge base ===== */
.kb-page {
  padding: 40px 0 70px;
}
.kb-page__head {
  margin-bottom: 32px;
}
.kb-page__title {
  font-size: 2.25rem;
  font-weight: 500;
  color: var(--black);
  margin-bottom: 10px;
}
.kb-page__subtitle {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
  max-width: 640px;
}
.kb-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}
.kb-sidebar {
  position: sticky;
  top: 88px;
  background: #fff;
  border: 1px solid #E3E8EF;
  border-radius: 16px;
  padding: 18px;
}
.kb-search {
  position: relative;
  display: block;
  margin-bottom: 16px;
}
.kb-search__icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-light);
  pointer-events: none;
}
.kb-search__input {
  padding: 13px 14px 13px 42px;
  font-size: 0.88rem;
}
.kb-nav__group {
  border-top: 1px solid #EEF2F6;
}
.kb-nav__group:first-child { border-top: none; }
.kb-nav__group[hidden] { display: none; }
.kb-nav__toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 4px;
  border: none;
  background: none;
  font-family: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--black);
  text-align: left;
  cursor: pointer;
  position: relative;
  z-index: 1;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  transition: color 0.15s ease;
}
.kb-nav__toggle:hover { color: var(--purple); }
.kb-nav__chevron {
  position: relative;
  width: 10px;
  height: 10px;
  flex-shrink: 0;
}
.kb-nav__chevron::before,
.kb-nav__chevron::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 6px;
  height: 1.5px;
  background: currentColor;
  border-radius: 1px;
  transition: transform 0.28s ease;
}
.kb-nav__chevron::before {
  transform: translate(-75%, -50%) rotate(45deg);
}
.kb-nav__chevron::after {
  transform: translate(-25%, -50%) rotate(-45deg);
}
.kb-nav__group.is-open .kb-nav__chevron::before {
  transform: translate(-75%, -50%) rotate(-45deg);
}
.kb-nav__group.is-open .kb-nav__chevron::after {
  transform: translate(-25%, -50%) rotate(45deg);
}
.kb-nav__panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.28s ease;
}
.kb-nav__group.is-open .kb-nav__panel {
  grid-template-rows: 1fr;
}
.kb-nav__list {
  overflow: hidden;
  min-height: 0;
  list-style: none;
  margin: 0;
  padding: 0 0 8px;
}
.kb-nav__list li[hidden] { display: none; }
.kb-nav__link {
  display: block;
  padding: 9px 10px 9px 14px;
  border-radius: 10px;
  font-size: 0.86rem;
  line-height: 1.45;
  color: var(--text);
  transition: background-color 0.15s ease, color 0.15s ease;
}
.kb-nav__link:hover {
  background: color-mix(in srgb, var(--purple) 8%, #fff);
  color: var(--purple);
}
.kb-nav__link.is-active {
  background: color-mix(in srgb, var(--purple) 12%, #fff);
  color: var(--purple);
  font-weight: 600;
}
.kb-sidebar__empty {
  font-size: 0.85rem;
  color: var(--text-light);
  text-align: center;
  padding: 12px 0 4px;
}
.kb-sidebar__empty[hidden] { display: none; }
.kb-nav[hidden] { display: none; }
.kb-main {
  min-width: 0;
}
.kb-article {
  background: #fff;
  border: 1px solid #E3E8EF;
  border-radius: 16px;
  padding: 32px 36px;
  margin-bottom: 24px;
}
.kb-article[hidden] { display: none; }
.kb-article__title {
  font-size: 1.5rem;
  font-weight: 500;
  line-height: 1.35;
  color: var(--black);
  margin-bottom: 18px;
}
.kb-article__body {
  font-size: 0.98rem;
  line-height: 1.75;
  color: var(--text);
}
.kb-article__body p + p { margin-top: 14px; }
.kb-article__body a {
  color: var(--purple);
  text-decoration: underline;
}
.kb-article__body a:hover { color: var(--purple-dark); }
.kb-cta-section {
  margin-top: 48px;
  padding-top: 40px;
  border-top: 1px solid #E3E8EF;
}
.kb-cta {
  width: 100%;
  text-align: center;
  background: #fff;
  border: 1px solid #E3E8EF;
  border-radius: 16px;
  padding: 40px 32px;
}
.kb-cta__title {
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--black);
  margin-bottom: 10px;
}
.kb-cta__text {
  font-size: 0.95rem;
  color: var(--text);
  margin-bottom: 22px;
}

/* ===== Contacts ===== */
.contacts-page {
  padding: 40px 0 70px;
}
.contacts-page__head {
  margin-bottom: 40px;
}
.contacts-page__title {
  font-size: 2.25rem;
  font-weight: 500;
  color: var(--black);
  margin-bottom: 10px;
}
.contacts-page__subtitle {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
  max-width: 640px;
}
.contacts-section + .contacts-section {
  margin-top: 48px;
  padding-top: 48px;
  border-top: 1px solid #E3E8EF;
}
.contacts-section__title {
  font-size: 1.35rem;
  font-weight: 500;
  color: var(--black);
  margin-bottom: 22px;
}
.contacts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.contacts-grid--docs {
  grid-template-columns: repeat(2, 1fr);
}
.contacts-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  background: #fff;
  border: 1px solid #E3E8EF;
  border-radius: 16px;
  padding: 24px 22px;
  min-height: 180px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease;
}
a.contacts-card:hover {
  border-color: color-mix(in srgb, var(--purple) 35%, #E3E8EF);
  box-shadow: 0 12px 32px rgba(80, 90, 150, 0.1);
  transform: translateY(-2px);
}
.contacts-card--static {
  cursor: default;
}
.contacts-card__icon,
.contacts-card__doc-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--purple) 10%, #fff);
  color: var(--purple);
  flex-shrink: 0;
}
.contacts-card__title {
  font-size: 1.05rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--black);
}
.contacts-card__desc {
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--text);
  flex: 1;
}
.contacts-card__action {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--purple);
  margin-top: auto;
}
.contacts-card__socials {
  height: 30px;
  width: auto;
  margin-top: auto;
  align-self: flex-start;
}

/* ===== Legal document ===== */
.legal-doc {
  padding: 40px 0 70px;
}
.legal-doc__inner {
  max-width: 820px;
}
.legal-doc__title {
  text-align: center;
  font-size: 1.75rem;
  font-weight: 500;
  line-height: 1.35;
  color: var(--black);
  margin-bottom: 10px;
}
.legal-doc__edition {
  text-align: right;
  font-size: 0.95rem;
  color: var(--text);
  margin-bottom: 36px;
}
.legal-doc__content {
  font-size: 0.95rem;
  line-height: 1.75;
  color: var(--black);
}
.legal-doc__item {
  display: flex;
  gap: 0;
  align-items: flex-start;
}
.legal-doc__item + .legal-doc__item,
.legal-doc__item + .legal-doc__list,
.legal-doc__list + .legal-doc__item,
.legal-doc__list + .legal-doc__list {
  margin-top: 14px;
}
.legal-doc__num {
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
  padding-right: 0.35em;
}
.legal-doc__item--level-2,
.legal-doc__item--level-3 {
  padding-left: 1.2em;
}
.legal-doc__item--level-3 {
  padding-left: 2.4em;
}
.legal-doc__item--plain,
.legal-doc__item--term {
  display: block;
}
.legal-doc__term {
  display: inline;
  font-weight: 600;
}
.legal-doc__text {
  flex: 1;
  min-width: 0;
}
.legal-doc__list {
  margin: 0;
  padding-left: 3.2em;
}
.legal-doc__list li + li {
  margin-top: 8px;
}
.legal-doc__content strong {
  font-weight: 600;
}

/* ===== Cookie banner ===== */
.cookie-banner {
  position: fixed;
  left: 24px;
  bottom: 24px;
  z-index: 60;
  width: min(380px, calc(100vw - 48px));
  padding: 20px 22px;
  background: #fff;
  border: 1px solid #E3E8EF;
  border-radius: 16px;
  box-shadow: 0 20px 50px rgba(80, 90, 150, 0.15);
}
.cookie-banner[hidden] { display: none; }
.cookie-banner__text {
  font-size: 0.82rem;
  line-height: 1.55;
  color: var(--text);
  margin-bottom: 16px;
}
.cookie-banner__text a {
  color: var(--purple);
  text-decoration: underline;
}
.cookie-banner__btn {
  width: 100%;
  padding: 13px 20px;
  font-size: 0.9rem;
}

/* ===== FAQ ===== */
.faq { padding: 50px 0; }
.faq__item {
  background: #fff;
  border-radius: 16px;
  margin-bottom: 18px;
  overflow: hidden;
}
.faq__q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background: none;
  border: none;
  font-family: inherit;
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--black);
  text-align: left;
  padding: 26px 30px;
  cursor: pointer;
}
.faq__q-text { flex: 1; min-width: 0; text-align: left; }
.faq__asterisk {
  color: #F87171;
  font-size: 0.55em;
  font-weight: 600;
  line-height: 0;
  vertical-align: super;
  margin-left: 1px;
}
.faq__icon {
  position: relative;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}
.faq__icon::before,
.faq__icon::after {
  content: "";
  position: absolute;
  background: var(--purple);
  border-radius: 2px;
}
.faq__icon::before { top: 10px; left: 0; width: 22px; height: 2px; }
.faq__icon::after  { left: 10px; top: 0; width: 2px; height: 22px; transition: transform 0.2s ease; }
.faq__item--open .faq__icon::after { transform: scaleY(0); }

.faq__a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}
.faq__a p {
  padding: 0 30px 28px;
  color: var(--text-light);
  font-size: 0.98rem;
  line-height: 1.7;
}
.faq__item--open .faq__a { max-height: 320px; }

/* ===== Footer ===== */
.footer {
  background: #fff;
  padding: 50px 0 40px;
}
.footer__top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding-bottom: 30px;
}
.footer__brand { display: flex; align-items: flex-start; gap: 26px; }
.footer__logo { font-size: 1.5rem; font-weight: 700; color: var(--black); }
.footer__copy { font-size: 0.8rem; color: var(--text-light); line-height: 1.5; }
.footer__support { display: flex; align-items: center; gap: 16px; }
.footer__support span { font-weight: 600; color: var(--black); font-size: 0.95rem; }
.footer__support img { height: 30px; width: auto; }

.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 30px;
}
.footer__disclaimer { font-size: 0.75rem; color: var(--text-light); line-height: 1.5; }
.footer__links { display: flex; flex-direction: column; gap: 6px; text-align: right; }
.footer__links a {
  font-size: 0.8rem;
  color: var(--text-light);
  text-decoration: underline;
}

/* ===== Responsive: tablet ===== */
@media (max-width: 960px) {
  .hero__title { font-size: 2.6rem; }
  .feature { gap: 36px; }
  .feature__heading { font-size: 1.7rem; }
  .step__num { font-size: 7rem; left: 28px; }
  .step__body { margin-left: 44%; }
  .register__inner { gap: 48px; }
  .tariffs__grid { gap: 18px; }
  .tariff-card { flex-basis: calc(50% - 9px); max-width: none; }
  .kb-layout { grid-template-columns: 240px minmax(0, 1fr); gap: 24px; }
  .contacts-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ===== Responsive: mobile ===== */
@media (max-width: 760px) {
  .container { padding: 0 18px; }
  body { padding-top: 64px; }

  /* On mobile let text reflow naturally instead of using desktop line breaks */
  br { display: none; }

  /* Header */
  .header__nav { display: none; }
  .header__actions { display: none; }
  .header__burger { display: flex; }
  .header__inner { height: 64px; }

  .header__nav.is-open {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    transform: none;
    background: #fff;
    padding: 22px 24px 28px;
    box-shadow: 0 24px 40px rgba(80, 90, 150, 0.12);
    border-radius: 0 0 18px 18px;
  }
  .header__nav.is-open .header__actions--mobile {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-top: 6px;
  }

  /* Section titles */
  .section-title { font-size: 1.5rem; }

  /* Hero */
  .hero { padding-top: 30px; }
  .hero__inner { padding-bottom: 34px; }
  .bubble-img { display: none; }
  .hero__title { font-size: 1.65rem; margin-bottom: 16px; }
  .hero__subtitle { font-size: 0.95rem; margin-bottom: 26px; }
  .hero__subtitle br { display: none; }
  .hero__btn { width: 100%; max-width: 340px; margin-top: 70px; }

  .hero-card { flex-direction: column; align-items: stretch; border-radius: 22px; min-height: auto; }
  .hero-card__text { flex: none; width: 100%; min-width: 0; padding: 30px 26px; align-items: center; text-align: center; border-radius: 22px 22px 0 0; }
  .hero-card__title { font-size: 1.45rem; text-align: center; }
  .hero-card__media { flex: none; width: 100%; min-height: 280px; border-radius: 0 0 22px 22px; }
  .hero-card__placeholder { min-height: 280px; }

  /* Niches */
  .niches { padding: 50px 0 20px; }
  .section-title br { display: none; }
  .tags { gap: 10px; margin-top: 26px; }
  .tag { font-size: 0.82rem; padding: 8px 13px; }

  /* Features */
  .features { padding: 20px 0; }
  .feature, .feature--reverse { flex-direction: column; align-items: stretch; gap: 24px; margin-top: 50px; }
  .feature__text, .feature__media { flex: none; width: 100%; min-width: 0; }
  .feature__media img { width: 100%; height: auto; }
  .feature__placeholder { min-height: 240px; }
  .feature--reverse .feature__media { order: 2; }
  .feature--reverse .feature__text { order: 1; }
  .feature__heading { font-size: 1.5rem; }
  .feature__heading br { display: none; }
  .feature__desc br { display: none; }
  .features__cta { margin-top: 50px; }
  .features__cta .btn { width: 100%; max-width: 340px; }

  /* Tariffs */
  .tariffs { padding: 50px 0; }
  .tariffs__placeholder { min-height: 240px; }
  .tariffs__note { margin-bottom: 22px; }
  .tariffs__period { gap: 10px; margin-bottom: 32px; }
  .tariffs__period-btn { padding: 12px 24px; font-size: 0.92rem; }
  .tariff-card { flex: 1 1 100%; max-width: 420px; }
  .tariff-card__free,
  .tariff-card__price--lg { font-size: 1.6rem; }

  /* Steps */
  .steps { padding: 50px 0; }
  .steps__title { font-size: 1.5rem; }
  .step { height: auto; min-height: 150px; padding: 30px 26px; }
  .step__num { font-size: 5rem; left: 18px; opacity: 0.7; }
  .step__body { margin-left: auto; text-align: right; max-width: 62%; }
  .step__heading { font-size: 1.25rem; }
  .step__desc br { display: none; }

  /* Register */
  .register { padding: 40px 0; }
  .register__inner { flex-direction: column; align-items: stretch; gap: 30px; }
  .register__left, .register__form { width: 100%; min-width: 0; }
  .register__left { text-align: center; }
  .register__title { font-size: 1.6rem; }
  .register__title br { display: none; }
  .register__list { text-align: left; }
  .register__form { width: 100%; }

  /* FAQ */
  .faq__q { font-size: 0.95rem; padding: 20px 20px; gap: 14px; }
  .faq__a p { padding: 0 20px 22px; font-size: 0.92rem; }

  /* Footer */
  .footer__top { flex-direction: column; gap: 26px; }
  .footer__bottom { flex-direction: column; gap: 20px; }
  .footer__links { text-align: left; }

  .cookie-banner {
    left: 16px;
    bottom: 16px;
    width: calc(100vw - 32px);
    padding: 18px;
  }

  .auth-card { padding: 28px 22px 24px; }
  .auth-card__title { font-size: 1.5rem; }

  .kb-page { padding: 28px 0 50px; }
  .kb-page__title { font-size: 1.75rem; }
  .kb-layout { grid-template-columns: 1fr; gap: 20px; }
  .kb-sidebar { position: static; }
  .kb-article { padding: 24px 20px; }
  .kb-article__title { font-size: 1.25rem; }
  .kb-cta-section { margin-top: 32px; padding-top: 28px; }
  .kb-cta { padding: 28px 22px; }

  .contacts-page { padding: 28px 0 50px; }
  .contacts-page__title { font-size: 1.75rem; }
  .contacts-section + .contacts-section { margin-top: 32px; padding-top: 32px; }
  .contacts-grid,
  .contacts-grid--docs { grid-template-columns: 1fr; gap: 14px; }
  .contacts-card { min-height: auto; }

  .legal-doc { padding: 28px 0 50px; }
  .legal-doc__title { font-size: 1.45rem; }
  .legal-doc__edition { margin-bottom: 28px; }
}
