/* Approved sound icons, driven only by the existing aria-pressed state.
   Legacy nodes remain available to their controllers; play/voice controls are unchanged.
   Inline SVG masks avoid extra image requests and remain decorative to assistive technology. */
@supports (mask-image: linear-gradient(#000,#000)) or (-webkit-mask-image: linear-gradient(#000,#000)) {
  button:is(#lz-sound,#pack-sound,#reading-sound-toggle,#sound,#sound-toggle,#wx-sound,.pack-audio-toggle,[data-chains-toggle],[data-embers-toggle],[data-forged-sound],[data-harp-toggle],[data-portal-sound],[data-record-sound],[data-relic-sound],[data-resonance-sound],[data-sealed-sound],[data-sound-toggle],#footer-sound)[aria-pressed]:not([hidden]) {
    --rv-audio-glyph: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2024%2024%22%3E%3Cpath%20fill%3D%22none%22%20stroke%3D%22currentColor%22%20stroke-width%3D%221.5%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%20d%3D%22M4%209h4l5-5v16l-5-5H4Zm13%200%205%206m0-6-5%206%22%2F%3E%3C%2Fsvg%3E");
    display:inline-flex;align-items:center;justify-content:center;column-gap:8px;
  }
  button:is(#lz-sound,#pack-sound,#reading-sound-toggle,#sound,#sound-toggle,#wx-sound,.pack-audio-toggle,[data-chains-toggle],[data-embers-toggle],[data-forged-sound],[data-harp-toggle],[data-portal-sound],[data-record-sound],[data-relic-sound],[data-resonance-sound],[data-sealed-sound],[data-sound-toggle],#footer-sound)[aria-pressed]:not([hidden])[aria-pressed="true"] {--rv-audio-glyph: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%2024%2024%22%3E%3Cpath%20fill%3D%22none%22%20stroke%3D%22currentColor%22%20stroke-width%3D%221.5%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%20d%3D%22M4%209h4l5-5v16l-5-5H4Zm13-2c3%203%203%207%200%2010m3-13c5%205%205%2011%200%2016%22%2F%3E%3C%2Fsvg%3E")}
  button:is(#lz-sound,#pack-sound,#reading-sound-toggle,#sound,#sound-toggle,#wx-sound,.pack-audio-toggle,[data-chains-toggle],[data-embers-toggle],[data-forged-sound],[data-harp-toggle],[data-portal-sound],[data-record-sound],[data-relic-sound],[data-resonance-sound],[data-sealed-sound],[data-sound-toggle],#footer-sound)[aria-pressed]:not([hidden])::before {
    content:"";display:inline-block;position:static;inset:auto;flex:0 0 20px;
    width:20px;height:20px;min-width:20px;min-height:20px;margin:0;padding:0;
    border:0;border-radius:0;box-shadow:none;transform:none;opacity:1;
    background:currentColor;vertical-align:middle;pointer-events:none;
    -webkit-mask:var(--rv-audio-glyph) center/contain no-repeat;
    mask:var(--rv-audio-glyph) center/contain no-repeat;
  }
  button:is(#lz-sound,#pack-sound,#reading-sound-toggle,#sound,#sound-toggle,#wx-sound,.pack-audio-toggle,[data-chains-toggle],[data-embers-toggle],[data-forged-sound],[data-harp-toggle],[data-portal-sound],[data-record-sound],[data-relic-sound],[data-resonance-sound],[data-sealed-sound],[data-sound-toggle],#footer-sound)[aria-pressed]:not([hidden]) > :is(svg,[data-embers-icon],[data-harp-icon],[data-chains-icon],.sound-bars,.rv-sound-dot,span[aria-hidden="true"]) {display:none!important}
  /* These atlas controls previously kept a permanently muted icon outside the button. */
  :is(.eh-audio,.rb-sound-wrap,.rl-sound-wrap)>svg {display:none!important}
  @media (forced-colors:active) {
    button:is(#lz-sound,#pack-sound,#reading-sound-toggle,#sound,#sound-toggle,#wx-sound,.pack-audio-toggle,[data-chains-toggle],[data-embers-toggle],[data-forged-sound],[data-harp-toggle],[data-portal-sound],[data-record-sound],[data-relic-sound],[data-resonance-sound],[data-sealed-sound],[data-sound-toggle],#footer-sound)[aria-pressed]:not([hidden])::before {background:CanvasText;forced-color-adjust:none}
  }
}
