/* page */
body {
  background-color: #292929;
  color: whitesmoke;
  font-family: "Segoe UI", Arial, sans-serif;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  height: 100vh;
  margin: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Outer Circle */
.outer-circle {
  position: relative;
  width: 250px;
  height: 250px;
  background-color: #bfbfbf;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: visible;
  box-shadow: 0 0 25px rgba(0, 0, 0, 0.4);
}

/* Arrow wrapper */
.arrow-wrap {
  position: absolute;
  z-index: -1;
  left: 50%;
  top: 50%;
  width: 250px;
  height: 250px;
  transform: translate(-50%, -50%) rotate(-45deg);
  transform-origin: 50% 50%;
  pointer-events: none;
  transition: transform 0.5s ease-in-out 0.1s;
}

/* Arrow image */
.arrow {
  position: absolute;
  right: -68px;
  top: 50%;
  transform: translateY(-50%);
  width: 120px;
  height: auto;
  display: block;
  -webkit-user-drag: none;
}

/* Inner circle */
.inner-circle {
  width: 200px;
  height: 200px;
  background-color: #f3f3f3;
  border-radius: 50%;
  box-shadow: 0 6px 10px rgba(0, 0, 0, 0.25);
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Reading text */
.reading {
  text-align: center;
}

.value {
  font-size: 48px;
  font-weight: bold;
  display: block;
  color: #333;
}

.unit {
  font-size: 16px;
  color: #666;
}

/* Switch container */
#mmol-switch {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 25px;
  background: rgba(255, 255, 255, 0.08);
  padding: 6px 12px;
  border-radius: 20px;
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2);
  font-size: 14px;
}

/* Switch (slider) */
.switch {
  position: relative;
  display: inline-block;
  width: 36px;
  height: 20px;
}

/* Hide default checkbox */
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

/* Slider track */
.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: #555;
  transition: background-color 0.1s;
  border-radius: 20px;
}

.slider:before {
  content: "";
  position: absolute;
  height: 14px;
  width: 14px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  border-radius: 50%;
  transition: transform 0.1s;
}

input:checked + .slider {
  background-color: #5ec557;
}

input:checked + .slider:before {
  transform: translateX(16px);
}
