.rhythm { padding-block: 80px 55px; --rhythm-text: #514e48; }
.rhythm-heading { display: grid; grid-template-columns: 1.15fr 1fr; gap: 64px; align-items: end; margin-bottom: 39px; }
.rhythm .eyebrow { color: var(--rhythm-text); font-size: 12px; margin-bottom: 18px; }
.rhythm-heading h2 { font-size: clamp(38px, 4.5vw, 56px); }
.rhythm-heading > p { font-size: 18px; line-height: 1.55; color: var(--rhythm-text); padding-bottom: 3px; }
.rhythm-grid { display: grid; grid-template-columns: 1fr 1fr; border-block: 1px solid var(--rule); padding-block: 30px 26px; }
.rhythm-card { min-width: 0; padding-right: 38px; }
.rhythm-card + .rhythm-card { padding-left: 38px; padding-right: 0; border-left: 1px solid var(--rule); }
.rhythm-label { display: flex; align-items: center; gap: 13px; margin-bottom: 23px; }
.rhythm-label p { font: 12px/1.5 var(--mono); letter-spacing: .09em; text-transform: uppercase; color: var(--rhythm-text); }
.rhythm-label .rhythm-icon { width: 32px; height: 32px; flex: 0 0 32px; color: var(--orange); }
.rhythm-card h3 { font-size: clamp(21px, 2vw, 26px); min-height: 1.15em; text-wrap: balance; }
.rhythm-description { color: var(--rhythm-text); font-size: 16px; line-height: 1.55; min-height: 3.1em; margin-top: 9px; max-width: 420px; }
.rhythm-timeline { --edge: 52px; position: relative; height: 124px; margin-top: 28px; font: 12px/1.5 var(--mono); text-transform: uppercase; letter-spacing: .025em; }
.timeline-track { position: absolute; top: 40px; left: var(--edge); right: var(--edge); height: 1px; background: var(--rule); }
/* A permanent rule keeps the diagram readable throughout the motion cycle. */
.timeline-progress { position: absolute; inset: -1px 0; height: 3px; overflow: hidden; pointer-events: none; }
.timeline-fixed .timeline-progress { left: 50%; }
.timeline-progress::before { content: ""; position: absolute; inset: 1px 0; background: #736d63; transform: scaleX(0); transform-origin: left; }
.timeline-progress::after { content: ""; position: absolute; top: 0; left: 0; width: 20%; height: 3px; border-radius: 2px; background: linear-gradient(90deg, transparent, #514e48); opacity: 0; transform: translateX(-100%); }
.timeline-check { position: absolute; inset: 0; width: 100%; height: 100%; stroke: var(--paper); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.timeline-check path { stroke-dasharray: 1; stroke-dashoffset: 0; }
.timeline-rolling .event-now .timeline-dot { width: 18px; height: 18px; top: -9px; left: -9px; }
.event-next .timeline-date::after { content: ""; position: absolute; inset: auto 0 -5px; height: 1px; background: #736d63; transform: scaleX(0); transform-origin: left; opacity: 0; }
.timeline-event { position: absolute; top: 40px; left: var(--edge); width: 0; height: 0; }
.timeline-fixed .event-now { left: 50%; }
.timeline-event.event-next { left: auto; right: var(--edge); }
.timeline-dot { position: absolute; top: -6px; left: -6px; width: 12px; height: 12px; border-radius: 50%; background: var(--paper); border: 1.5px solid #736d63; outline: 4px solid var(--paper); }
.event-past .timeline-dot { background: #736d63; }
.event-now .timeline-dot { border-color: var(--orange); background: var(--orange); }
.timeline-date, .timeline-caption { position: absolute; left: 0; transform: translateX(-50%); white-space: nowrap; }
.timeline-date { top: 18px; }
.timeline-caption { bottom: 21px; color: var(--rhythm-text); }
.timeline-interval { position: absolute; top: 1px; left: 50%; transform: translateX(-50%); color: var(--rhythm-text); white-space: nowrap; }
.timeline-footnote { position: absolute; top: 95px; left: 0; right: 0; text-align: center; font-size: 11px; color: var(--rhythm-text); letter-spacing: .035em; }
.rhythm-footer { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding-top: 14px; }
.rhythm-footer .text-link { margin-left: auto; min-height: 44px; }
/* The two diagrams take turns, with no disappearing text or layout movement. */
.rhythm-motion-toggle { display: inline-flex; align-items: center; gap: 9px; min-height: 44px; min-width: 132px; padding: 0; border: 0; background: none; color: var(--rhythm-text); font-size: 12px; cursor: pointer; }
.rhythm-motion-toggle[hidden] { display: none; }
.rhythm-motion-toggle svg { width: 17px; height: 17px; }
.rhythm-motion-toggle .motion-play-icon, .rhythm-motion-toggle.is-paused .motion-pause-icon { display: none; }
.rhythm-motion-toggle.is-paused .motion-play-icon { display: block; }
.rhythm-motion-toggle:hover { color: var(--ink); }
.rhythm-motion-toggle:focus-visible { outline: 2px solid var(--orange); outline-offset: 4px; border-radius: 2px; }
.rhythm-card { --cycle: 7.2s; --phase: 0s; }
.rhythm-rolling { --phase: 3.6s; }
.rhythm-playing .event-now .timeline-dot { animation: rhythm-origin var(--cycle) var(--phase) ease-in-out infinite both; }
.rhythm-playing .timeline-progress::before { animation: rhythm-connect var(--cycle) var(--phase) cubic-bezier(.4,0,.2,1) infinite both; }
.rhythm-playing .timeline-progress::after { animation: rhythm-beam var(--cycle) var(--phase) cubic-bezier(.4,0,.2,1) infinite both; }
.rhythm-playing .event-next .timeline-dot { animation: rhythm-arrive var(--cycle) var(--phase) ease-in-out infinite both; }
.rhythm-playing .event-next .timeline-date::after { animation: rhythm-confirm var(--cycle) var(--phase) ease-in-out infinite both; }
.rhythm-playing .timeline-check path { animation: rhythm-check var(--cycle) var(--phase) ease-in-out infinite both; }
.rhythm-paused *, .rhythm-paused *::before, .rhythm-paused *::after { animation-play-state: paused !important; }
@keyframes rhythm-origin {
  0%, 8%, 26%, 100% { transform: scale(1); box-shadow: 0 0 0 0 #ff3b1f00; }
  15% { transform: scale(1.12); box-shadow: 0 0 0 7px #ff3b1f18; }
  25% { transform: scale(1); box-shadow: 0 0 0 11px #ff3b1f00; }
}
@keyframes rhythm-connect {
  0%, 14% { transform: scaleX(0); opacity: 0; }
  17% { opacity: .65; }
  43%, 58% { transform: scaleX(1); opacity: .65; }
  68%, 100% { transform: scaleX(1); opacity: 0; }
}
@keyframes rhythm-beam {
  0%, 14% { transform: translateX(-100%); opacity: 0; }
  17% { opacity: 1; }
  41% { opacity: 1; }
  44%, 100% { transform: translateX(500%); opacity: 0; }
}
@keyframes rhythm-arrive {
  0%, 40%, 68%, 100% { transform: scale(1); background: var(--paper); box-shadow: 0 0 0 0 #736d6300; }
  45% { transform: scale(1.12); background: #736d63; box-shadow: 0 0 0 5px #736d6312; }
  51%, 59% { transform: scale(1); background: #736d63; box-shadow: 0 0 0 8px #736d6300; }
}
@keyframes rhythm-confirm {
  0%, 43% { transform: scaleX(0); opacity: 0; }
  50%, 59% { transform: scaleX(1); opacity: .65; }
  68%, 100% { transform: scaleX(1); opacity: 0; }
}
@keyframes rhythm-check {
  0%, 8% { stroke-dashoffset: 1; opacity: 0; }
  10% { opacity: 1; }
  19%, 61% { stroke-dashoffset: 0; opacity: 1; }
  68%, 100% { stroke-dashoffset: 0; opacity: 0; }
}
@media (max-width: 950px) {
  .rhythm-heading { gap: 32px; }
  .rhythm-heading > p { font-size: 16px; }
  .rhythm-card { padding-right: 26px; }
  .rhythm-card + .rhythm-card { padding-left: 26px; }
  .rhythm-card h3 { min-height: 2.3em; }
  .rhythm-timeline { --edge: 42px; font-size: 11px; }
  .rhythm-description { font-size: 15px; }
}
@media (max-width: 700px) {
  .rhythm { padding-block: 49px 34px; }
  .rhythm-heading { display: block; margin-bottom: 28px; }
  .rhythm .eyebrow { font-size: 11px; margin-bottom: 16px; }
  .rhythm-heading h2 { font-size: clamp(34px, 9vw, 48px); }
  .rhythm-heading > p { margin-top: 21px; max-width: 370px; font-size: 16px; }
  .rhythm-grid { grid-template-columns: 1fr; padding-block: 0; }
  .rhythm-card, .rhythm-card + .rhythm-card { padding: 26px 0 23px; border-left: 0; }
  .rhythm-card + .rhythm-card { border-top: 1px solid var(--rule); }
  .rhythm-label { margin-bottom: 16px; }
  .rhythm-label p { font-size: 11px; }
  .rhythm-card h3 { font-size: 23px; min-height: 0; }
  .rhythm-description { font-size: 16px; min-height: 0; margin-top: 11px; }
  .rhythm-timeline { --edge: 49px; margin-top: 20px; height: 113px; font-size: 12px; }
  .rhythm-footer { gap: 16px; }
  .rhythm-footer .text-link { font-size: 12px; gap: 10px; }
  .rhythm-motion-toggle { font-size: 11px; gap: 6px; min-width: 118px; }
  .rhythm-rolling { --phase: 0s; }
}
@media (max-width: 360px) {
  .rhythm-timeline { font-size: 11px; --edge: 43px; }
  .rhythm-card h3 { font-size: 22px; }
  .rhythm-footer { gap: 9px; }
}
@media (prefers-reduced-motion: reduce) {
  .rhythm-motion-toggle { display: none; }
  .rhythm-playing *, .rhythm-playing *::before, .rhythm-playing *::after { animation: none !important; }
}
