@media screen and (max-width: 2560px){
/* Reset margins and box-sizing */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Arial, sans-serif;
}

/* Center the form on the page */
body {
  background-color: #f8f9fa;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  margin: 0;
}

.logo {
  margin-bottom: 10px; /* Add spacing below the logo */
  transform: translateX(-10px); /* Moves the logo slightly to the left */
}

.logo img {
  max-width: 100px; /* Adjust size as needed */
  height: auto;
  display: block; /* Ensures the image behaves like a block element */
  margin: 0 auto; /* Centers the image horizontally */
}


.login-box {
  background: #ffffff;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  width: 100%;
  max-width: 400px;
  text-align: left;
}

.login-box h2 {
  text-align: center;
  margin-bottom: 20px;
  font-weight: bold;
  color: #333;
}

.input-group {
  display: flex;
  align-items: center;
}

.input-group-text, 
.form-control, 
#togglePassword {
  height: 40px; /* Ensure all elements are the same height */
}

.input-group-text {
  font-size: 1.2rem; /* Size for the icons */
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 20px;
}

.form-control {
  font-size: 1rem;
}

#togglePassword {
  border: 1px solid #ced4da; /* Match the border style of the input */
  border-left: none; /* Remove left border to align with input field */
  background-color: #f8f9fa;
  font-size: 0.9rem; /* Adjust font size to match input */
  padding: 0 10px;
  margin-bottom: 20px;
}

.form-control:focus, 
#togglePassword:focus {
  box-shadow: none;
}

/* Add hover effect for togglePassword */
#togglePassword:hover {
  background-color: #3c3d3e;
}


/************************************home.php *********************************************/



/*******************************************************************************
/++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++/

/* Minimized Sidebar */
#sidebar-reports.minimized {
    width: 70px; /* Minimized Sidebar Width */
}

/* Page Content Wrapper */
#page-content-wrapper {
    margin-left: 250px;
    transition: margin-left 0.3s ease; /* Smooth margin transition */
    width: calc(100% - 250px); /* Content width when sidebar is expanded */
}

/* When Sidebar is Minimized */
#page-content-wrapper.sidebar-minimized {
    margin-left: 70px; /* Move content left when minimized */
    width: calc(100% - 70px); /* Full width minus minimized sidebar */
}

/* Arrow Icon */
#arrowIcon {
    font-size: 20px;
    transition: transform 0.3s ease;
}

/* Ensure Sidebar Toggle button is hidden for larger screens */
#sidebarToggle {
    display: none;
}

/***************************************************************************
/+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++/



/* Sidebar */
#sidebar-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 250px; /* Sidebar width */
  background-color: #343a40;
  color: white;
  padding-top: 20px;
  z-index: 100; /* Sidebar on top */
  transition: width 0.3s ease;
  overflow-y: auto;
}


/* Sidebar Links */
#sidebar-wrapper .list-group-item {
  background-color: #343a40;
  color: white;
  border: none;
}

#sidebar-wrapper .list-group-item:hover {
  background-color: #495057;
}

#sidebar-wrapper .sidebar-header {
  font-size: 1.5rem;
  font-weight: bold;
  margin-bottom: 20px;
  transition: opacity 0.3s ease; /* Smooth hide/show effect */
}

.sidebar-header {
    color: white;               /* Set the text color to white */
    text-decoration: none;      /* Remove the underline */
    padding: 5px 0;            /* Add space between the text and other elements (adjust as needed) */
    display: block;             /* Make it a block element to allow padding and spacing */
}

.sidebar-header:hover {
    color: #f0f0f0;             /* Optional: Change color on hover for better visibility */
}


/* Top Bar */
#top-bar {
  padding: 0px 20px;
  background-color: #f8f9fa;
  position: fixed;
  top: 0;
  left: 250px; /* Align with the sidebar */
  width: calc(100% - 250px); /* Remaining width */
  z-index: 1; /* Ensure it stays on top */
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 50px;
}


/* Dashboard Section */
#dashboard {
  position: fixed;
  top: 50px; /* Adjust to keep below search bar */
  left: 250px;
  width: calc(100% - 250px); /* Remaining width */
  padding: 20px;
  z-index: 2; /* Ensure it's above other content */
  font-size: 2rem;
  font-weight: bold;
}



/************************************ Table Section*************************************/
/* Table Styling */
.table-box {
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
  max-height: 35.15625vw;
  overflow-y: auto;
  overflow-x:auto;
  max-width: 78.125vw;
  margin-top:100px;
}

.table {
  table-layout: auto; /* Allow content-based column width adjustment */
  width: 100%; /* Ensure the table spans the full available width */
  border-collapse: collapse; /* Merge cell borders */
}

.table th {
  background-color: #595b59;
  color: #fff;
  padding: 8px 12px;
  text-align: center;
  font-weight: bold;
  position: sticky; /* Make headers fixed */
  top: 0; /* Stick headers to the top */
  z-index: 2; /* Ensure headers stay above rows */
}

/* Table Body */
.table td {
  text-align: center;
  border-bottom: 1px solid #ddd;
  padding: 3px 12px;
  vertical-align: middle;
  min-width: 100px; /* Ensure columns have minimum width */
  white-space: nowrap; /* Prevent content from breaking into multiple lines */
  overflow: hidden;
}

.table tbody tr {
  height: auto; /* Let rows adjust based on content */
}

.table tbody tr:nth-child(odd) {
  background-color: #f9f9f9;
}

.table tbody tr:hover {
  background-color: #f1f1f1;
}

/* Scroll to Bottom Button */
#scrollToBottomBtn {
    position: fixed;
    bottom: 10px;
    right: 20px;
    background-color: grey;
    color: white;
    border: none;
    border-radius: 20%;
    padding: 5px; /* Reduced padding */
    font-size: 10px; /* Adjusted font size */
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: background-color 0.3s ease;
    z-index: 9999;
}


#scrollToBottomBtn:hover {
    background-color: #585858;
}

#scrollToBottomBtn i {
    margin: 0;
}
#scrollToBottomBtn:focus {
    outline: none;
}




/********************************Enter Truck Form CSS*******************************/

/* Body and container styling */
.container {
  max-width: 960px; /* Limits width for better layout control */
  width: 100%; /* Ensures responsiveness */
  margin: 30px auto;
  padding: 20px;
  background-color: #fff; /* White background for the form container */
  border-radius: 8px; /* Rounded corners for a cleaner look */
}

/* Heading styling */
h1.text-center {
  text-align: center;
  margin-top: 20px; /* Reduces the space above the heading */
  font-size: 28px;
  font-weight: 500; /* Makes the heading bold for better visibility */
  color: #333; /* Slightly darker color for better contrast */
}

/* Ensures the form content is scrollable */
#form {
  display: flex;
  flex-direction: column;
  max-height: 70vh; /* Uses a percentage of viewport height */
  overflow-y: auto; /* Enables vertical scrolling */
  padding-right: 10px; /* Prevents form fields from being cut off */
}

/* Styling for the form fields */
.form-control {
  width: 100%;
  padding: 12px; /* Larger padding for better field size */
  margin-bottom: 20px; /* Adds spacing between form fields */
  border: 1px solid #ccc; /* Light border for form fields */
  border-radius: 4px; /* Rounded corners for input fields */
  font-size: 16px; /* Ensures text inside inputs is readable */
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); /* Light shadow for depth */
}

.form-control:focus {
  border-color: #007bff; /* Blue border on focus */
  outline: none;
  box-shadow: 0 0 5px rgba(0, 123, 255, 0.5); /* Blue shadow for input focus */
}

/* Save button styling */
button.btn-primary {
  padding: 14px;
  font-size: 18px;
  background-color: #007bff; /* Button background color */
  color: #fff; /* White text */
  border: none;
  border-radius: 4px; /* Rounded button corners */
  cursor: pointer;
  transition: background-color 0.3s ease;
  margin-bottom: 50px;
}

button.btn-primary:hover {
  background-color: #0056b3; /* Darker shade on hover */
}

button.btn-primary:active {
  background-color: #003f7f; /* Even darker shade when button is pressed */
}

.btn-custom {
  color: #ffffff; /* Text color */
  background-color: #177ed9; /* Background color */
  margin-bottom: 20px;
}

.btn-custom:hover {
  color: #fff; /* Text color on hover */
  background-color: #105081; /* Darker background color on hover */
}

.selected-row {
  background-color: #fff5f0; /* Light blue background */
}


/* Styling based on status values */
.tag {
  background-color: rgb(98, 187, 98) !important;
}

.untag {
  background-color: rgb(218, 105, 105) !important;
}

.offline {
  background-color: grey !important;
  border-color: green !important;
}
.rabbit {
  background-color: rgb(241, 241, 125) !important;
}



/**************************************Reports**********************************/

.btn-signout {
color: #ffffff; /* Text color */
background-color: #9f2020; /* Background color */
}

.btn-signout:hover {
  background-color: #772424; /* Darker shade on hover */
  color:#ccc;
}

#sidebar-reports {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 250px; /* Sidebar width */
  background-color: #343a40;
  color: white;
  padding-top: 20px;
  z-index: 100; /* Sidebar on top */
  overflow-y: auto;
}

.form-control-reports{
  width: 100%;
  padding: 5px; /* Larger padding for better field size */
  border: 1px solid #ccc; /* Light border for form fields */
  border-radius: 4px; /* Rounded corners for input fields */
  font-size: 12px; /* Ensures text inside inputs is readable */
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); /* Light shadow for depth */
}

#sidebar-reports .sidebar-header {
  font-size: 1.5rem;
  font-weight: bold;
  margin-bottom: 20px;
}

.form-label-reports {
font-size: 0.8rem;
}

.form-select{
  padding:5px;
  font-size:12px;
}

.form-check-reports{
  margin-bottom: 5px;
  font-size: 0.8rem;
}

.btn-report1{
font-size: 0.9rem;
padding:5px;
color:#f4f4f4;
background-color: #5284c5;
}

.btn-report2{
  font-size: 0.9rem;
  padding:5px;
  color:#f4f4f4;
  background-color: #4d4f52;
  margin-top: 14px;
  }

  .btn-report3{
    font-size: 0.9rem;
    padding:5px;
    color:#f4f4f4;
    background-color: #0b791e;
    margin-top: 14px;
    }

  .btn-report1:hover {
    background-color: #709bd4; /* Darker shade on hover */
    color:#ccc;
    }

    .btn-report2:hover {
      background-color: #6c6f74; /* Darker shade on hover */
      color:#ccc;
    }

    .btn-report3:hover {
      background-color: #357a40; /* Darker shade on hover */
      color:#ccc;
    }

/*************************************Users.php*************************************/

#users-table{
overflow-y: auto;
max-height: 200px;
margin-top: 120px;
}

#users-container{
    overflow-y: auto; /* Enable vertical scrolling for the container */
    margin-top: 20px; /* Add some spacing below the dashboard */
}

.btn-register {
  font-size: 0.9rem;
  padding:5px;
  color:#f4f4f4;
  background-color: #5284c5;
  margin-bottom: 10px;
}

.btn-register:hover {
  background-color: #2f75cf; /* Darker shade on hover */
  color:#ffffff;
}
#user-select{
    font-size:1rem;
 }

.card {
  max-height: 250px; /* Limit the height of the card */
  overflow-y: auto; /* Enable scrolling for the card content */
  padding: 1px; /* Adjust padding to reduce extra space */
}
}






/***************************MOBILE ADJUSTMENTS******************************/
/***************************                  *****************************/
/***************************                  ****************************/
/* Adjustments for screens 768px and below */
@media (orientation: portrait) {

#sidebarToggle {
    display: block;
}

 .logo {
  margin-bottom: 10px; /* Add spacing below the logo */
  transform: translateX(-10px); /* Moves the logo slightly to the left */
}

.logo img {
    max-width: 80px; /* Adjust size to make logo smaller */
    height: auto;
    display: block;
    margin: 0 auto;
  }

  .login-box {
    background: #ffffff;
    padding: 15px; /* Reduced padding to make it smaller */
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    width: 300px; /* Reduce the width of the login box */
    text-align: left;
  }

  .login-box h2 {
    text-align: center;
    margin-bottom: 15px; /* Reduce margin to make it smaller */
    font-weight: bold;
    color: #333;
    font-size: 1.4rem; /* Make title font size smaller */
  }

  .input-group {
    display: flex;
    align-items: center;
    margin-bottom: 15px; /* Reduce margin between input fields */
  }

  .input-group-text, 
  .form-control, 
  #togglePassword {
    height: 35px; /* Reduce height of input fields */
    font-size: 0.9rem; /* Make font size slightly smaller */
  }

  .input-group-text {
    font-size: 1rem; /* Adjust icon size to match the smaller box */
    display: flex;
    justify-content: center;
    align-items: center;
  }

  .form-control {
    font-size: 0.9rem; /* Make font size of input fields smaller */
  }

  #togglePassword {
    border: 1px solid #ced4da;
    border-left: none;
    background-color: #f8f9fa;
    font-size: 0.8rem; /* Reduce font size for the toggle button */
    padding: 0 8px;
  }

  .form-control:focus, 
  #togglePassword:focus {
    box-shadow: none;
  }

  /* Add hover effect for togglePassword */
  #togglePassword:hover {
    background-color: #3c3d3e;
  }
 
}


/****************************************************************************/
/***************************************************************************/
/**************************************************************************/


/* Adjustments for screens 926px and below */
@media (max-width: 1024px) {
  
  .logo {
    margin-bottom: 10px; /* Add spacing below the logo */
    transform: translateX(-10px); /* Moves the logo slightly to the left */
    
  }
  
  .logo img {
    max-width: 120px; /* Adjust size for landscape */
    height: auto;
    display: block;
    margin: 0 auto;
  }
  
  .login-box {
    background: #ffffff;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    max-width: 100%; /* Make the box more flexible */
    text-align: left;
    height:auto;
    overflow-y: auto; /* Allow scrolling if content is too long */
  }
  
  .login-box h2 {
    text-align: center;
    margin-bottom: 10px;
    font-weight: bold;
    color: #333;
  }
  
  .input-group {
    display: flex;
    align-items: center;
    width: 100%;
  }
  
  .input-group-text, 
  .form-control, 
  #togglePassword {
    height: 45px; /* Increase height to match larger layout */
  }
  
  .input-group-text {
    font-size: 1.2rem;
    display: flex;
    justify-content: center;
    align-items: center;
  }
  
  .form-control {
    font-size: 1rem;
    width: 100%;
  }
  
  #togglePassword {
    border: 1px solid #ced4da;
    border-left: none;
    background-color: #f8f9fa;
    font-size: 0.9rem;
    padding: 0 12px;
    margin-bottom: 20px;
  }
  
  .form-control:focus, 
  #togglePassword:focus {
    box-shadow: none;
  }
  
  /* Add hover effect for togglePassword */
  #togglePassword:hover {
    background-color: #3c3d3e;
  }
  /* Success message styling */
 #successMessage {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background-color: #28a745; /* Green background for success */
  color: white;
  text-align: center;
  padding: 10px 0;
  font-size: 16px;
  font-weight: bold;
  z-index: 9999; /* Ensure it's above other content */
  transition: opacity 0.5s ease; /* Fade effect */
}

 /* Mobile-specific styling */
 #successMessage {
    font-size: 14px; /* Smaller font size for mobile devices */
    padding: 8px 0;
  }
  
 #errorMessage {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background-color: #FF0000; /* Green background for success */
  color: white;
  text-align: center;
  padding: 10px 0;
  font-size: 16px;
  font-weight: bold;
  z-index: 9999; /* Ensure it's above other content */
  transition: opacity 0.5s ease; /* Fade effect */
}

/* Mobile-specific styling */
 #errorMessage {
    font-size: 14px; /* Smaller font size for mobile devices */
    padding: 8px 0;
  }
 
  
  /* Topbar adjustment */
.topbar {
  position: fixed;
  width: calc(100% - 270px); /* Adjust width to accommodate the sidebar */
  top: 0;
  left: 250px; /* Align with the main content area */
  background-color: #343a40; /* Dark background for topbar */
  color: white;
  padding: 15px;
  z-index: 1000;
  height: 30px;
}

/* Dashboard section */
.dashboard {
  margin-top: 30px; /* Add space below the topbar */
  padding: 20px;
  background-color: #fff;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  z-index: 900;
  height: 50px; /* Adjust height if necessary */
}

/* Table Styling */
.table-box {
  position: absolute; /* Keeps the table positioned relative to its nearest positioned ancestor */
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
  overflow-y: auto;
  overflow-x: auto;
  width: auto;
  max-height: 40vw;
  top: 80px; /* Adjust this value to place the table below the dashboard */
  margin-left: -30%; /* Maintain horizontal positioning */
}


.table {
  table-layout: auto; /* Allow content-based column width adjustment */
  width: auto; /* Ensure the table spans the full available width */
  border-collapse: collapse; /* Merge cell borders */
  margin:0;
  
}
.sidebar-header {
    color: white;               /* Set the text color to white */
    text-decoration: none;      /* Remove the underline */
    padding: 5px 0;            /* Add space between the text and other elements (adjust as needed) */
    display: block;             /* Make it a block element to allow padding and spacing */
}

.sidebar-header:hover {
    color: #f0f0f0;             /* Optional: Change color on hover for better visibility */
}
}


/**********************SIDEBAR TOGGLE*************************/

/* Adjustments for screens 768px and below */
@media (orientation: portrait) {
    /* Sidebar */
    #sidebar-reports {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: 250px; /* Sidebar width */
        background-color: #343a40;
        color: white;
        padding-top: 20px;
        transition: width 0.3s ease;
    }

    /* Minimized Sidebar */
    #sidebar-reports.minimized {
        width: 70px; /* Minimized Sidebar Width */
    }

    /* Page Content Wrapper */
    #page-content-wrapper {
        margin-left: 250px;
        transition: margin-left 0.3s ease; /* Smooth margin transition */
        width: calc(100% - 250px); /* Content width when sidebar is expanded */
    }

    /* When Sidebar is Minimized */
    #page-content-wrapper.sidebar-minimized {
        margin-left: 70px; /* Move content left when minimized */
        width: calc(100% - 70px); /* Full width minus minimized sidebar */
    }

    /* Adjust the top bar when sidebar is minimized */
    #top-bar.sidebar-minimized {
        left: 70px; /* Adjust to minimize when sidebar collapses */
        width: calc(100% - 70px); /* Full width minus minimized sidebar width */
    }

    /* Adjust the dashboard when sidebar is minimized */
    #dashboard.sidebar-minimized {
        left: 70px; /* Adjust to minimize when sidebar collapses */
        width: calc(100% - 70px); /* Full width minus minimized sidebar width */
    }
}
