.detail-page {
  background: var(--surface-white);
}

.detail-page .site-header {
  border-bottom: 1px solid rgba(18, 53, 128, 0.08);
}

.detail-page .desktop-nav a[aria-current="page"] {
  color: var(--brand-700);
  font-weight: 600;
}

.detail-hero {
  position: relative;
  overflow: hidden;
  padding: 118px 0 76px;
  background:
    radial-gradient(circle at 84% 32%, rgba(69, 201, 242, 0.12), transparent 28%),
    linear-gradient(135deg, #071425 0%, #0b1d36 58%, #102c53 100%);
  color: var(--surface-white);
}

.detail-hero::after {
  position: absolute;
  right: -12%;
  bottom: 8%;
  width: 58%;
  height: 1px;
  transform: rotate(-17deg);
  transform-origin: right;
  background: var(--spectral-line);
  content: "";
  opacity: 0.7;
}

.detail-hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(390px, 0.8fr);
  gap: 72px;
  align-items: center;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 28px;
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.8125rem;
}

.breadcrumb a {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  color: rgba(255, 255, 255, 0.86);
}

.breadcrumb a:hover {
  color: var(--spectral-cyan);
}

.detail-hero .eyebrow {
  margin-bottom: 18px;
  color: #8edff5;
}

.detail-hero h1 {
  max-width: 760px;
  font-size: clamp(3.25rem, 5.2vw, 4.85rem);
}

.detail-hero-lead {
  max-width: 700px;
  margin-top: 26px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 1.1875rem;
  line-height: 1.62;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 26px;
}

.detail-tags li {
  padding: 7px 11px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: rgba(255, 255, 255, 0.83);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.detail-visual {
  position: relative;
  min-height: 430px;
  display: grid;
  place-items: center;
}

.detail-visual::before {
  position: absolute;
  inset: 11% 4%;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background:
    linear-gradient(rgba(69, 201, 242, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(69, 201, 242, 0.08) 1px, transparent 1px);
  background-size: 38px 38px;
  content: "";
}

.detail-visual img {
  position: relative;
  z-index: 1;
  width: min(100%, 610px);
  max-height: 390px;
  object-fit: contain;
  filter: drop-shadow(0 34px 40px rgba(0, 0, 0, 0.34));
  transform: scale(1);
  transform-origin: center;
  transition: transform var(--transition-base);
}

@media (hover: hover) and (pointer: fine) {
  .detail-visual:hover img {
    transform: scale(1.018);
  }
}

@media (prefers-reduced-motion: reduce) {
  .detail-visual img {
    transform: none !important;
  }
}

.detail-section {
  padding: 92px 0;
}

.detail-section-cool {
  background: var(--surface-cool);
}

.detail-section-dark {
  background: var(--ink-950);
  color: var(--surface-white);
}

.detail-heading {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(360px, 0.65fr);
  gap: 84px;
  align-items: end;
  margin-bottom: 48px;
}

.detail-heading .eyebrow {
  margin-bottom: 16px;
}

.detail-heading p:last-child {
  color: var(--ink-600);
  font-size: 1.0625rem;
}

.detail-section-dark .detail-heading p:last-child {
  color: rgba(255, 255, 255, 0.66);
}

.route-ledger {
  border-top: 1px solid var(--line);
}

.route-item {
  display: grid;
  grid-template-columns: 70px minmax(180px, 0.7fr) minmax(260px, 1.3fr) minmax(170px, 0.6fr);
  gap: 28px;
  align-items: start;
  padding: 30px 0;
  border-bottom: 1px solid var(--line);
}

.route-number {
  color: var(--brand-700);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.12em;
}

.route-item h3 {
  font-size: 1.35rem;
}

.route-item p {
  color: var(--ink-600);
}

.route-model {
  color: var(--brand-700);
  font-size: 0.875rem;
  font-weight: 600;
}

.spec-table-wrap {
  overflow-x: auto;
  border-top: 1px solid var(--line-dark);
}

.spec-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  text-align: left;
}

.spec-table th,
.spec-table td {
  padding: 20px 18px;
  border-bottom: 1px solid var(--line-dark);
  vertical-align: top;
}

.spec-table th {
  color: #9ccfe3;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.spec-table td:first-child {
  color: var(--surface-white);
  font-weight: 600;
}

.spec-table td {
  color: rgba(255, 255, 255, 0.73);
}

.spec-footnote {
  max-width: 820px;
  margin-top: 24px;
  color: rgba(255, 255, 255, 0.54);
  font-size: 0.8125rem;
}

.evidence-split {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(420px, 1.1fr);
  gap: 70px;
  align-items: center;
}

.evidence-copy .eyebrow {
  margin-bottom: 16px;
}

.evidence-copy h2 {
  margin-bottom: 22px;
}

.evidence-copy > p:not(.eyebrow) {
  color: var(--ink-600);
  font-size: 1.0625rem;
}

.evidence-frame {
  padding: 18px;
  border: 1px solid var(--line);
  background: var(--surface-white);
}

.evidence-frame img {
  width: 100%;
  height: auto;
}

.input-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.input-grid li {
  min-height: 150px;
  padding: 28px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.input-grid span {
  display: block;
  margin-bottom: 14px;
  color: var(--brand-700);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.11em;
}

.input-grid p {
  color: var(--ink-600);
}

.process-chain {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.process-chain li {
  position: relative;
  min-height: 230px;
  padding: 30px 26px;
  border-right: 1px solid var(--line);
}

.process-chain li:last-child {
  border-right: 0;
}

.process-chain span {
  color: var(--brand-700);
  font-size: 0.75rem;
  font-weight: 600;
}

.process-chain h3 {
  margin: 48px 0 14px;
  font-size: 1.25rem;
}

.process-chain p {
  color: var(--ink-600);
  font-size: 0.9375rem;
}

.metric-band {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 1px solid var(--line-dark);
}

.metric-band-title {
  margin: 40px 0 18px;
  color: var(--surface-white);
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  line-height: 1.2;
}

.metric {
  min-height: 180px;
  padding: 30px;
  border-right: 1px solid var(--line-dark);
}

.metric:last-child {
  border-right: 0;
}

.metric dt {
  color: #9ccfe3;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.metric dd {
  margin-top: 28px;
  color: var(--surface-white);
  font-size: clamp(2rem, 3vw, 2.8rem);
  font-weight: 500;
  letter-spacing: -0.035em;
  line-height: 1;
}

.metric small {
  display: block;
  margin-top: 14px;
  color: rgba(255, 255, 255, 0.56);
  font-size: 0.8125rem;
}

.colour-register {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: 44px;
  border: 1px solid var(--line);
}

.colour-register li {
  min-height: 140px;
  display: flex;
  align-items: end;
  padding: 20px;
  border-right: 1px solid rgba(255, 255, 255, 0.25);
  color: var(--surface-white);
  font-weight: 600;
}

.colour-register li:nth-child(1) { background: linear-gradient(135deg, #9e7929, #d6b55e); }
.colour-register li:nth-child(2) { background: linear-gradient(135deg, #81514d, #c78b82); }
.colour-register li:nth-child(3) { background: linear-gradient(135deg, #34383d, #737b84); }
.colour-register li:nth-child(4) { background: linear-gradient(135deg, #07090c, #303840); }
.colour-register li:last-child { border-right: 0; }

.material-register {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.material-register li {
  min-height: 180px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 26px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.52);
}

.material-register span {
  color: var(--brand-700);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.11em;
}

.material-register strong {
  color: var(--ink-950);
  font-size: clamp(1.7rem, 3vw, 2.5rem);
  font-weight: 500;
  letter-spacing: -0.03em;
}

.boundary-note {
  max-width: 930px;
  margin-top: 34px;
  padding: 22px 24px;
  border-left: 3px solid var(--brand-700);
  background: rgba(18, 53, 128, 0.06);
  color: var(--ink-600);
}

.system-boundary-section {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background:
    linear-gradient(102deg, rgba(234, 240, 247, 0.98) 0%, rgba(238, 244, 250, 0.98) 52%, rgba(225, 235, 247, 0.98) 100%);
}

.system-boundary-section::before,
.system-boundary-section::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  content: "";
}

.system-boundary-section::before {
  background-image:
    linear-gradient(rgba(18, 53, 128, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(18, 53, 128, 0.055) 1px, transparent 1px);
  background-size: 44px 44px;
  opacity: 0.58;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, rgba(0, 0, 0, 0.18) 38%, #000 70%, #000 100%);
  mask-image: linear-gradient(90deg, transparent 0%, rgba(0, 0, 0, 0.18) 38%, #000 70%, #000 100%);
}

.system-boundary-section::after {
  background:
    radial-gradient(circle at 78% 48%, rgba(69, 201, 242, 0.14), transparent 27%),
    radial-gradient(circle at 88% 30%, rgba(123, 111, 242, 0.08), transparent 30%);
}

.system-boundary-section .evidence-split {
  grid-template-columns: minmax(0, 0.82fr) minmax(460px, 1.18fr);
  gap: clamp(58px, 7vw, 110px);
}

.system-boundary-section .evidence-copy {
  position: relative;
  z-index: 1;
}

.system-boundary-section .evidence-copy h2 {
  max-width: 12ch;
  margin-bottom: 24px;
}

.system-boundary-section .evidence-copy > p:not(.eyebrow) {
  max-width: 48ch;
}

.system-boundary-section .boundary-note {
  max-width: 46ch;
  margin-top: 28px;
  padding: 20px 22px;
  border: 1px solid rgba(18, 53, 128, 0.14);
  background: rgba(244, 247, 251, 0.72);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.76);
}

.system-boundary-section .evidence-frame {
  position: relative;
  display: grid;
  min-height: 360px;
  place-items: center;
  overflow: hidden;
  padding: clamp(28px, 3.5vw, 48px);
  border: 1px solid rgba(18, 53, 128, 0.14);
  background:
    linear-gradient(rgba(18, 53, 128, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(18, 53, 128, 0.045) 1px, transparent 1px),
    rgba(247, 250, 253, 0.82);
  background-size: 32px 32px, 32px 32px, auto;
  box-shadow:
    0 26px 54px -42px rgba(7, 20, 37, 0.66),
    inset 0 1px 0 rgba(255, 255, 255, 0.88);
}

.system-boundary-section .evidence-frame::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 8%, rgba(69, 201, 242, 0.9) 48%, rgba(18, 53, 128, 0.5) 78%, transparent 100%);
  content: "";
}

.system-boundary-section .evidence-frame::after {
  position: absolute;
  right: 14%;
  bottom: 38px;
  left: 14%;
  height: 24px;
  border-radius: 50%;
  background: rgba(7, 20, 37, 0.14);
  filter: blur(16px);
  content: "";
}

.system-boundary-section .evidence-frame img {
  position: relative;
  z-index: 1;
  max-height: 350px;
  object-fit: contain;
  filter: drop-shadow(0 18px 20px rgba(7, 20, 37, 0.13));
}

.detail-cta {
  padding: 66px 0;
  background: var(--brand-700);
  color: var(--surface-white);
}

.detail-cta-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 48px;
  align-items: center;
}

.detail-cta h2 {
  max-width: 820px;
  font-size: clamp(2.3rem, 3.8vw, 3.4rem);
}

.detail-cta p {
  max-width: 720px;
  margin-top: 16px;
  color: rgba(255, 255, 255, 0.72);
}

@media (max-width: 1100px) {
  .detail-hero-grid {
    grid-template-columns: minmax(0, 1fr) minmax(340px, 0.7fr);
    gap: 38px;
  }

  .route-item {
    grid-template-columns: 52px minmax(170px, 0.7fr) minmax(220px, 1.1fr);
  }

  .route-model {
    grid-column: 2 / 4;
  }
}

@media (max-width: 1023px) {
  .detail-hero {
    padding: 96px 0 64px;
  }

  .detail-hero-grid,
  .detail-heading,
  .evidence-split {
    grid-template-columns: 1fr;
  }

  .detail-hero-grid,
  .detail-heading,
  .evidence-split {
    gap: 42px;
  }

  .detail-visual {
    min-height: 340px;
  }

  .detail-visual img {
    max-height: 310px;
  }

  .detail-section {
    padding: 76px 0;
  }

  .system-boundary-section .evidence-split {
    grid-template-columns: 1fr;
    gap: 38px;
  }

  .system-boundary-section .evidence-copy h2,
  .system-boundary-section .evidence-copy > p:not(.eyebrow),
  .system-boundary-section .boundary-note {
    max-width: 680px;
  }

  .system-boundary-section .evidence-frame {
    min-height: 320px;
  }

  .process-chain {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .process-chain li:nth-child(2) {
    border-right: 0;
  }

  .process-chain li:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }
}

@media (max-width: 767px) {
  .detail-hero {
    padding: 82px 0 54px;
  }

  .detail-hero h1 {
    font-size: clamp(2.55rem, 12vw, 3.25rem);
  }

  .detail-hero-lead {
    font-size: 1.0625rem;
  }

  .detail-actions {
    display: grid;
  }

  .detail-actions .button {
    width: 100%;
  }

  .detail-visual {
    min-height: 280px;
  }

  .detail-visual img {
    max-height: 250px;
  }

  .detail-section {
    padding: 58px 0;
  }

  .system-boundary-section::before {
    background-size: 32px 32px;
    opacity: 0.42;
  }

  .system-boundary-section .evidence-split {
    gap: 30px;
  }

  .system-boundary-section .evidence-copy h2 {
    max-width: 14ch;
    margin-bottom: 18px;
  }

  .system-boundary-section .boundary-note {
    margin-top: 22px;
    padding: 18px;
  }

  .system-boundary-section .evidence-frame {
    min-height: 230px;
    padding: 20px 16px 24px;
    background-size: 28px 28px, 28px 28px, auto;
  }

  .system-boundary-section .evidence-frame::after {
    bottom: 25px;
    height: 18px;
  }

  .system-boundary-section .evidence-frame img {
    max-height: 250px;
  }

  .detail-heading {
    margin-bottom: 34px;
  }

  .route-item {
    grid-template-columns: 38px 1fr;
    gap: 12px 14px;
    padding: 26px 0;
  }

  .route-item h3,
  .route-item p,
  .route-model {
    grid-column: 2;
  }

  .route-model {
    margin-top: 5px;
  }

  .input-grid,
  .metric-band,
  .colour-register,
  .material-register,
  .detail-cta-grid {
    grid-template-columns: 1fr;
  }

  .metric,
  .colour-register li {
    border-right: 0;
    border-bottom: 1px solid var(--line-dark);
  }

  .metric:last-child,
  .colour-register li:last-child {
    border-bottom: 0;
  }

  .process-chain {
    grid-template-columns: 1fr;
  }

  .process-chain li {
    min-height: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .process-chain li:last-child {
    border-bottom: 0;
  }

  .process-chain h3 {
    margin-top: 24px;
  }

  .detail-cta {
    padding: 52px 0;
  }

  .detail-cta .button {
    width: 100%;
  }
}
