/* Geisterarchiv – Das alte Grimoire: versiegelte Karten, Grimoire-Fenster mit Vorschau und Kauf, aufbrechendes Siegel. */

/* Karten sind Knöpfe */
button.karte.zu { width: 100%; text-align: left; font: inherit; cursor: pointer; align-items: stretch;
  transition: transform .45s cubic-bezier(.2, .7, .2, 1), box-shadow .45s, border-color .45s; }
button.karte.zu:hover, button.karte.zu:focus-visible { outline: none; transform: translateY(-4px); border-color: rgba(201, 163, 82, .6);
  box-shadow: inset 0 0 0 4px #170d07, inset 0 0 0 5px rgba(201, 163, 82, .2), 0 0 26px rgba(255, 170, 70, .16); }
.karte.zu .quelle { color: rgba(234, 217, 179, .5); }
.karte.zu.offen { background: linear-gradient(160deg, #3a2414, #1c110a); border-color: rgba(201, 163, 82, .5); }
.karte.zu.offen .preis { color: var(--gold-hell); }
.siegel.gebrochen { background: none; box-shadow: none; color: transparent; }
.siegel.gebrochen::before, .siegel.gebrochen::after {
  content: ""; position: absolute; width: 22px; height: 44px; top: 0;
  background: radial-gradient(circle at 80% 34%, #c8402c, #8e1a10 55%, #4f0b06);
}
.siegel.gebrochen::before { left: -3px; border-radius: 44px 0 0 44px; transform: rotate(-14deg); clip-path: polygon(0 0, 100% 0, 80% 30%, 100% 55%, 75% 75%, 100% 100%, 0 100%); }
.siegel.gebrochen::after { right: -3px; border-radius: 0 44px 44px 0; transform: rotate(12deg); clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 25% 75%, 0 55%, 20% 30%); }

.grimoire-paket { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 18px; margin: -6px 0 24px; text-align: center; }
.grimoire-paket[hidden], .grim-paypal[hidden] { display: none; }
.grimoire-paket p { margin: 0; color: var(--ui-leise); font-style: italic; }
.grimoire-paket b { color: var(--gold-hell); font-style: normal; font-weight: 500; }

/* Knöpfe */
.grim-knopf {
  display: inline-block; padding: 10px 20px; cursor: pointer; text-decoration: none; text-align: center;
  font-family: "Cormorant", serif; font-weight: 600; font-size: 19px; color: var(--gold-hell);
  background: rgba(18, 11, 6, .8); border: 1px solid rgba(201, 163, 82, .55);
}
.grim-knopf:hover, .grim-knopf:focus-visible { outline: none; border-color: var(--gold); box-shadow: 0 0 20px rgba(255, 170, 70, .2); }
.grim-knopf.haupt { display: block; margin: 16px auto 0; min-width: 240px; background: linear-gradient(180deg, #3a2414, #24150b); border-color: var(--gold); }

/* Fenster */
.grim-huelle { position: fixed; inset: 0; z-index: 90; display: flex; align-items: flex-start; justify-content: center; padding: 24px 16px; overflow-y: auto;
  background: rgba(6, 4, 2, .8); backdrop-filter: blur(3px); animation: grim-ein .4s ease both; }
@keyframes grim-ein { from { opacity: 0; } }
.grim-fenster {
  position: relative; width: min(100%, 560px); margin: auto 0; padding: 74px clamp(18px, 5vw, 36px) 26px;
  color: var(--ui); background: linear-gradient(170deg, #2c1a10, #140b06);
  border: 1px solid rgba(201, 163, 82, .35);
  box-shadow: inset 0 0 0 5px #140b06, inset 0 0 0 6px rgba(201, 163, 82, .18), 0 30px 60px rgba(0, 0, 0, .7);
  font-family: "Alegreya", Georgia, serif; font-size: 17px; line-height: 1.5;
}
.grim-zu { position: absolute; top: 12px; right: 12px; width: 40px; height: 40px; border-radius: 50%; cursor: pointer; font-size: 17px;
  color: var(--ui); background: rgba(255, 240, 210, .06); border: 1px solid rgba(201, 163, 82, .35); }
.grim-fenster h2 { margin: 0; font-family: "Fraktur", serif; font-weight: 400; font-size: clamp(34px, 8vw, 46px); line-height: 1.05; color: var(--gold-hell); text-align: center; }
.grim-fenster h3 { margin: 22px 0 6px; font-weight: 500; font-variant: small-caps; letter-spacing: .1em; font-size: 16px; color: var(--gold); }
.grim-kategorie { margin: 0; text-align: center; font-variant: small-caps; letter-spacing: .12em; font-size: 14px; color: var(--gold); }
.grim-quelle { margin: 6px 0 0; text-align: center; font-size: 14px; color: var(--ui-leise); }
.grim-vorschau { margin: 20px 0 0; padding: 14px 18px; border-left: 2px solid rgba(201, 163, 82, .5); background: rgba(255, 230, 180, .04); }
.grim-vorschau .orig { display: block; font-family: "Garamond", Georgia, serif; font-size: 19px; color: var(--gold-hell); }
.grim-vorschau .glosse { display: block; margin-top: 4px; font-style: italic; font-size: 15.5px; color: var(--ui-leise); }
.grim-erzaehlung { margin: 0; }
.grim-anliegen { margin: 14px 0 0; font-style: italic; color: var(--ui-leise); }
.grim-liste { margin: 18px 0 0; padding: 0 0 0 1.1em; }
.grim-liste li { margin: 4px 0; color: var(--ui-leise); }
.grim-liste b { color: var(--gold-hell); font-weight: 500; }

.grim-unten { margin-top: 22px; padding-top: 18px; border-top: 1px solid rgba(201, 163, 82, .2); }
.grim-wahl { display: grid; gap: 8px; }
.grim-option { display: flex; align-items: center; gap: 10px; padding: 10px 12px; cursor: pointer; border: 1px solid rgba(201, 163, 82, .28); background: rgba(255, 230, 180, .03); }
.grim-option:has(input:checked) { border-color: var(--gold); background: rgba(201, 163, 82, .08); }
.grim-option input { accent-color: #c9a352; }
.grim-option .was { flex: 1; }
.grim-option .betrag, .grim-betrag-zeile { font-weight: 600; color: var(--gold-hell); }
.grim-betrag-zeile { margin: 0; text-align: center; font-size: 19px; }
.grim-zustimmung { display: flex; gap: 10px; align-items: flex-start; margin: 14px 0 0; font-size: 14.5px; line-height: 1.45; cursor: pointer; }
.grim-zustimmung input { margin-top: 4px; width: 18px; height: 18px; flex: none; accent-color: #c9a352; }
.grim-zustimmung a, .grim-klein-text a { color: var(--gold-hell); }
.grim-paypal { margin: 16px 0 0; padding: 12px; background: #f6efe1; border-radius: 4px; min-height: 60px; }
.grim-meldung { margin: 10px 0 0; min-height: 1.2em; color: var(--gold-hell); font-style: italic; }
.grim-meldung:empty { display: none; }
.grim-klein-text { margin: 10px 0 0; font-size: 13.5px; color: rgba(234, 217, 179, .55); line-height: 1.45; }
.grim-bald, .grim-offen { margin: 0; text-align: center; font-family: "Cormorant", serif; font-style: italic; font-weight: 500; font-size: 22px; color: var(--gold-hell); }
.grim-schluessel { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px 12px; margin: 16px 0 0; padding: 12px; border: 1px dashed rgba(201, 163, 82, .5); }
.grim-schluessel .beschriftung { width: 100%; text-align: center; font-variant: small-caps; letter-spacing: .1em; font-size: 13px; color: var(--gold); }
.grim-schluessel code { font-family: ui-monospace, Consolas, monospace; font-size: clamp(17px, 4.6vw, 21px); letter-spacing: .06em; color: var(--gold-hell); }
.grim-klein { padding: 5px 12px; cursor: pointer; font: inherit; font-size: 14px; color: var(--ui); background: none; border: 1px solid rgba(201, 163, 82, .45); }

/* Siegel oben im Fenster: bricht beim Kauf auf */
.grim-siegel { position: absolute; top: 14px; left: 50%; width: 56px; height: 56px; margin-left: -28px; }
.grim-siegel .haelfte {
  position: absolute; top: 0; width: 28px; height: 56px; overflow: hidden; display: block;
  font-family: "Fraktur", serif; font-size: 30px; line-height: 56px; color: #5a0d07;
  background: radial-gradient(circle at 70% 36%, #c8402c, #8e1a10 55%, #4f0b06);
  box-shadow: 0 4px 8px rgba(0, 0, 0, .5);
  transition: transform 1.1s cubic-bezier(.3, 1.4, .5, 1), opacity 1.6s ease;
}
.grim-siegel .links { left: 0; border-radius: 56px 0 0 56px; text-indent: 15px; }
.grim-siegel .rechts { right: 0; border-radius: 0 56px 56px 0; text-indent: -13px; background: radial-gradient(circle at 10% 36%, #c8402c, #8e1a10 55%, #4f0b06); }
.grim-siegel.gebrochen .links, .grim-siegel.bricht .links { transform: translateX(-10px) rotate(-18deg); }
.grim-siegel.gebrochen .rechts, .grim-siegel.bricht .rechts { transform: translateX(10px) rotate(16deg); }
.grim-siegel.bricht::after { content: ""; position: absolute; inset: -40px; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(255, 200, 110, .55), rgba(255, 170, 70, 0) 65%); animation: grim-licht 1.8s ease-out forwards; }
@keyframes grim-licht { from { opacity: 0; transform: scale(.4); } 30% { opacity: 1; } to { opacity: 0; transform: scale(1.6); } }
.grim-fenster.frisch { animation: grim-glimmen 2.4s ease-out; }
@keyframes grim-glimmen { 0% { box-shadow: inset 0 0 0 5px #140b06, inset 0 0 0 6px rgba(201, 163, 82, .18), 0 0 0 rgba(255, 170, 70, 0); }
  30% { box-shadow: inset 0 0 0 5px #140b06, inset 0 0 0 6px rgba(201, 163, 82, .6), 0 0 70px rgba(255, 170, 70, .35); } }

.grim-toast { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); z-index: 95; max-width: calc(100% - 32px); margin: 0; padding: 12px 18px;
  background: #2c1a10; border: 1px solid var(--gold); color: var(--gold-hell); box-shadow: 0 10px 30px rgba(0, 0, 0, .6); animation: grim-ein .4s ease both; }

@media (prefers-reduced-motion: reduce) {
  .grim-siegel .haelfte { transition: none; } .grim-siegel.bricht::after, .grim-fenster.frisch { animation: none; }
}
/* Aus dem 6. und 7. Buch Mosis: eigenes Unterregal, Siegel als Tafel (rote Tinte auf Pergament) */
.mosis-kopf { margin: 44px auto 22px; max-width: 40em; text-align: center; }
.mosis-kopf h3 { margin: 0; font-family: "Fraktur", serif; font-weight: 400; font-size: clamp(28px, 4.4vw, 38px); line-height: 1.1; color: var(--gold); }
.mosis-kopf h3::before, .mosis-kopf h3::after { content: "✶"; margin: 0 .5em; font-family: "Alegreya", serif; font-size: .5em; vertical-align: middle; color: rgba(201, 163, 82, .7); }
.mosis-kopf p { margin: .5em 0 0; font-style: italic; color: var(--ui-leise); font-size: 16px; line-height: 1.5; }
.mosis-kopf a { color: var(--gold-hell); }
.tafel {
  display: block; padding: 7px 9px; line-height: 0;
  background: url("bild/pergament.webp") center / 100% 100% no-repeat;
  filter: sepia(.12) brightness(.92) drop-shadow(0 4px 8px rgba(0, 0, 0, .5));
}
.tafel img { display: block; width: 100%; height: auto; aspect-ratio: 1000 / 630; object-fit: contain; }
.karte.mit-tafel .tafel { margin: -6px -8px 14px; transition: filter .45s; }
button.karte.mit-tafel:hover .tafel, button.karte.mit-tafel:focus-visible .tafel { filter: sepia(.05) brightness(1) drop-shadow(0 4px 12px rgba(255, 170, 70, .25)); }
.karte.zu.mit-tafel:not(.offen) .tafel img { opacity: .9; }
.grim-tafel { margin: 18px auto 0; max-width: 360px; padding: 10px 12px; }

.grim-gesprochen { margin: 14px 0 0; padding: 10px 14px; border: 1px solid rgba(201, 163, 82, .35); background: rgba(201, 163, 82, .07); font-size: 15.5px; color: var(--gold-hell); }
.grim-gesprochen::before { content: "♪ "; color: var(--gold); }

/* Eigene Sektion „Das 6. und 7. Buch Mosis“ (seit 12.10., eigenes Paket) */
.mosis-regal { margin-top: 44px; }
.grimoire-kopf a { color: var(--gold-hell); }
.grimoire-kopf .bereich-preise { margin-top: .5em; font-size: 15px; }
.mosis-regal .grimoire-kopf { max-width: 44em; margin-left: auto; margin-right: auto; }
.mosis-regal .grimoire-kopf p { line-height: 1.5; }
