/* 背景宇宙星光  */
#universe{
  display: block;
  position: fixed;
  margin: 0;
  padding: 0;
  border: 0;
  outline: 0;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  /* 这个是调置顶的优先级的，-1在文章页下面，背景上面，个人推荐这种 */
  z-index: -1;
}

/* 全局背景渐变 */
html {
  background: linear-gradient(
    -45deg,
    #1a1a1a,
    #2d2d2d,
    #3a3a3a,
    #2d2d2d,
    #1a1a1a
  );
  background-size: 400% 400%;
  -webkit-animation: Gradient 15s ease infinite;
  -moz-animation: Gradient 15s ease infinite;
  animation: Gradient 15s ease infinite;
  min-height: 100%;
}

/* 浅色模式背景 */
[data-theme="light"] html {
  background: linear-gradient(
    -45deg,
    #f5f5f5,
    #e8e8e8,
    #f5f5f5,
    #e8e8e8,
    #f5f5f5
  );
  background-size: 400% 400%;
  -webkit-animation: Gradient 15s ease infinite;
  -moz-animation: Gradient 15s ease infinite;
  animation: Gradient 15s ease infinite;
}

/* 确保body继承背景 */
body {
  background: transparent;
  min-height: 100%;
}

/* 公告卡片图标样式 */
#aside-content .card-widget.card-announcement .item-headline i {
  color: #3eb8be !important; /* 默认红色 */
}

/* 黑夜模式下的公告卡片图标 */
[data-theme="dark"] #aside-content .card-widget.card-announcement .item-headline i {
  color: #2f83d6 !important; /* 蓝色，与Follow me按钮颜色一致 */
}

/* 标签卡片图标样式 */
#aside-content .card-widget.card-tags .item-headline i {
  color: #3eb8be !important;
}

/* 归档卡片图标样式 */
#aside-content .card-widget.card-archives .item-headline i {
  color: #3eb8be !important;
}

/* 暗夜模式下的标签卡片图标样式 */
[data-theme="dark"] #aside-content .card-widget.card-tags .item-headline i {
  color: #2f83d6 !important;
}

/* 暗夜模式下的归档卡片图标样式 */
[data-theme="dark"] #aside-content .card-widget.card-archives .item-headline i {
  color: #2f83d6 !important;
}

/* 侧边栏卡片统一样式 - 强制使用暗夜模式样式 */
/* 匹配所有在aside-content中的card-widget，无论嵌套层级 */
#aside-content .card-widget:not(.card-info) {
  background-color: #000000 !important;
  background-image: none !important;
  border-radius: 12px !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5) !important;
  --card-bg: #000000 !important;
  --font-color: #e0e0e0 !important;
  --text-highlight-color: #b0b0b0 !important;
}

/* 强制设置标题颜色 */
#aside-content .card-widget:not(.card-info) > .item-headline {
  color: #e0e0e0 !important;
  font-weight: 600 !important;
}

/* 强制设置内容颜色 */
#aside-content .card-widget:not(.card-info) .card-content,
#aside-content .card-widget:not(.card-info) .announcement_content,
#aside-content .card-widget:not(.card-info) .card-tag-cloud,
#aside-content .card-widget:not(.card-info) .card-archive-list,
#aside-content .card-widget:not(.card-info) .card-category-list {
  color: #b0b0b0 !important;
}

/* 强制设置链接颜色 */
#aside-content .card-widget:not(.card-info) a {
  color: #e0e0e0 !important;
  transition: color 0.3s ease !important;
}

#aside-content .card-widget:not(.card-info) a:hover {
  color: #3eb8be !important;
}

/* 强制设置标签云颜色 */
#aside-content .card-widget.card-tags .card-tag-cloud a {
  color: #b0b0b0 !important;
}

#aside-content .card-widget.card-tags .card-tag-cloud a:hover {
  color: #3eb8be !important;
}

/* 强制设置归档列表颜色 */
#aside-content .card-widget.card-archives .card-archive-list a {
  color: #b0b0b0 !important;
}

#aside-content .card-widget.card-archives .card-archive-list a:hover {
  color: #3eb8be !important;
}

/* 页脚黑色背景 */
#footer {
  background-color: #000000 !important;
  color: #ffffff !important;
}

#footer a {
  color: #ffffff !important;
}

#footer a:hover {
  color: #3eb8be !important;
}

/* 下载按钮样式 */
.download-btn {
    background-color: #003366;
    color: white;
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    margin-bottom: 20px; /* 添加一些间距 */
}

.download-btn:hover {
    background-color: #45a049; /* 鼠标悬停时保持原始颜色 */
    transform: scale(1); /* 鼠标悬停时保持元素大小不变 */
}

.parent-class .download-btn a {
    color: white; /* 白色 */
}

/* 引用按钮和弹出框样式 */
.citation-button {
    padding: 10px 20px;
    background-color: #003366;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
}

.citation-button:hover {
    background-color: #45a049;
}

.citation-popup {
    display: none;
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    padding: 20px;
    background-color: white;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.8);
    border-radius: 10px;
    text-align: center;
    z-index: 1000; /* 设置一个较高的层叠顺序值 */
}

.close-button, .copy-button {
    margin-top: 10px;
    padding: 5px 10px;
    color: white;
    border: none;
    cursor: pointer;
}

.close-button {
    background-color: #f44336;
}

.close-button:hover {
    background-color: #d32f2f;
}

.copy-button {
    background-color: #008CBA;
}

.copy-button:hover {
    background-color: #007bb5;
}

@font-face {
  font-family: 'OldSong, Times';
  font-display: swap;
  src: url('/fonts/OldSong.ttf') format("truetype"),
       url('/fonts/Times.ttf') format("truetype");
}


/* 侧边栏个人信息卡片动态渐变色 */
#aside-content > .card-widget.card-info {
  background: linear-gradient(
    -45deg,
    #e8d8b9,
    #eccec5,
    #a3e9eb,
    #bdbdf0,
    #eec1ea
  );
  box-shadow: 0 0 5px rgb(66, 68, 68);
  position: relative;
  background-size: 400% 400%;
  -webkit-animation: Gradient 10s ease infinite;
  -moz-animation: Gradient 10s ease infinite;
  animation: Gradient 10s ease infinite !important;
}
@-webkit-keyframes Gradient {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}
@-moz-keyframes Gradient {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}
@keyframes Gradient {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

/* 黑夜模式适配
[data-theme="dark"] #aside-content > .card-widget.card-info {
  background: linear-gradient(
    -45deg,
    #1a1a1a,
    #2d2d2d,
    #3a3a3a,
    #2d2d2d,
    #1a1a1a
  );
  box-shadow: 0 0 5px rgb(66, 68, 68);
  position: relative;
  background-size: 400% 400%;
  -webkit-animation: Gradient 10s ease infinite;
  -moz-animation: Gradient 10s ease infinite;
  animation: Gradient 10s ease infinite !important;
} */

/* 黑夜模式下的个人信息卡片字体颜色 */
[data-theme="dark"] #aside-content > .card-widget.card-info {
  color: #000000 !important;
}

[data-theme="dark"] #aside-content > .card-widget.card-info .author-info-name,
[data-theme="dark"] #aside-content > .card-widget.card-info .author-info-description,
[data-theme="dark"] #aside-content > .card-widget.card-info .site-data .headline,
[data-theme="dark"] #aside-content > .card-widget.card-info .site-data .length-num {
  color: #000000 !important;
}

/* 文章页面的个人信息卡片样式 - 强制使用黑灰渐变 */
.post #aside-content > .card-widget.card-info {
  background: linear-gradient(
    -45deg,
    #1a1a1a,
    #2d2d2d,
    #3a3a3a,
    #2d2d2d,
    #1a1a1a
  ) !important;
  box-shadow: 0 0 5px rgb(66, 68, 68) !important;
  position: relative !important;
  background-size: 400% 400% !important;
  -webkit-animation: Gradient 10s ease infinite !important;
  -moz-animation: Gradient 10s ease infinite !important;
  animation: Gradient 10s ease infinite !important;
}

/* 文章页面的个人信息卡片字体颜色 - 强制使用白色 */
.post #aside-content > .card-widget.card-info {
  color: #ffffff !important;
}

.post #aside-content > .card-widget.card-info .author-info-name,
.post #aside-content > .card-widget.card-info .author-info-description,
.post #aside-content > .card-widget.card-info .site-data .headline,
.post #aside-content > .card-widget.card-info .site-data .length-num {
  color: #ffffff !important;
}

/* 个人信息Follow me按钮 */
#aside-content > .card-widget.card-info > #card-info-btn {
  background-color: #3eb8be;
  border-radius: 8px;
}

/* 黑夜模式下的Follow me按钮 */
[data-theme="dark"] #aside-content > .card-widget.card-info > #card-info-btn {
  background-color: #003366;
}

/* 文章页面的Follow me按钮 - 强制使用深蓝色 */
.post #aside-content > .card-widget.card-info > #card-info-btn {
  background-color: #003366 !important;
  color: #ffffff !important;
}

