/* ===========================================
   TMEX — Hub de Servicios (page ID 2234)
   URL: /servicios/
   Complementa el design system global (landing.css).
   Prefijo de componentes propios: sh-
   =========================================== */

/* ---- Hero: datos operativos ---- */
.tmex-landing .sh-herofacts { list-style: none; display: flex; flex-wrap: wrap; gap: 10px 20px; margin: 0 0 24px; padding: 0; }
.tmex-landing .sh-herofacts li { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; color: rgba(255,255,255,0.88); }
.tmex-landing .sh-herofacts svg { width: 17px; height: 17px; color: var(--tmex-primary); flex-shrink: 0; }

/* ---- Hero: tarjeta de cobertura ---- */
.tmex-landing .sh-herocard { background: rgba(255,255,255,0.05); border: 1px solid rgba(0,175,233,0.28); border-radius: var(--tmex-radius-lg); padding: 30px; backdrop-filter: blur(8px); }
.tmex-landing .sh-herocard__title { font-family: var(--tmex-font-title); font-weight: 700; font-size: 15px; text-transform: uppercase; letter-spacing: 1.4px; color: var(--tmex-primary); margin-bottom: 20px; }
.tmex-landing .sh-herocard__row { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding: 13px 0; border-bottom: 1px solid rgba(255,255,255,0.10); }
.tmex-landing .sh-herocard__row:last-of-type { border-bottom: none; }
.tmex-landing .sh-herocard__k { font-size: 15px; color: rgba(255,255,255,0.72); }
.tmex-landing .sh-herocard__v { font-family: var(--tmex-font-title); font-weight: 700; font-size: 16px; color: var(--tmex-white); text-align: right; }
.tmex-landing .sh-herocard__note { margin-top: 18px; font-size: 13px; color: rgba(255,255,255,0.55); line-height: 1.6; }

/* ---- Tarjetas de audiencia ---- */
.tmex-landing .sh-audience { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.tmex-landing .sh-aud { display: flex; flex-direction: column; background: var(--tmex-white); border: 1px solid var(--tmex-border); border-radius: var(--tmex-radius-lg); padding: 32px; box-shadow: 0 8px 24px rgba(31,41,51,0.06); transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease; }
.tmex-landing .sh-aud:hover { transform: translateY(-5px); box-shadow: 0 16px 40px rgba(0,175,233,0.14); border-color: var(--tmex-primary); }
.tmex-landing .sh-aud__ic { width: 52px; height: 52px; border-radius: var(--tmex-radius-lg); background: var(--tmex-primary-10); color: var(--tmex-primary); display: flex; align-items: center; justify-content: center; margin-bottom: 18px; }
.tmex-landing .sh-aud__ic svg { width: 26px; height: 26px; }
.tmex-landing .sh-aud h3 { margin-bottom: 10px; }
.tmex-landing .sh-aud > p { color: var(--tmex-muted); font-size: 16px; }
.tmex-landing .sh-aud__label { display: block; font-family: var(--tmex-font-title); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 1.3px; color: var(--tmex-muted); margin: 20px 0 10px; }
.tmex-landing .sh-aud__list { list-style: none; padding: 0; margin: 0; }
.tmex-landing .sh-aud__list li { display: flex; align-items: flex-start; gap: 9px; font-size: 15px; color: var(--tmex-text); padding: 5px 0; }
.tmex-landing .sh-aud__list svg { width: 17px; height: 17px; color: var(--tmex-primary); flex-shrink: 0; margin-top: 4px; }
.tmex-landing .sh-aud .tl-card__link { margin-top: auto; padding-top: 22px; }

/* ---- Directorio maestro por necesidad ---- */
.tmex-landing .sh-dir { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.tmex-landing .sh-dirgroup { background: var(--tmex-white); border: 1px solid var(--tmex-border); border-radius: var(--tmex-radius-lg); padding: 28px; }
.tmex-landing .sh-dirgroup__head { display: flex; align-items: center; gap: 12px; padding-bottom: 16px; margin-bottom: 8px; border-bottom: 2px solid var(--tmex-primary-15); }
.tmex-landing .sh-dirgroup__head svg { width: 22px; height: 22px; color: var(--tmex-primary); flex-shrink: 0; }
.tmex-landing .sh-dirgroup__head h3 { font-size: 19px; margin: 0; }
.tmex-landing .sh-dirlist { list-style: none; padding: 0; margin: 0; }
.tmex-landing .sh-dirlist li { border-bottom: 1px solid var(--tmex-bg-soft); }
.tmex-landing .sh-dirlist li:last-child { border-bottom: none; }
.tmex-landing .sh-dirlist a { display: block; padding: 13px 0; transition: padding-left .2s ease; }
.tmex-landing .sh-dirlist a:hover { padding-left: 8px; }
.tmex-landing .sh-dirlist strong { display: block; font-family: var(--tmex-font-title); font-size: 16px; font-weight: 700; color: var(--tmex-dark); transition: color .2s ease; }
.tmex-landing .sh-dirlist a:hover strong { color: var(--tmex-primary); }
.tmex-landing .sh-dirlist span { display: block; font-size: 14px; color: var(--tmex-muted); line-height: 1.5; margin-top: 3px; }

/* ---- Cobertura y tiempos ---- */
.tmex-landing .sh-cov { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.tmex-landing .sh-covnote { margin-top: 20px; font-size: 14px; color: var(--tmex-muted); }

/* ---- Slot de imagen (solo visible en preview local) ---- */
.tmex-landing .sh-slot { border: 2px dashed var(--tmex-primary); border-radius: var(--tmex-radius-lg); background: var(--tmex-primary-10); min-height: 260px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 24px; text-align: center; color: var(--tmex-primary); font-family: var(--tmex-font-title); }
.tmex-landing .sh-slot b { font-size: 15px; }
.tmex-landing .sh-slot span { font-size: 13px; color: var(--tmex-muted); font-family: var(--tmex-font-body); }

/* ---- Responsive ---- */
@media (max-width: 1024px) {
  .tmex-landing .sh-audience { grid-template-columns: 1fr; }
  .tmex-landing .sh-dir { grid-template-columns: repeat(2, 1fr); }
  .tmex-landing .sh-cov { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 767px) {
  .tmex-landing .sh-dir { grid-template-columns: 1fr; }
  .tmex-landing .sh-herocard { padding: 24px; }
  .tmex-landing .sh-herocard__row { flex-direction: column; gap: 2px; align-items: flex-start; }
  .tmex-landing .sh-herocard__v { text-align: left; }
}

/* ---- Seccion "Por que TMEX": foto del equipo + razones ---- */
.tmex-landing .sh-why { display: grid; grid-template-columns: 1fr 1.12fr; gap: 60px; align-items: center; }
.tmex-landing .sh-why__content > p { color: var(--tmex-muted); font-size: 17px; margin-bottom: 30px; }

/* Marco de la foto del equipo.
   La foto original es 800x550 y trae mobiliario a los lados; el encuadre
   cuadrado con foco al 44% deja visible solo al equipo y el aviso TMEX. */
.tmex-landing .sh-team { position: relative; margin: 0; }
.tmex-landing .sh-team::before {
  content: ''; position: absolute; inset: 22px -22px -22px 22px;
  border: 2px solid var(--tmex-primary-15); border-radius: var(--tmex-radius-lg); z-index: 0;
}
.tmex-landing .sh-team__frame {
  position: relative; z-index: 1; padding: 4px; border-radius: 16px;
  background: linear-gradient(135deg, var(--tmex-primary) 0%, rgba(0,175,233,0.35) 40%, rgba(0,175,233,0.08) 100%);
  box-shadow: 0 26px 60px rgba(10,17,26,0.22);
}
.tmex-landing .sh-team__frame img {
  display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; object-position: 30% center;
  border-radius: var(--tmex-radius-lg); filter: contrast(1.10) saturate(0.62) brightness(1.06);
}
/* Velo inferior: asienta la etiqueta y suaviza el flash de la foto */
.tmex-landing .sh-team__frame::after {
  content: ''; position: absolute; inset: 4px; border-radius: var(--tmex-radius-lg); pointer-events: none;
  background:
    radial-gradient(120% 90% at 32% 42%, transparent 38%, rgba(10,17,26,0.50) 100%),
    linear-gradient(to top, rgba(10,17,26,0.48) 0%, transparent 42%);
}
.tmex-landing .sh-team__badge {
  position: absolute; left: 22px; bottom: 22px; z-index: 2;
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 999px;
  background: var(--tmex-primary); color: var(--tmex-white);
  font-family: var(--tmex-font-title); font-size: 13px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 1px; box-shadow: 0 8px 22px rgba(0,175,233,0.42);
}
.tmex-landing .sh-team__badge svg { width: 15px; height: 15px; }
.tmex-landing .sh-team figcaption { margin-top: 20px; font-size: 14px; color: var(--tmex-muted); line-height: 1.6; }

/* Razones en lista */
.tmex-landing .sh-reasons { display: grid; gap: 24px; }
.tmex-landing .sh-reason { display: flex; align-items: flex-start; gap: 16px; }
.tmex-landing .sh-reason__ic { flex-shrink: 0; width: 46px; height: 46px; border-radius: var(--tmex-radius-md); background: var(--tmex-primary-10); color: var(--tmex-primary); display: flex; align-items: center; justify-content: center; }
.tmex-landing .sh-reason__ic svg { width: 23px; height: 23px; }
.tmex-landing .sh-reason h3 { font-size: 19px; margin-bottom: 5px; }
.tmex-landing .sh-reason p { font-size: 16px; color: var(--tmex-muted); margin: 0; }

@media (max-width: 1024px) {
  .tmex-landing .sh-why { grid-template-columns: 1fr; gap: 44px; }
  .tmex-landing .sh-team { max-width: 520px; }
}
@media (max-width: 767px) {
  .tmex-landing .sh-team::before { inset: 14px -14px -14px 14px; }
  .tmex-landing .sh-team__badge { left: 16px; bottom: 16px; font-size: 12px; padding: 8px 14px; }
}

/* ---- Hero con foto de fondo ----
   La foto va en una etiqueta de imagen (no como background-image) para darle
   width/height y prioridad de carga. El velo la deja como textura: el
   texto y la tarjeta siguen siendo lo legible. */
.tmex-landing .sh-hero { position: relative; isolation: isolate; }
.tmex-landing .sh-hero__bg { position: absolute; inset: 0; z-index: 0; overflow: hidden; }
.tmex-landing .sh-hero__bg img {
  width: 100%; height: 100%; object-fit: cover; object-position: 72% center;
  filter: saturate(0.95) contrast(1.05);
}
.tmex-landing .sh-hero__bg::after {
  content: ''; position: absolute; inset: 0;
  background:
    linear-gradient(100deg, rgba(10,17,26,0.94) 0%, rgba(10,17,26,0.84) 30%, rgba(10,17,26,0.52) 58%, rgba(10,17,26,0.32) 100%),
    linear-gradient(to bottom, rgba(10,17,26,0.30) 0%, transparent 30%, rgba(10,17,26,0.40) 100%);
}
.tmex-landing .sh-hero .tl-container { position: relative; z-index: 1; }

@media (max-width: 1024px) {
  /* Apilado: el texto pasa por encima de la foto, hace falta mas velo */
  .tmex-landing .sh-hero__bg img { object-position: 65% center; }
  .tmex-landing .sh-hero__bg::after {
    background: linear-gradient(to bottom, rgba(10,17,26,0.93) 0%, rgba(10,17,26,0.90) 55%, rgba(10,17,26,0.95) 100%);
  }
}

/* ---- Tarjeta CTA que cierra el directorio ----
   Ocupa la sexta celda de la rejilla (5 grupos + esta), asi no queda hueco.
   Mismo tamano y radio que las demas, pero en color de marca para que destaque. */
.tmex-landing .sh-dircta {
  background: linear-gradient(150deg, var(--tmex-primary) 0%, var(--tmex-primary-hover) 55%, #0B7FAE 100%);
  border-color: transparent;
  box-shadow: 0 16px 38px rgba(0,175,233,0.28);
  display: flex; flex-direction: column; align-items: flex-start;
  position: relative; overflow: hidden;
}
/* Halo decorativo, mismo lenguaje que el hero */
.tmex-landing .sh-dircta::after {
  content: ''; position: absolute; right: -60px; bottom: -70px;
  width: 210px; height: 210px; border-radius: 50%;
  background: rgba(255,255,255,0.12); pointer-events: none;
}
.tmex-landing .sh-dircta > * { position: relative; z-index: 1; }
.tmex-landing .sh-dircta__ic {
  width: 46px; height: 46px; border-radius: var(--tmex-radius-md);
  background: rgba(255,255,255,0.18); color: var(--tmex-white);
  display: flex; align-items: center; justify-content: center; margin-bottom: 18px;
}
.tmex-landing .sh-dircta__ic svg { width: 24px; height: 24px; }
.tmex-landing .sh-dircta h3 { color: var(--tmex-white); font-size: 20px; margin-bottom: 10px; }
.tmex-landing .sh-dircta p { color: rgba(255,255,255,0.92); font-size: 15px; margin: 0 0 22px; }
.tmex-landing .sh-dircta__btn {
  margin-top: auto; display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 22px; border-radius: var(--tmex-radius-md);
  background: var(--tmex-white); color: var(--tmex-primary);
  font-family: var(--tmex-font-title); font-weight: 700; font-size: 15px;
  transition: transform .2s ease, box-shadow .2s ease, gap .2s ease;
}
.tmex-landing .sh-dircta__btn:hover {
  color: var(--tmex-primary-hover); transform: translateY(-2px); gap: 12px;
  box-shadow: 0 10px 24px rgba(0,0,0,0.18);
}

/* ---- Correccion de desborde en movil (ver landing.css) ----
   Estas dos rejillas tienen sus propias clases, asi que necesitan el mismo
   min-width:0 que el resto del sistema. */
.tmex-landing .sh-cov > *,
.tmex-landing .sh-why > * { min-width: 0; }

@media (max-width: 767px) {
  /* La tabla de cobertura solo tiene dos columnas de texto corto: en movil
     cabe entera, asi que es mejor que se ajuste a que obligue a desplazar.
     El overflow-x del contenedor sigue ahi como red de seguridad. */
  .tmex-landing .sh-cov .tl-table { min-width: 0; }
  .tmex-landing .sh-cov .tl-table th,
  .tmex-landing .sh-cov .tl-table td { padding: 12px 14px; font-size: 15px; }
}
