/* Study audio on the notch: ⟲10 ▶ ⟳10 (conceptual/tutor/study_audio.js,
   Seth 2026-10-26). Sits between the clock and the ⋯ button, sized like the
   pause sign so the tab grows by three small buttons and nothing jumps. */

.practice-notch-audio {
  align-items: center;
  border-left: 1px solid var(--border);
  display: inline-flex;
  gap: 2px;
  margin-left: 2px;
  padding-left: 6px;
}

.practice-notch-audio[hidden] {
  display: none;
}

.practice-notch-audio-btn {
  align-items: baseline;
  background: transparent;
  border: 0;
  border-radius: 6px;
  color: var(--muted);
  cursor: pointer;
  display: inline-flex;
  font: inherit;
  font-size: 15px;
  font-weight: 700;
  justify-content: center;
  line-height: 1;
  min-height: 24px;
  min-width: 24px;
  padding: 3px 4px;
  transition: background 120ms ease, color 120ms ease;
}

.practice-notch-audio-btn small {
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  margin-left: 1px;
}

.practice-notch-audio-btn:hover,
.practice-notch-audio-btn:focus-visible {
  background: var(--surface);
  color: var(--text);
}

/* ▶, and ‖ while it plays: the pause sign's own shapes (notch-menu.css). */
.practice-notch-audio-btn.is-play {
  align-items: center;
}

.practice-notch-audio-glyph {
  border-bottom: 5px solid transparent;
  border-left: 9px solid currentColor;
  border-top: 5px solid transparent;
  box-sizing: border-box;
  display: block;
  height: 10px;
  margin-left: 2px;
  width: 9px;
}

.practice-notch-audio-btn.is-playing .practice-notch-audio-glyph {
  border: 0;
  border-left: 3px solid currentColor;
  border-right: 3px solid currentColor;
  margin-left: 0;
  width: 9px;
}

.practice-notch-audio-btn.is-playing {
  color: var(--text);
}

.practice-notch-audio-btn.is-loading .practice-notch-audio-glyph {
  animation: study-audio-wait 900ms ease-in-out infinite;
}

@keyframes study-audio-wait {
  50% { opacity: 0.3; }
}

@media (prefers-reduced-motion: reduce) {
  .practice-notch-audio-btn.is-loading .practice-notch-audio-glyph {
    animation: none;
    opacity: 0.5;
  }
}

/* Settings: Autoplay greys out while Study audio is off (settings-page.js). */
#page-settings .settings-choose.is-disabled {
  opacity: 0.55;
}
