:root {
  color-scheme: dark;
  --night: #010909;
  --deep: #032e2b;
  --forest: #07544b;
  --cyan: #98e5da;
  --copper: #d2754f;
  --copper-hot: #ffae73;
  --bone: #f2f4ed;
  --mist: #a5b4af;
  --line: rgba(152, 229, 218, .18);
  --max: 96rem;
  --pad: clamp(1.15rem, 4vw, 4.8rem);
  --hero-image: url("assets/drill-rig-1120.webp");
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--night); }
body {
  margin: 0;
  color: var(--bone);
  background:
    linear-gradient(90deg, rgba(152,229,218,.018) 1px, transparent 1px),
    linear-gradient(rgba(152,229,218,.014) 1px, transparent 1px),
    var(--night);
  background-size: 7rem 7rem;
  font-family: "Arial Narrow", Arial, Helvetica, sans-serif;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; }
.wrap { width: min(100%, var(--max)); margin-inline: auto; padding-inline: var(--pad); }
.eyebrow {
  margin: 0 0 1rem;
  color: var(--cyan);
  font-size: .66rem;
  font-weight: 800;
  letter-spacing: .2em;
  text-transform: uppercase;
}

.mast {
  position: fixed;
  z-index: 40;
  inset: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4rem;
  padding: .75rem var(--pad);
  border-bottom: 1px solid rgba(255,255,255,.13);
  background: rgba(1,9,9,.76);
  backdrop-filter: blur(16px);
}
.brand { font-size: .72rem; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; text-decoration: none; }
.variant-nav { display: flex; gap: .3rem; padding: .26rem; border: 1px solid var(--line); }
.variant-nav a { padding: .55rem .72rem; color: rgba(255,255,255,.52); font-size: .58rem; letter-spacing: .11em; text-decoration: none; text-transform: uppercase; }
.variant-nav a[aria-current="page"] { color: #062c29; background: var(--cyan); }
.variant-nav a:focus-visible, .brand:focus-visible { outline: 2px solid var(--copper-hot); outline-offset: 3px; }

.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: end;
  isolation: isolate;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  z-index: -2;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(1,15,14,.94), rgba(1,15,14,.56) 48%, rgba(1,15,14,.08) 82%),
    linear-gradient(0deg, var(--night), transparent 38%),
    var(--hero-image) center 45% / cover no-repeat;
  transform: scale(1.018);
}
.hero::after { content: ""; position: absolute; z-index: -1; inset: 0; background: repeating-linear-gradient(90deg, transparent 0 9.9%, rgba(152,229,218,.17) 10%); opacity: .2; mask-image: linear-gradient(transparent, black 78%); }
.hero-inner { padding-block: clamp(9rem, 25vh, 16rem) clamp(4rem, 9vh, 7rem); }
.hero h1 { max-width: 12ch; margin: 0; font: 400 clamp(3.7rem, 8.2vw, 8.7rem)/.88 Georgia,serif; letter-spacing: -.06em; text-wrap: balance; }
.hero h1 span { color: var(--copper-hot); }
.hero-dek { max-width: 46rem; margin: 1.7rem 0 0; color: rgba(255,255,255,.78); font: clamp(1.05rem,1.65vw,1.42rem)/1.58 Georgia,serif; }
.hero-note { max-width: 48rem; margin: 2rem 0 0; color: rgba(255,255,255,.46); font-size: .68rem; line-height: 1.55; }
.scroll-cue { display: inline-flex; align-items: center; gap: .7rem; margin-top: 2.2rem; color: var(--cyan); font-size: .6rem; letter-spacing: .15em; text-transform: uppercase; }
.scroll-cue::before { content: ""; width: 3rem; height: 1px; background: currentColor; }

.premise { padding: clamp(6rem, 12vw, 11rem) 0; }
.premise-grid { display: grid; grid-template-columns: .82fr 1.18fr; gap: clamp(3rem, 9vw, 10rem); align-items: end; }
.premise h2 { margin: 0; font: 400 clamp(2.8rem,6vw,6.5rem)/.94 Georgia,serif; letter-spacing: -.05em; text-wrap: balance; }
.premise-copy { max-width: 46rem; }
.premise-copy p { margin: 0 0 1.25rem; color: var(--mist); font: clamp(1.12rem,1.7vw,1.45rem)/1.62 Georgia,serif; }
.mode-note { margin-top: 1.8rem; padding: 1rem 1.1rem; border-left: 2px solid var(--copper); background: rgba(210,117,79,.07); color: rgba(255,255,255,.64); font-size: .72rem; line-height: 1.55; }

.device-section { position: relative; min-height: 100svh; border-top: 1px solid var(--line); }
.device-stage {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: center;
  overflow: clip;
}
.device-grid { display: grid; grid-template-columns: minmax(17rem,.7fr) minmax(25rem,1.3fr); gap: clamp(2.5rem,7vw,7rem); align-items: center; padding-block: 6.5rem 3rem; }
.chapter-id { display: flex; align-items: center; gap: .8rem; color: var(--copper-hot); font-size: .62rem; letter-spacing: .17em; text-transform: uppercase; }
.chapter-id::before { content: ""; width: 2.7rem; height: 1px; background: currentColor; }
.device-copy h2 { max-width: 10ch; margin: 1.2rem 0 1.4rem; font: 400 clamp(2.7rem,5.4vw,6rem)/.92 Georgia,serif; letter-spacing: -.052em; text-wrap: balance; }
.device-copy > p { max-width: 34rem; margin: 0; color: var(--mist); font: 1rem/1.67 Georgia,serif; }
.device-copy .material-line { display: block; margin-top: 2rem; color: var(--cyan); font-size: .65rem; letter-spacing: .13em; text-transform: uppercase; }

.device-visual {
  --reveal: 1;
  position: relative;
  min-height: min(62vw, 42rem);
  aspect-ratio: 16 / 9;
  border: 1px solid var(--line);
  background: #010707;
  overflow: hidden;
  isolation: isolate;
  box-shadow: 0 2rem 6rem rgba(0,0,0,.4);
}
.plate { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; pointer-events: none; user-select: none; -webkit-user-drag: none; }
.plate.base { transform: scale(1.001); }
.plate.xray { z-index: 2; }
.image-shade { position: absolute; z-index: 4; inset: 0; background: linear-gradient(90deg, rgba(1,9,9,.34), transparent 35%), linear-gradient(0deg, rgba(1,9,9,.64), transparent 32%); pointer-events: none; }
.visual-label { position: absolute; z-index: 8; left: 1rem; right: 1rem; bottom: .85rem; display: flex; justify-content: space-between; gap: 1rem; color: rgba(255,255,255,.5); font-size: .59rem; line-height: 1.4; letter-spacing: .08em; text-transform: uppercase; }
.focus-marker { position: absolute; z-index: 8; top: 1rem; right: 1rem; display: flex; align-items: center; gap: .55rem; color: rgba(255,255,255,.4); font-size: .58rem; letter-spacing: .13em; text-transform: uppercase; }
.focus-marker::before { content: ""; width: .48rem; aspect-ratio: 1; border: 1px solid currentColor; border-radius: 50%; }
.device-section.is-active .focus-marker { color: var(--copper-hot); }
.device-section.is-active .focus-marker::before { background: currentColor; box-shadow: 0 0 14px currentColor; }

/* Version A: the focused copper receives only a bounded, copper-masked refraction. */
.glow-page .plate.base { display: none; }
.glow-page .plate.xray { opacity: .66; filter: grayscale(.24) saturate(.52) brightness(.7) contrast(.96); transition: opacity 260ms ease, filter 260ms ease; }
.glow-page .device-section.is-active .plate.xray { opacity: 1; filter: grayscale(0) saturate(1.28) brightness(1.06) contrast(1.06); }
.copper-refraction { position: absolute; z-index: 3; inset: 0; width: 100%; height: 100%; opacity: 0; filter: saturate(1.16) contrast(1.08); pointer-events: none; transition: opacity 220ms ease; }
.glow-page .device-section.is-active .copper-refraction { opacity: .96; }

/* Version B: the entire opaque object morphs continuously into its copper anatomy. */
.reveal-page.js .plate.base { opacity: calc(1 - var(--reveal)); filter: brightness(calc(.58 + var(--reveal) * .18)) contrast(calc(1 + var(--reveal) * .08)); transform: scale(calc(1 + var(--reveal) * .012)); }
.reveal-page.js .plate.xray { opacity: var(--reveal); filter: saturate(calc(.76 + var(--reveal) * .52)) brightness(calc(.7 + var(--reveal) * .34)) contrast(calc(.96 + var(--reveal) * .12)); transform: scale(calc(1.018 - var(--reveal) * .018)); }
.reveal-page.js .plate.xray-bloom { z-index: 3; opacity: calc(var(--reveal) * .38); mix-blend-mode: screen; filter: saturate(1.65) contrast(1.22) brightness(1.06) blur(.45px); transform: scale(calc(1.012 - var(--reveal) * .012)); }
.reveal-page.js .image-shade { opacity: calc(.9 - var(--reveal) * .55); }
.reveal-page.no-js .plate.base { opacity: 0; }
.reveal-page.no-js .xray-bloom { display: none; }
.reveal-page .progress-readout { position: absolute; z-index: 8; top: 1rem; left: 1rem; color: rgba(255,255,255,.44); font-size: .58rem; letter-spacing: .12em; text-transform: uppercase; }
.reveal-page .progress-readout b { color: var(--copper-hot); font-weight: 500; }

.closing { padding: clamp(7rem,14vw,13rem) 0; border-top: 1px solid var(--line); text-align: center; }
.closing h2 { max-width: 14ch; margin: 0 auto; font: 400 clamp(3rem,7vw,7.5rem)/.9 Georgia,serif; letter-spacing: -.06em; text-wrap: balance; }
.closing p { max-width: 44rem; margin: 2rem auto 0; color: var(--mist); font: 1.08rem/1.7 Georgia,serif; }
.disclosure { max-width: 64rem; margin: 4rem auto 0; padding: 1.1rem; border: 1px solid rgba(210,117,79,.4); color: rgba(255,255,255,.55); font-size: .7rem; line-height: 1.6; text-align: left; }
footer { padding: 1.4rem var(--pad); border-top: 1px solid var(--line); color: rgba(255,255,255,.4); font-size: .6rem; letter-spacing: .11em; text-transform: uppercase; }

.compare-page { min-height: 100svh; display: grid; align-items: center; padding: 7rem 0 4rem; }
.compare-page h1 { max-width: 12ch; margin: 0; font: 400 clamp(3.8rem,8vw,8rem)/.88 Georgia,serif; letter-spacing: -.06em; }
.compare-page .lede { max-width: 44rem; color: var(--mist); font: 1.18rem/1.65 Georgia,serif; }
.compare-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; margin-top: 3.5rem; background: var(--line); }
.compare-card { min-height: 28rem; display: flex; flex-direction: column; justify-content: flex-end; padding: clamp(1.5rem,3vw,3rem); background: var(--deep); text-decoration: none; }
.compare-card:nth-child(2) { background: #e8e4d9; color: #11201d; }
.compare-card span { font-size: .62rem; letter-spacing: .17em; text-transform: uppercase; }
.compare-card h2 { margin: auto 0 1rem; font: 400 clamp(2.4rem,4.5vw,4.8rem)/.94 Georgia,serif; letter-spacing: -.05em; }
.compare-card p { max-width: 31rem; margin: 0; font: .92rem/1.6 Georgia,serif; opacity: .7; }
.compare-card:focus-visible { outline: 3px solid var(--copper-hot); outline-offset: -5px; }

@media (max-width: 900px) {
  .premise-grid, .device-grid, .compare-grid { grid-template-columns: 1fr; }
  .device-section, .device-stage { min-height: auto; }
  .device-stage { align-items: start; }
  .device-grid { gap: 2rem; padding-top: 7rem; }
  .device-copy h2 { max-width: 14ch; }
  .device-visual { min-height: 0; width: 100%; }
  .visual-label span:last-child { display: none; }
  .compare-card { min-height: 23rem; }
}

@media (max-width: 640px) {
  :root { --hero-image: url("assets/drill-rig-720.webp"); }
  .mast { align-items: flex-start; }
  .brand { display: none; }
  .variant-nav { width: 100%; justify-content: space-between; }
  .variant-nav a { padding-inline: .45rem; }
  .hero h1 { font-size: clamp(3.4rem,16vw,5.3rem); }
  .device-grid { padding-top: 6.2rem; }
  .device-copy > p { font-size: .92rem; }
  .device-visual { aspect-ratio: 4 / 3; }
  .plate { object-position: 64% center; }
  .visual-label { font-size: .52rem; }
}

@media print, (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .mast { position: absolute; backdrop-filter: none; }
  .device-section { min-height: auto; break-inside: avoid; }
  .device-stage { position: relative; min-height: auto; }
  .device-grid { padding-block: 5rem; }
  .copper-refraction { animation: none !important; }
  .glow-page .copper-refraction { display: none; }
  .reveal-page .plate.base { opacity: 0 !important; }
  .reveal-page .plate.xray { opacity: 1 !important; }
}
