:root {
  --night: #07101c;
  --ink: #f5f1d7;
  --muted: #a8b59e;
  --yellow: #ffd65a;
  --orange: #ef853b;
  --green: #72d66a;
  --mint: #82f2b2;
  --cyan: #5be6de;
  --blue: #5d8be8;
  --purple: #a777df;
  --rock: #232a35;
  --rock-dark: #121720;
  --dirt: #46352d;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html {
  min-width: 320px;
  background: var(--night);
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  overflow-x: hidden;
  background: var(--night);
  color: var(--ink);
  font-family: "Courier New", Courier, monospace;
}

button { font: inherit; }

.world {
  --pointer-x: 0;
  --pointer-y: 0;
  position: relative;
  min-height: max(790px, 100svh);
  overflow: hidden;
  background: var(--rock-dark);
  image-rendering: pixelated;
  isolation: isolate;
}

.world::before,
.world::after {
  content: "";
  position: absolute;
  z-index: 30;
  pointer-events: none;
  width: 22px;
  height: 22px;
  border-color: var(--muted);
  opacity: .7;
}

.world::before {
  left: 10px;
  top: 79px;
  border-left: 4px solid;
  border-top: 4px solid;
}

.world::after {
  right: 10px;
  bottom: 10px;
  border-right: 4px solid;
  border-bottom: 4px solid;
}

.site-header {
  position: relative;
  z-index: 28;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 65px;
  padding: 10px 22px;
  border-bottom: 4px solid #4b3725;
  background: rgba(10,15,22,.92);
  box-shadow: 0 4px 0 #16100b;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  color: var(--yellow);
  font-size: 15px;
  letter-spacing: .06em;
  text-shadow: 2px 2px #613d21;
}

.mini-duck {
  position: relative;
  width: 35px;
  height: 29px;
  flex: 0 0 auto;
  background: var(--yellow);
  clip-path: polygon(9% 45%,26% 45%,26% 27%,62% 27%,62% 0,88% 0,88% 15%,100% 15%,100% 48%,88% 48%,88% 67%,71% 67%,71% 83%,20% 83%,20% 70%,9% 70%);
  filter: drop-shadow(3px 3px #5e3e1c);
}

.mini-duck::before {
  content: "";
  position: absolute;
  right: 0;
  top: 9px;
  width: 9px;
  height: 6px;
  background: var(--orange);
}

.mini-duck::after {
  content: "";
  position: absolute;
  right: 10px;
  top: 5px;
  width: 3px;
  height: 3px;
  background: #141315;
}

.system-status {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #9fb5aa;
  font-size: 10px;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.status-dot {
  width: 8px;
  height: 8px;
  background: var(--mint);
  box-shadow: 0 0 0 2px #204b38, 0 0 12px var(--mint);
  animation: blink 1.3s steps(2,end) infinite;
}

.sky {
  position: absolute;
  z-index: 0;
  left: 0;
  right: 0;
  top: 65px;
  height: 115px;
  overflow: hidden;
  border-bottom: 8px solid #2c5d38;
  background: linear-gradient(#07101c 0 60%, #10223b 100%);
}

.sky::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -17px;
  height: 12px;
  background: repeating-linear-gradient(90deg, #1f3d28 0 8px, #31583a 8px 16px, #244a2f 16px 24px);
}

.star {
  position: absolute;
  width: 3px;
  height: 3px;
  background: #d6e8f7;
  box-shadow: 28px 13px #d6e8f7, 73px -8px #8499ad, 124px 16px #d6e8f7, 179px -2px #8499ad, 244px 11px #d6e8f7, 307px -10px #d6e8f7, 361px 17px #8499ad, 430px 3px #d6e8f7, 498px 14px #8499ad, 565px -7px #d6e8f7, 634px 12px #d6e8f7, 701px 0 #8499ad;
  animation: twinkle 2.4s steps(2,end) infinite;
  transform: translate(calc(var(--pointer-x) * -3px), calc(var(--pointer-y) * -2px));
}

.stars-a { left: 4%; top: 27px; }
.stars-b { left: 17%; top: 66px; animation-delay: .8s; }

.moon {
  position: absolute;
  right: 6%;
  top: 18px;
  width: 53px;
  height: 53px;
  background: #f8e5a1;
  box-shadow: 0 0 0 5px rgba(248,229,161,.08), 0 0 30px rgba(248,229,161,.22);
  clip-path: polygon(18% 0,82% 0,82% 9%,100% 9%,100% 73%,91% 73%,91% 91%,73% 91%,73% 100%,18% 100%,18% 91%,9% 91%,9% 73%,0 73%,0 18%,9% 18%,9% 9%,18% 9%);
  transform: translate(calc(var(--pointer-x) * -5px), calc(var(--pointer-y) * -3px));
}

.moon::before,
.moon::after { content: ""; position: absolute; background: #d7c77f; }
.moon::before { width: 8px; height: 8px; left: 12px; top: 12px; }
.moon::after { width: 12px; height: 7px; right: 9px; bottom: 13px; }

.trees {
  position: absolute;
  left: 5%;
  right: 5%;
  bottom: 0;
  height: 52px;
  opacity: .9;
  transform: translateX(calc(var(--pointer-x) * -2px));
}

.tree {
  position: absolute;
  bottom: 0;
  width: 9px;
  height: 48px;
  background: #172d22;
  box-shadow: -16px 10px 0 2px #172d22, 13px 18px 0 3px #172d22;
}

.tree::before {
  content: "";
  position: absolute;
  width: 37px;
  height: 35px;
  left: -14px;
  top: -17px;
  background: #14301e;
  clip-path: polygon(33% 0,66% 0,66% 14%,86% 14%,86% 33%,100% 33%,100% 72%,82% 72%,82% 90%,18% 90%,18% 75%,0 75%,0 33%,14% 33%,14% 15%,33% 15%);
}

.tree-1 { left: 2%; }
.tree-2 { left: 18%; transform: scale(.75); transform-origin: bottom; }
.tree-3 { right: 22%; transform: scale(.85); transform-origin: bottom; }
.tree-4 { right: 4%; transform: scale(.65); transform-origin: bottom; }

.earth {
  position: absolute;
  z-index: 1;
  left: 0;
  right: 0;
  top: 188px;
  bottom: 0;
  background: repeating-linear-gradient(0deg, transparent 0 31px, rgba(0,0,0,.08) 31px 33px), repeating-linear-gradient(90deg, #342c2a 0 32px, #3e302b 32px 64px, #322a29 64px 96px);
}

.earth::before {
  content: "";
  position: absolute;
  inset: 12px 2% 35px;
  background: var(--rock);
  clip-path: polygon(2% 14%,8% 14%,8% 7%,19% 7%,19% 2%,34% 2%,34% 8%,48% 8%,48% 3%,66% 3%,66% 8%,82% 8%,82% 3%,93% 3%,93% 11%,98% 11%,98% 82%,93% 82%,93% 91%,81% 91%,81% 97%,61% 97%,61% 92%,42% 92%,42% 97%,23% 97%,23% 91%,8% 91%,8% 84%,2% 84%);
  box-shadow: inset 0 0 0 8px #30394a, inset 0 0 0 14px #181e29;
}

.strata {
  position: absolute;
  inset: 188px 0 0;
  z-index: 2;
  pointer-events: none;
  opacity: .5;
  background: linear-gradient(90deg,transparent 0 10%,rgba(116,128,143,.12) 10% 11%,transparent 11% 69%,rgba(116,128,143,.1) 69% 70%,transparent 70%), linear-gradient(0deg,transparent 0 24%,rgba(116,128,143,.09) 24% 25%,transparent 25% 72%,rgba(116,128,143,.08) 72% 73%,transparent 73%);
  background-size: 140px 104px;
}

.stalactite {
  position: absolute;
  z-index: 3;
  top: 188px;
  width: 35px;
  height: 65px;
  background: #30394a;
  clip-path: polygon(0 0,100% 0,75% 36%,64% 36%,52% 100%,42% 100%,30% 40%,18% 40%);
  filter: drop-shadow(5px 5px #181e29);
}

.stalactite-1 { left: 34%; }
.stalactite-2 { right: 28%; transform: scale(.7); transform-origin: top; }
.stalactite-3 { right: 6%; transform: scale(.5); transform-origin: top; }

.root {
  position: absolute;
  z-index: 4;
  top: 178px;
  width: 8px;
  height: 145px;
  background: #4b3725;
  box-shadow: 5px 0 #16100b;
  clip-path: polygon(0 0,100% 0,100% 45%,50% 45%,50% 72%,100% 72%,100% 100%,25% 100%,25% 68%,0 68%);
}

.root::after { content: ""; position: absolute; left: -9px; bottom: 0; width: 26px; height: 7px; background: #4b3725; }
.root-1 { left: 3%; }
.root-2 { right: 16%; height: 108px; transform: scaleX(-1); }

.scene-layout {
  position: relative;
  z-index: 8;
  display: grid;
  grid-template-columns: minmax(250px,.74fr) minmax(405px,1.26fr);
  gap: 30px;
  width: min(1180px, 100%);
  min-height: 660px;
  margin: 0 auto;
  padding: 145px 4.5% 78px;
}

.puzzle-copy {
  position: relative;
  align-self: start;
  margin-top: 21px;
  padding: 20px 20px 18px;
  border: 4px solid #6e553b;
  background: #151b24;
  box-shadow: inset 0 0 0 3px #272f3d, 7px 7px 0 rgba(0,0,0,.35);
}

.puzzle-copy::before,
.puzzle-copy::after { content: ""; position: absolute; width: 7px; height: 7px; background: #b3915e; }
.puzzle-copy::before { left: 5px; top: 5px; }
.puzzle-copy::after { right: 5px; bottom: 5px; }

.kicker { color: var(--mint); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; }

h1 {
  margin: 12px 0 11px;
  color: var(--ink);
  font-size: clamp(25px,3.6vw,43px);
  font-weight: 500;
  line-height: 1.05;
  letter-spacing: -.05em;
  text-transform: uppercase;
  text-shadow: 3px 3px #593d29;
}

h1 em { color: var(--yellow); font-style: normal; }
.puzzle-copy p { margin: 0; color: #aab6a8; font-size: 12px; line-height: 1.55; }

.rule {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 9px;
  align-items: center;
  margin: 16px 0 10px;
  color: #788b83;
  font-size: 9px;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.rule::before,
.rule::after { content: ""; height: 2px; background: #435260; }

.sequence { display: flex; gap: 7px; justify-content: center; margin: 0 0 13px; }

.sequence-token {
  position: relative;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 3px solid #435260;
  background: #222b37;
  color: #96aba2;
  font-size: 10px;
  box-shadow: 3px 3px #0c1219;
}

.sequence-token.is-next {
  border-color: #d5a849;
  background: #4c3c21;
  color: #ffe38a;
  box-shadow: 3px 3px #0c1219, 0 0 10px rgba(255,214,90,.25);
}

.sequence-token::after { content: attr(data-step); position: absolute; right: 2px; bottom: 0; color: #788b83; font-size: 7px; }

.readout {
  min-height: 43px;
  padding: 9px 10px;
  border-left: 4px solid var(--cyan);
  background: #0c1219;
  color: #83d9d5;
  font-size: 10px;
  line-height: 1.45;
}

.progress { display: grid; grid-template-columns: repeat(4,1fr); gap: 4px; margin-top: 11px; }
.progress i { height: 5px; background: #28333d; }
.progress i.is-done { background: var(--mint); box-shadow: 0 0 7px rgba(130,242,178,.35); }
.coordinates { display: flex; justify-content: space-between; gap: 10px; margin-top: 11px; color: #788b83; font-size: 8px; letter-spacing: .08em; }

.shrine { position: relative; align-self: center; min-height: 470px; }

.arch {
  position: absolute;
  left: 50%;
  top: 49%;
  width: min(450px,93%);
  aspect-ratio: 1;
  transform: translate(-50%,-50%);
  border: 10px solid #30394a;
  border-radius: 50% 50% 8% 8%;
  background: radial-gradient(circle at 50% 48%,#0c131c 0 39%,#181e29 40% 52%,#232a35 53% 64%,#181e29 65%);
  box-shadow: inset 0 0 0 7px #181e29, 0 0 0 6px #121720, 9px 10px rgba(0,0,0,.3);
}

.arch::before {
  content: "";
  position: absolute;
  inset: 7%;
  border: 3px solid #435260;
  border-radius: 50%;
  background: repeating-conic-gradient(from 0deg, transparent 0 8deg, rgba(91,230,222,.12) 8deg 10deg, transparent 10deg 22deg);
  animation: ring 32s steps(96,end) infinite;
}

.arch::after {
  content: "";
  position: absolute;
  inset: 18%;
  border: 4px solid #272f3d;
  border-radius: 50%;
  box-shadow: 0 0 0 2px #0c1219, inset 0 0 24px rgba(91,230,222,.08);
}

.cardinal { position: absolute; z-index: 3; color: #788b83; font-size: 8px; letter-spacing: .1em; }
.north { left: 50%; top: 7%; transform: translateX(-50%); }
.south { left: 50%; bottom: 5%; transform: translateX(-50%); }
.west { left: 5%; top: 49%; }
.east { right: 4%; top: 49%; }

.cables { position: absolute; z-index: 2; inset: 0; width: 100%; height: 100%; overflow: visible; }
.cable { fill: none; stroke: #24404a; stroke-width: 9; stroke-linecap: square; stroke-linejoin: round; }
.packet { fill: none; stroke: var(--cyan); stroke-width: 2; stroke-dasharray: 3 14; stroke-linecap: square; animation: packet 3.2s linear infinite; filter: drop-shadow(0 0 4px #5be6de); }
.packet-2 { animation-delay: -.8s; animation-duration: 4.1s; }
.packet-3 { animation-direction: reverse; animation-duration: 3.7s; }
.packet-4 { animation-delay: -1.7s; animation-direction: reverse; animation-duration: 4.5s; }

.relay {
  position: absolute;
  z-index: 8;
  width: 71px;
  height: 82px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #aab8c7;
  cursor: pointer;
}

.relay:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; }

.relay-crystal {
  position: absolute;
  left: 22px;
  top: 0;
  width: 28px;
  height: 47px;
  background: #3f5367;
  clip-path: polygon(36% 0,68% 0,100% 35%,82% 100%,23% 100%,0 38%);
  box-shadow: inset 6px 0 rgba(255,255,255,.06);
  transition: background .16s, box-shadow .16s;
}

.relay-base { position: absolute; left: 9px; bottom: 0; width: 53px; height: 29px; border: 4px solid #4d5968; background: #1d2530; box-shadow: 4px 4px rgba(0,0,0,.35); }
.relay-id { position: absolute; inset: auto 0 4px; text-align: center; color: #d2d8d4; font-size: 9px; }
.relay:hover .relay-crystal,
.relay.is-lit .relay-crystal { background: var(--cyan); box-shadow: inset 7px 0 rgba(255,255,255,.23), 0 0 18px rgba(91,230,222,.7); }
.relay-1 { left: 4%; top: 13%; }
.relay-2 { right: 4%; top: 13%; }
.relay-3 { left: 4%; bottom: 9%; }
.relay-4 { right: 4%; bottom: 9%; }

.terminal {
  position: absolute;
  z-index: 9;
  left: 50%;
  top: 49%;
  width: 160px;
  height: 151px;
  padding: 0;
  transform: translate(-50%,-50%);
  border: 6px solid #566274;
  background: #1b2530;
  box-shadow: inset 0 0 0 5px #0e151d, 0 0 0 5px #0b0f15, 8px 8px rgba(0,0,0,.4);
  color: inherit;
  cursor: pointer;
}

.terminal:focus-visible,
.miner:focus-visible,
.waterfall:focus-visible,
.lily-duck:focus-visible,
.slot:focus-visible { outline: 3px solid var(--yellow); outline-offset: 3px; }

.terminal::before,
.terminal::after { content: ""; position: absolute; top: 21px; width: 7px; height: 68px; background: #637083; }
.terminal::before { left: -12px; }
.terminal::after { right: -12px; }
.antenna { position: absolute; left: 50%; top: -34px; width: 5px; height: 30px; background: #637083; }
.antenna::before { content: ""; position: absolute; left: -5px; top: -7px; width: 15px; height: 12px; background: var(--purple); box-shadow: 0 0 12px var(--purple); animation: blink .8s steps(2,end) infinite; }

.terminal-screen {
  position: absolute;
  left: 19px;
  right: 19px;
  top: 18px;
  height: 75px;
  overflow: hidden;
  border: 4px solid #293844;
  background: #09231f;
  box-shadow: inset 0 0 18px rgba(91,230,222,.14);
}

.terminal-screen::after { content: ""; position: absolute; left: 0; right: 0; top: -7px; height: 5px; background: rgba(91,230,222,.18); animation: scan 2.7s steps(12,end) infinite; }
.screen-duck { position: absolute; left: 22px; top: 25px; width: 58px; height: 35px; background: var(--yellow); clip-path: polygon(0 42%,18% 42%,18% 22%,60% 22%,60% 0,83% 0,83% 13%,100% 13%,100% 48%,83% 48%,83% 66%,66% 66%,66% 82%,16% 82%,16% 67%,0 67%); animation: bob 1.6s steps(2,end) infinite; }
.screen-duck::before { content: ""; position: absolute; right: 0; top: 8px; width: 13px; height: 7px; background: var(--orange); }
.screen-duck::after { content: ""; position: absolute; right: 12px; top: 4px; width: 3px; height: 3px; background: #07110d; }
.screen-code { position: absolute; right: 7px; top: 10px; color: #55c8aa; font-size: 8px; line-height: 1.5; text-align: right; }
.terminal-lights { position: absolute; left: 18px; right: 18px; bottom: 18px; display: flex; gap: 8px; }
.terminal-lights i { width: 11px; height: 11px; border: 2px solid #0c1016; background: #28333d; }
.terminal-lights i:nth-child(1) { background: #e76952; }
.terminal-lights i:nth-child(2) { background: #d7b34e; animation: blink 1s steps(2,end) infinite; }
.terminal-lights i:nth-child(3) { background: #55cf83; }
.terminal-label { position: absolute; left: 0; right: 0; bottom: 2px; color: #788b83; font-size: 7px; letter-spacing: .1em; text-align: center; }

.platform { position: absolute; z-index: 7; left: 18%; right: 18%; bottom: 1%; height: 25px; border-top: 6px solid #566274; background: repeating-linear-gradient(90deg,#30394a 0 28px,#272f3d 28px 56px); box-shadow: 0 7px #121720; }
.miner { position: absolute; z-index: 11; left: 24%; bottom: 6%; width: 80px; height: 90px; padding: 0; border: 0; background: transparent; color: inherit; cursor: pointer; animation: bob 1.8s steps(2,end) infinite; }
.miner-body { position: absolute; left: 8px; bottom: 12px; width: 53px; height: 35px; background: var(--yellow); clip-path: polygon(0 24%,13% 24%,13% 10%,75% 10%,75% 0,88% 0,88% 12%,100% 12%,100% 60%,87% 60%,87% 78%,70% 78%,70% 92%,14% 92%,14% 78%,0 78%); filter: drop-shadow(4px 4px #554021); }
.miner-beak { position: absolute; right: 2px; bottom: 40px; width: 22px; height: 11px; background: var(--orange); }
.miner-eye { position: absolute; z-index: 2; right: 21px; bottom: 54px; width: 4px; height: 4px; background: #131517; }
.helmet { position: absolute; right: 14px; bottom: 60px; width: 39px; height: 17px; border-top: 5px solid #93a5b8; background: #7085a0; box-shadow: 4px 0 #344456; }
.helmet::before { content: ""; position: absolute; right: 4px; top: -12px; width: 11px; height: 11px; background: #f6e58e; box-shadow: 0 0 10px #f6e58e; }
.miner-pack { position: absolute; left: 0; bottom: 32px; width: 17px; height: 27px; border: 4px solid #294639; background: #496c5b; }
.feet { position: absolute; left: 17px; bottom: 4px; width: 17px; height: 8px; background: var(--orange); box-shadow: 28px 0 var(--orange); }
.pickaxe { position: absolute; right: -6px; bottom: 7px; width: 5px; height: 48px; background: #8b6647; transform: rotate(38deg); transform-origin: bottom; }
.pickaxe::before { content: ""; position: absolute; left: -12px; top: -3px; width: 30px; height: 7px; background: #9aa6b5; }

.waterfall { position: absolute; z-index: 5; right: 3.5%; top: 255px; width: 42px; height: 350px; padding: 0; border: 0; border-left: 5px solid #407ab2; border-right: 5px solid #153656; background: repeating-linear-gradient(90deg,#173d63 0 8px,#1d4c76 8px 16px,#65b9d5 16px 19px,#173d63 19px 28px); cursor: pointer; animation: fall 1.2s steps(5,end) infinite; opacity: .9; }
.waterfall::before { content: ""; position: absolute; left: -12px; right: -12px; bottom: -11px; height: 17px; background: #1d4c76; box-shadow: -9px 6px #173d63, 10px 5px #153656; }
.water { position: absolute; z-index: 6; left: 0; right: 0; bottom: 0; height: 48px; border-top: 5px solid #407ab2; background: repeating-linear-gradient(90deg,#173d63 0 20px,#1d4c76 20px 40px,#153656 40px 60px); animation: water 2s steps(2,end) infinite; }
.water::before { content: ""; position: absolute; left: 3%; top: 10px; width: 20px; height: 4px; background: #65b9d5; box-shadow: 70px 13px #65b9d5,151px 1px #65b9d5,240px 18px #65b9d5,330px 4px #65b9d5,421px 15px #65b9d5,510px 3px #65b9d5,612px 17px #65b9d5; opacity: .65; }
.lily { position: absolute; z-index: 7; right: 16%; bottom: 40px; width: 50px; height: 14px; background: #4b9c54; clip-path: polygon(0 25%,24% 25%,24% 0,75% 0,75% 25%,100% 25%,100% 75%,75% 75%,75% 100%,25% 100%,25% 75%,0 75%); animation: lily 2s steps(2,end) infinite; }
.lily-duck { position: absolute; z-index: 8; right: 19%; bottom: 50px; width: 39px; height: 31px; padding: 0; border: 0; background: var(--yellow); cursor: pointer; clip-path: polygon(0 42%,20% 42%,20% 22%,62% 22%,62% 0,85% 0,85% 16%,100% 16%,100% 52%,83% 52%,83% 72%,66% 72%,66% 88%,17% 88%,17% 72%,0 72%); animation: lily 2s steps(2,end) infinite; }
.lily-duck::before { content: ""; position: absolute; right: 0; top: 9px; width: 11px; height: 6px; background: var(--orange); }

.mushroom { position: absolute; z-index: 7; width: 18px; height: 24px; background: #d7c29f; clip-path: polygon(38% 42%,62% 42%,62% 100%,38% 100%); }
.mushroom::before { content: ""; position: absolute; left: 0; top: 0; width: 18px; height: 12px; background: #b568c7; clip-path: polygon(25% 0,75% 0,75% 17%,100% 17%,100% 75%,0 75%,0 17%,25% 17%); box-shadow: 0 0 9px rgba(181,104,199,.45); }
.mushroom-1 { left: 3%; bottom: 48px; }
.mushroom-2 { left: 6%; bottom: 48px; transform: scale(.7); }
.mushroom-3 { right: 7%; bottom: 48px; transform: scale(.8); }

.firefly { position: absolute; z-index: 13; width: 5px; height: 5px; background: #c7ff82; box-shadow: 0 0 9px #c7ff82; animation: firefly 4s steps(8,end) infinite alternate; }
.firefly-1 { left: 39%; top: 35%; }
.firefly-2 { right: 17%; top: 45%; animation-delay: -1.3s; }
.firefly-3 { left: 35%; bottom: 22%; animation-delay: -2.1s; }
.ore { position: absolute; z-index: 3; width: 10px; height: 10px; background: var(--purple); box-shadow: 13px 7px #6a4fa2,6px 19px var(--purple),22px 23px #6a4fa2; transform: rotate(45deg); opacity: .8; }
.ore-1 { right: 7%; top: 35%; }
.ore-2 { left: 34%; top: 32%; transform: rotate(45deg) scale(.75); }
.drip { position: absolute; z-index: 5; top: 247px; width: 4px; height: 8px; background: #65b9d5; animation: drip 2.3s steps(8,end) infinite; }
.drip-1 { left: 39%; }
.drip-2 { left: 71%; animation-delay: -1.2s; }

.inventory { position: absolute; z-index: 20; left: 50%; bottom: 10px; transform: translateX(-50%); display: flex; gap: 4px; padding: 5px; border: 3px solid #554533; background: rgba(15,19,26,.94); box-shadow: 4px 4px rgba(0,0,0,.35); }
.slot { position: relative; display: grid; place-items: end center; width: 39px; height: 39px; padding: 0 0 2px; border: 3px solid #526070; background: #212a35; box-shadow: inset 3px 3px #151b23; color: #c3c9c3; font-size: 8px; cursor: pointer; }
.slot.is-selected { border-color: #f5d66d; box-shadow: inset 3px 3px #151b23,0 0 0 2px #7b642e; }
.item { position: absolute; left: 10px; top: 7px; width: 14px; height: 14px; }
.bread { background: #b97b40; box-shadow: 3px -3px #e5b268; clip-path: polygon(0 25%,25% 25%,25% 0,75% 0,75% 25%,100% 25%,100% 100%,0 100%); }
.feather { background: #f7e17d; clip-path: polygon(42% 0,100% 0,100% 43%,71% 43%,71% 71%,29% 71%,29% 100%,0 100%,0 58%,29% 58%,29% 29%,42% 29%); }
.crystal { background: #67dacf; clip-path: polygon(50% 0,100% 42%,76% 100%,22% 100%,0 42%); }
.key { background: #d7ac4d; clip-path: polygon(0 0,57% 0,57% 28%,100% 28%,100% 57%,84% 57%,84% 84%,65% 84%,65% 57%,44% 57%,44% 100%,0 100%); }
.pearl { background: #b58bdd; box-shadow: 4px 4px #644b81; }
.item-count { position: absolute; right: 2px; bottom: 1px; color: #fff; font-size: 8px; text-shadow: 1px 1px #000; }
.depth-status { position: absolute; z-index: 20; left: 18px; bottom: 17px; color: #9fb5aa; font-size: 8px; letter-spacing: .12em; text-transform: uppercase; }
.depth-status::before { content: ""; display: inline-block; width: 7px; height: 7px; margin-right: 7px; background: var(--purple); box-shadow: 0 0 8px var(--purple); }
.noscript { position: absolute; z-index: 40; left: 50%; bottom: 66px; transform: translateX(-50%); padding: 8px 10px; border: 3px solid #6e553b; background: #151b24; color: var(--yellow); font-size: 10px; }

.survey-cue {
  position: absolute;
  z-index: 20;
  right: 18px;
  bottom: 17px;
  color: var(--cyan);
  font-size: 8px;
  letter-spacing: .12em;
  text-decoration: none;
  text-transform: uppercase;
}

.survey-cue:hover { color: var(--yellow); }
.survey-cue:focus-visible { outline: 3px solid var(--yellow); outline-offset: 5px; }

.terminal.is-open { box-shadow: inset 0 0 0 5px #0e151d, 0 0 0 5px #0b0f15, 0 0 28px rgba(91,230,222,.55), 8px 8px rgba(0,0,0,.4); }
.terminal.is-open .terminal-screen { background: #0c131c; }
.miner.is-mining .pickaxe { animation: mine-swing .32s steps(3,end) 3; }
.lily-duck.is-quacking { filter: drop-shadow(0 0 9px var(--yellow)); }
.world.is-water-paused .waterfall,
.world.is-water-paused .water { animation-play-state: paused; opacity: .55; }
.world.server-pulse .arch { box-shadow: inset 0 0 0 7px #181e29, 0 0 0 6px #121720, 0 0 30px rgba(91,230,222,.55), 9px 10px rgba(0,0,0,.3); }

.thrown-bread {
  position: absolute;
  z-index: 24;
  left: 50%;
  bottom: 52px;
  width: 14px;
  height: 14px;
  pointer-events: none;
  background: #b97b40;
  box-shadow: 3px -3px #e5b268;
  clip-path: polygon(0 25%,25% 25%,25% 0,75% 0,75% 25%,100% 25%,100% 100%,0 100%);
  animation: toss-bread .85s steps(9,end) forwards;
}

.overview {
  scroll-margin-top: 0;
  padding: 58px max(18px,4vw) 64px;
  overflow: hidden;
  border-top: 8px solid #30394a;
  background: repeating-linear-gradient(0deg,transparent 0 31px,rgba(0,0,0,.08) 31px 33px), repeating-linear-gradient(90deg,#121720 0 64px,#151b24 64px 128px);
  color: var(--ink);
}

.overview-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 36px;
  width: min(1380px,100%);
  margin: 0 auto 24px;
}

.overview-header h2 {
  margin: 9px 0 0;
  color: var(--ink);
  font-size: clamp(28px,4vw,52px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -.05em;
  text-transform: uppercase;
  text-shadow: 3px 3px #593d29;
}

.overview-header h2 em { color: var(--yellow); font-style: normal; }
.overview-header p { max-width: 430px; margin: 0 0 3px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.overview-intro { display: grid; justify-items: end; gap: 13px; }

.survey-progress {
  display: grid;
  grid-template-columns: repeat(5,18px);
  gap: 5px;
  color: var(--cyan);
  font-size: 8px;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.survey-progress span { grid-column: 1 / -1; justify-self: end; }
.survey-progress i { height: 6px; border: 1px solid #30505b; background: #18242e; }
.survey-progress i.is-done { border-color: var(--yellow); background: var(--yellow); box-shadow: 0 0 7px rgba(255,214,90,.55); }

.overview-frame {
  position: relative;
  width: min(1380px,100%);
  margin: 0 auto;
  overflow: hidden;
  border: 6px solid #566274;
  background: #0c1219;
  box-shadow: inset 0 0 0 4px #121720, 10px 10px rgba(0,0,0,.35);
}

.overview-frame::before,
.overview-frame::after { content: ""; position: absolute; z-index: 4; width: 18px; height: 18px; pointer-events: none; border-color: var(--yellow); }
.overview-frame::before { left: 9px; top: 9px; border-left: 4px solid; border-top: 4px solid; }
.overview-frame::after { right: 9px; bottom: 9px; border-right: 4px solid; border-bottom: 4px solid; }

.overview-frame img { display: block; width: 100%; height: auto; image-rendering: pixelated; }

.hotspot {
  position: absolute;
  z-index: 6;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 3px solid var(--cyan);
  background: rgba(7,16,28,.84);
  color: var(--ink);
  font-size: 8px;
  cursor: pointer;
  box-shadow: 0 0 0 4px rgba(91,230,222,.15), 0 0 15px rgba(91,230,222,.55);
  animation: hotspot 1.8s steps(2,end) infinite;
}

.hotspot:hover,
.hotspot.is-active { border-color: var(--yellow); color: var(--yellow); box-shadow: 0 0 0 4px rgba(255,214,90,.15), 0 0 18px rgba(255,214,90,.55); }
.hotspot.is-inspected::after { content: "✓"; position: absolute; right: -8px; top: -9px; color: var(--mint); font-size: 10px; text-shadow: 2px 2px #07101c; }
.hotspot:focus-visible { outline: 3px solid var(--yellow); outline-offset: 4px; }
.hotspot-waterfall { left: 17.5%; top: 53%; }
.hotspot-relays { left: 52%; top: 51%; }
.hotspot-gate { left: 50%; top: 62%; }
.hotspot-terminal { left: 75%; top: 21%; }
.hotspot-duck { left: 69%; top: 79%; }

.overview-note {
  position: absolute;
  z-index: 5;
  left: 24px;
  bottom: 24px;
  width: min(370px,42%);
  min-height: 112px;
  padding: 13px 15px;
  border: 4px solid #6e553b;
  background: rgba(10,15,22,.92);
  box-shadow: inset 0 0 0 3px #272f3d, 6px 6px rgba(0,0,0,.35);
}

.overview-note span { color: var(--mint); font-size: 8px; letter-spacing: .12em; }
.overview-note strong { display: block; margin-top: 5px; color: var(--yellow); font-size: 13px; text-transform: uppercase; }
.overview-note p { margin: 6px 0 0; color: var(--muted); font-size: 10px; line-height: 1.5; }

.operations {
  position: relative;
  padding: 74px max(18px,4vw) 82px;
  overflow: hidden;
  border-top: 8px solid #4b3725;
  background: radial-gradient(circle at 73% 12%,rgba(91,230,222,.08),transparent 28%), repeating-linear-gradient(0deg,transparent 0 31px,rgba(91,230,222,.025) 31px 33px), #0a0f16;
}

.operations::before {
  content: "QK // MAINTENANCE BUS 04";
  position: absolute;
  right: 4vw;
  top: 22px;
  color: #33434a;
  font-size: 8px;
  letter-spacing: .18em;
}

.operations-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 36px;
  width: min(1380px,100%);
  margin: 0 auto 27px;
}

.operations-header h2 {
  margin: 9px 0 0;
  color: var(--ink);
  font-size: clamp(30px,4vw,52px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -.05em;
  text-transform: uppercase;
  text-shadow: 3px 3px #593d29;
}

.operations-header h2 em { color: var(--yellow); font-style: normal; }
.operations-header > p { max-width: 470px; margin: 0 0 3px; color: var(--muted); font-size: 12px; line-height: 1.65; }

.operations-grid {
  display: grid;
  grid-template-columns: minmax(0,1.7fr) minmax(290px,.8fr);
  gap: 18px;
  width: min(1380px,100%);
  margin: 0 auto;
}

.ops-panel {
  position: relative;
  min-width: 0;
  border: 5px solid #3d4857;
  background: #111821;
  box-shadow: inset 0 0 0 3px #090d13, 8px 8px rgba(0,0,0,.35);
}

.ops-panel::before,
.ops-panel::after { content: ""; position: absolute; z-index: 3; width: 11px; height: 11px; background: #6d7885; box-shadow: inset 2px 2px #252d38; }
.ops-panel::before { left: 7px; top: 7px; }
.ops-panel::after { right: 7px; bottom: 7px; }
.route-console { grid-row: span 2; }

.panel-header {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 68px;
  padding: 12px 17px;
  border-bottom: 4px solid #303a47;
  background: #151e28;
}

.panel-header div > span { color: var(--mint); font-size: 7px; letter-spacing: .14em; }
.panel-header h3 { margin: 5px 0 0; color: var(--ink); font-size: 15px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; }
.panel-state { display: flex; align-items: center; gap: 8px; color: #82978e; font-size: 7px; letter-spacing: .1em; }
.panel-state i { width: 7px; height: 7px; background: var(--mint); box-shadow: 0 0 9px var(--mint); animation: blink 1.4s steps(2,end) infinite; }
.panel-state b { font-weight: 400; }

.route-map {
  position: relative;
  height: 360px;
  overflow: hidden;
  border-bottom: 4px solid #303a47;
  background-image: linear-gradient(rgba(91,230,222,.055) 1px,transparent 1px), linear-gradient(90deg,rgba(91,230,222,.055) 1px,transparent 1px), radial-gradient(circle at 50% 50%,rgba(40,99,95,.22),transparent 56%);
  background-size: 28px 28px,28px 28px,100% 100%;
}

.route-map::before {
  content: "";
  position: absolute;
  inset: 18px;
  border: 2px solid rgba(91,230,222,.12);
  box-shadow: inset 0 0 35px rgba(91,230,222,.035);
}

.route-track { position: absolute; z-index: 1; height: 5px; transform-origin: left center; background: repeating-linear-gradient(90deg,#2b5a62 0 8px,transparent 8px 13px); box-shadow: 0 0 8px rgba(91,230,222,.14); }
.track-a { left: 14%; top: 67%; width: 29%; transform: rotate(-47deg); }
.track-b { left: 36%; top: 29%; width: 25%; transform: rotate(38deg); }
.track-c { left: 56%; top: 61%; width: 24%; transform: rotate(-46deg); }
.track-d { left: 71%; top: 29%; width: 21%; transform: rotate(47deg); }

.route-packet { position: absolute; z-index: 4; left: 12%; top: 68%; width: 8px; height: 8px; background: var(--yellow); box-shadow: 0 0 12px var(--yellow); opacity: 0; }
.route-map.is-running .route-packet { opacity: 1; animation: route-packet 2.5s steps(20,end) infinite; }

.map-node {
  position: absolute;
  z-index: 5;
  display: grid;
  justify-items: center;
  gap: 4px;
  width: 88px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #92a6a0;
  cursor: pointer;
}

.map-node i { width: 22px; height: 22px; border: 4px solid #4e6471; background: #17232c; transform: rotate(45deg); box-shadow: inset 0 0 0 3px #0a1017, 0 0 10px rgba(91,230,222,.12); }
.map-node strong { margin-top: 4px; color: var(--ink); font-size: 9px; letter-spacing: .08em; }
.map-node small { color: #667a79; font-size: 7px; }
.map-node:hover i,
.map-node.is-active i,
.route-map.is-running .map-node i { border-color: var(--cyan); background: #174047; box-shadow: inset 0 0 0 3px #0a1017, 0 0 14px rgba(91,230,222,.6); }
.map-node:focus-visible { outline: 3px solid var(--yellow); outline-offset: 5px; }
.map-node.is-active strong { color: var(--yellow); }
.node-origin { left: 7%; top: 61%; }
.node-reed { left: 31%; top: 19%; }
.node-moss { left: 51%; top: 53%; }
.node-deep { left: 67%; top: 19%; }
.node-upstream { right: 5%; top: 61%; }
.map-grid-label { position: absolute; color: #344851; font-size: 7px; letter-spacing: .12em; }
.label-x { left: 28px; top: 28px; }
.label-y { right: 28px; bottom: 26px; writing-mode: vertical-rl; }

.console-output {
  min-height: 104px;
  margin: 0;
  padding: 15px 18px;
  overflow: auto;
  border: 0;
  background: #07110f;
  color: #73d4ad;
  font: 10px/1.65 "Courier New",Courier,monospace;
  white-space: pre-wrap;
  text-shadow: 0 0 8px rgba(115,212,173,.24);
}

.console-actions { display: grid; grid-template-columns: repeat(3,1fr); gap: 6px; padding: 11px; }
.console-actions button { min-height: 41px; border: 3px solid #465466; background: #1c2631; color: #abb9b2; font-size: 8px; letter-spacing: .08em; cursor: pointer; }
.console-actions button span { margin-right: 8px; color: var(--cyan); }
.console-actions button:hover,
.console-actions button.is-active { border-color: var(--yellow); color: var(--yellow); background: #282b27; }
.console-actions button:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; }

.tuner-panel { min-height: 339px; }
.tuner-led { width: 13px; height: 13px; border: 3px solid #141b22; background: #40505e; box-shadow: 0 0 0 2px #303b47; }
.tuner-panel.is-locked .tuner-led { background: var(--yellow); box-shadow: 0 0 0 2px #594b2b,0 0 15px var(--yellow); }
.tuner-display { margin: 18px 18px 10px; padding: 13px 14px; border: 4px solid #293b46; background: #09201e; box-shadow: inset 0 0 18px rgba(91,230,222,.1); }
.tuner-display span { display: block; color: #5b9187; font-size: 7px; letter-spacing: .14em; }
.tuner-display strong { display: block; margin: 7px 0 4px; color: var(--cyan); font-size: clamp(25px,3vw,37px); font-weight: 400; letter-spacing: -.06em; text-shadow: 0 0 12px rgba(91,230,222,.35); }
.tuner-display small { color: #739187; font-size: 8px; }
.signal-meter { display: grid; grid-template-columns: repeat(9,1fr); align-items: end; gap: 4px; height: 38px; margin: 0 18px; padding: 5px; border: 2px solid #2d3945; background: #0d141c; }
.signal-meter i { height: 7px; background: #283642; }
.signal-meter i:nth-child(2n) { height: 12px; }
.signal-meter i:nth-child(3n) { height: 19px; }
.signal-meter i.is-on { background: var(--mint); box-shadow: 0 0 6px rgba(130,242,178,.6); }
.signal-meter i.is-peak { background: var(--yellow); box-shadow: 0 0 8px rgba(255,214,90,.7); }
.tuner-control { display: grid; grid-template-columns: 28px 1fr 28px; align-items: center; gap: 8px; margin: 12px 17px 17px; color: #6f8280; font-size: 7px; text-align: center; }
.tuner-control input { width: 100%; height: 7px; margin: 0; appearance: none; border: 2px solid #3a4857; border-radius: 0; background: #18232c; cursor: ew-resize; }
.tuner-control input::-webkit-slider-thumb { width: 16px; height: 25px; appearance: none; border: 3px solid #6c7885; border-radius: 0; background: var(--yellow); box-shadow: 3px 3px #18120b; }
.tuner-control input::-moz-range-thumb { width: 12px; height: 21px; border: 3px solid #6c7885; border-radius: 0; background: var(--yellow); box-shadow: 3px 3px #18120b; }
.tuner-control input:focus-visible { outline: 3px solid var(--yellow); outline-offset: 5px; }
.tuner-secret { margin: 0 17px 18px; padding: 12px; border: 3px solid #69572d; background: #262318; box-shadow: inset 0 0 0 2px #13140f; }
.tuner-secret[hidden] { display: none; }
.tuner-secret span { color: var(--mint); font-size: 7px; letter-spacing: .13em; }
.tuner-secret strong { display: block; margin: 5px 0 6px; color: var(--yellow); font-size: 10px; text-transform: uppercase; }
.tuner-secret p { margin: 0; color: #b5b89c; font-size: 8px; line-height: 1.55; }

.archive-panel { min-height: 318px; }
.archive-count { color: #6f8280; font-size: 7px; letter-spacing: .11em; }
.archive-tabs { display: grid; grid-template-columns: repeat(3,1fr); gap: 4px; padding: 12px 12px 0; }
.archive-tabs button { min-width: 0; padding: 9px 4px; border: 3px solid #364251; background: #17202a; color: #738581; font-size: 7px; cursor: pointer; }
.archive-tabs button:hover,
.archive-tabs button.is-active { border-color: var(--purple); color: #d2b7ed; background: #282239; }
.archive-tabs button:focus-visible { outline: 3px solid var(--yellow); outline-offset: 2px; }
.archive-record { margin: 8px 12px 15px; padding: 15px; border: 3px solid #303b47; background: #0c1219; }
.archive-record > span { color: #707f7d; font-size: 7px; letter-spacing: .1em; }
.archive-record > strong { display: block; margin: 8px 0 7px; color: var(--purple); font-size: 12px; text-transform: uppercase; }
.archive-record p { min-height: 62px; margin: 0; color: #aab6ab; font-size: 9px; line-height: 1.55; }
.record-signature { display: flex; align-items: end; gap: 3px; height: 20px; margin-top: 12px; }
.record-signature i { width: 8px; height: 6px; background: #3c5260; }
.record-signature i:nth-child(2n) { height: 13px; background: #5c4776; }
.record-signature i:nth-child(3n) { height: 18px; background: var(--purple); }

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 15px max(18px,4vw);
  border-top: 4px solid #4b3725;
  background: #0a0f16;
  color: #788b83;
  font-size: 8px;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.site-footer span:first-child { color: var(--yellow); }

@keyframes twinkle { 50% { opacity: .35; } }
@keyframes blink { 50% { opacity: .28; } }
@keyframes ring { to { transform: rotate(360deg); } }
@keyframes packet { to { stroke-dashoffset: -68; } }
@keyframes bob { 50% { transform: translateY(-3px); } }
@keyframes scan { to { top: 78px; } }
@keyframes fall { to { background-position: 0 28px; } }
@keyframes water { 50% { background-position: 20px 0; } }
@keyframes lily { 50% { transform: translateY(3px); } }
@keyframes firefly { 0% { transform: translate(0,0); } 33% { transform: translate(17px,-13px); } 66% { transform: translate(-8px,11px); } 100% { transform: translate(21px,4px); } }
@keyframes drip { to { transform: translateY(170px); opacity: 0; } }
@keyframes mine-swing { 50% { transform: rotate(-45deg); } }
@keyframes toss-bread { 0% { transform: translate(0,0); } 45% { transform: translate(80px,-90px); } 100% { transform: translate(150px,5px); opacity: 0; } }
@keyframes hotspot { 50% { transform: scale(.9); } }
@keyframes route-packet {
  0% { left: 12%; top: 68%; }
  23% { left: 35%; top: 26%; }
  48% { left: 55%; top: 59%; }
  73% { left: 71%; top: 26%; }
  100% { left: 90%; top: 68%; }
}

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

@media (max-width: 760px) {
  .world { min-height: 1080px; }
  .scene-layout { grid-template-columns: 1fr; padding: 135px 5% 88px; gap: 22px; }
  .puzzle-copy { margin-top: 0; }
  .shrine { min-height: 490px; }
  .system-status { display: none; }
  .waterfall { top: 520px; height: 390px; opacity: .6; }
  .stalactite, .root { display: none; }
  .survey-cue { right: 12px; bottom: 64px; }
  .overview-header { align-items: start; flex-direction: column; gap: 12px; }
  .overview-intro { justify-items: start; }
  .survey-progress span { justify-self: start; }
  .overview-note { left: 12px; bottom: 12px; width: min(370px,58%); }
  .operations-header { align-items: start; flex-direction: column; gap: 12px; }
  .operations-grid { grid-template-columns: 1fr; }
  .route-console { grid-row: auto; }
}

@media (max-width: 450px) {
  .world { min-height: 1120px; }
  .site-header { padding: 8px 11px; }
  .brand { font-size: 12px; }
  .scene-layout { padding-left: 4%; padding-right: 4%; }
  .shrine { min-height: 455px; }
  .arch { width: 98%; }
  .terminal { transform: translate(-50%,-50%) scale(.78); }
  .relay { transform: scale(.8); }
  .relay-1, .relay-3 { left: 0; }
  .relay-2, .relay-4 { right: 0; }
  .miner { left: 18%; transform: scale(.8); transform-origin: bottom; }
  .inventory { gap: 2px; }
  .slot { width: 34px; height: 34px; }
  .depth-status { display: none; }
  .coordinates { flex-direction: column; gap: 4px; }
  .overview { padding: 38px 12px 44px; }
  .overview-frame { overflow: visible; border-width: 4px; }
  .overview-note { position: relative; left: auto; bottom: auto; width: auto; min-height: 0; margin: 0; border-width: 3px; box-shadow: none; }
  .hotspot { width: 25px; height: 25px; border-width: 2px; }
  .operations { padding: 46px 12px 48px; }
  .operations::before { display: none; }
  .route-map { height: 295px; }
  .map-node { width: 70px; }
  .node-origin { left: 1%; }
  .node-reed { left: 25%; }
  .node-moss { left: 45%; }
  .node-deep { left: 63%; }
  .node-upstream { right: 0; }
  .console-actions { grid-template-columns: 1fr; }
  .console-actions button { min-height: 37px; }
  .site-footer { flex-direction: column; gap: 7px; }
}
