/* SlotFather Christmas theme. Loaded only when base.twig's xmas flag is on
   (everyone since 2026-11-29). Everything is scoped to body.xmas. */
body.xmas{
  --xmas-red:#d23a3a; --xmas-green:#1f8a4c; --xmas-gold:#f2c14e; --xmas-snow:#f5f8ff;
}

/* Header: keep the navy, add a candy-cane stripe and a string of lights. */
body.xmas .site-header{
  background:linear-gradient(180deg,#1E2044 0%,#1a1d3f 100%);
  border-bottom:0;
  padding-bottom:16px;
}
body.xmas .site-header::before{ /* candy-cane stripe */
  content:"";position:absolute;left:0;right:0;bottom:12px;height:3px;
  background:repeating-linear-gradient(135deg,var(--xmas-red) 0 10px,#fff 10px 20px);
  opacity:.85;
}
body.xmas .xmas-lights{
  position:absolute;left:0;right:0;bottom:0;height:16px;margin:0;padding:0 6px;
  list-style:none;display:flex;justify-content:space-between;overflow:hidden;pointer-events:none;
}
body.xmas .xmas-lights li{
  position:relative;width:8px;height:12px;margin-top:2px;border-radius:50% 50% 45% 45%;
  background:var(--c);box-shadow:0 2px 8px 1px var(--c);
  animation:xmas-twinkle 2.4s ease-in-out infinite;animation-delay:var(--d);
}
body.xmas .xmas-lights li::before{ /* the little socket */
  content:"";position:absolute;top:-3px;left:1px;width:6px;height:4px;border-radius:2px;background:#3a3d5c;
}
@keyframes xmas-twinkle{0%,100%{opacity:1;filter:brightness(1.15)}50%{opacity:.35;filter:brightness(.7)}}

/* Brand: little Santa hat on the logo plus a tree. */
body.xmas .brand{position:relative;padding-left:4px}
body.xmas .brand .xmas-hat{
  position:absolute;left:-9px;top:-11px;width:24px;height:20px;transform:rotate(-18deg);pointer-events:none;
}
body.xmas .brand::after{content:" 🎄";font-size:.95em}

/* Nav: festive active / hover states. */
body.xmas .site-nav .nav-link:hover{color:#fff;background:#1f6b40}
body.xmas .site-nav .nav-link.active{color:#fff;background:var(--xmas-red);box-shadow:inset 0 -2px 0 var(--xmas-gold)}

/* Footer: snow drift along the top edge. */
body.xmas footer{position:relative;border-top:0!important}
body.xmas footer::before{
  content:"";position:absolute;left:0;right:0;top:-14px;height:15px;pointer-events:none;
  background:
    radial-gradient(circle at 10px 15px,var(--xmas-snow) 10px,transparent 10.5px) 0 0/34px 15px repeat-x,
    radial-gradient(circle at 24px 15px,#dfe6f5 8px,transparent 8.5px) 0 0/34px 15px repeat-x;
}

/* Snowfall overlay. */
#xmas-snow{position:fixed;inset:0;width:100%;height:100%;pointer-events:none;z-index:1020}
.xmas-toggle{
  position:fixed;right:14px;bottom:14px;z-index:1040;display:flex;align-items:center;gap:6px;
  background:#1E2044ee;color:#fff;border:1px solid #ffffff30;border-radius:999px;
  padding:7px 12px;font-size:12px;line-height:1;cursor:pointer;box-shadow:0 4px 16px #0006;
}
.xmas-toggle:hover{border-color:var(--xmas-gold)}
.xmas-toggle .xmas-preview{color:var(--xmas-gold);font-weight:700;letter-spacing:.4px}

@media (prefers-reduced-motion:reduce){
  body.xmas .xmas-lights li{animation:none}
}
@media (max-width:576px){
  .xmas-toggle{right:10px;bottom:10px;padding:6px 10px}
  .xmas-toggle .xmas-preview{display:none}
}

/* Snow caps sitting on top of the site's cards (.panel boxes and the home
   page leaderboard podium .lb-card). Pure decoration: pointer-events off. */
body.xmas .panel,body.xmas .lb-card{position:relative}
body.xmas .panel::before,body.xmas .lb-card::before{
  content:"";position:absolute;left:-1px;right:-1px;top:-6px;height:18px;z-index:2;pointer-events:none;
  border-radius:14px 14px 0 0;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 18'%3E%3Cpath fill='%23f5f8ff' d='M0 0H120V9Q114 10 110 9Q105 17 99 10Q90 12 81 10Q75 18 69 10Q59 12 49 10Q43 15 37 10Q27 12 17 10Q11 16 6 10Q2 10 0 9Z'/%3E%3Cpath fill='%23ffffff' opacity='.9' d='M0 0H120V3Q60 6 0 3Z'/%3E%3C/svg%3E") 0 0/120px 18px repeat-x;
  filter:drop-shadow(0 2px 2px rgba(0,0,0,.25));
}

/* Countdown / greeting strip above the footer text. */
body.xmas .xmas-greeting{
  margin:0 auto .7rem;font-size:.9rem;font-weight:700;letter-spacing:.3px;color:var(--xmas-gold);
  text-shadow:0 0 12px rgba(242,193,78,.35);
}
body.xmas .xmas-greeting b{color:#fff;font-size:1.05em}
