* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
html, body {
  height: 100%;
  font-family: Roboto, sans-serif;
  font-size: 12pt;
  overflow: auto;
}
body {
    position: relative;
  /**/display: grid;
  place-items: center;
  height: 100vh; /* Full viewport height */
  margin: 0;
}

.panel {
    position: absolute;
    display: grid;
    gap: 8vh;
    justify-items: center;
}

.toggle-container {
    all: unset; /* Removes all default styling on the div */
    display: inherit;
    gap: 1vh;
    justify-items: inherit;
}

#rave-settings {
    gap: 3vh;
}

.user-settings {
    position: absolute;
    top: 20px; /* Adjust the distance from the top */
    left: 0;
    width: 100%; /* Full width of the page */
    display: flex;
    justify-content: space-between; /* Align items: one left, one right */
    padding: 0 20px; /* Add some padding if needed */
    box-sizing: border-box; /* Ensure padding doesn’t affect width */
}

.rpm-container {
  display: flex;
  align-items: center;
}
h1 {
  font-size: 1.5rem;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  margin-left: 10px;
}
.user-settings img {
  max-height: 40px; /* Set image height as needed */
  width: auto;  /* Maintain aspect ratio */
}
#led, .led-red, .led-green {
  position: relative;
  width: 5em;
  height: 5em;
  border: 2px solid #000;
  border-radius: 2.5em;
  box-shadow: 0 0.5em 1em rgba(102, 0, 0, 0.3);
}
#led {
  background-image: radial-gradient(farthest-corner at 50% 20%, #b30000 0%, #330000 100%);
}
#led.on {
  background-image: radial-gradient(farthest-corner at 50% 75%, red 0%, #990000 100%);
  box-shadow: 0 1em 1.5em rgba(255, 0, 0, 0.5);
}
#led:after, .led-red:after, .led-green:after {
  content: '';
  position: absolute;
  top: .3em;
  left: 1em;
  width: 60%;
  height: 40%;
  border-radius: 60%;
  background-image: linear-gradient(rgba(255, 255, 255, 0.4), rgba(255, 255, 255, 0.1));
}
.led-red {
  width: 1em;
  height: 1em;
  background-color: red;
  border-radius: 50%;
  margin-right: 10px;
  box-shadow: 0 0.5em 1em rgba(102, 0, 0, 0.3);
}
.led-green {
  width: 1em;
  height: 1em;
  background-color: green;
  border-radius: 50%;
  margin-right: 10px;
  box-shadow: 0 0.5em 1em rgba(0, 102, 0, 0.3);
}
/* Gauge Styles */
#gauge-container {
  position: relative;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
#gauge {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: conic-gradient(
    rgb(170, 170, 170) 0%, rgb(170, 170, 170) 25%,
    white 25%, white 50%,
    rgb(170, 170, 170) 50%, rgb(170, 170, 170) 100%
  )
}
#gauge-in {
  width: 80%;
  height: 80%;
  border-radius: 50%;
  background: white;
}
.rpm, .rpm-value {
  position: absolute;
  bottom: 10%;
  right: 5%;
  font-size: 1.3rem;
  color: #000000;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}
.rpm-value {
    bottom: 20%;
    font-size: 1.8rem;
}

.popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: rgba(0, 0, 0, 0.3);
    z-index: 9999;
    transition: opacity 0.3s ease;
}

.popup.hidden {
    display: none;
}

.popup-content {
    position: relative;
    width: 300px;
    padding: 20px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column; /* Stack content vertically */
    align-items: center; /* Center horizontally */
}

.text-popup {
    margin-top: 3vh;
    margin-bottom: 3vh;
}

.close {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 18px;
    cursor: pointer;
}

/* Loading Circle */
.loading-circle {
    width: 50px;
    height: 50px;
    margin-top: 20px; /* Space between the text and the circle */
    border: 6px solid rgba(0, 0, 0, 1);
    border-top: 6px solid rgba(0, 0, 0, 0.1);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

input[type="text"], input[type="email"], input[type="password"] {
    width: 100%;
    padding: 10px;
    border: 2px solid #ccc;
    border-radius: 5px;
    font-size: 16px;
    outline: none;
    transition: border-color 0.3s ease;
}

input[type="text"]:focus, input[type="email"]:focus, input[type="password"]:focus {
    border-color: #333; /* Darker border on focus */
}

input[type="text"]:invalid:focus {
    border-color: #e63946; /* Soft red color on error */
}

input[type="text"]:valid:focus {
    border-color: #47e639; /* Soft red color on error */
}

.wifi-settings {
    padding: 10px 20px;
    border: 2px solid #ccc;
    border-radius: 5px;
    background-color: white;
    color: #333;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.wifi-settings:hover {
    background-color: #f0f0f0; /* Light gray on hover */
    border-color: #333; /* Darker border on hover */
}

.wifi-settings:focus {
    outline: none; /* Remove default outline */
    border-color: #333; /* Darker border when focused */
}



.custom-dropdown {
    position: relative;
    width: 100%;
    max-width: 400px; /* Set a max-width for better appearance */
    min-width: 150px;
}

/* Style for the dropdown button */
.dropdown-toggle {
  width: 100%;
  padding: 10px;
  border: 2px solid #ccc;
  border-radius: 5px;
  font-size: 16px;
  background-color: #fff;
  color: #333;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.3s ease;
  position: relative; /* Position relative for the arrow */
}

/* Adding an arrow */
.dropdown-toggle::after {
  content: '▼'; /* Unicode character for downward arrow */
  position: absolute;
  right: 10px; /* Space from the right */
  top: 50%;
  transform: translateY(-50%); /* Center the arrow vertically */
  font-size: 12px;
  color: #333; /* Color of the arrow */
}

/* Change border color on focus */
.dropdown-toggle:focus {
  border-color: #333;
  outline: none;
}

/* Dropdown options (hidden by default) */
.dropdown-options {
  position: absolute;
  width: 100%;
  margin: 5px 0 0;
  padding: 0;
  list-style: none;
  border: 2px solid #ccc;
  border-radius: 5px;
  background-color: #fff;
  max-height: 200px;
  overflow-y: auto;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  display: none;
  z-index: 1000;
}

/* Individual option items */
.dropdown-options li {
  padding: 10px;
  font-size: 16px;
  color: #333;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

/* Hover effect for dropdown options */
.dropdown-options li:hover {
  background-color: #f2f2f2;
}

/* Show dropdown options when dropdown is open */
.custom-dropdown.open .dropdown-options {
  display: block;
}







.rpm-slider {
    width: 100%;
    min-width: 180px;
    appearance: none;
    height: 2vw;
    max-height: 2vh;
    background: #A0A0A0;
    outline: none;
    opacity: 0.7;
    transition: opacity .15s ease-in-out;
    border-radius: 5px;
}

.rpm-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 2vh;
    min-width: 2vw;
    aspect-ratio: 1;
    background-color: var(--thumb-color, #000000); 
    border-radius: 50%;
    cursor: pointer;
    transition: background-color .15s ease-in-out;
}



@keyframes smoothRotate {
    0% {
      transform: rotate(0deg);
    }
    100% {
      transform: rotate(180deg);
    }
}
  
.rotate {
  animation: smoothRotate 1s ease-in-out;
}