/**
 * Generated by Muse
 * Date: 2026-10-07
 * Version: 1.0.0
 * Description: Trade8s styles — dark jazz-club theme.
 */
:root {
  --bg: #14101c;
  --panel: #1e1830;
  --accent: #e8b34b;
  --accent2: #7dd3fc;
  --text: #f0ead8;
  --dim: #8a84a0;
  --user: #4ade80;
  --robot: #c084fc;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: -apple-system, 'Segoe UI', system-ui, sans-serif;
  min-height: 100vh;
}
#app { max-width: 900px; margin: 0 auto; padding: 16px; }
header { text-align: center; margin-bottom: 12px; }
header h1 { margin: 0; font-size: 2.2rem; letter-spacing: 2px; color: var(--accent); }
.tagline { margin: 2px 0 0; color: var(--dim); font-style: italic; }

#setup {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: end;
  background: var(--panel); border-radius: 12px; padding: 12px 14px; margin-bottom: 12px;
}
#setup label { display: flex; flex-direction: column; font-size: 0.75rem; color: var(--dim); gap: 4px; }
#setup select, #setup input[type=range] { accent-color: var(--accent); }
#setup select {
  background: var(--bg); color: var(--text); border: 1px solid #3a3358;
  border-radius: 8px; padding: 8px; font-size: 0.95rem;
}
button {
  background: var(--accent); color: #1a1405; border: none; border-radius: 10px;
  padding: 10px 18px; font-size: 1rem; font-weight: 700; cursor: pointer;
}
button:disabled { opacity: 0.35; cursor: default; }
#stop-btn { background: #f87171; }
#pass-btn { background: var(--panel); color: var(--accent2); border: 1px solid var(--accent2); margin-top: 8px; }

#input-bar { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
#mic-btn { background: var(--panel); color: var(--text); border: 1px solid var(--accent); }
#mic-btn.live { background: rgba(74, 222, 128, 0.15); border-color: var(--user); color: var(--user); }
#mic-err { color: #f87171; font-size: 0.85rem; }
#tuner { display: flex; align-items: center; gap: 10px; }
#tuner.hidden { display: none; }
#mic-meter { width: 110px; height: 8px; background: #0c0a14; border-radius: 4px; overflow: hidden; }
#mic-meter-fill { height: 100%; width: 0; background: var(--accent); border-radius: 4px; transition: width 60ms; }
#tuner-note { font-size: 1.5rem; font-weight: 800; min-width: 52px; text-align: center; color: var(--text); }
#tuner-cents { font-size: 0.8rem; min-width: 44px; transition: margin-left 80ms; }
#gain-label { display: flex; align-items: center; gap: 6px; font-size: 0.75rem; color: var(--dim); }
#gain-label input { width: 90px; accent-color: var(--accent); }

#stage { text-align: center; margin-bottom: 8px; }
.hidden { display: none; }
#turn-banner {
  font-size: 1.6rem; font-weight: 800; letter-spacing: 1px;
  padding: 10px; border-radius: 12px; margin-bottom: 6px;
  transition: background 0.3s;
}
#turn-banner.user { background: rgba(74, 222, 128, 0.15); color: var(--user); }
#turn-banner.robot { background: rgba(192, 132, 252, 0.15); color: var(--robot); }
#turn-meta { color: var(--dim); font-size: 0.9rem; margin-bottom: 8px; }
#chord-now { color: var(--accent); font-weight: 700; font-size: 1.1rem; }

#prog-chart { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-bottom: 4px; }
.chord-cell {
  background: var(--panel); border: 1px solid #3a3358; border-radius: 8px;
  padding: 8px 10px; font-size: 0.85rem; font-weight: 600; min-width: 58px; text-align: center;
}
.chord-cell.now { border-color: var(--accent); color: var(--accent); box-shadow: 0 0 10px rgba(232, 179, 75, 0.35); }

#keyboard-wrap { margin-top: 14px; }
#keyboard {
  position: relative; display: flex; height: 190px; user-select: none;
  border-radius: 12px; overflow: hidden; background: #0c0a14;
}
.key { position: relative; cursor: pointer; }
.key.white {
  flex: 1; background: linear-gradient(#fdfbf5, #e8e2d2);
  border-right: 1px solid #b9b29e; border-radius: 0 0 6px 6px; z-index: 1;
}
.key.white span {
  position: absolute; bottom: 8px; width: 100%; text-align: center;
  color: #8a84a0; font-size: 0.7rem; font-weight: 700;
}
.key.black {
  width: 6.5%; margin: 0 -3.25%; height: 58%;
  background: linear-gradient(#3a3550, #14101c);
  border-radius: 0 0 5px 5px; z-index: 2;
}
.key.white.active { background: linear-gradient(#bbf7d0, #86efac); }
.key.black.active { background: linear-gradient(#4ade80, #166534); }
.key.robot-hit { filter: brightness(1.6); }
.key.white.robot-hit { background: linear-gradient(#e9d5ff, #c084fc); }
.key.black.robot-hit { background: linear-gradient(#c084fc, #7e22ce); }
.hint { text-align: center; color: var(--dim); font-size: 0.8rem; }

@media (max-width: 600px) {
  #keyboard { height: 150px; }
  header h1 { font-size: 1.7rem; }
  #turn-banner { font-size: 1.25rem; }
}
