
/* QERO_STORY_EDITOR_V1 */
dialog.qero-story-studio{
  width:min(980px,calc(100% - 24px));max-width:none;max-height:94dvh;
  padding:0;border:0;border-radius:20px;background:#fff;color:#161616;
  box-shadow:0 24px 90px #0005;overflow:auto;
}
dialog.qero-story-studio::backdrop{background:#000b}
.qero-story-studio *{box-sizing:border-box}
.story-studio-header{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:18px 22px;border-bottom:1px solid #eee}
.story-studio-header h2{margin:0;font-size:21px}
.story-studio-header p{margin:5px 0 0;color:#777;font-size:13px}
.story-studio-header button{font-size:26px;border:0;background:#f4f4f4;width:40px;height:40px;border-radius:50%}
.story-studio-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(260px,340px);gap:24px;padding:22px}
.story-studio-preview{min-width:0;text-align:center}
.story-studio-frame{position:relative;width:min(100%,320px);aspect-ratio:4/5;margin:auto;overflow:hidden;border-radius:22px;background:#fff0e6;box-shadow:0 12px 30px #4b2b1c24}
.story-studio-frame canvas{display:block;width:100%;height:100%;touch-action:none;user-select:none}
.story-studio-guide{position:absolute;left:14px;right:14px;pointer-events:none;color:#fff;font:700 12px Arial,sans-serif;text-shadow:0 1px 4px #000}
.story-studio-guide.top{top:18px;display:flex;gap:8px;align-items:center}
.story-studio-guide.top i{width:22px;height:22px;flex:none;border:1px solid #fff;border-radius:50%}
.story-studio-guide.bottom{bottom:16px;padding:10px;background:#ff6b00cc;border-radius:10px;text-shadow:none}
.story-studio-preview>small{display:block;max-width:320px;margin:10px auto;color:#777;font-size:12px;line-height:1.5}
.story-studio-controls{display:flex;flex-direction:column;gap:14px}
.story-studio-controls fieldset{margin:0;padding:14px;border:1px solid #e7e7e7;border-radius:14px;min-width:0}
.story-studio-controls legend{font-weight:800;padding:0 5px}
.story-studio-controls label{display:flex;flex-direction:column;gap:7px;margin:0 0 12px;font-size:13px;font-weight:700}
.story-studio-controls select,.story-studio-controls textarea{width:100%;padding:9px;border:1px solid #ddd;border-radius:9px;font:inherit;background:#fff;color:#111}
.story-studio-controls input[type=range]{width:100%;accent-color:#ff6b00}
.story-studio-controls input[type=color]{width:64px;height:36px;padding:2px;border:1px solid #ddd;border-radius:7px;background:#fff}
.story-studio-controls button,.story-studio-footer button{min-height:40px;padding:9px 12px;margin:3px;border:1px solid #ddd;border-radius:10px;background:#f6f6f6;color:#111;font:700 13px Arial,sans-serif;cursor:pointer}
.story-studio-controls button[aria-pressed=true]{border-color:#ff6b00;background:#fff0e6}
.story-studio-controls small,.story-studio-controls [data-status=tool]{display:block;color:#777;font-size:12px;line-height:1.5}
.story-studio-footer{display:flex;flex-wrap:wrap;justify-content:flex-end;align-items:center;gap:8px;padding:14px 20px;border-top:1px solid #eee}
.story-studio-footer [data-status=error]{flex:1 1 100%;margin:0;color:#b42716;font-size:13px}
.story-studio-footer button.story-studio-publish{background:#ff6b00;color:#fff;border-color:#ff6b00}
.qero-story-studio button:disabled{opacity:.55;cursor:wait}
.qero-story-studio button:focus-visible,.qero-story-studio input:focus-visible,.qero-story-studio select:focus-visible,.qero-story-studio textarea:focus-visible{outline:2px solid #ff6b00;outline-offset:2px}
@media(max-width:650px){
  dialog.qero-story-studio{width:100%;height:100dvh;max-height:100dvh;margin:0;border-radius:0}
  .story-studio-layout{grid-template-columns:1fr;padding:16px}
  .story-studio-header{padding:16px}
  .story-studio-footer{padding-bottom:calc(16px + env(safe-area-inset-bottom))}
}
/* END_QERO_STORY_EDITOR_V1 */
