/* Custom CSS for EIS - Mobile Optimized */

/* =========================================
   1. MOBILE SPECIFIC OPTIMIZATIONS (< 767px)
   ========================================= */
@media (max-width: 767px) {

  /* HIDE AdminLTE Logo Bar (Fixes "Double Bar" issue) */
  .main-header .logo {
    display: none !important;
  }

  /* Full Width Navbar */
  .main-header .navbar {
    margin-left: 0 !important;
  }

  /* Profile Dropdown: Fix positioning and width */
  .navbar-nav .dropdown-menu {
    position: absolute !important;
    right: 0 !important;
    left: auto !important;
    width: 280px !important;
    max-width: 90vw !important;
    /* Prevent overflow */
    border: 1px solid #ddd;
    background-color: #fff;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  }

  /* Profile Dropdown: Better Button Contrast */
  .navbar-nav>.user-menu>.dropdown-menu>.user-footer .btn-default {
    background-color: #f4f4f4 !important;
    color: #333 !important;
    border: 1px solid #ccc !important;
  }

  /* Typography: Smaller Headings */
  h1,
  h2,
  h3 {
    font-size: 1.5rem !important;
    margin-top: 10px !important;
  }

  /* Layout: Reduce Padding */
  .content-wrapper,
  .right-side {
    padding-top: 50px !important;
    /* Space for fixed header */
  }

  .content {
    padding: 10px !important;
    /* Tighter padding */
  }

  /* Boxes: Better Spacing */
  .box {
    margin-bottom: 15px !important;
  }

  /* Tables: Ensure Horizontal Scroll */
  .dataTables_wrapper {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
  }

  /* Navbar Toggle Avatar (Larger touch target) */
  .navbar-nav>.user-menu>.dropdown-toggle {
    padding: 10px 15px !important;
  }

  .navbar-nav>.user-menu>.dropdown-toggle>img.user-image {
    width: 35px !important;
    height: 35px !important;
    margin-top: -3px !important;
    /* Vertically centered */
  }
}

/* =========================================
   2. GLOBAL STYLES (Desktop & Mobile)
   ========================================= */

/* Navbar Avatar (Base Desktop) */
.navbar-nav>.user-menu>.dropdown-toggle>img.user-image {
  width: 25px;
  /* Default desktop size */
  height: 25px;
  object-fit: cover;
  border-radius: 50%;
  margin-right: 8px;
}

/* Dropdown Header Avatar (Large) */
.user-menu>.dropdown-menu>.user-header {
  height: auto !important;
  padding: 15px !important;
  background-color: #3c8dbc;
  /* AdminLTE Blue */
}

.user-menu>.dropdown-menu>.user-header>img {
  width: 90px !important;
  height: 90px !important;
  border: 3px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  object-fit: cover;
  display: block;
  margin: 0 auto 10px auto;
}

.user-menu>.dropdown-menu>.user-header>p {
  font-family: "Inter", sans-serif;
  font-size: 16px;
  color: rgba(255, 255, 255, 0.9);
  margin-top: 5px;
}

/* General UI Polish */
body {
  font-family: "Inter", sans-serif;
}

.btn-primary {
  background-color: #2a5298;
  border-color: #20407b;
}

.btn-primary:hover {
  background-color: #1e3c72;
}

/* Loader */
#loading-overlay {
  background-color: rgba(255, 255, 255, 0.8);
  /* Lighter overlay */
}

.loader {
  border: 5px solid #f3f3f3;
  border-top: 5px solid #3c8dbc;
  /* Matches theme */
  border-radius: 50%;
  width: 50px;
  height: 50px;
  animation: spin 0.8s linear infinite;
}

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

  100% {
    transform: rotate(360deg);
  }
}

/* Login Page Styles (Preserved) */
.login-page-wrapper {
  background: #f4f6f9;
}

.hero-section {
  background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
  color: white;
}