/* ============================================================================
   Operal AG — GeoAI & Environmental Intelligence
   Boswellia sacra Cross-Region Satellite Showcase (Brand Guidelines v1.0)
   ============================================================================ */

@font-face {
  font-family: "Manrope";
  src: url("/boswellia-sacra/fonts/Manrope-VariableFont_wght.ttf") format("truetype");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #173B34;
  --deep: #102F29;
  --paper: #F9FAF6;
  --lime: #D8EFAD;
  --soft: #EEF1E9;
  --line: #D8DED3;
  --muted: #596860;
  --sage: #C5D7C0;
  --peach: #EFC8A4;
  --white: #FFFFFF;
  --font: "Manrope", Arial, sans-serif;
  --max-w: 1340px;
}

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

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  max-width: 100%;
  overflow-x: clip;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--paper);
  font-size: 16px;
  line-height: 1.55;
  font-weight: 400;
  font-feature-settings: "kern" 1;
  -webkit-font-smoothing: antialiased;
  max-width: 100%;
  overflow-x: clip;
}

img, svg, canvas {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select {
  font: inherit;
  color: inherit;
  border-radius: 0;
}

button {
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

.dark-surface :focus-visible {
  outline-color: var(--lime);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 8px;
  z-index: 200;
  padding: 10px 16px;
  background: var(--lime);
  color: var(--ink);
  font-weight: 600;
  font-size: 13px;
}
.skip-link:focus {
  left: 12px;
}

.wrap {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 56px);
}

/* ----------------------------------------------------------- Typography */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 11px;
  line-height: 1.25;
  font-weight: 650;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
  margin: 0 0 16px;
}
.eyebrow::before {
  content: "";
  width: 7px;
  height: 7px;
  background: currentColor;
  flex: none;
}
.dark-surface .eyebrow {
  color: var(--lime);
}

.display-h1 {
  margin: 0;
  font-size: clamp(38px, 5.4vw, 72px);
  line-height: 0.98;
  font-weight: 450;
  letter-spacing: -0.05em;
}
.display-h1 .accent {
  color: var(--lime);
}

.sec-h2 {
  margin: 0;
  font-size: clamp(28px, 3.6vw, 46px);
  line-height: 1.04;
  font-weight: 500;
  letter-spacing: -0.04em;
}
.sec-h2 .muted-line {
  color: var(--muted);
}
.dark-surface .sec-h2 .muted-line {
  color: var(--sage);
}

.lead {
  margin: 20px 0 0;
  font-size: clamp(16.5px, 1.4vw, 19.5px);
  line-height: 1.52;
  color: var(--muted);
  max-width: 760px;
}
.dark-surface .lead {
  color: rgba(255, 255, 255, 0.76);
}

.num-idx {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
}
.dark-surface .num-idx {
  color: var(--sage);
}

/* ----------------------------------------------------------- Buttons */
.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 13px 20px;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.1;
  border: 1px solid var(--ink);
  background: transparent;
  color: var(--ink);
  transition: background 0.16s ease, color 0.16s ease, border-color 0.16s ease;
}
.btn:hover {
  background: var(--ink);
  color: var(--white);
}

.btn-lime {
  background: var(--lime);
  border-color: var(--lime);
  color: var(--ink);
}
.btn-lime:hover {
  background: var(--white);
  border-color: var(--white);
  color: var(--ink);
}

.btn-ink {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--white);
}
.btn-ink:hover {
  background: var(--deep);
  border-color: var(--deep);
}

.btn-ghost-dark {
  border-color: rgba(255, 255, 255, 0.34);
  color: var(--white);
}
.btn-ghost-dark:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--white);
  color: var(--white);
}

/* ----------------------------------------------------------- Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 90;
  background: rgba(249, 250, 246, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 68px;
}
.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}
.brand-logo {
  width: 124px;
  height: auto;
}
.brand-divider {
  width: 1px;
  height: 22px;
  background: var(--ink);
  opacity: 0.35;
}
.brand-unit {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.02em;
}
.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
}
.site-nav a {
  font-size: 12.5px;
  font-weight: 550;
  color: var(--muted);
  white-space: nowrap;
  transition: color 0.15s;
}
.site-nav a:hover {
  color: var(--ink);
}
.site-nav a .nav-num {
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  margin-right: 4px;
  font-weight: 650;
}
.header-cta {
  padding: 10px 15px;
  font-size: 12.5px;
  white-space: nowrap;
}

/* ----------------------------------------------------------- Hero */
.hero {
  position: relative;
  background: var(--deep);
  color: var(--white);
  padding: clamp(54px, 7vw, 96px) 0 clamp(44px, 5vw, 68px);
  overflow: hidden;
}
.hero-rings {
  position: absolute;
  right: -180px;
  top: -140px;
  width: 780px;
  height: 780px;
  color: rgba(216, 239, 173, 0.12);
  pointer-events: none;
}
.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(320px, 0.82fr);
  gap: clamp(28px, 4vw, 56px);
  align-items: end;
}
.hero-card {
  background: rgba(23, 59, 52, 0.68);
  border: 1px solid rgba(255, 255, 255, 0.16);
  padding: 18px;
}
.hero-card-media {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: #081915;
}
.hero-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.loc-tag {
  position: absolute;
  left: 10px;
  bottom: 10px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  background: rgba(16, 47, 41, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.2);
  font-size: 10.5px;
  font-weight: 600;
  color: var(--white);
  font-variant-numeric: tabular-nums;
}
.loc-tag i {
  display: inline-grid;
  place-items: center;
  width: 13px;
  height: 13px;
  background: var(--lime);
  color: var(--ink);
  font-style: normal;
  font-weight: 800;
  font-size: 10px;
  line-height: 1;
}
.hero-card-caption {
  margin-top: 12px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.72);
}
.hero-card-caption strong {
  display: block;
  color: var(--white);
  font-weight: 600;
  margin-bottom: 2px;
}

.kpi-strip {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: clamp(38px, 5vw, 58px);
  border-top: 1px solid rgba(255, 255, 255, 0.24);
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}
.kpi-cell {
  padding: 22px 22px 22px 0;
}
.kpi-cell + .kpi-cell {
  padding-left: 22px;
  border-left: 1px solid rgba(255, 255, 255, 0.14);
}
.kpi-val {
  font-size: clamp(30px, 3.2vw, 44px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
  color: var(--white);
}
.kpi-val.lime {
  color: var(--lime);
}
.kpi-lbl {
  margin-top: 8px;
  font-size: 12.5px;
  line-height: 1.42;
  color: rgba(255, 255, 255, 0.68);
}

/* ----------------------------------------------------------- Sections */
.section {
  padding: clamp(58px, 7vw, 96px) 0;
  border-bottom: 1px solid var(--line);
}
.section.soft {
  background: var(--soft);
}
.section.dark-surface {
  background: var(--deep);
  color: var(--white);
  border-bottom-color: rgba(255, 255, 255, 0.14);
}

.section-top {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(260px, 0.85fr);
  gap: clamp(24px, 4vw, 56px);
  align-items: end;
  padding-bottom: 36px;
  border-bottom: 1.5px solid var(--ink);
  margin-bottom: 36px;
}
.dark-surface .section-top {
  border-bottom-color: rgba(255, 255, 255, 0.24);
}
.section-top p {
  margin: 0;
  font-size: 15px;
  line-height: 1.58;
  color: var(--muted);
}
.dark-surface .section-top p {
  color: rgba(255, 255, 255, 0.74);
}

/* ----------------------------------------------------------- Section 01: Open Inventory */
.inventory-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 28px;
}
.stat-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-top: 2px solid var(--ink);
  padding: 22px 24px;
}
.stat-card .card-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 10px;
}
.stat-card h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.stat-card .big-num {
  font-size: 34px;
  font-weight: 550;
  letter-spacing: -0.04em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.stat-card p {
  margin: 10px 0 0;
  font-size: 13.5px;
  color: var(--muted);
  line-height: 1.5;
}
.morpho-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
}
.tag-pill {
  display: inline-block;
  padding: 5px 9px;
  font-size: 11.5px;
  font-weight: 600;
  border: 1px solid var(--line);
  background: var(--soft);
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.tag-pill.lime {
  background: var(--lime);
  border-color: var(--lime);
}
.tag-pill.peach {
  background: var(--peach);
  border-color: var(--peach);
}

.plate-frame {
  background: var(--deep);
  border: 1px solid var(--ink);
  padding: 16px;
  color: var(--white);
}
.plate-frame img {
  width: 100%;
  height: auto;
}
.plate-caption {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.75);
}
.plate-caption a {
  color: var(--lime);
  font-weight: 600;
}
.plate-caption a:hover {
  text-decoration: underline;
}

/* ----------------------------------------------------------- Section 02: Transfer Loop */
.loop-split {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  gap: 28px;
  margin-bottom: 32px;
}
.panel-box {
  background: var(--paper);
  border: 1px solid var(--line);
  border-top: 2px solid var(--ink);
  padding: 24px 26px;
}
.panel-box h3 {
  margin: 4px 0 14px;
  font-size: 21px;
  font-weight: 550;
  letter-spacing: -0.025em;
}

.operal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
}
.operal-table th {
  text-align: left;
  font-size: 10.5px;
  font-weight: 650;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 0 10px 10px 0;
  border-bottom: 1.5px solid var(--ink);
}
.operal-table td {
  padding: 11px 10px 11px 0;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.operal-table th.num,
.operal-table td.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  padding-right: 0;
}
.operal-table tr.highlight-row td {
  background: rgba(216, 239, 173, 0.42);
  font-weight: 600;
}

.weight-bars {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 12px;
}
.w-row {
  display: grid;
  grid-template-columns: 185px minmax(0, 1fr) 48px;
  align-items: center;
  gap: 12px;
  font-size: 12.5px;
}
.w-row span:first-child {
  color: var(--ink);
  font-weight: 500;
}
.w-track {
  height: 10px;
  background: var(--soft);
  border: 1px solid var(--line);
  overflow: hidden;
}
.w-fill {
  display: block;
  height: 100%;
  background: var(--ink);
}
.w-fill.top {
  background: var(--ink);
}
.w-fill.lime-bar {
  background: var(--ink);
  box-shadow: inset -4px 0 0 var(--lime);
}
.w-fill.sage {
  background: var(--sage);
}
.w-pct {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  color: var(--muted);
}

.findings-three {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 28px;
}
.finding-card {
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 22px 24px;
}
.finding-card .num-idx {
  display: block;
  margin-bottom: 8px;
}
.finding-card h4 {
  margin: 0 0 10px;
  font-size: 17.5px;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.22;
}
.finding-card p {
  margin: 0;
  font-size: 13.5px;
  color: var(--muted);
  line-height: 1.52;
}

.worked-fig {
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 18px;
}
.worked-fig img {
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
}
.worked-fig figcaption {
  margin-top: 12px;
  font-size: 12.5px;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

/* ----------------------------------------------------------- Section 03: Interactive Workbench */
.workbench-mode-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  background: rgba(23, 59, 52, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.18);
  margin-bottom: 12px;
}
.domain-switch {
  display: inline-flex;
  flex-wrap: wrap;
  border: 1px solid rgba(255, 255, 255, 0.28);
}
.domain-btn {
  padding: 10px 16px;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.78);
  font-size: 12.5px;
  font-weight: 600;
}
.domain-btn + .domain-btn {
  border-left: 1px solid rgba(255, 255, 255, 0.22);
}
.domain-btn[aria-pressed="true"] {
  background: var(--lime);
  color: var(--ink);
}
.workbench-exports {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.util-btn {
  padding: 8px 12px;
  font-size: 11.5px;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(16, 47, 41, 0.7);
  color: var(--white);
}
.util-btn:hover {
  border-color: var(--lime);
  color: var(--lime);
}

.filter-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  padding: 12px 18px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.14);
  margin-bottom: 16px;
}
.tier-group {
  display: inline-flex;
  flex-wrap: wrap;
  border: 1px solid rgba(255, 255, 255, 0.24);
}
.tier-group button {
  border: 0;
  border-right: 1px solid rgba(255, 255, 255, 0.18);
  background: transparent;
  color: rgba(255, 255, 255, 0.78);
  padding: 7px 11px;
  font-size: 11.5px;
  font-weight: 550;
}
.tier-group button:last-child {
  border-right: 0;
}
.tier-group button[aria-pressed="true"] {
  background: var(--lime);
  color: var(--ink);
  font-weight: 650;
}
.slider-box {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11.5px;
  color: rgba(255, 255, 255, 0.8);
}
.slider-box output {
  color: var(--lime);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  min-width: 32px;
}
.slider-box input[type="range"] {
  width: 96px;
  accent-color: var(--lime);
}
.chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.ev-chip {
  padding: 6px 10px;
  font-size: 11px;
  font-weight: 550;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: transparent;
  color: rgba(255, 255, 255, 0.78);
}
.ev-chip[aria-pressed="true"] {
  background: var(--sage);
  border-color: var(--sage);
  color: var(--ink);
  font-weight: 650;
}
.filter-readout {
  margin-left: auto;
  font-size: 11.5px;
  font-variant-numeric: tabular-nums;
  color: var(--lime);
  font-weight: 600;
}

.workbench-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 396px;
  gap: 16px;
  align-items: stretch;
}
.map-stage {
  position: relative;
  height: 640px;
  background: #081814;
  border: 1px solid rgba(255, 255, 255, 0.2);
  overflow: hidden;
}
#geoCanvas {
  width: 100%;
  height: 100%;
  cursor: grab;
  touch-action: none;
}
#geoCanvas:active {
  cursor: grabbing;
}

.map-nav-btns {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 3;
  display: flex;
  gap: 4px;
}
.map-nav-btns button,
.map-next-btn {
  padding: 7px 11px;
  font-size: 11.5px;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(16, 47, 41, 0.88);
  color: var(--white);
  backdrop-filter: blur(6px);
}
.map-nav-btns button:hover,
.map-next-btn:hover {
  border-color: var(--lime);
  color: var(--lime);
}
.map-layer-bar {
  position: absolute;
  top: 52px;
  left: 12px;
  z-index: 3;
  display: flex;
  gap: 3px;
  padding: 3px;
  background: rgba(16, 47, 41, 0.9);
  border: 1px solid rgba(255, 255, 255, 0.22);
}
.map-layer-bar button {
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.76);
  padding: 6px 10px;
  font-size: 11px;
  font-weight: 550;
  white-space: nowrap;
}
.map-layer-bar button[aria-pressed="true"] {
  background: var(--lime);
  color: var(--ink);
  font-weight: 650;
}
.map-next-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 3;
}
.map-legend {
  position: absolute;
  left: 12px;
  bottom: 38px;
  z-index: 3;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding: 6px 10px;
  background: rgba(16, 47, 41, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 10.5px;
  color: rgba(255, 255, 255, 0.85);
}
.map-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.map-legend i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  display: inline-block;
}
.lg-high { background: rgba(216, 239, 173, 0.35); border: 2px solid var(--lime); }
.lg-med { background: rgba(197, 215, 192, 0.25); border: 2px solid var(--sage); }
.lg-low { background: rgba(239, 200, 164, 0.25); border: 2px solid var(--peach); }
.lg-ref { background: rgba(255, 255, 255, 0.2); border: 2px solid var(--white); }

.map-coords {
  position: absolute;
  right: 12px;
  bottom: 38px;
  z-index: 3;
  padding: 5px 10px;
  background: rgba(16, 47, 41, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 10.5px;
  font-variant-numeric: tabular-nums;
  color: var(--lime);
}
.map-scale {
  position: absolute;
  right: 12px;
  bottom: 70px;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 4px 8px;
  background: rgba(16, 47, 41, 0.86);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  color: var(--white);
}
.map-scale span {
  display: inline-block;
  width: 64px;
  height: 4px;
  border: 1.5px solid var(--white);
  border-top: 0;
}
.map-credit {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 9px;
  z-index: 3;
  font-size: 9.5px;
  color: rgba(255, 255, 255, 0.66);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  pointer-events: none;
}

/* Inspector Sidebar */
.inspector-card {
  background: var(--paper);
  color: var(--ink);
  border: 1px solid var(--line);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 11px;
}
.insp-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.insp-badge {
  padding: 4px 8px;
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  background: var(--soft);
  border: 1px solid var(--line);
  color: var(--ink);
}
.insp-badge[data-tier="high"] {
  background: var(--lime);
  border-color: var(--ink);
}
.insp-id {
  font-size: 11px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.insp-title-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
}
.insp-title-row h3 {
  margin: 0;
  font-size: 28px;
  font-weight: 550;
  letter-spacing: -0.035em;
  line-height: 1.05;
}
.insp-coords {
  margin: -4px 0 0;
  font-size: 12px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.loupe-box {
  border: 1px solid var(--ink);
  background: #081814;
}
#loupeCanvas {
  width: 100%;
  height: 144px;
}
.loupe-labels {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  background: var(--deep);
  color: var(--white);
  font-size: 10px;
}
.loupe-labels span {
  padding: 5px 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.loupe-labels span:first-child {
  border-right: 1px solid rgba(255, 255, 255, 0.16);
}

.prob-box {
  background: var(--soft);
  border: 1px solid var(--line);
  padding: 12px;
}
.prob-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 8px;
}
.prob-kicker {
  display: block;
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.prob-score-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-top: 2px;
}
.prob-score-row strong {
  font-size: 30px;
  font-weight: 600;
  letter-spacing: -0.035em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.prob-score-row small {
  font-size: 12px;
  color: var(--muted);
}
.delta-pill {
  padding: 3px 7px;
  font-size: 10.5px;
  font-weight: 650;
  background: var(--lime);
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.delta-pill[data-neg="true"] {
  background: var(--peach);
}

.bio-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin: 10px 0;
  padding: 8px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  font-size: 10.5px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.bio-grid b {
  display: block;
  font-size: 12.5px;
  color: var(--ink);
  font-weight: 650;
}

.factor-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 10px;
}
.f-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.f-head {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.f-head b {
  color: var(--ink);
}
.f-bar {
  height: 5px;
  background: var(--line);
}
.f-bar i {
  display: block;
  height: 100%;
  background: var(--ink);
}

.twin-card {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  background: var(--white);
  border: 1px solid var(--line);
}
.twin-card img {
  width: 54px;
  height: 54px;
  object-fit: cover;
  border: 1px solid var(--line);
}
.twin-meta {
  min-width: 0;
}
.twin-meta span {
  display: block;
  font-size: 9.5px;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.twin-meta strong {
  display: block;
  font-size: 12.5px;
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.twin-meta small {
  display: block;
  font-size: 11px;
  color: var(--muted);
}
.twin-link {
  padding: 6px 9px;
  font-size: 11px;
  font-weight: 600;
  border: 1px solid var(--ink);
  background: var(--paper);
  color: var(--ink);
  white-space: nowrap;
}
.twin-link:hover {
  background: var(--ink);
  color: var(--white);
}

.insp-note {
  margin: auto 0 0;
  font-size: 11.5px;
  line-height: 1.45;
  color: var(--muted);
}

.candidate-rail-box {
  margin-top: 14px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.14);
}
.rail-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 10px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.78);
}
.rail-top strong {
  color: var(--white);
  font-size: 13.5px;
}
.cand-rail {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
  scrollbar-width: thin;
}
.cand-chip {
  flex: 0 0 auto;
  min-width: 134px;
  padding: 8px 11px;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(16, 47, 41, 0.85);
  color: var(--white);
}
.cand-chip[aria-selected="true"] {
  border-color: var(--lime);
  background: rgba(216, 239, 173, 0.16);
}
.cand-chip strong {
  display: block;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.cand-chip small {
  display: block;
  margin-top: 2px;
  font-size: 10.5px;
  color: var(--sage);
}

/* ----------------------------------------------------------- Section 04: 7-Sensor Comparator */
.comp-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.comp-tab {
  padding: 9px 14px;
  font-size: 12.5px;
  font-weight: 600;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--muted);
}
.comp-tab[aria-pressed="true"] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--white);
}

.comp-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  gap: 24px;
  align-items: start;
}
.curtain-stage {
  --split: 50%;
  position: relative;
  aspect-ratio: 4 / 3;
  max-height: 540px;
  width: 100%;
  background: var(--deep);
  border: 1px solid var(--ink);
  overflow: hidden;
  user-select: none;
  touch-action: pan-y;
}
.curtain-stage img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}
.curtain-before {
  clip-path: inset(0 calc(100% - var(--split)) 0 0);
}
.curtain-line {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--split);
  width: 2px;
  background: var(--lime);
  pointer-events: none;
}
.curtain-knob {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  background: var(--deep);
  border: 1.5px solid var(--lime);
  color: var(--lime);
  display: grid;
  place-items: center;
  font-size: 15px;
  font-weight: 700;
}
.curtain-lbl {
  position: absolute;
  top: 12px;
  z-index: 2;
  padding: 6px 10px;
  background: rgba(16, 47, 41, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: var(--white);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  max-width: 44%;
}
.curtain-lbl.left { left: 12px; }
.curtain-lbl.right { right: 12px; text-align: right; color: var(--lime); }
.curtain-slider-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 10px;
  font-size: 12px;
  color: var(--muted);
}
.curtain-slider-row input[type="range"] {
  flex: 1;
  accent-color: var(--ink);
}

/* ----------------------------------------------------------- Section 05: Transfer Applications & Guardrails */
.transfer-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 28px;
}
.transfer-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-top: 2px solid var(--ink);
  padding: 24px;
}
.transfer-card h3 {
  margin: 8px 0 10px;
  font-size: 19px;
  font-weight: 550;
  letter-spacing: -0.02em;
}
.transfer-card p {
  margin: 0;
  font-size: 13.5px;
  color: var(--muted);
  line-height: 1.52;
}

.guardrail-callout {
  background: var(--paper);
  border: 1px solid var(--ink);
  padding: 22px 26px;
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}
.guardrail-callout strong {
  display: block;
  font-size: 14px;
  font-weight: 650;
}
.guardrail-callout p {
  margin: 0;
  font-size: 13.5px;
  color: var(--muted);
  line-height: 1.55;
}

/* ----------------------------------------------------------- Closing CTA & Footer */
.cta-band {
  background: var(--deep);
  color: var(--white);
  padding: clamp(56px, 7vw, 88px) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}
.cta-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) auto;
  gap: 32px;
  align-items: end;
}

.site-footer {
  background: var(--deep);
  color: rgba(255, 255, 255, 0.72);
  padding: 36px 0 48px;
  font-size: 12.5px;
}
.footer-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}
.footer-brand img {
  width: 112px;
}
.footer-tagline {
  color: var(--lime);
  font-weight: 550;
  letter-spacing: 0.02em;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}
.footer-links a:hover {
  color: var(--white);
  text-decoration: underline;
}

/* ----------------------------------------------------------- Responsive */
@media (max-width: 1120px) {
  .site-nav {
    display: none;
  }
  .hero-grid,
  .section-top,
  .loop-split,
  .workbench-grid,
  .comp-layout,
  .cta-inner {
    grid-template-columns: minmax(0, 1fr);
  }
  .kpi-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .kpi-cell:nth-child(3) {
    padding-left: 0;
    border-left: 0;
  }
  .kpi-cell:nth-child(-n+2) {
    border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  }
  .inventory-grid,
  .findings-three,
  .transfer-grid {
    grid-template-columns: 1fr;
  }
  .guardrail-callout {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}

@media (max-width: 640px) {
  .wrap {
    padding: 0 16px;
  }
  .header-inner {
    min-height: 58px;
    gap: 10px;
  }
  .brand-logo {
    width: 104px;
  }
  .brand-divider,
  .brand-unit {
    display: none;
  }
  .header-cta {
    padding: 8px 12px;
    font-size: 11.5px;
  }
  .kpi-strip {
    grid-template-columns: 1fr;
  }
  .kpi-cell,
  .kpi-cell + .kpi-cell {
    padding: 16px 0;
    border-left: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.14);
  }
  .kpi-cell:last-child {
    border-bottom: 0;
  }
  .w-row {
    grid-template-columns: 1fr 44px;
    gap: 4px 10px;
  }
  .w-track {
    grid-column: 1 / -1;
  }
  .domain-switch,
  .domain-btn {
    width: 100%;
  }
  .domain-btn + .domain-btn {
    border-left: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.22);
  }
  .tier-group {
    width: 100%;
  }
  .tier-group button {
    flex: 1 1 auto;
    padding: 7px 8px;
    font-size: 11px;
  }
  .slider-box {
    width: 100%;
    justify-content: space-between;
  }
  .slider-box input[type="range"] {
    flex: 1;
    max-width: 160px;
  }
  .filter-readout {
    margin-left: 0;
    width: 100%;
  }
  .map-stage {
    height: 500px;
  }
  .map-nav-btns {
    left: 8px;
    right: 8px;
    top: 8px;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .map-nav-btns button {
    flex: 0 0 auto;
    white-space: nowrap;
    padding: 6px 9px;
    font-size: 10.5px;
  }
  .map-layer-bar {
    left: 8px;
    right: 8px;
    top: 44px;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .map-next-btn {
    top: 82px;
    right: 8px;
    padding: 6px 9px;
    font-size: 10.5px;
  }
  .map-legend {
    display: none;
  }
  .map-coords {
    right: 8px;
    bottom: 30px;
    font-size: 9.5px;
  }
  .map-scale {
    right: 8px;
    bottom: 60px;
  }
  .bio-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .panel-box {
    padding: 18px 14px;
    overflow-x: auto;
    min-width: 0;
  }
  .operal-table {
    font-size: 11px;
  }
  .operal-table th,
  .operal-table td {
    padding-right: 6px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
