/* Locations finder (page-templates/locations.php) + single store (single-location.php).
   Loaded together with contact.css (band, .info-card, .contact-map for the single page).
   Finder pattern: centered intro → Map/List tabs + search (map) or city chips (list)
   → map with floating store panel, or card grid. */

/* ---- Intro ---- */
.loc-page{background:#F7F8FA}
.loc-intro{padding-top:clamp(128px,14vw,168px);padding-bottom:clamp(1.75rem,3.5vw,2.75rem)}
.loc-intro-eyebrow{font-family:'Proxima Nova',system-ui,sans-serif;font-weight:800;font-size:clamp(1.15rem,2vw,1.45rem);letter-spacing:.2em;text-transform:uppercase;color:var(--ink);margin-bottom:1.6rem}
.loc-intro-logo{display:block;height:clamp(38px,4.6vw,52px);width:auto;margin:0 auto 1.6rem}
.loc-intro-title{font-family:'Cabin',sans-serif;font-weight:400;font-size:clamp(1.55rem,3.4vw,2.35rem);line-height:1.2;color:var(--ink);letter-spacing:-.01em;margin:0 auto 1.1rem;max-width:56rem}
.loc-intro-title strong{font-weight:700;color:var(--brand-deep)}
.loc-intro-text{font-size:clamp(15px,1.4vw,17px);color:rgba(38,38,36,.85);max-width:52rem;margin:0 auto}
.loc-intro-text strong{font-weight:700;color:var(--ink)}

/* ---- Toolbar: tabs | search (map) / chips (list) | spacer ---- */
.loc-toolbar{display:grid;grid-template-columns:minmax(0,1fr);gap:1rem;align-items:center;max-width:1230px;margin:0 auto 1.4rem}
@media(min-width:1024px){.loc-toolbar{grid-template-columns:200px minmax(0,1fr) 200px;gap:1.5rem}}
.loc-views{display:inline-flex;gap:.35rem;justify-self:center}
@media(min-width:1024px){.loc-views{justify-self:start}}
.loc-view-btn{display:inline-flex;align-items:center;gap:.45rem;font-family:'Cabin',sans-serif;font-weight:700;font-size:15px;color:var(--ink);background:transparent;border:0;border-radius:12px;padding:.75rem 1.1rem;cursor:pointer;transition:background-color .2s ease,color .2s ease,box-shadow .2s ease}
.loc-view-btn:hover{color:var(--brand-deep)}
.loc-view-btn[aria-selected="true"]{background:#fff;color:var(--brand-deep);box-shadow:0 4px 18px rgba(16,32,46,.10)}
.loc-views-spacer{display:none}
@media(min-width:1024px){.loc-views-spacer{display:block}}

.loc-search{position:relative;display:flex;align-items:center;width:100%;max-width:624px;justify-self:center;background:#fff;border:2px solid var(--brand-deep);border-radius:14px;padding:.4rem .4rem .4rem 1.4rem;box-shadow:0 6px 22px rgba(2,32,160,.06)}
.loc-search input{flex:1;min-width:0;border:0;outline:0;background:transparent;font-family:'Cabin',sans-serif;font-size:16px;color:var(--ink);padding:.7rem 0}
.loc-search input::placeholder{color:rgba(38,38,36,.55)}
.loc-search input:focus-visible{outline:0}
.loc-search:focus-within{box-shadow:0 0 0 4px rgba(34,114,206,.18)}
.loc-geo{flex:none;display:grid;place-items:center;width:46px;height:46px;border:0;border-radius:10px;background:rgba(2,32,160,.08);color:var(--brand-deep);cursor:pointer;transition:background-color .2s ease,color .2s ease}
.loc-geo:hover{background:var(--brand-deep);color:#fff}
.loc-geo.is-busy svg{animation:locSpin 1s linear infinite}
@keyframes locSpin{to{transform:rotate(360deg)}}

.loc-chips{display:none;flex-wrap:wrap;justify-content:center;gap:.5rem;justify-self:center;background:#fff;border:1px solid rgba(16,32,46,.08);border-radius:14px;padding:.4rem}
.loc-chip{font-family:'Cabin',sans-serif;font-weight:600;font-size:14.5px;color:var(--ink);background:#F1F3F7;border:0;border-radius:10px;padding:.65rem 1.1rem;cursor:pointer;transition:background-color .2s ease,color .2s ease}
.loc-chip:hover{background:rgba(2,32,160,.1);color:var(--brand-deep)}
.loc-chip[aria-pressed="true"]{background:var(--brand-deep);color:#fff}
.loc-finder.is-list .loc-search{display:none}
.loc-finder.is-list .loc-chips{display:flex}

.loc-msg{max-width:1230px;margin:-.4rem auto .9rem;text-align:center;font-size:14.5px;color:rgba(38,38,36,.7)}
.loc-msg:empty{display:none}

/* ---- Stage: map view (map + floating panel) ---- */
.loc-stage{position:relative;max-width:1230px;margin:0 auto}
.loc-map{position:relative;height:420px;border-radius:22px;overflow:hidden;background:#E6ECF4;z-index:0}
.loc-panel{position:relative;margin-top:1rem;background:#fff;border-radius:18px;box-shadow:0 1px 2px rgba(16,32,46,.04),0 12px 32px rgba(16,32,46,.10);padding:1rem .6rem .6rem 1rem;display:flex;flex-direction:column}
@media(min-width:1024px){
	.loc-map{height:min(640px,calc(100vh - 140px));min-height:500px}
	.loc-panel{position:absolute;z-index:2;top:16px;left:16px;bottom:16px;width:300px;margin:0}
}
.loc-panel-head{display:flex;align-items:center;justify-content:space-between;gap:.5rem;padding:0 .4rem .7rem 0}
.loc-panel-count{font-family:'Cabin',sans-serif;font-weight:700;font-size:14px;color:rgba(38,38,36,.55)}
.loc-reset{font-family:'Cabin',sans-serif;font-weight:700;font-size:14px;color:var(--brand-deep);background:none;border:0;cursor:pointer;text-decoration:underline;text-underline-offset:3px}
.loc-list{list-style:none;margin:0;padding:0 .4rem 0 0;display:grid;gap:.6rem;align-content:start}
@media(min-width:1024px){.loc-list{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:rgba(2,32,160,.35) transparent}}
.loc-item[hidden]{display:none}

.loc-card{position:relative;background:#fff;border:1px solid rgba(16,32,46,.10);border-radius:12px;overflow:hidden;transition:border-color .2s ease,box-shadow .2s ease}
.loc-card:hover{border-color:rgba(2,32,160,.35)}
.loc-item.is-active .loc-card{border-color:var(--brand-deep);box-shadow:0 0 0 1px var(--brand-deep)}
.loc-card-photo{display:none;background:rgba(34,114,206,.1)}
.loc-card-photo img{width:100%;height:100%;object-fit:cover;display:block}
.loc-card-body{padding:.85rem .85rem .9rem}
.loc-card-top{display:flex;align-items:flex-start;justify-content:space-between;gap:.5rem}
.loc-card-title{font-family:'Cabin',sans-serif;font-weight:700;font-size:15px;line-height:1.3;color:var(--ink);margin:0 0 .35rem}
.loc-card-title a{color:inherit;transition:color .2s ease}
.loc-card-title a:hover{color:var(--brand-deep)}
.loc-distance{flex:none;font-size:12px;font-weight:700;color:var(--brand-deep);background:rgba(2,32,160,.08);border-radius:999px;padding:.15rem .5rem;white-space:nowrap}
.loc-address{font-size:13.5px;line-height:1.5;color:rgba(38,38,36,.7);margin:0 0 .5rem}
.loc-open{font-size:12.5px;line-height:1.4;color:rgba(38,38,36,.7);margin:0 0 .7rem}
.loc-open b{font-weight:600}
.loc-open.is-open b{color:#15803D}
.loc-open.is-closed b{color:#C0262D}
.loc-actions{display:flex;flex-wrap:wrap;align-items:center;gap:.45rem}
.loc-pill{display:inline-flex;align-items:center;gap:.4rem;font-family:'Cabin',sans-serif;font-weight:600;font-size:13.5px;line-height:1;color:var(--ink);background:#fff;border:1px solid rgba(16,32,46,.16);border-radius:999px;padding:.6rem .95rem;transition:border-color .2s ease,color .2s ease}
.loc-pill:hover{border-color:var(--brand-deep);color:var(--brand-deep)}
.loc-pill-dir svg{color:var(--brand-sky)}
.loc-locate{display:grid;place-items:center;width:34px;height:34px;margin-left:auto;border-radius:999px;border:0;background:rgba(2,32,160,.07);color:var(--brand-deep);cursor:pointer;transition:background-color .2s ease,color .2s ease}
.loc-locate:hover{background:var(--brand-deep);color:#fff}
/* Map view keeps cards compact (store page is reachable via the title) */
.loc-stage[data-view="map"] .loc-actions .loc-pill:not(.loc-pill-dir){display:none}
.loc-empty{font-size:14.5px;color:rgba(38,38,36,.7);padding:1rem .4rem}

/* ---- Stage: list view (card grid, no map) ---- */
.loc-stage[data-view="list"] .loc-map{display:none}
.loc-stage[data-view="list"] .loc-panel{position:static;width:auto;margin:0;padding:0;background:transparent;box-shadow:none}
.loc-stage[data-view="list"] .loc-panel-head{display:none}
.loc-stage[data-view="list"] .loc-list{overflow:visible;padding:0;grid-template-columns:repeat(auto-fill,minmax(230px,1fr));gap:1rem}
.loc-stage[data-view="list"] .loc-card{height:100%;display:flex;flex-direction:column}
.loc-stage[data-view="list"] .loc-card-photo{display:block;aspect-ratio:16/10}
.loc-stage[data-view="list"] .loc-card-body{flex:1;display:flex;flex-direction:column;padding:1rem 1rem 1.1rem}
.loc-stage[data-view="list"] .loc-card-title{font-size:17px}
.loc-stage[data-view="list"] .loc-address{font-size:14px}
.loc-stage[data-view="list"] .loc-actions{margin-top:auto;flex-direction:column;align-items:flex-start}
.loc-stage[data-view="list"] .loc-locate{display:none}

/* Text link (single store "Get directions") */
.loc-link{display:inline-flex;align-items:center;gap:.35rem;font-family:'Cabin',sans-serif;font-weight:700;font-size:15px;color:var(--brand-deep);background:none;border:0;padding:.25rem 0;cursor:pointer;text-decoration:underline;text-decoration-color:rgba(2,32,160,.25);text-underline-offset:4px;transition:color .2s ease,text-decoration-color .2s ease}
.loc-link:hover{color:var(--brand-sky);text-decoration-color:currentColor}

/* ---- Leaflet: branded pins + popup ---- */
.loc-pin{background:none;border:0}
.loc-pin span{display:grid;place-items:center;width:38px;height:38px;border-radius:50% 50% 50% 0;background:var(--brand-deep);border:3px solid #fff;transform:rotate(-45deg);box-shadow:0 5px 12px rgba(1,14,77,.35);transition:background-color .2s ease,transform .2s ease}
.loc-pin span::after{content:"hk";transform:rotate(45deg);font-family:'Cabin',sans-serif;font-weight:700;font-size:13px;letter-spacing:-.02em;color:#fff}
.loc-pin.is-active span{background:var(--brand-sky);transform:rotate(-45deg) scale(1.15)}
.loc-pin.is-dim span{background:#9AA3B5}
.loc-me{border-radius:50%;background:#2272CE;border:3px solid #fff;box-shadow:0 0 0 6px rgba(34,114,206,.25)}
.loc-map .leaflet-popup-content-wrapper{border-radius:14px}
.loc-map .leaflet-popup-content{font-family:'Cabin',sans-serif;margin:.8rem 1rem;line-height:1.45}
.loc-popup strong{display:block;font-size:15px;color:var(--ink);margin-bottom:.15rem}
.loc-popup span{display:block;font-size:13px;color:rgba(38,38,36,.68);margin-bottom:.45rem}
.loc-popup a{font-weight:700;font-size:14px;color:var(--brand-deep);margin-right:.8rem}

/* ---- Single store (layout follows the Media Strom store page) ---- */
.ls-page{background:#F3F6FB;padding-bottom:clamp(3rem,6vw,5rem)}
.ls-band{padding-bottom:clamp(2rem,4vw,3rem)}
.ls-body{padding-top:2rem}
.ls-card{background:#fff;border-radius:18px;padding:1.4rem 1.5rem;box-shadow:0 1px 2px rgba(16,32,46,.04),0 8px 24px rgba(16,32,46,.05)}
.ls-card-title{font-family:'Cabin',sans-serif;font-weight:700;font-size:1.1rem;color:var(--ink);margin:0 0 .9rem}
.ls-crumbs{display:flex;flex-wrap:wrap;gap:.4rem;font-size:13.5px;color:rgba(255,255,255,.65);margin-bottom:1.25rem}
.ls-crumbs a{color:inherit;transition:color .2s ease}
.ls-crumbs a:hover{color:#fff}
.ls-crumbs [aria-current]{color:#fff}
.ls-head{display:flex;flex-direction:column;gap:.5rem}
.ls-eyebrow{font-family:'Cabin',sans-serif;font-weight:700;font-size:13px;letter-spacing:.16em;text-transform:uppercase;color:#fff;margin:0 0 .5rem}
.ls-title{font-family:'Proxima Nova',system-ui,sans-serif;font-weight:800;color:#fff;font-size:clamp(1.9rem,6vw,3.4rem);line-height:1.02;letter-spacing:-.01em;margin:0 0 .6rem}
.ls-address{font-size:15px;line-height:1.5;color:rgba(255,255,255,.78);margin:0 0 1rem}
@media(min-width:640px){.ls-address{font-size:17px}}
.ls-head-contact{display:flex;flex-wrap:wrap;gap:.5rem}
.ls-head .loc-pill{max-width:100%;overflow-wrap:anywhere;color:#fff;background:rgba(255,255,255,.08);border-color:rgba(255,255,255,.35)}
.ls-head .loc-pill:hover{color:var(--brand-deep);background:#fff;border-color:#fff}
.ls-head .loc-pill svg{flex:none;color:currentColor}
@media(min-width:768px){
	.ls-head{flex-direction:row;align-items:flex-end;justify-content:space-between}
	.ls-head-contact{justify-content:flex-end}
}

.ls-grid{display:grid;grid-template-columns:minmax(0,1fr);gap:1.25rem;margin-bottom:2rem}
.ls-photo{border-radius:18px;overflow:hidden;aspect-ratio:4/3;background:rgba(34,114,206,.1)}
.ls-photo img{width:100%;height:100%;object-fit:cover;display:block}
.ls-side{display:grid;gap:1.25rem;align-content:start}
@media(min-width:768px){
	.ls-grid{grid-template-columns:minmax(0,1fr) minmax(0,1fr)}
	.ls-photo{grid-column:1 / -1;aspect-ratio:16/9}
}
@media(min-width:1200px){
	.ls-grid{grid-template-columns:minmax(0,5fr) minmax(0,3.5fr) minmax(0,3.5fr)}
	.ls-photo{grid-column:auto;aspect-ratio:auto;min-height:440px}
}

/* Hours: one row per day, alternating rows, today highlighted */
.ls-hours-card{display:flex;flex-direction:column}
.ls-status{font-size:13.5px;line-height:1.4;color:rgba(38,38,36,.7);margin:-.4rem 0 .8rem}
.ls-status b{font-weight:700}
.ls-status.is-open b{color:#15803D}
.ls-status.is-closed b{color:#C0262D}
.ls-hours{list-style:none;margin:0 0 1.1rem;padding:0;display:grid}
.ls-hours li{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:.15rem 1rem;font-size:14.5px;color:rgba(38,38,36,.75);padding:.6rem .75rem;border-radius:8px}
.ls-hours li:nth-child(odd){background:#F3F6FB}
.ls-hours li.is-today{font-weight:700;color:var(--ink)}
.ls-day{display:inline-flex;align-items:center;gap:.5rem;font-weight:600;color:var(--ink)}
.ls-time{text-align:right;white-space:nowrap}
@media(max-width:379px){
	.ls-card{padding:1.15rem 1.1rem}
	.ls-hours li{flex-wrap:nowrap;font-size:13.5px;padding:.55rem .55rem}
	.ls-badge{font-size:10.5px;padding:.2rem .4rem}
	.ls-day{gap:.35rem}
}
.ls-badge{font-size:11.5px;font-weight:700;line-height:1;border-radius:999px;padding:.25rem .5rem}
.ls-badge.is-open{color:#15803D;background:rgba(21,128,61,.1)}
.ls-badge.is-closed{color:#C0262D;background:rgba(192,38,45,.08)}
.ls-cta{margin-top:auto;display:flex;align-items:center;justify-content:center;font-family:'Cabin',sans-serif;font-weight:700;font-size:15px;color:var(--brand-deep);border:1.5px solid var(--brand-deep);border-radius:10px;padding:.8rem 1rem;transition:background-color .2s ease,color .2s ease}
.ls-cta:hover{background:var(--brand-deep);color:#fff}

/* Good to know */
.ls-features{list-style:none;margin:0;padding:0;display:grid;gap:.9rem}
.ls-features li{display:flex;gap:.8rem;align-items:flex-start;font-size:14.5px;line-height:1.45;color:rgba(38,38,36,.72)}
.ls-features strong{display:block;font-weight:700;color:var(--ink)}
.ls-feature-ico{flex:none;display:grid;place-items:center;width:44px;height:44px;border-radius:12px;background:rgba(34,114,206,.12);color:var(--brand-sky)}

.ls-about{font-size:15.5px;line-height:1.7;color:rgba(38,38,36,.72)}
@media(min-width:768px){.ls-about{padding:1.75rem 2rem}}
.loc-prose > * + *{margin-top:.9rem}
.loc-prose a{color:var(--brand-deep);text-decoration:underline;text-underline-offset:3px}
.loc-prose ul{list-style:disc;padding-left:1.25rem}

/* No photo yet → brand placeholder */
.loc-ph{display:grid;place-items:center;width:100%;height:100%;min-height:inherit;background:linear-gradient(125deg,#2A3FD0 0%,var(--brand-deep) 55%,#010E4D 100%)}
.loc-ph img{width:min(60%,260px)!important;height:auto!important;object-fit:contain!important;opacity:.9}

/* ---- Store type: filter dropdown + card badge ---- */
.loc-type{position:relative}
.loc-panel-head .loc-type{margin-left:auto}
.loc-panel-head .loc-reset{margin-right:auto}
.loc-type-btn{display:inline-flex;align-items:center;gap:.4rem;font-family:'Cabin',sans-serif;font-weight:700;font-size:14px;color:var(--ink);background:#fff;border:1px solid rgba(16,32,46,.14);border-radius:10px;padding:.5rem .8rem;cursor:pointer;transition:border-color .2s ease,color .2s ease}
.loc-type-btn svg{color:var(--brand-deep)}
.loc-type-btn:hover,.loc-type-btn[aria-expanded="true"]{border-color:var(--brand-deep);color:var(--brand-deep)}
.loc-chips .loc-type-btn{padding:.6rem 1rem;font-size:14.5px}
.loc-type-n{display:inline-grid;place-items:center;min-width:20px;height:20px;padding:0 .3rem;border-radius:999px;background:var(--brand-deep);color:#fff;font-size:12px}
.loc-type-menu{position:absolute;z-index:30;top:calc(100% + 6px);right:0;min-width:210px;background:#fff;border-radius:12px;box-shadow:0 14px 36px rgba(16,32,46,.18);padding:.45rem;display:grid;gap:.1rem}
.loc-type-menu[hidden]{display:none}
.loc-type-opt{display:flex;align-items:center;gap:.6rem;font-size:14.5px;color:var(--ink);padding:.55rem .65rem;border-radius:8px;cursor:pointer;white-space:nowrap}
.loc-type-opt:hover{background:#F1F3F7}
.loc-type-opt input{width:17px;height:17px;accent-color:var(--brand-deep);cursor:pointer}
.loc-badge{display:none}
.loc-stage[data-view="list"] .loc-badge{display:inline-block;position:absolute;z-index:1;top:10px;left:10px;font-family:'Cabin',sans-serif;font-weight:700;font-size:12.5px;line-height:1;color:#3a2a00;background:var(--brand-gold);border-radius:6px;padding:.45rem .65rem}
.loc-type-head{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:.35rem .4rem .6rem .65rem;font-family:'Cabin',sans-serif;font-weight:700;font-size:15px;color:var(--ink)}
.loc-type-head span{display:inline-flex;align-items:center;gap:.5rem}
.loc-type-head svg{color:var(--brand-deep)}
.loc-type-close{display:grid;place-items:center;width:30px;height:30px;border:0;border-radius:999px;background:transparent;color:rgba(38,38,36,.6);cursor:pointer}
.loc-type-close:hover{background:#F1F3F7;color:var(--ink)}
/* Map panel: type picker slides in over the store list (reference pattern) */
.loc-panel{overflow:hidden}
.loc-panel .loc-type{position:static}
.loc-panel .loc-type-menu{position:absolute;inset:0;z-index:5;min-width:0;border-radius:inherit;box-shadow:none;padding:1rem;align-content:start;transform:translateX(100%);transition:transform .3s ease}
.loc-panel .loc-type-menu.is-open{transform:none}

/* ---- Mobile / tablet (reference breakpoint: below desktop) ---- */
@media(max-width:1023px){
	.loc-intro{padding-bottom:1.5rem}
	.loc-intro-eyebrow{font-size:1.4rem;letter-spacing:.06em;margin-bottom:1.1rem}
	.loc-intro-logo{height:40px;margin-bottom:1.1rem}
	.loc-intro-title{font-size:clamp(1.9rem,8.4vw,2.35rem);line-height:1.2}
	.loc-intro-text{font-size:15px}
	.loc-toolbar{gap:.9rem;margin-bottom:1rem}
	.loc-views{display:flex;width:100%;gap:8px}
	.loc-view-btn{flex:1 1 0;justify-content:center;border:1px solid rgba(16,32,46,.12);padding:.7rem .8rem}
	.loc-view-btn[aria-selected="true"]{border-color:transparent}
	.loc-search{max-width:none;padding-left:1rem}
	/* Map view: map on top, store list below */
	.loc-stage[data-view="map"]{display:flex;flex-direction:column;gap:12px}
	.loc-stage[data-view="map"] .loc-panel{order:2;margin:0}
	.loc-stage[data-view="map"] .loc-map{order:1;height:600px;border-radius:14px}
	.loc-stage[data-view="map"] .loc-list{max-height:50vh;overflow-y:auto;overscroll-behavior:contain}
	.loc-panel .loc-type-menu{min-height:300px}
	/* List view: chips wrap three per row, Type below */
	.loc-chips{width:100%;padding:.4rem}
	.loc-chip{flex:1 1 calc(33.333% - 8px);min-width:96px;padding:.65rem .5rem}
	.loc-chips .loc-type{flex:1 1 100%;display:flex;justify-content:center}
	.loc-chips .loc-type-menu{right:auto;left:50%;transform:translateX(-50%)}
}
