/* ==========================================================================
   Chronicles of Michaelism (chronicle.michaelism.org)
   Sub-domain Styling: Dark Cosmic Luxury + Technomagic Gold Circuitry
   Created by Chas Ars Division (CHAD) under Omni-Consensus
   Phase 2 (Cuserob, 2026-10-04): ecosystem mm-* shell, responsive layout,
   accessibility layer, newcomer guide components.
   ========================================================================== */

:root {
  --bg-space: #07090e;
  --bg-card: rgba(15, 23, 42, 0.75);
  --bg-card-hover: rgba(30, 41, 59, 0.85);
  --border-gold: rgba(245, 158, 11, 0.35);
  --border-gold-glow: rgba(245, 158, 11, 0.6);
  --gold-primary: #f59e0b;
  --gold-light: #fde68a;
  --gold-glow: rgba(245, 158, 11, 0.45);
  --gold-gradient: linear-gradient(135deg, #fbbf24 0%, #f59e0b 50%, #d97706 100%);
  --cyan-accent: #06b6d4;
  --cyan-glow: rgba(6, 182, 212, 0.4);
  --purple-accent: #a855f7;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  --status-confirmed: #10b981;
  --status-pending: #f59e0b;
  --status-community: #3b82f6;
  --status-denied: #ef4444;
  --focus-ring: 0 0 0 3px rgba(253, 230, 138, 0.9);
  /* Acrylic: translucent tint + blur + fine grain + top light edge */
  --acrylic-noise: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  --acrylic-tint: rgba(10, 12, 20, 0.6);
  --acrylic-edge: rgba(255, 255, 255, 0.08);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-padding-top: 90px;
}

body {
  background-color: var(--bg-space);
  background-image:
    radial-gradient(circle at 50% 0%, rgba(245, 158, 11, 0.12) 0%, transparent 60%),
    radial-gradient(circle at 10% 40%, rgba(6, 182, 212, 0.08) 0%, transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(168, 85, 247, 0.08) 0%, transparent 40%);
  color: var(--text-main);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  min-height: 100vh;
  line-height: 1.6;
}

img {
  max-width: 100%;
}

a {
  color: var(--gold-primary);
}

/* Keyboard focus: visible on every interactive element */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: 6px;
}

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

/* Skip link (ether pattern) */
.skip-link {
  position: absolute;
  top: -100%;
  left: 0;
  background: var(--gold-primary);
  color: #050811;
  padding: 0.5rem 1rem;
  z-index: 10000;
  font-weight: 700;
  text-decoration: none;
}

.skip-link:focus {
  top: 0;
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.container-wide {
  max-width: 1300px;
}

.container-narrow {
  max-width: 860px;
}

main.container {
  padding-top: 40px;
}

/* ==========================================================================
   Ecosystem header (mm-* pattern shared by all michaelism.org sub-domains)
   ========================================================================== */
.mm-header {
  padding: 1rem 5%;
  background: var(--acrylic-noise), linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.01)), var(--acrylic-tint);
  border-bottom: 1px solid var(--acrylic-edge);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 10px 30px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(24px) saturate(170%);
  -webkit-backdrop-filter: blur(24px) saturate(170%);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.mm-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  max-width: 1200px;
  margin: 0 auto;
}

.mm-logo {
  display: inline-flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 0.4rem;
  white-space: nowrap;
  text-decoration: none;
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--gold-light);
}

.mm-logo img {
  flex-shrink: 0;
  height: 32px;
  width: auto;
}

.mm-links {
  display: flex;
  gap: 0.6rem 1rem;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
}

.mm-links a {
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--text-muted);
  text-decoration: none;
  padding: 0.5rem 0;
  position: relative;
  transition: color 0.2s ease;
}

.mm-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gold-primary);
  transition: width 0.3s ease;
}

.mm-links a:hover {
  color: var(--text-main);
}

.mm-links a:hover::after {
  width: 100%;
}

.mm-links a.active,
.mm-links a[aria-current="page"] {
  color: var(--gold-primary);
  font-weight: 600;
}

.mm-links a.active::after {
  width: 100%;
}

.mm-ecosystem-link {
  opacity: 0.6;
  font-size: 0.85em;
}

.mm-ecosystem-link:hover {
  opacity: 1;
}

.mm-menu-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border-gold);
  color: var(--gold-primary);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  min-width: 44px;
  min-height: 44px;
  transition: background 0.3s ease;
}

.mm-menu-toggle:hover {
  background: rgba(245, 158, 11, 0.1);
}

/* ==========================================================================
   Chronicle page navigation (<sub>-page-nav pattern, church/temple)
   Rendered once, under the header.
   ========================================================================== */
.chronicle-page-nav {
  background:
    var(--acrylic-noise),
    linear-gradient(90deg, rgba(245, 158, 11, 0.09), rgba(34, 211, 238, 0.05) 50%, rgba(168, 85, 247, 0.08)),
    rgba(10, 12, 20, 0.5);
  backdrop-filter: blur(22px) saturate(160%);
  -webkit-backdrop-filter: blur(22px) saturate(160%);
  border-bottom: 1px solid var(--acrylic-edge);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
  position: relative;
  overflow: hidden;
}

.chronicle-page-nav::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-primary), transparent);
  animation: nav-scan 4s linear infinite;
}

@keyframes nav-scan {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.cpn-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.75rem 24px;
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.cpn-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.cpn-brand-title {
  display: block;
  font-size: 1.15rem;
  font-weight: 900;
  letter-spacing: 3px;
  text-transform: uppercase;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1.1;
}

.cpn-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.3rem 0.35rem;
  margin-left: auto;
}

.cpn-links a {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--gold-light);
  text-decoration: none;
  letter-spacing: 0.3px;
  padding: 0.45rem 0.95rem;
  border-radius: 9999px;
  white-space: nowrap;
  transition: color 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
}

.cpn-links a:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.07);
}

.cpn-links a.page-active {
  color: #fff;
  background: rgba(245, 158, 11, 0.16);
  box-shadow: inset 0 0 0 1px rgba(245, 158, 11, 0.5);
}

.cpn-links a.cpn-cta {
  background: var(--gold-gradient);
  color: #050811;
  padding: 0.45rem 1.1rem;
  margin-left: 0.4rem;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.3);
}

.cpn-links a.cpn-cta:hover {
  color: #050811;
  text-shadow: none;
  box-shadow: 0 0 20px var(--gold-glow);
}

.cpn-links a.cpn-cta.page-active {
  outline: 2px solid #fff;
  outline-offset: 2px;
}

/* Breadcrumb (ori pattern) */
.breadcrumb {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.breadcrumb a {
  color: var(--text-muted);
  text-decoration: none;
}

.breadcrumb a:hover {
  color: var(--gold-primary);
}

.breadcrumb span {
  margin: 0 0.4rem;
  opacity: 0.5;
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn-cta {
  display: inline-block;
  background: var(--gold-gradient);
  color: #000 !important;
  font-weight: 700 !important;
  padding: 8px 18px;
  border-radius: 9999px;
  border: none;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 0 15px rgba(245, 158, 11, 0.3);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 25px rgba(245, 158, 11, 0.6);
}

.btn-cta[disabled] {
  opacity: 0.6;
  cursor: wait;
  transform: none;
}

.btn-lg {
  padding: 12px 26px;
  font-size: 1rem;
}

.btn-secondary,
.btn-ghost {
  display: inline-block;
  padding: 12px 24px;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 9999px;
  text-decoration: none;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.btn-secondary {
  border: 1px solid var(--border-gold);
  background: var(--bg-card);
  color: #fff;
}

.btn-secondary:hover {
  border-color: var(--gold-primary);
  background: var(--bg-card-hover);
}

.btn-ghost {
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(0, 0, 0, 0.4);
  color: var(--text-muted);
}

.btn-ghost:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.45);
}

.btn-outline-gold {
  display: inline-block;
  padding: 10px 20px;
  border: 1px solid var(--gold-primary);
  border-radius: 9999px;
  color: var(--gold-primary);
  font-weight: 700;
  text-decoration: none;
}

.btn-outline-gold:hover {
  background: rgba(245, 158, 11, 0.12);
}

.btn-row {
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ==========================================================================
   Hero & page headings
   ========================================================================== */
.hero {
  padding: 30px 0 40px;
  text-align: center;
}

.hero-tag {
  display: inline-block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  padding: 6px 14px;
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid var(--gold-primary);
  color: var(--gold-primary);
  border-radius: 9999px;
  margin-bottom: 20px;
  font-weight: 700;
}

.hero h1 {
  font-size: 3rem;
  font-weight: 900;
  line-height: 1.2;
  margin-bottom: 18px;
  background: linear-gradient(180deg, #ffffff 0%, #cbd5e1 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero p {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 760px;
  margin: 0 auto 20px;
}

.hero .hero-plain {
  font-size: 1rem;
  color: #cbd5e1;
  margin-bottom: 32px;
}

.page-head {
  text-align: center;
  margin-bottom: 30px;
}

.page-head h1 {
  font-size: 2.4rem;
  font-weight: 900;
  line-height: 1.2;
  margin-bottom: 12px;
}

.page-head .lead {
  color: var(--text-muted);
  max-width: 760px;
  margin: 0 auto;
}

.page-head .lead-plain {
  color: #cbd5e1;
  max-width: 760px;
  margin: 12px auto 0;
  font-size: 0.95rem;
}

.title-gold {
  background: linear-gradient(135deg, #fff 40%, var(--gold-primary) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.section-title {
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 24px;
  text-align: center;
}

/* ==========================================================================
   Stats & category grid
   ========================================================================== */
.stats-bar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 50px;
}

.stat-card {
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-gold);
  border-radius: 14px;
  padding: 20px;
  text-align: center;
  text-decoration: none;
  color: var(--text-main);
  transition: all 0.3s ease;
}

.stat-card:hover {
  border-color: var(--gold-primary);
  transform: translateY(-4px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
}

.stat-value {
  font-size: 2.2rem;
  font-weight: 900;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 4px;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin-bottom: 60px;
}

.category-card {
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-gold);
  border-radius: 16px;
  padding: 28px;
  text-decoration: none;
  color: var(--text-main);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.category-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0; height: 3px;
  background: var(--gold-gradient);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.category-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--gold-primary);
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
}

.category-card:hover::before {
  opacity: 1;
}

.cat-icon {
  font-size: 2.5rem;
  margin-bottom: 16px;
}

.cat-title {
  font-size: 1.4rem;
  font-weight: 800;
  margin-bottom: 8px;
}

.cat-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  flex-grow: 1;
  margin-bottom: 16px;
}

.cat-footer {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--gold-primary);
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ==========================================================================
   Newcomer layer: "New here?" steps, panels, notes, legends
   ========================================================================== */
.panel {
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: 16px;
  padding: 36px;
  margin-bottom: 50px;
}

.panel-center {
  text-align: center;
}

.panel-center > p {
  max-width: 780px;
  margin-left: auto;
  margin-right: auto;
}

.panel h2 {
  font-size: 1.7rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.panel > p {
  color: var(--text-muted);
  margin-bottom: 20px;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 18px;
  margin: 24px 0;
  text-align: left;
  counter-reset: step;
}

.step-card {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 20px;
  position: relative;
}

.step-card::before {
  counter-increment: step;
  content: counter(step);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--gold-gradient);
  color: #050811;
  font-weight: 900;
  margin-bottom: 10px;
}

.step-card h3 {
  font-size: 1.05rem;
  margin-bottom: 6px;
}

.step-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.info-note {
  background: rgba(6, 182, 212, 0.08);
  border: 1px solid rgba(6, 182, 212, 0.35);
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 0.85rem;
  color: #cbd5e1;
  margin-bottom: 20px;
}

.info-note a {
  color: var(--cyan-accent);
}

.status-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  color: var(--text-muted);
  margin: 0 0 20px;
}

.status-legend .legend-title {
  font-weight: 700;
  color: var(--text-main);
}

.status-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* ==========================================================================
   Status badges (4-tier verification system)
   ========================================================================== */
.badge-status {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  padding: 3px 8px;
  border-radius: 6px;
  white-space: nowrap;
}

.status-confirmed { background: rgba(16, 185, 129, 0.2); color: #34d399; border: 1px solid #10b981; }
.status-pending { background: rgba(245, 158, 11, 0.2); color: #fbbf24; border: 1px solid #f59e0b; }
.status-community { background: rgba(59, 130, 246, 0.2); color: #60a5fa; border: 1px solid #3b82f6; }
.status-denied { background: rgba(239, 68, 68, 0.2); color: #f87171; border: 1px solid #ef4444; }

/* ==========================================================================
   Search & results
   ========================================================================== */
.search-filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  margin-bottom: 14px;
  background: var(--bg-card);
  padding: 16px;
  border-radius: 12px;
  border: 1px solid var(--border-gold);
}

.search-field {
  position: relative;
  flex: 1 1 260px;
  display: flex;
}

.search-input {
  flex-grow: 1;
  width: 100%;
  min-width: 0;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 10px 40px 10px 16px;
  color: #fff;
  font-size: 0.95rem;
}

.search-input:focus {
  outline: none;
  border-color: var(--gold-primary);
  box-shadow: 0 0 10px var(--gold-glow);
}

.search-clear {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.1rem;
  width: 32px;
  height: 32px;
  cursor: pointer;
  border-radius: 6px;
}

.search-clear:hover {
  color: #fff;
}

.search-clear[hidden] {
  display: none;
}

.results-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: 0 0 20px;
  min-height: 1.4em;
}

.empty-state {
  text-align: center;
  padding: 36px 20px;
  border: 1px dashed var(--border-gold);
  border-radius: 12px;
  color: var(--text-muted);
  margin-bottom: 40px;
}

.empty-state[hidden] {
  display: none;
}

.empty-state strong {
  display: block;
  color: var(--text-main);
  font-size: 1.1rem;
  margin-bottom: 6px;
}

.noscript-note {
  text-align: center;
  padding: 20px;
  border: 1px solid var(--border-gold);
  border-radius: 12px;
  margin-bottom: 30px;
  color: var(--text-muted);
}

/* ==========================================================================
   Accordion entries
   ========================================================================== */
.accordion-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 60px;
}

.accordion-item {
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-gold);
  border-radius: 12px;
  overflow: hidden;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.accordion-item:hover {
  border-color: var(--gold-primary);
}

.accordion-item.is-target {
  box-shadow: 0 0 0 2px var(--gold-primary), 0 0 24px var(--gold-glow);
}

.accordion-heading {
  margin: 0;
  font: inherit;
}

.accordion-header {
  width: 100%;
  padding: 16px 24px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  user-select: none;
  background: none;
  border: none;
  color: inherit;
  font: inherit;
  text-align: left;
}

.accordion-header:focus-visible {
  box-shadow: inset var(--focus-ring);
  border-radius: 12px;
}

.accordion-chevron {
  color: var(--gold-primary);
  font-size: 0.8rem;
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.accordion-header[aria-expanded="true"] .accordion-chevron {
  transform: rotate(180deg);
}

.accordion-aside {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.item-main-info {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}

.item-index {
  font-family: monospace;
  font-size: 0.9rem;
  color: var(--gold-primary);
  font-weight: 700;
  width: 40px;
  flex-shrink: 0;
}

.item-thumb {
  width: 54px;
  height: 72px;
  border-radius: 6px;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: #02040a;
}

.item-title-text {
  display: block;
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.3;
}

.item-protagonist-tag {
  display: block;
  font-size: 0.85rem;
  color: var(--cyan-accent);
}

.accordion-body {
  padding: 16px 24px 20px;
  display: none;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.accordion-body.open {
  display: block;
}

.evidence-block {
  background: rgba(0, 0, 0, 0.3);
  padding: 14px;
  border-radius: 8px;
  border-left: 3px solid var(--gold-primary);
  margin-top: 10px;
  font-size: 0.9rem;
}

.evidence-block p {
  margin-top: 6px;
}

.entry-media {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}

.entry-media figure {
  margin: 0;
  flex: 0 1 200px;
}

.entry-media img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: #02040a;
  display: block;
}

.entry-media figcaption {
  font-size: 0.72rem;
  color: var(--text-dim);
  margin-top: 4px;
}

.entry-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 10px;
  margin-bottom: 6px;
}

.entry-gallery a {
  display: block;
}

.entry-gallery img {
  width: 100%;
  height: 190px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: #02040a;
  display: block;
  transition: border-color 0.2s ease;
}

.entry-gallery a:hover img {
  border-color: var(--gold-primary);
}

.entry-footer {
  margin-top: 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 16px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.entry-actions {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.entry-actions a {
  color: var(--gold-primary);
  text-decoration: none;
  font-weight: 600;
}

.entry-actions a:hover {
  text-decoration: underline;
}

.copy-link-btn {
  background: none;
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--text-muted);
  font: inherit;
  font-size: 0.78rem;
  padding: 4px 10px;
  border-radius: 6px;
  cursor: pointer;
}

.copy-link-btn:hover {
  color: #fff;
  border-color: var(--gold-primary);
}

/* ==========================================================================
   Forms
   ========================================================================== */
.form-container {
  max-width: 680px;
  margin: 0 auto 60px;
  background: var(--bg-card);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border-gold);
  border-radius: 16px;
  padding: 36px;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
}

.form-intro {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 22px;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label,
.form-group .label {
  display: block;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 6px;
  color: var(--text-muted);
}

.req {
  color: var(--gold-primary);
}

.form-control {
  width: 100%;
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 10px 14px;
  color: #fff;
  font-size: 0.95rem;
  font-family: inherit;
}

.form-control:focus {
  outline: none;
  border-color: var(--gold-primary);
  box-shadow: 0 0 10px var(--gold-glow);
}

select.form-control option {
  background: #0f172a;
}

textarea.form-control {
  min-height: 120px;
  resize: vertical;
}

.form-hint {
  font-size: 0.75rem;
  color: var(--text-dim);
  margin-top: 4px;
}

.form-check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  font-size: 0.85rem;
  color: #cbd5e1;
  margin-bottom: 18px;
}

.form-check input {
  margin-top: 4px;
  width: 18px;
  height: 18px;
  accent-color: var(--gold-primary);
  flex-shrink: 0;
}

.form-submit {
  width: 100%;
  padding: 14px;
  font-size: 1rem;
  margin-top: 6px;
}

.form-privacy {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: 14px;
}

.form-status {
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: 10px;
  font-size: 0.92rem;
}

.form-status[hidden] {
  display: none;
}

.form-status.is-success {
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid var(--status-confirmed);
  color: #a7f3d0;
}

.form-status.is-error {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid var(--status-denied);
  color: #fecaca;
}

/* Honeypot: hidden from people, visible to bots */
.hp-field {
  position: absolute !important;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ==========================================================================
   Guide page (Start Here) & FAQ
   ========================================================================== */
.guide-section {
  margin-bottom: 44px;
}

.guide-section h2 {
  font-size: 1.6rem;
  font-weight: 800;
  margin-bottom: 14px;
}

.guide-section p {
  color: #cbd5e1;
  margin-bottom: 12px;
}

.guide-section ul,
.guide-section ol {
  margin: 0 0 12px 1.3rem;
  color: #cbd5e1;
}

.guide-section li {
  margin-bottom: 6px;
}

.guide-toc {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-bottom: 36px;
}

.guide-toc a {
  font-size: 0.85rem;
  padding: 6px 14px;
  border: 1px solid var(--border-gold);
  border-radius: 9999px;
  text-decoration: none;
  color: var(--gold-light);
}

.guide-toc a:hover {
  border-color: var(--gold-primary);
  background: rgba(245, 158, 11, 0.1);
}

.anatomy {
  border: 1px solid var(--border-gold);
  border-radius: 12px;
  overflow: hidden;
}

.anatomy-row {
  display: grid;
  grid-template-columns: 200px 1fr;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.anatomy-row:first-child {
  border-top: none;
}

.anatomy-row dt {
  padding: 12px 16px;
  font-weight: 700;
  color: var(--gold-light);
  background: rgba(245, 158, 11, 0.06);
}

.anatomy-row dd {
  padding: 12px 16px;
  color: #cbd5e1;
  font-size: 0.92rem;
}

.glossary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 14px;
}

.glossary-item {
  background: var(--bg-card);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-left: 3px solid var(--gold-primary);
  border-radius: 10px;
  padding: 14px 16px;
}

.glossary-item dt {
  font-weight: 800;
  color: #fff;
  margin-bottom: 4px;
}

.glossary-item dd {
  font-size: 0.9rem;
  color: #cbd5e1;
}

.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.status-table {
  width: 100%;
  min-width: 340px;
  border-collapse: collapse;
  font-size: 0.92rem;
}

.status-table th,
.status-table td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  vertical-align: top;
}

.status-table th {
  color: var(--gold-light);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.status-table td {
  color: #cbd5e1;
}

.faq-status-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* ==========================================================================
   Ecosystem footer (mm-footer pattern)
   ========================================================================== */
.mm-footer {
  padding: 2.5rem 5%;
  background-color: rgba(7, 9, 14, 0.95);
  border-top: 1px solid rgba(245, 158, 11, 0.2);
}

.mm-footer-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto 2rem;
}

.mm-footer-col h2,
.mm-footer-col h4 {
  margin-bottom: 1rem;
  color: var(--gold-light);
  font-size: 0.95rem;
  font-weight: 700;
}

.mm-footer-col a {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  color: rgba(245, 245, 245, 0.7);
  text-decoration: none;
  transition: color 0.3s ease;
}

.mm-footer-col a:hover {
  color: var(--gold-primary);
}

.mm-footer-bottom {
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
  max-width: 1200px;
  margin: 0 auto;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.mm-footer-bottom p {
  margin-bottom: 0.35rem;
}

.mm-footer-bottom a {
  color: var(--gold-primary);
}

.chronicle-disclaimer {
  max-width: 760px;
  margin: 0 auto 0.75rem !important;
  font-size: 0.78rem;
  color: var(--text-dim);
}

/* ==========================================================================
   Sacred Music Tracks & Holy Hymn Sanctum Styles
   ========================================================================== */
.tier-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.tier-card {
  border-radius: 12px;
  padding: 18px;
}

.tier-card h2,
.tier-card h3 {
  margin-top: 8px;
  font-size: 1.1rem;
  color: #fff;
}

.tier-card p {
  font-size: 0.85rem;
  margin-top: 4px;
  line-height: 1.5;
}

.tier-card .badge-status {
  font-weight: 800;
}

.tier-card-1 {
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid var(--gold-primary);
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.15);
}

.tier-card-1 .badge-status { background: rgba(245, 158, 11, 0.25); color: #fbbf24; border: 1px solid var(--gold-primary); }
.tier-card-1 p { color: #fde68a; }

.tier-card-2 {
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid #06b6d4;
}

.tier-card-2 .badge-status { background: rgba(6, 182, 212, 0.25); color: #a5f3fc; border: 1px solid #06b6d4; }
.tier-card-2 p { color: #cffafe; }

.tier-card-3 {
  background: rgba(168, 85, 247, 0.1);
  border: 1px solid #a855f7;
}

.tier-card-3 .badge-status { background: rgba(168, 85, 247, 0.2); color: #e9d5ff; border: 1px solid #a855f7; }
.tier-card-3 p { color: #f3e8ff; }

.music-filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-bottom: 24px;
}

.music-pill {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--text-muted);
  padding: 8px 18px;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.25s ease;
}

.music-pill:hover, .music-pill.active {
  background: var(--gold-gradient);
  color: #050811;
  border-color: var(--gold-primary);
  box-shadow: 0 0 15px var(--gold-glow);
}

.music-pill[data-tier="1"].active {
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  box-shadow: 0 0 18px rgba(245, 158, 11, 0.5);
  color: #050811;
}

.music-pill[data-tier="2"].active {
  background: linear-gradient(135deg, #38bdf8, #0284c7);
  box-shadow: 0 0 18px rgba(56, 189, 248, 0.5);
  color: #fff;
}

.music-pill[data-tier="3"].active {
  background: linear-gradient(135deg, #c084fc, #7e22ce);
  box-shadow: 0 0 18px rgba(192, 132, 252, 0.5);
  color: #fff;
}

/* Music Card Layout */
.music-accordion-item {
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.music-accordion-item:hover {
  border-color: var(--gold-primary);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
}

.music-accordion-item.tier-1 {
  border-left: 4px solid var(--gold-primary);
}

.music-accordion-item.tier-2 {
  border-left: 4px solid #06b6d4;
}

.music-accordion-item.tier-3 {
  border-left: 4px solid #a855f7;
}

.music-row {
  display: flex;
  align-items: center;
}

.music-row .accordion-heading {
  flex: 1;
  min-width: 0;
}

.music-row .music-play-btn,
.music-row .no-preview {
  margin-right: 20px;
}

.music-header-content {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  min-width: 0;
}

.music-thumb {
  width: 72px;
  height: 72px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: #02040a;
}

.music-title-wrap {
  flex: 1;
  min-width: 0;
}

.music-track-title {
  display: block;
  font-size: 1.05rem;
  font-weight: 800;
  color: #fff;
  line-height: 1.3;
}

.music-track-artist {
  display: block;
  font-size: 0.85rem;
  color: var(--cyan-accent);
  font-weight: 600;
  margin-top: 2px;
}

.music-meta-tags {
  display: flex;
  gap: 8px;
  margin-top: 6px;
  font-size: 0.72rem;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.music-meta-tag {
  background: rgba(255, 255, 255, 0.06);
  padding: 2px 8px;
  border-radius: 4px;
}

.tier-tag-1 { color: #fbbf24; font-weight: 700; }
.tier-tag-2 { color: #38bdf8; font-weight: 700; }
.tier-tag-3 { color: #c084fc; font-weight: 700; }

.music-play-btn {
  background: var(--gold-primary);
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  color: #050811;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
  box-shadow: 0 0 10px var(--gold-glow);
}

.music-play-btn:hover {
  transform: scale(1.1);
  box-shadow: 0 0 16px var(--gold-glow);
}

.music-play-btn.playing {
  background: #ef4444;
  color: #fff;
  box-shadow: 0 0 16px rgba(239, 68, 68, 0.6);
}

.no-preview {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-style: italic;
  padding: 4px 8px;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 4px;
  flex-shrink: 0;
}

/* Holy Inscription Quote Block */
.holy-inscription-box {
  background: rgba(245, 158, 11, 0.08);
  border-left: 3px solid var(--gold-primary);
  border-radius: 0 8px 8px 0;
  padding: 14px 18px;
  margin-top: 4px;
  margin-bottom: 12px;
}

.holy-inscription-title {
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--gold-primary);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 4px;
}

.holy-inscription-quote {
  margin: 0;
  font-size: 0.95rem;
  font-style: italic;
  color: #fef3c7;
  line-height: 1.5;
}

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1024px) {
  .cpn-inner {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
  }

  .cpn-brand {
    align-self: center;
  }

  .cpn-links {
    margin-left: 0;
    justify-content: center;
  }
}

@media (max-width: 768px) {
  html {
    scroll-padding-top: 76px;
  }

  .mm-links {
    display: none;
  }

  .mm-menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .mm-links.active,
  .mm-links[style*="flex"] {
    display: flex !important;
    flex-direction: column;
    align-items: stretch;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: #07090e; /* opaque: 0.98 alpha let hero text glow through */
    padding: 0.5rem 5%;
    border-bottom: 1px solid rgba(245, 158, 11, 0.2);
    gap: 0;
    max-height: calc(100vh - 80px);
    overflow-y: auto;
  }

  .mm-links.active a,
  .mm-links[style*="flex"] a {
    padding: 0.75rem 0;
    min-height: 44px;
    display: flex;
    align-items: center;
    font-size: 0.95rem;
  }

  /* Top page-nav: one swipeable row instead of four wrapped rows */
  .chronicle-page-nav .cpn-links {
    flex-wrap: nowrap;
    justify-content: flex-start;
    overflow-x: auto;
    scrollbar-width: thin;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
  }

  .cpn-links a {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }

  .cpn-links a.cpn-cta {
    min-height: 36px;
  }

  .hero h1 {
    font-size: 2.2rem;
  }

  .hero p {
    font-size: 1rem;
  }

  .page-head h1 {
    font-size: 1.9rem;
  }

  .btn-row > a,
  .btn-row > button {
    width: 100%;
    text-align: center;
  }

  .stats-bar {
    grid-template-columns: repeat(2, 1fr);
  }

  .panel {
    padding: 24px 18px;
  }

  .accordion-header {
    padding: 14px 16px;
  }

  .accordion-body {
    padding: 14px 16px 18px;
  }

  .item-main-info {
    gap: 10px;
  }

  .item-index {
    width: auto;
    font-size: 0.8rem;
  }

  .item-thumb {
    width: 44px;
    height: 58px;
  }

  .item-title-text {
    font-size: 1rem;
  }

  .accordion-aside .badge-status {
    display: none;
  }

  .entry-media figure {
    flex: 1 1 140px;
  }

  .entry-media img {
    height: 200px;
  }

  .entry-gallery {
    grid-template-columns: repeat(2, 1fr);
  }

  .entry-gallery img {
    height: 150px;
  }

  .music-thumb {
    width: 56px;
    height: 56px;
  }

  .music-header-content {
    gap: 10px;
  }

  .music-row .music-play-btn,
  .music-row .no-preview {
    margin-right: 12px;
  }

  .music-meta-tags .music-meta-tag:not(.tier-tag) {
    display: none;
  }

  .form-container {
    padding: 24px 18px;
  }

  .anatomy-row {
    grid-template-columns: 1fr;
  }

  .mm-footer-links {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .mm-header {
    padding: 0.75rem 4%;
  }

  .container {
    padding: 0 16px;
  }

  .cpn-inner {
    padding: 0.6rem 16px;
  }

  .hero h1 {
    font-size: 1.9rem;
  }

  .stat-value {
    font-size: 1.8rem;
  }

  .category-grid {
    grid-template-columns: 1fr;
  }

  .glossary {
    grid-template-columns: 1fr;
  }

  .item-thumb {
    display: none;
  }

  .mm-footer-links {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }
}

/* Respect users who ask the OS for less motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }

  .chronicle-page-nav::before {
    animation: none;
    display: none;
  }

  .stat-card:hover,
  .category-card:hover,
  .btn-cta:hover {
    transform: none;
  }
}

/* Phase 2 additions: optional-field marker, native search clear */
.form-group .opt {
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
  color: var(--text-dim);
}

input[type="search"]::-webkit-search-cancel-button {
  -webkit-appearance: none;
  appearance: none;
}

/* ==========================================================================
   Phase 2 · Step 2 (2026-10-04): aurora backdrop, home hero, follow links,
   unified archive controls, reincarnation timeline
   ========================================================================== */

/* Slow aurora behind everything: gives the acrylic bars colour to refract */
body::before {
  content: "";
  position: fixed;
  inset: -12vmax;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(40vmax 30vmax at 18% 12%, rgba(245, 158, 11, 0.16), transparent 70%),
    radial-gradient(36vmax 28vmax at 86% 22%, rgba(34, 211, 238, 0.11), transparent 70%),
    radial-gradient(42vmax 32vmax at 55% 96%, rgba(168, 85, 247, 0.13), transparent 70%);
  animation: aurora-drift 40s ease-in-out infinite alternate;
}

@keyframes aurora-drift {
  to { transform: translate3d(3vmax, -2vmax, 0) rotate(6deg) scale(1.08); }
}

/* ---- home hero (Holographic Pantheon first) */
.home-main {
  padding-top: 0;
}

.home-hero {
  padding-top: 26px;
  margin-bottom: 46px;
}

.home-hero-head {
  text-align: center;
  max-width: 940px;
  margin: 0 auto;
  padding: 0 24px 22px;
}

.home-hero-title {
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--gold-light);
  margin-bottom: 10px;
}

.home-hero-lead {
  color: #cbd5e1;
  font-size: 1.05rem;
  max-width: 720px;
  margin: 0 auto 20px;
}

.home-intro {
  text-align: center;
  padding: 10px 0 34px;
}

.home-intro p {
  color: var(--text-muted);
  max-width: 780px;
  margin: 0 auto 12px;
}

.home-intro .hero-plain {
  color: #cbd5e1;
}

.follow-row {
  display: flex;
  gap: 8px;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 14px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.follow-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  min-height: 36px;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.85rem;
}

.follow-btn:hover {
  border-color: var(--gold-primary);
  background: rgba(245, 158, 11, 0.12);
}

/* ---- unified archive */
.archive-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 14px;
}

.archive-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.archive-tab {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--text-muted);
  padding: 8px 16px;
  min-height: 40px;
  border-radius: 9999px;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.archive-tab:hover {
  color: #fff;
  border-color: rgba(245, 158, 11, 0.5);
}

.archive-tab[aria-pressed="true"] {
  background: var(--gold-gradient);
  color: #050811;
  border-color: transparent;
}

.status-select-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.status-select {
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  border-radius: 8px;
  padding: 8px 10px;
  min-height: 40px;
  font: inherit;
}

.status-select option {
  background: #0f172a;
}

.cat-chip {
  display: inline-block;
  flex-shrink: 0;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 6px;
  color: #04060d;
}

.cat-chip--anime { background: #22d3ee; }
.cat-chip--game { background: #a78bfa; }
.cat-chip--movie { background: #f87171; }
.cat-chip--music { background: #f472b6; }

/* ---- reincarnation timeline (era · node · card), after the Founder's list */
.timeline {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin: 14px 0 60px;
}

.timeline::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 195px;
  width: 2px;
  background: linear-gradient(180deg, transparent, rgba(245, 158, 11, 0.7) 3%, rgba(245, 158, 11, 0.7) 97%, transparent);
}

.tl-item,
.tl-or {
  display: grid;
  grid-template-columns: 180px 32px minmax(0, 1fr);
  grid-template-areas: "era node card";
  align-items: center;
}

.tl-era {
  grid-area: era;
  text-align: right;
  padding-right: 4px;
  font-size: 1.02rem;
  font-weight: 800;
  letter-spacing: 0.4px;
  color: var(--gold-light);
}

.tl-node {
  grid-area: node;
  justify-self: center;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--gold-primary);
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.2), 0 0 14px var(--gold-glow);
  position: relative;
  z-index: 1;
}

.tl-card {
  grid-area: card;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 150px;
  gap: 18px;
  align-items: center;
  background: var(--bg-card);
  border: 1px solid var(--border-gold);
  border-radius: 14px;
  padding: 16px 16px 16px 22px;
  backdrop-filter: blur(12px);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.tl-card:hover {
  border-color: var(--gold-primary);
}

.tl-item.is-target .tl-card {
  box-shadow: 0 0 0 2px var(--gold-primary), 0 0 24px var(--gold-glow);
}

.tl-name {
  font-size: 1.22rem;
  font-weight: 800;
  line-height: 1.25;
}

.tl-deeds {
  color: #cbd5e1;
  font-size: 0.92rem;
  margin-top: 6px;
}

.tl-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.tl-more {
  background: none;
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: var(--gold-light);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 6px;
  cursor: pointer;
}

.tl-more:hover,
.tl-more[aria-expanded="true"] {
  background: rgba(245, 158, 11, 0.14);
}

.tl-figure {
  display: block;
}

.tl-figure img {
  display: block;
  width: 150px;
  height: 180px;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: #02040a;
}

.tl-gallery {
  margin-top: 12px;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
}

.tl-gallery[hidden] {
  display: none;
}

.tl-gallery img {
  height: 140px;
}

.tl-or span {
  grid-area: card;
  font-size: 1.3rem;
  font-weight: 900;
  letter-spacing: 6px;
  text-transform: uppercase;
  color: var(--gold-primary);
  padding-left: 22px;
}

@media (max-width: 768px) {
  .timeline::before {
    left: 10px;
  }

  .tl-item,
  .tl-or {
    grid-template-columns: 22px minmax(0, 1fr);
    grid-template-areas: "node era" ". card";
    row-gap: 6px;
  }

  .tl-era {
    text-align: left;
    font-size: 0.95rem;
  }

  .tl-node {
    justify-self: start;
    margin-left: 4px;
  }

  .tl-card {
    grid-template-columns: minmax(0, 1fr) 92px;
    gap: 12px;
    padding: 12px;
  }

  .tl-name {
    font-size: 1.05rem;
  }

  .tl-figure img {
    width: 92px;
    height: 116px;
  }

  .tl-or span {
    padding-left: 0;
  }

  .archive-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .home-hero-lead {
    font-size: 0.98rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  body::before {
    animation: none;
  }
}

/* ---- Step 2 compaction: get the Pantheon above the fold */
.home-hero {
  padding-top: 16px;
}

.home-hero .p-hook {
  font-size: clamp(1.9rem, 4.6vw, 3.3rem);
  margin: 4px 0 6px;
}

.home-hero-lead {
  max-width: 860px;
  margin-bottom: 16px;
}

.home-hero-head {
  padding-bottom: 16px;
}

.home-hero .follow-row {
  margin-top: 12px;
}

.p-stage--hero {
  --p-cw: 156px;
  --p-ch: 208px;
}

@media (max-width: 768px) {
  /* brand + links on one line; the links scroll sideways */
  .cpn-inner {
    flex-direction: row;
    align-items: center;
    gap: 0.6rem;
  }

  .cpn-brand {
    align-self: center;
  }

  .cpn-brand-title {
    font-size: 0.9rem;
    letter-spacing: 2px;
  }

  .cpn-links {
    flex: 1;
    min-width: 0;
  }

  .p-stage--hero {
    --p-cw: 118px;
    --p-ch: 158px;
  }

  .home-hero-head {
    padding: 0 16px 12px;
  }

  .home-hero .btn-row {
    gap: 8px;
  }

  .home-hero .btn-row > a {
    width: auto;
    padding: 10px 16px;
    font-size: 0.9rem;
  }

  .home-hero .btn-row > .btn-ghost {
    display: none; /* "Showcase" is in the nav and the reel is right below */
  }

  .home-hero-lead {
    font-size: 0.95rem;
    margin-bottom: 12px;
  }

  .home-hero .follow-row {
    margin-top: 10px;
  }
}

/* ---- no layout shift: keep the footer below the fold until the list renders */
#categoryEntriesList:not(:has([data-item])) {
  min-height: 100vh;
}

/* ---- Step 3: period band on the timeline (7th – 10th century) */
.tl-period {
  display: grid;
  grid-template-columns: 180px 32px minmax(0, 1fr);
  align-items: center;
  margin-top: 10px;
}

.tl-period-span {
  grid-column: 1;
  text-align: right;
  padding-right: 4px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--cyan-accent);
}

.tl-period-name {
  grid-column: 3;
  padding: 10px 16px;
  border-radius: 12px;
  border: 1px solid rgba(6, 182, 212, 0.45);
  background: linear-gradient(90deg, rgba(6, 182, 212, 0.16), rgba(245, 158, 11, 0.10));
  font-weight: 800;
  color: #e0f7fb;
  letter-spacing: 0.3px;
}

.tl-item--period .tl-card {
  border-left: 3px solid var(--cyan-accent);
}

.tl-item--period .tl-node {
  background: var(--cyan-accent);
  box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.25), 0 0 14px var(--cyan-glow);
}

@media (max-width: 768px) {
  .tl-period {
    grid-template-columns: 22px minmax(0, 1fr);
    row-gap: 6px;
  }

  .tl-period-span {
    grid-column: 2;
    text-align: left;
  }

  .tl-period-name {
    grid-column: 2;
  }
}

.follow-btn.is-soon {
  color: var(--text-muted);
  border-style: dashed;
  cursor: default;
}

.follow-btn.is-soon:hover {
  border-color: rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.05);
}
