    :root{
      --bg:#0b1020;
      --card:#12182b;
      --accent:#58a6ff;
      --hot:#ef4444;
      --warm:#f59e0b;
      --cool:#22c55e;
      --oilers-blue:#0038A8;
      --flames-red:#CE1126;
      --priority-high:#ef4444;
      --priority-medium:#f59e0b;
      --priority-low:#22c55e;
      --unknown:#94a3b8;
    }

    html, body {
      height:100%;
      margin:0;
      font-family:system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
      background:radial-gradient(circle at top left, #0f172a, #020617 70%);
      color:white;
    }

    #app{
      display:grid;
      grid-template-columns:320px 1fr;
      grid-template-rows:auto auto 1fr;
      height:100vh;
    }

    header{
      grid-column:1/3;
      display:flex;
      align-items:center;
      justify-content:space-between;
      gap:12px;
      padding:12px 16px;
      background:linear-gradient(180deg,#0f1730,#0b1020);
      border-bottom:1px solid #1b2648;
    }

    header h1{
      font-size:18px;
      margin:0;
    }

    .meta{
      opacity:.8;
      font-size:12px;
    }

    .filters{
      grid-column:1/3;
      display:flex;
      flex-wrap:wrap;
      gap:8px;
      padding:10px 16px;
      border-bottom:1px solid #1b2648;
      background:linear-gradient(180deg,#0f1730,#0b1020);
      align-items:center;
    }

    .neighbourhood-search{
      display:flex;
      gap:6px;
      margin-right:4px;
    }

    .neighbourhood-search input,
    .neighbourhood-search button{
      min-height:34px;
      color:white;
      background:rgba(255,255,255,.06);
      border:1px solid rgba(88,166,255,.35);
      border-radius:9px;
      font:inherit;
      font-size:13px;
    }

    .neighbourhood-search input{width:290px;padding:0 10px}
    .neighbourhood-search button{padding:0 12px;cursor:pointer}
    .neighbourhood-search input::placeholder{color:#aebbd3}
    .neighbourhood-search input:focus-visible,
    .neighbourhood-search button:focus-visible{outline:3px solid rgba(88,166,255,.75);outline-offset:2px}

    .sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}

    .ward-filter{
      display:flex;
      align-items:center;
      gap:7px;
      margin-left:auto;
      color:#cbd5e1;
      font-size:12px;
      font-weight:700;
    }

    .ward-filter label span{color:#94a3b8;font-weight:500}
    .ward-filter select{
      min-height:34px;
      max-width:220px;
      padding:0 30px 0 10px;
      color:white;
      background:#121a31;
      border:1px solid rgba(88,166,255,.3);
      border-radius:9px;
      font:inherit;
      font-weight:500;
    }

    .ward-filter select:focus-visible{outline:3px solid rgba(88,166,255,.75);outline-offset:2px}

    .chip{
      appearance:none;
      color:inherit;
      background:rgba(255,255,255,.04);
      border:1px solid rgba(88,166,255,.2);
      border-radius:999px;
      padding:6px 12px;
      font:inherit;
      font-size:13px;
      cursor:pointer;
      transition:background .2s ease, border-color .2s ease, box-shadow .2s ease;
    }

    .chip:hover{
      background:rgba(59,130,246,.2);
      border-color:rgba(59,130,246,.6);
    }

    .chip:focus-visible,
    .hamburger:focus-visible,
    .details-close:focus-visible{
      outline:3px solid rgba(88,166,255,.75);
      outline-offset:2px;
    }

    .chip.active{
      background:linear-gradient(145deg,#1b2a4a,#223764);
      border-color:rgba(88,166,255,.6);
      box-shadow:0 0 12px rgba(59,130,246,.45);
    }

    .demo-badge{
      display:inline-flex;
      align-items:center;
      margin-top:5px;
      padding:3px 8px;
      color:#fde68a;
      background:rgba(245,158,11,.12);
      border:1px solid rgba(245,158,11,.45);
      border-radius:999px;
      font-size:11px;
      font-weight:700;
      letter-spacing:.04em;
      text-transform:uppercase;
    }

    .demo-badge.live{
      color:#bbf7d0;
      background:rgba(34,197,94,.12);
      border-color:rgba(34,197,94,.5);
    }

    .demo-badge.fallback{
      color:#fed7aa;
      background:rgba(249,115,22,.12);
      border-color:rgba(249,115,22,.5);
    }

    aside{
      background:var(--card);
      border-right:1px solid #1b2648;
      padding:12px;
      overflow:auto;
    }

    .panel{
      background:rgba(255,255,255,.02);
      border:1px solid #1b2648;
      border-radius:14px;
      padding:12px;
      margin-bottom:12px;
    }

    .panel h2{
      margin:0 0 10px 0;
      font-size:16px;
    }

    .panel-intro{
      margin:-4px 0 10px;
      color:#aebbd3;
      font-size:11px;
      line-height:1.4;
    }

    .growth-list{
      display:grid;
      gap:6px;
      margin:0;
      padding:0;
      list-style:none;
    }

    .growth-list button{
      display:grid;
      grid-template-columns:24px 1fr auto;
      align-items:center;
      gap:8px;
      width:100%;
      padding:8px;
      color:#e6eefc;
      background:#0e1530;
      border:1px solid #1b2648;
      border-radius:10px;
      font:inherit;
      text-align:left;
      cursor:pointer;
    }

    .growth-list button:hover{border-color:rgba(88,166,255,.6);background:#121d3d}
    .growth-list button:focus-visible,
    .share-neighbourhood:focus-visible{outline:3px solid rgba(88,166,255,.75);outline-offset:2px}
    .growth-rank{display:grid;place-items:center;width:22px;height:22px;color:#fde68a;background:rgba(245,158,11,.15);border-radius:50%;font-size:11px;font-weight:800}
    .growth-name{min-width:0;font-size:12px;font-weight:700}
    .growth-list small{display:block;color:#94a3b8;font-size:9px;font-weight:500}
    .growth-list strong{text-align:right;color:#fbbf24;font-size:12px}

    .legend h3{
      margin:12px 0 7px;
      color:#dbeafe;
      font-size:11px;
      letter-spacing:.06em;
      text-transform:uppercase;
    }

    .legend h3:first-child{margin-top:0}

    .legend-item{
      display:grid;
      grid-template-columns:28px 1fr;
      align-items:center;
      gap:8px;
      min-height:25px;
      color:#cbd5e1;
      font-size:11px;
      line-height:1.25;
    }

    .heat-gradient{
      width:26px;
      height:10px;
      border:1px solid rgba(255,255,255,.55);
      border-radius:999px;
      background:linear-gradient(90deg,#2c7bb6,#00a6ca,#00ccbc,#90eb9d,#ffff8c,#f9d057,#f29e2e,#e76818,#d7191c);
    }

    .dot,
    .ring{
      display:inline-block;
      justify-self:center;
      box-sizing:border-box;
      border-radius:50%;
    }

    .dot.housing{background:#fbbf24;border:2px solid #fff}
    .dot.housing.medium{width:10px;height:10px}
    .dot.housing.high{width:15px;height:15px}
    .dot.housing.very-high{width:20px;height:20px}
    .dot.enu-yes{width:15px;height:15px;background:var(--oilers-blue);border:2px solid var(--oilers-blue)}
    .dot.enu-no{width:15px;height:15px;background:var(--flames-red);border:2px solid var(--flames-red)}
    .dot.enu-unknown{width:9px;height:9px;background:var(--unknown);border:1px solid var(--unknown)}
    .ring{width:20px;height:20px;background:transparent;border:3px solid}
    .ring.advocates{border:2px dashed var(--warm)}
    .ring.priority-high{border-color:var(--priority-high)}
    .ring.priority-medium{border-color:var(--priority-medium)}
    .ring.priority-low{border-color:var(--priority-low)}
    .hall-symbol{justify-self:center;width:14px;height:14px;background:#0891b2;border:2px solid #e0f2fe;border-radius:4px}

    #map{
      width:100%;
      height:100%;
      min-height:500px;
    }

    .kpi{
      display:grid;
      grid-template-columns:repeat(3,1fr);
      gap:8px;
      margin-top:10px;
    }

    .k{
      background:#0e1530;
      border:1px solid #1b2648;
      border-radius:12px;
      padding:8px;
      text-align:center;
    }

    .k .n{
      font-weight:700;
      font-size:16px;
    }

    .k.blue{color:var(--oilers-blue)}
    .k.red{color:var(--flames-red)}
    .k.unknown{color:var(--unknown)}
    .k.high{color:var(--priority-high)}
    .k.medium{color:var(--priority-medium)}
    .k.low{color:var(--priority-low)}

    .toggle{
      display:flex;
      align-items:center;
      gap:8px;
      margin:8px 0;
    }

    .provisional-note,
    .source-note{
      margin:10px 0 0;
      color:#aebbd3;
      font-size:11px;
      line-height:1.45;
    }

    .site-credit{
      padding:2px 12px 14px;
      color:#7f8ca8;
      font-size:10px;
      line-height:1.4;
      text-align:center;
    }

    .site-credit a{
      color:#aebbd3;
      font-weight:600;
      text-decoration:none;
    }

    .site-credit a:hover,
    .site-credit a:focus-visible{
      color:#fff;
      text-decoration:underline;
    }

    .methodology-panel details{
      color:#dbeafe;
    }

    .methodology-panel summary{
      cursor:pointer;
      font-size:14px;
      font-weight:700;
      list-style-position:outside;
    }

    .methodology-panel summary:focus-visible{
      outline:3px solid rgba(88,166,255,.75);
      outline-offset:4px;
      border-radius:4px;
    }

    .methodology-copy{
      padding-top:6px;
      color:#cbd5e1;
      font-size:12px;
      line-height:1.45;
    }

    .methodology-copy p{
      margin:8px 0;
    }

    .leaflet-container a{
      color:#9fb0ce;
    }

    .details{
      position:fixed;
      right:16px;
      bottom:16px;
      width:390px;
      max-width:92vw;
      background:var(--card);
      border:1px solid #1b2648;
      border-radius:14px;
      padding:16px;
      box-shadow:0 10px 30px rgba(0,0,0,.45);
      z-index:1200;
    }

    .details.hidden{
      display:none;
    }

    .details h3{
      margin:1px 38px 8px 0;
      font-size:23px;
      line-height:1.15;
    }

    .profile-eyebrow{
      color:#7dd3fc;
      font-size:10px;
      font-weight:800;
      letter-spacing:.11em;
      text-transform:uppercase;
    }

    .official-geography{
      margin:-2px 34px 10px 0;
      color:#aebbd3;
      font-size:12px;
      line-height:1.4;
    }

    .profile-section{
      margin-top:11px;
      padding:11px;
      background:rgba(255,255,255,.025);
      border:1px solid #1b2648;
      border-radius:11px;
    }

    .profile-section-heading{
      display:flex;
      justify-content:space-between;
      align-items:center;
      gap:10px;
      color:#dbeafe;
      font-size:12px;
      font-weight:800;
    }

    .profile-section p{margin:6px 0 0;color:#aebbd3;font-size:11px;line-height:1.4}

    .growth-level{
      padding:3px 7px;
      border-radius:999px;
      font-size:10px;
      text-transform:uppercase;
    }
    .growth-level.very-high{color:#fee2e2;background:rgba(239,68,68,.2)}
    .growth-level.high{color:#ffedd5;background:rgba(249,115,22,.18)}
    .growth-level.moderate{color:#fef3c7;background:rgba(245,158,11,.18)}
    .growth-level.lower{color:#dcfce7;background:rgba(34,197,94,.16)}

    .profile-metrics{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:10px}
    .profile-metrics div{padding:9px;background:#0e1530;border-radius:9px}
    .profile-metrics strong{display:block;color:#fff;font-size:19px}
    .profile-metrics span{display:block;margin-top:2px;color:#94a3b8;font-size:9px;line-height:1.25}
    .profile-contact,.priority-line{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:9px;font-size:11px}
    .profile-contact span,.priority-line span:last-child{color:#94a3b8}
    .awaiting-contact{padding:7px 8px;background:rgba(148,163,184,.08);border-radius:7px}
    .civic-summary .row{margin:7px 0 0}
    .league-name{margin-top:7px;color:#7dd3fc;font-size:15px;font-weight:800;line-height:1.25}
    .league-link{display:inline-flex;margin-top:9px;color:#7dd3fc;font-size:11px;font-weight:800;text-decoration:none}
    .league-link:hover{text-decoration:underline}
    .league-link:focus-visible{outline:3px solid rgba(88,166,255,.75);outline-offset:3px;border-radius:3px}
    .community-hall-marker{cursor:pointer}

    .profile-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:12px}
    .profile-action{
      display:flex;
      align-items:center;
      justify-content:center;
      min-height:38px;
      box-sizing:border-box;
      padding:8px 10px;
      border-radius:9px;
      font:inherit;
      font-size:11px;
      font-weight:800;
      text-align:center;
      text-decoration:none;
      cursor:pointer;
    }
    .profile-action.primary{color:#07111f;background:#7dd3fc;border:1px solid #7dd3fc}
    .profile-action.secondary{margin:0;color:#dbeafe;background:rgba(59,130,246,.14);border:1px solid rgba(88,166,255,.45)}
    .profile-action.disabled{color:#94a3b8;background:rgba(148,163,184,.08);border:1px solid #334155;cursor:default}
    .profile-action:focus-visible{outline:3px solid rgba(88,166,255,.75);outline-offset:2px}
    .profile-footnote{margin:9px 0 0;color:#8190aa;font-size:9px;line-height:1.35}

    .area-choices{display:grid;gap:7px}
    .area-choices button{
      display:flex;
      justify-content:space-between;
      align-items:center;
      min-height:42px;
      padding:8px 10px;
      color:#e6eefc;
      background:#0e1530;
      border:1px solid #1b2648;
      border-radius:9px;
      font:inherit;
      font-size:13px;
      font-weight:700;
      cursor:pointer;
    }
    .area-choices button:hover{border-color:rgba(88,166,255,.6)}
    .area-choices button:focus-visible{outline:3px solid rgba(88,166,255,.75);outline-offset:2px}
    .area-choices small{color:#94a3b8;font-size:10px;font-weight:500}

    .details-close{
      position:absolute;
      top:8px;
      right:8px;
      width:30px;
      height:30px;
      color:#dbeafe;
      background:rgba(255,255,255,.04);
      border:1px solid #1b2648;
      border-radius:8px;
      cursor:pointer;
    }

    .share-status{display:block;margin-top:6px;color:#bbf7d0;font-size:10px;text-align:center}

    .map-status{
      position:fixed;
      left:50%;
      bottom:18px;
      transform:translateX(-50%);
      z-index:1300;
      max-width:min(520px,calc(100vw - 32px));
      padding:10px 14px;
      color:#fee2e2;
      background:#450a0a;
      border:1px solid #ef4444;
      border-radius:10px;
      box-shadow:0 10px 30px rgba(0,0,0,.4);
      font-size:13px;
    }

    .map-status.hidden{
      display:none;
    }

    .badge{
      display:inline-flex;
      align-items:center;
      gap:6px;
      padding:4px 8px;
      border-radius:999px;
      font-size:11px;
      border:1px solid #1b2648;
    }

    .badge.yes{
      background:rgba(0,56,168,.15);
      color:var(--oilers-blue);
    }

    .badge.no{
      background:rgba(206,17,38,.15);
      color:var(--flames-red);
    }

    .badge.unknown{
      background:rgba(148,163,184,.15);
      color:#cbd5e1;
    }

    .badge.priority-high{
      background:rgba(239,68,68,.15);
      color:var(--priority-high);
    }

    .badge.priority-medium{
      background:rgba(245,158,11,.15);
      color:var(--priority-medium);
    }

    .badge.priority-low{
      background:rgba(34,197,94,.15);
      color:var(--priority-low);
    }

    .row{
      display:flex;
      justify-content:space-between;
      margin:4px 0;
      font-size:13px;
      gap:12px;
    }

    .hamburger{
      display:none;
      margin-left:auto;
      background:transparent;
      color:#e6eefc;
      border:1px solid #1b2648;
      border-radius:10px;
      padding:6px 10px;
      font-size:18px;
      cursor:pointer;
    }

    .leaflet-interactive{
      touch-action:manipulation;
    }

    .neighbourhood-hit-target{
      cursor:pointer;
    }

    .backdrop{
      position:fixed;
      inset:56px 0 0 0;
      background:rgba(0,0,0,.35);
      z-index:999;
      opacity:0;
      pointer-events:none;
      transition:opacity .2s ease;
    }

    .backdrop.show{
      opacity:1;
      pointer-events:auto;
    }

    @media (max-width: 900px){
      #app{
        grid-template-columns:1fr;
        grid-template-rows:auto auto 1fr;
      }

      .hamburger{
        display:inline-block;
      }

      #sidepanel{
        position:fixed;
        top:56px;
        left:0;
        width:86vw;
        height:calc(100vh - 56px);
        background:var(--card);
        border-right:1px solid #1b2648;
        overflow:auto;
        transform:translateX(-105%);
        transition:transform .25s ease;
        z-index:1000;
      }

      #sidepanel.open{
        transform:translateX(0);
      }

      #map{
        min-height:500px;
      }

      .kpi{
        grid-template-columns:repeat(2,1fr);
      }

      .details{
        left:12px;
        right:12px;
        bottom:12px;
        width:auto;
        max-height:calc(100vh - 190px);
        overflow:auto;
      }

      .neighbourhood-search{width:100%;margin-right:0}
      .neighbourhood-search input{width:auto;min-width:0;flex:1}
      .ward-filter{width:100%;margin-left:0;justify-content:space-between}
      .ward-filter select{flex:1}
    }
