:root{
  --ink:#151827;--muted:#707584;--line:#e7e8ee;--soft:#f7f7fa;--purple:#6a5cff;--pink:#ff5d8d;--orange:#ff9a3c;--green:#1e9a64;--yellow:#fff6cc;--shadow:0 18px 50px rgba(31,31,58,.10);
  font-family:Inter,"Be Vietnam Pro",system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:var(--ink);background:#fff
}
*{box-sizing:border-box}html,body{margin:0;width:100%;height:100%;overflow:hidden;background:#fff}button,textarea,input{font:inherit}.app-shell{height:100dvh;display:flex;flex-direction:column;overflow:hidden}.topbar{height:64px;flex:0 0 64px;padding:0 14px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--line);background:rgba(255,255,255,.96);backdrop-filter:blur(16px);z-index:40}.topbar-left,.brand{display:flex;align-items:center}.topbar-left{gap:8px}.brand{gap:10px}.brand-mark{width:38px;height:38px;border-radius:14px;background:linear-gradient(135deg,var(--purple),var(--pink) 48%,var(--orange));display:grid;place-items:center;box-shadow:0 8px 20px rgba(106,92,255,.24);transform:rotate(-5deg)}.brand-mark span{color:#fff;font-size:20px;font-weight:900;transform:rotate(5deg)}.brand strong{display:block;font-size:16px;letter-spacing:.08em}.brand small{display:block;color:var(--muted);font-size:10px;margin-top:1px}.menu-button,.sidebar-close{border:0;background:transparent;color:#414552}.menu-button{width:42px;height:42px;border-radius:13px;display:grid;place-items:center}.menu-button svg{width:23px;height:23px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round}.menu-button:active{background:var(--soft)}.usage-pill{border:1px solid var(--line);background:#fff;border-radius:999px;height:38px;padding:0 13px;display:flex;align-items:center;gap:7px;font-weight:750;color:#4b4e5c}.usage-dot{width:8px;height:8px;border-radius:50%;background:var(--orange)}
.workspace{flex:1;min-height:0;display:grid;grid-template-columns:minmax(0,1fr);background:#fff}.left-sidebar{position:fixed;inset:64px auto 0 0;width:min(86vw,286px);z-index:55;background:#fff;border-right:1px solid var(--line);padding:16px 14px calc(14px + env(safe-area-inset-bottom));display:flex;flex-direction:column;gap:14px;transform:translateX(-105%);transition:transform .2s ease;box-shadow:18px 0 48px rgba(24,27,45,.14)}.left-sidebar.open{transform:translateX(0)}.mobile-overlay{position:fixed;inset:64px 0 0;background:rgba(20,22,34,.32);z-index:50}.mobile-overlay[hidden]{display:none}.sidebar-head{display:flex;align-items:center;justify-content:space-between;padding:0 4px}.sidebar-head strong{font-size:13px;color:#656a78}.sidebar-close{width:38px;height:38px;border-radius:50%;font-size:26px}.new-video-button{width:100%;height:50px;border:0;border-radius:16px;background:linear-gradient(105deg,var(--purple),var(--pink));color:#fff;font-weight:850;display:flex;align-items:center;justify-content:center;gap:8px;box-shadow:0 12px 28px rgba(106,92,255,.24)}.new-video-button span:first-child{font-size:22px;font-weight:400}.sidebar-nav{display:grid;gap:6px}.nav-item{width:100%;border:0;background:transparent;border-radius:15px;padding:11px 10px;display:grid;grid-template-columns:34px 1fr;gap:8px;text-align:left;color:#3d414f}.nav-item.active{background:#f0efff;color:#4436c9}.nav-item:active{transform:scale(.99)}.nav-icon{font-size:18px;display:grid;place-items:center}.nav-item strong,.nav-item small{display:block}.nav-item strong{font-size:13px}.nav-item small{font-size:10px;color:#818594;margin-top:3px;line-height:1.35}.sidebar-tip{margin-top:auto;border:1px solid #efe9ff;background:linear-gradient(145deg,#faf8ff,#fff8f2);border-radius:18px;padding:13px;display:flex;gap:10px}.tip-fire{font-size:20px}.sidebar-tip strong{display:block;font-size:12px}.sidebar-tip p{font-size:11px;color:#686d7a;line-height:1.45;margin:5px 0 0}.sidebar-account{border-top:1px solid var(--line);padding:13px 5px 0;display:grid;grid-template-columns:38px 1fr auto;gap:9px;align-items:center}.account-avatar{width:38px;height:38px;border-radius:13px;background:#f0efff;color:var(--purple);display:grid;place-items:center;font-weight:900}.sidebar-account strong,.sidebar-account small{display:block}.sidebar-account strong{font-size:12px}.sidebar-account small{font-size:10px;color:var(--muted);margin-top:2px}.account-more{color:#8a8d98}
.conversation-panel{min-width:0;min-height:0;display:flex;flex-direction:column;position:relative;background:#fff}.conversation{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;scrollbar-gutter:stable;max-width:820px;width:100%;margin:0 auto;padding:24px 15px 28px;scroll-behavior:smooth}.assistant-message,.user-message{display:flex;margin:0 0 24px}.assistant-message{gap:11px;align-items:flex-start}.assistant-avatar{flex:0 0 auto;width:32px;height:32px;border-radius:11px;display:grid;place-items:center;background:linear-gradient(135deg,var(--purple),var(--pink));color:#fff;font-weight:900;box-shadow:0 7px 18px rgba(106,92,255,.19)}.message-content{min-width:0;max-width:100%;font-size:15px;line-height:1.56}.assistant-message .message-content{padding-top:3px}.welcome-message h1{font-size:27px;line-height:1.17;margin:0 0 12px;letter-spacing:-.025em}.welcome-message p{font-size:15px;color:#515563;margin:0;max-width:680px}.quick-prompts{display:flex;flex-wrap:wrap;gap:8px;margin-top:17px}.quick-prompts button{min-height:42px;border:1px solid var(--line);border-radius:999px;background:#fff;padding:0 14px;color:#414552;font-size:13px;font-weight:750}.quick-prompts button:active{transform:scale(.98);background:var(--soft)}.user-message{justify-content:flex-end}.user-message .message-content{background:#f0efff;border:1px solid #dfdcff;border-radius:20px 20px 5px 20px;padding:12px 14px;max-width:min(88%,610px)}.user-message p{margin:0;white-space:pre-wrap}.message-attachments{display:flex;flex-wrap:wrap;gap:8px;margin-bottom:9px}.message-attachments:empty{display:none}.message-attachment{display:flex;align-items:center;gap:7px;padding:7px 9px;border-radius:11px;background:rgba(255,255,255,.78);font-size:12px;max-width:100%}.message-attachment span:last-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.assistant-message h2{font-size:19px;margin:0 0 8px}.assistant-message p{margin:0 0 11px}.assistant-message ul{margin:8px 0 14px;padding-left:20px}.assistant-message li{margin:5px 0}.draft-label{display:inline-flex;align-items:center;gap:6px;color:#765f00;background:#fff7d7;border:1px solid #f2dea0;border-radius:999px;padding:5px 9px;font-size:11px;font-weight:800;margin-bottom:9px}.script-card{border:1px solid var(--line);border-radius:18px;padding:15px;background:#fff;box-shadow:0 9px 28px rgba(35,35,58,.06);margin-top:12px}.script-card header{display:flex;justify-content:space-between;gap:10px;align-items:flex-start;margin-bottom:12px}.script-card header strong{font-size:15px}.script-card header span{font-size:11px;color:var(--muted);background:var(--soft);padding:5px 8px;border-radius:999px}.script-grid{display:grid;gap:8px}.script-row{display:grid;grid-template-columns:88px 1fr;gap:10px;padding:8px 0;border-top:1px solid #f0f0f5}.script-row:first-child{border-top:none}.script-row b{font-size:12px;color:var(--muted)}.script-row span{font-size:13px}.message-actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:13px}.secondary-button,.outline-button{min-height:44px;border-radius:13px;padding:0 14px;font-weight:750;font-size:14px}.secondary-button{border:1px solid var(--line);background:#fff;color:#343746}.outline-button{border:1px solid #cfcaff;background:#f8f7ff;color:#5546d9}.outline-button:disabled{opacity:.45}.primary-button{min-height:48px;border:0;border-radius:14px;padding:0 20px;color:#fff;font-weight:850;font-size:15px;background:linear-gradient(100deg,var(--purple),#8257f3 45%,var(--pink));box-shadow:0 11px 24px rgba(106,92,255,.23)}.primary-button:active{transform:translateY(1px)}.primary-button.full{width:100%}
.chat-bottom{flex:0 0 auto;position:relative;z-index:18;background:linear-gradient(to top,#fff 86%,rgba(255,255,255,.88));border-top:1px solid rgba(231,232,238,.7);padding:8px 10px calc(8px + env(safe-area-inset-bottom))}.mobile-summary-button{width:min(100%,820px);margin:0 auto 7px;border:1px solid #e5e2ff;background:#faf9ff;border-radius:14px;padding:8px 11px;display:flex;align-items:center;justify-content:space-between;text-align:left;color:#373a49}.mobile-summary-button b,.mobile-summary-button small{display:block}.mobile-summary-button b{font-size:12px}.mobile-summary-button small{font-size:10px;color:#777b89;margin-top:2px}.mobile-summary-arrow{font-size:18px;color:var(--purple)}.approval-dock{max-width:820px;margin:0 auto 7px;background:rgba(255,255,255,.98);border:1px solid #ddd9ff;border-radius:16px;padding:9px 9px 9px 13px;display:flex;align-items:center;justify-content:space-between;gap:10px;box-shadow:var(--shadow)}.approval-dock[hidden]{display:none}.approval-dock small{display:block;color:var(--green);font-size:10px;font-weight:800}.approval-dock strong{display:block;font-size:12px;margin-top:2px}.approval-dock .primary-button{min-width:122px}.composer{max-width:820px;margin:0 auto}.composer-row{display:flex;align-items:flex-end;gap:8px;padding:7px;background:#fff;border:1px solid #dfe0e7;border-radius:23px;box-shadow:0 10px 30px rgba(29,31,50,.10)}.icon-button,.send-button{width:44px;height:44px;border-radius:50%;flex:0 0 auto;display:grid;place-items:center}.add-button{border:0;background:var(--soft);font-size:27px;font-weight:300;color:#424654}.send-button{border:0;background:linear-gradient(135deg,var(--purple),var(--pink));color:#fff}.send-button svg{width:23px;height:23px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}.send-button:disabled{background:#dedfe5;color:#fff}.input-wrap{display:flex;align-items:center;min-height:44px;flex:1}.input-wrap textarea{width:100%;resize:none;border:0;outline:0;background:transparent;font:inherit;font-size:16px;line-height:1.4;max-height:120px;padding:10px 3px 8px;color:var(--ink)}.input-wrap textarea::placeholder{color:#9a9daa}.composer-note{margin:5px 6px 0;text-align:center;font-size:9px;color:#8b8e99}.attachment-strip{display:flex;gap:8px;overflow-x:auto;padding:2px 2px 7px;scrollbar-width:none}.attachment-strip[hidden]{display:none}.attachment-strip::-webkit-scrollbar{display:none}.attachment-chip{display:flex;align-items:center;gap:7px;min-width:0;max-width:255px;background:#fff;border:1px solid var(--line);border-radius:13px;padding:7px 8px;box-shadow:0 7px 20px rgba(30,30,50,.06)}.attachment-thumb{width:34px;height:34px;border-radius:8px;object-fit:cover;background:var(--soft);display:grid;place-items:center;font-size:15px}.attachment-meta{min-width:0}.attachment-meta strong{display:block;font-size:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.attachment-role{border:0;background:transparent;color:var(--purple);padding:0;font-size:10px;font-weight:800;text-align:left}.attachment-chip>.remove-attachment{border:0;background:transparent;width:28px;height:28px;border-radius:50%;font-size:17px;color:#7d808c}
.summary-panel{display:none}.summary-card{background:#fff;border:1px solid var(--line);border-radius:22px;padding:17px;box-shadow:0 14px 38px rgba(30,32,54,.06)}.summary-header{display:flex;align-items:flex-start;justify-content:space-between;gap:8px;margin-bottom:12px}.summary-header h2{font-size:18px;margin:0}.summary-header p{font-size:10px;color:var(--muted);margin:3px 0 0}.live-badge{font-size:9px;color:#6d5f00;background:var(--yellow);border-radius:999px;padding:5px 8px;white-space:nowrap}.progress-pill{border-radius:12px;background:#f0efff;color:#5144cf;font-size:11px;font-weight:850;padding:9px 11px;margin-bottom:11px}.summary-checklist{display:grid}.summary-check{display:grid;grid-template-columns:18px 1fr;gap:8px;align-items:center;padding:9px 0;border-top:1px solid #f0f0f5}.summary-check:first-child{border-top:0}.check-dot{width:10px;height:10px;border:2px solid #c5c8d1;border-radius:50%;margin-left:2px}.summary-check.complete .check-dot{border-color:var(--green);background:var(--green);box-shadow:inset 0 0 0 2px #fff}.summary-check.optional .check-dot{border-color:#b8b0ff;background:#eeeaff}.summary-check small,.summary-check strong{display:block}.summary-check small{font-size:10px;color:var(--muted)}.summary-check strong{font-size:12px;margin-top:2px}.creative-plan{border-top:1px solid var(--line);margin-top:5px;padding-top:12px}.creative-plan h3{font-size:12px;margin:0 0 7px}.creative-plan dl{margin:0}.creative-plan dl>div{display:grid;grid-template-columns:104px 1fr;gap:8px;padding:7px 0}.creative-plan dt{font-size:10px;color:var(--muted)}.creative-plan dd{margin:0;font-size:11px;font-weight:750;text-align:right}.next-action-card{border-radius:14px;background:linear-gradient(135deg,#f7f5ff,#fff6ef);padding:11px 12px;margin-top:12px}.next-action-card span,.next-action-card strong{display:block}.next-action-card span{font-size:9px;color:#7a6fc2;font-weight:850;text-transform:uppercase;letter-spacing:.05em}.next-action-card strong{font-size:11px;line-height:1.45;margin-top:4px}.safety-note{border-radius:14px;background:#f0faf5;padding:10px 12px;margin-top:9px}.safety-note strong,.safety-note span{display:block}.safety-note strong{font-size:11px;color:var(--green)}.safety-note span{font-size:10px;color:#527061;margin-top:3px;line-height:1.4}
.sheet-backdrop{position:fixed;inset:0;background:rgba(18,20,31,.34);z-index:80;display:flex;align-items:flex-end;justify-content:center;padding:12px}.sheet-backdrop[hidden]{display:none}.bottom-sheet{width:min(100%,520px);max-height:calc(100dvh - 24px);overflow:auto;background:#fff;border-radius:24px 24px 20px 20px;padding:8px 16px calc(18px + env(safe-area-inset-bottom));box-shadow:0 24px 80px rgba(0,0,0,.24);animation:sheetIn .18s ease-out}.sheet-handle{width:42px;height:5px;border-radius:999px;background:#d7d8dd;margin:2px auto 11px}.sheet-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:10px}.sheet-head h2{font-size:19px;margin:0}.sheet-head p{font-size:11px;color:var(--muted);margin:3px 0 0}.sheet-head button{width:40px;height:40px;border-radius:50%;border:0;background:var(--soft);font-size:24px;color:#555866}.source-option{width:100%;min-height:72px;border:1px solid var(--line);background:#fff;border-radius:17px;padding:10px 12px;display:flex;align-items:center;gap:12px;text-align:left;margin-top:9px}.source-option>span{width:44px;height:44px;border-radius:14px;background:#f0efff;color:var(--purple);display:grid;place-items:center;font-size:20px}.source-option strong,.source-option small{display:block}.source-option strong{font-size:15px}.source-option small{font-size:12px;color:var(--muted);margin-top:2px}.field-label{display:block;font-size:13px;font-weight:750;margin:14px 0 7px}.link-input{width:100%;height:52px;border:1px solid #d8d9e0;border-radius:14px;padding:0 13px;font-size:16px;outline:0}.link-input:focus{border-color:var(--purple);box-shadow:0 0 0 3px rgba(106,92,255,.10)}.field-help{font-size:12px;color:var(--muted);line-height:1.45;margin:8px 2px 16px}.notice-sheet{text-align:center}.notice-icon{width:58px;height:58px;border-radius:50%;background:#e9f8f0;color:var(--green);display:grid;place-items:center;font-size:29px;font-weight:900;margin:6px auto 12px}.notice-sheet h2{font-size:21px;margin:0 0 8px}.notice-sheet p{color:var(--muted);line-height:1.55;margin:0 0 18px}.summary-checklist.compact{grid-template-columns:1fr 1fr;gap:0 14px}.compact-plan{margin-top:8px}.mobile-summary-sheet .next-action-card{margin-bottom:4px}@keyframes sheetIn{from{transform:translateY(18px);opacity:.5}to{transform:none;opacity:1}}
@media (min-width:1080px){
  body{background:#f7f7fa}.menu-button,.sidebar-close{display:none}.workspace{grid-template-columns:246px minmax(0,1fr) 304px;gap:16px;padding:16px;max-width:1520px;width:100%;margin:0 auto;background:#f7f7fa}.left-sidebar{position:relative;inset:auto;width:auto;transform:none;z-index:1;border:1px solid var(--line);border-radius:22px;padding:15px 13px;box-shadow:0 12px 40px rgba(25,28,49,.04)}.conversation-panel{border:1px solid var(--line);border-radius:22px;overflow:hidden;box-shadow:0 12px 40px rgba(25,28,49,.04)}.conversation{padding:34px 32px 28px}.summary-panel{display:block;min-height:0;overflow:auto}.summary-card{position:sticky;top:0}.mobile-summary-button{display:none}.chat-bottom{padding:10px 18px 12px}.welcome-message h1{font-size:32px}.sheet-backdrop{align-items:center}.bottom-sheet{border-radius:24px}.sheet-handle{display:none}
}
@media (max-width:420px){.brand small{display:none}.usage-pill{padding:0 10px}.welcome-message h1{font-size:24px}.welcome-message p{font-size:14px}.quick-prompts button{font-size:12px;padding:0 11px}.composer-note{display:none}.approval-dock strong{max-width:170px}.summary-checklist.compact{grid-template-columns:1fr}}

/* R2 S5 guest AI binding: visible persistence state, login and rights notice. */
.sidebar-account{cursor:pointer}.sidebar-account[hidden]{display:none}.sidebar-account:focus-visible,.usage-pill:focus-visible{outline:3px solid rgba(106,92,255,.22);outline-offset:3px}
.login-sheet{padding-bottom:calc(24px + env(safe-area-inset-bottom))}.login-copy{font-size:14px;line-height:1.55;color:#555a69;margin:4px 0 18px}.google-login-button{min-height:48px;display:grid;place-items:center;color:var(--muted);overflow:hidden}.login-sheet .field-help{text-align:center;margin-bottom:0}
.rights-note{font-size:11px;line-height:1.45;color:#666c7a;background:#f7f7fa;border-radius:13px;padding:10px 12px;margin:12px 0 2px}
.runtime-save-badge{display:flex;width:max-content;max-width:100%;align-items:center;gap:5px;color:#12744d;background:#e9f8f0;border:1px solid #ccebdc;border-radius:999px;padding:5px 9px;font-size:11px;font-weight:850;margin-bottom:8px}.runtime-save-badge.pending{color:#635000;background:#fff7d7;border-color:#f2dea0}.runtime-save-badge.error{color:#a23a2e;background:#fff0ee;border-color:#ffd2cc}.runtime-pending .assistant-avatar{animation:senselPulse 1.15s ease-in-out infinite}.runtime-pending p{color:var(--muted)}
@keyframes senselPulse{50%{transform:scale(.92);opacity:.72}}

/* R2 S5: real advisory, free-image result and three-dot thinking wave. */
.real-advisor-copy{font-size:15px;line-height:1.7;color:#25243a;white-space:normal}
.free-image-note{display:block;margin-top:8px;color:#77738a;font-size:12px}
.thinking-wave{display:inline-flex;align-items:center;gap:5px;height:24px;padding:0 4px}
.thinking-wave i{display:block;width:7px;height:7px;border-radius:50%;background:linear-gradient(135deg,#7657f5,#ef3c8c);animation:senselWave 1.05s ease-in-out infinite}
.thinking-wave i:nth-child(2){animation-delay:.14s}.thinking-wave i:nth-child(3){animation-delay:.28s}
@keyframes senselWave{0%,60%,100%{transform:translateY(0);opacity:.45}30%{transform:translateY(-6px);opacity:1}}
.generated-image{margin:10px 0 0;max-width:440px}
.generated-image img{display:block;width:100%;max-height:560px;object-fit:contain;border-radius:16px;background:#f1f0f7;border:1px solid #e4e1ee}
.generated-image figcaption{padding-top:7px;color:#77738a;font-size:12px;line-height:1.4}
.image-download{display:inline-flex;align-items:center;justify-content:center;text-decoration:none}
.logout-button{margin-bottom:10px}
@media(max-width:699px){.ai-actions{display:grid;grid-template-columns:1fr 1fr}.ai-actions .edit-script{grid-column:1/-1}.generated-image{max-width:100%}}

/* R2 S5 F5 owner-approved logo placement and logo-free chat. */
.brand-owner-logo{position:relative;display:block;width:180px;height:54px;overflow:hidden;flex:0 0 180px;background:#fff}
.brand-owner-logo img{position:absolute;display:block;width:214px;height:214px;max-width:none;left:-18px;top:-78px;object-fit:contain}
.assistant-avatar{display:none!important;background:none!important}
.assistant-message{gap:0}
.assistant-message:not(.welcome-message) .message-content{background:#faf9ff;border-left:3px solid #7565f5;border-radius:0 14px 14px 0;padding:11px 13px;max-width:min(92%,680px)}
.account-avatar{background:#f0efff!important;color:#5849d8!important;font-size:14px!important;overflow:visible!important}
@media(max-width:380px){.brand-owner-logo{width:138px;height:42px;flex-basis:138px}.brand-owner-logo img{width:164px;height:164px;left:-13px;top:-59px}.usage-pill{font-size:12px}}


/* F13-S1: migrated project workspace, functional drafts and video-ready filters. */
.recent-projects{min-height:0;display:flex;flex-direction:column;gap:5px}
.recent-projects-head{display:flex;align-items:center;justify-content:space-between;padding:2px 8px 4px}
.recent-projects-head h3{margin:0;font-size:12px;line-height:1.3;color:#313440}
.recent-projects-head span{font-size:10px;color:var(--muted)}
.recent-projects-list{display:grid;gap:2px;max-height:min(32dvh,260px);overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;padding-right:2px}
.recent-project-item{width:100%;border:0;background:transparent;border-radius:10px;padding:8px 9px;text-align:left;color:#30333f;display:block;cursor:pointer}
.recent-project-item:hover,.recent-project-item:focus-visible{background:#f1f1f3;outline:0}
.recent-project-item.current{background:#ececef}
.recent-project-item strong,.recent-project-item small{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.recent-project-item strong{font-size:12px;font-weight:600}
.recent-project-item small{font-size:9px;color:var(--muted);margin-top:3px}
.recent-projects-empty{margin:0;padding:7px 9px;color:#858894;font-size:10px;line-height:1.45}
.recent-projects-empty[hidden]{display:none}
@media(min-width:1080px){.left-sidebar{gap:11px}.sidebar-tip{margin-top:auto}.recent-projects-list{max-height:min(29dvh,250px)}}
@media(max-width:1079px){.recent-projects-list{max-height:34dvh}.recent-project-item{padding:10px 9px}.recent-project-item strong{font-size:13px}}

/* F13-S1: Project Workspace foundation. */
.new-video-icon,.nav-icon,.tip-fire{display:grid;place-items:center;flex:0 0 auto}
.new-video-icon svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.9;stroke-linecap:round}
.nav-icon svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.tip-fire svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.project-context-bar{flex:0 0 auto;min-height:54px;display:flex;align-items:center;justify-content:space-between;gap:14px;padding:9px 18px;border-bottom:1px solid #ededf1;background:rgba(255,255,255,.96);z-index:4}
.project-context-copy{min-width:0;display:grid;gap:2px}.project-context-copy small{font-size:10px;color:var(--muted)}.project-context-copy strong{font-size:13px;font-weight:650;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.project-save-status{flex:0 0 auto;font-size:10px;color:#5d6472;background:#f2f3f5;border-radius:999px;padding:5px 9px}
.recent-project-row{position:relative;display:grid;grid-template-columns:minmax(0,1fr) 28px;align-items:center;border-radius:10px}
.recent-project-row:hover,.recent-project-row:focus-within{background:#f1f1f3}.recent-project-row.current{background:#ececef}
.recent-project-row .recent-project-item{min-width:0;border-radius:10px;background:transparent;padding-right:3px}.recent-project-row .recent-project-item:hover,.recent-project-row .recent-project-item:focus-visible{background:transparent}
.recent-project-menu{width:28px;height:28px;border:0;background:transparent;border-radius:8px;color:#777b87;font-size:14px;letter-spacing:1px;display:grid;place-items:center;opacity:0}
.recent-project-row:hover .recent-project-menu,.recent-project-row:focus-within .recent-project-menu,.recent-project-row.current .recent-project-menu{opacity:1}
.recent-project-menu:hover,.recent-project-menu:focus-visible{background:#e3e3e8;outline:0}
.sidebar-nav{border-bottom:1px solid #efeff2;padding-bottom:7px}.recent-projects{flex:0 1 auto}.sidebar-tip{margin-top:auto}
@media(max-width:1079px){.project-context-bar{min-height:50px;padding:8px 14px}.project-context-copy small{display:none}.project-context-copy strong{font-size:12px}.project-save-status{font-size:9px}.recent-project-menu{opacity:1}}

/* F13 S2 context-bound image progress */
.image-progress-card{display:flex;align-items:center;gap:12px;max-width:520px;padding:14px 15px;border-radius:16px;background:#f7f7fa;color:#20212a}
.image-progress-card .thinking-wave{flex:0 0 auto}
.image-progress-card strong,.image-progress-card small{display:block}
.image-progress-card strong{font-size:14px;line-height:1.35}
.image-progress-card small{margin-top:4px;color:#737683;font-size:12px;line-height:1.45}
.image-recheck{margin-top:10px}
.generated-image figcaption{max-width:560px}
@media(max-width:699px){.image-progress-card{max-width:100%;padding:12px}.generated-image img{max-height:68vh}}


/* F13 S2 U1 — inline source-image preview for clear before/after review. */
.message-source-gallery{display:flex;flex-wrap:wrap;gap:9px;margin:0 0 10px;align-items:flex-start}
.uploaded-source-figure{position:relative;width:clamp(112px,34vw,148px);margin:0;background:rgba(255,255,255,.82);border-radius:14px;padding:6px;overflow:hidden}
.uploaded-source-label{position:absolute;z-index:2;top:10px;left:10px;max-width:calc(100% - 20px);padding:4px 7px;border-radius:999px;background:rgba(20,22,34,.72);color:#fff;font-size:9px;font-weight:800;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;backdrop-filter:blur(6px)}
.uploaded-source-image{display:block;width:100%;aspect-ratio:3/4;object-fit:cover;border-radius:10px;background:#f1f0f7}
.uploaded-source-pending,.uploaded-source-unavailable{display:grid;place-items:center;color:#77738a;font-size:10px;text-align:center;padding:12px}
.uploaded-source-figure figcaption{padding:6px 2px 1px;color:#6f7380;font-size:10px;line-height:1.25;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
@media(min-width:1080px){.uploaded-source-figure{width:148px}}
@media(max-width:699px){.uploaded-source-figure{width:clamp(108px,36vw,142px)}.user-message .message-content{max-width:min(94%,610px)}}


/* F13 S3 — truthful project control panel and mobile workspace. */
.project-control-card{position:sticky;top:0;background:#fff;border:0;border-radius:20px;padding:18px;box-shadow:0 12px 34px rgba(25,28,49,.055)}
.project-control-header{display:flex;align-items:flex-start;justify-content:space-between;gap:10px;margin-bottom:14px}.control-eyebrow{display:block;color:#777b89;font-size:9px;font-weight:800;letter-spacing:.08em;text-transform:uppercase;margin-bottom:3px}.project-control-header h2{font-size:18px;line-height:1.2;margin:0}.project-control-header .live-badge{max-width:128px;overflow:hidden;text-overflow:ellipsis}
.control-status{display:grid;grid-template-columns:38px minmax(0,1fr);gap:11px;align-items:start;border-radius:16px;background:#f7f7fa;padding:13px;margin-bottom:4px}.control-status-icon{width:38px;height:38px;border-radius:12px;display:grid;place-items:center;background:#ececef;color:#656978}.control-status-icon svg,.control-line-icon svg,.mobile-summary-arrow svg,.sheet-head button svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}.control-status small,.control-status strong{display:block}.control-status small{font-size:9px;color:#787c89}.control-status strong{font-size:13px;line-height:1.35;margin-top:2px}.control-status p{font-size:10px;line-height:1.45;color:#656a78;margin:4px 0 0}.control-status[data-control-status-kind="processing"]{background:#f4f2ff}.control-status[data-control-status-kind="processing"] .control-status-icon{background:#e8e4ff;color:#5b4bdd;animation:senselPulse 1.15s ease-in-out infinite}.control-status[data-control-status-kind="waiting"]{background:#fff8e6}.control-status[data-control-status-kind="waiting"] .control-status-icon{background:#fff0bf;color:#7a6200}.control-status[data-control-status-kind="complete"],.control-status[data-control-status-kind="ready"]{background:#eef9f3}.control-status[data-control-status-kind="complete"] .control-status-icon,.control-status[data-control-status-kind="ready"] .control-status-icon{background:#dff3e9;color:#14764d}.control-status[data-control-status-kind="active"]{background:#f7f6ff}.control-status[data-control-status-kind="active"] .control-status-icon{background:#ebe8ff;color:#5c4edf}
.control-section{padding:14px 0;border-top:1px solid #efeff2}.control-section:first-of-type{border-top:0}.control-section h3{font-size:11px;line-height:1.3;margin:0 0 10px;color:#333641}.control-section-head{display:flex;align-items:center;justify-content:space-between}.control-section-head span{min-width:22px;height:22px;border-radius:999px;background:#f0efff;color:#5144cf;display:grid;place-items:center;font-size:10px;font-weight:800}.control-material-list{display:grid;gap:4px}.control-material{display:grid;grid-template-columns:30px minmax(0,1fr);gap:9px;align-items:center;padding:7px 0;color:#737784}.control-line-icon{width:30px;height:30px;border-radius:10px;background:#f5f5f7;display:grid;place-items:center}.control-line-icon svg{width:17px;height:17px}.control-material small,.control-material strong{display:block}.control-material small{font-size:9px;color:#858995}.control-material strong{font-size:11px;font-weight:650;line-height:1.35;margin-top:2px}.control-material.complete{color:#16764e}.control-material.complete .control-line-icon{background:#e9f8f0}.control-material.optional:not(.complete){color:#888c98}
.control-objective-section p{margin:0;font-size:11px;line-height:1.55;color:#4e5260;display:-webkit-box;-webkit-line-clamp:4;-webkit-box-orient:vertical;overflow:hidden}.control-actions{display:grid;gap:8px}.control-actions button{width:100%;min-height:42px;font-size:12px;border-radius:12px}.control-action-secondary{background:#f7f7fa;border-color:transparent}.control-truth{display:flex;gap:7px;margin:0;padding:11px 12px;border-radius:14px;background:#f0faf5;color:#4d6f5f;font-size:9px;line-height:1.45}.control-truth>span:first-child{color:#168052;font-weight:900}
.project-control-trigger{display:grid;grid-template-columns:10px minmax(0,1fr) 24px;gap:9px;align-items:center}.mobile-control-dot{width:9px;height:9px;border-radius:50%;background:#b9bdc7}.mobile-control-dot[data-control-status-kind="processing"]{background:#6a5cff;box-shadow:0 0 0 5px rgba(106,92,255,.12)}.mobile-control-dot[data-control-status-kind="waiting"]{background:#d5a800}.mobile-control-dot[data-control-status-kind="active"]{background:#6a5cff}.mobile-control-dot[data-control-status-kind="complete"],.mobile-control-dot[data-control-status-kind="ready"]{background:#1e9a64}.mobile-control-copy{min-width:0}.mobile-control-copy small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.mobile-summary-arrow{display:grid;place-items:center;color:#5f6270}.mobile-summary-arrow svg{width:18px;height:18px}.mobile-project-control-sheet{padding-left:18px;padding-right:18px}.mobile-project-control-sheet .sheet-head{margin-bottom:12px}.mobile-project-control-sheet .sheet-head button{display:grid;place-items:center;font-size:0}.mobile-project-control-sheet .control-status{margin-bottom:4px}.mobile-project-control-sheet .control-actions{grid-template-columns:1fr 1fr}.mobile-project-control-sheet .control-actions button{min-width:0}.mobile-project-control-sheet .control-truth{margin-top:4px}
@media(min-width:1080px){.workspace{grid-template-columns:246px minmax(0,1fr) 292px;gap:14px}.summary-panel{overflow:visible}.project-control-card{box-shadow:0 12px 40px rgba(25,28,49,.045)}.conversation{max-width:860px}.summary-card{display:none}}
@media(max-width:1079px){.mobile-summary-button{border:0;background:#f7f7fa;border-radius:16px;padding:9px 12px}.project-context-bar{border-bottom-color:#f0f0f3}.conversation-panel{background:#fff}.mobile-project-control-sheet{max-height:min(88dvh,760px)}}
@media(max-width:699px){.mobile-project-control-sheet .control-actions{grid-template-columns:1fr}.chat-bottom{padding-left:8px;padding-right:8px}.conversation{padding-left:12px;padding-right:12px}.mobile-summary-button{margin-bottom:6px}.control-objective-section p{-webkit-line-clamp:5}}


/* F13 S4 — SENSEL Visual System v1: one typography, one icon language, fewer borders. */
:root{
  --ink:#171923;
  --muted:#6f7380;
  --subtle:#9296a2;
  --canvas:#f7f8fa;
  --surface:#ffffff;
  --surface-soft:#f3f4f7;
  --surface-accent:#f0efff;
  --line:rgba(31,35,48,.09);
  --line-strong:rgba(31,35,48,.14);
  --purple:#6757f6;
  --pink:#f6538e;
  --orange:#ff9a3c;
  --green:#16845a;
  --yellow:#fff6cc;
  --shadow:0 14px 38px rgba(29,33,50,.07);
  --shadow-float:0 22px 64px rgba(22,26,42,.14);
  --radius-sm:10px;
  --radius-md:14px;
  --radius-lg:20px;
  --focus:0 0 0 3px rgba(103,87,246,.20);
  font-family:Inter,"Be Vietnam Pro",ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
}
html,body{background:var(--canvas);color:var(--ink);font-synthesis:none;text-rendering:optimizeLegibility}
button,a,input,textarea{transition:background-color .16s ease,color .16s ease,box-shadow .16s ease,transform .16s ease,opacity .16s ease}
button{cursor:pointer}
button:disabled{cursor:not-allowed}
button:focus-visible,a:focus-visible,input:focus-visible,textarea:focus-visible,[role="button"]:focus-visible{outline:0;box-shadow:var(--focus)}
svg{fill:none;stroke:currentColor;stroke-width:1.75;stroke-linecap:round;stroke-linejoin:round}
.outline-icon,.icon-only-button,.source-option-icon,.inline-status-icon{display:grid;place-items:center}
.outline-icon svg,.icon-only-button svg,.source-option-icon svg,.inline-status-icon svg,.recent-project-menu svg,.attachment-thumb-icon svg,.remove-attachment svg{width:18px;height:18px}
.icon-only-button{width:40px;height:40px;padding:0;border:0;border-radius:12px;background:transparent;color:#5f6471}
.icon-only-button:hover{background:var(--surface-soft);color:var(--ink)}

.topbar{height:60px;flex-basis:60px;border-bottom:0;box-shadow:0 1px 0 var(--line);background:rgba(255,255,255,.94)}
.usage-pill{height:36px;border:0;background:var(--surface-soft);padding:0 12px;font-size:13px;font-weight:650;color:#454956}
.usage-pill:hover{background:#eceef2}
.usage-dot{width:7px;height:7px}
.brand-owner-logo{filter:saturate(.96)}

.new-video-button,.primary-button,.send-button{background:linear-gradient(105deg,var(--purple),#8158f2 52%,var(--pink));border:0;color:#fff;box-shadow:0 8px 20px rgba(103,87,246,.18)}
.new-video-button{height:48px;border-radius:14px;font-weight:750}
.new-video-button:hover,.primary-button:hover,.send-button:not(:disabled):hover{filter:saturate(1.06);box-shadow:0 10px 24px rgba(103,87,246,.24);transform:translateY(-1px)}
.primary-button{min-height:44px;border-radius:12px;font-size:13px;font-weight:750;padding:0 16px}
.secondary-button,.outline-button{min-height:42px;border:0;border-radius:12px;background:var(--surface-soft);color:#353946;font-size:13px;font-weight:650;padding:0 14px;text-decoration:none;display:inline-flex;align-items:center;justify-content:center}
.outline-button{background:var(--surface-accent);color:#4f43c8}
.secondary-button:hover,.outline-button:hover{background:#ebecef}
.outline-button:hover{background:#e9e6ff}
.secondary-button:disabled,.outline-button:disabled{opacity:.48}

.sidebar-head{padding:0 6px}.sidebar-head strong{font-size:12px;font-weight:650;color:#555a68}
.nav-item{border:0;border-radius:12px;padding:10px 9px;grid-template-columns:31px 1fr;gap:7px}
.nav-item.active{background:#ebecef;color:#262936}
.nav-item:hover{background:#f0f1f4}
.nav-item strong{font-size:13px;font-weight:650}.nav-item small{font-size:10px;color:#848895}
.nav-icon svg,.new-video-icon svg,.tip-fire svg{stroke-width:1.75}
.sidebar-nav{border-bottom:0;padding-bottom:3px}
.recent-projects-head{padding-left:7px;padding-right:7px}.recent-projects-head h3{font-size:11px;text-transform:uppercase;letter-spacing:.04em;color:#696e7b}
.recent-project-row,.recent-project-item{border-radius:10px}
.recent-project-row:hover,.recent-project-row:focus-within{background:#eef0f3}.recent-project-row.current{background:#e9eaee}
.recent-project-item{padding:8px 8px}.recent-project-item strong{font-size:12px;font-weight:600}.recent-project-item small{font-size:9px}
.recent-project-menu{opacity:1;color:#777c88;letter-spacing:0;font-size:0}
.recent-project-menu:hover,.recent-project-menu:focus-visible{background:#dedfe4}
.sidebar-tip{border:0;border-radius:14px;background:var(--surface-soft);padding:12px;box-shadow:none}
.sidebar-tip strong{font-size:12px;font-weight:650}.sidebar-tip p{font-size:10px}
.sidebar-account{border-top:0;background:transparent;padding-top:8px}.account-more svg{width:19px;height:19px}

.project-context-bar{min-height:50px;border-bottom:0;box-shadow:0 1px 0 var(--line);padding:8px 16px;background:rgba(255,255,255,.95)}
.project-context-copy small{font-size:9px}.project-context-copy strong{font-size:13px;font-weight:650}
.project-save-status{font-size:9px;background:var(--surface-soft);padding:5px 9px;color:#696e7a}
.conversation{max-width:880px;padding-top:30px}
.message-content{font-size:14px;line-height:1.58}
.welcome-message h1{font-size:31px;font-weight:720;letter-spacing:-.035em}.welcome-message p{font-size:14px;line-height:1.6;color:#555966}
.quick-prompts button{min-height:40px;border:0;background:var(--surface-soft);border-radius:12px;padding:0 13px;font-size:12px;font-weight:650;color:#373b48}
.quick-prompts button:hover{background:#e9ebef}
.user-message .message-content{border:0;background:#f0efff;border-radius:18px 18px 5px 18px;padding:12px 14px;box-shadow:none}
.message-attachment{background:rgba(255,255,255,.72);border-radius:10px}
.runtime-save-badge,.draft-label{border:0;background:#eaf7f0;color:#16714e;display:inline-flex;align-items:center;gap:6px;font-size:10px;font-weight:700;border-radius:999px;padding:5px 9px}
.inline-status-icon svg{width:14px;height:14px;stroke-width:2}
.script-card{border:0;background:var(--surface-soft);border-radius:16px;box-shadow:none;padding:15px}
.script-row{border-top-color:var(--line)}
.message-actions{gap:7px}
.image-progress-card{background:var(--surface-soft);border-radius:14px}
.generated-image{border:0;background:transparent;border-radius:16px;padding:0;overflow:hidden}
.generated-image img{border-radius:16px;background:var(--surface-soft)}
.generated-image figcaption{padding:8px 2px 0;color:#737785}
.uploaded-source-figure{background:rgba(255,255,255,.78);border-radius:13px;padding:5px;box-shadow:0 5px 16px rgba(25,28,45,.06)}
.uploaded-source-image{border-radius:9px}.uploaded-source-label{background:rgba(23,25,35,.72);font-weight:650}

.chat-bottom{border-top:0;box-shadow:0 -1px 0 var(--line);background:rgba(255,255,255,.96);backdrop-filter:blur(16px)}
.composer-row{border:0;border-radius:22px;background:#fff;box-shadow:0 8px 28px rgba(28,32,49,.11),0 0 0 1px rgba(31,35,48,.06)}
.composer-row:focus-within{box-shadow:0 10px 32px rgba(28,32,49,.13),var(--focus)}
.add-button{background:transparent;color:#5c6170;font-size:0}
.add-button::before{content:"";width:18px;height:18px;background:linear-gradient(currentColor,currentColor) center/18px 1.7px no-repeat,linear-gradient(currentColor,currentColor) center/1.7px 18px no-repeat;border-radius:2px}
.send-button{width:42px;height:42px;box-shadow:none}.send-button:disabled{background:#e1e3e8;color:#fff}
.composer-note{color:#9a9eaa}
.attachment-chip{border:0;background:var(--surface-soft);box-shadow:none;border-radius:12px}
.attachment-thumb{background:#fff}.attachment-thumb-icon svg{color:#606574}
.attachment-role{color:#5548d0}.remove-attachment{display:grid;place-items:center}.remove-attachment:hover{background:#e4e5e9}
.approval-dock{border:0;background:#fff;box-shadow:var(--shadow);border-radius:14px}

.project-control-card{border:0;border-radius:18px;padding:17px;background:#fff;box-shadow:var(--shadow)}
.project-control-header{margin-bottom:12px}.control-eyebrow{font-size:8px;color:#858996}.project-control-header h2{font-size:18px;font-weight:700}
.live-badge{border:0;background:#edf7f1;color:#267153;font-size:9px;font-weight:650;padding:5px 8px}
.control-status{border-radius:14px;background:var(--surface-soft);padding:12px;grid-template-columns:36px minmax(0,1fr);gap:10px}
.control-status-icon{width:36px;height:36px;border-radius:11px;background:#e7e9ee}
.control-section{border-top:0;padding:13px 0}.control-section+.control-section{box-shadow:0 -1px 0 var(--line)}
.control-section h3{font-size:10px;text-transform:uppercase;letter-spacing:.035em;color:#717582;margin-bottom:9px}
.control-section-head span{background:#eceafc;color:#5549c7}
.control-material{padding:6px 0}.control-line-icon{background:var(--surface-soft);border-radius:9px}.control-material.complete .control-line-icon{background:#e7f5ed}
.control-actions{gap:7px}.control-actions button{border:0;border-radius:11px;min-height:40px}
.control-action-secondary{background:var(--surface-soft)}
.control-truth{border:0;border-radius:12px;background:#edf8f2;padding:10px 11px;color:#527061}
.control-truth-icon svg{width:15px;height:15px;color:#168052;stroke-width:2}

.sheet-backdrop{background:rgba(20,23,34,.34);backdrop-filter:blur(3px)}
.bottom-sheet{border:0;border-radius:22px;padding:10px 16px calc(18px + env(safe-area-inset-bottom));box-shadow:var(--shadow-float)}
.sheet-head{margin-bottom:12px}.sheet-head h2{font-size:18px;font-weight:700}.sheet-head button{border:0;background:transparent}
.source-option{border:0;background:var(--surface-soft);border-radius:14px;min-height:66px;padding:12px;margin-bottom:8px}
.source-option:hover{background:#eceef2}
.source-option-icon{width:36px;height:36px;border-radius:10px;background:#fff;color:#565b68}
.source-option-icon svg{width:19px;height:19px}
.link-input{border:0;background:var(--surface-soft);box-shadow:inset 0 0 0 1px transparent}
.link-input:focus{box-shadow:var(--focus)}
.notice-icon{border:0;background:#e9f7ef;color:#168052}.notice-icon svg{width:26px;height:26px;stroke-width:2}

.mobile-summary-button{border:0;background:var(--surface-soft);border-radius:13px}
.mobile-project-control-sheet .control-actions{gap:7px}

@media(min-width:1080px){
  body{background:var(--canvas)}
  .workspace{grid-template-columns:232px minmax(0,1fr) 280px;gap:12px;padding:12px;max-width:1500px;background:var(--canvas)}
  .left-sidebar{border:0;border-radius:0;background:transparent;box-shadow:none;padding:10px 9px}
  .conversation-panel{border:0;border-radius:20px;background:#fff;box-shadow:0 8px 30px rgba(27,31,48,.055);overflow:hidden}
  .summary-panel{padding-top:0}
  .project-control-card{box-shadow:0 8px 30px rgba(27,31,48,.055)}
  .conversation{padding:30px 38px 28px;max-width:900px}
  .chat-bottom{padding-left:22px;padding-right:22px}
}
@media(max-width:1079px){
  html,body,.workspace{background:#fff}
  .left-sidebar{inset:60px auto 0 0;border-right:0;box-shadow:18px 0 48px rgba(24,27,45,.15)}
  .mobile-overlay{inset:60px 0 0}
  .mobile-summary-button{padding:9px 11px}
}
@media(max-width:699px){
  .topbar{height:56px;flex-basis:56px;padding-left:8px;padding-right:8px}
  .left-sidebar{inset:56px auto 0 0}
  .mobile-overlay{inset:56px 0 0}
  .conversation{padding-top:20px;padding-bottom:20px}
  .welcome-message h1{font-size:25px}.welcome-message p{font-size:13px}
  .assistant-message,.user-message{margin-bottom:20px}
  .message-content{font-size:14px}
  .quick-prompts{gap:6px}.quick-prompts button{min-height:38px}
  .composer-row{border-radius:20px;padding:6px}.icon-button,.send-button{width:40px;height:40px}
  .mobile-project-control-sheet{border-radius:22px 22px 0 0}
}
@media(prefers-reduced-motion:reduce){
  *,*::before,*::after{scroll-behavior:auto!important;animation-duration:.001ms!important;animation-iteration-count:1!important;transition-duration:.001ms!important}
}
.message-attachment-icon{display:grid;place-items:center;color:#626775}.message-attachment-icon svg{width:16px;height:16px}

/* F14 S1 — server-synced workspace + responsive laptop/mobile correction. */
html{
  -webkit-text-size-adjust:100%;
  text-size-adjust:100%;
}
html,body,.app-shell{min-height:100svh;height:100dvh}

/* One composer boundary only: textarea and label never draw a second box. */
.composer-row{
  border:1px solid #e1e3e9!important;
  box-shadow:0 8px 24px rgba(28,32,49,.10)!important;
}
.composer-row:focus-within{
  border-color:rgba(106,92,255,.62)!important;
  box-shadow:0 10px 28px rgba(28,32,49,.12)!important;
}
.input-wrap,.input-wrap:focus-within{
  border:0!important;
  outline:0!important;
  box-shadow:none!important;
  background:transparent!important;
  padding:0!important;
  border-radius:0!important;
  -webkit-appearance:none;
  appearance:none;
}
.input-wrap textarea,.input-wrap textarea:focus,.input-wrap textarea:focus-visible{
  border:0!important;
  outline:0!important;
  box-shadow:none!important;
  background:transparent!important;
  -webkit-appearance:none;
  appearance:none;
}
.welcome-message[hidden]{display:none!important}

/* Compact laptop contract: keep composer, recent projects and project controls visible at 100%. */
@media (min-width:1080px) and (max-width:1439px){
  .topbar{height:54px;flex-basis:54px;padding-inline:10px}
  .brand-owner-logo{width:154px;height:46px;flex-basis:154px}
  .brand-owner-logo img{width:184px;height:184px;left:-15px;top:-67px}
  .usage-pill{height:34px;font-size:12px;padding-inline:10px}
  .workspace{grid-template-columns:210px minmax(0,1fr) 252px;gap:8px;padding:8px;max-width:none}
  .left-sidebar{padding:6px 5px;gap:7px}
  .sidebar-head{padding-inline:5px}.sidebar-head strong{font-size:11px}
  .new-video-button{height:44px;border-radius:13px;font-size:13px}
  .sidebar-nav{gap:2px;padding-bottom:4px}
  .nav-item{grid-template-columns:28px 1fr;padding:8px 7px;border-radius:12px;gap:6px}
  .nav-item strong{font-size:11px}.nav-item small{font-size:8px;margin-top:1px}
  .nav-icon svg{width:17px;height:17px}
  .recent-projects-head{padding:1px 6px 2px}.recent-projects-head h3{font-size:10px}
  .recent-projects-list{max-height:min(25dvh,185px)}
  .recent-project-item{padding:6px 7px}.recent-project-item strong{font-size:10px}.recent-project-item small{font-size:8px}
  .sidebar-tip{padding:9px;border-radius:14px;gap:7px}.sidebar-tip strong{font-size:10px}.sidebar-tip p{font-size:9px;margin-top:3px}
  .sidebar-account{padding-top:8px;grid-template-columns:32px 1fr 24px}.account-avatar{width:32px;height:32px}
  .sidebar-account strong{font-size:10px}.sidebar-account small{font-size:8px}
  .conversation-panel{border-radius:16px}
  .project-context-bar{min-height:44px;padding:6px 13px}
  .project-context-copy strong{font-size:11px}.project-save-status{font-size:8px;padding:4px 7px}
  .conversation{max-width:760px;padding:18px 22px 20px}
  .welcome-message h1{font-size:25px;margin-bottom:8px}.welcome-message p{font-size:12px;line-height:1.5}
  .quick-prompts{margin-top:11px;gap:6px}.quick-prompts button{min-height:36px;font-size:11px;padding-inline:11px}
  .assistant-message,.user-message{margin-bottom:16px}.message-content{font-size:13px}
  .chat-bottom{padding:6px 12px 7px}
  .mobile-summary-button{margin-bottom:5px;padding:7px 10px}
  .composer-row{padding:5px;border-radius:18px}.icon-button,.send-button{width:38px;height:38px}.input-wrap{min-height:38px}
  .input-wrap textarea{font-size:14px;max-height:88px;padding:8px 2px 6px}
  .composer-note{font-size:8px;margin-top:3px}
  .project-control-card{padding:13px;border-radius:15px;max-height:calc(100dvh - 70px);overflow:auto;overscroll-behavior:contain}
  .project-control-header{margin-bottom:9px}.project-control-header h2{font-size:15px}.control-eyebrow{font-size:7px}
  .control-status{padding:9px;grid-template-columns:31px 1fr;gap:8px}.control-status-icon{width:31px;height:31px}
  .control-status strong{font-size:11px}.control-status p{font-size:8px;margin-top:2px}
  .control-section{padding:9px 0}.control-section h3{font-size:8px;margin-bottom:6px}
  .control-material{padding:4px 0;grid-template-columns:26px 1fr;gap:6px}.control-line-icon{width:26px;height:26px}
  .control-material small{font-size:8px}.control-material strong{font-size:9px}
  .control-objective-section p{font-size:9px;line-height:1.4;-webkit-line-clamp:3}
  .control-actions{gap:5px}.control-actions button{min-height:36px;font-size:10px}
  .control-truth{padding:8px;font-size:8px}
}

@media (min-width:1080px) and (max-height:820px){
  .topbar{height:50px;flex-basis:50px}
  .workspace{padding:6px;gap:6px}
  .left-sidebar{gap:5px}.sidebar-tip{display:none}
  .recent-projects-list{max-height:min(24dvh,140px)}
  .conversation{padding-top:12px;padding-bottom:12px}
  .welcome-message h1{font-size:23px}.welcome-message p{font-size:11px}.quick-prompts{margin-top:8px}
  .assistant-message,.user-message{margin-bottom:12px}
  .chat-bottom{padding-top:4px;padding-bottom:5px}
  .composer-note{display:none}
  .project-control-card{max-height:calc(100dvh - 62px);padding:11px}
  .control-section{padding:7px 0}.control-truth{margin-top:2px}
}

/* Tablet and phone: the conversation owns the screen; menus and control surfaces become drawers. */
@media (max-width:1079px){
  .topbar{height:56px;flex-basis:56px;padding:0 10px}
  .brand-owner-logo{width:144px;height:44px;flex-basis:144px}
  .brand-owner-logo img{width:172px;height:172px;left:-14px;top:-63px}
  .usage-pill{height:34px;font-size:12px;padding:0 11px}
  .left-sidebar{inset:56px auto 0 0;width:min(88vw,360px);padding:16px 16px max(16px,env(safe-area-inset-bottom));overflow-y:auto;overscroll-behavior:contain}
  .mobile-overlay{inset:56px 0 0}
  .workspace{height:calc(100dvh - 56px)}
  .conversation-panel{height:100%;min-height:0}
  .project-context-bar{min-height:48px;padding:7px 13px}
  .conversation{scrollbar-gutter:auto}
  .chat-bottom{padding-bottom:max(8px,env(safe-area-inset-bottom))}
  .bottom-sheet{max-height:min(86dvh,720px);overflow-y:auto;overscroll-behavior:contain}
}

@media (max-width:699px){
  .topbar{height:54px;flex-basis:54px;padding:0 8px}
  .workspace{height:calc(100dvh - 54px)}
  .left-sidebar{inset:54px auto 0 0;width:min(88vw,342px);padding:13px 14px max(14px,env(safe-area-inset-bottom));gap:10px}
  .mobile-overlay{inset:54px 0 0}
  .brand-owner-logo{width:132px;height:40px;flex-basis:132px}
  .brand-owner-logo img{width:158px;height:158px;left:-13px;top:-58px}
  .menu-button{width:38px;height:38px}.menu-button svg{width:21px;height:21px}
  .usage-pill{height:32px;max-width:132px;font-size:11px;padding:0 10px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .usage-dot{width:7px;height:7px}
  .project-context-bar{min-height:46px;padding:6px 12px}
  .project-context-copy strong{font-size:12px}.project-save-status{font-size:9px;max-width:130px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .conversation{padding:14px 13px 16px;max-width:none}
  .welcome-message h1{font-size:27px;line-height:1.08;margin-bottom:11px;letter-spacing:-.035em}
  .welcome-message p{font-size:14px;line-height:1.55}
  .quick-prompts{display:flex;flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none;gap:7px;margin:14px -1px 0;padding:1px 1px 3px;overscroll-behavior-x:contain}
  .quick-prompts::-webkit-scrollbar{display:none}
  .quick-prompts button{flex:0 0 auto;min-height:38px;border-radius:12px;padding:0 13px;font-size:12px}
  .assistant-message,.user-message{margin-bottom:16px}
  .message-content{font-size:14px;line-height:1.52}
  .user-message .message-content{max-width:92%;padding:10px 12px;border-radius:16px 16px 5px 16px}
  .assistant-message:not(.welcome-message) .message-content{max-width:100%;padding:10px 11px}
  .generated-image img{max-height:56dvh;border-radius:13px}.generated-image{max-width:100%}
  .uploaded-source-figure{width:clamp(104px,34vw,132px)}
  .chat-bottom{padding:6px 8px max(7px,env(safe-area-inset-bottom));box-shadow:0 -1px 0 var(--line)}
  .mobile-summary-button{min-height:48px;margin-bottom:5px;padding:7px 10px;border-radius:13px}
  .mobile-summary-button b{font-size:12px}.mobile-summary-button small{font-size:9px}
  .composer-row{gap:5px;padding:4px;border-radius:18px}
  .icon-button,.send-button{width:40px;height:40px}.add-button::before{width:17px;height:17px;background-size:17px 1.6px,1.6px 17px}
  .input-wrap{min-height:40px}.input-wrap textarea{font-size:16px;line-height:1.35;max-height:96px;padding:8px 2px 7px}
  .composer-note{display:none}
  .attachment-strip{padding-bottom:5px}.attachment-chip{max-width:220px;padding:5px 7px}
  .approval-dock{padding:7px 7px 7px 10px;margin-bottom:5px}.approval-dock .primary-button{min-width:104px;min-height:40px}
  .sidebar-head strong{font-size:12px}.sidebar-close{width:36px;height:36px}
  .new-video-button{height:48px;border-radius:14px}
  .sidebar-nav{gap:2px}.nav-item{padding:9px 8px;grid-template-columns:31px 1fr}.nav-item strong{font-size:13px}.nav-item small{font-size:10px}
  .recent-projects-list{max-height:min(36dvh,300px)}
  .recent-project-item{padding:9px 8px}.recent-project-item strong{font-size:13px}.recent-project-item small{font-size:10px}
  .sidebar-tip{padding:11px;border-radius:15px}.sidebar-tip p{font-size:10px}
  .sidebar-account{position:relative;padding-top:10px}
  .mobile-project-control-sheet{max-height:min(82dvh,680px);padding:8px 15px max(16px,env(safe-area-inset-bottom));border-radius:20px 20px 0 0}
  .mobile-project-control-sheet .control-status{padding:11px}
  .mobile-project-control-sheet .control-section{padding:11px 0}
  .mobile-project-control-sheet .control-actions{grid-template-columns:1fr 1fr}
  .mobile-project-control-sheet .control-actions button{min-height:44px}
}

@media (max-width:380px){
  .brand-owner-logo{width:118px;height:38px;flex-basis:118px}
  .brand-owner-logo img{width:142px;height:142px;left:-12px;top:-52px}
  .usage-pill{max-width:116px;font-size:10px;padding-inline:8px}
  .welcome-message h1{font-size:24px}.welcome-message p{font-size:13px}
  .left-sidebar{width:90vw}
}

@media (max-width:699px) and (max-height:700px){
  .topbar{height:50px;flex-basis:50px}.workspace{height:calc(100dvh - 50px)}
  .left-sidebar{inset:50px auto 0 0}.mobile-overlay{inset:50px 0 0}
  .project-context-bar{min-height:42px}
  .conversation{padding-top:10px;padding-bottom:10px}
  .welcome-message h1{font-size:23px;margin-bottom:7px}.welcome-message p{font-size:12px}.quick-prompts{margin-top:9px}
  .mobile-summary-button{min-height:44px}.chat-bottom{padding-top:4px}
  .sidebar-tip{display:none}.recent-projects-list{max-height:34dvh}
}


/* F14 S2 U1: server source-media hydration and compact creation entry. */
.project-context-copy{min-width:0;display:flex;align-items:center}
.project-context-copy strong{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.welcome-message{margin-bottom:14px}
.welcome-message .message-content{width:100%;padding-top:0}
.welcome-message h1{font-size:24px;line-height:1.18;margin:0;max-width:760px;letter-spacing:-.028em}

@media (min-width:1080px) and (max-width:1439px){
  .welcome-message h1{font-size:21px;line-height:1.18;margin:0}
  .conversation{padding-top:14px}
}
@media (min-width:1080px) and (max-height:820px){
  .welcome-message h1{font-size:20px}
}
@media (max-width:699px){
  .project-context-bar{display:none}
  .conversation{padding-top:13px}
  .welcome-message{margin-bottom:10px}
  .welcome-message h1{font-size:clamp(20px,5.8vw,24px);line-height:1.17;margin:0;max-width:100%}
}
@media (max-width:380px){
  .welcome-message h1{font-size:20px;line-height:1.16}
}
@media (max-width:699px) and (max-height:700px){
  .welcome-message h1{font-size:19px}
  .conversation{padding-top:9px}
}


/* F14 S2 U2: typography harmony requested after cross-device source sync acceptance. */
.welcome-message h1,.project-control-header h2,.sheet-head h2,.mobile-summary-button b{font-size:13px;font-weight:650;line-height:1.35;letter-spacing:0}
.welcome-message h1{max-width:100%;margin:0;color:var(--ink)}
.project-control-header h2,.sheet-head h2{margin:0}
@media (min-width:1080px) and (max-width:1439px){
  .welcome-message h1,.project-control-header h2,.sheet-head h2{font-size:11px}
}
@media (max-width:699px){
  .welcome-message h1,.project-control-header h2,.sheet-head h2,.mobile-summary-button b{font-size:13px;line-height:1.35}
}

/* F14 S3 U1: one command gateway. */
.command-gateway-section p{margin:0;color:var(--muted);font-size:12px;line-height:1.5}
.result-only-actions{display:flex;gap:8px;margin-top:10px}
.ai-actions,.script-card .message-actions{display:none!important}
@media(max-width:699px){.command-gateway-section p{font-size:12px}.result-only-actions .secondary-button{min-height:42px}}

/* F14 S3 U6: hide only the duplicate project-control strip above the composer; desktop panel and mobile sheet payload remain preserved. */
.mobile-summary-button[hidden]{display:none!important}


/* F15 S2 U1 — Vision 1.0 explicit project-goal gate. New copy follows existing SENSEL type scale. */
.welcome-description{margin:5px 0 0!important;color:var(--muted)!important;font-size:12px!important;line-height:1.5!important;max-width:680px}
.project-goal-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:9px;margin-top:14px}
.project-goal-card{min-width:0;border:0;background:var(--surface-soft);border-radius:15px;padding:13px;display:grid;grid-template-columns:34px minmax(0,1fr) 14px;gap:10px;align-items:center;text-align:left;color:var(--ink)}
.project-goal-card:hover,.project-goal-card:focus-visible{background:var(--surface-accent);outline:0;box-shadow:var(--focus)}
.project-goal-card:active{transform:scale(.99)}
.project-goal-icon{width:34px;height:34px;border-radius:11px;background:#fff;display:grid;place-items:center;color:var(--purple)}
.project-goal-icon svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.project-goal-card strong,.project-goal-card small{display:block}.project-goal-card strong{font-size:13px;font-weight:650;line-height:1.35}.project-goal-card small{margin-top:3px;color:var(--muted);font-size:10px;line-height:1.4}.project-goal-arrow{color:#8a8e9b;font-size:22px;line-height:1}
.selected-task-banner{margin:0 0 14px;padding:12px 13px;border-radius:15px;background:var(--surface-soft);display:flex;align-items:center;justify-content:space-between;gap:12px}
.selected-task-banner[hidden]{display:none!important}.selected-task-copy{min-width:0}.selected-task-copy small,.selected-task-copy strong{display:block}.selected-task-copy small{font-size:9px;color:var(--muted)}.selected-task-copy strong{font-size:13px;font-weight:650;line-height:1.35;margin-top:2px}.selected-task-copy p{font-size:10px;line-height:1.4;color:var(--muted);margin:3px 0 0}.selected-task-change{flex:0 0 auto;border:0;background:#fff;border-radius:11px;min-height:36px;padding:0 11px;font-size:10px;font-weight:650;color:#5550c8}
.sheet-section-label{margin:3px 3px 7px;color:#7a7e8b;font-size:9px;font-weight:800;letter-spacing:.07em;text-transform:uppercase}.task-section-label{margin-top:14px;padding-top:12px;border-top:1px solid var(--line)}
.task-source-option{background:#fbfbfd}.video-mode-option{min-height:78px}.vision-mode-note{margin-top:11px;padding:11px 12px;border-radius:13px;background:#f0faf5;color:#4c6f5e;display:grid;gap:3px}.vision-mode-note strong{font-size:11px}.vision-mode-note span{font-size:10px;line-height:1.45}
@media(max-width:1079px){.project-goal-grid{grid-template-columns:1fr}.project-goal-card{padding:12px}.welcome-description{font-size:11px!important}}
@media(max-width:699px){.project-goal-grid{gap:8px;margin-top:12px}.project-goal-card{min-height:70px;padding:11px 12px;grid-template-columns:32px minmax(0,1fr) 12px}.project-goal-icon{width:32px;height:32px}.project-goal-card strong{font-size:13px}.project-goal-card small{font-size:10px}.selected-task-banner{margin-bottom:10px;padding:10px 11px}.selected-task-copy strong{font-size:12px}.selected-task-copy p{font-size:9px}.selected-task-change{min-height:34px}}
@media(max-width:380px){.project-goal-card{grid-template-columns:30px minmax(0,1fr) 10px;padding:10px}.project-goal-icon{width:30px;height:30px}.project-goal-card strong{font-size:12px}.welcome-description{font-size:10px!important}}


/* F15 S2 U2 — Vision 1.0 explicit input-role lock and confirmation */
.vision-readiness-card{max-width:760px;margin:8px auto 16px;border:1px solid #e7e4ff;border-radius:18px;background:#fff;padding:14px;box-shadow:0 12px 34px rgba(45,39,95,.08)}
.vision-readiness-card[hidden]{display:none}.vision-readiness-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:11px}.vision-readiness-head small{display:block;color:#777b89;font-size:9px;font-weight:800;text-transform:uppercase;letter-spacing:.08em}.vision-readiness-head h2{font-size:14px;line-height:1.25;margin:3px 0 0}.vision-readiness-status{border-radius:999px;background:#f1f1f5;color:#6e7280;font-size:9px;font-weight:800;padding:6px 9px;white-space:nowrap}.vision-readiness-status[data-state="ready"]{background:#eaf8f1;color:#218458}.vision-readiness-status[data-state="locked"]{background:#eeeaff;color:#5d48d8}
.vision-material-grid{display:grid;grid-template-columns:1fr 1fr;gap:9px}.vision-material-slot{display:grid;grid-template-columns:34px minmax(0,1fr) 22px;align-items:center;gap:9px;min-height:78px;border:1px solid #ececf2;background:#f8f8fb;border-radius:14px;padding:10px;text-align:left;color:var(--ink)}.vision-material-slot.complete{border-color:#cbeedc;background:#f3fbf7}.vision-material-slot:disabled{opacity:.86}.vision-slot-icon{width:34px;height:34px;border-radius:10px;background:#efedff;color:var(--purple);display:grid;place-items:center}.vision-slot-icon svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}.vision-material-slot small,.vision-material-slot strong,.vision-material-slot em{display:block}.vision-material-slot small{font-size:9px;color:#777b89}.vision-material-slot strong{font-size:11px;font-weight:700;margin-top:2px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.vision-material-slot em{font-size:9px;color:#8a8d99;font-style:normal;margin-top:3px}.vision-material-slot b{font-size:17px;color:var(--purple);font-weight:600;text-align:center}
.vision-preserve-box{margin-top:10px;border-radius:13px;background:#f1faf5;padding:10px 11px;color:#466b59}.vision-preserve-box strong{font-size:10px}.vision-preserve-box p{font-size:10px;line-height:1.45;margin:3px 0}.vision-preserve-box small{font-size:9px;color:#638171}.vision-rights-check{display:flex;align-items:flex-start;gap:8px;margin:11px 2px 0;font-size:10px;line-height:1.4;color:#575b68}.vision-rights-check input{margin-top:1px;accent-color:var(--purple);width:15px;height:15px}.vision-readiness-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:11px}.vision-readiness-actions .primary-button,.vision-readiness-actions .secondary-button{min-height:38px;padding:0 14px}.vision-safe-note{font-size:9px;line-height:1.4;color:#858895;margin:8px 2px 0}.vision-link-hold{font-size:10px;line-height:1.45;color:#6f7380;background:#f7f7fa;border-radius:12px;padding:10px 11px;margin:8px 0 0}
#visionSourceOptions[hidden],#standardSourceOptions[hidden]{display:none}#visionSourceOptions .source-option,#standardSourceOptions .source-option{width:100%;margin-bottom:8px}
@media(max-width:760px){.vision-readiness-card{margin:8px 0 14px;padding:12px;border-radius:16px}.vision-material-grid{grid-template-columns:1fr}.vision-material-slot{min-height:72px}.vision-readiness-head h2{font-size:14px}.vision-readiness-actions{display:grid;grid-template-columns:1fr 1fr}.vision-readiness-actions button{width:100%}}
