:root {
  --navy-950: #070B14;
  --navy-900: #0B1220;
  --navy-800: #121B2E;
  --navy-700: #1B2740;
  --navy-600: #2A3A5C;

  --cyan-400: #22D3EE;
  --teal-400: #2DD4BF;
  --green-400: #34D399;
  --blue-400: #3B82F6;
  --gradient-brand: linear-gradient(90deg, #22D3EE 0%, #2DD4BF 45%, #34D399 100%);

  --text-primary: #FFFFFF;
  --text-secondary: #AEB9CC;
  --text-muted: #8993A8;

  --border-subtle: rgba(45, 212, 191, 0.16);
  --border-hover: rgba(45, 212, 191, 0.4);
  --overlay-teal-soft: rgba(45, 212, 191, 0.12);

  --scrim-header: rgba(7, 11, 20, 0.82);
  --glass-panel: rgba(18, 27, 46, 0.72);

  --font-display: "Onest", "Segoe UI", sans-serif;
  --font-body: "Onest", "Segoe UI", sans-serif;

  --radius-pill: 999px;
  --radius-card: 20px;
  --radius-sm: 12px;

  --ease-settle: cubic-bezier(0.16, 1, 0.3, 1);
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--navy-900);
  color: var(--text-primary);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-display);
  margin: 0;
  line-height: 1.15;
}

p { margin: 0; }

a { color: inherit; }

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

.section { padding: 96px 0; }
.section-alt { background: var(--navy-950); }
.section h2 { font-size: clamp(1.5rem, 3vw + 1rem, 2.25rem); font-weight: 700; margin-bottom: 12px; }
.section-lead {
  color: var(--text-secondary);
  max-width: 62ch;
  font-size: 1.0625rem;
}

:focus-visible {
  outline: 2px solid var(--teal-400);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  z-index: 30;
  background: var(--navy-950);
  color: var(--text-primary);
  padding: 12px 20px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--teal-400);
  text-decoration: none;
  font-weight: 600;
  transition: top 150ms var(--ease-settle);
}
.skip-link:focus-visible {
  top: 16px;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 15px 30px;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: filter 150ms var(--ease-settle), background-color 150ms var(--ease-settle), transform 150ms var(--ease-settle);
}
.btn svg { width: 16px; height: 16px; flex-shrink: 0; }
.btn-primary {
  background: var(--gradient-brand);
  color: var(--navy-950);
}
.btn-primary:hover { filter: brightness(1.08); transform: translateY(-1px); }
.btn-primary:active { transform: translateY(0); filter: brightness(0.98); }
.btn-compact { padding: 13px 26px; font-size: 0.9375rem; }
.btn-secondary {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--teal-400);
  width: 100%;
  margin-top: auto;
}
.btn-secondary:hover { background: var(--overlay-teal-soft); }
.btn-pending {
  display: block;
  text-align: center;
  border-color: var(--navy-600);
  color: var(--text-muted);
  cursor: default;
}
.card-pending-note {
  margin-top: 10px;
  font-size: 0.8125rem;
  color: var(--text-muted);
  text-align: center;
}
.card-pending-note a { color: var(--teal-400); }

/* ---------- Anchor scroll offset (sticky header) ---------- */

#top, #aggregators, #how, #benefits, #help {
  scroll-margin-top: 84px;
}

/* ---------- Noscript fallback ---------- */

.noscript-banner {
  background: var(--navy-950);
  border-bottom: 1px solid var(--navy-700);
  padding: 16px 24px;
  color: var(--text-secondary);
  font-size: 0.9375rem;
  line-height: 1.6;
}
.noscript-banner p { max-width: 70ch; margin: 0 auto; }
.noscript-banner p + p { margin-top: 8px; }
.noscript-banner strong { color: var(--text-primary); }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--scrim-header);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--navy-700);
}
.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding-top: 14px;
  padding-bottom: 14px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.brand-mark {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--navy-800);
  border: 1.5px solid transparent;
  background-image: linear-gradient(var(--navy-800), var(--navy-800)), var(--gradient-brand);
  background-origin: border-box;
  background-clip: padding-box, border-box;
  color: var(--teal-400);
}
.brand-mark svg { width: 16px; height: 16px; }
.brand-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.125rem;
}
.site-nav {
  display: flex;
  gap: 28px;
  font-size: 0.9375rem;
  color: var(--text-secondary);
}
.site-nav a { text-decoration: none; transition: color 150ms; }
.site-nav a:hover { color: var(--text-primary); }

@media (max-width: 760px) {
  .site-nav {
    order: 3;
    width: 100%;
    justify-content: center;
    gap: 18px;
    font-size: 0.875rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 2px;
  }
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  padding: 72px 0 96px;
  min-height: 600px;
  display: flex;
  align-items: center;
  overflow: clip;
}
.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(180deg, transparent 60%, var(--navy-900) 100%),
    linear-gradient(90deg, var(--navy-900) 0%, rgba(11, 18, 32, 0.86) 32%, rgba(11, 18, 32, 0.4) 58%, rgba(11, 18, 32, 0.08) 78%),
    url("assets/hero-couriers.webp") center right / cover no-repeat;
  pointer-events: none;
}
.hero-inner {
  position: relative;
  z-index: 1;
  width: 100%;
}
.hero-copy h1 {
  font-size: clamp(2.25rem, 5vw + 1rem, 3.25rem);
  font-weight: 800;
  letter-spacing: -0.01em;
}
.grad-text {
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-sub {
  margin-top: 18px;
  color: var(--text-secondary);
  font-size: 1.125rem;
  max-width: 46ch;
}
.checklist {
  list-style: none;
  margin: 26px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.checklist li {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text-secondary);
  font-size: 1rem;
}
.checklist svg {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  color: var(--green-400);
}
.hero-copy { max-width: 560px; }
.hero-copy .btn-primary { margin-top: 30px; }

.format-row {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px 12px;
  background: var(--glass-panel);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  padding: 28px 20px;
  width: 100%;
  max-width: 460px;
  margin-top: 36px;
}
.format-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 6px;
  padding: 8px 4px;
}
.format-icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1.5px solid currentColor;
}
.format-icon svg { width: 24px; height: 24px; }
.format-icon-0 { color: var(--cyan-400); }
.format-icon-1 { color: var(--teal-400); }
.format-icon-2 { color: var(--green-400); }
.format-icon-3 { color: var(--blue-400); }
.format-label { font-weight: 600; font-size: 0.875rem; }
.format-note { color: var(--text-muted); font-size: 0.75rem; }

/* Единственный авторский момент движения: последовательное появление hero */
.hero-copy > * ,
.format-item {
  opacity: 0.4;
  transform: translateY(14px);
  transition: opacity 640ms var(--ease-settle), transform 640ms var(--ease-settle);
}
.hero-copy > *:nth-child(1) { transition-delay: 0ms; }
.hero-copy > *:nth-child(2) { transition-delay: 90ms; }
.hero-copy > *:nth-child(3) { transition-delay: 170ms; }
.hero-copy > *:nth-child(4) { transition-delay: 260ms; }
.hero-copy > *:nth-child(5) { transition-delay: 340ms; }
/* format-row's own children already stagger themselves; don't double-fade the wrapper */
.hero-copy > .format-row { opacity: 1; transform: none; transition: none; }
.format-item { transition-delay: var(--delay, 0ms); }
.hero.hero-in .hero-copy > *,
.hero.hero-in .format-item {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  .hero-copy > *, .format-item { transition: none; opacity: 1; transform: none; }
}

@media (max-width: 700px) {
  .hero { min-height: 0; padding: 48px 0 64px; }
  .hero-copy { max-width: none; }
  .hero-media {
    background:
      linear-gradient(180deg, rgba(7, 11, 20, 0.55) 0%, rgba(7, 11, 20, 0.92) 70%, var(--navy-900) 100%),
      url("assets/hero-couriers.webp") center 30% / cover no-repeat;
  }
  .format-row { max-width: none; }
}

/* ---------- Cards (aggregators) ---------- */

.agg-benefits {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
}
.agg-benefits li {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-secondary);
  font-size: 0.9375rem;
}
.agg-benefits svg {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  color: var(--green-400);
}
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin-top: 32px;
}
.card {
  background: var(--navy-800);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
  padding: 28px;
  display: flex;
  flex-direction: column;
  transition: transform 200ms var(--ease-settle), box-shadow 200ms var(--ease-settle), border-color 200ms;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 0 1px rgba(var(--agg-glow-rgb, 45, 212, 191), 0.35),
    0 12px 32px -8px rgba(var(--agg-glow-rgb, 45, 212, 191), 0.35);
  border-color: rgb(var(--agg-glow-rgb, 45, 212, 191));
}
.card-icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--navy-950);
  background: var(--gradient-brand);
  margin-bottom: 16px;
}
.card-icon svg { width: 22px; height: 22px; }
.card h3 { font-size: 1.25rem; font-weight: 700; margin-bottom: 6px; }
.card-desc { color: var(--text-secondary); margin-bottom: 14px; }

.card-links { margin-top: auto; }
.card-links-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.card-links-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}
.card-link-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--teal-400);
  color: var(--text-primary);
  font-size: 0.8125rem;
  font-weight: 600;
  text-decoration: none;
  transition: background 150ms;
}
.card-link-btn:hover { background: var(--overlay-teal-soft); }
.card-link-btn svg { width: 16px; height: 16px; flex-shrink: 0; }
.card-link-pending {
  border-color: var(--navy-600);
  color: var(--text-muted);
  cursor: default;
}

/* ---------- Steps ---------- */

.steps {
  position: relative;
  list-style: none;
  padding: 0;
  margin: 40px 0 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 28px;
  counter-reset: step;
}
.steps li { position: relative; display: flex; flex-direction: column; gap: 12px; }
@media (min-width: 860px) {
  .steps li:not(:last-child)::after {
    content: "";
    position: absolute;
    top: 30px;
    left: 60px;
    width: calc(100% - 2px);
    height: 2px;
    background: var(--gradient-brand);
    opacity: 0.4;
    z-index: 0;
  }
}
.step-num {
  position: relative;
  z-index: 1;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--gradient-brand);
  color: var(--navy-950);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
}
.steps h3 { font-size: 1.125rem; font-weight: 700; }
.steps p { color: var(--text-secondary); }

/* ---------- Benefits ---------- */

.benefits-row {
  margin-top: 32px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
}
.benefit {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  padding: 22px;
  background: var(--navy-800);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-card);
}
.benefit-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  border: 1.5px solid var(--teal-400);
  color: var(--teal-400);
}
.benefit-icon svg { width: 20px; height: 20px; }
.benefit-label { font-weight: 600; font-size: 0.9375rem; color: var(--text-primary); }

/* ---------- FAQ ---------- */

.faq-list { margin-top: 28px; display: flex; flex-direction: column; gap: 10px; }
.faq-item {
  background: var(--navy-800);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 18px 20px;
}
.faq-item summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-chevron { width: 18px; height: 18px; flex-shrink: 0; color: var(--teal-400); transition: transform 200ms; }
.faq-item[open] .faq-chevron { transform: rotate(180deg); }
.faq-item p {
  color: var(--text-secondary);
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--navy-600);
  max-width: 68ch;
}

/* ---------- Footer ---------- */

.footer { background: var(--navy-950); padding: 40px 0; }
.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  text-align: center;
}
.brand-small .brand-name { font-size: 0.9375rem; }
.disclaimer { color: var(--text-muted); font-size: 0.8125rem; max-width: 60ch; line-height: 1.5; }
.copyright { color: var(--text-muted); font-size: 0.8125rem; }

@media (max-width: 600px) {
  .section { padding: 56px 0; }
}
