/* Edition C: vorhandene Website-Farben und Archivo; eine unveränderte Buchengine. */
.ebook-seite { padding-top: var(--kopf-h); }
.fb { --fb-cover-groesse: .82; --fb-akzent: var(--lime); --fb-linie: color-mix(in srgb,var(--ink) 18%,transparent); --fb-gedimmt: color-mix(in srgb,var(--ink) 65%,transparent); position: relative; display: grid; grid-template-columns: .95fr 1.05fr; grid-template-rows: 64px minmax(0,1fr); height: calc(100svh - var(--kopf-h)); min-height: 0; background: transparent; color: var(--ink); font-stretch: normal; isolation: isolate; }
.fb button { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: .65rem 1rem; border: 1px solid var(--fb-linie); background: transparent; border-radius: 2px; color: inherit; font: inherit; font-size: .82rem; font-weight: 550; line-height: 1.2; cursor: pointer; gap: .65rem; transition: background .18s,color .18s,border-color .18s; }
.fb button:hover:not(:disabled) { background: rgba(255, 255, 255, 0.4); border-color: var(--ink); }
.fb button:disabled { opacity: .3; cursor: default; }
.fb button svg { flex: none; }
.fb button.fb__icon { width: 44px; min-width: 44px; padding: 0; border-color: transparent; }
.fb button[aria-expanded="true"],.fb button[aria-pressed="true"] { background: var(--fb-akzent); color: var(--ink); }
.fb :focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; box-shadow: none; }
.fb__intro { grid-column: 1; grid-row: 1 / 3; align-self: center; padding: 2rem clamp(1.5rem,4.8vw,6rem); display: grid; justify-items: start; gap: 1.6rem; }
.fb__rubrik { display: flex; align-items: center; gap: .7rem; font-size: .65rem; font-weight: 650; letter-spacing: .13em; text-transform: uppercase; }
.fb__rubrik > span:empty { width: 1.7rem; height: 2px; background: var(--ink); }
.fb__intro h1 { font-size: clamp(3rem,5.5vw,7rem); line-height: .94; letter-spacing: -.025em; }
.fb__intro h1 span { white-space: nowrap; }
.fb__einleitung { font-size: clamp(.95rem,1.25vw,1.15rem); line-height: 1.65; color: var(--fb-gedimmt); }
.fb button.fb__start { min-height: 54px; min-width: 190px; justify-content: space-between; padding: .8rem 1.15rem; margin-top: .5rem; background: var(--fb-akzent); color: var(--ink); border-color: var(--fb-akzent); font-size: .9rem; }
.fb button.fb__start:hover:not(:disabled) { background: var(--ink); color: var(--fb-akzent); border-color: var(--ink); }
.fb__ausgabe { display: grid; gap: .4rem; width: 100%; max-width: 330px; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--fb-linie); font-size: .68rem; color: var(--fb-gedimmt); }
.fb__ausgabe > span:first-child { text-transform: uppercase; letter-spacing: .11em; font-weight: 650; color: var(--ink); }
.fb__kopf { grid-column: 2; grid-row: 1; display: flex; justify-content: space-between; align-items: center; padding: .5rem clamp(.75rem,2vw,2rem); gap: .8rem; min-width: 0; }
.fb__marke { display: grid; gap: .2rem; min-width: 0; }
.fb__marke [data-buchtitel] { font-size: .75rem; color: var(--fb-gedimmt); white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.fb__kopfaktionen { display: flex; align-items: center; gap: .5rem; }
.fb__mitte { grid-column: 2; grid-row: 2; min-width: 0; min-height: 0; position: relative; overflow-x: clip; }
.fb__viewport { position: relative; height: 100%; min-height: 0; overflow: auto; scrollbar-gutter: stable both-edges; overscroll-behavior: contain; touch-action: pan-y pinch-zoom; display: flow-root; background: transparent; }
.fb:not(.fb--zoom) .fb__viewport { overflow: visible; }
.fb__zoomflaeche { position: relative; margin: 16px auto; }
.fb__geometrie { position: absolute; top: 0; left: 0; transform: translateX(var(--fb-versatz,0px)) scale(var(--fb-zoom,1)); transform-origin: 0 0; transition: transform 420ms cubic-bezier(.22,.61,.36,1); }
.fb__geometrie > div { width: 100%; height: 100%; }
.fb:not([data-lesemodus="true"]) .fb__geometrie { pointer-events: none; }
/* Zoom bleibt scrollbar; nur die sichtbaren Balken und ihre Reserve entfallen. */
.fb--zoom .fb__viewport { cursor: grab; touch-action: pan-x pan-y pinch-zoom; scrollbar-width: none; scrollbar-gutter: auto; }
.fb--zoom .fb__viewport::-webkit-scrollbar { display: none; width: 0; height: 0; }
.fb--ziehen .fb__viewport { cursor: grabbing; user-select: none; }
.fb__page { background: var(--fb-papier,rgba(243, 240, 233, 1)); color: rgba(36, 41, 45, 1); overflow: hidden; }
.fb__papier { position: relative; width: 100%; height: 100%; box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.05); }
.fb--falz .fb__papier::after { content: ""; position: absolute; top: 0; bottom: 0; width: clamp(2px,var(--fb-falz-breite,4%),80px); pointer-events: none; }
.fb--falz .fb__papier--links::after { right: 0; background: linear-gradient(to right,transparent,rgb(0 0 0 / calc(var(--fb-falz-staerke,.22) * .18)) 60%,rgb(0 0 0 / calc(var(--fb-falz-staerke,.22) * .82))); }
.fb--falz .fb__papier--rechts::after { left: 0; background: linear-gradient(to right,rgb(0 0 0 / var(--fb-falz-staerke,.22)),rgb(0 0 0 / calc(var(--fb-falz-staerke,.22) * .23)) 35%,transparent); }
.fb--falz .fb__page[data-deckel] .fb__papier::after { display: none; }
.fb__page[data-density="hard"] .fb__papier { box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.13); }
.fb__page img { display: block; width: 100%; height: 100%; object-fit: contain; user-select: none; -webkit-user-drag: none; }
.fb__seite-laden { position: absolute; inset: 0; display: grid; place-content: center; padding: 1rem; text-align: center; color: rgba(106, 110, 111, 1); font-size: .85rem; }
.fb__platzhalter[hidden],.fb__seite-laden[hidden] { display: none; }
.fb__platzhalter { position: absolute; inset: 0; padding: 2rem; display: grid; place-content: center; text-align: center; color: var(--fb-gedimmt); pointer-events: none; }
.fb__geometrie::before { content: ""; position: absolute; inset: 2px 0; z-index: -1; border-radius: 2px; box-shadow: 0 var(--fb-buch-abstand,22px) var(--fb-buch-weichheit,30px) calc(var(--fb-buch-weichheit,30px) * -.4667) rgb(0 0 0 / var(--fb-buch-staerke,.33)),0 calc(var(--fb-buch-abstand,22px) * .2273) calc(var(--fb-buch-weichheit,30px) * .4) calc(var(--fb-buch-weichheit,30px) * -.1) rgb(0 0 0 / calc(var(--fb-buch-staerke,.33) * .4)); pointer-events: none; }
.fb:not([data-buchzustand="offen"]) .fb__geometrie::before { display: none; }
.fb[data-buchzustand="front"][data-blaetterstatus="read"] .fb__page[data-deckel="front"],
.fb[data-buchzustand="back"][data-blaetterstatus="read"] .fb__page[data-deckel="back"] { box-shadow: 0 var(--fb-buch-abstand,22px) var(--fb-buch-weichheit,30px) calc(var(--fb-buch-weichheit,30px) * -.4667) rgb(0 0 0 / var(--fb-buch-staerke,.33)),0 calc(var(--fb-buch-abstand,22px) * .2273) calc(var(--fb-buch-weichheit,30px) * .4) calc(var(--fb-buch-weichheit,30px) * -.1) rgb(0 0 0 / calc(var(--fb-buch-staerke,.33) * .4)); }
.fb__geometrie--layout,.fb--radzoom .fb__geometrie { transition: none; }
.fb[data-uebergang="true"] .fb__mitte,.fb[data-uebergang="true"] button,.fb[data-uebergang="true"] input { pointer-events: none; }
.fb__fuss { display: none; }
/* Leseansicht: Bühne und Bedienung passen gemeinsam unter den Website-Kopf. */
.fb[data-lesemodus="true"] { grid-template-columns: minmax(0,1fr); grid-template-rows: 60px minmax(0,1fr) auto; height: calc(100dvh - var(--kopf-h)); }
.fb[data-lesemodus="true"] .fb__intro { display: none; }
.fb[data-lesemodus="true"] .fb__kopf { grid-column: 1; border-bottom: 1px solid var(--fb-linie); }
.fb[data-lesemodus="true"] .fb__mitte { grid-column: 1; grid-row: 2; }
.fb[data-lesemodus="true"] .fb__fuss { grid-column: 1; grid-row: 3; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; column-gap: 1rem; padding: .25rem clamp(.75rem,2vw,2rem) calc(.65rem + env(safe-area-inset-bottom)); background: var(--beton); border-top: 1px solid var(--fb-linie); }
.fb__blaettern,.fb__zoomwerkzeuge,.fb__ansichtswerkzeuge { display: flex; align-items: center; gap: .2rem; }
.fb__blaettern { justify-self: start; }
.fb__zoomwerkzeuge { justify-self: center; }
.fb__ansichtswerkzeuge { justify-self: end; }
.fb__seitenfeld { display: inline-flex; align-items: center; gap: .4rem; font-size: .76rem; white-space: nowrap; font-variant-numeric: tabular-nums; }
.fb__seitenfeld input { width: 3rem; min-height: 44px; border: 0; border-bottom: 1px solid var(--fb-linie); border-radius: 0; text-align: center; background: transparent; color: inherit; font: inherit; appearance: textfield; }
.fb__seitenfeld input::-webkit-inner-spin-button { appearance: none; }
.fb [data-fb="einpassen"] { border: 0; min-width: 68px; font-variant-numeric: tabular-nums; }
/* Zusatzfunktionen erscheinen nur bei Bedarf, ohne die Buchfläche zu verkleinern. */
.fb__seitenleiste,.fb__lesetext { position: absolute; z-index: 20; background: var(--beton-hell); border: 1px solid var(--fb-linie); box-shadow: 0 16px 44px rgba(0, 0, 0, 0.13); overflow: auto; overscroll-behavior: contain; }
.fb__seitenleiste { inset: .65rem .75rem .65rem auto; width: min(340px,calc(100% - 1.5rem)); padding: 1rem; }
.fb__seitenleistenkopf { display: flex; align-items: center; justify-content: space-between; gap: .75rem; position: sticky; top: -1rem; padding: .35rem 0; background: var(--beton-hell); z-index: 1; }
.fb__seitenleistenkopf h2 { font-size: 1rem; font-stretch: 85%; line-height: 1.2; }
.fb__tools-aktionen button { justify-content: flex-start; }
.fb__tools details { padding: .9rem 0; border-top: 1px solid var(--fb-linie); }
.fb__tools summary { cursor: pointer; min-height: 24px; font-size: .8rem; font-weight: 600; }
.fb__tools details > div { display: grid; gap: .5rem; padding-top: 1rem; }
.fb__tools details p { font-size: .75rem; color: var(--fb-gedimmt); margin-top: .75rem; line-height: 1.65; }
.fb__tools a { font-size: .8rem; padding: .75rem 0; text-underline-offset: .2em; }
.fb__inhaltsliste { display: grid; gap: .4rem; padding-top: .6rem; }
.fb__inhaltsliste button { width: 100%; justify-content: space-between; text-align: left; gap: .6rem; }
.fb__thumbliste { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .7rem; padding-top: .6rem; }
.fb__thumbliste button { width: 100%; display: grid; gap: .4rem; padding: .5rem; }
.fb__thumbliste img { width: 100%; height: 140px; object-fit: contain; background: var(--fb-papier,rgba(243, 240, 233, 1)); }
.fb__thumbliste [aria-current="page"] { border-color: var(--ink); background: var(--fb-akzent); }
.fb__lesetext { top: 64px; right: 1rem; bottom: 120px; width: min(600px,calc(100% - 2rem)); padding: 1.25rem; }
.fb__lesetext h2 { font-size: 1.5rem; margin-bottom: 1rem; }
.fb__lesetext h3 { font: inherit; font-weight: 650; margin: 1rem 0 .4rem; }
.fb__lesetext p { white-space: pre-line; font-size: .9rem; line-height: 1.7; }
.fb__deckel { padding: 8%; text-align: center; background: linear-gradient(110deg,rgba(48, 58, 62, 1),rgba(20, 27, 32, 1)); color: rgba(243, 240, 233, 1); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.15); }
.fb__deckel-inhalt { width: 100%; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4%; }
.fb__deckel strong { font-size: clamp(.7rem,2.6vw,2.5rem); letter-spacing: .035em; }
.fb__deckel span { font-size: clamp(.6rem,1.4vw,1.1rem); overflow-wrap: anywhere; }
.fb__deckel small { font-size: clamp(.4rem,.7vw,.7rem); color: var(--fb-akzent); letter-spacing: .1em; }
.fb__deckel--foto { padding: 0; background: var(--fb-papier,rgba(243, 240, 233, 1)); }
.fb:fullscreen { width: 100%; height: 100dvh; background: var(--beton); }
@media (max-width: 640px) {
  .fb { grid-template-columns: minmax(0,1fr); grid-template-rows: auto minmax(0,1fr); }
  .fb__intro { grid-column: 1; grid-row: 1; padding: 1.5rem var(--rand) .5rem; gap: .8rem; }
  .fb__intro h1 { font-size: clamp(2.6rem,10vw,3.6rem); }
  .fb__intro h1 span { white-space: normal; }
  .fb__einleitung { font-size: .85rem; line-height: 1.45; }
  .fb__einleitung br { display: none; }
  .fb button.fb__start { min-height: 48px; margin-top: .25rem; }
  .fb__ausgabe { display: none; }
  .fb:not([data-lesemodus="true"]) .fb__kopf { position: absolute; top: .5rem; right: .35rem; padding: 0; }
  .fb:not([data-lesemodus="true"]) .fb__marke { display: none; }
  .fb__mitte { grid-column: 1; grid-row: 2; }
  .fb[data-lesemodus="true"] { grid-template-rows: 56px minmax(0,1fr) auto; }
  .fb__kopf { padding-inline: .65rem; }
  .fb__marke .fb__rubrik { font-size: .52rem; }
  .fb__marke [data-buchtitel] { font-size: .65rem; max-width: 44vw; }
  .fb[data-lesemodus="true"] .fb__fuss { grid-template-columns: 1fr 1fr; padding-inline: .6rem; gap: 0 .5rem; }
  .fb__blaettern { grid-column: 1 / -1; justify-self: center; }
  .fb__zoomwerkzeuge { justify-self: start; }
  .fb__ansichtswerkzeuge { justify-self: end; }
  .fb__seitenleiste { inset: .5rem; width: auto; }
}
@media (max-height: 560px) and (min-width: 641px) {
  .fb__intro { gap: .65rem; padding-block: .5rem; }
  .fb__intro h1 { font-size: 3rem; }
  .fb__ausgabe { margin-top: 0; padding-top: .5rem; }
  .fb__einleitung { font-size: .85rem; }
  .fb__kopf { padding-block: 0; }
}
@media (prefers-reduced-motion: reduce) { .fb__geometrie,.fb__geometrie::before { transition: none; } }

.fb .stf__parent { touch-action: pan-y pinch-zoom; }
.fb--zoom .stf__parent { touch-action: pan-x pan-y pinch-zoom; }

/* Eine hochklappende Buchhälfte hat keine flache Auflagefläche mehr. */
/* Nur der Deckel hebt eine ganze Buchhälfte ab; weiche Seiten behalten die Auflage. */
.fb:has(.stf__hardShadow[style*="display: block"]) .fb__geometrie::before { display: none; }
/* Native Deckelschatten sind unbeschnittene Rechteckflächen auf der leeren Hälfte.
   Soft-Paper-Schatten, Falz und Bodenschatten im Stillstand bleiben erhalten. */
.fb .stf__hardShadow,.fb .stf__hardInnerShadow { display: none !important; }

/* Fokus zeigt Bedienbarkeit, keine Auswahl der gesamten Präsentationsfläche. */
.fb .fb__viewport:focus-visible { outline: none; box-shadow: none; }
.fb__mitte:has(.fb__viewport:focus-visible)::after,
.studie-studio .fb[data-lesemodus="true"]:has(:focus-visible) .fb__mitte::after { content: "← →  Blättern · + / −  Zoom"; position: absolute; top: .35rem; left: .75rem; z-index: 12; padding: .3rem .5rem; border-left: 2px solid var(--ink); background: var(--beton); color: var(--ink); font-size: .62rem; line-height: 1.3; pointer-events: none; }

/* Buchpapier darf beim Ziehen auch den Website-Kopf überdecken.
   Kopf = Ebene 60, Desktop-Menü = 61. Im Stillstand gilt die normale Reihenfolge. */
.fb[data-blaetterstatus="user_fold"],.fb[data-blaetterstatus="flipping"] { z-index: 62; }
.fb__mitte { z-index: 1; }

/* Während einer physischen Ziehgeste keine fremden Hover-/Klick-Ziele. */
body:has(.fb--geste) { user-select: none; -webkit-user-select: none; cursor: grabbing; }
body:has(.fb--geste) :is(.kopf,.menue,.fuss),
body:has(.fb--geste) :is(.kopf,.menue,.fuss) *,
.fb--geste :is(.fb__kopf,.fb__fuss,.fb__seitenleiste,.fb__lesetext),
.fb--geste :is(.fb__kopf,.fb__fuss,.fb__seitenleiste,.fb__lesetext) * { pointer-events: none !important; }

/* Derselbe Transform-Weg verbindet Einstieg und Leseansicht in beide Richtungen. */
.fb[data-uebergang="true"] { z-index: 62; }
.fb[data-uebergang="true"] .fb__mitte { overflow: visible; }
.fb__intro { transition: opacity 180ms ease; }
.fb[data-uebergang="true"][data-lesemodus="false"] .fb__intro { opacity: 0; }

/* A/B/C: gemeinsame Doppelseitenübersicht wie beim 3D-Portfolio. */
.fb--uebersicht .fb__seitenleiste {
  inset: auto auto .75rem 50%; transform: translateX(-50%);
  width: min(580px,calc(100% - 1.5rem));
  max-height: min(450px,62dvh,calc(100dvh - var(--kopf-h) - 100px));
  padding: .75rem; border-radius: 3px; box-shadow: 0 10px 24px rgba(0, 0, 0, 0.07);
}
.fb--uebersicht .fb__seitenleistenkopf { top: -.75rem; }
.fb--uebersicht .fb__thumbliste { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 8px; user-select: none; }
.fb--uebersicht .fb__thumbliste button { min-height: 90px; height: 100%; gap: 7px; padding: 8px; border-radius: 2px; justify-items: center; font-size: 10px; line-height: 1.4; }
.fb--uebersicht .fb__thumbnail { display: flex; height: 64px; width: 100%; justify-content: center; align-items: stretch; }
.fb--uebersicht .fb__thumbnail img { display: block; height: 64px; width: auto; max-width: 50%; object-fit: contain; -webkit-user-drag: none; }
.fb--uebersicht .fb__thumbnail img:not([src]) { visibility: hidden; }
.fb--uebersicht .fb__thumbnail img:only-child { max-width: 100%; }
@media(max-width:640px) {
  .fb--uebersicht .fb__thumbliste { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

.fb-development { position: absolute; inset: 72px 12px 100px auto; z-index: 30; width: min(350px,calc(100% - 24px)); max-height: calc(100% - 90px); margin: 0; padding: 14px; overflow: auto; overscroll-behavior: contain; border: 1px solid var(--fb-linie); border-radius: 3px; background: var(--beton-hell); color: var(--ink); box-shadow: 0 8px 30px rgba(0, 0, 0, 0.13); font: 12px/1.5 Archivo,Arial,sans-serif; }
.fb-development:not([open]) { display: none; }
.fb-development header { position: sticky; top: -14px; z-index: 1; display: flex; align-items: center; justify-content: space-between; background: var(--beton-hell); }
.fb-development h2 { font-size: 16px; }
.fb-development p { font-size: 11px; margin: 8px 0; }
.fb-development fieldset { border: 1px solid var(--fb-linie); padding: 10px; margin-block: 12px; }
.fb-development legend { font-weight: 650; }
.fb-development button { min-height: 36px; padding: 6px 10px; font-size: 12px; }
.fb-dev-field { display: grid; grid-template-columns: minmax(0,1fr) 28px; gap: 6px; align-items: center; margin-block: 10px; }
.fb-dev-field label { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 4px; }
.fb-dev-field label > span { grid-column: 1 / -1; }
.fb-dev-field input { width: 100%; min-width: 0; accent-color: var(--ink); }
.fb-dev-field input[type=checkbox] { width: auto; justify-self: start; }
.fb-dev-field output { font-size: 10px; font-variant-numeric: tabular-nums; }
.fb-development .fb-dev-field button { min-height: 28px; padding: 0; font-size: 17px; }
.fb-development footer { display: grid; gap: 8px; }
.fb-development textarea { width: 100%; font: 10px/1.5 monospace; }
@media(max-width:640px) { .fb-development { inset: 64px 8px 130px; width: auto; } }
@media(max-height:480px) { .fb-development { inset: 8px 8px 8px auto; max-height: calc(100% - 16px); } }

/* Edition C: Bediengruppen kompakt wie im 3D-Portfolio. */
.fb:not(.fb--minimal,.fb--studio)[data-lesemodus="true"] .fb__fuss {
  width: min(760px,calc(100% - 24px)); justify-self: center;
  column-gap: 12px; padding: 5px 0 max(10px,env(safe-area-inset-bottom));
}
.fb:not(.fb--minimal,.fb--studio) .fb__zoomwerkzeuge {
  border-inline: 1px solid var(--fb-linie); padding-inline: 12px;
}
@media(max-width:640px) {
  .fb:not(.fb--minimal,.fb--studio)[data-lesemodus="true"] .fb__fuss { grid-template-columns: 1fr auto; column-gap: 4px; }
  .fb:not(.fb--minimal,.fb--studio) .fb__blaettern { grid-column: 1; grid-row: 1; justify-self: start; }
  .fb:not(.fb--minimal,.fb--studio) .fb__ansichtswerkzeuge { grid-column: 2; grid-row: 1; }
  .fb:not(.fb--minimal,.fb--studio) .fb__zoomwerkzeuge { grid-column: 1 / -1; grid-row: 2; justify-self: center; border: 0; padding-inline: 0; }
}

/* Übersicht weiter scrollbar, ohne sichtbare Scrollbalken. */
.fb--uebersicht .fb__seitenleiste { scrollbar-width: none; }
.fb--uebersicht .fb__seitenleiste::-webkit-scrollbar { display: none; width: 0; height: 0; }

/* At 100% lift the moving sheet; zoomed folds stay with the clipped book. */
.fb.fb--blatt-ebene { z-index: 62; }
.fb .fb__blatt-ebene {
  position: fixed; z-index: 40; margin: 0; overflow: visible;
  transform-origin: 0 0; pointer-events: none; user-select: none;
}
.fb .fb__blatt-ebene[hidden] { display: none; }

.fb [data-fb=ton][aria-pressed=false] .fb__ton-an,.fb [data-fb=ton][aria-pressed=true] .fb__ton-aus { display: none; }


/* Geschlossen bleibt nur die Entwicklungsaktion; Besucherwerkzeuge gehören zur Leseansicht. */
.fb:not([data-lesemodus="true"]) .fb__fuss {
  grid-column: 2; grid-row: 3; display: flex; justify-content: flex-end; align-items: center;
  gap: 8px; padding: 4px 12px max(8px,env(safe-area-inset-bottom)); min-width: 0;
}
.fb:not([data-lesemodus="true"]) .fb__fuss > :not([data-fb-development]),
.fb:not([data-lesemodus="true"]) .fb__fuss:not(:has([data-fb-development])) { display: none; }
.fb.fb--minimal:not([data-lesemodus="true"]) .fb__fuss,
.fb.fb--studio:not([data-lesemodus="true"]) .fb__fuss { grid-column: 1; grid-row: 4; justify-content: center; }
.fb[data-lesemodus="true"] .fb__fuss:has([data-fb-development]) { grid-template-columns: auto auto auto auto; }
.fb[data-lesemodus="true"] .fb__fuss [data-fb-development] { grid-column: 4; grid-row: 1; justify-self: end; }
@media(max-width:820px) {
  .fb[data-lesemodus="true"] .fb__fuss,
  .fb[data-lesemodus="true"] .fb__fuss:has([data-fb-development]) { grid-template-columns: 1fr auto; gap: 0 4px; }
  .fb[data-lesemodus="true"] .fb__fuss .fb__blaettern { grid-column: 1 / -1; grid-row: 1; justify-self: center; }
  .fb[data-lesemodus="true"] .fb__fuss .fb__zoomwerkzeuge { grid-column: 1; grid-row: 2; justify-self: start; padding-inline: 0; border: 0; }
  .fb[data-lesemodus="true"] .fb__fuss .fb__ansichtswerkzeuge { grid-column: 2; grid-row: 2; }
  .fb [data-fb="einpassen"] { min-width: 56px; }
  .fb[data-lesemodus="true"] .fb__fuss [data-fb-development] { grid-column: 1 / -1; grid-row: 3; justify-self: center; }
}


@media(max-width:760px) { .fb.fb--studio[data-lesemodus="true"] .fb__fuss { width: calc(100% - 16px); padding-inline: 4px; } }

/* Manuelle Werte und Slider haben getrennte Bereiche. */
.fb-dev-field input[type=number] { width: 86px; padding: 4px; border: 1px solid var(--fb-linie); background: transparent; color: inherit; font: inherit; font-variant-numeric: tabular-nums; }
.fb-dev-field input[type=number][data-outside=true] { border-color: var(--ink); }

.fb-dev-field select { grid-column: 1 / -1; width: 100%; min-width: 0; padding: 6px; color: inherit; background: transparent; font: inherit; }

/* Gemeinsame Buchaktion für A/B/C; Öffnen bleibt am Cover. */
.fb .fb__buchschliessen[hidden] { display: none; }
.fb[data-lesemodus="true"] .fb__fuss [data-fb-development] {
  margin-inline-start: .5rem; padding-inline: .85rem; border: 0;
  border-inline-start: 1px solid var(--fb-linie); border-radius: 0;
  color: var(--fb-gedimmt); font-size: .75rem;
}
@media(max-width:820px) {
  .fb[data-lesemodus="true"] .fb__fuss [data-fb-development] { margin-inline-start: 0; border-inline-start: 0; }
}
@media(max-width:380px) {
  .fb[data-lesemodus="true"] .fb__fuss .fb__zoomwerkzeuge { grid-column: 1 / -1; grid-row: 2; justify-self: center; }
  .fb[data-lesemodus="true"] .fb__fuss .fb__ansichtswerkzeuge { grid-column: 1 / -1; grid-row: 3; justify-self: center; }
  .fb[data-lesemodus="true"] .fb__fuss [data-fb-development] { grid-row: 4; }
}

@media(max-width:760px) { .fb:not([data-lesemodus="true"]) .fb__fuss { grid-column: 1; } }

/* Reguläre Seitenmeldungen bleiben für Screenreader, Fehler bleiben sichtbar. */
.fb__meldung:not(.sr-only) { grid-column: 1 / -1; font-size: .75rem; padding: .5rem; }
.fb__bedienhilfe { margin-top: .75rem; border-top: 1px solid var(--fb-linie); font-size: .75rem; }
.fb__bedienhilfe summary { min-height: 44px; align-content: center; cursor: pointer; font-weight: 600; }
.fb__bedienhilfe p { margin-block: .5rem; line-height: 1.65; color: var(--fb-gedimmt); }

/* Ein Schalter für informative Lade- und Statusmeldungen, niemals für Fehler. */
.fb[data-hinweise="false"] :is(.fb__seite-laden,.fb__platzhalter):not([data-fehler]) { display: none; }
.fb__modus { font-size: .65rem; color: var(--fb-gedimmt); justify-self: end; }

/* Die Bühne behält ihre Maße; Papier und Schatten erst mit fertigen Bildern zeigen. */
.fb[data-startbereit="false"] .fb__geometrie { visibility: hidden; }
