/* 通用组件细节复核：图标盒、对齐、状态色。 */
.cc-notice-action > .cc-icon,
.cc-notice-action > img,
.cc-alert > .cc-icon,
.cc-alert > img {
  width: 22px !important;
  height: 22px !important;
  flex: 0 0 22px;
  margin-left: -3px;
  margin-right: 1px;
  object-fit: contain;
}
.cc-alert:not(.title) > .cc-icon,
.cc-alert:not(.title) > img { align-self: center; }
.cc-alert.title > .cc-icon,
.cc-alert.title > img { align-self: flex-start; }
.cc-alert > div { min-width: 0; align-items: center; }
.cc-alert.title > div { align-items: start; }
.cc-notice-action.error > img { filter: hue-rotate(325deg) saturate(1.4); }
.cc-notice-action > button {
  flex: 0 0 auto;
  height: 22px;
  padding: 1px 8px;
  border: 1px solid currentColor;
  border-radius: 11px;
  line-height: 18px;
}
.cc-float-expanded button { padding: 0; overflow: visible; }
.cc-float-expanded .cc-icon { width: 22px !important; height: 22px !important; max-width: none; }
.cc-float-expanded button:first-child .cc-icon { transform: rotate(-90deg); }
.cc-alert.info > img,
.cc-notice-action.info > img {
  filter: brightness(0) saturate(100%) invert(48%) sepia(99%) saturate(2578%) hue-rotate(193deg) brightness(102%) contrast(101%);
}
.cc-alert.error > img,
.cc-notice-action.error > img {
  filter: brightness(0) saturate(100%) invert(38%) sepia(87%) saturate(1330%) hue-rotate(323deg) brightness(92%) contrast(95%);
}
.cc-pagination button:first-of-type,
.cc-pagination button:last-of-type {
  color: transparent;
  background-color: #fff;
  background-image: url("assets/icons/线性图标=箭头.svg");
  background-position: center;
  background-size: 12px 12px;
  background-repeat: no-repeat;
}
.cc-pagination button:first-of-type { transform: rotate(180deg); }

/* 页面框架调整：顶部工具栏固定，品牌名称加长后保持完整。 */
.topbar {
  position: sticky;
  z-index: 25;
  top: 0;
  flex: 0 0 auto;
  background: rgba(255,255,255,.98);
  backdrop-filter: blur(8px);
}
.brand-row > div:nth-child(2) { min-width: 0; }
.brand-row > div:nth-child(2) strong {
  display: block;
  overflow: hidden;
  font-size: 15px;
  line-height: 22px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 页面标题下方的小组件类型汇总。 */
.component-summary {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.component-summary[hidden] { display: none; }
.component-summary button {
  box-sizing: border-box;
  height: 28px;
  padding: 3px 10px;
  border: 1px solid #d9d9d9;
  border-radius: 4px;
  color: #666;
  background: #fff;
  font: 400 12px/20px "Source Han Sans CN", "思源黑体 CN", sans-serif;
  cursor: pointer;
}
.component-summary button:hover { color: #4ba2ff; border-color: #4ba2ff; background: rgba(75,162,255,.04); }
.component-summary button:active { color: #2279d6; border-color: #2279d6; }
.summary-located { animation: summary-located 1.4s ease; }
@keyframes summary-located {
  0%,45% { box-shadow: 0 0 0 3px rgba(41,144,255,.14); }
  100% { box-shadow: none; }
}

/* 每个组件分组独立的变量交互预览。 */
.cc-group-playground {
  box-sizing: border-box;
  width: 100%;
  margin-top: 14px;
  padding: 14px;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 12px;
  align-items: stretch;
  border: 1px solid #d9d9d9;
  border-radius: 6px;
  background: #fff;
}
.cc-group-control {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
  width: min(220px, 100%);
}
.cc-group-control label {
  color: #666;
  font: 400 12px/18px "Source Han Sans CN", "思源黑体 CN", sans-serif;
}
.cc-group-control select {
  box-sizing: border-box;
  width: 100%;
  height: 32px;
  padding: 5px 28px 5px 12px;
  border: 1px solid #d9d9d9;
  border-radius: 4px;
  color: #333;
  background: #fff;
  font: 400 14px/22px "Source Han Sans CN", "思源黑体 CN", sans-serif;
}
.cc-group-control select:hover { border-color: #4ba2ff; }
.cc-group-control select:focus { border-color: #2990ff; outline: 0; }
.cc-group-live { min-width: 0; }
.cc-group-live .cc-live-demo {
  min-height: 120px;
  padding: 20px;
  overflow: hidden;
  border-radius: 4px;
  background: #fafafa;
}
.cc-group-live .variant-code {
  box-sizing: border-box;
  width: 100%;
  margin: 8px 0 0;
  padding: 8px 10px;
  min-height: auto;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
@media (max-width: 760px) {
  .cc-group-playground { grid-template-columns: 1fr; }
}

/* 通用组件每段代码的快捷复制按钮。 */
.cc-code-box {
  position: relative;
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
}
.cc-code-box > code,
.cc-code-box > pre {
  box-sizing: border-box;
  width: 100%;
  min-height: 36px;
  margin: 0;
  padding: 8px 68px 8px 10px;
  display: block;
  overflow: hidden;
  border-radius: 4px;
  color: #d8e7ff;
  background: #111827;
  font: 10px/18px ui-monospace, SFMono-Regular, Consolas, monospace;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.cc-group-live .cc-code-box,
#ccLive .cc-code-box { margin-top: 8px; }
.cc-copy-code {
  position: absolute;
  top: 6px;
  right: 6px;
  box-sizing: border-box;
  min-width: 52px;
  height: 24px;
  padding: 2px 8px;
  border: 1px solid rgba(255,255,255,.22);
  border-radius: 4px;
  color: #d8e7ff;
  background: rgba(255,255,255,.08);
  font: 400 12px/18px "Source Han Sans CN", "思源黑体 CN", sans-serif;
  cursor: pointer;
}
.cc-copy-code:hover { color: #fff; border-color: #4ba2ff; background: rgba(75,162,255,.18); }
.cc-copy-code:active,
.cc-copy-code.copied { color: #fff; border-color: #2990ff; background: #2990ff; }
