.learn { gap: 16px; user-select: auto; }
.learn .top { justify-content: flex-start; gap: 14px; }
.back {
  color: var(--muted); text-decoration: none; font-size: 0.95rem;
  padding: 8px 12px 8px 8px; border: 1px solid var(--line); border-radius: 999px;
}
.muted { color: var(--muted); }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }

.song-card {
  background: linear-gradient(160deg, #2a211b, var(--panel));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
}
.song-card h2 { margin: 2px 0 10px; font-size: 1.6rem; letter-spacing: -0.01em; }
.song-card p { margin: 0 0 10px; line-height: 1.5; color: #d9cbbb; }
.song-card .tip { margin: 0; font-size: 0.9rem; color: var(--muted); }
.song-card a, .lesson a { color: var(--brass); }
.eyebrow { text-transform: uppercase; letter-spacing: 0.16em; font-size: 0.72rem; color: var(--brass) !important; margin: 0 !important; }

.lessons {
  display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px;
  scrollbar-width: none; margin: 0 -16px; padding-inline: 16px;
}
.lessons::-webkit-scrollbar { display: none; }
.lessons button {
  flex: none; border: 1px solid var(--line); background: var(--panel); color: var(--muted);
  font: inherit; font-size: 0.88rem; padding: 9px 14px; border-radius: 999px; white-space: nowrap;
}
.lessons button b { color: var(--text); margin-right: 6px; }
.lessons button.on { background: var(--brass); border-color: var(--brass); color: #1b140e; font-weight: 700; }
.lessons button.on b { color: #1b140e; }
.lessons button.done::after { content: " ✓"; color: var(--good); }
.lessons button.on.done::after { color: #1b140e; }

.lesson h3 { margin: 0 0 6px; font-size: 1.25rem; }
.lesson-text { margin: 0 0 14px; color: #d9cbbb; line-height: 1.5; white-space: pre-line; }

button.primary { background: var(--brass); color: #1b140e; border-color: var(--brass); font-weight: 800; }
.lesson .row button, .paste button {
  border: 1px solid var(--line); background: var(--panel); color: var(--text);
  font: inherit; font-size: 0.95rem; padding: 11px 16px; border-radius: 999px;
}
.lesson .row button.primary { background: var(--brass); color: #1b140e; border-color: var(--brass); }
.lesson button:active { transform: scale(0.97); }

/* chords */
.chord-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.chord-card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 8px 6px 4px; color: var(--text); font: inherit; text-align: center;
}
.chord-card b { display: block; font-size: 1.1rem; }
.chord-card.playing { border-color: var(--brass); }
.chord-svg { width: 100%; max-width: 120px; display: block; margin: 0 auto; }
.chord-svg .nut { fill: var(--text); }
.chord-svg .fret { stroke: var(--line); stroke-width: 1.5; }
.chord-svg .str { stroke: var(--muted); stroke-width: 1.2; }
.chord-svg .dot { fill: var(--brass); }
.chord-svg .open { fill: none; stroke: var(--muted); stroke-width: 1.5; }
.chord-svg .mark { fill: var(--muted); font-size: 11px; text-anchor: middle; }
.chord-svg .finger { fill: #1b140e; font-size: 9px; font-weight: 700; text-anchor: middle; }

/* drill */
.drill { display: flex; flex-direction: column; gap: 14px; }
.pairs { flex-wrap: wrap; border-radius: var(--radius); }
.drill-stage { display: grid; grid-template-columns: 1.4fr 1fr; gap: 12px; align-items: end; }
.drill-chord { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px; text-align: center; }
.drill-chord span { display: block; font-weight: 800; font-size: 1.6rem; }
.drill-chord.next { opacity: 0.55; }
.drill-chord.next span { font-size: 0.8rem; font-weight: 500; color: var(--muted); }
.drill-chord.now { border-color: var(--brass); }
.drill-chord .chord-svg { max-width: 150px; }
.beats { display: flex; gap: 10px; justify-content: center; }
.beats i { width: 14px; height: 14px; border-radius: 50%; background: var(--line); transition: background 60ms; }
.beats i.on { background: var(--brass); }
.beats i.on.first { background: var(--good); }

.slider { display: flex; flex-direction: column; gap: 6px; color: var(--muted); font-size: 0.9rem; }
.slider b { color: var(--text); }
.slider input { width: 100%; accent-color: var(--brass); }

/* paste */
.paste textarea {
  width: 100%; background: #0f0d0b; color: var(--text); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 12px; font: 13px/1.35 ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  resize: vertical;
}
.paste { display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
.paste p { margin: 0; }

/* follow */
.follow { display: flex; flex-direction: column; gap: 12px; }
.next-note { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.next-note b { font-size: 1.05rem; }
.next-name { font-size: 2.4rem; font-weight: 800; line-height: 1; }
.follow.hit .next-name { color: var(--good); }

.tabgrid {
  display: flex; overflow-x: auto; gap: 2px; padding: 10px 8px; scroll-behavior: smooth;
  background: #0f0d0b; border: 1px solid var(--line); border-radius: var(--radius);
  font: 600 15px/1 ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
.tabgrid .names, .tabgrid .col { display: grid; grid-template-rows: repeat(6, 22px); flex: none; }
.tabgrid .names { color: var(--muted); padding-right: 6px; border-right: 2px solid var(--line); position: sticky; left: -8px; background: #0f0d0b; z-index: 1; }
.tabgrid .col { width: 26px; border-radius: 6px; cursor: pointer; }
.tabgrid .col span { display: grid; place-items: center; position: relative; color: var(--text); }
.tabgrid .col span::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; border-top: 1px solid var(--line); }
.tabgrid .col em { position: relative; font-style: normal; background: #0f0d0b; padding: 0 2px; border-radius: 3px; }
.tabgrid .col.current em { background: #3a2a15; }
.tabgrid .col.played span { color: #6b5f54; }
.tabgrid .col.current { background: rgba(227, 163, 59, 0.22); box-shadow: 0 0 0 1px var(--brass) inset; }
.tabgrid .col.current span { color: var(--brass); }

.feedback { margin: 0; min-height: 1.4em; font-weight: 600; text-align: center; }
.feedback.ok { color: var(--good); }
.feedback.bad { color: var(--bad); }
.stats { justify-content: space-between; color: var(--muted); font-size: 0.92rem; }
.stats b { color: var(--text); }
.buttons { justify-content: space-between; flex-wrap: nowrap; gap: 8px; }
.lesson .buttons button { flex: 1 1 auto; padding: 11px 10px; white-space: nowrap; }
.learn .level { margin: 0 10%; }
