/* =====================================================================
   침향단 판매몰 - style.css
   컬러: 크림 #FAF6EF / 진갈색 #2B2118 / 갈색 #A5672A / 금색 #C9A24B
   ===================================================================== */

* { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, 'Malgun Gothic', sans-serif;
  background: #e9e4dc;
  color: #2b2118;
  font-size: 15px;
  line-height: 1.6;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font-family: inherit; cursor: pointer; }
.muted { color: #999; font-size: 13px; }

.wrap {
  max-width: 640px;
  margin: 0 auto;
  background: #faf6ef;
  min-height: 100vh;
  box-shadow: 0 0 30px rgba(0,0,0,.08);
}

/* ===== 헤더 ===== */
.hdr {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px;
  background: #fff;
  border-bottom: 1px solid #eee5d8;
  position: sticky; top: 0; z-index: 40;
}
.hdr .brand { text-decoration: none; font-weight: 800; font-size: 19px; color: #2b2118; letter-spacing: -.5px; }
.hdr .brand img { height: 34px; width: auto; }
.hdr-link { font-size: 13px; color: #a5672a; text-decoration: none; font-weight: 600; }

/* ===== 상단 랜딩 이미지 ===== */
.landing { background: #fff; }
.landing img { width: 100%; }
.landing a { display: block; }

/* ===== 갤러리 ===== */
.gallery { position: relative; background: #fff; }
.slides { position: relative; overflow: hidden; }
.slide { position: absolute; inset: 0; opacity: 0; transition: opacity .4s; }
.slide:first-child { position: relative; }          /* 첫 장이 높이 기준 (원본 비율 유지) */
.slide.on { opacity: 1; }
.slide img { width: 100%; height: 100%; object-fit: contain; display: block; }
.slide.placeholder { display: flex; align-items: center; justify-content: center; color: #bbb; font-size: 14px; background: #f4efe6; }
.sl-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 38px; height: 38px; border-radius: 50%; border: none;
  background: rgba(255,255,255,.85); color: #2b2118; font-size: 22px; font-weight: 700;
  box-shadow: 0 2px 8px rgba(0,0,0,.15);
}
.sl-btn.prev { left: 10px; }
.sl-btn.next { right: 10px; }
.dots { position: absolute; bottom: 12px; left: 0; right: 0; display: flex; justify-content: center; gap: 6px; }
.dots span { width: 7px; height: 7px; border-radius: 50%; background: rgba(255,255,255,.55); }
.dots span.on { background: #a5672a; }

/* ===== 상품 정보 ===== */
.pinfo { background: #fff; padding: 22px 20px 18px; border-bottom: 8px solid #f1ebe0; }
.badge {
  display: inline-block; background: #c9a24b; color: #fff;
  font-size: 11px; font-weight: 800; padding: 3px 9px; border-radius: 4px; margin-bottom: 10px;
}
.pinfo h1 { font-size: 22px; font-weight: 800; letter-spacing: -.5px; margin-bottom: 6px; }
.pinfo .summary { color: #7a6a55; font-size: 14px; margin-bottom: 12px; }
.pinfo .price { display: flex; align-items: baseline; gap: 3px; margin-bottom: 14px; }
.pinfo .price b { font-size: 28px; font-weight: 800; color: #a5672a; }
.pinfo .price span { font-size: 16px; color: #a5672a; font-weight: 700; }
.pinfo .desc { font-size: 14px; color: #555; line-height: 1.7; margin-bottom: 14px; }
.ship-note { list-style: none; font-size: 13px; color: #666; }
.ship-note li { padding: 4px 0; }
.ship-note b { color: #2b2118; }

/* ===== 구매 박스 ===== */
.buy { background: #fff; padding: 20px; border-bottom: 8px solid #f1ebe0; }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; font-weight: 700; color: #555; margin-bottom: 6px; }
.field select {
  width: 100%; height: 46px; border: 1px solid #d9d0c2; border-radius: 8px;
  padding: 0 12px; font-size: 15px; font-family: inherit; background: #fff;
}
.qty { display: inline-flex; border: 1px solid #d9d0c2; border-radius: 8px; overflow: hidden; }
.qty .qb { width: 44px; height: 44px; border: none; background: #f7f2ea; font-size: 18px; font-weight: 700; color: #2b2118; }
.qty input { width: 60px; height: 44px; border: none; text-align: center; font-size: 16px; font-weight: 700; background: #fff; }
.total {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 0; border-top: 1px dashed #e4dbcd; margin-top: 4px;
  font-size: 14px; color: #555;
}
.total b { font-size: 22px; color: #a5672a; font-weight: 800; }
.btn-buy {
  width: 100%; height: 54px; border: none; border-radius: 10px;
  background: linear-gradient(135deg, #a5672a, #8a5220);
  color: #fff; font-size: 17px; font-weight: 800; letter-spacing: -.3px;
  box-shadow: 0 6px 16px rgba(165,103,42,.35);
}
.btn-buy:active { transform: scale(.98); }
.secure { text-align: center; font-size: 12px; color: #999; margin-top: 10px; }

/* ===== 섹션 공통 ===== */
.sec-title {
  font-size: 16px; font-weight: 800; padding: 18px 20px 12px;
  color: #2b2118; letter-spacing: -.3px;
}
.detail { background: #fff; border-bottom: 8px solid #f1ebe0; }
.detail img { width: 100%; }

/* ===== 후기 ===== */
.reviews { background: #fff; border-bottom: 8px solid #f1ebe0; padding-bottom: 8px; }
.rv { padding: 14px 20px; border-top: 1px solid #f3eee6; }
.rv-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.stars { color: #c9a24b; font-size: 14px; letter-spacing: 1px; }
.who { font-size: 12px; color: #999; }
.rv img { border-radius: 8px; margin-bottom: 8px; max-height: 240px; object-fit: cover; }
.rv p { font-size: 14px; color: #444; line-height: 1.7; }

/* ===== 안내 ===== */
.notice { background: #fff; padding-bottom: 20px; }
.notice-body { padding: 0 20px; font-size: 13px; color: #555; line-height: 1.75; white-space: normal; }

/* ===== 정책 페이지 ===== */
.page { background: #fff; padding: 24px 20px 32px; min-height: 60vh; }
.page-title { font-size: 20px; font-weight: 800; margin-bottom: 18px; }
.page-body { font-size: 14px; color: #444; line-height: 1.8; }
.btn-back {
  display: inline-block; margin-top: 24px; padding: 11px 20px; border-radius: 8px;
  background: #f1ebe0; color: #2b2118; font-size: 14px; font-weight: 700; text-decoration: none;
}

/* ===== 하단 고정 CTA ===== */
.sticky-cta {
  position: sticky; bottom: 0; z-index: 50;
  display: block; width: 100%; text-align: center; text-decoration: none;
  padding: 16px 0; font-size: 17px; font-weight: 800;
  background: linear-gradient(135deg, #a5672a, #8a5220); color: #fff;
  box-shadow: 0 -4px 16px rgba(0,0,0,.15);
}

/* ===== 푸터 ===== */
.ftr { background: #2b2118; color: #b9ab98; padding: 24px 20px 32px; font-size: 12px; text-align: center; }
.ftr-links { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; margin-bottom: 16px; }
.ftr-links a { color: #e2d5c4; text-decoration: none; }
.ftr-links a b { color: #fff; }
.ftr .biz { line-height: 1.9; }
.ftr .cert { margin-top: 14px; display: inline-block; line-height: 0; }
.ftr .cert img { width: 80px; height: auto; }
.ftr .copy { margin-top: 14px; color: #6f634f; font-size: 11px; }

/* =====================================================================
   2단계: 주문서 · 결과 · 주문조회
   ===================================================================== */

/* ===== 주문서 ===== */
.order { padding: 20px 16px 30px; }
.ocard { background: #fff; border-radius: 12px; padding: 18px 16px; margin-bottom: 12px; border: 1px solid #eee5d8; }
.ocard h2 { font-size: 15px; font-weight: 800; margin-bottom: 12px; color: #2b2118; }
.oitem { display: flex; gap: 12px; align-items: center; }
.oitem img { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; flex: none; }
.oitem > div { flex: 1; font-size: 14px; }
.oitem b { display: block; font-size: 15px; margin-bottom: 2px; }
.oprice { font-weight: 800; color: #a5672a; white-space: nowrap; }
.f { margin-bottom: 12px; }
.f label { display: block; font-size: 13px; font-weight: 700; color: #555; margin-bottom: 6px; }
.f label em { color: #e23b3b; font-style: normal; }
.f input, .f select {
  width: 100%; height: 46px; border: 1px solid #d9d0c2; border-radius: 8px;
  padding: 0 12px; font-size: 15px; font-family: inherit; background: #fff;
}
.f input:focus, .f select:focus { outline: none; border-color: #a5672a; }
.f input[readonly] { background: #faf6ef; }
.zip { display: flex; gap: 8px; }
.zip input { flex: 1; }
.btn-zip { flex: none; padding: 0 16px; height: 46px; border: none; border-radius: 8px;
  background: #2b2118; color: #fff; font-size: 14px; font-weight: 700; }
.amt { display: flex; justify-content: space-between; padding: 8px 0; font-size: 14px; color: #555; }
.amt b { color: #2b2118; }
.amt.total { border-top: 1px dashed #e4dbcd; margin-top: 4px; padding-top: 14px; font-size: 15px; font-weight: 800; }
.amt.total b { font-size: 22px; color: #a5672a; }
.agree { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; line-height: 1.6; cursor: pointer; }
.agree input { width: 20px; height: 20px; flex: none; margin-top: 2px; accent-color: #a5672a; }
.agree a { color: #a5672a; font-weight: 700; }
.agree em { color: #e23b3b; font-style: normal; }
.btn-pay {
  width: 100%; height: 56px; border: none; border-radius: 12px; margin-top: 6px;
  background: linear-gradient(135deg, #a5672a, #8a5220); color: #fff;
  font-size: 18px; font-weight: 800; box-shadow: 0 6px 16px rgba(165,103,42,.35);
}
.btn-pay:disabled { background: #bbb; box-shadow: none; }
.alert-box { background: #fee2e2; color: #b91c1c; padding: 12px 14px; border-radius: 9px; font-size: 13px; font-weight: 600; margin-bottom: 14px; }
.order .page-title { font-size: 20px; }

/* ===== 결과 페이지 (완료/실패) ===== */
.result { text-align: left; }
.ric { width: 76px; height: 76px; border-radius: 50%; margin: 6px auto 18px; font-size: 40px; font-weight: 800;
  display: flex; align-items: center; justify-content: center; color: #fff; }
.ric.ok   { background: linear-gradient(135deg, #a5672a, #c9a24b); box-shadow: 0 8px 20px rgba(165,103,42,.35); }
.ric.fail { background: #e23b3b; box-shadow: 0 8px 20px rgba(226,59,59,.3); }
.rmsg { text-align: center; color: #555; font-size: 14px; line-height: 1.7; margin-bottom: 18px; }
.rbox { background: #faf6ef; border-radius: 10px; padding: 6px 14px; margin-bottom: 8px; }
.rrow { display: flex; gap: 12px; padding: 9px 0; border-bottom: 1px solid #efe7da; font-size: 13px; }
.rrow:last-child { border-bottom: none; }
.rrow span { width: 68px; flex: none; color: #888; }
.rrow b { flex: 1; font-weight: 600; color: #2b2118; line-height: 1.5; }
.mono { font-family: 'JetBrains Mono', Consolas, monospace; letter-spacing: .3px; }
.ractions { display: flex; gap: 8px; margin-top: 10px; }
.btn-main { flex: 1; display: block; text-align: center; text-decoration: none; padding: 14px 0; border-radius: 10px;
  background: #a5672a; color: #fff; font-size: 15px; font-weight: 800; border: none; font-family: inherit; cursor: pointer; }
.btn-sub  { flex: 1; display: block; text-align: center; text-decoration: none; padding: 14px 0; border-radius: 10px;
  background: #f1ebe0; color: #2b2118; font-size: 15px; font-weight: 700; }

/* ===== 주문조회 ===== */
.lookup-form { background: #fff; border: 1px solid #eee5d8; border-radius: 12px; padding: 18px 16px; margin-bottom: 18px; }
.ferr { color: #b91c1c; font-size: 13px; font-weight: 600; margin-top: 10px; text-align: center; }
.odetail { background: #fff; border: 1px solid #eee5d8; border-radius: 12px; padding: 18px 16px; }
.steps { display: flex; justify-content: space-between; margin: 4px 6px 20px; position: relative; }
.steps::before { content: ''; position: absolute; left: 12px; right: 12px; top: 9px; height: 2px; background: #e4dbcd; }
.step { position: relative; text-align: center; flex: 1; }
.step .dot { display: block; width: 18px; height: 18px; border-radius: 50%; background: #e4dbcd; margin: 0 auto 6px; border: 3px solid #fff; }
.step .lbl { font-size: 11px; color: #aaa; }
.step.on .dot { background: #c9a24b; }
.step.on .lbl { color: #7a6a55; }
.step.cur .dot { background: #a5672a; box-shadow: 0 0 0 3px rgba(165,103,42,.2); }
.step.cur .lbl { color: #a5672a; font-weight: 800; }
.ostatus.cancel { background: #fee2e2; color: #b91c1c; border-radius: 9px; padding: 12px 14px; margin-bottom: 14px; font-size: 13px; }
.ostatus.cancel b { display: block; font-size: 15px; margin-bottom: 3px; }
.ostatus.cancel span { display: block; }
.track { display: inline-block; margin-left: 8px; font-size: 12px; color: #a5672a; text-decoration: none; font-weight: 700; }

/* =====================================================================
   랜딩 구조 (핸드폰 랜딩과 동일 요소)
   ===================================================================== */

/* 카운트다운 바 */
.countdown-bar {
  position: sticky; top: 0; z-index: 45;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  background: linear-gradient(135deg, #2b2118, #4a3520); color: #fff;
  padding: 10px 14px; font-size: 13px; font-weight: 700;
}
.cd-timer { font-family: 'JetBrains Mono', Consolas, monospace; color: #c9a24b; font-size: 15px; letter-spacing: .5px; }
.countdown-bar.ended { background: #666; }
.hdr { top: auto; position: relative; }   /* 헤더 sticky 해제 (카운트다운이 상단 고정) */

/* 섹션 이미지 */
.sections { background: #fff; }
.sections img { width: 100%; display: block; }
.sections a { display: block; }
.sections .placeholder { padding: 60px 20px; text-align: center; color: #bbb; font-size: 14px; background: #f4efe6; }

/* 잔여수량 */
.stock-bar { background: #fff3cd; color: #8a6d1a; text-align: center; padding: 9px 12px; font-size: 13px; font-weight: 700; }
.stock-bar b { color: #a5672a; font-size: 15px; }
.stock-bar b.rem { color: #e23b3b; }
.stock-bar b.soldout { color: #888; }

/* 구매박스 (핸드폰 랜딩 접수폼 스타일) */
.buy { background: #1a1a1a; padding: 0 0 22px; border-bottom: none; }
.buy-head { background: linear-gradient(135deg, #a5672a, #8a5220); color: #fff; text-align: center; padding: 18px 16px; }
.buy-head .fire { font-size: 13px; }
.buy-head b { font-size: 19px; font-weight: 800; }
.buy-head p { font-size: 12px; opacity: .92; margin-top: 5px; }
.buy-body { padding: 18px 16px 0; }
.pline { background: #fff; border-radius: 10px; padding: 16px; margin-bottom: 14px; }
.pline .badge { margin-bottom: 8px; }
.pline .pname { display: block; font-size: 18px; font-weight: 800; color: #2b2118; }
.pline .psum { display: block; font-size: 13px; color: #7a6a55; margin-top: 2px; }
.pline .price { margin: 10px 0 0; }
.pline .price b { font-size: 26px; font-weight: 800; color: #a5672a; }
.pline .price span { font-size: 15px; color: #a5672a; font-weight: 700; }
.pline .pdesc { font-size: 13px; color: #555; line-height: 1.65; margin-top: 10px; }
.buy .field label { color: #ddd; }
.buy .field select { border-color: #444; }
.buy .qty { border-color: #444; }
.buy .ship-note { color: #bbb; margin-bottom: 4px; }
.buy .ship-note b { color: #fff; }
.buy .total { color: #ccc; border-top-color: #333; }
.buy .total b { color: #c9a24b; }
.buy .secure { color: #888; }

/* 실시간 구매현황 */
.live { background: #fff; padding-bottom: 14px; border-bottom: 8px solid #f1ebe0; }
.ticker-wrap { height: 176px; overflow: hidden; margin: 0 16px; border: 1px solid #eee5d8; border-radius: 10px; background: #faf6ef; }
.ticker { list-style: none; }
.ticker li { display: flex; gap: 8px; align-items: center; padding: 9px 12px; border-bottom: 1px solid #f1ebe0; font-size: 12px; height: 44px; }
.ticker .nm { font-weight: 800; color: #2b2118; width: 48px; }
.ticker .ph { color: #888; width: 100px; }
.ticker .in { color: #a5672a; font-weight: 700; flex: 1; }
.ticker .tm { color: #aaa; font-size: 11px; }

/* 플로팅 버튼 */
.float-btns { position: fixed; right: 14px; bottom: 74px; z-index: 55; display: flex; flex-direction: column; gap: 8px; }
.fbtn { display: flex; align-items: center; gap: 5px; padding: 11px 16px; border-radius: 30px; font-size: 13px; font-weight: 800;
  text-decoration: none; color: #fff; box-shadow: 0 4px 12px rgba(0,0,0,.28); }
.fbtn-kakao { background: #fae100; color: #3c1e1e; }
.fbtn-tel { background: #2f9e44; }
.fbtn .ic { font-size: 15px; }

/* 토스트 */
.live-toast { position: fixed; left: 14px; bottom: 78px; z-index: 54; background: rgba(20,20,20,.94); color: #fff; font-size: 12px;
  padding: 10px 14px; border-radius: 10px; max-width: 260px; box-shadow: 0 6px 18px rgba(0,0,0,.3);
  opacity: 0; transform: translateY(10px); transition: opacity .4s, transform .4s; pointer-events: none; }
.live-toast.on { opacity: 1; transform: translateY(0); }
.live-toast b { color: #c9a24b; }
.lt-dot { display: inline-block; width: 7px; height: 7px; background: #4ade80; border-radius: 50%; margin-right: 5px; }
