/* music.css: Songwright "Our Music" cards, typographic covers and the one player.
   G.R.A.C.E. for D.E.A.N., 2026-10-29, key grace-sw-music-1029. Loaded once per page by partials/song-card.php,
   after songwright.css. Uses the design-contract tokens with fallbacks and defines no :root tokens.
   One light theme: nothing here changes a color under prefers-color-scheme. */

/* ---------- page head (/listen/ only) ---------- */
.swm-page .swm-shead{max-width:62ch}
.swm-page .swm-shead h1{font-family:var(--sw-display,'Cormorant Garamond',Georgia,serif);font-weight:600;font-size:clamp(2.6rem,6vw,4.2rem);line-height:1.02;letter-spacing:-.01em;color:var(--sw-forest,#152321);margin:.25rem 0 .55rem}
.swm-lead{font-family:var(--sw-display,'Cormorant Garamond',Georgia,serif);font-weight:500;font-style:italic;font-size:clamp(1.35rem,2.6vw,1.7rem);line-height:1.3;color:var(--sw-forest,#152321);margin:0 0 .7rem}
.swm-section .swm-intro{font-size:1rem;color:var(--sw-muted,#555C58);margin:.6rem auto 0}

/* ---------- occasion filter chips (all songs show by default) ---------- */
#listen.swm-section .sw-filter{min-height:44px;padding:.55rem 1.05rem;border:1px solid var(--sw-line,rgba(183,154,104,.40));background:transparent;color:var(--sw-charcoal,#373E3A);border-radius:999px;font:500 .9rem/1.1 var(--sw-body,'Inter',system-ui,sans-serif);letter-spacing:.02em}
#listen.swm-section .sw-filter:hover{border-color:var(--sw-champagne-ink,#7A623A);color:var(--sw-forest,#152321)}
#listen.swm-section .sw-filter.is-active{background:var(--sw-forest,#152321);color:var(--sw-ivory,#F3EEE5);border-color:var(--sw-forest,#152321)}
#listen.swm-section .sw-filter:focus-visible{outline:2px solid var(--sw-champagne-ink,#7A623A);outline-offset:2px}
.swm-count{text-align:center;font-size:.88rem;color:var(--sw-muted,#555C58);letter-spacing:.02em;margin:-.5rem 0 1.6rem}

/* ---------- the list ---------- */
.swm-section .sw-order{max-width:940px}
.swm-section .sw-songs{display:grid;gap:1.4rem}

/* ---------- one card ---------- */
.swm-section .swm-card{display:grid;grid-template-columns:minmax(0,240px) minmax(0,1fr);grid-template-areas:"cover head" "cover body";column-gap:2rem;align-items:start;background:var(--sw-ivory-2,#FAF7F1);border:1px solid var(--sw-line,rgba(183,154,104,.40));border-radius:2px;padding:1.8rem;box-shadow:none;transition:border-color var(--sw-dur,.24s)}
.swm-section .swm-card:hover,.swm-section .swm-card.is-playing{border-color:var(--sw-champagne,#B79A68)}
.swm-cover{grid-area:cover;width:100%;aspect-ratio:1/1;line-height:0;border:1px solid var(--sw-line,rgba(183,154,104,.40));background:var(--sw-forest,#152321)}
.swm-g-ivory .swm-cover{background:var(--sw-ivory,#F3EEE5)}
.swm-g-charcoal .swm-cover{background:var(--sw-charcoal,#373E3A)}
.swm-cover .swm-art{display:block;width:100%;height:100%}
.swm-head{grid-area:head;min-width:0}
.swm-body{grid-area:body;min-width:0}

.swm-card .occ{display:inline-block;font:600 .74rem/1.3 var(--sw-body,'Inter',system-ui,sans-serif);letter-spacing:.16em;text-transform:uppercase;color:var(--sw-champagne-ink,#7A623A);margin:0 0 .35rem}
.swm-card .swm-title{font-family:var(--sw-display,'Cormorant Garamond',Georgia,serif);font-weight:600;font-size:clamp(1.6rem,2.6vw,2.1rem);line-height:1.08;color:var(--sw-forest,#152321);margin:0 0 .3rem}
.swm-card .sub{font-family:var(--sw-display,'Cormorant Garamond',Georgia,serif);font-style:italic;font-weight:500;font-size:1.2rem;line-height:1.35;color:var(--sw-charcoal,#373E3A);margin:0 0 .5rem}
.swm-story{font-family:var(--sw-body,'Inter',system-ui,sans-serif);font-size:1rem;line-height:1.7;color:var(--sw-charcoal,#373E3A);margin:.25rem 0 1rem;max-width:var(--sw-measure,66ch)}

/* ---------- the player (custom control over native <audio preload="metadata">) ---------- */
.swm-player[hidden]{display:none !important}
.swm-player{display:flex;align-items:center;gap:.8rem;margin:.1rem 0 .9rem;padding:.4rem .95rem .4rem .4rem;border:1px solid var(--sw-line,rgba(183,154,104,.40));border-radius:999px;background:var(--sw-ivory,#F3EEE5)}
.swm-play{flex:0 0 44px;width:44px;height:44px;padding:0;border:0;border-radius:50%;background:var(--sw-forest,#152321);color:var(--sw-ivory,#F3EEE5);display:inline-flex;align-items:center;justify-content:center;cursor:pointer;transition:background var(--sw-dur,.24s),color var(--sw-dur,.24s)}
.swm-play:hover{background:var(--sw-forest-2,#1E322E);color:var(--sw-champagne-soft,#D9C7A3)}
.swm-play:focus-visible{outline:2px solid var(--sw-champagne-ink,#7A623A);outline-offset:3px}
.swm-play svg{width:20px;height:20px;fill:currentColor;display:block}
.swm-i-pause{display:none !important}
.swm-card.is-playing .swm-i-play{display:none !important}
.swm-card.is-playing .swm-i-pause{display:block !important}
.swm-card.is-loading .swm-play{opacity:.72}
.swm-bar{position:relative;flex:1 1 auto;min-width:0;height:44px}
.swm-rail{position:absolute;left:0;right:0;top:50%;height:3px;margin-top:-1.5px;background:var(--sw-line,rgba(183,154,104,.40));border-radius:2px;overflow:hidden;pointer-events:none}
.swm-fill{height:100%;width:0;background:var(--sw-champagne-ink,#7A623A)}
.swm-seek{position:absolute;left:0;top:0;width:100%;height:44px;margin:0;padding:0;background:transparent;-webkit-appearance:none;appearance:none;cursor:pointer}
.swm-seek::-webkit-slider-runnable-track{height:44px;background:transparent;border:0}
.swm-seek::-webkit-slider-thumb{-webkit-appearance:none;appearance:none;width:14px;height:14px;margin-top:15px;border-radius:50%;background:var(--sw-forest,#152321);border:2px solid var(--sw-ivory,#F3EEE5)}
.swm-seek::-moz-range-track{height:44px;background:transparent;border:0}
.swm-seek::-moz-range-thumb{width:11px;height:11px;border-radius:50%;background:var(--sw-forest,#152321);border:2px solid var(--sw-ivory,#F3EEE5)}
.swm-seek:focus{outline:none}
.swm-seek:focus-visible{outline:2px solid var(--sw-champagne-ink,#7A623A);outline-offset:-6px;border-radius:6px}
.swm-time{flex:0 0 auto;font:500 .85rem/1 var(--sw-body,'Inter',system-ui,sans-serif);font-variant-numeric:tabular-nums;color:var(--sw-muted,#555C58);white-space:nowrap}
.swm-sep{margin:0 .3rem}
.swm-card audio.swm-native-off{display:none}

/* ---------- details, credit, links ---------- */
.swm-card .style{font-size:.88rem;line-height:1.5;color:var(--sw-muted,#555C58);letter-spacing:.02em}
.swm-card .credit{font-size:.86rem;line-height:1.5;color:var(--sw-muted,#555C58);margin-top:.35rem}
.swm-card .swm-links{display:flex;flex-wrap:wrap;align-items:center;gap:0 .7rem;margin:.45rem 0 0}
.swm-card .swm-links a{display:inline-flex;align-items:center;min-height:44px;margin:0;font:600 .9rem/1.2 var(--sw-body,'Inter',system-ui,sans-serif);letter-spacing:.02em;color:var(--sw-champagne-ink,#7A623A);text-decoration:none}
.swm-card .swm-links a:hover{color:var(--sw-forest,#152321);text-decoration:underline;text-underline-offset:3px}
.swm-card .swm-rights::after,.swm-card .swm-links .license::after{content:" \2192";white-space:pre}
.swm-dot{color:var(--sw-champagne-ink,#7A623A)}
.swm-card .swm-production{font-size:.86rem;line-height:1.5;color:var(--sw-muted,#555C58);margin-top:.15rem}
.swm-card details{margin-top:.6rem;border-top:1px solid var(--sw-line,rgba(183,154,104,.40));padding-top:0}
.swm-card summary{display:flex;align-items:center;min-height:44px;font:600 .92rem/1.3 var(--sw-body,'Inter',system-ui,sans-serif);color:var(--sw-forest,#152321);cursor:pointer;list-style:none}
.swm-card summary::before{content:"+";display:inline-block;width:1.15em;color:var(--sw-champagne-ink,#7A623A);font-weight:600}
.swm-card details[open] > summary::before{content:"\2013"}
.swm-card summary:focus-visible{outline:2px solid var(--sw-champagne-ink,#7A623A);outline-offset:2px}
.swm-card .sw-lic-body p{font-size:.95rem;line-height:1.65;color:var(--sw-charcoal,#373E3A);margin:.2rem 0 .7rem}
.swm-card .sw-lic-body a{color:var(--sw-champagne-ink,#7A623A);font-weight:600}
/* lyrics: line breaks and the copyright stamp also on the home "Selected" block, where #listen rules do not reach */
.swm-section .sw-lyrics{font-family:Verdana,Roboto,"Segoe UI",Tahoma,Arial,sans-serif;font-size:.95rem;line-height:1.65;white-space:pre-line;color:var(--sw-charcoal,#373E3A)}
.swm-selected .sw-lyrics-copyright{font:600 .76rem/1.55 system-ui,Arial,sans-serif;color:#6b5a2e;background:rgba(196,160,82,.10);border:1px solid rgba(196,160,82,.34);border-radius:8px;padding:.6rem .8rem;margin:.1rem 0 .95rem}
.swm-selected .sw-lyrics-copyright-foot{margin:.95rem 0 .1rem;color:var(--sw-champagne-ink,#7A623A);background:none;border:0;border-top:1px solid rgba(0,0,0,.10);border-radius:0;padding:.7rem 0 0;font-weight:500}
.swm-section .sw-video-local{max-width:420px}

/* ---------- home "Selected Compositions" ---------- */
.swm-selected .swm-more{margin-top:2rem;display:flex;flex-wrap:wrap;gap:.8rem;justify-content:center}
.swm-selected .swm-more-note{margin-top:.8rem;font-size:.95rem;color:var(--sw-muted,#555C58)}
.swm-selected .swm-more-note a{color:var(--sw-champagne-ink,#7A623A);font-weight:600}
@media (min-width:1100px){
  .swm-selected .sw-order{max-width:1160px}
  .swm-selected .sw-songs{grid-template-columns:repeat(2,minmax(0,1fr));align-items:start}
  .swm-selected .swm-card{grid-template-columns:minmax(0,160px) minmax(0,1fr);column-gap:1.5rem;padding:1.5rem}
}

/* ---------- smaller screens ---------- */
@media (max-width:860px){
  .swm-section .swm-card{grid-template-columns:minmax(0,180px) minmax(0,1fr);column-gap:1.4rem;padding-top:1.5rem;padding-bottom:1.5rem}
  /* same widget-safe gutter J.U.N.E. set for #listen (2026-10-04), so the home block clears the ADA and back-to-top buttons too */
  .swm-selected .swm-card{padding-left:55px;padding-right:55px}
}
@media (max-width:640px){
  .swm-section .swm-card{grid-template-columns:104px minmax(0,1fr);grid-template-areas:"cover head" "body body";column-gap:1rem;row-gap:.9rem}
  .swm-head{align-self:center}
  .swm-card .swm-title{font-size:1.4rem}
  .swm-card .sub{font-size:1.02rem;margin-bottom:0}
  .swm-player{gap:.6rem;padding-right:.75rem}
  .swm-time{font-size:.8rem}
  .swm-card .swm-links{flex-direction:column;align-items:flex-start}
  .swm-dot{display:none}
}
@media (max-width:560px){ .swm-selected .swm-card{padding-right:43px} }
@media (max-width:480px){ .swm-selected .swm-card{padding-left:41px} }
@media (max-width:400px){ .swm-section .swm-card{grid-template-columns:88px minmax(0,1fr)} }
@media (prefers-reduced-motion:reduce){ .swm-section .swm-card,.swm-play{transition:none} }
