/* =========================================================
   乐博文化传媒 · 官网内容管理系统
   ========================================================= */

:root {
  --ink: #10120f;
  --ink-2: #181b16;
  --paper: #f2ede3;
  --paper-2: #e9e1d4;
  --panel: #fffdf8;
  --accent: #b6543c;
  --accent-deep: #8f3b28;
  --muted: #857e71;
  --line: rgba(16, 18, 15, 0.13);
  --line-strong: rgba(16, 18, 15, 0.25);
  --serif: "Source Han Serif SC", "Noto Serif SC", "Songti SC", "STSong", "SimSun", serif;
  --sans: "Source Han Sans SC", "Noto Sans SC", "PingFang SC", "Microsoft YaHei UI", "Microsoft YaHei", sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --side: 272px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
body.modal-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
img { display: block; max-width: 100%; }
h1, h2, h3, h4, p { margin: 0; }
::selection { background: var(--accent); color: #fff; }
.arrow { font-size: 13px; }

/* ---------- 通用按钮 / 表单 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  height: 44px;
  padding: 0 20px;
  border: 1px solid transparent;
  background: transparent;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  transition: background 0.3s, border-color 0.3s, color 0.3s;
  white-space: nowrap;
}
.btn-accent { background: var(--accent); border-color: var(--accent); color: #fff8ef; }
.btn-accent:hover { background: var(--accent-deep); border-color: var(--accent-deep); }
.btn-line { border-color: var(--line-strong); }
.btn-line:hover { border-color: var(--accent); color: var(--accent); }
.btn-ghost { color: var(--muted); }
.btn-ghost:hover { color: var(--ink); }
.btn-small { height: 36px; padding: 0 14px; font-size: 11px; }
.btn-wide { width: 100%; }
.btn-danger { border-color: rgba(143, 59, 40, 0.35); color: var(--accent-deep); }
.btn-danger:hover { background: var(--accent-deep); border-color: var(--accent-deep); color: #fff; }
.btn:disabled { opacity: 0.55; cursor: wait; }

.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field > label, .field-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: #5b554a;
}
.field > label em { font-style: normal; color: var(--accent); }
.field .hint { font-size: 10px; line-height: 1.6; color: #9a9284; }
.detail-text {
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  background: #f8f4eb;
  font-size: 13px;
  line-height: 1.7;
  color: var(--ink);
}
.detail-text a { color: var(--accent-deep); text-decoration: underline; text-underline-offset: 3px; }
.detail-content { min-height: 120px; white-space: normal; }
.field input[type="text"], .field input[type="password"], .field input[type="email"], .field input[type="tel"],
.field input[type="number"], .field select, .field textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 0;
  background: #fffefb;
  padding: 10px 12px;
  font-size: 13px;
  outline: none;
  transition: border-color 0.25s, box-shadow 0.25s;
}
.field textarea { min-height: 96px; resize: vertical; line-height: 1.7; }
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(182, 84, 60, 0.08);
}
.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field.wide { grid-column: 1 / -1; }
.check-field {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 40px;
  font-size: 12px;
  color: #4f4a40;
}
.check-field input { width: 16px; height: 16px; accent-color: var(--accent); }
.color-field { display: flex; align-items: center; gap: 10px; }
.color-field input[type="color"] {
  width: 46px;
  height: 38px;
  padding: 3px;
  border: 1px solid var(--line);
  background: #fff;
}
.color-field code { font-size: 11px; color: var(--muted); }

/* ---------- 登录 ---------- */
.login-view {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(400px, 0.88fr);
  background: var(--paper);
}
.login-visual { position: relative; overflow: hidden; min-height: 100vh; background: var(--ink); }
.login-visual > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.login-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(8, 9, 8, 0.82) 0%, rgba(8, 9, 8, 0.45) 55%, rgba(8, 9, 8, 0.3) 100%),
    linear-gradient(0deg, rgba(8, 9, 8, 0.82) 0%, transparent 55%, rgba(8, 9, 8, 0.3) 100%);
}
.login-visual-top {
  position: absolute;
  top: 38px;
  left: 44px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 14px;
  color: #f2ede3;
}
.login-brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(242, 237, 227, 0.5);
  color: #f2ede3;
  font-family: var(--serif);
  font-size: 24px;
}
.login-brand-en { font-size: 8px; letter-spacing: 0.24em; color: rgba(242, 237, 227, 0.68); }
.login-visual-copy { position: absolute; left: 44px; right: 44px; bottom: 116px; z-index: 2; color: #f2ede3; }
.login-visual-copy p { font-size: 9px; letter-spacing: 0.3em; color: rgba(242, 237, 227, 0.6); }
.login-visual-copy h1 {
  margin: 18px 0 22px;
  font-family: var(--serif);
  font-size: clamp(2.5rem, 4.4vw, 4.4rem);
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.02em;
}
.login-visual-copy span { font-size: 11px; letter-spacing: 0.1em; color: rgba(242, 237, 227, 0.64); }
.login-visual-foot {
  position: absolute;
  left: 44px;
  right: 44px;
  bottom: 32px;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  padding-top: 16px;
  border-top: 1px solid rgba(242, 237, 227, 0.16);
  font-size: 8px;
  letter-spacing: 0.16em;
  color: rgba(242, 237, 227, 0.42);
}
.login-panel { position: relative; display: flex; flex-direction: column; justify-content: center; padding: 64px 8vw; }
.login-box { width: min(390px, 100%); margin: 0 auto; }
.login-brand-mobile { display: none; align-items: center; gap: 12px; margin-bottom: 32px; }
.login-brand-mobile .login-brand-mark { border-color: var(--line-strong); color: var(--accent); }
.login-brand-mobile b { font-family: var(--serif); font-size: 18px; font-weight: 600; }
.login-kicker { font-size: 9px; font-weight: 600; letter-spacing: 0.28em; color: var(--accent); }
.login-box h2 { margin: 12px 0 8px; font-family: var(--serif); font-size: 34px; font-weight: 600; letter-spacing: -0.02em; }
.login-sub { margin-bottom: 34px; font-size: 12px; color: var(--muted); }
.login-field { display: flex; flex-direction: column; gap: 8px; margin-bottom: 18px; }
.login-field span { font-size: 11px; font-weight: 600; letter-spacing: 0.05em; color: #5b554a; }
.login-field input {
  width: 100%;
  height: 48px;
  border: 1px solid var(--line);
  background: #fffefb;
  padding: 0 13px;
  font-size: 13px;
  outline: none;
  transition: border-color 0.25s, box-shadow 0.25s;
}
.login-field input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(182, 84, 60, 0.08); }
.login-error { min-height: 18px; margin: -4px 0 10px; font-size: 11px; color: var(--accent-deep); }
.login-tip { margin-top: 22px; font-size: 10px; line-height: 1.8; color: #9a9284; }
.login-tip b { color: #655e52; font-weight: 600; }
.login-site-link {
  display: inline-block;
  margin-top: 28px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--line-strong);
  font-size: 10px;
  letter-spacing: 0.08em;
  color: #655e52;
}
.login-site-link:hover { color: var(--accent); border-color: var(--accent); }
.login-panel-foot {
  position: absolute;
  left: 8vw;
  right: 8vw;
  bottom: 28px;
  display: flex;
  justify-content: space-between;
  font-size: 8px;
  letter-spacing: 0.14em;
  color: #a89f90;
}

/* ---------- 应用框架 ---------- */
.app-view { min-height: 100vh; display: grid; grid-template-columns: var(--side) minmax(0, 1fr); }
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--ink);
  color: rgba(242, 237, 227, 0.78);
  overflow: hidden;
  z-index: 50;
}
.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 26px 24px 24px;
  border-bottom: 1px solid rgba(242, 237, 227, 0.1);
}
.side-mark {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid rgba(242, 237, 227, 0.32);
  color: #f2ede3;
  font-family: var(--serif);
  font-size: 23px;
  flex: none;
}
.side-brand-text { display: flex; flex-direction: column; gap: 3px; line-height: 1.2; min-width: 0; }
.side-brand-text b { font-family: var(--serif); font-size: 17px; font-weight: 600; color: #f2ede3; letter-spacing: 0.06em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-brand-text small { font-size: 7px; letter-spacing: 0.22em; color: rgba(242, 237, 227, 0.4); }
.side-nav { flex: 1; overflow-y: auto; padding: 20px 14px 28px; scrollbar-width: thin; scrollbar-color: rgba(242,237,227,.2) transparent; }
.side-group { margin-bottom: 22px; }
.side-group-label { display: block; padding: 0 12px 8px; font-size: 8px; letter-spacing: 0.2em; color: rgba(242, 237, 227, 0.32); }
.side-nav a {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  margin-bottom: 2px;
  font-size: 12px;
  letter-spacing: 0.04em;
  transition: background 0.25s, color 0.25s;
}
.side-nav a i { font-style: normal; font-size: 8px; letter-spacing: 0.08em; color: rgba(242, 237, 227, 0.3); width: 18px; }
.side-nav a span { flex: 1; }
.side-nav a:hover { background: rgba(242, 237, 227, 0.06); color: #f2ede3; }
.side-nav a.is-active { background: rgba(182, 84, 60, 0.17); color: #fff8ef; }
.side-nav a.is-active::before { content: ""; position: absolute; left: 0; top: 8px; bottom: 8px; width: 2px; background: var(--accent); }
.side-nav a.is-active i { color: var(--accent); }
.nav-badge {
  display: grid;
  place-items: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 9px;
  background: var(--accent);
  color: #fff;
  font-size: 9px;
  font-weight: 600;
}
.sidebar-foot { padding: 18px 24px 22px; border-top: 1px solid rgba(242, 237, 227, 0.1); display: flex; flex-direction: column; gap: 10px; }
.sidebar-foot a, .sidebar-foot button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border: 0;
  background: transparent;
  padding: 0;
  font-size: 10px;
  letter-spacing: 0.08em;
  color: rgba(242, 237, 227, 0.52);
  text-align: left;
  transition: color 0.25s;
}
.sidebar-foot a:hover, .sidebar-foot button:hover { color: #f2ede3; }
.sidebar-foot span { font-size: 12px; }

.app-main { min-width: 0; display: flex; flex-direction: column; min-height: 100vh; }
.topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 88px;
  padding: 16px 44px;
  background: rgba(242, 237, 227, 0.94);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.topbar-left { display: flex; align-items: center; gap: 16px; }
.topbar-kicker { font-size: 8px; letter-spacing: 0.2em; color: var(--muted); }
.topbar-kicker b { color: var(--accent); font-weight: 600; }
.topbar h1 { margin-top: 4px; font-family: var(--serif); font-size: 26px; font-weight: 600; letter-spacing: -0.01em; }
.topbar-right { display: flex; align-items: center; gap: 18px; }
.topbar-user { font-size: 11px; color: var(--muted); }
.topbar-user::before { content: "●"; color: #6d8c5b; font-size: 7px; margin-right: 7px; vertical-align: 1px; }
.side-toggle {
  display: none;
  width: 40px;
  height: 40px;
  padding: 11px 8px;
  border: 1px solid var(--line);
  background: transparent;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
}
.side-toggle span { display: block; width: 22px; height: 1px; background: var(--ink); }
.content { flex: 1; width: 100%; max-width: 1420px; margin: 0 auto; padding: 36px 44px 60px; }
.app-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 44px;
  border-top: 1px solid var(--line);
  font-size: 9px;
  letter-spacing: 0.08em;
  color: #a39a8b;
}

/* ---------- 页面头 / 卡片 ---------- */
.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 28px;
}
.page-head h2 { font-family: var(--serif); font-size: 30px; font-weight: 600; letter-spacing: -0.02em; }
.page-head p { margin-top: 7px; font-size: 12px; color: var(--muted); max-width: 640px; }
.page-actions { display: flex; align-items: center; gap: 10px; flex: none; }
.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 26px;
}
.panel + .panel { margin-top: 20px; }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 18px; }
.panel-head h3 { font-family: var(--serif); font-size: 19px; font-weight: 600; }
.panel-head p { margin-top: 4px; font-size: 10px; color: var(--muted); }
.panel-kicker { font-size: 8px; font-weight: 600; letter-spacing: 0.2em; color: var(--accent); margin-bottom: 5px; }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 20px; }
.stat-card { background: var(--panel); border: 1px solid var(--line); padding: 22px 22px 18px; position: relative; overflow: hidden; }
.stat-card::after { content: ""; position: absolute; left: 0; top: 0; width: 2px; height: 44px; background: var(--accent); }
.stat-label { font-size: 10px; letter-spacing: 0.08em; color: var(--muted); }
.stat-value { margin-top: 12px; font-family: var(--serif); font-size: 46px; font-weight: 600; line-height: 1; letter-spacing: -0.04em; }
.stat-value small { font-family: var(--sans); font-size: 12px; font-weight: 400; color: var(--muted); margin-left: 5px; letter-spacing: 0; }
.stat-note { margin-top: 12px; font-size: 10px; color: #9a9284; }
.stat-card.is-accent { background: var(--ink); color: #f2ede3; border-color: var(--ink); }
.stat-card.is-accent .stat-label, .stat-card.is-accent .stat-note { color: rgba(242, 237, 227, 0.6); }
.stat-card.is-accent::after { width: 3px; height: 100%; opacity: 0.8; }
.dash-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.9fr); gap: 20px; align-items: start; }
.bar-row { display: grid; grid-template-columns: 84px 1fr 40px; align-items: center; gap: 12px; padding: 9px 0; font-size: 11px; }
.bar-row span:first-child { color: #5f5950; }
.bar-track { height: 4px; background: var(--paper-2); overflow: hidden; }
.bar-fill { height: 100%; background: var(--accent); transform-origin: left; transition: width 0.8s var(--ease); }
.bar-row b { text-align: right; font-family: var(--serif); font-size: 13px; font-weight: 600; }
.quick-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.quick-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 14px;
  border: 1px solid var(--line);
  background: transparent;
  font-size: 11px;
  text-align: left;
  transition: border-color 0.25s, color 0.25s, background 0.25s;
}
.quick-btn:hover { border-color: var(--accent); color: var(--accent); background: #fffaf2; }
.quick-btn span:last-child { color: var(--muted); }
.recent-list { display: flex; flex-direction: column; }
.recent-item { display: flex; align-items: flex-start; gap: 14px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.recent-item:last-child { border-bottom: 0; padding-bottom: 0; }
.recent-dot { width: 6px; height: 6px; margin-top: 8px; border-radius: 50%; background: var(--accent); flex: none; }
.recent-dot.is-read { background: #c9c1b3; }
.recent-main { flex: 1; min-width: 0; }
.recent-main b { display: block; font-size: 12px; font-weight: 600; }
.recent-main p { margin-top: 2px; font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.recent-time { flex: none; font-size: 9px; color: #a39a8b; }
.empty-state { padding: 40px 20px; text-align: center; color: var(--muted); font-size: 12px; }
.empty-state b { display: block; font-family: var(--serif); font-size: 20px; color: var(--ink); margin-bottom: 7px; font-weight: 600; }

/* ---------- 表格 ---------- */
.table-wrap { background: var(--panel); border: 1px solid var(--line); overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; min-width: 680px; }
.data-table th {
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  background: #f8f4ec;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: #837b6e;
  text-align: left;
  white-space: nowrap;
}
.data-table td { padding: 13px 16px; border-bottom: 1px solid var(--line); font-size: 12px; vertical-align: middle; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover { background: #fffaf2; }
.data-table .thumb {
  width: 64px;
  height: 44px;
  background: var(--paper-2);
  object-fit: cover;
  border: 1px solid var(--line);
}
.data-table .thumb-empty { width: 64px; height: 44px; display: grid; place-items: center; border: 1px dashed var(--line-strong); color: #b3aa9b; font-size: 8px; }
.cell-title { display: flex; flex-direction: column; gap: 2px; min-width: 150px; }
.cell-title b { font-size: 12px; font-weight: 600; }
.cell-title span { font-size: 9px; color: var(--muted); }
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  border: 1px solid var(--line);
  font-size: 9px;
  letter-spacing: 0.04em;
  color: var(--muted);
  white-space: nowrap;
}
.badge::before { content: ""; width: 4px; height: 4px; border-radius: 50%; background: #b3aa9b; }
.badge.is-on { color: #5c7150; border-color: rgba(92, 113, 80, 0.3); }
.badge.is-on::before { background: #6d8c5b; }
.badge.is-off { color: #9b9183; }
.row-actions { display: flex; align-items: center; gap: 12px; white-space: nowrap; }
.row-actions button { border: 0; background: transparent; padding: 2px 0; font-size: 10px; color: #6c655a; transition: color 0.2s; }
.row-actions button:hover { color: var(--accent); }
.row-actions .del:hover { color: var(--accent-deep); }
.drag-note { font-size: 8px; letter-spacing: 0.08em; color: #aaa193; }

/* ---------- 设置 / 文案 ---------- */
.settings-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr); gap: 20px; align-items: stretch; }
.settings-card { background: var(--panel); border: 1px solid var(--line); padding: 26px; }
.settings-card + .settings-card { margin-top: 20px; }
.settings-card h3 { font-family: var(--serif); font-size: 19px; font-weight: 600; margin-bottom: 4px; }
.settings-card .sub { margin-bottom: 20px; font-size: 10px; color: var(--muted); }
.form-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--line); }
.preview-site { background: var(--ink); color: #f2ede3; padding: 26px; position: sticky; top: 110px; }
.preview-site .preview-top { display: flex; align-items: center; gap: 10px; padding-bottom: 16px; border-bottom: 1px solid rgba(242, 237, 227, 0.14); }
.preview-mark { display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid rgba(242, 237, 227, 0.32); font-family: var(--serif); font-size: 19px; }
.preview-site h4 { font-family: var(--serif); font-size: 16px; font-weight: 600; }
.preview-site small { display: block; font-size: 7px; letter-spacing: 0.16em; color: rgba(242, 237, 227, 0.45); }
.preview-site p { margin-top: 24px; font-family: var(--serif); font-size: 22px; line-height: 1.45; word-break: keep-all; }
.preview-site span { display: block; margin-top: 14px; font-size: 10px; color: rgba(242, 237, 227, 0.55); }
.preview-colors { display: flex; gap: 8px; margin-top: 24px; }
.preview-colors i { width: 28px; height: 28px; border: 1px solid rgba(242, 237, 227, 0.2); }
.preview-tip { margin-top: 20px; padding-top: 14px; border-top: 1px solid rgba(242, 237, 227, 0.14); font-size: 9px; line-height: 1.7; color: rgba(242, 237, 227, 0.4); }
.ui-group { background: var(--panel); border: 1px solid var(--line); margin-bottom: 18px; }
.ui-group-head { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.ui-group-head h3 { font-family: var(--serif); font-size: 18px; font-weight: 600; }
.ui-group-head span { font-size: 8px; letter-spacing: 0.18em; color: var(--muted); }
.ui-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; padding: 22px; }
.ui-grid .field.wide { grid-column: 1 / -1; }
.ui-note { padding: 12px 16px; border: 1px solid var(--line); background: #fbf7ef; font-size: 10px; color: var(--muted); margin-bottom: 20px; }

/* ---------- 上传 ---------- */
.uploader { display: flex; flex-direction: column; gap: 9px; }
.upload-preview {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 160px;
  border: 1px dashed var(--line-strong);
  background: #faf7f0;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.upload-preview img { width: 100%; height: 100%; object-fit: cover; }
.upload-preview span { font-size: 9px; color: #a79e90; letter-spacing: 0.08em; }
.upload-actions { display: flex; gap: 8px; }
.upload-actions button { padding: 5px 10px; border: 1px solid var(--line); background: transparent; font-size: 9px; transition: border-color 0.2s, color 0.2s; }
.upload-actions button:hover { border-color: var(--accent); color: var(--accent); }
.multi-images { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.multi-item { position: relative; aspect-ratio: 4 / 3; border: 1px solid var(--line); background: #faf7f0; overflow: hidden; }
.multi-item img { width: 100%; height: 100%; object-fit: cover; }
.multi-item button {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 22px;
  height: 22px;
  border: 0;
  background: rgba(14, 16, 15, 0.72);
  color: #fff;
  font-size: 13px;
  line-height: 1;
}
.uploader-multi .upload-actions { margin-top: 2px; }

/* ---------- 留言 ---------- */
.filter-bar { display: flex; align-items: center; gap: 8px; margin-bottom: 18px; flex-wrap: wrap; }
.filter-bar button {
  padding: 7px 12px;
  border: 1px solid var(--line);
  background: transparent;
  font-size: 10px;
  color: var(--muted);
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}
.filter-bar button.is-active { border-color: var(--accent); color: var(--accent); background: #fff8f2; }
.message-list { display: flex; flex-direction: column; gap: 10px; }
.message-card { background: var(--panel); border: 1px solid var(--line); padding: 18px 20px; position: relative; }
.message-card.is-unread { border-left: 3px solid var(--accent); }
.message-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.message-who { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.message-who b { font-family: var(--serif); font-size: 17px; font-weight: 600; }
.message-who span { font-size: 10px; color: var(--muted); }
.message-date { font-size: 9px; color: #a39a8b; white-space: nowrap; }
.message-content { margin-top: 10px; font-size: 12px; line-height: 1.8; color: #4f4a40; }
.message-actions { display: flex; gap: 14px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.message-actions button, .message-actions a { border: 0; background: transparent; padding: 0; font-size: 10px; color: #6c655a; }
.message-actions button:hover, .message-actions a:hover { color: var(--accent); }

/* ---------- 弹层 ---------- */
.modal { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 4vh 24px; }
.modal-mask { position: absolute; inset: 0; background: rgba(10, 11, 10, 0.66); backdrop-filter: blur(5px); }
.modal-card {
  position: relative;
  z-index: 1;
  width: min(780px, 100%);
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.28);
  animation: modalIn 0.4s var(--ease);
}
@keyframes modalIn { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 24px 28px 18px; border-bottom: 1px solid var(--line); }
.modal-head p { font-size: 8px; font-weight: 600; letter-spacing: 0.2em; color: var(--accent); }
.modal-head h2 { margin-top: 4px; font-family: var(--serif); font-size: 25px; font-weight: 600; }
.modal-x { position: relative; width: 36px; height: 36px; border: 1px solid var(--line); background: transparent; flex: none; }
.modal-x span { position: absolute; top: 50%; left: 50%; width: 15px; height: 1px; background: var(--ink); }
.modal-x span:first-child { transform: translate(-50%, -50%) rotate(45deg); }
.modal-x span:last-child { transform: translate(-50%, -50%) rotate(-45deg); }
.modal-x:hover { border-color: var(--accent); }
.modal-body { padding: 24px 28px; overflow-y: auto; }
.modal-foot { display: flex; align-items: center; justify-content: flex-end; gap: 10px; padding: 16px 28px; border-top: 1px solid var(--line); background: #f8f4ec; }
.modal-foot .danger-left { margin-right: auto; }

/* ---------- 提示 ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 30px;
  z-index: 300;
  transform: translate(-50%, 15px);
  max-width: 90vw;
  padding: 11px 20px;
  background: var(--ink);
  color: #f2ede3;
  font-size: 11px;
  letter-spacing: 0.03em;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s, transform 0.3s var(--ease), visibility 0.3s;
}
.toast.is-show { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.loading-line { padding: 60px 20px; text-align: center; color: var(--muted); font-size: 11px; letter-spacing: 0.08em; }

/* ---------- 响应式 ---------- */
@media (max-width: 1180px) {
  :root { --side: 244px; }
  .content, .topbar, .app-footer { padding-left: 30px; padding-right: 30px; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .settings-grid { grid-template-columns: 1fr; }
  .preview-site { position: static; }
}
@media (max-width: 920px) {
  .login-view { grid-template-columns: 1fr; }
  .login-visual { display: none; }
  .login-panel { padding: 60px 32px; min-height: 100vh; }
  .login-brand-mobile { display: flex; }
  .app-view { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    width: min(300px, 84vw);
    transform: translateX(-100%);
    transition: transform 0.45s var(--ease);
    box-shadow: 20px 0 60px rgba(0, 0, 0, 0.2);
  }
  body.side-open .sidebar { transform: translateX(0); }
  body.side-open::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 45;
    background: rgba(14, 16, 15, 0.46);
  }
  .side-toggle { display: flex; }
  .topbar { min-height: 76px; }
  .topbar h1 { font-size: 22px; }
  .topbar-user { display: none; }
  .dash-grid { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .topbar { padding: 12px 20px; gap: 12px; }
  .content { padding: 24px 20px 44px; }
  .app-footer { padding: 16px 20px; flex-direction: column; align-items: flex-start; gap: 6px; }
  .topbar-right .btn { display: none; }
  .page-head { flex-direction: column; align-items: flex-start; gap: 14px; }
  .stat-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .stat-card { padding: 16px; }
  .stat-value { font-size: 36px; }
  .field-grid, .ui-grid { grid-template-columns: 1fr; }
  .ui-grid .field.wide { grid-column: auto; }
  .quick-grid { grid-template-columns: 1fr; }
  .modal { padding: 0; place-items: end center; }
  .modal-card { width: 100%; max-height: 94vh; }
  .modal-head, .modal-body, .modal-foot { padding-left: 18px; padding-right: 18px; }
  .multi-images { grid-template-columns: repeat(2, 1fr); }
  .login-panel { padding: 42px 22px; }
  .login-panel-foot { left: 22px; right: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}
