/* Larger reading sizes, text tabs instead of pills, piano, staff, matrix, tool layouts. */
body { font-size: 18px; line-height: 1.65; }
.lede, .hx-lede { font-size: clamp(19px, 1.5vw, 22px); }
.card-copy p, .ch-body p, .panel p { font-size: 16.5px; }
.card-copy h3 { font-size: 21px; }
.nav-more > button, .nav-ask { font-size: 16px; }
.two-tone.big { font-size: clamp(38px, 4.4vw, 58px); max-width: 980px; }
.note-line { color: var(--slate); font-size: 16px; margin-top: 18px; max-width: 820px; }

/* no pills: tabs and quick picks are plain text with an underline when active */
.chip, .subnav a, .dark .chip { background: none !important; box-shadow: none !important; border-radius: 0 !important; padding: 6px 0 !important; border-bottom: 2px solid transparent !important; color: var(--slate) !important; font: 500 16px var(--body) !important; }
.chip:hover, .subnav a:hover { color: #fff !important; border-bottom-color: rgba(255,255,255,.25) !important; }
.chip[aria-pressed="true"] { color: #fff !important; border-bottom-color: #a78bfa !important; }
.chips, .subnav { gap: 10px 28px !important; }
.subnav { margin-top: 36px; border-bottom: 1px solid var(--line); padding-bottom: 0; }

/* tool layout */
.tool-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 28px; margin-top: 44px; align-items: start; }
.tool-head { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; margin-bottom: 18px; }
.tool-head > span { font: 600 18px var(--body); color: #fff; }
.tool-head .select { width: auto; min-width: 280px; font-size: 16px; padding: 11px 40px 11px 14px; }
.tool-side h3 { font-size: 22px; margin-bottom: 8px; }
.big-p { font-size: 17px; }
.fig { padding: 18px 0; border-top: 1px solid var(--line); }
.fig:first-child { border-top: 0; padding-top: 0; }
.fig b { display: block; font-size: clamp(28px, 2.6vw, 38px); font-weight: 500; letter-spacing: -0.03em; color: #fff; line-height: 1.1; margin-bottom: 6px; }
.fig span { color: var(--slate); font-size: 16px; line-height: 1.5; display: block; }

/* note picker */
.ni-staff { background: rgba(255,255,255,.02); border-radius: 10px; padding: 8px 4px 0; overflow-x: auto; }
.staff { width: 100%; height: auto; display: block; min-width: 560px; }
.staff .nh.on ellipse { fill: #a78bfa; }
.ni-count { color: var(--slate); font-size: 15.5px; margin: 12px 2px 16px; }
.ni-piano { position: relative; display: grid; grid-template-columns: repeat(7, 1fr); height: 170px; gap: 3px; user-select: none; }
.pk { position: relative; border: 0; cursor: pointer; font: 600 15px var(--body); display: flex; align-items: flex-end; justify-content: center; padding-bottom: 12px; transition: background .12s, transform .08s; }
.pk:active { transform: translateY(1px); }
.pk.w { background: linear-gradient(#f7f3ec, #e9e2d6); color: #3d3557; border-radius: 0 0 8px 8px; box-shadow: inset 0 -5px 0 rgba(0,0,0,.08); }
.pk.w:hover { background: linear-gradient(#fff, #f1ebe1); }
.pk.b { position: absolute; top: 0; width: 6.4%; height: 60%; background: linear-gradient(#2a2340, #120c22); color: #cfc7e6; border-radius: 0 0 6px 6px; z-index: 2; font-size: 12px; box-shadow: 0 4px 8px rgba(0,0,0,.45); }
.pk.b:hover { background: linear-gradient(#3b3159, #1d1535); }
.pk.used.w { background: linear-gradient(#b99cf2, #8b5cf6); color: #fff; }
.pk.used.b { background: linear-gradient(#8b5cf6, #6d42d6); color: #fff; }
.ni-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 18px; }
.ni-actions .btn { font-size: 15.5px; padding: 12px 18px; }
.ni-actions .btn:disabled { opacity: .45; cursor: default; }

/* nine groups */
.win-cards { margin-top: 28px; }
.win-title { font-size: 22px; margin: 32px 0 6px; }
.win-list { border-top: 1px solid var(--line); }
.win { display: grid; grid-template-columns: 40px 200px 1fr 220px; gap: 20px; align-items: center; padding: 16px 0; border-bottom: 1px solid var(--line); }
.win-n { font: 500 15px var(--mono); color: var(--faint); }
.win-notes { font: 500 19px var(--mono); color: #fff; letter-spacing: .02em; white-space: pre; }
.win-what b { display: block; font-weight: 600; font-size: 17px; }
.win-what span { color: var(--slate); font-size: 15px; }
.win-key { color: var(--slate); font-size: 15px; text-align: right; }
.win.t1 .win-what b { color: #c4b5fd; } .win.t2 .win-what b { color: #a78bfa; } .win.t3 .win-what b { color: #d9d3ea; } .win.t4 .win-what b, .win.t5 .win-what b { color: #8f87ad; }
.win.t1 .win-notes { color: #c4b5fd; }

/* melody list */
.mel-list { margin-top: 10px; border-top: 1px solid var(--line); max-height: 360px; overflow-y: auto; }
.mel-row { display: flex; justify-content: space-between; gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 16px; }
.mel-row span { font: 500 16px var(--mono); color: #fff; white-space: pre; }
.mel-row b { font-weight: 600; font-size: 15px; }

/* matrix, musictheory.net layout as a clean ruled table */
.mx-bar { display: flex; justify-content: space-between; align-items: end; gap: 20px; flex-wrap: wrap; margin-bottom: 22px; }
.mx-sel b { font-size: 40px; font-weight: 500; letter-spacing: -0.03em; color: #fff; }
.mx-sel b sub { font-size: 20px; }
.mx-sel span { display: block; color: var(--slate); font-size: 16px; }
.mx-tog { display: flex; gap: 24px; }
.mx-scroll { overflow-x: auto; }
.mx-table { border-collapse: collapse; margin: 0 auto; font: 500 17px var(--mono); }
.mx-table td { width: 52px; height: 46px; text-align: center; color: var(--ink-2); border: 1px solid rgba(255,255,255,.07); }
.mx-table td.diag { color: #fff; }
.mx-table td.hot { background: rgba(167,139,250,.22); color: #fff; }
.mx-table th { padding: 0; }
.mx-lab { width: 52px; height: 40px; border: 0; background: none; color: var(--slate); font: 600 15px var(--body); cursor: pointer; }
.mx-lab sub { font-size: 11px; }
.mx-lab:hover { color: #fff; }
.mx-lab.on { color: #fff; text-decoration: underline; text-decoration-color: #a78bfa; text-decoration-thickness: 2px; text-underline-offset: 6px; }
.mx-empty { color: var(--slate); }
.mx-staff { margin-top: 28px; border-top: 1px solid var(--line); padding-top: 20px; }

@media (max-width: 900px) {
  .tool-grid { grid-template-columns: 1fr; }
  .win { grid-template-columns: 30px 1fr; } .win-what, .win-key { grid-column: 2; text-align: left; }
  .ni-piano { height: 140px; }
}

/* composition page */
.gen-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 44px; }
.gen { text-align: left; background: #1c1435; border: 0; border-radius: 12px; padding: 26px; cursor: pointer; color: inherit; font: inherit; box-shadow: 0 0 0 1px rgba(255,255,255,.08); transition: box-shadow .2s, transform .2s; }
.gen:hover { transform: translateY(-3px); box-shadow: 0 0 0 1px rgba(167,139,250,.45), 0 30px 60px -30px rgba(0,0,0,.7); }
.gen b { display: block; color: #fff; font-size: 20px; font-weight: 600; margin-bottom: 8px; }
.gen span { color: var(--slate); font-size: 16px; line-height: 1.5; }
.hex-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; padding-bottom: 18px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.hex-pair small { display: block; color: var(--slate); font-size: 14px; }
.hex-pair b { font: 500 22px var(--mono); color: #fff; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px 48px; margin-top: 48px; }
.step b { display: block; color: #fff; font-size: 21px; font-weight: 600; margin-bottom: 10px; padding-top: 18px; border-top: 2px solid #a78bfa; }
.step p { color: var(--slate); font-size: 17px; line-height: 1.6; margin: 0; }
@media (max-width: 900px) { .gen-grid, .steps { grid-template-columns: 1fr; } }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
