/**
 * Project Type Gallery CSS
 * Custom styles for project taxonomy gallery layout
 */

/* Body and Container Background */
body.tax-project_type {
  background-color: #000 !important;
}

#Content {
  background-color: #000 !important;
}

/* Gallery Container */
.project-gallery-container {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  background-color: #000 !important;
  padding: 0;
}

.project-gallery-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  margin: 0;
  padding: 0;
  background-color: #000 !important;
  justify-content: center;
}

/* Gallery Items - Base Styles */
.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: 0;
  transition: all 0.3s ease;
}

.gallery-item:hover {
  transform: none;
  box-shadow: none;
}

/* Width Classes for Pattern: 50/50, 30/70, 70/30 */
.gallery-item-50 {
  flex: 0 0 calc(50% - 10px);
  width: calc(50% - 10px);
}

.gallery-item-30 {
  flex: 0 0 calc(30% - 10px);
  width: calc(30% - 10px);
}

.gallery-item-70 {
  flex: 0 0 calc(70% - 10px);
  width: calc(70% - 10px);
}

/* Row Management */
.gallery-item.row-start {
  clear: left;
}

.gallery-item.row-end {
  margin-right: 0;
}

/* Project Item Styling */
.project-item {
  position: relative;
  height: 100%;
  background: #000 !important;
  border-radius: 0;
  overflow: hidden;
}

.project-image-wrapper {
  position: relative;
  width: 100%;
  height: 300px;
  overflow: hidden;
}
.project-hover-overlay
{
  position:absolute;
  background:#151515ab;
  width:100%;
  height:0;
  top:0;
  left:0;
  transition: all .4s;
  opacity:0;
}
.project-item:hover .project-hover-overlay{
  height:100%;
  opacity:1;
}

.project-hover-content{
  /* background:red; */
  position:absolute;
  top:0%;
  left:0%;
  width:100%;
  height:100%;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
}
.project-hover-title{
  font-size:23px;
  font-weight:bold;
  margin-bottom:10px;
  letter-spacing:1.5px
}
.project-hover-city{
  font-size:16px
}
.project-link {
  display: block;
  position: relative;
  width: 100%;
  height: 100%;
  text-decoration: none;
  color: inherit;
}

.project-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: none;
  border-radius: 0;
}

/* Grayscale filter utility for taxonomy images (used by taxonomy-project_type.php)
   Adds cross-browser support and a smooth transition when toggling the class. */
.gray-filter {
  -webkit-filter: grayscale(100%);
  filter: grayscale(100%);
  transition: filter 0.25s ease, -webkit-filter 0.25s ease;
}

.project-placeholder {
  width: 100%;
  height: 100%;
  background: #333;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #666;
  font-size: 3rem;
}

/* No Projects Found */
.no-projects-found {
  text-align: center;
  padding: 60px 20px;
  color: #fff;
}

.no-projects-found p {
  font-size: 1.2rem;
  margin: 0;
}

/* Responsive Design */

/* Large Tablets and Small Desktops */
@media (max-width: 1024px) {
  .gallery-item-50 {
    flex: 0 0 calc(50% - 10px);
    width: calc(50% - 10px);
  }

  .gallery-item-30 {
    flex: 0 0 calc(35% - 10px);
    width: calc(35% - 10px);
  }

  .gallery-item-70 {
    flex: 0 0 calc(65% - 10px);
    width: calc(65% - 10px);
  }

  .project-image-wrapper {
    height: 250px;
  }
}

/* Tablets */
@media (max-width: 768px) {
  .project-gallery-grid {
    gap: 15px;
  }

  .gallery-item-50,
  .gallery-item-30,
  .gallery-item-70 {
    flex: 0 0 100%;
    width: 100%;
  }

  .project-image-wrapper {
    height: 200px;
  }
}

/* Mobile Phones */
@media (max-width: 480px) {
  .project-gallery-container {
    padding: 0 10px;
  }

  .project-gallery-grid {
    gap: 10px;
  }

  .project-image-wrapper {
    height: 180px;
  }
}

/* Print Styles */
@media print {
  .project-item {
    break-inside: avoid;
    margin-bottom: 20px;
  }

  .gallery-item {
    border: 1px solid #ddd;
  }
}

/* High DPI / Retina Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
  .project-image {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
  }
}

/* Focus States for Accessibility */
.project-link:focus {
  outline: 3px solid #007cba;
  outline-offset: 2px;
}

/* Animation for Loading */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.gallery-item {
  animation: fadeInUp 0.6s ease forwards;
}

.gallery-item:nth-child(1) {
  animation-delay: 0.1s;
}
.gallery-item:nth-child(2) {
  animation-delay: 0.2s;
}
.gallery-item:nth-child(3) {
  animation-delay: 0.3s;
}
.gallery-item:nth-child(4) {
  animation-delay: 0.4s;
}
.gallery-item:nth-child(5) {
  animation-delay: 0.5s;
}
.gallery-item:nth-child(6) {
  animation-delay: 0.6s;
}

.sub-taxonomy-nav {
  padding: 15px 0;
  margin-bottom: 20px;
}

.sub-taxonomy-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: center;
  gap: 30px;
  flex-wrap: wrap;
}

.sub-taxonomy-nav li {
  margin: 0;
}

.sub-taxonomy-nav a {
  color: #ffffffc7;
  text-decoration: none;
  border-radius: 4px;
  transition: all 0.3s ease;
  font-size: 14px;
  text-transform: capitalize;
  letter-spacing: 0.5px;
}

.sub-taxonomy-nav a:hover {
  color: #fff;
}

.sub-taxonomy-nav a.current {
  color: #fff;
}


.charts-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  padding: 50px;
  max-width: 1440px;
  margin: 0 auto;
  flex-wrap: wrap;
}

.single-chart-wrapper {
  width: 30%;
  min-width: max(400, 30%);
  margin: auto;
}
@media screen and(max-width:768px) {
  .single-chart-wrapper {
    width: 90%;
    margin: auto;
  }
}
@media (max-width: 768px) {
  .filter-nav ul{
    flex-wrap:wrap;
    align-content:center;
    justify-content:center;
  }
  .charts-wrapper {
    flex-direction:column;

  }
  .single-chart-wrapper{
        width:100%;
    min-width:100%;
  }
  .sub-taxonomy-nav ul {
    gap: 15px;
  }

  .sub-taxonomy-nav a {
    font-size: 12px;
    padding: 6px 12px;
  }
}


.dod-gallery-modal{
  position: fixed;
  height: 100%;
  width:100%;
top: 0;
left: 0;
  z-index: 999!important;
  background: black;
justify-content: center;
align-items: center;
}

.dod-gallery-modal .close{
     position: fixed;
     right: 60px;
     top: 60px;
     cursor: pointer;
    }

.dod-gallery-modal img{
  max-width: 1100px!important;
  margin: auto!important;
    max-height: 80vh;
  object-fit: cover;
  width: 100%;
}

.dod-gallery-modal .prev,
.dod-gallery-modal .next{
  position: fixed;
  top:50%;
  cursor: pointer;
}

.dod-gallery-modal .prev{left: 40px;}
.dod-gallery-modal .next{right: 40px;}
