:root {
  --shadow-black: #0d0d0d;
  --necro-purple: #2d1b4e;
  --necro-purple-deep: #1a0f2e;
  --soul-cyan: #4ecdc4;
  --gate-gold: #c5a572;
  --blood-crimson: #dc1428;
  --dark-essence: #9321ea;
  --bone-white: #e8e0d8;
  --toxic-green: #39ff14;
  --panel-border: rgba(197, 165, 114, 0.35);
  --font: "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --radius: 18px;
  --header-h: 72px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--shadow-black);
  color: var(--bone-white);
  line-height: 1.65;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--soul-cyan); text-decoration: none; }
a:hover { color: #7ee8e0; }

.container {
  width: min(1120px, calc(100% - 40px));
  margin-inline: auto;
}

/* Floating souls */
.soul-field {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.soul-particle {
  position: absolute;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--soul-cyan);
  opacity: 0;
  animation: soulDrift linear infinite;
  box-shadow: 0 0 8px var(--soul-cyan);
}

@keyframes soulDrift {
  0% { transform: translateY(100vh) scale(0); opacity: 0; }
  10% { opacity: 0.7; }
  90% { opacity: 0.4; }
  100% { transform: translateY(-10vh) scale(1.2); opacity: 0; }
}

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  background: rgba(13, 13, 13, 0.82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--panel-border);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--bone-white);
  text-decoration: none;
}

.brand-logo {
  border-radius: 12px;
  box-shadow: 0 0 20px rgba(78, 205, 196, 0.25);
}

.brand-name {
  font-weight: 800;
  font-size: 1.1rem;
  letter-spacing: 0.04em;
  background: linear-gradient(180deg, var(--bone-white), var(--gate-gold));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.site-nav {
  display: flex;
  gap: 28px;
}

.site-nav a {
  color: rgba(232, 224, 216, 0.75);
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  transition: color 0.2s;
}

.site-nav a:hover { color: var(--soul-cyan); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--bone-white);
  border-radius: 2px;
  transition: transform 0.25s, opacity 0.25s;
}

/* Hero */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: var(--header-h);
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  opacity: 0.45;
}

.hero-bg-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 70% 40%, rgba(147, 33, 234, 0.18), transparent),
    linear-gradient(180deg, rgba(13, 13, 13, 0.3) 0%, var(--shadow-black) 85%);
}

.hero-inner {
  position: relative;
  z-index: 1;
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
  padding: 60px 0 80px;
}

.eyebrow {
  color: var(--soul-cyan);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin: 0 0 16px;
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  line-height: 1.08;
  margin: 0 0 20px;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.gold { color: var(--gate-gold); }

.hero-lead {
  font-size: 1.08rem;
  color: rgba(232, 224, 216, 0.82);
  max-width: 52ch;
  margin: 0 0 28px;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 32px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 26px;
  border-radius: 14px;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  transition: transform 0.15s, box-shadow 0.2s;
  border: 1.5px solid transparent;
}

.btn:hover { transform: translateY(-2px); }

.btn-primary {
  background: linear-gradient(135deg, var(--dark-essence), var(--necro-purple));
  color: var(--bone-white);
  box-shadow: 0 8px 28px rgba(147, 33, 234, 0.35);
  border-color: rgba(78, 205, 196, 0.4);
}

.btn-primary:hover {
  box-shadow: 0 12px 36px rgba(78, 205, 196, 0.25);
  color: var(--bone-white);
}

.btn-ghost {
  background: rgba(26, 15, 46, 0.7);
  color: var(--bone-white);
  border-color: var(--panel-border);
}

.resource-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.resource-chip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(26, 15, 46, 0.85);
  border: 1px solid var(--panel-border);
  font-size: 0.85rem;
  font-weight: 700;
}

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

.gate-frame {
  position: relative;
  width: min(340px, 80vw);
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gate-glow {
  position: absolute;
  inset: 10%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(78, 205, 196, 0.35), transparent 70%);
  animation: pulseGlow 4s ease-in-out infinite;
}

@keyframes pulseGlow {
  0%, 100% { transform: scale(0.95); opacity: 0.6; }
  50% { transform: scale(1.08); opacity: 1; }
}

.gate-portal {
  position: relative;
  z-index: 2;
  animation: portalFloat 6s ease-in-out infinite;
  filter: drop-shadow(0 0 30px rgba(78, 205, 196, 0.5));
}

@keyframes portalFloat {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-12px) scale(1.03); }
}

.float-unit {
  position: absolute;
  z-index: 3;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.6));
}

.unit-left {
  left: -8%;
  bottom: 18%;
  animation: floatLeft 5s ease-in-out infinite;
}

.unit-right {
  right: -6%;
  top: 12%;
  animation: floatRight 7s ease-in-out infinite;
}

@keyframes floatLeft {
  0%, 100% { transform: translateY(0) rotate(-4deg); }
  50% { transform: translateY(-16px) rotate(2deg); }
}

@keyframes floatRight {
  0%, 100% { transform: translateY(0) rotate(3deg); }
  50% { transform: translateY(14px) rotate(-2deg); }
}

/* Pitch */
.pitch {
  padding: 72px 0;
  background: linear-gradient(180deg, var(--shadow-black), var(--necro-purple-deep));
}

.pitch-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.pitch-card {
  padding: 28px 24px;
  border-radius: var(--radius);
  background: rgba(45, 27, 78, 0.45);
  border: 1.5px solid var(--panel-border);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  transition: transform 0.25s, border-color 0.25s;
}

.pitch-card:hover {
  transform: translateY(-4px);
  border-color: rgba(78, 205, 196, 0.5);
}

.pitch-num {
  display: block;
  font-size: 2rem;
  font-weight: 900;
  color: var(--gate-gold);
  opacity: 0.5;
  margin-bottom: 8px;
}

.pitch-card h3 {
  margin: 0 0 10px;
  font-size: 1.15rem;
}

.pitch-card p {
  margin: 0;
  color: rgba(232, 224, 216, 0.78);
  font-size: 0.95rem;
}

/* Features */
.features {
  padding: 88px 0;
  position: relative;
}

.section-head {
  text-align: center;
  margin-bottom: 48px;
}

.section-head.left { text-align: left; }

.section-head h2 {
  font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  margin: 0;
  line-height: 1.2;
  max-width: 22ch;
  margin-inline: auto;
}

.section-head.left h2 { margin-inline: 0; max-width: none; }

.section-sub {
  color: rgba(232, 224, 216, 0.65);
  margin-top: 12px;
}

.feature-showcase {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.feature-panel {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 32px;
  align-items: center;
  padding: 28px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(26, 15, 46, 0.9), rgba(45, 27, 78, 0.5));
  border: 1.5px solid var(--panel-border);
}

.feature-panel.reverse {
  grid-template-columns: 1fr 200px;
}

.feature-panel.reverse .feature-art { order: 2; }
.feature-panel.reverse div { order: 1; }

.feature-art {
  width: 200px;
  border-radius: 16px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.45);
}

.feature-panel h3 {
  margin: 0 0 8px;
  color: var(--gate-gold);
  font-size: 1.3rem;
}

.feature-panel p {
  margin: 0;
  color: rgba(232, 224, 216, 0.8);
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-top: 40px;
}

.tag-cloud span {
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  background: rgba(78, 205, 196, 0.1);
  border: 1px solid rgba(78, 205, 196, 0.35);
  color: var(--soul-cyan);
}

/* Legal */
.legal {
  padding: 88px 0;
  background: var(--necro-purple-deep);
}

.legal-card {
  padding: 36px 32px;
  border-radius: var(--radius);
  background: rgba(13, 13, 13, 0.65);
  border: 1.5px solid var(--panel-border);
}

.legal-card h3 {
  color: var(--gate-gold);
  margin: 28px 0 10px;
  font-size: 1.1rem;
}

.legal-card h3:first-of-type { margin-top: 0; }

.legal-card p, .legal-card li {
  color: rgba(232, 224, 216, 0.85);
}

.legal-card ul {
  padding-left: 1.2rem;
}

.legal-card li { margin-bottom: 8px; }

/* Support */
.support {
  padding: 88px 0 100px;
}

.support-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 40px;
  align-items: start;
}

.support-mail {
  margin-top: 24px;
  font-size: 1rem;
}

.faq {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  border-radius: 14px;
  background: rgba(26, 15, 46, 0.75);
  border: 1.5px solid var(--panel-border);
  overflow: hidden;
}

.faq-item summary {
  cursor: pointer;
  padding: 18px 20px;
  font-weight: 700;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::after {
  content: "+";
  color: var(--soul-cyan);
  font-size: 1.3rem;
  font-weight: 400;
  transition: transform 0.2s;
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
}

.faq-item p {
  margin: 0;
  padding: 0 20px 18px;
  color: rgba(232, 224, 216, 0.78);
  font-size: 0.95rem;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--panel-border);
  padding: 28px 0;
  background: var(--shadow-black);
}

.footer-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.footer-icon { border-radius: 10px; }

.footer-inner p {
  margin: 4px 0 0;
  font-size: 0.85rem;
  color: rgba(232, 224, 216, 0.55);
}

.footer-nav {
  margin-left: auto;
  display: flex;
  gap: 20px;
}

.footer-nav a {
  color: rgba(232, 224, 216, 0.6);
  font-size: 0.88rem;
  font-weight: 600;
}

/* Mobile */
@media (max-width: 900px) {
  .hero-inner,
  .pitch-grid,
  .support-grid {
    grid-template-columns: 1fr;
  }

  .hero-visual { order: -1; }
  .gate-frame { width: min(260px, 70vw); }

  .feature-panel,
  .feature-panel.reverse {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .feature-panel.reverse .feature-art { order: 0; }
  .feature-art { margin: 0 auto; }

  .site-nav {
    position: fixed;
    top: var(--header-h);
    right: 0;
    left: 0;
    flex-direction: column;
    background: rgba(13, 13, 13, 0.96);
    padding: 20px 24px 28px;
    gap: 18px;
    border-bottom: 1px solid var(--panel-border);
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s, opacity 0.3s;
  }

  .site-nav.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .nav-toggle { display: flex; }

  .nav-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle.active span:nth-child(2) { opacity: 0; }
  .nav-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .footer-nav { margin-left: 0; width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}
