#rescue{inset:0;pointer-events:none;z-index:2;overflow:hidden}
#rescue>div,#myShield{
 --accent:#ffe49c;background:#102137ed;color:white;box-shadow:0 3px 15px #04142a47;
 font-variant-numeric:tabular-nums;text-shadow:none;border:1px solid var(--accent)
}
#rescue>div{
 position:absolute;top:-21px;left:-60px;width:120px;height:42px;text-align:center;
 border-radius:10px;line-height:17px;padding:3px 4px;white-space:nowrap;
 font:700 11px/17px system-ui,sans-serif;box-sizing:border-box;
 display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:3px
}
#rescue b{font-size:11px;color:var(--accent)}
#rescue span{grid-column:1/-1;white-space:pre;font-size:10px}
#rescue strong{
 color:var(--accent);display:block;font-size:13px;overflow:hidden;text-overflow:ellipsis
}
#rescue i{
 position:absolute;left:calc(50% - 6px);top:calc(50% - 6px);
 width:12px;height:12px;background:var(--accent);clip-path:polygon(10% 0,100% 50%,10% 100%)
}
#rescue>.urgent,#myShield.urgent{--accent:#ffb2a7;background:#4b1e31ed}
#rescue>.helping,#myShield.helping{--accent:#78f2c8;background:#104439ed}
#myShield{
 bottom:3%;left:50%;transform:translateX(-50%);width:min(294px,92%);
 padding:9px 12px;border-radius:13px;font:600 14px system-ui,sans-serif;text-align:center
}
#myShield>div:first-child{display:flex;align-items:center;justify-content:space-between}
#myShield b{color:var(--accent);font-size:14px}
#myShield small{font-weight:570;font-size:12px;color:#e4f0fb}
#myShield .charge{height:4px;overflow:hidden;border-radius:6px;background:#597189;margin:6px 0}
#myShield i{
 display:block;width:100%;height:100%;background:#69f8e2;transform-origin:left;
 transition:transform .17s ease-out
}
#hud:has(#myShield:not([hidden])) :is(#weapon,#frag,#smoke,#reloadInfo,#powers,#touch button,#cross){
 display:none!important
}
@media(max-width:650px){
 #hud:has(#myShield:not([hidden])) #vitals{left:auto;right:4%;bottom:calc(3% + 85px)}
}
@media(prefers-reduced-motion:no-preference){
 #rescue>.urgent{animation:alertAlly 1.4s ease-in-out infinite}
 @keyframes alertAlly{50%{box-shadow:0 0 0 4px #ff83796b}}
}

/* Local helper only. Keep the reticle open and the panel size constant
   while the digits, key binding and acknowledgement change. */
#reviveProgress{
 --aid:#7bffd7;--h:84px;
 left:50%;top:calc(50% + clamp(34px,6vh,64px));transform:translateX(-50%);
 width:288px;height:var(--h);max-width:94vw;z-index:4;pointer-events:none;
 display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;
 gap:0 14px;padding:0 15px 11px;border-radius:14px;border:1px solid var(--aid);
 background:linear-gradient(112deg,#0e273bf7,#082131fa);
 box-shadow:0 4px 20px #04132366,inset 0 0 0 2px #04142270;
 color:#fff;text-shadow:none;text-align:left;white-space:nowrap;
 font:700 18px/1.1 system-ui,sans-serif;font-variant-numeric:tabular-nums
}
#reviveProgress[hidden],#hud.observer #reviveProgress,
#reviveProgress[data-state="waiting"] [role="timer"] span,
#reviveProgress:is([data-state="success"],[data-state="cancelled"]) :is(strong,.remaining){display:none}
#reviveProgress[data-state="ready"]{--aid:#ffe49c}
#reviveProgress[data-state="cancelled"]{--aid:#ffb4a7}
#reviveProgress .helper{min-width:0}
#reviveProgress strong{display:flex;align-items:center;gap:.4em}
#reviveProgress kbd{
 color:#082034;background:var(--aid);border-radius:6px;margin:0;border:0;
 font:850 .94em system-ui,sans-serif;text-align:center;
 min-width:1.56em;padding:.08em .38em
}
#reviveProgress .helper>span{
 display:block;font-size:.84em;line-height:1.35;margin-top:3px;color:#d4e8f5;
 overflow:hidden;text-overflow:ellipsis
}
#reviveProgress .helper i{color:var(--aid);font-style:normal}
#reviveProgress .remaining{text-align:right;color:var(--aid)}
#reviveProgress small{display:block;font-size:.7em;text-transform:uppercase;letter-spacing:.06em}
#reviveProgress em{font-size:2.13em;font-style:normal;font-weight:850;line-height:1;color:white}
#reviveProgress .track{
 position:absolute;inset:auto 14px 9px;height:7px;border-radius:8px;
 overflow:hidden;background:#395468
}
#reviveProgress .track i{
 display:block;width:100%;height:100%;transform-origin:left;
 background:linear-gradient(to right,#13ceae,var(--aid) 86%,#eafffc)
}
#reviveProgress:is([data-state="success"],[data-state="cancelled"]) .helper{
 grid-column:1/-1;text-align:center;color:var(--aid)
}
#reviveProgress[data-state="success"] b::before{content:'✓ '}
#reviveProgress[data-state="cancelled"] b::before{content:'× '}
#hud:has(#reviveProgress:not([hidden])) :is(#notice,#cast,#fin){visibility:hidden}
@media(max-height:540px),(max-width:720px){
 #reviveProgress{
  --h:66px;top:calc(50% + 28px);width:232px;
  padding:0 11px 8px;column-gap:7px;border-radius:11px;font-size:15px
 }
 #reviveProgress .track{inset:auto 10px 6px;height:5px}
}
@media(pointer:coarse) and (orientation:landscape) and (max-width:720px){
 #reviveProgress{left:calc(50% - 30px);width:clamp(188px,92vw - 362px,232px)}
}
@media(orientation:portrait){
 /* On a phone the help, grenade and fire controls occupy the lower half. */
 #reviveProgress{top:auto;bottom:max(calc(50% + 35px),calc(28% + 202px))}
 #hud:has(#reviveProgress:not([hidden])) #dispatch{
  max-height:max(0px,calc(min(50% - 35px,72% - 202px) - 90px - var(--top)));overflow:hidden
 }
}
