:root{
--primary:#0b5fa5;
--secondary:#123b73;
--accent:#25d366;
--light:#f4f8fc;
--dark:#1f2937;
--white:#fff;
--radius:18px;
--shadow:0 10px 30px rgba(0,0,0,.12);
}

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

body{
font-family:"Poppins",sans-serif;
background:var(--light);
color:var(--dark);
line-height:1.6;
}

nav{
position:fixed;
top:0;
left:0;
width:100%;
padding:18px 8%;
display:flex;
justify-content:space-between;
align-items:center;
background:rgba(18,59,115,.92);
backdrop-filter:blur(10px);
z-index:1000;
}

.logo{
color:#fff;
font-size:1.3rem;
font-weight:700;
letter-spacing:1px;
}

nav ul{
display:flex;
list-style:none;
gap:28px;
}

nav a{
color:#fff;
text-decoration:none;
font-weight:500;
transition:.3s;
}

nav a:hover{
color:#7dd3fc;
}

.hero{
height:100vh;
display:flex;
justify-content:center;
align-items:center;
text-align:center;
padding:20px;
background:
linear-gradient(rgba(10,35,75,.82),rgba(10,35,75,.88)),
url("https://images.unsplash.com/photo-1509228468518-180dd4864904?auto=format&fit=crop&w=1800&q=80");
background-size:cover;
background-position:center;
color:#fff;
}

.overlay{
max-width:900px;
}

.hero h1{
font-size:4rem;
margin-bottom:15px;
}

.hero h2{
font-weight:400;
margin-bottom:20px;
}

.hero p{
font-size:1.1rem;
margin-bottom:40px;
}

.botones{
display:flex;
justify-content:center;
gap:20px;
flex-wrap:wrap;
}

.btn{
padding:16px 34px;
border-radius:50px;
text-decoration:none;
font-weight:600;
transition:.3s;
display:flex;
align-items:center;
gap:10px;
}

.whatsapp{
background:var(--accent);
color:#fff;
}

.instagram{
background:#fff;
color:var(--secondary);
}

.btn:hover{
transform:translateY(-5px);
box-shadow:var(--shadow);
}

section{
padding:100px 8%;
}

section h2{
text-align:center;
font-size:2.3rem;
margin-bottom:55px;
color:var(--secondary);
}

.cards{
display:grid;
grid-template-columns:repeat(auto-fit,minmax(240px,1fr));
gap:28px;
}

.card{
background:#fff;
padding:35px;
border-radius:var(--radius);
box-shadow:var(--shadow);
text-align:center;
transition:.3s;
}

.card:hover{
transform:translateY(-10px);
}

.card i{
font-size:46px;
color:var(--primary);
margin-bottom:20px;
}

.card h3{
margin-bottom:10px;
}

.card p{
color:#555;
font-size:.95rem;
}

#metodologia{
background:#eef5fc;
}

#contacto{
text-align:center;
}

#contacto p{
font-size:1.15rem;
margin:15px 0;
}

.grande{
margin:35px auto 0;
display:inline-flex;
}

.float{
position:fixed;
right:22px;
bottom:22px;
width:64px;
height:64px;
background:var(--accent);
border-radius:50%;
display:flex;
justify-content:center;
align-items:center;
text-decoration:none;
color:#fff;
font-size:32px;
box-shadow:var(--shadow);
transition:.3s;
z-index:999;
}

.float:hover{
transform:scale(1.1);
}

footer{
background:var(--secondary);
color:#fff;
text-align:center;
padding:40px 20px;
}

footer h3{
margin-bottom:10px;
}

.hidden{
opacity:0;
transform:translateY(40px);
transition:.8s;
}

.show{
opacity:1;
transform:none;
}

@media(max-width:768px){

nav{
padding:15px 20px;
flex-direction:column;
gap:12px;
}

nav ul{
gap:18px;
}

.hero h1{
font-size:2.6rem;
}

.hero h2{
font-size:1.2rem;
}

.botones{
flex-direction:column;
align-items:center;
}

.btn{
width:100%;
max-width:340px;
justify-content:center;
}

section{
padding:70px 25px;
}

section h2{
font-size:2rem;
}

.float{
width:58px;
height:58px;
font-size:28px;
}

}
.cards a{
    text-decoration:none;
    color:inherit;
}

.cards a:hover{
    color:inherit;
}
.contenido{

max-width:900px;

margin:120px auto;

padding:40px;

background:white;

border-radius:20px;

box-shadow:0 10px 30px rgba(0,0,0,.08);

}

.contenido h1{

color:#123B73;

margin-bottom:20px;

}

.contenido h2{

margin-top:40px;

margin-bottom:15px;

color:#0B5FA5;

}

.contenido p{

margin-bottom:15px;

}

.contenido pre{

background:#eef5fb;

padding:20px;

border-radius:10px;

overflow:auto;

font-size:18px;

margin:20px 0;

}

.contenido table{

width:100%;

border-collapse:collapse;

margin:25px 0;

}

.contenido th{

background:#123B73;

color:white;

padding:12px;

}

.contenido td{

padding:12px;

border:1px solid #ddd;

}

.contenido li{

margin:10px 0;

}
/* ===== CAJAS DE CONTENIDO ===== */

.caja{
    margin:30px 0;
    padding:22px;
    border-radius:14px;
    border-left:8px solid;
    box-shadow:0 5px 15px rgba(0,0,0,.08);
}

.caja h3{
    margin-top:0;
    margin-bottom:12px;
    font-size:1.2rem;
}

.caja p,
.caja li{
    margin-bottom:10px;
    line-height:1.7;
}

/* Definición */

.definicion{
    background:#eef6ff;
    border-color:#1976d2;
}

.definicion h3{
    color:#1976d2;
}

/* Ejemplo */

.ejemplo{
    background:#eefcf2;
    border-color:#2e7d32;
}

.ejemplo h3{
    color:#2e7d32;
}

/* Importante */

.importante{
    background:#fff8e6;
    border-color:#f9a825;
}

.importante h3{
    color:#d48806;
}

/* Error frecuente */

.error{
    background:#fdecec;
    border-color:#d32f2f;
}

.error h3{
    color:#c62828;
}

/* Consejo */

.consejo{
    background:#eefbff;
    border-color:#00acc1;
}

.consejo h3{
    color:#00838f;
}
.caja{
    background:#ffffff;
    border-left:6px solid #1E88E5;
    padding:25px;
    margin:30px 0;
    border-radius:12px;
    box-shadow:0 8px 24px rgba(0,0,0,.08);
}

.caja h3{
    margin-top:0;
    color:#0F2D59;
}

pre{
    background:#f7f9fc;
    padding:18px;
    border-radius:8px;
    overflow:auto;
    font-size:1.05rem;
}
.caja{
    transition:.3s;
}

.caja:hover{
    transform:translateY(-6px);
    box-shadow:0 15px 35px rgba(0,0,0,.15);
}
#topBtn{
position:fixed;
bottom:25px;
right:25px;
width:50px;
height:50px;
border:none;
border-radius:50%;
background:#0F2D59;
color:white;
font-size:22px;
cursor:pointer;
display:none;
z-index:999;
}

#topBtn:hover{
background:#1E88E5;
}
/* ---------- Cajas de contenido ---------- */

.caja{
    background:#fff;
    padding:25px;
    margin:30px 0;
    border-radius:12px;
    box-shadow:0 5px 18px rgba(0,0,0,.08);
}

.caja h2{
    margin-top:0;
}

.definicion{
    border-left:8px solid #2196F3;
}

.importante{
    border-left:8px solid #ff9800;
}

.ejemplo{
    border-left:8px solid #4CAF50;
}

.consejo{
    border-left:8px solid #8e44ad;
}

.error{
    border-left:8px solid #e53935;
}

pre{
    background:#f5f5f5;
    padding:20px;
    border-radius:8px;
    overflow-x:auto;
    font-size:18px;
}

table{
    width:100%;
    border-collapse:collapse;
    margin:30px 0;
}

table th{
    background:#1565c0;
    color:white;
    padding:14px;
}

table td{
    border:1px solid #ddd;
    padding:12px;
}

table tr:nth-child(even){
    background:#fafafa;
}

ol li,
ul li{
    margin-bottom:10px;
}

.contenido{
    max-width:1100px;
    margin:auto;
    padding:60px 20px;
    line-height:1.8;
}

.contenido h1{
    text-align:center;
    margin-bottom:40px;
}

.contenido h2{
    color:#1565c0;
}
@media (max-width:768px){

nav{
    flex-direction:column;
}

nav ul{
    flex-direction:column;
    text-align:center;
}

.hero h1{
    font-size:2rem;
}

.buscador input{
    width:90%;
}

table{
    display:block;
    overflow-x:auto;
}

}
.calculadora{

max-width:420px;

margin:50px auto;

background:white;

padding:25px;

border-radius:15px;

box-shadow:0 5px 20px rgba(0,0,0,.15);

}

.calculadora input{

width:100%;

padding:18px;

font-size:28px;

text-align:right;

margin-bottom:20px;

border:2px solid #1565c0;

border-radius:10px;

box-sizing:border-box;

}

.teclado{

display:grid;

grid-template-columns:repeat(4,1fr);

gap:12px;

}

.teclado button{

padding:18px;

font-size:22px;

border:none;

border-radius:10px;

background:#1565c0;

color:white;

cursor:pointer;

transition:.2s;

}

.teclado button:hover{

transform:scale(1.05);

}

.borrar{

background:#d32f2f !important;

}

.teclado button:last-child{

background:#d32f2f;

}
.igual{

grid-column:span 4;

background:#2e7d32 !important;

font-size:26px;

font-weight:bold;

}
