:root {
  --ink: #182230;
  --muted: #6d7888;
  --line: #e4e8ee;
  --surface: #ffffff;
  --surface-soft: #f7f9fb;
  --brand: #225b52;
  --brand-dark: #173f3a;
  --brand-soft: #e5f1ed;
  --info: #2b6da8;
  --info-soft: #e8f2fc;
  --warning: #a36c15;
  --warning-soft: #fff6df;
  --danger: #a04444;
  --danger-soft: #fff0f0;
  --success: #25735b;
  --success-soft: #e8f6ee;
  --shadow: 0 10px 34px rgba(24, 34, 48, .07);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: #f7f8fa;
  line-height: 1.5;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: #f7f8fa; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .55; }
code { font-family: "SFMono-Regular", Consolas, monospace; font-size: .86em; color: #485568; }

.app-layout { display: flex; min-height: 100vh; }
.sidebar { width: 248px; background: #fbfcfd; border-right: 1px solid var(--line); display: flex; flex-direction: column; padding: 28px 16px 18px; position: fixed; top: 0; bottom: 0; z-index: 5; }
.brand { display: flex; align-items: center; gap: 11px; padding: 0 12px; }
.brand-mark { width: 34px; height: 34px; background: var(--brand); color: #fff; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: 19px; box-shadow: 0 4px 9px rgba(34, 91, 82, .23); }
.brand strong { display: block; font-size: 15px; letter-spacing: .02em; }
.brand small { color: var(--muted); font-size: 11px; margin-top: 1px; display: block; }
.main-nav { margin-top: 42px; display: grid; gap: 5px; }
.nav-link { display: flex; align-items: center; gap: 11px; padding: 11px 13px; color: #667283; border-radius: 9px; font-size: 14px; transition: background .15s, color .15s; }
.nav-link:hover { color: var(--brand); background: #eef5f2; }
.nav-link-active { background: var(--brand-soft); color: var(--brand-dark); font-weight: 700; }
.nav-icon { width: 17px; text-align: center; font-size: 17px; }
.sidebar-note { margin-top: auto; font-size: 11px; color: #738091; line-height: 1.65; padding: 13px 12px; background: #f2f5f7; border-radius: 9px; }
.sidebar-note div { padding-left: 18px; margin-top: 2px; color: #98a1ad; }
.dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; margin-right: 6px; vertical-align: 1px; }
.dot-green { background: #45a77d; }
.dot-blue { background: #4c8ab5; }
.page-column { flex: 1; margin-left: 248px; min-width: 0; }
.topbar { height: 68px; padding: 0 42px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; background: rgba(255, 255, 255, .85); backdrop-filter: blur(10px); position: sticky; top: 0; z-index: 4; }
.crumb { color: #4a5767; font-weight: 650; font-size: 14px; }
.user-menu { display: flex; align-items: center; gap: 9px; color: #556172; font-size: 13px; }
.avatar { width: 27px; height: 27px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; background: var(--brand-soft); color: var(--brand-dark); font-weight: 700; }
.role-chip { color: var(--brand); background: var(--brand-soft); padding: 2px 7px; border-radius: 5px; font-size: 11px; }
.main-content { max-width: 1240px; margin: 0 auto; padding: 42px 48px 70px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 30px; }
.eyebrow { color: var(--brand); font-size: 11px; letter-spacing: .09em; font-weight: 750; text-transform: uppercase; margin: 0 0 8px; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: 30px; line-height: 1.25; letter-spacing: -.02em; margin-bottom: 8px; }
h2 { font-size: 17px; }
h3 { font-size: 17px; line-height: 1.4; margin-bottom: 8px; }
.page-subtitle { color: var(--muted); margin: 0; font-size: 14px; }
.button { border: 1px solid transparent; display: inline-flex; align-items: center; justify-content: center; gap: 6px; border-radius: 7px; padding: 9px 15px; font-weight: 650; font-size: 13px; transition: all .15s; }
.button-primary { color: #fff; background: var(--brand); box-shadow: 0 3px 10px rgba(34, 91, 82, .16); }
.button-primary:hover { background: var(--brand-dark); }
.button-secondary { color: var(--brand); background: #fff; border-color: #c8ddd7; }
.button-secondary:hover { background: var(--brand-soft); }
.button-ghost { color: #687485; background: transparent; border-color: transparent; }
.button-ghost:hover { background: #f0f2f5; }
.button-small { padding: 5px 9px; font-size: 12px; }
.button-block { width: 100%; padding: 12px; }
.banner { display: flex; align-items: center; gap: 11px; padding: 11px 14px; border-radius: 8px; border: 1px solid; font-size: 13px; margin-bottom: 18px; }
.banner strong { white-space: nowrap; }
.banner span { color: #657284; flex: 1; }
.banner-info { color: var(--info); border-color: #c8dff1; background: var(--info-soft); }
.banner-warning { color: var(--warning); border-color: #eed594; background: var(--warning-soft); }
.banner-danger { color: var(--danger); border-color: #f0caca; background: var(--danger-soft); }
.banner-close { margin-left: auto; background: none; border: 0; color: currentColor; font-size: 19px; line-height: 1; }
.tabs { border-bottom: 1px solid var(--line); display: flex; gap: 23px; margin-bottom: 21px; }
.tab { position: relative; border: 0; background: transparent; color: #778394; font-size: 14px; font-weight: 650; padding: 0 2px 12px; }
.tab-active { color: var(--brand-dark); }
.tab-active::after { content: ''; height: 2px; background: var(--brand); border-radius: 2px; position: absolute; left: 0; right: 0; bottom: -1px; }
.filter-bar { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; margin-bottom: 22px; }
.search-box { display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 7px; background: #fff; padding: 0 11px; height: 38px; flex: 1 1 260px; max-width: 370px; color: #94a0af; }
.search-box input { border: 0; outline: 0; flex: 1; min-width: 0; color: var(--ink); font-size: 13px; }
.filter-bar select, .filter-bar > input { height: 38px; border: 1px solid var(--line); border-radius: 7px; background: #fff; padding: 0 10px; color: #5d6979; min-width: 125px; outline: 0; font-size: 13px; }
.filter-bar select:focus, .filter-bar input:focus, input:focus, label select:focus { border-color: #76a89c; box-shadow: 0 0 0 3px rgba(62, 130, 115, .12); }
.list-caption { display: flex; gap: 12px; align-items: center; color: #637083; font-size: 12px; margin: 0 0 12px; }
.caption-note { color: #a0a8b3; }
.content-list { display: grid; gap: 13px; }
.content-card { display: flex; justify-content: space-between; gap: 22px; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 19px 20px; box-shadow: 0 2px 8px rgba(26, 37, 51, .025); transition: box-shadow .2s, border-color .2s; }
.content-card:hover { border-color: #cbded9; box-shadow: var(--shadow); }
.card-main { min-width: 0; flex: 1; }
.card-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.card-kicker { display: flex; gap: 7px; align-items: center; color: #8d98a7; font-size: 11px; }
.platform-tag { display: inline-flex; border-radius: 4px; background: #f3e9e2; color: #9d5f35; padding: 2px 5px; font-size: 11px; }
.content-card h3 a { color: var(--ink); }
.content-card h3 a:hover, .text-link:hover { color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }
.card-summary { color: #637083; font-size: 13px; margin-bottom: 11px; }
.card-meta { display: flex; gap: 17px; color: #98a1ad; font-size: 11px; flex-wrap: wrap; }
.analysis-strip { display: flex; gap: 9px; align-items: baseline; flex-wrap: wrap; background: #f7faf9; border-left: 2px solid #94bdb3; margin-top: 13px; padding: 8px 10px; color: #657a77; font-size: 12px; }
.analysis-strip strong { color: var(--brand); }
.analysis-label { color: #7a8d89; font-size: 11px; }
.analysis-muted { background: #f8f9fb; border-color: #cfd5dc; color: #8490a0; }
.card-footer { display: flex; gap: 15px; margin-top: 14px; }
.text-link { color: var(--brand); font-weight: 650; font-size: 12px; }
.text-link.secondary { color: #7d8996; font-weight: 500; }
.media-placeholder { width: 108px; height: 78px; border-radius: 7px; background: linear-gradient(135deg, #edf1f3, #f7f8fa); color: #9ca6b2; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: 11px; flex: none; }
.media-placeholder span { font-size: 22px; color: #a9b8b9; }
.status { display: inline-flex; align-items: center; border-radius: 5px; padding: 3px 7px; font-size: 11px; white-space: nowrap; font-weight: 650; }
.status-success { color: var(--success); background: var(--success-soft); }
.status-info { color: var(--info); background: var(--info-soft); }
.status-warning { color: var(--warning); background: var(--warning-soft); }
.status-danger { color: var(--danger); background: var(--danger-soft); }
.status-muted { color: #778394; background: #f0f2f5; }
.empty-state { background: #fff; border: 1px dashed #d7dde5; border-radius: 10px; padding: 64px 24px; text-align: center; color: var(--muted); }
.empty-icon { color: #9ebeb7; background: var(--brand-soft); width: 42px; height: 42px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; font-size: 23px; }
.empty-state h3 { color: #4e5c6c; margin: 14px 0 5px; }
.empty-state p { font-size: 13px; margin: 0; }
.loading-state { display: flex; justify-content: center; align-items: center; gap: 9px; color: #748091; min-height: 260px; font-size: 13px; }
.spinner { width: 15px; height: 15px; border: 2px solid #d1dfdc; border-top-color: var(--brand); border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.load-more { margin: 22px auto 0; display: flex; }

.detail-page { max-width: 1080px; margin: 0 auto; }
.detail-toolbar { display: flex; align-items: center; justify-content: space-between; margin: -8px 0 20px; }
.back-link { color: var(--brand); font-size: 13px; font-weight: 650; }
.detail-id { color: #9ca5b1; font-size: 11px; font-family: monospace; }
.detail-grid { display: grid; grid-template-columns: minmax(0, 1fr) 285px; gap: 18px; align-items: start; }
.detail-card { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 23px; }
.detail-card-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; border-bottom: 1px solid var(--line); padding-bottom: 18px; margin-bottom: 19px; }
.detail-card h1 { font-size: 24px; margin: 10px 0 7px; }
.muted { color: var(--muted); font-size: 12px; }
.notice { padding: 10px 12px; border-radius: 6px; font-size: 12px; margin-bottom: 22px; }
.notice-info { color: #647586; background: #f1f7f6; border-left: 3px solid #91bdb3; }
.decision-section { border-top: 1px solid var(--line); padding: 19px 0 2px; }
.decision-section:first-of-type { border-top: 0; padding-top: 0; }
.decision-section h2 { margin-bottom: 13px; }
.decision-value { display: inline-flex; border-radius: 6px; padding: 5px 10px; font-weight: 700; font-size: 13px; margin-bottom: 14px; }
.decision-include { background: var(--success-soft); color: var(--success); }
.decision-exclude { background: #f0f2f5; color: #667382; }
.decision-uncertain { background: var(--warning-soft); color: var(--warning); }
.detail-dl { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 9px 14px; margin: 0; font-size: 13px; }
.detail-dl dt { color: #96a0ad; }
.detail-dl dd { margin: 0; color: #4f5c6a; overflow-wrap: anywhere; }
.evidence-list { display: flex; flex-wrap: wrap; gap: 8px; }
.evidence { color: #52776f; background: #eef7f4; border: 1px solid #d5eae3; border-radius: 5px; padding: 6px 8px; font-size: 12px; }
.evidence small { color: #96aaa5; margin-left: 5px; }
.plain-list { color: #586676; padding-left: 19px; font-size: 13px; margin-bottom: 0; }
.technical-details { border-top: 1px solid var(--line); margin-top: 22px; padding-top: 17px; }
.technical-details summary { color: #718092; cursor: pointer; font-size: 12px; }
.technical-details .detail-dl { margin-top: 15px; }
.original-summary h2 { font-size: 15px; }
.original-summary p { color: #637083; font-size: 13px; line-height: 1.75; }
.tag-list { display: flex; flex-wrap: wrap; gap: 6px; margin: 20px 0 23px; }
.tag { background: #f2f4f6; color: #7d8793; border-radius: 4px; padding: 3px 7px; font-size: 11px; }
.empty-inline { padding: 15px 0; color: var(--muted); }
.empty-inline h2 { color: #536172; margin-bottom: 7px; }
.history-title { font-size: 14px; border-top: 1px solid var(--line); padding-top: 18px; margin-top: 22px; }
.history-list { display: grid; gap: 8px; }
.history-item { padding: 9px 10px; background: #f8fafb; border-radius: 6px; display: grid; gap: 3px; font-size: 12px; }
.history-item small { color: #8e99a6; }
.original-body, .original-fields, .original-media { border-top: 1px solid var(--line); padding-top: 19px; margin-top: 19px; }
.original-body h2, .original-fields h2, .original-media h2 { font-size: 15px; margin-bottom: 11px; }
.original-body p { color: #4f5d6c; line-height: 1.85; font-size: 14px; white-space: pre-wrap; }
.media-grid { display: flex; flex-wrap: wrap; gap: 10px; }
.media-card { display: grid; gap: 5px; color: #8a95a2; font-size: 11px; }

.settings-form, .settings-info, .operation-card, .reprocess-start, .preview-placeholder { background: #fff; border: 1px solid var(--line); border-radius: 10px; }
.settings-form { padding: 27px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 21px 24px; }
.form-grid label, .login-card label { color: #596677; font-size: 13px; display: grid; gap: 7px; }
.form-grid label > input, .form-grid label > select, .login-card label > input { height: 40px; border: 1px solid #dce2e8; border-radius: 6px; padding: 0 11px; color: var(--ink); background: #fff; outline: 0; }
.form-grid small { color: #98a2af; font-size: 11px; line-height: 1.5; }
.checkline { display: flex !important; grid-template-columns: none !important; align-items: center; gap: 6px; color: #8f5960 !important; font-size: 11px !important; }
.checkline input { width: 13px; height: 13px; }
.switch-row { display: flex !important; align-items: center; gap: 11px; padding-top: 25px; }
.switch-row > span:first-child { display: grid; gap: 3px; flex: 1; }
.switch-row input { position: absolute; opacity: 0; pointer-events: none; }
.switch { width: 42px; height: 24px; background: #d8dee5; border-radius: 20px; position: relative; transition: background .2s; }
.switch::after { content: ''; width: 18px; height: 18px; border-radius: 50%; background: #fff; position: absolute; top: 3px; left: 3px; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: left .2s; }
.switch-row input:checked + .switch { background: var(--brand); }
.switch-row input:checked + .switch::after { left: 21px; }
.form-actions { display: flex; align-items: center; gap: 12px; margin-top: 28px; border-top: 1px solid var(--line); padding-top: 19px; }
.form-feedback { font-size: 12px; }
.feedback-success { color: var(--success); }
.feedback-error { color: var(--danger); }
.settings-info { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--line); margin-top: 18px; overflow: hidden; }
.settings-info > div { background: #fff; padding: 18px 21px; }
.settings-info h2 { font-size: 13px; margin-bottom: 7px; }
.settings-info p { color: #667384; font-size: 12px; margin-bottom: 4px; }
.settings-info small { color: #9aa4b0; font-size: 11px; }

.task-toolbar { display: flex; justify-content: space-between; align-items: center; gap: 14px; margin-bottom: 17px; }
.filter-bar.compact { margin: 0; }
.table-wrap { background: #fff; border: 1px solid var(--line); border-radius: 10px; overflow-x: auto; }
table { border-collapse: collapse; width: 100%; font-size: 12px; min-width: 770px; }
th, td { text-align: left; padding: 13px 15px; border-bottom: 1px solid #edf0f3; vertical-align: middle; }
th { color: #8b96a3; background: #fafbfc; font-size: 11px; font-weight: 650; }
tr:last-child td { border-bottom: 0; }
td { color: #5f6b7b; }
td small { display: block; color: #9ca6b2; margin-top: 3px; font-size: 10px; }
.error-note { color: var(--danger) !important; max-width: 160px; }
.operation-card { padding: 22px; margin-bottom: 17px; }
.operation-head { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 19px; }
.operation-head h2 { margin: 3px 0 0; }
.progress { background: #eaf0ee; height: 8px; border-radius: 6px; overflow: hidden; }
.progress span { display: block; height: 100%; background: var(--brand); border-radius: inherit; transition: width .4s; }
.progress-stats { display: flex; justify-content: space-between; color: #7e8997; font-size: 12px; margin: 10px 0 17px; }
.operation-actions { display: flex; gap: 8px; }
.reprocess-start { padding: 23px; display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.reprocess-start h2 { margin-bottom: 5px; }
.reprocess-start p { margin: 0; color: #748091; font-size: 13px; }
.preview-placeholder { padding: 26px; margin-top: 16px; color: #98a2ae; font-size: 13px; text-align: center; border-style: dashed; }

.center-state { text-align: center; padding: 90px 20px; }
.forbidden-code { color: #c0d5cf; font-size: 62px; font-weight: 800; line-height: 1; letter-spacing: .04em; }
.center-state h1 { margin: 18px 0 7px; font-size: 22px; }
.center-state p { color: var(--muted); font-size: 13px; margin-bottom: 22px; }

.login-layout { min-height: 100vh; display: grid; grid-template-columns: minmax(320px, 1fr) minmax(420px, 520px); background: #fff; }
.login-art { background: linear-gradient(145deg, #173f3a 0%, #225b52 57%, #438075 100%); color: #fff; padding: 39px clamp(30px, 7vw, 100px); position: relative; overflow: hidden; display: flex; flex-direction: column; }
.login-art::before, .login-art::after { content: ''; position: absolute; border: 1px solid rgba(255,255,255,.11); border-radius: 50%; width: 500px; height: 500px; right: -190px; bottom: -195px; }
.login-art::after { width: 300px; height: 300px; right: -74px; bottom: -90px; }
.login-art .brand { padding: 0; position: relative; z-index: 1; }
.login-art .brand small { color: rgba(255,255,255,.58); }
.login-message { position: relative; z-index: 1; margin-top: auto; margin-bottom: 16vh; max-width: 430px; }
.login-message .eyebrow { color: #a9d6ca; }
.login-message h1 { font-size: clamp(32px, 4vw, 48px); letter-spacing: -.045em; margin-bottom: 18px; }
.login-message h1 em { color: #b9e1d5; font-style: normal; }
.login-message p:last-child { color: rgba(255,255,255,.7); line-height: 1.8; font-size: 14px; max-width: 330px; }
.login-art-footer { color: rgba(255,255,255,.45); font-size: 11px; position: relative; z-index: 1; }
.login-panel { display: flex; align-items: center; justify-content: center; padding: 30px; }
.login-card { width: 100%; max-width: 345px; }
.mobile-brand { display: none; }
.login-card h1 { font-size: 27px; margin-bottom: 7px; }
.login-subtitle { color: var(--muted); font-size: 13px; margin-bottom: 29px; }
.login-card form { display: grid; gap: 17px; }
.login-card label > input { height: 43px; }
.login-card .button { margin-top: 5px; }
.field-error { background: var(--danger-soft); border: 1px solid #f0caca; color: var(--danger); padding: 9px 10px; border-radius: 6px; font-size: 12px; margin-top: -3px; }
.login-hint { color: #a4acb6; line-height: 1.65; font-size: 11px; margin-top: 20px; }

@media (max-width: 920px) {
  .sidebar { width: 210px; }
  .page-column { margin-left: 210px; }
  .main-content { padding-left: 28px; padding-right: 28px; }
  .topbar { padding: 0 28px; }
  .detail-grid { grid-template-columns: 1fr; }
  .original-summary { order: -1; }
}
@media (max-width: 680px) {
  .sidebar { width: 100%; height: 60px; bottom: auto; padding: 0 12px; flex-direction: row; align-items: center; border-right: 0; border-bottom: 1px solid var(--line); }
  .sidebar .brand { padding: 0; }
  .sidebar .brand small, .sidebar-note { display: none; }
  .main-nav { margin: 0 0 0 auto; display: flex; gap: 2px; }
  .nav-link { font-size: 0; padding: 8px; }
  .nav-link .nav-icon { font-size: 18px; }
  .page-column { margin-left: 0; padding-top: 60px; }
  .topbar { top: 60px; height: 55px; padding: 0 16px; }
  .user-menu > span:not(.avatar):not(.role-chip) { display: none; }
  .main-content { padding: 26px 15px 48px; }
  .page-head { align-items: flex-start; margin-bottom: 22px; }
  .page-head > .button { padding: 7px 9px; font-size: 11px; }
  h1 { font-size: 25px; }
  .content-card { padding: 15px; }
  .media-placeholder { width: 67px; height: 58px; }
  .card-meta { gap: 6px 11px; }
  .filter-bar { gap: 7px; }
  .search-box { max-width: none; flex-basis: 100%; }
  .filter-bar select { flex: 1; min-width: 0; }
  .filter-bar .button { flex: 1; }
  .detail-card { padding: 17px; }
  .detail-card-header { display: block; }
  .detail-card-header > .status { margin-top: 12px; }
  .detail-card h1 { font-size: 21px; }
  .form-grid, .settings-info { grid-template-columns: 1fr; }
  .settings-form { padding: 18px; }
  .form-actions { flex-wrap: wrap; }
  .task-toolbar { align-items: stretch; flex-direction: column; }
  .task-toolbar .filter-bar { width: 100%; }
  .reprocess-start { display: block; }
  .reprocess-start .button { margin-top: 15px; }
  .progress-stats { display: grid; gap: 5px; }
  .login-layout { display: block; }
  .login-art { min-height: 235px; padding: 25px 22px; }
  .login-message { margin: 43px 0 0; }
  .login-message h1 { font-size: 30px; }
  .login-message p:last-child, .login-art-footer { display: none; }
  .login-panel { padding: 36px 22px; }
  .mobile-brand { display: flex; align-items: center; gap: 9px; margin-bottom: 31px; color: var(--brand-dark); }
  .mobile-brand .brand-mark { width: 30px; height: 30px; font-size: 16px; }
}
