/* Keep the photo itself stable while the browser handles touch and momentum. */
.property-mobile-photos{display:none}.photo-rail{display:flex;width:100%;height:100%;overflow-x:auto;overflow-y:hidden;scroll-snap-type:x mandatory;overscroll-behavior-x:contain;scrollbar-width:none;-webkit-overflow-scrolling:touch;isolation:isolate}.photo-rail::-webkit-scrollbar{display:none}.photo-slide{position:relative;display:grid;place-items:center;flex:0 0 100%;width:100%;min-width:0;height:100%;padding:0;border:0;border-radius:0;scroll-snap-align:start;scroll-snap-stop:always;background:#edf0f3;overflow:hidden}.photo-slide img{display:block;width:100%;height:100%;object-fit:contain;user-select:none}.photo-slide img[hidden]{display:none}.photo-load-error{font-size:14px;color:#607086}.photo-rail:focus-visible{outline:2px solid #3265eb;outline-offset:-3px}
#room-view{background:none!important;aspect-ratio:auto;width:100%;height:clamp(260px,55svh,730px);min-height:0;border-radius:8px;overflow:hidden}#room-view[hidden]{display:none}.gallery-dialog #room-tabs{display:flex;flex-wrap:nowrap;justify-content:flex-start;overflow-x:auto;overflow-y:hidden;max-height:none;gap:8px;scrollbar-width:none;padding:6px 0 2px;position:relative}.gallery-dialog #room-tabs button{flex:0 0 80px;width:80px;position:relative;padding:0;border:2px solid transparent;border-radius:6px;overflow:hidden}.gallery-dialog #room-tabs button[aria-pressed=true]{border-color:#2454d6}.gallery-dialog .room-thumbnail{height:58px;margin:0;border-radius:0}.gallery-dialog #room-tabs button>span{position:absolute;bottom:3px;right:5px;color:#fff;background:#15263aaa;border-radius:3px;padding:1px 4px;font-size:11px}.gallery-dialog .photo-next-step{display:none}.gallery-dialog .room-navigation{margin:12px 0}.gallery-dialog .room-navigation .round-button{width:44px;height:44px}.gallery-dialog.overview-open #room-tabs,.gallery-dialog.overview-open .room-navigation{display:none}#photo-overview button{aspect-ratio:4/3}#photo-overview img{height:100%;object-fit:cover}
@media(max-width:750px){
 .property-dialog{height:100dvh;max-height:100dvh;scroll-behavior:auto;overflow-x:hidden}.property-dialog .property-header{min-height:58px;padding:env(safe-area-inset-top) 18px 0;gap:16px}.property-header .back-to-homes{min-width:0;font-size:14px;gap:7px;min-height:50px}.property-header .property-header-actions{min-width:0;gap:20px}.property-header-actions button{min-height:44px}.property-header-actions button>span{display:none}.property-header .property-brand{display:none}.property-body{padding-top:0;--property-gutter:20px;padding-left:20px;padding-right:20px}.property-mobile-photos{display:block;margin:0 -20px}.property-mobile-photos #property-photo-rail{height:auto;aspect-ratio:4/3;width:100%;max-height:55svh}.property-mobile-photos .photo-slide{background:#e8edf1}.mobile-photo-footer{display:flex;align-items:center;gap:12px;padding:10px 18px;border-bottom:1px solid #e6ebef;background:#fff;min-height:54px;font-size:12px}.mobile-photo-footer>span{color:#778392;flex:1}.mobile-photo-footer button{padding:8px 0;font-size:13px;color:#244c85;min-height:36px}.property-dialog #property-gallery,.property-dialog .property-media-nav{display:none}.property-dialog .property-identity{padding:23px 0 20px}.property-dialog .property-identity h2{font-family:Arial,Helvetica,sans-serif;font-size:clamp(24px,6.2vw,32px);line-height:1.2;letter-spacing:-.8px}.property-identity .eyebrow{margin-bottom:9px}.property-dialog .property-asking{display:flex;gap:8px 16px;margin-top:12px}.property-asking #property-price{order:0;font-size:27px}.property-asking #property-facts{order:1;flex-basis:100%;font-size:15px;line-height:1.5}.property-asking #property-attribution{order:2;flex-basis:100%;font-size:12px;line-height:1.6;margin:3px 0 0}.property-asking #property-disclaimer{order:3;flex-basis:100%;margin:0;font-size:12px}.property-asking #property-disclaimer:empty{display:none}.property-dialog .property-possibilities{padding:18px;border-radius:12px;margin-bottom:24px}.property-dialog .property-possibilities h3{font-size:23px}.property-dialog .property-possibilities .fit-summary strong{font-size:23px}.property-dialog .property-possibilities .next-step-line{display:block}.property-mobile-action{gap:12px;padding:12px 20px max(12px,env(safe-area-inset-bottom));box-shadow:0 -5px 25px #12243a08}.property-mobile-action strong{font-size:18px}.property-mobile-action .primary-button{min-height:46px;border-radius:8px}.property-dialog .property-tabs{top:58px}
 .gallery-dialog[open]{display:flex;flex-direction:column;gap:0;width:100%;max-width:100%;height:100dvh;max-height:100dvh;margin:0;padding:0;border-radius:0;overflow:hidden;background:#111a23;color:white}.gallery-dialog::backdrop{background:#111a23}.gallery-dialog .dialog-heading{flex:none;align-items:center;margin:0;padding:max(15px,env(safe-area-inset-top)) 18px 12px;min-height:66px}.gallery-dialog .dialog-heading .eyebrow{display:none}.gallery-dialog .dialog-heading h2{font:500 15px/1.4 Arial,sans-serif;color:#fff;letter-spacing:0}.gallery-dialog .close-button{width:44px;height:44px;flex:none;color:#fff;background:#ffffff14;border-color:#ffffff28}.gallery-dialog .gallery-tools{flex:none;justify-content:flex-start;gap:8px;padding:0 18px 12px;margin:0}.gallery-dialog .gallery-tools button{color:#e8eef7;background:#ffffff0b;border-color:#ffffff25;min-height:38px;font-size:13px}.gallery-dialog #room-view{flex:1;min-height:0;height:auto;width:100%;border-radius:0;margin:0}.gallery-dialog .photo-slide{background:#111a23}.gallery-dialog .photo-load-error{color:#cbd5e1}.gallery-dialog .room-navigation{flex:none;margin:0;padding:14px 22px 10px}.gallery-dialog .room-navigation strong{font-size:13px;color:#eef3fa}.gallery-dialog .room-navigation #room-counter{font-size:12px;color:#a7b5c5}.gallery-dialog .room-navigation .round-button{background:#ffffff0b;border-color:#ffffff2b;color:white}.gallery-dialog #room-tabs{flex:none;padding:4px 16px max(14px,env(safe-area-inset-bottom));max-height:100px}.gallery-dialog #room-tabs button{flex-basis:74px;width:74px;min-width:74px}.gallery-dialog .room-thumbnail{height:55px}.gallery-dialog #photo-overview{flex:1;min-height:0;max-height:none;margin:0;padding:0 10px max(18px,env(safe-area-inset-bottom));gap:6px;grid-template-columns:1fr 1fr;overflow-y:auto}.gallery-dialog.overview-open #room-view{display:none}
}
@media(prefers-reduced-motion:reduce){.photo-rail{scroll-behavior:auto}}
@media(max-width:750px) and (max-height:500px){.gallery-dialog #room-tabs{display:none}.gallery-dialog .dialog-heading{padding:7px 16px;min-height:44px}.gallery-dialog .gallery-tools{position:absolute;right:72px;top:9px;padding:0}.gallery-dialog #gallery-fullscreen{display:none}.gallery-dialog .dialog-heading h2{max-width:52vw;font-size:13px}.gallery-dialog .room-navigation{padding:5px 20px}.gallery-dialog .room-navigation .round-button{width:36px;height:36px}.gallery-dialog .room-navigation strong{display:none}}

/* Mobile browsing is a continuous vertical photo story; a tap opens detail. */
#gallery-feed-hint{display:none}
@media(max-width:750px){
 .property-mobile-photos .photo-rail{overflow:hidden}
 .mobile-photo-footer #property-mobile-photo-count{margin-right:auto;min-height:44px;font-weight:600}
 .gallery-dialog #gallery-fullscreen{display:none}
 .gallery-dialog.overview-open .gallery-tools{position:static;padding:0 18px 14px}
 .gallery-dialog.overview-open #gallery-overview{display:none}
 .gallery-dialog.overview-open #gallery-feed-hint{display:block;color:#b7c3d0;font-size:12px;line-height:1.5}
 .gallery-dialog #photo-overview{display:block;position:relative;padding:0 0 max(18px,env(safe-area-inset-bottom));overflow-x:hidden;overflow-y:auto;overscroll-behavior-y:contain;-webkit-overflow-scrolling:touch;scroll-behavior:auto}
 .gallery-dialog #photo-overview[hidden]{display:none}
 .gallery-dialog #photo-overview button{display:block;width:100%;aspect-ratio:auto;margin:0 0 10px;border-radius:0;background:#17232f;overflow:hidden}
 .gallery-dialog #photo-overview img{display:block;width:100%;height:auto;aspect-ratio:auto var(--photo-ratio,3/2);object-fit:contain}
 .gallery-dialog #photo-overview img[hidden]{display:none}
 .gallery-dialog #photo-overview .photo-load-error{margin:0;min-height:220px;display:grid;place-items:center}
 .gallery-dialog #photo-overview button>span{left:auto;right:14px;bottom:14px;border-radius:20px;padding:5px 10px;background:#101d2bc9;font-size:11px;letter-spacing:.04em}
 .gallery-dialog #photo-overview button:focus-visible{outline:2px solid #9cbbff;outline-offset:-3px}
}

/* A centred strip that overflows pushes its first thumbnails past the left edge,
   out of scroll reach (photo 1 of 98 showed thumbnails from 42), so the
   #room-tabs rule above now starts at the left.
   A grid track sized "auto" lets an image's height:100% fall back to its natural
   height, so a 3:2 photo in a wide frame rendered 1008px tall inside 495px and
   lost its bottom half. Give the one cell a definite size so contain can work. */
.photo-slide{grid-template:minmax(0,1fr)/minmax(0,1fr)}.photo-slide img{min-width:0;min-height:0}

/* Desktop gets the same continuous vertical photo story as mobile: full screen,
   dark, every photograph uncropped at its own shape, a tap opens it alone. */
@media(min-width:751px){
 .gallery-dialog[open]{display:flex;flex-direction:column;width:100vw;max-width:100vw;height:100dvh;max-height:100dvh;margin:0;padding:0;border:0;border-radius:0;overflow:hidden;background:#111a23;color:#fff}
 .gallery-dialog::backdrop{background:#111a23}
 .gallery-dialog .dialog-heading{flex:none;align-items:center;margin:0;padding:20px 32px 10px}
 .gallery-dialog .dialog-heading .eyebrow{color:#8fa2b7}
 .gallery-dialog .dialog-heading h2{color:#fff;font-size:26px}
 .gallery-dialog .close-button{color:#fff;background:#ffffff14;border-color:#ffffff28}
 .gallery-dialog .gallery-tools{flex:none;display:flex;align-items:center;gap:8px;margin:0;padding:0 32px 14px}
 .gallery-dialog .gallery-tools button{color:#e8eef7;background:#ffffff0b;border-color:#ffffff25}
 .gallery-dialog.overview-open #gallery-feed-hint{display:block;margin-right:auto;color:#b7c3d0;font-size:13px}
 .gallery-dialog #photo-overview{display:block;flex:1;min-height:0;max-height:none;position:relative;margin:0;padding:0 32px 40px;overflow-x:hidden;overflow-y:auto;overscroll-behavior-y:contain}
 .gallery-dialog #photo-overview[hidden]{display:none}
 .gallery-dialog #photo-overview button{display:block;width:100%;max-width:1180px;aspect-ratio:auto;margin:0 auto 14px;border-radius:10px;background:transparent;overflow:hidden}
 .gallery-dialog #photo-overview img{display:block;width:100%;height:auto;max-height:calc(100dvh - 150px);aspect-ratio:auto var(--photo-ratio,3/2);object-fit:contain}
 .gallery-dialog #photo-overview img[hidden]{display:none}
 .gallery-dialog #photo-overview .photo-load-error{margin:0;min-height:320px;display:grid;place-items:center;color:#cbd5e1}
 .gallery-dialog #photo-overview button>span{left:auto;right:16px;bottom:16px;border-radius:20px;padding:6px 11px;background:#101d2bc9;font-size:12px;letter-spacing:.04em}
 .gallery-dialog #photo-overview button:focus-visible{outline:2px solid #9cbbff;outline-offset:-3px}
 .gallery-dialog #room-view{flex:1;min-height:0;height:auto;width:100%;max-width:none;aspect-ratio:auto;margin:0;border-radius:0}
 .gallery-dialog .photo-slide{background:#111a23}
 .gallery-dialog .room-navigation{flex:none;margin:0;padding:12px 32px 8px}
 .gallery-dialog .room-navigation strong{color:#eef3fa}
 .gallery-dialog .room-navigation #room-counter{color:#a7b5c5}
 .gallery-dialog .room-navigation .round-button{background:#ffffff0b;border-color:#ffffff2b;color:#fff}
 .gallery-dialog #room-tabs{flex:none;padding:4px 32px 18px}
 .gallery-dialog.overview-open #room-tabs,.gallery-dialog.overview-open .room-navigation{display:none}
}

/* The viewer's contents sit in a shell that lays out as if absent, except in
   full screen, where the shell is the full-screen element (a dialog cannot be). */
.gallery-shell{display:contents}
.gallery-shell:fullscreen{display:flex;flex-direction:column;width:100vw;height:100vh;background:#111a23;color:#fff;overflow:hidden}
.gallery-shell:fullscreen #room-view{flex:1;min-height:0;height:auto}
.gallery-shell:fullscreen #photo-overview{flex:1;min-height:0}
/* Two sharp columns when a listing's photos are too small for one wide column. */
@media(min-width:1100px){
 /* Wrapped flex, not grid: each tile needs a definite width for its image's
    percentage width to resolve, or the rows collapse to a few pixels. */
 .gallery-dialog #photo-overview.feed-two{display:flex;flex-wrap:wrap;justify-content:center;align-content:flex-start;column-gap:14px}
 .gallery-dialog #photo-overview.feed-two[hidden]{display:none}
 .gallery-dialog #photo-overview.feed-two button{flex:0 0 auto;width:min(580px,calc(50% - 7px));margin:0 0 14px;max-width:none}
 .gallery-dialog #photo-overview.feed-two img{max-height:none}
}

/* While any viewer is open the page behind must not show its own scrollbar: it
   painted over the gallery's and never moved with the photos. */
html:has(dialog[open]){overflow:hidden}
