/* ОБЩИЕ СТИЛИ */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 16px;
  line-height: 1.5;
}

body {
  font-family: 'Roboto', sans-serif;
  color: #e0e0e0;
  width: 100%;
  height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  margin: 0;
  padding: 0;
  background: linear-gradient(
    45deg,
    #ff0000, /* Красный */
    #ffa500, /* Оранжевый */
    #ffff00, /* Жёлтый */
    #00ff00, /* Зелёный */
    #00bfff, /* Голубой */
    #0000ff, /* Синий */
    #8a2be2  /* Фиолетовый */
  );
  background-size: 400% 400%;
  animation: rainbowGradient 20s linear infinite;
}

@keyframes rainbowGradient {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* СТИЛИ ПЛЕЕРА */
.player {
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.75);
  padding: 0;
  border-radius: 0;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  position: fixed;
  top: 0;
  left: 0;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center; /* Центрируем элементы плеера */
}

.track-list {
  margin-bottom: 20px;
  padding-top: 60px;
  width: 100%;
}

.track, .track-item {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 15px;
  margin: 5px 0;
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
  gap: 16px;
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
}

.track {
  background: rgba(255, 255, 255, 0.1);
  color: #e0e0e0;
}

.track:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: scale(1.02);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.track-item {
  background: rgba(29, 185, 84, 0.9);
  color: white;
  padding: 12px;
  margin: 8px 0;
}

.track-item:hover {
  background: rgba(22, 153, 64, 0.95);
  transform: scale(1.02);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.track-cover {
  width: 64px;
  height: 64px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  border: 2px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.track-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  max-width: calc(100% - 100px);
}

.track-title {
  font-weight: 600;
  margin-bottom: 4px;
  font-size: 16px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: white;
}

.track-artist {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.8);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ПАНЕЛЬ УПРАВЛЕНИЯ */
/* ПАНЕЛЬ УПРАВЛЕНИЯ — обновлённый контейнер */
.controls {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 16px 20px;
  background-color: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 100;
}

/* Ползунок громкости */
#volume {
  width: 90px;
  margin: 0 8px;
  accent-color: #ffd700;
}

/* Кнопка «Ещё» — теперь справа от ползунка */
.btn-more {
  display: inline-block;
  padding: 10px 20px;
  background-color: #00b83a;
  color: white;
  border: none;
  border-radius: 25px;
  font-size: 16px;
  font-weight: 500;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  white-space: nowrap;
  position: relative;
  overflow: hidden;
  /* Дополнительные стили для позиционирования */
  margin-left: 8px; /* Отступ от ползунка */
}

.btn-more::before {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  height: 6px;
  background-color: rgba(0, 184, 58, 0.4);
  border-radius: 3px;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.btn-more:hover::before {
  opacity: 1;
}

.btn-more:hover {
  background-color: #009e33;
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.2);
}

button {
  background: none;
  border: none;
  color: #ffd700;
  font-size: 22px;
  cursor: pointer;
  margin: 0;
  padding: 10px 14px;
  border-radius: 50%;
  transition: all 0.3s ease;
}

button:hover {
  background-color: rgba(255, 215, 0, 0.2);
  transform: scale(1.1);
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.4);
}

#volume {
  width: 90px;
  margin: 0 8px;
  accent-color: #ffd700;
}

/* СТИЛИ ДЛЯ СЧЁТЧИКА ПРОСЛУШИВАНИЙ */
.play-count {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.7);
  background-color: rgba(0, 0, 0, 0.3);
  padding: 6px 10px;
  border-radius: 8px;
  min-width: 32px;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: auto;
  transition: background-color 0.3s ease;
}

.track-item:hover .play-count {
  background-color: rgba(0, 0, 0, 0.5);
  color: #ffd700;
}

@media (max-width: 600px) {
  .play-count {
    font-size: 11px;
    padding: 4px 8px;
    margin-top: 6px;
    margin-left: 0;
    align-self: flex-end;
  }

  .track-info {
    max-width: calc(100% - 80px);
  }
}

.track-item {
  padding-right: 20px;
}

#vibe-title {
  position:

#vibe-title {
  position: fixed;
  top: 15px;
  right: 20px;
  font-family: 'Roboto', sans-serif;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 1px;
  color: #ff0000;
  z-index: 1000;
  transition: color 1.5s ease-in-out;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

@media (max-width: 768px) {
  #vibe-title {
    font-size: 18px;
    right: 15px;
    top: 12px;
  }
}

.background-animation {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  background:
    radial-gradient(circle at 20% 30%, rgba(255, 90, 120, 0.2)),
    radial-gradient(circle at 80% 70%, rgba(100, 200, 255, 0.15)),
    linear-gradient(45deg, #1a1a2e, #16213e);
  opacity: 0.8;
  animation:
    move-gradient 20s linear infinite,
    pulse-opacity 8s ease-in-out infinite;
}

@keyframes move-gradient {
  0% {
    background-position:
      0% 0%,
      100% 100%,
      0% 0%;
  }
  50% {
    background-position:
      100% 100%,
      0% 0%,
      50% 50%;
  }
  100% {
    background-position:
      0% 0%,
      100% 100%,
      100% 100%;
  }
}

@keyframes pulse-opacity {
  0%, 100% { opacity: 0.7; }
  50% { opacity: 0.9; }
}

.background-animation:hover {
  transform: scale(1.02);
  transition: transform 0.5s ease;
}

.btn-more {
  display: inline-block;
  padding: 10px 20px;
  background-color: #00b83a;
  color: white;
  border: none;
  border-radius: 25px;
  font-size: 16px;
  font-weight: 500;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}

/* Зелёный фон под кнопкой */
.btn-more::before {
  content: '';
  position: absolute;
  bottom: -8px; /* Смещение вниз за пределы кнопки */
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  height: 6px;
  background-color: rgba(0, 184, 58, 0.4); /* Полупрозрачный зелёный */
  border-radius: 3px;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.btn-more:hover::before {
  opacity: 1;
}

.btn-more:hover {
  background-color: #009e33;
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.2);
}

.link-back {
  margin-left: 15px;
  font-size: 13px;
}

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  z-index: 2000;
  overflow-y: auto;
  padding: 20px;
}

.modal.active {
  display: block;
}

.modal-container {
  max-width: 800px;
  margin: 40px auto;
  background-color: #1e1e2f;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  overflow: hidden;
  position: relative;
}

.modal-header {
  padding: 20px 25px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-title {
  color: #ffd700;
  font-size: 20px;
  font-weight: 600;
}

.modal-close {
  background: none;
  border: none;
  color: #fff;
  font-size: 24px;
  cursor: pointer;
  transition: color 0.3s;
}

.modal-close:hover {
  color: #ffd700;
}

.modal-body {
  padding: 25px;
}

.modal-footer {
  padding: 15px 25px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: right;
}

.modal-btn {
  background-color: #4CAF50;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  margin-left: 10px;
  transition: background-color 0.3s;
}

.modal-btn:hover {
  background-color: #45a049;
}

.modal-btn.cancel {
  background-color: #f44336;
}

.modal-btn.cancel:hover {
  background-color: #d32f2f;
}

@media (max-width: 768px) {
  .modal-container {
    margin: 20px auto;
    border-radius: 8px;
    max-width: 95%;
  }

  .modal-header,
  .modal-footer {
    padding: 15px;
  }

  .modal-body,
  .modal-footer {
    padding: 15px;
  }
}

.tooltip {
  position: absolute;
  background-color: rgba(0, 0, 0, 0.8);
  color: white;
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 12px;
  white-space: nowrap;
  z-index: 3000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.tooltip.show {
  opacity: 1;
}

.tooltip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -5px;
  border-width: 5px;
  border-style: solid;
  border-color: rgba(0, 0, 0, 0.8) transparent

.tooltip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -5px;
  border-width: 5px;
  border-style: solid;
  border-color: rgba(0, 0, 0, 0.8) transparent transparent transparent;
  transition: all 0.3s ease;
}

.fade-in {
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.pulse {
  animation: pulse-anim 1.5s infinite;
}

@keyframes pulse-anim {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.05);
    opacity: 0.8;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.spin {
  animation: spin-anim 2s linear infinite;
}

@keyframes spin-anim {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.slide-in {
  opacity: 0;
  transform: translateX(-20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.slide-in.visible {
  opacity: 1;
  transform: translateX(0);
}

/* Адаптация для мобильных устройств */
@media (max-width: 480px) {
  .controls {
    flex-direction: column;
    align-items: center;
    padding: 20px 10px;
  }

  button {
    margin: 8px 0;
    font-size: 20px;
    padding: 12px 16px;
  }

  #volume {
    width: 100%;
    max-width: 250px;
    margin: 10px auto;
  }

  .track-info {
    max-width: calc(100% - 60px);
  }

  .track-title {
    font-size: 14px;
  }

  .track-artist {
    font-size: 12px;
  }

  .play-count {
    font-size: 10px;
    padding: 3px 6px;
    min-width: 24px;
  }

  .btn-more {
    font-size: 14px;
    padding: 8px 16px;
  }
}

/* Дополнительные стили для интерактивности */
.interactive-hover:hover {
  transform: scale(1.03);
  transition: transform 0.2s ease;
}

.highlight {
  box-shadow: 0 0 12px rgba(255, 215, 0, 0.6);
  border-color: #ffd700;
  transition: box-shadow 0.3s ease;
}

.highlight:hover {
  box-shadow: 0 0 20px rgba(255, 215, 0, 0.9);
}

/* Стили для полноэкранного режима */
.fullscreen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 9999;
  background-color: #000;
}

/* Анимация появления модального окна */
.modal-container {
  animation: modal-fade-in 0.5s forwards;
}

@keyframes modal-fade-in {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Плавное исчезновение */
.fade-out {
  opacity: 1;
  transition: opacity 0.5s ease;
}

.fade-out.hidden {
  opacity: 0;
}

/* Стили для кнопок управления воспроизведением */
.control-btn {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background-color: transparent;
  border: 2px solid #ffd700;
  color: #ffd700;
  font-size: 18px;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.control-btn:hover {
  background-color: rgba(255, 215, 0, 0.2);
  transform: scale(1.1);
}

.control-btn.active {
  background-color: #ffd700;
  color: #000;
}

/* Индикатор загрузки */
.loading-indicator {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid transparent;
  border-top: 3px solid #ffd700;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  vertical-align: middle;
  margin-right: 8px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Финальные настройки */
* {
  scrollbar-width: thin;
  scrollbar-color: #666 #333;
}

*::-webkit-scrollbar {
  width: 8px;
}

*::-webkit-scrollbar-track {
  background: #222;
}

*::-webkit-scrollbar-thumb {
  background-color: #666;
  border-radius: 4px;
}

/* Предотвращение выделения текста на кнопках */
button, .btn-more, .control-btn {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

#now-playing {
  color: #ffd700; /* Золотой цвет */
  font-size: 16px;
  margin: 10px 0;
  text-align: center;
}

