/* ============================================
   赛博朋克风格博客园皮肤
   Cyberpunk / Neon-Noir for Cnblogs
   配色：深黑底 + 霓虹青(#00f0ff) + 品红(#ff006e) + 紫(#bd00ff)
   ============================================ */

/* ---------- 全局重置与底色 ---------- */
* {
  box-sizing: border-box;
}

body {
  background: #0a0a12 !important;
  color: #c8d6e5 !important;
  font-family: "Courier New", Consolas, "Microsoft YaHei", monospace !important;
  line-height: 1.8 !important;
  /* 网格背景 + 渐变 */
  background-image:
    linear-gradient(rgba(0, 240, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 240, 255, 0.03) 1px, transparent 1px),
    radial-gradient(ellipse at top, rgba(189, 0, 255, 0.12) 0%, transparent 60%),
    radial-gradient(ellipse at bottom, rgba(255, 0, 110, 0.08) 0%, transparent 60%) !important;
  background-size:
    40px 40px,
    40px 40px,
    100% 100%,
    100% 100% !important;
  background-attachment: fixed !important;
}

/* 顶部扫描线效果 */
body::before {
  content: "";
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 240, 255, 0.015) 2px,
    rgba(0, 240, 255, 0.015) 4px
  );
  pointer-events: none;
  z-index: 9999;
}

a {
  color: #00f0ff !important;
  text-decoration: none !important;
  transition: all 0.2s ease !important;
  text-shadow: 0 0 8px rgba(0, 240, 255, 0.5) !important;
}

a:hover {
  color: #ff006e !important;
  text-shadow: 0 0 12px rgba(255, 0, 110, 0.8) !important;
}

/* ---------- 头部 / 博客标题 ---------- */
#header {
  border-bottom: 1px solid rgba(0, 240, 255, 0.3) !important;
  box-shadow: 0 0 20px rgba(0, 240, 255, 0.15), inset 0 -1px 0 rgba(0, 240, 255, 0.2) !important;
  background: rgba(10, 10, 18, 0.8) !important;
  backdrop-filter: blur(8px);
  padding: 30px 20px 20px !important;
  margin-bottom: 30px !important;
  position: relative;
}

#header::after {
  content: "";
  position: absolute;
  bottom: -1px; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, #00f0ff, #ff006e, transparent);
  box-shadow: 0 0 10px #00f0ff;
}

#blogTitle {
  font-size: 2.4em !important;
  font-weight: bold !important;
  letter-spacing: 4px !important;
}

#blogTitle a {
  color: #00f0ff !important;
  text-shadow:
    0 0 10px rgba(0, 240, 255, 0.8),
    0 0 20px rgba(0, 240, 255, 0.4),
    0 0 40px rgba(0, 240, 255, 0.2) !important;
  position: relative;
  display: inline-block;
}

#blogTitle a::before,
#blogTitle a::after {
  content: attr(data-text);
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  overflow: hidden;
}

#blogTitle a::before {
  left: 2px;
  text-shadow: -2px 0 #ff006e;
  clip: rect(0, 900px, 0, 0);
  animation: glitch-1 3s infinite linear alternate-reverse;
  opacity: 0.7;
}

#blogTitle a::after {
  left: -2px;
  text-shadow: -2px 0 #bd00ff, 2px 2px #00f0ff;
  clip: rect(0, 900px, 0, 0);
  animation: glitch-2 2s infinite linear alternate-reverse;
  opacity: 0.7;
}

@keyframes glitch-1 {
  0% { clip: rect(20px, 9999px, 30px, 0); }
  20% { clip: rect(60px, 9999px, 70px, 0); }
  40% { clip: rect(10px, 9999px, 20px, 0); }
  60% { clip: rect(80px, 9999px, 90px, 0); }
  80% { clip: rect(40px, 9999px, 50px, 0); }
  100% { clip: rect(5px, 9999px, 15px, 0); }
}

@keyframes glitch-2 {
  0% { clip: rect(60px, 9999px, 70px, 0); }
  20% { clip: rect(10px, 9999px, 20px, 0); }
  40% { clip: rect(80px, 9999px, 90px, 0); }
  60% { clip: rect(30px, 9999px, 40px, 0); }
  80% { clip: rect(50px, 9999px, 60px, 0); }
  100% { clip: rect(70px, 9999px, 80px, 0); }
}

#blogSubtitle {
  color: #ff006e !important;
  font-size: 0.95em !important;
  letter-spacing: 2px !important;
  margin-top: 8px !important;
  text-shadow: 0 0 8px rgba(255, 0, 110, 0.5) !important;
}

/* ---------- 文章区块 ---------- */
.day {
  background: rgba(15, 15, 25, 0.75) !important;
  border: 1px solid rgba(0, 240, 255, 0.2) !important;
  border-left: 3px solid #00f0ff !important;
  border-radius: 0 6px 6px 0 !important;
  margin-bottom: 30px !important;
  padding: 25px 30px !important;
  box-shadow:
    0 0 15px rgba(0, 240, 255, 0.08),
    inset 0 0 30px rgba(0, 0, 0, 0.4) !important;
  backdrop-filter: blur(4px);
  transition: all 0.3s ease !important;
  position: relative;
}

.day:hover {
  border-left-color: #ff006e !important;
  border-color: rgba(255, 0, 110, 0.3) !important;
  box-shadow:
    0 0 25px rgba(255, 0, 110, 0.15),
    inset 0 0 30px rgba(0, 0, 0, 0.4) !important;
}

.day::before {
  content: "// SYSTEM.LOG";
  position: absolute;
  top: 8px;
  right: 12px;
  font-size: 0.7em;
  color: rgba(0, 240, 255, 0.3);
  letter-spacing: 2px;
}

/* 文章标题 */
.postTitle {
  font-size: 1.6em !important;
  margin-bottom: 15px !important;
  border-bottom: 1px dashed rgba(0, 240, 255, 0.2) !important;
  padding-bottom: 10px !important;
}

.postTitle a {
  color: #e0f7fa !important;
  text-shadow: 0 0 10px rgba(0, 240, 255, 0.6) !important;
  letter-spacing: 1px !important;
}

.postTitle a:hover {
  color: #fff !important;
  text-shadow:
    0 0 10px #00f0ff,
    0 0 20px #00f0ff,
    0 0 30px rgba(255, 0, 110, 0.5) !important;
}

.postTitle::before {
  content: "▸ ";
  color: #ff006e;
  text-shadow: 0 0 8px #ff006e;
}

/* 文章正文 */
.postCon {
  color: #b0bec5 !important;
  font-size: 0.95em !important;
}

.postCon h1, .postCon h2, .postCon h3, .postCon h4 {
  color: #00f0ff !important;
  margin: 20px 0 10px !important;
  text-shadow: 0 0 8px rgba(0, 240, 255, 0.4) !important;
  border-left: 3px solid #ff006e !important;
  padding-left: 10px !important;
}

.postCon h2 { font-size: 1.3em !important; }
.postCon h3 { font-size: 1.15em !important; }

.postCon p {
  margin: 12px 0 !important;
}

.postCon code {
  background: rgba(0, 240, 255, 0.08) !important;
  color: #00f0ff !important;
  padding: 2px 6px !important;
  border-radius: 3px !important;
  font-family: "Courier New", monospace !important;
  border: 1px solid rgba(0, 240, 255, 0.2) !important;
  font-size: 0.9em !important;
}

.postCon pre {
  background: #0d0d1a !important;
  border: 1px solid rgba(0, 240, 255, 0.3) !important;
  border-left: 3px solid #ff006e !important;
  border-radius: 0 4px 4px 0 !important;
  padding: 15px !important;
  overflow-x: auto !important;
  margin: 15px 0 !important;
  box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.6) !important;
}

.postCon pre code {
  background: transparent !important;
  border: none !important;
  color: #a5d6a7 !important;
  text-shadow: none !important;
}

.postCon blockquote {
  background: rgba(189, 0, 255, 0.08) !important;
  border-left: 3px solid #bd00ff !important;
  padding: 10px 15px !important;
  margin: 15px 0 !important;
  color: #ce93d8 !important;
  font-style: italic !important;
}

.postCon img {
  border: 1px solid rgba(0, 240, 255, 0.3) !important;
  border-radius: 4px !important;
  box-shadow: 0 0 15px rgba(0, 240, 255, 0.15) !important;
  max-width: 100% !important;
}

.postCon table {
  border-collapse: collapse !important;
  width: 100% !important;
  margin: 15px 0 !important;
}

.postCon th, .postCon td {
  border: 1px solid rgba(0, 240, 255, 0.25) !important;
  padding: 8px 12px !important;
}

.postCon th {
  background: rgba(0, 240, 255, 0.1) !important;
  color: #00f0ff !important;
  text-shadow: 0 0 5px rgba(0, 240, 255, 0.5) !important;
}

/* 文章底部元信息 */
.postDesc {
  margin-top: 20px !important;
  padding-top: 12px !important;
  border-top: 1px dashed rgba(255, 0, 110, 0.25) !important;
  font-size: 0.82em !important;
  color: #78909c !important;
  letter-spacing: 0.5px !important;
}

.postDesc a {
  color: #ff006e !important;
  text-shadow: 0 0 5px rgba(255, 0, 110, 0.4) !important;
}

/* ---------- 侧边栏 ---------- */
#sideBar {
  background: rgba(15, 15, 25, 0.7) !important;
  border: 1px solid rgba(189, 0, 255, 0.25) !important;
  border-radius: 6px !important;
  padding: 20px !important;
  backdrop-filter: blur(4px);
}

#sideBarBlock {
  margin-bottom: 20px !important;
}

.mySearch {
  margin-bottom: 20px !important;
}

.mySearch input[type="text"] {
  background: rgba(0, 0, 0, 0.4) !important;
  border: 1px solid rgba(0, 240, 255, 0.4) !important;
  color: #00f0ff !important;
  padding: 8px 12px !important;
  border-radius: 4px 0 0 4px !important;
  font-family: "Courier New", monospace !important;
  outline: none !important;
}

.mySearch input[type="button"],
.mySearch button {
  background: rgba(255, 0, 110, 0.2) !important;
  border: 1px solid #ff006e !important;
  color: #ff006e !important;
  padding: 8px 15px !important;
  border-radius: 0 4px 4px 0 !important;
  cursor: pointer !important;
  font-family: "Courier New", monospace !important;
  text-shadow: 0 0 5px rgba(255, 0, 110, 0.5) !important;
  transition: all 0.2s !important;
}

.mySearch input[type="button"]:hover,
.mySearch button:hover {
  background: #ff006e !important;
  color: #0a0a12 !important;
  box-shadow: 0 0 15px rgba(255, 0, 110, 0.6) !important;
}

/* 侧边栏 widget 标题 */
.widgetTitle {
  color: #00f0ff !important;
  font-size: 1.1em !important;
  letter-spacing: 2px !important;
  margin-bottom: 12px !important;
  padding-bottom: 8px !important;
  border-bottom: 1px solid rgba(0, 240, 255, 0.3) !important;
  text-shadow: 0 0 8px rgba(0, 240, 255, 0.5) !important;
}

.widgetTitle::before {
  content: "◆ ";
  color: #ff006e;
}

.widget {
  margin-bottom: 20px !important;
}

.widget a {
  color: #b0bec5 !important;
  text-shadow: none !important;
}

.widget a:hover {
  color: #00f0ff !important;
  text-shadow: 0 0 8px rgba(0, 240, 255, 0.6) !important;
}

/* 侧边栏列表 */
#sideBar ul {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 !important;
}

#sideBar ul li {
  padding: 6px 0 6px 15px !important;
  border-bottom: 1px dotted rgba(0, 240, 255, 0.1) !important;
  position: relative;
  font-size: 0.9em !important;
}

#sideBar ul li::before {
  content: "›";
  position: absolute;
  left: 0;
  color: #ff006e;
}

/* ---------- 分页 ---------- */
.pager {
  text-align: center !important;
  margin: 30px 0 !important;
}

.pager a, .pager span {
  display: inline-block !important;
  padding: 6px 14px !important;
  margin: 0 3px !important;
  border: 1px solid rgba(0, 240, 255, 0.3) !important;
  border-radius: 3px !important;
  color: #00f0ff !important;
  text-shadow: 0 0 5px rgba(0, 240, 255, 0.4) !important;
  transition: all 0.2s !important;
}

.pager a:hover {
  background: rgba(0, 240, 255, 0.15) !important;
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.3) !important;
}

.pager .current, .pager span.current {
  background: #ff006e !important;
  color: #0a0a12 !important;
  border-color: #ff006e !important;
  text-shadow: none !important;
  box-shadow: 0 0 15px rgba(255, 0, 110, 0.6) !important;
}

/* ---------- 评论区 ---------- */
#comments {
  background: rgba(15, 15, 25, 0.7) !important;
  border: 1px solid rgba(0, 240, 255, 0.2) !important;
  border-radius: 6px !important;
  padding: 20px !important;
  margin-top: 20px !important;
}

#comments h3, .commentTitle {
  color: #00f0ff !important;
  text-shadow: 0 0 8px rgba(0, 240, 255, 0.5) !important;
  border-bottom: 1px solid rgba(0, 240, 255, 0.3) !important;
  padding-bottom: 8px !important;
}

/* ---------- 页脚 ---------- */
#footer {
  text-align: center !important;
  padding: 30px 20px !important;
  margin-top: 40px !important;
  border-top: 1px solid rgba(0, 240, 255, 0.2) !important;
  color: #546e7a !important;
  font-size: 0.85em !important;
  letter-spacing: 1px !important;
}

#footer a {
  color: #ff006e !important;
}

/* ---------- 滚动条 ---------- */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: #0a0a12;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #00f0ff, #bd00ff);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #ff006e, #00f0ff);
}

/* ---------- 选中文字 ---------- */
::selection {
  background: rgba(255, 0, 110, 0.4) !important;
  color: #fff !important;
  text-shadow: 0 0 8px #ff006e !important;
}

/* ---------- 回到顶部按钮 ---------- */
#back-to-top, .back-to-top {
  background: rgba(0, 240, 255, 0.15) !important;
  border: 1px solid #00f0ff !important;
  color: #00f0ff !important;
  border-radius: 4px !important;
  box-shadow: 0 0 10px rgba(0, 240, 255, 0.3) !important;
}

/* ---------- 响应式微调 ---------- */
@media (max-width: 768px) {
  #blogTitle {
    font-size: 1.6em !important;
  }
  .day {
    padding: 15px !important;
  }
}
