/* v49 · Contacto: escena completa con transición continua */
.contact-hero .subpage-hero-visual::after {
  content: "";
  position: absolute;
  z-index: 0;
  inset: -24px;
  background: url("ubycar-hero-contacto-v2.webp") center center / cover no-repeat;
  filter: blur(13px) saturate(0.82) brightness(0.72);
  transform: scale(1.035);
  pointer-events: none;
}

.contact-hero .subpage-hero-visual > img {
  z-index: 1;
  top: 0;
  right: 0;
  bottom: 0;
  left: auto;
  width: auto;
  height: 100%;
  object-fit: contain;
  object-position: right center !important;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 23%, #000 100%);
  mask-image: linear-gradient(90deg, transparent 0%, #000 23%, #000 100%);
}

@media (max-width: 800px) {
  .contact-hero,
  .contact-hero .subpage-hero-layout {
    min-height: 0;
  }

  .contact-hero .subpage-hero-layout {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 30px;
    padding-top: 112px;
    padding-bottom: 52px;
  }

  .contact-hero .subpage-hero-inner {
    width: 100%;
    max-width: 680px;
    padding: 0;
  }

  .contact-hero .subpage-hero-layout::after {
    bottom: auto;
    height: 58%;
    background: linear-gradient(
      180deg,
      rgba(2, 14, 22, 0.96) 0%,
      rgba(2, 14, 22, 0.82) 68%,
      transparent 100%
    );
  }

  .contact-hero .subpage-hero-visual {
    position: relative;
    z-index: 2;
    inset: auto;
    width: 100%;
    min-height: 0;
    aspect-ratio: 4 / 3;
    transform: none;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 24px;
    background: #0c1f2c;
    box-shadow: 0 24px 65px rgba(0, 0, 0, 0.28);
  }

  .contact-hero .subpage-hero-visual::after {
    display: none;
  }

  .contact-hero .subpage-hero-visual::before {
    display: block;
    background: linear-gradient(
      180deg,
      transparent 58%,
      rgba(3, 15, 23, 0.7) 100%
    );
  }

  .contact-hero .subpage-hero-visual > img {
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center !important;
    -webkit-mask-image: none;
    mask-image: none;
  }

  .contact-hero .subpage-hero-visual figcaption {
    left: 14px;
    right: 14px;
    bottom: 14px;
    width: auto;
  }
}

@media (max-width: 520px) {
  .contact-hero .subpage-hero-layout {
    gap: 26px;
    padding-top: 103px;
    padding-bottom: 42px;
  }

  .contact-hero .subpage-hero-visual {
    border-radius: 20px;
  }
}
