/* Custom Title Fix - Force Multi-line Wrapping */
/* Added Yellow Background for Debugging/Confirmation */

.product-thumb .caption h4, 
.product-thumb .caption .product-name,
.product-thumb .caption h4 a,
.product-thumb .caption .product-name a,
.product-grid .product-thumb .caption h4,
.product-list .product-thumb .caption h4 {
  height: auto !important;
  max-height: none !important;
  min-height: 40px; /* Maintain alignment */
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
  display: block !important;
  
  /* Reset Webkit Line Clamp */
  -webkit-line-clamp: none !important;
  -webkit-box-orient: horizontal !important;
  
  /* Font styling */
  line-height: 1.4 !important;
  margin-bottom: 10px;
  
  /* Ensure visibility */
  visibility: visible !important;
  opacity: 1 !important;
  
  /* Wrapping */
  word-wrap: break-word !important;
  overflow-wrap: break-word !important;
}

/* Ensure container allows expansion */
.product-thumb .caption {
    height: auto !important;
    min-height: auto !important;
    overflow: visible !important;
}

/* Specific overrides for known classes */
h4.product-name {
    height: auto !important;
    white-space: normal !important;
}

.product-layout .product-thumb .caption h4 a {
    white-space: normal !important;
    display: inline !important; /* Allow text to flow */
}
