.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: clamp(460px, calc(100svh - var(--header) - 280px), 620px);
  background-color: #1c2838;
  background-image: url("../assets/background.png");
  background-repeat: no-repeat;
  background-position: right center;
  background-size: auto 148%;
  color: var(--white);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(8, 14, 28, 0.55) 0%,
    rgba(8, 14, 28, 0.28) 34%,
    rgba(8, 14, 28, 0.05) 58%,
    rgba(8, 14, 28, 0) 72%
  );
}

.hero-content {
  position: relative;
  z-index: 1;
  padding-block: 64px;
}

.hero h1 {
  max-width: 10.6em;
  margin: 0;
  font-size: clamp(32px, 3.05vw, 44px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.14;
}

.gold-rule {
  display: block;
  width: 44px;
  height: 3px;
  margin: 24px 0 20px;
  background: var(--gold);
}

.hero p {
  max-width: 24em;
  margin: 0;
  color: rgba(255, 255, 255, 0.94);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.55;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
}

.spaces {
  padding: 36px 0 28px;
  background: var(--white);
}

.spaces-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.card {
  min-height: 250px;
  padding: 36px 32px 32px;
  background: var(--card);
  border-radius: 18px;
}

.card-icon {
  width: 42px;
  height: 42px;
  fill: none;
  stroke: var(--gold);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.card h2 {
  margin: 22px 0 10px;
  font-size: 23px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.card p {
  max-width: 28em;
  margin: 0;
  color: var(--muted);
  font-size: 15.5px;
  line-height: 1.5;
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
  color: var(--gold);
  font-size: 14.5px;
  font-weight: 600;
}

.card-link:hover {
  color: var(--gold-hover);
}

.anchor {
  display: block;
  position: relative;
  top: calc(var(--header) * -1);
}

.avulso-home {
  scroll-margin-top: calc(var(--header) + 12px);
  padding: 8px 0 56px;
}

.avulso-home-head {
  max-width: 40rem;
  margin-bottom: 22px;
}

.avulso-home-head h2 {
  margin: 0;
  font-size: clamp(28px, 3vw, 36px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.avulso-home-head p:last-child {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.5;
}

.avulso-home .spaces-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.avulso-home .card {
  display: flex;
  flex-direction: column;
}

.avulso-home .card p {
  flex-grow: 1;
}

.avulso-home .btn {
  margin-top: 22px;
}

@media (max-width: 1200px) {
  .avulso-home .spaces-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .hero {
    background-position: center center;
    background-size: cover;
  }

  .spaces-grid,
  .avulso-home .spaces-grid {
    grid-template-columns: 1fr;
  }

  .card {
    min-height: 0;
  }
}

@media (max-width: 640px) {
  .hero {
    background-position: left center;
  }

  .hero-shade {
    background: linear-gradient(
      180deg,
      rgba(8, 14, 28, 0.78) 0%,
      rgba(8, 14, 28, 0.55) 48%,
      rgba(8, 14, 28, 0.28) 100%
    );
  }

  .hero h1 {
    max-width: 12em;
  }

  .hero-actions .btn {
    width: 100%;
  }
}
