/* CarisMisiones TX — estructura y componentes (mobile-first).
   Los colores, fuentes y formas vienen de las variables de theme.css. */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 90px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  padding-bottom: calc(76px + env(safe-area-inset-bottom));
}
body.has-sticky-cta { padding-bottom: calc(150px + env(safe-area-inset-bottom)); }
@media (min-width: 900px) { body, body.has-sticky-cta { padding-bottom: 0; } }

img { max-width: 100%; display: block; }
a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 3px; }
h1, h2, h3, h4 {
  font-family: var(--font-head); font-weight: var(--head-weight); line-height: 1.08;
  letter-spacing: var(--head-tracking); text-transform: var(--head-transform); margin: 0 0 .45em;
  color: var(--heading);
}
h1 { font-size: clamp(2.3rem, 9vw, 4.6rem); }
h2 { font-size: clamp(1.75rem, 6vw, 2.9rem); }
h3 { font-size: 1.3rem; letter-spacing: var(--head-tracking-sm); }
p { margin: 0 0 1em; }
em { font-style: var(--em-style); color: var(--em-color); }
.icon { width: 1.25em; height: 1.25em; flex: none; }

.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
@media (min-width: 900px) { .wrap { padding: 0 32px; } }
.section { padding: 56px 0; }
@media (min-width: 900px) { .section { padding: 96px 0; } }
.section-alt { background: var(--bg-alt); }
.section-head { margin-bottom: 28px; max-width: 46rem; }
.section-head.center { text-align: center; margin-left: auto; margin-right: auto; }
.section-head.row { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; max-width: none; }
.section-head h2 { margin-bottom: 0; }
.section-head p { color: var(--muted); margin: 12px 0 0; font-size: 1.1rem; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-label);
  font-size: .78rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
  color: var(--eyebrow); margin-bottom: 12px;
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: currentColor; display: var(--eyebrow-line); }
.kicker { font-size: .75rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--eyebrow); }
.muted { color: var(--muted); }
.link-arrow { font-weight: 700; text-decoration: none; white-space: nowrap; color: var(--link); }

/* ---------- botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 48px; padding: 0 1.4em; border-radius: var(--btn-radius);
  font: 700 1rem/1 var(--font-body); letter-spacing: var(--btn-tracking); text-transform: var(--btn-transform);
  text-decoration: none; border: 1.5px solid transparent; cursor: pointer;
  transition: transform .15s ease, background .2s, color .2s, border-color .2s;
  -webkit-tap-highlight-color: transparent;
}
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--primary); color: var(--on-primary); box-shadow: var(--btn-shadow); }
.btn-primary:hover { background: var(--primary-hover); color: var(--on-primary); }
.btn-ghost { background: var(--ghost-bg); color: var(--text); border-color: var(--line-strong); }
.btn-ghost:hover { border-color: var(--text); }
.btn-light { background: #fff; color: #1a1411; }
.btn-sm { min-height: 38px; padding: 0 1.1em; font-size: .9rem; }
.btn-lg { min-height: 54px; padding: 0 1.7em; font-size: 1.05rem; }
.btn-block { width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; }

.pill {
  display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px;
  font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  background: var(--pill-bg); color: var(--pill-text); margin-bottom: 14px;
}
.pill-live { background: var(--primary); color: var(--on-primary); animation: pulse 2s infinite; }
@keyframes pulse { 50% { opacity: .75; } }

/* ---------- encabezado ---------- */
.topbar {
  position: sticky; top: 0; z-index: 60; background: var(--header-bg); color: var(--header-text);
  border-bottom: 1px solid var(--header-line); backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px); padding-top: env(safe-area-inset-top);
  transition: background .3s, border-color .3s;
}
.topbar-inner { display: flex; align-items: center; gap: 20px; height: 64px; }
@media (min-width: 900px) { .topbar-inner { height: 76px; } }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; margin-right: auto; }
.brand-mark {
  width: 42px; height: 42px; border-radius: 50%; background: #fff; display: grid; place-items: center;
  box-shadow: 0 0 0 1px rgba(0,0,0,.06); flex: none;
}
.brand-mark img { width: 36px; height: 36px; }
.brand-name { font-family: var(--font-brand); font-weight: 800; font-size: 1.1rem; letter-spacing: var(--brand-tracking); text-transform: var(--brand-transform); }
.brand-name span { color: var(--primary); margin-left: 4px; }
.topnav { display: none; gap: 2px; }
.topnav a {
  color: inherit; text-decoration: none; font-weight: 600; font-size: .95rem; padding: 8px 12px; border-radius: 10px;
  opacity: .82; transition: opacity .2s, background .2s;
}
.topnav a:hover { opacity: 1; background: var(--nav-hover); }
.topnav a[aria-current="page"] { opacity: 1; color: var(--nav-active); }
@media (min-width: 900px) { .topnav { display: flex; } }


/* ---------- barra de pestañas (móvil) ---------- */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 70; display: grid; grid-template-columns: repeat(5, 1fr);
  background: var(--tab-bg); border-top: 1px solid var(--tab-line);
  padding: 6px 6px calc(6px + env(safe-area-inset-bottom));
  backdrop-filter: saturate(160%) blur(16px); -webkit-backdrop-filter: saturate(160%) blur(16px);
}
.tabbar a, .tabbar button {
  display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 6px 0;
  font: 600 .7rem/1 var(--font-body); color: var(--tab-text); text-decoration: none;
  background: none; border: 0; border-radius: 12px; cursor: pointer; -webkit-tap-highlight-color: transparent;
}
.tabbar .icon { width: 24px; height: 24px; }
.tabbar .active { color: var(--tab-active); }
.tabbar .active .icon { stroke-width: 2.4; }
@media (min-width: 900px) { .tabbar { display: none; } }

/* Hoja "Más" */
.sheet { position: fixed; inset: 0; z-index: 90; pointer-events: none; }
.sheet-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,.45); opacity: 0; transition: opacity .25s; }
.sheet-panel {
  position: absolute; left: 0; right: 0; bottom: 0; background: var(--surface); color: var(--text);
  border-radius: 24px 24px 0 0; padding: 10px 16px calc(20px + env(safe-area-inset-bottom));
  transform: translateY(100%); transition: transform .3s cubic-bezier(.2,.8,.2,1);
}
.sheet.open { pointer-events: auto; }
.sheet.open .sheet-backdrop { opacity: 1; }
.sheet.open .sheet-panel { transform: none; }
.sheet-handle { width: 40px; height: 5px; border-radius: 3px; background: var(--line-strong); margin: 0 auto 10px; }
.sheet-panel a {
  display: flex; align-items: center; gap: 14px; padding: 15px 8px; color: inherit; text-decoration: none;
  font-weight: 600; border-bottom: 1px solid var(--line);
}
.sheet-panel a:last-child { border-bottom: 0; }
.sheet-panel a span { flex: 1; }
.sheet-panel a .icon:first-child { color: var(--primary); }
.sheet-panel a .icon:last-child { opacity: .4; width: 18px; }

/* ---------- portada (hero) ---------- */
.hero { position: relative; overflow: hidden; isolation: isolate; }
.hero-media { position: absolute; inset: 0; z-index: -1; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: var(--hero-pos, center 42%); }
.hero-media::after { content: ""; position: absolute; inset: 0; background: var(--hero-overlay); }
.hero-content { position: relative; padding-top: 72px; padding-bottom: 64px; color: var(--hero-text); }
.hero-title { max-width: 12ch; color: inherit; }
.hero-text { font-size: 1.15rem; max-width: 34rem; opacity: .9; margin-bottom: 28px; }
.hero .eyebrow { color: var(--hero-eyebrow); }
.hero .btn-ghost { background: var(--hero-ghost-bg); color: var(--hero-text); border-color: var(--hero-ghost-line); }

/* ---------- accesos rápidos ---------- */
.quick { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; position: relative; z-index: 2; }
.quick a {
  display: flex; flex-direction: column; gap: 10px; padding: 18px; border-radius: var(--radius);
  background: var(--surface); color: var(--text); text-decoration: none; border: 1px solid var(--line);
  box-shadow: var(--shadow-sm); transition: transform .2s, border-color .2s;
}
.quick a:hover { transform: translateY(-2px); border-color: var(--line-strong); }
.quick .q-icon { width: 44px; height: 44px; border-radius: var(--radius-sm); display: grid; place-items: center; background: var(--icon-bg); color: var(--icon-color); }
.quick a > div { display: flex; flex-direction: column; gap: 2px; }
.quick strong { font-size: 1.02rem; }
.quick small { color: var(--muted); font-size: .85rem; line-height: 1.35; }
@media (min-width: 760px) { .quick { grid-template-columns: repeat(4, 1fr); } }

/* ---------- evento destacado ---------- */
.feature {
  display: grid; gap: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow);
}
.feature-media { display: block; background: var(--surface-2); }
.feature-media img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: top; }
.feature-body { padding: 24px; }
.feature-body h3 { font-size: clamp(1.6rem, 5vw, 2.4rem); }
.feature-lema { font-size: 1.1rem; color: var(--muted); font-style: italic; }
@media (min-width: 820px) {
  .feature { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); align-items: stretch; }
  .feature-media img { height: 100%; aspect-ratio: auto; min-height: 460px; }
  .feature-body { padding: 44px; align-self: center; }
}
.meta-list { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 10px; }
.meta-list li { display: flex; gap: 12px; align-items: flex-start; color: var(--muted); }
.meta-list .icon { color: var(--primary); margin-top: 3px; }
.meta-list--lg li { font-size: 1.05rem; }

/* ---------- tarjetas de evento ---------- */
.rail {
  display: grid; grid-auto-flow: column; grid-auto-columns: 78%; gap: 14px; overflow-x: auto;
  scroll-snap-type: x mandatory; padding: 4px 20px 16px; margin: 0 -20px; scrollbar-width: none;
}
.rail::-webkit-scrollbar { display: none; }
.rail > * { scroll-snap-align: start; }
@media (min-width: 640px) { .rail { grid-auto-columns: 46%; } }
@media (min-width: 1000px) { .rail { grid-auto-flow: row; grid-template-columns: repeat(3, 1fr); overflow: visible; margin: 0; padding: 4px 0; } }
.grid-events { display: grid; gap: 18px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid-events { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .grid-events { grid-template-columns: repeat(3, 1fr); } }

.ecard {
  display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden; text-decoration: none; color: var(--text);
  box-shadow: var(--shadow-sm); transition: transform .25s, box-shadow .25s;
}
.ecard:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.ecard-media { position: relative; aspect-ratio: var(--card-ratio, 4 / 3); background: var(--surface-2); overflow: hidden; border-radius: var(--card-media-radius, 0); }
.ecard-media > img { width: 100%; height: 100%; object-fit: cover; object-position: top; transition: transform .5s; }
.ecard:hover .ecard-media > img { transform: scale(1.04); }
.ecard--past .ecard-media > img { filter: grayscale(.5); }
.ecard--tbd .ecard-media { aspect-ratio: 16 / 9; }
.ecard-placeholder { width: 100%; height: 100%; display: grid; place-items: center; background: var(--placeholder-bg); }
.ecard-placeholder img { width: 34%; max-width: 120px; background: #fff; border-radius: 50%; padding: 10px; }
.ecard-body { padding: 16px 18px 20px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.ecard-body h3 { margin: 2px 0 4px; font-size: 1.2rem; line-height: 1.2; }
.ecard-meta { margin: 0; color: var(--muted); font-size: .92rem; }
.ecard-place { display: flex; gap: 6px; align-items: center; margin: 4px 0 0; font-size: .88rem; color: var(--muted); }
.ecard-place .icon { width: 15px; height: 15px; color: var(--primary); }
.date-badge {
  position: absolute; top: 12px; left: 12px; min-width: 54px; padding: 7px 8px 6px; border-radius: var(--radius-sm);
  background: var(--badge-bg); color: var(--badge-text); text-align: center; line-height: 1; box-shadow: 0 4px 14px rgba(0,0,0,.18);
}
.date-badge strong { display: block; font-family: var(--font-head); font-size: 1.45rem; font-weight: 800; }
.date-badge span { font-size: .66rem; font-weight: 800; letter-spacing: .1em; }
.date-badge.is-today { background: var(--primary); color: var(--on-primary); }
.date-badge--tbd span { font-size: .72rem; }

/* ---------- filtros ---------- */
.toolbar { display: flex; flex-direction: column; gap: 14px; margin-bottom: 24px; }
.segmented { display: inline-flex; padding: 4px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--line); align-self: flex-start; }
.segmented button {
  border: 0; background: none; padding: 9px 18px; border-radius: 999px; font: 700 .92rem var(--font-body);
  color: var(--muted); cursor: pointer;
}
.segmented button[aria-pressed="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 -20px; padding: 0 20px; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; border: 1px solid var(--line-strong); background: transparent; color: var(--text);
  padding: 8px 16px; border-radius: 999px; font: 600 .9rem var(--font-body); cursor: pointer;
}
.chip[aria-pressed="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }
@media (min-width: 760px) { .toolbar { flex-direction: row; align-items: center; justify-content: space-between; } .chips { margin: 0; padding: 0; } }

/* ---------- mosaicos de ministerios ---------- */
.tiles { display: grid; gap: 14px; grid-template-columns: 1fr 1fr; }
.tile {
  position: relative; display: flex; flex-direction: column; justify-content: flex-end; min-height: 220px;
  border-radius: var(--radius); overflow: hidden; color: #fff; text-decoration: none; isolation: isolate; padding: 18px;
}
.tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform .6s; }
.tile::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(0,0,0,0) 30%, rgba(0,0,0,.78) 100%); }
.tile:hover img { transform: scale(1.06); }
.tile h3 { color: #fff; margin: 0 0 4px; font-size: clamp(.98rem, 4.4vw, 1.15rem); overflow-wrap: anywhere; hyphens: auto; }
.tile p { margin: 0; font-size: .88rem; opacity: .85; line-height: 1.35; }
@media (min-width: 900px) { .tiles { grid-template-columns: repeat(4, 1fr); } .tile { min-height: 360px; padding: 24px; } .tile h3 { font-size: 1.4rem; } }

/* ---------- propósito ---------- */
.pillars { display: grid; gap: 14px; }
.pillar { padding: 26px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.pillar .num { font-family: var(--font-head); font-size: 2.6rem; font-weight: 800; color: var(--primary); line-height: 1; margin-bottom: 14px; }
.pillar h3 { text-transform: uppercase; letter-spacing: .08em; font-size: 1.15rem; }
.pillar p { color: var(--muted); margin: 0; }
@media (min-width: 820px) { .pillars { grid-template-columns: repeat(3, 1fr); gap: 20px; } .pillar { padding: 34px; } }

/* ---------- cita bíblica ---------- */
.verse { padding: 72px 0; background: var(--verse-bg); color: var(--verse-text); text-align: center; position: relative; overflow: hidden; }
.verse blockquote { margin: 0 auto; max-width: 54rem; font-family: var(--font-quote); font-size: clamp(1.35rem, 4.2vw, 2.1rem); line-height: 1.4; font-style: var(--quote-style); font-weight: var(--quote-weight); }
.verse cite { display: block; margin-top: 22px; font: 700 .82rem var(--font-body); letter-spacing: .2em; font-style: normal; opacity: .8; }

/* ---------- bloque dividido ---------- */
.split { display: grid; gap: 32px; align-items: center; }
.split-media { position: relative; }
.split-media img { width: 100%; border-radius: var(--radius-lg); aspect-ratio: 4 / 3; object-fit: cover; }
@media (min-width: 900px) { .split { grid-template-columns: 1fr 1fr; gap: 64px; } }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 24px 0 28px; }
.stat { padding: 14px; border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--line); }
.stat strong { display: block; font-family: var(--font-head); font-size: 1.7rem; font-weight: 800; color: var(--primary); line-height: 1.1; }
.stat span { font-size: .8rem; color: var(--muted); line-height: 1.3; display: block; }

/* ---------- tarjetas de llamada a la acción ---------- */
.cta-grid { display: grid; gap: 16px; }
@media (min-width: 900px) { .cta-grid { grid-template-columns: 1fr 1fr; } }
.cta-card {
  position: relative; overflow: hidden; isolation: isolate; border-radius: var(--radius-lg); padding: 32px 26px;
  min-height: 300px; display: flex; flex-direction: column; justify-content: flex-end; color: #fff;
}
.cta-card > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.cta-card::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(10,6,4,.15), rgba(10,6,4,.85)); }
.cta-card h2 { color: #fff; font-size: clamp(1.6rem, 5vw, 2.3rem); }
.cta-card p { opacity: .88; max-width: 30rem; }
.cta-card--solid { background: var(--cta-solid-bg); color: var(--cta-solid-text); }
.cta-card--solid::after { display: none; }
.cta-card--solid h2 { color: inherit; }
@media (min-width: 900px) { .cta-card { padding: 44px; min-height: 380px; } }

/* ---------- encabezado de página ---------- */
.page-head { padding: 40px 0 28px; }
.page-head h1 { font-size: clamp(2.4rem, 9vw, 4rem); }
.page-head p { color: var(--muted); font-size: 1.15rem; max-width: 40rem; margin: 0; }
.page-head--image { position: relative; isolation: isolate; color: #fff; padding: 88px 0 40px; overflow: hidden; }
.page-head--image > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.page-head--image::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(10,6,4,.35), rgba(10,6,4,.82)); }
.page-head--image h1, .page-head--image p { color: #fff; }
.page-head--image .eyebrow { color: #ffd38a; }
@media (min-width: 900px) { .page-head { padding: 72px 0 40px; } .page-head--image { padding: 160px 0 72px; } }

/* ---------- detalle de evento ---------- */
.detail-hero { position: relative; overflow: hidden; isolation: isolate; padding: 20px 0 48px; }
.detail-bg { position: absolute; inset: -40px; z-index: -1; background-size: cover; background-position: center; filter: blur(40px) saturate(1.2); opacity: var(--detail-bg-opacity, .25); }
.detail-grid { display: grid; gap: 28px; }
.detail-flyer img { width: 100%; border-radius: var(--radius-lg); box-shadow: var(--shadow); cursor: zoom-in; }
.detail-info h1 { font-size: clamp(2rem, 7vw, 3.4rem); }
.detail-lema { font-size: 1.2rem; font-style: italic; color: var(--muted); }
.detail-desc { font-size: 1.1rem; margin-bottom: 28px; }
.back-link { display: flex; width: fit-content; align-items: center; gap: 6px; text-decoration: none; color: var(--muted); font-weight: 600; margin-bottom: 18px; }
@media (min-width: 900px) {
  .detail-hero { padding: 56px 0 96px; }
  .detail-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 64px; align-items: start; }
  .detail-flyer { position: sticky; top: 100px; }
}
.sticky-cta {
  position: fixed; left: 0; right: 0; bottom: calc(68px + env(safe-area-inset-bottom)); z-index: 65;
  padding: 10px 16px; background: var(--tab-bg); border-top: 1px solid var(--tab-line);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
}
@media (min-width: 900px) { .sticky-cta { display: none; } }

/* ---------- formularios ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 26px; box-shadow: var(--shadow-sm); }
@media (min-width: 900px) { .card { padding: 40px; } }
.field { display: grid; gap: 8px; margin-bottom: 18px; }
.field label { font-weight: 700; font-size: .95rem; }
.field input, .field textarea {
  width: 100%; font: inherit; color: var(--text); background: var(--input-bg); border: 1.5px solid var(--line-strong);
  border-radius: var(--radius-sm); padding: 14px 16px; transition: border-color .2s, box-shadow .2s;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 4px var(--focus-ring); }
.field textarea { min-height: 160px; resize: vertical; }
.check { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 22px; color: var(--muted); }
.check input { width: 20px; height: 20px; accent-color: var(--primary); margin-top: 2px; }
.form-note { margin: 14px 0 0; font-size: .92rem; color: var(--muted); }
.two-col { display: grid; gap: 24px; }
@media (min-width: 900px) { .two-col { grid-template-columns: 1.15fr .85fr; gap: 40px; align-items: start; } }

.list-clean { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.list-clean li { display: flex; gap: 14px; align-items: flex-start; }
.list-clean .icon { color: var(--primary); margin-top: 3px; }
.list-clean a { display: block; }
.contact-lines a { display: block; }
.map { width: 100%; min-height: 340px; border: 0; border-radius: var(--radius-lg); display: block; }

/* ---------- línea de tiempo ---------- */
.timeline { list-style: none; padding: 0; margin: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 11px; top: 6px; bottom: 6px; width: 2px; background: var(--line-strong); }
.timeline li { position: relative; padding: 0 0 30px 44px; }
.timeline li::before { content: ""; position: absolute; left: 4px; top: 6px; width: 16px; height: 16px; border-radius: 50%; background: var(--primary); box-shadow: 0 0 0 5px var(--bg); }
.timeline strong { display: block; font-family: var(--font-head); font-size: 1.5rem; font-weight: 800; color: var(--primary); line-height: 1.1; }
.timeline h3 { margin: 4px 0 6px; }
.timeline p { margin: 0; color: var(--muted); }

.person { display: grid; gap: 22px; align-items: start; }
.person img { width: 100%; max-width: 280px; border-radius: var(--radius-lg); aspect-ratio: 3 / 4; object-fit: cover; }
@media (min-width: 760px) { .person { grid-template-columns: 260px 1fr; gap: 40px; } }
.prose { max-width: 44rem; }
.prose p { color: var(--muted); }
.books { padding-left: 1.2em; color: var(--muted); }
.credits { font-size: .9rem; color: var(--muted); padding-left: 1.2em; }

/* ---------- galería ---------- */
.gallery { columns: 2 160px; column-gap: 12px; }
.gallery figure { margin: 0 0 12px; break-inside: avoid; border-radius: var(--radius); overflow: hidden; background: var(--surface); border: 1px solid var(--line); }
.gallery img { width: 100%; cursor: zoom-in; }
.gallery figcaption { padding: 10px 12px; font-size: .85rem; color: var(--muted); }
@media (min-width: 900px) { .gallery { columns: 3 280px; column-gap: 18px; } .gallery figure { margin-bottom: 18px; } }

.empty { padding: 32px; text-align: center; color: var(--muted); border: 1.5px dashed var(--line-strong); border-radius: var(--radius); grid-column: 1 / -1; }

/* ---------- pie ---------- */
.footer { background: var(--footer-bg); color: var(--footer-text); padding: 56px 0 28px; font-size: .96rem; }
.footer .brand { margin-bottom: 14px; }
.footer-grid { display: grid; gap: 32px; }
.footer h4 { font-family: var(--font-body); font-size: .8rem; letter-spacing: .16em; text-transform: uppercase; color: var(--footer-head); margin-bottom: 14px; }
.footer a { color: inherit; }
.footer ul { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.footer ul a { text-decoration: none; opacity: .85; }
.footer ul a:hover { opacity: 1; text-decoration: underline; }
.footer-about p { opacity: .8; max-width: 26rem; }
.social { display: flex; gap: 10px; }
.social a { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--footer-line); }
.footer-bottom { display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; border-top: 1px solid var(--footer-line); margin-top: 40px; padding-top: 22px; font-size: .85rem; opacity: .75; }
@media (min-width: 900px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; } }


/* ---------- visor de imágenes ---------- */
.lightbox { position: fixed; inset: 0; z-index: 100; background: rgba(8,6,5,.94); display: none; align-items: center; justify-content: center; padding: 20px; }
.lightbox.open { display: flex; }
.lightbox img { max-height: 88vh; max-width: 100%; border-radius: 10px; }
.lightbox button { position: absolute; top: calc(14px + env(safe-area-inset-top)); right: 14px; width: 46px; height: 46px; border-radius: 50%; border: 0; background: rgba(255,255,255,.14); color: #fff; display: grid; place-items: center; cursor: pointer; }

/* ---------- animación de entrada ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } * { animation: none !important; } }

.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
