:root{
  --azul:#0a2540; --azul2:#123b63; --acento:#ff9f1c; --acento2:#f08c00;
  --verde:#12805c; --bg:#ffffff; --gris:#f5f7fa; --text:#1d2733; --muted:#5c6b7c; --line:#e3e8ef;
}
*{box-sizing:border-box; margin:0; padding:0;}
html{scroll-behavior:smooth;}
body{font-family:'Segoe UI', system-ui, -apple-system, sans-serif; background:var(--bg); color:var(--text); line-height:1.65;}
.wrap{max-width:1080px; margin:0 auto; padding:0 22px;}

/* NAV */
nav{position:sticky; top:0; z-index:100; background:rgba(255,255,255,.95); backdrop-filter:blur(8px); border-bottom:1px solid var(--line);}
.nav-in{display:flex; align-items:center; justify-content:space-between; gap:14px; padding:12px 22px; max-width:1080px; margin:0 auto; position:relative;}
.logo{display:flex; align-items:center; gap:10px; font-weight:800; font-size:18px; color:var(--azul); text-decoration:none; white-space:nowrap; margin-right:auto;}
.logo svg{width:30px; height:30px;}
/* Menú desplegable a la derecha */
.menu-btn{background:none; border:1px solid var(--line); border-radius:9px; cursor:pointer; display:flex; align-items:center; justify-content:center; padding:9px; transition:background .15s;}
.menu-btn:hover{background:var(--gris);}
.menu{display:none; position:absolute; top:calc(100% + 10px); right:22px; background:#fff; border:1px solid var(--line); border-radius:14px; box-shadow:0 16px 44px rgba(10,37,64,.16); flex-direction:column; padding:10px; min-width:250px; z-index:200;}
.menu.abierto{display:flex;}
.menu a{color:var(--text); text-decoration:none; font-size:15px; font-weight:600; padding:11px 14px; border-radius:9px;}
.menu a:hover{background:var(--gris); color:var(--azul);}
.menu a.activo{color:var(--acento2);}
.btn{display:inline-block; background:var(--acento); color:#241500; font-weight:700; font-size:15px; padding:12px 26px; border-radius:8px; text-decoration:none; border:none; cursor:pointer; transition:background .15s, transform .15s;}
.btn:hover{background:var(--acento2); transform:translateY(-1px);}
.btn-grande{font-size:17px; padding:15px 34px;}
.btn-linea{background:transparent; border:2px solid rgba(255,255,255,.5); color:#fff; font-weight:600;}
.btn-linea:hover{background:rgba(255,255,255,.1); border-color:#fff;}

/* HERO portada */
.hero{position:relative; color:#fff; background:
  linear-gradient(100deg, rgba(6,24,42,.92) 0%, rgba(6,24,42,.72) 45%, rgba(6,24,42,.38) 100%),
  url('https://images.unsplash.com/photo-1509391366360-2e959784a276?w=1600&q=70&auto=format&fit=crop') center/cover no-repeat;}
.hero-in{max-width:1080px; margin:0 auto; padding:96px 22px 104px;}
.hero h1{font-size:clamp(30px,4.8vw,48px); line-height:1.15; margin-bottom:18px; font-weight:800; max-width:640px; letter-spacing:-.5px;}
.hero h1 span{color:var(--acento);}
.hero p{color:#d4e0ec; font-size:18px; margin-bottom:30px; max-width:540px;}
.hero-ctas{display:flex; gap:12px; flex-wrap:wrap;}
.hero-datos{display:flex; gap:40px; margin-top:46px; flex-wrap:wrap;}
.dato b{font-size:30px; display:block; color:#fff;}
.dato span{font-size:13px; color:#aebfd0;}

/* Cabecera de página interior */
.page-hero{background:linear-gradient(120deg, var(--azul), var(--azul2)); color:#fff; padding:52px 0 56px;}
.page-hero h1{font-size:clamp(26px,4vw,38px); line-height:1.2; max-width:720px; margin-bottom:12px;}
.page-hero p{color:#c4d3e3; font-size:16.5px; max-width:640px;}
.miga{font-size:13px; color:#9db4ca; margin-bottom:18px;}
.miga a{color:#c4d3e3; text-decoration:none;}
.miga a:hover{text-decoration:underline;}

/* Barra de confianza */
.confianza{background:var(--azul); color:#c4d3e3; font-size:14px;}
.confianza .wrap{display:flex; justify-content:center; gap:14px 40px; flex-wrap:wrap; padding:14px 22px;}
.confianza b{color:#fff; font-weight:600;}

/* Secciones */
section{padding:64px 0;}
.gris{background:var(--gris);}
h2{font-size:clamp(23px,3.4vw,31px); text-align:center; margin-bottom:10px; color:var(--azul);}
.sub{text-align:center; color:var(--muted); max-width:600px; margin:0 auto 40px; font-size:16px;}
.prosa{max-width:760px; margin:0 auto;}
.prosa h2{text-align:left; font-size:24px; margin:34px 0 12px;}
.prosa h2:first-child{margin-top:0;}
.prosa p{color:var(--muted); margin-bottom:16px; font-size:15.5px;}
.prosa strong{color:var(--text);}
.prosa ul{margin:0 0 16px 22px; color:var(--muted); font-size:15.5px;}
.prosa li{margin-bottom:8px;}

/* Calculadora */
.calc{background:#fff; border:1px solid var(--line); border-radius:16px; box-shadow:0 10px 34px rgba(10,37,64,.08); padding:34px; max-width:680px; margin:0 auto;}
.campo label{font-weight:600; font-size:15px; display:block; margin-bottom:8px;}
.factura-val{font-size:28px; font-weight:800; color:var(--azul);}
input[type=range]{width:100%; accent-color:var(--acento2); margin:6px 0 4px;}
.rango-notas{display:flex; justify-content:space-between; font-size:12px; color:var(--muted); margin-bottom:18px;}
.resultados{display:grid; grid-template-columns:repeat(auto-fit,minmax(150px,1fr)); gap:12px; margin-bottom:8px;}
.res{background:var(--gris); border:1px solid var(--line); border-radius:12px; padding:16px 12px; text-align:center;}
.res b{display:block; font-size:24px; color:var(--verde);}
.res.destacado{background:#fff7ea; border-color:#f2ddb8;}
.res.destacado b{color:var(--acento2);}
.res span{font-size:12.5px; color:var(--muted);}
.aviso{font-size:12px; color:var(--muted); margin-bottom:22px;}
.form{border-top:1px solid var(--line); padding-top:22px;}
.form h3{font-size:18px; margin-bottom:4px; color:var(--azul);}
.form .form-sub{font-size:14px; color:var(--muted); margin-bottom:14px;}
.form input[type=text]{width:100%; padding:13px 14px; border:1px solid var(--line); border-radius:8px; font-size:15px; margin-bottom:10px; font-family:inherit;}
.form input[type=text]:focus{outline:2px solid var(--acento); border-color:transparent;}
.btn-enviar{width:100%; display:flex; align-items:center; justify-content:center; gap:10px;}
.btn-enviar svg{width:20px; height:20px;}
.rgpd{font-size:12px; color:var(--muted); margin-top:10px; text-align:center;}

/* Tarjetas de pasos / enlaces */
.tres{display:grid; grid-template-columns:repeat(auto-fit,minmax(250px,1fr)); gap:18px;}
.paso{background:#fff; border:1px solid var(--line); border-radius:14px; padding:26px;}
.paso .ico{width:46px; height:46px; border-radius:10px; background:#fff3e0; display:flex; align-items:center; justify-content:center; margin-bottom:14px;}
.paso .ico svg{width:24px; height:24px; stroke:var(--acento2);}
.paso h3{font-size:17px; margin-bottom:6px; color:var(--azul);}
.paso p{font-size:14.5px; color:var(--muted);}
a.paso{display:block; text-decoration:none; transition:transform .15s, box-shadow .15s;}
a.paso:hover{transform:translateY(-3px); box-shadow:0 10px 26px rgba(10,37,64,.1);}
a.paso .mas{color:var(--acento2); font-weight:700; font-size:14px; margin-top:10px; display:inline-block;}

/* Dos columnas con foto */
.dos-col{display:grid; grid-template-columns:1fr 1fr; gap:36px; align-items:center;}
.dos-col img{width:100%; height:100%; max-height:380px; object-fit:cover; border-radius:16px; box-shadow:0 12px 34px rgba(10,37,64,.15);}
.dos-col h2{text-align:left;}
.dos-col ul{list-style:none; margin-top:18px;}
.dos-col li{display:flex; gap:12px; align-items:flex-start; margin-bottom:14px; font-size:15.5px; color:var(--muted);}
.dos-col li svg{width:20px; height:20px; stroke:var(--verde); flex-shrink:0; margin-top:3px;}
.dos-col li b{color:var(--text);}

/* FAQ */
.faq{max-width:720px; margin:0 auto;}
details{background:#fff; border:1px solid var(--line); border-radius:10px; padding:16px 20px; margin-bottom:10px;}
summary{font-weight:600; cursor:pointer; font-size:15.5px; color:var(--azul);}
details p{margin-top:10px; font-size:14.5px; color:var(--muted);}

/* CTA final */
.cta-final{background:linear-gradient(150deg, var(--azul), var(--azul2)); color:#fff; text-align:center; border-radius:18px; padding:52px 30px; margin:0 22px;}
.cta-final h2{color:#fff;}
.cta-final p{color:#c4d3e3; max-width:520px; margin:0 auto 26px;}

footer{padding:34px 20px; font-size:13.5px; color:var(--muted); border-top:1px solid var(--line); margin-top:64px;}
.foot-in{max-width:1080px; margin:0 auto; display:flex; justify-content:space-between; gap:20px; flex-wrap:wrap;}
.foot-in a{color:var(--muted);}

/* WhatsApp flotante (con bote) */
.wa-float{position:fixed; right:20px; bottom:20px; background:#25D366; width:58px; height:58px; border-radius:50%; display:flex; align-items:center; justify-content:center; box-shadow:0 8px 20px rgba(0,0,0,.28); z-index:120; animation:bote 2.6s ease-in-out infinite;}
.wa-float:hover{animation-play-state:paused; transform:scale(1.07);}
.wa-float svg{width:31px; height:31px; fill:#fff;}
@keyframes bote{0%,100%{transform:translateY(0);} 12%{transform:translateY(-14px);} 22%{transform:translateY(0);} 30%{transform:translateY(-7px);} 38%{transform:translateY(0);}}

/* Barras de porcentaje animadas */
.barras{max-width:760px; margin:0 auto; display:flex; flex-direction:column; gap:22px;}
.barra-item .barra-top{display:flex; justify-content:space-between; align-items:baseline; margin-bottom:8px; gap:14px;}
.barra-item .barra-top b{font-size:16px; color:var(--azul);}
.barra-item .barra-top span{font-size:22px; font-weight:800; color:var(--acento2); white-space:nowrap;}
.barra{height:14px; background:var(--line); border-radius:20px; overflow:hidden;}
.barra i{display:block; height:100%; width:0; border-radius:20px; background:linear-gradient(90deg, var(--acento), var(--acento2)); transition:width 1.4s cubic-bezier(.25,.7,.3,1);}
.barra i.verde{background:linear-gradient(90deg, #2fae7d, var(--verde));}
.barra-item .nota{font-size:13px; color:var(--muted); margin-top:6px;}

/* Fotos en artículos */
.foto-articulo{width:100%; max-height:340px; object-fit:cover; border-radius:16px; box-shadow:0 12px 34px rgba(10,37,64,.15); margin-bottom:30px;}

/* Tarjetas de novedades */
.news-grid{display:grid; grid-template-columns:repeat(auto-fit,minmax(280px,1fr)); gap:20px;}
.news-card{background:#fff; border:1px solid var(--line); border-radius:14px; overflow:hidden; display:flex; flex-direction:column;}
.news-card img{width:100%; height:170px; object-fit:cover;}
.news-card .cuerpo{padding:20px; display:flex; flex-direction:column; gap:8px; flex:1;}
.news-card .etiqueta{font-size:11.5px; font-weight:700; color:var(--acento2); text-transform:uppercase; letter-spacing:.6px;}
.news-card h3{font-size:17px; color:var(--azul); line-height:1.35;}
.news-card p{font-size:14px; color:var(--muted); flex:1;}

/* Botón bajo cada tarjeta de servicio */
.btn-card{margin-top:14px; width:100%; text-align:center;}

/* Ventana emergente de presupuesto por servicio */
.modal-fondo{position:fixed; inset:0; background:rgba(10,37,64,.58); display:none; align-items:center; justify-content:center; z-index:300; padding:20px;}
.modal-fondo.abierto{display:flex;}
.modal{background:#fff; border-radius:18px; max-width:480px; width:100%; padding:30px; position:relative; box-shadow:0 24px 60px rgba(0,0,0,.3);}
.modal .cerrar{position:absolute; top:12px; right:16px; background:none; border:none; font-size:26px; line-height:1; cursor:pointer; color:var(--muted);}
.modal .cerrar:hover{color:var(--text);}
.modal h3{font-size:19px; color:var(--azul); margin-bottom:4px; padding-right:26px;}
.modal .modal-serv{display:inline-block; background:#fff3e0; color:var(--acento2); font-weight:700; font-size:13.5px; padding:5px 12px; border-radius:20px; margin:8px 0 16px;}
.modal input[type=text], .modal textarea{width:100%; padding:13px 14px; border:1px solid var(--line); border-radius:8px; font-size:15px; margin-bottom:10px; font-family:inherit; resize:vertical;}
.modal input[type=text]:focus, .modal textarea:focus{outline:2px solid var(--acento); border-color:transparent;}
.modal .rgpd{margin-top:10px;}

/* Aparición al hacer scroll */
.rev{opacity:0; transform:translateY(22px); transition:opacity .6s ease, transform .6s ease;}
.rev.vis{opacity:1; transform:none;}

@media(max-width:820px){
  .hero-in{padding:64px 22px 72px;}
  .dos-col{grid-template-columns:1fr;}
  .dos-col img{max-height:260px;}
  .nav-in .btn{padding:10px 16px; font-size:13.5px;}
}
