/* CAPTCHA × PISSTEK — PnL Generator (pissmissle.fun aesthetic) */

@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&display=swap');

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

body {
  background: #0a0a0a;
  color: #e0e0e0;
  font-family: 'Courier New', monospace;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  overflow-x: hidden;
}

/* Scanline overlay */
.scanlines {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 999;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.08) 2px,
    rgba(0, 0, 0, 0.08) 4px
  );
}

.container {
  text-align: center;
  padding: 2rem;
  max-width: 840px;
  width: 100%;
  position: relative;
  z-index: 1;
}

/* ── Header with glitch effect ── */

.title {
  font-family: 'Press Start 2P', monospace;
  font-size: 1.4rem;
  letter-spacing: 0.08em;
  margin-bottom: 0.5rem;
  color: #FFCC00;
  text-shadow:
    0 0 10px rgba(255, 204, 0, 0.5),
    0 0 20px rgba(255, 204, 0, 0.2);
  position: relative;
  animation: glitch-flicker 4s infinite;
}

.title .yellow {
  color: #FF4444;
}

@keyframes glitch-flicker {
  0%, 92%, 94%, 96%, 100% { opacity: 1; }
  93% { opacity: 0.8; transform: translateX(-2px); }
  95% { opacity: 0.9; transform: translateX(1px); }
}

.subtitle {
  font-family: 'Press Start 2P', monospace;
  color: #555;
  font-size: 0.55rem;
  letter-spacing: 0.3em;
  margin-bottom: 2.5rem;
}

/* ── Input fields — dark with bright borders ── */

#handle-input,
#wallet-input {
  background: #111111;
  border: 2px solid #333;
  color: #FFCC00;
  font-family: 'Courier New', monospace;
  font-size: 1.1rem;
  padding: 0.8rem 1rem;
  width: 100%;
  max-width: 440px;
  border-radius: 0;
  text-align: center;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  display: block;
  margin: 0 auto 1rem;
}

#handle-input:focus,
#wallet-input:focus {
  border-color: #FFCC00;
  box-shadow: 0 0 8px rgba(255, 204, 0, 0.3), inset 0 0 4px rgba(255, 204, 0, 0.1);
}

#handle-input::placeholder,
#wallet-input::placeholder {
  color: #444;
  font-style: normal;
}

#wallet-input { font-size: 0.85rem; }

/* ── Buttons — Win95/retro outset style ── */

button {
  background: #FFCC00;
  color: #0a0a0a;
  font-family: 'Press Start 2P', monospace;
  font-weight: bold;
  font-size: 0.7rem;
  border: 3px outset #FFE066;
  padding: 0.8rem 2rem;
  cursor: pointer;
  margin: 0.5rem 0.4rem 0;
  transition: all 0.1s;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

button:hover {
  background: #FFD633;
  border-color: #FFCC00;
}

button:active {
  border-style: inset;
  transform: translateY(1px);
}

button:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  border-style: outset;
}

/* ── Error message ── */

.error {
  color: #ff4444;
  font-family: 'Courier New', monospace;
  font-size: 0.85rem;
  margin-top: 0.8rem;
  min-height: 1.2em;
}

/* ── Card section ── */

#card-section { margin-top: 1.5rem; }

#card-canvas {
  border-radius: 0;
  border: 2px solid #333;
  max-width: 100%;
  height: auto;
  box-shadow: 0 0 20px rgba(255, 204, 0, 0.1);
}

/* ── Background selector ── */

.bg-selector {
  margin: 1.2rem auto 0;
  max-width: 520px;
}

.bg-label {
  font-family: 'Press Start 2P', monospace;
  color: #444;
  font-size: 0.45rem;
  letter-spacing: 0.15em;
  margin-bottom: 0.6rem;
}

.bg-options {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.bg-thumb {
  width: 72px;
  height: 48px;
  border: 2px outset #444;
  cursor: pointer;
  overflow: hidden;
  transition: border-color 0.2s, transform 0.15s;
}

.bg-thumb:hover {
  border-color: #888;
  transform: scale(1.05);
}

.bg-thumb.selected {
  border-color: #FFCC00;
  box-shadow: 0 0 10px rgba(255, 204, 0, 0.5);
  border-style: inset;
}

.bg-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.bg-thumb-dark {
  width: 100%;
  height: 100%;
  background: #0A0F0A;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Press Start 2P', monospace;
  font-size: 0.4rem;
  color: #555;
  letter-spacing: 0.1em;
}

/* ── Card action buttons ── */

.card-actions {
  margin-top: 1rem;
  display: flex;
  justify-content: center;
  gap: 0.8rem;
}

/* ── Footer tag ── */

.footer-tag {
  margin-top: 2.5rem;
  font-family: 'Courier New', monospace;
  font-size: 0.7rem;
  color: #333;
  letter-spacing: 0.1em;
}
