/* Smart Recommend: responsive grid */
.rec-box {
  margin: 20px 0;
}

.rec-title {
  margin: 0 0 12px;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.2;
}

.rec-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.rec-item {
  border: 1px solid #eee;
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
  height: 100%;
}

.rec-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(0,0,0,.08);
  border-color: #e3e3e3;
}

.rec-link {
  display: block;
  color: inherit;
  text-decoration: none;
  height: 100%;
}

.rec-img {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #fafafa;
  overflow: hidden;
}

.rec-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.rec-body {
  padding: 10px 12px 12px;
  display: grid;
  gap: 6px;
}

.rec-name {
  font-size: 14px;
  line-height: 1.3;
  font-weight: 500;

  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  min-height: calc(1.3em * 2);
}

.rec-price {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: baseline;
}

.rec-price .price-old {
  font-weight: 500;
  text-decoration: line-through;
  opacity: .65;
}

.rec-price .price-new {
  font-weight: 800;
}

/* Tablet */
@media (max-width: 992px) {
  .rec-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Small tablet / large phone */
@media (max-width: 768px) {
  .rec-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rec-title { font-size: 16px; }
}

/* Mobile */
@media (max-width: 420px) {
  .rec-grid { grid-template-columns: 1fr; }
}
