/* ==========================================================================
   로스터리 37 — 커피 원두·구독 (DREXLY 템플릿)
   색·활자·컴포넌트는 00-디자인보드.png, 조판은 01·02·06 시안을 따른다.
   에스프레소(딥) 위에 라임 한 점 — 밝은 크림 지면에 계기판 같은 표를 얹는다.
   ========================================================================== */

:root {
  /* 색 — 디자인보드 COLOR */
  --espresso: #2b1f17;
  --cream: #f7f4ee;
  --lime: #c7f25a;
  --stone: #dad7d2;
  --graphite: #333333;

  --bg: var(--cream);
  --bg-deep: var(--espresso);
  --surface: #fffdf8;
  --surface-2: #f1ede4;
  --ink: #23180f;
  --ink-2: #5f564c;
  --ink-3: #8b8177;
  --line: rgba(43, 31, 23, 0.14);
  --line-soft: rgba(43, 31, 23, 0.08);
  --line-dark: rgba(247, 244, 238, 0.16);
  --lime-deep: #a8d63a;
  --lime-wash: rgba(199, 242, 90, 0.22);

  /* 의미색 — 색만으로 상태를 전달하지 않는다(아이콘·글자 병기) */
  --ok: #2f6b3a;
  --ok-bg: rgba(47, 107, 58, 0.1);
  --warn: #96601a;
  --warn-bg: rgba(150, 96, 26, 0.12);
  --err: #a3372a;
  --err-bg: rgba(163, 55, 42, 0.1);

  /* 활자 — 디자인보드 TYPOGRAPHY: Pretendard Variable 한 벌 */
  --sans: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont,
    system-ui, "Apple SD Gothic Neo", "Noto Sans KR", "Malgun Gothic", sans-serif;

  /* 조판 */
  --wrap: 1200px;
  --gutter: 40px;
  --section: 116px;
  --r-sm: 6px;
  --r: 12px;
  --r-lg: 18px;
  --shadow: 0 1px 2px rgba(43, 31, 23, 0.05), 0 14px 34px rgba(43, 31, 23, 0.07);
  --ease: cubic-bezier(0.22, 0.72, 0.28, 1);
  --z-header: 60;
  --z-scrim: 80;
  --z-panel: 90;
  --z-toast: 120;
}

/* --------------------------------------------------------------- 기본 */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 92px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.72;
  letter-spacing: -0.012em;
  word-break: keep-all;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
  font-variant-numeric: tabular-nums;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; line-height: 1.28; letter-spacing: -0.03em; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

:focus-visible { outline: 2px solid var(--espresso); outline-offset: 3px; border-radius: 3px; }
.on-dark :focus-visible, .site-footer :focus-visible { outline-color: var(--lime); }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: var(--espresso); color: var(--cream); padding: 12px 20px; font-size: 14px;
}
.skip:focus { left: 0; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.frame { display: block; overflow: hidden; background: var(--surface-2); }

.ico {
  width: 22px; height: 22px; flex: none; fill: none; stroke: currentColor;
  stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round;
}
.ico-sm { width: 16px; height: 16px; stroke-width: 1.6; }
.ico-lg { width: 28px; height: 28px; stroke-width: 1.2; }

/* --------------------------------------------------------- 활자 계층 */
.display {
  font-size: clamp(38px, 5.6vw, 74px);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.045em;
}
.label {
  display: inline-block;
  font-size: 11px; font-weight: 700; line-height: 1.6;
  letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-3);
}
.on-dark .label { color: var(--lime); }
.sec-title {
  font-size: clamp(25px, 2.7vw, 36px);
  font-weight: 700; line-height: 1.32; letter-spacing: -0.038em;
}
.lead { color: var(--ink-2); font-size: 17px; line-height: 1.8; }
.small { font-size: 13.5px; color: var(--ink-2); line-height: 1.7; }
.tiny { font-size: 12.5px; color: var(--ink-3); line-height: 1.65; }
.num { font-feature-settings: "tnum" 1; letter-spacing: -0.01em; }

.section { padding-block: calc(var(--section) / 2); }
.section-first { padding-top: calc(var(--section) * 0.62); }
.section-last { padding-bottom: var(--section); }
.section-tint { background: var(--surface-2); }
.section-dark { background: var(--espresso); color: var(--cream); }
.section-dark .lead, .section-dark .small { color: rgba(247, 244, 238, 0.72); }
.section-dark .tiny { color: rgba(247, 244, 238, 0.55); }

/* 밝은 지면 위에 놓인 어두운 카드 — 글자색을 뒤집어 준다 */
.roastcard, .detail, .summary, .curvewrap { --ink: var(--cream); }
.roastcard .label, .detail .label, .summary .label, .curvewrap .label { color: var(--lime); }
.roastcard .lead, .detail .lead, .summary .lead,
.roastcard .small, .detail .small, .summary .small { color: rgba(247, 244, 238, 0.72); }
.roastcard .tiny, .detail .tiny, .summary .tiny, .curvewrap .tiny { color: rgba(247, 244, 238, 0.55); }
.detail .chip { background: rgba(247, 244, 238, 0.08); border-color: var(--line-dark); color: var(--cream); }
.detail .chip-ok { color: #cbe8b6; border-color: rgba(199, 242, 90, 0.4); }
.detail .chip-warn { color: #f0cf94; border-color: rgba(240, 207, 148, 0.4); }
.detail .chip-err { color: #f0b3a8; border-color: rgba(240, 179, 168, 0.4); }

.sec-head { margin-bottom: 44px; max-width: 760px; }
.sec-head .label { margin-bottom: 14px; }
.sec-head p { margin-top: 14px; color: var(--ink-2); }
.sec-head.row {
  max-width: none; display: flex; align-items: flex-end;
  justify-content: space-between; gap: 24px; flex-wrap: wrap;
}

/* --------------------------------------------------------------- 버튼 */
.btn {
  --btn-bg: transparent; --btn-fg: var(--ink); --btn-bd: var(--line);
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  min-height: 50px; padding: 0 24px;
  border: 1px solid var(--btn-bd); border-radius: 999px;
  background: var(--btn-bg); color: var(--btn-fg);
  font-size: 15px; font-weight: 600; letter-spacing: -0.02em; cursor: pointer;
  transition: background 0.24s var(--ease), color 0.24s var(--ease),
    border-color 0.24s var(--ease), transform 0.14s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.45; pointer-events: none; }
.btn .arw { transition: transform 0.24s var(--ease); }
.btn:hover .arw { transform: translateX(3px); }

.btn-lime { --btn-bg: var(--lime); --btn-fg: #22301a; --btn-bd: var(--lime); }
.btn-lime:hover { --btn-bg: var(--lime-deep); --btn-bd: var(--lime-deep); }
.btn-dark { --btn-bg: var(--espresso); --btn-fg: var(--cream); --btn-bd: var(--espresso); }
.btn-dark:hover { --btn-bg: #3d2c20; --btn-bd: #3d2c20; }
.btn-line { --btn-bg: var(--surface); --btn-fg: var(--ink); --btn-bd: var(--line); }
.btn-line:hover { --btn-bd: var(--ink); }
.btn-onDark { --btn-bg: transparent; --btn-fg: var(--cream); --btn-bd: var(--line-dark); }
.btn-onDark:hover { --btn-bg: rgba(247, 244, 238, 0.1); --btn-bd: rgba(247, 244, 238, 0.4); }
.btn-sm { min-height: 44px; padding: 0 18px; font-size: 14px; }
.btn-block { width: 100%; }

.btn-text {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 32px;
  font-size: 14px; font-weight: 600; color: var(--ink);
  border-bottom: 1px solid var(--line); padding-bottom: 2px;
  transition: border-color 0.24s var(--ease), gap 0.24s var(--ease), color 0.24s var(--ease);
}
.btn-text:hover { border-bottom-color: var(--ink); gap: 12px; }
.on-dark .btn-text { color: var(--cream); border-bottom-color: var(--line-dark); }
.on-dark .btn-text:hover { border-bottom-color: var(--lime); color: var(--lime); }

/* --------------------------------------------------------------- 배지 */
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 11px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface);
  font-size: 12px; font-weight: 600; color: var(--ink-2); letter-spacing: -0.01em;
}
.chip-lime { background: var(--lime-wash); border-color: rgba(168, 214, 58, 0.5); color: #40521a; }
.chip-ok { background: var(--ok-bg); border-color: rgba(47, 107, 58, 0.28); color: var(--ok); }
.chip-warn { background: var(--warn-bg); border-color: rgba(150, 96, 26, 0.3); color: var(--warn); }
.chip-err { background: var(--err-bg); border-color: rgba(163, 55, 42, 0.28); color: var(--err); }

/* --------------------------------------------------------------- 헤더 */
.site-header {
  position: sticky; top: 0; z-index: var(--z-header);
  background: rgba(247, 244, 238, 0.88);
  border-bottom: 1px solid var(--line-soft);
  transition: box-shadow 0.3s var(--ease), background 0.3s var(--ease);
}
.site-header.is-stuck {
  background: rgba(247, 244, 238, 0.96);
  -webkit-backdrop-filter: saturate(1.15) blur(10px);
  backdrop-filter: saturate(1.15) blur(10px);
  box-shadow: 0 1px 18px rgba(43, 31, 23, 0.07);
}
.nav { display: flex; align-items: center; gap: 26px; height: 78px; }
.brand { display: block; flex: none; letter-spacing: -0.04em; }
.brand b { display: block; font-size: 21px; font-weight: 700; line-height: 1.1; }
.brand small {
  display: block; font-size: 9.5px; font-weight: 600; letter-spacing: 0.18em;
  color: var(--ink-3); margin-top: 3px;
}
.navlinks { display: flex; align-items: center; gap: 30px; margin-left: 18px; }
.navlinks a {
  position: relative; font-size: 14.5px; font-weight: 500; color: var(--ink-2); padding: 8px 0;
  transition: color 0.24s var(--ease);
}
.navlinks a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px;
  background: var(--lime-deep); transform: scaleX(0); transform-origin: left;
  transition: transform 0.3s var(--ease);
}
.navlinks a:hover { color: var(--ink); }
.navlinks a:hover::after, .navlinks a[aria-current="page"]::after { transform: scaleX(1); }
.navlinks a[aria-current="page"] { color: var(--ink); font-weight: 600; }

.nav-actions { display: flex; align-items: center; gap: 6px; margin-left: auto; flex: none; }
.icon-btn {
  width: 44px; height: 44px; display: inline-grid; place-items: center;
  background: none; border: 1px solid transparent; border-radius: 999px; cursor: pointer;
  color: var(--ink); position: relative;
  transition: background 0.24s var(--ease), border-color 0.24s var(--ease);
}
.icon-btn:hover { background: rgba(43, 31, 23, 0.06); }
.cart-count {
  position: absolute; top: 4px; right: 3px; min-width: 18px; height: 18px; padding: 0 5px;
  display: grid; place-items: center; border-radius: 999px;
  background: var(--lime); color: #22301a; font-size: 10.5px; font-weight: 700; line-height: 1;
}
.cart-count[hidden] { display: none; }
.nav-cta { margin-left: 8px; }
.menu-btn { display: none; }

/* 모바일 서랍 */
.drawer {
  position: fixed; inset: 0 0 0 auto; width: min(348px, 88vw); z-index: var(--z-panel);
  background: var(--surface); border-left: 1px solid var(--line);
  padding: 20px 24px 36px; transform: translateX(100%);
  transition: transform 0.36s var(--ease);
  overflow-y: auto; display: flex; flex-direction: column;
}
.drawer.open { transform: none; }
.drawer-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.drawer nav { display: flex; flex-direction: column; }
.drawer nav a {
  font-size: 18px; font-weight: 600; letter-spacing: -0.03em;
  padding: 15px 0; min-height: 52px; display: flex; align-items: center;
  border-bottom: 1px solid var(--line-soft);
}
.drawer nav a[aria-current="page"] { color: var(--ink); }
.drawer nav a[aria-current="page"]::before {
  content: ""; width: 7px; height: 7px; border-radius: 50%;
  background: var(--lime-deep); margin-right: 9px;
}
.drawer-foot { margin-top: 24px; display: grid; gap: 10px; }
.drawer-foot .btn { justify-content: flex-start; }
.icon-btn.drawer-close { border-color: var(--line); }
.scrim {
  position: fixed; inset: 0; z-index: var(--z-scrim); background: rgba(35, 24, 15, 0.45);
  opacity: 0; visibility: hidden; transition: opacity 0.36s var(--ease), visibility 0.36s;
}
.scrim.open { opacity: 1; visibility: visible; }

/* ---------------------------------------------------- 히어로 (홈) §01 */
.hero { position: relative; background: var(--espresso); color: var(--cream); overflow: hidden; }
.hero-grid {
  position: relative; z-index: 2;
  display: grid; grid-template-columns: minmax(0, 1fr) 210px;
  gap: 40px; align-items: center;
  min-height: 560px; padding-block: 72px;
}
.hero-copy { max-width: 620px; }
.hero h1 { color: var(--cream); margin: 18px 0 22px; }
.hero h1 em { font-style: normal; color: var(--lime); }
.hero-lead { color: rgba(247, 244, 238, 0.76); font-size: 17px; max-width: 27em; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 34px; }
.hero-media {
  position: absolute; inset: 0 0 0 auto; width: 52%; z-index: 1;
}
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-media::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, var(--espresso) 4%, rgba(43, 31, 23, 0.72) 42%, rgba(43, 31, 23, 0.28) 100%);
}
.hero-rail { position: relative; z-index: 3; display: grid; gap: 4px; }
.hero-rail li {
  display: grid; grid-template-columns: 34px minmax(0, 1fr); align-items: baseline;
  gap: 10px; padding: 12px 0; border-top: 1px solid var(--line-dark);
  color: rgba(247, 244, 238, 0.45); font-size: 13.5px; letter-spacing: -0.02em;
}
.hero-rail li b { font-size: 12.5px; font-weight: 700; letter-spacing: 0.06em; }
.hero-rail li.on { color: var(--cream); }
.hero-rail li.on b { color: var(--lime); }

/* 내부 페이지 머리 */
.page-head { background: var(--espresso); color: var(--cream); padding-block: 66px 58px; }
.page-head h1 { color: var(--cream); font-size: clamp(30px, 4vw, 50px); letter-spacing: -0.042em; margin: 14px 0 16px; }
.page-head p { color: rgba(247, 244, 238, 0.74); max-width: 44em; }
.crumb { display: flex; gap: 8px; align-items: center; color: rgba(247, 244, 238, 0.5); font-size: 12.5px; }
.crumb a:hover { color: var(--lime); }

/* ------------------------------------------------- 홈 · 세 갈래 §02 */
.paths { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; }
.path {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px; align-items: start;
  padding: 34px 30px 30px; border-left: 1px solid var(--line);
}
.paths .path:last-child { border-right: 1px solid var(--line); }
.path h3 { font-size: 19px; margin: 10px 0 8px; letter-spacing: -0.035em; }
.path p { font-size: 13.5px; color: var(--ink-2); margin-bottom: 16px; }
.path-fig { width: 96px; flex: none; }
.path-fig img { border-radius: var(--r-sm); }
.minimap { width: 96px; height: 84px; }
.minimap line { stroke: var(--stone); stroke-width: 1; }
.minimap circle { fill: var(--ink-3); }
.minimap circle.hi { fill: var(--lime-deep); }

/* ------------------------------------------- 홈 · 추천 원두 카드 §03 */
.pick-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.pick {
  display: flex; flex-direction: column; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--r); padding: 18px 18px 20px;
}
.pick-fig {
  display: block; background: var(--surface-2); border-radius: var(--r-sm);
  padding: 14px 0; margin-bottom: 16px; text-align: center;
}
.pick-fig img { margin: 0 auto; width: 126px; height: auto; }
.pick-org { font-size: 12px; font-weight: 600; color: var(--ink-3); letter-spacing: 0.02em; }
.pick h3 { font-size: 16.5px; margin: 5px 0 8px; letter-spacing: -0.035em; }
.pick-note { font-size: 13px; color: var(--ink-2); min-height: 2.9em; }
.pick-meter { display: grid; gap: 6px; margin: 14px 0 16px; }
.meter-row { display: grid; grid-template-columns: 46px minmax(0, 1fr); align-items: center; gap: 8px; }
.meter-row span { font-size: 11.5px; color: var(--ink-3); font-weight: 600; }
.dots { display: flex; gap: 4px; }
.dots i { width: 9px; height: 9px; border-radius: 50%; background: var(--stone); display: block; }
.dots i.on { background: var(--lime-deep); }
.pick-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.price { font-size: 17px; font-weight: 700; letter-spacing: -0.03em; }
.price small { font-size: 11.5px; font-weight: 500; color: var(--ink-3); margin-left: 4px; }

/* --------------------------------------------------- 홈 · 신선도 §04 */
.fresh-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 56px; align-items: start; }
.fresh-list { display: grid; gap: 2px; }
.fresh-list li {
  display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 12px;
  padding: 16px 0; border-top: 1px solid var(--line);
}
.fresh-list li:last-child { border-bottom: 1px solid var(--line); }
.fresh-list b { display: block; font-size: 15px; letter-spacing: -0.03em; }
.fresh-list p { font-size: 13.5px; color: var(--ink-2); margin-top: 3px; }
.fresh-list .ico { color: var(--ink-3); margin-top: 3px; }
.roastcard {
  background: var(--espresso); color: var(--cream); border-radius: var(--r-lg);
  padding: 30px 30px 26px;
}
.roastcard h3 { font-size: 18px; color: var(--cream); margin-bottom: 6px; }
.roast-next {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px;
  margin: 22px 0 18px;
}
.roast-next div { border: 1px solid var(--line-dark); border-radius: var(--r); padding: 14px 16px; }
.roast-next dt { font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--lime); font-weight: 700; }
.roast-next dd { margin: 6px 0 0; font-size: 19px; font-weight: 700; letter-spacing: -0.03em; }

/* ------------------------------------------- 구독 4단계 (디자인보드) */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; }
.steps li { position: relative; padding: 0 26px 0 0; }
.steps li + li { padding-left: 26px; }
.steps li + li::before {
  content: ""; position: absolute; left: 0; top: 26px; bottom: 8px; width: 1px; background: var(--line-dark);
}
.step-ico {
  width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center;
  border: 1px solid var(--line-dark); color: var(--lime); margin-bottom: 18px;
}
.steps b { display: block; font-size: 11px; letter-spacing: 0.18em; color: var(--lime); font-weight: 700; }
.steps h3 { font-size: 18px; color: var(--cream); margin: 8px 0 8px; }
.steps p { font-size: 13.5px; color: rgba(247, 244, 238, 0.66); }

/* --------------------------------------------------------- CTA 밴드 */
.cta-band {
  display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap;
  background: var(--lime); border-radius: var(--r-lg); padding: 38px 44px; color: #22301a;
}
.cta-band h2 { font-size: clamp(22px, 2.4vw, 30px); letter-spacing: -0.04em; }
.cta-band p { font-size: 14.5px; margin-top: 8px; color: #3c4a25; }
.cta-band .btn-dark { --btn-bd: #22301a; --btn-bg: #22301a; }

/* ============================================ PAGE 02 — 원두 지도 */
.map-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 40px; align-items: start; }

.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; align-items: center; }
.filters .flabel { font-size: 12px; font-weight: 700; letter-spacing: 0.1em; color: var(--ink-3); margin-right: 4px; }
.fchip {
  min-height: 44px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface); cursor: pointer;
  font-size: 13.5px; font-weight: 600; color: var(--ink-2); letter-spacing: -0.02em;
  display: inline-flex; align-items: center; gap: 7px;
  transition: background 0.2s var(--ease), border-color 0.2s var(--ease), color 0.2s var(--ease);
}
.fchip:hover { border-color: var(--ink-3); }
.fchip[aria-pressed="true"] { background: var(--espresso); border-color: var(--espresso); color: var(--cream); }
.fchip[aria-pressed="true"]::before { content: "✓"; font-size: 12px; color: var(--lime); }

.mapbox {
  position: relative; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); padding: 46px 52px;
}
.plot { position: relative; width: 100%; aspect-ratio: 1 / 1; }
.plot-axis { position: absolute; inset: 0; width: 100%; height: 100%; }
.plot-axis line { stroke: var(--stone); }
.plot-axis line.grid { stroke: rgba(43, 31, 23, 0.07); }
.axis-tag {
  position: absolute; font-size: 11.5px; font-weight: 700; letter-spacing: 0.08em; color: var(--ink-3);
  background: var(--surface); padding: 2px 6px;
}
.axis-tag.t { top: -34px; left: 50%; transform: translateX(-50%); }
.axis-tag.b { bottom: -34px; left: 50%; transform: translateX(-50%); }
/* 세 글자짜리 축 이름이 「가벼 / 움」으로 쪼개지지 않게 각 줄을 통째로 둔다 */
.axis-tag.l, .axis-tag.r {
  top: 50%; transform: translateY(-50%); width: 54px;
  text-align: center; line-height: 1.4; white-space: nowrap; padding: 2px 0;
}
.axis-tag.l { left: -50px; }
.axis-tag.r { right: -50px; }
.plot-scale {
  display: none; gap: 8px 18px; flex-wrap: wrap; justify-content: space-between;
  margin-top: 18px; font-size: 12px; font-weight: 600; color: var(--ink-3);
}

.dot {
  position: absolute; width: 44px; height: 44px; margin: -22px 0 0 -22px;
  display: grid; place-items: center; border-radius: 50%; cursor: pointer;
}
.dot i {
  width: 15px; height: 15px; border-radius: 50%; background: var(--ink-2);
  border: 2px solid var(--surface); display: block;
  transition: transform 0.2s var(--ease), background 0.2s var(--ease);
  box-shadow: 0 0 0 1px rgba(43, 31, 23, 0.18);
}
.dot em {
  position: absolute; top: 34px; left: 50%; transform: translateX(-50%);
  font-style: normal; font-size: 11px; font-weight: 600; letter-spacing: -0.02em;
  color: var(--ink-2); white-space: nowrap; background: rgba(255, 253, 248, 0.86);
  padding: 1px 5px; border-radius: 4px; pointer-events: none;
}
.dot:hover i, .dot:focus-visible i { transform: scale(1.34); }
.dot[aria-current="true"] i { background: var(--lime-deep); transform: scale(1.5); }
.dot[aria-current="true"] em { color: var(--ink); font-weight: 700; }
.dot.dim { opacity: 0.22; pointer-events: none; }
.dot.dim em { display: none; }

.map-empty {
  margin-top: 18px; padding: 16px 18px; border: 1px dashed var(--line);
  border-radius: var(--r); font-size: 13.5px; color: var(--ink-2);
  display: flex; gap: 10px; align-items: center;
}
.map-empty[hidden] { display: none; }

.detail {
  position: sticky; top: 100px;
  background: var(--espresso); color: var(--cream); border-radius: var(--r-lg); padding: 26px 26px 24px;
}
.detail-top { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 16px; align-items: center; }
.detail-fig { background: rgba(247, 244, 238, 0.07); border-radius: var(--r-sm); padding: 8px 0; text-align: center; }
.detail-fig img { margin: 0 auto; width: 74px; height: auto; }
.detail h2, .detail h3 { color: var(--cream); font-size: 20px; letter-spacing: -0.035em; margin: 6px 0 4px; }
.detail-org { font-size: 12px; color: var(--lime); font-weight: 700; letter-spacing: 0.04em; }
.detail dl {
  margin: 20px 0 0; display: grid; grid-template-columns: 76px minmax(0, 1fr);
  gap: 0; font-size: 13.5px;
}
.detail dt { color: rgba(247, 244, 238, 0.55); padding: 9px 0; border-top: 1px solid var(--line-dark); }
.detail dd { margin: 0; padding: 9px 0; border-top: 1px solid var(--line-dark); color: var(--cream); }
.detail-foot { margin-top: 20px; display: grid; gap: 10px; }
.detail-price { display: flex; align-items: baseline; justify-content: space-between; }
.detail-price b { font-size: 22px; letter-spacing: -0.035em; }
.detail-price span { font-size: 12px; color: rgba(247, 244, 238, 0.6); }

/* 표 */
.tablewrap {
  /* position:relative 가 없으면 넘친 표가 문서 가로폭을 밀어 올린다(320·390px 사고) */
  position: relative; overflow-x: auto; -webkit-overflow-scrolling: touch;
  border: 1px solid var(--line); border-radius: var(--r); background: var(--surface);
}
table.data { width: 100%; min-width: 780px; border-collapse: collapse; font-size: 13.5px; }
table.data caption { text-align: left; padding: 16px 18px 0; font-size: 13px; color: var(--ink-2); }
table.data th, table.data td { padding: 13px 14px; text-align: left; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
table.data thead th {
  font-size: 11.5px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--ink-3); font-weight: 700; white-space: nowrap;
}
table.data tbody tr:last-child td { border-bottom: 0; }
table.data tbody tr.dim { display: none; }
table.data .nm { font-weight: 600; font-size: 14px; letter-spacing: -0.03em; }
table.data .nm small { display: block; font-size: 11.5px; color: var(--ink-3); font-weight: 500; letter-spacing: 0; }
table.data td.right { text-align: right; white-space: nowrap; }
table.data tr.picked { background: var(--lime-wash); }
table.data tr.hi td { background: rgba(43, 31, 23, 0.05); box-shadow: inset 3px 0 0 var(--lime-deep); }
.stepper { padding: 14px 22px 0; }

.pickbox { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; cursor: pointer; font-size: 13px; font-weight: 600; }
.pickbox input { position: absolute; opacity: 0; width: 0; height: 0; }
.pickbox .box {
  width: 20px; height: 20px; flex: none; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: 5px; background: var(--surface); color: transparent;
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease), color 0.18s var(--ease);
}
.pickbox input:checked + .box { background: var(--espresso); border-color: var(--espresso); color: var(--lime); }
.pickbox input:focus-visible + .box { outline: 2px solid var(--espresso); outline-offset: 2px; }

/* 비교 */
.cmp-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.cmp-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.cmp-col { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; }
.cmp-fig { background: var(--surface-2); border-radius: var(--r-sm); padding: 12px 0; text-align: center; margin-bottom: 14px; }
.cmp-fig img { margin: 0 auto; width: 104px; height: auto; }
.cmp-col h3 { font-size: 16px; letter-spacing: -0.035em; }
.cmp-col .cmp-org { font-size: 12px; color: var(--ink-3); font-weight: 600; margin-bottom: 14px; }
.cmp-rows { display: grid; gap: 7px; margin-bottom: 14px; }
.cmp-spec { display: grid; gap: 0; font-size: 12.5px; margin-bottom: 16px; }
.cmp-spec div { display: grid; grid-template-columns: 62px minmax(0, 1fr); gap: 8px; padding: 7px 0; border-top: 1px solid var(--line-soft); }
.cmp-spec dt { color: var(--ink-3); }
.cmp-spec dd { margin: 0; }
.cmp-col .price { display: block; margin-bottom: 12px; }
.cmp-empty {
  border: 1px dashed var(--line); border-radius: var(--r); padding: 30px 20px; text-align: center;
  color: var(--ink-3); font-size: 13.5px; display: grid; place-items: center; gap: 8px; min-height: 260px;
}

/* ============================================ PAGE 03 — 취향 가이드 */
.quiz { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 38px 40px 32px; }
.quiz-bar { display: flex; align-items: center; gap: 14px; margin-bottom: 30px; }
.quiz-track { position: relative; flex: 1; height: 5px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.quiz-fill { position: absolute; inset: 0 auto 0 0; width: 25%; background: var(--lime-deep); border-radius: 999px; transition: width 0.32s var(--ease); }
.quiz-count { font-size: 12.5px; font-weight: 700; color: var(--ink-2); letter-spacing: 0.02em; }
.quiz h2 { font-size: clamp(20px, 2.2vw, 27px); letter-spacing: -0.038em; text-align: center; margin-bottom: 8px; }
.quiz .qsub { text-align: center; font-size: 13.5px; color: var(--ink-2); margin-bottom: 30px; }

.opts { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; }
.opt { position: relative; }
.opt input { position: absolute; opacity: 0; width: 0; height: 0; }
.opt label {
  display: grid; justify-items: center; gap: 10px; cursor: pointer;
  width: 122px; padding: 12px 6px 14px; border-radius: var(--r); border: 1px solid transparent;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
}
.opt .ring {
  width: 84px; height: 84px; border-radius: 50%; overflow: hidden; display: block;
  border: 3px solid transparent; box-shadow: 0 0 0 1px var(--line);
  transition: border-color 0.2s var(--ease), transform 0.2s var(--ease);
}
.opt .ring img { width: 100%; height: 100%; object-fit: cover; }
.opt .cap { font-size: 14px; font-weight: 600; letter-spacing: -0.03em; text-align: center; }
.opt .sub { font-size: 11.5px; color: var(--ink-3); text-align: center; margin-top: -6px; }
.opt label:hover .ring { transform: translateY(-2px); }
.opt input:checked + label .ring { border-color: var(--lime-deep); box-shadow: 0 0 0 1px var(--lime-deep); }
.opt input:checked + label { background: var(--surface-2); }
.opt input:checked + label .cap::after { content: " ✓"; color: var(--ok); }
.opt input:focus-visible + label { border-color: var(--espresso); }

.opts.text .opt label { width: 190px; padding: 16px 18px; border: 1px solid var(--line); justify-items: start; gap: 4px; min-height: 76px; }
.opts.text .opt input:checked + label { border-color: var(--espresso); background: var(--surface-2); }
.opts.text .cap { text-align: left; }
.opts.text .sub { text-align: left; margin-top: 0; }

.quiz-nav { display: flex; justify-content: space-between; gap: 12px; margin-top: 34px; padding-top: 22px; border-top: 1px solid var(--line-soft); }
.quiz-step[hidden] { display: none; }
/* 무JS 완성본: 스크립트가 없으면 네 문항을 한 화면에 펼치고 이동 단추는 감춘다 */
html:not(.js) .quiz-step[hidden] { display: block; }
html:not(.js) .quiz-step + .quiz-step { margin-top: 34px; padding-top: 30px; border-top: 1px solid var(--line-soft); }
html:not(.js) .quiz-nav, html:not(.js) .quiz-bar { display: none; }
.nojs-only { display: none; }
html:not(.js) .nojs-only { display: block; }

.result-head { display: flex; align-items: center; gap: 12px; margin-bottom: 22px; }
.result-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-bottom: 26px; }
.result-card { display: grid; grid-template-columns: 104px minmax(0, 1fr); gap: 18px; background: var(--surface-2); border-radius: var(--r); padding: 18px; align-items: center; }
.result-card img { width: 92px; height: auto; margin: 0 auto; }
.result-card h3 { font-size: 17px; letter-spacing: -0.035em; margin-bottom: 4px; }
.result-why { font-size: 13px; color: var(--ink-2); margin: 8px 0 12px; }

.recipe { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); overflow: hidden; }
.recipe div { padding: 22px 20px; border-left: 1px solid var(--line-soft); }
.recipe div:first-child { border-left: 0; }
.recipe .ico { color: var(--ink-3); margin-bottom: 12px; }
.recipe dt { font-size: 11.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-3); font-weight: 700; }
.recipe dd { margin: 5px 0 0; font-size: 21px; font-weight: 700; letter-spacing: -0.035em; }

.grind-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.grind { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; }
.grind h3 { font-size: 15.5px; letter-spacing: -0.035em; margin-bottom: 6px; }
.grind p { font-size: 13px; color: var(--ink-2); }
/* span 을 사진 액자로 쓸 때는 블록이어야 높이가 먹는다 */
.grind-swatch { display: block; height: 46px; border-radius: var(--r-sm); margin-bottom: 14px; background-color: #efe9de; }

/* ============================================ PAGE 04 — 정기구독 */
.build { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 40px; align-items: start; }
.build-form { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 32px 34px 30px; }
.fieldset { border: 0; padding: 0; margin: 0 0 26px; }
.fieldset legend { padding: 0; font-size: 11.5px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 14px; }
.field { display: grid; gap: 7px; margin-bottom: 14px; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.field label { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.field label .req { color: var(--err); margin-left: 2px; }
.control {
  width: 100%; min-height: 50px; padding: 13px 16px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--r-sm); font: inherit; font-size: 14.5px;
  color: var(--ink);
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.control::placeholder { color: var(--ink-3); }
.control:focus { outline: none; border-color: var(--espresso); box-shadow: 0 0 0 3px rgba(199, 242, 90, 0.4); }
.control:disabled { background: var(--surface-2); color: var(--ink-3); cursor: not-allowed; }
textarea.control { min-height: 92px; resize: vertical; line-height: 1.65; }
select.control {
  appearance: none; padding-right: 42px;
  background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%238b8177' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center;
}
.field.invalid .control { border-color: var(--err); box-shadow: 0 0 0 3px rgba(163, 55, 42, 0.12); }
.err { display: none; font-size: 12.5px; color: var(--err); }
.err::before { content: "⚠ "; }
.field.invalid .err { display: block; }
.hint { font-size: 12.5px; color: var(--ink-3); }

.segs { display: flex; gap: 8px; flex-wrap: wrap; }
.seg { position: relative; flex: 1 1 120px; }
.seg input { position: absolute; opacity: 0; width: 0; height: 0; }
.seg label {
  display: grid; gap: 2px; cursor: pointer; text-align: center;
  min-height: 62px; padding: 11px 10px; border: 1px solid var(--line); border-radius: var(--r-sm);
  background: var(--surface); transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
  align-content: center;
}
.seg label b { font-size: 14.5px; font-weight: 700; letter-spacing: -0.03em; }
.seg label span { font-size: 11.5px; color: var(--ink-3); }
.seg input:checked + label { border-color: var(--espresso); background: var(--espresso); color: var(--cream); }
.seg input:checked + label span { color: var(--lime); }
.seg input:focus-visible + label { outline: 2px solid var(--espresso); outline-offset: 2px; }

.agree { display: flex; align-items: flex-start; gap: 10px; margin: 6px 0 18px; }
.agree input { position: absolute; opacity: 0; width: 0; height: 0; }
.agree label { display: flex; align-items: center; gap: 10px; min-height: 44px; cursor: pointer; font-size: 13.5px; color: var(--ink-2); }
.agree .box {
  width: 20px; height: 20px; flex: none; display: grid; place-items: center;
  border: 1px solid var(--line); border-radius: 5px; background: var(--surface); color: transparent;
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease), color 0.18s var(--ease);
}
.agree input:checked + label .box { background: var(--espresso); border-color: var(--espresso); color: var(--lime); }
.agree input:focus-visible + label .box { outline: 2px solid var(--espresso); outline-offset: 2px; }
.agree.invalid .box { border-color: var(--err); }

.summary { position: sticky; top: 100px; background: var(--espresso); color: var(--cream); border-radius: var(--r-lg); padding: 28px 28px 26px; }
.summary h2 { color: var(--cream); font-size: 18px; margin-bottom: 4px; }
.sum-rows { margin: 20px 0 0; font-size: 13.5px; }
.sum-rows div { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line-dark); }
.sum-rows dt { color: rgba(247, 244, 238, 0.62); }
.sum-rows dd { margin: 0; font-weight: 600; }
.sum-total { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--lime); }
.sum-total span { font-size: 13.5px; color: rgba(247, 244, 238, 0.75); }
.sum-total b { font-size: 27px; font-weight: 700; letter-spacing: -0.04em; color: var(--lime); }
.sum-note { font-size: 12px; color: rgba(247, 244, 238, 0.55); margin-top: 10px; }

.tl { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.tl-item {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 20px;
}
.tl-item b { display: block; font-size: 11.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-3); font-weight: 700; }
.tl-date { font-size: 21px; font-weight: 700; letter-spacing: -0.035em; margin: 8px 0 2px; }
.tl-item .tl-sub { font-size: 12.5px; color: var(--ink-2); }
.tl-item .tl-amt { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line-soft); font-size: 14px; font-weight: 700; }
.tl-item.skip { background: var(--surface-2); }
.tl-item.skip .tl-date { color: var(--ink-3); text-decoration: line-through; }

/* 아코디언 */
.acc { border-top: 1px solid var(--line); }
.acc-item { border-bottom: 1px solid var(--line); }
.acc-trigger {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px;
  background: none; border: 0; cursor: pointer; text-align: left;
  padding: 20px 4px; min-height: 60px; font-size: 15.5px; font-weight: 600; letter-spacing: -0.03em;
}
.acc-trigger .ico { color: var(--ink-3); transition: transform 0.3s var(--ease); flex: none; }
.acc-item.open .acc-trigger .ico { transform: rotate(180deg); }
.acc-panel { display: none; padding: 0 4px 22px; font-size: 14px; color: var(--ink-2); line-height: 1.8; }
.acc-item.open .acc-panel { display: block; }
/* 무JS 완성본: 스크립트가 없으면 전부 펼쳐 둔다 */
html:not(.js) .acc-panel { display: block; }
html:not(.js) .acc-trigger .ico { display: none; }
.acc-panel ul { display: grid; gap: 6px; margin-top: 8px; }
.acc-panel li { padding-left: 14px; position: relative; }
.acc-panel li::before { content: ""; position: absolute; left: 0; top: 11px; width: 5px; height: 5px; border-radius: 50%; background: var(--stone); }

/* ============================================ PAGE 05 — 스토리 */
.story-top { display: grid; grid-template-columns: minmax(0, 1fr) 350px; gap: 48px; align-items: center; }
.story-top .frame { border-radius: var(--r-lg); }
.story-body p + p { margin-top: 16px; }

.curvewrap { background: var(--espresso); color: var(--cream); border-radius: var(--r-lg); padding: 36px 40px 30px; }
.curve { display: block; width: 100%; height: auto; }
.curve .axis { stroke: rgba(247, 244, 238, 0.22); stroke-width: 1; }
.curve .curve-path {
  fill: none; stroke: var(--lime); stroke-width: 2.5; stroke-linecap: round;
  stroke-dasharray: 1000; stroke-dashoffset: 1000;
}
.curve .curve-path.drawn { stroke-dashoffset: 0; transition: stroke-dashoffset 1.6s var(--ease); }
.curve .mark { fill: var(--cream); }
.curve text { fill: rgba(247, 244, 238, 0.62); font-size: 11px; font-family: var(--sans); font-weight: 600; }
.curve text.hi { fill: var(--lime); }
@supports (animation-timeline: view()) {
  html.js .curve .curve-path {
    animation: draw linear both;
    animation-timeline: view();
    animation-range: entry 18% cover 52%;
  }
  @keyframes draw { to { stroke-dashoffset: 0; } }
}
.curve-legend { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; margin-top: 26px; }
.curve-legend div { border-top: 1px solid var(--line-dark); padding-top: 14px; }
.curve-legend b { display: block; font-size: 11px; letter-spacing: 0.16em; color: var(--lime); font-weight: 700; }
.curve-legend strong { display: block; font-size: 17px; font-weight: 700; letter-spacing: -0.03em; margin: 5px 0 3px; }
.curve-legend p { font-size: 12.5px; color: rgba(247, 244, 238, 0.62); }

.origins { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px; }
.origin { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.origin .frame img { width: 100%; height: auto; }
.origin-body { padding: 20px 22px 22px; }
.origin h3 { font-size: 17px; letter-spacing: -0.035em; margin-bottom: 4px; }
.origin .origin-sub { font-size: 12.5px; color: var(--ink-3); font-weight: 600; margin-bottom: 12px; }
.origin dl { display: grid; grid-template-columns: 58px minmax(0, 1fr); font-size: 12.5px; }
.origin dt { color: var(--ink-3); padding: 6px 0; border-top: 1px solid var(--line-soft); }
.origin dd { margin: 0; padding: 6px 0; border-top: 1px solid var(--line-soft); }

/* --------------------------------------------------------------- 푸터 */
.site-footer { background: var(--espresso); color: rgba(247, 244, 238, 0.72); padding: 66px 0 30px; font-size: 13.5px; }
.foot-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.3fr; gap: 40px; }
.site-footer .brand b, .site-footer h2 { color: var(--cream); }
.site-footer .brand small { color: rgba(247, 244, 238, 0.5); }
.foot-col h2 { font-size: 11.5px; letter-spacing: 0.18em; text-transform: uppercase; margin-bottom: 16px; font-weight: 700; }
.foot-col li { padding: 5px 0; }
.foot-col a:hover { color: var(--lime); }
.foot-brand p { margin-top: 16px; max-width: 24em; color: rgba(247, 244, 238, 0.6); }
.foot-info div { display: grid; grid-template-columns: 62px minmax(0, 1fr); gap: 8px; padding: 5px 0; }
.foot-info b { color: rgba(247, 244, 238, 0.5); font-weight: 500; }
.social { display: flex; gap: 8px; margin-top: 16px; }
.social a {
  width: 44px; height: 44px; display: grid; place-items: center;
  border: 1px solid var(--line-dark); border-radius: 50%; color: rgba(247, 244, 238, 0.8);
  transition: border-color 0.24s var(--ease), color 0.24s var(--ease);
}
.social a:hover { border-color: var(--lime); color: var(--lime); }
.legal { margin-top: 44px; padding-top: 22px; border-top: 1px solid var(--line-dark); font-size: 12px; color: rgba(247, 244, 238, 0.5); line-height: 1.9; }
.legal-links { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 12px; }
.legal-links a:hover { color: var(--lime); }

/* --------------------------------------------------- 장바구니 서랍 */
.cart-panel {
  position: fixed; inset: 0 0 0 auto; width: min(420px, 92vw); z-index: var(--z-panel);
  background: var(--surface); border-left: 1px solid var(--line);
  display: none; flex-direction: column;
}
.cart-panel.open { display: flex; animation: slidein 0.32s var(--ease); }
@keyframes slidein { from { transform: translateX(100%); } to { transform: none; } }
.cart-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.cart-head h2 { font-size: 17px; }
.cart-body { flex: 1; overflow-y: auto; padding: 18px 22px; }
.cart-empty { text-align: center; padding: 46px 10px; color: var(--ink-3); font-size: 14px; display: grid; gap: 14px; justify-items: center; }
.cart-line { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--line-soft); align-items: start; }
.cart-line img { width: 56px; height: auto; }
.cart-line b { font-size: 14px; font-weight: 600; letter-spacing: -0.03em; display: block; }
.cart-line .opt-txt { font-size: 12px; color: var(--ink-3); }
.cart-line .qty { display: inline-flex; align-items: center; gap: 2px; margin-top: 10px; border: 1px solid var(--line); border-radius: 999px; }
.qty button { width: 40px; height: 40px; display: grid; place-items: center; background: none; border: 0; cursor: pointer; border-radius: 999px; }
.qty button:hover { background: var(--surface-2); }
.qty span { min-width: 26px; text-align: center; font-size: 14px; font-weight: 600; }
.cart-line .line-price { font-size: 14px; font-weight: 700; white-space: nowrap; }
.cart-foot { border-top: 1px solid var(--line); padding: 18px 22px 22px; background: var(--surface); }
.coupon { display: flex; gap: 8px; margin-bottom: 14px; }
.coupon .control { min-height: 44px; }
.cart-sums { font-size: 13.5px; }
.cart-sums div { display: flex; justify-content: space-between; padding: 5px 0; }
.cart-sums .tot { border-top: 1px solid var(--line); margin-top: 8px; padding-top: 12px; font-size: 17px; font-weight: 700; }
.stepper { display: flex; gap: 6px; margin-bottom: 18px; }
.stepper li { flex: 1; font-size: 12px; font-weight: 600; color: var(--ink-3); border-top: 3px solid var(--line); padding-top: 8px; }
.stepper li[aria-current="step"] { color: var(--ink); border-top-color: var(--lime-deep); }
.stepper[hidden] { display: none; }
.checkout-block { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.checkout-block[hidden] { display: none; }
.co-row { display: grid; gap: 8px; padding: 14px 0; border-bottom: 1px solid var(--line-soft); font-size: 13.5px; }
.co-row b { font-size: 12px; color: var(--ink-3); font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; }
.done { text-align: center; display: grid; gap: 12px; justify-items: center; padding: 30px 0; }
.done .ring { width: 62px; height: 62px; border-radius: 50%; display: grid; place-items: center; background: var(--ok-bg); color: var(--ok); }

/* --------------------------------------------------------------- 검색 */
.search-panel {
  position: fixed; inset: 0; z-index: var(--z-panel); display: none;
  align-items: flex-start; justify-content: center; padding: 84px 20px 20px;
  background: rgba(35, 24, 15, 0.5);
}
.search-panel.open { display: flex; }
.search-card { width: min(560px, 100%); background: var(--surface); border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow); }
.search-top { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.search-top .control { border: 0; box-shadow: none; }
.search-top .control:focus { box-shadow: none; }
.search-list { max-height: 46vh; overflow-y: auto; padding: 8px; }
.search-list a { display: grid; gap: 2px; padding: 12px 14px; border-radius: var(--r-sm); min-height: 56px; align-content: center; }
.search-list a:hover, .search-list a:focus-visible { background: var(--surface-2); }
.search-list b { font-size: 14.5px; font-weight: 600; letter-spacing: -0.03em; }
.search-list span { font-size: 12.5px; color: var(--ink-3); }
.search-none { padding: 26px 14px; text-align: center; color: var(--ink-3); font-size: 13.5px; }

/* -------------------------------------- 모바일 하단 탭바 (06-mobile) */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 70; display: none;
  padding-bottom: env(safe-area-inset-bottom);
  background: rgba(247, 244, 238, 0.97);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
}
.tabbar ul { display: flex; }
.tabbar li { flex: 1 1 0; min-width: 0; }
.tabbar a, .tabbar button {
  width: 100%; min-height: 58px; padding: 8px 2px 7px;
  display: grid; justify-items: center; gap: 3px;
  background: none; border: 0; cursor: pointer; position: relative;
  font-size: 10.5px; font-weight: 600; letter-spacing: -0.03em; color: var(--ink-3);
}
.tabbar a[aria-current="page"] { color: var(--ink); }
.tabbar a[aria-current="page"] .ico { color: var(--ink); }
.tabbar .ico { width: 21px; height: 21px; color: var(--ink-3); }
.tabbar .cart-count { top: 5px; right: calc(50% - 20px); }

/* --------------------------------------------------------------- 토스트 */
.toast {
  position: fixed; left: 50%; bottom: 30px; z-index: var(--z-toast);
  transform: translate(-50%, 16px);
  min-width: 260px; max-width: calc(100vw - 32px);
  display: flex; align-items: center; gap: 12px;
  padding: 14px 20px; background: var(--espresso); color: var(--cream);
  border-radius: 999px; font-size: 14px; box-shadow: 0 14px 36px rgba(43, 31, 23, 0.3);
  opacity: 0; visibility: hidden;
  /* 알림은 아래 버튼을 가로막지 않는다 */
  pointer-events: none;
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s;
}
.toast.show { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.toast .ico { color: var(--lime); }

.spinner {
  width: 15px; height: 15px; border: 2px solid rgba(247, 244, 238, 0.35);
  border-top-color: var(--cream); border-radius: 50%; animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.to-top {
  position: fixed; right: 22px; bottom: 26px; z-index: 65;
  width: 46px; height: 46px; display: grid; place-items: center;
  background: var(--espresso); color: var(--cream); border: 0; border-radius: 50%;
  cursor: pointer; opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s;
}
.to-top.show { opacity: 1; visibility: visible; transform: none; }

/* --------------------------------------------------------------- 등장 */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }

/* =============================================================== 반응형 */
@media (max-width: 1180px) {
  :root { --wrap: 1024px; --section: 104px; }
  .navlinks { gap: 20px; }
  .map-layout { grid-template-columns: minmax(0, 1fr) 320px; gap: 28px; }
  .build { grid-template-columns: minmax(0, 1fr) 330px; gap: 28px; }
  .story-top { grid-template-columns: minmax(0, 1fr) 300px; gap: 32px; }
}

@media (max-width: 1024px) {
  :root { --gutter: 28px; --section: 88px; }
  .nav { height: 68px; }
  .navlinks, .nav-cta { display: none; }
  .menu-btn { display: inline-grid; }
  .hero-grid { grid-template-columns: minmax(0, 1fr); min-height: 0; padding-block: 54px 44px; gap: 30px; }
  .hero-media { width: 100%; opacity: 0.42; }
  .hero-media::after { background: linear-gradient(180deg, rgba(43, 31, 23, 0.55) 0%, rgba(43, 31, 23, 0.9) 72%); }
  .hero-rail { grid-template-columns: repeat(3, minmax(0, 1fr)); display: grid; }
  .hero-rail li { border-top: 1px solid var(--line-dark); }
  .paths { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .paths .path:last-child { border-right: 0; }
  .pick-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fresh-grid { grid-template-columns: minmax(0, 1fr); gap: 34px; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 30px 0; }
  .map-layout { grid-template-columns: minmax(0, 1fr); }
  .detail { position: static; }
  .cmp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .build { grid-template-columns: minmax(0, 1fr); }
  .summary { position: static; }
  .result-grid { grid-template-columns: minmax(0, 1fr); }
  .grind-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .origins { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .story-top { grid-template-columns: minmax(0, 1fr); }
  .foot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; }
  .quiz { padding: 30px 26px 26px; }
  .recipe { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .recipe div:nth-child(3) { border-left: 0; }
  .recipe div:nth-child(n + 3) { border-top: 1px solid var(--line-soft); }
  .curve-legend { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  :root { --gutter: 20px; --section: 72px; }
  body { font-size: 15.5px; }
  .display { font-size: clamp(32px, 9vw, 44px); }
  .hero-actions .btn { width: 100%; }
  .hero-rail { grid-template-columns: minmax(0, 1fr); }
  .paths { grid-template-columns: minmax(0, 1fr); }
  .path { border-left: 0; border-top: 1px solid var(--line); padding: 24px 0; }
  .paths .path:last-child { border-right: 0; border-bottom: 1px solid var(--line); }
  .pick-grid { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .pick { flex-direction: row; gap: 16px; align-items: flex-start; }
  .pick-fig { width: 96px; flex: none; margin-bottom: 0; padding: 10px 0; }
  .pick-fig img { width: 72px; }
  .pick-body { flex: 1; min-width: 0; }
  .pick-note { min-height: 0; }
  .pick-meter { margin: 10px 0 12px; }
  /* 좁은 칸에서 가격과 담기 버튼이 서로를 밀지 않게 줄을 바꾼다 */
  .pick-foot { flex-wrap: wrap; row-gap: 12px; }
  .pick-foot .btn-sm { padding: 0 14px; }
  .steps { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .steps li { padding: 22px 0 0; }
  .steps li + li { padding-left: 0; }
  .steps li + li::before { left: 26px; top: 0; height: 22px; bottom: auto; width: 1px; }
  .step-ico { margin-bottom: 12px; width: 46px; height: 46px; }
  .cta-band { padding: 28px 24px; }
  /* 좁은 화면에서는 가로축 이름을 지도 옆이 아니라 아래 한 줄로 옮긴다 */
  .mapbox { padding: 38px 24px 30px; }
  .axis-tag.l, .axis-tag.r { display: none; }
  .plot-scale { display: flex; }
  .dot em { font-size: 10px; }
  .cmp-grid { grid-template-columns: minmax(0, 1fr); }
  .grind-grid { grid-template-columns: minmax(0, 1fr); }
  .origins { grid-template-columns: minmax(0, 1fr); }
  .foot-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .recipe { grid-template-columns: minmax(0, 1fr); }
  .recipe div { border-left: 0; border-top: 1px solid var(--line-soft); }
  .recipe div:first-child { border-top: 0; }
  .curve-legend { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .tl { grid-template-columns: minmax(0, 1fr); }
  .field-row { grid-template-columns: minmax(0, 1fr); }
  .build-form { padding: 24px 20px 22px; }
  .quiz { padding: 24px 18px 22px; }
  .opt label { width: 104px; }
  .opt .ring { width: 72px; height: 72px; }
  .opts.text .opt { flex: 1 1 100%; }
  .opts.text .opt label { width: 100%; }
  .result-card { grid-template-columns: 84px minmax(0, 1fr); gap: 12px; }
  .result-card img { width: 74px; }
  .tabbar { display: block; }
  body { padding-bottom: 62px; }
  .to-top { display: none; }
  .toast { bottom: 78px; }
  .detail dl { grid-template-columns: 68px minmax(0, 1fr); }
  .sec-head { margin-bottom: 30px; }
}

/* 좁은 폭에서는 헤더 아이콘이 상호를 밀어낸다 — 마이페이지는 서랍으로 내린다 */
@media (max-width: 560px) {
  .nav-my { display: none; }
  .nav-actions { gap: 2px; }
}

@media (max-width: 420px) {
  .brand small { display: none; }
  .brand b { font-size: 19px; }
  .nav { gap: 8px; }
}

@media (max-width: 380px) {
  .opt label { width: 92px; padding: 8px 2px 10px; }
  .opt .ring { width: 62px; height: 62px; }
  .mapbox { padding: 34px 18px 26px; }
  .cta-band { padding: 24px 18px; }
  .tabbar a, .tabbar button { font-size: 10px; }
}

/* 모션 최소화 — 진행 애니메이션을 걷어내고 최종 상태를 즉시 보여준다 */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important; animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important; scroll-behavior: auto !important;
  }
  .js .reveal { opacity: 1 !important; transform: none !important; }
  .curve .curve-path { stroke-dashoffset: 0 !important; animation: none !important; }
  .cart-panel.open { animation: none; }
}

@media print {
  .site-header, .drawer, .scrim, .to-top, .toast, .tabbar, .cart-panel, .search-panel { display: none !important; }
  body { background: #fff; }
}
