.gallery_fst_sec{
    margin-top: 125px;
    padding-bottom: 0px;
}
.gallery_fst_sec p{
    max-width: 100% !important;
}
/* nav */
.gallery-nav {
  margin-bottom: 50px;
}

.gallery-nav ul {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 35px;
  list-style: none;
  padding-left: 0;
}

.btn-filter {
  position: relative;
  color: #aaa;
  padding-bottom: 5px;
  font-weight: 600;
  font-size: 16px;
  transition: color .3s;
  background:none;
  border:none;
  text-transform: uppercase;
}

.btn-filter.current,
.btn-filter:hover {
  color: #212121;
}

.btn-filter::after {
  content: '';
  position: absolute;
  display: block;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 2px;
  background: #00B0C8;
  transform: translateX(-50%);
  transition: width .3s;
  z-index: -1;
}

.btn-filter.current::after,
.btn-filter:hover::after {
  width: 100%;
}

.gallery {
    position: relative;
    display: grid;
    grid-template-columns: auto auto auto;
    grid-gap: 10px;
    height: auto;
}

.card {
    position: relative;
    display: block;
    width:100% !important;
    overflow: hidden;
    left: auto !important;
    right: auto !important;
    height: auto !important;
    top: auto !important;
    border:none;
}

.card-wrap {
  position: relative;
  top: 0;
  transition: all .3s;
  transform: scale(1);
}

.card.show .card-wrap {
  transform: scale(1);
}

.card-img {
  position: relative;
  width: 100%;
  height: 0;
  padding-bottom: 65%;
  overflow: hidden;
}

.card-img img {
  position: absolute;
  display: block;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: translate(-50%, -50%);
}

.card-txt {
  position: absolute;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background: white;
  gap: 10px 0;
  width: 100%;
  height: 50%;
  text-transform: uppercase;
}

.card-txt strong {
  font-size: 16px;
  color: #000;
}

.card-txt em {
  font-size: 12px;
  color: #626262;
}
.card-img {
  transition: all .6s;
}
.card:hover .card-img{
    transform: scale(1.1);
}

/* modal */
.modal {
  position: fixed;
  display: none;
  justify-content: center;
  align-items: center;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.85);
  z-index: 100;

}
.outer_model {
  justify-content: center;
  align-items: center;
  display:flex;
width: 100%;
  height: 100%;
}
.inner_model {

    width: 100%;
    max-width: 800px;
    margin:auto;
    position:relative;
}
.modal-title {
  position: absolute;
  top: 0;
  left: 0;
  margin: 15px;
  font-size: 24px;
  font-weight: 700;
}

.img-wrap {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  height: 100%;
}

.modal-img {
  width:100%;
  height: 600px;
  object-fit: cover;
}

.modal-btn {
  position: absolute;
  display: block;
  font-size: 40px;
  line-height: 100%;
  font-weight: 700;
  color: #444;
  transition: all .5s;
}

.modal-btn[data-type=prev] {
  top: 50%;
  left: 5vw;
  transform: translateY(-50%);
}

.modal-btn[data-type=next] {
  top: 50%;
  right: 5vw;
  transform: translateY(-50%);
}

.modal-btn[data-type=close] {
    position: absolute;
    top: 12px;
    right: 15px;
    font-size: 32px;
    font-weight: 500;
    cursor: pointer;
    color: #333;
    z-index: 10;
    background: #fff;
    line-height: 30px;
    width: 30px;
    display: flex;
    text-align: center;
    align-items: center;
    justify-content: center;
    padding-bottom: 6px;
    border:none;
}
.prev_btn {
    border: none;
    font-size: 0px;
    left: 10px !important; 
    transform: scaleX(-1) !important;
    top: 46% !important;
}
.next_btn {
    border: none;
    font-size: 0px;
    right: 10px !important;
}

.modal-btn[data-type=close] .line:first-of-type {
  transform: translate(-50%, -50%) rotate(45deg);
}

.modal-btn[data-type=close] .line:last-of-type {
  transform: translate(-50%, -50%) rotate(-45deg);
}

/*.latest-update {*/
/*  background: #D0021B;*/
/*  color: #fff;*/
/*  padding: 6px 14px;*/
/*  border-radius: 3px;*/
/*  font-weight: 700;*/
/*  letter-spacing: 0.4px;*/
/*  animation: intenseFlicker 1.2s infinite;*/
/*  border-bottom:0px !important;*/
/*}*/
/*.latest-update:hover {*/
/*      color: #fff !important;*/
/*}*/
/*@keyframes intenseFlicker {*/
/*  0% {*/
/*    background-color: #D0021B;*/
/*    box-shadow: 0 0 0px #D0021B;*/
/*    filter: brightness(1);*/
/*  }*/
/*  25% {*/
/*    background-color: #FF1E2D;*/
/*    box-shadow: 0 0 6px #FF1E2D;*/
/*    filter: brightness(1.4);*/
/*  }*/
/*  50% {*/
/*    background-color: #A30014;*/
/*    box-shadow: 0 0 1px #A30014;*/
/*    filter: brightness(0.9);*/
/*  }*/
/*  75% {*/
/*    background-color: #FF1E2D;*/
/*    box-shadow: 0 0 8px #FF1E2D;*/
/*    filter: brightness(1.5);*/
/*  }*/
/*  100% {*/
/*    background-color: #D0021B;*/
/*    box-shadow: 0 0 0px #D0021B;*/
/*    filter: brightness(1);*/
/*  }*/
/*}*/



@media only screen and (min-device-width: 300px) and (max-device-width: 767px) {
    
    .inner_model {
        width: 90%;
    }
    .modal-img {
        height: 200px;
    }
    .next_btn , .prev_btn{
        width: 25px;
    }
    .next_btn img , .prev_btn img {
        width:100%;
    }
    .modal-btn[data-type=close] {
        line-height: 19px;
        width: 25px;
        font-size: 26px;
        top: 0;
        right: 0;
    }
    
    
    
    .gallery-nav ul {
        gap: 20px;
    }
    .gallery-nav {
        margin-bottom: 20px;
    }
    .gallery {
        grid-template-columns:auto;
        padding-left: 0;
    }
    .filter_sec {
        padding-bottom:0px;
    }
    
    .latest-update  {
        width:fit-content;
    }
}