/*
Theme Name: PawsCare Child
Author: WebGeniusLab
Author URI: http://webgeniuslab.net
Description: -
Version: 1.0
Template: pawscare
Text Domain: pawscare-child
*/
.adoptable-animals-filters-grid{
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 24px;
    padding: 20px;
}

.adoptable-animals-grid{
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
  gap: 24px;
  padding: 20px;

}

.filters-card{
  border: 1px solid #ddd;
}

.filters-heading{
  text-align: center;
  
}

.filters-heading h3{
  margin: 10px 0px 5px 0px !important;
}

.my-filters select{
  margin-bottom: 10px !important;
}

.animal-card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.animal-card .hero-photo {
  border-radius: 4px;
  margin-bottom: 12px;
  background: #eee;
  height: 300px;
  width: 400px;

}

.flex-center{
    display: flex;
    justify-content: center;
}

.animal-card h3 {
  font-size: 1.5em;
  /* margin: 0 0 6px; */
  text-align: center;
  line-height: 1.5;
}

.animal-card .bonded {
  font-size: 0.9em;
  color: #555;
  margin-bottom: 12px;
}

.animal-card .card-tags{
    margin-bottom: 2px;
    padding: 2px 0px;
    background-color: #ddd;
    display: flex;
    justify-content: left;
    padding-left: 10px;
}

.card-tags {
  display: flex;
  justify-content: flex-start;
  align-items: flex-start;
  margin: 2px 0;
}

.card-tags strong{
  display: inline-block;
  width: 80px;   /* adjust width so all labels line up */
  font-weight: bold;
}

.animal-info-grid strong {
  display: inline-block;
  width: 200px;   /* adjust width so all labels line up */
  font-weight: bold;
}

.card-tags span {
  flex: 1;
}
.animal-card .description {
  font-size: 0.95em;
  color: #333;
  margin-bottom: 12px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  height: 80px;

}

.need-foster{
  color: #E66D74;
  text-align: center;
  margin-bottom: 5px;
  height: 35px;
}

.animal-card .info-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.9em;
  margin-bottom: 4px;
}


/* /single animal page layout/ */
.single-animal-container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 40px auto;
    max-width: 1400px;
}
.animal-media {
    flex: 1 1 35%;
}
.animal-media img,
.animal-media .placeholder {
    max-width: 100%;
    /* max-height: 400px;*/
    object-fit: contain;
    background: #eee;
}
.thumbnails {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}
.thumbnails img.thumb {
    width: 60px;
    height: 60px;
    object-fit: cover;
    cursor: pointer;
    border: 1px solid #ccc;
}
.animal-details, .animal-details-mobile {
    flex: 1 1 45%;
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.animal-header h1 {
    margin: 0;
}
.animal-header .needs-foster {
    color: #E66D74 ;
    font-weight: bold;
    font-family: 'Nunito Sans';
}
.animal-bio {
    font-size: 1rem;
    line-height: 1.5;
}
.animal-info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.animal-info-grid-mobile{
    margin-top: 10px;
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 10px;
}

.animal-info-grid-mobile strong{
  display: inline-block;
  width: 80px;   /* adjust width so all labels line up */
  font-weight: bold;
}

.social-share-mobile  p{
  margin-left: 10px;
}
.animal-actions .btn {
    text-align: center;
    display: inline-block;
    background: #76489D;
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    margin-right: 10px;
    width: 250px;
}

  .animal-actions-mobile{
    text-align: center;
  }
 .animal-actions-mobile .btn {
    text-align: center;
    display: inline-block;
    background: #76489D;
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    margin-right: 10px;
    width: 250px;
    margin: 5px;
}
.social-share {
    margin-top: 30px;
    display:flex;
    flex-direction: column;
    gap:10px;
    padding: 30px;
    justify-content: center;
}
.social-share .social {
    display: inline-block;
    margin-right: 10px;
    width: 200px;
    text-align: center;
}

.float-right{
  float: right;
}

.header-info .btn, .social-btn .social{
    display: inline-block;
    background: #76489D;
    color: white;
    padding: 10px 20px;
    text-decoration: none;
    margin-right: 10px;
}

.animal-details, .animal-details-mobile{
  flex: 1 1 45%;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 20px 20px;
  background: #ddd;
}
.header-info{
  display: flex;
  justify-content: space-between;
  /* align-items: center; */
}

.animal-details-mobile{
  max-width: 100%;
}

.animal-bio .description{
  max-height: 360px;   /* Adjust the height as needed */
  height: 360px;
   overflow-y: auto;  /* vertical scroll only when needed */
  overflow-x: hidden; /* hide horizontal scroll */
  padding-right: 10px; /* optional: adds spacing so text doesn't touch scrollbar */
  box-sizing: border-box;
  position: relative;
}

.animal-bio-mobile .description{
  max-height: 355px;   /* Adjust the height as needed */
  overflow-y: auto;  /* vertical scroll only when needed */
  overflow-x: hidden; /* hide horizontal scroll */
  padding-right: 10px; /* optional: adds spacing so text doesn't touch scrollbar */
  box-sizing: border-box;
  position: relative;
  margin-bottom: 20px;
}

.animal-bio .description::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 50px; /* height of fade effect */
}

.bg-grey{
  background-color: #ddd;
}

.action-btns, .social-btn{
  padding: 30px 0px;
  display: flex;
  justify-content: space-around;
}

/* slider css *////////////////////////////////////////////////
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}


.media-slider {
    max-width: 685px;
    /* margin: 0 auto; */
    margin-bottom: 10px;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.main-display {
    position: relative;
    height: 400px;
    background: #d3d3d3;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.main-display img,
.main-display video {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.media-placeholder {
    text-align: center;
    color: #666;
    font-size: 18px;
}

.media-placeholder h3 {
    margin-bottom: 10px;
    font-size: 24px;
}

.nav-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: #76489D;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10;
}

.nav-arrow:hover {
    background: rgba(255,255,255,0.95);
    transform: translateY(-50%) scale(1.1);
}

.nav-arrow.prev {
  left: 15px;
}

.nav-arrow.next {
  right: 15px;
}

.video-controls {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0,0,0,0.7);
  color: white;
  padding: 10px 20px;
  border-radius: 25px;
  font-size: 14px;
  display: none;
}

.video-controls.show {
  display: block;
}

.thumbnail-container {
  position: relative;
  padding: 20px;
  background: white;
}

.thumbnail-track {
  display: flex;
  gap: 15px;
  transition: transform 0.3s ease;
  overflow: hidden;
}

.thumbnail {
  /*min-width: 100px;*/
  height: 70px;
  background: #d3d3d3;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  border: 3px solid transparent;
}

.thumbnail:hover {
  transform: scale(1.05);
  border-color: #007cba;
}

.thumbnail.active {
  border-color: #007cba;
  box-shadow: 0 0 10px rgba(0,124,186,0.3);
}

.thumbnail img,
.thumbnail video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.thumbnail .play-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 20px;
  height: 20px;
  background: rgba(0,0,0,0.7);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
}

.thumbnail-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: #76489D;
  border: none;
  width: 35px;
  height: 35px;
  border-radius: 50%;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  /* padding: 10px 20px 6px; */
  padding: 7px 19px 7px;
}

.thumbnail-nav:hover {
  background:#58C5C7;
  transform: translateY(-50%) scale(1.1);
}

.thumbnail-nav.prev {
    left: 2px;
}

.thumbnail-nav.next {
    right: 2px;
}

.media-info {
    padding: 15px 20px;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
}

.media-title {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 5px;
}

.media-description {
    font-size: 14px;
    color: #666;
    line-height: 1.4;
}

@media (max-width: 600px) {
    .main-display {
        height: 250px;
    }
    
    .nav-arrow {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    .thumbnail {
        min-width: 70px;
        height: 50px;
    }
}



/* single animal page mobile screen style for order */

/* Default layout keeps desktop stacking */
.single-animal-container {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
}

.animal-details-mobile, .animal-actions-mobile, .social-share-mobile {
  display: none;
}

/* Mobile view */
@media screen and (max-width: 768px) {
  .animal-bio, 
  .animal-info-grid,
  .animal-actions,
  .social-share {
    display: none;
  }

  .animal-details-mobile, .animal-actions-mobile, .social-share-mobile {
    display: block !important;
  }
}


/* 📱 Mobile (up to 767px) */
/* 📱 Mobile */
@media (max-width: 767px) {
  .media-slider {
    max-width: 100vw;  /* 100% of viewport width */
  }

  .adoptable-animals-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    padding: 20px 0px;
  }

  .nav-arrow{
    padding: 12px;
  } 
  .animal-info-grid-mobile strong {
    width: 200px;
  }
}

/* 📱💻 Tablets (768px to 1024px) */
@media (min-width: 768px) and (max-width: 1024px) {
  .media-slider {
    max-width: 800px; /* adjust as needed */
  }
}

/* Mobile layout fix */
@media (max-width: 768px) {

  .animal-card .hero-photo {
    height: 210px;  /* override */
    width: 250px;   /* override */
  }
  .adoptable-animals-filters-grid {
    gap: 10px;
  }
  

  .single-animal-container {
    display: flex;
    flex-direction: column;
    margin-top: 0px !important;
  }

  /* Order fix for mobile */
  .animal-details .animal-header    { order: 1; } /* Hi, my name is... */
  .animal-media                     { order: 2; } /* Gallery */
  .animal-details-mobile            { order: 3; } /* Gallery */
  .animal-actions-mobile            { order: 4; }
  .social-share-mobile              { order: 5; }  
}

.nav-arrow:hover {
  background-color: #58C5C7;
}


.media-modal {
  display: none; 
  position: fixed; 
  z-index: 100000; 
  padding-top: 60px; 
  left: 0; top: 100px;
  width: 100%; height: 100%;
  overflow: auto; 
  background-color: rgba(0,0,0,0.9);
}

.media-modal-content {
  margin: auto;
  display: flex;
  justify-content: center;
  align-items: center;
  max-width: 90%;
  max-height: 90%;
}

.media-close {
  position: absolute;
  top: 20px; right: 35px;
  color: #fff; font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  z-index: 10000;
}

/* Tablet breakpoint (iPad portrait + landscape) */
@media (min-width: 768px) and (max-width: 1024px) {


  .animal-info-grid-mobile { 
    grid-template-columns: repeat(2, 1fr);
  }
  .adoptable-animals-filters-grid {
      display: grid;
      grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
      gap: 24px;
      padding: 20px;
  }
}