/* ── 도봉초등학교 총동문회 — Green Theme (site17 Feather Green 팔레트 적용) ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* Green palette — site17 Duolingo Feather Green 톤 (변수명은 호환 위해 유지) */
  --maple-red:      #34c00d;   /* vivid green (primary/buttons) */
  --maple-red-dk:   #1f8f06;   /* deep vivid green (text/heading) */
  --maple-orange:   #45c712;   /* 중간 그린 */
  --maple-yellow:   #62d61f;   /* 하이라이트 (덜 노랑) */
  --maple-red-lt:   #d3f2bd;   /* 연한 그린 wash */
  --maple-orange-lt:#dcf4c9;   /* 연한 그린 wash */
  --maple-yellow-lt:#e6f7cf;   /* 가장 연한 그린 */

  /* Semantic */
  --accent:    var(--maple-red);
  --accent-dk: var(--maple-red-dk);
  --accent-lt: var(--maple-red-lt);

  --bg:        #ffffff;
  --bg-soft:   #f6fbf1;          /* 따뜻한 크림 */
  --text:      #1c2417;
  --text-2:    #36402f;
  --text-3:    #566b50;
  --text-4:    #8a9a80;
  --border:    rgba(216, 90, 58, 0.10);
  --border-md: rgba(216, 90, 58, 0.18);
  --border-dark: rgba(0,0,0,0.12);
  --gray-50:   #f0f7e8;
  --gray-100:  #deefcb;
  --gray-200:  #cbe3ae;

  --red:       #d45656;
  --blue:      #3772cf;

  /* Gradient — 선명한 그린 (vivid green) */
  --grad-maple: linear-gradient(135deg, #2fbe0a 0%, #43c916 50%, #5cd628 100%);
  --grad-maple-soft: linear-gradient(to right, #d8f2c6 0%, #def4ce 28%, #e5f6d7 55%, #ebf8de 80%, #f0fae4 100%);
  --grad-hero-radial: radial-gradient(circle at 100% 0%, rgba(92,214,40,0.42) 0%, transparent 55%),
                      radial-gradient(circle at 0% 80%, rgba(47,190,10,0.26) 0%, transparent 55%);

  /* 질감 (texture) — 종이 입자감 + 색 블룸. SVG data URI에서 # 은 %23 로 escape 필수 */
  /* 곡선 줄무늬 (기본) — 부드러운 sine wave */
  --tex-grain-light: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 80' preserveAspectRatio='none'%3E%3Cg fill='none' stroke='%23ffffff' stroke-linecap='round'%3E%3Cpath d='M0 20 Q50 4 100 20 T200 20' stroke-width='1.2' opacity='.36'/%3E%3Cpath d='M0 40 Q50 56 100 40 T200 40' stroke-width='0.9' opacity='.30'/%3E%3Cpath d='M0 60 Q50 44 100 60 T200 60' stroke-width='1.1' opacity='.27'/%3E%3C/g%3E%3C/svg%3E");
  --tex-grain-dark: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 80' preserveAspectRatio='none'%3E%3Cg fill='none' stroke='%232d6e1f' stroke-linecap='round'%3E%3Cpath d='M0 20 Q50 4 100 20 T200 20' stroke-width='1.2' opacity='.30'/%3E%3Cpath d='M0 40 Q50 56 100 40 T200 40' stroke-width='0.9' opacity='.23'/%3E%3Cpath d='M0 60 Q50 44 100 60 T200 60' stroke-width='1.1' opacity='.36'/%3E%3C/g%3E%3C/svg%3E");

  /* 카드용 10종 무작위 곡선 패턴 — 카드 1장 전체를 비반복으로 덮음. 간격/방향/길이/굵기 모두 다양 */
  /* 1: 길게 이어지는 4선 (S 흐름) — 한 선이 좌→우로 흘러가며 위아래 굽이침 */
  --tex-curve-1: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 300' preserveAspectRatio='none'%3E%3Cg fill='none' stroke='%23ffffff' stroke-linecap='round'%3E%3Cpath d='M-20 60 Q80 20 150 80 Q220 140 280 60 Q340 -20 420 80' stroke-width='1.4' opacity='.36'/%3E%3Cpath d='M-20 200 Q60 240 140 180 Q220 120 320 220 Q380 280 420 200' stroke-width='1.1' opacity='.30'/%3E%3Cpath d='M50 320 Q80 250 30 180 Q-20 110 80 -20' stroke-width='0.9' opacity='.24'/%3E%3Cpath d='M380 -20 Q320 60 360 130 Q400 200 380 320' stroke-width='1.0' opacity='.27'/%3E%3C/g%3E%3C/svg%3E");
  /* 2: 흩어진 짧은 곡선 조각 9개 — 위치/각도 모두 무작위 */
  --tex-curve-2: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 300' preserveAspectRatio='none'%3E%3Cg fill='none' stroke='%23ffffff' stroke-linecap='round'%3E%3Cpath d='M30 60 Q70 30 110 80' stroke-width='1.3' opacity='.32'/%3E%3Cpath d='M170 30 Q210 70 250 40' stroke-width='1.0' opacity='.30'/%3E%3Cpath d='M280 90 Q320 50 370 100' stroke-width='1.1' opacity='.27'/%3E%3Cpath d='M50 160 Q100 130 130 180' stroke-width='0.9' opacity='.24'/%3E%3Cpath d='M200 190 Q240 150 290 200' stroke-width='1.0' opacity='.27'/%3E%3Cpath d='M340 170 Q380 140 410 195' stroke-width='0.8' opacity='.23'/%3E%3Cpath d='M70 250 Q120 290 180 240' stroke-width='1.2' opacity='.30'/%3E%3Cpath d='M210 280 Q260 240 320 285' stroke-width='1.0' opacity='.26'/%3E%3Cpath d='M340 250 Q380 290 410 240' stroke-width='0.9' opacity='.24'/%3E%3C/g%3E%3C/svg%3E");
  /* 3: 강줄기 + 가지 (river with branches) */
  --tex-curve-3: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 300' preserveAspectRatio='none'%3E%3Cg fill='none' stroke='%23ffffff' stroke-linecap='round'%3E%3Cpath d='M-20 150 Q100 100 200 160 Q300 220 420 140' stroke-width='1.6' opacity='.36'/%3E%3Cpath d='M70 130 Q60 90 90 50 Q120 10 90 -20' stroke-width='1.0' opacity='.27'/%3E%3Cpath d='M150 145 Q140 90 130 40 Q140 0 170 -20' stroke-width='0.9' opacity='.26'/%3E%3Cpath d='M250 195 Q260 240 240 290' stroke-width='1.0' opacity='.27'/%3E%3Cpath d='M340 175 Q360 220 340 280 Q320 320 380 320' stroke-width='1.1' opacity='.28'/%3E%3Cpath d='M180 155 Q200 200 180 250' stroke-width='0.8' opacity='.23'/%3E%3Cpath d='M50 145 Q20 110 50 80' stroke-width='0.8' opacity='.36'/%3E%3C/g%3E%3C/svg%3E");
  /* 4: 폭풍 — 대각선 카오스 */
  --tex-curve-4: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 300' preserveAspectRatio='none'%3E%3Cg fill='none' stroke='%23ffffff' stroke-linecap='round'%3E%3Cpath d='M-20 280 Q100 150 200 200 Q300 250 420 50' stroke-width='1.4' opacity='.36'/%3E%3Cpath d='M-20 50 Q150 200 280 100 Q380 30 420 200' stroke-width='1.2' opacity='.30'/%3E%3Cpath d='M50 -20 Q120 150 80 320' stroke-width='1.0' opacity='.27'/%3E%3Cpath d='M280 -20 Q220 100 350 200 Q400 250 420 320' stroke-width='1.1' opacity='.28'/%3E%3Cpath d='M-20 170 Q200 140 260 180' stroke-width='0.7' opacity='.23'/%3E%3Cpath d='M180 -20 Q170 60 230 100' stroke-width='0.9' opacity='.24'/%3E%3C/g%3E%3C/svg%3E");
  /* 5: S-curl 컬렉션 — 굽이굽이 도는 컬 5개 */
  --tex-curve-5: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 300' preserveAspectRatio='none'%3E%3Cg fill='none' stroke='%23ffffff' stroke-linecap='round'%3E%3Cpath d='M80 200 C 50 100 150 80 100 50 S 250 80 200 150' stroke-width='1.2' opacity='.32'/%3E%3Cpath d='M280 80 C 350 50 380 150 320 200 S 200 280 280 250' stroke-width='1.1' opacity='.30'/%3E%3Cpath d='M-20 100 C 50 80 100 130 80 200 S 200 250 250 230' stroke-width='1.0' opacity='.26'/%3E%3Cpath d='M150 -20 C 200 30 220 80 180 100' stroke-width='0.9' opacity='.24'/%3E%3Cpath d='M300 280 C 350 250 380 220 360 180' stroke-width='0.9' opacity='.24'/%3E%3C/g%3E%3C/svg%3E");
  /* 6: 연결된 지그재그 (single path zigzags) — 각진 듯 둥근 코너 */
  --tex-curve-6: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 300' preserveAspectRatio='none'%3E%3Cg fill='none' stroke='%23ffffff' stroke-linecap='round'%3E%3Cpath d='M-20 80 Q60 60 100 100 Q140 140 200 80 Q260 20 320 100 Q380 180 420 60' stroke-width='1.4' opacity='.36'/%3E%3Cpath d='M-20 220 Q80 180 140 240 Q200 280 280 200 Q360 130 420 250' stroke-width='1.1' opacity='.30'/%3E%3Cpath d='M30 -10 Q60 30 30 80 Q0 130 50 180 Q100 220 60 320' stroke-width='1.0' opacity='.27'/%3E%3Cpath d='M380 320 Q360 270 400 230 Q440 180 380 130' stroke-width='0.9' opacity='.24'/%3E%3C/g%3E%3C/svg%3E");
  /* 7: 거미줄/네트워크 — 곡선이 교차점에서 만남 */
  --tex-curve-7: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 300' preserveAspectRatio='none'%3E%3Cg fill='none' stroke='%23ffffff' stroke-linecap='round'%3E%3Cpath d='M50 50 Q150 100 250 60 Q350 30 420 80' stroke-width='1.2' opacity='.30'/%3E%3Cpath d='M150 100 Q160 180 80 230 Q30 270 -20 250' stroke-width='1.0' opacity='.27'/%3E%3Cpath d='M250 60 Q280 150 200 200' stroke-width='1.1' opacity='.28'/%3E%3Cpath d='M200 200 Q280 240 350 200 Q400 180 420 220' stroke-width='1.0' opacity='.26'/%3E%3Cpath d='M80 230 Q140 280 220 260' stroke-width='0.9' opacity='.24'/%3E%3Cpath d='M350 200 Q380 250 340 290 Q300 320 250 300' stroke-width='1.0' opacity='.27'/%3E%3Cpath d='M50 50 Q-20 80 -20 130' stroke-width='0.8' opacity='.23'/%3E%3Cpath d='M250 60 Q260 20 290 -20' stroke-width='0.8' opacity='.36'/%3E%3C/g%3E%3C/svg%3E");
  /* 8: 듬성한 세로 흐름 — 굵기/시작점 모두 다름 */
  --tex-curve-8: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 300' preserveAspectRatio='none'%3E%3Cg fill='none' stroke='%23ffffff' stroke-linecap='round'%3E%3Cpath d='M40 -10 Q50 80 30 150 Q10 220 60 320' stroke-width='1.3' opacity='.32'/%3E%3Cpath d='M120 -10 Q130 100 110 200' stroke-width='0.9' opacity='.24'/%3E%3Cpath d='M210 50 Q220 120 200 200 Q180 280 220 320' stroke-width='1.1' opacity='.28'/%3E%3Cpath d='M310 -10 Q330 80 290 160 Q250 230 310 320' stroke-width='1.0' opacity='.27'/%3E%3Cpath d='M380 100 Q400 200 360 320' stroke-width='0.8' opacity='.23'/%3E%3Cpath d='M70 200 Q100 250 80 320' stroke-width='0.9' opacity='.24'/%3E%3Cpath d='M170 -10 Q175 50 165 100' stroke-width='0.7' opacity='.36'/%3E%3C/g%3E%3C/svg%3E");
  /* 9: 모서리 발산 — 코너에서 시작하는 곡선 */
  --tex-curve-9: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 300' preserveAspectRatio='none'%3E%3Cg fill='none' stroke='%23ffffff' stroke-linecap='round'%3E%3Cpath d='M-20 -20 Q120 80 100 200 Q90 280 50 320' stroke-width='1.3' opacity='.32'/%3E%3Cpath d='M420 -20 Q300 60 320 200 Q330 270 380 320' stroke-width='1.2' opacity='.30'/%3E%3Cpath d='M-20 320 Q100 200 200 250 Q280 290 320 320' stroke-width='1.1' opacity='.28'/%3E%3Cpath d='M420 320 Q300 280 200 250' stroke-width='0.9' opacity='.23'/%3E%3Cpath d='M180 -20 Q200 60 250 100' stroke-width='1.0' opacity='.26'/%3E%3Cpath d='M-20 180 Q60 160 130 180' stroke-width='0.8' opacity='.36'/%3E%3Cpath d='M320 100 Q380 130 420 110' stroke-width='0.9' opacity='.24'/%3E%3C/g%3E%3C/svg%3E");
  /* 10: 나선 + 흩뿌린 점 */
  --tex-curve-10: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 300' preserveAspectRatio='none'%3E%3Cg fill='none' stroke='%23ffffff' stroke-linecap='round'%3E%3Cpath d='M200 150 m -60 0 a 60 60 0 1 1 120 0 a 50 50 0 1 0 -100 0 a 40 40 0 1 1 80 0 a 30 30 0 1 0 -60 0' stroke-width='1.2' opacity='.30'/%3E%3Cpath d='M-20 50 Q60 40 100 80' stroke-width='0.9' opacity='.24'/%3E%3Cpath d='M320 30 Q380 80 420 60' stroke-width='1.0' opacity='.27'/%3E%3Cpath d='M-20 270 Q40 250 80 280' stroke-width='1.0' opacity='.26'/%3E%3Cpath d='M340 280 Q380 250 420 290' stroke-width='0.9' opacity='.24'/%3E%3C/g%3E%3Cg fill='%23ffffff'%3E%3Ccircle cx='60' cy='200' r='2.5' opacity='.36'/%3E%3Ccircle cx='350' cy='200' r='2.5' opacity='.32'/%3E%3Ccircle cx='200' cy='40' r='2' opacity='.30'/%3E%3Ccircle cx='200' cy='270' r='2' opacity='.30'/%3E%3Ccircle cx='130' cy='100' r='1.8' opacity='.27'/%3E%3Ccircle cx='280' cy='240' r='1.8' opacity='.27'/%3E%3C/g%3E%3C/svg%3E");
  /* 색 블룸 (수채화 번짐) */
  --tex-bloom-warm:  radial-gradient(ellipse at 18% 32%, rgba(120,210,25,0.22) 0%, transparent 45%),
                     radial-gradient(ellipse at 82% 78%, rgba(43,135,0,0.20) 0%, transparent 50%),
                     radial-gradient(ellipse at 55% 12%, rgba(95,191,22,0.14) 0%, transparent 40%);

  /* Radius */
  --r-xs: 4px; --r-sm: 8px; --r-md: 14px; --r-lg: 20px; --r-pill: 9999px;

  /* Shadow */
  --shadow:      0 2px 8px rgba(34,90,10,0.08);
  --shadow-md:   0 4px 16px rgba(34,90,10,0.13);
  --shadow-btn:  0 1px 3px rgba(0,0,0,0.08);

  /* Layout */
  --top-h: 56px;
  --nav-h: 60px;
  --dsb-w: 152px;
  --max-w: 480px;
  --page-px: 8px;   /* 좌우 공통 여백: 모바일 8px (데스크톱 16px로 오버라이드) */
}

html, body {
  height: 100%;
  width: 100%;
  background: var(--bg);
  font-family: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-size: calc(16px * var(--font-scale, 1));
  line-height: 1.5;
  text-rendering: optimizeLegibility;
}

button { font-family: inherit; }
input, textarea, select { font-family: inherit; }

.leaf-icon { font-size: 1.2em; line-height: 1; }

/* ── App Shell ────────────────────────────────────────────────────────────── */
#app {
  width: 100%;
  min-height: 100dvh;
  display: flex; flex-direction: row;
  background: var(--bg);
}

.desktop-sidebar { display: none; }

.main-area {
  flex: 1; min-width: 0;
  display: flex; flex-direction: column;
  min-height: 100dvh;
  position: relative;
}

@media (min-width: 1024px) {
  :root { --page-px: 16px; }   /* 데스크톱 좌우 여백 16px */
  #app { max-width: 1280px; margin: 0 auto; }
  .desktop-sidebar {
    display: flex; flex-direction: column;
    width: var(--dsb-w); min-height: 100dvh;
    position: sticky; top: 0; height: 100dvh;
    overflow-y: auto; flex-shrink: 0;
    /* 깔끔한 흰 배경 — 라인/그라디언트 제거 */
    background: var(--bg);
    border-right: 1px solid rgba(88,204,2,0.18);
    /* 평소엔 투명, 스크롤(=호버) 중에만 노출 */
    scrollbar-width: thin; /* Firefox */
    scrollbar-color: transparent transparent;
  }
  .desktop-sidebar::-webkit-scrollbar { width: 6px; }
  .desktop-sidebar::-webkit-scrollbar-thumb {
    background: transparent;
    border-radius: 3px;
    transition: background .25s;
  }
  .desktop-sidebar:hover::-webkit-scrollbar-thumb {
    background: rgba(43,135,0,0.35);
  }
  .desktop-sidebar:hover { scrollbar-color: rgba(43,135,0,0.35) transparent; }
  .bottom-nav   { display: none !important; }
  #btn-hamburger { display: none !important; }
  .top-bar { position: sticky; top: 0; }
  .top-logo { display: none; }
  #main { padding-bottom: 32px; }
  .biz-grid { grid-template-columns: repeat(3, 1fr); }
  .hero { padding: 48px 32px 24px; }
  .hero-title { font-size: calc(46px * var(--font-scale, 1)); }
}

/* Tablet */
@media (min-width: 640px) and (max-width: 1023px) {
  .biz-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ── Desktop Sidebar ─────────────────────────────────────────────────────── */
.dsb-logo {
  font-size: calc(20px * var(--font-scale, 1)); font-weight: 700;
  height: var(--top-h);
  display: flex; align-items: center; gap: 8px;
  padding: 0 20px;
  color: var(--text);
  cursor: pointer;
  border-bottom: 1px solid var(--border);
  background: var(--grad-maple);
  color: #fff;
  letter-spacing: -0.3px;
}
.dsb-nav {
  padding: 10px 8px;
  flex: 1;
  display: flex; flex-direction: column; gap: 1px;
}
.dsb-item {
  display: flex; align-items: center; gap: 9px;
  width: 100%; padding: 8px 12px;
  border: none; background: none; border-radius: var(--r-sm);
  font-size: calc(14px * var(--font-scale, 1)); font-weight: 600;
  color: var(--text); cursor: pointer; text-align: left;
  transition: background .15s, color .15s;
}
.dsb-item svg { width: 18px; height: 18px; fill: currentColor; flex-shrink: 0; }
.dsb-item:hover { background: var(--maple-red-lt); color: var(--maple-red-dk); }
.dsb-item.active {
  background: var(--grad-maple);
  color: #fff; font-weight: 600;
  box-shadow: 0 2px 8px rgba(43,135,0,0.25);
}
.dsb-item.active svg { fill: #fff; }
.dsb-footer {
  padding: 14px 16px;
  border-top: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 14px;
}
.dsb-footer .fs-controls { margin-bottom: 0; }
.dsb-admin {
  display: block; width: 100%; text-align: center;
  padding: 9px 0; font-size: calc(14px * var(--font-scale, 1)); color: var(--text-3);
  text-decoration: none;
  border: 1px solid var(--border-md); border-radius: var(--r-sm);
  transition: all .15s;
}
.dsb-admin:hover { border-color: var(--maple-red); color: var(--maple-red); background: var(--maple-red-lt); }

/* ── Side Menu (mobile overlay) ─────────────────────────────────────────── */
.side-overlay {
  position: fixed; inset: 0;
  background: rgba(28,36,23,0.35);
  z-index: 200;
  opacity: 0; pointer-events: none;
  transition: opacity .25s;
}
.side-overlay.open { opacity: 1; pointer-events: all; }

.side-panel {
  position: fixed;
  top: 0; left: 0; bottom: 0; width: 194px;
  background: var(--bg); z-index: 201;
  transform: translateX(-100%);
  transition: transform .28s cubic-bezier(.4,0,.2,1);
  display: flex; flex-direction: column;
}
.side-panel.open { transform: translateX(0); }

.side-header {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--top-h);
  padding: 0 12px 0 20px;
  background: var(--tex-grain-light), var(--grad-maple);
  background-size: 200px 56px, auto;
  background-repeat: repeat, no-repeat;
  color: #fff;
}
.side-logo {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: calc(18px * var(--font-scale, 1)); font-weight: 700;
  letter-spacing: -0.3px;
}
.side-close {
  width: 32px; height: 32px; border-radius: var(--r-sm);
  border: none; background: rgba(255,255,255,0.2);
  cursor: pointer; display: flex; align-items: center; justify-content: center;
}
.side-close svg { width: 18px; height: 18px; fill: #fff; }

.side-nav {
  padding: 10px 10px;
  flex: 1;
  display: flex; flex-direction: column; gap: 0;
  overflow-y: auto;
  /* 패널 열릴 때 스크롤바가 잠깐 노출되는 현상 방지 — 평소 투명, 호버/스크롤 시에만 노출 */
  scrollbar-width: thin;
  scrollbar-color: transparent transparent;
}
.side-nav::-webkit-scrollbar { width: 6px; }
.side-nav::-webkit-scrollbar-thumb {
  background: transparent;
  border-radius: 3px;
  transition: background .25s;
}
.side-nav:hover::-webkit-scrollbar-thumb,
.side-nav:active::-webkit-scrollbar-thumb {
  background: rgba(43,135,0,0.3);
}
.side-nav:hover { scrollbar-color: rgba(43,135,0,0.3) transparent; }
/* 사이드패널의 1차 메뉴(홈·동문 업체·공지사항) 만 타겟팅.
   cat-tree-nav 내부 버튼은 .cat-nav-item 스타일이 그대로 적용됨 */
.side-nav > button {
  display: flex; align-items: center; gap: 10px;
  width: 100%; padding: 8px 12px;
  border: none; background: none; border-radius: var(--r-sm);
  font-size: calc(16px * var(--font-scale, 1)); font-weight: 600;
  color: var(--text); cursor: pointer; text-align: left;
  transition: background .12s, color .12s;
}
.side-nav > button svg { width: 17px; height: 17px; fill: currentColor; }
.side-nav > button:hover { background: var(--maple-red-lt); color: var(--maple-red-dk); }
.side-nav > button.active { background: var(--maple-red-lt); color: var(--maple-red-dk); font-weight: 600; }

.side-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 14px;
}
.side-admin-btn {
  width: 100%; padding: 10px;
  border: 1px solid var(--border-md); background: var(--bg); color: var(--text-3);
  border-radius: var(--r-sm); font-size: calc(14px * var(--font-scale, 1)); cursor: pointer;
}
.side-admin-btn:hover { border-color: var(--maple-red); color: var(--maple-red); }

/* Font size controls in side-footer */
.fs-controls {
  display: flex; flex-direction: column; gap: 6px;
}
.fs-label {
  font-size: calc(12px * var(--font-scale, 1)); color: var(--text-4); font-weight: 600;
  letter-spacing: 0.3px;
}
.fs-buttons {
  display: flex; gap: 3px;
}
.fs-btn {
  flex: 1; height: 28px;
  border: 1px solid var(--border-md); background: var(--bg);
  color: var(--text-2); border-radius: var(--r-sm);
  cursor: pointer; font-family: inherit;
  display: inline-flex; align-items: center; justify-content: center;
  transition: all .12s;
}
.fs-btn:hover { border-color: var(--maple-red); color: var(--maple-red); }
.fs-btn.active {
  background: var(--maple-red-lt);
  border-color: var(--maple-red);
  color: var(--maple-red-dk);
  font-weight: 700;
}

/* ── Top Bar ──────────────────────────────────────────────────────────────── */
.top-bar {
  position: sticky; top: 0;
  width: 100%; height: var(--top-h);
  /* 곡선 줄무늬 + 단풍 그라디언트 */
  background: var(--tex-grain-light), var(--grad-maple);
  background-size: 200px 56px, auto;
  background-repeat: repeat, no-repeat;
  border-bottom: none;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 8px;
  z-index: 100;
  flex-shrink: 0;
  transition: transform .28s ease;
}
.top-bar.hidden { transform: translateY(-100%); }
.top-logo {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: calc(28px * var(--font-scale, 1)); font-weight: 800;
  color: #141414; cursor: pointer;
  letter-spacing: -0.3px;
  max-width: calc(100% - 100px);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  text-shadow: 0 1px 2px rgba(255,255,255,0.45);
}
.top-logo .leaf-icon {
  font-size: calc(30px * var(--font-scale, 1));
}
@media (max-width: 480px) {
  .top-logo { font-size: calc(24px * var(--font-scale, 1)); }
}
.top-btn {
  width: 38px; height: 38px;
  border: none; background: none;
  cursor: pointer; border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
  color: #fff; transition: background .12s;
}
.top-btn:hover { background: rgba(255,255,255,0.15); }
.top-btn svg { width: 22px; height: 22px; fill: currentColor; }

/* ── Bottom Nav ───────────────────────────────────────────────────────────── */
.bottom-nav {
  position: fixed; bottom: 0; left: 0;
  width: 100%; height: var(--nav-h);
  background: rgba(255,255,255,0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
  display: flex; z-index: 100;
  padding-bottom: env(safe-area-inset-bottom, 0);
}
.nav-item {
  flex: 1; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 3px;
  border: none; background: none;
  cursor: pointer; color: var(--text-4);
  font-size: calc(12px * var(--font-scale, 1)); font-weight: 500;
  transition: color .12s;
}
.nav-item svg { width: 22px; height: 22px; fill: currentColor; }
.nav-item.active { color: var(--maple-red); }
.nav-item.active svg { fill: var(--maple-red); }

/* ── Main Content ─────────────────────────────────────────────────────────── */
#main {
  flex: 1;
  padding-bottom: calc(var(--nav-h) + 16px);
  min-height: 0;
}

/* ── Hero ─────────────────────────────────────────────────────────────────── */
/* 은행잎 단풍 그라데이션 (연녹→황금→매우 진한 노랑) + 흩날리는 은행잎 일러스트 */
.hero {
  background:
    /* 우상단 큰 흰색 잎 (rotate 18) */
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-20 -20 140 140'><g transform='rotate(18 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='%23ffffff' opacity='0.24'/></g></svg>") right -25px top -10px / 200px 200px no-repeat,
    /* 좌하단 황금잎 (rotate -28) */
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-20 -20 140 140'><g transform='rotate(-28 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='%23a8e01f' opacity='0.28'/></g></svg>") left -32px bottom -28px / 150px 150px no-repeat,
    /* 우중상단 작은 흰잎 (rotate 55) */
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-20 -20 140 140'><g transform='rotate(55 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='%23ffffff' opacity='0.16'/></g></svg>") right 28% top 30px / 75px 75px no-repeat,
    /* 중하단 진한노랑 작은잎 (rotate -50) */
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-20 -20 140 140'><g transform='rotate(-50 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='%235a9e1a' opacity='0.22'/></g></svg>") left 35% bottom 35px / 65px 65px no-repeat,
    /* 좌상단 작은 흰잎 (rotate 95) */
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-20 -20 140 140'><g transform='rotate(95 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='%23ffffff' opacity='0.14'/></g></svg>") left 8% top 50px / 55px 55px no-repeat,
    /* 우하단 작은 황금잎 (rotate -75) */
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-20 -20 140 140'><g transform='rotate(-75 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='%2396d619' opacity='0.18'/></g></svg>") right 12% bottom 20px / 60px 60px no-repeat,
    /* 곡선 줄무늬 + 수채 블룸 */
    var(--tex-grain-light),
    var(--tex-bloom-warm),
    var(--grad-maple);
  background-size: auto, auto, auto, auto, auto, auto, 280px 110px, auto, auto;
  background-repeat: no-repeat, no-repeat, no-repeat, no-repeat, no-repeat, no-repeat, repeat, no-repeat, no-repeat;
  padding: 32px var(--page-px) 24px;
  position: relative;
  overflow: hidden;
}

/* Home: hero extends up behind the transparent top-bar */
body.on-home .top-bar {
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: none;
}
body.on-home #main > .hero:first-child {
  margin-top: calc(var(--top-h) * -1);
  padding-top: calc(var(--top-h) + 28px);
}
.hero > * { position: relative; z-index: 1; }
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255,255,255,0.7);
  color: var(--maple-red-dk);
  font-size: calc(12px * var(--font-scale, 1)); font-weight: 700;
  letter-spacing: 0.8px; text-transform: uppercase;
  padding: 5px 12px; border-radius: var(--r-pill);
  margin-bottom: 14px;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(43,135,0,0.15);
}
.hero-title {
  font-size: calc(30px * var(--font-scale, 1)); font-weight: 800;
  line-height: 1.2; letter-spacing: -0.6px;
  color: #fff; margin-bottom: 10px;
  display: inline-block;
  text-shadow: 0 1px 3px rgba(0,0,0,0.15);
}
.hero-sub {
  font-size: calc(16px * var(--font-scale, 1)); color: rgba(255,255,255,0.95);
  line-height: 1.6; margin-bottom: 18px;
  font-weight: 500;
  text-shadow: 0 1px 2px rgba(0,0,0,0.10);
}
.hero-stats {
  display: flex; gap: 10px; flex-wrap: wrap;
}
.hero-stat {
  flex: 1; min-width: 100px;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255,255,255,0.6);
  border-radius: var(--r-md);
  padding: 12px 14px;
  box-shadow: var(--shadow);
}
.hero-stat-label { font-size: calc(12px * var(--font-scale, 1)); color: var(--text-3); margin-bottom: 2px; font-weight: 600; }
.hero-stat-value { font-size: calc(24px * var(--font-scale, 1)); font-weight: 700; color: var(--maple-red-dk); }

/* ── Home search (hero) ──────────────────────────────────────────────── */
.home-search-row {
  display: flex; align-items: center; gap: 8px;
  margin-top: 14px;
}
.home-search-wrap {
  position: relative;
  flex: 1; min-width: 0;
  display: flex; align-items: center;
  background: rgba(255,255,255,0.92);
  border: 1px solid rgba(43,135,0,0.12);
  border-radius: var(--r-md);
  padding: 0 10px 0 36px;
  height: 36px;
  box-shadow: 0 2px 6px rgba(43,135,0,0.06);
  backdrop-filter: blur(6px);
  transition: border-color .12s, box-shadow .12s;
}
.home-search-wrap:focus-within {
  border-color: var(--maple-red);
  box-shadow: 0 0 0 3px rgba(43,135,0,0.12);
}
.home-search-icon {
  position: absolute; left: 13px; top: 50%;
  transform: translateY(-50%);
  width: 16px; height: 16px;
  fill: var(--text-4);
  pointer-events: none;
}
.home-search-input {
  width: 100%;
  padding: 0 4px;
  height: 100%;
  border: none; outline: none;
  background: transparent;
  font-size: calc(14px * var(--font-scale, 1)); color: var(--text);
  font-family: inherit;
  min-width: 0;
}
.home-search-input::placeholder { color: var(--text-4); }
.home-search-clear {
  border: none; background: var(--gray-100);
  width: 22px; height: 22px; border-radius: 50%;
  font-size: calc(12px * var(--font-scale, 1)); color: var(--text-3); cursor: pointer;
  flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
}
.home-search-clear:hover { background: var(--maple-red-lt); color: var(--maple-red); }

/* Home view-toggle next to search */
.home-search-row .view-toggle { flex-shrink: 0; }

/* Biz list page search + view toggle row */
.biz-search-row {
  display: flex; align-items: center; gap: 8px;
  padding: 0 var(--page-px) 10px;
}
.biz-search-row .biz-search-input {
  flex: 1; min-width: 0;
  height: 36px;
  padding: 0 12px;
  font-size: calc(12px * var(--font-scale, 1));
}
.biz-search-row .biz-sort-select {
  flex-shrink: 0;
  height: 36px;
  width: auto;
  min-width: 110px;
  padding: 0 28px 0 12px;
  font-size: calc(13px * var(--font-scale, 1));
  cursor: pointer;
  background-color: var(--bg);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23999'><path d='M7 10l5 5 5-5z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 6px center;
  background-size: 16px 16px;
  -webkit-appearance: none; appearance: none;
}
.biz-search-row .view-toggle { flex-shrink: 0; }
@media (max-width: 520px) {
  .biz-search-row { flex-wrap: wrap; }
  .biz-search-row .biz-search-input { flex: 1 1 100%; order: 1; }
  .biz-search-row .biz-sort-select { order: 2; }
  .biz-search-row .view-toggle { order: 3; margin-left: auto; }
}

/* ── Section ──────────────────────────────────────────────────────────────── */
.section-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 22px var(--page-px) 10px;
}
.section-title {
  font-size: calc(16px * var(--font-scale, 1)); font-weight: 700;
  color: var(--text); letter-spacing: -0.2px;
  display: inline-flex; align-items: center; gap: 6px;
}
.section-title::before {
  content: '';
  width: 4px; height: 16px;
  background: var(--grad-maple);
  border-radius: 2px;
}
.section-link {
  font-size: calc(14px * var(--font-scale, 1)); font-weight: 600;
  color: var(--maple-red); background: none; border: none;
  cursor: pointer;
}

/* ── Sidebar Category Tree (public) ────────────────────────────────────── */
.cat-tree-nav {
  display: flex; flex-direction: column; gap: 0;
  margin: 0 0 4px;
  padding-left: 0;
}
.cat-nav-item {
  display: flex; align-items: center; gap: 7px;
  width: 100%; padding: 5px 10px;
  border: none; background: none; border-radius: var(--r-sm);
  font-size: calc(14px * var(--font-scale, 1)); font-weight: 500; color: var(--text-2);
  cursor: pointer; text-align: left;
  font-family: inherit;
  transition: background .12s, color .12s;
}
.cat-nav-item:hover { background: var(--maple-red-lt); color: var(--maple-red-dk); }
.cat-nav-item.active { background: var(--maple-red-lt); color: var(--maple-red-dk); font-weight: 600; }
.cat-nav-item .ci {
  width: 28px; height: 28px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--maple-red-lt); border-radius: 8px; color: var(--maple-red-dk);
  transition: background .12s, color .12s;
}
.cat-nav-item:hover .ci { background: var(--maple-orange-lt); color: var(--maple-red); }
.cat-nav-item.active .ci { background: var(--maple-red); color: #fff; }
/* 하위 카테고리: 아이콘을 오른쪽 끝이 상위 아이콘 오른쪽 끝과 맞도록 정렬.
   결과: 하위 이름 시작 위치가 상위 이름 시작 위치와 동일한 세로선에 정렬됨 */
.cat-nav-sub { padding-left: 16px; }
.cat-nav-sub .ci { width: 22px; height: 22px; border-radius: 6px; }
.cat-nav-sub .ci svg { width: 14px; height: 14px; }
.cat-icon-badge {
  display: inline-flex; align-items: center; justify-content: center;
  width: 24px; height: 24px; border-radius: 6px;
  background: var(--maple-red-lt); color: var(--maple-red-dk);
  vertical-align: middle;
}
.cat-nav-item .cn { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cat-nav-item .cc {
  font-size: calc(12px * var(--font-scale, 1));
  background: rgba(43,135,0,0.20);
  color: var(--maple-red-dk);
  padding: 1px 8px; border-radius: 9999px;
  flex-shrink: 0;
}
.cat-nav-item:hover .cc { background: rgba(43,135,0,0.30); }
.cat-nav-item.active .cc { background: var(--maple-red); color: #fff; }

.cat-nav-parent { font-weight: 500; color: var(--text-2); }
.cat-chev {
  display: inline-block; width: 10px; font-size: calc(10px * var(--font-scale, 1));
  color: var(--text-4);
  transition: transform .15s;
}
.cat-nav-group.open .cat-chev { transform: rotate(90deg); }
.cat-nav-children {
  display: none;
  margin-left: 0;
  padding-left: 0;
  border-left: none;
}
.cat-nav-group.open .cat-nav-children { display: block; }
/* Sub item — 왼쪽 16px: 상위 텍스트(10+28+7=45)와 하위 텍스트(16+22+7=45) 시작점이 세로로 정렬.
   즉 "음식점" 의 "음" 아래에 "한식" 의 "한" 이 같은 X에 위치. 상하 여백 1px 로 간격 축소. */
.cat-nav-sub { padding: 1px 10px 1px 16px; font-size: calc(12px * var(--font-scale, 1)); }
.cat-nav-sub .cc { font-size: calc(10px * var(--font-scale, 1)); padding: 0 5px; }

/* Side panel (mobile) spacing tweak */
.side-nav .cat-tree-nav { margin: 0 4px 4px; }

/* ── Category Chips ───────────────────────────────────────────────────────── */
.chip-row {
  display: flex; gap: 8px;
  padding: 4px var(--page-px) 14px;
  overflow-x: auto; scrollbar-width: none;
}
.chip-row::-webkit-scrollbar { display: none; }

.chip {
  flex-shrink: 0;
  padding: 7px 14px;
  border-radius: var(--r-pill);
  font-size: calc(14px * var(--font-scale, 1)); font-weight: 500;
  border: 1px solid var(--border-md);
  background: var(--bg);
  color: var(--text-2);
  cursor: pointer; white-space: nowrap;
  transition: all .15s; box-shadow: var(--shadow-btn);
  display: inline-flex; align-items: center; gap: 5px;
}
.chip:hover { border-color: var(--maple-red); color: var(--maple-red); }
.chip.active {
  background: var(--grad-maple);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 2px 8px rgba(43,135,0,0.25);
}
.chip-count {
  font-size: calc(12px * var(--font-scale, 1)); font-weight: 700;
  background: rgba(43,135,0,0.20);
  color: var(--maple-red-dk);
  padding: 1px 7px; border-radius: 9999px;
}
.chip.active .chip-count { background: rgba(255,255,255,0.3); color: #fff; }

/* Sub-category chip row — align with top chip row padding */
.sub-chip-row {
  padding: 8px var(--page-px) 12px;
  margin: 0;
  border-top: 1px dashed var(--border-md);
}
.chip.sub {
  font-size: calc(14px * var(--font-scale, 1));
  padding: 5px 12px;
  background: var(--bg-soft);
  border-color: var(--border);
}
.chip.sub.active {
  background: var(--maple-yellow);
  color: var(--maple-red-dk);
  border-color: var(--maple-yellow);
  box-shadow: 0 2px 6px rgba(150,215,80,0.3);
}

.biz-crumb {
  font-size: calc(12px * var(--font-scale, 1)); color: var(--text-4);
  font-weight: 500; letter-spacing: 0;
  margin-left: 8px;
  text-transform: none;
}

/* ── Business List Wrapper & View Modes ───────────────────────────────── */
.biz-list-wrap, .biz-grid {
  padding: 4px var(--page-px) 8px;
}
.biz-list-wrap.view-grid, .biz-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
@media (min-width: 720px) {
  .biz-list-wrap.view-grid, .biz-grid { grid-template-columns: repeat(2, 1fr); }
}
/* Mini mode: 1 col narrow, 2 cols wide */
.biz-list-wrap.view-mini { display: grid; grid-template-columns: 1fr; gap: 8px; }
@media (min-width: 720px) {
  .biz-list-wrap.view-mini { grid-template-columns: repeat(2, 1fr); }
}
.biz-list-wrap.view-mini {
  display: flex; flex-direction: column; gap: 8px;
}
.biz-list-wrap.view-list {
  display: flex; flex-direction: column; gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  overflow: hidden;
  background: var(--bg);
}

/* ── View Toggle Buttons ──────────────────────────────────────────────── */
.view-toggle {
  display: inline-flex; gap: 2px;
  background: var(--gray-100);
  border-radius: var(--r-sm);
  padding: 3px;
}
.vt-btn {
  width: 48px; height: 30px;
  border: none; background: transparent;
  border-radius: 6px;
  cursor: pointer; color: var(--text-4);
  display: inline-flex; align-items: center; justify-content: center;
  transition: all .12s;
}
.vt-btn svg { width: 15px; height: 15px; fill: currentColor; }
.vt-btn:first-child svg { width: 19px; height: 19px; }
.vt-btn:hover { color: var(--text-2); }
.vt-btn.active {
  background: var(--bg);
  color: var(--maple-red);
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

/* ── Business Card (base) ──────────────────────────────────────────────── */
.biz-card {
  /* 카드 배경: 메인 그린보다 조금 연한 톤 */
  --card-grad: linear-gradient(135deg, #5cd236 0%, #6edb48 50%, #86e461 100%);
  background: var(--card-grad);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  overflow: hidden;
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: transform .15s, box-shadow .15s, border-color .15s;
  display: flex; flex-direction: column;
  position: relative;
}
/* 카드 질감 오버레이 제거 — 단풍 그라디언트만 사용 */
.biz-card > * { position: relative; z-index: 2; }
.biz-card:hover { box-shadow: var(--shadow-md); border-color: var(--border-md); transform: translateY(-2px); }
.biz-card:active { transform: translateY(0); }

/* ── 카드 배경 흰 라인 은행잎 변형 5종 (nth-child로 순환 배치) ────────────── */
.biz-card:nth-child(10n+1) {
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(18 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.75'/></g></svg>") right -15px center / 130px 130px no-repeat,
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(-35 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.55'/></g></svg>") left -12px bottom -12px / 80px 80px no-repeat,
    var(--card-grad);
}
.biz-card:nth-child(10n+2) {
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(-22 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.7'/></g></svg>") left -10px top -20px / 130px 130px no-repeat,
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(50 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.5'/></g></svg>") right 8px bottom -10px / 90px 90px no-repeat,
    var(--card-grad);
}
.biz-card:nth-child(10n+3) {
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(45 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='%23ffffff' stroke='%23ffffff' stroke-width='1.5' stroke-linejoin='round' opacity='0.18'/></g></svg>") right -10px top -25px / 145px 145px no-repeat,
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(-60 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.55'/></g></svg>") left 38% bottom -8px / 75px 75px no-repeat,
    var(--card-grad);
}
.biz-card:nth-child(10n+4) {
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(-50 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.7'/></g></svg>") right -25px top 0 / 140px 140px no-repeat,
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(75 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.55'/></g></svg>") left -15px bottom 5px / 85px 85px no-repeat,
    var(--card-grad);
}
.biz-card:nth-child(10n+5) {
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(0 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='%23ffffff' stroke='%23ffffff' stroke-width='1.5' stroke-linejoin='round' opacity='0.16'/></g></svg>") right 5% center / 110px 110px no-repeat,
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(-15 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.6'/></g></svg>") left 8px top -8px / 75px 75px no-repeat,
    var(--card-grad);
}
.biz-card:nth-child(10n+6) {
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(70 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.65'/></g></svg>") right -10px top 0 / 135px 135px no-repeat,
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(-10 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.5'/></g></svg>") left -8px bottom 8px / 75px 75px no-repeat,
    var(--card-grad);
}
.biz-card:nth-child(10n+7) {
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(25 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='%23ffffff' stroke='%23ffffff' stroke-width='1.5' stroke-linejoin='round' opacity='0.17'/></g></svg>") left 4% center / 105px 105px no-repeat,
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(-75 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.6'/></g></svg>") right 12px top -5px / 85px 85px no-repeat,
    var(--card-grad);
}
.biz-card:nth-child(10n+8) {
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(165 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.6'/></g></svg>") right -5px bottom -15px / 135px 135px no-repeat,
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(35 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.5'/></g></svg>") left -10px top -10px / 80px 80px no-repeat,
    var(--card-grad);
}
.biz-card:nth-child(10n+9) {
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(25 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.55'/></g></svg>") right -5px top -5px / 75px 75px no-repeat,
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(-55 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.5'/></g></svg>") left -5px bottom -5px / 70px 70px no-repeat,
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(90 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.4'/></g></svg>") center 50% / 60px 60px no-repeat,
    var(--card-grad);
}
.biz-card:nth-child(10n) {
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(-15 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='%23ffffff' stroke='%23ffffff' stroke-width='1.5' stroke-linejoin='round' opacity='0.14'/></g></svg>") right -30px center / 165px 165px no-repeat,
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-8 -8 116 116'><g transform='rotate(110 50 50)'><path d='M50 100 Q48 80 50 60 C30 60 12 50 8 32 C5 18 18 6 32 8 C40 12 46 22 50 38 C54 22 60 12 68 8 C82 6 95 18 92 32 C88 50 70 60 50 60 Q52 80 50 100 Z' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linejoin='round' opacity='0.5'/></g></svg>") left 12px top 5px / 70px 70px no-repeat,
    var(--card-grad);
}

.biz-card-thumb {
  width: 100%; aspect-ratio: 16 / 10;
  background: var(--tex-grain-dark), var(--tex-bloom-warm), var(--grad-maple-soft);
  background-size: 200px 80px, auto, auto;
  background-repeat: repeat, no-repeat, no-repeat;
  display: flex; align-items: center; justify-content: center;
  font-size: calc(58px * var(--font-scale, 1));
  position: relative;
  overflow: hidden;
}
.biz-card-thumb img { width: 100%; height: 100%; object-fit: cover; }
.biz-card-thumb .ribbon,
.ribbon-floating {
  position: absolute; top: 10px; left: 10px;
  background: var(--grad-maple);
  color: #fff; padding: 3px 10px;
  font-size: calc(12px * var(--font-scale, 1)); font-weight: 700; letter-spacing: 0.5px;
  border-radius: var(--r-pill);
  box-shadow: 0 2px 6px rgba(43,135,0,0.3);
  z-index: 2;
}
/* 동문 혜택 — 카드 사진 좌하단 오버레이 */
.biz-card-discount-overlay {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 8px 12px;
  background: linear-gradient(to top, rgba(0,0,0,0.65), rgba(0,0,0,0));
  color: #fff; font-size: calc(12px * var(--font-scale, 1)); font-weight: 600;
  letter-spacing: -0.2px;
  z-index: 2; pointer-events: none;
  text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

.biz-card-body {
  padding: 12px var(--page-px) 14px;
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 1;
}
.biz-card-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 8px;
  margin-bottom: 2px;
}
.biz-meta-row {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: 6px;
  font-size: calc(14px * var(--font-scale, 1)); color: var(--text-2);
  line-height: 1.4;
}
.biz-meta-row .lb { font-size: calc(12px * var(--font-scale, 1)); color: var(--text-4); font-weight: 600; }
/* (legacy biz-owner-icon font-size 정의 → 아래 통합 배지 스타일로 대체) */
.biz-meta-row strong { font-weight: 700; font-size: calc(16px * var(--font-scale, 1)); }
/* school-badge 사이즈는 모든 뷰에서 통일 (전역 .biz-school-badge에서 관리) */
.biz-meta-row .biz-phone-inline { color: var(--maple-red-dk); font-size: calc(14px * var(--font-scale, 1)); font-weight: 700; }
.biz-meta-row .biz-card-discount { font-size: calc(12px * var(--font-scale, 1)); padding: 2px 7px; }
.biz-phone-discount-row {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: 6px;
  margin: 2px 0 4px;
  line-height: 1.4;
}
.biz-phone-discount-row .biz-phone-inline { color: var(--maple-red-dk); font-size: calc(14px * var(--font-scale, 1)); font-weight: 700; }
.biz-phone-discount-row .biz-card-discount { font-size: calc(12px * var(--font-scale, 1)); padding: 2px 7px; }
.biz-card-name {
  font-size: calc(18px * var(--font-scale, 1)); font-weight: 700;
  color: var(--text-2); line-height: 1.3;
  letter-spacing: -0.2px;
  flex: 1; min-width: 0;
  display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap;
}
.biz-featured-star {
  font-size: calc(11px * var(--font-scale, 1));
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
  flex-shrink: 0;
  line-height: 1;
}

/* NEW / 주년 badges next to name */
.biz-new-tag, .biz-anni-tag {
  display: inline-flex; align-items: center;
  font-size: calc(12px * var(--font-scale, 1)); font-weight: 800;
  padding: 2px 7px;
  border-radius: var(--r-pill);
  letter-spacing: 0.3px;
  flex-shrink: 0;
  line-height: 1.3;
}
.biz-new-tag {
  background: var(--grad-maple);
  color: #fff;
  box-shadow: 0 1px 3px rgba(43,135,0,0.25);
}
.biz-anni-tag {
  background: linear-gradient(135deg, #c4ec5c 0%, #5a9e1a 100%);
  color: #2D5F1B;
  box-shadow: 0 1px 3px rgba(150,215,80,0.3);
}

.section-link-muted {
  font-size: calc(12px * var(--font-scale, 1)); color: var(--text-4);
  font-weight: 500;
}
.biz-cat-tag {
  flex-shrink: 0;
  font-size: calc(10px * var(--font-scale, 1)); font-weight: 700;
  color: var(--maple-red);
  background: var(--maple-red-lt);
  padding: 3px 8px;
  border-radius: var(--r-pill);
  letter-spacing: 0.3px;
  white-space: nowrap;
}
.biz-owner-row {
  font-size: calc(14px * var(--font-scale, 1)); color: var(--text-2);
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
}
.biz-owner-row .lb {
  font-size: calc(12px * var(--font-scale, 1)); color: var(--text-4);
  font-weight: 600;
}
.biz-owner-row strong { font-weight: 700; }
.biz-school-badge {
  display: inline-flex; align-items: center; justify-content: center;
  height: 18px;
  font-size: calc(10px * var(--font-scale, 1)); font-weight: 700;
  background: var(--maple-yellow-lt);
  color: var(--maple-red-dk);
  padding: 0 6px;
  border-radius: var(--r-pill);
  letter-spacing: 0.1px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
  flex-shrink: 0;
  line-height: 1;
}
.biz-line {
  font-size: calc(14px * var(--font-scale, 1)); color: var(--text-3);
  line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden;
}
.biz-card-discount {
  display: inline-flex;
  font-size: calc(12px * var(--font-scale, 1)); font-weight: 700;
  color: var(--maple-orange);
  background: var(--maple-yellow-lt);
  padding: 3px 8px; border-radius: var(--r-pill);
  align-self: flex-start;
}
/* Map pill buttons — brand colored (inside biz-card-side, stacked vertically) */
.biz-map-row {
  display: flex; flex-direction: column; gap: 5px;
  align-items: flex-end;
  margin-top: 0;
}
.map-pill {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 9px 3px 3px;
  border: none;
  border-radius: var(--r-pill);
  font-size: calc(12px * var(--font-scale, 1)); font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  letter-spacing: -0.2px;
  transition: transform .08s, box-shadow .12s, filter .12s;
  white-space: nowrap;
  text-decoration: none;
}
.map-pill:hover { filter: brightness(1.05); box-shadow: 0 2px 8px rgba(0,0,0,0.12); }
.map-pill:active { transform: scale(0.97); }
.map-pill-logo {
  display: inline-flex; align-items: center; justify-content: center;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: #fff;
  font-weight: 900; font-size: calc(12px * var(--font-scale, 1));
  letter-spacing: 0;
  line-height: 1;
}
.map-pill.naver {
  background: #03C75A; color: #fff;
}
.map-pill.naver .map-pill-logo { color: #03C75A; }

/* 카드 우하단 네이버 지도 버튼 (그리드·미니 모두) */
.biz-card-naver-btn {
  position: absolute; right: 12px; bottom: 6px;
  z-index: 2;
  width: 64px; box-sizing: border-box; justify-content: center;
  padding: 4px 10px 4px 4px;
  font-size: calc(11px * var(--font-scale, 1));
  gap: 5px;
}
.biz-card-naver-btn .map-pill-logo {
  width: 14px; height: 14px;
  font-size: calc(9px * var(--font-scale, 1));
  font-weight: 800;
  line-height: 1;
}

/* 정보 라벨 단색 SVG 아이콘 — 흰 원형 배지 + 진한 녹색 아이콘 */
.biz-owner-icon, .biz-phone-icon, .biz-addr-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  color: var(--maple-red-dk);
  flex-shrink: 0;
  vertical-align: middle;
  line-height: 0;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}
/* 전화 아이콘은 부모 wrapper(biz-phone-inline) 안에 들어있어
   row의 flex gap이 직접 적용되지 않으므로 margin-right로 간격 부여 */
.biz-phone-icon { margin-right: 6px; }
.biz-owner-icon svg, .biz-phone-icon svg, .biz-addr-icon svg {
  width: 13px; height: 13px;
}
/* 모든 뷰에서 동일한 크기 유지 — 미니/리스트도 22px 고정 */

/* 휴대폰 번호 — 크롤링 방지 클릭하여 확인 버튼 */
.biz-phone-reveal {
  display: inline-flex; align-items: center; gap: 4px;
  border: 1px solid var(--border-md);
  background: var(--maple-red-lt);
  color: var(--maple-red-dk);
  padding: 2px 10px; border-radius: 9999px;
  font-size: calc(11px * var(--font-scale, 1)); font-weight: 600;
  cursor: pointer; font-family: inherit;
  transition: background .12s, border-color .12s;
}
.biz-phone-reveal:hover {
  background: var(--maple-orange-lt);
  border-color: var(--maple-red);
}
.biz-phone-revealed {
  color: var(--maple-red-dk); font-weight: 700;
  text-decoration: none;
}
.biz-phone-revealed:hover { text-decoration: underline; }

.map-pill.kakao {
  background: #FEE500; color: #3C1E1E;
}
.map-pill.kakao .map-pill-logo { background: #3C1E1E; color: #FEE500; }

/* Small map badges inline next to address (grid/mini/list views) */
.map-mini {
  display: inline-flex; align-items: center; justify-content: center;
  width: 20px; height: 20px;
  border-radius: 50%;
  font-size: calc(12px * var(--font-scale, 1)); font-weight: 900;
  text-decoration: none;
  margin-left: 4px;
  vertical-align: middle;
  letter-spacing: 0;
  transition: transform .08s, filter .12s;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}
.map-mini.naver { background: #03C75A; color: #fff; }
.map-mini.kakao { background: #FEE500; color: #3C1E1E; }
.map-mini:hover { filter: brightness(1.1); transform: scale(1.15); }

/* Address line that must show N/K badges without being clipped (badges right-aligned) */
.biz-addr-line {
  display: flex; align-items: center; gap: 6px;
  font-size: calc(12px * var(--font-scale, 1)); color: var(--text);
  line-height: 1.45;
  min-width: 0;
}
.biz-addr-text {
  min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.biz-addr-line .map-mini { flex-shrink: 0; margin-left: 0; }
.biz-addr-line .map-mini:first-child { margin-left: 0; margin-right: 2px; }

/* List view address: allow inline with map badges */
.biz-list-addr { display: inline-flex; align-items: center; gap: 6px; }
.biz-list-addr .map-mini { vertical-align: middle; }

/* Mini thumb only rendered when thumb_url exists (no empty box for missing image) */

/* Grid mode: with-photo vs no-photo */
.biz-card.has-photo {}
.biz-card.no-photo .biz-card-body { padding: 14px var(--page-px); }
.biz-card.no-photo { min-height: auto; }

/* Mini card: horizontal layout */
.biz-card.mini {
  flex-direction: row;
  padding: 10px 12px;
  gap: 10px;
  align-items: stretch;
}
.biz-card.mini .biz-card-body {
  padding: 0; flex: 1; min-width: 0; gap: 4px;
  display: flex; flex-direction: column;
  align-items: stretch;
}
.biz-card.mini .biz-card-name {
  font-size: calc(18px * var(--font-scale, 1));
  display: inline-flex; align-items: center; gap: 5px;
}
.biz-card.mini .biz-line { font-size: calc(12px * var(--font-scale, 1)); }

/* Mini card specific rows */
.mini-cat-row {
  display: flex; align-items: center;
  margin-bottom: 1px;
}
.mini-cat-row .biz-cat-tag {
  font-size: calc(10px * var(--font-scale, 1));
  padding: 2px 7px;
}
.mini-meta-line {
  display: flex; flex-wrap: wrap; gap: 6px;
  align-items: center;
  font-size: calc(12px * var(--font-scale, 1)); color: var(--text-2);
  line-height: 1.4;
}
.mini-meta-line .lb { font-size: calc(12px * var(--font-scale, 1)); color: var(--text-4); font-weight: 600; }
.mini-meta-line strong { font-weight: 700; font-size: calc(14px * var(--font-scale, 1)); }
/* mini-meta-line school-badge 별도 사이즈 제거 — 전역 통일 */
.mini-meta-line .mini-phone { color: var(--text-3); font-size: calc(12px * var(--font-scale, 1)); }
/* 미니 카드 우측 컬럼 (카테고리, 썸네일, 지도버튼 — 동일 가로폭, 동일 세로간격) */
.biz-mini-side {
  --mini-side-w: 64px;
  display: flex; flex-direction: column;
  align-items: stretch; gap: 6px;
  flex-shrink: 0;
  align-self: stretch;
  width: var(--mini-side-w);
}
.biz-mini-cat {
  display: flex; align-items: center; justify-content: center;
  width: 100%;
  height: 22px;
}
.biz-mini-cat .biz-cat-tag {
  width: 100%;
  box-sizing: border-box;
  text-align: center;
  padding: 3px 4px;
  overflow: hidden; text-overflow: ellipsis;
}
.biz-mini-thumb {
  width: 100%; height: var(--mini-side-w);
  border-radius: var(--r-sm);
  overflow: hidden; flex-shrink: 0;
  background: var(--grad-maple-soft);
  display: flex; align-items: center; justify-content: center;
  position: relative;
}
.biz-card.mini .biz-card-naver-btn.in-side {
  position: static;
  width: 100%;
  height: 22px;
  padding: 3px 6px 3px 3px;
  flex-shrink: 0;
  align-self: stretch;
}
.biz-mini-thumb img { width: 100%; height: 100%; object-fit: cover; }
.biz-mini-thumb .ph { font-size: calc(28px * var(--font-scale, 1)); opacity: 0.7; }
.mini-star {
  position: absolute; top: 2px; right: 2px;
  font-size: calc(12px * var(--font-scale, 1));
  background: rgba(255,255,255,0.9);
  border-radius: 50%;
  width: 18px; height: 18px;
  display: flex; align-items: center; justify-content: center;
}

/* List row */
.biz-list-row {
  display: flex; align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background .12s;
}
.biz-list-row:last-child { border-bottom: none; }
.biz-list-row:hover { background: var(--bg-soft); }
.biz-list-main { flex: 1; min-width: 0; }
.biz-list-name {
  font-size: calc(16px * var(--font-scale, 1)); font-weight: 700;
  display: flex; align-items: center; gap: 6px;
  letter-spacing: -0.2px;
}
.biz-list-star { font-size: calc(14px * var(--font-scale, 1)); }
.biz-list-sub {
  margin-top: 4px;
  font-size: calc(12px * var(--font-scale, 1)); color: var(--text-4);
  display: flex; gap: 10px; flex-wrap: wrap;
}
.biz-list-cat {
  flex-shrink: 0;
  margin-left: auto;
  align-self: flex-start;
}

/* ── Business Detail ──────────────────────────────────────────────────────── */
.biz-detail { padding: 0 var(--page-px) 24px; }
.biz-detail-hero {
  position: relative;
  margin: 0 -16px 16px;
  aspect-ratio: 16 / 9;
  background: var(--grad-maple-soft);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  touch-action: pan-y;
  user-select: none;
}
.biz-detail-hero img { width: 100%; height: 100%; object-fit: cover; }
.biz-detail-hero .placeholder { font-size: calc(102px * var(--font-scale, 1)); opacity: 0.5; }
/* 슬라이드 — 모든 이미지를 절대 위치로 겹쳐두고 active만 노출 */
.biz-hero-img {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transition: opacity .25s ease;
}
.biz-hero-img.active { opacity: 1; }
/* 좌우 nav */
.biz-hero-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 42px; height: 42px; border-radius: 50%;
  border: none; background: rgba(0,0,0,0.45); color: #fff;
  font-size: 26px; line-height: 1; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  z-index: 4; transition: background .12s, transform .12s;
  font-family: inherit;
}
.biz-hero-nav:hover { background: rgba(0,0,0,0.65); transform: translateY(-50%) scale(1.05); }
.biz-hero-nav.prev { left: 12px; }
.biz-hero-nav.next { right: 12px; }
/* 닷 인디케이터 */
.biz-hero-dots {
  position: absolute; bottom: 12px; left: 50%; transform: translateX(-50%);
  display: flex; gap: 6px; z-index: 4;
}
.biz-hero-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(255,255,255,0.55);
  cursor: pointer; transition: all .12s;
}
.biz-hero-dot.active { background: #fff; transform: scale(1.3); }
/* 썸네일 스트립 */
.biz-hero-thumbs {
  display: flex; gap: 8px; padding: 4px 0 12px;
  overflow-x: auto; scrollbar-width: thin;
  margin: 0 -16px 12px; padding-left: 16px; padding-right: 16px;
}
.biz-hero-thumb {
  width: 72px; height: 56px; flex-shrink: 0;
  border: 2px solid transparent; border-radius: 6px;
  overflow: hidden; padding: 0; cursor: pointer;
  background: var(--gray-100); transition: border-color .15s;
}
.biz-hero-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.biz-hero-thumb.active { border-color: var(--maple-red); }
.biz-hero-thumb:hover { border-color: var(--maple-orange); }

.biz-detail-title {
  font-size: calc(26px * var(--font-scale, 1)); font-weight: 800;
  letter-spacing: -0.4px;
  margin-top: 24px;
  margin-bottom: 4px;
  display: flex; align-items: center; gap: 10px;
}
.biz-detail-title .biz-title-text { flex: 0 1 auto; min-width: 0; }
.biz-detail-cat-inline {
  flex-shrink: 0;
  display: inline-flex; align-items: center;
  padding: 4px 12px; border-radius: var(--r-pill);
  background: var(--maple-red-lt); color: var(--maple-red-dk);
  font-size: calc(12px * var(--font-scale, 1)); font-weight: 600;
  letter-spacing: -0.2px; line-height: 1.3;
  white-space: nowrap;
  margin-right: auto;
}
.biz-share-btn {
  flex-shrink: 0;
  width: 42px; height: 42px;
  border: 1.5px solid var(--border-dark); background: var(--bg);
  border-radius: 50%;
  color: var(--text-2);
  cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: color .12s, background .12s, border-color .12s;
}
.biz-share-btn svg { width: 20px; height: 20px; }
.biz-share-btn:hover {
  color: var(--maple-red); background: var(--maple-red-lt); border-color: var(--maple-red);
}

/* 공유 모달 */
.share-modal { padding: 18px 18px 16px; min-width: 280px; max-width: 420px; }
.share-modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.share-modal-title { font-size: calc(16px * var(--font-scale, 1)); font-weight: 700; }
.share-biz-name {
  font-size: calc(14px * var(--font-scale, 1)); font-weight: 700; color: var(--maple-red-dk);
  background: var(--maple-red-lt); border-radius: var(--r-sm);
  padding: 8px 12px; margin-bottom: 8px; word-break: break-all;
}
.share-url {
  background: var(--bg-soft); border: 1px solid var(--border);
  border-radius: var(--r-sm); padding: 10px 12px;
  font-size: calc(10px * var(--font-scale, 1)); color: var(--text-2);
  word-break: break-all; line-height: 1.4; margin-bottom: 14px;
  font-family: ui-monospace, SFMono-Regular, monospace;
}
.share-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.share-btn {
  height: 44px;
  border-radius: var(--r-sm); border: 1px solid var(--border-md);
  background: var(--bg); color: var(--text);
  font-size: calc(12px * var(--font-scale, 1)); font-weight: 600;
  cursor: pointer; font-family: inherit;
  transition: background .12s, border-color .12s, color .12s;
}
.share-btn.share-copy { background: var(--maple-red-lt); color: var(--maple-red-dk); border-color: var(--maple-red-lt); }
.share-btn.share-copy:hover { background: var(--maple-red); color: #fff; border-color: var(--maple-red); }
.share-btn.share-open { background: var(--maple-red); color: #fff; border-color: var(--maple-red); }
.share-btn.share-open:hover { background: var(--maple-red-dk); border-color: var(--maple-red-dk); }
.biz-detail-cat {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: calc(12px * var(--font-scale, 1)); font-weight: 700;
  color: var(--maple-red); background: var(--maple-red-lt);
  padding: 3px 10px; border-radius: var(--r-pill);
  margin-bottom: 12px;
}

.biz-info-grid {
  display: grid; grid-template-columns: 1fr;
  gap: 10px;
  margin-top: 16px;
  padding: 16px;
  background: var(--bg-soft);
  border-radius: var(--r-md);
  border: 1px solid var(--border);
}
.biz-info-row {
  display: grid; grid-template-columns: 80px 1fr;
  gap: 12px; align-items: baseline;
  font-size: calc(16px * var(--font-scale, 1));
}
.biz-info-label { color: var(--text-4); font-size: calc(14px * var(--font-scale, 1)); font-weight: 600; }
.biz-info-value { color: var(--text); word-break: break-all; }
.biz-owner-name { font-size: calc(18px * var(--font-scale, 1)); font-weight: 700; color: var(--text-2); }
.biz-info-value a { color: var(--maple-red-dk); text-decoration: none; font-weight: 700; }
.biz-info-value a:hover { text-decoration: underline; }

/* 상세 섹션 (설명 / 사진) — 공통 스타일 */
.biz-detail-section { margin-top: 24px; }
.biz-detail-section-title {
  font-size: calc(14px * var(--font-scale, 1)); font-weight: 700; color: var(--text);
  margin-bottom: 10px;
  display: flex; align-items: center; gap: 6px;
}
.biz-detail-section-title::before {
  content: '';
  width: 3px; height: 14px;
  background: var(--grad-maple);
  border-radius: 2px;
}

.biz-desc {
  padding: 14px;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: var(--r-md);
  font-size: calc(14px * var(--font-scale, 1)); line-height: 1.7; color: var(--text-2);
  white-space: pre-wrap;
  min-height: calc(1.7em * 4 + 28px);
}
.biz-desc.empty { color: var(--text-4); }
.biz-desc ul { padding-left: 28px; list-style: disc; margin: 6px 0; }
.biz-desc ol { padding-left: 28px; list-style: decimal; margin: 6px 0; }
.biz-desc blockquote { padding-left: 14px; border-left: 3px solid var(--border-md); margin: 6px 0; color: var(--text-3); }
.biz-desc b, .biz-desc strong { font-weight: 700; color: var(--text); }

/* 주소 라인 — 한 줄 아래 N/K 버튼 */
.biz-addr-value {
  display: flex; flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}
.biz-addr-text-inline { word-break: break-all; }
.biz-addr-maps { display: inline-flex; gap: 8px; flex-shrink: 0; }
.map-pill.compact {
  display: inline-flex; align-items: center; justify-content: center;
  height: 32px;
  min-width: 96px;
  padding: 0 14px 0 4px;
  font-size: calc(13px * var(--font-scale, 1));
  gap: 7px;
  text-decoration: none;
}
.map-pill.compact .map-pill-logo {
  width: 24px; height: 24px;
  font-size: calc(11px * var(--font-scale, 1));
}
.biz-discount-card {
  margin-top: 12px; padding: 14px 16px;
  background: linear-gradient(135deg, var(--maple-yellow-lt) 0%, var(--maple-orange-lt) 100%);
  border-left: 3px solid var(--maple-orange);
  border-radius: var(--r-md);
}
.biz-discount-card .t { font-size: calc(12px * var(--font-scale, 1)); color: var(--maple-orange); font-weight: 700; letter-spacing: 0.4px; margin-bottom: 3px; text-transform: uppercase; }
.biz-discount-card .v { font-size: calc(16px * var(--font-scale, 1)); font-weight: 600; color: var(--text); }
.biz-notes-card {
  margin-top: 14px; padding: 12px 14px;
  background: var(--bg); border: 1px solid var(--border);
  border-left: 3px solid var(--text-3);
  border-radius: var(--r-md);
}
.biz-notes-title { font-size: calc(12px * var(--font-scale, 1)); color: var(--text-2); font-weight: 700; margin-bottom: 6px; }
.biz-notes-body { font-size: calc(12px * var(--font-scale, 1)); color: var(--text); line-height: 1.6; word-break: break-word; }

/* Map buttons (biz detail) */
.map-actions {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 14px;
}
.map-actions.two { grid-template-columns: repeat(2, 1fr); }
.map-actions .map-pill {
  justify-content: center;
  padding: 12px 10px;
  font-size: calc(14px * var(--font-scale, 1));
  text-decoration: none;
  gap: 8px;
}
.map-actions .map-pill .map-pill-logo {
  width: 26px; height: 26px; font-size: calc(12px * var(--font-scale, 1));
}
.map-pill.naver-pano { background: #00B2A9; color: #fff; }
.map-pill.naver-pano .map-pill-logo { color: #00B2A9; }
/* 주소 미입력 상태: 버튼은 보이지만 회색톤 & 클릭해도 무반응 (JS에서 처리) */
.map-pill.disabled {
  opacity: 0.45;
  cursor: not-allowed;
  filter: grayscale(0.6);
}
.map-pill.disabled:hover { filter: grayscale(0.6); box-shadow: none; }
.map-pill.disabled:active { transform: none; }

/* 업체 수정 모달 내 주소 아래 지도 버튼: 세로 여유 + 중앙정렬 */
.addr-map-btns .map-pill {
  justify-content: center;
  padding: 10px 12px;
  font-size: calc(12px * var(--font-scale, 1));
  gap: 8px;
}
.addr-map-btns .map-pill .map-pill-logo {
  width: 22px; height: 22px; font-size: calc(12px * var(--font-scale, 1));
}
@media (max-width: 520px) {
  .map-actions { grid-template-columns: repeat(3, 1fr); gap: 5px; }
  .map-actions .map-pill { padding: 10px 6px; font-size: calc(10px * var(--font-scale, 1)); gap: 5px; flex-wrap: nowrap; }
  .map-actions .map-pill .map-pill-logo { width: 20px; height: 20px; font-size: calc(10px * var(--font-scale, 1)); }
  .map-actions .map-pill .map-pill-label { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
}
@media (max-width: 360px) {
  .map-actions .map-pill { font-size: calc(10px * var(--font-scale, 1)); padding: 9px 4px; gap: 4px; }
  .map-actions .map-pill .map-pill-logo { width: 18px; height: 18px; font-size: calc(8px * var(--font-scale, 1)); }
}
.map-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 11px 12px;
  border: 1px solid var(--border-md);
  border-radius: var(--r-md);
  background: var(--bg);
  font-size: calc(14px * var(--font-scale, 1)); font-weight: 600;
  color: var(--text-2);
  cursor: pointer; text-decoration: none;
  transition: all .15s;
}
.map-btn:hover { border-color: var(--maple-red); color: var(--maple-red); background: var(--maple-red-lt); }
.map-btn.naver { color: #03C75A; border-color: rgba(3,199,90,0.25); }
.map-btn.naver:hover { background: rgba(3,199,90,0.08); border-color: #03C75A; }
.map-btn.kakao { color: #C88400; border-color: rgba(252,227,4,0.45); }
.map-btn.kakao:hover { background: #fef9c3; border-color: #FCE304; }
.map-btn .logo { display: inline-flex; width: 16px; height: 16px; font-weight: 900; font-size: calc(12px * var(--font-scale, 1)); border-radius: 4px; align-items: center; justify-content: center; }
.map-btn.naver .logo { background: #03C75A; color: #fff; }
.map-btn.kakao .logo { background: #FCE304; color: #000; }

/* Photo Gallery */
.photo-gallery-wrap {
  margin-top: 20px;
}
.photo-gallery-title {
  font-size: calc(14px * var(--font-scale, 1)); font-weight: 700; color: var(--text);
  margin-bottom: 10px;
  display: flex; align-items: center; gap: 6px;
}
.photo-gallery-title::before {
  content: '';
  width: 3px; height: 14px;
  background: var(--grad-maple);
  border-radius: 2px;
}
.photo-gallery {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
}
.photo-item {
  aspect-ratio: 1 / 1;
  background: var(--gray-100);
  border-radius: var(--r-sm);
  overflow: hidden;
  cursor: pointer;
  position: relative;
}
.photo-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .2s; }
.photo-item:hover img { transform: scale(1.05); }

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; z-index: 300;
  background: rgba(0,0,0,0.92);
  display: flex; align-items: center; justify-content: center;
  padding: 16px;
}
.lightbox img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: var(--r-sm); }
.lightbox-close {
  position: absolute; top: 16px; right: 16px;
  width: 40px; height: 40px; border-radius: 50%;
  border: none; background: rgba(255,255,255,0.15);
  color: #fff; font-size: calc(24px * var(--font-scale, 1)); cursor: pointer;
}
.lightbox-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(255,255,255,0.15); color: #fff;
  border: none; cursor: pointer; font-size: calc(26px * var(--font-scale, 1));
  display: flex; align-items: center; justify-content: center;
}
.lightbox-nav.prev { left: 10px; }
.lightbox-nav.next { right: 10px; }

/* ── Notice List ──────────────────────────────────────────────────────────── */
.notice-list {
  display: flex; flex-direction: column;
  padding: 4px var(--page-px);
}
.notice-row {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background .12s;
}
.notice-row:hover { background: var(--bg-soft); }
.notice-row-icon {
  width: 38px; height: 38px; flex-shrink: 0;
  border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: calc(22px * var(--font-scale, 1));
}
.notice-row-icon.t-general   { background: var(--maple-red-lt); color: var(--maple-red); }
.notice-row-icon.t-obituary  { background: #eef1f5; color: #4a5668; }
.notice-row-icon.t-celebration { background: var(--maple-yellow-lt); color: var(--maple-orange); }

.notice-row-body { flex: 1; min-width: 0; }
/* 제목 영역: 항상 2줄 높이를 확보하고 날짜를 오른쪽 아래(2번째 줄)에 배치 */
.notice-row-headline {
  position: relative;
  padding-right: 84px;   /* 날짜 자리 확보 (마지막 줄 오른쪽 끝) */
}
.notice-row-title {
  font-size: calc(16px * var(--font-scale, 1)); font-weight: 600; color: var(--text);
  line-height: 1.4; letter-spacing: -0.2px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.notice-row-title .pin { color: var(--maple-red); font-size: calc(12px * var(--font-scale, 1)); }
.notice-row-date {
  position: absolute; right: 0; bottom: 0;
  font-size: calc(12px * var(--font-scale, 1)); color: var(--text-4);
  line-height: 1.4; white-space: nowrap; text-align: right;
}
.notice-row-excerpt {
  margin-top: 4px;
  font-size: calc(14px * var(--font-scale, 1)); color: var(--text-3);
  line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.notice-type-badge {
  display: inline-block;
  font-size: calc(12px * var(--font-scale, 1)); font-weight: 700;
  padding: 2px 7px; border-radius: var(--r-pill);
  letter-spacing: 0.3px;
}
.ntb-general { background: var(--maple-red-lt); color: var(--maple-red); }
.ntb-obituary { background: #eef1f5; color: #4a5668; }
.ntb-celebration { background: var(--maple-yellow-lt); color: var(--maple-orange); }

/* Notice detail */
.notice-detail { padding: 4px var(--page-px) 20px; }
.notice-detail-title {
  font-size: calc(26px * var(--font-scale, 1)); font-weight: 800; letter-spacing: -0.4px;
  margin: 12px 0 6px;
}
.notice-detail-meta {
  display: flex; gap: 10px; align-items: center;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
  font-size: calc(14px * var(--font-scale, 1)); color: var(--text-4);
}
.notice-detail-content {
  padding: 18px 0;
  font-size: calc(16px * var(--font-scale, 1)); line-height: 1.7;
  color: var(--text-2);
  white-space: pre-wrap;
}
.notice-meta-card {
  margin-top: 12px; padding: 14px 16px;
  background: var(--bg-soft);
  border-radius: var(--r-md);
  border-left: 3px solid var(--maple-orange);
}
.notice-meta-card h5 { font-size: calc(14px * var(--font-scale, 1)); color: var(--maple-red-dk); font-weight: 700; margin-bottom: 8px; letter-spacing: 0.3px; }
.notice-meta-card .mm-row { display: grid; grid-template-columns: 72px 1fr; gap: 8px; padding: 3px 0; font-size: calc(14px * var(--font-scale, 1)); }
.notice-meta-card .mm-label { color: var(--text-4); font-weight: 600; font-size: calc(14px * var(--font-scale, 1)); }
.notice-meta-card .mm-value { color: var(--text); }

/* ── Modal ────────────────────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(28,36,23,0.55);
  backdrop-filter: blur(4px);
  z-index: 250;
  display: flex; align-items: center; justify-content: center;
  padding: 16px;
}
.modal-box {
  background: var(--bg);
  border-radius: var(--r-lg);
  width: 100%;
  max-width: var(--max-w);
  max-height: 88dvh;
  overflow: hidden;
  box-shadow: 0 10px 40px rgba(0,0,0,0.2);
  display: flex;
  flex-direction: column;
}
.modal-box > #modal-content {
  overflow-y: auto;
  flex: 1 1 auto;
  min-height: 0;
}
.modal-box > #modal-content::-webkit-scrollbar { width: 8px; }
.modal-box > #modal-content::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.2); border-radius: 4px; }
.modal-box > #modal-content::-webkit-scrollbar-track { background: transparent; }

/* ── Toast ────────────────────────────────────────────────────────────────── */
.toast {
  position: fixed; bottom: 80px; left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--text); color: #fff;
  padding: 11px 18px; border-radius: var(--r-pill);
  font-size: calc(14px * var(--font-scale, 1)); font-weight: 500;
  box-shadow: 0 4px 16px rgba(0,0,0,0.25);
  opacity: 0; pointer-events: none;
  transition: opacity .25s, transform .25s;
  z-index: 400;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ── Forms (admin) ───────────────────────────────────────────────────────── */
.form-input, .form-textarea, .form-select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border-md);
  border-radius: var(--r-sm);
  font-size: calc(16px * var(--font-scale, 1));
  color: var(--text);
  background: var(--bg);
  font-family: inherit;
  transition: border-color .12s;
}
.form-input:focus, .form-textarea:focus, .form-select:focus {
  outline: none;
  border-color: var(--maple-red);
  box-shadow: 0 0 0 3px rgba(43,135,0,0.12);
}
.form-textarea { resize: vertical; min-height: 80px; }

/* 리치 에디터 (업체설명) */
.rich-editor {
  border: 1px solid var(--border-md);
  border-radius: var(--r-sm);
  background: var(--bg);
  overflow: hidden;
}
.rich-editor:focus-within {
  border-color: var(--maple-red);
  box-shadow: 0 0 0 3px rgba(43,135,0,0.12);
}
.rich-toolbar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 4px;
  padding: 6px 8px;
  background: var(--bg-soft);
  border-bottom: 1px solid var(--border);
}
.rt-btn {
  height: 28px; min-width: 32px;
  padding: 0 8px;
  border: 1px solid var(--border);
  background: var(--bg);
  border-radius: var(--r-xs, 4px);
  font-size: calc(11px * var(--font-scale, 1));
  cursor: pointer; font-family: inherit;
  color: var(--text-2);
  transition: background .12s, border-color .12s;
}
.rt-btn:hover { background: var(--maple-red-lt); border-color: var(--maple-red); color: var(--maple-red-dk); }
.rt-btn:active { transform: translateY(1px); }
.rt-size {
  height: 28px;
  padding: 0 6px;
  border: 1px solid var(--border);
  border-radius: var(--r-xs, 4px);
  background: var(--bg);
  font-size: calc(10px * var(--font-scale, 1));
  font-family: inherit;
  cursor: pointer;
}
.rt-sep {
  display: inline-block;
  width: 1px; height: 18px;
  background: var(--border);
  margin: 0 4px;
}
.rt-color-btn { display: inline-flex; align-items: center; justify-content: center; padding: 0 6px; }
.rt-color-dot {
  width: 14px; height: 14px; border-radius: 50%;
  border: 1px solid rgba(0,0,0,0.2); display: inline-block;
  box-shadow: 0 0 0 1px #fff inset;
}
.rt-color-pop {
  position: fixed; z-index: 9999;
  background: var(--bg); border: 1px solid var(--border-md); border-radius: 8px;
  padding: 6px; box-shadow: 0 8px 24px rgba(0,0,0,0.15);
  display: grid; grid-template-columns: repeat(8, 22px); gap: 4px;
}
.rt-color-cell {
  width: 22px; height: 22px; border-radius: 4px;
  border: 1px solid rgba(0,0,0,0.1); cursor: pointer; padding: 0;
  transition: transform 0.08s;
}
.rt-color-cell:hover { transform: scale(1.15); border-color: var(--maple-red); }
.rich-content {
  min-height: 140px;
  max-height: 360px; overflow-y: auto;
  padding: 12px 14px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--text);
  outline: none;
  white-space: pre-wrap; word-break: break-word;
}
.rich-content ul { padding-left: 24px; list-style: disc; }
.rich-content ol { padding-left: 24px; list-style: decimal; }
.rich-content blockquote { padding-left: 12px; border-left: 3px solid var(--border-md); margin: 4px 0; }
.rich-content:empty::before {
  content: attr(data-placeholder);
  color: var(--text-4);
}
.form-row { margin-bottom: 12px; }
.form-label { display: block; font-size: calc(14px * var(--font-scale, 1)); font-weight: 600; color: var(--text-3); margin-bottom: 5px; }
.form-hint { font-size: calc(12px * var(--font-scale, 1)); color: var(--text-4); margin-top: 4px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 16px;
  border-radius: var(--r-sm);
  font-size: calc(14px * var(--font-scale, 1)); font-weight: 600;
  border: 1px solid var(--border-md);
  background: var(--bg); color: var(--text);
  cursor: pointer;
  transition: all .15s;
}
.btn:hover { border-color: var(--maple-red); color: var(--maple-red); }
.btn-primary {
  background: var(--grad-maple);
  border-color: transparent;
  color: #fff;
  font-weight: 700;
  text-shadow: 0 1px 2px rgba(0,0,0,0.20);
  box-shadow: 0 3px 10px rgba(31,143,6,0.35);
}
.btn-primary:hover { color: #fff; filter: brightness(1.05); }
.btn-danger {
  background: #f2faef;
  border-color: rgba(89,204,2,0.25);
  color: var(--red);
}
.btn-danger:hover { border-color: var(--red); color: var(--red); background: #fee; }
.btn-sm { padding: 6px 10px; font-size: calc(14px * var(--font-scale, 1)); }

/* ── Empty state ─────────────────────────────────────────────────────────── */
.empty {
  padding: 60px var(--page-px);
  text-align: center;
  color: var(--text-4);
}
.empty-icon { font-size: calc(58px * var(--font-scale, 1)); opacity: 0.4; margin-bottom: 12px; }
.empty-text { font-size: calc(14px * var(--font-scale, 1)); }

/* ── Loading ──────────────────────────────────────────────────────────────── */
.loading {
  padding: 40px; text-align: center;
  font-size: calc(14px * var(--font-scale, 1)); color: var(--text-4);
}

/* ── Tabs (notice sub-categories) ────────────────────────────────────────── */
.tab-bar {
  display: flex;
  padding: 4px 16px 0;
  gap: 0;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
  position: sticky; top: var(--top-h);
  z-index: 50;
}
.tab-bar .tab {
  flex: 1;
  padding: 12px 8px;
  border: none; background: none;
  font-size: calc(16px * var(--font-scale, 1)); font-weight: 600;
  color: var(--text-4); cursor: pointer;
  position: relative;
  transition: color .15s;
}
.tab-bar .tab.active { color: var(--maple-red-dk); }
.tab-bar .tab.active::after {
  content: '';
  position: absolute; bottom: -1px; left: 12px; right: 12px;
  height: 2px;
  background: var(--grad-maple);
  border-radius: 2px;
}

/* ── Admin upload ────────────────────────────────────────────────────────── */
.upload-dropzone {
  padding: 20px;
  border: 2px dashed var(--border-md);
  border-radius: var(--r-md);
  text-align: center;
  background: var(--bg-soft);
  cursor: pointer;
  transition: all .15s;
}
.upload-dropzone:hover { border-color: var(--maple-red); background: var(--maple-red-lt); }
.upload-dropzone input { display: none; }
.upload-icon { font-size: calc(42px * var(--font-scale, 1)); margin-bottom: 6px; }
.upload-hint { font-size: calc(14px * var(--font-scale, 1)); color: var(--text-4); }

/* Photo slot grid (6 slots, empty = click to fill) */
.photo-slot-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  margin-top: 10px;
}
.photo-slot-grid[data-uploading="1"] { opacity: 0.6; pointer-events: none; }
.photo-slot {
  aspect-ratio: 1; border-radius: var(--r-sm);
  overflow: hidden; position: relative;
  background: var(--gray-100);
  border: 1px dashed var(--border-md);
  padding: 0; margin: 0;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  flex-direction: column; gap: 4px;
  color: var(--text-4);
  transition: all .15s;
}
.photo-slot.empty:hover {
  border-color: var(--maple-red);
  background: var(--maple-red-lt);
  color: var(--maple-red);
}
.photo-slot.filled {
  border-style: solid;
  cursor: default;
}
.photo-slot img { width: 100%; height: 100%; object-fit: cover; }
.photo-slot-plus { font-size: calc(34px * var(--font-scale, 1)); font-weight: 300; line-height: 1; }
.photo-slot-hint { font-size: calc(12px * var(--font-scale, 1)); }
.photo-slot-actions {
  display: flex; flex-direction: column; gap: 4px;
  width: 100%; padding: 0 8px; margin-top: 6px;
}
.photo-slot-btn {
  font-size: calc(10px * var(--font-scale, 1)); font-weight: 600; padding: 5px 6px;
  border: 1px solid var(--border-md); border-radius: 6px;
  background: #fff; color: var(--text-2); cursor: pointer;
  font-family: inherit; line-height: 1.2;
}
.photo-slot-btn:hover { background: var(--maple-red-lt); border-color: var(--maple-red); color: var(--maple-red); }
.photo-slot-btn.danger { color: var(--red, #d92d20); border-color: #fca5a5; }
.photo-slot-btn.danger:hover { background: #fee2e2; color: #b91c1c; border-color: #ef4444; }

.photo-slot.filled {
  padding: 0; display: flex; flex-direction: column;
}
.photo-slot.filled img {
  width: 100%; flex: 1 1 auto; min-height: 0;
  object-fit: cover;
}
/* 우상단 제거(X) 버튼 */
.photo-slot-x {
  position: absolute; top: 6px; right: 6px;
  width: 26px; height: 26px; border-radius: 50%;
  border: none; background: rgba(0,0,0,0.55); color: #fff;
  font-size: 16px; line-height: 1; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  z-index: 3; transition: all .12s;
  font-family: inherit; padding: 0;
}
.photo-slot-x:hover { background: var(--red, #d92d20); transform: scale(1.08); }
/* 대표이미지 뱃지 — 좌상단 작게 표시 */
.photo-slot-rep {
  position: absolute; top: 6px; left: 6px;
  background: var(--maple-red); color: #fff;
  font-size: calc(9px * var(--font-scale, 1)); font-weight: 700;
  padding: 3px 8px; border-radius: 4px;
  z-index: 3; letter-spacing: 0.3px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
/* 빈 슬롯 (대표 자리) 시각적 강조 */
.photo-slot.empty.is-rep {
  border-color: var(--maple-red);
  background: var(--maple-red-lt);
  color: var(--maple-red-dk);
}
.photo-slot-hint small { font-size: 0.85em; opacity: 0.85; }
.photo-slot.filled .photo-slot-actions {
  margin-top: 0; padding: 4px; background: rgba(255,255,255,0.9);
}

.btn.btn-danger-soft {
  background: #fff; color: var(--red, #d92d20); border: 1px solid #fca5a5;
}
.btn.btn-danger-soft:hover { background: #fee2e2; border-color: #ef4444; }

/* 대표이미지: 업체사진 슬롯과 동일 크기 */
.thumb-row {
  display: grid; grid-template-columns: 1fr 2fr; gap: 10px; align-items: flex-start;
}
.thumb-preview-box {
  aspect-ratio: 1; border-radius: var(--r-sm);
  overflow: hidden; background: var(--gray-100);
  border: 1px dashed var(--border-md);
  position: relative;
  transition: border-color .12s, background .12s;
}
.thumb-preview-box img { width: 100%; height: 100%; object-fit: cover; display: block; position: relative; z-index: 1; }
.thumb-preview-box .drop-hint {
  position: absolute; inset: 0; z-index: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: calc(10px * var(--font-scale, 1)); color: var(--text-4); text-align: center;
  padding: 8px; pointer-events: none;
}
.thumb-preview-box.drag-over {
  border: 2px dashed var(--maple-red);
  background: var(--maple-red-lt);
}
.photo-slot.drag-over {
  border: 2px dashed var(--maple-red) !important;
  background: var(--maple-red-lt) !important;
  transform: scale(1.02);
}
.thumb-controls { display: flex; flex-direction: column; }
.thumb-btn-row { display: flex; gap: 6px; flex-wrap: wrap; }
.thumb-btn-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.thumb-btn-grid .btn { padding: 8px 10px; font-size: calc(12px * var(--font-scale, 1)); }

/* 이미지 붙여넣기 전용 다이얼로그 */
.paste-dialog-backdrop {
  position: fixed; inset: 0; z-index: 9999;
  background: rgba(0,0,0,0.5);
  display: flex; align-items: center; justify-content: center;
  padding: 16px;
}
.paste-dialog {
  background: #fff; border-radius: var(--r-md);
  padding: 20px; width: 100%; max-width: 420px;
  box-shadow: 0 12px 32px rgba(0,0,0,0.2);
}
.paste-dialog-title { font-size: calc(14px * var(--font-scale, 1)); font-weight: 700; margin-bottom: 10px; }
.paste-dialog-hint { font-size: calc(12px * var(--font-scale, 1)); color: var(--text-3); margin-bottom: 12px; line-height: 1.5; }
.paste-dialog-area {
  min-height: 100px; padding: 16px;
  border: 2px dashed var(--border-md); border-radius: 8px;
  background: var(--gray-100); color: var(--text-3);
  font-size: calc(12px * var(--font-scale, 1)); text-align: center;
  outline: none; cursor: text;
  display: flex; align-items: center; justify-content: center;
}
.paste-dialog-area:focus { border-color: var(--maple-red); background: var(--maple-red-lt); color: var(--maple-red); }
.paste-dialog-area.drag-over { border-color: var(--maple-red); background: var(--maple-red-lt); color: var(--maple-red); }
.paste-dialog-area:empty::before { content: attr(data-placeholder); }
.paste-dialog-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.paste-dialog-actions .btn { width: 100%; padding: 10px 12px; font-size: calc(12px * var(--font-scale, 1)); }

.thumb-preview-box.clickable, .photo-slot.empty.clickable { cursor: pointer; }
.thumb-preview-box.clickable:hover { border-color: var(--maple-red); background: var(--maple-red-lt); }
.photo-slot.empty.clickable:hover .photo-slot-plus,
.photo-slot.empty.clickable:hover .photo-slot-hint { color: var(--maple-red); }
.photo-slot-del {
  position: absolute; top: 4px; right: 4px;
  width: 24px; height: 24px; border-radius: 50%;
  background: rgba(0,0,0,0.65); color: #fff;
  border: none; cursor: pointer;
  font-size: calc(14px * var(--font-scale, 1)); line-height: 1;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 1px 4px rgba(0,0,0,0.3);
}
.photo-slot-del:hover { background: var(--red); }

/* Admin page layout */
.admin-shell { max-width: 980px; margin: 0 auto; padding: 16px; }
.admin-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px;
  background: var(--grad-maple);
  color: #2d6e14;
  border-radius: var(--r-md);
  margin-bottom: 18px;
}
.admin-header h1 {
  font-size: calc(22px * var(--font-scale, 1)); font-weight: 700; letter-spacing: -0.3px;
  color: #2d6e14; text-shadow: 0 1px 2px rgba(255,255,255,0.35);
}
.admin-header .btn {
  background: rgba(255,255,255,0.35) !important;
  color: #2d6e14 !important;
  border-color: rgba(45,110,20,0.25) !important;
  text-shadow: 0 1px 1px rgba(255,255,255,0.3);
  font-weight: 700;
}
.admin-header .btn:hover {
  background: rgba(255,255,255,0.55) !important;
  border-color: rgba(45,110,20,0.45) !important;
}
.admin-tab-row {
  display: flex; gap: 6px; margin-bottom: 14px;
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
}
.admin-tab {
  padding: 10px 16px;
  border: none; background: none;
  font-size: calc(16px * var(--font-scale, 1)); font-weight: 600;
  color: var(--text-3); cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  white-space: nowrap;
}
.admin-tab.active { color: var(--maple-red-dk); border-bottom-color: var(--maple-red); }

.admin-table {
  width: 100%; border-collapse: collapse;
  font-size: calc(14px * var(--font-scale, 1));
}
.admin-table th, .admin-table td {
  padding: 10px 12px; text-align: left;
  border-bottom: 1px solid var(--border);
}
.admin-table th { background: var(--bg-soft); font-weight: 600; color: var(--text-3); font-size: calc(14px * var(--font-scale, 1)); }
.admin-table tbody tr:hover { background: var(--bg-soft); }

.admin-actions { display: flex; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; align-items: center; }
.admin-search { flex: 1; min-width: 180px; }
.admin-new-biz-btn { min-width: 140px; padding-left: 18px; padding-right: 18px; white-space: nowrap; margin-left: auto; }
.admin-actions-right { display: flex; justify-content: flex-end; margin-bottom: 14px; }

/* 사이트 설정 카드 그룹 */
.settings-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  padding: 18px 20px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}
.settings-card-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 14px;
}
.settings-card-title {
  font-size: calc(15px * var(--font-scale, 1));
  font-weight: 700;
  color: var(--text-1);
  margin: 0 0 14px;
}
.settings-card-head .settings-card-title { margin-bottom: 0; }
.settings-card-danger {
  border-color: rgba(89,204,2,0.3);
  background: linear-gradient(0deg, rgba(89,204,2,0.03), rgba(89,204,2,0.03)), var(--bg);
}

/* Business admin 2-line row list */
.biz-admin-list {
  display: flex; flex-direction: column;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  overflow: hidden;
  background: var(--bg);
}

/* select 안의 <hr> 구분선 — 끝까지 연한 회색 */
select hr {
  border: none;
  height: 1px;
  background: rgba(0,0,0,0.12);
  margin: 4px 0;
}
.biz-row {
  display: grid;
  grid-template-columns: 32px 44px minmax(0,1.1fr) minmax(0,1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  transition: background .12s;
  background: var(--bg);
}
.biz-row.biz-row-alt { background: #f7fbec; }
.biz-row:hover { background: var(--maple-yellow-lt, #e6f5da); }
.biz-row-num {
  font-size: calc(13px * var(--font-scale, 1));
  font-weight: 700;
  color: var(--text-4);
  text-align: center;
  font-variant-numeric: tabular-nums;
}
/* 카테고리 아이콘 그리드 (100종 픽커) */
.icon-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(40px, 1fr));
  gap: 4px;
  margin-top: 8px;
  max-height: 320px;
  overflow-y: auto;
  padding: 6px;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  background: var(--bg-soft);
}
.icon-tile {
  width: 100%; aspect-ratio: 1;
  display: flex; align-items: center; justify-content: center;
  border: 1.5px solid transparent; border-radius: 6px;
  background: var(--bg); color: var(--text-2);
  cursor: pointer; padding: 0; font-family: inherit;
  transition: all .12s;
}
.icon-tile:hover { border-color: var(--maple-orange); background: var(--maple-orange-lt); color: var(--maple-red-dk); transform: scale(1.05); }
.icon-tile.selected {
  border-color: var(--maple-red); background: var(--maple-red-lt); color: var(--maple-red-dk);
  box-shadow: 0 0 0 2px rgba(88,204,2,0.2);
}
.icon-tile svg { width: 22px; height: 22px; }
.icon-tile.small { aspect-ratio: auto; }

/* 별표/휴지통 배지 배경 (업체 카드) */
.biz-row > .biz-row-actions .icon-btn {
  background: var(--maple-yellow-lt, #e8f7cc);
  color: var(--maple-orange, #4faf14);
  border-radius: 8px;
}
.biz-row > .biz-row-actions .icon-btn:hover {
  background: var(--maple-orange, #4faf14); color: #fff;
}
.biz-row > .biz-row-actions .icon-btn.on {
  background: var(--maple-yellow-lt, #e8f7cc);
  color: var(--maple-orange, #4faf14);
}
.biz-row > .biz-row-actions .icon-btn.danger {
  background: #fee; color: var(--red);
}
.biz-row > .biz-row-actions .icon-btn.danger:hover {
  background: var(--red); color: #fff;
}

/* 좁은 화면 — 4줄 세로 스택: 번호+이름 / 상호+카테고리 / 전화 / 주소 */
@media (max-width: 720px) {
  .biz-row {
    grid-template-columns: 28px 44px minmax(0,1fr) auto;
    grid-template-rows: repeat(4, auto);
    column-gap: 8px;
    row-gap: 2px;
    align-items: start;
  }
  .biz-row > .biz-row-num {
    grid-column: 1; grid-row: 1 / -1;
    align-self: start; margin-top: 4px;
  }
  .biz-row > .biz-row-thumb {
    grid-column: 2; grid-row: 1 / -1;
    align-self: start; margin-top: 2px;
  }
  .biz-row > .biz-row-actions {
    grid-column: 4; grid-row: 1 / -1;
    align-self: start;
  }
  /* col 래퍼는 display:contents로 자식을 grid item으로 노출 */
  .biz-row > .biz-row-col { display: contents; }
  /* col1 (좌): l1=이름→row1, l2=전화→row3 */
  .biz-row > .biz-row-col:nth-of-type(1) > .biz-row-l1 { grid-column: 3; grid-row: 1; }
  .biz-row > .biz-row-col:nth-of-type(1) > .biz-row-l2 { grid-column: 3; grid-row: 3; }
  /* col2 (우): l1=상호→row2, l2=주소→row4 */
  .biz-row > .biz-row-col:nth-of-type(2) > .biz-row-l1 { grid-column: 3; grid-row: 2; }
  .biz-row > .biz-row-col:nth-of-type(2) > .biz-row-l2 { grid-column: 3; grid-row: 4; }
}
/* Notice admin row: type badge | title+date | actions */
.biz-row.notice-row-admin {
  grid-template-columns: auto minmax(0,1fr) auto;
}
.notice-row-badge { display: flex; align-items: center; }
.notice-row-badge .notice-type-badge {
  width: 56px;
  padding: 5px 0;
  font-size: calc(14px * var(--font-scale, 1)); font-weight: 700;
  text-align: center;
  letter-spacing: 0.5px;
}
.biz-row:last-child { border-bottom: none; }
.biz-row:hover { background: var(--bg-soft); }

.biz-row-thumb {
  width: 44px; height: 44px;
  border-radius: var(--r-sm);
  background: var(--grad-maple-soft);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  font-size: calc(22px * var(--font-scale, 1));
}
.biz-row-thumb img { width: 100%; height: 100%; object-fit: cover; }

.biz-row-col { min-width: 0; }
.biz-row-l1 {
  font-size: calc(16px * var(--font-scale, 1)); font-weight: 600; color: var(--text);
  line-height: 1.3;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.biz-row-l1 .batch { color: var(--text-4); font-weight: 500; font-size: calc(12px * var(--font-scale, 1)); margin-left: 2px; }
.biz-row-l2 {
  margin-top: 2px;
  font-size: calc(14px * var(--font-scale, 1)); color: var(--text-4);
  line-height: 1.3;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.biz-row-actions {
  display: flex; gap: 2px; align-items: center;
  flex-shrink: 0;
}
.icon-btn {
  width: 34px; height: 34px; padding: 0;
  border: none; background: none; cursor: pointer;
  border-radius: var(--r-sm);
  color: var(--text-4);
  display: inline-flex; align-items: center; justify-content: center;
  transition: background .12s, color .12s;
}
.icon-btn svg { width: 18px; height: 18px; fill: currentColor; }
.icon-btn:hover { background: var(--maple-red-lt); color: var(--maple-red); }
.icon-btn.on { color: var(--maple-yellow); }
.icon-btn.on:hover { color: var(--maple-orange); background: var(--maple-yellow-lt); }
.icon-btn.danger:hover { background: #fee; color: var(--red); }

/* Admin category tree */
.cat-tree {
  display: flex; flex-direction: column;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--bg);
  overflow: hidden;
}
.cat-row {
  display: grid;
  grid-template-columns: 32px 1fr auto;
  gap: 12px; align-items: center;
  padding: 4px 10px;
  border-bottom: 1px solid var(--border);
  min-height: 34px;
}
.cat-row:last-child { border-bottom: none; }
.cat-row:hover { background: var(--bg-soft); }
.cat-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border-radius: 8px;
  background: var(--maple-red-lt); color: var(--maple-red-dk);
  flex-shrink: 0;
}
.biz-row-thumb span {
  display: inline-flex; align-items: center; justify-content: center;
  width: 100%; height: 100%; border-radius: 8px;
  background: var(--maple-red-lt); color: var(--maple-red-dk);
}
.cat-name { display: flex; align-items: center; gap: 6px; font-size: calc(16px * var(--font-scale, 1)); font-weight: 700; }
.cat-count {
  font-size: calc(12px * var(--font-scale, 1)); color: var(--text-4);
  background: var(--gray-100);
  padding: 0 7px; border-radius: 9999px;
  line-height: 16px;
}
.cat-actions { display: flex; gap: 6px; }
.cat-row .icon-btn { width: 28px; height: 28px; background: var(--maple-red-lt); color: var(--maple-red-dk); border-radius: 8px; }
.cat-row .icon-btn[title*="추가"] { width: 56px; }
.cat-row .icon-btn:hover { background: var(--maple-red); color: #fff; }
.cat-row .icon-btn.danger { background: #fee; color: var(--red); }
.cat-row .icon-btn.danger:hover { background: var(--red); color: #fff; }
.cat-row .icon-btn svg { width: 15px; height: 15px; }
/* Sub-categories: 10% tighter */
.cat-row.cat-row-sub {
  padding-top: 2px;
  padding-bottom: 2px;
  min-height: 30px;
}
.cat-row.cat-row-sub .cat-name { font-size: calc(14px * var(--font-scale, 1)); font-weight: 500; }
.cat-row.cat-row-sub .cat-count { font-size: calc(10px * var(--font-scale, 1)); padding: 0 6px; line-height: 15px; }
.cat-row.cat-row-sub .icon-btn { width: 26px; height: 26px; }
.cat-row.cat-row-sub .icon-btn[title*="추가"] { width: 52px; }
.cat-row.cat-row-sub .icon-btn svg { width: 14px; height: 14px; }

.login-card {
  max-width: 380px; margin: 10vh auto 0;
  padding: 28px 24px;
  border-radius: var(--r-lg);
  background: var(--bg);
  box-shadow: 0 6px 24px rgba(43,135,0,0.12);
  border: 1px solid var(--border);
}
.login-logo {
  text-align: center; margin-bottom: 18px;
  font-size: calc(50px * var(--font-scale, 1));
}
.login-title { text-align: center; font-size: calc(22px * var(--font-scale, 1)); font-weight: 700; margin-bottom: 4px; }
.login-sub { text-align: center; color: var(--text-4); font-size: calc(14px * var(--font-scale, 1)); margin-bottom: 22px; }
