:root{color-scheme:dark;font-family:Arial,Helvetica,sans-serif;color:#edf0e9;background:#11181b;font-synthesis:none}*{box-sizing:border-box}body{margin:0}button,a,input{-webkit-tap-highlight-color:transparent}button,input{font:inherit}button{cursor:pointer}header{min-height:84px;display:flex;justify-content:space-between;align-items:center;border-bottom:1px solid #ffffff16;padding:20px 4vw;gap:20px}.brand{color:inherit;text-decoration:none;font-size:14px;font-weight:700;letter-spacing:2px;display:flex;align-items:center;gap:14px}.brand-mark{font-size:36px;color:#d0ec9c;font-weight:400}.edition{font-size:12px;font-weight:400;color:#a1adae;letter-spacing:1px}.live{font-size:13px;color:#a1adae;display:flex;align-items:center;gap:10px}.live i{height:5px;width:5px;border-radius:50%;background:#d0ec9c}main{display:grid;grid-template-columns:minmax(0,1fr) 350px;max-width:1600px;margin:auto;padding:28px 4vw 0;gap:28px}.stage{align-self:start;position:relative;min-width:0;border:1px solid #ffffff17;border-radius:10px;overflow:hidden;background:radial-gradient(ellipse at 50% 43%,#2c393b 0%,#1b272b 42%,#141e22 78%);display:flex;flex-direction:column}.stage-heading{display:flex;justify-content:space-between;padding:30px 32px 0;position:absolute;inset:0 0 auto;pointer-events:none}.eyebrow{font-size:12px;letter-spacing:2px;color:#a5b5b3;font-weight:600}h1{font-family:Georgia,serif;font-size:clamp(26px,3vw,43px);font-weight:400;letter-spacing:-1px;margin:10px 0}.stage-number{font-family:Georgia,serif;font-size:22px;color:#879796}canvas{width:100%;height:clamp(560px,70vh,760px);min-height:0;display:block;touch-action:none;flex:none}.stage-caption{padding:18px 25px;display:flex;align-items:center;justify-content:space-between;gap:15px;border-top:1px solid #ffffff12;color:#aab8b7;font-size:13px}.quiet{border:0;background:none;color:#d0ec9c;font-size:14px;padding:6px 0}.quiet:disabled{opacity:.4;cursor:default}aside{padding:10px 0}.panel-heading h2{font-family:Georgia,serif;font-size:32px;font-weight:400;margin:12px 0}.panel-heading p,.motion p{font-size:14px;line-height:1.6;color:#aab5b5;margin:10px 0 20px}fieldset{border:0;border-top:1px solid #ffffff1d;padding:22px 0 12px;margin:20px 0 0;min-width:0}legend{font-size:14px;font-weight:600;padding:0 12px 0 0}legend span{color:#83968e;font-size:12px;margin-right:9px}label{font-size:14px;display:flex;justify-content:space-between;gap:5px;margin-bottom:6px}output{font-variant-numeric:tabular-nums;color:#a8b7ac;font-size:12px}input[type=range]{width:100%;height:22px;margin:0 0 15px;accent-color:#d0ec9c;cursor:ew-resize}.limbs{display:grid;grid-template-columns:1fr 1fr;gap:4px 20px}.note{font-size:12px!important;line-height:1.6;color:#849995;margin:0}.motion{background:#d0ec9c0a;border:1px solid #d0ec9c26;border-radius:7px;padding:18px;margin-top:8px}.motion-title{display:flex;align-items:center;justify-content:space-between;gap:10px}h3{font-size:16px;font-weight:500;margin:0}#motion-badge{font-size:10px;letter-spacing:1px;color:#b7c89f}.motion p{margin:12px 0}#motion{display:flex;align-items:center;justify-content:space-between;width:100%;background:#d0ec9c;color:#223027;border:0;padding:13px 15px;border-radius:4px;font-size:14px;font-weight:600}#motion:disabled{opacity:.6;cursor:wait}.reset{width:100%;padding:16px;margin-top:16px;background:transparent;border:1px solid #ffffff25;border-radius:5px;color:#cbd5d0;font-size:14px}button:hover{filter:brightness(1.12)}:focus-visible{outline:2px solid #d0ec9c;outline-offset:5px}footer{max-width:1600px;margin:auto;display:flex;justify-content:space-between;padding:24px 4vw;font-size:12px;color:#7d9290}@media(max-width:1000px){main{grid-template-columns:minmax(0,1fr) 300px;gap:20px;padding:20px}.edition,.live{display:none}.stage-heading{padding:25px 22px}.stage-caption{padding:14px;font-size:12px}}@media(max-width:720px){header{min-height:65px;padding:12px 20px}main{grid-template-columns:1fr;padding:14px;gap:24px}canvas{min-height:0;height:560px;flex:none}.stage-heading{padding:22px}h1{font-size:30px}aside{padding:0 8px}.panel-heading p br{display:none}fieldset{padding-top:18px}.stage-caption{font-size:12px}.live{display:none}footer{padding:24px 22px;gap:14px}.motion-title{flex-wrap:wrap}}@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto}}

.keyboard-help{display:none;margin:0;padding:10px 20px;color:#d0ec9c;font-size:12px;line-height:1.6}canvas:focus-visible~.keyboard-help{display:block}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}

.header-actions{display:flex;align-items:center;gap:20px}
#controls-toggle{background:#ffffff08;border:1px solid #ffffff25;border-radius:5px;padding:9px 12px;color:#cbd5d0;font-size:13px;white-space:nowrap}
#studio[data-controls=collapsed]{grid-template-columns:minmax(0,1fr)}
#puppet-controls[hidden]{display:none}
@media(max-width:420px){header{gap:10px;padding:12px 14px}.brand{gap:8px;font-size:12px;letter-spacing:1px}#controls-toggle{padding:9px 8px;font-size:12px}}



.view-controls{display:flex;flex-wrap:wrap;justify-content:space-between;gap:10px;padding:12px 20px;border-top:1px solid #ffffff12}.view-controls>div{display:flex;align-items:center;gap:6px}.view-controls button{background:#ffffff08;border:1px solid #ffffff20;border-radius:4px;padding:8px 10px;color:#cbd5d0;font-size:14px}.view-controls output{margin-left:6px;min-width:35px}#render-status:not([hidden]){position:absolute;top:40%;left:10%;right:10%;padding:20px;background:#182529;border:1px solid #d0ec9c50;border-radius:6px;font-size:16px;line-height:1.6;color:#d0ec9c}canvas:focus-visible{outline-offset:-3px}@media(max-width:720px){.view-controls{padding:12px;gap:8px}.view-controls button{padding:8px}.view-controls output{display:none}}

.stage{--section-inset:28px}
.pose-controls{display:flex;align-items:center;gap:14px;flex-wrap:wrap;padding:12px var(--section-inset);border-top:1px solid #ffffff12}.pose-buttons{display:flex;gap:8px;flex-wrap:wrap}.pose-buttons button{font-size:14px;color:#cbd5d0;background:#ffffff08;border:1px solid #ffffff20;border-radius:4px;padding:9px 13px}.pose-buttons button[aria-pressed=true]{background:#d0ec9c;color:#223027;border-color:#d0ec9c}@media(max-width:720px){.pose-controls{padding:12px var(--section-inset)}.pose-buttons{gap:6px}.pose-buttons button{padding:9px 11px}}

.animation-controls{margin:0 var(--section-inset);padding:12px 0 10px;border-top:1px solid #344044}
.animation-toolbar,.timeline-row,.timeline-details{display:flex;align-items:center;gap:12px;justify-content:space-between}
.keyframe-actions button,#timeline-start,#timeline-play{background:#ffffff08;border:1px solid #ffffff20;border-radius:4px;padding:8px 10px;color:#cbd5d0;font-size:13px}.animation-controls button:disabled{opacity:.4;cursor:default}.animation-toolbar{flex-wrap:wrap}.animation-toolbar>div{display:flex;gap:6px}
.animation-controls label{display:flex;align-items:center;gap:6px;margin:0;font-size:12px;white-space:nowrap}
.animation-controls input[type=number]{width:62px;background:#11181b;color:#e5e5d8;border:1px solid #485453;border-radius:5px;padding:6px;font:inherit}
.view-angle-field{align-items:center;gap:4px;margin:0 0 0 6px;color:#e5e5d8;font-size:12px}
#view-angle{width:70px;min-width:0;background:#11181b;color:#e5e5d8;border:1px solid #485453;border-radius:5px;padding:6px;font:inherit;text-align:center}
.timeline-row{margin-top:4px}.timeline-track{--playhead-size:18px;flex:1;min-width:0;padding:0 9px}
/* Match marker endpoints to the slider thumb's center, including at 0 and 60s. */
#keyframe-markers{height:30px;position:relative;margin:0 calc(var(--playhead-size)/2)}
.keyframe-marker{position:absolute;transform:translateX(-50%);padding:3px 4px;background:#263236;border:1px solid #60716b;border-radius:4px;color:#aabbb0;line-height:20px;min-width:24px}
.keyframe-marker:hover{border-color:#b4c99b;background:#34433a}
.keyframe-marker{cursor:ew-resize;touch-action:none;user-select:none;-webkit-user-select:none}
.keyframe-marker[data-dragging=true]{z-index:1}
.keyframe-marker[aria-pressed=true]{color:#dfeeb0;background:#34433a;border-color:#d0ec9c}
#timeline-position{appearance:none;-webkit-appearance:none;width:100%;height:22px;margin:0;padding:0;border:0;display:block;background:transparent}
#timeline-position::-webkit-slider-runnable-track{height:4px;border:0;border-radius:2px;background:#60716b}
#timeline-position::-webkit-slider-thumb{appearance:none;-webkit-appearance:none;box-sizing:border-box;width:var(--playhead-size);height:var(--playhead-size);margin-top:calc((4px - var(--playhead-size))/2);border:0;border-radius:50%;background:#d3e4a0}
#timeline-position::-moz-range-track{height:4px;border:0;border-radius:2px;background:#60716b}
#timeline-position::-moz-range-thumb{box-sizing:border-box;width:var(--playhead-size);height:var(--playhead-size);border:0;border-radius:50%;background:#d3e4a0}
.timeline-scale{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:start;gap:8px;font-size:11px;color:#91a099;margin-top:0}
.keyframe-actions{display:flex;justify-content:center;flex-wrap:wrap;gap:6px;margin-top:5px}
.keyframe-actions button{padding:5px 8px}
#timeline-start,#timeline-play{align-self:flex-start;margin-top:24px}
#timeline-play{min-width:83px}.timeline-details{margin-top:8px;font-size:11px;color:#aebbad;flex-wrap:wrap}
.animation-controls .note{margin:10px 0 0}#timeline-status:empty{display:none}
@media(max-width:600px){.stage{--section-inset:18px}.animation-toolbar{gap:10px}.animation-toolbar>.eyebrow{width:100%}.animation-controls button{font-size:11px}}

.timeline-details{display:grid;grid-template-columns:auto minmax(0,1fr) auto}
#timeline-state{text-align:center;overflow-wrap:anywhere}

.animation-toolbar{display:grid;grid-template-columns:1fr}.animation-toolbar>div{justify-self:center;justify-content:center;flex-wrap:wrap}

.confirmation-dialog{width:min(420px,calc(100% - 36px));padding:28px;background:#1b272b;color:#edf0e9;border:1px solid #60716b;border-radius:12px;box-shadow:0 24px 80px #0008}
.confirmation-dialog::backdrop{background:#080e12bb;backdrop-filter:blur(4px)}
.confirmation-dialog h2{font:normal 28px Georgia,serif;margin:14px 0 12px}
.confirmation-dialog p{font-size:14px;line-height:1.6;color:#aab8b7;margin:0 0 24px}
.confirmation-actions{display:flex;justify-content:flex-end;gap:10px}
.confirmation-actions button{padding:10px 16px;border:1px solid #60716b;border-radius:5px;background:#ffffff08;color:#edf0e9;font-size:14px}
#delete-all-confirm{background:#d0ec9c;color:#223027;border-color:#d0ec9c}

.prop-controls{display:flex;align-items:center;gap:14px;flex-wrap:wrap;padding:12px var(--section-inset);border-top:1px solid #ffffff12}
.prop-buttons{display:flex;gap:8px}.prop-buttons button{font-size:14px;color:#cbd5d0;background:#ffffff08;border:1px solid #ffffff20;border-radius:4px;padding:9px 13px}.prop-buttons button[aria-pressed=true]{background:#d0ec9c;color:#223027;border-color:#d0ec9c}

.view-controls .stage-height-control{flex:1;min-width:200px;max-width:340px;gap:8px}
.stage-height-control label{margin:0;font-size:12px;white-space:nowrap}
#stage-height{flex:1;min-width:60px;width:100px;margin:0}
#stage-height-out{display:block;min-width:30px;margin:0;text-align:right}

.stage-heading{z-index:2;transform:translateZ(0)}
#stage-intro{opacity:1;will-change:opacity}
#stage-intro[hidden]{display:none}
