.ny-garland,
.ny-snow,
.ny-cap,
.ny-hat {
  pointer-events: none;
}

.ny-rel {
  position: relative;
}

.ny-garland {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 0;
  z-index: 65;
  overflow: visible;
}

.ny-wire {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 22px;
  overflow: visible;
}

.ny-bulb {
  position: absolute;
  width: 8px;
  height: 10px;
  margin-left: -4px;
  border-radius: 4px 4px 6px 6px;
  background:
    radial-gradient(circle at 35% 28%, rgba(255, 255, 255, .95) 0 1px, transparent 1.5px),
    radial-gradient(circle at 40% 35%, #fff 0 1px, var(--c) 2px 62%, rgba(0, 0, 0, .28) 100%);
  box-shadow:
    0 0 4px var(--c),
    0 0 8px color-mix(in srgb, var(--c) 65%, transparent);
  transform: rotate(var(--tilt, 0deg));
  transform-origin: 50% 0;
  animation: ny-glow 1.8s ease-in-out infinite;
  animation-delay: var(--d, 0s);
}

.ny-bulb::before {
  content: "";
  position: absolute;
  top: -3px;
  left: 1px;
  width: 6px;
  height: 3px;
  border-radius: 1px 1px 0 0;
  background: linear-gradient(#5c5348, #2c261f);
}


@keyframes ny-glow {
  0%, 100% { opacity: 1; filter: brightness(1.2) saturate(1.15); }
  45% { opacity: .42; filter: brightness(.65) saturate(.8); }
  70% { opacity: .95; filter: brightness(1.05); }
}

html.dark .ny-wire path {
  stroke: #d9cbb8;
}

.ny-snow {
  position: fixed;
  inset: 0;
  z-index: 64;
  overflow: hidden;
}

.ny-flake {
  position: absolute;
  top: -12px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 6px rgba(255, 255, 255, .75);
  opacity: var(--o, .8);
  animation: ny-fall var(--t, 12s) linear infinite;
  animation-delay: var(--delay, 0s);
}

.ny-flake.is-crystal {
  border-radius: 0;
  background: none;
  box-shadow: none;
  width: auto;
  height: auto;
}

.ny-flake svg {
  display: block;
  width: var(--s);
  height: var(--s);
  fill: rgba(255, 255, 255, .92);
  filter: drop-shadow(0 0 4px rgba(255, 255, 255, .7));
}

@keyframes ny-fall {
  0% { transform: translate3d(0, -12vh, 0) rotate(0deg); }
  25% { transform: translate3d(var(--sway), 28vh, 0) rotate(90deg); }
  50% { transform: translate3d(calc(var(--sway) * -0.6), 58vh, 0) rotate(180deg); }
  75% { transform: translate3d(calc(var(--sway) * 0.8), 86vh, 0) rotate(270deg); }
  100% { transform: translate3d(calc(var(--sway) * -0.2), 112vh, 0) rotate(360deg); }
}

.ny-cap {
  position: absolute;
  left: 0;
  right: 0;
  top: -6px;
  height: 32px;
  z-index: 4;
  border-radius: inherit;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 480 36'%3E%3Crect x='0' y='0' width='480' height='18' fill='%23fff'/%3E%3Cellipse cx='40' cy='16' rx='36' ry='14' fill='%23fff'/%3E%3Cellipse cx='112' cy='18' rx='44' ry='16' fill='%23fff'/%3E%3Cellipse cx='188' cy='16' rx='34' ry='13' fill='%23fff'/%3E%3Cellipse cx='260' cy='19' rx='48' ry='16' fill='%23fff'/%3E%3Cellipse cx='344' cy='16' rx='40' ry='15' fill='%23fff'/%3E%3Cellipse cx='424' cy='18' rx='44' ry='15' fill='%23fff'/%3E%3C/svg%3E") center top / 400px 32px repeat-x;
  filter: drop-shadow(0 2px 1px rgba(140, 166, 188, .4));
}

.ny-on .site-head,
.ny-on .site-header {
  padding-top: var(--ny-hat-room, 0px);
}

.ny-hat {
  position: fixed;
  z-index: 66;
  left: 0;
  top: 0;
  width: 34px;
  height: 30px;
  transform: rotate(var(--ny-hat-angle, -18deg));
  transform-origin: 50% 100%;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .28));
}

.ny-hat svg {
  display: block;
  width: 100%;
  height: 100%;
}

@media (prefers-reduced-motion: reduce) {
  .ny-snow { display: none; }
  .ny-bulb { animation: none; opacity: 1; filter: brightness(1.05); }
}
