/* CashFlow Studio visuals bound to the live ledger and existing routes. */
body.cashflow-studio{overflow-x:hidden}
html[data-theme="dark"] body.cashflow-studio{background:radial-gradient(ellipse at 78% 3%,#324a2940,transparent 33%),linear-gradient(135deg,#101817,#131d1b 55%,#151d17);color:#eaf0e8}
html[data-theme="light"] body.cashflow-studio{background:radial-gradient(ellipse at 78% 3%,#eee3bd75,transparent 35%),linear-gradient(135deg,#f5f4ef,#edf3ed 58%,#f7f2e7)}
.cashflow-studio .sidebar{width:252px;background:linear-gradient(180deg,#111b19f5,#0c1513f8);border-right-color:#ffffff12;backdrop-filter:blur(18px)}
.cashflow-studio .workspace{margin-left:252px;background:transparent}
.cashflow-studio .topbar{height:70px;background:#101817b8;border-bottom-color:#ffffff12;backdrop-filter:blur(18px)}
.cashflow-studio .view-root{max-width:1480px;padding:32px clamp(20px,3.7vw,52px) 70px}
.cashflow-studio .nav-label,.cashflow-studio .branch-field label{letter-spacing:1.5px}
.studio-nav-tag{margin-left:auto;color:#d4f2a8;background:#b9ee7416;border:1px solid #b9ee7428;padding:3px 6px;border-radius:6px;font-size:7px;font-weight:800;letter-spacing:.7px}
.studio-welcome-row{display:flex;align-items:flex-end;justify-content:space-between;gap:24px;margin-bottom:22px}
.studio-date-label{display:flex;align-items:center;gap:8px;color:#9dae9f;font-size:9px;font-weight:750;letter-spacing:1.25px}
.studio-date-label i{width:7px;height:7px;border-radius:50%;background:#b9ee74;box-shadow:0 0 11px #b9ee7499}
.studio-date-label span{color:#708075}
.studio-welcome-row h1{margin:11px 0 8px;color:#edf4ea;font:720 clamp(27px,3.4vw,40px)/1.06 Inter,"Segoe UI",system-ui,sans-serif;letter-spacing:-1.5px}
.studio-welcome-row h1 em{color:#c7ef8f;font-style:normal}
.studio-welcome-row>div:first-child>p{margin:0;color:#a3b0a6;font-size:11px;line-height:1.55}
.studio-mode-switch{display:flex;align-items:center;gap:3px;flex:none;padding:5px;border:1px solid #ffffff16;border-radius:11px;background:#ffffff08}
.studio-mode-switch>span{padding:0 8px;color:#9aa89f;font-size:9px}
.studio-mode-switch button{min-width:54px;padding:8px 11px;border:0;border-radius:7px;background:transparent;color:#9ba9a0;font-size:9px;font-weight:700;transition:background .2s,color .2s,transform .2s}
.studio-mode-switch button:hover{transform:translateY(-1px);color:#f4f7ef}
.studio-mode-switch button.active{background:#b9ee7421;color:#ddf6b7;box-shadow:inset 0 0 0 1px #b9ee7425}
.studio-hero-grid{display:grid;grid-template-columns:minmax(0,1.27fr) minmax(310px,.83fr);gap:14px}
.studio-balance-card,.studio-quick-card,.studio-assistant-card,.studio-assistant-guide,.studio-stat,.studio-activity,.studio-invoices{position:relative;overflow:hidden;border:1px solid #ffffff13;border-radius:19px;box-shadow:0 18px 52px #0002}
.studio-balance-card{min-height:336px;padding:22px 24px 15px;background:radial-gradient(ellipse at 86% 120%,#b9ee741c,transparent 49%),linear-gradient(145deg,#1d2b25,#151f1c 72%);isolation:isolate}
.studio-balance-card:before{content:"";position:absolute;z-index:-1;inset:-45% -30% auto auto;width:440px;height:440px;border:1px solid #b9ee7417;border-radius:50%;box-shadow:0 0 0 32px #b9ee7405,0 0 0 72px #b9ee7403;animation:studioOrbit 48s linear infinite}
.studio-balance-card:after{content:"";position:absolute;z-index:-1;right:-30px;bottom:-155px;width:310px;height:310px;border:1px dashed #c9ed9140;border-radius:50%;animation:studioOrbit 70s linear infinite reverse}
.studio-balance-top{display:flex;align-items:center;justify-content:space-between}
.studio-eyebrow{color:#aab9a8;font-size:8px;font-weight:800;letter-spacing:1.35px}
.studio-info{display:inline-grid;place-items:center;width:13px;height:13px;margin-left:4px;border:1px solid #aabd9d88;border-radius:50%;font:700 8px Georgia,serif;letter-spacing:0}
.studio-eye{width:29px;height:29px;border:1px solid #ffffff19;border-radius:9px;background:#ffffff08;color:#d9e7d6;font-size:14px}
.studio-balance-value{display:flex;align-items:baseline;gap:9px;margin:12px 0 2px;color:#f0f4e9;font-size:clamp(30px,3.6vw,43px);font-variant-numeric:tabular-nums;font-weight:720;letter-spacing:-1.6px}
.studio-balance-value small{color:#aab9a8;font-size:12px;font-weight:600;letter-spacing:0}
.studio-balance-caption{display:flex;align-items:center;justify-content:space-between;gap:12px;color:#84948a;font-size:8px}
.studio-balance-caption>span:first-child{display:flex;align-items:center;gap:6px}
.studio-balance-caption i,.studio-balance-foot>span i{width:6px;height:6px;display:inline-block;border-radius:50%;background:#b9ee74;box-shadow:0 0 9px #b9ee7480}
.studio-chart-wrap{height:145px;margin:10px 0 4px;position:relative}
.studio-chart-wrap svg{width:100%;height:calc(100% - 18px);overflow:visible}
.studio-chart-area{fill:url(#studioArea)}
.studio-chart-line{fill:none;stroke:#b9ee74;stroke-width:2.1;vector-effect:non-scaling-stroke;filter:drop-shadow(0 0 7px #b9ee7470)}
.studio-chart-point{fill:#e4f7c5;stroke:#b9ee74;stroke-width:3;vector-effect:non-scaling-stroke;filter:drop-shadow(0 0 7px #b9ee74)}
.studio-chart-labels{position:absolute;left:0;right:0;bottom:0;display:flex;justify-content:space-between;color:#74847a;font-size:7px}
.studio-balance-foot{display:flex;align-items:center;justify-content:space-between;gap:12px;padding-top:10px;border-top:1px solid #ffffff12;color:#87978c;font-size:8px}
.studio-balance-foot>span{display:flex;align-items:center;gap:6px}
.studio-balance-foot button,.studio-section-head button{border:0;background:transparent;color:#c9e89a;font-size:8px;font-weight:700}
.studio-balance-foot button b,.studio-section-head button b{padding-left:4px;font-size:12px}
.studio-balance-orb{position:absolute;right:17%;top:18%;width:5px;height:5px;border-radius:50%;background:#e1c773;box-shadow:0 0 14px 4px #e1c77345;animation:studioGlow 3.5s ease-in-out infinite alternate}
.studio-quick-card{padding:19px 20px 16px;background:linear-gradient(145deg,#202b26,#17211e 76%)}
.studio-quick-head,.studio-assistant-card-head{display:flex;align-items:center;gap:11px}
.studio-quick-icon{display:grid;place-items:center;flex:none;width:37px;height:37px;border:1px solid #b9ee7433;border-radius:12px;background:#b9ee7415;color:#c7ed95;font-size:19px;box-shadow:0 0 25px #b9ee7410}
.studio-quick-head h2,.studio-assistant-card-head h2{margin:4px 0 0;color:#edf3e8;font-size:15px;letter-spacing:-.45px}
.studio-quick-card>p{margin:12px 0 14px;color:#a0aea4;font-size:9px;line-height:1.55}
.studio-prompt-label,.studio-assistant-label{display:block;margin-bottom:6px;color:#aab9ad;font-size:8px;font-weight:700}
.studio-prompt-box{position:relative;display:flex;align-items:stretch;min-height:66px;border:1px solid #ffffff18;border-radius:11px;background:#101a16;transition:border-color .2s,box-shadow .2s}
.studio-prompt-box:focus-within{border-color:#b9ee7470;box-shadow:0 0 0 3px #b9ee7412}
.studio-prompt-box textarea{width:100%;min-width:0;resize:vertical;border:0;background:transparent;color:#e8f1e7;padding:11px 42px 11px 12px;font:10px/1.55 Inter,"Segoe UI",system-ui,sans-serif;outline:0}
.studio-prompt-box textarea::placeholder{color:#687970}
.studio-mic{position:absolute;right:7px;top:7px;display:grid;place-items:center;width:31px;height:31px;border:1px solid #ffffff16;border-radius:9px;background:#ffffff08;color:#cce9a2;font-size:17px}
.studio-mic.recording{color:#ffe0c9;background:#a94f3e44;border-color:#e88c6e88;animation:studioRecord 1s ease-in-out infinite alternate}
.studio-prompt-actions{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-top:9px}
.studio-prompt-actions>span{color:#9bae8e;font-size:7px}
.studio-analyze{display:inline-flex;align-items:center;justify-content:center;gap:15px;min-height:35px;padding:0 12px;border:1px solid #c5ed8c35;border-radius:9px;background:linear-gradient(130deg,#c4ee8b,#a9df69);color:#1b2e20;font-size:9px;font-weight:800;box-shadow:0 5px 17px #b9ee7415;transition:transform .18s,box-shadow .18s}
.studio-analyze:hover{transform:translateY(-2px);box-shadow:0 9px 22px #b9ee7429}
.studio-analyze b{font-size:13px}
.studio-open-assistant{display:block;margin:8px 0 0 auto;border:0;background:transparent;color:#95aa9b;font-size:8px}
.studio-open-assistant:hover{color:#daf0be}
.studio-assistant-result:empty{display:none}
.studio-assistant-result .studio-draft-card{margin-top:11px;padding:11px;border:1px solid #b9ee7430;border-radius:10px;background:#b9ee740b}
.studio-draft-title{display:flex;align-items:center;gap:7px;color:#d9edc5;font-size:9px}
.studio-draft-title>span{display:grid;place-items:center;width:18px;height:18px;border-radius:50%;background:#b9ee7421;color:#c8ef99}
.studio-draft-card>p{margin:6px 0 9px;color:#a3b19f;font-size:8px}
.studio-draft-row{display:flex;justify-content:space-between;gap:10px;padding:5px 0;border-top:1px solid #ffffff0e;color:#aebaae;font-size:8px}
.studio-draft-row b{flex:none;color:#e4efda;font-variant-numeric:tabular-nums}
.studio-draft-card>small{display:block;margin-top:6px;color:#87968a;font-size:7px;line-height:1.45}
.studio-analysis-hint{padding:9px;color:#9eae9e;font-size:8px}
.studio-stat-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin:12px 0}
.studio-stat{min-height:116px;padding:14px 15px;background:linear-gradient(140deg,#1a2520d9,#141e1bcf);border-radius:15px}
.studio-stat-top{display:flex;align-items:center;justify-content:space-between;gap:8px;color:#99a79d;font-size:7px;font-weight:750;letter-spacing:.7px}
.studio-stat-icon{display:grid;place-items:center;width:23px;height:23px;border-radius:8px;font-size:12px;font-style:normal}
.studio-stat-icon.positive{background:#b9ee7415;color:#c2e98b}.studio-stat-icon.negative{background:#e58c7818;color:#e9a18f}.studio-stat-icon.gold{background:#dbbd671a;color:#e6cf83}.studio-stat-icon.lilac{background:#b8a0df18;color:#c3b1e4}
.studio-stat>b{display:block;margin:11px 0 3px;color:#e9f1e6;font-size:17px;font-variant-numeric:tabular-nums;letter-spacing:-.4px}
.studio-stat>b small{color:#9caa9e;font-size:8px;font-weight:600;letter-spacing:0}
.studio-stat>small{display:block;color:#809087;font-size:7px;line-height:1.4}
.studio-spark{position:absolute;right:15px;bottom:16px;display:flex;align-items:end;gap:3px;height:23px;opacity:.7}
.studio-spark i{width:4px;border-radius:4px 4px 1px 1px;background:#a9d976;transform-origin:bottom;animation:studioBar 2.1s ease-in-out infinite alternate}
.studio-spark i:nth-child(1){height:7px}.studio-spark i:nth-child(2){height:12px;animation-delay:-.5s}.studio-spark i:nth-child(3){height:9px;animation-delay:-1s}.studio-spark i:nth-child(4){height:18px;animation-delay:-.8s}.studio-spark i:nth-child(5){height:13px;animation-delay:-.3s}.studio-spark i:nth-child(6){height:20px;animation-delay:-1.4s}.studio-spark i:nth-child(7){height:16px;animation-delay:-.9s}
.studio-spark.negative i{background:#d98c7b}
.studio-progress{display:block;width:100%;height:3px;margin-top:10px;border-radius:4px;background:#ffffff10;overflow:hidden}.studio-progress i{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,#d3b968,#b9ee74);transition:width .35s}
.studio-balance-badge{display:inline-block;margin-top:8px;padding:4px 6px;border:1px solid #b9ee7420;border-radius:5px;background:#b9ee740a;color:#c8dfa9;font-size:6.5px}
.studio-lower-grid{display:grid;grid-template-columns:minmax(0,1.28fr) minmax(300px,.82fr);gap:12px}
.studio-activity,.studio-invoices{padding:17px 18px;background:linear-gradient(145deg,#19231f,#141d1a 88%);border-radius:16px}
.studio-section-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:12px}
.studio-section-head h2{margin:5px 0 0;color:#e6eee6;font-size:13px;letter-spacing:-.3px}
.studio-activity .table-scroll{max-width:100%;overflow:auto}
.studio-activity .data-table{min-width:575px;border-collapse:collapse;color:#d7e0d8}
.studio-activity .data-table th{padding:8px 7px;border-bottom:1px solid #ffffff12;color:#7f9085;font-size:7px;letter-spacing:.6px;text-align:left}
.studio-activity .data-table td{padding:9px 7px;border-bottom:1px solid #ffffff0c;color:#b3c0b5;font-size:8px}
.studio-activity .data-table tr:last-child td{border-bottom:0}
.studio-activity .data-table .num{white-space:nowrap;font-variant-numeric:tabular-nums}
.studio-activity .branch-pill{background:#ffffff0b;color:#c0d3b4;font-size:7px}
.studio-activity .empty-state{padding:20px 8px;color:#acb8ac}
.studio-invoice-mark{display:grid;place-items:center;width:31px;height:31px;border-radius:9px;background:linear-gradient(145deg,#d8c27d,#aa9656);color:#202b22;font-size:9px;font-weight:850;letter-spacing:.4px}
.studio-invoice-list{display:grid;gap:1px}
.studio-invoice-row{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:11px 0;border-bottom:1px solid #ffffff0e}
.studio-invoice-row>span{display:grid;gap:4px;min-width:0}.studio-invoice-row>span:last-child{text-align:right}
.studio-invoice-row b{overflow:hidden;color:#dce7dc;font-size:8px;text-overflow:ellipsis;white-space:nowrap;font-variant-numeric:tabular-nums}
.studio-invoice-row small{color:#84948a;font-size:7px}.studio-invoice-row small.paid{color:#a8da80}
.studio-invoice-actions{display:flex;justify-content:space-between;gap:7px;margin-top:11px}
.studio-invoice-actions .button{min-height:32px;padding:7px 9px;font-size:8px}
.studio-invoice-actions .button-primary{background:linear-gradient(130deg,#c4ee8b,#a9df69);color:#1b2e20}
.studio-account-strip{display:grid;gap:5px;margin-top:13px;padding-top:10px;border-top:1px solid #ffffff10}
.studio-account-strip>span{display:flex;align-items:center;gap:6px;color:#94a397;font-size:7px}.studio-account-strip>span i{width:6px;height:6px;border-radius:50%;background:#b9ee74}.studio-account-strip>span i.cash{background:#e1be67}.studio-account-strip>span b{margin-left:auto;color:#c8d6c6;font-variant-numeric:tabular-nums}
.studio-invoices .empty-state{min-height:94px;display:grid;justify-items:start;align-content:center;gap:6px;color:#a7b3a8;font-size:8px}
.studio-legal-note{display:flex;align-items:center;gap:9px;margin-top:12px;padding:10px 12px;border:1px solid #ffffff10;border-radius:10px;background:#ffffff04;color:#90a096}
.studio-legal-note>span{color:#d8c36d;font-size:12px}.studio-legal-note p{flex:1;margin:0;font-size:7px;line-height:1.5}.studio-legal-note p b{color:#b6c6b4}.studio-legal-note button{flex:none;border:0;background:transparent;color:#b8d995;font-size:7px}

.studio-assistant-layout{display:grid;grid-template-columns:minmax(0,1.32fr) minmax(260px,.68fr);gap:14px}
.studio-assistant-card{padding:22px;background:linear-gradient(145deg,#1b2822,#141e1a);border-radius:18px}
.studio-assistant-card-head{align-items:flex-start;margin-bottom:20px}.studio-assistant-card-head .studio-quick-icon{width:45px;height:45px}
.studio-assistant-card-head h2{font-size:18px}.studio-assistant-card-head p{margin:5px 0 0;color:#93a398;font-size:9px;line-height:1.5}
.studio-assistant-label{margin-bottom:7px;color:#b3c1b4;font-size:9px}
.studio-prompt-large{min-height:130px}.studio-prompt-large textarea{font-size:11px;line-height:1.7}
.studio-examples{display:flex;align-items:center;flex-wrap:wrap;gap:6px;margin:13px 0 15px}.studio-examples>span{width:100%;margin-bottom:2px;color:#7f9184;font-size:7px;font-weight:800;letter-spacing:1px}
.studio-examples button{padding:6px 8px;border:1px solid #ffffff17;border-radius:7px;background:#ffffff06;color:#aebdaf;font-size:7px;transition:border-color .2s,color .2s,background .2s}.studio-examples button:hover{border-color:#b9ee7445;background:#b9ee740c;color:#dbefc5}
.studio-assistant-actions{display:flex;align-items:center;gap:8px}.studio-assistant-actions .studio-analyze{min-height:39px;padding:0 15px}
.studio-assistant-actions .button-outline{min-height:39px;padding:8px 12px;font-size:8px}
.studio-privacy-note{margin:15px 0 0;padding-top:11px;border-top:1px solid #ffffff10;color:#809087;font-size:7px;line-height:1.6}
.studio-assistant-guide{display:grid;align-content:start;gap:8px;padding:14px;background:linear-gradient(145deg,#1b2621,#131c19);border-radius:17px}
.studio-assistant-guide>article{display:flex;gap:11px;padding:12px 10px;border:1px solid #ffffff0b;border-radius:10px;background:#ffffff03}
.studio-assistant-guide>article>span{display:grid;place-items:center;flex:none;width:24px;height:24px;border:1px solid #b9ee7429;border-radius:8px;color:#c8e99b;font-size:8px;font-weight:800}
.studio-assistant-guide article b{color:#dce7d9;font-size:9px}.studio-assistant-guide article p{margin:4px 0 0;color:#8fa095;font-size:7px;line-height:1.5}
.studio-assistant-guide>.studio-assistant-rule{display:block;border-color:#dbc36825;background:#d9bc6010}.studio-assistant-guide>.studio-assistant-rule b{color:#e2d194}.studio-assistant-guide>.button{margin-top:2px;justify-self:start;font-size:8px}
.studio-sound-panel>small{display:block;margin-top:8px;color:var(--muted);font-size:8px}
.studio-sound-toggle{display:flex;align-items:center;gap:9px;color:var(--ink);font-size:10px;font-weight:650}
.studio-sound-toggle input{width:18px;height:18px;accent-color:#187967}
.studio-settings-mode{width:max-content}.studio-settings-mode button{color:#718078}.studio-settings-mode button.active{color:#205344;background:#ddefd8}

.milo-dock{position:fixed;z-index:55;right:26px;bottom:17px;width:132px;height:149px;padding:0;border:0;background:none;filter:drop-shadow(0 16px 18px #0003);cursor:pointer;transition:transform .25s}
.milo-dock:hover,.milo-dock:focus-visible{transform:translateY(-5px) rotate(-1deg)}.milo-art{position:relative;z-index:1;display:block;width:100%;height:100%}.milo-art svg{width:100%;height:100%;overflow:visible}.milo-glow{position:absolute;left:10px;bottom:4px;width:112px;height:37px;border-radius:50%;background:#b9ee7420;filter:blur(18px);animation:studioPulse 3.7s ease-in-out infinite}.milo-bubble{position:absolute;right:105px;bottom:52px;display:grid;gap:2px;padding:8px 11px;border:1px solid #d4e2c9;border-radius:11px 11px 3px 11px;background:#eff6e8;color:#27372c;box-shadow:0 15px 35px #0003;white-space:nowrap;opacity:0;transform:translateX(7px);transition:opacity .2s,transform .2s;pointer-events:none}.milo-bubble b{font-size:10px}.milo-bubble small{font-size:8px;color:#637269}.milo-dock:hover .milo-bubble,.milo-dock:focus-visible .milo-bubble,.milo-dock.listening .milo-bubble,.milo-dock.is-error .milo-bubble{opacity:1;transform:none}.milo-ping{position:absolute;right:13px;bottom:79px;width:9px;height:9px;border:2px solid #17231e;border-radius:50%;background:#b9ee74;box-shadow:0 0 13px #b9ee74}.milo-dock.happy .milo-art{animation:studioDance .65s ease-in-out 2}.milo-dock.point .milo-art,.milo-dock.is-error .milo-art{animation:studioPoint .7s ease}.milo-dock.listening .milo-art{transform:perspective(400px) rotateY(-5deg) translateY(-2px)}.milo-dock .mascot-burst{z-index:4;inset:14px 6px}
@keyframes studioOrbit{to{transform:rotate(360deg)}}@keyframes studioGlow{to{opacity:.5;transform:scale(.7)}}@keyframes studioPulse{50%{opacity:.6;transform:scale(1.1)}}@keyframes studioBar{to{transform:scaleY(.48);opacity:.5}}@keyframes studioRecord{to{box-shadow:0 0 0 5px #e88c6e1c}}@keyframes studioDance{25%{transform:translateY(-12px) rotate(7deg)}65%{transform:translateY(-5px) rotate(-7deg)}}@keyframes studioPoint{40%{transform:translateX(-7px) rotate(-4deg)}}

html[data-theme="dark"] .studio-sound-panel,html[data-theme="dark"] .studio-assistant-guide,html[data-theme="dark"] .studio-assistant-card{color:#e6eee8}
html[data-theme="dark"] .studio-settings-mode button{color:#9aa99e}html[data-theme="dark"] .studio-settings-mode button.active{color:#183c2f;background:#c4e993}
html[data-theme="light"] .studio-welcome-row h1{color:#21352b}html[data-theme="light"] .studio-welcome-row h1 em{color:#557f43}html[data-theme="light"] .studio-welcome-row>div:first-child>p{color:#65756a}html[data-theme="light"] .studio-date-label{color:#64766a}
html[data-theme="light"] .studio-mode-switch{border-color:#22372918;background:#ffffffbd}html[data-theme="light"] .studio-mode-switch>span{color:#718078}html[data-theme="light"] .studio-mode-switch button{color:#718078}html[data-theme="light"] .studio-mode-switch button.active{background:#e2efd9;color:#27523e}
html[data-theme="light"] .studio-quick-card,html[data-theme="light"] .studio-assistant-card,html[data-theme="light"] .studio-assistant-guide,html[data-theme="light"] .studio-stat,html[data-theme="light"] .studio-activity,html[data-theme="light"] .studio-invoices{background:linear-gradient(145deg,#fff,#f7faf6);border-color:#20392b18;box-shadow:0 15px 40px #20372a0c}
html[data-theme="light"] .studio-quick-head h2,html[data-theme="light"] .studio-assistant-card-head h2,html[data-theme="light"] .studio-section-head h2,html[data-theme="light"] .studio-stat>b,html[data-theme="light"] .studio-invoice-row b{color:#263b30}
html[data-theme="light"] .studio-quick-card>p,html[data-theme="light"] .studio-assistant-card-head p,html[data-theme="light"] .studio-stat>small,html[data-theme="light"] .studio-invoice-row small{color:#6c7a70}
html[data-theme="light"] .studio-eyebrow{color:#718274}html[data-theme="light"] .studio-prompt-label,html[data-theme="light"] .studio-assistant-label{color:#52665a}
html[data-theme="light"] .studio-prompt-box{background:#f5f8f3;border-color:#253d2b24}html[data-theme="light"] .studio-prompt-box textarea{color:#26392e}html[data-theme="light"] .studio-prompt-box textarea::placeholder{color:#849187}
html[data-theme="light"] .studio-open-assistant{color:#63796a}html[data-theme="light"] .studio-draft-card{background:#edf6e7;border-color:#9abf6b}.studio-activity .empty-state{color:#aebcaf}
html[data-theme="light"] .studio-activity .data-table th{color:#63786b;border-color:#243d2b18}html[data-theme="light"] .studio-activity .data-table td{color:#33483a;border-color:#243d2b12}html[data-theme="light"] .studio-activity .branch-pill{background:#eff5eb;color:#47644f}
html[data-theme="light"] .studio-assistant-guide>article{border-color:#223d2a14;background:#ffffff80}html[data-theme="light"] .studio-assistant-guide article b{color:#2a4435}html[data-theme="light"] .studio-assistant-guide article p{color:#6b7b70}html[data-theme="light"] .studio-assistant-guide>.studio-assistant-rule{background:#f7f1d9;border-color:#d8c879}html[data-theme="light"] .studio-assistant-guide>.studio-assistant-rule b{color:#675a2c}
html[data-theme="light"] .studio-spark i{opacity:.8}html[data-theme="light"] .studio-legal-note{background:#ffffffa6;border-color:#233a2a12;color:#65766a}html[data-theme="light"] .studio-legal-note p b{color:#416148}html[data-theme="light"] .studio-account-strip{border-color:#213c2a17}html[data-theme="light"] .studio-account-strip>span{color:#627368}html[data-theme="light"] .studio-account-strip>span b{color:#33483a}
body.mode-pme .studio-stat:last-child{border-color:#b9ee7442}

@media(max-width:1120px){.studio-hero-grid{grid-template-columns:minmax(0,1.15fr) minmax(290px,.85fr)}.studio-stat-grid{gap:8px}.studio-stat{padding:12px}.studio-lower-grid{grid-template-columns:minmax(0,1.1fr) minmax(270px,.9fr)}}
@media(max-width:850px){.cashflow-studio .sidebar{width:270px}.cashflow-studio .workspace{margin-left:0}.cashflow-studio .view-root{padding:25px 20px 92px}.cashflow-studio .topbar{height:61px;padding:0 18px}.studio-welcome-row{align-items:flex-start;flex-direction:column;gap:13px}.studio-mode-switch{align-self:flex-start}.studio-hero-grid{grid-template-columns:1fr 1fr}.studio-balance-card,.studio-quick-card{min-height:310px}.studio-balance-card{padding:18px}.studio-quick-card{padding:17px}.studio-stat-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.studio-lower-grid{grid-template-columns:minmax(0,1.1fr) minmax(255px,.9fr)}.studio-activity,.studio-invoices{padding:14px}.studio-assistant-layout{grid-template-columns:minmax(0,1.2fr) minmax(235px,.8fr)}.milo-dock{right:8px;bottom:75px;transform:scale(.82);transform-origin:bottom right}.milo-dock:hover,.milo-dock:focus-visible{transform:scale(.82) translateY(-4px)}}
@media(max-width:620px){.cashflow-studio .view-root{padding:21px 14px 94px}.studio-welcome-row{margin-bottom:15px}.studio-welcome-row h1{font-size:30px;letter-spacing:-1px}.studio-date-label{font-size:7px;letter-spacing:.9px;gap:6px}.studio-hero-grid{grid-template-columns:1fr;gap:9px}.studio-balance-card{min-height:285px;padding:17px}.studio-quick-card{min-height:0;padding:16px}.studio-balance-value{font-size:35px}.studio-chart-wrap{height:124px}.studio-stat-grid{gap:8px;margin:9px 0}.studio-stat{min-height:105px;padding:11px}.studio-stat-top{font-size:6.5px;letter-spacing:.4px}.studio-stat>b{font-size:15px}.studio-spark{right:11px;bottom:12px;transform:scale(.8);transform-origin:bottom right}.studio-lower-grid{grid-template-columns:1fr;gap:9px}.studio-activity,.studio-invoices{padding:14px}.studio-activity .data-table{min-width:520px}.studio-legal-note{align-items:flex-start}.studio-legal-note p{font-size:7px}.studio-legal-note button{font-size:7px}.studio-assistant-layout{grid-template-columns:1fr;gap:10px}.studio-assistant-card{padding:17px}.studio-assistant-card-head h2{font-size:16px}.studio-assistant-guide{grid-template-columns:1fr 1fr;padding:10px}.studio-assistant-guide>article{padding:9px 7px;gap:7px}.studio-assistant-guide>.studio-assistant-rule{grid-column:1/-1}.studio-assistant-guide>.button{grid-column:1/-1}.studio-prompt-large{min-height:120px}.studio-examples button{font-size:7px}.milo-dock{right:1px;bottom:70px;transform:scale(.72)}.milo-dock:hover,.milo-dock:focus-visible{transform:scale(.72) translateY(-4px)}.milo-bubble{right:96px;bottom:50px}}
@media(max-width:360px){.studio-welcome-row h1{font-size:27px}.studio-stat{padding:9px}.studio-stat>b{font-size:13px}.studio-invoice-actions{gap:4px}.studio-invoice-actions .button{padding:7px 6px;font-size:7px}}
@media(prefers-reduced-motion:reduce){.studio-balance-card:before,.studio-balance-card:after,.studio-balance-orb,.studio-spark i,.milo-glow,.milo-dock.happy .milo-art,.milo-dock.point .milo-art,.milo-dock.is-error .milo-art,.studio-mic.recording{animation:none!important}.studio-mode-switch button,.studio-progress i,.studio-milo,.milo-bubble{transition:none!important}}
@media print{.cashflow-studio .studio-welcome-row,.cashflow-studio .studio-hero-grid,.cashflow-studio .studio-stat-grid,.cashflow-studio .studio-lower-grid,.cashflow-studio .studio-legal-note,#miloDock{display:none!important}}

/* Mobile and iOS finishing pass */
@media(max-width:620px){
  .cashflow-studio .topbar{height:auto;min-height:calc(61px + env(safe-area-inset-top));padding-top:env(safe-area-inset-top);padding-left:max(14px,env(safe-area-inset-left));padding-right:max(14px,env(safe-area-inset-right))}
  .cashflow-studio .view-root{padding-left:max(14px,env(safe-area-inset-left));padding-right:max(14px,env(safe-area-inset-right));padding-bottom:calc(112px + env(safe-area-inset-bottom))}
  .cashflow-studio .mobile-tabs{min-height:calc(68px + env(safe-area-inset-bottom));padding-left:max(5px,env(safe-area-inset-left));padding-right:max(5px,env(safe-area-inset-right));padding-bottom:calc(6px + env(safe-area-inset-bottom))}
  .cashflow-studio .mobile-tabs button{min-height:52px;touch-action:manipulation}
  .cashflow-studio .studio-welcome-row>div>p{font-size:12px;line-height:1.55}
  .cashflow-studio .studio-date-label{font-size:8px;letter-spacing:.75px}
  .cashflow-studio .studio-eyebrow{font-size:9px;letter-spacing:.8px}
  .cashflow-studio .studio-balance-caption,.cashflow-studio .studio-balance-foot{font-size:10px;line-height:1.4}
  .cashflow-studio .studio-balance-foot button,.cashflow-studio .studio-section-head button{min-height:44px;padding:8px 5px;font-size:10px;touch-action:manipulation}
  .cashflow-studio .studio-stat-top{font-size:8px;letter-spacing:.45px}
  .cashflow-studio .studio-stat>small{font-size:10px;line-height:1.45}
  .cashflow-studio .studio-balance-badge{font-size:8px}
  .cashflow-studio .studio-quick-card>p{font-size:12px;line-height:1.55}
  .cashflow-studio .studio-prompt-label,.cashflow-studio .studio-assistant-label{font-size:11px}
  .cashflow-studio .studio-prompt-box textarea{min-height:72px;padding:12px 52px 12px 13px;font-size:16px!important;line-height:1.5;-webkit-appearance:none}
  .cashflow-studio .studio-prompt-large textarea{min-height:116px;font-size:16px!important;line-height:1.5}
  .cashflow-studio .studio-mic{width:44px;height:44px;right:5px;top:5px;touch-action:manipulation}
  .cashflow-studio .studio-prompt-actions>span{font-size:9px;line-height:1.4}
  .cashflow-studio .studio-analyze{min-height:44px;padding:0 13px;font-size:11px;touch-action:manipulation}
  .cashflow-studio .studio-open-assistant{min-height:44px;padding:8px 4px;font-size:10px;touch-action:manipulation}
  .cashflow-studio .studio-activity .table-scroll{overflow:visible}
  .cashflow-studio .studio-activity .data-table{width:100%;min-width:0!important}
  .cashflow-studio .studio-activity .data-table tbody td{font-size:11px}
  .cashflow-studio .studio-activity .data-table tbody td:before{font-size:9px}
  .cashflow-studio .studio-activity .branch-pill{font-size:9px}
  .cashflow-studio .studio-section-head .studio-eyebrow{font-size:8px}
  .cashflow-studio .studio-invoice-row b{font-size:11px}
  .cashflow-studio .studio-invoice-row small,.cashflow-studio .studio-account-strip>span{font-size:10px;line-height:1.4}
  .cashflow-studio .studio-invoice-actions{align-items:stretch}
  .cashflow-studio .studio-invoice-actions .button{min-height:44px;padding:8px 9px;font-size:10px;touch-action:manipulation}
  .cashflow-studio .studio-legal-note p{font-size:9px;line-height:1.5}
  .cashflow-studio .studio-legal-note button{min-height:44px;font-size:9px}
  .cashflow-studio .studio-assistant-card-head p{font-size:12px;line-height:1.5}
  .cashflow-studio .studio-examples>span{font-size:9px}
  .cashflow-studio .studio-examples button{min-height:40px;padding:8px 10px;font-size:10px;touch-action:manipulation}
  .cashflow-studio .studio-assistant-actions .studio-analyze,.cashflow-studio .studio-assistant-actions .button-outline{min-height:44px;font-size:10px}
  .cashflow-studio .studio-privacy-note{font-size:10px;line-height:1.55}
  .cashflow-studio .studio-assistant-guide article b{font-size:11px}
  .cashflow-studio .studio-assistant-guide article p{font-size:9px;line-height:1.5}
  .cashflow-studio .studio-assistant-guide>.button{min-height:44px;font-size:10px}
  .cashflow-studio .studio-sound-toggle{min-height:44px;font-size:12px}
  .cashflow-studio .studio-sound-panel>small{font-size:10px;line-height:1.5}
  .cashflow-studio .studio-eye{width:44px;height:44px;touch-action:manipulation}
  #miloDock{right:calc(5px + env(safe-area-inset-right));bottom:calc(70px + env(safe-area-inset-bottom))}
}
@supports (-webkit-touch-callout:none){
  html{-webkit-text-size-adjust:100%}
  .cashflow-studio .modal{max-height:calc(100vh - 18px);max-height:calc(100dvh - 18px);overscroll-behavior:contain;-webkit-overflow-scrolling:touch}
  .cashflow-studio .modal-actions{padding-bottom:max(8px,env(safe-area-inset-bottom))}
  .cashflow-studio input,.cashflow-studio select,.cashflow-studio textarea{scroll-margin-bottom:30vh}
}
