.lightbox-icon{
   width:25px;
   z-index: 2147483647;
}

.lightbox-container {
  /* ... (other styles) ... */
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 999999;
  opacity: 0; /* Start with opacity 0 for animation */
  pointer-events: none; /* Prevent clicks on background when hidden */
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.3s ease; /* Add animation for opacity */
}

.lightbox-content {
  /* ... (other styles) ... */
  max-width: 90%;
  max-height: 90%;
  margin: auto;
  background-color: #fff;
  box-shadow: 0px 0px 20px rgba(0, 0, 0, 0.3);
  border-radius: 5px;
  overflow: auto;
  position: relative; /* Make the lightbox content container relative */
  text-align: center;
  display: flex;
  flex-direction: column; /* Stack text below image */
  justify-content: space-between; /* Keep text at the bottom */
  align-items: center; /* Center text horizontally */
  overflow-x: hidden !important;
}

.lightbox-img {
  max-width: 100%;
  max-height: 100%;
}

.close-button {
  position: absolute;
  top: 1%;
  right: 0.5%;
  cursor: pointer;
  font-size: 50px;
  color: #fff; /* Change the color to make it visible on a light background */
  z-index: 1; /* Ensure the close button appears above the image */
  width: 50px; /* Ensure width and height are the same for a perfect circle */
  height: 50px;
  text-align: center;
  line-height: 40px;
  border-radius: 50%; /* Define border-radius for both states */
  background-color: rgba(200, 200, 200, 0.5);
}

.close-button:hover{
  background-color: rgba(200, 200, 200, 0.4);
}

.close-button::before {
  position: absolute;
  content: '';
  top: -20px;
  left: -20px;
  right: -5px;
  bottom: -20px;
}


.image-container {
  position: relative;
  display: inline-block;
  margin: 10px;
}

.lightbox-button {
  padding: 11px; /* Slightly increased padding for better button size */
  background-color: #9b59b6; /* Purple color */
  color: #fff;
  font-size: 14px; /* Slightly reduced font size for a more balanced look */
  border: none;
  cursor: pointer;
  line-height: 1; /* Center the icon */
  border-radius: 35%; /* Add a circular border */
  transition: background-color 0.3s ease-in-out; /* Add a smooth transition effect */
  font-weight: bold;
}

.lightbox-button i {
    transition: transform 0.5s ease;
  }


.lightbox-button:hover {
  background-color: #8e44ad; /* Darker purple color on hover */
}




.search-icon{
  filter: invert(100%);
  -webkit-filter: invert(100%);
  -moz-filter: invert(100%);
   -o-filter: invert(100%);
  -ms-filter: invert(100%);
}

.lightbox-info {
    margin-top: 10px; /* Add spacing between image and text */
    font-size: 20px; /* Increase font size */
    color: #fff; /* Change text color to white */
    position: sticky; /* Make the text sticky */
    bottom: 0; /* Position at the bottom */
    background-color: rgba(43, 42, 42, 1); /* Dark background color */
    padding: 15px; /* Add padding for spacing */
    width: 100%; /* Full width */
    box-shadow: 0px -4px 8px rgba(0, 0, 0, 0.1); /* Add subtle shadow */
    display: flex;
    flex-direction: column;
    align-items: center;
}


.lightbox-image-title {
  flex: 1; /* Allow the title to take up available space */
  margin: 0; /* Reset default margin */
  font-size:22px !important;
}

.lightbox-download-buttons {
    margin-top: 15px;
    gap: 5px;
    display: block;
    overflow: hidden;
  }

.lightbox-download-buttons a.download-button {
  display: inline-block;
  text-decoration: none;
  padding: 8px 16px;
  background-color: #007bff;
  color: #fff;
  border-radius: 4px;
  text-align: center;
  margin: 0 10px !important;
  font-size:15px;
}

.lightbox-download-buttons .download-icon{
  width:20px;
  height:20px;
  filter: invert(100%);
  -webkit-filter: invert(100%);
  -moz-filter: invert(100%);
   -o-filter: invert(100%);
  -ms-filter: invert(100%);
  margin-right:3px;
}

.lightbox-button:before {
  content: "Zoom In";
  position: absolute;
  bottom: -30px; /* Adjust the vertical position */
  left: 50%;
  transform: translateX(-50%);
  background-color: black; /* Black background */
  color: white; /* White text color */
  padding: 5px 10px;
  border-radius: 4px;
  font-size: 14px;
  white-space: nowrap; /* Prevent text from wrapping */
  opacity: 0;
  transition: opacity 0.3s ease-in-out;
  z-index: -1;
}

.lightbox-button:hover:before {
  opacity: 1; /* Show the text on hover */
}

.modal{
  z-index: 9999999 !important;
}

.modal-backdrop{
  z-index: 9999998 !important;
}

.lightbox-nav {
  position: absolute;
  top: 50%; /* Position in the vertical center of the viewport */
  transform: translateY(-50%);
  background: none; /* Remove the background color */
  border: none;
  color: #fff;
  cursor: pointer;
  z-index: 999999999999997; /* Ensure the nav buttons appear above the lightbox content */
  margin:0 !important;
  visibility: visible; /* defaultly */
  display: inline-block;
  width: 50px;
  height: 50px;
  border-radius: 50%; /* Define border-radius for both states */
  background-color: rgba(200, 200, 200, 0.5);
  text-align: center;
}

.lightbox-nav:hover{
  background-color: rgba(200, 200, 200, 0.4);
}

.lightbox-nav > img {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}


.lightbox-nav-left {
  left: 1%; /* Position the left arrow button */
}

.lightbox-nav-right {
  right: 1%; /* Position the right arrow button */
}


.lightbox-nav-left::before {
  position: absolute;
  content: '';
  top: -20px;
  left: -5px;
  right: -20px;
  bottom: -20px;
}

.lightbox-nav-right::before {
  position: absolute;
  content: '';
  top: -20px;
  left: -20px;
  right: -5px;
  bottom: -20px;
}

/* Animation keyframes for shaking effect */
@keyframes shake {
  0%, 100% {
    transform: translateY(-50%) translateX(0); /* Maintain the vertical centering */
  }
  25% {
    transform: translateY(-50%) translateX(-2px);
  }
  50% {
    transform: translateY(-50%) translateX(2px);
  }
  75% {
    transform: translateY(-50%) translateX(-2px);
  }
}

@media all and (max-width: 768px) {
  .lightbox-content {
    max-width: 80%;
    max-height: 80%;
    /*margin: 0;
    position:absolute;
    top:10%;*/
  }

  .close-button {
    top: 1%;
    right: 1%;
    font-size: 20px;
    width: 40px;
    height: 40px;
  }

  .lightbox-download-buttons a.download-button {
    margin: 5px 5px !important;
    font-size: 12px;
  }

  /* Adjust styles for mobile devices */
  .lightbox-info {
    font-size: 16px;
    padding: 10px;
  }

  .lightbox-download-buttons > .download-button{
    font-size: 14px;
  }

  .lightbox-button {
    padding: 7px 10px;
    font-size:12px;
  }

  .lightbox-button::before {
    font-size:12px;
  }

  .lightbox-nav {
    width: 40px;
    height: 40px;
  }

  .lightbox-nav-left {
    left: 1%; /* Position the left arrow button */
  }

  .lightbox-nav-right {
    right: 1%; /* Position the right arrow button */
  }

  .lightbox-icon{
    width:20px;
  }

  .lightbox-image-title{
    font-size: 15px;
  }

  .lightbox-download-buttons a.download-button {
      margin: 3px 3px 7px 3px !important;
      font-size: 10px;
  }

  .lightbox-download-buttons a.download-button {
    display: inline-block;
    text-decoration: none;
    padding: 6px 10px;
    background-color: #007bff;
    color: #fff;
    border-radius: 4px;
    text-align: center;
  }

  .lightbox-download-buttons .download-icon{
    width:15px !important;
    height:15px !important;
    margin-right:2px !important;
  }
}