/* 
   极致·简 个人博客主题
   https://app.zbp.cool/zblogTheme/1538.html
*/ 
:root, html[data-theme="light"] {
  --bg: #f5f6f8;
  --bg-card: #ffffff;
  --bg-soft: #f0f2f5;
  --text-1: #1f2329;
  --text-2: #57606a;
  --text-3: #8b949e;
  --border: #e6e8eb;
  --accent: #2f6fed;
  --accent-2: #1d55d8;
  --accent-soft: rgba(47, 111, 237, 0.08);
  --header-bg: rgba(255, 255, 255, 0.82);
  --shadow-card: 0 1px 2px rgba(16, 24, 40, 0.04), 0 1px 3px rgba(16, 24, 40, 0.06);
  --shadow-hover: 0 6px 16px rgba(16, 24, 40, 0.09);
  --shadow-drop: 0 8px 24px rgba(16, 24, 40, 0.12);
  --code-bg: #f4f5f7;
  --quote-bg: #f7f9fc;
  --mask: rgba(15, 23, 42, 0.45);
  color-scheme: light;
}
html[data-theme="dark"] {
  --bg: #0f1115;
  --bg-card: #171a21;
  --bg-soft: #1e222c;
  --text-1: #e6e8ec;
  --text-2: #9aa3b0;
  --text-3: #6c7480;
  --border: #262b36;
  --accent: #6f9bff;
  --accent-2: #8fb0ff;
  --accent-soft: rgba(111, 155, 255, 0.13);
  --header-bg: rgba(15, 17, 21, 0.82);
  --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.25);
  --shadow-hover: 0 6px 18px rgba(0, 0, 0, 0.45);
  --shadow-drop: 0 10px 30px rgba(0, 0, 0, 0.55);
  --code-bg: #1e222c;
  --quote-bg: #1a1e27;
  --mask: rgba(0, 0, 0, 0.55);
  color-scheme: dark;
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-1);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color 0.25s ease, color 0.25s ease;
}
img {
  max-width: 100%;
  height: auto;
  border: 0;
}
ul, ol {
  list-style: none;
}
a {
  color: inherit;
  text-decoration: none;
  transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}
button {
  font-family: inherit;
}
input, textarea, select {
  font-family: inherit;
}
html{
  opacity: 0;
  overflow: hidden;
}
::selection {
  background: var(--accent-soft);
  color: var(--accent);
}
[data-theme] ::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
[data-theme] ::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 6px;
}
[data-theme] ::-webkit-scrollbar-thumb:hover {
  background: var(--text-3);
}
[id] {
  scroll-margin-top: 86px;
}
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.container {
  width: 100%;
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 20px;
}
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  z-index: 1300;
  transition: width 0.08s linear;
}
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--header-bg);
  -webkit-backdrop-filter: saturate(1.6) blur(12px);
  backdrop-filter: saturate(1.6) blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner {
  display: flex;
  align-items: center;
  height: 62px;
  gap: 16px;
  justify-content: space-between;
}
.logo {
  flex: none;
}
.logo a,.logo a h1 {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--text-1);
}
.logo a:hover {
  color: var(--accent);
}
.main-nav {
  flex: 1;
  min-width: 0;
  display: flex;
  justify-content: center;
}
.nav-list {
  display: flex;
  align-items: center;
  gap: 2px;
}
.nav-list > li {
  position: relative;
}
.nav-list > li > a {
  display: block;
  padding: 7px 15px;
  border-radius: 8px;
  font-size: 15px;
  color: var(--text-2);
  font-weight: 500;
}
.nav-list > li > a:hover {
  color: var(--accent);
  background: var(--accent-soft);
}
.nav-list > li > a.selected {
  color: var(--accent);
  background: var(--accent-soft);
}
.nav-list .sub-nav {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  min-width: 170px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow-drop);
  padding: 8px;
  z-index: 100;
}
.nav-list > li:hover > .sub-nav {
  display: block;
}
.nav-list .sub-nav::before {
  content: "";
  position: absolute;
  top: -10px;
  left: 0;
  right: 0;
  height: 10px;
}
.nav-list .sub-nav li a {
  display: block;
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 14px;
  color: var(--text-2);
  white-space: nowrap;
}
.nav-list .sub-nav li a:hover {
  color: var(--accent);
  background: var(--accent-soft);
}
.drawer-close, .sub-toggle {
  display: none;
}
.header-actions {
  flex: none;
  display: flex;
  align-items: center;
  gap: 4px;
}
.header-btn {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--text-2);
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.header-btn:hover {
  background: var(--accent-soft);
  color: var(--accent);
}
.header-btn svg {
  width: 20px;
  height: 20px;
}
.menu-toggle {
  display: none;
}
.theme-toggle .icon-sun {
  display: none;
}
.theme-toggle .icon-moon {
  display: block;
}
html[data-theme="dark"] .theme-toggle .icon-sun {
  display: block;
}
html[data-theme="dark"] .theme-toggle .icon-moon {
  display: none;
}
html.selected {
  opacity: 1;
  overflow: auto;
}
.search-panel {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-drop);
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.25s ease;
}
.search-panel.open {
  max-height: 120px;
}
.search-form {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 0;
}
.search-form svg {
  width: 20px;
  height: 20px;
  color: var(--text-3);
  flex: none;
}
.search-form input[type="search"] {
  flex: 1;
  min-width: 0;
  padding: 10px 14px;
  font-size: 15px;
  background: var(--bg-soft);
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--text-1);
  outline: none;
  transition: border-color 0.15s ease;
}
.search-form input[type="search"]:focus {
  border-color: var(--accent);
  background: var(--bg-card);
}
.search-form button {
  flex: none;
  padding: 10px 22px;
  font-size: 14px;
  font-weight: 500;
  background: var(--accent);
  color: #fff;
  border: 0;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.15s ease;
}
.search-form button:hover {
  background: var(--accent-2);
}
.nav-mask {
  position: fixed;
  inset: 0;
  background: var(--mask);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
  z-index: 998;
}
.nav-mask.show {
  opacity: 1;
  visibility: visible;
}
.layout {
  display: flex;
  align-items: flex-start;
  gap: 28px;
  padding: 28px 20px 56px;
}
.layout .main-col {
  flex: 1;
  min-width: 0;
}
.layout .side-col {
  flex: none;
  width: 302px;
  position: sticky;
  top: 84px;
}
.page-head {
  margin: 4px 0 22px;
}
.breadcrumb {
  font-size: 13px;
  color: var(--text-3);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}
.breadcrumb a {
  color: var(--text-3);
}
.breadcrumb a:hover {
  color: var(--accent);
}
.breadcrumb .sep {
  margin: 0 7px;
}
.page-title {
  font-size: 25px;
  font-weight: 700;
  line-height: 1.4;
  margin-top: 10px;
}
.page-desc {
  font-size: 14px;
  color: var(--text-2);
  margin-top: 6px;
}
.post-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.post-item {
  display: flex;
  gap: 22px;
  padding: 22px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  animation: fadeUp 0.4s ease both;
}
.post-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
  border-color: color-mix(in srgb, var(--accent) 35%, var(--border));
}
.post-thumb {
  flex: none;
  width: 150px;
  aspect-ratio: 4 / 3;
  border-radius: 10px;
  overflow: hidden;
  background: var(--bg-soft);
}
.post-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.45s ease;
}
.post-item:hover .post-thumb img {
  transform: scale(1.06);
}
.post-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.post-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 12.5px;
  color: var(--text-3);
}
.post-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.post-meta-item svg {
  width: 14px;
  height: 14px;
}
.post-cat a {
  color: var(--accent);
}
.post-cat a:hover {
  text-decoration: underline;
}
.post-flag {
  font-size: 11.5px;
  line-height: 1;
  color: #fff;
  background: var(--accent);
  padding: 3px 8px;
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: 1px;
}
.post-title {
  font-size: 19px;
  line-height: 1.5;
  font-weight: 600;
}
.post-title a {
  color: var(--text-1);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.post-title a:hover {
  color: var(--accent);
}
.post-excerpt {
  font-size: 14px;
  line-height: 1.8;
  color: var(--text-2);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.post-foot {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 12.5px;
  color: var(--text-3);
  margin-top: auto;
}
.post-foot svg {
  width: 14px;
  height: 14px;
}
.post-more {
  margin-left: auto;
  font-size: 13px;
  color: var(--accent);
  font-weight: 500;
}
.post-more:hover {
  text-decoration: underline;
}
.post-empty {
  background: var(--bg-card);
  border: 1px dashed var(--border);
  border-radius: 12px;
  padding: 56px 24px;
  text-align: center;
  color: var(--text-3);
  font-size: 14px;
}
.search-form-inline {
  display: flex;
  gap: 10px;
  max-width: 420px;
  margin: 18px auto 0;
}
.search-form-inline input {
  flex: 1;
  min-width: 0;
  padding: 9px 14px;
  font-size: 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-1);
  outline: none;
}
.search-form-inline input:focus {
  border-color: var(--accent);
}
.search-form-inline button {
  flex: none;
  padding: 9px 20px;
  font-size: 14px;
  background: var(--accent);
  color: #fff;
  border: 0;
  border-radius: 8px;
  cursor: pointer;
}
.post-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow-card);
  padding: 34px 38px;
  animation: fadeUp 0.4s ease both;
}
.post-header {
  border-bottom: 1px solid var(--border);
  padding-bottom: 20px;
  margin-bottom: 24px;
}
.post-title-lg {
  font-size: 30px;
  line-height: 1.4;
  font-weight: 700;
}
.post-meta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 18px;
  margin-top: 16px;
  font-size: 13px;
  color: var(--text-3);
}
.meta-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.meta-item svg {
  width: 14px;
  height: 14px;
}
.meta-author {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.meta-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1px solid var(--border);
}
.post-abstract {
  background: var(--quote-bg);
  border-left: 3px solid var(--accent);
  padding: 13px 18px;
  border-radius: 0 10px 10px 0;
  font-size: 14px;
  line-height: 1.8;
  color: var(--text-2);
  margin-bottom: 26px;
}
.post-abstract strong {
  color: var(--accent);
  font-weight: 600;
  margin-right: 8px;
}
.post-content {
  font-size: 16px;
  line-height: 1.95;
  color: var(--text-1);
  word-break: break-word;
}
.post-content p {
  margin: 0 0 1.25em;
}
.post-content h2, .post-content h3, .post-content h4 {
  font-weight: 700;
  line-height: 1.5;
  margin: 1.9em 0 0.85em;
}
.post-content h2 {
  font-size: 1.35em;
  padding-left: 13px;
  border-left: 4px solid var(--accent);
}
.post-content h3 {
  font-size: 1.18em;
}
.post-content h4 {
  font-size: 1.05em;
}
.post-content a {
  color: var(--accent);
  border-bottom: 1px solid transparent;
}
.post-content a:hover {
  border-bottom-color: var(--accent);
}
.post-content img {
  border-radius: 10px;
  margin: 1.2em auto;
  display: block;
}
.post-content img[align="left"] {
  margin-right: 1em;
}
.post-content img[align="right"] {
  margin-left: 1em;
}
.post-content blockquote {
  margin: 1.4em 0;
  padding: 14px 20px;
  background: var(--quote-bg);
  border-left: 4px solid var(--accent);
  border-radius: 0 10px 10px 0;
  color: var(--text-2);
  font-size: 0.95em;
}
.post-content ul {
  list-style: disc;
  margin: 0 0 1.25em;
  padding-left: 1.7em;
}
.post-content ol {
  list-style: decimal;
  margin: 0 0 1.25em;
  padding-left: 1.7em;
}
.post-content li {
  margin: 0.35em 0;
}
.post-content code {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  font-size: 0.9em;
  background: var(--code-bg);
  color: var(--text-1);
  padding: 2px 7px;
  border-radius: 5px;
  word-break: break-all;
}
.post-content pre {
  margin: 1.4em 0;
  padding: 18px 20px;
  overflow-x: auto;
  background: var(--code-bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  line-height: 1.7;
  font-size: 0.92em;
}
.post-content pre code {
  background: transparent;
  padding: 0;
  border-radius: 0;
}
.post-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.4em 0;
  font-size: 0.92em;
}
.post-content th, .post-content td {
  border: 1px solid var(--border);
  padding: 9px 13px;
  text-align: left;
}
.post-content th {
  background: var(--bg-soft);
  font-weight: 600;
}
.post-content hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 2.2em 0;
}
.post-content iframe, .post-content video {
  max-width: 100%;
  border-radius: 10px;
}
.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid var(--border);
}
.tag-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  padding: 5px 14px;
  border-radius: 999px;
  background: var(--bg-soft);
  color: var(--text-2);
  transition: background-color 0.15s ease, color 0.15s ease;
}
.tag-chip svg {
  width: 13px;
  height: 13px;
}
.tag-chip:hover {
  background: var(--accent-soft);
  color: var(--accent);
}
.post-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 20px;
}
.post-nav-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 20px;
  box-shadow: var(--shadow-card);
  transition: border-color 0.15s ease, transform 0.15s ease;
}
.post-nav-item:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
}
.post-nav-item.is-next {
  text-align: right;
}
.post-nav-item.is-disabled {
  opacity: 0.45;
  pointer-events: none;
}
.post-nav-label {
  font-size: 12px;
  color: var(--text-3);
}
.post-nav-title {
  font-size: 14.5px;
  color: var(--text-1);
  font-weight: 500;
}
.related-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow-card);
  padding: 26px 30px;
  margin-top: 20px;
}
.card-title {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 9px;
}
.card-title::before {
  content: "";
  width: 4px;
  height: 17px;
  border-radius: 2px;
  background: var(--accent);
}
.related-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 2px;
  border-bottom: 1px dashed var(--border);
}
.related-list li:last-child {
  border-bottom: 0;
}
.related-list li a {
  font-size: 14.5px;
  color: var(--text-1);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.related-list li a:hover {
  color: var(--accent);
}
.related-list li time {
  flex: none;
  font-size: 12px;
  color: var(--text-3);
}
.related-empty {
  font-size: 13.5px;
  color: var(--text-3);
}
.author-card {
  display: flex;
  align-items: center;
  gap: 18px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow-card);
  padding: 24px 28px;
  margin-top: 20px;
}
.author-avatar {
  width: 66px;
  height: 66px;
  border-radius: 50%;
  border: 2px solid var(--border);
  flex: none;
}
.author-body {
  flex: 1;
  min-width: 0;
}
.author-name {
  font-size: 16.5px;
  font-weight: 700;
}
.author-intro {
  font-size: 13.5px;
  line-height: 1.8;
  color: var(--text-2);
  margin-top: 5px;
}
.comment-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow-card);
  padding: 28px 32px;
  margin-top: 20px;
}
.comment-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.comment-head .card-title {
  margin-bottom: 0;
}
.comment-count {
  font-size: 14px;
  color: var(--text-3);
  font-weight: 400;
  margin-left: 6px;
}
.comment-head #cancel-reply {
  font-size: 12.5px;
  color: var(--accent);
}
.comment-head #cancel-reply:hover {
  text-decoration: underline;
}
.comment-fields {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 14px;
}
.comment-field label {
  display: block;
  font-size: 12.5px;
  color: var(--text-2);
  margin-bottom: 6px;
}
.comment-field label i {
  color: #e5484d;
  font-style: normal;
  margin-left: 2px;
}
.comment-field input[type="text"] {
  width: 100%;
  padding: 9px 13px;
  font-size: 14px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-1);
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.comment-field input[type="text"]:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.comment-field-textarea {
  grid-column: 1 / -1;
  margin-top: 6px;
}
.comment-field-textarea textarea {
  width: 100%;
  min-height: 110px;
  padding: 11px 14px;
  font-size: 14px;
  line-height: 1.7;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-1);
  outline: none;
  resize: vertical;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.comment-field-textarea textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.comment-captcha {
  height: 34px;
  margin-top: 8px;
  border-radius: 6px;
  border: 1px solid var(--border);
  cursor: pointer;
  display: block;
}
.comment-submit {
  text-align: right;
  margin-top: 16px;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 24px;
  font-size: 14px;
  font-weight: 500;
  border-radius: 8px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.15s ease;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover {
  background: var(--accent-2);
}
.btn-ghost {
  background: var(--bg-card);
  border-color: var(--border);
  color: var(--text-2);
}
.btn-ghost:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.comment-list {
  margin-top: 18px;
}
.comment-item {
  display: flex;
  gap: 15px;
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
}
.comment-avatar {
  flex: none;
  width: 42px;
}
.comment-avatar img {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: block;
  border: 1px solid var(--border);
}
.comment-main {
  flex: 1;
  min-width: 0;
}
.comment-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.comment-name {
  font-size: 14.5px;
  font-weight: 600;
}
.comment-name a {
  color: var(--text-1);
}
.comment-name a:hover {
  color: var(--accent);
}
.comment-time {
  font-size: 12.5px;
  color: var(--text-3);
}
.comment-reply {
  margin-left: auto;
  font-size: 12.5px;
  color: var(--accent);
  opacity: 0;
  transition: opacity 0.15s ease;
}
.comment-item:hover .comment-reply {
  opacity: 1;
}
.comment-text {
  font-size: 14.5px;
  line-height: 1.85;
  color: var(--text-1);
  margin-top: 7px;
  word-break: break-word;
}
.comment-text p {
  margin: 0.4em 0;
}
.comment-children {
  margin: 16px 0 0 24px;
  padding-left: 20px;
  border-left: 2px solid var(--border);
}
.comment-children .comment-item:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}
.comment-page {
  margin-top: 16px;
}
.widget {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow-card);
  padding: 20px;
  margin-bottom: 20px;
  animation: fadeUp 0.4s ease both;
}
.widget-title {
  font-size: 15.5px;
  font-weight: 700;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 9px;
}
.widget-title::before {
  content: "";
  width: 4px;
  height: 15px;
  border-radius: 2px;
  background: var(--accent);
}
.widget-list li {
  overflow: hidden;
}
.widget-list li a {
  display: block;
  padding: 7px 2px;
  font-size: 14px;
  color: var(--text-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.widget-list li a:hover {
  color: var(--accent);
}
.widget-body img {
  max-width: 100%;
  border-radius: 8px;
}
#divSearchPanel {
  padding: 14px;
}
#divSearchPanel .widget-title {
  display: none;
}
#divSearchPanel form {
  display: flex;
  gap: 8px;
}
#divSearchPanel input[type="text"] {
  flex: 1;
  min-width: 0;
  padding: 8px 12px;
  font-size: 13.5px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-1);
  outline: none;
}
#divSearchPanel input[type="text"]:focus {
  border-color: var(--accent);
}
#divSearchPanel input[type="submit"] {
  padding: 8px 16px;
  font-size: 13.5px;
  background: var(--accent);
  color: #fff;
  border: 0;
  border-radius: 8px;
  cursor: pointer;
}
#divSearchPanel input[type="submit"]:hover {
  background: var(--accent-2);
}
#divTags ul {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
#divTags li a {
  display: inline-block;
  font-size: 13px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--bg-soft);
  color: var(--text-2);
  transition: background-color 0.15s ease, color 0.15s ease;
}
#divTags li a:hover {
  background: var(--accent-soft);
  color: var(--accent);
}
#divArchives li, #divCatalog li, #divStatistics li, #divNavBar li {
  width: 50%;
  float: left;
  height: 32px;
  line-height: 32px;
  overflow: hidden;
}
#divArchives a, #divCatalog a, #divStatistics a, #divNavBar a {
  padding-right: 8px;
}
#divComments li, #divPrevious li {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
#divCalendar table {
  width: 100%;
  border-collapse: collapse;
}
#divCalendar caption {
  font-size: 14px;
  font-weight: 600;
  padding: 8px 0 10px;
}
#divCalendar caption a {
  font-size: 14px;
  color: var(--text-1);
  padding: 0 6px;
}
#divCalendar caption a:hover {
  color: var(--accent);
}
#divCalendar th {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-2);
  padding: 6px 0;
  border-bottom: 1px solid var(--border);
}
#divCalendar td {
  text-align: center;
  padding: 5px 0;
  font-size: 13.5px;
  color: var(--text-2);
}
#divCalendar td a {
  color: var(--text-1);
  font-weight: 600;
}
#divCalendar td a:hover {
  color: var(--accent);
}
#divContorPanel .widget-body {
  text-align: center;
}
#divContorPanel .cp-hello {
  font-size: 14px;
  color: var(--text-2);
  margin-bottom: 12px;
}
#divContorPanel .cp-login, #divContorPanel .cp-vrs {
  display: inline-block;
  margin: 0 4px;
}
#divContorPanel .cp-login a, #divContorPanel .cp-vrs a {
  display: inline-block;
  padding: 6px 16px;
  font-size: 13px;
  border-radius: 8px;
  border: 1px solid var(--border);
  color: var(--text-2);
}
#divContorPanel .cp-login a:hover, #divContorPanel .cp-vrs a:hover {
  border-color: var(--accent);
  color: var(--accent);
}
#divFavorites a, #divLinkage a, #divAuthors a {
  display: inline-block;
  font-size: 13px;
  color: var(--text-2);
  margin: 0 8px 8px 0;
  padding: 3px 10px;
  background: var(--bg-soft);
  border-radius: 6px;
}
#divFavorites a:hover, #divLinkage a:hover, #divAuthors a:hover {
  color: var(--accent);
  background: var(--accent-soft);
}
.pagination {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 28px 0 4px;
}
.page {
  min-width: 37px;
  height: 37px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13.5px;
  color: var(--text-2);
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 9px;
  cursor: pointer;
  transition: all 0.15s ease;
}
a.page:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-soft);
}
.page-current {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.page-current:hover {
  color: #fff;
}
.page-disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg-card);
  padding: 26px 0 30px;
  text-align: center;
  font-size: 13px;
  line-height: 2.1;
  color: var(--text-3);
}
.site-footer a {
  color: var(--text-3);
}
.site-footer a:hover {
  color: var(--accent);
}
.back-to-top {
  position: fixed;
  right: 26px;
  bottom: 26px;
  z-index: 950;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-card);
  border: 1px solid var(--border);
  color: var(--text-2);
  box-shadow: var(--shadow-card);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: all 0.25s ease;
}
.back-to-top svg {
  width: 19px;
  height: 19px;
}
.back-to-top.show {
  opacity: 1;
  visibility: visible;
  transform: none;
}
.back-to-top:hover {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: var(--shadow-hover);
}
.page-404-wrap {
  display: flex;
  justify-content: center;
  padding-top: 60px;
  padding-bottom: 80px;
}
.page-404 {
  width: 100%;
  max-width: 540px;
  text-align: center;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow-card);
  padding: 72px 40px;
  animation: fadeUp 0.4s ease both;
}
.nf-code {
  font-size: 108px;
  font-weight: 800;
  line-height: 1;
  background: linear-gradient(135deg, var(--accent), #a78bfa);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.nf-text {
  font-size: 15px;
  color: var(--text-2);
  margin: 18px 0 30px;
}
.nf-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
}
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  html {
    scroll-behavior: auto;
  }
}
@media (max-width: 1024px) {
  .layout {
    gap: 22px;
  }
  .layout .side-col {
    width: 264px;
  }
}
@media (max-width: 900px) {
  .menu-toggle {
    display: inline-flex;
  }
  .main-nav {
    position: fixed;
    top: 0;
    right: -300px;
    width: 290px;
    height: 100vh;
    background: var(--bg-card);
    z-index: 1001;
    padding: 74px 18px 30px;
    overflow-y: auto;
    display: block;
    transition: right 0.3s ease;
    box-shadow: var(--shadow-drop);
  }
  .main-nav.open {
    right: 0;
  }
  .drawer-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 16px;
    right: 16px;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: var(--bg-soft);
    color: var(--text-2);
    cursor: pointer;
    transition: color 0.15s ease, border-color 0.15s ease;
  }
  .drawer-close:hover {
    color: var(--accent);
    border-color: var(--accent);
  }
  .drawer-close svg {
    width: 18px;
    height: 18px;
  }
  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
  }
  .nav-list > li > a {
    padding: 12px 42px 12px 16px;
    font-size: 15px;
    border-radius: 10px;
  }
  .sub-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 26px;
    right: 8px;
    transform: translateY(-50%);
    width: 30px;
    height: 30px;
    border: 0;
    background: transparent;
    color: var(--text-3);
    cursor: pointer;
    border-radius: 8px;
    transition: color 0.15s ease;
    z-index: 99;
  }
  .sub-toggle:hover {
    color: var(--accent);
    background: var(--accent-soft);
  }
  .sub-toggle svg {
    width: 13px;
    height: 13px;
    transition: transform 0.25s ease;
  }
  .nav-list > li.open > .sub-toggle svg {
    transform: rotate(90deg);
  }
  .nav-list .sub-nav {
    position: static;
    transform: none;
    display: none;
    min-width: 0;
    background: transparent;
    border: 0;
    box-shadow: none;
    padding: 0 0 4px 18px;
  }
  .nav-list > li:hover > .sub-nav {
    display: none;
  }
  .nav-list > li.open > .sub-nav {
    display: block;
  }
  .nav-list .sub-nav li a {
    padding: 10px 12px;
  }
  .layout .side-col {
    display: none;
  }
  .layout {
    padding: 24px 0 48px;
  }
  .layout .container, .container {
    padding: 0 16px;
  }
  .search-panel.open {
    max-height: 140px;
  }
}
@media (max-width: 640px) {
  .header-inner {
    height: 56px;
  }
  .logo a,.logo a h1 {
    font-size: 18px;
  }
  .layout {
    gap: 0;
    padding-top: 16px;
  }
  .post-item {
    gap: 14px;
    padding: 16px 18px;
  }
  .post-thumb {
    width: 108px;
    border-radius: 8px;
  }
  .post-title {
    font-size: 16.5px;
  }
  .post-excerpt {
    font-size: 13px;
    -webkit-line-clamp: 2;
  }
  .post-foot {
    gap: 10px;
  }
  .post-more {
    display: none;
  }
  .page-title {
    font-size: 21px;
  }
  .post-card {
    padding: 24px 20px;
    border-radius: 0;
    border-left: 0;
    border-right: 0;
  }
  .post-title-lg {
    font-size: 23px;
  }
  .post-meta-row {
    gap: 12px;
    font-size: 12.5px;
  }
  .post-nav {
    grid-template-columns: 1fr;
  }
  .post-nav-item.is-next {
    text-align: left;
  }
  .related-card, .comment-card {
    padding: 20px 18px;
    border-radius: 0;
    border-left: 0;
    border-right: 0;
  }
  .author-card {
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    padding: 20px 22px;
  }
  .comment-fields {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .comment-children {
    margin-left: 12px;
    padding-left: 12px;
  }
  .comment-avatar {
    width: 36px;
  }
  .comment-avatar img {
    width: 36px;
    height: 36px;
  }
  .comment-reply {
    opacity: 1;
  }
  .nf-code {
    font-size: 78px;
  }
  .page-404 {
    padding: 52px 24px;
  }
  .back-to-top {
    right: 16px;
    bottom: 16px;
    width: 38px;
    height: 38px;
  }
  .search-form button {
    padding: 9px 16px;
  }
}
@media (max-width: 400px) {
  .post-thumb {
    width: 92px;
  }
  .post-item {
    padding: 14px 16px;
  }
}