﻿:root {
      --neon-pink: #ff2f92;
      --neon-cyan: #2fe6ff;
      --neon-yellow: #ffce33;
      --panel-bg: rgba(10, 10, 18, 0.72);
      --danger: #ff3b3b;
    }

    html,
    body {
      margin: 0;
      padding: 0;
      overflow: hidden;
      background: #000;
      font-family: 'Segoe UI', Arial, sans-serif;
      width: 100vw;
      height: 100vh;
      height: 100dvh;
    }

    #game-container,
    #hud,
    #start-overlay,
    #pause-overlay,
    #busted-overlay,
    #orientation-overlay {
      position: fixed;
      inset: 0;
      width: 100vw;
      height: 100vh;
      height: 100dvh;
      box-sizing: border-box;
    }

    #game-container {
      z-index: 0;
    }

    canvas {
      display: block;
      touch-action: none;
    }

    /* ---------- HUD ---------- */
    #hud {
      position: fixed;
      inset: 0;
      pointer-events: none;
      color: #fff;
      text-shadow: 0 1px 3px rgba(0, 0, 0, 0.9);
    }

    .hud-panel {
      background: var(--panel-bg);
      border: 1px solid rgba(255, 255, 255, 0.08);
      border-radius: 10px;
      backdrop-filter: blur(4px);
    }

    #top-left {
      position: fixed;
      top: 16px;
      left: 16px;
      padding: 10px 14px;
      display: flex;
      flex-direction: column;
      gap: 6px;
      min-width: 190px;
    }

    .bar-row {
      display: flex;
      align-items: center;
      gap: 8px;
    }

    .bar-label {
      width: 16px;
      text-align: center;
      font-size: 13px;
    }

    .bar-bg {
      flex: 1;
      height: 10px;
      background: rgba(255, 255, 255, 0.12);
      border-radius: 6px;
      overflow: hidden;
    }

    .bar-fill {
      height: 100%;
      border-radius: 6px;
      transition: width .15s ease;
    }

    #health-fill {
      background: linear-gradient(90deg, #ff3b3b, #ff7a3b);
    }

    #armor-fill {
      background: linear-gradient(90deg, var(--neon-cyan), #3b7bff);
    }

    #top-right {
      position: fixed;
      top: 16px;
      right: 16px;
      padding: 10px 16px;
      text-align: right;
    }

    #money {
      font-size: 22px;
      font-weight: 700;
      color: var(--neon-yellow);
      letter-spacing: 0.5px;
    }

    #stars {
      margin-top: 4px;
      font-size: 20px;
      letter-spacing: 3px;
    }

    #game-time {
      margin-top: 6px;
      color: rgba(255, 255, 255, 0.72);
      font-size: 11px;
      letter-spacing: 1.5px;
    }

    .star-on {
      color: var(--neon-yellow);
      text-shadow: 0 0 6px var(--neon-yellow);
    }

    .star-off {
      color: rgba(255, 255, 255, 0.18);
    }

    #mode-badge {
      position: fixed;
      top: 16px;
      left: 50%;
      transform: translateX(-50%);
      padding: 6px 18px;
      font-size: 13px;
      font-weight: 600;
      letter-spacing: 1px;
      border-radius: 20px;
    }

    #pause-button {
      display: none;
      position: fixed;
      top: 106px;
      right: 18px;
      padding: 10px 16px;
      border: 1px solid rgba(255, 255, 255, 0.7);
      border-radius: 999px;
      background: rgba(7, 7, 7, 0.7);
      color: #fff;
      font: 700 11px Consolas, 'Courier New', monospace;
      letter-spacing: 1.5px;
      cursor: pointer;
      pointer-events: auto;
      z-index: 22;
      box-shadow: 0 0 18px rgba(255,255,255,0.08);
    }

    #pause-button:hover,
    #pause-button:focus-visible {
      background: rgba(255,255,255,0.12);
      outline: none;
    }

    #mission-text {
      position: fixed;
      top: 60px;
      left: 50%;
      transform: translateX(-50%);
      font-size: 14px;
      color: var(--neon-cyan);
      font-weight: 600;
      text-align: center;
      max-width: 80vw;
    }

    #crosshair {
      position: fixed;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%);
      width: 32px;
      height: 32px;
      pointer-events: none;
      color: rgba(255, 255, 255, 0.9);
      transition: transform .12s ease;
    }

    #crosshair.aiming {
      transform: translate(-50%, -50%) scale(1.2);
      color: var(--neon-pink);
    }

    #crosshair .ch-line {
      position: absolute;
      background: currentColor;
    }

    #crosshair .ch-dot {
      position: absolute;
      width: 4px;
      height: 4px;
      left: 14px;
      top: 14px;
      background: currentColor;
      border-radius: 50%;
    }

    #crosshair .ch-corner {
      position: absolute;
      width: 9px;
      height: 9px;
    }

    #crosshair .ch-circle {
      position: absolute;
      left: 1px;
      top: 1px;
      width: 30px;
      height: 30px;
      border: 2px solid currentColor;
      border-radius: 50%;
    }

    #crosshair.aiming .ch-circle {
      box-shadow: 0 0 10px rgba(255, 47, 146, 0.7);
    }

    #lock-hint {
      position: fixed;
      top: 50%;
      left: 50%;
      transform: translate(-50%, 40px);
      font-size: 14px;
      font-weight: 600;
      background: rgba(0, 0, 0, 0.6);
      padding: 8px 16px;
      border-radius: 20px;
      white-space: nowrap;
    }

    #scope-vignette {
      position: fixed;
      inset: 0;
      pointer-events: none;
      opacity: 0;
      transition: opacity .15s ease;
      box-shadow: inset 0 0 10vw 4vw rgba(0, 0, 0, 0.65);
      z-index: 5;
    }

    #mobile-controls {
      display: none;
      touch-action: none;
      background: transparent;
    }

    #orientation-overlay {
      display: none;
    }

    #scope-vignette.active {
      opacity: 1;
    }

    #minimap-wrap {
      position: fixed;
      bottom: 16px;
      left: 16px;
      width: 170px;
      height: 170px;
      border-radius: 50%;
      border: 2px solid rgba(255, 255, 255, 0.35);
      overflow: hidden;
      box-shadow: 0 0 18px rgba(0, 0, 0, 0.6);
    }

    #minimap {
      width: 100%;
      height: 100%;
      background: #0b3d1a;
    }

    #speed-wrap {
      position: fixed;
      bottom: 16px;
      right: 16px;
      padding: 10px 14px 12px;
      text-align: center;
      min-width: 118px;
      background: rgba(5, 10, 18, 0.72);
      border: 1px solid rgba(255, 255, 255, 0.24);
      box-shadow: inset 0 0 18px rgba(0, 0, 0, 0.35);
    }

    .speed-gauge {
      width: 100%;
      height: 7px;
      margin-bottom: 8px;
      border: 1px solid rgba(255, 255, 255, 0.2);
      background: rgba(255, 255, 255, 0.08);
      overflow: hidden;
    }

    #speed-gauge-fill {
      width: 0%;
      height: 100%;
      background: linear-gradient(90deg, #53f2c7 0%, #f6d365 50%, #ff5f6d 100%);
      box-shadow: 0 0 12px rgba(83, 242, 199, 0.7);
      transition: width 0.12s ease-out;
    }

    #weapon-wrap {
      position: fixed;
      bottom: 60px;
      right: 16px;
      padding: 6px 16px;
      text-align: center;
      font-size: 13px;
      font-weight: 700;
      color: var(--neon-cyan);
    }

    #integrity-wrap {
      position: fixed;
      bottom: 104px;
      right: 16px;
      padding: 8px 16px;
      min-width: 150px;
      font-size: 12px;
    }

    #integrity-label {
      margin-bottom: 4px;
      display: flex;
      justify-content: space-between;
      gap: 10px;
    }

    #integrity-pct {
      font-weight: 700;
    }

    #debug-panel {
      position: fixed;
      right: 16px;
      bottom: 176px;
      min-width: 178px;
      padding: 9px 11px;
      border: 1px solid rgba(255, 255, 255, 0.2);
      background: rgba(0, 0, 0, 0.62);
      color: rgba(255, 255, 255, 0.72);
      font: 10px/1.55 Consolas, 'Courier New', monospace;
      letter-spacing: 0.4px;
      pointer-events: none;
      text-align: left;
    }

    .debug-title {
      margin-bottom: 3px;
      color: #fff;
      font-weight: 700;
      letter-spacing: 1px;
    }

    #debug-readout {
      white-space: pre;
    }

    #speed-val {
      font-size: 26px;
      font-weight: 800;
    }

    #speed-unit {
      font-size: 11px;
      opacity: 0.7;
    }

    #toast {
      position: fixed;
      bottom: 130px;
      left: 50%;
      transform: translateX(-50%);
      font-size: 15px;
      font-weight: 600;
      color: #fff;
      opacity: 0;
      transition: opacity .3s ease;
      text-align: center;
    }

    #controls-hint {
      position: fixed;
      bottom: 16px;
      left: 50%;
      transform: translateX(-50%);
      font-size: 12px;
      opacity: 0.65;
      text-align: center;
      line-height: 1.5;
    }

    #command-console {
      position: fixed;
      left: 50%;
      bottom: 48px;
      transform: translateX(-50%);
      width: min(760px, calc(100vw - 32px));
      padding: 10px 14px 12px;
      background: rgba(8, 10, 18, 0.78);
      border: 1px solid rgba(255, 255, 255, 0.12);
      box-shadow: 0 0 24px rgba(0, 0, 0, 0.45), inset 0 0 14px rgba(47, 230, 255, 0.08);
      pointer-events: auto;
      z-index: 18;
    }

    .console-label {
      color: rgba(255, 255, 255, 0.72);
      font-size: 10px;
      font-weight: 700;
      letter-spacing: 2px;
      text-transform: uppercase;
      margin-bottom: 8px;
    }

    .console-input-row {
      display: flex;
      align-items: center;
      gap: 10px;
      min-height: 30px;
      padding: 0 2px;
    }

    .console-prompt {
      color: var(--neon-cyan);
      font: 700 16px Consolas, 'Courier New', monospace;
      text-shadow: 0 0 12px rgba(47, 230, 255, 0.9);
    }

    #command-input {
      flex: 1;
      width: 100%;
      border: none;
      background: transparent;
      color: #f5f7ff;
      font: 600 14px Consolas, 'Courier New', monospace;
      letter-spacing: 0.4px;
      outline: none;
    }

    #command-input::placeholder {
      color: rgba(255, 255, 255, 0.4);
    }

    #command-input:focus {
      box-shadow: none;
    }

    .version-label {
      position: fixed;
      right: 16px;
      bottom: 16px;
      z-index: 2;
      color: rgba(255, 255, 255, 0.7);
      font: 10px/1.2 Consolas, 'Courier New', monospace;
      letter-spacing: 0.8px;
      text-transform: uppercase;
      text-shadow: 1px 1px 0 #000;
      pointer-events: none;
    }

    /* ---------- Start overlay ---------- */
    #start-overlay {
      overflow: auto;
      background: #000;
      display: flex;
      align-items: center;
      justify-content: center;
      z-index: 50;
      color: #f4f5f0;
      padding: calc(env(safe-area-inset-top, 0px) + 34px) calc(env(safe-area-inset-right, 0px) + 48px) calc(env(safe-area-inset-bottom, 0px) + 24px) calc(env(safe-area-inset-left, 0px) + 48px);
      isolation: isolate;
    }

    #start-overlay::before,
    #start-overlay::after {
      content: '';
      position: absolute;
      pointer-events: none;
      z-index: -1;
    }

    #start-overlay::before {
      inset: 0;
      background: linear-gradient(115deg, rgba(255, 255, 255, 0.08), transparent 34%),
        radial-gradient(circle at 84% 18%, rgba(255, 255, 255, 0.1), transparent 28%),
        linear-gradient(180deg, transparent 65%, rgba(0, 0, 0, 0.95));
    }

    #start-overlay::after {
      width: 42vw;
      height: 42vw;
      right: -15vw;
      bottom: -21vw;
      border: 1px solid rgba(255, 255, 255, 0.2);
      border-radius: 50%;
      box-shadow: 0 0 0 34px rgba(255, 255, 255, 0.035), 0 0 0 68px rgba(255, 255, 255, 0.025);
    }

    .start-grid,
    .start-noise {
      position: absolute;
      inset: 0;
      pointer-events: none;
      z-index: -1;
    }

    .start-grid {
      opacity: 0.34;
      background-image: linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
      background-size: 64px 64px;
      mask-image: linear-gradient(90deg, #000, transparent 82%);
    }

    .start-noise {
      opacity: 0.04;
      background-image: url('../images/starcity.png');
      background-size: 480px auto;
      background-position: right 10% bottom 12%;
      background-repeat: no-repeat;
      filter: blur(2px);
    }

    .start-shell {
      width: min(1180px, 100%);
      min-height: min(720px, calc(100vh - 68px));
      display: flex;
      flex-direction: column;
      justify-content: space-between;
      border-left: 1px solid rgba(255, 255, 255, 0.13);
      border-right: 1px solid rgba(255, 255, 255, 0.13);
      padding: 0 38px;
      box-sizing: border-box;
    }

    .start-header,
    .start-footer {
      display: flex;
      align-items: center;
      justify-content: space-between;
      color: rgba(244, 245, 240, 0.54);
      font-size: 10px;
      letter-spacing: 2px;
      text-transform: uppercase;
    }

    .start-header {
      height: 32px;
      border-bottom: 1px solid rgba(255, 255, 255, 0.13);
    }

    .start-kicker,
    .start-signal,
    .start-footer span {
      white-space: nowrap;
    }

    .status-dot {
      display: inline-block;
      width: 6px;
      height: 6px;
      margin-right: 8px;
      border-radius: 50%;
      background: #fff;
      box-shadow: 0 0 10px rgba(255, 255, 255, 0.9);
    }

    .start-signal span {
      color: #fff;
      margin-left: 8px;
    }

    .start-hero {
      display: grid;
      grid-template-columns: minmax(300px, 0.9fr) minmax(340px, 1.1fr);
      gap: clamp(40px, 9vw, 150px);
      align-items: end;
      padding: clamp(52px, 10vh, 100px) 0 48px;
    }

    .brand-logo {
      display: block;
      width: min(430px, 100%);
      height: auto;
      object-fit: contain;
      object-position: left center;
      margin-bottom: 18px;
    }

    .brand-caption,
    .start-eyebrow {
      color: #fff;
      font-size: 11px;
      font-weight: 700;
      letter-spacing: 3px;
      text-transform: uppercase;
    }

    .start-eyebrow {
      margin-bottom: 16px;
      color: #fff;
    }

    #start-overlay h1 {
      max-width: 540px;
      margin: 0 0 14px;
      color: #f4f5f0;
      font-size: clamp(38px, 6vw, 78px);
      font-weight: 800;
      letter-spacing: -1px;
      line-height: 0.95;
    }

    #start-overlay .sub {
      max-width: 430px;
      margin: 0 0 28px;
      color: rgba(244, 245, 240, 0.64);
      font-size: 15px;
      line-height: 1.55;
    }

    #start-btn {
      display: inline-flex;
      align-items: center;
      gap: 12px;
      background: #fff;
      border: 1px solid #fff;
      color: #000;
      font-size: 14px;
      font-weight: 800;
      padding: 15px 22px;
      border-radius: 2px;
      cursor: pointer;
      letter-spacing: 1.5px;
      box-shadow: 7px 7px 0 rgba(255, 255, 255, 0.25);
      transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
    }

    #start-btn span {
      font-size: 11px;
    }

    #start-btn:hover {
      background: #d8d8d8;
      transform: translate(3px, 3px);
      box-shadow: 4px 4px 0 rgba(255, 255, 255, 0.25);
    }

    #loading-note {
      max-width: 480px;
      margin-top: 20px;
      color: rgba(244, 245, 240, 0.38);
      font-size: 10px;
      line-height: 1.5;
    }

    #desktop-only-note {
      display: none;
      margin-top: 16px;
      color: #fff;
      font-size: 10px;
      font-weight: 800;
      letter-spacing: 1.5px;
    }

    #start-btn:disabled {
      cursor: not-allowed;
      opacity: 0.4;
      box-shadow: none;
      transform: none;
    }

    .start-briefing {
      border-top: 1px solid rgba(255, 255, 255, 0.16);
      border-bottom: 1px solid rgba(255, 255, 255, 0.16);
      padding: 18px 0 20px;
    }

    .briefing-heading {
      display: flex;
      gap: 14px;
      align-items: center;
      margin-bottom: 18px;
    }

    .briefing-heading > span {
      color: #fff;
      font-size: 12px;
      font-weight: 800;
    }

    .briefing-heading strong,
    .briefing-heading small {
      display: block;
    }

    .briefing-heading strong {
      font-size: 12px;
      letter-spacing: 2px;
    }

    .briefing-heading small {
      margin-top: 3px;
      color: rgba(244, 245, 240, 0.4);
      font-size: 9px;
      letter-spacing: 1.5px;
    }

    #controls-grid {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 14px 28px;
      text-align: left;
      font-size: 11px;
    }

    #controls-grid div {
      display: grid;
      grid-template-columns: 58px 1fr;
      grid-template-rows: auto auto;
      column-gap: 10px;
    }

    #controls-grid div span {
      grid-row: 1 / 3;
      align-self: center;
      color: #fff;
      font-size: 10px;
      font-weight: 800;
      letter-spacing: 1px;
    }

    #controls-grid b {
      font-size: 11px;
    }

    #controls-grid em {
      color: rgba(244, 245, 240, 0.42);
      font-size: 10px;
      font-style: normal;
      line-height: 1.4;
    }

    .start-footer {
      height: 42px;
      font-size: 9px;
      letter-spacing: 1.5px;
    }

    @media (max-width: 900px) and (pointer: coarse) {
      #start-overlay {
        align-items: flex-start;
        padding: 22px 18px;
      }

      .start-shell {
        min-height: calc(100vh - 44px);
        padding: 0 18px;
      }

      .start-header {
        height: 40px;
      }

      .start-signal,
      .start-footer span:last-child {
        display: none;
      }

      .start-kicker {
        font-size: 9px;
        letter-spacing: 1.4px;
      }

      .start-hero {
        display: block;
        padding: 48px 0 38px;
      }

      .brand-logo {
        width: min(330px, 88vw);
        margin-bottom: 14px;
      }

      .start-copy {
        margin-top: 48px;
      }

      #start-overlay h1 {
        font-size: clamp(42px, 14vw, 68px);
      }

      #controls-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px 12px;
      }

      #controls-grid div {
        grid-template-columns: 48px 1fr;
      }

      .start-footer {
        height: 52px;
        font-size: 8px;
      }
    }

    @media (prefers-reduced-motion: reduce) {
      #start-btn {
        transition: none;
      }
    }

    @media (max-width: 900px) and (pointer: coarse) {
      #desktop-only-note {
        display: block;
      }

      #start-btn:disabled::after {
        content: ' / DESKTOP';
      }
    }

    /* ---------- Minimal pregame menu ---------- */
    #start-overlay {
      align-items: center;
      background: #000;
      padding: 24px;
    }

    #start-overlay::before,
    #start-overlay::after,
    .start-grid,
    .start-noise {
      display: none;
    }

    .start-shell {
      width: min(620px, 100%);
      min-height: 0;
      border: 0;
      padding: 0;
    }

    .start-hero {
      display: block;
      padding: 0;
      text-align: center;
    }

    .brand-logo {
      width: min(600px, 86vw);
      margin: 0 auto 18px;
    }

    .brand-caption,
    .start-eyebrow {
      color: #fff;
      font-size: 10px;
      letter-spacing: 2px;
    }

    .start-copy {
      margin-top: 46px;
    }

    .start-eyebrow {
      margin-bottom: 14px;
    }

    #start-overlay h1 {
      max-width: none;
      margin-bottom: 12px;
      font-size: clamp(36px, 7vw, 64px);
      letter-spacing: 0;
    }

    #start-overlay .sub {
      max-width: 380px;
      margin: 0 auto 26px;
      color: #aaa;
      font-size: 13px;
    }

    #start-btn {
      box-shadow: none;
      transition: background .15s ease, color .15s ease;
    }

    #start-btn:hover {
      transform: none;
      box-shadow: none;
    }

    #loading-note {
      max-width: 420px;
      margin: 18px auto 0;
      color: #666;
    }

    #desktop-only-note {
      color: #fff;
    }

    /* ---------- Monochrome game HUD ---------- */
    #hud {
      font-family: Consolas, 'Courier New', monospace;
      text-shadow: 1px 1px 0 #000;
    }

    #hud .hud-panel {
      background: rgba(0, 0, 0, 0.76);
      border: 1px solid rgba(255, 255, 255, 0.62);
      border-radius: 0;
      backdrop-filter: none;
      box-shadow: 3px 3px 0 rgba(0, 0, 0, 0.6);
    }

    #top-left,
    #top-right {
      padding: 9px 12px;
    }

    #top-left {
      min-width: 194px;
    }

    #car-status {
      display: none;
      margin-top: 8px;
      padding-top: 8px;
      border-top: 1px solid #555;
    }

    .car-status-label,
    .car-max-speed {
      color: #aaa;
      font-size: 10px;
      letter-spacing: 1px;
    }

    .car-status-label {
      display: flex;
      justify-content: space-between;
      margin-bottom: 4px;
    }

    #car-health-pct,
    .car-max-speed strong {
      color: #fff;
    }

    #car-health-fill {
      background: #fff;
    }

    .car-max-speed {
      margin-top: 7px;
    }

    .bar-bg {
      height: 8px;
      background: #242424;
      border: 1px solid #666;
      border-radius: 0;
    }

    .bar-fill {
      border-radius: 0;
      transition: width .15s steps(4);
    }

    #health-fill,
    #armor-fill {
      background: #fff;
    }

    #armor-fill {
      background: #888;
    }

    #money,
    #weapon-wrap,
    #mission-text,
    .star-on,
    #integrity-pct {
      color: #fff;
    }

    #money {
      font-size: 19px;
      letter-spacing: 1px;
    }

    #stars {
      font-size: 17px;
      letter-spacing: 2px;
    }

    .star-off {
      color: #444;
    }

    #mode-badge {
      padding: 6px 14px;
      border-radius: 0;
      font-size: 11px;
      letter-spacing: 2px;
    }

    #mission-text {
      font-size: 11px;
      letter-spacing: 0.6px;
      text-transform: uppercase;
    }

    #lock-hint,
    #controls-hint,
    #toast {
      font-family: Consolas, 'Courier New', monospace;
      color: #fff;
      letter-spacing: 0.5px;
    }

    #lock-hint {
      display: none !important;
      padding: 7px 12px;
      border-radius: 0;
      border: 1px solid rgba(255, 255, 255, 0.55);
      background: rgba(0, 0, 0, 0.82);
      font-size: 11px;
      text-transform: uppercase;
    }

    #minimap-wrap {
      border-radius: 0;
      border: 2px solid rgba(255, 255, 255, 0.75);
      box-shadow: 3px 3px 0 rgba(0, 0, 0, 0.7);
    }

    #minimap {
      background: #080808;
      filter: grayscale(1) contrast(1.15);
    }

    #speed-wrap {
      bottom: 54px;
      padding: 8px 12px 10px;
      min-width: 108px;
    }

    #speed-val {
      font-size: 24px;
      letter-spacing: 1px;
      color: #f7f7f7;
    }

    #speed-unit {
      color: #aaa;
      letter-spacing: 1px;
    }

    #weapon-wrap {
      position: static;
      margin-top: 8px;
      padding: 6px 10px;
      font-size: 11px;
      letter-spacing: 1px;
      text-transform: uppercase;
      text-align: left;
      box-shadow: none;
    }

    #ammo-label {
      display: block;
      margin-top: 3px;
      color: #aaa;
      font-size: 10px;
      letter-spacing: 1px;
    }

    #controls-hint.is-hidden {
      opacity: 0;
      visibility: hidden;
      transition: opacity .6s ease, visibility .6s ease;
    }

    #integrity-wrap {
      font-size: 10px;
      letter-spacing: 0.5px;
    }

    #integrity-fill {
      background: #fff !important;
    }

    #controls-hint {
      opacity: 0.75;
      font-size: 10px;
      text-transform: uppercase;
    }

    #debug-panel {
      min-width: 218px;
      padding: 10px 12px;
      border: 1px solid #fff;
      background: rgba(0, 0, 0, 0.86);
      color: #aaa;
      font-size: 10px;
      line-height: 1.6;
      letter-spacing: 0.6px;
      box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.7);
    }

    .debug-title {
      padding-bottom: 4px;
      margin-bottom: 5px;
      border-bottom: 1px solid #555;
      color: #fff;
      font-size: 10px;
      letter-spacing: 2px;
    }

    #crosshair {
      color: #fff;
    }

    #crosshair.aiming {
      color: #fff;
    }

    #crosshair.aiming .ch-circle {
      box-shadow: 0 0 0 1px #000;
    }

    #pause-overlay {
      position: fixed;
      inset: 0;
      z-index: 80;
      display: none;
      align-items: center;
      justify-content: center;
      background: rgba(0, 0, 0, 0.88);
      color: #fff;
      font-family: Consolas, 'Courier New', monospace;
      text-align: center;
      cursor: default;
    }

    #pause-overlay.visible {
      display: flex;
    }

    .pause-panel {
      width: min(420px, calc(100vw - 28px));
      max-height: calc(100vh - 24px);
      overflow: auto;
      padding: 24px 18px 18px;
      border: 1px solid #fff;
      background: #050505;
      box-shadow: 7px 7px 0 rgba(255, 255, 255, 0.16);
      box-sizing: border-box;
    }

    .pause-kicker {
      color: #999;
      font-size: 10px;
      letter-spacing: 2px;
      line-height: 1.4;
    }

    .pause-panel h2 {
      margin: 18px 0 8px;
      font-size: clamp(28px, 8vw, 58px);
      letter-spacing: 5px;
      line-height: 1.05;
    }

    .pause-panel p {
      margin: 0 0 20px;
      color: #aaa;
      font-size: 12px;
      line-height: 1.5;
    }

    .pause-sensitivity {
      display: none;
      margin: 0 0 18px;
      text-align: left;
      padding: 12px 12px 10px;
      border: 1px solid rgba(255,255,255,0.18);
      background: rgba(255,255,255,0.02);
    }

    .pause-sensitivity label {
      display: block;
      margin-bottom: 8px;
      font-size: 9px;
      letter-spacing: 2px;
      color: #d7d7d7;
      line-height: 1.4;
    }

    .sensitivity-row {
      display: flex;
      align-items: center;
      gap: 10px;
    }

    .sensitivity-row input[type="range"] {
      flex: 1;
      accent-color: #fff;
      cursor: pointer;
    }

    #touch-sensitivity-value {
      min-width: 52px;
      text-align: right;
      font-size: 12px;
      font-weight: 700;
      color: #fff;
    }

    .pause-actions {
      display: grid;
      gap: 10px;
    }

    .pause-actions button {
      min-height: 42px;
      width: 100%;
      border: 1px solid #fff;
      border-radius: 0;
      background: #fff;
      color: #000;
      cursor: pointer;
      font: 700 12px Consolas, 'Courier New', monospace;
      letter-spacing: 1.5px;
      padding: 10px 12px;
      box-sizing: border-box;
    }

    .pause-actions button + button {
      background: transparent;
      color: #fff;
    }

    .pause-actions button:hover,
    .pause-actions button:focus-visible {
      background: #bbb;
      color: #000;
      outline: none;
    }

    .pause-hint {
      margin-top: 18px;
      color: #666;
      font-size: 10px;
      letter-spacing: 0.8px;
      line-height: 1.5;
    }

    @media (max-width: 900px) and (pointer: coarse) {
      html, body, #game-container, #hud {
        touch-action: none;
      }

      #start-overlay {
        padding: 20px;
      }

      .start-shell {
        display: block;
        width: min(520px, 100%);
      }

      .start-hero {
        padding: 0;
      }

      .brand-logo {
        width: min(360px, 82vw);
      }

      .start-copy {
        margin-top: 30px;
      }

      #start-btn {
        min-height: 52px;
        padding: 14px 18px;
        font-size: 12px;
      }

      #desktop-only-note {
        display: block;
        font-size: 9px;
      }

      #loading-note {
        font-size: 9px;
      }

      #debug-panel {
        display: none;
      }

      #lock-hint, #controls-hint {
        display: none !important;
      }

      #top-left {
        top: 10px;
        left: 10px;
        min-width: 142px;
        padding: 7px 9px;
      }

      #top-right {
        top: 10px;
        right: 10px;
        padding: 7px 9px;
      }

      #money {
        font-size: 16px;
      }

      #stars {
        font-size: 14px;
      }

        #game-time {
          margin-top: 4px;
          font-size: 9px;
        }

      #minimap-wrap {
        bottom: 18px;
        left: 12px;
        width: 122px;
        height: 122px;
      }

      #speed-wrap {
        bottom: 22px;
        right: 50%;
        transform: translateX(50%);
        min-width: 72px;
        padding: 6px 9px;
      }

      #weapon-wrap {
        bottom: auto;
        top: 78px;
        right: 10px;
        padding: 5px 8px;
        font-size: 10px;
      }

      #pause-button {
        display: block;
      }

      .pause-sensitivity {
        display: block;
      }

      #mobile-controls {
        display: block;
        position: fixed;
        inset: 0;
        z-index: 20;
        pointer-events: none;
        font-family: Consolas, 'Courier New', monospace;
      }

      .mobile-stick {
        position: absolute;
        left: 18px;
        bottom: 22px;
        width: 128px;
        height: 128px;
        border: 2px solid rgba(255, 255, 255, 0.52);
        border-radius: 50%;
        background: rgba(0, 0, 0, 0.32);
        pointer-events: auto;
        touch-action: none;
      }

      .mobile-stick::after {
        content: '';
        position: absolute;
        inset: 25%;
        border: 1px solid rgba(255, 255, 255, 0.2);
        border-radius: 50%;
      }

      .mobile-stick-knob {
        position: absolute;
        left: 50%;
        top: 50%;
        width: 46px;
        height: 46px;
        border: 1px solid #fff;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.2);
        transform: translate(-50%, -50%);
        transition: transform 0.08s ease-out, box-shadow 0.12s ease;
        box-shadow: 0 0 10px rgba(255, 255, 255, 0.08);
        pointer-events: none;
      }

      .mobile-actions {
        position: absolute;
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        width: 142px;
        pointer-events: auto;
      }

      .mobile-actions-left {
        left: 162px;
        bottom: 26px;
      }

      .mobile-actions-right {
        right: 16px;
        bottom: 24px;
        justify-content: flex-end;
      }

      .touch-button {
        min-width: 60px;
        min-height: 44px;
        padding: 7px 8px;
        border: 1px solid rgba(255, 255, 255, 0.7);
        border-radius: 2px;
        background: rgba(0, 0, 0, 0.65);
        color: #fff;
        font: 700 10px Consolas, 'Courier New', monospace;
        letter-spacing: 0.5px;
        touch-action: none;
        user-select: none;
        -webkit-user-select: none;
      }

      .touch-button:active {
        background: #fff;
        color: #000;
      }

      .touch-small {
        min-width: 62px;
      }

      .touch-aim {
        border-color: #ffce33;
      }

      .touch-fire {
        min-width: 76px;
        min-height: 54px;
        border-color: #ff3b3b;
        background: rgba(100, 0, 0, 0.72);
      }

      .version-label {
        right: 10px;
        bottom: 4px;
        font-size: 8px;
      }
    }

    @media (max-width: 900px) and (pointer: coarse) and (orientation: portrait) {
      #orientation-overlay {
        position: fixed;
        inset: 0;
        z-index: 200;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-direction: column;
        padding: 24px;
        box-sizing: border-box;
        background: #050505;
        color: #fff;
        text-align: center;
        font-family: Consolas, 'Courier New', monospace;
      }

      #orientation-overlay h1 {
        margin: 18px 0 10px;
        font-size: 22px;
        letter-spacing: 2px;
      }

      #orientation-overlay p {
        margin: 0;
        color: #aaa;
        font-size: 12px;
      }

      .orientation-mark {
        color: #ffce33;
        font-size: 56px;
        line-height: 1;
      }
    }

    body.playing {
      cursor: none;
    }

    body.playing.paused {
      cursor: default;
    }

    #busted-overlay {
      position: fixed;
      inset: 0;
      background: rgba(80, 0, 0, 0.55);
      display: none;
      align-items: center;
      justify-content: center;
      flex-direction: column;
      z-index: 60;
      color: #fff;
    }

    #busted-overlay h2 {
      font-size: 48px;
      letter-spacing: 4px;
      margin: 0;
    }
