* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background-image: url("bg.jpg");
  background-size: cover;
  background-repeat: no-repeat;
  background-position: 50%;
  height: 100vh;
  overflow: hidden;
  /* font-family: "Inter", sans-serif; */
  font-family: "Roboto", sans-serif;
}

button {
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-align: left;
  transition: 0.3s;
}

.sidebar {
  position: fixed;
  top: 24px;
  left: 24px;
  bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 260px;
  border-radius: 16px;
  padding: 0 16px;
  border: 1px solid rgb(255 255 255 / 8%);
  background: rgb(0 0 0 / 40%);
  backdrop-filter: blur(20px);
  transition: width 0.4s;
}

.sidebar header {
  display: flex;
  align-items: center;
  height: 72px;
  padding: 0 1.25rem 0 0;
  border-bottom: 1px solid rgb(255 255 255 / 8%);
}

.sidebar header button {
  width: 52px;
}

.sidebar header img {
  height: 24px;
}

.sidebar button {
  position: relative;
  display: flex;
  gap: 16px;
  align-items: center;
  height: 50px;
  width: 100%;
  border-radius: 6px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 400;
  line-height: 1;
  padding: 0 12px 0 16px;
  color: rgb(255 255 255 / 95%);
}

.sidebar button p:nth-child(2) {
  flex: 1 1 auto;
}

.sidebar button:is(.active, :hover) {
  background: rgb(0 0 0 / 30%);
}

.sidebar button i {
  transition: 0.3s;
}

.sidebar button.active > i:nth-child(3) {
  rotate: -180deg;
}

.sidebar button:not(.active):hover {
  background: rgb(0 0 0 / 10%);
}

.sidebar ul {
  display: grid;
  list-style: none;
  padding: 0;
  margin: 0;
  width: 100%;
}

.sub-menu {
  position: relative;
  overflow: hidden;
  height: 0;
  transition: 0.5s;
}

.sub-menu ul {
  position: absolute;
  top: 0;
  left: 0;
  display: grid;
}

.sub-menu button {
  padding-left: 52px;
}

.sub-menu button::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 24px;
  translate: 0 -50%;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background-color: rgb(255 255 255 / 35%);
}

.sidebar .material-symbols-outlined {
  font-size: 16px;
}

.sidebar i {
  font-size: 20px;
  width: 20px;
  max-width: 20px;
  min-width: 20px;
}



#toast-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 9999;
}

.toast {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 260px;
  max-width: 320px;
  padding: 14px 18px;
  border-radius: 10px;
  font-family: Arial, sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: #fff;
  box-shadow: 0 4px 10px rgba(0,0,0,0.25);
  opacity: 0;
  transform: translateX(100%);
  animation: slideIn 0.4s forwards, fadeOut 0.5s ease 3.5s forwards;
}

.toast svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.toast.offline {
  background-color: #e74c3c;
}

.toast.online {
  background-color: #2ecc71;
}

@keyframes slideIn {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeOut {
  to {
    opacity: 0;
    transform: translateX(100%);
  }
}
