/* THE KEY'S TOGGLES (key.js). The legend rows under them are app-card.js's and keep app.css's look.
   Every target here is 44 px tall (Apple's floor), and the open key takes up to 300 px so a label, its count and
   its switch fit on one line from a 320 px phone up. */
/* open, the key sits over the Get-the-app strip (z 35, getapp.js), which otherwise covered its heading */
html body:not(.brief-open) #key:not(.collapsed) { z-index:36; width:min(300px, calc(100vw - 24px)); max-width:min(300px, calc(100vw - 24px)); }
#keyShow { margin:2px 0 6px; }
#keyShow .kshow-h { font:500 10px/1.2 var(--ui, system-ui, sans-serif); letter-spacing:.16em; text-transform:uppercase;
  color:rgba(255,255,255,.62); padding:6px 2px 4px; }
html body #keyShow button.krow, html body #keyShow button.kall {
  display:flex; align-items:center; gap:10px; width:100%; min-height:44px; margin:0; padding:4px 4px 4px 2px;
  background:transparent; border:0; border-radius:8px; box-shadow:none; color:rgba(255,255,255,.88);
  font:400 13px/1.25 var(--ui, system-ui, sans-serif); letter-spacing:.01em; text-align:left; text-transform:none;
  cursor:pointer; pointer-events:auto; -webkit-tap-highlight-color:transparent; touch-action:manipulation; }
html body #keyShow button.krow[aria-pressed="true"] { background:rgba(233,196,106,.16); color:#fff; }
html body #keyShow button.krow:focus-visible, html body #keyShow button.kall:focus-visible { outline:2px solid #e9c46a; outline-offset:-2px; }
@media (hover:hover) { html body #keyShow button.krow:hover { background:rgba(255,255,255,.08); } }
#keyShow .kl { flex:1 1 auto; min-width:0; display:flex; flex-direction:column; }
#keyShow .kt { overflow-wrap:anywhere; }
#keyShow .kz { font-size:11px; color:rgba(255,255,255,.6); margin-top:1px; }
#keyShow .kz[hidden] { display:none; }
#keyShow .kn { flex:0 0 auto; font-variant-numeric:tabular-nums; color:#e9c46a; font-size:12px; }
/* the switch: a pill whose knob moves right and turns gold when the row is on */
#keyShow .ktg { flex:0 0 30px; width:30px; height:18px; border-radius:9px; position:relative;
  background:rgba(255,255,255,.18); transition:background .15s ease; }
#keyShow .ktg::after { content:''; position:absolute; top:2px; left:2px; width:14px; height:14px; border-radius:50%;
  background:#fff; transition:transform .15s ease; }
#keyShow .krow[aria-pressed="true"] .ktg { background:#e9c46a; }
#keyShow .krow[aria-pressed="true"] .ktg::after { transform:translateX(12px); background:#10201e; }
@media (prefers-reduced-motion: reduce) { #keyShow .ktg, #keyShow .ktg::after { transition:none; } }
html body #keyShow button.kall { justify-content:center; margin-top:4px; color:#e9c46a; font-weight:500;
  border:.5px solid rgba(233,196,106,.45); }
html body #keyShow button.kall[hidden] { display:none; }
/* the swatches: the colour or shape the map draws for that row */
#keyShow .ksw { flex:0 0 18px; width:18px; height:18px; border-radius:50%; position:relative; }
#keyShow .ksw-people   { background:#e9c46a; box-shadow:inset 0 0 0 2px #fff4d6; }
#keyShow .ksw-footage  { border-radius:4px; background:linear-gradient(#e9c46a,#b98a2c); }
#keyShow .ksw-filmed   { border-radius:3px; background:#4ade80; }
#keyShow .ksw-drone    { border-radius:3px; background:#4ade80; box-shadow:inset 0 0 0 4px #1e5f34; }
#keyShow .ksw-unfilmed { background:transparent; box-shadow:inset 0 0 0 2px #c4cfdb; }
#keyShow .ksw-inat     { background:#2f8f86; box-shadow:inset 0 0 0 2px #7fd6cb; }
#keyShow .ksw-video    { background:#8a63c7; }
#keyShow .ksw-species  { border-radius:0; height:2px; background:#f3d27a; }
/* the legend's own rows that act (fly somewhere): 44 px on a touch screen too */
@media (pointer:coarse) { #key #keyRows .row.go { min-height:44px; margin-top:0; } }
/* footage poles are DOM markers, not a layer: dimmed here while another row is lit */
body.key-dim-poles .fp > * { opacity:.16; transition:opacity .2s ease; }
