/* V163 visual alignment. Application layout stays fluid; only the web shell draws a device. */
:root{--app-ink:#181818;--app-muted:#8d8d8d;--app-line:#eeeeeb;--app-gutter:18px}
body{color:var(--app-ink);font-family:Arial,"Microsoft YaHei",sans-serif;-webkit-font-smoothing:antialiased}
button,input,textarea{font-family:inherit}button{touch-action:manipulation}.primary{border-radius:12px!important;font-weight:500!important;min-height:46px;line-height:1.45}.secondary{border-radius:12px!important;min-height:44px}.eyebrow{font-size:9px;letter-spacing:1.8px;color:#8d8d8d;line-height:1.6}
.screen{padding-inline:var(--app-gutter)}.screen h1{letter-spacing:-.6px}.screen h2{letter-spacing:-.35px}.topbar{background:#fff;min-height:60px;border-bottom:1px solid #f0f0ee}.nav{border-top:1px solid #efefed;box-shadow:none}.nav button{font-size:10px;gap:5px}.nav svg{width:22px;height:22px}
body[data-page=intro] .screen{padding-bottom:20px;display:flex;flex-direction:column}body[data-page=intro] .intro-top{flex:none;border:0;min-height:52px}.intro-top .brand{font-size:21px;letter-spacing:-.7px}.intro-top .text-btn{font-size:12px;color:#888}.intro-flow{display:flex;flex-direction:column;flex:1;min-height:0}.intro-visual{height:auto;flex:1;min-height:150px;max-height:43vh;border-radius:18px;overflow:hidden}.intro-visual img{width:100%;height:100%;object-fit:cover}.intro-copy{padding:20px 2px 0}.intro-copy h1{font-size:28px;line-height:1.3;max-width:100%;letter-spacing:-.6px}.intro-copy p{font-size:13px;line-height:1.7;color:#888;margin:12px 0 20px}.intro-progress{margin-bottom:16px}.intro-copy .text-btn{margin-top:8px;font-size:12px}
.register-page{padding:0 20px 24px;max-width:500px;height:100dvh;overflow-y:auto}.register-page header{position:sticky;top:0;background:#fff;z-index:5;height:60px;gap:12px}.register-page header span{font-size:15px;font-weight:600;letter-spacing:0}.register-page section{padding-top:28px}.register-page h1{font-size:28px;line-height:1.25;letter-spacing:-.65px;margin:10px 0}.register-page .intro{font-size:13px;line-height:1.65;color:#888;margin-bottom:24px}#create-account label{font-size:12px;margin-bottom:16px}#create-account input{min-height:46px;padding:12px 14px;border-radius:12px;background:#fafafa;font-size:15px}#register-submit{border-radius:12px;min-height:48px;background:#181818;font-size:14px;font-weight:500}.register-page .browse-link{display:block;text-align:center;margin:18px 0 0;font-size:12px;color:#888;text-decoration:none}.register-page .login-link{font-size:12px;margin-top:16px;text-decoration:none}
.composition-header{position:sticky;top:0;z-index:25;background:#fff;border-bottom:1px solid #f0f0ee;height:60px;min-height:60px}.composition-header strong{font-size:14px;font-weight:500;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.composition-hero{border-radius:16px}.inspiration-copy{padding:0 0 18px}.inspiration-copy h1{font-size:25px;line-height:1.25;letter-spacing:-.5px;margin:8px 0 12px}.inspiration-copy p{font-size:13px;line-height:1.75;color:#888;margin:0}.composition-editor>.section-label{display:flex;align-items:center;justify-content:space-between;margin:0 0 14px}.composition-editor>.section-label h2{font-size:17px;margin:0}.furniture-count{font-size:11px;color:#888;background:#f5f5f3;border-radius:20px;padding:4px 9px}.composition-item{border:0;border-radius:12px;padding:0 0 10px;box-shadow:none}.composition-item img{padding:12px;background:#f7f7f5;border-radius:12px}.composition-item>span:not(.missing-picture){font-size:11px;line-height:1.5;margin:8px 2px 0}.composition-item small{top:8px;right:8px;font-size:9px}.composition-copy-footer{padding-top:12px;background:#fffffff7;border-top:1px solid #f0f0ee}.composition-copy-footer .composition-hint{font-size:10px;line-height:1.6;color:#999;max-width:330px}.composition-copy-footer .primary{width:100%;max-width:none}.composition-footer button{font-size:13px}.model-header,.product-header,.generation-header{border-bottom:1px solid #f0f0ee}.model-info,.model-preview-card,.generation-upload-card{border-radius:16px}.quality-cards button{border-radius:12px}.inline-plan{border:1px solid #eee;border-radius:14px;box-shadow:none}.inline-plan button{border-radius:10px}.creation-card,.project-card{box-shadow:none}.library-tabs button,.creation-tabs button{font-size:11px}.member-profile .profile-credit-card{border-radius:16px}.screen input,.screen textarea{border-radius:12px}.screen dialog button{line-height:1.4}
@media(max-width:600px){.composition-layout{display:flex;flex-direction:column;gap:20px;padding-top:16px}.composition-preview,.composition-editor{width:100%;min-width:0}.composition-furniture{grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.composition-hero{aspect-ratio:1.12;object-fit:cover}.inspiration-copy h1{font-size:24px}.register-page section{padding-top:24px}.creation-tabs button{padding-inline:3px;white-space:nowrap}}
@media(max-height:700px){.intro-visual{min-height:110px;max-height:32vh}.intro-copy{padding-top:14px}.intro-copy h1{font-size:24px}.intro-copy p{margin:8px 0 14px}.intro-progress{margin-bottom:12px}}

.screen{scrollbar-width:none}.screen::-webkit-scrollbar{display:none}

.intro-ambient{height:100%;min-height:180px;background:linear-gradient(145deg,#e9e6dd,#f7f5f0 50%,#d6d9ce)}
.intro-copy{display:flex;flex-direction:column;flex:1;min-height:0}.intro-copy .primary{margin-top:auto;flex:none}.intro-copy .text-btn{flex:none}
html,body,#composition,#model-detail,.register-page{scrollbar-width:none}::-webkit-scrollbar{width:0;height:0}

.library-empty-card{grid-column:1/-1;display:flex;min-height:174px;align-items:center;justify-content:center;flex-direction:column;gap:16px;padding:26px 20px;border:1px solid #eaeae7;border-radius:16px;background:#fafaf9;text-align:center;color:#92948d}.library-empty-card svg{width:42px;height:42px;color:#b7bab0}.library-empty-card p{margin:0;font-size:13px;line-height:1.6}.library-discover{margin-top:30px}.library-discover>h2{font-size:20px;font-weight:600;margin:0 0 20px;letter-spacing:-.4px}.library-discover .look-list{gap:26px}.library-discover .card-media{border-radius:16px}

/* Live designer: V163 composition, with real chat and optional room shortcuts. */
.similar-designs{margin:28px 0 16px;padding-top:24px;border-top:1px solid #efefed}.similar-designs h2{font-size:18px;line-height:1.4;margin:0 0 16px;letter-spacing:-.3px}.similar-design-list{display:grid;grid-auto-flow:column;grid-auto-columns:72%;gap:14px;overflow-x:auto;scroll-snap-type:x proximity;padding-bottom:6px}.similar-design-card{display:block;min-width:0;text-decoration:none;color:#181818;scroll-snap-align:start}.similar-design-cover{display:block;width:100%;aspect-ratio:1.25;object-fit:cover;border-radius:14px;background:#f5f5f3}.similar-design-card strong{display:block;font-size:13px;line-height:1.5;font-weight:600;margin:10px 2px 0;overflow-wrap:anywhere}.similar-design-card:focus-visible{outline:2px solid #8c977d;outline-offset:3px;border-radius:14px}@media(min-width:700px){.similar-design-list{grid-auto-columns:calc((100% - 28px)/3)}}
body[data-page=designer] .screen{padding-left:16px;padding-right:16px}
body[data-page=designer] .live-chat-heading{min-height:60px;padding:8px 0;border-bottom:0;gap:12px}
body[data-page=designer] .live-chat-heading strong{font-size:28px;font-weight:700;line-height:1.25;letter-spacing:-.7px}
body[data-page=designer] .chat-header-actions{gap:7px}
body[data-page=designer] .chat-header-actions button{width:34px;height:34px;border:1px solid #e8e8e6;background:#fff;color:#777;font-size:24px;font-weight:400}
body[data-page=designer] .chat-page-subtitle{flex:none;font-size:13px;line-height:1.6;color:#999;margin:4px 0 0;padding-bottom:24px;border-bottom:1px solid #eee}
body[data-page=designer] .chat-stream{padding:16px 0;scroll-behavior:auto}
body[data-page=designer] .chat-greeting{height:auto;min-height:0;display:block;text-align:left;padding:0}
.chat-intro-turn{display:flex;align-items:flex-start;gap:9px;margin-bottom:22px}
.chat-designer-mark{display:grid;place-items:center;width:24px;height:24px;flex:none;border-radius:6px;background-color:#f3f3f2;color:#858980;font-size:20px;line-height:1}
.chat-intro-turn>div{min-width:0;flex:1}.chat-intro-turn small{display:block;font-size:11px;line-height:1.5;color:#999;margin-bottom:7px}
.chat-intro-turn p{display:inline-block;margin:0;border-radius:0 14px 14px 14px;background:#f1f1f1;padding:12px;font-size:13px;line-height:1.6;color:#252525}
.chat-space-label{font-size:11px;line-height:1.5;color:#999;margin:0 0 12px}
body[data-page=designer] .chat-space-starters{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:0}
body[data-page=designer] .chat-space-starters button{display:flex;align-items:center;justify-content:flex-start;gap:15px;min-height:68px;padding:14px 16px;border:1px solid #e8e8e8;border-radius:13px;background:#fff;font-size:14px;font-weight:600;line-height:1.4;text-align:left;color:#242424;box-shadow:none}
.chat-space-starters svg{width:24px;height:24px;flex:none;color:#777}.chat-space-starters button:active{background:#f5f5f3}.chat-space-starters button:focus-visible{outline:2px solid #8c977d;outline-offset:2px}
body[data-page=designer] .chat-dock{border:0;padding:10px 0 max(10px,env(safe-area-inset-bottom))}
body[data-page=designer] .composer-hint{font-size:10px;margin-bottom:8px;color:#aaa}
body[data-page=designer] .live-composer{min-height:46px;padding:7px 9px;gap:6px;border:1px solid #e6e6e4;border-radius:26px;box-shadow:0 3px 16px #00000006}
body[data-page=designer] .live-composer textarea{font-size:13px;line-height:20px;min-height:28px;padding:4px 0}
body[data-page=designer] .chat-upload{width:28px;height:28px;font-size:23px}
body[data-page=designer] .chat-send{width:28px;height:28px;font-size:21px;background:#74776f}
body[data-page=designer] .live-message.assistant{position:relative;padding-left:33px}
body[data-page=designer] .live-message.assistant::before{content:'';background-image:url(./ui-designer.svg);background-repeat:no-repeat;background-position:center;background-size:20px 20px;position:absolute;left:0;top:0;display:grid;place-items:center;width:24px;height:24px;background-color:#f3f3f2;color:#858980;border-radius:6px;font-size:20px}
body[data-page=designer] .live-message.assistant>p{display:table;padding:12px;border-radius:0 14px 14px 14px;background:#f1f1f1;font-size:13px;line-height:1.6}
@media(min-width:700px){body[data-page=designer] .live-chat{width:100%;max-width:760px;margin-inline:auto}}
@media(max-height:650px){body[data-page=designer] .chat-space-starters button{min-height:54px;padding-block:10px}.chat-intro-turn{margin-bottom:14px}body[data-page=designer] .chat-page-subtitle{padding-bottom:14px}}

/* Keep navigation visible while the page content scrolls. */
.screen>.topbar,body[data-page=home] .screen>.topbar{position:sticky;top:0;z-index:45;background:#fff;isolation:isolate}
body[data-page=home] .home-tools{top:var(--page-header-height,62px);z-index:35}
.screen{scroll-padding-top:72px}
#model-detail>.product-header,#generation .creation-header,main>.model-header{position:sticky;top:0;z-index:45;background:#fff;margin-top:0;padding-block:8px}
.weekly-challenge>header{position:sticky;top:0;z-index:45;background:#fff;height:62px;box-sizing:border-box}
.weekly-challenge .wc-tabs{top:62px}

/* Independent weekly challenge identity; never use the first catalogue image. */
.challenge-editorial{background:#e9e8db;align-items:center}.challenge-editorial>i{font:normal 76px Georgia;color:#738267;padding-right:22px;opacity:.7}.wc-editorial-hero{background:linear-gradient(135deg,#e7e2d0,#b3bea2);height:260px}.wc-editorial-hero:after{display:none}.wc-editorial-hero>div{color:#253323;right:55px}.wc-editorial-hero small,.wc-editorial-hero p{color:#4d5d43}.wc-editorial-hero>span{position:absolute;right:18px;top:12px;font-size:120px;color:#fff5}.wc-theme-copy>small{letter-spacing:1px}.wc-brief-grid{display:grid;gap:12px;margin:22px 0}.wc-brief-grid article{padding:16px;border:1px solid #e7e9e0;border-radius:14px;background:#fafbf8}.wc-brief-grid b{color:#8b987b;font-size:12px;margin-right:12px}.wc-brief-grid strong{font-size:14px}.wc-brief-grid p{margin:8px 0 0}.wc-tabs{scroll-margin-top:62px}.wc-rules section{scroll-margin-top:124px}

.creator-link{display:flex;align-items:center;gap:9px;text-decoration:none;color:inherit;font-size:13px;margin:12px 0}.creator-avatar{display:grid;place-items:center;width:32px;height:32px;flex:none;border-radius:50%;background:#ecefe5;color:#425339;overflow:hidden}.creator-avatar img{width:100%;height:100%;object-fit:cover}.image-author.creator-link{margin:0}.inspiration-copy>.creator-link{margin-bottom:18px}#creator-page{max-width:720px;margin:auto;padding:0 16px 32px;font:14px/1.6 Arial,sans-serif}.creator-header{position:sticky;top:0;z-index:40;display:flex;align-items:center;justify-content:space-between;height:60px;background:white;border-bottom:1px solid #eee}.creator-header a{font-size:30px;text-decoration:none;color:inherit}.creator-identity{padding:24px 0}.creator-identity .creator-avatar{width:64px;height:64px;font-size:24px}.creator-identity .creator-link{font-size:22px;font-weight:600}.creator-design{display:block;margin:0 0 24px;color:inherit;text-decoration:none}.creator-design img{width:100%;aspect-ratio:1.25;object-fit:cover;border-radius:16px}.creator-design h2{font-size:17px;margin:10px 0 6px}.creator-design p{font-size:13px;color:#888}#creator-edit{padding:24px 0;display:grid;gap:18px}#creator-edit label{display:grid;gap:8px}#creator-edit input,#creator-edit textarea{box-sizing:border-box;max-width:100%;width:100%;padding:12px;border:1px solid #ddd;border-radius:12px;font:inherit;font-size:16px}#creator-edit button{border:0;border-radius:24px;padding:14px;background:#20251d;color:white}#creator-edit p{color:#888;font-size:12px}

/* Curated weekly theme: stable photo and comfortable portrait spacing. */
.challenge-entry.challenge-editorial{display:grid;grid-template-columns:minmax(0,1fr) 42%;gap:0;min-height:172px;margin:8px 0 24px;background:#eeede5;align-items:stretch}
.challenge-entry.challenge-editorial>span{padding:20px 14px 20px 18px;gap:9px}
.challenge-entry.challenge-editorial strong{font-size:21px;line-height:1.25}
.challenge-entry.challenge-editorial>img{width:100%;max-width:none;height:100%;min-height:172px;object-fit:cover;object-position:50% 55%;background:#deddd3;opacity:0;transition:opacity .2s}
.challenge-entry.challenge-editorial>img.cover-ready{opacity:1}
.wc-editorial-hero>img[data-challenge-cover]{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;opacity:0;transition:opacity .2s}
.wc-editorial-hero>img.cover-ready{opacity:1}
.wc-editorial-hero:after{display:block;position:absolute;inset:0;content:"";background:linear-gradient(0deg,rgba(0,0,0,.68),rgba(0,0,0,0) 85%);pointer-events:none}
.wc-editorial-hero>div{z-index:1;right:24px;color:white}
.wc-editorial-hero small,.wc-editorial-hero p{color:#fff}
@media(max-width:350px){.challenge-entry.challenge-editorial>span{padding:16px 12px}.challenge-entry.challenge-editorial strong{font-size:19px}}
@media(prefers-reduced-motion:reduce){[data-challenge-cover]{transition:none!important}}

/* Entry alignment measured against V159/V163: 16px gutter, 47px header,
   330px artwork and actions following copy rather than pushed to the bottom. */
:root{--app-gutter:16px;--ui-gutter:16px}
#app .screen{padding-inline:16px}
.screen>.topbar{height:47px;min-height:47px}
body[data-page=home] .home-tools{top:var(--page-header-height,47px)}
body[data-page=intro] .screen{display:block;overflow-y:auto;padding-bottom:28px}
body[data-page=intro] .intro-top{height:47px;min-height:47px}
.intro-top .brand{font-size:23px}
.intro-flow{display:block;min-height:0}
.intro-visual{display:block;height:330px;max-height:none;min-height:0;margin-top:8px;border-radius:16px}
.intro-copy{display:block;padding:22px 6px 14px}
.intro-copy h1{font-size:28px;line-height:1.15;max-width:320px;margin:0;letter-spacing:-.8px}
.intro-copy p{margin:12px 0 20px;font-size:13px;line-height:1.7}
.intro-progress{margin-bottom:20px}
.intro-copy .primary{margin-top:0;width:100%}
.intro-copy .text-btn{display:block;width:100%;margin-top:8px}
.register-page{padding:0 16px 28px;max-width:500px}
.register-page header{height:47px;min-height:47px}
.register-page section,.auth-entry{padding:24px 0 0}
.register-page h1,.auth-entry h1{font-size:26px;line-height:1.25;font-weight:650;letter-spacing:-.5px;margin:10px 0}
.register-page .intro,.auth-entry .signup-intro{font-size:13px;line-height:1.6;color:#737373;margin:0 0 24px}
#live-auth-form{display:flex;flex-direction:column;gap:0}
#live-auth-form label,#create-account label{display:block;font-size:12px;line-height:1.5;margin:0 0 18px}
#live-auth-form input,#create-account input{display:block;width:100%;box-sizing:border-box;margin:6px 0 0;padding:13px 12px;min-height:46px;border:1px solid #dedede;border-radius:12px;background:#fafafa;font-size:16px;line-height:1.3}
#live-auth-form .text-btn{font-size:12px;min-height:44px;margin:6px 0 0}
#live-auth-error:empty,#register-error:empty,.register-status:empty{display:none}
#live-auth-error,#register-error{margin:0 0 16px;font-size:12px;line-height:1.6;color:#a44832}
.guest-profile.identity-card{margin:24px 0;padding:24px 20px;gap:16px;border-radius:16px}
.guest-profile h2{font-size:20px;line-height:1.3}.guest-profile p{font-size:13px;line-height:1.6;color:#737373}.guest-profile .primary,.guest-profile .secondary{font-size:13px;min-height:46px}
@media(max-height:650px){.intro-visual{height:250px}.intro-copy{padding-top:18px}.intro-copy h1{font-size:26px}.intro-progress{margin-bottom:16px}}

/* One portrait layout rhythm across app-owned screens. Device status is owned
   by display-mode only, never repeated inside the application viewport. */
:root{--page-header-height:47px;--page-gutter:16px;--section-gap:24px}
#app .screen>.topbar{height:47px;min-height:47px;box-sizing:border-box;margin-top:0;padding-block:0}
#app .screen{scroll-padding-top:63px}
body[data-page=designer] .live-chat-heading{height:47px;min-height:47px;padding:0;box-sizing:border-box}
body[data-page=designer] .live-chat-heading strong{font-size:26px;line-height:1.25}
.creator-header,.register-page header{height:47px;min-height:47px;box-sizing:border-box}
.weekly-challenge>header{height:47px;min-height:47px;padding-block:0}
.weekly-challenge .wc-tabs{top:47px}.wc-tabs{scroll-margin-top:47px}.wc-rules section{scroll-margin-top:109px}
@media(max-width:600px){
 #composition,#model-detail,#generation,main:has(.creation-form){padding-left:16px;padding-right:16px;padding-top:0;box-sizing:border-box}
 #composition>.composition-header,#model-detail>.product-header,#model-detail>.model-header,#generation .creation-header{height:47px;min-height:47px;box-sizing:border-box;margin-top:0;padding-top:0;padding-bottom:0;align-items:center}
 #model-detail>.product-header,#model-detail>.model-header,#generation .creation-header{margin-bottom:16px}
 .composition-header strong,.product-header h1,#model-detail>.product-header h1,.creation-header.product-header h1{font-size:16px;line-height:1.3;min-width:0}
 .composition-header a,.product-header>a,.creation-header>a,.creator-header>a,.register-page header>a{display:inline-flex;align-items:center;justify-content:center;min-width:32px;min-height:44px;flex-shrink:0}
 .composition-layout{gap:24px;padding-top:16px}
 .composition-editor,.model-info,.creation-form{min-width:0}
 #creator-page{padding-inline:16px}.creator-identity{padding:24px 0}
 .weekly-challenge .wc-body{padding-inline:16px}
 .library-tabs button{min-width:0}.library-tabs{margin-inline:0}
}

/* Loading shapes keep the actual page grids and header/footer positioning. */
.sk-block,.quality-skeleton{background:#f3f3f0;border-radius:12px;min-width:0}.sk-line{height:14px;margin:12px 0;border-radius:6px}.sk-input{height:46px;border:1px solid #eee;width:100%}.quality-skeleton{height:100px;flex:1}.sk-block.composition-hero{width:100%;aspect-ratio:1.12}@media(min-width:721px){.sk-block.composition-hero{aspect-ratio:1.4}}

/* Standalone creator pages must not inherit the browser's 8px body margin. */
html,body{margin:0}#creator-page{box-sizing:border-box}


/* Model routes: override the older model-specific 64px header rules. */
body.model-page #model-detail{padding-inline:16px}
body.model-page #model-detail>.product-header{height:47px;min-height:47px;padding-block:0;margin:0;grid-template-columns:44px minmax(0,1fr) 44px;gap:8px}
body.model-page #model-detail>.product-header h1{font-size:16px;line-height:1.3;margin:0}
body.model-page .model-detail-layout{padding:16px 0 calc(24px + env(safe-area-inset-bottom));gap:24px;scroll-padding-top:16px}
body.model-page .model-info{padding:0;margin:0;border:0;border-radius:0;background:transparent}
body.model-page .model-info h2{font-size:20px;line-height:1.4;margin:0 0 8px}
body.model-page .model-info p{font-size:13px;line-height:1.6;margin:0 0 16px}
body.model-page .model-edit-page{padding:24px 0 calc(24px + env(safe-area-inset-bottom));scroll-padding-block:16px}
body.model-page .model-info form{gap:20px}
body.model-page .model-info label{gap:8px;font-size:13px}
body.model-page .model-info input,body.model-page .model-info .choice-trigger{min-height:46px;padding:12px;border-radius:12px;font-size:16px;width:100%;box-sizing:border-box}
body.model-page .model-info fieldset{min-width:0;margin:0;padding:0;gap:10px}
body.model-page .model-info legend{margin-bottom:12px}
body.model-page .model-info form p{margin:0}
#model-edit-error:empty{display:none}
body.model-page .detail-edit-actions{padding:4px 0 0}
body.model-page .detail-edit-actions button,body.model-page .detail-edit{min-height:46px;border-radius:12px}
/* Shared sheet gutters apply after component styles, including lazy-loaded pickers. */
dialog:modal{padding:12px 16px calc(24px + env(safe-area-inset-bottom))!important;scroll-padding-block:20px}
dialog:modal::before{margin-bottom:20px}
dialog:modal>header,dialog:modal>.drawer-head{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:40px;margin:0 0 20px;padding:0}
dialog:modal>h2,dialog:modal>header h2,dialog:modal>.drawer-head h2{font-size:20px;line-height:1.35;margin:0}
dialog:modal>h2{margin-bottom:20px}
dialog:modal>p{font-size:13px;line-height:1.6;margin:0 0 16px}
dialog:modal input:not([type=checkbox]):not([type=radio]),dialog:modal textarea,dialog:modal select{box-sizing:border-box;max-width:100%}
dialog:modal>.sheet-footer{padding:16px 0 0;margin-top:20px}
dialog:modal .choice-sheet-search{margin:0 0 16px}
dialog:modal .choice-sheet-groups{margin:0 0 16px;padding-bottom:4px}
dialog:modal .choice-sheet-options{gap:10px}
dialog:modal .language-options{gap:10px}
dialog:modal .language-options button{min-height:48px;padding:12px 16px;font-size:14px}
dialog:modal .public-furniture-image{margin:0 0 20px}

/* Furniture collection: quiet two-column cards shared with the loading layout. */
.composition-furniture{grid-template-columns:repeat(2,minmax(0,1fr));gap:16px 12px;align-items:start}
.composition-item{padding:0 0 14px;border:1px solid #eeeee8;border-radius:16px;background:#fff;overflow:hidden;cursor:pointer;transition:background .15s ease}
.composition-item img,.composition-item .missing-picture{display:block;box-sizing:border-box;width:100%;aspect-ratio:1;object-fit:contain;padding:0;border-radius:0;background:#f6f5f1}
.composition-item>span:not(.missing-picture){display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;white-space:normal;overflow:hidden;text-overflow:ellipsis;margin:12px 12px 0;font-size:13px;font-weight:500;line-height:1.5;min-height:39px;overflow-wrap:anywhere}
.composition-item small{top:10px;right:10px;padding:4px 7px;background:#fffffff0;border-radius:20px;font-size:10px}
.composition-item:active{background:#f0f1eb}
.composition-item .furniture-size{font-size:11px;font-weight:400}
.composition-editor>.section-label{margin-bottom:16px;gap:12px}
.furniture-count{padding:0;background:none;font-size:13px;color:#8a8d83;font-variant-numeric:tabular-nums}
.composition-item .furniture-card-placeholder{border-radius:0;background:#f6f5f1}
.composition-item>.sk-line{margin:12px 12px 0;min-height:39px}
@media(min-width:1000px){.composition-furniture{gap:18px 14px}}

/* Design metadata: shared mobile chips, compact filters and explicit state. */
.design-badges{display:flex;flex-wrap:wrap;gap:6px;margin:8px 0;font-size:11px;font-weight:400;line-height:1.5;color:#73776f}
.design-badges>span{padding:3px 8px;border-radius:20px;background:#f3f4f1}.design-badges>.is-published{background:#edf3e9;color:#4d6942}
.design-search-form{display:grid;gap:10px;margin:0 0 18px}.design-filter-row{display:flex;gap:8px}.design-filter-row>label{min-width:0;flex:1}.design-filter-row select,.design-filter-row .choice-trigger{width:100%;min-height:40px;border:1px solid #ecece8;border-radius:20px;background:#f7f7f5;padding:8px 12px;font-size:12px}
.design-space-choices{border:0;margin:0;padding:0;min-width:0}.design-space-choices legend{margin-bottom:10px;font-size:13px;color:#666}.design-space-choices>div{display:flex;flex-wrap:wrap;gap:8px}.design-space-choices label{position:relative;display:block!important;margin:0!important}.design-space-choices input{position:absolute;opacity:0;width:1px;height:1px}.design-space-choices span{display:block;padding:10px 14px;border-radius:22px;border:1px solid #e7e7e3;font-size:12px}.design-space-choices input:checked+span{background:#181a16;color:#fff;border-color:#181a16}.design-space-choices input:focus-visible+span{outline:2px solid #74876b;outline-offset:2px}

.choice-sheet [hidden]{display:none!important}

/* Keep submission on the existing form; feedback belongs to its action. */
#generation.is-submitting .generate-footer button[type=submit]{display:flex;align-items:center;justify-content:center;gap:10px;opacity:1;background:#30362c;color:#fff}
#generation.is-submitting .generate-footer button[type=submit]:before{content:'';width:15px;height:15px;flex:none;border:2px solid #ffffff40;border-top-color:#fff;border-radius:50%;animation:generation-spin .9s linear infinite}
.model-library-grid>.library-empty-card[hidden]{display:none!important}
.model-library-grid .pending-product.library-card{padding:0;border:1px solid #eeeee8;border-radius:16px;background:#fff;overflow:hidden;align-self:start}
.model-library-grid .pending-product .library-cover{aspect-ratio:1;height:auto;min-height:0;background:#f6f6f3;border-radius:0}
.model-library-grid .pending-product .library-card-copy{padding:12px 12px 0}
.model-library-grid .pending-product .model-task-status{padding:8px 12px 14px}
.model-library-grid .pending-product .library-card-copy strong{font-size:13px}
@media(prefers-reduced-motion:reduce){#generation.is-submitting .generate-footer button[type=submit]:before{animation:none}}

.model-library-grid .pending-product{position:relative}
.model-library-grid .pending-product .library-card-menu{position:absolute;top:10px;right:10px;transform:none;z-index:3}
.model-library-grid .pending-product .library-card-menu>div{min-width:120px;max-width:calc(100vw - 64px)}
.model-library-grid .pending-product .library-card-menu .danger{color:#a44839}
.model-library-grid .pending-product.is-failed .model-task-status{color:#9b6355}

/* Mobile authentication and touch targets: guest access is an action, not an error. */
.app-signin-prompt{display:flex;align-items:center;gap:12px;width:100%;min-height:56px;margin:0 0 10px;padding:10px 16px;border:1px solid #e5e7df;border-radius:16px;background:#f2f4ed;color:#283023;text-align:left;font:inherit;cursor:pointer;box-sizing:border-box}
.app-signin-icon{display:grid;place-items:center;flex:none;width:32px;height:32px;border-radius:50%;background:#fff}.app-signin-icon svg{width:22px;height:22px}.app-signin-copy{flex:1;font-size:15px;font-weight:600;line-height:1.5}.app-signin-chevron{font-size:26px;line-height:1}
.app-signin-action{display:flex;align-items:center;justify-content:center;gap:16px;min-height:48px;padding:12px 20px;box-sizing:border-box;border:0;border-radius:14px;background:#20251c;color:#fff!important;text-decoration:none!important;font:inherit;font-size:16px;font-weight:600}
.app-signin-prompt:active{background:#e7ebdf}.app-signin-action:active{background:#394330}.app-signin-prompt:focus-visible,.app-signin-action:focus-visible{outline:2px solid #77856b;outline-offset:3px}
body[data-page=designer] .chat-header-actions button,.chat-history-sheet header button{width:44px;height:44px;flex:none}
body[data-page=designer] .live-composer{min-height:56px;padding:5px 6px;gap:6px}
body[data-page=designer] .chat-upload,body[data-page=designer] .chat-send{width:44px;height:44px;min-width:44px;flex:none}
body[data-page=designer] .live-composer textarea{font-size:16px;line-height:22px;min-height:32px;padding:5px 0}
.chat-error button{min-height:44px;min-width:60px;padding:8px 12px;border-radius:10px;background:#fff;text-decoration:none;font-size:14px}
.chat-attachment button{min-width:44px;min-height:44px}.plan-actions button{min-height:44px;padding:10px 14px;font-size:14px}
.identity-card [data-act=signin],.identity-card [data-act=register-open]{min-height:48px;border-radius:14px;font-size:16px}
@media(pointer:coarse){input:not([type=checkbox]):not([type=radio]):not([type=file]),textarea{font-size:16px}}

.generation-list-hint{margin:-4px 0 16px;padding:10px 12px;border-radius:12px;background:#f5f6f2;color:#747c6b;font-size:13px;line-height:1.65;overflow-wrap:anywhere}

/* Ordering is informational until the API exposes a sort choice. */
.catalogue-order-note{font-size:12px;line-height:1.5;color:#888;white-space:nowrap;cursor:default;flex:none}

/* Choice sheets: one spacing system, without stacked flex gaps and margins. */
dialog.choice-sheet:modal[open]{height:auto;min-height:0;gap:12px;padding:10px 16px calc(16px + env(safe-area-inset-bottom))!important;justify-content:flex-start}
dialog.choice-sheet:modal::before{margin:2px auto 0;flex-shrink:0}
dialog.choice-sheet:modal>header{margin:0;padding:0;min-height:44px;flex-shrink:0}
dialog.choice-sheet:modal .choice-sheet-search{margin:0;padding:0}
dialog.choice-sheet:modal .choice-sheet-groups{margin:0;padding:0 0 2px}
dialog.choice-sheet:modal .choice-sheet-options{gap:8px;padding:0 0 2px;flex:0 1 auto}
dialog.choice-sheet:modal .choice-sheet-options button{min-height:46px;padding:10px 12px;line-height:1.4}
dialog.choice-sheet:modal .choice-sheet-close{width:44px;height:44px;min-height:44px}
dialog.choice-sheet:modal>.choice-sheet-empty{margin:0;padding:12px 0}

/* Semantic status colours and quiet type colours; text always remains visible. */
[data-choice-tone="published"]{--tag-bg:#e6f2e8;--tag-ink:#28603c;--tag-border:#a9cbb1}
[data-choice-tone="pending"]{--tag-bg:#fff2d9;--tag-ink:#865609;--tag-border:#e7c680}
[data-choice-tone="rejected"]{--tag-bg:#fbe9e7;--tag-ink:#9b3934;--tag-border:#e4aca8}
[data-choice-tone="unpublished"],[data-choice-tone="neutral"]{--tag-bg:#f0f1f3;--tag-ink:#57616c;--tag-border:#c6ccd2}
[data-choice-tone="type-0"]{--tag-bg:#eaf0fa;--tag-ink:#3f5e91;--tag-border:#afc1df}
[data-choice-tone="type-1"]{--tag-bg:#efeafa;--tag-ink:#68518f;--tag-border:#c2b1dd}
[data-choice-tone="type-2"]{--tag-bg:#e7f2ef;--tag-ink:#336e60;--tag-border:#a5cfc3}
[data-choice-tone="type-3"]{--tag-bg:#faece3;--tag-ink:#8b593b;--tag-border:#dfbba3}
[data-choice-tone="type-4"]{--tag-bg:#f5eaf0;--tag-ink:#8b4b6c;--tag-border:#d9b1c7}
[data-choice-tone="type-5"]{--tag-bg:#eef1e3;--tag-ink:#626d32;--tag-border:#c0c99b}
.design-badges>[data-choice-tone],.choice-trigger[data-choice-tone],dialog.choice-sheet .choice-sheet-options button[data-choice-tone]{background:var(--tag-bg);color:var(--tag-ink);border:1px solid var(--tag-border)}
dialog.choice-sheet .choice-sheet-options button[data-choice-tone][aria-pressed="true"]{background:var(--tag-bg);color:var(--tag-ink);border-color:var(--tag-ink);box-shadow:inset 0 0 0 1px var(--tag-ink);font-weight:650}

/* Room types have stable, distinct colours in every locale. */
[data-choice-tone="room-lavender"]{--tag-bg:#f1ebf8;--tag-ink:#705486;--tag-border:#cbb8dd}
[data-choice-tone="room-sand"]{--tag-bg:#f8efdf;--tag-ink:#87632f;--tag-border:#dec89f}
[data-choice-tone="room-mint"]{--tag-bg:#e5f3ef;--tag-ink:#326f62;--tag-border:#a4cfc2}
[data-choice-tone="room-rose"]{--tag-bg:#f9eaf0;--tag-ink:#984c70;--tag-border:#dfb0c5}
[data-choice-tone="room-blue"]{--tag-bg:#e7eff9;--tag-ink:#3d6090;--tag-border:#acc2df}
[data-choice-tone="room-violet"]{--tag-bg:#eae7fa;--tag-ink:#584a97;--tag-border:#b8afe1}
[data-choice-tone="room-olive"]{--tag-bg:#eef3df;--tag-ink:#64752e;--tag-border:#c1cf99}
[data-choice-tone="room-slate"]{--tag-bg:#eaf0f2;--tag-ink:#506b77;--tag-border:#b5c7ce}

.discovery-empty{padding:28px 20px!important;min-height:0!important;border:1px solid #eee;border-radius:18px;background:#fafaf8!important;text-align:center}.discovery-empty h3{font-size:17px;line-height:1.5;margin:0 0 8px}.discovery-empty p{font-size:13px;line-height:1.7;margin:0 auto 18px;max-width:280px;color:#777}.discovery-empty button{min-height:44px;color:#333!important;padding:10px 18px}

/* All root tabs share the same bottom navigation geometry. */
:root{--app-tabbar-height:calc(61px + env(safe-area-inset-bottom))}
body .nav,body[data-page=designer] .nav{height:var(--app-tabbar-height);min-height:var(--app-tabbar-height);bottom:0;padding:7px 7px calc(8px + env(safe-area-inset-bottom));box-sizing:border-box}
body[data-page=designer] .screen{height:calc(100% - var(--app-tabbar-height));bottom:var(--app-tabbar-height);padding-bottom:0}
@media(orientation:landscape) and (max-height:500px){:root{--app-tabbar-height:calc(48px + env(safe-area-inset-bottom))}body .nav,body[data-page=designer] .nav{padding:4px 12px calc(4px + env(safe-area-inset-bottom))}}

/* Generation feedback lives inside the fixed square preview. */
.model-library-grid .pending-product .model-progress-preview{position:relative;aspect-ratio:1;overflow:hidden}
.pending-product .model-progress-preview:before{display:none}
.model-progress-center{position:absolute;inset:12px;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:10px}
.model-progress-ring{position:relative;width:96px;height:96px;flex:none;color:#849275}
.pending-product .library-cover .model-ring-track{position:absolute;inset:0;width:100%;height:100%;fill:none;stroke-width:3;transform:rotate(-90deg)}
.ring-track{stroke:#e1e6da}.ring-value{stroke:#849275;stroke-linecap:round;transition:stroke-dashoffset .4s ease}
.model-ring-content{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px}
.pending-product .library-cover .model-ring-cube{width:30px;height:30px;stroke-width:1.4}
.model-ring-content b{font:600 14px/1.2 Arial,sans-serif;font-variant-numeric:tabular-nums}
.model-progress-label{font-size:12px;line-height:1.4;text-align:center;max-width:100%;color:#7c8275;overflow-wrap:anywhere}
.model-progress-ring.is-indeterminate .model-ring-track{animation:model-ring-spin 1.5s linear infinite}
.model-library-grid .pending-product .library-card-copy{padding:12px}
@keyframes model-ring-spin{to{transform:rotate(270deg)}}
@media(prefers-reduced-motion:reduce){.model-progress-ring.is-indeterminate .model-ring-track{animation:none}.ring-value{transition:none}}
.reduce-motion .model-progress-ring.is-indeterminate .model-ring-track{animation:none}

/* Initial loading is centered; background library refresh keeps its cards. */
.page-loading-state{min-height:220px;min-height:clamp(180px,38dvh,360px);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;width:100%;text-align:center;color:#93968b;font-size:13px}
.page-loading-state .load-spinner{display:block;width:24px;height:24px;border:2px solid #e5e8df;border-top-color:#859377;border-radius:50%;animation:generation-spin 1s linear infinite}
dialog>p[role=status]:first-child{min-height:150px;display:flex;align-items:center;justify-content:center;text-align:center;margin:0;color:#8b9184}
.model-preview-card{position:relative}.model-preview-card>#model-feedback{position:absolute;left:16px;right:16px;top:50%;transform:translateY(-50%);text-align:center;pointer-events:none}
@media(prefers-reduced-motion:reduce){.page-loading-state .load-spinner{animation:none}}

/* Back glyph and hover target share one fixed, centered box. */
:is(.product-header,.composition-header,.creation-header,.creator-header,.register-page header)>a:first-child{position:relative;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;width:44px;height:44px;min-width:44px;min-height:44px;flex:0 0 44px;padding:0;margin:0;border:0;border-radius:50%;font-size:0!important;line-height:1;text-decoration:none;color:inherit}
:is(.product-header,.composition-header,.creation-header,.creator-header,.register-page header)>a:first-child::before{content:'';position:absolute;left:50%;top:50%;width:20px;height:20px;margin:0;border:0;transform:translate(-50%,-50%);background:currentColor;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='m15 5-7 7 7 7' fill='none' stroke='black' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat}
:is(.product-header,.composition-header,.creation-header,.creator-header,.register-page header)>a:first-child:hover{background:#f3f3f0}

/* One centered loading state while detail data is prepared. */
[data-page-loading]{position:relative;min-height:60dvh}
.page-loading-overlay{position:fixed;inset:60px 0 70px;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:12px;z-index:2;color:#858c7c;font-size:13px;pointer-events:none;background:#ffffff80}
.page-loading-overlay .load-spinner{width:24px;height:24px;border:2px solid #e5e8df;border-top-color:#859377;border-radius:50%;animation:generation-spin 1s linear infinite}
.chat-history-sheet>p,.showcase-page>p[role=status]{min-height:160px;display:flex;align-items:center;justify-content:center;text-align:center}
@media(prefers-reduced-motion:reduce){.page-loading-overlay .load-spinner{animation:none}}
/* Detail pages use the same back/title row instead of mixed grid centering. */
#composition .composition-header,#model-detail .model-header,#generation .creation-header,#creator-page .creator-header,.register-page header{display:flex;align-items:center;justify-content:flex-start;gap:8px;height:var(--page-header-height,47px);min-height:var(--page-header-height,47px);padding-block:0;margin-top:0;box-sizing:border-box}
:is(.composition-header,.model-header,.creation-header,.creator-header)>:is(h1,strong),.register-page>header>span{flex:1;min-width:0;margin:0;padding:0;text-align:left;line-height:1.3;font-size:16px;letter-spacing:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.product-name-field{display:grid;gap:8px;font-size:13px;margin:0 0 16px}.product-name-field input{width:100%;box-sizing:border-box;min-height:42px;padding:10px 12px;border:1px solid #e5e5e5;border-radius:11px;font-size:14px}

/* Homepage title uses spacing without a divider. */
body[data-page=home] .topbar{border-bottom-color:transparent;box-shadow:none}

/* Model actions mirror the design page, with safe space below scroll content. */
body.model-page #model-detail{padding-bottom:100px}
.model-action-footer{position:fixed;z-index:35;bottom:0;left:0;right:0;display:grid;grid-template-columns:minmax(90px,1fr) minmax(140px,2fr);gap:12px;padding:12px 16px calc(16px + env(safe-area-inset-bottom));border-top:1px solid #eee;background:#fffffff5;backdrop-filter:blur(12px)}
.model-action-footer button{min-height:48px;border:1px solid #ddd;border-radius:24px;padding:10px 16px;font-size:14px;background:white;color:#222;white-space:nowrap}.model-action-footer .primary{background:#181818;color:white;border-color:#181818}.model-action-footer button:disabled{opacity:.45}
.model-publish-settings{margin-top:18px;font-size:13px;color:#777}.model-publish-settings summary{cursor:pointer;padding:10px 0}
.model-leave-sheet{box-sizing:border-box;width:100%;max-width:520px;margin:auto auto 0;border:0;border-radius:24px 24px 0 0;padding:24px 20px calc(24px + env(safe-area-inset-bottom))}.model-leave-sheet::backdrop{background:#0005}.model-leave-sheet h2{font-size:20px;margin:0 0 12px}.model-leave-sheet p{font-size:14px;color:#777;line-height:1.5}.model-leave-sheet button{display:block;width:100%;min-height:46px;border-radius:24px;margin-top:10px;border:1px solid #eee;background:white}.model-leave-sheet .primary{background:#181818;color:white}
.composition-initial-loading{min-height:55dvh;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;color:#8a8e82;font-size:14px}
.composition-footer{gap:12px}.composition-footer>button{flex:1 1 0;min-width:0;width:auto;min-height:48px;white-space:nowrap;padding:12px 14px}.composition-footer>.composition-save{flex:1.4 1 0}

/* Equal, generous model actions on touch screens. */
.model-action-footer{grid-template-columns:repeat(2,minmax(0,1fr))}.model-action-footer button{min-height:52px;font-size:15px;font-weight:500}
/* Shared primary-tab header alignment: no decorative divider. */
body:is([data-page=home],[data-page=saved],[data-page=profile]) #app .screen>.topbar,
body[data-page=designer] .live-chat-heading{height:47px;min-height:47px;box-sizing:border-box;padding:0;border:0;box-shadow:none;display:flex;align-items:center;gap:12px}
body:is([data-page=home],[data-page=saved],[data-page=profile]) .topbar>h1,
body[data-page=designer] .live-chat-heading strong{display:block;margin:0;font-size:28px;line-height:35px;letter-spacing:-.6px}
body[data-page=designer] .chat-page-subtitle{border-bottom:0}
body[data-page=designer] .chat-header-actions{display:flex;align-items:center;gap:4px;margin-left:auto}
body[data-page=designer] .chat-header-actions button{width:44px;height:44px;min-width:44px;min-height:44px;display:grid;place-items:center;margin:0;padding:0;line-height:1;box-sizing:border-box}
body:is([data-page=home],[data-page=saved],[data-page=profile]) .topbar>button{min-width:44px;min-height:44px;display:grid;place-items:center;align-self:center}

body[data-page=home] .screen,body[data-page=saved] .screen,body[data-page=profile] .screen{overscroll-behavior-y:contain}.pull-refresh-indicator{position:fixed;z-index:90;left:50%;transform:translateX(-50%);display:flex;align-items:center;gap:9px;padding:10px 16px;border:1px solid #eceee7;border-radius:24px;background:#fffffff5;box-shadow:0 4px 16px #0000000d;color:#737c68;font-size:12px;pointer-events:none;white-space:nowrap}.pull-refresh-indicator.is-refreshing:before{content:'';width:15px;height:15px;border:2px solid #e3e7dc;border-top-color:#7b896d;border-radius:50%;animation:generation-spin .8s linear infinite}@media(prefers-reduced-motion:reduce){.pull-refresh-indicator.is-refreshing:before{animation:none}}
body:is([data-page=home],[data-page=saved],[data-page=profile]) #app .screen>.topbar>h1{font-size:28px;line-height:35px;margin:0}

/* Shared mobile filters: fixed search toggle, horizontally scrollable choices. */
.unified-filter-row{display:flex;align-items:center;gap:8px;width:100%;min-width:0}
.unified-filter-row>button,.unified-search-toggle{width:44px;height:44px;min-width:44px;flex:0 0 44px;display:grid;place-items:center;border:0;border-radius:50%;background:#f5f5f4;color:#333;padding:11px}
.unified-search-toggle svg,.unified-filter-row>button svg{width:21px;height:21px}
.unified-filter-scroll{display:flex;align-items:center;flex:1;min-width:0;gap:8px;overflow-x:auto;overscroll-behavior-x:contain;scrollbar-width:none;padding:2px 0;touch-action:pan-x pan-y}
.unified-filter-scroll>*,.unified-filter-scroll .design-filter-row>*{flex:0 0 auto;min-width:0}
.unified-filter-scroll .design-filter-row{display:flex;flex-wrap:nowrap;gap:8px;width:max-content;margin:0}
.unified-filter-scroll label{display:block;margin:0;width:auto!important}
.unified-filter-scroll .choice-trigger,.unified-filter-scroll .style-trigger{width:auto;min-height:44px;max-width:220px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;padding:11px 30px 11px 15px;border:0;border-radius:24px;background:#f5f5f4;font-size:13px;font-weight:400}
.unified-filter-scroll .style-trigger{display:flex;align-items:center;gap:8px;padding-right:14px}
.unified-filter-scroll .style-trigger svg{width:14px;height:14px;fill:none;stroke:currentColor}
.unified-filter-scroll .has-selection,.unified-filter-scroll .choice-trigger[data-filter-active=true]{background:#252a23;color:#fff}
form[data-unified-filters]{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:10px!important;grid-template-columns:none!important}
form[data-unified-filters]>.app-search-field{width:100%;min-width:0;box-sizing:border-box}
form[data-unified-filters]>.app-search-field[hidden]{display:none!important}
.home-tools>.search{margin-top:10px}.home-tools>.selected-styles:empty{display:none}

/* All filter choices share one label/chevron treatment. */
.unified-filter-scroll .choice-trigger,.unified-filter-scroll .style-trigger,.unified-filter-scroll .app-type-filter .choice-trigger{display:flex;align-items:center;justify-content:space-between;gap:12px;box-sizing:border-box;height:44px;min-height:44px;width:auto;min-width:0;padding:0 16px;border:0;border-radius:24px;background:#f5f5f4;color:#333;font:400 13px/20px Arial,"Microsoft YaHei",sans-serif;text-align:left}
.unified-filter-scroll .choice-trigger::after,.unified-filter-scroll .style-trigger::after{content:'';display:block;box-sizing:border-box;width:7px;height:7px;margin:0 2px 4px;border:0;border-right:1.5px solid currentColor;border-bottom:1.5px solid currentColor;transform:rotate(45deg);flex:0 0 7px;opacity:.65}
.unified-filter-scroll .style-trigger>svg{display:none}
.unified-filter-scroll .choice-trigger[data-filter-active=true],.unified-filter-scroll .style-trigger.has-selection{background:#252a23;color:#fff}

.unified-filter-scroll .choice-trigger,.unified-filter-scroll .style-trigger,.unified-filter-scroll .app-type-filter .choice-trigger{padding-right:10px}
.unified-filter-scroll .choice-trigger::after,.unified-filter-scroll .style-trigger::after{margin-right:0}

/* Hide the legacy icon inside translated label wrappers. */
.unified-filter-scroll .style-trigger svg{display:none}
/* The refresh strip occupies real layout space below the fixed page header. */
.pull-refresh-strip{position:relative;box-sizing:border-box;flex-shrink:0;width:100%;height:0;display:flex;align-items:center;justify-content:center;overflow:hidden;color:#818877;background:#f5f6f2;font-size:12px;transition:height .18s ease,opacity .18s ease;margin:0!important;padding:0!important;border-radius:0}
.pull-refresh-strip.is-refreshing:after{content:'';position:absolute;bottom:0;left:0;width:35%;height:3px;border-radius:3px;background:#89967b;animation:pull-refresh-bar 1s ease-in-out infinite}
@keyframes pull-refresh-bar{from{transform:translateX(-100%)}to{transform:translateX(385%)}}
@media(prefers-reduced-motion:reduce){.pull-refresh-strip{transition:none}.pull-refresh-strip.is-refreshing:after{animation:none;left:30%}}


/* Save-design room choices must not shrink into vertical labels. */
#publication-form .design-space-choices>div{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
#publication-form .design-space-choices label{display:block!important;width:auto!important;min-width:0;margin:0!important;flex:none}
#publication-form .design-space-choices label>span{display:flex;align-items:center;justify-content:center;box-sizing:border-box;width:100%;min-height:44px;padding:10px 4px;white-space:nowrap;font-size:12px;line-height:20px}
#publication-form .design-space-choices input[type=radio]{position:absolute;opacity:0;width:1px!important;height:1px;min-width:0;min-height:0;padding:0;margin:0}
html[lang^=en] #publication-form .design-space-choices>div{grid-template-columns:repeat(2,minmax(0,1fr))}
.pull-refresh-strip{gap:8px}.pull-refresh-arrow{width:18px;height:18px;flex-shrink:0;transition:transform .18s ease;display:none}.pull-refresh-strip.is-pulling .pull-refresh-arrow{display:block}.pull-refresh-strip.is-ready .pull-refresh-arrow{transform:rotate(180deg)}@media(prefers-reduced-motion:reduce){.pull-refresh-arrow{transition:none}}

body:is([data-page=saved],[data-page=profile]) #app .screen>.topbar{display:none}

/* Align the composer input and both touch targets on one centre line. */
body[data-page=designer] .live-composer{align-items:center}
body[data-page=designer] .live-composer textarea{margin:0;box-sizing:border-box}
body[data-page=designer] .chat-upload,body[data-page=designer] .chat-send{display:grid;place-items:center;padding:0;margin:0;line-height:1;box-sizing:border-box}
/* Registration is a full-width secondary action beside the primary sign-in hierarchy. */
.auth-entry #live-auth-form [data-act="register-open"]{display:flex;align-items:center;justify-content:center;width:100%;box-sizing:border-box;min-height:52px;padding:14px 20px;border:1px solid #b9bbb5;border-radius:14px;background:#fff;color:#171917;font:inherit;line-height:1.4;text-decoration:none}
.auth-entry #live-auth-form [data-act="register-open"]:hover{background:#f6f7f3}
.auth-entry #live-auth-form [data-act="register-open"]:focus-visible{outline:2px solid #7b896d;outline-offset:3px}
/* Share identical geometry for both account entry actions. */
.auth-entry #live-auth-form > button:is([name="action"],[data-act="register-open"]){display:flex;align-items:center;justify-content:center;box-sizing:border-box;width:100%;max-width:none;height:52px;min-height:52px;padding:0 20px;margin:0;border-width:1px;border-style:solid;border-radius:12px!important;font-size:16px;font-weight:500!important;line-height:1.4}
.auth-entry #live-auth-form > button[name="action"]{border-color:#171917}
/* Account actions and header controls share one spacing and sizing rule. */
.auth-entry #live-auth-form > button[name="action"] + button[data-act="register-open"]{margin-top:12px}
.auth-top > .icon,.register-page header .register-close{display:grid;place-items:center;flex:0 0 44px;width:44px;height:44px;min-height:44px;padding:0;border:0;border-radius:50%;background:#f5f5f3;color:#171717;line-height:1;text-decoration:none}
.auth-top > .icon svg,.register-page header .register-close svg{display:block;width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.auth-top > .icon:hover,.register-page header .register-close:hover{background:#ebede7}
.auth-top > .icon:focus-visible,.register-page header .register-close:focus-visible{outline:2px solid #7b896d;outline-offset:2px}

/* Shared platform-independent SVG glyph sizing. */
.ui-symbol{display:inline-block;width:20px;height:20px;min-width:20px;flex:none;vertical-align:middle;pointer-events:none;fill:none;stroke:currentColor;stroke-width:1.7}
.chat-designer-mark .ui-symbol,.designer-mark .ui-symbol{width:20px;height:20px}

:is(.product-header,.composition-header,.creation-header,.creator-header,.register-page header)>a:first-child:has(svg)::before{display:none}

:is(.product-header,.composition-header,.creation-header,.creator-header,.register-page header)>a:first-child:has(svg)::before{display:none}

.library-pagination{min-height:56px;padding:16px 0;display:flex;align-items:center;justify-content:center;gap:8px;color:#94978f;font-size:12px;overflow-anchor:none}.library-pagination button{border:0;background:none;color:#73796b;font:inherit;padding:10px 16px}.library-pagination .load-spinner{width:16px;height:16px}.pagination-spacer{height:24px}

/* Consistent recoverable generation errors */
.task-issue-panel{margin:12px 0;padding:14px;border:1px solid #ecdcd5;border-radius:14px;background:#fcf7f4;color:#5e4137;font-size:13px;line-height:1.5}
.task-issue-panel>strong{font-size:14px}.task-issue-panel .task-issue{margin:6px 0 12px;padding:0;color:#79685f}
.task-issue-panel .task-issue-actions{display:flex;gap:8px;flex-wrap:wrap}.task-issue-panel button{min-height:40px;padding:8px 16px;border-radius:20px;border:1px solid #dbcec7;background:white;font:inherit;color:#252923}.task-issue-panel button:first-child{background:#252923;color:white;border-color:#252923}.task-issue-panel button:disabled{opacity:.55}.pending-product>.task-issue-panel{margin:10px}

.generation-record-picker{display:flex;gap:8px;overflow-x:auto;padding:4px 0 12px;scrollbar-width:thin}.generation-record-picker button{flex:0 0 auto;display:grid;gap:4px;text-align:left;padding:10px 12px;border:1px solid #ddd;border-radius:12px;background:#fff;color:#6f756a;font-size:12px}.generation-record-picker button[aria-pressed=true]{border:2px solid #28342b;background:#edf1eb;color:#253128;padding:9px 11px}.generation-record-picker strong{font-size:12px}.selected-record-label{margin:0 0 10px;font-size:12px;color:#707568}.record-placeholder{display:flex!important;flex-direction:column;align-items:center;justify-content:center;gap:12px;background:#f4f3f0;color:#8a8076;min-height:220px;aspect-ratio:1}.record-placeholder strong{font-size:14px;font-weight:500}

.generation-card-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;align-items:start;margin:0 0 16px}.generation-result-card{min-width:0;border:1px solid #e6e6e2;border-radius:14px;overflow:hidden;background:white}.generation-result-card.is-selected{border-color:#53654d;box-shadow:0 0 0 1px #53654d}.generation-card-select{display:block;width:100%;padding:0;border:0;background:none;text-align:left;color:inherit;cursor:pointer}.generation-card-image{display:block;width:100%;height:auto;aspect-ratio:1;object-fit:cover;border-radius:0!important}.generation-card-placeholder{display:flex;flex-direction:column;gap:12px;justify-content:center;align-items:center;background:#f3f3ef;color:#858a7e;font-size:12px}.generation-card-caption{display:grid;gap:5px;padding:10px;font-size:11px;color:#858a7e}.generation-card-caption strong{font-size:11px;font-weight:500;color:#343a31;line-height:1.5}.generation-card-view{margin:0 10px 10px;border:0;background:#f2f3ef;border-radius:20px;padding:8px 12px;font-size:12px}.generation-result-card .task-issue-panel{margin:0;padding:10px;border:0;border-radius:0;font-size:11px}.generation-result-card .task-issue-panel>strong{display:none}.generation-result-card .task-issue-actions{gap:6px}.generation-result-card .task-issue-actions button{padding:6px 10px;min-height:36px;font-size:11px}

/* Favorites: one consistent vertical rhythm for both content types. */
body[data-page="saved"] .library-section-heading:has(+ .favorite-kinds){margin:20px 0 16px;min-height:28px}
.favorite-kinds{display:grid;grid-template-columns:1fr 1fr;gap:4px;padding:4px;margin:0 0 16px;background:#f3f3f2;border-radius:14px}
.favorite-kinds .chip{display:flex;align-items:center;justify-content:center;min-height:44px;margin:0;padding:10px 12px;border:0;border-radius:10px;background:transparent;color:#737373;font-size:14px;line-height:1.4}
.favorite-kinds .chip.active{background:#fff;color:#181818;font-weight:600;box-shadow:0 1px 4px #0000000d}
.favorite-kinds .chip:focus-visible{outline:2px solid #333;outline-offset:1px}
#cloud-search.favorite-search-form{display:flex;flex-direction:column;gap:12px;margin:0 0 20px;padding:0;min-width:0}
.favorite-search-form .app-search-field{width:100%;box-sizing:border-box;min-height:44px;flex:none;margin:0}
.favorite-search-form .app-type-filter{align-self:flex-start;max-width:100%;margin:0}
.favorite-search-form + .creation-grid{margin-top:0}
.favorite-search-form + .creation-grid .library-empty-card{grid-column:1/-1;box-sizing:border-box;width:100%;margin:0;min-height:180px;padding:24px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;text-align:center}
.favorite-search-form + .creation-grid .library-empty-card p{margin:0;line-height:1.6}

/* Selected image above a compact, horizontally scrolling history. */
.selected-generation-preview{display:block;width:100%;padding:0;margin:0 0 14px;border:0;background:#f3f3ef;border-radius:16px;overflow:hidden;aspect-ratio:1.12;color:#888}
.selected-generation-preview .composition-hero{display:block;width:100%;height:100%;margin:0;object-fit:cover;border-radius:0}
.selected-generation-empty{display:flex;align-items:center;justify-content:center;font-size:13px}
.composition-preview .generation-card-list{display:flex;gap:10px;overflow-x:auto;align-items:stretch;margin:0;padding:2px 2px 8px;scrollbar-width:thin;overscroll-behavior-x:contain}
.composition-preview .generation-result-card{flex:0 0 112px;border-radius:10px}
.composition-preview .generation-card-image{aspect-ratio:1.2}
.composition-preview .generation-card-caption{padding:8px;gap:4px;font-size:10px}
.composition-preview .generation-card-caption strong{font-size:10px;line-height:1.5}
.composition-preview .generation-card-placeholder{gap:6px;font-size:10px}
.selected-generation-preview:focus-visible,.generation-card-select:focus-visible{outline:2px solid #53654d;outline-offset:2px}

/* Give atmosphere copy enough room to read and edit on portrait screens. */
#composition-generate>.primary{position:sticky;bottom:0;z-index:2;box-shadow:0 -10px 0 6px #fff}
/* Task-backed image history: selection is visual, without metadata captions. */
.composition-preview .generation-result-card{position:relative}
.generation-record-delete{position:absolute;right:6px;top:6px;width:30px;height:30px;display:grid;place-items:center;padding:0;border:0;border-radius:50%;background:rgba(255,255,255,.94);color:#333}
.selected-generation-empty{flex-direction:column;gap:16px}
.selected-generation-empty .load-feedback{width:min(80%,280px);justify-content:center}
.library-card.has-design-task{position:relative}
.library-card.has-design-task .design-task-status{position:absolute;top:0;left:0;width:100%;aspect-ratio:1.2;display:flex;align-items:center;justify-content:center;background:#f5f5f3;border-radius:16px;pointer-events:none}
.library-card.has-design-task .design-task-status .load-feedback{width:80%;justify-content:center}

.square-favorite{width:42px;height:42px;flex:0 0 42px;display:inline-grid;place-items:center;padding:0;border:1px solid #e8e8e5;border-radius:50%;background:#fff;color:#555;cursor:pointer}
.square-favorite.is-saved{color:#ad534d;background:#fff5f3;border-color:#f1d9d4}
.square-favorite:disabled{opacity:.5;cursor:wait}
.public-furniture-detail{position:relative}
.public-furniture-detail>.square-favorite{position:absolute;right:0;top:0}
.public-furniture-detail>h2{padding-right:52px}

#catalog .product-grid>article{position:relative}
#catalog .product-grid>article>.square-favorite{position:absolute;right:10px;top:10px;z-index:1}

/* Shared square and owner publication preview rhythm. */
.design-preview-layout .inspiration-copy{padding:0}
.design-preview-layout .design-preview-heading{display:flex;flex-direction:column;gap:10px}
.design-preview-layout .inspiration-copy h1{margin:0;font-size:24px;line-height:1.3}
.design-preview-layout .design-badges{display:flex;flex-wrap:wrap;gap:6px;margin:0}
.design-preview-layout .inspiration-copy>.creator-link{margin:14px 0;font-size:14px;gap:10px}
.design-preview-layout .inspiration-copy p{margin:0;font-size:14px;line-height:1.7;color:#62645f}
.design-preview-layout .composition-group{margin:24px 0}
.design-preview-layout .composition-group .section-label{margin-bottom:12px}
@media(max-width:600px){.composition-layout.design-preview-layout{gap:16px}}

/* Empty designs explain the first action; existing task results retain their layout. */
#composition.design-start{padding-bottom:24px}
.design-start .composition-layout,.design-without-image .composition-layout{display:block}
.design-start-guide{max-width:420px;margin:0 auto;padding:clamp(60px,16vh,140px) 4px 40px;text-align:center}
.design-start-guide h1{margin:0 0 14px;font-size:25px;line-height:1.4;letter-spacing:-.5px}
.design-start-guide p{margin:0 0 30px;font-size:15px;line-height:1.7;color:#6b6d67}
.design-start-guide button{width:100%;min-height:52px;border-radius:16px;font-size:16px}
.design-add-optional{background:#f5f5f3;border:0;border-radius:14px;padding:14px 18px;min-height:48px;color:#464943;font-size:14px;cursor:pointer}

/* Compact shared design lists: reset nested headings instead of browser h2 margins. */
#composition .composition-group{margin:18px 0 20px}
#composition .composition-group .section-label,#composition .composition-heading{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:0 0 10px}
#composition .composition-group h2{font-size:17px;font-weight:600;line-height:1.4;margin:0;letter-spacing:0}
#composition .composition-strip{gap:12px;padding:4px 0 4px}
#composition .composition-mini-open>span:not(.missing-picture){margin:6px 2px 0;line-height:1.4}
#composition .composition-group+.composition-group{margin-top:20px}

/* Home vertical rhythm: tighter whitespace, unchanged touch targets. */
body[data-page=home] .challenge-entry.challenge-editorial{min-height:150px;margin:4px 0 12px}
body[data-page=home] .challenge-entry.challenge-editorial>span{padding:16px 14px 16px 16px;gap:7px}
body[data-page=home] .challenge-entry.challenge-editorial>img{min-height:150px}
body[data-page=home] .challenge-entry.challenge-editorial strong{font-size:20px}
body[data-page=home] .home-tools{padding:6px 0;margin:0}
body[data-page=home] .discovery-note{margin:4px 0 10px;line-height:1.4}
body[data-page=home] .look-list{gap:22px}
body[data-page=home] .explore-caption{padding:8px 2px 0}
body[data-page=home] .explore-caption .caption-heading{gap:8px;min-height:34px}
body[data-page=home] .explore-caption .design-badges{margin-top:4px;margin-bottom:4px;gap:6px}
body[data-page=home] .explore-caption .caption-description{margin:4px 0 0;line-height:1.5}

/* Furniture names share a readable two-line baseline across picker and design lists. */
#composition .composition-mini-open,#furniture-sheet .composition-choice-grid>button{font-family:inherit;text-align:left}
#composition .composition-mini-open>span:not(.missing-picture),
#furniture-sheet .composition-choice-grid>button>span:not(.missing-picture){
 display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;
 font-family:inherit;font-size:13px;font-weight:500;line-height:1.5;letter-spacing:0;
 color:#393c36;margin:8px 2px 0;min-height:39px;max-height:39px;
 white-space:normal;word-break:normal;overflow-wrap:anywhere;text-align:left;
}
#composition .composition-mini{flex-basis:116px}
#composition .composition-mini-open img,#composition .composition-mini-open .missing-picture{width:100%;height:auto;aspect-ratio:1}
#furniture-sheet .composition-choice-grid>button{padding-bottom:10px}
#composition .composition-mini-open>span:not(.missing-picture),#furniture-sheet .composition-choice-grid>button>span:not(.missing-picture){text-wrap:pretty}

body[data-page=home] .home-list-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 8px;min-height:36px}
body[data-page=home] .home-list-heading .discovery-note{margin:0}
body[data-page=home] .home-sort-action{display:inline-flex;align-items:center;gap:5px;min-height:36px;padding:6px 0 6px 10px;border:0;background:transparent;border-radius:8px;color:#666b62;font:inherit;font-size:12px;white-space:nowrap}
body[data-page=home] .home-sort-action svg{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:1.5}
body[data-page=home] .home-sort-action:focus-visible{outline:2px solid #747d68;outline-offset:3px}

@media(pointer:fine){#composition .composition-strip,#composition .generation-card-list{cursor:grab}#composition .composition-strip button,#composition .generation-card-list button{cursor:grab}}
#composition .is-mouse-dragging{scroll-snap-type:none;scroll-behavior:auto;user-select:none;cursor:grabbing!important}
#composition .is-mouse-dragging *{user-select:none;cursor:grabbing!important}

/* Display-only series/name hierarchy; original names stay in data and detail pages. */
#composition .furniture-name,#furniture-sheet .furniture-name{margin:8px 2px 0;text-align:left;min-width:0}
#composition .furniture-name-main,#furniture-sheet .furniture-name-main{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden;font-size:13px;line-height:1.45;font-weight:600;color:#30342e;min-height:38px;max-height:38px;white-space:normal;word-break:normal;overflow-wrap:anywhere;text-wrap:pretty}
#composition .furniture-name-series,#furniture-sheet .furniture-name-series{display:block;margin-top:3px;font-size:11px;line-height:16px;font-weight:400;color:#858980;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#composition .furniture-name-main,#furniture-sheet .furniture-name-main{min-height:19px}

body[data-page=home] .home-search-row{display:flex;align-items:center;gap:8px;min-width:0}
body[data-page=home] .home-search-input{display:flex;align-items:center;gap:8px;flex:1 1 0;min-width:0;height:44px;box-sizing:border-box;padding:0 12px;background:#f5f5f3;border-radius:24px;margin:0}
body[data-page=home] .home-search-input>svg{flex:none;width:18px;height:18px;color:#777c73}
body[data-page=home] .home-search-input input{flex:1;min-width:0;width:100%;height:100%;padding:0;border:0;outline:0;background:transparent;font:inherit;font-size:14px;color:#30342e}
body[data-page=home] .home-search-input:focus-within{box-shadow:0 0 0 1.5px #858e7c}
body[data-page=home] .home-search-row .unified-filter-scroll{flex:0 0 auto;max-width:42%;min-width:0;margin:0}
body[data-page=home] .home-search-row .unified-filter-scroll>label{max-width:100%}
/* Selected generation: one centered, truthful progress display. */
.generation-stage{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:14px;width:100%;padding:24px;text-align:center;box-sizing:border-box;color:#293128}
.generation-stage .generation-stage-spinner{display:block;flex:none;width:36px;height:36px;border:2px solid #dfe3da;border-top-color:#78866d;border-radius:50%;animation:composition-spin 1s linear infinite}
.generation-stage strong{display:flex;align-items:baseline;gap:8px;font-size:16px;line-height:1.5;font-weight:500}
.generation-stage-percent{font-size:14px;font-variant-numeric:tabular-nums;color:#68765e}
.generation-stage progress{display:block;width:144px;height:4px;border:0;border-radius:8px;overflow:hidden;appearance:none;background:#e1e5dc;accent-color:#78866d}
.generation-stage progress::-webkit-progress-bar{background:#e1e5dc;border-radius:8px}
.generation-stage progress::-webkit-progress-value{background:#78866d;border-radius:8px}
.generation-stage progress::-moz-progress-bar{background:#78866d;border-radius:8px}
.generation-stage p{font-size:12px;line-height:1.6;color:#83887e;margin:0}
#composition .generation-card-placeholder:has(.composition-spinner)>span[data-i18n-ignore]{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
@keyframes composition-spin{to{transform:rotate(360deg)}}
@media(prefers-reduced-motion:reduce){.generation-stage-spinner{animation:none}}

/* Shared list progress matches the selected design preview. */
.model-progress-preview{display:flex;align-items:center;justify-content:center}
.library-card .generation-stage{padding:16px;gap:10px}
.library-card .generation-stage strong{font-size:14px;flex-wrap:wrap;justify-content:center;gap:6px}
.library-card .generation-stage p{font-size:11px;max-width:210px}
.library-card .generation-stage progress{width:min(144px,80%)}
.library-card .generation-stage .generation-stage-spinner{width:30px;height:30px}

/* Settings: consistent leading icon, text column and trailing affordance. */
.settings-page{padding-top:4px}
.settings-page .settings-list{margin:0}
.settings-page .settings-list-support{margin-top:20px;border-top:1px solid var(--line,#ecece8)}
.settings-page .settings-row{display:flex;align-items:center;width:100%;min-height:60px;gap:12px;padding:15px 0;margin:0;border:0;border-bottom:1px solid var(--line,#ecece8);border-radius:0;background:transparent;text-align:left;color:var(--ink,#222);box-sizing:border-box;font:inherit}
.settings-page button.settings-row{cursor:pointer}
.settings-page .settings-row>svg{width:20px;height:20px;flex:0 0 20px;color:#62675f}
.settings-page .settings-row>svg:last-child{width:16px;height:16px;flex-basis:16px;color:#969b92}
.settings-page .settings-copy{display:flex;flex:1;min-width:0;flex-direction:column;gap:4px}
.settings-page .settings-copy b{font-size:14px;font-weight:500;line-height:1.45}
.settings-page .settings-copy small{font-size:12px;line-height:1.55;color:#858a81;font-weight:400}
.settings-page .settings-value{font-size:12px;color:#858a81;line-height:1.5;flex:none;max-width:35%;text-align:right}
.settings-page .settings-row-static{align-items:flex-start}
.settings-page .settings-row-static>svg{margin-top:1px}
.settings-page .settings-row-static .settings-value{padding-top:1px}
.settings-page .settings-signout{margin-top:26px}
.settings-page .settings-signout>button{width:100%;min-height:46px;margin:0;font-size:14px;border-radius:12px}
.settings-page .settings-signout p{margin:10px 2px 0;text-align:left;font-size:11px;line-height:1.6;color:#858a81}
.settings-page button.settings-row:focus-visible{outline:2px solid #78866d;outline-offset:3px}

@media (hover:hover) and (pointer:fine){.similar-design-list{cursor:grab}.similar-design-list img{user-select:none;-webkit-user-drag:none}}

/* Shared mouse drag feedback; touch keeps native scrolling. */
.is-mouse-dragging{scroll-snap-type:none!important;scroll-behavior:auto!important;user-select:none!important;cursor:grabbing!important}.is-mouse-dragging *{user-select:none!important;cursor:grabbing!important}
@media(hover:hover) and (pointer:fine){:is(.composition-strip,.generation-card-list,.similar-design-list,.composition-results,.category-row,.layout-options,.unified-filter-scroll,.generation-record-picker,.home-chips,.soft-materials,.chat-selected-materials,.library-sections,.publication-cover-options,.atmosphere-tags,.choice-sheet-groups,.chips,.furniture-tabs,.model-strip,.similar-list,.diy-tools){cursor:grab}}

/* Compact favorites layout; empty task status must not create a second spacer. */
.screen:has(.favorite-kinds) .library-section-heading{margin:16px 0 12px;min-height:26px}
.screen:has(.favorite-kinds) .library-section-heading h2{font-size:20px;line-height:26px}
.screen:has(.favorite-kinds) #parent-task-status:empty{display:none;margin:0}
.favorite-kinds{padding:3px;gap:3px;margin-bottom:12px;border-radius:12px}
.favorite-kinds .chip{min-height:38px;padding:8px 12px;border-radius:9px}
#cloud-search.favorite-search-form{gap:10px;margin-bottom:14px}
.favorite-search-form + .creation-grid .library-empty-card{min-height:144px;padding:20px;border-radius:14px}


/* Generation sheet: compact prompt editor and fully visible quality choices. */
#composition-generate .atmosphere-options{margin:14px 0 16px}
#composition-generate .atmosphere-options>p{margin-bottom:10px}
#composition-generate .atmosphere-tags{gap:6px}
#composition-generate .atmosphere-tags button{padding:6px 10px;min-height:32px}
#composition-generate .composition-tiers{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:0 0 16px}
#composition-generate .composition-tiers label{box-sizing:border-box;min-height:78px;padding:10px 6px;gap:4px;align-content:center;border-radius:12px;border-color:#e3e3df;line-height:1.4}
#composition-generate .composition-tiers b{font-size:13px;font-weight:600}
#composition-generate .composition-tiers span{font-size:12px;color:#72766e}
#composition-generate .composition-tiers small{font-size:11px;color:#858980}
#composition-generate .composition-tiers label:has(:checked){border-color:#6f7e65;background:#f1f4ee;box-shadow:inset 0 0 0 1px #6f7e65}
#furniture-sheet #composition-generate>.primary{position:static;margin:0;min-height:46px;border-radius:12px;box-shadow:none}


/* Sheet chrome remains available while its contents scroll. */
dialog:modal>header,dialog:modal>.drawer-head,dialog:modal>form>header,dialog:modal>.publication-form>header,dialog:modal .result-toolbar{
 position:sticky;top:0;z-index:20;background:#fff;isolation:isolate;
 box-shadow:0 -20px 0 16px #fff,0 8px 0 #fff;
}
dialog:modal>header h2,dialog:modal>form>header h2,dialog:modal>.drawer-head h2{min-width:0;overflow-wrap:anywhere}
dialog:modal>header>button,dialog:modal>form>header>button,dialog:modal>.drawer-head>button{flex-shrink:0}
dialog:modal{scroll-padding-top:76px;scroll-padding-bottom:86px}
#furniture-sheet #composition-generate>.primary,dialog:modal #publication-form>.primary:last-child{
 position:sticky;bottom:0;z-index:15;box-shadow:0 10px 0 16px #fff,0 -12px 0 #fff;margin-top:16px;
}
/* Choice lists already scroll internally; keep their header outside that area. */
dialog.choice-sheet:modal>header{position:relative;top:auto;flex-shrink:0;box-shadow:none}

dialog:modal:not(.choice-sheet)::before{position:sticky;top:0;z-index:21;box-shadow:0 -12px 0 12px #fff,0 8px 0 10px #fff}
dialog:modal:not(.choice-sheet)>header,dialog:modal>form>header,dialog:modal>.publication-form>header,dialog:modal>.drawer-head,dialog:modal .result-toolbar{top:24px}

.home-content-tabs{display:flex;gap:24px;margin:0 0 14px;border-bottom:1px solid #eee;min-height:42px;align-items:stretch}.home-content-tabs a{display:flex;align-items:center;padding:8px 3px;text-decoration:none;color:#888;font-size:15px;border-bottom:2px solid transparent}.home-content-tabs a[aria-current=page]{color:#181818;font-weight:600;border-color:#181818}
/* Compact public design metadata: creator and room type share a row. */
.design-preview-layout .design-preview-meta{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:10px 0 12px;min-width:0}
.design-preview-layout .design-preview-meta .creator-link{display:flex;align-items:center;gap:8px;margin:0;min-width:0;font-size:13px;flex:1}
.design-preview-meta .creator-link>span:last-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.design-preview-meta .creator-avatar{width:28px;height:28px;flex:none;font-size:12px}
.design-preview-layout .design-preview-meta .design-badges{margin:0;flex:none;gap:4px;font-size:10px;line-height:1.4}
.design-preview-meta .design-badges>[data-choice-tone]{padding:2px 6px;border-color:transparent;background:#f5f6f3;color:#7c8277}

.discovery-header{display:flex!important;align-items:center;justify-content:space-between;gap:10px}.discovery-header h1{display:flex;align-items:baseline;gap:5px;white-space:nowrap;margin:0!important}.discovery-suffix{font-family:Arial,"Microsoft YaHei",sans-serif;font-size:14px;font-weight:400;color:#85857e}.discovery-switch{display:inline-flex;align-items:center;justify-content:center;gap:5px;flex-shrink:0;min-height:40px;padding:8px 10px;border-radius:20px;background:#f5f5f3;color:#444;text-decoration:none;font:13px Arial,"Microsoft YaHei",sans-serif}.discovery-switch svg{width:16px!important;height:16px!important;fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round}#catalog .furniture-header{padding:12px 20px;border-bottom:1px solid #eee}#catalog .furniture-header h1{font-size:27px}#catalog .furniture-scroll{scrollbar-width:none}#catalog .furniture-scroll::-webkit-scrollbar{display:none}

/* Compact header switch: explicit action, neutral outline. */
.discovery-header .discovery-switch{background:#fff;border:1px solid #deded9;border-radius:10px;min-height:40px;padding:9px 12px;font-size:13px;font-weight:500;line-height:20px;color:#41453d;transition:background .15s,border-color .15s}.discovery-header .discovery-switch svg{display:none}.discovery-header .discovery-switch:hover{background:#f7f8f5;border-color:#bfc5b7}.discovery-header .discovery-switch:focus-visible{outline:2px solid #64725b;outline-offset:3px}.discovery-header .discovery-suffix{font-size:15px;color:#76796f}.discovery-header h1.brand,#catalog .discovery-header h1{font-size:27px!important}
/* Show the whole design image; fixed ratios are only for loading placeholders. */
#composition .selected-generation-preview:not(.selected-generation-empty){aspect-ratio:auto;height:auto}
#composition .composition-preview img.composition-hero{display:block;width:100%;height:auto;aspect-ratio:auto;object-fit:contain}
#composition .composition-preview img.generation-card-image{object-fit:contain;background:#f5f5f2}

/* Consistent modal header geometry and scroll containment. */
dialog:modal{overscroll-behavior:contain;scroll-padding-block:96px 96px}
dialog:modal>form>header,dialog:modal>header,dialog:modal>.drawer-head{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:44px}
dialog:modal>form>header h2{margin:0;font-size:20px;line-height:1.35}
dialog:modal>form>header>button,dialog:modal>header>button,dialog:modal>.drawer-head>button{display:inline-flex;align-items:center;justify-content:center;width:44px;height:44px;min-height:44px;padding:0;flex:0 0 44px}
dialog.choice-sheet:modal{overflow:hidden}
dialog.choice-sheet:modal .choice-sheet-options{min-height:0;overflow-y:auto;overscroll-behavior:contain;scroll-padding-block:8px}

/* Library search fills available width, wrapping only when controls no longer fit. */
#cloud-search.library-inline-search{flex-direction:row!important;flex-wrap:wrap;align-items:center!important;gap:8px!important}
#cloud-search.library-inline-search>.app-search-field{flex:1 1 160px;width:auto;min-width:150px;margin:0}
#cloud-search.library-inline-search>.unified-filter-row{flex:0 1 auto;width:auto;max-width:100%;margin:0}
#cloud-search.library-inline-search .unified-filter-scroll{flex:0 1 auto;max-width:100%}
#cloud-search.library-inline-search .app-search-field input{min-width:0;width:100%}

/* Keep library search and filters on one row at phone widths. */
#cloud-search.library-inline-search{flex-wrap:nowrap}
#cloud-search.library-inline-search>.app-search-field{flex:1 1 0;min-width:0}
#cloud-search.library-inline-search>.unified-filter-row{flex:0 0 auto;max-width:68%}
#cloud-search.library-inline-search .app-search-field input{width:0;flex:1 1 0;min-width:0;text-overflow:ellipsis}
#cloud-search.library-inline-search .unified-filter-scroll .choice-trigger{padding-inline:10px!important;gap:6px!important}

/* One scroll owner for product preview and editor; nested form must not trap wheel/touch. */
body.model-page .model-detail-layout{overflow-y:auto;overflow-x:hidden;scrollbar-width:none;-ms-overflow-style:none}
body.model-page .model-detail-layout>.model-edit-page{overflow:visible;overscroll-behavior:auto;min-height:auto}
body.model-page .model-edit-page{scrollbar-width:none}
body.model-page .model-detail-layout::-webkit-scrollbar,body.model-page .model-edit-page::-webkit-scrollbar{display:none;width:0;height:0}

/* Generating products use the same card geometry as completed products. */
body[data-page=saved] .model-library-grid .pending-product.library-card{border:0;border-radius:0;background:transparent;overflow:visible;box-shadow:none;padding:0;align-self:start}
body[data-page=saved] .model-library-grid .pending-product .library-cover{border-radius:12px;background:#f6f6f6;aspect-ratio:1;width:100%}
body[data-page=saved] .model-library-grid .pending-product .library-card-copy{display:block;padding:10px 2px}
body[data-page=saved] .model-library-grid .pending-product .library-card-copy strong{font-size:15px;font-weight:600;line-height:1.45;letter-spacing:-.2px}

/* Furniture discovery: one compact search and category row. */
#catalog .furniture-search-tools{display:grid;grid-template-columns:minmax(0,1fr) 112px;gap:8px;margin:0 0 16px;align-items:start}
#catalog #furniture-search{position:relative;margin:0;min-width:0;grid-column:1;grid-row:1}
#catalog #furniture-search input{width:100%;height:44px;padding:0 12px 0 42px;font-size:14px;border:1px solid transparent}
#catalog #furniture-search input:focus{outline:none;border-color:#84917b;background:#f6f7f3}
#catalog #furniture-search button{position:absolute;left:0;top:0;width:40px;height:44px;padding:0;display:grid;place-items:center;border:0;background:transparent;border-radius:22px}
#catalog .furniture-search-tools .furniture-filters{display:contents}
#catalog .furniture-search-tools .furniture-filters>select,#catalog .furniture-search-tools .furniture-filters>.choice-trigger{grid-column:2;width:112px!important;max-width:112px;min-height:44px!important;height:44px;box-sizing:border-box;margin:0!important}
