.rhythm-page { padding-block:clamp(18px,3.5vw,44px) clamp(32px,5vw,72px); color:#123745; }
.rhythm-back,.rhythm-end a,.rhythm-reference a { color:#195852; text-underline-offset: .2em; }
.rhythm-back { display:inline-block; padding:.45rem 0; }
.rhythm-intro { max-width:78ch; padding:clamp(16px,3vw,36px) 0; }
.rhythm-intro h1 { font:500 clamp(2.6rem,5.6vw,5.8rem)/1.02 Georgia,serif; color:#123944; letter-spacing:-.045em; margin:0 0 .8rem; text-wrap:balance; }
.rhythm-intro p { max-width:61ch; margin:0; line-height:1.55; font-size:clamp(1rem,1.35vw,1.22rem); }
.rhythm-grid { display:grid; grid-template-columns:minmax(0,1.85fr) minmax(0,1fr); gap:clamp(22px,5vw,72px); align-items:start; }
.rhythm-practice[hidden] { display:none; }
.rhythm-practice button { background:#fff; color:#1b464c; border:1px solid #829992; border-radius:5px; min-height:44px; padding:.48rem .9rem; font:inherit; font-weight:600; cursor:pointer; }
.rhythm-practice button[aria-pressed=true] { background:#174e50; border-color:#174e50; color:#fff; }
.rhythm-practice [data-next] { margin-top:.8rem; }
.rhythm-practice button[hidden] { display:none; }
.rhythm-page button:focus-visible,.rhythm-page a:focus-visible { outline:3px solid #bf6817; outline-offset:3px; }
.rhythm-switches,.rhythm-answer > div,[data-marks] { display:flex; flex-wrap:wrap; gap:.5rem; }
.rhythm-switches { margin:0 0 .75rem; }
.rhythm-trace { background:#10323e; color:#e7f4ee; border-radius:12px; padding:clamp(16px,2.4vw,28px); }
.rhythm-trace-head { display:flex; align-items:baseline; justify-content:space-between; flex-wrap:wrap; gap:.35rem .8rem; margin-bottom:1.35rem; }
.rhythm-trace h2,.rhythm-step h2,.rhythm-reference h2 { font:500 clamp(1.45rem,2.3vw,2.25rem)/1.15 Georgia,serif; margin:0; }
.rhythm-trace h2 { color:#fff; }
.rhythm-trace-head span,.rhythm-key { font-size:.9rem; color:#c5deda; }
.rhythm-wave { position:relative; background:#183f49; }
.rhythm-pulses { display:grid; align-items:end; height:4.1rem; overflow:hidden; }
.rhythm-pulses span { height:13%; background:#80a8a2; border-right:1px solid #234e55; box-shadow:inset 0 3px #bfd4cd; }
.rhythm-pulses span.is-lit { height:100%; background:#ccb57a; box-shadow:inset 0 4px #ffe3a1; border-right-color:#718983; }
.rhythm-cursor { position:absolute; top:-5px; bottom:0; left:0; width:2px; transform:translateX(-50%); background:white; box-shadow:0 0 0 1px #17353a; }
.rhythm-cursor::before { content:''; width:8px; height:8px; position:absolute; top:-4px; left:-3px; transform:rotate(45deg); background:white; border:1px solid #17353a; }
.rhythm-axis { display:flex; justify-content:space-between; margin-top:.45rem; font:500 .91rem/1.4 system-ui,sans-serif; font-variant-numeric:tabular-nums; color:#d6e8e3; }
.rhythm-player { display:flex; align-items:center; flex-wrap:wrap; gap:.55rem 1rem; border-top:1px solid #44616a; margin-top:1rem; padding-top:.85rem; }
.rhythm-player button { background:#e6f0ea; color:#173a43; border-color:transparent; }
.rhythm-clock { font-variant-numeric:tabular-nums; }
.rhythm-key { margin-inline-start:auto; }
.rhythm-step { margin:1.55rem 0 1.25rem; }
.rhythm-step h2,.rhythm-reference h2,.rhythm-answer legend { color:#173d46; }
.rhythm-step p,.rhythm-reference p,.rhythm-end p { margin:.55rem 0 .8rem; line-height:1.55; }
.rhythm-answer { min-width:0; padding:0; margin:0; border:0; }
.rhythm-answer legend { padding:0 0 .65rem; font:600 1.05rem/1.4 system-ui,sans-serif; }
.rhythm-answer:disabled button { color:#546365; background:#ebedeb; border-color:#b5c1bd; cursor:default; }
.rhythm-feedback:empty,.rhythm-feedback > p:empty { display:none; }
.rhythm-step .rhythm-feedback:not(:empty),.rhythm-feedback > p:not(:empty) { color:#204a45; background:#e4f0e9; padding:.8rem 1rem; border-left:3px solid #347669; margin:.75rem 0 0; line-height:1.5; }
.rhythm-reference { border-top:2px solid #588278; padding-top:.85rem; min-width:0; }
.rhythm-reference figure { margin:0 0 1.3rem; }
.rhythm-reference img { display:block; width:100%; height:clamp(180px,19vw,300px); object-fit:cover; object-position:50% 49%; border-radius:6px; }
.rhythm-reference figcaption { color:#425a58; font-size:.84rem; line-height:1.45; padding-top:.4rem; }
.rhythm-end { margin-top:clamp(25px,4vw,55px); border-top:1px solid #bdcec7; padding-top:.7rem; }
.rhythm-end p { max-width:83ch; }
.rhythm-end a { display:inline-block; padding-block:.4rem; font-weight:650; }
@media (max-width:760px) {
  .rhythm-grid { grid-template-columns:minmax(0,1fr); }
  .rhythm-key { margin-inline-start:0; }
  .rhythm-reference img { height:clamp(180px,50vw,290px); }
}
@media (forced-colors:active) {
  .rhythm-pulses span { background:GrayText; }
  .rhythm-pulses span.is-lit,.rhythm-cursor { background:Highlight; }
  .rhythm-practice button[aria-pressed=true] { border:3px double Highlight; }
}
