:root {
  --bg: #0a0a0b;
  --bg-2: #111113;
  --bg-3: #18181b;
  --ink: #f4f4f5;
  --ink-muted: rgba(244, 244, 245, 0.62);
  --mist: #a1a1aa;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.14);
  --accent: #5eead4;
  --accent-dim: rgba(94, 234, 212, 0.14);
  --accent-glow: rgba(94, 234, 212, 0.28);
  --ok: #5eead4;
  --danger: #fb7185;
  --display: "Fraunces", Georgia, serif;
  --body: "Manrope", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --radius: 16px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --header-h: 88px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

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

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  font-weight: 400;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection {
  background: var(--accent);
  color: #0a0a0b;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 9998;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  mix-blend-mode: overlay;
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

.wrap {
  width: min(1120px, calc(100% - 48px));
  margin-inline: auto;
}

.eyebrow {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.eyebrow::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-dim);
}

h1,
h2,
h3 {
  font-family: var(--display);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.08;
}

.progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  z-index: 200;
  background: linear-gradient(90deg, var(--accent), #fff);
  transform-origin: left;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.3s var(--ease), background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.btn:active {
  transform: scale(0.97);
}

.btn-primary {
  background: var(--ink);
  color: var(--bg);
}

.btn-primary:hover {
  background: var(--accent);
  box-shadow: 0 12px 40px var(--accent-glow);
}

.btn-ghost {
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.02);
}

.btn-ghost:hover {
  border-color: rgba(94, 234, 212, 0.45);
  background: var(--accent-dim);
}

.btn-wa {
  background: #25d366;
  color: #06240f;
}

.btn-wa:hover {
  filter: brightness(1.06);
  transform: translateY(-2px);
}

.btn-full {
  width: 100%;
}

body.has-dock {
  cursor: none;
}

body.has-dock a,
body.has-dock button,
body.has-dock .btn,
body.has-dock .filter-btn,
body.has-dock .orbit-node,
body.has-dock .stack-btn,
body.has-dock input,
body.has-dock textarea,
body.has-dock select {
  cursor: none;
}

.cursor {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 10000;
  pointer-events: none;
  mix-blend-mode: difference;
}

.cursor-dot {
  position: absolute;
  width: 6px;
  height: 6px;
  margin: -3px 0 0 -3px;
  border-radius: 50%;
  background: #fff;
}

.cursor-ring {
  position: absolute;
  width: 40px;
  height: 40px;
  margin: -20px 0 0 -20px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.7);
  transition: width 0.25s var(--ease), height 0.25s var(--ease), margin 0.25s var(--ease), border-color 0.25s;
}

body.is-hovering .cursor-ring {
  width: 64px;
  height: 64px;
  margin: -32px 0 0 -32px;
  border-color: var(--accent);
}

@media (max-width: 900px), (pointer: coarse) {
  body.has-dock {
    cursor: auto;
  }
  body.has-dock a,
  body.has-dock button {
    cursor: pointer;
  }
  .cursor {
    display: none;
  }
}

/* Floating dock header */
.dock-header {
  position: fixed;
  top: 18px;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  justify-content: center;
  padding: 0 16px;
  pointer-events: none;
}

.dock {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px 8px 12px;
  border-radius: 999px;
  background: rgba(17, 17, 19, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  max-width: 920px;
  width: max-content;
  transition: transform 0.35s var(--ease), box-shadow 0.35s ease;
}

.dock-header.is-compact .dock {
  transform: scale(0.96);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.4);
}

.dock-logo {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: -0.03em;
  padding-right: 6px;
}

.dock-logo .logo-mark {
  width: 28px;
  height: 28px;
  border-radius: 8px;
}

.dock-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 0 4px;
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);
  margin: 0 4px;
}

.dock-nav a {
  position: relative;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--mist);
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease;
}

.dock-nav a:hover,
.dock-nav a.is-active {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.06);
}

.dock-nav a.is-active {
  color: #062019;
  background: var(--accent);
}

.dock-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.dock-wa,
.dock-hire {
  font-size: 12px;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 999px;
}

.dock-wa {
  border: 1px solid var(--line-strong);
  color: var(--mist);
}

.dock-hire {
  background: var(--ink);
  color: var(--bg);
}

.dock-hire:hover {
  background: var(--accent);
}

.dock-toggle {
  display: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: transparent;
  place-items: center;
  gap: 5px;
  flex-direction: column;
}

.dock-toggle span {
  display: block;
  width: 14px;
  height: 1.5px;
  background: var(--ink);
}

.logo-mark {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  overflow: hidden;
  flex-shrink: 0;
}

.logo-mark img {
  width: 100%;
  height: 100%;
}

.logo-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: -0.03em;
}

/* Legacy aliases removed — dock only */

/* Hero */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  overflow: hidden;
  perspective: 1200px;
}

.hero-bg {
  position: absolute;
  inset: -12%;
  background:
    radial-gradient(60% 50% at 70% 20%, rgba(94, 234, 212, 0.18), transparent 55%),
    radial-gradient(40% 40% at 15% 80%, rgba(255, 255, 255, 0.05), transparent 50%),
    var(--bg);
  will-change: transform;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.38;
  mix-blend-mode: screen;
}

.hero-wallpaper {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  pointer-events: none;
  opacity: 0.9;
}

.hero-glow {
  position: absolute;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent-glow), transparent 70%);
  top: 10%;
  right: 5%;
  filter: blur(40px);
  pointer-events: none;
  will-change: transform;
  z-index: 1;
}

.hero-orb {
  position: absolute;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  left: 8%;
  bottom: 18%;
  background:
    radial-gradient(circle at 35% 30%, rgba(255, 255, 255, 0.18), transparent 40%),
    radial-gradient(circle at 50% 50%, rgba(94, 234, 212, 0.22), transparent 68%);
  filter: blur(2px);
  pointer-events: none;
  z-index: 1;
  will-change: transform;
  animation: orbFloat 9s ease-in-out infinite alternate;
}

@keyframes orbFloat {
  from {
    transform: translate3d(0, 0, 0) scale(1);
  }
  to {
    transform: translate3d(24px, -30px, 40px) scale(1.08);
  }
}

.hero-inner {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: calc(var(--header-h) + 56px) 0 100px;
  text-align: center;
  transform-style: preserve-3d;
  will-change: transform;
}

.hero-brand {
  margin-bottom: 22px;
  perspective: 900px;
  display: flex;
  justify-content: center;
}

.logo-3d {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: clamp(12px, 2vw, 22px);
  transform-style: preserve-3d;
  will-change: transform;
  transform: rotateX(12deg) rotateY(-14deg);
}

.logo-3d__mark {
  width: clamp(52px, 9vw, 84px);
  height: clamp(52px, 9vw, 84px);
  border-radius: 20px;
  overflow: hidden;
  flex-shrink: 0;
  transform: translateZ(48px);
  box-shadow:
    0 18px 40px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(94, 234, 212, 0.25),
    0 0 40px rgba(94, 234, 212, 0.2);
  animation: logoMarkFloat 5s ease-in-out infinite alternate;
}

.logo-3d__mark img {
  width: 100%;
  height: 100%;
}

@keyframes logoMarkFloat {
  from {
    transform: translateZ(48px) translateY(0);
  }
  to {
    transform: translateZ(56px) translateY(-8px);
  }
}

.logo-3d__word {
  position: relative;
  display: inline-block;
  transform-style: preserve-3d;
  font-family: var(--display);
  font-size: clamp(56px, 12vw, 120px);
  font-weight: 500;
  letter-spacing: -0.045em;
  line-height: 0.92;
  height: 1em;
}

.logo-3d__face,
.logo-3d__depth {
  display: block;
  white-space: nowrap;
}

.logo-3d__face {
  position: relative;
  z-index: 8;
  transform: translateZ(28px);
  background: linear-gradient(115deg, #ffffff 10%, #e8fffa 40%, #5eead4 78%, #a7f3e8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 40px rgba(94, 234, 212, 0.25);
  filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.35));
}

.logo-3d__depth {
  position: absolute;
  left: 0;
  top: 0;
  color: #0f2f2a;
  user-select: none;
  pointer-events: none;
}

.logo-3d__depth:nth-child(1) {
  transform: translateZ(0px);
  color: #062019;
}
.logo-3d__depth:nth-child(2) {
  transform: translateZ(4px);
  color: #0a3d36;
}
.logo-3d__depth:nth-child(3) {
  transform: translateZ(8px);
  color: #0f4f45;
}
.logo-3d__depth:nth-child(4) {
  transform: translateZ(12px);
  color: #146357;
}
.logo-3d__depth:nth-child(5) {
  transform: translateZ(16px);
  color: #1a7a6a;
}
.logo-3d__depth:nth-child(6) {
  transform: translateZ(22px);
  color: #2a9d89;
}

.logo-3d::after {
  content: "";
  position: absolute;
  left: 12%;
  right: 8%;
  bottom: -18%;
  height: 28%;
  background: radial-gradient(ellipse at center, rgba(94, 234, 212, 0.35), transparent 70%);
  filter: blur(16px);
  transform: translateZ(-20px) rotateX(80deg);
  pointer-events: none;
  opacity: 0.85;
}

@media (prefers-reduced-motion: reduce) {
  .logo-3d {
    transform: none;
  }
  .logo-3d__mark {
    animation: none;
    transform: none;
  }
  .logo-3d__depth {
    display: none;
  }
  .logo-3d__face {
    transform: none;
  }
}

.hero h1 {
  font-size: clamp(22px, 3.4vw, 36px);
  font-weight: 400;
  max-width: 640px;
  margin: 0 auto 16px;
  color: var(--ink);
}

.hero h1 em {
  font-style: italic;
  color: var(--accent);
}

.hero .lead {
  color: var(--ink-muted);
  max-width: 480px;
  margin: 0 auto 32px;
  font-size: 16px;
}

.hero-ctas {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 36px;
}

.hero-meta {
  display: flex;
  gap: 18px;
  justify-content: center;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--mist);
}

.hero-meta span {
  padding: 7px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.02);
}

.scroll-hint {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mist);
}

/* Sections */
section {
  padding: 110px 0;
  position: relative;
}

.section-head {
  max-width: 620px;
  margin-bottom: 48px;
}

.section-head.center {
  text-align: center;
  margin-inline: auto;
}

.section-head.center .eyebrow {
  justify-content: center;
}

.section-head h2 {
  font-size: clamp(30px, 4.5vw, 48px);
  margin-top: 14px;
}

.section-head p {
  margin-top: 14px;
  color: var(--mist);
  font-size: 16px;
  max-width: 520px;
  line-height: 1.65;
}

.section-head.center p {
  margin-inline: auto;
}

[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
}

/* Playground */
.play {
  background: var(--bg-2);
  overflow: hidden;
}

.play-board {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 28px;
  align-items: stretch;
}

.orbit {
  position: relative;
  min-height: 420px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background:
    radial-gradient(circle at 50% 50%, rgba(94, 234, 212, 0.08), transparent 55%),
    var(--bg);
  overflow: hidden;
  cursor: crosshair;
}

.orbit-core {
  position: absolute;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 1px solid rgba(94, 234, 212, 0.35);
  background: rgba(94, 234, 212, 0.06);
  display: grid;
  place-items: center;
  text-align: center;
  font-family: var(--display);
  font-size: 22px;
  z-index: 2;
  box-shadow: 0 0 60px var(--accent-glow);
}

.orbit-ring {
  position: absolute;
  inset: 50% auto auto 50%;
  border: 1px dashed rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.orbit-ring.r1 {
  width: 220px;
  height: 220px;
}

.orbit-ring.r2 {
  width: 320px;
  height: 320px;
}

.orbit-node {
  position: absolute;
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(17, 17, 19, 0.92);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.35s var(--ease), border-color 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
  z-index: 3;
  user-select: none;
}

.orbit-node:hover,
.orbit-node.is-active {
  border-color: rgba(94, 234, 212, 0.55);
  background: rgba(94, 234, 212, 0.1);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  transform: scale(1.06);
}

.orbit-node[data-i="0"] {
  top: 18%;
  left: 18%;
}
.orbit-node[data-i="1"] {
  top: 14%;
  right: 16%;
}
.orbit-node[data-i="2"] {
  bottom: 22%;
  left: 14%;
}
.orbit-node[data-i="3"] {
  bottom: 16%;
  right: 18%;
}
.orbit-node[data-i="4"] {
  top: 46%;
  left: 6%;
}
.orbit-node[data-i="5"] {
  top: 48%;
  right: 8%;
}

.play-detail {
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 28px;
  background: var(--bg-3);
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 420px;
}

.play-detail .tag {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.play-detail h3 {
  font-size: 32px;
  margin-bottom: 12px;
}

.play-detail p {
  color: var(--mist);
  line-height: 1.65;
  margin-bottom: 20px;
}

.play-detail ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.play-detail li {
  font-size: 14px;
  color: var(--ink-muted);
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.play-detail li::before {
  content: "";
  width: 7px;
  height: 7px;
  margin-top: 7px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

/* Name tunnel */
.name-tunnel {
  position: relative;
  height: 88px;
  overflow: hidden;
  border-block: 1px solid var(--line);
  background: var(--bg-2);
  perspective: 600px;
  display: flex;
  align-items: center;
}

.name-tunnel__track {
  display: flex;
  gap: 48px;
  width: max-content;
  animation: tunnelScroll 40s linear infinite;
  transform-style: preserve-3d;
  font-family: var(--display);
  font-size: clamp(28px, 5vw, 48px);
  letter-spacing: -0.04em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(94, 234, 212, 0.45);
  white-space: nowrap;
  padding-inline: 24px;
}

.name-tunnel__track span:nth-child(odd) {
  color: rgba(244, 244, 245, 0.12);
  -webkit-text-stroke: 0;
}

@keyframes tunnelScroll {
  from {
    transform: translate3d(0, 0, 0) rotateX(12deg);
  }
  to {
    transform: translate3d(-50%, 0, 0) rotateX(12deg);
  }
}

/* Work / 3D stack */
.work {
  background: var(--bg);
  padding-bottom: 80px;
}

.filters {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.center-filters {
  justify-content: center;
}

.filter-btn {
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--mist);
  font-size: 13px;
  font-weight: 600;
  transition: all 0.25s ease;
}

.filter-btn:hover,
.filter-btn.is-active {
  color: var(--bg);
  background: var(--accent);
  border-color: var(--accent);
}

.stack-stage {
  position: relative;
  min-height: 560px;
  perspective: 1600px;
  margin-top: 12px;
  user-select: none;
  touch-action: pan-y;
  overflow: visible;
}

.stack-deck {
  position: relative;
  width: min(520px, 92%);
  height: 520px;
  margin: 0 auto;
  transform-style: preserve-3d;
}

.stack-card {
  position: absolute;
  inset: 0;
  border: 1px solid var(--line);
  border-radius: 22px;
  overflow: hidden;
  background: var(--bg-2);
  display: flex;
  flex-direction: column;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
  transform-origin: center center;
  transition: transform 0.55s var(--ease), opacity 0.45s ease, filter 0.45s ease, box-shadow 0.45s ease;
  will-change: transform, opacity;
  cursor: pointer;
}

.stack-card.is-front {
  cursor: default;
  box-shadow:
    0 40px 100px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(94, 234, 212, 0.25);
}

.stack-card:not(.is-front):hover {
  filter: brightness(1.06) !important;
}

.stack-card .thumb {
  aspect-ratio: 16 / 11;
  position: relative;
  overflow: hidden;
  background: var(--bg-3);
  flex-shrink: 0;
}

.stack-card .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.stack-card .badge {
  position: absolute;
  top: 14px;
  left: 14px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 5px 9px;
  border-radius: 999px;
  background: rgba(10, 10, 11, 0.75);
  border: 1px solid var(--line);
  color: var(--accent);
  backdrop-filter: blur(8px);
}

.stack-card .project-body {
  padding: 20px 22px 22px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.stack-card .project-body h3 {
  font-family: var(--body);
  font-weight: 700;
  font-size: 22px;
  letter-spacing: -0.03em;
}

.stack-card .project-body p {
  font-size: 14px;
  color: var(--mist);
  line-height: 1.5;
  flex: 1;
}

.stack-card.is-hidden-filter {
  display: none !important;
}

.stack-edge {
  position: absolute;
  top: 0;
  bottom: 80px;
  width: 18%;
  z-index: 20;
  border: 0;
  background: transparent;
}

.stack-edge--prev {
  left: 0;
}

.stack-edge--next {
  right: 0;
}

.stack-ui {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 28px;
}

.stack-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.03);
  color: var(--ink);
  font-size: 18px;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.stack-btn:hover {
  background: var(--accent-dim);
  border-color: rgba(94, 234, 212, 0.45);
  transform: scale(1.05);
}

.stack-meta {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--mist);
  min-width: 200px;
  justify-content: center;
}

.stack-meta strong {
  font-family: var(--body);
  font-size: 15px;
  color: var(--ink);
  margin-left: 6px;
}

.stack-hint {
  text-align: center;
  margin-top: 12px;
  font-size: 12px;
  color: #71717a;
  font-family: var(--mono);
  letter-spacing: 0.06em;
}

.banner-parallax {
  overflow: hidden;
}

.banner-parallax img {
  will-change: transform;
  transform: scale(1.12);
}

/* Portal CTA */
.portal {
  position: relative;
  min-height: 70vh;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: var(--bg-2);
  text-align: center;
  padding: 80px 24px;
}

.portal-depth {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
}

.portal-depth span {
  position: absolute;
  border: 1px solid rgba(94, 234, 212, 0.18);
  border-radius: 50%;
  animation: portalPulse 6s ease-in-out infinite;
}

.portal-depth span:nth-child(1) {
  width: 180px;
  height: 180px;
  animation-delay: 0s;
}
.portal-depth span:nth-child(2) {
  width: 280px;
  height: 280px;
  animation-delay: 0.4s;
}
.portal-depth span:nth-child(3) {
  width: 400px;
  height: 400px;
  animation-delay: 0.8s;
}
.portal-depth span:nth-child(4) {
  width: 540px;
  height: 540px;
  animation-delay: 1.2s;
}
.portal-depth span:nth-child(5) {
  width: 700px;
  height: 700px;
  animation-delay: 1.6s;
}

@keyframes portalPulse {
  0%,
  100% {
    transform: scale(1) rotateX(55deg);
    opacity: 0.35;
  }
  50% {
    transform: scale(1.08) rotateX(55deg);
    opacity: 0.7;
  }
}

.portal-core {
  position: relative;
  z-index: 2;
}

.portal-core h2 {
  font-size: clamp(32px, 5vw, 56px);
  margin: 14px 0 28px;
}


/* Story / sticky */
.story {
  padding: 0;
  background: var(--bg-2);
}

.story-track {
  position: relative;
  height: 320vh;
}

.story-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
  display: grid;
  place-items: center;
}

.story-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 40px;
  padding: 0 max(24px, calc((100% - 1120px) / 2));
  opacity: 0;
  pointer-events: none;
  transform: translateY(40px);
}

.story-slide.is-active {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
}

.story-copy h2 {
  font-size: clamp(28px, 4vw, 46px);
  margin: 12px 0 14px;
}

.story-copy p {
  color: var(--mist);
  max-width: 420px;
  line-height: 1.65;
}

.story-visual {
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid var(--line);
  aspect-ratio: 4 / 3;
  background: var(--bg-3);
  position: relative;
  transform-style: preserve-3d;
  perspective: 900px;
}

.story-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.14);
  transition: transform 1.2s var(--ease);
  will-change: transform;
}

.story-slide.is-active .story-visual img {
  transform: scale(1);
}

.story-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(94, 234, 212, 0.12), transparent 50%);
  pointer-events: none;
}

.story-dots {
  position: absolute;
  right: 28px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 5;
}

.story-dots button {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 0;
  background: rgba(255, 255, 255, 0.25);
  cursor: pointer;
}

.story-dots button.is-active {
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-dim);
}

/* About */
.about {
  background: var(--bg);
}

.about-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
}

.about-card {
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px;
  background: var(--bg-2);
}

.about-card h3 {
  font-size: 28px;
  margin-bottom: 12px;
}

.about-card p {
  color: var(--mist);
  margin-bottom: 20px;
  line-height: 1.65;
}

.social-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

/* Contact */
.contact {
  background:
    radial-gradient(55% 45% at 50% 0%, rgba(94, 234, 212, 0.1), transparent 60%),
    var(--bg-2);
}

.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 40px;
  align-items: start;
}

.contact-links {
  margin-top: 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact-links a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
  transition: border-color 0.25s ease, background 0.25s ease;
  font-size: 14px;
}

.contact-links a:hover {
  border-color: rgba(94, 234, 212, 0.4);
  background: var(--accent-dim);
}

.contact-links .label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mist);
  min-width: 72px;
}

.contact-form {
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px;
  background: rgba(17, 17, 19, 0.9);
  backdrop-filter: blur(10px);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.field {
  margin-bottom: 12px;
}

.field label {
  display: block;
  font-size: 11px;
  font-family: var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--mist);
  margin-bottom: 8px;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 14px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.field textarea {
  min-height: 120px;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: rgba(94, 234, 212, 0.5);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

.form-status {
  margin-top: 10px;
  font-size: 14px;
  min-height: 20px;
}

.form-status.ok {
  color: var(--ok);
}

.form-status.err {
  color: var(--danger);
}

.btn[disabled] {
  opacity: 0.6;
  cursor: not-allowed;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 56px 0 28px;
  background: var(--bg);
  color: var(--mist);
}

.footer-top {
  display: flex;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 20px;
}

.footer-brand p {
  margin-top: 12px;
  max-width: 280px;
  font-size: 14px;
  line-height: 1.55;
}

.footer-cols {
  display: flex;
  gap: 48px;
  flex-wrap: wrap;
}

.footer-col h4 {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #71717a;
  margin-bottom: 12px;
}

.footer-col a {
  display: block;
  font-size: 14px;
  margin-bottom: 10px;
  color: var(--mist);
  transition: color 0.2s ease;
}

.footer-col a:hover {
  color: var(--accent);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 12.5px;
  color: #71717a;
}

/* Mobile */
@media (max-width: 980px) {
  .wrap {
    width: min(100% - 32px, 1120px);
  }

  .play-board,
  .about-grid,
  .contact-grid,
  .story-slide {
    grid-template-columns: 1fr;
  }

  .play-detail {
    min-height: auto;
  }

  .stack-deck {
    width: min(420px, 100%);
    height: 460px;
  }

  .stack-stage {
    min-height: 500px;
    overflow: visible;
  }

  .story-track {
    height: auto;
  }

  .story-sticky {
    position: relative;
    height: auto;
    display: flex;
    flex-direction: column;
    gap: 28px;
    padding: 64px 0;
  }

  .story-slide {
    position: relative;
    opacity: 1 !important;
    pointer-events: auto;
    transform: none !important;
    padding: 0;
    gap: 16px;
  }

  .story-dots {
    display: none;
  }

  .orbit {
    min-height: auto;
    height: auto;
    padding: 20px 14px 24px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    align-content: flex-start;
  }

  .orbit-ring,
  .orbit-core {
    display: none;
  }

  .orbit-node {
    position: static !important;
    transform: none !important;
    top: auto !important;
    left: auto !important;
    right: auto !important;
    bottom: auto !important;
  }

  .dock {
    width: min(100%, 420px);
    max-width: 100%;
  }

  .dock-nav {
    display: none;
  }

  .dock-header.open .dock {
    flex-wrap: wrap;
    border-radius: 24px;
    width: min(420px, calc(100vw - 24px));
    padding: 12px;
  }

  .dock-header.open .dock-nav {
    display: flex;
    flex-direction: column;
    width: 100%;
    border: 0;
    margin: 8px 0 0;
    order: 3;
  }

  .dock-header.open .dock-nav a {
    width: 100%;
    text-align: left;
  }

  .dock-toggle {
    display: grid;
  }

  .dock-word {
    display: none;
  }

  .logo-3d {
    flex-direction: column;
    gap: 10px;
    transform: rotateX(8deg) rotateY(0deg) !important;
  }

  .logo-3d__mark {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    animation: none;
    transform: translateZ(24px);
  }

  .logo-3d__word {
    font-size: clamp(42px, 14vw, 64px);
    height: auto;
  }

  .logo-3d__depth {
    display: none;
  }

  .logo-3d__face {
    transform: none;
  }

  .hero-inner {
    padding: calc(var(--header-h) + 28px) 0 72px;
  }

  .hero-ctas {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-ctas .btn {
    width: 100%;
  }

  .hero-meta {
    gap: 8px;
  }

  .hero-meta span {
    font-size: 11px;
    padding: 6px 10px;
  }

  .hero-wallpaper,
  .hero-orb {
    display: none;
  }

  .name-tunnel {
    height: 64px;
  }

  .name-tunnel__track {
    font-size: 28px;
    gap: 28px;
  }

  .portal {
    min-height: auto;
    padding: 72px 20px;
  }

  .portal-depth span:nth-child(n + 3) {
    display: none;
  }

  section {
    padding: 72px 0;
  }

  .stack-meta {
    min-width: 0;
    flex-wrap: wrap;
  }

  .stack-meta strong {
    width: 100%;
    text-align: center;
    margin: 4px 0 0;
  }
}

@media (max-width: 720px) {
  .wrap {
    width: min(100% - 28px, 1120px);
  }

  .dock-header {
    top: 12px;
    padding: 0 12px;
  }

  .dock-wa {
    display: none;
  }

  .stack-deck {
    height: 420px;
  }

  .stack-edge {
    display: none;
  }

  .stack-ui {
    gap: 10px;
  }

  .stack-btn {
    width: 44px;
    height: 44px;
  }

  .stack-hint {
    font-size: 11px;
    padding: 0 12px;
  }

  .stack-hint::after {
    content: " · tap cards or arrows";
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .contact-links a {
    flex-wrap: wrap;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 6px;
  }

  .section-head h2,
  .portal-core h2 {
    font-size: clamp(26px, 8vw, 36px);
  }

  .hero h1 {
    font-size: clamp(20px, 6.2vw, 28px);
  }

  .play-detail h3 {
    font-size: 26px;
  }

  .filters {
    justify-content: center;
  }

  /* Soften expensive effects on small phones */
  body::after {
    opacity: 0.02;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}

/* Contain paint for below-fold sections */
.play,
.work,
.story,
.about,
.contact,
.portal,
.site-footer {
  content-visibility: auto;
  contain-intrinsic-size: 1px 800px;
}



@media (prefers-reduced-motion: reduce) {
  .hero-wallpaper,
  .hero-orb {
    display: none !important;
  }
  .hero-orb {
    animation: none !important;
  }
  .name-tunnel__track {
    animation: none;
  }
  .portal-depth span {
    animation: none;
  }
  body.has-dock {
    cursor: auto;
  }
  .cursor {
    display: none;
  }
}
