/* =====================================================================
   EasySatBox · globus-motor.css · v1.0.0 · 17.11.2026
   Utseendet til det motoren selv eier: kloden og lagene, søkefeltet,
   bunnlinja med knappene, nærkartet, 3D-rammen, meldinger og merket som dras.
   Reglene er hentet uendret fra Globusen (index.html), i samme rekkefølge.
   Globusen har foreløpig de samme reglene i sin egen stil, så utseendet der
   er garantert urørt. Nye produkter lenker til denne fila og legger sine
   egne paneler oppå. Nederst: tilpasninger for skallet GlobusMotor.start() lager.
   ===================================================================== */
:root { /* Nattblå scene rundt en lysende klode. Kloden fyller scenen; meny, søk, lag og kort ligger som glassflater rundt den. */ --night: #030918; --glass: rgba(7, 20, 52, .88); --edge: rgba(92, 156, 255, .42); --ink: #f3f7ff; --ink-soft: #a9bde0; --blue: #2f8cff; --gold: #f6b93b; --display: "Bricolage Grotesque", "Arial Narrow", "Helvetica Neue", Arial, sans-serif; --body: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; color-scheme: dark; }
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body { background: var(--night); color: var(--ink); font-family: var(--body); font-size: 15px; line-height: 1.4; -webkit-font-smoothing: antialiased; overflow: hidden; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid #9cc6ff; outline-offset: 2px; }
[hidden] { display: none !important; }
.app { position: relative; height: 100%; min-height: 430px; overflow: hidden; background: radial-gradient(120% 95% at 50% 46%, #0b2358 0%, #071640 42%, var(--night) 100%); }
.layer { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
#fx { touch-action: none; cursor: grab; -webkit-user-select: none; user-select: none; -webkit-tap-highlight-color: transparent; }
#fx.dragging { cursor: grabbing; }
#fx.pointing { cursor: pointer; }
#fx:focus-visible { outline-offset: -3px; }
.panel { background: var(--glass); border: 1px solid var(--edge); border-radius: 14px; box-shadow: 0 10px 34px rgba(0, 8, 36, .55), inset 0 1px 0 rgba(255, 255, 255, .07); }
.top { position: absolute; left: 0; right: 0; top: 0; z-index: 5; display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 14px 16px; pointer-events: none; }
.top > * { pointer-events: auto; }
.search { position: relative; width: min(310px, 44vw); }
.search svg { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); color: var(--ink-soft); pointer-events: none; }
.search input { width: 100%; height: 44px; padding: 0 14px 0 42px; border-radius: 999px; background: var(--glass); border: 1px solid var(--edge); outline-offset: 2px; box-shadow: 0 6px 22px rgba(0, 8, 36, .5); }
.search input::placeholder { color: var(--ink-soft); }
.results { position: absolute; right: 0; left: 0; top: 50px; margin: 0; padding: 6px; list-style: none; max-height: min(60vh, 380px); overflow-y: auto; }
.res { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 10px; align-items: center; width: 100%; text-align: left; padding: 8px; border: 0; border-radius: 9px; background: none; }
.res:hover, .res:focus-visible { background: rgba(60, 130, 255, .22); }
.res-title { display: block; font-weight: 600; }
.res-place { display: block; font-size: 13px; color: var(--ink-soft); }
.res-none { padding: 10px; color: var(--ink-soft); }
.dot { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; flex: none; background: var(--c, #fff); color: #06122e; box-shadow: 0 0 0 2px rgba(255, 255, 255, .85); }
.open { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 14px; border-radius: 999px; background: linear-gradient(180deg, #2a78ee, #1247b4); border: 1px solid #8fc0ff; color: #fff; font-weight: 600; text-decoration: none; white-space: nowrap; }
.bar { position: absolute; left: 0; right: 0; bottom: 0; z-index: 4; height: 72px; padding: 0 16px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; border-top: 1px solid rgba(92, 156, 255, .2); background: linear-gradient(180deg, rgba(3, 9, 24, 0), rgba(3, 9, 24, .78)); }
.bar-left { display: flex; align-items: center; gap: 12px; min-width: 0; }
.bar-mid { display: flex; align-items: center; gap: 12px; }
.bar-right { display: flex; align-items: center; gap: 12px; justify-content: flex-end; }
.round { width: 46px; height: 46px; border-radius: 50%; flex: none; display: grid; place-items: center; padding: 0; background: var(--glass); border: 1px solid var(--edge); }
.round.big { width: 56px; height: 56px; border-color: #8fc0ff; box-shadow: 0 0 16px rgba(47, 140, 255, .5); }
.round:hover, .zoom button:hover { border-color: #b9d8ff; background: rgba(22, 60, 140, .9); }
#home { color: #ff5a5a; }
.readout { min-width: 0; }
.readout output { display: block; font-family: var(--mono); font-weight: 500; font-size: 14.5px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.readout span { display: block; font-size: 13.5px; color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.zoom { display: flex; border-radius: 999px; overflow: hidden; border: 1px solid var(--edge); background: var(--glass); }
.zoom button { width: 52px; height: 44px; display: grid; place-items: center; padding: 0; background: none; border: 0; }
.zoom button + button { border-left: 1px solid rgba(92, 156, 255, .3); }
.is-mobile .top { padding: 9px 12px; align-items: center; }
.is-mobile .search { width: 138px; flex: none; }
.is-mobile .search input { height: 40px; padding-left: 38px; }
.is-mobile .search:focus-within { position: absolute; left: 12px; right: 12px; top: 8px; width: auto; z-index: 6; }
.is-mobile .open { height: 34px; padding: 0 12px; font-size: 14px; }
.is-mobile .bar { height: 58px; padding: 0 12px; gap: 8px; grid-template-columns: minmax(0, 1fr) auto auto; }
.is-mobile .round { width: 40px; height: 40px; }
.is-mobile .round.big { width: 44px; height: 44px; }
.is-mobile #rot-l, .is-mobile #rot-r, .is-mobile #fs { display: none; }
.is-mobile .zoom button { width: 44px; height: 40px; }
.is-mobile .readout output { font-size: 12.5px; }
.is-mobile .readout span { font-size: 12px; }
.is-mobile .bar-left { gap: 8px; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
#stars, #gl { z-index: 0; }
#gl { transition: opacity .35s ease, transform .35s ease; transform-origin: var(--gx, 50%) var(--gy, 50%); }
#stars { transition: opacity .35s ease; }
.kart { z-index: 1; background: #0a1838; visibility: hidden; opacity: 0; transform: scale(.82); transform-origin: var(--gx, 50%) var(--gy, 50%); transition: opacity .35s ease, transform .35s ease, visibility 0s linear .35s; }
#fx { z-index: 2; }
.map-on #gl { opacity: 0; transform: scale(1.6); }
.map-on #stars { opacity: 0; }
.map-on .kart { visibility: visible; opacity: 1; transform: none; transition: opacity .35s ease, transform .35s ease; }
.map-on #fx { pointer-events: none; }
.map-on #rot-l, .map-on #rot-r { display: none; }
.app:not(.map-on) #b3d { display: none; }
.kart.pointing { cursor: pointer; }
.kart .leaflet-bottom { bottom: 76px; }
.kart .leaflet-control-attribution { background: rgba(7, 20, 52, .86); color: var(--ink-soft); border-radius: 6px 6px 0 0; padding: 2px 8px; font-family: var(--body); font-size: 11.5px; }
.kart .leaflet-control-attribution a { color: #cfe2ff; }
.open { min-height: 44px; }
.mini { min-width: 52px; height: 44px; padding: 0 13px; border-radius: 999px; font-weight: 600; background: rgba(7, 20, 52, .78); border: 1px solid var(--edge); }
.mini:hover { border-color: #b9d8ff; background: rgba(22, 60, 140, .9); }
.toast { position: absolute; left: 50%; bottom: 92px; z-index: 7; transform: translateX(-50%); max-width: calc(100% - 32px); padding: 9px 14px; border-radius: 999px; font-size: 14px; background: rgba(5, 16, 44, .95); border: 1px solid #8fc0ff; opacity: 0; pointer-events: none; transition: opacity .25s; }
.toast.vis { opacity: 1; }
.lag3d { position: absolute; inset: 0; z-index: 20; background: var(--night); }
.lag3d iframe { display: block; width: 100%; height: 100%; border: 0; }
.lukk3d { position: absolute; left: 12px; top: 12px; height: 46px; padding: 0 16px; border-radius: 999px; font-weight: 600; background: var(--glass); border: 1px solid #8fc0ff; box-shadow: 0 6px 22px rgba(0, 8, 36, .6); }
.map-on #spin { width: auto; padding: 0 18px 0 14px; border-radius: 999px; display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }
#b3d { font-weight: 700; font-size: 14.5px; }
.sted-sok .res-title { color: #cfe2ff; }
.res { min-height: 44px; }
.is-mobile .open { height: 44px; }
.is-mobile .bar { height: 62px; }
.is-mobile .round { width: 44px; height: 44px; }
.is-mobile .round.big { width: 46px; height: 46px; }
.is-mobile .zoom button { width: 44px; height: 44px; }
.is-mobile .toast { bottom: 204px; }
.is-mobile .kart .leaflet-bottom { bottom: 64px; }
.is-mobile.map-on #spin span { display: none; }
.is-mobile.map-on #spin { padding: 0; width: 46px; justify-content: center; }
.is-mobile .readout output { font-size: 12px; }
.is-mobile .bar { grid-template-columns: minmax(0, 1fr) auto auto; gap: 6px; }
.is-mobile .bar-right, .is-mobile .bar-mid { gap: 6px; }
@media (prefers-reduced-motion: reduce) {
  #gl, #stars, .kart, .map-on .kart, .toast { transition: none; }
}
.map-on .bar { background: rgba(3, 9, 24, .92); }
.readout { overflow: hidden; }
.readout output { overflow: hidden; text-overflow: ellipsis; }
.is-mobile.map-on #home { display: none; }
.is-mobile .kart .leaflet-bottom.leaflet-left { bottom: auto; top: 126px; }
.is-mobile .kart .leaflet-control-attribution { border-radius: 0 6px 6px 0; }
#bfoto { width: auto; padding: 0 15px; border-radius: 999px; font-weight: 600; font-size: 14.500px; }
#bfoto[aria-pressed="true"] { background: linear-gradient(180deg, #2a78ee, #1247b4); border-color: #b9d8ff; }
#bfoto .kort { display: none; }
.app:not(.map-on) #bfoto { display: none; }
.mini.bekreft { background: #b3261e; border-color: #ffb4ab; color: #fff; }
.flyttbar { position: absolute; left: 50%; top: 12px; transform: translateX(-50%); z-index: 9; display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px 14px; width: max-content; max-width: calc(100% - 20px); padding: 9px 12px 9px 16px; border-color: var(--gold); font-weight: 500; }
.flyttbar .rad { display: flex; gap: 8px; }
.flyttpin { background: none; border: 0; cursor: grab; }
.flyttpin svg { display: block; filter: drop-shadow(0 3px 5px rgba(0, 6, 30, .65)); }
.flyttpin:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 10px; }
button.open { font: inherit; font-weight: 600; cursor: pointer; }
button.open:disabled { opacity: .55; cursor: default; }
.is-mobile #bfoto { padding: 0 12px; }
.is-mobile #bfoto .lang { display: none; }
.is-mobile #bfoto .kort { display: inline; }
.is-mobile .flyttbar { top: 8px; padding: 8px 10px; font-size: 14px; }
.is-mobile.map-on .readout span { display: none; }

/* ---------- skallet fra GlobusMotor.start(): bare kloden, søk og bunnlinje ---------- */
.gm-skall .top { justify-content: flex-end; }
.gm-skall.is-mobile .toast { bottom: 76px; }
.gm-skall.is-mobile .kart .leaflet-bottom.leaflet-left { top: auto; bottom: 64px; }
.gm-skall.is-mobile .kart .leaflet-control-attribution { border-radius: 6px 6px 0 0; }
