/* ===========================================================
   Estruccon Ingeniería S.A.S. — Estilos personalizados
   Paleta: Azul Energía #05538D · Verde Solar #7ABA50
   =========================================================== */

:root {
  --azul: #05538D;
  --azul-900: #032f4f;
  --verde: #7ABA50;
}

/* ---------- Base ---------- */
html { -webkit-text-size-adjust: 100%; }
/* clip evita el desborde horizontal sin convertir al body en contenedor de scroll
   (hidden rompería la navegación por anclas #id y window.scrollY). */
body { overflow-x: clip; }
::selection { background: rgba(122, 186, 80, 0.3); }

/* ---------- Navbar (transparente -> sólido al hacer scroll) ---------- */
#navbar .nav-inner { color: #fff; }
#navbar .nav-brand { color: #fff; }
#navbar .nav-link { color: rgba(255, 255, 255, 0.85); position: relative; transition: color .25s; }
#navbar .nav-link:hover { color: #fff; }
#navbar .nav-menu-btn { color: #fff; border-color: rgba(255, 255, 255, 0.25); }

#navbar.scrolled { background: rgba(255, 255, 255, 0.85); backdrop-filter: blur(14px); box-shadow: 0 8px 30px -12px rgba(3, 47, 79, 0.25); }
#navbar.scrolled .nav-inner { height: 4rem; color: var(--azul-900); }
#navbar.scrolled .nav-brand { color: var(--azul-900); }
#navbar.scrolled .nav-link { color: rgba(3, 47, 79, 0.75); }
#navbar.scrolled .nav-link:hover { color: var(--azul); }
#navbar.scrolled .nav-menu-btn { color: var(--azul-900); border-color: rgba(0, 0, 0, 0.1); }

/* ---------- Logotipo de la barra ----------
   Se apilan dos versiones en la misma celda de la retícula y se cruzan por
   opacidad: la blanca sobre el hero oscuro, la de color al hacer scroll
   (cuando la barra pasa a fondo blanco). */
.nav-logo-link { display: grid; align-items: center; }
.nav-logo-img {
  grid-area: 1 / 1; height: 44px; width: auto;
  transition: opacity .35s ease, height .5s cubic-bezier(.2,.8,.2,1), transform .5s cubic-bezier(.2,.8,.2,1);
}
.nav-logo-color { opacity: 0; }
#navbar.scrolled .nav-logo-blanco { opacity: 0; }
#navbar.scrolled .nav-logo-color { opacity: 1; }
#navbar.scrolled .nav-logo-img { height: 36px; }
.nav-logo-link:hover .nav-logo-img { transform: scale(1.03); }
@media (max-width: 400px) {
  .nav-logo-img { height: 36px; }
  #navbar.scrolled .nav-logo-img { height: 32px; }
}

/* Logotipo del pie de página (siempre sobre fondo azul oscuro) */
.footer-logo { height: 52px; width: auto; }

.nav-link::after {
  content: ""; position: absolute; left: 0; bottom: -6px; height: 2px; width: 0;
  background: var(--verde); transition: width .3s ease;
}
.nav-link:hover::after { width: 100%; }

/* Estado activo (página actual) */
#navbar .nav-link.active { color: #fff; }
#navbar.scrolled .nav-link.active { color: var(--azul); }
.nav-link.active::after { width: 100%; }
.mobile-link.active { color: var(--verde); }

/* ---------- Encabezado de páginas internas ---------- */
.page-hero {
  position: relative; overflow: hidden;
  padding-top: 9rem; padding-bottom: 5rem;
  background: #032f4f; color: #fff;
}
.breadcrumb { display: flex; align-items: center; gap: .5rem; font-size: .8rem; font-weight: 600; color: rgba(255, 255, 255, 0.55); }
.breadcrumb a { color: rgba(255, 255, 255, 0.7); transition: color .2s; }
.breadcrumb a:hover { color: var(--verde); }
.breadcrumb .sep { color: rgba(255, 255, 255, 0.3); }

/* ---------- Hero backgrounds ---------- */
.hero-mesh {
  background:
    radial-gradient(60% 55% at 15% 20%, rgba(122, 186, 80, 0.22) 0%, transparent 60%),
    radial-gradient(50% 50% at 85% 15%, rgba(26, 107, 168, 0.45) 0%, transparent 60%),
    linear-gradient(160deg, #043b64 0%, #032f4f 55%, #05233d 100%);
}
.hero-grid {
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.5) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.5) 1px, transparent 1px);
  background-size: 54px 54px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000 30%, transparent 75%);
}

/* ---------- Carrusel de clientes (marquee en bucle) ---------- */
.marquee {
  position: relative; width: 100%; overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track {
  display: flex; align-items: center; width: max-content;
  gap: 3.5rem; padding: 0 1.75rem;
  animation: marquee 42s linear infinite;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

.cliente-logo {
  height: 60px; width: auto; max-width: 190px; object-fit: contain;
  flex-shrink: 0; opacity: .85;
  /* Oculta el recuadro blanco de los logos que no son transparentes,
     mezclándolo con el fondo blanco de la sección. */
  mix-blend-mode: multiply;
  transition: opacity .3s ease, transform .3s ease;
}
.cliente-logo:hover { opacity: 1; transform: scale(1.06); }

/* Logos de aliados: son lockups apilados (marca sobre texto), por lo que a igual
   alto se ven más pequeños que los wordmarks de clientes. Se les da más alto y un
   ancho máximo mayor para igualarlos ópticamente. */
.aliado-logo { height: 90px; max-width: 220px; }

/* Logos que son enlaces (presentación en PDF o sitio web del aliado) */
.logo-enlace {
  display: inline-flex; align-items: center; border-radius: 10px;
  cursor: pointer; text-decoration: none;
}
.logo-enlace:focus-visible {
  outline: 2px solid var(--verde); outline-offset: 6px;
}

/* Respaldo en texto cuando el archivo del logo no existe */
.cliente-fallback {
  flex-shrink: 0; font-family: 'Sora', sans-serif; font-weight: 800;
  font-size: 1.25rem; color: rgba(3, 47, 79, 0.45); white-space: nowrap;
  transition: color .3s ease;
}
.cliente-fallback:hover { color: var(--azul); }

@media (prefers-reduced-motion: reduce) {
  .marquee-track { animation: none; flex-wrap: wrap; justify-content: center; row-gap: 1.5rem; }
}

/* ---------- Paneles de video de experticias (servicios) ---------- */
.expertise-video video { display: block; transition: transform .6s cubic-bezier(.2, .8, .2, 1); }
.expertise-video:hover video { transform: scale(1.05); }
.video-hint {
  position: absolute; bottom: .85rem; left: .85rem; z-index: 20;
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .4rem .8rem .4rem .45rem; border-radius: 999px;
  background: rgba(3, 47, 79, .72); color: #fff; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  font-size: .72rem; font-weight: 700; letter-spacing: .01em; pointer-events: none;
  transition: opacity .35s ease;
}
.video-play {
  display: grid; place-items: center; width: 20px; height: 20px; flex-shrink: 0;
  border-radius: 999px; background: var(--verde); color: #fff;
}
.expertise-video.is-playing .video-hint { opacity: 0; }
@media (prefers-reduced-motion: reduce) {
  .expertise-video:hover video { transform: none; }
}

/* ---------- Efecto "sin sorpresas" (aparición con rebote) ---------- */
.sorpresa {
  position: relative; display: inline-block; cursor: default; font-weight: 800;
  background: linear-gradient(100deg, #7ABA50 0%, #5f9a3b 55%, #05538D 130%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  outline: none; will-change: transform, opacity;
}
/* Entra saltando desde abajo con un rebote elástico (la palabra siempre es visible por defecto) */
.sorpresa.in { animation: sorpresa-in .7s cubic-bezier(.2, 1.55, .35, 1); }
@keyframes sorpresa-in {
  0% { opacity: .2; transform: translateY(-0.6em) scale(.7) rotate(-4deg); }
  55% { opacity: 1; transform: translateY(0.14em) scale(1.12) rotate(2deg); }
  75% { transform: translateY(-0.04em) scale(.97) rotate(-1deg); }
  100% { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  .sorpresa.in { animation: none; }
}

/* ---------- Botón flotante de WhatsApp ---------- */
.wa-fab {
  position: fixed; right: 1.5rem; bottom: 1.5rem; z-index: 900;
  display: grid; place-items: center; width: 58px; height: 58px; border-radius: 999px;
  background: #25D366; color: #fff;
  box-shadow: 0 12px 30px -8px rgba(37, 211, 102, .55);
  transition: transform .3s cubic-bezier(.2,.8,.2,1), box-shadow .3s ease;
}
.wa-fab svg { width: 30px; height: 30px; }
.wa-fab:hover, .wa-fab:focus-visible { transform: scale(1.08); box-shadow: 0 16px 38px -8px rgba(37, 211, 102, .75); }
.wa-fab:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
/* Anillo de pulso (queda detrás del círculo verde) */
.wa-fab::before {
  content: ''; position: absolute; inset: 0; border-radius: 999px;
  background: #25D366; z-index: -1; animation: wa-pulso 2.4s ease-out infinite;
}
@keyframes wa-pulso {
  0% { transform: scale(1); opacity: .55; }
  70%, 100% { transform: scale(1.75); opacity: 0; }
}
.wa-tooltip {
  position: absolute; right: 72px; white-space: nowrap;
  background: var(--azul-900); color: #fff; font-size: .78rem; font-weight: 700;
  padding: .45rem .8rem; border-radius: 8px;
  opacity: 0; transform: translateX(8px); pointer-events: none;
  transition: opacity .25s ease, transform .25s ease;
}
.wa-fab:hover .wa-tooltip, .wa-fab:focus-visible .wa-tooltip { opacity: 1; transform: translateX(0); }
@media (max-width: 640px) {
  .wa-fab { width: 54px; height: 54px; right: 1rem; bottom: 1rem; }
  .wa-tooltip { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .wa-fab::before { animation: none; }
  .wa-fab:hover, .wa-fab:focus-visible { transform: none; }
}

/* Sol de marca animado en el hero */
.hero-sol {
  filter: drop-shadow(0 0 46px rgba(122, 186, 80, 0.22));
  animation: sol-breathe 9s ease-in-out infinite;
}
@keyframes sol-breathe {
  0%, 100% { transform: translateY(-50%) scale(1); opacity: .8; }
  50% { transform: translateY(-50%) scale(1.04); opacity: .92; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-sol { animation: none; }
}

.text-gradient-solar {
  background: linear-gradient(100deg, #7ABA50 0%, #a9d488 45%, #7fb2d9 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  display: inline-block;
}

/* ---------- Buttons / checks ---------- */
.check, .check-dark {
  display: grid; place-items: center; flex-shrink: 0;
  height: 20px; width: 20px; border-radius: 6px; font-size: 12px; font-weight: 800;
  margin-top: 1px;
}
.check { background: rgba(122, 186, 80, 0.15); color: var(--verde); }
.check-dark { background: rgba(122, 186, 80, 0.2); color: var(--verde); }

/* ---------- Service cards ---------- */
.service-card { transition: transform .5s cubic-bezier(.2,.8,.2,1), box-shadow .5s; }
.service-card:hover { transform: translateY(-8px); }

/* ---------- Features ---------- */
.feature-icon {
  display: grid; place-items: center; height: 44px; width: 44px; border-radius: 12px;
  background: rgba(5, 83, 141, 0.08); color: var(--azul); margin-bottom: 14px;
}
.feature-title { font-family: 'Sora', sans-serif; font-weight: 700; font-size: 1.05rem; color: var(--azul-900); }
.feature-text { margin-top: 6px; font-size: .9rem; line-height: 1.55; color: rgba(3, 47, 79, 0.65); }

/* Variantes de las tarjetas cuando van sobre fondo azul oscuro.
   Necesarias porque styles.css se carga después de tailwind.css y sus
   colores fijos ganarían sobre utilidades como text-white. */
.on-dark .feature-icon { background: rgba(255, 255, 255, 0.1); color: var(--verde); }
.on-dark .feature-title { color: #fff; }
.on-dark .feature-text { color: rgba(255, 255, 255, 0.65); }

/* ---------- Proceso (servicios) ---------- */
.process-step {
  position: relative; border-radius: 1rem; background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.06); padding: 1.75rem;
  box-shadow: 0 10px 30px -20px rgba(3, 47, 79, 0.35); transition: transform .3s, box-shadow .3s;
}
.process-step:hover { transform: translateY(-4px); box-shadow: 0 18px 40px -22px rgba(5, 83, 141, 0.4); }
.process-step { overflow: hidden; }
.step-ic, .step-title, .step-text { position: relative; z-index: 1; }
.step-ic {
  display: grid; place-items: center; width: 52px; height: 52px; border-radius: 14px;
  background: rgba(122, 186, 80, 0.12); color: var(--verde); margin-bottom: 1rem;
}
.step-ic svg { width: 26px; height: 26px; }
/* Número grande como marca de agua que llena el espacio de la tarjeta */
.step-num {
  position: absolute; bottom: -0.8rem; right: 0.6rem; z-index: 0; line-height: .8; pointer-events: none;
  font-family: 'Sora', sans-serif; font-weight: 800; font-size: 5rem; color: rgba(5, 83, 141, 0.06);
}
.step-title { margin-top: .5rem; font-family: 'Sora', sans-serif; font-weight: 700; font-size: 1.05rem; color: var(--azul-900); }
.step-text { margin-top: .5rem; font-size: .92rem; line-height: 1.6; color: rgba(3, 47, 79, 0.75); }

/* ---------- Normas (certificaciones) ---------- */
.norm-card {
  border-radius: 1.25rem; background: #fff; border: 1px solid rgba(0, 0, 0, 0.06);
  padding: 2.25rem; box-shadow: 0 12px 34px -22px rgba(3, 47, 79, 0.4); transition: transform .3s, box-shadow .3s;
}
.norm-card:hover { transform: translateY(-5px); box-shadow: 0 22px 50px -24px rgba(5, 83, 141, 0.45); }
.norm-badge {
  display: inline-grid; place-items: center; min-width: 4.5rem; padding: .5rem 1rem;
  border-radius: .75rem; background: var(--azul); color: #fff;
  font-family: 'Sora', sans-serif; font-weight: 800; letter-spacing: .04em;
}
.norm-title { margin-top: 1.25rem; font-family: 'Sora', sans-serif; font-weight: 700; font-size: 1.2rem; color: var(--azul-900); }
.norm-text { margin-top: .75rem; line-height: 1.6; color: rgba(3, 47, 79, 0.68); }

/* Sub-normas dentro de la tarjeta HSEQ */
.norm-list { margin-top: 1.5rem; display: grid; gap: 1rem; }
.norm-list li { display: flex; align-items: flex-start; gap: .75rem; font-size: .92rem; line-height: 1.6; color: rgba(3, 47, 79, 0.72); }
.norm-list strong { color: var(--azul-900); font-weight: 700; }
@media (min-width: 768px) {
  .norm-list { grid-template-columns: repeat(3, 1fr); gap: 1.75rem; }
}

/* ---------- Certifications ---------- */
.cert-badge {
  display: grid; place-items: center; text-align: center; padding: 1.75rem 1rem;
  border-radius: 1rem; background: #fff; border: 1px solid rgba(0, 0, 0, 0.06);
  font-family: 'Sora', sans-serif; font-weight: 700; color: var(--azul);
  box-shadow: 0 10px 30px -18px rgba(3, 47, 79, 0.4); transition: transform .3s, box-shadow .3s;
}
.cert-badge:hover { transform: translateY(-4px); box-shadow: 0 18px 40px -20px rgba(5, 83, 141, 0.45); }

/* ---------- Contact ---------- */
.contact-row { display: flex; align-items: center; gap: 16px; }
.contact-ic {
  display: grid; place-items: center; height: 48px; width: 48px; flex-shrink: 0;
  border-radius: 14px; background: rgba(5, 83, 141, 0.08); color: var(--azul);
}

/* Contactos comerciales de los aliados (bloque secundario dentro de Contacto).
   Se apila en dos líneas para que los correos largos nunca se desborden. */
.aliado-contacto {
  display: block; padding: 11px 15px; border-radius: 12px;
  background: rgba(5, 83, 141, 0.04); border: 1px solid rgba(0, 0, 0, 0.05);
  text-decoration: none; transition: background .25s ease, border-color .25s ease, transform .25s ease;
}
.aliado-contacto:hover {
  background: rgba(122, 186, 80, 0.09); border-color: rgba(122, 186, 80, 0.35);
  transform: translateX(3px);
}
.aliado-contacto:focus-visible { outline: 2px solid var(--verde); outline-offset: 3px; }
.aliado-contacto-nombre {
  display: block; font-family: 'Sora', sans-serif; font-weight: 700;
  font-size: .92rem; color: var(--azul-900);
}
.aliado-contacto-mail {
  display: block; margin-top: 2px; font-size: .86rem; color: rgba(3, 47, 79, 0.62);
  word-break: break-word; transition: color .25s ease;
}
.aliado-contacto:hover .aliado-contacto-mail { color: #5f9a3b; }

/* ---------- Form ---------- */
.form-label { display: block; font-size: .8rem; font-weight: 700; color: var(--azul-900); margin-bottom: 6px; }
.form-input {
  width: 100%; border-radius: 12px; background: #fff; border: 1px solid rgba(0, 0, 0, 0.1);
  padding: .75rem 1rem; font-size: .95rem; color: var(--azul-900); transition: border-color .2s, box-shadow .2s;
}
.form-input::placeholder { color: rgba(3, 47, 79, 0.35); }
.form-input:focus { outline: none; border-color: var(--verde); box-shadow: 0 0 0 3px rgba(122, 186, 80, 0.2); }
.form-input.invalid { border-color: #dc2626; box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.12); }
.form-error { min-height: 1rem; margin-top: 4px; font-size: .78rem; font-weight: 600; color: #dc2626; }

/* ---------- Footer ---------- */
.footer-title { font-family: 'Sora', sans-serif; font-weight: 700; font-size: .95rem; margin-bottom: 1rem; }
.footer-list { display: flex; flex-direction: column; gap: .6rem; font-size: .9rem; color: rgba(255, 255, 255, 0.6); }
.footer-list a { transition: color .2s; }
.footer-list a:hover { color: var(--verde); }

/* ---------- Map: sidebar list + filters ---------- */
.filtro-btn {
  font-size: .72rem; font-weight: 700; padding: .35rem .7rem; border-radius: 999px;
  color: rgba(255, 255, 255, 0.7); background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1); cursor: pointer; transition: all .2s;
}
.filtro-btn:hover { color: #fff; background: rgba(255, 255, 255, 0.12); }
.filtro-btn.is-active { color: var(--azul-900); background: var(--verde); border-color: var(--verde); }

.proyecto-item {
  width: 100%; text-align: left; padding: .7rem .8rem; border-radius: 12px; cursor: pointer;
  transition: background .2s; display: flex; gap: .7rem; align-items: flex-start;
}
.proyecto-item:hover, .proyecto-item.active { background: rgba(255, 255, 255, 0.08); }
.proyecto-item .p-dot { height: 10px; width: 10px; border-radius: 999px; margin-top: 5px; flex-shrink: 0; }
.proyecto-item .p-name { font-weight: 700; font-size: .85rem; color: #fff; line-height: 1.25; }
.proyecto-item .p-city { font-size: .74rem; color: rgba(255, 255, 255, 0.55); margin-top: 2px; }

.legend-item { display: flex; align-items: center; gap: 8px; color: rgba(255, 255, 255, 0.8); }
.legend-item .dot { height: 9px; width: 9px; border-radius: 999px; display: inline-block; }

/* Scrollbar */
.custom-scroll::-webkit-scrollbar { width: 6px; }
.custom-scroll::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.15); border-radius: 999px; }
.custom-scroll::-webkit-scrollbar-track { background: transparent; }

/* ---------- Leaflet marker + popup ---------- */
.estruccon-pin {
  width: 26px; height: 26px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg);
  border: 2.5px solid #fff; box-shadow: 0 3px 10px rgba(0, 0, 0, 0.4);
  display: grid; place-items: center;
}
.estruccon-pin span { transform: rotate(45deg); color: #fff; font-size: 11px; font-weight: 800; }

.leaflet-popup-content-wrapper { border-radius: 14px; box-shadow: 0 12px 40px -12px rgba(3, 47, 79, .5); padding: 2px; }
.leaflet-popup-content { margin: 14px 16px; font-family: 'Manrope', sans-serif; }
.popup-cat { display: inline-block; font-size: .62rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; padding: 2px 8px; border-radius: 999px; color: #fff; }
.popup-title { font-family: 'Sora', sans-serif; font-weight: 700; font-size: 1rem; color: #032f4f; margin: 8px 0 2px; }
.popup-city { font-size: .8rem; color: #05538D; font-weight: 600; display: flex; align-items: center; gap: 4px; }
.popup-desc { font-size: .82rem; color: #475569; margin-top: 6px; line-height: 1.45; }

/* Miniatura dentro del popup del mapa */
.popup-thumb {
  display: block; width: 100%; height: 110px; object-fit: cover;
  border-radius: 10px; margin-top: 10px; background: var(--azul-50, #eaf3fa);
}
/* Datos técnicos (potencia / año / módulos), solo si el proyecto los trae */
.popup-datos { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.popup-dato {
  font-size: .68rem; font-weight: 700; color: var(--azul);
  background: rgba(5, 83, 141, .08); border-radius: 999px; padding: 3px 9px;
}
.popup-btn {
  display: inline-flex; align-items: center; gap: 6px; margin-top: 10px;
  background: var(--verde); color: #fff; font-weight: 700; font-size: .78rem;
  padding: 7px 14px; border-radius: 999px; border: 0; cursor: pointer;
  transition: background .25s ease;
}
.popup-btn:hover { background: #5f9a3b; }

/* ---------- Modal de detalle del proyecto ---------- */
.pm-overlay {
  position: fixed; inset: 0; z-index: 2000; display: grid; place-items: center;
  background: rgba(3, 47, 79, .78); backdrop-filter: blur(4px); padding: 20px;
  opacity: 0; pointer-events: none; transition: opacity .25s ease;
}
.pm-overlay.is-open { opacity: 1; pointer-events: auto; }
.pm-dialog {
  background: #fff; border-radius: 20px; width: min(880px, 100%);
  max-height: 90vh; overflow-y: auto; box-shadow: 0 40px 90px -30px rgba(0,0,0,.5);
  transform: translateY(12px) scale(.98); transition: transform .3s cubic-bezier(.2,.8,.2,1);
}
.pm-overlay.is-open .pm-dialog { transform: none; }
.pm-cerrar {
  position: sticky; top: 12px; float: right; margin: 12px 12px 0 0; z-index: 2;
  display: grid; place-items: center; height: 36px; width: 36px; border-radius: 50%;
  border: 0; background: rgba(3,47,79,.08); color: var(--azul-900); cursor: pointer;
  font-size: 20px; line-height: 1; transition: background .25s ease;
}
.pm-cerrar:hover { background: rgba(3,47,79,.16); }
.pm-cuerpo { padding: 26px 28px 30px; }
.pm-cat {
  display: inline-block; font-size: .64rem; font-weight: 800; letter-spacing: .06em;
  text-transform: uppercase; padding: 3px 10px; border-radius: 999px; color: #fff;
}
.pm-titulo { font-family: 'Sora', sans-serif; font-weight: 800; font-size: 1.55rem; color: var(--azul-900); margin-top: 10px; line-height: 1.2; }
.pm-ciudad { font-size: .9rem; font-weight: 600; color: var(--azul); margin-top: 4px; }
.pm-desc { margin-top: 14px; font-size: .95rem; line-height: 1.65; color: rgba(3,47,79,.72); }

.pm-datos { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 12px; margin-top: 20px; }
.pm-dato { background: var(--azul-50, #eaf3fa); border-radius: 14px; padding: 12px 14px; }
.pm-dato-valor { font-family: 'Sora', sans-serif; font-weight: 800; font-size: 1.15rem; color: var(--azul); }
.pm-dato-etq { font-size: .72rem; font-weight: 600; color: rgba(3,47,79,.55); margin-top: 2px; }

.pm-galeria {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 10px; margin-top: 22px; align-items: start;
}
.pm-foto {
  width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 12px;
  cursor: zoom-in; background: var(--azul-50, #eaf3fa);
  transition: transform .35s cubic-bezier(.2,.8,.2,1), box-shadow .35s;
}
/* Tomas verticales de celular: recortadas a 3:2 quedaban en una franja de
   paneles, sin cielo ni contexto. Se les da su propia proporción. */
.pm-foto--alta { aspect-ratio: 3 / 4; }
.pm-foto:hover { transform: translateY(-3px); box-shadow: 0 16px 32px -18px rgba(3,47,79,.5); }
.pm-sin-fotos { margin-top: 20px; font-size: .85rem; color: rgba(3,47,79,.45); font-style: italic; }

/* Visor a pantalla completa de una foto, con zoom */
.pm-visor {
  position: fixed; inset: 0; z-index: 2100; display: grid; place-items: center;
  background: rgba(0,0,0,.92); padding: 24px 24px 84px; opacity: 0; pointer-events: none;
  transition: opacity .25s ease; cursor: zoom-out;
}
.pm-visor.is-open { opacity: 1; pointer-events: auto; }
/* El lienzo recorta la foto ampliada en vez de dejarla desbordar la pantalla. */
.pm-visor-lienzo {
  width: 100%; height: 100%; display: grid; place-items: center; overflow: hidden;
}
.pm-visor img {
  max-width: 100%; max-height: 100%; border-radius: 10px;
  cursor: zoom-in; transform-origin: center center;
  transition: transform .18s ease-out; will-change: transform;
  -webkit-user-select: none; user-select: none; -webkit-user-drag: none;
}
.pm-visor.is-zoom img { cursor: grab; transition: none; }
.pm-visor.is-zoom img:active { cursor: grabbing; }

/* Controles */
.pm-zoom {
  position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%);
  display: flex; align-items: center; gap: 6px; cursor: auto;
  background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.18);
  backdrop-filter: blur(8px); border-radius: 999px; padding: 6px;
}
.pm-zoom-btn {
  min-width: 38px; height: 38px; padding: 0 12px; border: 0; border-radius: 999px;
  background: rgba(255,255,255,.14); color: #fff; font: inherit; font-size: 1rem;
  font-weight: 700; line-height: 1; cursor: pointer; transition: background .2s;
}
.pm-zoom-btn:hover { background: rgba(255,255,255,.28); }
.pm-zoom-btn:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.pm-zoom-nivel {
  min-width: 58px; text-align: center; color: #fff; font-size: .8rem;
  font-weight: 700; font-variant-numeric: tabular-nums;
}
.pm-visor-cerrar {
  position: absolute; top: 16px; right: 18px; width: 42px; height: 42px;
  border: 0; border-radius: 999px; background: rgba(255,255,255,.14); color: #fff;
  font-size: 1.6rem; line-height: 1; cursor: pointer; transition: background .2s;
}
.pm-visor-cerrar:hover { background: rgba(255,255,255,.3); }
.pm-visor-cerrar:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

@media (max-width: 640px) {
  .pm-visor { padding: 16px 16px 78px; }
  .pm-zoom-btn { min-width: 42px; height: 42px; }
}

@media (prefers-reduced-motion: reduce) {
  .pm-overlay, .pm-dialog, .pm-visor, .pm-foto, .pm-visor img { transition: none; }
}

.marker-cluster-estruccon {
  background: rgba(5, 83, 141, 0.25); border-radius: 999px;
}
.marker-cluster-estruccon div {
  background: var(--azul); color: #fff; border-radius: 999px; font-family: 'Sora', sans-serif;
  font-weight: 800; width: 38px; height: 38px; margin-left: 5px; margin-top: 5px;
  display: grid; place-items: center; border: 3px solid rgba(122, 186, 80, .8);
}

/* ---------- Scroll reveal ---------- */
[data-reveal] { opacity: 0; transform: translateY(26px); transition: opacity .7s cubic-bezier(.2,.8,.2,1), transform .7s cubic-bezier(.2,.8,.2,1); }
[data-reveal].is-visible { opacity: 1; transform: none; }

/* ---------- Equipo directivo ---------- */
.team-card {
  background: #fff; border: 1px solid rgba(0, 0, 0, .05); border-radius: 1.5rem;
  overflow: hidden; box-shadow: 0 18px 40px -28px rgba(3, 47, 79, .35);
  transition: transform .5s cubic-bezier(.2,.8,.2,1), box-shadow .5s;
}
.team-card:hover { transform: translateY(-8px); box-shadow: 0 30px 60px -30px rgba(5, 83, 141, .45); }

.team-photo-wrap { position: relative; aspect-ratio: 4 / 5; overflow: hidden; background: var(--azul-50, #eaf3fa); }
.team-photo { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2,.8,.2,1); }
.team-card:hover .team-photo { transform: scale(1.04); }

.team-body { padding: 1.5rem 1.5rem 1.75rem; }
.team-role {
  font-size: .72rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase;
  color: var(--verde);
}
.team-name {
  margin-top: .4rem; font-family: 'Sora', sans-serif; font-weight: 700;
  font-size: 1.2rem; line-height: 1.25; color: var(--azul-900);
}
.team-text { margin-top: .7rem; font-size: .92rem; line-height: 1.65; color: rgba(3, 47, 79, .70); }

.team-links { margin-top: 1rem; display: flex; gap: .6rem; }
.team-link {
  display: grid; place-items: center; height: 34px; width: 34px; border-radius: .7rem;
  background: rgba(5, 83, 141, .07); color: var(--azul); transition: background .25s, color .25s;
}
.team-link:hover { background: var(--azul); color: #fff; }
.team-link svg { width: 17px; height: 17px; }

/* ---------- Animations ---------- */
@keyframes bounce-slow { 0%, 100% { transform: translate(-50%, 0); } 50% { transform: translate(-50%, 8px); } }
.animate-bounce-slow { animation: bounce-slow 2.2s ease-in-out infinite; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  [data-reveal] { opacity: 1 !important; transform: none !important; transition: none; }
  .animate-bounce-slow, .animate-pulse { animation: none; }
  html { scroll-behavior: auto; }
}

/* Detalle de viviendas en proyectos que agrupan varias casas
   (p. ej. un conjunto residencial). Enumerarlas dentro de la descripción
   resultaba ilegible; en tabla cada dato queda alineado y comparable. */
.pm-sub {
  margin-top: 26px; font-family: var(--fuente-display, inherit);
  font-size: 1rem; font-weight: 700; color: var(--azul, #05538D);
}
.pm-tabla-env { margin-top: 10px; overflow-x: auto; }
.pm-tabla {
  width: 100%; border-collapse: collapse; font-size: .85rem;
  min-width: 380px;
}
.pm-tabla th {
  text-align: left; font-weight: 700; font-size: .7rem;
  text-transform: uppercase; letter-spacing: .04em;
  color: rgba(3, 47, 79, .55); padding: 0 10px 8px 0;
  border-bottom: 2px solid rgba(5, 83, 141, .16);
}
.pm-tabla td {
  padding: 9px 10px 9px 0; border-bottom: 1px solid rgba(5, 83, 141, .09);
  color: rgba(3, 47, 79, .85);
}
.pm-tabla tbody tr:last-child td { border-bottom: 0; }
.pm-tabla td:first-child { font-weight: 600; color: var(--azul-900, #032f4f); }
.pm-tabla td:not(:first-child) { font-variant-numeric: tabular-nums; white-space: nowrap; }
