:root {
  --void: #07050f;
  --deep: #0e0b1e;
  --surface: #13102a;
  --rim: rgba(127,119,221,0.15);
  --rim2: rgba(127,119,221,0.08);
  --purple: #7F77DD;
  --purple-light: #C9A0FF;
  --purple-dim: rgba(127,119,221,0.25);
  --teal: #1D9E75;
  --teal-light: #5DCAA5;
  --amber: #FFB84D;
  --coral: #FF6B4D;
  --pink: #FF5FA0;
  --blue: #5DAFFF;
  --text: #ffffff;
  --text-dim: rgba(255,255,255,0.75);
  --text-muted: rgba(255,255,255,0.55);
  --serif: 'Cormorant Garamond', Georgia, serif;
  --sans: 'Outfit', sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--void);
  color: var(--text);
  font-family: var(--sans);
  font-weight: 300;
  overflow-x: hidden;
  line-height: 1.75;
}

/* ── STARFIELD ── */
#stars {
  position: fixed; inset: 0; z-index: 0;
  pointer-events: none; overflow: hidden;
}
.star {
  position: absolute; border-radius: 50%;
  background: white; animation: twinkle var(--d,4s) ease-in-out infinite var(--dl,0s);
}
@keyframes twinkle {
  0%,100%{opacity:var(--oa,.15)} 50%{opacity:var(--ob,.6)}
}

/* ── NAV ── */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.25rem 3rem;
  border-bottom: 1px solid transparent;
  transition: background .4s, border-color .4s, backdrop-filter .4s;
}
nav.scrolled {
  background: rgba(7,5,15,0.95);
  border-color: var(--rim);
  backdrop-filter: blur(14px);
}
.nav-logo {
  font-family: var(--serif); font-size: 1.5rem; font-weight: 600;
  letter-spacing: .06em; color: var(--purple-light);
  text-decoration: none; animation: slideInLeft .6s ease-out;
}
.nav-links { 
  display: flex; gap: 2rem; list-style: none; 
  transition: all .3s ease;
}
.nav-links a {
  font-size: .8rem; letter-spacing: .12em; text-transform: uppercase;
  color: var(--text); text-decoration: none;
  transition: color .25s, text-shadow .25s;
  position: relative;
  opacity: 0.8;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: -4px; left: 0; width: 0;
  height: 2px; background: var(--purple-light);
  transition: width .3s ease;
}
.nav-links a:hover { 
  color: var(--purple-light); 
  text-shadow: 0 0 8px rgba(175, 169, 236, 0.5);
}
.nav-links a:hover::after { width: 100%; }

/* ── HAMBURGER MENU ── */
.menu-toggle {
  display: none; flex-direction: column; gap: 5px;
  background: none; border: none; cursor: pointer;
  padding: .5rem; z-index: 101;
}
.menu-toggle span {
  width: 24px; height: 2px; background: var(--purple-light);
  border-radius: 1px; transition: all .3s ease;
}
.menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(11px, 11px);
}
.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}
.menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

@media(max-width:600px){
  nav { padding: 1rem 1.5rem; }
  .menu-toggle { display: flex; }
  .nav-links { 
    position: absolute; top: 60px; left: 0; right: 0;
    flex-direction: column; gap: 0; list-style: none;
    background: rgba(7, 5, 15, 0.98);
    border-bottom: 1px solid var(--rim2);
    backdrop-filter: blur(14px);
    max-height: 0; overflow: hidden;
    transition: max-height .3s ease;
  }
  .nav-links.active { max-height: 300px; }
  .nav-links li { 
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--rim2);
  }
  .nav-links a::after { display: none; }
  .nav-links a:hover { color: var(--purple-light); }
}

/* ── HERO ── */
#hero {
  min-height: 100vh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center;
  padding: 6rem 2rem 4rem;
}
@media(max-width:768px) {
  #hero { 
    min-height: auto; 
    padding: 8rem 1.5rem 3rem;
  }
}
.hero-eyebrow {
  font-family: var(--sans); font-size: .72rem; letter-spacing: .28em;
  text-transform: uppercase; color: var(--teal-light);
  margin-bottom: 1.4rem;
  opacity: 0; animation: fadeUp .9s .2s forwards;
}
.hero-title {
  font-family: var(--serif); font-size: clamp(4rem, 10vw, 8.5rem);
  font-weight: 300; line-height: 1; letter-spacing: -.01em;
  color: var(--text);
  opacity: 0; animation: fadeUp .9s .38s forwards;
}
.hero-title em {
  font-style: italic; color: var(--purple-light);
  text-shadow: 0 0 20px rgba(175, 169, 236, 0.4);
  animation: glow 3s ease-in-out infinite;
}
.hero-sub {
  margin-top: 1.8rem;
  font-family: var(--serif); font-size: clamp(1.1rem, 2.5vw, 1.45rem);
  font-style: italic; font-weight: 300; color: var(--text);
  max-width: 640px;
  opacity: 0; animation: fadeUp .9s .56s forwards;
}
.hero-cta {
  margin-top: 3rem; display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center;
  opacity: 0; animation: fadeUp .9s .72s forwards;
}
.btn-primary {
  padding: .75rem 2rem; border-radius: 2rem;
  background: var(--purple); color: #fff;
  font-family: var(--sans); font-size: .82rem; letter-spacing: .1em;
  text-transform: uppercase; text-decoration: none;
  border: none; cursor: pointer;
  transition: all .3s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
}
.btn-primary::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.2) 0%, transparent 100%);
  opacity: 0; transition: opacity .3s;
}
.btn-primary:hover { 
  background: var(--purple-light); 
  transform: translateY(-3px);
  box-shadow: 0 12px 24px rgba(175, 169, 236, 0.3);
}
.btn-primary:hover::before { opacity: 1; }
.btn-primary:active { transform: translateY(-1px); }

.btn-outline {
  padding: .75rem 2rem; border-radius: 2rem;
  border: 1px solid var(--rim); background: transparent;
  color: var(--text);
  font-family: var(--sans); font-size: .82rem; letter-spacing: .1em;
  text-transform: uppercase; text-decoration: none;
  cursor: pointer;
  transition: all .3s ease;
}
.btn-outline:hover { 
  border-color: var(--purple); 
  color: var(--purple-light); 
  transform: translateY(-3px);
  background: rgba(127, 119, 221, 0.08);
  box-shadow: 0 8px 16px rgba(127, 119, 221, 0.15);
}
.btn-outline:active { transform: translateY(-1px); }

@media(max-width:600px) {
  .btn-primary, .btn-outline {
    padding: .85rem 1.8rem;
    font-size: .75rem;
    min-height: 44px;
  }
}

/* Orbital diagram in hero */
.hero-orb {
  margin-top: 5rem;
  opacity: 0; animation: fadeUp .9s .88s forwards;
  width: 100%; max-width: 520px;
  will-change: transform;
}

@media(max-width:600px) {
  .hero-orb {
    margin-top: 3rem;
    max-width: 320px;
  }
}

/* ── DIVIDER ── */
.divider {
  width: 48px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--purple), transparent);
  margin: 0 auto 3rem;
}

/* ── TRUTH SECTION ── */
.truths-header {
  text-align: center; padding: 6rem 2rem 4rem;
}
.section-label {
  font-size: .72rem; letter-spacing: .28em; text-transform: uppercase;
  color: var(--teal-light); margin-bottom: 1rem;
}
.section-title {
  font-family: var(--serif); font-size: clamp(2.2rem, 5vw, 3.6rem);
  font-weight: 300; color: var(--text);
}

.truths-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5px;
  background: var(--rim2);
  border: 1px solid var(--rim2);
  max-width: 1200px;
  margin: 0 auto;
}

@media(max-width:768px) {
  .truths-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
    border: none;
    background: transparent;
  }
  .truth-card { border-left-width: 4px; }
}
.truth-card {
  background: var(--void);
  padding: 3rem 2.5rem;
  transition: all .35s cubic-bezier(0.34, 1.56, 0.64, 1);
  cursor: default;
  border-left: 3px solid transparent;
  position: relative;
  overflow: hidden;
}
.truth-card::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(175,169,236,0.05) 0%, transparent 100%);
  opacity: 0; transition: opacity .35s;
  pointer-events: none;
}
.truth-card:hover { 
  background: var(--surface);
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(175, 169, 236, 0.15);
}
.truth-card:hover::before { opacity: 1; }
.truth-card.reveal {
  animation: slideUp .7s cubic-bezier(0.34, 1.56, 0.64, 1) backwards;
}
.truth-card:nth-child(1) { animation-delay: 0.1s; }
.truth-card:nth-child(2) { animation-delay: 0.2s; }
.truth-card:nth-child(3) { animation-delay: 0.3s; }
.truth-card:nth-child(4) { animation-delay: 0.4s; }
.truth-card:nth-child(5) { animation-delay: 0.5s; }
.truth-numeral {
  font-family: var(--serif); font-size: 3.5rem; font-weight: 300;
  line-height: 1; color: var(--purple-dim);
  margin-bottom: 1rem;
  display: block;
}
.truth-accent {
  display: inline-block; width: 32px; height: 2px;
  margin-bottom: 1.2rem;
}
.truth-name {
  font-family: var(--serif); font-size: 1.55rem; font-weight: 600;
  color: var(--text); margin-bottom: .5rem;
}

@media(max-width:600px) {
  .truth-name {
    font-size: 1.4rem;
  }
}
.truth-subtitle {
  font-size: .75rem; letter-spacing: .18em; text-transform: uppercase;
  margin-bottom: 1.4rem;
}

@media(max-width:600px) {
  .truth-subtitle {
    font-size: .82rem;
    letter-spacing: .2em;
  }
}
.truth-body {
  font-size: .97rem; color: var(--text); line-height: 1.8;
  font-weight: 300;
}

@media(max-width:600px) {
  .truth-body {
    font-size: 1.02rem;
    line-height: 1.95;
    letter-spacing: 0.2px;
  }
}
.truth-quote {
  margin-top: 1.5rem; padding-left: 1.2rem;
  border-left: 2px solid;
  font-family: var(--serif); font-style: italic;
  font-size: 1.08rem; color: var(--text);
  line-height: 1.6;
  font-weight: 300;
}

@media(max-width:600px) {
  .truth-quote {
    font-size: 1.12rem;
    line-height: 1.85;
    letter-spacing: 0.2px;
  }
}

/* ── ORIGIN SECTION ── */
#origin {
  padding: 8rem 2rem;
  max-width: 860px; margin: 0 auto;
}
@media(max-width:600px) {
  #origin { padding: 4rem 1.5rem; }
}
#origin .section-label { margin-bottom: 1rem; }
#origin .section-title { margin-bottom: 3rem; }
.prose {
  font-family: var(--serif); font-size: clamp(1.05rem, 2vw, 1.22rem);
  font-weight: 300; line-height: 1.85; color: var(--text);
  animation: fadeUp .8s ease-out;
}
.prose strong { color: var(--amber); font-weight: 500; }
.prose em { color: var(--purple-light); font-style: italic; }

@media(max-width:600px) {
  .prose {
    font-size: 1.15rem;
    line-height: 2;
    letter-spacing: 0.3px;
  }
}

/* ── FIELD SECTION ── */
#field {
  padding: 8rem 2rem;
  background: var(--deep);
  border-top: 1px solid var(--rim2);
  border-bottom: 1px solid var(--rim2);
}
@media(max-width:600px) {
  #field { padding: 4rem 1.5rem; }
}
.field-inner {
  max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr; gap: 5rem; align-items: start;
}
@media(max-width:720px){ .field-inner{grid-template-columns:1fr;gap:2.5rem;} }
.field-diagram { 
  width: 100%; 
  animation: floatUp .8s ease-out;
}

/* ── ETHIC SECTION ── */
#ethic {
  padding: 8rem 2rem;
  background: var(--deep);
  border-top: 1px solid var(--rim2);
  border-bottom: 1px solid var(--rim2);
}
@media(max-width:600px) {
  #ethic { padding: 4rem 1.5rem; }
}
.ethic-inner { max-width: 900px; margin: 0 auto; text-align: center; }
.ethic-law {
  font-family: var(--serif); font-size: clamp(1.8rem, 4.5vw, 3rem);
  font-weight: 300; font-style: italic;
  line-height: 1.3; color: var(--text);
  margin: 2.5rem 0;
}
.ethic-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem; margin-top: 3.5rem; text-align: left;
}
@media(max-width:600px) {
  .ethic-grid { grid-template-columns: 1fr; }
}
.ethic-item {
  padding: 1.8rem;
  border: 1px solid var(--rim);
  border-radius: 4px;
  transition: all .35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.ethic-item:hover { 
  border-color: var(--purple-dim); 
  background: var(--surface);
  transform: translateY(-6px);
  box-shadow: 0 16px 32px rgba(127, 119, 221, 0.1);
}
.ethic-icon {
  width: 32px; height: 32px; border-radius: 50%;
  margin-bottom: 1rem; opacity: .8;
  transition: transform .3s ease;
}
.ethic-item:hover .ethic-icon {
  transform: scale(1.2) rotate(10deg);
}
.ethic-item h4 {
  font-family: var(--serif); font-size: 1.1rem; font-weight: 600;
  color: var(--text); margin-bottom: .5rem;
}
.ethic-item p { font-size: .9rem; color: var(--text); font-weight: 300; }

@media(max-width:600px) {
  .ethic-item p {
    font-size: .98rem;
    line-height: 1.8;
  }
}

@media(max-width:600px) {
  .ethic-item h4 {
    font-size: 1.05rem;
  }
}

/* ── PRACTICES SECTION ── */
#practices { padding: 8rem 2rem; max-width: 900px; margin: 0 auto; }
.practices-list { list-style: none; margin-top: 3rem; }
.practices-list li {
  display: grid; grid-template-columns: 48px 1fr;
  gap: 1.5rem; align-items: start;
  padding: 2rem 0; border-bottom: 1px solid var(--rim2);
  transition: all .3s ease;
  animation: slideFromLeft .6s ease-out backwards;
}
.practices-list li:nth-child(1) { animation-delay: 0.1s; }
.practices-list li:nth-child(2) { animation-delay: 0.2s; }
.practices-list li:nth-child(3) { animation-delay: 0.3s; }
.practices-list li:nth-child(4) { animation-delay: 0.4s; }
.practices-list li:nth-child(5) { animation-delay: 0.5s; }

.practices-list li:hover {
  transform: translateX(8px);
}

.practice-dot {
  width: 12px; height: 12px; border-radius: 50%;
  margin-top: .45rem;
  animation: pulse 2s ease-in-out infinite;
}
.practice-dot:hover { animation: pulse .6s ease-out; }

.practice-name {
  font-family: var(--serif); font-size: 1.3rem; font-weight: 600;
  color: var(--text); margin-bottom: .4rem;
  transition: color .25s;
}

@media(max-width:600px) {
  .practice-name {
    font-size: 1.25rem;
  }
}
.practice-desc { 
  font-size: .97rem; color: var(--text);
  transition: color .25s;
  font-weight: 300;
}

@media(max-width:600px) {
  .practice-desc {
    font-size: 1.02rem;
    line-height: 1.85;
    letter-spacing: 0.2px;
  }
}

.practices-list li:hover .practice-name,
.practices-list li:hover .practice-desc {
  color: var(--purple-light);
}

@media(max-width:600px) {
  #practices { padding: 4rem 1.5rem; }
  .practices-list li {
    grid-template-columns: 40px 1fr;
    gap: 1rem;
    padding: 1.5rem 0;
  }
}

/* ── COMPARE TABLE ── */
#compare {
  padding: 8rem 2rem;
  background: var(--deep);
  border-top: 1px solid var(--rim2);
}
.compare-inner { max-width: 1000px; margin: 0 auto; }
.compare-table {
  width: 100%; border-collapse: collapse; margin-top: 3rem;
  font-size: .92rem;
}
.compare-table th {
  font-family: var(--sans); font-size: .68rem; letter-spacing: .18em;
  text-transform: uppercase; color: var(--text-muted);
  padding: 1rem 1.5rem; border-bottom: 1px solid var(--rim);
  text-align: left;
}
.compare-table td {
  padding: 1.2rem 1.5rem; border-bottom: 1px solid var(--rim2);
  color: var(--text); line-height: 1.6; vertical-align: top;
  transition: all .25s ease;
  font-weight: 300;
}
@media(max-width:768px) {
  .compare-table th {
    font-size: .75rem;
  }
  .compare-table td {
    font-size: 1rem;
    line-height: 1.8;
  }
  .compare-table td:first-child {
    font-size: 1.1rem;
  }
}
.compare-table tr:hover td { 
  background: var(--surface); 
  transform: translateX(4px);
}
.compare-table td:first-child {
  font-family: var(--serif); font-size: 1.05rem; font-weight: 600;
  color: var(--text);
}
.compare-table td:nth-child(2) { color: var(--teal-light); }

@media(max-width:768px) {
  .compare-table, .compare-table thead, .compare-table tbody, 
  .compare-table th, .compare-table td, .compare-table tr {
    display: block;
  }
  
  .compare-table thead { display: none; }
  
  .compare-table tr {
    margin-bottom: 2rem;
    border: 1px solid var(--rim);
    border-radius: 8px;
    padding: 1.5rem;
    background: var(--surface);
  }
  
  .compare-table td {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 1rem;
    padding: .8rem 0;
    border: none;
    border-bottom: 1px solid var(--rim2);
  }
  
  .compare-table td:last-child { border-bottom: none; }
  
  .compare-table td::before {
    content: attr(data-label);
    font-weight: 600;
    color: var(--purple-light);
    text-transform: uppercase;
    font-size: .7rem;
    letter-spacing: .12em;
  }
  
  .compare-table td:first-child::before { content: 'Religion'; }
  .compare-table td:nth-child(2)::before { content: 'What got right'; }
  .compare-table td:nth-child(3)::before { content: 'What Noetism fixes'; }
}

/* ── FOOTER ── */
footer {
  padding: 4rem 2rem;
  border-top: 1px solid var(--rim2);
  text-align: center;
}
@media(max-width:600px) {
  footer { padding: 3rem 1.5rem; }
}
.footer-logo {
  font-family: var(--serif); font-size: 2rem; font-weight: 300;
  color: var(--purple-dim); letter-spacing: .06em;
  margin-bottom: 1rem;
  animation: fadeUp .8s ease-out;
}
footer p {
  font-size: .8rem; color: var(--text-muted); letter-spacing: .08em;
}

/* ── SECTION RESPONSIVE ── */
.section-label {
  font-size: .72rem; letter-spacing: .28em; text-transform: uppercase;
  color: var(--teal-light); margin-bottom: 1rem;
  animation: fadeUp .6s ease-out backwards;
}

@media(max-width:600px) {
  .section-label {
    font-size: .78rem;
    letter-spacing: .3em;
  }
}
.section-title {
  font-family: var(--serif); font-size: clamp(2.2rem, 5vw, 3.6rem);
  font-weight: 300; color: var(--text);
  animation: fadeUp .7s .1s ease-out backwards;
}

@media(max-width:600px) {
  .section-title {
    line-height: 1.2;
    letter-spacing: -0.5px;
  }
}

/* ── REVEAL ── */
.reveal {
  opacity: 0; transform: translateY(28px);
  transition: opacity .75s ease, transform .75s ease;
}
.reveal.visible { opacity: 1; transform: none; }

@keyframes fadeUp {
  to { opacity: 1; transform: translateY(0); }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideFromLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes floatUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% {
    opacity: .8;
    transform: scale(1);
  }
  50% {
    opacity: 1;
    transform: scale(1.3);
  }
}

@keyframes glow {
  0%, 100% {
    text-shadow: 0 0 10px rgba(175, 169, 236, 0.3), 0 0 20px rgba(175, 169, 236, 0.2);
  }
  50% {
    text-shadow: 0 0 20px rgba(175, 169, 236, 0.6), 0 0 40px rgba(175, 169, 236, 0.3);
  }
}
