:root {
  --primary: #2d3138;
  --bg: #ffffff;
  --card: #ffffff;
  --text: #23211d;
  --muted: #8f8b83;
  --line: #ececea;
  --radius: 10px;
  --shadow: 0 10px 25px -8px rgba(15, 23, 42, .10);

  /* 본문 인터페이스는 차분한 무채색으로 유지 */
  --home-primary: #2d3138;
  --home-primary-dark: #1e2228;
  --home-soft: #f1f2f4;
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: "Pretendard Variable", Pretendard, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 14px;
}

/* 인쇄 상세 드롭다운 테두리 제거 */
#ind-coverPrint-select,
#ind-innerPrint-select,
#ind-coverPrint-select:focus,
#ind-innerPrint-select:focus,
#ind-coverPrint-select:active,
#ind-innerPrint-select:active,
#ind-coverPrint-select:hover,
#ind-innerPrint-select:hover,
#ind-coverPrint-select:focus-visible,
#ind-innerPrint-select:focus-visible {
  outline: none !important;
  border: 1px solid #cbd5e1 !important;
  border-color: #cbd5e1 !important;
  box-shadow: none !important;
}

/* 모든 상태에서 테두리 강제 설정 */
select#ind-innerPrint-select,
select#ind-coverPrint-select {
  border: 1px solid #cbd5e1 !important;
  border-color: #cbd5e1 !important;
}

.container {
  max-width: 1600px;
  width: 100%;
  margin: 0 auto;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: relative;
  z-index: 0;
  box-sizing: border-box;
}

/* ================= HEADER ================= */
.header {
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  position: sticky;
  top: 0;
  z-index: 1100;
  border-bottom: 1px solid #e6edf3;
  margin: 0;
  transition: transform 0.28s ease;
}
/* 아래로 스크롤하면 헤더 자동 숨김(위로 올리면 다시 표시) */
.header.header--hidden { transform: translateY(-100%); }

/* ── 온담 로고: 한국식 낙관(도장) + 명조체 ── */
.brand-logo-text {
  display: flex;
  align-items: center;
  gap: 11px;
  cursor: pointer;
  user-select: none;
}
/* 모던 워드마크 (20~40대 타깃) — 둥근 그린 마크 + Pretendard 볼드 */
.brand-mark {
  width: 36px; height: 36px; flex: none; border-radius: 11px;
  background: linear-gradient(135deg, #1bb15e 0%, #037a3f 100%);
  box-shadow: 0 5px 12px rgba(3,122,63,.30);
  position: relative;
}
.brand-mark::after {        /* 인쇄물(종이) 느낌의 미니멀 글리프 */
  content: ''; position: absolute; inset: 10px;
  border-radius: 4px; border: 2.5px solid rgba(255,255,255,.95);
  border-right-color: transparent; border-bottom-color: transparent;
}
.brand-words { display: flex; flex-direction: column; line-height: 1; gap: 3px; }
.brand-name {
  font-family: 'Pretendard', 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  font-size: 23px; font-weight: 800; color: #0f1722; letter-spacing: -0.6px;
}
.brand-tag {
  font-family: 'Pretendard', 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  font-size: 9.5px; font-weight: 800; letter-spacing: 2.2px; color: #1bb15e;
}
@media (max-width: 640px) {
  .brand-mark { width: 32px; height: 32px; border-radius: 9px; }
  .brand-name { font-size: 20px; }
  .brand-tag { font-size: 9px; letter-spacing: 1.8px; }
}

/* 개인결제 등 .main-content: 스크롤 시 카테고리(헤더) 뒤로 들어가도록, 겹침 방지 */
.main-content {
  z-index: 0;
  position: relative;
}

.header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  padding: 6px 32px 8px 32px;
  gap: 12px;
  background: #fff;
  max-width: 1600px;
  margin: 0 auto;
  width: 100%;
  box-sizing: border-box;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  user-select: none;
  margin-top: 6px;
}

/* 로고 이미지 흰색 배경 자동 제거 (multiply 합성: 흰색은 배경색 그대로 유지) */
#brand-logo {
  mix-blend-mode: multiply;
}

.logo-icon {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  background: var(--primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 24px;
  flex: 0 0 auto;
}

.brand-info h1 {
  margin: 0;
  font-size: 20px;
  font-weight: 900;
  letter-spacing: -.3px;
  color: #0f172a;
}

/* 네이버스토어식 헤더 검색바 */
.header-search {
  flex: 1 1 auto;
  max-width: 520px;
  margin: 0 28px;
  display: flex;
  align-items: center;
  background: #fff;
  border: 2px solid #2d3138;
  border-radius: 999px;
  padding: 3px 4px 3px 20px;
}
.header-search input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  background: transparent;
  font-size: 15px;
  color: #0f172a;
  padding: 9px 0;
}
.header-search input::placeholder { color: #9aa3af; }
.header-search button {
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  background: #2d3138;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.header-search button:hover { background: #1e2228; }
@media (max-width: 820px) {
  /* 모바일: 검색바를 헤더 둘째 줄 전체폭으로 */
  .header-search { order: 3; flex-basis: 100%; max-width: 100%; margin: 8px 0 0; }
}

.top-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-wrap: wrap;
  padding-top: 0;
  margin-left: auto;
}

.top-nav a {
  text-decoration: none;
  color: #475569;
  font-weight: 600;
  font-size: 12px;
  cursor: pointer;
  line-height: 1;
  transition: color 0.2s;
}

/* 네비 항목을 inline-flex로 통일하여 내부 아이템(아이콘/배지) 수직 가운데 정렬 */
.top-nav a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  vertical-align: middle;
}

.top-nav a:hover {
  color: var(--home-primary);
}

.top-nav .nav-sep {
  width: 1px;
  height: 12px;
  background: #d8ddd8;
  flex-shrink: 0;
  margin: 0 2px;
}

.top-nav .nav-user {
  color: #1e293b;
  font-weight: 800;
}

.top-nav .nav-logout {
  color: #b45353;
}

.top-nav .nav-logout:hover {
  color: #991b1b;
}

.top-nav .nav-admin {
  color: #2563eb;
  font-weight: 700;
}

.top-nav .nav-cart {
  display: flex;
  align-items: center;
  gap: 6px;
}

.cart-badge {
  background: var(--home-primary);
  color: #fff;
  font-size: 10px;
  padding: 2px 7px;
  border-radius: 999px;
  font-weight: 700;
  min-width: 18px;
  text-align: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  vertical-align: middle;
}

.header-bottom {
  display: block;
  padding: 0;
  background: #fff;
  color: #0f172a;
  position: relative;
  border-bottom: 1px solid #e6edf3;
}
  width: 42px;
  height: 42px;
  border-radius: 10px;
  border: none;
  background: transparent;
  color: #0f172a;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex: 0 0 auto;
  transition: background 0.2s;
  margin-left: 40px;
  margin-right: 0;
}

.menu-btn:hover {
  background: rgba(0, 0, 0, 0.05);
}

.cat-tabs {
  display: flex;
  align-items: center;
  gap: 0;
  flex: none;
  justify-content: center;
  border-bottom: none;
  margin: 0;
  padding: 0;
  height: 100%;
}

/* 온담 모던 가로 메뉴(둥근 pill 호버 + 라운드 그린 언더라인) — 20~40대 타깃 */
.cat-menu-row { gap: 0 4px !important; }
.cat-menu-row .cat-nav-col { min-width: auto; }
.cat-link,
.cat-tab-btn {
  color: #3f4a5a;
  text-decoration: none;
  font-family: 'Pretendard', 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  font-weight: 700;
  font-size: 15.5px;
  letter-spacing: -0.3px;
  padding: 10px 15px;
  border: none;
  background: none;
  border-radius: 12px;
  position: relative;
  white-space: nowrap;
  cursor: pointer;
  transition: color 0.15s, background 0.15s;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin: 2px 0;
  line-height: 1.2;
}
.cat-menu-row .cat-nav-col .cat-tab-btn { display: inline-flex; width: auto; padding: 10px 15px; }
.cat-caret {
  font-size: 11px;
  color: #94a3b8;
  transition: transform 0.18s, color 0.15s;
}
/* 라운드 밑줄 인디케이터(가운데 정렬, 둥근 끝) */
.cat-link::after,
.cat-tab-btn::after {
  content: '';
  position: absolute;
  left: 15px; right: 15px; bottom: 5px;
  height: 3px;
  border-radius: 3px;
  background: var(--primary);
  transform: scaleX(0);
  transition: transform 0.18s ease;
}
.cat-link:hover,
.cat-tab-btn:hover,
.cat-nav-col.has-menu:hover .cat-tab-btn,
.cat-link.active,
.cat-tab-btn.active {
  color: var(--primary);
  background: rgba(3,122,63,0.07);   /* 따뜻한 그린 소프트 pill */
}
.cat-link:hover::after,
.cat-tab-btn:hover::after,
.cat-nav-col.has-menu:hover .cat-tab-btn::after,
.cat-link.active::after,
.cat-tab-btn.active::after { transform: scaleX(1); }
.cat-tab-btn:hover .cat-caret,
.cat-nav-col.has-menu:hover .cat-caret,
.cat-tab-btn.active .cat-caret {
  color: var(--primary);
  transform: rotate(180deg);
}
/* 오늘의 특가는 빨강 강조 */
.cat-link--deal { color: #e0392b; }
.cat-link--deal:hover, .cat-link--deal.active { color: #e0392b; background: rgba(224,57,43,0.08); }
.cat-link--deal::after { background: #dc2626; }

/* 그리드 기반 카테고리 네비게이션 — 4개 탭 중앙 정렬, 탭 간 간격 */
.cat-nav-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 0 48px;
  margin: 0 auto;
  width: 100%;
  max-width: 1600px;
  padding: 0 32px;
  box-sizing: border-box;
}

.cat-nav-col {
  flex: 0 0 auto;
  text-align: center;
  position: relative;
  min-width: 100px;
}

.cat-nav-col .cat-tab-btn {
  display: block;
  padding: 16px 14px;
  width: 100%;
  box-sizing: border-box;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cat-dropdown-content {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  padding: 0;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transition: all 0.2s ease;
  background: #fff;
  z-index: 100;
}

.header-bottom:hover .cat-dropdown-content {
  padding: 15px 0;
  max-height: 200px;
  opacity: 1;
  visibility: visible;
}

.cat-dropdown-content a {
  display: block;
  color: #475569;
  padding: 6px 0;
  cursor: pointer;
  font-size: 14px;
  text-decoration: none;
}

.cat-dropdown-content a:hover {
  color: var(--primary);
}

/* ── 주문제작/일반상품 2-갈래 드롭다운 메뉴 (컬럼별 hover) ── */
.cat-nav-col.has-menu .cat-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: #fff;
  border: 1px solid #e6edf3;
  border-radius: 12px;
  box-shadow: 0 12px 30px rgba(0,0,0,0.10);
  padding: 8px;
  min-width: 168px;
  display: none;
  z-index: 1200;
}
.cat-nav-col.has-menu:hover .cat-menu { display: block; }
.cat-nav-col.has-menu:hover .cat-menu.cat-menu--wide {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px 6px;
  min-width: 300px;
}
.cat-menu a {
  display: block;
  padding: 9px 14px;
  color: #475569;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  text-align: left;
  border-radius: 8px;
  cursor: pointer;
  text-decoration: none;
}
.cat-menu a:hover { background: #f1f5f4; color: var(--primary); }
/* 와우 섹션 드롭다운(인쇄물/판촉·굿즈/사인·디스플레이) — 카테고리 썸네일 그리드 */
#nav-wow-sections { display: contents; }   /* span이 flex 행에 자식(드롭다운)을 직접 펼침 */
.cat-nav-col.has-menu:hover .cat-menu.cat-menu--sec {
  display: grid;
  grid-template-columns: repeat(2, minmax(258px, 1fr));
  gap: 6px;
  padding: 16px;
  min-width: 552px;
  max-height: 82vh;
  overflow-y: auto;
}
/* 드롭다운 항목(썸네일+이름) — .cat-menu a{display:block} 보다 우선 */
.cat-menu .wow-mega-item {
  display: flex; align-items: center; gap: 14px;
  padding: 9px 12px; border-radius: 12px; cursor: pointer; text-decoration: none;
}
.cat-menu .wow-mega-item:hover { background: rgba(3,122,63,0.07); }
.cat-menu .wm-thumb {
  display: block; width: 88px; height: 66px; flex: none; border-radius: 10px;
  background: #eef3f7 center/cover no-repeat; border: 1px solid #eef1f4;
}
.cat-menu .wm-name { font-size: 16px; font-weight: 700; color: #374151; text-align: left; line-height: 1.25; }
.cat-menu .wow-mega-item:hover .wm-name { color: var(--primary); }

/* ───────── 이용안내(용지/인쇄방식/제작가이드) ───────── */
.guide-tabs { display: flex; gap: 8px; border-bottom: 2px solid #eef1f4; margin-bottom: 22px; flex-wrap: wrap; }
.guide-tab {
  background: none; border: none; cursor: pointer; padding: 11px 18px; font-size: 15px; font-weight: 700;
  color: #64748b; border-bottom: 3px solid transparent; margin-bottom: -2px; border-radius: 8px 8px 0 0;
  font-family: 'Pretendard', 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif; transition: all .15s;
}
.guide-tab:hover { color: var(--primary); background: rgba(3,122,63,0.05); }
.guide-tab.active { color: var(--primary); border-bottom-color: var(--primary); }
.guide-h { font-size: 19px; font-weight: 800; color: #0f1722; margin: 4px 0 6px; }
.guide-note { font-size: 13px; color: #64748b; background: #f6f9f7; border: 1px solid #e7f0ea; border-radius: 10px; padding: 11px 14px; margin-bottom: 18px; }
.paper-group { margin-bottom: 26px; }
.pg-title { font-size: 16px; font-weight: 800; color: #1f2937; margin-bottom: 10px; }
.pg-title span { font-size: 12px; font-weight: 700; color: #94a3b8; margin-left: 4px; }
.paper-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; }
.paper-card { border: 1px solid #eef1f4; border-radius: 12px; overflow: hidden; background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,0.04); }
.paper-thumb { display: block; width: 100%; aspect-ratio: 4/3; object-fit: cover; background: #f1f5f4; }
.paper-name { padding: 9px 11px; font-size: 13px; font-weight: 600; color: #374151; }
.guide-table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 760px; }
.guide-table th, .guide-table td { border: 1px solid #e6edf3; padding: 11px 13px; text-align: center; vertical-align: middle; line-height: 1.5; }
.guide-table thead th { background: #1f2937; color: #fff; font-weight: 800; font-size: 14px; }
.guide-table tbody th { background: #f6f9f7; color: #0f1722; font-weight: 800; white-space: nowrap; }
.guide-table td { color: #475569; }
.gt-mini { display: inline-block; color: #94a3b8; font-size: 11px; margin-top: 3px; }
.guide-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.guide-card { border: 1px solid #eef1f4; border-radius: 14px; padding: 16px 18px; background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,0.04); }
.guide-card .gc-num { width: 24px; height: 24px; border-radius: 50%; background: #f0efeb; color: #6b675f; font-size: 12.5px; font-weight: 800; display: inline-flex; align-items: center; justify-content: center; margin-bottom: 8px; }
.guide-card .gc-t { font-size: 15px; font-weight: 800; color: #0f1722; margin-bottom: 5px; }
.guide-card .gc-d { font-size: 13px; color: #5b6675; line-height: 1.6; }
.guide-card .gc-tip { margin-top: 9px; font-size: 12.5px; font-weight: 700; color: var(--primary); background: rgba(3,122,63,0.07); border-radius: 8px; padding: 8px 10px; line-height: 1.5; }
.guide-intro { font-size: 14px; color: #55524c; background: #f7f6f3; border: 1px solid #e8e6e0; border-radius: 12px; padding: 14px 16px; margin-bottom: 18px; line-height: 1.65; }

/* ───────── 책자 표지 후가공 — 접이식(선택) ───────── */
.sf-fin-box { margin-top: 14px; }
.sf-fin-toggle { width: 100%; display: flex; align-items: center; gap: 8px; background: #f6f9f7; border: 1px solid #e7f0ea; border-radius: 12px; cursor: pointer; padding: 13px 15px; font-family: inherit; transition: background .15s; }
.sf-fin-toggle:hover { background: #eef5f0; }
.sf-fin-lab { font-size: 14.5px; font-weight: 800; color: #0f1722; }
.sf-fin-sub { font-size: 12px; font-weight: 600; color: #94a3b8; margin-left: 2px; }
.sf-fin-sum { margin-left: auto; font-size: 12.5px; font-weight: 700; color: #94a3b8; }
.sf-fin-sum.on { color: var(--primary); }
.sf-fin-caret { font-size: 12px; color: #94a3b8; margin-left: 8px; }
.sf-fin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px 14px; margin-top: 12px; }
@media (max-width: 540px) { .sf-fin-grid { grid-template-columns: 1fr; } }

/* 견적 입력 누락 강조 — 어느 칸을 채워야 하는지 표시 */
.sf-invalid { border: 1.5px solid #ef4444 !important; background: #fff7f7 !important; box-shadow: 0 0 0 3px rgba(239,68,68,0.12) !important; }
.sf-status.err { color: #dc2626; font-weight: 700; }
.sf-status.sf-guide { color: #bae6fd; font-weight: 800; line-height: 1.55; }
.sf-combo-suggest {
  margin-top: 10px; padding: 14px; border: 1px solid rgba(16,185,129,.5);
  border-radius: 12px; background: rgba(16,185,129,.1); color: #d1fae5;
  font-size: 12.5px; line-height: 1.55; text-align: left;
}
.sf-combo-suggest-title { font-weight: 950; color: #fff; margin-bottom: 5px; font-size: 14px; }
.sf-combo-suggest-desc { color: #bae6fd; margin-bottom: 10px; }
.sf-combo-card {
  display: block; width: 100%; text-align: left; margin-top: 8px; padding: 12px;
  border: 1px solid rgba(16,185,129,.42); border-radius: 10px; background: #fff;
  color: #0f172a; cursor: pointer; font-family: inherit;
  box-shadow: 0 6px 16px rgba(2,6,23,.12);
}
.sf-combo-card:hover { border-color: #10b981; box-shadow: 0 8px 18px rgba(16,185,129,.18); }
.sf-combo-card-main { font-size: 13.5px; font-weight: 950; line-height: 1.45; margin-bottom: 8px; }
.sf-combo-chips { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 8px; }
.sf-combo-chip {
  display: inline-flex; align-items: center; gap: 4px; max-width: 100%;
  padding: 4px 7px; border-radius: 999px; background: #ecfdf5; color: #047857;
  font-size: 11.5px; font-weight: 850; line-height: 1.35;
}
.sf-combo-meta { display: flex; flex-wrap: wrap; gap: 6px; color: #334155; font-size: 12px; font-weight: 850; }
.sf-combo-apply {
  margin-top: 9px; display: inline-flex; align-items: center; justify-content: center;
  min-height: 32px; padding: 7px 10px; border-radius: 8px; background: #10b981;
  color: #052e22; font-size: 12.5px; font-weight: 950;
}
.sf-combo-empty-btn {
  width: 100%; padding: 10px 12px; border: none; border-radius: 8px; background: #10b981;
  color: #052e22; cursor: pointer; font-size: 13px; font-weight: 900; font-family: inherit;
}
/* 그 칸 바로 옆 친절 안내 버블 */
.sf-fieldhint {
  position: relative; margin-top: 7px; display: inline-block;
  font-size: 12.5px; font-weight: 800; color: #b45309;
  background: #fff7ed; border: 1.5px solid #fdba74; border-radius: 9px;
  padding: 7px 11px; box-shadow: 0 3px 8px rgba(234,88,12,0.14);
  animation: sfHintPop 0.22s ease;
}
.sf-fieldhint::before {   /* 위쪽 말풍선 꼬리 */
  content: ''; position: absolute; top: -6px; left: 16px;
  width: 10px; height: 10px; background: #fff7ed;
  border-left: 1.5px solid #fdba74; border-top: 1.5px solid #fdba74;
  transform: rotate(45deg);
}
@keyframes sfHintPop { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
/* 메뉴가 잘리지 않도록 헤더 하단 오버플로 허용 */
.header-bottom { overflow: visible; }
@media (max-width: 820px) {
  .cat-nav-col.has-menu .cat-menu { display: none !important; }
  .cat-caret { display: none; }
  .header-bottom:hover .cat-dropdown-content,
  .header-bottom:hover .cat-full-dropdown {
    display: none !important;
    max-height: 0 !important;
    opacity: 0 !important;
    visibility: hidden !important;
    padding: 0 !important;
  }
}

/* 전체 메뉴 드롭다운 (사용 안 함) */
.cat-full-dropdown {
  width: 100%;
  background: #ffffff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
  z-index: 2000;
  position: absolute;
  top: 100%;
  left: 0;
}

.header-bottom:hover .cat-full-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.cat-nav {
  display: block;
  width: 100vw;
  margin-left: calc(-50vw + 50%);
  background: #fff;
  padding-left: 0;
}

.header:hover ~ .cat-nav .cat-dropdown,
.cat-nav:hover .cat-dropdown {
  opacity: 1;
  visibility: visible;
  max-height: 500px;
  transform: translateY(0);
  padding: 24px 40px 24px 122px;
}

.cat-nav::-webkit-scrollbar {
  display: none;
}

.cat-dropdown {
  position: relative;
  top: 0;
  left: 0;
  right: auto;
  background: #ffffff;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  margin-top: 0;
  width: 100%;
  margin-left: 0;
  opacity: 0;
  visibility: hidden;
  max-height: 0;
  overflow: hidden;
  transform: translateY(-10px);
  transition: opacity 0.2s ease, visibility 0.2s ease, max-height 0.2s ease, transform 0.2s ease;
  z-index: 100;
  border: none;
  padding: 0 40px 0 122px;
}

.cat-content-panel {
  display: none;
}

.cat-content-panel.active {
  display: block;
}

.cat-dropdown a {
  display: block;
  color: #1e293b;
  padding: 10px 0;
  font-size: 15px;
  font-weight: 500;
  border-radius: 0;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  background: transparent;
  border-bottom: none;
}

.cat-dropdown a:hover {
  background: transparent;
  color: var(--primary);
}

/* ================= FULL MENU DROPDOWN ================= */
.header-bottom {
  position: relative;
}

.full-menu-overlay {
  display: none;
}

.full-menu-panel {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: #fff;
  z-index: 2000;
  max-height: calc(100vh - 200px);
  overflow-y: auto;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  transform: translateY(-20px);
  opacity: 0;
  visibility: hidden;
  transition: transform 0.3s ease, opacity 0.3s, visibility 0.3s;
  pointer-events: auto;
}

.full-menu-panel.show {
  transform: translateY(0);
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.full-menu-content {
  padding: 24px 30px;
  background: #fff;
  position: relative;
  z-index: 2001;
  display: flex;
  flex-direction: row;
  gap: 30px;
  flex-wrap: wrap;
  align-items: flex-start;
}

.full-menu-category-section {
  display: flex;
  flex-direction: column;
  border-bottom: none;
  padding: 16px;
  flex: 0 1 auto;
  background: #f8fafc;
  border-radius: 0;
}

.full-menu-category-section:last-child {
  border-bottom: none;
}

.full-menu-category-title {
  font-size: 15px;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--primary);
  letter-spacing: 0.5px;
}

.full-menu-columns {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.full-menu-column {
  display: flex;
  flex-direction: column;
}

.full-menu-column-title {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: #64748b;
  margin-bottom: 8px;
  padding-bottom: 0;
  border-bottom: none;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.full-menu-column-title::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 4px;
  background: var(--primary);
  border-radius: 50%;
  margin-right: 4px;
}

.full-menu-column-item {
  padding: 7px 0;
  color: #475569;
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.2s;
  cursor: pointer;
  border-radius: 0;
  white-space: nowrap;
  padding-left: 8px;
  border-left: 2px solid transparent;
}

.full-menu-column-item:hover {
  background: none;
  color: var(--primary);
  border-left: 2px solid var(--primary);
  font-weight: 600;
  padding-left: 8px;
}

/* ================= COMMON CARD ================= */
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 0px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.card-body {
  padding: 18px;
}

.btn {
  width: auto;
  border: none;
  border-radius: 0px;
  padding: 10px;
  font-weight: 600;
  cursor: pointer;
  transition: .15s;
  font-size: 13px;
}

.admin-tab-btn.active {
  background: var(--home-primary) !important;
}

.col-resizer {
  position: absolute;
  right: 0;
  top: 0;
  width: 4px;
  height: 100%;
  cursor: col-resize;
  background: #cbd5e1;
  user-select: none;
  transition: background 0.2s ease;
}

.col-resizer:hover {
  background: var(--home-primary) !important;
}

.btn-primary {
  background: var(--home-primary);
  color: #fff;
}

.btn-primary:hover {
  background: var(--home-primary-dark);
}

.quote-calc-btn-wrap .btn-primary {
  background: var(--primary);
}
.quote-calc-btn-wrap .btn-primary:hover {
  background: var(--home-primary-dark);
}

.btn-secondary {
  background: #1e293b;
  color: #fff;
}

/* ================= HOME GRID (Row-based) ================= */
#view-home {
  display: block;
}

.home-grid {
  display: flex;
  flex-direction: column;
  gap: 70px;
}

.home-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  align-items: flex-start;
  padding: 0 16px;
  box-sizing: border-box;
}

@media (min-width: 1600px) {
  .home-row {
    grid-template-columns: 1fr;
  }
}

/* 홈 로그인/바로가기 카드 + 공지 카드 숨김 — 헤더/하단으로 통일, 메인은 상품 중심 */
.home-row .home-login-card { display: none !important; }
.home-row .home-notice { display: none !important; }
/* 히어로 배너 영역 제거 — 헤더(검색) 바로 아래 상품이 오도록 */
.home-row { display: none !important; }
.home-grid { gap: 0 !important; }

.consult-entry {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(310px, .9fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
  margin: 24px auto 32px;
  max-width: 1280px;
  padding: 27px 0 28px;
  border-top: 2px solid #272a31;
  border-bottom: 1px solid #dedfe3;
  border-radius: 0;
  background: transparent;
  box-sizing: border-box;
}
.consult-entry-copy { min-width: 0; }
.consult-entry-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 11px;
  color: #7c553a;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: -.02em;
}
.consult-entry-eyebrow::before {
  width: 22px;
  height: 2px;
  background: currentColor;
  content: "";
}
.consult-entry h2 {
  margin: 0;
  color: #20232a;
  font-size: clamp(28px, 2.35vw, 36px);
  font-weight: 800;
  letter-spacing: -.06em;
  line-height: 1.23;
  word-break: keep-all;
}
.consult-entry-desc {
  max-width: 570px;
  margin: 16px 0 0;
  color: #5f646d;
  font-size: 14px;
  line-height: 1.65;
  word-break: keep-all;
}
.consult-entry-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 20px; }
.consult-entry-actions button {
  min-height: 46px;
  border-radius: 7px;
  padding: 0 18px;
  font: inherit;
  font-size: 14px;
  font-weight: 750;
  cursor: pointer;
}
.consult-entry-primary { border: 1px solid #303643; background: #303643; color: #fff; }
.consult-entry-primary:hover { background: #20242d; }
.consult-entry-secondary { border: 1px solid transparent; background: transparent; color: #4c525d; }
.consult-entry-secondary span { display: inline-block; margin-left: 4px; transition: transform .16s ease; }
.consult-entry-secondary:hover { color: #171a20; text-decoration: underline; text-underline-offset: 4px; }
.consult-entry-secondary:hover span { transform: translateX(3px); }
.consult-entry-note { margin: 11px 0 0; color: #858992; font-size: 12px; line-height: 1.55; }
.consult-entry-steps {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0 0 0 29px;
  list-style: none;
  border-left: 1px solid #d9dce1;
}
.consult-entry-steps li {
  position: relative;
  min-height: 74px;
  padding: 11px 0 12px 12px;
  border: 0;
  border-bottom: 1px solid #e3e5e8;
  border-radius: 0;
  background: transparent;
  box-sizing: border-box;
}
.consult-entry-steps li:first-child { padding-top: 0; }
.consult-entry-steps li:last-child { padding-bottom: 0; border-bottom: 0; }
.consult-step-number {
  position: absolute;
  top: 11px;
  left: -30px;
  color: #875b40;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .06em;
}
.consult-entry-steps li:first-child .consult-step-number { top: 0; }
.consult-entry-steps strong { display: block; color: #2a2e36; font-size: 15px; font-weight: 800; letter-spacing: -.03em; }
.consult-entry-steps p { margin: 5px 0 0; color: #777c85; font-size: 12.5px; line-height: 1.5; word-break: keep-all; }

.home-catalog {
  width: 100%;
  max-width: 1280px;
  margin-right: auto !important;
  margin-left: auto !important;
}

#home-sections .home-sec-grid {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)) !important;
  gap: 20px !important;
}

#view-home #home-sections button[style*="background:#037a3f"],
#view-home #home-sections button[style*="background: rgb(3, 122, 63)"] {
  background: #2d3138 !important;
  border-color: #2d3138 !important;
  box-shadow: 0 2px 6px rgba(30, 34, 40, .18) !important;
}

#view-home #home-sections [style*="color:#037a3f"],
#view-home #home-sections [style*="color: rgb(3, 122, 63)"] {
  color: #4d525b !important;
}

#view-home #home-sections [style*="background:#e7f5ee"],
#view-home #home-sections [style*="background: rgb(231, 245, 238)"] {
  background: #f0f1f3 !important;
}

#view-home #home-sections [style*="background:#eef6f1"],
#view-home #home-sections [style*="background: rgb(238, 246, 241)"] {
  background-color: #f1f2f4 !important;
}

#view-home #home-sections .home-sec-grid > .card {
  box-shadow: 0 8px 22px rgba(24, 28, 34, .08) !important;
}

#view-home #home-sections .home-sec-grid > .card:hover {
  box-shadow: 0 15px 30px rgba(24, 28, 34, .14) !important;
}

.sf-consult-price-note {
  margin: 0 0 16px;
  padding: 13px 14px;
  border: 1px solid #eadfd2;
  border-radius: 10px;
  background: #fffaf5;
  color: #6e6257;
  font-size: 13px;
  line-height: 1.6;
  word-break: keep-all;
}
body:not(.sf-admin-inspect) #view-shop .sf-priceblock { display: none; }
body:not(.sf-admin-inspect) #view-shop #sf-inquiry { display: none; }
body:not(.sf-admin-inspect) #view-shop #sf-go { flex: 1; }

@media (max-width: 780px) {
  .consult-entry { grid-template-columns: 1fr; gap: 32px; margin: 20px 16px 30px; padding: 28px 0 30px; }
  .consult-entry h2 { font-size: 28px; }
  .consult-entry-desc { font-size: 14px; line-height: 1.65; }
  .consult-entry-actions { display: grid; grid-template-columns: 1fr; }
  .consult-entry-actions button { width: 100%; }
  .consult-entry-steps { padding-left: 27px; }
  .consult-entry-steps li { min-height: auto; padding: 14px 0 15px 11px; }
  .home-catalog { max-width: 100%; }
  #home-sections .home-sec-grid { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)) !important; gap: 14px !important; }
}

/* 슬라이더 영역: 그리드 열 안에 맞춤 */
.home-row .hero-left {
  min-width: 0;
  width: 100%;
  max-width: calc(100% - 15px);
  overflow: hidden;
}

/* 데스크톱 슬라이더: 이미지 높이에 맞춰 컨테이너 높이 결정 → 확대 시 아래 회색 영역 제거 */
.home-row .home-slider {
  height: auto !important;
  min-height: 0;
  max-width: 100%;
  box-sizing: border-box;
}
.home-row .home-slider .home-slide.active {
  position: relative !important;
  inset: auto !important;
}
.home-row .home-slider .home-slide.active img {
  width: 100% !important;
  height: auto !important;
  display: block !important;
  vertical-align: top;
}

/* 메인 히어로(슬라이더 대체) — 네이버쇼핑풍 깔끔한 단일 검색바 */
.home-hero {
  background: #f8fafc;
  border: 1px solid #eef2f6;
  border-radius: 16px;
  padding: 52px 24px;
  min-height: 200px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
}
.home-hero-title {
  font-size: 27px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
  line-height: 1.25;
}
.home-hero-sub {
  font-size: 14px;
  color: #64748b;
  margin: 10px 0 24px;
  line-height: 1.5;
}
.home-hero-search {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: 600px;
  background: #fff;
  border: 2px solid #2d3138;
  border-radius: 999px;
  padding: 5px 6px 5px 24px;
  box-shadow: 0 4px 16px rgba(30,34,40,.08);
}
.home-hero-search input {
  flex: 1;
  min-width: 0;
  border: none;
  outline: none;
  background: transparent;
  font-size: 16px;
  color: #0f172a;
  padding: 10px 0;
}
.home-hero-search input::placeholder { color: #94a3b8; }
.home-hero-search button {
  flex: 0 0 46px;
  width: 46px;
  height: 46px;
  border: none;
  border-radius: 50%;
  background: #2d3138;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.home-hero-search button:hover { background: #1e2228; }
@media (max-width: 640px) {
  .home-hero { padding: 32px 18px; min-height: 0; }
  .home-hero-title { font-size: 21px; }
}
/* 데스크톱: 헤더 검색바가 있으니 히어로 검색은 숨김(모바일에선 표시) */
@media (min-width: 821px) {
  .home-hero-search { display: none; }
  .home-hero { min-height: 0; padding: 40px 24px; }
}

.home-row .home-login-card {
  height: fit-content;
  width: 100%;
}

.home-row .home-login-card .card-body {
  height: auto;
  display: flex;
  flex-direction: column;
}

.home-row .home-shortcuts {
  margin-top: 8px;
}

.home-row .home-login-card .card-body>:last-child {
  margin-top: auto;
}

@media (max-width: 980px) {
  /* 데스크톱과 같이 히어로/메인슬라이드 영역은 숨김 */
  .home-row {
    display: none !important;
    grid-template-columns: none !important;
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 12px !important;
    box-sizing: border-box !important;
  }
  
  /* 슬라이더 영역 */
  .home-row .hero-left {
    width: 100% !important;
    max-width: 100% !important;
    margin-bottom: 16px;
  }
  
  /* 로그인+공지 컨테이너 */
  .home-row > div:last-child {
    width: 100% !important;
    max-width: 100% !important;
  }

  .header {
    position: static;
  }

  /* 홈 화면 전체: 오버플로우 방지 */
  #view-home,
  .home-grid {
    max-width: 100% !important;
    width: 100% !important;
    overflow-x: hidden !important;
  }

  /* 로그인 카드: 화면 안에 맞추기 */
  .home-login-card,
  .home-row .home-login-card {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
  .home-login-card .card-body {
    padding: 16px !important;
    box-sizing: border-box !important;
  }

  /* 메인 슬라이더: 이미지 높이에 맞춰 컨테이너 높이 결정 (아래 빈 공간 제거) */
  .home-row .home-slider {
    min-height: 0 !important;
    height: auto !important;
    max-width: 100% !important;
    width: 100% !important;
    background: #f8fafc;
  }
  .home-row .home-slider .home-slide {
    position: relative !important;
    inset: auto !important;
    display: none;
  }
  .home-row .home-slider .home-slide.active {
    display: block !important;
  }
  .home-row .home-slider .home-slide img {
    width: 100% !important;
    height: auto !important;
    display: block !important;
    vertical-align: top;
    object-fit: contain !important;
    background: #f8fafc;
  }
  .home-slide-text,
  .home-slide-overlay {
    z-index: 2;
  }
  .home-slide-text {
    text-shadow: 0 1px 3px rgba(0,0,0,0.5);
  }

  /* 공지사항 카드: 오버플로우 방지 */
  .home-notice {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
  .notice-head {
    padding: 6px 14px !important;
  }
  .notice-head,
  .notice-list {
    padding-left: 12px;
    padding-right: 12px;
  }
}

/* ---- Slider ---- */
.home-slider {
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  background: #000;
  border: 1px solid var(--line);
  width: 100%;
  max-width: 100%;
}

.home-slide {
  position: absolute;
  inset: 0;
  display: none;
}

.home-slide.active {
  display: block;
}

.home-slide img {
  width: 100%;
  height: 100%;
  object-fit: contain !important;
  object-position: top center !important;
  opacity: 1;
  background: #f1f5f9;
}

/* 데스크톱 슬라이더: 배경 + 이미지 항상 전체 노출(잘림 방지), 위쪽 여백 제거 */
.home-slider {
  background: #f1f5f9;
}
.home-row .home-slider .home-slide img {
  object-fit: contain !important;
  object-position: top center !important;
}

.home-slide-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0), rgba(0, 0, 0, .20));
}

.home-slide-text {
  position: absolute;
  left: 24px;
  bottom: 22px;
  color: #fff;
  max-width: 70%;
}

.home-slide-text h2 {
  margin: 0;
  font-size: 28px;
  font-weight: 1100;
  letter-spacing: -.4px;
}

.home-slide-text p {
  margin: 8px 0 0 0;
  font-weight: 800;
  opacity: .92;
}

.home-pager {
  display: flex;
  align-items: center;
  gap: 6px;
}

.home-pager-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: all 0.3s ease;
}

.home-pager-dot.active {
  background: #fff;
  width: 24px;
  border-radius: 4px;
}

/* ---- Login card ---- */
.home-login-head {
  padding: 14px 18px;
  font-weight: 1100;
  background: #f8fbff;
  border-bottom: 1px solid var(--line);
}

.home-mini-links {
  display: flex;
  justify-content: space-between;
  margin-top: 10px;
  font-weight: 900;
  font-size: 12px;
  color: var(--muted);
}

.home-mini-links a {
  color: var(--muted);
  text-decoration: none;
  cursor: pointer;
}

.home-mini-links a:hover {
  color: var(--text);
  text-decoration: underline;
}

.home-shortcuts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 14px;
}

.home-shortcuts .sc {
  border: none;
  border-radius: 0px;
  padding: 12px 8px;
  text-align: center;
  cursor: pointer;
  transition: .15s;
  background: #fff;
}

.home-shortcuts .sc:hover {
  border-color: var(--home-primary);
  transform: translateY(-1px);
}

.home-shortcuts .sico {
  font-size: 20px;
  color: var(--home-primary);
  margin-bottom: 4px;
}

.home-shortcuts .stxt {
  font-size: 12px;
  font-weight: 1100;
  color: #334155;
}

/* ---- Quick icons row (make them look like real tiles) ---- */
.quick-card {
  padding: 18px;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.home-quick-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  flex: 1;
}

@media (max-width: 980px) {
  .home-quick-row {
    grid-template-columns: repeat(3, minmax(120px, 1fr));
  }
}

@media (max-width: 520px) {
  .home-quick-row {
    grid-template-columns: repeat(2, minmax(120px, 1fr));
  }
}

.home-quick {
  border: 1px solid #e2e8f0;
  border-radius: 0px;
  padding: 24px 16px;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.home-quick:hover {
  border-color: var(--primary);
  box-shadow: 0 8px 24px rgba(3, 122, 63, 0.15);
  transform: translateY(-4px);
}

.home-quick .ico {
  width: 64px;
  height: 64px;
  border-radius: 0px;
  margin: 0 auto 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
  box-shadow: 0 4px 12px rgba(3, 122, 63, 0.1);
}

.home-quick .txt {
  font-weight: 700;
  font-size: 14px;
  color: #1e293b;
  letter-spacing: -0.2px;
}

/* ---- Notice card ---- */
.home-notice {
  display: flex;
  flex-direction: column;
  height: auto;
  max-height: 250px;
}

.home-notice .notice-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.notice-head .ttl {
  font-weight: 1100;
  font-size: 16px;
}

.notice-head .more {
  font-weight: 1100;
  font-size: 12px;
  color: var(--home-primary);
  cursor: pointer;
}

.notice-head .more:hover {
  text-decoration: underline;
}

.notice-list {
  padding: 14px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.notice-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-weight: 900;
  color: #334155;
  cursor: pointer;
}

.notice-tag {
  font-size: 11px;
  font-weight: 1100;
  padding: 2px 8px;
  border-radius: 999px;
  background: #eaf4ff;
  color: #1d4ed8;
  white-space: nowrap;
}

.notice-title {
  font-size: 13px;
}

.notice-item:hover .notice-title {
  text-decoration: underline;
}

/* ---- CS ---- */
.home-cs {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
  height: 100%;
}

.cs-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.cs-ico {
  width: 58px;
  height: 58px;
  border-radius: 0px;
  background: var(--home-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  color: var(--home-primary);
}

.cs-txt .cst {
  margin: 0;
  font-weight: 1100;
  font-size: 18px;
}

.cs-txt .csh {
  margin: 4px 0 0 0;
  font-weight: 900;
  font-size: 12px;
  color: var(--muted);
}

.cs-right {
  text-align: right;
}

.cs-right .num {
  margin: 0;
  font-size: 30px;
  font-weight: 1200;
  letter-spacing: -.5px;
}

.cs-right .sub {
  margin: 4px 0 0 0;
  font-size: 12px;
  font-weight: 900;
  color: var(--muted);
}

/* ---- Best Products ---- */
.home-best {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
}

.best-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.best-label {
  margin: 0;
  font-size: 11px;
  font-weight: 1100;
  letter-spacing: 1px;
  color: #16a34a;
}

.best-title {
  margin: 2px 0 0 0;
  font-weight: 1100;
  font-size: 18px;
  color: #0f172a;
}

.best-sub {
  margin: 0;
  font-size: 12px;
  font-weight: 900;
  color: var(--muted);
}

.best-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.best-item {
  border: 1px solid var(--line);
  border-radius: 0px;
  overflow: hidden;
  background: #f8fafc;
  transition: .15s ease;
  cursor: pointer;
  padding: 0;
  display: block;
}

.best-item:hover {
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

.best-thumb {
  width: 100%;
  height: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  background: #fff;
}

/* ---- Toast ---- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%);
  background: #0f172a;
  color: #fff;
  padding: 12px 18px;
  border-radius: 999px;
  opacity: 0;
  pointer-events: none;
  transition: .2s;
  z-index: 3000;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(-6px);
}

/* ── 커스텀 모달 (alert/confirm/prompt 대체) ── */
@keyframes cmFadeIn {
  from { opacity: 0; transform: scale(0.92) translateY(10px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}
#custom-modal-overlay { backdrop-filter: blur(2px); }
#custom-modal-overlay.cm-show { display: flex !important; }
.cm-btn {
  flex: 1; min-width: 100px; padding: 11px 0; border: none; border-radius: 10px;
  font-size: 14px; font-weight: 700; cursor: pointer; transition: opacity 0.15s, transform 0.1s;
}
.cm-btn:active { transform: scale(0.97); }
.cm-btn-cancel { background: #f1f5f9; color: #475569; }
.cm-btn-cancel:hover { background: #e2e8f0; }
.cm-btn-ok { background: #3b82f6; color: #fff; }
.cm-btn-ok:hover { background: #2563eb; }
.cm-btn-danger { background: #ef4444; color: #fff; }
.cm-btn-danger:hover { background: #dc2626; }

.note-editor.note-frame {
  border-radius: 8px !important;
  border-color: #cbd5e1 !important;
}

.note-statusbar {
  display: none;
}

.note-editing-area .note-editable {
  border-radius: 0 0 8px 8px;
}

#adm-guide-txt,
#adm-ship-txt {
  width: 100%;
  padding: 10px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #f8fafc;
  font-size: 13px;
  resize: vertical;
  font-family: inherit;
}

/* ================= ADMIN EDITOR (Smart-store style) ================= */
#adm-content {
  /* card wrapper appearance already handled by .card */
}
.admin-editor-wrap .note-editor,
.admin-editor-wrap .note-editable {
  min-height: 280px;
}

#category-buttons,
#category-buttons * {
  user-select: none !important;
  -webkit-user-select: none !important;
  -moz-user-select: none !important;
  -ms-user-select: none !important;
  -khtml-user-select: none !important;
  -webkit-touch-callout: none !important;
}

#category-buttons button,
#category-buttons button * {
  user-select: none !important;
  -webkit-user-select: none !important;
  -moz-user-select: none !important;
  -ms-user-select: none !important;
  -khtml-user-select: none !important;
  -webkit-touch-callout: none !important;
}

#category-buttons button::selection,
#category-buttons button::-moz-selection {
  background: transparent !important;
  color: inherit !important;
}

.adm-cat-btn {
  transition: all 0.2s ease;
  font-weight: 600;
  user-select: none !important;
  -webkit-user-select: none !important;
  -moz-user-select: none !important;
  -ms-user-select: none !important;
}

.adm-cat-btn:hover {
  background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%) !important;
  border-color: var(--primary) !important;
  transform: translateX(4px);
  box-shadow: 0 2px 8px rgba(3, 122, 63, 0.15);
}

#adm-img-preview { display:block; margin-top:8px; text-align:center; }
#adm-img-preview img { max-width:100%; max-height:150px; border-radius:8px; border:1px solid #e2e8f0; }
#adm-preview-img { max-width:100%; max-height:140px; object-fit:contain; display:block; margin:0 auto; }

#adm-preview-title { font-weight:800; font-size:15px; }
#adm-preview-binding { color: #64748b; font-size:13px; }

#adm-cat-select, #adm-binding-select, #adm-margin-val, #adm-img-url {
  padding:8px 10px;
  border-radius:8px;
  border:1px solid #e2e8f0;
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
}

#adm-cat-select:focus, #adm-binding-select:focus, 
#adm-margin-val:focus, #adm-img-url:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(3, 122, 63, 0.1);
}

.card .btn { border-radius:10px; }

/* 개인결제 링크 폼: 메인 영역 너비 제한 + 가운데 정렬 */
#payment-link-form {
  max-width: 640px !important;
  width: 100% !important;
  box-sizing: border-box;
  margin-left: auto !important;
  margin-right: auto !important;
}

/* 개인결제 링크 폼 하단 버튼: 가로로 늘어나지 않고 텍스트 너비만 사용 */
#payment-link-form-actions .btn {
  flex: 0 0 auto;
  width: max-content;
  min-width: 0;
}

@media (max-width: 980px) {
  /* 관리자 화면을 한열로 정렬하여 모바일에서 편집 용이 */
  #adm-content .container, #adm-content .admin-editor-wrap { width:100%; }
}

/* 가벼운 유틸 */
.admin-small { font-size:12px; color:#64748b; }

/* 관리자 패널 기본 숨김 (JavaScript 로드 전까지) */
#admin-panel {
  display: none;
}

/* ========== 견적 옵션 폼 크기 축소 ========== */
/* 섹션 박스 패딩 축소 */
#indigo-quote-form #cat-binding-wrap,
#indigo-quote-form #ind-area-binding-direction,
#indigo-quote-form #ind-area-cover,
#indigo-quote-form #ind-area-inner {
  padding: 10px 12px !important;
}
/* 섹션 제목 마진 축소 */
#indigo-quote-form #cat-binding-wrap > label,
#indigo-quote-form #ind-area-binding-direction > label {
  margin-bottom: 8px !important;
  font-size: 13px !important;
}
#indigo-quote-form #ind-area-cover > div:first-child,
#indigo-quote-form #ind-area-inner > div:first-child {
  margin-bottom: 8px !important;
}
/* 제본방식·제본방향 버튼 패딩·아이콘 축소 */
#indigo-quote-form .cat-binding-btn,
#indigo-quote-form .binding-dir-btn {
  padding: 8px 10px !important;
  min-width: 90px !important;
  gap: 7px !important;
}
/* 제본 방향 버튼 행: 중앙 정렬 + 간격 확대 + 텍스트 줄바꿈 방지 */
#ind-area-binding-direction > div {
  justify-content: center !important;
  gap: 18px !important;
}
#indigo-quote-form .binding-dir-btn > span:last-of-type {
  white-space: nowrap !important;
}
#indigo-quote-form .cat-binding-btn .cat-type-icon svg,
#indigo-quote-form .binding-dir-btn svg {
  width: 26px !important;
  height: 26px !important;
}
/* 인쇄(단면/양면) 버튼 */
#indigo-quote-form .print-side-btn {
  padding: 10px 10px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}
#indigo-quote-form .print-side-btn > span {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
}
#indigo-quote-form .print-side-btn .cat-type-icon svg,
#indigo-quote-form .print-side-btn svg {
  width: 26px !important;
  height: 26px !important;
}
/* 컬러/흑백, 코팅 버튼 */
#indigo-quote-form .print-color-btn,
#indigo-quote-form .coating-btn {
  padding: 8px 10px !important;
}
/* 표지·내지 버튼 폰트 통일 (인라인 스타일 override) */
#indigo-quote-form .print-btn-label {
  font-size: 14px !important;
  font-weight: 700 !important;
}
#indigo-quote-form .print-color-btn .print-btn-label {
  font-size: 13px !important;
}
#indigo-quote-form .coating-btn-label {
  font-size: 13px !important;
  font-weight: 700 !important;
}
/* 표지·내지 내부 label 폰트 통일 */
#ind-area-cover label,
#ind-area-inner label {
  font-size: 12px !important;
}
/* 표지·내지 내부 소-섹션 마진 축소 */
#ind-area-cover > div,
#ind-area-inner > div {
  margin-bottom: 10px !important;
}
/* 표지 제목 wrapper(첫번째 div): 마진은 인라인 스타일(14px)이 이미 있으므로 override 제거 */
#ind-area-cover > div:first-child {
  margin-bottom: 14px !important;
}
/* 인쇄 섹션 버튼 행 간격 축소 */
#ind-area-cover > div > div > div,
#ind-area-inner > div > div > div {
  margin-bottom: 6px !important;
}
/* 섹션 구분 여백 축소 */
#indigo-quote-form > div > div:first-child {
  padding-bottom: 12px !important;
  margin-bottom: 12px !important;
}
#indigo-quote-form > div > div:nth-child(2) {
  padding-bottom: 12px !important;
  margin-bottom: 12px !important;
}

/* ========== 견적 상품 이미지: 회색 틀 중앙 정렬, 태두리(여백) 축소 ========== */
#view-quotation .quote-product-img-wrap {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}
#view-quotation #quote-indigo-img {
  object-fit: contain !important;
  object-position: center center !important;
  display: block;
}
#view-quotation > div > div > div:first-child > div {
  max-width: 280px;
  margin-left: auto;
  margin-right: auto;
  padding: 8px;
  box-sizing: border-box;
}
#view-quotation .img-placeholder {
  padding: 8px;
  box-sizing: border-box;
  align-items: center !important;
  justify-content: center !important;
}

/* 사이즈 입력: 숫자·×·mm 세로 정렬 */
.size-dim-group {
  display: flex;
  align-items: center;
  gap: 4px;
}
.size-dim-x {
  display: inline-flex;
  align-items: center;
  line-height: 1;
  flex-shrink: 0;
}

/* 제본방향 안내 물음표 (클릭 시 팝오버) */
.binding-direction-help {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  margin-left: 6px;
  border-radius: 50%;
  background: #94a3b8;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  cursor: help;
  flex-shrink: 0;
  user-select: none;
}
.binding-direction-help:hover {
  background: #64748b;
}

/* 제본방향 호버 툴팁 컨테이너 */
.binding-direction-help-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
}
.binding-direction-tooltip {
  display: none;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: calc(100% + 8px);
  width: max-content;
  max-width: min(360px, calc(100vw - 24px));
  padding: 12px 14px;
  background: #1e293b;
  color: #f1f5f9;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.5;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  z-index: 10000;
  pointer-events: none;
  box-sizing: border-box;
}
.binding-direction-tooltip .binding-tt-title {
  font-weight: 700;
  font-size: 14px;
  margin-bottom: 6px;
}
.binding-direction-tooltip .binding-tt-text {
  margin-bottom: 10px;
}
.binding-direction-tooltip img {
  max-width: 100%;
  height: auto;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,0.2);
}

/* 제본방향 호버 툴팁: 모바일에서 화면 안쪽으로, 넘치지 않게 */
@media (max-width: 768px) {
  .binding-direction-tooltip {
    position: fixed;
    left: 12px;
    right: 12px;
    width: calc(100vw - 24px);
    max-width: calc(100vw - 24px);
    bottom: auto;
    top: 50%;
    transform: translateY(-50%);
    max-height: min(85vh, 480px);
    overflow-y: auto;
    box-sizing: border-box;
    -webkit-overflow-scrolling: touch;
  }
  .binding-direction-help-popover {
    max-width: calc(100vw - 24px) !important;
    max-height: 85vh !important;
  }
}

/* 작업사이즈 설명 아이콘 (동그라미 물음표) + 호버 툴팁 - 전역 적용 */
.work-size-help {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  margin-left: 6px;
  border-radius: 50%;
  background: #94a3b8;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  cursor: help;
  flex-shrink: 0;
  position: relative;
}
.work-size-help:hover::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: calc(100% + 8px);
  width: max-content;
  max-width: min(520px, calc(100vw - 24px));
  padding: 12px 14px;
  background: #1e293b;
  color: #f1f5f9;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.6;
  border-radius: 8px;
  white-space: pre-line;
  word-break: keep-all;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
  z-index: 10000;
  pointer-events: none;
}
.work-size-help:hover::before {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: calc(100% + 2px);
  border: 6px solid transparent;
  border-top-color: #1e293b;
  z-index: 10001;
  pointer-events: none;
}

/* 모바일: 툴팁을 화면 안쪽에 고정해 잘리지 않게 표시 */
@media (max-width: 768px) {
  .work-size-help:hover::after,
  .work-size-help:focus::after {
    position: fixed !important;
    left: 12px !important;
    right: 12px !important;
    width: calc(100vw - 24px) !important;
    max-width: calc(100vw - 24px) !important;
    top: 50% !important;
    bottom: auto !important;
    transform: translateY(-50%) !important;
    margin: 0 !important;
    box-sizing: border-box !important;
    max-height: 70vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  .work-size-help:hover::before,
  .work-size-help:focus::before {
    display: none;
  }
  /* 터치로 툴팁 보이게 하기 위해 포커스 가능 + 터치 영역 (살짝만 크게) */
  .work-size-help {
    position: relative;
    min-width: 34px;
    min-height: 34px;
    width: 34px;
    height: 34px;
    font-size: 13px;
  }
}
/* 주문내역 재주문 안내 툴팁: 문장 단위로만 줄바꿈되도록 박스 넓힘 */
.order-reorder-help:hover::after {
  width: 420px;
  max-width: min(420px, calc(100vw - 24px));
  word-break: keep-all;
}

/* 수량: 데스크톱에서 한 줄 (수량 라벨 + -/input/+ + +1부 +10부 +100부) */
.qty-control-wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.qty-control-wrap .qty-main-row {
  margin-bottom: 0;
}

/* ========== 모바일 대응 (견적·공통) ========== */
@media (max-width: 768px) {
  /* 견적 화면: 3열 → 1열, 오른쪽 넘침 방지 */
  #view-quotation {
    overflow-x: hidden;
    max-width: 100%;
  }
  #view-quotation > div {
    padding: 12px !important;
    max-width: 100% !important;
    box-sizing: border-box;
  }
  #view-quotation > div > div {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 16px;
    max-width: 100% !important;
    min-width: 0;
  }
  #view-quotation > div > div > div:first-child,
  #view-quotation > div > div > div:nth-child(2),
  #view-quotation > div > div > div:last-child {
    min-width: 0;
    max-width: 100%;
  }
  /* 상품 이미지(썸네일): 뷰포트 안에 맞춤, 오른쪽 넘침 방지 */
  #view-quotation > div > div > div:first-child > div {
    max-width: min(320px, 100%) !important;
    width: 100% !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding: 6px !important;
    box-sizing: border-box;
  }
  #view-quotation .quote-product-img-wrap {
    max-width: 100% !important;
    overflow: hidden;
  }
  #view-quotation .img-placeholder,
  #view-quotation #quote-indigo-img {
    max-height: 280px;
    aspect-ratio: 1 / 1;
  }
  #view-quotation .img-placeholder {
    padding: 6px !important;
  }
  #view-quotation #quote-indigo-img {
    padding: 0 !important;
    object-fit: contain;
    max-width: 100%;
  }
  /* 견적 폼 영역: 너비 제한으로 넘침 방지 */
  #indigo-quote-form {
    min-width: 0;
    max-width: 100%;
    overflow-x: hidden;
  }
  #indigo-quote-form > div {
    max-width: 100%;
    min-width: 0;
  }
  /* 제본 방향 버튼: 2열 그리드로 배치, 오버플로우 방지 */
  #ind-area-binding-direction > div {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
    width: 100% !important;
  }
  #ind-area-binding-direction .binding-dir-btn {
    min-width: 0 !important;
    width: 100% !important;
    flex: none !important;
    padding: 10px 8px !important;
  }
  #ind-area-binding-direction .binding-dir-btn svg {
    width: 28px !important;
    height: 28px !important;
    flex-shrink: 0;
  }
  #ind-area-binding-direction .binding-dir-btn span {
    font-size: 12px !important;
  }
  /* 중철/무선, 소량/대량 버튼: 2열 그리드 (display는 JS가 none/flex 제어하므로 !important 사용 안 함) */
  #cat-binding-buttons.cat-type-buttons,
  #cat-quantity-buttons.cat-type-buttons {
    flex-wrap: wrap;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    width: 100%;
  }
  .cat-type-btn {
    min-width: 0 !important;
    width: 100% !important;
    flex: none !important;
  }
  /* 견적 요약/배송/파일 영역: sticky 해제, 전체 너비 */
  #view-quotation > div > div > div:last-child {
    position: static !important;
    top: auto !important;
  }
  /* 표지/내지: 2열 → 1열 */
  #ind-paper-print-container {
    grid-template-columns: 1fr !important;
    gap: 16px !important;
  }
  #ind-paper-print-divider {
    width: 100% !important;
    height: 1px !important;
    min-height: 1px !important;
  }
  /* 견적 계산하기 버튼: 모바일에서 중앙 정렬 */
  #view-quotation .quote-calc-btn-wrap {
    display: flex !important;
    justify-content: center !important;
  }
  /* 터치하기 좋은 버튼/입력 높이 */
  #view-quotation button,
  #view-quotation select,
  #view-quotation input[type="number"],
  #view-quotation input[type="text"] {
    min-height: 44px;
    font-size: 16px !important; /* iOS 줌 방지 */
  }
  #view-quotation .btn {
    min-height: 48px;
    padding: 14px 16px !important;
  }
  /* 수량: 모바일에서 두 줄로 쌓고, +1/+10/+100 부는 동일 너비 그리드 */
  #indigo-quote-form .qty-control-wrap {
    flex-direction: column;
    align-items: flex-start;
  }
  #indigo-quote-form .qty-main-row {
    margin-bottom: 8px;
  }
  #indigo-quote-form .qty-quick-row {
    margin-left: 0 !important;
    margin-top: 4px;
    display: grid !important;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 6px;
    width: 100%;
    max-width: 100%;
  }
  #indigo-quote-form .qty-quick-btn {
    min-width: 0;
  }
  /* 기본 사양: 라벨·입력 줄바꿈 가능 */
  #indigo-quote-form > div > div[style*="display:flex"],
  #indigo-quote-form div[style*="align-items:center"][style*="gap:12px"] {
    flex-wrap: wrap !important;
    gap: 8px !important;
  }
  #indigo-quote-form label[style*="min-width:60px"],
  #indigo-quote-form label[style*="min-width:70px"] {
    min-width: 0 !important;
    width: 100%;
  }
  /* 사이즈/작업사이즈 행은 한 줄 유지, 라벨 너비 복구 */
  #size-cutting-container,
  #size-working-container {
    flex-wrap: nowrap !important;
  }
  #size-cutting-container label.size-row-label,
  #size-working-container label.size-row-label {
    width: 80px !important;
    min-width: 80px !important;
  }
  /* 제본방향: 물음표 터치 영역 (줄바꿈은 위에서 flex-wrap: wrap으로 처리) */
  #ind-area-binding-direction .binding-direction-help-wrap {
    flex-shrink: 0 !important;
    min-width: 34px;
  }
  #ind-area-binding-direction .binding-direction-help {
    width: 30px !important;
    height: 30px !important;
    min-width: 30px !important;
    min-height: 30px !important;
    font-size: 13px !important;
  }
  #indigo-quote-form select,
  #indigo-quote-form input[type="number"] {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  /* 사이즈/작업사이즈 숫자칸은 고정 너비 유지 */
  #ind-size-width, #ind-size-height,
  #ind-size-working-width, #ind-size-working-height {
    width: 70px !important;
    max-width: 70px !important;
  }
  #indigo-quote-form .qty-buttons-row {
    flex-wrap: wrap;
  }
}

@media (max-width: 480px) {
  #view-quotation > div {
    padding: 8px;
  }
  #view-quotation > div > div > div:first-child > div {
    max-width: 280px !important;
    padding: 4px !important;
  }
  #view-quotation .img-placeholder,
  #view-quotation #quote-indigo-img {
    max-height: 260px;
  }
  #view-quotation .img-placeholder {
    padding: 4px !important;
  }
  /* 배송 주소/파일 섹션 버튼 그룹 줄바꿈 */
  #quote-delivery-section > div > div:first-child,
  #quote-file-section button {
    flex-wrap: wrap;
  }
  /* 중철/무선 버튼: 더 작은 패딩, 아이콘 축소 */
  .cat-type-btn {
    padding: 10px 8px !important;
    font-size: 12px !important;
  }
  .cat-type-btn .cat-type-icon svg {
    width: 24px !important;
    height: 24px !important;
  }
  /* 제본 방향: 아이콘·텍스트 더 축소 */
  #ind-area-binding-direction .binding-dir-btn {
    padding: 8px 6px !important;
    gap: 6px !important;
  }
  #ind-area-binding-direction .binding-dir-btn svg {
    width: 24px !important;
    height: 24px !important;
  }
  #ind-area-binding-direction .binding-dir-btn span {
    font-size: 11px !important;
  }
}

/* 720px 이하: 카테고리 3열×2줄, 견적 화면·썸네일 넘침 방지 */
@media (max-width: 720px) {
  body {
    overflow-x: hidden;
  }
  .container {
    max-width: 100% !important;
    width: 100%;
    overflow-x: hidden;
    padding: 12px !important;
    box-sizing: border-box;
  }

  /* 홈 화면: 오버플로우 방지 */
  #view-home,
  .home-grid {
    max-width: 100% !important;
    width: 100% !important;
    overflow-x: hidden !important;
    box-sizing: border-box !important;
  }
  .home-row {
    display: none !important;
    max-width: 100% !important;
    width: 100% !important;
    padding: 0 8px !important;
    box-sizing: border-box !important;
  }
  .home-row .hero-left {
    width: 100% !important;
    margin-bottom: 12px;
  }
  .home-row > div:last-child {
    width: 100% !important;
    max-width: 100% !important;
  }
  /* 로그인 카드 */
  .home-login-card {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
  .home-login-card .card-body {
    padding: 12px !important;
    box-sizing: border-box !important;
  }
  /* 로그인 폼 입력창 */
  .home-login-card input[type="text"],
  .home-login-card input[type="password"] {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }
  /* 로그인 버튼 */
  .home-login-card .btn {
    width: 100% !important;
    box-sizing: border-box !important;
  }
  /* 바로가기 아이콘 (장바구니, 주문조회, 견적문의) */
  .home-shortcuts {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 6px !important;
    width: 100% !important;
  }
  .home-shortcuts .sc {
    padding: 8px 2px !important;
  }
  .home-shortcuts .stxt {
    font-size: 10px !important;
  }
  .home-shortcuts .sico {
    font-size: 16px !important;
  }
  /* 공지사항 */
  .home-notice {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
  }
  .notice-head {
    padding: 6px 12px !important;
  }
  .notice-head .ttl {
    font-size: 11px !important;
  }
  .notice-head .more {
    font-size: 10px !important;
  }
  .notice-list {
    padding: 10px 12px !important;
  }
  /* 견적 화면 전체·썸네일·설정 칸 뷰포트 안으로 */
  #view-quotation {
    overflow-x: hidden;
    max-width: 100%;
  }
  #view-quotation > div,
  #view-quotation > div > div {
    max-width: 100% !important;
    min-width: 0;
  }
  #view-quotation > div > div > div:first-child > div {
    max-width: min(300px, 100%) !important;
    width: 100% !important;
  }
  #indigo-quote-form {
    min-width: 0;
    max-width: 100%;
  }
  /* 중철/무선, 소량/대량 버튼: 2열 그리드 (display는 JS가 none/flex로 제어) */
  #cat-binding-buttons.cat-type-buttons,
  #cat-quantity-buttons.cat-type-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    width: 100%;
  }
  .cat-type-btn {
    min-width: 0 !important;
    width: 100% !important;
  }
  /* 제본 방향 버튼: 2열 그리드 */
  #ind-area-binding-direction > div {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
    width: 100% !important;
  }
  #ind-area-binding-direction .binding-dir-btn {
    min-width: 0 !important;
    width: 100% !important;
    padding: 12px 10px !important;
  }
  .header,
  .header-bottom {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: auto;
    box-sizing: border-box;
  }
  .header-bottom .cat-nav-grid {
    flex-wrap: wrap !important;
    justify-content: center;
    gap: 6px 10px !important;
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 6px 10px 8px !important;
    box-sizing: border-box;
  }
  .cat-menu-row { gap: 6px 10px !important; }
  .cat-nav-col { min-width: 0 !important; }
  .header-bottom .cat-link,
  .header-bottom .cat-tab-btn,
  .cat-nav-col .cat-tab-btn,
  .cat-menu-row .cat-nav-col .cat-tab-btn {
    padding: 8px 12px !important;
    font-size: 14px !important;
    white-space: nowrap !important;
    line-height: 1.25 !important;
    min-height: 40px;
    align-items: center;
    justify-content: center;
    text-align: center;
  }
  .cat-dropdown-content a {
    font-size: 12px !important;
    padding: 5px 0 !important;
  }
  .header-bottom:hover .cat-dropdown-content {
    padding: 10px 0 !important;
  }
}

/* 모바일: 카테고리 3열×2줄, 오른쪽 넘침 방지 */
@media (max-width: 560px) {
  body {
    overflow-x: hidden;
  }
  .header,
  .header-bottom {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: auto;
    box-sizing: border-box;
  }
  .header-bottom .cat-nav-grid {
    flex-wrap: wrap !important;
    justify-content: center;
    gap: 6px 10px !important;
    padding: 6px 10px 8px !important;
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
    box-sizing: border-box;
  }
  .cat-menu-row { gap: 6px 10px !important; }
  .header-bottom .cat-link,
  .header-bottom .cat-tab-btn,
  .cat-nav-col .cat-tab-btn,
  .cat-menu-row .cat-nav-col .cat-tab-btn {
    padding: 8px 12px !important;
    font-size: 14px !important;
    white-space: nowrap !important;
    line-height: 1.25 !important;
    min-height: 40px;
    align-items: center;
    justify-content: center;
    text-align: center;
  }
  .cat-dropdown-content a {
    font-size: 11px !important;
    padding: 4px 0 !important;
  }
  .header-bottom:hover .cat-dropdown-content {
    padding: 8px 0 !important;
  }
}

/* 아주 좁은 화면(휴대폰): 3열 유지, 오른쪽 넘침 방지 */
@media (max-width: 420px) {
  body {
    overflow-x: hidden;
  }
  .header,
  .header-bottom {
    width: 100% !important;
    max-width: 100% !important;
    overflow-x: auto;
    box-sizing: border-box;
  }
  .header-bottom .cat-nav-grid {
    flex-wrap: wrap !important;
    justify-content: center;
    gap: 6px 8px !important;
    padding: 6px 8px 8px !important;
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
  }
  .cat-menu-row { gap: 6px 8px !important; }
  .header-bottom .cat-link,
  .header-bottom .cat-tab-btn,
  .cat-nav-col .cat-tab-btn,
  .cat-menu-row .cat-nav-col .cat-tab-btn {
    padding: 8px 11px !important;
    font-size: 13.5px !important;
    white-space: nowrap !important;
    line-height: 1.25 !important;
  }
  .cat-dropdown-content a {
    font-size: 9px !important;
    padding: 3px 0 !important;
  }
  .header-bottom:hover .cat-dropdown-content {
    padding: 6px 0 !important;
  }
}

/* 배너 슬라이드 오버레이: 좁은 화면에서 비율·가독성 */
@media (max-width: 640px) {
  .home-row .home-slider {
    min-height: 0 !important;
    height: auto !important;
    background: #f8fafc;
  }
  .home-row .home-slider .home-slide img {
    width: 100% !important;
    height: auto !important;
    object-fit: contain !important;
    background: #f8fafc;
  }
  .home-slide-text {
    left: 10px;
    bottom: 10px;
    max-width: 85%;
    z-index: 3;
    text-shadow: 0 1px 4px rgba(0,0,0,0.6);
  }
  .home-slide-text h2 {
    font-size: 16px;
    line-height: 1.3;
  }
  .home-slide-text p {
    font-size: 11px;
    margin-top: 4px;
  }
  .home-slide-text .home-slide-tags,
  .home-slide-overlay [style*="display:flex"],
  .home-slide-overlay [style*="gap"] {
    gap: 4px !important;
  }
  .home-slide-overlay .btn,
  .home-slide-overlay [class*="tag"],
  .home-slide-overlay span[style*="padding"] {
    padding: 5px 8px !important;
    font-size: 11px !important;
  }
}

/* 모바일: 네비·헤더 등 공통 */
@media (max-width: 768px) {
  .main-content {
    padding-left: 0;
    padding-right: 0;
  }
}

/* 좁은 화면: 글자를 줄이지 않고 네비를 둘째 줄로 내려 터치 영역을 확보 */
@media (max-width: 720px) {
  .header-top {
    padding: 6px 12px 8px 12px;
    gap: 8px;
  }
  #brand-logo {
    height: 44px !important;
    width: auto !important;
  }
  .top-nav,
  #nav-links {
    gap: 4px !important;
  }
  .top-nav a,
  #nav-links a {
    font-size: 13px !important;
    padding: 8px 6px !important;
    min-height: 36px;
    box-sizing: border-box;
  }
  .top-nav .nav-cart { gap: 4px !important; }
  .cart-badge {
    font-size: 10px;
    padding: 2px 5px;
    min-width: 16px;
  }
}

@media (max-width: 560px) {
  .header-top {
    padding: 8px 12px;
    gap: 4px;
  }
  #brand-logo {
    height: 36px !important;
    width: auto !important;
  }
  .top-nav,
  #nav-links {
    flex-basis: 100%;
    justify-content: flex-end;
    gap: 0 !important;
    margin-left: 0;
  }
  .top-nav a,
  #nav-links a {
    font-size: 13px !important;
    padding: 10px 8px !important;
    min-height: 40px;
  }
  .cart-badge {
    font-size: 10px;
    padding: 2px 6px;
    min-width: 16px;
  }
  #cart-list > div {
    flex-wrap: wrap !important;
  }
  #cart-list > div > div:first-child,
  #cart-list > div > div:last-child {
    flex: 1 1 100% !important;
    min-width: 100% !important;
  }
  #cart-list > div > div:last-child {
    margin-left: 0 !important;
    flex: 1 1 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed #e2e8f0;
    text-align: left !important;
  }
  #cart-benefits {
    flex-wrap: wrap !important;
  }
  #cart-benefits > div {
    border-left: none !important;
  }
  #ct-prepaid-row > div:last-of-type,
  #ct-points-row > div:last-of-type {
    flex-wrap: wrap;
  }
}

@media (max-width: 420px) {
  .header-top {
    padding: 8px 10px;
  }
  .top-nav a,
  #nav-links a {
    font-size: 12px !important;
    padding: 10px 6px !important;
  }
}

@media (max-width: 640px) {
  input[type="text"],
  input[type="tel"],
  input[type="email"],
  input[type="password"],
  input[type="search"],
  input[type="number"],
  select,
  textarea {
    font-size: 16px !important;
  }
}

/* 견적 폼 버튼식 선택 스타일 (제본 방향·제본 방식 동일 박스 스타일) */
.binding-dir-btn, .print-side-btn, .print-color-btn, .cat-binding-btn {
  transition: all 0.15s ease;
}
.binding-dir-btn:hover, .print-side-btn:hover, .print-color-btn:hover, .cat-binding-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.binding-dir-btn.active, .print-side-btn.active, .print-color-btn.active, .cat-binding-btn.active {
  box-shadow: 0 2px 8px rgba(0,102,204,0.15);
}

/* 모바일: 푸터 하단 중앙 정렬·여백 */
@media (max-width: 768px) {
  footer {
    padding: 24px 0 !important;
  }
  footer > div {
    padding-left: 16px !important;
    padding-right: 16px !important;
    max-width: 100% !important;
    box-sizing: border-box;
  }
  footer > div > div:first-child {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 28px !important;
    max-width: 100% !important;
    margin-left: auto !important;
    margin-right: auto !important;
    justify-items: stretch !important;
    text-align: center !important;
  }
  footer > div > div:first-child > div {
    text-align: center !important;
  }
  footer > div > div:first-child > div p,
  footer > div > div:first-child > div div {
    justify-content: center !important;
  }
  footer > div > div:nth-child(2) {
    text-align: center !important;
  }
  footer > div > div:nth-child(3) {
    text-align: center !important;
    font-size: 12px !important;
  }
  footer > div > div:nth-child(3) p {
    margin: 4px 0 !important;
  }
  footer > div > div:nth-child(3) > p:last-of-type {
    flex-direction: column !important;
    align-items: center !important;
    gap: 8px !important;
  }
}

@media (max-width: 480px) {
  footer > div {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }
}

/* ===== 견적 폼 드롭박스 & 버튼 스타일 개선 ===== */

/* 드롭박스 공통 스타일 */
#indigo-quote-form select {
  padding: 12px 14px !important;
  border: 1px solid #d1d5db !important;
  border-radius: 8px !important;
  background: #fff !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  color: #1e293b !important;
  cursor: pointer;
  transition: all 0.2s ease;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 12px center !important;
  padding-right: 36px !important;
}

#indigo-quote-form select:hover {
  border-color: var(--primary) !important;
  background-color: #f8fafc !important;
}

#indigo-quote-form select:focus {
  outline: none !important;
  border-color: var(--primary) !important;
  box-shadow: 0 0 0 3px rgba(3, 122, 63, 0.1) !important;
}

/* 숨겨진 select는 스타일 제외 */
#indigo-quote-form select[style*="display:none"],
#indigo-quote-form select[style*="display: none"] {
  padding: 0 !important;
  border: none !important;
  background: transparent !important;
}

/* 인쇄 버튼 통일 스타일 */
.print-side-btn,
.print-color-btn {
  min-height: 70px !important;
  transition: all 0.2s ease !important;
  margin: 0;
}

.print-side-btn:hover,
.print-color-btn:hover,
.coating-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* 양면/단면: 아이콘·글자 세로·가로 중앙 정렬 */
.print-side-btn {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

.print-side-btn > span {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 12px;
  margin: 0;
  padding: 0;
}

.print-side-btn svg {
  display: block !important;
  flex-shrink: 0;
  margin: 0;
  vertical-align: middle;
}

.print-side-btn .print-btn-label {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: 36px;
  line-height: 1 !important;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* 디지털 흑백 버튼: 색깔(아이콘) 왼쪽·글자 오른쪽 가로 배치, 버튼 너비에 따라 글자 크기 자동 조절 */
.print-color-btn-toner {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  container-type: inline-size;
  container-name: toner-btn;
}
/* 전단지·리플렛·명함에서는 디지털 흑백 버튼 비노출 (책자에서만 사용) */
body.quote-single-sheet #ind-inner-print-toner-btn {
  display: none !important;
}
/* 코팅 버튼 행: 줄바꿈 방지 + 균등 배분 */
#ind-area-cover div:has(> .coating-btn) {
  flex-wrap: nowrap !important;
  gap: 6px !important;
}
#ind-area-cover .coating-btn {
  min-width: 0 !important;
  flex: 1 1 0 !important;
  padding: 8px 6px !important;
}
/* 내지 컬러 선택: 디지털 흑백 버튼을 단독 두 번째 행으로 */
div:has(> #ind-inner-print-toner-btn) {
  flex-wrap: wrap !important;
}
#ind-inner-print-toner-btn {
  flex: 1 0 100% !important;
}
@container toner-btn (max-width: 140px) {
  .print-color-btn-toner .print-btn-label-toner { font-size: 11px !important; }
}
@container toner-btn (max-width: 120px) {
  .print-color-btn-toner .print-btn-label-toner { font-size: 10px !important; }
}
@container toner-btn (max-width: 100px) {
  .print-color-btn-toner .print-btn-label-toner { font-size: 9px !important; }
}

/* 제본 방향 버튼 */
.binding-dir-btn {
  transition: all 0.2s ease !important;
}

.binding-dir-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* 라벨 스타일 */
#indigo-quote-form label {
  font-size: 13px !important;
  font-weight: 700 !important;
  color: #475569 !important;
}

#popup-notice-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.48);
  z-index: 2990;
}
.popup-notice-win .popup-seq {
  font-size: 12px;
  font-weight: 700;
  color: #64748b;
}
.popup-notice-win .popup-next-btn {
  background: #037a3f !important;
  color: #fff !important;
}
.popup-notice-win .popup-close-all-btn {
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 700;
  background: #e2e8f0;
  color: #334155;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  min-height: 40px;
}

@media (max-width: 640px) {
  #popup-notice-window.popup-notice-win,
  [id^="popup-notice-window-"] {
    left: 16px !important;
    right: 16px !important;
    top: 50% !important;
    bottom: auto !important;
    transform: translateY(-50%);
    width: auto !important;
    min-width: 0 !important;
    max-width: calc(100vw - 32px) !important;
    max-height: calc(100vh - 32px) !important;
    overflow: auto !important;
    border-radius: 14px !important;
    z-index: 3000 !important;
  }
  #popup-notice-window img,
  [id^="popup-notice-window-"] img,
  #notice-popup-modal img {
    max-width: 100% !important;
    height: auto !important;
  }
  [id^="popup-notice-window-"] > div:last-child .popup-close-btn {
    min-height: 40px;
    min-width: 72px;
    font-size: 14px !important;
    padding: 8px 14px !important;
  }
}

/* ── 관리자 탭바: 알록달록 제거 → 차분한 단색 + 현재 탭만 강조 ── */
#adm-tabbar .btn {
  background: #fff !important;
  color: #475569 !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: none !important;
  font-weight: 600 !important;
  flex: 0 1 auto !important;
  min-width: 0 !important;
  padding: 9px 16px !important;
  border-radius: 8px !important;
  font-size: 14px !important;
  transition: background .12s, color .12s, border-color .12s;
}
#adm-tabbar .btn:hover {
  background: #f1f5f4 !important;
  color: #0f172a !important;
  border-color: #cbd5e1 !important;
}
#adm-tabbar .btn.adm-active {
  background: var(--home-primary, #037a3f) !important;
  color: #fff !important;
  border-color: var(--home-primary, #037a3f) !important;
}

/* ── 관리자 좌측 사이드바 레이아웃 ── */
#adm-tabbar {
  flex: 0 0 210px !important;
  flex-direction: column !important;
  flex-wrap: nowrap !important;
  gap: 4px !important;
  margin-bottom: 0 !important;
  position: sticky;
  top: 12px;
  align-self: flex-start;
}
#adm-tabbar .btn {
  width: 100% !important;
  display: block !important;
  text-align: left !important;
  flex: 0 0 auto !important;
}
#adm-tabbar .adm-nav-label {
  width: 100%;
  margin: 12px 0 3px;
  padding: 0 4px;
  color: #94a3b8;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .06em;
}
#adm-tabbar .adm-nav-label:first-child {
  margin-top: 0;
}
#adm-tabbar .btn.adm-nav-primary {
  border-color: #b7d8cc !important;
  background: #f4fbf8 !important;
  color: #0f3f32 !important;
  font-weight: 800 !important;
}
#adm-tabbar .btn.adm-nav-primary:hover {
  background: #e7f5ef !important;
  border-color: #8ec6b3 !important;
}
#adm-tabbar .btn.adm-nav-primary.adm-active,
#adm-tabbar .btn.adm-active {
  background: var(--home-primary, #037a3f) !important;
  color: #fff !important;
  border-color: var(--home-primary, #037a3f) !important;
}
#adm-main { width: 100%; }
@media (max-width: 820px) {
  #adm-shell { flex-direction: column !important; }
  #adm-tabbar {
    flex: 1 1 auto !important;
    width: 100%;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    position: static;
  }
  #adm-tabbar .btn { width: auto !important; display: inline-block !important; }
  #adm-tabbar .adm-nav-label {
    flex: 0 0 100%;
    margin-top: 10px;
  }
}

/* ── 관리자 주문 상태 카드: 큰 색동 원형 → 차분한 플랫 카드 ── */
.adm-stat {
  flex: 1 1 120px;
  min-width: 120px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 14px 16px;
  cursor: pointer;
  transition: box-shadow .15s, border-color .15s, transform .12s;
}
.adm-stat:hover {
  border-color: #cbd5e1;
  box-shadow: 0 4px 14px rgba(0,0,0,0.07);
  transform: translateY(-1px);
}
.adm-stat-label {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  color: #64748b;
  font-weight: 600;
  margin-bottom: 8px;
}
.adm-stat-dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--c, #94a3b8);
  display: inline-block;
  flex: 0 0 auto;
}
.adm-stat-num {
  font-size: 24px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.1;
}

/* ── 조회기간 버튼: 무지개 → 뉴트럴 통일 ── */
#admin-panel .adm-daterange .btn {
  background: #fff !important;
  color: #475569 !important;
  border: 1px solid #e2e8f0 !important;
  font-weight: 600 !important;
}
#admin-panel .adm-daterange .btn:hover {
  background: #f1f5f4 !important;
  color: #0f172a !important;
}

/* ── 주문 액션 툴바: 무지개 → 평평한 뉴트럴(파괴적 동작만 빨강) ── */
.adm-toolbar .btn {
  background: #fff !important;
  color: #475569 !important;
  border: 1px solid #e2e8f0 !important;
  padding: 8px 14px !important;
  border-radius: 8px !important;
  font-weight: 600 !important;
  font-size: 12px !important;
  cursor: pointer;
}
.adm-toolbar .btn:hover {
  background: #f1f5f4 !important;
  color: #0f172a !important;
  border-color: #cbd5e1 !important;
}
.adm-toolbar .btn.adm-danger {
  color: #dc2626 !important;
  border-color: #fecaca !important;
}
.adm-toolbar .btn.adm-danger:hover {
  background: #fef2f2 !important;
  color: #b91c1c !important;
}


/* ── 버튼 색 통일 규칙(전역): 동작 버튼은 무채색, 주요=초록, 위험=빨강만.
   상태 칩(span/div)·브랜드 마크는 버튼이 아니므로 영향 없음. ── */
button[style*="background:#7c3aed"],
button[style*="background: #7c3aed"],
button[style*="background:#8b5cf6"],
button[style*="background: #8b5cf6"],
button[style*="background:#a78bfa"],
button[style*="background: #a78bfa"],
button[style*="background:#0891b2"],
button[style*="background: #0891b2"],
button[style*="background:#06b6d4"],
button[style*="background: #06b6d4"],
button[style*="background:#3b82f6"],
button[style*="background: #3b82f6"],
button[style*="background:#2563eb"],
button[style*="background: #2563eb"],
button[style*="background:#6366f1"],
button[style*="background: #6366f1"],
button[style*="background:#0f766e"],
button[style*="background: #0f766e"],
button[style*="background:#0d9488"],
button[style*="background: #0d9488"],
button[style*="background:#f97316"],
button[style*="background: #f97316"],
button[style*="background:#f59e0b"],
button[style*="background: #f59e0b"],
button[style*="background:#667eea"],
button[style*="background: #667eea"],
button[style*="background:#6b5b95"],
button[style*="background: #6b5b95"],
button[style*="background:#8b4513"],
button[style*="background: #8b4513"],
button[style*="background:#0f7ba7"],
button[style*="background: #0f7ba7"] {
  background: #f2f1ee !important;
  color: #55524c !important;
  border: 1px solid #e3e1dc !important;
}
button[style*="background:#10b981"],
button[style*="background: #10b981"],
button[style*="background:#16a34a"],
button[style*="background: #16a34a"],
button[style*="background:#22c55e"],
button[style*="background: #22c55e"],
button[style*="background:#059669"],
button[style*="background: #059669"],
button[style*="background:#037a3f"],
button[style*="background: #037a3f"] {
  background: var(--home-primary, #2f6049) !important;
  color: #fff !important;
}
button[style*="background:#ef4444"],
button[style*="background: #ef4444"],
button[style*="background:#e11d48"],
button[style*="background: #e11d48"] {
  background: #fff !important;
  color: #dc2626 !important;
  border: 1.5px solid #efc7c7 !important;
}
/* 주문상세 모달 노란 강조 박스 톤 다운 */
div[style*="background:#fef3c7"], div[style*="background: #fef3c7"] {
  background: #faf7ee !important;
  border-color: #e8e2d0 !important;
}
