:root{--paper:#f5f2eb;--ink:#252a27;--muted:#5c675d;--line:#dcded5;--coral:#bc4d36;--accent:#d3e4bd;--dark:#1d2421}*{box-sizing:border-box}body{margin:0;background:var(--paper);color:var(--ink);font:16px/1.5 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}button,input,textarea{font:inherit}button,a,summary{touch-action:manipulation;-webkit-tap-highlight-color:transparent}button{cursor:pointer;border:0}button:disabled{opacity:.4;cursor:default}a{color:inherit}button:focus-visible,a:focus-visible,input:focus-visible,textarea:focus-visible,summary:focus-visible{outline:3px solid #bc4d36;outline-offset:3px}[hidden]{display:none!important}.topbar{max-width:800px;margin:auto;padding:16px 20px 12px;display:flex;align-items:center;justify-content:space-between;gap:12px}.brand{display:flex;gap:10px;align-items:center;font-size:18px;font-weight:800;letter-spacing:-.4px}.brand img{border-radius:10px}.brand small{display:block;font-size:11px;font-weight:550;letter-spacing:0;color:var(--muted);margin-top:2px}.round-button{width:44px;height:44px;flex:0 0 44px;border-radius:50%;background:#e8ebe2;color:var(--ink);font-size:23px}.steps{display:flex;gap:8px;max-width:760px;margin:0 auto 12px;padding:0 20px}.steps button{flex:1;min-height:44px;border-radius:10px;background:transparent;color:#63705e;font-size:15px;font-weight:700;display:flex;align-items:center;justify-content:center;gap:9px}.steps button span{width:23px;height:23px;display:grid;place-items:center;font-size:12px;background:#e2e6db;border-radius:50%}.steps button[aria-current=step]{background:#e1e9d5;color:#2d4424}.steps button[aria-current=step] span{background:#34472d;color:white}main{max-width:760px;margin:auto;padding:0 20px 16px}.script-card{background:#fffefa;border:1px solid var(--line);border-radius:18px;padding:24px}.card-head{margin-bottom:16px}.card-head h1{font-size:27px;letter-spacing:-.9px;line-height:1.2;margin:0 0 6px;font-weight:800}.card-head p{margin:0;font-size:14px;color:var(--muted)}.saved{font-size:12px;color:#4f6b40;display:block;margin-top:10px}.saved:before{content:'✓ ';font-weight:800}textarea{display:block;width:100%;height:clamp(210px,calc(100dvh - 480px),440px);min-height:180px;resize:vertical;border:1px solid #dde2d3;background:#f6f7f0;border-radius:12px;padding:18px;color:#2d352d;font-size:20px;line-height:1.65;font-weight:600}textarea::placeholder{color:#697265}.script-meta{display:flex;justify-content:space-between;gap:8px;font-size:12px;color:var(--muted);margin:10px 1px}.script-actions{display:flex;gap:8px;margin-bottom:15px}.script-actions button{min-height:44px;padding:8px 14px;border-radius:9px;background:#eef1e7;color:#425438;font-size:14px;font-weight:700}.primary-button{display:flex;justify-content:center;align-items:center;gap:12px;min-height:52px;width:100%;background:var(--coral);color:white;border-radius:12px;text-decoration:none;font-size:16px;font-weight:750;padding:12px 16px}.primary-button span{margin-left:auto}.private-note{font-size:11px;text-align:center;margin:12px 0 0;color:var(--muted)}.status{font-size:12px;line-height:1.5;color:var(--muted);text-align:center;padding:0 8px;margin:12px 0 0;overflow-wrap:anywhere}.status.error{color:#a63321;font-weight:650}.studio-card{display:flex;flex-direction:column;gap:10px;min-width:0}.studio-head{display:flex;justify-content:space-between;align-items:center;gap:6px}.text-button{background:transparent;color:#435637;min-height:44px;padding:8px 6px;font-size:14px;font-weight:700}.modes{display:flex;background:#e5e9df;border-radius:10px;padding:3px;gap:2px}.modes button{min-height:40px;padding:8px 12px;background:transparent;border-radius:8px;color:#5e6b55;font-size:14px;font-weight:700}.modes button.selected{background:#fffefa;color:#2c4222;box-shadow:0 1px 4px #0001}.stage{background:var(--dark);position:relative;overflow:hidden;border-radius:18px;color:white;flex:1;min-height:240px;width:100%}.stage>video{position:absolute;inset:0;width:100%;height:100%;object-fit:contain}.stage>video.mirrored{transform:scaleX(-1)}.stage-top,.stage-bottom{position:absolute;left:16px;right:12px;z-index:3;display:flex;align-items:center;justify-content:space-between;gap:6px;pointer-events:none}.stage-top{top:10px}.stage-top button{pointer-events:auto;background:#17201b99;border:1px solid #ffffff33;color:white}.stage-top>span{background:#17201bbf;font-size:10px;letter-spacing:.4px;padding:7px 8px;border-radius:7px;font-weight:650}.stage-top i{width:6px;height:6px;display:inline-block;background:#bcd49b;border-radius:50%;margin-right:4px}.stage.recording .stage-top i{background:#ff7465}.stage-bottom{bottom:12px;font-size:10px;color:#e4eadd}.stage-bottom span{background:#17201bbf;padding:5px 8px;border-radius:6px}#duration{font-family:monospace;font-size:15px;font-variant-numeric:tabular-nums}.camera-placeholder{position:absolute;inset:58px 16px 44px;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center}.lens-icon{font-size:43px;line-height:1.4;color:#d3e4bd}.camera-placeholder h2{font-size:23px;letter-spacing:-.5px;line-height:1.25;margin:6px 0 10px}.camera-placeholder p{font-size:13px;line-height:1.65;color:#d0d9c9;margin:0 0 17px}.camera-placeholder .primary-button{width:auto;padding:12px 25px;background:#d3e4bd;color:#293d1f}.camera-placeholder small{font-size:10px;color:#bdcbb4;margin:8px 0 0}.camera-placeholder .text-button{font-size:12px;color:#d3e4bd;text-decoration:underline;text-underline-offset:4px}.prompter{position:absolute;top:62px;left:7%;width:86%;height:48%;z-index:2;overflow:auto;overscroll-behavior:contain;scrollbar-width:none;background:#000a;border-radius:12px;mask-image:linear-gradient(transparent,#000 6%,#000 86%,transparent);-webkit-mask-image:linear-gradient(transparent,#000 6%,#000 86%,transparent)}.prompter::-webkit-scrollbar{display:none}#promptText{white-space:pre-wrap;overflow-wrap:anywhere;font-size:36px;font-weight:750;line-height:1.45;padding:24px 16px 240px;text-shadow:0 2px 4px #000}.reading-line{position:absolute;left:1.5%;top:87px;color:var(--accent);font-size:24px;z-index:3}.countdown{position:absolute;inset:0;z-index:5;display:grid;place-items:center;background:#0008;font-size:96px;font-weight:800}.quick-controls{display:flex;align-items:center;justify-content:space-between;gap:6px;background:#e9ede2;border-radius:12px;padding:2px 4px}.quick-controls button{height:44px;min-width:44px;padding:0 8px;background:transparent;border-radius:8px;color:#354a2b;font-size:19px;font-weight:700}.quick-controls button:active{background:#d6dfca}.quick-controls>button{font-size:24px}.quick-speed,.quick-font{display:flex;align-items:center;gap:2px}.quick-speed span{font-size:14px;font-variant-numeric:tabular-nums;min-width:38px;text-align:center}.quick-font{border-left:1px solid #cdd5c3;padding-left:8px}.transport{display:flex;align-items:center;justify-content:center;gap:12px;min-height:58px}.record{display:flex;align-items:center;justify-content:center;gap:10px;min-height:56px;min-width:168px;border-radius:32px;background:var(--coral);color:white;padding:12px 16px;font-size:16px;font-weight:750;flex:1;max-width:290px}.record-dot{width:17px;height:17px;flex:0 0 17px;background:white;border-radius:50%}.record.active .record-dot{border-radius:3px}.side-action{background:transparent;color:#4c5b42;min-width:48px;min-height:52px;padding:2px;font-size:23px;line-height:1.1}.side-action small,.side-action span{display:block}.side-action small{font-size:10px;font-weight:700;margin-top:4px}.result-reopen{font-size:12px;min-height:32px;padding:0;text-decoration:underline}.recording-result{position:fixed;inset:16px;z-index:20;max-width:640px;margin:auto;background:#fffefa;border:1px solid var(--line);border-radius:18px;padding:24px;overflow:auto;box-shadow:0 0 0 100vmax #17201bd9;color:var(--ink)}.recording-result h2{font-size:28px;margin:0;letter-spacing:-.5px}.eyebrow{font-size:10px;color:#607450;font-weight:750;letter-spacing:1px;margin:0 0 6px}.recording-result>p{font-size:13px;color:var(--muted)}.recording-result video{display:block;width:100%;max-height:48dvh;border-radius:12px;background:#17201b;margin:16px 0}.result-actions{display:grid;gap:10px}.secondary-button{min-height:48px;padding:11px 16px;background:#e4ebd9;color:#344b27;border-radius:10px;font-size:15px;font-weight:700}.result-warning{padding:10px 12px;background:#f9efe4;border-radius:10px;font-size:13px!important;color:#6c4d30!important}.recording-result>.text-button{width:100%}dialog{border:1px solid var(--line);border-radius:20px;width:min(480px,calc(100% - 24px));max-height:calc(100dvh - 32px);overflow:auto;padding:24px;background:#fffefa;color:var(--ink);box-shadow:0 12px 70px #0004}dialog::backdrop{background:#17201bc9}.dialog-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:20px}.dialog-head h2{font-size:23px;line-height:1.25;letter-spacing:-.6px;margin:0;font-weight:750}.dialog-head .round-button{font-size:27px}dialog p,dialog li{font-size:14px;color:var(--muted);line-height:1.7}dialog h3{font-size:17px;margin:16px 0 8px}dialog ol{padding-left:22px}dialog li{margin-bottom:10px}dialog summary{font-size:14px;font-weight:700;cursor:pointer;min-height:44px;padding:10px 0}.setting{margin-bottom:24px}.setting label{display:flex;align-items:center;justify-content:space-between;font-size:16px;font-weight:700}.setting output{font-size:15px;color:#52703e}input[type=range]{width:100%;height:36px;accent-color:#526b40;margin:8px 0 0}.speed-presets{display:flex;gap:8px}.speed-presets button{flex:1;min-height:44px;background:#edf0e7;color:#405635;border-radius:8px;font-size:13px;font-weight:650}.speed-presets button[aria-pressed=true]{background:#344b27;color:white}.toggles{display:grid;gap:20px;margin:22px 0 26px}.toggles label{display:flex;gap:10px;align-items:center;font-size:14px;font-weight:650}.toggles input{height:22px;width:22px;flex:0 0 22px;accent-color:#526b40}.toggles small{display:block;font-weight:400;font-size:12px;color:var(--muted);margin-top:2px}.install-card{padding:4px 16px 16px;background:#eef2e6;border-radius:12px;margin:20px 0}.install-card p{margin-top:0}.install-card button{width:100%}.help-steps{counter-reset:steps;padding-left:22px}.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}body[data-view=studio]{height:100dvh;display:flex;flex-direction:column;overflow:hidden}body[data-view=studio] .topbar,body[data-view=studio] .steps{width:100%;flex-shrink:0}body[data-view=studio] main{display:flex;flex-direction:column;width:100%;flex:1;min-height:0;padding-bottom:max(10px,env(safe-area-inset-bottom))}body[data-view=studio] .studio-card{flex:1;min-height:0}body[data-view=studio] .status{min-height:36px;flex-shrink:0;margin-top:8px;font-size:11px}body[data-view=studio] .stage{min-height:200px}body.focus-view .topbar,body.focus-view .steps{display:none}body.focus-view main{padding-top:max(8px,env(safe-area-inset-top))}body.focus-view .stage{border-radius:12px}body[data-mode=practice] .stage{background:#142019}body[data-mode=practice] .prompter{height:75%;background:transparent}body[data-mode=practice] .record-dot{background:none;border-left:15px solid white;border-top:9px solid transparent;border-bottom:9px solid transparent;border-radius:0;flex-basis:15px;width:15px;height:18px}body[data-mode=practice] .record.active .record-dot{border:0;border-left:5px solid white;border-right:5px solid white;width:16px;height:18px;background:transparent}body[data-mode=practice] .stage-bottom #duration{visibility:hidden}@media(max-width:500px){.topbar{padding:12px 16px 8px}.steps{padding:0 16px;margin-bottom:10px}main{padding:0 16px 16px}.script-card{padding:18px;border-radius:16px}.card-head h1{font-size:26px}.card-head{margin-bottom:12px}textarea{font-size:19px;padding:14px}.script-actions{margin-bottom:12px}.script-actions button{padding:8px 11px;font-size:13px}.private-note{font-size:10px}.studio-head{gap:4px}.studio-head>.text-button{font-size:13px}.modes button{padding:8px 10px;font-size:13px}.stage{border-radius:14px}.quick-controls{gap:2px}.quick-font{padding-left:5px;gap:0}.transport{gap:8px}.record{min-width:155px}.camera-placeholder p{font-size:12px;margin-bottom:12px}.camera-placeholder h2{font-size:21px}.camera-placeholder small{font-size:9px}.recording-result{inset:10px;padding:18px}dialog{padding:20px}.dialog-head h2{font-size:21px}body[data-view=studio] main{padding-left:10px;padding-right:10px}body[data-view=studio] .status{padding:0 6px}}
@media(max-height:700px){body[data-view=studio] .topbar{padding-top:6px;padding-bottom:4px}body[data-view=studio] .steps{margin-bottom:4px}body[data-view=studio] .studio-head{min-height:40px}body[data-view=studio] .studio-card{gap:6px}.camera-placeholder{inset:52px 12px 38px}.camera-placeholder .lens-icon{display:none}.camera-placeholder h2{font-size:19px;margin:0 0 5px}.camera-placeholder p{font-size:11px;margin-bottom:8px}.camera-placeholder .primary-button{min-height:44px;padding:8px 18px}.camera-placeholder small{display:none}.camera-placeholder .text-button{min-height:36px}.prompter{top:57px}.reading-line{top:82px}body[data-view=studio] .status{margin-top:4px;min-height:32px;font-size:10px}.record{min-height:50px}}
@media(orientation:landscape) and (max-height:550px){body[data-view=studio] .topbar,body[data-view=studio] .steps{display:none}body[data-view=studio] main{max-width:1000px;padding-top:4px}body[data-view=studio] .studio-card{display:grid;grid-template-columns:minmax(0,1fr) 225px;grid-template-rows:44px 1fr 58px;gap:6px 16px}body[data-view=studio] .stage{grid-column:1;grid-row:1/4;min-height:160px}body[data-view=studio] .studio-head{grid-column:2;grid-row:1;flex-wrap:wrap}body[data-view=studio] .studio-head>.text-button{display:block;width:44px;min-width:44px;font-size:0}body[data-view=studio] .studio-head>.text-button:before{content:"‹";font-size:26px}body[data-view=studio] .studio-head .modes button{font-size:12px;padding:6px}body[data-view=studio] .studio-head .modes{gap:0}body[data-view=studio] .quick-controls{grid-column:2;grid-row:2;flex-wrap:wrap;align-content:center;justify-content:center}body[data-view=studio] .transport{grid-column:2;grid-row:3;gap:2px}.record{min-width:130px;font-size:14px;padding:10px}.side-action{min-width:40px}body[data-view=studio] .status{font-size:10px;min-height:24px}.camera-placeholder .lens-icon{display:none}}

.recording-result{width:min(640px,calc(100% - 24px));max-height:calc(100dvh - 24px)}
@media(orientation:landscape) and (max-height:550px){body[data-view=studio] .studio-head{display:grid;grid-template-columns:44px minmax(0,1fr) 44px;gap:3px}body[data-view=studio] .studio-head>.text-button{height:44px;padding:0;line-height:1;display:grid;place-items:center}body[data-view=studio] .studio-head .modes{min-width:0;padding:2px}body[data-view=studio] .studio-head .modes button{min-width:0;flex:1;font-size:11px;padding:3px;white-space:nowrap}}

.saved.error{color:#a63321}.saved.error:before{content:'○ '}.storage-notice{font-size:13px;line-height:1.5;padding:12px;border:1px solid #d5ac79;border-radius:10px;background:#fff1dd;color:#6b451f;margin:0 0 12px}
