:root{--bg:#f4f5f4;--paper:#fff;--ink:#222925;--muted:#7b827d;--line:#e4e7e4;--accent:#293b31;--soft:#eaf0eb;--sans:Inter,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif}
*{box-sizing:border-box}
body{margin:0;background:var(--bg);color:var(--ink);font:13px var(--sans);-webkit-font-smoothing:antialiased}
button,input,textarea,select{font:inherit;color:inherit}
button,a{touch-action:manipulation;-webkit-tap-highlight-color:transparent}
button{border:0;background:none;cursor:pointer}
button:disabled{cursor:not-allowed;opacity:.5}
a{color:inherit;text-decoration:none}
button:focus-visible,a:focus-visible,select:focus-visible,label:has(input:focus-visible){outline:2px solid #7c9683;outline-offset:4px}
input:focus,textarea:focus{outline:none}
[hidden]{display:none!important}
.svg-defs{position:absolute;width:0;height:0;overflow:hidden}
.icon{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}
.sr-only{position:absolute;width:1px;height:1px;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}
.app-shell{min-height:100dvh;display:flex}
.sidebar{width:222px;flex-shrink:0;display:flex;flex-direction:column;position:sticky;top:0;height:100dvh;min-height:550px;background:#fafbf9;border-right:1px solid var(--line);padding:30px 18px 18px}
.brand{display:flex;align-items:center;gap:10px;margin:0 3px 35px}
.brand-monogram{font:35px Georgia,serif;letter-spacing:-3px;line-height:1}
.brand-name{font-size:13px;font-weight:600;letter-spacing:-.2px}
.brand-name>span{display:block;font-size:7px;font-weight:500;letter-spacing:1.35px;color:var(--muted);margin-top:6px}
.new-button{width:100%;display:flex;align-items:center;justify-content:center;gap:8px;border-radius:6px;padding:11px 10px;background:var(--ink);color:#fff;font-size:12px;font-weight:500;transition:background .2s}
.new-button:hover{background:var(--accent)}
.new-button>.icon{width:16px;height:16px}
.main-nav{display:grid;gap:4px;margin-top:26px}
.nav-item{display:flex;align-items:center;gap:11px;text-align:left;padding:12px 13px;border-radius:6px;font-size:12px;color:#757d77}
.nav-item>.icon{width:17px;height:17px}
.nav-item.active{background:var(--soft);color:var(--accent);font-weight:600}
.nav-item:hover:not(.active){background:#f0f2ef}
.nav-count{margin-left:auto;font-size:10px;color:#929891}
.history-heading{margin:35px 12px 13px;font-size:9px;letter-spacing:1.4px;color:#969d96}
.history-list{flex:1;min-height:50px;overflow:auto}
.history-empty{font-size:11px;color:#969d96;margin:9px 12px}
.history-item{width:100%;display:flex;align-items:center;gap:9px;text-align:left;padding:10px 12px;border-radius:5px;font-size:11px;color:#7a817b}
.history-item>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.history-item>.icon{width:13px;height:13px;opacity:.6}
.history-item:hover,.history-item.active{background:#eef1ed;color:var(--accent)}
.sidebar-bottom{padding-top:20px}
.budget-card{padding:15px 9px 19px;border-bottom:1px solid var(--line)}
.budget-amount{display:flex;align-items:baseline;gap:7px}
.budget-amount>strong{font-size:22px;font-weight:500;letter-spacing:-.6px}
.budget-amount>span{font-size:10px;color:#7a827a}
.budget-card progress{display:block;width:100%;height:3px;appearance:none;border:0;border-radius:5px;overflow:hidden;margin:12px 0 9px;background:#e2e7e1}
.budget-card progress::-webkit-progress-bar{background:#e2e7e1}
.budget-card progress::-webkit-progress-value{background:#7e9784;border-radius:5px}
.budget-card progress::-moz-progress-bar{background:#7e9784}
.budget-detail{display:flex;justify-content:space-between;gap:5px;font-size:9px;color:#91988f}
.budget-more{display:flex;align-items:center;justify-content:space-between;gap:8px;width:100%;padding:13px 0 0;font-size:10px;color:#788373}
.budget-more>.icon{width:13px;height:13px}
.profile{display:flex;align-items:center;gap:9px;padding:19px 3px 0}
.avatar{width:31px;height:31px;border-radius:50%;display:flex;align-items:center;justify-content:center;background:#e9ece5;color:#6f7b69;font-size:10px;flex-shrink:0}
.profile>div{flex:1}
.profile strong{display:block;font-size:11px;font-weight:500}
.profile div>span{display:block;font-size:9px;color:#969c93;margin-top:4px}
#profile-lock>.icon{width:13px;height:13px;color:#a0a69c}
.workspace{flex:1;min-width:0}
.topbar{height:68px;display:flex;align-items:center;justify-content:space-between;padding:0 35px;border-bottom:1px solid var(--line);background:#fff}
.breadcrumbs,.topbar-right{display:flex;align-items:center;gap:16px}
.breadcrumbs>strong{font-size:12px;font-weight:500}
.private-badge{display:flex;align-items:center;gap:6px;font-size:10px;color:#8c958c}
.private-badge>.icon{width:12px;height:12px}
.icon-button{display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;border-radius:5px;flex-shrink:0;color:#939c94}
.icon-button:hover{background:#edf1eb;color:var(--accent)}
.topbar-right>.icon-button>.icon{width:16px;height:16px}
.mobile-menu{display:none}
.setup-banner{display:flex;align-items:center;gap:8px;font-size:10px;color:#78856f;background:#edf1e9;padding:9px 35px;border-bottom:1px solid #e0e6da}
.setup-banner>.icon{width:13px;height:13px}
.main-layout{max-width:1140px;margin:0 auto}
.creative-space{padding:40px 48px 35px;min-width:0}
.editor-heading{display:flex;align-items:center;justify-content:space-between;gap:18px;margin-bottom:25px}
h1{margin:0;font-size:24px;font-weight:550;letter-spacing:-.7px;line-height:1.4}
.editor-heading p{margin:7px 0 0;font-size:11px;color:#939b93}
.size-control{display:flex;align-items:center;gap:9px;font-size:10px;color:#969e97;flex-shrink:0}
.size-control select{font-size:11px;border:1px solid #dfe5df;background:#fff;border-radius:5px;padding:9px 25px 9px 10px;cursor:pointer;color:#606c61}
.welcome{width:100%}
.dropzone{min-height:340px;height:clamp(340px,45vh,520px);display:flex;align-items:center;justify-content:center;position:relative;border:1px dashed #ccd4cd;border-radius:8px;cursor:pointer;overflow:hidden;background-color:#fafbf9;background-image:radial-gradient(#dce2db .7px,transparent .7px);background-size:17px 17px;transition:border-color .2s,background-color .2s}
.dropzone:hover,.dropzone.drag-over{border-color:#829783;background-color:#f1f5ee}
.dropzone input{position:absolute;width:1px;height:1px;opacity:0}
.upload-empty{display:flex;flex-direction:column;align-items:center;padding:30px;text-align:center}
.upload-icon{display:flex;align-items:center;justify-content:center;width:57px;height:57px;border:1px solid #e1e7de;border-radius:12px;color:#7b8e76;background:#fff;box-shadow:0 3px 10px #253d2410;margin-bottom:20px}
.upload-icon>.icon{width:25px;height:25px;stroke-width:1.3}
.upload-empty>strong{font-size:15px;font-weight:500;letter-spacing:-.2px;color:#5a685a}
.upload-button{display:flex;align-items:center;gap:7px;border:1px solid #dce4d8;background:#fff;border-radius:5px;padding:10px 14px;margin-top:17px;font-size:11px;color:#687a61;box-shadow:0 2px 2px #30442704}
.upload-button>.icon{width:14px;height:14px}
.upload-empty>small{font-size:9px;color:#a0aa9b;margin-top:15px}
.source-preview{display:block;width:100%;height:100%;object-fit:contain;background:#edf0e9}
.preview-label{position:absolute;bottom:15px;right:15px;display:flex;align-items:center;gap:6px;padding:9px 12px;font-size:10px;color:#52614d;background:#fffffff2;box-shadow:0 2px 10px #14240e14;border-radius:5px}
.preview-label>.icon{width:13px;height:13px}
.composer-area{margin-top:18px}
.composer{padding:17px 18px 13px;background:#fff;border:1px solid #dbe2d8;border-radius:8px;box-shadow:0 4px 10px #2a3d2010;transition:border-color .2s,box-shadow .2s}
.composer:focus-within{border-color:#a4b69b;box-shadow:0 0 0 3px #94ac8312}
.composer textarea{display:block;width:100%;min-height:60px;max-height:180px;resize:vertical;border:0;padding:0;background:none;line-height:1.7;font-size:13px}
.composer textarea::placeholder{color:#99a192}
.composer-bottom{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:10px}
.attach-button{display:inline-flex;align-items:center;gap:6px;padding:7px 3px;font-size:11px;color:#768370}
.attach-button>.icon{width:16px;height:16px}
.attach-button:hover{color:var(--ink)}
.send-controls{display:flex;align-items:center;gap:14px}
#prompt-counter{font-size:9px;color:#a4ac9f}
.generate-button{display:inline-flex;align-items:center;justify-content:center;gap:12px;padding:11px 15px;border-radius:5px;background:var(--ink);color:#fff;font-size:11px;font-weight:500;transition:background .2s;white-space:nowrap}
.generate-button:hover{background:var(--accent)}
.generate-button>.icon{width:15px;height:15px}
.composer-footer{display:flex;justify-content:space-between;gap:12px;margin:11px 2px 0;color:#959f8f;font-size:9px;line-height:1.6}
.form-error{font-size:11px;line-height:1.7;color:#975b4a;background:#faf0eb;border:1px solid #efddd2;border-radius:6px;padding:10px 13px}
.reference-list{display:flex;flex-wrap:wrap;gap:10px;margin-bottom:13px}
.reference-list:empty{display:none}
.reference-item{display:flex;align-items:center;gap:10px;border:1px solid #dfe5db;border-radius:6px;background:#fff;padding:5px;max-width:calc(33.333% - 7px);flex:1;min-width:0}
.reference-item img{width:58px;height:43px;object-fit:cover;border-radius:3px}
.reference-item>span{flex:1;font-size:10px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#84907b}
.reference-item .icon-button{width:25px;height:25px}
.reference-item .icon{width:13px;height:13px}
.editing-indicator{display:flex;align-items:center;gap:7px;margin-bottom:12px;padding:5px 10px;border-radius:5px;background:#e7ede2;color:#71836a;font-size:10px}
.editing-indicator>.icon{width:14px;height:14px}
.editing-indicator>.icon-button{margin-left:auto;width:25px;height:25px}
.editing-indicator .icon-button>.icon{width:13px;height:13px}
.messages{display:flex;flex-direction:column;gap:15px}
.message-user{max-width:100%;font-size:12px;color:#76816f;white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.7;padding:0 2px;margin-top:10px}
.message-assistant{margin-bottom:15px}
.assistant-avatar{display:none}
.message-content{min-width:0}
.result-image-button{padding:0;display:block;width:100%;border-radius:7px;overflow:hidden;background:#e9eee5}
.result-image{display:block;width:100%;height:auto;max-height:620px;object-fit:contain}
.result-actions{display:flex;gap:8px;margin-top:11px;flex-wrap:wrap}
.small-button{display:inline-flex;align-items:center;gap:6px;padding:8px 11px;border:1px solid #dce4d5;background:#fff;border-radius:5px;font-size:10px;color:#728567}
.small-button:hover{background:#edf2e7}
.small-button>.icon{width:13px;height:13px}
.message-error{background:#f7eee8;border:1px solid #eadbcb;border-radius:6px;padding:13px;font-size:11px;color:#9a7e60;line-height:1.8}
.pending-card{display:flex;align-items:center;justify-content:center;flex-direction:column;gap:14px;min-height:280px;border:1px solid #e0e7d9;border-radius:7px;background:linear-gradient(110deg,#eaf0e3 8%,#f7faf3 18%,#eaf0e3 33%);background-size:220% 100%;animation:shimmer 3s linear infinite;color:#80956f;font-size:12px}
.pending-card>.icon{width:26px;height:26px}
.pending-card small{font-size:10px;color:#98a78b}
.gallery-view{max-width:1140px;padding:40px 48px;margin:0 auto}
.gallery-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px;margin-top:25px}
.gallery-card{overflow:hidden;border:1px solid var(--line);border-radius:7px;background:#fff}
.gallery-card>.result-image-button{border-radius:0}
.gallery-card .result-image{aspect-ratio:1.5;object-fit:cover}
.gallery-card-body{padding:14px}
.gallery-card-body>p{font-size:11px;line-height:1.6;margin:0;color:#7a8a6c;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.gallery-empty{grid-column:1/-1;display:flex;flex-direction:column;align-items:center;justify-content:center;min-height:340px;border:1px dashed #d5dfca;border-radius:8px;text-align:center;color:#8e9e7c}
.gallery-empty>.icon{width:32px;height:32px}
.gallery-empty h3{font-size:15px;font-weight:500;margin:18px 0 22px}
dialog{max-width:min(520px,calc(100vw - 32px));max-height:calc(100dvh - 40px);padding:35px;border:1px solid #dde4d7;border-radius:10px;background:#fff;color:var(--ink);box-shadow:0 20px 100px #20351033}
dialog::backdrop{background:#202a2166;backdrop-filter:blur(5px)}
dialog h2{font-size:23px;font-weight:550;letter-spacing:-.6px;margin:0 0 24px;line-height:1.4}
.dialog-close{position:absolute;right:10px;top:10px}
.login-dialog{width:390px;padding:36px}
.login-brand{font:48px Georgia,serif;letter-spacing:-4px;margin-bottom:29px}
.eyebrow{font-size:9px;letter-spacing:2px;color:#8f9e83;margin-bottom:10px}
.login-dialog h2{font-size:25px;margin:0 0 29px}
.login-dialog label{display:block;font-size:11px;color:#748967;margin:0 0 9px}
.login-dialog input{width:100%;border:1px solid #d9e3d0;background:#fafcf8;border-radius:5px;padding:12px;font-size:13px}
.login-dialog input:focus{border-color:#91a87d;box-shadow:0 0 0 3px #8eaa7412}
.login-dialog .generate-button{width:100%;justify-content:space-between;margin-top:13px;padding:13px}
.login-private{display:flex;justify-content:center;align-items:center;gap:6px;font-size:10px;color:#99aa8b;margin-top:24px}
.login-private>.icon{width:12px;height:12px}
.info-dialog>p{font-size:12px;color:#7c8e6d;line-height:1.8}
.budget-explanation{background:#f3f7ee;border:1px solid #e3ebd9;border-radius:6px;padding:17px;margin:20px 0}
.budget-explanation h3{font-size:12px;margin:0;color:#6d845a}
.budget-explanation p{font-size:11px;line-height:1.8;color:#899b77}
.budget-explanation p:last-child{margin-bottom:0}
.info-dialog>.privacy-note{font-size:10px;color:#93a580}
.info-dialog>.model-note{font-size:9px;color:#a0b08c;margin-bottom:0}
.image-dialog{padding:35px 15px 15px;max-width:90vw;text-align:center}
.image-dialog>img{display:block;max-width:100%;max-height:75dvh;margin:0 auto 15px;border-radius:5px}
.toast{position:fixed;bottom:24px;left:50%;transform:translateX(-50%);z-index:40;max-width:calc(100vw - 30px);border-radius:6px;background:#273b21;color:#fff;padding:13px 20px;box-shadow:0 5px 20px #19330e20;font-size:11px;line-height:1.6}
.sidebar-scrim{position:fixed;inset:0;background:#15240d55;z-index:25}
@keyframes shimmer{to{background-position:-220% 0}}
@media(min-width:1600px){.creative-space{padding-top:50px}.editor-heading{margin-bottom:30px}.dropzone{height:50vh;max-height:600px}}
@media(max-width:1100px){.sidebar{width:200px;padding-left:14px;padding-right:14px}.brand{gap:8px}.brand-name{font-size:12px}.brand-name>span{font-size:6px;letter-spacing:1.1px}.creative-space,.gallery-view{padding:30px}.topbar{padding:0 30px}.reference-item>span{font-size:9px}.reference-item img{width:45px}.reference-item{gap:5px}.gallery-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.sidebar{position:fixed;transform:translateX(-100%);transition:transform .2s;z-index:30;width:222px;min-height:0;overflow:auto}.sidebar.open{transform:translateX(0)}.mobile-menu{display:inline-flex}.topbar{height:58px;padding:0 18px}.breadcrumbs{gap:8px}.topbar-right{gap:10px}.private-badge{font-size:9px}.creative-space,.gallery-view{padding:26px 20px}.editor-heading{align-items:flex-start;margin-bottom:20px;gap:12px}h1{font-size:21px}.editor-heading p{font-size:10px;margin-top:6px}.size-control{margin-top:1px}.size-control>span{display:none}.size-control select{font-size:10px;padding:8px 20px 8px 8px}.setup-banner{padding:9px 20px;font-size:9px}.dropzone{height:40vh;min-height:300px}.composer{padding:14px 13px 12px}.composer textarea{font-size:12px}.composer-bottom{gap:6px}.generate-button{font-size:10px;gap:7px;padding:10px 12px}.attach-button{font-size:10px;gap:4px}.attach-button>.icon{width:14px;height:14px}#prompt-counter{display:none}.send-controls{gap:0}.composer-footer{font-size:8px}.reference-list{gap:7px}.reference-item{max-width:calc(33.333% - 5px);padding:4px;gap:4px;position:relative}.reference-item img{width:100%;height:62px}.reference-item>span{display:none}.reference-item .icon-button{position:absolute;top:5px;right:5px;width:21px;height:21px;background:#fffffff0}.gallery-grid{gap:12px}.gallery-card-body{padding:10px}.small-button{padding:7px 8px;font-size:9px}.message-user{font-size:11px}.toast{width:max-content}.info-dialog{padding:32px 24px}.info-dialog h2{font-size:21px}}
@media(max-width:380px){.creative-space,.gallery-view{padding:22px 14px}.editor-heading{flex-wrap:wrap;gap:13px}.editor-heading>div{flex:1;min-width:180px}.dropzone{min-height:260px;height:35vh}.upload-empty{padding:20px}.upload-empty>strong{font-size:14px}.generate-button{font-size:9px;padding:10px}.attach-button{font-size:9px}.composer-footer>span:last-child{display:none}.gallery-grid{grid-template-columns:1fr}.login-dialog{padding:30px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}}
