/* ==========================================================================
   TATTVA MAESTRO - STYLESHEET
   Aesthetics: Luxury Cosmic, Sacred Geometry, Vedic Numerology
   Layout: Centered Hero Minimalist Teaser
   ========================================================================== */

:root {
  --bg-primary: #050611;
  --bg-secondary: #0c0e23;

  --border-subtle: rgba(212, 175, 55, 0.18);
  --border-bright: rgba(245, 194, 83, 0.45);
  --border-glass: rgba(255, 255, 255, 0.08);

  --gold-primary: #f5c253;
  --gold-glow: #e6a838;
  --gold-subtle: #eed59a;
  --gold-dark: #8e6820;

  --violet-glow: #8b5cf6;
  --indigo-deep: #4338ca;
  --cyan-accent: #38bdf8;

  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;

  --font-serif: 'Cinzel', serif;
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'Space Grotesk', monospace;

  --transition-smooth: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  --shadow-gold: 0 0 35px rgba(245, 194, 83, 0.22);
}

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

html, body {
  width: 100%;
  min-height: 100vh;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-sans);
  overflow-x: hidden;
  position: relative;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ==========================================================================
   BACKGROUND CANVAS & COSMIC GLOW ORBS
   ========================================================================== */

#numbersCanvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
}

.cosmos-glow-orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(120px);
  pointer-events: none;
  z-index: 1;
  opacity: 0.35;
  animation: floatOrb 24s ease-in-out infinite alternate;
}

.orb-1 {
  width: 600px;
  height: 600px;
  top: -150px;
  left: 50%;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(139, 92, 246, 0.45) 0%, rgba(245, 194, 83, 0.15) 60%, transparent 80%);
}

.orb-2 {
  width: 500px;
  height: 500px;
  bottom: 5%;
  left: -100px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.25) 0%, rgba(67, 56, 202, 0.3) 50%, transparent 80%);
  animation-duration: 32s;
  animation-delay: -5s;
}

.orb-3 {
  width: 550px;
  height: 550px;
  top: 40%;
  right: -120px;
  background: radial-gradient(circle, rgba(245, 194, 83, 0.25) 0%, rgba(139, 92, 246, 0.25) 50%, transparent 80%);
  animation-duration: 28s;
  animation-delay: -10s;
}

@keyframes floatOrb {
  0% { transform: translateY(0) scale(1); }
  50% { transform: translateY(40px) scale(1.08); }
  100% { transform: translateY(-30px) scale(0.95); }
}

.vignette-overlay {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at center, transparent 40%, rgba(5, 6, 17, 0.88) 100%);
  pointer-events: none;
  z-index: 2;
}

/* ==========================================================================
   SACRED GEOMETRY ROTATING RINGS (BACKGROUND WATERMARK)
   ========================================================================== */

.sacred-geometry-wrap {
  position: fixed;
  top: 50%;
  left: 50%;
  width: 760px;
  height: 760px;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 1;
  opacity: 0.2;
  display: flex;
  align-items: center;
  justify-content: center;
}

.geo-ring {
  position: absolute;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.geo-ring-outer {
  width: 720px;
  height: 720px;
  border: 1px dashed rgba(245, 194, 83, 0.45);
  animation: rotateClockwise 120s linear infinite;
}

.geo-ring-outer .ring-num {
  position: absolute;
  font-family: var(--font-serif);
  font-weight: 700;
  color: var(--gold-primary);
  font-size: 1.15rem;
  text-shadow: 0 0 10px rgba(245, 194, 83, 0.6);
}

/* 9 numbers distributed on 360/9 = 40 deg intervals */
.n-1 { transform: rotate(0deg) translateY(-360px) rotate(0deg); }
.n-2 { transform: rotate(40deg) translateY(-360px) rotate(-40deg); }
.n-3 { transform: rotate(80deg) translateY(-360px) rotate(-80deg); }
.n-4 { transform: rotate(120deg) translateY(-360px) rotate(-120deg); }
.n-5 { transform: rotate(160deg) translateY(-360px) rotate(-160deg); }
.n-6 { transform: rotate(200deg) translateY(-360px) rotate(-200deg); }
.n-7 { transform: rotate(240deg) translateY(-360px) rotate(-240deg); }
.n-8 { transform: rotate(280deg) translateY(-360px) rotate(-280deg); }
.n-9 { transform: rotate(320deg) translateY(-360px) rotate(-320deg); }

.geo-ring-middle {
  width: 520px;
  height: 520px;
  border: 1px solid rgba(139, 92, 246, 0.35);
  animation: rotateCounter 80s linear infinite;
}

.hexagram {
  position: relative;
  width: 320px;
  height: 320px;
  border: 1px solid rgba(245, 194, 83, 0.25);
  transform: rotate(45deg);
}

.geo-ring-inner {
  width: 280px;
  height: 280px;
  border: 1px dashed rgba(212, 175, 55, 0.3);
  animation: rotateClockwise 60s linear infinite;
}

.geo-core-symbol {
  font-size: 2.5rem;
  color: var(--gold-primary);
  text-shadow: 0 0 25px var(--gold-primary);
}

@keyframes rotateClockwise {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes rotateCounter {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

/* ==========================================================================
   PAGE CONTAINER & ABSOLUTE CENTER HERO
   ========================================================================== */

.page-container {
  position: relative;
  z-index: 10;
  width: 100%;
  height: 100vh;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.5rem;
}

.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 1080px;
  width: 100%;
  margin: auto;
}

.hero-headline {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 4.4vw, 3.8rem);
  font-weight: 800;
  line-height: 1.28;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  margin-bottom: 2rem;
  animation: fadeInUp 0.9s ease backwards;
}

/* Dynamic Rotating Word Container - CSS Grid stack guarantees full width & zero background-clip cropping */
.rotating-word-container {
  display: inline-grid;
  grid-template-areas: "word";
  align-items: center;
  justify-items: center;
  vertical-align: bottom;
  position: relative;
  padding: 0 0.1em;
}

.rotating-word {
  grid-area: word;
  display: inline-block;
  white-space: nowrap;
  width: max-content;
  padding: 0 0.15em;
  background: linear-gradient(135deg, #ffe9a6 0%, #f5c253 45%, #e18c28 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  opacity: 0;
  visibility: hidden;
  transform: translateY(18px) scale(0.97);
  filter: blur(5px);
  pointer-events: none;
  transition: opacity 0.55s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.55s cubic-bezier(0.16, 1, 0.3, 1),
              filter 0.55s cubic-bezier(0.16, 1, 0.3, 1),
              visibility 0.55s;
}

.rotating-word.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
  filter: blur(0);
  pointer-events: auto;
}

.text-gold {
  color: var(--gold-primary);
  font-weight: 600;
  text-shadow: 0 0 15px rgba(245, 194, 83, 0.3);
}

.hero-description {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  line-height: 1.8;
  color: var(--text-secondary);
  max-width: 760px;
  font-weight: 300;
  animation: fadeInUp 0.9s ease 0.15s backwards;
}

/* ==========================================================================
   ANIMATIONS
   ========================================================================== */

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

/* ==========================================================================
   RESPONSIVE DESIGN (TABLETS & MOBILE)
   ========================================================================== */

@media (max-width: 900px) {
  .hero-headline {
    font-size: clamp(1.8rem, 5.2vw, 2.9rem);
  }

  .sacred-geometry-wrap {
    width: 500px;
    height: 500px;
    opacity: 0.14;
  }
  .geo-ring-outer {
    width: 480px;
    height: 480px;
  }
  .n-1 { transform: rotate(0deg) translateY(-240px) rotate(0deg); }
  .n-2 { transform: rotate(40deg) translateY(-240px) rotate(-40deg); }
  .n-3 { transform: rotate(80deg) translateY(-240px) rotate(-80deg); }
  .n-4 { transform: rotate(120deg) translateY(-240px) rotate(-120deg); }
  .n-5 { transform: rotate(160deg) translateY(-240px) rotate(-160deg); }
  .n-6 { transform: rotate(200deg) translateY(-240px) rotate(-200deg); }
  .n-7 { transform: rotate(240deg) translateY(-240px) rotate(-240deg); }
  .n-8 { transform: rotate(280deg) translateY(-240px) rotate(-280deg); }
  .n-9 { transform: rotate(320deg) translateY(-240px) rotate(-320deg); }
}

@media (max-width: 640px) {
  html, body {
    overflow-y: auto;
  }

  .page-container {
    padding: 1.5rem 1rem;
    height: auto;
    min-height: 100vh;
  }

  .hero-headline {
    font-size: clamp(1.45rem, 6.2vw, 2.2rem);
  }

  .headline-br {
    display: inline;
  }

  .rotating-word-container {
    display: grid;
    margin: 0.25rem 0;
  }
}

@media (max-width: 420px) {
  .hero-headline {
    font-size: clamp(1.3rem, 5.8vw, 1.85rem);
  }
}
