:root{
  /* FIX header */
  --header-h: 64px;

  /* Palette */
  --d:#0f172a;    /* dark */
  --p:#1e3a8a;    /* primary */
  --l:#3b82f6;    /* light */
  --a:#6366f1;    /* accent */
  --t:#1f2937;    /* text */
  --mut:#6b7280;  /* muted */
  --bg:#f8fafc;   /* bg light */
  --w:#ffffff;    /* white */
}

*{box-sizing:border-box;margin:0;padding:0}
html{scroll-behavior:smooth}
body{
  font-family:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu,Cantarell,sans-serif;
  line-height:1.6;
  color:var(--t);
  overflow-x:hidden;
  background:var(--w);
}
a{color:inherit;text-decoration:none}
img{max-width:100%;display:block}

.container{max-width:1100px;margin:0 auto;padding:0 18px}

/* Para que al ir a #secciones no quede tapado por el header fixed */
section{scroll-margin-top:calc(var(--header-h) + 10px)}

/* ================= HEADER / NAV (FIXEADO) ================= */
.header{
  position:fixed;
  top:0;left:0;right:0;
  height:var(--header-h);
  z-index:1000;
  background:linear-gradient(135deg,var(--d),var(--p));
  box-shadow:0 2px 10px rgba(0,0,0,.15);
}

.nav{
  height:100%;
  display:flex;
  align-items:center;
  justify-content:space-between;
  position:relative;
}

/* Brand / logo */
.brand{
  display:flex;
  align-items:center;
}

.brand img{
  height: auto;        /* deja de forzar altura */
  max-height: 46px;    /* límite real del header */
  width: auto;
  transform: scale(4); /* AGRANDA visualmente el logo */
  transform-origin: left center;
}

/* Desktop menu */
.menu{
  display:flex;
  align-items:center;
  gap:20px;
  list-style:none;
}

.menu a{
  color:var(--w);
  font-weight:650;
  font-size:0.95rem;
  line-height:1;
  padding:8px 0;
  transition:color .2s ease;
}

.menu a:hover{color:var(--a)}

/* Hamburger */
.menu-btn{
  display:none;
  background:transparent;
  border:0;
  cursor:pointer;
  padding:10px;
}

.menu-btn span{
  display:block;
  width:26px;
  height:2px;
  background:var(--w);
  margin:6px 0;
}

/* ================= HERO ================= */
.hero{
  margin-top:var(--header-h);
  padding:95px 18px 80px;
  text-align:center;
  color:var(--w);
  background:linear-gradient(135deg,var(--d),var(--p),var(--l));
}

.hero h1{
  font-size:clamp(2rem,5vw,3rem);
  line-height:1.15;
  margin-bottom:12px;
}

.hero p{
  max-width:720px;
  margin:0 auto 24px;
  font-size:1.15rem;
  opacity:.95;
}

.cta{
  display:flex;
  gap:12px;
  justify-content:center;
  flex-wrap:wrap;
}

.btn{
  display:inline-block;
  padding:12px 22px;
  border-radius:10px;
  font-weight:750;
  transition:transform .2s ease, box-shadow .2s ease, background .2s ease, color .2s ease;
}

.btn.primary{
  background:var(--w);
  color:var(--p);
}

.btn.primary:hover{
  transform:translateY(-2px);
  box-shadow:0 10px 25px rgba(0,0,0,.2);
}

.btn.ghost{
  border:2px solid var(--w);
  color:var(--w);
}

.btn.ghost:hover{
  background:var(--w);
  color:var(--p);
}

/* ================= SECTIONS ================= */
.section{padding:70px 0;background:var(--w)}
.section.alt{background:var(--bg)}
.section.dark{
  background:linear-gradient(135deg,var(--d),var(--p));
  color:var(--w);
}

.section h2{
  text-align:center;
  font-size:2.1rem;
  margin-bottom:8px;
}

.sub{
  text-align:center;
  color:var(--mut);
  margin-bottom:28px;
}

.section.dark .sub{color:rgba(255,255,255,.85)}

.grid{display:grid;gap:18px}
/* Servicios: 2x2 parejo */
.grid.cards{
  grid-template-columns:1fr;
}

/* Desktop / tablet */
@media (min-width:700px){
  .grid.cards{
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }
}

.grid.contact{grid-template-columns:repeat(auto-fit,minmax(220px,1fr));margin-top:26px}

/* Cards */
.card{
  background:var(--w);
  border-radius:14px;
  padding:22px;
  box-shadow:0 4px 10px rgba(0,0,0,.06);
  border-top:4px solid var(--p);
}
.card{
  height:100%;
  display:flex;
  flex-direction:column;
}

.card .ico{font-size:2.2rem;margin-bottom:8px}
.card h3{margin:6px 0 8px}
.card p,.card li{color:var(--mut)}
.card ul{margin-top:10px;padding-left:18px}

/* Split (cobertura) */
.split{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:22px;
  align-items:center;
}

.box{
  background:linear-gradient(135deg,var(--l),var(--a));
  color:var(--w);
  padding:22px;
  border-radius:14px;
}

.box h3{margin-bottom:10px}

.loc{list-style:none}
.loc li{
  padding:10px 0;
  border-bottom:1px solid rgba(255,255,255,.2);
}
.loc li::before{content:"📍 ";margin-right:6px}

.center{text-align:center}

/* Contact */
.contact-item{
  display:flex;
  flex-direction:column;
  gap:6px;
  align-items:center;
  justify-content:center;
  padding:18px;
  border-radius:14px;
  background:rgba(255,255,255,.08);
  border:1px solid rgba(255,255,255,.12);
}

.contact-item:hover{background:rgba(255,255,255,.12)}
.contact-item .ico{font-size:2.2rem}
.contact-item small{opacity:.9}

.note{
  margin-top:26px;
  padding:18px;
  border-radius:14px;
  background:rgba(255,255,255,.10);
  border:1px solid rgba(255,255,255,.12);
}

/* ================= CARRUSEL ================= */
.carousel{
  position:relative;
  max-width:1100px;
  margin:0 auto;
  border-radius:14px;
  overflow:hidden;
}

.track{
  display:flex;
  transition:transform .45s ease;
  will-change:transform;
}

.slide{
  min-width:100%;
  position:relative;
}

.slide img{
  height:480px;
  width:100%;
  object-fit:cover;
}

.slide figcaption{
  position:absolute;
  left:0;right:0;bottom:0;
  padding:18px 18px 16px;
  background:linear-gradient(to top,rgba(0,0,0,.75),transparent);
  color:#fff;
}

.slide figcaption strong{
  display:block;
  font-size:1.2rem;
  margin-bottom:2px;
}

.slide figcaption span{opacity:.9}

.nav{
  /* OJO: esto es el botón del carrusel también; tu HTML usa .nav en el header
     por eso NO usamos ".nav" acá. Usamos ".carousel .nav" abajo. */
}

.carousel .nav{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  width:46px;
  height:46px;
  border-radius:999px;
  border:0;
  cursor:pointer;
  z-index:2;
  background:rgba(255,255,255,.92);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:1.3rem;
  transition:.2s;
}

.carousel .nav:hover{
  background:#fff;
  transform:translateY(-50%) scale(1.06);
}

.carousel .prev{left:12px}
.carousel .next{right:12px}

.dots{
  display:flex;
  gap:8px;
  justify-content:center;
  align-items:center;
  margin-top:12px;
}

.dot{
  width:10px;
  height:10px;
  border-radius:999px;
  border:0;
  cursor:pointer;
  background:#9ca3af;
  transition:.2s;
}

.dot.active{
  width:28px;
  border-radius:8px;
  background:var(--p);
}

/* ================= FOOTER ================= */
.footer{
  background:var(--d);
  color:rgba(255,255,255,.85);
  padding:20px 0;
  text-align:center;
}

/* ================= MOBILE ================= */
@media (max-width:768px){
  :root{
    --header-h:56px;
  }

  /* LOGO */
  .brand{
    display:flex;
    align-items:center;
  }

  .brand img{
    height:auto;
    max-height:36px;        /* límite real del header */
    width:auto;
    transform:scale(1.5);  /* agranda el logo sin romper el nav */
    transform-origin:left center;
  }

  /* Menu */
  .menu-btn{
    display:block;
  }

  .menu{
    display:none;
    position:absolute;
    top:100%;
    left:0;
    right:0;
    flex-direction:column;
    gap:0;
    background:rgba(15,23,42,.98);
    padding:10px 18px;
    border-bottom:1px solid rgba(255,255,255,.15);
  }

  .menu.open{
    display:flex;
  }

  .menu a{
    padding:14px 0;
    font-size:1rem;
  }

  /* Layout tweaks */
  .split{
    grid-template-columns:1fr;
  }

  .slide img{
    height:300px;
  }

  .carousel .nav{
    width:40px;
    height:40px;
  }
}


/* ================= ANIMACIONES SUAVES ================= */
@keyframes fadeInUp{
  from{opacity:0;transform:translateY(18px)}
  to{opacity:1;transform:translateY(0)}
}
.card{animation:fadeInUp .45s ease-out}
/* WhatsApp Floating Button (FIX) */
.wa-float{
  position:fixed !important;
  right:14px;
  bottom:14px;
  width:48px;
  height:48px;
  border-radius:999px;
  background:#25D366;
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow:0 10px 25px rgba(0,0,0,.25);
  z-index:2000;
}

.wa-float img{
  width:60%;
  height:60%;
  object-fit:contain;
  display:block;
}

/* Desktop un toque más grande */
@media (min-width:769px){
  .wa-float{
    width:56px;
    height:56px;
    right:18px;
    bottom:18px;
  }
}
