/* PWA Offline Caching App Styles */

html,
body {
  height: 100%;
  margin: 0;
  background: #000;
  color: #fff;
  font-family: Arial;
  overflow: hidden;
}

#parentElement {
  width: 100vw;
  height: 100vh;
  position: relative;
  overflow: hidden;
}

#debug {
  position: absolute;
  top: 6px;
  right: 6px;
  z-index: 9999;
  display: none !important;
}

#status {
  position: absolute;
  left: 6px;
  top: 6px;
  background: #222;
  padding: 8px;
  display: none !important;
  border-radius: 6px;
}

video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Start hidden. Only show via JS if downloads are needed. */
#progressOverlay {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: #000;
  display: none; /* Changed from flex to none */
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 10001;
}

/* Styles for the 3-bar dashboard */
.status-dashboard {
  width: 320px;
  font-size: 14px;
  margin-top: 40px;
}

.status-row {
  display: flex;
  align-items: center;
  margin-bottom: 12px;
  gap: 10px;
}

.status-label {
  width: 70px;
  text-align: right;
  color: #fff;
  font-weight: bold;
}

.bar-container {
  flex-grow: 1;
  height: 14px;
  border: 1px solid #555;
  padding: 2px;
  position: relative;
}

.bar-fill {
  height: 100%;
  width: 0%;
  background: #fff;
  transition: width 0.2s ease-out;
}

.status-pct {
  width: 45px;
  text-align: right;
  color: #fff;
}

/* Style the text below the animation */
#progressText {
  margin-top: -20px; /* Pull text closer to animation */
  font-family: 'Space Mono', monospace;
  font-size: 24px;
  color: #4caf50;
  font-weight: bold;
}

#progressCountdownText {
  margin-top: 10px;
  font-size: 16px;
  color: #888;
}

html.offline #progressOverlay {
  display: none !important;
}