/* Container for overall search results */
.custom-search-results {
  margin: 0 auto;
  max-width: 1680px;
}

/* Search header styling */
.search-header h2 {
  font-family: 'Roboto', sans-serif;
  font-weight: 700;
  font-size: 48px;
  line-height: 57.6px;
  letter-spacing: 0;
  color: #03008D;
  margin-bottom: 40px;
}

/* Pour que le préfixe ne soit pas en gras */
.search-header h2 .search-prefix {
  font-weight: 400;
}

/* Each CPT section spacing */
.cpt-section {
  margin-bottom: 40px;
}

/* Horizontal divider between CPT sections */
.cpt-divider {
  display: block;
  width: 100%;
  border: none;
  border-top: 1px solid #D7D7F6;
  margin-top: 20px;
  margin-bottom: 20px !important;
}


/* Header: CPT title on left, view more button on right */
.cpt-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

/* CPT Title styling above cards */
.cpt-header h2 {
  font-family: 'Roboto', sans-serif;
  font-weight: 700;
  font-size: 48px;
  line-height: 57.6px;
  letter-spacing: 0;
  color: #03008D;
  margin: 0;
  display: inline-flex;
  align-items: center;
}

/* Results count styling */
.results-count {
  background-color: #03008D;
  color: #fff;
  border-radius: 10px;
  padding: 4px 8px;
  font-size: 14px;
  margin-left: 10px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
}

/* "Voir plus" button styling */
.view-more-btn {
  padding: 10px 20px;
  background-color: #31A912;
  color: #fff;
  text-decoration: none;
  border-radius: 30px;
  font-family: 'Roboto', sans-serif;
  font-weight: 700;
  font-size: 16px;
  transition: background-color 0.3s ease;
}

.view-more-btn:hover {
  background-color: #03008D;
  color: #fff;
}

/* Cards container: displays 4 cards in a row */
.cards-container {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

/* Individual card styling */
.card {
  width: calc(25% - 20px); 
  background-color: #fff;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.card-content {
  padding-top: 10px;
}

/* Card image area styling */
.card-image {
  background-size: cover;
  background-position: center;
  height: 200px;
  position: relative;
  border-top-left-radius: 10px;
  border-top-right-radius: 10px;
}

/* Label in the bottom left of the image */
.cpt-label {
  position: absolute;
  bottom: 10px;
  left: 10px;
  background-color: #31A912;
  color: #fff;
  font-family: 'Roboto', sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 24px;
  letter-spacing: 0;
  padding: 5px 10px;
  border-radius: 4px;
}

.cpt-label-fixed {
  background-color: #31A912;
  color: #fff;
  font-family: 'Roboto', sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 24px;
  letter-spacing: 0;
  padding: 5px 10px;
  border-radius: 4px;
  margin-left: 10px;
  margin-right: 10px;
  margin-bottom: 20px;
}

/* Card title area styling */
.card-title {
  padding: 20px;
  font-family: 'Roboto', sans-serif;
  font-weight: 700;
  font-size: 24px;
  line-height: 33px;
  letter-spacing: 0;
  color: #03008D;
  border-bottom-left-radius: 10px;
  border-bottom-right-radius: 10px;
}

/* Ensure title links inherit the text styling */
.card-title a {
  color: inherit;
  text-decoration: none;
}

/* No results styling */
.no-results {
  background-color: #fff;
  border-radius: 30px;
  padding: 20px;
  color: #03008D;
  text-align: center;
  width: 100%;
  font-family: 'Roboto', sans-serif;
  font-weight: 400;
  font-size: 14px;
}

.no-search-term {
  background-color: #fff; 
  padding: 20px;            
  color: #03008D;           
  width: 100%;              
  margin-top: 50px;         
  text-align: center;       
  box-sizing: border-box;   
  border-radius: 30px;
}

@media (min-width: 768px) and (max-width: 1023px) {
  .card {
	width: calc(50% - 20px);
  }
}

/* Responsive adjustments for mobile */
@media (max-width: 767px) {
  .cards-container {
    flex-direction: column;
  }
  .card {
    width: 100%;
  }
  .cpt-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .view-more-btn {
    margin-top: 10px;
  }
}
