  *::before,
  *::after {
      margin: 0;
      padding: 0;
      box-sizing: border-box;
  }

  :root {
      --black: #0a0a0a;
      --yellow: #FFD600;
      --red: #B02519;
      --white: #f5f5f0;
      --grey: #1a1a1a;
  }

  html,
  body {
      height: 100%;
      background: var(--black);
      color: var(--white);
      font-family: 'DM Sans', sans-serif;
      overflow-x: hidden;
      overflow-y: auto;
  }

  /* ── Road ──────────────────────────────── */
  .road {
      position: fixed;
      bottom: 0;
      left: 0;
      right: 0;
      height: 110px;
      background: #111;
      z-index: 1;
  }

  .road::before {
      content: '';
      position: absolute;
      top: 50%;
      left: 0;
      right: 0;
      height: 4px;
      background: repeating-linear-gradient(90deg, var(--yellow) 0, var(--yellow) 40px, transparent 40px, transparent 80px);
      transform: translateY(-50%);
      animation: roadMove 0.6s linear infinite;
  }

  .road::after {
      content: '';
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      height: 3px;
      background: var(--yellow);
      opacity: 0.3;
  }

  @keyframes roadMove {
      from {
          background-position: 0 0;
      }

      to {
          background-position: -80px 0;
      }
  }

  /* ── City skyline ────────────────────────── */
  .skyline {
      position: fixed;
      bottom: 110px;
      left: 0;
      right: 0;
      height: 200px;
      z-index: 0;
      overflow: auto;
  }

  .skyline svg {
      width: 100%;
      height: 100%;
  }

  /* ── Stars ───────────────────────────────── */
  .stars {
      position: fixed;
      inset: 0;
      z-index: 0;
  }

  .star {
      position: absolute;
      background: white;
      border-radius: 50%;
      animation: twinkle var(--d, 3s) ease-in-out infinite;
  }

  @keyframes twinkle {

      0%,
      100% {
          opacity: 0.2;
          transform: scale(1);
      }

      50% {
          opacity: 1;
          transform: scale(1.4);
      }
  }

  /* ── Taxi ────────────────────────────────── */
  .taxi-scene {
      position: fixed;
      bottom: 80px;
      left: -220px;
      z-index: 10;
      animation: drive 4s cubic-bezier(0.25, 0.1, 0.25, 1) forwards;
      animation-delay: 0.5s;
  }

  @keyframes drive {
      0% {
          left: -220px;
      }

      60% {
          left: calc(50% - 90px);
      }

      75% {
          left: calc(50% - 85px);
      }

      100% {
          left: calc(50% - 90px);
      }
  }

  .taxi {
      width: 180px;
      filter: drop-shadow(0 10px 30px rgba(255, 214, 0, 0.4));
      animation: taxiBounce 0.3s ease-in-out infinite;
      animation-play-state: running;
  }

  .taxi-scene.parked .taxi {
      animation-play-state: paused;
  }

  @keyframes taxiBounce {

      0%,
      100% {
          transform: translateY(0) rotate(0deg);
      }

      50% {
          transform: translateY(-3px) rotate(0.3deg);
      }
  }

  /* Headlights beam */
  .headlight-beam {
      position: absolute;
      right: -60px;
      top: 18px;
      width: 70px;
      height: 28px;
      background: linear-gradient(90deg, rgba(255, 240, 150, 0.6), transparent);
      clip-path: polygon(0 30%, 100% 0%, 100% 100%, 0 70%);
      filter: blur(3px);
      opacity: 0;
      animation: lightsOn 0.3s ease forwards;
      animation-delay: 4.5s;
  }

  @keyframes lightsOn {
      to {
          opacity: 1;
      }
  }

  /* ── Main content ────────────────────────── */
  .error-content {
      position: relative;
      z-index: 20;
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      height: 100vh;
      padding-bottom: 130px;
      text-align: center;
      gap: 0;
  }

  .four-o-four {
      font-family: 'Syne', sans-serif;
      font-size: clamp(120px, 20vw, 220px);
      font-weight: 800;
      line-height: 0.85;
      color: transparent;
      -webkit-text-stroke: 2px rgba(255, 214, 0, 0.15);
      position: relative;
      user-select: none;
      animation: fadeInDown 0.8s ease forwards;
      animation-delay: 4.2s;
      opacity: 0;
  }

  .four-o-four::after {
      content: '404';
      position: absolute;
      inset: 0;
      color: transparent;
      -webkit-text-stroke: 2px var(--yellow);
      clip-path: inset(0 100% 0 0);
      animation: reveal 1s ease forwards;
      animation-delay: 4.6s;
  }

  @keyframes reveal {
      to {
          clip-path: inset(0 0% 0 0);
      }
  }

  @keyframes fadeInDown {
      from {
          opacity: 0;
          transform: translateY(-20px);
      }

      to {
          opacity: 1;
          transform: translateY(0);
      }
  }

  .headline {
      font-family: 'Syne', sans-serif;
      font-size: clamp(22px, 4vw, 42px);
      font-weight: 700;
      color: var(--white);
      opacity: 0;
      animation: fadeUp 0.6s ease forwards;
      animation-delay: 5s;
      margin-top: -10px;
  }

  .sub {
      font-size: clamp(13px, 1.8vw, 17px);
      font-weight: 300;
      color: rgba(245, 245, 240, 0.5);
      max-width: 360px;
      line-height: 1.6;
      opacity: 0;
      animation: fadeUp 0.6s ease forwards;
      animation-delay: 5.2s;
      margin-top: 14px;
  }

  @keyframes fadeUp {
      from {
          opacity: 0;
          transform: translateY(16px);
      }

      to {
          opacity: 1;
          transform: translateY(0);
      }
  }

  .btn-home {
      margin-top: 32px;
      padding: 14px 36px;
      background: var(--yellow);
      color: var(--black);
      font-family: 'Syne', sans-serif;
      font-size: 15px;
      font-weight: 700;
      letter-spacing: 0.06em;
      text-transform: uppercase;
      text-decoration: none;
      border: none;
      cursor: pointer;
      position: relative;
      overflow: auto;
      opacity: 0;
      animation: fadeUp 0.6s ease forwards;
      animation-delay: 5.4s;
      transition: transform 0.2s ease, box-shadow 0.2s ease;
  }

  .btn-home::before {
      content: '';
      position: absolute;
      inset: 0;
      background: var(--red);
      transform: translateX(-101%);
      transition: transform 0.3s ease;
      z-index: 0;
  }

  .btn-home:hover::before {
      transform: translateX(0);
  }

  .btn-home:hover {
      color: white;
      transform: translateY(-2px);
      box-shadow: 0 8px 24px rgba(176, 37, 25, 0.4);
  }

  .btn-home span {
      position: relative;
      z-index: 1;
  }

  /* ── Smoke puffs ─────────────────────────── */
  .smoke-container {
      position: fixed;
      bottom: 120px;
      z-index: 9;
      left: calc(50% - 90px);
      opacity: 0;
      animation: smokeAppear 0.1s forwards;
      animation-delay: 4.4s;
  }

  .smoke {
      position: absolute;
      width: 12px;
      height: 12px;
      background: rgba(200, 200, 200, 0.25);
      border-radius: 50%;
      filter: blur(4px);
      animation: puff 1.8s ease-out infinite;
  }

  .smoke:nth-child(1) {
      animation-delay: 0s;
      left: -10px;
  }

  .smoke:nth-child(2) {
      animation-delay: 0.6s;
      left: -18px;
  }

  .smoke:nth-child(3) {
      animation-delay: 1.2s;
      left: -5px;
  }

  @keyframes puff {
      0% {
          transform: translate(0, 0) scale(1);
          opacity: 0.5;
      }

      100% {
          transform: translate(-30px, -40px) scale(3);
          opacity: 0;
      }
  }

  @keyframes smokeAppear {
      to {
          opacity: 1;
      }
  }