/* Главная: hero, четыре пространства тарифов, блок «Как это работает» */

.home-wrap {
  max-width: 72rem;
  padding-bottom: 4rem;
}

.site-topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1.25rem;
  margin-bottom: 2rem;
}

.site-brand {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
  text-decoration: none;
}

.site-brand:hover,
.site-brand:focus-visible {
  color: var(--accent);
  text-decoration: none;
}

.site-topnav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  font-size: 0.92rem;
}

.hero {
  display: grid;
  gap: 2rem;
  align-items: center;
  margin-bottom: 3rem;
}

@media (min-width: 56rem) {
  .hero {
    grid-template-columns: 1.1fr 0.9fr;
  }
}

.hero-copy h1 {
  font-size: clamp(1.85rem, 4vw, 2.75rem);
  line-height: 1.15;
  margin: 0 0 0.75rem;
}

.hero-tagline {
  font-size: clamp(1.05rem, 2.2vw, 1.35rem);
  color: var(--muted);
  margin: 0 0 1.5rem;
  max-width: 34rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.hero-visual {
  position: relative;
  border-radius: calc(var(--radius) + 4px);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
  aspect-ratio: 9 / 16;
  max-height: 28rem;
  margin-inline: auto;
  width: min(100%, 16rem);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.22);
}

@media (min-width: 56rem) {
  .hero-visual {
    width: 100%;
    max-height: none;
  }
}

.hero-demo {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 1rem;
  gap: 0.75rem;
}

.hero-demo-bar {
  height: 0.45rem;
  width: 2.5rem;
  border-radius: 999px;
  background: var(--border);
  margin-inline: auto;
}

.hero-demo-screen {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.65rem;
  padding: 0.75rem;
  border-radius: var(--radius);
  background: rgba(127, 127, 127, 0.08);
}

.hero-demo-chip {
  align-self: flex-start;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  font-size: 0.78rem;
  background: var(--accent);
  color: #fff;
  animation: demoPulse 3.5s ease-in-out infinite;
}

.hero-demo-query {
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  font-size: 0.88rem;
  color: var(--muted);
}

.hero-demo-result {
  padding: 0.75rem;
  border-radius: var(--radius);
  border: 1px solid var(--accent);
  font-size: 0.88rem;
  opacity: 0;
  animation: demoReveal 3.5s ease-in-out infinite;
}

@keyframes demoPulse {
  0%,
  28% {
    opacity: 1;
  }
  40%,
  100% {
    opacity: 0.55;
  }
}

@keyframes demoReveal {
  0%,
  45% {
    opacity: 0;
    transform: translateY(6px);
  }
  58%,
  88% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(6px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-demo-chip,
  .hero-demo-result {
    animation: none;
    opacity: 1;
    transform: none;
  }
}

.section-head {
  margin-bottom: 1.25rem;
}

.section-head h2 {
  font-size: clamp(1.25rem, 2.5vw, 1.6rem);
  margin: 0 0 0.35rem;
}

.section-head p {
  margin: 0;
  color: var(--muted);
}

.tier-spaces {
  margin-bottom: 3rem;
}

.tier-spaces-scroll {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding: 0.25rem 0 1rem;
  margin: 0 -1.25rem;
  padding-inline: 1.25rem;
}

.tier-spaces-scroll::-webkit-scrollbar {
  height: 6px;
}

.tier-spaces-scroll::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 999px;
}

@media (min-width: 48rem) {
  .tier-spaces-scroll {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    overflow: visible;
    scroll-snap-type: none;
    margin: 0;
    padding: 0;
  }
}

@media (min-width: 64rem) {
  .tier-spaces-scroll {
    grid-template-columns: repeat(4, 1fr);
  }
}

.tier-space {
  flex: 0 0 min(82vw, 18rem);
  scroll-snap-align: center;
  display: flex;
  flex-direction: column;
  min-height: 18rem;
  padding: 1.35rem;
  border-radius: calc(var(--radius) + 2px);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  text-decoration: none;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  position: relative;
  overflow: hidden;
}

@media (min-width: 48rem) {
  .tier-space {
    flex: none;
    min-height: 20rem;
  }

  .tier-space--premium {
    grid-row: span 1;
  }
}

.tier-space::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  background: var(--tier-accent, var(--accent));
}

.tier-space:hover,
.tier-space:focus-visible {
  border-color: var(--tier-accent, var(--accent));
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.14);
  text-decoration: none;
  color: var(--text);
  outline: none;
}

.tier-space--free {
  --tier-accent: #64748b;
}

.tier-space--standard {
  --tier-accent: #0284c7;
}

.tier-space--premium {
  --tier-accent: #7c3aed;
}

.tier-space--social {
  --tier-accent: #ea580c;
}

.tier-space-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--tier-accent, var(--accent));
  margin: 0 0 0.35rem;
}

.tier-space-title {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
}

.tier-space-slogan {
  font-size: 0.98rem;
  line-height: 1.45;
  margin: 0 0 1rem;
  flex: 1;
}

.tier-space-bullets {
  margin: 0 0 1rem;
  padding-left: 1.1rem;
  font-size: 0.88rem;
  color: var(--muted);
}

.tier-space-bullets li {
  margin-bottom: 0.3rem;
}

.tier-space-cta {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--tier-accent, var(--accent));
}

.tier-spaces-hint {
  margin-top: 0.75rem;
  font-size: 0.85rem;
  color: var(--muted);
  text-align: center;
}

@media (min-width: 48rem) {
  .tier-spaces-hint {
    display: none;
  }
}

.how-it-works {
  margin-bottom: 2.5rem;
  padding: 1.75rem 1.25rem;
  border-radius: calc(var(--radius) + 2px);
  border: 1px solid var(--border);
  background: var(--surface);
}

.how-steps {
  display: grid;
  gap: 1.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 40rem) {
  .how-steps {
    grid-template-columns: repeat(3, 1fr);
  }
}

.how-step {
  text-align: center;
}

.how-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
}

.how-step h3 {
  font-size: 1rem;
  margin: 0 0 0.35rem;
}

.how-step p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
}

.home-foot-grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 40rem) {
  .home-foot-grid {
    grid-template-columns: 1fr 1fr;
  }
}
