/* Dygita Theme - Build: 2026-03-15T15:18:14.843Z */

/* === css/variables.css === */
/* Dygita CSS 层次：变量层（设计令牌，仅定义 CSS 变量） */
/* CSS Variables and Dark Mode Support */
:root {
  --body-bg-color: #f5f7f9;
  --content-bg-color: #fff;
  --card-bg-color: #f5f5f5;
  --text-color: #555;
  --muted-text-color: #999;
  --blockquote-color: #666;
  --link-color: #555;
  --link-hover-color: #222;
  --accent-color: #e74c3c;
  --accent-hover-color: #cf3f31;
  --overlay-bg-color: rgba(255, 255, 255, 0.93);
  --brand-color: #fff;
  --brand-hover-color: #fff;
  --table-row-odd-bg-color: #f9f9f9;
  --table-row-hover-bg-color: #f5f5f5;
  --menu-item-bg-color: #f5f5f5;
  --btn-default-bg: #fff;
  --btn-default-color: #555;
  --btn-default-border-color: #555;
  --btn-default-hover-bg: #222;
  --btn-default-hover-color: #fff;
  --btn-default-hover-border-color: #222;
  --border-color: #eaecef;
  --hover-bg-color: #f6f8fa;
  --code-bg-color: #f6f8fa;
  --code-text-color: #333;
  --header-bg-color: #E74C3C;
  --header-text-color: #fff;
  --sidebar-bg-color: #fff;
  --post-bg-color: #fff;
  --post-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);

  /* Z-index tokens */
  --z-header-bg: 0;
  --z-header-content: 1;
  --z-content-control: 10;
  --z-catalog-sticky: 1100;
  --z-sidebar-toggle: 1200;
  --z-back-to-top: 1300;
  --z-reading-progress: 1400;
  --z-overlay: 1500;
  --z-modal: 1600;
}

/* 暗色主题 - 符合Typecho规范 */
[data-theme="dark"] {
  --body-bg-color: #1e1e1e;
  --content-bg-color: #252525;
  --card-bg-color: #2d2d2d;
  --text-color: #c9d1d9;
  --muted-text-color: #8b949e;
  --blockquote-color: #9aa0a6;
  --link-color: #58a6ff;
  --link-hover-color: #79b8ff;
  --accent-color: #ff7b72;
  --accent-hover-color: #ff9b95;
  --overlay-bg-color: rgba(23, 23, 23, 0.92);
  --brand-color: #c9d1d9;
  --brand-hover-color: #e6edf3;
  --table-row-odd-bg-color: #2d2d2d;
  --table-row-hover-bg-color: #363636;
  --menu-item-bg-color: #2d2d2d;
  --btn-default-bg: #2d2d2d;
  --btn-default-color: #c9d1d9;
  --btn-default-border-color: #484f58;
  --btn-default-hover-bg: #363636;
  --btn-default-hover-color: #e6edf3;
  --btn-default-hover-border-color: #586069;
  --border-color: #30363d;
  --hover-bg-color: #2d2d2d;
  --code-bg-color: #2d2d2d;
  --code-text-color: #c9d1d9;
  /* 保持标题栏颜色为红色，不受暗黑主题影响 */
  --header-bg-color: #E74C3C;
  --header-text-color: #fff;
  --sidebar-bg-color: #2d2d2d;
  --post-bg-color: #2d2d2d;
  --post-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* === css/base.css === */
/* Dygita CSS 层次：基础层（Reset + HTML 元素默认样式） */

/*
Theme Name: Dygita for Typecho
Version: 1.0
Author: Googlo & Ported to Typecho
Description: Dygita Theme Ported to Typecho
*/

/* Base Style Reset */
html {
  line-height: 1.15;
  -webkit-text-size-adjust: 100%;
}

body {
  background-color: #f5f7f9;
  color: #555;
  margin: 0;
  padding: 0;
  background-color: var(--body-bg-color);
  color: var(--text-color);
}

main {
  display: block;
}

h1 {
  font-size: 2em;
  margin: 0.67em 0;
}

hr {
  box-sizing: content-box;
  height: 0;
  overflow: visible;
}

pre {
  font-family: monospace, monospace;
  font-size: 1em;
}

a {
  background: transparent;
}

abbr[title] {
  border-bottom: none;
  text-decoration: underline;
  text-decoration: underline dotted;
}

b,
strong {
  font-weight: bolder;
}

code,
kbd,
samp {
  font-family: monospace, monospace;
  font-size: 1em;
}

small {
  font-size: 80%;
}

sub,
sup {
  font-size: 75%;
  line-height: 0;
  position: relative;
  vertical-align: baseline;
}

sub {
  bottom: -0.25em;
}

sup {
  top: -0.5em;
}

img {
  border-style: none;
}

button,
input,
optgroup,
select,
textarea {
  font-family: inherit;
  font-size: 100%;
  line-height: 1.15;
  margin: 0;
}

button,
input {
  overflow: visible;
}

button,
select {
  text-transform: none;
}

button,
[type='button'],
[type='reset'],
[type='submit'] {
  appearance: button;
  -webkit-appearance: button;
}

button::-moz-focus-inner,
[type='button']::-moz-focus-inner,
[type='reset']::-moz-focus-inner,
[type='submit']::-moz-focus-inner {
  border-style: none;
  padding: 0;
}

button:-moz-focusring,
[type='button']:-moz-focusring,
[type='reset']:-moz-focusring,
[type='submit']:-moz-focusring {
  outline: 1px dotted ButtonText;
}

fieldset {
  padding: 0.35em 0.75em 0.625em;
}

legend {
  box-sizing: border-box;
  color: inherit;
  display: table;
  max-width: 100%;
  padding: 0;
  white-space: normal;
}

progress {
  vertical-align: baseline;
}

textarea {
  overflow: auto;
}

[type='checkbox'],
[type='radio'] {
  box-sizing: border-box;
  padding: 0;
}

[type='number']::-webkit-inner-spin-button,
[type='number']::-webkit-outer-spin-button {
  height: auto;
}

[type='search'] {
  outline-offset: -2px;
  appearance: textfield;
  -webkit-appearance: textfield;
}

[type='search']::-webkit-search-decoration {
  -webkit-appearance: none;
}

::-webkit-file-upload-button {
  font: inherit;
  -webkit-appearance: button;
}

details {
  display: block;
}

summary {
  display: list-item;
}

template {
  display: none;
}

[hidden] {
  display: none;
}

::selection {
  background: #262a30;
  color: #eee;
}

/* 禁用所有可能的悬停位移效果 */
*,
*::before,
*::after {
  --tw-translate-x: 0;
  --tw-translate-y: 0;
  --tw-rotate: 0;
  --tw-skew-x: 0;
  --tw-skew-y: 0;
  --tw-scale-x: 1;
  --tw-scale-y: 1;
}

/* Body Styles */
html,
body {
  height: 100%;
  width: 100%;
  margin: 0;
  padding: 0;
}

body {
  background: #f5f7f9;
  color: #555;
  background: var(--body-bg-color);
  color: var(--text-color);
  font-family: 'Lato', "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 1em;
  line-height: 2;
}

@media (max-width: 992px) {
  body {
    padding-left: 0;
    padding-right: 0;
  }
}

/* 全局暗色主题样式 - 确保所有元素都受到影响 */
body {
  background-color: #f5f7f9;
  color: #555;
  background-color: var(--body-bg-color);
  color: var(--text-color);
}

/* 确保所有容器元素都使用暗色主题 */
.main-container,
.content-wrap,
.footer,
.footer-inner,
.footer-copyright {
  background-color: #f5f7f9;
  color: #555;
  border-color: #eaecef;
  background-color: var(--body-bg-color);
  color: var(--text-color);
  border-color: var(--border-color);
}

/* 确保所有表单元素都使用暗色主题 */
input,
textarea,
select {
  background-color: #fff;
  color: #555;
  border-color: #eaecef;
  background-color: var(--content-bg-color);
  color: var(--text-color);
  border-color: var(--border-color);
}

/* 确保所有链接都使用暗色主题 */
a {
  color: #555;
  color: var(--link-color);
}

a:hover {
  color: #222;
  color: var(--link-hover-color);
}

/* 确保所有标题都使用暗色主题 */
h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--text-color);
}

/* 确保所有列表都使用暗色主题 */
ul,
ol {
  color: var(--text-color);
}

/* 确保所有表格都使用暗色主题 */
table {
  border-color: var(--border-color);
}

th,
td {
  background-color: var(--content-bg-color);
  color: var(--text-color);
  border-color: var(--border-color);
}

/* 确保所有引用块都使用暗色主题 */
blockquote {
  background-color: var(--content-bg-color);
  color: var(--blockquote-color);
  border-color: var(--border-color);
}

/* 确保所有代码块都使用暗色主题 */
code,
pre {
  background-color: var(--code-bg-color);
  color: var(--code-text-color);
  border-color: var(--border-color);
}

/* 确保所有按钮都使用暗色主题 */
button,
.btn {
  background-color: var(--btn-default-bg);
  color: var(--btn-default-color);
  border-color: var(--btn-default-border-color);
}

button:hover,
.btn:hover {
  background-color: var(--btn-default-hover-bg);
  color: var(--btn-default-hover-color);
  border-color: var(--btn-default-hover-border-color);
}

/* 确保所有导航元素都使用暗色主题 */
.m-nav,
.m-nav-all,
.nav-container,
.nav,
.nav li,
.nav li a {
  background-color: var(--menu-item-bg-color);
  color: var(--text-color);
  border-color: var(--border-color);
}

.nav li a:hover,
.nav li.active a {
  background-color: var(--hover-bg-color);
  color: var(--link-hover-color);
}

/* 确保搜索表单使用暗色主题 */
.search-form,
.search-form input {
  background-color: var(--content-bg-color);
  color: var(--text-color);
  border-color: var(--border-color);
}

/* 确保侧边栏使用暗色主题 */
.sidebar,
.sidebar-left,
.sidebar-right {
  background-color: var(--sidebar-bg-color);
  color: var(--text-color);
  border-color: var(--border-color);
}

/* 确保小部件使用暗色主题 */
.widget {
  background-color: var(--card-bg-color);
  color: var(--text-color);
  border-color: var(--border-color);
}

/* 确保分页控件使用暗色主题 */
.pagination {
  background-color: var(--content-bg-color);
  color: var(--text-color);
}

.pagination ul li a,
.pagination ul li span {
  background-color: var(--hover-bg-color);
  color: var(--link-color);
  border-color: var(--border-color);
}

/* 确保文章元信息使用暗色主题 */
.auth-span,
.auth-span .muted,
.auth-span .muted a {
  color: var(--text-color);
}

/* 确保相关文章使用暗色主题 */
.related-posts {
  background-color: var(--card-bg-color);
  color: var(--text-color);
  border-color: var(--border-color);
}

/* 确保评论区域使用暗色主题 */
.comments-area {
  background-color: var(--content-bg-color);
  color: var(--text-color);
  border-color: var(--border-color);
}

/* 确保标签云使用暗色主题 */
#tag-cloud-tags {
  background-color: var(--content-bg-color);
  color: var(--text-color);
}

/* 确保返回顶部按钮使用暗色主题 */
.back-to-top {
  background-color: var(--btn-default-bg);
  color: var(--btn-default-color);
  border-color: var(--btn-default-border-color);
  z-index: var(--z-back-to-top, 1300);
}

.back-to-top:hover {
  background-color: var(--btn-default-hover-bg);
  color: var(--btn-default-hover-color);
  border-color: var(--btn-default-hover-border-color);
}

/* 确保阅读进度条使用暗色主题 */
.reading-progress-bar {
  background-color: var(--link-color);
  z-index: var(--z-reading-progress, 1400);
}

/* 暗色主题下的边框和阴影调整 */
.post-block,
.content-wrap,
.sidebar {
  border: 1px solid var(--border-color);
  box-shadow: var(--post-shadow);
  background: var(--content-bg-color);
  color: var(--text-color);
}

/* 确保内部元素不重复添加边框和背景 */
.widget,
.content,
.article-header,
.article-content {
  border: none;
  box-shadow: none;
  background: transparent;
  color: var(--text-color);
}

/* 确保文章标题和内容在暗黑主题下使用正确的颜色 */
.article-title {
  color: var(--text-color);
}

.article-header .meta {
  color: var(--blockquote-color);
}

/* 确保页面标题在暗黑主题下使用正确的颜色 */
.page-title {
  color: var(--text-color);
}

/* 确保评论表单在所有主题下使用正确的颜色和样式 */
#respond {
  background: var(--content-bg-color);
  border-top: 1px solid var(--border-color);
  padding: 30px;
  border-radius: 8px;
  margin-top: 30px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

#comment-form {
  background: var(--content-bg-color);
  color: var(--text-color);
}

#comment-form input,
#comment-form textarea {
  background: var(--content-bg-color);
  border: 1px solid var(--border-color);
  color: var(--text-color);
  border-radius: 4px;
  padding: 12px 16px;
  width: 100%;
  box-sizing: border-box;
  margin-bottom: 15px;
  font-size: 14px;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

#comment-form input:focus,
#comment-form textarea:focus {
  border-color: var(--link-color);
  outline: none;
  box-shadow: 0 0 0 3px rgba(88, 166, 255, 0.1);
}

#comment-form #submit {
  background: var(--link-color);
  border: 1px solid var(--link-color);
  color: var(--brand-color);
  padding: 10px 20px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s ease;
}

#comment-form #submit:hover {
  background: var(--link-hover-color);
  border-color: var(--link-hover-color);
}

/* 确保评论列表在暗黑主题下使用正确的颜色 */
.comment-list {
  background: var(--content-bg-color);
  color: var(--text-color);
}

/* 暗色主题下的分隔线调整 */
hr {
  background-image: repeating-linear-gradient(-45deg, var(--border-color), var(--border-color) 4px, transparent 4px, transparent 8px);
}

/* 暗色主题下的代码块调整 */
.highlight-container {
  background: var(--code-bg-color);
}

.highlight,
pre {
  background: var(--code-bg-color);
  color: var(--code-text-color);
}

code {
  background: var(--code-bg-color);
  color: var(--code-text-color);
}

/* 暗色主题下的表格调整 */
th,
td {
  border-color: var(--border-color);
}

/* 暗色主题下的按钮调整 */
.btn {
  background: var(--btn-default-bg);
  border-color: var(--btn-default-border-color);
  color: var(--btn-default-color);
}

.btn:hover {
  background: var(--btn-default-hover-bg);
  border-color: var(--btn-default-hover-border-color);
  color: var(--btn-default-hover-color);
}

/* 暗色主题下的导航栏调整 */
.header {
  background-color: var(--header-bg-color);
}

.header a {
  color: var(--header-text-color);
}

.site-nav .menu-item a {
  color: var(--header-text-color);
}

/* Typography Styles */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: 'Lato', "PingFang SC", "Microsoft YaHei", sans-serif;
  font-weight: bold;
  line-height: 1.5;
  margin: 20px 0 15px;
}

h1 {
  font-size: 1.5em;
}

h2 {
  font-size: 1.375em;
}

h3 {
  font-size: 1.25em;
}

h4 {
  font-size: 1.125em;
}

h5 {
  font-size: 1em;
}

h6 {
  font-size: 0.875em;
}

p {
  margin: 0 0 20px 0;
}

/* Link Styles */
a,
span.exturl {
  border-bottom: 1px solid var(--border-color);
  color: var(--link-color);
  outline: 0;
  text-decoration: none;
  overflow-wrap: break-word;
  word-wrap: break-word;
  cursor: pointer;
}

a:hover,
span.exturl:hover {
  border-bottom-color: var(--link-hover-color);
  color: var(--link-hover-color);
}

/* Image Styles */
iframe,
img,
video {
  display: block;
  margin-left: auto;
  margin-right: auto;
  max-width: 100%;
}

/* Horizontal Rule Styles */
hr {
  background-image: repeating-linear-gradient(-45deg, #ddd, #ddd 4px, transparent 4px, transparent 8px);
  border: 0;
  height: 3px;
  margin: 40px 0;
}

/* Blockquote Styles */
blockquote {
  border-left: 4px solid var(--border-color);
  color: var(--blockquote-color);
  margin: 0;
  padding: 0 15px;
}

blockquote cite::before {
  content: '-';
  padding: 0 5px;
}

/* KBD Styles */
kbd {
  background-color: var(--code-bg-color);
  background-image: linear-gradient(var(--hover-bg-color), var(--content-bg-color), var(--hover-bg-color));
  border: 1px solid var(--border-color);
  border-radius: 0.2em;
  box-shadow: 0.1em 0.1em 0.2em rgba(0, 0, 0, 0.1);
  color: var(--text-color);
  font-family: inherit;
  padding: 0.1em 0.3em;
  white-space: nowrap;
}

/* 懒加载占位符样式 */
img.lazy {
  opacity: 0;
  transition: opacity 0.3s ease-in-out;
}

img {
  max-width: 100%;
  height: auto;
}


/* === css/layout.css === */
/* Dygita CSS 层次：布局层（整体容器与响应式栅格） */

/* 布局样式 */

/* 全局布局 */

/* 页脚样式 */
.footer {
  width: 100%;
  text-align: center;
  padding: 20px 0;
  background-color: var(--body-bg-color);
  color: var(--blockquote-color);
  font-size: 13px;
  border-top: 1px solid var(--border-color);
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.footer-copyright {
  text-align: center;
}

/* 确保所有容器元素都使用暗色主题 */
.main-container,
.content-wrap,
.footer,
.footer-inner,
.footer-copyright {
  background-color: var(--body-bg-color);
  color: var(--text-color);
  border-color: var(--border-color);
}

/* 三栏布局 */
.main-container {
  display: flex;
  flex-wrap: nowrap;
  width: 100%;
  max-width: 1680px;
  margin: 0 auto;
  padding: 20px 0;
  justify-content: center;
  gap: 20px;
  box-sizing: border-box;
  align-items: flex-start;
}

/* 左侧边栏 */
.sidebar-left {
  width: 18%;
  min-width: 18%;
  max-width: 18%;
  flex-shrink: 0;
  order: 1;
  box-sizing: border-box;
  background: var(--content-bg-color);
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

/* 右侧边栏 */
.sidebar-right {
  width: 24%;
  min-width: 24%;
  max-width: 24%;
  flex-shrink: 0;
  order: 3;
  box-sizing: border-box;
  background: var(--content-bg-color);
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

/* 中间内容区域 */
.content-wrap {
  flex: 1;
  min-width: 0;
  order: 2;
  box-sizing: border-box;
  background: var(--content-bg-color);
  border-radius: 8px;
  padding: 40px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
  position: relative;
  left: 0;
  right: 0;
  margin: 0 auto;
}

/* 响应式布局 */
@media (max-width: 1200px) {
  .sidebar-left,
  .sidebar-right {
    width: 20%;
    min-width: 20%;
    max-width: 20%;
  }
}

@media (max-width: 992px) {
  .sidebar-left,
  .sidebar-right {
    width: 22%;
    min-width: 22%;
    max-width: 22%;
  }
}

@media (max-width: 768px) {
  .main-container {
    flex-direction: column;
    padding: 10px;
  }

  .sidebar-left,
  .sidebar-right {
    width: 100%;
    min-width: 100%;
    max-width: 100%;
    order: 1;
  }

  .content-wrap {
    width: 100%;
    max-width: 100%;
    min-width: 100%;
    order: 2;
  }

  .sidebar-right {
    order: 3;
  }
}

/* === css/components.css === */
/* Dygita CSS 层次：组件层（可复用 UI 组件样式） */

/* Sidebar widgets */
.sidebar-left .widget-profile {
    text-align: center;
    padding: 10px;
}

.sidebar-left .profile-avatar img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
}

.sidebar-left .profile-info {
    margin-top: 10px;
}

.sidebar-right .contact-info {
    padding: 10px;
}

.sidebar-right .ad-box {
    padding: 10px;
}

.sidebar-right .ad-box img {
    width: 100%;
    border-radius: 4px;
}

/* Comments form */
.respond {
    padding: 20px;
}

#response {
    margin-bottom: 20px;
    font-size: 1.2rem;
    color: var(--text-color);
}

#comment-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.comments-count-title {
    margin: 20px 0;
    padding: 10px 20px;
    font-size: 1.1rem;
    color: var(--text-color);
}

/* 相关文章样式 */
.related_posts {
    margin: 30px 0;
    padding: 20px;
    background: #f9f9f9;
    background: var(--card-bg-color, #f9f9f9);
    border-radius: 8px;
}

.related-title {
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 18px;
    color: #333;
    color: var(--text-color, #333);
    border-bottom: 2px solid var(--accent-color, #e74c3c);
    padding-bottom: 10px;
}

.related-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.related-item {
    flex: 1 1 calc(33.333% - 10px);
    min-width: 200px;
    background: var(--content-bg-color, #fff);
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.related-item:hover {
    transform: translateY(-5px);
}

.related-thumb {
    width: 100%;
    height: 120px;
    object-fit: cover;
}

.related-item .related-item-title {
    display: block;
    padding: 10px;
    font-size: 14px;
    color: #333;
    color: var(--text-color, #333);
    text-decoration: none;
    border: none;
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.no-related {
    text-align: center;
    padding: 20px;
}

/* 作者页「关于我」区块 */
.author-about .author-about-inner {
    padding: 20px 0;
    max-width: 720px;
    margin: 0 auto;
}

.author-about .author-profile {
    text-align: center;
    margin-bottom: 24px;
}

.author-about .author-avatar {
    margin-bottom: 12px;
}

.author-about .author-avatar img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
}

.author-about .author-name {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
    color: var(--text-color, #333);
}

.author-about .author-bio {
    margin-bottom: 24px;
    line-height: 1.7;
    color: #555;
    color: var(--text-color, #555);
}

.author-about .author-bio p {
    margin: 0;
}

.author-about .author-contact,
.author-about .author-stats {
    margin-bottom: 20px;
    padding: 16px 0;
    border-top: 1px solid var(--border-color, #eee);
}

.author-about .author-contact h3,
.author-about .author-stats h3 {
    margin: 0 0 12px 0;
    font-size: 1.1rem;
    color: #333;
    color: var(--text-color, #333);
}

.author-about .contact-list p,
.author-about .author-stats p {
    margin: 0;
    color: #555;
    color: var(--text-color, #555);
}

.author-about .contact-list a {
    color: var(--link-color, #1098f7);
    text-decoration: none;
}

.author-about .contact-list a:hover {
    text-decoration: underline;
}

.author-about .author-stats p span {
    margin-right: 20px;
}

.author-about .author-stats p span i {
    margin-right: 6px;
}

.archive-header.section-title {
    margin-top: 32px;
    margin-bottom: 16px;
}

.archive-header.section-title h2 {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.hot-posts {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: left;
}

.hot-posts li {
    margin: 10px 0;
    padding-left: 20px;
    position: relative;
}

.hot-posts li:before {
    content: '\f0da';
    font-family: 'FontAwesome';
    position: absolute;
    left: 0;
    color: var(--accent-color, #e74c3c);
}

.hot-posts li a {
    color: #333;
    color: var(--text-color, #333);
    text-decoration: none;
    transition: color 0.3s ease;
}

.hot-posts li a:hover {
    color: var(--accent-color, #e74c3c);
}

@media (max-width: 768px) {
    .related-item {
        flex: 1 1 calc(50% - 10px);
    }
}

@media (max-width: 576px) {
    .related-item {
        flex: 1 1 100%;
    }
}

/* 文章目录样式 */
.widget-catalog {
    background: #f9f9f9;
    background: var(--card-bg-color, #f9f9f9);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
}

.widget-catalog .title h2 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 16px;
    color: #333;
    color: var(--text-color, #333);
    border-bottom: 2px solid var(--accent-color, #e74c3c);
    padding-bottom: 8px;
}

.catalog-content ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.catalog-content li {
    margin: 8px 0;
    padding-left: 15px;
    position: relative;
}

.catalog-content li:before {
    content: '\f0da';
    font-family: 'FontAwesome';
    position: absolute;
    left: 0;
    color: var(--accent-color, #e74c3c);
    font-size: 12px;
}

.catalog-content li ul {
    margin-left: 15px;
    margin-top: 5px;
}

.catalog-content a {
    color: #333;
    color: var(--text-color, #333);
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 14px;
    display: block;
    padding: 3px 0;
}

.catalog-content a:hover {
    color: var(--accent-color, #e74c3c);
    padding-left: 5px;
}

.catalog-content a.active {
    color: var(--accent-color, #e74c3c);
    font-weight: bold;
    padding-left: 10px;
    border-left: 3px solid var(--accent-color, #e74c3c);
}

.no-catalog {
    text-align: center;
    color: #999;
    color: var(--muted-text-color, #999);
    font-size: 14px;
    padding: 20px 0;
}

/* 目录悬浮样式 */
.widget-catalog.fixed {
    position: sticky;
    top: 20px;
    z-index: var(--z-catalog-sticky, 1100);
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* 跳转页面样式 */
body {
    background: var(--body-bg-color, #f5f7f9);
}

.loading {
    -webkit-animation: fadein 2s;
    -moz-animation: fadein 2s;
    -o-animation: fadein 2s;
    animation: fadein 2s
}

@-moz-keyframes fadein {
    from {
        opacity: 0
    }

    to {
        opacity: 1
    }
}

@-webkit-keyframes fadein {
    from {
        opacity: 0
    }

    to {
        opacity: 1
    }
}

@-o-keyframes fadein {
    from {
        opacity: 0
    }

    to {
        opacity: 1
    }
}

@keyframes fadein {
    from {
        opacity: 0
    }

    to {
        opacity: 1
    }
}

.spinner-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    z-index: var(--z-modal, 1600);
    height: 100%;
    min-width: 100%;
    min-height: 100%;
    background: var(--overlay-bg-color, rgba(255, 255, 255, 0.93))
}

.spinner-text {
    position: absolute;
    top: 50%;
    left: 50%;
    margin-left: -90px;
    margin-top: 2px;
    color: #BBB;
    letter-spacing: 1px;
    font-weight: 700;
    font-size: 36px;
    font-family: Arial
}

.spinner {
    position: absolute;
    top: 50%;
    left: 50%;
    display: block;
    margin-left: -160px;
    width: 1px;
    height: 1px;
    border: 25px solid rgba(100, 100, 100, 0.2);
    -webkit-border-radius: 50px;
    -moz-border-radius: 50px;
    border-radius: 50px;
    border-left-color: transparent;
    border-right-color: transparent;
    -webkit-animation: spin 1.5s infinite;
    -moz-animation: spin 1.5s infinite;
    animation: spin 1.5s infinite
}

@-webkit-keyframes spin {

    0%,
    100% {
        -webkit-transform: rotate(0deg) scale(1)
    }

    50% {
        -webkit-transform: rotate(720deg) scale(0.6)
    }
}

@-moz-keyframes spin {

    0%,
    100% {
        -moz-transform: rotate(0deg) scale(1)
    }

    50% {
        -moz-transform: rotate(720deg) scale(0.6)
    }
}

@-o-keyframes spin {

    0%,
    100% {
        -o-transform: rotate(0deg) scale(1)
    }

    50% {
        -o-transform: rotate(720deg) scale(0.6)
    }
}

@keyframes spin {

    0%,
    100% {
        transform: rotate(0deg) scale(1)
    }

    50% {
        transform: rotate(720deg) scale(0.6)
    }
}

/* === css/custom.css === */
/* Dygita CSS 层次：业务层（页面 / 模板定制样式） */

/**
 * Dygita Theme - Custom Styles
 * 提取自 header.php 的内联样式
 * @author Yacine Tsai
 * @version 1.1.0
 */

/* 进一步调整标题栏高度，减少留白 */
.l-header {
    padding: 20px 0;
    min-height: 120px;
    margin-top: 0;
    border-top: none;
    background: var(--header-bg-color, #E74C3C);
    background-color: var(--header-bg-color, #E74C3C);
}

/* 确保m-about没有额外的margin-top */
.l-header .m-about {
    margin-top: 0;
    padding-top: 0;
    position: relative;
    z-index: var(--z-header-content, 1);
}

/* 针对header及其子元素的margin和padding重置 */
.l-header,
.l-header * {
    margin-top: 0;
    padding-top: 0;
}

/* 确保没有任何元素在header上方 */
body > *:first-child,
body > header:first-of-type {
    margin-top: 0;
    padding-top: 0;
}

/* 调整标题栏内元素大小，适应新高度 */
.l-header #logo {
    margin-bottom: 10px;
}

.l-header #logo img {
    width: 50px;
    height: 50px;
}

.l-header .tit {
    font-size: 1.8rem;
    margin: 5px 0 5px;
}

.l-header .about {
    font-size: 0.9rem;
    margin-bottom: 10px;
}

/* 调整 header-canvas 元素高度，减少留白 */
.l-header #header-canvas {
    height: 100%;
    max-height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: var(--z-header-bg, 0);
    background-color: var(--header-bg-color, #E74C3C);
}

/* 确保canvas内部的canvas元素也有正确的背景色 */
.l-header #header-canvas canvas {
    background-color: var(--header-bg-color, #E74C3C);
}

/* 调整 hdbg 元素，减少留白 */
.l-header .hdbg {
    height: 100%;
    max-height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--header-bg-color, #E74C3C);
    z-index: var(--z-header-bg, 0);
}

/* 确保header背景色正确显示 - 修复顶部黑色区域 */
.l-header {
    background-color: var(--header-bg-color, #E74C3C);
    position: relative;
    overflow: hidden;
}

/* 代码块样式 */
pre {
    background: #2d2d2d;
    border-radius: 8px;
    margin: 20px 0;
    padding: 15px;
    overflow: auto;
    position: relative;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

pre code {
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 14px;
    line-height: 1.5;
    color: #ccc;
    background: transparent;
    padding: 0;
}

/* 代码块语言标签 */
pre[class*="language-python"]::before {
    content: "Python";
    position: absolute;
    top: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.2);
    color: #fff;
    padding: 3px 10px;
    font-size: 12px;
    border-bottom-left-radius: 8px;
    text-transform: uppercase;
    font-weight: bold;
}

pre[class*="language-javascript"]::before {
    content: "JavaScript";
    position: absolute;
    top: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.2);
    color: #fff;
    padding: 3px 10px;
    font-size: 12px;
    border-bottom-left-radius: 8px;
    text-transform: uppercase;
    font-weight: bold;
}

pre[class*="language-css"]::before {
    content: "CSS";
    position: absolute;
    top: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.2);
    color: #fff;
    padding: 3px 10px;
    font-size: 12px;
    border-bottom-left-radius: 8px;
    text-transform: uppercase;
    font-weight: bold;
}

pre[class*="language-markup"]::before {
    content: "HTML";
    position: absolute;
    top: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.2);
    color: #fff;
    padding: 3px 10px;
    font-size: 12px;
    border-bottom-left-radius: 8px;
    text-transform: uppercase;
    font-weight: bold;
}

pre[class*="language-bash"]::before {
    content: "Bash";
    position: absolute;
    top: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.2);
    color: #fff;
    padding: 3px 10px;
    font-size: 12px;
    border-bottom-left-radius: 8px;
    text-transform: uppercase;
    font-weight: bold;
}

pre[class*="language-json"]::before {
    content: "JSON";
    position: absolute;
    top: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.2);
    color: #fff;
    padding: 3px 10px;
    font-size: 12px;
    border-bottom-left-radius: 8px;
    text-transform: uppercase;
    font-weight: bold;
}

/* 复制按钮样式 */
.copy-to-clipboard-button {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 5px 10px;
    font-size: 12px;
    cursor: pointer;
    transition: background 0.3s ease;
    z-index: var(--z-content-control, 10);
}

.copy-to-clipboard-button:hover {
    background: rgba(255, 255, 255, 0.2);
}

.copy-to-clipboard-button.copied {
    background: #4CAF50;
}

/* 行号样式 */
.line-numbers {
    margin-right: 10px;
    color: #888;
    user-select: none;
}

/* 确保代码块在移动设备上显示正常 */
@media (max-width: 768px) {
    pre {
        padding: 10px;
    }

    pre code {
        font-size: 12px;
    }
}

/* 文章底部样式 - 修复贴边问题 */
.article-footer {
    margin-top: 30px;
    padding: 20px 30px;
    border-top: 1px dashed var(--border-color, #eee);
    margin-left: 30px;
    margin-right: 30px;
    border-radius: 10px;
    background-color: var(--card-bg-color, #f9f9f9);
    color: var(--blockquote-color, #666);
}

/* 相关文章样式 - 修复贴边问题 */
.related_posts {
    margin: 30px 30px;
    padding: 25px;
    background: var(--card-bg-color, #f9f9f9);
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.related_posts .related-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.related_posts .related-item {
    flex: 1 1 calc(33.333% - 10px);
    min-width: 200px;
    background: var(--content-bg-color, #fff);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.related_posts .related-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
}

.related_posts .related-item-title {
    display: block;
    padding: 12px 15px;
    font-size: 14px;
    color: var(--text-color, #333);
    text-decoration: none;
    border: none;
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 社交分享样式 */
.article-footer .article-share {
    margin-top: 20px;
    padding: 20px 20px;
    border-top: 1px solid var(--border-color, #eee);
    margin-left: 0;
    margin-right: 0;
    border-radius: 8px;
    background-color: var(--content-bg-color, #fff);
}

/* 文章标签样式 */
.article-footer .article-tags {
    margin-bottom: 20px;
    padding: 10px 15px;
    border-radius: 6px;
    background-color: var(--content-bg-color, #fff);
    display: inline-block;
}

.article-share h4 {
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 16px;
    color: #333;
}

.share-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.share-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s ease;
    color: #fff;
}

.share-btn i {
    margin-right: 5px;
    font-size: 16px;
}

/* 微信分享按钮 */
.share-btn.wechat {
    background: #07C160;
}

.share-btn.wechat:hover {
    background: #05A850;
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(7, 193, 96, 0.3);
}

/* 微博分享按钮 */
.share-btn.weibo {
    background: #E6162D;
}

.share-btn.weibo:hover {
    background: #C41227;
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(230, 22, 45, 0.3);
}

/* QQ分享按钮 */
.share-btn.qq {
    background: #12B7F5;
}

.share-btn.qq:hover {
    background: #0AA6E8;
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(18, 183, 245, 0.3);
}

/* 复制链接按钮 */
.share-btn.copy {
    background: #666;
}

.share-btn.copy:hover {
    background: #555;
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(102, 102, 102, 0.3);
}

/* 响应式调整 */
@media (max-width: 768px) {
    .share-buttons {
        justify-content: center;
    }

    .share-btn {
        flex: 1 1 calc(50% - 5px);
        min-width: 120px;
    }
}

@media (max-width: 576px) {
    .share-btn {
        flex: 1 1 100%;
    }
}

/* 老位图资源防放大，避免高分屏发糊与边缘锯齿 */
img[src*="/img/smilies/"],
img[src*="/img/fancybox_"],
img[src$="loading.gif"],
img[src$="vip.png"] {
    width: auto;
    height: auto;
    max-width: 100%;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

/* Swiper.js 轮播图样式 */
.swiper-container {
    width: 100%;
    height: 360px;
    position: relative;
}

.swiper-slide {
    position: relative;
    height: 360px;
    overflow: hidden;
}

.swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.swiper-slide-title {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 15px;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    font-size: 18px;
    font-weight: bold;
    text-align: center;
}

.swiper-pagination {
    bottom: 20px ;
}

.swiper-button-next,
.swiper-button-prev {
    color: white ;
    background: rgba(0, 0, 0, 0.3);
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

.swiper-button-next:after,
.swiper-button-prev:after {
    font-size: 20px ;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .swiper-container {
        height: 250px;
    }

    .swiper-slide {
        height: 250px;
    }

    .swiper-slide-title {
        font-size: 16px;
        padding: 10px;
    }

    .swiper-button-next,
    .swiper-button-prev {
        width: 30px;
        height: 30px;
    }

    .swiper-button-next:after,
    .swiper-button-prev:after {
        font-size: 16px ;
    }
}

@media (max-width: 576px) {
    .swiper-container {
        height: 200px;
    }

    .swiper-slide {
        height: 200px;
    }

    .swiper-slide-title {
        font-size: 14px;
        padding: 8px;
    }
}

/* 导航栏按钮对齐样式 */
.m-nav-all {
    justify-content: center ;
}

.m-nav .nav-container {
    justify-content: center ;
}

.m-nav .nav {
    display: flex ;
    justify-content: center ;
    align-items: center ;
    margin: 0 auto ;
}

.m-nav .nav li {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 50px;
}

.m-nav .nav li a {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 0 15px;
    transition: none ;
}

/* 移除推到右侧的样式 */
.m-nav .nav .search-toggle-li {
    margin-left: 0 ;
}

.m-nav .nav .color-toggle-li {
    margin-left: 0 ;
}

.m-nav .nav .theme-toggle-li,
.m-nav .nav .lang-toggle-li {
    margin-left: 0 ;
}

/* 消除导航栏按钮点击时的闪烁效果 */
.m-nav .nav li a:hover,
.m-nav .nav li a:active,
.m-nav .nav li a:focus {
    transition: none ;
}

/* 消除navbar导航栏的缩放闪烁效果 - 覆盖header.php中的内联样式 */
.navbar .nav li a,
.navbar .nav li a:hover,
.navbar .nav li a:active,
.navbar .nav li a:focus,
.navbar .nav li.current-menu-item a,
.navbar .nav li.current-page-item a {
    transform: none ;
    box-shadow: none ;
    outline: none ;
    transition: background-color 0.3s ease, color 0.3s ease ;
    -webkit-box-shadow: none ;
    -moz-box-shadow: none ;
}

/* 消除所有导航链接的outline效果,防止点击时的焦点框 */
.m-nav .nav li a,
.m-nav .nav li a:hover,
.m-nav .nav li a:active,
.m-nav .nav li a:focus,
.m-nav .nav li.active a,
.site-nav .menu-item a,
.site-nav .menu-item a:hover,
.site-nav .menu-item a:active,
.site-nav .menu-item a:focus {
    outline: none ;
    box-shadow: none ;
    -webkit-box-shadow: none ;
    -moz-box-shadow: none ;
}

/* 消除导航栏图标按钮的收放闪烁效果 */
.search-toggle-li .btn,
.color-toggle-li .btn,
.theme-toggle-li .btn {
    transition: none ;
    outline: none ;
    box-shadow: none ;
    -webkit-box-shadow: none ;
    -moz-box-shadow: none ;
}

.search-toggle-li .btn:hover,
.search-toggle-li .btn:active,
.search-toggle-li .btn:focus,
.color-toggle-li .btn:hover,
.color-toggle-li .btn:active,
.color-toggle-li .btn:focus,
.theme-toggle-li .btn:hover,
.theme-toggle-li .btn:active,
.theme-toggle-li .btn:focus,
.lang-toggle-li .btn:hover,
.lang-toggle-li .btn:active,
.lang-toggle-li .btn:focus {
    transition: none ;
    transform: none ;
    outline: none ;
    box-shadow: none ;
    -webkit-box-shadow: none ;
    -moz-box-shadow: none ;
}

/* 搜索按钮对齐样式 */
.search-toggle-li {
    display: flex;
    align-items: center;
    height: 50px;
}

.search-toggle-li .search-toggle {
    display: flex;
    align-items: center;
    height: 100%;
}

.search-toggle-li .search-toggle .btn {
    display: flex;
    align-items: center;
    height: 100%;
    padding: 0 15px;
    margin: 0;
}

/* 颜色切换按钮对齐样式 */
.color-toggle-li {
    display: flex;
    align-items: center;
    height: 50px;
}

.color-toggle-li .color-toggle {
    display: flex;
    align-items: center;
    height: 100%;
}

.color-toggle-li .color-toggle .btn {
    display: flex;
    align-items: center;
    height: 100%;
    padding: 0 15px;
    margin: 0;
}

/* 主题切换按钮对齐样式 */
.theme-toggle-li {
    display: flex;
    align-items: center;
    height: 50px;
}

.theme-toggle-li .theme-toggle {
    display: flex;
    align-items: center;
    height: 100%;
}

.theme-toggle-li .theme-toggle .btn {
    display: flex;
    align-items: center;
    height: 100%;
    padding: 0 15px;
    margin: 0;
}

/* 语言切换按钮：与主题切换同风格 */
.lang-toggle-li {
    display: flex;
    align-items: center;
    height: 50px;
}
.lang-toggle-li .lang-toggle {
    display: flex;
    align-items: center;
    height: 100%;
}
.lang-toggle-li .lang-toggle .btn {
    display: flex;
    align-items: center;
    height: 100%;
    padding: 0 15px;
    margin: 0;
    text-decoration: none;
}

/* 确保按钮内的图标也上下居中 */
.btn i {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 修复页面顶部可能出现的异常元素 */
body > div.fixed {
    position: relative ;
}

/* 确保没有任何固定定位元素在页面顶部异常显示 */
.main-container,
.content-wrap {
    position: relative ;
    top: auto ;
}

/* 归档页面文章样式 - 修复中间文章栏太靠边的问题 */
.excerpt-one {
    background: var(--content-bg-color, #fff) ;
    padding: 25px ;
    margin-bottom: 20px ;
    border-radius: 10px ;
    box-shadow: 0 2px 15px rgba(0,0,0,0.05) ;
    transition: all 0.3s ease ;
}

.excerpt-one:hover {
    box-shadow: 0 5px 20px rgba(0,0,0,0.1) ;
    transform: translateY(-2px) ;
}

.excerpt-one .note {
    display: block ;
    margin-bottom: 15px ;
    line-height: 1.6 ;
    color: var(--text-color, #333) ;
    padding: 0 10px ;
}

.excerpt-one .auth-span {
    clear: both ;
    display: block ;
    margin-top: 15px ;
    font-size: 12px ;
    color: var(--blockquote-color, #999) ;
    border-top: none ;
    padding-top: 0 ;
}

/* 文章详情页样式 - 修复中间文章栏太靠边的问题 */
.content .article-content {
    line-height: 1.8 ;
    font-size: 16px ;
    color: var(--text-color, #333) ;
    word-wrap: break-word ;
    padding: 0 30px ;
    margin: 0 auto ;
    max-width: 800px ;
    box-sizing: border-box ;
}

/* 增强优先级 - 确保样式覆盖所有其他规则 */
.main-container .content-wrap .content .article-content {
    padding: 0 30px ;
    margin: 0 auto ;
    max-width: 800px ;
}

/* 直接针对文章内容的段落添加边距 */
.article-content p {
    margin-left: 20px ;
    margin-right: 20px ;
    max-width: calc(100% - 40px) ;
}

/* 修复可能的侧边栏切换按钮位置异常 */
.sidebar-toggle {
    min-height: 60px ;
    position: fixed ;
    top: 50% ;
    left: 0 ;
    right: auto ;
    transform: translateY(-50%) ;
    z-index: var(--z-sidebar-toggle, 1200) ;
}

.sidebar-toggle.right {
    left: auto ;
    right: 0 ;
}

/* 隐藏header区域中的分类信息 */
.l-header .metacat,
#l-header .metacat {
    display: none ;
    visibility: hidden ;
    opacity: 0 ;
    position: absolute ;
    top: -9999px ;
    left: -9999px ;
}

/* 确保没有其他元素在header区域显示分类信息 */
.l-header > *:not(.m-about):not(.hdbg):not(#header-canvas),
#l-header > *:not(.m-about):not(.hdbg):not(#header-canvas) {
    display: none ;
    visibility: hidden ;
    opacity: 0 ;
}

/* 确保侧边栏切换按钮不会出现在页面顶部 */
body > .sidebar-toggle {
    top: 50% ;
    transform: translateY(-50%) ;
}

/* 强制确保 sidebar-toggle 在正确的位置 */
.sidebar-toggle.left {
    left: 0 ;
    right: auto ;
}

/* 确保没有意外的高度计算问题 */
html, body {
    height: 100% ;
    min-height: 100vh ;
}

/* 修复导航栏可能出现的箭头 */
.m-nav .nav li::before,
.m-nav .nav li::after,
.nav li::before,
.nav li::after,
.nav li a::before,
.nav li a::after,
.navbar .nav li::before,
.navbar .nav li::after,
.navbar .nav li a::before,
.navbar .nav li a::after {
    display: none ;
    content: none ;
}

/* 修复文章标题可能出现的箭头 */
.article-header::before,
.article-header::after,
.article-title::before,
.article-title::after,
.article-title a::before,
.article-title a::after {
    display: none ;
    content: none ;
}

/* 标签云页面样式 */
.tag-cloud-page {
    margin-bottom: 40px;
}

.tag-cloud-canvas-wrapper {
    text-align: center;
    background: var(--content-bg-color);
    padding: 20px;
    border-radius: 8px;
}

#tag-cloud-tags {
    max-width: 100%;
    height: auto;
}

.tag-cloud-fallback {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    padding: 20px;
}

.tag-cloud-fallback .tag {
    display: inline-block;
    padding: 5px 15px;
    background: var(--card-bg-color);
    color: var(--text-color);
    border-radius: 20px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.tag-cloud-fallback .tag:hover {
    background: var(--link-color);
    color: #fff;
}

.category-list-page h2 {
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--link-color);
    color: var(--text-color);
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
}

.category-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: var(--card-bg-color);
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-color);
    transition: all 0.3s ease;
}

.category-item:hover {
    background: var(--link-color);
    color: #fff;
    transform: translateY(-3px);
}

.category-count {
    background: rgba(0,0,0,0.1);
    padding: 2px 10px;
    border-radius: 10px;
    font-size: 12px;
}

.category-item:hover .category-count {
    background: rgba(255,255,255,0.2);
}

@media (max-width: 768px) {
    .category-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
}

/* 确保搜索遮罩层默认完全隐藏 */
.search-pop-overlay,
#search-form {
    visibility: hidden ;
    opacity: 0 ;
    pointer-events: none ;
}

.search-pop-overlay {
    z-index: var(--z-overlay, 1500) ;
}

#search-form {
    z-index: var(--z-modal, 1600) ;
}

.search-pop-overlay.search-active,
#search-form.search-active {
    visibility: visible ;
    opacity: 1 ;
    pointer-events: auto ;
}

/* 移除分类数量显示 */
.category-list-count {
    display: none ;
}

/* 分类两列布局，居中对齐 */
.sidebar-right .widget-content .category-list {
    display: flex ;
    flex-wrap: wrap ;
    gap: 10px ;
    padding: 5px ;
}

.sidebar-right .category-list-item {
    flex: 0 0 calc(50% - 5px) ;
    max-width: calc(50% - 5px) ;
    text-align: center ;
    width: calc(50% - 5px) ;
    float: none ;
    margin: 0 ;
}

.sidebar-right .category-list-link {
    display: block ;
    text-align: center ;
}

/* 修改布局：左右侧边栏18%，中间自适应 */
.main-container {
    display: flex ;
    flex-wrap: nowrap ;
    width: 100% ;
    max-width: 1680px ;
    margin: 0 auto ;
    padding: 20px ;
    gap: 20px ;
    box-sizing: border-box ;
    align-items: stretch ;
}

/* 左侧边栏 */
.sidebar-left {
    width: 18% ;
    min-width: 18% ;
    max-width: 18% ;
    flex-shrink: 0 ;
    order: 1 ;
    box-sizing: border-box ;
}

/* 右侧边栏 */
.sidebar-right {
    width: 24% ;
    min-width: 24% ;
    max-width: 24% ;
    flex-shrink: 0 ;
    order: 3 ;
    box-sizing: border-box ;
}

/* 中间内容区域 */
.content-wrap {
    flex: 1 ;
    min-width: 0 ;
    order: 2 ;
    box-sizing: border-box ;
    padding: 0 ;
}

/* 响应式调整 */
@media (max-width: 1200px) {
    .sidebar-left,
    .sidebar-right {
        width: 20% ;
        min-width: 20% ;
        max-width: 20% ;
    }
}

@media (max-width: 992px) {
    .sidebar-left,
    .sidebar-right {
        width: 22% ;
        min-width: 22% ;
        max-width: 22% ;
    }
}

@media (max-width: 768px) {
    .main-container {
        flex-direction: column ;
        padding: 10px ;
    }

    .sidebar-left,
    .sidebar-right {
        width: 100% ;
        min-width: 100% ;
        max-width: 100% ;
        order: 1 ;
    }

    .content-wrap {
        width: 100% ;
        max-width: 100% ;
        min-width: 100% ;
        order: 2 ;
    }

    .sidebar-right {
        order: 3 ;
    }
}

/* ========================================
   404 页面样式
   ======================================== */
.error-404 {
    text-align: center;
    padding: 60px 20px;
    background: var(--content-bg-color);
    border-radius: 8px;
    margin: 40px 0;
    position: relative;
    overflow: hidden;
}

.error-404::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        rgba(231, 76, 60, 0.05) 0%,
        rgba(52, 152, 219, 0.05) 25%,
        rgba(46, 204, 113, 0.05) 50%,
        rgba(155, 89, 182, 0.05) 75%,
        rgba(241, 196, 15, 0.05) 100%
    );
    animation: gradient-shift 15s ease infinite;
    z-index: var(--z-header-bg, 0);
}

@keyframes gradient-shift {
    0% { transform: translateX(0) translateY(0); }
    50% { transform: translateX(-25%) translateY(-25%); }
    100% { transform: translateX(0) translateY(0); }
}

.error-404 > * {
    position: relative;
    z-index: var(--z-header-content, 1);
}

.error-404 .error-code {
    font-size: 120px;
    font-weight: bold;
    color: var(--link-color);
    margin: 0;
    line-height: 1;
    text-shadow: 3px 3px 0 rgba(0, 0, 0, 0.1);
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-20px); }
    60% { transform: translateY(-10px); }
}

.error-404 .error-message {
    font-size: 24px;
    color: var(--text-color);
    margin: 20px 0;
}

.error-404 .error-description {
    font-size: 16px;
    color: #999;
    margin: 20px 0 40px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.error-404 .error-actions {
    margin: 30px 0;
    display: flex;
    justify-content: center;
    gap: 15px;
}

.error-404 .error-actions .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 25px;
    text-decoration: none;
    font-size: 14px;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.error-404 .error-actions .btn i {
    margin-right: 8px;
}

.error-404 .error-actions .btn-primary {
    background: var(--link-color);
    color: white;
}

.error-404 .error-actions .btn-primary:hover {
    background: var(--hover-color);
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.error-404 .error-actions .btn-secondary {
    background: #f0f0f0;
    color: var(--text-color);
}

.error-404 .error-actions .btn-secondary:hover {
    background: #e0e0e0;
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.error-404 .search-box {
    margin: 40px auto;
    max-width: 500px;
    position: relative;
}

.error-404 .search-box input {
    width: 100%;
    padding: 15px 50px 15px 20px;
    border: 2px solid #ddd;
    border-radius: 25px;
    font-size: 14px;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.error-404 .search-box input:focus {
    outline: none;
    border-color: var(--link-color);
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.1);
}

.error-404 .search-box button {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    background: var(--link-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.error-404 .search-box button:hover {
    background: var(--hover-color);
    transform: translateY(-50%) scale(1.05);
}

.error-404 .content-section {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 40px;
    margin-top: 60px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.error-404 .content-block {
    flex: 1 1 calc(50% - 20px);
    min-width: 300px;
    text-align: left;
}

.error-404 .content-block h3 {
    font-size: 18px;
    color: var(--text-color);
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--link-color);
    display: inline-block;
}

.error-404 .content-block ul {
    list-style: none;
    padding: 0;
}

.error-404 .content-block li {
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.3s ease;
}

.error-404 .content-block li:hover {
    padding-left: 10px;
}

.error-404 .content-block li:last-child {
    border-bottom: none;
}

.error-404 .content-block a {
    color: var(--link-color);
    text-decoration: none;
    transition: color 0.3s ease;
    display: flex;
    align-items: center;
}

.error-404 .content-block a i {
    margin-right: 8px;
    font-size: 12px;
}

.error-404 .content-block a:hover {
    color: var(--hover-color);
    text-decoration: underline;
}

.error-404 .tags-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
}

.error-404 .tags-cloud a {
    background: #f0f0f0;
    color: var(--text-color);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 13px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.error-404 .tags-cloud a:hover {
    background: var(--link-color);
    color: white;
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .error-404 {
        padding: 40px 15px;
        margin: 20px 0;
    }
    .error-404 .error-code {
        font-size: 80px;
    }
    .error-404 .error-message {
        font-size: 18px;
    }
    .error-404 .error-actions {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
    .error-404 .error-actions .btn {
        width: 200px;
    }
    .error-404 .content-section {
        flex-direction: column;
        gap: 30px;
    }
    .error-404 .content-block {
        flex: 1 1 100%;
    }
}

/* ========================================
   相关文章样式
   ======================================== */
.related_posts {
    margin: 30px 0;
    padding: 20px;
    background: var(--card-bg-color, #f9f9f9);
    border-radius: 8px;
}

.related-title {
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 18px;
    color: var(--text-color, #333);
    border-bottom: 2px solid #e74c3c;
    padding-bottom: 10px;
}

.related-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.related-item {
    flex: 1 1 calc(33.333% - 10px);
    min-width: 200px;
    background: var(--content-bg-color, #fff);
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.related-item:hover {
    transform: translateY(-5px);
}

.related-thumb {
    width: 100%;
    height: 120px;
    object-fit: cover;
}

.related-item .related-item-title {
    display: block;
    padding: 10px;
    font-size: 14px;
    color: var(--text-color, #333);
    text-decoration: none;
    border: none;
    margin: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.no-related {
    text-align: center;
    padding: 20px;
}

.hot-posts {
    list-style: none;
    padding: 0;
    margin: 0;
    text-align: left;
}

.hot-posts li {
    margin: 10px 0;
    padding-left: 20px;
    position: relative;
}

.hot-posts li:before {
    content: '\f0da';
    font-family: 'FontAwesome';
    position: absolute;
    left: 0;
    color: #e74c3c;
}

.hot-posts li a {
    color: var(--text-color, #333);
    text-decoration: none;
    transition: color 0.3s ease;
}

.hot-posts li a:hover {
    color: #e74c3c;
}

@media (max-width: 768px) {
    .related-item {
        flex: 1 1 calc(50% - 10px);
    }
}

@media (max-width: 576px) {
    .related-item {
        flex: 1 1 100%;
    }
}

/* Download page - file links (download.php) */
#filelink a {
    margin: 25px 15px 25px 0;
    color: #4094EF;
    padding: 5px 50px;
    font-family: "Microsoft YaHei", "微软雅黑", sans-serif;
    font-size: 19px;
    border: 1px solid #4094EF;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    text-decoration: none;
}

#filelink a:hover {
    background: #4094EF;
    color: #FFF;
    transition-duration: 0.3s;
    border-color: #FFF;
}

#filelink .filelink-inner {
    text-align: center;
}

/* About page (about.php) */
.about-content .about-avatar {
    text-align: center;
    margin-bottom: 20px;
}

.about-content .about-avatar img {
    width: 150px;
    height: 150px;
    border-radius: 50%;
}

.about-content .about-info {
    text-align: center;
    margin-bottom: 30px;
}

.about-content .about-info h2 {
    margin-bottom: 10px;
}

.about-content .about-info p {
    margin-bottom: 20px;
    color: #666;
    color: var(--blockquote-color, #666);
}

.about-content .about-details h3 {
    margin-bottom: 15px;
    border-bottom: 1px solid #eee;
    border-bottom-color: var(--border-color, #eee);
    padding-bottom: 10px;
}

.about-content .about-details h3 + p {
    margin-bottom: 15px;
    line-height: 1.6;
}

.about-content .about-details h3 + p + p {
    margin-bottom: 15px;
    line-height: 1.6;
}

.about-content .about-details h3:nth-of-type(2) {
    margin-top: 30px;
}

.about-content .about-details p {
    margin-bottom: 10px;
}

/* Chongzhi page (chongzhi.php) */
.page-chongzhi .alert.alert-warning {
    font-size: 16px;
}

/* Tougao page (tougao.php) */
.googlo-tougao .field-row {
    text-align: left;
    padding-top: 10px;
}

.googlo-tougao .field-row input,
.googlo-tougao .field-row textarea {
    width: 98%;
}

.googlo-tougao .actions-row {
    text-align: center;
    padding-top: 10px;
}

.googlo-tougao .actions-row .button,
.googlo-tougao .actions-row .buttn {
    width: 100px;
    height: 30px;
}

/* Shuoshuo page (shuoshuo.php) */
.shuoshuo-sjsj {
    float: left;
}

/* Archives page (archives.php) */
.archives-list {
    display: none;
}

/* Tag cloud page (page-tag-cloud.php) */
.tag-cloud-page #tag-cloud-tags {
    display: none;
}

/* Product page (product.php) */
.product-list .thumb-img .thumb {
    width: 275px;
    height: 275px;
}

/* Go page (go.php) */
.go-loading-message {
    position: absolute;
    top: 60%;
    left: 50%;
    transform: translateX(-50%);
    color: #999;
    font-size: 14px;
}

.go-loading-message a {
    color: #4094EF;
    word-break: break-all;
}


/* === css/inline.css === */
/* Dygita CSS 层次：补丁层（小体量覆盖与兼容性修复） */

/* 懒加载占位符样式 */
img.lazy {
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

img {
    max-width: 100%;
    height: auto;
}

/* 内联样式 */

.l-header {
    background-color: #E74C3C;
    background-color: var(--header-bg-color, #E74C3C);
    position: relative;
    overflow: hidden;
    margin-top: 0;
    padding-top: 0;
}

.l-header .hdbg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #E74C3C;
    background-color: var(--header-bg-color, #E74C3C);
    z-index: var(--z-header-bg, 0);
}

.l-header .m-about {
    position: relative;
    z-index: var(--z-header-content, 1);
}

.l-header #header-canvas {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    z-index: var(--z-header-bg, 0);
}

#m-header .right {
    font-size: 18px;
}

