@import url("./fonts.css");
@import url("./navigation.css");
/* Die Stadt füllt die Bildschirmhöhe. Zum Erkunden seitlich scrollen. */
* { box-sizing: border-box; }
html, body { width: 100%; height: 100%; margin: 0; overflow: hidden; }
body { background: #88cee6; font-family: "GNF", monospace; }
#city-scroll { width: 100vw; height: 100vh; height: 100dvh; overflow-x: auto; overflow-y: hidden; overscroll-behavior: contain; touch-action: pan-x; scrollbar-width: none; outline: none; }
#city-scroll::-webkit-scrollbar { display: none; }
#city-scroll:focus-visible { outline: 2px dashed #235c80; outline-offset: -5px; }
/* Das Pixelbild liegt unten. Schrift und Bedienelemente liegen darüber. */
#city { display: block; image-rendering: pixelated; image-rendering: crisp-edges; }
#city-stage { position: relative; }
#city-lettering { position: absolute; top: 0; left: 0; pointer-events: none; overflow: hidden; font-family: "GNF", monospace; font-weight: 400; font-kerning: none; text-rendering: geometricPrecision; }
/* Unsichtbare Flächen machen Stockwerke und Schilder anklickbar und mit der Tastatur auswählbar. */
#project-links { position: absolute; inset: 0; pointer-events: none; }
.chapter-link, .company-link, #garage-trigger { position: absolute; display: block; border: 0; background: transparent; -webkit-tap-highlight-color: transparent; }
.chapter-link, .company-link { pointer-events: auto; cursor: pointer; outline: none; }
.chapter-link:hover, .chapter-link:focus-visible, .company-link:hover, .company-link:focus-visible { box-shadow: inset 0 0 0 var(--pixel-size, 3px) #fff0b9; }
#garage-trigger { outline: none; padding: 0; cursor: pointer; font-family: "GNF", monospace; }
#garage-trigger:focus-visible { outline: 2px dashed #fff0b9; outline-offset: 3px; }
#raccoon-trigger { position: absolute; z-index: 1; border: 0; padding: 0; background: transparent; cursor: pointer; -webkit-tap-highlight-color: transparent; }
#raccoon-trigger:focus-visible { outline: 2px dashed #253b32; outline-offset: 3px; }
#raccoon-speech { position: absolute; z-index: 3; width: max-content; max-width: min(320px, calc(100vw - 32px)); margin: 0; padding: 14px 17px; transform: translate(-50%, -100%); border: 3px solid #253b32; box-shadow: 4px 4px #202a30; background: #f2e5b9; color: #253b32; font-size: clamp(14px, 1.6vw, 18px); line-height: 1.5; text-align: center; }
#raccoon-speech::after { content: ""; position: absolute; top: 100%; left: 50%; width: 13px; height: 13px; border-right: 3px solid #253b32; border-bottom: 3px solid #253b32; background: #f2e5b9; transform: translate(-50%, -5px) rotate(45deg); }
#raccoon-store { color: inherit; text-underline-offset: 4px; }
#raccoon-store:focus-visible { outline: 2px dashed currentColor; outline-offset: 4px; }
.garage-invitation { position: absolute; left: calc(4 * var(--pixel-size)); top: calc(4 * var(--pixel-size)); width: calc(81 * var(--pixel-size)); height: calc(40 * var(--pixel-size)); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: calc(4 * var(--pixel-size)); color: #f5e6b8; font-size: calc(10.24 * var(--pixel-size)); line-height: 1; white-space: nowrap; clip-path: inset(var(--shutter-coverage, 100%) 0 0); pointer-events: none; }
.pixel-eye { display: block; width: calc(21 * var(--pixel-size)); height: calc(11 * var(--pixel-size)); }
/* Links und Hinweise bleiben beim Scrollen an derselben Stelle. */
.exit, .page-title { position: fixed; z-index: 2; color: #235c80; text-shadow: 2px 3px 0 #d8e8e7; }
.exit { top: clamp(19px, 3.1vh, 37px); left: clamp(19px, 3.4vw, 53px); text-decoration: underline; text-underline-offset: 4px; }
.exit:focus-visible { outline: 2px dashed #235c80; outline-offset: 5px; }
.page-title { top: clamp(19px, 3.1vh, 37px); left: 50%; transform: translateX(-50%); margin: 0; font-size: clamp(27px, 3vw, 43px); line-height: 1; font-weight: 700; white-space: nowrap; pointer-events: none; }
.explore-note { position: fixed; z-index: 2; top: clamp(88px, 14vh, 145px); left: 50%; transform: translateX(-50%); margin: 0; color: #23678a; font: 400 12px/1.4 "GNF", monospace; letter-spacing: 2px; white-space: nowrap; text-shadow: 2px 2px #c6edf0; pointer-events: none; }
.scroll-hint { position: fixed; bottom: 15px; left: 50%; transform: translateX(-50%); margin: 0; color: #e5e4cd; font-size: 11px; font-weight: 700; letter-spacing: 1px; white-space: nowrap; pointer-events: none; }
.scroll-hint[hidden] { display: none; }
.scroll-hint span { margin-left: 7px; }
/* Die Bildbeschreibung bleibt für Vorleseprogramme zugänglich, ist aber nicht sichtbar. */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
/* Größe von Titel und Hinweis auf dem Handy. */
@media (max-width: 600px) { .page-title { font-size: 27px; } .explore-note { font-size: 10px; letter-spacing: 1px; } }

/* Die Fotos bilden einen geschlossenen Kreis. Das vordere Bild wird groß angezeigt. */
#immo-gallery { position: fixed; inset: 0; width: 100%; max-width: none; height: 100%; height: 100dvh; max-height: none; margin: 0; padding: 0; border: 0; overflow: hidden; background: transparent; color: #f5e6b8; font-family: "GNF", monospace; }
#immo-gallery::backdrop { background: rgb(10 24 31 / 64%); backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px); }
.gallery-shell { width: 100%; height: 100%; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; padding: clamp(18px, 3.5vh, 40px) 0 max(22px, env(safe-area-inset-bottom)); animation: gallery-appear 220ms ease-out; }
.gallery-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 0 clamp(20px, 5vw, 80px); }
.gallery-header h2 { margin: 0; font-size: clamp(15px, 2vw, 23px); font-weight: 400; line-height: 1.5; text-shadow: 2px 2px #183542; }
.gallery-orbit { position: relative; min-height: 0; container-type: size; isolation: isolate; perspective: 1400px; cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none; }
.gallery-orbit.is-dragging { cursor: grabbing; }
.gallery-photo { position: absolute; top: 50%; left: 50%; width: min(76vw, 1180px); width: min(76vw, 1180px, calc((100cqh - 40px) * var(--photo-ratio, 1.5))); aspect-ratio: var(--photo-ratio, 1.5); margin: 0; padding: 4px; background: #e9dcb9; box-shadow: 0 0 0 2px #355565, 6px 6px 0 2px rgb(7 20 28 / 55%); will-change: transform; pointer-events: none; transform-origin: center; }
.gallery-photo img { display: block; width: 100%; height: 100%; object-fit: contain; background: #10232b; pointer-events: none; }
.gallery-footer { position: relative; z-index: 20; display: grid; justify-items: center; gap: 18px; padding-top: 4px; }
.gallery-controls { display: flex; align-items: center; gap: clamp(24px, 4vw, 60px); }
.pixel-button { display: grid; place-items: center; flex: 0 0 auto; width: 48px; height: 44px; border: 0; border-radius: 0; padding: 13px; color: #f5e6b8; background: #274958; box-shadow: 0 -3px #72949a, 3px 0 #72949a, 0 3px #132d3b, -3px 0 #72949a, 3px 6px 0 #10232b; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.pixel-button svg { display: block; width: 100%; height: 100%; fill: currentColor; shape-rendering: crispEdges; }
.pixel-button:hover { color: #fff7dc; background: #3d6470; }
.pixel-button:active { transform: translateY(3px); box-shadow: 0 -3px #72949a, 3px 0 #72949a, 0 3px #132d3b, -3px 0 #72949a; }
.pixel-button:focus-visible { outline: 2px dashed #f5e6b8; outline-offset: 8px; }
.gallery-close { width: 38px; height: 36px; padding: 11px; }
.gallery-count { min-width: 92px; margin: 0; text-align: center; font-size: 16px; font-variant-numeric: tabular-nums; }
#gallery-help { margin: 0; color: #c0d0cb; font-size: 10px; line-height: 1.6; letter-spacing: 1px; text-align: center; }
@keyframes gallery-appear { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@media (max-width: 600px) {
  .gallery-photo { width: 84vw; width: min(84vw, calc((100cqh - 40px) * var(--photo-ratio, 1.5))); padding: 3px; }
  .gallery-header h2 { max-width: 220px; font-size: 14px; }
  .gallery-footer { gap: 17px; }
  #gallery-help { font-size: 9px; letter-spacing: 0; }
}
@media (prefers-reduced-motion: reduce) { .gallery-shell { animation: none; } }
