/* ============================================================
   chat-snow.css — 싱클 채팅 (SnowUI 클론)
   원본: claude.ai/design "Syncle Chat.dc.html" (e3f5848e)
   디자인 토큰·마크업을 그대로 이식한 클론 페이지 스타일.
   로더: js/pages/chat-snow.js (.cs-* 네임스페이스)
   ============================================================ */

/* ── SnowUI 토큰 (디자인 시스템 원본 값) ── */
:root {
  --blue-500: #4C98FD; --blue-600: #3771C8; --blue-400: #62B3FE; --blue-100: #EDEDFF;
  --violet-500: #7F54FF; --azure-500: #0183FC;
  --accent-purple: #A259FF; --accent-green: #0ACF83; --accent-amber: #FFC225;
  --white: #FFFFFF;
  --neutral-50: #F7F9FB; --neutral-75: #F6F7FE; --neutral-100: #F2F6FB; --neutral-150: #F5F6F9;
  --neutral-200: #E4EAF0; --neutral-300: #CFD0D2; --neutral-400: #B5B6B8; --neutral-500: #909399;
  --neutral-600: #707580; --neutral-900: #1C1C1C; --neutral-950: #1B1D25;
  --scrim-52: rgba(27,29,37,0.52);
  --surface-page: var(--white); --surface-subtle: var(--neutral-150); --surface-fill: var(--neutral-100);
  --surface-composer: var(--neutral-75); --surface-inverse: var(--neutral-950);
  --text-primary: var(--neutral-900); --text-secondary: var(--neutral-600); --text-muted: var(--neutral-400);
  --text-placeholder: var(--neutral-500);
  --border-subtle: var(--neutral-200); --border-default: #E7EBF0; --border-strong: var(--neutral-300);
  --action-primary: var(--blue-500); --action-primary-press: var(--blue-600);
  --status-danger: #FF0000;
  --radius-xs: 6px; --radius-sm: 8px; --radius-md: 12px; --radius-lg: 16px; --radius-xl: 20px;
  --radius-2xl: 24px; --radius-full: 9999px;
  --shadow-xs: 0 1px 2px rgba(27,29,37,0.04); --shadow-sm: 0 2px 8px rgba(27,29,37,0.06);
  --shadow-md: 0 8px 24px rgba(27,29,37,0.08); --shadow-lg: 0 16px 40px rgba(27,29,37,0.10);
  --shadow-xl: 0 24px 64px rgba(27,29,37,0.12); --shadow-card: 0 6px 20px rgba(27,29,37,0.06);
  --shadow-inset: inset 0 0 0 1px rgba(27,29,37,0.04);
  --cs-font: 'Pretendard Variable', Pretendard, 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Apple SD Gothic Neo', 'Malgun Gothic', sans-serif;
  --duration-fast: .15s; --ease-standard: cubic-bezier(.4,0,.2,1);
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body { margin: 0; background: var(--surface-page); color: var(--text-primary); font-family: var(--cs-font); -webkit-font-smoothing: antialiased; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgba(27,29,37,0.10); border-radius: 999px; border: 3px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-track { background: transparent; }
button { cursor: pointer; font-family: inherit; }
input, textarea { font-family: inherit; }

/* ── 앱 프레임 ── */
.cs-app { height: 100vh; height: 100dvh; display: flex; flex-direction: column; overflow: hidden; background: var(--surface-page); }

/* 톱바 */
.cs-topbar { display: flex; align-items: center; gap: 16px; padding: 11px 20px; border-bottom: 1px solid var(--border-subtle); flex-shrink: 0; z-index: 20; }
.cs-back-top {
  width: 36px; height: 36px; border: none; border-radius: var(--radius-full); background: transparent;
  color: var(--text-secondary); display: flex; align-items: center; justify-content: center;
  font-size: 20px; flex-shrink: 0; margin-left: -6px;
}
.cs-back-top:hover { background: var(--surface-fill); color: var(--text-primary); }
.cs-brand { display: flex; align-items: center; gap: 9px; min-width: 0; text-decoration: none; color: inherit; font-weight: 800; font-size: 18px; letter-spacing: -0.02em; }
.cs-logo-img { height: 34px; width: auto; display: block; }
.cs-brand-div { width: 1px; height: 15px; background: var(--border-strong); margin: 0 2px; flex-shrink: 0; }
.cs-brand-sub { font-size: 14px; color: var(--text-muted); white-space: nowrap; }
.cs-topbar-spacer { flex: 1; }
.cs-seg { display: inline-flex; background: var(--surface-fill); border-radius: var(--radius-full); padding: 3px; }
.cs-seg-btn { border: none; background: transparent; color: var(--text-secondary); font-size: 14px; font-weight: 500; padding: 6px 14px; border-radius: var(--radius-full); white-space: nowrap; transition: all var(--duration-fast) var(--ease-standard); }
.cs-seg-btn.active { background: var(--white); box-shadow: var(--shadow-xs); color: var(--text-primary); }

/* 본문 그리드 */
.cs-body { flex: 1; display: grid; min-height: 0; grid-template-columns: 360px 1fr; }
.cs-app.is-narrow .cs-body { grid-template-columns: 1fr; }
.cs-app.is-narrow .cs-list { display: flex; }
.cs-app.is-narrow .cs-room { display: none; }
.cs-app.is-narrow.view-room .cs-list { display: none; }
.cs-app.is-narrow.view-room .cs-room { display: flex; }

/* ── 채팅 목록 ── */
.cs-list { display: flex; flex-direction: column; min-height: 0; min-width: 0; border-right: 1px solid var(--border-subtle); }
.cs-app.is-narrow .cs-list { border-right: none; }
.cs-list-head { padding: 20px 16px 12px; display: flex; flex-direction: column; gap: 14px; flex-shrink: 0; }
.cs-title-row { display: flex; align-items: center; gap: 8px; padding: 0 4px; }
.cs-title { font-size: 24px; font-weight: 600; letter-spacing: -0.02em; white-space: nowrap; }
.cs-unread-chip { color: var(--white); background: var(--action-primary); border-radius: var(--radius-full); padding: 2px 8px; font-size: 12px; font-weight: 600; line-height: 1.4; }
.cs-search { display: flex; align-items: center; gap: 8px; height: 42px; padding: 0 14px; background: var(--surface-fill); border-radius: var(--radius-md); }
.cs-search i { font-size: 18px; color: var(--text-muted); }
.cs-search input { flex: 1; min-width: 0; border: none; outline: none; background: transparent; font-size: 15px; color: var(--text-primary); }
.cs-search input::placeholder { color: var(--text-placeholder); }
.cs-search-clear { border: none; background: transparent; color: var(--text-muted); display: flex; padding: 0; }
.cs-chips { display: flex; gap: 8px; }
.cs-chip { border: none; background: var(--surface-fill); color: var(--text-secondary); font-size: 14px; font-weight: 500; padding: 7px 14px; border-radius: var(--radius-full); transition: all var(--duration-fast) var(--ease-standard); }
.cs-chip.active { background: var(--surface-inverse); color: var(--white); }

.cs-rows { flex: 1; overflow-y: auto; min-height: 0; padding: 0 8px 12px; }
.cs-row { display: flex; gap: 12px; width: 100%; text-align: left; padding: 12px; border: none; border-radius: var(--radius-lg); cursor: pointer; background: transparent; transition: background var(--duration-fast) var(--ease-standard); }
.cs-row:hover { background: var(--surface-fill); }
.cs-row.selected { background: var(--surface-fill); box-shadow: inset 3px 0 0 var(--action-primary); }
.cs-row-avwrap { position: relative; flex-shrink: 0; align-self: flex-start; margin-top: 2px; }
.cs-row-unread { position: absolute; top: -3px; right: -4px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: var(--radius-full); background: var(--action-primary); color: var(--white); font-size: 12px; font-weight: 600; line-height: 1; display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 2px var(--surface-page); }
.cs-row-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.cs-row-top { display: flex; align-items: center; gap: 8px; }
.cs-row-name { font-size: 15px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-row-time { margin-left: auto; font-size: 12px; color: var(--text-muted); white-space: nowrap; flex-shrink: 0; }
.cs-row-preview { font-size: 14px; color: var(--text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-row-preview.unread { color: var(--text-primary); font-weight: 600; }
.cs-row-meta { display: flex; align-items: center; gap: 6px; margin-top: 3px; min-width: 0; }
.cs-row-space { font-size: 12px; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-list-empty { padding: 60px 24px; text-align: center; color: var(--text-muted); font-size: 15px; }

/* 아바타 (이미지 or 이니셜) */
.cs-av { border-radius: var(--radius-full); background: var(--surface-fill); color: var(--text-secondary); display: flex; align-items: center; justify-content: center; font-weight: 600; overflow: hidden; flex-shrink: 0; }
.cs-av img { width: 100%; height: 100%; object-fit: cover; }
.cs-av--44 { width: 44px; height: 44px; font-size: 16px; }
.cs-av--40 { width: 40px; height: 40px; font-size: 15px; }

/* 뱃지 (SnowUI Badge soft) */
.cs-badge { display: inline-flex; align-items: center; padding: 3px 8px; border-radius: var(--radius-xs); font-size: 12px; font-weight: 600; line-height: 1.3; white-space: nowrap; flex-shrink: 0; }
.cs-badge--neutral { background: var(--surface-fill); color: var(--text-secondary); }
.cs-badge--blue { background: rgba(76,152,253,0.14); color: var(--blue-600); }
.cs-badge--amber { background: rgba(255,194,37,0.18); color: #946B00; }
.cs-badge--green { background: rgba(10,207,131,0.14); color: #0A9E66; }

/* ── 채팅방 ── */
.cs-room { display: flex; flex-direction: column; min-height: 0; min-width: 0; position: relative; }
.cs-room-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; color: var(--text-muted); }
.cs-room-empty i { font-size: 40px; opacity: .5; }
.cs-room-empty p { margin: 0; font-size: 15px; }

.cs-room-head { display: flex; align-items: center; gap: 11px; padding: 12px 16px; border-bottom: 1px solid var(--border-subtle); flex-shrink: 0; z-index: 5; }
.cs-back { width: 36px; height: 36px; border: none; background: transparent; color: var(--text-secondary); display: none; align-items: center; justify-content: center; border-radius: var(--radius-full); margin-left: -6px; font-size: 20px; }
.cs-app.is-narrow .cs-back { display: flex; }
.cs-back:hover { background: var(--surface-fill); }
.cs-room-names { display: flex; flex-direction: column; min-width: 0; gap: 1px; }
.cs-room-name { font-size: 18px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-room-sub { font-size: 12px; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-room-spacer { flex: 1; }
.cs-icon-btn { width: 36px; height: 36px; border: none; background: transparent; color: var(--text-secondary); display: flex; align-items: center; justify-content: center; border-radius: var(--radius-full); font-size: 20px; }
.cs-icon-btn:hover { background: var(--surface-fill); }

/* 고정 공간 카드 */
.cs-space-card { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--border-subtle); flex-shrink: 0; cursor: pointer; }
.cs-space-card:hover { background: var(--surface-fill); }
.cs-space-thumb { width: 46px; height: 46px; border-radius: var(--radius-md); background: linear-gradient(135deg,#6E86C8,#4C98FD); flex-shrink: 0; display: flex; align-items: center; justify-content: center; color: var(--white); font-size: 22px; overflow: hidden; }
.cs-space-thumb img { width: 100%; height: 100%; object-fit: cover; }
.cs-space-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.cs-space-top { display: flex; align-items: center; gap: 6px; min-width: 0; }
.cs-space-title { font-size: 15px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-space-sub { font-size: 14px; color: var(--text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-space-sub b { color: var(--action-primary); font-weight: 600; }
.cs-space-card > i { font-size: 18px; color: var(--text-muted); flex-shrink: 0; }

/* 메시지 영역 */
.cs-msgs { flex: 1; overflow-x: hidden; overflow-y: auto; min-height: 0; padding: 18px 20px 22px; }
.cs-guide-wrap { display: flex; justify-content: center; margin-bottom: 18px; }
.cs-guide-pill { display: inline-flex; align-items: center; gap: 8px; background: var(--surface-page); border-radius: var(--radius-full); padding: 7px 14px; box-shadow: var(--shadow-sm); font-size: 12px; color: var(--text-secondary); }
.cs-guide-pill i { font-size: 15px; color: var(--action-primary); }
.cs-guide-pill b { color: var(--text-primary); font-weight: 600; }
.cs-date-wrap { display: flex; justify-content: center; margin: 16px 0 12px; }
.cs-date-pill { font-size: 12px; color: var(--text-muted); background: var(--surface-fill); border-radius: var(--radius-full); padding: 4px 12px; font-weight: 500; }
.cs-sys-wrap { display: flex; justify-content: center; margin: 12px 0; }
.cs-sys-pill { font-size: 12px; color: var(--action-primary); background: var(--blue-100); border-radius: var(--radius-full); padding: 6px 14px; font-weight: 600; text-align: center; }

.cs-msg { display: flex; justify-content: flex-start; margin-bottom: 3px; }
.cs-msg.own { justify-content: flex-end; }
.cs-msg.group-end { margin-bottom: 14px; }
.cs-msg-col { display: flex; flex-direction: column; align-items: flex-start; max-width: min(78%, 540px); }
.cs-msg.own .cs-msg-col { align-items: flex-end; }
.cs-bubble { background: var(--surface-subtle); color: var(--text-primary); padding: 10px 14px; border-radius: 16px; box-shadow: var(--shadow-inset); font-size: 16px; line-height: 1.5; white-space: pre-wrap; word-break: break-word; }
.cs-msg.group-end:not(.own) .cs-bubble { border-radius: 16px 16px 16px 5px; }
.cs-msg.own .cs-bubble { background: var(--action-primary); color: var(--white); box-shadow: none; }
.cs-msg.own.group-end .cs-bubble { border-radius: 16px 16px 5px 16px; }
.cs-caption { font-size: 12px; color: var(--text-muted); margin-top: 4px; padding: 0 2px; }

/* 사진 메시지 (실제 이미지) */
.cs-photo { max-width: 240px; border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-sm); cursor: zoom-in; }
.cs-photo img { display: block; width: 100%; height: auto; }
.cs-photo-expired { width: 220px; height: 130px; border-radius: var(--radius-lg); background: var(--surface-subtle); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; color: var(--text-muted); font-size: 12px; }
.cs-photo-expired i { font-size: 26px; }

/* 카드 공통 (견적/방문 일정) */
.cs-card { border-radius: var(--radius-xl); background: var(--surface-page); box-shadow: var(--shadow-card); overflow: hidden; }
.cs-card-head { display: flex; align-items: center; gap: 9px; padding: 15px 16px 12px; }
.cs-card-icon { width: 30px; height: 30px; border-radius: var(--radius-sm); display: flex; align-items: center; justify-content: center; font-size: 17px; flex-shrink: 0; }
.cs-card-icon--quote { background: var(--blue-100); color: var(--action-primary); }
.cs-card-icon--tour { background: rgba(162,89,255,0.14); color: var(--accent-purple); }
.cs-card-title { font-size: 18px; font-weight: 600; }
.cs-card-head .cs-badge { margin-left: auto; }

.cs-quote { width: 300px; }
.cs-quote-body { padding: 0 16px 12px; display: flex; flex-direction: column; gap: 9px; }
.cs-quote-line { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.cs-quote-line span:first-child { color: var(--text-secondary); }
.cs-quote-line span:last-child { color: var(--text-primary); font-weight: 600; text-align: right; }
.cs-quote-div { height: 1px; background: var(--border-subtle); margin: 3px 0; }
.cs-quote-total { display: flex; justify-content: space-between; align-items: baseline; }
.cs-quote-total span:first-child { font-size: 16px; font-weight: 600; }
.cs-quote-total span:last-child { font-size: 20px; color: var(--action-primary); font-weight: 600; }
.cs-card-foot { padding: 0 16px 16px; }
.cs-card-note { padding: 2px 16px 16px; display: flex; align-items: center; justify-content: center; gap: 6px; font-size: 14px; font-weight: 600; }
.cs-card-note--amber { color: #946B00; }
.cs-card-note--green { color: #0A9E66; }
.cs-card-note--muted { color: var(--text-muted); font-weight: 400; padding: 4px 0 14px; }

.cs-tour { width: 270px; padding: 15px 16px; display: flex; flex-direction: column; gap: 10px; }
.cs-tour-date { font-size: 20px; font-weight: 600; }
.cs-tour-time { font-size: 16px; color: var(--text-secondary); margin-top: -6px; }

/* 버튼 (SnowUI Button primary) */
.cs-btn { border: none; border-radius: var(--radius-md); background: var(--action-primary); color: var(--white); font-size: 15px; font-weight: 600; display: inline-flex; align-items: center; justify-content: center; gap: 6px; transition: background var(--duration-fast) var(--ease-standard); white-space: nowrap; }
.cs-btn:hover { background: var(--action-primary-press); }
.cs-btn:disabled { background: var(--neutral-200); color: var(--neutral-500); cursor: default; }
.cs-btn--md { height: 40px; padding: 0 16px; width: 100%; }
.cs-btn--lg { height: 48px; padding: 0 18px; width: 100%; font-size: 16px; }

/* ── 컴포저 ── */
.cs-composer-bar { display: flex; align-items: flex-end; gap: 10px; padding: 12px 16px 16px; border-top: 1px solid var(--border-subtle); flex-shrink: 0; }
.cs-plus { width: 44px; height: 44px; border-radius: var(--radius-full); border: none; background: var(--surface-fill); color: var(--text-primary); display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 20px; }
.cs-plus:hover { background: var(--neutral-200); }
.cs-composer { flex: 1; min-width: 0; border-radius: var(--radius-lg); background: var(--surface-composer); padding: 12px 14px 10px; display: flex; flex-direction: column; gap: 8px; border: 1.5px solid transparent; transition: box-shadow var(--duration-fast) var(--ease-standard); }
.cs-composer.focus { background: linear-gradient(var(--white), var(--white)) padding-box, linear-gradient(135deg, var(--violet-500), var(--azure-500)) border-box; box-shadow: 0 8px 28px rgba(127,84,255,0.14); }
.cs-composer textarea { width: 100%; max-height: 120px; border: none; outline: none; background: transparent; resize: none; font-size: 16px; line-height: 1.5; color: var(--text-primary); padding: 0; }
.cs-composer textarea::placeholder { color: var(--text-placeholder); }
.cs-composer-foot { display: flex; align-items: center; justify-content: flex-end; }
.cs-send { border: none; border-radius: var(--radius-sm); height: 34px; padding: 0 16px; background: var(--action-primary); color: var(--white); font-size: 14px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; transition: opacity var(--duration-fast); }
.cs-send:disabled { background: var(--neutral-200); color: var(--neutral-500); cursor: default; }

/* 토스트 */
.cs-toast-wrap { position: absolute; left: 0; right: 0; bottom: 96px; display: flex; justify-content: center; pointer-events: none; z-index: 40; }
.cs-toast { display: inline-flex; align-items: center; gap: 8px; background: var(--surface-inverse); color: var(--white); border-radius: var(--radius-full); padding: 10px 18px; box-shadow: var(--shadow-md); font-size: 14px; font-weight: 500; }
.cs-toast i { font-size: 16px; color: var(--accent-green); }

/* ── 오버레이 ── */
.cs-overlay { position: fixed; inset: 0; background: var(--scrim-52); z-index: 150; display: flex; justify-content: center; align-items: center; }
.cs-app.is-narrow ~ .cs-overlay, .cs-overlay.narrow { align-items: flex-end; }
.cs-panel { width: min(100%, 460px); max-height: 86vh; background: var(--surface-page); border-radius: 22px; box-shadow: var(--shadow-lg); display: flex; flex-direction: column; overflow: hidden; }
.cs-overlay.narrow .cs-panel { width: 100%; border-radius: 22px 22px 0 0; max-height: 90vh; }
.cs-grab { display: none; justify-content: center; padding-top: 10px; flex-shrink: 0; }
.cs-grab span { width: 40px; height: 4px; border-radius: var(--radius-full); background: var(--border-strong); }
.cs-overlay.narrow .cs-grab { display: flex; }
.cs-panel-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px 12px; flex-shrink: 0; }
.cs-panel-title { font-size: 20px; font-weight: 600; white-space: nowrap; }
.cs-panel-close { width: 32px; height: 32px; border: none; background: var(--surface-fill); border-radius: var(--radius-full); color: var(--text-secondary); display: flex; align-items: center; justify-content: center; font-size: 16px; }
.cs-panel-sub { padding: 18px 20px 8px; font-size: 18px; font-weight: 600; }
.cs-panel-body { flex: 1; overflow-y: auto; min-height: 0; padding: 0 20px 8px; }
.cs-panel-foot { flex-shrink: 0; padding: 12px 20px 20px; border-top: 1px solid var(--border-subtle); }
.cs-panel-summary { font-size: 12px; color: var(--text-secondary); text-align: center; margin-bottom: 10px; }

/* + 시트 / 방 메뉴 액션 */
.cs-actions { padding: 4px 12px 14px; }
.cs-action { display: flex; align-items: center; gap: 14px; width: 100%; text-align: left; border: none; background: transparent; padding: 13px 12px; border-radius: var(--radius-md); }
.cs-action:hover { background: var(--surface-fill); }
.cs-action-icon { width: 40px; height: 40px; border-radius: var(--radius-md); display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 20px; }
.cs-action-texts { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.cs-action-label { font-size: 16px; font-weight: 600; color: var(--text-primary); }
.cs-action-desc { font-size: 12px; color: var(--text-muted); }
.cs-menu-item { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: none; background: transparent; padding: 15px 12px; border-radius: var(--radius-md); font-size: 16px; font-weight: 500; color: var(--text-primary); }
.cs-menu-item:hover { background: var(--surface-fill); }
.cs-menu-item i { font-size: 20px; }
.cs-menu-item.danger { color: var(--status-danger); }

/* 예약/방문 시트 내부 */
.cs-sheet-space { display: flex; align-items: center; gap: 11px; padding: 12px; background: var(--surface-subtle); border-radius: var(--radius-md); margin-bottom: 18px; }
.cs-sheet-space .cs-space-thumb { width: 42px; height: 42px; border-radius: var(--radius-sm); font-size: 20px; }
.cs-sheet-space-name { font-size: 15px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-sheet-space-rate { font-size: 12px; color: var(--text-secondary); }
.cs-sec-label { font-size: 14px; color: var(--text-secondary); font-weight: 600; margin-bottom: 10px; display: flex; align-items: center; justify-content: space-between; }
.cs-sec-label .nav { display: inline-flex; align-items: center; gap: 4px; color: var(--text-muted); font-weight: 400; }
.cs-sec-label .nav button { width: 26px; height: 26px; border: none; border-radius: var(--radius-full); background: var(--surface-fill); color: var(--text-secondary); font-size: 12px; display: inline-flex; align-items: center; justify-content: center; }
.cs-cal { margin-bottom: 20px; }
.cs-cal-dow { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; margin-bottom: 6px; }
.cs-cal-dow span { text-align: center; font-size: 12px; font-weight: 600; color: var(--text-muted); }
.cs-cal-dow span.sun { color: var(--status-danger); }
.cs-cal-dow span.sat { color: var(--action-primary); }
.cs-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.cs-cal-cell { height: 38px; border: none; border-radius: var(--radius-full); background: transparent; color: var(--text-primary); font-size: 14px; }
.cs-cal-cell:disabled { color: var(--text-muted); cursor: default; }
.cs-cal-cell.sel { background: var(--action-primary); color: var(--white); font-weight: 600; }
.cs-slots { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.cs-slot { border: none; background: var(--surface-fill); color: var(--text-primary); font-size: 14px; font-weight: 500; padding: 8px 15px; border-radius: var(--radius-full); transition: all var(--duration-fast) var(--ease-standard); }
.cs-slot.active { background: var(--action-primary); color: var(--white); }
.cs-stepper-row { display: flex; align-items: center; justify-content: space-between; padding: 2px 2px 16px; }
.cs-stepper { display: flex; align-items: center; gap: 14px; }
.cs-stepper button { width: 34px; height: 34px; border-radius: var(--radius-full); border: 1px solid var(--border-default); background: var(--white); color: var(--text-primary); display: flex; align-items: center; justify-content: center; font-size: 15px; }
.cs-stepper .val { font-size: 16px; font-weight: 600; min-width: 46px; text-align: center; }
.cs-rate-row { padding: 2px 2px 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.cs-rate-input { display: flex; align-items: center; gap: 6px; }
.cs-rate-input input { width: 110px; height: 36px; border: 1px solid var(--border-default); border-radius: var(--radius-sm); padding: 0 10px; font-size: 15px; text-align: right; outline: none; }
.cs-rate-input input:focus { border-color: var(--action-primary); }
.cs-quote-summary { background: var(--surface-subtle); border-radius: var(--radius-md); padding: 14px 16px; margin-bottom: 6px; display: flex; flex-direction: column; gap: 10px; }
.cs-quote-summary .line { display: flex; justify-content: space-between; font-size: 14px; }
.cs-quote-summary .line span:first-child { color: var(--text-secondary); }
.cs-quote-summary .line span:last-child { font-weight: 600; }
.cs-quote-summary .div { height: 1px; background: var(--border-subtle); }
.cs-quote-summary .total { display: flex; justify-content: space-between; align-items: baseline; }
.cs-quote-summary .total span:first-child { font-size: 16px; font-weight: 600; }
.cs-quote-summary .total span:last-child { font-size: 24px; color: var(--action-primary); font-weight: 600; }

/* 이미지 뷰어 */
.cs-viewer { position: fixed; inset: 0; z-index: 300; background: rgba(0,0,0,.85); display: flex; align-items: center; justify-content: center; padding: 32px; }
.cs-viewer img { max-width: 100%; max-height: 100%; border-radius: var(--radius-sm); }
.cs-viewer-close { position: absolute; right: 20px; top: 20px; width: 40px; height: 40px; border: none; border-radius: var(--radius-full); background: rgba(255,255,255,.14); color: #fff; font-size: 16px; }

/* 로딩 */
@keyframes csSpin { to { transform: rotate(360deg); } }
.cs-spinner { width: 22px; height: 22px; border: 2.5px solid var(--border-subtle); border-top-color: var(--action-primary); border-radius: 50%; animation: csSpin .8s linear infinite; margin: 40px auto; }
@media (prefers-reduced-motion: reduce) { .cs-spinner { animation-duration: 1.6s; } }

/* 반응형 미세 조정 */
@media (max-width: 879px) {
  .cs-brand-sub, .cs-brand-div { display: none; }
  .cs-msgs { padding: 14px 14px 18px; }
  .cs-composer-bar { padding: 10px 12px 14px; }
}
