/* ==========================================================================
   ssada-core.css — 싸다닷컴 단일 상품카드 표준 (UI_STANDARD v0.1)
   확정값: 썸네일 80×80 / radius 12 / object-fit cover / 카드 radius 16
   이 파일이 .product-card 계열의 유일한 정의처입니다.
   각 페이지의 인라인 .product-card~ 규칙은 제거하고 이 파일을 link 하세요.
   ※ 페이지 껍데기(.stats-bar / .mini-search / .product-grid 레이아웃)는
      이번 단계 범위 밖 — 기존 인라인 유지.
   ========================================================================== */

/* --- 카드 본체 --- */
.product-card {
  background: #fff;
  border-radius: 16px;            /* 14 → 16 (표준) */
  padding: 14px;
  display: flex;
  gap: 12px;
  align-items: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  border: 2px solid transparent;
  position: relative;
  transition: border-color 0.2s;
}
.product-card:hover { border-color: #FF4B2B; }
.product-card.best  { border-color: #FF4B2B; }

/* --- 최저가 배지 (결과셋당 1개) --- */
.best-badge {
  position: absolute;
  top: -1px;
  left: 14px;
  background: #FF4B2B;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 0 0 8px 8px;
}

/* --- 썸네일 (표준 80×80 / cover) --- */
.product-img,
.product-img-placeholder {
  width: 80px;                    /* 72 → 80 (표준) */
  height: 80px;
  border-radius: 12px;            /* 10 → 12 (표준) */
  background: #f5f5f5;            /* 로딩/실패 시 자리 유지 → CLS 방지 */
  flex-shrink: 0;
}
.product-img { object-fit: cover; }
.product-img-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
}

/* --- 정보 영역 --- */
.product-info { flex: 1; min-width: 0; }
.product-name {
  font-size: 13px;
  font-weight: 600;
  color: #111;
  margin-bottom: 3px;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.price-row { display: flex; align-items: baseline; gap: 6px; margin-bottom: 2px; }
.price { font-size: 18px; font-weight: 900; color: #FF4B2B; }
.price-detail { font-size: 10px; color: #aaa; margin-bottom: 4px; }
.price-detail span { color: #FF4B2B; font-weight: 700; }

/* --- 태그 --- */
.tags { display: flex; gap: 4px; flex-wrap: wrap; }
.mall-tag { font-size: 10px; padding: 2px 7px; border-radius: 5px; background: #f0f0f0; color: #666; font-weight: 600; }
.tag-free { font-size: 10px; padding: 2px 7px; border-radius: 5px; background: #e8f5e9; color: #2e7d32; font-weight: 600; }

/* --- 구매 버튼 (아웃바운드: rel은 마크업에서 nofollow sponsored noopener) --- */
.buy-btn {
  padding: 10px 14px;
  background: #FF4B2B;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  display: inline-block;
  flex-shrink: 0;
}
.buy-btn:hover { background: #CC2200; }

/* --- 모바일 (≤480px): 세로형, 이미지 상단 정사각(고정 height 금지 → CLS 방지) --- */
@media (max-width: 480px) {
  .product-card { flex-direction: column; align-items: stretch; padding: 10px; gap: 6px; }
  .product-card.best { padding-top: 20px; }
  .product-img,
  .product-img-placeholder {
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;          /* 기존 height:100px 하드코딩 대체 */
  }
  .price { font-size: 15px; }
  .buy-btn { width: 100%; text-align: center; padding: 7px; font-size: 11px; margin-top: 4px; }
}
