/* One holiday background for every page of the site.
   seasons.js sets the colors and the wallpaper on <html> (paintSeasonBackground) and fills the moving layer
   (paintSeasonMotion): falling holiday pieces and a garland across the top. With no holiday on, each page keeps its own look. */

/* the wallpaper goes on the page itself, so the moving layer sits on top of it */
html[data-season] { background:none; }
html[data-season] body { background:var(--sWall), linear-gradient(180deg,var(--sBg1),var(--sBg2)) !important; background-size:190px 190px, 100% 100% !important; background-attachment:scroll !important; }

/* falling pieces */
#seasonFx, #seasonGarland { position:fixed; left:0; right:0; z-index:-1; pointer-events:none; overflow:hidden; }
#seasonFx { top:0; bottom:0; opacity:.55; }
#seasonFx span { position:absolute; top:-14vh; font-size:var(--sz,44px); will-change:transform;
  animation:seasonFall var(--dur,14s) linear var(--delay,0s) infinite; text-shadow:0 3px 3px rgba(43,16,85,.3); }
@keyframes seasonFall {
  0% { transform:translate3d(0,0,0) rotate(0deg); }
  25% { transform:translate3d(var(--sway,30px),32vh,0) rotate(40deg); }
  50% { transform:translate3d(0,64vh,0) rotate(-20deg); }
  75% { transform:translate3d(calc(var(--sway,30px) * -1),96vh,0) rotate(30deg); }
  100% { transform:translate3d(0,130vh,0) rotate(0deg); }
}

/* garland across the top */
#seasonGarland { top:0; height:46px; }
#seasonGarland::before { content:""; position:absolute; left:-2%; right:-2%; top:-18px; height:40px; border-bottom:5px solid var(--sA);
  border-radius:0 0 50% 50% / 0 0 100% 100%; }
#seasonGarland .gRow { position:absolute; left:0; right:0; top:-8px; display:flex; justify-content:space-around; }
#seasonGarland .gRow span { font-size:28px; display:inline-block; transform-origin:50% -10px; animation:swing 2.8s ease-in-out infinite;
  text-shadow:0 3px 2px rgba(43,16,85,.35); }
#seasonGarland .gRow span:nth-child(odd) { animation-delay:-1.4s; }
#seasonGarland .usaTag { font-size:.6em; }
@keyframes swing { 0%,100% { transform:rotate(-10deg); } 50% { transform:rotate(10deg); } }
@media (prefers-reduced-motion: reduce) { #seasonFx span { animation:none; top:var(--rest,50%); } #seasonGarland .gRow span { animation:none; } }
body.onPlayer #seasonFx, body.onPlayer #seasonGarland { display:none; }

/* the word USA, in text, where the flag emoji would show as "US" on Windows */
.usaTag { display:inline-block; font:900 .5em/1.7 "Arial Black", Arial, sans-serif; letter-spacing:.03em; color:#fff; background:var(--sA,#1d3f9e);
  padding:0 .34em; border-radius:.3em; vertical-align:.16em; text-shadow:none; }
