* { box-sizing: border-box; }
body { margin: 0; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans KR", sans-serif; color: #222; background: #f7f7f8; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 18px; }
.site-header { background: #fff; border-bottom: 1px solid #e5e5e5; position: sticky; top: 0; z-index: 10; }
.header-inner { height: 72px; display: flex; align-items: center; gap: 28px; }
.logo { font-size: 24px; font-weight: 800; }
.top-search { flex: 1; display: flex; gap: 8px; }
.top-search input, .filter-box input, .filter-box select { width: 100%; height: 42px; border: 1px solid #ddd; border-radius: 8px; padding: 0 12px; background: #fff; }
button, .btn-reset { height: 42px; border: 0; border-radius: 8px; padding: 0 18px; background: #111; color: #fff; cursor: pointer; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
button.secondary { background: #555; }
button:disabled { background: #aaa; cursor: not-allowed; }
.btn-reset { background: #777; white-space: nowrap; }
.page-title { padding: 34px 0 18px; }
.page-title h1 { margin: 0 0 8px; font-size: 30px; }
.page-title p { margin: 0; color: #666; }
.filter-box { background: #fff; border: 1px solid #e5e5e5; border-radius: 14px; padding: 16px; display: grid; grid-template-columns: 2fr 1fr 1fr 160px auto auto; gap: 8px; margin-bottom: 22px; }
.goods-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.goods-card { background: #fff; border: 1px solid #e5e5e5; border-radius: 16px; overflow: hidden; transition: transform .15s ease, box-shadow .15s ease; }
.goods-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,.08); }
.goods-thumb { position: relative; aspect-ratio: 1 / 1; background: #eee; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.goods-thumb img { width: 100%; height: 100%; object-fit: cover; }
.badge { position: absolute; left: 10px; top: 10px; border-radius: 999px; padding: 6px 10px; font-size: 13px; font-weight: 800; }
.soldout { background: rgba(0,0,0,.75); color: #fff; }
.goods-info { padding: 14px; }
.brand { color: #777; font-size: 13px; margin-bottom: 6px; }
.brand.big { font-size: 15px; font-weight: 700; }
.goods-name { display: block; font-weight: 700; line-height: 1.35; min-height: 44px; }
.summary { color: #777; font-size: 13px; line-height: 1.45; min-height: 38px; }
.price-row { margin-top: 12px; display: flex; align-items: baseline; gap: 8px; }
.normal-price { color: #999; text-decoration: line-through; font-size: 14px; }
.price { font-size: 20px; }
.meta { margin-top: 12px; display: flex; justify-content: space-between; color: #777; font-size: 13px; }
.pagination { display: flex; justify-content: center; gap: 6px; padding: 32px 0; }
.pagination a { min-width: 38px; height: 38px; border: 1px solid #ddd; background: #fff; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; }
.pagination a.active { background: #111; color: #fff; border-color: #111; }
.empty { margin: 40px 0; padding: 40px; background: #fff; border: 1px solid #e5e5e5; border-radius: 14px; text-align: center; color: #777; }
.breadcrumb { padding: 24px 0 12px; color: #777; display: flex; gap: 8px; }
.detail-top { display: grid; grid-template-columns: 1fr 1fr; gap: 36px; background: #fff; border: 1px solid #e5e5e5; border-radius: 18px; padding: 24px; }
.main-image { position: relative; background: #f0f0f0; border-radius: 14px; overflow: hidden; aspect-ratio: 1 / 1; display: flex; align-items: center; justify-content: center; }
.main-image img { width: 100%; height: 100%; object-fit: cover; }
.thumb-list { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin-top: 10px; }
.thumb-list img { aspect-ratio: 1 / 1; object-fit: cover; border: 1px solid #ddd; border-radius: 8px; background: #f2f2f2; }
.detail-info h1 { margin: 8px 0 12px; font-size: 30px; line-height: 1.3; }
.detail-summary { color: #666; line-height: 1.6; }
.detail-price { margin: 24px 0; }
.detail-price strong { font-size: 34px; }
.info-table { width: 100%; border-collapse: collapse; margin: 20px 0; }
.info-table th, .info-table td { border-top: 1px solid #eee; padding: 12px 8px; text-align: left; vertical-align: top; }
.info-table th { width: 130px; color: #777; font-weight: 600; }
.buy-box { display: flex; gap: 10px; margin-top: 24px; }
.buy-box button { flex: 1; height: 52px; font-size: 16px; }
.detail-section { margin-top: 24px; background: #fff; border: 1px solid #e5e5e5; border-radius: 18px; padding: 24px; }
.detail-section h2 { margin: 0 0 18px; }
.detail-content, .text-box { line-height: 1.75; overflow-wrap: anywhere; }
.site-footer { margin-top: 40px; background: #222; color: #bbb; padding: 28px 0; }
@media (max-width: 900px) {
    .goods-grid { grid-template-columns: repeat(2, 1fr); }
    .filter-box { grid-template-columns: 1fr 1fr; }
    .detail-top { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
    .header-inner { height: auto; padding-top: 14px; padding-bottom: 14px; flex-direction: column; align-items: stretch; }
    .goods-grid { grid-template-columns: 1fr; }
    .filter-box { grid-template-columns: 1fr; }
}
