/* ==================================================
   TRASTEOS YA — Mega menu + Rojos dimensionales + nav fixes (v2.2)
   ================================================== */

/* ---------- MEGA MENU (estaba faltando en v2) ---------- */

.nav__mega { position: relative; }

/* Puente invisible: extiende el area de hover hacia abajo para que
   no se pierda el :hover al cruzar el gap entre "Servicios" y el panel */
.nav__mega::after {
  content: '';
  position: absolute;
  top: 100%;
  left: -20px;
  right: -20px;
  height: 18px;
  pointer-events: auto;
  background: transparent;
  z-index: 100;
}

.nav__mega-panel {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  /* z-index alto para asegurar que va por encima del hero */
  /* Mega menu en AZUL METALICO BRILLANTE (como image 1) */
  background:
    linear-gradient(180deg, rgba(255,255,255,0.08) 0%, transparent 30%, transparent 70%, rgba(0,0,0,0.20) 100%),
    linear-gradient(135deg, #001236 0%, #0A1845 30%, #1E3A8A 50%, #0A1845 70%, #001236 100%);
  border: 1px solid rgba(93,168,255,0.35);
  border-radius: var(--radius-lg);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.20),
    0 24px 60px rgba(10,24,69,0.45),
    0 12px 28px rgba(10,24,69,0.40);
  padding: var(--space-lg);
  min-width: 560px;
  max-width: 640px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity var(--dur) ease, transform var(--dur) ease, visibility var(--dur) ease;
  z-index: 9999;
}
.nav__mega:hover .nav__mega-panel,
.nav__mega:focus-within .nav__mega-panel,
.nav__mega.is-open .nav__mega-panel {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}
.nav__mega-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-sm);
}
.nav__mega-item {
  display: flex;
  gap: 12px;
  padding: 12px;
  border-radius: var(--radius-md);
  transition: background var(--dur-fast) ease, transform var(--dur-fast) ease;
  text-decoration: none;
  color: white;
}
.nav__mega-item:hover {
  background: rgba(255,255,255,0.10);
  color: white;
  transform: translateX(2px);
}
.nav__mega-icon {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, rgba(227,6,19,0.30) 0%, rgba(227,6,19,0.10) 100%);
  border: 1px solid rgba(255,140,148,0.30);
  color: #FFB4BC;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.15);
}
.nav__mega-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
  font-size: 15px;
  color: #FFFFFF;
  display: block;
  margin-bottom: 2px;
  letter-spacing: -0.01em;
}
.nav__mega-desc {
  font-size: 13px;
  color: rgba(255,255,255,0.70);
  display: block;
  line-height: 1.4;
}

/* ---------- NAV: WhatsApp solo icono (redondo) ---------- */

.btn-icon-wa {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(180deg, #2EEB76 0%, #25D366 50%, #1AAF54 100%);
  color: white;
  cursor: pointer;
  transition: all var(--dur) var(--ease-in-out);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.25),
    inset 0 -2px 0 rgba(0,0,0,0.18),
    0 4px 14px rgba(37,211,102,0.40);
  text-decoration: none;
  flex-shrink: 0;
}
.btn-icon-wa:hover {
  transform: translateY(-1px) scale(1.05);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.30),
    inset 0 -2px 0 rgba(0,0,0,0.20),
    0 8px 24px rgba(37,211,102,0.55);
  color: white;
}
.btn-icon-wa svg { width: 22px; height: 22px; }

/* ---------- HERO CTAs · botones iguales ---------- */

.hero__ctas { gap: var(--space-md); }
.hero__ctas .btn {
  flex: 1 1 220px;
  min-width: 200px;
  max-width: 320px;
  justify-content: center;
}
@media (max-width: 640px) {
  .hero__ctas .btn { max-width: 100%; }
}

/* ---------- ROJOS DIMENSIONALES (gradientes + shadows) ---------- */

.btn-primary {
  background: linear-gradient(180deg, #FF2638 0%, #E30613 50%, #B0050F 100%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.25),
    inset 0 -2px 0 rgba(0,0,0,0.18),
    0 4px 14px rgba(227,6,19,0.45),
    0 2px 4px rgba(159,4,14,0.30);
  text-shadow: 0 1px 1px rgba(0,0,0,0.22);
}
.btn-primary:hover {
  background: linear-gradient(180deg, #FF3B4B 0%, #DC0511 50%, #9F040E 100%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.30),
    inset 0 -2px 0 rgba(0,0,0,0.22),
    0 10px 28px rgba(227,6,19,0.55),
    0 4px 8px rgba(159,4,14,0.40);
}

.step__num {
  background: radial-gradient(circle at 32% 28%, #FF4452 0%, #E30613 55%, #8E0410 100%);
  box-shadow:
    inset 0 2px 4px rgba(255,255,255,0.35),
    inset 0 -4px 8px rgba(0,0,0,0.30),
    0 10px 28px rgba(227,6,19,0.45),
    0 4px 8px rgba(142,4,16,0.40);
  text-shadow: 0 2px 3px rgba(0,0,0,0.30);
}

.hero__title strong {
  background: linear-gradient(140deg, #FF2638 0%, #E30613 45%, #8E0410 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 3px 6px rgba(159,4,14,0.30));
  font-weight: 900;
}

.eyebrow--red,
.eyebrow.eyebrow--red {
  background: linear-gradient(135deg, #FF2638 0%, #B0050F 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 1px 2px rgba(159,4,14,0.25));
}

.testimonial__avatar {
  background: radial-gradient(circle at 30% 30%, #1A3070 0%, #0A1845 60%, #040A28 100%);
  box-shadow:
    inset 0 2px 3px rgba(255,255,255,0.18),
    inset 0 -3px 6px rgba(0,0,0,0.35),
    0 6px 16px rgba(10,24,69,0.30);
}

.testimonial__quote::before {
  background: linear-gradient(180deg, #FF2638 0%, #E30613 60%, #8E0410 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 2px 4px rgba(159,4,14,0.30));
}

.coverage__city svg { filter: drop-shadow(0 1px 2px rgba(159,4,14,0.40)); }

.nav__link--active::after {
  background: linear-gradient(90deg, #FF2638 0%, #B0050F 100%);
  height: 3px;
  border-radius: 2px;
  box-shadow: 0 2px 4px rgba(227,6,19,0.35);
}

/* Pill "EL MÁS PEDIDO" */
[style*="background:var(--brand-red)"] {
  background: linear-gradient(135deg, #FF2638 0%, #B0050F 100%) !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.25),
    0 2px 6px rgba(159,4,14,0.30);
}

.hero__badge svg { filter: drop-shadow(0 1px 2px rgba(10,24,69,0.18)); }

/* ---------- LOGO en nav · TAMAÑO AUMENTADO ---------- */

.nav__logo img {
  height: 56px;
  width: auto;
  max-width: 240px;
  object-fit: contain;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.40));
}
@media (min-width: 1024px) {
  .nav__logo img { height: 68px; max-width: 300px; }
}
.footer__brand img {
  height: 84px;
  width: auto;
  max-width: 320px;
  object-fit: contain;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.30));
}

/* ============================================
   NAVBAR EN AZUL METALICO (foto 1 del cliente)
   ============================================ */

.nav {
  position: sticky !important;
  top: 0 !important;
  z-index: 1000 !important;
  /* Forzar altura fija para que ningun child (especialmente .nav__mobile) lo expanda */
  height: 68px !important;
  max-height: 68px !important;
  min-height: 68px !important;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.08) 0%, transparent 40%, transparent 60%, rgba(0,0,0,0.30) 100%),
    linear-gradient(135deg, #001236 0%, #0A1845 25%, #1E3A8A 50%, #0A1845 75%, #001236 100%) !important;
  border-bottom: 1px solid rgba(93,168,255,0.35) !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.18),
    0 6px 24px rgba(10,24,69,0.40);
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  /* NO overflow:hidden — eso recortaba el mega menu panel.
     El patron de rombos se contiene solo (::before con inset:0). */
  overflow: visible !important;
}
/* Clip del patron de rombos al area del navbar sin afectar a children absolutos */
.nav::before { overflow: hidden; }

/* Patrón de rombos sobre el navbar (mismo del footer) */
.nav::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(45deg, rgba(93,168,255,0.12) 25%, transparent 25%),
    linear-gradient(-45deg, rgba(93,168,255,0.12) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, rgba(93,168,255,0.12) 75%),
    linear-gradient(-45deg, transparent 75%, rgba(93,168,255,0.12) 75%);
  background-size: 28px 28px;
  background-position: 0 0, 0 14px, 14px -14px, -14px 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.85;
}
.nav__inner,
.nav__mobile { position: relative; z-index: 1; }

.nav__link {
  color: rgba(255,255,255,0.85) !important;
  background: transparent !important;
}
.nav__link:hover {
  color: #5DA8FF !important;
  animation: nav-vibrate 240ms ease-in-out;
}
.nav__link--active {
  color: #FFFFFF !important;
  font-weight: 700;
}
.nav__link--active::after {
  background: linear-gradient(90deg, #FF2638 0%, #B0050F 100%);
  box-shadow: 0 2px 8px rgba(227,6,19,0.50);
}

.nav__burger span { background: white !important; }
/* Refuerzo de la X cuando esta abierto (sobre fondo navy) */
.nav__burger.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg) !important; background: white !important; }
.nav__burger.is-open span:nth-child(2) { opacity: 0 !important; }
.nav__burger.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg) !important; background: white !important; }

.nav__mobile {
  background:
    linear-gradient(135deg, #001236 0%, #0A1845 50%, #001236 100%);
}
.nav__mobile-link {
  color: white;
  border-bottom-color: rgba(255,255,255,0.15);
}
.nav__mobile-link:hover { color: #5DA8FF; }

/* Boton Cotizar en nav (sobre fondo navy) */
.nav__actions .btn-primary.btn-sm {
  background: linear-gradient(180deg, #FF2638 0%, #E30613 50%, #B0050F 100%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.30),
    0 6px 16px rgba(227,6,19,0.50);
}

/* Boton WhatsApp icon en nav (mas brillante sobre navy) */
.btn-icon-wa {
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.30),
    0 6px 18px rgba(37,211,102,0.55);
}

/* ---------- ROMBOS más visibles en fondos oscuros ---------- */

.section--dark::before,
.trust-strip::before,
.footer::before,
.quick-quote::after,
.transya-banner::after,
.bento .card--service.is-feature::after {
  opacity: 1 !important;
  background-image:
    linear-gradient(45deg, rgba(93,168,255,0.10) 25%, transparent 25%),
    linear-gradient(-45deg, rgba(93,168,255,0.10) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, rgba(93,168,255,0.10) 75%),
    linear-gradient(-45deg, transparent 75%, rgba(93,168,255,0.10) 75%) !important;
  background-size: 32px 32px !important;
  background-position: 0 0, 0 16px, 16px -16px, -16px 0 !important;
}

/* ============================================
   FOOTER EN AZUL METALICO (igual al navbar de arriba)
   ============================================ */

.footer {
  background:
    linear-gradient(180deg, rgba(255,255,255,0.10) 0%, transparent 40%, transparent 60%, rgba(0,0,0,0.30) 100%),
    linear-gradient(135deg, #001236 0%, #0A1845 25%, #1E3A8A 50%, #0A1845 75%, #001236 100%) !important;
  border-top: 1px solid rgba(93,168,255,0.35);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.18);
}
.footer__social {
  background: rgba(255,255,255,0.14);
  border: 1px solid rgba(255,255,255,0.20);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.18);
}
.footer__social:hover {
  background: linear-gradient(180deg, #FF2638 0%, #E30613 50%, #B0050F 100%);
  border-color: rgba(227,6,19,0.50);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.30),
    0 6px 16px rgba(227,6,19,0.45);
  transform: translateY(-2px);
}
.footer h4 { color: #DAEFFF !important; }
.footer a:hover { color: #5DA8FF !important; }

/* ============================================
   MAPA DE COBERTURA (Leaflet + custom markers)
   ============================================ */

#coverage-map {
  width: 100%;
  height: 100%;
  min-height: 480px;
  border-radius: var(--radius-xl);
  z-index: 1;
}
.coverage__map {
  padding: 0 !important;
  background: transparent !important;
  border: none !important;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  min-height: 520px;
  box-shadow: var(--shadow-lg);
  border-radius: var(--radius-xl);
}

/* Markers personalizados */
.ty-marker {
  position: relative;
  pointer-events: auto;
}
.ty-marker__dot {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 16px;
  height: 16px;
  margin: -8px 0 0 -8px;
  background: #E30613;
  border: 3px solid white;
  border-radius: 50%;
  box-shadow: 0 4px 12px rgba(227,6,19,0.50);
  z-index: 2;
}
.ty-marker__dot--blue {
  background: linear-gradient(180deg, #2D6FE0 0%, #003DA5 100%);
  width: 14px;
  height: 14px;
  margin: -7px 0 0 -7px;
  border-width: 2px;
  box-shadow: 0 3px 8px rgba(10,24,69,0.40);
}
.ty-marker--main .ty-marker__dot {
  width: 22px;
  height: 22px;
  margin: -11px 0 0 -11px;
  background: linear-gradient(180deg, #FF2638 0%, #E30613 50%, #B0050F 100%);
  border-width: 3.5px;
  box-shadow: 0 6px 18px rgba(227,6,19,0.65);
}
.ty-marker__pulse {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 22px;
  height: 22px;
  margin: -11px 0 0 -11px;
  border-radius: 50%;
  background: rgba(227,6,19,0.45);
  animation: ty-marker-pulse 2.4s ease-out infinite;
  z-index: 1;
}
@keyframes ty-marker-pulse {
  0%   { transform: scale(1);   opacity: 0.75; }
  100% { transform: scale(3.8); opacity: 0;    }
}

/* Labels al lado del marker */
.ty-marker__label {
  position: absolute;
  top: 50%;
  left: 18px;
  transform: translateY(-50%);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
  font-size: 14px;
  color: #0F172A;
  text-shadow:
    -1px -1px 0 rgba(255,255,255,0.9),
     1px -1px 0 rgba(255,255,255,0.9),
    -1px  1px 0 rgba(255,255,255,0.9),
     1px  1px 0 rgba(255,255,255,0.9),
     0 2px 4px rgba(255,255,255,0.8);
  white-space: nowrap;
  pointer-events: none;
  letter-spacing: -0.01em;
}
.ty-marker__label--small {
  font-size: 12px;
  font-weight: 600;
  left: 14px;
}
.ty-marker--main .ty-marker__label {
  font-size: 16px;
  font-weight: 800;
  color: #0A1845;
  left: 22px;
}

/* Leaflet tooltips */
.leaflet-tooltip {
  background: #0A1845 !important;
  color: white !important;
  border: 1px solid rgba(93,168,255,0.40) !important;
  border-radius: 8px !important;
  padding: 6px 12px !important;
  font-family: 'Plus Jakarta Sans', sans-serif !important;
  font-weight: 600 !important;
  font-size: 12px !important;
  box-shadow: 0 8px 20px rgba(10,24,69,0.30) !important;
}
.leaflet-tooltip-top:before { border-top-color: #0A1845 !important; }

.leaflet-control-attribution {
  font-size: 10px !important;
  background: rgba(255,255,255,0.85) !important;
}
.leaflet-control-zoom a {
  background: white !important;
  color: var(--brand-navy) !important;
  border-color: var(--border) !important;
}
.leaflet-control-zoom a:hover {
  background: var(--surface-alt) !important;
}
