/* ===== EduConecta · base compartida por todas las páginas ===== */
@font-face { font-family: 'Ezra'; src: url('/fonts/ezra-medium.woff2') format('woff2'); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: 'Ezra'; src: url('/fonts/ezra-semibold.woff2') format('woff2'); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: 'Ezra'; src: url('/fonts/ezra-bold.woff2') format('woff2'); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: 'Ezra'; src: url('/fonts/ezra-extrabold.woff2') format('woff2'); font-weight: 800; font-style: normal; font-display: swap; }
@font-face { font-family: 'Ezra'; src: url('/fonts/ezra-semibolditalic.woff2') format('woff2'); font-weight: 600; font-style: italic; font-display: swap; }
@font-face { font-family: 'Ezra'; src: url('/fonts/ezra-bolditalic.woff2') format('woff2'); font-weight: 700; font-style: italic; font-display: swap; }
@font-face { font-family: 'Ezra'; src: url('/fonts/ezra-extrabolditalic.woff2') format('woff2'); font-weight: 800; font-style: italic; font-display: swap; }
:root {
  --navy: #172643; --indigo: #3E43AF; --steel: #B6C9DA; --lavender: #D7E3FF; --lime: #B5E24C;
  --cream: #F4F0E8; --ink: #172643; --muted: #5A6480; --line: #E4E2DA; --white: #fff;
  --font: 'Montserrat', system-ui, sans-serif;
  --font-display: 'Ezra', 'Montserrat', system-ui, sans-serif;
  --font-accent: 'Ezra', 'Montserrat', system-ui, sans-serif;
  --radius: 26px; --ease: cubic-bezier(.2, .8, .2, 1); --shadow: 0 18px 50px rgba(23, 38, 67, .10);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body { font-family: var(--font); color: var(--ink); background: var(--cream); line-height: 1.65; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; }
button { font-family: inherit; cursor: pointer; }
[hidden] { display: none !important; }
.wrap { width: min(1160px, 100% - 40px); margin-inline: auto; }
.narrow { width: min(820px, 100% - 40px); margin-inline: auto; }
section { position: relative; padding: clamp(72px, 10vw, 120px) 0; }
h1, h2, h3, .display { font-family: var(--font-display); }
h1, h2, h3 { line-height: 1.12; letter-spacing: -.015em; font-weight: 800; }
h1 { font-size: clamp(34px, 5.6vw, 64px); }
h2 { font-size: clamp(28px, 4vw, 46px); }
h3 { font-size: clamp(19px, 2vw, 22px); font-weight: 700; }
.accent { font-family: var(--font-accent); font-style: italic; font-weight: 700; }
.mark { background: linear-gradient(transparent 62%, rgba(181, 226, 76, .75) 62%); padding: 0 .08em; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: 12.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--indigo); }
.eyebrow::before { content: ""; width: 26px; height: 2px; background: currentColor; border-radius: 2px; }
.lead { font-size: clamp(17px, 1.8vw, 20px); color: var(--muted); max-width: 680px; }
.center { text-align: center; }
.center .lead { margin-inline: auto; }
.muted { color: var(--muted); }
.stack-text > * + * { margin-top: 16px; }

/* Botones */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 54px; padding: 15px 28px; border-radius: 999px; font-weight: 700; font-size: 15.5px; text-decoration: none; border: 0; text-align: center; transition: transform .2s var(--ease), box-shadow .25s, background .2s, color .2s; }
.btn:hover { transform: translateY(-2px); }
.btn-lime { background: var(--lime); color: var(--navy); box-shadow: 0 10px 30px rgba(181, 226, 76, .45); }
.btn-navy { background: var(--navy); color: #fff; box-shadow: 0 10px 30px rgba(23, 38, 67, .25); }
.btn-indigo { background: var(--indigo); color: #fff; box-shadow: 0 10px 30px rgba(62, 67, 175, .3); }
.btn-ghost { background: transparent; color: inherit; border: 2px solid currentColor; }
.btns { display: flex; flex-wrap: wrap; gap: 12px; }
.center .btns { justify-content: center; }
.link-arrow { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; color: var(--indigo); text-decoration: none; }
.link-arrow::after { content: "→"; transition: transform .2s var(--ease); }
.link-arrow:hover::after { transform: translateX(4px); }

/* Header y menú (igual en todas las páginas) */
.header { position: fixed; inset: 0 0 auto; z-index: 50; transition: background .3s, box-shadow .3s, padding .3s; padding: 18px 0; }
.header.scrolled { background: rgba(244, 240, 232, .92); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); box-shadow: 0 1px 0 var(--line); padding: 10px 0; }
.header .wrap { display: flex; align-items: center; gap: 24px; }
.header .logo img { height: 38px; width: auto; }
.header nav { display: flex; gap: 4px; margin-left: auto; align-items: center; }
.header nav a { white-space: nowrap; font-size: 14px; font-weight: 700; text-decoration: none; padding: 8px 14px; border-radius: 999px; opacity: .82; transition: opacity .2s, background .2s; }
.header nav a:hover { opacity: 1; background: rgba(23, 38, 67, .06); }
.header nav a[aria-current="page"] { opacity: 1; background: var(--navy); color: #fff; }
.header .btn { min-height: 44px; padding: 10px 20px; font-size: 14px; }
.menu-btn { display: none; margin-left: auto; width: 44px; height: 44px; border-radius: 12px; border: 0; background: var(--navy); color: #fff; }
@media (max-width: 1100px) {
  .header nav { position: fixed; inset: 64px 12px auto; flex-direction: column; align-items: stretch; gap: 2px; background: #fff; border-radius: 20px; padding: 10px; box-shadow: var(--shadow); display: none; }
  .header nav.open { display: flex; }
  .header nav a { padding: 14px 16px; opacity: 1; border-radius: 12px; }
  .header .btn.hide-sm { display: none; }
  .menu-btn { display: grid; place-items: center; }
}

/* Foto con forma de arco (marca) */
.arch { border-radius: 220px 220px var(--radius) var(--radius); overflow: hidden; box-shadow: var(--shadow); background: var(--steel); }
.arch img { width: 100%; height: 100%; object-fit: cover; }
.photo-cap { margin-top: 14px; font-family: var(--font-display); font-weight: 700; color: var(--indigo); text-align: center; }

/* Indicadores */
.stats3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.stat3 { border-top: 4px solid var(--lime); padding-top: 18px; }
.stat3 b { display: block; font-family: var(--font-display); font-size: clamp(38px, 4.6vw, 56px); font-weight: 800; line-height: 1; color: var(--indigo); margin-bottom: 10px; }
.stat3 span { color: var(--muted); font-weight: 600; }
@media (max-width: 640px) { .stats3 { grid-template-columns: 1fr; } }

/* Tarjetas */
.card { background: #fff; border-radius: var(--radius); padding: clamp(24px, 3vw, 34px); box-shadow: 0 4px 16px rgba(23,38,67,.05); }

/* Pie de página */
footer { background: #0e1a31; color: rgba(255,255,255,.65); padding: 50px 0 36px; font-size: 14px; }
footer .wrap { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 30px; }
footer img { height: 34px; filter: brightness(0) invert(1); margin-bottom: 14px; }
footer h4 { color: #fff; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; margin-bottom: 12px; }
footer a { display: block; text-decoration: none; padding: 4px 0; }
footer a:hover { color: var(--lime); }
footer .legal { grid-column: 1 / -1; border-top: 1px solid rgba(255,255,255,.1); padding-top: 20px; font-size: 12.5px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }
@media (max-width: 760px) { footer .wrap { grid-template-columns: 1fr; } }

.wa-float { position: fixed; right: 18px; bottom: 18px; z-index: 40; width: 58px; height: 58px; border-radius: 50%; background: #25d366; display: grid; place-items: center; box-shadow: 0 10px 30px rgba(0,0,0,.22); transition: transform .2s; }
.wa-float:hover { transform: scale(1.07); }
.wa-float svg { width: 30px; height: 30px; fill: #fff; }

/* Revelado al scrollear */
.rv { opacity: 0; transform: translateY(30px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.rv.in { opacity: 1; transform: none; }
.rv.d1 { transition-delay: .08s; } .rv.d2 { transition-delay: .16s; } .rv.d3 { transition-delay: .24s; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .rv { opacity: 1; transform: none; }
}

/* ===== Modo edición (?editar) ===== */
body.editing [data-edit] { outline: 2px dashed rgba(62,67,175,.45); outline-offset: 4px; border-radius: 4px; cursor: text; }
body.editing [data-edit]:hover { outline-color: var(--indigo); background: rgba(215,227,255,.25); }
body.editing [data-edit]:focus { outline: 2px solid var(--indigo); background: rgba(215,227,255,.35); }
body.editing [data-edit].changed { outline-color: #e79b10; }
body.editing .rv { opacity: 1; transform: none; }
.edit-bar { position: fixed; top: 12px; left: 50%; transform: translateX(-50%); z-index: 100; background: var(--navy); color: #fff; border-radius: 999px; padding: 8px 8px 8px 18px; display: flex; align-items: center; gap: 12px; box-shadow: 0 16px 40px rgba(0,0,0,.3); font-size: 13.5px; font-weight: 600; white-space: nowrap; }
.edit-bar button { border: 0; border-radius: 999px; padding: 9px 16px; font-weight: 700; font-size: 13px; }
.edit-bar .save { background: var(--lime); color: var(--navy); }
.edit-bar .exit { background: rgba(255,255,255,.12); color: #fff; }
.edit-bar .n { color: var(--lime); }
body.editing .header { top: 64px; }
.login-card { position: fixed; inset: 0; z-index: 110; background: rgba(15,22,40,.6); backdrop-filter: blur(6px); display: grid; place-items: center; padding: 20px; }
.login-card form { background: #fff; border-radius: 26px; padding: 30px; width: min(420px, 100%); display: grid; gap: 14px; }
.login-card input { font: inherit; padding: 14px 16px; border: 2px solid var(--line); border-radius: 14px; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 140px); background: var(--navy); color: #fff; padding: 12px 20px; border-radius: 999px; font-weight: 600; font-size: 14px; z-index: 120; transition: transform .35s var(--ease); }
.toast.show { transform: translate(-50%, 0); }
