.suggestions-container {
  padding: 0;
  max-width: 1200px;
  margin: 0 auto;
}

.suggestions-container.mt-5 { margin-top: 16px !important; }

.suggestions-header {
  text-align: left;
  margin-bottom: 12px;
}

.suggestions-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--ht-navy, #15110D);
  margin: 0;
}

.suggestions-subtitle {
  color: var(--ht-muted, #6c757d);
  font-size: 0.95rem;
  margin-bottom: 0;
}

.suggestions-grid {
  display: grid;
  /* min() gör att spårets minsta bredd aldrig överstiger containern — annars
     spränger rutnätet sin förälder på smala skärmar. width/min-width behövs
     eftersom rutnätet på flera sidor ligger som flex-barn i en .row. */
  grid-template-columns: repeat(auto-fill, minmax(min(220px, 100%), 1fr));
  gap: 16px;
  margin-top: 1rem;
  width: 100%;
  min-width: 0;
}

/* Rutnätsceller får inte växa efter sitt innehålls min-content-bredd. Utan
   detta blåser en lång obruten rubrik (t.ex. "12au7/E88CC/E80CC") upp
   kolumnen så att grannkolumnen klipps bort på mobil. */
.suggestions-grid > * {
  min-width: 0;
}

.suggestion-card {
  background: #fff;
  border: 1px solid var(--ht-border, #e5e7eb);
  border-radius: var(--ht-radius, 8px);
  box-shadow: none;
  overflow: hidden;
  transition: background-color .12s ease;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  height: 100%;
  display: flex;
  flex-direction: column;
  position: relative;
  min-width: 0;
}
.suggestion-card:hover {
  background: var(--ht-bg-subtle, #f8f9fa);
  text-decoration: none;
  color: inherit;
}

/* Removed previous .suggestion-card:hover lifting & shadow effect */

/* Image container & image */
.suggestion-image-container {
  width: 100%;
  height: 180px;
  background: linear-gradient(135deg, #e9ecef, #f8f9fa);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}

.suggestion-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: none;
}

/* Removed previous .suggestion-card:hover .suggestion-image scale */

/* OPTIONAL: Re‑enable original hover effects only when parent grid has modifier class */
.suggestions-grid--interactive .suggestion-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.suggestions-grid--interactive .suggestion-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
  text-decoration: none;
  color: inherit;
}
.suggestions-grid--interactive .suggestion-image {
  transition: transform 0.2s ease;
}
.suggestions-grid--interactive .suggestion-card:hover .suggestion-image {
  transform: scale(1.02);
}

.suggestion-content {
  padding: 12px 14px 14px;
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.suggestion-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--ht-navy, #15110D);
  margin: 0 0 4px;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  /* Modell-/artikelbeteckningar saknar ofta brytpunkter — bryt hellre mitt i
     ordet än att låta rubriken bestämma kortets bredd. */
  overflow-wrap: anywhere;
}

.suggestion-price {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--ht-fg, #111);
  margin-bottom: 4px;
}

.suggestion-location {
  font-size: 0.875rem;
  color: var(--ht-muted, #6c757d);
  display: flex;
  align-items: center;
  gap: 0.25rem;
  margin-bottom: 0.5rem;
}

.suggestion-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  padding-top: 6px;
  border-top: 0;
  font-size: 0.75rem;
  color: var(--ht-muted, #6c757d);
}

.suggestion-date {
  font-size: 0.75rem;
  color: var(--ht-muted, #6c757d);
}

.suggestion-category {
  font-size: 0.75rem;
  background: var(--ht-bg-subtle, #f8f9fa);
  color: var(--ht-muted, #6c757d);
  padding: 2px 8px;
  border-radius: 4px;
  white-space: nowrap;
  border: 1px solid var(--ht-border, #e5e7eb);
}

.suggestion-type {
  font-size: 0.8125rem;
  font-weight: 600;
  color: #2e8b57;
  margin-bottom: 4px;
  text-transform: none;
}

/* Heart aligned with price in a dedicated row */
.suggestion-price-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 0.25rem;
  margin-bottom: 0.5rem;
}

/* Heart shown inline (not overlay) when used in the price row */
.suggestion-card .favourite-heart {
  position: static;
}

/* Responsive breakpoints */
@media (max-width: 768px) {
  .suggestions-grid {
    grid-template-columns: repeat(auto-fill, minmax(min(180px, 100%), 1fr));
    gap: 12px;
  }

  .suggestions-container {
    padding: 1rem 0;
  }

  .suggestions-title {
    font-size: 1.25rem;
  }

  .suggestions-subtitle {
    font-size: 0.95rem;
  }
}

@media (max-width: 480px) {
  .suggestions-grid {
    /* minmax(0, 1fr) — inte 1fr — så att kolumnerna delar bredden lika även
       när innehållet har en större min-content-bredd än sin andel. */
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .suggestion-image-container {
    height: 140px;
  }

  .suggestion-content {
    padding: 10px 10px 12px;
  }

  .suggestion-title {
    font-size: 0.9375rem;
  }

  .suggestion-price {
    font-size: 1rem;
  }
}

/* Riktigt smala telefoner (t.ex. iPhone SE i äldre generationer) får en
   kolumn — två kort à ~130 px blir oläsligt trångt. */
@media (max-width: 359px) {
  .suggestions-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .suggestion-image-container {
    height: 180px;
  }
}

/* Loading state for future use */
.suggestion-card.loading {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Ensure consistent card heights */
.suggestions-grid .suggestion-card {
  min-height: 300px;
}

/* Highlighted ad styling — matches .ht-ad--featured on index */
.suggestion-card-highlighted {
  background: linear-gradient(135deg, #d6e7ff, #cce1ff);
  border-left: 3px solid var(--ht-accent, #4A90D9);
}
.suggestion-card-highlighted:hover {
  background: linear-gradient(135deg, #c7defa, #b9d5f2);
}

/* Focus styles for accessibility */
.suggestion-card:focus {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
}
