/* Desktop presentation is isolated; the preceding two sheets preserve mobile. */
.message.visible{display:flex;align-items:center;gap:16px;pointer-events:auto;padding:4px 8px 4px 16px}
.message>span{white-space:normal;overflow-wrap:anywhere}
.message>button{font-size:22px;min-width:36px;min-height:36px;padding:2px 8px;flex:none}
@media(min-width:900px){
  :root{--pc-panel:320px;--pc-timeline:288px}
  .pc-editor,.pc-editor.rehearsing:not(.panel-open),.pc-editor.panel-open{grid-template-columns:72px var(--pc-panel) minmax(0,1fr);grid-template-rows:56px minmax(0,1fr) var(--pc-timeline)}
  .pc-editor.inspector-closed{grid-template-columns:72px 0 minmax(0,1fr)}
  .pc-editor.inspector-closed .pc-inspector{display:none}
  .pc-topbar,.page .pc-topbar{height:56px;min-height:56px;padding:0 16px 0 12px;gap:16px}
  .pc-topbar button{min-height:36px;height:36px;min-width:36px;padding:6px 10px;font-size:14px}
  .pc-topbar .home-button{border:0;padding:6px;min-width:36px;color:var(--muted)}
  .pc-wordmark{font-size:20px;font-weight:600;letter-spacing:-.8px;margin-right:12px}
  .pc-wordmark>span{color:var(--blue)}
  .pc-topbar .project-name{gap:18px;min-width:120px;overflow:hidden}
  .pc-topbar .project-name strong{font-size:14px;padding-left:16px;max-width:280px;border-left:1px solid var(--line)}
  .pc-topbar .save-state{font-size:12px;position:static;letter-spacing:0}
  .pc-topbar .save-state:before{position:static}
  .pc-topbar .header-actions{gap:8px;margin-left:auto}
  .history-actions{display:flex;padding-right:16px;margin-right:8px;border-right:1px solid var(--line)}
  .pc-topbar .export-button{margin:0;border-color:var(--line);background:var(--raised)}
  .pc-topbar .pc-share{border-color:var(--line)}
  .pc-editor .work-nav{grid-column:1;grid-row:2/4;gap:8px;padding:12px 6px;background:var(--surface)}
  .pc-editor .work-nav button{font-size:12px;min-height:64px;padding:9px 0;gap:6px}
  .pc-editor .work-nav .icon{width:21px;height:21px}
  .pc-editor .stage-work{grid-column:3;grid-row:2;background:var(--bg);visibility:visible!important}
  .pc-context{height:48px;min-height:48px;padding:0 24px;border-bottom:1px solid var(--line);gap:16px;background:var(--bg)}
  .pc-context>div{gap:12px;min-width:0;display:flex;align-items:center}
  .pc-context .context-label{font-size:12px;color:var(--muted);white-space:nowrap}
  .pc-context strong{font-size:14px;max-width:240px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .pc-context small{font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .pc-context .preview-context{margin-left:auto;font-size:12px;color:var(--muted);flex:none}
  .preview-context time{font-variant-numeric:tabular-nums;color:var(--green)}
  .pc-editor .stage-area{padding:24px 32px 24px;min-height:0;flex:1;overflow:hidden}
  .pc-editor .stage-footer{height:38px;min-height:38px;padding:0 24px;font-size:12px;display:flex;border-top:1px solid var(--line)}
  .pc-editor .stage-footer span{font-size:12px}
  .pc-editor .stage-footer button{min-height:32px;padding:3px 10px;font-size:12px}
  .pc-editor .stageboard{max-width:100%;border-radius:3px}
  .pc-editor .performer .token{font-size:clamp(12px,calc(var(--diameter)*.46),20px)}
  .pc-editor .person-name{font-size:12px}
  .pc-editor .stage-measure,.pc-editor .stage-depth,.pc-editor .backstage,.pc-editor .audience{font-size:12px}
  .pc-editor .stage-measure,.pc-editor .backstage{top:-20px}
  .pc-editor .audience{bottom:-22px}
  .pc-editor .pc-inspector{display:block;grid-column:2;grid-row:2;position:static;min-width:0;max-height:none;width:auto;border:0;border-right:1px solid var(--line);border-left:0;border-radius:0;box-shadow:none;padding:0 20px 16px;overflow:auto;background:var(--surface);z-index:3}
  .pc-inspector .panel-heading{height:52px;min-height:52px;position:sticky;top:0;padding:0;z-index:4;margin:0 0 12px;background:var(--surface);border-bottom:1px solid var(--line)}
  .pc-inspector .panel-heading:after{display:none}
  .pc-inspector .panel-heading h2{font-size:14px}
  .pc-inspector .panel-heading button{min-width:32px;min-height:32px;height:32px;padding:4px}
  .pc-inspector button{font-size:14px;min-height:36px}
  .pc-inspector .panel-row{margin-bottom:10px;font-size:12px;color:var(--muted)}
  .pc-inspector .panel-row button{font-size:12px;min-height:28px;padding:2px 4px}
  .pc-inspector h3{font-size:14px}
  .pc-inspector p,.pc-inspector .muted,.pc-inspector label{font-size:12px;line-height:1.55}
  .pc-inspector .panel-section{display:block;gap:0;margin-top:12px;padding:12px 0}
  .pc-inspector .panel-section h3{margin-bottom:0}
  .pc-inspector .search-input{height:40px;min-height:40px;flex:none}
  .pc-inspector .search-input input{min-height:38px;font-size:14px;width:100%}
  .pc-inspector.pc-list-panel{display:flex;flex-direction:column;overflow:hidden}
  .pc-list-panel .panel-heading{flex:none}
  .pc-roster-scroll{min-height:0;overflow:auto;flex:1;overscroll-behavior:contain;margin:0 -8px;padding:0 8px;scrollbar-gutter:stable}
  .roster-columns{display:flex;justify-content:space-between;padding:16px 8px 8px 30px;font-size:12px;color:var(--muted);flex:none}
  .pc-roster-row{display:flex;align-items:center;gap:8px;min-height:57px;border-bottom:1px solid var(--line)}
  .pc-roster-row>input{flex:none;width:16px;height:16px;min-height:16px;margin:0}
  .pc-roster-row .person-row{display:flex;gap:10px;border:0;padding:8px 4px;min-height:56px;flex:1;min-width:0;width:auto;border-radius:4px;text-align:left;background:transparent}
  .pc-roster-row.is-selected .person-row{background:var(--blue-tint)}
  .pc-roster-row .person-dot{width:28px;height:28px;min-width:28px;font-size:12px}
  .pc-roster-row .roster-name{flex:1;min-width:0;font-size:14px;overflow:hidden;text-overflow:ellipsis}
  .pc-roster-row .roster-name small{display:block;font-size:12px;margin-top:2px;font-weight:400}
  .roster-xy{display:grid;grid-template-columns:38px 38px;gap:2px;flex:none;font-variant-numeric:tabular-nums;font-size:12px;color:var(--muted);text-align:right;font-weight:400}
  .pc-inspector .roster-mode-entry{position:static;flex:none;border-top:1px solid var(--line);padding:12px 0 0;margin:8px 0 0;background:var(--surface)}
  .pc-inspector .roster-mode-entry button{min-height:40px;font-size:14px}
  .pc-inspector .pc-back{color:var(--muted);padding:4px 0;min-height:32px;font-size:12px;margin-bottom:4px}
  .pc-inspector .selected-person{margin:0;gap:10px;padding:4px 0 8px;border-bottom:1px solid var(--line)}
  .pc-inspector .selected-person .person-dot{width:36px;height:36px;min-width:36px;font-size:16px}
  .pc-inspector .selected-person h2{font-size:22px;line-height:1.4}
  .pc-inspector .selected-person p{font-size:12px;margin-top:3px;max-height:38px;overflow:auto;overflow-wrap:anywhere}
  .pc-inspector .selected-person>div{min-width:0;flex:1}
  .pc-inspector .selected-person>button{font-size:12px;min-width:36px;padding:4px}
  .pc-inspector .unit-summary{font-size:12px;color:var(--text);margin:8px 0}
  .pc-inspector .partner-note{font-size:12px;padding:0;margin:0 0 8px;background:transparent;color:var(--muted)}
  .pc-inspector .layout-tools{grid-template-columns:1fr 1fr;gap:8px;margin-top:10px}
  .pc-inspector .layout-tools>div{display:flex;flex-direction:column;gap:3px;min-width:0}
  .pc-inspector .layout-tools button{padding:6px;min-height:36px;font-size:14px}
  .pc-inspector .layout-tools small{font-size:12px;min-height:0;line-height:1.4;margin:0;padding:0 7px 4px}
  .pc-inspector .coordinate-anchor{font-size:12px;color:var(--muted);margin:10px 0 -8px}
  .pc-inspector .coordinate-anchor b{color:var(--text);font-weight:600}
  .pc-inspector .coordinate-fields{gap:12px;margin:10px 0 12px}
  .pc-inspector .coordinate-fields label{font-size:12px;gap:4px}
  .pc-inspector .coordinate-fields input{font-size:22px;height:48px;min-height:48px;padding:6px 10px;background:var(--bg)}
  .pc-inspector .nudge{gap:5px;margin:8px 0}
  .pc-inspector .nudge button{font-size:12px;min-height:32px;padding:4px}
  .pc-inspector #nudge-step{min-height:36px;font-size:14px}
  .detail-hint{margin:16px 0 12px;color:var(--muted)}
  .pc-panel-caption{color:var(--muted);margin-bottom:16px}
  .pc-lock{border-top:1px solid var(--line);color:var(--muted);padding-top:12px;margin-top:12px}
  .pc-editor .rehearsal-bar{height:44px;min-height:44px;background:var(--surface);border-bottom:1px solid var(--line);padding:0 20px}
  .pc-editor .rehearsal-bar>span:last-child{flex:none;font-size:12px;color:var(--muted)}
  .pc-editor .timeline{grid-column:2/4;grid-row:3;display:grid;grid-template-rows:44px 28px minmax(0,1fr) 40px;padding:0 24px;border-left:0;background:var(--surface);min-width:0}
  .pc-editor .transport{gap:4px;height:44px;min-height:44px;justify-content:flex-start}
  .pc-editor .transport button{min-height:36px;min-width:36px;height:36px}
  .pc-editor .transport .play-button{width:36px;height:36px;min-width:36px;min-height:36px}
  .pc-editor .clock{font-size:18px;margin-left:12px}
  .pc-editor .clock span{font-size:12px}
  .pc-editor .transport-end{margin-left:20px;gap:6px}
  .pc-editor .transport-end .speed{font-size:14px}
  .pc-editor .timeline-toolbar{height:28px;min-height:28px;font-size:12px;display:flex}
  .pc-editor .track-title,.pc-editor .track-title>span,.pc-editor .view-actions button,.pc-editor .timeline-scale{font-size:12px}
  .pc-editor .timeline-scale{margin-left:12px}
  .pc-editor .view-actions button{min-height:26px;padding:2px 8px}
  .pc-editor .timeline-scroll{min-height:0;grid-row:3}
  .pc-editor .track-inner{min-height:167px}
  .pc-editor .ruler{height:20px}
  .pc-editor .tick{font-size:12px;min-height:20px}
  .pc-editor .clips{height:96px}
  .pc-editor .clip{height:90px}
  .pc-editor .hold{padding-bottom:22px}
  .pc-editor .hold.compact{padding:3px 2px}
  .pc-editor .clip-caption,.pc-editor .clip-caption b{font-size:12px}
  .pc-editor .ribbon{font-size:12px}
  .pc-editor .move.selected:after{top:30px;bottom:30px}
  .pc-editor .waveform{height:48px;margin-top:3px}
  .pc-editor .waveform>span{font-size:12px}
  .pc-editor .detailed-waveform{position:relative;display:block;border:0;background:var(--bg);overflow:hidden}
  .detailed-waveform>svg{position:absolute;inset:0;width:100%;height:100%;display:block;color:var(--muted);pointer-events:none}
  .wave-peaks{fill:currentColor;opacity:.78}
  .wave-center{stroke:var(--major);stroke-width:.5;fill:none;opacity:.6}
  .pc-editor .detailed-waveform>span{position:absolute;left:10px;top:auto;bottom:3px;padding:0 4px;background:var(--bg);color:var(--muted);line-height:16px}
  .motion-route{color:var(--actor);fill:none;stroke:currentColor;stroke-width:.028;opacity:.17;pointer-events:none}
  .motion-route.focused{opacity:.9}
  .motion-route.subdued{opacity:.1}
  .motion-destination{fill:var(--actor);fill-opacity:.1;stroke:var(--actor);stroke-opacity:.35;stroke-width:.035}
  .token-direction{position:absolute;width:calc(var(--diameter)/2 + 26px + var(--label-clearance,0px));height:14px;transform:translateY(-50%) rotate(var(--direction));transform-origin:0 50%;z-index:2;pointer-events:none;color:var(--actor);opacity:.85}
  .token-direction>svg{position:absolute;right:0;top:0;width:24px;height:14px;overflow:visible;pointer-events:none}
  .direction-ink{fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
  .token-direction.focused{opacity:1}
  .token-direction.subdued{opacity:.7}
  :root[data-theme=light] .token-direction{color:color-mix(in srgb,var(--actor) 65%,#142033)}
  :root[data-theme=light] .motion-route{color:color-mix(in srgb,var(--actor) 65%,#142033)}
  .token-direction.focused .direction-ink{stroke-width:2.5}
  .pc-editor .performer{z-index:3}
  .pc-editor .performer.chosen{z-index:4}
  .motion-edit-hint{color:var(--muted);margin:8px 0}
  .pc-motion-lock{color:var(--muted);margin:6px 0}
  .pc-editor .selection-detail{grid-row:4;padding:3px 0;gap:10px;overflow:hidden}
  .pc-editor .selection-detail strong,.pc-editor .selection-detail span{font-size:12px}
  .pc-editor .selection-detail>div{display:flex;align-items:center;gap:12px}
  .pc-editor .selection-detail button{min-height:32px;font-size:12px}
  .pc-editor .selection-detail>.detail-thumb{width:45px;height:30px}
  .pc-editor .save-error{top:56px;right:20px;font-size:12px}
  .pc-panel-reopen{position:absolute;left:80px;top:64px;background:var(--surface);border:1px solid var(--line);z-index:5;font-size:12px;min-height:36px}
  .pc-home .page-body{max-width:1160px;padding:40px}
  .pc-home .page-title{margin-bottom:36px;align-items:center}
  .pc-home h1{font-size:28px;line-height:1.3;letter-spacing:-.8px}
  .pc-home .page-title p{font-size:14px;margin-top:8px}
  .pc-home .eyebrow{font-size:12px;margin-bottom:8px}
  .pc-home .project-content{padding:32px}
  .pc-home .project-content h2{font-size:26px}
  .pc-home .project-content>p,.pc-home .project-bottom small,.pc-home .project-bottom button{font-size:14px}
  .pc-home .project-feature{grid-template-columns:1fr 1.1fr}
  .page.export-page .page-body{max-width:none;padding:28px 40px}
  .export-page .export-layout{grid-template-columns:280px minmax(0,1fr);gap:40px;max-width:1200px;margin:auto}
  .export-page .page-title{max-width:1200px;margin:0 auto 24px}
  .export-page .format-option small,.export-page .output-status,.export-page .print-caption{font-size:12px}
  .export-page .export-options h2,.export-page .preview-heading h2{font-size:14px}
  .export-page .preview-column{padding:20px 32px 28px}
  .export-page .paper-preview{max-width:720px;margin:auto}
  .export-page .export-options>.primary{font-size:14px;min-height:40px}
  .export-page .export-options .panel-section{display:block;padding:14px 0;margin-top:14px}
  .export-page .export-options .panel-section h2{margin-bottom:12px}
  .export-page .check-row{min-height:34px;margin:0;font-size:14px}
  .export-page .format-option{min-height:64px;padding:10px 14px}
  .export-page .export-options>.primary{margin-top:16px}
  .pc-editor .speed-menu{left:200px;right:auto}
}
@media(min-width:900px) and (max-width:1100px){
  :root{--pc-panel:280px}
  .pc-editor .pc-inspector{padding-left:16px;padding-right:16px}
  .pc-wordmark{display:none}
  .pc-topbar .project-name{gap:10px}
  .pc-topbar .project-name strong{border:0;padding-left:0;max-width:170px}
  .pc-topbar .header-actions{gap:4px}
  .history-actions{padding-right:8px;margin-right:0}
  .pc-topbar .save-state{font-size:12px}
  .pc-context{padding:0 16px;gap:8px}
  .pc-context>div{gap:8px}
  .pc-context small,.preview-context>span:last-child{display:none}
  .roster-xy{grid-template-columns:32px 32px;font-size:12px}
  .pc-roster-row .person-row{gap:7px}
  .pc-roster-row{gap:6px}
  .pc-editor .stage-area{padding-left:24px;padding-right:24px}
}
@media(min-width:900px) and (max-height:800px){
  :root{--pc-timeline:256px}
  .pc-editor .timeline{grid-template-rows:44px 24px minmax(0,1fr) 36px}
  .pc-editor .timeline-toolbar{height:24px;min-height:24px}
  .pc-editor .clips{height:78px}
  .pc-editor .clip{height:72px}
  .pc-editor .ruler{height:18px}
  .pc-editor .track-inner{min-height:147px}
  .pc-editor .stage-footer{height:34px;min-height:34px}
  .pc-editor .stage-area{padding-top:20px;padding-bottom:20px}
}
