/* An engraved room of string, skin and reeds. All play surfaces are native buttons. */
.session-room {
  --room-paper: #f0ead6;
  --room-ink: #19251f;
  --stage-lime: #d7ed8b;
  --brass: #c8b784;
  background: #302b22;
  color: var(--room-paper);
  font-family: var(--body);
}
.room-width { width: min(1260px, calc(100% - clamp(36px, 8vw, 144px))); margin-inline: auto; }
.session-room :is(figure, h1, h2, p) { margin: 0; }
.session-room button, .session-room select { font: inherit; }
.session-room button { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.session-room :is(button,a,select,input):focus-visible { outline: 3px solid #f8db79; outline-offset: 3px; box-shadow: 0 0 0 5px #25372c; }
.room-intro {
  isolation: isolate; position: relative;
  border-bottom: 5px solid #b59a65;
  background: radial-gradient(ellipse at 90% -18%,#75815a 0,transparent 65%),#1c3028;
}
.room-intro::before {
  content: ''; position: absolute; z-index: -1; inset: 0; opacity: .7; pointer-events: none;
  background: repeating-linear-gradient(105deg,transparent 0 88px,#d7e2ac0a 89px 107px,transparent 109px 165px), url('assets/session/grain.svg');
}
.room-intro::after {
  content: ''; position: absolute; z-index:-1; inset-block:0; pointer-events:none;
  width:clamp(150px,17vw,232px);
  right:calc(max((100% - 1260px) / 2,4vw) + clamp(190px,18vw,250px) + 1.4vw);
  background: url('assets/session/microphone.svg') left top / contain no-repeat;
}
.room-intro-inner {
  display: grid; grid-template-columns: minmax(0,1fr) minmax(190px, 250px); gap: clamp(1.2rem, 6vw, 6rem);
  align-items: center; padding-block: clamp(1.65rem, 3.5vw, 3.5rem);
}
.room-label, .sound-cap h2, .tempo-select, .beat-display, .instrument-menu, .session-volume {
  font: 700 .71rem/1.4 var(--body); letter-spacing: .095em; text-transform: uppercase;
}
.room-label { display: flex; align-items: center; gap: .65rem; color: var(--stage-lime); }
.room-label::before { content: ''; width: 2.2rem; height: 2px; background: #ddb079; }
.session-bill h1 {
  margin: .12em 0 .14em;
  font: 800 clamp(4.25rem, 7.7vw, 8.1rem)/.82 var(--display);
  text-transform: uppercase; letter-spacing: -.035em;
}
.session-bill h1 em { color: var(--stage-lime); font-style: normal; }
.session-bill > p:last-child { max-width: 53ch; margin-top: 1.1rem; color: #e0e2cb; font-size: clamp(.95rem, 1.25vw, 1.15rem); line-height: 1.46; }

.sound-desk {
  position: relative; padding: 1rem 1.15rem;
  border: 1px solid #405446; border-radius: 4px;
  color: #eae6d3; background: linear-gradient(170deg,#38423a,#222b25);
  box-shadow: inset 0 1px #79816e, 3px 4px 0 #0f1913;
}
.sound-cap { display: flex; align-items: center; justify-content: space-between; padding-bottom: .75rem; }
.sound-cap h2 { font-size: .72rem; }
.sound-led { width: .48rem; height: .48rem; background: #85917c; border-radius: 50%; box-shadow: 0 0 0 2px #172219; }
.sound-desk:has([data-session-sound][aria-pressed="false"]) .sound-led { background: #cfea73; box-shadow: 0 0 8px #bad677, 0 0 0 2px #172219; }
.sound-power {
  width: 100%; min-height: 44px; display: flex; justify-content: center; align-items: center; gap: .75rem;
  border: 1px solid #bdbb8e; border-radius: 3px;
  box-shadow: inset 0 1px #f8f4bd, inset 0 -3px #a8a77c, 1px 3px 0 #18251b;
  background: #d9e5a2; color: #18271b;
}
.sound-power [data-session-label] { font-size: .89rem; font-weight: 750; }
.power-mark { position: relative; width: .9rem; height: .9rem; border: 1.65px solid currentColor; border-top-color: transparent; border-radius: 100%; }
.power-mark::before { content: ''; position: absolute; inset: -2px 4px 4px; border-left: 1.65px solid currentColor; }
.sound-power:active, .sound-power[aria-pressed=true] { transform: translateY(1px); box-shadow: inset 0 1px 3px #7d8766; }
.session-volume { display: flex; align-items: center; gap: .7rem; padding-top: .65rem; font-size: .63rem; }
.session-volume input { min-width: 0; width: 100%; height: 30px; margin: 0; accent-color: #c2bb89; cursor: pointer; }
.studio-floor {
  background-color: #3b3328;
  background-image: url('assets/session/grain.svg'), repeating-linear-gradient(91deg,#a389604a 0 1px,transparent 1px 61px,#201f1488 61px 62px,transparent 62px 66px),linear-gradient(160deg,#675744,#383227 72%);
}
.session-rack { padding-block: clamp(1.25rem,2.5vw,2.5rem); }
.loop-desk {
  position: relative; isolation: isolate; display: grid; align-items: center;
  grid-template-columns: minmax(120px, .85fr) minmax(340px,2.3fr) auto minmax(68px,.5fr);
  gap: .6rem clamp(1rem,2.8vw,2.8rem);
  padding: 1rem clamp(1rem, 2.2vw, 2.2rem) .75rem;
  border: 2px solid #302c21; border-radius: 5px;
  background: linear-gradient(145deg,#e1dcc5,#c9c6ac 80%,#b8b79d);
  color: #232b21; box-shadow: inset 0 1px 0 #fff5d8, inset 0 -3px #b1a98b, 3px 4px 0 #27251a;
  scroll-margin-top: .8rem;
}
.loop-desk::before, .station::before {
  content: ''; position: absolute; inset: 6px; z-index: -1; pointer-events:none;
  background:
    radial-gradient(circle at 3px 3px,#4f513f 0 1px,#c7c2a6 1.3px 2.3px,#32382c 2.5px 2.9px,transparent 3.2px),
    radial-gradient(circle at calc(100% - 3px) 3px,#4f513f 0 1px,#c7c2a6 1.3px 2.3px,#32382c 2.5px 2.9px,transparent 3.2px),
    radial-gradient(circle at calc(100% - 3px) calc(100% - 3px),#4f513f 0 1px,#c7c2a6 1.3px 2.3px,#32382c 2.5px 2.9px,transparent 3.2px),
    radial-gradient(circle at 3px calc(100% - 3px),#4f513f 0 1px,#c7c2a6 1.3px 2.3px,#32382c 2.5px 2.9px,transparent 3.2px);
}
.loop-ident { display: flex; align-items: center; gap: .55rem; }
.loop-ident h2 { font: 750 clamp(1.55rem, 2.4vw,2.55rem)/.94 var(--display); letter-spacing: -.025em; text-transform: uppercase; }
.spool-mark { display: inline-flex; padding-bottom: 2px; border-bottom: 1.5px solid; }
.spool-mark i { height: .7rem; width: .7rem; border: 1.5px solid; border-radius: 50%; background: radial-gradient(circle,#58634e 0 1.6px,transparent 2px); }
.transport { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: .3rem; }
.transport button {
  display: flex; flex-direction: column; justify-content: center; align-items: center; gap: .34rem;
  min-height: 47px; padding: .4rem .15rem .5rem; border: 1px solid #7d806a; border-radius: 3px;
  background: linear-gradient(#f4f0db,#e2dfc7 80%,#cfccb6); color: #253124; box-shadow: inset 0 1px #fff9e5, 0 2px #898c72;
  font: 700 .78rem/1.15 var(--body);
}
.transport button:disabled { color: #666756; background: #d6d3be; box-shadow: inset 0 1px #e6e3ce; cursor: default; }
.transport button:not(:disabled):hover,.sound-power:hover { filter: brightness(1.045); }
.transport button:active:not(:disabled),.transport button[aria-pressed=true] { transform: translateY(1.5px); box-shadow: inset 0 1px 3px #a7a38d; }
.transport i { width: 9px; height: 9px; display: block; }
.transport .transport-record { border-radius: 50%; background: #a34432; }
.transport .transport-play { width: 0; height: 0; border: solid transparent; border-width: 5px 0 5px 8px; border-left-color: currentColor; }
.transport .transport-layer { border: 1px solid; box-shadow: 2px 2px; width: 8px; height: 7px; }
.transport .transport-stop { background: currentColor; }
.transport .transport-clear { border: 1.4px solid; border-left-color: transparent; border-radius: 50%; position: relative; }
.transport-clear::before { position: absolute; content: ''; top:-2px; left:-1px; border: solid transparent; border-width: 2px 3px 2px 0; border-right-color: currentColor; transform: rotate(-30deg); }
.tempo-select { display: grid; gap: .1rem; font-size:.62rem; }
.tempo-select select { padding:.3rem .15rem; color:#20291d; min-height: 33px; border:0; border-bottom:1px solid #5e6652; background:transparent; font:700 .85rem/1.2 var(--body); }
.beat-display { text-align:right; font-size:.64rem; letter-spacing:.05em; }
.beat-lamps { display:flex; justify-content:flex-end; gap: .3rem; margin-top:.4rem; }
.beat-lamps i { display:block; width: .68rem; height:.35rem; border:1px solid #77745c; background:#979781; border-radius:1px; }
.beat-lamps i[data-active] { background:#c4db69; border-color:#344936; box-shadow: 0 0 5px #c5d781; }
.session-room[data-mode=recording] .transport-record,.session-room[data-mode=overdub] .transport-layer { box-shadow: 0 0 0 2px #f8d3ba, 0 0 0 3px #b27854; }
.session-status { grid-column:1/-1; border-top:1px solid #a4a68d; padding-top: .45rem; font-size:.78rem; line-height:1.4; }
.instrument-menu {
  display:flex; justify-content:flex-end; gap:1.1rem; align-items:center; padding-block:.55rem .35rem;
  color:#eee7ce; font-size:.63rem;
}
.instrument-menu a { display:inline-flex; min-height:36px; align-items:center; border-bottom:1px solid transparent; }
.instrument-menu a:hover { border-color:#dcc999; }
.stations { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:clamp(.8rem,1.65vw,1.65rem); }
.station {
  --station-ink:#f0e7d2; --station-edge:#897f62; --station-top:#4a5846; --station-base:#273e34;
  position:relative; isolation:isolate; min-width:0; color:var(--station-ink);
  border:2px solid #28271c; border-radius:4px;
  background: url('assets/session/grain.svg'), linear-gradient(135deg,var(--station-top),var(--station-base) 85%);
  box-shadow: inset 0 1px var(--station-edge), inset 0 -3px #17251b66, 3px 4px 0 #242319;
  scroll-margin-top: .8rem;
}
.station:target { outline:2px solid #e5d287; outline-offset:3px; }
.station-label {
  display:flex; justify-content:space-between; align-items:baseline; gap:.7rem;
  margin:clamp(.9rem,2vw,1.6rem) clamp(1rem,3vw,2rem) 0;
  padding-bottom:.45rem; border-bottom:1px solid color-mix(in srgb,var(--station-ink) 38%,transparent);
}
.station-label h2 { font:800 clamp(1.95rem,3.1vw,3.8rem)/.94 var(--display); text-transform:uppercase; letter-spacing:-.026em; }
.station-label span { font:italic 500 clamp(.87rem,1.25vw,1.18rem)/1.2 Georgia,serif; white-space:nowrap; }
.station-art { position:relative; width:100%; aspect-ratio:600/220; }
.station-art img,.station-art svg { display:block; width:100%; height:100%; }
.string-art,.chord-art { margin-top:.1rem; }
.live-strings { position:absolute; inset:0; pointer-events:none; }
.live-strings path { fill:none; stroke:#f7f7b3; stroke-width:2.8; stroke-linecap:round; opacity:0; }
.station:has([data-session-note="0"][data-active]) .resonance-0,
.station:has([data-session-note="1"][data-active]) .resonance-1,
.station:has([data-session-note="2"][data-active]) .resonance-2,
.station:has([data-session-note="3"][data-active]) .resonance-3,
.station:has([data-session-note="4"][data-active]) .resonance-4,
.station:has([data-session-note="5"][data-active]) .resonance-5 { opacity:1; }
.string-rail, .chord-keys { display:grid; gap:2px; margin:0 clamp(.9rem,2.2vw,1.65rem) 1.05rem; }
.string-rail { padding:3px; background:#242d24; border-radius:3px; box-shadow:0 1px #b1ae8c; }
.guitar-rail { grid-template-columns:repeat(6,minmax(0,1fr)); }
.bass-rail,.chord-keys { grid-template-columns:repeat(4,minmax(0,1fr)); }
.string-key,.chord-key {
  min-height:46px; border:0; border-radius:1px; display:flex; justify-content:center; align-items:baseline;
  gap:.1em; padding:.45rem .15rem; line-height:1; color:#19271c;
}
.string-key {
  box-shadow:inset 0 1px #faf5d9, inset 0 -3px #a6a081;
  background: linear-gradient(110deg,transparent 70%,#9f9b7430 72%,transparent 74%), linear-gradient(#e5dfc1,#cec8aa);
}
.string-key > span,.chord-key > span { font:800 1.65rem/1.1 var(--display); }
.string-key small { font:650 .68rem/1 var(--body); }
.string-key[data-active],.chord-key[data-active] { background:#d5e99b; box-shadow:inset 0 3px 4px #78815f; transform:translateY(1px); }
.string-key:hover:not([data-active]),.chord-key:hover:not([data-active]) { background:#f1eace; }
.kit-station { --station-top:#c19a6d; --station-base:#a88057; --station-ink:#27281e; --station-edge:#e3be87; display:flex; flex-direction:column; }
.kit-art { margin-block:auto; }
.kit-hit {
  position:absolute; display:grid; place-items:center; transform:translate(-50%,-50%);
  min-width:44px; min-height:44px; width:var(--surface); height:var(--depth);
  border:0; border-radius:50%; background:transparent; color:#17271d;
}
.kit-hit span { font:750 clamp(.67rem,1.2vw,.88rem)/1.1 var(--body); padding:.25em .42em; background:#e8dfbded; border-radius:2px; }
.kit-hit[data-active],.kit-hit:active { background:#e8ef9b8c; box-shadow:inset 0 0 0 2px #f6edb8; }
.kit-hit:hover:not([data-active]) span { background:#faf2cc; }
.hit-kick { left:48.3%; top:56%; --surface:24%; --depth:51%; }
.hit-snare { left:22.8%; top:63.6%; --surface:17.9%; --depth:41%; }
.hit-hat { left:14.8%; top:30%; --surface:19%; --depth:27%; }
.hit-floor { left:70.5%; top:62.3%; --surface:17.5%; --depth:39%; }
.hit-ride { left:85.3%; top:27.7%; --surface:22%; --depth:32%; }
.bass-station { --station-top:#475550; --station-base:#263837; --station-ink:#e8e1c9; --station-edge:#859486; }
.chord-station { --station-top:#a2aa86; --station-base:#859675; --station-ink:#182c22; --station-edge:#c7cea6; }
.chord-keys { gap:3px; background:#332e23; padding:4px 4px 5px; box-shadow:0 2px 0 #635846; margin-top:-.3rem; }
.chord-key {
  position:relative; align-items:center; gap:.22em; padding:.46rem .18rem;
  background:linear-gradient(#d3cdb9,#f8f2dd 58%,#e9e4cf); box-shadow:inset 0 -3px #c0b7a2; border-radius:0 0 3px 3px;
}
.chord-key small { font:650 clamp(.58rem,1vw,.8rem)/1 var(--body); }
.room-exit { display:flex; justify-content:space-between; align-items:center; margin-top:1.1rem; color:#ece9d7; }
.room-exit a { display:inline-flex; align-items:center; gap:.5rem; min-height:44px; font-size:.84rem; font-weight:650; }
.room-exit a:hover { text-decoration:underline; }
.session-noscript { padding-block:1rem; }
@media(max-width:960px) {
  .loop-desk { grid-template-columns:1fr auto auto; gap:.65rem 1rem; }
  .loop-ident { grid-column:1; }
  .transport { grid-column:1/4; grid-row:2; }
  .tempo-select { grid-column:2; grid-row:1; display:flex; align-items:center; gap:.5rem; }
  .beat-display { grid-column:3; grid-row:1; }
  .room-intro-inner { grid-template-columns:minmax(0,1fr) minmax(170px,210px); }
  .room-intro::after { right:25%; width:100px; opacity:.75; }
  .session-bill { z-index:1; }
}
@media(max-width:700px) {
  .stations { grid-template-columns:1fr; gap:1.1rem; }
  .kit-art { margin-block:.45rem .8rem; }
  .station-label { padding-bottom:.5rem; }
}
@media(max-width:560px) {
  .room-width { width:calc(100% - 28px); }
  .room-intro::after { inset:0 0 auto auto; width:60px; height:62px; opacity:.9; }
  .room-intro-inner { display:block; padding-block:1.4rem; }
  .session-bill h1 { font-size:clamp(3.35rem,12.8vw,4.5rem); margin:.19em 0 .13em; }
  .session-bill > p:last-child { margin-top:.65rem; max-width:42ch; }
  .sound-desk { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:.5rem .75rem; align-items:center; margin-top:1.1rem; padding:.68rem .75rem; }
  .sound-cap { grid-column:1/-1; padding:0; }
  .sound-power { min-height:44px; gap:.45rem; }
  .session-volume { padding:0; gap:.4rem; }
  .session-volume input { height:36px; }
  .session-rack { padding-block:1rem; }
  .loop-desk { padding:.85rem .7rem .65rem; gap:.5rem .45rem; }
  .loop-ident h2 { font-size:1.34rem; }
  .spool-mark { display:none; }
  .tempo-select { gap:.35rem; }
  .tempo-select select { min-height:37px; font-size:.75rem; }
  .beat-display { max-width:4.7rem; font-size:.56rem; }
  .beat-lamps { gap:3px; }
  .transport { gap:3px; }
  .transport button { min-height:45px; font-size:.69rem; }
  .session-status { font-size:.75rem; }
  .instrument-menu { justify-content:space-around; gap:.4rem; padding:.4rem 0; }
  .instrument-menu a { min-height:36px; }
  .station-label { margin:.95rem 1rem 0; }
  .station-label h2 { font-size:2.1rem; }
}
@media(max-width:360px) {
  .guitar-rail { margin-inline:.32rem; }
  .loop-ident h2 { font-size:1.18rem; }
  .tempo-select { display:grid; gap:0; font-size:.55rem; }
  .tempo-select select { min-height:30px; }
  .station-label h2 { font-size:1.9rem; }
}
@media(prefers-reduced-motion:no-preference) {
  .string-key, .chord-key, .sound-power { transition:transform .08s ease,box-shadow .08s ease; }
  .station:has([data-active]) .live-strings path { animation:room-pluck .16s ease-out; }
  @keyframes room-pluck { 0% { transform:translateY(0); } 30% { transform:translateY(-1.9px); } 67% { transform:translateY(1.2px); } 100% { transform:translateY(0); } }
}


.station-monitor {
  display:flex; align-items:center; gap:.55rem;
  margin:.27rem clamp(1rem,3vw,2rem) 0;
}
.station-monitor button {
  display:inline-flex; align-items:center; gap:.36rem; min-height:44px;
  padding:.12rem .3rem; border:0; color:inherit; background:transparent;
  font:650 .73rem/1.2 var(--body);
}
.station-monitor button:first-child { padding-left:0; }
.station-monitor .power-mark { width:.68rem; height:.68rem; border-width:1.5px; }
.station-monitor .power-mark::before { inset:-1.6px 3px 3px; border-width:1.5px; }
.station-monitor [aria-pressed=true] { text-decoration:underline; text-underline-offset:3px; }
.monitor-stop i { width:7px; height:7px; background:currentColor; }
.station-monitor button:disabled { opacity:.60; cursor:default; }
/* A sideways brush plays the strings. A vertical swipe anywhere on the
   instrument remains a page scroll, and pinch-to-zoom stays available. */
[data-session-strings], .string-rail, .session-room .string-rail button { touch-action: pan-y pinch-zoom; }
.live-strings {
  pointer-events: auto;
  touch-action: pan-y pinch-zoom;
  cursor: crosshair;
  clip-path: polygon(12% 48%, 85% 34%, 85% 52%, 12% 69%);
}
@media(max-width:760px) and (min-width:561px) { .room-intro::after { display:none; } }

/* Keep the bill on its printed line while the condensed heading face downloads.
   The zero in the supplied Barlow Condensed 800 face measures 0.456 em. */
@media (min-width: 900px) {
  @supports (font-size-adjust: ch-width .456) {
    .session-bill h1 { white-space: nowrap; font-size-adjust: ch-width .456; }
  }
}
