/* Base Styles (Desktop) */
:root {
  --services_container: 120rem;
  --primary: #fff;
  --white: hsl(0, 0%, 100%);
  --white-light: hsl(0, 0%, 99%);
  --box-shadow: hsl(220, 7.32%, 91.96%);
}

.services_container {
  max-width: var(--services_container);
  padding: 0 1rem;
  margin: 0 auto;
}

.paa {
  text-align: center;
}

.section-heading {
  margin: 3rem 0;
  font-size: 2.6rem;
  padding-bottom: 0.7rem;
  position: relative;
  display: inline-block;
  color: #000;
}

.section-heading::before,
.section-heading::after {
  content: "";
  position: absolute;
}

.section-heading::before {
  width: 100%;
  height: 0.2rem;
  bottom: 0;
  left: 0;
  background: #000;
  border-radius: 0.2rem;
}

.section-heading::after {
  bottom: -0.4rem;
  left: 50%;
  transform: translateX(-50%);
  width: 1rem;
  height: 1rem;
  border: 0.2rem solid #000;
  background: var(--box-shadow);
}

.tab-container {
  /* width: 70%; */
  width: 74%;
  margin: 40px auto 3rem auto;
}

.tab-filter-container {
  padding: 1rem;
  text-align: center;
  background: hsl(205.71, 30.43%, 95.49%);
}

.filter-btn {
  display: inline-flex;
  /* padding: 0.8rem 2.5rem; */
  padding: 0.5rem 1.5rem;
  cursor: pointer;
  border-radius: 2rem;
  align-items: center;
  gap: 0.5rem;
  font-weight: 500;
  font-size: 16px;
}

.filter-btn.active {
  background: #04146b;
  color: var(--white);
}

.tab-filter-item-container {
  margin: 20px auto;
  position: relative;
  overflow: hidden;
  height: 460px !important;
}

.tab-item {
  width: 95%;
  height: 100%;
  position: absolute;
  padding: 0rem 3rem;
  transform: translateY(100%);
  background: var(--white-light);
  transition: transform 0.5s ease-in-out;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(29rem, 1fr));
  place-items: center start;
}

.tab-img {
  width: 32rem;
  border-radius: 20px;
}

.tab-heading {
  /* padding: 2rem 0; */
  padding: 1rem 0;
  font-size: 1.4rem;
  color: #000;
}

.tab-item.select_tab {
  transform: translateY(0);
  transition: transform 0.5s ease-in-out;
  background: var(--white-light);
  animation: fadeIn 0.6s ease-in-out;
}

.btn-primary {
  margin-top: 1.5rem;
  display: inline-block;
  background: var(--primary);
  padding: 0.6rem 2rem;
  border-radius: 2rem;
  color: var(--white);
}

@keyframes fadeIn {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

/* Medium screens (tablets) */
@media (max-width: 1024px) {
  .services_container {
    max-width: 90rem;
    padding: 0 1rem;
  }

  .section-heading {
    font-size: 2.2rem;
  }

  .tab-container {
    width: 80%;
  }

  .tab-item {
    padding: 0 2rem;
    grid-template-columns: 1fr;
    place-items: center;
  }

  .tab-img {
    width: 28rem;
  }
}

/* Small screens (mobile) */
@media (max-width: 767px) {
  .services_container {
    max-width: 100%;
    padding: 0 0.5rem;
  }

  .section-heading {
    font-size: 1.8rem;
  }

  .tab-container {
    width: 90%;
  }

  .tab-filter-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
  }

  .filter-btn {
    padding: 0.6rem 1.5rem;
    font-size: 14px;
  }

  .tab-item {
    padding: 0 1rem;
    grid-template-columns: 1fr;
    place-items: center;
  }

  .tab-img {
    width: 100%;
    max-width: 24rem;
  }

  .tab-heading {
    font-size: 1.5rem;
  }
}


@media (min-width:300px) and (max-width:1276px){
  .tab-filter-item-container {
    height: 750px !important;
  }
}