/* Main Styles */
@import "https://fonts.googleapis.com/css?family=Poppins:300,400,500,600,700";

body,
html {
  font-family: 'Poppins', sans-serif;
  background: white;
  height: 100%;
  font-size: 0.8rem;
  */
}

/* Typography */
p,
td,
th,
tr {
  font-family: 'Poppins', sans-serif;
  font-size: 0.85rem !important;
}

a,
a:hover,
a:focus {
  color: inherit;
  text-decoration: none;
  transition: all 0.3s;
}


/* Utility Classes */
.bd-placeholder-img {
  font-size: 1.125rem;
  text-anchor: middle;
  user-select: none;
}

@media (min-width: 768px) {
  .bd-placeholder-img-lg {
    font-size: 3.5rem;
  }
}

/* Content Style */
#mainpage {
  width: calc(100% - 210px);
  transition: all 0.3s ease-in-out;
  padding: 10px;
  min-height: 100vh;
  margin-top: 10px;
  display: flex;
  flex-direction: column;
  margin-left: 210px;
  /* Add this line */
}

#mainpage.active {
  width: 100%;
  margin-left: 0;
}

/* Autocomplete UI section */
.ui-menu {
  font-size: 12px !important;; /* Increases font size - adjust this value as needed */
  font-family: inherit !important;; /* Inherits font family from body */
}

.ui-menu-item {
  font-family: inherit !important;;
}

.ui-menu-item-wrapper {
  font-family: inherit !important;;
  padding: 8px 12px; /* Optional: adds some padding for better readability */
}


/* Sidebar */

/* Modern Sidebar Styles */
#sidebar {
  width: 200px;
  background: linear-gradient(145deg, #1a1a1a, #000000);
  color: #ffffff;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: absolute;
  height: 100vh;
  z-index: 1000;
  left: 0;
  box-shadow: 2px 0 8px rgba(0, 0, 0, 0.3);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #333 #1a1a1a;
}

#sidebar::-webkit-scrollbar {
  width: 6px;
}

#sidebar::-webkit-scrollbar-track {
  background: #1a1a1a;
}

#sidebar::-webkit-scrollbar-thumb {
  background-color: #333;
  border-radius: 3px;
}


#sidebar.active {
  left: -200px;
}

#sidebar .sidebar-header {
  padding: 20px;
  background-color: black;
  color: white;
  text-align: center;
}

#sidebar ul.components {
  padding: 5px 0;
  background-color: black;
  color: white;
}

#sidebar ul p {
  color: white;
  padding: 10px;
  text-align: center;
}

#sidebar ul li a {
  padding: 8px;
  font-size: 1.2em;
  display: block;
  color: black !important;
  text-align: left !important;
}

#sidebar ul li a:hover {
  color: #007bff;
  background: rgba(255, 255, 255, 0.1);
}

#sidebar ul li.active>a,
a[aria-expanded="true"] {
  color: white;
  background: rgba(255, 255, 255, 0.2);
}

/* Dropdown styles */
#sidebar .dropdown-container {
  width: 100%;
  background-color: black;
}


#sidebar .btn-light {
  background-color: black;
  color: white;
  border: none;
  width: 100%;
  text-align: center;
}

#sidebar .dropdown-menu-custom {
  list-style-type: none;
  padding: 0;
}

#sidebar .dropdown-item-custom {
  color: white;
  text-align: center;
}

#sidebar .dropdown-item-custom:hover {
  background-color: rgba(255, 255, 255, 0.1);
}

/* Media Queries */
@media (max-width: 768px) {
  #sidebar {
    left: -250px;
  }

  #sidebar.active {
    left: 0;
  }

  #sidebarCollapse span {
    display: none;
  }

  #mainpage {
    width: 100%;
    margin-left: 0;
  }

  #mainpage.active {
    margin-left: 250px;
  }

  /* New full screen class for mobile */
  .active1 {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    margin: 0;
    padding: 0;
    z-index: 2000;
    /* Higher than sidebar to ensure it's on top */
    background-color: white;
    /* Or whatever background color you prefer */
    overflow-y: auto;
    /* Allow scrolling if content is taller than viewport */
    transition: all 0.3s ease-in-out;
    /* Match your existing transitions */
  }

  /* Optional: Adjust sidebar behavior when active1 is present */
  .active1~#sidebar {
    display: none;
  }

  /* Optional: Hide any scrollbars on the main body when active1 is present */
  body:has(.active1) {
    overflow: hidden;
  }
}




/* modal */
/* for xs screen, set modal width to 90% */
@media (max-width: 575.98px) {
  .modal-dialog {
    max-width: 90%;
    margin: 1.75rem auto;
  }
}


/* Navbar */
.navbar-brand {
  padding-top: .75rem;
  padding-bottom: .75rem;
  background-color: rgba(0, 0, 0, .25);
  box-shadow: inset -1px 0 0 rgba(0, 0, 0, .25);
}

.navbar .navbar-toggler {
  top: .25rem;
  right: 1rem;
}

.navbar .form-control {
  padding: .75rem 1rem;
}

.nav-link {
  padding: .5rem 1rem;
}

/* nav link on hover */
.nav-link:hover {
  background-color: rgba(0, 0, 0, .1);
}

/* Buttons */
.button-4 {
  appearance: none;
  background-color: #FAFBFC;
  border: 1px solid rgba(27, 31, 35, 0.15);
  border-radius: 6px;
  box-shadow: rgba(27, 31, 35, 0.04) 0 1px 0, rgba(255, 255, 255, 0.25) 0 1px 0 inset;
  color: blue;
  cursor: pointer;
  display: inline-block;
  font-size: 12px;
  font-weight: bold;
  line-height: 20px;
  padding: 2px 16px;
  position: relative;
  transition: background-color 0.2s cubic-bezier(0.3, 0, 0.5, 1);
  user-select: none;
  vertical-align: middle;
  white-space: nowrap;
  word-wrap: break-word;
}

.button-4:hover {
  background-color: #F3F4F6;
  text-decoration: none;
  transition-duration: 0.1s;
}

.button-4:disabled {
  background-color: #FAFBFC;
  border-color: rgba(27, 31, 35, 0.15);
  color: #959DA5;
  cursor: default;
}

.button-4:active {
  background-color: #EDEFF2;
  box-shadow: rgba(225, 228, 232, 0.2) 0 1px 0 inset;
  transition: none 0s;
}

.button-4:focus {
  outline: 1px transparent;
}


label {
  font-weight: bold;
  
}


/* Base table styles */
.searchable-table {
  width: 100%;
  margin-bottom: 1rem;
  background-color: transparent;
  padding: 5px;
}

/* Desktop view */
@media screen and (min-width: 601px) {
  .searchable-table {
    /* display: block; */
    max-height: calc(100vh - 400px);
    overflow-y: auto;
    overflow-x: auto;
    width: 100% !important;
    min-width: 100% !important;
  }
  
  .searchable-table table {
    width: 100% !important;
    min-width: 100% !important;
  }
}


/* Badges */
.badge-custom {
  display: inline-block;
  padding: 0.25em 0.6em;
  font-size: 75%;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
  vertical-align: baseline;
  border-radius: 0.25rem;
  color: #fff;
  background-color: #007bff;
  transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out;
}

.badge-custom:hover {
  color: #fff;
  text-decoration: none;
  background-color: #0056b3;
}

.dropdown-item-custom .badge-custom {
  margin-left: 5px;
}

/* date range filter section */

.date-range-list {
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
}

.date-range-list ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.date-range-list li {
  padding: 10px 15px;
  cursor: pointer;
  color: #333;
  background: #fff;
  transition: all 0.2s ease;
  border-bottom: 1px solid #f0f0f0;
  font-size: 12px;
}

.date-range-list li:last-child {
  border-bottom: none;
}

.date-range-list li:hover {
  background-color: #f8f9fa;
}

.date-range-list li.active {
  background-color: #e7f3ff;
  color: #0d6efd;
  font-weight: 500;
}

.date-range-list .custom-range {
  background-color: #f8f9fa;
  font-weight: 500;
  color: #0d6efd;
}

.date-range-list .custom-range.active {
  background-color: #e7f3ff;
}

/* Style for date inputs */
input[type="date"] {
  width: 100%;
  padding: 0.375rem 0.75rem;
  font-size: 1rem;
  line-height: 1.5;
  color: #212529;
  background-color: #fff;
  border: 1px solid #ced4da;
  border-radius: 0.25rem;
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}



/* Date Filter Card Styles */
.card {
  border: 1px solid rgba(0, 0, 0, 0.125);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  border-radius: 0.5rem;
  margin-bottom: 1.5rem;
}

.card-header {
  background-color: #f8f9fa;
  border-bottom: 1px solid rgba(0, 0, 0, 0.125);
  padding: 1rem 1.25rem;
  border-top-left-radius: 0.5rem;
  border-top-right-radius: 0.5rem;
}

.card-body {
  padding: 1.25rem;
}


.accordion-item {
    border: 1px solid rgba(0, 0, 0, 0.125);
    margin-bottom: 0.5rem;
    border-radius: 0.375rem;
}

.accordion-button {
    border: none;
    background-color: #e8f0fe;
    font-weight: 600;
    padding: 1rem 1.25rem;
    color: #333;
}

.accordion-button:not(.collapsed) {
    background-color: #e8f0fe;
    color: #000;
    box-shadow: none;
}

.accordion-button::after {
    color: #333;
}

.accordion-button:focus {
    box-shadow: none;
    border-color: rgba(0, 0, 0, 0.125);
}

.accordion-body {
    padding: 1rem 1.25rem;
    background-color: #ffffff;
}

.accordion-button:hover {
    background-color: #d3e3fd;
}

/* Status Background Styles */
.status-draft, .status-archived {
  background-color: lightgrey !important;
  font-weight: bold !important;
  border-radius: 20px !important;
}

.btn-primary, .btn-info, .btn-warning, .btn-danger, .btn-success {
  font-weight: bold !important;
}

.status-active, .status-in-transit {
  background-color: #17a2b8 !important;
  color: white !important;
  font-weight: bold !important;
  border-radius: 20px !important;
}

.status-cancelled, .status-closed, .status-could-not-deliver, .status-overdue {
  background-color: #dc3545 !important;
  color: white !important;
  font-weight: bold !important;
  border-radius: 20px !important;
}

.status-pending, .status-due {
  background-color: #ffc107 !important;
  color: black !important;
  font-weight: bold !important;
  border-radius: 20px !important;
}

.status-pending-stock, .status-partially-paid {
  background-color: #ff9800 !important;
  color: white !important;
  font-weight: bold !important;
  border-radius: 20px !important;
}

.status-confirmed, .status-delivered, .status-paid, .status-completed {
  background-color: #3cb371  !important;
  color: white !important;
  font-weight: bold !important;
  border-radius: 20px !important;
}

/* Text Status Styles */
.text-status-draft, .text-status-archived {
  color: lightgrey !important;
  font-weight: bold !important;
}

.text-status-active, .text-status-paid { 
  color: #28a745 !important;
  font-weight: bold !important;
}

.text-status-cancelled, .text-status-closed, .text-status-could-not-deliver, .status-overdue {
  color: #dc3545 !important;
  font-weight: bold !important;
}

.text-status-completed, .text-status-in-transit, .text-status-partially-paid {
  color: #17a2b8 !important;
  font-weight: bold !important;
}

.text-status-pending {
  color: #ffc107 !important;
  font-weight: bold !important;
}

.text-status-pending-stock {
  color: #ff9800 !important;
  font-weight: bold !important;
}

.text-status-confirmed, .text-status-delivered {
  color: #28a745 !important;
  font-weight: bold !important;
}
/* custom css for status - change */

