/* ============================================================
   B.E Guardian Rio CityKit · additive UI + beauty pass
   Loaded AFTER app.css so it can layer on top. Self-contained:
   every selector here is created by rio-citykit.js, except the
   beauty-pass selectors, which gently enhance the existing app
   (tile pane, verdict, cards). Nothing is removed.
   Dark glass aesthetic, matched to app.css tokens.
   ============================================================ */

/* ---------- Walk Watch: floating countdown chip ---------- */
#ck-watchchip{
  position:fixed;left:50%;transform:translateX(-50%);
  bottom:calc(var(--tab-h) + var(--sb) + 18px);z-index:90;
  display:none;align-items:center;gap:8px;
  background:rgba(124,224,176,.16);border:1px solid rgba(124,224,176,.55);
  color:var(--green-light);font-family:var(--mono);font-weight:700;
  font-size:12px;letter-spacing:.04em;padding:14px 16px;min-height:44px;box-sizing:border-box;border-radius:30px;
  backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);
  cursor:pointer;box-shadow:0 8px 26px rgba(0,0,0,.45),inset 0 1px 0 rgba(255,255,255,.06);
}
#ck-watchchip.on{display:inline-flex}
#ck-watchchip:active{transform:translateX(-50%) scale(.96)}
#ck-watchchip:focus-visible{outline:2px solid var(--green-light);outline-offset:3px}
#ck-watchchip .ck-eye{width:7px;height:7px;border-radius:50%;background:var(--green-light);flex-shrink:0}
@media(prefers-reduced-motion:no-preference){
  #ck-watchchip.on .ck-eye{animation:ckPulse 2.2s ease-in-out infinite}
}
@keyframes ckPulse{0%,100%{box-shadow:0 0 0 0 rgba(124,224,176,.5)}60%{box-shadow:0 0 0 7px rgba(124,224,176,0)}}

/* ---------- Walk Watch: setup + expiry sheets (reuse the app .sheet look) ---------- */
.ck-sheet{
  position:fixed;inset:0;z-index:240;display:none;
  align-items:flex-end;justify-content:center;
  background:rgba(6,8,11,.78);
  backdrop-filter:blur(6px);-webkit-backdrop-filter:blur(6px);
}
.ck-sheet.on{display:flex}
.ck-sheet__c{
  width:100%;max-width:var(--maxw);
  background:var(--card);border:1px solid var(--border-2);
  border-bottom:0;border-radius:20px 20px 0 0;
  padding:22px 18px calc(var(--sb) + 24px);
  box-shadow:0 -18px 50px rgba(0,0,0,.55),inset 0 1px 0 rgba(255,255,255,.05);
}
@media(prefers-reduced-motion:no-preference){
  .ck-sheet.on .ck-sheet__c{animation:ckSheetUp .42s var(--ease) both}
}
@keyframes ckSheetUp{from{transform:translateY(40px);opacity:0}to{transform:none;opacity:1}}
.ck-sheet__grab{width:38px;height:4px;border-radius:3px;background:var(--border-2);margin:0 auto 16px}
.ck-sheet h2{font-family:var(--head);font-weight:800;font-size:24px;text-transform:uppercase;letter-spacing:.01em;line-height:1.02}
.ck-sheet p{font-size:13.5px;color:var(--light);line-height:1.5;margin-top:8px}
.ck-sheet .ck-fine{font-size:11px;color:var(--muted);margin-top:13px}
.ck-mins{display:flex;gap:9px;margin-top:16px}
.ck-mins .btn{flex:1;padding:14px 0;margin:0}
.ck-sheet .btn{width:100%;margin-top:11px}
.ck-sheet .ck-x{
  position:absolute;top:14px;right:16px;width:34px;height:34px;border-radius:50%;
  border:none;background:rgba(255,255,255,.06);color:var(--light);
  font-size:22px;line-height:1;display:grid;place-items:center;
}
.ck-sheet__c{position:relative}
.ck-btn-danger{background:transparent;color:#FF6B5E;border:1.5px solid var(--red)}

/* ---------- Walk Watch: full-screen "Are you safe?" expiry prompt ---------- */
#ck-expiry{
  position:fixed;inset:0;z-index:5300;display:none;
  flex-direction:column;align-items:center;justify-content:center;
  text-align:center;padding:36px 26px calc(var(--sb) + 30px);
  background:linear-gradient(180deg,#241307,#06080c);
}
#ck-expiry.on{display:flex}
/* visually-hidden live region: announces the grace countdown to screen readers */
.ck-sr{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
#ck-expiry .ck-ring{
  width:118px;height:118px;border-radius:50%;display:grid;place-items:center;
  margin:0 auto 22px;background:rgba(230,43,30,.16);
  border:1.5px solid rgba(230,43,30,.5);color:#FF8175;
  font-family:var(--mono);font-weight:700;font-size:34px;letter-spacing:.02em;
}
#ck-expiry h2{font-family:var(--head);font-weight:900;font-size:34px;text-transform:uppercase;line-height:.95;color:var(--white)}
#ck-expiry p{font-size:14.5px;color:var(--light);line-height:1.55;margin-top:12px;max-width:340px}
#ck-expiry .ck-acts{display:flex;flex-direction:column;gap:11px;width:100%;max-width:340px;margin-top:26px}
#ck-expiry .ck-acts .btn{width:100%;margin:0}

/* ============================================================
   BEAUTY PASS · additive only, layered over app.css
   ============================================================ */

/* (a) desaturate the Leaflet basemap so safety colors pop.
   Verified: neither guardian.js nor app.css set a tile-pane filter. */
.leaflet-tile-pane{filter:brightness(.92) saturate(.82)}

/* (b) level-keyed verdict glow.
   #grd-verdict has no level class; rio-citykit.js reads the inner
   banner's left-border colour and stamps data-lv (0 calm / 1 sharp /
   2 phone-away) on #grd-verdict. Glows are keyed off that.
   Reduced-motion safe: these are static shadows, no pulsing. */
#grd-verdict{border-radius:11px;transition:box-shadow .4s var(--ease)}
#grd-verdict[data-lv="0"]{box-shadow:0 0 0 1px rgba(61,153,112,.28),0 6px 22px rgba(61,153,112,.22)}
#grd-verdict[data-lv="1"]{box-shadow:0 0 0 1px rgba(254,223,0,.3),0 6px 22px rgba(254,223,0,.2)}
#grd-verdict[data-lv="2"]{box-shadow:0 0 0 1px rgba(230,43,30,.34),0 6px 26px rgba(230,43,30,.28)}

/* (c) raised-card highlight: the dark-mode way to read "lifted".
   Additive inset highlight, kept separate so it never replaces an
   existing box-shadow on these elements. */
.card,
.sheet__head,
.grd-lk-card,
#grd-verdict{box-shadow:inset 0 1px 0 rgba(255,255,255,.05)}
/* the verdict already carries its level glow above; re-add the inset
   alongside each level so the highlight survives there too. */
#grd-verdict[data-lv="0"]{box-shadow:inset 0 1px 0 rgba(255,255,255,.05),0 0 0 1px rgba(61,153,112,.28),0 6px 22px rgba(61,153,112,.22)}
#grd-verdict[data-lv="1"]{box-shadow:inset 0 1px 0 rgba(255,255,255,.05),0 0 0 1px rgba(254,223,0,.3),0 6px 22px rgba(254,223,0,.2)}
#grd-verdict[data-lv="2"]{box-shadow:inset 0 1px 0 rgba(255,255,255,.05),0 0 0 1px rgba(230,43,30,.34),0 6px 26px rgba(230,43,30,.28)}
