*{
  margin:0;
  padding:0;
  box-sizing:border-box;
  font-family:Arial, sans-serif;
}

html, body{
  height:100%;
  overflow:hidden;
}

body{
  background:#0b0b0b;
  display:flex;
  justify-content:center;
  align-items:center;
  padding:8px;
}

.app{
  width:100%;
  max-width:430px;
  height:78vh;
  padding:12px;
  background:#111;
  color:white;
  display:flex;
  flex-direction:column;
  gap:10px;
  border-radius:28px;
  box-shadow:0 0 30px rgba(0,0,0,0.35);
}

.header{
  text-align:center;
}

.header h1{
  font-size:22px;
}

.header p{
  font-size:12px;
  color:#aaa;
}

.light-screen{
  width:100%;
  height:18vh;
  min-height:110px;
  max-height:150px;
  border-radius:20px;
  background:#6bb6ff;
  transition:0.4s ease;
  box-shadow:0 0 30px rgba(255,255,255,0.12);
}

/* boutons */
.main-btn{
  width:100%;
  padding:12px;
  border:none;
  border-radius:16px;
  background:white;
  color:black;
  font-weight:bold;
  font-size:14px;
  cursor:pointer;
}

/* POPUP */
.color-overlay{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,0.6);
  display:none;
  justify-content:center;
  align-items:center;
  z-index:999;
}

.color-popup{
  width:90%;
  max-width:360px;
  background:#1a1a1a;
  border-radius:20px;
  padding:14px;
  max-height:70vh;
  overflow-y:auto;
}

.popup-title{
  text-align:center;
  font-size:14px;
  margin-bottom:10px;
}

.color-item{
  display:flex;
  align-items:center;
  gap:10px;
  padding:10px;
  border-radius:12px;
  font-size:13px;
  cursor:pointer;
}

.color-item:hover{
  background:#222;
}

.dot{
  width:16px;
  height:16px;
  border-radius:50%;
}

.gradient-sunrise{
  background:linear-gradient(180deg,#ffcc70,#ff9966);
}

.gradient-sunset{
  background:linear-gradient(180deg,#ff6b6b,#6b5bff);
}

/* BOX */
.intensity-box,
.timer-box{
  background:#181818;
  padding:12px;
  border-radius:16px;
}

.intensity-box label,
.timer-box label{
  font-size:13px;
}

#intensityRange{
  width:100%;
  margin-top:8px;
}

.timer-box input{
  width:100%;
  padding:10px;
  margin:10px 0;
  border:none;
  border-radius:12px;
}

#startTimer{
  width:100%;
  padding:12px;
  border:none;
  border-radius:14px;
  background:white;
  color:black;
  font-weight:bold;
}

.status{
  text-align:center;
  font-size:12px;
  color:#bbb;
  margin-top:auto;
}

/* MODE SOMMEIL */
.sleep-mode{
  background:black !important;
  pointer-events:none;
}

/* ===== FIX FULLSCREEN PROPRE ===== */
.light-screen.fullscreen{
  position:fixed;
  inset:0;
  width:100vw !important;
  height:100vh !important;
  max-height:none !important;
  min-height:none !important;
  border-radius:0 !important;
  z-index:9999;
  transition:0.3s ease;
}