:root {
  --bg: #f6f6f8;
  --surface: #ffffff;
  --surface-2: #f0f0f3;
  --border: #e3e3e8;
  --text: #1c1c1f;
  --muted: #6b6b76;
  --accent: #5b5bd6;
  --accent-soft: #ededfc;
  --accent-text: #ffffff;
  --bubble-me: #5b5bd6;
  --bubble-me-text: #ffffff;
  --bubble-bot: #ffffff;
  --success: #2f9e5b;
  --warn-bg: #fff6e0;
  --warn-text: #8a5a00;
  --danger: #d93f3f;
  --shadow: 0 1px 2px rgba(20, 20, 40, .05), 0 4px 16px rgba(20, 20, 40, .06);
  --radius: 16px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #111114; --surface: #1b1b20; --surface-2: #24242b; --border: #2f2f38;
    --text: #ededf2; --muted: #9a9aa8; --accent: #8b8bf5; --accent-soft: #26264a;
    --accent-text: #0f0f1a; --bubble-me: #6e6ee8; --bubble-me-text: #ffffff; --bubble-bot: #24242b;
    --warn-bg: #3a2e12; --warn-text: #f5c96a; --shadow: 0 1px 2px rgba(0,0,0,.3), 0 4px 16px rgba(0,0,0,.25);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #111114; --surface: #1b1b20; --surface-2: #24242b; --border: #2f2f38;
  --text: #ededf2; --muted: #9a9aa8; --accent: #8b8bf5; --accent-soft: #26264a;
  --accent-text: #0f0f1a; --bubble-me: #6e6ee8; --bubble-me-text: #ffffff; --bubble-bot: #24242b;
  --warn-bg: #3a2e12; --warn-text: #f5c96a; --shadow: 0 1px 2px rgba(0,0,0,.3), 0 4px 16px rgba(0,0,0,.25);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--bg); color: var(--text);
  font: 15px/1.55 -apple-system, BlinkMacSystemFont, "Apple SD Gothic Neo", "Pretendard", "Noto Sans KR", "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--accent); }
h1, h2, h3 { margin: 0; line-height: 1.25; letter-spacing: -0.01em; }
.muted { color: var(--muted); }
.small { font-size: 13px; }

/* ---------- 공통 컴포넌트 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 1px solid var(--border); background: var(--surface); border-radius: 12px;
  padding: 10px 16px; font-weight: 600; transition: transform .08s, background .15s;
}
.btn:hover { background: var(--surface-2); }
.btn:active { transform: scale(.98); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.btn.primary:hover { filter: brightness(1.06); }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.danger { color: var(--danger); }
.btn.lg { padding: 14px 22px; font-size: 16px; border-radius: 14px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.icon-btn { border: 0; background: transparent; padding: 8px; border-radius: 10px; color: var(--muted); font-size: 18px; line-height: 1; }
.icon-btn:hover { background: var(--surface-2); color: var(--text); }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.badge { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--surface-2); color: var(--muted); }
.badge.warn { background: var(--warn-bg); color: var(--warn-text); }
.badge.ok { background: color-mix(in srgb, var(--success) 15%, transparent); color: var(--success); }

.field { display: grid; gap: 6px; }
.field label { font-weight: 600; font-size: 14px; }
.field .hint { font-size: 12.5px; color: var(--muted); }
.input, textarea.input, select.input {
  width: 100%; border: 1px solid var(--border); background: var(--surface); border-radius: 12px; padding: 11px 13px; outline: none;
}
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
textarea.input { resize: vertical; min-height: 80px; }
.form-grid { display: grid; gap: 16px; grid-template-columns: 1fr 1fr; }
.form-grid .full { grid-column: 1 / -1; }

.avatar {
  width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; font-size: 22px; flex: none;
  background: color-mix(in srgb, var(--c, var(--accent)) 16%, var(--surface));
  border: 1px solid color-mix(in srgb, var(--c, var(--accent)) 30%, transparent);
}
.avatar.sm { width: 34px; height: 34px; border-radius: 11px; font-size: 17px; }
.avatar.lg { width: 64px; height: 64px; border-radius: 20px; font-size: 32px; }

#toast {
  position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(20px); opacity: 0; pointer-events: none;
  background: var(--text); color: var(--bg); padding: 10px 18px; border-radius: 12px; font-weight: 600; font-size: 14px;
  transition: all .2s; z-index: 100; max-width: calc(100% - 32px);
}
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- 상단바 ---------- */
.topbar {
  position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 12px;
  padding: 12px 20px; background: color-mix(in srgb, var(--bg) 85%, transparent); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.logo { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 17px; text-decoration: none; color: var(--text); }
.logo-mark { width: 30px; height: 30px; border-radius: 9px; background: var(--accent); color: var(--accent-text); display: grid; place-items: center; font-size: 16px; }
.topbar .spacer { flex: 1; }
.topbar .biz { font-weight: 600; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.page { max-width: 1080px; margin: 0 auto; padding: 28px 20px 60px; }

/* ---------- 온보딩 ---------- */
.onb { max-width: 760px; margin: 0 auto; padding: 40px 20px 80px; }
.steps { display: flex; gap: 8px; margin-bottom: 28px; }
.steps span { flex: 1; height: 4px; border-radius: 4px; background: var(--border); }
.steps span.on { background: var(--accent); }
.onb h1 { font-size: 28px; margin-bottom: 8px; }
.onb .lead { color: var(--muted); margin: 0 0 28px; font-size: 16px; }
.industry-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.industry {
  text-align: left; padding: 18px; border-radius: var(--radius); border: 1.5px solid var(--border); background: var(--surface);
  display: grid; gap: 6px; transition: border-color .15s, transform .1s;
}
.industry:hover { border-color: var(--accent); transform: translateY(-1px); }
.industry.sel { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.industry .emo { font-size: 28px; }
.industry b { font-size: 16px; }
.industry span { color: var(--muted); font-size: 13.5px; }
.onb-actions { display: flex; justify-content: space-between; gap: 12px; margin-top: 28px; }
.team-pick { display: grid; gap: 10px; }
.pick-row { display: flex; gap: 14px; align-items: center; padding: 14px 16px; }
.pick-row .info { flex: 1; min-width: 0; }
.pick-row .info b { display: block; }
.pick-row input { width: 20px; height: 20px; accent-color: var(--accent); flex: none; }
.pick-total { display: flex; justify-content: space-between; align-items: center; padding: 16px 18px; margin-top: 14px; background: var(--accent-soft); border-radius: var(--radius); font-weight: 600; }

/* ---------- 대시보드 ---------- */
.hero { display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px; margin-bottom: 28px; }
.hero-main { padding: 26px; }
.hero-main h1 { font-size: 26px; margin: 10px 0 8px; }
.hero-main p { margin: 0; color: var(--muted); }
.roi { padding: 22px 24px; display: grid; gap: 4px; align-content: center; }
.roi .big { font-size: 30px; font-weight: 800; letter-spacing: -0.02em; }
.roi .sub { color: var(--muted); font-size: 13.5px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin: 0 0 14px; }
.section-head h2 { font-size: 19px; }
.bot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.bot-card { padding: 18px; display: flex; flex-direction: column; gap: 12px; text-decoration: none; color: inherit; transition: transform .1s, border-color .15s; }
.bot-card:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--c) 50%, var(--border)); }
.bot-card .top { display: flex; gap: 12px; align-items: center; }
.bot-card .name { font-weight: 700; font-size: 16px; }
.bot-card .title { font-size: 13px; color: var(--muted); }
.bot-card .desc { color: var(--muted); font-size: 14px; flex: 1; margin: 0; }
.bot-card .foot { display: flex; justify-content: space-between; align-items: center; font-size: 13px; }
.bot-card .go { color: var(--accent); font-weight: 700; }
.online { width: 8px; height: 8px; border-radius: 50%; background: var(--success); display: inline-block; margin-right: 6px; }
.add-card { border-style: dashed; box-shadow: none; display: grid; place-items: center; min-height: 170px; color: var(--muted); font-weight: 600; background: transparent; }
.add-card:hover { color: var(--accent); border-color: var(--accent); }
.tips { margin-top: 28px; padding: 20px 22px; }
.tips ol { margin: 10px 0 0; padding-left: 20px; display: grid; gap: 6px; }

/* ---------- 채팅 ---------- */
.chat-layout { display: grid; grid-template-columns: 270px 1fr; height: calc(100dvh - 57px); }
.sidebar { border-right: 1px solid var(--border); overflow-y: auto; padding: 12px; background: var(--surface); }
.side-item { display: flex; gap: 10px; align-items: center; padding: 10px; border-radius: 12px; text-decoration: none; color: inherit; }
.side-item:hover { background: var(--surface-2); }
.side-item.on { background: var(--accent-soft); }
.side-item .t { min-width: 0; }
.side-item b { display: block; font-size: 14.5px; }
.side-item span { display: block; font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-back { display: block; padding: 8px 10px 14px; font-weight: 600; text-decoration: none; color: var(--muted); }
.chat { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.chat-head { display: flex; align-items: center; gap: 12px; padding: 12px 18px; border-bottom: 1px solid var(--border); background: var(--surface); }
.chat-head .t { flex: 1; min-width: 0; }
.chat-head b { display: block; }
.chat-head span { font-size: 13px; color: var(--muted); }
.mobile-back { display: none; }
.messages { flex: 1; overflow-y: auto; padding: 22px 18px; display: flex; flex-direction: column; gap: 14px; }
.msg { display: flex; gap: 10px; max-width: 760px; width: 100%; }
.msg.me { margin-left: auto; justify-content: flex-end; }
.bubble { padding: 11px 15px; border-radius: 18px; max-width: min(620px, 85%); word-break: break-word; }
.msg.me .bubble { background: var(--bubble-me); color: var(--bubble-me-text); border-bottom-right-radius: 6px; white-space: pre-wrap; }
.msg.bot .bubble { background: var(--bubble-bot); border: 1px solid var(--border); border-bottom-left-radius: 6px; }
.bubble p { margin: 0 0 8px; }
.bubble p:last-child { margin-bottom: 0; }
.bubble ul, .bubble ol { margin: 4px 0 8px; padding-left: 20px; }
.bubble h4 { margin: 10px 0 4px; font-size: 15px; }
.deliver { margin: 8px 0; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); overflow: hidden; }
.deliver .dhead { display: flex; justify-content: space-between; align-items: center; padding: 6px 8px 6px 12px; font-size: 12px; font-weight: 700; color: var(--muted); border-bottom: 1px solid var(--border); }
.deliver .dbody { padding: 10px 12px; white-space: pre-wrap; }
.copy-btn { border: 1px solid var(--border); background: var(--surface); border-radius: 8px; padding: 3px 10px; font-size: 12px; font-weight: 700; }
.msg-tools { display: flex; gap: 6px; margin-top: 6px; }
.msg-tools button { border: 0; background: transparent; color: var(--muted); font-size: 12.5px; padding: 2px 4px; }
.msg-tools button:hover { color: var(--text); }
.demo-tag { font-size: 11.5px; color: var(--warn-text); background: var(--warn-bg); padding: 1px 7px; border-radius: 6px; margin-left: 4px; }
.typing { display: inline-flex; gap: 4px; padding: 14px 16px; }
.typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); animation: blink 1.2s infinite; }
.typing i:nth-child(2) { animation-delay: .2s; } .typing i:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 0%, 80%, 100% { opacity: .25; } 40% { opacity: 1; } }

.empty { margin: auto; text-align: center; max-width: 520px; display: grid; gap: 12px; justify-items: center; padding: 20px 0; }
.empty h3 { font-size: 20px; }
.empty ul { text-align: left; margin: 0; padding-left: 20px; color: var(--muted); }
.big-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; width: 100%; margin-top: 6px; }
.big-actions button { text-align: left; padding: 14px; border-radius: 14px; border: 1px solid var(--border); background: var(--surface); font-weight: 600; }
.big-actions button:hover { border-color: var(--accent); color: var(--accent); }

.composer-wrap { border-top: 1px solid var(--border); background: var(--surface); padding: 10px 14px 14px; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 10px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; border: 1px solid var(--border); background: var(--surface-2); border-radius: 999px; padding: 6px 13px; font-size: 13.5px; font-weight: 600; }
.chip:hover { border-color: var(--accent); color: var(--accent); }
.composer { display: flex; gap: 8px; align-items: flex-end; }
.composer textarea { flex: 1; resize: none; max-height: 200px; min-height: 46px; border-radius: 14px; }
.composer .btn { height: 46px; }

/* ---------- 모달 ---------- */
.modal-bg { position: fixed; inset: 0; background: rgba(10, 10, 20, .45); display: grid; place-items: center; padding: 16px; z-index: 50; }
.modal { width: min(620px, 100%); max-height: calc(100dvh - 32px); overflow-y: auto; padding: 24px; display: grid; gap: 16px; }
.modal-actions { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }

/* ---------- 설정 ---------- */
.settings { max-width: 760px; margin: 0 auto; padding: 28px 20px 60px; display: grid; gap: 18px; }
.settings .card { padding: 22px; display: grid; gap: 14px; }
.settings h2 { font-size: 18px; }
.code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; white-space: pre-wrap; }

/* ---------- 모바일 ---------- */
@media (max-width: 760px) {
  .hero { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .chat-layout { grid-template-columns: 1fr; }
  .sidebar { display: none; }
  .mobile-back { display: inline-flex; }
  .big-actions { grid-template-columns: 1fr; }
  .topbar .biz { display: none; }
  .page, .onb, .settings { padding-left: 16px; padding-right: 16px; }
  .onb h1 { font-size: 24px; }
}

/* ---------- 전화·문자 ---------- */
.inbox-link { position: relative; text-decoration: none; }
.inbox-link .dot { position: absolute; top: 1px; right: 0; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--danger); color: var(--text); font-size: 11px; font-weight: 700; display: grid; place-items: center; }
.phone-btn { padding: 7px 12px; font-size: 13.5px; white-space: nowrap; }
.chan-tag { font-size: 11.5px; color: var(--muted); background: var(--surface-2); padding: 1px 7px; border-radius: 6px; margin-left: 4px; }
.note { padding: 12px 14px; border-radius: 12px; font-size: 14px; background: var(--surface-2); }
.note.warn { background: var(--warn-bg); color: var(--warn-text); }
.phone-num { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 16px; border-radius: 14px; background: var(--accent-soft); }
.big-num { font-size: 22px; font-weight: 800; letter-spacing: .01em; }
.toggle { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.toggle input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--accent); flex: none; }
.psec { display: grid; gap: 12px; padding-top: 14px; border-top: 1px solid var(--border); }
.psec h3 { font-size: 16px; }
.psec.sim { background: var(--surface-2); margin: 0 -24px; padding: 16px 24px; border-top: 0; }
.srow { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 14.5px; }
.draft { display: grid; gap: 8px; padding: 14px; border: 1px solid var(--border); border-radius: 14px; }
.draft-head { display: flex; gap: 10px; align-items: center; }
.asked { padding: 10px 12px; border-radius: 12px; background: var(--surface-2); font-size: 14px; }
.log { display: grid; gap: 2px; }
.log-row { display: flex; gap: 10px; padding: 10px 4px; border-bottom: 1px solid var(--border); }
.log-row:last-child { border-bottom: 0; }
.log-main { min-width: 0; display: grid; gap: 3px; }
.log-body { white-space: pre-wrap; word-break: break-word; font-size: 14px; }
.call { border: 1px solid var(--border); border-radius: 12px; padding: 10px 14px; }
.call summary { cursor: pointer; }
.turn { padding: 6px 0; font-size: 14px; }
.turn.bot b { color: var(--accent); }
.dhead > span { display: inline-flex; gap: 4px; }
@media (max-width: 760px) { .phone-btn { padding: 6px 9px; font-size: 12.5px; } .psec.sim { margin: 0 -16px; padding: 16px; } }
.lang-btn { border: 1px solid var(--border); background: var(--surface); border-radius: 999px; padding: 4px 11px; font-size: 12.5px; font-weight: 700; color: var(--muted); }
.lang-btn:hover { color: var(--text); border-color: var(--accent); }

/* ---------- WhatsApp ---------- */
.wa-card { display: flex; align-items: center; gap: 14px; padding: 16px 20px; margin-bottom: 28px; text-decoration: none; color: inherit; border-color: color-mix(in srgb, #25d366 40%, var(--border)); }
.wa-card:hover { border-color: #25d366; }
.wa-logo { font-size: 26px; }
.wa-text { flex: 1; min-width: 0; display: grid; gap: 2px; }
.wa-card .go { color: var(--accent); font-weight: 700; white-space: nowrap; }
.chan-tag.wa { background: color-mix(in srgb, #25d366 16%, var(--surface)); color: #1a8f4a; }
@media (max-width: 760px) { .wa-card { flex-wrap: wrap; } }

/* ---------- live demo (phone simulator) ---------- */
.demo-try { margin-top: 22px; width: 100%; text-align: left; padding: 16px 18px; display: grid; gap: 4px; border-style: dashed; box-shadow: none; }
.demo-try:hover { border-color: var(--accent); }
.demo-link { margin: -16px 0 28px; }
.demo-layout { display: grid; grid-template-columns: 360px 1fr; gap: 24px; align-items: start; }
.phone { position: relative; height: 680px; border-radius: 44px; background: #0b141a; border: 10px solid #1f2328; box-shadow: var(--shadow), 0 20px 50px rgba(0,0,0,.18); display: flex; flex-direction: column; overflow: hidden; }
.phone-notch { position: absolute; top: 8px; left: 50%; transform: translateX(-50%); width: 110px; height: 22px; background: #1f2328; border-radius: 12px; z-index: 2; }
.wa-head { display: flex; align-items: center; gap: 10px; padding: 40px 14px 10px; background: #1f2c33; color: var(--text); }
.wa-head b { display: block; font-size: 15px; }
.wa-head span { font-size: 12px; color: #8696a0; }
.wa-chat { flex: 1; overflow-y: auto; padding: 12px 10px; display: flex; flex-direction: column; gap: 6px;
  background-color: #0b141a; background-image: radial-gradient(rgba(var(--fg-rgb), .035) 1px, transparent 1px); background-size: 18px 18px; }
.wa-msg { display: flex; }
.wa-msg.out { justify-content: flex-end; }
.wa-bubble { max-width: 82%; padding: 7px 10px 6px; border-radius: 10px; font-size: 14px; line-height: 1.4; color: var(--text); background: #202c33; word-break: break-word; }
.wa-msg.out .wa-bubble { background: #005c4b; border-top-right-radius: 3px; }
.wa-msg.in .wa-bubble { border-top-left-radius: 3px; }
.wa-time { float: right; margin: 6px 0 -2px 8px; font-size: 11px; color: rgba(233,237,239,.6); }
.wa-typing { color: #8696a0; font-style: italic; }
.wa-note { align-self: center; font-size: 12px; color: #ffd279; background: rgba(255,210,121,.1); padding: 4px 10px; border-radius: 8px; text-align: center; }
.wa-input { display: flex; gap: 8px; padding: 8px 10px 18px; background: #0b141a; }
.wa-input input { flex: 1; border: 0; border-radius: 22px; padding: 11px 14px; background: #202c33; color: var(--text); outline: none; }
.wa-input button { width: 44px; height: 44px; border-radius: 50%; border: 0; background: #090B0A; color: var(--text); font-size: 17px; }
.wa-input button:disabled, .wa-input input:disabled { opacity: .5; }
.demo-side { display: grid; gap: 14px; }
.seg { display: flex; flex-wrap: wrap; gap: 6px; }
.seg button { border: 1px solid var(--border); background: var(--surface); border-radius: 999px; padding: 6px 12px; font-size: 13.5px; font-weight: 600; }
.seg button.on { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
@media (max-width: 860px) { .demo-layout { grid-template-columns: 1fr; } .phone { height: 560px; max-width: 380px; width: 100%; margin: 0 auto; } }
.lang-btn, .topbar .badge { white-space: nowrap; flex: none; }
@media (max-width: 760px) {
  .topbar { gap: 8px; padding: 10px 12px; }
  .topbar .badge.ok { font-size: 0; padding: 4px; }
  .topbar .badge.ok::before { content: "●"; font-size: 12px; }
  .logo { font-size: 15px; }
}

/* =====================================================================
   v2 — messenger layout (staff list | chat | details), WhatsApp-like theme
   ===================================================================== */
:root {
  --bg: #eef1f3; --surface: #ffffff; --surface-2: #f0f2f5; --panel: #f0f2f5; --border: #e3e7ea;
  --text: #111b21; --muted: #667781; --accent: #090B0A; --accent-strong: #008069; --accent-soft: #e7f8f2; --accent-text: #ffffff;
  --bubble-me: #d9fdd3; --bubble-me-text: #111b21; --bubble-bot: #ffffff; --chat-bg: #efeae2; --chat-dot: rgba(0,0,0,.045);
  --hover: #f5f6f6; --active: #e9edef; --radius: 14px;
  --shadow: 0 1px 1px rgba(11,20,26,.06), 0 2px 8px rgba(11,20,26,.05);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0c1317; --surface: #111b21; --surface-2: #202c33; --panel: #202c33; --border: #26343c;
    --text: #e9edef; --muted: #8696a0; --accent: #090B0A; --accent-strong: #090B0A; --accent-soft: #0f3a33; --accent-text: #0b141a;
    --bubble-me: #005c4b; --bubble-me-text: #e9edef; --bubble-bot: #202c33; --chat-bg: #0b141a; --chat-dot: rgba(var(--fg-rgb), .035);
    --hover: #1b262d; --active: #2a3942; --shadow: 0 1px 2px rgba(0,0,0,.35);
  }
}
:root[data-theme="dark"] {
  --bg: #0c1317; --surface: #111b21; --surface-2: #202c33; --panel: #202c33; --border: #26343c;
  --text: #e9edef; --muted: #8696a0; --accent: #090B0A; --accent-strong: #090B0A; --accent-soft: #0f3a33; --accent-text: #0b141a;
  --bubble-me: #005c4b; --bubble-me-text: #e9edef; --bubble-bot: #202c33; --chat-bg: #0b141a; --chat-dot: rgba(var(--fg-rgb), .035);
  --hover: #1b262d; --active: #2a3942; --shadow: 0 1px 2px rgba(0,0,0,.35);
}
body { font-family: "Segoe UI", -apple-system, BlinkMacSystemFont, "Helvetica Neue", "Apple SD Gothic Neo", "Noto Sans KR", sans-serif; }
body:not([data-view="setup"]) { overflow: hidden; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--text); }
.logo-mark { background: var(--accent); color: #fff; }
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 18%, transparent); }

/* ---------- shell ---------- */
.shell { display: grid; grid-template-columns: minmax(300px, 360px) 1fr; height: 100dvh; background: var(--bg); }
.shell.has-details { grid-template-columns: minmax(300px, 360px) 1fr 340px; }
.center { min-width: 0; min-height: 0; overflow-y: auto; background: var(--bg); position: relative; }
.center.is-chat { display: flex; flex-direction: column; overflow: hidden; }

/* ---------- left rail ---------- */
.rail { display: flex; flex-direction: column; min-height: 0; background: var(--surface); border-right: 1px solid var(--border); }
.rail-head { display: flex; align-items: center; gap: 8px; padding: 12px 14px; background: var(--panel); min-height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; text-decoration: none; color: var(--text); }
.brand-t { display: grid; min-width: 0; }
.brand-t b { font-size: 15.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-t small { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 5px; }
.dotw { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); display: inline-block; }
.dotw.warn { background: #f5a524; }
.rail-search { padding: 8px 12px; }
.rail-search input { width: 100%; border: 0; border-radius: 10px; background: var(--surface-2); padding: 9px 12px 9px 34px; outline: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23889' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: 11px center; }
.rail-nav { display: flex; gap: 6px; padding: 2px 12px 8px; overflow-x: auto; scrollbar-width: none; }
.rail-nav::-webkit-scrollbar { display: none; }
.nav-item { flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 6px 11px; border-radius: 999px; background: var(--surface-2); color: var(--text); text-decoration: none; font-size: 13.5px; font-weight: 600; }
.nav-item:hover { background: var(--active); }
.nav-item.on { background: var(--accent-soft); color: var(--accent-strong); }
.nav-ic { font-size: 13px; }
.rail-label { padding: 10px 16px 4px; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.contacts { flex: 1; overflow-y: auto; }
.contact { display: flex; gap: 12px; align-items: center; padding: 10px 14px; text-decoration: none; color: inherit; position: relative; }
.contact:hover { background: var(--hover); }
.contact.on { background: var(--active); }
.contact .avatar { width: 48px; height: 48px; border-radius: 50%; font-size: 23px; position: relative; }
.presence { position: absolute; right: 1px; bottom: 1px; width: 11px; height: 11px; border-radius: 50%; background: var(--accent); border: 2px solid var(--surface); }
.c-main { flex: 1; min-width: 0; border-bottom: 1px solid var(--border); padding-bottom: 10px; margin-bottom: -10px; }
.contact:last-child .c-main { border-bottom: 0; }
.c-top, .c-bottom { display: flex; align-items: center; gap: 8px; }
.c-top b { flex: 1; font-size: 15.5px; font-weight: 600; }
.c-time { font-size: 12px; color: var(--muted); }
.c-time.hot { color: var(--accent); font-weight: 700; }
.c-prev { flex: 1; min-width: 0; font-size: 13.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.c-badge { flex: none; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--accent); color: #fff; font-size: 11.5px; font-weight: 700; display: inline-grid; place-items: center; }
.rail-add { margin: 8px 12px 12px; border: 1px dashed var(--border); background: transparent; border-radius: 12px; padding: 10px; color: var(--muted); font-weight: 600; }
.rail-add:hover { color: var(--accent); border-color: var(--accent); }
.rail .lang-btn { padding: 4px 10px; }

/* ---------- chat ---------- */
.chat-head { display: flex; align-items: center; gap: 6px; padding: 8px 12px; background: var(--panel); min-height: 60px; border-left: 1px solid var(--border); }
.chat-who { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; border: 0; background: transparent; text-align: left; padding: 2px 4px; border-radius: 10px; color: inherit; }
.chat-who .avatar { width: 42px; height: 42px; border-radius: 50%; font-size: 21px; }
.chat-who b { display: block; font-size: 16px; }
.chat-who span { display: block; font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-head .icon-btn { font-size: 19px; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; }
.chat-head .icon-btn.on { background: var(--active); color: var(--text); }
.m-only { display: none !important; }
.wa-bg { background-color: var(--chat-bg); background-image: radial-gradient(var(--chat-dot) 1.2px, transparent 1.2px); background-size: 22px 22px; }
.center.is-chat .messages { flex: 1; overflow-y: auto; padding: 18px 6% 14px; gap: 4px; }
.msg { max-width: none; }
.msg + .msg.me, .msg + .msg.bot { margin-top: 2px; }
.msg.me + .msg.bot, .msg.bot + .msg.me { margin-top: 10px; }
.bubble { position: relative; padding: 7px 10px 6px; border-radius: 10px; box-shadow: 0 1px .5px rgba(11,20,26,.13); max-width: min(640px, 78%); font-size: 14.5px; line-height: 1.45; }
.msg.me .bubble { background: var(--bubble-me); color: var(--bubble-me-text); border-top-right-radius: 3px; border-bottom-right-radius: 10px; }
.msg.bot .bubble { background: var(--bubble-bot); border: 0; border-top-left-radius: 3px; border-bottom-left-radius: 10px; }
.b-foot { display: flex; align-items: center; justify-content: flex-end; gap: 6px; margin-top: 3px; min-height: 16px; }
.b-time { font-size: 11px; color: var(--muted); }
.msg.me .b-time { color: color-mix(in srgb, var(--bubble-me-text) 55%, transparent); }
.b-copy { border: 0; background: transparent; color: var(--muted); font-size: 13px; padding: 0 2px; margin-right: auto; opacity: .7; }
.b-copy:hover { opacity: 1; color: var(--accent); }
.day-sep { display: flex; justify-content: center; margin: 10px 0 6px; }
.day-sep span { background: var(--surface); color: var(--muted); font-size: 12px; padding: 4px 12px; border-radius: 8px; box-shadow: var(--shadow); }
.deliver { background: color-mix(in srgb, var(--accent) 6%, var(--surface-2)); border: 0; border-left: 4px solid var(--accent); border-radius: 8px; }
.deliver .dhead { border-bottom: 0; color: var(--accent-strong); padding-bottom: 0; }
.copy-btn { border-radius: 999px; }
.empty.card { margin: auto; padding: 26px 24px; max-width: 460px; background: var(--surface); }
.composer-wrap { background: var(--panel); border-top: 0; padding: 8px 12px 12px; }
.chips { padding-bottom: 8px; }
.chip { background: var(--surface); border-color: var(--border); }
.chip:hover { border-color: var(--accent); color: var(--accent-strong); }
.composer { align-items: center; }
.composer textarea { border: 0; border-radius: 22px; background: var(--surface); min-height: 44px; padding: 11px 16px; }
.send-btn { width: 46px; height: 46px; border-radius: 50%; border: 0; background: var(--accent); color: var(--text); font-size: 18px; flex: none; display: grid; place-items: center; }
.send-btn:disabled { opacity: .5; }
.typing { padding: 12px 14px; }

/* ---------- details (right) ---------- */
.details { min-height: 0; overflow-y: auto; background: var(--surface); border-left: 1px solid var(--border); }
.d-head { position: relative; text-align: center; padding: 28px 20px 18px; display: grid; justify-items: center; gap: 2px; border-bottom: 8px solid var(--bg); }
.d-head h3 { font-size: 20px; margin-top: 10px; }
.d-head p { margin: 0; }
.d-close { position: absolute; top: 10px; left: 10px; }
.avatar.xl { width: 96px; height: 96px; border-radius: 50%; font-size: 46px; }
.d-online { font-size: 12.5px; color: var(--muted); margin-top: 4px; }
.d-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 14px 16px; border-bottom: 8px solid var(--bg); }
.d-act { display: grid; justify-items: center; gap: 4px; padding: 10px 4px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); font-size: 12.5px; font-weight: 600; color: var(--accent-strong); }
.d-act span { font-size: 18px; }
.d-act:hover { background: var(--hover); }
.d-sec { padding: 14px 18px; border-bottom: 8px solid var(--bg); display: grid; gap: 8px; }
.d-sec h4 { margin: 0; font-size: 13px; color: var(--muted); font-weight: 700; display: flex; align-items: center; gap: 6px; }
.d-quick { display: grid; }
.d-quick button { display: flex; justify-content: space-between; align-items: center; text-align: left; border: 0; background: transparent; padding: 10px 2px; border-bottom: 1px solid var(--border); font-size: 14.5px; }
.d-quick button:last-child { border-bottom: 0; }
.d-quick button span { color: var(--muted); font-size: 18px; }
.d-quick button:hover { color: var(--accent-strong); }
.d-list { margin: 0; padding-left: 18px; color: var(--text); font-size: 14px; display: grid; gap: 4px; }
.d-draft { display: grid; gap: 6px; padding: 10px; border-radius: 12px; background: var(--surface-2); }
.d-draft textarea { min-height: 70px; font-size: 13.5px; }
.d-draft-btns { display: flex; justify-content: flex-end; gap: 6px; }
.d-draft-btns .btn { padding: 6px 12px; font-size: 13px; }
.d-value { border-bottom: 0; }
.d-value b { font-size: 22px; }

/* ---------- pages inside the shell ---------- */
.center .page, .center .settings { padding-top: 24px; }
.home-empty { height: 100%; display: grid; place-content: center; justify-items: center; gap: 8px; }
.home-empty span { font-size: 40px; }
.m-back { display: none; }
.card { box-shadow: var(--shadow); }
.hero-main, .roi { background: var(--surface); }
.roi .big { color: var(--accent-strong); }
.bot-card .avatar, .pick-row .avatar { border-radius: 50%; }
.industry.sel { border-color: var(--accent); }
.steps span.on { background: var(--accent); }

/* ---------- mobile: works like a messenger app ---------- */
@media (max-width: 1100px) {
  .shell.has-details { grid-template-columns: minmax(280px, 330px) 1fr; }
  .shell.has-details .details { position: fixed; top: 0; right: 0; bottom: 0; width: min(360px, 92vw); z-index: 40; box-shadow: -8px 0 30px rgba(0,0,0,.2); }
}
@media (max-width: 860px) {
  .shell, .shell.has-details { grid-template-columns: 1fr; }
  body[data-view="list"] .center { display: none; }
  body[data-view="page"] .rail { display: none; }
  .m-only { display: grid !important; }
  .m-back { display: block; margin-bottom: 8px; }
  .m-back a { text-decoration: none; font-size: 20px; color: var(--text); }
  .center.is-chat .messages { padding: 12px 10px; }
  .bubble { max-width: 86%; }
  .chat-head { border-left: 0; }
  .shell.has-details .details { width: 100vw; }
}
.rail-nav { flex-wrap: wrap; overflow: visible; }
.b-copy { font-size: 0; width: 18px; height: 16px; background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='9' y='9' width='12' height='12' rx='2'/%3E%3Cpath d='M5 15V5a2 2 0 0 1 2-2h10'/%3E%3C/svg%3E") center / 15px no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='9' y='9' width='12' height='12' rx='2'/%3E%3Cpath d='M5 15V5a2 2 0 0 1 2-2h10'/%3E%3C/svg%3E") center / 15px no-repeat; }
.shell > * { min-width: 0; }
.rail-head > * { flex-shrink: 0; }
.rail-head .brand { flex-shrink: 1; }

/* ---------- premium: client setup ---------- */
.pr-back { text-decoration: none; font-weight: 600; }
.pr-steps { display: grid; gap: 12px; }
.pr-step { display: flex; align-items: center; gap: 16px; padding: 18px 20px; text-decoration: none; color: inherit; }
.pr-step:hover { border-color: var(--accent); }
.pr-num { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; background: var(--surface-2); flex: none; }
.pr-step.done .pr-num { background: var(--accent); color: var(--text); }
.pr-step.doing .pr-num { background: var(--warn-bg); color: var(--warn-text); }
.pr-body { flex: 1; min-width: 0; display: grid; gap: 2px; }
.pr-body p { margin: 0; }
.pr-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.pr-step .go { color: var(--accent-strong); font-weight: 700; white-space: nowrap; }
.pr-pick { padding: 10px 4px; border-bottom: 1px solid var(--border); }
.pr-pick:last-child { border-bottom: 0; }
.pr-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
.pr-kpi { padding: 14px 16px; border-radius: 12px; background: var(--surface-2); display: grid; gap: 2px; }
.pr-kpi span { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.pr-kpi b { font-size: 22px; color: var(--accent-strong); }
.pr-kpi small { font-size: 12px; color: var(--muted); }
.pr-summary { background: var(--surface-2); border-radius: 12px; padding: 12px 14px; }
.kitem { border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; }
.kitem summary { cursor: pointer; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.kitem .kdel { margin-left: auto; padding: 4px 10px; font-size: 12.5px; }
.kitem .code { margin-top: 10px; max-height: 260px; overflow: auto; }
.tr-item { padding: 8px 0; border-bottom: 1px solid var(--border); }
.tr-item:last-child { border-bottom: 0; }
.tr-item input:checked + span { color: var(--muted); text-decoration: line-through; }

/* ---------- printable documents (manual, report) ---------- */
.doc-wrap { max-width: 860px; margin: 0 auto; padding: 24px 20px 60px; display: grid; gap: 16px; }
.doc-tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.doc-tools .input { width: auto; flex: 1 1 180px; }
.doc { background: #fff; color: #111b21; border-radius: 14px; box-shadow: var(--shadow); padding: 44px 48px; line-height: 1.6; }
.doc h2 { font-size: 18px; margin: 28px 0 10px; color: #008069; }
.doc h3 { font-size: 15.5px; margin: 0 0 4px; }
.doc ol, .doc ul { padding-left: 20px; }
.doc li { margin: 4px 0; }
.doc .muted { color: #667781; }
.doc-cover { text-align: center; padding: 30px 0 34px; border-bottom: 3px solid #090B0A; margin-bottom: 10px; }
.doc-cover.small-cover { padding: 10px 0 20px; }
.doc-cover h1 { font-size: 28px; margin: 10px 0 6px; }
.doc-cover p { margin: 0; color: #667781; }
.doc-logo { font-size: 40px; }
.doc-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.doc-table th, .doc-table td { text-align: left; padding: 8px 10px; border-bottom: 1px solid #e3e7ea; vertical-align: top; }
.doc-table th { background: #f0f2f5; font-size: 12.5px; text-transform: uppercase; letter-spacing: .03em; color: #54656f; }
.doc-staff { padding: 12px 0; border-bottom: 1px solid #e3e7ea; break-inside: avoid; }
.doc-staff p { margin: 2px 0; }
.doc .pr-kpi { background: #f0f2f5; }
.doc .pr-kpi b { color: #008069; }
.doc .input { background: #fff; color: #111b21; }
.doc-kpis { margin: 18px 0 6px; }
.print-only { display: none; }
@media print {
  @page { size: A4; margin: 14mm; }
  html, body { background: #fff !important; overflow: visible !important; height: auto !important; }
  .rail, .no-print, .details, #toast { display: none !important; }
  .shell, .shell.has-details { display: block !important; height: auto !important; background: #fff !important; }
  .center { overflow: visible !important; background: #fff !important; }
  .doc-wrap { padding: 0; max-width: none; }
  .doc { box-shadow: none; padding: 0; border-radius: 0; }
  .print-only { display: block; }
  .page-break { break-before: page; }
  .pr-kpi, .doc-table tr { break-inside: avoid; }
}
.settings .pr-step { display: flex; padding: 18px 20px; }
.settings .pr-pick.pick-row { display: flex; }
/* Office-B logo mark */
.logo-mark { background: none !important; padding: 0; overflow: hidden; }
.logo-mark svg, .doc-logo svg { width: 100%; height: 100%; display: block; }
.brand .logo-mark { width: 38px; height: 38px; border-radius: 11px; flex: none; }
.doc-logo { width: 54px; height: 54px; margin: 0 auto; }

/* =====================================================================
   v3 — Office-B premium black (always dark; WhatsApp layout kept)
   ===================================================================== */
:root, :root:not([data-theme="light"]), :root[data-theme="dark"], :root[data-theme="light"] {
  color-scheme: dark;
  --bg: #000000;            /* app background */
  --surface: #0c0c0d;       /* panels, cards */
  --surface-2: #151517;     /* inputs, chips, raised */
  --panel: #0c0c0d;         /* rail & chat headers */
  --border: #1f1f22;
  --text: #f4f4f5;
  --muted: #8b8b93;
  --accent: var(--accent-ink);        /* refined emerald */
  --accent-strong: var(--accent-ink);
  --accent-soft: rgba(var(--accent-rgb), .12);
  --accent-text: #00130b;
  --bubble-me: #0f3d2c;
  --bubble-me-text: #eafff5;
  --bubble-bot: #161618;
  --chat-bg: #050505;
  --chat-dot: rgba(var(--fg-rgb), .028);
  --hover: #121214;
  --active: #1a1a1d;
  --warn-bg: rgba(245, 165, 36, .12);
  --warn-text: #f5b74a;
  --danger: #ff6b6b;
  --success: var(--accent-ink);
  --shadow: 0 0 0 1px rgba(var(--fg-rgb), .04), 0 8px 24px rgba(0,0,0,.5);
}
body { background: var(--bg); color: var(--text); letter-spacing: -0.005em; }

/* buttons: emerald with dark text, subtle glow */
.btn { background: var(--surface-2); border-color: var(--border); color: var(--text); }
.btn:hover { background: #1c1c1f; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); box-shadow: 0 0 0 1px rgba(var(--accent-rgb), .25), 0 6px 18px rgba(var(--accent-rgb), .18); }
.btn.primary:hover { filter: brightness(1.08); }
.send-btn { background: var(--accent); color: var(--accent-text); box-shadow: 0 6px 18px rgba(var(--accent-rgb), .25); }
.logo-mark svg rect { fill: var(--accent); }
.logo-mark svg path:last-child { fill: var(--accent); }

/* surfaces */
.card { background: var(--surface); border-color: var(--border); }
.input, textarea.input, select.input { background: var(--surface-2); border-color: var(--border); color: var(--text); }
.input::placeholder { color: #5f5f66; }
.chip, .nav-item, .seg button, .d-act, .lang-btn { background: var(--surface-2); border-color: var(--border); color: var(--text); }
.nav-item.on, .seg button.on { background: var(--accent-soft); color: var(--accent-strong); border-color: rgba(var(--accent-rgb), .35); }
.badge { background: var(--surface-2); color: var(--muted); }
.badge.ok { background: var(--accent-soft); color: var(--accent-strong); }
.modal { background: var(--surface); }
.modal-bg { background: rgba(0,0,0,.7); backdrop-filter: blur(4px); }
#toast { background: #f4f4f5; color: #000; }

/* rail */
.rail { background: var(--bg); border-right-color: var(--border); }
.rail-head { background: var(--bg); border-bottom: 1px solid var(--border); }
.rail-search input { background-color: var(--surface-2); color: var(--text); }
.contact.on { background: var(--active); box-shadow: inset 3px 0 0 var(--accent); }
.c-main { border-bottom-color: #141416; }
.presence { border-color: #000; }
.c-badge { background: var(--accent); color: var(--accent-text); }
.rail-label { color: #5f5f66; }

/* chat */
.chat-head { background: var(--bg); border-bottom: 1px solid var(--border); border-left: 0; }
.wa-bg { background-color: var(--chat-bg); }
.bubble { box-shadow: none; border: 1px solid transparent; }
.msg.bot .bubble { border-color: #202023; }
.msg.me .bubble { border-color: rgba(var(--accent-rgb), .18); }
.composer-wrap { background: var(--bg); border-top: 1px solid var(--border); }
.composer textarea { background: var(--surface-2); color: var(--text); }
.day-sep span { background: var(--surface-2); color: var(--muted); box-shadow: none; }
.deliver { background: rgba(var(--accent-rgb), .06); border-left-color: var(--accent); }
.deliver .dhead { color: var(--accent-strong); }
.copy-btn { background: var(--surface-2); border-color: var(--border); color: var(--text); }

/* details */
.details { background: var(--bg); border-left-color: var(--border); }
.d-head, .d-actions, .d-sec { border-bottom-color: #0a0a0b; }
.d-head { background: radial-gradient(120% 80% at 50% 0%, rgba(var(--accent-rgb), .10), transparent 60%); }
.d-act { color: var(--accent-strong); }
.d-draft { background: var(--surface-2); }

/* overview & pages */
.center { background: var(--bg); }
.hero-main { background: linear-gradient(145deg, #0f0f11, #0a0a0b); }
.roi { background: radial-gradient(120% 120% at 100% 0%, rgba(var(--accent-rgb), .16), var(--surface) 55%); }
.roi .big, .pr-kpi b { color: var(--accent-strong); }
.pr-kpi { background: var(--surface-2); }
.pr-step.done .pr-num { background: var(--accent); color: var(--accent-text); }
.note { background: var(--surface-2); }
.code { background: var(--surface-2); border-color: var(--border); color: var(--text); }
.wa-card { border-color: rgba(var(--accent-rgb), .3); }
.demo-try { border-color: var(--border); }
.industry, .pick-row { background: var(--surface); }
.industry.sel { box-shadow: 0 0 0 3px var(--accent-soft); }
.topbar { background: rgba(0,0,0,.85); border-bottom-color: var(--border); }
.steps span { background: #1f1f22; }

/* printable docs stay white on screen and paper */
.doc { color: #111b21; }
.doc .input { background: #fff; color: #111b21; border-color: #d4d4d8; }
.wa-text > .badge { justify-self: start; }
@media print {
  :root, :root:not([data-theme="light"]), :root[data-theme="dark"], :root[data-theme="light"] { color-scheme: light; --bg: #fff; }
  html, body, #app, .shell, .center, .doc-wrap, main { background: #fff !important; }
  body { color: #111b21 !important; }
}

/* =====================================================================
   v4 — Office-B premium: Geist + Pretendard + Instrument Serif,
   icon dock, monogram avatars, restrained accent, motion
   ===================================================================== */
:root, :root:not([data-theme="light"]), :root[data-theme="dark"], :root[data-theme="light"] {
  --font: "Geist", "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-display: "Instrument Serif", "Pretendard Variable", Pretendard, Georgia, serif;
  --font-mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --bg: #000; --surface: #0a0a0a; --surface-2: #141414; --panel: #000; --border: #1c1c1c; --border-strong: #2a2a2a;
  --text: #ededed; --muted: #8f8f8f; --faint: #5c5c5c;
  --accent: var(--accent-ink); --accent-strong: var(--accent-ink); --accent-soft: rgba(var(--accent-rgb), .10); --accent-text: #00140b;
  --bubble-me: #11281f; --bubble-me-text: #e9fbf2; --bubble-bot: #121212; --chat-bg: #000;
  --hover: #0f0f0f; --active: #161616; --radius: 14px;
  --shadow: 0 1px 0 rgba(var(--fg-rgb), .03) inset, 0 12px 32px rgba(0,0,0,.55);
  --ease: cubic-bezier(.2, .8, .2, 1);
}
html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
body { font-family: var(--font); font-size: 14.5px; letter-spacing: -0.006em; font-feature-settings: "ss01", "cv11"; }
h1, h2, h3 { letter-spacing: -0.02em; font-weight: 600; }
button, input, textarea, select { font-family: var(--font); }
a, button, .card, .contact, .dock-item, .chip, .input { transition: background-color .18s var(--ease), border-color .18s var(--ease), color .18s var(--ease), opacity .18s var(--ease), transform .18s var(--ease), box-shadow .18s var(--ease); }
::selection { background: rgba(var(--accent-rgb), .28); }
* { scrollbar-width: thin; scrollbar-color: #262626 transparent; }
*::-webkit-scrollbar { width: 8px; height: 8px; } *::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 8px; } *::-webkit-scrollbar-track { background: transparent; }
.ki { flex: none; display: inline-block; vertical-align: -0.2em; }
.c-time, .b-time, .pr-kpi b, .roi .big, .d-value b, .c-badge, .dock-badge, .doc-table td, .big-num, .pick-total { font-variant-numeric: tabular-nums; }

/* display serif — used sparingly for big moments */
.onb h1, .hero-main h1, .center main > h1, .doc-cover h1 { font-family: var(--font-display); font-weight: 400; letter-spacing: -0.01em; line-height: 1.08; }
.onb h1 { font-size: 46px; }
.hero-main h1 { font-size: 40px; margin: 14px 0 10px; }
.center main > h1 { font-size: 38px !important; margin: 2px 0 0; }
.doc-cover h1 { font-size: 36px; }
.roi .big { font-family: var(--font-display); font-weight: 400; font-size: 54px; letter-spacing: -0.02em; color: var(--text); line-height: 1; }

/* buttons: white primary (quiet luxury), emerald only for send/approve moments */
.btn { border-radius: 10px; padding: 9px 15px; font-weight: 550; font-size: 14px; background: var(--surface-2); border: 1px solid var(--border-strong); color: var(--text); gap: 7px; }
.btn:hover { background: var(--hover); border-color: var(--border-strong); }
.btn.primary { background: #f4f4f4; border-color: #f4f4f4; color: #0a0a0a; box-shadow: none; }
.btn.primary:hover { background: #fff; filter: none; }
.btn.lg { padding: 13px 22px; border-radius: 12px; font-size: 15px; }
.btn.ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn.ghost:hover { color: var(--text); background: var(--surface-2); }
.btn.danger { color: #ff7b7b; }
[data-send] { background: var(--accent) !important; border-color: var(--accent) !important; color: var(--accent-text) !important; }
.send-btn { width: 44px; height: 44px; background: var(--accent); color: var(--accent-text); box-shadow: none; }
.send-btn:hover { filter: brightness(1.08); }
.icon-btn { color: var(--muted); border-radius: 10px; width: 38px; height: 38px; display: inline-grid; place-items: center; padding: 0; }
.icon-btn:hover { color: var(--text); background: var(--surface-2); }
.card { border: 1px solid var(--border); border-radius: 16px; background: var(--surface); box-shadow: none; }
.badge { border-radius: 6px; font-weight: 550; font-size: 11.5px; letter-spacing: .01em; padding: 3px 8px; background: var(--surface-2); color: var(--muted); border: 1px solid var(--border-strong); }
.badge.ok { background: transparent; color: var(--accent-strong); border-color: rgba(var(--accent-rgb), .28); }
.badge.warn { background: transparent; color: #f2b45a; border-color: rgba(242,180,90,.28); }
.input, textarea.input, select.input { border-radius: 10px; background: var(--surface-2); border: 1px solid var(--border-strong); padding: 10px 12px; }
.input:focus { border-color: var(--border-strong); box-shadow: 0 0 0 3px rgba(var(--fg-rgb), .06); }
.field label { font-weight: 550; font-size: 13px; color: var(--text); }
.note { border: 1px solid var(--border-strong); background: transparent; border-radius: 12px; }
.note.warn { color: #f2b45a; border-color: rgba(242,180,90,.25); background: rgba(242,180,90,.04); }
#toast { border-radius: 10px; font-weight: 550; box-shadow: 0 10px 30px rgba(0,0,0,.5); }
.modal { border-radius: 18px; border: 1px solid var(--border-strong); background: var(--surface); }

/* ---------- shell: dock | list | center | details ---------- */
.shell { grid-template-columns: 72px minmax(300px, 350px) 1fr; }
.shell.has-details { grid-template-columns: 72px minmax(300px, 350px) 1fr 360px; }
.dock { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 0 16px; background: var(--bg); border-right: 1px solid var(--border); min-height: 0; }
.dock-logo { width: 38px; height: 38px; margin-bottom: 14px; display: block; border-radius: 11px; overflow: hidden; }
.dock-logo svg { width: 100%; height: 100%; display: block; }
.dock-logo svg rect { fill: #fff; } .dock-logo svg path:first-of-type { fill: #000; } .dock-logo svg path:last-child { fill: #fff; }
.dock-item { position: relative; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; color: var(--muted); background: transparent; border: 0; text-decoration: none; }
.dock-item:hover { color: var(--text); background: var(--surface-2); }
.dock-item.on { color: var(--text); background: var(--active); }
.dock-item.on::before { content: ""; position: absolute; left: -14px; top: 12px; bottom: 12px; width: 3px; border-radius: 0 3px 3px 0; background: #fff; }
.dock-badge { position: absolute; top: 5px; right: 4px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: var(--accent); color: var(--accent-text); font-size: 10.5px; font-weight: 700; display: grid; place-items: center; border: 2px solid #000; }
.dock-label { display: none; }
.dock-spacer { flex: 1; }
.dock-mini { position: absolute; bottom: 3px; right: 3px; font-size: 8.5px; font-weight: 700; letter-spacing: .04em; color: var(--muted); font-family: var(--font-mono); }
.dock-lang { cursor: pointer; }

/* rail */
.rail { background: var(--bg); border-right: 1px solid var(--border); }
.rail-head { background: var(--bg); border-bottom: 0; padding: 18px 16px 10px; min-height: 0; gap: 10px; align-items: flex-start; }
.brand-t { flex: 1; min-width: 0; display: grid; gap: 3px; }
.brand-t b { font-size: 19px; font-weight: 650; letter-spacing: -0.025em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-t small { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.dotw { width: 6px; height: 6px; box-shadow: 0 0 0 3px rgba(var(--accent-rgb), .14); }
.rail-search { position: relative; padding: 6px 14px 10px; }
.rail-search .rs-ic { position: absolute; left: 26px; top: 50%; transform: translateY(-58%); color: var(--muted); pointer-events: none; }
.rail-search input { background-image: none !important; background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 9px 12px 9px 36px; font-size: 13.5px; }
.rail-search input:focus { border-color: var(--border-strong); }
.rail-label { padding: 12px 18px 6px; font-size: 11px; letter-spacing: .08em; color: var(--muted); font-weight: 600; }
.contact { padding: 9px 12px; margin: 1px 8px; border-radius: 12px; gap: 12px; }
.contact:hover { background: var(--hover); }
.contact.on { background: var(--active); box-shadow: none; }
.c-main { border-bottom: 0; padding-bottom: 0; margin-bottom: 0; }
.c-top b { font-size: 15px; font-weight: 600; letter-spacing: -0.01em; }
.c-prev { font-size: 13px; color: var(--muted); display: flex; align-items: center; gap: 5px; }
.c-chan { color: var(--accent); display: inline-flex; }
.c-time { font-size: 11.5px; color: var(--muted); }
.c-badge { background: var(--accent); color: var(--accent-text); font-weight: 700; }

/* monogram avatars */
.avatar { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; flex: none; position: relative;
  background: radial-gradient(120% 120% at 30% 20%, color-mix(in srgb, var(--c, #888) 55%, #fff 0%) 0%, color-mix(in srgb, var(--c, #888) 70%, #000) 100%);
  border: 1px solid rgba(var(--fg-rgb), .08); color: #fff; font-weight: 600; font-size: 16px; letter-spacing: -0.02em; box-shadow: inset 0 1px 0 rgba(var(--fg-rgb), .18); }
.avatar.sm { width: 32px; height: 32px; font-size: 12.5px; }
.avatar.lg { width: 64px; height: 64px; font-size: 24px; }
.avatar.xl { width: 104px; height: 104px; font-size: 38px; font-weight: 500; box-shadow: inset 0 1px 0 rgba(var(--fg-rgb), .2), 0 20px 50px color-mix(in srgb, var(--c, #888) 22%, transparent); }
.contact .avatar { width: 46px; height: 46px; font-size: 16px; }
.presence { width: 10px; height: 10px; background: var(--accent); border: 2px solid #000; right: 0; bottom: 0; }
.chat-who .avatar { width: 40px; height: 40px; font-size: 15px; }
.avatar.wa-biz { background: none; border: 0; box-shadow: none; overflow: hidden; border-radius: 9px; }
.avatar.wa-biz svg { width: 100%; height: 100%; }
.mono-chip { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; font-size: 10px; font-weight: 700; color: #fff; vertical-align: -5px; margin-right: 4px;
  background: color-mix(in srgb, var(--c, #888) 75%, #000); }

/* chat */
.chat-head { background: color-mix(in srgb, var(--bg) 86%, transparent); backdrop-filter: saturate(140%) blur(16px); border-bottom: 1px solid var(--border); padding: 10px 16px; min-height: 64px; }
.chat-who b { font-size: 15.5px; font-weight: 600; letter-spacing: -0.015em; }
.chat-who span { font-size: 12.5px; color: var(--muted); }
.chat-head .icon-btn.on { background: var(--active); color: var(--text); }
.wa-bg { background-color: var(--bg); background-image: radial-gradient(rgba(var(--fg-rgb), .035) 1px, transparent 1px); background-size: 26px 26px; }
.center.is-chat .messages { padding: 26px 8% 18px; }
.bubble { border-radius: 16px; padding: 9px 13px 7px; font-size: 14.5px; line-height: 1.55; max-width: min(620px, 74%); }
.msg.me .bubble { background: var(--bubble-me); border: 1px solid rgba(var(--accent-rgb), .14); border-top-right-radius: 6px; }
.msg.bot .bubble { background: var(--bubble-bot); border: 1px solid var(--border); border-top-left-radius: 6px; }
.msg.me + .msg.bot, .msg.bot + .msg.me { margin-top: 14px; }
.b-foot { gap: 8px; }
.b-time { font-size: 10.5px; color: var(--muted); letter-spacing: .02em; }
.msg.me .b-time { color: rgba(233,251,242,.45); }
.b-copy { width: auto; height: auto; background: none; -webkit-mask: none; mask: none; font-size: inherit; color: var(--muted); display: inline-flex; padding: 2px; border-radius: 6px; }
.b-copy:hover { color: var(--text); background: var(--hover); }
.chan-tag { background: transparent; border: 1px solid var(--border-strong); color: var(--muted); border-radius: 6px; font-size: 10.5px; padding: 0 6px; }
.chan-tag.wa { color: var(--accent-strong); border-color: rgba(var(--accent-rgb), .25); background: transparent; }
.demo-tag { background: transparent; border: 1px solid rgba(242,180,90,.3); color: #f2b45a; }
.day-sep span { background: var(--surface-2); border: 1px solid var(--border); color: var(--muted); font-size: 11.5px; letter-spacing: .02em; border-radius: 999px; padding: 3px 12px; }
.deliver { background: var(--surface); border: 1px solid var(--border); border-left: 2px solid var(--accent); border-radius: 12px; }
.deliver .dhead { color: var(--text); font-weight: 600; letter-spacing: .02em; text-transform: uppercase; font-size: 10.5px; padding: 8px 8px 4px 12px; }
.copy-btn { background: var(--surface-2); border: 1px solid var(--border-strong); color: var(--text); border-radius: 8px; padding: 3px 10px; font-weight: 550; }
.copy-btn:hover { background: var(--active); }
.composer-wrap { background: var(--bg); border-top: 1px solid var(--border); padding: 10px 16px 16px; }
.chips { gap: 6px; }
.chip { background: transparent; border: 1px solid var(--border-strong); color: var(--text); font-weight: 500; font-size: 13px; padding: 6px 12px; }
.chip:hover { border-color: var(--border-strong); color: var(--text); background: var(--surface-2); }
.composer textarea { background: var(--surface-2); border: 1px solid var(--border); border-radius: 22px; padding: 11px 18px; }
.composer textarea:focus { border-color: var(--border-strong); box-shadow: none; }
.empty.card { background: var(--surface); border: 1px solid var(--border); padding: 32px 28px; }
.empty h3 { font-family: var(--font-display); font-weight: 400; font-size: 30px; letter-spacing: -0.01em; }
.big-actions button { background: var(--hover); border: 1px solid var(--border); color: var(--text); font-weight: 500; border-radius: 12px; }
.big-actions button:hover { border-color: var(--border-strong); color: var(--text); }

/* new message motion */
@keyframes rise { from { opacity: 0; transform: translateY(8px) scale(.985); } to { opacity: 1; transform: none; } }
.msg.fresh .bubble { animation: rise .32s var(--ease) both; }
.typing i { background: #8a8a8a; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.center > *, .details > * { animation: fadeIn .22s var(--ease) both; }

/* details */
.details { background: var(--bg); border-left: 1px solid var(--border); }
.d-head { background: radial-gradient(90% 70% at 50% 0%, color-mix(in srgb, var(--c, var(--accent-ink)) 14%, transparent), transparent 70%); padding: 36px 20px 22px; border-bottom: 1px solid var(--border); }
.d-head h3 { font-size: 22px; font-weight: 600; margin-top: 14px; }
.d-online { color: var(--muted); }
.d-actions { border-bottom: 1px solid var(--border); padding: 16px; gap: 8px; }
.d-act { background: var(--surface-2); border: 1px solid var(--border); color: var(--text); font-weight: 500; border-radius: 12px; padding: 12px 4px; }
.d-act span { color: var(--text); display: grid; place-items: center; }
.d-act:hover { background: var(--active); border-color: var(--border-strong); }
.d-sec { border-bottom: 1px solid var(--border); padding: 18px 20px; }
.d-sec h4 { font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.d-quick button { color: var(--text); border-bottom: 1px solid var(--border); font-size: 14px; }
.d-quick button:hover { color: var(--text); }
.d-list { color: var(--text); }
.d-draft { background: var(--surface); border: 1px solid var(--border); }
.d-value b { font-family: var(--font-display); font-weight: 400; font-size: 32px; color: var(--text); }

/* pages */
.center .page, .center .settings { padding-top: 34px; }
.settings { gap: 16px; }
.settings .card { padding: 24px; }
.settings h2 { font-size: 15px; font-weight: 600; letter-spacing: -0.01em; }
.hero { gap: 14px; }
.hero-main { background: linear-gradient(160deg, var(--surface-2), #070707); padding: 32px; }
.roi { background: radial-gradient(130% 120% at 100% 0%, rgba(var(--accent-rgb), .12), var(--surface) 60%); padding: 28px; }
.roi .sub { color: var(--muted); }
.section-head h2 { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.bot-card { padding: 20px; border-radius: 16px; }
.bot-card:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.bot-card .go { color: var(--text); }
.bot-card .desc { color: var(--muted); }
.online { background: var(--accent); box-shadow: 0 0 0 3px rgba(var(--accent-rgb), .14); }
.wa-card { border-color: var(--border); background: linear-gradient(90deg, rgba(var(--accent-rgb), .07), transparent 40%), var(--surface); }
.wa-logo { color: var(--accent); display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: rgba(var(--accent-rgb), .08); border: 1px solid rgba(var(--accent-rgb), .2); }
.wa-card .go, .pr-step .go { color: var(--text); }
.demo-link { margin: -14px 0 30px; }
.tips { background: #070707; }
.pr-step { border-radius: 16px; }
.pr-step:hover { border-color: var(--border-strong); }
.pr-num { background: var(--surface-2); border: 1px solid var(--border-strong); font-family: var(--font-mono); font-weight: 500; font-size: 14px; }
.pr-step.done .pr-num { background: #fff; color: #000; border-color: #fff; }
.pr-title { display: inline-flex; align-items: center; gap: 8px; font-size: 15.5px; }
.pr-kpi { background: var(--surface-2); border: 1px solid var(--border); border-radius: 14px; padding: 16px 18px; }
.pr-kpi b { font-family: var(--font-display); font-weight: 400; font-size: 34px; color: var(--text); line-height: 1.1; }
.pr-kpi span { color: var(--muted); font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; }
.log-row .arrow { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--border); color: var(--muted); flex: none; }
.log-row .arrow.in { color: var(--accent); }
.home-empty .logo-mark.big { width: 64px; height: 64px; border-radius: 18px; display: block; overflow: hidden; }
.home-empty .logo-mark.big svg rect { fill: #fff; } .home-empty .logo-mark.big svg path:first-of-type { fill: #000; } .home-empty .logo-mark.big svg path:last-child { fill: #fff; }

/* onboarding */
.onb { max-width: 820px; padding-top: 64px; }
.onb .lead { font-size: 17px; color: var(--muted); }
.industry { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 20px; gap: 8px; }
.industry:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.industry.sel { border-color: #fff; box-shadow: 0 0 0 1px #fff; }
.industry .emo { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--border-strong); color: var(--text); font-size: 0; }
.industry b { font-size: 15.5px; }
.industry span:last-child { color: var(--muted); }
.steps span { height: 3px; background: #1f1f1f; }
.steps span.on { background: #fff; }
.demo-try { background: transparent; border: 1px dashed var(--border-strong); border-radius: 16px; }
.demo-try:hover { border-color: #fff; }
.pick-row { border-radius: 14px; }
.pick-total { background: var(--surface-2); border: 1px solid var(--border); }
.topbar { background: rgba(0,0,0,.7); backdrop-filter: blur(16px); border-bottom: 1px solid var(--border); }
.topbar .logo-mark { width: 30px; height: 30px; border-radius: 9px; }
.topbar .logo-mark svg rect { fill: #fff; } .topbar .logo-mark svg path:first-of-type { fill: #000; } .topbar .logo-mark svg path:last-child { fill: #fff; }
.logo { font-weight: 650; letter-spacing: -0.02em; }

/* docs (print) */
.doc { font-family: var(--font); }
.doc-cover h1 { font-family: var(--font-display); }
.doc h2 { color: #0a0a0a; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.doc-logo { width: 46px; height: 46px; border-radius: 13px; overflow: hidden; }
.doc-logo svg rect { fill: #0a0a0a; } .doc-logo svg path:first-of-type { fill: #fff; } .doc-logo svg path:last-child { fill: #0a0a0a; }
.doc-cover { border-bottom: 1px solid #0a0a0a; }
.doc .pr-kpi { background: #f6f6f6; border-color: #ececec; }
.doc .pr-kpi b { color: #0a0a0a; }
.doc .pr-kpi span { color: #6b6b6b; }

/* ---------- mobile: bottom tab bar like a messenger app ---------- */
@media (max-width: 1100px) {
  .shell.has-details { grid-template-columns: 72px minmax(280px, 320px) 1fr; }
}
@media (max-width: 860px) {
  .shell, .shell.has-details { grid-template-columns: 1fr; }
  .dock { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; flex-direction: row; justify-content: space-around; gap: 0; padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
    border-right: 0; border-top: 1px solid var(--border); background: rgba(0,0,0,.92); backdrop-filter: blur(16px); }
  .dock-logo, .dock-spacer, .dock-lang { display: none; }
  .dock-item { width: auto; flex: 1; height: 52px; display: flex; flex-direction: column; justify-content: center; gap: 3px; border-radius: 10px; }
  .dock-item.on { background: transparent; color: var(--text); }
  .dock-item.on::before { display: none; }
  .dock-label { display: block; font-size: 10.5px; font-weight: 550; letter-spacing: .01em; }
  .dock-badge { top: 2px; right: calc(50% - 22px); }
  body[data-chat="1"] .dock { display: none; }
  .rail { padding-bottom: 72px; }
  .center:not(.is-chat) { padding-bottom: 80px; }
  .onb h1 { font-size: 36px; }
  .hero-main h1 { font-size: 32px; }
  .center main > h1 { font-size: 32px !important; }
  .roi .big { font-size: 44px; }
  .center.is-chat .messages { padding: 14px 10px; }
  .bubble { max-width: 86%; }
}
.demo-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 4px; }
.demo-head h1 { font-family: var(--font-display); font-weight: 400; font-size: 38px; letter-spacing: -0.01em; }
.demo-try b { display: inline-flex; align-items: center; gap: 8px; }
.phone { border-color: var(--border); box-shadow: 0 0 0 1px var(--border-strong), 0 40px 80px rgba(0,0,0,.6); }
@media (max-width: 860px) {
  .dock .dock-item.dock-lang, .dock .dock-item.dock-opt { display: none; }
  .dock-label { white-space: nowrap; }
}
@media (max-width: 860px) { .pr-step .go { display: none; } .pr-step { gap: 12px; padding: 16px; } }
@media print { .dock, .chat-head, .composer-wrap { display: none !important; } .center:not(.is-chat) { padding-bottom: 0 !important; } }

/* ---------- calendar & booking ---------- */
.cal { max-width: 1040px; }
.cal-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.cal-head h1 { font-family: var(--font-display); font-weight: 400; font-size: 40px; letter-spacing: -0.01em; }
.cal-head p { margin: 2px 0 0; }
.cal-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.cal-kpis { margin-bottom: 18px; }
.cal-day { border: 1px solid var(--border); border-radius: 16px; background: #070707; padding: 6px 6px 8px; margin-bottom: 10px; }
.cal-day.is-today { border-color: var(--text); background: linear-gradient(180deg, rgba(var(--accent-rgb), .12), transparent 60px), var(--surface); }
.cal-dayhead { display: flex; align-items: center; gap: 10px; padding: 10px 12px 8px; }
.cal-dayhead b { font-size: 14.5px; letter-spacing: -0.01em; }
.cal-dayhead .muted { margin-left: auto; }
.ap-row { display: grid; grid-template-columns: 64px 32px 1fr auto auto; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; }
.ap-row:hover { background: var(--hover); }
.ap-row + .ap-row { border-top: 1px solid #121212; }
.ap-row.done, .ap-row.noshow { opacity: .55; }
.ap-time { display: grid; font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.ap-time b { font-size: 14px; font-weight: 500; color: var(--text); }
.ap-time span { font-size: 11.5px; color: var(--muted); }
.ap-main { min-width: 0; display: grid; gap: 2px; }
.ap-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ap-top b { font-size: 14.5px; font-weight: 600; }
.ap-sub { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ap-note { font-size: 12px; color: #c9a45a; }
.ap-empty { padding: 6px 12px 10px; }
.ap-rems { display: flex; gap: 6px; }
.rem { display: inline-flex; align-items: center; gap: 3px; font-size: 10.5px; font-family: var(--font-mono); color: var(--muted); border: 1px solid var(--border); border-radius: 6px; padding: 1px 6px; }
.rem.ok { color: var(--accent-strong); border-color: rgba(var(--accent-rgb), .3); }
.rem.bad { color: #ff8a8a; border-color: rgba(255,120,120,.35); }
.ap-acts { display: flex; gap: 6px; justify-content: flex-end; }
.sm-btn { padding: 6px 10px; font-size: 12.5px; border-radius: 8px; }
.st { font-size: 11px; font-weight: 600; letter-spacing: .02em; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--border-strong); color: var(--text); }
.st-confirmed { color: var(--accent-strong); border-color: rgba(var(--accent-rgb), .3); }
.st-held { color: #f2b45a; border-color: rgba(242,180,90,.35); }
.st-cancelled, .st-noshow { color: #ff8a8a; border-color: rgba(255,120,120,.3); }
.st-done { color: var(--muted); }
.ai-tag { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; color: #b8b8ff; border: 1px solid rgba(160,160,255,.3); border-radius: 999px; padding: 1px 7px; }
.slots { padding: 2px 12px 6px; }
.slots summary { cursor: pointer; list-style: none; }
.slots summary::-webkit-details-marker { display: none; }
.slot-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px 0 4px; }
.slot { border: 1px solid var(--border-strong); background: transparent; color: #d6d6d6; border-radius: 8px; padding: 5px 10px; font-family: var(--font-mono); font-size: 12.5px; }
.slot:hover { border-color: var(--accent); color: var(--text); }
.bk-chip { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 10px; font-size: 12.5px; color: var(--accent-strong); border: 1px solid rgba(var(--accent-rgb), .28); background: rgba(var(--accent-rgb), .06); }
.bk-chip b { color: var(--text); font-weight: 600; }
.bk-chip.warn { color: #f2b45a; border-color: rgba(242,180,90,.3); background: rgba(242,180,90,.05); }
.bk-chip.bad { color: #ff8a8a; border-color: rgba(255,120,120,.3); background: rgba(255,120,120,.05); }
.hours { display: grid; gap: 6px; }
.hour-row { display: grid; grid-template-columns: 110px 1fr auto 1fr; gap: 10px; align-items: center; }
.hour-row .input:disabled { opacity: .35; }
.svc-row { display: grid; grid-template-columns: 1fr 110px 40px; gap: 8px; margin-bottom: 8px; }
.settings > h1 { font-family: var(--font-display); font-weight: 400; font-size: 38px; }
@media (max-width: 860px) {
  .ap-row { grid-template-columns: 54px 1fr; }
  .ap-row .avatar { display: none; }
  .ap-rems, .ap-acts { grid-column: 2; justify-content: flex-start; }
  .cal-head h1 { font-size: 32px; }
  .hour-row { grid-template-columns: 80px 1fr auto 1fr; }
}
a.btn { text-decoration: none; }
@media (max-width: 860px) {
  .cal-kpis { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .cal-kpis .pr-kpi { padding: 12px 14px; }
  .cal-kpis .pr-kpi b { font-size: 28px; }
  .cal-tools .btn.primary { order: -1; }
}

/* =====================================================================
   v5 — Office-B: logo mark (bold B + working dot), multilingual fonts
   ===================================================================== */
:root, :root:not([data-theme="light"]), :root[data-theme="dark"], :root[data-theme="light"] {
  --font: "Geist", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-display: "Instrument Serif", "Noto Sans SC", Georgia, serif;
}
html[lang="zh"] .onb h1, html[lang="zh"] .hero-main h1, html[lang="zh"] .center main > h1, html[lang="zh"] .cal-head h1,
html[lang="zh"] .settings > h1, html[lang="zh"] .demo-head h1, html[lang="zh"] .empty h3 { font-family: "Noto Sans SC", var(--font); font-weight: 600; letter-spacing: 0; }
html[lang="zh"] .roi .big, html[lang="zh"] .pr-kpi b, html[lang="zh"] .d-value b { font-family: var(--font); font-weight: 600; }
/* logo: same artwork everywhere, colors per context */
svg .lg-fg { fill: none !important; }
.logo-mark svg .lg-bg, .dock-logo svg .lg-bg, .topbar .logo-mark svg .lg-bg, .home-empty .logo-mark.big svg .lg-bg { fill: #C5FF32 !important; }
.logo-mark svg .lg-fg, .dock-logo svg .lg-fg, .topbar .logo-mark svg .lg-fg, .home-empty .logo-mark.big svg .lg-fg { stroke: #090B0A !important; }
svg .lg-dot { fill: var(--accent) !important; }
.doc-logo svg .lg-bg { fill: #C5FF32 !important; }
.doc-logo svg .lg-fg { stroke: #090B0A !important; }
.wa-biz svg .lg-bg { fill: #C5FF32 !important; }
.lang-list { display: grid; gap: 8px; }
.lang-opt { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--border-strong); background: var(--surface-2); color: var(--text); text-align: left; }
.lang-opt b { flex: 1; font-size: 15px; font-weight: 600; }
.lang-opt span { font-family: var(--font-mono); font-size: 12px; color: var(--muted); }
.lang-opt:hover { border-color: var(--text); }
.lang-opt.on { border-color: #fff; }
.lang-btn { display: inline-flex; align-items: center; gap: 6px; }

/* ---------- v6: plans, trained badge, Lena team results ---------- */
.plan-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 6px 0 12px; }
.plan-opt { display: flex; flex-direction: column; gap: 6px; text-align: left; padding: 18px; cursor: pointer; border: 1px solid var(--line, var(--border-strong)); background: var(--card, var(--surface-2)); color: inherit; font: inherit; border-radius: 16px; transition: border-color .15s, transform .15s; }
.plan-opt:hover { transform: translateY(-1px); }
.plan-opt.sel { border-color: var(--accent-ink); box-shadow: 0 0 0 1px var(--accent-ink) inset; }
.plan-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.plan-price { font-family: "Instrument Serif", serif; font-size: 34px; line-height: 1.1; letter-spacing: -.01em; }
.plan-price small, .compare b small { font-family: Geist, sans-serif; font-size: 13px; opacity: .6; margin-left: 3px; }
.compare { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 14px; padding: 16px 18px; margin-bottom: 14px; }
.compare > div { display: flex; flex-direction: column; gap: 3px; }
.compare b { font-size: 24px; font-weight: 600; }
.compare .c-bad { color: #f87171; text-decoration: line-through; text-decoration-thickness: 1px; text-decoration-color: rgba(248,113,113,.5); }
.compare .c-good { color: var(--accent-ink); }
.compare .c-vs { font-family: "Geist Mono", monospace; font-size: 12px; opacity: .5; }
.pick-hint { margin: -4px 0 10px; }
.pick-row.off { opacity: .55; }
.pick-row input:disabled { opacity: .7; }
.trained { display: flex; width: fit-content; align-items: center; gap: 4px; margin-top: 4px; font-size: 11px; color: var(--accent-ink); letter-spacing: .02em; }
.team-out { margin-top: 12px; border-top: 1px solid rgba(var(--fg-rgb), .08); padding-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.team-head { font-size: 12px; opacity: .7; display: flex; align-items: center; gap: 6px; margin-bottom: 2px; }
.team-item { border: 1px solid rgba(var(--fg-rgb), .08); border-radius: 12px; background: rgba(var(--fg-rgb), .02); }
.team-item summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 9px 11px; cursor: pointer; }
.team-item summary::-webkit-details-marker { display: none; }
.team-item .ti-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.team-item .ti-text .small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.team-item .ti-chev { opacity: .5; transition: transform .15s; flex: none; }
.team-item[open] .ti-chev { transform: rotate(90deg); }
.team-item .ti-body { padding: 4px 12px 12px; border-top: 1px solid rgba(var(--fg-rgb), .06); }
.avatar.xs { width: 26px; height: 26px; font-size: 10px; flex: none; }
.typing-note { display: block; font-size: 12px; opacity: .6; margin: 4px 0 0 6px; }
@media (max-width: 600px) { .plan-grid { grid-template-columns: 1fr; } .compare { grid-template-columns: 1fr; text-align: left; } .compare .c-vs { display: none; } }
@media print { .team-item { break-inside: avoid; } .team-item .ti-body { display: block; } }

/* v7: tagline */
.logo-tag { font-weight: 400; opacity: .55; margin-left: 8px; font-size: 13px; letter-spacing: 0; }
@media (max-width: 600px) { .logo-tag { display: none; } }
.doc-brand { margin: 6px 0 0; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; opacity: .6; }

/* ---------- v8: live voice ---------- */
.voice-btn { flex: none; width: 44px; height: 44px; border-radius: 50%; border: 1px solid rgba(var(--fg-rgb), .14); background: rgba(var(--fg-rgb), .04); color: inherit; display: grid; place-items: center; cursor: pointer; transition: background .15s, border-color .15s; }
.voice-btn:hover { background: rgba(var(--accent-rgb), .12); border-color: var(--accent-ink); color: var(--accent-ink); }
.voice-bg { position: fixed; inset: 0; z-index: 200; background: radial-gradient(ellipse at 50% 30%, rgba(30,30,30,.92), rgba(0,0,0,.97)); display: grid; place-items: center; backdrop-filter: blur(10px); animation: vfade .2s ease; }
@keyframes vfade { from { opacity: 0 } }
.voice-card { width: min(440px, 100%); padding: 32px 20px 24px; display: flex; flex-direction: column; align-items: center; gap: 8px; height: min(720px, 100vh); }
.voice-orb { position: relative; width: 140px; height: 140px; display: grid; place-items: center; margin: 24px 0 14px; }
.voice-orb .avatar.xl { width: 104px; height: 104px; font-size: 34px; position: relative; z-index: 2; box-shadow: 0 0 0 1px rgba(var(--fg-rgb), .08); }
.voice-orb .ring { position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--c); opacity: .0; }
.voice-bg[data-state="listen"] .ring { animation: vring 2.4s ease-out infinite; }
.voice-bg[data-state="speak"] .ring { animation: vring 1s ease-out infinite; opacity: .6; }
.voice-bg[data-state="speak"] .ring.r2 { animation-delay: .5s; }
.voice-bg[data-state="think"] .ring { animation: vspin 1.2s linear infinite; border-style: dashed; opacity: .7; }
@keyframes vring { 0% { transform: scale(.75); opacity: .7 } 100% { transform: scale(1.35); opacity: 0 } }
@keyframes vspin { to { transform: rotate(360deg) } }
.voice-name { font-family: "Instrument Serif", serif; font-size: 34px; line-height: 1; }
.voice-state { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-ink); }
.voice-hint { margin-bottom: 6px; text-align: center; }
.voice-log { flex: 1; width: 100%; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; padding: 8px 4px; mask-image: linear-gradient(to bottom, transparent, #000 24px); }
.v-line { font-size: 14px; line-height: 1.45; max-width: 88%; padding: 8px 12px; border-radius: 14px; }
.v-line.me { align-self: flex-end; background: rgba(var(--accent-rgb), .14); }
.v-line.ai { align-self: flex-start; background: rgba(var(--fg-rgb), .06); }
.v-line.tool { align-self: center; font-size: 12px; color: var(--accent-ink); border: 1px solid rgba(var(--accent-rgb), .35); border-radius: 999px; padding: 4px 12px; }
.v-line.err, .v-line.sys { color: #f87171; border-color: rgba(248,113,113,.4); align-self: center; font-size: 12px; }
.voice-actions { display: flex; gap: 28px; padding-top: 14px; }
.v-btn { display: flex; flex-direction: column; align-items: center; gap: 6px; background: none; border: 0; color: inherit; font: inherit; font-size: 12px; cursor: pointer; }
.v-btn > svg { box-sizing: content-box; padding: 18px; border-radius: 50%; background: rgba(var(--fg-rgb), .08); }
.v-btn.on > svg { background: #fff; color: #000; }
.v-btn.end > svg { background: #ef4444; color: #fff; }

/* ---------- v9: files ---------- */
.attach-btn { width: 40px; height: 40px; align-self: center; }
.filed-card { display: flex; align-items: center; gap: 10px; margin-top: 10px; padding: 10px 12px; border-radius: 12px; border: 1px solid rgba(var(--accent-rgb), .35); background: rgba(var(--accent-rgb), .06); color: inherit; text-decoration: none; }
.filed-card > span { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.filed-card b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.filed-card svg { flex: none; color: var(--accent-ink); }
.files-where { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 14px 16px; }
.files-where code { font-size: 12px; opacity: .8; word-break: break-all; }
.files-where p { flex-basis: 100%; }
.files-group h2 { display: flex; align-items: center; gap: 8px; font-size: 15px; margin: 0 0 8px; }
.file-row { display: flex; align-items: center; gap: 12px; padding: 10px 6px; border-top: 1px solid rgba(var(--fg-rgb), .06); color: inherit; text-decoration: none; }
.file-row:hover { background: rgba(var(--fg-rgb), .03); }
.file-ext { flex: none; width: 42px; height: 42px; border-radius: 10px; display: grid; place-items: center; font: 600 10px "Geist Mono", monospace; background: rgba(var(--fg-rgb), .06); }
.file-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.file-main b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-sum { opacity: .75; }

/* Korean */
html:lang(ko) { --font: "Geist", "Noto Sans KR", "Apple SD Gothic Neo", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; --font-display: "Instrument Serif", "Noto Sans KR", Georgia, serif; }

/* ---------- v10: login & roles ---------- */
body[data-role="staff"] .owner-only { display: none !important; }
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; background: radial-gradient(ellipse at 50% 0%, rgba(var(--accent-rgb), .08), transparent 60%), var(--bg, var(--bg)); }
.login-card { width: min(400px, 100%); display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; }
.login-logo svg { width: 56px; height: 56px; }
.login-card h1 { font-family: var(--font-display); font-weight: 400; font-size: 36px; margin: 14px 0 0; }
.login-card > p { margin: 0 0 14px; }
.login-form { width: 100%; display: flex; flex-direction: column; gap: 12px; text-align: left; }
.login-form label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; opacity: .9; }
.login-form .btn { margin-top: 6px; width: 100%; justify-content: center; }
.login-help { text-align: center; margin: 4px 0 0; }
.login-lang { margin-top: 18px; }
.users-list { display: flex; flex-direction: column; }
.user-actions { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.btn.sm { padding: 4px 10px; font-size: 12px; }

/* ---------- v12: rich documents + PDF ---------- */
.bubble h2 { font-size: 17px; margin: 14px 0 6px; } .bubble h3 { font-size: 15px; margin: 12px 0 4px; } .bubble h4 { font-size: 14px; margin: 10px 0 4px; }
.bubble a { color: var(--accent-ink); word-break: break-word; }
.md-table { overflow-x: auto; margin: 8px 0; }
.md-table table { border-collapse: collapse; font-size: 13px; min-width: 100%; }
.md-table th, .md-table td { border: 1px solid rgba(var(--fg-rgb), .12); padding: 6px 8px; text-align: left; vertical-align: top; }
.md-table th { background: rgba(var(--fg-rgb), .05); font-weight: 600; }
.b-pdf { display: inline-flex; align-items: center; gap: 3px; font-size: 11px; font-weight: 600; }
.ti-actions { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 8px; }
#printDoc { display: none; }
@media print {
  body.print-doc > *:not(#printDoc) { display: none !important; }
  body.print-doc #printDoc { display: block !important; }
  body.print-doc { background: #fff !important; }
  .pdoc { color: #111; font-size: 11.5pt; line-height: 1.55; max-width: none; padding: 0; background: #fff; }
  .pdoc-head { display: flex; align-items: center; gap: 12px; border-bottom: 2px solid #090B0A; padding-bottom: 10px; margin-bottom: 18px; }
  .pdoc-head .doc-logo svg { width: 34px; height: 34px; }
  .pdoc-head div:last-child { display: flex; flex-direction: column; } .pdoc-head span { color: #666; font-size: 9.5pt; }
  .pdoc h2 { font-size: 16pt; margin: 18px 0 8px; color: #111; } .pdoc h3 { font-size: 13pt; margin: 14px 0 6px; } .pdoc h4 { font-size: 11.5pt; margin: 10px 0 4px; }
  .pdoc p, .pdoc li { color: #222; } .pdoc a { color: #00795f; }
  .pdoc .md-table th, .pdoc .md-table td { border: 1px solid #ccc; color: #111; } .pdoc .md-table th { background: #f1f5f4; }
  .pdoc table, .pdoc tr { break-inside: avoid; } .pdoc h2, .pdoc h3 { break-after: avoid; }
  .pdoc-foot { margin-top: 28px; border-top: 1px solid #ddd; padding-top: 8px; font-size: 8.5pt; color: #888; }
  @page { margin: 16mm 14mm; }
}
.cite { font-size: .72em; margin-left: 1px; } .cite a { text-decoration: none; }
@media print { .pdoc-title { font-family: "Instrument Serif", Georgia, serif; font-weight: 400; font-size: 24pt; line-height: 1.15; margin: 4px 0 14px; color: #111; } .pdoc h2 { border-bottom: 1px solid #e5e5e5; padding-bottom: 4px; } .pdoc .cite { font-size: 7pt; } }
@media print { html:lang(ko) .pdoc-title, html:lang(zh) .pdoc-title { font-family: "Geist", "Noto Sans KR", "Noto Sans SC", sans-serif; font-weight: 700; font-size: 19pt; letter-spacing: -0.01em; } }
/* ---------- v13: chat attachments ---------- */
.att-tray { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 2px; }
.att-tray:empty { display: none; }
.att-chip { display: inline-flex; align-items: center; gap: 6px; max-width: 240px; padding: 4px 6px 4px 8px; border-radius: 10px; background: rgba(var(--fg-rgb), .06); border: 1px solid rgba(var(--fg-rgb), .1); font-size: 12px; }
.att-chip img { width: 28px; height: 28px; object-fit: cover; border-radius: 6px; }
.att-chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.att-chip button { background: none; border: 0; color: inherit; opacity: .6; cursor: pointer; display: grid; place-items: center; padding: 2px; }
.att-hint { flex-basis: 100%; }
.att-list { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 6px; }
.att-img img { max-width: 220px; max-height: 220px; border-radius: 10px; display: block; }
.att-file { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 10px; background: rgba(0,0,0,.2); color: inherit; text-decoration: none; font-size: 12.5px; }
.drop-on { outline: 2px dashed var(--accent-ink); outline-offset: -8px; }
/* ---------- v14: streaming, modes ---------- */
.live-status { display: flex; align-items: center; gap: 8px; font-size: 12.5px; opacity: .75; min-height: 4px; }
.live-status:empty { display: none; }
.spin { width: 12px; height: 12px; border-radius: 50%; border: 2px solid rgba(var(--accent-rgb), .25); border-top-color: var(--accent-ink); animation: vspin .8s linear infinite; }
.dots { display: inline-flex; gap: 4px; padding: 4px 0; }
.dots i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .4; animation: dotb 1.2s infinite ease-in-out; }
.dots i:nth-child(2) { animation-delay: .15s; } .dots i:nth-child(3) { animation-delay: .3s; }
@keyframes dotb { 0%, 80%, 100% { transform: translateY(0); opacity: .35 } 40% { transform: translateY(-3px); opacity: .9 } }
@keyframes vspin { to { transform: rotate(360deg) } }
.mode-btn.on { background: rgba(167,139,250,.18); border-color: #a78bfa; color: #c4b5fd; }
.bubble .att-list .att-img img { max-width: min(320px, 70vw); max-height: 320px; }
.att-video { display: flex; flex-direction: column; gap: 4px; }
.att-video video { width: min(340px, 72vw); max-height: 420px; border-radius: 12px; background: var(--bg); }

/* =====================================================================
   v15 — Office-B visual identity
   Ink Navy #090B0A · Citrus #C5FF32 · Warm Ivory #F4F6F2
   Light (ivory) is the default; dark (navy) follows the system or the toggle.
   ===================================================================== */
:root:root:root {
  --brand-navy: #090B0A; --brand-citrus: #C5FF32; --brand-ivory: #F4F6F2;
  --font: "Outfit", "Noto Sans KR", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-display: "Outfit", "Noto Sans KR", "Noto Sans SC", -apple-system, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --bg: #F4F6F2; --surface: #FFFFFF; --surface-2: #ECEFEA; --panel: #F4F6F2; --hover: #E7EBE5; --active: #DFE4DD;
  --border: #E1E5DF; --border-strong: #CBD2CA; --text: #090B0A; --muted: #5A615C; --faint: #8B918C;
  --accent: #C5FF32; --accent-strong: #B2EE16; --accent-ink: #3D5C00; --accent-text: #090B0A; --accent-soft: rgba(197, 255, 50, .45);
  --accent-rgb: 150, 205, 20; --fg-rgb: 20, 43, 54;
  --primary: #090B0A; --primary-text: #F4F6F2; --primary-hover: #161A17;
  --bubble-me: #C5FF32; --bubble-me-text: #090B0A; --bubble-bot: #FFFFFF; --chat-bg: #F4F6F2;
  --dock-bg: #090B0A; --dock-fg: rgba(244, 246, 242, .62); --dock-fg-on: #C5FF32;
  --warn-bg: #FFF3D1; --warn-text: #8A5A00; --danger: #C2410C; --success: #3D5C00;
  --shadow: 0 1px 2px rgba(9, 11, 10, .06), 0 8px 24px rgba(9, 11, 10, .06);
  --radius: 14px; color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:root:root:not([data-theme="light"]) {
    --bg: #090B0A; --surface: #090B0A; --surface-2: #141815; --panel: #090B0A; --hover: #141815; --active: #1B201C;
    --border: #1F2420; --border-strong: #2B322D; --text: #F4F6F2; --muted: #8F9792; --faint: #5F6661;
    --accent-ink: #C5FF32; --accent-rgb: 223, 255, 112; --fg-rgb: 245, 243, 236;
    --primary: #C5FF32; --primary-text: #090B0A; --primary-hover: #D6FF66;
    --bubble-bot: #141815; --chat-bg: #090B0A; --dock-bg: #050605;
    --warn-bg: rgba(242, 180, 90, .12); --warn-text: #F2C46D; --danger: #FF8A65; --success: #C5FF32;
    --shadow: 0 1px 2px rgba(0, 0, 0, .25), 0 10px 30px rgba(0, 0, 0, .25); color-scheme: dark;
  }
}
:root:root:root[data-theme="dark"] {
  --bg: #090B0A; --surface: #090B0A; --surface-2: #141815; --panel: #090B0A; --hover: #141815; --active: #1B201C;
  --border: #1F2420; --border-strong: #2B322D; --text: #F4F6F2; --muted: #8F9792; --faint: #5F6661;
  --accent-ink: #C5FF32; --accent-rgb: 223, 255, 112; --fg-rgb: 245, 243, 236;
  --primary: #C5FF32; --primary-text: #090B0A; --primary-hover: #D6FF66;
  --bubble-bot: #141815; --chat-bg: #090B0A; --dock-bg: #050605;
  --warn-bg: rgba(242, 180, 90, .12); --warn-text: #F2C46D; --danger: #FF8A65; --success: #C5FF32;
  --shadow: 0 1px 2px rgba(0, 0, 0, .25), 0 10px 30px rgba(0, 0, 0, .25); color-scheme: dark;
}

/* base */
html body { background: var(--bg); color: var(--text); font-family: var(--font); font-size: 15px; letter-spacing: -0.003em; font-feature-settings: normal; }
html h1, html h2, html h3 { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.025em; }
html .onb h1, html .hero-main h1, html .center main > h1, html .doc-cover h1, html .empty h3, html .roi .big, html .voice-name, html .plan-price, html .login-card h1 {
  font-family: var(--font-display); font-weight: 650; letter-spacing: -0.035em; }
html .roi .big { color: var(--text); }
html * { scrollbar-color: var(--border-strong) transparent; }
html *::-webkit-scrollbar-thumb { background: var(--border-strong); }
html ::selection { background: var(--brand-citrus); color: var(--brand-navy); }

/* wordmark: "Office-" + citrus B tile */
.wordmark { display: inline-flex; align-items: center; gap: .04em; font-family: var(--font-display); font-weight: 700; letter-spacing: -0.04em; color: var(--text); line-height: 1; white-space: nowrap; }
.wordmark .wm-b { display: inline-grid; place-items: center; background: var(--brand-citrus); color: var(--brand-navy); border-radius: .2em; padding: .04em .14em .02em; margin-left: .02em; }

/* buttons */
html .btn { border-radius: 12px; font-weight: 600; background: var(--surface); border: 1px solid var(--border-strong); color: var(--text); }
html .btn:hover { background: var(--hover); border-color: var(--border-strong); }
html .btn.primary { background: var(--primary); border-color: var(--primary); color: var(--primary-text); }
html .btn.primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); }
html .btn.primary:disabled { opacity: .45; }
html .send-btn, html [data-send] { background: var(--brand-citrus) !important; border-color: var(--brand-citrus) !important; color: var(--brand-navy) !important; }
html .send-btn:hover { filter: brightness(.97); }
html .voice-btn { border-color: var(--border-strong); background: var(--surface); color: var(--text); }
html .voice-btn:hover { background: var(--accent-soft); border-color: var(--accent-ink); color: var(--text); }
html .mode-btn.on { background: var(--brand-navy); border-color: var(--brand-navy); color: var(--brand-citrus); }
html .input, html textarea.input, html select.input { background: var(--surface); border-color: var(--border-strong); color: var(--text); }
html .input:focus { border-color: var(--text); box-shadow: 0 0 0 3px var(--accent-soft); }
html .field label { color: var(--text); }
html .card { background: var(--surface); border-color: var(--border); box-shadow: var(--shadow); }
html .badge { background: var(--surface-2); border-color: var(--border); color: var(--muted); }
html .badge.ok { background: var(--accent-soft); border-color: transparent; color: var(--brand-navy); }
html .badge.warn { background: var(--warn-bg); border-color: transparent; color: var(--warn-text); }
html .modal { background: var(--surface); border-color: var(--border); }
html #toast { background: var(--brand-navy); color: var(--brand-ivory); }

/* dock: always ink navy */
html .dock { background: var(--dock-bg); border-right: 0; }
html .dock-logo { border-radius: 11px; }
html .dock-item { color: var(--dock-fg); }
html .dock-item:hover { color: var(--brand-ivory); background: rgba(244, 246, 242, .08); }
html .dock-item.on { color: var(--dock-fg-on); background: rgba(197, 255, 50, .12); }
html .dock-item.on::before { background: var(--brand-citrus); }
html .dock-badge { background: var(--brand-citrus); color: var(--brand-navy); }
html .dock-mini { color: rgba(244, 246, 242, .7); }

/* rail + chat */
html .rail, html .rail-head { background: var(--surface); }
html .rail { border-right: 1px solid var(--border); }
html .rail-search input { background: var(--bg); border-color: var(--border); }
html .contact:hover { background: var(--hover); }
html .contact.on { background: var(--bg); box-shadow: inset 3px 0 0 var(--brand-citrus); }
html .c-badge { background: var(--brand-citrus); color: var(--brand-navy); }
html .presence { background: var(--accent-strong); border-color: var(--surface); }
html .chat-head { background: color-mix(in srgb, var(--surface) 88%, transparent); }
html .center, html .composer-wrap { background: var(--bg); }
html .composer-wrap { border-top: 1px solid var(--border); }
html .wa-bg { background-color: var(--chat-bg); background-image: radial-gradient(rgba(var(--fg-rgb), .045) 1px, transparent 1px); }
html .composer textarea { background: var(--surface); border-color: var(--border-strong); color: var(--text); }
html .composer textarea:focus { border-color: var(--text); }
html .msg.me .bubble { background: var(--bubble-me); color: var(--bubble-me-text); border: 0; }
html .msg.me .b-time, html .msg.me .b-copy { color: rgba(9, 11, 10, .55); }
html .msg.me .chan-tag { border-color: rgba(9, 11, 10, .25); color: rgba(9, 11, 10, .7); }
html .msg.me .att-file { background: rgba(9, 11, 10, .08); }
html .msg.bot .bubble { background: var(--bubble-bot); border: 1px solid var(--border); box-shadow: 0 1px 1px rgba(9, 11, 10, .03); }
html .b-copy:hover { background: var(--hover); color: var(--text); }
html .day-sep span { background: var(--surface); border-color: var(--border); color: var(--muted); }
html .deliver { background: var(--bg); border-color: var(--border); border-left: 3px solid var(--brand-citrus); }
html .deliver .dhead { color: var(--muted); }
html .copy-btn { background: var(--surface); border-color: var(--border-strong); color: var(--text); }
html .chip { background: var(--surface); border-color: var(--border); color: var(--text); }
html .chip:hover { border-color: var(--text); background: var(--surface); }
html .empty.card { background: var(--surface); border-color: var(--border); }
html .big-actions button { background: var(--bg); border-color: var(--border); color: var(--text); }
html .big-actions button:hover { border-color: var(--text); }
html .bubble a, html .bubble h2, html .bubble h3 { color: var(--text); }
html .bubble a { text-decoration-color: var(--accent-strong); text-underline-offset: 2px; }
html .md-table th { background: var(--surface-2); }
html .team-item { background: var(--bg); }
html .live-status .spin { border-color: rgba(var(--fg-rgb), .15); border-top-color: var(--accent-ink); }
html .filed-card { background: var(--accent-soft); border-color: transparent; }
html .filed-card svg { color: var(--text); }

/* avatars: flat brand-friendly tiles */
html .avatar { background: color-mix(in srgb, var(--c, #888) 88%, #090B0A); border: 0; box-shadow: none; color: #fff; font-family: var(--font-display); font-weight: 600; }
html .mono-chip { background: color-mix(in srgb, var(--c, #888) 85%, #090B0A); }

/* onboarding / login / plans */
html .topbar { background: color-mix(in srgb, var(--bg) 90%, transparent); border-bottom: 1px solid var(--border); }
html .topbar .logo { color: var(--text); }
html .login { background: var(--bg); }
html .login-card .login-logo { margin-bottom: 4px; }
html .plan-opt { background: var(--surface); border-color: var(--border); }
html .plan-opt.sel { border-color: var(--brand-navy); box-shadow: 0 0 0 1px var(--brand-navy) inset; }
html .compare .c-good { color: var(--accent-ink); }
html .compare .c-bad { color: var(--danger); }
html .trained { color: var(--accent-ink); }
html .industry.sel, html .industry:hover { border-color: var(--text); }
html .pick-row input[type="checkbox"] { accent-color: var(--brand-navy); }

/* voice screen */
html .voice-bg { background: radial-gradient(ellipse at 50% 30%, #161A17, #050605 75%); color: var(--brand-ivory); }
html .voice-state { color: var(--brand-citrus); }
html .v-line.me { background: rgba(197, 255, 50, .16); }
html .v-line.tool { color: var(--brand-citrus); border-color: rgba(197, 255, 50, .4); }

/* print: brand lines */
@media print { .pdoc-head { border-bottom-color: #090B0A !important; } .pdoc h2 { border-bottom-color: #E1E5DF !important; } .doc-cover { border-bottom-color: #C5FF32 !important; } }
html .dock-logo svg rect, html .logo-mark svg rect, html svg .lg-bg { fill: var(--brand-citrus) !important; }
html .dock-logo svg path, html .logo-mark svg path, html svg .lg-fg { fill: none !important; stroke: var(--brand-navy) !important; }
html .logo-mark { background: transparent; }
.seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 3px; gap: 2px; }
.seg button { border: 0; background: transparent; color: var(--muted); font: inherit; font-size: 13px; font-weight: 600; padding: 5px 12px; border-radius: 7px; cursor: pointer; }
.seg button.on { background: var(--surface); color: var(--text); box-shadow: 0 1px 2px rgba(9, 11, 10, .12); }
/* v15 — remaining components */
html .input::placeholder, html textarea::placeholder { color: var(--faint); }
html .rail-label { color: var(--faint); }
html .c-prev, html .c-time { color: var(--muted); }
html .d-head, html .d-actions, html .d-sec { border-bottom-color: var(--border); }
html .details { background: var(--surface); border-left: 1px solid var(--border); }
html .hero-main { background: linear-gradient(150deg, var(--brand-navy), #161A17); color: var(--brand-ivory); border: 0; }
html .hero-main h1, html .hero-main p { color: var(--brand-ivory); }
html .hero-main .badge { background: rgba(197, 255, 50, .16); color: var(--brand-citrus); border: 0; }
html .roi { background: var(--brand-citrus); color: var(--brand-navy); border: 0; }
html .roi .big, html .roi .sub, html .roi .muted { color: var(--brand-navy); }
html .tips, html .cal-day { background: var(--surface); }
html .pr-step.done .pr-num { background: var(--brand-citrus); color: var(--brand-navy); border-color: var(--brand-citrus); }
html .industry.sel { border-color: var(--brand-navy); box-shadow: 0 0 0 1px var(--brand-navy); }
html .steps span { background: var(--border); } html .steps span.on { background: var(--brand-navy); }
html .demo-try:hover { border-color: var(--text); }
html .ap-row + .ap-row { border-top-color: var(--border); }
html .slot { color: var(--text); }
html .slot:hover { background: var(--accent-soft); border-color: var(--accent-ink); }
html .typing i { background: var(--muted); }
html .ai-tag { color: #5B4FD6; border-color: rgba(91, 79, 214, .3); }
html .badge.warn, html .note.warn, html .demo-tag, html .st-held, html .bk-chip.warn { color: var(--warn-text); border-color: rgba(176, 120, 0, .3); }
html .note.warn, html .bk-chip.warn { background: var(--warn-bg); }
html .rem.bad, html .st-cancelled, html .st-noshow, html .bk-chip.bad, html .btn.danger { color: var(--danger); border-color: rgba(194, 65, 12, .3); }
html .ap-note { color: var(--warn-text); }
html .pr-kpi { background: var(--surface-2); border-color: var(--border); }
html .lang-opt { background: var(--surface); border-color: var(--border); color: var(--text); }
html .lang-opt.on { border-color: var(--brand-navy); box-shadow: 0 0 0 1px var(--brand-navy) inset; }
html .home-empty { color: var(--muted); }
html .topbar .badge.ok { background: var(--accent-soft); color: var(--brand-navy); }
html .msg.bot .bubble .deliver .dbody { color: var(--text); }
@media (prefers-color-scheme: dark) {
  html:not([data-theme="light"]) .badge.ok, html:not([data-theme="light"]) .topbar .badge.ok { background: rgba(197, 255, 50, .14); color: var(--brand-citrus); }
  html:not([data-theme="light"]) .ai-tag { color: #C4BDFF; }
}
html[data-theme="dark"] .badge.ok, html[data-theme="dark"] .topbar .badge.ok { background: rgba(197, 255, 50, .14); color: var(--brand-citrus); }
html[data-theme="dark"] .ai-tag { color: #C4BDFF; }
@media (max-width: 600px) {
  html .composer { gap: 4px; align-items: flex-end; }
  html .composer textarea { min-width: 0; flex: 1 1 auto; padding: 10px 14px; font-size: 16px; }
  html .composer .mode-btn, html .composer .attach-btn { width: 34px; height: 34px; border: 0; background: transparent; margin-bottom: 5px; }
  html .composer .voice-btn:not(.mode-btn):not(.attach-btn) { width: 40px; height: 40px; margin-bottom: 2px; }
  html .composer .send-btn { width: 42px; height: 42px; }
  html .composer-wrap { padding: 8px 10px 12px; }
}
html .composer textarea::placeholder { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.link-btn { background: none; border: 0; padding: 0 0 0 6px; color: var(--accent-ink); font: inherit; cursor: pointer; display: inline-flex; align-items: center; gap: 3px; }
.link-btn:hover { text-decoration: underline; }

/* =====================================================================
   v16 — Office-B identity 02 (premium)
   Carbon #090B0A · Acid Green #C5FF32 · Soft White #F4F6F2
   Dark is the default; light is optional. Green is used sparingly.
   ===================================================================== */
:root:root:root[data-theme="dark"] {
  --bg: #090B0A; --surface: #0F1210; --surface-2: #151916; --panel: #0F1210; --hover: #131714; --active: #1A1F1B;
  --border: #1D221F; --border-strong: #2A302C; --text: #F4F6F2; --muted: #8F9792; --faint: #5F6661;
  --bubble-bot: #111412; --chat-bg: #090B0A; --dock-bg: #050605;
  --shadow: 0 1px 0 rgba(244, 246, 242, .03) inset, 0 20px 40px rgba(0, 0, 0, .35);
}
html[data-theme="dark"] body { background: #090B0A; }

/* type: tighter, heavier, calmer */
html body { font-size: 15px; letter-spacing: -0.006em; }
html h1, html h2, html h3 { font-weight: 700; letter-spacing: -0.04em; }
html .onb h1, html .hero-main h1, html .center main > h1, html .login-card h1 { font-weight: 700; letter-spacing: -0.05em; line-height: 1.02; }
.eyebrow-label, html .rail-label, html .section-head h2, html .d-sec > h4, html .d-sec .d-title {
  font-size: 11px !important; letter-spacing: .16em !important; text-transform: uppercase; font-weight: 600 !important; color: var(--faint) !important; }
html .section-head h2 { color: var(--muted) !important; }

/* wordmark: Office + italic -B */
html .wordmark { font-weight: 800; letter-spacing: -0.05em; gap: 0; color: var(--text); }
html .wordmark .wm-b { display: inline-block; transform: skewX(-11deg); background: none; color: var(--brand-citrus); padding: 0; margin-left: .015em; border-radius: 0; }
html:not([data-theme="dark"]) .wordmark .wm-b { background: var(--brand-citrus); color: #090B0A; padding: 0 .12em; border-radius: .12em; }

/* surfaces: hairlines, no heavy shadows */
html .card { border-radius: 18px; }
html[data-theme="dark"] .card { background: linear-gradient(180deg, rgba(244, 246, 242, .018), rgba(244, 246, 242, 0) 120px), var(--surface); box-shadow: none; }
html[data-theme="dark"] .modal { background: #0F1210; border-color: #242A26; box-shadow: 0 30px 80px rgba(0, 0, 0, .6); }

/* hero + value card */
html .hero-main { background: radial-gradient(560px 280px at 100% 0%, rgba(197, 255, 50, .13), transparent 62%), linear-gradient(160deg, #121613, #090B0A 70%); border: 1px solid #1F2420; }
html:not([data-theme="dark"]) .hero-main { border: 0; }
html .hero-main .badge { background: rgba(197, 255, 50, .12); color: #C5FF32; }
html .roi { background: #C5FF32; color: #090B0A; }

/* dock */
html .dock { background: var(--dock-bg); border-right: 1px solid #141815; }
html .dock-item.on { background: rgba(197, 255, 50, .10); color: #C5FF32; }

/* chat: quieter background, crisp bubbles */
html[data-theme="dark"] .wa-bg { background-image: none; background-color: #090B0A; }
html .msg.me .bubble { background: #C5FF32; color: #090B0A; border-radius: 18px 18px 6px 18px; }
html .msg.bot .bubble { border-radius: 18px 18px 18px 6px; }
html[data-theme="dark"] .msg.bot .bubble { background: #111412; border-color: #1D221F; box-shadow: none; }
html[data-theme="dark"] .composer textarea { background: #0F1210; border-color: #242A26; }
html[data-theme="dark"] .composer textarea:focus { border-color: #C5FF32; box-shadow: 0 0 0 3px rgba(197, 255, 50, .12); }
html[data-theme="dark"] .chat-head { background: rgba(9, 11, 10, .86); }
html[data-theme="dark"] .rail, html[data-theme="dark"] .rail-head, html[data-theme="dark"] .details { background: #0B0D0C; }
html[data-theme="dark"] .contact.on { background: #121513; box-shadow: inset 2px 0 0 #C5FF32; }
html[data-theme="dark"] .chip { background: transparent; border-color: #242A26; color: #C9CFCA; }
html[data-theme="dark"] .chip:hover { border-color: #C5FF32; color: #F4F6F2; }

/* buttons */
html .btn { border-radius: 999px; padding: 9px 18px; }
html .btn.lg { padding: 13px 26px; }
html .btn.sm { padding: 4px 12px; }
html[data-theme="dark"] .btn.primary { background: #C5FF32; border-color: #C5FF32; color: #090B0A; }
html[data-theme="dark"] .btn.primary:hover { background: #D6FF66; border-color: #D6FF66; }
html[data-theme="dark"] .btn:not(.primary) { background: transparent; border-color: #2A302C; }
html[data-theme="dark"] .btn:not(.primary):hover { border-color: #F4F6F2; background: transparent; }

/* login: big wordmark on carbon with a soft green glow */
html .login { background: radial-gradient(700px 360px at 50% -10%, rgba(197, 255, 50, .10), transparent 70%), var(--bg); }
html .login-card h1 { font-size: 30px; margin-top: 28px; }
html .login-logo .wordmark { font-size: 46px !important; }

/* onboarding plan cards */
html[data-theme="dark"] .plan-opt.sel { border-color: #C5FF32; box-shadow: 0 0 0 1px #C5FF32 inset; }
html .compare .c-good { color: var(--accent-ink); }

/* voice screen */
html .voice-bg { background: radial-gradient(ellipse at 50% 25%, #141914, #050605 72%); }
html .voice-orb .ring { border-color: #C5FF32; }
html body .roi.card, html[data-theme] body .roi.card { background: #C5FF32; border-color: #C5FF32; color: #090B0A; }
html body .roi.card .big, html body .roi.card .sub, html body .roi.card .muted, html body .roi.card span { color: #090B0A !important; opacity: 1; }
html body .roi.card .muted { opacity: .7; }
html[data-theme="dark"] body .hero-main.card { background: radial-gradient(560px 280px at 100% 0%, rgba(197, 255, 50, .13), transparent 62%), linear-gradient(160deg, #121613, #090B0A 70%); }
