/* ── 公式グッズ(goods.html) — apply.css(panel·field·summary·done) 위에 얹는다 ── */
.goods .rf-edition { color: var(--gold); font-weight: 700; margin-top: 6px; }
.goods .rf-lead { color: var(--muted); margin-top: 10px; line-height: 1.7; max-width: 720px; }
.gd-note { margin: -16px 0 28px; padding: 14px 18px; border-radius: 14px; border: 1px solid rgba(245,180,0,.28); background: rgba(245,180,0,.06); color: var(--text); font-size: 14px; line-height: 1.7; }
.gd-note p + p { margin-top: 4px; }
.gd-note a { color: var(--gold); text-decoration: underline; text-underline-offset: 3px; }
.gd-closed { text-align: center; }
.gd-closed p { color: var(--muted); margin-bottom: 20px; }

/* 상품 목록: 카드 격자 */
.gd-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; }
@media (max-width: 560px) { .gd-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; } }
.gd-card { display: flex; flex-direction: column; gap: 8px; padding: 12px; border-radius: 18px; border: 1px solid var(--line); background: rgba(255,255,255,.03); transition: border-color .25s, transform .25s, box-shadow .25s; }
.gd-card:hover { border-color: rgba(245,180,0,.5); transform: translateY(-3px); box-shadow: 0 18px 50px -24px rgba(245,180,0,.45); }
.gd-card-img { position: relative; display: block; aspect-ratio: 1 / 1; border-radius: 12px; overflow: hidden; background: rgba(255,255,255,.04); }
.gd-card-img img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.gd-card:hover .gd-card-img img { transform: scale(1.04); }
.gd-noimg { display: grid; place-items: center; width: 100%; height: 100%; color: var(--muted); font-size: 13px; }
.gd-badge { position: absolute; left: 10px; top: 10px; padding: 4px 10px; border-radius: 999px; background: rgba(5,10,26,.78); border: 1px solid rgba(255,255,255,.3); color: #fff; font-size: 12px; font-weight: 700; letter-spacing: .04em; }
.gd-card.is-soldout .gd-card-img img { filter: grayscale(.8); opacity: .7; }
.gd-card-name { font-weight: 700; line-height: 1.4; }
.gd-card-price { font-family: var(--cond); font-weight: 800; font-size: 20px; color: var(--gold); letter-spacing: .02em; }

/* 상품 상세 */
.gd-back { display: inline-block; margin-bottom: 20px; color: var(--muted); font-size: 14px; }
.gd-back:hover { color: var(--text); }
.gd-item { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(20px, 4vw, 48px); align-items: start; }
@media (max-width: 820px) { .gd-item { grid-template-columns: 1fr; } }
.gd-main { position: relative; aspect-ratio: 1 / 1; border-radius: 20px; overflow: hidden; border: 1px solid var(--line); background: rgba(255,255,255,.04); }
.gd-main img { display: block; width: 100%; height: 100%; object-fit: contain; }
.gd-thumbs { display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; padding-bottom: 4px; }
.gd-thumb { flex: none; width: 68px; height: 68px; padding: 0; border-radius: 10px; overflow: hidden; border: 2px solid transparent; background: rgba(255,255,255,.04); cursor: pointer; }
.gd-thumb[aria-pressed="true"] { border-color: var(--gold); }
.gd-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.gd-name { font-family: var(--cond); font-weight: 800; font-size: clamp(26px, 3.4vw, 38px); line-height: 1.2; letter-spacing: .01em; }
.gd-price { margin-top: 10px; font-family: var(--cond); font-weight: 800; font-size: 28px; color: var(--gold); }
.gd-desc { margin-top: 18px; color: var(--text); font-size: 15px; line-height: 1.8; }
.gd-desc p + p { margin-top: 2px; }
.gd-desc a { color: var(--gold); text-decoration: underline; text-underline-offset: 3px; }
.gd-soldout-note { margin-top: 20px; color: #ffb4ba; font-weight: 700; }
.gd-buy { display: grid; gap: 14px; margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.gd-buy .btn { justify-self: start; }
.gd-buy .btn.is-added { background: #22c55e; border-color: #22c55e; color: #052e16; }
.gd-qty { max-width: 220px; }
.gd-stepper { display: inline-flex; align-items: stretch; border: 1px solid rgba(255,255,255,.18); border-radius: 12px; overflow: hidden; background: rgba(255,255,255,.04); }
.gd-stepper button { width: 42px; border: 0; background: transparent; color: var(--text); font-size: 20px; cursor: pointer; }
.gd-stepper button:hover { background: rgba(255,255,255,.08); }
.gd-stepper input { width: 56px; text-align: center; border: 0; border-left: 1px solid rgba(255,255,255,.12); border-right: 1px solid rgba(255,255,255,.12); border-radius: 0 !important; background: transparent !important; box-shadow: none !important; -moz-appearance: textfield; }
.gd-stepper input::-webkit-outer-spin-button, .gd-stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* 장바구니 요약(떠 있는 칸) */
.gd-cartbar { margin-top: 28px; }

/* 주문 폼: 장바구니 표 */
.gd-cart { display: grid; gap: 10px; }
.gd-cart-row { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto auto auto; gap: 12px; align-items: center; padding: 10px 12px; border-radius: 14px; border: 1px solid var(--line); background: rgba(255,255,255,.03); }
.gd-cart-img { width: 56px; height: 56px; border-radius: 10px; overflow: hidden; background: rgba(255,255,255,.05); }
.gd-cart-img img { display: block; width: 100%; height: 100%; object-fit: cover; }
.gd-cart-name { display: grid; gap: 2px; min-width: 0; }
.gd-cart-name b { line-height: 1.3; }
.gd-cart-name small { color: var(--muted); font-size: 12px; }
.gd-cart-amt { font-family: var(--cond); font-weight: 800; font-size: 18px; color: var(--gold); white-space: nowrap; }
.gd-remove { width: 32px; height: 32px; border-radius: 50%; border: 1px solid rgba(255,255,255,.18); background: transparent; color: var(--muted); font-size: 18px; cursor: pointer; }
.gd-remove:hover { border-color: var(--hong); color: #ffb4ba; }
@media (max-width: 600px) {
  .gd-cart-row { grid-template-columns: 48px minmax(0, 1fr) auto; }
  .gd-cart-row .gd-stepper { grid-column: 2; }
  .gd-cart-row .gd-cart-amt { grid-column: 3; grid-row: 1; }
  .gd-cart-row .gd-remove { grid-column: 3; grid-row: 2; justify-self: end; }
}
.gd-empty { color: var(--muted); }

/* 받는 방법 */
.gd-delivery { display: grid; gap: 10px; }
.gd-radio { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border: 1px solid rgba(255,255,255,.14); border-radius: 14px; cursor: pointer; }
.gd-radio:has(input:checked) { border-color: var(--gold); background: rgba(245,180,0,.05); }
.gd-radio input { margin-top: 4px; accent-color: var(--gold); }
.gd-radio b { display: block; }
.gd-radio small { color: var(--muted); font-size: 12px; }
.gd-delivery.invalid { border-radius: 14px; }

/* 합계·결제 버튼 */
.gd-total { margin-top: 20px; }
.gd-paynote { flex-basis: 100%; margin: 0; color: var(--muted); font-size: 12px; }

/* 완료 화면 영수증 */
.gd-receipt { max-width: 440px; margin: 24px auto 0; text-align: left; border: 1px solid var(--line); border-radius: 16px; padding: 14px 18px; display: grid; gap: 6px; }
.gd-receipt > div { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.gd-receipt small { color: var(--muted); }
.gd-receipt-total { margin-top: 6px; padding-top: 8px; border-top: 1px solid var(--line); font-weight: 700; }
.gd-receipt-total b { color: var(--gold); font-size: 18px; }
