/* Holiday decorations created by christmas.js (only present Nov 1 – Jan 6). */

/* Keep the poem clear of the light strings on narrow screens. */
[data-holiday="yes"] main {
  padding-left: max(1.5rem, 48px);
  padding-right: max(1.5rem, 48px);
}

.xmas-lights {
  position: fixed;
  top: 0;
  bottom: 0;
  width: 36px;
  z-index: 2;
  pointer-events: none; /* fixed, so the glow spilling past its 36px never adds scrolling */
}
.xmas-lights.left { left: 4px; }
.xmas-lights.right { right: 4px; }
.xmas-lights svg { display: block; overflow: visible; }

.xmas-lights .wire {
  fill: none;
  stroke: #2e4a32;
  stroke-width: 1.6;
}
.xmas-lights .socket { fill: #3c5a40; }

.bulb {
  filter: drop-shadow(0 0 3px var(--glow)) drop-shadow(0 0 8px var(--glow));
  animation: xmas-twinkle 2.4s ease-in-out infinite;
}

@keyframes xmas-twinkle {
  0%, 100% { opacity: 1; }
  45% { opacity: 0.9; }
  60% { opacity: 0.3; }
  75% { opacity: 0.95; }
}

.xmas-tree {
  width: min(60vw, 230px);
  margin-top: clamp(0.5rem, 3vh, 2rem);
}
.xmas-tree svg { display: block; width: 100%; height: auto; overflow: visible; }
.xmas-tree .mound { fill: #e6edf6; }
.xmas-tree .trunk { fill: #7a4a24; }
.xmas-tree .garland { fill: none; stroke: #e9c46a; stroke-width: 2.4; stroke-linecap: round; opacity: 0.9; }
.xmas-tree .ornament { stroke: rgb(0 0 0 / 0.15); stroke-width: 0.8; }
.xmas-tree .shine { fill: rgb(255 255 255 / 0.7); }
.xmas-tree .star {
  fill: #ffd23f;
  stroke: #f4a300;
  stroke-width: 1;
  stroke-linejoin: round;
  transform-box: fill-box;
  transform-origin: 50% 50%;
  filter: drop-shadow(0 0 6px #ffd23f);
  animation: xmas-star 3s ease-in-out infinite;
}

@keyframes xmas-star {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 5px #ffd23f); }
  50% { transform: scale(1.08); filter: drop-shadow(0 0 12px #ffd23f); }
}

@media (prefers-color-scheme: dark) {
  .xmas-lights .wire { stroke: #4b6b4f; }
  .xmas-lights .socket { fill: #5a7a5e; }
}

@media (prefers-reduced-motion: reduce) {
  .bulb, .xmas-tree .star { animation: none; }
}
