/* ============================================
   Section Styles — Hero, Synopsis, Characters,
   Hidden Agendas, Allegiance, Structure, etc.
   ============================================ */

/* --- Hero --- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 80px;
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background:
    radial-gradient(ellipse at 78% 45%, var(--humanoid-bg) 0%, transparent 55%),
    radial-gradient(ellipse at 20% 55%, var(--human-bg) 0%, transparent 50%);
  pointer-events: none;
  z-index: 0;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle 420px at var(--cursor-x, 82%) var(--cursor-y, 45%),
      rgba(46, 107, 104, 0.08) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
  transition: background 0.15s ease-out;
}

.hero-content {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 60px;
  align-items: center;
}

.hero-text h1 { margin-bottom: 18px; }

.hero-text h1 .human {
  color: var(--human);
  font-style: italic;
}

.hero-text h1 .humanoid-text { color: var(--humanoid); }

.hero-subtitle {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  color: var(--text-muted);
  letter-spacing: 2px;
  margin-bottom: 22px;
}

.hero-tagline {
  font-size: 1.2rem;
  color: var(--text-dim);
  line-height: 1.7;
  max-width: 34rem;
  margin-bottom: 32px;
}

.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-visual img { max-width: 100%; height: auto; }

/* --- Synopsis --- */
.synopsis-text {
  max-width: 1000px;
  margin: 0 auto;
  font-size: 1.15rem;
  line-height: 1.85;
  color: var(--text-dim);
  text-align: left;
  padding: 28px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  position: relative;
}

/* --- Character Grid --- */
.char-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 22px;
}

.char-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 24px;
  transition: all var(--speed);
  position: relative;
  overflow: hidden;
}

.char-card:hover {
  border-color: var(--human);
  box-shadow: 0 12px 30px rgba(28, 27, 24, 0.06);
}

.char-card.humanoid-card:hover { border-color: var(--humanoid); }

.char-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 1px;
  padding: 3px 9px;
  border-radius: 999px;
  text-transform: uppercase;
}

.char-badge.single-sex {
  background: var(--human-bg);
  color: var(--human);
  border: 1px solid var(--human-glow);
}

.char-badge.diversity {
  background: var(--humanoid-bg);
  color: var(--humanoid);
  border: 1px solid var(--humanoid-glow);
}

.char-card .card-icon {
  width: 46px;
  height: auto;
  margin-bottom: 14px;
  border-radius: 6px;
}

.char-card h3 {
  font-size: 1.15rem;
  margin-bottom: 2px;
}

.char-card .char-role {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--text-muted);
  letter-spacing: 1px;
  margin-bottom: 14px;
}

.char-card .char-desc {
  font-size: 0.95rem;
  color: var(--text-dim);
  line-height: 1.55;
}

.char-card .char-arc {
  margin-top: 12px;
  padding: 10px 12px;
  background: var(--bg-surface);
  border-radius: 6px;
  font-size: 0.88rem;
  color: var(--text);
  font-style: italic;
  border-left: 2px solid var(--human);
}

/* --- Hidden Agendas (Intrigue Section) --- */
.intrigue-section {
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.intrigue-grid {
  max-width: 820px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.intrigue-arrow {
  font-size: 1.4rem;
  color: var(--humanoid);
  opacity: 0.5;
  line-height: 1;
}

.intrigue-card {
  width: 100%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  transition: box-shadow var(--speed);
}

.intrigue-card:hover { box-shadow: 0 8px 24px rgba(28, 27, 24, 0.05); }

.intrigue-card .intrigue-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  padding: 10px 18px;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
}

.intrigue-card.perception .intrigue-label {
  background: var(--human-bg);
  color: var(--human);
}

.intrigue-card.reality .intrigue-label {
  background: var(--humanoid-bg);
  color: var(--humanoid);
}

.intrigue-card.counterflow .intrigue-label {
  background: var(--bg-elevated);
  color: var(--text);
}

.intrigue-card .intrigue-body { padding: 16px 18px; }

.intrigue-card .intrigue-body p {
  font-size: 1rem;
  color: var(--text-dim);
  line-height: 1.65;
  margin: 0;
}

.intrigue-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
}

.intrigue-item:last-child { border-bottom: none; }

.intrigue-char {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--humanoid);
  white-space: nowrap;
  min-width: 80px;
  padding-top: 2px;
}

.intrigue-action {
  font-size: 0.95rem;
  color: var(--text-dim);
  line-height: 1.5;
}

.intrigue-verdict {
  margin-top: 12px;
  padding: 12px 14px;
  background: var(--humanoid-bg);
  border-radius: 6px;
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.55;
  border-left: 3px solid var(--humanoid);
}

.intrigue-drivers {
  max-width: 720px;
  margin: 48px auto 0;
  text-align: center;
}

.intrigue-drivers h3 {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  margin-bottom: 12px;
  color: var(--text);
}

.intrigue-drivers p {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--text-dim);
}

/* --- Allegiance Axis --- */
.allegiance-axis {
  max-width: 900px;
  margin: 0 auto 48px;
}

.axis-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

.single-sex-label { color: var(--human); }
.diversity-label { color: var(--humanoid); }

.axis-mid {
  color: var(--text-muted);
  font-size: 0.7rem;
}

.axis-bar {
  display: flex;
  height: 6px;
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 28px;
}

.single-sex-track { flex: 2; background: var(--human); opacity: 0.5; }
.swing-track { flex: 0.8; background: var(--text-muted); opacity: 0.3; }
.diversity-track { flex: 2; background: var(--humanoid); opacity: 0.5; }

.axis-body {
  display: grid;
  grid-template-columns: 1fr 1.1fr 1fr;
  gap: 20px;
}

.axis-column h4 {
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 10px;
  letter-spacing: 0.5px;
  color: var(--text);
}

.axis-char {
  font-size: 0.9rem;
  color: var(--text-dim);
  line-height: 1.5;
  padding: 3px 0;
}

.ax-m { color: var(--human); font-weight: 500; }
.ax-w { color: var(--humanoid); font-weight: 500; }
.ax-h { color: #555; font-weight: 500; }

.swing-char {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 12px;
  margin: 6px 0;
}

.ax-note {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-style: italic;
}

.axis-center {
  padding: 0 8px;
  border-left: 1px dashed var(--border);
  border-right: 1px dashed var(--border);
}

/* --- Humanoid Network --- */
.allegiance-network {
  max-width: 900px;
  margin: 0 auto 40px;
  text-align: center;
}

.allegiance-network h3 {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  color: var(--text);
  margin-bottom: 4px;
}

.allegiance-network > p {
  font-size: 0.95rem;
  color: var(--text-dim);
  margin-bottom: 24px;
}

.network-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px;
  text-align: left;
}

.network-node {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 16px;
  transition: border-color var(--speed), box-shadow var(--speed);
}

.network-node:hover { box-shadow: 0 6px 18px rgba(28, 27, 24, 0.05); }

.network-node.awakening {
  border-left: 3px solid var(--human);
  background: linear-gradient(135deg, var(--bg-card) 80%, var(--human-bg));
}

.network-node.protocol {
  border-left: 3px solid var(--humanoid);
  background: linear-gradient(135deg, var(--bg-card) 80%, var(--humanoid-bg));
}

.network-node h4 {
  font-size: 0.75rem;
  font-family: var(--font-mono);
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.node-char {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}

.node-desc {
  font-size: 0.85rem;
  color: var(--text-dim);
  line-height: 1.45;
}

/* --- Allegiance Map --- */
.allegiance-map { text-align: center; }

.allegiance-map img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  border: 1px solid var(--border);
}

/* --- Structure Timeline --- */
.structure-visual { text-align: center; margin-bottom: 32px; }

.structure-visual img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.chapter-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}

.chapter-part {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 18px;
}

.chapter-part .part-number {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-muted);
}

.chapter-part .part-chapters {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 4px 0 8px;
}

.chapter-part .part-title {
  font-size: 1rem;
  color: var(--text);
  margin-bottom: 6px;
}

.chapter-part .part-blurb {
  font-size: 1.0rem;
  color: var(--text-dim);
  line-height: 1.5;
}

/* --- Thematic Core --- */
.thematic-core { text-align: center; }

.thematic-core img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  border: 1px solid var(--border);
}

/* --- Adaptations --- */
.adapt-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.adapt-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 32px 24px;
  text-align: center;
  position: relative;
  transition: all var(--speed);
}

.adapt-card:hover {
  border-color: var(--human);
  box-shadow: 0 12px 30px rgba(28, 27, 24, 0.06);
}

.adapt-card .adapt-icon {
  font-size: 2rem;
  margin-bottom: 14px;
}

.adapt-card h3 { margin-bottom: 8px; }

.adapt-card p {
  font-size: 0.95rem;
  color: var(--text-dim);
  line-height: 1.6;
}

/* --- Call to Action --- */
.cta-section {
  text-align: center;
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.cta-section h2 { margin-bottom: 12px; }

.cta-section h2 .human {
  color: var(--human);
  font-style: italic;
}

.cta-section h2 .humanoid-text { color: var(--humanoid); }

.cta-section p {
  color: var(--text-dim);
  max-width: 560px;
  margin: 0 auto 32px;
}

/* ============================================
   Theme Quad — deep themes panels
   ============================================ */

.theme-quad {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin: 28px 0;
}

.theme-panel {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 24px 28px;
}

.theme-panel h3 {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 560;
  color: var(--text);
  margin-bottom: 12px;
}

.theme-panel h3 .theme-icon {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-muted);
  display: block;
  margin-bottom: 2px;
}

.theme-panel p {
  font-size: 1.15rem;
  line-height: 1.75;
  color: var(--text-dim);
  margin-bottom: 10px;
}

.theme-panel ul {
  list-style: none;
  padding: 0;
}

.theme-panel ul li {
  position: relative;
  padding: 6px 0 6px 20px;
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--text-dim);
}

.theme-panel ul li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--humanoid);
}