/* FCS 2.0 – das Original im Browser (Entwurf vom 2026-11-25).
   Der Bildschirm selbst ist das Programm: 640 × 350 Punkte EGA, auf 4:3 gestreckt wie auf dem Monitor, ohne Glättung.
   Nur der Rahmen drumherum ist von heute; Farben der Tasten aus FCS selbst (Palette #0055AA usw., siehe documentation/fcs/). */

@font-face { font-family: "Nunito"; src: url("../../assets/schrift/nunito-latin.woff2") format("woff2"); font-weight: 300 700; font-display: swap; }

:root {
  --fcs-blau: #0055aa; --gruen: #55ff55; --rot: #ff5555; --gelb: #ffff55; --magenta: #ff55ff; --grau: #aaaaaa; --hell: #fff;
  --mono: ui-monospace, Consolas, "Lucida Console", Menlo, "DejaVu Sans Mono", monospace;
  color-scheme: dark;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; background: #0b0b0d; color: #d9d4c7; }
body { font: 15px/1.45 Nunito, system-ui, sans-serif; min-height: 100vh; }

.leiste { display: flex; align-items: center; gap: 1rem; padding: .45rem 1rem; background: #17171b; border-bottom: 1px solid #2a2a30; min-height: 2.6rem; }
.leiste a { color: #e9d9a8; text-decoration: none; white-space: nowrap; }
.leiste a:hover, .leiste a:focus-visible { text-decoration: underline; }
.leiste p { margin: 0; flex: 1; text-align: center; color: #a9a397; font-size: .9rem; }
@media (max-width: 640px) { .leiste p span { display: none; } }
html.eingebettet .leiste { display: none; }

.programm { max-width: 1040px; margin: 0 auto; padding: clamp(8px, 1.6vw, 20px); }
.ohne-skript { text-align: center; }
.ohne-skript img { max-width: 100%; height: auto; }

/* ---------- Monitor ---------- */
.monitor { margin: 0; }
.schirm { position: relative; width: 100%; max-width: calc((100vh - 10rem) * 4 / 3); min-width: 0; margin: 0 auto; aspect-ratio: 4 / 3; background: #000; border: 10px solid #26262b; border-radius: 6px; box-shadow: 0 0 0 1px #3a3a42, 0 12px 40px rgba(0,0,0,.6); overflow: hidden; }
@media (max-width: 640px) { .schirm { border-width: 4px; max-width: none; } }
/* js-dos legt ein div.dosbox-container um das Canvas */
.schirm .dosbox-container, .schirm canvas { position: absolute; inset: 0; width: 100% !important; height: 100% !important; }
.schirm canvas { display: block; image-rendering: pixelated; image-rendering: crisp-edges; outline: none; }
.dosbox-powered, .dosbox-overlay, .dosbox-loader { display: none !important; }

.vorhang { position: absolute; inset: 0; display: grid; place-items: center; align-content: center; gap: .8rem; background: #000; z-index: 2; }
.vorhang img { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .45; image-rendering: pixelated; }
.vorhang .an, .vorhang p { position: relative; }
.vorhang p { margin: 0; padding: .2rem .6rem; background: #000c; color: var(--grau); font: .9rem var(--mono); text-align: center; }
.an { font: 700 1.1rem var(--mono); letter-spacing: .08em; color: #000; background: var(--gelb); border: 0; border-bottom: 4px solid #aa5500; padding: .7rem 1.6rem; cursor: pointer; }
.an:hover { background: var(--hell); }
.an:focus-visible { outline: 3px dotted var(--hell); outline-offset: 4px; }
.an:disabled { opacity: .6; cursor: progress; }

.monitor figcaption { margin: .6rem auto 0; max-width: 46rem; text-align: center; color: #a9a397; font-size: .88rem; }

/* ---------- Tasten für Touch-Geräte ---------- */
.tasten { margin: .9rem auto 0; max-width: 820px; display: grid; gap: .4rem; font-family: var(--mono); }
.tasten__reihe { display: flex; flex-wrap: wrap; gap: .3rem; justify-content: center; }
.tasten button { font: 700 .9rem var(--mono); min-width: 2.7rem; min-height: 2.5rem; padding: .2rem .5rem; color: #000; background: var(--grau); border: 0; border-bottom: 3px solid #555; border-radius: 0; cursor: pointer; touch-action: manipulation; user-select: none; -webkit-user-select: none; }
.tasten button:active { transform: translateY(2px); border-bottom-width: 1px; }
.tasten button:focus-visible, .tippen input:focus-visible { outline: 2px dotted var(--hell); outline-offset: 2px; }
.tasten__f button:nth-child(1) { background: var(--gruen); }
.tasten__f button:nth-child(2) { background: var(--rot); }
.tasten__f button:nth-child(3) { background: var(--gelb); }
.tasten__f button:nth-child(n+4):nth-child(-n+8) { background: var(--magenta); }
.tasten__f button:nth-child(n+9) { background: var(--hell); color: var(--fcs-blau); }
.tasten__enter { min-width: 5rem !important; background: var(--hell) !important; color: var(--fcs-blau) !important; }
.tippen { display: inline-flex; align-items: center; gap: .35rem; color: var(--grau); font-size: .85rem; }
.tippen input { width: 5.5rem; min-height: 2.5rem; font: 1rem var(--mono); color: var(--hell); background: #000; border: 1px solid var(--grau); border-radius: 0; padding: .2rem .4rem; }
@media (max-width: 560px) {
  .tasten__f { display: grid; grid-template-columns: repeat(10, 1fr); }
  .tasten__f button { min-width: 0; padding: .2rem 0; font-size: .78rem; }
}
@media (hover: hover) and (pointer: fine) { .tasten { opacity: .75; } .tasten:hover, .tasten:focus-within { opacity: 1; } }

/* ---------- Erklärung ---------- */
.merk { max-width: 46rem; margin: 1.4rem auto 2rem; display: grid; gap: .6rem; }
.merk details { border: 1px solid #2a2a30; background: #121216; padding: .2rem .9rem; }
.merk summary { cursor: pointer; padding: .4rem 0; color: #e9d9a8; font-weight: 700; }
.merk p, .merk li { color: #cfc9bb; }
.merk ol { padding-left: 1.3rem; }
.merk li { margin: .25rem 0; }
.merk a { color: #e9d9a8; }
kbd { font: .85em var(--mono); padding: .05em .35em; color: #000; background: var(--grau); border-bottom: 2px solid #555; white-space: nowrap; }
