/* =========================================================
   Jóvenes Astrónomos Foster — course landing page
   Builds on style.css (tokens, .btn, .container, .section,
   .faq-item, .form-field, starfield). Page-specific only.
   ========================================================= */

/* ---- NAV ---- */
.jaf-nav {
  position: sticky;
  top: var(--banner-h, 0px);
  z-index: 100;
  background: rgba(6, 8, 28, 0.72);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.jaf-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 12px;
}
.jaf-nav-brand { display: flex; align-items: center; gap: 12px; }
.jaf-nav-brand img { width: 42px; height: auto; }
.jaf-nav-brand span { font-size: 0.78rem; line-height: 1.25; color: var(--text-1); letter-spacing: 0.04em; }
.jaf-nav-brand strong { color: var(--text-0); font-family: var(--f-display); font-size: 0.95rem; }
.jaf-nav-links { display: flex; align-items: center; gap: 28px; }
.jaf-nav-links a {
  font-size: 0.92rem;
  color: var(--text-1);
  letter-spacing: 0.01em;
  transition: color var(--t-fast) var(--ease);
}
.jaf-nav-links a:hover { color: var(--gold-bright); }
.jaf-nav-actions { display: flex; align-items: center; gap: 18px; }
#que-es, #programa, #faq, #inscripcion { scroll-margin-top: 84px; }
@media (max-width: 880px) {
  .jaf-nav-links { display: none; }
}

/* ---- HERO ---- */
.jaf-hero {
  position: relative;
  min-height: clamp(520px, 82vh, 760px);
  display: flex;
  align-items: flex-end;
  padding-block: clamp(48px, 9vw, 120px);
  overflow: hidden;
}
/* The photo + darkening gradient live on a ::before that is MASKED to fade to
   transparent at the bottom, so the hero dissolves into the fixed starfield
   behind it — seamless regardless of the page background colour. The cosmic
   gradient is the bottom background layer (fallback until the photo is added). */
.jaf-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse at 70% 18%, rgba(108, 93, 211, 0.28), transparent 60%),
    linear-gradient(180deg, rgba(6,8,28,0.10) 0%, rgba(6,8,28,0.45) 58%, rgba(6,8,28,0.80) 100%),
    url('/assets/images/jovenes-astronomos.jpg'),
    linear-gradient(180deg, #0a0e26 0%, #05060f 100%);
  background-size: cover;
  background-position: center 30%;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 92%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, #000 92%, transparent 100%);
}
.jaf-hero-overlay { position: absolute; inset: 0; pointer-events: none; }
.jaf-hero-content { position: relative; z-index: 2; max-width: 760px; }
.jaf-eyebrow {
  font-family: var(--f-mono);
  font-size: 0.8rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold-bright);
  margin-bottom: 18px;
}
.jaf-eyebrow span { color: var(--text-1); }
.jaf-hero-title {
  font-family: var(--f-display);
  font-size: clamp(2.2rem, 5.5vw, 4rem);
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: #fff;
  margin-bottom: 22px;
}
.jaf-hero-sub {
  font-size: clamp(1.05rem, 1.8vw, 1.3rem);
  line-height: 1.6;
  color: var(--text-1);
  max-width: 620px;
  margin-bottom: 18px;
}
.jaf-hero-meta { color: var(--text-0); margin-bottom: 28px; font-size: 1.05rem; }
.jaf-hero-meta strong { color: var(--gold-bright); }

/* ---- SHARED COPY ---- */
.jaf-lead {
  font-size: clamp(1rem, 1.5vw, 1.15rem);
  line-height: 1.75;
  color: var(--text-1);
  max-width: 760px;
  margin: 0 auto 1.1rem;
}
.jaf-intro .section-header { margin-bottom: 40px; }
.jaf-lead-accent { color: var(--gold-bright); font-weight: 500; text-align: center; }
.jaf-obs-inner { max-width: 820px; }
.jaf-obs .jaf-lead { margin-left: 0; }

/* ---- DATOS CLAVE ---- */
.jaf-facts {
  max-width: 820px;
  margin: 48px auto 0;
  display: grid;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.jaf-facts li {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 18px;
  padding: 16px 22px;
  background: var(--bg-2);
}
.jaf-fact-k {
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  padding-top: 2px;
}
.jaf-fact-v { color: var(--text-1); }
.jaf-fact-v strong { color: var(--gold-bright); font-size: 1.1rem; }

/* ---- TRES DÍAS ---- */
.jaf-day-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}
.jaf-day-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
}
.jaf-day-num {
  display: inline-block;
  font-family: var(--f-mono);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold-bright);
  background: var(--gold-soft);
  border: 1px solid var(--gold-soft);
  border-radius: 100px;
  padding: 5px 14px;
  margin-bottom: 16px;
}
.jaf-day-card h3 { font-family: var(--f-display); font-size: 1.35rem; color: var(--text-0); margin-bottom: 12px; }
.jaf-day-card p { color: var(--text-2); line-height: 1.7; font-size: 0.95rem; }

/* ---- INVESTIGACIÓN ---- */
.jaf-research-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}
.jaf-research-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
}
.jaf-research-star { border-color: rgba(212, 166, 75, 0.45); background: var(--gold-soft); }
.jaf-research-badge {
  position: absolute; top: -11px; left: 24px;
  font-family: var(--f-mono); font-size: 0.66rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: #1a1206; background: linear-gradient(135deg, var(--gold), var(--gold-bright));
  border-radius: 100px; padding: 4px 12px;
}
.jaf-research-card h3 { font-family: var(--f-display); font-size: 1.3rem; color: var(--text-0); margin-bottom: 10px; }
.jaf-research-card p { color: var(--text-2); line-height: 1.65; font-size: 0.95rem; }

/* ---- SIGNUP FORM ---- */
.jaf-cupos-line strong { color: var(--gold-bright); }
.jaf-signup-wrap { max-width: 720px; margin: 0 auto; }
.jaf-form {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(24px, 4vw, 40px);
}
.jaf-fieldset { border: none; margin-bottom: 28px; }
.jaf-fieldset legend {
  font-family: var(--f-mono);
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 16px;
  width: 100%;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}
.jaf-radio-row { display: flex; gap: 18px; padding-top: 8px; flex-wrap: wrap; }
.jaf-radio, .jaf-check { display: flex; align-items: flex-start; gap: 10px; color: var(--text-1); font-size: 0.92rem; cursor: pointer; }
.jaf-radio input, .jaf-check input { width: auto; margin-top: 3px; accent-color: var(--gold); flex-shrink: 0; }
.jaf-check { margin-top: 14px; line-height: 1.5; }
.jaf-check a { color: var(--gold-bright); text-decoration: underline; }
/* Sibling-discount verification block (revealed when the checkbox is on) */
.jaf-sibling { margin: 10px 0 4px; padding: 14px 16px; border: 1px solid var(--border); border-radius: var(--radius); background: rgba(255,255,255,.02); }
.jaf-sibling-verify { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 10px; }
.jaf-sibling-status { font-size: 0.88rem; line-height: 1.4; color: var(--text-2); }
.jaf-sibling-status.is-ok { color: var(--green); }
.jaf-sibling-status.is-err { color: var(--red); }
.jaf-pay-summary {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; margin-bottom: 20px;
  background: var(--gold-soft); border: 1px solid rgba(212, 166, 75, 0.3); border-radius: var(--radius);
}
.jaf-pay-summary span { color: var(--text-1); }
.jaf-pay-summary strong { font-family: var(--f-mono); font-size: 1.3rem; color: var(--gold-bright); }
.jaf-form-note { color: var(--text-3); font-size: 0.82rem; text-align: center; margin-top: 12px; }
.jaf-contact-line { color: var(--text-2); font-size: 0.88rem; text-align: center; margin-top: 16px; }
.jaf-contact-line a { color: var(--gold-bright); }
.jaf-ph { color: var(--text-3); }
.jaf-form-status {
  background: rgba(111, 29, 29, 0.3); border: 1px solid rgba(200, 80, 80, 0.4);
  color: #ff9e9e; border-radius: var(--radius); padding: 14px 18px; margin-bottom: 20px; text-align: center;
}
.cf-turnstile { margin: 0 0 18px; }

@media (max-width: 600px) {
  .jaf-facts li { grid-template-columns: 1fr; gap: 4px; }
  /* Hero text sat too low: shorten the hero and centre the content so it
     rides higher instead of being pinned to the bottom of an 82vh block. */
  .jaf-hero {
    min-height: clamp(460px, 68vh, 600px);
    align-items: center;
    padding-block: clamp(28px, 8vw, 56px);
  }
}
