body {
  margin: 0;
  padding: 0;
  font-family: 'Segoe UI', Tahoma, sans-serif;
  background: linear-gradient(135deg, #fc00ff, #00dbde);
  color: white;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ===== HEADER ===== */
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(0, 0, 0, 0.25);
  padding: 20px 40px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.5);
}
header h1 {
  font-size: 2em;
  margin: 0;
}
#admin-icon {
  font-size: 24px;
  cursor: pointer;
}

/* ===== SEARCH SECTION ===== */
#search-bar {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 30px auto;
  width: 85%;
}
input[type="text"] {
  flex-grow: 1;
  padding: 12px 16px;
  border: none;
  border-radius: 8px;
  font-size: 1em;
}
button {
  background: rgba(0, 0, 0, 0.3);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 10px 16px;
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
  transition: 0.2s ease;
}
button:hover {
  background: rgba(255,255,255,0.2);
}

/* ===== MODE SELECTION ===== */
.mode-button {
  background-color: #9b25d1;
  color: white;
  border: none;
  padding: 8px 16px;
  margin: 0 5px;
  border-radius: 8px;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.3s ease, color 0.3s ease;
}
.mode-button:hover {
  background-color: #b145f2;
}
.mode-button.active {
  background-color: #ffffff;
  color: #9b25d1;
  border: 2px solid #9b25d1;
}

/* ===== NOW PLAYING SECTION ===== */
.card, #now-playing, .playlist {
  background: rgba(0,0,0,0.35);
  margin: 20px auto;
  padding: 20px;
  border-radius: 12px;
  width: 85%;
  box-shadow: 0 0 20px rgba(0,0,0,0.4);
}
#now-track {
  font-size: 1.1em;
  font-weight: bold;
}
#progress-container {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 15px;
  font-family: 'Courier New', monospace;
  color: #fff;
}
#progress-bar {
  flex: 1;
  height: 10px;
  border-radius: 5px;
  background: linear-gradient(to right, #00ffff, #ff66cc);
  outline: none;
}

/* ===== TRACK RESULT ===== */
.track {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(255,255,255,0.05);
  margin: 8px auto;
  padding: 12px 16px;
  border-radius: 8px;
  width: 85%;
  transition: all 0.2s ease;
}
.track:hover {
  background: rgba(255,255,255,0.1);
}
.track-title {
  font-weight: bold;
  font-size: 1em;
}

/* ===== PLAYLIST ===== */
.playlist-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
.vote-count {
  font-size: 0.85em;
  color: #ccc;
}

/* ===== DJ CONTROLS ===== */
#dj-controls {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin: 15px auto;
}
#dj-controls.hidden {
  display: none !important;
}

/* ===== ADMIN POPUP ===== */
#admin-popup {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  justify-content: center;
  align-items: center;
  z-index: 999;
  display: none;
}
#admin-popup.show {
  display: flex;
}
.popup-content {
  background: #222;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 0 20px #000;
  color: white;
  text-align: center;
  width: 300px;
}
.popup-content input {
  width: 100%;
  padding: 10px;
  border-radius: 6px;
  margin: 10px 0;
}

/* ===== ICONS ===== */
.track-title.spotify::before,
.playlist-title.spotify::before {
  content: "🎵 ";
  color: #1DB954;
  margin-right: 6px;
}
.track-title.youtube::before,
.playlist-title.youtube::before {
  content: "📺 ";
  color: #FF0000;
  margin-right: 6px;
}
.track-title,
.playlist-title {
  display: inline-block;
  font-weight: bold;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  #search-bar {
    flex-direction: column;
    width: 90%;
  }
  input[type="text"] {
    width: 100%;
  }
  .track, .playlist-item, .card {
    width: 95%;
  }

  #search-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 30px;
    width: 90%;
    margin-left: auto;
    margin-right: auto;
  }

  #source-buttons {
    display: flex;
    gap: 10px;
  }

  .source-button {
    padding: 8px 14px;
    background: rgba(255,255,255,0.1);
    border: none;
    border-radius: 8px;
    color: white;
    font-weight: bold;
    cursor: pointer;
  }

  .source-button.active {
    background: rgba(0,0,0,0.4);
    box-shadow: 0 0 8px #000;
  }

  /* ===== TOP BAR / HEADER CENTRAL MODERNE ===== */
  #top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0, 0, 0, 0.25);
    padding: 15px 25px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.4);
    position: sticky;
    top: 0;
    z-index: 10;
  }

  .site-title {
    flex-grow: 1;
    text-align: center;
    font-size: 1.4em;
    font-weight: bold;
    color: white;
  }

  .top-buttons {
    display: flex;
    flex-direction: column;
    gap: 5px;
  }

  .top-buttons button {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: none;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 0.95em;
    cursor: pointer;
    transition: 0.2s ease;
  }

  .top-buttons button:hover {
    background: rgba(255, 255, 255, 0.25);
  }

  .left-placeholder {
    display: none;
  }
}
