#ctv-cast-wrap, #ctv-cast-toast {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  color: #eef8ff;
  background: #0a2033e8;
  border: 1px solid #b8def466;
  border-radius: 12px;
  box-shadow: 0 6px 18px #04162366;
  font: 600 12px/1.25 system-ui, sans-serif;
  pointer-events: none;
}

#ctv-cast-wrap[hidden], #ctv-cast-toast[hidden],
#ctv-cast-target[hidden], #ctv-cast-hint[hidden] { display: none; }

#ctv-cast-wrap {
  bottom: max(140px, calc(env(safe-area-inset-bottom) + 109px));
  width: min(228px, 57%);
  padding: 8px 10px;
}

.ctv-power-header { display: flex; justify-content: space-between; gap: 8px; }
#ctv-cast-pct { font-variant-numeric: tabular-nums; }

#ctv-cast-track {
  position: relative;
  height: 11px;
  margin-top: 5px;
  overflow: hidden;
  border: 1px solid #8fb5cb88;
  border-radius: 999px;
  background: #051421;
}

#ctv-cast-fill { height: 100%; background: linear-gradient(90deg, #34cae1, #5b9af4); }
.ctv-power-chum #ctv-cast-fill { background: linear-gradient(90deg, #f8b648, #ff861f); }

#ctv-cast-target {
  position: absolute;
  inset-block: 0;
  box-sizing: border-box;
  border-inline: 1px solid #a6ffdc;
  background: #54e5ac65;
}

#ctv-cast-hint { margin-top: 5px; text-align: center; color: #a6ffdc; }

#ctv-cast-toast {
  bottom: max(195px, calc(env(safe-area-inset-bottom) + 162px));
  width: max-content;
  max-width: 75%;
  padding: 6px 10px;
  text-align: center;
}

#ctv-cast-toast.ctv-power-highlight { color: #a6ffdc; border-color: #6bdca970; }

#ctv-cast-landing {
  position: absolute;
  width: 21px;
  height: 21px;
  transform: translate(-50%, -50%) scaleY(.67);
  border: 2px solid #f3ffff;
  border-radius: 50%;
  box-shadow: 0 0 0 3px #102b4e77, 0 0 14px #85e6ff;
  background: radial-gradient(circle, #f5ffff 0 2px, #4a8da435 3px, transparent 68%);
  z-index: 89;
  pointer-events: none;
}

#ctv-cast-landing[hidden] { display: none; }
#ctv-cast-landing.ctv-landing-chum { border-color: #ffe6a4; box-shadow: 0 0 0 3px #102b4e77, 0 0 14px #ffc36d; }
