/* ------------------------------
   CrossFire Radio Sidebar Player
   mainplay.css
   ------------------------------ */

* {
  box-sizing: border-box;
}

/* Player Container */
.player-shell {
  background: rgba(10, 10, 10, 0.95);
  border-radius: 14px;
  padding: 18px 22px;
  box-shadow: 0 0 25px rgba(255, 69, 0, 0.4);
  border: 1px solid rgba(255, 69, 0, 0.4);
  width: 300px;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
  overflow: hidden;
  margin: 0 auto;
  animation: fadeIn 0.8s ease-out;
}

/* Ember Particles */
.ember {
  position: absolute;
  width: 4px;
  height: 4px;
  background: radial-gradient(circle, #ff8c00 0%, transparent 70%);
  border-radius: 50%;
  opacity: 0.7;
  animation: emberFloat 6s linear infinite;
  pointer-events: none;
}

.ember:nth-child(1) { left: 10%; bottom: -10px; animation-delay: 0s; }
.ember:nth-child(2) { left: 40%; bottom: -20px; animation-delay: 1.2s; }
.ember:nth-child(3) { left: 70%; bottom: -15px; animation-delay: 2.4s; }
.ember:nth-child(4) { left: 85%; bottom: -25px; animation-delay: 3.6s; }
.ember:nth-child(5) { left: 25%; bottom: -18px; animation-delay: 4.2s; }

@keyframes emberFloat {
  0% { transform: translateY(0) scale(1); opacity: 0.8; }
  50% { opacity: 1; }
  100% { transform: translateY(-120px) scale(0.6); opacity: 0; }
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Header */
.header {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo svg {
  filter: drop-shadow(0 0 8px #ff4500);
}

.title-block {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.station-name {
  font-size: 15px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tagline {
  font-size: 10px;
  color: #ffb366;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

/* Audio Element */
.audio {
  width: 100%;
  margin-top: 4px;
  filter: drop-shadow(0 0 4px rgba(0,0,0,0.8));
}

/* Now Playing */
.now-playing {
  width: 100%;
  background: rgba(20, 10, 0, 0.6);
  border: 1px solid rgba(255, 69, 0, 0.4);
  padding: 6px 10px;
  border-radius: 6px;
  margin-top: 4px;
  text-align: center;
  font-size: 13px;
  color: #ffb366;
  letter-spacing: 0.04em;
  white-space: nowrap;
  overflow: hidden;
  position: relative;
}

.now-playing span {
  display: inline-block;
  animation: scrollText 12s linear infinite;
  padding-left: 100%;
}

@keyframes scrollText {
  0% { transform: translateX(0); }
  100% { transform: translateX(-100%); }
}

/* Controls Row */
.controls-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 6px;
}

/* Volume Control */
.volume-control {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
}

.volume-icon {
  width: 24px;
  height: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.volume-icon svg {
  filter: drop-shadow(0 0 4px #ff4500);
  transition: transform 0.15s ease, filter 0.15s ease;
}

.volume-icon.muted svg {
  filter: drop-shadow(0 0 4px #660000);
}

.volume-icon:hover svg {
  transform: scale(1.05);
}

/* Custom Volume Slider */
.volume-slider {
  -webkit-appearance: none;
  width: 100%;
  height: 6px;
  background: #222;
  border-radius: 5px;
  outline: none;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.volume-slider::-webkit-slider-runnable-track {
  background: linear-gradient(90deg, #552000, #552000);
  height: 6px;
  border-radius: 5px;
}

.volume-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  background: #ff4500;
  border-radius: 50%;
  border: 2px solid #fff;
  margin-top: -5px;
  box-shadow: 0 0 6px #ff4500;
  position: relative;
  z-index: 2;
}

.volume-slider::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, #ff4500, #ff8c00);
  transform-origin: left center;
  transform: scaleX(1);
  z-index: 1;
  pointer-events: none;
}

/* EQ Bars */
.eq-bars {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  width: 40px;
  height: 20px;
}

.eq-bar {
  flex: 1;
  background: linear-gradient(to top, #ff4500, #ffdd99);
  border-radius: 2px;
  height: 20%;
  opacity: 0.8;
  transform-origin: bottom;
}

/* Footer */
.footer-text {
  font-size: 10px;
  text-align: center;
  color: #888;
  margin-top: 4px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.footer-text a {
  color: #F4C542;
  text-decoration: none;
}

.popout-launch {
  text-align: center;
  margin-top: 12px;
}

.popout-btn {
  background: linear-gradient(90deg, #ff4500, #ff8c00);
  border: none;
  padding: 8px 14px;
  border-radius: 6px;
  color: #fff;
  font-weight: 600;
  letter-spacing: 0.05em;
  cursor: pointer;
  box-shadow: 0 0 10px rgba(255, 69, 0, 0.4);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.popout-btn:hover {
  transform: scale(1.05);
  box-shadow: 0 0 14px rgba(255, 106, 0, 0.6);
}

.pause-toast {
  opacity: 0;
  pointer-events: none;
  background: rgba(20, 10, 0, 0.85);
  border: 1px solid rgba(255, 69, 0, 0.4);
  color: #ffb366;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 12px;
  text-align: center;
  margin-top: 10px;
  transition: opacity 0.4s ease;
  box-shadow: 0 0 10px rgba(255, 69, 0, 0.3);
}

.pause-toast.show {
  opacity: 1;
}