/* ============ Casa de Oración — estilos ============
   Estilo moderno de iglesia: fotos protagonistas, blanco y negro, tipografía fuerte, un acento dorado. */
:root {
  --black: #0b0b0b;
  --black-2: #161616;
  --black-3: #222;
  --white: #ffffff;
  --gray: #f4f3f0;
  --gray-2: #e8e6e1;
  --text: #141414;
  --muted: #5f5f5f;
  --muted-light: #a9a9a9;
  --line: #e2e0db;
  --line-dark: #2c2c2c;
  --gold: #c9a14a;
  --gold-dark: #9c7a2e;
  --red: #e0362b;
  --radius: 18px;
  --radius-sm: 12px;
  --head: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --body: "Inter", "Segoe UI", system-ui, sans-serif;
  --wrap: 1200px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body { font-family: var(--body); font-size: 16px; line-height: 1.6; color: var(--text); background: var(--white); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; }
h1, h2, h3, h4 { font-family: var(--head); font-weight: 800; line-height: 1.04; letter-spacing: -.025em; }
h2 { font-size: clamp(2rem, 4.6vw, 3.4rem); }
h3 { font-size: 1.3rem; font-weight: 700; letter-spacing: -.01em; }
p + p { margin-top: .8rem; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap, .container { width: min(var(--wrap), 100% - 48px); margin-inline: auto; }
.narrow { width: min(820px, 100% - 48px); }
.center { text-align: center; }
.section { padding: clamp(72px, 10vw, 128px) 0; }
.section-gray { background: var(--gray); }
.section-dark { background: var(--black); color: var(--white); }

.eyebrow { font-family: var(--head); font-size: .8rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: 14px; }
.eyebrow-dark { color: var(--gold-dark); }
.lead { font-size: 1.15rem; color: var(--text); }
.muted { color: var(--muted); }
.muted-light { color: var(--muted-light); }
.section-head { max-width: 680px; margin-bottom: 48px; }
.section-head h2 { margin-bottom: 14px; }
.section-head p:not(.eyebrow) { color: var(--muted); font-size: 1.08rem; }
.section-dark .section-head p:not(.eyebrow) { color: var(--muted-light); }
.section-head-row { max-width: none; display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; }
.section-head-row > div { max-width: 640px; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 52px; padding: 0 28px; border-radius: 999px; border: 1.5px solid transparent;
  font: 600 .98rem var(--body); cursor: pointer; white-space: nowrap; background: transparent; color: inherit;
  transition: background .2s, color .2s, border-color .2s, transform .2s;
}
.btn:active { transform: scale(.98); }
.btn-sm { height: 40px; padding: 0 18px; font-size: .9rem; }
.btn-light { background: var(--white); color: var(--black); }
.btn-light:hover { background: var(--gray-2); }
.btn-outline-light, .btn-line { border-color: rgba(255, 255, 255, .55); color: var(--white); background: transparent; }
.btn-outline-light:hover, .btn-line:hover { background: var(--white); color: var(--black); border-color: var(--white); }
.btn-dark, .btn-gold { background: var(--black); color: var(--white); }
.btn-dark:hover, .btn-gold:hover { background: var(--black-3); }
.btn-outline-dark, .btn-ghost { border-color: var(--text); color: var(--text); background: transparent; }
.btn-outline-dark:hover, .btn-ghost:hover { background: var(--black); color: var(--white); border-color: var(--black); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }

/* ---------- Encabezado ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50; height: 72px;
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 0 max(24px, calc((100% - var(--wrap)) / 2));
  background: var(--black); color: var(--white); transition: background .3s, box-shadow .3s;
}
.home .topbar { position: fixed; left: 0; right: 0; background: transparent; }
.home .topbar.scrolled { background: rgba(11, 11, 11, .92); backdrop-filter: blur(12px); box-shadow: 0 1px 0 rgba(255, 255, 255, .06); }
.brand { display: flex; align-items: center; gap: 12px; font-family: var(--head); font-weight: 800; font-size: 1.15rem; letter-spacing: -.01em; }
.brand img { border-radius: 50%; }
.nav-desktop { display: flex; gap: 30px; }
.nav-desktop a { font-size: .93rem; font-weight: 500; color: rgba(255, 255, 255, .78); transition: color .2s; }
.nav-desktop a:hover, .nav-desktop a.current { color: var(--white); }
.topbar-actions { display: flex; gap: 10px; }

/* ---------- Portada ---------- */
.hero { position: relative; min-height: clamp(600px, 52vw, 860px); display: flex; flex-direction: column; justify-content: flex-end; color: var(--white); background: var(--black); overflow: hidden; }
.hero-bg {
  position: absolute; top: 0; bottom: 0; right: 0; left: 36%; width: 64%; height: 100%; object-fit: cover; object-position: 80% 20%;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 28%); mask-image: linear-gradient(90deg, transparent 0%, #000 28%);
}
.hero-shade {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse at 75% 30%, rgba(201, 161, 74, .18), transparent 60%),
    linear-gradient(180deg, rgba(0, 0, 0, .55) 0%, rgba(0, 0, 0, 0) 20%, rgba(0, 0, 0, 0) 65%, rgba(0, 0, 0, .85) 100%);
}
.hero-inner { position: relative; padding: 140px 0 56px; }
.hero-inner > * { max-width: 46%; }
.hero-inner > h1 { max-width: 10ch; }
.hero h1 { font-size: clamp(2.8rem, 6.2vw, 5.6rem); max-width: 10ch; margin-bottom: 22px; }
.hero-sub { font-size: clamp(1.05rem, 1.6vw, 1.25rem); max-width: 480px; color: rgba(255, 255, 255, .85); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.hero-pastors { margin-top: 40px; font-size: .9rem; color: rgba(255, 255, 255, .7); display: flex; align-items: center; gap: 12px; }
.hero-pastors::before { content: ""; width: 28px; height: 1.5px; background: var(--gold); }
.hero-next { position: relative; border-top: 1px solid rgba(255, 255, 255, .14); background: rgba(0, 0, 0, .35); backdrop-filter: blur(8px); }
.hero-next-inner { display: flex; align-items: center; gap: 12px; padding: 18px 0; font-size: .95rem; color: rgba(255, 255, 255, .85); flex-wrap: wrap; }
.hero-next-inner strong { color: var(--white); }
.hero-next-inner a { margin-left: auto; font-weight: 600; color: var(--white); }
.hero-next-inner a:hover { color: var(--gold); }
.live-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 0 rgba(224, 54, 43, .6); animation: pulse 2s infinite; flex-shrink: 0; }
@keyframes pulse { 70% { box-shadow: 0 0 0 8px rgba(224, 54, 43, 0); } 100% { box-shadow: 0 0 0 0 rgba(224, 54, 43, 0); } }

/* ---------- Reuniones ---------- */
.schedule { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; }
.slot {
  position: relative; display: flex; flex-direction: column; padding: 26px 22px 22px;
  background: var(--gray); border-radius: var(--radius); transition: background .2s, transform .2s;
}
.slot:hover { transform: translateY(-3px); }
.slot .day { font-family: var(--head); font-weight: 700; font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.slot .time { font-family: var(--head); font-weight: 800; font-size: 2.4rem; letter-spacing: -.03em; margin: 10px 0 2px; line-height: 1; }
.slot .time small { display: block; font-family: var(--body); font-weight: 500; font-size: .85rem; letter-spacing: 0; color: var(--muted); margin-top: 6px; }
.slot .name { font-weight: 600; font-size: 1.02rem; margin-top: 14px; flex: 1; }
.slot .cal { margin-top: 18px; align-self: flex-start; background: none; border: 0; padding: 0; font-size: .85rem; font-weight: 600; color: var(--text); cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.slot .cal:hover { color: var(--gold-dark); }
.slot.is-next { background: var(--black); color: var(--white); }
.slot.is-next .day, .slot.is-next .time small { color: var(--muted-light); }
.slot.is-next .cal { color: var(--white); }
.slot.is-next::after {
  content: "Próxima"; order: -1; align-self: flex-start; margin-bottom: 10px; font-size: .7rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  background: var(--red); color: var(--white); padding: 4px 9px; border-radius: 999px;
}

/* ---------- Visita ---------- */
.visit { display: grid; grid-template-columns: 1fr 1fr; gap: 0; background: var(--white); border-radius: var(--radius); overflow: hidden; }
.visit-photo img { width: 100%; height: 100%; min-height: 420px; object-fit: cover; }
.visit-body { padding: clamp(32px, 5vw, 64px); }
.visit-body h2 { margin-bottom: 14px; }
.visit-body .lead { color: var(--muted); font-size: 1.08rem; }
.steps { list-style: none; margin-top: 28px; display: grid; gap: 22px; }
.steps li { display: grid; grid-template-columns: 44px 1fr; gap: 14px; align-items: start; }
.steps li > span { font-family: var(--head); font-weight: 800; font-size: .9rem; color: var(--gold-dark); padding-top: 3px; border-top: 2px solid var(--gold); }
.steps strong { font-family: var(--head); font-weight: 700; font-size: 1.1rem; }
.steps p { color: var(--muted); font-size: .96rem; margin-top: 2px; }
.map-card { margin-top: 16px; border-radius: var(--radius); overflow: hidden; height: 320px; }
.map-card iframe { width: 100%; height: 100%; border: 0; display: block; filter: grayscale(1) contrast(1.05); }

/* ---------- Pastores ---------- */
.pastors { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 6vw, 88px); align-items: center; }
.pastors-photo { border-radius: var(--radius); overflow: hidden; }
.pastors-photo img { width: 100%; aspect-ratio: 6/5; object-fit: cover; object-position: center bottom; }
.pastors-body h2 { margin-bottom: 20px; }
.pastors-body > p:not(.eyebrow):not(.lead) { color: var(--muted); }

/* ---------- Ministerios ---------- */
.ministries { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.ministry { position: relative; aspect-ratio: 3/4; border-radius: var(--radius); overflow: hidden; color: var(--white); background: var(--black-2); }
.ministry img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.ministry::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0, 0, 0, 0) 45%, rgba(0, 0, 0, .8) 100%); }
.ministry:hover img { transform: scale(1.05); }
.ministry-text { position: absolute; left: 22px; right: 22px; bottom: 20px; z-index: 1; }
.ministry-text span { font-size: .82rem; font-weight: 600; color: rgba(255, 255, 255, .78); }
.ministry-text h3 { font-size: 1.5rem; font-weight: 800; margin-top: 4px; }

/* ---------- Mensajes ---------- */
.messages { display: grid; grid-template-columns: 1.55fr 1fr; gap: 20px; }
.msg-featured { position: relative; border: 0; padding: 0; cursor: pointer; text-align: left; color: var(--white); border-radius: var(--radius); overflow: hidden; min-height: 460px; background: var(--black-2); }
.msg-featured img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 30%; transition: transform .6s; }
.msg-featured:hover img { transform: scale(1.03); }
.msg-featured::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0, 0, 0, 0) 40%, rgba(0, 0, 0, .85)); }
.msg-play { position: absolute; z-index: 1; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 76px; height: 76px; border-radius: 50%; background: var(--white); color: var(--black); display: grid; place-items: center; padding-left: 4px; transition: transform .2s; }
.msg-featured:hover .msg-play { transform: translate(-50%, -50%) scale(1.08); }
.msg-caption { position: absolute; z-index: 1; left: 28px; right: 28px; bottom: 26px; display: flex; flex-direction: column; gap: 4px; }
.msg-caption small { font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--gold); }
.msg-caption strong { font-family: var(--head); font-weight: 800; font-size: clamp(1.4rem, 2.6vw, 2rem); line-height: 1.1; letter-spacing: -.02em; }
.msg-caption span { color: var(--muted-light); font-size: .95rem; }
.msg-list { display: grid; gap: 12px; align-content: start; }
.msg-item { display: grid; grid-template-columns: 112px 1fr; gap: 16px; align-items: center; border: 0; background: var(--black-2); color: var(--white); text-align: left; padding: 10px; border-radius: var(--radius-sm); cursor: pointer; transition: background .2s; }
.msg-item:hover { background: var(--black-3); }
.msg-thumb { position: relative; aspect-ratio: 1; border-radius: 8px; overflow: hidden; }
.msg-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: center 25%; }
.msg-thumb em { position: absolute; right: 6px; bottom: 6px; font-style: normal; font-size: .72rem; font-weight: 600; background: rgba(0, 0, 0, .75); padding: 1px 6px; border-radius: 4px; }
.msg-text { display: flex; flex-direction: column; gap: 4px; }
.msg-text strong { font-family: var(--head); font-weight: 700; font-size: 1.05rem; line-height: 1.25; }
.msg-text span { color: var(--muted-light); font-size: .88rem; }

/* ---------- Eventos ---------- */
.events-preview { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.events-list { display: grid; gap: 20px; margin-bottom: 30px; }
.event { display: flex; flex-direction: column; background: var(--gray); border-radius: var(--radius); overflow: hidden; }
.events-list .event { display: grid; grid-template-columns: 340px 1fr; }
.ev-img { position: relative; aspect-ratio: 16/10; overflow: hidden; background: var(--gray-2); }
.events-list .ev-img { aspect-ratio: auto; min-height: 300px; }
.ev-img img { width: 100%; height: 100%; object-fit: cover; object-position: center 22%; transition: transform .6s; }
.event:hover .ev-img img { transform: scale(1.03); }
.ev-date { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 60px; height: 64px; border-radius: 12px; background: var(--white); color: var(--text); line-height: 1; flex-shrink: 0; }
.ev-img .ev-date { position: absolute; top: 16px; left: 16px; }
.ev-date strong { font-family: var(--head); font-weight: 800; font-size: 1.6rem; }
.ev-date span { font-size: .68rem; font-weight: 700; letter-spacing: .1em; margin-top: 4px; color: var(--gold-dark); }
.ev-badge { position: absolute; top: 16px; right: 16px; font-size: .72rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; padding: 5px 11px; border-radius: 999px; background: rgba(0, 0, 0, .7); color: var(--white); backdrop-filter: blur(6px); }
.ev-badge.ev-soon { background: var(--red); }
.ev-body { padding: 26px 28px 28px; display: flex; flex-direction: column; flex: 1; }
.events-list .ev-body { padding: 34px 36px; justify-content: center; }
.ev-body h3 { font-size: 1.6rem; font-weight: 800; margin-bottom: 8px; }
.ev-meta { color: var(--gold-dark); font-size: .9rem; font-weight: 600; margin-bottom: 10px; }
.ev-body p:not(.ev-meta) { color: var(--muted); margin-top: 0; }
.ev-body .btn-row { margin-top: auto; padding-top: 22px; }
.ev-body .btn { height: 42px; padding: 0 20px; font-size: .9rem; }

.sub-title { font-size: clamp(1.7rem, 3.5vw, 2.4rem); margin: 64px 0 22px; }
.week-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 12px; }
.week-item { display: flex; align-items: center; gap: 16px; padding: 14px; background: var(--gray); border-radius: var(--radius-sm); }
.week-item .ev-date { width: 54px; height: 58px; }
.week-item .ev-date strong { font-size: 1.35rem; }
.wi-text { display: flex; flex-direction: column; flex: 1; }
.wi-text strong { font-weight: 600; }
.wi-text span { color: var(--muted); font-size: .9rem; }
.week-item .cal { width: 42px; height: 42px; border-radius: 50%; border: 0; background: var(--white); display: grid; place-items: center; cursor: pointer; color: var(--text); }
.week-item .cal:hover { background: var(--black); color: var(--white); }
.empty { padding: 44px 36px; background: var(--gray); border-radius: var(--radius); }
.empty h3 { font-size: 1.6rem; font-weight: 800; margin-bottom: 8px; }
.empty p { color: var(--muted); max-width: 520px; margin-bottom: 22px; }

/* ---------- Franja de fotos ---------- */
.photo-strip { position: relative; overflow: hidden; background: var(--black); }
.strip-track { display: flex; gap: 6px; width: max-content; animation: strip 60s linear infinite; }
.strip-track img { height: 300px; width: auto; aspect-ratio: 3/4; object-fit: cover; }
.photo-strip:hover .strip-track { animation-play-state: paused; }
@keyframes strip { to { transform: translateX(-50%); } }
.strip-cta { position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%); }

/* ---------- Palabra del día ---------- */
.verse-day { text-align: center; }
.verse-day blockquote { font-family: var(--head); font-weight: 700; font-size: clamp(1.7rem, 4vw, 2.8rem); line-height: 1.18; letter-spacing: -.02em; margin: 6px 0 26px; }
.verse-foot { display: flex; align-items: center; justify-content: center; gap: 18px; flex-wrap: wrap; }
.verse-foot cite { font-style: normal; font-weight: 600; color: var(--gold-dark); }

/* ---------- Oración + ofrendas ---------- */
.duo { display: grid; grid-template-columns: 1.4fr 1fr; gap: 20px; }
.panel { background: var(--white); border-radius: var(--radius); padding: clamp(28px, 4vw, 48px); }
.panel h2 { font-size: clamp(1.8rem, 3.4vw, 2.5rem); margin-bottom: 12px; }
.panel-dark { background: var(--black); color: var(--white); display: flex; flex-direction: column; }
.form { display: grid; gap: 16px; margin-top: 26px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form label { display: grid; gap: 6px; font-size: .9rem; font-weight: 600; }
.form .opt { color: var(--muted); font-weight: 400; }
.form input, .form select, .form textarea {
  width: 100%; padding: 14px 16px; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  background: var(--white); color: var(--text); font: 400 1rem var(--body); resize: vertical; transition: border-color .2s;
}
.form input:focus, .form select:focus, .form textarea:focus { outline: none; border-color: var(--black); }
.form .btn { justify-self: start; }
.form-note { color: var(--muted); }
.alias-box { margin-top: auto; padding-top: 30px; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.alias-box span { font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted-light); }
.alias-box strong { font-family: var(--head); font-weight: 800; font-size: 1.7rem; letter-spacing: -.02em; margin-bottom: 8px; }

/* ---------- CTA final ---------- */
.final-cta { background: var(--black); color: var(--white); padding: clamp(72px, 10vw, 120px) 0; border-bottom: 1px solid var(--line-dark); }
.final-inner { display: flex; justify-content: space-between; align-items: center; gap: 30px; flex-wrap: wrap; }
.final-inner h2 { font-size: clamp(2.2rem, 5vw, 3.8rem); max-width: 14ch; }
.final-inner .btn-row { margin-top: 0; }

/* ---------- Pie ---------- */
.footer { background: var(--black); color: var(--white); padding: 64px 0 40px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.2fr; gap: 40px; }
.footer p { color: var(--muted-light); font-size: .93rem; margin-top: 12px; max-width: 300px; }
.footer h4 { font-size: .85rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted-light); margin-bottom: 16px; }
.footer ul { list-style: none; display: grid; gap: 8px; font-size: .95rem; }
.footer ul a:hover { color: var(--gold); }
.socials { display: flex; gap: 10px; margin-top: 18px; }
.socials a { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: var(--black-3); transition: background .2s, color .2s; }
.socials a:hover { background: var(--white); color: var(--black); }
.copy { width: min(var(--wrap), 100% - 48px); margin: 48px auto 0; padding-top: 22px; border-top: 1px solid var(--line-dark); color: var(--muted-light); font-size: .85rem; }
.footer-mini { padding: 0 0 30px; }
.footer-mini .copy { margin-top: 0; border-top: 0; }

/* ---------- Subpáginas ---------- */
.page-hero { background: var(--black); color: var(--white); padding: 64px 0 0; }
.back { display: inline-flex; align-items: center; gap: 6px; font-size: .9rem; color: var(--muted-light); margin-bottom: 30px; }
.back:hover { color: var(--white); }
.page-hero .tag { display: block; font-family: var(--head); font-size: .8rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: 12px; }
.page-hero h1 { font-size: clamp(2.8rem, 8vw, 5.2rem); margin-bottom: 14px; }
.page-hero p { color: var(--muted-light); font-size: 1.1rem; max-width: 560px; }
.subpage .section { padding-top: 48px; }
.tabs { display: inline-flex; gap: 4px; margin: 40px 0 0; padding: 5px; background: var(--black-3); border-radius: 999px; transform: translateY(50%); position: relative; z-index: 2; }
.page-hero { margin-bottom: 26px; }
.tab { display: inline-flex; align-items: center; gap: 8px; height: 46px; padding: 0 24px; border: 0; border-radius: 999px; background: transparent; color: var(--muted-light); font: 600 .98rem var(--body); cursor: pointer; transition: background .2s, color .2s; }
.tab:hover { color: var(--white); }
.tab[aria-selected="true"] { background: var(--white); color: var(--black); }
.tab .count { font-size: .78rem; padding: 1px 8px; border-radius: 999px; background: rgba(128, 128, 128, .25); }
.tab .count:empty { display: none; }

.album + .album { margin-top: 64px; }
.album-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 20px; }
.album-head h2 { font-size: clamp(1.5rem, 3vw, 2rem); }
.album-head span { color: var(--muted); font-size: .92rem; }
.photo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.photo { aspect-ratio: 1; border: 0; padding: 0; border-radius: var(--radius-sm); overflow: hidden; cursor: zoom-in; background: var(--gray); }
.photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.photo:hover img { transform: scale(1.05); }

.video-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 30px 20px; margin-bottom: 40px; }
.video-card { border: 0; padding: 0; background: none; text-align: left; color: var(--text); cursor: pointer; }
.vc-thumb { position: relative; aspect-ratio: 4/5; border-radius: var(--radius); overflow: hidden; background: var(--gray); }
.vc-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: center 25%; transition: transform .5s; }
.video-card:hover .vc-thumb img { transform: scale(1.04); }
.vc-thumb .play { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 60px; height: 60px; border-radius: 50%; background: var(--white); color: var(--black); display: grid; place-items: center; padding-left: 3px; }
.vc-thumb .play svg { width: 24px; height: 24px; }
.vc-dur { position: absolute; right: 12px; bottom: 12px; background: rgba(0, 0, 0, .75); color: var(--white); font-size: .78rem; font-weight: 600; padding: 2px 8px; border-radius: 6px; }
.vc-info { padding-top: 14px; display: flex; flex-direction: column; gap: 3px; }
.vc-info strong { font-family: var(--head); font-weight: 700; font-size: 1.12rem; line-height: 1.25; }
.vc-info span { color: var(--muted); font-size: .88rem; }


/* Encabezado con video (Eventos): mitad derecha, igual que la portada del inicio */
.page-hero-video { margin-bottom: 0; position: relative; min-height: 560px; padding-top: 72px; display: flex; flex-direction: column; justify-content: center; overflow: hidden; }
.ph-media {
  position: absolute; top: 0; bottom: 0; right: 0; left: 46%;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 30%); mask-image: linear-gradient(90deg, transparent 0%, #000 30%);
}
.ph-bg { width: 100%; height: 100%; object-fit: cover; object-position: center 35%; }
.ph-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0, 0, 0, .45) 0%, transparent 25%, transparent 65%, rgba(0, 0, 0, .75) 100%); }
.page-hero-video .container { position: relative; z-index: 1; }
.page-hero-video .ph-text { max-width: 48%; }
.page-hero-video p { color: rgba(255, 255, 255, .82); }
.page-hero-video .tabs { transform: none; margin: 34px 0 40px; }
.page-hero-video + .section, .page-hero-video ~ .tab-panel { padding-top: 56px; }

/* Tablet y celular: video arriba, texto debajo */
@media (max-width: 900px) {
  .page-hero-video { display: block; min-height: 0; padding-top: 0; }
  .ph-media { position: relative; left: 0; height: min(92vw, 520px); -webkit-mask-image: none; mask-image: none; }
  .ph-shade { background: linear-gradient(180deg, rgba(0, 0, 0, .25) 0%, transparent 30%, transparent 55%, var(--black) 100%); }
  .page-hero-video .ph-text { max-width: none; margin-top: -90px; }
}
.ph-logo { background: #000; }
.ph-logo .ph-bg { object-fit: contain; object-position: center; background: #000; }
@media (max-width: 900px) {
  .ph-logo .ph-media { height: auto; aspect-ratio: 16 / 9; }
  .ph-logo .ph-shade { background: linear-gradient(180deg, transparent 75%, #000 100%); }
  .ph-logo .ph-text { margin-top: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  .ph-bg { display: none; }
  .ph-media { background: url("../img/videos/fondo-celebracion.jpg") center/cover; }
  .ph-logo .ph-media { background-image: url("../img/videos/fondo-logo-fuego.jpg"); }
}

/* ---------- TV en vivo ---------- */
.tv-page { background: var(--black); }
.tv { background: #000; color: var(--white); padding: 40px 0 56px; }
.tv-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.tv-brand { font-family: var(--head); font-weight: 700; font-size: .95rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted-light); margin-bottom: 6px; }
.tv-brand strong { color: var(--gold); }
.tv-head h1 { font-size: clamp(2rem, 5vw, 3.4rem); }
.tv-status { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border-radius: 999px; background: var(--black-3); color: var(--muted-light); font-weight: 700; font-size: .85rem; letter-spacing: .06em; text-transform: uppercase; }
.tv-status .dot { width: 9px; height: 9px; border-radius: 50%; background: #666; }
.tv-status.on { background: var(--red); color: var(--white); }
.tv-status.on .dot { background: var(--white); animation: pulse 2s infinite; }
.tv-stage { position: relative; border-radius: var(--radius); overflow: hidden; background: #000; border: 1px solid var(--line-dark); }
.tv-off { position: relative; aspect-ratio: 16 / 9; display: grid; align-items: end; }
.tv-off video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .55; }
.tv-off::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0,0,0,.85) 0%, rgba(0,0,0,.4) 55%, rgba(0,0,0,.1) 100%); }
.tv-off-info { position: relative; z-index: 1; padding: clamp(22px, 4vw, 48px); max-width: 620px; }
.tv-off-info h2 { font-size: clamp(1.8rem, 4vw, 3rem); margin-bottom: 6px; }
.tv-prox-cuando { color: rgba(255,255,255,.8); font-size: 1.05rem; margin-bottom: 20px; }
.countdown { display: flex; gap: 10px; flex-wrap: wrap; }
.countdown div { min-width: 74px; padding: 12px 10px; border-radius: 14px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.12); backdrop-filter: blur(6px); text-align: center; }
.countdown strong { display: block; font-family: var(--head); font-weight: 800; font-size: 1.9rem; line-height: 1; }
.countdown span { font-size: .75rem; color: var(--muted-light); text-transform: uppercase; letter-spacing: .08em; }
.tv-pronto { color: var(--white); font-weight: 600; }
.tv-live { display: grid; place-items: center; background: radial-gradient(circle at 50% 40%, #1d1d1d, #000 70%); }
.tv-live.is-horizontal .tv-frame { width: 100%; aspect-ratio: 16 / 9; }
.tv-live.is-vertical { padding: 18px 0; }
.tv-live.is-vertical .tv-frame { height: min(80vh, 760px); aspect-ratio: 9 / 16; max-width: 100%; border-radius: 12px; overflow: hidden; }
.tv-frame iframe { width: 100%; height: 100%; border: 0; display: block; background: #000; }
.tv-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 20px; }
.tv-hint { color: var(--muted-light); font-size: .92rem; flex-basis: 100%; }

/* Cartel "EN VIVO AHORA" en el resto de las páginas */
.live-banner { position: sticky; top: 72px; z-index: 45; display: flex; align-items: center; justify-content: center; gap: 10px; padding: 10px 18px; background: var(--red); color: var(--white); font-size: .92rem; flex-wrap: wrap; text-align: center; }
.home .live-banner { position: fixed; left: 0; right: 0; top: 72px; }
.live-banner .live-dot { background: var(--white); }
.live-banner .lb-title { opacity: .9; }
.live-banner .lb-cta { font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.esta-en-vivo .bottom-nav a[href="tv.html"] { color: var(--white); }
.esta-en-vivo .bottom-nav a[href="tv.html"] svg circle { fill: var(--red); stroke: var(--red); }

@media (max-width: 640px) {
  .tv { padding-top: 24px; }
  .tv-off { aspect-ratio: 4 / 5; }
  .tv-off::after { background: linear-gradient(180deg, rgba(0,0,0,.15) 0%, rgba(0,0,0,.55) 45%, rgba(0,0,0,.92) 100%); }
  .countdown div { min-width: 0; flex: 1; padding: 10px 4px; }
  .countdown strong { font-size: 1.5rem; }
  .tv-live.is-vertical { padding: 0; }
  .tv-live.is-vertical .tv-frame { height: auto; width: 100%; border-radius: 0; }
  .live-banner, .home .live-banner { top: 64px; font-size: .85rem; }
  .tv-actions .btn { flex: 1; }
}

/* ---------- Lightbox y video ---------- */
.lightbox, .video-modal { position: fixed; inset: 0; z-index: 100; background: rgba(0, 0, 0, .94); display: grid; place-items: center; padding: 64px 16px; }
.lightbox img { max-width: 100%; max-height: 84vh; border-radius: 10px; }
.lb-btn { position: absolute; width: 48px; height: 48px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .12); color: var(--white); font-size: 1.5rem; line-height: 1; cursor: pointer; display: grid; place-items: center; transition: background .2s; }
.lb-btn:hover { background: var(--white); color: var(--black); }
.lb-close { top: 16px; right: 16px; font-size: 1rem; z-index: 2; }
.lb-prev { left: 16px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 16px; top: 50%; transform: translateY(-50%); }
.lb-count { position: absolute; bottom: 22px; left: 50%; transform: translateX(-50%); color: var(--muted-light); font-size: .9rem; }
.vm-box { position: relative; width: min(420px, 100%); }
.vm-box .lb-close { top: -58px; right: 0; }
.vm-frame { aspect-ratio: 9/16; max-height: 76vh; margin: 0 auto; background: #000; border-radius: var(--radius); overflow: hidden; }
.vm-frame iframe { width: 100%; height: 100%; border: 0; }
.vm-frame video { width: 100%; height: 100%; background: #000; object-fit: contain; }
.video-modal.is-wide .vm-box { width: min(960px, 100%); }
.video-modal.is-wide .vm-frame { aspect-ratio: 16/9; max-height: 80vh; }
.vm-info { display: flex; justify-content: space-between; gap: 12px; padding: 14px 2px; color: var(--white); flex-wrap: wrap; }
.vm-info strong { font-family: var(--head); font-weight: 700; }
.vm-info a { color: var(--gold); font-size: .92rem; }
.vm-hint { flex-basis: 100%; color: var(--muted-light); font-size: .85rem; }

/* ---------- Toast ---------- */
.toast { position: fixed; left: 50%; bottom: 96px; transform: translate(-50%, 16px); opacity: 0; pointer-events: none; z-index: 120; background: var(--black); color: var(--white); padding: 13px 22px; border-radius: 999px; font-weight: 600; transition: .25s; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Nav inferior ---------- */
.bottom-nav { display: none; }

/* ---------- Aparición suave ---------- */
.reveal { opacity: 0; transform: translateY(16px); 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; }
  .strip-track, .live-dot { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .nav-desktop { display: none; }
  .ministries { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 860px) {
  .visit, .pastors, .messages, .duo { grid-template-columns: 1fr; }
  .visit-photo img { min-height: 260px; aspect-ratio: 16/10; }
  .msg-featured { min-height: 380px; }
  .events-list .event { grid-template-columns: 1fr; }
  .events-list .ev-img { min-height: 0; aspect-ratio: 4/3; }
}

/* Portada en tablet y celular: foto arriba, texto debajo */
@media (max-width: 900px) {
  .hero { min-height: 0; display: block; padding-top: 72px; }
  .hero-bg { position: relative; left: 0; width: 100%; height: min(78vw, 560px); object-position: 72% 0%; -webkit-mask-image: none; mask-image: none; }
  .hero-inner > * { max-width: none; }
  .hero-shade { top: 72px; bottom: auto; height: min(78vw, 560px); background: linear-gradient(180deg, rgba(0, 0, 0, .15) 0%, rgba(0, 0, 0, 0) 22%, rgba(0, 0, 0, 0) 55%, var(--black) 100%); }
  .hero-inner { padding: 0 0 40px; margin-top: -70px; }
  .hero h1 { max-width: 13ch; }
  .hero-next { background: var(--black-2); backdrop-filter: none; }
}
@media (max-width: 640px) {
  .wrap, .container, .copy { width: calc(100% - 36px); }
  .topbar { height: 64px; padding: 0 18px; }
  .hero { padding-top: 64px; }
  .hero-shade { top: 64px; }
  .hero .eyebrow { font-size: .72rem; }
  .topbar-actions .btn-light { display: none; }
  .brand { font-size: 1.05rem; }
  .hero h1 { font-size: 2.7rem; }
  .hero-cta .btn { flex: 1; padding: 0 16px; }
  .hero-pastors { margin-top: 26px; }
  .hero-next-inner { display: grid; grid-template-columns: auto 1fr; align-items: baseline; font-size: .9rem; gap: 6px 10px; padding: 16px 0; }
  .hero-next-inner .live-dot { align-self: center; }
  .hero-next-inner a { grid-column: 2; margin-left: 0; }
  .section-head { margin-bottom: 32px; }
  .schedule { grid-template-columns: 1fr 1fr; gap: 10px; }
  .slot { padding: 20px 16px 18px; }
  .slot .time { font-size: 2rem; }
  .slot.is-next { grid-column: 1 / -1; }
  .ministries { gap: 10px; }
  .ministry-text { left: 14px; right: 14px; bottom: 14px; }
  .ministry-text h3 { font-size: 1.15rem; }
  .ministry-text span { font-size: .75rem; }
  .msg-item { grid-template-columns: 88px 1fr; }
  .events-preview { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .final-inner .btn-row { width: 100%; }
  .final-inner .btn { flex: 1; }
  .footer { padding-bottom: 100px; }
  .footer-grid { grid-template-columns: 1fr; gap: 30px; }
  .strip-track img { height: 220px; }
  .photo-grid { grid-template-columns: repeat(3, 1fr); gap: 4px; }
  .photo { border-radius: 6px; }
  .video-grid { grid-template-columns: 1fr 1fr; gap: 22px 12px; }
  .lb-prev, .lb-next { top: auto; bottom: 12px; transform: none; }
  .tabs { width: 100%; }
  .tab { flex: 1; justify-content: center; padding: 0 12px; }
  .map-card { height: 240px; }

  .bottom-nav {
    display: grid; grid-template-columns: repeat(5, 1fr);
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
    background: rgba(11, 11, 11, .96); backdrop-filter: blur(12px); border-top: 1px solid var(--line-dark);
    padding: 7px 0 calc(7px + env(safe-area-inset-bottom));
  }
  .bottom-nav a { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: .68rem; font-weight: 500; color: var(--muted-light); padding: 3px 0; }
  .bottom-nav svg { width: 23px; height: 23px; }
  .bottom-nav a.active { color: var(--white); }
}
