@charset "utf-8";
/* ==========================================================================
   중고폰 리스트(List.php) 리뉴얼 스타일
   업로드 위치 : /shop/assets/css/pages/phone-renew.css
   대상 마크업 : List.php 가 출력하는 .pr-* 클래스 (사이트 공통 CSS 와 겹치지 않음)
   ========================================================================== */

.pr-page {
  --pr-bg: #eff3f8;
  --pr-surface: #fff;
  --pr-line: #e5eaf1;
  --pr-line-2: #d4dce7;

  --pr-ink: #0f172a;
  --pr-ink-2: #475569;
  --pr-ink-3: #94a3b8;

  --pr-blue: #1b5bff;
  --pr-blue-soft: #eef3ff;
  --pr-red: #f0455a;

  --pr-shadow: 0 1px 2px rgba(15, 23, 42, .04);
  --pr-shadow-hover: 0 10px 28px rgba(15, 23, 42, .10);

  --pr-max: 1200px;

  letter-spacing: -.02em;
  color: var(--pr-ink);
}

.pr-page, .pr-page *, .pr-page *::before, .pr-page *::after { box-sizing: border-box; }

.pr-page img { max-width: 100%; }

.pr-inner {
  max-width: var(--pr-max);
  margin: 0 auto;
}

/* 스크린리더 전용 */
.pr-page .blind {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ==========================================================================
   1. 히어로 + 필터
   ========================================================================== */
.pr-hero {
  background: var(--pr-surface);
  border-bottom: 1px solid var(--pr-line);
  padding: 44px 20px 28px;
}

.pr-title {
  margin: 0;
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -.03em;
  line-height: 1.3;
}

.pr-desc {
  margin: 8px 0 0;
  font-size: 15px;
  color: var(--pr-ink-2);
}

.pr-filters {
  margin-top: 26px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pr-filter {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 16px;
  background: #f6f8fb;
  border: 1px solid var(--pr-line);
  border-radius: 12px;
}

.pr-filter__label {
  flex: 0 0 auto;
  min-width: 44px;
  font-size: 13px;
  font-weight: 700;
  color: var(--pr-ink-2);
}

.pr-filter__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
}

/* 칩 : 등급은 <a>, 제조사·가격대는 <button> — 동일하게 보이도록 */
.pr-chip {
  display: inline-flex;
  align-items: center;
  appearance: none;
  font-family: inherit;
  border: 1px solid transparent;
  background: transparent;
  border-radius: 999px;
  padding: 7px 16px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -.02em;
  color: var(--pr-ink-2);
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background .15s, color .15s, border-color .15s;
}

.pr-chip:hover { background: #eaeff6; color: var(--pr-ink); }

.pr-chip.is-on,
.pr-chip[aria-pressed="true"] {
  background: var(--pr-surface);
  border-color: var(--pr-blue);
  color: var(--pr-blue);
  box-shadow: var(--pr-shadow);
}

.pr-chip:focus-visible { outline: 2px solid var(--pr-blue); outline-offset: 2px; }

/* ==========================================================================
   2. 본문 + 툴바
   ========================================================================== */
.pr-body {
  background: var(--pr-bg);
  padding: 26px 20px 90px;
}

.pr-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 16px;
}

.pr-count { margin: 0; font-size: 14px; color: var(--pr-ink-2); }
.pr-count b { font-weight: 700; color: var(--pr-ink); }

.pr-toolbar__right { display: flex; align-items: center; gap: 10px; }

.pr-sort {
  appearance: none;
  font-family: inherit;
  border: 0;
  background: transparent;
  font-size: 14px;
  font-weight: 600;
  color: var(--pr-ink);
  padding: 6px 22px 6px 8px;
  cursor: pointer;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'><path d='M2.5 4.5 6 8l3.5-3.5' fill='none' stroke='%230f172a' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/></svg>");
  background-repeat: no-repeat;
  background-position: right 4px center;
}

.pr-view { display: flex; gap: 2px; padding: 2px; background: #e3e9f2; border-radius: 8px; }

.pr-view__btn {
  appearance: none;
  border: 0;
  background: transparent;
  width: 30px; height: 26px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  color: var(--pr-ink-3);
  cursor: pointer;
  transition: background .15s, color .15s;
}

.pr-view__btn[aria-pressed="true"] {
  background: var(--pr-surface);
  color: var(--pr-ink);
  box-shadow: var(--pr-shadow);
}

.pr-view__btn svg { width: 15px; height: 15px; display: block; }

/* ==========================================================================
   3. 카드 그리드
   ========================================================================== */
.pr-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.pr-card { display: flex; margin: 0; padding: 0; list-style: none; }
.pr-card[hidden] { display: none; }

.pr-card__in {
  position: relative;
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-width: 0;
  padding: 16px 16px 18px;
  background: var(--pr-surface);
  border: 1px solid var(--pr-line);
  border-radius: 16px;
  box-shadow: var(--pr-shadow);
  overflow: hidden;
  color: inherit;
  text-decoration: none;
  transition: box-shadow .2s, transform .2s, border-color .2s;
}

a.pr-card__in:hover {
  border-color: var(--pr-line-2);
  box-shadow: var(--pr-shadow-hover);
  transform: translateY(-2px);
}

a.pr-card__in:focus-visible { outline: 2px solid var(--pr-blue); outline-offset: 2px; }

/* 3-1. 뱃지 */
.pr-badge {
  position: absolute;
  top: 0; left: 0;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 10px;
  border-radius: 0 0 10px 0;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  color: #fff;
  background: var(--pr-ink-3);
}

.pr-badge.popular { background: #ff5a1f; }              /* 인기 */
.pr-badge.point   { background: #f0455a; }              /* 한정수량 */
.pr-badge.recom   { background: #ede9fe; color: #7c3aed; } /* 추천 */

/* 3-2. 썸네일 */
.pr-thumb { display: block; }

.pr-thumb img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border-radius: 12px;
  transition: transform .3s;
}

a.pr-card__in:hover .pr-thumb img { transform: scale(1.04); }

/* 3-3. 색상 도트 (color_hex 그대로 인라인 적용) */
.pr-colors {
  display: flex;
  align-items: center;
  gap: 5px;
  min-height: 13px;
  margin: 10px 0 12px;
}

.pr-color {
  display: block;
  flex: 0 0 auto;
  width: 11px; height: 11px;
  border: 1px solid rgba(15, 23, 42, .14);
  border-radius: 50%;
}

.pr-color-more {
  font-size: 11px;
  font-weight: 600;
  font-style: normal;
  color: var(--pr-ink-3);
}

/* 색상이 없는 상품도 높이를 맞춤 */
.pr-card__in > .pr-thumb + .pr-name { margin-top: 22px; }

/* 3-4. 상품명 */
.pr-name {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -.03em;
  line-height: 1.35;
  color: var(--pr-ink);
}

/* 3-5. 용량 칩 */
.pr-specs { display: flex; flex-wrap: wrap; gap: 4px; margin: 0 0 12px; }

.pr-spec {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 8px;
  border-radius: 6px;
  background: #f1f5f9;
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
}

/* 3-6. 출고가 / 판매가 */
.pr-origin {
  display: block;
  margin: 0 0 2px;
  font-size: 12px;
  color: var(--pr-ink-3);
}

.pr-origin s { text-decoration: line-through; }

.pr-price {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin: 0 0 14px;
  font-size: 13px;
  color: var(--pr-ink-2);
}

.pr-rate {
  font-size: 19px;
  font-weight: 800;
  font-style: normal;
  letter-spacing: -.03em;
  color: var(--pr-red);
}

.pr-price b {
  font-size: 23px;
  font-weight: 800;
  letter-spacing: -.04em;
  color: var(--pr-blue);
}

.pr-price i { font-style: normal; font-size: 13px; }

/* 3-7. 월 납부금액 (has-monthly 카드만) */
.pr-card.has-monthly .pr-price {
  margin-bottom: 10px;
  font-size: 12px;
  color: var(--pr-ink-3);
}

.pr-card.has-monthly .pr-price b {
  font-size: 15px;
  font-weight: 700;
  color: var(--pr-ink-2);
  text-decoration: line-through;
}

.pr-card.has-monthly .pr-price i { font-size: 12px; color: var(--pr-ink-3); }

.pr-card.has-monthly .pr-rate { font-size: 15px; }

.pr-monthly {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 0 0 10px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #f4f7fb;
}

.pr-monthly__row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: baseline;
  column-gap: 6px;
}

.pr-monthly__row em {
  font-style: normal;
  font-size: 12px;
  font-weight: 700;
  color: var(--pr-ink-2);
  white-space: nowrap;
}

.pr-monthly__row i {
  font-style: normal;
  font-size: 10px;
  line-height: 1.3;
  color: var(--pr-ink-3);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pr-monthly__row b {
  font-size: 13px;
  font-weight: 700;
  color: var(--pr-ink);
  white-space: nowrap;
}

.pr-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px;
  margin: 0 0 14px;
}

.pr-total em {
  font-style: normal;
  font-size: 12px;
  font-weight: 700;
  color: var(--pr-ink-2);
  white-space: nowrap;
}

.pr-total b {
  margin-left: auto;
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -.04em;
  color: var(--pr-blue);
}

.pr-total i { font-style: normal; font-size: 13px; color: var(--pr-blue); }

/* 3-7. 구매 버튼 */
.pr-buy {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-top: auto;
  width: 100%;
  height: 44px;
  border-radius: 10px;
  background: var(--pr-blue-soft);
  color: var(--pr-blue);
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  transition: background .15s, color .15s;
}

.pr-buy::after {
  content: "";
  width: 6px; height: 6px;
  margin-left: 2px;
  border-right: 1.6px solid currentColor;
  border-top: 1.6px solid currentColor;
  transform: rotate(45deg);
}

a.pr-card__in:hover .pr-buy { background: var(--pr-blue); color: #fff; }

.pr-buy.is-off { background: #f1f5f9; color: #94a3b8; }
.pr-buy.is-off::after { display: none; }

.pr-card.is-soldout .pr-thumb img { filter: grayscale(1); opacity: .55; }

/* ==========================================================================
   4. 리스트(가로) 보기
   ========================================================================== */
.pr-list.is-row { grid-template-columns: 1fr; gap: 10px; }

.pr-list.is-row .pr-card__in {
  display: grid;
  grid-template-columns: 96px 1fr auto;
  grid-template-rows: auto auto;
  column-gap: 18px;
  row-gap: 4px;
  align-items: center;
  padding: 14px 18px;
}

.pr-list.is-row .pr-thumb { grid-row: 1 / 3; }
.pr-list.is-row .pr-colors { display: none; }
.pr-list.is-row .pr-name { grid-column: 2; margin: 0; }
.pr-list.is-row .pr-specs { grid-column: 2; margin: 0; }
.pr-list.is-row .pr-origin { grid-column: 3; grid-row: 1; justify-self: end; margin: 0; }
.pr-list.is-row .pr-price { grid-column: 3; grid-row: 2; justify-self: end; margin: 0; }
.pr-list.is-row .pr-buy { display: none; }
.pr-list.is-row .pr-monthly { display: none; }
.pr-list.is-row .pr-total { grid-column: 3; grid-row: 2; justify-self: end; margin: 0; }
.pr-list.is-row .pr-card.has-monthly .pr-price { grid-column: 3; grid-row: 1; justify-self: end; }
.pr-list.is-row .pr-card__in > .pr-thumb + .pr-name { margin-top: 0; }

/* ==========================================================================
   5. 빈 상태
   ========================================================================== */
.pr-empty { display: none; padding: 90px 20px; text-align: center; }
.pr-empty.is-on { display: block; }

.pr-empty__icon {
  display: block;
  width: 34px; height: 46px;
  margin: 0 auto 20px;
  border: 2px solid var(--pr-ink-3);
  border-radius: 7px;
  opacity: .45;
}

.pr-empty__title { margin: 0 0 6px; font-size: 16px; font-weight: 700; }
.pr-empty__desc  { margin: 0 0 22px; font-size: 14px; color: var(--pr-ink-2); }

.pr-reset {
  appearance: none;
  font-family: inherit;
  border: 0;
  border-radius: 10px;
  padding: 12px 24px;
  background: var(--pr-blue);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

.pr-reset:hover { background: #1247d6; }

/* ==========================================================================
   6. 반응형
   ========================================================================== */
@media (max-width: 1024px) {
  .pr-list { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
  .pr-hero { padding: 32px 16px 22px; }
  .pr-title { font-size: 24px; }
}

@media (max-width: 768px) {
  .pr-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .pr-body { padding: 18px 16px 60px; }
  .pr-card__in { padding: 12px 12px 14px; }
  .pr-name { font-size: 14px; }
  .pr-price b { font-size: 19px; }
  .pr-rate { font-size: 16px; }
  .pr-buy { height: 40px; font-size: 13px; }

  .pr-filter { flex-direction: column; align-items: flex-start; gap: 8px; padding: 12px 14px; }
  .pr-filter__chips { width: 100%; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .pr-filter__chips::-webkit-scrollbar { display: none; }
  .pr-chip { padding: 6px 13px; font-size: 13px; }
  .pr-view { display: none; }

  .pr-list.is-row .pr-card__in { grid-template-columns: 72px 1fr; grid-template-rows: auto auto auto; }
  .pr-list.is-row .pr-thumb { grid-row: 1 / 4; }
  .pr-list.is-row .pr-origin,
  .pr-list.is-row .pr-price { grid-column: 2; grid-row: auto; justify-self: start; }
}

@media (max-width: 400px) {
  .pr-title { font-size: 21px; }
  .pr-desc { font-size: 13px; }
}

@media (prefers-reduced-motion: reduce) {
  .pr-card__in, .pr-thumb img { transition: none !important; }
  a.pr-card__in:hover { transform: none; }
  a.pr-card__in:hover .pr-thumb img { transform: none; }
}
