@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@400;500;600;700;800;900&family=Outfit:wght@200;300;400;500;600;700&display=swap');

:root {
  --night: #030610;
  --night-deep: #010308;
  --night-light: #0d1222;
  --gold: #d4af37;
  --gold-bright: #ffd700;
  --gold-glow: rgba(212, 175, 55, 0.25);
  --coral: #e76f51;
  --coral-glow: rgba(231, 111, 81, 0.35);
  --ink: #f0f4f8;
  --muted: #a0aec0;
  --glass-bg: rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.08);
  --line: rgba(212, 175, 55, 0.15);
}

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

html {
  scroll-behavior: smooth;
  background-color: var(--night-deep);
}

body {
  background: 
    radial-gradient(circle at 80% 20%, rgba(130, 150, 201, 0.12) 0%, transparent 50%),
    radial-gradient(circle at 20% 80%, rgba(212, 175, 55, 0.06) 0%, transparent 60%),
    radial-gradient(circle at 50% 50%, var(--night-light) 0%, var(--night) 70%, var(--night-deep) 100%);
  color: var(--ink);
  font-family: 'Outfit', sans-serif;
  font-weight: 300;
  line-height: 1.7;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6, .back-link, .eyebrow, .badge, .myth-card h3, .famous-card h3 {
  font-family: 'Cinzel', serif;
  font-weight: 500;
  letter-spacing: 0.05em;
}

/* Header */
.detail-header {
  height: 90px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 6vw;
  background: rgba(3, 6, 16, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(212, 175, 55, 0.15);
  position: sticky;
  top: 0;
  z-index: 100;
}

.back-link {
  font-size: 0.85rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #c7ccda;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all 0.3s ease;
  border: 1px solid var(--glass-border);
  padding: 0.6rem 1.2rem;
  border-radius: 4px;
  background: var(--glass-bg);
}

.back-link:hover {
  color: var(--gold-bright);
  border-color: var(--gold-bright);
  box-shadow: 0 0 15px var(--gold-glow);
  transform: translateX(-3px);
}

.detail-logo {
  font-size: 0.95rem;
  letter-spacing: 0.2em;
  font-weight: 700;
  text-decoration: none;
  color: var(--ink);
}

.detail-logo span {
  color: var(--gold);
}

/* Hero Section */
.detail-hero {
  padding: 6rem 6vw 4rem;
  position: relative;
  overflow: hidden;
  text-align: center;
  border-bottom: 1px solid var(--line);
  background: radial-gradient(circle at center, rgba(212, 175, 55, 0.05) 0%, transparent 60%);
}

.detail-starfield {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, #fff 0 1px, transparent 1.2px);
  background-size: 140px 140px;
  opacity: 0.15;
  pointer-events: none;
}

.hero-glyph {
  font-size: 8.5rem;
  line-height: 1;
  display: inline-block;
  margin-bottom: 1.5rem;
  text-shadow: 0 0 40px var(--accent-glow);
  animation: pulse-glow 3s infinite alternate;
}

.detail-hero h1 {
  font-size: clamp(2.8rem, 6vw, 5rem);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.5rem;
  background: linear-gradient(135deg, #ffffff 0%, #ffeaa7 30%, #e2b93c 70%, #906602 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 4px 15px rgba(0, 0, 0, 0.4));
}

.hero-motto {
  font-size: 1.4rem;
  font-style: italic;
  color: var(--gold);
  margin-bottom: 2rem;
  font-family: 'Cinzel', serif;
}

.badges {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  max-width: 800px;
  margin: 0 auto;
}

.badge {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  padding: 0.5rem 1.2rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--glass-border);
  border-radius: 30px;
  color: #cbd5e0;
}

.badge.accent-badge {
  border-color: var(--accent-color);
  background: color-mix(in srgb, var(--accent-color), transparent 94%);
  color: var(--accent-color);
  font-weight: 600;
}

/* Content Grid */
.detail-main {
  padding: 6rem 6vw;
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 4rem;
}

/* Sections */
.detail-section {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 4vw;
  align-items: start;
  border-bottom: 1px solid var(--line);
  padding-bottom: 4rem;
}

.detail-section:last-of-type {
  border-bottom: 0;
  padding-bottom: 0;
}

.section-sidebar {
  position: sticky;
  top: 130px;
}

.section-sidebar h2 {
  font-size: 2.2rem;
  text-transform: uppercase;
  margin-bottom: 1rem;
  color: var(--ink);
  line-height: 1.1;
}

.section-sidebar p {
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.6;
}

.section-content {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  padding: 3.5rem;
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.section-content h3 {
  font-size: 1.8rem;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  color: var(--gold);
}

.section-content p {
  margin-bottom: 1.5rem;
  color: #cbd5e1;
}

.section-content p:last-child {
  margin-bottom: 0;
}

/* Trait List */
.trait-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-top: 2rem;
}

.trait-card {
  background: rgba(255, 255, 255, 0.015);
  border: 1px solid rgba(255, 255, 255, 0.04);
  padding: 1.8rem;
  border-radius: 6px;
}

.trait-card h4 {
  font-family: 'Cinzel', serif;
  font-size: 1.1rem;
  color: var(--gold);
  margin-bottom: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.trait-card p {
  font-size: 0.9rem;
  color: #a0aec0;
  margin: 0;
}

.trait-card.shadow-card h4 {
  color: var(--coral);
}

/* Decan Block */
.decan-block {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}

.decan-card {
  padding: 1.8rem;
  background: rgba(3, 6, 16, 0.4);
  border: 1px solid var(--line);
  border-radius: 4px;
  text-align: center;
}

.decan-card span {
  font-family: 'Cinzel', serif;
  font-size: 0.8rem;
  color: var(--coral);
  letter-spacing: 0.15em;
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
}

.decan-card h4 {
  font-family: 'Cinzel', serif;
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  color: var(--ink);
}

.decan-card p {
  font-size: 0.85rem;
  color: #a0aec0;
  margin: 0;
  line-height: 1.6;
}

/* Myth Card */
.myth-container {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 2.5rem;
}

.tarot-box {
  background: radial-gradient(circle at center, rgba(212, 175, 55, 0.08) 0%, transparent 80%);
  border: 1px dashed var(--line);
  padding: 2.5rem;
  border-radius: 6px;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.tarot-symbol {
  font-size: 3.5rem;
  color: var(--gold);
  margin-bottom: 1rem;
}

.tarot-box h4 {
  font-family: 'Cinzel', serif;
  font-size: 1.2rem;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
  color: var(--ink);
}

.tarot-box p {
  font-size: 0.85rem;
  color: #a0aec0;
  margin: 0;
}

/* Famous People Grid */
.famous-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.famous-card {
  padding: 1.5rem;
  background: rgba(255, 255, 255, 0.01);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 4px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.famous-card h4 {
  font-family: 'Outfit', sans-serif;
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--gold-bright);
}

.famous-card span {
  font-size: 0.85rem;
  color: var(--muted);
}

/* Compatibility Matrix */
.compatibility-list {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1.5rem;
  margin-top: 2rem;
}

.comp-card {
  padding: 1.5rem;
  border-radius: 4px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.04);
}

.comp-card.high {
  background: rgba(6, 214, 160, 0.03);
  border-color: rgba(6, 214, 160, 0.15);
}

.comp-card.neutral {
  background: rgba(255, 209, 102, 0.03);
  border-color: rgba(255, 209, 102, 0.15);
}

.comp-card.low {
  background: rgba(239, 71, 111, 0.03);
  border-color: rgba(239, 71, 111, 0.15);
}

.comp-card h4 {
  font-family: 'Cinzel', serif;
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
}

.comp-card.high h4 { color: #06d6a0; }
.comp-card.neutral h4 { color: #ffd166; }
.comp-card.low h4 { color: #ef476f; }

.comp-card p {
  font-size: 0.85rem;
  color: #cbd5e0;
  margin: 0;
}

/* Buttons in details */
.text-link {
  border: 1px solid rgba(212, 175, 55, 0.3);
  padding: 0.9rem 1.8rem;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(5px);
  transition: all 0.3s ease;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  text-decoration: none;
}

.text-link:hover {
  background: rgba(212, 175, 55, 0.1);
  border-color: var(--gold-bright);
  color: var(--gold-bright);
  box-shadow: 0 0 20px rgba(212, 175, 55, 0.2);
  transform: translateY(-2px);
}

/* Footer style in detail */
.detail-footer {
  padding: 4rem 6vw;
  background: #020409;
  border-top: 1px solid rgba(212, 175, 55, 0.12);
  text-align: center;
}

.detail-footer p {
  font-size: 0.85rem;
  color: #586175;
}

/* Animations */
@keyframes pulse-glow {
  0% {
    transform: scale(1);
    text-shadow: 0 0 30px var(--accent-glow);
  }
  100% {
    transform: scale(1.03);
    text-shadow: 0 0 50px var(--accent-glow), 0 0 10px var(--accent-color);
  }
}

/* Responsive */
@media(max-width: 1050px) {
  .detail-section {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding-bottom: 3rem;
  }
  .section-sidebar {
    position: static;
  }
  .section-content {
    padding: 2rem;
  }
}

@media(max-width: 768px) {
  .detail-header {
    height: 80px;
    padding: 0 1.5rem;
  }
  .detail-hero {
    padding: 4rem 1.5rem 3rem;
  }
  .hero-glyph {
    font-size: 6.5rem;
  }
  .detail-main {
    padding: 4rem 1.5rem;
    gap: 3rem;
  }
  .detail-section,
  .section-sidebar,
  .section-content,
  .trait-grid,
  .decan-block,
  .myth-container,
  .famous-grid,
  .compatibility-list,
  .resonance-grid {
    min-width: 0;
    max-width: 100%;
  }
  .detail-hero h1,
  .section-sidebar h2,
  .section-content h3,
  .section-content p,
  .trait-card,
  .decan-card,
  .comp-card {
    overflow-wrap: anywhere;
  }
  .trait-grid, .decan-block, .myth-container, .famous-grid, .compatibility-list, .resonance-grid {
    grid-template-columns: 1fr !important;
  }
  .myth-container {
    gap: 1.5rem;
  }
  .tarot-box {
    padding: 2rem;
    order: -1;
  }
}

@media(max-width: 480px) {
  .detail-header {
    padding: 0 1rem;
    gap: 0.65rem;
  }
  .back-link {
    min-height: 44px;
    padding: 0.5rem 0.65rem;
    gap: 6px;
    font-size: 0.7rem;
    letter-spacing: 0.08em;
    white-space: nowrap;
  }
  .detail-logo {
    min-height: 44px;
    display: flex;
    align-items: center;
    font-size: 0.78rem;
    letter-spacing: 0.1em;
    white-space: nowrap;
  }
  .detail-hero {
    padding: 3.25rem 1rem 2.5rem;
  }
  .hero-glyph {
    font-size: 5.25rem;
  }
  .detail-hero h1 {
    font-size: clamp(2rem, 12vw, 2.65rem);
    letter-spacing: 0.06em;
    line-height: 1.15;
  }
  .hero-motto {
    font-size: 1.05rem;
  }
  .badge {
    max-width: 100%;
    padding: 0.5rem 0.85rem;
    letter-spacing: 0.1em;
    overflow-wrap: anywhere;
  }
  .detail-main {
    padding: 3rem 1rem;
    gap: 2.5rem;
  }
  .section-sidebar h2 {
    font-size: 1.75rem;
  }
  .section-content {
    padding: 1.35rem;
  }
  .section-content h3 {
    font-size: 1.4rem;
  }
  .trait-card,
  .decan-card,
  .tarot-box,
  .comp-card {
    padding: 1.25rem;
  }
}

/* ==========================================
   ZODIAC HUB SECTIONS
   ========================================== */
.zodiac-hub-section {
  padding: 3rem 1.5rem;
  border-top: 1px solid var(--line);
  background: rgba(3, 6, 16, 0.4);
}
.zodiac-link-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}
.zodiac-mini-card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 1.2rem 1.5rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  color: #fff;
  text-decoration: none;
  transition: all 0.3s ease;
}
.zodiac-mini-card:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--gold-glow);
  box-shadow: 0 4px 15px rgba(255, 215, 0, 0.1);
  transform: translateY(-2px);
}
.zodiac-mini-card span.hub-label {
  font-size: 0.75rem;
  color: var(--muted);
  margin-bottom: 0.4rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.zodiac-mini-card span.hub-title {
  font-weight: 500;
  font-size: 1.05rem;
  font-family: 'Cinzel', serif;
}
.zodiac-cta-panel {
  padding: 4rem 1.5rem;
  background: linear-gradient(135deg, rgba(3, 6, 16, 0.9) 0%, rgba(10, 15, 30, 0.95) 100%);
  border: 1px solid var(--gold-glow);
  border-radius: 12px;
  margin: 3rem 0;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
  text-align: center;
}
