/**
 * @copyright Copyright (c) 2026 WBPC-GLOBAL. All Rights Reserved. Proprietary.
 * 문제: 대화창이 작은 박스 · 제어판·사이드 없음 /
 * 이유: 사령관 — Cursor급 회원 실사용 · 제어판·기능 포함 /
 * 수정: 전면 셸 · 사이드 · 컴포저 · 제어판 · Soft≠LIVE
 */
html {
  /* 문제: 핸드폰 대화 구도가 레이아웃뷰포트와 어긋남 /
     이유: inset:0·100vw 는 주소창·홈바를 포함한 큰 상자 /
     수정: visualViewport → --app-h/--app-w/--app-top/--app-left */
  --app-h: 100dvh;
  --app-w: 100%;
  --app-top: 0px;
  --app-left: 0px;
}
html,
body.mcc-page {
  /* 문제: html/body까지 --app-h면 키보드 offset이 겹쳐 입력칸이 잘림 /
     이유: 다른 AI 대화창은 문서상자는 화면 전체, 대화 호스트만 보이는 영역 /
     수정: 문서=100dvh. 호스트만 visualViewport */
  height: 100%;
  height: 100dvh;
  max-height: 100%;
  width: 100%;
  max-width: 100%;
  margin: 0;
  overflow: hidden;
}

body.mcc-page {
  /* 문제: 크림·금색 띠가 지금 대화창과 다름 /
     이유: 사령관 — 사이트 대화창을 Cursor 대화처럼 /
     수정: 기본 다크 셸. paper는 제어판에서만 */
  --mcc-bg: #181818;
  --mcc-panel: #1e1e1e;
  --mcc-ink: #e8e8e8;
  --mcc-muted: #9a9a9a;
  --mcc-line: rgba(255, 255, 255, 0.1);
  --mcc-accent: #3b82f6;
  --mcc-side: #141414;
  --mcc-bot: transparent;
  --mcc-user: #2a2d33;
  --mcc-fs: 15px;
  background: var(--mcc-bg);
  color: var(--mcc-ink);
  font-family: "Pretendard", "Noto Sans KR", system-ui, sans-serif;
  font-size: var(--mcc-fs);
}

html[data-mcc-theme="paper"] body.mcc-page {
  --mcc-bg: #f4efe4;
  --mcc-panel: #fffdf8;
  --mcc-ink: #1c2430;
  --mcc-muted: #6b7788;
  --mcc-line: rgba(28, 36, 48, 0.12);
  --mcc-side: #f7f2e8;
  --mcc-bot: #ffffff;
  --mcc-user: #e8f0ff;
}
html[data-mcc-theme="light"] body.mcc-page {
  --mcc-bg: #f5f7fa;
  --mcc-panel: #ffffff;
  --mcc-side: #eef2f7;
  --mcc-bot: #ffffff;
  --mcc-user: #e8f0ff;
}
html[data-mcc-theme="dark"] body.mcc-page {
  --mcc-bg: #181818;
  --mcc-panel: #1e1e1e;
  --mcc-ink: #e8e8e8;
  --mcc-muted: #9a9a9a;
  --mcc-line: rgba(255, 255, 255, 0.1);
  --mcc-side: #141414;
  --mcc-bot: transparent;
  --mcc-user: #2a2d33;
}
html[data-mcc-theme="navy"] body.mcc-page {
  --mcc-bg: #0b1a33;
  --mcc-panel: #102040;
  --mcc-ink: #e8eef8;
  --mcc-muted: #9aacc4;
  --mcc-line: rgba(232, 238, 248, 0.14);
  --mcc-side: #0d1f3d;
  --mcc-bot: #132848;
  --mcc-user: #1a3560;
}

html[data-mcc-font="xs"] body.mcc-page {
  --mcc-fs: 11.5px;
}
html[data-mcc-font="sm"] body.mcc-page {
  --mcc-fs: 13px;
}
html[data-mcc-font="md"] body.mcc-page {
  --mcc-fs: 15px;
}
html[data-mcc-font="lg"] body.mcc-page {
  --mcc-fs: 16.5px;
}
html[data-mcc-font="xl"] body.mcc-page {
  --mcc-fs: 18px;
}
html.mcc-compact body.mcc-page {
  --mcc-fs: 12px;
}
html.mcc-compact[data-mcc-font="xs"] body.mcc-page {
  --mcc-fs: 11px;
}
html.mcc-compact[data-mcc-font="sm"] body.mcc-page {
  --mcc-fs: 12px;
}
html.mcc-compact[data-mcc-font="md"] body.mcc-page {
  --mcc-fs: 12.5px;
}
html.mcc-compact[data-mcc-font="lg"] body.mcc-page {
  --mcc-fs: 14px;
}
html.mcc-compact[data-mcc-font="xl"] body.mcc-page {
  --mcc-fs: 15.5px;
}

#djetora-cursor-host,
.djetora-cursor-host {
  height: 100%;
  min-height: 0;
}

#wbpc-member-cursor-chat,
.mcc-root {
  height: 100%;
  min-height: 0;
}

/* 문제: 100dvh가 팝업보다 커서 입력칸이 잘리고 말은 위에만 붙음 /
   이유: 사령관 — 이게 정상이냐 /
   수정: 호스트 높이에 맞춤 · 대화는 입력칸 바로 위 */
.mcc-shell {
  display: grid;
  grid-template-columns: 260px 1fr;
  grid-template-rows: 1fr;
  height: 100%;
  max-height: 100%;
  min-height: 0;
  max-width: none;
  width: 100%;
  margin: 0;
  border: 0;
  border-radius: 0;
  overflow: hidden;
  background: var(--mcc-bg);
  box-shadow: none;
}

.mcc-face {
  display: none;
}

body.mcc-side-collapsed .mcc-shell {
  grid-template-columns: 0 1fr;
}
body.mcc-side-collapsed .mcc-side {
  overflow: hidden;
  border: 0;
  padding: 0;
  opacity: 0;
  pointer-events: none;
}

.mcc-side {
  grid-row: 1;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0.85rem 0.75rem;
  background: var(--mcc-side);
  border-right: 1px solid var(--mcc-line);
  min-height: 0;
}

.mcc-side-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
}

.mcc-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: inherit;
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.mcc-new,
.mcc-side-btn,
.mcc-icon-btn,
.mcc-send,
.mcc-attach,
.mcc-control-save,
.mcc-control-close,
.mcc-copy,
.mcc-chip {
  font: inherit;
  cursor: pointer;
}

.mcc-new {
  border: 1px solid var(--mcc-line);
  background: transparent;
  color: inherit;
  padding: 0.35rem 0.55rem;
  border-radius: 8px;
}

.mcc-thread-list {
  flex: 1;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.mcc-thread {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  width: 100%;
  text-align: left;
  border: 0;
  background: transparent;
  color: inherit;
  padding: 0.45rem 0.5rem;
  border-radius: 8px;
}

.mcc-thread:hover,
.mcc-thread-on {
  background: rgba(47, 111, 237, 0.1);
}

.mcc-thread-title {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.92em;
}

.mcc-thread-del {
  opacity: 0;
  border: 0;
  background: transparent;
  color: var(--mcc-muted);
  padding: 0 0.2rem;
}
.mcc-thread:hover .mcc-thread-del {
  opacity: 1;
}

.mcc-side-tools {
  display: flex;
  gap: 0.35rem;
}
.mcc-side-btn,
.mcc-icon-btn {
  border: 1px solid var(--mcc-line);
  background: transparent;
  color: inherit;
  padding: 0.35rem 0.55rem;
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.85em;
}

.mcc-side-foot,
.mcc-prog-hint,
.mcc-note,
.mcc-attach-note {
  color: var(--mcc-muted);
  font-size: 0.78em;
  margin: 0.25rem 0 0;
}

.mcc-main {
  grid-row: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  overflow: hidden;
}

.mcc-top {
  flex-shrink: 0;
  padding: 0.75rem 1rem 0.5rem;
  border-bottom: 1px solid var(--mcc-line);
}

.mcc-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}

.mcc-top-title {
  font-weight: 700;
}

.mcc-top-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.mcc-capability-rail {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  max-height: 4.6rem;
  overflow: auto;
}

.mcc-cap {
  border: 1px solid var(--mcc-line);
  background: transparent;
  color: inherit;
  padding: 0.28rem 0.55rem;
  border-radius: 999px;
  font-size: 0.78em;
}

.mcc-cap-open {
  border-color: var(--mcc-accent);
  color: var(--mcc-accent);
}
.mcc-cap-open:hover {
  background: rgba(47, 111, 237, 0.08);
}
.mcc-cap-locked,
.mcc-cap:disabled {
  opacity: 0.42;
  cursor: not-allowed;
  color: var(--mcc-muted);
}

.mcc-auth-banner {
  margin: 0.4rem auto 0;
  max-width: 48rem;
  width: calc(100% - 2rem);
  padding: 0.35rem 0.75rem;
  border: 0;
  border-radius: 0;
  background: transparent;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.75rem;
}
.mcc-auth-banner .mcc-auth-copy {
  margin: 0;
  font-size: 0.82rem;
  color: var(--mcc-muted);
  flex: 1 1 12rem;
}
.mcc-auth-banner .mcc-auth-copy a {
  color: var(--mcc-accent);
  font-weight: 700;
}
.mcc-side-locked {
  margin: 0.85rem 0.7rem;
  color: var(--mcc-muted);
  font-size: 0.82rem;
  line-height: 1.45;
}
/* Soft Open: 게이트 locked여도 입력은 연다. 흐림 잠금 없음 */
.mcc-auth-links {
  display: flex;
  gap: 0.85rem;
}
.mcc-login-toggle {
  font: inherit;
  cursor: pointer;
  border: 1px solid var(--mcc-line);
  background: var(--mcc-accent);
  color: #fff;
  padding: 0.35rem 0.8rem;
  border-radius: 8px;
  font-weight: 700;
}
.mcc-login-form[hidden] {
  display: none !important;
}
.mcc-login-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0;
  flex: 1 1 100%;
}
.mcc-login-form input {
  flex: 1 1 7rem;
  min-height: 2.1rem;
  padding: 0.35rem 0.5rem;
  border: 1px solid var(--mcc-line);
  border-radius: 8px;
  background: var(--mcc-panel);
  color: inherit;
}
.mcc-login-form button {
  min-height: 2.1rem;
  padding: 0.35rem 0.8rem;
  border: 0;
  border-radius: 8px;
  background: #2f6fed;
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}
.mcc-login-err { color: #b42318; margin: 0.35rem 0 0; }

.mcc-log {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 0.75rem 1.1rem 0.35rem;
  display: flex;
  flex-direction: column;
  max-width: 48rem;
  width: 100%;
  margin: 0 auto;
}
.mcc-log-grow {
  flex: 1 1 auto;
  min-height: 0.25rem;
}

.mcc-welcome {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  max-width: 36rem;
  margin: 0 auto;
  min-height: 100%;
  text-align: center;
}
.mcc-welcome-brand {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  margin: 0 0 0.5rem;
}
.mcc-welcome-line {
  font-size: 1.25rem;
  margin: 0 0 0.45rem;
}
.mcc-welcome-sub {
  color: var(--mcc-muted);
  margin: 0 0 1rem;
}
.mcc-welcome-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  justify-content: center;
}
.mcc-chip {
  border: 1px solid var(--mcc-line);
  background: var(--mcc-panel);
  color: inherit;
  padding: 0.4rem 0.7rem;
  border-radius: 999px;
}

.mcc-bubble {
  max-width: min(42rem, 100%);
  width: 100%;
  margin: 0.55rem 0;
  padding: 0.15rem 0;
  border-radius: 0;
  line-height: 1.7;
  align-self: stretch;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.mcc-bubble.mcc-bot {
  background: var(--mcc-bot);
  border: 0;
}
.mcc-bubble.mcc-user {
  align-self: flex-end;
  width: fit-content;
  max-width: min(36rem, 86%);
  padding: 0.65rem 0.9rem;
  border-radius: 14px;
  background: var(--mcc-user);
  border: 0;
}
.mcc-md-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0.35rem 0;
  font-size: 0.92em;
}
.mcc-md-table th,
.mcc-md-table td {
  border: 1px solid var(--mcc-line);
  padding: 0.28rem 0.45rem;
  text-align: left;
}

/* 문제: 대기 문구가 안 보임 / 이유: 사령관 — 글자 점멸·무지개 점열 / 수정: 로그 아래 상태줄 */
.mcc-status {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-shrink: 0;
  min-height: 1.75rem;
  padding: 0.2rem 1.1rem 0.55rem;
  font-size: 18px;
  font-weight: 700;
  color: #2563eb;
}
.mcc-status[hidden] {
  display: none !important;
}
.mcc-status-text.mcc-status-blink {
  animation: mcc-status-blink 1s infinite;
}
@keyframes mcc-status-blink {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.3;
  }
}
.mcc-btn-list,
.mcc-btn-new {
  display: none;
}
.mcc-bubble-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.25rem;
  color: var(--mcc-muted);
  font-size: 0.78em;
}
.mcc-copy {
  border: 0;
  background: transparent;
  color: var(--mcc-muted);
}

.mcc-composer {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 0.45rem;
  align-items: end;
  flex-shrink: 0;
  margin: 0.5rem auto 1rem;
  max-width: 48rem;
  width: calc(100% - 2rem);
  padding: 0.7rem 0.8rem;
  border: 1px solid var(--mcc-line);
  border-radius: 16px;
  background: var(--mcc-panel);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.28);
}

.mcc-input {
  width: 100%;
  resize: none;
  border: 0;
  outline: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  line-height: 1.5;
  max-height: 160px;
  padding: 0.35rem 0.15rem;
}

.mcc-attach,
.mcc-send {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 999px;
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.mcc-attach {
  background: transparent;
  border: 1px solid var(--mcc-line);
  color: inherit;
}
.mcc-send {
  background: var(--mcc-accent);
  color: #fff;
}

.mcc-attach-note,
.mcc-note {
  margin: 0 1.1rem 0.75rem;
}

/* 문제: 결과 파일이 창에 안 보임 / 수정: 첨부 칩·코드칸 */
.mcc-files {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.65rem;
}
.mcc-file {
  display: inline-flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.45rem 0.7rem;
  border: 1px solid var(--mcc-line);
  border-radius: 10px;
  background: var(--mcc-panel);
  color: inherit;
  text-decoration: none;
  font-size: 0.85em;
}
.mcc-file-name {
  font-weight: 600;
}
.mcc-file-preview {
  max-width: 180px;
  max-height: 180px;
  background: #1a1e24;
  border-radius: 8px;
}
.mcc-doc-preview {
  width: 100%;
  margin-top: 0.65rem;
}
.mcc-pdf-frame {
  width: 100%;
  min-height: 420px;
  border: 1px solid var(--mcc-line);
  border-radius: 12px;
  background: #111;
}
.mcc-file-sub {
  font-size: 0.75em;
  opacity: 0.75;
  font-weight: 400;
}
.mcc-code {
  margin: 0.5rem 0 0;
  padding: 0.7rem 0.8rem;
  overflow: auto;
  max-height: 520px;
  border-radius: 10px;
  background: #151b22;
  color: #e8eef4;
  font-size: 0.82em;
  line-height: 1.45;
}

.mcc-council {
  margin: 0.5rem 1rem 0;
  padding: 0.55rem 0.7rem;
  border: 1px dashed var(--mcc-line);
  border-radius: 10px;
  color: var(--mcc-muted);
  font-size: 0.85em;
}
.mcc-council-lanes {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.35rem;
}
.mcc-council-lane {
  border: 1px solid var(--mcc-line);
  padding: 0.15rem 0.4rem;
  border-radius: 6px;
}

.lounge-lease-hint {
  display: none;
}

/* 제어판 */
.mcc-control-panel {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: rgba(10, 14, 20, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.mcc-control-panel[hidden] {
  display: none !important;
}
.mcc-control-card {
  width: min(420px, 100%);
  background: var(--mcc-panel);
  color: var(--mcc-ink);
  border: 1px solid var(--mcc-line);
  border-radius: 16px;
  padding: 1rem;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.18);
}
.mcc-control-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}
.mcc-control-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin: 0.55rem 0;
  font-size: 0.9em;
}
.mcc-control-field select,
.mcc-control-field input {
  font: inherit;
  padding: 0.45rem 0.55rem;
  border-radius: 8px;
  border: 1px solid var(--mcc-line);
  background: transparent;
  color: inherit;
}
.mcc-control-check {
  display: flex;
  gap: 0.45rem;
  align-items: center;
  margin: 0.55rem 0;
}
.mcc-control-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 0.75rem 0;
}
.mcc-control-links a {
  color: var(--mcc-accent);
}
.mcc-control-note {
  color: var(--mcc-muted);
  font-size: 0.78em;
}
.mcc-control-save {
  width: 100%;
  margin-top: 0.5rem;
  border: 0;
  border-radius: 10px;
  padding: 0.65rem;
  background: var(--mcc-accent);
  color: #fff;
}
.mcc-control-close {
  border: 1px solid var(--mcc-line);
  background: transparent;
  color: inherit;
  border-radius: 8px;
  padding: 0.3rem 0.55rem;
}

/* 문제: 핸드폰에서 대화창 구도가 안 맞음 /
   이유: 데스크톱 2열 그리드 + host inset:0(레이아웃뷰포트) + 접힌 사이드 0+1fr /
   수정: .mcc-compact = 보이는 화면 상자 · flex 1열 · 입력칸 하단 고정 */
html.mcc-compact #djetora-cursor-host,
html.mcc-compact .djetora-cursor-host,
body.mcc-compact #djetora-cursor-host,
body.mcc-compact .djetora-cursor-host {
  position: fixed;
  top: var(--app-top, 0px);
  left: var(--app-left, 0px);
  right: auto;
  bottom: auto;
  inset: auto;
  box-sizing: border-box;
  width: var(--app-w, 100%);
  height: var(--app-h, 100dvh);
  max-width: 100%;
  max-height: var(--app-h, 100dvh);
  overflow-x: hidden;
  z-index: 2;
}
html.mcc-compact,
html.mcc-compact body.mcc-page,
body.mcc-compact {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  overflow: hidden;
}
html.mcc-compact #wbpc-member-cursor-chat,
html.mcc-compact .mcc-root,
body.mcc-compact #wbpc-member-cursor-chat,
body.mcc-compact .mcc-root {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  overflow: hidden;
}
html.mcc-compact .mcc-shell,
body.mcc-compact .mcc-shell,
body.mcc-compact.mcc-side-collapsed .mcc-shell {
  display: flex;
  flex-direction: column;
  grid-template-columns: none;
  grid-template-rows: none;
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
}
html.mcc-compact .mcc-face,
body.mcc-compact .mcc-face {
  display: none;
}
html.mcc-compact .mcc-btn-list,
body.mcc-compact .mcc-btn-list {
  display: inline-flex;
}
html.mcc-compact .mcc-side,
body.mcc-compact .mcc-side {
  position: fixed;
  z-index: 40;
  left: var(--app-left, 0px);
  top: var(--app-top, 0px);
  bottom: auto;
  width: min(280px, 86vw);
  max-height: none;
  height: var(--app-h, 100dvh);
  border-right: 1px solid var(--mcc-line);
  border-bottom: 0;
  box-shadow: 8px 0 28px rgba(16, 24, 40, 0.18);
}
html.mcc-compact body.mcc-side-collapsed .mcc-side,
body.mcc-compact.mcc-side-collapsed .mcc-side {
  transform: translateX(-110%);
  opacity: 0;
  pointer-events: none;
  width: min(280px, 86vw);
  padding: 0.85rem 0.75rem;
}
html.mcc-compact .mcc-main,
body.mcc-compact .mcc-main {
  flex: 1 1 auto;
  grid-column: auto;
  grid-row: auto;
  min-width: 0;
  min-height: 0;
  width: 100%;
}
html.mcc-compact .mcc-capability-rail,
body.mcc-compact .mcc-capability-rail {
  max-height: 2.2rem;
}
html.mcc-compact .mcc-prog-hint,
body.mcc-compact .mcc-prog-hint {
  display: none;
}
html.mcc-compact,
html.mcc-compact body.mcc-page {
  overscroll-behavior: none;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
html.mcc-compact .mcc-top,
body.mcc-compact .mcc-top {
  display: block !important;
  flex-shrink: 0;
  padding: max(0.25rem, env(safe-area-inset-top)) max(0.45rem, env(safe-area-inset-right)) 0.2rem max(0.45rem, env(safe-area-inset-left));
}
html.mcc-compact .mcc-top-row,
body.mcc-compact .mcc-top-row {
  margin-bottom: 0;
  gap: 0.25rem;
  min-height: 44px;
}
html.mcc-compact .mcc-top-title,
body.mcc-compact .mcc-top-title {
  flex: 1;
  text-align: center;
  font-size: 0.92em;
}
html.mcc-compact .mcc-top-actions,
body.mcc-compact .mcc-top-actions {
  flex-wrap: nowrap;
}
html.mcc-compact .mcc-top-actions a,
body.mcc-compact .mcc-top-actions a {
  display: none;
}
html.mcc-compact .mcc-btn-new,
body.mcc-compact .mcc-btn-new {
  display: inline-flex;
}
html.mcc-compact .mcc-btn-clear,
body.mcc-compact .mcc-btn-clear {
  display: none;
}
html.mcc-compact .mcc-copy,
body.mcc-compact .mcc-copy {
  display: none;
}
html.mcc-compact .mcc-cap[data-href],
body.mcc-compact .mcc-cap[data-href] {
  display: none;
}
html.mcc-compact .mcc-log,
body.mcc-compact .mcc-log {
  flex: 1 1 auto;
  min-height: 0;
  padding: 0.4rem 0.7rem 0.2rem;
  max-width: none;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
html.mcc-compact .mcc-bubble,
body.mcc-compact .mcc-bubble {
  max-width: min(42rem, calc(100% - 1rem));
}
html.mcc-compact .mcc-welcome-brand,
body.mcc-compact .mcc-welcome-brand {
  font-size: 1.08em;
}
html.mcc-compact .mcc-welcome-line,
body.mcc-compact .mcc-welcome-line {
  font-size: 0.98em;
}
html.mcc-compact .mcc-note,
html.mcc-compact .mcc-attach-note,
body.mcc-compact .mcc-note,
body.mcc-compact .mcc-attach-note {
  margin: 0 0.7rem 0.2rem;
}
html.mcc-compact .mcc-side-dim,
body.mcc-compact .mcc-side-dim {
  display: none;
  position: fixed;
  z-index: 35;
  inset: 0;
  border: 0;
  margin: 0;
  padding: 0;
  background: rgba(0, 0, 0, 0.42);
}
html.mcc-compact body:not(.mcc-side-collapsed) .mcc-side-dim,
body.mcc-compact:not(.mcc-side-collapsed) .mcc-side-dim {
  display: block;
}
html.mcc-compact .mcc-side,
body.mcc-compact .mcc-side {
  transition: transform 0.2s ease, opacity 0.2s ease;
}
html.mcc-compact .mcc-auth-copy,
body.mcc-compact .mcc-auth-copy {
  display: none;
}
html.mcc-compact .mcc-auth-banner,
body.mcc-compact .mcc-auth-banner {
  margin: 0.15rem 0.5rem 0;
  width: auto;
  max-width: none;
  padding: 0.15rem 0.35rem;
}
html.mcc-compact .mcc-composer,
body.mcc-compact .mcc-composer {
  display: flex;
  align-items: flex-end;
  gap: 0.35rem;
  box-sizing: border-box;
  width: auto;
  max-width: 100%;
  margin: 0.2rem max(0.5rem, env(safe-area-inset-right)) max(0.35rem, env(safe-area-inset-bottom)) max(0.5rem, env(safe-area-inset-left));
  padding: 0.35rem 0.4rem;
  border-radius: 24px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.22);
}
html.mcc-compact .mcc-input,
body.mcc-compact .mcc-input {
  font-size: 16px;
  line-height: 1.4;
  min-height: 24px;
  max-height: 96px;
  padding: 0.45rem 0.2rem;
}
html.mcc-compact .mcc-attach,
html.mcc-compact .mcc-send,
body.mcc-compact .mcc-attach,
body.mcc-compact .mcc-send {
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
}
html.mcc-compact .mcc-thread-del,
body.mcc-compact .mcc-thread-del {
  opacity: 1;
  min-width: 2rem;
  min-height: 2rem;
}
html.mcc-compact .mcc-icon-btn,
html.mcc-compact .mcc-new,
html.mcc-compact .mcc-side-btn,
html.mcc-compact .mcc-login-toggle,
body.mcc-compact .mcc-icon-btn,
body.mcc-compact .mcc-new,
body.mcc-compact .mcc-side-btn,
body.mcc-compact .mcc-login-toggle {
  min-height: 44px;
  min-width: 44px;
  touch-action: manipulation;
}
html.mcc-compact .mcc-control-check,
body.mcc-compact .mcc-control-check {
  display: none;
}
html.mcc-compact .mcc-control-panel,
body.mcc-compact .mcc-control-panel {
  align-items: flex-end;
  padding: 0;
}
html.mcc-compact .mcc-control-card,
body.mcc-compact .mcc-control-card {
  width: 100%;
  max-height: min(88dvh, var(--app-h, 88dvh));
  overflow: auto;
  border-radius: 16px 16px 0 0;
  padding: 1rem 1rem max(1rem, env(safe-area-inset-bottom));
}
html.mcc-kb-open .mcc-auth-banner,
html.mcc-kb-open .mcc-capability-rail,
html.mcc-kb-open .mcc-attach-note {
  display: none !important;
}
html.mcc-kb-open .mcc-top {
  padding-top: 0.1rem;
  padding-bottom: 0.05rem;
}
html.mcc-kb-open .mcc-composer {
  margin-bottom: 0.2rem;
}

@media (max-width: 1024px) {
  /* 문제: 핸드폰에서 폭이 넘치고 글씨가 큼 /
     이유: 2열 260px + 100dvw · compact 클래스 전에 데스크톱 격자 /
     수정: 보이는 너비 자동맞춤 · 아주작게 기본. Soft≠LIVE */
  html,
  html body.mcc-page {
    overflow-x: hidden;
    width: 100%;
    max-width: 100%;
    overscroll-behavior: none;
  }
  body.mcc-page {
    --mcc-fs: 12px;
  }
  html[data-mcc-font="xs"] body.mcc-page {
    --mcc-fs: 11px;
  }
  #djetora-cursor-host,
  .djetora-cursor-host,
  #wbpc-member-cursor-chat,
  .mcc-root,
  .mcc-shell,
  .mcc-main,
  .mcc-log {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow-x: hidden;
  }
  .mcc-shell,
  body.mcc-side-collapsed .mcc-shell {
    display: flex !important;
    flex-direction: column;
    grid-template-columns: none !important;
  }
  .mcc-welcome-brand {
    font-size: 1.08em;
  }
  .mcc-welcome-line {
    font-size: 0.98em;
  }
  .mcc-status {
    font-size: 1em;
  }
  .mcc-bubble,
  .mcc-bubble pre,
  .mcc-bubble code,
  .mcc-bubble img,
  .mcc-md-table {
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: break-word;
  }
}
