:root {
  --bg: #020617;
  --panel: rgba(15, 23, 42, 0.92);
  --panel-solid: #0f172a;
  --panel-deep: #07111f;
  --border: rgba(148, 163, 184, 0.18);
  --border-strong: rgba(148, 163, 184, 0.28);
  --text: #f8fafc;
  --muted: #94a3b8;
  --blue: #38bdf8;
  --blue-deep: #1d4ed8;
  --green: #22c55e;
  --amber: #f59e0b;
  --red: #ef4444;
  --shadow: rgba(0, 0, 0, 0.42);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  color: inherit;
}

.app-shell {
  min-height: 100vh;
  background:
    linear-gradient(135deg, rgba(56, 189, 248, 0.1), transparent 34%),
    linear-gradient(180deg, #020617 0%, #08111f 100%);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 96px;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border-strong);
  background: rgba(2, 6, 23, 0.92);
  box-shadow: 0 18px 52px rgba(0, 0, 0, 0.38);
}

.brand-lockup {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
}

.brand-mark {
  width: 58px;
  height: 58px;
  flex: 0 0 auto;
}

.brand-mark svg {
  display: block;
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 0 18px rgba(56, 189, 248, 0.25));
}

.company {
  color: var(--text);
  font-size: 15px;
  font-weight: 750;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  margin-top: 3px;
  font-size: clamp(22px, 2vw, 30px);
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: 0;
}

.brand-lockup p {
  margin-top: 7px;
  color: var(--muted);
  font-size: 14px;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.icon-button,
.avatar {
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--border);
  background: rgba(15, 23, 42, 0.85);
  cursor: pointer;
}

.icon-button {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 19px;
  font-weight: 800;
}

.icon-button svg {
  width: 21px;
  height: 21px;
}

.icon-button span {
  position: absolute;
  right: -3px;
  top: -5px;
  display: grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  border-radius: 999px;
  background: var(--blue-deep);
  color: #fff;
  font-size: 11px;
  font-weight: 900;
}

.avatar {
  width: 46px;
  height: 46px;
  border-radius: 999px;
  color: var(--text);
  font-size: 15px;
  font-weight: 900;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(420px, 36vw);
  min-height: calc(100vh - 96px);
}

.viewer-region {
  position: relative;
  min-height: calc(100vh - 96px);
  overflow: hidden;
  background: #020617;
}

.viewer-region iframe {
  position: relative;
  z-index: 0;
  display: block;
  width: 100%;
  height: calc(100vh - 96px);
  min-height: 760px;
  border: 0;
  background: #020617;
}

.viewer-fallback {
  position: absolute;
  z-index: 1;
  inset: 0;
  display: grid;
  place-items: center;
  overflow: hidden;
  background:
    radial-gradient(circle at 34% 35%, rgba(56, 189, 248, 0.17), transparent 20%),
    radial-gradient(circle at 68% 68%, rgba(37, 99, 235, 0.14), transparent 24%),
    linear-gradient(120deg, rgba(15, 23, 42, 0.28), rgba(2, 6, 23, 0.9)),
    #020617;
  transition: opacity 260ms ease, visibility 260ms ease;
}

.viewer-region.viewer-ready .viewer-fallback {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.fallback-grid {
  position: absolute;
  inset: 120px 90px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  opacity: 0.55;
  transform: perspective(700px) rotateX(58deg) rotateZ(-8deg);
}

.fallback-grid span {
  min-height: 130px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  background:
    linear-gradient(90deg, rgba(56, 189, 248, 0.14) 1px, transparent 1px) 0 0 / 18px 18px,
    linear-gradient(rgba(56, 189, 248, 0.14) 1px, transparent 1px) 0 0 / 18px 18px,
    rgba(15, 23, 42, 0.54);
  box-shadow: inset 0 0 34px rgba(56, 189, 248, 0.05);
}

.fallback-message {
  position: relative;
  display: grid;
  gap: 8px;
  max-width: 420px;
  padding: 18px 20px;
  border: 1px solid rgba(56, 189, 248, 0.34);
  border-radius: 10px;
  background: rgba(2, 6, 23, 0.72);
  text-align: center;
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.42);
  backdrop-filter: blur(16px);
}

.fallback-message strong {
  font-size: 17px;
  font-weight: 900;
}

.fallback-message span {
  color: var(--muted);
  font-size: 13px;
}

.viewer-controls {
  position: absolute;
  z-index: 4;
  top: 16px;
  left: 16px;
  right: 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  pointer-events: none;
}

.meta-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.82);
  color: var(--text);
  padding: 0 14px;
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(14px);
  pointer-events: auto;
}

.meta-pill span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.meta-pill strong {
  font-size: 13px;
  font-weight: 900;
}

.meta-pill svg {
  width: 18px;
  height: 18px;
  color: var(--muted);
}

.copy-model,
.hide-panel {
  cursor: pointer;
}

.hide-panel {
  margin-left: auto;
}

.select-pill select {
  max-width: 260px;
  border: 0;
  background: transparent;
  color: var(--text);
  outline: none;
  font-size: 13px;
  font-weight: 850;
}

.select-pill option {
  color: #020617;
}

.left-rail {
  position: absolute;
  z-index: 5;
  top: 116px;
  left: 20px;
  display: grid;
  gap: 10px;
  padding: 8px;
  border: 1px solid var(--border-strong);
  border-radius: 16px;
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(16px);
}

.rail-button {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: #dbeafe;
  cursor: pointer;
}

.rail-button.active,
.rail-button:hover {
  border-color: rgba(56, 189, 248, 0.55);
  background: rgba(37, 99, 235, 0.82);
}

.rail-button svg {
  width: 22px;
  height: 22px;
}

.hotspot {
  position: absolute;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 10px;
  border: 0;
  background: transparent;
  padding: 0;
  color: inherit;
  pointer-events: auto;
  cursor: pointer;
}

.hotspot span {
  width: 20px;
  height: 20px;
  border: 3px solid rgba(186, 230, 253, 0.9);
  border-radius: 999px;
  background: var(--blue-deep);
  box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.22), 0 0 28px rgba(56, 189, 248, 0.45);
}

.hotspot div {
  min-width: 120px;
  padding: 11px 12px;
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 6px;
  background: rgba(2, 6, 23, 0.78);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(12px);
}

.hotspot strong,
.hotspot small {
  display: block;
}

.hotspot strong {
  color: var(--text);
  font-size: 13px;
  line-height: 1.3;
}

.hotspot small {
  margin-top: 4px;
  color: #cbd5e1;
  font-size: 11px;
}

.hotspot.pdu {
  left: 20%;
  top: 38%;
}

.hotspot.rack {
  left: 56%;
  top: 40%;
}

.hotspot.cooling {
  left: 49%;
  bottom: 27%;
}

.mini-map {
  position: absolute;
  z-index: 4;
  left: 20px;
  bottom: 58px;
  width: 330px;
  padding: 14px;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  background: rgba(2, 6, 23, 0.76);
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.38);
  backdrop-filter: blur(14px);
}

.level-select {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  min-height: 38px;
  margin-bottom: 14px;
  padding: 0 12px;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.72);
  color: var(--text);
  font-size: 13px;
  font-weight: 850;
}

.level-select svg {
  width: 16px;
  height: 16px;
}

.map-canvas {
  position: relative;
  height: 150px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background:
    linear-gradient(90deg, rgba(148, 163, 184, 0.18) 1px, transparent 1px) 0 0 / 28px 28px,
    linear-gradient(rgba(148, 163, 184, 0.18) 1px, transparent 1px) 0 0 / 28px 28px,
    rgba(15, 23, 42, 0.78);
}

.map-line {
  position: absolute;
  background: rgba(248, 250, 252, 0.7);
}

.map-line.horizontal {
  height: 2px;
  left: 12px;
  right: 12px;
}

.map-line.vertical {
  width: 2px;
  top: 12px;
  bottom: 12px;
}

.map-line.a { top: 32px; left: 20%; }
.map-line.b { top: 74px; }
.map-line.c { top: 116px; }
.map-line.vertical.a { left: 28px; }
.map-line.vertical.b { left: 132px; }
.map-line.vertical.c { right: 42px; }

.map-pin,
.map-current {
  position: absolute;
  border-radius: 999px;
  background: var(--blue-deep);
}

.map-pin {
  width: 18px;
  height: 18px;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.18);
}

.map-pin.one { left: 58px; top: 28px; }
.map-pin.two { left: 84px; top: 84px; }
.map-pin.three { right: 74px; bottom: 26px; }

.map-current {
  left: 78px;
  bottom: 22px;
  width: 14px;
  height: 14px;
  border: 2px solid #e0f2fe;
}

.bottom-nav {
  position: absolute;
  z-index: 4;
  left: 50%;
  bottom: 58px;
  transform: translateX(-50%);
  display: flex;
  gap: 4px;
  padding: 7px;
  border: 1px solid var(--border-strong);
  border-radius: 10px;
  background: rgba(2, 6, 23, 0.72);
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(14px);
}

.bottom-nav button {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #e2e8f0;
  cursor: pointer;
}

.bottom-nav button:hover {
  background: rgba(56, 189, 248, 0.16);
}

.bottom-nav svg {
  width: 22px;
  height: 22px;
}

.viewer-alert {
  position: absolute;
  z-index: 7;
  left: 20px;
  right: 20px;
  bottom: 18px;
  display: none;
  padding: 12px 14px;
  border: 1px solid rgba(245, 158, 11, 0.48);
  border-radius: 8px;
  background: rgba(2, 6, 23, 0.9);
  color: #fde68a;
  font-size: 13px;
  line-height: 1.45;
  backdrop-filter: blur(12px);
}

.viewer-alert.visible {
  display: block;
}

.command-panel {
  max-height: calc(100vh - 96px);
  overflow: auto;
  padding: 10px;
  border-left: 1px solid var(--border-strong);
  background: rgba(2, 6, 23, 0.7);
  scrollbar-width: thin;
  scrollbar-color: var(--border-strong) var(--bg);
}

.command-panel.hidden {
  display: none;
}

.workspace.panel-hidden {
  grid-template-columns: 1fr;
}

.panel-card {
  margin-bottom: 10px;
  padding: 14px;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.94), rgba(7, 17, 31, 0.94));
  box-shadow: 0 14px 42px rgba(0, 0, 0, 0.2);
}

.card-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 13px;
}

.panel-card h2 {
  color: var(--text);
  font-size: 16px;
  line-height: 1.2;
  font-weight: 900;
}

.status-dot-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #dbeafe;
  font-size: 12px;
  font-weight: 850;
}

.status-dot-label i {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--amber);
}

.status-dot-label.loaded i,
.status-dot-label.connected i {
  background: var(--green);
}

.status-dot-label.error i {
  background: var(--red);
}

.button-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.primary-button,
.secondary-button,
.link-button,
.tab-button {
  border: 1px solid var(--border-strong);
  border-radius: 7px;
  cursor: pointer;
}

.primary-button,
.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 38px;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 850;
}

.primary-button {
  border-color: rgba(56, 189, 248, 0.45);
  background: linear-gradient(180deg, #2f8deb, #1d65c8);
  color: white;
}

.secondary-button {
  background: rgba(15, 23, 42, 0.84);
  color: var(--text);
}

.primary-button svg,
.secondary-button svg {
  width: 16px;
  height: 16px;
}

.primary-button:hover,
.secondary-button:hover,
.link-button:hover,
.tab-button:hover {
  border-color: var(--blue);
}

.status-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 12px;
}

.status-grid div {
  min-width: 0;
  padding: 9px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: rgba(2, 6, 23, 0.42);
}

.status-grid span,
.status-grid strong {
  display: block;
  overflow-wrap: anywhere;
}

.status-grid span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
}

.status-grid strong {
  margin-top: 4px;
  color: var(--text);
  font-size: 12px;
  font-weight: 850;
}

.status-grid .connected {
  color: var(--green);
}

.status-grid .error {
  color: var(--red);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.metric {
  display: grid;
  grid-template-columns: 34px 1fr;
  grid-template-rows: auto auto;
  column-gap: 8px;
  min-height: 62px;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: rgba(15, 23, 42, 0.82);
}

.metric svg {
  grid-row: 1 / 3;
  align-self: center;
  width: 28px;
  height: 28px;
  color: var(--blue-deep);
}

.metric.green svg {
  color: var(--green);
}

.metric strong {
  font-size: 18px;
  line-height: 1.05;
}

.metric span {
  color: var(--muted);
  font-size: 11px;
}

.split-panel {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  gap: 10px;
}

.link-button {
  border: 0;
  background: transparent;
  color: var(--blue);
  padding: 4px 0;
  font-size: 12px;
  font-weight: 850;
}

.zone-list,
.asset-list,
.record-list {
  display: grid;
  gap: 8px;
}

.zone-button {
  display: grid;
  grid-template-columns: 26px 44px 1fr auto;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-height: 42px;
  border: 1px solid transparent;
  border-radius: 5px;
  background: transparent;
  color: var(--muted);
  padding: 8px;
  text-align: left;
  cursor: pointer;
}

.zone-button:hover,
.zone-button.active {
  border-color: rgba(56, 189, 248, 0.28);
  background: rgba(37, 99, 235, 0.22);
  color: #dbeafe;
}

.zone-button svg {
  width: 20px;
  height: 20px;
}

.zone-code {
  color: var(--text);
  font-size: 12px;
  font-weight: 900;
}

.zone-name,
.zone-type {
  font-size: 12px;
}

.zone-type {
  color: #cbd5e1;
}

.asset-card {
  display: grid;
  grid-template-columns: 54px 1fr;
  gap: 12px;
  width: 100%;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.58);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.asset-card:hover,
.asset-card.active {
  border-color: rgba(56, 189, 248, 0.45);
  background: rgba(30, 64, 175, 0.25);
}

.asset-cube {
  position: relative;
  width: 44px;
  height: 60px;
  border: 1px solid rgba(148, 163, 184, 0.38);
  border-radius: 4px;
  background:
    linear-gradient(90deg, rgba(248, 250, 252, 0.06), transparent 45%),
    linear-gradient(180deg, #3f4650, #1f2937);
  box-shadow: inset 8px 0 0 rgba(255, 255, 255, 0.05);
}

.asset-cube::before,
.asset-cube::after {
  content: "";
  position: absolute;
  left: 9px;
  right: 9px;
  height: 2px;
  background: rgba(148, 163, 184, 0.65);
}

.asset-cube::before {
  top: 18px;
}

.asset-cube::after {
  top: 32px;
}

.asset-card strong,
.asset-card span {
  display: block;
}

.asset-card strong {
  margin-bottom: 4px;
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
}

.asset-card span {
  color: #cbd5e1;
  font-size: 12px;
  line-height: 1.35;
}

.asset-card .operational {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
}

.asset-card .operational::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--green);
}

.workflow {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px;
}

.workflow-step {
  position: relative;
  min-height: 62px;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: rgba(15, 23, 42, 0.72);
}

.workflow-step:not(:last-child)::after {
  content: "→";
  position: absolute;
  right: -21px;
  top: 21px;
  color: var(--muted);
  font-size: 22px;
}

.workflow-step b {
  display: inline-grid;
  place-items: center;
  width: 19px;
  height: 19px;
  margin-right: 7px;
  border-radius: 6px;
  background: var(--blue-deep);
  color: white;
  font-size: 11px;
}

.workflow-step strong {
  color: var(--text);
  font-size: 13px;
}

.workflow-step span {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  font-size: 11px;
}

.tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 7px;
  margin-bottom: 12px;
}

.tab-button {
  min-height: 34px;
  background: rgba(2, 6, 23, 0.5);
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  cursor: pointer;
}

.tab-button.active {
  border-color: rgba(56, 189, 248, 0.55);
  background: rgba(37, 99, 235, 0.32);
  color: var(--text);
}

.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
}

.form-grid {
  display: grid;
  gap: 8px;
}

.two-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: rgba(2, 6, 23, 0.66);
  color: var(--text);
  padding: 9px 10px;
  outline: none;
  font-size: 13px;
}

textarea {
  min-height: 74px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: rgba(56, 189, 248, 0.72);
}

select option {
  color: #020617;
}

.record-list {
  margin-top: 10px;
}

.record {
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: rgba(2, 6, 23, 0.5);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.record strong {
  display: block;
  margin-bottom: 4px;
  color: var(--text);
  font-size: 13px;
}

.record small {
  display: block;
  margin-top: 7px;
  color: #64748b;
}

.record button {
  margin-top: 8px;
  min-height: 30px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: rgba(15, 23, 42, 0.78);
  color: var(--text);
  font-size: 12px;
  cursor: pointer;
}

.photo-gallery {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-top: 10px;
}

.photo-card {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: rgba(2, 6, 23, 0.58);
}

.photo-card img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.photo-card div {
  padding: 8px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.model-json {
  max-height: 220px;
  overflow: auto;
  margin: 0;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: rgba(2, 6, 23, 0.72);
  color: #cbd5e1;
  font-size: 11px;
  line-height: 1.45;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.closeout-card table {
  width: 100%;
  border-collapse: collapse;
  color: var(--muted);
  font-size: 12px;
}

.closeout-card th,
.closeout-card td {
  border-bottom: 1px solid var(--border);
  padding: 9px 7px;
  text-align: left;
  vertical-align: top;
}

.closeout-card th {
  color: #cbd5e1;
  font-size: 11px;
  font-weight: 850;
}

.status-badge {
  display: inline-flex;
  min-height: 23px;
  align-items: center;
  border-radius: 6px;
  background: rgba(22, 101, 52, 0.72);
  color: #dcfce7;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 850;
}

.privacy-card {
  display: grid;
  gap: 8px;
}

.privacy-card p {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.toast {
  position: fixed;
  z-index: 50;
  right: 18px;
  bottom: 18px;
  display: none;
  max-width: min(360px, calc(100vw - 36px));
  padding: 12px 14px;
  border: 1px solid rgba(34, 197, 94, 0.38);
  border-radius: 8px;
  background: #052e16;
  color: #dcfce7;
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.45);
  font-size: 13px;
  font-weight: 850;
}

.toast.visible {
  display: block;
}

.tag-overlay {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
}

.hotspot {
  pointer-events: auto;
}

.hotspot.layer-hidden {
  display: none;
}

.hotspot.asset span {
  background: var(--blue-deep);
}

.hotspot.safety span {
  background: var(--amber);
}

.hotspot.maintenance span {
  background: var(--green);
}

.hotspot.closeout span {
  background: #a78bfa;
}

.view-mode-overlay {
  position: absolute;
  z-index: 3;
  right: 24px;
  bottom: 132px;
  display: grid;
  gap: 6px;
  max-width: 300px;
  padding: 12px 14px;
  border: 1px solid rgba(56, 189, 248, 0.28);
  border-radius: 8px;
  background: rgba(2, 6, 23, 0.78);
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(14px);
}

.view-mode-overlay strong {
  color: var(--text);
  font-size: 13px;
}

.view-mode-overlay span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.viewer-region.view-2d .viewer-fallback,
.viewer-region.view-layers .viewer-fallback,
.viewer-region.view-vr .viewer-fallback {
  visibility: visible;
  opacity: 1;
}

.viewer-region.view-2d .fallback-message strong {
  font-size: 0;
}

.viewer-region.view-2d .fallback-message strong::after {
  content: "2D Map View";
  font-size: 17px;
}

.viewer-region.view-layers .fallback-message strong {
  font-size: 0;
}

.viewer-region.view-layers .fallback-message strong::after {
  content: "Layer Matrix View";
  font-size: 17px;
}

.viewer-region.view-vr .fallback-message strong {
  font-size: 0;
}

.viewer-region.view-vr .fallback-message strong::after {
  content: "VR Review Ready";
  font-size: 17px;
}

.editor-note {
  margin-bottom: 12px;
  padding: 10px;
  border: 1px solid rgba(56, 189, 248, 0.26);
  border-radius: 7px;
  background: rgba(56, 189, 248, 0.08);
  color: #bae6fd;
  font-size: 12px;
  line-height: 1.45;
}

.editor-block {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.editor-block h3 {
  margin: 0;
  color: var(--text);
  font-size: 13px;
  font-weight: 900;
  text-transform: uppercase;
}

.layer-record {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px;
}

.layer-swatch {
  width: 16px;
  height: 16px;
  border-radius: 999px;
  border: 1px solid rgba(248, 250, 252, 0.45);
}

.record-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.record-actions button {
  min-height: 28px;
  padding: 4px 8px;
}

.model-actions {
  margin-top: 10px;
}

.mode-select-active {
  outline: 1px solid rgba(56, 189, 248, 0.5);
}

@media (max-width: 1380px) {
  .workspace {
    grid-template-columns: minmax(0, 1fr) minmax(390px, 39vw);
  }

  .metric-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .split-panel {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1080px) {
  .workspace {
    grid-template-columns: 1fr;
  }

  .viewer-region,
  .viewer-region iframe {
    min-height: 720px;
    height: 720px;
  }

  .command-panel {
    max-height: none;
    border-left: 0;
    border-top: 1px solid var(--border-strong);
  }

  .hide-panel {
    margin-left: 0;
  }
}

@media (max-width: 760px) {
  .topbar,
  .brand-lockup,
  .viewer-controls {
    align-items: stretch;
    flex-direction: column;
  }

  .top-actions {
    align-self: flex-start;
  }

  .viewer-controls {
    position: static;
    padding: 10px;
    background: rgba(2, 6, 23, 0.92);
  }

  .meta-pill,
  .select-pill select {
    width: 100%;
  }

  .viewer-region,
  .viewer-region iframe {
    height: 620px;
    min-height: 620px;
  }

  .left-rail,
  .mini-map,
  .bottom-nav {
    display: none;
  }

  .tag-overlay,
  .view-mode-overlay {
    display: none;
  }

  .button-grid,
  .status-grid,
  .metric-grid,
  .workflow,
  .tabs,
  .two-columns,
  .photo-gallery {
    grid-template-columns: 1fr;
  }

  .workflow {
    gap: 8px;
  }

  .workflow-step::after {
    display: none;
  }
}
