:root {
  color-scheme: dark;
  --ink: #f5f8fb;
  --muted: #93a0ac;
  --line: rgba(183, 206, 226, 0.72);
}

* { box-sizing: border-box; }

html,
body {
  width: 100%;
  min-height: 100%;
  margin: 0;
  overflow: hidden;
  background: #050709;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button { font: inherit; }

.viewer-shell {
  position: relative;
  width: 100vw;
  height: 100svh;
  min-height: 520px;
  isolation: isolate;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 46%, rgba(34, 47, 58, 0.62), rgba(9, 13, 18, 0.35) 31%, transparent 58%),
    linear-gradient(145deg, #070a0d, #10161c 48%, #050708);
}

.viewer-shell::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  pointer-events: none;
  background-image: linear-gradient(rgba(255, 255, 255, 0.012) 1px, transparent 1px);
  background-size: 100% 4px;
  mask-image: linear-gradient(to bottom, transparent, black 25%, black 75%, transparent);
}

.ambient {
  position: absolute;
  z-index: -1;
  width: min(44vw, 650px);
  aspect-ratio: 1;
  border-radius: 999px;
  filter: blur(110px);
  opacity: 0.12;
  pointer-events: none;
}

.ambient-one { top: -28%; right: -8%; background: #36a8ff; }
.ambient-two { bottom: -32%; left: -10%; background: #22d08b; }

.viewer-header {
  position: absolute;
  z-index: 6;
  top: clamp(22px, 3.2vw, 46px);
  left: clamp(22px, 4vw, 62px);
  display: flex;
  align-items: center;
  gap: 14px;
  pointer-events: none;
}

.viewer-header p {
  margin: 0;
  font-size: clamp(12px, 1vw, 15px);
  font-weight: 750;
  letter-spacing: 0.22em;
}

.viewer-header span {
  display: block;
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.06em;
}

.brand-mark {
  position: relative;
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.05);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.brand-mark span {
  position: absolute;
  left: 8px;
  width: 18px;
  height: 3px;
  border-radius: 4px;
  background: linear-gradient(90deg, #18d98b, #9fffd3);
  transform: skewX(-28deg);
}

.brand-mark span:nth-child(1) { top: 8px; }
.brand-mark span:nth-child(2) { top: 15px; width: 14px; }
.brand-mark span:nth-child(3) { top: 22px; width: 10px; }

.viewer-stage,
.canvas-mount { position: absolute; inset: 0; }

.canvas-mount::after {
  content: "";
  position: absolute;
  z-index: 2;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 50% 47%, transparent 31%, rgba(1, 5, 9, 0.09) 61%, rgba(1, 4, 7, 0.46) 100%),
    radial-gradient(circle at 50% 48%, color-mix(in srgb, var(--feature-accent, #8fd1ff) 7%, transparent), transparent 53%);
  opacity: var(--focus-intensity, 0);
  transition: opacity 360ms cubic-bezier(.2,.8,.2,1);
}

.canvas-mount canvas {
  display: block;
  width: 100%;
  height: 100%;
  touch-action: none;
  cursor: grab;
}

.canvas-mount canvas:active { cursor: grabbing; }

.cinematic-transition {
  position: absolute;
  z-index: 8;
  top: -12%;
  bottom: -12%;
  left: -30%;
  width: 28%;
  pointer-events: none;
  background:
    linear-gradient(90deg,
      transparent 0%,
      rgba(57, 237, 205, .025) 18%,
      rgba(93, 239, 216, .16) 43%,
      rgba(214, 255, 248, .52) 50%,
      rgba(78, 219, 255, .14) 57%,
      transparent 82%);
  opacity: 0;
  filter: blur(7px) drop-shadow(0 0 22px rgba(66, 232, 207, .32));
  mix-blend-mode: screen;
  transform: translate3d(0, 0, 0) skewX(-9deg);
  will-change: opacity, transform;
}

.cinematic-transition::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 1px;
  background: rgba(223, 255, 250, .86);
  box-shadow: 0 0 12px rgba(91, 255, 223, .92), 0 0 44px rgba(67, 211, 255, .58);
}

.cinematic-transition.is-active {
  opacity: 1;
}

.stress-pulses {
  position: absolute;
  z-index: 3;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  mix-blend-mode: screen;
  transition: opacity 320ms cubic-bezier(.2,.8,.2,1);
}

.stress-pulses::before,
.stress-pulses i {
  position: absolute;
  top: var(--pulse-y, 55%);
  left: var(--pulse-x, 58%);
  width: clamp(150px, 19vw, 300px);
  aspect-ratio: 1.18;
  border-radius: 50%;
  transform: translate(-50%, -50%) scale(.28);
}

.stress-pulses::before {
  content: "";
  background: radial-gradient(ellipse, rgba(255, 164, 54, .2), rgba(255, 116, 45, .055) 42%, transparent 68%);
  filter: blur(8px);
  transition: background 320ms ease, transform 520ms cubic-bezier(.2,.8,.2,1);
}

.stress-pulses i {
  border: 1.5px solid rgba(255, 185, 78, .78);
  box-shadow: 0 0 12px rgba(255, 137, 43, .42), inset 0 0 12px rgba(255, 137, 43, .2);
  opacity: 0;
}

.stress-pulses.is-high { opacity: 1; }
.stress-pulses.is-high i { animation: stress-wave 1.28s cubic-bezier(.16,.64,.34,1) infinite; }
.stress-pulses.is-high i:nth-child(2) { animation-delay: .43s; }
.stress-pulses.is-high i:nth-child(3) { animation-delay: .86s; }

.stress-pulses.is-damped { opacity: .64; }
.stress-pulses.is-damped::before {
  background: radial-gradient(circle, rgba(53, 227, 178, .12), transparent 58%);
  transform: translate(-50%, -50%) scale(.42);
}
.stress-pulses.is-damped i:first-child {
  border-color: rgba(73, 240, 193, .44);
  box-shadow: 0 0 20px rgba(61, 226, 182, .18), inset 0 0 18px rgba(61, 226, 182, .1);
  opacity: .42;
  transform: translate(-50%, -50%) scale(.44);
}

@keyframes stress-wave {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(.32); }
  12% { opacity: .9; }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(1.32); }
}

.hero-message {
  position: absolute;
  z-index: 6;
  left: clamp(26px, 5vw, 74px);
  bottom: clamp(34px, 8vh, 92px);
  display: grid;
  gap: 8px;
  max-width: min(620px, 70vw);
  pointer-events: none;
  opacity: 0;
  transform: translate3d(0, 14px, 0);
  transition: opacity 440ms ease, transform 620ms cubic-bezier(.16,.84,.22,1);
}

.hero-message.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

.hero-message span {
  color: #50e4c8;
  font-size: clamp(9px, .8vw, 12px);
  font-weight: 760;
  letter-spacing: .24em;
}

.hero-message strong {
  color: #f4fbff;
  font-size: clamp(24px, 3vw, 48px);
  font-weight: 780;
  letter-spacing: .045em;
  line-height: 1.02;
  text-shadow: 0 0 26px rgba(82, 227, 201, .18);
}

.leader-overlay {
  position: absolute;
  z-index: 3;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
}

.leader-overlay path {
  fill: none;
  stroke: var(--feature-accent, #8fd1ff);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-dasharray: 100;
  stroke-dashoffset: 0;
  vector-effect: non-scaling-stroke;
  filter: drop-shadow(0 0 4px var(--feature-accent, #8fd1ff)) drop-shadow(0 0 12px rgba(78, 183, 255, 0.58));
  transition: opacity 180ms ease;
}

.leader-overlay path.is-drawing { animation: leader-draw 680ms cubic-bezier(.2,.78,.2,1) both; }

.leader-overlay circle {
  fill: #eaf6ff;
  stroke: var(--feature-accent, #8fd1ff);
  stroke-width: 2;
  filter: drop-shadow(0 0 8px var(--feature-accent, #8fd1ff));
  transition: opacity 180ms ease;
  opacity: 0;
  animation: none;
}

.leader-overlay circle.is-active {
  opacity: 1;
  animation: feature-pulse 1.8s ease-in-out infinite;
}

.vibration-process {
  --vibration-accent: #ffb84d;
  --vibration-level: 94%;
  position: absolute;
  z-index: 5;
  top: clamp(112px, 15vh, 168px);
  left: clamp(24px, 4vw, 62px);
  width: min(520px, 42vw);
  min-width: 430px;
  padding: 19px 20px 18px;
  border: 1px solid color-mix(in srgb, var(--vibration-accent) 48%, rgba(126, 171, 202, .3));
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(7, 14, 21, .96), rgba(9, 18, 27, .85)),
    radial-gradient(circle at 12% 0%, color-mix(in srgb, var(--vibration-accent) 16%, transparent), transparent 55%);
  box-shadow:
    0 22px 64px rgba(0, 0, 0, .4),
    0 0 38px color-mix(in srgb, var(--vibration-accent) 13%, transparent),
    inset 0 1px 0 rgba(255, 255, 255, .1);
  backdrop-filter: blur(20px);
  opacity: 0;
  transform: translate3d(-16px, 0, 0) scale(.985);
  transition:
    opacity 320ms ease,
    transform 520ms cubic-bezier(.16,.84,.22,1),
    border-color 520ms ease,
    box-shadow 520ms ease;
  pointer-events: none;
}

.vibration-process::after {
  content: "";
  position: absolute;
  inset: -1px;
  padding: 1px;
  border-radius: inherit;
  background: linear-gradient(112deg, transparent 14%, color-mix(in srgb, var(--vibration-accent) 46%, transparent), transparent 38%);
  background-size: 240% 100%;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  animation: vibration-panel-scan 3.4s ease-in-out infinite;
}

.vibration-process.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
}

.vibration-process-kicker {
  display: flex;
  align-items: center;
  gap: 8px;
  color: rgba(184, 220, 245, .72);
  font-size: 9px;
  font-weight: 720;
  letter-spacing: .17em;
  text-transform: uppercase;
}

.vibration-process-kicker > span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--vibration-accent);
  box-shadow: 0 0 14px var(--vibration-accent);
  animation: vibration-status-pulse 1.25s ease-in-out infinite;
}

.vibration-process-kicker b {
  margin-left: auto;
  color: color-mix(in srgb, var(--vibration-accent) 78%, white);
  font-size: 9px;
  letter-spacing: .13em;
}

.vibration-process h2 {
  margin: 11px 0 5px;
  color: #f5fbff;
  font-size: clamp(20px, 1.45vw, 25px);
  font-weight: 790;
  letter-spacing: .055em;
  line-height: 1.1;
  text-transform: uppercase;
  text-shadow: 0 0 20px color-mix(in srgb, var(--vibration-accent) 24%, transparent);
}

.vibration-process-state {
  min-height: 20px;
  margin: 0;
  color: #aec4d4;
  font-size: 13px;
  line-height: 1.42;
}

.vibration-wave {
  height: 72px;
  margin-top: 11px;
  overflow: hidden;
  border: 1px solid rgba(132, 181, 216, .16);
  border-radius: 10px;
  background:
    linear-gradient(rgba(132, 181, 216, .055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(132, 181, 216, .055) 1px, transparent 1px),
    rgba(1, 7, 12, .54);
  background-size: 100% 18px, 32px 100%, auto;
}

.vibration-wave svg { width: 100%; height: 100%; }

.vibration-wave path {
  fill: none;
  vector-effect: non-scaling-stroke;
}

.vibration-wave-reference {
  stroke: rgba(146, 187, 216, .2);
  stroke-width: 1;
  stroke-dasharray: 4 6;
}

#vibration-waveform {
  stroke: var(--vibration-accent);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 5px var(--vibration-accent));
  transition: stroke 420ms ease;
}

.vibration-level { margin-top: 11px; }

.vibration-level > div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 7px;
  color: rgba(169, 195, 213, .68);
  font-size: 9px;
  font-weight: 680;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.vibration-level strong {
  color: color-mix(in srgb, var(--vibration-accent) 82%, white);
  font-size: 9px;
  letter-spacing: .13em;
}

.vibration-level > i {
  position: relative;
  display: block;
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(145, 184, 213, .12);
}

.vibration-level > i > b {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--vibration-level);
  border-radius: inherit;
  background: linear-gradient(90deg, color-mix(in srgb, var(--vibration-accent) 55%, #2477ba), var(--vibration-accent));
  box-shadow: 0 0 15px var(--vibration-accent);
  transition: width 120ms linear, background 420ms ease;
}

.vibration-process-steps {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 5px;
  margin: 11px 0 0;
  padding: 0;
  list-style: none;
}

.vibration-process-steps li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 5px;
  align-items: center;
  min-height: 45px;
  padding: 6px;
  border: 1px solid rgba(137, 174, 200, .14);
  border-radius: 9px;
  background: rgba(255, 255, 255, .025);
  color: rgba(164, 187, 204, .56);
  transition: color 220ms ease, border-color 220ms ease, background 220ms ease, box-shadow 220ms ease;
}

.vibration-process-steps li.is-active {
  border-color: color-mix(in srgb, var(--vibration-accent) 58%, transparent);
  background: color-mix(in srgb, var(--vibration-accent) 10%, transparent);
  color: #eef9ff;
  box-shadow: inset 0 0 18px color-mix(in srgb, var(--vibration-accent) 8%, transparent);
}

.vibration-process-steps li.is-complete { color: rgba(139, 211, 255, .72); }

.vibration-process-steps em {
  color: var(--vibration-accent);
  font-size: 9px;
  font-style: normal;
  font-weight: 780;
}

.vibration-process-steps span {
  font-size: 7px;
  font-weight: 680;
  letter-spacing: .04em;
  line-height: 1.22;
  text-transform: uppercase;
}

.vibration-process-note {
  margin: 11px 0 0;
  padding-top: 10px;
  border-top: 1px solid rgba(143, 193, 228, .12);
  color: rgba(163, 188, 206, .68);
  font-size: 9px;
  line-height: 1.45;
}

.epoxy-process {
  --meter-progress: 0%;
  position: absolute;
  z-index: 5;
  top: clamp(112px, 15vh, 168px);
  left: clamp(24px, 4vw, 62px);
  width: min(390px, 31vw);
  min-width: 330px;
  padding: 19px 20px 18px;
  border: 1px solid rgba(64, 169, 255, 0.44);
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(7, 14, 23, 0.95), rgba(9, 20, 30, 0.83)),
    radial-gradient(circle at 12% 0%, rgba(45, 158, 255, 0.18), transparent 54%);
  box-shadow:
    0 22px 64px rgba(0, 0, 0, 0.4),
    0 0 38px rgba(38, 154, 255, 0.15),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px);
  opacity: 0;
  transform: translate3d(-16px, 0, 0) scale(.985);
  transition: opacity 320ms ease, transform 520ms cubic-bezier(.16,.84,.22,1);
  pointer-events: none;
}

.epoxy-process::after {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: linear-gradient(112deg, transparent 15%, rgba(87, 190, 255, 0.2), transparent 38%);
  background-size: 240% 100%;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  padding: 1px;
  animation: epoxy-panel-scan 3.8s ease-in-out infinite;
}

.epoxy-process.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
}

.epoxy-process-kicker {
  display: flex;
  align-items: center;
  gap: 8px;
  color: rgba(184, 220, 245, 0.72);
  font-size: 9px;
  font-weight: 720;
  letter-spacing: .17em;
  text-transform: uppercase;
}

.epoxy-process-kicker > span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #38a8ff;
  box-shadow: 0 0 14px #38a8ff;
  animation: epoxy-status-pulse 1.5s ease-in-out infinite;
}

.epoxy-process-kicker b {
  margin-left: auto;
  color: #75c8ff;
  font-size: 9px;
  letter-spacing: .13em;
}

.epoxy-process h2 {
  margin: 11px 0 5px;
  color: #f5fbff;
  font-size: clamp(20px, 1.45vw, 25px);
  font-weight: 790;
  letter-spacing: .055em;
  line-height: 1.1;
  text-transform: uppercase;
  text-shadow: 0 0 20px rgba(70, 177, 255, 0.22);
}

.epoxy-process-state {
  min-height: 36px;
  margin: 0;
  color: #aec4d4;
  font-size: 13px;
  line-height: 1.42;
}

.epoxy-process-meter {
  position: relative;
  height: 24px;
  margin-top: 14px;
  overflow: hidden;
  border: 1px solid rgba(91, 181, 244, 0.24);
  border-radius: 8px;
  background: rgba(1, 7, 12, 0.62);
}

.epoxy-process-meter i {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--meter-progress);
  background: linear-gradient(90deg, rgba(23, 117, 255, 0.45), #2e9cff 75%, #8bd7ff);
  box-shadow: 0 0 18px rgba(46, 156, 255, 0.7);
  transition: width 100ms linear;
}

.epoxy-process-meter span {
  position: absolute;
  inset: 0 8px 0 auto;
  display: grid;
  place-items: center;
  color: #e6f6ff;
  font-size: 9px;
  font-weight: 780;
  letter-spacing: .12em;
  text-shadow: 0 1px 3px #00101b;
}

.epoxy-process-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 7px;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
}

.epoxy-process-steps li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 7px;
  align-items: center;
  min-height: 45px;
  padding: 7px;
  border: 1px solid rgba(137, 174, 200, 0.14);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.025);
  color: rgba(164, 187, 204, 0.56);
  transition: color 220ms ease, border-color 220ms ease, background 220ms ease, box-shadow 220ms ease;
}

.epoxy-process-steps li.is-active {
  border-color: rgba(73, 175, 255, 0.62);
  background: rgba(40, 148, 238, 0.12);
  color: #e9f7ff;
  box-shadow: inset 0 0 18px rgba(41, 151, 255, 0.08), 0 0 16px rgba(41, 151, 255, 0.08);
}

.epoxy-process-steps li.is-complete { color: rgba(139, 211, 255, 0.72); }

.epoxy-process-steps em {
  color: #56b9ff;
  font-size: 9px;
  font-style: normal;
  font-weight: 780;
  letter-spacing: .06em;
}

.epoxy-process-steps span {
  font-size: 9px;
  font-weight: 680;
  letter-spacing: .04em;
  line-height: 1.22;
  text-transform: uppercase;
}

.epoxy-process-note {
  margin: 11px 0 0;
  padding-top: 10px;
  border-top: 1px solid rgba(143, 193, 228, 0.12);
  color: rgba(163, 188, 206, 0.7);
  font-size: 10px;
  line-height: 1.45;
}

.screen-callout {
  --accent: #bed2e7;
  --callout-progress: 0%;
  position: absolute;
  z-index: 4;
  top: 48%;
  right: clamp(26px, 5vw, 82px);
  display: flex;
  width: min(410px, 32vw);
  min-width: 310px;
  gap: 16px;
  align-items: stretch;
  padding: 18px 21px 18px 16px;
  border: 1px solid color-mix(in srgb, var(--accent) 54%, rgba(184, 205, 222, 0.38));
  border-radius: 17px;
  background: linear-gradient(135deg, rgba(9, 14, 20, 0.94), rgba(11, 17, 23, 0.76));
  box-shadow:
    0 18px 55px rgba(0, 0, 0, 0.42),
    0 0 28px color-mix(in srgb, var(--accent) 16%, transparent),
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    inset 0 0 28px color-mix(in srgb, var(--accent) 5%, transparent);
  backdrop-filter: blur(18px);
  opacity: 0;
  transform: translate3d(14px, -50%, 0);
  transition: opacity 260ms ease, transform 420ms cubic-bezier(.16,.84,.22,1);
  pointer-events: none;
}

.screen-callout::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 15%;
  width: 32%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  box-shadow: 0 0 12px var(--accent);
  animation: label-scan 2.6s ease-in-out infinite;
}

.screen-callout::after {
  content: "";
  position: absolute;
  right: 18px;
  bottom: -1px;
  left: 18px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    var(--accent) 0,
    var(--accent) var(--callout-progress),
    rgba(139, 177, 205, 0.13) var(--callout-progress),
    rgba(139, 177, 205, 0.13) 100%
  );
  box-shadow: 0 0 12px color-mix(in srgb, var(--accent) 58%, transparent);
}

.screen-callout.is-visible { opacity: 1; transform: translate3d(0, -50%, 0); }

.callout-accent {
  flex: 0 0 5px;
  width: 5px;
  min-height: 50px;
  margin: 1px 2px 1px 0;
  border-radius: 6px;
  background: var(--accent);
  box-shadow: 0 0 18px color-mix(in srgb, var(--accent) 58%, transparent);
}

.screen-callout strong,
.screen-callout small { display: block; }

.screen-callout strong {
  color: #f8fbff;
  font-size: clamp(17px, 1.35vw, 22px);
  font-weight: 760;
  letter-spacing: 0.075em;
  line-height: 1.18;
  text-shadow: 0 0 14px color-mix(in srgb, var(--accent) 32%, transparent);
}

.screen-callout small {
  margin-top: 7px;
  color: #aebbc6;
  font-size: clamp(12px, 0.85vw, 14px);
  line-height: 1.45;
}

.viewer-controls {
  position: absolute;
  z-index: 8;
  left: 50%;
  bottom: clamp(18px, 2.4vw, 32px);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px;
  border: 1px solid rgba(188, 205, 219, 0.22);
  border-radius: 999px;
  background: rgba(7, 11, 15, 0.76);
  box-shadow: 0 14px 42px rgba(0, 0, 0, 0.38), inset 0 1px 0 rgba(255, 255, 255, 0.09);
  backdrop-filter: blur(18px);
  transform: translateX(-50%);
}

.timeline-panel {
  --timeline-progress: 0%;
  position: absolute;
  z-index: 8;
  right: clamp(24px, 4vw, 60px);
  bottom: clamp(29px, 3.2vw, 44px);
  display: grid;
  grid-template-columns: 42px minmax(180px, 28vw) 42px;
  align-items: center;
  gap: 11px;
  padding: 11px 15px;
  border: 1px solid rgba(151, 197, 229, 0.25);
  border-radius: 14px;
  background: rgba(5, 10, 15, 0.76);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(18px);
}

.timeline-panel > span {
  color: rgba(207, 225, 239, 0.72);
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.08em;
  text-align: center;
}

.timeline-panel input {
  width: 100%;
  height: 18px;
  margin: 0;
  appearance: none;
  background: transparent;
  cursor: ew-resize;
}

.timeline-panel input::-webkit-slider-runnable-track {
  height: 3px;
  border-radius: 99px;
  background: linear-gradient(90deg, #35e9a1 var(--timeline-progress), rgba(154, 183, 204, 0.22) var(--timeline-progress));
  box-shadow: 0 0 10px rgba(53, 233, 161, 0.24);
}

.timeline-panel input::-moz-range-track {
  height: 3px;
  border-radius: 99px;
  background: linear-gradient(90deg, #35e9a1 var(--timeline-progress), rgba(154, 183, 204, 0.22) var(--timeline-progress));
}

.timeline-panel input::-webkit-slider-thumb {
  width: 15px;
  height: 15px;
  margin-top: -6px;
  appearance: none;
  border: 2px solid #dffff2;
  border-radius: 50%;
  background: #2fe09a;
  box-shadow: 0 0 0 5px rgba(47, 224, 154, 0.12), 0 0 16px rgba(47, 224, 154, 0.76);
}

.timeline-panel input::-moz-range-thumb {
  width: 13px;
  height: 13px;
  border: 2px solid #dffff2;
  border-radius: 50%;
  background: #2fe09a;
  box-shadow: 0 0 0 5px rgba(47, 224, 154, 0.12), 0 0 16px rgba(47, 224, 154, 0.76);
}

.timeline-panel input:focus-visible {
  outline: 2px solid rgba(79, 236, 177, 0.58);
  outline-offset: 6px;
  border-radius: 8px;
}

.viewer-controls button {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  color: #dce6ee;
  background: transparent;
  cursor: pointer;
  transition: background 160ms ease, color 160ms ease, transform 160ms ease;
}

.viewer-controls button span { font-size: 23px; line-height: 1; }

.viewer-controls button:hover,
.viewer-controls button:focus-visible {
  color: #fff;
  background: rgba(255, 255, 255, 0.09);
  outline: none;
}

.viewer-controls button:active { transform: scale(0.94); }

.viewer-controls .play-control {
  width: 53px;
  height: 53px;
  color: #07110d;
  background: linear-gradient(145deg, #91ffd1, #28da91 62%, #14b873);
  box-shadow: 0 0 30px rgba(37, 219, 143, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.56);
}

.viewer-controls .play-control:hover,
.viewer-controls .play-control:focus-visible {
  color: #030a07;
  background: linear-gradient(145deg, #b2ffe0, #3fe39f 62%, #1bc27b);
}

.viewer-controls .play-control span {
  font-size: 18px;
  font-weight: 850;
  letter-spacing: -0.12em;
}

.interaction-hint {
  position: absolute;
  z-index: 6;
  bottom: clamp(26px, 3.4vw, 48px);
  left: clamp(22px, 4vw, 62px);
  color: rgba(185, 197, 207, 0.68);
  font-size: 11px;
  letter-spacing: 0.08em;
  pointer-events: none;
}

.interaction-hint span { margin: 0 6px; color: rgba(104, 225, 168, 0.76); }

.loading-panel,
.error-panel {
  position: absolute;
  z-index: 10;
  top: 50%;
  left: 50%;
  display: flex;
  align-items: center;
  flex-direction: column;
  gap: 12px;
  min-width: 250px;
  padding: 26px 30px;
  border: 1px solid rgba(180, 205, 224, 0.22);
  border-radius: 20px;
  background: rgba(6, 10, 14, 0.9);
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(18px);
  transform: translate(-50%, -50%);
}

.loading-panel strong { font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; }
.loading-panel span { color: #7f8d99; font-size: 12px; }

.loading-ring {
  width: 30px;
  height: 30px;
  border: 2px solid rgba(255, 255, 255, 0.12);
  border-top-color: #34dd99;
  border-radius: 50%;
  animation: spin 800ms linear infinite;
}

.error-panel { color: #ffd7d7; font-size: 13px; text-align: center; }
[hidden] { display: none !important; }

@keyframes spin { to { transform: rotate(360deg); } }

@keyframes leader-draw {
  from { stroke-dashoffset: 100; opacity: 0; }
  18% { opacity: 1; }
  to { stroke-dashoffset: 0; opacity: 1; }
}

@keyframes feature-pulse {
  0%, 100% { r: 4.2px; opacity: .72; }
  50% { r: 5.2px; opacity: 1; }
}

@keyframes label-scan {
  0%, 100% { left: 10%; opacity: .35; }
  50% { left: 58%; opacity: 1; }
}

@keyframes epoxy-panel-scan {
  0%, 100% { background-position: 120% 0; opacity: .35; }
  55% { background-position: -40% 0; opacity: 1; }
}

@keyframes epoxy-status-pulse {
  0%, 100% { opacity: .55; transform: scale(.82); }
  50% { opacity: 1; transform: scale(1.08); }
}

@keyframes vibration-panel-scan {
  0%, 100% { background-position: 120% 0; opacity: .3; }
  55% { background-position: -40% 0; opacity: .92; }
}

@keyframes vibration-status-pulse {
  0%, 100% { opacity: .45; transform: scale(.8); }
  50% { opacity: 1; transform: scale(1.12); }
}

@media (max-width: 760px) {
  .stress-pulses::before,
  .stress-pulses i {
    width: min(52vw, 250px);
  }
  .viewer-header { top: 20px; left: 20px; }
  .hero-message {
    right: 22px;
    bottom: 154px;
    left: 22px;
    max-width: none;
  }
  .vibration-process,
  .epoxy-process {
    top: 82px;
    right: 18px;
    left: 18px;
    width: auto;
    min-width: 0;
    padding: 15px 16px 14px;
  }
  .epoxy-process h2 { font-size: 17px; }
  .vibration-process h2 { font-size: 17px; }
  .vibration-process-state { font-size: 11px; }
  .vibration-wave { height: 56px; }
  .epoxy-process-state { min-height: 31px; font-size: 11px; }
  .epoxy-process-note { display: none; }
  .vibration-process-note { display: none; }
  .vibration-process-steps {
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
  }
  .vibration-process-steps li {
    grid-template-columns: 1fr;
    gap: 2px;
    padding: 5px 3px;
    text-align: center;
  }
  .vibration-process-steps span { font-size: 7px; }
  .vibration-process-steps li,
  .epoxy-process-steps li { min-height: 39px; }
  .screen-callout {
    top: auto;
    right: 18px;
    bottom: 176px;
    left: 18px;
    width: auto;
    min-width: 0;
    transform: translate3d(0, 10px, 0);
  }
  .screen-callout.is-visible { transform: translate3d(0, 0, 0); }
  .interaction-hint { display: none; }
  .viewer-controls { bottom: 20px; }
  .timeline-panel {
    right: 18px;
    bottom: 92px;
    left: 18px;
    grid-template-columns: 38px 1fr 38px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .canvas-mount::after,
  .vibration-process,
  .vibration-process::after,
  .vibration-process-kicker > span,
  .epoxy-process,
  .epoxy-process::after,
  .epoxy-process-kicker > span,
  .screen-callout,
  .leader-overlay path,
  .leader-overlay circle,
  .viewer-controls button { transition: none; }
  .stress-pulses.is-high i { animation: none; }
}

/* Clean, passive presentation used inside the website hero. */
.hero-embed,
.hero-embed body {
  height: 100%;
  min-height: 0;
  background: transparent !important;
  background-color: transparent !important;
  color-scheme: normal;
}

.hero-embed .viewer-shell {
  width: 100%;
  height: 100%;
  min-height: 0;
  background: transparent !important;
  background-color: transparent !important;
}

.hero-embed .viewer-stage,
.hero-embed .canvas-mount,
.hero-embed .canvas-mount canvas {
  background: transparent !important;
  background-color: transparent !important;
}

.hero-embed .viewer-shell::after {
  display: none;
}

.hero-embed .viewer-header,
.hero-embed .hero-message,
.hero-embed .vibration-process,
.hero-embed .epoxy-process,
.hero-embed .stress-pulses,
.hero-embed .ambient,
.hero-embed .cinematic-transition,
.hero-embed .interaction-hint,
.hero-embed .viewer-controls {
  display: none !important;
}

.hero-embed .canvas-mount canvas {
  cursor: default;
  pointer-events: none;
}

.hero-embed .canvas-mount::after {
  background: none;
  opacity: 0;
}

.hero-embed .leader-overlay {
  display: block;
  z-index: 5;
}

.hero-embed .leader-overlay path {
  stroke-width: 1.45;
  filter: drop-shadow(0 0 4px var(--feature-accent, #8fd1ff));
}

.hero-embed .screen-callout {
  display: flex;
  right: 2.5%;
  width: min(265px, 36vw);
  min-width: 0;
  gap: 10px;
  padding: 12px 14px 12px 11px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(6, 10, 15, .84), rgba(8, 13, 19, .7));
  box-shadow: 0 12px 38px rgba(0, 0, 0, .28), 0 0 20px color-mix(in srgb, var(--accent) 12%, transparent);
  backdrop-filter: blur(12px);
}

.hero-embed .callout-accent {
  flex-basis: 3px;
  width: 3px;
  min-height: 35px;
}

.hero-embed .screen-callout strong {
  font-size: clamp(10px, 1.1vw, 14px);
  letter-spacing: .07em;
}

.hero-embed .screen-callout small {
  margin-top: 4px;
  font-size: clamp(8px, .75vw, 10px);
  line-height: 1.35;
}

@media (max-width: 760px) {
  .hero-embed .screen-callout {
    right: 4%;
    bottom: calc(100px + env(safe-area-inset-bottom, 0px));
    left: auto;
    width: min(245px, 56vw);
    transform: translate3d(0, 8px, 0);
  }

  .hero-embed .screen-callout.is-visible {
    transform: translate3d(0, 0, 0);
  }
}

.hero-embed .loading-panel {
  min-width: 0;
  padding: 18px;
  border: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.hero-embed .loading-panel strong,
.hero-embed .loading-panel span {
  display: none;
}

.hero-embed .loading-ring {
  border-color: rgba(255, 255, 255, .08);
  border-top-color: #5c96ff;
}

/* Standalone playback, kept separate from the hidden viewer/zoom controls. */
.hero-embed .timeline-panel {
  display: grid;
  grid-template-columns: 44px 42px minmax(0, 1fr) 42px;
  gap: 12px;
  width: min(680px, calc(100% - 32px));
  left: 50%;
  right: auto;
  bottom: calc(24px + env(safe-area-inset-bottom, 0px));
  transform: translateX(-50%);
  padding: 8px 14px 8px 8px;
  border-color: rgba(61, 255, 153, .23);
}

.hero-embed .timeline-panel > span {
  font-size: 12px;
  letter-spacing: .02em;
  color: #cbd8e2;
}

.hero-embed .timeline-panel input {
  min-width: 0;
  height: 44px;
  touch-action: none;
}

.hero-embed .timeline-panel input::-webkit-slider-runnable-track {
  background: linear-gradient(90deg, #3dff99 var(--timeline-progress), rgba(154, 183, 204, .22) var(--timeline-progress));
  box-shadow: 0 0 10px rgba(61, 255, 153, .25);
}

.hero-embed .timeline-panel input::-moz-range-track {
  background: linear-gradient(90deg, #3dff99 var(--timeline-progress), rgba(154, 183, 204, .22) var(--timeline-progress));
}

.hero-embed .timeline-panel input::-webkit-slider-thumb {
  background: #3dff99;
}

.hero-embed .timeline-panel input::-moz-range-thumb {
  background: #3dff99;
}

.hero-embed .timeline-panel .play-control {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid rgba(213, 255, 231, .5);
  border-radius: 50%;
  color: #042310;
  background: linear-gradient(145deg, #a2ffcb, #3dff99 60%, #18db78);
  cursor: pointer;
  box-shadow: 0 0 22px rgba(61, 255, 153, .2);
}

.hero-embed .timeline-panel .play-control:hover {
  filter: brightness(1.12);
}

.hero-embed .timeline-panel .play-control:focus-visible {
  outline: 2px solid #e0ffed;
  outline-offset: 3px;
}

.hero-embed .timeline-panel .play-control span {
  font-size: 18px;
  font-weight: 800;
  line-height: 1;
}

@media (max-width: 480px) {
  .hero-embed .timeline-panel {
    grid-template-columns: 44px 35px minmax(0, 1fr) 35px;
    gap: 8px;
    bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  }
}

/* The website hero already provides its own engineering note and interaction
   affordance. Keep playback controls in the standalone viewer only. */
.hero-embed .timeline-panel {
  display: none !important;
}
