

.tssd-adv { position: relative; margin: 0 0 1.5em; }
.tssd-adv__sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

/* Farben der Motive (currentColor) */
.tssd-adv--green { color: var(--sd-xmas-green); }
.tssd-adv--red   { color: var(--sd-xmas-red); }
.tssd-adv--gold  { color: var(--sd-gold-dark); }
.tssd-adv--snow  { color: var(--sd-muted); }
html[data-theme="dark"] .tssd-adv--snow { color: var(--sd-snow); }

/* Kopfband */
.tssd-adv__scene { position: relative; height: 150px; margin: 0 0 14px; border-radius: var(--sd-radius-lg);
  background: linear-gradient(var(--sd-surface-2), var(--sd-surface)); border: 1px solid var(--sd-line-soft); overflow: hidden; }
.tssd-adv__scene svg { position: absolute; bottom: 0; height: 100%; }
.tssd-adv__scene-bg { left: 0; width: 100%; }

.tssd-adv__scene-l { left: 0; width: auto; }
.tssd-adv__scene-r { right: 0; width: auto; }
.tssd-adv__hill { fill: var(--sd-surface); stroke: var(--sd-line); }

.tssd-adv__status { background: var(--sd-highlight); border-radius: var(--sd-radius); padding: 10px 14px; margin: 0 0 18px;
  font-weight: 600; color: var(--sd-text); }

/* Türchen-Raster mit leisem Schneefall dahinter */
.tssd-adv__snow { position: relative; padding: 10px; border-radius: var(--sd-radius-lg); }
.tssd-adv__snow::before { content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit; opacity: .45;
  background-image:
    radial-gradient(2px 2px at 20px 30px, var(--sd-muted) 50%, transparent 51%),
    radial-gradient(3px 3px at 90px 80px, var(--sd-muted) 50%, transparent 51%),
    radial-gradient(2px 2px at 150px 20px, var(--sd-muted) 50%, transparent 51%),
    radial-gradient(2.5px 2.5px at 60px 140px, var(--sd-muted) 50%, transparent 51%),
    radial-gradient(2px 2px at 180px 110px, var(--sd-muted) 50%, transparent 51%);
  background-size: 200px 160px; animation: tssd-adv-snow 14s linear infinite; }
html[data-theme="dark"] .tssd-adv__snow::before {
  background-image:
    radial-gradient(2px 2px at 20px 30px, var(--sd-snow) 50%, transparent 51%),
    radial-gradient(3px 3px at 90px 80px, var(--sd-snow) 50%, transparent 51%),
    radial-gradient(2px 2px at 150px 20px, var(--sd-snow) 50%, transparent 51%),
    radial-gradient(2.5px 2.5px at 60px 140px, var(--sd-snow) 50%, transparent 51%),
    radial-gradient(2px 2px at 180px 110px, var(--sd-snow) 50%, transparent 51%); }
@keyframes tssd-adv-snow { from { background-position: 0 0; } to { background-position: 40px 160px; } }
@media (prefers-reduced-motion: reduce) { .tssd-adv__snow::before { animation: none; } }

.tssd-adv__doors { position: relative; display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; grid-auto-flow: dense; }
.tssd-adv__door { position: relative; display: flex; flex-direction: column; justify-content: space-between; min-height: 96px;
  padding: 8px 9px; border-radius: var(--sd-radius); border: 1px solid var(--sd-line); background: var(--sd-surface-2);
  color: var(--sd-text); font-size: var(--sd-fs-2xs); line-height: 1.3; text-align: left; overflow: hidden; text-decoration: none; }
a.tssd-adv__door:link, a.tssd-adv__door:visited { color: var(--sd-text); text-decoration: none; }
.tssd-adv__n { position: relative; font-family: var(--sd-font-brand); font-weight: 700; font-size: var(--sd-fs-xl); line-height: 1; color: var(--sd-gold-dark); }
.tssd-adv__when { position: relative; color: var(--sd-muted); }
.tssd-adv__what { position: relative; display: block; font-weight: 600; color: var(--sd-text); }
.tssd-adv__tag { font-weight: 700; color: var(--sd-gold-dark); }
.tssd-adv__door.is-big { grid-column: span 2; grid-row: span 2; }
.tssd-adv__door.is-wide { grid-column: span 2; }
.tssd-adv__motif { position: absolute; right: 7px; top: 7px; width: 28px; height: 28px; opacity: .85; }
.tssd-adv__door.is-big .tssd-adv__motif { top: auto; bottom: 10px; right: 10px; width: 64px; height: 64px; }
.tssd-adv__door.is-wide .tssd-adv__motif { width: 36px; height: 36px; }
.tssd-adv__door.is-closed .tssd-adv__n { opacity: .6; }
.tssd-adv__door.is-closed .tssd-adv__motif { opacity: .45; }
.tssd-adv__door.is-open, .tssd-adv__door.is-today { background: var(--sd-surface); box-shadow: var(--sd-shadow-sm); }
.tssd-adv__door.is-open:hover, .tssd-adv__door.is-open:focus-visible,
.tssd-adv__door.is-today:hover, .tssd-adv__door.is-today:focus-visible { border-color: var(--sd-gold-line); outline: none; box-shadow: var(--sd-focus); }
.tssd-adv__door.is-today { background: var(--sd-highlight); border: 2px solid var(--sd-gold); }
.tssd-adv__bow { position: absolute; top: 4px; right: 6px; width: 32px; height: 32px; color: var(--sd-xmas-red); }

.tssd-adv__pick { margin: 10px 0 0; color: var(--sd-muted); font-size: var(--sd-fs-sm); }

/* Bedienfeld je Türchen: ohne Skript über :target; das heutige ist vorgewählt */
.tssd-adv__panel { display: none; position: relative; margin-top: 14px; background: var(--sd-surface); border: 1px solid var(--sd-line);
  border-left: 4px solid var(--sd-xmas-green); border-radius: var(--sd-radius); padding: 14px 16px; scroll-margin-top: 90px; }
.tssd-adv__panel.is-current { display: block; }

.tssd-adv__panels:has(.tssd-adv__panel:target) .tssd-adv__panel.is-current:not(:target) { display: none; }
.tssd-adv__panels .tssd-adv__panel:target { display: block; }
.tssd-adv__panel h3 { margin: 0 0 4px; font-family: var(--sd-font-brand); font-size: var(--sd-fs-lg); }
.tssd-adv__sub, .tssd-adv__contents { margin: 0 0 8px; color: var(--sd-muted); font-size: var(--sd-fs-sm); }
/* unter der Überschrift (die Seite gibt h3 eine Linie darüber und darunter) */
.tssd-adv__deco { position: absolute; right: 16px; top: 76px; width: 44px; height: 44px; color: var(--sd-xmas-green); }
.tssd-adv__links { margin: 6px 0 0; }
.tssd-adv__hint { font-size: var(--sd-fs-sm); background: var(--sd-gold-soft); border-radius: var(--sd-radius-sm); padding: 6px 10px; margin: 8px 0 0; }

@media (max-width: 640px) {
  .tssd-adv__doors { grid-template-columns: repeat(3, 1fr); }
  .tssd-adv__scene { height: 110px; }
}

/* B3 — Kasten auf der Startseite ([tssd_advent_teaser]), sd-card + Tanne */
.tssd-adv-teaser { display: flex; gap: 16px; align-items: flex-start; border-left: 4px solid var(--sd-xmas-green); }
.tssd-adv-teaser__ico { flex: 0 0 auto; width: 48px; height: 48px; }
.tssd-adv-teaser__text p { margin: 0 0 8px; }
.tssd-adv-teaser__head { font-family: var(--sd-font-brand); font-weight: 700; font-size: var(--sd-fs-lg); }
.tssd-adv-teaser .tssd-adv__sprite { position: absolute; }

/* B2 — Anmeldekasten (Türchen-Erinnerung per Mail) */
.tssd-adv__signup { background: var(--sd-surface); border: 1px solid var(--sd-line); border-left: 4px solid var(--sd-gold);
  border-radius: var(--sd-radius); padding: 14px 16px; margin: 0 0 22px; }
.tssd-adv__signup p { margin: 0 0 8px; }
.tssd-adv__row { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
.tssd-adv__row input[type=email] { flex: 1 1 220px; }
.tssd-adv__chk { display: flex; gap: 8px; align-items: flex-start; font-size: var(--sd-fs-sm); margin: 4px 0; }
.tssd-adv__chk input { margin-top: 4px; }
.tssd-adv__privacy { font-size: var(--sd-fs-sm); color: var(--sd-muted); }
.tssd-adv__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

