/*=============================================
=            GLOBAL & UTILITIES               =
=============================================*/
body {
  margin: 0;
  font-family:
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    Oxygen,
    Ubuntu,
    Cantarell,
    "Open Sans",
    "Helvetica Neue",
    sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

img {
  max-width: 100%;
  display: block;
}

.library-page-wrapper .container {
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1rem;
  padding-right: 1rem;
}
.library-page-wrapper .section-header {
  margin-bottom: 2rem;
}
.library-page-wrapper .section-title {
  font-weight: 700;
  color: #262626;
  font-size: 2rem;
  line-height: 2.75rem;
  margin: 0;
}
@media (min-width: 1024px) {
  .library-page-wrapper .section-header {
    margin-bottom: 2.5rem;
  }
  .library-page-wrapper .section-title {
    font-size: 2.5rem;
    line-height: 3.5rem;
    text-align: center;
  }
}

/*=============================================
=                 BREADCRUMBS                 =
=============================================*/
.library-page-wrapper .breadcrumbs {
  background-color: #fafafa;
}
.library-page-wrapper .breadcrumbs-container {
  display: flex;
  align-items: center;
  padding: 8px 0;
}
.library-page-wrapper .breadcrumbs__current-page {
  padding: 0.25rem 0.75rem;
}
.library-page-wrapper .breadcrumbs__current-page p {
  color: #404040;
  font-size: 0.875rem;
  font-weight: 500;
  margin: 0;
}

/*=============================================
=               BANNER SECTION                =
=============================================*/
.banner-section {
  position: relative;
  overflow: hidden;
  min-height: 546px;
  padding-top: 2.5rem;
  padding-bottom: 2.5rem;
  background: #edf7ff;
}
.banner-section__container {
  position: relative;
  z-index: 0;
}
.banner-section__text-content {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.banner-section__title {
  font-size: 40px;
  line-height: 56px;
  font-weight: 700;
  color: #262626;
  margin: 0;
}
.banner-section__description {
  color: #4b5563;
  line-height: 28px;
  margin: 0;
}
.banner-section__buttons {
  display: flex;
  flex-direction: column-reverse;
  gap: 1rem;
}
.banner-section__buttons .btn {
  font-weight: 600;
  padding: 10px 1rem;
  border-radius: 0.375rem;
  transition: all 0.3s ease;
  cursor: pointer;
  font-size: 1rem;
}
.banner-section__buttons .btn-primary {
  background-color: #a40000;
  color: white;
  border: 1px solid #a40000;
}
.banner-section__buttons .btn-primary:hover {
  background-color: white;
  color: #004aad;
  border-color: #004aad;
}
.banner-section__buttons .btn-secondary {
  background-color: transparent;
  color: #004aad;
  border: 1px solid #004aad;
}
.banner-section__buttons .btn-secondary:hover {
  background-color: #a40000;
  color: white;
  border-color: #a40000;
}
/* .banner-carousel-desktop {
  display: none;
} */
.banner-carousel-mobile {
  margin-top: 2rem;
  position: relative;
  width: 100%;
  height: 330px;
  overflow: visible;
}
/* Swiper Container Styles */
.banner-carousel-container {
  position: relative;
  z-index: 2;
}
.banner-swiper-container {
  width: 100%;
  height: 100%;
  padding-bottom: 92px;
}

@media (max-width: 1023px) {
  .banner-swiper-container {
    padding-bottom: 32px;
  }
  .swiper-slide .carousel-card-inner {
    transform: scale(0.9) !important;
  }
  .swiper-slide.swiper-slide-active .carousel-card-inner {
    transform: scale(1) !important;
  }
}

.banner-swiper-container .swiper-wrapper {
  align-items: center;
}
.banner-swiper-container .swiper-slide {
  width: 203px !important;
  height: 291px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.6s ease-out;
}
.banner-swiper-container .swiper-slide-active {
  width: 203px !important;
  height: 291px;
}
.carousel-card-inner {
  position: relative;
  border-radius: 1rem;
  width: 100%;
  height: 100%;
  overflow: hidden;
}
.carousel-card-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.carousel-card-overlay {
  position: absolute;
  inset: 0;
  background-color: rgba(255, 255, 255, 0.3);
  transition: all 0.5s;
  opacity: 1;
}
.banner-swiper-container .swiper-slide-active .carousel-card-overlay {
  opacity: 0;
}
/* Swiper Pagination Styles */
.banner-swiper-container .swiper-pagination {
  position: absolute;
  bottom: 0;
  left: 55%;
  transform: translateX(-50%);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
  z-index: 20;
  width: auto;
}
.banner-swiper-container .carousel-dot {
  width: 12px;
  height: 12px;
  transition: all 0.5s ease-out;
  background-color: #d1d5db;
  border-radius: 9999px;
  cursor: pointer;
  border: none;
  padding: 0;
  opacity: 1;
  margin: 0;
}
.banner-swiper-container .carousel-dot:hover {
  background-color: #9ca3af;
  transform: scale(1.1);
}
.banner-swiper-container .carousel-dot.swiper-pagination-bullet-active {
  background-color: #174ea2;
  width: 32px;
}

@media (min-width: 1024px) {
  .banner-swiper-container .swiper-pagination {
    bottom: 2.5rem;
  }
  .banner-section {
    display: flex;
    align-items: center;
  }
  .banner-section__text-content {
    width: 57%;
  }
  .banner-section__title {
    font-size: 60px;
    line-height: 72px;
    font-weight: 700;
  }
  .banner-section__description {
    margin: 0 0 8px;
  }
  .banner-section__buttons {
    flex-direction: row;
  }
  .banner-carousel-desktop {
    display: block;
    position: absolute;
    top: 0;
    right: 0;
    width: 40%;
    height: 100%;
  }
  .banner-carousel-desktop .banner-swiper-container {
    height: 100%;
    padding-left: 5.5rem;
    padding-top: 60px;
  }
  .banner-carousel-desktop .swiper-slide {
    width: 265px !important;
    height: 397px;
  }
  .banner-carousel-desktop .swiper-slide-active {
    width: 307px !important;
    height: 437px;
  }
  .banner-carousel-desktop .carousel-dot.swiper-pagination-bullet-active {
    width: 48px;
  }
  .banner-carousel-mobile {
    display: none;
  }
}

/*=============================================
=             WHY NEED SECTION                =
=============================================*/
.why-need-section {
  padding-top: 2.5rem;
}
.why-need-section__layout {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 1.5rem;
  align-items: center;
}
.why-need-section__cards {
  grid-column: span 12;
}
.why-need-section__image {
  grid-column: span 12;
}
.why-need-section__image img {
  width: 100%;
  height: auto;
  border-radius: 0.5rem;
}
.why-need-card {
  overflow: hidden;
  border-radius: 0 0.5rem;
  border: 1px solid var(--card-border-color);
  background-color: var(--card-background-color);
  padding: 1rem 1.5rem 1rem 90px;
  position: relative;
  margin-bottom: 1.5rem;
}
.why-need-card:last-child {
  margin-bottom: 0;
}
.why-need-card__title {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--card-color);
}
.why-need-card__description {
  color: #4b5563;
}
.why-need-card__description ul {
  list-style-type: disc;
  margin-left: 1.5rem;
  margin-top: 0.5rem;
  padding-left: 0;
}
.why-need-card__description li {
  margin-bottom: 0.25rem;
}
.why-need-card__icon-bg {
  position: absolute;
  width: 6rem;
  height: 3.75rem;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  top: -0.75rem;
  left: -2rem;
  transform: rotate(45deg);
  padding: 1.25rem;
  border-radius: 9999px;
}
.why-need-card__icon-wrapper {
  transform: rotate(-45deg);
}
.why-need-card__icon {
  width: 1.5rem;
  height: 1.5rem;
}
@media (min-width: 1024px) {
  .why-need-section {
    padding-top: 5rem;
  }
  .why-need-section__layout {
    gap: 2rem;
  }
  .why-need-section__cards {
    grid-column: span 7 / span 7;
  }
  .why-need-section__image {
    grid-column: span 5 / span 5;
  }
  .why-need-card {
    padding-left: 109px;
  }
  .why-need-card__title {
    font-size: 1.5rem;
  }
}

/*=============================================
=               CONTENT SECTION (FIXED)       =
=============================================*/
.content-section {
  padding-top: 2.5rem;
}
.content-section .section-header {
  margin-bottom: 1.5rem;
}
.content-section__grid {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}
.grid-row {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 2rem;
}
.content-item {
  height: 100%;
  min-height: 280px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.content-item--image {
  justify-content: center;
}
.content-item--image img {
  width: 100%;
  height: auto;
  max-width: 100%;
  object-fit: cover;
  border-radius: 0.5rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}
.content-item--text {
  background-color: #f5f5f5;
  padding: 1rem;
  justify-content: center;
  transition: all 0.3s ease;
  width: 100%;
  border-radius: 16px;
}
.content-item--text img {
  margin-bottom: 1rem;
  flex-shrink: 0;
  width: 7rem;
  height: 7rem;
}
.content-item--text h3 {
  font-weight: 600;
  color: #001f49;
  line-height: 24px;
  margin: 0;
  font-size: 14px;
}

/* Mobile Layout Fix (< 1024px) */
.grid-col-mobile-12 {
  grid-column: span 12 / span 12;
}
.grid-col-mobile-6 {
  grid-column: span 6 / span 6;
}
.content-item {
  min-height: unset;
}
.content-item--text {
  justify-content: start;
}

/* Desktop Layout */
@media (min-width: 1024px) {
  .content-section {
    padding-top: 5rem;
  }
  .content-section .section-header {
    margin-bottom: 2.5rem;
  }
  .grid-col-lg-3 {
    grid-column: span 3 / span 3;
  }
  .grid-col-lg-4 {
    grid-column: span 4 / span 4;
  }
  .grid-col-lg-5 {
    grid-column: span 5 / span 5;
  }
  .content-item--text.size-3 {
    padding: 1.5rem;
  }
  .content-item--text.size-3 h3 {
    font-size: 1rem;
  }
  .content-item--text.size-4 {
    padding: 1.5rem;
  }
  .content-item--text.size-4 h3 {
    font-size: 1.125rem;
  }
  .content-item--text img {
    width: auto;
    height: auto;
  }
}

/*=============================================
=           REPOSITORY FOR SECTION            =
=============================================*/
.repo-for-content {
  color: #262626;
}
.repo-for-section {
  padding-top: 2.5rem;
}
.repo-for-section-inner {
  background-color: #edf7ff;
  padding: 2.5rem 0;
}
.repo-for-section-inner .section-title {
  margin-bottom: 88px;
}
.repo-for-section__layout {
  display: flex;
  flex-direction: column-reverse;
  align-items: center;
  gap: 2rem;
}
.repo-for-section__image img {
  max-width: 100%;
  height: auto;
}
.repo-for-section__items {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
}
.repo-for-item {
  display: flex;
  gap: 1rem;
  align-items: center;
  padding: 12px 24px;
  border-radius: 9999px;
  background-color: white;
}
.repo-for-item p {
  margin: 0;
  font-size: 14px;
  line-height: 24px;
}
.repo-for-item img {
  width: 72px;
  height: 72px;
  flex-shrink: 0;
}
@media (min-width: 1024px) {
  .repo-for-section {
    padding-top: 5rem;
  }
  .repo-for-section-inner {
    padding: 5rem 0;
  }
  .repo-for-section__layout {
    flex-direction: row;
    align-items: center;
  }
  .repo-for-section__image {
    flex: 5;
  }
  .repo-for-section__items {
    flex: 7;
    max-width: 600px;
    margin: auto;
    gap: 37px;
  }
  .repo-for-item {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    padding: 1.5rem 2rem;
    border-radius: 9999px;
    background-color: white;
  }
  .repo-for-item[data-index="1"],
  .repo-for-item[data-index="2"] {
    margin-left: 2rem;
  }
  .repo-for-item p {
    font-size: 14px;
    line-height: 24px;
  }
}

/*=============================================
=              BENEFITS SECTION               =
=============================================*/
.benefits-section {
  padding-top: 2.5rem;
}
.benefits-section__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}
.benefit-card {
  overflow: hidden;
}
.benefit-card__image-wrapper {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 0.75rem;
}
.benefit-card__image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.benefit-card__content {
  padding-top: 1rem;
}
.benefit-card__title {
  font-size: 1.5rem;
  font-weight: 600;
  color: #262626;
  margin-top: 0;
  margin-bottom: 12px;
  line-height: 1.2;
}
.benefit-card__description {
  color: #4b5563;
  font-size: 1rem;
  line-height: 1.625;
  margin: 0;
}
@media (min-width: 768px) {
  .benefits-section__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1024px) {
  .benefits-section {
    padding-top: 5rem;
  }
  .benefits-section__grid {
    column-gap: 2rem;
    row-gap: 3.75rem;
  }
  .benefit-card__content {
    padding-top: 1.5rem;
  }
  .benefit-card__title {
    margin-bottom: 16px;
  }
}

/*=============================================
=                BOOKS SECTION                =
=============================================*/
.books-section {
  padding: 2.5rem 0;
}
.books-filters-desktop {
  display: none;
}
.books-filters-mobile {
  margin-bottom: 1.5rem;
  position: relative;
}
.books-filters-mobile select {
  width: 100%;
  padding: 0.75rem 1rem;
  background-color: white;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #262626;
  appearance: none;
  cursor: pointer;
}
.books-filters-mobile .select-arrow {
  position: absolute;
  right: 0;
  top: 14px;
  display: flex;
  align-items: center;
  padding: 0 1rem;
  pointer-events: none;
}
.books-grid {
  display: none;
}
.books-carousel-mobile {
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  padding-bottom: 1rem;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
}
.books-carousel-mobile::-webkit-scrollbar {
  display: none;
}
.book-card {
  display: block;
}
.book-card__image-wrapper {
  position: relative;
  aspect-ratio: 3 / 4;
  margin-bottom: 0.75rem;
  overflow: hidden;
  border-radius: 0.75rem;
  transition: all 0.3s ease;
  background-color: #f2f4f7;
}
.book-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all 0.3s ease;
}
.book-card:hover .book-card__image {
  transform: scale(1.05);
  transition: all 0.3s ease;
}
.book-card__title {
  font-weight: 600;
  color: #262626;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
}
@media (min-width: 1024px) {
  .books-section {
    padding: 5rem 0;
  }
  .books-filters-desktop {
    display: none; /* As per React logic, no desktop filters are shown */
  }
  .books-filters-mobile {
    display: none;
  }
  .books-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }
  .books-carousel-mobile {
    display: none;
  }
  .book-card__image {
    padding: 2.5rem 2.25rem;
  }
  .book-card__title {
    font-size: 1.5rem;
  }
}
@media (max-width: 1023px) {
  .books-carousel-mobile .book-card {
    flex-shrink: 0;
    width: 222px;
    scroll-snap-align: start;
  }
  .books-carousel-mobile .book-card__image {
    padding: 2rem 1.5rem;
  }
  .books-carousel-mobile .book-card__title {
    font-size: 0.875rem;
  }
  .repo-for-section-inner .section-title {
    margin-bottom: 32px;
  }
  .grid-row {
    gap: 20px;
  }
  .content-section__grid {
    gap: 20px;
  }
}
@media (min-width: 768px) and (max-width: 1023px) {
  .books-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
  }
}
@media (min-width: 1024px) {
  .books-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
  }
}
