/* Abogados H — fondos originales visibles aun si el navegador sustituye
   la propiedad background del contenedor. No se alteran colores ni tamaños. */
:root { color-scheme: only light !important; }

/* Cada imagen debe pintarse ENCIMA del fondo del contenedor, no debajo.
   La versión anterior usaba z-index:-1 y el fondo negro la ocultaba. */
.h-fondo-resistente {
  position: relative;
  isolation: isolate;
}
.h-fondo-resistente > .h-fondo-resistente__imagen,
.h-fondo-resistente > .h-fondo-resistente__picture {
  display: block;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  z-index: 0;
  pointer-events: none;
  user-select: none;
}
.h-fondo-resistente > .h-fondo-resistente__imagen,
.h-fondo-resistente__picture > .h-fondo-resistente__imagen {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  filter: none !important;
  mix-blend-mode: normal !important;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}
/* Encima de la foto: solamente los contenedores de contenido ya existentes.
   No mover decoraciones, no cambiar dimensiones ni comportamiento. */
#inicioPage .hero-section > .hero-container,
#inicioPage .sobre-nosotros > .sobre-contenido,
#inicioPage .seccion-servicios > .servicios-container,
#inicioPage .hero-module > .inner,
#nosotrosPage .marmol-surface > .seccion-nosotros,
#nosotrosPage .marmol-surface > .seccion-valores,
#serviciosPage .services-hero > .services-wrap,
#serviciosPage .seccion-contacto-luxe > .contacto-luxe-wrap,
#contactoPage .sec3 > .contact-block,
#contactoPage .info-strip > .info-wrap,
#contactoPage .sec5 > .faq {
  position: relative;
  z-index: 1;
}
/* Ya es absoluta en el diseño original: conservar esa posición. */
#serviciosPage .services-hero > .services-bottom-crest {
  z-index: 1;
}
/* Posición de las fotografías establecida por el diseño original. */
@media (max-width:780px) {
  #inicioPage .hero-section > .h-fondo-resistente__imagen { object-position:81% center; }
}
@media (min-width:781px) and (max-width:1100px) {
  #inicioPage .hero-section > .h-fondo-resistente__imagen { object-position:82% center; }
}

/* Restauracion visual: la fotografía de Inicio llega hasta el separador,
   sin que el fondo de la sección siguiente tape sus últimos píxeles. */
#inicioPage .hero-section.h-fondo-resistente { z-index: 1; }

/* La imagen del horizonte de Servicios era un pseudoelemento tapado por
   la textura añadida. Ahora está delante de la textura y detrás del contenido. */
#serviciosPage .services-hero.h-fondo-resistente::before { display: none !important; }
#serviciosPage .services-hero > .h-servicios-horizonte {
  position: absolute;
  top: -30px; left: 0; width: 100%;
  height: clamp(355px, 46.5vw, 608px);
  display: block; object-fit: fill;
  z-index: 1; pointer-events: none; user-select: none;
  filter: none !important; mix-blend-mode: normal !important;
}
@media (max-width: 900px) {
  #serviciosPage .services-hero > .h-servicios-horizonte { top: 0; height: 290px; object-fit: cover; opacity: .55; }
}

/* El degradado del banner móvil (z:2) debe quedar por debajo del texto.
   La capa añadida en la versión anterior fijaba el texto a z:1, oscureciéndolo. */
#inicioPage .hero-section.h-fondo-resistente > .hero-container { z-index: 10; }


/* SERVICIOS · ÚNICA CORRECCIÓN VISUAL EN ESCRITORIO (22-10-2026).
   El dibujo original se redujo proporcionalmente en un único recurso; evita cover,
   el fondo duplicado y las máscaras sobre el paisaje. Se conservan tarjetas y sello. */
#serviciosPage .services-hero::after { display:none !important; }
@media screen and (min-width:768px) {
  #serviciosPage .services-hero.h-fondo-resistente {
    background-image:none !important;
    background-color:#20406a !important;
  }
  #serviciosPage .services-hero.h-fondo-resistente > .h-fondo-resistente__picture {
    display:block !important;
    position:absolute !important;
    inset:0 !important;
    width:100% !important;
    height:100% !important;
    overflow:hidden !important;
    background:none !important;
    opacity:1 !important;
  }
  #serviciosPage .services-hero.h-fondo-resistente > .h-fondo-resistente__picture > .h-fondo-resistente__imagen {
    display:block !important;
    position:absolute !important;
    inset:0 !important;
    width:100% !important;
    height:100% !important;
    max-width:none !important;
    object-fit:fill !important;
    opacity:1 !important;
    transform:none !important;
    filter:none !important;
    -webkit-mask-image:none !important;
    mask-image:none !important;
  }
  #serviciosPage .services-hero > .h-servicios-horizonte {
    -webkit-mask-image:none !important;
    mask-image:none !important;
    opacity:1 !important;
  }
}


/* Separador dorado de la unión REAL entre paisaje y fondo azul.
   La imagen del horizonte comienza 30px arriba del bloque y mide exactamente
   clamp(355px, 46.5vw, 608px) en escritorio; en móvil mide 290px y empieza en 0.
   La raya permanece detrás de las tarjetas, sin superponer sus textos. */
#serviciosPage .services-hero.h-fondo-resistente::after {
  content:"" !important;
  display:block !important;
  position:absolute !important;
  left:0 !important;
  right:0 !important;
  bottom:auto !important;
  top:calc(clamp(355px, 46.5vw, 608px) - 30px) !important;
  transform:none !important;
  width:100% !important;
  height:3px !important;
  border:0 !important;
  border-radius:0 !important;
  background:linear-gradient(90deg, transparent 0%, #ba8d46 4%, #e4bd6d 50%, #ba8d46 96%, transparent 100%) !important;
  box-shadow:0 1px 2px #08193244 !important;
  z-index:2 !important;
  opacity:1 !important;
  pointer-events:none !important;
}
#serviciosPage .services-hero > .services-wrap,
#serviciosPage .services-hero > .services-bottom-crest {
  z-index:3;
}
@media screen and (max-width:900px) {
  #serviciosPage .services-hero.h-fondo-resistente::after {top:290px !important; height:2px !important;}
}
