:root {
  --bg: #08060a;
  --bg-2: #120a0b;
  --ink: #f6eee8;
  --muted: #a8968c;
  --line: rgba(255, 190, 140, 0.14);
  --fire-1: #ffc107;
  --fire-2: #ff5a14;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html, body { height: 100%; }

body {
  background:
    radial-gradient(120% 80% at 50% 45%, var(--bg-2) 0%, var(--bg) 60%) fixed,
    var(--bg);
  color: var(--ink);
  font: 400 16px/1.5 Inter, system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

#bg, #fx {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
#bg { z-index: 0; }
#fx { z-index: 3; mix-blend-mode: screen; }

#src {
  position: fixed;
  width: 2px;
  height: 2px;
  left: 0;
  top: 0;
  opacity: 0;
  pointer-events: none;
}

/* ---------- nav ---------- */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 10;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 clamp(16px, 4vw, 48px);
  opacity: 0;
  transform: translateY(-8px);
  animation: in 1.2s var(--ease-out) 0.4s forwards;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font: 700 14px/1 Unbounded, sans-serif;
  letter-spacing: 0.2em;
}
.brand-mark {
  font: 800 22px/1 Unbounded, sans-serif;
  letter-spacing: 0;
  background: linear-gradient(100deg, var(--fire-1), var(--fire-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.links { display: flex; gap: 32px; }
.links a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.2s;
}
.links a:hover { color: var(--ink); }

/* ---------- buttons ---------- */
.btn {
  --h: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: var(--h);
  padding: 0 26px;
  border-radius: 999px;
  font: 600 15px/1 Inter, sans-serif;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 0.25s var(--ease-out), box-shadow 0.25s, background-color 0.25s, border-color 0.25s;
}
.btn-sm { --h: 38px; padding: 0 18px; font-size: 14px; }
.btn-primary {
  color: #1a0700;
  background: linear-gradient(100deg, var(--fire-1), var(--fire-2));
  box-shadow: 0 8px 32px -8px rgba(255, 90, 20, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.35);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 40px -8px rgba(255, 90, 20, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.35); }
.btn-ghost {
  color: var(--ink);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(8px);
}
.btn-primary, .btn-discord { min-width: 168px; letter-spacing: 0.14em; font-weight: 700; }
.btn-discord { gap: 10px; }
.btn-discord svg { width: 18px; height: 18px; fill: currentColor; }
.btn-ghost:hover { border-color: rgba(255, 170, 90, 0.4); background: rgba(255, 140, 60, 0.08); }
.btn:focus-visible, .ctl:focus-visible, .links a:focus-visible, .brand:focus-visible {
  outline: 2px solid var(--fire-1);
  outline-offset: 3px;
}

/* ---------- hero ---------- */
.hero {
  position: relative;
  z-index: 1;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
}

.stage {
  position: absolute;
  left: 0;
  top: 0;
  z-index: 2;
  will-change: transform;
  transition: transform 1.6s var(--ease-out);
}
#dragon {
  display: block;
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 0 26px rgba(255, 96, 20, 0.28));
}

.copy {
  position: absolute;
  left: 0;
  right: 0;
  top: var(--copy-top, 70%);
  z-index: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0 16px;
  pointer-events: none;
}
.copy > * {
  opacity: 0;
  transform: translateY(14px);
  filter: blur(6px);
  transition: opacity 1s var(--ease-out), transform 1.2s var(--ease-out), filter 1s var(--ease-out);
}
.revealed .copy { pointer-events: auto; }
.revealed .copy > * { opacity: 1; transform: none; filter: none; }
.revealed .copy > :nth-child(2) { transition-delay: 0.12s; }
.revealed .copy > :nth-child(3) { transition-delay: 0.24s; }
.revealed .copy > :nth-child(4) { transition-delay: 0.36s; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.32em;
  text-transform: uppercase;
}
.dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--fire-2);
  box-shadow: 0 0 12px 2px rgba(255, 90, 20, 0.8);
  animation: pulse 2.4s ease-in-out infinite;
}

.title {
  margin-top: 14px;
  font: 800 clamp(30px, 5.2vw, 68px)/1 Unbounded, sans-serif;
  letter-spacing: 0.14em;
  padding-left: 0.14em;
  background: linear-gradient(180deg, #fff7ec 0%, #ffd6a6 55%, #ff9a4a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 40px rgba(255, 120, 40, 0.18);
}

.lead {
  margin-top: 14px;
  color: var(--muted);
  font-size: clamp(15px, 1.4vw, 18px);
}

.cta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 28px;
}

/* ---------- controls ---------- */
.controls {
  position: absolute;
  right: clamp(16px, 3vw, 32px);
  bottom: clamp(16px, 3vw, 28px);
  z-index: 6;
  display: flex;
  gap: 8px;
  opacity: 0;
  animation: in 1s var(--ease-out) 1.2s forwards;
}
.ctl {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(20, 12, 12, 0.5);
  backdrop-filter: blur(10px);
  color: var(--muted);
  font: 500 13px/1 Inter, sans-serif;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.ctl:hover { color: var(--ink); border-color: rgba(255, 170, 90, 0.4); }
.ctl[hidden] { display: none; }
.ctl svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.ctl-icon { width: 36px; padding: 0; justify-content: center; }
.ctl-icon .on, .ctl-icon[aria-pressed="true"] .off { display: none; }
.ctl-icon[aria-pressed="true"] .on { display: block; }

.ignite {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 7;
  display: grid;
  place-items: center;
  width: 128px;
  height: 128px;
  margin: -64px 0 0 -64px;
  border: 0;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 110, 30, 0.22), rgba(255, 90, 20, 0) 70%);
  color: var(--ink);
  font: 700 12px/1 Unbounded, sans-serif;
  letter-spacing: 0.24em;
  cursor: pointer;
}
.ignite[hidden] { display: none; }
.ignite-ring {
  position: absolute;
  inset: 18px;
  border: 1px solid rgba(255, 170, 90, 0.5);
  border-radius: 50%;
  animation: pulse 2s ease-in-out infinite;
}

@keyframes in { to { opacity: 1; transform: none; } }
@keyframes pulse { 50% { opacity: 0.45; transform: scale(0.92); } }

@media (max-width: 760px) {
  .links { display: none; }
  .nav { height: 64px; }
  .cta .btn { --h: 46px; padding: 0 22px; }
  .controls { left: 16px; right: 16px; justify-content: flex-end; }
}

@media (prefers-reduced-motion: reduce) {
  .stage { transition: none; }
  .copy > *, .nav, .controls { transition-duration: 0.01s; animation-duration: 0.01s; }
  .dot, .ignite-ring { animation: none; }
}
