/* Final UI polish for the deployed TypeRush bundle. */
.typerush-home-button {
  color: #f8fafc;
}

.typerush-home-button svg {
  display: block;
}

/* The preloader should show progress, not internal asset and model names. */
.preloader-sub-tag,
.preloader-model-active,
.preloader-fleet-grid,
.preloader-loading-pill,
.simple-status-text {
  display: none !important;
}

.game-preloader-center-box {
  gap: 16px;
}

/* The compiled screen uses these class names; this restores its intended card UI. */
.exchange-modal-card {
  position: relative;
  width: min(580px, 100%);
  max-height: min(720px, calc(100vh - 40px));
  overflow: auto;
  box-sizing: border-box;
  padding: 26px;
  border: 1px solid rgba(125, 211, 252, .28);
  border-radius: 20px;
  background: linear-gradient(155deg, #16233a 0%, #0b1220 58%, #060b14 100%);
  box-shadow: 0 28px 80px rgba(0, 0, 0, .72), 0 0 46px rgba(56, 189, 248, .16);
  color: #f8fafc;
  font-family: var(--font-sans, Inter, sans-serif);
  animation: typerushExchangeEnter .24s cubic-bezier(.16, 1, .3, 1);
}

@keyframes typerushExchangeEnter {
  from { opacity: 0; transform: translateY(10px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.exchange-modal-header,
.exchange-player-strip,
.form-row-header,
.input-group-row,
.conversion-result-box,
.exchange-actions {
  display: flex;
  align-items: center;
}

.exchange-modal-header {
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.exchange-title-stack { min-width: 0; }
.exchange-badge,
.rate-badge,
.exchange-success-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #7dd3fc;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .12em;
}

.exchange-badge { margin-bottom: 5px; }
.exchange-modal-title { margin: 0; color: #fff; font-size: clamp(20px, 4vw, 25px); line-height: 1.08; letter-spacing: -.035em; }

.exchange-close-btn {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 10px;
  background: rgba(255,255,255,.06);
  color: #cbd5e1;
  cursor: pointer;
}
.exchange-close-btn:hover { color: #fff; background: rgba(239,68,68,.25); border-color: rgba(248,113,113,.65); }

.exchange-body { display: grid; gap: 14px; }
.exchange-player-strip,
.exchange-rate-banner,
.exchange-form-section,
.conversion-result-box,
.exchange-meta-box,
.exchange-receipt-card {
  border: 1px solid rgba(148,163,184,.18);
  border-radius: 14px;
  background: rgba(15, 23, 42, .66);
}

.exchange-player-strip { justify-content: space-between; gap: 14px; padding: 13px 15px; }
.player-meta { display: flex; align-items: center; gap: 10px; min-width: 0; }
.pilot-avatar { display: grid; place-items: center; flex: 0 0 auto; width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(135deg, #0ea5e9, #1d4ed8); font-size: 19px; }
.pilot-role,
.wallet-label,
.available-stash,
.conversion-sub,
.receipt-label { display: block; color: #94a3b8; font-size: 10px; font-weight: 800; letter-spacing: .08em; }
.pilot-name { overflow: hidden; color: #fff; font-size: 15px; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.platform-wallet-preview { flex: 0 0 auto; text-align: right; }
.wallet-val { color: #fbbf24; font-family: var(--font-mono, monospace); font-size: 15px; font-weight: 800; }

.exchange-rate-banner { padding: 13px 15px; background: linear-gradient(110deg, rgba(14,165,233,.14), rgba(16,185,129,.11)); }
.rate-badge { color: #7dd3fc; }
.rate-equation { display: flex; align-items: baseline; gap: 7px; margin: 5px 0; font-family: var(--font-mono, monospace); font-size: 17px; font-weight: 900; }
.rate-highlight { color: #facc15; }.rate-eq { color: #94a3b8; }.rate-gold { color: #34d399; }
.rate-description { margin: 0; color: #cbd5e1; font-size: 12px; line-height: 1.4; }

.exchange-form-section { padding: 15px; }
.form-row-header { justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.form-row-header label { color: #e2e8f0; font-size: 11px; font-weight: 800; letter-spacing: .055em; }
.available-stash { text-align: right; }.available-stash strong { color: #facc15; }
.input-group-row { gap: 10px; }
.input-with-icon { display: flex; flex: 1 1 auto; align-items: center; min-width: 0; padding: 0 12px; border: 1px solid rgba(125,211,252,.3); border-radius: 11px; background: #08111f; }
.input-with-icon:focus-within { border-color: #38bdf8; box-shadow: 0 0 0 3px rgba(56,189,248,.12); }
.input-coin-icon { flex: 0 0 auto; color: #facc15; }
.exchange-num-input { width: 100%; min-width: 0; padding: 11px 8px; border: 0; outline: 0; background: transparent; color: #fff; font-family: var(--font-mono, monospace); font-size: 18px; font-weight: 800; }
.quick-amount-buttons { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; }
.btn-quick-pill { padding: 9px 7px; border: 1px solid rgba(148,163,184,.25); border-radius: 8px; background: rgba(255,255,255,.06); color: #cbd5e1; font: 800 11px var(--font-mono, monospace); cursor: pointer; }
.btn-quick-pill:hover,.btn-quick-pill.max { border-color: rgba(56,189,248,.7); background: rgba(14,165,233,.16); color: #7dd3fc; }

.conversion-result-box { justify-content: space-between; gap: 12px; margin-top: 14px; padding: 13px 15px; background: linear-gradient(90deg, rgba(16,185,129,.12), rgba(14,165,233,.08)); }
.conversion-left { display: flex; align-items: center; gap: 9px; }.icon-sparkle { color: #facc15; }.conversion-title { color: #fff; font-size: 13px; font-weight: 800; }.conversion-borns-val { color: #34d399; font-family: var(--font-mono, monospace); font-size: 19px; font-weight: 900; white-space: nowrap; }
.exchange-error-notice { padding: 10px 12px; border: 1px solid rgba(248,113,113,.42); border-radius: 10px; background: rgba(127,29,29,.25); color: #fecaca; font-size: 12px; }
.btn-confirm-exchange { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; margin-top: 14px; padding: 14px; border: 0; border-radius: 11px; background: linear-gradient(135deg, #10b981, #047857); color: #fff; font: 800 14px var(--font-sans, Inter, sans-serif); cursor: pointer; box-shadow: 0 9px 22px rgba(5,150,105,.27); }
.btn-confirm-exchange:hover:not(:disabled) { filter: brightness(1.12); transform: translateY(-1px); }.btn-confirm-exchange:disabled { cursor: not-allowed; opacity: .48; }

.exchange-success-view { display: grid; justify-items: center; gap: 12px; text-align: center; }.celebration-icon-glow { display: grid; place-items: center; width: 74px; height: 74px; border: 2px solid #34d399; border-radius: 50%; background: rgba(16,185,129,.13); color: #facc15; box-shadow: 0 0 28px rgba(16,185,129,.3); }.exchange-success-heading { margin: -5px 0 0; color: #fff; }.exchange-success-sub { max-width: 410px; margin: 0; color: #cbd5e1; font-size: 13px; line-height: 1.45; }.exchange-receipt-card { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; width: 100%; box-sizing: border-box; padding: 14px; }.receipt-row { display: grid; gap: 4px; }.receipt-row:last-child { text-align: right; }.receipt-val-deduct { color: #fbbf24; }.receipt-val-credit { color: #34d399; }.receipt-arrow { color: #7dd3fc; }.exchange-meta-box { width: 100%; box-sizing: border-box; padding: 12px 14px; }.meta-line { display: flex; justify-content: space-between; gap: 12px; color: #94a3b8; font-size: 11px; }.meta-line + .meta-line { margin-top: 7px; }.meta-line b { color: #e2e8f0; }.meta-borns { color: #34d399 !important; }.exchange-actions { width: 100%; gap: 9px; }.btn-exchange-action { flex: 1; padding: 12px 10px; border-radius: 10px; font-size: 12px; font-weight: 800; cursor: pointer; }.btn-exchange-action.primary { border: 0; background: #38bdf8; color: #062030; }.btn-exchange-action.ghost { border: 1px solid rgba(148,163,184,.3); background: transparent; color: #cbd5e1; }

.typerush-ad-frame {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #08111f;
}
.garage-billboard-shell .billboard-inner-frame { padding: 4px; }

@media (max-width: 720px) {
  .exchange-modal-card { padding: 18px; border-radius: 16px; }
  .exchange-player-strip { align-items: flex-start; }.platform-wallet-preview { text-align: left; }
  .input-group-row { align-items: stretch; flex-direction: column; }.quick-amount-buttons { min-height: 39px; }
}


/* --- ENDGAME RESULTS SCREEN BANNER ADS --- */
.results-endgame-ad-slot {
  width: 100%;
  max-width: 640px;
  margin: 14px auto 18px auto;
  padding: 6px;
  background: #08111f;
  border: 1px solid rgba(125, 211, 252, 0.22);
  border-radius: 12px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.5);
  box-sizing: border-box;
  text-align: center;
}

.endgame-ad-label {
  font-family: var(--font-mono, monospace);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.15em;
  color: #64748b;
  text-transform: uppercase;
  margin-bottom: 5px;
}

.results-ad-frame {
  width: 100%;
  height: 90px;
  border: 0;
  display: block;
  background: #08111f;
  border-radius: 8px;
}

/* --- CAR COLOR LOCK & SWATCH STYLING --- */
.color-swatch-circle {
  width: 28px !important;
  height: 28px !important;
  border-radius: 50% !important;
  position: relative !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  border: 2px solid rgba(255, 255, 255, 0.45) !important;
  cursor: pointer !important;
  transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease !important;
  box-sizing: border-box !important;
}

.color-swatch-circle.is-selected,
.color-swatch-circle.is-active {
  border-color: #ffffff !important;
  transform: scale(1.18) !important;
  box-shadow: 0 0 14px rgba(255, 255, 255, 0.9) !important;
}

.color-swatch-circle.is-color-locked {
  filter: brightness(0.72) saturate(0.85) !important;
  box-shadow: inset 0 0 0 1.5px rgba(0, 0, 0, 0.65) !important;
}

.color-swatch-circle.is-color-locked:hover {
  filter: brightness(0.9) saturate(1) !important;
  transform: scale(1.1) !important;
}

.color-swatch-circle.is-color-locked::after {
  content: '🔒';
  font-size: 11px;
  line-height: 1;
  pointer-events: none;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.95));
}

.color-swatch-circle .swatch-lock-icon {
  display: none !important;
}

/* Strictly and permanently purge the ruined garage button & modal */
.results-actions button:nth-child(2):not(:last-child),
.results-actions [data-testid="results-garage-btn"],
[data-testid="results-garage-btn"],
[data-testid="garage-modal"] {
  display: none !important;
  pointer-events: none !important;
  visibility: hidden !important;
  width: 0 !important;
  height: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  border: 0 !important;
}
