:root {
  --bg: #f5f7fa;
  --panel: #ffffff;
  --ink: #16202c;
  --muted: #5d6b7a;
  --line: #e2e8f0;
  --brand: #0b63c5;
  --brand-dark: #084a94;
  --brand-soft: #e8f1fd;
  --danger: #c0392b;
  --success: #1f7a4d;
  --radius: 12px;
  --shadow: 0 10px 30px rgba(22, 32, 44, 0.06);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  font-size: 16px;
  line-height: 1.7;
}

a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-dark); }

h1, h2, h3 { line-height: 1.35; margin: 0; }
p { margin: 0; }

.wrap { width: min(1120px, calc(100% - 40px)); margin: 0 auto; }
.main { padding: 28px 0 64px; min-height: 60vh; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(8px);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 68px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 700; }
.brand:hover { color: var(--ink); }
.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--brand), #2f9ce6);
  color: #fff;
  font-size: 14px;
  letter-spacing: 0.5px;
}
.brand-text { font-size: 18px; letter-spacing: 0.2px; }
.brand-text em { font-style: normal; color: var(--muted); font-weight: 500; margin-left: 2px; font-size: 15px; }
.main-nav { display: flex; gap: 4px; margin-left: 8px; }
.main-nav a {
  color: var(--muted);
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 15px;
}
.main-nav a:hover { color: var(--ink); background: #eef2f7; }
.main-nav a.active { color: var(--brand); background: var(--brand-soft); font-weight: 600; }
.search-form { margin-left: auto; display: flex; gap: 6px; }
.search-form input[type="search"] {
  width: 190px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
  font-size: 14px;
  color: var(--ink);
  outline: none;
}
.search-form input[type="search"]:focus { border-color: var(--brand); background: #fff; }
.search-form button {
  padding: 8px 14px;
  border: 0;
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  font-size: 14px;
  cursor: pointer;
}
.search-form.inline { margin-left: 0; }
.search-form.inline input[type="search"] { width: min(360px, 60vw); }

/* Hero */
.hero {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 32px;
  align-items: center;
  padding: 46px;
  border-radius: 20px;
  background:
    radial-gradient(900px 320px at 90% 0%, rgba(47, 156, 230, 0.18), transparent 60%),
    linear-gradient(135deg, #ffffff 0%, #eff6fe 100%);
  border: 1px solid #dce8f7;
  box-shadow: var(--shadow);
}
.eyebrow { color: var(--brand); font-size: 13px; font-weight: 700; letter-spacing: 1.4px; text-transform: uppercase; }
.hero h1 { margin: 12px 0 14px; font-size: 40px; letter-spacing: -0.5px; }
.lead { color: var(--muted); font-size: 17px; max-width: 560px; }
.hero-actions { display: flex; gap: 12px; margin-top: 24px; flex-wrap: wrap; }
.hero-stats {
  display: grid;
  gap: 12px;
}
.hero-stats div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 14px 18px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.hero-stats strong { font-size: 22px; color: var(--brand-dark); }
.hero-stats span { color: var(--muted); font-size: 14px; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 18px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font-size: 15px;
  cursor: pointer;
  font-family: inherit;
}
.btn:hover { border-color: #cdd7e3; background: #f8fafc; color: var(--ink); }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.primary:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; }
.btn.small { padding: 5px 11px; font-size: 13px; border-radius: 7px; }
.btn.danger { color: var(--danger); border-color: #f0d5d1; background: #fff7f6; }
.btn.danger:hover { background: #fdeceb; }
.btn.block { width: 100%; }
.link-btn { background: none; border: 0; color: var(--brand); cursor: pointer; font-size: 14px; padding: 0; font-family: inherit; }
.link-btn:hover { color: var(--brand-dark); text-decoration: underline; }

/* Layout */
.content-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 28px; margin-top: 32px; align-items: start; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 12px; }
.section-head h2 { font-size: 22px; }
.section-head a { font-size: 14px; }

/* Article list */
.article-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.article-item {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 22px;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.article-item:hover { border-color: #c9d9ee; box-shadow: var(--shadow); }
.article-date { color: var(--muted); font-size: 13px; }
.article-item h2 { font-size: 20px; margin: 6px 0 8px; }
.article-item h2 a { color: var(--ink); }
.article-item h2 a:hover { color: var(--brand); }
.article-summary { color: var(--muted); font-size: 15px; }
.tag-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.tag {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 12.5px;
}
.tag:hover { background: #d8e9fc; color: var(--brand-dark); }
.tag span { color: var(--muted); font-size: 11px; }
.tag.small { padding: 2px 8px; font-size: 12px; }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-cloud.large { gap: 10px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.tag-cloud.large .tag { font-size: 14px; padding: 6px 13px; }

/* Sidebar */
.sidebar { display: grid; gap: 16px; position: sticky; top: 88px; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.panel h3 { font-size: 16px; margin-bottom: 14px; }
.panel p { color: var(--muted); font-size: 14px; margin-bottom: 8px; }
.panel.cta { background: linear-gradient(160deg, #eef6ff, #fff); border-color: #d7e6f8; }
.panel-more { display: inline-block; margin-top: 12px; font-size: 13px; }
.archive-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.archive-list a { display: flex; justify-content: space-between; color: var(--ink); font-size: 14px; padding: 4px 0; }
.archive-list a:hover { color: var(--brand); }
.archive-list span { color: var(--muted); font-size: 12px; }

/* Page head */
.page-head { margin: 10px 0 24px; }
.page-head h1 { font-size: 32px; margin-bottom: 8px; }
.page-head p { color: var(--muted); }
.page-head form { margin-top: 16px; }

/* Article */
.article { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 40px 46px; }
.article h1 { font-size: 34px; letter-spacing: -0.3px; margin: 14px 0 14px; }
.breadcrumb { display: flex; gap: 8px; color: var(--muted); font-size: 13px; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--brand); }
.article-meta { display: flex; flex-wrap: wrap; gap: 16px; color: var(--muted); font-size: 13.5px; margin-bottom: 8px; }
.prose { font-size: 16px; line-height: 1.85; color: #24303d; word-wrap: break-word; }
.prose h1, .prose h2, .prose h3, .prose h4 { color: var(--ink); margin: 1.6em 0 0.6em; line-height: 1.4; }
.prose h1 { font-size: 28px; }
.prose h2 { font-size: 23px; border-bottom: 1px solid var(--line); padding-bottom: 6px; }
.prose h3 { font-size: 19px; }
.prose p { margin: 0.9em 0; }
.prose ul, .prose ol { padding-left: 1.5em; margin: 0.9em 0; }
.prose li { margin: 0.3em 0; }
.prose img { max-width: 100%; height: auto; border-radius: 8px; display: block; margin: 1.2em auto; }
.prose a { text-decoration: underline; text-underline-offset: 2px; }
.prose blockquote { margin: 1.2em 0; padding: 10px 18px; border-left: 4px solid var(--brand); background: #f4f8fd; color: #3b4a5a; }
.prose code { background: #eef2f7; padding: 2px 6px; border-radius: 5px; font-size: 0.9em; font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace; }
.prose pre { background: #141c26; color: #e6edf5; padding: 18px 20px; border-radius: 10px; overflow-x: auto; font-size: 14px; line-height: 1.6; }
.prose pre code { background: none; padding: 0; color: inherit; font-size: inherit; }
.prose table { width: 100%; border-collapse: collapse; margin: 1.2em 0; font-size: 15px; }
.prose th, .prose td { border: 1px solid var(--line); padding: 8px 12px; text-align: left; }
.prose th { background: #f4f7fb; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2em 0; }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 20px; }
.pager-item { display: grid; gap: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; }
.pager-item span { color: var(--muted); font-size: 12px; }
.pager-item strong { color: var(--ink); font-size: 15px; font-weight: 600; line-height: 1.5; }
.pager-item:hover strong { color: var(--brand); }
.pager-item.next { text-align: right; }

/* Pagination */
.pagination { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 26px; }
.page-btn { padding: 7px 16px; border: 1px solid var(--line); border-radius: 8px; background: #fff; font-size: 14px; }
.page-btn.disabled { color: #b3bdc9; background: #f5f7fa; }
.page-info { color: var(--muted); font-size: 13px; }

/* Archive */
.archive-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 14px; }
.archive-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; display: flex; justify-content: space-between; align-items: baseline; }
.archive-card strong { color: var(--ink); font-size: 16px; }
.archive-card span { color: var(--muted); font-size: 13px; }
.archive-card:hover { border-color: #c9d9ee; box-shadow: var(--shadow); }

/* Footer */
.site-footer { margin-top: 40px; background: #101923; color: #b9c4d0; padding: 42px 0 24px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 32px; }
.site-footer p { margin: 0 0 8px; font-size: 14px; color: #b9c4d0; }
.site-footer a { color: #d6e2f0; }
.site-footer a:hover { color: #fff; }
.footer-title { color: #fff; font-size: 17px; font-weight: 700; }
.footer-legal { text-align: right; }
.copyright { border-top: 1px solid #26313d; margin-top: 28px; padding-top: 18px; font-size: 13px; color: #8794a3; }

/* Not found */
.notfound { text-align: center; padding: 90px 20px; }
.notfound h1 { font-size: 72px; color: var(--brand); }
.notfound p { color: var(--muted); margin: 10px 0 26px; }
.notfound .hero-actions { justify-content: center; }

/* Alerts */
.alert { padding: 10px 14px; border-radius: 9px; font-size: 14px; margin-bottom: 16px; }
.alert.error { background: #fdecea; color: #9b2c20; border: 1px solid #f5cfca; }
.alert.success { background: #eaf7ef; color: #1c6b45; border: 1px solid #c9e9d7; }
.muted { color: var(--muted); font-size: 14px; }

/* 表单基础样式 */
input[type="text"], input[type="password"], input[type="date"], input[type="url"], input[type="search"], textarea {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 15px;
  font-family: inherit;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
input:focus, textarea:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(11, 99, 197, 0.12); }
textarea { resize: vertical; line-height: 1.65; font-family: "SFMono-Regular", Consolas, Menlo, monospace; font-size: 14px; }

.stack { display: grid; gap: 14px; }
.stack label { display: grid; gap: 6px; font-size: 14px; color: var(--muted); }
.captcha-row { display: flex; align-items: center; gap: 10px; }
.captcha-row input[type="text"] { flex: 1 1 auto; min-width: 0; width: auto; }
.captcha-row img { width: 168px; height: 56px; flex: none; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.captcha-refresh { justify-self: start; font-size: 13px; color: var(--muted); text-decoration: underline; }

/* Admin */
.admin-body { background: #f4f6fa; }

.admin-shell { display: flex; min-height: 100vh; }
.admin-side {
  width: 248px; flex: none; position: sticky; top: 0; height: 100vh;
  background: linear-gradient(180deg, #0e1a2b 0%, #13253c 100%);
  color: #b9cce3; display: flex; flex-direction: column; padding: 18px 14px 14px;
}
.admin-side-brand { display: flex; align-items: center; gap: 10px; padding: 6px 8px 18px; color: #fff; }
.admin-side-brand:hover { color: #fff; }
.admin-side-brand .brand-mark { width: 34px; height: 34px; border-radius: 9px; font-size: 13px; }
.side-brand-text strong { display: block; font-size: 15px; line-height: 1.35; }
.side-brand-text small { display: block; color: #7f9abb; font-size: 12px; }
.admin-side-group { margin-top: 14px; }
.admin-side-label {
  display: block; padding: 0 12px 8px; font-size: 11.5px; letter-spacing: 1.4px;
  color: #6d87a5; text-transform: uppercase;
}
.admin-side-nav { display: grid; gap: 3px; }
.admin-side-nav a { position: relative; display: block; padding: 10px 12px; border-radius: 9px; color: #b9cce3; font-size: 14px; }
.admin-side-nav a:hover { background: rgba(255, 255, 255, .06); color: #fff; }
.admin-side-nav a.on { background: rgba(50, 132, 224, .18); color: #fff; font-weight: 600; }
.admin-side-nav a.on::before {
  content: ""; position: absolute; left: -14px; top: 8px; bottom: 8px; width: 3px;
  border-radius: 0 3px 3px 0; background: #43a0ff;
}
.admin-side-foot { margin-top: auto; padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, .08); }
.admin-side-user { display: flex; align-items: center; gap: 10px; padding: 8px 8px 10px; }
.admin-avatar {
  width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center;
  background: linear-gradient(135deg, #2f9ce6, #0b63c5); color: #fff; font-size: 13px; font-weight: 600;
}
.admin-side-user .who b { display: block; color: #fff; font-size: 13.5px; font-weight: 600; }
.admin-side-user .who span { display: block; color: #7f9abb; font-size: 11.5px; }
.admin-side-foot form { margin: 0; }
.admin-logout {
  width: 100%; display: flex; align-items: center; justify-content: center; padding: 9px 12px;
  border: 0; border-radius: 8px; background: transparent; color: #9db3cd; font-size: 13px; cursor: pointer;
}
.admin-logout:hover { background: rgba(255, 255, 255, .06); color: #fff; }

.admin-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.admin-topbar {
  position: sticky; top: 0; z-index: 30; height: 62px; display: flex; align-items: center;
  gap: 16px; padding: 0 30px; background: rgba(255, 255, 255, .92);
  border-bottom: 1px solid var(--line); backdrop-filter: blur(8px);
}
.admin-crumb { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13px; }
.admin-crumb b { color: var(--ink); font-weight: 600; }
.admin-crumb .sep { color: #c3cedb; }
.admin-topbar-spacer { flex: 1; }
.admin-site-link { font-size: 13.5px; }
.admin-site-link:hover { text-decoration: underline; }
.admin-content { padding: 26px 30px 90px; width: 100%; max-width: 1240px; }

.admin-page-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 18px;
  flex-wrap: wrap; margin-bottom: 20px;
}
.admin-page-head h1 { font-size: 25px; }
.admin-desc { margin-top: 4px; color: var(--muted); font-size: 13.5px; }
.admin-head-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.admin-head-actions .btn.primary { box-shadow: 0 6px 16px rgba(11, 99, 197, .2); }

.admin-search {
  display: flex; align-items: center; gap: 8px; height: 38px; min-width: 280px;
  background: #fff; border: 1px solid var(--line); border-radius: 9px; padding: 2px 4px 2px 12px;
}
.admin-search:focus-within { border-color: #86b6ef; box-shadow: 0 0 0 3px rgba(11, 99, 197, .12); }
.admin-search input[type="search"] { flex: 1; min-width: 0; border: 0; padding: 0; height: 32px; box-shadow: none; }
.admin-search input[type="search"]:focus { border: 0; box-shadow: none; }
.admin-search .btn { height: 30px; }

.admin-card {
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  box-shadow: var(--shadow-sm); overflow: hidden;
}
.admin-card + .admin-card { margin-top: 16px; }
.admin-card-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 13px 16px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 13px;
}
.admin-card-head b { color: var(--ink); }
.admin-table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.admin-table th {
  text-align: left; font-weight: 600; font-size: 12.5px; letter-spacing: .3px; color: var(--muted);
  background: #f8fafc; padding: 11px 16px; border-bottom: 1px solid var(--line); white-space: nowrap;
}
.admin-table td { padding: 13px 16px; border-bottom: 1px solid #eef2f7; vertical-align: middle; }
.admin-table tbody tr:last-child td { border-bottom: 0; }
.admin-table tbody tr:hover { background: #fafcff; }
.admin-table td.nowrap, .admin-table .date-col { white-space: nowrap; color: var(--muted); font-variant-numeric: tabular-nums; }
.table-title-cell { display: flex; flex-direction: column; gap: 2px; min-width: 280px; }
.table-title { color: var(--ink); font-weight: 600; }
.table-title:hover { color: var(--brand); }
.table-slug { color: #93a3b4; font-size: 11.5px; }
.tag-cell { max-width: 300px; }
.table-actions { display: flex; gap: 4px; justify-content: flex-end; white-space: nowrap; }
.table-actions form { margin: 0; }
.actions-col { width: 160px; }
.btn.ghost { border-color: transparent; background: transparent; color: var(--brand); }
.btn.ghost:hover { background: var(--brand-soft); border-color: transparent; color: var(--brand-dark); }
.admin-empty { padding: 46px 16px; text-align: center; color: var(--muted); font-size: 14px; }

.admin-pager {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 13px 16px; border-top: 1px solid var(--line); flex-wrap: wrap;
}
.admin-pager .info { color: var(--muted); font-size: 13px; }
.admin-pager .pages { display: flex; gap: 6px; }
.page-link {
  display: inline-flex; align-items: center; height: 32px; padding: 0 12px;
  border: 1px solid var(--line); border-radius: 7px; font-size: 13px; color: var(--muted);
}
.page-link:hover { border-color: #cdd8e5; color: var(--ink); }
.page-link.disabled { opacity: .45; pointer-events: none; }

.admin-meta { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 18px; padding: 20px; }
.admin-meta label { display: grid; gap: 6px; font-size: 14px; color: var(--muted); }
.admin-meta .full { grid-column: 1 / -1; }
.slug-chip { display: inline-block; background: #f1f5fa; color: #48617c; border-radius: 6px; padding: 1px 7px; font-size: 12px; }
.admin-editor { display: grid; gap: 0; }
.admin-editor-card { padding: 0; }
.admin-editor-split { display: grid; grid-template-columns: 1.05fr .95fr; }
.admin-pane { display: flex; flex-direction: column; min-width: 0; }
.admin-pane + .admin-pane { border-left: 1px solid var(--line); }
.admin-pane-head {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 10px 16px; background: #f8fafc; border-bottom: 1px solid var(--line);
  font-size: 12.5px; color: var(--muted);
}
.admin-pane textarea { border: 0; border-radius: 0; min-height: 420px; box-shadow: none; font-size: 13.5px; }
.admin-pane textarea:focus { box-shadow: none; }
.admin-preview { padding: 18px 20px; min-height: 420px; max-height: 720px; overflow-y: auto; font-size: 15px; }
.admin-editor-foot {
  display: flex; align-items: center; gap: 12px; padding: 14px 20px;
  border-top: 1px solid var(--line); background: #fbfcfe;
}
.admin-editor-foot .hint { margin-right: auto; color: #93a3b4; font-size: 12.5px; }

.admin-chips { display: flex; gap: 8px; flex-wrap: wrap; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.chip {
  height: 30px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--line);
  background: #fff; color: var(--muted); font-size: 13px; cursor: pointer;
}
.chip:hover { border-color: #cdd8e5; color: var(--ink); }
.chip.on { background: var(--brand-soft); border-color: #bcd8f7; color: var(--brand-dark); font-weight: 600; }
.badge { display: inline-flex; align-items: center; font-size: 12px; padding: 3px 9px; border-radius: 999px; background: #f1f5fa; color: #48617c; }
.badge.login { background: #e8f5ee; color: #1f7a4d; }
.badge.create { background: var(--brand-soft); color: var(--brand-dark); }
.badge.update { background: #fdf3e2; color: #a86a00; }
.badge.delete { background: #fdeceb; color: var(--danger); }
.ip-col { color: var(--muted); font-size: 12.5px; }
.mono { font-family: "SFMono-Regular", Consolas, Menlo, monospace; font-size: 12.5px; }

/* 登录 / 初始化 */
.auth-body { background: #f4f6fa; }
.auth-shell { display: grid; grid-template-columns: 1.05fr .95fr; min-height: 100vh; }
.auth-brand {
  position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: space-between;
  padding: 48px 5vw; color: #fff;
  background: radial-gradient(1200px 600px at 15% 0%, #1b4d8c 0%, transparent 55%),
              linear-gradient(150deg, #0e1a2b 0%, #123a66 100%);
}
.auth-brand::after {
  content: ""; position: absolute; inset: 0; opacity: .28; pointer-events: none;
  background-image: linear-gradient(rgba(255, 255, 255, .06) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(255, 255, 255, .06) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(70% 60% at 30% 30%, #000 0%, transparent 100%);
  mask-image: radial-gradient(70% 60% at 30% 30%, #000 0%, transparent 100%);
}
.auth-brand > * { position: relative; z-index: 1; }
.auth-brand-row { display: flex; align-items: center; gap: 12px; color: #fff; }
.auth-brand-row:hover { color: #fff; }
.auth-brand-row .brand-mark { width: 40px; height: 40px; border-radius: 11px; font-size: 15px; box-shadow: 0 6px 18px rgba(11, 99, 197, .45); }
.auth-brand-row strong { font-size: 17px; }
.auth-brand-row em { font-style: normal; font-weight: 400; color: #9fc0e4; font-size: 14px; margin-left: 4px; }
.auth-lead h2 { font-size: 34px; margin-bottom: 14px; }
.auth-lead > p { color: #a9c3e0; max-width: 460px; }
.auth-points { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 13px; }
.auth-points li { position: relative; padding-left: 20px; color: #cfe0f5; font-size: 14px; max-width: 480px; }
.auth-points li::before {
  content: ""; position: absolute; left: 0; top: 9px; width: 7px; height: 7px;
  border-radius: 50%; background: #4da3ff; box-shadow: 0 0 0 4px rgba(77, 163, 255, .16);
}
.auth-foot { display: flex; gap: 16px; flex-wrap: wrap; color: #7fa0c4; font-size: 12.5px; }
.auth-main { display: grid; place-items: center; padding: 48px 6vw; }
.auth-card { width: min(400px, 100%); }
.auth-card h1 { font-size: 26px; }
.auth-sub { margin: 6px 0 22px; color: var(--muted); font-size: 14px; }
.auth-fineprint { margin-top: 20px; text-align: center; color: #8a98a8; font-size: 12.5px; }

@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; padding: 30px; }
  .hero h1 { font-size: 32px; }
  .content-grid { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .article { padding: 26px 22px; }
  .article h1 { font-size: 27px; }
  .admin-editor-split { grid-template-columns: 1fr; }
  .admin-pane textarea, .admin-preview { min-height: 340px; }
  .admin-meta { grid-template-columns: 1fr; }
  .auth-shell { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
  .auth-main { padding: 40px 20px; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-legal { text-align: left; }
}

@media (max-width: 720px) {
  .header-inner { flex-wrap: wrap; gap: 10px; padding: 10px 0; }
  .main-nav { order: 3; width: 100%; overflow-x: auto; }
  .search-form { margin-left: 0; width: 100%; }
  .search-form input[type="search"] { flex: 1; width: auto; }
  .pager { grid-template-columns: 1fr; }
  .pager-item.next { text-align: left; }
  .admin-shell { flex-direction: column; }
  .admin-side {
    position: static; width: 100%; height: auto; flex-direction: row; flex-wrap: wrap;
    align-items: center; gap: 8px; padding: 10px 14px;
  }
  .admin-side-brand { padding: 0 10px 0 0; }
  .side-brand-text small { display: none; }
  .admin-side-group { margin-top: 0; }
  .admin-side-label { display: none; }
  .admin-side-nav { display: flex; gap: 4px; }
  .admin-side-nav a { padding: 8px 10px; font-size: 13.5px; }
  .admin-side-nav a.on::before { display: none; }
  .admin-side-foot {
    margin: 0 0 0 auto; padding: 0; border: 0; display: flex; align-items: center; gap: 8px;
  }
  .admin-side-user { padding: 0; }
  .admin-side-user .who { display: none; }
  .admin-logout { width: auto; padding: 8px 10px; }
  .admin-topbar { height: 54px; padding: 0 16px; }
  .admin-content { padding: 18px 16px 40px; }
  .admin-page-head { flex-wrap: wrap; gap: 12px; }
  .admin-head-actions { width: 100%; }
  .admin-search { width: 100%; }
  .admin-meta { padding: 16px; }
}
