/* Product detail ("Learn more") pages — pdx layout. Behaviour in product-detail.js. */
:root {
  --pdx-ease: var(--ease-out, cubic-bezier(0.16, 1, 0.3, 1));
  --pdx-orange: var(--accent-orange, #FF5A00);
  --pdx-top: 80px;               /* fixed header height, measured by product-detail.js */
}

/* ---------- Entrance + scroll reveal ---------- */
html.pdx-ready [data-pdx-rise] { opacity: 0; transform: translateY(28px); }
html.pdx-ready [data-pdx-rise].pdx-in {
  opacity: 1; transform: none;
  transition: opacity .9s var(--pdx-ease), transform .9s var(--pdx-ease);
  transition-delay: var(--pdx-d, 0s);
}
html.pdx-ready [data-pdx-reveal] { opacity: 0; transform: translateY(40px); }
html.pdx-ready [data-pdx-reveal].pdx-in {
  opacity: 1; transform: none;
  transition: opacity .9s var(--pdx-ease), transform .9s var(--pdx-ease);
  transition-delay: var(--pdx-d, 0s);
}

/* ---------- Hero ---------- */
.pdx-hero {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  padding: calc(var(--pdx-top) + 64px) 0 96px;
  min-height: min(100vh, 880px);
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.06));
}
.pdx-hero-bg {
  position: absolute;
  inset: -60px;
  z-index: -2;
  background: var(--pdx-img) center / cover no-repeat;
  filter: blur(60px) saturate(1.2) brightness(0.35);
  transform: scale(1.1);
}
.pdx-hero::before {                     /* darken towards the text side + fade into the page */
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, rgba(7, 10, 14, 0.95) 0%, rgba(7, 10, 14, 0.7) 45%, rgba(7, 10, 14, 0.35) 100%),
    linear-gradient(180deg, transparent 60%, var(--bg-base, #0A0D12) 100%);
}
.pdx-watermark {
  position: absolute;
  left: 50%; bottom: -0.12em;
  z-index: -1;
  transform: translateX(-50%);
  font-family: var(--font-display, sans-serif);
  font-weight: 800;
  font-size: clamp(5rem, 14vw, 15rem);
  line-height: 1;
  white-space: nowrap;
  letter-spacing: -0.04em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255, 255, 255, 0.05);
  pointer-events: none;
  user-select: none;
}
.pdx-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: 64px;
  align-items: center;
}

.pdx-crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 26px;
  font-family: var(--font-mono, monospace);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.pdx-crumbs a { color: var(--text-secondary, #8A94A6); position: relative; transition: color .25s ease; }
.pdx-crumbs a::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -3px;
  height: 1px;
  background: var(--pdx-orange);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s var(--pdx-ease);
}
.pdx-crumbs a:hover { color: var(--pdx-orange); }
.pdx-crumbs a:hover::after { transform: scaleX(1); }
.pdx-crumbs a.is-current { color: var(--pdx-orange); }
.pdx-crumbs span { color: rgba(255, 255, 255, 0.2); }

.pdx-tags { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 22px; }
.pdx-title {
  font-family: var(--font-display, sans-serif);
  font-size: clamp(2.4rem, 4.2vw + 0.6rem, 5rem);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.035em;
  text-transform: uppercase;
  margin: 0 0 20px;
  background: linear-gradient(180deg, #FFFFFF 30%, #B9C3D1 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.pdx-sub {
  font-size: clamp(1.05rem, 0.6vw + 0.9rem, 1.3rem);
  line-height: 1.55;
  color: #C8D1DD;
  max-width: 560px;
  margin: 0 0 32px;
}
.pdx-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 36px; }

.pdx-highlights {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.pdx-highlights li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px 8px 8px;
  border-radius: 999px;
  font-size: 0.82rem;
  color: #DCE3EC;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.09);
  transition: border-color .3s ease, background .3s ease, transform .35s var(--pdx-ease);
}
.pdx-highlights li span {
  display: grid; place-items: center;
  width: 26px; height: 26px;
  border-radius: 50%;
  font-family: var(--font-mono, monospace);
  font-size: 0.68rem;
  color: var(--pdx-orange);
  background: rgba(255, 90, 0, 0.12);
}
.pdx-highlights li:hover { border-color: rgba(255, 90, 0, 0.45); background: rgba(255, 90, 0, 0.08); transform: translateY(-2px); }

/* Product viewport */
.pdx-hero-visual { position: relative; }
.pdx-hero-visual::before {              /* static glow behind the product */
  content: '';
  position: absolute;
  inset: 8% 6%;
  z-index: -1;
  background: radial-gradient(closest-side, rgba(255, 90, 0, 0.3), transparent);
  filter: blur(30px);
}
.pdx-viewport {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: #06090D;
  box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.95), 0 0 0 1px rgba(255, 90, 0, 0.08);
  transform: perspective(1400px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition: transform .8s var(--pdx-ease), box-shadow .4s ease, border-color .4s ease;
}
.pdx-viewport:hover {
  transition: transform .15s ease-out, box-shadow .4s ease, border-color .4s ease;
  border-color: rgba(255, 90, 0, 0.5);
  box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.95), 0 0 60px -16px rgba(255, 90, 0, 0.55);
}
.pdx-viewport img, .pdx-viewport video {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transform: scale(1.02);
  transition: transform .8s var(--pdx-ease);
}
.pdx-viewport:hover img, .pdx-viewport:hover video { transform: scale(1.08); }
.pdx-scan, .pdx-corners, .pdx-reticle, .pdx-hud { position: absolute; pointer-events: none; }
.pdx-scan {
  left: 0; right: 0; top: 0;
  height: 30%;
  background: linear-gradient(180deg, transparent, rgba(255, 90, 0, 0.06) 85%, rgba(255, 140, 60, 0.45));
  transform: translateY(-100%);
  animation: pdx-scan 5s cubic-bezier(.45, 0, .55, 1) infinite;
}
@keyframes pdx-scan { to { transform: translateY(340%); } }
.pdx-corners {
  inset: 14px;
  --c: rgba(255, 90, 0, 0.9); --l: 26px; --t: 2px;
  background:
    linear-gradient(var(--c), var(--c)) left top / var(--l) var(--t),
    linear-gradient(var(--c), var(--c)) left top / var(--t) var(--l),
    linear-gradient(var(--c), var(--c)) right top / var(--l) var(--t),
    linear-gradient(var(--c), var(--c)) right top / var(--t) var(--l),
    linear-gradient(var(--c), var(--c)) left bottom / var(--l) var(--t),
    linear-gradient(var(--c), var(--c)) left bottom / var(--t) var(--l),
    linear-gradient(var(--c), var(--c)) right bottom / var(--l) var(--t),
    linear-gradient(var(--c), var(--c)) right bottom / var(--t) var(--l);
  background-repeat: no-repeat;
  transition: inset .5s var(--pdx-ease);
}
.pdx-viewport:hover .pdx-corners { inset: 10px; }
.pdx-reticle {
  left: 50%; top: 50%;
  width: 34%;
  transform: translate(-50%, -50%);
  fill: none;
  stroke: rgba(255, 140, 60, 0.55);
  stroke-width: .6;
  stroke-dasharray: 3 4;
  opacity: 0;
  transition: opacity .4s ease;
}
.pdx-viewport:hover .pdx-reticle { opacity: 1; animation: pdx-spin 12s linear infinite; }
@keyframes pdx-spin { to { transform: translate(-50%, -50%) rotate(360deg); } }
.pdx-hud {
  font-family: var(--font-mono, monospace);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #FFD9C0;
  padding: 6px 11px;
  border-radius: 7px;
  background: rgba(6, 9, 13, 0.72);
  border: 1px solid rgba(255, 90, 0, 0.35);
}
.pdx-hud-tl { top: 24px; left: 24px; display: flex; align-items: center; gap: 8px; }
.pdx-hud-tl::before {
  content: '';
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #FF3B30;
  box-shadow: 0 0 8px #FF3B30;
  animation: pdx-blink 1.4s ease-in-out infinite;
}
.pdx-hud-br { right: 24px; bottom: 24px; max-width: 70%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@keyframes pdx-blink { 50% { opacity: .25; } }

/* ---------- Sticky section bar ---------- */
.pdx-subnav {
  position: sticky;
  top: var(--pdx-top);
  z-index: 900;
  background: rgba(8, 11, 15, 0.9);
  border-bottom: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.06));
}
.pdx-subnav .container { display: flex; align-items: center; gap: 28px; min-height: 62px; }
.pdx-subnav-name {
  font-family: var(--font-display, sans-serif);
  font-weight: 800;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--text-primary, #F5F5F2);
  white-space: nowrap;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity .35s ease, transform .35s var(--pdx-ease);
}
.pdx-subnav.is-stuck .pdx-subnav-name { opacity: 1; transform: none; }
.pdx-subnav-links { display: flex; gap: 6px; margin-right: auto; overflow-x: auto; scrollbar-width: none; }
.pdx-subnav-links::-webkit-scrollbar { display: none; }
.pdx-subnav-links a {
  position: relative;
  padding: 20px 14px;
  font-family: var(--font-mono, monospace);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-secondary, #8A94A6);
  white-space: nowrap;
  transition: color .25s ease;
}
.pdx-subnav-links a::after {
  content: '';
  position: absolute;
  left: 14px; right: 14px; bottom: -1px;
  height: 2px;
  background: var(--pdx-orange);
  transform: scaleX(0);
  transition: transform .35s var(--pdx-ease);
}
.pdx-subnav-links a:hover { color: var(--text-primary, #F5F5F2); }
.pdx-subnav-links a.is-active { color: var(--pdx-orange); }
.pdx-subnav-links a.is-active::after { transform: scaleX(1); }

/* ---------- Sections ---------- */
.pdx-section { padding: 110px 0; position: relative; scroll-margin-top: calc(var(--pdx-top) + 70px); }

/* Overview */
.pdx-overview {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 64px;
  align-items: start;
}
.pdx-lead {
  font-size: clamp(1.1rem, 0.7vw + 0.95rem, 1.45rem);
  line-height: 1.7;
  color: #D5DDE8;
  margin: 8px 0 0;
  padding-left: 24px;
  border-left: 3px solid var(--pdx-orange);
}
.pdx-side { display: flex; flex-direction: column; gap: 18px; }
.pdx-role {
  display: flex;
  gap: 18px;
  padding: 26px;
  border-radius: var(--radius-xl, 18px);
  background: linear-gradient(135deg, rgba(255, 90, 0, 0.1), rgba(255, 90, 0, 0.02) 60%), var(--bg-card, #11161D);
  border: 1px solid rgba(255, 90, 0, 0.3);
  transition: transform .45s var(--pdx-ease), box-shadow .4s ease, border-color .3s ease;
}
.pdx-role:hover { transform: translateY(-4px); border-color: rgba(255, 90, 0, 0.6); box-shadow: 0 0 40px -14px rgba(255, 90, 0, 0.5); }
.pdx-role-icon {
  flex: none;
  width: 48px; height: 48px;
  display: grid; place-items: center;
  border-radius: 14px;
  color: #0B0F14;
  background: var(--pdx-orange);
  transition: transform .5s var(--pdx-ease);
}
.pdx-role-icon svg { width: 24px; height: 24px; }
.pdx-role:hover .pdx-role-icon { transform: rotate(90deg); }
.pdx-label {
  font-family: var(--font-mono, monospace);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--pdx-orange);
  margin-bottom: 6px;
}
.pdx-role p { margin: 0; color: #D5DDE8; font-size: 0.95rem; line-height: 1.6; }
.pdx-facts {
  margin: 0;
  border-radius: var(--radius-xl, 18px);
  background: var(--bg-card, #11161D);
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.06));
  overflow: hidden;
}
.pdx-facts > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 22px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: background .25s ease;
}
.pdx-facts > div:last-child { border-bottom: 0; }
.pdx-facts > div:hover { background: rgba(255, 90, 0, 0.05); }
.pdx-facts dt { font-family: var(--font-mono, monospace); font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-secondary, #8A94A6); }
.pdx-facts dd { margin: 0; text-align: right; font-size: 0.9rem; color: var(--text-primary, #F5F5F2); }

/* Capabilities explorer */
.pdx-caps-section { background: rgba(21, 27, 34, 0.45); border-top: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.06)); border-bottom: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.06)); }
.pdx-caps {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 28px;
  align-items: stretch;
}
.pdx-cap-list { display: flex; flex-direction: column; gap: 12px; }
.pdx-cap-tab {
  position: relative;
  display: flex;
  align-items: center;
  gap: 18px;
  width: 100%;
  padding: 22px 24px;
  text-align: left;
  font: inherit;
  color: var(--text-secondary, #8A94A6);
  background: var(--bg-card, #11161D);
  border: 1px solid var(--border-subtle, rgba(255, 255, 255, 0.06));
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  transition: border-color .3s ease, color .3s ease, background .3s ease, transform .4s var(--pdx-ease);
}
.pdx-cap-tab:hover { color: var(--text-primary, #F5F5F2); transform: translateX(4px); }
.pdx-cap-tab.is-active {
  color: var(--text-primary, #F5F5F2);
  border-color: rgba(255, 90, 0, 0.5);
  background: linear-gradient(90deg, rgba(255, 90, 0, 0.12), rgba(255, 90, 0, 0.02) 70%), var(--bg-card, #11161D);
}
.pdx-cap-n {
  flex: none;
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border-radius: 50%;
  font-family: var(--font-mono, monospace);
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--pdx-orange);
  border: 1px solid rgba(255, 90, 0, 0.35);
  transition: background .3s ease, color .3s ease;
}
.pdx-cap-tab.is-active .pdx-cap-n { background: var(--pdx-orange); color: #0B0F14; }
.pdx-cap-t { font-family: var(--font-display, sans-serif); font-weight: 700; font-size: 1.02rem; line-height: 1.3; }
.pdx-cap-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: rgba(255, 255, 255, 0.04); }
.pdx-cap-bar i { display: block; height: 100%; background: var(--pdx-orange); transform: scaleX(0); transform-origin: left; }
.pdx-cap-tab.is-active .pdx-cap-bar i { animation: pdx-progress var(--pdx-cycle, 5s) linear forwards; }
.pdx-caps.is-paused .pdx-cap-tab.is-active .pdx-cap-bar i { animation-play-state: paused; }
@keyframes pdx-progress { to { transform: scaleX(1); } }

.pdx-cap-stage {
  position: relative;
  min-height: 340px;
  border-radius: 22px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #06090D;
}
.pdx-cap-img {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: .35;
  transform: scale(1.15);
  transition: transform 1.2s var(--pdx-ease), object-position 1.2s var(--pdx-ease);
}
.pdx-cap-stage::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(0deg, rgba(6, 9, 13, 0.97) 20%, rgba(6, 9, 13, 0.55) 70%, rgba(6, 9, 13, 0.3));
}
.pdx-cap-panel {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  z-index: 2;
  padding: 40px;
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .5s ease, transform .6s var(--pdx-ease);
  pointer-events: none;
}
.pdx-cap-panel.is-active { opacity: 1; transform: none; pointer-events: auto; transition-delay: .1s; }
.pdx-cap-num {
  font-family: var(--font-mono, monospace);
  font-weight: 800;
  font-size: clamp(4rem, 7vw, 6.5rem);
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255, 90, 0, 0.6);
  margin-bottom: 14px;
}
.pdx-cap-panel h3 {
  font-family: var(--font-display, sans-serif);
  font-size: clamp(1.4rem, 1.2vw + 1rem, 2rem);
  line-height: 1.15;
  color: #fff;
  margin: 0 0 12px;
}
.pdx-cap-panel p { margin: 0; max-width: 520px; font-size: 1rem; line-height: 1.65; color: #C8D1DD; }

/* Call-to-action band */
.pdx-band { padding: 20px 0 0; }
.pdx-band-box {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 48px 52px;
  border-radius: 24px;
  background: linear-gradient(120deg, rgba(255, 90, 0, 0.16), rgba(255, 90, 0, 0.03) 55%), var(--bg-card, #11161D);
  border: 1px solid rgba(255, 90, 0, 0.35);
}
.pdx-band-copy { flex: 1; }
.pdx-band-copy h2 {
  font-family: var(--font-display, sans-serif);
  font-size: clamp(1.5rem, 1.4vw + 1rem, 2.3rem);
  line-height: 1.15;
  color: #fff;
  margin: 0 0 8px;
}
.pdx-band-copy p { margin: 0; color: #C8D1DD; }
.pdx-radar {
  position: absolute;
  right: -90px; top: 50%;
  z-index: -1;
  width: 360px; height: 360px;
  margin-top: -180px;
  border-radius: 50%;
  opacity: .5;
  background:
    radial-gradient(circle, transparent 0 32.5%, rgba(255, 90, 0, 0.18) 33% 33.5%, transparent 34% 65.5%, rgba(255, 90, 0, 0.14) 66% 66.5%, transparent 67%);
}
.pdx-radar::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(rgba(255, 90, 0, 0.35), transparent 25%);
  animation: pdx-radar 4s linear infinite;
}
@keyframes pdx-radar { to { transform: rotate(360deg); } }

/* Related */
.pdx-back { margin-top: 48px; text-align: center; }

/* ---------- Responsive ---------- */
@media (max-width: 992px) {
  .pdx-hero { min-height: 0; padding-bottom: 72px; }
  .pdx-hero-grid, .pdx-overview, .pdx-caps { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .pdx-hero-visual { order: -1; }
  .pdx-subnav-name { display: none; }
  .pdx-subnav .btn { display: none; }
  .pdx-section { padding: 80px 0; }
  .pdx-band-box { flex-direction: column; align-items: flex-start; padding: 36px 28px; }
}
@media (max-width: 640px) {
  .pdx-cap-panel { padding: 28px; }
  .pdx-cap-stage { min-height: 300px; }
  .pdx-hud-br { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .pdx-scan, .pdx-hud-tl::before, .pdx-radar::before, .pdx-viewport:hover .pdx-reticle { animation: none !important; }
  .pdx-viewport { transform: none !important; }
}

/* `overflow-x: hidden` on body turns it into a scroll container and breaks position: sticky */
body { overflow-x: clip; }

/* In-place hover zoom on the hero image (.pdx-zoom: Materials & Services, Energy & Resilience pages) */
.pdx-viewport.pdx-zoom { animation: none; }
.pdx-viewport.pdx-zoom img { transition: transform .35s ease; }
.pdx-viewport.pdx-zoom:hover img { transform: none; }
.pdx-viewport.pdx-zoom.is-zooming img { transform: scale(var(--pdx-zoom, 2.5)); cursor: zoom-in; }
/* keep the view clear while zooming */
.pdx-viewport.pdx-zoom.is-zooming .pdx-scan,
.pdx-viewport.pdx-zoom.is-zooming .pdx-reticle,
.pdx-viewport.pdx-zoom.is-zooming .pdx-hud { opacity: 0; animation: none; }
