/* === CSS for Codecolor === */

#navbarTogglerDemo01 a{border:1px solid transparent}
#navbarTogglerDemo01 a:hover{border:1px solid #0198fa}
.awesome{
  font-family:futura;
  width:100%;
  color:#313131;
  font-size:35px;
  font-weight:700;
  -webkit-animation:20s infinite alternate colorchange
}
@-webkit-keyframes colorchange{
  0%{color:#00f}
  10%{color:#8e44ad}
  20%{color:red}
  30%{color:#4c0}
  40%{color:#000}
  50%{color:#ff0}
  60%{color:#0ff}
  70%,90%{color:#2980b9}
  80%{color:#f1c40f}
  100%{color:#ff0066}
}
.alert{
  padding:20px;
  background-color:#fc0;
  color:#fff
}
.closebtn{
  margin-left:15px;
  color:#fff;
  font-weight:700;
  float:right;
  font-size:22px;
  line-height:20px;
  cursor:pointer;
  transition:.3s
}
.closebtn:hover{color:#000}

/* === CSS for Codecolor end === */

/* === CSS for the Wheel +++ === */
:root{
  /* Switched to a light theme */
  --bg: #ffffff;
  --bg-grad-1: #ffffff;
  --bg-grad-2: #ffffff;
  --card: #f8fafc;
  --card-border: #d0d7e2;
  --text: #111827;
  --muted: #6b7280;
  --accent: #2563eb;
  --shadow: rgba(15,23,42,.15);
  --btn: #2563eb;
  --btn-danger: #ef4444;
}

*{ box-sizing: border-box; }

html, body{
  height:100%;
  margin:0;
  padding:0;
  color:var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  background:
    radial-gradient(circle at 10% 0%,
      #dbeafe 0%,        /* light blue */
      transparent 45%
    ),
    radial-gradient(circle at 90% 0%,
      #fee2e2 0%,        /* soft red */
      transparent 50%
    ),
    radial-gradient(circle at 0% 85%,
      #fef3c7 0%,        /* warm yellow */
      transparent 50%
    ),
    radial-gradient(circle at 100% 90%,
      #e0f2fe 0%,        /* blue again */
      transparent 55%
    ),
    linear-gradient(180deg,
      #f9fafb 0%,
      #e5e7eb 100%
    ) !important;
}





/* === Header === */

.sub{
  margin: 6px auto 0;
  color: var(--muted);
  max-width: 900px;
}
.sub code{
  background: rgba(148,163,184,0.15);
  padding: 2px 8px;
  border-radius: 10px;
  border: 1px solid var(--card-border);
}

/* === Layout === */
.layout{
  max-width: 100%;
}

.layout2{
  max-width: 100%;
  margin: 0 auto;
  padding: 0px;
  display: grid;
  grid-template-columns: 1fr 360px;  
  gap: 0px;  
}

@media (max-width: 980px){
  .layout2{ grid-template-columns: 1fr; }
}

/* === Wheel Area === */

/* === Wheel Area === */

.wheel-container {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  max-width: 760px;
  margin: 32px auto 32px;
  border-radius: 50%;
}

/* Gradient halo / glow behind the wheel */
/* Premium gradient glow halo */
.wheel-container::before {
  content: "";
  position: absolute;
  inset: -15px;        /* glow extends OUTSIDE the wheel */
  border-radius: 50%;
  background:
    radial-gradient(circle,
      rgba(255, 255, 255, 0.9) 0%,
      rgba(255, 255, 255, 0.6) 20%,
      rgba(56, 189, 248, 0.45) 45%,    /* cyan */
      rgba(129, 140, 248, 0.40) 70%,   /* indigo */
      rgba(236, 72, 153, 0.35) 100%    /* pink */
    );
  filter: blur(18px);
  z-index: 0;
  pointer-events: none;
}

/* Subtle bottom shadow to lift the wheel */
.wheel-container::after {
  content: "";
  position: absolute;
  inset: 18px;
  border-radius: 50%;
  box-shadow: 0 18px 45px rgba(0,0,0,0.25);
  z-index: -1;
}


#wheelCanvas {
  display: block;
  width: 100%;
  height: auto;
  background: #ffffff;   /* wheel itself is solid white */
  border-radius: 50%;
  position: relative;
  z-index: 1;            /* above the halo */
}



/* === POINTER: pulled further out so ~20% overlaps the wheel === */
.wheel-marker {
  position: absolute;
  top: 50%;
  right: -1.5em; /* was calc(1% + 0px) – now pushed outside */
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-top: 1.4em solid transparent;
  border-bottom: 1.4em solid transparent;
  border-right: 2.4em solid #ff4d5a;
  z-index: 10;
  pointer-events: none;
}

/* === Side Panel === */
.panel{
  background: rgba(248,250,252,0.92);  /* slight transparency */
  border: 1px solid rgba(148,163,184,0.4);
  border-radius: 18px;
  padding: 16px;
  box-shadow: 0 18px 40px rgba(15,23,42,0.15);
}


/* make panel positioned so popup can be absolute inside it */
.panel { position: relative; }

/* spin-time popup (small dropdown-like panel) */
/* spin-time popup styled to match dark header */
.spin-time-popup{
  position: absolute;
  top: 62px;
  right: 16px;
  background: #343a40; /* same as navbar bg-dark */
  border: 1px solid rgba(255,255,255,0.18);
  padding: 12px;
  border-radius: 10px;
  min-width: 190px;
  box-shadow: 0 14px 40px rgba(0,0,0,0.55);
  z-index: 60;
  color: #f8f9fa; /* light text */
}

/* label inside popup */
.spin-time-popup label{
  color:#f8f9fa;
}

/* number input inside popup */
.spin-time-popup input[type="number"]{
  background: #495057;                 /* dark input */
  color: #f8f9fa;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,0.25);
  padding: 6px 8px;
}

/* buttons inside popup */
.spin-time-popup .btn {
  padding: 8px 10px;
  font-size: 0.95rem;
  box-shadow: none;
}

/* primary button in popup: bright blue like Bootstrap primary */
.spin-time-popup .btn.primary{
  background: #007bff;
  border-color: #007bff;
  color: #ffffff;
}

/* ghost button in popup: just light text + border */
.spin-time-popup .btn.ghost{
  background: transparent;
  border-color: rgba(255,255,255,0.4);
  color:#f8f9fa;
}


.label{ font-weight: 700; display:block; margin-bottom: 8px; }
#namesInput{
  width: 100%;
  min-height: 340px;
  resize: vertical;
  border: 1px solid var(--card-border);
  background: #ffffff;
  color: var(--text);
  border-radius: 12px;
  padding: 12px 14px;
  outline: none;
}
.btn-row{
  display: flex;
  gap: 10px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.btn{
  background: #e5e7eb;
  color: var(--text);
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  padding: 10px 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 10px 20px rgba(148,163,184,.35);
  transition: transform .08s ease, box-shadow .2s ease, background .2s ease;
}
.btn:hover{
  transform: translateY(-1px);
  box-shadow: 0 14px 30px rgba(148,163,184,.45);
}
.btn.primary{
  background: var(--btn);
  border-color: #1d4ed8;
  color:#fff;
}
.btn.danger{
  background: var(--btn-danger);
  border-color: #dc2626;
  color: #fff;
}
.btn.ghost{
  background: transparent;
}

/* Stronger styling for the "Clear" button */
.btn.danger.ghost{
  background: #fee2e2;    /* soft red background */
  color: #b91c1c;         /* dark red text */
  border-color: #fca5a5;  /* light red border */
}
.btn.danger.ghost:hover{
  background: #fecaca;
  box-shadow: 0 0 0 1px rgba(248,113,113,0.4);
}


.hint{ color: var(--muted); margin-top: 10px; }

/* === Modal === */
.modal{
  position: fixed;
  inset: 0;
  display: none; /* toggled to flex */
  align-items: center;
  justify-content: center;
  background: rgba(15,23,42,.35);
  z-index: 50;
}
.modal.show{ display: flex; }
.modal-content{
  background: #ffffff;
  color: var(--text);
  border: 1px solid var(--card-border);
  border-radius: 18px;
  padding: 20px;
  width: min(520px, 94%);
  box-shadow: 0 24px 70px rgba(15,23,42,0.28);
  text-align: center;
  animation: pop .25s ease-out;
}

.spin-duration {
  margin-top: 12px;
  display:flex;
  align-items:center;
  gap:10px;
}
.spin-duration input[type="range"] {
  width: 160px;
}
.spin-duration label {
  font-weight:600;
  color:var(--muted);
}
#spinDurationValue {
  color: var(--text);
  margin-left:6px;
  font-weight:700;
}

.winner-name{
  font-size: 1.35rem;
  font-weight: 800;
  margin: 8px 0 6px;
}
.modal-actions{
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 8px;
}

@keyframes pop{
  from { transform: scale(.88); opacity: .1; }
  to   { transform: scale(1);   opacity: 1;  }
}

