/* =====================================================================
   Aristokrat Roleplay · Startseite · Illustrationen
   Nur Bildwerk: Palast-Akademie (Symbol #acad), Mond, Korn und Vignette,
   Balustrade, Eule, Galerie-Tafeln. Bewegung und Layout stehen in home.css.
   ===================================================================== */

/* ---------- Palast-Akademie: Klassen des Symbols #acad (siehe academy-symbol.svg) ---------- */
.ac-far { fill: var(--ac-far, #1c2230); }
.ac-terrace { fill: var(--ac-terrace, #0e121a); }
.ac-rock { fill: var(--ac-rock, #090b11); }
.ac-mass { fill: var(--ac-mass, #10131b); }
.ac-roof { fill: var(--ac-roof, #1a2131); }
.ac-trim { fill: var(--ac-trim, #202838); }
.ac-dark { fill: var(--ac-dark, #07090e); }
.ac-win { fill: var(--ac-win, #f2b35a); filter: var(--ac-win-glow, drop-shadow(0 0 2px rgba(242, 179, 90, .9)) drop-shadow(0 0 7px rgba(242, 150, 70, .45))); }
.ac-lamp { fill: var(--ac-lamp, #ffd38a); filter: var(--ac-lamp-glow, drop-shadow(0 0 2px #ffd38a) drop-shadow(0 0 9px rgba(255, 190, 100, .6))); }
.ac-finial { fill: var(--ac-finial, #d9b46a); filter: var(--ac-finial-glow, drop-shadow(0 0 3px rgba(240, 220, 174, .7))); }
.ac-rim { fill: none; stroke: var(--ac-rim, #93a8cf); stroke-opacity: var(--ac-rim-o, .5); stroke-width: var(--ac-rim-w, 1); stroke-linecap: round; }
.ac-bal { fill: none; stroke: var(--ac-trim, #202838); }
.ac-bal-m { fill: none; stroke: var(--ac-mass, #10131b); }

/* Fenster flackern (Rosette und Portal bleiben ruhig), Laternen atmen */
.ac-win > :nth-child(5n+4) { animation: ac-flick 9s steps(1, end) infinite; animation-play-state: var(--ac-anim, running); }
.ac-win > :nth-child(7n+6) { animation: ac-flick 13s steps(1, end) infinite reverse; animation-play-state: var(--ac-anim, running); }
.ac-lamp > :nth-child(3n+1) { animation: ac-lamp 3.4s ease-in-out infinite alternate; animation-play-state: var(--ac-anim, running); }
@keyframes ac-flick { 0%, 100% { opacity: 1; } 38% { opacity: .35; } 41% { opacity: 1; } 72% { opacity: .6; } 74% { opacity: 1; } }
@keyframes ac-lamp { to { opacity: .78; } }

/* Nachtfarben der Szene, Premium-Verläufe aus den Seiten-defs */
.acad {
  --ac-far: #1c2230; --ac-mass: #10131b; --ac-terrace: #0e121a; --ac-rock: #090b11; --ac-roof: #1a2131;
  --ac-trim: #202838; --ac-dark: #07090e; --ac-win: #f2b35a; --ac-lamp: #ffd38a; --ac-finial: #d9b46a;
  --ac-rim: #9fb2d6; --ac-rim-o: .5;
}
.acad.prem { --ac-mass: url(#acad-g-mass) #10131b; --ac-roof: url(#acad-g-roof) #1a2131; --ac-terrace: url(#acad-g-terrace) #0e121a; }
.acad-refl { --ac-win: #d08a3c; --ac-lamp: #e0a050; --ac-rim-o: .18; --ac-far: #161c29; --ac-win-glow: none; --ac-lamp-glow: none; --ac-finial-glow: none; }

@media (prefers-reduced-motion: reduce) {
  .ac-win > *, .ac-lamp > * { animation: none !important; }
}

/* ---------- Mond: weiche Scheibe mit Randverdunkelung und leiser Marmorierung ---------- */
.hm__disc {
  background:
    radial-gradient(circle at 50% 50%, transparent 52%, rgba(146, 136, 112, .17) 78%, rgba(108, 98, 82, .42) 100%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'%3E%3Cfilter id='n' x='0' y='0' width='1' height='1'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.032' numOctaves='3' seed='11'/%3E%3CfeColorMatrix values='0 0 0 0 .47  0 0 0 0 .45  0 0 0 0 .41  1.35 0 0 0 -.52'/%3E%3C/filter%3E%3Crect width='100' height='100' filter='url(%23n)'/%3E%3C/svg%3E") center / 100% 100%,
    radial-gradient(ellipse 30% 22% at 62% 40%, rgba(158, 150, 126, .2), transparent 72%),
    radial-gradient(ellipse 20% 28% at 40% 60%, rgba(158, 150, 126, .15), transparent 70%),
    radial-gradient(ellipse 26% 16% at 64% 67%, rgba(158, 150, 126, .12), transparent 70%),
    radial-gradient(circle at 40% 37%, #fffaf0 0%, #f7f0dc 42%, #e7ddc4 76%, #d2c6a8 100%);
  box-shadow: 0 0 10px 2px rgba(255, 246, 220, .4), 0 0 40px 12px rgba(196, 212, 245, .18), 0 0 110px 36px rgba(150, 172, 225, .09);
}

/* ---------- Korn über Szene und Tafeln (statische Kachel, keine Mischmodi) ---------- */
.hm__vig::after,
.pn__art-in::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='g' x='0' y='0' width='1' height='1'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' seed='5' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .86  0 0 0 0 .9  0 0 0 0 1  0 0 0 1.5 -.7'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23g)' opacity='.11'/%3E%3C/svg%3E") 0 0 / 200px 200px repeat;
  opacity: 1;
}
.pn__art-in::after { z-index: 1; }

/* ---------- Galerie: Akademie jenseits des Sees (Tafel 3) ---------- */
.pc-acad:not(.acad-refl) { --ac-rim-o: .4; }

/* ---------- Eule im Gleitflug (Briefe): Größe, Flughöhe über der Überschrift, ruhiger Flügelschlag ---------- */
.post__owl { width: clamp(92px, 8.6vw, 136px); top: 3.5%; }
.post__owl .ow__near { transform-box: fill-box; transform-origin: 100% 82%; animation: ow-beat 3.2s ease-in-out infinite; }
.post__owl .ow__far { transform-box: fill-box; transform-origin: 93% 97%; animation: ow-beat 3.2s -.12s ease-in-out infinite; }
@keyframes ow-beat { 0%, 100% { transform: rotate(0deg); } 40% { transform: rotate(-11deg) scaleY(.93); } 70% { transform: rotate(2deg); } }

@media (prefers-reduced-motion: reduce) {
  .post__owl .ow__near, .post__owl .ow__far { animation: none !important; }
}

/* Dauerschleifen des Symbols ruhen, wenn der Hero aus dem Bild ist (home.js setzt .is-off) und in der Galerie */
.hm.is-off .acad, .pn .acad { --ac-anim: paused; }
