/* Modern St Albans Round Table inspired tracker. No external theme dependency. */
:root{--ink:#17253b;--navy:#102b51;--blue:#1264aa;--sky:#eaf4fc;--accent:#1e8ac8;--paper:#f5f8fc;--line:#dce6ef;--muted:#52647a}
*{box-sizing:border-box}html{scroll-behavior:smooth}body{margin:0;background:var(--paper);color:var(--ink);font:16px/1.55 system-ui,-apple-system,Segoe UI,Arial,sans-serif}a{color:var(--blue)}header{background:white;color:var(--navy);border-bottom:1px solid var(--line);padding:18px max(18px,calc((100vw - 1160px)/2));display:flex;align-items:center;justify-content:space-between;gap:18px;box-shadow:0 2px 14px #1634540a}header .brand{display:flex;align-items:center;gap:14px}header .brand-symbol{width:52px;height:52px;border-radius:14px;background:var(--sky);display:grid;place-items:center;font-size:28px}header h1{margin:0;font-size:clamp(21px,3vw,30px);letter-spacing:-.04em;font-weight:800;line-height:1.15}header small{display:block;margin-top:5px;color:var(--blue);font-weight:750;font-size:11px;letter-spacing:.12em;text-transform:uppercase}header a{font-weight:700;text-decoration:none}.wrap{max-width:1160px;margin:auto;padding:28px 20px 60px}h2{font-size:clamp(23px,2.8vw,32px);line-height:1.18;letter-spacing:-.04em;margin:5px 0 15px;font-weight:800}p{line-height:1.6}.muted{color:var(--muted)}.panel,.route-intro{background:white;border:1px solid var(--line);border-radius:18px;padding:25px;margin:18px 0;box-shadow:0 6px 24px #15345209}.route-intro{background:linear-gradient(115deg,#e8f4fd,#fff 65%);padding:32px}.route-intro h2{font-size:clamp(29px,4vw,43px)}.route-intro p:last-child{margin-bottom:0}.section-kicker{color:var(--blue);text-transform:uppercase;font-size:12px;font-weight:850;letter-spacing:.14em;margin:0 0 9px}.today-panel{background:var(--navy);color:white;border:0}.today-panel strong{color:#cbeaff}.today-panel .status{color:white}.panel>strong{font-size:20px}.map{height:min(65vh,630px);min-height:390px;border:1px solid var(--line);border-radius:18px;overflow:hidden;background:#e6edf3;box-shadow:0 8px 30px #15345212}.map-label{font-size:12px;font-weight:800;color:var(--blue);letter-spacing:.11em;text-transform:uppercase;margin:24px 0 10px}.legend{font-size:13px;color:var(--muted);margin:12px 0}.controls{display:flex;gap:10px;flex-wrap:wrap}button{background:var(--blue);color:white;border:0;border-radius:9px;padding:12px 18px;font:700 14px system-ui,sans-serif;cursor:pointer;transition:background .15s,transform .15s}button:hover:not(:disabled){background:#084a84;transform:translateY(-1px)}button:disabled{opacity:.5;cursor:not-allowed}button.secondary{background:var(--sky);color:var(--navy)}button.secondary:hover:not(:disabled){background:#d3e9fa}label{display:block;margin:14px 0 7px;font-size:12px;text-transform:uppercase;letter-spacing:.08em;font-weight:800;color:var(--navy)}input,select{font:inherit;border:1px solid #b7cadc;border-radius:9px;background:white;color:var(--ink);padding:12px;max-width:100%}input{width:320px}select{display:block;width:min(100%,390px);margin-bottom:14px}.pill{background:#e6f4ff;color:#07558b;border:1px solid #c6e6fa;padding:9px 13px;border-radius:999px;font-size:12px;font-weight:850;white-space:nowrap}.status{font-size:15px;line-height:1.6}.notice{background:#edf6ff;border-left:4px solid var(--accent);padding:14px;border-radius:8px;font-size:13px}.hidden{display:none!important}.schedule-list{display:grid}.schedule-row{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:15px 4px;border-bottom:1px solid var(--line)}.schedule-row:last-child{border:0}.schedule-row .muted{font-size:13px;margin-top:4px}.schedule-row button{white-space:nowrap;padding:9px 13px}.is-today{background:var(--sky);border-radius:10px;padding-left:12px;padding-right:12px;border-bottom-color:transparent}.schedule-panel h2{margin-bottom:8px}.schedule-panel .muted{margin-top:0}.santa{font-size:29px;filter:drop-shadow(0 2px 3px #3338)}footer{color:#607187;font-size:12px;margin:30px 0}button:focus-visible,select:focus-visible,input:focus-visible,a:focus-visible{outline:3px solid #ffbd4a;outline-offset:3px}@media(max-width:600px){header{padding:14px 16px}header .brand-symbol{width:42px;height:42px;font-size:23px}header small{font-size:10px}.wrap{padding:16px 12px 35px}.panel{padding:17px}.route-intro{padding:22px}.map{height:55vh;min-height:350px}.schedule-row{align-items:flex-start}.schedule-row button{font-size:12px}.pill{font-size:11px;padding:7px 9px}}

/* Official Round Table logo */
header .brand-logo{display:block;width:140px;max-height:82px;height:auto;object-fit:contain;flex-shrink:0}
@media(max-width:600px){header .brand-logo{width:92px;max-height:62px}}

.street-form{margin:14px 0}.street-form label{display:block;margin-bottom:7px;font-weight:600}.street-controls{display:flex;gap:9px;flex-wrap:wrap}.street-controls input{flex:1;min-width:180px;border:1px solid #b8c9dc;border-radius:7px;padding:11px;font:inherit}.street-result{border-top:1px solid #dce5ef;padding:13px 0}.street-result p{margin:5px 0 10px}.street-result button{margin:0}

/* Santa Float donations */
.donation-panel{border:1px solid #c9dceb;background:linear-gradient(135deg,#f5faff,#ffffff)}
.donation-panel h2{margin:5px 0 10px}
.donation-button{display:inline-flex;align-items:center;justify-content:center;min-height:44px;padding:12px 22px;border-radius:9px;background:#07558b;color:#fff!important;font-weight:750;text-decoration:none;box-shadow:0 3px 8px #063e6622}
.donation-button:hover{background:#063e66}
.donation-note{font-size:12px;margin-top:12px}

/* Compact route controls and next-visit details above the map */
.top-route-grid{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);gap:18px;align-items:stretch;margin-bottom:18px}
.top-route-grid>.route-intro,.top-route-grid>.today-panel{margin:0;min-width:0}
.top-route-grid>.route-intro{padding:23px 25px}
.top-route-grid>.route-intro h2{font-size:clamp(24px,2.8vw,32px);margin-bottom:10px}
.top-route-grid>.route-intro select{width:100%;max-width:none}
.top-route-grid>.today-panel{display:flex;flex-direction:column;justify-content:center}
.top-route-grid>.today-panel .status{margin-bottom:0}
@media(max-width:720px){.top-route-grid{grid-template-columns:1fr;gap:12px}.top-route-grid>.route-intro,.top-route-grid>.today-panel{padding:18px}.top-route-grid>.route-intro h2{font-size:26px}}

.postcode-form{margin-top:1.25rem;padding-top:1rem;border-top:1px solid #dce5e5}.postcode-form .muted{font-size:.88rem;margin:.45rem 0 .6rem}

/* Public tracker: live status above map and donation calls to action */
.map-heading{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:20px 0 10px;flex-wrap:wrap}
.map-heading .map-label{margin:0}
.location-status-row{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.location-status-row .status{flex:1;min-width:180px}
.location-status-row .donation-button{white-space:nowrap}
[hidden]{display:none!important}
.payment-brands{display:inline-flex;vertical-align:middle;align-items:center;gap:7px;margin-left:14px;flex-wrap:wrap}
.payment-brand{display:inline-flex;position:relative;align-items:center;justify-content:center;height:32px;min-width:54px;padding:2px 6px;background:#fff;border:1px solid #d5dce5;border-radius:5px;box-shadow:0 1px 3px #1232;font-weight:900;line-height:1;letter-spacing:-.04em}
.payment-brand.visa{color:#173f91;font-size:19px;font-style:italic}
.payment-brand.amex{background:#2375bf;color:white;font-size:9px;letter-spacing:0;text-align:center}
.payment-brand.mastercard{min-width:60px;gap:0;overflow:hidden}
.mc-red,.mc-yellow{display:block;width:19px;height:19px;border-radius:50%}.mc-red{background:#e52b36;margin-right:-7px}.mc-yellow{background:#f5a623;opacity:.9}.mc-label{position:absolute;bottom:1px;left:0;right:0;text-align:center;font-size:7px;letter-spacing:0;color:#333}
@media(max-width:600px){.payment-brands{margin:12px 0 0;display:flex}.location-status-row .status{min-width:150px}}

/* Donate action in the top site banner */
.header-donate{flex-shrink:0;white-space:nowrap}
@media(max-width:600px){.header-donate{padding:9px 13px;min-height:40px;font-size:13px}header .brand{min-width:0}header h1{font-size:clamp(17px,4.6vw,22px)}header small{letter-spacing:.03em}}

/* Charity profiles, shown below Santa's location */
.charity-layout{display:flex;gap:20px;align-items:flex-start;margin-top:12px}
.charity-logo-wrap{width:128px;min-width:128px;min-height:105px;display:flex;align-items:center;justify-content:center;border-radius:12px;background:#f6f7f8;padding:12px}
.charity-logo-wrap img{max-width:100%;max-height:110px;object-fit:contain}
.charity-logo-fallback{font-size:30px;font-weight:800;color:#66747d}
.charity-copy{min-width:0}.charity-copy h3{margin:0 0 8px;font-size:1.15rem}.charity-copy p{margin:0 0 10px;line-height:1.55}.charity-copy a{font-weight:650}
@media(max-width:560px){.charity-layout{gap:13px}.charity-logo-wrap{width:78px;min-width:78px;min-height:78px;padding:8px}.charity-logo-fallback{font-size:23px}}

/* Ensure loaded charity logos replace initial-letter placeholders. */
.charity-logo-wrap img:not([hidden]){display:block;max-width:100%;height:auto;object-fit:contain}
.charity-logo-wrap img[hidden],.charity-logo-fallback[hidden]{display:none!important}

/* Keep the Centre on Santa control beside the location status on desktop and mobile. */
.location-status-row{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:nowrap}
.location-status-row .status{flex:1 1 auto;min-width:0;margin:0}
.location-status-row #recenter{flex:0 0 auto;white-space:nowrap}
@media(max-width:420px){.location-status-row{gap:8px}.location-status-row #recenter{font-size:12px;padding:9px 10px}}

/* Two independent map centring controls, wrapping cleanly on narrow screens. */
.map-centre-buttons{display:flex;align-items:center;gap:8px;flex:0 0 auto;flex-wrap:wrap;justify-content:flex-end}
.map-centre-buttons button{white-space:nowrap}
@media(max-width:650px){.location-status-row{flex-wrap:wrap}.map-centre-buttons{width:100%;justify-content:flex-start}.map-centre-buttons button{flex:1 1 auto}}

/* Driver navigation map: full viewport with an always-visible exit control. */
.navigation-map-container{position:relative}
.navigation-map-container>.map{width:100%}
.map-fullscreen-toggle{position:absolute;z-index:1000;right:12px;top:12px;padding:10px 13px;background:#fff;color:#12375b;border:2px solid #abc6d9;box-shadow:0 2px 10px #0003}
.map-fullscreen-toggle:hover:not(:disabled){background:#e9f5ff;color:#12375b}
body.navigation-map-open{overflow:hidden}
.navigation-map-container.navigation-map-fullscreen{position:fixed;inset:0;z-index:9999;background:#e6edf3}
.navigation-map-fullscreen>.map{height:100%;height:100dvh;min-height:0;max-height:none;border:0;border-radius:0;box-shadow:none}
.navigation-map-fullscreen>.map-fullscreen-toggle{top:max(12px,env(safe-area-inset-top));right:max(12px,env(safe-area-inset-right))}

/* Visible navigation toolbar, with an accessible full-screen exit button. */
.navigation-map-container .navigation-map-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:12px 0 8px;position:relative;z-index:1}
.navigation-map-container .map-fullscreen-toggle{position:static;z-index:auto;flex:0 0 auto;background:#07558b;color:#fff!important;border:0;box-shadow:0 2px 8px #0002}
.navigation-map-container .map-fullscreen-toggle:hover:not(:disabled){background:#06466f;color:#fff!important}
.navigation-map-container.navigation-map-fullscreen .navigation-map-toolbar{position:absolute;top:0;right:0;left:0;margin:0;padding:max(12px,env(safe-area-inset-top)) max(12px,env(safe-area-inset-right)) 0 max(12px,env(safe-area-inset-left));z-index:2000;pointer-events:none}
.navigation-map-container.navigation-map-fullscreen .navigation-map-toolbar strong{display:none}
.navigation-map-container.navigation-map-fullscreen .map-fullscreen-toggle{margin-left:auto;pointer-events:auto}

/* Equal-size map centring buttons on mobile phones. */
@media(max-width:650px){
  .map-centre-buttons{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));width:100%;gap:8px}
  .map-centre-buttons button,
  .location-status-row #recenter{width:100%;min-width:0;min-height:44px;box-sizing:border-box;display:flex;align-items:center;justify-content:center;font-size:13px;line-height:1.25;padding:10px 6px;white-space:normal;text-align:center;flex:auto}
}

/* Public tracker: full-viewport map with a visible exit button. */
.public-map-toolbar{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:0 0 8px}
.public-map-toolbar strong{font-size:.95rem}
#publicFullscreen{flex:0 0 auto;min-height:44px;padding:10px 15px}
body.public-map-open{overflow:hidden}
.public-map-wrap.public-map-fullscreen{position:fixed;inset:0;z-index:10000;background:#fff;padding:8px;display:flex;flex-direction:column}
.public-map-wrap.public-map-fullscreen #map{flex:1;min-height:0!important;height:auto!important;max-height:none!important;width:100%;border-radius:6px}
.public-map-wrap.public-map-fullscreen .public-map-toolbar{padding:2px 4px 8px;margin:0}

/* Public tracker: map controls visible in normal and fullscreen views. */
.public-map-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap;justify-content:flex-end}
.public-map-actions .map-centre-buttons{display:flex;gap:8px;align-items:center;width:auto;flex:0 1 auto;justify-content:flex-end}
.public-map-actions .map-centre-buttons button{min-height:44px;box-sizing:border-box}
@media(max-width:650px){
 .public-map-toolbar{align-items:stretch;flex-direction:column;gap:8px}
 .public-map-actions{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px;width:100%}
 .public-map-actions .map-centre-buttons{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));width:100%;gap:8px;min-width:0}
 .public-map-actions .map-centre-buttons button{width:100%;min-width:0;min-height:44px;font-size:12px;line-height:1.2;padding:9px 4px;white-space:normal;text-align:center;justify-content:center}
 .public-map-actions #publicFullscreen{padding:9px 8px;white-space:nowrap;font-size:12px}
}

/* Keep the route key visible beneath the map, including in full-screen mode. */
.public-map-legend{margin:10px 2px 12px;line-height:1.5}
.public-map-wrap.public-map-fullscreen .public-map-legend{flex:0 0 auto;margin:8px 4px 2px;padding:4px 0;background:#fff;overflow-wrap:anywhere}

/* Start and Finish legend symbols use the exact map marker fill colours. */
.public-map-legend .legend-dot{display:inline-block;width:13px;height:13px;border-radius:50%;border:2px solid #fff;box-shadow:0 0 0 1px #9da8b4;vertical-align:-2px;margin-right:3px}
.public-map-legend .legend-dot-start{background:#22c55e}
.public-map-legend .legend-dot-finish{background:#333333}

/* Route schedule: charity logo beside route and date */
.schedule-route-info{display:flex;align-items:center;gap:14px;min-width:0;flex:1}
.schedule-charity-logo{display:block;width:58px;height:58px;object-fit:contain;flex:0 0 58px;border-radius:8px;background:#fff}
.schedule-route-copy{min-width:0}
@media(max-width:600px){.schedule-route-info{gap:10px}.schedule-charity-logo{width:46px;height:46px;flex-basis:46px}}

.payment-brand.wallet img{display:block;width:58px;height:26px;object-fit:contain}

.payment-brand.supplied{min-width:0;width:auto;height:36px;padding:3px 5px;box-sizing:border-box}.payment-brand.supplied img{display:block;height:28px;width:auto;max-width:76px;object-fit:contain}
