/* dotBeat chord sheet styles - touched 2026-05-07 to refresh the public CSS asset. */
:root {
  --sheet-ink: #111827;
  --sheet-muted: #475569;
  --sheet-line: #c7d0de;
  --sheet-soft-line: #d4dce8;
  --sheet-gold: #d69425;
}

body {
  min-height: 100vh;
  color: var(--text);
  background: linear-gradient(180deg, var(--bg-top), var(--bg-bottom));
}

.chord-sheet-page {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 48px;
}

.nav-logo {
  text-decoration: none;
}

.chord-sheet-controls {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  align-items: start;
  margin: 14px 0 22px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  background: rgba(20, 36, 70, 0.72);
  box-shadow: 0 18px 36px rgba(4, 10, 24, 0.2);
}

.controls-title h1 {
  margin: 0;
  color: #f5f7fb;
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.02;
}

.control-grid {
  display: grid;
  grid-template-columns: minmax(168px, 240px) minmax(260px, 1fr);
  gap: 16px 28px;
  align-items: start;
}

.control-grid-primary {
  min-width: 0;
}

.control-grid-secondary {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}

.control-stack-duo {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  align-items: start;
}

.control-stack-duo .control-field {
  min-width: 0;
}

.control-field--progression {
  min-width: 0;
}

.control-checkbox-row {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 8px 24px;
  align-items: center;
}

.control-field--checkbox {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.control-field--checkbox input[type="checkbox"] {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  accent-color: #f0c45b;
  cursor: pointer;
}

.control-field--checkbox span {
  text-transform: none;
  letter-spacing: 0;
  font-size: 12px;
  font-weight: 600;
}

.chord-sheet-page[data-sheet="many"] .control-field--mode,
.chord-sheet-page[data-sheet="many"] .control-field--progression,
.chord-sheet-page[data-sheet="same-shape"] .control-field--keys,
.chord-sheet-page[data-sheet="same-shape"] .control-field--mode,
.chord-sheet-page[data-sheet="same-shape"] .control-field--progression,
.chord-sheet-page[data-sheet="movable"] .control-field--keys,
.chord-sheet-page[data-sheet="movable"] .control-field--mode,
.chord-sheet-page[data-sheet="movable"] .control-field--progression {
  display: none;
}

@media (max-width: 1120px) {
  .control-field--progression select {
    font-size: 11px;
  }
}

.control-field {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.control-field select {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  min-height: 44px;
  padding: 0 34px 0 11px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 12px;
  background: #0e1d39;
  color: #f5f7fb;
  font: inherit;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  line-height: 1.2;
  text-transform: none;
}

.control-field--progression select {
  font-size: 12px;
  font-weight: 700;
}

.control-field select option {
  background: #ffffff;
  color: #111827;
}

.control-field small {
  color: rgba(214, 229, 247, 0.72);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.35;
  text-transform: none;
}

.control-field select[multiple] {
  height: auto;
  min-height: 158px;
  padding: 8px 10px;
}

.control-field select[multiple] option {
  padding: 7px 8px;
  border-radius: 6px;
}

.control-print-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  min-width: 0;
}

.scale-mode-tip {
  flex: 1 1 220px;
  margin: 0;
  min-width: 0;
  color: var(--gold);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.38;
  letter-spacing: 0.01em;
}

.sheet-mode-tip-print {
  display: none;
  margin: 0;
}

.print-sheet-btn {
  width: auto;
  min-height: 44px;
  padding: 0 22px;
  border: 0;
  border-radius: 999px;
  background: #2a9db5;
  color: #081634;
  font: inherit;
  font-size: 14px;
  font-weight: 850;
  cursor: pointer;
  flex-shrink: 0;
  margin-top: 2px;
}

.print-page {
  color: var(--sheet-ink);
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 18px;
  box-shadow: 0 22px 48px rgba(4, 10, 24, 0.24);
  padding: 34px;
}

.print-sheet-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
  margin: 0 0 28px;
  padding: 0 0 18px;
  border-bottom: 2px solid #bfc9d8;
}

.print-sheet-brand {
  display: grid;
  gap: 6px;
  min-width: 180px;
}

.print-sheet-logo {
  width: 150px;
  height: auto;
  display: block;
}

.print-sheet-brand-copy {
  margin: 0;
  color: var(--sheet-muted);
  font-size: 13px;
}

.print-sheet-brand-note {
  margin: 4px 0 0;
  color: #94a3b8;
  font-size: 11px;
  font-style: italic;
  line-height: 1.4;
}

.print-sheet-title-group {
  text-align: right;
}

.print-sheet-title-group h2 {
  margin: 0;
  color: #0f172a;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.08;
}

.print-sheet-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px 22px;
  margin-top: 12px;
  color: #334155;
  font-size: 14px;
}

.print-sheet-meta strong {
  color: #0f172a;
}

/* Wrapper scrolls; inner <table> repeats <thead> on each printed page. */
.family-grid-wrapper {
  overflow-x: auto;
  padding-bottom: 4px;
  min-width: 0;
  max-width: 100%;
}

.family-grid {
  display: table;
  width: 100%;
  max-width: 100%;
  border-collapse: separate;
  border-spacing: 6px 10px;
  table-layout: fixed;
  min-width: 0;
}

.family-grid col.family-col-key {
  width: 68px;
}

/* Row classes on <tr> — hooks for print/theming (display: table-row is implicit). */

.family-grid thead {
  display: table-header-group;
}

.family-grid tbody {
  display: table-row-group;
}

.family-key-heading,
.family-roman-cell {
  display: table-cell;
  vertical-align: middle;
  text-align: center;
  min-height: 42px;
  padding: 8px 4px;
  border: 1.5px solid var(--sheet-line);
  border-radius: 8px;
  background: #f8fafc;
  font-size: 15px;
  font-weight: 900;
  letter-spacing: 0.05em;
}

.family-key-heading {
  color: #0f172a;
  text-transform: uppercase;
}

.family-roman-cell {
  color: var(--sheet-gold);
  padding: 8px 2px;
  text-transform: none;
  line-height: 1.2;
}

.family-card-cell {
  display: table-cell;
  vertical-align: top;
  text-align: center;
  padding: 0;
}

.family-grid th {
  font-weight: 900;
}

.progression-key-example-cell {
  display: table-cell;
  vertical-align: middle;
  padding: 0;
}

/* Inline-flex inner so <sup> stays in normal inline flow and reads as superscript. */
.family-roman-inner {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap;
  white-space: nowrap;
  text-transform: none;
}

.family-roman-cell sup {
  font-size: 0.62em;
  font-weight: 900;
  line-height: 0;
  vertical-align: super;
  text-transform: none;
}

.progression-key-example-row {
  margin-top: -2px;
}

.progression-key-example-text {
  display: block;
  width: 100%;
  box-sizing: border-box;
  padding: 6px 10px;
  border: 1px solid var(--sheet-soft-line);
  border-radius: 8px;
  background: #f8fafc;
  color: var(--sheet-muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.35;
}

.progression-key-example-key {
  color: #0f172a;
  font-weight: 900;
}

.family-key-tip-row {
  margin-top: -2px;
}

.family-key-tip-cell {
  display: table-cell;
  vertical-align: middle;
  padding: 3px 0 8px;
  color: var(--sheet-muted);
  font-size: 10px;
  font-style: italic;
  font-weight: 400;
  line-height: 1.4;
}

.family-key-cell {
  display: table-cell;
  vertical-align: top;
  text-align: center;
  padding: 8px 5px;
  border: 1.5px solid var(--sheet-line);
  border-radius: 8px;
  background: #f8fafc;
  color: #0f172a;
  font-size: 22px;
  font-weight: 900;
  line-height: 1;
}

.family-key-name {
  display: block;
}

.family-key-sig {
  display: block;
  margin-top: 5px;
  font-size: 12px;
  font-weight: 600;
  color: #64748b;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.family-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  height: 160px;
  padding: 6px 5px 4px;
  border: 1.5px solid var(--sheet-line);
  border-radius: 8px;
  background: #fff;
  break-inside: avoid;
  page-break-inside: avoid;
  text-align: center;
  box-sizing: border-box;
}

.family-card-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px;
  width: 100%;
  padding: 0 4px 4px;
}

.progression-example-row {
  margin-top: -5px;
}

.progression-example-label,
.progression-example-text {
  display: table-cell;
  vertical-align: middle;
  min-height: 34px;
  padding: 7px 10px;
  border: 1px solid var(--sheet-soft-line);
  border-radius: 8px;
  background: #f8fafc;
  color: var(--sheet-muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
}

.progression-example-label {
  text-align: center;
  color: #0f172a;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.progression-example-text {
  font-weight: 700;
  text-align: left;
}

.family-chord-name {
  color: #111827;
  font-size: clamp(12px, 1.6vw, 17px);
  font-weight: 800;
  line-height: 1.05;
  white-space: nowrap;
  flex-shrink: 0;
}

.chord-name-suffix {
  font-size: 0.85em;
  font-weight: 600;
  color: #334155;
  letter-spacing: 0;
}

.family-chord-notes {
  color: #64748b;
  font-size: 8px;
  font-weight: 500;
  line-height: 1.2;
  text-align: right;
  letter-spacing: 0.01em;
  flex-shrink: 1;
  min-width: 0;
  overflow-wrap: anywhere;
}

.chord-diagram-slot {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  flex: 1;
  min-height: 0;
  margin-top: 2px;
}

.chord-diagram {
  width: 102px;
  height: auto;
  flex-shrink: 0;
  display: block;
  overflow: visible;
}

.many-root-list {
  display: grid;
  gap: 18px;
}

.many-root-section {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr);
  gap: 10px;
  align-items: stretch;
  padding: 10px;
  border: 1.5px solid var(--sheet-line);
  border-radius: 10px;
  background: #fff;
  break-inside: avoid;
  page-break-inside: avoid;
}

.many-root-heading {
  display: grid;
  place-items: center;
  margin: 0;
  min-height: 100%;
  border: 1.5px solid var(--sheet-line);
  border-radius: 8px;
  background: #f8fafc;
  color: #0f172a;
  font-size: 28px;
  font-weight: 900;
  line-height: 1;
}

.many-group-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  min-width: 0;
}

.many-chord-group {
  display: grid;
  gap: 6px;
  min-width: 0;
  padding: 8px;
  border: 1px solid var(--sheet-soft-line);
  border-radius: 8px;
  background: #f8fafc;
}

.many-chord-group-title {
  margin: 0;
  color: var(--sheet-gold);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.06em;
  line-height: 1;
  text-align: center;
  text-transform: uppercase;
}

.many-chord-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(104px, 1fr));
  gap: 7px;
}

.many-chord-card {
  padding: 8px 5px 5px;
}

.many-chord-quality {
  color: #64748b;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.05em;
  line-height: 1;
  text-transform: uppercase;
}

.print-page[data-sheet="many"] .family-chord-name {
  font-size: clamp(14px, 1.8vw, 18px);
}

.print-page[data-sheet="many"] .chord-diagram {
  width: min(104px, 100%);
}

.same-shape-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 12px;
}

.same-shape-card {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-width: 0;
  padding: 10px;
  border: 1.5px solid var(--sheet-line);
  border-radius: 9px;
  background: #fff;
  break-inside: avoid;
  page-break-inside: avoid;
}

.same-shape-diagram {
  display: flex;
  justify-content: center;
}

.same-shape-card .chord-diagram {
  width: min(88px, 100%);
}

.same-shape-copy {
  display: grid;
  gap: 7px;
  min-width: 0;
}

.same-shape-pattern {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  padding: 4px 7px;
  border-radius: 999px;
  background: #f1f5f9;
  color: #334155;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.03em;
  overflow-wrap: anywhere;
}

.same-shape-names {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.same-shape-names span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 3px 7px;
  border: 1px solid var(--sheet-soft-line);
  border-radius: 999px;
  background: #f8fafc;
  color: #111827;
  font-size: 12px;
  font-weight: 850;
  line-height: 1;
}

.movable-family-list {
  display: grid;
  gap: 14px;
}

.movable-family-card {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1.5px solid var(--sheet-line);
  border-radius: 10px;
  background: #fff;
  break-inside: avoid;
  page-break-inside: avoid;
}

.movable-family-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #f8fafc;
  color: #475569;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.movable-family-name,
.movable-family-pattern {
  display: grid;
  gap: 3px;
}

.movable-family-pattern {
  text-align: right;
}

.movable-family-header strong {
  color: #0f172a;
  font-size: 14px;
  letter-spacing: 0.02em;
  text-transform: none;
}

.movable-entry-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(112px, 1fr));
  gap: 8px;
}

.movable-entry-card {
  padding: 9px 5px 5px;
}

.movable-entry-card .same-shape-pattern {
  margin-top: 4px;
  font-size: 10px;
}

.print-page[data-sheet="movable"] .chord-diagram {
  width: min(100px, 100%);
}

.diagram-grid,
.diagram-top {
  stroke: #94a3b8;
  stroke-width: 1.4;
}

.diagram-top,
.diagram-position-top {
  stroke: #64748b;
  stroke-width: 2.4;
}

.diagram-position-top {
  stroke-width: 1.4;
  stroke-dasharray: 3 2;
}

.diagram-fret-label {
  fill: #475569;
  font-size: 9px;
  font-weight: 800;
  text-anchor: start;
}

.diagram-dot {
  fill: #f0c45b;
}

.diagram-barre {
  stroke: #f0c45b;
  stroke-width: 13;
  stroke-linecap: round;
}

/* Match Scale Studio / songsheet: baritone chord markers use site teal (--teal / #2a9db5). */
.print-page[data-instrument="baritone"] .diagram-dot {
  fill: var(--teal, #2a9db5);
}

.print-page[data-instrument="baritone"] .diagram-barre {
  stroke: var(--teal, #2a9db5);
}

.print-page[data-instrument="baritone"] .family-roman-cell {
  color: var(--teal, #2a9db5);
}

.print-page[data-instrument="baritone"] .progression-key-example-text {
  color: #334155;
}

.print-page[data-instrument="baritone"] .progression-key-example-key {
  color: var(--teal, #2a9db5);
}

.diagram-finger {
  fill: #111827;
  font-size: 8px;
  font-weight: 800;
  text-anchor: middle;
  dominant-baseline: middle;
}

.diagram-fret-number {
  fill: #64748b;
  font-size: 7.5px;
  font-weight: 800;
  text-anchor: middle;
}

.diagram-open,
.diagram-muted {
  fill: #64748b;
  font-size: 11px;
  font-weight: 700;
  text-anchor: middle;
}

.diagram-muted {
  fill: #334155;
  font-weight: 900;
}

.chord-unavailable {
  display: grid;
  place-items: center;
  gap: 4px;
  width: 100%;
  min-height: 104px;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  color: #334155;
  font-weight: 800;
}

.chord-unavailable small {
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
}

.sheet-footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-top: 22px;
  padding-top: 14px;
  border-top: 1px solid var(--sheet-soft-line);
  color: #64748b;
  font-size: 11px;
  text-align: center;
}

.diagram-legend {
  display: inline-flex;
  justify-content: center;
  gap: 10px 18px;
  flex-wrap: wrap;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
}

.diagram-legend strong {
  display: inline-grid;
  place-items: center;
  min-width: 1.4em;
  color: #111827;
  font-weight: 900;
}

.sheet-footer-row {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  width: 100%;
}

.sheet-footer-note {
  margin: 0;
  max-width: 40rem;
  color: #64748b;
  font-size: 10px;
  line-height: 1.45;
  font-weight: 500;
}

.sheet-footer-credit {
  margin: 4px 0 0;
  padding: 0;
  max-width: 40rem;
  color: #64748b;
  font-size: 9px;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1.35;
}

@media (max-width: 920px) {
  .chord-sheet-controls {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .control-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .control-stack-duo {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .print-sheet-btn {
    width: auto;
  }

  .many-root-section {
    grid-template-columns: 1fr;
  }

  .many-root-heading {
    min-height: 46px;
  }

  .many-group-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .chord-sheet-page {
    width: min(100% - 20px, 1180px);
    margin-bottom: 28px;
  }

  .control-grid {
    gap: 12px;
  }

  .control-stack-duo {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .control-field select {
    font-size: 11px;
    min-height: 42px;
    padding: 0 28px 0 9px;
  }

  .print-page {
    padding: 18px;
    border-radius: 14px;
  }

  .print-sheet-header {
    display: grid;
    gap: 14px;
  }

  .print-sheet-title-group {
    text-align: left;
  }

  .print-sheet-meta {
    justify-content: flex-start;
  }

  .print-page:not([data-sheet="many"]) .family-grid {
    display: block;
    border-spacing: 0;
  }

  .print-page:not([data-sheet="many"]) .family-grid thead {
    display: none;
  }

  .print-page:not([data-sheet="many"]) .family-grid tbody {
    display: grid;
    gap: 10px;
  }

  .print-page:not([data-sheet="many"]) .family-shape-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(128px, 1fr));
    gap: 8px;
    padding: 8px;
    border: 1.5px solid var(--sheet-line);
    border-radius: 10px;
    background: #fff;
  }

  .print-page:not([data-sheet="many"]) .family-card-cell {
    display: block;
  }

  .family-card {
    min-height: 0;
    padding: 10px 6px 6px;
  }

  .print-page:not([data-sheet="many"]) .family-key-cell {
    display: block;
    grid-column: 1 / -1;
    padding: 9px 8px;
    font-size: 20px;
    writing-mode: horizontal-tb;
    transform: none;
  }

  .chord-diagram {
    width: 98px;
    flex-shrink: 0;
  }

  .print-page[data-sheet="many"] .chord-diagram {
    width: 98px;
  }

  .same-shape-grid {
    grid-template-columns: 1fr;
  }

  .same-shape-card {
    grid-template-columns: 104px minmax(0, 1fr);
  }

  .same-shape-card .chord-diagram {
    width: 98px;
  }

  .movable-family-header {
    align-items: flex-start;
    flex-direction: column;
  }

  .movable-family-pattern {
    text-align: left;
  }

  .movable-entry-grid {
    grid-template-columns: repeat(auto-fit, minmax(98px, 1fr));
  }

  .print-page:not([data-sheet="many"]) .progression-key-example-row,
  .print-page:not([data-sheet="many"]) .progression-example-row,
  .print-page:not([data-sheet="many"]) .family-key-tip-row {
    display: block;
    margin-top: -4px;
  }

  .print-page:not([data-sheet="many"]) .progression-key-example-cell,
  .print-page:not([data-sheet="many"]) .progression-example-label,
  .print-page:not([data-sheet="many"]) .progression-example-text,
  .print-page:not([data-sheet="many"]) .family-key-tip-cell {
    display: block;
    width: 100%;
    box-sizing: border-box;
  }

  .print-page:not([data-sheet="many"]) .progression-example-label {
    margin-bottom: 4px;
  }

  .many-root-list {
    gap: 14px;
  }

  .many-root-section {
    padding: 8px;
  }

  .many-chord-cards {
    grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  }

  .sheet-footer {
    display: flex;
    flex-direction: column;
  }

  .sheet-footer-row {
    display: grid;
    gap: 8px;
  }
}

@media print {
  /* top, right, bottom, left — extra left for 3-hole punch / binder margin */
  @page {
    margin: 12mm 10mm 14mm 22mm;
  }

  html,
  body {
    background: #fff !important;
    color: #111827 !important;
    overflow: visible !important;
  }

  body {
    margin: 0 !important;
    padding: 0 !important;
    font-family: "Helvetica Neue", Arial, sans-serif;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .skip-link,
  .nav,
  .chord-sheet-controls {
    display: none !important;
  }

  .chord-sheet-page,
  .print-page {
    width: auto !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: #fff !important;
  }

  .print-sheet-header {
    gap: 8mm;
    margin: 0 0 5mm;
    padding: 0 0 3mm;
    border-bottom: 0.45mm solid #bfc9d8;
  }

  .print-sheet-logo {
    width: 38mm;
  }

  .print-sheet-brand-copy {
    font-size: 8.5pt;
    letter-spacing: 0.02em;
  }

  .print-sheet-brand-note {
    font-size: 7pt;
    margin-top: 2pt;
  }

  .print-sheet-title-group h2 {
    font-size: 18pt;
    letter-spacing: -0.02em;
  }

  .print-sheet-meta {
    gap: 2mm 4mm;
    margin-top: 2mm;
    font-size: 8.5pt;
  }

  .sheet-mode-tip-print {
    display: block;
    margin: 2.5mm 0 0;
    padding: 0;
    max-width: 118mm;
    margin-left: auto;
    color: var(--sheet-gold);
    font-size: 8.5pt;
    font-weight: 600;
    line-height: 1.35;
    text-align: right;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .print-page[data-instrument="baritone"] .sheet-mode-tip-print {
    color: var(--teal, #2a9db5);
  }

  .family-grid-wrapper {
    overflow: visible;
    padding-bottom: 0;
  }

  .family-grid {
    border-spacing: 1.2mm 1.5mm;
  }

  .family-grid col.family-col-key {
    width: 12mm;
  }

  .family-grid thead {
    display: table-header-group;
  }

  .family-grid tbody {
    display: table-row-group;
  }

  .family-key-heading,
  .family-roman-cell {
    min-height: 7mm;
    padding: 1mm 0.55mm;
    border: 0.35mm solid #c7d0de;
    border-radius: 2.2mm;
    font-size: 9pt;
  }

  .family-roman-cell {
    padding: 1mm 0.3mm;
    line-height: 1.12;
  }

  .family-roman-cell sup {
    font-size: 0.6em;
    line-height: 0;
    vertical-align: super;
  }

  .family-key-cell {
    vertical-align: top;
    padding: 1.4mm 0.45mm;
    border: 0.35mm solid #c7d0de;
    border-radius: 2.2mm;
    font-size: 10pt;
    line-height: 1.12;
    writing-mode: horizontal-tb;
    transform: none;
  }

  .family-key-sig {
    font-size: 7pt;
    margin-top: 2px;
  }

  .progression-key-example-text {
    padding: 0.9mm 1.2mm;
    font-size: 5.5pt;
    line-height: 1.2;
  }

  .family-card {
    min-height: 0;
    height: auto;
    padding: 1.2mm 0.65mm 0.45mm;
    border: 0.35mm solid #c7d0de;
    border-radius: 2.2mm;
  }

  .family-card-cell {
    vertical-align: top;
  }

  .progression-example-row {
    margin-top: -1mm;
  }

  .progression-example-label,
  .progression-example-text {
    min-height: 6mm;
    padding: 1mm 1.2mm;
    border: 0.25mm solid #d4dce8;
    border-radius: 1.8mm;
    font-size: 6.2pt;
  }

  .family-card-header {
    padding: 0 2px 2px;
    gap: 2px;
  }

  .family-chord-name {
    margin-top: 0;
    font-size: 8.5pt;
    font-weight: 800;
  }

  .family-chord-notes {
    font-size: 6pt;
  }

  .chord-diagram-slot {
    min-height: 0;
    margin-top: 0.2mm;
  }

  .chord-diagram {
    width: 17.5mm;
    height: auto;
    flex-shrink: 0;
  }

  .family-card {
    width: 100%;
    height: 34mm;
    box-sizing: border-box;
  }

  .many-root-list {
    gap: 3.5mm;
  }

  .many-root-section {
    grid-template-columns: 12mm minmax(0, 1fr);
    gap: 1.6mm;
    padding: 1.6mm;
    border: 0.35mm solid #c7d0de;
    border-radius: 2.2mm;
  }

  .many-root-heading {
    min-height: 100%;
    border: 0.35mm solid #c7d0de;
    border-radius: 2mm;
    font-size: 10pt;
  }

  .many-group-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.6mm;
  }

  .many-chord-group {
    gap: 1mm;
    padding: 1.2mm;
    border: 0.25mm solid #d4dce8;
    border-radius: 1.8mm;
  }

  .many-chord-group-title {
    font-size: 6.5pt;
  }

  .many-chord-cards {
    grid-template-columns: repeat(auto-fit, minmax(18mm, 1fr));
    gap: 1mm;
  }

  .many-chord-card {
    padding: 1mm 0.45mm 0.35mm;
  }

  .many-chord-quality {
    font-size: 5.3pt;
  }

  .print-page[data-sheet="many"] .family-chord-name {
    font-size: 7.4pt;
  }

  .print-page[data-sheet="many"] .chord-diagram {
    width: 16mm;
  }

  .same-shape-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.5mm;
  }

  .same-shape-card {
    grid-template-columns: 16mm minmax(0, 1fr);
    gap: 1.4mm;
    padding: 1.1mm;
    border: 0.35mm solid #c7d0de;
    border-radius: 2mm;
  }

  .same-shape-card .chord-diagram {
    width: 15mm;
  }

  .same-shape-copy {
    gap: 1mm;
  }

  .same-shape-pattern {
    padding: 0.6mm 1mm;
    font-size: 5.6pt;
  }

  .same-shape-names {
    gap: 0.8mm;
  }

  .same-shape-names span {
    min-height: 4.5mm;
    padding: 0.6mm 1mm;
    font-size: 6pt;
  }

  .movable-family-list {
    gap: 2mm;
  }

  .movable-family-card {
    gap: 1.5mm;
    padding: 1.4mm;
    border: 0.35mm solid #c7d0de;
    border-radius: 2mm;
  }

  .movable-family-header {
    padding: 0.9mm 1.2mm;
    border-radius: 1.8mm;
    font-size: 5.8pt;
  }

  .movable-family-header strong {
    font-size: 7pt;
  }

  .movable-family-name,
  .movable-family-pattern {
    gap: 0.4mm;
  }

  .movable-entry-grid {
    grid-template-columns: repeat(auto-fit, minmax(18mm, 1fr));
    gap: 1mm;
  }

  .movable-entry-card {
    padding: 0.9mm 0.4mm 0.3mm;
  }

  .movable-entry-card .same-shape-pattern {
    margin-top: 0.5mm;
    font-size: 5.4pt;
  }

  .print-page[data-sheet="movable"] .chord-diagram {
    width: 15.5mm;
  }

  .chord-unavailable {
    min-height: 14mm;
    padding: 1.2mm;
    gap: 1mm;
    font-size: 6.5pt;
  }

  .chord-unavailable small {
    font-size: 6pt;
  }

  .sheet-footer {
    margin-top: 5mm;
    padding-top: 4mm;
    font-size: 6.5pt;
    gap: 1.8mm;
    align-items: center;
    text-align: center;
  }

  .sheet-footer-note {
    font-size: 6.25pt;
    line-height: 1.35;
    max-width: 100%;
    font-weight: 500;
    color: #475569 !important;
  }

  .sheet-footer-credit {
    margin-top: 1.5mm;
    font-size: 6pt;
    font-weight: 500;
    color: #64748b !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
}
