/* Reset and Base Styles */
:root {
  --primary-color: #00b7eb;
  --secondary-color: #ffe66d;
  --shadow-light: rgba(0, 183, 235, 0.2);
  --shadow-strong: rgba(0, 183, 235, 0.6);
  --transition-ease: 0.3s ease;
}

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

body {
  font-family: 'Montserrat', sans-serif;
  background: #000;
  color: #fff;
  line-height: 1.6;
  overscroll-behavior: none;
  user-select: none;
  transition: background 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

body.caribbean-theme {
  background: linear-gradient(135deg, #00c4cc, #ff6b6b, #4ecdc4, var(--secondary-color));
  background-size: 400% 400%;
  animation: gradientAnimation 15s ease infinite;
}

body.sunset-theme {
  background: linear-gradient(135deg, #ff6b6b, #ffa500, #ff4500, #800080);
  background-size: 400% 400%;
  animation: gradientAnimation 15s ease infinite;
}

@keyframes gradientAnimation {
  0% { background plunder: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Intro Animation */
.intro-animation {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: linear-gradient(135deg, #00c4cc, #ff6b6b, #4ecdc4);
  background-size: 400% 400%;
  animation: gradientAnimation 15s ease infinite;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 3000;
  opacity: 1;
  transition: opacity 1s ease;
}

.intro-animation.hidden {
  opacity: 0;
  pointer-events: none;
}

.intro-content {
  text-align: center;
  color: #fff;
  text-shadow: 0 0 15px rgba(0, 183, 235, 0.6);
}

.intro-title {
  font-size: clamp(2rem, 8vw, 4rem);
  margin-bottom: 1rem;
  animation: bounceIn 1s ease;
}

.intro-emojis span {
  font-size: 2.5rem;
  margin: 0 0.5rem;
  display: inline-block;
  animation: emojiPop 1.5s ease infinite;
}

.intro-emojis span:nth-child(2) { animation-delay: 0.2s; }
.intro-emojis span:nth-child(3) { animation-delay: 0.4s; }

.intro-subtitle {
  font-size: 1.5rem;
  opacity: 0;
  animation: fadeInUp 1s ease 1s forwards;
}

@keyframes bounceIn {
  0% { transform: scale(0.3); opacity: 0; }
  60% { transform: scale(1.2); opacity: 1; }
  100% { transform: scale(1); }
}

@keyframes emojiPop {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-1rem); }
}

@keyframes fadeInUp {
  0% { opacity: 0; transform: translateY(1rem); }
  100% { opacity: 1; transform: translateY(0); }
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
  text-align: center;
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 2.5rem;
  animation: fadeIn 1.5s ease-out;
  opacity: 0;
  transition: opacity 1s ease;
}

@keyframes fadeIn {
  0% { opacity: 0; transform: translateY(1rem); }
  100% { opacity: 1; transform: translateY(0); }
}

/* Header */
header {
  position: relative;
}

header.playing h1 {
  animation: pulse 1.2s ease-in-out infinite;
  text-shadow: 0 0 20px var(--primary-color);
}

header.playing::after {
  content: '♪ ♫';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  font-size: 2.5rem;
  color: var(--primary-color);
  text-shadow: 0 0 15px var(--shadow-strong);
  animation: notesRise 3s ease-out infinite;
  opacity: 0;
}

header h1 {
  font-size: clamp(2rem, 8vw, 4rem);
  color: var(--primary-color);
  text-shadow: 0 0 15px var(--shadow-light);
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.25rem;
  transition: var(--transition-ease);
}

header h1:hover {
  text-shadow: 0 0 25px #00f0ff, 0 0 50px #00f0ff;
  transform: scale(1.02);
}

header p {
  font-size: clamp(1rem, 4vw, 1.5rem);
  color: var(--secondary-color);
  text-shadow: 0 0 8px rgba(255, 230, 109, 0.5);
  font-weight: 600;
}

/* Tracks Section */
.image-and-tracks {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 550px) minmax(0, 1fr);
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  min-height: 700px;
}

.track-list-left,
.track-list-right {
  display: grid;
  gap: 1.5rem;
  justify-items: center;
}

.track-item {
  --size: 140px;
  background: rgba(255, 255, 255, 0.15);
  padding: 1.25rem;
  border-radius: 50%;
  cursor: pointer;
  transition: var(--transition-ease);
  display: grid;
  place-items: center;
  width: var(--size);
  height: var(--size);
  box-shadow: 0 5px 20px var(--shadow-light);
  animation: float 4s ease-in-out infinite;
  backdrop-filter: blur(5px);
  font-size: 1rem;
  font-weight: 500;
  position: relative;
}

.track-item:hover {
  transform: scale(1.15);
  box-shadow: 0 10px 30px var(--shadow-strong);
  background: rgba(255, 255, 255, 0.25);
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-1rem); }
}

.track-item::before {
  content: '';
  position: absolute;
  inset: -0.5rem;
  border-radius: 50%;
  background: radial-gradient(circle, var(--shadow-light) 0%, transparent 70%);
  z-index: -1;
  opacity: 0;
  transition: opacity var(--transition-ease);
}

.track-item:hover::before {
  opacity: 1;
}

/* Animation Keyframes */
@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

@keyframes notesRise {
  0% {
    opacity: 1;
    transform: translateX(-50%) translateY(0) rotate(0deg);
  }
  100% {
    opacity: 0;
    transform: translateX(-50%) translateY(-4rem) rotate(30deg);
  }
}

/* Image Container */
.image-container {
  position: relative;
  width: 100%;
  max-width: 550px;
  height: clamp(350px, 60vw, 650px);
  margin: 0 auto;
  isolation: isolate;
  place-self: center;
}

.image-layer {
  position: absolute;
  inset: 0;
  transition: transform 0.2s ease-out;
  will-change: transform;
  opacity: 0.9;
  filter: brightness(1.15) contrast(1.15);
}

.image-layer img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

.image-layer.background {
  opacity: 0.8;
  z-index: 4;
}

.image-layer.red {
  z-index: 1;
}

.image-layer.green {
  z-index: 2;
}

.image-layer.blue {
  z-index: 3;
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  z-index: 2000;
  align-items: center;
  justify-content: center;
}

.modal-content {
  background: #fff;
  padding: 1.5rem;
  border-radius: 1rem;
  max-width: 450px;
  width: 90%;
  box-shadow: 0 10px 40px var(--shadow-light);
  position: relative;
}

.close-modal {
  position: absolute;
  top: 0.75rem;
  right: 1rem;
  font-size: 1.75rem;
  cursor: pointer;
  color: #333;
  transition: color var(--transition-ease);
}

.close-modal:hover {
  color: var(--primary-color);
}

/* Bio Section */
.bio h2 {
  font-size: clamp(1.5rem, 6vw, 2.5rem);
  color: var(--primary-color);
  margin-bottom: 1.5rem;
  text-shadow: 0 0 10px var(--shadow-light);
}

.bio p {
  font-size: clamp(1rem, 3.5vw, 1.25rem);
  color: #f0f0f0;
  max-width: 850px;
  margin: 0 auto;
  line-height: 1.9;
}

/* Footer */
footer {
  margin-top: 3rem;
  padding: 1.5rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

footer p {
  font-size: clamp(0.8rem, 2.5vw, 1rem);
  color: #999;
}

/* Emoji Animation */
.emoji {
  position: fixed;
  font-size: 1.75rem;
  pointer-events: none;
  animation: emojiDance 3s ease-out forwards;
  filter: drop-shadow(0 0 5px rgba(255, 255, 255, 0.6));
}

@keyframes emojiDance {
  0% {
    opacity: 1;
    transform: translateY(0) rotate(0deg) scale(1);
  }
  50% {
    opacity: 0.8;
    transform: translateY(-50vh) rotate(360deg) scale(2);
  }
  100% {
    opacity: 0;
    transform: translateY(-100vh) rotate(720deg) scale(1.5);
  }
}

/* Responsive Design */
@media (max-width: 900px) {
  .image-and-tracks {
    grid-template-columns: 1fr;
    gap: 2rem;
    min-height: auto;
  }

  .track-list-left,
  .track-list-right {
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    padding: 0 0.5rem;
  }
}

@media (max-width: 600px) {
  .container {
    padding: 1.5rem 0.75rem;
  }
  .track-item {
    --size: 110px;
    padding: 0.75rem;
  }
  .image-container {
    height: auto;
    min-height: 250px;
    max-height: 400px;
    width: 100%;
    max-width: 100%;
  }
  header h1 {
    letter-spacing: 0.125rem;
  }

  .image-layer img {
    object-fit: contain;
  }
}

.style-toggle {
  position: fixed;
  top: 20px;
  right: 20px;
  padding: 10px 20px;
  background-color: #1a3c5a;
  color: #fff;
  border: none;
  border-radius: 5px;
  font-family: 'Montserrat', sans-serif;
  font-size: 16px;
  cursor: pointer;
  transition: background-color 0.3s ease;
  z-index: 1000;
}

.style-toggle:hover {
  background-color: #2a5c8a;
}

.book-now {
  text-align: center;
  margin: 2rem 0;
}

.book-now-button {
  display: inline-block;
  padding: 0.8rem 1.8rem;
  background-color: #1a3c5e;
  color: #fff;
  font-family: 'Montserrat', sans-serif;
  font-size: 1.1rem;
  font-weight: 400;
  text-decoration: none;
  border: 2px solid #1a3c5e;
  border-radius: 5px;
  transition: background-color 0.3s, color 0.3s;
}

.book-now-button:hover {
  background-color: transparent;
  color: #1a3c5e;
}

/* Confetti */
.confetti {
  position: fixed;
  width: 10px;
  height: 10px;
  background: #fff;
  pointer-events: none;
  z-index: 90;
  animation: confettiFall 3s linear forwards;
}

@keyframes confettiFall {
  0% {
    opacity: 1;
    transform: translateY(0) rotate(0deg);
  }
  100% {
    opacity: 0;
    transform: translateY(100vh) rotate(720deg);
  }
}

/* Lasers */
.laser {
  position: fixed;
  width: 100vw;
  height: 2px;
  background: #ff0000;
  pointer-events: none;
  z-index: -100;
  animation: laserMove 1.5s linear forwards;
  opacity: 0.7;
  box-shadow: 0 0 10px currentColor;
}

@keyframes laserMove {
  0% {
    transform: translateX(-10%) rotate(0deg);
    opacity: 0.7;
  }
  100% {
    transform: translateX(110%) rotate(0deg);
    opacity: 0;
  }
}

/* Disco Lights */
.disco-lights {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100px;
  height: 100px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.8) 10%, transparent 70%);
  pointer-events: none;
  z-index: 80;
  animation: discoSpin 10s linear infinite;
}

.disco-lights::before,
.disco-lights::after {
  content: '';
  position: absolute;
  width: 200vw;
  height: 200px;
  top: 50%;
  left: 50%;
  transform-origin: center;
  opacity: 0.3;
}

.disco-lights::before {
  background: conic-gradient(
    from 0deg,
    rgba(255, 0, 0, 0.5),
    rgba(0, 255, 0, 0.5),
    rgba(0, 0, 255, 0.5),
    rgba(255, 255, 0, 0.5),
    rgba(255, 0, 255, 0.5),
    rgba(0, 255, 255, 0.5),
    rgba(255, 0, 0, 0.5)
  );
  animation: discoRotate 5s linear infinite;
}

.disco-lights::after {
  background: conic-gradient(
    from 180deg,
    rgba(0, 255, 255, 0.5),
    rgba(255, 0, 255, 0.5),
    rgba(255, 255, 0, 0.5),
    rgba(0, 0, 255, 0.5),
    rgba(0, 255, 0, 0.5),
    rgba(255, 0, 0, 0.5),
    rgba(0, 255, 255, 0.5)
  );
  animation: discoRotate 7s linear infinite reverse;
}

@keyframes discoSpin {
  0% {
    transform: translateX(-50%) rotate(0deg);
  }
  100% {
    transform: translateX(-50%) rotate(360deg);
  }
}

@keyframes discoRotate {
  0% {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  100% {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

/* Party Lights (Background Glow) */
@keyframes partyGlow {
  0% { filter: brightness(1) hue-rotate(0deg); }
  50% { filter: brightness(1.2) hue-rotate(180deg); }
  100% { filter: brightness(1) hue-rotate(360deg); }
}

body.party-mode .image-container {
  animation: partyGlow 5s ease infinite;
}
