/* ============================================================
   universe.css — Speculative Worlds (Exploration)
   Component layer for the fiction universes, built on the
   site design tokens in /css/shared.css (load shared.css
   first). Replaces the retired per-universe dark theme.
   ============================================================ */

/* ========== UNIVERSE HERO (landing pages) ========== */
.u-hero {
  background: var(--navy-dark);
  padding: 10rem 2rem 5.5rem;
  position: relative;
  overflow: hidden;
  text-align: center;
}
.u-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(rgba(26,58,138,0.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(26,58,138,0.12) 1px, transparent 1px);
  background-size: 30px 30px;
  opacity: 0.4;
}
.u-hero > * { position: relative; z-index: 1; }
.u-eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--yellow);
  margin-bottom: 1.25rem;
}
.u-hero h1 {
  font-family: 'Playfair Display', serif;
  font-weight: 900;
  color: var(--white);
  font-size: clamp(2.8rem, 7vw, 4.5rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
}
.u-hero h1 em { color: var(--orange); font-style: italic; font-weight: 400; }
.u-hero-sub {
  color: rgba(255,255,255,0.72);
  font-size: 1.08rem;
  line-height: 1.7;
  max-width: 580px;
  margin: 0 auto 2.5rem;
}
.u-ctas { display: flex; gap: 0.8rem; flex-wrap: wrap; justify-content: center; }
.u-ctas a {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 0.7rem 1.6rem;
  border-radius: 100px;
  text-decoration: none;
  color: rgba(255,255,255,0.85);
  border: 1px solid rgba(255,255,255,0.3);
  transition: all 0.25s ease;
}
.u-ctas a:hover { border-color: var(--yellow); color: var(--yellow); }
.u-ctas a.primary { background: var(--yellow); border-color: var(--yellow); color: var(--navy-dark); }
.u-ctas a.primary:hover { background: #ffd94a; color: var(--navy-dark); }

/* ========== SECTIONS ========== */
.u-section { padding: 4rem 2rem; background: var(--white); }
.u-section.alt { background: var(--grey-light); }
.u-container { max-width: 1100px; margin: 0 auto; }
.u-narrow { max-width: 680px; margin: 0 auto; }
.u-wide { max-width: 1100px; margin: 0 auto; padding: 3.5rem 2rem 4rem; }
.u-label {
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}
.u-section h2 {
  font-family: 'Playfair Display', serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--charcoal);
  line-height: 1.2;
  margin-bottom: 1.25rem;
}
.u-lede p {
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--text-body);
  margin-bottom: 1.25rem;
}
.u-lede p:last-child { margin-bottom: 0; }
.u-hr { border: none; height: 1px; background: var(--grey-mid); margin: 2.5rem 0; }

/* ========== STATS ========== */
.u-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 2.5rem;
  justify-content: center;
  margin-top: 2.5rem;
}
.u-stat { text-align: center; }
.u-stat-num {
  font-family: 'Playfair Display', serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--royal);
  line-height: 1.1;
}
.u-stat-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-top: 0.3rem;
}

/* ========== NAV CARDS (landing pages) ========== */
.u-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  margin-top: 2rem;
}
@media (max-width: 720px) { .u-cards { grid-template-columns: 1fr; } }
.u-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--grey-mid);
  border-radius: 12px;
  padding: 1.5rem 1.5rem 1.35rem;
  text-decoration: none;
  color: inherit;
  background: var(--white);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.u-card:hover { transform: translateY(-3px); box-shadow: 0 12px 32px rgba(10,20,40,0.10); border-color: var(--royal); }
.u-card-label {
  align-self: flex-start;
  font-size: 0.64rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--royal);
  background: var(--grey-light);
  padding: 4px 9px;
  border-radius: 4px;
  margin-bottom: 0.85rem;
}
.u-card h3 {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 1.2rem;
  line-height: 1.2;
  color: var(--navy-dark);
  margin-bottom: 0.5rem;
}
.u-card p { color: var(--text-body); font-size: 0.92rem; line-height: 1.6; flex: 1; }
.u-card-footer {
  margin-top: 1rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: var(--royal);
}
.u-card:hover .u-card-footer { color: var(--orange-accessible); }

/* ========== CLOSING QUOTE ========== */
.u-quote { text-align: center; }
.u-quote p {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 1.3rem;
  color: var(--charcoal);
  line-height: 1.6;
  max-width: 580px;
  margin: 0 auto;
}
.u-quote .u-quote-by {
  font-family: 'DM Sans', sans-serif;
  font-style: normal;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 1rem;
  letter-spacing: 0.06em;
}

/* ========== TIMELINE (Executable Minds overview) ========== */
.timeline { position: relative; padding-left: 2.5rem; margin-top: 2.5rem; }
.timeline::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 1px;
  background: var(--grey-mid);
}
.timeline-item { position: relative; margin-bottom: 2rem; }
.timeline-item:last-child { margin-bottom: 0; }
.timeline-item::before {
  content: '';
  position: absolute;
  left: -2.5rem; top: 0.55rem;
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--orange);
  border: 2px solid var(--white);
  margin-left: -4px;
}
.timeline-item .tl-date {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--royal);
  margin-bottom: 0.3rem;
}
.timeline-item h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}
.timeline-item h3 a { color: var(--charcoal); text-decoration: none; }
.timeline-item h3 a:hover { color: var(--royal); }
.timeline-item p { font-size: 0.92rem; color: var(--text-body); line-height: 1.65; }
.timeline-item .tl-location { font-size: 0.82rem; color: var(--text-muted); font-style: italic; margin-bottom: 0.25rem; }

/* ========== CHARACTER CARDS ========== */
.card-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}
@media (max-width: 720px) { .card-grid { grid-template-columns: 1fr; } }
.char-card {
  background: var(--white);
  border: 1px solid var(--grey-mid);
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: border-color 0.3s, box-shadow 0.3s;
}
.char-card:hover { box-shadow: 0 8px 28px rgba(10,20,40,0.10); }
.char-card__head { padding: 1.5rem 1.75rem 1rem; display: flex; gap: 1rem; align-items: flex-start; }
.freq-dot { width: 9px; height: 9px; border-radius: 50%; margin-top: 0.5rem; flex-shrink: 0; }
.char-card__head h4 {
  font-family: 'Playfair Display', serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--charcoal);
  margin-bottom: 0.15rem;
}
.char-card__head .freq-label { font-size: 0.84rem; font-style: italic; color: var(--text-secondary); line-height: 1.45; }
.char-card__hint { padding: 0 1.75rem 1.25rem; font-size: 0.72rem; color: var(--text-muted); }
.char-card.expanded .char-card__hint { display: none; }
.char-card__body { padding: 0 1.75rem 1.5rem; display: none; }
.char-card.expanded .char-card__body { display: block; }
.char-card__body p { font-size: 0.9rem; color: var(--text-body); line-height: 1.65; margin-bottom: 0.8rem; }
.char-card__body .char-quote {
  font-style: italic;
  font-size: 0.95rem;
  color: var(--charcoal);
  border-left: 2px solid var(--grey-mid);
  padding: 0.75rem 1.1rem;
  margin: 1rem 0;
  line-height: 1.55;
  background: var(--grey-light);
  border-radius: 0 8px 8px 0;
}
.char-card__body .appears {
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-top: 0.5rem;
}
.group-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--grey-mid);
  margin-bottom: 1.5rem;
}
.card-grid + .group-label { margin-top: 3rem; }

/* ========== MISC ========== */
.scene-break {
  text-align: center;
  letter-spacing: 0.5em;
  color: var(--text-muted);
  margin: 2.2rem 0;
}
.u-links {
  font-size: 0.82rem;
  color: var(--text-muted);
  text-align: center;
  margin: 1.5rem 0;
}
.u-links a { color: var(--royal-light); text-decoration: none; font-weight: 600; }
.u-links a:hover { color: var(--orange); }
.fade-in { opacity: 0; transform: translateY(14px); transition: opacity 0.6s ease, transform 0.6s ease; }
.fade-in.visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .fade-in { opacity: 1; transform: none; transition: none; }
}
