:root {
  --ink: #080a0d;
  --panel: rgba(8, 10, 13, 0.9);
  --line: #61656b;
  --acid: #e7ff1f;
  --cyan: #2bd9d5;
  --pink: #ff2f91;
  --cream: #f3ead1;
  --muted: #a7a9ad;
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
  background: #020304;
  color: var(--cream);
  font-family: "Courier New", Courier, monospace;
  overscroll-behavior: none;
}

button {
  font: inherit;
}

button:focus-visible {
  outline: 3px solid white;
  outline-offset: 3px;
}

#game-shell {
  position: relative;
  width: 100vw;
  height: 100svh;
  min-height: 480px;
  overflow: hidden;
  background: #16191e;
  border: 1px solid #363a40;
  isolation: isolate;
  touch-action: none;
}

#game {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

#game-shell::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 20;
  pointer-events: none;
  opacity: 0.18;
  background:
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.04) 0 1px, transparent 1px 4px),
    radial-gradient(circle at center, transparent 45%, rgba(0, 0, 0, 0.42) 100%);
  mix-blend-mode: overlay;
}

#hud {
  position: absolute;
  inset: 0;
  z-index: 10;
  pointer-events: none;
}

.status-panel {
  position: absolute;
  top: max(8px, env(safe-area-inset-top));
  left: max(10px, env(safe-area-inset-left));
  width: min(48vw, 440px);
  display: grid;
  gap: 6px;
  padding: 7px 9px;
  background: linear-gradient(90deg, rgba(3, 4, 6, 0.96), rgba(3, 4, 6, 0.72));
  border-left: 4px solid #81858b;
  box-shadow: 0 3px 0 rgba(0, 0, 0, 0.55);
}

.bar-row {
  display: grid;
  grid-template-columns: 68px 1fr;
  gap: 8px;
  align-items: center;
  font-family: Georgia, serif;
  font-size: 12px;
  font-weight: 700;
  text-shadow: 2px 2px #000;
}

.bar-track {
  height: 9px;
  padding: 2px;
  background: #07080a;
  border: 1px solid #85888d;
  box-shadow: 0 0 0 2px #111317;
}

.bar-fill {
  height: 100%;
  width: 100%;
  transition: width 120ms linear;
}

.bar-fill.health {
  background: #f14278;
}

.bar-fill.energy {
  background: var(--acid);
}

.bar-fill.armor {
  background: var(--cyan);
}

.armor-row {
  opacity: 0.94;
}

.world-status {
  position: absolute;
  top: max(8px, env(safe-area-inset-top));
  right: max(124px, calc(env(safe-area-inset-right) + 124px));
  display: grid;
  grid-template-columns: auto auto;
  grid-template-areas: "money money" "period clock";
  gap: 1px 10px;
  align-items: baseline;
  text-align: right;
  text-shadow: 2px 2px #000;
}

#money {
  grid-area: money;
  color: var(--acid);
  font-size: 18px;
}

#period {
  grid-area: period;
  color: #a29b91;
  font-size: 11px;
  font-weight: 700;
}

#clock {
  grid-area: clock;
  color: #aaa49b;
  font-size: 12px;
}

.hud-actions {
  position: absolute;
  z-index: 30;
  top: max(7px, env(safe-area-inset-top));
  right: max(8px, env(safe-area-inset-right));
  display: flex;
  gap: 6px;
  pointer-events: auto;
}

.square-btn {
  width: 50px;
  height: 46px;
  border: 2px solid #555b64;
  background: #11151b;
  color: white;
  font-size: 23px;
  font-weight: 900;
  box-shadow: inset 0 0 0 3px #050608, 3px 3px 0 rgba(0, 0, 0, 0.55);
  cursor: pointer;
}

.phone-btn {
  background: var(--acid);
  color: #050608;
  border-color: #0e1115;
}

.mission-card {
  position: absolute;
  top: max(82px, calc(env(safe-area-inset-top) + 82px));
  left: 0;
  width: min(470px, calc(100vw - 270px));
  min-width: 290px;
  height: 48px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 11px;
  align-items: center;
  padding: 0 14px 0 12px;
  background: rgba(8, 9, 12, 0.9);
  border-left: 5px solid var(--acid);
  border-bottom: 2px solid rgba(255, 255, 255, 0.14);
  box-shadow: 4px 5px 0 rgba(0, 0, 0, 0.35);
}

.area-banner {
  position: absolute;
  z-index: 22;
  left: max(18px, env(safe-area-inset-left));
  bottom: max(184px, calc(env(safe-area-inset-bottom) + 184px));
  max-width: min(430px, calc(100vw - 36px));
  color: #f3ead1;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(17px, 2.5vw, 25px);
  font-style: italic;
  font-weight: 900;
  letter-spacing: 0.04em;
  opacity: 0;
  text-shadow: 0 3px 0 #080a0d, 2px 0 0 #080a0d, -2px 0 0 #080a0d;
  transform: translateY(8px);
  transition: opacity 180ms ease, transform 180ms ease;
  pointer-events: none;
}

.area-banner.visible {
  opacity: 0.9;
  transform: translateY(0);
}

#mission-index {
  color: var(--acid);
  font-family: Georgia, serif;
  font-size: 13px;
  font-weight: 900;
}

#mission-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: Arial, sans-serif;
  font-size: 15px;
}

.mission-icon {
  color: var(--cyan);
  font-size: 19px;
}

#minimap {
  position: absolute;
  top: max(64px, calc(env(safe-area-inset-top) + 64px));
  right: max(11px, env(safe-area-inset-right));
  width: 224px;
  height: 132px;
  background: #171b20;
  border: 5px solid rgba(9, 11, 14, 0.94);
  box-shadow: 0 0 0 2px #5c6066, 4px 5px 0 rgba(0, 0, 0, 0.4);
  image-rendering: pixelated;
}

.wanted {
  position: absolute;
  top: max(70px, calc(env(safe-area-inset-top) + 70px));
  right: max(16px, calc(env(safe-area-inset-right) + 16px));
  width: 215px;
  color: #6f747c;
  text-align: right;
  letter-spacing: 1px;
  font-size: 22px;
  font-weight: 900;
  text-shadow: 2px 2px #000;
}

.wanted.active {
  color: var(--acid);
}

.equipment {
  position: absolute;
  top: max(202px, calc(env(safe-area-inset-top) + 202px));
  right: max(11px, env(safe-area-inset-right));
  display: flex;
  gap: 7px;
  align-items: center;
  padding: 5px 8px;
  background: rgba(7, 9, 12, 0.86);
  border-right: 3px solid var(--pink);
  color: #ddd8c9;
  font-size: 11px;
  font-weight: 900;
  text-shadow: 1px 1px #000;
}

#weapon-name {
  color: var(--pink);
}

#fuel-status {
  color: var(--cyan);
}

.objective {
  position: absolute;
  z-index: 13;
  left: 50%;
  bottom: 174px;
  width: min(94vw, 690px);
  min-height: 47px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 9px 18px;
  background: rgba(8, 10, 12, 0.9);
  border: 2px solid #93aa00;
  color: var(--acid);
  font-family: Georgia, serif;
  font-size: clamp(13px, 2vw, 17px);
  font-weight: 900;
  text-align: center;
  text-shadow: 2px 2px #000;
  box-shadow: 3px 4px 0 rgba(0, 0, 0, 0.38);
}

.objective-star {
  flex: 0 0 auto;
  font-size: 18px;
}

.hint {
  position: absolute;
  z-index: 14;
  left: 50%;
  bottom: 151px;
  transform: translateX(-50%);
  padding: 3px 9px;
  color: #f5f0df;
  background: rgba(0, 0, 0, 0.72);
  font-size: 12px;
  opacity: 0;
  transition: opacity 160ms ease;
  pointer-events: none;
}

.hint.visible {
  opacity: 1;
}

#mobile-controls {
  position: absolute;
  inset: 0;
  z-index: 15;
  pointer-events: none;
}

.joystick {
  position: absolute;
  left: max(13px, env(safe-area-inset-left));
  bottom: max(16px, env(safe-area-inset-bottom));
  width: 138px;
  height: 138px;
  border: 5px solid rgba(0, 0, 0, 0.8);
  border-radius: 50%;
  background: rgba(24, 27, 32, 0.82);
  box-shadow: inset 0 0 0 3px #45494e, 3px 4px 0 rgba(0, 0, 0, 0.42);
  pointer-events: auto;
  touch-action: none;
}

.joystick-knob {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 66px;
  height: 66px;
  transform: translate(-50%, -50%);
  border: 4px solid #050608;
  border-radius: 50%;
  background: var(--pink);
  box-shadow: inset 0 0 0 3px #ff77b8, 2px 3px 0 rgba(0, 0, 0, 0.45);
}

.arrow {
  position: absolute;
  color: #8e9298;
  font-size: 14px;
  line-height: 1;
}

.arrow.up { top: 7px; left: 59px; }
.arrow.right { right: 7px; top: 59px; }
.arrow.down { bottom: 7px; left: 59px; }
.arrow.left { left: 7px; top: 59px; }

.action-buttons {
  position: absolute;
  right: max(14px, env(safe-area-inset-right));
  bottom: max(17px, env(safe-area-inset-bottom));
  width: 206px;
  height: 152px;
  pointer-events: none;
}

.action-btn {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border: 4px solid #07090b;
  border-radius: 50%;
  color: #07090b;
  box-shadow: 0 0 0 2px #b9bdc0, 3px 4px 0 rgba(0, 0, 0, 0.42);
  cursor: pointer;
  pointer-events: auto;
  touch-action: none;
  user-select: none;
}

.action-btn span {
  font-size: 22px;
  font-weight: 900;
  line-height: 1;
}

.action-btn strong {
  font-family: Georgia, serif;
  font-size: 11px;
}

.action-btn:active,
.action-btn.pressed {
  filter: brightness(0.74);
  transform: scale(0.96);
}

.use-btn {
  top: 0;
  left: 56px;
  width: 92px;
  height: 92px;
  background: var(--acid);
}

.run-btn {
  bottom: 0;
  left: 0;
  width: 80px;
  height: 80px;
  background: var(--cyan);
}

.punch-btn {
  right: 0;
  bottom: 0;
  width: 80px;
  height: 80px;
  background: var(--pink);
}

.keyboard-help {
  position: absolute;
  z-index: 12;
  left: 50%;
  bottom: 9px;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.66);
  font-size: 12px;
  white-space: nowrap;
  text-shadow: 1px 1px #000;
  pointer-events: none;
}

.dialogue {
  position: absolute;
  z-index: 31;
  left: 50%;
  bottom: 174px;
  width: min(720px, 92vw);
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 16px;
  padding: 16px;
  background: rgba(7, 8, 10, 0.96);
  border: 2px solid var(--cyan);
  box-shadow: 7px 8px 0 rgba(0, 0, 0, 0.48);
}

.portrait {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  background: #d19b25;
  border: 4px solid #111;
  color: #111;
  font-family: Georgia, serif;
  font-size: 30px;
  font-weight: 900;
}

.dialogue strong {
  color: var(--acid);
  font-size: 15px;
}

.dialogue p {
  margin: 5px 0 8px;
  font-family: Arial, sans-serif;
  font-size: 16px;
  line-height: 1.35;
}

.dialogue small {
  color: var(--muted);
}

.phone-overlay {
  position: absolute;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(5px);
  pointer-events: auto;
}

.phone-screen {
  width: min(390px, 92vw);
  max-height: 94svh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 7px solid #12151a;
  border-radius: 28px;
  background: #e8e4d8;
  color: #111318;
  box-shadow: 0 20px 70px rgba(0, 0, 0, 0.7), 0 0 0 2px #5d626a;
}

.phone-screen header {
  min-height: 62px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 10px 14px;
  background: var(--acid);
  border-bottom: 4px solid #15181d;
}

.phone-screen header strong {
  font-size: 22px;
}

.phone-screen header button {
  justify-self: end;
  width: 38px;
  height: 38px;
  border: 2px solid #111;
  border-radius: 50%;
  background: transparent;
  color: #111;
  font-size: 26px;
  font-weight: 900;
  cursor: pointer;
}

.phone-content {
  display: grid;
  gap: 12px;
  padding: 18px;
  overflow: auto;
}

.phone-app-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.phone-app-grid button {
  min-height: 66px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border: 2px solid #1b1d21;
  background: #f7f4ea;
  color: #111318;
  font-size: 11px;
  font-weight: 900;
  cursor: pointer;
}

.phone-app-grid button span {
  font-size: 21px;
  line-height: 1;
}

.phone-app-grid button:hover,
.phone-app-grid button.active {
  background: var(--cyan);
  box-shadow: 3px 3px 0 #15181d;
}

.phone-app-view {
  min-height: 128px;
  max-height: 210px;
  overflow: auto;
  padding: 13px;
  border: 2px solid #15181d;
  background: #f7f4ea;
  font-family: Arial, sans-serif;
  font-size: 14px;
  line-height: 1.35;
}

.phone-app-view > strong {
  display: block;
  margin-bottom: 6px;
  font-family: "Courier New", monospace;
  color: #111318;
}

.phone-app-view p {
  margin: 4px 0 8px;
}

.phone-app-view button {
  width: 100%;
  min-height: 38px;
  margin-top: 7px;
  border: 2px solid #14171b;
  background: var(--acid);
  color: #0c0e11;
  font-weight: 900;
  cursor: pointer;
}

.phone-app-view .muted {
  color: #686c70;
  font-size: 12px;
}

.phone-app-view .news-item {
  padding: 8px 0;
  border-bottom: 1px dashed #919396;
}

.phone-app-view .inventory-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px dashed #a7a8a4;
}

.radio-hud {
  position: absolute;
  top: 154px;
  right: 18px;
  z-index: 14;
  max-width: min(340px, 52vw);
  padding: 8px 12px;
  border-left: 5px solid var(--cyan);
  background: rgba(8, 10, 13, .88);
  color: #fff;
  font-family: "Courier New", monospace;
  pointer-events: none;
}

.gps-hud {
  position: absolute;
  top: 154px;
  left: 18px;
  z-index: 14;
  min-width: 220px;
  max-width: min(390px, 54vw);
  padding: 8px 12px;
  border-left: 5px solid var(--acid);
  background: rgba(8, 10, 13, .9);
  color: #fff;
  font-family: "Courier New", monospace;
  pointer-events: none;
}

.gps-hud span,
.gps-hud strong,
.gps-hud small { display: block; }
.gps-hud span { color: var(--cyan); font-size: 11px; font-weight: 900; }
.gps-hud strong { margin-top: 2px; font-size: 13px; }
.gps-hud small { margin-top: 2px; color: #d2d4d5; font-size: 11px; }

@media (max-width: 620px) {
  .gps-hud { top: 148px; left: 10px; min-width: 170px; }
  .radio-hud { top: 222px; right: 10px; }
}

.radio-hud strong,
.radio-hud span { display: block; }
.radio-hud strong { color: var(--acid); font-size: 12px; }
.radio-hud span { margin-top: 3px; font-size: 11px; }

.setting-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 4px 0;
}

.setting-row button { width: auto; min-width: 92px; margin: 0; }

.phone-app {
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 11px;
  padding: 13px;
  border: 2px solid #8d9296;
  background: #f7f4ea;
}

.phone-app.selected {
  border-color: #15181d;
  box-shadow: 4px 4px 0 var(--cyan);
}

.phone-app > span {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  background: var(--pink);
  border: 2px solid #111;
  font-size: 20px;
}

.phone-app p {
  margin: 3px 0 0;
  font-family: Arial, sans-serif;
  font-size: 14px;
  line-height: 1.35;
}

.phone-primary,
.phone-secondary {
  min-height: 48px;
  border: 3px solid #111;
  font-weight: 900;
  cursor: pointer;
}

.phone-primary {
  background: var(--cyan);
}

.phone-secondary {
  background: transparent;
}

.start-screen {
  position: absolute;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  overflow: hidden;
  background:
    linear-gradient(120deg, rgba(255, 47, 145, 0.22), transparent 40%),
    linear-gradient(300deg, rgba(43, 217, 213, 0.2), transparent 48%),
    #080a0d;
  transition: opacity 380ms ease, visibility 380ms ease;
}

.start-screen.dismissed {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.start-screen::before {
  content: "";
  position: absolute;
  width: 86vmin;
  height: 86vmin;
  border: 2px solid rgba(231, 255, 31, 0.32);
  transform: rotate(12deg);
  box-shadow: 0 0 0 7vmin rgba(255, 47, 145, 0.04), 0 0 0 14vmin rgba(43, 217, 213, 0.04);
}

.start-noise {
  position: absolute;
  inset: 0;
  opacity: 0.12;
  background: repeating-linear-gradient(0deg, white 0 1px, transparent 1px 5px);
  mix-blend-mode: overlay;
}

.start-content {
  position: relative;
  z-index: 1;
  width: min(590px, 88vw);
  text-align: center;
}

.eyebrow {
  display: inline-block;
  padding: 6px 10px;
  background: var(--acid);
  color: #090b0e;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.start-content h1 {
  margin: 16px 0 8px;
  font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
  font-size: clamp(64px, 14vw, 136px);
  line-height: 0.72;
  letter-spacing: -0.035em;
  text-align: left;
  text-shadow: 8px 8px 0 #000;
  transform: skewY(-3deg);
}

.start-content h1 em {
  color: var(--pink);
  font-style: normal;
  -webkit-text-stroke: 2px var(--cream);
}

.start-content p {
  margin: 26px 0 20px;
  color: var(--cyan);
  font-weight: 900;
}

#start-btn {
  width: min(300px, 80vw);
  min-height: 64px;
  border: 4px solid #07080a;
  background: var(--acid);
  color: #07080a;
  font-size: 21px;
  font-weight: 900;
  box-shadow: 7px 7px 0 var(--pink);
  cursor: pointer;
}

.start-content small {
  display: block;
  margin-top: 20px;
  color: #a6a9ae;
}

.mission-complete {
  position: absolute;
  z-index: 45;
  top: 42%;
  left: 50%;
  width: min(720px, 96vw);
  transform: translate(-50%, -50%) skewY(-2deg);
  display: grid;
  gap: 7px;
  padding: 24px 18px;
  background: rgba(7, 9, 12, 0.94);
  border-top: 6px solid var(--acid);
  border-bottom: 6px solid var(--acid);
  text-align: center;
  box-shadow: 0 12px 0 rgba(0, 0, 0, 0.46);
  animation: complete-in 520ms cubic-bezier(0.2, 0.85, 0.25, 1.2);
}

.mission-complete span {
  color: var(--cyan);
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.15em;
}

.mission-complete strong {
  color: var(--cream);
  font-family: Impact, sans-serif;
  font-size: clamp(30px, 7vw, 62px);
  letter-spacing: 0.03em;
}

.mission-complete small {
  color: var(--acid);
  font-size: 22px;
  font-weight: 900;
}

.action-panel {
  position: absolute;
  z-index: 42;
  left: 50%;
  top: 50%;
  width: min(520px, 92vw);
  max-height: min(620px, 82vh);
  overflow: auto;
  transform: translate(-50%, -50%);
  padding: 18px;
  background: rgba(9, 11, 14, 0.97);
  border: 3px solid var(--acid);
  box-shadow: 9px 10px 0 rgba(0, 0, 0, 0.55);
  pointer-events: auto;
}

.action-panel header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 12px;
  border-bottom: 2px solid #45494f;
}

.action-panel h2 {
  margin: 2px 0 0;
  color: var(--cream);
  font-family: Impact, sans-serif;
  font-size: 30px;
  letter-spacing: 0.04em;
}

#panel-kicker {
  color: var(--cyan);
  font-size: 11px;
  font-weight: 900;
}

#panel-close {
  width: 40px;
  height: 40px;
  border: 2px solid #777c82;
  background: #171a20;
  color: white;
  font-size: 24px;
  cursor: pointer;
}

#panel-copy {
  font-family: Arial, sans-serif;
  font-size: 16px;
  line-height: 1.4;
}

.panel-actions {
  display: grid;
  gap: 9px;
}

.panel-actions button {
  min-height: 50px;
  padding: 9px 13px;
  border: 2px solid #777c82;
  background: #171a20;
  color: #f5efdf;
  text-align: left;
  font-weight: 900;
  cursor: pointer;
}

.panel-actions button:hover,
.panel-actions button:focus-visible {
  border-color: var(--acid);
  color: var(--acid);
}

.panel-actions button span {
  float: right;
  color: var(--cyan);
}

.panel-actions button.danger {
  border-color: var(--pink);
}

.panel-actions button:disabled {
  opacity: 0.42;
  cursor: not-allowed;
}

.separos {
  position: absolute;
  inset: 0;
  z-index: 55;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px;
  background: #11151a;
  color: #eee8d8;
  text-align: center;
}

.separos > span {
  color: var(--pink);
  font-size: 15px;
  font-weight: 900;
  letter-spacing: 0.2em;
}

.separos > strong {
  font-family: Impact, sans-serif;
  font-size: clamp(34px, 8vw, 72px);
  font-weight: 400;
}

.separos p {
  margin: 0;
  font-family: Arial, sans-serif;
}

.separos b {
  display: grid;
  place-items: center;
  width: 94px;
  height: 94px;
  margin-top: 12px;
  border: 5px solid var(--acid);
  border-radius: 50%;
  color: var(--acid);
  font-size: 42px;
}

.cell-bars {
  position: absolute;
  inset: 0;
  opacity: 0.28;
  background: repeating-linear-gradient(90deg, transparent 0 52px, #8e969e 52px 68px);
  pointer-events: none;
}

.news-flash {
  position: absolute;
  z-index: 26;
  left: 50%;
  top: 138px;
  width: min(680px, 94vw);
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: auto 1fr;
  background: rgba(8, 10, 13, 0.95);
  border: 2px solid #e44848;
  box-shadow: 5px 5px 0 rgba(0, 0, 0, 0.4);
}

.news-flash strong {
  padding: 9px 11px;
  background: #d92c3e;
  color: white;
  font-size: 12px;
}

.news-flash span {
  padding: 9px 11px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: Arial, sans-serif;
  font-size: 13px;
  font-weight: 700;
}

.hidden {
  display: none !important;
}

@keyframes complete-in {
  from { opacity: 0; transform: translate(-50%, -34%) skewY(-2deg) scale(0.86); }
  to { opacity: 1; transform: translate(-50%, -50%) skewY(-2deg) scale(1); }
}

@media (pointer: fine) and (min-width: 900px) {
  .joystick,
  .action-buttons {
    opacity: 0.72;
    transition: opacity 160ms ease;
  }

  .joystick:hover,
  .action-buttons:hover {
    opacity: 1;
  }

  .objective {
    bottom: 72px;
  }

  .hint {
    bottom: 49px;
  }

  .dialogue {
    bottom: 75px;
  }
}

@media (max-width: 720px) {
  .status-panel {
    width: calc(100vw - 208px);
    min-width: 205px;
  }

  .world-status {
    top: 58px;
    right: 13px;
  }

  .mission-card {
    top: max(82px, calc(env(safe-area-inset-top) + 82px));
    width: calc(100vw - 172px);
    min-width: 0;
    padding-right: 8px;
  }

  #minimap {
    top: max(134px, calc(env(safe-area-inset-top) + 134px));
    width: 154px;
    height: 94px;
  }

  .wanted {
    top: max(137px, calc(env(safe-area-inset-top) + 137px));
    width: 148px;
    font-size: 17px;
  }

  .equipment {
    top: max(231px, calc(env(safe-area-inset-top) + 231px));
  }

  .objective {
    bottom: 171px;
  }

  .keyboard-help {
    display: none;
  }
}

@media (max-width: 470px), (max-height: 620px) {
  .bar-row {
    grid-template-columns: 52px 1fr;
    font-size: 10px;
  }

  .square-btn {
    width: 43px;
    height: 42px;
  }

  .world-status {
    right: 9px;
  }

  .joystick {
    width: 116px;
    height: 116px;
  }

  .joystick-knob {
    width: 58px;
    height: 58px;
  }

  .arrow.up,
  .arrow.down { left: 49px; }
  .arrow.right,
  .arrow.left { top: 49px; }

  .action-buttons {
    width: 180px;
    height: 130px;
  }

  .use-btn {
    left: 50px;
    width: 78px;
    height: 78px;
  }

  .run-btn,
  .punch-btn {
    width: 68px;
    height: 68px;
  }

  .action-btn span {
    font-size: 18px;
  }

  .objective {
    bottom: 143px;
    min-height: 41px;
  }

  .hint {
    bottom: 123px;
  }

  .dialogue {
    bottom: 143px;
  }
}

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