@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@400;500;600;700;800&display=swap');
:root{font-family:'DM Sans',sans-serif;color:#182735;background:#f3f5f6;font-synthesis:none;--ink:#152332;--muted:#64717d;--line:#dde3e7;--lime:#d3ef87}*{box-sizing:border-box}body{margin:0}button,input,select,textarea{font:inherit}button,a,input,select,textarea{touch-action:manipulation}button{cursor:pointer;background:white;border:1px solid var(--line);border-radius:8px;padding:11px 17px;font-weight:600;font-size:.875rem;color:var(--ink);transition:background .18s,transform .18s}button:hover{background:#eaf0f2}button:active{transform:translateY(1px)}:focus-visible{outline:3px solid #58841e;outline-offset:3px}.topbar{height:86px;background:white;border-bottom:1px solid var(--line);display:flex;align-items:center;justify-content:space-between;padding:0 4.5%}.brand{display:flex;align-items:center;gap:10px;font:800 1.55rem 'Manrope',sans-serif;text-decoration:none;color:var(--ink);letter-spacing:-1px}.brandmark{display:grid;place-items:center;width:37px;height:37px;border-radius:10px;background:var(--ink);color:var(--lime);font-size:30px;line-height:1}.studio{font:600 .625rem 'DM Sans',sans-serif;letter-spacing:2px;border-left:1px solid #c9d1d7;margin-left:7px;padding-left:17px;color:#6b7781}.project-actions{display:flex;gap:10px}.dark{background:var(--ink);color:white;border-color:var(--ink)}.dark:hover{background:#30465b}.dark span{margin-left:16px}main{max-width:1560px;margin:auto;padding:38px 4.5% 0}.heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:30px}.eyebrow{font-size:.68rem;font-weight:700;letter-spacing:1.6px;color:#667783;margin:0 0 10px}h1{font:600 clamp(1.8rem,3vw,2.5rem)/1.2 'Manrope',sans-serif;letter-spacing:-1.5px;margin:0 0 11px}.heading p:last-child{font-size:1rem;color:var(--muted);margin:0}.new{background:transparent}.workspace{display:grid;grid-template-columns:330px minmax(0,1fr);gap:26px;align-items:start}.controls{background:white;border:1px solid var(--line);border-radius:14px;overflow:hidden}.panel-title{display:flex;justify-content:space-between;align-items:center;padding:22px 23px 20px;font-weight:700}.step{font-size:.75rem;color:#7c8993;letter-spacing:1px}.mode{display:flex;border:0;background:#eef2f4;margin:0 22px 22px;padding:4px;border-radius:8px}.mode label{flex:1;position:relative;text-align:center;cursor:pointer}.mode input{position:absolute;opacity:0}.mode span{display:block;font-size:.875rem;font-weight:600;padding:11px 4px;border-radius:6px;color:#71808b}.mode input:checked+span{background:var(--ink);color:white;box-shadow:0 2px 4px #15233220}.mode input:focus-visible+span{outline:3px solid #58841e}.control-section{border-top:1px solid var(--line);padding:22px}h2{font-size:1rem;margin:0}.control-section h2{font-size:.9rem;margin-bottom:18px;display:flex;gap:12px;align-items:center}.control-section h2>span{font-size:.75rem;font-weight:700;display:grid;place-items:center;width:24px;height:24px;border:1px solid var(--line);border-radius:50%;color:#788692}.dropzone{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;border:1px dashed #b9c5ce;border-radius:9px;background:#f8fafb;padding:22px 8px;text-align:center;cursor:pointer}.dropzone:hover,.dropzone.drag{background:#edf4e5;border-color:#748f43}.dropzone input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}.dropzone:focus-within{outline:3px solid #58841e}.dropzone strong{font-size:.875rem}.dropzone>span:not(.upload-icon){font-size:.875rem;color:var(--muted)}.dropzone small{font-size:.75rem;color:#788592}.upload-icon{display:grid;place-items:center;width:34px;height:34px;border:1px solid var(--line);border-radius:8px;background:white;font-size:24px;margin-bottom:4px}.text-button{border:0;padding:7px 0;background:transparent;font-size:.875rem;text-decoration:none}.text-button:hover{background:transparent;color:#527226;text-decoration:underline}.photo-tools{display:flex;justify-content:space-between;margin-top:9px}.field-label{display:block;font-size:.875rem;font-weight:500;margin:16px 0 8px}select,textarea{width:100%;border:1px solid #cfd8df;background:white;color:var(--ink);padding:11px 12px;border-radius:7px;font-size:.875rem}select{min-height:43px}textarea{resize:vertical;min-height:82px;line-height:1.5}.optional{float:right;color:#81909b;font-weight:400;font-size:.75rem}.primary{display:flex;justify-content:space-between;width:100%;padding:14px 16px;background:var(--lime);border-color:var(--lime);margin-top:17px}.primary:hover{background:#c1e16f}.control-hint{text-align:center;font-size:.75rem;color:var(--muted);margin:12px 0 0}.canvas-panel{min-width:0;background:white;border:1px solid var(--line);border-radius:14px;overflow:hidden}.canvas-toolbar{display:flex;justify-content:space-between;gap:15px;align-items:center;padding:20px 25px}.project-name{min-width:0;display:flex;flex-direction:column;gap:5px}.project-name input{border:0;background:transparent;width:min(300px,100%);font:700 1rem 'Manrope',sans-serif;color:var(--ink);padding:0}.project-name span{font-size:.75rem;color:#7b8995}.preview{position:relative;background:#e8edef;min-height:425px;aspect-ratio:1.65;overflow:hidden;display:grid;place-items:center;margin:0 16px;border-radius:9px}.preview>img{width:100%;height:100%;position:absolute;object-fit:contain;background:#dfe5e7}.empty-state{text-align:center;padding:40px 20px}.empty-icon{width:70px;height:70px;background:white;border:1px solid #dce2e5;border-radius:20px;display:grid;place-items:center;font-size:45px;margin:0 auto 26px;color:#344856;box-shadow:0 10px 25px #15233208}.empty-state h2{font:600 1.8rem 'Manrope',sans-serif;letter-spacing:-.7px}.empty-state p:not(.eyebrow){color:var(--muted);line-height:1.6;font-size:.9rem;margin:14px 0 22px}.empty-state button{background:var(--ink);color:white;border-color:var(--ink)}.preview-label{position:absolute;left:18px;top:18px;padding:8px 10px;border-radius:5px;background:#152332d9;color:white;font-size:.75rem;letter-spacing:1.3px}.expand{position:absolute;bottom:16px;right:16px;background:white;padding:5px 11px;font-size:23px}.board-summary{padding:27px 28px 0}.board-head{display:flex;justify-content:space-between;align-items:center;gap:15px}.board-head .eyebrow{font-size:.75rem;margin-bottom:9px}.board-head h2{font:600 1.45rem 'Manrope',sans-serif;letter-spacing:-.5px}.board-badge{background:#eff3e9;color:#526630;font-size:.75rem;padding:7px 10px;border-radius:20px;white-space:nowrap}.specs{display:grid;grid-template-columns:repeat(3,1fr);gap:18px;margin:28px 0}.specs div{border-left:1px solid var(--line);padding-left:18px}.specs div:first-child{border:0;padding-left:0}.specs span{display:block;font-size:.75rem;letter-spacing:1.3px;color:#71818d;margin-bottom:8px}.specs strong{font-size:.875rem;font-weight:500}.board-footer{border-top:1px solid var(--line);padding:15px 0;display:flex;justify-content:space-between;align-items:center;gap:16px}.board-footer p{font-size:.75rem;color:#77848e;max-width:360px;line-height:1.5;margin:0}.board-footer button{white-space:nowrap}.privacy-note{display:flex;align-items:center;gap:9px;padding:16px 28px;background:#f8fafb;color:#7c8890;font-size:.75rem;border-top:1px solid var(--line)}footer{padding:30px 0;display:flex;justify-content:space-between;align-items:center;color:#82909a;font-size:.75rem}footer>span:first-child{font-weight:700;font-size:.9rem;color:#53636f}footer>span:last-child{font-size:.75rem;letter-spacing:1.2px}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}[hidden]{display:none!important}#summaryNotes{font-size:.9rem;line-height:1.6;white-space:pre-wrap;overflow-wrap:anywhere;color:#52616d}#toast{position:fixed;bottom:24px;left:50%;transform:translateX(-50%);background:var(--ink);color:white;border:1px solid #647482;border-radius:9px;padding:15px 22px;z-index:20;box-shadow:0 8px 35px #0003;max-width:calc(100% - 30px);font-size:.9rem}dialog{border:1px solid var(--line);border-radius:14px;padding:28px;max-width:460px;width:calc(100% - 32px);color:var(--ink)}dialog::backdrop{background:#10233299;backdrop-filter:blur(3px)}dialog p{line-height:1.6;color:var(--muted)}.dialog-actions{display:flex;justify-content:flex-end;gap:10px}#imageDialog{max-width:95vw;width:auto;background:#142331;padding:12px}#largeImage{display:block;max-width:88vw;max-height:85vh;object-fit:contain}#closeImage{position:absolute;right:20px;top:20px}
@media(min-width:1450px){.preview{min-height:535px}}@media(max-width:1000px){.workspace{grid-template-columns:290px minmax(0,1fr);gap:18px}.control-section{padding:19px}.panel-title{padding:20px}.preview{min-height:380px}.specs{gap:10px}.specs div{padding-left:10px}.board-summary{padding:24px 20px 0}.board-head{align-items:flex-start}.board-badge{display:none}.canvas-toolbar{padding:20px}.board-footer{align-items:flex-start;flex-direction:column;gap:5px}}@media(max-width:720px){.topbar{height:auto;min-height:74px;padding:16px 20px;gap:14px;flex-wrap:wrap}.brand{font-size:1.3rem}.studio{display:none}.project-actions{gap:7px}.project-actions button{padding:10px;font-size:.875rem}.dark span{margin-left:5px}main{padding:28px 18px 0}.heading{align-items:flex-start;gap:14px;margin-bottom:24px}.heading .eyebrow{font-size:.75rem;letter-spacing:1.1px}h1{font-size:1.85rem;letter-spacing:-1px}.heading p:last-child{font-size:.875rem;line-height:1.5}.new{padding:9px;font-size:.875rem;white-space:nowrap}.workspace{display:flex;flex-direction:column;gap:20px}.controls,.canvas-panel{width:100%}.mode{margin-bottom:18px}.control-section{padding:20px}.preview{aspect-ratio:1.1;min-height:300px;margin:0 12px}.canvas-toolbar{padding:18px}.project-name input{width:190px;max-width:100%}.canvas-toolbar button{font-size:.875rem}.empty-state h2{font-size:1.6rem}.empty-icon{margin-bottom:20px}.board-head h2{font-size:1.3rem}.specs{gap:10px;margin:24px 0}.specs strong{font-size:.875rem;line-height:1.5}.privacy-note{padding:15px 20px;line-height:1.5}footer p{display:none}footer{padding:24px 0}.board-footer{flex-direction:row;align-items:center}.board-footer p{max-width:220px}.control-hint{font-size:.75rem}}
.result-toolbar{display:flex;justify-content:space-between;gap:12px;align-items:center;padding:0 20px 16px;flex-wrap:wrap}.view-tabs{display:flex;background:#edf1f3;padding:4px;border-radius:8px;gap:3px}.view-tabs button{border:0;background:transparent;padding:9px 13px}.view-tabs button[aria-pressed=true]{background:var(--ink);color:white}button:disabled{opacity:.45;cursor:not-allowed;transform:none}.generation-status{margin:14px 0 0;padding:12px;border-radius:7px;background:#f1f5f8;font-size:.875rem;line-height:1.5;overflow-wrap:anywhere}.generation-status.error{background:#fff0ed;color:#9a3020}.generation-status.success{background:#eff6e5;color:#3d5d20}.quota-note{font-size:.75rem;color:#64717d;line-height:1.5;margin-bottom:0}.busy-overlay{position:absolute;inset:0;z-index:3;display:flex;flex-direction:column;align-items:center;justify-content:center;background:#152332e8;color:white;text-align:center;padding:20px}.busy-overlay p{font-size:.875rem;line-height:1.5}.spinner{width:36px;height:36px;border:3px solid #ffffff50;border-top-color:var(--lime);border-radius:50%;animation:spin 1s linear infinite;margin-bottom:20px}@keyframes spin{to{transform:rotate(360deg)}}.compare-view{position:absolute;inset:0;display:grid;grid-template-columns:1fr 1fr;gap:3px;background:#bac5cd}.compare-view figure{margin:0;position:relative;min-width:0;background:#e8edef;display:grid;place-items:center}.compare-view img{width:100%;height:100%;object-fit:contain;position:absolute}.compare-view figcaption{position:absolute;bottom:16px;background:#152332d9;color:white;border-radius:5px;padding:8px 12px;font-size:.875rem}.history-section{padding:22px 24px 0}.history-heading{display:flex;align-items:center;justify-content:space-between;gap:12px}.history-heading span{font-size:.75rem;color:var(--muted)}.history{display:flex;gap:10px;margin-top:12px}.history button{padding:5px;flex:1;max-width:180px;text-align:left;min-width:0}.history img{width:100%;height:80px;object-fit:cover;border-radius:5px}.history span{display:block;padding:5px;font-size:.75rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.history button[aria-pressed=true]{border:2px solid #6b8a31;background:#f0f7e5}.preview{min-height:360px}.control-hint{line-height:1.5}select,textarea{font-size:1rem}.eyebrow,.studio{font-size:.75rem}#generationStatus:empty{display:none}@media(max-width:720px){.compare-view{grid-template-columns:1fr;grid-template-rows:1fr 1fr}.preview.comparing{min-height:620px}.result-toolbar{padding:0 15px 15px}.view-tabs button{padding:10px;font-size:.875rem}.history-section{padding:18px}.heading{flex-wrap:wrap}.new{margin-left:auto}.preview{min-height:320px}.history-heading{align-items:flex-start}.history-heading span{max-width:130px;text-align:right}.project-name input{font-size:1rem}.privacy-note{font-size:.8rem}}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important;transition:none!important}.spinner{animation:none}}

.product-editor{margin:24px;padding:22px;background:#f6f9f0;border:1px solid #dae5c6;border-radius:12px}.editor-heading{display:flex;justify-content:space-between;gap:16px;align-items:center}.product-editor p,.product-editor small{font-size:.875rem;line-height:1.5;color:#52616d}.product-fields{display:grid;grid-template-columns:1fr 1fr;gap:20px}.product-fields small{display:block}#regionSize{width:100%;min-height:40px;accent-color:#527226}.product-options{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:20px 0}.product-options button{min-height:72px;text-align:left;line-height:1.5}.product-options button[aria-pressed=true],#toggleProducts[aria-pressed=true]{background:#152332;color:white;border-color:#152332}.select-product{cursor:crosshair}#productRegion{position:absolute;border:3px solid #d3ef87;box-shadow:0 0 0 1px #152332;pointer-events:none;z-index:1}#productRegion span{position:absolute;left:0;top:0;font-size:11px;padding:3px 5px;background:#152332;color:white;max-width:100%}.preview-label{pointer-events:none}#previewImage:focus-visible{outline-offset:-4px}.product-editor .control-hint{text-align:left}@media(max-width:720px){.product-editor{margin:18px 12px;padding:16px}.editor-heading{align-items:flex-start;flex-direction:column}.product-fields{grid-template-columns:1fr;gap:0}.product-options{grid-template-columns:1fr}.product-options button{min-height:48px}}

.preview-status{margin:0 16px 16px}.product-editor{scroll-margin-top:18px}#largeImage:focus-visible{outline:3px solid var(--lime)}

/* Keep the complete application name readable on small phones. */
@media(max-width:720px){.topbar{height:auto;min-height:86px;flex-wrap:wrap;gap:14px;padding-top:16px;padding-bottom:16px}.brand{font-size:1.3rem}.project-actions{margin-left:auto}}

.mode{margin-left:12px;margin-right:12px}.mode span{font-size:.78rem;padding:12px 3px}.building-features{border:0;padding:0;margin:20px 0 6px}.building-features legend{font-size:.875rem;font-weight:600;margin-bottom:10px}#buildingFeatures{display:grid;grid-template-columns:1fr;gap:9px}#buildingFeatures label{display:flex;align-items:center;gap:10px;font-size:.85rem;cursor:pointer}#buildingFeatures input{width:18px;height:18px;accent-color:#527226}#summaryConstruction{font-size:.875rem;line-height:1.7;color:var(--muted)}

/* A tall comparison must not enlarge an auto-width aspect-ratio grid. */
.preview{min-width:0;width:calc(100% - 32px)}.preview.comparing{aspect-ratio:auto}@media(max-width:720px){.preview{width:calc(100% - 24px)}}
/* Original, locally hosted architectural illustrations: no image service calls. */
body{background:#dbe4dc;isolation:isolate}.architecture-background{position:fixed;inset:0;z-index:-1;overflow:hidden;pointer-events:none;background:#a8b9ac}.architecture-scene{position:absolute;inset:-2%;opacity:0;transition:opacity .9s ease;background-size:cover;background-position:center 30%;animation:architecture-drift 18s ease-in-out infinite alternate;will-change:opacity}.architecture-scene.active{opacity:1}.architecture-scene[data-scene="0"]{background-image:url('scenes/modern.svg')}.architecture-scene[data-scene="1"]{background-image:url('scenes/heritage.svg')}.architecture-scene[data-scene="2"]{background-image:url('scenes/tropical.svg')}.architecture-wash{position:absolute;inset:0;background:linear-gradient(90deg,rgba(240,245,234,.86),rgba(230,240,225,.32) 55%,rgba(233,239,224,.12)),linear-gradient(0deg,rgba(221,231,222,.85),transparent 75%)}.topbar{background:rgba(255,255,255,.9);backdrop-filter:blur(14px)}.heading{min-height:230px;align-items:center;gap:20px}.heading>div{padding:22px 25px;background:rgba(250,253,245,.8);border:1px solid #ffffffb8;border-radius:18px;backdrop-filter:blur(12px);box-shadow:0 12px 45px #2645360c}.heading .new{background:#ffffffed}.scene-controls{display:flex;justify-content:space-between;gap:12px;align-items:center;margin:-8px 0 22px;padding:10px 16px;border:1px solid #ffffffb8;border-radius:12px;background:#f7faf0e8;color:#304a3b;font-size:.85rem}.scene-controls>span{display:flex;gap:9px;align-items:center;flex-wrap:wrap}.scene-controls button{font-size:.75rem;padding:8px 12px;white-space:nowrap;background:#fff9}.scene-dot{width:7px;height:7px;border-radius:50%;background:#6a8c42}.scene-caption{color:#657765;font-size:.75rem}.controls,.canvas-panel{box-shadow:0 18px 55px #1d39261a}footer{background:#f7faf0e8;border-radius:12px 12px 0 0;padding:20px!important}.ambience-paused .architecture-scene{animation-play-state:paused}@keyframes architecture-drift{from{transform:scale(1) translateX(0)}to{transform:scale(1.045) translateX(-.5%)}}@media(max-width:720px){.architecture-scene{background-position:65% center}.heading{min-height:230px;align-content:flex-end;gap:12px;margin-bottom:24px}.heading>div{padding:18px}.heading h1{font-size:1.85rem}.scene-controls{align-items:flex-start;padding:10px 12px}.scene-caption{display:none}.scene-controls>span{gap:6px}.scene-controls button{padding:8px}.architecture-wash{background:linear-gradient(180deg,#edf3e430,#edf3e4a8 45%,#edf3e4d9)}main{padding-top:24px}}@media(prefers-reduced-motion:reduce){.architecture-scene{animation:none;transition:none}}
