{% from '../../css/_variables.css' import 
  primary, 
  accent,
  accent_bg, 
  text_dark, 
  text_light, 
  border_light,
  borders_color,
  light,
  white,
  dark,
  sm, 
  md, 
  lg,
  gutter,
  radius_4,
  radius_7
%}

/* ========================================
   Customer Success Listing Module
   Matches Resource Listing Module Styles
   ======================================== */

.resource-listing {
  max-width: 1330px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Searchable Dropdown - Native Type-to-Filter */
.drop-down--searchable .drop-down__list {
  max-height: 350px;
  overflow-y: auto;
}

.drop-down--searchable .drop-down__no-results {
  padding: 16px;
  text-align: center;
  color: #666;
  font-size: 0.875rem;
}

/* Show caret when dropdown is open and text is cleared for type-to-filter */
.drop-down--searchable .drop-down__btn-text:empty::after {
  content: '|';
  color: #666;
  display: inline-block;
  animation: customer-success-caret-blink 1s steps(1, end) infinite;
}

@keyframes customer-success-caret-blink {
  50% {
    opacity: 0;
  }
}

.listing__toolbar {
  max-width: 1330px;
  margin: 0 auto 40px auto;
  padding: 0;
}

.listing__toolbar-elements {
  width: 100%;
}

.resources__filters {
  align-items: center;
  display: flex;
  flex-wrap: nowrap;
  gap: 32px;
  width: 100%;
  justify-content: space-between;
}

.resources__filters .listing__filter-drop-down {
  flex: 1;
  width: auto !important;
}

.resources__filters .drop-down__btn {
  width: 100%;
  background-color: #ffffff !important;
  border: 1px solid  !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  transition: all 0.2s ease;
}

.resources__filters .drop-down__btn:hover {
  border-color:  !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.resource-listing__grid {
  margin-top: 40px;
}

/* Load More */
.resource-listing__load-more {
  display: none;
  justify-content: center;
  margin-top: 24px;
}

.customer-success-card-item {
  margin-bottom: 16px;
}

/* Larger pill tags */
.customer-success-service-badge,
.customer-success-tech-badge {
  font-size: 0.75rem;
  padding: 0;
  border-radius: 0;
  line-height: 1.4;
  display: inline-block;
  background-color: transparent !important;
  font-weight: 600;
}

/* Tag colors */
.customer-success-service-badge {
  color: #1a4fa3 !important; /* blue */
}

.customer-success-tech-badge {
  color: #28a745 !important; /* green */
}

/* Align tags on a clean row with wrap */
.content-card__header .customer-success-service-badge,
.content-card__header .customer-success-tech-badge {
  margin-right: 8px;
  margin-bottom: 6px;
  vertical-align: middle;
}

/* Consistent card image sizing */
.resource-listing .content-card__img {
  max-height: 180px;
  min-height: 180px;
  overflow: hidden;
}

.resource-listing .content-card__img img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

/* Reduce extra bottom padding on cards */
.resource-listing .content-card {
  padding-bottom: 0;
}

/* Clamp excerpt to 2 lines with ellipsis */
.resource-listing .content-card__desc {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

/* Tighten heading spacing and size */
.resource-listing .content-card__title-tag {
  font-size: 1.125rem;
  line-height: 1.2;
  margin-bottom: 0.25rem;
}

/* Reduce extra space below body text */
.resource-listing .content-card__body {
  padding-bottom: 12px;
}

/* No Results Styling - Matches Resource Listing */
.resource-listing__no-results {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 400px;
  padding: 60px 20px;
}

.resource-listing__no-results-content {
  text-align: center;
  max-width: 500px;
}

.resource-listing__no-results-content h3 {
  margin: 0 0 12px 0;
  color: #333;
  font-size: 1.5rem;
}

.resource-listing__no-results-content p {
  margin: 0 0 24px 0;
  color: #666;
}

/* Responsive */
@media (max-width: 768px) {
  .resources__filters {
    flex-direction: column;
    gap: 16px;
  }
  
  .resources__filters .listing__filter-drop-down {
    width: 100% !important;
  }
  
  .resource-listing__grid {
    margin-top: 24px;
  }
  
  .customer-success-card-item {
    margin-bottom: 20px;
  }
}
