/* The underground's small buried things (owner 2026-10-14; src/components/UndergroundDecor.tsx): pieces of pixel art in
   the side margins, behind the page (the first thing in .main-content, under the banners' sky and ground), never in
   the way of a click. The diamonds catch the light now and then (the sky's twinkle.png); reduced motion = still.
   Castle look only. Undo: ../removed-features-backup/underground-layers-2026-10-14/README.txt */

html:not([data-site-theme="castle"]) .ug-decor { display: none; }
.ug-decor {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}
.ug-piece {
  position: absolute;
  background-repeat: no-repeat;
  background-position: 0 0;
  image-rendering: pixelated;
}
/* a diamond's glint: a small cross of light over its top facet, flashing now and then */
.ug-glint::after {
  content: '';
  position: absolute;
  left: 30%;
  top: -6px;
  width: 21px;
  height: 21px;
  background: url("/theme/castle/twinkle.png") 0 0 / 100% 100% no-repeat;
  image-rendering: pixelated;
  opacity: 0;
  animation: ug-glint 7s linear infinite;
}
.ug-glint:nth-child(odd)::after { animation-duration: 9s; animation-delay: -3s; }
@keyframes ug-glint {
  0%, 90%, 100% { opacity: 0; }
  93% { opacity: 1; }
  96% { opacity: 0.4; }
}
@media (prefers-reduced-motion: reduce) {
  .ug-glint::after { animation: none; }
}
