/* Motion Prompt #087 / #153 / #154 / #160 / #161.
 * MIT License (c) 2026 Shohei Ohtaki. Adapted to actual file-tool events.
 * https://showheyohtaki.github.io/motion-prompt/ */
:root{--blue:#6545eb;--ink:#23173f;--muted:#6f6680;--line:#e3dfea;--paper:#f5f3fc;--coral:#ff805c;color:var(--ink);background:var(--paper);font-family:"Microsoft YaHei","PingFang SC","Segoe UI",sans-serif}
body.studio-app{background:var(--paper);color:var(--ink)}
.studio-app header{height:82px;position:sticky;top:0;padding:0 max(28px,calc((100vw - 1320px)/2));background:#f5f3fcf2;border-bottom:1px solid var(--line);backdrop-filter:blur(14px);z-index:20;gap:26px}
.studio-app .brand{color:var(--ink);font-weight:800;letter-spacing:-1px;font-size:27px}
.studio-app .brand-mark{border-radius:12px;background:var(--blue);box-shadow:none;color:#fff;width:38px;height:38px;transform:rotate(-7deg)}
.studio-app .brand-sub{font-size:13px;color:var(--muted);letter-spacing:0}
.studio-app .header-note{font-size:12px}.studio-app .status-dot{background:var(--blue)}
.studio-app .layout{max-width:1320px;display:flex;flex-direction:column;min-height:calc(100vh - 82px)}
.studio-app aside{order:0;padding:0;border:0;background:transparent;display:contents}.studio-app .nav-caption,.studio-app .local-note{display:none}
.studio-app #categories{display:flex;flex-direction:row;gap:8px;align-items:center;padding:23px 32px 0;flex-wrap:wrap;order:0}
.studio-app .nav-button{padding:10px 16px;min-height:44px;gap:8px;background:transparent;border:1px solid transparent;border-radius:10px;color:#706480;font-size:14px;box-shadow:none;transition:color .2s,background .2s,border-color .2s}
.studio-app .nav-button:last-child{margin:0 0 0 auto;border:0;font-size:12px;color:#8a8098}
.studio-app .nav-button.active{background:#e6dfff;color:#4d2bc7;border-color:#d7cbfc;font-weight:700;box-shadow:none}
.studio-app .nav-button svg{width:19px;height:19px}
.studio-app main{padding:0 32px;min-width:0;width:100%;order:1}
.studio-hero{display:grid;grid-template-columns:.9fr 1.1fr;align-items:center;gap:35px;padding:33px 35px;margin:23px 0 32px;background:#f5ce66;border-radius:23px;min-height:0}
.hero-kicker{font-size:12px;display:flex;gap:8px;align-items:center;letter-spacing:.2px;color:#67512f;margin:0 0 23px}
.studio-app .studio-hero h1{font-size:clamp(40px,4.15vw,60px);font-weight:850;line-height:1.24;letter-spacing:-2.7px;margin:0;color:#271542}
.hero-description{color:#635138;font-size:14px;line-height:1.9;margin:18px 0 20px}
.studio-app .primary{border:0;border-radius:12px;background:var(--blue);color:#fff;padding:13px 24px;font-weight:650;min-height:48px;box-shadow:0 7px 18px #6545eb24;transition:background .2s,transform .2s}
.studio-app .primary:hover{background:#5231d4}.studio-app .primary:active{transform:scale(.97)}
.studio-app .secondary{border-radius:12px;background:#fff9;color:#49395f;border:1px solid #dcd4e8;min-height:44px;padding:11px 18px}
.hero-actions{display:flex;gap:12px;align-items:center}.hero-pick{position:relative;display:inline-flex;align-items:center;cursor:pointer;overflow:hidden}
.hero-pick input{position:absolute;width:1px;height:1px;opacity:0;inset:auto}.hero-pick:focus-within{outline:3px solid #b8a4ff;outline-offset:4px}
.hero-private{font-size:12px;color:#705c3d;margin:12px 0 17px}.hero-shortcuts{display:flex;align-items:center;gap:23px;font-size:13px;color:#4c3b66}
.hero-shortcuts a{border-bottom:1px solid #bdb1ce;padding:7px 0}.hero-shortcuts a:hover{color:var(--blue);border-color:var(--blue)}
.hero-preview{border-radius:20px;background:#221a36;box-shadow:9px 11px 0 #d6ac48,0 15px 30px #71522028;padding:12px;position:relative;min-width:0;color:#fff;transform:rotate(1deg);transition:transform .4s cubic-bezier(.215,.61,.355,1),box-shadow .3s;isolation:isolate}
.hero-preview.is-dragover{outline:4px solid var(--coral);outline-offset:7px;transform:rotate(0) scale(1.02)}
.preview-top{display:flex;justify-content:space-between;align-items:center;padding:0 3px 10px;gap:12px;font-size:11px;color:#bfb1d5}
.preview-tab{color:#ffb69e;background:#453044;border-radius:7px;padding:7px 11px;font-size:12px;font-weight:700}
.compare-frame{position:relative;aspect-ratio:1.6;overflow:hidden;border-radius:12px;background:#151221;--compare:50%;isolation:isolate}
.hero-photo{aspect-ratio:1.9}
.studio-app .hero-photo img{object-fit:cover!important}
.compare-frame img{position:absolute!important;inset:0;width:100%!important;height:100%!important;max-width:none;object-fit:contain!important;background:transparent!important;border-radius:0!important;display:block}
.compare-frame .compare-after{clip-path:inset(0 calc(100% - var(--compare)) 0 0)}
.compare-label{position:absolute;z-index:2;top:12px;padding:6px 10px;border-radius:7px;background:#151221b8;color:#fff;font-size:11px;pointer-events:none}
.before-label{right:12px}.after-label{left:12px}
.compare-line{position:absolute;left:var(--compare);top:0;bottom:0;width:3px;background:white;pointer-events:none;z-index:3;transform:translateX(-50%)}
.compare-handle{position:absolute;width:34px;height:34px;top:50%;left:50%;transform:translate(-50%,-50%);background:#fff;border-radius:50%;box-shadow:0 2px 12px #0004;background-image:url('/assets/arrows-horizontal.svg');background-position:center;background-repeat:no-repeat;background-size:19px}
.compare-range{position:absolute!important;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:ew-resize;z-index:4;touch-action:pan-y;padding:0!important}
.compare-frame:focus-within{outline:3px solid #ffab8e;outline-offset:3px}.compare-range:disabled{cursor:wait}
.preview-bottom{display:flex;justify-content:space-between;align-items:center;padding:14px 4px 5px;gap:12px;font-size:11px;color:#bfb4cf}
.preview-bottom strong{display:block;font-size:13px;font-weight:600;color:#fff;margin-bottom:5px}.preview-bottom span{line-height:1.6}
.preview-drag{text-align:right;color:#f1c2b2}.drop-instruction{font-size:11px;color:#cfc4dd;text-align:center;margin:9px 0 2px;padding-top:9px;border-top:1px solid #ffffff17}
.catalog-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;border-top:1px solid #dcd3e8;padding-top:30px;margin-bottom:20px}
.catalog-heading h2{font-size:24px;letter-spacing:-.7px}.catalog-heading p{font-size:13px;color:var(--muted);margin:7px 0 0}.catalog-heading>span{font-size:12px;color:var(--muted)}
.studio-app .search{height:54px;max-width:none;margin:0 0 14px;background:#fff;border-color:#ded4ec;border-radius:12px;box-shadow:none;color:#9183a6}
.studio-app .search input{color:var(--ink)}.studio-app .search:focus-within{border-color:#9d81f8;box-shadow:0 0 0 3px #6545eb10}
.studio-app .quick-filters{margin-bottom:23px;gap:5px}.studio-app .quick-filters button{border-radius:8px;color:#80718e;min-height:40px}
.studio-app .quick-filters button.active{background:#e8e0ff;color:#5838ce}.studio-app .section-title h2{font-size:17px}.studio-app .section-title span{color:#8c7e99}
.studio-app .tool-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;perspective:1000px}
.studio-app .tool-card{border-radius:16px;background:#fff;border:1px solid #e5dfee;min-height:169px;box-shadow:none;transform-style:preserve-3d;position:relative;transition:transform .4s cubic-bezier(.215,.61,.355,1),box-shadow .4s,border-color .3s;isolation:isolate;--rx:0rad;--ry:0rad}
.studio-app .tool-card:hover{border-color:#aa91df;box-shadow:0 16px 28px #513d7514;transform:perspective(520px) rotateX(var(--rx)) rotateY(var(--ry))}
.studio-app .tool-card::after{content:"";position:absolute;inset:0;border-radius:inherit;pointer-events:none;background:radial-gradient(115px circle at var(--spot-x,-200px) var(--spot-y,-200px),#ffffff57,transparent);opacity:0;transition:opacity .4s}
.studio-app .tool-card:hover::after{opacity:1}.studio-app .tool-card::before{content:"";position:absolute;inset:-1px;border-radius:inherit;padding:2px;pointer-events:none;opacity:0;background:radial-gradient(120px circle at var(--spot-x,-200px) var(--spot-y,-200px),#ff805c,transparent);-webkit-mask:linear-gradient(#fff 0 0) content-box,linear-gradient(#fff 0 0);-webkit-mask-composite:xor;mask-composite:exclude;transition:opacity .4s}
.studio-app .tool-card:hover::before{opacity:1}.studio-app .tool-open{padding:21px;border-radius:16px;position:relative;z-index:1}
.studio-app .card-top{margin-bottom:15px;gap:10px}.studio-app .tool-icon{width:40px;height:40px;border-radius:12px;background:#e9e1ff;color:#6745cd}
.studio-app .tone-pdf{background:#ffe1d7;color:#bf5333}.studio-app .tone-text{background:#d9eee5;color:#347b65}.studio-app .tone-table{background:#d9ecf6;color:#33748e}.studio-app .tone-ai{background:#eeebf2;color:#8e809d}
.studio-app .tool-card h3{font-size:16px;color:#352347;margin:0 0 7px}.studio-app .tool-card p{color:#72637f;font-size:12px;line-height:1.75}.studio-app .tag{color:#796a87;font-size:11px}
.studio-app .star-button{z-index:3;min-width:40px;min-height:40px;top:10px;right:8px;color:#aa9cb5}.studio-app .star-button[aria-pressed=true]{background:#fff0cf;color:#a67a23}
.studio-app .ai-notice{margin-top:23px;background:#eee9f7;border:0;color:#82748f;border-radius:10px;font-size:12px}
.studio-app .growth-home{background:transparent!important;border-top:1px solid #ded5e9;padding:28px 0!important;margin-top:28px!important;border-radius:0!important}
.studio-app .growth-home h2{font-size:20px!important;color:var(--ink)}.studio-app .growth-home p{font-size:13px;color:var(--muted)}
.studio-app .growth-home nav{display:flex;flex-direction:row;flex-wrap:wrap;gap:8px}.studio-app .growth-home a{background:#e7dff6;color:#694f8b;border:0;border-radius:8px;padding:10px 13px;font-size:12px}
.studio-app .bottom-note{background:#ebe5f5;color:#71617f;border-radius:12px;margin:0 0 30px}.studio-app .bottom-note strong,.studio-app .bottom-note p{color:#7e6d8b}
.studio-app #workspace{padding:34px 0 8px;max-width:1120px;margin:auto}.studio-app .back{min-height:44px;padding:0;color:#867194;margin-bottom:20px}
.studio-app .work-heading{margin-bottom:25px;gap:15px}.studio-app .work-heading h1,.studio-app .work-heading h2{font-size:30px;letter-spacing:-1px;color:var(--ink)}.studio-app .work-heading p{color:#8a7999}
.studio-app .work-surface{max-width:none;padding:30px;border-radius:19px;border-color:#e3d8ec;background:#fff;box-shadow:0 10px 32px #50336b05}
.studio-app .drop{min-height:160px;border:1.5px dashed #bba3dc;background:#f8f5ff;border-radius:14px;color:#775a9a;transition:background .2s,border-color .2s}
.studio-app .drop:hover,.studio-app .drop.is-dragover{background:#ece3ff;border-color:var(--blue)}.studio-app .drop input::file-selector-button{border:0;background:#ded0fa;color:#5e3a96;padding:9px 12px;border-radius:8px;margin-right:10px;cursor:pointer}
.studio-app .fields{margin-top:22px;gap:17px}.studio-app .field{color:#8a739a;font-size:13px}.studio-app .field input,.studio-app .field select,.studio-app textarea{border-color:#e1d8ed;background:#fcfaff;color:var(--ink);border-radius:10px;min-height:46px}
.studio-app textarea:focus,.studio-app .field input:focus,.studio-app .field select:focus{outline:2px solid #c4b0f2;outline-offset:2px}
.studio-app .hint,.studio-app .help-note,.studio-app .preview-hint{color:#8a7897}.studio-app .file-tile,.studio-app .page-tile{background:#f8f5fc;border-color:#e4daed;border-radius:12px}.studio-app .tile-actions button{border-color:#e2d7ef;color:#765292;min-height:34px}
.studio-app .actions{gap:12px}.studio-app #run{position:relative;width:150px;min-width:150px;overflow:hidden;transition:width .3s cubic-bezier(.65,0,.35,1),border-radius .3s,background .2s,color .15s;white-space:nowrap}
.studio-app #run[data-phase=busy]{width:48px;min-width:48px;padding:0;border-radius:50%;color:transparent;opacity:1;box-shadow:none}
.studio-app #run[data-phase=busy]::after{content:"";position:absolute;width:18px;height:18px;border:3px solid #ffffff4d;border-top-color:#fff;border-radius:50%;left:12px;top:12px;animation:studio-spin .7s linear infinite}
.studio-app #run[data-phase=success]{background:#1e9e5a;box-shadow:none;color:white;min-width:150px}.studio-app #run[data-phase=error]{background:#b6474c;box-shadow:none;color:white}
.studio-app #message:not(:empty){padding:12px 15px;background:#f1ebfc;color:#75578e;border-radius:10px;border-left:3px solid #b299dd}.studio-app #message.error{background:#fff0ed;color:#b84d48;border-color:#e99483}
.studio-app .output-item{border-color:#e4dcee;border-radius:14px;padding:15px;gap:14px}.studio-app .output-item a{background:#efe8ff;border-color:#ded0f5;color:#7044ac;min-height:40px;display:flex;align-items:center}
.studio-app .comparison{display:block;width:100%;padding:0;border:0;background:transparent}.studio-app .comparison .compare-frame{max-height:480px;aspect-ratio:1.6;background:#f0ecf5}.studio-app .comparison .compare-frame img{max-height:none}
.studio-app .compare-captions{display:flex;justify-content:space-between;gap:15px;flex-wrap:wrap;margin:12px 0 2px;font-size:12px;color:#80718f}.studio-app .compare-instruction{font-size:11px;color:#9b8ca9;margin:8px 0 0}
.studio-app .result-text{background:#f7f3fc;border:1px solid #e6ddf0;color:#624d77;border-radius:12px}.studio-app .csv-preview th{background:#eee5fb}.studio-app .csv-preview td,.studio-app .csv-preview th{border-color:#e6dbef}
.studio-app footer{border-top:1px solid #e0d6ea;margin-top:30px;padding:25px 0;gap:12px;color:#9788a4}.studio-app footer .quiet{color:#9788a4}.studio-app footer a:hover{color:var(--blue)}
.studio-app dialog{color:var(--ink);background:#fcfaff;border-radius:18px}.studio-app dialog p{color:#806f90}.studio-app dialog::backdrop{background:#24143788;backdrop-filter:blur(4px)}
.studio-app button:focus-visible,.studio-app a:focus-visible{outline-color:#b599f4}.studio-app .growth-tool-guide{border-color:#e4d9f0;background:#fff;border-radius:16px;padding:28px;margin-top:25px}.studio-app .growth-tool-guide h2{color:#5c3a7b}
.sr-only{position:absolute;width:1px;height:1px;clip:rect(0,0,0,0);overflow:hidden;white-space:nowrap}
.studio-app[data-browsing=true] .studio-hero,.studio-app[data-browsing=true] .catalog-heading{display:none}
.studio-app[data-browsing=true] #catalog{padding-top:28px}
@keyframes studio-spin{to{transform:rotate(360deg)}}
::view-transition-group(studio-tool){animation-duration:.6s;animation-timing-function:cubic-bezier(.65,0,.35,1)}
::view-transition{pointer-events:none}
::view-transition-group(*),::view-transition-image-pair(*),::view-transition-old(*),::view-transition-new(*){pointer-events:none}
::view-transition-old(root),::view-transition-new(root){animation-duration:.3s}
@media(max-width:1050px){.studio-app .tool-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.studio-hero{gap:27px;padding:27px;min-height:0}.studio-app .studio-hero h1{font-size:40px}.hero-description{font-size:13px}.studio-app header{padding:0 28px}.hero-preview{padding:12px}.preview-drag{display:none}.hero-private{font-size:11px}.hero-kicker{font-size:11px}}
@media(max-width:760px){.studio-app header{height:68px;min-height:68px;display:flex;padding:0 18px;gap:12px}.studio-app .brand{font-size:23px}.studio-app .brand-sub{display:none}.studio-app #home-top{margin-left:auto;font-size:12px}.studio-app #bookmark{font-size:11px;padding:8px 10px;min-height:38px}.studio-app #categories{padding:16px 18px 0;flex-wrap:nowrap;overflow:auto;gap:4px;width:100%;scrollbar-width:none}.studio-app .nav-button{padding:9px 12px;min-height:42px;font-size:12px;flex-shrink:0}.studio-app .nav-button svg{display:none}.studio-app .nav-button:last-child{margin-left:0;font-size:11px}.studio-app main{padding:0 20px}.studio-hero{grid-template-columns:1fr;gap:27px;padding:27px 20px;margin:20px -5px 27px;min-height:0}.studio-app .studio-hero h1{font-size:43px;letter-spacing:-1.8px}.hero-kicker{margin:0 0 16px;font-size:12px}.hero-description{font-size:13px;line-height:1.85;margin:17px 0 19px}.hero-actions{gap:10px}.studio-app .hero-pick{min-height:47px;padding:12px 23px}.studio-app .hero-sample{min-height:47px;font-size:13px}.hero-private{margin:12px 0 13px}.hero-shortcuts{font-size:12px;gap:24px}.hero-preview{padding:11px;box-shadow:6px 8px 0 #d6ac48;transform:rotate(0)}.preview-top{padding-bottom:10px}.preview-tab{font-size:11px;padding:6px 9px}.preview-bottom strong{font-size:12px}.drop-instruction{font-size:10px;margin-top:10px}.catalog-heading{padding-top:25px;margin-bottom:18px}.catalog-heading h2{font-size:21px}.catalog-heading p{font-size:12px}.catalog-heading>span{display:none}.studio-app .tool-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.studio-app .tool-card{border-radius:13px;min-height:165px}.studio-app .tool-open{padding:17px 13px}.studio-app .tool-card h3{font-size:14px}.studio-app .tool-card p{font-size:12px;line-height:1.75}.studio-app .tool-icon{width:34px;height:34px;border-radius:10px}.studio-app .tag{font-size:10px}.studio-app .card-top{gap:8px;margin-bottom:14px}.studio-app .star-button{right:1px;top:6px;min-width:34px;min-height:34px;padding:6px}.studio-app .search{height:51px}.studio-app .search input{font-size:12px}.studio-app .quick-filters button{font-size:11px;padding:8px 10px}.studio-app .section-title h2{font-size:16px}.studio-app .section-title span{font-size:11px}.studio-app #workspace{padding:24px 0 0}.studio-app .work-heading h1,.studio-app .work-heading h2{font-size:25px}.studio-app .work-heading p{font-size:12px}.studio-app .work-surface{padding:17px;border-radius:15px}.studio-app .drop{padding:22px 12px;min-height:155px}.studio-app .drop strong{font-size:15px}.studio-app .drop small{font-size:11px}.studio-app .drop input{font-size:11px}.studio-app .field{font-size:12px;min-width:125px}.studio-app .hint{font-size:11px}.studio-app .comparison .compare-frame{aspect-ratio:1.15}.studio-app .compare-captions{font-size:10px}.studio-app .ai-notice{font-size:11px}.studio-app footer{font-size:10px;gap:8px;line-height:1.8}.studio-app .growth-tool-guide{padding:20px}.studio-app .growth-home nav{gap:7px}.studio-app .growth-home a{font-size:11px;padding:9px 11px}}
@media(hover:none),(pointer:coarse){.studio-app .tool-card:hover{transform:none}.studio-app .tool-card::after{display:none}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}.studio-app .tool-card:hover{transform:none}.studio-app .tool-card::after{display:none}.hero-preview{transform:none}::view-transition-group(*),::view-transition-old(*),::view-transition-new(*){animation:none!important}}

@media(prefers-reduced-motion:reduce){.studio-app #run[data-phase=busy]{width:150px;min-width:150px;border-radius:12px;color:#fff;padding:12px}.studio-app #run[data-phase=busy]::after{display:none}}
