/* ==========================================================================
   PAGE: MALL LIST (상품 리스트 페이지)
   ========================================================================== */

/* --- 1. 서브 배너 영역 --- */
.main_banner_B {
    width: 100%;
    max-width: var(--w-container); /* 헤더와 동일한 최대 너비 */
    margin: 20px auto 40px; /* 상하 여백 */
    border-radius: 12px;
    overflow: hidden; /* 모서리 둥글게 */
  }
  .main_banner_B img {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
  }
  
  /* --- 2. 페이지 타이틀 영역 --- */
  .main_title {
    max-width: var(--w-container);
    margin: 0 auto 30px;
    padding: 0 20px;
    text-align: center; /* 중앙 정렬 (요즘 트렌드) */
  }
  .main_title_txt01 {
    font-size: 28px;
    font-weight: 700;
    color: var(--c-black);
    margin-bottom: 8px;
  }
  .main_title_txt02 {
    font-size: 15px;
    color: var(--c-gray);
    font-weight: 400;
  }
  
  /* --- 3. 상품 리스트 그리드 (Grid Layout) --- */
  .main_product_list .ttery_product {
    max-width: var(--w-container);
    margin: 0 auto;
    padding: 10px 20px;
  }
  
  .prdList.grid4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4열 고정 */
    gap: 40px 20px; /* 세로간격 40px, 가로간격 20px */
  }
  
  /* --- 4. 상품 카드 디자인 (Item) --- */
  .prdList__item {
    position: relative;
    display: flex;
    flex-direction: column;
    transition: transform 0.2s ease;
  }
  .prdList__item:hover {
    transform: translateY(-5px); /* 호버 시 살짝 위로 */
  }
  
  /* 4-1. 썸네일 */
  .prdList__item .thumbnail {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    background-color: #f4f4f4;
    aspect-ratio: 1 / 1; /* 정사각형 비율 유지 */
    margin-bottom: 12px;
  }
  .prdList__item .thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
  }
  /* 썸네일 호버 시 이미지 확대 효과 */
  .prdList__item:hover .thumbnail img {
    transform: scale(1.05);
  }
  
  /* 4-2. 뱃지 (Badges) */
  .badge-wrap {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    z-index: 2;
  }
  .nanum_box, .badge {
    font-size: 11px;
    padding: 3px 6px;
    border-radius: 2px;
    font-weight: 600;
    line-height: 1;
  }
  /* 품절 뱃지 스타일 */
  .badge--hit, .badge--partial {
    background: rgba(0,0,0,0.7);
    color: #fff;
  }
  
  /* 4-3. 상품 정보 (Description) */
  .description {
    display: flex;
    flex-direction: column;
    gap: 4px;
  }
  
  /* 업체명 (Vendor) */
  .vendor-header {
    font-size: 13px;
    color: #999;
    margin-bottom: 2px !important;
  }
  
  /* 상품명 */
  .description .name a span {
    font-size: 15px !important;
    color: var(--c-black) !important;
    font-weight: 400;
    line-height: 1.4;
    
    /* 2줄 말줄임 처리 */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 42px; /* 2줄 높이 확보 */
  }
  
  /* 가격 정보 (.spec) */
  .spec {
    margin-top: 8px;
    display: flex;
    flex-direction: column;
    gap: 2px;
  }
  .spec li { display: flex; align-items: center; flex-wrap: wrap; }
  
  /* 소비자가 (취소선) */
  .spec li span[style*="text-decoration:line-through"] {
    font-size: 14px !important;
    color: #bbb !important;
  }
  
  /* 판매가 & 할인율 */
  .spec li span[style*="font-weight:600"] { /* 할인율 */
    font-size: 18px !important;
    color: var(--c-point) !important; /* 브랜드 포인트 컬러 */
    font-weight: 700 !important;
    margin-right: 6px !important;
  }
  .spec li span[style*="color:#1a1a1a"] { /* 판매가 */
    font-size: 18px !important;
    color: var(--c-black) !important;
    font-weight: 700 !important;
  }
  
  /* 쿠폰가 */
  .spec li strong.title { display: none; } /* '쿠폰적용가' 텍스트 숨김 (깔끔하게) */
  .spec li span[style*="color:#d32f2f"] { /* 쿠폰 가격 */
    font-size: 14px !important;
    color: var(--c-primary) !important;
    font-weight: 600 !important;
    margin-top: 2px;
  }
  
  
  /* --- 6. 모바일 반응형 (Mobile) --- */
  @media (max-width: 768px) {
    /* 4열 -> 2열 변경 */
    .prdList.grid4 {
      grid-template-columns: repeat(2, 1fr);
      gap: 20px 12px; /* 간격 좁힘 */
    }
  
    .main_title_txt01 { font-size: 20px; }
    .main_title_txt02 { font-size: 13px; }
    
    .prdList__item .thumbnail { border-radius: 6px; }
    
    .description .name a span {
      font-size: 14px !important;
      min-height: 40px;
    }
    
    .spec li span[style*="font-weight:600"], /* 할인율 */
    .spec li span[style*="color:#1a1a1a"] { /* 판매가 */
      font-size: 16px !important;
    }
  }