/* ============================================
   상품 목록 페이지 CSS
============================================ */
.pl-wrap {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px 80px;
}

/* ── 카테고리 탭 네비 ── */
.pl-cat-nav {
    /* border-bottom: 2px solid #e5e7eb; */
    margin-bottom: 0;
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 50;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 5px;
    margin-top: 30px;
}
.pl-cat-inner {
    display: flex;
    align-items: flex-end;
    gap: 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.pl-cat-inner::-webkit-scrollbar { display: none; }

.pl-cat-group {
    position: relative;
    display: flex;
    flex-direction: column;
}
.pl-cat-item {
    display: block;
    padding: 14px 22px;
    font-size: 14px;
    font-weight: 500;
    color: #6b7280;
    white-space: nowrap;
    text-decoration: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: color .15s, border-color .15s;
}
.pl-cat-item:hover { color: #111; }
.pl-cat-item.active {
    color: #111;
    font-weight: 700;
    border-bottom-color: #111;
}
.pl-cat-sub {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 8px 0;
    min-width: 140px;
    box-shadow: 0 4px 12px rgba(0,0,0,.08);
    z-index: 100;
}
.pl-cat-group:hover .pl-cat-sub { display: block; }
.pl-cat-sub-item {
    display: block;
    padding: 8px 18px;
    font-size: 13px;
    color: #374151;
    white-space: nowrap;
    text-decoration: none;
    transition: background .1s;
}
.pl-cat-sub-item:hover { background: #f9fafb; color: #111; }
.pl-cat-sub-item.active { color: #111; font-weight: 700; }

/* ── 상단 바 ── */
.pl-topbar { padding: 20px 0 16px; }
.pl-topbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}
.pl-breadcrumb {
    font-size: 18px;
    font-weight: 700;
    color: #111;
    display: flex;
    align-items: baseline;
    gap: 6px;
}
.pl-total { font-size: 13px; font-weight: 400; color: #9ca3af; }

/* ── 필터 폼 ── */
.pl-filter-form {
    display: flex;
    align-items: center;
    gap: 8px;
}
.pl-select {
    padding: 8px 12px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 13px;
    color: #374151;
    background: #fff;
    cursor: pointer;
    outline: none;
}
.pl-search-box {
    display: flex;
    align-items: center;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
    transition: border-color .15s;
}
.pl-search-box:focus-within { border-color: #111; }
.pl-search-input {
    border: none;
    outline: none;
    padding: 8px 12px;
    font-size: 13px;
    width: 180px;
    background: transparent;
}
.pl-search-btn {
    background: none;
    border: none;
    padding: 8px 10px;
    cursor: pointer;
    color: #6b7280;
    display: flex;
    align-items: center;
    transition: color .15s;
}
.pl-search-btn:hover { color: #111; }
.pl-reset {
    font-size: 13px;
    color: #9ca3af;
    text-decoration: none;
    padding: 4px 6px;
    border-radius: 4px;
    transition: color .15s;
}
.pl-reset:hover { color: #111; }

/* ── 콘텐츠 ── */
.pl-content { padding-top: 8px; }

/* ── 빈 상태 ── */
.pl-empty {
    text-align: center;
    padding: 80px 20px;
    color: #9ca3af;
}
.pl-empty p { margin-top: 16px; font-size: 14px; }

/* ── 그리드 ── */
.pl-grid {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 28px 20px;
    padding: 0;
    margin: 0;
}
@media (max-width: 1024px) { .pl-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 720px)  { .pl-grid { grid-template-columns: repeat(2, 1fr); gap: 18px 12px; } }
@media (max-width: 480px)  { .pl-grid { grid-template-columns: repeat(2, 1fr); gap: 14px 10px; } }

/* ── 상품 아이템 ── */
.pl-item-link {
    display: block;
    text-decoration: none;
    color: inherit;
}
.pl-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    background: #f9fafb;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 14px;
}
.pl-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .3s ease;
}
.pl-item-link:hover .pl-thumb img { transform: scale(1.04); }
.pl-no-img {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f3f4f6;
}

/* 뱃지 */
.pl-badge-featured,
.pl-badge-inquiry {
    position: absolute;
    top: 10px;
    left: 10px;
    padding: 3px 9px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    line-height: 1.4;
}
.pl-badge-featured { background: #f59e0b; color: #fff; }
.pl-badge-inquiry  { background: #8b5cf6; color: #fff; left: auto; right: 10px; }

/* 상품 정보 */
.pl-item-info { padding: 0 2px; }
.pl-cat-label {
    font-size: 11px;
    color: #9ca3af;
    letter-spacing: .5px;
    text-transform: uppercase;
    display: block;
    margin-bottom: 4px;
}
.pl-name {
    font-size: 14px;
    font-weight: 600;
    color: #111;
    line-height: 1.4;
    margin: 0 0 5px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.pl-desc {
    font-size: 12px;
    color: #9ca3af;
    margin: 0 0 8px;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.pl-price { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.pl-price-normal { font-size: 15px; font-weight: 700; color: #111; }
.pl-price-origin { font-size: 12px; color: #9ca3af; text-decoration: line-through; }
.pl-price-sale   { font-size: 15px; font-weight: 700; color: #ef4444; }
.pl-price-inquiry{ font-size: 13px; font-weight: 600; color: #8b5cf6; }
.pl-discount     { font-size: 13px; font-weight: 700; color: #ef4444; }

/* ── 페이지네이션 ── */
.pl-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    margin-top: 48px;
    flex-wrap: wrap;
}
.pl-page-num,
.pl-page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    font-size: 14px;
    color: #374151;
    text-decoration: none;
    border: 1px solid #e5e7eb;
    transition: all .15s;
    background: #fff;
}
.pl-page-num:hover,
.pl-page-btn:hover  { background: #111; color: #fff; border-color: #111; }
.pl-page-num.on     { background: #111; color: #fff; border-color: #111; font-weight: 700; }
.pl-page-dot        { font-size: 14px; color: #9ca3af; padding: 0 4px; }

/* ── 반응형 ── */
@media (max-width: 768px) {
    .pl-topbar-inner { flex-direction: column; align-items: flex-start; }
    .pl-filter-form  { width: 100%; flex-wrap: wrap; }
    .pl-search-input { width: 140px; }
    .pl-cat-item     { padding: 12px 14px; font-size: 13px; }
    .pl-cat-inner {
    display: flex;
    align-items: flex-end;
    gap: 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
}

/* ── 용량/포장 라벨 (카드 - 상품명 아래) ── */
.pl-unit {
    margin: 4px 0 2px;
    font-size: 11px;
    font-weight: 600;
    color: #64748b;
    letter-spacing: 0.2px;
}
