/* ═══════════════════════════════════════════════════════════════
   DreamStar Nova — Home / Landing Page
   Scroll-driven parallax, portal dive, manifesto reveal
   Dark-first with html[data-theme="light"] overrides
   ═══════════════════════════════════════════════════════════════ */

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

.hm-body {
  background: #000;
  color: #fff;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "SF Pro Display", sans-serif;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection { background: #00d1ff; color: #000; }
::-webkit-scrollbar { width: 0; }


/* ═══════════════════════════════════════
   BACKGROUND LAYER
   ═══════════════════════════════════════ */
.hm-bg-layer {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.hm-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  transform: scale(1.25);
  animation: hm-ken-burns 60s infinite ease-in-out;
  opacity: .85;
}

.hm-bg-tint {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.1);
}

@keyframes hm-ken-burns {
  0%   { transform: scale(1.25) translate(0%, 0%); }
  25%  { transform: scale(1.35) translate(-2%, -1%); }
  50%  { transform: scale(1.30) translate(1.5%, -2%); }
  75%  { transform: scale(1.35) translate(2%, 0.5%); }
  100% { transform: scale(1.25) translate(0%, 0%); }
}


/* ═══════════════════════════════════════
   SCROLL BODY
   ═══════════════════════════════════════ */
.hm-scroll-body {
  position: relative;
}


/* ═══════════════════════════════════════
   FIXED VIEWPORT (hero + portal)
   ═══════════════════════════════════════ */
.hm-fixed-viewport {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

/* Hero text — centered over portal glass */
.hm-hero-text {
  position: absolute;
  inset: 0;
  z-index: 25;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  will-change: opacity, transform;
  transition: opacity .35s ease, transform .35s ease;
}

.hm-hero-title {
  font-size: clamp(48px, 8vw, 96px);
  font-weight: 900;
  letter-spacing: -.03em;
  line-height: 1.05;
  margin-bottom: 20px;
  color: #fff;
}

.hm-hero-sub {
  font-size: clamp(16px, 2.2vw, 24px);
  font-weight: 400;
  letter-spacing: .08em;
  color: rgba(255,255,255,.5);
  animation: hmBreathe 4s ease-in-out infinite;
}

@keyframes hmBreathe {
  0%, 100% { opacity: .4; }
  50%      { opacity: .7; }
}

/* Portal / spaceship window */
.hm-portal {
  position: relative;
  width: 100vw;
  height: 100vh;
  will-change: transform, opacity;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hm-portal-img {
  position: relative;
  width: 100vw;
  height: 100vh;
  object-fit: cover;
  z-index: 20;
  mix-blend-mode: lighten;
}

.hm-portal-glare {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(255,255,255,.1), transparent 60%);
  z-index: 30;
  opacity: .3;
}


/* ═══════════════════════════════════════
   MANIFESTO SECTIONS
   ═══════════════════════════════════════ */
.hm-manifesto-layer {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.hm-section {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding: 60px 5vw;
  max-width: 1080px;
  margin: 0 auto;
  will-change: opacity, transform;
  opacity: 0;
}

/* Phase badge */
.hm-phase-badge {
  margin-bottom: 28px;
  padding: 3px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.05);
  color: rgba(255,255,255,.05);
  transition: all .7s ease;
}
.hm-phase-badge span {
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .4em;
}
.hm-section.active .hm-phase-badge {
  border-color: rgba(0,209,255,.4);
  color: rgba(0,209,255,.6);
  box-shadow: 0 0 12px rgba(0,209,255,.1);
}

/* Section title */
.hm-section-title {
  font-size: clamp(28px, 4vw, 48px);
  font-weight: 800;
  letter-spacing: -.02em;
  line-height: 1.2;
  margin-bottom: 40px;
  color: rgba(255,255,255,.05);
  transition: color .7s ease;
}
.hm-section.active .hm-section-title {
  color: #fff;
}

/* Section lines */
.hm-section-lines {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 40px;
}
.hm-section-lines p {
  font-size: clamp(16px, 1.8vw, 22px);
  font-weight: 400;
  letter-spacing: .01em;
  line-height: 1.7;
  color: rgba(255,255,255,.05);
  transition: color 1s ease;
}
.hm-section.active .hm-section-lines p {
  color: rgba(255,255,255,.75);
}

/* Slogan */
.hm-section-slogan {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .35em;
  text-transform: uppercase;
  color: rgba(255,255,255,0);
  transition: color 1s ease;
}
.hm-section.active .hm-section-slogan {
  color: rgba(0,209,255,.6);
}


/* ═══════════════════════════════════════
   CLOSING CTA
   ═══════════════════════════════════════ */
.hm-closing {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: scale(.95);
  pointer-events: none;
  transition: opacity 1s ease, transform 1s ease;
}
.hm-closing.show {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
}

.hm-closing-bg {
  display: none;
}

.hm-closing-content {
  position: relative;
  text-align: center;
  padding: 0 24px;
  max-width: 700px;
}

.hm-closing-badge {
  display: block;
  font-size: clamp(28px, 4vw, 48px);
  font-weight: 800;
  letter-spacing: -.02em;
  color: #fff;
  margin-bottom: 24px;
}

.hm-closing-desc {
  font-size: clamp(16px, 1.8vw, 22px);
  line-height: 1.7;
  color: rgba(255,255,255,.75);
  margin-bottom: 56px;
}

.hm-closing-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 40px;
  border-radius: 999px;
  background: #fff;
  color: #000;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  box-shadow: 0 10px 40px rgba(0,0,0,.3);
  transition: all .3s ease;
}
.hm-closing-btn:hover {
  background: #00d1ff;
  color: #000;
  transform: scale(1.03);
}
.hm-closing-btn svg {
  transition: transform .3s ease;
}
.hm-closing-btn:hover svg {
  transform: translateX(6px);
}


/* ═══════════════════════════════════════
   NAV BAR (50px)
   ═══════════════════════════════════════ */
.hm-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 50px;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 100;
  transition: transform .5s ease, opacity .5s ease;
}
.hm-nav--hidden {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}

.hm-nav-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hm-nav-logo {
  display: flex;
  align-items: center;
  justify-content: center;
}
.hm-nav-logo-img {
  height: 20px;
  width: auto;
}
html[data-theme="light"] .hm-nav-logo-img {
  filter: none;
}

.hm-nav-brand {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -.01em;
}

.hm-nav-right {
  display: flex;
  align-items: center;
  gap: 20px;
}

.hm-theme-btn {
  border: 0;
  background: transparent;
  color: inherit;
  opacity: .4;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity .2s;
}
.hm-theme-btn:hover { opacity: 1; }

/* Show/hide sun/moon icons: dark=moon, light=sun */
.hm-ico-sun { display: none; }
.hm-ico-moon { display: inline; color: #94a3b8; }
html[data-theme="light"] .hm-ico-sun { display: inline; color: #f59e0b; }
html[data-theme="light"] .hm-ico-moon { display: none; }

.hm-nav-cta {
  padding: 6px 16px;
  border-radius: 999px;
  background: #fff;
  color: #000;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: -.01em;
  text-decoration: none;
  transition: all .2s;
}
.hm-nav-cta:hover {
  background: #00d1ff;
}


/* ═══════════════════════════════════════
   LIGHT THEME
   ═══════════════════════════════════════ */
html[data-theme="light"] .hm-body {
  background: #f5f5f7;
  color: #1d1d1f;
}

html[data-theme="light"] .hm-bg-tint {
  background: rgba(255,255,255,.05);
}

html[data-theme="light"] .hm-hero-sub {
  color: rgba(0,0,0,.45);
  animation-name: hmBreatheLight;
}
@keyframes hmBreatheLight {
  0%, 100% { opacity: .3; text-shadow: 0 0 0 transparent; }
  50%      { opacity: .6; text-shadow: 0 0 20px rgba(37,99,235,.12); }
}

html[data-theme="light"] .hm-phase-badge {
  border-color: rgba(0,0,0,.05);
  color: rgba(0,0,0,.05);
}
html[data-theme="light"] .hm-section.active .hm-phase-badge {
  border-color: #2563eb;
  color: #2563eb;
  box-shadow: 0 0 20px rgba(37,99,235,.15);
}

html[data-theme="light"] .hm-section-title { color: rgba(0,0,0,.05); }
html[data-theme="light"] .hm-section.active .hm-section-title { color: #1d1d1f; }

html[data-theme="light"] .hm-section-lines p { color: rgba(0,0,0,.05); }
html[data-theme="light"] .hm-section.active .hm-section-lines p { color: rgba(0,0,0,.7); }

html[data-theme="light"] .hm-section-slogan { color: rgba(0,0,0,0); }
html[data-theme="light"] .hm-section.active .hm-section-slogan { color: rgba(37,99,235,.35); }

html[data-theme="light"] .hm-closing-bg {
  background: rgba(255,255,255,.95);
}
html[data-theme="light"] .hm-closing-badge { color: #111827; }
html[data-theme="light"] .hm-closing-desc { color: rgba(0,0,0,.6); }

html[data-theme="light"] .hm-closing-btn {
  background: #000;
  color: #fff;
}
html[data-theme="light"] .hm-closing-btn:hover {
  background: #2563eb;
  color: #fff;
}

html[data-theme="light"] .hm-nav-cta {
  background: #000;
  color: #fff;
}
html[data-theme="light"] .hm-nav-cta:hover {
  background: #2563eb;
}

/* ── Footer ── */
.hm-footer {
  position: absolute;
  bottom: 20px;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 12px;
  color: rgba(255,255,255,.35);
  letter-spacing: .02em;
}
.hm-footer p { margin: 0; }
html[data-theme="light"] .hm-footer { color: rgba(0,0,0,.35); }

/* ═══════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════ */
@media (max-width: 768px) {
  .hm-section { padding: 0 20px; }
  .hm-section-lines { gap: 24px; margin-bottom: 48px; }
  .hm-phase-badge { margin-bottom: 32px; }
  .hm-section-title { margin-bottom: 36px; }

  .hm-closing-btn {
    padding: 16px 40px;
    font-size: 16px;
    gap: 12px;
  }
  .hm-closing-btn svg { width: 22px; height: 22px; }

  .hm-nav { padding: 0 16px; }
}

@media (max-width: 480px) {
  .hm-hero-title { font-size: clamp(36px, 10vw, 60px); }
  .hm-section { padding: 0 16px; }
  .hm-closing-badge { font-size: 11px; letter-spacing: .4em; }
}
