:root {
  --mc-bg: #eef4ff;
  --mc-card: #ffffff;
  --mc-line: #d7e3f4;
  --mc-text: #12213f;
  --mc-muted: #64748b;
  --mc-accent: #4f46e5;
  --mc-accent-strong: #2f6fff;
  --mc-accent-soft: #eef4ff;
  --mc-shadow: rgb(17 30 68 / 14%);
  font-family: "Noto Sans SC", sans-serif;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  color: var(--mc-text);
  background: linear-gradient(180deg, #f4f8ff 0%, #ffffff 40%, #f7faff 100%);
}
.hidden { display: none !important; }
.mc-shell { width: min(1320px, calc(100% - 32px)); margin: 0 auto; }
.mc-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgb(8 16 38 / 86%);
  backdrop-filter: blur(14px);
}
.mc-header .mc-shell {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.mc-brand {
  color: #fff;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}
.mc-brand-icon {
  width: 42px;
  height: 42px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #6ea8ff, #2f6fff);
}
.mc-nav { display: flex; gap: 22px; }
.mc-nav a { color: rgb(255 255 255 / 82%); text-decoration: none; }
.mc-head-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.mc-main { padding-bottom: 48px; }
.mc-hero { padding: 56px 0 28px; }
.mc-hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #11193d 0%, #2a4fd7 55%, #57a0ff 100%);
  color: #fff;
  padding: 72px 0 40px;
}
.mc-hero::before,
.mc-hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(10px);
  opacity: 0.35;
}
.mc-hero::before {
  width: 320px;
  height: 320px;
  background: #7cc7ff;
  top: -120px;
  right: -60px;
}
.mc-hero::after {
  width: 260px;
  height: 260px;
  background: #8f7cff;
  bottom: -120px;
  left: -60px;
}
.mc-hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(290px, 0.8fr);
  gap: 24px;
}
.mc-kicker {
  display: inline-flex;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgb(255 255 255 / 18%);
  color: #fff;
  font-weight: 800;
  font-size: 0.86rem;
}
.mc-hero h1 {
  margin: 16px 0 14px;
  font-size: clamp(2.1rem, 5vw, 4rem);
  line-height: 1.08;
}
.mc-hero p {
  margin: 0;
  max-width: 760px;
  color: rgb(255 255 255 / 86%);
  line-height: 1.85;
}
.mc-model-banner {
  display: grid;
  gap: 10px;
  max-width: 760px;
  margin-top: 24px;
  padding: 18px 20px;
  border-radius: 22px;
  background: rgb(255 255 255 / 12%);
  border: 1px solid rgb(255 255 255 / 18%);
  box-shadow: 0 18px 36px rgb(11 18 44 / 16%);
}
.mc-model-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 32px;
  padding: 0 14px;
  border-radius: 999px;
  background: #fff;
  color: #17306b;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}
.mc-model-banner strong {
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  line-height: 1.35;
}
.mc-model-banner span:last-child {
  color: rgb(255 255 255 / 88%);
  line-height: 1.75;
}
.mc-pills { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; }
.mc-pills span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  background: rgb(255 255 255 / 12%);
  border: 1px solid rgb(255 255 255 / 20%);
  box-shadow: 0 12px 28px rgb(11 18 44 / 16%);
}
.mc-hero-card, .mc-panel {
  background: var(--mc-card);
  border: 1px solid var(--mc-line);
  border-radius: 24px;
  box-shadow: 0 24px 48px var(--mc-shadow);
}
.mc-hero-card {
  padding: 24px;
  background: linear-gradient(180deg, rgb(255 255 255 / 22%), rgb(255 255 255 / 10%));
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 28%), 0 24px 48px rgb(6 12 34 / 22%);
  color: #fff;
}
.mc-card-title { color: rgb(255 255 255 / 72%); }
.mc-session-label { margin-top: 12px; font-size: 1.4rem; font-weight: 800; }
.mc-session-meta { margin-top: 10px; color: rgb(255 255 255 / 82%); line-height: 1.7; }
.mc-model-card {
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid rgb(255 255 255 / 18%);
}
.mc-model-overline {
  color: rgb(255 255 255 / 72%);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}
.mc-model-current-name {
  margin-top: 10px;
  font-size: 1.18rem;
  font-weight: 800;
}
.mc-model-current-desc {
  margin-top: 8px;
  color: rgb(255 255 255 / 84%);
  line-height: 1.7;
}
.mc-model-switch {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}
.mc-model-btn {
  min-height: 44px;
  padding: 0 16px;
  border-radius: 14px;
  border: 1px solid rgb(255 255 255 / 22%);
  background: rgb(255 255 255 / 10%);
  color: #fff;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  transition: transform 160ms ease, background 160ms ease, color 160ms ease, box-shadow 160ms ease;
}
.mc-model-btn:hover {
  transform: translateY(-1px);
}
.mc-model-btn.active {
  color: #17306b;
  background: #fff;
  box-shadow: 0 14px 28px rgb(11 18 44 / 20%);
}
.mc-model-btn:disabled {
  opacity: 0.7;
  cursor: wait;
}
.mc-grid {
  display: grid;
  grid-template-columns: minmax(280px, 320px) minmax(0, 1fr) minmax(280px, 360px);
  gap: 20px;
}
.mc-panel { padding: 22px; }
.mc-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}
.mc-panel-head h2 { margin: 0; font-size: 1.16rem; }
.mc-upload-form { display: grid; gap: 12px; }
.mc-upload-zone {
  display: grid;
  gap: 8px;
  padding: 18px;
  border-radius: 18px;
  border: 2px dashed #bfd3f4;
  background: linear-gradient(180deg, #f9fbff, #f3f7ff);
  cursor: pointer;
}
.mc-upload-zone input { margin-top: 6px; }
.mc-upload-title, .mc-block-title, .mc-preview-name { font-weight: 800; }
.mc-upload-subtitle, .mc-empty, .mc-status, .mc-preview-meta, .mc-tips { color: var(--mc-muted); }
.mc-primary-btn, .mc-ghost-btn {
  min-height: 46px;
  padding: 0 16px;
  border-radius: 14px;
  border: 0;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-weight: 800;
}
.mc-primary-btn {
  color: #fff;
  background: linear-gradient(135deg, var(--mc-accent), var(--mc-accent-strong));
  box-shadow: 0 16px 26px rgb(79 70 229 / 20%);
}
.mc-ghost-btn {
  background: #f2f6fb;
  color: var(--mc-text);
  border: 1px solid var(--mc-line);
}
.mc-file-list { display: grid; gap: 10px; margin-top: 12px; }
.mc-file-item {
  width: 100%;
  text-align: left;
  border: 1px solid var(--mc-line);
  background: #f7fafc;
  border-radius: 16px;
  padding: 12px 14px;
  cursor: pointer;
}
.mc-file-item.active {
  border-color: var(--mc-accent);
  box-shadow: 0 12px 24px rgb(79 70 229 / 12%);
}
.mc-file-row { display: flex; justify-content: space-between; gap: 12px; }
.mc-file-path { font-weight: 700; line-height: 1.5; word-break: break-all; }
.mc-file-meta { margin-top: 6px; font-size: 0.86rem; color: var(--mc-muted); }
.mc-quick-prompts { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 14px; }
.mc-quick-prompts button {
  border: 1px solid var(--mc-line);
  background: #fff;
  border-radius: 999px;
  padding: 10px 14px;
  cursor: pointer;
}
.mc-chat-log {
  min-height: 420px;
  max-height: 620px;
  overflow: auto;
  display: grid;
  gap: 12px;
}
.mc-chat-bubble {
  max-width: 88%;
  padding: 14px 16px;
  border-radius: 18px;
  line-height: 1.75;
  white-space: pre-wrap;
  word-break: break-word;
}
.mc-chat-bubble.user { margin-left: auto; background: #0e2b54; color: #fff; }
.mc-chat-bubble.assistant { background: #f4f8fc; border: 1px solid var(--mc-line); }
.mc-chat-bubble.system { max-width: 100%; background: #fff9e8; border: 1px solid #f3d99c; }
.mc-chat-form { margin-top: 14px; }
.mc-chat-form textarea {
  width: 100%;
  resize: vertical;
  min-height: 110px;
  border-radius: 18px;
  border: 1px solid var(--mc-line);
  padding: 14px 16px;
  font: inherit;
}
.mc-chat-actions {
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.mc-preview-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.mc-preview-body {
  border: 1px solid var(--mc-line);
  border-radius: 18px;
  background: #0d1728;
  color: #d7e4ff;
  min-height: 360px;
  max-height: 620px;
  overflow: auto;
}
.mc-preview-body pre {
  margin: 0;
  padding: 18px;
  white-space: pre-wrap;
  word-break: break-word;
  font-family: Consolas, Monaco, monospace;
  line-height: 1.7;
}
.mc-preview-image { width: 100%; display: block; border-radius: 18px; }
.mc-preview-frame {
  width: 100%;
  min-height: 560px;
  border: 0;
  background: #fff;
  border-radius: 18px;
}
.mc-binary-card { padding: 18px; color: var(--mc-text); background: #fff; }
@media (max-width: 1100px) {
  .mc-grid, .mc-hero-grid { grid-template-columns: 1fr; }
  .mc-chat-log, .mc-preview-body { max-height: none; }
}
@media (max-width: 720px) {
  .mc-header .mc-shell, .mc-panel-head, .mc-chat-actions, .mc-preview-head { flex-direction: column; align-items: stretch; }
  .mc-nav { gap: 14px; flex-wrap: wrap; }
  .mc-chat-bubble { max-width: 100%; }
  .mc-model-banner,
  .mc-model-card {
    margin-top: 16px;
  }
  .mc-model-switch {
    flex-direction: column;
  }
}