/* =========================================
   Enlace Soluciones Educativas · estilos
   Paleta tomada del logo: azul + tinta. Sin degradados ni emojis.
   ========================================= */
:root {
    --ink: #0f1f38;
    --ink-soft: #3d4a5c;
    --brand: #1f5fa8;
    --brand-dark: #174a85;
    --brand-tint: #eaf1f9;
    --line: #e2e5e9;
    --paper: #ffffff;
    --cream: #fafaf8;
    --soft: #f6f6f3;
    --wa: #1a7f45;
    --wa-dark: #146637;
    --radius: 10px;
    --serif: Georgia, "Iowan Old Style", "Times New Roman", serif;
    --sans: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

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

html { scroll-behavior: smooth; scroll-padding-top: 88px; }

body {
    font-family: var(--sans);
    font-size: 1.0625rem;
    line-height: 1.65;
    color: var(--ink);
    background: var(--paper);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { color: var(--brand); }
a:focus-visible, button:focus-visible, summary:focus-visible,
input:focus-visible, select:focus-visible {
    outline: 3px solid var(--brand);
    outline-offset: 2px;
}

h1, h2, h3 { font-family: var(--serif); font-weight: 700; line-height: 1.2; color: var(--ink); }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.25rem); letter-spacing: -0.01em; }
h3 { font-size: 1.25rem; }
p + p { margin-top: 0.9em; }

.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 20px; }

.eyebrow {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--brand);
    margin-bottom: 12px;
}

/* ---------- Botones ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 48px;
    padding: 12px 22px;
    border-radius: var(--radius);
    border: 1px solid transparent;
    font: 600 1rem var(--sans);
    text-decoration: none;
    cursor: pointer;
    transition: background-color .2s, border-color .2s, color .2s;
}
.btn svg { width: 20px; height: 20px; fill: currentColor; flex-shrink: 0; }
.btn-wa { background: var(--wa); color: #fff; }
.btn-wa:hover { background: var(--wa-dark); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-block { width: 100%; }

/* ---------- Cabecera (fondo crema #fafaf8 para fundir el logo) ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: var(--cream);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 2px 10px rgba(15, 31, 56, 0.04);
}
.header-row { display: flex; align-items: center; justify-content: space-between; height: 80px; gap: 16px; }
.brand { display: flex; align-items: center; text-decoration: none; }
.brand img { height: 64px; width: auto; object-fit: contain; }

.menu { display: flex; align-items: center; gap: 28px; }
.menu a { color: var(--ink-soft); font-weight: 500; font-size: 0.98rem; text-decoration: none; }
.menu a:hover { color: var(--ink); }
.menu .menu-cta {
    color: var(--paper);
    background: var(--ink);
    padding: 9px 16px;
    border-radius: var(--radius);
}
.menu .menu-cta:hover { background: var(--brand-dark); color: var(--paper); }

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--paper);
    cursor: pointer;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
}
.menu-toggle span { width: 18px; height: 2px; background: var(--ink); border-radius: 2px; transition: transform .2s, opacity .2s; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Portada ---------- */
.hero { padding: 72px 0 80px; border-bottom: 1px solid var(--line); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 64px; align-items: center; }
.hero h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); letter-spacing: -0.02em; margin-bottom: 20px; }
.lead { font-size: 1.15rem; color: var(--ink-soft); max-width: 36em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero-note { margin-top: 16px; font-size: 0.92rem; color: var(--ink-soft); }

.hero-card {
    background: var(--soft);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 32px;
}
.card-kicker { font-family: var(--sans); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 20px; }

.steps { list-style: none; counter-reset: paso; display: grid; gap: 22px; }
.steps li { counter-increment: paso; display: grid; grid-template-columns: 36px minmax(0, 1fr); column-gap: 14px; }
.steps li::before {
    content: counter(paso);
    grid-row: span 2;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1.5px solid var(--brand);
    color: var(--brand);
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}
.steps strong { font-size: 1.02rem; }
.steps span { color: var(--ink-soft); font-size: 0.97rem; }

/* ---------- Secciones ---------- */
.section { padding: 88px 0; }
.section-soft { background: var(--soft); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { max-width: 680px; margin-bottom: 44px; }
.section-lead { margin-top: 12px; font-size: 1.08rem; color: var(--ink-soft); }

/* Programas (cuadrícula 2x2 de las 4 líneas académicas) */
.programs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.program {
    min-width: 0;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 32px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 24px;
    transition: transform .2s, box-shadow .2s, border-color .2s;
}
.program:hover {
    transform: translateY(-3px);
    border-color: #cbd5e1;
    box-shadow: 0 12px 28px rgba(15, 31, 56, 0.07);
}
.program-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: var(--brand-tint);
    color: var(--brand);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 18px;
}
.program-icon svg {
    width: 24px;
    height: 24px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.program h3 { margin-bottom: 10px; font-size: 1.3rem; }
.program p { color: var(--ink-soft); }
.program-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding-top: 18px;
    border-top: 1px solid var(--line);
    font-weight: 700;
    font-size: 0.98rem;
    color: var(--brand);
    text-decoration: none;
    overflow-wrap: anywhere;
}
.program-link::after { content: "→"; transition: transform .2s; }
.program-link:hover { color: var(--brand-dark); }
.program-link:hover::after { transform: translateX(4px); }

/* Compromisos */
.promises { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; }
.promise { min-width: 0; }
.promise svg {
    width: 28px;
    height: 28px;
    fill: none;
    stroke: var(--brand);
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
    margin-bottom: 16px;
}
.promise h3 { font-size: 1.15rem; margin-bottom: 8px; }
.promise p { color: var(--ink-soft); font-size: 1rem; }

/* Nosotros */
.about-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 64px; align-items: start; }
.about-grid h2 { margin-bottom: 20px; }
.about-grid p { color: var(--ink-soft); }
.team { display: grid; gap: 0; border-top: 1px solid var(--line); }
.team div { padding: 20px 0; border-bottom: 1px solid var(--line); }
.team dt { font-family: var(--serif); font-weight: 700; font-size: 1.15rem; }
.team dd { color: var(--ink-soft); font-size: 0.98rem; }

/* Preguntas */
.faq-wrap { max-width: 820px; }
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
    list-style: none;
    cursor: pointer;
    padding: 20px 40px 20px 0;
    font-weight: 600;
    font-size: 1.05rem;
    position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
    content: "+";
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.4rem;
    font-weight: 400;
    color: var(--brand);
}
.faq details[open] summary::after { content: "−"; }
.faq details p { padding: 0 40px 22px 0; color: var(--ink-soft); }

/* Contacto */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; align-items: start; }
.contact-grid h2 { margin-bottom: 16px; }
.contact-grid > div > p { color: var(--ink-soft); }
.channels { list-style: none; margin-top: 28px; display: grid; gap: 16px; }
.channels li { display: grid; min-width: 0; }
.channels span { font-size: 0.85rem; color: var(--ink-soft); }
.channels a { font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }

.contact-card {
    min-width: 0;
    background: var(--soft);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 32px;
    display: grid;
    gap: 8px;
}
.contact-card label { font-weight: 600; font-size: 0.95rem; margin-top: 8px; }
.contact-card input,
.contact-card select {
    width: 100%;
    min-height: 48px;
    padding: 10px 14px;
    border: 1px solid #cfd4da;
    border-radius: var(--radius);
    background: var(--paper);
    font: 1rem var(--sans);
    color: var(--ink);
}
.contact-card .btn { margin-top: 16px; }
.form-error { color: #b42318; font-size: 0.92rem; }

/* ---------- Pie ---------- */
.site-footer { background: var(--ink); color: #c9d1dc; padding: 56px 0 24px; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr); gap: 40px; }
.footer-logo { height: 50px; width: auto; background: var(--cream); padding: 6px 12px; border-radius: 10px; margin-bottom: 14px; }
.footer-title { font-family: var(--sans); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: #fff; margin-bottom: 14px; }
.site-footer ul { list-style: none; display: grid; gap: 8px; }
.site-footer a { color: #c9d1dc; text-decoration: none; overflow-wrap: anywhere; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-base { margin-top: 40px; padding-top: 20px; border-top: 1px solid rgba(255, 255, 255, 0.12); font-size: 0.9rem; }

/* ---------- WhatsApp flotante ---------- */
.wa-float {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 40;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--wa);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 18px rgba(15, 31, 56, 0.22);
}
.wa-float:hover { background: var(--wa-dark); }
.wa-float svg { width: 28px; height: 28px; fill: currentColor; }

/* ---------- Tableta y teléfono ---------- */
@media (max-width: 900px) {
    .menu-toggle { display: flex; }
    .menu {
        display: none;
        position: absolute;
        top: 80px;
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        background: var(--cream);
        border-bottom: 1px solid var(--line);
        padding: 8px 20px 20px;
        box-shadow: 0 12px 24px rgba(15, 31, 56, 0.08);
    }
    .menu.is-open { display: flex; }
    .menu a { padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 1.05rem; }
    .menu .menu-cta { margin-top: 16px; text-align: center; border-bottom: 0; }

    .hero-grid, .about-grid, .contact-grid { grid-template-columns: minmax(0, 1fr); gap: 40px; }
    .programs { grid-template-columns: minmax(0, 1fr); }
    .promises { grid-template-columns: minmax(0, 1fr); gap: 32px; }
    .footer-grid { grid-template-columns: minmax(0, 1fr); gap: 32px; }
}

@media (max-width: 560px) {
    body { font-size: 1rem; }
    .header-row { height: 70px; }
    .brand img { height: 48px; }
    .menu { top: 70px; }
    .hero { padding: 44px 0 56px; }
    .section { padding: 64px 0; }
    .hero-actions .btn { width: 100%; }
    .hero-card, .program, .contact-card { padding: 24px; }
    .wa-float { right: 16px; bottom: 16px; width: 52px; height: 52px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    * { transition: none !important; }
}
