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

body {
  background: #000;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  overflow: hidden;
}

#canvas { display: block; }

#status,
#progress,
#transfersub,
#info,
#infobox,
#box,
div.emscripten,
div.emscripten_border { display: none !important; }

/* ── landing overlay ── */
#overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: #070d07;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  transition: opacity 0.7s ease;
}
#overlay.fade-out {
  opacity: 0;
  pointer-events: none;
}

/* ── lane strips ── */
.lanes { position: absolute; bottom: 0; left: 0; width: 100%; }
.lane  { height: 40px; position: relative; overflow: hidden; }
.lane.road::after {
  content: '';
  position: absolute;
  top: 50%; left: 0;
  width: 200%; height: 3px;
  transform: translateY(-50%);
  background: repeating-linear-gradient(
    to right,
    transparent 0, transparent 36px,
    rgba(255,255,255,0.07) 36px, rgba(255,255,255,0.07) 72px
  );
  animation: dash 1.6s linear infinite;
}
@keyframes dash {
  from { transform: translateY(-50%) translateX(0); }
  to   { transform: translateY(-50%) translateX(72px); }
}
.lanes-fade {
  position: absolute;
  bottom: 280px; left: 0;
  width: 100%; height: 110px;
  background: linear-gradient(to bottom, #070d07, transparent);
}

/* ── content ── */
.content {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
}

h1 {
  font-family: Impact, 'Arial Black', sans-serif;
  font-size: clamp(64px, 13vw, 104px);
  letter-spacing: 10px;
  color: #00d637;
  text-shadow: 5px 5px 0 #004d10, 0 0 40px rgba(0,210,55,0.3);
  animation: glow 3s ease-in-out infinite;
}
@keyframes glow {
  0%, 100% { text-shadow: 5px 5px 0 #004d10, 0 0 40px rgba(0,210,55,0.30); }
  50%       { text-shadow: 5px 5px 0 #004d10, 0 0 72px rgba(0,230,70,0.65); }
}

.tagline {
  margin-top: 12px;
  font-family: Arial, sans-serif;
  font-size: 11px;
  letter-spacing: 7px;
  color: #2a622a;
  text-transform: uppercase;
}

.divider {
  margin: 24px 0 28px;
  width: 220px; height: 1px;
  background: linear-gradient(to right, transparent, #00a030, transparent);
}

#playBtn {
  padding: 15px 72px;
  font-family: Arial, sans-serif;
  font-size: 17px;
  font-weight: bold;
  letter-spacing: 5px;
  background: #009930;
  color: #fff;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s, transform 0.12s, box-shadow 0.2s;
  box-shadow: 0 4px 24px rgba(0,153,48,0.35);
}
#playBtn:hover {
  background: #00bf3f;
  transform: scale(1.06);
  box-shadow: 0 6px 36px rgba(0,200,60,0.55);
}
#playBtn:active { transform: scale(0.97); }

#overlayStatus {
  margin-top: 16px;
  font-family: Arial, sans-serif;
  font-size: 12px;
  letter-spacing: 2px;
  color: #2a622a;
  min-height: 18px;
  text-transform: uppercase;
}

#overlayLoadBar {
  display: none;
  width: 220px;
  height: 4px;
  background: #0a2a0a;
  border-radius: 2px;
  margin-top: 4px;
  overflow: hidden;
}
#overlayLoadBar.active { display: block; }
#overlayLoadBar::after {
  content: '';
  display: block;
  width: 40%;
  height: 100%;
  background: #00d637;
  border-radius: 2px;
  animation: barSlide 1.4s ease-in-out infinite;
}
@keyframes barSlide {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(250%); }
}

/* ── fade to black on click ── */
#fade {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: #000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.65s ease;
}
#fade.out { opacity: 1; }

.credit {
  position: absolute;
  bottom: 14px;
  font-family: Arial, sans-serif;
  font-size: 11px;
  color: #2a3a2a;
  letter-spacing: 1px;
  z-index: 10;
}
