:root {
  --bg: #041011;
  --ink: #f6fff7;
  --muted: rgba(246, 255, 247, 0.72);
  --line: rgba(246, 255, 247, 0.18);
  --panel: rgba(3, 13, 14, 0.72);
  --mint: #4dffb5;
  --blue: #78dcff;
  --amber: #e9c46a;
  --coral: #ff7a59;
  --accent: #4dffb5;
  --accent-rgb: 77, 255, 181;
  --accent-2: #78dcff;
  --accent-2-rgb: 120, 220, 255;
  --project-atmosphere: rgba(77, 255, 181, 0.18);
  --radius: 8px;
  --ease: cubic-bezier(0.2, 0.86, 0.2, 1);
  --project-index: 0;
  --project-total: 3;
  --project-total-width: 300vw;
  --viewport-width: 100vw;
  --project-shift: 0vw;
  --project-progress: 0;
  --turntable-frames: 36;
  --turntable-strip-width: 100%;
  --rotation-frame: 0;
  --rotation-loop-progress: 0;
  --rotation-progress: 0;
  --frame-residual: 0;
  --frame-nudge-x: 0px;
  --frame-nudge-yaw: 0deg;
  --frame-nudge-z: 0px;
  --rotation-offset: 0%;
  --rotation-blend-offset: 0%;
  --rotation-blend-opacity: 0;
  --prev-frame: 0;
  --prev-offset: 0%;
  --next-frame: 1;
  --next-offset: 0%;
  --turn-direction: 1;
  --turn-deg: 0deg;
  --scene-progress: 0;
  --scene-sweep: 0deg;
  --backdrop-shift: 0%;
  --stage-tilt: 0deg;
  --stage-tilt-mobile: 0deg;
  color-scheme: dark;
}

body[data-project="xingdian"] {
  --accent: #4dffb5;
  --accent-rgb: 77, 255, 181;
  --accent-2: #78dcff;
  --accent-2-rgb: 120, 220, 255;
  --project-atmosphere: rgba(77, 255, 181, 0.18);
}

body[data-project="study"] {
  --accent: #78dcff;
  --accent-rgb: 120, 220, 255;
  --accent-2: #e9c46a;
  --accent-2-rgb: 233, 196, 106;
  --project-atmosphere: rgba(120, 220, 255, 0.18);
}

body[data-project="law"] {
  --accent: #e9c46a;
  --accent-rgb: 233, 196, 106;
  --accent-2: #ff7a59;
  --accent-2-rgb: 255, 122, 89;
  --project-atmosphere: rgba(233, 196, 106, 0.17);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  overflow: hidden;
  background: var(--bg);
  color: var(--ink);
  font-family:
    "Aptos",
    "Microsoft YaHei UI",
    "Microsoft YaHei",
    "PingFang SC",
    "Noto Sans CJK SC",
    system-ui,
    sans-serif;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 90;
  pointer-events: none;
}

body::before {
  opacity: 0.11;
  mix-blend-mode: soft-light;
  background:
    radial-gradient(circle at 18% 28%, rgba(var(--accent-rgb), 0.18), transparent 34%),
    radial-gradient(circle at 78% 72%, rgba(var(--accent-2-rgb), 0.1), transparent 28%),
    linear-gradient(115deg, transparent 0 43%, rgba(255, 255, 255, 0.045) 49%, transparent 56% 100%);
  transition: background 820ms var(--ease);
}

body::after {
  opacity: 0.035;
  background:
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.12) 0 1px, transparent 1px 6px),
    radial-gradient(circle at 50% 50%, transparent 0 64%, rgba(0, 0, 0, 0.72) 100%);
}

button,
a {
  font: inherit;
}

button {
  cursor: pointer;
}

.skip-nav {
  position: fixed;
  left: 18px;
  top: 18px;
  z-index: 100;
  transform: translateY(-120%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(3, 13, 14, 0.92);
  color: var(--ink);
  padding: 10px 14px;
  text-decoration: none;
  transition: transform 160ms var(--ease);
}

.skip-nav:focus {
  transform: translateY(0);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.site-header {
  position: fixed;
  z-index: 80;
  inset: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 28px clamp(24px, 5vw, 72px);
  pointer-events: none;
}

.brand,
.project-tabs {
  pointer-events: auto;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 850;
}

.brand-text {
  display: grid;
  gap: 2px;
}

.brand-text strong {
  font-size: 16px;
  line-height: 1;
}

.brand-text small {
  color: rgba(246, 255, 247, 0.58);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  width: 31px;
  height: 31px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;
  background:
    linear-gradient(135deg, transparent 36%, var(--accent) 37% 52%, transparent 53%),
    radial-gradient(circle at 30% 30%, #fff 0 18%, transparent 20%),
    rgba(255, 255, 255, 0.1);
  box-shadow: 0 0 38px rgba(var(--accent-rgb), 0.24);
}

.project-tabs {
  display: flex;
  gap: 8px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(3, 13, 14, 0.46);
  backdrop-filter: blur(18px);
}

.project-tab {
  min-width: 62px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgba(246, 255, 247, 0.58);
  padding: 9px 14px;
  font-weight: 850;
  transition:
    background 180ms var(--ease),
    color 180ms var(--ease),
    transform 180ms var(--ease);
}

.project-tab.is-active {
  background: linear-gradient(135deg, var(--ink), color-mix(in srgb, var(--accent) 30%, var(--ink)));
  color: #041011;
}

.project-tab:hover {
  transform: translateY(-1px);
}

.portfolio-shell {
  width: var(--viewport-width);
  min-height: 100svh;
  overflow: hidden;
}

.project-track {
  display: flex;
  width: var(--project-total-width);
  min-height: 100svh;
  transform: translate3d(var(--project-shift), 0, 0);
  transition: transform 820ms var(--ease);
  will-change: transform;
}

body.is-initializing .project-track,
body.is-initializing .turntable-strip,
body.is-initializing .scene-backdrop,
body.is-initializing .project-slide::after {
  transition: none !important;
}

body.is-case-open .project-track {
  filter: brightness(0.76) saturate(0.82);
}

.project-slide {
  position: relative;
  flex: 0 0 var(--viewport-width);
  min-height: 100svh;
  overflow: hidden;
  isolation: isolate;
}

.project-slide::after {
  content: "";
  position: absolute;
  z-index: 12;
  inset: 0 auto 0 -20vw;
  width: 22vw;
  pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(var(--accent-rgb), 0.16), transparent);
  transform: skewX(-13deg) translateX(calc(var(--project-progress) * 42vw));
  opacity: 0.52;
  transition:
    transform 820ms var(--ease),
    opacity 360ms var(--ease);
}

.environment {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.scene-backdrop,
.project-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

.scene-backdrop {
  opacity: 0;
  filter: saturate(1.08) contrast(1.06) brightness(0.96);
  transform: scale(1.04) translateX(var(--backdrop-shift));
  transition:
    opacity 720ms var(--ease),
    transform 760ms var(--ease),
    filter 760ms var(--ease);
}

body[data-scene="briefing"] .office-backdrop,
body[data-scene="voice"] .office-backdrop,
body[data-scene="dispatch"] .mall-backdrop,
body[data-scene="patrol"] .mall-backdrop,
body[data-scene="review"] .hq-backdrop {
  opacity: 1;
}

body[data-scene="briefing"] .office-backdrop,
body[data-scene="voice"] .office-backdrop,
body[data-scene="review"] .hq-backdrop {
  filter: saturate(1.04) contrast(1.06) brightness(0.76);
}

body[data-scene="review"] .hq-backdrop {
  filter: saturate(1) contrast(1.06) brightness(0.66);
}

body[data-scene="patrol"] .mall-backdrop {
  filter: saturate(1.08) contrast(1.05) brightness(0.98);
}

body[data-scene="dispatch"] .mall-backdrop {
  filter: saturate(1.08) contrast(1.06) brightness(0.9);
}

.environment-grade,
.project-grade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(4, 16, 17, 0.82), rgba(4, 16, 17, 0.52) 25%, rgba(4, 16, 17, 0.1) 52%, rgba(4, 16, 17, 0.28) 100%),
    linear-gradient(180deg, rgba(4, 16, 17, 0.46), transparent 40%, rgba(4, 16, 17, 0.72) 100%),
    radial-gradient(circle at 62% 36%, var(--project-atmosphere), transparent 34%);
}

.environment::after,
.portfolio-project::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  opacity: 0.3;
  pointer-events: none;
  background:
    linear-gradient(rgba(255, 255, 255, 0.032) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.028) 1px, transparent 1px);
  background-size: 68px 68px;
  mask-image: linear-gradient(90deg, transparent, #000 18%, #000 82%, transparent);
}

.office-layer,
.dispatch-layer,
.scan-layer,
.review-layer {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity 560ms var(--ease),
    transform 720ms var(--ease);
}

body[data-scene="briefing"] .office-layer,
body[data-scene="voice"] .office-layer,
body[data-scene="dispatch"] .dispatch-layer,
body[data-scene="patrol"] .scan-layer,
body[data-scene="review"] .review-layer {
  opacity: 1;
  transform: translateY(0);
}

body[data-scene="briefing"] .office-layer,
body[data-scene="voice"] .office-layer {
  opacity: 0.72;
}

.floor-map {
  position: absolute;
  z-index: 3;
  left: 44%;
  bottom: clamp(120px, 14vh, 152px);
  width: min(480px, 33vw);
  height: 76px;
  border: 1px solid rgba(var(--accent-rgb), 0.26);
  border-radius: var(--radius);
  opacity: 0.64;
  background:
    linear-gradient(90deg, rgba(var(--accent-rgb), 0.12), transparent 52%, rgba(var(--accent-2-rgb), 0.1)),
    rgba(3, 13, 14, 0.48);
  box-shadow:
    inset 0 0 34px rgba(var(--accent-rgb), 0.08),
    0 26px 70px rgba(0, 0, 0, 0.28);
  transform:
    translateX(-50%)
    skewX(-10deg)
    rotateZ(-1deg)
    translateY(calc(var(--scene-progress) * -14px));
  transform-origin: center bottom;
  transition:
    opacity 620ms var(--ease),
    transform 720ms var(--ease),
    border-color 620ms var(--ease);
}

.floor-map::before,
.floor-map::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.floor-map::before {
  left: 28px;
  right: 28px;
  top: 50%;
  height: 1px;
  border: 0;
  background:
    linear-gradient(90deg, rgba(var(--accent-rgb), 0.08), rgba(var(--accent-rgb), 0.72), rgba(var(--accent-2-rgb), 0.3));
  box-shadow: 0 0 20px rgba(var(--accent-rgb), 0.28);
}

.floor-map::after {
  left: 24px;
  right: 24px;
  top: 50%;
  height: 22px;
  opacity: 0.75;
  background:
    radial-gradient(circle at 16% 50%, rgba(var(--accent-rgb), 0.72) 0 4px, transparent 5px),
    radial-gradient(circle at 36% 50%, rgba(var(--accent-rgb), 0.62) 0 4px, transparent 5px),
    radial-gradient(circle at 64% 50%, rgba(var(--accent-2-rgb), 0.58) 0 4px, transparent 5px),
    radial-gradient(circle at 84% 50%, rgba(var(--accent-2-rgb), 0.5) 0 4px, transparent 5px);
  transform: translateY(-50%);
}

.floor-map span {
  position: absolute;
  z-index: 1;
  min-width: 78px;
  border: 1px solid rgba(246, 255, 247, 0.14);
  border-radius: 999px;
  background: rgba(3, 13, 14, 0.76);
  color: rgba(246, 255, 247, 0.78);
  padding: 6px 9px;
  text-align: center;
  font-size: 12px;
  font-weight: 900;
  box-shadow: 0 0 0 rgba(var(--accent-rgb), 0);
  transform: skewX(10deg) rotateZ(1deg);
  transition:
    color 460ms var(--ease),
    border-color 460ms var(--ease),
    background 460ms var(--ease),
    box-shadow 460ms var(--ease),
    transform 460ms var(--ease);
}

.floor-map [data-zone="tile"] {
  left: 3%;
  top: 18px;
}

.floor-map [data-zone="cabinet"] {
  left: 26%;
  top: 18px;
}

.floor-map [data-zone="bath"] {
  left: 52%;
  top: 18px;
}

.floor-map [data-zone="floor"] {
  right: 3%;
  top: 18px;
}

body[data-scene="dispatch"] .floor-map,
body[data-scene="patrol"] .floor-map {
  opacity: 0.9;
  border-color: rgba(var(--accent-rgb), 0.42);
}

body[data-scene="dispatch"] .floor-map [data-zone="tile"],
body[data-scene="dispatch"] .floor-map [data-zone="cabinet"],
body[data-scene="patrol"] .floor-map [data-zone="bath"],
body[data-scene="patrol"] .floor-map [data-zone="floor"] {
  border-color: rgba(var(--accent-rgb), 0.72);
  background: rgba(var(--accent-rgb), 0.16);
  color: var(--ink);
  box-shadow: 0 0 22px rgba(var(--accent-rgb), 0.34);
  transform: skewX(10deg) rotateZ(1deg) translateY(-4px);
}

.office-desk {
  position: absolute;
  left: 47%;
  top: 63%;
  width: min(340px, 26vw);
  height: 120px;
  border: 1px solid rgba(246, 255, 247, 0.18);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, rgba(246, 255, 247, 0.12), rgba(246, 255, 247, 0.04)),
    rgba(3, 13, 14, 0.48);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.34);
  opacity: 0.46;
  transform: perspective(900px) rotateX(62deg) rotateZ(-2deg);
}

.office-screen {
  position: absolute;
  left: 58%;
  top: 26%;
  width: 260px;
  padding: 18px;
  border: 1px solid rgba(var(--accent-rgb), 0.42);
  border-radius: var(--radius);
  background: rgba(3, 13, 14, 0.68);
  box-shadow: 0 0 58px rgba(var(--accent-rgb), 0.18);
  backdrop-filter: blur(18px);
  opacity: 0.72;
}

.office-screen span {
  display: block;
  height: 10px;
  margin: 10px 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), transparent);
}

.office-screen span:nth-child(2) {
  width: 68%;
  opacity: 0.58;
}

.office-screen span:nth-child(3) {
  width: 46%;
  opacity: 0.38;
}

.dispatch-layer span,
.scan-layer span,
.review-layer span {
  position: absolute;
  display: block;
  border: 1px solid rgba(var(--accent-rgb), 0.42);
  border-radius: var(--radius);
  background: rgba(3, 13, 14, 0.55);
  box-shadow: 0 0 48px rgba(var(--accent-rgb), 0.16);
  backdrop-filter: blur(14px);
}

.dispatch-layer::before,
.scan-layer::before,
.review-layer::before {
  content: "";
  position: absolute;
  pointer-events: none;
}

.dispatch-layer::before {
  left: 48%;
  top: 44%;
  width: 34%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(var(--accent-rgb), 0.8), transparent);
  filter: drop-shadow(0 0 14px rgba(var(--accent-rgb), 0.5));
  transform: rotate(17deg);
  animation: flowLine 2.8s infinite var(--ease);
}

.dispatch-layer span {
  width: 142px;
  height: 64px;
  animation: dispatchFloat 3.8s infinite ease-in-out;
}

.dispatch-layer span:nth-child(1) {
  left: 57%;
  top: 38%;
}

.dispatch-layer span:nth-child(2) {
  left: 70%;
  top: 58%;
  animation-delay: 0.25s;
}

.dispatch-layer span:nth-child(3) {
  left: 45%;
  top: 62%;
  animation-delay: 0.5s;
}

.scan-layer span {
  width: 210px;
  height: 96px;
}

.scan-layer::before {
  left: 10%;
  right: 9%;
  top: 53%;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(var(--accent-2-rgb), 0.94), rgba(var(--accent-rgb), 0.76), transparent);
  box-shadow: 0 0 22px rgba(var(--accent-rgb), 0.36);
  transform: translateY(-50%);
  animation: scanSweep 2.9s infinite var(--ease);
}

.scan-layer span::after {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(var(--accent-2-rgb), 0.5);
  border-radius: calc(var(--radius) - 2px);
}

.scan-layer span:nth-child(1) {
  left: 18%;
  top: 46%;
}

.scan-layer span:nth-child(2) {
  right: 11%;
  top: 42%;
}

.scan-layer span:nth-child(3) {
  left: 48%;
  bottom: 18%;
}

.review-layer span {
  right: 9%;
  width: 300px;
  height: 56px;
}

.review-layer::before {
  right: 14%;
  top: 23%;
  width: 280px;
  height: 280px;
  border: 1px solid rgba(var(--accent-rgb), 0.18);
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(var(--accent-rgb), 0.13), transparent 56%),
    conic-gradient(from 120deg, transparent, rgba(var(--accent-rgb), 0.22), transparent 34%);
  animation: reviewPulse 4.6s infinite linear;
}

.review-layer span:nth-child(1) {
  top: 28%;
}

.review-layer span:nth-child(2) {
  top: 39%;
  width: 250px;
  opacity: 0.5;
}

.review-layer span:nth-child(3) {
  top: 50%;
  width: 190px;
  opacity: 0.58;
}

.character-stage {
  position: absolute;
  z-index: 3;
  left: 52.5%;
  top: 51%;
  width: min(560px, 38vw);
  aspect-ratio: 0.72;
  transform:
    translate(-40%, -49%)
    perspective(1200px)
    rotateY(var(--stage-tilt));
  transform-style: preserve-3d;
  touch-action: none;
  user-select: none;
  cursor: grab;
  transition: transform 360ms var(--ease);
}

.character-stage:active {
  cursor: grabbing;
}

.turntable-affordance {
  position: absolute;
  z-index: 34;
  left: clamp(560px, 45vw, 720px);
  top: clamp(116px, 15vh, 150px);
  display: grid;
  gap: 4px;
  min-width: 210px;
  border: 1px solid rgba(var(--accent-rgb), 0.62);
  border-radius: 999px;
  background:
    linear-gradient(135deg, rgba(var(--accent-rgb), 0.24), rgba(246, 255, 247, 0.07)),
    rgba(3, 13, 14, 0.86);
  box-shadow:
    0 22px 58px rgba(0, 0, 0, 0.34),
    0 0 34px rgba(var(--accent-rgb), 0.28);
  padding: 10px 16px 10px 46px;
  color: var(--ink);
  pointer-events: none;
  transform: rotateZ(-2deg);
  transition:
    opacity 260ms var(--ease),
    transform 260ms var(--ease),
    border-color 260ms var(--ease);
}

.turntable-affordance::before {
  content: "";
  position: absolute;
  left: 15px;
  top: 50%;
  width: 20px;
  height: 10px;
  border-left: 2px solid var(--accent);
  border-right: 2px solid var(--accent);
  transform: translateY(-50%);
  filter: drop-shadow(0 0 12px rgba(var(--accent-rgb), 0.58));
}

.turntable-affordance strong {
  font-size: 12px;
  line-height: 1.1;
}

.turntable-affordance span {
  color: rgba(246, 255, 247, 0.64);
  font-size: 10px;
  font-weight: 780;
  line-height: 1.1;
}

.character-stage:hover + .turntable-affordance,
.character-stage:focus-visible + .turntable-affordance,
body.is-turntable-wheel-hint .turntable-affordance {
  border-color: rgba(var(--accent-rgb), 0.72);
  transform: rotateZ(0deg) translateY(-4px);
}

body.is-dragging-character .turntable-affordance,
body.is-turning .turntable-affordance {
  opacity: 0;
  transform: rotateZ(0deg) translateY(-14px) scale(0.96);
}

body.has-used-turntable:not(.is-dragging-character):not(.is-turning) .turntable-affordance {
  opacity: 0.68;
}

body.is-character-autoplaying .turntable-affordance {
  border-color: rgba(var(--accent-rgb), 0.74);
  box-shadow:
    0 22px 58px rgba(0, 0, 0, 0.34),
    0 0 42px rgba(var(--accent-rgb), 0.34);
}

body.is-character-autoplaying .turntable-affordance::before {
  animation: autoplaySightline 1.6s ease-in-out infinite;
}

.character-rig {
  position: absolute;
  inset: 0;
  z-index: 2;
  transform-style: preserve-3d;
  animation: none;
  will-change: auto;
}

body[data-scene="briefing"] .character-rig {
  animation: none;
}

body[data-scene="voice"] .character-rig {
  animation: none;
}

body[data-scene="dispatch"] .character-rig {
  animation: none;
}

body[data-scene="patrol"] .character-rig {
  animation: none;
}

body[data-scene="review"] .character-rig {
  animation: none;
}

body.is-turning .character-rig {
  animation: none;
}

.turntable-window {
  position: absolute;
  overflow: hidden;
  border-radius: 42% 42% 24% 24% / 16% 16% 8% 8%;
  filter:
    drop-shadow(0 20px 26px rgba(0, 0, 0, 0.3));
  transform-origin: center bottom;
  pointer-events: none;
  transition:
    transform 650ms var(--ease),
    opacity 650ms var(--ease),
    filter 650ms var(--ease);
}

.turntable-window--main {
  inset: 0;
  z-index: 3;
  transform:
    translate3d(var(--frame-nudge-x), 0, calc(36px + var(--frame-nudge-z)))
    rotateY(var(--frame-nudge-yaw))
    scale(1);
  transition:
    opacity 180ms var(--ease),
    filter 180ms var(--ease);
}

.turntable-window--blend {
  inset: 0;
  z-index: 4;
  opacity: var(--rotation-blend-opacity);
  transform:
    translate3d(var(--frame-nudge-x), 0, calc(36px + var(--frame-nudge-z)))
    rotateY(var(--frame-nudge-yaw))
    scale(1);
  transition: none;
}

.turntable-window--side {
  inset: 7% 9% 6%;
  z-index: 1;
  opacity: 0;
  filter:
    saturate(0.82)
    brightness(0.78)
    drop-shadow(0 18px 28px rgba(0, 0, 0, 0.24));
  pointer-events: none;
}

body.is-dragging-character .turntable-window--side,
body.is-turntable-gliding .turntable-window--side {
  opacity: 0;
}

.turntable-window--prev {
  transform:
    translate3d(-36%, 1%, -115px)
    rotateY(20deg)
    rotateZ(-4deg)
    scale(0.68);
}

.turntable-window--next {
  transform:
    translate3d(37%, 2%, -120px)
    rotateY(-22deg)
    rotateZ(4deg)
    scale(0.66);
}

.turntable-strip {
  position: absolute;
  left: 0;
  top: 0;
  width: var(--turntable-strip-width);
  height: 100%;
  object-fit: contain;
  object-position: center center;
  image-rendering: auto;
  transition: none;
  transform: translateZ(0);
  will-change: auto;
  user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
}

.turntable-strip--main {
  transform: none;
}

.turntable-strip--blend {
  transform: none;
}

.turntable-strip--prev {
  transform: none;
}

.turntable-strip--next {
  transform: none;
}

.character-gesture {
  position: absolute;
  z-index: 4;
  inset: 0;
  pointer-events: none;
}

.character-gesture span {
  position: absolute;
  opacity: 0;
  border-radius: 999px;
  background: rgba(var(--accent-rgb), 0.9);
  box-shadow: 0 0 28px rgba(var(--accent-rgb), 0.42);
  transition:
    opacity 260ms var(--ease),
    transform 420ms var(--ease);
}

body[data-scene="briefing"] .character-gesture span:nth-child(1) {
  left: 70%;
  top: 18%;
  width: 54px;
  height: 22px;
  opacity: 0.5;
  background: linear-gradient(135deg, rgba(var(--accent-rgb), 0.72), rgba(var(--accent-2-rgb), 0.52));
  animation: briefingCard 4.8s ease-in-out infinite;
}

body[data-scene="voice"] .character-gesture span {
  left: 66%;
  top: 31%;
  width: 10px;
  height: 10px;
  opacity: 0.78;
  animation: voiceDots 1.3s ease-in-out infinite;
}

body[data-scene="voice"] .character-gesture span:nth-child(2) {
  margin-left: 18px;
  animation-delay: 130ms;
}

body[data-scene="voice"] .character-gesture span:nth-child(3) {
  margin-left: 36px;
  animation-delay: 260ms;
}

body[data-scene="dispatch"] .character-gesture span {
  left: 69%;
  top: 42%;
  width: 62px;
  height: 20px;
  opacity: 0.86;
  background: rgba(var(--accent-2-rgb), 0.92);
  animation: dispatchTicket 2.2s ease-in-out infinite;
}

body[data-scene="dispatch"] .character-gesture span:nth-child(2) {
  animation-delay: 260ms;
}

body[data-scene="dispatch"] .character-gesture span:nth-child(3) {
  animation-delay: 520ms;
}

body[data-scene="patrol"] .character-gesture span:nth-child(1) {
  left: 24%;
  top: 48%;
  width: 54%;
  height: 3px;
  opacity: 0.9;
  border-radius: 0;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  animation: patrolScan 1.7s ease-in-out infinite;
}

body[data-scene="review"] .character-gesture span {
  left: 22%;
  top: 22%;
  width: 58%;
  aspect-ratio: 1;
  opacity: 0.34;
  border: 1px solid rgba(var(--accent-rgb), 0.78);
  background: transparent;
  animation: reviewOrbit 4.2s linear infinite;
}

body[data-scene="review"] .character-gesture span:nth-child(2) {
  inset: auto;
  left: 29%;
  top: 29%;
  width: 44%;
  animation-duration: 3.5s;
  animation-direction: reverse;
}

body[data-scene="review"] .character-gesture span:nth-child(3) {
  inset: auto;
  left: 36%;
  top: 36%;
  width: 30%;
  animation-duration: 2.8s;
}

.rotation-dialogue {
  position: absolute;
  z-index: 30;
  left: clamp(540px, 43vw, 730px);
  top: 20%;
  width: min(340px, 29vw);
  border: 1px solid rgba(var(--accent-rgb), 0.58);
  border-radius: 18px 18px 18px 6px;
  background:
    linear-gradient(145deg, rgba(6, 31, 28, 0.97), rgba(3, 13, 14, 0.92)),
    rgba(3, 13, 14, 0.94);
  box-shadow:
    0 28px 70px rgba(0, 0, 0, 0.36),
    0 0 34px rgba(var(--accent-rgb), 0.16);
  padding: 14px 16px 15px;
  backdrop-filter: none;
  transform: rotateZ(-2deg);
  transform-origin: 12% 100%;
  transition:
    transform 650ms var(--ease),
    opacity 650ms var(--ease),
    border-color 650ms var(--ease);
  pointer-events: none;
}

.rotation-dialogue::before {
  content: "";
  position: absolute;
  left: 16px;
  bottom: -10px;
  width: 18px;
  height: 18px;
  border-right: 1px solid rgba(var(--accent-rgb), 0.58);
  border-bottom: 1px solid rgba(var(--accent-rgb), 0.58);
  background: rgba(4, 20, 19, 0.96);
  transform: rotate(45deg);
}

.rotation-dialogue p {
  margin: 0 0 8px;
  color: var(--accent);
  font-family: "Cascadia Mono", "JetBrains Mono", monospace;
  font-size: 11px;
  font-weight: 800;
}

.rotation-dialogue strong {
  display: block;
  color: var(--ink);
  font-size: clamp(16px, 1.25vw, 19px);
  line-height: 1.35;
}

.rotation-dialogue span {
  display: block;
  margin-top: 10px;
  color: rgba(246, 255, 247, 0.74);
  font-size: 13px;
  font-weight: 760;
  line-height: 1.48;
}

body.is-turning .rotation-dialogue,
body.is-dragging-character .rotation-dialogue {
  animation: dialoguePop 650ms var(--ease);
  border-color: rgba(246, 255, 247, 0.62);
}

body[data-scene="briefing"] .rotation-dialogue {
  left: clamp(540px, 43vw, 730px);
  top: 18%;
}

body[data-scene="voice"] .rotation-dialogue {
  left: clamp(540px, 43vw, 730px);
  top: 24%;
}

body[data-scene="dispatch"] .rotation-dialogue {
  left: clamp(540px, 43vw, 730px);
  top: 34%;
}

body[data-scene="patrol"] .rotation-dialogue {
  left: clamp(540px, 43vw, 730px);
  top: 44%;
}

body[data-scene="review"] .rotation-dialogue {
  left: clamp(540px, 43vw, 730px);
  top: 22%;
}

.angle-halo {
  position: absolute;
  z-index: 1;
  left: -8%;
  top: 16%;
  width: 116%;
  aspect-ratio: 1;
  border: 1px solid rgba(var(--accent-rgb), 0.34);
  border-radius: 50%;
  transform:
    rotateX(70deg)
    rotateZ(calc(var(--turn-deg) - 18deg));
  box-shadow:
    0 0 48px rgba(var(--accent-rgb), 0.18),
    inset 0 0 44px rgba(var(--accent-rgb), 0.1);
  transition: transform 420ms var(--ease);
}

.angle-halo::before,
.angle-halo::after {
  content: "";
  position: absolute;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 24px var(--accent);
}

.angle-halo::before {
  left: 68%;
  top: 4%;
}

.angle-halo::after {
  right: 10%;
  bottom: 22%;
  background: var(--accent-2);
}

.stage-shadow {
  position: absolute;
  z-index: 0;
  left: 18%;
  right: 18%;
  bottom: 1%;
  height: 34px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.4);
  filter: blur(16px);
}

.product-evidence {
  position: absolute;
  z-index: 2;
  right: clamp(18px, 3vw, 44px);
  bottom: 132px;
  width: min(520px, 35vw);
  pointer-events: none;
  transform:
    perspective(1400px)
    rotateY(-0.15deg)
    rotateX(0deg)
    translateY(calc(var(--scene-progress) * -1px));
  transform-origin: right center;
  transition: transform 560ms var(--ease);
}

.proof-copy {
  display: none;
  width: min(360px, 88%);
  margin-left: auto;
  border: 1px solid rgba(var(--accent-rgb), 0.32);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(4, 30, 28, 0.98), rgba(3, 13, 14, 0.94)),
    rgba(3, 13, 14, 0.96);
  box-shadow: 0 18px 52px rgba(0, 0, 0, 0.3);
  padding: 14px 16px 15px;
  backdrop-filter: none;
}

.proof-copy p {
  margin: 0 0 8px;
  color: var(--accent);
  font-family: "Cascadia Mono", "JetBrains Mono", monospace;
  font-size: 11px;
}

.proof-copy strong {
  display: block;
  color: var(--ink);
  font-size: 18px;
  line-height: 1.2;
}

.proof-copy small {
  display: block;
  margin-top: 8px;
  color: rgba(246, 255, 247, 0.68);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.65;
}

.device-composition {
  position: relative;
  height: 270px;
  margin-top: 0;
}

.desktop-device,
.phone-device {
  position: absolute;
  margin: 0;
  border: 1px solid rgba(246, 255, 247, 0.34);
  background: rgba(246, 255, 247, 0.96);
  box-shadow:
    0 20px 46px rgba(0, 0, 0, 0.34),
    0 0 22px rgba(var(--accent-rgb), 0.14);
  overflow: hidden;
  transition:
    opacity 620ms var(--ease),
    transform 620ms var(--ease),
    filter 620ms var(--ease),
    width 620ms var(--ease),
    right 620ms var(--ease),
    bottom 620ms var(--ease);
}

.desktop-device {
  right: 82px;
  bottom: 20px;
  width: min(430px, 28vw);
  border-radius: var(--radius);
  padding: 6px 6px 18px;
  transform: rotateZ(-0.4deg) translateY(0) scale(1);
  opacity: 0.96;
  filter: saturate(1.08) contrast(1.1) brightness(1.04);
}

.phone-device {
  bottom: 0;
  width: 166px;
  aspect-ratio: 9 / 18.5;
  border-radius: 20px;
  padding: 7px;
  transform: translateY(2px) rotateZ(0.8deg) scale(0.98);
  opacity: 0.94;
  filter: saturate(1.08) contrast(1.1) brightness(1.04);
}

.phone-report {
  right: 0;
}

.phone-task {
  right: 126px;
  bottom: -10px;
  transform: translateY(0) rotateZ(-1.1deg) scale(0.96);
}

.desktop-device figcaption,
.phone-device figcaption {
  position: absolute;
  z-index: 2;
  left: 12px;
  top: 10px;
  border: 1px solid rgba(var(--accent-rgb), 0.26);
  border-radius: 999px;
  background: rgba(3, 13, 14, 0.92);
  color: rgba(246, 255, 247, 0.88);
  padding: 4px 8px;
  font-size: 11px;
  font-weight: 850;
  backdrop-filter: none;
}

.desktop-device img,
.phone-device img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: calc(var(--radius) - 2px);
  object-fit: cover;
  object-position: top center;
  backface-visibility: hidden;
  image-rendering: auto;
  transform: none;
}

.desktop-device img {
  aspect-ratio: 16 / 9;
  height: auto;
}

body[data-scene="briefing"] .phone-report,
body[data-scene="voice"] .phone-report {
  z-index: 5;
  right: 0;
  bottom: -4px;
  width: 190px;
  opacity: 1;
  filter: saturate(1.16) contrast(1.12) brightness(1.08);
  transform: translateY(-14px) rotateZ(0.35deg) scale(1.06);
}

body[data-scene="briefing"] .phone-task,
body[data-scene="voice"] .phone-task {
  opacity: 0.42;
  filter: saturate(0.88) contrast(0.98) brightness(0.86);
  transform: translateY(4px) rotateZ(-0.6deg) scale(0.88);
}

body[data-scene="briefing"] .desktop-device,
body[data-scene="voice"] .desktop-device,
body[data-scene="dispatch"] .desktop-device,
body[data-scene="patrol"] .desktop-device {
  opacity: 0.9;
  filter: saturate(1.04) contrast(1.07) brightness(1);
}

body[data-scene="dispatch"] .phone-task,
body[data-scene="patrol"] .phone-task {
  z-index: 5;
  right: 8px;
  bottom: -4px;
  width: 190px;
  opacity: 1;
  filter: saturate(1.16) contrast(1.12) brightness(1.08);
  transform: translateY(-14px) rotateZ(-0.35deg) scale(1.06);
}

body[data-scene="dispatch"] .phone-report,
body[data-scene="patrol"] .phone-report {
  opacity: 0.44;
  filter: saturate(0.88) contrast(0.98) brightness(0.86);
  transform: translateY(4px) rotateZ(0.6deg) scale(0.88);
}

body[data-scene="review"] .desktop-device {
  z-index: 5;
  right: 26px;
  bottom: 22px;
  width: min(452px, 29vw);
  opacity: 1;
  filter: saturate(1.12) contrast(1.08) brightness(1.04);
  transform: rotateZ(-0.2deg) translateY(-6px) scale(1.02);
}

body[data-scene="review"] .phone-device {
  opacity: 0.4;
  filter: saturate(0.88) contrast(0.98) brightness(0.86);
  transform: translateY(4px) rotateZ(0deg) scale(0.82);
}

.story-copy,
.project-copy {
  position: relative;
  z-index: 5;
  display: flex;
  width: min(620px, 43vw);
  min-height: 100svh;
  flex-direction: column;
  justify-content: center;
  padding: 108px 0 120px clamp(34px, 7vw, 106px);
}

.story-copy::before,
.project-copy::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0 -2vw 0 -9vw;
  background:
    linear-gradient(90deg, rgba(4, 16, 17, 0.88), rgba(4, 16, 17, 0.54) 65%, transparent),
    radial-gradient(circle at 28% 46%, rgba(var(--accent-rgb), 0.14), transparent 38%);
  backdrop-filter: blur(2px);
}

.eyebrow,
.scene-card p:first-child,
.case-kicker,
.rotation-meter,
.project-flow > p,
.project-meter {
  font-family: "Cascadia Mono", "JetBrains Mono", monospace;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent);
  font-size: 13px;
}

.business-line {
  width: fit-content;
  max-width: min(560px, 100%);
  margin: 0 0 18px;
  border-left: 2px solid var(--accent);
  background:
    linear-gradient(90deg, rgba(var(--accent-rgb), 0.18), rgba(var(--accent-rgb), 0.02)),
    rgba(3, 13, 14, 0.46);
  color: rgba(246, 255, 247, 0.9);
  padding: 8px 12px;
  font-size: clamp(14px, 0.95vw, 16px);
  font-weight: 900;
  line-height: 1.35;
  box-shadow: 0 0 28px rgba(var(--accent-rgb), 0.11);
}

h1 {
  margin: 0;
  max-width: 650px;
  color: var(--ink);
  font-family:
    "Arial Black",
    "Microsoft YaHei UI",
    "Microsoft YaHei",
    "PingFang SC",
    sans-serif;
  font-size: clamp(54px, 5.8vw, 94px);
  line-height: 0.96;
  letter-spacing: 0;
  word-break: keep-all;
}

h1 span {
  display: block;
  white-space: nowrap;
}

.lead {
  min-height: 86px;
  margin: 24px 0 0;
  max-width: 590px;
  color: rgba(246, 255, 247, 0.86);
  font-size: clamp(18px, 1.18vw, 22px);
  font-weight: 760;
  line-height: 1.55;
  transition: opacity 260ms var(--ease);
}

.hero-route {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  width: min(560px, 100%);
  margin-top: 18px;
}

.hero-route span {
  position: relative;
  border: 1px solid rgba(var(--accent-rgb), 0.24);
  border-radius: var(--radius);
  background:
    linear-gradient(120deg, rgba(var(--accent-rgb), 0.12), rgba(246, 255, 247, 0.035)),
    rgba(3, 13, 14, 0.38);
  color: rgba(246, 255, 247, 0.86);
  padding: 8px 7px;
  text-align: center;
  font-size: 12px;
  font-weight: 900;
}

.hero-route span:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -9px;
  width: 9px;
  height: 1px;
  background: rgba(var(--accent-rgb), 0.48);
  transform: translateY(-50%);
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.tag-row span {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(246, 255, 247, 0.08);
  padding: 8px 11px;
  color: rgba(246, 255, 247, 0.84);
  font-size: 13px;
  font-weight: 760;
}

.tag-row span:first-child {
  border-color: rgba(var(--accent-rgb), 0.46);
  background: rgba(var(--accent-rgb), 0.15);
  color: var(--ink);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.project-link,
.case-button {
  min-height: 50px;
  border-radius: var(--radius);
  padding: 14px 18px;
  text-decoration: none;
  font-weight: 900;
  transition:
    transform 180ms var(--ease),
    background 180ms var(--ease),
    border-color 180ms var(--ease);
}

.project-link {
  border: 1px solid rgba(246, 255, 247, 0.92);
  background: var(--ink);
  color: #041011;
}

.case-button {
  border: 1px solid var(--line);
  background: rgba(246, 255, 247, 0.08);
  color: var(--ink);
}

.project-link:hover,
.case-button:hover {
  transform: translateY(-2px);
}

.scene-card {
  position: absolute;
  z-index: 7;
  right: clamp(30px, 6vw, 92px);
  top: 20%;
  width: min(380px, 29vw);
  border: 1px solid rgba(var(--accent-rgb), 0.46);
  border-radius: var(--radius);
  background:
    linear-gradient(145deg, rgba(8, 33, 29, 0.96), rgba(3, 13, 14, 0.9)),
    rgba(3, 13, 14, 0.94);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.34);
  padding: 22px;
  backdrop-filter: none;
  transform: translateY(calc(var(--scene-progress) * 26px));
  transition: transform 620ms var(--ease);
}

.scene-card p:first-child {
  margin: 0 0 12px;
  color: var(--accent);
  font-size: 12px;
}

.scene-card h2 {
  margin: 0;
  font-size: clamp(24px, 2.1vw, 34px);
  line-height: 1.12;
}

.scene-card p:last-child {
  margin: 14px 0 0;
  color: rgba(246, 255, 247, 0.75);
  line-height: 1.75;
}

.scene-signals {
  display: grid;
  gap: 8px;
  margin: 16px 0 0;
}

.scene-signals div {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  border: 1px solid rgba(var(--accent-rgb), 0.22);
  border-radius: var(--radius);
  background:
    linear-gradient(90deg, rgba(var(--accent-rgb), 0.12), rgba(246, 255, 247, 0.045)),
    rgba(3, 13, 14, 0.72);
  padding: 9px 10px;
}

.scene-signals dt {
  color: var(--accent);
  font-family: "Cascadia Mono", "JetBrains Mono", monospace;
  font-size: 11px;
  font-weight: 900;
}

.scene-signals dd {
  margin: 0;
  color: rgba(246, 255, 247, 0.86);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.4;
}

.rotation-meter {
  position: absolute;
  z-index: 8;
  left: 50%;
  bottom: 36px;
  width: 88px;
  height: 88px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(var(--accent-rgb), 0.36);
  border-radius: 50%;
  background:
    conic-gradient(from -90deg, rgba(var(--accent-rgb), 0.86) var(--scene-sweep), rgba(246, 255, 247, 0.12) 0),
    rgba(3, 13, 14, 0.56);
  box-shadow: 0 0 48px rgba(var(--accent-rgb), 0.16);
  transform: translateX(-50%);
  color: var(--ink);
  font-weight: 900;
}

.rotation-meter::before {
  content: "";
  position: absolute;
  inset: 7px;
  border-radius: 50%;
  background: rgba(3, 13, 14, 0.9);
}

.rotation-meter span {
  position: relative;
}

.rotation-steps {
  position: absolute;
  z-index: 8;
  right: clamp(24px, 4vw, 58px);
  bottom: clamp(22px, 3.2vw, 34px);
  width: min(500px, 35vw);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
  pointer-events: auto;
}

.rotation-steps [data-scene-button] {
  appearance: none;
  width: 100%;
  min-height: 58px;
  display: grid;
  gap: 4px;
  border: 1px solid rgba(246, 255, 247, 0.18);
  border-radius: var(--radius);
  background: rgba(3, 13, 14, 0.78);
  color: rgba(246, 255, 247, 0.76);
  padding: 10px 8px;
  text-align: left;
  font-weight: 850;
  backdrop-filter: none;
  cursor: pointer;
  user-select: none;
  transition:
    transform 180ms var(--ease),
    background 180ms var(--ease),
    border-color 180ms var(--ease),
    color 180ms var(--ease);
}

.rotation-steps [data-scene-button]:focus-visible {
  outline: 2px solid rgba(var(--accent-rgb), 0.86);
  outline-offset: 3px;
}

.rotation-steps [data-scene-button] span {
  color: var(--accent);
  font-family: "Cascadia Mono", "JetBrains Mono", monospace;
  font-size: 10px;
}

.rotation-steps [data-scene-button].is-active {
  transform: translateY(-6px);
  border-color: rgba(246, 255, 247, 0.46);
  background: rgba(246, 255, 247, 0.16);
  color: var(--ink);
}

.portfolio-project .project-backdrop {
  z-index: 0;
  filter: saturate(0.96) contrast(1.05) brightness(0.78);
  transform: scale(1.03);
}

.study-slide .project-backdrop {
  object-position: center center;
}

.law-slide .project-backdrop {
  object-position: center center;
}

.portfolio-project .project-grade {
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(4, 16, 17, 0.98), rgba(4, 16, 17, 0.78) 25%, rgba(4, 16, 17, 0.24) 58%, rgba(4, 16, 17, 0.58) 100%),
    linear-gradient(180deg, rgba(4, 16, 17, 0.7), transparent 42%, rgba(4, 16, 17, 0.88) 100%);
}

.portfolio-project .project-copy {
  width: min(660px, 45vw);
}

.project-atmosphere {
  position: absolute;
  z-index: 2;
  pointer-events: none;
}

.learning-constellation {
  right: min(530px, 39vw);
  top: 17%;
  width: min(420px, 29vw);
  aspect-ratio: 1;
  border: 1px solid rgba(var(--accent-rgb), 0.22);
  border-radius: 50%;
  opacity: 0.86;
  background:
    radial-gradient(circle at 50% 50%, rgba(var(--accent-rgb), 0.18), transparent 34%),
    conic-gradient(from 220deg, rgba(var(--accent-rgb), 0.68), rgba(var(--accent-2-rgb), 0.28), rgba(var(--accent-rgb), 0.1), rgba(var(--accent-rgb), 0.68));
  box-shadow:
    inset 0 0 46px rgba(var(--accent-rgb), 0.08),
    0 0 70px rgba(var(--accent-rgb), 0.1);
  transform: perspective(1000px) rotateX(62deg) rotateZ(-18deg);
}

.learning-constellation::before,
.learning-constellation::after {
  content: "";
  position: absolute;
  inset: 18%;
  border: 1px solid rgba(246, 255, 247, 0.12);
  border-radius: 50%;
}

.learning-constellation::after {
  inset: 34%;
  background: radial-gradient(circle, rgba(var(--accent-rgb), 0.44) 0 4px, transparent 5px);
  box-shadow: 0 0 28px rgba(var(--accent-rgb), 0.32);
}

.learning-constellation span {
  position: absolute;
  min-width: 70px;
  border: 1px solid rgba(var(--accent-rgb), 0.28);
  border-radius: 999px;
  background: rgba(3, 13, 14, 0.72);
  color: rgba(246, 255, 247, 0.78);
  padding: 6px 10px;
  text-align: center;
  font-size: 12px;
  font-weight: 900;
  transform: rotateZ(18deg) rotateX(-62deg);
  box-shadow: 0 0 18px rgba(var(--accent-rgb), 0.14);
}

.learning-constellation [data-node="goal"] {
  left: 9%;
  top: 41%;
}

.learning-constellation [data-node="breakdown"] {
  left: 30%;
  top: 15%;
}

.learning-constellation [data-node="practice"] {
  right: 12%;
  top: 28%;
}

.learning-constellation [data-node="feedback"] {
  right: 17%;
  bottom: 21%;
}

.learning-constellation [data-node="archive"] {
  left: 24%;
  bottom: 12%;
  border-color: rgba(var(--accent-2-rgb), 0.38);
}

.legal-dossier {
  right: min(525px, 38vw);
  top: 15%;
  width: min(430px, 30vw);
  height: min(520px, 58vh);
  opacity: 0.86;
  transform: perspective(1100px) rotateY(-18deg) rotateX(5deg);
  transform-origin: right center;
}

.legal-dossier::before {
  content: "";
  position: absolute;
  inset: 6% 8% 7%;
  border: 1px solid rgba(var(--accent-rgb), 0.18);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(var(--accent-rgb), 0.12), rgba(3, 13, 14, 0.08)),
    repeating-linear-gradient(0deg, rgba(246, 255, 247, 0.07) 0 1px, transparent 1px 34px);
  box-shadow:
    inset 0 0 44px rgba(var(--accent-rgb), 0.06),
    0 24px 70px rgba(0, 0, 0, 0.22);
}

.legal-dossier::after {
  content: "";
  position: absolute;
  left: 13%;
  top: 16%;
  bottom: 16%;
  width: 1px;
  background: linear-gradient(180deg, rgba(var(--accent-rgb), 0.18), rgba(var(--accent-rgb), 0.72), rgba(var(--accent-2-rgb), 0.3));
  box-shadow: 0 0 24px rgba(var(--accent-rgb), 0.22);
}

.legal-dossier span {
  position: absolute;
  left: 19%;
  min-width: 120px;
  border: 1px solid rgba(var(--accent-rgb), 0.22);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(3, 13, 14, 0.82), rgba(3, 13, 14, 0.58)),
    rgba(246, 255, 247, 0.04);
  color: rgba(246, 255, 247, 0.82);
  padding: 9px 12px;
  font-size: 12px;
  font-weight: 900;
  box-shadow:
    0 18px 36px rgba(0, 0, 0, 0.22),
    0 0 22px rgba(var(--accent-rgb), 0.08);
}

.legal-dossier [data-doc="contract"] {
  top: 13%;
}

.legal-dossier [data-doc="evidence"] {
  top: 29%;
  left: 28%;
}

.legal-dossier [data-doc="rag"] {
  top: 45%;
  left: 17%;
}

.legal-dossier [data-doc="review"] {
  top: 61%;
  left: 33%;
  border-color: rgba(var(--accent-2-rgb), 0.52);
  color: var(--ink);
}

.legal-dossier [data-doc="report"] {
  top: 77%;
  left: 23%;
}

.project-flow {
  position: absolute;
  z-index: 6;
  right: clamp(30px, 6vw, 92px);
  bottom: clamp(82px, 12vh, 132px);
  width: min(420px, 31vw);
  --flow-index: 0;
  --flow-progress: 0;
  border: 1px solid rgba(246, 255, 247, 0.16);
  border-radius: var(--radius);
  background: rgba(3, 13, 14, 0.56);
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.34);
  padding: 22px;
  backdrop-filter: blur(20px);
  overflow: hidden;
}

.project-flow::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at calc(20% + var(--flow-progress) * 60%) 18%, rgba(var(--accent-rgb), 0.2), transparent 27%),
    linear-gradient(120deg, transparent, rgba(var(--accent-rgb), 0.11), transparent);
  opacity: 0.9;
  transition: background 520ms var(--ease);
}

.project-flow > p {
  position: relative;
  margin: 0 0 16px;
  color: var(--accent);
  font-size: 12px;
}

.flow-spotlight {
  position: relative;
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
  border: 1px solid rgba(var(--accent-rgb), 0.18);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(var(--accent-rgb), 0.11), rgba(246, 255, 247, 0.04)),
    rgba(3, 13, 14, 0.42);
  padding: 16px;
}

.flow-spotlight span {
  color: var(--accent-2);
  font-family: "Cascadia Mono", "JetBrains Mono", monospace;
  font-size: 11px;
}

.flow-spotlight strong {
  color: var(--ink);
  font-size: 20px;
  line-height: 1.18;
}

.flow-spotlight small {
  color: rgba(246, 255, 247, 0.72);
  font-size: 13px;
  line-height: 1.6;
}

.flow-proof {
  position: relative;
  height: 124px;
  margin: 0 0 18px;
}

.flow-proof figure {
  position: absolute;
  width: 58%;
  height: 104px;
  margin: 0;
  border: 1px solid rgba(246, 255, 247, 0.16);
  border-radius: var(--radius);
  background: rgba(3, 13, 14, 0.66);
  box-shadow:
    0 18px 46px rgba(0, 0, 0, 0.32),
    0 0 26px rgba(var(--accent-rgb), 0.1);
  overflow: hidden;
  transform-origin: center bottom;
}

.flow-proof figure:nth-child(1) {
  left: 0;
  bottom: 2px;
  z-index: 1;
  transform: rotateZ(-4deg);
}

.flow-proof figure:nth-child(2) {
  left: 21%;
  top: 0;
  z-index: 3;
  transform: rotateZ(1deg) translateY(-2px);
}

.flow-proof figure:nth-child(3) {
  right: 0;
  bottom: 7px;
  z-index: 2;
  transform: rotateZ(4deg);
}

.flow-proof img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  filter: saturate(0.92) contrast(1.02) brightness(0.88);
}

.flow-proof figcaption {
  position: absolute;
  left: 9px;
  top: 8px;
  z-index: 2;
  border: 1px solid rgba(var(--accent-rgb), 0.24);
  border-radius: 999px;
  background: rgba(3, 13, 14, 0.76);
  color: rgba(246, 255, 247, 0.88);
  padding: 3px 7px;
  font-size: 10px;
  font-weight: 850;
  backdrop-filter: blur(8px);
}

.project-flow ol {
  position: relative;
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0 0 0 10px;
  list-style: none;
}

.project-flow ol::before {
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  bottom: 2px;
  width: 1px;
  background:
    linear-gradient(
      180deg,
      rgba(var(--accent-rgb), 0.9) calc(var(--flow-progress) * 100%),
      rgba(246, 255, 247, 0.16) 0
    );
  box-shadow: 0 0 18px rgba(var(--accent-rgb), 0.28);
}

.project-flow li {
  display: block;
}

.project-flow button {
  width: 100%;
  min-height: 44px;
  display: grid;
  grid-template-columns: 42px 1fr;
  align-items: center;
  border: 1px solid rgba(246, 255, 247, 0.12);
  border-radius: var(--radius);
  background: rgba(246, 255, 247, 0.06);
  padding: 9px 12px;
  color: rgba(246, 255, 247, 0.84);
  text-align: left;
  font-weight: 780;
  transition:
    transform 180ms var(--ease),
    background 180ms var(--ease),
    border-color 180ms var(--ease),
    color 180ms var(--ease);
}

.project-flow button:hover,
.project-flow button.is-active {
  transform: translateX(-4px);
  border-color: rgba(var(--accent-rgb), 0.42);
  background: rgba(var(--accent-rgb), 0.1);
  color: var(--ink);
  box-shadow: 0 0 30px rgba(var(--accent-rgb), 0.12);
}

.project-flow button span {
  color: var(--accent-2);
  font-family: "Cascadia Mono", "JetBrains Mono", monospace;
  font-size: 12px;
}

.project-meter {
  position: fixed;
  z-index: 82;
  left: clamp(24px, 5vw, 72px);
  bottom: clamp(22px, 4vw, 42px);
  display: grid;
  grid-template-columns: auto 96px auto;
  align-items: center;
  gap: 12px;
  color: rgba(246, 255, 247, 0.72);
  font-size: 12px;
  pointer-events: none;
}

.project-meter i {
  display: block;
  height: 1px;
  background:
    linear-gradient(90deg, var(--accent) calc(var(--project-progress) * 100%), rgba(246, 255, 247, 0.18) 0);
}

.project-meter small {
  grid-column: 1 / -1;
  color: rgba(246, 255, 247, 0.52);
  font-family:
    "Microsoft YaHei UI",
    "Microsoft YaHei",
    "PingFang SC",
    system-ui,
    sans-serif;
  font-size: 11px;
  font-weight: 820;
  text-align: center;
}

.case-panel {
  position: fixed;
  z-index: 100;
  right: clamp(22px, 5vw, 72px);
  bottom: clamp(22px, 5vw, 72px);
  width: min(680px, calc(100vw - 44px));
  max-height: min(760px, calc(100svh - 44px));
  overflow-y: auto;
  border: 1px solid rgba(246, 255, 247, 0.18);
  border-radius: var(--radius);
  background: rgba(3, 13, 14, 0.92);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.36);
  padding: 26px;
  backdrop-filter: blur(22px);
}

.case-panel[hidden] {
  display: none;
}

.case-panel-close {
  position: absolute;
  right: 14px;
  top: 14px;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(246, 255, 247, 0.08);
  color: var(--ink);
  font-size: 20px;
}

.case-kicker {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 12px;
}

.case-panel h2 {
  margin: 0;
  max-width: 560px;
  font-size: 30px;
  line-height: 1.18;
}

.case-panel p:not(.case-kicker) {
  margin: 16px 0 0;
  color: rgba(246, 255, 247, 0.78);
  line-height: 1.85;
}

.case-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 18px 0 0;
}

.case-facts div {
  min-height: 112px;
  border: 1px solid rgba(var(--accent-rgb), 0.22);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(var(--accent-rgb), 0.1), rgba(246, 255, 247, 0.035)),
    rgba(246, 255, 247, 0.04);
  padding: 13px 14px;
}

.case-facts dt {
  margin: 0 0 8px;
  color: var(--accent);
  font-family: "Cascadia Mono", "JetBrains Mono", monospace;
  font-size: 12px;
  font-weight: 900;
}

.case-facts dd {
  margin: 0;
  color: rgba(246, 255, 247, 0.76);
  font-size: 13px;
  font-weight: 650;
  line-height: 1.65;
}

.case-link {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  margin-top: 18px;
  border: 1px solid rgba(246, 255, 247, 0.88);
  border-radius: var(--radius);
  background: var(--ink);
  color: #041011;
  padding: 11px 15px;
  text-decoration: none;
  font-weight: 900;
  transition:
    transform 180ms var(--ease),
    background 180ms var(--ease);
}

.case-link:hover {
  transform: translateY(-2px);
}

.portfolio-icp {
  position: fixed;
  z-index: 84;
  right: clamp(18px, 4vw, 54px);
  bottom: 14px;
  color: rgba(246, 255, 247, 0.52);
  font-size: 11px;
  font-weight: 700;
  text-decoration: none;
}

.portfolio-icp:hover {
  color: rgba(246, 255, 247, 0.82);
}

.project-link:focus-visible,
.case-button:focus-visible,
.case-link:focus-visible,
.brand:focus-visible,
.project-tab:focus-visible,
.case-panel-close:focus-visible,
.character-stage:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent) 75%, white);
  outline-offset: 3px;
}

@keyframes dispatchFloat {
  0%, 100% {
    transform: translateY(0) translateX(0);
  }

  50% {
    transform: translateY(-12px) translateX(8px);
  }
}

@keyframes characterBriefing {
  0%, 100% {
    transform: translate3d(0, 0, 0) rotateZ(0deg);
  }

  50% {
    transform: translate3d(0, -4px, 8px) rotateZ(-0.25deg);
  }
}

@keyframes characterSpeaking {
  0%, 100% {
    transform: translate3d(0, 0, 0) rotateZ(0deg);
  }

  30% {
    transform: translate3d(4px, -4px, 10px) rotateZ(0.45deg);
  }

  62% {
    transform: translate3d(-2px, -2px, 5px) rotateZ(-0.25deg);
  }
}

@keyframes characterDispatch {
  0%, 100% {
    transform: translate3d(0, 0, 0) rotateZ(0deg);
  }

  42% {
    transform: translate3d(7px, -4px, 12px) rotateZ(0.65deg);
  }

  70% {
    transform: translate3d(-2px, -1px, 4px) rotateZ(-0.22deg);
  }
}

@keyframes characterPatrol {
  0%, 100% {
    transform: translate3d(0, 0, 0) rotateZ(0deg);
  }

  25% {
    transform: translate3d(-4px, -4px, 10px) rotateZ(-0.45deg);
  }

  55% {
    transform: translate3d(5px, -5px, 12px) rotateZ(0.35deg);
  }

  78% {
    transform: translate3d(2px, -1px, 5px) rotateZ(0.15deg);
  }
}

@keyframes characterReview {
  0%, 100% {
    transform: translate3d(0, 0, 0) rotateZ(0deg) scale(1);
  }

  50% {
    transform: translate3d(0, -5px, 12px) rotateZ(0.25deg) scale(1.006);
  }
}

@keyframes autoplaySightline {
  0%, 100% {
    transform: translateY(-50%) scaleX(0.86);
    opacity: 0.62;
  }

  50% {
    transform: translateY(-50%) scaleX(1.18);
    opacity: 1;
  }
}

@keyframes turntableSnap {
  0% {
    transform: translate3d(calc(var(--turn-direction) * 8px), 0, -8px) rotateZ(calc(var(--turn-direction) * -0.7deg)) scale(0.996);
    filter: blur(0);
  }

  58% {
    transform: translate3d(calc(var(--turn-direction) * -4px), -4px, 10px) rotateZ(calc(var(--turn-direction) * 0.45deg)) scale(1.006);
    filter: blur(0);
  }

  100% {
    transform: translate3d(0, 0, 0) rotateZ(0deg) scale(1);
    filter: blur(0);
  }
}

@keyframes dialoguePop {
  0% {
    opacity: 0.3;
    transform:
      translate3d(calc(var(--turn-direction) * 26px), 18px, 0)
      rotateZ(calc(var(--turn-direction) * 2deg))
      scale(0.92);
  }

  62% {
    opacity: 1;
    transform:
      translate3d(calc(var(--turn-direction) * -8px), -6px, 0)
      rotateZ(calc(var(--turn-direction) * -1deg))
      scale(1.03);
  }

  100% {
    opacity: 1;
    transform:
      translate3d(0, 0, 0)
      rotateZ(-2deg)
      scale(1);
  }
}

@keyframes briefingCard {
  0%, 100% {
    transform: translate3d(0, 0, 0) scale(0.94);
  }

  50% {
    transform: translate3d(7px, -8px, 0) scale(1);
  }
}

@keyframes voiceDots {
  0%, 100% {
    transform: translateY(0) scale(0.75);
    opacity: 0.35;
  }

  45% {
    transform: translateY(-12px) scale(1.08);
    opacity: 0.92;
  }
}

@keyframes dispatchTicket {
  0% {
    transform: translate3d(-12px, 10px, 0) scaleX(0.72);
    opacity: 0;
  }

  38% {
    opacity: 0.92;
  }

  100% {
    transform: translate3d(72px, -32px, 0) scaleX(1);
    opacity: 0;
  }
}

@keyframes patrolScan {
  0%, 100% {
    transform: translateY(-62px) scaleX(0.62);
    opacity: 0.18;
  }

  50% {
    transform: translateY(56px) scaleX(1);
    opacity: 0.95;
  }
}

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

@keyframes flowLine {
  0%, 100% {
    opacity: 0.2;
    transform: rotate(17deg) scaleX(0.72);
  }

  50% {
    opacity: 1;
    transform: rotate(17deg) scaleX(1);
  }
}

@keyframes scanSweep {
  0%, 100% {
    opacity: 0.35;
    transform: translateY(-32px) scaleX(0.76);
  }

  50% {
    opacity: 1;
    transform: translateY(32px) scaleX(1);
  }
}

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

@media (max-width: 1120px) {
  .character-stage {
    width: min(470px, 39vw);
    left: 59%;
  }

  .rotation-dialogue {
    width: min(285px, 74%);
    left: 52%;
  }

  .scene-card {
    width: min(350px, 32vw);
    right: 28px;
  }

  .rotation-steps {
    width: min(520px, 44vw);
  }

  .product-evidence {
    right: 28px;
    width: min(470px, 39vw);
  }

  .desktop-device {
    right: 74px;
    width: min(348px, 29vw);
  }

  .phone-device {
    width: 118px;
  }

  .phone-task {
    right: 104px;
  }

  .project-flow {
    width: min(380px, 34vw);
    right: 28px;
  }
}

@media (max-width: 860px) {
  body {
    overflow-y: auto;
  }

  .portfolio-shell {
    overflow: hidden;
  }

  .project-track {
    min-height: auto;
  }

  .project-slide {
    min-height: 100svh;
    overflow-x: hidden;
    overflow-y: visible;
    padding-bottom: 42px;
  }

  .project-slide::after {
    display: none;
  }

  .environment {
    position: relative;
    height: 62svh;
    min-height: 510px;
  }

  .environment-grade {
    background:
      linear-gradient(180deg, rgba(4, 16, 17, 0.62), transparent 34%, rgba(4, 16, 17, 0.92) 100%),
      linear-gradient(90deg, rgba(4, 16, 17, 0.46), rgba(4, 16, 17, 0.08) 50%, rgba(4, 16, 17, 0.42));
  }

  .character-stage {
    top: 326px;
    left: 50%;
    width: min(356px, 76vw);
    transform:
      translate(-50%, -50%)
      perspective(1100px)
      rotateY(var(--stage-tilt-mobile));
  }

  .turntable-affordance {
    left: 50%;
    top: 88px;
    min-width: 184px;
    padding: 9px 14px 9px 42px;
    transform: translateX(-50%) rotateZ(-2deg);
  }

  .character-stage:hover + .turntable-affordance,
  .character-stage:focus-visible + .turntable-affordance,
  body.is-turntable-wheel-hint .turntable-affordance {
    transform: translateX(-50%) rotateZ(0deg) translateY(-4px);
  }

  body.is-dragging-character .turntable-affordance,
  body.is-turning .turntable-affordance {
    transform: translateX(-50%) rotateZ(0deg) translateY(-14px) scale(0.96);
  }

  .rotation-dialogue,
  body[data-scene="briefing"] .rotation-dialogue,
  body[data-scene="voice"] .rotation-dialogue,
  body[data-scene="dispatch"] .rotation-dialogue,
  body[data-scene="patrol"] .rotation-dialogue,
  body[data-scene="review"] .rotation-dialogue {
    left: 52%;
    top: 20%;
    width: min(278px, 72vw);
    padding: 12px 13px;
  }

  .rotation-dialogue strong {
    font-size: 15px;
  }

  .rotation-dialogue span {
    font-size: 11px;
  }

  .floor-map {
    left: 50%;
    bottom: 46px;
    width: min(460px, 90vw);
    height: 68px;
    opacity: 0.52;
    transform:
      translateX(-50%)
      skewX(-10deg)
      rotateZ(-3deg);
  }

  .floor-map span {
    min-width: 70px;
    padding: 6px 8px;
    font-size: 10px;
  }

  .product-evidence {
    position: relative;
    z-index: 6;
    right: auto;
    bottom: auto;
    width: auto;
    margin: 14px 18px 0;
    transform: none;
    pointer-events: auto;
  }

  .proof-copy {
    display: block;
    width: auto;
    margin-left: 0;
  }

  .device-composition {
    height: 236px;
  }

  .desktop-device {
    left: 0;
    right: auto;
    bottom: 26px;
    width: 78%;
  }

  .phone-device {
    width: 126px;
  }

  .phone-report {
    right: 0;
    bottom: 8px;
  }

  .phone-task {
    right: 112px;
    bottom: -8px;
  }

  body[data-scene="briefing"] .phone-report,
  body[data-scene="voice"] .phone-report {
    right: 0;
    bottom: 8px;
    width: 126px;
    opacity: 1;
    transform: translateY(-8px) rotateZ(1deg) scale(1.02);
  }

  body[data-scene="briefing"] .phone-task,
  body[data-scene="voice"] .phone-task {
    right: 112px;
    bottom: -8px;
    width: 126px;
    opacity: 0.48;
    transform: translateY(0) rotateZ(-1deg) scale(0.92);
  }

  body[data-scene="dispatch"] .phone-task,
  body[data-scene="patrol"] .phone-task {
    right: 112px;
    bottom: -8px;
    width: 126px;
    opacity: 1;
    transform: translateY(-8px) rotateZ(-1deg) scale(1.02);
  }

  body[data-scene="dispatch"] .phone-report,
  body[data-scene="patrol"] .phone-report {
    right: 0;
    bottom: 8px;
    width: 126px;
    opacity: 0.48;
    transform: translateY(0) rotateZ(1deg) scale(0.92);
  }

  body[data-scene="review"] .desktop-device,
  body[data-scene="briefing"] .desktop-device,
  body[data-scene="voice"] .desktop-device,
  body[data-scene="dispatch"] .desktop-device,
  body[data-scene="patrol"] .desktop-device {
    left: 0;
    right: auto;
    bottom: 26px;
    width: 78%;
    transform: rotateZ(-0.6deg) translateY(0) scale(1);
  }

  body[data-scene="review"] .phone-device {
    width: 126px;
    opacity: 0.36;
    transform: translateY(0) rotateZ(0deg) scale(0.9);
  }

  .story-copy,
  .project-copy {
    width: auto;
    min-height: auto;
    padding: 26px 18px 0;
  }

  .portfolio-project .project-copy {
    width: auto;
  }

  .project-copy .lead {
    max-width: none;
  }

  .story-copy::before,
  .project-copy::before {
    display: none;
  }

  h1 {
    font-size: clamp(42px, 12vw, 58px);
  }

  .business-line {
    max-width: none;
    margin-bottom: 14px;
    padding: 8px 10px;
    font-size: 13px;
  }

  .lead {
    min-height: 0;
    font-size: 18px;
  }

  .hero-route {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px;
    margin-top: 16px;
  }

  .hero-route span {
    padding: 8px 6px;
    font-size: 11px;
  }

  .hero-route span::after {
    display: none;
  }

  .scene-card {
    position: relative;
    inset: auto;
    z-index: 6;
    width: auto;
    margin: 20px 18px 0;
  }

  .scene-signals div {
    grid-template-columns: 76px minmax(0, 1fr);
  }

  .rotation-meter {
    top: 452px;
    bottom: auto;
    width: 72px;
    height: 72px;
  }

  .rotation-steps {
    position: relative;
    right: auto;
    bottom: auto;
    width: auto;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 5px;
    margin: 14px 10px 0;
  }

  .rotation-steps [data-scene-button] {
    min-height: 52px;
    padding: 8px 4px;
    text-align: center;
    font-size: 11px;
  }

  .portfolio-project {
    display: flex;
    min-height: 100svh;
    flex-direction: column;
    justify-content: flex-start;
    padding-top: 44svh;
  }

  .portfolio-project .project-backdrop {
    height: 54svh;
    min-height: 520px;
    object-position: 62% center;
    filter: saturate(0.96) contrast(1.05) brightness(0.72);
  }

  .portfolio-project .project-grade {
    background:
      linear-gradient(180deg, rgba(4, 16, 17, 0.2), rgba(4, 16, 17, 0.55) 42%, rgba(4, 16, 17, 0.98) 76%),
      linear-gradient(90deg, rgba(4, 16, 17, 0.32), transparent, rgba(4, 16, 17, 0.32));
  }

  .project-atmosphere {
    z-index: 2;
    opacity: 0.5;
  }

  .learning-constellation {
    right: 18px;
    top: 86px;
    width: min(260px, 68vw);
    transform: perspective(900px) rotateX(58deg) rotateZ(-18deg);
  }

  .learning-constellation span {
    min-width: 54px;
    padding: 5px 7px;
    font-size: 10px;
  }

  .legal-dossier {
    right: 18px;
    top: 86px;
    width: min(260px, 66vw);
    height: 310px;
    transform: perspective(900px) rotateY(-12deg) rotateX(4deg);
  }

  .legal-dossier span {
    min-width: 88px;
    padding: 7px 9px;
    font-size: 10px;
  }

  .project-flow {
    position: relative;
    inset: auto;
    width: auto;
    margin: 20px 18px 0;
  }

  .flow-proof {
    height: 142px;
  }

  .flow-proof figure {
    height: 120px;
  }

  .project-meter {
    display: none;
  }

  .portfolio-icp {
    position: static;
    display: block;
    width: max-content;
    margin: 28px 18px 18px auto;
    opacity: 0.4;
    transform: none;
  }
}

@media (max-width: 540px) {
  .site-header {
    align-items: flex-start;
    padding: 16px 16px 0;
  }

  .brand {
    font-size: 14px;
  }

  .brand-text {
    gap: 0;
  }

  .brand-text strong {
    font-size: 14px;
  }

  .brand-text small {
    display: none;
  }

  .brand-mark {
    width: 27px;
    height: 27px;
  }

  .project-tabs {
    gap: 4px;
    padding: 4px;
  }

  .project-tab {
    min-width: 42px;
    padding: 7px 9px;
    font-size: 12px;
  }

  .environment {
    height: 56svh;
    min-height: 470px;
  }

  .mall-backdrop {
    object-position: center center;
  }

  .character-stage {
    top: 296px;
    width: min(304px, 76vw);
  }

  .rotation-dialogue,
  body[data-scene="briefing"] .rotation-dialogue,
  body[data-scene="voice"] .rotation-dialogue,
  body[data-scene="dispatch"] .rotation-dialogue,
  body[data-scene="patrol"] .rotation-dialogue,
  body[data-scene="review"] .rotation-dialogue {
    left: 50%;
    top: 24%;
    width: min(300px, calc(100vw - 40px));
    transform: translateX(-50%) rotateZ(-2deg);
  }

  .office-screen {
    left: 38%;
    top: 24%;
    width: 210px;
  }

  .product-evidence {
    margin: 12px 18px 0;
  }

  .proof-copy {
    display: none;
  }

  .proof-copy strong {
    font-size: 16px;
  }

  .proof-copy small {
    font-size: 11px;
  }

  .device-composition {
    height: 206px;
  }

  .desktop-device {
    width: 68%;
    bottom: 18px;
    padding: 5px 5px 14px;
  }

  .phone-device {
    width: 104px;
    border-radius: 16px;
    padding: 5px;
  }

  .phone-task {
    right: 88px;
  }

  body[data-scene="briefing"] .phone-report,
  body[data-scene="voice"] .phone-report {
    width: 104px;
    right: 0;
    bottom: 8px;
    transform: translateY(-4px) rotateZ(1deg) scale(1.02);
  }

  body[data-scene="briefing"] .phone-task,
  body[data-scene="voice"] .phone-task {
    width: 104px;
    right: 88px;
    bottom: -8px;
    transform: translateY(0) rotateZ(-1deg) scale(0.92);
  }

  body[data-scene="dispatch"] .phone-task,
  body[data-scene="patrol"] .phone-task {
    width: 104px;
    right: 88px;
    bottom: -8px;
    transform: translateY(-4px) rotateZ(-1deg) scale(1.02);
  }

  body[data-scene="dispatch"] .phone-report,
  body[data-scene="patrol"] .phone-report {
    width: 104px;
    right: 0;
    bottom: 8px;
    transform: translateY(0) rotateZ(1deg) scale(0.92);
  }

  body[data-scene="review"] .desktop-device,
  body[data-scene="briefing"] .desktop-device,
  body[data-scene="voice"] .desktop-device,
  body[data-scene="dispatch"] .desktop-device,
  body[data-scene="patrol"] .desktop-device {
    width: 68%;
    bottom: 18px;
  }

  body[data-scene="review"] .phone-device {
    width: 104px;
  }

  .desktop-device figcaption,
  .phone-device figcaption {
    left: 8px;
    top: 8px;
    padding: 3px 6px;
    font-size: 10px;
  }

  .scene-card,
  .project-flow {
    padding: 18px;
  }

  .scene-card h2 {
    font-size: 24px;
  }

  .scene-signals {
    gap: 7px;
  }

  .scene-signals div {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .scene-signals dd {
    font-size: 12px;
  }

  .tag-row {
    gap: 8px;
  }

  .tag-row span {
    font-size: 12px;
  }

  .project-link,
  .case-button {
    flex: 1 1 150px;
    min-height: 46px;
    padding: 12px 14px;
    text-align: center;
    font-size: 14px;
  }

  .project-flow button {
    grid-template-columns: 36px 1fr;
    font-size: 13px;
  }

  .flow-proof {
    height: 118px;
  }

  .flow-proof figure {
    height: 98px;
  }

  .flow-proof figcaption {
    left: 7px;
    top: 7px;
    font-size: 9px;
  }

  .case-panel {
    inset: auto 14px 14px;
    width: auto;
    max-height: calc(100svh - 28px);
    overflow-y: auto;
  }

  .case-facts {
    grid-template-columns: 1fr;
  }

  .case-facts div {
    min-height: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.001ms !important;
  }
}
