/* ============================================================
   VK RADIO TRADER — assets/css/christmas.css
   Aussie summer Christmas theme. Loaded by index.php only while
   $xmas_on is true (1 Dec – 26 Dec). Scoped to .hero.xm.
   ============================================================ */

/* Warm summer-dusk scrim: deep green into sunset gold */
.hero.xm::before {
  background:
    radial-gradient(ellipse at 88% 0%, rgba(255,196,64,0.34) 0%, transparent 52%),
    linear-gradient(135deg, rgba(8,34,24,0.80) 0%, rgba(24,60,40,0.66) 55%, rgba(150,40,30,0.50) 100%);
}

.hero.xm .hero-badge {
  background: rgba(224,52,52,0.16);
  border-color: rgba(255,120,110,0.5);
  color: #ffe3dc;
}
.hero.xm h1 em {
  color: #ffd25a;
  text-shadow: 0 0 14px rgba(255,200,70,0.55), 0 2px 12px rgba(0,0,0,0.5);
}

/* Summer sun, top-right, slowly pulsing */
.xm-sun {
  position: absolute; top: 14px; right: 18px; z-index: 1;
  width: 54px; height: 54px; border-radius: 50%;
  background: radial-gradient(circle, #fff3b0 0%, #ffc93c 55%, rgba(255,160,40,0) 72%);
  box-shadow: 0 0 40px 14px rgba(255,190,60,0.35);
  animation: xmSun 6s ease-in-out infinite;
  pointer-events: none;
}
@keyframes xmSun { 0%,100% { transform: scale(1); opacity: .9; } 50% { transform: scale(1.1); opacity: 1; } }

/* Sparkle layer (filled by christmas.js) */
.xm-sparkles { position: absolute; inset: 0; z-index: 1; overflow: hidden; pointer-events: none; }
.xm-sparkles.off { display: none; }
.xm-spark {
  position: absolute; bottom: -12px; border-radius: 50%;
  background: #fff6c8; box-shadow: 0 0 8px 2px rgba(255,220,110,0.8);
  opacity: 0; animation: xmRise linear infinite;
}
.xm-spark.r { background:#ffb3a8; box-shadow:0 0 8px 2px rgba(255,110,100,0.75); }
.xm-spark.g { background:#bff2c9; box-shadow:0 0 8px 2px rgba(90,220,130,0.7); }
@keyframes xmRise {
  0%   { transform: translate(0,0) scale(.6); opacity: 0; }
  12%  { opacity: .95; }
  70%  { opacity: .8; }
  100% { transform: translate(var(--dx,20px), -460px) scale(1.1); opacity: 0; }
}

/* Toggle */
.xm-toggle {
  position: absolute; bottom: 10px; right: 12px; z-index: 3;
  background: rgba(0,0,0,.35); color: #ffe9b0; border: 1px solid rgba(255,220,140,.4);
  border-radius: 999px; padding: 4px 11px; font-size: .74rem; cursor: pointer;
  font-family: inherit; backdrop-filter: blur(4px);
}
.xm-toggle:hover { background: rgba(0,0,0,.55); }

/* Strip flair */
.xm-stats-flair { position: relative; }

@media (max-width: 640px) {
  .xm-sun { width: 28px; height: 28px; top: 6px; right: 8px; box-shadow: 0 0 22px 8px rgba(255,190,60,0.3); }
  .xm-spark:nth-child(n+16) { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .xm-sparkles, .xm-sun { animation: none; }
  .xm-spark { animation: none; }
  .xm-toggle { display: none; }
}

/* ---------- Fairy lights along the top of the hero ---------- */
.xm-lights {
  position: absolute; top: -2px; left: 0; right: 0; z-index: 2; height: 46px;
  display: flex; overflow: hidden; pointer-events: none;
}
.xm-lights.off { display: none; }
.xm-swag { position: relative; flex: 0 0 88px; height: 22px;
  border-bottom: 2px solid rgba(20,40,28,.85); border-radius: 0 0 50% 50%; }
.xm-bulb {
  position: absolute; width: 8px; height: 11px; margin-left: -4px;
  border-radius: 50% 50% 55% 55%; background: var(--c);
  box-shadow: 0 0 9px 3px var(--c);
  animation: xmTwinkle 2.6s ease-in-out infinite;
}
.xm-bulb::before { /* little cap */
  content:''; position:absolute; top:-3px; left:1px; width:6px; height:4px;
  background: rgba(20,40,28,.9); border-radius: 1px;
}
@keyframes xmTwinkle { 0%,100% { opacity: 1; } 50% { opacity: .38; } }
@media (max-width: 640px) { .xm-swag { flex-basis: 64px; } }
@media (prefers-reduced-motion: reduce) { .xm-bulb { animation: none; } }
