/* Erdforscher – Gestaltung. Fuer ein iPad im Querformat gebaut, im Hochformat nutzbar.
   Grundregel: Alles, was ein Finger treffen soll, ist mindestens 56 px gross. */

:root {
  --nacht: #0a0f2c;
  --papier: #fff8e8;
  --tinte: #26233a;
  --orange: #ff8a3d;
  --gelb: #ffd23f;
  --gruen: #2fc77a;
  --gruen-dunkel: #1f9d5c;
  --rot: #ff5d6c;
  --blau: #3a7bff;
  --schatten: 0 6px 18px rgba(0, 0, 0, .35);
  --rund: ui-rounded, "SF Pro Rounded", "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  margin: 0; height: 100%; overflow: hidden; overscroll-behavior: none;
  background: var(--nacht); color: var(--tinte);
  font-family: var(--rund); font-size: 20px;
  -webkit-user-select: none; user-select: none; -webkit-touch-callout: none;
}
button { font-family: inherit; touch-action: manipulation; cursor: pointer; }
[hidden] { display: none !important; }

/* Karte: ganze Seite, Sternenhimmel dahinter (die Satellitenkugel ist rund). */
#karte {
  position: fixed; inset: 0;
  background:
    radial-gradient(1.5px 1.5px at 12% 18%, #fff, transparent),
    radial-gradient(1px 1px at 28% 72%, #fff, transparent),
    radial-gradient(1.5px 1.5px at 44% 33%, #fff9, transparent),
    radial-gradient(1px 1px at 63% 12%, #fff, transparent),
    radial-gradient(2px 2px at 78% 58%, #fff8, transparent),
    radial-gradient(1px 1px at 90% 85%, #fff, transparent),
    radial-gradient(1px 1px at 8% 90%, #fff9, transparent),
    radial-gradient(1.5px 1.5px at 55% 90%, #fff, transparent),
    radial-gradient(ellipse at center, #14204f 0%, var(--nacht) 70%);
}
#schild { position: fixed; inset: 0; pointer-events: none; z-index: 5; }
#schild.aktiv { pointer-events: auto; }
.maplibregl-ctrl-attrib { font-size: 11px; opacity: .85; }

/* ── Knöpfe ── */
.rund {
  width: 60px; height: 60px; border-radius: 50%; border: 0; flex: none;
  background: var(--papier); color: var(--tinte); font-size: 28px; line-height: 1;
  box-shadow: var(--schatten); display: grid; place-items: center;
}
.rund:active { transform: scale(.92); }
.rund.klein { width: 52px; height: 52px; font-size: 24px; }
.rund.gross { width: 68px; height: 68px; font-size: 32px; font-weight: 700; }
.rund.hilfe { background: var(--gelb); }
/* Eingeschalteter Schalter (z. B. Ländernamen): gelb mit hellem Ring, sonst nicht vom Aus zu unterscheiden. */
.rund.an { background: var(--gelb); box-shadow: 0 0 0 4px #fff8, var(--schatten); }
.rund.hilfe.puls { animation: hilfepuls 1s ease-in-out infinite; }
@keyframes hilfepuls {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255, 210, 63, .9), var(--schatten); }
  50% { box-shadow: 0 0 0 16px rgba(255, 210, 63, 0), var(--schatten); }
}

/* Passbüchlein-Symbol: im Text so groß wie die Schrift, auf dem runden Kopfzeilen-Knopf größer. */
.pass-icon { width: 1.25em; height: 1.25em; vertical-align: -0.28em; }
.pass-icon.gross { width: 40px; height: 40px; vertical-align: middle; }

.knopf {
  border: 0; border-radius: 22px; padding: 14px 22px; font-size: 22px; font-weight: 800;
  background: var(--orange); color: #fff; box-shadow: 0 5px 0 #c9631f, var(--schatten);
}
.knopf:active { transform: translateY(3px); box-shadow: 0 2px 0 #c9631f; }
.knopf.zweit { background: var(--blau); box-shadow: 0 5px 0 #2557b8, var(--schatten); }
.knopf.gross-knopf { font-size: 28px; padding: 18px 30px; background: var(--gruen); box-shadow: 0 6px 0 var(--gruen-dunkel), var(--schatten); }
.knopf.klein-knopf { font-size: 16px; padding: 10px 16px; background: #26233a14; box-shadow: none; color: var(--tinte); }

/* ── Kopfzeile ── */
#hud-oben {
  position: fixed; z-index: 10; left: 12px; right: 12px;
  top: max(12px, env(safe-area-inset-top));
  display: flex; justify-content: space-between; align-items: flex-start; gap: 12px;
  pointer-events: none;
}
#hud-oben > * { pointer-events: auto; }
body[data-modus="start"] #hud-oben, body[data-modus="start"] #hud-zoom,
body[data-modus="weltraum"] #hud-oben, body[data-modus="weltraum"] #hud-zoom { display: none; }
body[data-modus="weltraum"] #karte { visibility: hidden; }

#auftrag {
  display: flex; align-items: center; gap: 12px; padding: 8px 14px 8px 10px; min-width: 0;
  background: var(--papier); border-radius: 34px; box-shadow: var(--schatten);
  max-width: min(760px, calc(100vw - 260px));
}
.maskott {
  width: 48px; height: 48px; flex: none; border-radius: 50%; display: grid; place-items: center;
  background: #ffe9b8; font-size: 30px;
}
.auftrag-text { min-width: 0; }
#auftrag-klein { font-size: 13px; font-weight: 700; color: #8a7f9f; text-transform: uppercase; letter-spacing: .06em; }
#auftrag-titel { font-size: 26px; font-weight: 900; line-height: 1.1; overflow-wrap: anywhere; }
#auftrag-flagge { height: 38px; width: auto; border-radius: 6px; box-shadow: 0 1px 4px #0005; flex: none; }
#btn-hilfe { display: none; }
body[data-phase="finden"] #btn-hilfe, body[data-phase="zoomen"] #btn-hilfe { display: grid; }
body[data-modus="entdecken"] #btn-vorlesen, body[data-modus="entdecken"] #btn-hilfe { display: none; }

#oben-rechts { display: flex; gap: 10px; align-items: center; }
#punkte {
  display: flex; gap: 10px; background: var(--papier); border-radius: 30px; padding: 10px 16px;
  font-weight: 900; font-size: 20px; box-shadow: var(--schatten); white-space: nowrap;
}

/* ── Pico ── */
#pico {
  position: fixed; z-index: 9; left: 50%; top: calc(max(12px, env(safe-area-inset-top)) + 84px);
  transform: translate(-50%, -20px); opacity: 0; pointer-events: none;
  display: flex; align-items: center; gap: 12px; padding: 10px 20px 10px 10px;
  max-width: min(780px, calc(100vw - 32px)); background: #fff; border-radius: 32px;
  box-shadow: var(--schatten); font-size: 22px; font-weight: 700; line-height: 1.25;
  transition: opacity .25s, transform .25s;
}
#pico.sichtbar { opacity: 1; transform: translate(-50%, 0); }

/* ── Zoom ── */
#hud-zoom {
  position: fixed; z-index: 10; right: 12px; top: 50%; transform: translateY(-50%);
  display: flex; flex-direction: column; gap: 12px;
}

/* Mit dem Rätselblatt unten rücken die Zoom-Knöpfe nach oben, damit nichts verdeckt wird. */
body[data-phase="raetsel"] #hud-zoom { top: 30%; }

/* ── Ankunft ── */
#ankunft {
  position: fixed; z-index: 12; left: 50%; top: 34%; transform: translate(-50%, -50%);
  text-align: center; padding: 22px 38px; border-radius: 34px; background: var(--papier);
  box-shadow: var(--schatten); animation: hereinspringen .5s cubic-bezier(.2, 1.4, .4, 1);
  pointer-events: none;
}
.ankunft-ort { font-size: 42px; font-weight: 900; }
.ankunft-sub { font-size: 22px; font-weight: 700; color: #6b6285; }
@keyframes hereinspringen { from { transform: translate(-50%, -50%) scale(.4); opacity: 0; } }

/* ── Karten-Markierungen ── */
.stern { position: relative; width: 64px; height: 64px; cursor: pointer; }
.stern .symbol { position: absolute; inset: 0; display: grid; place-items: center; font-size: 40px; filter: drop-shadow(0 2px 4px #0008); }
.stern i, .ring i {
  position: absolute; inset: 0; border-radius: 50%; border: 4px solid var(--gelb);
  animation: puls 1.6s ease-out infinite;
}
.stern i:nth-child(2) { animation-delay: .8s; }
.ring { width: 220px; height: 220px; pointer-events: none; }
.ring i { border-color: #fff; border-width: 6px; }
.ring i:nth-child(2) { animation-delay: .8s; }
@keyframes puls { from { transform: scale(.4); opacity: 1; } to { transform: scale(1.5); opacity: 0; } }

/* ── Blatt unten (Rätsel) ── */
.blatt {
  position: fixed; z-index: 11; left: 12px; right: 12px; bottom: max(12px, env(safe-area-inset-bottom));
  max-height: 58vh; overflow: auto; padding: 18px 22px 22px;
  background: var(--papier); border-radius: 30px; box-shadow: 0 -4px 30px rgba(0, 0, 0, .45);
  animation: hochfahren .45s cubic-bezier(.2, 1, .3, 1);
}
@keyframes hochfahren { from { transform: translateY(110%); } }
.blatt header { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.plakette { background: var(--blau); color: #fff; font-weight: 900; padding: 8px 18px; border-radius: 24px; font-size: 20px; }
#r-zaehler { margin-left: auto; font-weight: 800; color: #8a7f9f; }
#r-frage { margin: 6px 0 16px; font-size: 27px; font-weight: 700; line-height: 1.3; }
#r-antworten { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.antwort {
  min-height: 78px; padding: 12px 14px; border: 0; border-radius: 22px; background: #fff;
  font-size: 25px; font-weight: 800; color: var(--tinte); box-shadow: 0 5px 0 #d8cfb8, 0 3px 10px #0003;
  overflow-wrap: anywhere;
}
.antwort:active { transform: translateY(3px); box-shadow: 0 2px 0 #d8cfb8; }
.antwort.richtig { background: var(--gruen); color: #fff; box-shadow: 0 5px 0 var(--gruen-dunkel); }
.antwort.falsch { background: #ffd9dd; color: #a33b48; box-shadow: none; opacity: .7; animation: wackeln .4s; }
@keyframes wackeln { 25% { transform: translateX(-10px); } 75% { transform: translateX(10px); } }
#r-wissen .richtig { font-size: 30px; font-weight: 900; color: var(--gruen-dunkel); }
#r-wissen-text { font-size: 24px; line-height: 1.35; margin: 8px 0 12px; font-weight: 600; }
#r-neu:not(:empty) {
  display: inline-block; background: #ffe9b8; border-radius: 20px; padding: 8px 16px; margin-bottom: 12px;
  font-weight: 900; font-size: 22px;
}

/* ── Overlays ── */
.overlay {
  position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: 16px;
  background: rgba(10, 15, 44, .55); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
/* Startbildschirm: Der Globus soll daneben zu sehen sein und sich drehen, nicht verschwimmen.
   Querformat: Menü links, Globus rechts. Hochformat: Menü unten, Globus oben. */
#start { background: none; backdrop-filter: none; -webkit-backdrop-filter: none; pointer-events: none; }
#start .karte { pointer-events: auto; }
@media (min-width: 901px) { #start { place-items: center start; padding-left: 4vw; } }
@media (max-width: 900px) { #start { place-items: end center; padding-bottom: max(16px, env(safe-area-inset-bottom)); } }
.karte {
  background: var(--papier); border-radius: 34px; padding: 28px 34px; box-shadow: var(--schatten);
  max-width: 100%; max-height: 100%; overflow: auto; text-align: center;
}
.start-karte { width: min(500px, 100%); background: var(--papier); }
.titel { font-size: 56px; font-weight: 900; letter-spacing: -.02em; }
.globus { display: inline-block; }
.drehen { animation: dreh 3s linear infinite; font-size: 64px; }
@keyframes dreh { to { transform: rotate(360deg); } }
.unter { font-size: 22px; font-weight: 700; margin: 6px 0 18px; color: #5a5273; }
.namefeld { margin: 0 0 16px; }
.namefeld label { display: block; font-weight: 800; margin-bottom: 6px; }
.namefeld input {
  width: 100%; max-width: 340px; font: inherit; font-size: 26px; text-align: center; padding: 10px 14px;
  border-radius: 18px; border: 3px solid #e6dcc2; background: #fff; color: var(--tinte); user-select: text;
}
.knopfreihe { display: flex; flex-direction: column; gap: 14px; align-items: stretch; }
.fuss { display: flex; justify-content: center; gap: 12px; margin-top: 18px; }
.stand { margin-top: 12px; font-size: 13px; font-weight: 700; color: #9b92b3; }
#s-infotext { margin-top: 14px; font-size: 14px; line-height: 1.4; color: #5a5273; text-align: left; user-select: text; }

.breit { width: min(1100px, 100%); height: min(760px, 100%); display: flex; flex-direction: column; text-align: left; }
.pass-kopf { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.reiter { display: flex; gap: 10px; }
.reiter-knopf { border: 0; border-radius: 22px; padding: 12px 22px; font-size: 22px; font-weight: 900; background: #ece3cc; color: var(--tinte); }
.reiter-knopf.aktiv { background: var(--blau); color: #fff; }
#pass-inhalt { flex: 1; overflow: auto; }
.gitter { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; padding: 4px; }
.etappe { grid-column: 1 / -1; font-weight: 900; font-size: 22px; margin-top: 8px; color: #6b6285; }
.kachel {
  position: relative; border: 3px solid #e6dcc2; border-radius: 22px; padding: 12px 8px; background: #fff;
  text-align: center; font-size: 18px; font-weight: 800; color: var(--tinte); min-height: 120px;
}
.kachel img { display: block; margin: 0 auto 8px; height: 52px; width: auto; border-radius: 6px; box-shadow: 0 1px 4px #0004; }
.kachel .fragezeichen { height: 52px; margin-bottom: 8px; display: grid; place-items: center; font-size: 40px; color: #c9bfa5; }
.kachel.gestempelt { border-color: var(--gruen); background: #effbf3; }
.kachel .haken { position: absolute; top: -10px; right: -8px; font-size: 28px; }
.kachel .sterne { font-size: 15px; margin-top: 2px; }
.kachel.tier { min-height: 130px; }
.kachel.tier .gross { font-size: 46px; line-height: 1.1; }
.kachel.gesperrt { opacity: .7; }
#pass-detail { background: #fff; border-radius: 24px; padding: 16px 20px; margin-bottom: 14px; border: 3px solid #e6dcc2; }
#pass-detail h3 { margin: 0 0 6px; font-size: 28px; }
#pass-detail p { margin: 6px 0; font-size: 20px; font-weight: 600; line-height: 1.35; }
#pass-detail .knopf { margin-top: 8px; font-size: 20px; padding: 12px 20px; }

/* overflow-x aus: Der Stempel fliegt vergrößert ein und würde sonst einen Rollbalken erzeugen. */
.stempelkarte { max-width: 560px; overflow-x: hidden; }
.stempel {
  width: 220px; height: 220px; margin: 0 auto 10px; border-radius: 50%; border: 8px double var(--rot); color: var(--rot);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  transform: rotate(-8deg); animation: stempeln .7s cubic-bezier(.2, 1.6, .4, 1) both; background: #fff;
}
.stempel img { height: 74px; width: auto; border-radius: 8px; box-shadow: 0 2px 6px #0005; }
.stempel span { font-weight: 900; font-size: 26px; text-transform: uppercase; letter-spacing: .04em; padding: 0 10px; }
@keyframes stempeln { from { transform: rotate(-8deg) scale(2.6); opacity: 0; } }
.stempelkarte h2 { font-size: 36px; margin: 8px 0; }
#st-text { font-size: 22px; font-weight: 700; margin: 6px 0; }
#st-sterne { font-size: 36px; margin: 4px 0; }
#st-tier:not(:empty) { background: #ffe9b8; border-radius: 20px; padding: 10px 16px; margin: 10px 0 14px; font-size: 22px; font-weight: 900; }

#laden {
  position: fixed; inset: 0; z-index: 50; background: var(--nacht); color: #fff;
  display: flex; flex-direction: column; gap: 14px; align-items: center; justify-content: center;
  font-size: 24px; font-weight: 800; transition: opacity .6s;
}
#laden.weg { opacity: 0; pointer-events: none; }

/* Konfetti */
.konfetti { position: fixed; z-index: 30; top: -40px; font-size: 34px; pointer-events: none; animation: fallen linear forwards; }
@keyframes fallen { to { transform: translateY(110vh) rotate(540deg); opacity: .9; } }

/* Hochformat und kleine Bildschirme */
@media (max-width: 900px) {
  #r-antworten { grid-template-columns: 1fr; }
  #r-frage { font-size: 24px; }
  #auftrag { max-width: calc(100vw - 24px); }
  #oben-rechts { position: fixed; right: 12px; top: calc(max(12px, env(safe-area-inset-top)) + 70px); }
  #pico { top: calc(max(12px, env(safe-area-inset-top)) + 150px); }
  #auftrag-titel { font-size: 22px; }
  .titel { font-size: 44px; }
  .blatt { max-height: 62vh; }
}
@media (max-height: 560px) {
  .blatt { max-height: 66vh; padding: 12px 16px 14px; }
  #r-frage { font-size: 21px; margin-bottom: 10px; }
  .antwort { min-height: 60px; font-size: 21px; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

/* Die Entdeckerpause lässt die Karte frei und hält den nächsten Schritt erreichbar. */
.umsehen {
  position: fixed; z-index: 11; left: 50%; bottom: max(24px, env(safe-area-inset-bottom));
  transform: translateX(-50%); width: max-content; max-width: calc(100vw - 32px);
  padding: 14px 22px 20px; border-radius: 28px; background: var(--papier); box-shadow: var(--schatten);
  text-align: center;
}
.umsehen p { margin: 0 0 12px; font-size: 22px; font-weight: 700; }
.u-knopfreihe { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }
#r-hinweis { background: #ffe9b8; padding: 12px 16px; border-radius: 18px; font-size: 22px; }
#pass { z-index: 25; }
.knopf.klein-knopf, .reiter-knopf { min-height: 56px; }
body[data-phase="raetsel"] #btn-hilfe { display: none; }
@media (max-width: 600px) {
  #auftrag .maskott, #auftrag-flagge { display: none; }
  #auftrag { gap: 8px; padding-right: 8px; }
  #auftrag .rund { width: 52px; height: 52px; }
  .blatt header { flex-wrap: wrap; }
  #r-zaehler { font-size: 16px; }
  .ankunft-ort { font-size: 30px; }
  #ankunft { width: calc(100vw - 32px); padding: 18px; }
}
/* EOX verlangt sichtbare verlinkte Bildcredits. Das Rätselblatt darf sie nicht verdecken. */
.maplibregl-ctrl-attrib { max-width: min(380px, calc(100vw - 32px)); opacity: 1; line-height: 1.3; }
body[data-phase="raetsel"] .maplibregl-ctrl-bottom-left { bottom: auto; top: 166px; }
body[data-phase="umsehen"] .maplibregl-ctrl-attrib { max-width: 240px; }
@media (max-width: 900px) {
  body[data-phase="raetsel"] .maplibregl-ctrl-bottom-left { top: 224px; }
}
#eltern { margin-top: 12px; font-size: 16px; text-align: left; }
#eltern summary { min-height: 56px; padding: 16px 8px; cursor: pointer; font-weight: 700; }
#eltern .knopf { margin: 8px 4px 8px 0; }
#eltern input { max-width: 100%; min-height: 56px; font: inherit; user-select: text; }
.datei-label { display: block; margin: 10px 0 6px; font-weight: 700; }
/* Das Startmenü liegt links bzw. im Hochformat unten; die Bildcredits bleiben daneben sichtbar. */
body[data-modus="start"] .maplibregl-ctrl-bottom-left { left: auto; right: 0; }
@media (max-width: 900px) {
  body[data-modus="start"] .maplibregl-ctrl-bottom-left { bottom: auto; top: max(8px, env(safe-area-inset-top)); }
}
/* ───────────────────────────── Weltraum-Modus ───────────────────────────── */
.knopf.weltraum { background: linear-gradient(135deg, #6a4cff, #b04dff); box-shadow: 0 5px 0 #4a31b8, var(--schatten); }
/* Nur die 3D-Fläche füllt das Fenster; der gleichnamige Menüknopf muss im Menü bleiben. */
#wr { position: fixed; inset: 0; z-index: 7; background: #02030a; touch-action: none; }
#wr-leinwand { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; }
#wr-kopf {
  position: absolute; left: 12px; right: 12px; top: max(12px, env(safe-area-inset-top));
  display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; pointer-events: none;
}
#wr-kopf > * { pointer-events: auto; }
.wr-titel {
  display: flex; align-items: center; gap: 12px; padding: 8px 22px 8px 10px;
  background: var(--papier); border-radius: 34px; box-shadow: var(--schatten);
}
.wr-klein { font-size: 13px; font-weight: 700; color: #8a7f9f; text-transform: uppercase; letter-spacing: .06em; }
.wr-gross { font-size: 26px; font-weight: 900; line-height: 1.1; }
.wr-rechts { display: flex; align-items: center; gap: 10px; }
#wr-zaehler { background: var(--papier); border-radius: 30px; padding: 12px 18px; font-weight: 900; font-size: 20px; box-shadow: var(--schatten); }
#wr-zoom { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; gap: 12px; }
#wr-laden {
  position: absolute; left: 50%; top: 45%; transform: translate(-50%, -50%); color: #fff; font-size: 24px; font-weight: 800;
  background: #0b1030cc; padding: 16px 28px; border-radius: 28px;
}

/* Steckbrief rechts (im Hochformat über der Zielleiste). Zuklappen gibt den freien Blick auf den Himmelskörper. */
#wr-karte {
  position: absolute; right: 12px; width: min(420px, 44vw); overflow: auto; text-align: left;
  top: calc(max(12px, env(safe-area-inset-top)) + 82px); bottom: 136px;
  background: var(--papier); border-radius: 28px; padding: 16px 20px 18px; box-shadow: var(--schatten);
  animation: einblenden .35s ease-out;
}
@keyframes einblenden { from { opacity: 0; transform: translateY(14px); } }
#wr-karte header { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
#wr-karte h2 { margin: 0; font-size: 32px; }
#wr-karte header .rund { margin-left: auto; }
#wr-karte.zu { bottom: auto; }
#wr-karte.zu > :not(header) { display: none; }
.wr-steck { margin: 12px 0 6px; }
.wr-steck div { display: flex; gap: 12px; padding: 6px 0; border-bottom: 1px dashed #e3d9c0; font-size: 18px; line-height: 1.3; }
.wr-steck dt { flex: 0 0 38%; font-weight: 800; color: #6b6285; }
.wr-steck dd { margin: 0; font-weight: 600; }
.wr-fakten { list-style: none; padding: 0; margin: 10px 0; }
.wr-fakten li { font-size: 20px; font-weight: 600; line-height: 1.35; margin: 10px 0; }
.wr-knoepfe { display: flex; gap: 10px; flex-wrap: wrap; margin: 12px 0 6px; }
.wr-knoepfe .knopf { font-size: 20px; padding: 12px 18px; }
.wr-hinweis { margin: 12px 0 0; font-size: 14px; line-height: 1.35; color: #8a7f9f; }
.wr-frage { font-size: 24px; font-weight: 700; line-height: 1.3; margin: 12px 0; }
.wr-antworten { display: grid; gap: 10px; margin-bottom: 12px; }
.wr-meldung { font-size: 20px; font-weight: 600; line-height: 1.35; margin: 10px 0; }

/* Zielleiste unten: Sonne bis Neptun, seitlich wischbar. */
#wr-leiste {
  position: absolute; left: 12px; right: 12px; bottom: max(12px, env(safe-area-inset-bottom));
  display: flex; gap: 6px; padding: 8px; overflow-x: auto; touch-action: pan-x;
  background: rgba(11, 16, 48, .82); border-radius: 30px; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
#wr-leiste::-webkit-scrollbar { display: none; }
.wr-knopf {
  position: relative; flex: 0 0 auto; width: 96px; padding: 8px 4px 6px; border: 0; border-radius: 22px;
  background: transparent; color: #fff; font-size: 17px; font-weight: 800; touch-action: manipulation;
  display: flex; flex-direction: column; align-items: center; gap: 5px;
}
.wr-knopf.aktiv { background: rgba(255, 255, 255, .16); box-shadow: inset 0 0 0 3px var(--gelb); }
.wr-kugel { width: 46px; height: 46px; border-radius: 50%; box-shadow: inset -7px -7px 12px rgba(0, 0, 0, .4), 0 0 12px rgba(0, 0, 0, .5); }
.wr-haken { display: none; position: absolute; top: 2px; right: 12px; font-size: 18px; }
.wr-knopf.fertig .wr-haken { display: block; }

@media (max-width: 900px) {
  #wr-karte { left: 12px; right: 12px; width: auto; top: auto; bottom: 136px; max-height: 42vh; }
  #wr-karte.zu { max-height: none; }
  .wr-gross { font-size: 22px; }
}

/* Im Weltraum liegt Pico links oben neben dem Steckbrief, nicht in der Mitte über dessen Titel. */
@media (min-width: 901px) {
  body[data-modus="weltraum"] #pico { left: 12px; transform: translate(0, -20px); max-width: calc(100vw - 500px); }
  body[data-modus="weltraum"] #pico.sichtbar { transform: translate(0, 0); }
}
@media (max-width: 900px) {
  /* Hochformat: Zoom-Tasten rechts oben, damit der Steckbrief sie nicht verdeckt. */
  #wr-zoom { left: auto; right: 12px; top: calc(max(12px, env(safe-area-inset-top)) + 80px); transform: none; }
  #wr-karte { max-height: 38vh; }
}
