.hero-actions { gap: .7rem; }
.hero-listen { border-color: #f4f3ef66; background: #111d; }
.hero-listen:hover, .hero-listen:focus-visible { border-color: var(--accent); color: var(--accent); }

.sub-secondary { min-height: 44px; }
.directory-lead { max-width: 34ch; color: #51483b; margin-top: 1rem; }
.native-player-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 17rem), 1fr)); gap: .75rem; }
.native-player { display: flex; flex-direction: column-reverse; gap: .55rem; padding: .85rem; border: 1px solid var(--rule); }
.native-player a { display: inline-flex; align-items: center; justify-content: space-between; min-height: 44px; color: var(--accent); }
.native-player audio { width: 100%; }

.portfolio-piece:not(.featured-piece) { display: grid; grid-template-columns: minmax(0,.85fr) minmax(0,1fr); align-items: start; gap: .75rem 1rem; }
.portfolio-piece .piece-image .section-icon { position: absolute; inset: auto auto .6rem .6rem; width: 2rem; height: 2rem; padding: .38rem; color: var(--accent); background: #111e; border: 1px solid #f4f3ef55; }
.portfolio-piece .piece-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem .85rem; margin-top: .9rem; }
.piece-actions .piece-action { min-height: 44px; min-width: 5.2rem; margin-top: 0; border: 1px solid #272017; }
.piece-actions .piece-action:hover, .piece-actions .piece-action:focus-visible { background: var(--accent); color: var(--ink); }
.piece-action .piece-pause, .piece-action .piece-resume { display: none; }
.piece-action[data-preview-state] .piece-play { display: none; }
.piece-action[data-preview-state='playing'] .piece-pause, .piece-action[data-preview-state='paused'] .piece-resume { display: inline; }
.piece-action[data-preview-state='playing'] { background: var(--accent); color: var(--ink); }
.piece-action[data-preview-state='playing'] .play-triangle { width: 8px; height: 9px; border: 0; border-inline: 2px solid currentColor; }
.piece-context { display: inline-flex; align-items: center; gap: .45rem; min-height: 44px; color: #554024; font-size: .86rem; text-underline-offset: .23em; }
.piece-context:hover { text-decoration: underline; }

.comparison-cues { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: .8rem 1.5rem; padding: 0; margin: clamp(1.25rem,3vw,2.4rem) 0 0; }
.comparison-cues > div { border-top: 1px solid var(--rule); padding-top: .8rem; }
.comparison-cues dt { color: var(--accent); font: 700 1rem/1.3 var(--display); }
.comparison-cues dd { margin: .35rem 0 0; color: var(--muted); font-size: .9rem; line-height: 1.55; max-width: 37ch; }

@media (max-width: 920px) {
  .portfolio-piece:not(.featured-piece) { grid-template-columns: minmax(0,1fr); }
}
@media (max-width: 680px) {
  .comparison-cues { grid-template-columns: minmax(0,1fr); }
  .comparison-cues > div { display: grid; grid-template-columns: minmax(4.7rem,.48fr) minmax(0,1fr); gap: .65rem; }
  .comparison-cues dd { margin: 0; }
  .portfolio-piece .piece-image img { aspect-ratio: 1.65; }
}

.page-sections { border-block: 1px solid var(--rule); background: #1d1915; }
.page-sections-inner { display: flex; align-items: center; gap: clamp(1rem, 4vw, 4.3rem); }
.page-sections p { flex: none; color: var(--muted); font: .72rem/1.4 var(--mono); text-transform: uppercase; }
.page-sections ul { flex: 1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); list-style: none; padding: 0; margin: 0; }
.page-sections li { display: grid; border-inline-start: 1px solid var(--rule); }
.page-sections li:last-child { border-inline-end: 1px solid var(--rule); }
.page-sections a { display: flex; align-items: center; justify-content: space-between; gap: .8rem; padding: .9rem clamp(.8rem, 2vw, 1.65rem); min-height: 58px; font: 700 1rem/1.22 var(--display); }
.page-sections a span { flex: none; color: var(--accent); }
.page-sections a:hover, .page-sections a:focus-visible { color: var(--accent); background: #2d2415; }
.page-sections a:focus-visible { outline-offset: -3px; }
.page-sections a[aria-current="location"] {
  color: var(--accent);
  background: #2d2415;
  box-shadow: inset 0 -2px var(--accent);
}
.next-grid nav a > span:first-child { display: flex; align-items: center; gap: .75rem; }
.next-grid nav .section-icon, .footer-entry .section-icon { width: 1rem; height: 1rem; color: var(--accent); }

@media (min-width: 981px) and (min-height: 660px) {
  html:has(.page-sections) { scroll-padding-top: calc(var(--header-height) + 64px); }
  .page-sections { position: sticky; top: var(--header-height); z-index: 3; }
  .page-sections ~ .listening { scroll-margin-top: 0; }
}

.footer-main { grid-template-areas: "identity pages entry"; }
.footer-entry { grid-area: entry; }
.footer-entry a { display: flex; align-items: center; gap: .6rem; min-height: 44px; color: var(--muted); font-size: .9rem; line-height: 1.28; }
.footer-entry li + li { border-top: 1px solid var(--rule); }
.footer-entry a:hover, .footer-entry a:focus-visible { color: var(--accent); }
.footer-nav a { min-height: 44px; }
.footer-bottom a { min-height: 44px; display: inline-flex; align-items: center; gap: .38rem; }

.fallback-menu { display: none; }
@media (max-width: 980px) {
  .menu-toggle, .head-listen { min-height: 44px; }
  .fallback-menu { display: block; padding: .5rem var(--gutter-right) .5rem var(--gutter-left); border-bottom: 1px solid var(--rule); }
  .fallback-menu summary, .fallback-menu a { min-height: 44px; align-content: center; }
  .fallback-menu a { display: block; border-top: 1px solid var(--rule); }
  .fallback-menu a[aria-current='page'] { color: var(--accent); }
}

@media (max-width: 680px) {
  .page-sections-inner { display: block; padding-block: .75rem; }
  .page-sections p { padding-bottom: .45rem; }
  .page-sections ul { border-block-start: 1px solid var(--rule); }
  .page-sections a { align-items: flex-start; min-height: 52px; gap: .25rem; padding: .65rem .5rem; font-size: .84rem; }
  .page-sections li:first-child { border-inline-start: 0; }
  .page-sections li:last-child { border-inline-end: 0; }
  .sub-copy { padding-bottom: 2.5rem; }
  .sub-copy .back-link { margin-bottom: clamp(2.5rem, 9vw, 4.4rem); }
  .footer-main { grid-template-areas: "identity identity" "pages entry"; grid-template-columns: minmax(0,1.05fr) minmax(0,1fr); }
  .footer-entry a { font-size: .81rem; }
}

@media (max-width: 380px) {
  .hero-actions .button { font-size: .87rem; gap: .45rem; padding-inline: .6rem; }
  .hero-actions .listen-icon { width: 1.05rem; height: 1.05rem; }
  .footer-entry a { gap: .38rem; }
  .footer-entry .section-icon { width: .88rem; height: .88rem; }
}

@media (orientation: landscape) and (max-width: 980px) and (max-height: 500px) {
  html { --nav-height: 52px; }
  .sub-hero { min-height: 0; }
  .sub-copy { padding-block: 1rem 1.35rem; }
  .sub-copy .back-link { margin-bottom: .25rem; }
  .sub-copy .signal-label { display: inline-flex; margin-inline-start: .85rem; }
  .sub-hero .sub-image { left: 26%; }
  .sub-hero h1 {
    max-width: 15ch;
    margin-top: .6rem;
    font-size: clamp(2.55rem, 6.5vw, 4.4rem);
  }
  .sub-hero .hero-description { max-width: 47ch; margin-top: .72rem; }
  .sub-actions { margin-top: .85rem; gap: .45rem 1rem; }
  .sub-actions .button { min-height: 44px; padding: .58rem .78rem; }
  .page-sections-inner { gap: .65rem; }
  .page-sections a { min-height: 48px; }
}

@media (orientation: landscape) and (max-width: 980px) and (max-height: 360px) {
  .sub-copy { padding-block: .6rem 1rem; }
  .sub-hero .hero-description { font-size: .94rem; }
}

@media (orientation: landscape) and (540px <= width <= 980px) and (max-height: 500px) {
  .mobile-nav-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: clamp(.65rem, 2vw, 1.2rem);
  }
  .mobile-nav a, .mobile-nav a + a {
    min-height: 49px;
    padding-block: .35rem;
    border-top: 0;
    border-bottom: 1px solid var(--rule);
  }
  .mobile-nav .mobile-nav-listen { grid-column: 1 / -1; }
}
