.screen-runner .page-runner { min-height: 0; }
.brettspiel, .musikwerkstatt { gap: 12px; min-height: 0; }
.brettspiel .scan-prompt, .musikwerkstatt .scan-prompt { flex: none; margin: 0; font-size: clamp(16px, 2vw, 23px); }
/* Grundform ausserhalb des Uebungsrahmens; im Rahmen gilt das Brett-Geruest am Ende von play-upgrades.css. */
.brettspiel__body { display: flex; gap: 18px; flex: 1; min-height: 160px; overflow: hidden; align-items: center; }
.brettspiel__board { display: grid; height: 100%; width: auto; max-height: 520px; max-width: min(58vw, 520px); flex: 0 0 auto; aspect-ratio: 1; gap: 2px; }
.brettspiel__panel { display: flex; gap: 10px; flex-wrap: wrap; flex: 1; align-content: center; }
.brettspiel__panel .kunst-knopf { min-width: 120px; min-height: 96px; padding: 8px; flex: 1 1 150px; }
.brettspiel__panel .scan-card__label { font-size: 18px; }
.brettspiel__info { font-size: 16px; line-height: 1.5; flex-basis: 100%; }
.brettspiel__cell { position: relative; min-width: 0; min-height: 0; border: 2px solid transparent; padding: 3px; border-radius: 5px; display: flex; align-items: center; justify-content: center; cursor: pointer; color: #11223b; background: #b6d3be; }
.brettspiel__cell:disabled { opacity: 1; cursor: default; }
.brettspiel__cell.scan-focus { transform: none; outline-offset: -4px; outline: 5px solid #fbbf24; z-index: 1; }
.brettspiel__cell:focus-visible { outline: 5px solid #fbbf24; outline-offset: -5px; }
.brettspiel__ziel { border-color: #00b76b; box-shadow: inset 0 0 0 2px #0c5535; }
.brettspiel__selected { outline: 4px solid #e87717; outline-offset: -5px; }
.brettspiel__tipp { box-shadow: inset 0 0 0 5px #ee8a17; }
.schachbrett { grid-template-columns: repeat(8, minmax(0, 1fr)); grid-template-rows: repeat(8, minmax(0, 1fr)); }
.schachbrett__hell { background: #f4e5c8; }
.schachbrett__dunkel { background: #8b7359; }
.schachbrett__figur { width: 80%; height: 80%; object-fit: contain; }
.schachbrett small { position: absolute; bottom: 0; left: 2px; font-size: clamp(9px,1.2vw,14px); padding: 0 2px; background: #ffffffe0; color: #17243a; border-radius: 2px; }
.ludobrett { grid-template-columns: repeat(11, minmax(0, 1fr)); grid-template-rows: repeat(11, minmax(0, 1fr)); gap: 2px; background: #dee7ed; border-radius: 10px; padding: 5px; box-sizing: border-box; }
.ludobrett__feld { display: flex; align-items: center; justify-content: center; font-size: clamp(8px,1vw,13px); min-width: 0; min-height: 0; border-radius: 50%; }
.ludobrett__weg { border: 1px solid #64748b; background: #fff; color: #334155; }
.ludobrett__figur { width: 95%; height: 95%; display: flex; align-items: center; justify-content: center; border-radius: 50%; border: 2px solid #17243a; font-size: clamp(10px,1.5vw,18px); font-weight: bold; }
.ludo-farbe-0 { background: #ffb4ae; color: #531511; }
.ludo-farbe-1 { background: #a3ceff; color: #102c53; }
.ludo-farbe-2 { background: #a3e7b2; color: #103d20; }
.ludo-farbe-3 { background: #ffe18c; color: #473406; }
.reversibrett { background: #235b45; padding: 3px; }
.reversibrett .spiel-stein { width: 80%; height: 80%; }
.leiterbrett { grid-template-columns: repeat(10,1fr); aspect-ratio: 2; align-self: center; height: auto; width: min(58vw,520px); }
.leiterbrett__feld { min-height: 42px; position: relative; border-radius: 6px; background: #d7e5ef; color: #17243a; text-align: center; padding: 3px; font-size: 16px; }
.leiterbrett__feld small { display: block; font-size: 11px; }
.leiterbrett__hoch { background: #b2e4bc; }
.leiterbrett__runter { background: #ffc9a3; }
.leiterbrett .spiel-stein { width: 16px; height: 16px; }
.bingobrett { grid-template-columns: repeat(4,minmax(0,1fr)); grid-template-rows: repeat(4,minmax(0,1fr)); }
.bingobrett .brettspiel__cell { font-size: clamp(24px,5vw,45px); }
.musik__display { min-height: 48px; flex: none; padding: 10px 16px; border-radius: 12px; background: #dce8f2; color: #17243a; font-size: 19px; overflow-wrap: anywhere; max-height: 100px; overflow: auto; }
.musik__pads { display: grid; grid-template-columns: repeat(auto-fit,minmax(90px,1fr)); gap: 10px; flex: 1; min-height: 100px; }
.musik__pad { min-width: 0; min-height: 100px; border-bottom: 12px solid #4e70bf; }
.musik__pad:nth-child(3n+2) { border-bottom-color: #c36827; }
.musik__pad:nth-child(3n+3) { border-bottom-color: #28926e; }
.musik__pads--beat { grid-template-columns: repeat(8,minmax(0,1fr)); grid-template-rows: repeat(4,minmax(42px,1fr)); gap: 5px; }
.musik__step { min-height: 42px; min-width: 0; font-size: clamp(10px,1.5vw,17px); padding: 4px; }
.musik__step[aria-pressed=true] { background: #24694e; color: #fff; }
.musik__step.musik__playing { box-shadow: inset 0 0 0 4px #e99e22; }
.musik__pad.scan-holding { outline: 5px solid #e99e22; outline-offset: -5px; }
.brettspiel .scan-dim, .musikwerkstatt .scan-dim { opacity: 0.78; }
@media(max-width:650px) {
  .brettspiel__body { flex-direction: column; align-items: center; }
  .brettspiel__board { width: min(100%,420px); height: auto; max-height: none; max-width: 100%; }
  .brettspiel__panel { width: 100%; flex: none; }
  .musik__pads { gap: 5px; }
}
[data-theme=cvi] .brettspiel__cell { border-color: #fff; }
@media(prefers-reduced-motion:reduce) { .brettspiel *, .musikwerkstatt * { transition:none !important; } }
