:root {
  color-scheme: light;
  --canvas: #f8f6f2;
  --paper: #fffdfa;
  --ink: #30261f;
  --soft: #74665a;
  --muted: #776d63;
  --line: #e9e1d6;
  --line-soft: #f1ebe3;
  --gold: #956238;
  --gold-dark: #774926;
  --gold-pale: #f4e8d9;
  --green: #3e6856;
  --shadow: 0 2px 10px #3d281b06;
  font-family: "Segoe UI", "Microsoft YaHei UI", "PingFang SC", sans-serif;
  color: var(--ink);
  background: var(--canvas);
  font-synthesis: none;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 77px; }
body { margin: 0; min-width: 320px; min-height: 100vh; font-size: 14px; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .65; }
button, a { color: inherit; }
a { text-decoration: none; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 2px solid #a26b38; outline-offset: 3px; }
svg { flex: none; vertical-align: middle; }
h1, h2, h3, p { margin: 0; }
h1 { line-height: 1.2; font-size: 34px; letter-spacing: -.025em; }
h2 { font-size: 18px; line-height: 1.4; }
h3 { font-size: 14px; line-height: 1.5; }
p { line-height: 1.65; }
strong { font-weight: 650; }
.muted { color: var(--muted); }
.readable { line-height: 1.8; white-space: pre-wrap; overflow-wrap: anywhere; }
.loading { min-height: 85vh; display: grid; place-content: center; gap: 14px; text-align: center; padding: 18px; }
.brand { display: flex; align-items: center; gap: 12px; text-align: left; }
.brand > img { width: 44px; height: 44px; box-shadow: 0 3px 10px #44261121; border-radius: 12px; flex: none; }
.brand > div { display: grid; gap: 3px; }
.brand strong { font-size: 20px; color: #39291e; line-height: 1.15; letter-spacing: .025em; }
.brand span { font-size: 11px; font-weight: 550; letter-spacing: .13em; color: #7a6656; white-space: nowrap; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid transparent; padding: 9px 14px; min-height: 39px; border-radius: 9px; line-height: 1.35; font-weight: 600; background: transparent; white-space: nowrap; font-size: 13px; transition: background .15s, border-color .15s, color .15s; }
.btn.primary { background: #8d5931; color: white; border-color: #8d5931; box-shadow: 0 2px 4px #61341215; }
.btn.primary:hover { background: #734723; border-color: #734723; }
.btn.secondary { background: #fffdf9; color: #604a3a; border-color: #e7dbcc; }
.btn.secondary:hover { background: #f8efe3; border-color: #d8bea3; }
.btn.danger-outline { color: #913d35; border-color: #e8c4bd; background: #fff8f5; }
.btn.danger-outline:hover { background: #f8e5df; }
.btn.danger { color: white; border-color: #a34238; background: #a34238; }
.btn.danger:hover { background: #8e352e; }
.profile-removal { margin-right: auto; }
.btn.quiet, .btn.text { color: #87542e; }
.btn.quiet:hover, .btn.text:hover { background: var(--gold-pale); }
.btn.text { padding-inline: 4px; min-height: 28px; }
.btn.full { width: 100%; }
.icon-btn { display: inline-grid; place-items: center; border: 1px solid transparent; padding: 0; width: 37px; height: 37px; border-radius: 9px; background: transparent; color: #776556; flex: none; }
.icon-btn:hover { background: #f5ede2; color: var(--gold-dark); }
.kicker { color: #735339; font-weight: 650; font-size: 12px; letter-spacing: .04em; display: inline-flex; align-items: center; gap: 8px; line-height: 1.4; }
.kicker > i { width: 7px; height: 7px; border-radius: 50%; background: #a87342; display: inline-block; }
.kicker > span { color: #806d5a; font-weight: 500; padding-left: 8px; border-left: 1px solid #bc9d80; margin-left: 4px; font-size: 11px; }
.login-shell { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.28fr) minmax(410px, 1fr); }
.login-art { position: relative; isolation: isolate; padding: clamp(30px, 5.4vw, 82px); display: flex; flex-direction: column; justify-content: space-between; gap: 30px; overflow: hidden; background: linear-gradient(90deg,#fff4e644 1%,transparent 80%), url("/assets/champagne-planet.png") 64% center / cover; }
.login-art::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg,#fff4e9cc 0%,#fff5ebab 28%,transparent 77%); }
.login-art-copy { max-width: 430px; padding-bottom: 17vh; }
.login-art h1 { font-size: clamp(44px, 5.15vw, 79px); font-weight: 740; line-height: 1.12; margin: 18px 0; letter-spacing: -.075em; }
.login-art h1 span { color: #ab7343; }
.login-art p { font-size: clamp(13px, 1.15vw, 17px); color: #5b493c; max-width: 284px; margin-top: 18px; line-height: 1.9; }
.login-art-foot { display: flex; gap: 15px; justify-content: space-between; font-size: 11px; color: #765841; letter-spacing: .1em; font-weight: 650; }
.login-pane { display: grid; place-items: center; padding: 44px; background: #fffdf9; }
.login-form { width: min(100%, 355px); }
.login-icon { width: 48px; height: 48px; border-radius: 14px; background: #f3e7d8; color: #8d5931; display: grid; place-items: center; margin-bottom: 20px; }
.login-form h2 { font-size: 30px; letter-spacing: -.045em; margin-bottom: 7px; }
.login-form > p { color: var(--muted); margin-bottom: 26px; }
.login-form form { display: grid; gap: 15px; }
.login-form form .primary { margin-top: 5px; min-height: 45px; flex-direction: row-reverse; }
.login-switch { display: flex; align-items: center; gap: 2px; color: var(--muted); justify-content: center; margin-top: 14px; }
.login-or { display: flex; align-items: center; gap: 12px; margin: 16px 0; color: var(--muted); font-size: 12px; }
.login-or::before, .login-or::after { content: ""; height: 1px; background: var(--line); flex: 1; }
.login-form .local-note { display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 12px; margin: 22px 0 0; }
.shell { min-height: 100vh; display: grid; grid-template-columns: 218px minmax(0, 1fr); }
.sidebar { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; padding: 25px 15px 16px; border-right: 1px solid #eae2d7; background: #fcf9f4; overflow: auto; }
.brand-link { padding: 0 10px; width: fit-content; display: block; }
.nav-caption { color: #76685a; font-size: 11px; margin: 46px 0 11px 12px; font-weight: 650; letter-spacing: .11em; }
.system-caption { margin-top: 27px; }
.sidebar nav { display: grid; gap: 5px; }
.nav-item { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 10px 11px; border: 1px solid transparent; border-radius: 9px; color: #685a4d; font-weight: 580; }
.nav-item span { flex: 1; white-space: nowrap; }
.nav-item:hover { background: #f5eee4; }
.nav-item.active { background: #f2e6d6; border-color: #eaddcc; color: #754927; font-weight: 700; }
.sidebar-foot { margin-top: auto; padding-top: 30px; }
.local-status { display: flex; align-items: center; gap: 7px; color: #5e6d5b; font-size: 11px; margin: 0 8px 12px; }
.local-status span { width: 7px; height: 7px; background: #679074; border-radius: 50%; box-shadow: 0 0 0 3px #e7efe5; }
.profile { display: grid; grid-template-columns: 34px minmax(0,1fr) 27px; align-items: center; gap: 9px; border: 1px solid var(--line); border-radius: 11px; background: #fffaf3; padding: 8px 6px 8px 8px; }
.profile div:nth-child(2) { min-width: 0; }
.profile strong, .profile span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile strong { font-size: 12px; }
.profile span { font-size: 10px; margin-top: 2px; color: var(--muted); }
.profile .icon-btn { width: 26px; height: 28px; }
.avatar, .top-avatar { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; background: #ead6bb; color: #704321; font-size: 13px; font-weight: 700; }
.main-layout { min-width: 0; }
.topbar { min-height: 64px; position: sticky; top: 0; z-index: 3; background: #fbf8f3f5; border-bottom: 1px solid #ebe3d9; display: flex; align-items: center; justify-content: space-between; padding: 0 29px; gap: 12px; backdrop-filter: blur(12px); }
.crumb { display: flex; align-items: center; gap: 8px; color: #7d6e61; font-size: 12px; }
.crumb strong { color: var(--ink); }
.top-actions { display: flex; align-items: center; gap: 12px; }
.btn.search-btn { border-color: #ebe2d7; color: #766657; background: #fffcf7; min-height: 34px; min-width: 112px; padding: 6px 10px; justify-content: flex-start; }
.btn.search-btn:hover { border-color: #d3ab83; }
.top-actions .icon-btn { border-color: #ebe2d7; background: #fffcf7; width: 35px; height: 34px; }
.top-divider { height: 24px; width: 1px; background: var(--line); }
.top-avatar { width: 32px; height: 32px; border: 0; border-radius: 50%; cursor: pointer; }
.workspace { padding: 26px 29px 42px; max-width: 1470px; margin-inline: auto; }
.panel { background: var(--paper); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); min-width: 0; overflow: hidden; }
.workspace > .panel + .panel, .workspace > .split-grid + .panel { margin-top: 16px; }
.position-guide { margin-bottom: 13px; }
.icon-tile { width: 35px; height: 35px; display: inline-grid; place-items: center; border-radius: 9px; color: #936439; background: #f4e8d6; flex: none; }
.icon-tile.gold { color: #946335; background: #f5e8d5; }
.icon-tile.peach { color: #a06449; background: #f6e6db; }
.icon-tile.green { color: #50735b; background: #eaf0e5; }
.icon-tile.violet { color: #766282; background: #eee8f2; }
.panel-head { padding: 16px 19px; min-height: 59px; display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; border-bottom: 1px solid var(--line-soft); }
.panel-head h2 { overflow-wrap: anywhere; }
.panel-body { padding: 19px; }
.tabs { display: flex; align-items: center; gap: 4px; color: #725d4e; flex-wrap: wrap; }
.tabs.compact { background: #f6f1ea; padding: 3px; border-radius: 9px; }
.tabs .btn { font-weight: 600; }
.tabs.compact .btn { min-height: 26px; padding: 4px 8px; font-size: 11px; border-radius: 7px; }
.tabs .btn.selected { background: #fffdf9; border-color: #e7d8c7; color: #83532c; box-shadow: 0 1px 3px #44311f11; }
.tabs .btn:not(.selected):not(.primary):hover { background: #f4eadd; }
.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; margin: 5px 0 22px; }
.page-head h1 { overflow-wrap: anywhere; }
.page-head p { margin-top: 8px; color: var(--muted); }
.page-actions, .form-actions, .toolbar, .meta-line, .version-links { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.page-actions { padding-top: 2px; justify-content: flex-end; flex-shrink: 0; }
.panel .form-actions { padding-top: 3px; }
.stack { display: grid; gap: 15px; min-width: 0; }
.knowledge-choices { display: grid; gap: 7px; border: 1px solid var(--line); border-radius: 8px; padding: 8px 11px 10px; margin: 0; }
.knowledge-choices legend { padding: 0 4px; font-size: 12px; color: var(--soft); }
.knowledge-choices input { accent-color: var(--gold); }
.field { display: grid; gap: 6px; min-width: 0; align-content: start; }
.field > span { color: #594a3d; font-size: 12px; font-weight: 650; }
.field input, .field select, .field textarea { width: 100%; min-height: 40px; border-radius: 8px; color: var(--ink); background: #fffdfa; border: 1px solid #e4d7c8; padding: 9px 10px; line-height: 1.5; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: #ceae8e; }
.field input[type=file] { padding: 7px; }
.field textarea { resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: #82756a; }
.field select:disabled { opacity: .75; }
.form-grid, .split-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 14px; }
.form-grid.three, .info-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 14px; }
.split-grid { grid-template-columns: minmax(0,1.35fr) minmax(235px,1fr); align-items: start; }
.info { display: grid; gap: 5px; min-width: 0; align-content: start; }
.info span { color: var(--muted); font-size: 12px; }
.info strong { color: var(--ink); font-size: 13px; line-height: 1.6; overflow-wrap: anywhere; white-space: pre-wrap; }
.tag { font-size: 11px; font-weight: 650; display: inline-flex; align-items: center; min-height: 24px; padding: 3px 8px; border-radius: 6px; color: #675b50; background: #f0ece5; white-space: nowrap; width: fit-content; line-height: 1.3; }
.tag.gold { color: #81502a; background: #f6e9d6; } .tag.green { color: #3c644f; background: #e8f0e7; } .tag.rose { color: #903e49; background: #fae9e9; }
.tag.platform.red { color: #923f4e; background: #f9e9ec; } .tag.platform.douyin { color: #524563; background: #efeaf4; } .tag.platform.wechat { color: #3e6651; background: #e9f1e7; }
.empty { min-height: 175px; padding: 25px 18px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 8px; }
.empty > div { color: #956238; border-radius: 12px; display: grid; place-items: center; width: 43px; height: 43px; background: #f5ebde; }
.empty p { color: var(--muted); font-size: 12px; }
.empty .btn { margin-top: 5px; }
.platform-tabs { margin-bottom: 15px; }
.platform-tabs > .btn { min-height: 37px; padding-inline: 13px; }
.metric-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.metric-strip span { font-size: 11px; background: #f5f0e8; padding: 4px 8px; border-radius: 6px; color: var(--soft); }
.record-list { padding: 2px 15px; }
.record { display: flex; align-items: center; gap: 10px; min-height: 60px; padding: 9px 0; }
.record + .record { border-top: 1px solid var(--line-soft); }
.record-main { flex: 1; min-width: 0; }
.record-main strong { display: block; overflow-wrap: anywhere; }
.record-main span { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.toggle-list { display: grid; gap: 7px; }
.notice { display: flex; align-items: flex-start; gap: 9px; padding: 11px 12px; border-radius: 9px; background: #f7ecde; color: #6d4b31; line-height: 1.6; }
.subsection { border-top: 1px solid var(--line); padding-top: 14px; }
.subsection p { margin-top: 4px; }
.toggle { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 37px; padding: 5px 0; cursor: pointer; }
.toggle input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.toggle i { width: 37px; height: 21px; border-radius: 15px; background: #d8cdbf; position: relative; flex: none; }
.toggle i::after { content: ""; position: absolute; left: 3px; top: 3px; width: 15px; height: 15px; border-radius: 50%; background: white; transition: transform .15s; }
.toggle input:checked + i { background: #8d5931; }
.toggle input:checked + i::after { transform: translateX(16px); }
.toggle input:focus-visible + i { outline: 2px solid #a26b38; outline-offset: 3px; }
dialog { width: min(580px, calc(100vw - 24px)); max-height: calc(100vh - 30px); padding: 0; border: 1px solid #e2d1be; border-radius: 15px; color: var(--ink); background: var(--paper); box-shadow: 0 16px 70px #39231136; }
dialog::backdrop { background: #2d221a68; backdrop-filter: blur(2px); }
.dialog-head { display: flex; align-items: center; justify-content: space-between; gap: 9px; padding: 10px 15px 10px 19px; border-bottom: 1px solid var(--line); }
.dialog-body { padding: 17px 19px 19px; }
.dialog-body .form-actions { justify-content: flex-end; }
.dialog-error { margin-top: 12px; color: #8d3841; background: #f9eaea; padding: 8px 10px; border-radius: 8px; }
.toasts { position: fixed; right: 17px; bottom: 16px; z-index: 20; display: grid; gap: 8px; max-width: min(395px,calc(100vw - 34px)); pointer-events: none; }
.toast { background: #fffdfa; padding: 9px 13px 9px 10px; border: 1px solid #e2d3c2; border-radius: 10px; box-shadow: 0 8px 25px #41291925; display: flex; align-items: flex-start; gap: 8px; min-height: 48px; }
.toast strong { line-height: 1.5; color: #523c2d; }
.toast a { pointer-events: auto; }
.toast p { color: var(--muted); font-size: 12px; margin-top: 2px; overflow-wrap: anywhere; }
.toast.error { border-color: #dda8a0; }
dialog:has(form) { margin-bottom: min(15vh, 105px); }
@media (max-width: 1100px) {
  .shell { grid-template-columns: 184px minmax(0,1fr); }
  .sidebar { padding-inline: 11px; }
  .topbar, .workspace { padding-inline: 19px; }
  .page-head { flex-wrap: wrap; }
}
@media (max-width: 850px) {
  .shell { grid-template-columns: 61px minmax(0,1fr); }
  .sidebar { padding-inline: 7px; }
  .brand-link { padding-inline: 3px; }
  .sidebar .brand > div, .nav-caption, .nav-item span, .nav-item svg + span + svg, .profile div:nth-child(2), .profile .icon-btn, .local-status { display: none; }
  .sidebar nav { margin-top: 25px; }
  .nav-item { justify-content: center; }
  .sidebar > .nav-item { margin-top: 12px; }
  .profile { padding: 5px; display: grid; grid-template-columns: 1fr; place-items: center; }
  .login-shell { grid-template-columns: 1fr 1fr; }
  .login-pane { padding: 27px; }
  .login-art { padding: 26px; }
  .login-art-copy { padding-bottom: 7vh; }
}
@media (max-width: 650px) {
  .panel-head { flex-wrap: wrap; }
  .dialog-body .form-actions { flex-wrap: wrap; }
  .topbar, .workspace { padding-inline: 12px; }
  .topbar { min-height: 54px; }
  .top-actions { gap: 6px; }
  .btn.search-btn { min-width: 0; }
  .workspace { padding-top: 13px; }
  .split-grid, .form-grid, .form-grid.three, .info-grid { grid-template-columns: minmax(0,1fr); }
  .page-actions { flex-shrink: 1; justify-content: flex-start; }
  .page-head h1 { font-size: 26px; }
  .record { flex-wrap: wrap; }
  .record-main { min-width: 45%; }
  .login-shell { grid-template-columns: 1fr; }
  .login-art { min-height: 216px; gap: 16px; padding: 17px; }
  .login-art-copy { padding-bottom: 0; }
  .login-art h1 { font-size: 35px; margin: 6px 0; letter-spacing: -.035em; }
  .login-art h1 br { display: none; }
  .login-art p { margin-top: 4px; max-width: 225px; font-size: 12px; }
  .login-art-foot { display: none; }
  .login-pane { padding: 23px 18px; }
  .login-icon { display: none; }
  .login-form h2 { font-size: 23px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; } }
