.loader-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.9); /* Light overlay */
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  transition: opacity 0.3s ease-in-out;
  opacity: 1;
}

#loader {
  width: 4.8px;
  height: 4.8px;
  display: block;
  margin: 20px auto;
  position: relative;
  border-radius: 4px;
  color: #115109;
  background: currentColor;
  box-sizing: border-box;
  animation: animloader 0.3s 0.3s linear infinite alternate;
}
#loader::after,
#loader::before {
  content: "";
  box-sizing: border-box;
  width: 4.8px;
  height: 4.8px;
  border-radius: 4px;
  background: currentColor;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: 15px;
  animation: animloader 0.3s 0.45s linear infinite alternate;
}
#loader::after {
  top: -15px;
  animation-delay: 0s;
}

@keyframes animloader {
  0% {
    width: 4.8px;
  }
  100% {
    width: 48px;
  }
}

.custom-bg-sidebar {
  background-color: #4e73df;
  background-image: linear-gradient(180deg, #4e73df 10%, #224abe 100%);
  background-size: cover;
}

.custom-bg-sidebar-header {
  background-color: #4e73df;
  background-size: cover;
}

/* Toast */
.colored-toast.swal2-icon-success {
  background-color: #a5dc86 !important;
}

.colored-toast.swal2-icon-error {
  background-color: #f27474 !important;
}

.colored-toast.swal2-icon-warning {
  background-color: #f8bb86 !important;
}

.colored-toast.swal2-icon-info {
  background-color: #0dcaf0 !important;
}

.colored-toast.swal2-icon-question {
  background-color: #87adbd !important;
}

.colored-toast .swal2-title {
  color: white;
}

.colored-toast .swal2-close {
  color: white;
}

.colored-toast .swal2-html-container {
  color: white;
}
/* Toast end */

/* landing page */

.custom-header-img-logo {
  height: 100px;
}

.custom-img-height {
  height: 250px;
}

/* landing page end */

/* Datatable page entry text */
div .dt-length .dt-input {
  margin-right: 5px !important;
}

/* TIMELINE */

.tracking-list {
  /* border: 1px solid #e5e5e5; */
  background: #fff;
  border-radius: 10px;
}

.tracking-list .tracking-item:first-child {
  font-weight: 700;
}

.tracking-item {
  border-left: 2px solid #e5e5e5;
  position: relative;
  padding: 2rem 1.5rem 0.5rem 2.5rem;
  font-size: 0.9rem;
  margin-left: 3rem;
  min-height: 5rem;
}

.tracking-item:last-child {
  padding-bottom: 4rem;
}

.tracking-item .tracking-date {
  margin-bottom: 0.5rem;
}

.tracking-item .tracking-date span {
  color: #888;
  font-size: 85%;
  padding-left: 0.4rem;
}

.tracking-item .tracking-content {
  padding: 0.5rem 0.8rem;
  background-color: #f4f4f4;
  border-radius: 0.5rem;
}

.tracking-item .tracking-content span {
  display: block;
  color: #888;
  font-size: 85%;
}

.tracking-item .tracking-icon {
  line-height: 2.6rem;
  position: absolute;
  left: -1.3rem;
  width: 2.6rem;
  height: 2.6rem;
  text-align: center;
  border-radius: 50%;
  font-size: 1.1rem;
  /* background-color: #e5e5e5; */
  /* color: #fff; */
  /* background-color: #d2f4e8; */
}

.tracking-bg-success {
  background-color: #d2f4e8;
}

.tracking-icon-success {
  color: #0f6848;
}

.tracking-bg-fail {
  background-color: #f8d7da;
}

.tracking-icon-fail {
  color: #78261f;
}

.tracking-item .tracking-icon {
  color: #fff;
  font-size: 1rem;
  padding-top: 12;
}

.tracking-item .tracking-icon i {
  padding-top: 12px;
  /* color: #0f6848; */
}

@media (min-width: 992px) {
  .tracking-item {
    margin-left: 11rem;
  }
  .tracking-item .tracking-date {
    position: absolute;
    left: -11rem;
    width: 8.5rem;
    text-align: right;
  }
  .tracking-item .tracking-date span {
    display: block;
  }
  .tracking-item .tracking-content {
    padding: 0;
    background-color: transparent;
  }
}

/* TIMELINE END */

/* custom font size */

.fs-12 {
  font-size: 12px;
}

/* custom font size end*/

/* custom modal content */

.custom-modal-content {
  height: 100% !important;
}

/* custom modal content end */

/* custom bg-color */

.bg-gray3 {
  background-color: #858796;
}

/* custom bg-color end */

/* select2 size */
.select2-container .select2-selection--single {
  height: 40px !important;
}

.select2-container .select2-selection--single .select2-selection__rendered,
.select2-container--bootstrap-5
  .select2-selection--single
  .select2-selection__rendered
  .select2-selection__placeholder {
  line-height: 2 !important;
}

.is-invalid + .select2-container--bootstrap-5 .select2-selection,
.was-validated
  select:invalid
  + .select2-container--bootstrap-5
  .select2-selection {
  border-width: 2px;
}
/* select2 size */

/* 𝗔𝗗𝗟 Subtle borders between rows, better spacing on mobile */
#update_adl_modal .card .border-bottom {
  border-color: rgba(0, 0, 0, 0.06) !important;
}
#update_adl_modal .form-control-plaintext {
  min-height: 38px;
}
@media (max-width: 767.98px) {
  #update_adl_modal .form-text {
    margin-top: 0.25rem;
  }
}

/*  𝗔𝗗𝗟 Accordion & cards */
.accordion-item .accordion-button {
  box-shadow: none;
}
.accordion-item .accordion-button:not(.collapsed) {
  filter: brightness(0.95);
}

/*  𝗔𝗗𝗟 Inputs */
.input-group-text {
  min-width: 42px;
  justify-content: center;
}

/* 𝗔𝗗𝗟 Datatable area */
#adl_form_dt {
  border-radius: 0.5rem;
  overflow: hidden;
}
.table-hover tbody tr:hover {
  background-color: rgba(0, 0, 0, 0.03);
}

/* .table.custom-hover {
  border-radius: .5rem;
  overflow: hidden;
}
.table-hover tbody tr:hover { background-color: rgba(0,0,0,.03); } */

.table.custom-hover thead th {
  background-color: #007bff;
  color: #fff;
  text-align: center;
  border-bottom: 2px solid #ddd;
}

.table.custom-hover.table-striped tbody tr:nth-of-type(odd) {
  background-color: #f8fbff; /* very light blue */
}

.long-button {
  width: 800px; /* or a percentage like 80% */
  max-width: 100%; /* Ensures responsiveness */
  height: 35px;
  font-size: 14px;
  border-radius: 8px; /* Optional for rounded edges */
}

/* Navbar alingment */
/* Ensure Navigation Items Wrap */
.nav-item {
  display: block; /* Ensure items are treated as block elements */
  padding: 10px 15px;
}

.nav-item a {
  display: flex;
  align-items: center;
  width: 100%;
  text-decoration: none;
  overflow: hidden; /* Prevent horizontal scrolling */
}

.nav-item p {
  display: block; /* Ensure the title behaves like a block element */
  margin: 0;
  white-space: normal; /* Allow text to wrap */
  word-break: break-word; /* Break long words */
  overflow: visible; /* Allow content to expand */
  line-height: 1.2; /* Adjust spacing for readability */
  font-size: 14px;
}

/* Fix for Collapsible Items */
.collapse {
  margin-left: 15px; /* Optional slight indent for collapsed items */
}

.collapse.show p {
  white-space: normal; /* Ensure expanded items wrap */
}

/* Submenu Styles */
.submenu {
  padding-left: 20px; /* Indent submenu items */
}

.submenu p {
  font-size: 12px; /* Smaller font size for submenus */
  white-space: normal; /* Allow wrapping in submenus */
  word-break: break-word; /* Handle long submenu titles */
}
.nav-item p {
  max-width: 250px; /* Set a reasonable width for wrapping */
  width: 100%; /* Ensure it takes full space */
}
.nav-item a,
.nav-item p {
  white-space: normal !important; /* Force wrapping, overriding Bootstrap styles */
  word-break: break-word !important; /* Force breaking long words */
  overflow: visible !important; /* Ensure visibility of wrapped text */
}
/* Navbar alingment END*/

/* =========================================================
   UNIVERSAL DATATABLE ALIGNMENT (custom.css)
   Applies consistent alignment to all tables
   ========================================================= */

/* 1) Vertical-center all header/body cells */
.dataTable th,
.dataTable td,
.table th,
.table td {
  vertical-align: middle !important;
}

/* 2) Center headers for a clean uniform look */
.dataTable thead th,
.table thead th {
  text-align: center !important;
}

/* 3) Center the first column (often Actions or Select) */
.dataTable th:first-child,
.dataTable td:first-child,
.table th:first-child,
.table td:first-child {
  text-align: center !important;
}

/* 4) Center the second column (e.g., No., Date, etc.) */
.dataTable th:nth-child(2),
.dataTable td:nth-child(2),
.table th:nth-child(2),
.table td:nth-child(2) {
  text-align: center !important;
}

/* 5) Keep long-text columns left-aligned for readability */
.dataTable th:nth-child(3),
.dataTable td:nth-child(3),
.dataTable th:nth-child(4),
.dataTable td:nth-child(4),
.dataTable th:nth-child(5),
.dataTable td:nth-child(5),
.dataTable th:nth-child(6),
.dataTable td:nth-child(6),
.table th:nth-child(3),
.table td:nth-child(3),
.table th:nth-child(4),
.table td:nth-child(4),
.table th:nth-child(5),
.table td:nth-child(5),
.table th:nth-child(6),
.table td:nth-child(6) {
  text-align: left !important;
  white-space: normal; /* wrap long text nicely */
}

/* 6) Center buttons in the first two columns */
.dataTable td:nth-child(-n + 2) .btn,
.table td:nth-child(-n + 2) .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* 7) Optional: smoother hover effect for all tables */
.table-hover tbody tr:hover td {
  background-color: rgba(0, 0, 0, 0.03);
}

/* Full width container */
.dashboard-wrapper {
  max-width: 100%;
  padding: 0 25px;
}

/* Bigger elegant cards */
.province-card {
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: 0.25s ease;
  height: 320px; /* FINAL SIZE (balanced, readable, elegant) */
  display: flex;
  flex-direction: column;
}

/* Hover animation */
.province-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.15);
}

/* Province header with white font */
.province-header {
  padding: 16px 26px;
  font-size: 1rem;
  font-weight: 800;
  color: #fff;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  letter-spacing: 0.5px;
}

/* Body aligned center */
.province-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  padding: 25px 10px;
}

/* Big number */
.province-value {
  font-size: 2.8rem;
  font-weight: 900;
  margin-bottom: 5px;
}

/* Label */
.province-label {
  font-size: 0.9rem;
  color: #6c757d;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Province header colors */
.cavite-header {
  background: #f5c400;
}
.laguna-header {
  background: #fd7e14;
}
.batangas-header {
  background: #28a745;
}
.rizal-header {
  background: #0d6efd;
}
.quezon-header {
  background: #d63384;
}

/* Value text colors */
.text-cavite {
  color: #f5c400;
}
.text-laguna {
  color: #fd7e14;
}
.text-batangas {
  color: #28a745;
}
.text-rizal {
  color: #0d6efd;
}
.text-quezon {
  color: #d63384;
}

#add_work_program_modal .select2-selection--multiple {
  display: flex;
  flex-wrap: wrap;
  min-height: 38px;
}

#add_work_program_modal .select2-selection__rendered {
  display: flex !important;
  flex-direction: column;
  gap: 4px;
}

#add_work_program_modal .select2-selection__choice {
  white-space: normal !important;
  word-break: break-word;
}

#update_work_program_modal .select2-container {
  width: 100% !important;
}

#update_work_program_modal
  .select2-container--default
  .select2-selection--multiple {
  min-height: 38px;
  border: 1px solid #ced4da;
  border-radius: 0.375rem;
  padding: 0.25rem 0.5rem;
  white-space: normal !important;
  height: auto !important;
}

#update_work_program_modal .select2-selection__rendered {
  display: flex !important;
  flex-wrap: wrap;
  gap: 4px;
}

#update_work_program_modal .select2-selection__choice {
  white-space: normal !important;
  word-break: break-word;
  max-width: 100%;
}
