/* Dead Reckoning — x-ray harness hero (pre-rendered video) */

.xr-hero {
  position: relative; overflow: hidden;
  height: calc(100svh - 64px); min-height: 620px; max-height: 1180px;
  background: #0b0a08;
  isolation: isolate;
  --xr-pad: clamp(20px, 3vw, 48px);
}
.xr-media { position: absolute; inset: 0; }
.xr-v {
  position: absolute; inset: 0; width: 100%; height: 100%; display: block;
  object-fit: cover; object-position: 50% 50%;
  background: #0b0a08;
  opacity: 0; transition: opacity .7s ease;
}
.xr-v.on { opacity: 1; }
.xr-leaders { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 2; overflow: visible; }
.xr-leaders polyline { fill: none; stroke: rgba(245,241,232,0.5); stroke-width: 1; }
.xr-leaders circle { fill: #0b0a08; stroke: #E8963F; stroke-width: 1.5; }
.xr-labels { position: absolute; inset: 0; pointer-events: none; z-index: 3; }
.xr-label {
  position: absolute; left: 0; top: 0;
  display: flex; flex-wrap: wrap; column-gap: 8px; row-gap: 3px; align-items: baseline;
  padding: 5px 9px 6px;
  background: linear-gradient(90deg, rgba(11,10,8,0.62), rgba(11,10,8,0.12));
  border-left: 2px solid #C97A32;
  font: 500 11px/1.2 var(--mono); letter-spacing: 0.08em; text-transform: uppercase;
  white-space: nowrap; opacity: 0; will-change: transform, opacity;
}
.xr-label.focus { border-left-color: #E8963F; background: rgba(40,26,12,0.75); }
.xr-l-id { color: #E8963F; }
.xr-l-t { color: var(--ink); font-weight: 600; }
.xr-l-s { flex-basis: 100%; color: rgba(245,241,232,0.62); letter-spacing: 0.05em; text-transform: none; font-size: 11.5px; }

.xr-scantag {
  position: absolute; left: 0; top: 18px; z-index: 3; pointer-events: none;
  font: 500 10.5px/1 var(--mono); letter-spacing: 0.14em; text-transform: uppercase;
  opacity: 0; will-change: transform;
}
.xr-scantag > * { padding: 6px 8px; }
.xr-st-l { position: absolute; right: calc(50% + 34px); color: rgba(185,210,255,0.85); white-space: nowrap; transition: opacity .3s; }
.xr-st-r { position: absolute; left: calc(50% + 34px); color: rgba(245,241,232,0.7); white-space: nowrap; transition: opacity .3s; }
.xr-scantag b {
  position: absolute; left: 0; transform: translateX(-50%);
  font-weight: 600; color: #0b0a08; background: #F5D9B8; border-radius: 1px;
  font-variant-numeric: tabular-nums; letter-spacing: 0.06em;
}
.xr-st-l::before { content: '◂ '; } .xr-st-r::after { content: ' ▸'; }
.xr-scantag.no-r .xr-st-r, .xr-scantag.no-l .xr-st-l { opacity: 0; }

/* legend sits on the footage */
.xr-legend {
  position: absolute; z-index: 4; right: var(--xr-pad); bottom: clamp(28px, 5vh, 56px);
  list-style: none; display: grid; gap: 8px;
  font: 500 11px/1 var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: rgba(245,241,232,0.7);
  text-shadow: 0 1px 12px rgba(0,0,0,0.95);
}
.xr-legend li { display: flex; align-items: center; gap: 10px; }
.xr-legend i { width: 22px; height: 3px; border-radius: 2px; background: var(--c); box-shadow: 0 0 10px var(--c); }

/* one panel: machine selector + what you're looking at */
.xr-panel {
  position: absolute; z-index: 5; right: var(--xr-pad); top: 22px; width: 372px;
  background: rgba(14,13,10,0.62);
  border: 1px solid rgba(245,241,232,0.10); border-radius: 3px;
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.xr-tabs { display: grid; grid-template-columns: repeat(3, 1fr); border-bottom: 1px solid rgba(245,241,232,0.08); }
.xr-tab {
  --p: 0;
  position: relative; display: flex; align-items: baseline; gap: 7px;
  padding: 13px 12px 14px;
  background: none; border: 0; border-right: 1px solid rgba(245,241,232,0.08);
  color: rgba(245,241,232,0.5); cursor: pointer; text-align: left;
  font: 500 11px/1 var(--mono); letter-spacing: 0.09em; text-transform: uppercase; white-space: nowrap;
  transition: color .25s, background-color .25s;
}
.xr-tab:last-child { border-right: 0; }
.xr-tab:hover { color: var(--ink); background: rgba(245,241,232,0.03); }
.xr-tab.on { color: var(--ink); background: rgba(232,150,63,0.07); }
.xr-t-no { color: #E8963F; font-weight: 600; font-variant-numeric: tabular-nums; }
.xr-t-bar { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: rgba(245,241,232,0.05); overflow: hidden; }
.xr-t-bar::after { content: ''; position: absolute; inset: 0; background: #E8963F; transform-origin: left; transform: scaleX(var(--p)); box-shadow: 0 0 10px rgba(232,150,63,.9); }
.xr-now { padding: 16px 18px 18px; }
.xr-name { font: 600 13px/1.3 var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink); }
.xr-blurb { margin-top: 8px; font-family: var(--sans); font-size: 14px; line-height: 1.55; color: rgba(245,241,232,0.68); }
.xr-focus {
  display: grid; grid-template-rows: 0fr; opacity: 0;
  margin-top: 0; border-left: 2px solid #E8963F; padding-left: 12px;
  transition: grid-template-rows .5s cubic-bezier(.16,1,.3,1), opacity .4s ease, margin-top .5s;
}
.xr-focus > * { min-height: 0; overflow: hidden; }
.xr-focus.on { grid-template-rows: 1fr; opacity: 1; margin-top: 14px; }
.xr-focus-in { display: block; }
.xr-f-k { display: block; font: 600 10.5px/1 var(--mono); letter-spacing: 0.16em; text-transform: uppercase; color: #E8963F; }
.xr-f-t { display: block; margin-top: 7px; font: 600 13px/1.3 var(--mono); letter-spacing: 0.06em; color: var(--ink); }
.xr-f-d { display: block; margin-top: 5px; font-family: var(--sans); font-size: 13.5px; line-height: 1.5; color: rgba(245,241,232,0.8); }
.xr-credit { margin-top: 12px; font: 400 10.5px/1.4 var(--mono); letter-spacing: 0.03em; color: rgba(245,241,232,0.4); }
.xr-credit:empty { display: none; }

/* the pitch: bottom-left */
.xr-copy {
  position: absolute; z-index: 4;
  left: var(--xr-pad); bottom: clamp(28px, 5vh, 56px);
  width: min(560px, 40vw);
}
.xr-copy::before {
  content: ''; position: absolute; z-index: -1; inset: -140px -220px -80px -160px;
  background: radial-gradient(closest-side, rgba(11,10,8,0.8), rgba(11,10,8,0));
  pointer-events: none;
}
.xr-h1 {
  font-family: var(--sans); font-weight: 600;
  font-size: clamp(34px, 3.5vw, 58px); line-height: 1.0; letter-spacing: -0.032em;
  color: var(--ink);
  opacity: 0; animation: up 1.2s cubic-bezier(.16,1,.3,1) .2s forwards;
}
.xr-h1 span { display: block; color: rgba(245,241,232,0.5); }
.xr-lede {
  margin-top: 18px; max-width: 48ch;
  font-family: var(--sans); font-size: clamp(15px, 1.1vw, 17px); line-height: 1.6; color: rgba(245,241,232,0.84);
  opacity: 0; animation: up 1.2s cubic-bezier(.16,1,.3,1) .4s forwards;
}
.xr-lede .feel { font-style: italic; font-weight: 600; color: #E8963F; text-shadow: 0 0 14px rgba(201,122,50,.5); }
.xr-ctas { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; opacity: 0; animation: up 1.2s cubic-bezier(.16,1,.3,1) .6s forwards; }
.xr-ctas .cta { margin-top: 0; }

@media (max-width: 1100px) {
  .xr-copy { width: min(500px, 46vw); }
  .xr-panel { width: 330px; }
  .xr-t-nm { font-size: 10px; }
}

/* ── phones: footage on top (legend on it), info box under it, then the pitch ── */
@media (max-width: 760px) {
  .xr-hero { height: auto; min-height: 0; max-height: none; display: flex; flex-direction: column; }
  .xr-media { position: relative; inset: auto; width: 100%; aspect-ratio: 4 / 5; max-height: 72svh; flex: none; }
  .xr-legend {
    right: auto; left: var(--xr-pad); bottom: 14px;
    grid-template-columns: repeat(4, auto); gap: 14px; font-size: 9.5px; letter-spacing: 0.1em;
  }
  .xr-legend li { gap: 6px; }
  .xr-legend i { width: 12px; }
  .xr-scantag { display: none; }
  .xr-label { font-size: 10px; padding: 3px 7px 4px; }
  .xr-l-s, .xr-l-id { display: none; }
  .xr-panel {
    position: relative; right: auto; top: auto; width: auto;
    margin: 0 var(--xr-pad); background: rgba(245,241,232,0.03);
    backdrop-filter: none; -webkit-backdrop-filter: none;
  }
  .xr-tab { padding: 12px 10px 13px; font-size: 10.5px; letter-spacing: 0.06em; }
  .xr-now { padding: 14px 14px 16px; }
  .xr-copy { position: relative; left: auto; bottom: auto; width: auto; padding: 30px var(--xr-pad) 44px; }
  .xr-copy::before { display: none; }
  .xr-h1 { font-size: clamp(32px, 9.6vw, 46px); }
  .xr-lede { font-size: 15.5px; margin-top: 14px; }
  .xr-ctas { margin-top: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .xr-h1, .xr-lede, .xr-ctas { animation: none; opacity: 1; }
  .xr-v { transition: none; }
}
/* phones: the close-up swaps in for the blurb inside a fixed-height box, so the page never jumps */
@media (max-width: 760px) {
  .xr-now { position: relative; min-height: 160px; }
  .xr-blurb { transition: opacity .35s ease; }
  .xr-focus { position: absolute; left: 14px; right: 14px; top: 42px; margin-top: 0 !important; grid-template-rows: 1fr; transform: translateY(6px); transition: opacity .4s ease, transform .4s ease; pointer-events: none; }
  .xr-focus.on { transform: none; }
  .xr-panel.focusing .xr-blurb, .xr-panel.focusing .xr-credit { opacity: 0; }
}

/* details toggle: phones only */
.xr-more { display: none; }
@media (max-width: 760px) {
  .xr-more {
    display: flex; justify-content: space-between; align-items: center; width: 100%;
    padding: 12px 14px; background: none; border: 0; cursor: pointer;
    font: 500 11px/1 var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: rgba(245,241,232,0.6);
  }
  .xr-more span { transition: transform .3s ease; }
  .xr-more[aria-expanded="true"] span { transform: rotate(180deg); }
  .xr-panel .xr-now { display: none; }
  .xr-panel.open .xr-now { display: block; border-top: 1px solid rgba(245,241,232,0.08); }
}
