/* Glaseffekt — eigenstaendiges Modul (nur .glass*).
   Riffelglas: eine Blau-Gradientflaeche wird per SVG-DisplacementMap durch
   senkrechte Glasrippen gebrochen, darueber liegen feine Lichtkanten.
   Animationen respektieren prefers-reduced-motion. */

.glass__defs { position: absolute; width: 0; height: 0; }

.glass {
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: -1;
  background: #040a16;
}

.glass__farbe {
  position: absolute;
  inset: -4%;
  display: block;
  background:
    radial-gradient(58% 70% at 18% 22%, #1d4ed8 0%, rgba(29, 78, 216, 0) 60%),
    radial-gradient(50% 62% at 78% 68%, #0e7490 0%, rgba(14, 116, 144, 0) 62%),
    radial-gradient(42% 52% at 62% 8%, #312e81 0%, rgba(49, 46, 129, 0) 60%),
    linear-gradient(160deg, #071427 0%, #0b2340 42%, #06101f 100%);
  filter: url(#reed);
  transform: scale(1.06);
  animation: glass-wandern 22s ease-in-out infinite alternate;
}

/* feine senkrechte Kanten: machen aus dem Wobble echte Riffel */
.glass__linien {
  position: absolute;
  inset: 0;
  display: block;
  background: repeating-linear-gradient(
    90deg,
    rgba(255, 255, 255, 0.20) 0 1.5px,
    rgba(255, 255, 255, 0) 1.5px 8px,
    rgba(2, 8, 20, 0.30) 8px 10px,
    rgba(255, 255, 255, 0) 10px 28px
  );
  mix-blend-mode: overlay;
  opacity: 1;
}

/* weiches Gegenlicht, das durch das Glas faellt */
.glass__licht {
  position: absolute;
  inset: 0;
  display: block;
  background:
    radial-gradient(40% 55% at 72% 42%, rgba(147, 197, 253, 0.22), transparent 70%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.04), transparent 35%);
  mix-blend-mode: screen;
  pointer-events: none;
}

@keyframes glass-wandern {
  from { transform: scale(1.06) translate3d(-1.2%, -0.8%, 0); }
  to   { transform: scale(1.10) translate3d(1.6%, 1.2%, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .glass__farbe { animation: none; }
}
