:root {
    --blue: #185fa5;
    --blue-dark: #0c447c;
    --blue-bg: #e6f1fb;
    --green: #0f6e56;
    --green-bg: #e1f5ee;
    --red: #cc2b2b;
    --text: #222;
    --text-sub: #666;
    --text-muted: #999;
    --border: #e5e5e5;
    --bg: #fff;
    --bg-soft: #f7f8fa;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 화면에는 안 보이고 검색엔진/스크린리더만 읽는 텍스트 */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

body {
    font-family: "Pretendard", -apple-system, BlinkMacSystemFont, "Malgun Gothic", sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.5;
}

.container {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 16px;
}

/* 헤더 */
.site-header {
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    background: var(--bg);
    z-index: 10;
}

.header-inner {
    display: flex;
    align-items: center;
    height: 56px;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo img {
    height: 36px;
    display: block;
    mix-blend-mode: multiply;
}

/* 파트너스 고지 문구 (쿠팡 가이드: 본문보다 크게 + 눈에 띄는 색) */
.disclosure-top {
    font-size: 18px;
    font-weight: 900;
    line-height: 1.5;
    color: #1467c4;
    background: #eef5fd;
    border: 1px solid #c9dff7;
    border-radius: 8px;
    padding: 14px 16px;
    margin-top: 14px;
}

/* 카테고리 칩 */
.chips {
    display: flex;
    gap: 8px;
    padding-top: 12px;
    padding-bottom: 4px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.chips::-webkit-scrollbar {
    display: none;
}

.chip {
    flex: 0 0 auto;
    font-size: 13px;
    padding: 7px 14px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--bg);
    color: var(--text-sub);
    cursor: pointer;
    font-family: inherit;
}

.chip.active {
    background: var(--blue);
    border-color: var(--blue);
    color: #fff;
    font-weight: 600;
}

/* 상품 그리드 */
.grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    padding: 16px 0 40px;
}

@media (min-width: 600px) {
    .grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 16px;
    }
}

@media (min-width: 900px) {
    .grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

/* 상품 카드 */
.card {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    background: var(--bg);
    text-decoration: none;
    color: inherit;
    transition: box-shadow 0.15s, transform 0.15s;
}

.card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.thumb {
    aspect-ratio: 1;
    background: var(--bg-soft);
    overflow: hidden;
}

.thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.card-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 12px;
}

.badges {
    display: flex;
    gap: 4px;
    margin-bottom: 6px;
    min-height: 20px;
}

.badge {
    font-size: 11px;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 4px;
}

.badge-rocket {
    background: var(--blue-bg);
    color: var(--blue-dark);
}

.badge-fresh {
    background: var(--green-bg);
    color: var(--green);
}

.badge-tomorrow {
    border: 1px solid var(--green);
    color: var(--green);
    background: #fff;
}

.name {
    font-size: 14px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 6px;
}

.price-row {
    font-size: 13px;
    margin-bottom: 2px;
}

.discount {
    color: var(--red);
    font-weight: 700;
    margin-right: 4px;
}

.orig-price {
    color: var(--text-muted);
    text-decoration: line-through;
}

.price {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 4px;
}

.price .won {
    font-size: 14px;
    font-weight: 500;
}

.meta {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.meta .star {
    color: #f5a623;
}

.cta {
    margin-top: auto;
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    padding: 10px 0;
    border-radius: 8px;
    background: var(--blue);
    color: #fff;
}

.card:hover .cta {
    background: var(--blue-dark);
}

.empty {
    text-align: center;
    color: var(--text-muted);
    padding: 60px 0;
}

/* 푸터 */
.site-footer {
    border-top: 1px solid var(--border);
    background: var(--bg-soft);
    padding: 20px 0;
    font-size: 13px;
    color: var(--text-sub);
}

.site-footer p:first-child {
    font-weight: 600;
    color: var(--text);
}

.site-footer p + p {
    margin-top: 4px;
}
