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

:root {
  --lime: #deff00;
  --black: #000000;
  --glow: 0 0 20px rgba(222, 255, 0, 0.6), 0 0 60px rgba(222, 255, 0, 0.25);
  --glow-strong: 0 0 30px rgba(222, 255, 0, 0.9), 0 0 80px rgba(222, 255, 0, 0.4), 0 0 120px rgba(222, 255, 0, 0.15);
}

html, body {
  width: 100%;
  height: 100%;
  background: var(--black);
  color: var(--lime);
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  overflow: hidden;
}

/* ─── AUTH SCREEN ─────────────────────────────────────────────────── */

#auth-screen {
  position: fixed;
  inset: 0;
  background: var(--black);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 48px;
  z-index: 1000;
  transition: opacity 0.4s ease;
}

#auth-screen.hidden {
  opacity: 0;
  pointer-events: none;
}

#auth-logo {
  font-size: clamp(2.5rem, 8vw, 6rem);
  font-weight: 700;
  letter-spacing: 0.05em;
  text-shadow: var(--glow-strong);
  user-select: none;
}

#auth-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  width: min(320px, 80vw);
}

#auth-input {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid rgba(182, 255, 0, 0.4);
  color: var(--lime);
  font-family: inherit;
  font-size: 1.2rem;
  letter-spacing: 0.15em;
  text-align: center;
  padding: 8px 0;
  outline: none;
  transition: border-color 0.2s;
  caret-color: var(--lime);
}

#auth-input:focus {
  border-bottom-color: var(--lime);
  text-shadow: var(--glow);
}

#auth-input::placeholder {
  color: rgba(182, 255, 0, 0.25);
  letter-spacing: 0.1em;
}

#auth-error {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  color: rgba(182, 255, 0, 0.5);
  text-transform: uppercase;
  height: 1em;
  transition: opacity 0.3s;
  opacity: 0;
}

#auth-error.visible {
  opacity: 1;
}

/* ─── MAIN PLAYER ─────────────────────────────────────────────────── */

#player {
  position: fixed;
  inset: 0;
  background: var(--black);
  opacity: 0;
  transition: opacity 0.6s ease;
}

#player.visible {
  opacity: 1;
}

#video-container {
  position: absolute;
  inset: 0;
}

#main-video,
#next-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

#next-video {
  opacity: 0;
  pointer-events: none;
}

/* ─── OVERLAY ─────────────────────────────────────────────────────── */

#overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  transition: opacity 0.5s ease;
}

#overlay.hidden {
  opacity: 0;
}

#logo {
  font-size: clamp(2rem, 7vw, 5.5rem);
  font-weight: 700;
  letter-spacing: 0.08em;
  text-shadow: var(--glow-strong);
  user-select: none;
}

/* ─── METADATA OVERLAY ────────────────────────────────────────────── */

#metadata-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  padding: 48px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
}

#metadata-overlay.visible {
  opacity: 1;
}

#metadata-panel {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-width: 480px;
}

#meta-title {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-shadow: var(--glow);
}

#meta-artist {
  font-size: 0.9rem;
  letter-spacing: 0.08em;
  opacity: 0.7;
}

#meta-year {
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  opacity: 0.5;
}

#meta-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.tag {
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border: 1px solid rgba(182, 255, 0, 0.35);
  padding: 3px 8px;
  opacity: 0.6;
}

/* ─── NOW PLAYING ─────────────────────────────────────────────────── */

#now-playing {
  position: absolute;
  bottom: 56px;
  right: 56px;
  text-align: right;
  pointer-events: auto;
  cursor: pointer;
  transition: opacity 0.4s ease;
  user-select: none;
}

#now-playing.hidden {
  opacity: 0;
  pointer-events: none;
}

#now-playing-label {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--lime);
  opacity: 0.7;
  max-width: 50vw;
  word-wrap: break-word;
}


/* ─── TRANSITION FADE ─────────────────────────────────────────────── */

#transition-fade {
  position: absolute;
  inset: 0;
  background: var(--black);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

#transition-fade.active {
  opacity: 1;
}
