/* Reset and Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Trebuchet MS", "Lucida Sans Unicode", "Lucida Grande",
    "Lucida Sans", Arial, sans-serif;
  line-height: 1.6;
}

.login-body {
  background-image: url("../assets/images/1.jpeg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed;
  background-color: #f0f4f8;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  margin: 0;
  padding: 20px;
}

.login-container {
  width: 100%;
  max-width: 450px;
  background-color: rgba(197, 191, 191, 0.7);
  padding: 40px;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(5px);
}

.login-title {
  color: #2c3e50;
  margin-bottom: 30px;
  text-align: center;
  font-size: 24px;
}

.login-input {
  width: 100%;
  padding: 14px;
  margin-bottom: 20px;
  border: 1px solid rgba(221, 221, 221, 0.7);
  border-radius: 4px;
  font-size: 16px;
  background-color: rgba(255, 255, 255, 0.8);
}

.login-button {
  width: 100%;
  padding: 12px;
  background-color: rgba(52, 152, 219, 0.8);
  color: white;
  border: none;
  border-radius: 4px;
  font-size: 16px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.login-button:hover {
  background-color: rgba(41, 128, 185, 0.9);
}

/* Layout Container */
.layout-container {
  display: flex;
  height: 100vh;
  overflow: hidden;
}

/* Sidebar Styles */
.sidebar {
  width: 250px;
  background-color: white;
  border-right: 1px solid #ddd;
  padding: 20px;
  overflow-y: auto;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
}

/* User Profile Card */
.user-profile-card {
  text-align: center;
  margin-bottom: 20px;
  padding: 15px;
  height: 200px;
  border-radius: 10px;
  background: rgb(0, 0, 175);
}


.user-avatar {
  width: 100px;
  height: 100px;
  background: white;
  border-radius: 50%;
  margin-bottom: 10px;
}

.user-info h3 {
  margin: 5px 0;
  color: #333;
  font-size: 16px;
}

.user-role {
  color: white;
  font-size: 14px;
  margin-bottom: 5px;
}

.full-name {
  color: white;
  font-size: 14px;
}

/* Sidebar Navigation */
.side-nav ul {
  list-style: none;
}

.side-nav > ul > li {
  margin-bottom: 5px;
}

.side-nav a {
  display: flex;
  align-items: center;
  padding: 10px;
  color: #333;
  text-decoration: none;
  border-radius: 4px;
}

.side-nav a:hover {
  background-color: #f5f5f5;
}

.side-nav a.active {
  background-color: rgb(0, 0, 175);
  color: white;
}

.side-nav i {
  margin-right: 10px;
  width: 20px;
  text-align: center;
}

/* Submenu */
.submenu {
  display: none;
  margin-left: 20px;
}

.submenu.active {
  display: block;
}

/* Main Content Area */
.main-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  margin-left: 250px;
  height: 100vh;
  overflow: hidden;
}

/* Header */
.main-header {
  background-color: rgb(0, 0, 175);
  padding: 15px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: white;
  position: fixed;
  height: 90px;
  top: 0;
  left: 250px;
  right: 0;
  z-index: 1000;
}

.main-header h1 {
  font-size: 20px;
  margin: 0;
  font-family: "Trebuchet MS", "Lucida Sans Unicode", "Lucida Grande",
    "Lucida Sans", Arial, sans-serif;
}

.header-nav ul {
  display: flex;
  list-style: none;
  gap: 20px;
}

.header-nav a {
  color: white;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 5px;
}

/* Main Content */
.main-content {
  padding: 20px;
  background-color: #f5f5f5;
  flex: 1;
  overflow-y: auto;
  padding-bottom: 90px;
}

.content-area {
  padding-top: 90px;
  padding-bottom: 90px;
}

/* Footer */
.main-footer {
  position: fixed;
  bottom: 0;
  left: 250px;
  right: 0;
  background-color: #fff;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
  z-index: 1000;
}

.footer-nav ul {
  display: flex;
  justify-content: space-around;
  list-style-type: none;
  padding: 0;
  margin: 0;
}

.footer-nav li {
  flex: 1;
  text-align: center;
}

.footer-nav a {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px;
  color: #333;
  text-decoration: none;
  font-size: 0.8em;
}

.footer-nav i {
  font-size: 1.5em;
  margin-bottom: 5px;
}

.logout-desktop {
  display: inline-block;
}

.logout-mobile {
  display: none;
}

/* Mobile Phones */
@media (max-width: 480px) {
  /* Sidebar adjustments */
  .sidebar {
    width: 70%; /* Sidebar is 70% of viewport width */
    display: none; /* Hidden by default */
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    background-color: white;
    z-index: 1001;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
    overflow-y: auto;
    padding: 20px;
  }

  .sidebar.active {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 100vh;
    overflow-y: auto;
    background-color: white;
    padding: 20px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
  }

  /* Menu Toggle button */
  .menu-toggle {
    display: block;
    cursor: pointer;
    font-size: 24px;
    color: white;
    z-index: 1002;
  }

  /* Main wrapper layout adjustments */
  .main-wrapper {
    margin-left: 0;
  }

  .close-btn {
    display: block;
  }

  .logout-desktop {
    display: none;
  }

  .logout-mobile {
    display: block;
  }
  /* Header */
  .main-header {
    left: 0;
    right: 0;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    z-index: 1000;
  }

  /* Main Content */
  .main-content {
    padding: 15px;
    overflow-y: auto;
  }

  /* Footer adjustments */
  .main-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: #fff;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
  }

  /* Footer navigation */
  .footer-nav ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    padding: 5px;
  }

  .footer-nav a {
    font-size: 0.6em;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 5px;
    color: #333;
    text-decoration: none;
  }

  .overlay {
    display: none; /* Hidden by default */
    position: fixed;
    top: 0;
    left: 250px; /* Start from the right of the sidebar */
    width: calc(100vw - 250px); /* Cover the area excluding the sidebar width */
    height: 100vh; /* Cover full height including header and footer */
    background-color: rgba(0, 0, 0, 0.5); /* Black transparent overlay */
    z-index: 900; /* Below the sidebar */
  }

  /* Show the overlay when the sidebar is active */
  .sidebar.active ~ .overlay {
    display: block;
  }
}

/* Tablets */
/* @media (min-width: 481px) and (max-width: 768px) {
  .sidebar {
    width: 200px;
  }
  .main-wrapper {
    margin-left: 200px;
  }
  .main-header,
  .main-footer {
    left: 200px;
  }
} */

@media (min-width: 481px) and (max-width: 768px) {
  /* Sidebar adjustments */
  .sidebar {
    width: 70%;
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    background-color: white;
    z-index: 1001;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
    overflow-y: auto;
    padding: 20px;
  }

  .sidebar.active {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 100vh;
    overflow-y: auto;
    background-color: white;
    padding: 20px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
  }

  /* Menu Toggle button */
  .menu-toggle {
    display: block;
    cursor: pointer;
    font-size: 24px;
    color: white;
    z-index: 1002;
  }

  /* Main wrapper layout adjustments */
  .main-wrapper {
    margin-left: 0;
  }

  .close-btn {
    display: block;
  }

  .logout-desktop {
    display: none;
  }

  .logout-mobile {
    display: block;
  }

  /* Header */
  .main-header {
    left: 0;
    right: 0;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    z-index: 1000;
  }

  /* Main Content */
  .main-content {
    margin-top: 60px;
    padding: 15px;
    overflow-y: auto;
  }

  /* Footer adjustments */
  .main-footer {
    left: 0;
    right: 0;
  }

  /* Overlay */
  .overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 900;
  }

  /* Show the overlay when the sidebar is active */
  .sidebar.active ~ .overlay {
    display: block;
  }
}

/* Mobile-specific adjustments */
@media (max-width: 480px) {
  /* Any mobile-specific styles that differ from tablet can go here */
  .footer-nav ul {
    flex-wrap: wrap;
    padding: 5px;
  }

  .footer-nav a {
    font-size: 0.6em;
    padding: 5px;
  }
}

/* Desktops */
@media (min-width: 769px) {
  .sidebar {
    width: 250px;
    display: block;
  }

  .main-wrapper {
    margin-left: 250px;
  }

  .main-header,
  .main-footer {
    left: 250px;
  }

  .menu-toggle {
    display: none;
  }

  .overlay {
    display: none;
  }
}

/* Menu Toggle for Mobile */
.menu-toggle.active + .sidebar {
  display: block;
}

.error-border {
  border: 1px solid red !important;
}