/* ==========================
   Hero – Mobile First
========================== */

.hero {
  display: flex;
  flex-direction: column;
  justify-content: space-between;

  height: 340px;
  position: relative;

  background-image: url("../../images/hero/richmond-skyline-hero.webp");

  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* ==========================
   Hero Image
========================== */

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  display: block;
}

/* ==========================
   Hero Overlay
========================== */

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.2));
}

/* ==========================
   Hero Content
========================== */

.hero-content {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 60px;
  z-index: 2;
}

.hero-title {
  font-size: clamp(3rem, 6vw, 4.5rem);
  letter-spacing: 8px;
  text-transform: uppercase;
  font-weight: 700;
  color: #ffffff;
  text-shadow: 0 6px 25px rgba(0, 0, 0, 0.35);
  display: inline-block;
}

.hero-title::after {
  content: "";
  display: block;

  width: 80%;
  max-width: 100%;

  height: 3px;
  margin: 16px auto 0;

  background: linear-gradient(to right, var(--color-accent), var(--color-accent-dark));

  transform: scaleX(0);
  transform-origin: center;
  animation: heroLineExpand 0.8s ease 0.15s forwards;
}

/* ==========================
   Animation
========================== */

@keyframes heroLineExpand {
  from {
    transform: scaleX(0);
  }

  to {
    transform: scaleX(1);
  }
}

/* ==========================
   Tablet
========================== */

@media (min-width: 481px) and (max-width: 767px) {
  .hero {
    height: 260px;
  }

  .hero-content {
    padding-bottom: 25px;
  }

  .hero-image {
    object-position: center 55%;
  }
}

/* ==========================
   Desktop
========================== */

@media (min-width: 768px) {
  .hero {
    height: 340px;
  }

  .hero-content {
    padding-bottom: 30px;
  }

  .hero-image {
    object-position: center 45%;
  }
}
