/* ============================================================
   산지직빵농수산 — 모바일 앱형 커머스
   손님 90%가 폰. 화면은 640px 한 칼럼 기준으로 짭니다.
   ============================================================ */

:root {
  --ink:      #0C2E31;   /* 갯벌 먹빛 — 헤더·탭바 */
  --ink-2:    #14464A;
  --sea:      #0E6E7E;   /* 물결 청록 — 수산 */
  --sea-3:    #6FBFC8;
  --land:     #5E7F3C;   /* 무청 초록 — 농산 */
  --gift:     #A8752F;   /* 선물 */
  --red:      #D64031;   /* 값·할인 */
  --red-2:    #B22F22;
  --tx:       #17211F;
  --tx-2:     #6B7876;
  --tx-3:     #9AA5A3;
  --line:     #E6EAE8;
  --bg:       #F2F4F3;
  --w:        #FFFFFF;

  --app: 640px;
  --r: 10px;
  --tabh: 58px;

  --f-sign: "Black Han Sans", sans-serif;
  --f: "IBM Plex Sans KR", -apple-system, BlinkMacSystemFont, "Malgun Gothic", sans-serif;
  --f-num: "IBM Plex Sans KR", sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--f); color: var(--tx); background: var(--bg);
  line-height: 1.6; -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: none; cursor: pointer; }
ul, ol { list-style: none; }
input, select, textarea { font: inherit; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* 앱 컨테이너 */
.app {
  max-width: var(--app); margin: 0 auto; background: var(--w);
  min-height: 100vh; position: relative; overflow-x: hidden;
  padding-bottom: calc(var(--tabh) + env(safe-area-inset-bottom) + 8px);
  box-shadow: 0 0 40px rgba(12,46,49,.07);
}

/* ============ 상단 ============ */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: var(--ink); color: #fff;
}
.tb-in {
  display: flex; align-items: center; gap: 10px;
  height: 54px; padding: 0 14px;
}
.tb-logo { display: flex; align-items: center; gap: 8px; }
.tb-logo img { width: 32px; height: 32px; }
.tb-logo b { font-family: var(--f-sign); font-weight: 400; font-size: 19px; letter-spacing: .01em; }
.tb-acts { margin-left: auto; display: flex; align-items: center; gap: 4px; }
.icon-btn {
  width: 40px; height: 40px; display: grid; place-items: center;
  position: relative; border-radius: 50%;
}
.icon-btn:active { background: rgba(255,255,255,.12); }
.icon-btn svg { width: 22px; height: 22px; stroke: #fff; fill: none; stroke-width: 1.9; }
.cart-badge {
  position: absolute; top: 3px; right: 3px;
  min-width: 17px; height: 17px; padding: 0 4px;
  background: var(--red); color: #fff; border-radius: 999px;
  font-size: 10.5px; font-weight: 700; display: grid; place-items: center;
}

/* 공지 띠 */
.notice {
  background: var(--ink-2); color: #A9C9C8;
  font-size: 12px; padding: 7px 14px; text-align: center;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* 상단 탭 */
.tabs { display: flex; background: var(--ink); border-bottom: 1px solid rgba(255,255,255,.12); }
.tabs a {
  flex: 1; text-align: center; padding: 13px 0 12px;
  font-size: 14.5px; font-weight: 500; color: rgba(255,255,255,.55);
  border-bottom: 2.5px solid transparent;
}
.tabs a.on { color: #fff; font-weight: 700; border-bottom-color: #fff; }

/* ============ 히어로 캐러셀 ============ */
.hero { position: relative; background: var(--ink); overflow: hidden; }
.hero-track { display: flex; transition: transform .45s cubic-bezier(.4,0,.2,1); }
.hero-slide { min-width: 100%; position: relative; }
.hero-slide img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.hero-tx {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 60px 20px 22px; color: #fff;
  background: linear-gradient(180deg, rgba(8,30,32,0) 0%, rgba(8,30,32,.82) 62%, rgba(8,30,32,.94) 100%);
}
.hero-tx h2 { font-size: 24px; font-weight: 700; line-height: 1.3; letter-spacing: -.02em; }
.hero-tx p { font-size: 13.5px; color: #C3D6D5; margin-top: 6px; }
.hero-count {
  position: absolute; right: 14px; bottom: 14px;
  background: rgba(0,0,0,.5); color: #fff;
  font-size: 11.5px; font-weight: 600; padding: 4px 10px; border-radius: 999px;
}
.hero-dots { position: absolute; left: 20px; bottom: 16px; display: flex; gap: 5px; }
.hero-dots i { width: 6px; height: 6px; border-radius: 50%; background: rgba(255,255,255,.42); }
.hero-dots i.on { background: #fff; width: 16px; border-radius: 3px; }

/* ============ 카테고리 ============ */
.catrow {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 6px; padding: 20px 14px 6px;
}
.cat { display: flex; flex-direction: column; align-items: center; gap: 9px; padding: 6px 0; }
.cat-ic {
  width: 72px; height: 72px; border-radius: 50%; overflow: hidden;
  background: var(--bg); border: 1px solid var(--line);
}
.cat-ic img { width: 100%; height: 100%; object-fit: cover; }
.cat b { font-size: 14px; font-weight: 600; }
.cat:active .cat-ic { transform: scale(.95); }
.cat-ic { transition: transform .15s ease; }

/* ============ 진열대 ============ */
.shelf { padding: 26px 0 8px; }
.shelf-hd {
  display: flex; align-items: baseline; gap: 8px;
  padding: 0 16px 14px;
}
.shelf-hd h3 { font-size: 19px; font-weight: 700; letter-spacing: -.02em; }
.shelf-hd span { font-size: 12.5px; color: var(--tx-3); }
.shelf-hd a { margin-left: auto; font-size: 13px; color: var(--tx-2); font-weight: 500; }
.shelf-hd a::after { content: " ›"; }

/* 가로 스크롤 */
.rail {
  display: flex; gap: 12px; overflow-x: auto; padding: 0 16px 6px;
  scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.rail::-webkit-scrollbar { display: none; }
.rail > * { scroll-snap-align: start; }

/* 넓은 카드 */
.wide { min-width: 78%; max-width: 78%; }
.wide .p-img { aspect-ratio: 4 / 3; border-radius: var(--r); }
.wide .p-copy { font-size: 17px; font-weight: 700; line-height: 1.35; margin-top: 11px; letter-spacing: -.02em; }
.wide .p-sub {
  display: flex; align-items: center; gap: 9px; margin-top: 9px;
  padding-top: 9px; border-top: 1px solid var(--line);
}
.wide .p-sub img { width: 38px; height: 38px; border-radius: 6px; object-fit: cover; flex: none; }
.wide .p-sub-tx { min-width: 0; }
.wide .p-name { font-size: 12.5px; color: var(--tx-2); overflow: hidden;
  display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; }

/* 세로 리스트 카드 */
.plist { padding: 0 16px; display: flex; flex-direction: column; gap: 26px; }
.pitem .p-img { aspect-ratio: 1 / 1; border-radius: var(--r); }

/* 2열 그리드 (목록 페이지) */
.pgrid2 { padding: 16px; display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px 12px; }
.pgrid2 .p-img { aspect-ratio: 1 / 1; border-radius: var(--r); }
.pgrid2 .p-title { font-size: 14px; }

/* 카드 공통 */
.p-img { position: relative; overflow: hidden; background: var(--bg); display: block; }
.p-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.p-badge {
  position: absolute; left: 8px; top: 8px; z-index: 2;
  background: var(--red); color: #fff; font-size: 11px; font-weight: 700;
  padding: 4px 9px; border-radius: 6px;
}
.p-like {
  position: absolute; right: 8px; bottom: 8px; z-index: 2;
  width: 34px; height: 34px; border-radius: 50%;
  background: rgba(0,0,0,.42); display: grid; place-items: center;
}
.p-like svg { width: 19px; height: 19px; fill: none; stroke: #fff; stroke-width: 2; }
.p-like.on svg { fill: var(--red); stroke: var(--red); }

.p-title {
  font-size: 15px; font-weight: 500; line-height: 1.45; margin-top: 10px;
  overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.p-price { display: flex; align-items: baseline; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.p-off { color: var(--red); font-weight: 700; font-size: 15px; }
.p-now { font-weight: 700; font-size: 16.5px; letter-spacing: -.02em; }
.p-now em { font-style: normal; font-weight: 500; font-size: 12.5px; color: var(--tx-2); }
.p-was { font-size: 12.5px; color: var(--tx-3); text-decoration: line-through; }
.p-ask { font-size: 15px; font-weight: 700; color: var(--gift); margin-top: 6px; }
.p-tags { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 8px; }
.p-tags i {
  font-style: normal; font-size: 11px; color: var(--tx-2);
  border: 1px solid var(--line); padding: 2px 7px; border-radius: 4px;
}
.p-from {
  display: flex; align-items: center; gap: 7px; margin-top: 10px;
  font-size: 12px; color: var(--tx-2);
}
.p-from img { width: 22px; height: 22px; border-radius: 50%; background: var(--bg); }
.p-from b { font-weight: 500; }

/* 오늘특가 */
.deal { background: #FFF6F4; padding: 22px 0 26px; margin-top: 22px; }
.deal .shelf-hd h3 { display: flex; align-items: baseline; gap: 8px; }
.deal-clock { color: var(--red); font-weight: 700; font-size: 16px; font-variant-numeric: tabular-nums; }
.deal .plist { padding: 0 16px; }

/* ============ 하단 탭바 ============ */
.tabbar {
  position: fixed; left: 50%; transform: translateX(-50%); bottom: 0;
  width: 100%; max-width: var(--app); z-index: 60;
  background: rgba(255,255,255,.97); backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom);
  display: grid; grid-template-columns: repeat(4, 1fr);
}
.tabbar a {
  height: var(--tabh); display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 3px;
  font-size: 10.5px; color: var(--tx-3); position: relative;
}
.tabbar a svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.tabbar a.on { color: var(--ink); font-weight: 700; }
.tabbar .cart-badge { top: 6px; right: calc(50% - 20px); }

/* 맨 위로 */
.fab {
  position: fixed; z-index: 55; right: 16px;
  bottom: calc(var(--tabh) + env(safe-area-inset-bottom) + 16px);
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--w); border: 1px solid var(--line);
  box-shadow: 0 4px 14px rgba(12,46,49,.16);
  display: grid; place-items: center;
  opacity: 0; pointer-events: none; transition: opacity .22s ease;
}
.fab.on { opacity: 1; pointer-events: auto; }
.fab svg { width: 20px; height: 20px; stroke: var(--ink); fill: none; stroke-width: 2; }
@media (min-width: 700px) { .fab { right: calc(50% - var(--app)/2 + 16px); } }

/* 토스트 */
.toast {
  position: fixed; z-index: 70; left: 50%; transform: translateX(-50%) translateY(20px);
  bottom: calc(var(--tabh) + env(safe-area-inset-bottom) + 14px);
  width: calc(100% - 32px); max-width: 420px;
  background: rgba(18,26,25,.95); color: #fff; border-radius: 12px;
  padding: 11px 14px; display: flex; align-items: center; gap: 11px;
  opacity: 0; pointer-events: none; transition: all .28s cubic-bezier(.4,0,.2,1);
  font-size: 13.5px;
}
.toast.on { opacity: 1; transform: translateX(-50%) translateY(0); pointer-events: auto; }
.toast img { width: 40px; height: 40px; border-radius: 8px; object-fit: cover; flex: none; }
.toast b { display: block; font-size: 13px; font-weight: 600; }
.toast span { color: var(--sea-3); font-size: 12.5px; }
.toast button { margin-left: auto; color: #8FA3A2; font-size: 20px; line-height: 1; padding: 4px; }

/* ============ 검색 ============ */
.searchbar { padding: 12px 14px; background: var(--w); border-bottom: 1px solid var(--line); display: none; }
.searchbar.on { display: block; }
.searchbar input {
  width: 100%; padding: 12px 14px; border: 1px solid var(--line);
  border-radius: 10px; background: var(--bg); font-size: 15px;
}

/* ============ 페이지 머리 ============ */
.phead { padding: 20px 16px 6px; }
.phead h1 { font-size: 23px; font-weight: 700; letter-spacing: -.02em; }
.phead p { font-size: 13.5px; color: var(--tx-2); margin-top: 5px; }
.subtabs { display: flex; gap: 7px; padding: 14px 16px 4px; overflow-x: auto; scrollbar-width: none; }
.subtabs::-webkit-scrollbar { display: none; }
.subtabs a {
  flex: none; padding: 8px 15px; border-radius: 999px; font-size: 13.5px;
  border: 1px solid var(--line); color: var(--tx-2); background: var(--w);
}
.subtabs a.on { background: var(--ink); border-color: var(--ink); color: #fff; font-weight: 600; }

/* ============ 상품 상세 ============ */
.pd-gallery { position: relative; }
.pd-track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.pd-track::-webkit-scrollbar { display: none; }
.pd-track img { min-width: 100%; aspect-ratio: 1 / 1; object-fit: cover; scroll-snap-align: start; }
.pd-body { padding: 20px 16px 8px; }
.pd-origin { font-size: 12.5px; color: var(--sea); font-weight: 600; }
.pd-name { font-size: 21px; font-weight: 700; line-height: 1.35; margin-top: 7px; letter-spacing: -.02em; }
.pd-copy { font-size: 14.5px; color: var(--red); font-weight: 600; margin-top: 8px; }
.pd-price { display: flex; align-items: baseline; gap: 8px; margin-top: 14px; flex-wrap: wrap; }
.pd-price .p-off { font-size: 21px; }
.pd-price .p-now { font-size: 27px; }
.pd-summary { font-size: 14.5px; color: var(--tx-2); margin-top: 14px; }
.pd-facts { margin-top: 18px; border-top: 1px solid var(--line); }
.pd-facts div { display: flex; gap: 14px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.pd-facts dt { width: 74px; color: var(--tx-3); flex: none; }
.pd-facts dd { color: var(--tx); }

/* 옵션 고르기 */
.opt-wrap { padding: 4px 16px 20px; }
.opt-label { font-size: 12.5px; color: var(--tx-3); margin: 18px 0 9px; font-weight: 600; }
.chips { display: flex; gap: 7px; flex-wrap: wrap; }
.chip {
  padding: 11px 16px; border: 1.5px solid var(--line); border-radius: 9px;
  font-size: 14px; font-weight: 600; background: var(--w); min-height: 44px;
}
.chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }

/* 등급 저울 */
.scale { display: grid; grid-template-columns: repeat(3,1fr); gap: 4px; align-items: end;
  background: linear-gradient(180deg,#F7F9F8,#fff); border: 1px solid var(--line);
  border-radius: var(--r); padding: 20px 8px 0; }
.gr { display: flex; flex-direction: column; align-items: center; padding-bottom: 14px;
  border-bottom: 2.5px solid transparent; position: relative; }
.gr-shell { height: 96px; display: flex; align-items: flex-end; }
.gr-shell img { width: calc(84% * var(--s)); height: auto;
  filter: drop-shadow(0 6px 9px rgba(12,46,49,.15)); }
.gr-ruler { width: calc(84% * var(--s)); border-top: 1px solid #A8865E; height: 1px;
  margin-top: 11px; position: relative; }
.gr-ruler::before, .gr-ruler::after { content:""; position:absolute; top:-4px; width:1px; height:8px; background:#A8865E; }
.gr-ruler::before { left: 0; } .gr-ruler::after { right: 0; }
.gr-len { font-size: 10.5px; color: #6B4F35; margin-top: 6px; font-variant-numeric: tabular-nums; }
.gr-name { font-size: 15px; font-weight: 700; margin-top: 5px; }
.gr-use { font-size: 10.5px; color: var(--tx-3); }
.gr.on { border-bottom-color: var(--red); }
.gr.on .gr-name { color: var(--red); }
.gr-best { position: absolute; top: -6px; background: var(--red); color: #fff;
  font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 999px; }

/* 상세 이미지 */
.pd-detail { margin-top: 10px; }
.pd-detail img { width: 100%; }
.pd-more { padding: 26px 16px 10px; }

/* 하단 구매바 */
.buybar {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: calc(var(--tabh) + env(safe-area-inset-bottom));
  width: 100%; max-width: var(--app); z-index: 58;
  background: var(--w); border-top: 1px solid var(--line);
  padding: 10px 14px; display: flex; align-items: center; gap: 10px;
}
.buybar-p { line-height: 1.25; min-width: 0; }
.buybar-p b { display: block; font-size: 19px; font-weight: 700; letter-spacing: -.02em; }
.buybar-p span { font-size: 11.5px; color: var(--tx-3); display: block;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.buybar .btn { margin-left: auto; flex: none; }

/* 버튼 */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  padding: 14px 22px; border-radius: 10px; font-size: 15px; font-weight: 700;
  min-height: 48px; transition: background .18s ease, transform .12s ease;
}
.btn:active { transform: scale(.98); }
.btn-red { background: var(--red); color: #fff; }
.btn-red:active { background: var(--red-2); }
.btn-ink { background: var(--ink); color: #fff; }
.btn-line { border: 1.5px solid var(--line); color: var(--tx); }
.btn-block { width: 100%; }
.btn[disabled] { background: #C9D3D1; color: #fff; pointer-events: none; }

/* ============ 장바구니 ============ */
.cart-list { padding: 8px 16px; }
.citem { display: flex; gap: 12px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.citem img { width: 78px; height: 78px; border-radius: 8px; object-fit: cover; flex: none; }
.citem-b { flex: 1; min-width: 0; }
.citem-b h4 { font-size: 14.5px; font-weight: 600; line-height: 1.4; }
.citem-b p { font-size: 12.5px; color: var(--tx-2); margin-top: 3px; }
.citem-b strong { display: block; margin-top: 7px; font-size: 16px; }
.citem-x { color: var(--tx-3); font-size: 19px; padding: 2px 4px; align-self: flex-start; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--line);
  border-radius: 8px; margin-top: 8px; }
.qty button { width: 34px; height: 34px; font-size: 17px; color: var(--tx-2); }
.qty span { min-width: 32px; text-align: center; font-size: 14px; font-weight: 600; }
.cart-sum { padding: 18px 16px; background: var(--bg); margin-top: 8px; }
.cart-sum div { display: flex; justify-content: space-between; padding: 6px 0; font-size: 14px; color: var(--tx-2); }
.cart-sum .tot { border-top: 1px solid var(--line); margin-top: 8px; padding-top: 14px;
  font-size: 17px; font-weight: 700; color: var(--tx); }

/* 빈 상태 */
.empty { padding: 70px 24px; text-align: center; }
.empty svg { width: 46px; height: 46px; stroke: var(--tx-3); fill: none; stroke-width: 1.5; margin: 0 auto 16px; }
.empty h3 { font-size: 17px; font-weight: 700; }
.empty p { font-size: 14px; color: var(--tx-2); margin-top: 7px; }
.empty .btn { margin-top: 20px; }

/* 주문 안내 박스 */
.orderbox { padding: 18px 16px; }
.orderbox h4 { font-size: 15px; font-weight: 700; margin-bottom: 12px; }
.orderbox .btn { margin-bottom: 8px; }
.order-todo {
  font-size: 13px; color: var(--tx-2); background: var(--bg);
  border-left: 3px solid var(--gift); padding: 13px 14px; border-radius: 0 8px 8px 0;
}
.order-todo code { background: var(--w); border: 1px solid var(--line); padding: 1px 5px;
  border-radius: 4px; font-size: 12px; }

/* ============ 푸터 ============ */
.foot { background: var(--bg); padding: 26px 16px 30px; margin-top: 26px; }
.foot-links { display: flex; flex-wrap: wrap; gap: 14px; padding-bottom: 16px;
  border-bottom: 1px solid var(--line); font-size: 12.5px; color: var(--tx-2); }
.foot-legal { font-size: 11.5px; color: var(--tx-3); line-height: 1.85; margin-top: 16px; }
.foot-legal b { color: var(--tx-2); font-weight: 500; }
.foot-mark { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.foot-mark img { width: 34px; height: 34px; }
.foot-mark b { font-family: var(--f-sign); font-weight: 400; font-size: 16px; color: var(--ink); }

@media (max-width: 380px) {
  .cat-ic { width: 62px; height: 62px; }
  .hero-tx h2 { font-size: 21px; }
  .pd-name { font-size: 19px; }
}

/* ============================================================
   주문서 · 주문완료
   ============================================================ */
.co-sec { padding: 20px 16px; border-bottom: 8px solid var(--bg); }
.co-sec:last-child { border-bottom: none; }
.co-h { font-size: 16px; font-weight: 700; margin-bottom: 14px; }

.co-items { border-top: 1px solid var(--line); margin-bottom: 14px; }
.co-item { display: flex; align-items: center; gap: 11px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.co-item img { width: 52px; height: 52px; border-radius: 8px; object-fit: cover; flex: none; }
.co-item div { flex: 1; min-width: 0; }
.co-item b { display: block; font-size: 14px; font-weight: 600; line-height: 1.4; }
.co-item span { font-size: 12px; color: var(--tx-2); }
.co-item strong { font-size: 14.5px; white-space: nowrap; }

/* 입력 */
.fl { display: block; font-size: 13px; font-weight: 600; color: var(--tx-2); margin-bottom: 14px; }
.fl i { font-style: normal; font-weight: 400; color: var(--tx-3); }
.fi {
  display: block; width: 100%; margin-top: 7px;
  padding: 13px 14px; border: 1.5px solid var(--line); border-radius: 9px;
  background: var(--w); font-size: 16px; color: var(--tx); line-height: 1.5;
}
.fi:focus { border-color: var(--sea); outline: none; }
textarea.fi { resize: vertical; min-height: 78px; }

/* 결제수단 */
.pay-opt {
  border: 1.5px solid var(--line); border-radius: 9px;
  padding: 14px 15px; margin-bottom: 9px;
}
.pay-opt b { display: block; font-size: 15px; font-weight: 700; }
.pay-opt span { font-size: 12.5px; color: var(--tx-2); }
.pay-opt.on { border-color: var(--ink); background: #F7FAF9; }
.pay-opt.on b::before { content: "● "; color: var(--red); }
.pay-opt.off { opacity: .55; }
.pay-opt.off b::before { content: "○ "; color: var(--tx-3); }

.bank-box {
  margin-top: 14px; padding: 15px; border-radius: 9px;
  background: #F7FAF9; border: 1px solid var(--line);
}
.bank-box b { display: block; font-size: 17px; font-weight: 700; letter-spacing: -.01em; }
.bank-box span { display: block; font-size: 12.5px; color: var(--tx-2); }
.bank-box.wait { background: #FFF8F1; border-color: #EBD9C2; }
.bank-box.big { text-align: center; padding: 22px 16px; }
.bank-box.big b { font-size: 21px; margin: 6px 0 4px; }
.bank-box.big .btn { margin-top: 14px; }

.chk { display: flex; gap: 9px; align-items: flex-start; font-size: 13px; color: var(--tx-2); line-height: 1.6; }
.chk input { width: 20px; height: 20px; margin-top: 1px; flex: none; accent-color: var(--red); }
.co-note { font-size: 12.5px; color: var(--tx-3); margin-top: 12px; line-height: 1.7; }
.pay-amt { color: var(--red); font-size: 17px; font-weight: 700; }
.addr-v { text-align: right; max-width: 62%; }

/* 주문 완료 */
.done-top { text-align: center; padding: 38px 20px 30px; background: var(--ink); color: #fff; }
.done-mark {
  width: 54px; height: 54px; margin: 0 auto 16px; border-radius: 50%;
  background: var(--red); color: #fff; font-size: 27px; display: grid; place-items: center;
}
.done-top h2 { font-size: 21px; font-weight: 700; }
.done-top p { font-size: 13.5px; color: #A9C9C8; margin-top: 7px; }
.done-top b { color: #fff; font-weight: 700; }

/* 주문 내역 */
.ord { display: block; padding: 15px 0; border-bottom: 1px solid var(--line); }
.ord-hd { display: flex; align-items: center; gap: 9px; }
.ord-hd b { font-size: 14px; font-weight: 700; }
.ord-st {
  font-size: 11px; font-weight: 700; color: var(--red);
  background: #FFF0EE; padding: 3px 8px; border-radius: 5px;
}
.ord p { font-size: 13px; color: var(--tx-2); margin-top: 5px; }
.ord strong { font-size: 15px; }

/* ============================================================
   사장님 주문 확인
   ============================================================ */
.done-ok { font-size: 12.5px; color: #7FD4C8 !important; margin-top: 6px; }
.done-warn {
  font-size: 13px; color: #FFD9D2 !important; margin-top: 12px; line-height: 1.6;
  background: rgba(214,64,49,.25); border-radius: 8px; padding: 11px 13px;
}
.done-warn b { color: #fff; }

.chk-list { padding: 8px 16px 0; }
.chk-card {
  border: 1px solid var(--line); border-radius: var(--r);
  padding: 15px; margin-bottom: 13px; background: var(--w);
}
.chk-hd { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.chk-hd b { font-size: 14px; font-weight: 700; }
.chk-when { font-style: normal; margin-left: auto; font-size: 12px; color: var(--tx-3); }
.ord-st.st-입금확인 { color: var(--sea); background: #E6F3F5; }
.ord-st.st-발송완료 { color: var(--land); background: #EDF3E5; }
.ord-st.st-취소     { color: var(--tx-3); background: var(--bg); }

.chk-items { border-top: 1px dashed var(--line); padding-top: 10px; }
.chk-items p { font-size: 13.5px; color: var(--tx-2); }
.chk-total { font-size: 17px; font-weight: 700; margin-top: 8px; }
.chk-total span { font-size: 12.5px; font-weight: 500; color: var(--tx-2); margin-left: 6px; }
.chk-buyer {
  margin-top: 11px; padding: 11px 12px; background: var(--bg); border-radius: 8px;
  font-size: 13.5px; line-height: 1.65;
}
.chk-buyer a { color: var(--sea); font-weight: 600; text-decoration: underline; }
.chk-memo { color: var(--red); font-size: 12.5px; }
.chk-acts { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 12px; }
.chk-btn {
  padding: 9px 13px; border: 1px solid var(--line); border-radius: 7px;
  font-size: 12.5px; font-weight: 600; color: var(--tx-2); background: var(--w);
  min-height: 38px;
}
.chk-btn.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.chk-btn.copy { margin-left: auto; color: var(--sea); }

/* 구매바 버튼 2개 */
.buybar-btns { margin-left: auto; display: flex; gap: 8px; flex: none; }
.buybar-btns .btn { margin-left: 0; padding: 13px 16px; font-size: 14px; }

/* 사장님 화면 — 내려받기 줄 */
.exp-row { display: flex; gap: 7px; padding: 0 16px 12px; flex-wrap: wrap; }
.exp-row .chk-btn { background: var(--w); }

/* 후기 */
.rv-list { padding: 0 16px; display: flex; flex-direction: column; gap: 12px; }
.rv { border: 1px solid var(--line); border-radius: var(--r); padding: 14px 15px; }
.rv-hd { display: flex; align-items: baseline; gap: 8px; }
.rv-star { color: #F0A24B; font-size: 14px; letter-spacing: 1px; }
.rv-hd span { font-size: 13px; font-weight: 600; }
.rv-hd i { font-style: normal; margin-left: auto; font-size: 11.5px; color: var(--tx-3); }
.rv p { font-size: 14px; color: var(--tx-2); margin-top: 7px; line-height: 1.65; }

/* 관리자 */
.adm-tabs { display: flex; gap: 7px; padding: 4px 16px 14px; }
.adm-tabs button {
  flex: 1; padding: 11px 0; border: 1px solid var(--line); border-radius: 9px;
  font-size: 14px; font-weight: 600; color: var(--tx-2); background: var(--w);
}
.adm-tabs button.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.adm-card {
  border: 1px solid var(--line); border-radius: var(--r);
  padding: 15px; margin: 0 16px 13px; background: var(--w);
}
.adm-card .fl { margin-bottom: 10px; }
.adm-row { display: flex; gap: 8px; }
.adm-row .fl { flex: 1; }
.adm-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.adm-grid input { width: 100%; padding: 9px 6px; border: 1px solid var(--line);
  border-radius: 7px; font-size: 13px; text-align: right; }
.adm-grid .gh { font-size: 11px; color: var(--tx-3); align-self: center; text-align: center; }
.adm-top { display: flex; align-items: center; gap: 9px; margin-bottom: 11px; }
.adm-top b { font-size: 15px; }
.adm-top .chk-btn { margin-left: auto; }
.adm-note { font-size: 12.5px; color: var(--tx-3); padding: 0 16px 12px; line-height: 1.7; }
.adm-save { position: sticky; bottom: calc(var(--tabh) + 8px); padding: 10px 16px; z-index: 5; }
.tgl { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--tx-2); }
.tgl input { width: 18px; height: 18px; accent-color: var(--ink); }

/* 후기 사진·실구매·작성 */
.rv-ph { display: flex; gap: 7px; margin-top: 9px; flex-wrap: wrap; }
.rv-ph img { width: 74px; height: 74px; object-fit: cover; border-radius: 8px;
  border: 1px solid var(--line); cursor: pointer; }
.rv-buy { font-style: normal; font-size: 10.5px; font-weight: 700; color: var(--sea);
  background: #E6F3F5; padding: 2px 6px; border-radius: 4px; margin-left: 4px; }
.rv-none { font-size: 14px; color: var(--tx-3); padding: 6px 0 2px; }
.shelf-hd a[data-rv-write] { color: var(--red); font-weight: 700; }
.rv-form { border: 1.5px solid var(--line); border-radius: var(--r);
  padding: 16px 15px; margin-bottom: 16px; background: #FBFCFB; }
.star-in { display: flex; gap: 4px; margin-bottom: 6px; }
.star-in button { font-size: 30px; color: #D8DEDC; line-height: 1; padding: 2px; }
.star-in button.on { color: #F0A24B; }

/* 회원 카드 */
.mem-card { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.mem-card > div:first-child b { font-size: 17px; }
.mem-card > div:first-child span { display: block; font-size: 12.5px; color: var(--tx-2); }
.mem-pts { background: var(--bg); border-radius: 10px; padding: 10px 16px; }
.mem-pts i { font-style: normal; display: block; font-size: 11px; color: var(--tx-3); }
.mem-pts b { font-size: 19px; color: var(--sea); }
.mem-card .chk-btn { margin-left: auto; }

/* 주소 검색 */
.addr-row { display: flex; gap: 8px; margin-top: 7px; }
.addr-row .fi { flex: 1; margin-top: 0; background: var(--bg); }
.addr-row .btn { flex: none; padding: 0 15px; min-height: 48px; font-size: 14px; }

/* 옵션 선택 (세로, 가격 병기) */
.chips-col { flex-direction: column; }
.chip-opt { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; }
.chip-opt b { font-weight: 600; }
.chip-opt .chip-p { margin-left: auto; font-weight: 700; color: var(--red); }
.chip-opt .chip-p s { color: var(--tx-3); font-weight: 400; font-size: 12px; margin-left: 4px; }
.chip-opt.on .chip-p, .chip-opt.on .chip-p s { color: #fff; }

/* 관리자 옵션 줄 */
.opt-line { align-items: flex-end; }
.opt-line .fl { margin-bottom: 8px; }
.opt-line .chk-btn { margin-bottom: 10px; }

/* 소셜 로그인 */
.btn-kakao { background: #FEE500; color: #191919; }
.btn-kakao b { font-weight: 800; }
.btn-kakao:active { background: #F4DC00; }
.btn-google { background: #fff; color: var(--tx); border: 1.5px solid var(--line); }
.sso-or {
  text-align: center; font-size: 12px; color: var(--tx-3);
  margin: 14px 0 12px; position: relative;
}
.sso-or::before, .sso-or::after {
  content: ""; position: absolute; top: 50%; width: 26%;
  border-top: 1px solid var(--line);
}
.sso-or::before { left: 0; }
.sso-or::after { right: 0; }

/* 토스트 링크 */
.toast-go { color: #FFC7BF; font-size: 12.5px; font-weight: 700; white-space: nowrap; margin-left: 4px; }

/* 옵션 바닥 시트 */
.sheet-bg { position: fixed; inset: 0; background: rgba(10,20,19,.52); z-index: 90;
  opacity: 0; transition: opacity .22s ease; }
.sheet-bg.on { opacity: 1; }
.sheet {
  position: fixed; left: 50%; bottom: 0; transform: translate(-50%, 105%);
  width: 100%; max-width: var(--app); background: var(--w);
  border-radius: 18px 18px 0 0; z-index: 91;
  padding: 16px 16px calc(16px + env(safe-area-inset-bottom));
  max-height: 78vh; overflow-y: auto;
  transition: transform .28s cubic-bezier(.4,0,.2,1);
}
.sheet.on { transform: translate(-50%, 0); }
.sheet-hd { display: flex; align-items: center; margin-bottom: 4px; }
.sheet-hd b { font-size: 16px; }
.sheet-hd button { margin-left: auto; font-size: 26px; color: var(--tx-3); line-height: 1; padding: 2px 6px; }
.sheet .chips { margin-bottom: 2px; }
.sh-sub { font-style: normal; font-size: 10.5px; color: var(--tx-3); margin-left: 3px; }
.chip.on .sh-sub { color: rgba(255,255,255,.7); }
.sheet-qty { display: flex; align-items: center; gap: 12px; margin: 16px 0 14px; }
.sheet-qty > span { font-size: 13px; color: var(--tx-2); font-weight: 600; }
.sheet-tot { margin-left: auto; font-size: 20px; color: var(--red); }

/* 주문완료 상태 안내 */
.done-status {
  padding: 15px 18px; text-align: center; font-size: 15px; font-weight: 700;
  background: #E6F3F5; color: var(--sea);
}
.done-status.st-발송완료 { background: #EDF3E5; color: var(--land); }
.done-status.st-취소 { background: var(--bg); color: var(--tx-2); }

/* 관리자 — 실물 카드 편집 */
.pv-list { padding: 0 16px; display: flex; flex-direction: column; gap: 18px; }
.pv-card { border: 1px solid var(--line); border-radius: var(--r); background: var(--w); overflow: hidden; }
.pv-card.off { opacity: .55; }
.pv-photo { position: relative; aspect-ratio: 4 / 3; background: var(--bg); cursor: pointer; }
.pv-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pv-photo .p-badge { cursor: text; }
.pv-cam {
  position: absolute; right: 8px; bottom: 8px;
  background: rgba(0,0,0,.55); color: #fff; font-size: 12px; font-weight: 600;
  padding: 6px 10px; border-radius: 999px;
}
.pv-off {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%,-50%);
  background: rgba(0,0,0,.6); color: #fff; font-size: 13px; font-weight: 700;
  padding: 7px 14px; border-radius: 8px;
}
.pv-body { padding: 13px 14px 6px; }
.pv-name { display: block; font-size: 17px; font-weight: 700; line-height: 1.35; margin-top: 2px; }
.pv-sum { font-size: 13.5px; color: var(--tx-2); margin-top: 5px; }
.pv-ed { border-bottom: 1.5px dashed #C9DDE0; padding: 1px 2px; min-width: 30px; display: inline-block; }
.pv-ed:focus { outline: none; background: #FFFBE8; border-bottom-color: var(--red); }
p.pv-ed, .pv-name { display: block; }
.pv-price {
  display: flex; align-items: baseline; gap: 8px; margin-top: 10px;
  padding: 9px 0 12px; cursor: pointer;
}
.pv-price i { font-style: normal; margin-left: auto; font-size: 12px; color: var(--sea); font-weight: 600; }
.pv-edit { padding: 4px 14px 12px; border-top: 1px dashed var(--line); }
.pv-tools {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  border-top: 1px solid var(--line); padding: 10px 14px; background: #FAFBFA;
}
.pv-new {
  border: 2px dashed var(--line); background: none; text-align: center;
  padding: 26px 10px; font-size: 16px; font-weight: 700; color: var(--tx-2);
  cursor: pointer; border-radius: var(--r);
}
.pv-new span { display: block; font-size: 12px; font-weight: 400; color: var(--tx-3); margin-top: 5px; }
.pv-new:active { background: var(--bg); }

/* 사진 드래그 */
.pv-photo.drag { outline: 3px dashed var(--red); outline-offset: -3px; }
.pv-photo.drag::after { content: "여기에 놓으세요"; position: absolute; inset: 0; display: grid; place-items: center; background: rgba(214,64,49,.25); color: #fff; font-weight: 800; font-size: 16px; }
