/* 后台独立样式：不引用官网 tailwind/common.css，避免管理页跟公开站绑在一起。 */
:root {
  --ink: #201f1a;
  --muted: #6e6b62;
  --line: #e7e5e0;
  --paper: #ffffff;
  --wash: #fafaf8;
  --gold: #e8a825;
  --green: #4f9462;
  --red: #dc2626;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--wash); color: var(--ink); font: 15px/1.5 system-ui, sans-serif; }
/* 登录页仍用这条；React 壳的 Sidebar.Main 是 main.admin-main，不能被 56rem 卡住 */
main:not(.admin-main) { max-width: 56rem; margin: 0 auto; padding: 2.5rem 1.25rem; }
.admin-main { max-width: none; margin: 0; padding: 0; }
h1 { margin: 0; font-size: 1.4rem; }
.sub { margin: 0.35rem 0 0; color: var(--muted); font-size: 0.85rem; }
header { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; }
button, .btn-primary, .btn-ghost {
  font: inherit; cursor: pointer; border-radius: 999px; min-height: 2.5rem; padding: 0 1.1rem;
}
.btn-primary, #login-btn, #save-post, #asset-add, #slot-save {
  background: var(--ink); color: #fff; border: 0;
}
.btn-ghost, #logout {
  background: transparent; border: 1px solid var(--line); color: var(--ink);
}
.hidden { display: none !important; }
label { display: block; font-size: 0.72rem; font-weight: 650; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
input, textarea, select, .admin-input {
  margin-top: 0.5rem; width: 100%; border: 1px solid var(--line); border-radius: 0.75rem;
  background: var(--paper); padding: 0.65rem 0.75rem; font: inherit; color: var(--ink);
}
textarea { min-height: 7rem; resize: vertical; }
.admin-input:focus, input:focus, textarea:focus, select:focus { outline: none; border-color: rgba(232,168,37,.55); }
.tab-btn { min-height: 2.5rem; border: 0; border-bottom: 2px solid transparent; background: none; border-radius: 0; padding: 0 1rem; color: var(--muted); }
.tab-btn.border-custom-ink, .tab-btn[aria-current] { border-bottom-color: var(--ink); color: var(--ink); }
#contact-badge { display: inline-flex; min-width: 1.1rem; height: 1.1rem; align-items: center; justify-content: center; border-radius: 999px; background: var(--red); color: #fff; font-size: 0.7rem; margin-left: 0.25rem; }
.grid { display: grid; gap: 0.75rem; }
@media (min-width: 640px) { .sm\:grid-cols-2 { grid-template-columns: 1fr 1fr; } .sm\:grid-cols-3 { grid-template-columns: 1fr 1fr 1fr; } }
code { font-size: 0.85em; }
.text-red-600, .text-red-400 { color: var(--red); }
.text-custom-green { color: var(--green); }
.text-custom-muted { color: var(--muted); }
.text-xs { font-size: 0.75rem; }
.text-sm { font-size: 0.875rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 0.75rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mt-10 { margin-top: 2.5rem; }
.max-w-sm { max-width: 24rem; }
