:root {
    --bg: #f6f8fb;
    --surface: #ffffff;
    --surface-muted: #f8fafc;
    --text: #202633;
    --text-soft: #6e7687;
    --border: #e3e7ee;
    --primary: #2f6ff2;
    --primary-dark: #245fd8;
    --green: #15966f;
    --green-soft: #edf9f5;
    --orange: #b45309;
    --orange-soft: #fff7ed;
    --purple: #7e22ce;
    --purple-soft: #faf5ff;
    --danger: #b42318;
    --sidebar: #fbfcfe;
    --sidebar-soft: #f1f4f8;
    --shadow: 0 10px 30px rgba(27, 39, 62, 0.06);
}

.access-error-body {
    min-width: 320px;
    margin: 0;
    color: var(--text);
    background: var(--bg);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

.access-error-page {
    display: grid;
    min-height: 100vh;
    padding: 24px;
    place-items: center;
    box-sizing: border-box;
}

.access-error-card {
    width: min(430px, 100%);
    padding: 42px 36px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--surface);
    box-shadow: var(--shadow);
    text-align: center;
    box-sizing: border-box;
}

.access-error-card img { width: 52px; height: 52px; object-fit: contain; }
.access-error-card > span { display: block; margin-top: 18px; color: var(--primary); font-size: 12px; font-weight: 700; }
.access-error-card h1 { margin: 8px 0 0; font-size: 26px; }
.access-error-card p { margin: 12px 0 24px; color: var(--text-soft); font-size: 14px; line-height: 1.7; }
.access-error-card a { display: inline-flex; height: 40px; padding: 0 22px; align-items: center; justify-content: center; border-radius: 6px; color: #fff; background: var(--primary); font-size: 14px; text-decoration: none; }
.access-error-card a:hover { background: var(--primary-dark); }

/* Layui 与原生下拉统一为账户余额筛选控件的视觉规范。 */
body.admin-body select[lay-ignore] {
    height: 38px;
    padding: 0 34px 0 12px;
    border: 1px solid #d7deea;
    border-radius: 6px;
    outline: 0;
    color: #344054;
    background-color: #fff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'%3E%3Cpath d='m3.5 5.25 3.5 3.5 3.5-3.5' fill='none' stroke='%23667585' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 11px center;
    background-size: 14px 14px;
    box-sizing: border-box;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}

body.admin-body select[lay-ignore]:hover { border-color: #b9c6d8; }
body.admin-body select[lay-ignore]:focus { border-color: #4d7ff2; box-shadow: 0 0 0 3px rgba(47, 113, 244, .1); }
body.admin-body select[lay-ignore]:disabled { color: #98a2b1; background-color: #f4f6f8; cursor: not-allowed; }
.admin-body .layui-form select:not([lay-ignore]) { display: none !important; }
.admin-body .layui-form-select .layui-input { height: 38px; border-color: #d7deea; border-radius: 6px; color: #344054; }
.admin-body .layui-form-select:hover .layui-input { border-color: #b9c6d8; }
.admin-body .layui-form-select.layui-form-selected .layui-input { border-color: #4d7ff2; box-shadow: 0 0 0 3px rgba(47, 113, 244, .1); }
.admin-body .layui-form-select dl { border-color: #d7deea; border-radius: 6px; box-shadow: 0 10px 24px rgba(31, 45, 69, .12); }
.admin-body .layui-form-select dl dd { min-height: 36px; padding: 0 12px; line-height: 36px; }

/* 发布闭环、审核工作台、媒体渠道、智能创作与企业信息 */
.content-module-switch {
    display: inline-flex;
    min-height: 42px;
    margin-bottom: 14px;
    padding: 3px;
    gap: 3px;
    border: 1px solid #dfe5ee;
    border-radius: 6px;
    background: #eef1f5;
}

.content-module-switch button {
    display: inline-flex;
    min-width: 128px;
    height: 36px;
    padding: 0 18px;
    align-items: center;
    justify-content: center;
    gap: 7px;
    border: 0;
    border-radius: 4px;
    color: #627086;
    background: transparent;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.content-module-switch button.is-active {
    color: #1f57ca;
    background: #fff;
    box-shadow: 0 1px 4px rgba(27, 43, 72, .1);
}

.content-title-management { overflow: hidden; }
.content-title-heading {
    display: flex;
    min-height: 82px;
    padding: 18px 20px;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border-bottom: 1px solid var(--border);
}
.content-title-heading h2 { margin: 0; color: #1f2c42; font-size: 19px; }
.content-title-heading p { margin: 5px 0 0; color: #778398; font-size: 13px; }
.content-title-heading-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 8px; }
.content-title-source-tabs { padding: 0 16px; }
.filter-form.content-title-filter {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    padding: 14px 16px;
    border-bottom: 1px solid #edf0f5;
}
.content-title-filter > .search-field { width: 320px; min-width: 280px; flex: 0 1 320px; }
.content-title-filter > select + .layui-form-select { width: 150px; flex: 0 0 150px; }
.content-title-filter > #content-title-owner-filter + .layui-form-select { width: 180px; flex-basis: 180px; }
.content-title-filter-actions { display: flex; flex: 0 0 auto; align-items: center; gap: 8px; }
.filter-form.content-title-filter .content-title-filter-actions .layui-btn { width: auto; flex: 0 0 auto; margin: 0; }
.content-title-table { min-width: 1120px; }
.layui-layer-page.content-title-form-layer .layui-layer-content { height: 100%; overflow: hidden; }
.content-title-create-modal { height: 100%; max-width: 680px; padding: 26px 28px 20px; display: flex; overflow: hidden; flex-direction: column; box-sizing: border-box; }
.content-title-create-modal > header { display: flex; align-items: center; gap: 12px; }
.content-title-create-modal > header > span { display: inline-grid; width: 42px; height: 42px; flex: 0 0 auto; place-items: center; border-radius: 7px; color: #245fd8; background: #eaf1ff; font-size: 20px; }
.content-title-create-heading-copy { min-width: 0; flex: 1 1 auto; }
.content-title-create-modal .modal-header-close { flex: 0 0 auto; }
.content-title-create-modal h2 { margin: 0; color: #24324a; font-size: 18px; }
.content-title-create-modal header p { margin: 4px 0 0; color: #7b8799; font-size: 12px; }
.content-title-create-modal form { min-height: 0; display: grid; margin-top: 20px; padding-bottom: 8px; align-content: start; flex: 1; gap: 14px; overflow-y: auto; }
.content-title-create-modal .manual-field textarea { min-height: 140px; resize: vertical; }
.content-title-create-modal > .modal-actions { margin: 0 -28px -20px; padding: 12px 28px; flex: 0 0 auto; background: #fff; }
.layui-layer-page.article-generation-layer .layui-layer-content { height: 100%; overflow: hidden; }
.article-generation-layer .article-generation-modal { height: 100%; max-height: none; }
.article-generation-modal { display: flex; width: 100%; max-height: 84vh; padding: 22px 24px 18px; flex-direction: column; box-sizing: border-box; }
.article-generation-modal > header { display: flex; align-items: center; gap: 14px; }
.article-generation-modal > header > span { display: inline-grid; width: 48px; height: 48px; flex: 0 0 auto; place-items: center; border-radius: 50%; color: #2f6ff2; background: #eaf1ff; font-size: 22px; }
.article-generation-modal > header > div { min-width: 0; }
.article-generation-modal > header > span:not(.is-failed):not(.is-success) i { animation: studio-spin 1s linear infinite; }
.article-generation-modal > header > span.is-success { color: #1f8a68; background: #e8f7f1; }
.article-generation-modal > header > span.is-failed { color: #b42318; background: #fff0ef; }
.article-generation-modal h2 { margin: 0; color: #24324a; font-size: 19px; }
.article-generation-modal header p { margin: 5px 0 0; color: #78859a; font-size: 12px; line-height: 1.55; }
.article-generation-modal-close,
.modal-header-close { display: inline-grid; width: 34px; height: 34px; margin-left: auto; padding: 0; flex: 0 0 auto; place-items: center; align-self: flex-start; border: 1px solid #dce3ed; border-radius: 8px; color: #66758a; background: #fff; font-size: 16px; cursor: pointer; transition: border-color .16s ease, color .16s ease, background-color .16s ease; }
.article-generation-modal-close:hover,
.modal-header-close:hover { border-color: #aebdd2; color: #245fd8; background: #f5f8ff; }
.article-generation-modal-close:focus-visible,
.modal-header-close:focus-visible { outline: 2px solid rgba(47, 111, 242, .22); outline-offset: 2px; }
.article-generation-batch { display: flex; min-height: 38px; margin-top: 16px; padding: 7px 9px 7px 12px; align-items: center; gap: 10px; border: 1px solid #e2e7ef; border-radius: 7px; background: #f8fafc; box-sizing: border-box; }
.article-generation-batch > span { flex: 0 0 auto; color: #768297; font-size: 11px; }
.article-generation-batch code { min-width: 0; flex: 1 1 auto; overflow: hidden; color: #344054; font: 11px/1.5 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; text-overflow: ellipsis; white-space: nowrap; user-select: all; }
.article-generation-batch button { display: inline-flex; height: 26px; padding: 0 9px; align-items: center; gap: 5px; flex: 0 0 auto; border: 1px solid #cfd8e6; border-radius: 5px; color: #245fd8; background: #fff; font-size: 10px; cursor: pointer; }
.article-generation-batch button:hover { border-color: #8ea9d6; background: #f3f7ff; }
.article-generation-progress { display: flex; margin: 16px 0 12px; flex-direction: column; gap: 8px; }
.article-generation-progress > i { height: 8px; overflow: hidden; border-radius: 4px; background: #e8edf5; }
.article-generation-progress > i > b { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #2f6ff2, #6a91f7); transition: width .3s ease; }
.article-generation-progress > small { color: #7d899b; font-size: 11px; }
.article-generation-task-list { display: grid; min-height: 0; max-height: min(46vh, 480px); margin: 0; padding: 0 4px 0 0; gap: 8px; overflow-y: auto; overscroll-behavior: contain; list-style: none; }
.article-generation-layer .article-generation-task-list { min-height: 140px; max-height: none; flex: 1 1 auto; align-content: start; }
.article-generation-task-list li { display: grid; min-height: 58px; padding: 10px 12px; grid-template-columns: 34px minmax(0, 1fr) auto auto; align-items: center; gap: 10px; border: 1px solid #e1e6ee; border-radius: 7px; background: #fff; }
.article-generation-task-list li > b { display: inline-grid; width: 30px; height: 30px; place-items: center; border-radius: 5px; color: #2f6ff2; background: #eef3ff; font-size: 10px; }
.article-generation-task-list li > div { min-width: 0; }
.article-generation-task-list li strong,
.article-generation-task-list li small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.article-generation-task-list li strong { color: #344054; font-size: 13px; }
.article-generation-task-list li small { margin-top: 4px; color: #7f8a9c; font-size: 11px; }
.article-generation-task-status { padding: 3px 8px; border-radius: 10px; color: #68758a; background: #eef1f5; font-size: 10px; white-space: nowrap; }
.article-generation-task-status.status-1 { color: #245fd8; background: #eaf1ff; }
.article-generation-task-status.status-2 { color: #26745c; background: #e9f6f1; }
.article-generation-task-status.status-3 { color: #b42318; background: #fff0ef; }
.article-generation-modal > footer { margin-top: 14px; flex: 0 0 auto; }
@media (max-width: 760px) {
    .article-generation-modal { max-height: 90vh; padding: 18px 16px 14px; }
    .article-generation-layer .article-generation-modal { max-height: none; }
    .article-generation-modal > header { align-items: flex-start; }
    .article-generation-modal > header > span { width: 42px; height: 42px; font-size: 19px; }
    .article-generation-modal h2 { font-size: 17px; }
    .article-generation-task-list { max-height: 48vh; }
    .article-generation-layer .article-generation-task-list { min-height: 100px; max-height: none; }
    .article-generation-task-list li { grid-template-columns: 30px minmax(0, 1fr) auto; }
    .article-generation-task-list li > button { grid-column: 2 / -1; justify-self: start; }
    .article-generation-batch { flex-wrap: wrap; }
    .article-generation-batch code { order: 3; flex-basis: 100%; }
}
.table-muted { color: #98a2b3; font-size: 12px; }
.content-title-table td > strong,
.content-title-table td > small,
.publish-record-table td > strong,
.publish-record-table td > small,
.publish-review-table td > strong,
.publish-review-table td > small { display: block; }
.content-title-table td > strong,
.publish-record-table td > strong,
.publish-review-table td > strong { color: #26364f; font-size: 13px; }
.content-title-table td > small,
.publish-record-table td > small,
.publish-review-table td > small { margin-top: 4px; color: #8792a4; font-size: 12px; line-height: 1.45; }
.content-select-column { width: 42px; text-align: center; }
.content-select-column input,
.content-management-table td:first-child input { width: 16px; height: 16px; accent-color: var(--primary); }

.publish-stepper {
    display: flex;
    max-width: 760px;
    margin: 0 auto 18px;
    align-items: center;
    justify-content: center;
}
.publish-stepper > span { display: inline-flex; align-items: center; gap: 8px; color: #8792a5; font-size: 14px; font-weight: 600; white-space: nowrap; }
.publish-stepper > span b { display: inline-grid; width: 28px; height: 28px; place-items: center; border: 1px solid #d6dde8; border-radius: 50%; color: #7c8799; background: #fff; font-size: 12px; }
.publish-stepper > span.is-active { color: #245fd8; }
.publish-stepper > span.is-active b { border-color: var(--primary); color: #fff; background: var(--primary); }
.publish-stepper > span.is-complete { color: #168365; }
.publish-stepper > span.is-complete b { border-color: #168365; color: #fff; background: #168365; }
.publish-stepper > i { width: 90px; height: 1px; margin: 0 14px; background: #dfe4ec; }

.publish-layout { display: grid; grid-template-columns: minmax(0, 1fr) 310px; align-items: start; gap: 16px; }
.publish-workflow { display: grid; min-width: 0; gap: 16px; }
.publish-section { overflow: hidden; }
.publish-section.is-validation-attention,
.publish-summary-panel.is-validation-attention { animation: publish-validation-attention 1.6s ease; }
@keyframes publish-validation-attention {
    0%, 100% { border-color: #e4e9f0; box-shadow: none; }
    24%, 72% { border-color: #f0ae45; box-shadow: 0 0 0 4px rgba(245, 158, 11, .16); }
}
.publish-section-heading {
    display: flex;
    min-height: 76px;
    padding: 16px 18px;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid #e7ebf1;
}
.publish-section-heading > div { display: flex; align-items: center; gap: 12px; }
.publish-section-heading > div > span { display: inline-grid; width: 32px; height: 32px; place-items: center; border-radius: 6px; color: #245fd8; background: #eaf1ff; font-size: 14px; font-weight: 700; }
.publish-section-heading h2 { margin: 0; color: #233149; font-size: 17px; }
.publish-section-heading p { margin: 4px 0 0; color: #7e899b; font-size: 12px; }
.publish-section-heading > strong { color: #2f6ff2; font-size: 13px; white-space: nowrap; }
.publish-article-toolbar { display: flex; min-height: 62px; padding: 10px 16px; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid #edf0f4; background: #fbfcfe; }
.publish-article-search { display: grid; grid-template-columns: minmax(260px, 420px) max-content max-content; gap: 8px; }
.publish-article-search label,
.publish-target-filter label { position: relative; }
.publish-article-search label i,
.publish-target-filter label i { position: absolute; top: 12px; left: 12px; z-index: 1; color: #8793a5; }
.publish-article-search input,
.publish-target-filter input { padding-left: 36px; }
.publish-article-toolbar > div { display: flex; align-items: center; gap: 9px; color: #7b8799; font-size: 11px; white-space: nowrap; }
.publish-article-toolbar .layui-btn { margin: 0; }
.publish-article-list { position: relative; max-height: 430px; overflow: auto; scrollbar-color: #cbd4e1 transparent; scrollbar-width: thin; }
.publish-article-list:focus-visible { outline: 2px solid rgba(47, 111, 242, .28); outline-offset: -2px; }
.publish-article-table-head,
.publish-article-option {
    display: grid;
    min-width: 620px;
    grid-template-columns: 22px minmax(260px, 1fr) 112px 92px;
    align-items: center;
    gap: 12px;
}
.publish-article-table-head { position: sticky; top: 0; z-index: 2; min-height: 40px; padding: 0 16px; border-bottom: 1px solid #e4e9f0; color: #6f7d91; background: #f7f9fc; font-size: 11px; font-weight: 700; box-sizing: border-box; }
.publish-article-rows { min-width: 620px; }
.publish-article-option {
    min-height: 52px;
    padding: 0 16px;
    border-bottom: 1px solid #edf0f4;
    background: #fff;
    box-sizing: border-box;
    cursor: pointer;
    transition: background .16s ease, box-shadow .16s ease;
}
.publish-article-option:hover { background: #f8faff; }
.publish-article-option.is-selected { background: #f2f6ff; box-shadow: inset 3px 0 #2f6ff2; }
.publish-article-option.is-disabled { color: #98a2b1; background: #f8f9fb; cursor: not-allowed; }
.publish-article-option.is-disabled:hover { background: #f8f9fb; }
.publish-article-option.is-disabled .publish-check { border-color: #dce2ea; background: #f0f2f5; }
.publish-article-option.is-disabled strong,
.publish-article-option.is-disabled .publish-article-mode { color: #98a2b1; }
.publish-article-option input { position: absolute; opacity: 0; pointer-events: none; }
.publish-check { display: inline-grid; width: 20px; height: 20px; place-items: center; border: 1px solid #cbd3df; border-radius: 4px; color: transparent; background: #fff; }
.publish-article-option.is-selected .publish-check { border-color: var(--primary); color: #fff; background: var(--primary); }
.publish-article-title-cell { min-width: 0; }
.publish-article-option strong { display: block; overflow: hidden; color: #26354d; font-size: 13px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.publish-article-mode { color: #65748a; font-size: 12px; }
.publish-article-option .status-badge { width: max-content; }
.publish-article-load-state { display: flex; min-height: 44px; padding: 0 16px; align-items: center; justify-content: center; gap: 10px; color: #8290a3; background: #fbfcfe; font-size: 11px; box-sizing: border-box; }
.publish-article-load-state[hidden] { display: none; }
.publish-article-load-state .layui-btn { margin: 0; }
.publish-article-load-state .layui-btn[hidden] { display: none; }
.publish-empty-state { display: flex; min-height: 210px; align-items: center; justify-content: center; flex-direction: column; gap: 10px; color: #8290a4; text-align: center; }
.publish-empty-state > i { font-size: 32px; }
.publish-empty-state strong { color: #34435b; font-size: 16px; }

.publish-selected-target-groups { display: grid; padding: 12px 16px; gap: 9px; border-bottom: 1px solid #e7ece9; background: #f4faf7; }
.publish-selected-target-groups section { display: grid; grid-template-columns: minmax(150px, 220px) minmax(0, 1fr); align-items: start; gap: 10px; }
.publish-selected-target-groups strong { padding-top: 5px; color: #286253; font-size: 12px; }
.publish-selected-target-groups section > div { display: flex; gap: 6px; flex-wrap: wrap; }
.publish-selected-target-groups button { min-height: 27px; padding: 4px 9px; border: 1px solid #bcded3; border-radius: 14px; color: #246a56; background: #fff; font-size: 11px; cursor: pointer; }
.publish-target-filter { display: grid; padding: 12px 16px; grid-template-columns: minmax(220px, 360px) 150px 170px max-content max-content; gap: 8px; border-bottom: 1px solid #edf0f4; background: #fbfcfe; }
.publish-target-filter select { width: 100%; height: 38px; padding: 0 9px; border: 1px solid #d9e0e9; border-radius: 4px; color: #4f5d72; background: #fff; }
.publish-target-filter .layui-btn { margin: 0; }
.publish-target-table-wrap { overflow-x: auto; scrollbar-color: #cbd4e1 transparent; scrollbar-width: thin; }
.publish-target-table-head,
.publish-target-row { display: grid; min-width: 960px; grid-template-columns: 20px minmax(160px, 190px) 126px 108px 110px minmax(150px, 1fr) 174px; align-items: center; gap: 8px; }
.publish-target-table-head { min-height: 40px; padding: 0 12px; border-bottom: 1px solid #e4e9f0; color: #6f7d91; background: #f7f9fc; font-size: 11px; font-weight: 700; box-sizing: border-box; }
.publish-target-list { display: grid; min-width: 960px; }
.publish-target-row { min-height: 72px; padding: 8px 12px; border: 0; border-bottom: 1px solid #edf0f4; color: inherit; background: #fff; text-align: left; box-sizing: border-box; cursor: pointer; }
.publish-target-row:last-child { border-bottom: 0; }
.publish-target-row:hover { background: #f8fafc; }
.publish-target-row:focus-visible { outline: 2px solid rgba(47, 111, 242, .32); outline-offset: -2px; }
.publish-target-row.is-selected { background: #f3f8f6; box-shadow: inset 3px 0 #15966f; }
.publish-target-row.is-selected > .publish-check { border-color: #15966f; color: #fff; background: #15966f; }
.publish-target-row.is-disabled { color: #98a2b1; background: #f8f9fb; cursor: not-allowed; }
.publish-target-row.is-disabled:hover { background: #f8f9fb; }
.publish-target-row.is-disabled > .publish-check { border-color: #dce2ea; color: transparent; background: #f0f2f5; }
.publish-target-row.is-disabled strong,
.publish-target-row.is-disabled b,
.publish-target-row.is-disabled .publish-target-board,
.publish-target-row.is-disabled .publish-target-description,
.publish-target-row.is-disabled .publish-target-rating { color: #98a2b1; }
.publish-target-row strong { overflow: hidden; color: #27364e; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.publish-target-row strong.publish-target-name { display: flex; min-width: 0; overflow: visible; align-items: center; }
.publish-target-name-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.publish-exclusive-badge {
    display: inline-flex;
    min-width: 30px;
    height: 18px;
    margin-left: 5px;
    padding: 0 5px;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    border: 1px solid #f1d38c;
    border-radius: 9px;
    color: #9a6100;
    background: #fff7df;
    box-sizing: border-box;
    font-size: 9px;
    font-weight: 700;
    line-height: 16px;
    cursor: default;
}
.publish-target-board,
.publish-target-description { overflow: hidden; color: #69778b; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.publish-target-description { display: -webkit-box; color: #7a8799; font-size: 11px; line-height: 1.55; white-space: normal; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.publish-target-row b { min-width: 0; overflow: hidden; color: #8e4d0e; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.publish-target-rating { min-width: 0; overflow: hidden; color: #f59e0b; font-size: 15px; letter-spacing: 1px; white-space: nowrap; }
.publish-target-schedule { display: grid; min-width: 0; gap: 3px; cursor: pointer; }
.publish-target-schedule-control { position: relative; display: block; min-width: 0; }
.publish-target-schedule input { width: 100%; height: 34px; padding: 0 32px 0 9px; border: 1px solid #d7dee8; border-radius: 6px; color: #344258; background: #fff; box-sizing: border-box; font-size: 11px; outline: 0; cursor: pointer; }
.publish-target-schedule-control > i { position: absolute; top: 50%; right: 10px; color: #8491a5; font-size: 15px; pointer-events: none; transform: translateY(-50%); }
.publish-target-schedule input:focus { border-color: #6f9af5; box-shadow: 0 0 0 3px rgba(47, 111, 242, .09); }
.publish-target-schedule input:focus + i { color: #2f6ff2; }
.publish-target-schedule input:disabled { color: #98a2b1; background: #f2f4f7; pointer-events: none; }
.publish-target-schedule input:disabled + i { color: #a7b0bd; }
.publish-target-schedule small { overflow: hidden; color: #8a96a7; font-size: 10px; line-height: 1.2; text-overflow: ellipsis; white-space: nowrap; }

.layui-laydate.geo-schedule-picker { margin-top: 8px; overflow: hidden; border: 1px solid #dce3ee; border-radius: 10px; color: #425169; box-shadow: 0 14px 36px rgba(28, 44, 76, .18); animation-duration: .16s; }
.geo-schedule-picker .layui-laydate-main { width: 304px; }
.geo-schedule-picker .layui-laydate-header { padding: 13px 70px 8px; border-bottom-color: #edf0f5; background: #fafbfe; line-height: 32px; }
.geo-schedule-picker .layui-laydate-header i { top: 13px; color: #75839a; }
.geo-schedule-picker .layui-laydate-header i:hover,
.geo-schedule-picker .layui-laydate-header span:hover { color: #2f6ff2; }
.geo-schedule-picker .laydate-set-ym { color: #27364e; font-weight: 700; }
.geo-schedule-picker .layui-laydate-content { padding: 11px 14px 13px; }
.geo-schedule-picker .layui-laydate-content table { width: 100%; }
.geo-schedule-picker .layui-laydate-content th { color: #8a96a7; font-size: 12px; }
.geo-schedule-picker .layui-laydate-content td { height: 34px; border-radius: 6px; color: #425169; }
.geo-schedule-picker .layui-laydate-content td:hover,
.geo-schedule-picker .layui-laydate-list li:hover { color: #2f6ff2; background: #edf3ff; }
.geo-schedule-picker .layui-laydate-content .laydate-day-prev,
.geo-schedule-picker .layui-laydate-content .laydate-day-next { color: #b2bbc8; }
.layui-laydate.geo-schedule-picker .layui-this { border-radius: 6px; background: #2f6ff2 !important; }
.geo-schedule-picker .layui-laydate-footer { height: 50px; padding: 11px 14px; border-top-color: #edf0f5; background: #fafbfe; }
.geo-schedule-picker .layui-laydate-footer span { color: #66758b; }
.geo-schedule-picker .layui-laydate-footer span:hover,
.geo-schedule-picker .layui-laydate-footer span[lay-type=date] { color: #2f6ff2; }
.geo-schedule-picker .laydate-footer-btns { top: 11px; right: 14px; }
.geo-schedule-picker .laydate-footer-btns span { height: 28px; margin-left: 6px; padding: 0 11px; border-color: #d5dce7; border-radius: 5px; line-height: 28px; }
.geo-schedule-picker .laydate-footer-btns .laydate-btns-confirm { border-color: #2f6ff2; color: #fff; background: #2f6ff2; }
.geo-schedule-picker .laydate-time-list li ol { border-color: #e6eaf0; }
.geo-schedule-picker .laydate-time-list ol li { padding-left: 30px; color: #59677d; }
.publish-target-grid { display: grid; padding: 14px 16px 18px; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.publish-target-option {
    display: grid;
    min-height: 90px;
    padding: 13px;
    grid-template-columns: 40px minmax(0, 1fr) auto;
    align-items: center;
    gap: 11px;
    border: 1px solid #dfe4ec;
    border-radius: 6px;
    color: inherit;
    background: #fff;
    text-align: left;
    cursor: pointer;
    transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.publish-target-option:hover:not(.is-locked) { border-color: #87aaf2; box-shadow: 0 7px 18px rgba(40, 76, 145, .08); transform: translateY(-1px); }
.publish-target-option.is-selected { border-color: #4e84ef; background: #f3f7ff; box-shadow: inset 3px 0 #2f6ff2; }
.publish-target-option.is-locked { color: #9099a8; background: #f5f6f8; cursor: not-allowed; }
.publish-target-icon { display: inline-grid; width: 40px; height: 40px; place-items: center; border-radius: 6px; color: #2f6ff2; background: #edf3ff; font-size: 18px; }
.publish-target-option.is-locked .publish-target-icon { color: #8f98a7; background: #e8ebef; }
.publish-target-option > span:nth-child(2) { display: flex; min-width: 0; flex-direction: column; gap: 4px; }
.publish-target-option strong { color: #27364e; font-size: 13px; line-height: 1.45; }
.publish-target-option small { color: #7f8b9e; font-size: 11px; }
.publish-target-option em { color: #2f6ff2; font-size: 11px; font-style: normal; white-space: nowrap; }
.publish-target-option.is-locked em { color: #8e97a6; }

.publish-summary-panel { position: sticky; top: 78px; padding: 18px; }
.publish-summary-panel > header { display: flex; align-items: center; justify-content: space-between; }
.publish-summary-panel h2 { margin: 0; color: #26344b; font-size: 17px; }
.publish-summary-panel dl { margin: 17px 0 0; }
.publish-summary-panel dl div { display: flex; min-height: 42px; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid #edf0f4; }
.publish-summary-panel dl div[hidden] { display: none; }
.publish-summary-panel dt { color: #798598; font-size: 12px; }
.publish-summary-panel dd { margin: 0; color: #2b3a52; font-size: 14px; font-weight: 700; }
.publish-summary-panel #publish-summary-quota-row { gap: 8px; }
.publish-summary-panel #publish-summary-quota-row dt { flex: 0 0 auto; white-space: nowrap; }
.publish-summary-panel #publish-summary-quota { font-size: 11px; font-weight: 600; line-height: 1.35; white-space: nowrap; }
.publish-summary-panel dd.is-amount { color: #a5520b; font-size: 20px; }
.publish-summary-note { display: flex; margin: 16px 0; padding: 11px; gap: 9px; color: #5c6b80; background: #f4f6f9; font-size: 12px; line-height: 1.6; }
.publish-summary-note i { color: #2f6ff2; }
.publish-summary-panel > button { width: 100%; }
.publish-summary-panel > button.is-validation-required { cursor: pointer; }
.publish-summary-panel > p { margin: 10px 0 0; color: #8893a5; font-size: 11px; text-align: center; }

.publish-records-panel,
.publish-review-panel { overflow: hidden; }
.publish-record-filter,
.publish-review-panel > .filter-form { padding: 14px 16px; border-bottom: 1px solid #edf0f5; }
.filter-form.publish-record-filter { display: flex; flex-wrap: wrap; justify-content: flex-start; gap: 10px; }
.publish-record-filter > .search-field { width: 360px; min-width: 280px; flex: 0 1 360px; }
.publish-record-filter > .compact-filter-input { width: 170px; max-width: 170px; flex: 0 0 170px; }
.publish-record-filter > .filter-select { width: 160px; flex: 0 0 160px; }
.publish-record-filter > .filter-select + .layui-form-select { width: 160px; flex: 0 0 160px; }
.filter-form.publish-record-filter .layui-btn { width: auto; margin: 0; }
.compact-filter-input { max-width: 160px; }
.publish-record-table { min-width: 1060px; }
.publish-record-table .publish-record-batch-column { width: 190px; }
.publish-record-table .publish-record-owner-column { width: 150px; }
.publish-record-table .publish-record-content-column { min-width: 250px; }
.publish-record-table .publish-record-channel-column { min-width: 270px; }
.publish-record-table .publish-record-amount-column { width: 125px; }
.publish-record-table .publish-record-status-column { width: 90px; }
.publish-record-table .publish-record-time-column { width: 145px; }
.publish-record-table .publish-record-action-column { width: 72px; }
.publish-record-channels { display: flex; align-items: flex-start; gap: 5px; flex-wrap: wrap; }
.publish-record-channels span,
.publish-record-channels a { display: inline-flex; min-height: 24px; padding: 3px 8px; align-items: center; border-radius: 4px; color: #53647d; background: #f1f4f8; font-size: 12px; line-height: 1.45; text-decoration: none; }
.publish-record-channels a { color: #245fd8; background: #edf3ff; box-shadow: inset 0 0 0 1px #d8e5ff; }
.publish-record-channels a:hover { color: #174eae; background: #e2ecff; }
.publish-record-view-button { min-width: 58px; margin: 0; }
.publish-review-table { min-width: 1180px; }
.publish-record-layer .layui-layer-content { height: 100%; overflow: hidden; }
.publish-record-detail { display: flex; height: 100%; max-height: none; padding: 22px 24px 18px; overflow: hidden; flex-direction: column; box-sizing: border-box; background: #fff; }
.publish-record-detail-scroll { min-height: 0; margin-right: -10px; padding-right: 10px; flex: 1 1 auto; overflow-x: hidden; overflow-y: auto; }
.publish-review-detail { min-height: 100%; padding: 22px 24px 18px; box-sizing: border-box; background: #f7f9fc; }
.publish-record-detail-heading,
.publish-review-detail-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.publish-record-detail-heading-actions,
.publish-review-detail-heading-actions { display: flex; align-items: flex-start; gap: 10px; }
.publish-review-detail-heading-actions { flex: 0 0 auto; }
.publish-review-detail-heading-actions .modal-header-close { margin-left: 0; }
.publish-record-detail-heading small,
.publish-review-detail-heading small { color: #6d7f9a; font-size: 12px; }
.publish-record-detail-heading h2,
.publish-review-detail-heading h2 { margin: 6px 0 5px; color: #1c2940; font-size: 22px; }
.publish-record-detail-heading p,
.publish-review-detail-heading p { margin: 0; color: #748095; font-size: 13px; }
.publish-detail-summary { display: grid; margin: 18px 0; grid-template-columns: repeat(5, minmax(0, 1fr)); border: 1px solid #e0e5ed; border-radius: 6px; background: #fff; }
.publish-detail-summary div { min-width: 0; padding: 12px 14px; border-right: 1px solid #e8ebf0; }
.publish-detail-summary div:last-child { border-right: 0; }
.publish-detail-summary dt { color: #8490a3; font-size: 11px; }
.publish-detail-summary dd { margin: 5px 0 0; color: #2a3950; font-size: 13px; font-weight: 700; line-height: 1.45; }
.detail-section-heading { display: flex; min-height: 50px; align-items: center; justify-content: space-between; gap: 12px; }
.detail-section-heading h3 { margin: 0; color: #26354d; font-size: 15px; }
.detail-section-heading span { color: #8792a4; font-size: 11px; }
.publish-item-detail-list { display: grid; gap: 12px; }
.publish-article-detail-group { overflow: hidden; border: 1px solid #e0e5ed; border-radius: 6px; background: #fff; }
.publish-article-detail-group > header { display: flex; min-height: 54px; padding: 10px 14px; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid #e0e5ed; background: #f7f9fc; box-sizing: border-box; }
.publish-article-detail-group > header > div { display: flex; min-width: 0; flex-direction: column; gap: 3px; }
.publish-article-detail-group > header small { color: #2f6ff2; font-size: 10px; font-weight: 600; }
.publish-article-detail-group > header strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.publish-article-detail-group > header > span { flex: 0 0 auto; color: #68778d; font-size: 11px; }
.publish-channel-detail-list > article { display: flex; min-height: 66px; padding: 10px 14px; align-items: center; justify-content: space-between; gap: 18px; border-bottom: 1px solid #edf0f4; }
.publish-channel-detail-list > article:last-child { border-bottom: 0; }
.publish-channel-detail-list > article > div:first-child { display: flex; min-width: 0; flex-direction: column; gap: 5px; }
.publish-item-detail-list strong { color: #2b3a52; font-size: 13px; }
.publish-item-detail-list span { overflow: hidden; color: #7f8a9c; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.publish-item-result { display: flex; max-width: 45%; align-items: center; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
.publish-item-billing { white-space: nowrap; }
.publish-item-billing.is-exclusive-quota { padding: 4px 8px; border-radius: 999px; color: #8a5a00; background: #fff5d6; font-size: 12px; }
.publish-item-result a { color: #2f6ff2; font-size: 12px; }
.publish-item-result small { width: 100%; color: #b42318; font-size: 11px; text-align: right; }
.publish-item-result small.publish-item-schedule { color: #667085; }
.publish-item-result small.publish-item-external-id { color: #667085; }
.publish-record-detail .modal-actions { margin: 16px -24px -18px; padding: 12px 24px; flex: 0 0 auto; border-top: 1px solid #edf0f4; background: #fff; }
.publish-review-timeline { display: grid; padding: 4px 0; }
.publish-review-timeline > article { display: grid; min-height: 58px; grid-template-columns: 14px minmax(0, 1fr) auto; gap: 10px; align-items: start; }
.publish-review-timeline > article > i { width: 9px; height: 9px; margin-top: 5px; border: 2px solid #9bb8f4; border-radius: 50%; background: #fff; box-sizing: border-box; }
.publish-review-timeline > article > div { display: flex; flex-direction: column; gap: 4px; }
.publish-review-timeline strong { color: #2b3a52; font-size: 13px; }
.publish-review-timeline span,
.publish-review-timeline time { color: #8490a2; font-size: 11px; }
.publish-review-timeline small { color: #63728a; font-size: 11px; line-height: 1.55; }
.publish-review-timeline .publish-review-targets { color: #4f6078; }
.publish-review-timeline .publish-review-note { color: #8a5a00; }

.review-safety-notice { border-color: #f0d7b5; background: #fff9f0; }
.review-safety-notice > i,
.review-safety-notice strong { color: #a5540c; }
.review-detail-layout { display: grid; margin-top: 18px; grid-template-columns: minmax(0, 1fr) 360px; gap: 16px; }
.review-content-pane,
.review-target-pane,
.review-history-section,
.review-decision-section { border: 1px solid #e0e5ed; border-radius: 6px; background: #fff; }
.review-content-pane > header,
.review-target-pane > header,
.review-history-section > header { padding: 8px 14px; border-bottom: 1px solid #edf0f4; }
.review-target-selection-toolbar { display: flex; align-items: center; justify-content: flex-end; gap: 7px; }
.review-target-selection-toolbar[hidden] { display: none; }
.review-target-selection-toolbar span { color: #55657b; font-size: 10px; white-space: nowrap; }
.review-target-selection-toolbar button { height: 27px; padding: 0 9px; border: 1px solid #9db6e9; border-radius: 5px; color: #245fd8; background: #f3f7ff; font-size: 10px; cursor: pointer; white-space: nowrap; }
.review-target-selection-toolbar button:hover { border-color: #2f6ff2; background: #eaf1ff; }
.review-article-tabs { display: flex; align-items: center; justify-content: flex-end; gap: 7px; flex-wrap: wrap; }
.review-article-tabs-label { color: #66748a; font-size: 12px; font-weight: 600; }
.review-article-tabs button { display: inline-flex; min-width: 76px; height: 32px; padding: 0 12px; align-items: center; justify-content: center; border: 1px solid #8eabdf; border-radius: 5px; color: #245fd8; background: #edf3ff; box-shadow: 0 2px 6px rgba(47, 111, 242, .1); font-size: 12px; font-weight: 600; cursor: pointer; }
.review-article-tabs button:hover { border-color: #2f6ff2; background: #e3edff; }
.review-article-tabs button.is-read { border-color: #83c4b1; color: #17755c; background: #edf8f4; }
.review-article-tabs button.is-active { border-color: #2f6ff2; color: #fff; background: #2f6ff2; }
.review-article-preview { padding: 16px; }
.review-article-preview h4 { margin: 0 0 12px; color: #1f2c42; font-size: 18px; line-height: 1.5; }
.review-article-meta { display: grid; margin: 0 0 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px 15px; }
.review-article-meta div { display: grid; grid-template-columns: 58px minmax(0, 1fr); gap: 7px; }
.review-article-meta div:last-child { grid-column: 1 / -1; }
.review-article-meta dt { color: #8a95a6; font-size: 11px; }
.review-article-meta dd { margin: 0; color: #4c5a70; font-size: 12px; line-height: 1.5; }
.review-knowledge-basis { display: flex; margin-bottom: 14px; padding: 10px 12px; gap: 9px; align-items: center; color: #285d4c; background: #eff8f4; }
.review-knowledge-basis > i { font-size: 18px; }
.review-knowledge-basis > div { display: flex; flex-direction: column; gap: 3px; }
.review-knowledge-basis strong { font-size: 12px; }
.review-knowledge-basis span { color: #618176; font-size: 11px; }
.review-article-body { max-height: 450px; overflow: auto; color: #303b4d; font-size: 15px; line-height: 1.85; }
.review-article-body img { max-width: 100%; height: auto; }
.review-article-body table { max-width: 100%; border-collapse: collapse; }
.review-article-body td,
.review-article-body th { padding: 6px; border: 1px solid #dfe4eb; }
.review-target-list { display: grid; max-height: 440px; overflow: auto; }
.review-destination-group { border-bottom: 1px solid #e5e9ef; }
.review-destination-group:last-child { border-bottom: 0; }
.review-destination-group > header { display: flex; min-height: 38px; padding: 7px 14px; align-items: center; justify-content: space-between; gap: 10px; background: #f4f8f6; }
.review-destination-group > header strong { color: #286253; font-size: 12px; }
.review-destination-group > header span { color: #799087; font-size: 10px; }
.review-destination-group > div > article { display: flex; min-height: 78px; padding: 11px 14px; align-items: flex-start; justify-content: space-between; gap: 12px; border-top: 1px solid #edf0f4; }
.review-destination-group > div > article.has-selection-control { display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; align-items: center; }
.review-destination-group > div > article.is-selectable { cursor: pointer; transition: background-color .16s ease, box-shadow .16s ease; }
.review-destination-group > div > article.is-selectable:hover { background: #f7f9fd; }
.review-destination-group > div > article.is-selectable:focus-visible { outline: 2px solid rgba(47, 111, 242, .45); outline-offset: -2px; }
.review-destination-group > div > article.is-selected { background: #eef5ff; box-shadow: inset 3px 0 #2f6ff2; }
.review-target-check { display: inline-flex; width: 18px; height: 18px; align-items: center; justify-content: center; border: 1px solid #bdc7d5; border-radius: 4px; color: transparent; background: #fff; box-sizing: border-box; }
.review-target-check i { font-size: 12px; }
.review-destination-group > div > article.is-selected .review-target-check { border-color: #2f6ff2; color: #fff; background: #2f6ff2; }
.review-target-check.is-locked { border-color: #d6dce5; color: #8d98a8; background: #f2f4f7; cursor: not-allowed; }
.review-destination-group > div > article.is-reviewed { background: #fafbfc; }
.review-destination-group > div > article > div { display: flex; min-width: 0; flex-direction: column; gap: 5px; }
.review-destination-group > div > article > div:first-child strong,
.review-destination-group > div > article.has-selection-control > div:nth-child(2) strong { color: #29384f; font-size: 12px; }
.review-destination-group > div > article > div:first-child span,
.review-destination-group > div > article.has-selection-control > div:nth-child(2) span { color: #8792a3; font-size: 11px; line-height: 1.45; }
.review-destination-group > div > article > div:last-child { align-items: flex-end; white-space: nowrap; }
.review-target-list b { color: #8d4b0d; font-size: 12px; }
.review-target-list small { color: #8792a3; font-size: 10px; }
.review-amount-summary { margin: 0; padding: 10px 14px; background: #f8fafc; }
.review-amount-summary div { display: flex; min-height: 30px; align-items: center; justify-content: space-between; }
.review-amount-summary dt { color: #778397; font-size: 11px; }
.review-amount-summary dd { margin: 0; color: #27364e; font-size: 12px; font-weight: 700; }
.review-history-section { margin-top: 16px; padding: 0 14px 10px; }
.review-decision-section { margin-top: 16px; padding: 14px; }
.review-decision-section label { display: flex; margin-bottom: 8px; align-items: center; justify-content: space-between; color: #394960; font-size: 13px; font-weight: 600; }
.review-decision-section label small { color: #8a95a7; font-size: 11px; font-weight: 400; }
.review-decision-section textarea { min-height: 92px; }
.review-decision-error { display: block; min-height: 16px; margin-top: 6px; }
.review-decision-section .review-decision-error:empty { display: block; }
.review-modal-actions { position: sticky; bottom: 0; margin: 0 -24px -18px; padding: 14px 24px; border-top: 1px solid #e0e5ed; background: rgba(255, 255, 255, .96); }
.review-modal-actions .layui-btn:disabled { opacity: .45; box-shadow: none; cursor: not-allowed; }
.publish-review-status-cell small { display: block; margin-top: 5px; color: #7c8798; font-size: 10px; white-space: nowrap; }
.publish-record-status-cell small { display: block; margin-top: 5px; color: #7c8798; font-size: 10px; line-height: 1.4; white-space: nowrap; }

.media-channel-filters,
.media-channel-results { overflow: hidden; border: 1px solid var(--border); border-radius: 7px; background: #fff; box-shadow: var(--shadow); }
.media-channel-filters { margin-bottom: 16px; }
.channel-filter-row { display: grid; min-height: 58px; padding: 10px 18px; grid-template-columns: 100px minmax(0, 1fr); align-items: center; gap: 12px; border-bottom: 1px solid #edf0f4; }
.channel-filter-row[hidden] { display: none; }
.channel-filter-row > strong { color: #536178; font-size: 13px; }
.channel-filter-row > div { display: flex; min-width: 0; align-items: center; gap: 6px; flex-wrap: wrap; }
.channel-filter-chip { min-height: 30px; padding: 5px 12px; border: 1px solid transparent; border-radius: 4px; color: #56647a; background: transparent; font-size: 13px; cursor: pointer; }
.channel-filter-chip:hover:not(:disabled) { color: #245fd8; background: #edf3ff; }
.channel-filter-chip.is-active { color: #fff; background: #2f6ff2; }
.channel-filter-chip.is-fixed { color: #687489; background: #eef1f5; }
.channel-filter-chip:disabled:not(.is-fixed) { color: #b0b7c2; text-decoration: line-through; cursor: not-allowed; }
.filter-skeleton { color: #929cad; font-size: 12px; }
.media-channel-search { display: grid; padding: 12px 18px; grid-template-columns: 320px max-content max-content; justify-content: start; gap: 8px; }
.media-channel-search label { position: relative; }
.media-channel-search label i { position: absolute; top: 12px; left: 12px; color: #8b96a8; }
.media-channel-search input { padding-left: 36px; }
.media-channel-result-heading { display: flex; min-height: 78px; padding: 14px 18px; align-items: center; justify-content: space-between; gap: 14px; border-bottom: 1px solid #e7ebf1; }
.media-channel-result-heading h2 { margin: 0; color: #243249; font-size: 18px; }
.media-channel-result-heading p { margin: 5px 0 0; color: #7e899b; font-size: 12px; }
.media-channel-bulk-actions { display: flex; align-items: center; gap: 10px; }
.media-channel-bulk-actions > span { color: #23735b; font-size: 12px; white-space: nowrap; }
.media-channel-bulk-actions .layui-btn { margin: 0; }
.media-channel-table-wrap { overflow-x: auto; }
.media-channel-table-head,
.media-channel-item { display: grid; min-width: 1080px; grid-template-columns: 42px 230px 112px minmax(280px, 1fr) 116px 92px 82px; align-items: center; column-gap: 12px; }
.media-channel-table-head { min-height: 42px; padding: 0 16px; border-bottom: 1px solid #e5eaf0; color: #758197; background: #f8fafc; box-sizing: border-box; font-size: 11px; font-weight: 700; }
.media-channel-list { min-width: 1080px; }
.media-channel-item { min-height: 74px; padding: 10px 16px; border-bottom: 1px solid #e9edf2; background: #fff; box-sizing: border-box; transition: background .16s ease, box-shadow .16s ease; }
.media-channel-item:last-child { border-bottom: 0; }
.media-channel-item:hover { background: #fbfcfe; }
.media-channel-item.is-selected { background: #f3f8f6; box-shadow: inset 3px 0 #15966f; }
.media-channel-selector { display: inline-grid; width: 22px; height: 22px; padding: 0; place-items: center; border: 1px solid #c8d1dd; border-radius: 4px; color: transparent; background: #fff; cursor: pointer; }
.media-channel-item.is-selected .media-channel-selector { border-color: #15966f; color: #fff; background: #15966f; }
.media-channel-name { min-width: 0; overflow: hidden; color: #26364d; font-size: 13px; line-height: 1.45; text-overflow: ellipsis; white-space: nowrap; }
.media-channel-price { color: #9b520d; font-size: 13px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.media-channel-description { display: -webkit-box; margin: 0; overflow: hidden; color: #68758a; font-size: 11px; line-height: 1.6; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.media-channel-stars { display: inline-flex; gap: 1px; color: #d9dee7; font-size: 15px; letter-spacing: 0; white-space: nowrap; }
.media-channel-stars i { font-style: normal; }
.media-channel-stars i.is-active { color: #f3a31b; }
.media-channel-duration { color: #526077; font-size: 12px; font-weight: 600; white-space: nowrap; }
.media-channel-publish { min-width: 72px; margin: 0; }
.media-channel-list > .table-empty { min-height: 90px; margin: 0; }

.studio-workspace { display: grid; min-height: 660px; grid-template-columns: 440px minmax(0, 1fr); overflow: hidden; border: 1px solid var(--border); border-radius: 7px; background: #fff; box-shadow: var(--shadow); }
.studio-onboarding { display: grid; margin: 0 0 12px; padding: 0; grid-template-columns: repeat(4, minmax(0, 1fr)); overflow: hidden; border: 1px solid #dfe5ee; border-radius: 7px; background: #fff; list-style: none; }
.studio-onboarding li { position: relative; display: grid; min-height: 66px; padding: 10px 34px 10px 14px; grid-template-columns: 30px minmax(0, 1fr); align-items: center; gap: 10px; color: #98a2b3; border-right: 1px solid #e6eaf0; }
.studio-onboarding li:last-child { border-right: 0; }
.studio-onboarding li > b { display: inline-grid; width: 28px; height: 28px; place-items: center; border: 1px solid #d6dce6; border-radius: 50%; color: #8a94a5; background: #fff; font-size: 12px; }
.studio-onboarding li > span { display: flex; min-width: 0; flex-direction: column; gap: 3px; }
.studio-onboarding strong { color: #586579; font-size: 13px; }
.studio-onboarding small { font-size: 11px; }
.studio-onboarding li > i { position: absolute; right: 12px; color: #bcc4d0; }
.studio-onboarding li.is-active { background: #f4f7ff; }
.studio-onboarding li.is-active > b { border-color: #2f6ff2; color: #fff; background: #2f6ff2; }
.studio-onboarding li.is-active strong { color: #245fd8; }
.studio-onboarding li.is-complete { background: #f2faf7; }
.studio-onboarding li.is-complete > b { border-color: #15966f; color: #fff; background: #15966f; }
.studio-onboarding li.is-complete strong { color: #16775b; }
.studio-onboarding li.is-locked { background: #fafbfc; }
.studio-prerequisite-guide { margin-bottom: 14px; padding: 14px 16px; border: 1px solid #ead6ad; border-left: 4px solid #d89526; border-radius: 7px; background: #fffbf2; box-shadow: 0 3px 12px rgba(78, 60, 25, .05); }
.studio-prerequisite-guide[hidden] { display: none; }
.studio-prerequisite-guide > header { display: flex; align-items: center; gap: 10px; }
.studio-prerequisite-guide > header > span { display: inline-grid; width: 32px; height: 32px; flex: 0 0 auto; place-items: center; border-radius: 50%; color: #9a630e; background: #f9e9c8; font-size: 16px; }
.studio-prerequisite-guide > header > div { display: flex; min-width: 0; flex-direction: column; gap: 3px; }
.studio-prerequisite-guide > header strong { color: #674718; font-size: 13px; }
.studio-prerequisite-guide > header small { color: #8a6b39; font-size: 11px; line-height: 1.5; }
.studio-control-pane { padding: 26px 24px; border-right: 1px solid #e2e7ef; background: #fafbfd; }
.studio-control-pane > header small,
.studio-result-pane > header small { color: #2f6ff2; font-size: 12px; font-weight: 700; }
.studio-control-pane > header h2,
.studio-result-pane > header h2 { margin: 6px 0; color: #1f2d43; font-size: 21px; }
.studio-control-pane > header p { margin: 0; color: #7a8699; font-size: 13px; }
.studio-prerequisite-list { display: grid; margin-top: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.studio-prerequisite { display: grid; min-height: 72px; padding: 11px; grid-template-columns: 36px minmax(0, 1fr) auto; align-items: center; gap: 10px; border: 1px solid #dce3ee; border-radius: 7px; background: #fff; }
.studio-prerequisite > span { display: inline-grid; width: 36px; height: 36px; place-items: center; border-radius: 6px; color: #2f6ff2; background: #eaf1ff; font-size: 17px; }
.studio-prerequisite > div { display: flex; min-width: 0; flex-direction: column; gap: 4px; }
.studio-prerequisite strong { color: #344054; font-size: 12px; }
.studio-prerequisite small { color: #7d899b; font-size: 10px; line-height: 1.45; }
.studio-prerequisite.is-complete { border-color: #bfe1d5; background: #f4fbf8; }
.studio-prerequisite.is-complete > span { color: #16775b; background: #e4f5ee; }
.studio-inline-guide { margin-left: auto; color: #2f6ff2; font-size: 11px; font-weight: 500; }
.studio-guide-empty { padding: 20px 14px; border: 1px dashed #cdd6e3; border-radius: 7px; background: #fff; text-align: center; }
.studio-guide-empty p { margin: 0 0 8px; color: #748196; font-size: 11px; line-height: 1.55; }
.studio-guide-empty a { color: #2f6ff2; font-size: 12px; font-weight: 600; }
.studio-control-group { margin-top: 12px; padding: 16px; border: 1px solid #e0e6ef; border-radius: 7px; background: #fff; box-shadow: 0 2px 7px rgba(35, 50, 76, .035); }
.studio-control-pane > header + .studio-control-group { margin-top: 20px; }
.studio-control-group > label { display: flex; margin-bottom: 9px; align-items: center; justify-content: space-between; color: #3b4a61; font-size: 13px; font-weight: 700; }
.studio-control-group > label em { color: #c1372a; font-style: normal; }
.studio-control-group > label small { margin-left: auto; color: #8c96a6; font-size: 11px; font-weight: 400; }
.studio-selected-keywords { margin-bottom: 10px; padding: 9px 10px; border: 1px solid #dce4f0; border-radius: 6px; background: #f7f9fc; }
.studio-selected-keywords > header { display: flex; min-height: 24px; align-items: center; justify-content: space-between; }
.studio-selected-keywords > header span { color: #59677c; font-size: 11px; font-weight: 700; }
.studio-selected-keywords > header button { padding: 0; border: 0; color: #2f6ff2; background: transparent; font-size: 10px; cursor: pointer; }
.studio-selected-keywords > header button:disabled { color: #a9b1bd; cursor: not-allowed; }
.studio-selected-keywords > div { display: flex; max-height: 92px; margin-top: 5px; flex-wrap: wrap; gap: 6px; overflow-y: auto; }
.studio-selected-keywords > div > p { margin: 0; color: #98a2b1; font-size: 10px; line-height: 28px; }
.studio-selected-keyword { display: inline-flex; max-width: 100%; min-height: 28px; padding: 0 5px 0 9px; align-items: center; gap: 5px; border: 1px solid #b9cdf7; border-radius: 14px; color: #245fd8; background: #edf3ff; font-size: 10px; }
.studio-selected-keyword > span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.studio-selected-keyword > button { display: inline-grid; width: 18px; height: 18px; padding: 0; flex: 0 0 auto; place-items: center; border: 0; border-radius: 50%; color: #5477be; background: transparent; cursor: pointer; }
.studio-selected-keyword > button:hover { color: #fff; background: #2f6ff2; }
.studio-keyword-filter { display: grid; margin-bottom: 8px; grid-template-columns: minmax(145px, .8fr) minmax(160px, 1.2fr); gap: 8px; }
.studio-keyword-filter select,
.studio-keyword-filter input { width: 100%; height: 38px; border: 1px solid #d9e0ea; border-radius: 5px; background: #fff; box-sizing: border-box; font-size: 12px; }
.studio-keyword-filter select { padding: 0 9px; }
.studio-keyword-filter label { position: relative; }
.studio-keyword-filter label i { position: absolute; top: 11px; left: 10px; color: #8995a8; z-index: 1; }
.studio-keyword-filter label input { padding-left: 32px; }
.studio-keyword-list { display: grid; max-height: 230px; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; overflow-y: auto; }
.studio-keyword-list > .table-empty,
.studio-keyword-list > .studio-guide-empty { grid-column: 1 / -1; }
.studio-keyword-option { display: grid; min-height: 54px; padding: 8px 9px; grid-template-columns: 22px minmax(0, 1fr); align-items: center; gap: 7px; border: 1px solid #dde3ec; border-radius: 6px; color: inherit; background: #fff; text-align: left; cursor: pointer; }
.studio-keyword-option:hover { border-color: #91aff0; background: #f8faff; }
.studio-keyword-option > i { display: inline-grid; width: 20px; height: 20px; place-items: center; border: 1px solid #cad3df; border-radius: 4px; color: transparent; background: #fff; font-size: 13px; }
.studio-keyword-option > span { display: flex; min-width: 0; flex-direction: column; gap: 2px; }
.studio-keyword-option strong { overflow: hidden; color: #344054; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.studio-keyword-option small { overflow: hidden; color: #8a95a7; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.studio-keyword-option.is-selected { border-color: #2f6ff2; background: #f2f6ff; box-shadow: inset 3px 0 #2f6ff2; }
.studio-keyword-option.is-selected > i { border-color: #2f6ff2; color: #fff; background: #2f6ff2; }
.studio-keyword-pagination { display: flex; min-height: 34px; margin-top: 7px; align-items: center; justify-content: space-between; color: #7c889a; font-size: 10px; }
.studio-keyword-pagination > div { display: flex; align-items: center; gap: 7px; }
.studio-keyword-pagination button { display: inline-grid; width: 28px; height: 28px; padding: 0; place-items: center; border: 1px solid #dce2eb; border-radius: 4px; color: #617087; background: #fff; cursor: pointer; }
.studio-keyword-pagination button:disabled { color: #b7bec8; background: #f4f5f7; cursor: not-allowed; }
.studio-knowledge-summary { display: grid; min-height: 68px; padding: 10px; grid-template-columns: 36px minmax(0, 1fr) auto; align-items: center; gap: 9px; border: 1px solid #dde3ec; border-radius: 6px; background: #f7f9fc; }
.studio-knowledge-summary > span:first-child { display: inline-grid; width: 36px; height: 36px; place-items: center; border-radius: 5px; color: #7b8798; background: #e9edf3; }
.studio-knowledge-summary > span:nth-child(2) { display: flex; min-width: 0; flex-direction: column; gap: 4px; }
.studio-knowledge-summary strong { overflow: hidden; color: #344054; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.studio-knowledge-summary small { color: #8691a3; font-size: 11px; }
.studio-knowledge-summary em { color: #9b620f; font-size: 10px; font-style: normal; white-space: nowrap; }
.studio-knowledge-summary.is-ready { border-color: #bfe1d5; background: #f4fbf8; }
.studio-knowledge-summary.is-ready > span:first-child { color: #16775b; background: #e4f5ee; }
.studio-knowledge-summary.is-ready em { color: #16775b; }
.studio-knowledge-summary > .studio-guide-empty,
.studio-knowledge-summary > .table-empty { grid-column: 1 / -1; }
.studio-strategy-control > select { width: 100%; height: 40px; border: 1px solid #d9e0ea; border-radius: 5px; background: #fff; }
.studio-strategy-fixed { display: flex; min-height: 50px; padding: 9px 11px; align-items: center; gap: 9px; border: 1px solid #dfe5ee; border-radius: 6px; background: #f7f9fc; }
.studio-strategy-fixed > i { color: #687b9e; font-size: 17px; }
.studio-strategy-fixed > span { display: flex; min-width: 0; flex-direction: column; gap: 2px; }
.studio-strategy-fixed strong { color: #3f4d63; font-size: 12px; }
.studio-strategy-fixed small { color: #8a95a7; font-size: 10px; }
.studio-knowledge-list { display: grid; max-height: 285px; gap: 8px; overflow: auto; }
.studio-knowledge-option { display: grid; min-height: 68px; padding: 10px; grid-template-columns: 36px minmax(0, 1fr) auto; align-items: center; gap: 9px; border: 1px solid #dde3ec; border-radius: 6px; color: inherit; background: #fff; text-align: left; cursor: pointer; }
.studio-knowledge-option:hover:not(:disabled) { border-color: #91aff0; }
.studio-knowledge-option.is-selected { border-color: #2f6ff2; background: #f2f6ff; box-shadow: inset 3px 0 #2f6ff2; }
.studio-knowledge-option:disabled { color: #99a2b0; background: #f2f4f6; cursor: not-allowed; }
.studio-knowledge-option > span:first-child { display: inline-grid; width: 36px; height: 36px; place-items: center; border-radius: 5px; color: #2f6ff2; background: #eaf1ff; }
.studio-knowledge-option > span:nth-child(2) { display: flex; min-width: 0; flex-direction: column; gap: 4px; }
.studio-knowledge-option strong { overflow: hidden; color: #2d3c53; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.studio-knowledge-option small { color: #8691a3; font-size: 11px; }
.studio-knowledge-option em { color: #248064; font-size: 10px; font-style: normal; }
.studio-count-control { display: grid; grid-template-columns: minmax(0, 1fr) 80px; gap: 8px; }
.studio-count-presets { display: grid; padding: 3px; grid-template-columns: repeat(4, 1fr); gap: 3px; border: 1px solid #dce2eb; border-radius: 5px; background: #f0f3f7; }
.studio-count-presets button { height: 32px; border: 0; border-radius: 3px; color: #637087; background: transparent; cursor: pointer; }
.studio-count-presets button.is-active { color: #245fd8; background: #fff; box-shadow: 0 1px 3px rgba(30, 48, 80, .12); }
.studio-count-control input { height: 40px; text-align: center; }
.studio-hidden-strategy { display: flex; margin-top: 20px; padding: 12px; align-items: center; gap: 10px; color: #68758a; background: #f0f2f5; }
.studio-hidden-strategy > i { font-size: 18px; }
.studio-hidden-strategy > span { display: flex; flex-direction: column; gap: 3px; }
.studio-hidden-strategy strong { color: #4b586d; font-size: 12px; }
.studio-hidden-strategy small { font-size: 10px; line-height: 1.5; }
.studio-generate-button { width: 100%; margin-top: 22px; }
.studio-generation-message { margin: 9px 0 0; color: #8a94a4; font-size: 11px; line-height: 1.5; text-align: center; }
.studio-result-pane { display: flex; min-width: 0; flex-direction: column; }
.studio-result-pane > header { display: flex; min-height: 86px; padding: 17px 22px; align-items: center; justify-content: space-between; border-bottom: 1px solid #e8ebf1; }
.studio-result-pane > header h2 { margin-bottom: 0; }
.studio-result-pane > header > span { color: #79869a; font-size: 12px; }
.studio-result-empty { display: flex; min-height: 540px; padding: 30px; align-items: center; justify-content: center; flex-direction: column; color: #7e8a9d; text-align: center; }
.studio-result-empty > span { display: inline-grid; width: 70px; height: 70px; margin-bottom: 16px; place-items: center; border-radius: 50%; color: #2f6ff2; background: #eaf1ff; font-size: 30px; }
.studio-result-empty h3 { margin: 0; color: #2c3b52; font-size: 18px; }
.studio-result-empty p { max-width: 460px; margin: 10px 0 16px; font-size: 13px; line-height: 1.65; }
.studio-result-empty a { color: #2f6ff2; font-size: 13px; }
.studio-task-progress { display: flex; min-height: 540px; padding: 34px; align-items: center; justify-content: center; flex-direction: column; text-align: center; box-sizing: border-box; }
.studio-task-progress[hidden],
.studio-result-list[hidden],
.studio-result-empty[hidden] { display: none; }
.studio-task-progress > span { display: inline-grid; width: 72px; height: 72px; margin-bottom: 18px; place-items: center; border-radius: 50%; color: #2f6ff2; background: #eaf1ff; font-size: 30px; }
.studio-task-progress:not(.is-failed) > span i,
.studio-generate-button:disabled .layui-icon-loading { animation: studio-spin 1s linear infinite; }
.studio-task-progress h3 { margin: 0; color: #2c3b52; font-size: 18px; }
.studio-task-progress > p { max-width: 520px; margin: 10px 0 20px; color: #738095; font-size: 13px; line-height: 1.65; }
.studio-task-progress > div { display: flex; width: min(100%, 480px); flex-direction: column; gap: 8px; }
.studio-task-progress > div > i { width: 100%; height: 8px; overflow: hidden; border-radius: 4px; background: #e8edf5; }
.studio-task-progress > div > i > b { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #2f6ff2, #6a91f7); transition: width .3s ease; }
.studio-task-progress > div > small { color: #8792a4; font-size: 11px; }
.studio-task-progress.is-failed > span { color: #b42318; background: #fff0ef; }
.studio-task-progress.is-failed > div > i > b { background: #d94b41; }
.studio-task-retry { margin-top: 18px; }
.studio-task-retry[hidden] { display: none; }
.studio-result-list { display: flex; flex: 0 0 auto; padding: 18px 22px 22px; flex-direction: column; overflow: hidden; }
.studio-title-toolbar { display: flex; min-height: 48px; margin-bottom: 12px; padding: 8px 10px; align-items: center; justify-content: space-between; gap: 12px; border: 1px solid #dfe5ee; border-radius: 6px; background: #f8fafc; box-sizing: border-box; }
.studio-title-toolbar > label { display: inline-flex; align-items: center; gap: 8px; color: #536178; font-size: 12px; cursor: pointer; }
.studio-title-toolbar input,
.studio-result-list li > input { width: 17px; height: 17px; margin: 0; flex: 0 0 auto; accent-color: #2f6ff2; cursor: pointer; }
.studio-title-toolbar > div { display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
.studio-title-toolbar > div > span { color: #6f7c90; font-size: 11px; white-space: nowrap; }
.studio-title-toolbar .layui-btn { margin: 0; }
.studio-title-toolbar .primary-button:disabled { border-color: #dfe4eb; color: #929cab; background: #edf0f4; box-shadow: none; cursor: not-allowed; }
.studio-title-toolbar button[hidden] { display: none; }
.studio-title-toolbar #studio-article-progress-button:not([hidden]) .layui-icon-loading { animation: studio-spin 1s linear infinite; }
.studio-result-list ol { display: grid; height: 982px; margin: 0; padding: 0 4px 0 0; align-content: start; gap: 8px; overflow-y: auto; scrollbar-gutter: stable; list-style: none; }
.studio-result-list li { display: grid; min-height: 58px; padding: 10px 12px; grid-template-columns: 18px 34px minmax(0, 1fr) auto; align-items: center; gap: 10px; border: 1px solid #e0e6ef; border-radius: 6px; background: #fff; box-sizing: border-box; cursor: pointer; transition: border-color .16s ease, background-color .16s ease, box-shadow .16s ease; }
.studio-result-list li:hover:not(.is-disabled) { border-color: #a9bff0; background: #f9fbff; }
.studio-result-list li.is-selected { border-color: #2f6ff2; background: #f2f6ff; box-shadow: inset 3px 0 #2f6ff2; }
.studio-result-list li.is-disabled { color: #8d97a6; background: #fafbfc; cursor: default; }
.studio-result-list li.is-disabled > input { cursor: not-allowed; }
.studio-result-list li b { display: inline-grid; width: 30px; height: 30px; place-items: center; border-radius: 5px; color: #2f6ff2; background: #eef3ff; font-size: 10px; }
.studio-result-list li span { color: #344054; font-size: 13px; line-height: 1.55; }
.studio-result-list li em { padding: 3px 7px; border-radius: 10px; color: #26745c; background: #e9f6f1; font-size: 10px; font-style: normal; white-space: nowrap; }
.studio-result-list li.is-disabled em { color: #727d8e; background: #edf0f4; }
.studio-title-inline-actions { display: flex; align-items: center; justify-self: end; gap: 7px; }
.studio-title-edit-button,
.studio-title-edit-field button { height: 28px; padding: 0 9px; border: 1px solid #cdd8eb; border-radius: 5px; color: #245fd8; background: #fff; font-size: 11px; line-height: 26px; white-space: nowrap; cursor: pointer; }
.studio-title-edit-button:hover,
.studio-title-edit-field button:hover { border-color: #8eabdf; background: #f5f8ff; }
.studio-title-edit-field { display: flex; min-width: 0; align-items: center; gap: 7px; }
.studio-title-edit-field input { width: 100%; min-width: 0; height: 34px; padding: 0 10px; border: 1px solid #2f6ff2; border-radius: 5px; color: #27364e; background: #fff; box-sizing: border-box; outline: none; }
.studio-title-edit-field button.is-primary { border-color: #2f6ff2; color: #fff; background: #2f6ff2; }
.studio-title-edit-field button:disabled { opacity: .6; cursor: wait; }
.studio-result-list > footer { display: flex; margin-top: 14px; padding: 12px 2px 0; align-items: center; justify-content: space-between; border-top: 1px solid #e8ecf2; color: #7a8698; font-size: 11px; }
.studio-result-list > footer a { color: #2f6ff2; font-size: 12px; font-weight: 600; }
@keyframes studio-spin { to { transform: rotate(360deg); } }

.account-profile-heading,
.profile-account-strip,
.profile-form { width: min(100%, 1040px); }
.profile-account-strip { display: grid; min-height: 88px; margin-bottom: 12px; padding: 14px 18px; grid-template-columns: 54px minmax(0, 1fr) auto; align-items: center; gap: 13px; border: 1px solid var(--border); border-radius: 7px; background: #fff; box-shadow: var(--shadow); box-sizing: border-box; }
.profile-logo-preview { display: inline-grid; width: 58px; height: 58px; overflow: hidden; place-items: center; border-radius: 6px; color: #2f6ff2; background: #eaf1ff; font-size: 24px; }
.profile-logo-preview img { width: 100%; height: 100%; object-fit: contain; }
.profile-account-strip > div { display: flex; min-width: 0; flex-direction: column; gap: 3px; }
.profile-account-strip > div small { color: #8691a3; font-size: 11px; }
.profile-account-strip > div strong { color: #27364e; font-size: 17px; }
.profile-account-strip > div span { color: #778398; font-size: 12px; }
.profile-account-strip dl { display: flex; margin: 0; gap: 0; }
.profile-account-strip dl div { min-width: 150px; padding: 2px 20px; border-left: 1px solid #e5e9ef; }
.profile-account-strip dt { color: #8994a5; font-size: 11px; }
.profile-account-strip dd { margin: 5px 0 0; color: #45536a; font-size: 12px; font-weight: 600; }
.profile-form { display: grid; gap: 12px; }
.profile-form-section { overflow: hidden; border: 1px solid var(--border); border-radius: 7px; background: #fff; box-shadow: var(--shadow); }
.profile-location-section { position: relative; z-index: 2; overflow: visible; }
.profile-form-section > header { display: flex; min-height: 62px; padding: 11px 16px; align-items: center; gap: 10px; border-bottom: 1px solid #e8ebf1; box-sizing: border-box; }
.profile-form-section > header > span { display: inline-grid; width: 34px; height: 34px; place-items: center; border-radius: 5px; color: #2f6ff2; background: #eaf1ff; font-size: 15px; }
.profile-form-section h2 { margin: 0; color: #26354c; font-size: 15px; }
.profile-form-section p { margin: 4px 0 0; color: #7e899b; font-size: 12px; }
.profile-form-grid { display: grid; padding: 16px; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 14px; }
.profile-form-grid label { position: relative; display: grid; gap: 7px; }
.profile-form-grid label > span { color: #536178; font-size: 13px; font-weight: 600; }
.profile-form-grid label > span em { color: #c33629; font-style: normal; }
.profile-form-grid input,
.profile-form-grid select { width: 100%; height: 38px; border: 1px solid #d9e0ea; border-radius: 5px; background: #fff; box-sizing: border-box; }
.profile-form-grid select { padding: 0 10px; }
.profile-form-grid textarea { min-height: 96px; }
.profile-wide-field { grid-column: 1 / -1; }
.profile-logo-field { display: grid; grid-column: 1 / -1; gap: 7px; }
.profile-logo-field > span { color: #536178; font-size: 13px; font-weight: 600; }
.profile-logo-uploader { display: grid; min-height: 92px; padding: 12px; grid-template-columns: 68px minmax(0, 1fr); align-items: center; gap: 13px; border: 1px dashed #b9c7da; border-radius: 7px; background: #fbfcfe; box-sizing: border-box; transition: border-color .18s ease, background-color .18s ease; }
.profile-logo-uploader:hover { border-color: #7fa2dc; background: #f7faff; }
.profile-logo-uploader.is-uploading { border-color: #8facdc; background: #f2f6fd; }
.profile-logo-upload-preview { display: inline-grid; width: 66px; height: 66px; overflow: hidden; place-items: center; border: 1px solid #dce4f0; border-radius: 7px; color: #5d7fb8; background: #fff; font-size: 25px; }
.profile-logo-upload-preview img { width: 100%; height: 100%; object-fit: contain; }
.profile-logo-uploader > div { display: flex; min-width: 0; flex-direction: column; align-items: flex-start; gap: 4px; }
.profile-logo-uploader strong { color: #344054; font-size: 13px; }
.profile-logo-uploader small { color: #8290a3; font-size: 11px; line-height: 1.5; }
.profile-logo-actions { display: flex; margin-top: 5px; align-items: center; gap: 7px; }
.profile-logo-actions .layui-btn { height: 30px; margin: 0; line-height: 28px; }
.logo-crop-modal .layui-layer-content { overflow: auto; }
.logo-crop-dialog { padding: 20px; box-sizing: border-box; }
.logo-crop-introduction { margin: 0 0 16px; color: #667085; font-size: 13px; line-height: 1.7; }
.logo-crop-layout { display: grid; grid-template-columns: minmax(0, 1fr) 220px; align-items: stretch; gap: 18px; }
.logo-crop-editor { min-width: 0; overflow: hidden; border: 1px solid #dce3ed; border-radius: 8px; background: #f8fafc; }
.logo-crop-stage { height: min(48vh, 410px); min-height: 310px; overflow: hidden; background: #253044; }
.logo-crop-stage img { display: block; max-width: 100%; }
.logo-crop-controls { display: flex; min-height: 52px; padding: 10px 12px; align-items: center; justify-content: center; gap: 8px; border-top: 1px solid #dce3ed; background: #fff; box-sizing: border-box; }
.logo-crop-control-button { display: inline-flex; height: 32px; padding: 0 12px; align-items: center; justify-content: center; gap: 5px; border: 1px solid #d1d9e5; border-radius: 5px; color: #46556d; background: #fff; font-size: 12px; cursor: pointer; transition: border-color .16s ease, color .16s ease, background-color .16s ease; }
.logo-crop-control-button:hover,
.logo-crop-control-button:focus-visible { border-color: #3daea1; color: #187f75; background: #f0fbf9; outline: none; }
.logo-crop-preview-panel { display: flex; min-width: 0; padding: 18px 16px; flex-direction: column; align-items: center; border: 1px solid #dce3ed; border-radius: 8px; background: #fbfcfe; box-sizing: border-box; }
.logo-crop-preview-panel > strong { color: #26354c; font-size: 15px; }
.logo-crop-preview-panel > p { margin: 6px 0 18px; color: #7a879b; font-size: 12px; line-height: 1.6; text-align: center; }
.logo-crop-preview-panel > small { margin-top: auto; padding-top: 16px; color: #7a879b; font-size: 12px; line-height: 1.65; }
.logo-crop-previews { display: grid; width: 100%; grid-template-columns: 1fr; justify-items: center; gap: 18px; }
.logo-crop-preview-item { display: grid; justify-items: center; gap: 8px; color: #536178; font-size: 12px; }
.logo-crop-live-preview { display: block; width: 96px; height: 96px; overflow: hidden; border: 1px solid #d8e0ea; background: #fff; box-shadow: 0 8px 22px rgba(44, 64, 92, .12); }
.logo-crop-square-preview { border-radius: 9px; }
.logo-crop-circle-preview { width: 78px; height: 78px; border-radius: 50%; }
.logo-crop-actions { margin-top: 18px; padding-top: 14px; border-top: 1px solid #e6eaf0; }
.profile-word-count { position: absolute; right: 9px; bottom: 7px; color: #909aab; font-size: 10px; }
.profile-form-actions { display: flex; min-height: 70px; padding: 13px 18px; align-items: center; justify-content: flex-start; gap: 14px; border: 1px solid #dfe5ed; border-radius: 7px; background: #fff; }

/* 登录账号个人资料与安全设置 */
.account-settings-heading,
.account-settings-grid { width: min(100%, 1040px); }
.account-settings-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 14px; }
.account-settings-card { overflow: hidden; border: 1px solid var(--border); border-radius: 8px; background: #fff; box-shadow: var(--shadow); }
.account-settings-card > header { display: flex; min-height: 68px; padding: 13px 17px; align-items: center; gap: 11px; border-bottom: 1px solid #e8ecf2; background: #fbfcfe; box-sizing: border-box; }
.account-settings-card > header > span { display: inline-grid; width: 36px; height: 36px; place-items: center; border-radius: 7px; color: #2f6ff2; background: #eaf1ff; font-size: 16px; }
.account-settings-card > header h2 { margin: 0; color: #27364e; font-size: 15px; }
.account-settings-card > header p { margin: 4px 0 0; color: #7d899c; font-size: 11px; }
.account-password-card { grid-column: 1 / -1; }
.account-settings-form,
.account-security-form { display: grid; padding: 18px; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.account-settings-form label,
.account-security-form label { display: grid; align-content: start; gap: 7px; }
.account-settings-form label > span:first-child,
.account-security-form label > span:first-child { color: #526078; font-size: 12px; font-weight: 600; }
.account-settings-form label > span em,
.account-security-form label > span em { color: #c33629; font-style: normal; }
.account-settings-form label > small,
.account-security-form label > small { color: #8b95a6; font-size: 10px; line-height: 1.5; }
.account-settings-form input:disabled { color: #7c8798; background: #f4f6f9; cursor: not-allowed; }
.account-settings-form footer,
.account-security-form footer { display: flex; grid-column: 1 / -1; padding-top: 4px; justify-content: flex-start; }
.account-mobile-display { display: flex; min-height: 38px; padding: 0 11px; align-items: center; justify-content: space-between; gap: 8px; border: 1px solid #d9e0ea; border-radius: 5px; background: #f7f9fc; box-sizing: border-box; }
.account-mobile-display strong { color: #344054; font-size: 13px; }
.account-mobile-display em { padding: 3px 7px; border-radius: 10px; color: #95630d; background: #fff3d8; font-size: 10px; font-style: normal; }
.account-mobile-display em.is-verified { color: #177255; background: #e9f7f1; }
.account-sms-field { display: grid; grid-template-columns: minmax(0, 1fr) 112px; gap: 8px; }
.account-sms-field button { border: 1px solid #9fc8c0; border-radius: 5px; color: #167a69; background: #f1fbf9; font-size: 12px; cursor: pointer; }
.account-sms-field button:hover { border-color: #48a994; background: #eaf8f5; }
.account-sms-field button:disabled { opacity: .65; cursor: wait; }
.account-mobile-reserved { display: flex; grid-column: 1 / -1; min-height: 44px; padding: 10px 12px; align-items: center; gap: 8px; border: 1px solid #dbe5f6; border-radius: 6px; color: #536783; background: #f5f8fd; box-sizing: border-box; font-size: 12px; }
.account-mobile-reserved i { color: #2f6ff2; }
.account-settings-complete { display: flex; min-height: 156px; padding: 26px; align-items: center; justify-content: center; gap: 13px; color: #246f59; }
.account-settings-complete > i { font-size: 32px; }
.account-settings-complete > div { display: flex; flex-direction: column; gap: 5px; }
.account-settings-complete strong { color: #2c4f45; font-size: 15px; }
.account-settings-complete span { color: #6e7f79; font-size: 12px; }
.account-settings-card [hidden] { display: none !important; }
.account-form .field-help { display: block; margin-top: 5px; color: #8994a5; font-size: 10px; line-height: 1.45; }
.account-form .field-help.is-checking { color: #5d6f89; }
.account-form .field-help.is-success { color: #167a59; }
.account-form .field-help.is-error { color: #b42318; }

/* 内部任务中心与客户内容进度 */
.task-summary-grid { display: grid; margin-bottom: 14px; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.task-summary-grid article { min-height: 92px; padding: 15px 17px; display: flex; flex-direction: column; gap: 4px; border: 1px solid var(--border); border-radius: 7px; background: #fff; box-shadow: var(--shadow); }
.task-summary-grid small { color: #657186; font-size: 12px; }
.task-summary-grid strong { color: #24324a; font-size: 24px; }
.task-summary-grid span { color: #8b95a5; font-size: 10px; }
.task-center-panel { overflow: hidden; }
.task-center-filter { display: flex; padding: 14px 16px; flex-wrap: wrap; align-items: center; gap: 8px; border-bottom: 1px solid var(--border); }
.task-center-filter .search-field { min-width: 240px; max-width: 360px; flex: 1 1 280px; }
.task-center-filter .layui-form-select { width: 150px; flex: 0 0 150px; }
.task-center-table { min-width: 1080px; }
.task-center-table td > strong, .task-center-table td > small { display: block; }
.task-center-table td > strong { color: #26364f; font-size: 12px; }
.task-center-table td > small { margin-top: 4px; color: #8792a4; font-size: 10px; }
.task-progress { display: flex; min-width: 150px; flex-direction: column; gap: 6px; }
.task-progress > i { width: 100%; height: 6px; overflow: hidden; border-radius: 3px; background: #edf0f5; }
.task-progress > i > b { display: block; height: 100%; border-radius: inherit; background: #2f6ff2; }
.task-progress small { color: #6f7b8f; font-size: 10px; white-space: nowrap; }
.layui-layer-page.task-detail-layer .layui-layer-content { max-height: calc(86vh - 58px); overflow: hidden; }
.task-detail-modal { width: 100%; max-width: 900px; max-height: calc(86vh - 58px); padding: 24px 24px 18px; overflow-x: hidden; overflow-y: auto; box-sizing: border-box; }
.task-detail-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.task-detail-header small { color: #7f8a9b; font-size: 10px; }
.task-detail-header h2 { margin: 5px 0; color: #24324a; font-size: 20px; }
.task-detail-header p { margin: 0; color: #6d798d; font-size: 12px; }
.task-detail-meta { display: grid; margin: 18px 0; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1px solid #e1e6ee; border-radius: 7px; }
.task-detail-meta div { padding: 11px 13px; border-right: 1px solid #e6eaf0; border-bottom: 1px solid #e6eaf0; }
.task-detail-meta div:nth-child(3n) { border-right: 0; }
.task-detail-meta div:nth-last-child(-n+3) { border-bottom: 0; }
.task-detail-meta dt { color: #8994a5; font-size: 10px; }
.task-detail-meta dd { margin: 4px 0 0; color: #344054; font-size: 12px; font-weight: 600; }
.task-detail-error { display: flex; margin-bottom: 16px; padding: 12px 14px; align-items: flex-start; gap: 10px; border: 1px solid #ffd0cc; border-radius: 7px; color: #a6342a; background: #fff5f4; }
.task-detail-error[hidden] { display: none; }
#task-detail-result[hidden], #task-detail-retry[hidden] { display: none; }
.task-detail-error > i { margin-top: 2px; }
.task-detail-error > div { min-width: 0; }
.task-detail-error strong { font-size: 12px; }
.task-detail-error p { margin: 4px 0 0; font-size: 12px; line-height: 1.6; }
.task-detail-error small { display: block; margin-top: 5px; overflow-wrap: anywhere; color: #bd5b52; font-size: 10px; }
.task-log-section { overflow: hidden; border: 1px solid #e1e6ee; border-radius: 7px; }
.task-log-section > header { display: flex; min-height: 48px; padding: 0 14px; align-items: center; justify-content: space-between; border-bottom: 1px solid #e8ebf0; background: #fafbfd; }
.task-log-section h3 { margin: 0; color: #344054; font-size: 13px; }
.task-log-section header span { color: #8b95a5; font-size: 10px; }
.task-log-list { max-height: 320px; padding: 14px; overflow: auto; }
.task-log-item { position: relative; display: grid; padding: 0 0 16px 2px; grid-template-columns: 12px minmax(0, 1fr); gap: 10px; }
.task-log-item:last-child { padding-bottom: 0; }
.task-log-item > i { width: 8px; height: 8px; margin-top: 4px; border: 2px solid #fff; border-radius: 50%; background: #15966f; box-shadow: 0 0 0 1px #9ed5c3; }
.task-log-item.is-failed > i { background: #b42318; box-shadow: 0 0 0 1px #efb0aa; }
.task-log-item > div { min-width: 0; }
.task-log-item strong { display: inline-block; color: #344054; font-size: 12px; }
.task-log-item time, .task-log-item small { margin-left: 8px; color: #939dad; font-size: 10px; }
.task-log-item p { margin: 4px 0 0; color: #667085; font-size: 11px; line-height: 1.55; }
.task-log-item pre { max-height: 120px; margin: 7px 0 0; padding: 8px; overflow: auto; border-radius: 4px; color: #5d6777; background: #f4f6f8; font-size: 10px; white-space: pre-wrap; }

@media (max-width: 1320px) {
    .content-title-filter > .search-field { width: 260px; min-width: 220px; flex-basis: 260px; }
    .content-title-filter > select + .layui-form-select { width: 140px; flex-basis: 140px; }
    .content-title-filter > #content-title-owner-filter + .layui-form-select { width: 160px; flex-basis: 160px; }
    .publish-layout { grid-template-columns: minmax(0, 1fr) 280px; }
    .publish-target-grid { grid-template-columns: 1fr; }
    .review-detail-layout { grid-template-columns: minmax(0, 1fr) 320px; }
    .publish-target-filter { grid-template-columns: minmax(220px, 1fr) 140px 150px max-content max-content; }
    .media-channel-table-head,
    .media-channel-item { min-width: 940px; grid-template-columns: 36px 190px 100px minmax(260px, 1fr) 106px 76px 72px; column-gap: 10px; }
    .media-channel-list { min-width: 940px; }
}

@media (max-width: 980px) {
    .publish-layout { grid-template-columns: 1fr; }
    .publish-summary-panel { position: static; }
    .review-detail-layout { grid-template-columns: 1fr; }
    .review-target-list { max-height: 320px; }
    .studio-workspace { grid-template-columns: 390px minmax(0, 1fr); }
    .profile-account-strip { grid-template-columns: 58px minmax(0, 1fr); }
    .profile-account-strip dl { grid-column: 1 / -1; }
    .profile-account-strip dl div:first-child { padding-left: 0; border-left: 0; }
    .account-settings-grid { grid-template-columns: 1fr; }
    .account-password-card { grid-column: auto; }
    .publish-article-toolbar { align-items: stretch; flex-direction: column; }
    .publish-target-filter { grid-template-columns: minmax(220px, 1fr) repeat(2, 150px) max-content max-content; }
}

@media (max-width: 760px) {
    .studio-workspace { min-height: 0; grid-template-columns: 1fr; }
    .studio-control-pane { border-right: 0; border-bottom: 1px solid #e2e7ef; }
    .studio-result-empty { min-height: 330px; }
    .studio-onboarding { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .studio-onboarding li { border-bottom: 1px solid #e6eaf0; }
    .studio-onboarding li:nth-child(2n) { border-right: 0; }
    .studio-onboarding li:nth-last-child(-n+2) { border-bottom: 0; }
    .studio-prerequisite-list { grid-template-columns: 1fr; }
    .task-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .task-detail-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .task-detail-meta div:nth-child(3n) { border-right: 1px solid #e6eaf0; }
    .task-detail-meta div:nth-child(2n) { border-right: 0; }
    .task-detail-meta div:nth-last-child(-n+3) { border-bottom: 1px solid #e6eaf0; }
    .task-detail-meta div:nth-last-child(-n+2) { border-bottom: 0; }
    .publish-record-filter > .search-field { width: 100%; min-width: 0; flex-basis: 100%; }
    .publish-record-filter > .compact-filter-input,
    .publish-record-filter > .filter-select,
    .publish-record-filter > .filter-select + .layui-form-select { width: calc(50% - 5px); max-width: none; flex-basis: calc(50% - 5px); }
    .publish-detail-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .publish-detail-summary div { border-bottom: 1px solid #e8ebf0; }
    .publish-detail-summary div:nth-child(2n) { border-right: 0; }
    .publish-article-detail-group > header,
    .publish-channel-detail-list > article { align-items: flex-start; flex-direction: column; }
    .publish-item-result { max-width: none; justify-content: flex-start; }
    .publish-item-result small { text-align: left; }
}

@media (max-width: 620px) {
    .topbar-account-trigger { min-width: 0; padding: 6px; }
    .topbar-account-trigger .topbar-user { display: none; }
    .topbar-account-menu { position: fixed; top: 58px; right: 10px; }
    .account-settings-form,
    .account-security-form { grid-template-columns: 1fr; padding: 15px; }
    .account-settings-form footer,
    .account-security-form footer,
    .account-mobile-reserved { grid-column: auto; }
    .content-module-switch { display: grid; width: 100%; grid-template-columns: repeat(2, 1fr); box-sizing: border-box; }
    .content-module-switch button { min-width: 0; padding: 0 8px; }
    .content-title-heading { align-items: stretch; flex-direction: column; }
    .content-title-heading-actions { align-items: stretch; flex-direction: column; }
    .content-title-heading .layui-btn { width: 100%; margin: 0; }
    .publish-stepper { justify-content: space-between; }
    .publish-stepper > span { flex-direction: column; gap: 4px; font-size: 11px; }
    .publish-stepper > i { width: 28px; margin: 0 5px 22px; }
    .publish-section-heading { align-items: flex-start; flex-direction: column; }
    .publish-article-toolbar { padding: 12px; }
    .publish-article-search,
    .publish-target-filter { grid-template-columns: 1fr; }
    .publish-article-search .layui-btn,
    .publish-target-filter .layui-btn { width: 100%; margin: 0; }
    .publish-selected-target-groups section { grid-template-columns: 1fr; gap: 4px; }
    .publish-article-table-head,
    .publish-article-option,
    .publish-article-rows { min-width: 520px; }
    .publish-article-table-head,
    .publish-article-option { grid-template-columns: 22px minmax(180px, 1fr) 96px 82px; }
    .publish-target-grid { padding: 12px; }
    .publish-target-option { grid-template-columns: 36px minmax(0, 1fr); }
    .publish-target-option > em { grid-column: 2; }
    .publish-summary-panel { padding: 15px; }
    .compact-filter-input { max-width: none; }
    .publish-record-filter > .search-field,
    .publish-record-filter > .compact-filter-input,
    .publish-record-filter > .filter-select,
    .publish-record-filter > .filter-select + .layui-form-select { width: 100%; min-width: 0; max-width: none; flex-basis: 100%; }
    .filter-form.publish-record-filter .layui-btn { width: 100%; }
    .publish-record-detail,
    .publish-review-detail { padding: 18px 14px 14px; }
    .publish-record-detail .modal-actions { margin: 18px -14px -14px; padding: 12px 14px; }
    .publish-record-detail-heading,
    .publish-review-detail-heading { flex-direction: column; }
    .publish-review-timeline > article { grid-template-columns: 14px minmax(0, 1fr); }
    .publish-review-timeline time { grid-column: 2; }
    .publish-review-detail-heading-actions { width: 100%; align-items: center; justify-content: space-between; }
    .publish-review-detail-heading-actions .modal-header-close { align-self: center; }
    .publish-detail-summary { grid-template-columns: 1fr; }
    .publish-detail-summary div,
    .publish-detail-summary div:nth-child(2n) { border-right: 0; }
    .review-article-meta { grid-template-columns: 1fr; }
    .review-modal-actions { margin: 0 -14px -14px; padding: 12px 14px; align-items: stretch; flex-direction: column; }
    .review-modal-actions .layui-btn { width: 100%; margin: 0; }
    .channel-filter-row { grid-template-columns: 1fr; gap: 6px; }
    .media-channel-search { grid-template-columns: 1fr; }
    .media-channel-search .layui-btn { width: 100%; margin: 0; }
    .media-channel-result-heading { align-items: flex-start; flex-direction: column; }
    .media-channel-bulk-actions { width: 100%; flex-wrap: wrap; }
    .media-channel-bulk-actions .primary-button { margin-left: auto; }
    .studio-control-pane { padding: 22px 16px; }
    .studio-onboarding { grid-template-columns: 1fr; }
    .studio-onboarding li,
    .studio-onboarding li:nth-last-child(-n+2) { border-right: 0; border-bottom: 1px solid #e6eaf0; }
    .studio-onboarding li:last-child { border-bottom: 0; }
    .studio-prerequisite-guide { padding: 13px 12px; }
    .studio-prerequisite { grid-template-columns: 36px minmax(0, 1fr); }
    .studio-prerequisite > a { grid-column: 1 / -1; width: 100%; margin: 0; }
    .studio-count-control { grid-template-columns: 1fr; }
    .studio-keyword-filter,
    .studio-keyword-list { grid-template-columns: 1fr; }
    .studio-title-toolbar { align-items: stretch; flex-direction: column; }
    .studio-title-toolbar > div { align-items: stretch; flex-direction: column; }
    .studio-title-toolbar .layui-btn { width: 100%; }
    .studio-result-list { padding: 14px 12px 18px; }
    .studio-result-list li { grid-template-columns: 18px 30px minmax(0, 1fr); }
    .studio-title-inline-actions { grid-column: 3; justify-self: start; }
    .studio-title-edit-field { grid-column: 3; flex-wrap: wrap; }
    .studio-title-edit-field input { flex: 1 0 100%; }
    .profile-account-strip { padding: 14px; grid-template-columns: 50px minmax(0, 1fr); }
    .profile-logo-preview { width: 50px; height: 50px; }
    .profile-account-strip dl { display: grid; grid-template-columns: 1fr; }
    .profile-account-strip dl div { padding: 8px 0; border-top: 1px solid #e5e9ef; border-left: 0; }
    .profile-form-grid { padding: 16px; grid-template-columns: 1fr; }
    .profile-wide-field { grid-column: auto; }
    .profile-form-actions { align-items: stretch; flex-direction: column; }
    .profile-form-actions .layui-btn,
    .account-profile-heading .layui-btn { width: 100%; }
    .logo-crop-dialog { padding: 14px; }
    .logo-crop-layout { grid-template-columns: 1fr; gap: 12px; }
    .logo-crop-stage { height: 320px; min-height: 240px; }
    .logo-crop-controls { flex-wrap: wrap; }
    .logo-crop-preview-panel { padding: 14px; }
    .logo-crop-preview-panel > p { margin-bottom: 14px; }
    .logo-crop-previews { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: end; gap: 12px; }
    .logo-crop-preview-panel > small { margin-top: 14px; padding-top: 12px; }
    .logo-crop-actions { align-items: stretch; flex-direction: column-reverse; }
    .logo-crop-actions .layui-btn { width: 100%; margin: 0; }
    .task-summary-grid { grid-template-columns: 1fr; }
    .task-center-filter .search-field,
    .task-center-filter .layui-form-select,
    .task-center-filter .layui-btn { width: 100%; max-width: none; flex: 1 1 100%; margin: 0; }
    .task-detail-modal { padding: 18px 14px 14px; }
    .task-detail-header { flex-direction: column; }
    .task-detail-meta { grid-template-columns: 1fr; }
    .task-detail-meta div,
    .task-detail-meta div:nth-child(2n),
    .task-detail-meta div:nth-child(3n) { border-right: 0; border-bottom: 1px solid #e6eaf0; }
    .task-detail-meta div:last-child { border-bottom: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .publish-article-option,
    .publish-target-option { transition: none; }
}

/* 发布渠道资源级联、板块接口与频道定价 */
.channel-page-heading { align-items: flex-end; }
.channel-heading-actions { display: flex; align-items: center; gap: 10px; }
.page-heading .channel-scope-mark {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    height: 38px;
    margin: 0;
    padding: 0 11px;
    border: 1px solid #cbd9f8;
    border-radius: 5px;
    color: #2c62c9;
    background: #f4f7ff;
    font-size: 11px;
    font-weight: 700;
}

.channel-security-notice { margin-bottom: 14px; }
.channel-workspace {
    display: grid;
    grid-template-columns: 292px minmax(0, 1fr);
    min-height: 620px;
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fff;
    box-shadow: var(--shadow);
}

.channel-cascade-panel {
    padding: 20px 17px;
    border-right: 1px solid var(--border);
    background: #f9fbfe;
}

.channel-cascade-panel > header,
.channel-config-header,
.channel-form-section > header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.channel-cascade-panel > header span { color: #263650; font-size: 14px; font-weight: 700; }
.channel-cascade-panel > header small { max-width: 126px; color: #8a95a8; font-size: 9px; line-height: 1.5; text-align: right; }
.channel-cascade-fields { display: grid; gap: 11px; margin-top: 19px; }
.channel-cascade-fields label { display: grid; gap: 6px; }
.channel-cascade-fields label > span { color: #59667a; font-size: 10px; font-weight: 700; }
.channel-cascade-field > .layui-form-select { width: 100%; min-width: 0; }
.channel-field-heading { display: flex; min-height: 24px; align-items: center; justify-content: space-between; gap: 8px; }
.channel-field-actions { display: inline-flex; align-items: center; gap: 4px; }
.channel-field-actions button {
    display: inline-grid;
    width: 24px;
    height: 24px;
    padding: 0;
    place-items: center;
    border: 1px solid #d9e1ee;
    border-radius: 5px;
    color: #3f70d8;
    background: #fff;
    cursor: pointer;
}
.channel-field-actions button:hover:not(:disabled) { border-color: #9fbbf7; background: #edf4ff; }
.channel-field-actions button:disabled { color: #aab3c2; background: #f3f5f8; cursor: not-allowed; }
.channel-field-actions i { font-size: 13px; }
.channel-cascade-fields select {
    width: 100%;
    height: 36px;
    padding: 0 30px 0 10px;
    border: 1px solid #d7deea;
    border-radius: 4px;
    color: #2d3b53;
    background: #fff;
    font-size: 11px;
    outline: none;
}

.channel-cascade-fields select:focus { border-color: #6f9af5; box-shadow: 0 0 0 3px rgba(47, 111, 242, .09); }
.channel-cascade-fields select:disabled { color: #9ca6b7; background: #f1f4f8; cursor: not-allowed; }
.channel-selection-context {
    display: flex;
    min-height: 96px;
    margin-top: 18px;
    padding: 13px;
    border-left: 3px solid #3976f3;
    flex-direction: column;
    gap: 5px;
    color: #34435c;
    background: #eef4ff;
    box-sizing: border-box;
}

.channel-selection-context small { color: #77849b; font-size: 9px; }
.channel-selection-context strong { font-size: 11px; line-height: 1.55; }
.channel-selection-context span { color: #697790; font-size: 9px; line-height: 1.55; }
.channel-config-panel { min-width: 0; }
.channel-config-header {
    min-height: 78px;
    align-items: center;
    padding: 17px 20px;
    border-bottom: 1px solid var(--border);
    box-sizing: border-box;
}

.channel-config-header h2 { margin: 0; color: #1e2c43; font-size: 17px; }
.channel-config-header p { margin: 5px 0 0; color: #7e899b; font-size: 10px; }
.channel-config-tools { display: flex; align-items: center; gap: 18px; }
.channel-config-tools > span { color: #75839a; font-size: 10px; white-space: nowrap; }
.channel-active-filter { padding: 8px 10px; border: 1px solid #dce4f0; border-radius: 6px; background: #f8fafc; }
.channel-active-filter small { min-width: 68px; color: #4f5f76; font-weight: 600; }
.channel-table-wrap { max-height: 690px; overflow: auto; }
.data-table.channel-config-table { min-width: 640px; table-layout: fixed; }
.channel-config-table th:nth-child(1) { width: 42%; }
.channel-config-table th:nth-child(2) { width: 15%; }
.channel-config-table th:nth-child(3) { width: 16%; }
.channel-config-table th:nth-child(4) { width: 12%; }
.channel-config-table th:nth-child(5) { width: 15%; }
.channel-config-table thead th { position: sticky; top: 0; z-index: 1; background: #f8fafc; }
.channel-config-table td:last-child { white-space: nowrap; }
.channel-config-table td:last-child .table-action + .table-action { margin-left: 10px; }
.channel-resource-name,
.channel-api-summary { display: flex; min-width: 0; flex-direction: column; gap: 4px; }
.channel-resource-name strong { color: #27364e; font-size: 11px; }
.channel-resource-name small,
.channel-api-summary small { color: #8a95a7; font-size: 9px; }
.channel-config-table .channel-resource-name small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.channel-api-summary strong { color: #4c5b71; font-family: SFMono-Regular, Consolas, monospace; font-size: 10px; }
.channel-api-summary small.is-configured { color: #168664; }
.channel-child-row td:first-child { padding-left: 31px; }
.channel-child-row td:first-child::before {
    display: inline-block;
    width: 12px;
    height: 8px;
    margin: 0 7px 3px -18px;
    border-bottom: 1px solid #c8d2e2;
    border-left: 1px solid #c8d2e2;
    content: '';
}
.channel-category-row { background: #fbfcfe; }
.channel-category-row .channel-resource-name strong { font-weight: 600; }
.channel-category-row .channel-resource-name small { color: #929cac; }

.channel-price-text { color: #175d49; font-size: 12px; font-variant-numeric: tabular-nums; }
.channel-price-muted { color: #98a2b3; font-size: 10px; font-weight: 500; }
.table-action:disabled { color: #a8b0bf; cursor: not-allowed; }
.channel-configuration-layer { width: 100%; padding: 0; background: #fff; box-sizing: border-box; }
.channel-configuration-form { padding: 22px 24px 16px; }
.layui-layer-page.channel-configuration-form-layer .layui-layer-content { max-height: calc(100vh - 102px); overflow-y: auto; overscroll-behavior: contain; }
.modal-form-actions { display: flex; justify-content: flex-end; gap: 8px; padding-top: 16px; }
.modal-form-actions .layui-btn { margin: 0; }
.channel-structure-layer { width: 100%; padding: 0; background: #fff; box-sizing: border-box; }
.channel-structure-form { padding: 22px 24px 16px; }
.channel-form-identity { display: flex; align-items: center; gap: 12px; padding-bottom: 17px; border-bottom: 1px solid #e5e9f0; }
.channel-node-symbol {
    display: inline-flex;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    flex: 0 0 42px;
    color: #2f6ff2;
    background: #edf3ff;
    font-size: 19px;
}

.channel-form-identity small { color: #718096; font-size: 9px; }
.channel-form-identity h2 { margin: 2px 0; color: #20304a; font-size: 18px; }
.channel-form-identity p { margin: 0; color: #8995a8; font-family: SFMono-Regular, Consolas, monospace; font-size: 9px; }
.channel-form-section { display: grid; gap: 13px; padding: 18px 0; border-bottom: 1px solid #edf0f4; }
.channel-form-section[hidden] { display: none; }
.channel-form-section > header strong { color: #2b3950; font-size: 12px; }
.channel-form-section > header span { max-width: 420px; color: #8792a4; font-size: 9px; line-height: 1.55; text-align: right; }
.channel-form-section label { display: grid; gap: 7px; color: #4a5971; font-size: 10px; font-weight: 700; }
.channel-form-section label[hidden] { display: none; }
.channel-form-section label > small { color: #8994a5; font-size: 9px; font-weight: 400; line-height: 1.5; }
.channel-form-section label em { color: var(--danger); font-style: normal; }
.channel-form-section .two-column-form { gap: 12px; }
.channel-form-section .three-column-form { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(110px, .8fr) minmax(110px, .8fr); gap: 12px; }
.channel-price-field { max-width: 310px; }
.channel-sort-field { max-width: 310px; }
.channel-money-input { position: relative; display: block; }
.channel-money-input b { position: absolute; top: 50%; left: 12px; z-index: 1; color: #5d6d85; font-size: 12px; transform: translateY(-50%); }
.channel-money-input .layui-input { padding-left: 44px; font-variant-numeric: tabular-nums; }
.channel-change-reason textarea { min-height: 88px; resize: vertical; }
.channel-resource-status-field {
    display: grid;
    max-width: 430px;
    gap: 7px;
    color: #4a5971;
    font-size: 10px;
    font-weight: 700;
}
.channel-resource-status-control { display: flex; align-items: center; gap: 12px; }
.channel-resource-status-control > small { color: #8994a5; font-size: 9px; font-weight: 400; line-height: 1.5; }
.channel-resource-status-control .form-status-switch { min-height: 36px; padding: 7px 10px; border-radius: 5px; }
.channel-resource-seo-section textarea { resize: vertical; }
.channel-resource-seo-section .channel-seo-keyword { min-height: 64px; }
.channel-resource-seo-section .channel-seo-description { min-height: 96px; }
.channel-display-metrics { display: grid; grid-template-columns: minmax(180px, .8fr) minmax(280px, 1.2fr); gap: 12px; }
.channel-display-metrics[hidden] { display: none; }
.channel-duration-inputs { display: grid; grid-template-columns: minmax(70px, 1fr) max-content minmax(70px, 1fr) max-content; align-items: center; gap: 8px; }
.channel-duration-inputs b,
.channel-duration-inputs > span { color: #7b8799; font-size: 10px; font-style: normal; font-weight: 500; }

@media (max-width: 1040px) {
    .channel-workspace { grid-template-columns: 245px minmax(0, 1fr); }
    .channel-cascade-panel { padding-right: 13px; padding-left: 13px; }
}

@media (max-width: 760px) {
    .channel-page-heading { align-items: stretch; }
    .channel-heading-actions { align-items: flex-start; flex-wrap: wrap; }
    .channel-scope-mark { align-self: flex-start; }
    .channel-workspace { display: block; }
    .channel-cascade-panel { border-right: 0; border-bottom: 1px solid var(--border); }
    .channel-cascade-fields { grid-template-columns: 1fr 1fr; }
    .channel-config-header { align-items: flex-start; flex-direction: column; }
    .channel-config-tools { width: 100%; justify-content: space-between; }
    .channel-configuration-form { padding: 18px 16px 12px; }
    .channel-structure-form { padding: 18px 16px 12px; }
    .channel-form-section > header { flex-direction: column; }
    .channel-form-section > header span { text-align: left; }
    .channel-form-section .three-column-form { grid-template-columns: 1fr; }
    .channel-display-metrics { grid-template-columns: 1fr; }
    .channel-resource-status-control { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 480px) {
    .channel-cascade-fields { grid-template-columns: 1fr; }
}

/* 用户内容删除与站内信 */
.message-center-link { position: relative; text-decoration: none; }
.message-center-link.is-active { color: var(--primary); background: #edf3ff; }
.message-center-link.has-unread {
    border-color: #d4e1fb;
    color: var(--primary);
    background: #f4f7ff;
}

.message-center-link.has-unread > i {
    transform-origin: 50% 8%;
    animation: message-bell-ring 1.9s ease-in-out infinite;
}

.message-unread-badge {
    position: absolute;
    top: -4px;
    right: -5px;
    min-width: 16px;
    height: 16px;
    padding: 0 4px;
    border: 2px solid #fff;
    border-radius: 10px;
    color: #fff;
    background: var(--danger);
    box-sizing: border-box;
    font-size: 9px;
    font-weight: 700;
    line-height: 12px;
    text-align: center;
}

.message-unread-badge::after {
    position: absolute;
    inset: -5px;
    border: 1px solid rgba(180, 35, 24, 0.28);
    border-radius: inherit;
    content: '';
    animation: message-badge-pulse 1.9s ease-out infinite;
}

@keyframes message-bell-ring {
    0%, 42%, 100% { transform: rotate(0deg); }
    6% { transform: rotate(14deg); }
    12% { transform: rotate(-12deg); }
    18% { transform: rotate(9deg); }
    24% { transform: rotate(-6deg); }
    30% { transform: rotate(3deg); }
}

@keyframes message-badge-pulse {
    0% { opacity: 0.62; transform: scale(0.72); }
    58%, 100% { opacity: 0; transform: scale(1.55); }
}

@media (prefers-reduced-motion: reduce) {
    .message-center-link.has-unread > i,
    .message-unread-badge::after {
        animation: none;
    }
}

.user-content-delete-modal {
    padding: 24px 24px 18px;
    box-sizing: border-box;
    background: #fff;
}

.user-content-delete-modal > header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 18px;
}

.user-content-delete-modal h2 { margin: 0; color: #202d43; font-size: 20px; }
.user-content-delete-modal header p { margin: 5px 0 0; color: #768197; line-height: 1.55; }
.danger-symbol {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 10px;
    color: var(--danger);
    background: #fff1f0;
    font-size: 20px;
}

.business-notice.danger-notice {
    margin: 0 0 18px;
    border-color: #f1c5c1;
    background: #fff7f6;
}

.business-notice.danger-notice > i,
.business-notice.danger-notice strong { color: var(--danger); }
.user-content-delete-modal textarea { min-height: 108px; resize: vertical; }
.danger-button,
.layui-btn.danger-button {
    border-color: var(--danger);
    color: #fff;
    background: var(--danger);
}

.danger-button:hover,
.layui-btn.danger-button:hover { border-color: #981b13; color: #fff; background: #981b13; }

.message-center-heading { align-items: flex-end; }
.message-filter-tabs {
    display: flex;
    align-items: center;
    gap: 24px;
    margin: 6px 0 0;
    padding: 0 4px;
    border-bottom: 1px solid #dfe5ee;
}

.message-filter-tabs button {
    padding: 13px 2px 11px;
    border: 0;
    border-bottom: 2px solid transparent;
    color: #718096;
    background: transparent;
    cursor: pointer;
    font-size: 12px;
}

.message-filter-tabs button.is-active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 700; }
.message-center-panel { margin-top: 14px; }
.message-list-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 46px;
    padding: 0 16px;
    border-bottom: 1px solid #edf0f5;
    border-radius: 8px 8px 0 0;
    background: #fbfcfe;
    box-sizing: border-box;
}

.message-list-count {
    display: inline-flex;
    min-width: 0;
    align-items: center;
    gap: 7px;
    color: #3f4f68;
    font-size: 11px;
    font-weight: 700;
}

.message-list-count > i {
    color: var(--primary);
    font-size: 14px;
}

.message-list-count > span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.message-list-heading small {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #8a95a8;
    font-size: 10px;
    white-space: nowrap;
}

.message-list-heading small > i {
    color: #a3acba;
    font-size: 12px;
}

.message-table { min-width: 900px; }
.message-table.message-table-customer { min-width: 760px; }
.message-table tr.is-unread td { background: #f7faff; }
.message-table tr.is-unread td:first-child { box-shadow: inset 3px 0 0 #2f71f4; }
.message-table td > strong,
.message-table td > small { display: block; }
.message-table td > strong { color: #263650; font-size: 12px; }
.message-table td > small {
    max-width: 440px;
    margin-top: 4px;
    overflow: hidden;
    color: #8793a6;
    font-size: 10px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.message-view-button {
    display: inline-flex;
    height: 32px;
    margin: 0;
    padding: 0 13px;
    align-items: center;
    justify-content: center;
    gap: 5px;
    line-height: 30px;
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
}

.message-view-button > i { font-size: 13px; }
.layui-layer-page.message-detail-layer .layui-layer-content { max-height: calc(100vh - 96px); }
.modal-content.message-detail-modal { display: flex; min-height: 430px; padding: 30px; flex-direction: column; background: #fff; box-sizing: border-box; }
.message-detail-modal > header { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.message-detail-modal h2 { margin: 12px 0 6px; color: #1d2a40; font-size: 24px; line-height: 1.4; }
.message-detail-modal header p { margin: 0; color: #8994a6; font-size: 11px; }
.message-read-state { color: #637089; font-size: 11px; white-space: nowrap; }
.message-detail-modal > article {
    min-height: 130px;
    margin: 24px 0;
    padding: 22px 0;
    flex: 1;
    color: #33425b;
    border-top: 1px solid #e5e9ef;
    border-bottom: 1px solid #e5e9ef;
    font-size: 14px;
    line-height: 1.85;
    white-space: pre-wrap;
}

.message-detail-modal > .modal-actions { margin: auto -30px -30px; padding: 14px 30px; }
.message-detail-modal > .modal-actions #message-detail-action:not([hidden]) { display: inline-flex; align-items: center; gap: 5px; }
.message-detail-modal > .modal-actions #message-detail-action[hidden] { display: none; }

@media (max-width: 620px) {
    .message-center-heading { align-items: stretch; }
    .message-center-heading .layui-btn { width: 100%; }
    .message-filter-tabs { gap: 18px; overflow-x: auto; }
    .message-filter-tabs button { flex: 0 0 auto; }
    .message-list-heading {
        min-height: 58px;
        align-items: flex-start;
        flex-direction: column;
        justify-content: center;
        gap: 3px;
        padding: 9px 12px;
    }

    .message-list-heading small { white-space: normal; }
    .modal-content.message-detail-modal,
    .user-content-delete-modal { padding: 20px 16px 14px; }
    .modal-content.message-detail-modal { min-height: 0; }
    .message-detail-modal > header { flex-direction: column; }
    .message-detail-modal > .modal-actions { margin: 18px -16px -14px; padding: 12px 16px; }
}

/* 人民币账户余额与不可删除资金流水 */
.finance-notice {
    margin-bottom: 14px;
}

.balance-metric-grid,
.balance-client-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}

.balance-metric-grid article,
.balance-client-summary article {
    display: flex;
    min-height: 112px;
    align-items: center;
    gap: 13px;
    padding: 18px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fff;
    box-sizing: border-box;
    animation: finance-metric-enter 260ms ease both;
}

.balance-metric-grid article:nth-child(2),
.balance-client-summary article:nth-child(2) { animation-delay: 45ms; }
.balance-metric-grid article:nth-child(3),
.balance-client-summary article:nth-child(3) { animation-delay: 90ms; }
.balance-metric-grid article:nth-child(4) { animation-delay: 135ms; }

.balance-metric-grid article > div,
.balance-client-summary article > div {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.balance-metric-grid small,
.balance-metric-grid em,
.balance-client-summary small,
.balance-client-summary em {
    color: #667085;
    font-size: 11px;
    font-style: normal;
}

.balance-metric-grid strong,
.balance-client-summary strong {
    color: #172033;
    font-size: 23px;
    font-variant-numeric: tabular-nums;
    font-weight: 650;
    line-height: 1.25;
}

.balance-filter-form {
    display: grid;
    grid-template-columns: minmax(320px, 400px) 160px auto auto;
    justify-content: start;
    gap: 9px;
    padding: 14px;
    border-bottom: 1px solid var(--border);
}

.balance-account-table {
    min-width: 1120px;
}

.balance-money-cell,
.ledger-signed-amount {
    white-space: nowrap;
    font-variant-numeric: tabular-nums;
    font-weight: 650;
}

.balance-money-cell.available { color: #1d4ed8; }
.balance-money-cell.frozen { color: #b45309; }
.balance-money-cell.spent { color: #6d4bc3; }
.balance-money-cell.muted { color: #4b5565; }

#finance-page .balance-cash-equivalent {
    display: block;
    margin-top: 4px;
    color: var(--text-soft);
    font-size: 12px;
    font-weight: 400;
    line-height: 1.4;
    white-space: nowrap;
}

.finance-time-cell {
    color: #667085;
    font-size: 11px;
    white-space: nowrap;
}

.finance-row {
    animation: finance-row-enter 220ms ease both;
    animation-delay: calc(min(var(--row-index), 8) * 22ms);
}

.finance-form-modal {
    width: 100%;
    box-sizing: border-box;
}

.finance-form [hidden] { display: none !important; }

.finance-form > label,
.finance-form > .finance-customer-field,
.finance-form > .two-column-form,
.finance-form > .selected-finance-customer,
.finance-form > .balance-change-preview,
.finance-form > .inline-notice {
    margin-bottom: 14px;
}

.finance-form label > span {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 11px;
    font-weight: 600;
}

.finance-customer-field > label {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 11px;
    font-weight: 600;
}

.finance-customer-field > label em { color: var(--danger); font-style: normal; }
.finance-customer-combobox { position: relative; }
.finance-customer-search { position: relative; }
.finance-customer-search > i {
    position: absolute;
    z-index: 1;
    top: 11px;
    left: 12px;
    color: #8a95a7;
}

.finance-customer-search .layui-input { padding-right: 40px; padding-left: 38px; }
.finance-customer-search > button {
    position: absolute;
    top: 5px;
    right: 6px;
    width: 30px;
    height: 30px;
    padding: 0;
    border: 0;
    border-radius: 4px;
    color: #8591a5;
    background: transparent;
    cursor: pointer;
}

.finance-customer-search > button:hover { color: var(--primary); background: #eef3fc; }
.finance-customer-combobox.is-selected .finance-customer-search .layui-input {
    border-color: #7ea3eb;
    background: #f8fbff;
    font-weight: 650;
}

.finance-customer-results {
    position: absolute;
    z-index: 20;
    top: calc(100% + 5px);
    right: 0;
    left: 0;
    max-height: 238px;
    padding: 5px;
    overflow-y: auto;
    border: 1px solid #ccd6e5;
    border-radius: 6px;
    background: #fff;
    box-shadow: 0 12px 30px rgba(31, 46, 72, 0.16);
}

.finance-customer-option {
    width: 100%;
    min-height: 48px;
    padding: 8px 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    border: 0;
    border-radius: 4px;
    color: #26364f;
    background: #fff;
    text-align: left;
    cursor: pointer;
}

.finance-customer-option:hover,
.finance-customer-option:focus { outline: 0; background: #edf4ff; }
.finance-customer-option > span { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.finance-customer-option strong { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.finance-customer-option small { overflow: hidden; color: #7a8699; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.finance-customer-option em { flex: 0 0 auto; color: #8a95a6; font-size: 9px; font-style: normal; }
.finance-customer-result-note { margin: 0; padding: 10px; color: #7b8799; font-size: 10px; line-height: 1.55; text-align: center; }
.finance-customer-hint { display: block; margin-top: 6px; color: #7a8698; font-size: 9px; line-height: 1.5; }
.finance-customer-hint.is-selected { color: #2c67c8; }

.finance-form label em {
    color: var(--danger);
    font-style: normal;
}

.finance-form select[lay-ignore] {
    width: 100%;
    height: 38px;
    padding: 0 10px;
    border: 1px solid #d7dde7;
    border-radius: 4px;
    background: #fff;
    color: #202939;
    outline: 0;
}

.finance-form select[lay-ignore]:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(52, 112, 228, 0.11);
}

.finance-form .layui-textarea {
    min-height: 88px;
    resize: vertical;
}

.balance-change-preview {
    display: grid;
    grid-template-columns: 90px minmax(0, 1fr);
    align-items: center;
    gap: 3px 12px;
    min-height: 66px;
    padding: 12px 14px;
    border: 1px solid #dbe5f5;
    border-left: 3px solid var(--primary);
    border-radius: 6px;
    background: #f8fbff;
}

.balance-change-preview > span {
    grid-row: 1 / span 2;
    color: #536176;
    font-size: 10px;
    font-weight: 650;
}

.balance-change-preview strong {
    color: #17365d;
    font-size: 15px;
    font-variant-numeric: tabular-nums;
}

.balance-change-preview small {
    color: #758196;
    font-size: 10px;
}

.balance-change-preview.is-updated strong {
    animation: finance-value-flash 260ms ease;
}

.selected-finance-customer {
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.selected-finance-customer small,
.selected-finance-customer span {
    color: #667085;
    font-size: 10px;
}

.selected-finance-customer strong {
    color: #172033;
    font-size: 14px;
}

.finance-detail-modal {
    padding: 0;
}

.layui-layer-page.finance-ledger-layer .layui-layer-content {
    max-height: min(640px, calc(100vh - 118px));
    overflow-y: auto;
}

.balance-detail-header {
    display: grid;
    grid-template-columns: minmax(210px, 1.1fr) minmax(360px, 1.8fr) auto;
    align-items: center;
    gap: 22px;
    padding: 18px 20px;
    border-bottom: 1px solid var(--border);
    background: #fbfcfe;
}

.balance-detail-header > div:first-child small,
.balance-detail-header > div:first-child p {
    color: #758196;
    font-size: 10px;
}

.balance-detail-header h2 {
    margin: 3px 0;
    color: #172033;
    font-size: 17px;
}

.balance-detail-header dl {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    margin: 0;
}

.balance-detail-header dl div {
    padding: 0 16px;
    border-left: 1px solid #dfe4ec;
}

.balance-detail-header dt {
    color: #758196;
    font-size: 10px;
}

.balance-detail-header dd {
    margin: 4px 0 0;
    color: #172033;
    font-size: 16px;
    font-variant-numeric: tabular-nums;
    font-weight: 650;
}

.balance-detail-actions {
    display: flex;
    gap: 8px;
}

.balance-ledger-filter {
    display: grid;
    grid-template-columns: minmax(220px, 300px) 150px 138px 138px auto auto;
    justify-content: start;
    gap: 8px;
    padding: 12px 14px;
    border-bottom: 1px solid var(--border);
}

.balance-ledger-table {
    min-width: 1080px;
}

.ledger-signed-amount.increase { color: #16845b; }
.ledger-signed-amount.decrease { color: #b54708; }

.ledger-remark {
    max-width: 220px;
    overflow: hidden;
    color: #596579;
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.status-badge.red {
    color: var(--danger);
    background: #fff1f0;
}

.balance-client-summary {
    grid-template-columns: 1.35fr 1fr 1fr;
}

.balance-client-summary .balance-primary-summary {
    border-left: 3px solid var(--primary);
}

.balance-primary-summary p {
    margin: 2px 0 0;
    color: #667085;
    font-size: 11px;
}

.balance-primary-summary p b {
    color: #344054;
    font-variant-numeric: tabular-nums;
    font-weight: 600;
}

.balance-section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 16px 10px;
}

.balance-section-heading h2 {
    margin: 0;
    color: #172033;
    font-size: 14px;
}

.balance-section-heading p {
    margin: 3px 0 0;
    color: #758196;
    font-size: 10px;
}

@keyframes finance-metric-enter {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes finance-row-enter {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes finance-value-flash {
    0% { opacity: 0.55; transform: translateY(2px); }
    100% { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1180px) {
    .balance-metric-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .balance-detail-header {
        grid-template-columns: 1fr auto;
    }

    .balance-detail-header dl {
        grid-column: 1 / -1;
        grid-row: 2;
    }

    .balance-ledger-filter {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 820px) {
    .balance-filter-form,
    .balance-ledger-filter {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .balance-client-summary {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 620px) {
    .balance-metric-grid,
    .balance-filter-form,
    .balance-ledger-filter,
    .balance-detail-header,
    .balance-detail-header dl {
        grid-template-columns: 1fr;
    }

    .balance-filter-form .layui-btn,
    .balance-ledger-filter .layui-btn {
        margin-left: 0;
        width: 100%;
    }

    .balance-detail-header dl div {
        padding: 8px 0;
        border-top: 1px solid #e4e8ef;
        border-left: 0;
    }

    .balance-detail-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .balance-change-preview {
        grid-template-columns: 1fr;
    }

    .balance-change-preview > span {
        grid-row: auto;
    }
}

/* 内容管理：紧凑运营列表、隔离正文预览和明确的未发布边界。 */
.content-publishing-notice {
    margin-bottom: 12px;
    color: #80570f;
    border-color: #f0ddb2;
    background: #fffaf0;
}

.content-publishing-notice > i,
.content-publishing-notice strong { color: #a4670b; }

.content-source-tabs {
    min-height: 44px;
    margin-bottom: 12px;
    display: flex;
    align-items: flex-end;
    gap: 22px;
    overflow-x: auto;
    border-bottom: 1px solid #dfe5ee;
}

.content-source-tabs button,
.content-source-tabs > span {
    min-height: 44px;
    padding: 0 1px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    flex: 0 0 auto;
    color: #6d788c;
    border: 0;
    border-bottom: 2px solid transparent;
    background: transparent;
    font-size: 13px;
    cursor: pointer;
}

.content-source-tabs button.is-active {
    color: #245fd8;
    border-bottom-color: #2f71f4;
    font-weight: 700;
}

.content-source-tabs button span {
    min-width: 22px;
    padding: 2px 6px;
    color: inherit;
    border-radius: 10px;
    background: #edf2ff;
    font-size: 10px;
    text-align: center;
}

.content-source-tabs > span { cursor: default; }
.content-source-tabs > span em {
    padding: 2px 6px;
    color: #8a94a5;
    border-radius: 9px;
    background: #f0f2f5;
    font-size: 9px;
    font-style: normal;
}

.content-filter-summary {
    min-height: 40px;
    padding: 0 14px;
    display: flex;
    align-items: center;
    color: #7a8598;
    border-bottom: 1px solid #edf0f5;
    font-size: 11px;
}

.content-management-table { min-width: 1060px; }
.content-management-table th:first-child,
.content-management-table td:first-child { width: 78px; }
.content-management-table .content-id-cell { color: #59708f; font-variant-numeric: tabular-nums; }

.content-management-table td > strong,
.content-management-table td > small {
    display: block;
    max-width: 100%;
}

.content-management-table td > strong {
    color: #24334d;
    font-size: 12px;
    font-weight: 650;
}

.content-management-table td > small {
    margin-top: 4px;
    color: #8994a6;
    font-size: 10px;
    line-height: 1.45;
}

.content-management-table .content-title-cell { min-width: 280px; max-width: 420px; }
.content-management-table .content-title-cell strong,
.content-management-table .content-title-cell small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.content-management-table .content-owner-cell { min-width: 155px; }
.content-management-table .content-source-cell { min-width: 105px; }
.content-management-table .content-model-cell,
.content-title-table .content-model-cell { min-width: 150px; }
.content-management-table .content-time-cell { min-width: 134px; }
.content-row-action { display: inline-flex; min-width: 54px; height: 30px; padding: 0 12px; align-items: center; justify-content: center; flex: 0 0 auto; border: 1px solid #cfd8e6; border-radius: 5px; color: #344054; background: #fff; font-size: 11px; line-height: normal; white-space: nowrap; cursor: pointer; }
.content-row-action:hover { border-color: #8ea9d6; color: #245fd8; background: #f7faff; }
.content-row-action.is-primary { border-color: var(--primary); color: #fff; background: var(--primary); }
.content-row-action.is-primary:hover { border-color: var(--primary-dark); color: #fff; background: var(--primary-dark); }
.content-row-action.danger { border-color: #e8c7c4; color: #ad3027; }
.content-row-action.danger:hover { border-color: #c94a40; color: #98251d; background: #fff6f5; }

.content-import-layer .layui-layer-content { max-height: calc(100vh - 48px); overflow-y: auto; }
.content-import-task-layer .layui-layer-content { height: 100%; overflow: hidden; }
.content-import-modal { width: 100%; padding: 22px 24px 18px; box-sizing: border-box; }
.content-import-task-modal { width: 100%; height: 100%; padding: 22px 24px 18px; box-sizing: border-box; display: flex; flex-direction: column; overflow: hidden; }
.content-import-heading,
.content-import-task-heading { display: flex; align-items: center; gap: 13px; }
.content-import-heading > span { width: 44px; height: 44px; display: inline-grid; flex: 0 0 auto; place-items: center; border-radius: 9px; color: #285fc9; background: #eaf1ff; font-size: 20px; }
.content-import-heading > div,
.content-import-task-heading > div { min-width: 0; flex: 1; }
.content-import-heading h2,
.content-import-task-heading h2 { margin: 0; color: #1e2b42; font-size: 18px; }
.content-import-heading p,
.content-import-task-heading p { margin: 5px 0 0; color: #778398; font-size: 11px; line-height: 1.55; }
.content-import-template-card { margin: 18px 0 12px; padding: 14px 16px; display: flex; align-items: center; justify-content: space-between; gap: 14px; border: 1px solid #d9e4f7; border-radius: 8px; background: #f7faff; }
.content-import-template-card > div { min-width: 0; }
.content-import-template-card strong,
.content-import-template-card small { display: block; }
.content-import-template-card strong { color: #263854; font-size: 13px; }
.content-import-template-card small { margin-top: 4px; color: #718099; font-size: 10px; line-height: 1.55; }
.content-import-template-card .layui-btn { flex: 0 0 auto; margin: 0; }
.content-import-header-preview { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.content-import-header-preview span { min-height: 42px; padding: 0 11px; display: flex; align-items: center; gap: 8px; overflow: hidden; color: #34445f; border: 1px solid #dfe5ee; border-radius: 6px; background: #fff; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.content-import-header-preview b { width: 20px; height: 20px; display: inline-grid; flex: 0 0 auto; place-items: center; border-radius: 50%; color: #fff; background: #3157c8; font-size: 9px; }
.content-import-form { margin-top: 16px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; }
.content-import-form .manual-field { margin: 0; }
.content-import-form .manual-field > small { display: block; margin-top: 6px; color: #8994a6; font-size: 9px; }
.content-import-owner-fixed { min-height: 39px; padding: 0 12px; display: flex; align-items: center; box-sizing: border-box; border: 1px solid #d7dee9; border-radius: 5px; color: #536176; background: #f6f8fb; font-size: 11px; }
.content-import-file input { width: 100%; min-height: 39px; padding: 7px 9px; box-sizing: border-box; border: 1px dashed #aebbd0; border-radius: 5px; color: #526078; background: #f8fafc; font-size: 10px; }
.content-import-error { margin: 12px 0 0; }
.content-import-notice { margin: 16px 0 0; }
.content-import-modal > footer,
.content-import-task-modal > footer { margin-top: 16px; }
.content-import-task-heading .icon-button { width: 36px; height: 36px; flex: 0 0 auto; border: 1px solid #d8e0ec; border-radius: 5px; color: #2d68d7; background: #fff; cursor: pointer; }
.content-import-task-list { min-height: 160px; margin-top: 14px; padding: 0 4px; flex: 1 1 auto; overflow-y: auto; }
.content-import-task-list .table-empty { min-height: 120px; display: grid; place-items: center; }
.content-import-task-item:first-child { border-top: 1px solid #edf0f4; }
.content-import-task-item .import-task-head strong { max-width: calc(100% - 150px); overflow: hidden; color: #26364f; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.content-import-task-item p { margin: 5px 0; font-size: 10px; }
.content-import-task-item small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.content-detail-modal {
    min-height: 100%;
    padding: 22px 24px 18px;
    box-sizing: border-box;
    background: #f7f9fc;
}

.content-detail-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.content-detail-header > div { min-width: 0; }
.content-detail-header small { color: #6d7f9a; font-size: 11px; }
.content-detail-header h2 {
    margin: 7px 0 6px;
    color: #18233a;
    font-size: 21px;
    line-height: 1.4;
}

.content-detail-header p {
    margin: 0;
    color: #6f7b8e;
    line-height: 1.65;
}

.content-detail-meta {
    margin: 18px 0;
    padding: 14px 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0;
    border-top: 1px solid #e1e6ee;
    border-bottom: 1px solid #e1e6ee;
}

.content-detail-meta div {
    min-width: 0;
    padding: 5px 16px;
    border-right: 1px solid #e5e9f0;
}

.content-detail-meta div:nth-child(3n) { border-right: 0; }
.content-detail-meta dt { color: #8994a5; font-size: 10px; }
.content-detail-meta dd {
    margin: 4px 0 0;
    overflow: hidden;
    color: #2d3b54;
    font-size: 12px;
    font-weight: 650;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.content-detail-preview-section {
    overflow: hidden;
    border: 1px solid #e0e6ee;
    border-radius: 9px;
    background: #fff;
}

.content-detail-preview-section > header {
    min-height: 58px;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    border-bottom: 1px solid #edf0f5;
}

.content-detail-preview-section h3 { margin: 0; color: #24324a; font-size: 13px; }
.content-detail-preview-section p { margin: 3px 0 0; color: #8a95a7; font-size: 10px; }
.content-detail-preview-section > header > span { color: #66758d; font-size: 11px; }
.content-detail-preview-section iframe { width: 100%; height: 410px; display: block; border: 0; background: #fff; }
.content-detail-actions { padding-top: 16px; }
.content-detail-actions [hidden] { display: none; }

@media (max-width: 760px) {
    .content-detail-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .content-detail-meta div:nth-child(3n) { border-right: 1px solid #e5e9f0; }
    .content-detail-meta div:nth-child(2n) { border-right: 0; }
}

@media (max-width: 620px) {
    .content-management-heading .page-heading-actions,
    .content-management-heading .layui-btn { width: 100%; }
    .content-detail-modal { padding: 18px 14px 14px; }
    .content-detail-header { flex-direction: column; }
    .content-detail-meta { grid-template-columns: 1fr; }
    .content-detail-meta div,
    .content-detail-meta div:nth-child(2n),
    .content-detail-meta div:nth-child(3n) { padding: 7px 0; border-right: 0; }
    .content-detail-preview-section > header { align-items: flex-start; flex-direction: column; }
    .content-detail-preview-section iframe { height: 360px; }
    .content-import-modal,
    .content-import-task-modal { padding: 18px 14px 14px; }
    .content-import-template-card { align-items: stretch; flex-direction: column; }
    .content-import-template-card .layui-btn { width: 100%; }
    .content-import-header-preview,
    .content-import-form { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
    .balance-metric-grid article,
    .balance-client-summary article,
    .finance-row,
    .balance-change-preview.is-updated strong {
        animation: none;
    }
}

/* 人工写作 */
.page-heading.manual-writing-page-heading > div > span {
    display: block;
    margin-bottom: 5px;
    color: var(--primary);
    font-size: 12px;
    font-weight: 700;
}

.business-notice.manual-writing-notice {
    border-color: #c8e6da;
    background: #f1faf6;
    color: #345c50;
}

.business-notice.manual-writing-notice > i,
.business-notice.manual-writing-notice strong {
    color: var(--green);
}

.manual-writing-workspace {
    display: grid;
    grid-template-columns: minmax(620px, 1fr) 320px;
    align-items: start;
    gap: 16px;
}

.manual-writing-editor-panel {
    min-width: 0;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.manual-writing-editor-heading {
    min-height: 72px;
    padding: 16px 20px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid var(--border);
}

.manual-writing-editor-heading h2,
.manual-writing-settings-panel h2 {
    margin: 0;
    font-size: 16px;
}

.manual-writing-editor-heading p,
.manual-writing-settings-panel header p {
    margin: 5px 0 0;
    color: var(--text-soft);
    font-size: 12px;
    line-height: 1.55;
}

.manual-save-state {
    min-height: 28px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #475467;
    border: 1px solid #d9e0ea;
    border-radius: 999px;
    background: #f8fafc;
    font-size: 11px;
    white-space: nowrap;
}

.manual-save-state i {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #98a2b3;
}

.manual-save-state.is-saved {
    color: #27745d;
    border-color: #c9e6dc;
    background: #f1faf6;
}

.manual-save-state.is-saved i { background: var(--green); }
.manual-save-state.is-waiting { color: #8a5b16; border-color: #f1d7aa; background: #fff9ef; }
.manual-save-state.is-waiting i { background: #d28a23; }
.manual-save-state.is-saving i,
.manual-save-state.is-loading i { background: var(--primary); animation: manual-saving-pulse 1s ease-in-out infinite; }
.manual-save-state.is-error { color: var(--danger); border-color: #f1c6c2; background: #fff5f4; }
.manual-save-state.is-error i { background: var(--danger); }

@keyframes manual-saving-pulse {
    50% { opacity: 0.25; transform: scale(0.75); }
}

.manual-paper {
    padding: 24px 26px 20px;
    background: linear-gradient(180deg, #fff 0%, #fff 72%, #fbfcfe 100%);
}

.manual-field {
    display: flex;
    flex-direction: column;
    gap: 7px;
    color: #344054;
    font-size: 12px;
    font-weight: 700;
}

.manual-field > span {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.manual-field > span em {
    margin-right: auto;
    color: var(--danger);
    font-style: normal;
}

.manual-field > span small {
    color: #98a2b3;
    font-size: 10px;
    font-weight: 500;
}

.manual-title-field input {
    height: 54px;
    padding: 0 15px;
    color: #172033;
    font-size: 19px;
    font-weight: 700;
}

.manual-summary-field {
    margin-top: 18px;
}

.manual-summary-field textarea {
    min-height: 82px;
    padding: 12px 14px;
    resize: vertical;
    line-height: 1.65;
}

.manual-field-error {
    min-height: 0;
    color: var(--danger);
    font-size: 11px;
    font-weight: 500;
}

.manual-field-error:empty { display: none; }
.is-invalid { border-color: #f0a8a2 !important; box-shadow: 0 0 0 3px rgba(180, 35, 24, 0.08) !important; }

.manual-editor-toolbar {
    position: relative;
    min-height: 44px;
    margin-top: 20px;
    padding: 6px 8px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 3px;
    border: 1px solid #d7dee8;
    border-bottom: 0;
    border-radius: 7px 7px 0 0;
    background: #f8fafc;
}

.manual-editor-toolbar button,
.manual-editor-toolbar select {
    min-height: 30px;
    padding: 0 9px;
    align-items: center;
    gap: 5px;
    color: #586274;
    border: 0;
    border-radius: 5px;
    background: transparent;
    cursor: pointer;
    font-size: 11px;
}

.manual-editor-toolbar button { display: inline-flex; }
.manual-editor-toolbar [hidden],
.manual-article-images[hidden] { display: none; }
.manual-editor-toolbar select { min-width: 112px; outline: 0; }
.manual-editor-toolbar #manual-font-family { min-width: 96px; }
.manual-editor-toolbar #manual-font-size { min-width: 88px; }

.manual-editor-toolbar .manual-toolbar-icon-button {
    width: 30px;
    min-width: 30px;
    padding: 0;
    justify-content: center;
}

.manual-toolbar-icon-button .is-mirrored { transform: scaleX(-1); }

.manual-editor-toolbar button:hover,
.manual-editor-toolbar button.is-active {
    color: var(--primary);
    background: #eaf1ff;
}

.manual-editor-toolbar button:disabled,
.manual-editor-toolbar select:disabled {
    color: #aab3c1;
    background: transparent;
    cursor: not-allowed;
    opacity: 0.65;
}

.manual-toolbar-divider {
    width: 1px;
    height: 22px;
    margin: 0 4px;
    background: #d9e0ea;
}

.manual-emoji-picker {
    position: absolute;
    top: calc(100% + 6px);
    left: 8px;
    z-index: 12;
    width: min(330px, calc(100vw - 72px));
    padding: 8px;
    display: grid;
    grid-template-columns: repeat(8, 32px);
    gap: 4px;
    border: 1px solid #d7dee8;
    border-radius: 7px;
    background: #fff;
    box-shadow: 0 12px 30px rgba(27, 39, 61, 0.16);
}

.manual-emoji-picker[hidden] { display: none; }

.manual-emoji-picker button {
    width: 32px;
    min-width: 32px;
    min-height: 32px;
    padding: 0;
    justify-content: center;
    color: #303a4d;
    font-family: "Apple Color Emoji", "Segoe UI Emoji", sans-serif;
    font-size: 18px;
}

.manual-body-editor {
    min-height: 440px;
    padding: 24px 28px;
    color: #303a4d;
    border: 1px solid #d7dee8;
    border-radius: 0 0 7px 7px;
    outline: 0;
    background: #fff;
    font-family: "Songti SC", "STSong", "Microsoft YaHei", sans-serif;
    font-size: 16px;
    line-height: 1.95;
}

.manual-html-source {
    width: 100%;
    min-height: 440px;
    padding: 20px 22px;
    color: #243047;
    border: 1px solid #d7dee8;
    border-radius: 0 0 7px 7px;
    outline: 0;
    background: #fbfcfe;
    font-family: Consolas, "SFMono-Regular", "Liberation Mono", monospace;
    font-size: 13px;
    line-height: 1.75;
    resize: vertical;
    tab-size: 4;
}

.manual-html-source:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.08);
}

.manual-html-source[hidden] { display: none; }

.manual-body-editor:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.08);
}

.manual-body-editor:empty::before {
    color: #98a2b3;
    content: attr(data-placeholder);
    pointer-events: none;
}

.manual-body-editor h1,
.manual-body-editor h2,
.manual-body-editor h3,
.manual-body-editor h4,
.manual-body-editor h5,
.manual-body-editor h6 { margin: 1.2em 0 0.55em; line-height: 1.45; }
.manual-body-editor p { margin: 0.65em 0; }
.manual-body-editor span[data-font-family="Microsoft YaHei"] { font-family: "Microsoft YaHei", sans-serif; }
.manual-body-editor span[data-font-family="SimSun"] { font-family: SimSun, "宋体", serif; }
.manual-body-editor span[data-font-family="SimHei"] { font-family: SimHei, "黑体", sans-serif; }
.manual-body-editor span[data-font-family="KaiTi"] { font-family: KaiTi, "楷体", serif; }
.manual-body-editor span[data-font-family="FangSong"] { font-family: FangSong, "仿宋", serif; }
.manual-body-editor span[data-font-family="Arial"] { font-family: Arial, sans-serif; }
.manual-body-editor span[data-font-size="14px"] { font-size: 14px; }
.manual-body-editor span[data-font-size="16px"] { font-size: 16px; }
.manual-body-editor span[data-font-size="18px"] { font-size: 18px; }
.manual-body-editor span[data-font-size="20px"] { font-size: 20px; }
.manual-body-editor span[data-font-size="24px"] { font-size: 24px; }
.manual-body-editor span[data-font-size="28px"] { font-size: 28px; }
.manual-body-editor span[data-font-size="32px"] { font-size: 32px; }
.manual-body-editor blockquote { margin: 1em 0; padding: 8px 14px; color: #526071; border-left: 3px solid #9db9ef; background: #f7faff; }
.manual-body-editor figure { margin: 20px auto; text-align: center; }
.manual-body-editor figure img,
.manual-body-editor > img,
.manual-body-editor p > img { max-width: 100%; max-height: 520px; height: auto; border-radius: 7px; object-fit: contain; }
.manual-body-editor figcaption { margin-top: 7px; color: #7a8494; font-size: 12px; }
.manual-body-editor table { width: 100%; margin: 18px 0; border-collapse: collapse; }
.manual-body-editor caption { padding: 8px; color: #475467; font-weight: 700; }
.manual-body-editor th,
.manual-body-editor td { min-width: 80px; padding: 9px 10px; border: 1px solid #cfd7e3; vertical-align: top; }
.manual-body-editor th { background: #f3f6fa; font-weight: 700; }

.manual-article-images {
    margin-top: 16px;
    padding: 13px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fbfcfe;
}

.manual-article-images > header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.manual-article-images > header div { display: flex; flex-direction: column; gap: 3px; }
.manual-article-images > header strong { font-size: 12px; }
.manual-article-images > header span { color: var(--text-soft); font-size: 11px; line-height: 1.5; }
.manual-article-images > header b { color: var(--primary); font-size: 11px; }

.manual-article-image-list {
    margin-top: 10px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.manual-article-image-list > p {
    grid-column: 1 / -1;
    margin: 0;
    padding: 13px;
    color: #8791a1;
    border: 1px dashed #ccd5e2;
    border-radius: 6px;
    background: #fff;
    font-size: 11px;
    text-align: center;
}

.manual-article-image-list article {
    min-width: 0;
    padding: 6px;
    display: grid;
    grid-template-columns: 56px minmax(0, 1fr) 30px;
    align-items: center;
    gap: 9px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: #fff;
}

.manual-article-image-list article > img { width: 56px; height: 48px; object-fit: cover; border-radius: 5px; }
.manual-article-image-list article > div { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.manual-article-image-list article strong { overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.manual-article-image-list article span { color: var(--text-soft); font-size: 10px; }
.manual-article-image-list article button { width: 30px; height: 30px; color: #8b95a5; border: 0; border-radius: 5px; background: transparent; cursor: pointer; }
.manual-article-image-list article button:hover { color: var(--danger); background: #fff2f1; }

.manual-writing-editor-footer {
    min-height: 58px;
    padding: 11px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    color: var(--text-soft);
    border-top: 1px solid var(--border);
    background: #fbfcfe;
    font-size: 11px;
}

.manual-writing-editor-footer > span { display: flex; align-items: center; gap: 7px; }
.manual-writing-editor-footer > span i { width: 3px; height: 3px; border-radius: 50%; background: #98a2b3; }
.manual-writing-editor-footer button { min-height: 34px; padding: 0 11px; display: inline-flex; align-items: center; gap: 6px; color: #276d58; border: 1px solid #c6e1d7; border-radius: 6px; background: #f1faf6; cursor: pointer; font-size: 11px; }

.manual-writing-settings-panel {
    position: sticky;
    top: 78px;
    padding: 18px;
    box-shadow: var(--shadow);
}

.manual-writing-settings-panel > header {
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border);
}

.manual-setting-fields {
    padding: 17px 0 2px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.manual-setting-fields select,
.manual-setting-fields input { width: 100%; height: 42px; }
.manual-setting-fields input[readonly] { color: #677285; background: #f7f9fc; }

.manual-publish-boundary {
    margin-top: 17px;
    padding: 13px;
    display: grid;
    grid-template-columns: 26px minmax(0, 1fr);
    gap: 9px;
    color: #365e53;
    border: 1px solid #cfe5dd;
    border-radius: 7px;
    background: #f3faf7;
}

.manual-publish-boundary > i { color: var(--green); font-size: 19px; }
.manual-publish-boundary strong { font-size: 12px; }
.manual-publish-boundary p { margin: 4px 0 0; color: #677e77; font-size: 11px; line-height: 1.65; }

.manual-draft-meta {
    margin-top: 16px;
    padding: 12px 0;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px 12px;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    font-size: 11px;
}

.manual-draft-meta span { color: var(--text-soft); }
.manual-draft-meta b { color: #344054; }

.manual-setting-actions {
    margin-top: 17px;
    display: grid;
    grid-template-columns: 1fr 1.35fr;
    gap: 8px;
}

.manual-setting-actions .layui-btn { display: inline-flex; width: 100%; margin: 0; padding: 0 10px; align-items: center; justify-content: center; gap: 6px; }
.manual-setting-actions .layui-btn:disabled { cursor: not-allowed; opacity: .68; }
.manual-action-spinner { display: none; animation: studio-spin .8s linear infinite; }
#manual-save-draft-button.is-saving .manual-action-spinner { display: inline-block; }
.manual-publish-pending { margin: 10px 0 0; color: #8a6a34; font-size: 10px; line-height: 1.55; }
.manual-publish-pending i { margin-right: 4px; }
.manual-publish-pending.is-ready { color: #23785d; }
.manual-publish-pending.is-warning { color: #a15c12; }

.manual-media-picker-layer { height: 100%; padding: 18px 18px 0; display: flex; overflow: hidden; flex-direction: column; background: #f8fafc; box-sizing: border-box; }
.manual-media-picker-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.manual-media-picker-toolbar .search-field { width: min(420px, 70%); }
.manual-media-picker-toolbar > span { color: var(--primary); font-size: 11px; }
.manual-media-picker-grid { min-height: 0; margin-top: 14px; padding: 3px 3px 14px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-content: start; flex: 1; gap: 12px; overflow-y: auto; }
.manual-media-picker-grid > .table-empty { grid-column: 1 / -1; padding: 80px 20px; }

.manual-media-picker-item {
    position: relative;
    min-width: 0;
    padding: 8px;
    display: grid;
    grid-template-columns: 1fr;
    color: #344054;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fff;
    box-shadow: 0 4px 14px rgba(34, 49, 77, .05);
    cursor: pointer;
    text-align: left;
}

.manual-media-picker-item:hover { border-color: #9eb8e8; box-shadow: 0 7px 20px rgba(47, 91, 163, .1); }
.manual-media-picker-item.is-selected { border-color: var(--primary); background: #f7faff; box-shadow: inset 0 0 0 1px var(--primary), 0 7px 20px rgba(47, 91, 163, .1); }
.manual-media-picker-item.is-disabled { background: #f3f5f8; cursor: not-allowed; opacity: .66; }
.manual-media-picker-preview { position: relative; overflow: hidden; border-radius: 6px; background: #eef2f7; }
.manual-media-picker-item img { display: block; width: 100%; aspect-ratio: 1.55; object-fit: cover; }
.manual-media-picker-marker { position: absolute; top: 14px; left: 14px; z-index: 2; width: 24px; height: 24px; display: grid; place-items: center; color: transparent; border: 2px solid rgba(255, 255, 255, .95); border-radius: 50%; background: rgba(26, 38, 58, .28); box-shadow: 0 2px 8px rgba(16, 24, 40, .18); }
.manual-media-picker-marker.is-selected { color: #fff; border-color: #fff; background: var(--primary); }
.manual-media-picker-marker.is-inserted { color: #fff; border-color: #fff; background: var(--green); }
.manual-media-picker-view { position: absolute; right: 8px; bottom: 8px; min-height: 28px; padding: 0 10px; display: inline-flex; align-items: center; gap: 5px; border: 1px solid rgba(255, 255, 255, .7); border-radius: 5px; color: #fff; background: rgba(21, 33, 52, .72); backdrop-filter: blur(4px); cursor: pointer; font-size: 11px; }
.manual-media-picker-view:hover { background: rgba(31, 73, 145, .9); }
.manual-media-picker-item strong { margin: 8px 2px 0; overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.manual-media-picker-item > .manual-media-picker-detail { margin: 4px 2px 1px; color: var(--text-soft); font-size: 10px; }
.manual-media-picker-layer > .modal-actions { margin: 0 -18px; padding: 12px 18px; flex: 0 0 auto; border-top: 1px solid var(--border); background: #fff; }
.manual-media-preview-overlay { position: fixed; inset: 0; z-index: 2147483646; display: flex; padding: 28px; align-items: center; justify-content: center; background: rgba(10, 16, 27, .88); box-sizing: border-box; }
.manual-media-preview-panel { display: flex; width: min(1040px, 94vw); max-height: 92vh; overflow: hidden; flex-direction: column; border: 1px solid rgba(255, 255, 255, .18); border-radius: 10px; background: #121a27; box-shadow: 0 24px 70px rgba(0, 0, 0, .46); }
.manual-media-preview-panel > header { display: flex; min-height: 60px; padding: 10px 12px 10px 18px; align-items: center; justify-content: space-between; gap: 16px; color: #fff; background: #1b2636; }
.manual-media-preview-panel > header > div { display: flex; min-width: 0; flex-direction: column; gap: 4px; }
.manual-media-preview-panel > header strong { overflow: hidden; font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }
.manual-media-preview-panel > header span { color: #aebbcf; font-size: 11px; }
.manual-media-preview-close { display: inline-grid; width: 36px; height: 36px; flex: 0 0 auto; place-items: center; border: 1px solid rgba(255, 255, 255, .2); border-radius: 7px; color: #fff; background: rgba(255, 255, 255, .08); cursor: pointer; }
.manual-media-preview-close:hover { background: rgba(255, 255, 255, .16); }
.manual-media-preview-stage { display: flex; min-height: 260px; padding: 18px; align-items: center; justify-content: center; overflow: auto; background: #0c121c; }
.manual-media-preview-stage img { width: min(900px, 86vw); height: min(720px, 76vh); object-fit: contain; image-rendering: auto; }

@media (max-width: 1180px) {
    .manual-writing-workspace { grid-template-columns: minmax(0, 1fr) 290px; }
    .manual-paper { padding-right: 20px; padding-left: 20px; }
}

@media (max-width: 900px) {
    .manual-writing-workspace { grid-template-columns: 1fr; }
    .manual-writing-settings-panel { position: static; }
    .manual-media-picker-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 600px) {
    .manual-writing-page-heading { align-items: stretch; flex-direction: column; }
    .manual-writing-page-heading .layui-btn { width: 100%; margin: 0; }
    .manual-writing-editor-heading { align-items: stretch; flex-direction: column; }
    .manual-save-state { align-self: flex-start; }
    .manual-paper { padding: 18px 14px; }
    .manual-title-field input { font-size: 16px; }
    .manual-editor-toolbar select { min-width: 98px; max-width: 128px; }
    .manual-editor-toolbar #manual-font-family,
    .manual-editor-toolbar #manual-font-size { min-width: 92px; }
    .manual-body-editor,
    .manual-html-source { min-height: 360px; padding: 18px 16px; }
    .manual-body-editor { font-size: 15px; }
    .manual-article-image-list,
    .manual-media-picker-grid { grid-template-columns: 1fr; }
    .manual-writing-editor-footer { align-items: flex-start; flex-direction: column; }
    .manual-writing-editor-footer button { width: 100%; justify-content: center; }
    .manual-setting-actions { grid-template-columns: 1fr; }
    .manual-media-preview-overlay { padding: 12px; }
    .manual-media-preview-panel { width: 100%; }
    .manual-media-preview-stage { padding: 10px; }
}

* {
    box-sizing: border-box;
    letter-spacing: 0;
}

html,
body {
    min-height: 100%;
}

body {
    margin: 0;
    color: var(--text);
    background: var(--bg);
    font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
    font-size: 14px;
}

button,
input,
select,
textarea {
    font: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

.brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    width: 42px;
    height: 42px;
    border-radius: 8px;
    background: #eef4ff;
    overflow: hidden;
}

.brand-mark img {
    width: 36px;
    height: 36px;
    object-fit: contain;
}

.layui-btn {
    border-radius: 6px;
    height: 38px;
    line-height: 38px;
    padding: 0 16px;
}

.primary-button {
    border: 1px solid var(--primary);
    background: var(--primary);
    color: #fff;
}

.primary-button:hover {
    border-color: var(--primary-dark);
    background: var(--primary-dark);
    color: #fff;
}

.secondary-button {
    border: 1px solid #b8c5d9;
    background: #fff;
    color: #344054;
}

.secondary-button:hover,
.ghost-button:hover {
    border-color: #8fa4c2;
    color: var(--primary);
}

.ghost-button {
    border: 1px solid var(--border);
    background: var(--surface-muted);
    color: #475467;
}

.layui-input,
.layui-select,
.layui-textarea {
    height: 40px;
    border-color: #d5dce6;
    border-radius: 6px;
    color: var(--text);
}

.layui-input:focus,
.layui-textarea:focus {
    border-color: var(--primary) !important;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* 登录 */
.login-body {
    overflow: hidden;
    background: #1e293b;
}

.login-page {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 42px max(7vw, 48px);
    background-image: url("../images/dashboard-hero.png");
    background-position: center;
    background-size: cover;
}

.login-page::before {
    position: absolute;
    inset: 0;
    content: "";
    background: rgba(8, 18, 38, 0.58);
}

.login-panel {
    position: relative;
    z-index: 1;
    width: min(430px, 100%);
    padding: 34px 36px 28px;
    border: 1px solid rgba(255, 255, 255, 0.76);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 24px 64px rgba(4, 12, 29, 0.28);
}

.login-brand,
.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.login-brand > span:last-child,
.sidebar-brand > span:last-child {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.login-brand strong {
    font-size: 18px;
    color: #152039;
}

.login-brand small {
    color: #7a8598;
}

.login-heading {
    margin: 42px 0 28px;
}

.login-heading > span,
.page-heading > div > span {
    display: block;
    margin-bottom: 8px;
    color: var(--primary);
    font-size: 13px;
    font-weight: 700;
}

.login-heading h1 {
    margin: 0 0 10px;
    font-size: 30px;
    line-height: 1.25;
}

.login-heading p,
.page-heading p {
    margin: 0;
    color: var(--text-soft);
    line-height: 1.7;
}

.login-form .field-label {
    display: block;
    margin: 0 0 8px;
    color: #344054;
    font-weight: 600;
}

.input-with-icon {
    position: relative;
    margin-bottom: 20px;
}

.input-with-icon > i {
    position: absolute;
    z-index: 1;
    left: 13px;
    top: 11px;
    color: #8b98aa;
}

.input-with-icon .layui-input {
    padding-left: 40px;
}

.password-field .layui-input {
    padding-right: 42px;
}

.password-toggle {
    position: absolute;
    right: 7px;
    top: 4px;
    width: 32px;
    height: 32px;
    border: 0;
    background: transparent;
    color: #667085;
    cursor: pointer;
}

.captcha-field {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 132px;
    gap: 10px;
    margin-bottom: 20px;
}

.captcha-input {
    margin-bottom: 0;
}

.captcha-refresh {
    width: 132px;
    height: 42px;
    padding: 0;
    overflow: hidden;
    border: 1px solid #d6deea;
    border-radius: 6px;
    background: #f2f7fc;
    cursor: pointer;
    transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.captcha-refresh:hover,
.captcha-refresh:focus-visible {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
    outline: none;
}

.captcha-refresh img {
    display: block;
    width: 132px;
    height: 42px;
    object-fit: cover;
}

.login-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 0 0 20px;
    color: #667085;
    font-size: 13px;
}

.login-options label {
    cursor: pointer;
}

.form-error {
    margin: 0 0 14px;
    padding: 9px 11px;
    border: 1px solid #f4c7c3;
    border-radius: 6px;
    background: #fff5f4;
    color: var(--danger);
    line-height: 1.5;
}

.login-submit {
    width: 100%;
    height: 44px;
    line-height: 44px;
}

.login-submit i {
    margin-right: 7px;
}

.login-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
    color: #7b8798;
    font-size: 13px;
}

/* 后台框架 */
.admin-shell {
    min-height: 100vh;
}

.sidebar {
    position: fixed;
    z-index: 20;
    inset: 0 auto 0 0;
    display: flex;
    flex-direction: column;
    width: 224px;
    color: #50596a;
    background: var(--sidebar);
    border-right: 1px solid var(--border);
}

.sidebar-brand {
    flex: 0 0 64px;
    padding: 0 18px;
    border-bottom: 1px solid var(--border);
}

.sidebar-brand .brand-mark {
    width: 34px;
    height: 34px;
    background: #eef4ff;
}

.sidebar-brand .brand-mark img {
    width: 30px;
    height: 30px;
}

.sidebar-brand strong {
    color: #202633;
    font-size: 16px;
}

.sidebar-brand small {
    color: #737d8e;
    font-size: 12px;
}

.sidebar-nav {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 12px 10px 16px;
    scrollbar-width: thin;
}

.nav-section {
    display: block;
    padding: 15px 11px 4px;
    color: #7d8798;
    font-size: 12px;
    font-weight: 500;
}

.nav-item {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 37px;
    margin: 1px 0;
    padding: 0 12px;
    border-radius: 9px;
    color: #50596a;
    font-size: 14px;
    text-decoration: none;
    transition: color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}

.nav-item i {
    width: 28px;
    color: #657184;
    font-size: 16px;
}

.nav-item:hover {
    color: #263043;
    background: var(--sidebar-soft);
}

.nav-item.is-active {
    color: #5949e8;
    background: #eeecff;
    box-shadow: 0 0 0 2px #dedaf8;
    font-weight: 600;
}

.nav-item.is-active i {
    color: #5949e8;
}

.nav-item.is-disabled {
    cursor: default;
    opacity: 0.88;
}

.nav-item.is-disabled:hover {
    color: #50596a;
    background: transparent;
}

.sidebar-footer {
    margin-top: auto;
    padding: 12px;
    border-top: 1px solid var(--border);
}

.support-card {
    display: flex;
    align-items: center;
    gap: 9px;
    min-height: 58px;
    padding: 10px 11px;
    border: 1px solid #dcefe5;
    border-radius: 8px;
    color: #517061;
    background: #f0f8f4;
}

.support-card > i {
    font-size: 20px;
}

.support-card > span {
    display: flex;
    min-width: 0;
    flex-direction: column;
}

.support-card strong {
    font-size: 12px;
}

.support-card small {
    margin-top: 2px;
    color: #657a70;
    font-size: 12px;
    white-space: nowrap;
}

.account-upgrade-layer-shell { overflow: hidden; border-radius: 14px !important; }
.account-upgrade-layer-open .topbar-account-menu { display: none !important; }
.account-upgrade-dialog { position: relative; padding: 26px; color: #4a5568; background: #fff; }
.account-upgrade-dialog-close { position: absolute; top: 16px; right: 16px; display: grid; width: 34px; height: 34px; padding: 0; place-items: center; border: 1px solid transparent; border-radius: 9px; color: #7b8494; background: #f5f7fa; cursor: pointer; transition: color .16s ease, border-color .16s ease, background-color .16s ease, transform .16s ease; }
.account-upgrade-dialog-close:hover { border-color: #dbe2ec; color: #344054; background: #eef2f7; transform: translateY(-1px); }
.account-upgrade-dialog-close:focus-visible { outline: 2px solid #356be9; outline-offset: 2px; }
.account-upgrade-dialog-close .layui-icon { font-size: 17px; }
.account-upgrade-dialog > header { display: flex; align-items: center; gap: 13px; }
.account-upgrade-dialog-icon { display: grid; width: 48px; height: 48px; flex: 0 0 48px; place-items: center; border-radius: 13px; color: #6552d9; background: #eeeaff; font-size: 22px; }
.account-upgrade-dialog header small { color: #7a68db; font-size: 9px; font-weight: 800; letter-spacing: 1.4px; }
.account-upgrade-dialog h2 { margin: 4px 0 0; color: #252d3d; font-size: 20px; }
.account-upgrade-intro { margin: 20px 0 0; color: #657086; font-size: 13px; line-height: 1.75; }
.account-upgrade-contact-list { display: grid; margin-top: 18px; gap: 9px; }
.account-upgrade-contact { display: flex; min-height: 56px; padding: 10px 13px; align-items: center; gap: 11px; border: 1px solid #e2e6ee; border-radius: 9px; background: #fafbfe; box-sizing: border-box; }
.account-upgrade-contact > i { display: grid; width: 30px; height: 30px; flex: 0 0 30px; place-items: center; border-radius: 8px; color: #5668c9; background: #edf0ff; }
.account-upgrade-contact > span { display: flex; min-width: 0; flex-direction: column; }
.account-upgrade-contact small { color: #8a94a6; font-size: 10px; }
.account-upgrade-contact strong,
.account-upgrade-contact a { margin-top: 2px; color: #3b465b; font-size: 13px; font-weight: 700; text-decoration: none; overflow-wrap: anywhere; }
.account-upgrade-contact a:hover { color: #245fd8; }
.account-upgrade-placeholder { display: flex; margin-top: 14px; padding: 9px 11px; align-items: flex-start; gap: 7px; border-radius: 8px; color: #8a6c2d; background: #fff8e8; font-size: 11px; line-height: 1.55; }
.account-upgrade-placeholder i { margin-top: 1px; }
.account-upgrade-dialog > footer { display: flex; margin-top: 20px; justify-content: center; }
.account-upgrade-dialog > footer .layui-btn { min-width: 128px; }

@media (max-width: 620px) {
    .account-upgrade-dialog { padding: 20px 16px; }
    .account-upgrade-dialog > header { padding-right: 40px; }
    .account-upgrade-dialog-close { top: 12px; right: 12px; width: 38px; height: 38px; }
}

.admin-main {
    min-height: 100vh;
    margin-left: 224px;
}

.topbar {
    position: sticky;
    z-index: 10;
    top: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    padding: 0 18px;
    border-bottom: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.96);
}

.topbar-context {
    display: flex;
    align-items: center;
    min-width: 220px;
    gap: 9px;
}

.topbar-context > i {
    color: var(--primary);
    font-size: 18px;
}

.topbar-context > span,
.topbar-user {
    display: flex;
    flex-direction: column;
}

.topbar-context strong {
    color: #202633;
    font-size: 14px;
}

.topbar-context small {
    margin-top: 2px;
    color: #6f7888;
    font-size: 12px;
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.environment-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 8px;
    border: 1px solid #dcefe5;
    border-radius: 6px;
    color: #557164;
    background: #f0f8f4;
    font-size: 12px;
}

.role-switcher {
    display: flex;
    align-items: center;
    gap: 2px;
    height: 34px;
    padding: 3px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #f3f5f8;
}

.role-switcher span,
.role-switcher em,
.role-switcher strong {
    display: inline-flex;
    align-items: center;
    height: 26px;
    padding: 0 7px;
    border-radius: 5px;
    font-size: 12px;
    font-style: normal;
    white-space: nowrap;
}

.role-switcher span,
.role-switcher em {
    color: #858d9b;
}

.role-switcher strong {
    color: var(--primary);
    background: #fff;
    box-shadow: 0 1px 4px rgba(31, 48, 77, 0.11);
}

.topbar-icon-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    padding: 0;
    border: 1px solid transparent;
    border-radius: 7px;
    color: #5f6877;
    background: transparent;
    cursor: pointer;
}

.topbar-icon-button:hover {
    border-color: var(--border);
    background: #f1f4f8;
}

.topbar-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 31px;
    height: 31px;
    overflow: hidden;
    border-radius: 50%;
    color: #fff;
    background: #7d8392;
    font-size: 12px;
    font-weight: 600;
}

.topbar-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #fff;
}

.topbar-avatar > i {
    font-size: 16px;
}

.topbar-user strong {
    color: #4d5564;
    font-size: 14px;
}

.topbar-user small {
    margin-top: 2px;
    color: #737d8e;
    font-size: 12px;
}

.topbar-account { position: relative; }
.topbar-account-trigger { display: flex; min-width: 178px; height: 48px; padding: 6px 8px; align-items: center; gap: 9px; border: 0; border-radius: 7px; color: inherit; background: transparent; text-align: left; cursor: pointer; }
.topbar-account-trigger:hover,
.topbar-account:focus-within .topbar-account-trigger,
.topbar-account.is-open .topbar-account-trigger { background: #f3f6fa; }
.topbar-account-trigger .topbar-user { min-width: 0; flex: 1; }
.topbar-account-trigger .topbar-user strong,
.topbar-account-trigger .topbar-user small { max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar-account-arrow { color: #8a94a5; font-size: 11px; transition: transform .16s ease; }
.topbar-account:hover .topbar-account-arrow,
.topbar-account:focus-within .topbar-account-arrow,
.topbar-account.is-open .topbar-account-arrow { transform: rotate(180deg); }
.topbar-account-menu { position: absolute; top: calc(100% + 7px); right: 0; display: none; width: 180px; padding: 6px; border: 1px solid #e0e6ef; border-radius: 8px; background: #fff; box-shadow: 0 12px 30px rgba(31, 45, 69, .14); box-sizing: border-box; }
.topbar-account:hover .topbar-account-menu,
.topbar-account:focus-within .topbar-account-menu,
.topbar-account.is-open .topbar-account-menu { display: grid; }
.topbar-account-menu::before { position: absolute; top: -8px; right: 0; left: 0; height: 8px; content: ''; }
.topbar-account-menu a,
.topbar-account-menu button { display: flex; width: 100%; min-height: 38px; padding: 0 11px; align-items: center; gap: 9px; border: 0; border-radius: 6px; color: #445168; background: transparent; box-sizing: border-box; font-size: 13px; text-align: left; text-decoration: none; cursor: pointer; }
.topbar-account-menu a:hover,
.topbar-account-menu button:hover { color: #245fd8; background: #f2f6ff; }
.topbar-account-menu .account-upgrade-menu-item > i { color: #6653d9; }
.topbar-account-menu #logout-button { margin-top: 4px; border-top: 1px solid #edf0f5; border-radius: 0 0 6px 6px; color: #9a4138; }
.topbar-account-menu #logout-button:hover { color: #b42318; background: #fff4f2; }

.mobile-menu-button {
    display: none;
    margin-right: 12px;
    width: 36px;
    height: 36px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: #fff;
}

.page-content {
    width: min(100%, 1710px);
    margin: 0 auto;
    padding: 22px 26px 42px;
}

.page-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    min-height: 58px;
    margin-bottom: 18px;
}

.page-heading h1 {
    margin: 0;
    font-size: 25px;
    line-height: 1.25;
}

.page-heading p {
    margin: 6px 0 0;
    max-width: 840px;
    color: var(--text-soft);
    font-size: 13px;
    line-height: 1.55;
}

.business-notice,
.inline-notice {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    border: 1px solid #bfdbfe;
    border-radius: 7px;
    background: #eff6ff;
    color: #344b6f;
}

.business-notice {
    margin-bottom: 14px;
    padding: 12px 14px;
}

.business-notice[hidden] {
    display: none;
}

.business-notice > i,
.inline-notice > i {
    color: var(--primary);
    font-size: 18px;
}

.business-notice div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.business-notice strong {
    color: #344b6f;
    font-size: 12px;
}

.business-notice span,
.inline-notice span {
    line-height: 1.6;
}

.business-notice span {
    font-size: 11px;
}

.content-panel {
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
}

.filter-form {
    display: grid;
    grid-template-columns: minmax(280px, 360px) 170px 150px auto auto;
    align-items: center;
    justify-content: start;
    gap: 10px;
    padding: 12px 14px;
    border-bottom: 1px solid var(--border);
}

.filter-form .layui-form-select {
    width: 100%;
}

.filter-form > .filter-select {
    display: block;
    width: 150px;
    height: 38px;
    padding: 0 34px 0 12px;
    border: 1px solid #d7deea;
    border-radius: 6px;
    outline: 0;
    color: #344054;
    background-color: #fff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'%3E%3Cpath d='m3.5 5.25 3.5 3.5 3.5-3.5' fill='none' stroke='%23667585' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 11px center;
    background-size: 14px 14px;
    font-size: 13px;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}

.filter-form > .filter-select:hover {
    border-color: #b9c6d8;
}

.filter-form > .filter-select:focus {
    border-color: #4d7ff2;
    box-shadow: 0 0 0 3px rgba(47, 113, 244, 0.1);
}

/* 后台筛选栏统一规范：主搜索框有明确上限，控件左对齐，剩余空间留白。 */
.filter-form.content-management-filter {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    padding: 14px;
}

.content-management-filter > .search-field {
    width: 320px;
    min-width: 280px;
    max-width: 320px;
    flex: 0 1 320px;
}

.content-management-filter > .content-batch-filter {
    width: 300px;
    min-width: 260px;
    max-width: 300px;
    flex: 0 1 300px;
}

.content-management-filter > .filter-select {
    display: block;
    height: 38px;
    width: 130px;
    min-width: 0;
    flex: 0 0 130px;
    padding: 0 34px 0 12px;
    border: 1px solid #d7deea;
    border-radius: 6px;
    outline: 0;
    color: #344054;
    background-color: #fff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'%3E%3Cpath d='m3.5 5.25 3.5 3.5 3.5-3.5' fill='none' stroke='%23667585' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 11px center;
    background-size: 14px 14px;
    font-size: 13px;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}

.content-management-filter > .filter-select + .layui-form-select {
    width: 140px;
    flex: 0 0 140px;
}

.content-management-filter > .is-owner-filter + .layui-form-select {
    width: 180px;
    flex-basis: 180px;
}

.content-management-filter > .filter-select:hover {
    border-color: #b9c6d8;
}

.content-management-filter > .filter-select:focus {
    border-color: #4d7ff2;
    box-shadow: 0 0 0 3px rgba(47, 113, 244, 0.1);
}

.content-management-filter > .is-owner-filter {
    width: 170px;
    flex-basis: 170px;
}

.content-management-filter > .is-type-filter {
    width: 150px;
    flex-basis: 150px;
}

.filter-form.content-management-filter .layui-btn {
    width: auto;
    margin: 0;
}

@media (max-width: 760px) {
    .content-title-filter > .search-field,
    .content-management-filter > .search-field {
        width: 100%;
        min-width: 0;
        max-width: none;
        flex-basis: 100%;
    }

    .content-title-filter > select + .layui-form-select,
    .content-management-filter > .filter-select,
    .content-management-filter > .is-owner-filter,
    .content-management-filter > .is-type-filter,
    .content-management-filter > .filter-select + .layui-form-select,
    .content-management-filter > .is-owner-filter + .layui-form-select {
        width: calc(50% - 4px);
        flex-basis: calc(50% - 4px);
    }
}

@media (max-width: 620px) {
    .content-title-filter > select + .layui-form-select,
    .content-management-filter > .filter-select,
    .content-management-filter > .is-owner-filter,
    .content-management-filter > .is-type-filter,
    .content-management-filter > .filter-select + .layui-form-select,
    .content-management-filter > .is-owner-filter + .layui-form-select {
        width: 100%;
        flex-basis: 100%;
    }

    .filter-form.content-management-filter .layui-btn {
        width: 100%;
    }

    .content-title-filter-actions { width: 100%; flex: 1 0 100%; }
    .filter-form.content-title-filter .content-title-filter-actions .layui-btn { min-width: 0; flex: 1 1 0; }
}

.search-field {
    position: relative;
}

.search-field i {
    position: absolute;
    z-index: 1;
    top: 11px;
    left: 12px;
    color: #8b95a7;
}

.search-field input {
    padding-left: 38px;
}

.content-panel .layui-table-view {
    margin: 0;
    border: 0;
    border-radius: 0 0 8px 8px;
}

.data-table-wrap {
    width: 100%;
    overflow-x: auto;
}

.data-table {
    width: 100%;
    min-width: 960px;
    border-collapse: collapse;
    table-layout: auto;
}

.data-table th,
.data-table td {
    padding: 11px 12px;
    border-bottom: 1px solid #edf0f4;
    text-align: left;
    vertical-align: middle;
}

.data-table th {
    background: #fbfcfe;
    color: #475467;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

.data-table tbody tr:hover {
    background: #fbfdff;
}

.data-table tbody tr:last-child td {
    border-bottom: 0;
}

.number-cell {
    text-align: center !important;
    white-space: nowrap;
}

.user-table .number-cell,
.permission-table .number-cell {
    text-align: left !important;
}

.table-empty {
    height: 150px;
    color: var(--text-soft);
    text-align: center !important;
}

.data-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    min-height: 58px;
    padding: 10px 16px;
    border-top: 1px solid var(--border);
    color: var(--text-soft);
}

.pagination-controls {
    display: flex;
    align-items: center;
    gap: 7px;
}

.pagination-controls button,
.pagination-controls select {
    height: 34px;
    border: 1px solid #d6dce5;
    border-radius: 5px;
    background: #fff;
    color: #475467;
}

.pagination-controls button {
    padding: 0 12px;
    cursor: pointer;
}

.pagination-controls select {
    padding: 0 8px;
}

.pagination-controls button:disabled {
    background: #f4f6f8;
    color: #a4adba;
    cursor: not-allowed;
}

.layui-table-header th {
    background: #f8fafc;
    color: #475467;
    font-weight: 700;
}

.layui-table-cell {
    height: auto;
    min-height: 28px;
    line-height: 1.5;
    white-space: normal;
}

.user-cell {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 3px 0;
}

.user-cell strong {
    color: var(--text);
    font-size: 12px;
}

.user-cell small,
.muted-text {
    color: #8a95a6;
    font-size: 10px;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    min-height: 25px;
    padding: 2px 8px;
    border-radius: 5px;
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
}

.status-badge.blue {
    color: #1d4ed8;
    background: #eff6ff;
}

.status-badge.green {
    color: var(--green);
    background: var(--green-soft);
}

.status-badge.orange {
    color: var(--orange);
    background: var(--orange-soft);
}

.status-badge.purple {
    color: var(--purple);
    background: var(--purple-soft);
}

.status-badge.gray {
    color: #667085;
    background: #f2f4f7;
}

.table-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.table-action {
    border: 0;
    background: transparent;
    color: var(--primary);
    cursor: pointer;
    font-size: 11px;
}

.table-action.danger {
    color: var(--danger);
}

.table-action:disabled {
    color: #aeb6c3;
    cursor: not-allowed;
}

.publish-review-table .review-list-action-button {
    height: 30px;
    line-height: 28px;
    margin: 0;
    padding: 0 14px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
}

.publish-review-title-link {
    display: inline-block;
    color: var(--primary);
    font-size: 13px;
    font-weight: 600;
    line-height: 1.45;
}

.publish-review-title-link:hover {
    color: #174db8;
    text-decoration: underline;
}

.media-delete-button {
    margin-right: auto;
    border: 1px solid #f0b8b4;
    background: #fff5f4;
    color: var(--danger);
}

.media-delete-button:hover {
    border-color: var(--danger);
    color: var(--danger);
}

.media-delete-button:disabled {
    border-color: #e1e5eb;
    background: #f5f6f8;
    color: #aeb6c3;
    cursor: not-allowed;
}

.modal-content {
    padding: 18px;
    background: #fff;
}

.modal-content[hidden] {
    display: none !important;
}

.layui-layer-page {
    border-radius: 11px;
    box-shadow: 0 26px 80px rgba(14, 25, 45, 0.25);
    overflow: hidden;
}

.layui-layer-page .layui-layer-title {
    height: 58px;
    padding: 0 58px 0 18px;
    border-bottom: 1px solid var(--border);
    background: #fff;
    color: var(--text);
    font-size: 15px;
    font-weight: 700;
    line-height: 58px;
}

.layui-layer-page .layui-layer-setwin {
    top: 21px;
    right: 18px;
}

.layui-layer-page .layui-layer-content {
    overflow-y: auto;
}

.layui-layer-page.user-account-form-layer .layui-layer-content {
    max-height: calc(100vh - 104px);
}

.layui-layer-page.enterprise-profile-modal .layui-layer-content {
    max-height: calc(100vh - 98px);
    overflow-x: hidden;
    background: #f6f8fb;
}

.enterprise-profile-layer {
    padding: 14px;
    background: #f6f8fb;
}

.enterprise-profile-form {
    display: grid;
    gap: 12px;
}

.enterprise-profile-summary {
    display: grid;
    min-height: 76px;
    padding: 12px 14px;
    grid-template-columns: 48px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fff;
    box-sizing: border-box;
}

.enterprise-profile-summary > span:first-child {
    display: inline-grid;
    width: 48px;
    height: 48px;
    overflow: hidden;
    place-items: center;
    border-radius: 7px;
    color: #2f6ff2;
    background: #eaf1ff;
    font-size: 21px;
}

.enterprise-profile-summary > span:first-child img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.enterprise-profile-summary > div {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.enterprise-profile-summary small { color: #8a95a6; font-size: 10px; }
.enterprise-profile-summary strong { overflow: hidden; color: #27364e; font-size: 15px; text-overflow: ellipsis; white-space: nowrap; }
.enterprise-profile-summary em { color: #778398; font-size: 11px; font-style: normal; }

.enterprise-profile-section {
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fff;
}

.enterprise-profile-section > header {
    display: flex;
    min-height: 52px;
    padding: 10px 16px;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    border-bottom: 1px solid #e8ebf1;
    box-sizing: border-box;
}

.enterprise-profile-section > header strong { color: #2c3a50; font-size: 14px; }
.enterprise-profile-section > header span { color: #8792a4; font-size: 11px; }
.enterprise-profile-actions { margin-top: 0; }
.user-table .table-actions { min-width: 245px; flex-wrap: wrap; row-gap: 5px; }

.user-grant-summary {
    display: flex;
    margin-bottom: 16px;
    padding: 12px 14px;
    flex-direction: column;
    gap: 3px;
    border: 1px solid #d9e5ff;
    border-radius: 7px;
    background: #f5f8ff;
}

.user-grant-summary small { color: #7d8ba1; font-size: 10px; }
.user-grant-summary strong { color: #253550; font-size: 15px; }
.user-grant-summary span { color: #66758b; font-size: 11px; }

.account-form > label,
.two-column-form > label,
.permission-picker > label {
    display: block;
    margin-bottom: 14px;
}

.account-form > label[hidden],
.account-form > .inline-notice[hidden] {
    display: none !important;
}

.account-form label > span {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 11px;
    font-weight: 600;
}

.account-form label em {
    color: var(--danger);
    font-style: normal;
}

.two-column-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.inline-notice {
    margin: 2px 0 14px;
    padding: 10px;
    font-size: 11px;
}

.inline-notice.warning {
    border-color: #fed7aa;
    background: var(--orange-soft);
    color: #744210;
}

.inline-notice.warning > i {
    color: var(--orange);
}

.permission-picker {
    margin: 0 0 14px;
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fafbfc;
}

.permission-picker > header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
}

.permission-picker > header div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.permission-picker > header span {
    color: var(--text-soft);
    font-size: 10px;
}

.permission-picker > header button {
    border: 0;
    background: transparent;
    color: var(--primary);
    cursor: pointer;
    font-size: 10px;
}

.permission-options {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 12px;
}

.permission-option {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    min-height: 54px;
    padding: 9px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: #fff;
}

.permission-option input {
    margin-top: 3px;
}

.permission-option span {
    display: flex !important;
    flex-direction: column;
    gap: 2px;
    margin: 0 !important;
    font-weight: 400 !important;
}

.permission-option small {
    color: #8a95a6;
    font-size: 9px;
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding-top: 2px;
    border-top: 1px solid var(--border);
    margin: 0 -18px -18px;
    padding: 10px 18px;
}

/* 角色权限 */
.role-matrix {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.role-card {
    display: flex;
    min-height: 300px;
    flex-direction: column;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.role-card > header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 18px;
    border-bottom: 1px solid var(--border);
}

.role-icon,
.metric-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    width: 42px;
    height: 42px;
    border-radius: 7px;
}

.role-icon.blue,
.metric-icon.blue {
    color: #1d4ed8;
    background: #eaf2ff;
}

.role-icon.green,
.metric-icon.green {
    color: var(--green);
    background: var(--green-soft);
}

.role-icon.orange,
.metric-icon.orange {
    color: var(--orange);
    background: var(--orange-soft);
}

.role-icon.purple,
.metric-icon.purple {
    color: var(--purple);
    background: var(--purple-soft);
}

.role-card > header div {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 4px;
}

.role-card > header strong {
    font-size: 16px;
}

.role-card > header span {
    color: var(--text-soft);
    line-height: 1.5;
}

.role-code {
    margin-left: auto;
    padding: 3px 7px;
    border-radius: 5px;
    background: #f2f4f7;
    color: #667085;
    font-family: Consolas, monospace;
    font-size: 11px;
}

.role-permissions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    flex: 1 1 auto;
    padding: 16px 18px;
}

.role-permission {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 36px;
    color: #475467;
}

.role-permission.is-forbidden {
    color: #a0a8b5;
}

.role-card > footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 13px 18px;
    border-top: 1px solid var(--border);
    background: #fbfcfd;
}

.role-card > footer span {
    color: var(--text-soft);
    font-size: 12px;
}

.role-table {
    min-width: 900px;
    table-layout: fixed;
}

.role-table .role-name-column { width: 25%; }
.role-table .role-code-column { width: 18%; }
.role-table .role-scope-column { width: 16%; }
.role-table .role-permission-column { width: 14%; }
.role-table .role-status-column { width: 10%; }
.role-table .role-action-column { width: 17%; }

.role-table .number-cell {
    text-align: left !important;
}

.role-code-cell {
    color: #667085;
    font-family: Consolas, monospace;
    font-size: 11px;
}

.permission-filter-form {
    display: grid;
    grid-template-columns: minmax(300px, 400px) 190px 130px 130px auto auto;
    align-items: center;
    justify-content: start;
    gap: 10px;
    padding: 12px 14px;
    border-bottom: 1px solid var(--border);
}

.permission-filter-form .layui-form-select {
    width: 100%;
}

.permission-table {
    min-width: 1180px;
}

.permission-code-text,
.permission-route-cell {
    overflow-wrap: anywhere;
    color: #667085;
    font-family: Consolas, monospace;
    font-size: 10px;
}

.permission-route-cell {
    max-width: 250px;
}

.permission-time-cell {
    white-space: nowrap;
}

.permission-native-select {
    width: 100%;
    height: 38px;
    padding: 0 34px 0 10px;
    border: 1px solid #d7deea;
    border-radius: 4px;
    background: #fff;
    color: #344054;
}

.permission-native-select:disabled,
.account-form input[readonly] {
    background: #f4f6f8;
    color: #7b8492;
    cursor: not-allowed;
}

.permission-toggle-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: start;
    gap: 10px;
}

.permission-toggle-grid .ai-native-switch {
    min-height: 54px;
    margin: 0;
}

.permission-account-summary {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
}

.permission-account-summary strong {
    color: var(--text);
    font-size: 14px;
}

.permission-account-summary span {
    color: var(--text-soft);
    font-size: 11px;
}

.permission-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 12px;
    color: var(--text-soft);
    font-size: 10px;
}

.permission-legend span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.legend-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #98a2b3;
}

.legend-dot.role-default {
    background: var(--primary);
}

.legend-dot.account-allow {
    background: var(--green);
}

.legend-dot.account-deny {
    background: var(--danger);
}

.permission-group-list {
    margin-bottom: 14px;
    border: 1px solid var(--border);
    border-radius: 7px;
    overflow: hidden;
}

.permission-group + .permission-group {
    border-top: 1px solid var(--border);
}

.permission-group-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 42px;
    padding: 8px 12px;
    background: #f8fafc;
}

.permission-group-header > span,
.permission-group-title {
    color: var(--text-soft);
    font-size: 10px;
}

.permission-group-header > strong,
.permission-group-title strong {
    color: var(--text);
    font-size: 12px;
}

.permission-group-title {
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.permission-group-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--primary);
    cursor: pointer;
    font-size: 10px;
}

.permission-route-row {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) 86px 160px;
    align-items: center;
    gap: 12px;
    min-height: 54px;
    padding: 8px 12px;
    border-top: 1px solid #edf0f4;
}

.permission-route-row.role-route-row {
    grid-template-columns: 18px minmax(0, 1fr);
    cursor: pointer;
}

.permission-route-info {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.account-form .permission-route-info {
    display: flex;
    margin: 0;
    color: inherit;
    font-weight: 400;
}

.permission-route-info strong {
    color: #344054;
    font-size: 11px;
}

.permission-route-info small {
    overflow-wrap: anywhere;
    color: #8a95a6;
    font-family: Consolas, monospace;
    font-size: 9px;
}

.permission-role-state {
    color: #98a2b3;
    font-size: 10px;
}

.permission-role-state.is-allowed {
    color: var(--primary);
}

.permission-decision-select {
    width: 100%;
    height: 32px;
    padding: 0 8px;
    border: 1px solid var(--border);
    border-radius: 5px;
    background: #fff;
    color: #344054;
    font-size: 10px;
}

/* 模型与提示词管理 */
.ai-provider-panel {
    overflow: hidden;
    margin-bottom: 18px;
}

.ai-provider-panel-header {
    display: flex;
    min-height: 86px;
    padding: 18px 20px;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border-bottom: 1px solid #e6ebf2;
    background: #fbfcfe;
    box-sizing: border-box;
}

.ai-provider-panel-heading {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 12px;
}

.ai-provider-panel-heading-icon {
    display: inline-grid;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    place-items: center;
    border: 1px solid #d8e5fb;
    border-radius: 8px;
    color: var(--primary);
    background: #eef4ff;
}

.ai-provider-panel-heading-icon i {
    font-size: 18px;
}

.ai-provider-panel-heading > div {
    min-width: 0;
}

.ai-provider-panel-heading h2,
.ai-provider-panel-heading p {
    margin: 0;
}

.ai-provider-panel-heading h2 {
    color: #273142;
    font-size: 17px;
    font-weight: 650;
    line-height: 1.35;
}

.ai-provider-panel-heading p {
    margin-top: 4px;
    color: #7e899a;
    font-size: 11px;
    line-height: 1.55;
}

.ai-provider-panel-actions {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
}

.ai-provider-summary {
    display: grid;
    min-height: 48px;
    padding: 6px 12px;
    grid-template-columns: minmax(68px, auto) 1px minmax(76px, auto);
    align-items: center;
    gap: 11px;
    border: 1px solid #dfe6f0;
    border-radius: 8px;
    background: #fff;
    box-sizing: border-box;
    box-shadow: 0 1px 2px rgb(16 24 40 / 3%);
}

.ai-provider-summary-item {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: baseline;
    gap: 5px;
    white-space: nowrap;
}

.ai-provider-summary-item strong {
    color: #2d3b52;
    font-size: 18px;
    font-weight: 700;
    line-height: 1;
}

.ai-provider-summary-item small {
    color: #8792a3;
    font-size: 10px;
}

.ai-provider-summary-item.is-enabled small {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #527667;
}

.ai-provider-summary-item.is-enabled small::before {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #22a06b;
    box-shadow: 0 0 0 3px rgb(34 160 107 / 10%);
    content: '';
}

.ai-provider-summary-divider {
    width: 1px;
    height: 24px;
    background: #e5e9f0;
}

.ai-provider-summary.is-loading {
    display: flex;
    min-width: 140px;
    justify-content: center;
}

.ai-provider-summary-message {
    color: #7e899a;
    font-size: 10px;
    white-space: nowrap;
}

.ai-provider-summary.is-error .ai-provider-summary-message {
    color: var(--danger);
}

.ai-provider-list {
    display: grid;
    padding: 16px 18px 18px;
    grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
    gap: 12px;
}

.ai-provider-card {
    min-width: 0;
    padding: 15px 16px 13px;
    border: 1px solid #dce3ee;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 1px 2px rgb(16 24 40 / 3%);
    transition: border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.ai-provider-card:hover {
    border-color: #b9c9e7;
    box-shadow: 0 7px 18px rgb(52 112 228 / 8%);
    transform: translateY(-1px);
}

.ai-provider-card.is-disabled {
    background: #fafbfc;
}

.ai-provider-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}

.ai-provider-card-identity {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 10px;
}

.ai-provider-card-icon {
    display: inline-flex;
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    align-items: center;
    justify-content: center;
    border-radius: 7px;
    background: #eef4ff;
    color: var(--primary);
}

.ai-provider-card-icon i {
    font-size: 17px;
}

.ai-provider-card-name {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.ai-provider-card-name strong {
    overflow: hidden;
    color: #273142;
    font-size: 13px;
    font-weight: 650;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ai-provider-card-name small {
    overflow: hidden;
    color: #8a95a6;
    font-family: Consolas, "Courier New", monospace;
    font-size: 9px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ai-provider-card-status {
    flex: 0 0 auto;
}

.ai-provider-card-protocol {
    display: flex;
    align-items: center;
    gap: 7px;
    margin: 12px 0 9px;
}

.ai-provider-protocol-tag {
    display: inline-flex;
    min-height: 22px;
    align-items: center;
    padding: 0 8px;
    border-radius: 4px;
    background: #f0f4fa;
    color: #475467;
    font-size: 9px;
    font-weight: 600;
}

.ai-provider-card-protocol small {
    color: #8a95a6;
    font-size: 9px;
}

.ai-provider-card-endpoint {
    min-width: 0;
    padding: 9px 10px;
    border: 1px solid #e7ebf2;
    border-radius: 6px;
    background: #f8fafc;
}

.ai-provider-card-endpoint > span,
.ai-provider-card-key > span {
    display: block;
    margin-bottom: 4px;
    color: #8a95a6;
    font-size: 9px;
}

.ai-provider-card-endpoint code {
    display: block;
    overflow: hidden;
    color: #475467;
    font-family: Consolas, "Courier New", monospace;
    font-size: 10px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ai-provider-card-footer {
    display: grid;
    grid-template-columns: minmax(120px, 1fr) auto auto;
    align-items: end;
    gap: 14px;
    margin-top: 11px;
}

.ai-provider-card-key {
    min-width: 0;
}

.ai-provider-card-key code {
    display: block;
    overflow: hidden;
    color: #344054;
    font-family: Consolas, "Courier New", monospace;
    font-size: 10px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ai-provider-card-timeout {
    display: inline-flex;
    min-height: 28px;
    align-items: center;
    gap: 5px;
    color: #667085;
    font-size: 10px;
    white-space: nowrap;
}

.ai-provider-card-timeout i {
    color: #98a2b3;
    font-size: 12px;
}

.ai-provider-edit-button {
    min-height: 30px;
    padding: 0 11px;
    border: 1px solid #c9d4e7;
    border-radius: 5px;
    background: #fff;
    color: #315f9f;
    font-size: 10px;
    font-weight: 600;
    cursor: pointer;
}

.ai-provider-edit-button:hover,
.ai-provider-edit-button:focus-visible {
    border-color: #8eadda;
    background: #f4f8ff;
    color: var(--primary);
    outline: none;
}

.ai-provider-empty {
    grid-column: 1 / -1;
    padding: 26px 16px;
    border: 1px dashed #d7deea;
    border-radius: 7px;
    color: #8a95a6;
    background: #fafbfc;
    font-size: 11px;
    text-align: center;
}

.ai-provider-empty.is-error {
    border-color: #efc6c2;
    color: var(--danger);
    background: #fff8f7;
}

.ai-provider-layer {
    min-height: 0;
    padding: 0 24px 18px;
    box-sizing: border-box;
}

.layui-layer-page.ai-provider-form-layer .layui-layer-content {
    max-height: calc(100vh - 102px);
    overflow-y: auto;
    overscroll-behavior: contain;
}

.ai-provider-layer .modal-actions {
    position: sticky;
    bottom: 0;
    z-index: 2;
    background: #fff;
    box-shadow: 0 -8px 16px rgba(29, 41, 57, 0.05);
}

.ai-provider-key-field {
    display: block;
    margin: 15px 0;
}

.ai-provider-url-field {
    display: block;
    margin: 15px 0;
}

.ai-provider-timeout-field {
    display: block;
    max-width: 260px;
    margin: 0 0 15px;
}

.ai-provider-key-label {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.ai-provider-key-label > span {
    margin: 0 !important;
}

.ai-provider-key-label > small {
    color: #2f855a;
    font-size: 9px;
    font-weight: 500;
}

.ai-provider-key-label > small.is-warning {
    color: #b36b00;
}

#ai-platform-model-field[hidden] {
    display: none !important;
}

.ai-secret-input {
    position: relative;
    display: block !important;
    margin: 0 !important;
}

.ai-secret-input .layui-input {
    padding-right: 78px;
    background: #fbfcfe;
}

.ai-secret-input button {
    position: absolute;
    top: 4px;
    right: 5px;
    width: 66px;
    height: 32px;
    padding: 0;
    border: 1px solid #d7deea;
    border-radius: 5px;
    background: #fff;
    color: #475467;
    font-size: 10px;
    cursor: pointer;
}

.ai-secret-input button:hover,
.ai-secret-input button:focus-visible {
    border-color: #a9bee3;
    background: #eef4ff;
    color: var(--primary);
    outline: none;
}

.ai-secret-input button:disabled {
    border-color: #e7ebf1;
    background: #f4f6f8;
    color: #a0a8b5;
    cursor: not-allowed;
}

.ai-secret-input button i {
    margin-right: 4px;
    font-size: 11px;
}

.ai-filter-form {
    grid-template-columns: minmax(280px, 360px) 145px 170px 130px auto auto;
}

.ai-configuration-table {
    min-width: 1160px;
}

.ai-config-summary {
    display: flex;
    min-width: 130px;
    flex-direction: column;
    gap: 3px;
}

.ai-config-summary strong {
    color: var(--text);
    font-size: 12px;
    font-weight: 600;
}

.ai-config-summary small {
    color: #8a95a6;
    font-size: 10px;
    word-break: break-word;
}

.ai-code-text,
.code-input {
    font-family: Consolas, "Courier New", monospace;
}

.ai-code-text {
    color: #475467;
    font-size: 11px;
    word-break: break-all;
}

.ai-configuration-layer {
    padding: 0 20px 18px;
}

.ai-form-section {
    padding: 18px 0 4px;
    border-bottom: 1px solid var(--border);
}

.ai-form-section:first-child {
    padding-top: 4px;
}

.ai-form-section:last-of-type {
    border-bottom: 0;
}

.ai-form-section-header {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-bottom: 14px;
}

.ai-form-section-header strong {
    color: #273142;
    font-size: 14px;
}

.ai-form-section-header span {
    color: #8993a4;
    font-size: 10px;
}

.ai-form-section > label,
.ai-parameter-grid > label {
    display: block;
    margin-bottom: 14px;
}

.ai-form-section label > span,
.ai-parameter-grid label > span,
.ai-switch-row label > span {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 11px;
    font-weight: 600;
}

.ai-form-section label em {
    color: var(--danger);
    font-style: normal;
}

.ai-model-selector {
    max-width: 100%;
}

.ai-field-help {
    display: block;
    margin-top: 5px;
    color: #8a95a6;
    font-size: 9px;
    line-height: 1.5;
}

.ai-model-reference-notice {
    margin-top: -2px;
}

.ai-parameter-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.ai-parameter-grid.two-items {
    max-width: 620px;
}

.ai-parameter-grid.three-items {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.ai-parameter-grid.four-items {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}

.ai-switch-row {
    display: grid;
    grid-template-columns: repeat(3, 180px);
    align-items: start;
    gap: 18px;
    margin-bottom: 14px;
}

.ai-native-switch {
    position: relative;
    display: grid !important;
    grid-template-columns: 46px 1fr;
    grid-template-rows: auto 24px;
    align-items: center;
    gap: 6px 9px;
    min-height: 58px;
    cursor: pointer;
}

.ai-native-switch > span {
    grid-column: 1 / -1;
    margin: 0 !important;
}

.ai-native-switch > input {
    position: absolute;
    z-index: 2;
    bottom: 0;
    left: 0;
    width: 46px;
    height: 24px;
    margin: 0;
    opacity: 0;
    cursor: pointer;
}

.ai-native-switch > i {
    position: relative;
    display: block;
    width: 46px;
    height: 24px;
    border: 1px solid #cbd3df;
    border-radius: 12px;
    background: #d7dde6;
    transition: background-color 0.16s ease, border-color 0.16s ease;
}

.ai-native-switch > i::after {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgb(16 24 40 / 20%);
    content: "";
    transition: transform 0.16s ease;
}

.ai-native-switch > input:checked + i {
    border-color: #22a06b;
    background: #22a06b;
}

.ai-native-switch > input:checked + i::after {
    transform: translateX(22px);
}

.ai-native-switch > input:focus-visible + i {
    box-shadow: 0 0 0 3px rgb(52 112 228 / 18%);
}

.ai-native-switch > small {
    color: #7e899a;
    font-size: 9px;
    line-height: 1.4;
}

.ai-native-switch.is-disabled {
    cursor: not-allowed;
    opacity: 0.58;
}

.ai-native-switch.is-disabled > input {
    cursor: not-allowed;
}

.ai-prompt-content {
    min-height: 230px;
    resize: vertical;
    line-height: 1.7;
}

.ai-prompt-workspace {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 14px;
}

.ai-prompt-input-panel {
    display: block;
}

.ai-prompt-input-panel > span {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 11px;
    font-weight: 600;
}

.ai-prompt-preview-panel {
    overflow: hidden;
    border: 1px solid #d7deea;
    border-radius: 6px;
    background: #fff;
}

.ai-prompt-preview-panel > header {
    display: flex;
    min-height: 38px;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 0 12px;
    border-bottom: 1px solid #e7ebf1;
    background: #f8fafc;
}

.ai-prompt-preview-panel > header strong {
    color: #344054;
    font-size: 11px;
}

.ai-prompt-preview-panel > header span {
    color: #8a95a6;
    font-size: 9px;
}

.ai-markdown-preview {
    min-height: 229px;
    max-height: 460px;
    overflow: auto;
    padding: 14px 16px;
    color: #344054;
    font-size: 12px;
    line-height: 1.75;
    overflow-wrap: anywhere;
}

.ai-markdown-preview h1,
.ai-markdown-preview h2,
.ai-markdown-preview h3,
.ai-markdown-preview h4 {
    margin: 14px 0 8px;
    color: #1f2937;
    font-size: 14px;
    line-height: 1.5;
}

.ai-markdown-preview h1:first-child,
.ai-markdown-preview h2:first-child,
.ai-markdown-preview h3:first-child {
    margin-top: 0;
}

.ai-markdown-preview p,
.ai-markdown-preview ul,
.ai-markdown-preview ol,
.ai-markdown-preview blockquote,
.ai-markdown-preview pre {
    margin: 0 0 10px;
}

.ai-markdown-preview ul,
.ai-markdown-preview ol {
    padding-left: 22px;
}

.ai-markdown-preview blockquote {
    padding: 8px 12px;
    border-left: 3px solid #91a7d8;
    background: #f5f7fb;
    color: #596579;
}

.ai-markdown-preview code {
    padding: 2px 4px;
    border-radius: 3px;
    background: #eef2f7;
    font-family: Consolas, "Courier New", monospace;
    font-size: 11px;
}

.ai-markdown-preview pre {
    overflow: auto;
    padding: 10px 12px;
    border-radius: 4px;
    background: #182230;
    color: #f8fafc;
}

.ai-markdown-preview pre code {
    padding: 0;
    background: transparent;
    color: inherit;
}

.ai-preview-empty,
.ai-preview-error {
    color: #98a2b3;
}

.ai-preview-error {
    color: var(--danger);
}

.ai-fixed-parameter-notice {
    margin: 0 0 14px;
}

.ai-user-message-note {
    margin: -3px 0 14px;
    color: #7e899a;
    font-size: 10px;
    line-height: 1.6;
}

.ai-configuration-form .modal-actions {
    position: sticky;
    z-index: 2;
    bottom: -18px;
    background: #fff;
}

.knowledge-configuration-table {
    min-width: 900px;
}

.knowledge-configuration-table th,
.knowledge-configuration-table td {
    font-size: 12px;
}

.knowledge-config-summary {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 105px;
}

.knowledge-config-summary strong {
    color: #273142;
    font-size: 13px;
}

.knowledge-config-summary small {
    color: #667085;
    font-size: 11px;
    line-height: 1.5;
}

.knowledge-configuration-layer {
    padding: 18px 20px 14px;
}

.knowledge-form-section {
    margin-bottom: 18px;
    padding-bottom: 4px;
    border-bottom: 1px solid #edf0f4;
}

.knowledge-form-section-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.knowledge-form-section-header strong {
    color: #273142;
    font-size: 14px;
}

.knowledge-form-section-header span {
    color: #8993a4;
    font-size: 10px;
}

.knowledge-type-code {
    margin-bottom: 12px;
    color: #667085;
    font-family: Consolas, "Courier New", monospace;
    font-size: 10px;
}

.knowledge-rule-grid label > span {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 11px;
    font-weight: 600;
}

.knowledge-rule-grid label em {
    color: var(--danger);
    font-style: normal;
}

.knowledge-rule-grid label small {
    display: block;
    margin-top: 5px;
    color: #8993a4;
    font-size: 9px;
}

.knowledge-status-toggle {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    margin-top: 13px;
    color: #344054;
    font-size: 11px;
    cursor: pointer;
}

.knowledge-status-toggle input,
.knowledge-field-checkbox {
    width: 16px;
    height: 16px;
    margin: 0;
    accent-color: #3470e4;
    cursor: pointer;
}

.knowledge-field-tabs {
    display: flex;
    gap: 4px;
    border-bottom: 1px solid #dfe4ec;
}

.knowledge-field-toolbar {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid #dfe4ec;
}

.knowledge-field-toolbar .knowledge-field-tabs {
    border-bottom: 0;
}

.knowledge-field-toolbar-actions {
    margin-bottom: 5px;
    display: flex;
    align-items: center;
    gap: 7px;
}

.knowledge-field-add-button,
.knowledge-field-restore-button {
    min-height: 32px;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
}

.knowledge-field-add-button {
    border: 1px solid #3470e4;
    color: #fff;
    background: #3470e4;
    box-shadow: 0 4px 10px rgba(52, 112, 228, 0.16);
}

.knowledge-field-add-button:hover {
    border-color: #245fc7;
    background: #245fc7;
}

.knowledge-field-restore-button {
    border: 1px solid #cfd8e6;
    color: #475467;
    background: #fff;
}

.knowledge-field-restore-button[hidden] {
    display: none;
}

.knowledge-field-development-notice {
    margin: 0 0 9px;
    padding: 8px 10px;
    display: flex;
    align-items: flex-start;
    gap: 7px;
    border: 1px solid #dbe7fa;
    border-radius: 6px;
    color: #53657d;
    background: #f7faff;
    font-size: 10px;
    line-height: 1.55;
}

.knowledge-field-development-notice i {
    margin-top: 1px;
    color: #3470e4;
}

.knowledge-field-tabs button {
    min-height: 35px;
    padding: 0 14px;
    border: 0;
    border-bottom: 2px solid transparent;
    background: transparent;
    color: #667085;
    font-size: 11px;
    cursor: pointer;
}

.knowledge-field-tabs button.is-active {
    border-bottom-color: #3470e4;
    color: #245fc7;
    font-weight: 600;
}

.knowledge-field-tabs b {
    display: inline-flex;
    min-width: 18px;
    height: 18px;
    align-items: center;
    justify-content: center;
    margin-left: 4px;
    border-radius: 9px;
    background: #eef3fb;
    font-size: 9px;
}

.knowledge-field-table-wrap {
    max-height: 410px;
    overflow: auto;
    border: 1px solid #dfe4ec;
}

.knowledge-field-table {
    width: 100%;
    min-width: 1000px;
    table-layout: fixed;
    border-collapse: collapse;
}

.knowledge-field-table th,
.knowledge-field-table td {
    padding: 8px 9px;
    border-bottom: 1px solid #edf0f4;
    color: #475467;
    font-size: 11px;
    text-align: left;
    vertical-align: middle;
}

.knowledge-field-table th {
    position: sticky;
    z-index: 1;
    top: 0;
    background: #f8fafc;
    color: #344054;
    font-weight: 600;
}

.knowledge-field-table th:nth-child(1) { width: 145px; }
.knowledge-field-table th:nth-child(2) { width: 170px; }
.knowledge-field-table th:nth-child(3) { width: 112px; }
.knowledge-field-table th:nth-child(4) { width: 82px; }
.knowledge-field-table th:nth-child(5),
.knowledge-field-table th:nth-child(6),
.knowledge-field-table th:nth-child(7) { width: 58px; }
.knowledge-field-table th:nth-child(8) { width: 70px; }
.knowledge-field-table th:nth-child(9) { width: 100px; }

.knowledge-field-table th:nth-child(5),
.knowledge-field-table th:nth-child(6),
.knowledge-field-table th:nth-child(7),
.knowledge-field-table td:nth-child(5),
.knowledge-field-table td:nth-child(6),
.knowledge-field-table td:nth-child(7) {
    text-align: center;
}

.knowledge-field-input {
    width: 100%;
    min-width: 0;
    height: 32px;
    font-size: 10px;
}

.knowledge-field-input.is-invalid {
    border-color: var(--danger);
    box-shadow: 0 0 0 2px rgba(217, 45, 32, 0.1);
}

.knowledge-field-code-input {
    color: #344054;
    font-family: Consolas, "Courier New", monospace;
}

.knowledge-field-type-select {
    width: 100%;
    height: 32px;
    padding: 0 28px 0 9px;
    border: 1px solid #d7deea;
    border-radius: 4px;
    color: #344054;
    background: #fff;
    font-size: 11px;
}

.knowledge-field-table tr.is-new td {
    background: #f7fbff;
}

.knowledge-field-table tr.is-new td:first-child {
    box-shadow: inset 3px 0 #3470e4;
}

.knowledge-field-row-actions {
    display: flex;
    align-items: center;
    gap: 6px;
}

.field-toggle {
    position: relative;
    width: 34px;
    height: 18px;
    padding: 0;
    border: 0;
    border-radius: 9px;
    background: #c7ced8;
    cursor: pointer;
    transition: background-color 0.18s ease;
}

.field-toggle span {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.25);
    transition: transform 0.18s ease;
}

.field-toggle.is-on {
    background: #3470e4;
}

.field-toggle.is-on span {
    transform: translateX(16px);
}

.field-toggle:focus-visible {
    outline: 2px solid #91b4f8;
    outline-offset: 2px;
}

.knowledge-field-restore-list {
    max-height: 420px;
    padding: 12px;
    display: grid;
    gap: 8px;
    overflow: auto;
}

.knowledge-field-restore-list button {
    min-height: 54px;
    padding: 9px 12px;
    display: flex;
    align-items: flex-start;
    flex-direction: column;
    gap: 3px;
    border: 1px solid var(--border);
    border-radius: 5px;
    background: #fff;
    text-align: left;
    cursor: pointer;
}

.knowledge-field-restore-list button:hover {
    border-color: #8e83ee;
    background: #faf9ff;
}

.knowledge-field-restore-list strong {
    color: #273142;
    font-size: 12px;
}

.knowledge-field-restore-list small {
    color: #667085;
    font-size: 10px;
}

.knowledge-field-option-layer {
    padding: 18px 20px 14px;
}

.knowledge-field-option-layer p {
    margin: 0 0 9px;
    color: #667085;
    font-size: 11px;
}

.knowledge-field-option-layer textarea {
    min-height: 190px;
    resize: vertical;
    font-family: Consolas, "Courier New", monospace;
    font-size: 11px;
    line-height: 1.65;
}

.knowledge-field-code {
    color: #596579;
    font-family: Consolas, "Courier New", monospace;
    font-size: 9px;
    white-space: nowrap;
}

.knowledge-configuration-form .modal-actions {
    position: sticky;
    z-index: 2;
    bottom: -14px;
    background: #fff;
}

.knowledge-filter-form {
    grid-template-columns: minmax(320px, 400px) 170px 170px 140px auto auto;
}

.knowledge-type-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}

#add-knowledge-library-button[hidden],
.knowledge-type-grid[hidden] {
    display: none !important;
}

.knowledge-type-grid > .table-empty {
    grid-column: 1 / -1;
    margin: 0;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.knowledge-type-card {
    min-height: 220px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.knowledge-type-card.is-active {
    border-color: #8e83ee;
    box-shadow: 0 0 0 2px #ece9ff;
}

.knowledge-type-card.is-empty {
    background: #fbfcfe;
}

.knowledge-type-card > header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.knowledge-type-icon {
    display: inline-flex;
    width: 38px;
    height: 38px;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    font-size: 18px;
}

.knowledge-type-icon.tone-0 { color: #2563eb; background: #eaf1ff; }
.knowledge-type-icon.tone-1 { color: #7e22ce; background: #f5eaff; }
.knowledge-type-icon.tone-2 { color: #087f5b; background: #e8f8f2; }
.knowledge-type-card h2 { margin: 14px 0 0; font-size: 16px; }
.knowledge-type-card > p { min-height: 36px; margin: 6px 0 0; color: var(--text-soft); font-size: 10px; line-height: 1.6; }
.knowledge-type-card dl { margin: 12px 0; padding: 9px 0; display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid #edf0f4; border-bottom: 1px solid #edf0f4; }
.knowledge-type-card dl div { display: flex; flex-direction: column; gap: 3px; }
.knowledge-type-card dt { color: var(--text-soft); font-size: 9px; }
.knowledge-type-card dd { margin: 0; font-size: 10px; font-weight: 600; }
.knowledge-type-card > button { width: 100%; height: 34px; margin-top: auto; border-radius: 5px; cursor: pointer; }

.knowledge-detail-panel { overflow: hidden; }
.knowledge-detail-heading { min-height: 74px; padding: 14px 16px; display: flex; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--border); }
.knowledge-detail-heading > div { display: flex; align-items: center; gap: 10px; }
.knowledge-detail-heading > div:last-child { flex-wrap: wrap; justify-content: flex-end; }
.knowledge-detail-icon { display: inline-flex; width: 40px; height: 40px; align-items: center; justify-content: center; border-radius: 6px; color: #5949e8; background: #eeecff; font-size: 19px; }
.knowledge-detail-heading h2, .knowledge-detail-heading p { margin: 0; }
.knowledge-detail-heading h2 { font-size: 15px; }
.knowledge-detail-heading p { margin-top: 4px; color: var(--text-soft); font-size: 9px; }
.knowledge-detail-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 14px 16px; border-bottom: 1px solid var(--border); background: #fbfcfe; }
.knowledge-detail-summary > div { padding: 0 14px; display: flex; flex-direction: column; gap: 4px; border-right: 1px solid var(--border); }
.knowledge-detail-summary > div:first-child { padding-left: 0; }
.knowledge-detail-summary > div:last-child { border-right: 0; }
.knowledge-detail-summary small { color: var(--text-soft); font-size: 9px; }
.knowledge-detail-summary strong { font-size: 11px; }
.knowledge-children-section > header { padding: 14px 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.knowledge-children-section h3, .knowledge-children-section p { margin: 0; }
.knowledge-children-section h3 { font-size: 13px; }
.knowledge-children-section p { margin-top: 3px; color: var(--text-soft); font-size: 9px; }
.knowledge-child-table { min-width: 760px; }
.knowledge-child-table th:first-child, .knowledge-child-table td:first-child { padding-left: 16px; }
.knowledge-type-layer, .knowledge-items-browser-layer { padding: 18px 20px 14px; }
.knowledge-type-choice { display: grid; grid-template-columns: 1fr; gap: 10px; }
.knowledge-type-choice-row { min-height: 76px; padding: 12px 14px; display: grid; grid-template-columns: 40px minmax(0, 1fr) auto 18px; align-items: center; gap: 12px; border: 1px solid var(--border); border-radius: 7px; background: #fff; text-align: left; cursor: pointer; transition: border-color 0.16s ease, background-color 0.16s ease, transform 0.16s ease; }
.knowledge-type-choice-row:hover:not(:disabled) { border-color: #8e83ee; background: #faf9ff; transform: translateY(-1px); }
.knowledge-type-choice-row:disabled { cursor: default; opacity: 0.72; }
.knowledge-type-choice-icon { width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; border-radius: 7px; font-size: 19px; }
.knowledge-type-choice-icon.tone-0 { color: #2563eb; background: #eaf1ff; }
.knowledge-type-choice-icon.tone-1 { color: #7e22ce; background: #f5eaff; }
.knowledge-type-choice-icon.tone-2 { color: #087f5b; background: #e8f8f2; }
.knowledge-type-choice-content { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.knowledge-type-choice-content strong { color: #273142; font-size: 13px; }
.knowledge-type-choice-content small { color: #667085; font-size: 10px; line-height: 1.5; }
.knowledge-type-choice-state { padding: 3px 8px; border-radius: 4px; color: #245fc7; background: #edf4ff; font-size: 10px; }
.knowledge-type-choice-state.is-created { color: #087f5b; background: #e8f8f2; }
.knowledge-type-choice-row > .layui-icon-right { color: #98a2b3; font-size: 14px; }
.knowledge-items-browser-heading { margin-bottom: 12px; }
.knowledge-items-browser-heading h3, .knowledge-items-browser-heading p { margin: 0; }
.knowledge-items-browser-heading h3 { font-size: 14px; }
.knowledge-items-browser-heading p { margin-top: 4px; color: var(--text-soft); font-size: 9px; }
.user-knowledge-table { min-width: 1220px; }

.knowledge-library-table {
    min-width: 1080px;
}

.layui-layer-page.knowledge-library-form-layer .layui-layer-content {
    height: 100%;
    overflow: hidden;
}

.knowledge-library-layer {
    height: 100%;
    max-height: none;
    padding: 0;
    overflow: hidden;
    box-sizing: border-box;
}

.knowledge-library-form {
    height: 100%;
    min-height: 0;
    padding: 20px 24px 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
    box-sizing: border-box;
}

.knowledge-item-layer {
    max-height: calc(100vh - 90px);
    padding: 18px 20px 14px;
    overflow-y: auto;
    box-sizing: border-box;
}

.knowledge-library-basic-grid label > span,
.knowledge-item-meta-grid label > span,
.knowledge-dynamic-field > span {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 11px;
    font-weight: 600;
}

.knowledge-library-basic-grid label em,
.knowledge-required-mark {
    margin-left: 3px;
    color: var(--danger);
    font-style: normal;
}

.knowledge-form-invalid {
    border-color: var(--danger) !important;
    box-shadow: 0 0 0 2px rgba(198, 44, 44, 0.1) !important;
}

.knowledge-library-basic-grid select,
.knowledge-dynamic-field select {
    width: 100%;
    height: 38px;
    padding: 0 32px 0 10px;
    border: 1px solid #d7deea;
    border-radius: 4px;
    background: #fff;
    color: #344054;
    font-size: 11px;
}

.knowledge-library-basic-grid select:disabled {
    background: #f4f6f8;
    color: #98a2b3;
}

.knowledge-dynamic-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 13px 14px;
}

.knowledge-dynamic-field:has(textarea) {
    grid-column: 1 / -1;
}

.knowledge-dynamic-fields[data-knowledge-type="enterprise"] .knowledge-dynamic-field[data-field-code="address"] {
    grid-column: 1 / -1;
}

.knowledge-dynamic-field textarea {
    min-height: 105px;
    resize: vertical;
    line-height: 1.6;
}

.knowledge-inline-toggle {
    display: inline-flex;
    min-height: 38px;
    align-items: center;
    gap: 7px;
    color: #475467;
    font-size: 11px;
}

.knowledge-inline-toggle input {
    width: 16px;
    height: 16px;
    margin: 0;
    accent-color: #3470e4;
}

.knowledge-image-upload {
    display: grid;
    min-height: 82px;
    grid-template-columns: 64px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 9px;
    border: 1px dashed #b8c4d6;
    border-radius: 6px;
    background: #f8fafc;
}

.knowledge-image-upload.is-uploading {
    opacity: 0.72;
}

.knowledge-image-preview {
    display: inline-flex;
    width: 64px;
    height: 64px;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 6px;
    background: #e8eef7;
    color: #8190a5;
    font-size: 24px;
}

.knowledge-image-preview img {
    display: none;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #fff;
}

.knowledge-image-preview.has-image img {
    display: block;
}

.knowledge-image-preview.has-image i {
    display: none;
}

.knowledge-image-content {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 4px;
}

.knowledge-image-content strong {
    color: #344054;
    font-size: 11px;
}

.knowledge-image-content small {
    color: #8993a4;
    font-size: 9px;
    line-height: 1.5;
}

.knowledge-image-picker {
    position: relative;
    min-width: 82px;
    overflow: hidden;
    cursor: pointer;
}

.knowledge-image-picker input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
}

.knowledge-fields-empty {
    grid-column: 1 / -1;
    margin: 0;
    padding: 22px;
    border: 1px dashed #d7deea;
    color: #8993a4;
    font-size: 11px;
    text-align: center;
}

.knowledge-fields-empty.error {
    border-color: #f3c5c5;
    color: var(--danger);
}

.knowledge-items-section .knowledge-form-section-header {
    align-items: center;
}

.knowledge-item-table-wrap {
    max-height: 260px;
    overflow: auto;
    border: 1px solid #dfe4ec;
}

.knowledge-item-table-wrap .knowledge-field-table {
    min-width: 680px;
}

.knowledge-library-form .modal-actions {
    position: sticky;
    z-index: 3;
    bottom: 0;
    margin: 18px -24px 0;
    padding: 12px 24px 14px;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 -8px 20px rgba(31, 44, 68, 0.06);
}

.knowledge-item-form .modal-actions {
    position: sticky;
    z-index: 2;
    bottom: -14px;
    background: #fff;
}

.knowledge-item-status-row {
    display: flex;
    justify-content: flex-start;
    margin-top: 22px;
    padding: 16px 0 20px;
    border-top: 1px solid #edf0f4;
}

.knowledge-item-status-switch > span:first-child {
    margin-right: 4px;
    color: #344054;
    font-size: 11px;
    font-weight: 600;
}

.keyword-library-filters {
    display: grid;
    grid-template-columns: minmax(300px, 380px) 180px 150px auto auto;
    justify-content: start;
    gap: 10px;
    margin-bottom: 14px;
}

.keyword-workspace {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    min-height: 0;
    border: 1px solid #e0e5ec;
}

.keyword-library-pane {
    border-right: 1px solid #e0e5ec;
    background: #f8fafc;
}

.keyword-library-pane > header {
    padding: 16px;
    border-bottom: 1px solid #e0e5ec;
}

.keyword-library-pane > header div {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.keyword-library-pane > header strong {
    color: #273142;
    font-size: 13px;
}

.keyword-library-pane > header span {
    color: #8993a4;
    font-size: 10px;
}

.keyword-library-list {
    max-height: 550px;
    overflow: auto;
    padding: 8px;
}

.keyword-library-entry {
    display: flex;
    width: 100%;
    align-items: center;
    gap: 5px;
    padding: 4px;
    border: 1px solid transparent;
    border-radius: 5px;
    background: transparent;
    text-align: left;
}

.keyword-library-entry:hover,
.keyword-library-entry.is-active {
    border-color: #cddaf3;
    background: #edf3ff;
}

.keyword-library-select {
    display: grid;
    min-width: 0;
    flex: 1 1 auto;
    grid-template-columns: 34px minmax(0, 1fr);
    align-items: center;
    gap: 9px;
    padding: 7px 5px;
    border: 0;
    background: transparent;
    text-align: left;
    cursor: pointer;
}

.keyword-library-controls {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 4px;
}

.keyword-library-edit,
.keyword-library-delete {
    display: inline-flex;
    width: 27px;
    height: 27px;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 1px solid #d7deea;
    border-radius: 4px;
    color: #667085;
    background: #fff;
    cursor: pointer;
}

.keyword-library-edit:hover {
    color: var(--primary);
    border-color: #aabce0;
}

.keyword-library-delete:hover {
    color: var(--danger);
    border-color: #e4aaa5;
    background: #fff6f5;
}

.keyword-library-icon {
    display: inline-flex;
    width: 32px;
    height: 32px;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    background: #dce8fd;
    color: #3470e4;
}

.keyword-library-text {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.keyword-library-text strong {
    overflow: hidden;
    color: #273142;
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.keyword-library-text small {
    overflow: hidden;
    color: #8993a4;
    font-size: 9px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.keyword-item-pane {
    min-width: 0;
    padding: 18px;
}

.keyword-empty-notice {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 14px;
    border: 1px solid #d8e3f5;
    border-radius: 5px;
    color: #667085;
    background: #f7faff;
}

.keyword-empty-notice[hidden] {
    display: none;
}

.keyword-manager-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 15px;
}

.keyword-manager-header h2,
.keyword-manager-header p {
    margin: 0;
}

.keyword-manager-header h2 {
    color: #273142;
    font-size: 16px;
}

.keyword-manager-header p {
    margin-top: 4px;
    color: #8993a4;
    font-size: 10px;
}

.keyword-manager-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.keyword-item-filters {
    display: grid;
    grid-template-columns: minmax(260px, 340px) 140px 130px auto;
    justify-content: start;
    gap: 9px;
    margin-bottom: 12px;
}

.keyword-selection-bar {
    margin-bottom: 12px;
    padding: 12px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border: 1px solid #d9e2f0;
    border-radius: 6px;
    background: #f8fafc;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.keyword-selection-bar[hidden] {
    display: none;
}

.keyword-selection-main {
    display: flex;
    min-width: 0;
    align-items: flex-start;
    flex: 1 1 auto;
    flex-direction: row !important;
    gap: 10px !important;
}

.keyword-selection-icon {
    width: 30px;
    height: 30px;
    display: inline-flex;
    flex: 0 0 30px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #2563eb;
    background: #eaf1ff;
    font-size: 17px;
}

.keyword-selection-main > div {
    min-width: 0;
}

.keyword-selection-main strong {
    display: block;
    color: #273142;
    font-size: 12px;
    line-height: 1.4;
}

.keyword-selection-main strong b {
    color: #2563eb;
}

.keyword-selection-main small {
    display: block;
    margin-top: 2px;
    color: #667085;
    font-size: 10px;
}

.keyword-selection-actions {
    display: flex !important;
    flex: 0 0 auto;
    align-items: center;
    flex-direction: row !important;
    gap: 8px !important;
}

#clear-keyword-selection {
    height: 34px;
    padding: 0 10px;
    border: 1px solid transparent;
    border-radius: 4px;
    color: #475467;
    background: transparent;
    font-size: 11px;
    cursor: pointer;
}

#clear-keyword-selection:hover {
    border-color: #d5dce7;
    background: #fff;
}

#create-title-task-button {
    height: 36px;
    margin: 0;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: #fff;
    font-size: 12px;
    line-height: 1;
}

#keyword-selection-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}

.keyword-selection-chip {
    max-width: 220px;
    height: 26px;
    padding: 0 7px 0 9px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    overflow: hidden;
    border: 1px solid #d9e2f0;
    border-radius: 13px;
    color: #344054;
    background: #fff;
    font-size: 10px;
    cursor: pointer;
}

.keyword-selection-chip span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.keyword-selection-chip i {
    color: #98a2b3;
    font-size: 12px;
}

.keyword-selection-chip:hover {
    border-color: #9cb8ee;
    color: #245fc7;
}

.keyword-check-column {
    width: 58px;
    text-align: center !important;
}

.keyword-check-column input {
    width: 16px;
    height: 16px;
    accent-color: #5949e8;
}

.keyword-item-table {
    min-width: 760px;
}

.keyword-library-layer,
.keyword-item-layer,
.keyword-import-layer,
.keyword-task-layer {
    padding: 20px;
}

.keyword-library-form > label:not(.knowledge-status-toggle),
.keyword-item-form > label:not(.knowledge-status-toggle) {
    display: block;
    margin-bottom: 14px;
}

.keyword-library-form label > span,
.keyword-item-form label > span {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 11px;
    font-weight: 600;
}

.keyword-library-form label em,
.keyword-item-form label em {
    color: var(--danger);
    font-style: normal;
}

.keyword-field-help {
    display: block;
    margin-top: 6px;
    color: #8993a4;
    font-size: 11px;
    line-height: 1.5;
}

.keyword-form-error {
    margin: 0 0 14px;
    padding: 9px 11px;
    border: 1px solid #f4c7c3;
    border-radius: 6px;
    color: var(--danger);
    background: #fff5f4;
    font-size: 12px;
    line-height: 1.5;
}

.keyword-form-error[hidden] { display: none; }

.keyword-library-form select,
.keyword-item-form select {
    width: 100%;
    height: 38px;
    padding: 0 10px;
    border: 1px solid #d7deea;
    border-radius: 4px;
    background: #fff;
}

.keyword-item-form textarea {
    min-height: 170px;
    resize: vertical;
}

.keyword-item-form label small {
    display: block;
    margin-top: 6px;
    color: #8993a4;
    font-size: 9px;
}

.keyword-import-form > label:not(.knowledge-status-toggle) {
    display: block;
    margin-bottom: 14px;
}

.keyword-import-form label > span {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 11px;
    font-weight: 600;
}

.keyword-import-form label em {
    color: var(--danger);
    font-style: normal;
}

.keyword-import-form select {
    width: 100%;
    height: 38px;
    padding: 0 10px;
    border: 1px solid #d7deea;
    border-radius: 4px;
    background: #fff;
}

.keyword-file-picker input {
    width: 100%;
    padding: 9px;
    border: 1px dashed #aebbd0;
    border-radius: 5px;
    background: #f8fafc;
    font-size: 10px;
}

.keyword-file-picker small {
    display: block;
    margin-top: 6px;
    color: #8993a4;
    font-size: 9px;
}

.keyword-task-layer-heading {
    min-height: 48px;
    margin: -4px 0 10px;
    padding: 0 0 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
}

.keyword-task-layer-heading > div {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.keyword-task-layer-heading strong { font-size: 13px; }
.keyword-task-layer-heading span { color: var(--text-soft); font-size: 11px; }
.keyword-task-layer-heading button { width: 32px; height: 32px; padding: 0; border: 1px solid var(--border); border-radius: 4px; color: var(--primary); background: #fff; cursor: pointer; }
#keyword-import-task-list { min-height: 120px; max-height: calc(100vh - 270px); padding: 0 2px; overflow: auto; }
#keyword-import-task-list .table-empty { height: 60px; margin: 0; }
.keyword-task-card { min-height: 76px; padding: 12px 8px; display: grid; grid-template-columns: minmax(220px, 1.1fr) minmax(240px, 1fr) auto; align-items: center; gap: 14px; border-bottom: 1px solid #edf0f4; }
.keyword-task-card:last-child { border-bottom: 0; }
.keyword-task-info { display: flex; min-width: 0; flex-direction: column; gap: 5px; }
.keyword-task-info strong { overflow: hidden; color: var(--text); font-size: 13px; line-height: 1.45; text-overflow: ellipsis; white-space: nowrap; }
.keyword-task-info small, .keyword-task-counts { color: var(--text-soft); font-size: 11px; line-height: 1.45; }
.keyword-task-progress-cell { display: flex; min-width: 0; flex-direction: column; gap: 6px; }
.keyword-task-progress-label { display: flex; align-items: center; justify-content: space-between; color: var(--text-soft); font-size: 11px; }
.keyword-task-progress-label strong { color: var(--text); font-size: 11px; font-weight: 600; }
.keyword-task-progress { height: 6px; overflow: hidden; border-radius: 3px; background: #edf0f5; }
.keyword-task-progress span { display: block; height: 100%; border-radius: inherit; background: #5949e8; }
.keyword-task-state { justify-self: end; white-space: nowrap; }
.keyword-task-error { grid-column: 1 / -1; margin: -4px 0 0; padding: 7px 9px; border-radius: 4px; color: #b42318; background: #fff2f0; font-size: 11px; line-height: 1.5; }
@media (max-width: 620px) {
    .keyword-task-layer { padding: 16px; }
    .keyword-task-layer > .modal-actions { margin: 0 -16px -16px; padding: 10px 16px; }
    .keyword-task-card { grid-template-columns: minmax(0, 1fr) auto; gap: 10px 12px; }
    .keyword-task-progress-cell { grid-column: 1 / -1; grid-row: 2; }
    .keyword-task-state { grid-column: 2; grid-row: 1; }
}
.user-asset-filter { display: grid; grid-template-columns: minmax(300px, 380px) 160px auto auto; justify-content: start; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--border); }
.user-keyword-table { min-width: 1140px; }

.media-account-filter {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 12px;
}

.media-account-filter label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #475467;
    font-size: 10px;
}

.media-account-filter select {
    min-width: 260px;
    height: 36px;
    padding: 0 10px;
    border: 1px solid #d7deea;
    border-radius: 4px;
    background: #fff;
}

.media-workspace {
    display: grid;
    grid-template-columns: 230px minmax(0, 1fr);
    min-height: 610px;
    border: 1px solid #e0e5ec;
}

.media-category-pane {
    border-right: 1px solid #e0e5ec;
    background: #f8fafc;
}

.media-category-pane > header {
    display: flex;
    min-height: 52px;
    align-items: center;
    justify-content: space-between;
    padding: 0 12px 0 14px;
    border-bottom: 1px solid #e0e5ec;
}

.media-category-pane > header div {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.media-category-pane > header strong {
    color: #273142;
    font-size: 12px;
}

.media-category-pane > header span {
    color: #8993a4;
    font-size: 9px;
}

.media-category-pane > header button {
    display: inline-flex;
    width: 30px;
    height: 30px;
    align-items: center;
    justify-content: center;
    border: 1px solid #d7deea;
    border-radius: 4px;
    background: #fff;
    color: #3470e4;
    cursor: pointer;
}

.media-category-list {
    padding: 8px;
}

.media-category-entry {
    display: grid;
    width: 100%;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    gap: 7px;
    padding: 9px 8px;
    border: 1px solid transparent;
    border-radius: 4px;
    background: transparent;
    color: #475467;
    font-size: 10px;
    text-align: left;
    cursor: pointer;
}

.media-category-entry:hover,
.media-category-entry.is-active {
    border-color: #cddaf3;
    background: #edf3ff;
    color: #245fc7;
}

.media-category-entry span b {
    margin-left: 5px;
    color: #22a06b;
    font-size: 8px;
}

.media-category-entry small {
    color: #8993a4;
}

.media-category-entry i {
    color: #8993a4;
    font-size: 13px;
}

.media-asset-pane {
    min-width: 0;
    padding: 16px;
}

.media-asset-filters {
    display: grid;
    grid-template-columns: minmax(280px, 360px) 140px auto auto;
    justify-content: start;
    gap: 9px;
    margin-bottom: 14px;
}

.media-asset-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
    gap: 12px;
    min-height: 480px;
    align-content: start;
}

.media-asset-card {
    overflow: hidden;
    padding: 0;
    border: 1px solid #dfe4ec;
    border-radius: 6px;
    background: #fff;
    text-align: left;
    cursor: pointer;
}

.media-asset-card:hover {
    border-color: #9eb9ea;
    box-shadow: 0 4px 12px rgb(30 64 175 / 8%);
}

.media-asset-card.is-disabled {
    opacity: 0.62;
}

.media-asset-image {
    display: block;
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #eef1f5;
}

.media-asset-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.media-asset-info {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
    padding: 9px 10px 6px;
}

.media-asset-info strong,
.media-asset-info small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.media-asset-info strong {
    color: #273142;
    font-size: 10px;
}

.media-asset-info small {
    color: #8993a4;
    font-size: 8px;
}

.media-asset-card > .status-badge {
    margin: 0 10px 10px;
}

.media-assets-empty {
    grid-column: 1 / -1;
    align-self: center;
    color: #98a2b3;
    font-size: 11px;
    text-align: center;
}

.media-category-layer,
.media-upload-layer,
.media-asset-layer {
    padding: 20px;
}

.media-asset-layer {
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}

.media-category-form > label,
.media-upload-form > label,
.media-asset-form > label:not(.knowledge-status-toggle) {
    display: block;
    margin-bottom: 14px;
}

.media-category-form label > span,
.media-upload-form label > span,
.media-asset-form label > span {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 11px;
    font-weight: 600;
}

.media-category-form label em,
.media-upload-form label em {
    color: var(--danger);
    font-style: normal;
}

.media-category-form textarea {
    min-height: 90px;
}

.media-category-form select,
.media-upload-form select,
.media-asset-form select {
    width: 100%;
    height: 38px;
    padding: 0 10px;
    border: 1px solid #d7deea;
    border-radius: 4px;
    background: #fff;
}

.media-toggle-row {
    display: flex;
    gap: 24px;
}

.media-file-picker input {
    width: 100%;
    padding: 9px;
    border: 1px dashed #aebbd0;
    border-radius: 5px;
    background: #f8fafc;
    font-size: 10px;
}

.media-file-picker small {
    display: block;
    margin-top: 6px;
    color: #8993a4;
    font-size: 9px;
}

.media-asset-preview {
    display: flex;
    max-height: 330px;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
    overflow: hidden;
    border: 1px solid #dfe4ec;
    background: #f4f6f8;
}

.media-asset-preview img {
    max-width: 100%;
    max-height: 330px;
    object-fit: contain;
}

.media-reference-note {
    margin: 12px 0;
    color: #667085;
    font-size: 9px;
}

.media-upload-layer {
    width: auto;
}

.media-crop-workspace {
    margin-bottom: 14px;
    border: 1px solid #dfe4ec;
    border-radius: 6px;
    background: #f8fafc;
}

.media-crop-toolbar {
    display: flex;
    min-height: 50px;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
    border-bottom: 1px solid #dfe4ec;
}

.media-crop-toolbar > span {
    flex: 0 0 auto;
    color: #344054;
    font-size: 10px;
    font-weight: 600;
}

.media-ratio-options {
    display: flex;
    flex: 1;
    flex-wrap: wrap;
    gap: 6px;
}

.media-ratio-options button,
.media-crop-reset {
    min-width: 48px;
    height: 30px;
    padding: 0 10px;
    border: 1px solid #d6dce7;
    border-radius: 4px;
    color: #475467;
    background: #fff;
    font-size: 9px;
    cursor: pointer;
}

.media-ratio-options button:hover,
.media-ratio-options button.is-active {
    border-color: #7568e8;
    color: #5144c8;
    background: #f1efff;
}

.media-ratio-options.is-disabled {
    pointer-events: none;
    opacity: 0.45;
}

.media-crop-reset {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.media-crop-stage {
    height: min(48vh, 430px);
    min-height: 280px;
    overflow: hidden;
    background: #273142;
}

.media-crop-stage img {
    display: block;
    max-width: 100%;
}

.media-crop-workspace > p {
    margin: 0;
    padding: 8px 12px;
    color: #667085;
    font-size: 9px;
}

.media-upload-fields {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 12px;
}

.media-upload-fields label {
    display: block;
    margin-bottom: 0;
}

.media-upload-fields label > span {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 11px;
    font-weight: 600;
}

.user-media-table {
    min-width: 1240px;
}

.user-media-thumbnail {
    display: block;
    width: 72px;
    height: 48px;
    overflow: hidden;
    padding: 0;
    border: 1px solid #dfe4ec;
    border-radius: 4px;
    background: #f4f6f8;
    cursor: zoom-in;
}

.user-media-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-media-table td:nth-child(5) {
    max-width: 260px;
}

.user-media-table .table-primary,
.user-media-table .table-secondary {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-media-table .table-primary {
    color: #273142;
    font-size: 10px;
}

.user-media-table .table-secondary {
    margin-top: 3px;
    color: #8993a4;
    font-size: 8px;
}

.user-media-original {
    display: flex;
    height: 100%;
    min-height: 320px;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
    overflow: auto;
    background: #202631;
}

.user-media-preview-layer {
    height: 100%;
    padding: 0;
}

.user-media-original img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.compact-status-switch {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    user-select: none;
}

.compact-status-switch.is-pending {
    cursor: wait;
    opacity: 0.68;
}

.compact-status-switch input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.compact-status-switch-track {
    position: relative;
    width: 34px;
    height: 18px;
    flex: 0 0 34px;
    border-radius: 9px;
    background: #c7ced8;
    transition: background-color 0.18s ease;
}

.compact-status-switch-track::after {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.28);
    content: '';
    transition: transform 0.18s ease;
}

.compact-status-switch input:checked + .compact-status-switch-track {
    background: #3470e4;
}

.compact-status-switch input:checked + .compact-status-switch-track::after {
    transform: translateX(16px);
}

.compact-status-switch input:focus-visible + .compact-status-switch-track {
    outline: 2px solid #91b4f8;
    outline-offset: 2px;
}

.compact-status-switch input:disabled + .compact-status-switch-track {
    opacity: 0.6;
}

.compact-status-switch small {
    min-width: 24px;
    color: #667085;
    font-size: 10px;
}

.form-status-switch {
    width: fit-content;
    min-height: 40px;
    padding: 8px 12px;
    border: 1px solid #e0e6ef;
    border-radius: 8px;
    background: #f8fafc;
}

.form-status-switch > .form-status-switch-label {
    color: #344054;
    font-size: 13px;
    font-weight: 600;
}

.page-heading-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sensitive-detection-control {
    min-height: 86px;
    margin-bottom: 14px;
    padding: 15px 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    border: 1px solid #bdd7c8;
    border-radius: 10px;
    background: linear-gradient(135deg, #f3fbf6 0%, #f8fcfa 100%);
    transition: 160ms ease;
}

.sensitive-detection-control.is-off {
    border-color: #efcf9f;
    background: #fff9ef;
}

.sensitive-detection-control.is-disabled,
.sensitive-detection-control.is-pending {
    opacity: 0.72;
}

.sensitive-detection-copy {
    display: flex;
    align-items: center;
    gap: 13px;
}

.sensitive-detection-icon {
    width: 42px;
    height: 42px;
    display: grid;
    flex: 0 0 42px;
    place-items: center;
    border-radius: 9px;
    background: #dff3e7;
    color: #198754;
    font-size: 20px;
}

.sensitive-detection-copy strong {
    color: #172033;
    font-size: 14px;
}

.sensitive-detection-copy p {
    margin: 4px 0 3px;
    color: #475467;
    font-size: 12px;
}

.sensitive-detection-copy small {
    color: #7b8798;
    font-size: 10px;
}

.sensitive-detection-switch {
    flex: 0 0 auto;
}

.sensitive-filter-form {
    display: grid;
    grid-template-columns: minmax(240px, 360px) 150px 130px auto auto;
    justify-content: start;
    gap: 10px;
    padding: 14px;
    border-bottom: 1px solid var(--border);
}

.sensitive-table {
    min-width: 860px;
    font-size: 12px;
}

.sensitive-table th,
.sensitive-table td {
    padding-top: 13px;
    padding-bottom: 13px;
}

.sensitive-word-text {
    color: #172033;
    font-size: 13px;
    font-weight: 600;
}

.sensitive-remark {
    max-width: 360px;
    overflow: hidden;
    color: #667085;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sensitive-form-switch {
    margin: 4px 0 12px;
}

.sensitive-form-switch em {
    color: #475467;
    font-size: 12px;
    font-style: normal;
}

.sensitive-import-form-layer #sensitive-import-layer {
    height: 100%;
}

.sensitive-import-form-layer #sensitive-import-form {
    min-height: 100%;
    display: flex;
    flex-direction: column;
}

.sensitive-import-form-layer #sensitive-import-form > * {
    flex-shrink: 0;
}

.sensitive-import-form-layer .modal-actions {
    margin-top: auto;
}

.sensitive-import-form-layer .layui-form-select dl {
    max-height: min(300px, calc(100vh - 360px));
}

.sensitive-import-upload-row {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 12px;
}

.sensitive-import-upload-row .layui-btn {
    flex: 0 0 auto;
    margin: 0;
}

.sensitive-import-file-name {
    min-width: 0;
    overflow: hidden;
    color: #667085;
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sensitive-import-file-help {
    display: block;
    margin-top: 7px;
    color: #8a96a8;
    font-size: 11px;
}

.task-modal-toolbar {
    display: flex;
    min-height: 42px;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
    border-bottom: 1px solid var(--border);
    color: #172033;
    font-size: 13px;
    font-weight: 600;
}

.task-modal-toolbar .icon-button {
    width: 32px;
    height: 32px;
    border: 1px solid var(--border);
    border-radius: 4px;
    background: #fff;
    color: var(--primary);
    cursor: pointer;
}

.sensitive-task-layer {
    height: 100%;
    box-sizing: border-box;
}

.sensitive-task-layer .import-task-list {
    max-height: 440px;
    overflow: auto;
}

.import-task-item {
    padding: 13px 4px;
    border-bottom: 1px solid #edf0f4;
}

.import-task-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 7px;
}

.import-task-item p,
.import-task-item small {
    margin: 6px 0;
    color: #667085;
    font-size: 11px;
}

.import-task-progress {
    height: 6px;
    overflow: hidden;
    border-radius: 3px;
    background: #edf0f5;
}

.import-task-progress i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: #3470e4;
}

.token-metric-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}

.token-metric-grid article {
    display: flex;
    min-height: 112px;
    align-items: center;
    gap: 13px;
    padding: 18px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fff;
    box-sizing: border-box;
}

.token-metric-grid article > div {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.token-metric-grid small,
.token-metric-grid em {
    color: #667085;
    font-size: 11px;
    font-style: normal;
}

.token-metric-grid strong {
    color: #172033;
    font-size: 24px;
    font-weight: 650;
    line-height: 1.25;
}

.filter-form.token-filter-form {
    display: flex;
    flex-wrap: wrap;
    padding: 14px;
}

.token-filter-form .search-field { width: 320px; max-width: 100%; flex: 0 1 320px; }
.token-filter-form .layui-form-select { width: 150px; flex: 0 0 150px; }
.token-filter-form .layui-btn { width: auto; margin: 0; flex: 0 0 auto; }
.token-date-field { position: relative; width: 158px; flex: 0 0 158px; }
.token-date-field .layui-input { padding-right: 36px; cursor: pointer; }
.token-date-field .layui-input:focus { border-color: #2f6ff2; box-shadow: 0 0 0 3px rgba(47, 111, 242, .1); }
.token-date-field > i { position: absolute; top: 50%; right: 12px; color: #8592a8; font-size: 17px; transform: translateY(-50%); pointer-events: none; }
.token-date-field:focus-within > i { color: #2f6ff2; }

@media (max-width: 760px) {
    .token-filter-form .search-field { width: 100%; flex-basis: 100%; }
}

@media (max-width: 620px) {
    .token-filter-form .search-field,
    .token-filter-form .layui-form-select,
    .token-filter-form .token-date-field,
    .token-filter-form .layui-btn { width: 100%; min-width: 0; flex-basis: 100%; }
}

.token-trend-section {
    padding: 16px 16px 10px;
    border-bottom: 1px solid var(--border);
}

.token-trend-section > header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 12px;
}

.token-trend-section > header strong {
    color: #172033;
    font-size: 13px;
}

.token-trend-section > header span {
    color: #7a8494;
    font-size: 10px;
}

.token-trend {
    display: flex;
    min-height: 170px;
    align-items: stretch;
    gap: 7px;
    overflow-x: auto;
}

.token-trend-item {
    display: grid;
    min-width: 38px;
    flex: 1 0 38px;
    grid-template-rows: 20px 112px 24px;
    align-items: end;
    text-align: center;
}

.token-trend-item strong {
    overflow: hidden;
    color: #667085;
    font-size: 9px;
    font-weight: 500;
    text-overflow: ellipsis;
}

.token-trend-bar {
    display: flex;
    height: 100%;
    align-items: flex-end;
    justify-content: center;
    border-bottom: 1px solid #dfe5ee;
}

.token-trend-bar i {
    display: block;
    width: min(22px, 70%);
    min-height: 2px;
    border-radius: 3px 3px 0 0;
    background: #3470e4;
}

.token-trend-item small {
    overflow: hidden;
    color: #667085;
    font-size: 8px;
    line-height: 24px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.token-table {
    min-width: 1120px;
    font-size: 11px;
}

.token-total-cell {
    color: #172033;
    font-weight: 650;
}

.token-response-detail {
    width: 100%;
    min-height: 320px;
    padding: 20px;
    box-sizing: border-box;
}

.token-response-meta {
    display: grid;
    margin: 0 0 16px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    border: 1px solid #e1e6ee;
    border-radius: 7px;
}

.token-response-meta div {
    min-width: 0;
    padding: 10px 12px;
    border-right: 1px solid #e6eaf0;
    border-bottom: 1px solid #e6eaf0;
}

.token-response-meta div:nth-child(3n) { border-right: 0; }
.token-response-meta div:nth-last-child(-n+3) { border-bottom: 0; }
.token-response-meta dt { color: #8994a5; font-size: 10px; }
.token-response-meta dd { margin: 4px 0 0; overflow-wrap: anywhere; color: #344054; font-size: 12px; font-weight: 600; }

.token-response-error {
    margin-bottom: 16px;
    padding: 11px 13px;
    border: 1px solid #ffd0cc;
    border-radius: 7px;
    color: #a6342a;
    background: #fff5f4;
    font-size: 12px;
    line-height: 1.6;
}

.token-response-title { display: block; margin-bottom: 8px; color: #344054; font-size: 12px; }

.token-response-body {
    max-height: calc(100vh - 330px);
    margin: 0;
    padding: 14px;
    overflow: auto;
    border: 1px solid #dde3ec;
    border-radius: 7px;
    color: #344054;
    background: #f8fafc;
    font: 11px/1.65 SFMono-Regular, Consolas, monospace;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.operation-log-filter {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 9px;
    padding: 14px;
    border-bottom: 1px solid var(--border);
}

.operation-log-filter .search-field {
    width: min(320px, 100%);
    min-width: 220px;
    flex: 1 1 260px;
}

.operation-log-filter .layui-form-select {
    width: 142px;
    flex: 0 0 142px;
}

.operation-log-filter > input[type="date"] {
    width: 138px;
    flex: 0 0 138px;
}

.operation-log-table {
    min-width: 1120px;
    font-size: 11px;
}

.operation-time-cell {
    white-space: nowrap;
}

.operation-summary-cell {
    max-width: 360px;
    overflow: hidden;
    color: #344054;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.operation-log-detail {
    padding: 18px;
    color: #344054;
}

.layui-layer-page.operation-log-detail-layer .layui-layer-content {
    height: auto !important;
    max-height: calc(100vh - 82px);
}

.operation-log-detail-meta {
    display: grid;
    grid-template-columns: 86px minmax(0, 1fr);
    gap: 8px 12px;
    margin: 0 0 16px;
}

.operation-log-detail-meta dt { color: #8994a5; }
.operation-log-detail-meta dd { margin: 0; overflow-wrap: anywhere; }

.operation-log-detail-section + .operation-log-detail-section { margin-top: 16px; }
.operation-log-detail-section strong { display: block; margin-bottom: 7px; }

.operation-log-detail-section pre {
    max-height: 260px;
    margin: 0;
    padding: 13px;
    overflow: auto;
    border: 1px solid #dde3ec;
    border-radius: 7px;
    color: #344054;
    background: #f8fafc;
    font: 11px/1.65 SFMono-Regular, Consolas, monospace;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.settings-section {
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fff;
}

.settings-section > header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 18px;
    border-bottom: 1px solid var(--border);
}

.settings-section > header > div {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.settings-section > header strong {
    color: #172033;
    font-size: 14px;
}

.settings-section > header small {
    color: #7a8494;
    font-size: 10px;
}

.settings-icon {
    display: inline-flex;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    font-size: 18px;
}

.settings-icon.blue { color: #2563eb; background: #eaf1ff; }
.settings-icon.green { color: #087f5b; background: #e8f8f2; }
.settings-icon.purple { color: #7e22ce; background: #f5eaff; }
.settings-icon.orange { color: #b45309; background: #fff1df; }
.settings-icon.red { color: #b42318; background: #fff0ee; }

.settings-section dl {
    margin: 0;
    padding: 6px 18px 12px;
}

.settings-section dl > div {
    display: grid;
    min-height: 42px;
    grid-template-columns: 120px minmax(0, 1fr);
    align-items: center;
    gap: 14px;
    border-bottom: 1px solid #f0f2f5;
}

.settings-section dl > div:last-child {
    border-bottom: 0;
}

.settings-section dt {
    color: #667085;
    font-size: 11px;
}

.settings-section dd {
    min-width: 0;
    margin: 0;
    overflow-wrap: anywhere;
    color: #273142;
    font-size: 12px;
    font-weight: 550;
}

.request-simulation-workspace {
    display: grid;
    gap: 12px;
}

.request-simulation-tabs {
    display: inline-flex;
    width: fit-content;
    gap: 4px;
    padding: 4px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow);
}

.request-simulation-tabs button {
    display: inline-flex;
    min-height: 36px;
    align-items: center;
    gap: 7px;
    padding: 0 15px;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: #667085;
    cursor: pointer;
    font-size: 11px;
    font-weight: 650;
}

.request-simulation-tabs button:hover { color: var(--primary); background: #f4f7ff; }
.request-simulation-tabs button.is-active { color: #fff; background: var(--primary); box-shadow: 0 5px 13px rgba(47, 107, 255, .2); }

.request-simulation-grid {
    display: grid;
    grid-template-columns: minmax(300px, .72fr) minmax(520px, 1.28fr);
    align-items: start;
    gap: 14px;
}

.request-simulation-panel {
    min-width: 0;
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow);
}

.request-simulation-panel > header {
    display: flex;
    min-height: 72px;
    align-items: center;
    gap: 12px;
    padding: 15px 18px;
    border-bottom: 1px solid var(--border);
    box-sizing: border-box;
}

.request-simulation-panel > header > div {
    display: flex;
    min-width: 0;
    flex-direction: column;
    gap: 3px;
}

.request-simulation-panel > header strong { color: #172033; font-size: 14px; }
.request-simulation-panel > header small { color: #7a8494; font-size: 10px; line-height: 1.5; }

.request-simulation-form {
    display: grid;
    gap: 18px;
    padding: 20px 18px;
}

.request-simulation-form label {
    display: grid;
    gap: 7px;
    color: #344054;
    font-size: 11px;
    font-weight: 700;
}

.request-simulation-form label > span em { color: var(--danger); font-style: normal; }
.request-simulation-form label > small { color: #8792a4; font-size: 10px; font-weight: 400; line-height: 1.5; }
.request-simulation-form textarea { min-height: 220px; resize: vertical; }
.request-simulation-form .request-simulation-title-input { min-height: 92px; }
.request-simulation-select {
    width: 100%;
    height: 38px;
    padding: 0 34px 0 11px;
    border: 1px solid #d7deea;
    border-radius: 6px;
    outline: 0;
    appearance: none;
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%237b8799' d='M2.2 4.3 6 8l3.8-3.7.8.8L6 9.6 1.4 5.1z'/%3E%3C/svg%3E") no-repeat right 11px center;
    color: #273142;
    font-size: 11px;
}
.request-simulation-select:focus { border-color: var(--primary); box-shadow: 0 0 0 2px rgba(47, 107, 255, .1); }
.request-simulation-select:disabled { background-color: #f5f7fa; color: #98a2b3; cursor: not-allowed; }
.request-simulation-count { max-width: 220px; }

.request-simulation-actions {
    display: flex;
    min-height: 38px;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.request-simulation-actions .layui-btn { margin: 0; }
.request-simulation-actions > span { color: var(--danger); font-size: 10px; }

.request-simulation-result { min-width: 0; }
.request-json-frame { margin: 18px; overflow: hidden; border: 1px solid #25314b; border-radius: 8px; background: #0b1020; box-shadow: 0 14px 36px rgba(15, 23, 42, .16); }

.request-json-toolbar {
    display: flex;
    min-height: 42px;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 0 14px;
    border-bottom: 1px solid #25314b;
    background: #11182b;
}

.request-json-toolbar > span { display: flex; align-items: center; gap: 6px; }
.request-json-toolbar > span i { display: block; width: 9px; height: 9px; border-radius: 50%; background: #ff5f57; }
.request-json-toolbar > span i:nth-child(2) { background: #febc2e; }
.request-json-toolbar > span i:nth-child(3) { background: #28c840; }
.request-json-toolbar b { margin-left: 7px; color: #8fa1bd; font: 500 10px/1.2 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; }

.request-json-toolbar button {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: 0;
    background: transparent;
    color: #a9b7cc;
    cursor: pointer;
    font-size: 10px;
}

.request-json-toolbar button:hover { color: #fff; }
.request-json-toolbar button:disabled { color: #56647a; cursor: not-allowed; }

.request-json-frame pre {
    min-height: 520px;
    max-height: calc(100vh - 285px);
    margin: 0;
    overflow: auto;
    padding: 18px;
    color: #d9e2f1;
    font: 12px/1.7 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    tab-size: 2;
    white-space: pre;
    word-wrap: normal;
}

.loading-state,
.empty-state {
    grid-column: 1 / -1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 240px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text-soft);
}

.metric-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.metric-grid article {
    display: flex;
    gap: 13px;
    padding: 20px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
}

.metric-grid article > div {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.metric-grid small,
.metric-grid p {
    margin: 0;
    color: var(--text-soft);
}

.metric-grid strong {
    font-size: 16px;
}

/* 平台运营首页：未开发模块只展示不可操作状态。 */
.operations-dashboard { display: flex; flex-direction: column; gap: 14px; }
.operations-hero { min-height: 176px; padding: 28px 30px; display: flex; align-items: center; color: #fff; background: #4037ad; border-radius: 8px; box-shadow: 0 12px 30px rgba(47, 42, 137, 0.16); }
.operations-role-pill { display: inline-flex; align-items: center; gap: 5px; padding: 5px 8px; border: 1px solid rgba(255, 255, 255, 0.2); border-radius: 999px; color: #fff; background: rgba(255, 255, 255, 0.13); font-size: 12px; font-weight: 700; }
.operations-hero h1 { margin: 13px 0 0; font-size: 28px; line-height: 1.2; }
.operations-hero p { max-width: 760px; margin: 8px 0 0; color: rgba(255, 255, 255, 0.9); font-size: 14px; line-height: 1.65; }
.operations-hero-actions { display: flex; gap: 8px; margin-top: 17px; }
.operations-primary-action { color: #3d36a1; border-color: #fff; background: #fff; }
.operations-secondary-action { color: #fff; border-color: rgba(255, 255, 255, 0.34); background: rgba(255, 255, 255, 0.08); }
.operations-primary-action:hover,
.operations-primary-action:focus-visible { color: #30298c; border-color: #fff; background: #f1f0ff; opacity: 1; }
.operations-secondary-action:hover,
.operations-secondary-action:focus-visible { color: #fff; border-color: rgba(255, 255, 255, 0.58); background: rgba(255, 255, 255, 0.16); opacity: 1; }
.operations-hero-actions .layui-btn[disabled] { cursor: not-allowed; opacity: 0.72; }
.operations-metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.operations-metrics article, .operations-metrics > a { min-height: 104px; padding: 17px; display: flex; align-items: center; gap: 13px; border: 1px solid var(--border); border-radius: 8px; background: #fff; box-sizing: border-box; }
.operations-metrics > a { color: inherit; text-decoration: none; transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease; }
.operations-metrics > a:hover, .operations-metrics > a:focus-visible { border-color: #b9c7e4; box-shadow: 0 8px 20px rgba(38, 65, 112, .09); transform: translateY(-1px); }
.operations-metrics article > div, .operations-metrics > a > div { display: flex; min-width: 0; flex-direction: column; gap: 5px; }
.operations-metrics small { margin: 0; color: #596273; font-size: 13px; font-weight: 500; }
.operations-metrics strong { color: #202633; font-size: 24px; line-height: 1.2; }
.operations-metrics article > div > span, .operations-metrics > a > div > span { overflow: hidden; color: #7b8493; font-size: 11px; line-height: 1.45; text-overflow: ellipsis; white-space: nowrap; }
.operations-ai-flow { display: block; width: 80px; height: 24px; overflow: visible; }
.operations-ai-flow-path { fill: none; stroke: #8795ee; stroke-width: 1.8; stroke-linecap: round; stroke-dasharray: 5 4; transition: stroke-dashoffset .35s ease; }
.operations-ai-flow-node { fill: #c9d2ff; transition: fill .2s ease; }
.operations-ai-flow-spark { fill: #6558d9; transform-box: fill-box; transform-origin: center; transition: filter .22s ease, transform .22s ease; }
.operations-ai-flow-orbit { fill: #a9b5f6; transition: transform .22s ease; transform-box: fill-box; transform-origin: center; }
.operations-metric-entry-arrow { margin-left: auto; color: #9aa6bb; font-size: 16px; transition: color .18s ease, transform .18s ease; }
.operations-metric-entry:hover .operations-ai-flow-path, .operations-metric-entry:focus-visible .operations-ai-flow-path { stroke-dashoffset: -9; }
.operations-metric-entry:hover .operations-ai-flow-node, .operations-metric-entry:focus-visible .operations-ai-flow-node { fill: #6f7fe6; }
.operations-metric-entry:hover .operations-ai-flow-spark, .operations-metric-entry:focus-visible .operations-ai-flow-spark { filter: drop-shadow(0 0 4px rgba(101, 88, 217, .38)); transform: rotate(12deg) scale(1.08); }
.operations-metric-entry:hover .operations-ai-flow-orbit, .operations-metric-entry:focus-visible .operations-ai-flow-orbit { transform: scale(1.22); }
.operations-metric-entry:hover .operations-metric-entry-arrow, .operations-metric-entry:focus-visible .operations-metric-entry-arrow { color: #2563eb; transform: translateX(3px); }
@media (prefers-reduced-motion: reduce) {
    .operations-metrics > a,
    .operations-ai-flow-path,
    .operations-ai-flow-node,
    .operations-ai-flow-spark,
    .operations-ai-flow-orbit,
    .operations-metric-entry-arrow { transition: none; }
}
.operations-metric-icon, .operations-square-icon { display: inline-flex; flex: 0 0 auto; align-items: center; justify-content: center; border-radius: 6px; }
.operations-metric-icon { width: 42px; height: 42px; font-size: 20px; }
.operations-square-icon { width: 38px; height: 38px; font-size: 18px; }
.operations-metric-icon.blue, .operations-square-icon.blue { color: #2563eb; background: #eaf1ff; }
.operations-metric-icon.purple, .operations-square-icon.purple { color: #7e22ce; background: #f5eaff; }
.operations-metric-icon.orange, .operations-square-icon.orange { color: #b45309; background: #fff1df; }
.operations-metric-icon.green, .operations-square-icon.green { color: #087f5b; background: #e8f8f2; }
.operations-module-grid { display: grid; grid-template-columns: minmax(430px, 1.05fr) minmax(520px, 1.35fr); gap: 14px; }
.operations-panel { padding: 18px; border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.operations-panel-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.operations-panel-heading h2, .operations-panel-heading p { margin: 0; }
.operations-panel-heading h2 { font-size: 17px; }
.operations-panel-heading p { margin-top: 5px; color: #5f6878; font-size: 13px; line-height: 1.5; }
.operations-planned-tag { padding: 4px 7px; border-radius: 4px; color: #5949b9; background: #f0edff; font-size: 12px; font-weight: 600; }
.operations-module-list { margin-top: 10px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
.operations-module-list > a, .operations-module-list > span, .operations-module-list > div { min-height: 79px; padding: 11px; display: grid; grid-template-columns: 38px minmax(0, 1fr) 16px; align-items: center; gap: 10px; border: 1px solid var(--border); border-radius: 8px; color: var(--text); background: #fff; text-decoration: none; }
.operations-module-list > a:hover { border-color: #b9c7e4; background: #fafcff; }
.operations-module-list > .is-disabled { cursor: not-allowed; background: #fafbfc; }
.operations-module-list > a > span:nth-child(2), .operations-module-list > span > span:nth-child(2) { display: flex; min-width: 0; flex-direction: column; }
.operations-module-list strong { color: #303846; font-size: 14px; }
.operations-module-list small { margin-top: 5px; overflow: hidden; color: #616b7b; font-size: 12px; line-height: 1.45; text-overflow: ellipsis; white-space: nowrap; }
.operations-module-list > a > i, .operations-module-list > span > i { color: #9ba3b2; }
.operations-module-list > .operations-module-hub { grid-template-columns: 38px minmax(0, 1fr); }
.operations-module-hub.is-wide { grid-column: 1 / -1; }
.operations-module-hub > span:nth-child(2) { display: flex; min-width: 0; flex-direction: column; }
.operations-module-shortcuts { display: flex; margin-top: 8px; gap: 5px; flex-wrap: wrap; }
.operations-module-shortcuts a { padding: 3px 7px; border: 1px solid #dbe4f3; border-radius: 4px; color: #355f9d; background: #f7faff; font-size: 11px; line-height: 1.4; text-decoration: none; }
.operations-module-shortcuts a:hover { border-color: #adc3e6; color: var(--primary); background: #eef4ff; }
.operations-flow { margin-top: 12px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; }
.operations-flow > div, .operations-flow > a { position: relative; min-height: 166px; padding: 14px 10px; display: flex; align-items: center; justify-content: center; flex-direction: column; border: 1px solid var(--border); border-radius: 8px; color: var(--text); background: #fbfcfe; text-align: center; text-decoration: none; }
.operations-flow > a:hover { border-color: #b9c7e4; background: #f8fbff; }
.operations-flow strong { margin-top: 12px; color: #303846; font-size: 14px; }
.operations-flow small { margin-top: 5px; color: #616b7b; font-size: 12px; line-height: 1.4; }
.operations-flow b { margin-top: 12px; color: var(--green); font-size: 17px; }
.operations-flow > div > i, .operations-flow > a > i { position: absolute; z-index: 2; top: 50%; right: -14px; padding: 2px; border-radius: 50%; color: #a9b2c2; background: #fff; }
.operations-alert-panel { grid-column: 1 / -1; }
.operations-alert-list { margin-top: 10px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; }
.operations-alert-list > span, .operations-alert-list > a { min-height: 72px; padding: 10px; display: grid; grid-template-columns: 38px minmax(0, 1fr) auto; align-items: center; gap: 9px; border: 1px solid var(--border); border-radius: 8px; color: var(--text); text-decoration: none; }
.operations-alert-list > a:hover { border-color: #b9c7e4; background: #fafcff; }
.operations-alert-list > span > span:nth-child(2), .operations-alert-list > a > span:nth-child(2) { display: flex; min-width: 0; flex-direction: column; }
.operations-alert-list strong { color: #303846; font-size: 14px; }
.operations-alert-list small { margin-top: 5px; color: #616b7b; font-size: 12px; line-height: 1.45; }
.operations-alert-list em { padding: 4px 7px; border-radius: 4px; color: #6f5e1e; background: #faf4dc; font-size: 12px; font-style: normal; font-weight: 600; }
.operations-alert-list em.is-pending { color: #8a5300; background: #fff2d6; }
.operations-alert-list em.is-ready { color: #176449; background: #e9f7f1; }
.operations-alert-list em.is-danger { color: #b42318; background: #fff0ee; }

.sidebar-mask {
    display: none;
}

@media (max-width: 1320px) {
    .role-switcher em {
        display: none;
    }

    .operations-module-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1100px) {
    .role-switcher,
    .topbar-user small {
        display: none;
    }

    .filter-form {
        grid-template-columns: minmax(220px, 1fr) 160px 140px;
    }

    .filter-form .layui-btn {
        width: 100%;
    }

    .permission-options {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ai-filter-form {
        grid-template-columns: minmax(220px, 1fr) 145px 170px;
    }

    .knowledge-filter-form {
        grid-template-columns: minmax(220px, 1fr) repeat(2, 150px);
    }

    .keyword-library-filters {
        grid-template-columns: minmax(220px, 1fr) 160px 140px;
    }

    .keyword-item-filters {
        grid-template-columns: minmax(220px, 1fr) 140px 130px;
    }

    .media-workspace {
        grid-template-columns: 190px minmax(0, 1fr);
    }

    .operations-metrics {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 860px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.2s ease;
    }

    .sidebar.is-open {
        transform: translateX(0);
    }

    .admin-main {
        margin-left: 0;
    }

    .mobile-menu-button {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .sidebar-mask.is-visible {
        position: fixed;
        z-index: 15;
        inset: 0;
        display: block;
        background: rgba(15, 23, 42, 0.46);
    }

    .page-content {
        padding: 22px 18px;
    }

    .role-matrix,
    .metric-grid {
        grid-template-columns: 1fr;
    }

    .operations-flow,
    .operations-alert-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ai-parameter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ai-parameter-grid.three-items {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ai-parameter-grid.four-items {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ai-prompt-workspace {
        grid-template-columns: 1fr;
    }

    .login-page {
        justify-content: center;
        padding: 26px;
    }

    .token-metric-grid,
    .settings-grid {
        grid-template-columns: 1fr;
    }

    .request-simulation-grid { grid-template-columns: 1fr; }
    .request-simulation-tabs { width: 100%; }
    .request-simulation-tabs button { flex: 1; justify-content: center; }

    .sensitive-filter-form,
    .token-filter-form,
    .operation-log-filter {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 620px) {
    .login-body {
        overflow: auto;
    }

    .login-page {
        align-items: flex-start;
        padding: 18px;
    }

    .login-panel {
        margin-top: 16px;
        padding: 26px 22px 22px;
    }

    .login-heading {
        margin: 30px 0 24px;
    }

    .captcha-field {
        grid-template-columns: minmax(0, 1fr) 118px;
    }

    .captcha-refresh,
    .captcha-refresh img {
        width: 118px;
    }

    .topbar {
        padding: 0 14px;
    }

    .topbar-status {
        display: none;
    }

    .page-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .page-heading-actions {
        justify-content: flex-start;
        flex-wrap: wrap;
    }

    .ai-provider-panel-header {
        align-items: stretch;
        flex-direction: column;
        gap: 14px;
        padding: 16px;
    }

    .ai-provider-panel-header .layui-btn {
        width: 100%;
    }

    .ai-provider-panel-actions {
        align-items: center;
    }

    .ai-provider-summary {
        width: 100%;
        grid-template-columns: minmax(0, 1fr) 1px minmax(0, 1fr);
    }

    .ai-provider-summary-item {
        justify-content: center;
    }

    .ai-provider-list {
        padding: 12px;
        grid-template-columns: 1fr;
    }

    .ai-provider-card-footer {
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 10px;
    }

    .ai-provider-card-key {
        grid-column: 1 / -1;
    }

    .ai-provider-layer {
        padding-right: 16px;
        padding-left: 16px;
    }

    .sensitive-detection-control {
        align-items: flex-start;
        flex-direction: column;
        gap: 14px;
    }

    .sensitive-detection-switch {
        margin-left: 55px;
    }

    .operations-hero {
        padding: 24px 20px;
    }

    .operations-hero-actions,
    .operations-panel-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .operations-metrics,
    .operations-module-list,
    .operations-flow,
    .operations-alert-list {
        grid-template-columns: 1fr;
    }

    .filter-form,
    .two-column-form {
        grid-template-columns: 1fr;
    }

    .ai-parameter-grid,
    .ai-switch-row {
        grid-template-columns: 1fr;
    }

    .ai-parameter-grid.three-items {
        grid-template-columns: 1fr;
    }

    .ai-parameter-grid.four-items {
        grid-template-columns: 1fr;
    }

    .ai-switch-row .ai-compact-number {
        max-width: none;
    }

    .ai-form-section-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 4px;
    }

    .knowledge-form-section-header {
        align-items: flex-start;
        flex-direction: column;
        gap: 4px;
    }

    .knowledge-field-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .knowledge-field-toolbar-actions {
        justify-content: flex-end;
    }

    .knowledge-dynamic-fields {
        grid-template-columns: 1fr;
    }

    .keyword-workspace {
        grid-template-columns: 1fr;
    }

    .media-workspace {
        grid-template-columns: 1fr;
    }

    .media-category-pane {
        border-right: 0;
        border-bottom: 1px solid #e0e5ec;
    }

    .media-category-list {
        max-height: 220px;
        overflow: auto;
    }

    .media-crop-toolbar,
    .media-upload-fields {
        align-items: stretch;
        grid-template-columns: 1fr;
        flex-direction: column;
    }

    .media-crop-stage {
        height: 330px;
        min-height: 240px;
    }

    .media-asset-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .keyword-library-pane {
        border-right: 0;
        border-bottom: 1px solid #e0e5ec;
    }

    .keyword-library-list {
        max-height: 250px;
    }

    .permission-options,
    .role-permissions {
        grid-template-columns: 1fr;
    }

    .permission-picker > header {
        align-items: flex-start;
        flex-direction: column;
    }

    .modal-content {
        padding: 18px 16px 14px;
    }

    .permission-route-row {
        grid-template-columns: 1fr;
    }

    .permission-route-row.role-route-row {
        grid-template-columns: 18px minmax(0, 1fr);
    }

    .permission-filter-form {
        grid-template-columns: 1fr;
    }

    .permission-filter-form .layui-btn,
    .knowledge-filter-form .layui-btn,
    .keyword-library-filters .layui-btn,
    .keyword-item-filters .layui-btn,
    .user-asset-filter .layui-btn,
    .media-asset-filters .layui-btn,
    .sensitive-filter-form .layui-btn,
    .token-filter-form .layui-btn,
    .operation-log-filter .layui-btn {
        margin-left: 0;
        width: 100%;
    }

    .knowledge-filter-form,
    .keyword-library-filters,
    .keyword-item-filters,
    .user-asset-filter,
    .media-asset-filters,
    .sensitive-filter-form,
    .token-filter-form,
    .operation-log-filter {
        grid-template-columns: 1fr;
    }

    .operation-log-filter .search-field,
    .operation-log-filter .layui-form-select,
    .operation-log-filter > input[type="date"] {
        width: 100%;
        min-width: 0;
        max-width: none;
        flex: 1 1 100%;
    }

    .token-metric-grid,
    .settings-grid {
        grid-template-columns: 1fr;
    }

    .request-simulation-grid { grid-template-columns: 1fr; }
    .request-simulation-form textarea { min-height: 170px; }
    .request-simulation-count { max-width: none; }
    .request-simulation-actions { align-items: stretch; flex-direction: column; }
    .request-simulation-actions .layui-btn { width: 100%; }
    .request-json-frame { margin: 12px; }
    .request-json-frame pre { min-height: 400px; max-height: 620px; padding: 14px; font-size: 11px; }

    .token-trend-section > header {
        align-items: flex-start;
        flex-direction: column;
        gap: 4px;
    }

    .token-response-detail { padding: 14px; }
    .token-response-meta { grid-template-columns: 1fr; }
    .token-response-meta div,
    .token-response-meta div:nth-child(3n),
    .token-response-meta div:nth-last-child(-n+3) { border-right: 0; border-bottom: 1px solid #e6eaf0; }
    .token-response-meta div:last-child { border-bottom: 0; }

    .permission-toggle-grid {
        grid-template-columns: 1fr;
        padding-top: 0;
    }

    .data-pagination {
        align-items: stretch;
        flex-direction: column;
    }

    .pagination-controls {
        justify-content: space-between;
    }
}
.article-configuration-panel {
    max-width: 980px;
}

.article-configuration-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    padding: 24px 28px;
    border-bottom: 1px solid var(--border);
}

.article-configuration-header h2 {
    margin: 0 0 8px;
    font-size: 20px;
}

.article-configuration-header p {
    margin: 0;
    color: var(--text-soft);
}

.article-configuration-form {
    padding: 28px;
}

.article-configuration-form label small {
    display: block;
    margin-top: 8px;
    color: var(--text-soft);
    line-height: 1.6;
}

.article-configuration-summary {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 24px;
    padding: 14px 16px;
    color: #2459bb;
    background: #f2f6ff;
    border: 1px solid #d7e3ff;
    border-radius: 8px;
}

.article-configuration-summary.is-invalid {
    color: #b42318;
    background: #fff5f4;
    border-color: #ffd5d2;
}

.article-configuration-actions {
    display: flex;
    justify-content: flex-start;
    margin-top: 24px;
}

@media (max-width: 720px) {
    .article-configuration-panel {
        max-width: none;
    }

    .article-configuration-header,
    .article-configuration-form {
        padding: 20px;
    }

    .article-configuration-header {
        flex-direction: column;
        gap: 12px;
    }
}

.security-page-heading {
    align-items: center;
}

.security-draft-notice {
    border-color: #f4d28a;
    background: #fffaf0;
}

#security-config-schema-notice[hidden] {
    display: none;
}

.security-draft-notice > i,
.security-draft-notice strong {
    color: #b76e00;
}

.security-draft-notice.is-enabled {
    border-color: #a9dfce;
    background: #f1fbf7;
}

.security-draft-notice.is-enabled > i,
.security-draft-notice.is-enabled strong {
    color: #167b5a;
}

.security-overview-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}

.security-overview-grid article {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 12px;
    padding: 15px 16px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fff;
}

.security-overview-grid article > div {
    min-width: 0;
}

.security-overview-grid small,
.security-overview-grid strong,
.security-overview-grid p {
    display: block;
}

.security-overview-grid small {
    margin-bottom: 2px;
    color: var(--text-soft);
    font-size: 11px;
}

.security-overview-grid strong {
    color: #172033;
    font-size: 14px;
}

.security-overview-grid p {
    margin: 4px 0 0;
    color: var(--text-soft);
    font-size: 11px;
    line-height: 1.5;
}

.security-configuration-form {
    display: grid;
    gap: 14px;
}

.security-rule-section {
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: #fff;
}

.security-rule-section > header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    padding: 18px 20px;
    border-bottom: 1px solid var(--border);
    background: #fbfcfe;
}

.security-rule-section > header h2 {
    margin: 0 0 5px;
    color: #172033;
    font-size: 16px;
}

.security-rule-section > header p {
    margin: 0;
    color: var(--text-soft);
    font-size: 12px;
    line-height: 1.6;
}

.security-rule-section > header > span {
    flex: 0 0 auto;
    padding: 4px 9px;
    color: #526277;
    font-size: 11px;
    border-radius: 999px;
    background: #edf1f7;
}

.security-rule-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px 20px;
    padding: 20px;
}

.security-enforcement-control {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 20px;
}

.security-enforcement-switch {
    flex: 0 0 auto;
}

.security-enforcement-switch .compact-status-switch small {
    display: inline;
    margin: 0;
}

.security-enforcement-control > p {
    margin: 0;
    color: var(--text-soft);
    font-size: 12px;
    line-height: 1.7;
}

.security-rule-field {
    min-width: 0;
}

.security-rule-field > span:first-child {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-bottom: 8px;
    color: #344054;
    font-size: 12px;
    font-weight: 600;
}

.security-rule-help {
    display: inline-flex;
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    align-items: center;
    justify-content: center;
    color: #8b95a5;
    font-size: 11px;
    font-weight: 600;
    line-height: 1;
    border: 1px solid #c8ced8;
    border-radius: 50%;
    background: #f4f6f8;
    cursor: help;
    outline: none;
}

.security-rule-help:hover,
.security-rule-help:focus {
    color: #667085;
    border-color: #98a2b3;
    background: #eceff3;
    box-shadow: 0 0 0 2px rgba(152, 162, 179, 0.16);
}

.security-rule-tooltip .layui-layer-content {
    max-width: 360px;
    padding: 10px 12px;
    font-size: 12px;
    line-height: 1.7;
    white-space: normal;
}

.security-rule-field em {
    color: var(--danger);
    font-style: normal;
}

.security-rule-field small {
    display: block;
    margin-top: 7px;
    color: var(--text-soft);
    font-size: 11px;
    line-height: 1.55;
}

.security-rule-field-wide {
    grid-column: 1 / -1;
}

.security-rule-field textarea {
    min-height: 112px;
    resize: vertical;
}

.security-input-unit {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
}

.security-input-unit input {
    border-radius: 4px 0 0 4px;
}

.security-input-unit > span {
    display: inline-flex;
    height: 38px;
    align-items: center;
    padding: 0 12px;
    color: #667085;
    font-size: 11px;
    border: 1px solid #d8dee8;
    border-left: 0;
    border-radius: 0 4px 4px 0;
    background: #f7f9fc;
}

.security-configuration-actions {
    display: flex;
    position: sticky;
    z-index: 5;
    bottom: 0;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 16px 20px;
    border: 1px solid var(--border);
    border-radius: 7px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 -5px 18px rgba(28, 39, 56, 0.06);
}

.security-configuration-actions strong,
.security-configuration-actions span {
    display: block;
}

.security-configuration-actions strong {
    margin-bottom: 3px;
    color: #344054;
    font-size: 12px;
}

.security-configuration-actions span {
    color: var(--text-soft);
    font-size: 11px;
}

@media (max-width: 1280px) {
    .security-overview-grid,
    .security-rule-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 620px) {
    .security-page-heading,
    .security-rule-section > header,
    .security-enforcement-control,
    .security-configuration-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .security-overview-grid,
    .security-rule-grid {
        grid-template-columns: 1fr;
    }

    .security-rule-grid,
    .security-rule-section > header,
    .security-configuration-actions {
        padding: 16px;
    }

    .security-rule-field-wide {
        grid-column: auto;
    }

    .security-configuration-actions .layui-btn {
        width: 100%;
    }
}

/* 安全黑名单 */
.security-blacklist-table th:nth-child(1) { width: 19%; }
.security-blacklist-table th:nth-child(2) { width: 20%; }
.security-blacklist-table th:nth-child(3) { width: 25%; }
.security-blacklist-table th:nth-child(4) { width: 12%; }
.security-blacklist-table th:nth-child(5) { width: 15%; }
.security-blacklist-table th:nth-child(6) { width: 9%; }

.security-blacklist-target {
    display: block;
    margin-top: 7px;
    color: #1f2937;
    font-size: 13px;
    overflow-wrap: anywhere;
}

.security-blacklist-reason {
    max-width: 320px;
    color: #526277;
    line-height: 1.65;
    overflow-wrap: anywhere;
}

.security-blacklist-form textarea {
    min-height: 104px;
    resize: vertical;
}

@media (max-width: 620px) {
    .security-blacklist-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .security-blacklist-heading .layui-btn {
        width: 100%;
    }
}

/* GEO优化方案 */
.marketing-plan-heading {
    min-height: 0;
    margin-bottom: 10px;
}

#marketing-plan-page > .business-notice {
    align-items: center;
    margin-bottom: 12px;
    padding: 9px 12px;
}

.marketing-plan-workspace {
    display: grid;
    grid-template-columns: minmax(440px, 500px) minmax(0, 1fr);
    gap: 14px;
    align-items: start;
    margin-bottom: 14px;
}

.marketing-plan-workspace.is-customer {
    display: block;
}

.marketing-plan-control {
    padding: 18px;
}

.marketing-plan-control[hidden] {
    display: none;
}

.layui-layer-content > .marketing-plan-control {
    display: block;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.marketing-plan-control > header {
    display: block;
    margin-bottom: 14px;
}

.marketing-plan-control h2,
.marketing-plan-preview h2,
.marketing-plan-history h2 {
    margin: 0;
    color: #1d2939;
    font-size: 18px;
}

.marketing-plan-control header p,
.marketing-plan-history header p {
    margin: 5px 0 0;
    color: #7b8798;
    font-size: 11px;
    line-height: 1.55;
}

.marketing-plan-control form {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 12px;
}

.marketing-plan-control form > label {
    display: block;
    margin: 0;
}

.marketing-plan-control form > label:nth-child(3),
.marketing-plan-control form > label:nth-child(4),
.marketing-plan-control form > .marketing-plan-submit,
.marketing-plan-control form > .marketing-plan-submit-help {
    grid-column: 1 / -1;
}

.marketing-plan-control form > label > span {
    display: block;
    margin-bottom: 5px;
    color: #344054;
    font-size: 12px;
    font-weight: 600;
}

.marketing-plan-control em {
    color: var(--danger);
    font-style: normal;
}

.marketing-plan-control textarea {
    min-height: 74px;
    max-height: 160px;
    resize: vertical;
    line-height: 1.7;
}

.marketing-plan-control label > small,
.marketing-plan-submit-help {
    display: block;
    margin-top: 6px;
    color: #8b96a7;
    font-size: 10px;
    line-height: 1.6;
}

.marketing-plan-submit {
    width: 100%;
}

.marketing-plan-submit-help {
    margin: -4px 0 -2px;
    text-align: center;
}

.marketing-plan-preview {
    display: flex;
    height: 100%;
    min-height: 0;
    flex-direction: column;
    box-sizing: border-box;
    background: #fff;
}

.marketing-plan-preview[hidden] {
    display: none;
}

.layui-layer-content > .marketing-plan-preview {
    display: flex;
}

.marketing-plan-preview > .marketing-plan-preview-header {
    display: flex;
    flex: 0 0 auto;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin: 0;
    padding: 18px 22px;
    border-bottom: 1px solid #e8edf4;
}

.marketing-plan-preview-header p {
    margin: 5px 0 0;
    color: #7b8798;
    font-size: 11px;
}

.marketing-plan-preview-body {
    display: flex;
    min-height: 0;
    flex: 1;
    flex-direction: column;
}

.marketing-plan-preview-empty {
    display: flex;
    min-height: 0;
    flex: 1;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    padding: 24px;
    color: #8a96a8;
    text-align: center;
    box-sizing: border-box;
    animation: marketing-plan-state-in .2s ease-out;
}

.marketing-plan-preview-empty[hidden],
.marketing-plan-markdown[hidden] {
    display: none;
}

.marketing-plan-preview-empty > span {
    display: inline-flex;
    width: 52px;
    height: 52px;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
    border-radius: 50%;
    background: #f0f4fa;
    color: #5474a9;
    font-size: 24px;
    transition: background-color .18s ease, color .18s ease;
}

.marketing-plan-preview-empty > .marketing-plan-status {
    width: auto;
    height: auto;
    margin: 0 0 16px;
    border-radius: 999px;
    font-size: 10px;
}

.marketing-plan-preview-empty > h2 {
    max-width: 680px;
    margin: 0 0 18px;
    color: #1d2939;
    font-size: 20px;
    line-height: 1.45;
    overflow-wrap: anywhere;
}

.marketing-plan-preview-empty > div {
    max-width: 520px;
}

.marketing-plan-preview-empty h3 {
    margin: 0 0 8px;
    color: #475467;
    font-size: 15px;
}

.marketing-plan-preview-empty p {
    margin: 0;
    font-size: 11px;
    line-height: 1.8;
}

.marketing-plan-preview.is-running .marketing-plan-preview-empty > span,
.marketing-plan-preview.is-queued .marketing-plan-preview-empty > span {
    color: #245fbd;
    background: #edf4ff;
}

.marketing-plan-preview.is-manual .marketing-plan-preview-empty > span {
    color: #6941c6;
    background: #f2efff;
}

.marketing-plan-preview.is-error .marketing-plan-preview-empty > span {
    color: #b42318;
    background: #fdecea;
}

.marketing-plan-preview.is-error .marketing-plan-preview-empty h3 {
    color: #8f2d25;
}

.marketing-plan-status {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    padding: 4px 9px;
    border-radius: 999px;
    background: #f0f2f5;
    color: #667085;
    font-size: 10px;
    font-weight: 600;
}

.marketing-plan-status.is-0 { background: #fff6e5; color: #9a6700; }
.marketing-plan-status.is-1,
.marketing-plan-status.is-2 { background: #edf4ff; color: #175cd3; }
.marketing-plan-status.is-3 { background: #f2efff; color: #6941c6; }
.marketing-plan-status.is-4 { background: #eaf8f0; color: #16794b; }
.marketing-plan-status.is-5 { background: #fff0ef; color: #b42318; }
.marketing-plan-status.is-6 { background: #f0f2f5; color: #667085; }

.marketing-plan-markdown {
    min-height: 0;
    flex: 1;
    overflow: auto;
    padding: 22px 26px 30px;
    color: #344054;
    font-size: 12px;
    line-height: 1.8;
    overflow-wrap: anywhere;
}

.marketing-plan-markdown h1 { margin: 0 0 22px; color: #172b4d; font-size: 24px; }
.marketing-plan-markdown h2 { margin: 28px 0 12px; padding-bottom: 7px; border-bottom: 1px solid #e4e9f0; font-size: 17px; }
.marketing-plan-markdown h3 { margin: 20px 0 10px; color: #243b64; font-size: 14px; }
.marketing-plan-markdown p,
.marketing-plan-markdown ul,
.marketing-plan-markdown ol,
.marketing-plan-markdown blockquote { margin: 0 0 12px; }
.marketing-plan-markdown ul,
.marketing-plan-markdown ol { padding-left: 22px; }
.marketing-plan-markdown table { width: 100%; margin: 14px 0 20px; border-collapse: collapse; font-size: 11px; }
.marketing-plan-markdown th,
.marketing-plan-markdown td { padding: 8px 10px; border: 1px solid #dfe5ed; text-align: left; vertical-align: top; }
.marketing-plan-markdown th { background: #f5f7fa; color: #344054; }
.marketing-plan-markdown blockquote { padding: 10px 14px; border-left: 3px solid #6688bd; background: #f5f7fb; }
.marketing-plan-markdown a { color: #245fbd; text-decoration: underline; text-underline-offset: 2px; }

.marketing-plan-preview-actions {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    padding: 12px 20px;
    border-top: 1px solid #e8edf4;
    background: #fbfcfe;
}

.marketing-plan-preview-actions .layui-btn {
    margin: 0;
}

.marketing-plan-preview-actions .layui-btn:disabled {
    cursor: not-allowed;
    opacity: .5;
}

.marketing-plan-history {
    min-width: 0;
    overflow: hidden;
    padding: 0;
}

.marketing-plan-history > header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin: 0;
    padding: 16px 20px;
    border-bottom: 1px solid #edf0f4;
}

.marketing-plan-history-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.marketing-plan-history-actions .layui-btn {
    margin: 0;
}

.filter-form.marketing-plan-filter {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
    padding: 12px 14px;
}

.marketing-plan-filter .search-field {
    width: 340px;
    max-width: 100%;
    flex: 0 1 340px;
}

.marketing-plan-filter .layui-form-select,
.marketing-plan-filter > select {
    width: 160px;
    flex: 0 0 160px;
}

.marketing-plan-filter .layui-btn {
    width: auto;
    flex: 0 0 auto;
    margin: 0;
}

.marketing-plan-history-table {
    min-width: 720px;
    table-layout: fixed;
}

.marketing-plan-history-table th:nth-child(1) { width: 25%; }
.marketing-plan-history-table th:nth-child(2) { width: 12%; }
.marketing-plan-history-table th:nth-child(3) { width: 30%; }
.marketing-plan-history-table th:nth-child(4) { width: 19%; }
.marketing-plan-history-table th:nth-child(5) { width: 14%; }

.marketing-plan-history-table.is-manager {
    min-width: 1080px;
}

.marketing-plan-history-table.is-manager th:nth-child(1) { width: 15%; }
.marketing-plan-history-table.is-manager th:nth-child(2) { width: 13%; }
.marketing-plan-history-table.is-manager th:nth-child(3) { width: 8%; }
.marketing-plan-history-table.is-manager th:nth-child(4) { width: 13%; }
.marketing-plan-history-table.is-manager th:nth-child(5) { width: 19%; }
.marketing-plan-history-table.is-manager th:nth-child(6) { width: 14%; }
.marketing-plan-history-table.is-manager th:nth-child(7) { width: 18%; }

.marketing-plan-history-table th,
.marketing-plan-history-table td {
    padding-right: 14px;
    padding-left: 14px;
    text-align: left;
    vertical-align: middle;
}

.marketing-plan-history-table td {
    color: #475467;
    line-height: 1.55;
    overflow-wrap: anywhere;
}

.marketing-plan-history-table td:first-child strong,
.marketing-plan-history-table td:first-child a {
    display: block;
}

.marketing-plan-history-table td:first-child strong {
    color: #26344a;
    font-size: 12px;
}

.marketing-plan-history-table td:first-child a {
    margin-top: 5px;
    color: #5474a9;
    font-size: 10px;
}

.marketing-plan-history-table:not(.is-manager) td:nth-child(4),
.marketing-plan-history-table:not(.is-manager) td:nth-child(5),
.marketing-plan-history-table.is-manager td:nth-child(6) {
    white-space: nowrap;
}

.marketing-plan-submitter-cell strong {
    display: block;
    color: #344054;
    font-size: 11px;
}

.marketing-plan-submitter,
.marketing-plan-process-name,
.marketing-plan-difficulty {
    display: block;
}

.marketing-plan-submitter {
    margin-top: 4px;
    color: #7b8798;
    font-size: 10px;
}

.marketing-plan-pagination {
    border-top: 1px solid #edf0f4;
}

.marketing-plan-process-name {
    color: #344054;
    font-size: 11px;
}

.marketing-plan-difficulty {
    margin-top: 4px;
    color: #8b96a7;
    font-size: 10px;
}

.marketing-plan-row-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 6px;
}

.marketing-plan-row-actions .table-action-button {
    height: 28px;
    padding: 0 6px;
}

.table-action-button {
    display: inline-flex;
    height: 30px;
    align-items: center;
    justify-content: center;
    padding: 0 12px;
    border: 1px solid #cbd8ed;
    border-radius: 6px;
    color: #315fAD;
    background: #fff;
    font-size: 11px;
    cursor: pointer;
    transition: border-color .16s ease, background-color .16s ease, color .16s ease;
}

.table-action-button:hover {
    border-color: #8ba9d8;
    color: #174ea6;
    background: #f4f8ff;
}

.table-action-button.is-primary {
    border-color: #356fd4;
    color: #fff;
    background: #356fd4;
}

.table-action-button.is-primary:hover {
    border-color: #245fbd;
    color: #fff;
    background: #245fbd;
}

.table-action-button.is-quiet {
    border-color: transparent;
    color: #526277;
    background: transparent;
}

.table-action-button.is-quiet:hover {
    border-color: #dce3ee;
    color: #245fbd;
    background: #f7f9fc;
}

.marketing-plan-history tr.is-selected td {
    background: #f7f9fd;
}

.marketing-plan-import-layer {
    display: flex;
    height: 100%;
    min-height: 0;
    flex-direction: column;
    padding: 18px 20px;
    box-sizing: border-box;
}

.marketing-plan-import-layer[hidden] {
    display: none;
}

.layui-layer-content > .marketing-plan-import-layer {
    display: flex;
}

.marketing-plan-import-summary {
    display: flex;
    align-items: baseline;
    gap: 12px;
    padding-bottom: 14px;
    border-bottom: 1px solid #edf0f4;
}

.marketing-plan-import-summary strong {
    color: #1d2939;
    font-size: 15px;
}

.marketing-plan-import-summary span {
    color: #7b8798;
    font-size: 11px;
}

.marketing-plan-import-grid {
    display: grid;
    min-height: 0;
    flex: 1;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 18px;
    padding: 16px 0;
}

.marketing-plan-import-grid > label,
.marketing-plan-import-grid > section {
    display: flex;
    min-height: 0;
    flex-direction: column;
}

.marketing-plan-import-grid > label > span,
.marketing-plan-import-grid > section > span {
    display: block;
    margin-bottom: 7px;
    color: #344054;
    font-size: 12px;
    font-weight: 600;
}

.marketing-plan-import-grid textarea {
    min-height: 0;
    flex: 1;
    resize: none;
    color: #344054;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 12px;
    line-height: 1.65;
}

.marketing-plan-import-preview {
    min-height: 0;
    flex: 1;
    overflow: auto;
    padding: 14px 16px;
    border: 1px solid #e1e7ef;
    border-radius: 6px;
    background: #fbfcfe;
    box-sizing: border-box;
}

.marketing-plan-import-preview.marketing-plan-markdown {
    padding-right: 16px;
}

.marketing-plan-import-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding-top: 14px;
    border-top: 1px solid #edf0f4;
}

@keyframes marketing-plan-state-in {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1450px) {
    .marketing-plan-workspace {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 900px) {
    .marketing-plan-filter .search-field {
        width: 100%;
        flex-basis: 100%;
    }

    .marketing-plan-import-grid {
        grid-template-columns: 1fr;
    }

    .marketing-plan-import-grid textarea,
    .marketing-plan-import-preview {
        min-height: 240px;
    }
}

@media (max-width: 620px) {
    .marketing-plan-control {
        padding: 16px;
    }

    .marketing-plan-history > header {
        align-items: stretch;
        flex-direction: column;
    }

    .marketing-plan-history-actions .layui-btn {
        flex: 1;
    }

    .filter-form.marketing-plan-filter {
        align-items: stretch;
        flex-direction: column;
    }

    .marketing-plan-filter .search-field,
    .marketing-plan-filter .layui-form-select,
    .marketing-plan-filter > select,
    .marketing-plan-filter .layui-btn {
        width: 100%;
        min-width: 0;
        flex-basis: auto;
    }

    .marketing-plan-control form {
        grid-template-columns: 1fr;
    }

    .marketing-plan-control form > label {
        grid-column: 1;
    }

    .marketing-plan-preview-empty {
        padding: 18px 8px;
    }

    .marketing-plan-preview-empty > h2 {
        font-size: 18px;
    }

    .marketing-plan-import-layer {
        padding: 14px;
    }

    .marketing-plan-import-summary {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
    }

    .marketing-plan-import-actions .layui-btn {
        flex: 1;
        margin: 0;
    }

    .marketing-plan-preview > .marketing-plan-preview-header {
        padding: 14px 16px;
    }

    .marketing-plan-markdown {
        padding: 18px 16px 24px;
    }

    .marketing-plan-preview-actions {
        padding: 10px 12px;
    }

    .marketing-plan-preview-actions .layui-btn {
        flex: 1;
        margin: 0;
    }
}

/* 商业账户入口复用侧栏底部空间，资金数据仅由本人摘要接口提供。 */
.commerce-sidebar-wallet { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: 8px; row-gap: 8px; padding: 10px; background: #f2f6ff; border: 1px solid #d9e3fb; border-radius: 8px; color: #52627a; }
.commerce-sidebar-wallet > span { font-size: 11px; line-height: 20px; }
.commerce-sidebar-wallet > strong { font-size: 17px; line-height: 22px; text-align: right; color: #2e68de; font-weight: 600; overflow-wrap: anywhere; }
.commerce-sidebar-actions { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 8px; }
.commerce-sidebar-actions > a,.commerce-sidebar-actions > button { display: flex; align-items: center; justify-content: center; gap: 5px; box-sizing: border-box; min-width: 0; height: 32px; padding: 0 6px; border-radius: 6px; font: inherit; font-size: 12px; line-height: 1; white-space: nowrap; cursor: pointer; }
.commerce-sidebar-recharge { background: #fff; border: 1px solid #d8e2f8; color: #356be9; }
.commerce-sidebar-recharge:hover { background: #eaf0ff; color: #2454c4; }
.commerce-sidebar-actions > .commerce-sidebar-buy { background: var(--primary,#356be9); border: 1px solid var(--primary,#356be9); color: #fff; font-weight: 600; box-shadow: 0 3px 8px #356be929; }
.commerce-sidebar-actions > .commerce-sidebar-buy:hover { background: #2454c4; border-color: #2454c4; }
.commerce-sidebar-buy .layui-icon { font-size: 14px; }
.commerce-sidebar-actions > :focus-visible { outline: 2px solid #356be9; outline-offset: 3px; }

/* 后台充值独占一行的字段保留完整上下间距。 */
#recharge-form > label { display: block; }
