/* The music workspace (Release room), Flaptown Design v5 (2026-11-08). Loads after /v5/flaptown-v5.css and /music/music.css.
   A milled side plate with the release list in a list pocket; each part of the editor is a panel; fields are milled into
   raised plates; the status bar is a pocket with a lamp and a status word (DONE / WORKING / FAILED, set by workspace.js). */

.ws-intro { margin: 0 0 25px; }
.ws-intro h1 { margin: 0 0 10px; }
.ws-bar { position: sticky; top: 0; z-index: 4; margin: 0 0 25px; padding: 12px 18px; border-radius: 10px; }
.ws-bar .status { margin: 0; min-height: 25px; overflow-wrap: anywhere; }
.ws-bar .status:empty { display: flex; }
.label-owner { display: flex; flex-wrap: wrap; align-items: center; gap: 5px 12px; margin: 0 0 25px; }
.label-owner a { display: inline-flex; align-items: center; min-height: 44px; }
#login { margin: 0 0 30px; }

.workspace-grid { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 25px; align-items: start; }
.ws-side { position: sticky; top: 80px; display: grid; gap: 15px; padding: 20px 15px; border-radius: 12px;
  box-shadow: inset 0 1px 0 #c9bab014, inset 1px 0 0 #c9bab00a, inset 0 -1px 0 #00000099, 0 2px 0 #000, 0 10px 24px #00000080; }
.ws-side .key { width: 100%; }
.side-head { margin: 5px 0 -5px; }
.ws-side .lp > .sc { max-height: 360px; min-height: 64px; }
.release-item { display: block !important; text-align: left; overflow-wrap: anywhere; }
.release-item.active { background: var(--plate-hi); box-shadow: 0 1px 0 #000, 0 2px 4px #000000b3, inset 0 1px 0 #c9bab01f, inset 2px 0 0 var(--clay); }
#releases:empty::before { content: "No releases yet."; padding: 10px; color: var(--dusty); font-size: 13px; }
.muted { margin: 0; font-size: 13px; line-height: 20px; color: var(--dusty); }
.drawer { border-top: 1px solid var(--mocha); padding-top: 10px; font-size: 13px; line-height: 20px; }
.drawer summary { display: flex; align-items: center; gap: 10px; min-height: 44px; cursor: pointer; list-style: none; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--rose); }
.drawer summary::-webkit-details-marker { display: none; }
.drawer summary::before { content: ""; width: 7px; height: 7px; border-right: 1.5px solid var(--clay); border-bottom: 1.5px solid var(--clay); transform: rotate(-45deg); transition: transform .3s var(--ease); }
.drawer[open] summary::before { transform: rotate(45deg); }
.drawer p { margin: 0 0 8px; color: var(--rose); }

.ws-editor { display: grid; gap: 20px; min-width: 0; margin: 0; }
.ws-editor form { display: grid; gap: 20px; }
.ws-editor .panel { padding: 25px; }
.ws-editor .sec-head { margin: 0 0 15px; }
.ws-head .section-bar { display: flex; align-items: center; justify-content: space-between; gap: 15px; flex-wrap: wrap; }
.ws-head h2 { margin: 0; overflow-wrap: anywhere; }
.ws-head #public-link { margin: 10px 0 0; overflow-wrap: anywhere; }
.ws-head #public-link:empty { display: none; }
.state-chip { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 6px; background: var(--pocket); color: var(--done);
  font-size: 11px; line-height: 16px; letter-spacing: .08em; text-transform: uppercase; box-shadow: inset 0 2px 5px -1px #000000e6, inset 0 -1px 0 var(--mocha); }
.state-chip::before { content: ""; width: 7px; height: 7px; border-radius: 999px; background: radial-gradient(circle at 35% 35%, #e3e6f6 0%, #9ea3c8 55%, #3e4158 100%); box-shadow: 0 0 0 1.5px #050606, 0 0 6px 1px #9ea3c899; }
.state-chip:empty { display: none; }
.fine { color: var(--dusty); font-size: 13px; line-height: 20px; max-width: 760px; }
.ws-editor h4, .publication h4 { font-size: 15px; line-height: 25px; margin: 20px 0 10px; color: var(--oak); }

/* fields: milled into a raised plate */
.fields { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 15px 20px; padding: 20px; border-radius: 10px; background: var(--plate-hi);
  box-shadow: inset 0 1px 0 #c9bab01f, 0 2px 0 #000, 0 8px 18px #000000b3; }
.fields + .check, .fields + p { margin-top: 15px; }
.wide { grid-column: 1 / -1; }
.ws-editor label, .publication label.field-label, .fields label { display: grid; gap: 8px; align-content: start; font-size: 12px; line-height: 16px; letter-spacing: .08em; text-transform: uppercase; color: var(--rose); }
#editor label input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]), #editor label textarea, #editor label select, #approval-section select { width: 100%; font-size: 15px; line-height: 25px; letter-spacing: 0; text-transform: none; }
.ws-editor label textarea { min-height: 100px; }
.field-label { margin: 15px 0; }
input[type=file] { padding: 8px 10px; }
input[type=file]::file-selector-button { font: inherit; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--oak); margin-right: 12px; padding: 6px 12px; border-radius: 6px; cursor: pointer;
  background: #3e415866; border: 1.5px solid #3e4158; box-shadow: 0 2px 0 #000; }
.ws-editor label.check, .publication label.check, .checks label { display: flex; align-items: center; gap: 12px; min-height: 44px; font-size: 13px; line-height: 20px; letter-spacing: 0; text-transform: none; color: var(--oak); cursor: pointer; }
.checks { display: grid; gap: 2px; margin: 0 0 10px; }
.checks.row { display: flex; flex-wrap: wrap; gap: 0 25px; }
.checks > p { color: var(--dusty); font-size: 13px; margin: 0; }
/* recessed squares; the tick draws in */
.ws-editor input[type=checkbox], .publication input[type=checkbox] { -webkit-appearance: none; appearance: none; flex: none; display: grid; place-items: center; width: 20px; height: 20px; margin: 0; cursor: pointer;
  border-radius: 4px; background: var(--pocket); border: 1px solid #000; border-bottom-color: var(--mocha); box-shadow: inset 0 2px 4px #000000e6; }
.ws-editor input[type=checkbox]::after, .publication input[type=checkbox]::after { content: ""; width: 10px; height: 5px; margin-top: -3px; border-left: 2px solid var(--oak); border-bottom: 2px solid var(--oak);
  transform: rotate(-45deg) scale(0); transition: transform .18s var(--ease); }
.ws-editor input[type=checkbox]:checked::after, .publication input[type=checkbox]:checked::after { transform: rotate(-45deg) scale(1); }
.ws-editor input[type=checkbox]:checked, .publication input[type=checkbox]:checked { border-color: #a46f6799; }
fieldset { margin: 0 0 10px; padding: 10px 15px 5px; border: 1px solid var(--mocha); border-radius: 8px; }
legend { padding: 0 6px; color: var(--rose); }

/* files */
.upload-row { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 15px; padding: 20px; border-radius: 10px; background: var(--plate-hi); box-shadow: inset 0 1px 0 #c9bab01f, 0 2px 0 #000, 0 8px 18px #000000b3; }
.upload-row label { flex: 1 1 200px; min-width: 0; }
progress { -webkit-appearance: none; appearance: none; display: block; width: 100%; height: 10px; margin: 15px 0 0; border: 0; border-radius: 999px; background: var(--pocket); box-shadow: inset 0 2px 3px #000, inset 0 -1px 0 var(--mocha); overflow: hidden; }
progress::-webkit-progress-bar { background: var(--pocket); border-radius: 999px; box-shadow: inset 0 2px 3px #000; }
progress::-webkit-progress-value { background: var(--rose2); border-radius: 999px; }
progress::-moz-progress-bar { background: var(--rose2); border-radius: 999px; }
.assets-pocket { margin: 20px 0; }
#assets { list-style: none; margin: 0; }
#assets:empty { display: none; }
#assets li { display: flex; flex-wrap: wrap; align-items: center; gap: 5px 10px; min-height: 52px; padding: 6px 6px 6px 14px; border-radius: 3px; background: var(--plate);
  font-size: 13px; line-height: 20px; box-shadow: 0 1px 0 #000, 0 2px 4px #000000b3, inset 0 1px 0 #c9bab012; overflow-wrap: anywhere; }
#assets li a { flex: 1 1 200px; color: var(--oak); }
#assets li span { color: var(--dusty); }
#assets li button { margin-left: auto; }
.cover-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 20px; align-items: start; }
.cover-frame { display: block; padding: 5px; border-radius: 10px; }
.cover-frame .window { width: 160px; aspect-ratio: 1; }
.cover-frame:has(img[hidden]) .window::before { content: "No cover chosen"; position: absolute; inset: 0; display: grid; place-items: center; padding: 10px; text-align: center; color: var(--dusty); font-size: 11px; letter-spacing: .04em; }
.review-cover { display: block; width: 100%; height: 100%; object-fit: cover; }

/* every button the editor draws is a key */
.ws-editor button:not(.key), .ws-editor a.button { --c: var(--dim); --f: #3e415833; display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 44px; padding: 0 16px;
  border-radius: 6px; cursor: pointer; color: var(--oak); font-size: 12px; line-height: 16px; letter-spacing: .08em; text-transform: uppercase; text-shadow: var(--carve);
  background: var(--f); border: 1.5px solid color-mix(in srgb, var(--c) 70%, transparent); box-shadow: 0 3px 0 #000, 0 6px 14px #00000099, inset 0 1px 0 #c9bab00f;
  transition: background-color .14s ease, border-color .14s ease, transform .08s ease, box-shadow .08s ease; }
.ws-editor button:not(.key):hover { border-color: var(--c); }
.ws-editor button:not(.key):active { transform: translateY(2px); box-shadow: 0 1px 0 #000; }
.ws-editor button:disabled { opacity: .38; cursor: default; transform: none; }
.actions { display: flex; flex-wrap: wrap; gap: 15px; align-items: center; margin: 20px 0 0; }

/* tracks: each a raised plate */
#tracks { display: grid; gap: 15px; margin: 0 0 20px; }
.track-edit { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 15px 20px; padding: 20px; border-radius: 10px; background: var(--plate-hi);
  box-shadow: inset 0 1px 0 #c9bab01f, 0 2px 0 #000, 0 8px 18px #000000b3; }
.track-edit h4 { grid-column: 1 / -1; margin: 0; font-size: 12px; line-height: 16px; letter-spacing: .08em; text-transform: uppercase; color: var(--clay); }
.track-edit audio { grid-column: 1 / -1; width: 100%; height: 44px; margin: 0; border-radius: 8px; color-scheme: dark; filter: invert(.9) sepia(.25) hue-rotate(-10deg); }
.track-edit .actions { grid-column: 1 / -1; margin: 0; }

.sub-plate { margin: 20px 0 0; padding: 20px; border-radius: 10px; background: var(--plate-hi); box-shadow: inset 0 1px 0 #c9bab01f, 0 2px 0 #000, 0 8px 18px #000000b3; }
.sub-plate h4 { margin-top: 0; }
.sub-plate .fields { padding: 0; background: none; box-shadow: none; }
.todo { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 6px; }
.todo:empty { display: none; }
.todo li { position: relative; padding-left: 22px; font-size: 13px; line-height: 20px; color: var(--oak); }
.todo li::before { content: ""; position: absolute; left: 2px; top: 6px; width: 7px; height: 7px; border-radius: 999px; background: radial-gradient(circle at 35% 35%, #fbe6c2, #d4b07a 55%, #8a6f45); box-shadow: 0 0 0 1.5px #050606, 0 0 5px #d4b07a80; }

/* sharing */
#sharing-links { display: grid; gap: 10px; margin: 15px 0 0; }
#sharing-links:empty { display: none; }
#sharing-links p { margin: 0; color: var(--dusty); font-size: 13px; }
#sharing-links textarea { font-size: 12px; line-height: 20px; min-height: 90px; }

/* approvals */
.publication { margin: 0; }
#approval-summary p { font-size: 13px; line-height: 20px; margin: 0 0 6px; }
#approval-summary ol { padding-left: 20px; font-size: 13px; line-height: 20px; }
#approval-summary li::marker { color: var(--clay); }
#approval-summary details summary { min-height: 44px; display: flex; align-items: center; cursor: pointer; color: var(--rose); font-size: 13px; }
#approval-summary pre { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 12px; line-height: 18px; max-height: 360px; overflow: auto; padding: 12px; border-radius: 8px; background: var(--pocket); box-shadow: inset 0 3px 8px -3px #000000e6; }
#approval-statement { margin: 10px 0; color: var(--rose); }
#approve-packet { margin-top: 10px; }
#approval-history { display: grid; gap: 10px; }
#approval-history > p { color: var(--dusty); font-size: 13px; margin: 0; }
.approval-record { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; padding: 15px; border-radius: 6px; background: var(--pocket);
  box-shadow: inset 0 3px 8px -3px #000000e6, inset 0 1px 0 #000, inset 0 -1px 0 var(--mocha); }
.approval-record p { flex: 1 1 100%; margin: 0; font-size: 13px; line-height: 20px; }
.approval-record p:first-child { color: var(--oak); }
.approval-record p + p { color: var(--dusty); }

.principles { margin-top: 50px; }
.principles h2 { margin: 0 0 10px; }
.principles p:not(.eyebrow) { color: var(--rose); max-width: var(--measure); }

@media (max-width: 1000px) {
  .workspace-grid { grid-template-columns: 1fr; }
  .ws-side { position: static; }
}
@media (max-width: 700px) {
  .ws-bar { padding: 10px 12px; }
  .ws-editor .panel { padding: 20px 15px; }
  .fields, .track-edit { grid-template-columns: 1fr; padding: 15px; }
  .wide { grid-column: auto; }
  .upload-row { padding: 15px; }
  .upload-row .key { flex: 1 1 100%; }
  .cover-row { grid-template-columns: 1fr; }
  .actions .key, .actions button { flex: 1 1 100%; }
}
