/* Room layout — tokens/fonts come from css/sangeet-theme.css (canonical: shared/). */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

a { color: var(--terra); }
a:hover { color: var(--terra-soft); }

h1 { font-family: var(--font-display); font-size: 2.2rem; line-height: 1.15; margin: 0 0 10px; font-weight: 600; }
h2 { font-size: 1.5rem; margin: 40px 0 12px; padding-bottom: 6px; border-bottom: 3px solid var(--ochre); display: inline-block; }
h3 { font-size: 1.1rem; color: var(--terra); margin: 22px 0 8px; }
.lead { font-size: 1.1rem; color: #4a3728; }
.card {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--shadow); margin: 16px 0;
}
.note {
  border-left: 5px solid var(--ochre); background: #fbf1da;
  padding: 12px 16px; border-radius: 8px; margin: 16px 0; color: #5a4a34;
}
.tip { border-left-color: var(--green); background: #eef3e7; }
/* --- Action language (repo-wide) ---------------------------------------
   .btn.play  = this button makes sound / starts playback  → green, leading ▶
   .btn.nav   = this button goes to another page           → terra, trailing →
   Plain .btn / .btn.ghost stay neutral for everything else (Stop, Connect,
   Reveal, Reset, etc.) so a play triangle is never forced where it is nonsense.
   Note: use ONE of {ghost, play, nav} per button (same specificity). */
.btn.play {
  background: transparent; color: #2c6e49; border: 1.5px solid #b6d8bf;
}
.btn.play:hover { background: #eef6ef; border-color: #2c6e49; color: #22593a; }
.btn.play::before {
  content: "\25B6"; font-size: .78em; margin-right: 8px; line-height: 1;
  position: relative; top: -0.03em;
}
/* A .btn.play that has become its own Stop toggle: neutral look, ■ (set via
   textContent by js/sangeet-play-toggle.js) instead of the leading ▶. */
.btn.play.is-stop { color: var(--ink); border-color: var(--line); background: transparent; }
.btn.play.is-stop:hover { color: var(--terra); border-color: var(--terra); background: transparent; }
.btn.play.is-stop::before { content: none; }
.btn.nav { background: var(--terra); color: #fff; border: none; }
.btn.nav:hover { background: var(--terra-soft); color: #fff; }
.btn.nav::after { content: "\2192"; margin-left: 8px; font-weight: 700; }
.row { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; }

.card table { border-collapse: collapse; width: max-content; max-width: 100%; margin: 8px 0; font-size: 0.95rem; }
.card table.with-play { max-width: 760px; }
.card table.with-play .feel-cell { width: 1%; white-space: nowrap; padding-right: 0; }
.card th, .card td { text-align: left; padding: 6px 10px; border-bottom: 1px solid #eadfce; }
.card th { color: var(--accent); font-weight: 800; }

/* Diagram box is styled by css/sangeet-chord-diagram.css; four strings in a
 * narrower card want slightly larger type than the six-string default. */
.gdiag {
  --gdiag-width: 132px;
  --gdiag-width-lg: 168px;
  --gdiag-sname: 9px;
  --gdiag-mark: 12px;
  --gdiag-finger: 10px;
  --gdiag-sname-lg: 10px;
  --gdiag-mark-lg: 13px;
  --gdiag-finger-lg: 11px;
}

/* Guitar capo ↔ uke shape bridge (chords page). */
.capo-viz {
  display: flex; flex-wrap: wrap; align-items: center; gap: 14px 18px;
  margin: 14px 0 16px; padding: 12px 14px;
  background: #f7f0e4; border-radius: 10px; border: 1px solid var(--line);
}
.capo-viz-label {
  font-size: .72rem; font-weight: 800; letter-spacing: .06em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 6px;
}
.capo-neck {
  display: grid; grid-template-columns: repeat(6, minmax(36px, 1fr));
  gap: 4px; position: relative; max-width: 320px;
}
.capo-neck > span {
  text-align: center; font-weight: 800; font-size: .82rem;
  padding: 8px 4px; border-radius: 6px;
}
.capo-bass.muted {
  color: var(--muted); background: #ebe3d4; opacity: .7;
  text-decoration: line-through;
}
.capo-top {
  color: var(--ink); background: #fffdf8;
  border: 1.5px solid var(--terra);
}
.capo-bar {
  grid-column: 3 / -1; margin-top: 2px;
  background: var(--ink); color: #fff; font-size: .7rem;
  letter-spacing: .08em; text-transform: uppercase; padding: 4px !important;
}
.capo-viz-eq {
  font-size: 1.6rem; font-weight: 800; color: var(--terra); line-height: 1;
}
.capo-uke-strings {
  display: flex; gap: 6px;
}
.capo-uke-strings span {
  min-width: 36px; text-align: center; font-weight: 800;
  padding: 8px 6px; border-radius: 6px;
  background: #fffdf8; border: 1.5px solid var(--terra); color: var(--ink);
}
.shape-pairs {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 14px;
  margin-top: 8px;
}
.shape-pair {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.shape-pair-cap {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  text-align: center; font-size: .82rem; line-height: 1.25; color: var(--ink);
  min-height: 4.2em;
}
.shape-pair-cap small {
  display: block; font-size: .68rem; font-weight: 600;
  color: var(--muted); letter-spacing: .02em;
}
.shape-arrow { color: var(--terra); font-weight: 800; font-size: 1rem; }
.shape-from, .shape-to { display: block; }

@media (max-width: 820px) {
  .capo-neck { max-width: 100%; grid-template-columns: repeat(3, 1fr); }
  .capo-bar { grid-column: 1 / -1; }
}

/* The neck itself is styled by css/sangeet-fretboard.css (shared with the
 * other fretted rooms). Room-specific neck overrides would go here. */

.gtab-wrap {
  overflow-x: auto;
  max-width: 100%;
  margin: 10px auto;
  width: fit-content;
}
.gtab-inner {
  position: relative;
  display: inline-block;
  width: fit-content;
}
.gtab-inner .gtab,
.gtab-inner .gym-tab {
  margin: 0;
  overflow: visible;
}
.gtab-playhead {
  position: absolute;
  top: 8px;
  bottom: 8px;
  width: 1.6em;
  background: var(--terra);
  opacity: 0.28;
  border-radius: 3px;
  pointer-events: none;
  display: none;
  z-index: 1;
  transition: left 0.07s linear;
}
.gtab-inner.is-playing .gtab-playhead { display: block; }

.tsig-frac {
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center;
  min-width: 2.2rem; font-weight: 800; line-height: 1; margin-right: 4px; vertical-align: middle;
}
.tsig-frac b { font-size: 1.15rem; font-style: normal; }
.tsig-frac i {
  display: block; width: 1.35em; height: 2px; background: var(--ink); margin: 3px 0; font-style: normal;
}

.nv-ruler {
  display: flex; height: 42px; border: 2px solid var(--line); border-radius: 10px;
  overflow: hidden; background: #fffdf8; margin: 10px 0 6px;
}
.nv-cell {
  flex: var(--w, 1); min-width: 0;
  border-right: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  font-size: .72rem; font-weight: 800; background: #fff6d6;
}
.nv-cell:last-child { border-right: none; }
.nv-cell.rest { background: #f4eee4; color: var(--muted); font-weight: 700; }
.nv-cell.empty { background: #fffdf8; color: var(--muted); font-weight: 600; }
.nv-cell.on { background: var(--ochre); border-color: var(--terra); }
.nv-count {
  display: flex; font-size: .72rem; font-weight: 700; color: var(--muted);
  letter-spacing: .02em; margin: 0 0 10px;
}
.nv-count span { flex: 1; text-align: center; }
.nv-add { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
.nv-add .btn { font-size: .85rem; padding: 7px 12px; }
.nv-left { font-weight: 800; margin: 6px 0 0; }
.nv-left.ok { color: #1a7a4e; }
.nv-left.over { color: #c43b2a; }

.player {
  position: sticky; top: 10px; z-index: 5; background: #fffdf8;
  border: 1px solid #e7ddcd; border-radius: 14px; padding: 12px 14px; margin: 6px 0 14px;
}
.now-chords { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 6px; align-items: flex-start; }
.now-chip {
  border: 1px solid #e0d6c5; background: #fff; border-radius: 10px;
  padding: 8px 12px; min-width: 70px; text-align: center;
}
.now-chip .rn { font-family: ui-monospace, Consolas, monospace; color: var(--muted); font-size: .72rem; }
.now-chip .nm { font-weight: 800; font-size: .98rem; }
.now-chip.active { border-color: var(--terra); background: var(--terra); color: #fff; }
.now-chip.active .rn { color: #eaf4ef; }
/* Play-along: chord name + fingerboard diagram (beginner-friendly). */
.now-chip.with-shape {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 6px 6px 8px; min-width: 0;
}
.now-chip.with-shape .rn { margin-bottom: 2px; }
.now-chip.with-shape .gdiag {
  border: none; background: transparent; padding: 0;
  width: 96px; min-width: 96px; border-radius: 0;
}
.now-chip.with-shape .gdiag-name { margin-top: 2px; font-size: .92rem; }
.now-chip.with-shape .gdiag:hover,
.now-chip.with-shape .gdiag:focus-visible {
  border-color: transparent; outline: none;
}
.now-chip.with-shape.active {
  background: #fff7ef; color: var(--ink);
  border-color: var(--terra); box-shadow: 0 0 0 2px rgba(184, 90, 42, 0.22);
}
.now-chip.with-shape.active .rn { color: var(--terra); font-weight: 800; }
.now-chip.with-shape.active .gdiag-name { color: var(--terra); }
.now-chip.missing-shape .nm { margin-top: 4px; }
.song-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.song-btn {
  text-align: left; width: 100%; cursor: pointer; border: 1px solid #e0d6c5;
  background: #fff; border-radius: 10px; padding: 10px 12px; font: inherit; color: var(--ink);
}
.song-btn:hover, .song-btn.active { border-color: var(--terra); background: #e8f2ee; }
.song-btn .t { font-weight: 700; display: block; }
.song-btn .a { color: var(--muted); font-size: .88rem; }

.tracks {
  display: grid;
  gap: 12px;
  margin: 16px 0;
}
@media (min-width: 800px) {
  .tracks { grid-template-columns: 1fr 1fr 1fr; }
}
.track {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px;
  box-shadow: var(--shadow);
}

@media (max-width: 820px) {
  
  h1 { font-size: 1.75rem; }
}
