.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg,
      rgba(15, 31, 56, .78) 0%,
      rgba(15, 31, 56, .74) 30%,
      rgba(15, 31, 56, .42) 58%,
      rgba(15, 31, 56, .27) 78%,
      rgba(15, 31, 56, .18) 100%),
    linear-gradient(180deg,
      rgba(6, 13, 26, .10) 0%,
      rgba(6, 13, 26, .025) 48%,
      rgba(6, 13, 26, .12) 100%);
  pointer-events: none;
}

.hero > :not(.municipality-hero-image):not(.municipality-hero-credit) {
  position: relative;
  z-index: 2;
}

.municipality-hero-image {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.municipality-hero-credit {
  position: absolute;
  right: 1rem;
  bottom: .55rem;
  z-index: 3;
  max-width: min(72vw, 720px);
  margin: 0;
  padding: .26rem .48rem;
  border-radius: 4px;
  background: rgba(6, 13, 26, .66);
  color: rgba(255, 255, 255, .78);
  font-size: .62rem;
  line-height: 1.35;
  text-align: right;
  backdrop-filter: blur(3px);
}

.municipality-hero-credit a {
  color: rgba(255, 255, 255, .9);
  text-decoration-color: rgba(184, 156, 106, .72);
  text-underline-offset: 2px;
}

.municipality-hero-credit a:hover,
.municipality-hero-credit a:focus-visible {
  color: #fff;
  text-decoration-color: #d8bd87;
}

@media (max-width: 768px) {
  .hero::before {
    background:
      linear-gradient(90deg,
        rgba(15, 31, 56, .80) 0%,
        rgba(15, 31, 56, .62) 48%,
        rgba(15, 31, 56, .36) 100%),
      linear-gradient(180deg,
        rgba(6, 13, 26, .12) 0%,
        rgba(6, 13, 26, .035) 48%,
        rgba(6, 13, 26, .14) 100%);
  }

  .municipality-hero-image {
    object-position: center;
  }

  .municipality-hero-credit {
    right: .55rem;
    bottom: .35rem;
    max-width: calc(100% - 1.1rem);
    font-size: .56rem;
  }
}

@media (prefers-reduced-transparency: reduce) {
  .municipality-hero-credit {
    background: #060d1a;
    backdrop-filter: none;
  }
}
