.room-mobile,.room-mobile-reopen{display:none}
@media(max-width:760px){
 .room-mobile-reopen:not([hidden]){display:inline-flex}
 body.room-mobile-open{overflow:hidden}
 body.room-mobile-open > :is(.sidebar,.mobile-design-dock){visibility:hidden}
 .room-mobile:not([hidden]){position:fixed;inset:0;z-index:900;display:grid;grid-template-rows:auto minmax(0,1fr) auto;background:#f5f5f5;color:#252125;font:14px/1.3 system-ui,sans-serif;padding:env(safe-area-inset-top) 0 env(safe-area-inset-bottom)}
 .room-mobile button,.room-mobile summary{font:inherit;cursor:pointer}
 .room-mobile button:disabled{opacity:.48;cursor:default}
 .room-mobile header{position:relative;display:grid;grid-template-columns:44px 1fr 44px;align-items:center;justify-items:center;padding:5px 4px;background:white;min-height:48px}
 .room-mobile header button,.room-mobile summary{border:0;background:white;color:inherit;border-radius:4px;min-height:38px;padding:6px 12px}
 .room-mobile header [data-photo]{background:#721238;color:white;font-weight:650}
 .room-mobile summary{list-style:none;font-size:22px}
 .room-mobile header details[open]{position:relative;z-index:3}
 .room-mobile header details button{position:absolute;right:0;width:155px;text-align:left;box-shadow:0 1px 8px #0002}
 .room-mobile header details button:nth-of-type(2){top:76px}
 .room-mobile header details button:nth-of-type(3){top:114px}
 .room-mobile-stage{position:relative;min-height:0;display:grid;place-items:center;background:#dedbd9;overflow:hidden}
 .room-mobile-stage img{position:absolute;inset:0;width:100%;height:100%;min-height:0;object-fit:contain}
 .room-mobile-hotspots{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);pointer-events:none}
 .room-mobile-hotspots button,.room-mobile-stage [data-catalog]{position:absolute;border:0;border-radius:100px;background:#241e22d9;color:white}
 .room-mobile-hotspots button{transform:translate(-50%,-50%);white-space:nowrap;pointer-events:auto;font-size:11px;padding:5px 8px;max-width:130px;overflow:hidden;text-overflow:ellipsis}
 .room-mobile-stage [data-catalog]{bottom:8px;left:8px;width:38px;height:38px;font-size:22px}
 .room-mobile-tray{background:white;border-radius:10px 10px 0 0;padding:0 8px 8px;min-height:0;box-shadow:0 -1px 6px #0001}
 .room-mobile-handle{display:block;width:72px;height:22px;margin:auto;border:0;background:none;touch-action:none}
 .room-mobile-handle::after{content:"";display:block;margin:auto;width:44px;height:3px;border-radius:9px;background:#9a9498}
 .room-mobile-actions,.room-mobile-filters{display:flex;align-items:center;gap:8px;padding:0 4px 6px}
 .room-mobile-actions span{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:12px}
 .room-mobile-actions button,.room-mobile-filters button{border:0;border-radius:4px;background:#f3eff1;color:inherit;padding:7px}
 .room-mobile-filters input,.room-mobile-filters select{min-width:0;width:0;flex:1;border:1px solid #ddd5da;border-radius:4px;background:white;color:inherit;padding:6px;font-size:16px}
 .room-mobile-swatches{display:flex;gap:6px;overflow-x:auto;scroll-snap-type:x proximity}
 .room-mobile-swatches div{position:relative;flex:0 0 66px;scroll-snap-align:start}
 .room-mobile-swatches button:first-child{width:100%;min-height:64px;background:var(--swatch);border:2px solid transparent;border-radius:4px;color:transparent;font-size:0}
 .room-mobile-swatches button:first-child[aria-pressed=true]{border-color:#721238;box-shadow:inset 0 0 0 2px white}
 .room-mobile-swatches button:nth-child(2){position:absolute;top:3px;right:3px;border:0;border-radius:50%;background:#231a20b3;color:white;width:22px;height:22px;padding:0}
 .room-mobile.expanded .room-mobile-swatches{display:grid;grid-template-columns:repeat(auto-fill,minmax(82px,1fr));max-height:40dvh;overflow-y:auto}
 .room-mobile.expanded .room-mobile-swatches button:first-child{min-height:82px}
}

/* Small-screen visualiser: keep photo, toolbar and finish controls within viewport. */
@media(max-width:760px){
 .room-mobile:not([hidden]){width:100%;max-width:100vw;height:100dvh;max-height:100dvh;overflow:hidden;grid-template-rows:minmax(52px,auto) minmax(100px,1fr) auto;padding-top:env(safe-area-inset-top);padding-bottom:env(safe-area-inset-bottom)}
 .room-mobile header{grid-template-columns:48px minmax(0,1fr) 48px;gap:8px;padding:6px 10px;z-index:2}
 .room-mobile header [data-photo]{width:max-content;max-width:100%;min-height:42px;padding:8px 16px;border-radius:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
 .room-mobile header [data-close]{min-width:44px;min-height:44px;font-size:24px}
 .room-mobile header details{justify-self:end}
 .room-mobile header summary{display:grid;place-items:center;min-width:44px;min-height:44px}
 .room-mobile-tray{max-height:min(47dvh,360px);overflow:hidden;padding:0 10px 12px;border-radius:18px 18px 0 0;display:flex;flex-direction:column;gap:5px}
 .room-mobile-actions{flex-wrap:wrap;row-gap:6px}
 .room-mobile-actions [data-render]{min-height:42px;font-weight:650;white-space:nowrap}
 .room-mobile-actions [data-state]{min-width:70px}
 .room-mobile-filters{flex:none}
 .room-mobile-filters select{flex:0 0 32%;max-width:40%;text-overflow:ellipsis}
 .room-mobile-filters input{flex:1;min-width:55px}
 .room-mobile-swatches{flex:none;min-height:76px;max-height:94px;padding-bottom:8px}
 .room-mobile.expanded .room-mobile-swatches{flex:1;min-height:90px;max-height:min(30dvh,220px);overflow-y:auto}
 .room-mobile-stage [data-catalog]{width:44px;height:44px;bottom:12px;left:12px}
 .room-mobile-hotspots button{min-height:28px;max-width:110px;font-size:10px}
}
@media(max-width:390px){
 .room-mobile header{gap:3px;padding-inline:5px}
 .room-mobile header [data-photo]{font-size:12px;padding:8px 10px}
 .room-mobile-actions{gap:5px}
 .room-mobile-actions button{font-size:12px;padding:8px}
 .room-mobile-actions [data-state]{font-size:10px;max-width:90px}
 .room-mobile-tray{padding-inline:7px}
 .room-mobile-hotspots button{font-size:9px;max-width:90px;padding:4px 5px}
}
@media(max-height:650px) and (max-width:760px){
 .room-mobile:not([hidden]){grid-template-rows:48px minmax(80px,1fr) auto}
 .room-mobile-tray{max-height:50dvh}
 .room-mobile-swatches{max-height:78px}
}

/* Mobile polish: legible finishes, reachable menu, and stable viewport. */
@media(max-width:760px){
 .room-mobile:not([hidden]){height:100dvh;height:100svh;min-height:0}
 .room-mobile header details{position:relative}
 .room-mobile header details[open]{z-index:10}
 .room-mobile header details[open] button{position:relative!important;display:block;top:auto!important;right:auto!important;width:100%;min-height:44px;box-shadow:none!important;padding:11px 12px;text-align:left;white-space:nowrap}
 .room-mobile header details[open] summary{background:#f8f2f5}
 .room-mobile header details[open]{justify-self:end}
 .room-mobile header details[open]::after{content:"";position:absolute;right:0;top:100%;width:172px;height:0;pointer-events:none}
 .room-mobile header details[open] button{background:white}
 .room-mobile header details[open] button:first-of-type{border-radius:12px 12px 0 0}
 .room-mobile header details[open] button:last-of-type{border-radius:0 0 12px 12px}
 .room-mobile header details[open] button{position:absolute!important;right:0!important;top:100%!important;transform:none!important;width:172px;box-shadow:0 10px 28px #0002!important}.room-mobile header details[open] button:nth-of-type(2){top:calc(100% + 44px)!important}.room-mobile header details[open] button:nth-of-type(3){top:calc(100% + 88px)!important}
 .room-mobile-tray{flex-shrink:0}
 .room-mobile-swatches{min-height:94px;max-height:110px}
 .room-mobile-swatches>div{flex-basis:78px;min-width:0}
 .room-mobile-swatches button:first-child{min-height:58px}
 .room-mobile-swatch-name{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-align:center;font-size:10px;color:#544d52;margin-top:5px}
 .room-mobile.expanded .room-mobile-swatches{max-height:min(31dvh,250px)}
 .room-mobile.expanded .room-mobile-swatches>div{min-width:0}
 .room-mobile-hotspots button{line-height:1.2;white-space:normal;max-width:110px;overflow-wrap:break-word}
 .room-mobile button:focus-visible,.room-mobile input:focus-visible,.room-mobile select:focus-visible,.room-mobile summary:focus-visible{outline:2px solid #9e174b;outline-offset:2px}
}
@media(max-width:390px){
 .room-mobile-swatches>div{flex-basis:70px}
 .room-mobile-swatch-name{font-size:9px}
 .room-mobile-actions [data-render]{flex:1 1 100%;min-height:44px}
 .room-mobile-stage{min-height:100px}
}

/* Review menu now has five actions: use a contained dropdown rather than per-item absolute positions. */
@media(max-width:760px){
 .room-mobile header details[open]{position:absolute!important;top:6px;right:8px;z-index:20;width:min(215px,calc(100vw - 16px));max-height:min(76dvh,430px);overflow-y:auto;background:#fff;border:1px solid #eee3e9;border-radius:16px;box-shadow:0 15px 40px rgba(30,20,25,.18);padding:6px;justify-self:unset}
 .room-mobile header details[open] summary{display:grid;place-items:center;margin-left:auto}
 .room-mobile header details[open] button,
 .room-mobile header details[open] button:nth-of-type(2),
 .room-mobile header details[open] button:nth-of-type(3){position:static!important;top:auto!important;right:auto!important;display:block!important;transform:none!important;width:100%;max-width:100%;min-height:44px;border-radius:10px!important;box-shadow:none!important;text-align:left;white-space:normal;overflow-wrap:break-word}
 .room-mobile header details[open] button:focus-visible{outline:2px solid #9e174b;outline-offset:-2px}
}

/* Keep the full photo visible and reserve space for the finish controls. */
@media(max-width:760px){
 .room-mobile:not([hidden]){grid-template-rows:auto minmax(0,min(50svh,430px)) minmax(0,1fr);}
 .room-mobile header{border-bottom:1px solid #eee7eb}
 .room-mobile-stage{min-height:0;margin:8px 10px;border-radius:16px;background:#eeeae8}
 .room-mobile-tray{max-height:none;overflow:auto;overscroll-behavior:contain;justify-content:flex-start;align-items:stretch;padding-inline:12px;border:1px solid #eee7eb;border-bottom:0}
 .room-mobile-tray > *{flex-shrink:0}
 .room-mobile-tray .room-mobile-handle{flex:0 0 22px;margin:0 auto}
 .room-mobile-actions{display:grid;grid-template-columns:auto auto minmax(0,1fr);gap:6px}
 .room-mobile-actions [data-state]{min-width:0;max-width:none;text-align:right}
 .room-mobile-actions [data-render]{grid-column:1/-1;min-height:44px;background:#721238;color:#fff;border-radius:10px}
 .room-mobile-filters{display:grid;grid-template-columns:minmax(0,1fr) 44px;gap:6px}
 .room-mobile-filters select,.room-mobile-filters input{box-sizing:border-box;width:100%;max-width:none;min-height:44px;border-radius:10px;padding-inline:9px}
 .room-mobile-filters select{grid-column:1/-1}
 .room-mobile-filters button{min-height:44px;border-radius:10px}
 .room-mobile-swatches button:first-child{border-radius:10px}
}
@media(max-width:760px) and (max-height:650px){
 .room-mobile:not([hidden]){grid-template-rows:auto minmax(0,42svh) minmax(0,1fr)}
}

/* Roomvo-style mobile regeneration action: always reachable above catalogue tools. */
@media(max-width:760px){
.room-mobile-tray .room-generate-look{display:block;flex:0 0 auto;width:calc(100% - 24px);min-height:48px;margin:8px 12px 10px;border:0;border-radius:12px;background:#dc1e62;color:#fff;font:650 14px/1.2 -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;box-shadow:0 5px 18px #dc1e6226}
.room-mobile-tray .room-generate-look:disabled{opacity:.5;box-shadow:none}
.room-mobile-tray .room-generate-look:focus-visible{outline:3px solid #812044;outline-offset:2px}
}

/* Compact premium mobile editor header, no oversized wrapping actions. */
@media(max-width:760px){
.room-mobile:not([hidden]) header{box-sizing:border-box;display:grid!important;grid-template-columns:44px minmax(0,1fr) 44px!important;grid-template-rows:46px auto!important;column-gap:8px!important;row-gap:0!important;align-items:center!important;padding:4px 14px 8px!important;min-height:0!important;background:#fff!important;border-bottom:1px solid #eee9ec!important;border-radius:0!important;box-shadow:none!important}
.room-mobile header [data-close]{grid-column:1;grid-row:1;width:40px!important;height:40px!important;min-height:40px!important;padding:8px!important;border:0!important;background:transparent!important}
.room-mobile header [data-close] svg{width:20px!important;height:20px!important;stroke:#262026!important;stroke-width:1.7!important}
.room-mobile header [data-photo]{grid-column:2;grid-row:1;justify-self:center!important;display:inline-flex!important;align-items:center;justify-content:center;gap:7px;width:auto!important;max-width:100%!important;min-height:36px!important;height:36px!important;padding:7px 13px!important;border-radius:999px!important;background:#fcebf1!important;color:#ad2455!important;font-size:12px!important;font-weight:600!important;letter-spacing:0!important;box-shadow:none!important}
.room-mobile header [data-photo] svg{width:16px!important;height:16px!important;stroke:currentColor!important;fill:none!important}
.room-mobile header details{grid-column:3;grid-row:1;justify-self:end!important}
.room-mobile header details:not([open]) summary{width:40px!important;height:40px!important;min-height:40px!important;padding:8px!important;background:transparent!important}
.room-mobile header .room-result-actions{grid-column:1/-1;grid-row:2;display:flex!important;align-items:center;justify-content:flex-end;gap:8px;width:100%;min-height:0;margin:0;padding:0!important;background:transparent!important;border:0!important}
.room-mobile header .room-result-actions button:not([hidden]){display:inline-flex!important;align-items:center;justify-content:center;min-height:32px!important;height:32px!important;width:auto!important;padding:5px 12px!important;border-radius:9px!important;font-size:12px!important;font-weight:600!important;line-height:1!important;box-shadow:none!important}
.room-mobile header .room-result-actions [data-share]{border:1px solid #eee5ea!important;background:#fff!important;color:#40323b!important}
.room-mobile header .room-result-actions [data-quote]{border:0!important;background:#861c49!important;color:#fff!important}
.room-mobile header .room-result-actions button[hidden]{display:none!important}
.room-mobile header .room-result-actions:has(>button[hidden]:first-child + button[hidden]){display:none!important}
}

/* Single-line navigation: Share and Quote live inside the overflow menu. */
@media(max-width:760px){
.room-mobile:not([hidden]) header{grid-template-rows:46px!important;padding:4px 14px!important}
.room-mobile header details .room-result-actions{display:block!important;grid-column:auto!important;grid-row:auto!important;width:100%!important;padding:5px 0 0!important;margin-top:5px!important;border-top:1px solid #f0e9ed!important}
.room-mobile header details:not([open]) .room-result-actions{display:none!important}
.room-mobile header details[open] .room-result-actions button:not([hidden]){position:static!important;display:block!important;width:100%!important;height:auto!important;min-height:42px!important;margin:0!important;padding:11px 12px!important;text-align:left!important;border:0!important;border-radius:9px!important;background:#fff!important;color:#352b31!important;font-size:13px!important;font-weight:500!important;box-shadow:none!important}
.room-mobile header details[open] .room-result-actions [data-quote]:not([hidden]){color:#ba245b!important;font-weight:650!important}
.room-mobile header details[open] .room-result-actions button[hidden]{display:none!important}
.room-mobile header details[open] .room-result-actions button:hover{background:#fdf0f5!important}
}
