.ad-placement{clear:both;display:flex;flex-direction:column;align-items:center;gap:6px;max-width:100%;margin:24px 0;padding:12px 0;color:var(--muted,#656277);box-sizing:border-box;flex:0 0 auto}
.ad-placement-label{font:500 10px/1.4 var(--sans,system-ui);letter-spacing:.08em;text-transform:uppercase}
.ad-placeholder{width:var(--ad-width,320px);height:var(--ad-height,100px);max-width:100%;box-sizing:border-box;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;padding:6px;border:1px dashed #b6adc9;border-radius:8px;background:repeating-linear-gradient(135deg,#b9aad00b 0 8px,#b9aad018 8px 16px);text-align:center;color:inherit}
.ad-placeholder strong{font-size:12px}.ad-placeholder span{font-size:10px;line-height:1.3}.ad-placeholder small{font-size:9px}.ad-placement[data-ad-size$="x50"] .ad-placeholder small{display:none}
.ad-house{width:var(--ad-width,320px);min-height:var(--ad-height,100px);max-width:100%;box-sizing:border-box;display:flex;align-items:center;justify-content:center;gap:16px;padding:8px 14px;border:1px solid #c8b5dd;border-radius:10px;background:linear-gradient(115deg,#f5eefc,#fff8ec);color:#3e2b59;font-family:var(--sans,system-ui);text-align:left}
.ad-house strong,.ad-house span{display:block}.ad-house strong{font-size:14px;line-height:1.3}.ad-house span{font-size:11px;line-height:1.4;margin-top:4px}.ad-house button{flex-shrink:0;min-height:44px;border:1px solid #8a68ac;border-radius:8px;padding:8px 12px;background:#fff;color:#493064;font:600 12px/1.3 var(--sans,system-ui);cursor:pointer}.ad-house button:focus-visible{outline:3px solid #7954a3;outline-offset:3px}
.ad-placement[data-ad-format="rectangle"] .ad-house{flex-direction:column;gap:20px;text-align:center}.ad-placement[data-ad-size$="x60"] .ad-house span{display:none}
html[data-plan="pro"] .ad-placement{display:none!important}
.rewarded-video-dialog{width:min(480px,calc(100% - 24px));max-height:calc(100dvh - 32px);overflow:auto;box-sizing:border-box;padding:24px;border:1px solid #cec6e1;border-radius:20px;background:var(--panel,#fff);color:var(--ink,#25213b)}
.rewarded-video-dialog::backdrop{background:#15102499}.rewarded-video-dialog p{line-height:1.6}.rewarded-video-stage{aspect-ratio:16/9;background:#242038;color:#fff;display:grid;place-content:center;gap:10px;border-radius:12px;text-align:center;padding:12px;box-sizing:border-box}.rewarded-video-stage progress{max-width:100%}.rewarded-video-actions{display:flex;flex-wrap:wrap;gap:12px;margin-top:18px}.rewarded-video-dialog [role=status]{min-height:24px;font-size:13px}
html[data-app-theme=dark] .rewarded-video-dialog{background:#242139;color:#f5f0ff}
:root #appShell[data-active-tab="library"] #freePlanBanner{margin:8px 0;padding:8px 0;width:100%}
:root #appShell[data-active-tab="library"] main{display:flex!important;flex-direction:column!important}
:root #appShell[data-active-tab="library"] main>#libraryView{flex:1 1 0!important;height:auto!important;min-height:0!important}
:root #appShell[data-active-tab="library"] #freePlanBanner{margin-bottom:calc(8px + var(--ad-bottom-inset,0px))}

#appCompanion[data-ad-offset]{translate:0 calc(-1 * var(--ad-companion-offset,0px))}

/* Let the room shrink around its controls with or without an ad. */
:root #appShell[data-active-tab="library"] #libraryView>.room-experience:not(.is-small-fullview){flex:1 1 0!important;min-height:0!important;overflow:hidden}
:root #appShell[data-active-tab="library"] .room-experience:not(.is-small-fullview)>#roomViewport{flex:1 1 0!important;height:auto!important;min-height:0!important}
:root #appShell[data-active-tab="library"] .room-experience>:is(.library-controls,.library-controls-show,.legacy-room-dock,.app-room-navigation){flex-shrink:0}

/* Desktop Library fills the space below the header, including ad-free previews. */
@media(min-width:761px){
:root #appShell[data-preview="desktop"][data-active-tab="library"] .main-wrapper{display:flex!important;flex-direction:column;min-height:0!important}
:root #appShell[data-preview="desktop"][data-active-tab="library"] .main-wrapper>main{flex:1 1 0!important;height:auto!important;min-height:0!important}
:root #appShell[data-preview="desktop"][data-active-tab="library"] .main-wrapper>:is(.topbar,.prism-topbar){flex-shrink:0}
}
