:root.atlas-vr-is-open {
  overflow: hidden;
}

.atlas-vr[hidden],
.atlas-vr [hidden] {
  display: none !important;
}

.atlas-vr {
  --atlas-vr-space: #02090b;
  --atlas-vr-globe: #183932;
  --atlas-vr-grid: #80a98c;
  --atlas-vr-accent: #e6b96d;
  --atlas-vr-haze: #66b7a5;
  --atlas-vr-panel: rgba(7, 15, 17, 0.9);
  --atlas-vr-panel-solid: #0a1517;
  --atlas-vr-line: rgba(211, 229, 224, 0.24);
  --atlas-vr-text: #f1f5f2;
  --atlas-vr-muted: #a7bab6;
  position: fixed;
  inset: 0;
  z-index: 12000;
  overflow: hidden;
  color: var(--atlas-vr-text);
  background: var(--atlas-vr-space);
  color-scheme: dark;
  font-family: "Segoe UI", Arial, sans-serif;
  isolation: isolate;
}

.atlas-vr *,
.atlas-vr *::before,
.atlas-vr *::after {
  box-sizing: border-box;
}

.atlas-vr button,
.atlas-vr select,
.atlas-vr input {
  font: inherit;
  letter-spacing: 0;
}

.atlas-vr__stage,
.atlas-vr__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.atlas-vr__stage {
  overflow: hidden;
  background: var(--atlas-vr-space);
}

.atlas-vr__canvas {
  display: block;
  outline: 0;
  touch-action: none;
}

.atlas-vr__canvas.has-marker-hit {
  cursor: pointer;
}

.atlas-vr__topbar {
  position: absolute;
  z-index: 5;
  inset: 0 0 auto;
  min-height: 72px;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto minmax(220px, 1fr);
  align-items: center;
  gap: 20px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--atlas-vr-line);
  background: rgba(4, 10, 12, 0.94);
}

.atlas-vr__topbar h1,
.atlas-vr__detail h2 {
  margin: 0;
  color: var(--atlas-vr-text);
  letter-spacing: 0;
}

.atlas-vr__topbar h1 {
  font-size: 1.1rem;
  line-height: 1.2;
}

.atlas-vr__eyebrow {
  margin: 0 0 3px;
  color: var(--atlas-vr-accent);
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1.2;
  text-transform: uppercase;
}

.atlas-vr__webxr-status {
  margin: 0;
  color: var(--atlas-vr-muted);
  font-size: 0.78rem;
  text-align: center;
}

.atlas-vr__actions {
  min-width: 0;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
}

.atlas-vr__xr-slot {
  min-width: 0;
  min-height: 40px;
  display: flex;
  align-items: center;
}

.atlas-vr .atlas-vr__enter-vr,
.atlas-vr__close,
.atlas-vr__detail-close {
  border: 1px solid var(--atlas-vr-line) !important;
  color: var(--atlas-vr-text) !important;
  background: rgba(8, 18, 20, 0.88) !important;
  box-shadow: none !important;
  cursor: pointer !important;
}

.atlas-vr .atlas-vr__enter-vr {
  position: static !important;
  inset: auto !important;
  width: auto !important;
  min-width: 126px !important;
  height: 40px !important;
  margin: 0 !important;
  padding: 0 15px !important;
  border-radius: 4px !important;
  opacity: 1 !important;
  font: 700 0.72rem/38px "Segoe UI", Arial, sans-serif !important;
  letter-spacing: 0 !important;
  text-transform: uppercase !important;
}

.atlas-vr__close,
.atlas-vr__detail-close {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  padding: 0;
  border-radius: 4px;
  font-size: 1.75rem;
  line-height: 1;
}

.atlas-vr__close:hover,
.atlas-vr__detail-close:hover,
.atlas-vr .atlas-vr__enter-vr:hover {
  border-color: var(--atlas-vr-accent) !important;
  background: color-mix(in srgb, var(--atlas-vr-accent) 18%, #081214) !important;
}

.atlas-vr button:focus-visible,
.atlas-vr select:focus-visible,
.atlas-vr input:focus-visible {
  outline: 3px solid var(--atlas-vr-accent);
  outline-offset: 2px;
}

.atlas-vr__explorer {
  position: absolute;
  z-index: 4;
  top: 92px;
  bottom: 164px;
  left: 18px;
  width: min(330px, calc(100vw - 36px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--atlas-vr-line);
  border-radius: 6px;
  background: var(--atlas-vr-panel);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(16px);
}

.atlas-vr__field {
  display: grid;
  gap: 6px;
  padding: 14px;
  border-bottom: 1px solid var(--atlas-vr-line);
}

.atlas-vr__field > span,
.atlas-vr__timeline > label {
  color: var(--atlas-vr-muted);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
}

.atlas-vr__field select {
  width: 100%;
  height: 40px;
  padding: 0 36px 0 11px;
  border: 1px solid var(--atlas-vr-line);
  border-radius: 3px;
  color: var(--atlas-vr-text);
  background: var(--atlas-vr-panel-solid);
}

.atlas-vr__count {
  margin: 0;
  padding: 10px 14px;
  border-bottom: 1px solid var(--atlas-vr-line);
  color: var(--atlas-vr-muted);
  font-size: 0.76rem;
}

.atlas-vr__orientation {
  margin: 0;
  padding: 8px 14px;
  border-bottom: 1px solid var(--atlas-vr-line);
  color: var(--atlas-vr-muted);
  font-size: 0.64rem;
  line-height: 1.35;
}

.atlas-vr__places {
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  scrollbar-color: var(--atlas-vr-grid) transparent;
}

.atlas-vr__place {
  width: 100%;
  min-height: 55px;
  display: grid;
  grid-template-columns: 10px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  padding: 9px 12px;
  border: 0;
  border-bottom: 1px solid var(--atlas-vr-line);
  color: var(--atlas-vr-text);
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.atlas-vr__place > span:first-child {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--atlas-vr-marker);
  box-shadow: 0 0 12px color-mix(in srgb, var(--atlas-vr-marker) 70%, transparent);
}

.atlas-vr__place > span:last-child {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.atlas-vr__place strong,
.atlas-vr__place small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.atlas-vr__place strong {
  font-size: 0.83rem;
}

.atlas-vr__place small {
  color: var(--atlas-vr-muted);
  font-size: 0.68rem;
}

.atlas-vr__place:hover,
.atlas-vr__place.is-selected {
  background: color-mix(in srgb, var(--atlas-vr-accent) 13%, transparent);
}

.atlas-vr__place.is-selected {
  box-shadow: inset 3px 0 var(--atlas-vr-accent);
}

.atlas-vr__empty {
  margin: 0;
  padding: 18px 14px;
  color: var(--atlas-vr-muted);
  font-size: 0.8rem;
  line-height: 1.5;
}

.atlas-vr__detail {
  position: absolute;
  z-index: 6;
  top: 92px;
  right: 18px;
  bottom: 164px;
  width: min(410px, calc(100vw - 36px));
  overflow: auto;
  overscroll-behavior: contain;
  padding: 22px;
  border: 1px solid var(--atlas-vr-line);
  border-radius: 6px;
  background: var(--atlas-vr-panel);
  box-shadow: 0 20px 70px rgba(0, 0, 0, 0.36);
  backdrop-filter: blur(18px);
  scrollbar-color: var(--atlas-vr-grid) transparent;
}

.atlas-vr__detail-close {
  position: sticky;
  z-index: 2;
  top: 0;
  float: right;
  margin: -8px -8px 6px 12px;
}

.atlas-vr__detail h2 {
  max-width: calc(100% - 54px);
  font-size: 1.55rem;
  line-height: 1.15;
}

.atlas-vr__detail p {
  color: #d6e0dd;
  font-size: 0.83rem;
  line-height: 1.55;
}

.atlas-vr__place-meta {
  margin: 6px 0 18px;
  color: var(--atlas-vr-muted) !important;
  font-size: 0.74rem !important;
}

.atlas-vr__confidence {
  display: grid;
  gap: 3px;
  padding: 10px 12px;
  border-left: 3px solid var(--atlas-vr-accent);
  background: color-mix(in srgb, var(--atlas-vr-accent) 10%, transparent);
}

.atlas-vr__confidence strong {
  color: var(--atlas-vr-accent);
  font-size: 0.66rem;
  text-transform: uppercase;
}

.atlas-vr__detail dl {
  margin: 20px 0 0;
}

.atlas-vr__detail dl > div {
  padding: 13px 0;
  border-top: 1px solid var(--atlas-vr-line);
}

.atlas-vr__detail dt {
  margin-bottom: 5px;
  color: var(--atlas-vr-accent);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
}

.atlas-vr__detail dd {
  margin: 0;
  color: #d6e0dd;
  font-size: 0.79rem;
  line-height: 1.5;
}

.atlas-vr__timeline {
  position: absolute;
  z-index: 5;
  right: 18px;
  bottom: 18px;
  left: 18px;
  min-height: 124px;
  display: grid;
  grid-template-columns: minmax(240px, 0.7fr) minmax(360px, 1.3fr);
  grid-template-rows: auto auto;
  column-gap: 28px;
  align-items: end;
  padding: 15px 18px 13px;
  border: 1px solid var(--atlas-vr-line);
  border-radius: 6px;
  background: var(--atlas-vr-panel);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(18px);
}

.atlas-vr__era-copy {
  grid-row: 1 / span 2;
  min-width: 0;
}

.atlas-vr__era-copy > span {
  display: block;
  color: var(--atlas-vr-accent);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
}

.atlas-vr__era-copy > strong {
  display: block;
  margin-top: 3px;
  font-size: 1.08rem;
  line-height: 1.2;
}

.atlas-vr__era-copy p {
  max-width: 68ch;
  margin: 6px 0 0;
  color: var(--atlas-vr-muted);
  font-size: 0.72rem;
  line-height: 1.4;
}

.atlas-vr__timeline > label {
  align-self: end;
}

.atlas-vr__timeline input[type="range"] {
  width: 100%;
  height: 28px;
  margin: 0;
  accent-color: var(--atlas-vr-accent);
  cursor: ew-resize;
}

.atlas-vr__era-ends {
  grid-column: 2;
  display: flex;
  justify-content: space-between;
  margin-top: -7px;
  color: var(--atlas-vr-muted);
  font-size: 0.62rem;
}

.atlas-vr__tooltip {
  position: absolute;
  z-index: 8;
  max-width: 260px;
  padding: 7px 9px;
  border: 1px solid var(--atlas-vr-line);
  border-radius: 3px;
  color: var(--atlas-vr-text);
  background: rgba(5, 13, 15, 0.94);
  font-size: 0.72rem;
  line-height: 1.35;
  pointer-events: none;
  transform: translate(14px, -50%);
}

.atlas-vr__loading,
.atlas-vr__fallback {
  position: absolute;
  z-index: 3;
  top: 50%;
  left: 50%;
  width: min(420px, calc(100% - 40px));
  color: var(--atlas-vr-text);
  text-align: center;
  transform: translate(-50%, -50%);
}

.atlas-vr__loading {
  display: grid;
  justify-items: center;
  gap: 14px;
  color: var(--atlas-vr-muted);
  font-size: 0.82rem;
}

.atlas-vr__loading span {
  width: 48px;
  height: 48px;
  border: 2px solid var(--atlas-vr-line);
  border-top-color: var(--atlas-vr-accent);
  border-radius: 50%;
  animation: atlas-vr-spin 900ms linear infinite;
}

.atlas-vr__fallback {
  padding: 24px;
  border: 1px solid var(--atlas-vr-line);
  background: rgba(5, 13, 15, 0.92);
}

.atlas-vr__fallback strong {
  font-size: 1.1rem;
}

.atlas-vr__fallback p {
  margin: 8px 0 0;
  color: var(--atlas-vr-muted);
  font-size: 0.82rem;
  line-height: 1.5;
}

.atlas-vr.is-fallback .atlas-vr__explorer,
.atlas-vr.is-fallback .atlas-vr__timeline {
  background: rgba(7, 15, 17, 0.98);
}

@keyframes atlas-vr-spin {
  to {
    transform: rotate(360deg);
  }
}

@media (max-width: 900px) {
  .atlas-vr__topbar {
    grid-template-columns: minmax(180px, 1fr) auto;
  }

  .atlas-vr__webxr-status {
    display: none;
  }

  .atlas-vr__explorer {
    bottom: 154px;
    width: 280px;
  }

  .atlas-vr__detail {
    bottom: 154px;
    width: min(370px, calc(100vw - 330px));
  }

  .atlas-vr__timeline {
    min-height: 114px;
    grid-template-columns: minmax(210px, 0.8fr) minmax(280px, 1.2fr);
  }

  .atlas-vr__era-copy p {
    display: none;
  }
}

@media (max-width: 680px) {
  .atlas-vr__topbar {
    min-height: 62px;
    padding: 9px 10px;
  }

  .atlas-vr__topbar h1 {
    font-size: 0.95rem;
  }

  .atlas-vr__eyebrow {
    font-size: 0.58rem;
  }

  .atlas-vr__xr-slot {
    display: none;
  }

  .atlas-vr__close {
    width: 42px;
    height: 42px;
  }

  .atlas-vr__explorer {
    top: 74px;
    right: 10px;
    bottom: auto;
    left: 10px;
    width: auto;
    max-height: 27vh;
  }

  .atlas-vr__field {
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    padding: 8px 10px;
  }

  .atlas-vr__field select {
    height: 36px;
  }

  .atlas-vr__count {
    padding: 7px 10px;
  }

  .atlas-vr__orientation {
    display: none;
  }

  .atlas-vr__place {
    min-height: 48px;
    padding: 7px 10px;
  }

  .atlas-vr__detail {
    top: auto;
    right: 10px;
    bottom: 112px;
    left: 10px;
    width: auto;
    max-height: 43vh;
    padding: 16px;
  }

  .atlas-vr__detail h2 {
    font-size: 1.25rem;
  }

  .atlas-vr__timeline {
    right: 10px;
    bottom: 10px;
    left: 10px;
    min-height: 92px;
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: auto auto;
    gap: 8px;
    padding: 10px 12px;
  }

  .atlas-vr__era-copy {
    grid-row: auto;
  }

  .atlas-vr__era-copy > strong {
    font-size: 0.88rem;
  }

  .atlas-vr__timeline > label,
  .atlas-vr__era-copy p,
  .atlas-vr__era-ends {
    display: none;
  }

  .atlas-vr__timeline input[type="range"] {
    height: 24px;
  }

  .atlas-vr__tooltip {
    display: none;
  }
}

@media (max-height: 620px) and (min-width: 681px) {
  .atlas-vr__explorer,
  .atlas-vr__detail {
    top: 78px;
    bottom: 112px;
  }

  .atlas-vr__timeline {
    bottom: 8px;
    min-height: 88px;
    padding-block: 10px;
  }

  .atlas-vr__era-copy p {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .atlas-vr *,
  .atlas-vr *::before,
  .atlas-vr *::after {
    scroll-behavior: auto !important;
  }

  .atlas-vr__loading span {
    animation: none;
  }
}

@media (forced-colors: active) {
  .atlas-vr__topbar,
  .atlas-vr__explorer,
  .atlas-vr__detail,
  .atlas-vr__timeline,
  .atlas-vr__fallback {
    border: 1px solid CanvasText;
    background: Canvas;
    color: CanvasText;
    forced-color-adjust: none;
  }

  .atlas-vr__place.is-selected {
    outline: 2px solid Highlight;
    outline-offset: -2px;
  }
}
