/* ==========================================================================
   Dance FM Moldova — Hero Player Widget
   Design: Glassmorphism Dark with magenta brand accents
   Brand Colors: #000000, #FFFFFF, #FE00F3, #FE79F6, #FFBFFB
   ========================================================================== */

/* --- Container --- */
.df-hero {
  position: relative;
  width: 100%;
  max-width: 100%;
  border-radius: 20px;
  overflow: hidden;
  background: #000000;
  color: #fff;
  font-family: 'Saira Condensed', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  aspect-ratio: 16 / 7;
  min-height: 280px;
  max-height: 500px;
  /* Visible magenta border glow */
  border: 1px solid rgba(254, 0, 243, 0.3);
  box-shadow:
    0 0 30px rgba(254, 0, 243, 0.12),
    0 0 80px rgba(254, 0, 243, 0.06),
    inset 0 0 60px rgba(254, 0, 243, 0.04);
}

@media (max-width: 768px) {
  .df-hero {
    aspect-ratio: auto;
    min-height: 340px;
    max-height: none;
    border-radius: 16px;
  }
}

/* --- Background (blurred cover art) --- */
.df-hero-bg {
  position: absolute;
  inset: -60px;
  background-size: cover;
  background-position: center;
  filter: blur(50px) brightness(0.25) saturate(1.6);
  transition: background-image 1.2s ease;
  z-index: 0;
}

/* --- Dark glass overlay with visible magenta gradient --- */
.df-hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 80% 50%, rgba(254, 0, 243, 0.12) 0%, transparent 60%),
    radial-gradient(ellipse at 20% 80%, rgba(254, 121, 246, 0.08) 0%, transparent 50%),
    linear-gradient(135deg, rgba(0, 0, 0, 0.6) 0%, rgba(0, 0, 0, 0.3) 50%, rgba(254, 0, 243, 0.08) 100%);
  z-index: 1;
}

/* --- Animated magenta accent line at bottom --- */
.df-hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 5%;
  right: 5%;
  height: 2px;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(254, 0, 243, 0.3) 15%,
    #FE00F3 50%,
    rgba(254, 0, 243, 0.3) 85%,
    transparent 100%);
  z-index: 5;
  box-shadow: 0 0 12px rgba(254, 0, 243, 0.4);
}

/* --- Animated magenta accent line at top --- */
.df-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 15%;
  right: 15%;
  height: 1px;
  background: linear-gradient(90deg,
    transparent,
    rgba(254, 0, 243, 0.25),
    transparent);
  z-index: 5;
}

/* --- Content Layout --- */
.df-hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 44px;
  padding: 44px;
  height: 100%;
}

@media (max-width: 768px) {
  .df-hero-content {
    flex-direction: column;
    gap: 28px;
    padding: 32px 24px;
    text-align: center;
  }
}

/* --- Canvas Visualizer (behind content) --- */
.df-hero-visualizer-wrap {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.4;
  mix-blend-mode: screen;
}

.df-hero-visualizer-wrap canvas {
  width: 100%;
  height: 100%;
  display: block;
}

/* --- Cover Art (with prominent glass frame + glow) --- */
.df-hero-cover {
  width: 210px;
  height: 210px;
  min-width: 210px;
  border-radius: 16px;
  overflow: visible;
  position: relative;
}

.df-hero-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 16px;
  transition: opacity 0.6s ease, transform 0.4s ease;
  /* Glass frame around cover */
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(254, 0, 243, 0.15),
    0 0 30px rgba(254, 0, 243, 0.1);
}

/* --- Cover Glow — ALWAYS visible, brighter when playing --- */
.df-hero-cover .df-hero-cover-glow {
  position: absolute;
  inset: -12px;
  border-radius: 28px;
  background: radial-gradient(ellipse at center,
    rgba(254, 0, 243, 0.25) 0%,
    rgba(254, 121, 246, 0.12) 40%,
    transparent 70%);
  z-index: -1;
  filter: blur(20px);
  opacity: 0.5;
  transition: opacity 0.6s ease;
}

.df-hero.df-hero-playing .df-hero-cover-glow {
  opacity: 1;
  animation: df-glow-pulse 3s ease-in-out infinite;
}

@keyframes df-glow-pulse {
  0%, 100% { opacity: 0.8; transform: scale(1); }
  50%      { opacity: 1; transform: scale(1.08); }
}

@media (max-width: 768px) {
  .df-hero-cover {
    width: 160px;
    height: 160px;
    min-width: 160px;
  }
}

/* --- Track Info --- */
.df-hero-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.df-hero-station {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: #FE00F3;
  text-shadow: 0 0 20px rgba(254, 0, 243, 0.4);
}

.df-hero-artist {
  font-size: 36px;
  font-weight: 700;
  line-height: 1.1;
  color: #fff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.5);
}

.df-hero-title {
  font-size: 20px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.55);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-bottom: 4px;
}

@media (max-width: 768px) {
  .df-hero-artist {
    font-size: 26px;
  }
  .df-hero-title {
    font-size: 16px;
  }
}

/* --- Controls Row --- */
.df-hero-controls {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 10px;
}

@media (max-width: 768px) {
  .df-hero-controls {
    justify-content: center;
  }
}

/* --- Hero Play Button (magenta with glow) --- */
.df-hero .df-hero-play-btn {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 58px !important;
  height: 58px !important;
  border: none !important;
  border-radius: 50% !important;
  background: #FE00F3 !important;
  color: #fff !important;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
  box-shadow:
    0 4px 20px rgba(254, 0, 243, 0.5),
    0 0 40px rgba(254, 0, 243, 0.2) !important;
  position: relative;
  overflow: hidden;
  padding: 0 !important;
  margin: 0 !important;
}

.df-hero .df-hero-play-btn:hover {
  background: #FE79F6 !important;
  transform: scale(1.1);
  box-shadow:
    0 6px 28px rgba(254, 0, 243, 0.6),
    0 0 60px rgba(254, 0, 243, 0.25) !important;
}

.df-hero .df-hero-play-btn:active {
  transform: scale(0.95);
}

.df-hero .df-hero-play-btn svg {
  width: 26px;
  height: 26px;
  fill: #fff !important;
  display: block;
  flex-shrink: 0;
}

.df-hero .df-hero-play-btn .df-hero-icon-play {
  margin-left: 3px;
  margin-right: -3px;
}

.df-hero .df-hero-play-btn .df-hero-icon-pause {
  display: none;
  margin: 0;
}

.df-hero .df-hero-play-btn.df-hero-btn-playing .df-hero-icon-play {
  display: none;
}

.df-hero .df-hero-play-btn.df-hero-btn-playing .df-hero-icon-pause {
  display: block;
}

/* Loading spinner */
.df-hero .df-hero-play-btn.df-hero-btn-loading {
  pointer-events: none;
}

.df-hero .df-hero-play-btn.df-hero-btn-loading::after {
  content: '';
  position: absolute;
  inset: 4px;
  border: 2.5px solid transparent;
  border-top-color: #fff;
  border-radius: 50%;
  animation: df-spin 0.7s linear infinite;
}

.df-hero .df-hero-play-btn.df-hero-btn-loading svg {
  opacity: 0.3;
}

/* --- LIVE Badge (glassmorphism pill with visible glow) --- */
.df-hero-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  border-radius: 20px;
  background: rgba(254, 0, 243, 0.15);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(254, 0, 243, 0.3);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: #FFBFFB;
  box-shadow: 0 0 15px rgba(254, 0, 243, 0.15);
}

.df-hero-live .df-hero-live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #FE00F3;
  box-shadow: 0 0 10px rgba(254, 0, 243, 0.8);
  animation: df-pulse 1.5s ease-in-out infinite;
}

/* --- Equalizer Bars (CSS fallback for mobile) --- */
.df-hero-bars {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 32px;
}

.df-hero-bars .df-hero-bar {
  width: 4px;
  border-radius: 2px;
  background: linear-gradient(to top, #FE00F3, #FFBFFB);
  box-shadow: 0 0 6px rgba(254, 0, 243, 0.3);
}

.df-hero-bars .df-hero-bar:nth-child(1) { height: 12px; animation: df-bar1 0.8s ease-in-out infinite; animation-play-state: paused; }
.df-hero-bars .df-hero-bar:nth-child(2) { height: 20px; animation: df-bar2 0.6s ease-in-out infinite 0.15s; animation-play-state: paused; }
.df-hero-bars .df-hero-bar:nth-child(3) { height: 14px; animation: df-bar3 0.75s ease-in-out infinite 0.3s; animation-play-state: paused; }
.df-hero-bars .df-hero-bar:nth-child(4) { height: 26px; animation: df-bar4 0.65s ease-in-out infinite 0.1s; animation-play-state: paused; }
.df-hero-bars .df-hero-bar:nth-child(5) { height: 10px; animation: df-bar1 0.7s ease-in-out infinite 0.2s; animation-play-state: paused; }
.df-hero-bars .df-hero-bar:nth-child(6) { height: 18px; animation: df-bar3 0.85s ease-in-out infinite 0.05s; animation-play-state: paused; }

.df-hero.df-hero-playing .df-hero-bars .df-hero-bar {
  animation-play-state: running;
}
