/* ==========================================================================
   I AM THAT MUSIC (IAT) — global stylesheet
   ========================================================================== */

:root {
  --bg: #060608;
  --bg-elevated: #0d0d12;
  --purple: #7c3aed;
  --purple-light: #a78bfa;
  --blue: #22d3ee;
  --white: #f5f5f7;
  --muted: #9ca3af;
  --line: rgba(245, 245, 247, 0.08);
  --font-display: "Space Grotesk", "Inter", sans-serif;
  --font-body: "Inter", sans-serif;
  --nav-height: 76px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--white);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.1;
  margin: 0 0 0.5em;
  letter-spacing: -0.02em;
}

p { color: var(--muted); }

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 32px;
}

/* ---------- Nav ---------- */

.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  z-index: 100;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background 0.3s ease, border-color 0.3s ease;
}

.site-nav.is-scrolled {
  background: rgba(6, 6, 8, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.04em;
}

.nav-logo img { height: 34px; width: auto; }

.nav-logo .mark {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  overflow: hidden;
  flex-shrink: 0;
}

.nav-logo .mark img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
  font-size: 0.92rem;
}

.nav-links a {
  color: var(--muted);
  transition: color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--white);
}

.nav-cta {
  padding: 10px 20px;
  border-radius: 999px;
  background: var(--white);
  color: var(--bg) !important;
  font-weight: 600;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--white);
  font-size: 1.5rem;
  cursor: pointer;
}

@media (max-width: 800px) {
  .nav-links {
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: rgba(6, 6, 8, 0.97);
    backdrop-filter: blur(12px);
    flex-direction: column;
    padding: 24px 32px 32px;
    gap: 20px;
    border-bottom: 1px solid var(--line);
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
  }
  .nav-links.is-open {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }
  .nav-toggle { display: block; }
}

/* ---------- Continuous scene background ----------
   One fixed backdrop behind the entire document: a live video (Stage 1)
   handed off progressively to a pre-decoded canvas (Stage 2) as caching
   catches up, playing across the whole document scroll — not just the
   hero — so every section (Home/About/Tour/Music/Contact) reads as one
   continuous camera move rather than separate flat pages.

   Opacity here starts at 0 and is otherwise entirely controlled by JS
   inline styles (js/scene-video.js): a transition is applied only for
   the one-time initial fade-in, then removed, so every later handoff
   between the two layers is an instant, imperceptible cut rather than a
   visible cross-fade. */

.scene-bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  background: #000;
  overflow: hidden;
}

.scene-frame {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
}

.scene-overlay {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    rgba(3, 3, 6, 0.45) 0%,
    rgba(3, 3, 6, 0.55) 35%,
    rgba(3, 3, 6, 0.72) 75%,
    rgba(3, 3, 6, 0.85) 100%
  );
}

/* ---------- Chapters ---------- */

.chapter {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 140px 0;
}

.chapter-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 32px;
}

.chapter--hero {
  text-align: center;
}

.chapter--hero .eyebrow {
  font-size: 0.8rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 18px;
  display: block;
}

.chapter--hero h1 {
  font-size: clamp(2.6rem, 8vw, 6.5rem);
  color: var(--white);
  text-shadow: 0 10px 60px rgba(0, 0, 0, 0.6);
}

.chapter--hero .sub {
  color: var(--muted);
  font-size: clamp(0.95rem, 1.4vw, 1.15rem);
  max-width: 480px;
  margin: 18px auto 0;
}

.glass-card {
  background: rgba(6, 6, 8, 0.55);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 24px;
  padding: 56px;
}

@media (max-width: 700px) {
  .glass-card { padding: 32px 24px; }
  .chapter { padding: 100px 0; }
}

.chapter .eyebrow {
  font-size: 0.78rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 14px;
  display: block;
}

.chapter h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 40px;
}

.scroll-cue {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  animation: bob 2s ease-in-out infinite;
}

.scroll-cue .line {
  width: 1px;
  height: 30px;
  background: linear-gradient(var(--blue), transparent);
}

@keyframes bob {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 8px); }
}

/* ---------- Shared content pieces (used inside .glass-card chapters) ---------- */

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

@media (max-width: 860px) {
  .grid-3 { grid-template-columns: 1fr; }
}

.card {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 32px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.card:hover {
  border-color: rgba(124, 58, 237, 0.4);
  transform: translateY(-4px);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.92rem;
}

.btn-primary {
  background: linear-gradient(135deg, var(--purple), var(--blue));
  color: #05050a;
}

.btn-ghost {
  border: 1px solid var(--line);
  color: var(--white);
}

.btn-ghost:hover { border-color: var(--purple-light); }

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 56px 0 32px;
}

.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 32px;
  margin-bottom: 40px;
}

.footer-social {
  display: flex;
  gap: 18px;
}

.footer-social a {
  color: var(--muted);
  font-size: 0.9rem;
  border: 1px solid var(--line);
  padding: 8px 16px;
  border-radius: 999px;
}

.footer-social a:hover { color: var(--white); border-color: var(--purple-light); }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.8rem;
  color: var(--muted);
}

/* ---------- Sound-on prompt (muted-autoplay unmute button) ---------- */

#soundToggle {
  position: fixed;
  left: 50%;
  bottom: 32px;
  transform: translateX(-50%);
  z-index: 500;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 34px;
  border: none;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--purple), var(--blue));
  color: #05050a;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
  cursor: pointer;
  box-shadow: 0 8px 40px rgba(124, 58, 237, 0.55);
  animation: soundToggleAttract 1.4s ease-in-out infinite;
}

#soundToggle .icon {
  display: inline-block;
  animation: soundToggleRing 1.4s ease-in-out infinite;
}

#soundToggle:hover {
  filter: brightness(1.1);
}

@keyframes soundToggleAttract {
  0%, 100% {
    transform: translateX(-50%) scale(1);
    box-shadow: 0 8px 40px rgba(124, 58, 237, 0.55), 0 0 0 0 rgba(34, 211, 238, 0.5);
  }
  50% {
    transform: translateX(-50%) scale(1.08);
    box-shadow: 0 8px 50px rgba(124, 58, 237, 0.75), 0 0 0 18px rgba(34, 211, 238, 0);
  }
}

@keyframes soundToggleRing {
  0%, 100% { transform: rotate(0deg); }
  15% { transform: rotate(-18deg); }
  30% { transform: rotate(14deg); }
  45% { transform: rotate(-10deg); }
  60% { transform: rotate(6deg); }
  75%, 100% { transform: rotate(0deg); }
}

@media (max-width: 700px) {
  #soundToggle { padding: 14px 24px; font-size: 0.95rem; bottom: 22px; gap: 10px; }
}

/* ---------- Bio pull-quotes ---------- */

.bio-quote {
  border-left: 3px solid var(--purple-light);
  padding-left: 20px;
  margin: 28px 0;
  font-style: italic;
  font-size: 1.05rem;
  color: var(--white);
}

/* ---------- Policy / legal text pages ---------- */

.policy-page .chapter-inner {
  max-width: 860px;
}

.policy-page h3 {
  font-size: 1.2rem;
  margin-top: 36px;
}

.policy-page ul {
  color: var(--muted);
  margin: 0 0 20px;
  padding-left: 22px;
}

.policy-page li {
  margin-bottom: 8px;
}

.policy-page p a {
  color: var(--blue);
  text-decoration: underline;
}

/* ---------- Tour table ---------- */

.tour-list { border-top: 1px solid var(--line); }

.tour-row {
  display: grid;
  grid-template-columns: 120px 1fr 1fr 140px;
  gap: 20px;
  align-items: center;
  padding: 26px 0;
  border-bottom: 1px solid var(--line);
}

.tour-row .date { color: var(--blue); font-family: var(--font-display); font-weight: 600; }
.tour-row .venue { color: var(--muted); font-size: 0.88rem; }
.tour-row .city { font-weight: 600; }

@media (max-width: 700px) {
  .tour-row { grid-template-columns: 1fr; gap: 8px; text-align: left; }
}

/* ---------- Music page ---------- */

.player-card {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 28px;
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 18px;
}

.player-card .art {
  width: 64px;
  height: 64px;
  border-radius: 10px;
  background: conic-gradient(from 120deg, var(--purple), var(--blue));
  flex-shrink: 0;
}

.player-card .meta { flex: 1; }
.player-card .meta h3 { margin: 0 0 4px; font-size: 1rem; }
.player-card .meta p { margin: 0; font-size: 0.85rem; }

/* ---------- Contact form ---------- */

.contact-form {
  display: grid;
  gap: 20px;
  max-width: 640px;
}

.contact-form .row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

@media (max-width: 600px) {
  .contact-form .row-2 { grid-template-columns: 1fr; }
}

.contact-form label {
  display: block;
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 8px;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 13px 16px;
  color: var(--white);
  font-family: var(--font-body);
  font-size: 0.95rem;
}

.contact-form textarea { min-height: 120px; resize: vertical; }

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--purple-light);
}

.contact-info {
  display: grid;
  gap: 22px;
}

.contact-info .item .label {
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: 6px;
}
