:root {
  --bg: #0f0f1e;
  --nes-red: #e60012;
  --nes-grey: #7c7c7c;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background:
    radial-gradient(circle at 20% 10%, rgba(230,0,18,0.12), transparent 40%),
    radial-gradient(circle at 80% 90%, rgba(255,210,63,0.08), transparent 40%),
    #0f0f1e;
  background-attachment: fixed;
  min-height: 100vh;
}

.cart-panel {
  background: linear-gradient(180deg, #1c1c34, #16162a);
  border: 3px solid #2e2e50;
  border-radius: 12px;
  padding: 1.1rem;
  box-shadow: 0 6px 0 #0a0a18, inset 0 0 0 1px rgba(255,255,255,0.03);
}

.panel-title {
  font-family: 'Press Start 2P', monospace;
  font-size: 11px;
  color: #ffd23f;
  margin: 0 0 1rem 0;
  letter-spacing: 1px;
  border-bottom: 2px dashed #2e2e50;
  padding-bottom: 0.6rem;
}

.dropzone {
  border: 2px dashed #4a4a70;
  border-radius: 10px;
  padding: 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  min-height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.dropzone:hover { border-color: var(--nes-red); }
.dropzone-active {
  border-color: var(--nes-red);
  background: rgba(230,0,18,0.08);
  box-shadow: 0 0 20px rgba(230,0,18,0.3);
}

.crt-wrap {
  position: relative;
  display: inline-block;
}
.crt-wrap::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(
    to bottom,
    rgba(0,0,0,0) 0,
    rgba(0,0,0,0) 2px,
    rgba(0,0,0,0.18) 3px
  );
}

.image-render-pixel {
  image-rendering: pixelated;
}

.hex-cell {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 700;
  text-align: center;
  padding: 6px 0;
  background: #0a0a18;
  border: 1px solid #2e2e50;
  border-radius: 4px;
  color: #c8c8c8;
  transition: all 0.12s;
}
.hex-magic {
  color: #4ade80;
  border-color: #4ade8055;
  background: rgba(74,222,128,0.08);
}
.hex-hover {
  border-color: var(--nes-red);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 3px 8px rgba(230,0,18,0.4);
}

.select-nes {
  width: 100%;
  background: #0a0a18;
  border: 2px solid #4a4a70;
  color: #fff;
  padding: 8px;
  border-radius: 6px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
}
.select-nes:focus { outline: none; border-color: var(--nes-red); }

input[type="range"] {
  height: 6px;
  border-radius: 3px;
  background: #2e2e50;
}

code {
  font-family: 'JetBrains Mono', monospace;
  background: #0a0a18;
  padding: 1px 5px;
  border-radius: 3px;
}