/* ==========================================================================
   OLA · Sitio público
   Requiere tokens.css. Mobile-first; puntos de interrupción: 600 / 860 / 1080 / 1280 px.
   ========================================================================== */

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
main { flex: 1; display: block; }
img, svg, video { max-width: 100%; height: auto; }
img { display: block; }
[hidden] { display: none !important; }
h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--navy-900);
  line-height: var(--lh-tight);
  letter-spacing: -0.015em;
  margin: 0 0 var(--sp-4);
  text-wrap: balance;
}
h1 { font-size: var(--fs-4xl); font-weight: 800; }
h2 { font-size: var(--fs-3xl); font-weight: 750; }
h3 { font-size: var(--fs-xl); font-weight: 700; line-height: var(--lh-snug); }
h4 { font-size: var(--fs-lg); font-weight: 700; }
p { margin: 0 0 var(--sp-4); text-wrap: pretty; }
a { color: var(--blue-600); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { color: var(--blue-700); text-decoration-thickness: 2px; }
:focus-visible { outline: none; box-shadow: var(--focus-ring); border-radius: 4px; }
::selection { background: var(--turquoise-100); color: var(--navy-900); }
hr { border: 0; border-top: 1px solid var(--line); margin: var(--sp-6) 0; }
.icon { width: 1.25em; height: 1.25em; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; vertical-align: -0.25em; }
.icon--fill { fill: currentColor; stroke: none; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: var(--sp-4); top: -100px; z-index: 100;
  background: var(--navy-900); color: #fff; padding: var(--sp-3) var(--sp-4);
  border-radius: var(--radius); font-weight: 600; text-decoration: none;
}
.skip-link:focus { top: var(--sp-3); color: #fff; }

.container { width: 100%; max-width: calc(var(--container) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.container--narrow { max-width: calc(var(--container-narrow) + 2 * var(--gutter)); }

/* ---------- Botones ---------- */
.btn {
  --btn-bg: var(--blue-600); --btn-fg: #fff; --btn-bd: var(--btn-bg);
  display: inline-flex; align-items: center; justify-content: center; gap: 0.55em;
  min-height: 48px; padding: 0.7em 1.35em;
  font: 600 var(--fs-sm)/1.2 var(--font-body); letter-spacing: 0.005em;
  color: var(--btn-fg); background: var(--btn-bg); border: 1.5px solid var(--btn-bd);
  border-radius: var(--radius-pill); text-decoration: none; cursor: pointer;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease), border-color var(--dur) var(--ease), transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.btn:hover { --btn-bg: var(--blue-700); color: var(--btn-fg); text-decoration: none; box-shadow: var(--shadow); }
.btn:active { transform: translateY(1px); }
.btn--secondary { --btn-bg: transparent; --btn-fg: var(--blue-700); --btn-bd: var(--line-strong); }
.btn--secondary:hover { --btn-bg: var(--blue-50); --btn-fg: var(--blue-700); --btn-bd: var(--blue-600); }
.btn--light { --btn-bg: #fff; --btn-fg: var(--navy-900); --btn-bd: #fff; }
.btn--light:hover { --btn-bg: var(--turquoise-50); --btn-fg: var(--navy-900); }
.btn--ghost-light { --btn-bg: transparent; --btn-fg: #fff; --btn-bd: rgba(255,255,255,0.55); }
.btn--ghost-light:hover { --btn-bg: rgba(255,255,255,0.12); --btn-fg: #fff; --btn-bd: #fff; }
.btn--sm { min-height: 40px; padding: 0.5em 1em; font-size: var(--fs-xs); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.6; pointer-events: none; }
.btn .icon { width: 1.1em; height: 1.1em; }

.link-arrow { display: inline-flex; align-items: center; gap: 0.4em; font-weight: 600; text-decoration: none; color: var(--blue-600); }
.link-arrow .icon { transition: transform var(--dur) var(--ease); }
.link-arrow:hover .icon { transform: translateX(3px); }
.link-arrow:hover { text-decoration: underline; }

/* ---------- Encabezado ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  /* Sin backdrop-filter: crearía un bloque contenedor que atraparía el menú móvil fijo. */
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease);
}
.site-header.is-scrolled { border-color: var(--line); box-shadow: var(--shadow-xs); }
.site-header__bar { display: flex; align-items: center; gap: var(--sp-5); min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: var(--sp-3); text-decoration: none; color: var(--navy-800); margin-right: auto; }
.brand:hover { text-decoration: none; color: var(--navy-800); }
.brand__mark { width: auto; height: 52px; }
.brand__text { display: flex; flex-direction: column; line-height: 1.12; font-family: var(--font-display); }
.brand__name { font-size: 0.82rem; font-weight: 700; max-width: 15.5rem; color: var(--navy-800); letter-spacing: -0.005em; }
.brand__tag { font-size: 0.7rem; font-weight: 600; color: var(--turquoise-700); letter-spacing: 0.08em; text-transform: uppercase; margin-top: 3px; }
@media (max-width: 420px) { .brand__text { display: none; } }

.nav { display: none; }
.nav__list { list-style: none; display: flex; align-items: center; gap: 0.15rem; margin: 0; padding: 0; }
.nav__link {
  position: relative; display: inline-flex; align-items: center; min-height: 44px; padding: 0 0.7rem;
  color: var(--ink-soft); font-weight: 550; font-size: 0.95rem; text-decoration: none; border-radius: var(--radius-sm);
}
.nav__link:hover { color: var(--navy-900); text-decoration: none; background: var(--surface-alt); }
.nav__link[aria-current="page"] { color: var(--navy-900); }
.nav__link[aria-current="page"]::after {
  content: ""; position: absolute; left: 0.7rem; right: 0.7rem; bottom: 6px; height: 2.5px;
  border-radius: 2px; background: var(--brand-gradient);
}
.header-cta { display: none; }
.menu-toggle {
  display: inline-flex; align-items: center; gap: var(--sp-2); min-height: 44px; padding: 0 0.9rem;
  background: var(--surface); color: var(--navy-900); border: 1.5px solid var(--line-strong);
  border-radius: var(--radius-pill); font: 600 var(--fs-sm) var(--font-body); cursor: pointer;
}
.menu-toggle .icon-close { display: none; }
.menu-toggle[aria-expanded="true"] .icon-open { display: none; }
.menu-toggle[aria-expanded="true"] .icon-close { display: block; }

/* Menú móvil */
.mobile-nav {
  position: fixed; inset: var(--header-h) 0 0 0; z-index: 49;
  background: var(--surface); overflow-y: auto; padding: var(--sp-5) var(--gutter) var(--sp-7);
  border-top: 1px solid var(--line);
}
.mobile-nav[hidden] { display: none; }
.mobile-nav ul { list-style: none; margin: 0 0 var(--sp-5); padding: 0; }
.mobile-nav a.mobile-nav__link {
  display: flex; align-items: center; justify-content: space-between; min-height: 56px;
  font: 650 1.125rem var(--font-display); color: var(--navy-900); text-decoration: none;
  border-bottom: 1px solid var(--line);
}
.mobile-nav a.mobile-nav__link[aria-current="page"] { color: var(--blue-600); }
.mobile-nav .btn { width: 100%; }
body.nav-open { overflow: hidden; }

@media (min-width: 1140px) {
  .nav { display: block; }
  .header-cta { display: inline-flex; }
  .menu-toggle, .mobile-nav { display: none !important; }
}
@media (min-width: 1140px) and (max-width: 1260px) {
  .brand__text { display: none; }
}

/* ---------- Secciones genéricas ---------- */
.section { padding-block: var(--section-y); }
.section--alt { background: var(--surface-alt); }
.section--tint { background: linear-gradient(180deg, var(--blue-50), #fff); }
.section__head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: var(--sp-4) var(--sp-6); margin-bottom: var(--sp-6); }
.section__head h2 { margin: 0; }
.section__head p { margin: var(--sp-2) 0 0; color: var(--ink-soft); max-width: 60ch; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 0.6em; margin-bottom: var(--sp-3);
  font: 700 var(--fs-xs)/1.2 var(--font-body); letter-spacing: 0.12em; text-transform: uppercase; color: var(--turquoise-700);
}
.eyebrow::before { content: ""; width: 28px; height: 2px; border-radius: 2px; background: var(--brand-gradient); }
.lead { font-size: var(--fs-lg); color: var(--ink-soft); line-height: 1.6; max-width: 62ch; }

/* Encabezado de página interior */
.page-hero {
  position: relative; overflow: hidden;
  padding: clamp(3rem, 2rem + 4vw, 5.5rem) 0 clamp(2.5rem, 1.5rem + 3vw, 4rem);
  background:
    radial-gradient(60% 120% at 100% 0%, rgba(5, 164, 195, 0.10), transparent 60%),
    radial-gradient(50% 120% at 0% 100%, rgba(0, 79, 166, 0.07), transparent 60%),
    linear-gradient(180deg, var(--blue-50), #fff);
  border-bottom: 1px solid var(--line);
}
.page-hero h1 { font-size: var(--fs-3xl); margin-bottom: var(--sp-3); max-width: 22ch; }
.page-hero .lead { margin: 0; }
.page-hero__pattern { position: absolute; right: -60px; top: -40px; width: min(520px, 60vw); opacity: 0.55; pointer-events: none; color: var(--turquoise-500); }
.breadcrumbs { font-size: var(--fs-xs); color: var(--muted); margin-bottom: var(--sp-4); }
.breadcrumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 0.4em; margin: 0; padding: 0; }
.breadcrumbs li + li::before { content: "/"; margin-right: 0.4em; color: var(--line-strong); }
.breadcrumbs a { color: var(--muted); }

/* ---------- Portada ---------- */
.hero {
  position: relative; overflow: hidden; isolation: isolate;
  padding: clamp(2.5rem, 1rem + 5vw, 5.5rem) 0 clamp(3rem, 1.5rem + 5vw, 6rem);
  background:
    radial-gradient(55% 70% at 85% 35%, rgba(5, 164, 195, 0.13), transparent 70%),
    radial-gradient(45% 60% at 10% 90%, rgba(0, 79, 166, 0.08), transparent 70%),
    linear-gradient(180deg, #f7fbfe 0%, #fff 100%);
}
.hero__grid { display: grid; gap: var(--sp-7); align-items: center; }
.hero__eyebrow { color: var(--turquoise-700); }
.hero h1 { font-size: var(--fs-4xl); max-width: 16ch; margin-bottom: var(--sp-5); }
.hero h1 .accent { background: var(--brand-gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero__text .lead { margin-bottom: var(--sp-6); }
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--sp-3); }
.hero__visual { position: relative; display: grid; place-items: center; justify-self: center; width: min(100%, 440px); aspect-ratio: 1; }
.hero__seal { position: relative; z-index: 2; width: 78%; filter: drop-shadow(0 22px 40px rgba(0, 63, 143, 0.18)); }
.hero__orbit { position: absolute; inset: 0; z-index: 1; color: var(--turquoise-500); }
.hero__orbit circle { fill: none; stroke: currentColor; }
.hero__lines { position: absolute; inset: 0; z-index: -1; color: var(--blue-500); opacity: 0.6; pointer-events: none; }
@media (min-width: 860px) {
  .hero__grid { grid-template-columns: 1.15fr 0.85fr; }
  .hero__visual { justify-self: end; }
}
@media (prefers-reduced-motion: no-preference) {
  .js .hero__seal { animation: seal-in 1.1s var(--ease) both; }
  .js .hero__orbit .orbit-a { transform-origin: 50% 50%; animation: orbit-draw 1.6s var(--ease) 0.15s both; }
  .js .hero__orbit .orbit-b { transform-origin: 50% 50%; animation: orbit-draw 1.9s var(--ease) 0.3s both; }
  .js .hero__text > * { animation: rise 0.8s var(--ease) both; }
  .js .hero__text > *:nth-child(2) { animation-delay: 0.08s; }
  .js .hero__text > *:nth-child(3) { animation-delay: 0.16s; }
  .js .hero__text > *:nth-child(4) { animation-delay: 0.24s; }
}
@keyframes seal-in { from { opacity: 0; transform: scale(0.94); } to { opacity: 1; transform: none; } }
@keyframes orbit-draw { from { stroke-dashoffset: 1; opacity: 0; } to { stroke-dashoffset: 0; opacity: 1; } }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* Accesos rápidos */
.quick-grid { display: grid; gap: var(--sp-4); grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); }
.quick-card {
  position: relative; display: flex; flex-direction: column; gap: var(--sp-3); padding: var(--sp-5);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  text-decoration: none; color: var(--ink); box-shadow: var(--shadow-xs);
  transition: border-color var(--dur) var(--ease), box-shadow var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.quick-card:hover { color: var(--ink); text-decoration: none; border-color: var(--turquoise-500); box-shadow: var(--shadow); transform: translateY(-2px); }
.quick-card__icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 12px; color: var(--blue-600); background: linear-gradient(135deg, var(--turquoise-50), var(--blue-100)); }
.quick-card__icon .icon { width: 24px; height: 24px; }
.quick-card h3 { margin: 0; font-size: 1.125rem; }
.quick-card p { margin: 0; color: var(--ink-soft); font-size: var(--fs-sm); line-height: 1.55; }
.quick-card .link-arrow { margin-top: auto; font-size: var(--fs-sm); }

/* Presentación */
.intro-block { display: grid; gap: var(--sp-6); align-items: start; }
@media (min-width: 860px) { .intro-block { grid-template-columns: 0.8fr 1.2fr; gap: var(--sp-8); } }
.intro-block__aside { position: relative; }
.intro-block__aside .mark-line { width: 64px; height: 4px; border-radius: 2px; background: var(--brand-gradient); margin-top: var(--sp-5); }

/* ---------- Tarjetas de contenido ---------- */
.card-grid { display: grid; gap: var(--sp-5); grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
.card {
  position: relative; display: flex; flex-direction: column; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs); transition: box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.card:hover { box-shadow: var(--shadow); border-color: var(--line-strong); transform: translateY(-2px); }
.card__media { aspect-ratio: 16 / 9; background: var(--surface-tint); overflow: hidden; }
.card__media img { width: 100%; height: 100%; object-fit: cover; }
/* Imagen completa (sin recortes) sobre un fondo difuminado de la misma imagen (--media-bg). */
.media-fit { position: relative; overflow: hidden; isolation: isolate; background: var(--surface-tint); }
.media-fit::before {
  content: ""; position: absolute; inset: -24px; z-index: -1;
  background: var(--media-bg, none) center / cover no-repeat; filter: blur(20px) saturate(1.15); opacity: 0.6;
}
.media-fit img { position: relative; width: 100%; height: 100%; object-fit: contain; }
.card__media--placeholder { display: grid; place-items: center; background: linear-gradient(135deg, var(--turquoise-50), var(--blue-100)); color: var(--blue-600); }
.card__media--placeholder img { width: 84px; height: auto; object-fit: contain; opacity: 0.9; }
.card__body { display: flex; flex-direction: column; gap: var(--sp-2); padding: var(--sp-5); flex: 1; }
.card__meta { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2) var(--sp-3); font-size: var(--fs-xs); color: var(--muted); }
.card__title { font-size: 1.15rem; margin: 0; }
.card__title a { color: var(--navy-900); text-decoration: none; }
.card__title a::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.card__title a:hover { color: var(--blue-600); }
.card__title a:focus-visible { box-shadow: none; }
.card:has(.card__title a:focus-visible) { box-shadow: var(--focus-ring); }
.card__excerpt { margin: 0; color: var(--ink-soft); font-size: var(--fs-sm); line-height: 1.6; }
.card__footer { margin-top: auto; padding-top: var(--sp-3); font-size: var(--fs-xs); color: var(--muted); }

.badge {
  display: inline-flex; align-items: center; gap: 0.35em; padding: 0.2em 0.7em;
  font: 650 0.75rem/1.5 var(--font-body); letter-spacing: 0.02em;
  border-radius: var(--radius-pill); background: var(--turquoise-50); color: var(--turquoise-700); border: 1px solid var(--turquoise-100);
}
.badge--blue { background: var(--blue-50); color: var(--blue-700); border-color: var(--blue-100); }
.badge--muted { background: var(--surface-alt); color: var(--muted); border-color: var(--line); }
.badge--danger { background: var(--danger-bg); color: var(--danger); border-color: #f7c9c4; }
.badge--warning { background: var(--warning-bg); color: var(--warning); border-color: #f3dcae; }
.badge--success { background: var(--success-bg); color: var(--success); border-color: #bfe5d2; }

/* Noticia destacada */
.feature {
  display: grid; overflow: hidden; margin-bottom: var(--sp-6);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-xl); box-shadow: var(--shadow-sm);
  position: relative;
}
.feature__media { aspect-ratio: 16 / 9; background: var(--surface-tint); overflow: hidden; }
.feature__media img { width: 100%; height: 100%; object-fit: cover; }
.feature__body { padding: clamp(1.5rem, 1rem + 2vw, 2.75rem); display: flex; flex-direction: column; gap: var(--sp-3); justify-content: center; }
.feature__body h2 { font-size: var(--fs-2xl); margin: 0; }
.feature__body h2 a { color: var(--navy-900); text-decoration: none; }
.feature__body h2 a::after { content: ""; position: absolute; inset: 0; }
.feature__body h2 a:hover { color: var(--blue-600); }
@media (min-width: 860px) { .feature { grid-template-columns: 1.2fr 1fr; } .feature__media { aspect-ratio: auto; min-height: 340px; } }

/* Eventos */
.tz-list { list-style: none; margin: var(--sp-1) 0 0; padding: 0; display: grid; gap: var(--sp-2); }
.tz-list li { display: grid; grid-template-columns: 20px 1fr; align-items: center; column-gap: var(--sp-2); font-size: var(--fs-sm); line-height: 1.35; }
.tz-list img { grid-row: 1; width: 20px; height: 15px; object-fit: cover; border-radius: 2px; box-shadow: 0 0 0 1px rgb(8 35 74 / 0.12); }
.tz-list__country { grid-column: 2; color: var(--ink-soft); }
.tz-list__time { grid-column: 2; font-weight: 650; color: var(--navy-900); }
.tz-list__time small { font-weight: 400; color: var(--muted); }
.event-list { display: grid; gap: var(--sp-4); }
.event-item {
  position: relative; display: grid; grid-template-columns: auto 1fr; gap: var(--sp-4) var(--sp-5); align-items: start;
  padding: var(--sp-5); background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xs); transition: box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.event-item:hover { box-shadow: var(--shadow); border-color: var(--line-strong); }
.event-item:has(a:focus-visible) { box-shadow: var(--focus-ring); }
.event-item h3 { margin: 0 0 var(--sp-2); font-size: 1.15rem; }
.event-item h3 a { color: var(--navy-900); text-decoration: none; }
.event-item h3 a::after { content: ""; position: absolute; inset: 0; }
.event-item h3 a:hover { color: var(--blue-600); }
.event-item h3 a:focus-visible { box-shadow: none; }
.event-item p { margin: 0; color: var(--ink-soft); font-size: var(--fs-sm); }
.date-tile {
  display: grid; place-items: center; width: 72px; padding: var(--sp-2) 0; text-align: center;
  border-radius: var(--radius); color: #fff; background: linear-gradient(160deg, var(--turquoise-600), var(--blue-600));
  font-family: var(--font-display); line-height: 1.05;
}
.date-tile__day { font-size: 1.75rem; font-weight: 800; }
.date-tile__month { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; }
.date-tile__year { font-size: 0.7rem; opacity: 0.85; }
.date-tile--past { background: var(--surface-tint); color: var(--ink-soft); }
.meta-row { display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-4); margin-top: var(--sp-2); font-size: var(--fs-xs); color: var(--muted); }
.meta-row span { display: inline-flex; align-items: center; gap: 0.35em; }
.event-item:has(.event-item__thumb) { grid-template-columns: auto 1fr 168px; }
.event-item__thumb { grid-column: 3; grid-row: 1; aspect-ratio: 4 / 3; border-radius: var(--radius); border: 1px solid var(--line); }
@media (max-width: 599px) {
  .event-item:has(.event-item__thumb) { grid-template-columns: auto 1fr; }
  .event-item__thumb { grid-column: 1 / -1; grid-row: 1; aspect-ratio: 16 / 9; }
}

/* ---------- Directiva ---------- */
.board-body + .board-body { margin-top: var(--sp-8); }
.board-body > h2 { margin: 0 0 var(--sp-5); font-size: var(--fs-2xl); }
.board-grid { display: grid; gap: var(--sp-5); grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); }
.member {
  display: flex; flex-direction: column; text-align: center; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-xs);
}
.member__photo { position: relative; aspect-ratio: 4 / 4.4; background: linear-gradient(160deg, var(--turquoise-50), var(--blue-100)); }
.member__photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 22%; }
.member__initials { position: absolute; inset: 0; display: grid; place-items: center; font: 750 3rem var(--font-display); color: var(--blue-600); letter-spacing: 0.02em; }
.member__body { padding: var(--sp-5) var(--sp-4) var(--sp-5); display: flex; flex-direction: column; gap: var(--sp-1); flex: 1; }
.member__body::before { content: ""; width: 40px; height: 3px; margin: 0 auto var(--sp-3); border-radius: 2px; background: var(--brand-gradient); }
.member__name { margin: 0; font-size: 1.1rem; }
.member__role { margin: 0; color: var(--turquoise-700); font-weight: 650; font-size: var(--fs-sm); }
.member details { margin-top: var(--sp-3); text-align: left; font-size: var(--fs-sm); color: var(--ink-soft); }
.member summary { cursor: pointer; text-align: center; color: var(--blue-600); font-weight: 600; list-style: none; min-height: 32px; }
.member summary::-webkit-details-marker { display: none; }
.member details[open] summary { margin-bottom: var(--sp-2); }
.board-period { display: inline-flex; align-items: center; gap: var(--sp-2); padding: 0.35em 1em; border-radius: var(--radius-pill); background: #fff; border: 1px solid var(--line); font-weight: 650; color: var(--navy-800); font-size: var(--fs-sm); }

/* ---------- Línea de tiempo de presidentes ---------- */
.timeline { --tl-x: 22px; position: relative; list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-4); }
.timeline::before {
  content: ""; position: absolute; top: 8px; bottom: 8px; left: var(--tl-x); width: 2px; transform: translateX(-50%);
  background: linear-gradient(180deg, var(--turquoise-500), var(--blue-600));
}
.timeline__item { position: relative; padding-left: calc(var(--tl-x) * 2 + 4px); }
.timeline__dot {
  position: absolute; left: var(--tl-x); top: 50%; width: 14px; height: 14px; transform: translate(-50%, -50%);
  border-radius: 50%; background: var(--surface); border: 3px solid var(--turquoise-600);
}
.timeline__card {
  display: flex; gap: var(--sp-4); align-items: center; padding: var(--sp-4) var(--sp-5);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-xs);
}
.timeline__avatar {
  position: relative; flex: none; display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%;
  background: linear-gradient(160deg, var(--turquoise-50), var(--blue-100)); color: var(--blue-700);
  font-family: var(--font-display); font-weight: 800; font-size: 1.05rem; box-shadow: 0 0 0 1px var(--line);
}
.timeline__avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.timeline__country img { width: 20px; height: 15px; object-fit: cover; border-radius: 2px; box-shadow: 0 0 0 1px rgb(8 35 74 / 0.12); }
.timeline__body { min-width: 0; }
.timeline__body p { margin: 0; }
.timeline__meta { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2); }
.timeline__number { font-size: var(--fs-xs); font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--turquoise-700); }
.timeline__body .timeline__period { margin-top: 2px; font-family: var(--font-display); font-weight: 800; font-size: var(--fs-lg); color: var(--navy-900); line-height: var(--lh-tight); }
.timeline__name { margin: 2px 0 0; font-size: var(--fs-base); font-weight: 650; color: var(--ink); line-height: var(--lh-snug); }
.timeline__body .timeline__country { display: inline-flex; align-items: center; gap: 0.35em; margin-top: 4px; font-size: var(--fs-sm); color: var(--muted); }
.timeline__item--current .timeline__card {
  border: 2px solid transparent; box-shadow: var(--shadow);
  background: linear-gradient(var(--surface), var(--surface)) padding-box, var(--brand-gradient) border-box;
}
.timeline__item--current .timeline__dot { width: 20px; height: 20px; border: 0; background: var(--brand-gradient); box-shadow: 0 0 0 4px var(--turquoise-100); }
.timeline__item--current .timeline__avatar { background: var(--brand-gradient); color: #fff; box-shadow: none; }
@media (min-width: 860px) {
  .timeline { --tl-x: 50%; gap: 0; }
  .timeline__item { width: 50%; padding: 0 var(--sp-6) var(--sp-3) 0; }
  .timeline__item:nth-child(even) { margin-left: 50%; padding: 0 0 var(--sp-3) var(--sp-6); }
  .timeline__item:nth-child(odd) .timeline__dot { left: 100%; }
  .timeline__item:nth-child(even) .timeline__dot { left: 0; }
  .timeline__item:nth-child(odd) .timeline__card { flex-direction: row-reverse; text-align: right; }
  .timeline__item:nth-child(odd) .timeline__meta { justify-content: flex-end; }
  .timeline__item + .timeline__item { margin-top: -3.25rem; }
}

/* ---------- Publicaciones ---------- */
.pub-card .card__media { aspect-ratio: 4 / 3; }
.pub-type { display: inline-flex; align-items: center; gap: 0.35em; font-weight: 650; color: var(--blue-700); }

/* ---------- Contenido enriquecido (Markdown) ---------- */
.prose { max-width: 72ch; color: var(--ink); }
.prose > :first-child { margin-top: 0; }
.prose h2 { font-size: var(--fs-2xl); margin-top: var(--sp-7); }
.prose h3 { margin-top: var(--sp-6); }
.prose ul, .prose ol { padding-left: 1.4em; margin: 0 0 var(--sp-4); }
.prose li { margin-bottom: var(--sp-2); }
.prose li::marker { color: var(--turquoise-600); }
.prose blockquote { margin: var(--sp-5) 0; padding: var(--sp-3) var(--sp-5); border-left: 4px solid var(--turquoise-500); background: var(--turquoise-50); border-radius: 0 var(--radius) var(--radius) 0; color: var(--navy-900); }
.prose img { border-radius: var(--radius); margin: var(--sp-5) 0; }
.prose table { width: 100%; border-collapse: collapse; margin: var(--sp-5) 0; font-size: var(--fs-sm); display: block; overflow-x: auto; }
.prose th, .prose td { border: 1px solid var(--line); padding: var(--sp-2) var(--sp-3); text-align: left; }
.prose th { background: var(--surface-alt); }
.prose code { background: var(--surface-alt); padding: 0.1em 0.35em; border-radius: 4px; font-size: 0.92em; }

/* Bloques institucionales (Nosotros) */
.about-nav { position: sticky; top: calc(var(--header-h) + 24px); align-self: start; display: none; }
.about-nav ol { list-style: none; margin: 0; padding: 0; border-left: 2px solid var(--line); }
.about-nav a { display: block; padding: 0.45em 0 0.45em 1em; margin-left: -2px; border-left: 2px solid transparent; color: var(--ink-soft); text-decoration: none; font-size: var(--fs-sm); }
.about-nav a:hover { color: var(--navy-900); border-color: var(--turquoise-500); }
.about-layout { display: grid; gap: var(--sp-7); }
@media (min-width: 1080px) { .about-layout { grid-template-columns: 220px 1fr; } .about-nav { display: block; } }
.about-section { padding-bottom: var(--sp-7); margin-bottom: var(--sp-7); border-bottom: 1px solid var(--line); scroll-margin-top: calc(var(--header-h) + 24px); }
.about-section:last-child { border-bottom: 0; }
.mv-grid { display: grid; gap: var(--sp-5); margin-bottom: var(--sp-7); }
@media (min-width: 860px) { .mv-grid { grid-template-columns: 1fr 1fr; } }
.mv-card { position: relative; padding: var(--sp-6); border-radius: var(--radius-lg); background: linear-gradient(160deg, var(--blue-50), #fff 70%); border: 1px solid var(--line); overflow: hidden; }
.mv-card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--brand-gradient); }
.mv-card h2 { font-size: var(--fs-xl); }

/* ---------- Estados vacíos y avisos ---------- */
.empty {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: var(--sp-3);
  padding: var(--sp-7) var(--sp-5); border: 1.5px dashed var(--line-strong); border-radius: var(--radius-lg); background: var(--surface-alt); color: var(--ink-soft);
}
.empty .icon { width: 36px; height: 36px; color: var(--turquoise-600); }
.empty h2, .empty h3 { font-size: 1.15rem; margin: 0; }
.empty p { margin: 0; max-width: 52ch; }

.alert { display: flex; gap: var(--sp-3); align-items: flex-start; padding: var(--sp-4) var(--sp-5); border-radius: var(--radius); border: 1px solid; margin-bottom: var(--sp-5); font-size: var(--fs-sm); }
.alert .icon { margin-top: 0.15em; }
.alert p { margin: 0; }
.alert--success { background: var(--success-bg); border-color: #bfe5d2; color: var(--success); }
.alert--error { background: var(--danger-bg); border-color: #f7c9c4; color: var(--danger); }
.alert--info { background: var(--info-bg); border-color: var(--blue-100); color: var(--blue-700); }
.alert--warning { background: var(--warning-bg); border-color: #f3dcae; color: var(--warning); }

/* ---------- Filtros y búsqueda ---------- */
.toolbar { display: flex; flex-wrap: wrap; gap: var(--sp-3); align-items: center; justify-content: space-between; margin-bottom: var(--sp-6); }
.search { display: flex; flex: 1 1 320px; max-width: 480px; position: relative; }
.search .icon { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.search input { flex: 1; min-height: 48px; padding: 0 1rem 0 2.75rem; border: 1.5px solid var(--line-strong); border-radius: var(--radius-pill) 0 0 var(--radius-pill); font: inherit; font-size: var(--fs-sm); background: #fff; color: var(--ink); }
.search input:focus { outline: none; border-color: var(--blue-600); box-shadow: 0 0 0 3px var(--blue-100); }
.search button { border-radius: 0 var(--radius-pill) var(--radius-pill) 0; min-height: 48px; }
.chips { display: flex; flex-wrap: wrap; gap: var(--sp-2); list-style: none; margin: 0; padding: 0; }
.chip { display: inline-flex; align-items: center; min-height: 40px; padding: 0 1rem; border-radius: var(--radius-pill); border: 1.5px solid var(--line); background: #fff; color: var(--ink-soft); font-size: var(--fs-sm); font-weight: 550; text-decoration: none; }
.chip:hover { border-color: var(--blue-600); color: var(--blue-700); text-decoration: none; }
.chip[aria-current="true"] { background: var(--navy-900); border-color: var(--navy-900); color: #fff; }
.results-note { font-size: var(--fs-sm); color: var(--muted); margin-bottom: var(--sp-4); }

.pagination { display: flex; justify-content: center; margin-top: var(--sp-7); }
.pagination ul { display: flex; flex-wrap: wrap; gap: var(--sp-2); list-style: none; margin: 0; padding: 0; }
.pagination a, .pagination span { display: inline-grid; place-items: center; min-width: 44px; min-height: 44px; padding: 0 0.8rem; border-radius: var(--radius); border: 1px solid var(--line); text-decoration: none; color: var(--ink-soft); font-weight: 600; font-size: var(--fs-sm); }
.pagination a:hover { border-color: var(--blue-600); color: var(--blue-700); }
.pagination [aria-current="page"] { background: var(--blue-600); border-color: var(--blue-600); color: #fff; }

/* ---------- Formularios ---------- */
.form { display: grid; gap: var(--sp-5); }
.form-row { display: grid; gap: var(--sp-5); }
@media (min-width: 600px) { .form-row--2 { grid-template-columns: 1fr 1fr; } }
.field { display: flex; flex-direction: column; gap: var(--sp-2); }
.field label, .field .label { font-weight: 600; font-size: var(--fs-sm); color: var(--navy-900); }
.field .optional { font-weight: 450; color: var(--muted); }
.field .hint { font-size: var(--fs-xs); color: var(--muted); margin: 0; }
.input, .field input[type="text"], .field input[type="email"], .field input[type="url"], .field input[type="search"], .field input[type="password"], .field select, .field textarea {
  width: 100%; min-height: 48px; padding: 0.7rem 0.9rem; font: inherit; font-size: 1rem; color: var(--ink);
  background: #fff; border: 1.5px solid var(--line-strong); border-radius: var(--radius); transition: border-color var(--dur), box-shadow var(--dur);
}
.field textarea { min-height: 150px; resize: vertical; line-height: 1.55; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: #9fb2c7; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--blue-600); box-shadow: 0 0 0 3px var(--blue-100); }
.field [aria-invalid="true"] { border-color: var(--danger); }
.field [aria-invalid="true"]:focus { box-shadow: 0 0 0 3px var(--danger-bg); }
.field-error { display: flex; gap: 0.35em; align-items: center; font-size: var(--fs-xs); font-weight: 600; color: var(--danger); margin: 0; }
.field-error:empty { display: none; }
.check { display: flex; gap: var(--sp-3); align-items: flex-start; font-size: var(--fs-sm); color: var(--ink-soft); }
.check input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--blue-600); flex: none; }
.hp-field { position: absolute !important; left: -10000px !important; width: 1px; height: 1px; overflow: hidden; }
.form-card { padding: clamp(1.25rem, 0.8rem + 2vw, 2.5rem); background: #fff; border: 1px solid var(--line); border-radius: var(--radius-xl); box-shadow: var(--shadow-sm); }
.form-note { font-size: var(--fs-xs); color: var(--muted); margin: 0; }

/* ---------- Bandas de llamada a la acción ---------- */
.cta-band {
  position: relative; overflow: hidden; isolation: isolate;
  padding: clamp(2.5rem, 1.5rem + 4vw, 4.5rem) clamp(1.5rem, 1rem + 3vw, 4rem);
  border-radius: var(--radius-xl); color: #e8f2fb;
  background: radial-gradient(70% 140% at 100% 0%, rgba(25, 195, 192, 0.35), transparent 60%), linear-gradient(120deg, var(--navy-900) 0%, var(--blue-700) 70%, #0a5fb8 100%);
}
.cta-band h2 { color: #fff; margin-bottom: var(--sp-3); }
.cta-band p { color: #d5e5f5; max-width: 58ch; }
.cta-band .actions { display: flex; flex-wrap: wrap; gap: var(--sp-3); margin-top: var(--sp-5); }
.cta-band__art { position: absolute; right: -30px; bottom: -40px; width: 380px; opacity: 0.12; z-index: -1; filter: brightness(0) invert(1); pointer-events: none; }
@media (max-width: 700px) { .cta-band__art { width: 240px; right: -60px; } }
.cta-band .prose, .cta-band .prose p { color: #d5e5f5; }

.contact-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-4); }
.contact-list li { display: flex; gap: var(--sp-3); align-items: flex-start; }
.contact-list .icon { color: var(--turquoise-600); margin-top: 0.2em; }
.contact-list strong { display: block; font-size: var(--fs-xs); color: var(--muted); text-transform: uppercase; letter-spacing: 0.08em; font-weight: 650; }

.split { display: grid; gap: var(--sp-7); }
@media (min-width: 960px) { .split { grid-template-columns: 0.9fr 1.1fr; align-items: start; } .split--even { grid-template-columns: 1fr 1fr; } }

/* Pasos de afiliación */
.steps { counter-reset: step; list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-4); }
.steps li { counter-increment: step; position: relative; padding-left: 3.25rem; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 2.25rem; height: 2.25rem; display: grid; place-items: center; border-radius: 50%; background: var(--blue-50); color: var(--blue-700); font-weight: 750; font-family: var(--font-display); }

/* ---------- Detalle de artículo ---------- */
.article-header { padding: clamp(2.5rem, 1.5rem + 3vw, 4rem) 0 var(--sp-6); }
.article-header h1 { font-size: var(--fs-3xl); max-width: 26ch; }
.article-header .lead { margin-bottom: var(--sp-4); }
.article-media { margin: 0 0 var(--sp-7); }
.article-media { border-radius: var(--radius-xl); }
.article-media img { display: block; width: auto; max-width: 100%; height: auto; max-height: 640px; margin-inline: auto; object-fit: contain; }
.article-media figcaption { font-size: var(--fs-xs); color: var(--muted); margin-top: var(--sp-2); }
.article-layout { display: grid; gap: var(--sp-7); padding-bottom: var(--section-y); }
@media (min-width: 1080px) { .article-layout { grid-template-columns: 1fr 320px; } }
.aside-card { padding: var(--sp-5); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface-alt); }
.aside-card h2 { font-size: 1.05rem; margin-bottom: var(--sp-4); }
.share { display: flex; flex-wrap: wrap; gap: var(--sp-2); }
.info-list { display: grid; gap: var(--sp-4); margin: 0; }
.info-list dt { font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); font-weight: 650; }
.info-list dd { margin: 0.2rem 0 0; font-weight: 550; color: var(--navy-900); overflow-wrap: anywhere; }
.preview-banner { position: sticky; top: 0; z-index: 60; background: var(--warning-bg); color: var(--warning); border-bottom: 1px solid #f3dcae; padding: var(--sp-2) var(--gutter); text-align: center; font-weight: 600; font-size: var(--fs-sm); }

/* ---------- Pie de página ---------- */
.site-footer { margin-top: auto; background: var(--navy-950); color: #b9c8db; font-size: var(--fs-sm); position: relative; }
.site-footer::before { content: ""; display: block; height: 4px; background: var(--brand-gradient); }
.site-footer a { color: #dce8f5; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-grid { display: grid; gap: var(--sp-7); padding: var(--sp-8) 0 var(--sp-7); }
@media (min-width: 860px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; } }
.footer-brand { display: flex; flex-direction: column; gap: var(--sp-4); }
.footer-brand__logo { display: inline-flex; align-items: center; gap: var(--sp-3); }
.footer-brand__logo img { height: 64px; width: auto; background: #fff; border-radius: 50%; padding: 2px; }
.footer-brand__name { font: 700 1rem/1.3 var(--font-display); color: #fff; max-width: 18rem; }
.site-footer h2 { font: 700 0.8rem var(--font-body); letter-spacing: 0.12em; text-transform: uppercase; color: #7fd6e0; margin-bottom: var(--sp-4); }
.footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-2); }
.footer-links a { display: inline-flex; min-height: 32px; align-items: center; gap: 0.5em; }
.footer-bottom { display: flex; flex-wrap: wrap; gap: var(--sp-3) var(--sp-5); justify-content: space-between; padding: var(--sp-5) 0; border-top: 1px solid rgba(255, 255, 255, 0.1); font-size: var(--fs-xs); color: #9fb1c8; }
.footer-bottom ul { display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-5); list-style: none; margin: 0; padding: 0; }
.social { display: flex; flex-wrap: wrap; gap: var(--sp-2); list-style: none; margin: 0; padding: 0; }
.social a { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: rgba(255, 255, 255, 0.08); }
.social a:hover { background: rgba(255, 255, 255, 0.18); }

/* ---------- Página de error ---------- */
.error-page { text-align: center; padding: var(--sp-9) 0; }
.error-page__code { font: 800 clamp(4rem, 3rem + 6vw, 7rem)/1 var(--font-display); background: var(--brand-gradient); -webkit-background-clip: text; background-clip: text; color: transparent; margin-bottom: var(--sp-4); }
.error-page .actions { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-3); margin-top: var(--sp-6); }

/* ---------- Aparición al desplazarse (solo con JS y sin movimiento reducido) ---------- */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
  .js [data-reveal].is-visible { opacity: 1; transform: none; }
}

/* ---------- Impresión ---------- */
@media print {
  .site-header, .site-footer, .skip-link, .mobile-nav, .toolbar, .pagination, .share, .btn { display: none !important; }
  body { color: #000; }
  a { color: #000; }
  .prose a::after { content: " (" attr(href) ")"; font-size: 0.85em; }
}

/* En pantallas estrechas, el formulario aparece antes que la información complementaria. */
@media (max-width: 959px) { .split > .form-card { order: -1; } }

/* ---------- Enlace a la publicación original en redes sociales ---------- */
.card__social {
  position: relative; z-index: 2; /* por encima del enlace que cubre la tarjeta */
  display: inline-flex; align-items: center; gap: 0.4em; min-height: 32px;
  font-size: var(--fs-xs); font-weight: 650; color: var(--blue-700); text-decoration: none;
}
.card__social:hover { color: var(--blue-600); text-decoration: underline; }
.card__social .icon { width: 1.15em; height: 1.15em; }
.card__social--facebook .icon { color: #1877f2; }
.card__social--instagram .icon { color: #c13584; }
.card__social--linkedin .icon { color: #0a66c2; }
.card__social--youtube .icon { color: #ff0000; }
.card__social--x .icon, .card__social--tiktok .icon { color: #111; }
.feature__actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2) var(--sp-5); }
.feature__actions .card__social { font-size: var(--fs-sm); }

.social-origin {
  display: flex; gap: var(--sp-4); align-items: flex-start; margin-top: var(--sp-6); padding: var(--sp-5);
  border: 1px solid var(--line); border-left: 4px solid var(--turquoise-500); border-radius: var(--radius-lg); background: var(--surface-alt);
}
.social-origin > div { min-width: 0; }
.social-origin__icon { width: 32px; height: 32px; color: var(--blue-600); flex: none; }
.social-origin__title { font: 700 1.05rem/1.3 var(--font-display); color: var(--navy-900); margin: 0 0 var(--sp-1); }
.social-origin__text { color: var(--ink-soft); font-size: var(--fs-sm); margin: 0 0 var(--sp-4); }
.btn--social-facebook { --btn-bg: #1565d8; --btn-bd: #1565d8; } /* azul de Facebook oscurecido para contraste AA */
.btn--social-facebook:hover { --btn-bg: #0f5fc7; }
.btn--social-instagram { --btn-bg: #c13584; --btn-bd: #c13584; }
.btn--social-instagram:hover { --btn-bg: #a12a6e; }
.btn--social-x, .btn--social-tiktok { --btn-bg: #111; --btn-bd: #111; }
.btn--social-x:hover, .btn--social-tiktok:hover { --btn-bg: #333; }
.btn--social-linkedin { --btn-bg: #0a66c2; --btn-bd: #0a66c2; }
.btn--social-youtube { --btn-bg: #cc0000; --btn-bd: #cc0000; }
