@import url("https://fonts.googleapis.com/css2?family=Poppins&display=swap");

*,
::after,
::before {
  box-sizing: border-box;
}

.font-family {
  font-family: "Poppins";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(https://fonts.gstatic.com/s/poppins/v22/pxiEyp8kv8JHgFVrJJnecmNE.woff2)
    format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

.required-field::after {
  content: " *";
  color: red;
}

span {
  color: #28c986;
}

.js-sidebar {
  background-color: rgb(43, 155, 136) !important;
}

body {
  font-family: "Poppins" !important;
  font-size: 0.875rem;
  opacity: 1;
  overflow-y: scroll;
  margin: 0;
}

a {
  cursor: pointer;
  text-decoration: none;
}

li {
  list-style: none;
}

h5,
h4,
h2 {
  font-weight: 800;
  color: var(--bs-emphasis-color);
  text-align: center;
}

/* Layout for admin dashboard skeleton */

.wrapper {
  align-items: stretch;
  display: flex;
  width: 100%;
}

#sidebar {
  max-width: 264px;
  min-width: 264px;
  /* background: var(--bs-dark); */
  transition: all 0.35s ease-in-out;
}

.main {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-width: 0;
  overflow: hidden;
  transition: all 0.35s ease-in-out;
  width: 100%;
  background: var(--bs-light-bg-subtle);
}

/* Sidebar Elements Style */

.sidebar-logo {
  padding: 1.15rem;
}

.sidebar-logo a {
  color: #e9ecef;
  font-size: 1.15rem;
  font-weight: 600;
}

.sidebar-nav {
  list-style: none;
  margin-bottom: 0;
  padding-left: 0;
  margin-left: 0;
}

.sidebar-header {
  color: #e9ecef;
  font-size: 0.75rem;
  padding: 1.5rem 1.5rem 0.375rem;
}

a.sidebar-link {
  padding: 0.625rem 1.625rem;
  color: #ffffff;
  position: relative;
  display: block;
  font-size: 0.875rem;
}

.sidebar-link[data-bs-toggle="collapse"]::after {
  border: solid;
  border-width: 0 0.105rem 0.105rem 0;
  content: "";
  display: inline-block;
  padding: 3px;
  position: absolute;
  right: 2.5rem;
  bottom: 9px;
  transform: rotate(-135deg);
  transition: all 0.2s ease-out;
}

.sidebar-link[data-bs-toggle="collapse"].collapsed::after {
  transform: rotate(45deg);
  transition: all 0.2s ease-out;
}

.avatar {
  height: 40px;
  width: 40px;
}

/* Navbar*/
.navbar-nav .dropdown-menu {
  position: absolute;
  right: 0;
  left: auto;
  z-index: 1000;
  float: none;
  margin-top: 0;
}

/* Ensure the parent container has proper positioning */
.navbar-nav .nav-item.dropdown {
  position: relative;
}

/* Additional padding to ensure dropdown has space */
.navbar .dropdown-menu {
  min-width: 10rem;
  padding: 0.5rem 0;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

/* Ensure avatar has position relative */
.nav-icon {
  position: relative;
  display: inline-block;
}
.navbar {
  padding-top: 20px; /* Adjust as needed */
}

.navbar-expand .navbar-nav {
  margin-left: auto;
}
/* end of Navbar*/

.content {
  flex: 1;
  max-width: 100vw;
  width: 100vw;
}

@media (min-width: 768px) {
  .content {
    max-width: auto;
    width: auto;
  }
}

.card {
  box-shadow: 0 0 0.875rem 0 rgba(34, 46, 60, 0.05);
  margin-bottom: 24px;
}

/* Sidebar Toggle and General Responsiveness */

#sidebar.collapsed {
  margin-left: -264px;
}

/* Footer and Nav */

.footer {
  position: relative;
  width: 100%;
  font-size: 14px;
  box-shadow: 0px -2px 5px rgba(0, 0, 0, 0.1);
  color: rgb(44, 44, 44);
  background-color: #2a2a2b !important;
  color: #ffffff;
}

@media (max-width: 767.98px) {
  .js-sidebar {
    margin-left: -264px;
  }

  #sidebar.collapsed {
    margin-left: 0;
  }

  .navbar,
  footer {
    width: 100vw;
  }
}

.footer {
  background-color: rgb(36, 36, 36);
  color: #ffffff;
}

/* Theme Toggler */

.theme-toggle {
  position: fixed;
  bottom: 82%;
  transform: translateY(-65%);
  text-align: center;
  z-index: 10;
  right: 3px;
  left: auto;
  border: none;
  border-radius: 10px;
  background-color: var(--bs-body-color);
}

html[data-bs-theme="dark"] .theme-toggle .fa-sun,
html[data-bs-theme="light"] .theme-toggle .fa-moon {
  cursor: pointer;
  padding: 4px;
  display: block;
  font-size: 1.25rem;
  color: #259986;
}

html[data-bs-theme="dark"] .theme-toggle .fa-moon {
  display: none;
}

html[data-bs-theme="light"] .theme-toggle .fa-sun {
  display: none;
}

html[data-bs-theme="light"] .deleteChaptBtn {
  color: rgb(52, 52, 52);
}

html[data-bs-theme="dark"] .deleteChaptBtn {
  color: #259986;
}

html[data-bs-theme="light"] #exportModal div {
  background-color: white;
}

html[data-bs-theme="dark"] #exportModal div {
  background-color: rgb(52, 52, 52);
}

html[data-bs-theme="dark"] #exportModal h3 {
  color: rgb(247, 247, 247);
}

.custom-search-input {
  max-width: 400px; /* Adjust as needed */
  width: 100%; /* Ensures it adapts on smaller screens */
}

.custom-search-input::placeholder {
  color: rgb(134, 134, 134);
}

.search-bar {
  margin-bottom: 30px;
}

.search-btn {
  background-color: #259986;
  color: #f1f1f1;
}

.search-btn:hover {
  background-color: rgb(42, 168, 147);
  color: #ffffff;
}

@media (max-width: 768px) {
  .navbar {
    padding: 0.5rem 1rem; /* Adjust padding for smaller screens */
  }
  .footer {
    padding: 1rem; /* Ensure footer has padding on smaller screens */
  }

  .custom-search-input {
    max-width: 100%; /* Ensure search input takes full width on smaller screens */

    width: 100%;
  }
  .search-btn {
    padding: 8px 12px;
  }
}

.swiper {
  padding: 50px;
  width: 80%;
  max-width: 900px;
  margin-bottom: 20px;
  height: 100%;
}
.swiper-slide img {
  width: 100px;
  height: 150px;
  object-fit: contain;
  transition: transform 0.3s ease-in-out;
  filter: grayscale(100%);
}

.swiper-slide img:hover {
  transform: scale(1.2); /* Slightly increase size on hover */
}

.carousel-inner {
  justify-content: center;
  max-height: 400px; /* Adjust this height as needed */
  margin: 20px;
}

.carousel-item img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Ensures the image covers the area without stretching */
}

.ml {
  margin-bottom: 50px;
  margin-top: 50px;
}

.swiper-slide img:hover {
  filter: grayscale(0%);
}

.table img {
  width: 50px;
  height: 50px;
  border-radius: 50%;
}

/*members-profile css*/
.btn-edit {
  padding: 8px 8px;
  border-radius: 10px;
  margin-bottom: 15px;
  background-color: rgb(37, 153, 134);
  color: #ffffff;
  letter-spacing: 1px;
  box-shadow: 4px 4px 8px rgba(0, 0, 0, 0.1);
  transition: all 0.2s ease-in-out;
  border: none;
  font-size: 12px;
}

#editPhotoSection,
#uploadPhotoSection {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.cancel {
  padding: 10px 10px;
  border-radius: 10px;
  margin-bottom: 10px;
  background-color: rgb(108, 117, 125);
  color: #ffffff;
  letter-spacing: 1px;
  box-shadow: 4px 4px 8px rgba(0, 0, 0, 0.1);
  transition: all 0.2s ease-in-out;
  border: none;
  font-size: 12px;
  margin-left: 10px;
}

.cancel:hover {
  background-color: rgb(90, 98, 105);
  box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

input[type="file"]#photoInput {
  height: auto;
  padding: 3px 6px;
  font-size: 12px;
  width: 200px;
  justify-content: center;
}
/*end of members-profile css*/

/*masterlist css*/
.btn-add {
  padding: 8px 8px;
  border-radius: 4px;
  background-color: rgb(37, 153, 134);
  color: #ffffff;
  letter-spacing: 1px;
  box-shadow: 4px 4px 8px rgba(0, 0, 0, 0.1);
  transition: all 0.2s ease-in-out;
  border: none;
  font-size: 12px;
}

.btn-edit:hover,
.btn-add:hover,
.create-button:hover {
  background-color: rgb(40, 204, 177);
  box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
  color: aliceblue;
}
/*end of masterlist css*/

/*table*/
table td a {
  color: rgb(43, 155, 136); /* Change text color */
}

#usertables th {
  background-color: transparent !important;
  color: inherit !important;
}

th {
  cursor: pointer;
  color: rgb(255, 255, 255) !important;
  background-color: rgb(37, 153, 134) !important;
}

/* Optional: Adjust profile image on smaller devices */
@media (max-width: 576px) {
  .table img {
    width: 40px;
    height: 40px;
  }

  .btn-danger .btn-sm {
    padding: 5px 8px;
    font-size: 12px;
  }
}

.btn-danger {
  padding: 5px 8px;
  font-size: 12px;
}
.btn-sm {
  padding: 5px 8px;
  font-size: 11px;
}
/*table*/

.container {
  margin-top: 20px;
}

/* Modal styles */
.modal-content {
  border-radius: 12px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  border: none;
}

.modal-header {
  background-color: rgb(37, 153, 134);
  color: white;
  border-bottom: none;
}

.modal-body {
  padding-bottom: 5px;
}

/* Align buttons side by side with equal width */
.modal-footer {
  display: flex;
  justify-content: flex-end; /* Align to right */
  padding-top: 0;
  border-top: none;
}

/* Custom style for Add button only */
.btn-add-chapter {
  background-color: rgb(37, 153, 134);
  color: white;
  border: none;
  transition: all 0.2s ease-in-out;
  letter-spacing: 1px;
  font-size: 12px;
}

.btn-add-chapter:hover {
  background-color: rgb(40, 204, 177);
  color: white;
  box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

/* Ensure consistent style for Cancel button */
.modal-footer .btn-secondary {
  background-color: #6c757d;
  color: white;
  border: none;
  font-size: 13px;
}

.modal-footer .btn-secondary:hover {
  background-color: #5a6268;
  color: white;
}

.btn-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 15px;
  padding: 20px;
}

.btn-region {
  flex: 1 1 120px; /* Adjusts button width dynamically */
  text-align: center;
  padding: 10px 7px; /* Reduced vertical padding */
  font-size: 14px; /* Decreased font size */
  border-radius: 8px;
  background-color: #e9e9e9;
  color: #212121;
  letter-spacing: 1px;
  transition: all 0.3s ease;
  min-width: 130px; /* Minimum button width */
}

.btn-region a {
  text-decoration: none;
  color: inherit;
  display: block;
  width: 100%;
}

.btn-region:hover {
  background-color: rgb(40, 204, 177);
  transform: scale(1.05);
  color: #ffffff;
  box-shadow: 3px 3px 6px rgba(0, 0, 0, 0.2);
}

.btn-region:active {
  transform: scale(0.95);
}

/* Ensure buttons wrap properly in a container */
.btn-container {
  display: flex;
  flex-wrap: wrap;
  gap: 10px; /* Adds spacing between buttons */
  justify-content: center; /* Centers buttons */
}

.list-group-item {
  margin: 5px 0;
  font-size: 14px;
  word-spacing: 10px;
  display: flex;
  justify-content: space-between; /* Ensure even distribution */
  border: none;
  background-color: inherit;
  transition: all 0.1s ease-in-out;
}

.list-group-item:hover {
  background: #e3e3e3;
  transform: translateY(-2px);
  color: rgb(35, 35, 35);
}

/* Delete Button */
.delete-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 12px;
  color: #474747;
  transition: color 0.2s ease-in-out;
}

/*pagination*/
.pagination .page-item {
  margin: 0 5px;
}
.pagination .page-link {
  color: rgb(148, 148, 148);
  border: none;
  background: transparent;
  font-weight: normal;
  font-size: 14px;
}
.pagination .page-item.active .page-link {
  color: inherit;
  font-weight: bold;
  position: relative;
}

.pagination .page-item.active .page-link::after {
  content: "";
  display: block;
  width: 100%;
  height: 2px;
  background-color: #259986;
  position: absolute;
  bottom: -5px;
  left: 0;
}
.pagination .page-item.disabled .page-link {
  pointer-events: none;
  color: lightgray;
}
/* end of pagination*/

.user-image-preview {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 15px;
}

@media (max-width: 768px) {
  .user-image-preview {
    width: 120px;
    height: 120px;
  }
}

.loader-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  background: white;
  z-index: 1050;
}

.dots {
  width: 100px;
  height: 25.4px;
  background: radial-gradient(circle closest-side, rgb(37, 153, 134) 90%, #0000)
      0% 50%,
    radial-gradient(circle closest-side, rgb(37, 153, 134) 90%, #0000) 50% 50%,
    radial-gradient(circle closest-side, rgb(37, 153, 134) 90%, #0000) 100% 50%;
  background-size: calc(100% / 3) 100%;
  background-repeat: no-repeat;
  animation: dots-zcf63l 1s infinite linear;
}

@keyframes dots-zcf63l {
  33% {
    background-size: calc(100% / 3) 0%, calc(100% / 3) 100%, calc(100% / 3) 100%;
  }

  50% {
    background-size: calc(100% / 3) 100%, calc(100% / 3) 0%, calc(100% / 3) 100%;
  }

  66% {
    background-size: calc(100% / 3) 100%, calc(100% / 3) 100%, calc(100% / 3) 0%;
  }
}

.toggle-container {
  display: flex;
  align-items: center;
  cursor: pointer;
  width: 60px;
  height: 30px;
  background-color: #e5e7eb;
  border-radius: 999px;
  position: relative;
  transition: background 0.3s;
}

.toggle-slider {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 24px;
  height: 24px;
  background: white;
  border-radius: 50%;
  transition: transform 0.3s ease;
}

.toggle-container.active {
  background-color: lightblue;
}

.toggle-container.active .toggle-slider {
  transform: translateX(30px);
}

.toggle-icon {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  transition: opacity 0.3s ease;
  font-size: 16px;
}

.icon-off {
  left: 8px;
  color: #6b7280;
}

.icon-on {
  right: 8px;
  color: white;
  opacity: 0;
}

.toggle-container.active .icon-off {
  opacity: 0;
}

.toggle-container.active .icon-on {
  opacity: 1;
}

@media (max-width: 576px) {
  /* Targets small screens like mobile */
  #toggleDelete {
    transform: scale(0.8); /* Makes the toggle smaller */
  }

  .toggle-icon {
    width: 13px; /* Reduce SVG icon size */
    height: 13px;
  }

  .btn-add {
    font-size: 10px; /* Reduce button text size */
    padding: 8px 10px; /* Adjust button padding */
  }

  .btn-region {
    font-size: 12px; /* Reduce button text size */
    padding: 8px 7px; /* Adjust button padding */
  }

  .btn-custom {
    font-size: 10px; /* Reduce button text size */
  }
}

.region-badge {
  font-size: 0.7em;
  background-color: #f0f0f0;
  border-radius: 3px;
  padding: 2px 5px;
  margin-left: 5px;
  color: #666;
  white-space: nowrap;
}
