/* IA-Link — marca: azul principal #0F4C81, secundario #1FA2FF, fondo #0A0F1C */

:root {
  --brand-primary: #0f4c81;
  --brand-secondary: #1fa2ff;
  --brand-bg: #0a0f1c;
  --brand-primary-rgb: 15, 76, 129;
  --brand-secondary-rgb: 31, 162, 255;

  --bg-deep: var(--brand-bg);
  --bg: var(--brand-bg);
  --bg-panel: rgba(var(--brand-primary-rgb), 0.38);
  --bg-panel-solid: #0d1528;
  --bg-card: rgba(var(--brand-primary-rgb), 0.45);
  --cyan: var(--brand-secondary);
  --cyan-light: #6bb8ff;
  --blue: var(--brand-secondary);
  --blue-deep: var(--brand-primary);
  --indigo: #2563a8;
  --text: #e8eef5;
  --text-muted: #8fa8c4;
  --border: rgba(var(--brand-secondary-rgb), 0.22);
  --whatsapp: #25d366;
  --radius: 1rem;
  --radius-lg: 1.35rem;
  --font: "Montserrat", "Poppins", "Roboto", system-ui, -apple-system, sans-serif;
  --font-weight-body: 500;
  --font-weight-semibold: 600;
  --shadow-glow: 0 0 80px rgba(var(--brand-secondary-rgb), 0.2);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  font-weight: var(--font-weight-body);
  color: var(--text);
  background: var(--bg-deep);
  line-height: 1.6;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font);
  font-weight: var(--font-weight-semibold);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--cyan);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* ----- Fondo animado ----- */
.bg-stage {
  position: fixed;
  inset: 0;
  z-index: -2;
  overflow: hidden;
  background: radial-gradient(ellipse 120% 80% at 50% -20%, rgba(var(--brand-primary-rgb), 0.55) 0%, transparent 55%),
    radial-gradient(ellipse 90% 60% at 100% 50%, rgba(var(--brand-secondary-rgb), 0.22) 0%, transparent 45%),
    radial-gradient(ellipse 70% 50% at 0% 80%, rgba(var(--brand-secondary-rgb), 0.14) 0%, transparent 50%),
    var(--bg-deep);
  animation: stage-breathe 22s ease-in-out infinite;
}

.bg-stage::before,
.bg-stage::after {
  content: "";
  position: absolute;
  inset: -8%;
  pointer-events: none;
}

.bg-stage::before {
  background-image:
    radial-gradient(circle, rgba(var(--brand-secondary-rgb), 0.45) 0 2px, transparent 2.5px),
    radial-gradient(circle, rgba(var(--brand-secondary-rgb), 0.22) 0 1.5px, transparent 2px);
  background-size: 180px 180px, 120px 120px;
  background-position: 20px 10px, 70px 40px;
  opacity: 0.35;
  mask-image: radial-gradient(ellipse 90% 74% at 50% 46%, black 12%, transparent 72%);
  animation: network-nodes 26s linear infinite;
}

.bg-stage::after {
  background-image:
    linear-gradient(22deg, transparent 46%, rgba(var(--brand-secondary-rgb), 0.12) 49%, rgba(var(--brand-secondary-rgb), 0.12) 51%, transparent 54%),
    linear-gradient(-18deg, transparent 46%, rgba(var(--brand-secondary-rgb), 0.09) 49%, rgba(var(--brand-secondary-rgb), 0.09) 51%, transparent 54%);
  background-size: 210px 210px, 240px 240px;
  opacity: 0.26;
  mask-image: radial-gradient(ellipse 88% 70% at 45% 44%, black 18%, transparent 76%);
  animation: network-links 30s linear infinite;
}

@keyframes stage-breathe {
  0%,
  100% {
    filter: brightness(1) saturate(1);
  }
  50% {
    filter: brightness(1.05) saturate(1.08);
  }
}

@keyframes network-nodes {
  0% {
    transform: translate3d(0, 0, 0);
  }
  100% {
    transform: translate3d(-90px, -70px, 0);
  }
}

@keyframes network-links {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  50% {
    transform: translate3d(35px, -24px, 0) scale(1.03);
  }
  100% {
    transform: translate3d(70px, -48px, 0) scale(1);
  }
}

.bg-grid {
  position: absolute;
  inset: -12%;
  background-image: linear-gradient(rgba(var(--brand-secondary-rgb), 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(var(--brand-secondary-rgb), 0.048) 1px, transparent 1px),
    linear-gradient(rgba(var(--brand-secondary-rgb), 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(var(--brand-secondary-rgb), 0.03) 1px, transparent 1px);
  background-size: 56px 56px, 56px 56px, 28px 28px, 28px 28px;
  background-position: 0 0, 0 0, 12px 12px, 12px 12px;
  mask-image: radial-gradient(ellipse 85% 72% at 50% 38%, black 15%, transparent 72%);
  animation: grid-drift 18s linear infinite, grid-wobble 9s ease-in-out infinite;
}

.bg-grid::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(var(--brand-secondary-rgb), 0.09) 1px, transparent 1px),
    linear-gradient(90deg, rgba(var(--brand-secondary-rgb), 0.075) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 75% 65% at 45% 45%, black 10%, transparent 70%);
  animation: grid-drift-reverse 26s linear infinite;
  opacity: 0.55;
  pointer-events: none;
}

@keyframes grid-drift {
  0% {
    transform: translate(0, 0) rotate(0deg);
  }
  100% {
    transform: translate(-56px, -56px) rotate(0.35deg);
  }
}

@keyframes grid-drift-reverse {
  0% {
    transform: translate(0, 0);
  }
  100% {
    transform: translate(56px, 40px);
  }
}

@keyframes grid-wobble {
  0%,
  100% {
    opacity: 0.92;
  }
  50% {
    opacity: 1;
  }
}

.bg-orbs {
  position: absolute;
  inset: -20%;
  pointer-events: none;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(72px);
  opacity: 0.5;
  animation: orb-float 14s ease-in-out infinite;
}

.orb-1 {
  width: min(55vw, 520px);
  height: min(55vw, 520px);
  background: radial-gradient(circle, var(--cyan), transparent 70%);
  top: 5%;
  left: 10%;
  animation-delay: 0s;
}

.orb-2 {
  width: min(45vw, 440px);
  height: min(45vw, 440px);
  background: radial-gradient(circle, var(--indigo), transparent 70%);
  bottom: 10%;
  right: 5%;
  animation-delay: -6s;
}

.orb-3 {
  width: min(40vw, 380px);
  height: min(40vw, 380px);
  background: radial-gradient(circle, var(--blue-deep), transparent 70%);
  top: 40%;
  right: 25%;
  animation-delay: -12s;
}

.orb-4 {
  width: min(32vw, 300px);
  height: min(32vw, 300px);
  background: radial-gradient(circle, rgba(var(--brand-secondary-rgb), 0.55), transparent 72%);
  bottom: 35%;
  left: 30%;
  opacity: 0.38;
  animation-delay: -9s;
  animation-duration: 22s;
}

@keyframes orb-float {
  0%,
  100% {
    transform: translate(0, 0) scale(1) rotate(0deg);
  }
  25% {
    transform: translate(7%, -6%) scale(1.08) rotate(1.2deg);
  }
  50% {
    transform: translate(-5%, 8%) scale(0.96) rotate(-0.8deg);
  }
  75% {
    transform: translate(6%, 4%) scale(1.04) rotate(0.6deg);
  }
}

/* ----- Layout ----- */
.wrap {
  width: min(1120px, 92vw);
  margin-inline: auto;
}

.section {
  padding: clamp(3.5rem, 8vw, 6rem) 0;
  position: relative;
  scroll-margin-top: 5.75rem;
}

.section-title {
  font-size: clamp(1.65rem, 4vw, 2.25rem);
  font-weight: var(--font-weight-semibold);
  letter-spacing: -0.02em;
  margin: 0 0 0.5rem;
  background: linear-gradient(135deg, #f4f8fc, var(--brand-secondary));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.section-lead {
  color: var(--text-muted);
  max-width: none;
  margin: 0 0 2.5rem;
  font-size: 1.05rem;
  line-height: 1.65;
  text-wrap: pretty;
}

/* ----- Header ----- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(16px);
  background: rgba(10, 15, 28, 0.88);
  border-bottom: 1px solid var(--border);
  /* Igual al alto real de .header-inner + este borde (evita hueco bajo el header en menu movil). */
  --header-bar-height: calc(1.7rem + clamp(36px, 5vw, 44px) + 1px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0;
}

.logo-link {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
}

.logo-link img {
  height: clamp(36px, 5vw, 44px);
  width: auto;
}

.nav-desktop {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.nav-desktop a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: var(--font-weight-semibold);
  padding: 0.5rem 0.75rem;
  border-radius: 0.5rem;
  transition: color 0.2s, background 0.2s;
}

.nav-desktop a:hover {
  color: var(--text);
  background: rgba(var(--brand-secondary-rgb), 0.08);
  text-decoration: none;
}

.nav-desktop a.is-active,
.nav-desktop a[aria-current="page"] {
  color: var(--cyan);
  background: rgba(var(--brand-secondary-rgb), 0.14);
  box-shadow: 0 0 0 1px rgba(var(--brand-secondary-rgb), 0.35);
}

.nav-item-has-sub {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.15rem;
}

.nav-item-has-sub > .nav-parent {
  padding-right: 0.35rem;
}

.nav-item-has-sub .nav-caret {
  display: inline-flex;
  width: 1.25rem;
  height: 1.25rem;
  align-items: center;
  justify-content: center;
  border: none;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  border-radius: 0.35rem;
  font-size: 0.65rem;
  padding: 0;
  transition: color 0.2s, background 0.2s;
}

.nav-item-has-sub .nav-caret:hover {
  color: var(--cyan);
  background: rgba(var(--brand-secondary-rgb), 0.1);
}

.nav-item-has-sub:focus-within .nav-sub,
.nav-item-has-sub.is-open .nav-sub {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}

@media (hover: hover) and (min-width: 881px) {
  .nav-item-has-sub:hover .nav-sub {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
  }
}

.nav-sub {
  position: absolute;
  top: calc(100% + 0.35rem);
  left: 0;
  min-width: 17.5rem;
  margin: 0;
  padding: 0.4rem;
  list-style: none;
  background: var(--bg-panel-solid);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.45);
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity 0.2s, transform 0.2s, visibility 0.2s;
  pointer-events: none;
  z-index: 120;
}

.nav-sub a {
  display: block;
  padding: 0.55rem 0.75rem;
  border-radius: 0.45rem;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.nav-sub a:hover {
  background: rgba(var(--brand-secondary-rgb), 0.1);
  color: var(--text);
}

.nav-sub a.is-active {
  color: var(--cyan);
  background: rgba(var(--brand-secondary-rgb), 0.12);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.15rem;
  font-family: var(--font);
  font-weight: var(--font-weight-semibold);
  font-size: 0.92rem;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.2s, background 0.2s;
  text-decoration: none;
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: linear-gradient(135deg, var(--brand-secondary), var(--brand-primary));
  color: #fff;
  box-shadow: 0 4px 24px rgba(var(--brand-secondary-rgb), 0.35);
}

.btn-primary:hover {
  box-shadow: 0 6px 32px rgba(var(--brand-secondary-rgb), 0.45);
  text-decoration: none;
  color: #fff;
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.1);
  text-decoration: none;
  color: var(--text);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 0.5rem;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 0.5rem;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--cyan);
}

.nav-mobile-social {
  display: none;
}

@media (max-width: 880px) {
  /* Sin blur en el header movil: el nav fijo respeta el viewport. */
  .site-header {
    backdrop-filter: none;
    background: rgba(3, 11, 24, 0.94);
  }

  .nav-toggle {
    display: flex;
  }

  .nav-desktop {
    position: fixed;
    left: 0;
    right: 0;
    top: calc(env(safe-area-inset-top, 0px) + var(--header-bar-height) - 0.5px);
    bottom: 0;
    flex-direction: column;
    align-items: stretch;
    align-content: flex-start;
    justify-content: flex-start;
    padding: 1rem 1.15rem;
    padding-bottom: calc(1.25rem + env(safe-area-inset-bottom, 0px));
    margin: 0;
    width: 100%;
    max-width: none;
    box-sizing: border-box;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    background: var(--bg-panel-solid);
    border: none;
    border-radius: 0 0 var(--radius-lg) var(--radius-lg);
    box-shadow: 0 28px 60px rgba(0, 0, 0, 0.55);
    transform: translateY(-105%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: transform 0.28s ease, opacity 0.28s ease, visibility 0.28s;
    z-index: 200;
  }

  .nav-desktop.is-open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .nav-desktop .btn {
    margin-top: 0.5rem;
    width: 100%;
    padding: calc(0.65rem * 0.75) calc(1.15rem * 0.75);
    font-size: calc(0.92rem * 0.75);
    gap: calc(0.5rem * 0.75);
  }

  .nav-mobile-social {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0.65rem;
    width: 100%;
  }

  .nav-desktop .nav-mobile-social a.social-float-btn {
    padding: 0;
    color: #fff;
    font-weight: 800;
    font-size: 0.8rem;
    flex-shrink: 0;
    width: 3.25rem;
    height: 3.25rem;
    min-width: 3.25rem;
    min-height: 3.25rem;
    max-width: 3.25rem;
    max-height: 3.25rem;
    box-sizing: border-box;
    border-radius: 50%;
    aspect-ratio: 1;
    line-height: 0;
    overflow: hidden;
  }

  .nav-desktop .nav-mobile-social a.social-float-btn:hover {
    color: #fff;
    text-decoration: none;
  }

  .nav-desktop .nav-mobile-social a.social-float-btn--fb:hover {
    background: linear-gradient(135deg, #1877f2 0%, #125bc4 100%);
  }

  .nav-desktop .nav-mobile-social a.social-float-btn--ig:hover {
    background: linear-gradient(135deg, #f58529 0%, #dd2a7b 45%, #8134af 70%, #515bd4 100%);
  }

  .nav-desktop .nav-mobile-social a.social-float-btn svg {
    width: 1.85rem;
    height: 1.85rem;
  }

  .nav-item-has-sub {
    flex-direction: column;
    align-items: stretch;
  }

  .nav-item-has-sub > .nav-parent {
    width: 100%;
  }

  .nav-sub {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    pointer-events: auto;
    display: none;
    margin-top: 0.35rem;
    box-shadow: none;
    border: 1px solid rgba(var(--brand-secondary-rgb), 0.15);
    background: rgba(13, 20, 32, 0.85);
  }

  .nav-item-has-sub.is-open .nav-sub {
    display: block;
  }

  .nav-item-has-sub:focus-within .nav-sub {
    display: block;
  }

  .nav-item-has-sub .nav-caret {
    position: absolute;
    right: 0.5rem;
    top: 0.4rem;
  }

  body.nav-mobile-open {
    overflow: hidden;
  }

  body.nav-mobile-open .wa-float,
  body.nav-mobile-open .social-float-left {
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s;
  }
}

/* ----- Hero ----- */
.hero {
  padding: clamp(3rem, 10vw, 5.5rem) 0 clamp(4rem, 12vw, 7rem);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.35rem 0.85rem 0.35rem 0.35rem;
  background: rgba(var(--brand-secondary-rgb), 0.1);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.82rem;
  color: var(--cyan);
  margin-bottom: 1.25rem;
}

.hero-badge img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
}

.hero h1 {
  font-size: clamp(2.1rem, 5.5vw, 3.35rem);
  line-height: 1.12;
  font-weight: var(--font-weight-semibold);
  letter-spacing: -0.03em;
  margin: 0 0 1rem;
}

.hero h1 span {
  background: linear-gradient(90deg, var(--brand-secondary), var(--brand-primary), #7eb8e8);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero p {
  color: var(--text-muted);
  font-size: 1.08rem;
  max-width: 52ch;
  margin: 0 0 1.75rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.hero-visual {
  position: relative;
  min-height: 280px;
}

.hero-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-glow);
  transform: perspective(1000px) rotateY(-6deg) rotateX(4deg);
  transition: transform 0.5s ease;
}

.hero-card:hover {
  transform: perspective(1000px) rotateY(0deg) rotateX(0deg);
}

.hero-card img {
  width: 100%;
  height: 320px;
  object-fit: cover;
}

.hero-stat {
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  right: 1rem;
  padding: 1rem 1.15rem;
  background: rgba(10, 15, 28, 0.9);
  backdrop-filter: blur(12px);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 0.75rem;
  text-align: center;
}

.hero-stat strong {
  display: block;
  font-size: 1.25rem;
  color: var(--cyan);
}

.hero-stat span {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ----- Cards / servicios ----- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

.card {
  background: var(--bg-panel);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.25s;
}

.card:hover {
  border-color: rgba(var(--brand-secondary-rgb), 0.45);
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
}

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(var(--brand-secondary-rgb), 0.22), rgba(var(--brand-primary-rgb), 0.45));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  color: var(--cyan);
}

.card-icon svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.card h3 {
  margin: 0;
  font-size: 1.1rem;
}

.card p {
  margin: 0;
  flex: 1;
  color: var(--text-muted);
  font-size: 0.92rem;
}

.card .btn {
  align-self: flex-start;
  margin-top: 0.5rem;
}

.card-img {
  height: 140px;
  border-radius: var(--radius);
  overflow: hidden;
  margin: -0.25rem -0.25rem 0.5rem -0.25rem;
}

.card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ----- Timeline proceso ----- */
.timeline {
  display: grid;
  gap: 1rem;
  counter-reset: step;
}

.timeline-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.25rem;
  align-items: start;
  padding: 1.35rem 1.5rem;
  background: var(--bg-panel);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.timeline-item::before {
  counter-increment: step;
  content: counter(step);
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  font-weight: 800;
  background: linear-gradient(135deg, var(--brand-secondary), var(--brand-primary));
  color: #fff;
  border-radius: 12px;
}

.timeline-item h3 {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
}

.timeline-item p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* ----- Contact grid ----- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  align-items: start;
}

.contact-stack {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.contact-map-panel .contact-map-wrap--stacked {
  min-height: 0;
}

.contact-map-panel .contact-map-wrap--stacked iframe {
  height: 280px;
}

@media (max-width: 860px) {
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .contact-map-panel .contact-map-wrap--stacked iframe {
    height: 240px;
  }
}

.contact-panel {
  background: var(--bg-panel);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
}

.form-row {
  margin-bottom: 1rem;
}

.form-row label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 0.35rem;
}

.form-row input,
.form-row textarea {
  width: 100%;
  padding: 0.65rem 0.85rem;
  border-radius: 0.65rem;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.25);
  color: var(--text);
  font-family: var(--font);
  font-size: 0.95rem;
}

.form-row input:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px rgba(var(--brand-secondary-rgb), 0.2);
}

.form-row textarea {
  min-height: 120px;
  resize: vertical;
}

.map-embed {
  border: 0;
  width: 100%;
  height: min(360px, 50vh);
  border-radius: var(--radius-lg);
  filter: saturate(0.95) contrast(1.05);
}

.map-note {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.75rem;
}

/* ----- Footer ----- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 2.5rem 0 6rem;
  background: rgba(0, 0, 0, 0.25);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: 2rem;
}

@media (max-width: 1100px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

.footer-brand img {
  height: 40px;
  width: auto;
  margin-bottom: 0.75rem;
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin: 0;
  max-width: 36ch;
}

.footer-col h4 {
  margin: 0 0 0.75rem;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--cyan);
}

.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-col li {
  margin-bottom: 0.45rem;
}

.footer-col a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.92rem;
}

.footer-col a:hover {
  color: var(--text);
  text-decoration: underline;
}

.footer-social {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.footer-social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-social-link svg {
  width: 1.05rem;
  height: 1.05rem;
  flex-shrink: 0;
  color: var(--cyan);
}

.footer-bottom {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* ----- WhatsApp flotante ----- */
.wa-float {
  position: fixed;
  right: 1.15rem;
  bottom: 1.15rem;
  z-index: 9999;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.75rem 1.1rem;
  background: var(--whatsapp);
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
  border-radius: 999px;
  box-shadow: 0 8px 32px rgba(37, 211, 102, 0.45);
  text-decoration: none;
  animation: wa-pulse 2.5s ease-in-out infinite;
  transition: transform 0.2s, box-shadow 0.2s;
}

.wa-float:hover {
  transform: scale(1.04);
  color: #fff;
  text-decoration: none;
  box-shadow: 0 12px 40px rgba(37, 211, 102, 0.55);
}

.wa-float svg {
  flex-shrink: 0;
}

/* ----- Redes sociales flotantes ----- */
.social-float-left {
  position: fixed;
  left: 1.15rem;
  bottom: 1.15rem;
  z-index: 9998;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.social-float-btn {
  width: 2.85rem;
  height: 2.85rem;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 800;
  color: #fff;
  text-decoration: none;
  box-shadow: 0 8px 20px rgba(2, 6, 23, 0.45);
  transition: transform 0.2s, box-shadow 0.2s;
}

.social-float-btn:hover {
  transform: scale(1.06);
  color: #fff;
  text-decoration: none;
  box-shadow: 0 10px 26px rgba(2, 6, 23, 0.55);
}

.social-float-btn svg {
  display: block;
  width: 1.75rem;
  height: 1.75rem;
}

.social-float-btn--fb {
  background: linear-gradient(135deg, #1877f2 0%, #125bc4 100%);
}

.social-float-btn--ig {
  background: linear-gradient(135deg, #f58529 0%, #dd2a7b 45%, #8134af 70%, #515bd4 100%);
}

@keyframes wa-pulse {
  0%,
  100% {
    box-shadow: 0 8px 32px rgba(37, 211, 102, 0.45);
  }
  50% {
    box-shadow: 0 8px 40px rgba(37, 211, 102, 0.65);
  }
}

@media (max-width: 480px) {
  .social-float-left {
    display: none;
  }

  .wa-float span {
    display: none;
  }

  .wa-float {
    left: auto;
    right: 0.75rem;
    bottom: 0.95rem;
    width: 2.6rem;
    height: 2.6rem;
    min-width: 2.6rem;
    padding: 0;
    gap: 0;
    border-radius: 50%;
    justify-content: center;
  }

  .social-float-left {
    left: auto;
    right: 0.75rem;
    bottom: 4.25rem;
    gap: 0.5rem;
    align-items: flex-end;
  }

  .social-float-btn {
    width: 2.6rem;
    height: 2.6rem;
    font-size: 0.72rem;
  }

  .wa-float svg,
  .social-float-btn svg {
    width: 1.2rem;
    height: 1.2rem;
  }
}

/* ----- Pagina Servicios ----- */
.services-hero {
  position: relative;
  padding: clamp(3.5rem, 10vw, 6rem) 0 clamp(2.5rem, 6vw, 4rem);
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.services-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(10, 15, 28, 0.94) 0%, rgba(var(--brand-primary-rgb), 0.55) 50%, rgba(10, 15, 28, 0.96) 100%),
    url("https://images.unsplash.com/photo-1451187580459-43490279c0fa?auto=format&fit=crop&w=1800&q=80") center/cover no-repeat;
  z-index: 0;
}

.services-hero .wrap {
  position: relative;
  z-index: 1;
}

.services-hero-inner {
  max-width: 42rem;
}

.services-hero h1 {
  font-size: clamp(1.85rem, 4vw, 2.75rem);
  margin-bottom: 0.75rem;
}

.services-hero p {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 1.25rem;
}

.services-sticky-wrap {
  position: sticky;
  top: 4.25rem;
  z-index: 40;
  padding: 0.65rem 0;
  margin-bottom: 0.5rem;
  background: linear-gradient(180deg, var(--bg) 70%, transparent);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(var(--brand-secondary-rgb), 0.12);
}

.services-sticky-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  justify-content: center;
}

.services-sticky-nav a {
  display: inline-flex;
  align-items: center;
  padding: 0.45rem 0.9rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 999px;
  text-decoration: none;
  transition: color 0.2s, border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.services-sticky-nav a:hover {
  color: var(--cyan);
  border-color: rgba(var(--brand-secondary-rgb), 0.45);
  background: rgba(var(--brand-secondary-rgb), 0.08);
}

.services-sticky-nav a.is-active {
  color: var(--cyan-light);
  border-color: var(--cyan);
  background: rgba(var(--brand-secondary-rgb), 0.14);
  box-shadow: 0 0 20px rgba(var(--brand-secondary-rgb), 0.15);
}

.services-section {
  scroll-margin-top: 6.5rem;
  padding: clamp(2.5rem, 5vw, 4rem) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.services-section:last-of-type {
  border-bottom: none;
}

.services-section-header {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.65rem;
  margin-bottom: clamp(1.25rem, 3vw, 2rem);
}

.services-section-header h2 {
  margin: 0;
  font-size: clamp(1.35rem, 3vw, 1.85rem);
}

.services-section-header p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.65;
  text-wrap: pretty;
}

.services-pdf-bullets {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.65;
}

.services-pdf-bullets li {
  margin-bottom: 0.35rem;
}

.services-grid {
  display: grid;
  gap: 1rem;
}

@media (min-width: 720px) {
  .services-grid.cols-2 {
    grid-template-columns: 1fr 1fr;
  }
}

.services-card {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.22);
}

.services-card-visual {
  position: relative;
  aspect-ratio: 16 / 9;
  max-height: 220px;
  overflow: hidden;
  background: var(--bg-panel);
}

.services-card-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.services-card-body {
  padding: 1.15rem 1.25rem 1.35rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.services-card-body h3 {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.services-card-body p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.55;
  flex: 1;
}

.teaser-servicios {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 960px) {
  .teaser-servicios {
    grid-template-columns: 1.1fr 1fr;
    align-items: center;
    gap: 2rem;
  }
}

.teaser-servicios-visual {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  aspect-ratio: 4 / 3;
  background: var(--bg-panel);
}

.teaser-servicios-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.contact-map-block {
  margin-top: 2rem;
}

.contact-map-wrap {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
  min-height: 320px;
  background: var(--bg-panel);
}

.contact-map-wrap iframe {
  display: block;
  width: 100%;
  height: 360px;
  border: 0;
}

.contact-map-note {
  margin-top: 0.65rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  text-align: center;
}

.services-card:hover .services-card-visual img {
  transform: scale(1.04);
}

.casos-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr));
  gap: 0.85rem;
  margin: clamp(1.5rem, 4vw, 2.25rem) 0;
  padding: 1.1rem 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.casos-metrics strong {
  display: block;
  font-size: 1.35rem;
  color: var(--cyan-light);
  font-weight: 800;
}

.casos-metrics span {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.casos-quote {
  margin-top: 1.5rem;
  padding: 1.25rem 1.4rem;
  border-left: 3px solid var(--cyan);
  background: rgba(var(--brand-secondary-rgb), 0.06);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: 0.95rem;
  color: var(--text-muted);
  max-width: none;
  line-height: 1.65;
  text-wrap: pretty;
}

.casos-feature {
  margin-top: 1.25rem;
}

.cases-hero {
  position: relative;
  padding: clamp(3.5rem, 9vw, 6rem) 0 clamp(2.5rem, 5vw, 4rem);
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}

.cases-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(135deg, rgba(10, 15, 28, 0.96) 0%, rgba(var(--brand-primary-rgb), 0.54) 50%, rgba(10, 15, 28, 0.98) 100%),
    url("img/caso-fibra-optica-01.jpeg") center/cover no-repeat;
  opacity: 0.36;
}

.cases-hero .wrap,
.cases-section .wrap {
  position: relative;
  z-index: 1;
}

.cases-hero-inner {
  max-width: 52rem;
}

.cases-hero h1 {
  margin: 0 0 0.85rem;
  font-size: clamp(2rem, 5vw, 3.1rem);
  line-height: 1.08;
}

.cases-hero p {
  margin: 0;
  max-width: 60ch;
  color: var(--text-muted);
  font-size: 1.04rem;
}

.cases-section {
  padding: clamp(3rem, 7vw, 5rem) 0;
}

.cases-section + .cases-section {
  border-top: 1px solid rgba(var(--brand-secondary-rgb), 0.08);
}

.cases-section-header {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.cases-section-header h2 {
  margin: 0;
  font-size: clamp(1.45rem, 3vw, 2rem);
}

.cases-section-header p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 70ch;
}

.cases-gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

@media (max-width: 960px) {
  .cases-gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .cases-gallery-grid {
    grid-template-columns: 1fr;
  }
}

.cases-gallery-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.22);
}

.cases-gallery-item img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  display: block;
}

.cases-gallery-caption {
  padding: 0.85rem 0.95rem 1rem;
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.55;
}

.cases-highlight {
  margin-top: 1.5rem;
  padding: 1.15rem 1.25rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  color: var(--text-muted);
  line-height: 1.7;
}

/* Permitir que el texto del bloque de casos haga saltos de linea. */

/* AOS fallback reduced motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto;
  }
}

@media (max-width: 1024px) {
  .hero-card {
    transform: none;
  }

  .services-sticky-wrap {
    top: 3.85rem;
  }
}

@media (max-width: 640px) {
  .section {
    padding: 3.15rem 0;
  }

  .hero p,
  .section-lead {
    font-size: 0.98rem;
  }

  .hero-stat {
    grid-template-columns: 1fr;
    gap: 0.55rem;
    text-align: left;
  }

  .hero-stat strong {
    font-size: 1.1rem;
  }

  .card,
  .contact-panel {
    padding: 1.2rem;
  }

  .timeline-item {
    grid-template-columns: 1fr;
    gap: 0.8rem;
    padding: 1.1rem 1rem;
  }

  .timeline-item::before {
    width: 38px;
    height: 38px;
    font-size: 0.95rem;
  }

  .services-sticky-wrap {
    top: 3.55rem;
    padding: 0.5rem 0;
  }

  .services-sticky-nav {
    justify-content: flex-start;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 0.2rem;
    scrollbar-width: thin;
  }

  .services-sticky-nav a {
    white-space: nowrap;
  }

  .services-card-body {
    padding: 1rem;
  }

  .btn {
    min-height: 42px;
  }
}
