/* ═══════════════════════════════════════════════════════════════
   Kulturhjertet — Pano2VR Shell
   Estetikk: Mørk, raffinert, nordisk kulturbygg-stemning.
   Typografi: Cormorant Garamond (display) + DM Sans (UI)
   ═══════════════════════════════════════════════════════════════ */

/* ─── Custom properties ─────────────────────────────────────── */
:root {
  --gold:          #c8a96e;
  --gold-dim:      rgba(200, 169, 110, 0.35);
  --gold-glow:     rgba(200, 169, 110, 0.12);
  --ink:           #0d0d0e;
  --ink-2:         #161618;
  --ink-3:         #1e1e21;
  --ink-4:         #2a2a2e;
  --surface:       rgba(18, 18, 20, 0.82);
  --surface-heavy: rgba(14, 14, 16, 0.96);
  --text-primary:  #f0ece4;
  --text-muted:    rgba(240, 236, 228, 0.45);
  --text-dim:      rgba(240, 236, 228, 0.25);

  --bar-h:         56px;
  --bar-h-sm:      48px;
  --radius:        6px;
  --radius-lg:     12px;
  --blur:          backdrop-filter: blur(20px) saturate(160%);
  --ease-out:      cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out:   cubic-bezier(0.4, 0, 0.2, 1);

  --panel-w:       340px;
  --drawer-w:      280px;

  font-size: 15px;
}

/* ─── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; overflow: hidden; background: var(--ink); }

body {
  font-family: 'DM Sans', system-ui, sans-serif;
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
}

/* ─── Shell ─────────────────────────────────────────────────── */
.shell {
  position: fixed;
  inset: 0;
  display: grid;
  grid-template-rows: var(--bar-h) 1fr var(--bar-h);
  grid-template-columns: 1fr;
  grid-template-areas:
    "top"
    "stage"
    "bottom";
}

/* ─── Loading screen ────────────────────────────────────────── */
.load-screen {
  position: absolute;
  inset: 0;
  z-index: 200;
  background: var(--ink);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.4s var(--ease-out);
}
.shell--ready .load-screen { opacity: 0; pointer-events: none; }

.load-screen__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  width: min(340px, 90vw);
}

.load-screen__logo {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: clamp(2rem, 8vw, 3.2rem);
  font-weight: 300;
  letter-spacing: 0.12em;
  color: var(--gold);
}

.load-screen__subtitle {
  font-size: 0.75rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.load-screen__bar {
  width: 100%;
  height: 1px;
  background: var(--ink-4);
  position: relative;
  overflow: hidden;
}

.load-screen__bar-fill {
  position: absolute;
  left: 0; top: 0; bottom: 0;
  background: linear-gradient(90deg, var(--gold-dim), var(--gold));
  width: 0%;
  transition: width 0.3s var(--ease-out);
}

.load-screen__percent {
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  color: var(--text-dim);
}

/* ─── Top bar ───────────────────────────────────────────────── */
.top-bar {
  grid-area: top;
  display: flex;
  align-items: center;
  padding: 0 12px;
  background: var(--surface-heavy);
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  border-bottom: 1px solid rgba(200, 169, 110, 0.1);
  position: relative;
  z-index: 100;
}

.top-bar__left,
.top-bar__right {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
}

.top-bar__right { justify-content: flex-end; }

.top-bar__center {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  pointer-events: none;
}

.top-bar__title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.15rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 40vw;
  transition: color 0.3s;
}

/* ─── Icon buttons ──────────────────────────────────────────── */
.icon-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  border-radius: var(--radius);
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.2s, background 0.2s;
}

.icon-btn:hover {
  color: var(--gold);
  background: var(--gold-glow);
}

.icon-btn svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* Icon buttons med tekst-label */
.icon-btn--labeled {
  width: auto;
  gap: 8px;
  padding: 0 14px;
  margin-left: 8px;
}

.icon-btn__label {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.2s;
}

.icon-btn--labeled:hover .icon-btn__label {
  color: var(--gold);
}

/* Aktiv tilstand - knappen lyser mens menyen er åpen */
.icon-btn--active {
  color: var(--gold);
  background: var(--gold-glow);
}

.icon-btn--active .icon-btn__label {
  color: var(--gold);
}

/* Skjul fullscreen på mobil */
@media (max-width: 768px) {
  .icon-btn--desktop-only {
    display: none !important;
  }
}

/* På mobil: skjul tekst-labels, vis kun ikoner */
@media (max-width: 768px) {
  .icon-btn--labeled {
    width: 36px;
    height: 36px;
    padding: 0;
    margin-left: 4px;
    gap: 0;
  }
  .icon-btn__label {
    display: none;
  }
}

/* ─── Pano stage ────────────────────────────────────────────── */
.pano-stage {
  grid-area: stage;
  position: relative;
  overflow: hidden;
  background: var(--ink-2);
  min-height: 0;
  height: 100%;
  width: 100%;
}

.pano-embed {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
}

/* ─── Compass ───────────────────────────────────────────────── */
.compass {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 52px;
  height: 52px;
  pointer-events: none;
  z-index: 10;
  opacity: 0.75;
  transition: opacity 0.3s;
}

.compass:hover { opacity: 1; }

.compass__ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  color: var(--gold);
  font-family: 'DM Sans', sans-serif;
}

.compass__needle {
  position: absolute;
  inset: 12px;
  transition: transform 0.1s linear;
  transform-origin: center center;
}

.compass__needle svg {
  width: 100%;
  height: 100%;
}

/* ─── Transition overlay ────────────────────────────────────── */
.transition-overlay {
  position: absolute;
  inset: 0;
  background: var(--ink);
  opacity: 0;
  pointer-events: none;
  z-index: 20;
  transition: opacity 0.3s var(--ease-in-out);
}

.transition-overlay.active { opacity: 0.6; }

/* ─── Side panel ────────────────────────────────────────────── */
.side-panel {
  position: fixed;
  top: var(--bar-h);
  right: 0;
  bottom: var(--bar-h);
  width: var(--panel-w);
  max-width: 90vw;
  background: var(--surface-heavy);
  backdrop-filter: blur(28px) saturate(160%);
  -webkit-backdrop-filter: blur(28px) saturate(160%);
  border-left: 1px solid rgba(200, 169, 110, 0.12);
  z-index: 90;
  transform: translateX(100%);
  transition: transform 0.35s var(--ease-out);
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.side-panel--open { transform: translateX(0); }

.side-panel__close {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 10;
  padding: 8px;
}

.side-panel__section { display: flex; flex-direction: column; gap: 12px; }

.panel-label {
  font-size: 0.65rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: 0.8;
}

.panel-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.8rem;
  font-weight: 300;
  line-height: 1.2;
  color: var(--text-primary);
}

.panel-body {
  font-size: 0.88rem;
  line-height: 1.65;
  color: var(--text-muted);
}

.panel-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.meta-tag {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  padding: 3px 10px;
  border: 1px solid var(--gold-dim);
  border-radius: 100px;
  color: var(--gold);
  text-transform: uppercase;
}

/* ═══════════════════════════════════════════════════════════════
   KART — Desktop flytende vindu + Mobil bottom sheet
   ═══════════════════════════════════════════════════════════════ */

/* ─── Desktop: Flytende vindu ───────────────────────────────── */
.map-window {
  position: fixed;
  top: 80px;
  right: 20px;
  width: 400px;
  height: 450px;
  min-width: 280px;
  min-height: 250px;
  max-width: 80vw;
  max-height: 80vh;
  background: var(--surface-heavy);
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  border: 1px solid rgba(200, 169, 110, 0.2);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  z-index: 150;
  overflow: hidden;
  user-select: none;
}

.map-window--visible {
  display: flex !important;
  animation: mapWindowEnter 0.3s var(--ease-out);
}

/* Minimized widget state */
.map-window--minimized {
  animation: none;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  height: auto !important;
  min-height: unset !important;
  max-height: unset !important;
  overflow: visible;
}

.map-window--minimized .map-window__content {
  display: none !important; /* Skjul kart-innhold helt */
}

.map-window--minimized .map-window__titlebar {
  border-bottom: none;
  background: rgba(200, 169, 110, 0.15);
  padding: 12px 14px; /* Litt mer padding for bedre klikkflate */
}

.map-window--minimized .map-window__title::before {
  content: '▸ ';
  opacity: 0.7;
}

.map-window--minimized .map-window__resize {
  display: none !important; /* Skjul resize handles */
}

@keyframes mapWindowEnter {
  from { opacity: 0; transform: scale(0.95) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

/* Titlebar */
.map-window__titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: rgba(200, 169, 110, 0.08);
  border-bottom: 1px solid rgba(200, 169, 110, 0.12);
  cursor: grab;
}

.map-window__titlebar:active {
  cursor: grabbing;
}

.map-window__title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1rem;
  color: var(--gold);
  letter-spacing: 0.05em;
}

.map-window__controls {
  display: flex;
  gap: 4px;
}

.map-window__btn {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--radius);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
}

.map-window__btn:hover {
  background: var(--gold-glow);
  border-color: var(--gold-dim);
  color: var(--gold);
}

.map-window__btn svg {
  width: 14px;
  height: 14px;
}

/* Content */
.map-window__content {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  position: relative;
}

.map-window__content .geo-map {
  flex: 1;
  height: auto;
  border: none;
  border-radius: 0;
}

.map-window__content .map-legend {
  padding: 10px 14px;
  background: rgba(0, 0, 0, 0.2);
  border-top: 1px solid rgba(200, 169, 110, 0.1);
}

/* Content må fortsatt klippe innhold */
.map-window__content {
  overflow: hidden;
  border-radius: 0 0 var(--radius) var(--radius);
}

/* Resize handles - alltid synlige */
.map-window {
  overflow: visible !important; /* Viktig: ikke klipp handles som går utenfor */
}

.map-window__resize {
  position: absolute;
  z-index: 1000; /* Høy z-index for å være overalt */
}

/* Resize handles - utvidet hit-område utenfor vinduet */
.map-window__resize--n { top: -10px; left: 20px; right: 20px; height: 20px; cursor: ns-resize; }
.map-window__resize--s { bottom: -10px; left: 20px; right: 20px; height: 20px; cursor: ns-resize; }
.map-window__resize--e { right: -10px; top: 20px; bottom: 20px; width: 20px; cursor: ew-resize; }
.map-window__resize--w { left: -10px; top: 20px; bottom: 20px; width: 20px; cursor: ew-resize; }

/* Corners - utvidet hit-område */
.map-window__resize--ne { top: -10px; right: -10px; width: 30px; height: 30px; cursor: nesw-resize; }
.map-window__resize--nw { top: -10px; left: -10px; width: 30px; height: 30px; cursor: nwse-resize; }
.map-window__resize--se { bottom: -10px; right: -10px; width: 30px; height: 30px; cursor: nwse-resize; }
.map-window__resize--sw { bottom: -10px; left: -10px; width: 30px; height: 30px; cursor: nesw-resize; }

/* Base stil - alltid synlig subtilt (lyslere) */
.map-window__resize::after {
  content: '';
  position: absolute;
  background: rgba(200, 169, 110, 0.4);
  border-radius: 2px;
  transition: all 0.2s ease;
}

/* Sides - horisontale linjer */
.map-window__resize--n::after,
.map-window__resize--s::after {
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 24px;
  height: 2px;
}

/* Sider - vertikale linjer */
.map-window__resize--e::after,
.map-window__resize--w::after {
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 2px;
  height: 24px;
}

/* Corners - L-formede hjørner med border-radius */
.map-window__resize--ne::after,
.map-window__resize--nw::after,
.map-window__resize--se::after,
.map-window__resize--sw::after {
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 14px;
  height: 14px;
  background: transparent;
  border: 2px solid rgba(200, 169, 110, 0.4);
  border-radius: var(--radius);
}

/* NE - L i øvre høyre */
.map-window__resize--ne::after {
  border-right-color: rgba(200, 169, 110, 0.4);
  border-top-color: rgba(200, 169, 110, 0.4);
  border-left: none;
  border-bottom: none;
  border-radius: 0 var(--radius) 0 0;
}

/* NW - L i øvre venstre */
.map-window__resize--nw::after {
  border-left-color: rgba(200, 169, 110, 0.4);
  border-top-color: rgba(200, 169, 110, 0.4);
  border-right: none;
  border-bottom: none;
  border-radius: var(--radius) 0 0 0;
}

/* SE - L i nedre høyre */
.map-window__resize--se::after {
  border-right-color: rgba(200, 169, 110, 0.4);
  border-bottom-color: rgba(200, 169, 110, 0.4);
  border-left: none;
  border-top: none;
  border-radius: 0 0 var(--radius) 0;
}

/* SW - L i nedre venstre */
.map-window__resize--sw::after {
  border-left-color: rgba(200, 169, 110, 0.4);
  border-bottom-color: rgba(200, 169, 110, 0.4);
  border-right: none;
  border-top: none;
  border-radius: 0 0 0 var(--radius);
}

/* Hover effekt - lys opp tydelig */
.map-window__resize:hover::after {
  background: var(--gold);
  box-shadow: 0 0 12px rgba(200, 169, 110, 0.8);
}

.map-window__resize--n:hover::after,
.map-window__resize--s:hover::after {
  width: 32px;
  height: 3px;
}

.map-window__resize--e:hover::after,
.map-window__resize--w:hover::after {
  width: 3px;
  height: 32px;
}

/* Hjørner hover */
.map-window__resize--ne:hover::after,
.map-window__resize--nw:hover::after,
.map-window__resize--se:hover::after,
.map-window__resize--sw:hover::after {
  background: transparent;
  border-color: var(--gold) !important;
  border-width: 3px;
  box-shadow: 0 0 12px rgba(200, 169, 110, 0.8);
}

/* ─── Mobil: Bottom sheet ──────────────────────────────────── */
.map-sheet {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: 50vh;
  background: var(--surface-heavy);
  backdrop-filter: blur(28px) saturate(160%);
  -webkit-backdrop-filter: blur(28px) saturate(160%);
  border-top: 1px solid rgba(200, 169, 110, 0.2);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  display: flex;
  flex-direction: column;
  z-index: 150;
  transform: translateY(100%);
  transition: transform 0.35s var(--ease-out);
}

.map-sheet--open {
  transform: translateY(0);
}

.map-sheet__handle {
  display: flex;
  justify-content: center;
  padding: 12px 0 8px;
  cursor: grab;
}

.map-sheet__handle:active {
  cursor: grabbing;
}

.map-sheet__dragbar {
  width: 40px;
  height: 4px;
  background: var(--gold-dim);
  border-radius: 2px;
  transition: background 0.2s;
}

.map-sheet__handle:hover .map-sheet__dragbar {
  background: var(--gold);
}

.map-sheet__content {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 0 16px 16px;
}

.map-sheet__content .geo-map {
  flex: 1;
  height: auto;
  border-radius: var(--radius);
}

/* Skjul mobil sheet på desktop */
@media (min-width: 769px) {
  .map-sheet { display: none !important; }
}

/* Skjul desktop vindu på mobil */
@media (max-width: 768px) {
  .map-window { display: none !important; }
}

/* ─── Geo map (Leaflet) ─────────────────────────────────────── */
.geo-map {
  border: 1px solid rgba(200, 169, 110, 0.15);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--ink-2);
  height: 320px;
  min-height: 200px;
}

/* Leaflet dark mode overrides */
.leaflet-container {
  background: var(--ink-2) !important;
  font-family: 'DM Sans', system-ui, sans-serif;
}

.leaflet-popup-content-wrapper,
.leaflet-popup-tip {
  background: var(--surface-heavy);
  color: var(--text-primary);
  border: 1px solid rgba(200, 169, 110, 0.2);
  border-radius: var(--radius);
}

.leaflet-popup-content {
  margin: 8px 12px;
  font-size: 0.85rem;
}

.leaflet-popup-content strong {
  color: var(--gold);
  font-family: 'Cormorant Garamond', serif;
  font-size: 1rem;
}

/* Custom markører */
.map-marker {
  background: transparent !important;
  border: none !important;
}

.map-marker svg {
  width: 100%;
  height: 100%;
  display: block;
}

.map-marker--active svg {
  filter: drop-shadow(0 0 8px rgba(200, 169, 110, 0.6)) !important;
}

/* Zoom controls styling */
.leaflet-control-zoom a {
  background: var(--surface-heavy) !important;
  color: var(--text-primary) !important;
  border: 1px solid rgba(200, 169, 110, 0.2) !important;
  border-radius: var(--radius) !important;
  width: 28px;
  height: 28px;
  line-height: 26px;
  font-size: 18px;
}

.leaflet-control-zoom a:hover {
  background: var(--gold-dim) !important;
  color: var(--gold) !important;
}

.leaflet-control-zoom-in { margin-bottom: 4px; }

/* Kart-legende */
.map-legend {
  display: flex;
  gap: 16px;
  padding: 8px 0;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.map-legend__item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.map-legend__icon {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1px solid currentColor;
}

.map-legend__icon--drone {
  background: rgba(200, 169, 110, 0.2);
  border-color: var(--gold);
}

.map-legend__icon--ground {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.5);
}

/* ─── Nav drawer ────────────────────────────────────────────── */
.nav-drawer {
  position: fixed;
  top: var(--bar-h);
  left: 0;
  bottom: var(--bar-h);
  width: var(--drawer-w);
  max-width: 80vw;
  background: var(--surface-heavy);
  backdrop-filter: blur(28px) saturate(160%);
  -webkit-backdrop-filter: blur(28px) saturate(160%);
  border-right: 1px solid rgba(200, 169, 110, 0.12);
  z-index: 90;
  transform: translateX(-100%);
  transition: transform 0.35s var(--ease-out);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.nav-drawer--open { transform: translateX(0); }

.nav-drawer__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 16px 12px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

/* ─── Nav list ──────────────────────────────────────────────── */
.nav-list {
  list-style: none;
  padding: 8px 0;
  flex: 1;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  cursor: pointer;
  transition: background 0.2s;
  border-left: 2px solid transparent;
}

.nav-item:hover { background: var(--gold-glow); }

.nav-item--active {
  border-left-color: var(--gold);
  background: rgba(200, 169, 110, 0.06);
}

.nav-item--active .nav-item__title { color: var(--gold); }

.nav-item__index {
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  font-variant-numeric: tabular-nums;
  min-width: 20px;
}

.nav-item__title {
  font-size: 0.88rem;
  color: var(--text-muted);
  flex: 1;
  transition: color 0.2s;
}

.nav-item--visited .nav-item__title { color: rgba(240, 236, 228, 0.65); }

.nav-item__visited-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: transparent;
  border: 1px solid var(--text-dim);
  flex-shrink: 0;
  transition: background 0.3s, border-color 0.3s;
}

.nav-item--visited .nav-item__visited-dot {
  background: var(--gold-dim);
  border-color: var(--gold);
}

/* ─── Bottom bar ────────────────────────────────────────────── */
.bottom-bar {
  grid-area: bottom;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  background: var(--surface-heavy);
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  border-top: 1px solid rgba(200, 169, 110, 0.1);
  position: relative;
  z-index: 100;
}

.bottom-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  padding: 6px 10px;
  border-radius: var(--radius);
  transition: color 0.2s, background 0.2s;
}

.bottom-btn:hover {
  color: var(--gold);
  background: var(--gold-glow);
}

.bottom-btn svg {
  width: 16px;
  height: 16px;
}

.bottom-bar__scene-info {
  display: flex;
  align-items: center;
  gap: 0;
}

/* ─── Scene dots ────────────────────────────────────────────── */
.scene-dots {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  max-width: 40vw;
}

.scene-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--ink-4);
  border: 1px solid rgba(200, 169, 110, 0.3);
  cursor: pointer;
  padding: 0;
  transition: background 0.25s, transform 0.25s, border-color 0.25s;
}

.scene-dot:hover {
  transform: scale(1.4);
  border-color: var(--gold);
}

.scene-dot--active {
  background: var(--gold);
  border-color: var(--gold);
  transform: scale(1.25);
}

/* ─── Toast ─────────────────────────────────────────────────── */
.toast-stack {
  position: fixed;
  bottom: calc(var(--bar-h) + 16px);
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  z-index: 300;
  pointer-events: none;
}

.toast {
  background: var(--surface-heavy);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--gold-dim);
  color: var(--text-primary);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  padding: 8px 20px;
  border-radius: 100px;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.25s, transform 0.25s var(--ease-out);
  white-space: nowrap;
}

.toast--visible { opacity: 1; transform: translateY(0); }

/* ─── Scrollbar (webkit) ────────────────────────────────────── */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--gold-dim); border-radius: 2px; }

/* ─── Responsive: mobil ─────────────────────────────────────── */
@media (max-width: 600px) {
  :root {
    --bar-h: var(--bar-h-sm);
    --panel-w: 100vw;
    --drawer-w: 85vw;
  }

  .top-bar__title { max-width: 30vw; font-size: 1rem; }

  .compass {
    top: 10px;
    right: 10px;
    width: 42px;
    height: 42px;
  }

  .bottom-btn span { display: none; }
  .bottom-btn svg { width: 20px; height: 20px; }

  .scene-dots { max-width: 50vw; }

  .side-panel {
    top: var(--bar-h);
    bottom: var(--bar-h);
  }
}

/* ─── Safe areas (notch / home indicator) ───────────────────── */
@supports (padding: max(0px)) {
  .top-bar    { padding-top:    max(0px, env(safe-area-inset-top)); }
  .bottom-bar { padding-bottom: max(0px, env(safe-area-inset-bottom)); }
}

/* ─── Fullscreen adjustments ────────────────────────────────── */
.shell--fullscreen .top-bar,
.shell--fullscreen .bottom-bar {
  background: rgba(10, 10, 11, 0.7);
}

/* ─── Animert scene-tittel ved bytte ────────────────────────── */
@keyframes titleIn {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

.top-bar__title { animation: titleIn 0.4s var(--ease-out); }
