/* Weihnachtsgruß auf der Startseite (01.12.–31.12.) – abschaltbar über XMAS_GRUSS in build.py */
.xg[hidden] { display: none; }
.xg-snow { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; transition: opacity 1.2s ease; }
.hero > .wrap { position: relative; z-index: 1; }

/* Weihnachtsmann im Propellerflugzeug mit NMF-Banner im Schlepp – fliegt einmal durch den oberen Bereich */
.xg-plane { position: absolute; top: 8px; left: 0; width: 440px; z-index: 3; pointer-events: none;
  transform: translateX(-460px); transition: opacity .8s ease; }
.xg-plane.fliegt { animation: xgFlug 13s linear 1 forwards; }
.xg-plane img { display: block; width: 100%; height: auto; animation: xgWippen 1.7s ease-in-out infinite alternate; }
@keyframes xgFlug { from { transform: translateX(-460px); } to { transform: translateX(var(--xg-weg, 1400px)); } }
@keyframes xgWippen { from { transform: translateY(-5px) rotate(-1.5deg); } to { transform: translateY(5px) rotate(1deg); } }

/* Grußkarte */
.xg-wrap { display: grid; grid-template-rows: 1fr; margin-bottom: 2.2rem; transition: grid-template-rows .7s ease, margin .7s ease; }
.xg-wrap > div { overflow: hidden; min-height: 0; }
.xg.zu .xg-wrap { grid-template-rows: 0fr; margin-bottom: 0; }
.xg-card { position: relative; max-width: 560px; margin: 0 auto; padding: 1.6rem 2rem 1.8rem; text-align: center; overflow: hidden;
  background: rgba(49,54,59,.9); border: 1px solid rgba(101,173,174,.55); border-radius: var(--radius);
  opacity: 0; transform: translateY(14px); transition: opacity .7s ease, transform .7s ease; }
.xg.offen .xg-card { opacity: 1; transform: none; }
.xg.zu .xg-card { opacity: 0; transform: translateY(-8px); }
.xg-ey { font-family: var(--mono); font-size: .75rem; letter-spacing: .16em; text-transform: uppercase; color: var(--accent); }
.xg-ey span { display: inline-block; animation: xgFunkeln 2.4s ease-in-out infinite; }
.xg-ey span + span { animation-delay: 1.2s; }
@keyframes xgFunkeln { 0%, 100% { opacity: .45; transform: scale(.9); } 50% { opacity: 1; transform: scale(1.12); } }
.xg-title { color: #fff; font-size: clamp(1.3rem, 2.4vw, 1.6rem); font-weight: 700; letter-spacing: -.02em; line-height: 1.25; margin: .6rem 0 .6rem; }
.xg-card p.xg-text { color: #c9d1d4; font-size: 1rem; line-height: 1.65; margin: 0; }
.xg-text em { font-style: normal; color: var(--accent); }
.xg-close { position: absolute; top: .7rem; right: .7rem; width: 34px; height: 34px; border-radius: 50%; padding: 0; cursor: pointer;
  border: 1px solid rgba(101,173,174,.5); background: transparent; color: #c9d1d4; font-size: 1.2rem; line-height: 1; transition: background .15s, color .15s; }
.xg-close:hover, .xg-close:focus-visible { background: var(--accent-strong); color: #fff; }
.xg-zeit { position: absolute; left: 0; bottom: 0; height: 3px; width: 100%; background: var(--accent); transform-origin: left; transform: scaleX(1); }
.xg.zu .xg-snow, .xg.zu .xg-plane { opacity: 0; }

@media (max-width: 640px) {
  .xg-plane { width: 270px; top: 4px; transform: translateX(-290px); }
  @keyframes xgFlug { from { transform: translateX(-290px); } to { transform: translateX(var(--xg-weg, 700px)); } }
  .xg-card { padding: 1.4rem 1.2rem 1.6rem; }
  .xg-wrap { margin-bottom: 1.6rem; }
}
@media (prefers-reduced-motion: reduce) {
  .xg-snow, .xg-plane { display: none; }
  .xg-card, .xg-wrap { transition: none; }
  .xg-ey span { animation: none; }
}
