:root {
  --explorer-width: 230px;
  --inspector-width: 270px;
  --timeline-height: 132px;
}
.header {
  height: 58px;
  padding: 0 20px;
  gap: 25px;
}
.brand {
  font-size: calc(18px * var(--text-scale, 1));
  min-width: 200px;
}
.brand img {
  width: 33px;
  height: 33px;
}
.brand small {
  font-size: calc(8px * var(--text-scale, 1));
}
.breadcrumb {
  font-size: calc(10px * var(--text-scale, 1));
}
.workspace {
  height: calc(100dvh - 58px);
  min-height: 0;
  grid-template-columns: 66px var(--explorer-width) minmax(0, 1fr);
}
.rail {
  overflow: auto;
  padding-top: 12px;
  gap: 3px;
  scrollbar-width: thin;
}
.rail-button {
  width: 49px;
  min-height: 50px;
  flex-shrink: 0;
}
.rail-button > span {
  font-size: calc(21px * var(--text-scale, 1));
}
.rail-button small {
  font-size: calc(8px * var(--text-scale, 1));
}
.rail-bottom {
  padding-top: 18px;
  gap: 2px;
}
.section-rail {
  display: grid;
  gap: 2px;
}
.explorer {
  padding: 16px 10px 12px;
  min-height: 0;
  overflow: hidden;
}
.explorer-heading h2 {
  margin-bottom: 14px;
}
.asset-tree {
  max-height: none;
  flex: 1;
  min-height: 0;
}
.explorer-footer {
  padding: 10px 2px;
}
.explorer-tabs {
  margin-top: 8px;
}
.explorer-heading .eyebrow {
  font-size: calc(8px * var(--text-scale, 1));
}
.main-content {
  display: flex;
  flex-direction: column;
  position: relative;
  padding: 10px 12px 0;
  min-height: 0;
  gap: 9px;
  overflow: hidden;
}
.page-heading {
  margin: 0;
  min-height: 26px;
  max-height: 30px;
}
.page-heading > div > .eyebrow,
.page-heading .subtitle,
.page-heading h1 > span {
  display: none;
}
.page-heading h1 {
  font-size: calc(13px * var(--text-scale, 1));
  margin: 0;
  letter-spacing: -0.2px;
}
.page-heading .primary {
  padding: 6px 11px;
  font-size: calc(9px * var(--text-scale, 1));
}
.command-bar {
  height: 35px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-shrink: 0;
}
.work-domain {
  display: flex;
  align-items: center;
  gap: 9px;
}
.work-domain > .eyebrow {
  font-size: calc(8px * var(--text-scale, 1));
  color: #408262;
}
.work-domain select {
  border: 0;
  background: transparent;
  color: #345d49;
  font-size: calc(12px * var(--text-scale, 1));
  font-weight: 600;
  max-width: 250px;
}
.status-pill {
  font-size: calc(7px * var(--text-scale, 1));
  border: 1px solid #cbdcc1;
  border-radius: 5px;
  padding: 4px 6px;
  color: #729466;
}
.layout-buttons {
  display: flex;
  gap: 3px;
}
.layout-buttons button {
  padding: 6px 9px;
  font-size: calc(9px * var(--text-scale, 1));
  border-radius: 6px;
  color: #8a9a7d;
}
.layout-buttons button.active {
  background: #e0ecd6;
  color: #3e7750;
}
.content-grid {
  flex: 1;
  min-height: 0;
  grid-template-columns: minmax(0, 1fr) var(--inspector-width);
  gap: 12px;
  position: relative;
}
.viewport-panel {
  height: 100%;
  min-height: 0;
  min-width: 0;
}
.inspector {
  height: 100%;
  overflow: auto;
  scrollbar-width: thin;
  padding: 15px 17px;
  display: block;
}
.inspector h2 {
  font-size: calc(17px * var(--text-scale, 1));
}
.inspector .asset-symbol {
  margin-top: 12px;
  width: 36px;
  height: 36px;
  font-size: calc(22px * var(--text-scale, 1));
}
.inspector .measurement {
  padding-top: 12px;
}
.measurement strong {
  font-size: calc(31px * var(--text-scale, 1));
}
.inspector-badges {
  margin: 12px 0;
}
.chart-heading {
  margin-top: 17px;
}
.detail-rows {
  margin: 15px 0;
}
.detail-rows > div {
  margin: 10px 0;
}
.inspector-actions {
  display: grid;
  gap: 6px;
  margin-top: 10px;
}
.timeline-panel {
  flex-shrink: 0;
  height: var(--timeline-height);
  min-height: 100px;
  margin-top: 0;
  padding: 12px 16px;
  position: relative;
}
.timeline-body {
  height: calc(100% - 30px);
  margin-top: 3px;
}
.workspace-footer {
  padding: 4px 0 8px;
  min-height: 22px;
  flex-shrink: 0;
  gap: 8px;
}
.workspace-footer > span:nth-child(2) {
  display: none;
}
.timeline-heading input,
.timeline-heading select {
  font-size: calc(9px * var(--text-scale, 1));
  background: #f6f9f0;
  border: 1px solid #dbe5ce;
  border-radius: 4px;
  padding: 3px;
  color: #688056;
}
.timeline-heading #timeline-date {
  display: none;
}
.timeline-grip {
  position: absolute;
  left: 40%;
  right: 40%;
  height: 8px;
  top: -5px;
  border-top: 3px solid #b9cba8;
  cursor: ns-resize;
  touch-action: none;
}
.resize-grip {
  position: absolute;
  z-index: 8;
  touch-action: none;
}
.explorer-grip {
  left: 0;
  top: 90px;
  bottom: 170px;
  width: 6px;
  cursor: ew-resize;
}
.inspector-grip {
  right: calc(var(--inspector-width) + 3px);
  top: 0;
  bottom: 0;
  width: 7px;
  cursor: ew-resize;
}
.resize-grip:hover {
  background: #7aab5b44;
}
.viewport-top {
  padding: 10px 12px;
}
.viewport-top .viewport-id {
  font-size: calc(7px * var(--text-scale, 1));
}
#viewport,
#viewport-labels {
  top: 48px;
}
.kpis {
  margin: 0 12px;
  gap: 7px;
  position: absolute;
  left: 0;
  right: 0;
  top: 54px;
  pointer-events: none;
}
.kpis article {
  padding: 9px 12px;
  backdrop-filter: blur(7px);
  background: #fffef6d9;
}
.kpis article > div {
  font-size: calc(22px * var(--text-scale, 1));
  margin: 5px 0;
}
.kpis article > span {
  font-size: calc(9px * var(--text-scale, 1));
}
.kpis footer {
  font-size: calc(7px * var(--text-scale, 1));
}
.viewport-tools {
  top: 150px;
  left: 12px;
}
.viewport-heading-chip {
  position: absolute;
  bottom: 14px;
  right: 13px;
  display: flex;
  gap: 8px;
  align-items: center;
  color: #7e9271;
  background: #f9fcefce;
  border: 1px solid #d6e4c7;
  border-radius: 6px;
  padding: 4px 6px;
  font-size: calc(9px * var(--text-scale, 1));
  z-index: 3;
}
.viewport-heading-chip button {
  font-size: calc(18px * var(--text-scale, 1));
  line-height: 18px;
}
.compass {
  bottom: 54px;
  right: 16px;
}
.exploration {
  bottom: 51px;
  left: 12px;
  padding: 8px 10px;
}
.viewport-guide {
  bottom: 12px;
  left: 12px;
}
.viewport-guide > span:last-child {
  display: none;
}
.viewport-status {
  top: 160px;
}
.footer-links {
  display: flex;
  gap: 7px;
  margin-left: auto;
}
.footer-links button {
  font-size: calc(8px * var(--text-scale, 1));
  color: #7e946f;
}
#tree-mode {
  margin-top: 10px;
  width: 100%;
  font-size: calc(10px * var(--text-scale, 1));
  padding: 7px;
  border: 1px solid #dce5d1;
  background: #f9fcf4;
  border-radius: 6px;
  color: #6f8560;
}
.tree-level {
  display: block;
  font-size: calc(8px * var(--text-scale, 1));
  color: #9aaa89;
  margin-top: 3px;
}
.pyramid-key {
  font-size: calc(7px * var(--text-scale, 1));
  letter-spacing: 0.6px;
  color: #8da07c;
  padding: 8px 4px;
}
.bim-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 10px;
}
.bim-toolbar .small-button {
  font-size: calc(8px * var(--text-scale, 1));
  padding: 5px;
}
.bim-row {
  display: flex;
  align-items: center;
  border-bottom: 1px solid #e6ecdd;
  gap: 2px;
}
.bim-row button:first-child {
  flex: 1;
  text-align: left;
  font-size: calc(9px * var(--text-scale, 1));
  overflow: hidden;
  text-overflow: ellipsis;
  padding: 9px 2px;
  min-width: 0;
}
.bim-row small {
  display: block;
  font-size: calc(7px * var(--text-scale, 1));
  color: #9aac8e;
}
.bim-row > button:not(:first-child) {
  font-size: calc(13px * var(--text-scale, 1));
  padding: 5px;
  color: #71965d;
}
.section-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}
.section-cards button {
  border: 1px solid #dbe5ce;
  border-radius: 8px;
  padding: 13px;
  text-align: left;
  background: #f6faee;
}
.section-cards strong {
  display: block;
  margin: 4px 0;
  font-size: calc(12px * var(--text-scale, 1));
}
.section-cards small,
.section-cards span {
  font-size: calc(9px * var(--text-scale, 1));
  color: #93a382;
}
.layout-preset-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.assistant-fab {
  position: fixed;
  right: 20px;
  bottom: 30px;
  border-radius: 13px;
  border: 1px solid #bed2ae;
  background: #f4fbece8;
  box-shadow: 0 6px 25px #193e2315;
  padding: 9px 13px;
  z-index: 6;
  display: grid;
  grid-template-columns: 25px 1fr;
  gap: 0 6px;
  text-align: left;
}
.assistant-fab > span {
  grid-row: 1/3;
  font-size: calc(23px * var(--text-scale, 1));
  color: #759f55;
}
.assistant-fab b {
  font-size: calc(9px * var(--text-scale, 1));
  font-weight: 600;
}
.assistant-fab small {
  font-size: calc(8px * var(--text-scale, 1));
  color: #98aa85;
}
.ai-placeholder > span {
  font-size: calc(40px * var(--text-scale, 1));
  color: #7baa59;
}
.ai-placeholder textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #dbe5ce;
  border-radius: 6px;
}
.ai-placeholder > .primary {
  margin-top: 12px;
}
#map-viewport {
  position: absolute;
  inset: 0;
  z-index: 4;
  background: #edf3e5;
}
#leaflet-map {
  width: 100%;
  height: 100%;
  border-radius: 14px;
}
.map-notice {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px;
  text-align: center;
  color: #7b9169;
}
.map-notice p {
  max-width: 360px;
  font-size: calc(12px * var(--text-scale, 1));
  line-height: 1.8;
}
.map-context-tools {
  position: absolute;
  left: 50px;
  top: 12px;
  z-index: 1000;
  display: flex;
  gap: 5px;
}
.map-context-tools button {
  background: #fafff3;
  border: 1px solid #cdddbc;
  border-radius: 6px;
  padding: 8px 12px;
  font-size: calc(10px * var(--text-scale, 1));
}
#analytics-stage {
  position: relative;
  max-width: 100%;
  margin-top: 12px;
}
#analytics-canvas {
  max-width: 100%;
  display: block;
  max-height: 360px;
  object-fit: contain;
  background: #e9f0e0;
}
#analytics-video {
  width: 100%;
  max-height: 280px;
}
.footer-links {
  padding-right: 145px;
}
.locked .workspace,
.locked .header,
.locked .assistant-fab {
  display: none !important;
}
.lock-screen {
  height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: radial-gradient(ellipse at 50% 40%, #dfedce, #f5f8ef 65%);
  gap: 10px;
}
.lock-screen img {
  width: 66px;
  height: 66px;
}
.lock-screen h1 {
  font-size: calc(30px * var(--text-scale, 1));
  letter-spacing: 2px;
  margin: 10px;
}
.lock-screen p {
  color: #92a381;
  font-size: calc(12px * var(--text-scale, 1));
}
.lock-screen small {
  font-size: calc(9px * var(--text-scale, 1));
  letter-spacing: 2px;
  color: #a0ad93;
}
.locked dialog {
  width: min(520px, 94vw);
}
body:not(.locked) .lock-screen {
  display: none;
}
body[data-layout="focus"] .explorer,
body.hide-explorer .explorer {
  display: none;
}
body[data-layout="focus"] .workspace,
body.hide-explorer .workspace {
  grid-template-columns: 66px minmax(0, 1fr);
}
body[data-layout="focus"] .content-grid,
body.hide-inspector .content-grid {
  grid-template-columns: minmax(0, 1fr);
}
body[data-layout="focus"] .inspector,
body[data-layout="focus"] .inspector-grip,
body.hide-inspector .inspector,
body.hide-inspector .inspector-grip {
  display: none;
}
body[data-layout="focus"] .page-heading,
body[data-layout="focus"] .kpis,
body[data-layout="bim"] .kpis {
  display: none;
}
body[data-layout="focus"] .viewport-tools,
body[data-layout="bim"] .viewport-tools {
  top: 70px;
}
body.inspector-left .inspector {
  grid-column: 1;
  grid-row: 1;
}
body.inspector-left .content-grid {
  grid-template-columns: var(--inspector-width) minmax(0, 1fr);
}
body.inspector-left .viewport-panel {
  grid-column: 2;
  grid-row: 1;
}
body.inspector-left .inspector-grip {
  left: calc(var(--inspector-width) + 3px);
  right: auto;
}
body[data-layout="map"] .compass {
  display: none;
}
@media (max-width: 1100px) {
  :root {
    --explorer-width: 190px;
    --inspector-width: 230px;
  }
  .work-domain > .eyebrow {
    display: none;
  }
  .status-pill {
    display: none;
  }
  .layout-buttons button {
    padding: 6px;
  }
  .page-heading h1 {
    font-size: calc(11px * var(--text-scale, 1));
  }
  .content-grid {
    grid-template-columns: minmax(0, 1fr) var(--inspector-width);
  }
  .inspector {
    display: block;
  }
  .header .breadcrumb {
    display: none;
  }
  .kpis article {
    padding: 7px;
  }
  .kpis article > div {
    font-size: calc(18px * var(--text-scale, 1));
  }
  .kpis footer {
    display: none;
  }
  .assistant-fab {
    right: 14px;
    bottom: 26px;
    padding: 7px 9px;
  }
}
@media (max-width: 800px) {
  .workspace {
    grid-template-columns: 52px minmax(0, 1fr);
  }
  .explorer,
  .explorer-grip {
    display: none;
  }
  .content-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .inspector,
  .inspector-grip {
    display: none;
  }
  .rail {
    width: 52px;
  }
  .rail-button {
    width: 43px;
  }
  .main-content {
    padding: 7px 8px 0;
    gap: 6px;
  }
  .command-bar {
    height: 31px;
  }
  .work-domain select {
    font-size: calc(10px * var(--text-scale, 1));
    max-width: 190px;
  }
  .layout-buttons button {
    font-size: calc(8px * var(--text-scale, 1));
    padding: 5px;
  }
  .header {
    padding: 0 13px;
    height: 50px;
  }
  .workspace {
    height: calc(100dvh - 50px);
  }
  .header .brand {
    font-size: calc(17px * var(--text-scale, 1));
    min-width: 0;
  }
  .page-heading {
    max-height: 24px;
  }
  .page-heading h1 {
    font-size: calc(10px * var(--text-scale, 1));
  }
  .page-heading .primary {
    font-size: calc(8px * var(--text-scale, 1));
  }
  .timeline-panel {
    padding: 10px;
    height: 125px;
  }
  .timeline-heading input,
  .timeline-heading select {
    font-size: calc(8px * var(--text-scale, 1));
    padding: 2px;
    max-width: 100px;
  }
  .timeline-heading > div {
    gap: 5px;
  }
  .time-readout {
    min-width: 60px;
  }
  .timeline-ticks {
    font-size: calc(7px * var(--text-scale, 1));
  }
  .workspace-footer > span {
    font-size: calc(6px * var(--text-scale, 1));
  }
  .workspace-footer > span:last-of-type {
    display: none;
  }
  .footer-links {
    padding-right: 0;
    gap: 4px;
  }
  .footer-links button {
    font-size: calc(7px * var(--text-scale, 1));
  }
  .assistant-fab {
    right: 11px;
    bottom: 160px;
  }
  .assistant-fab b,
  .assistant-fab small {
    display: none;
  }
  .assistant-fab {
    display: block;
  }
  .assistant-fab > span {
    font-size: calc(20px * var(--text-scale, 1));
  }
  .viewport-heading-chip {
    max-width: 45%;
    font-size: calc(8px * var(--text-scale, 1));
  }
  .viewport-heading-chip > span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .exploration {
    max-width: 190px;
  }
  .exploration small {
    font-size: calc(7px * var(--text-scale, 1));
  }
  .exploration strong {
    font-size: calc(8px * var(--text-scale, 1));
  }
  .progress-circle {
    margin-left: 0;
  }
  .section-cards {
    grid-template-columns: 1fr;
  }
  .viewport-tools {
    top: 139px;
  }
  .viewport-status {
    inset: 145px 50px auto;
  }
  .kpis {
    top: 51px;
  }
  .viewport-top {
    padding: 8px;
  }
  .segmented button {
    font-size: calc(8px * var(--text-scale, 1));
    padding: 7px 9px;
  }
}
[hidden] {
  display: none !important;
}
.feature-entry {
  border-bottom: 1px solid #dce4d3;
  padding: 14px 0;
}
.feature-entry h3 {
  margin: 5px 0;
}
.feature-entry p {
  line-height: 1.6;
}
.booklet-content {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font:
    calc(14px * var(--text-scale, 1))/1.8 ui-monospace,
    monospace;
  color: #304c40;
}
body.inspector-left[data-layout="focus"] .content-grid,
body.inspector-left.hide-inspector .content-grid {
  grid-template-columns: minmax(0, 1fr);
}
body.inspector-left[data-layout="focus"] .viewport-panel,
body.inspector-left.hide-inspector .viewport-panel {
  grid-column: 1;
}
body[data-layout="focus"] .explorer-grip,
body.hide-explorer .explorer-grip {
  display: none;
}
