@font-face {
  font-family: "JetBrainsMono Nerd Font";
  src: url("../assets/fonts/JetBrainsMonoNerdFontMono-Regular.woff") format("woff");
  font-weight: 400;
  font-display: swap;
}

:root {
  --bg: #121214;
  --chrome: #1b1e26;
  --ink: #d0d0d0;
  --dim: #808080;
  --accent: #50c8ff;
  --coral: #ff6e63;
  --amber: #ffb454;
  --yellow: #ffe066;
  --green: #7bd88f;
  --blue: #62a8ff;
  --indigo: #7b8cfa;
  --violet: #9b8cf5;
  --mono: "JetBrainsMono Nerd Font", "JetBrains Mono", ui-monospace, monospace;
  --focus: var(--amber);
}

* { box-sizing: border-box; }
html, body {
  margin: 0;
  height: 100%;
  background: #000;
  color: var(--ink);
  font-family: var(--mono);
  overflow: hidden;
}

.app {
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
  margin: 0;
  background: #0a0a0c;
  border: none;
  box-shadow: none;
}

.titlebar {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 36px;
  padding: 0 12px;
  background: var(--chrome);
  border-bottom: 1px solid #2a2a34;
  user-select: none;
  flex-shrink: 0;
}
.app-icon { width: 16px; height: 16px; }
.title {
  flex: 1;
  text-align: center;
  font-size: 13px;
  color: #e5e9f0;
  letter-spacing: 0.01em;
}

.stage {
  flex: 1;
  min-height: 0;
  position: relative;
  background: #0a0a0c;
  outline: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: text;
}
.stage:focus-within #screen {
  box-shadow: 0 0 0 1px #3a3a48, 0 24px 80px rgba(0, 0, 0, 0.55);
}
#screen {
  display: block;
  background: var(--bg);
  image-rendering: auto;
  box-shadow: 0 0 0 1px #2a2a34, 0 24px 80px rgba(0, 0, 0, 0.55);
}
.keys {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  border: 0;
  padding: 0;
  margin: 0;
  resize: none;
  overflow: hidden;
  caret-color: transparent;
  color: transparent;
  background: transparent;
  outline: none;
  z-index: 2;
}

.chord {
  display: flex;
  align-items: stretch;
  height: 28px;
  background: var(--focus);
  color: #111;
  font-size: 12px;
  line-height: 28px;
  white-space: nowrap;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  flex-shrink: 0;
}
.chord.is-visible {
  opacity: 1;
  pointer-events: auto;
}
.chord-text {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: clip;
  padding: 0 8px;
  font-weight: 500;
}
.spectrum {
  display: flex;
  flex-shrink: 0;
  border-left: 1px solid #111;
}
.spectrum i {
  display: block;
  width: 5px;
  height: 100%;
}
.spectrum i:nth-child(1) { background: var(--coral); }
.spectrum i:nth-child(2) { background: var(--amber); }
.spectrum i:nth-child(3) { background: var(--yellow); }
.spectrum i:nth-child(4) { background: var(--green); }
.spectrum i:nth-child(5) { background: var(--blue); }
.spectrum i:nth-child(6) { background: var(--indigo); }
.spectrum i:nth-child(7) { background: var(--violet); }
.spectrum i:nth-child(8) { background: var(--ink); }

@media (max-width: 720px) {
  .chord { font-size: 11px; }
}
