﻿:root {
  color-scheme: light;
  --bg: #f7f8fa;
  --bg-grid: rgba(17, 24, 39, .035);
  --surface: rgba(255, 255, 255, .82);
  --surface-solid: #ffffff;
  --surface-soft: #eef1f6;
  --text: #111318;
  --muted: #5e6674;
  --soft: #8891a1;
  --line: rgba(17, 24, 39, .09);
  --line-strong: rgba(17, 24, 39, .16);
  --accent: #ea1b25;
  --accent-strong: #c8141d;
  --accent-soft: rgba(234, 27, 37, .08);
  --dark: #0f1115;
  --danger: #d71f31;
  --success: #0a8f5a;
  --radius: 8px;
  --shadow: 0 22px 72px rgba(15, 18, 26, .08);
  --shadow-strong: 0 30px 92px rgba(15, 18, 26, .14);
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0b0d10;
  --bg-grid: rgba(255, 255, 255, .045);
  --surface: rgba(18, 20, 26, .78);
  --surface-solid: #12141a;
  --surface-soft: #181b22;
  --text: #f6f7fb;
  --muted: #abb2c1;
  --soft: #7a8190;
  --line: rgba(255, 255, 255, .09);
  --line-strong: rgba(255, 255, 255, .16);
  --accent: #ff3a45;
  --accent-strong: #ff6670;
  --accent-soft: rgba(255, 58, 69, .12);
  --dark: #f6f7fb;
  --danger: #ff6b75;
  --success: #39d693;
  --shadow: 0 24px 74px rgba(0, 0, 0, .34);
  --shadow-strong: 0 34px 100px rgba(0, 0, 0, .46);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
  scroll-padding-top: 112px;
}

body {
  min-width: 320px;
  margin: 0;
  position: relative;
  isolation: isolate;
  overflow-x: hidden;
  color: var(--text);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .82), rgba(255, 255, 255, 0) 26%),
    linear-gradient(90deg, var(--bg-grid) 1px, transparent 1px),
    linear-gradient(var(--bg-grid) 1px, transparent 1px),
    var(--bg);
  background-size: auto, 96px 96px, 96px 96px, auto;
  background-attachment: fixed;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, Helvetica, sans-serif;
  letter-spacing: 0;
  transition: background-color .28s ease, color .28s ease;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: .36;
  background-repeat: repeat-x;
  background-position: 0 7vh, -260px 38vh, 160px 72vh;
  background-size: 1800px 36vh, 1700px 34vh, 1900px 36vh;
  mix-blend-mode: multiply;
}

body::before {
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1600 220'%3E%3Cg fill='none' stroke='%23ea1b25' stroke-opacity='.34' stroke-width='2.8' stroke-linecap='round'%3E%3Cpath d='M0 90 C 90 30 150 150 240 90 S 390 30 480 90 S 630 150 720 90 S 870 30 960 90 S 1110 150 1200 90 S 1350 30 1440 90 S 1530 150 1600 90'/%3E%3Cpath d='M0 128 C 100 70 170 186 260 128 S 430 70 520 128 S 690 186 780 128 S 950 70 1040 128 S 1210 186 1300 128 S 1470 70 1560 128 S 1590 186 1600 128' stroke-opacity='.24'/%3E%3Cpath d='M0 54 C 80 10 170 98 250 54 S 410 10 490 54 S 650 98 730 54 S 890 10 970 54 S 1130 98 1210 54 S 1370 10 1450 54 S 1530 98 1600 54' stroke-opacity='.18'/%3E%3C/g%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1600 220'%3E%3Cg fill='none' stroke='%23ea1b25' stroke-opacity='.28' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M0 90 C 90 30 150 150 240 90 S 390 30 480 90 S 630 150 720 90 S 870 30 960 90 S 1110 150 1200 90 S 1350 30 1440 90 S 1530 150 1600 90'/%3E%3Cpath d='M0 128 C 100 70 170 186 260 128 S 430 70 520 128 S 690 186 780 128 S 950 70 1040 128 S 1210 186 1300 128 S 1470 70 1560 128 S 1590 186 1600 128' stroke-opacity='.2'/%3E%3C/g%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1600 220'%3E%3Cg fill='none' stroke='%23ea1b25' stroke-opacity='.3' stroke-width='2.6' stroke-linecap='round'%3E%3Cpath d='M0 90 C 90 30 150 150 240 90 S 390 30 480 90 S 630 150 720 90 S 870 30 960 90 S 1110 150 1200 90 S 1350 30 1440 90 S 1530 150 1600 90'/%3E%3Cpath d='M0 54 C 80 10 170 98 250 54 S 410 10 490 54 S 650 98 730 54 S 890 10 970 54 S 1130 98 1210 54 S 1370 10 1450 54 S 1530 98 1600 54' stroke-opacity='.18'/%3E%3C/g%3E%3C/svg%3E");
  animation: wave-drift 24s linear infinite;
}

body::after {
  opacity: .24;
  background-position: 220px 22vh, -180px 58vh;
  background-size: 1650px 30vh, 1750px 32vh;
  filter: blur(.6px);
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1400 180'%3E%3Cg fill='none' stroke='%23ea1b25' stroke-opacity='.24' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M0 78 C 75 28 145 128 220 78 S 370 28 445 78 S 595 128 670 78 S 820 28 895 78 S 1045 128 1120 78 S 1270 28 1345 78 S 1385 128 1400 78'/%3E%3Cpath d='M0 118 C 90 68 165 168 255 118 S 420 68 510 118 S 675 168 765 118 S 930 68 1020 118 S 1185 168 1275 118 S 1380 68 1400 118' stroke-opacity='.16'/%3E%3C/g%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1400 180'%3E%3Cg fill='none' stroke='%23ea1b25' stroke-opacity='.2' stroke-width='1.8' stroke-linecap='round'%3E%3Cpath d='M0 78 C 75 28 145 128 220 78 S 370 28 445 78 S 595 128 670 78 S 820 28 895 78 S 1045 128 1120 78 S 1270 28 1345 78 S 1385 128 1400 78'/%3E%3C/g%3E%3C/svg%3E");
  animation: wave-drift-reverse 30s linear infinite;
}

:root[data-theme="dark"] body {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .045), rgba(255, 255, 255, 0) 26%),
    linear-gradient(90deg, var(--bg-grid) 1px, transparent 1px),
    linear-gradient(var(--bg-grid) 1px, transparent 1px),
    var(--bg);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: .62;
}

h1,
h2,
h3,
p {
  margin: 0;
}

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

.site-shell {
  width: min(1180px, 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: 18px 18px 34px;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 1;
}

.compact-shell {
  width: min(980px, 100%);
}

main {
  flex: 1 0 auto;
}

.surface-panel,
.glass-panel {
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, .55);
  backdrop-filter: blur(18px) saturate(130%);
  -webkit-backdrop-filter: blur(18px) saturate(130%);
}

:root[data-theme="dark"] .surface-panel,
:root[data-theme="dark"] .glass-panel {
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, .07);
}

.topbar {
  position: sticky;
  top: 6px;
  z-index: 20;
  width: 100vw;
  min-height: 60px;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr) max-content;
  align-items: center;
  gap: clamp(18px, 2.6vw, 52px);
  padding: 8px clamp(12px, 1.6vw, 24px);
  border-radius: 0 0 var(--radius) var(--radius);
  transition: transform .26s ease, opacity .26s ease, border-color .2s ease, box-shadow .2s ease;
  will-change: transform, opacity;
}

.topbar.is-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-125%);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  flex: 0 0 auto;
}

.brand img {
  width: 48px;
  height: 48px;
  object-fit: contain;
  filter: drop-shadow(0 12px 24px rgba(227, 6, 19, .16));
}

.brand span {
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 22px;
  font-weight: 950;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
}

.brand b {
  color: var(--accent);
  font-weight: 950;
}

.nav-links,
.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-links {
  justify-content: space-between;
  justify-self: center;
  width: 100%;
  min-width: 0;
  gap: 10px;
  overflow: hidden;
}

.topbar-actions {
  flex: 0 0 auto;
  margin-left: auto;
  justify-self: end;
  min-width: max-content;
}

.nav-links {
  color: var(--muted);
  font-size: 13px;
  font-weight: 750;
}

.nav-links a {
  flex: 1 1 0;
  min-width: 0;
  padding: 9px 8px;
  border-radius: var(--radius);
  text-align: center;
  white-space: normal;
  transition: background .18s ease, color .18s ease;
}

.nav-links a:hover,
.footer a:hover {
  color: var(--accent);
  background: var(--accent-soft);
}

.cabinet-button,
.support-button,
.primary-button,
.ghost-button,
.theme-toggle,
.quick-links a {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  border-radius: var(--radius);
  font-weight: 850;
  line-height: 1;
  white-space: nowrap;
  transition: transform .18s ease, border-color .18s ease, background .18s ease, color .18s ease, box-shadow .18s ease;
}

.primary-button {
  border: 1px solid var(--dark);
  color: var(--surface-solid);
  background: var(--dark);
  box-shadow: 0 16px 34px rgba(17, 19, 24, .18);
}

:root[data-theme="dark"] .primary-button {
  color: #111318;
  background: #f7f8fb;
  border-color: #f7f8fb;
}

.cabinet-button,
.support-button,
.ghost-button,
.quick-links a {
  border: 1px solid var(--line);
  color: var(--text);
  background: rgba(255, 255, 255, .42);
}

:root[data-theme="dark"] .cabinet-button,
:root[data-theme="dark"] .support-button,
:root[data-theme="dark"] .ghost-button,
:root[data-theme="dark"] .quick-links a {
  background: rgba(255, 255, 255, .045);
}

.theme-toggle {
  border: 1px solid var(--line);
  color: var(--text);
  background: var(--surface-solid);
  padding: 0 12px;
}

.theme-toggle-track {
  width: 36px;
  height: 20px;
  position: relative;
  border-radius: 999px;
  background: var(--surface-soft);
  border: 1px solid var(--line);
}

.theme-toggle-knob {
  width: 14px;
  height: 14px;
  position: absolute;
  left: 3px;
  top: 2px;
  border-radius: 50%;
  background: var(--accent);
  transition: transform .22s ease;
}

:root[data-theme="dark"] .theme-toggle-knob {
  transform: translateX(15px);
}

.theme-toggle-label {
  min-width: 52px;
  text-align: left;
  font-size: 13px;
}

.primary-button:hover,
.cabinet-button:hover,
.support-button:hover,
.ghost-button:hover,
.theme-toggle:hover,
.quick-links a:hover {
  transform: translateY(-2px);
  border-color: var(--line-strong);
  box-shadow: 0 16px 34px rgba(17, 19, 24, .12);
}

.ghost-button:hover,
.cabinet-button:hover,
.support-button:hover,
.quick-links a:hover {
  color: var(--accent);
  background: var(--accent-soft);
}

.hero-grid {
  min-height: calc(100vh - 120px);
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(330px, .78fr);
  align-items: center;
  gap: 22px;
  padding: 58px 0 36px;
}

.hero-copy,
.auth-intro-copy,
.entry-copy {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.kicker {
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

h1 {
  max-width: 780px;
  color: var(--text);
  font-size: clamp(44px, 8vw, 88px);
  line-height: .94;
  font-weight: 950;
}

.hero-copy h1 {
  max-width: 720px;
  font-size: clamp(38px, 6.2vw, 72px);
  line-height: .92;
  animation: hero-title-enter .85s cubic-bezier(.2, .8, .2, 1) both, hero-title-glow 7s ease-in-out 1.1s infinite;
  will-change: transform, opacity, text-shadow;
}

h2 {
  color: var(--text);
  font-size: clamp(30px, 4.5vw, 52px);
  line-height: 1.02;
  font-weight: 930;
}

h3 {
  color: var(--text);
  font-size: 21px;
  line-height: 1.15;
  font-weight: 880;
}

.lead {
  max-width: 700px;
  color: var(--muted);
  font-size: clamp(17px, 2.4vw, 22px);
  line-height: 1.55;
}

.hero-actions,
.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.quick-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.quick-links a {
  min-height: 38px;
  padding: 0 13px;
  color: var(--muted);
  font-size: 13px;
}

.hero-board {
  min-height: 540px;
  position: relative;
  overflow: hidden;
  padding: 20px;
  display: grid;
  grid-template-rows: auto 1fr auto auto;
  gap: 16px;
}

.hero-board::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, transparent, rgba(17, 24, 39, .06), transparent),
    linear-gradient(180deg, rgba(255, 255, 255, .25), transparent 32%);
  transform: translateX(-100%);
  animation: board-sheen 6.4s ease-in-out infinite;
}

.board-header,
.board-stats,
.board-steps p {
  position: relative;
  z-index: 1;
}

.board-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--soft);
  font-size: 12px;
  font-weight: 850;
  text-transform: uppercase;
}

.board-header strong {
  color: var(--success);
}

.board-logo {
  position: relative;
  z-index: 1;
  min-height: 210px;
  display: grid;
  place-items: center;
}

.board-logo img {
  width: min(245px, 72%);
  filter: drop-shadow(0 28px 48px rgba(227, 6, 19, .14));
  animation: float-mark 5.8s ease-in-out infinite;
}

.board-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.board-stats div,
.service-facts div {
  padding: 16px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: var(--surface-solid);
}

:root[data-theme="dark"] .board-stats div,
:root[data-theme="dark"] .service-facts div {
  background: rgba(255, 255, 255, .035);
}

.board-stats span,
.metric-card span,
.feature-icon,
.plan-badge,
.step-card span,
.service-facts span {
  color: var(--accent);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.board-stats strong {
  display: block;
  margin-top: 16px;
  color: var(--text);
  font-size: 38px;
  line-height: 1;
}

.board-steps {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 10px;
}

.board-steps p {
  display: flex;
  gap: 12px;
  align-items: center;
  padding: 12px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  color: var(--muted);
  background: rgba(255, 255, 255, .44);
}

:root[data-theme="dark"] .board-steps p {
  background: rgba(255, 255, 255, .035);
}

.board-steps span {
  flex: 0 0 auto;
  color: var(--accent);
  font-weight: 900;
}

.board-steps a {
  color: var(--text);
  font-weight: 850;
}

.inline-action {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  background: var(--surface-solid);
  white-space: nowrap;
  box-shadow: 0 10px 22px rgba(15, 18, 26, .08);
}

.section-grid,
.content-section {
  padding: 46px 0;
}

.section-grid {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(280px, 1fr);
  gap: 20px;
  align-items: end;
}

.section-head {
  max-width: 820px;
  display: grid;
  gap: 14px;
  margin-bottom: 22px;
}

.split-head {
  max-width: none;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
}

.section-text {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.65;
}

.stats-grid,
.dashboard-grid,
.advantages-grid,
.plans-grid,
.steps-grid {
  display: grid;
  gap: 14px;
}

.stats-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.advantages-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.plans-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.steps-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.dashboard-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 22px 0 14px;
}

.metric-card,
.feature-card,
.plan-card,
.step-card {
  min-height: 164px;
  padding: 20px;
}

.metric-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.metric-card strong {
  color: var(--text);
  font-size: clamp(30px, 5vw, 56px);
  line-height: 1;
  overflow-wrap: anywhere;
}

.feature-card,
.plan-card,
.step-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}

.feature-card:hover,
.plan-card:hover,
.step-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-strong);
}

.feature-card p,
.plan-card p,
.step-card p {
  color: var(--muted);
  line-height: 1.58;
}

.plan-card {
  min-height: 250px;
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(234, 27, 37, .05), transparent 44%),
    var(--surface);
}

.plan-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(115deg, transparent 0 36%, rgba(255, 255, 255, .28) 46%, transparent 56% 100%);
  transform: translateX(-120%);
  animation: plan-gloss 8s ease-in-out infinite;
}

:root[data-theme="dark"] .plan-card::before {
  background: linear-gradient(115deg, transparent 0 36%, rgba(255, 255, 255, .08) 46%, transparent 56% 100%);
}

.plan-card > * {
  position: relative;
  z-index: 1;
}

.plan-card.plan-link {
  color: inherit;
  text-decoration: none;
  cursor: pointer;
}

.plan-card.plan-link:hover .plan-action {
  color: var(--accent);
  background: var(--accent-soft);
}

.plan-card h3 {
  min-height: 48px;
}

.plan-note {
  min-height: 44px;
  font-size: 13px;
}

.plan-price {
  margin-top: auto;
  color: var(--text);
  font-size: 32px;
  font-weight: 950;
  line-height: 1;
}

.plan-price small {
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.plan-action {
  margin-top: auto;
  width: fit-content;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  padding: 0 14px;
  border-radius: var(--radius);
  color: var(--text);
  background: var(--surface-solid);
  font-size: 13px;
  font-weight: 850;
  box-shadow: 0 10px 22px rgba(15, 18, 26, .08);
}

.plan-meta {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
}

.plan-meta span {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}

.plan-meta b,
.plan-meta em {
  color: var(--text);
}

.plan-meta em {
  min-width: 0;
  font-style: normal;
  text-align: right;
  overflow-wrap: anywhere;
}

.step-card span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #ffffff;
  background: var(--accent);
}

.referral-strip {
  margin: 42px 0 8px;
  padding: 26px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(420px, .46fr);
  gap: 18px;
  align-items: center;
}

.referral-copy {
  display: grid;
  gap: 14px;
  margin-bottom: 0;
}

.referral-spot {
  min-height: 180px;
  padding: 22px;
  display: grid;
  gap: 10px;
  align-content: center;
  justify-items: start;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: var(--surface-solid);
}

.referral-spot strong {
  color: var(--accent);
  max-width: 100%;
  display: grid;
  gap: 4px;
  font-size: clamp(32px, 3.6vw, 42px);
  line-height: .86;
  font-weight: 950;
  text-transform: uppercase;
  white-space: normal;
  overflow-wrap: normal;
  word-break: keep-all;
  hyphens: none;
}

.referral-spot strong span {
  display: block;
  color: inherit;
  font: inherit;
  line-height: inherit;
  white-space: nowrap;
}

.referral-spot > span {
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
}

.news-strip {
  margin: 32px 0 8px;
  padding: 26px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, .46fr);
  gap: 18px;
  align-items: center;
}

.news-copy {
  display: grid;
  gap: 14px;
}

.news-card {
  min-height: 180px;
  justify-self: stretch;
}

.news-card h3 {
  min-height: 0;
}

.constructor-teaser {
  margin: 34px 0 8px;
  padding: 26px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, .42fr);
  gap: 18px;
  align-items: center;
}

.constructor-teaser-copy {
  display: grid;
  gap: 14px;
}

.constructor-teaser h2 {
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1;
}

.constructor-teaser-meta {
  display: grid;
  gap: 10px;
}

.constructor-teaser-meta span {
  min-height: 48px;
  display: flex;
  align-items: center;
  padding: 0 16px;
  border-radius: var(--radius);
  color: var(--text);
  background: var(--surface-solid);
  font-size: 13px;
  font-weight: 850;
  box-shadow: 0 12px 28px rgba(15, 18, 26, .07);
}

.constructor-panel {
  margin: 16px 0 12px;
  padding: 22px;
  display: grid;
  gap: 18px;
}

.constructor-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.constructor-chipset {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.constructor-chipset span {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border-radius: var(--radius);
  color: var(--muted);
  background: var(--surface-solid);
  font-size: 13px;
  font-weight: 780;
}

.constructor-panel-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, .44fr);
  gap: 16px;
  align-items: stretch;
}

.constructor-controls,
.constructor-summary {
  position: relative;
  overflow: hidden;
  padding: 18px;
  border-radius: calc(var(--radius) + 2px);
  background: var(--surface-solid);
  box-shadow: 0 14px 34px rgba(15, 18, 26, .06);
}

.constructor-controls {
  display: grid;
  gap: 12px;
}

.range-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.range-row input {
  min-height: auto;
  accent-color: var(--accent);
}

.range-row strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 850;
  white-space: nowrap;
}

.constructor-line {
  padding-top: 10px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
}

.constructor-line strong {
  color: var(--text);
}

.constructor-summary {
  display: grid;
  gap: 12px;
  align-content: start;
}

.constructor-summary strong {
  color: var(--text);
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1;
  font-weight: 950;
}

.constructor-summary p {
  color: var(--muted);
  line-height: 1.55;
}

.constructor-summary .full-button {
  width: 100%;
}

.service-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.service-facts strong {
  display: block;
  margin: 12px 0 8px;
  color: var(--text);
  font-size: 34px;
  line-height: 1;
}

.service-facts p {
  color: var(--muted);
  line-height: 1.45;
}

.service-facts .primary-button {
  grid-column: 1 / -1;
}

.auth-layout {
  min-height: calc(100vh - 168px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, .64fr);
  gap: 18px;
  align-items: center;
  padding: 42px 0;
}

.auth-intro {
  min-height: 360px;
  position: relative;
  overflow: hidden;
  display: grid;
  grid-template-columns: 178px minmax(0, 1fr);
  align-items: center;
  gap: 26px;
  padding: 28px;
}

.auth-intro::before,
.empty-state::before,
.cabinet-head::before,
.subscription-card::before,
.qr-card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(120deg, transparent 8%, rgba(255, 255, 255, .24) 42%, transparent 72%);
  transform: translateX(-110%);
  animation: board-sheen 7.2s ease-in-out infinite;
}

:root[data-theme="dark"] .auth-intro::before,
:root[data-theme="dark"] .empty-state::before,
:root[data-theme="dark"] .cabinet-head::before,
:root[data-theme="dark"] .subscription-card::before,
:root[data-theme="dark"] .qr-card::before {
  background: linear-gradient(120deg, transparent 8%, rgba(255, 255, 255, .055) 42%, transparent 72%);
}

.vignette-mark,
.mini-mark {
  position: relative;
  display: grid;
  place-items: center;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background:
    radial-gradient(circle at 50% 45%, rgba(234, 27, 37, .13), transparent 54%),
    linear-gradient(180deg, rgba(255, 255, 255, .64), rgba(255, 255, 255, .18)),
    var(--surface-soft);
  overflow: hidden;
}

:root[data-theme="dark"] .vignette-mark,
:root[data-theme="dark"] .mini-mark {
  background:
    radial-gradient(circle at 50% 45%, rgba(255, 58, 69, .2), transparent 56%),
    linear-gradient(180deg, rgba(255, 255, 255, .08), rgba(255, 255, 255, .02)),
    var(--surface-soft);
}

.vignette-mark {
  width: 178px;
  height: 178px;
}

.vignette-mark img {
  width: 118px;
  filter: drop-shadow(0 24px 34px rgba(227, 6, 19, .18));
  animation: float-mark 5.8s ease-in-out infinite;
}

.auth-intro-copy,
.entry-copy,
.cabinet-title,
.subscription-card > *,
.qr-card > * {
  position: relative;
  z-index: 1;
}

.auth-intro h1 {
  max-width: 500px;
  font-size: clamp(34px, 4.8vw, 54px);
  line-height: .98;
}

.auth-intro .lead,
.empty-state .lead {
  max-width: 560px;
  font-size: clamp(15px, 2vw, 18px);
}

.auth-points {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.auth-points span {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  color: var(--muted);
  background: rgba(255, 255, 255, .42);
  font-size: 13px;
  font-weight: 780;
}

:root[data-theme="dark"] .auth-points span {
  background: rgba(255, 255, 255, .035);
}

.auth-card {
  padding: 22px;
}

form {
  display: grid;
  gap: 14px;
}

label {
  color: var(--text);
  font-size: 14px;
  font-weight: 750;
}

input {
  width: 100%;
  min-height: 50px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 14px;
  color: var(--text);
  background: var(--surface-solid);
  outline: none;
}

input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.code-step {
  display: grid;
  gap: 8px;
}

.check-line {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  color: var(--muted);
  font-weight: 500;
  line-height: 1.45;
}

.check-line input {
  min-height: auto;
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: var(--accent);
}

.check-line a,
.legal-page a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.full-button {
  width: 100%;
}

.form-status {
  min-height: 22px;
  color: var(--muted);
  line-height: 1.45;
}

.cabinet-layout {
  padding: 38px 0 32px;
}

.empty-state {
  max-width: 840px;
  min-height: 300px;
  position: relative;
  overflow: hidden;
  margin: 42px auto;
  padding: 28px;
  display: grid;
  grid-template-columns: 156px minmax(0, 1fr);
  gap: 24px;
  align-items: center;
}

.compact-mark {
  width: 156px;
  height: 156px;
}

.compact-mark img {
  width: 104px;
}

.empty-state h1 {
  font-size: clamp(34px, 4.8vw, 52px);
  line-height: .98;
}

.cabinet-head {
  position: relative;
  overflow: hidden;
  padding: 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 18px;
}

.cabinet-head-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.cabinet-title {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 16px;
}

.mini-mark {
  flex: 0 0 auto;
  width: 72px;
  height: 72px;
}

.mini-mark img {
  width: 48px;
  filter: drop-shadow(0 14px 22px rgba(227, 6, 19, .18));
}

.cabinet-head h1 {
  max-width: none;
  margin-top: 5px;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1;
}

.cabinet-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, .46fr);
  gap: 14px;
}

.subscription-card,
.qr-card {
  position: relative;
  overflow: hidden;
  padding: 20px;
}

.subscription-card {
  display: grid;
  gap: 14px;
}

.card-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.cabinet-layout h2 {
  margin-top: 7px;
  font-size: clamp(26px, 3.6vw, 38px);
  line-height: 1;
}

.cabinet-layout .dashboard-grid {
  margin: 14px 0;
}

.cabinet-layout .metric-card {
  min-height: 124px;
  position: relative;
  overflow: hidden;
  padding: 16px;
}

.cabinet-layout .metric-card::after {
  content: "";
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 0;
  height: 3px;
  border-radius: 999px 999px 0 0;
  background: linear-gradient(90deg, var(--accent), transparent);
  opacity: .78;
}

.cabinet-layout .metric-card[data-state="active"]::after {
  background: linear-gradient(90deg, var(--success), transparent);
}

.cabinet-layout .metric-card[data-state="active"] span {
  color: var(--success);
}

.cabinet-layout .metric-card strong {
  margin-top: 18px;
  font-size: clamp(28px, 3.8vw, 42px);
  letter-spacing: 0;
}

.cabinet-layout .metric-card span {
  font-size: 12px;
}

.copy-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.qr-card {
  display: grid;
  gap: 14px;
}

.qr-box {
  min-height: 246px;
  display: grid;
  place-items: center;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: var(--surface-soft);
  overflow: hidden;
}

.qr-box img {
  width: min(210px, 84%);
  border-radius: var(--radius);
  background: #ffffff;
  box-shadow: 0 18px 46px rgba(17, 19, 24, .12);
}

.qr-box span {
  padding: 18px;
  color: var(--muted);
  text-align: center;
}

.legal-page {
  margin: 52px 0 36px;
  padding: 34px;
}

.legal-page h1 {
  margin: 10px 0 14px;
  font-size: clamp(38px, 6vw, 64px);
}

.legal-page h2 {
  margin-top: 28px;
  font-size: 24px;
}

.legal-page p {
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.65;
}

.footer {
  flex: 0 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  align-items: center;
  justify-content: center;
  margin-top: 20px;
  padding: 18px 0 0;
  border-top: 1px solid var(--line);
  color: var(--soft);
  font-size: 12px;
  line-height: 1.4;
}

.footer span {
  color: var(--text);
  font-weight: 850;
}

.footer a {
  color: var(--muted);
}

#legal-footer,
#advantages,
#plans,
#stats,
#connect,
#referral {
  scroll-margin-top: 112px;
}

.hidden {
  display: none !important;
}

.reveal {
  opacity: 1;
  transform: none;
}

.motion-ready .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .58s ease, transform .58s ease;
}

.motion-ready .reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes board-sheen {
  0%,
  50%,
  100% {
    transform: translateX(-100%);
  }
  70% {
    transform: translateX(100%);
  }
}

@keyframes plan-gloss {
  0%,
  58% {
    transform: translateX(-120%);
  }
  78% {
    transform: translateX(120%);
  }
  100% {
    transform: translateX(120%);
  }
}

@keyframes wave-drift {
  from {
    background-position: 0 7vh, -260px 38vh, 160px 72vh;
  }
  to {
    background-position: 1800px 7vh, 1440px 38vh, 2060px 72vh;
  }
}

@keyframes wave-drift-reverse {
  from {
    background-position: 220px 22vh, -180px 58vh;
  }
  to {
    background-position: -1430px 22vh, -1730px 58vh;
  }
}

@keyframes hero-title-enter {
  from {
    opacity: 0;
    transform: translateY(16px) scale(.985);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes hero-title-glow {
  0%,
  100% {
    text-shadow: 0 0 0 rgba(234, 27, 37, 0);
  }
  50% {
    text-shadow: 0 0 18px rgba(234, 27, 37, .08);
  }
}

@keyframes float-mark {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 1080px) {
  .plans-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .steps-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .topbar {
    display: flex;
    flex-wrap: wrap;
    padding-left: 12px;
    padding-right: 12px;
  }

  .brand {
    flex: 1 1 auto;
  }

  .nav-links {
    order: 3;
    width: 100%;
    justify-content: flex-start;
    overflow-x: auto;
    padding-bottom: 2px;
    justify-self: auto;
  }
}

@media (max-width: 920px) {
  .site-shell {
    padding: 12px 12px 28px;
  }

  .topbar {
    top: 6px;
    flex-wrap: wrap;
    padding-left: 12px;
    padding-right: 12px;
  }

  .topbar-actions {
    flex: 0 0 auto;
  }

  .hero-grid,
  .auth-layout,
  .section-grid,
  .cabinet-grid,
  .referral-strip,
  .news-strip,
  .constructor-teaser,
  .constructor-panel-grid {
    grid-template-columns: 1fr;
  }

  .hero-grid {
    min-height: auto;
    padding-top: 42px;
  }

  .hero-board {
    min-height: 430px;
  }

  .advantages-grid,
  .dashboard-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .news-card {
    min-height: 0;
  }

  .split-head {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .constructor-panel-head {
    flex-direction: column;
  }

  .constructor-chipset {
    justify-content: flex-start;
  }

  .cabinet-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .cabinet-head-actions,
  .cabinet-head .ghost-button,
  .cabinet-head .primary-button {
    align-self: flex-start;
  }
}

@media (max-width: 640px) {
  body::before {
    opacity: .18;
  }

  body::after {
    opacity: .12;
  }

  h1 {
    font-size: clamp(40px, 14vw, 62px);
  }

  .hero-copy h1 {
    max-width: 100%;
    font-size: clamp(34px, 12.5vw, 54px);
  }

  h2 {
    font-size: clamp(30px, 10vw, 42px);
  }

  .brand img {
    width: 42px;
    height: 42px;
  }

  .topbar-actions {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .nav-links {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    overflow: visible;
    padding-bottom: 0;
  }

  .nav-links a {
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1.12;
  }

  .nav-links a:last-child {
    grid-column: 1 / -1;
  }

  .theme-toggle,
  .support-button,
  .cabinet-button {
    width: 100%;
  }

  .cabinet-button {
    grid-column: 1 / -1;
  }

  .hero-actions,
  .button-row,
  .copy-row,
  .quick-links,
  .stats-grid,
  .dashboard-grid,
  .advantages-grid,
  .plans-grid,
  .steps-grid,
  .service-facts {
    grid-template-columns: 1fr;
  }

  .hero-actions > *,
  .button-row > *,
  .quick-links > * {
    width: 100%;
  }

  .auth-intro,
  .empty-state {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .vignette-mark,
  .compact-mark {
    width: 132px;
    height: 132px;
  }

  .vignette-mark img,
  .compact-mark img {
    width: 88px;
  }

  .cabinet-title {
    align-items: flex-start;
  }

  .mini-mark {
    width: 58px;
    height: 58px;
  }

  .mini-mark img {
    width: 38px;
  }

  .referral-spot {
    padding: 14px;
  }

  .referral-spot strong {
    font-size: clamp(24px, 7.6vw, 34px);
  }

  .constructor-teaser-meta {
    grid-template-columns: 1fr;
  }

  .range-row {
    grid-template-columns: 1fr;
  }

  .range-row strong {
    justify-self: start;
  }

  .constructor-summary strong {
    font-size: clamp(30px, 11vw, 42px);
  }

  .board-stats {
    grid-template-columns: 1fr;
  }

  .metric-card,
  .feature-card,
  .plan-card,
  .step-card,
  .auth-card,
  .subscription-card,
  .qr-card,
  .legal-page,
  .empty-state,
  .referral-strip,
  .constructor-teaser,
  .constructor-panel {
    padding: 18px;
  }

  .referral-strip {
    padding: 16px;
  }
}
