/* Dark remains the default. The map and photographs keep their own colours. */
:root{color-scheme:dark}
:root[data-theme=light]{color-scheme:light}
.map-style-switch .theme-toggle{display:grid;place-items:center;min-width:38px;width:38px;min-height:34px;padding:0}
.theme-toggle .icon{width:17px;height:17px}
.theme-toggle .theme-moon{display:none}
:root[data-theme=light] .theme-toggle .theme-sun{display:none}
:root[data-theme=light] .theme-toggle .theme-moon{display:block}
@media(max-width:760px){.map-style-switch .theme-toggle{min-height:38px}}

/* Clear light glass uses a restrained white wash; the map stays visible beneath it.
   System high contrast keeps the existing native-colour accessibility layer. */
@media(forced-colors:none){
 :root[data-theme=light]{
  --glass-fill:rgba(249,249,249,.46);
  --glass-reflection:linear-gradient(135deg,rgba(255,255,255,.22),rgba(255,255,255,.1) 55%,rgba(255,255,255,.15));
  --glass-shadow:0 16px 48px rgba(0,0,0,.1);
  --theme-ink:#111;
  --theme-muted:#202020;
 }
 :root[data-theme=light] :is(.property-panel,.destination-card,.map-style-switch,
 .category-filters button,.map-controls>button,.zoom-controls,.overview-map-note,
 .atlas-pin__label,.map-loading,.map-status){
  color:var(--theme-ink);background:var(--glass-reflection),var(--glass-fill);
  box-shadow:var(--glass-shadow);border-color:transparent;
  -webkit-backdrop-filter:blur(12.06px) brightness(1.12);backdrop-filter:blur(12.06px) brightness(1.12);
 }
 :root[data-theme=light] .workspace.detail-mode .property-panel,
 :root[data-theme=light] .destination-card{
  --ink:var(--theme-ink);--line:rgba(0,0,0,.12);--glass-fill:rgba(249,249,249,.46);
  background:var(--glass-reflection),var(--glass-fill);
  -webkit-backdrop-filter:blur(13.4px) brightness(1.12);backdrop-filter:blur(13.4px) brightness(1.12);
 }
 :root[data-theme=light] body:not(.is-detail) .overview-map-note{
  background:var(--glass-reflection),var(--glass-fill);
 }
 :root[data-theme=light] .property-panel :is(h1,.section-title h2,.nearby-item strong),
 :root[data-theme=light] .destination-card h2{
  color:var(--theme-ink);text-shadow:none;
 }
 :root[data-theme=light] .property-panel :is(.detail-series,.property-heading>.eyebrow,
 .property-facts,.property-description,.amenities span,.booking-note,.section-title .eyebrow,
 .guide-intro,.nearby-item small,.route-disclosure){color:var(--theme-muted);text-shadow:none}
 :root[data-theme=light] .property-panel :is(.property-facts,.property-description){color:#181818}
 :root[data-theme=light] .property-panel .property-facts span{background:rgba(0,0,0,.045);border-color:transparent}
 /* Local backing keeps scrolling copy from ghosting through sticky controls. */
 :root[data-theme=light] .property-panel .detail-topbar{
  background:rgba(247,247,247,.9);border-color:transparent;color:var(--theme-ink);
 }
 :root[data-theme=light] .property-panel .text-button{color:var(--theme-ink)}
 :root[data-theme=light] .property-panel :is(.round-button,.sheet-toggle){
  color:var(--theme-ink);background:rgba(0,0,0,.065);border-color:transparent;
 }
 :root[data-theme=light] .property-panel :is(.round-button,.sheet-toggle):hover{background:rgba(0,0,0,.12)}
 :root[data-theme=light] .property-panel .round-button[aria-pressed=true]{color:#ad4431}
 :root[data-theme=light] .property-panel .round-button[aria-pressed=true] .icon{fill:#edb7aa}
 :root[data-theme=light] .property-panel .booking-button{
  color:var(--theme-ink);background:rgba(255,255,255,.35);border-color:transparent;
  box-shadow:0 5px 18px rgba(0,0,0,.08);
 }
 :root[data-theme=light] .property-panel .booking-button:hover{background:rgba(255,255,255,.58)}
 :root[data-theme=light] .property-panel .nearby-item{background:rgba(255,255,255,.14);border-color:transparent}
 :root[data-theme=light] .property-panel .nearby-item:hover{background:rgba(255,255,255,.32)}
 :root[data-theme=light] .property-panel .nearby-item.selected{background:rgba(0,0,0,.1)}
 :root[data-theme=light] .property-panel .nearby-item.selected strong{color:var(--theme-ink)}
 :root[data-theme=light] .property-panel :is(.guide-decoration .icon,.nearby-item>.icon){color:#303030}
 :root[data-theme=light] :is(.property-panel,.destination-card) .service-icon{
  color:#252525;background:rgba(0,0,0,.065);border-color:transparent;
 }

 /* Image controls use their own light backing over any photo. */
 :root[data-theme=light] .property-panel :is(.gallery-navigation button,.gallery-navigation>span,
 .gallery-autoplay,.expand-photo),
 :root[data-theme=light] .destination-photos button>span{
  color:#181818;background:rgba(255,255,255,.6);border-color:transparent;
  -webkit-backdrop-filter:blur(8.04px);backdrop-filter:blur(8.04px);
 }
 :root[data-theme=light] .property-panel :is(.gallery-navigation button,.gallery-autoplay):hover{background:rgba(255,255,255,.8)}
 :root[data-theme=light] .destination-photos button{background-color:#ececec;background-clip:padding-box}
 :root[data-theme=light] .property-panel .photo-thumb.active{border-color:transparent;box-shadow:none}

 /* Map controls and labels change theme; the map tiles and coloured pins do not. */
 :root[data-theme=light] :is(.map-style-switch button,.map-controls button,.category-filters button){color:var(--theme-ink)}
 :root[data-theme=light] .map-controls button:hover{background:rgba(0,0,0,.09)}
 :root[data-theme=light] .map-controls>button:hover{background:var(--glass-reflection),rgba(255,255,255,.6)}
 :root[data-theme=light] .zoom-controls button+button{border-color:transparent}
 :root[data-theme=light] .map-style-switch button[aria-pressed=true]{background:rgba(0,0,0,.11);color:#171717;box-shadow:none}
 :root[data-theme=light] .map-style-switch button:not([aria-pressed=true]):hover{background:rgba(0,0,0,.055)}
 :root[data-theme=light] .category-filters button:hover{background:var(--glass-reflection),rgba(255,255,255,.62)}
 :root[data-theme=light] .category-filters button[aria-pressed=true]{background:rgba(47,47,47,.9);color:#fff;border-color:transparent;box-shadow:var(--glass-shadow)}
 :root[data-theme=light] .category-filters button[aria-pressed=true]:hover{background:rgba(30,30,30,.96)}
 :root[data-theme=light] :is(.atlas-pin__label,.atlas-pin--service .atlas-pin__label){
  background:var(--glass-reflection),rgba(249,249,249,.58);color:var(--theme-ink);border-color:transparent;
  box-shadow:0 6px 20px rgba(0,0,0,.14);
 }
 :root[data-theme=light] .atlas-pin__label small{color:var(--theme-muted)}
 :root[data-theme=light] :is(.overview-map-note div>span,.overview-map-note .note-arrow){color:var(--theme-muted)}
 :root[data-theme=light] .map-loading .loading-orbit,
 :root[data-theme=light] .destination-card .small-spinner{border-color:rgba(0,0,0,.16);border-top-color:#484848}
 :root[data-theme=light] .maplibregl-ctrl-attrib{
  background:rgba(249,249,249,.6)!important;color:#181818!important;border-color:transparent!important;
 }
 :root[data-theme=light] .maplibregl-ctrl-attrib a{color:#181818!important}
 :root[data-theme=light] .maplibregl-ctrl-attrib-button{filter:none}

 :root[data-theme=light] .destination-heading{background:rgba(247,247,247,.9);border-color:transparent}
 :root[data-theme=light] .destination-heading .eyebrow{color:var(--theme-muted)}
 :root[data-theme=light] .destination-heading>.round-button{background:rgba(0,0,0,.06);color:var(--theme-ink);border-color:transparent}
 :root[data-theme=light] .destination-heading>.round-button:hover{background:rgba(0,0,0,.12)}
 :root[data-theme=light] .destination-card :is(.route-summary,.route-estimate,p,
 .destination-location-note,.destination-photo-caption,.destination-source){color:var(--theme-muted)}
 :root[data-theme=light] .destination-card :is(.route-summary,strong){color:#181818}
 :root[data-theme=light] .destination-actions a{background:rgba(0,0,0,.065);color:var(--theme-ink);border-color:transparent}
 :root[data-theme=light] .destination-actions .directions-button{background:rgba(0,0,0,.12)}
 :root[data-theme=light] .destination-actions a:hover{background:rgba(0,0,0,.19)}
 :root[data-theme=light] .destination-source:hover{color:#171717}

 :root[data-theme=light] .gallery-dialog{
  color:var(--theme-ink);background:var(--glass-reflection),rgba(249,249,249,.92);
  border-color:transparent;box-shadow:var(--glass-shadow);
 }
 :root[data-theme=light] .gallery-dialog::backdrop{background:rgba(215,215,215,.45)}
 :root[data-theme=light] :is(.lightbox-top button,.lightbox-stage>button){background:rgba(0,0,0,.07);color:var(--theme-ink);border-color:transparent}
 :root[data-theme=light] :is(.lightbox-top button,.lightbox-stage>button):hover{background:rgba(0,0,0,.14)}
 :root[data-theme=light] .lightbox-credit{color:var(--theme-muted)}
 :root[data-theme=light] .lightbox-credit:hover{color:#171717}
 :root[data-theme=light] .toast{background:rgba(249,249,249,.96);color:var(--theme-ink);box-shadow:0 6px 30px rgba(0,0,0,.16)}

 /* Dual-tone photo focus remains visible against both pale and dark images. */
 :root[data-theme=light] :is(.gallery-main,.photo-thumb,.destination-photos button):focus-visible::after{
  border-color:#252525;box-shadow:0 0 0 2px rgba(255,255,255,.95);
 }
 :root[data-theme=light] :is(.zoom-controls>button,.category-filters button,
 .map-style-switch button,.sheet-toggle):focus-visible{outline-color:#303030}
 :root[data-theme=light] .category-filters button[aria-pressed=true]:focus-visible{outline-color:#fff}

 @media(max-width:760px){
  :root[data-theme=light] .property-panel .detail-topbar{background:rgba(247,247,247,.92)}
  :root[data-theme=light] .destination-card .destination-actions{
   background:rgba(247,247,247,.92);border-color:transparent;box-shadow:0 -8px 18px rgba(0,0,0,.07);
  }
  :root[data-theme=light] .property-panel .property-facts span{background:none}
 }
 @supports not ((backdrop-filter:blur(1px)) or (-webkit-backdrop-filter:blur(1px))){
  :root[data-theme=light] :is(.property-panel,.destination-card,.map-style-switch,
  .category-filters button,.map-controls>button,.zoom-controls,.overview-map-note,.atlas-pin__label,
  .map-loading,.map-status,.gallery-dialog),
  :root[data-theme=light] .workspace.detail-mode .property-panel,
  :root[data-theme=light] body:not(.is-detail) .overview-map-note,
  :root[data-theme=light] .atlas-pin--service .atlas-pin__label,
  :root[data-theme=light] .property-panel .detail-topbar,
  :root[data-theme=light] .destination-heading,
  :root[data-theme=light] .destination-card .destination-actions{background:#f3f3f3}
  :root[data-theme=light] .category-filters button[aria-pressed=true]{background:#303030;color:#fff}
  :root[data-theme=light] .map-controls>button:hover{background:#fff}
  :root[data-theme=light] .maplibregl-ctrl-attrib{background:#f3f3f3!important}
 }
}
