*,:before,:after{box-sizing:border-box}:root{--bg:#fff5f7;--text:#2d1a1f;--text-sub:#8a6070;--btn-start-bg:#e8648a;--btn-start-text:#fff;--btn-stop-bg:#dc2626;--btn-stop-text:#fff;--btn-clear-bg:#fce4ec;--btn-clear-text:#2d1a1f;--btn-font-bg:#fce4ec;--btn-font-text:#2d1a1f;--interim-color:#c48ba0;--status-dot:#e8648a;--header-border:#f8bbd0;--error-bg:#fef2f2;--error-text:#991b1b;--notice-bg:#fce4ec;--notice-text:#880e4f;color:var(--text);background:var(--bg);-webkit-font-smoothing:antialiased;font-family:Hiragino Kaku Gothic ProN,Hiragino Sans,Meiryo,sans-serif;font-size:16px}body{background:var(--bg);margin:0}#root{width:100%;min-height:100svh}.mascot-speech{--mascot-speech-font-size:36px;--mascot-bg:var(--bg,#fff7fa);--mascot-bubble:var(--btn-clear-bg,#fff);--mascot-ink:var(--text,#000);--mascot-border:var(--header-border,#111);--mascot-shadow:0 14px 34px #58183924;width:100%;height:100%;color:var(--mascot-ink);flex-direction:column;justify-content:flex-end;align-items:center;gap:10px;padding:8px 12px 4px;display:flex;overflow:hidden}.mascot-speech__bubble{width:100%;min-height:calc(var(--mascot-speech-font-size) * 2.7);border:3px solid var(--mascot-border);background:var(--mascot-bubble);box-shadow:var(--mascot-shadow);border-radius:24px;flex:auto;padding:18px 18px 22px;display:flex;position:relative}.mascot-speech__bubble:before,.mascot-speech__bubble:after{content:"";width:0;height:0;position:absolute;left:50%;transform:translate(-50%)}.mascot-speech__bubble:before{border-top:30px solid var(--mascot-border);border-left:22px solid #0000;border-right:22px solid #0000;bottom:-29px}.mascot-speech__bubble:after{border-top:24px solid var(--mascot-bubble);border-left:17px solid #0000;border-right:17px solid #0000;bottom:-22px}.mascot-speech__body{overscroll-behavior:contain;scrollbar-width:thin;flex-direction:column;flex:auto;justify-content:flex-start;width:100%;display:flex;overflow-y:auto}.mascot-speech__text{color:var(--mascot-ink);font-size:var(--mascot-speech-font-size);letter-spacing:.01em;overflow-wrap:anywhere;white-space:pre-wrap;text-align:left;margin:0;font-weight:800;line-height:1.6}.mascot-speech__placeholder{color:var(--text-sub,#3c3c3c);font-size:var(--mascot-speech-font-size);text-align:center;margin:auto;font-weight:700;line-height:1.5}.mascot{transform-origin:50% 100%;flex:none;place-items:end center;width:min(48vw,190px);height:clamp(120px,24dvh,220px);display:grid;position:relative}.mascot--idle{animation:2.8s ease-in-out infinite mascot-idle-breath}.mascot--talking{animation:.24s ease-in-out infinite mascot-talk}.mascot--listening{animation:1.35s ease-in-out infinite mascot-listening-bob}.mascot__image,.mascot__lottie{object-fit:contain;object-position:bottom center;width:100%;height:100%;display:block}.mascot__sprite{width:var(--mascot-frame-width);height:var(--mascot-frame-height);background-image:var(--mascot-sprite-url);background-position:var(--mascot-frame-x) var(--mascot-frame-y);transform-origin:50% 100%;background-repeat:no-repeat;background-size:auto;max-width:100%;max-height:100%}.mascot__fallback{width:min(100%,160px);height:100%;position:relative}.mascot__fallback-head{background:#92b774;border:3px solid #101010;border-radius:48% 48% 42% 42%;width:132px;height:122px;position:absolute;top:0;left:50%;transform:translate(-50%)}.mascot__fallback-head:before,.mascot__fallback-head:after{content:"";background:#f3c982;border-radius:50%;width:56px;height:50px;position:absolute;top:78px}.mascot__fallback-head:before{left:16px}.mascot__fallback-head:after{right:16px}.mascot__fallback-eye{z-index:1;background:#111;border-radius:999px;width:14px;height:19px;position:absolute;top:40px}.mascot__fallback-eye:first-child{left:40px}.mascot__fallback-eye:nth-child(2){right:40px}.mascot__fallback-mouth{z-index:2;border-bottom:4px solid #111;border-radius:0 0 999px 999px;width:32px;height:12px;position:absolute;bottom:26px;left:50%;transform:translate(-50%)}.mascot--talking .mascot__fallback-mouth{background:#49251f;border:4px solid #111;border-radius:999px;height:20px}.mascot__fallback-body{background:#7ea360;border:3px solid #101010;border-radius:42px 42px 34px 34px;width:110px;height:96px;position:absolute;bottom:0;left:50%;transform:translate(-50%)}@keyframes mascot-idle-breath{0%,to{transform:translateY(0)scale(1)}50%{transform:translateY(-3px)scale(1.01)}}@keyframes mascot-listening-bob{0%,to{transform:translateY(0)}45%{transform:translateY(-11px)}}@keyframes mascot-talk{0%,to{transform:translateY(0)rotate(-1deg)}50%{transform:translateY(-5px)rotate(1deg)}}@media (width<=380px){.mascot-speech{padding-left:10px;padding-right:10px}.mascot-speech__bubble{border-radius:20px;padding:15px 14px 20px}}@media (prefers-reduced-motion:reduce){.mascot,.mascot--idle,.mascot--talking,.mascot--listening{animation:none}}.app{background:var(--bg);max-width:480px;height:100svh;color:var(--text);flex-direction:column;margin:0 auto;display:flex;overflow:hidden}body{background:var(--bg)}.header{border-bottom:1px solid var(--header-border);flex-shrink:0;justify-content:space-between;align-items:center;padding:12px 16px;display:flex}.app-title{color:var(--text);font-size:20px;font-weight:700}.theme-btn{border:1px solid var(--header-border);background:var(--btn-font-bg);color:var(--btn-font-text);cursor:pointer;border-radius:20px;padding:6px 14px;font-size:15px;line-height:1.4}.main{flex-direction:column;flex:1;justify-content:center;padding:4px;display:flex;overflow:hidden}.welcome{text-align:center;flex-direction:column;align-items:center;padding:24px 8px;display:flex}.mascot{object-fit:contain;-webkit-user-select:none;user-select:none;-webkit-user-drag:none;pointer-events:none;display:block}.mascot-idle{width:180px;max-width:55%;height:auto;margin-bottom:20px;animation:3s ease-in-out infinite bob}.mascot-bounce{width:200px;max-width:60%;height:auto;margin-bottom:12px;animation:1.1s ease-in-out infinite bounce}.mascot-small{width:96px;height:auto;margin-bottom:8px}.mascot-jump{animation:.6s ease-out jump}@keyframes bob{0%,to{transform:translateY(0)}50%{transform:translateY(-10px)}}@keyframes bounce{0%,to{transform:translateY(0)scale(1)}30%{transform:translateY(-16px)scale(1.03)}60%{transform:translateY(0)scale(1)}}@keyframes jump{0%{transform:translateY(0)scale(1)}35%{transform:translateY(-22px)scale(1.08)}70%{transform:translateY(0)scale(.98)}to{transform:translateY(0)scale(1)}}.listening-wait{flex-direction:column;justify-content:center;align-items:center;display:flex}.welcome-text{color:var(--text);margin-bottom:24px;font-size:26px;font-weight:700;line-height:1.6}.welcome-note{color:var(--text-sub);font-size:15px;line-height:1.7}.text-area{flex:1;justify-content:center;align-items:center;padding:12px 8px;display:flex;overflow:hidden}.latest-wrap{flex-direction:column;justify-content:center;align-items:center;gap:.6em;width:100%;display:flex}.prev-line{color:var(--text-sub);text-align:center;word-break:break-all;opacity:.7;margin:0;font-size:20px;line-height:1.4}.latest-line{color:var(--text);text-align:center;word-break:break-all;margin:0;font-weight:700;line-height:1.5;animation:.45s ease-out popIn}@keyframes popIn{0%{opacity:0;transform:scale(.9)translateY(12px)}60%{opacity:1;transform:scale(1.02)translateY(0)}to{opacity:1;transform:scale(1)translateY(0)}}.placeholder{color:var(--interim-color);text-align:center;margin:0;font-size:24px}.notice-box{background:var(--notice-bg);text-align:center;border-radius:12px;padding:24px 20px}.notice-title{color:var(--notice-text);margin-bottom:12px;font-size:22px;font-weight:700}.notice-body{color:var(--notice-text);font-size:18px;line-height:1.7}.error-banner{background:var(--error-bg);border-radius:12px;margin-top:8px;padding:16px 20px}.error-text{color:var(--error-text);white-space:pre-line;text-align:center;font-size:18px;line-height:1.7}.footer{border-top:1px solid var(--header-border);flex-direction:column;flex-shrink:0;gap:12px;padding:12px 16px 20px;display:flex}.font-controls{justify-content:center;gap:10px;display:flex}.font-btn{text-align:center;border:1px solid var(--header-border);background:var(--btn-font-bg);max-width:140px;color:var(--btn-font-text);cursor:pointer;border-radius:10px;flex:1;padding:10px 8px;font-family:inherit;font-size:16px;font-weight:700;line-height:1.4}.font-btn:disabled{opacity:.35;cursor:default}.main-controls{gap:10px;display:flex}.btn{cursor:pointer;border:none;border-radius:12px;flex:1;padding:16px 12px;font-family:inherit;font-size:20px;font-weight:700;line-height:1.3;transition:opacity .15s}.btn:active{opacity:.8}.btn-start{background:var(--btn-start-bg);color:var(--btn-start-text)}.btn-stop{background:var(--btn-stop-bg);color:var(--btn-stop-text)}.btn-clear{background:var(--btn-clear-bg);color:var(--btn-clear-text);flex:none;width:110px;font-size:17px}.status-bar{justify-content:center;align-items:center;gap:8px;display:flex}.status-dot{background:var(--status-dot);border-radius:50%;width:10px;height:10px;animation:1.5s ease-in-out infinite pulse}.status-text{color:var(--text-sub);font-size:16px;font-weight:700}@keyframes pulse{0%,to{opacity:1}50%{opacity:.35}}.header-btns{gap:8px;display:flex}.update-banner{color:#fff;background:#e8648a;flex-shrink:0;justify-content:space-between;align-items:center;gap:12px;padding:10px 16px;display:flex}.update-text{font-size:15px;font-weight:700}.update-btn{color:#fff;cursor:pointer;background:0 0;border:2px solid #fff;border-radius:20px;flex-shrink:0;padding:6px 18px;font-family:inherit;font-size:15px;font-weight:700}.dict-panel{background:var(--btn-font-bg);border-bottom:2px solid var(--header-border);flex-direction:column;flex-shrink:0;gap:10px;max-height:60vh;padding:14px 16px;display:flex;overflow-y:auto}.dict-title{color:var(--text);margin:0;font-size:15px;font-weight:700}.dict-sub{color:var(--text-sub);font-size:12px;font-weight:400}.dict-input-row{align-items:flex-end;gap:8px;display:flex}.dict-field{flex-direction:column;flex:1;gap:4px;min-width:0;display:flex}.dict-label{color:var(--text-sub);font-size:12px;font-weight:700}.dict-input{border:1px solid var(--header-border);background:var(--bg);width:100%;color:var(--text);box-sizing:border-box;border-radius:8px;padding:8px 10px;font-family:inherit;font-size:15px}.dict-arrow{color:var(--text-sub);flex-shrink:0;padding-bottom:8px;font-size:18px}.dict-add-btn{background:var(--btn-start-bg);width:100%;color:var(--btn-start-text);cursor:pointer;border:none;border-radius:8px;padding:10px 14px;font-family:inherit;font-size:16px;font-weight:700}.dict-add-btn:disabled{opacity:.4;cursor:default}.dict-list{flex-direction:column;gap:6px;max-height:160px;margin:0;padding:0;list-style:none;display:flex;overflow-y:auto}.dict-item{background:var(--bg);border:1px solid var(--header-border);border-radius:8px;align-items:center;gap:6px;padding:8px 10px;font-size:15px;display:flex}.dict-from{color:var(--text-sub);text-overflow:ellipsis;white-space:nowrap;flex:1;min-width:0;overflow:hidden}.dict-to{color:var(--text);text-overflow:ellipsis;white-space:nowrap;flex:1;min-width:0;font-weight:700;overflow:hidden}.dict-remove-btn{border:1px solid var(--header-border);background:var(--btn-clear-bg);color:var(--btn-clear-text);cursor:pointer;border-radius:6px;flex-shrink:0;padding:4px 10px;font-family:inherit;font-size:13px}.dict-empty{color:var(--text-sub);text-align:center;margin:0;font-size:13px}@media (orientation:landscape) and (height<=500px){.app{max-width:100%}.header{padding:5px max(16px, env(safe-area-inset-right)) 5px max(16px, env(safe-area-inset-left))}.app-title{font-size:15px}.theme-btn{padding:4px 10px;font-size:13px}.main{padding:6px max(16px, env(safe-area-inset-right)) 6px max(16px, env(safe-area-inset-left))}.welcome-text{font-size:20px}.welcome-note{font-size:13px}.footer{padding:6px max(12px, env(safe-area-inset-right)) max(6px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));flex-direction:row;align-items:stretch;gap:8px}.font-controls{flex-direction:column;flex-shrink:0;justify-content:center;gap:5px;width:72px}.font-btn{max-width:100%;padding:5px 4px;font-size:12px;line-height:1.2}.main-controls{flex-direction:column;flex:1;gap:5px}.btn{padding:8px 12px;font-size:16px}.btn-clear{width:auto;font-size:14px}.status-bar{flex-direction:column;flex-shrink:0;justify-content:center;gap:4px}.status-dot{width:8px;height:8px}.status-text{writing-mode:vertical-rl;font-size:11px}}
