@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@400;600;700&display=swap');

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  height: 100vh;
  font-family: 'Rajdhani', sans-serif;
  background:
    radial-gradient(circle at center, #1b1b1b, #050505),
    repeating-linear-gradient(
      0deg,
      rgba(255,255,255,0.03),
      rgba(255,255,255,0.03) 1px,
      transparent 1px,
      transparent 3px
    );
  display: flex;
  align-items: center;
  justify-content: center;
  color: #d6d6d6;
}

.device {
  width: 92%;
  max-width: 420px;
  height: 75%;
  background: linear-gradient(145deg, #111, #070707);
  border: 1px solid #333;
  box-shadow: 0 0 40px rgba(0,0,0,0.9), inset 0 0 25px rgba(255,255,255,0.04);
  padding: 20px;
  position: relative;
}

.device span {
  position: absolute;
  width: 14px;
  height: 14px;
  border: 2px solid #ff9f1c;
}

.device span:nth-child(1) { top: 0; left: 0; border-right: none; border-bottom: none; }
.device span:nth-child(2) { top: 0; right: 0; border-left: none; border-bottom: none; }
.device span:nth-child(3) { bottom: 0; left: 0; border-right: none; border-top: none; }
.device span:nth-child(4) { bottom: 0; right: 0; border-left: none; border-top: none; }

h2 { font-size: 1.3rem; letter-spacing: 2px; color: #ff9f1c; text-align: center; }
h3 { margin-top: 8px; font-size: 0.9rem; text-align: center; color: #aaa; }

#timer { margin-top: 40px; font-size: 2.6rem; text-align: center; letter-spacing: 3px; color: #eaeaea; }

.final-bar {
  position: absolute;
  bottom: 55px;
  left: 20px;
  right: 20px;
  height: 28px;
  border: 1px solid #c98b1f;
  background: #1a1a1a;
  overflow: hidden;
  opacity: 0;
  transition: opacity 0.5s ease;
}

.final-bar span {
  position: absolute;
  width: 100%;
  text-align: center;
  font-size: 0.8rem;
  letter-spacing: 2px;
  color: #ffb000;
  line-height: 28px;
  z-index: 2;
}

.bar-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #ffb000, #ffd36a);
  transition: width 1s linear;
}

.final-bar.active { opacity: 1; }
.hidden { display: none; }

.footer {
  position: absolute;
  bottom: 12px;
  width: 100%;
  text-align: center;
  font-size: 0.75rem;
  color: #666;
}
