/* Standalone first-party Melody Studio — scoped to /flow/studio. */
.studio-page{min-height:100vh;background:radial-gradient(circle at 24% 9%,#26464e,#091b2b 56%,#08111e);
  color:#f5f2e8;padding:70px 20px 90px}
.studio-shell{max-width:1200px;margin:auto}
.studio-shell a{color:#f8d991}
.studio-kicker{color:#cfbd82;letter-spacing:.24em;font-size:12px;font-weight:700}
.studio-shell h1{font-size:clamp(34px,6vw,65px);letter-spacing:-.035em;margin:12px 0}
.studio-intro{max-width:780px;color:#c1d0d4;line-height:1.8}
.studio-grid{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(340px,.8fr);
  gap:24px;margin:35px 0}
.studio-play,.studio-editor{border:1px solid #708d9870;background:#142937c7;
  padding:28px;border-radius:22px;min-width:0}
.studio-play h2,.studio-editor h2{font-size:24px;margin-top:0;color:#f7d89e}
.studio-pad{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:15px;
  max-width:510px;margin:30px auto}
.studio-note{min-height:100px;border:2px solid #a7ac9c;background:
  radial-gradient(circle at 38% 28%,#8ba7ab,#446572 62%,#26424d);border-radius:50%;
  box-shadow:inset 0 5px 10px #d3d8c559,0 12px 22px #0007;color:#fff;
  font-size:21px;font-weight:800;cursor:pointer;touch-action:manipulation}
.studio-note:focus-visible{outline:3px solid #f6d68b;outline-offset:4px}
.studio-note.is-played{border-color:#f9d47d;box-shadow:0 0 28px #fbd57ca6}
.studio-control{display:flex;flex-wrap:wrap;gap:10px;margin:20px 0}
.studio-control button,.studio-history button,.studio-note-list button{
  padding:11px 16px;background:#2a424d;color:#f9f5ee;border:1px solid #98abb4;
  border-radius:10px;cursor:pointer}
.studio-control .studio-primary{background:#d6ba75;color:#142431;border-color:#f8d992;font-weight:800}
.studio-control button:disabled,.studio-history button:disabled{opacity:.48;cursor:not-allowed}
.studio-hint,.studio-footnote{color:#b8c9cc;font-size:13px;line-height:1.7}
.studio-status{min-height:28px;color:#f4d78d;font-weight:700}
.studio-editor label{display:block;color:#e6e5dc;margin:15px 0 7px;font-weight:700}
.studio-editor input[type=text],.studio-editor select{width:100%;background:#102431;color:#fff;
  padding:12px;border:1px solid #9daaaa;border-radius:10px}
.studio-editor input[type=checkbox]{accent-color:#f1ce85;margin-right:9px}
.studio-stats{display:flex;justify-content:space-between;color:#e9d9ac;padding:16px 0}
.studio-note-list{min-height:120px;max-height:390px;overflow:auto;padding:0;list-style:none;
  border:1px solid #6b87854a;border-radius:10px}
.studio-note-list li{display:flex;align-items:center;justify-content:space-between;gap:8px;
  padding:9px 13px;border-bottom:1px solid #75949b42}
.studio-note-list button{padding:5px 10px}
.studio-notice{border:1px solid #a38c6478;padding:13px;background:#3d3425a8;border-radius:10px;
  line-height:1.6}
.studio-history{padding:15px;border:1px solid #829d9c;border-radius:10px;margin:25px 0}
.studio-history summary{cursor:pointer;color:#f5d89c;font-weight:800}
.studio-history li{padding:8px 0;line-height:1.6}
.studio-footnote{margin:35px 0}
@media(max-width:850px){.studio-grid{grid-template-columns:1fr}.studio-pad{max-width:480px}}
@media(max-width:480px){.studio-page{padding-inline:12px}.studio-play,.studio-editor{padding:16px}
  .studio-note{min-height:76px;font-size:16px}.studio-pad{gap:9px}}
@media(prefers-reduced-motion:reduce){.studio-note{transition:none}}


/* P3 follow-up: real nine-note map, private library and inline expressive editing. */
.studio-instrument-meta{display:flex;flex-wrap:wrap;align-items:center;gap:12px;margin:18px 0;
    padding:12px 16px;background:#223d48;border:1px solid #7391978c;border-radius:12px}
.studio-instrument-meta strong{color:#f9dc9c}
.studio-instrument-meta span{color:#c6d6d8;font-size:13px}
.studio-pad{grid-template-rows:repeat(3,minmax(0,1fr))}
.studio-note[data-position="0"]{grid-area:2/2;background:radial-gradient(circle at 34% 24%,#d6cfa5,#6c8077 64%,#344b50);border-color:#f5de9f}
.studio-note[data-position="1"]{grid-area:1/2}
.studio-note[data-position="2"]{grid-area:1/3}
.studio-note[data-position="3"]{grid-area:2/3}
.studio-note[data-position="4"]{grid-area:3/3}
.studio-note[data-position="5"]{grid-area:3/2}
.studio-note[data-position="6"]{grid-area:3/1}
.studio-note[data-position="7"]{grid-area:2/1}
.studio-note[data-position="8"]{grid-area:1/1}
.studio-editor input[type=number],.studio-editor input[type=range]{accent-color:#efce8a}
.studio-editor input[type=number]{width:100%;background:#102431;color:#fff;
    padding:11px;border:1px solid #9daaaa;border-radius:9px}
.studio-inline-label{display:flex!important;align-items:center;gap:9px;line-height:1.55}
.studio-note-list{padding:10px;max-height:490px}
.studio-note-list li.studio-note-item{display:block;padding:12px;margin-bottom:10px;
    border:1px solid #8aa3a180;background:#1b3741;border-radius:12px}
.studio-note-item>strong{display:block;font-size:15px;color:#f8d993;margin-bottom:12px}
.studio-note-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px 14px}
.studio-note-fields label{display:flex;flex-direction:column;gap:6px;
    color:#d8e6df;font-size:12px;font-weight:700;margin:0;min-width:0}
.studio-note-fields label>span{display:block}
.studio-note-fields select,.studio-note-fields input[type=number]{
    max-width:100%;padding:9px;font-size:14px}
.studio-velocity{display:flex;gap:8px;align-items:center;min-height:38px}
.studio-velocity input{min-width:0;flex:1}
.studio-velocity output{min-width:27px;text-align:right;color:#f8d993;font-variant-numeric:tabular-nums}
.studio-note-actions{display:flex;gap:7px;flex-wrap:wrap;margin-top:11px}
.studio-note-actions button{padding:7px 11px;font-size:12px}
.studio-danger{background:#60353c!important;border-color:#e7a4a8!important;color:#ffe8e8!important}
.studio-note-list button:focus-visible,.studio-control button:focus-visible,
.studio-history button:focus-visible{outline:3px solid #f6d68b;outline-offset:3px}
.studio-note-list input:focus-visible,.studio-note-list select:focus-visible,
.studio-editor input:focus-visible{outline:2px solid #f6d68b;outline-offset:2px}
.studio-editor :disabled{cursor:not-allowed}
@media(min-width:1100px){.studio-note-fields{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media(max-width:480px){.studio-note-fields{grid-template-columns:repeat(2,minmax(0,1fr))}
    .studio-note-item{padding:10px}.studio-pad{grid-template-rows:repeat(3,76px)}}
