:root{
  --azul-marino: #1b2249;
  --azul-marino-oscuro: #161c3d;
  --verde-whatsapp: #5cb85c;
  --verde-boton: #4caf50;
  --gris-claro: #d9d9d9;
  --gris-topbar: #c9c9c9;
  --blanco: #ffffff;
  --texto-claro: #f2f2f2;
}

*{
  margin:0;
  padding:0;
  box-sizing:border-box;
}

html{
  scroll-behavior: smooth;
}

body{
  font-family: 'Poppins', sans-serif;
  font-weight: 400;
  color:#222;
  line-height:1.5;
  overflow-x:hidden;
}

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

/* ===================== IMAGENES ===================== */
.img-placeholder{
  width:100%;
  height:100%;
  display:flex;
  align-items:center;
  justify-content:center;
  background:#e3e3e3;
  overflow:hidden;
}
.img-placeholder img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

a{ text-decoration:none; color:inherit; }
ul{ list-style:none; }
button{ font-family:'Poppins', sans-serif; cursor:pointer; border:none; }

h1,h2,h3,h4{
  font-weight:600;
}

/* ===================== TOP BAR ===================== */
.topbar{
  background:var(--gris-topbar);
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:8px 24px;
  font-size:13px;
  color:#222;
  flex-wrap:wrap;
  gap:8px;
}
.topbar-info{
  display:flex;
  align-items:center;
  gap:24px;
  flex-wrap:wrap;
}
.topbar-info span{
  display:flex;
  align-items:center;
  gap:6px;
}
.topbar-whatsapp{
  background:var(--verde-whatsapp);
  color:#fff;
  font-weight:600;
  font-size:12px;
  padding:8px 18px;
  border-radius:6px;
  display:flex;
  align-items:center;
  gap:8px;
  line-height:1.2;
}
.topbar-whatsapp:hover{
  background: var(--verde-boton);
  transition: 0.3s;
}
.icons{
  height: 22px;
  width: auto;
  object-fit: contain;
  flex-shrink: 0;
}

/* ===================== NAV ===================== */
.navbar{
  background:var(--azul-marino);
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:14px 40px;
  flex-wrap:wrap;
  position:relative;
  z-index:100;
}
.logo{
  display:flex;
  align-items:center;
  gap:12px;
}
.logo .img-placeholder{
  width:62px;
  height:62px;
  background:transparent;
  flex-shrink:0;
}
.logo .img-placeholder img{
  object-fit:contain;
}
.logo-text{
  color:#fff;
  font-size:13px;
  font-weight:600;
  line-height:1.2;
}
.nav-links{
  display:flex;
  gap:48px;
}
.nav-links a{
  color:#fff;
  font-size:17px;
  font-weight:400;
  transition:opacity .2s;
}
.nav-links a:hover{ opacity:.7; }

.nav-toggle{
  display:none;
  flex-direction:column;
  gap:5px;
  background:none;
  padding:6px;
  z-index:101;
}
.nav-toggle span{
  width:26px;
  height:3px;
  background:#fff;
  border-radius:2px;
  transition: transform 0.3s, opacity 0.3s;
}

/* ===================== HERO / CARRUSEL ===================== */
.hero{
  position:relative;
  width:100%;
  height:62vw;
  max-height:560px;
  min-height:340px;
  overflow:hidden;
}
.hero-slides{
  position:relative;
  width:100%;
  height:100%;
}
.hero-slide{
  position:absolute;
  inset:0;
  opacity:0;
  transition:opacity .8s ease-in-out;
}
.hero-slide.active{
  opacity:1;
}
.hero-slide .img-placeholder{
  width:100%;
  height:100%;
  background:#1b2249;
}
.hero-overlay{
  position:absolute;
  inset:0;
  background:linear-gradient(90deg, rgba(0,0,0,.45) 0%, rgba(0,0,0,.15) 60%, rgba(0,0,0,.35) 100%);
  z-index:1;
}
.hero-content{
  position:absolute;
  inset:0;
  z-index:2;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  text-align:center;
  padding:0 20px;
}
.hero-content h1{
  color:#fff;
  font-size:clamp(22px, 4.5vw, 52px);
  font-weight:700;
  line-height:1.2;
  text-shadow:0 2px 8px rgba(0,0,0,.35);
}
.hero-cta{
  margin-top:28px;
  background:var(--azul-marino);
  color:#fff;
  font-size:16px;
  font-weight:600;
  padding:14px 34px;
  border-radius:8px;
  display:inline-block;
}
.hero-cta:hover{
  background-color: #161c3d;
  transition: 0.3s;
}
.hero-watermark{
  position:absolute;
  bottom:50%;
  right:8%;
  width:90px;
  height:90px;
  background:rgba(255,255,255,.18);
  transform:rotate(45deg);
  z-index:1;
}
.hero-brand{
  position:absolute;
  bottom:18px;
  right:30px;
  color:#fff;
  font-size:clamp(14px,2vw,24px);
  font-weight:600;
  z-index:2;
  text-shadow:0 2px 6px rgba(0,0,0,.4);
}
.hero-arrow{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  width:44px;
  height:44px;
  border-radius:50%;
  background:rgba(27,34,73,.55);
  color:#fff;
  font-size:20px;
  display:flex;
  align-items:center;
  justify-content:center;
  z-index:3;
  transition:background .2s;
}
.hero-arrow:hover{ background:var(--azul-marino); }
.hero-arrow.prev{ left:24px; }
.hero-arrow.next{ right:24px; }

.hero-dots{
  position:absolute;
  bottom:14px;
  left:50%;
  transform:translateX(-50%);
  display:flex;
  gap:8px;
  z-index:3;
}
.hero-dots button{
  width:9px;
  height:9px;
  border-radius:50%;
  background:rgba(255,255,255,.5);
  padding:0;
}
.hero-dots button.active{
  background:#fff;
}

/* ===================== NOSOTROS ===================== */
.about{
  display:flex;
  align-items:center;
  gap:60px;
  padding:70px 60px;
  max-width:1300px;
  margin:0 auto;
  flex-wrap:wrap;
}
.about-img{
  flex:1 1 380px;
  min-width:280px;
}
.about-img .img-placeholder{
  width:100%;
  aspect-ratio: 4/3;
  height:auto;
  border-radius:4px;
}
.about-text{
  flex:1 1 420px;
  min-width:280px;
}
.about-text h2{
  font-size:38px;
  color:var(--azul-marino);
}
.about-text .tagline{
  font-style:italic;
  font-weight:400;
  font-size:15px;
  color:#444;
  margin-top:6px;
  margin-bottom:22px;
}
.about-text p{
  font-size:15px;
  color:#333;
  margin-bottom:18px;
}

/* ===================== QUE HACEMOS ===================== */
.services{
  padding:60px 40px 80px;
  max-width:1300px;
  margin:0 auto;
  text-align:center;
}
.services h2{
  color:var(--azul-marino);
  font-size:42px;
  margin-bottom:50px;
}
.services-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:34px;
  margin-bottom:34px;
}
.services-grid.row-2{
  grid-template-columns:repeat(2,1fr);
  max-width:760px;
  margin:0 auto;
}
.service-card{
  border-radius:10px;
  overflow:hidden;
  box-shadow:0 6px 18px rgba(0,0,0,.08);
}
.service-card .img-placeholder{
  width:100%;
  aspect-ratio:4/3;
  height:auto;
}
.service-label{
  background:var(--azul-marino);
  color:#fff;
  font-weight:600;
  font-size:15px;
  padding:18px 16px;
  text-align:center;
}

/* ===================== CONTACTO ===================== */
.contact-heading{
  text-align:center;
  color:var(--azul-marino);
  font-size:38px;
  line-height:1.3;
  max-width:780px;
  margin:60px auto 50px;
  padding:0 20px;
}
.contact-section{
  display:flex;
  flex-wrap:wrap;
  max-width:1300px;
  margin:0 auto 80px;
}
.contact-form{
  flex:1 1 420px;
  background:var(--azul-marino);
  padding:50px 48px;
  color:#fff;
}
.contact-form label{
  display:block;
  font-weight:600;
  margin-bottom:8px;
  font-size:15px;
}
.contact-form input,
.contact-form textarea{
  width:100%;
  border:none;
  border-radius:6px;
  padding:13px 16px;
  margin-bottom:22px;
  font-family:'Poppins', sans-serif;
  font-size:14px;
}
.contact-form textarea{
  resize:vertical;
  min-height:110px;
}
.contact-form button{
  background:var(--verde-boton);
  color:#fff;
  font-weight:600;
  font-size:14px;
  padding:12px 30px;
  border-radius:20px;
}
.enviar:hover{
  background-color: #3d8b3f;
  transition: 0.3s;
}
.contact-info{
  flex:1 1 420px;
  position:relative;
  min-height:380px;
  color:#fff;
  display:flex;
  align-items:center;
  justify-content:center;
}
.contact-info .img-placeholder{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  z-index:0;
}
.contact-info-overlay{
  position:absolute;
  inset:0;
  background:rgba(20,26,58,.55);
  z-index:1;
}
.contact-info-content{
  position:relative;
  z-index:2;
  padding:48px;
  width:100%;
}
.contact-info-content h3{
  font-size:40px;
  margin-bottom:22px;
  text-align:center;
}
.contact-line{
  display:flex;
  align-items:flex-start;
  gap:14px;
  margin-top:25px;
  font-size:14px;
  font-weight:600;
}
.contact-line .icon{
  width:30px;
  height:30px;
  border-radius:50%;
  background:rgba(255,255,255,.15);
  display:flex;
  align-items:center;
  justify-content:center;
  flex-shrink:0;
  font-size:14px;
  overflow:hidden;
}
.contact-line .icon img{
  width:16px;
  height:16px;
  object-fit:contain;
}
.contact-line p{
  margin-top:5px;
}

/* ===================== FOOTER ===================== */
footer{
  background:var(--azul-marino-oscuro);
  text-align:center;
  padding:40px 20px 24px;
  color:#fff;
}
.footer-logo{
  width:80px;
  height:80px;
  margin:0 auto 26px;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
}
.footer-logo .img-placeholder{
  width:80px;
  height:80px;
  background:transparent;
}
footer p{
  font-size:13px;
  opacity:.85;
}

/* ===================== BOTONES FLOTANTES ===================== */
.floating-buttons{
  position:fixed;
  right:22px;
  bottom:22px;
  display:flex;
  flex-direction:column;
  gap:14px;
  z-index:50;
}
.floating-buttons button,
.floating-buttons a{
  width:48px;
  height:48px;
  border-radius:50%;
  display:flex;
  align-items:center;
  justify-content:center;
  color:#fff;
  font-size:20px;
  box-shadow:0 4px 12px rgba(0,0,0,.25);
  transition:transform .2s;
}
.floating-buttons button:hover,
.floating-buttons a:hover{
  transform:translateY(-3px);
}
.btn-top{ background:var(--azul-marino); }
.Whatsapp{
  height:50px;
  width:50px;
  object-fit:contain;
}

/* =======================================================
   RESPONSIVE - TABLETS GRANDES (max 1024px)
   ======================================================= */
@media (max-width: 1024px){
  .about{
    padding:60px 40px;
    gap:40px;
  }
  .services{
    padding:50px 30px 60px;
  }
  .services h2{
    font-size:36px;
  }
  .contact-form{
    padding:40px 36px;
  }
  .contact-info-content{
    padding:40px 36px;
  }
  .contact-info-content h3{
    font-size:34px;
  }
  .contact-heading{
    font-size:34px;
  }
}

/* =======================================================
   RESPONSIVE - TABLETS PORTRAIT / MÓVILES GRANDES (max 900px)
   ======================================================= */
@media (max-width: 900px){
  /* --- Navbar hamburguesa --- */
  .nav-links{
    position:absolute;
    top:100%;
    left:0;
    right:0;
    background:var(--azul-marino);
    flex-direction:column;
    align-items:center;
    padding:0;
    gap:0;
    display:none;
    box-shadow:0 8px 16px rgba(0,0,0,.2);
  }
  .nav-links.open{
    display:flex;
  }
  .nav-links li{
    width:100%;
    text-align:center;
    border-top:1px solid rgba(255,255,255,.08);
  }
  .nav-links a{
    display:block;
    padding:16px 20px;
    font-size:16px;
    width:100%;
  }
  .nav-toggle{ display:flex; }

  .navbar{
    padding:14px 24px;
  }

  /* --- About --- */
  .about{
    flex-direction:column;
    padding:50px 30px;
    gap:30px;
  }
  .about-img{
    flex:1 1 100%;
    min-width:unset;
    width:100%;
  }
  .about-text{
    flex:1 1 100%;
    min-width:unset;
  }
  .about-text h2{
    font-size:32px;
  }

  /* --- Servicios --- */
  .services-grid{
    grid-template-columns: repeat(2,1fr);
    gap:20px;
  }
  .services-grid.row-2{
    grid-template-columns: repeat(2,1fr);
    max-width:100%;
  }

  /* --- Contacto --- */
  .contact-heading{
    font-size:30px;
    margin:50px auto 36px;
  }
  .contact-section{
    flex-direction:column;
    margin-bottom:60px;
  }
  .contact-form{
    flex:1 1 100%;
    padding:40px 30px;
  }
  .contact-info{
    flex:1 1 100%;
    min-height:320px;
  }
}

/* =======================================================
   RESPONSIVE - MÓVILES (max 600px)
   ======================================================= */
@media (max-width: 600px){
  /* --- Top bar --- */
  .topbar{
    flex-direction:column;
    align-items:center;
    gap:6px;
    padding:10px 16px;
    text-align:center;
  }
  .topbar-info{
    justify-content:center;
    gap:14px;
  }
  .topbar-whatsapp{
    width:100%;
    justify-content:center;
  }
  .icons{
    height:18px;
  }

  /* --- Navbar --- */
  .navbar{
    padding:12px 20px;
  }
  .logo .img-placeholder{
    width:52px;
    height:52px;
  }

  /* --- Hero --- */
  .hero{
    height:75vw;
    min-height:260px;
  }
  .hero-content h1{
    font-size:clamp(18px, 5.5vw, 30px);
  }
  .hero-cta{
    font-size:13px;
    padding:11px 22px;
    margin-top:18px;
  }
  .hero-arrow{
    width:34px;
    height:34px;
    font-size:15px;
  }
  .hero-arrow.prev{ left:12px; }
  .hero-arrow.next{ right:12px; }

  /* --- About --- */
  .about{
    padding:40px 20px;
    gap:24px;
  }
  .about-text h2{
    font-size:28px;
  }
  .about-text .tagline{
    font-size:14px;
  }
  .about-text p{
    font-size:14px;
  }

  /* --- Servicios --- */
  .services{
    padding:40px 16px 50px;
  }
  .services h2{
    font-size:30px;
    margin-bottom:30px;
  }
  .services-grid{
    grid-template-columns: 1fr;
    gap:18px;
  }
  .services-grid.row-2{
    grid-template-columns: 1fr;
    max-width:100%;
    margin:0;
  }
  .service-label{
    font-size:14px;
    padding:14px 12px;
  }

  /* --- Contacto --- */
  .contact-heading{
    font-size:24px;
    margin:36px auto 28px;
    padding:0 16px;
  }
  .contact-form{
    padding:30px 20px;
  }
  .contact-form input,
  .contact-form textarea{
    font-size:14px;
    padding:11px 14px;
  }
  .contact-info{
    min-height:280px;
  }
  .contact-info-content{
    padding:28px 20px;
  }
  .contact-info-content h3{
    font-size:28px;
    margin-bottom:14px;
  }
  .contact-line{
    font-size:13px;
    margin-top:18px;
    gap:10px;
  }

  /* --- Footer --- */
  footer{
    padding:30px 16px 20px;
  }
}

/* =======================================================
   RESPONSIVE - MÓVILES PEQUEÑOS (max 420px)
   ======================================================= */
@media (max-width: 420px){
  .topbar{
    font-size:11px;
    padding:8px 12px;
  }
  .topbar-info{
    flex-direction:column;
    gap:4px;
  }
  .topbar-whatsapp{
    font-size:11px;
    padding:7px 14px;
  }
  .navbar{
    padding:10px 16px;
  }
  .logo .img-placeholder{
    width:46px;
    height:46px;
  }
  .hero{
    height:72vw;
    min-height:240px;
  }
  .hero-content h1{
    font-size:clamp(16px, 6vw, 26px);
  }
  .hero-cta{
    font-size:12px;
    padding:10px 18px;
    margin-top:14px;
  }
  .about-text h2{
    font-size:24px;
  }
  .services h2{
    font-size:26px;
  }
  .contact-heading{
    font-size:22px;
  }
  .contact-info-content h3{
    font-size:24px;
  }
  .floating-buttons{
    right:14px;
    bottom:14px;
  }
  .floating-buttons button,
  .floating-buttons a{
    width:42px;
    height:42px;
  }
  .Whatsapp{
    height:42px;
    width:42px;
  }
}

 /* Grilla optimizada para 4 servicios */
  .interactive-services-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
  }

  /* Contenedor interactivo de la tarjeta */
  .service-card-interactive {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    border: 1px solid #eef0f6;
    position: relative;
    min-height: 420px;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.3s ease;
  }

  .service-card-interactive:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(27, 34, 73, 0.1);
  }

  /* Estado 1: Portada (Simple) */
  .card-preview-state {
    display: flex;
    flex-direction: column;
    height: 100%;
    opacity: 1;
    transform: scale(1);
    transition: opacity 0.4s ease, transform 0.4s ease, visibility 0.4s;
    flex-grow: 1;
  }

  /* Estado 2: Detallado (Oculto por defecto) */
  .card-detail-state {
    display: none;
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.4s ease, transform 0.4s ease;
    padding: 30px;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    flex-grow: 1;
    background: #ffffff;
  }

  /* Clase activa que alterna los estados de la tarjeta */
  .service-card-interactive.show-details .card-preview-state {
    opacity: 0;
    transform: scale(0.95);
    visibility: hidden;
    height: 0;
    min-height: 0;
    overflow: hidden;
    flex-grow: 0;
  }

  .service-card-interactive.show-details .card-detail-state {
    display: flex;
    opacity: 1;
    transform: scale(1);
  }

  /* Detalles internos */
  .card-detail-header h3 {
    color: var(--azul-marino);
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 12px;
    border-bottom: 2px solid #f4f5f8;
    padding-bottom: 10px;
  }

  .card-detail-desc {
    font-size: 13.5px;
    color: #555555;
    line-height: 1.6;
    margin-bottom: 18px;
  }

  .card-detail-tasks-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--azul-marino);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
    display: block;
  }

  .card-detail-list {
    list-style: none;
    padding: 0;
    margin: 0 0 20px 0;
  }

  .card-detail-item {
    font-size: 13px;
    color: #444444;
    margin-bottom: 8px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
    line-height: 1.5;
  }

  .card-detail-item strong {
    color: #222;
  }

  /* Ícono verde de checkmark */
  .card-detail-item::before {
    content: "✓";
    color: var(--verde-boton);
    font-weight: bold;
    font-size: 14px;
    flex-shrink: 0;
    margin-top: 1px;
  }

  /* Botones internos */
  .btn-see-more {
    margin-top: auto;
    background: var(--azul-marino);
    color: #ffffff !important;
    text-align: center;
    padding: 15px;
    font-weight: 600;
    font-size: 15px;
    border: none;
    width: 100%;
    cursor: pointer;
    transition: background 0.2s;
  }

  .btn-see-more:hover {
    background: var(--azul-marino-oscuro);
  }

  .btn-go-back {
    background: #f4f5f8;
    color: #555555;
    border: none;
    padding: 10px 20px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    align-self: flex-start;
  }

  .btn-go-back:hover {
    background: #eef0f5;
    color: var(--azul-marino);
  }

  /* Responsivo */
  @media (max-width: 900px) {
    .interactive-services-grid {
      grid-template-columns: 1fr;
      gap: 20px;
    }
    .service-card-interactive {
      min-height: auto;
    }
  }