/* ============================================
   0x6rss Cyber Intelligence Theme Override
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;700&family=Inter:wght@300;400;600;700&display=swap');

/* --- Base --- */
body {
  background: #0a0a0f !important;
  color: #c8ccd0 !important;
  font-family: 'Inter', sans-serif !important;
}

::selection {
  background: #00ff4133;
  color: #fff;
}

/* --- Scrollbar --- */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #0a0a0f; }
::-webkit-scrollbar-thumb { background: #1a3a1a; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #00ff41; }

/* --- Navbar --- */
.navbar {
  background: rgba(5, 5, 10, 0.92) !important;
  border-bottom: 1px solid #00ff4122 !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

nav:hover {
  background: rgba(5, 5, 10, 0.98) !important;
}

.navbar-icon {
  color: #00ff41 !important;
}

.navbar-icon:hover {
  color: #00ff41 !important;
  text-shadow: 0 0 12px #00ff4188, 0 0 24px #00ff4144 !important;
}

.navbar-nav > li > a {
  color: #7a8a7a !important;
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 15px !important;
  font-weight: 600 !important;
  letter-spacing: 1px;
  text-transform: uppercase;
  transition: color 0.3s, text-shadow 0.3s;
}

.navbar-nav > li > a:hover,
.navbar-nav > li > a:focus {
  color: #00ff41 !important;
  text-shadow: 0 0 8px #00ff4166;
}

.navbar-default {
  border-color: transparent !important;
}

/* --- Background SVG layers --- */
.bgColor1 { stop-color: #00ff41 !important; }
.bgColor2 { stop-color: #ff3333 !important; }

/* --- Headings --- */
h1, h2, h3, h4, h5, h6 {
  font-family: 'JetBrains Mono', monospace !important;
  color: #e0e0e0 !important;
  text-decoration-color: #00ff4133 !important;
  border-bottom-color: #00ff4122 !important;
}

h1 a, h1 a:hover {
  color: #00ff41 !important;
  text-shadow: 0 0 20px #00ff4133;
}

h2 {
  color: #00ff41 !important;
  border-bottom: 1px solid #00ff4122 !important;
  padding-bottom: 0.3em;
}

h3 {
  color: #ff6b6b !important;
}

h4 {
  color: #e0c452 !important;
}

/* --- Post titles --- */
.post-title {
  color: #00ff41 !important;
  font-family: 'JetBrains Mono', monospace !important;
}

.post-title a {
  color: #00ff41 !important;
  transition: text-shadow 0.3s;
}

.post-title a:hover {
  text-shadow: 0 0 16px #00ff4155;
  text-decoration: none;
}

/* --- Links --- */
a {
  color: #00ff41 !important;
  transition: color 0.2s, text-shadow 0.2s;
}

a:hover, a:focus {
  color: #33ff6a !important;
  text-decoration: none !important;
  text-shadow: 0 0 6px #00ff4144;
}

/* --- Text --- */
p, li, td, th {
  color: #b8bcc0;
  line-height: 1.75;
  font-size: 15px;
}

em {
  color: #e0c452;
  font-style: italic;
}

/* --- Code blocks --- */
pre {
  background: #0d1117 !important;
  border: 1px solid #1a3a1a !important;
  border-left: 3px solid #00ff41 !important;
  border-radius: 6px !important;
  padding: 16px !important;
  margin: 1.5em 0 !important;
}

pre strong, pre code {
  background: transparent !important;
  color: #c9d1d9 !important;
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 13px !important;
  font-weight: 400 !important;
  text-shadow: none !important;
}

/* --- Avatar --- */
.avatar-image {
  border-color: #00ff41 !important;
  border-width: 2px !important;
  box-shadow: 0 0 20px #00ff4122, 0 0 40px #00ff4111;
  transition: box-shadow 0.3s;
}

.avatar-image:hover {
  box-shadow: 0 0 30px #00ff4144, 0 0 60px #00ff4122;
}

.avatar-description, #avatar-description-en {
  color: #7a8a7a !important;
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 12px !important;
}

/* --- Right pane --- */
.right-pane a {
  color: #7a8a7a !important;
  font-size: 13px;
}

.right-pane a:hover {
  color: #00ff41 !important;
}

.right-pane h4 {
  color: #00ff41 !important;
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 14px !important;
  letter-spacing: 1px;
  text-transform: uppercase;
}

/* --- Labels/Tags --- */
.label {
  font-family: 'JetBrains Mono', monospace !important;
  font-size: 12px !important;
  font-weight: 400 !important;
  letter-spacing: 0.5px;
  border-radius: 3px !important;
  padding: 4px 8px !important;
}

.label-default { background: #1a2a1a !important; color: #00ff41 !important; border: 1px solid #00ff4133; }
.label-primary { background: #1a1a2a !important; color: #6b9bff !important; border: 1px solid #6b9bff33; }
.label-success { background: #1a2a1a !important; color: #33ff6a !important; border: 1px solid #33ff6a33; }
.label-info    { background: #1a2a2a !important; color: #33ccff !important; border: 1px solid #33ccff33; }
.label-warning { background: #2a2a1a !important; color: #e0c452 !important; border: 1px solid #e0c45233; }
.label-danger  { background: #2a1a1a !important; color: #ff6b6b !important; border: 1px solid #ff6b6b33; }

/* --- Footer --- */
.page-footer {
  border-top: 1px solid #1a3a1a;
  padding-top: 2em;
}

.page-footer center div div a i,
.social-icons a i {
  color: #3a4a3a !important;
  text-shadow: none !important;
  transition: color 0.3s, text-shadow 0.3s;
}

.social-icons a i:hover,
.page-footer center div div a i:hover {
  color: #00ff41 !important;
  text-shadow: 0 0 12px #00ff4166 !important;
}

.social-icons {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
}

.social-icons a {
  display: inline-flex;
  align-items: center;
  margin: 0 !important;
}

.page-footer center div div a i:hover {
  color: #00ff41 !important;
  text-shadow: 0 0 12px #00ff4166;
}

/* --- Matrix text (index page) --- */
.matrix-text {
  font-family: 'JetBrains Mono', monospace !important;
  color: #00ff41 !important;
  font-size: 28px !important;
  text-shadow: 0 0 10px #00ff4144, 0 0 20px #00ff4122;
}

@keyframes blink-caret {
  from, to { border-color: transparent }
  50% { border-color: #00ff41; }
}

/* --- Blog list items --- */
.content-div a h1.post-title {
  transition: text-shadow 0.3s, color 0.3s;
}

.content-div a:hover h1.post-title {
  text-shadow: 0 0 20px #00ff4144;
}

/* --- Horizontal rules --- */
hr {
  border-color: #1a3a1a !important;
}

/* --- Pie chart text --- */
svg text {
  font-family: 'JetBrains Mono', monospace !important;
}

/* --- Blog images --- */
.blog-image {
  border: 1px solid #1a2a1a;
  border-radius: 4px;
}

/* --- Blockquote --- */
blockquote {
  border-color: #00ff41 !important;
  background: #0d1117;
  padding: 1em 1.5em;
  border-radius: 0 4px 4px 0;
}

/* --- Table --- */
.table-hover > tbody > tr:hover {
  background-color: #0d1a0d !important;
}

.table > thead > tr > th {
  border-bottom-color: #1a3a1a !important;
  color: #00ff41;
}

.table > tbody > tr > td {
  border-top-color: #111a11 !important;
}

/* --- 0x6rss brand glow on h1 --- */
.page-title a[href="#title"] {
  position: relative;
}

/* --- h1-strip fix --- */
.h1-strip {
  padding-bottom: 2em !important;
  background: transparent !important;
  border: none !important;
}

/* --- Light/Dark toggle --- */
[id="css-theme"][href*="light"] ~ * body,
body {
  transition: background 0.3s, color 0.3s;
}

/* --- Subtle scan line effect --- */
body::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 99998;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.03) 2px,
    rgba(0, 0, 0, 0.03) 4px
  );
}

/* ============================================
   Light Theme Variant
   ============================================ */
body.theme-light {
  background: #f0f2f0 !important;
  color: #1a1a1a !important;
}

body.theme-light::after {
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.015) 2px,
    rgba(0, 0, 0, 0.015) 4px
  );
}

body.theme-light ::selection {
  background: #00aa2a44;
  color: #000;
}

body.theme-light ::-webkit-scrollbar-track { background: #f0f2f0; }
body.theme-light ::-webkit-scrollbar-thumb { background: #a0c0a0; }
body.theme-light ::-webkit-scrollbar-thumb:hover { background: #00882a; }

/* Navbar */
body.theme-light .navbar {
  background: rgba(240, 242, 240, 0.92) !important;
  border-bottom: 1px solid #00882a33 !important;
}

body.theme-light nav:hover {
  background: rgba(240, 242, 240, 0.98) !important;
}

body.theme-light .navbar-icon {
  color: #00882a !important;
}

body.theme-light .navbar-icon:hover {
  color: #00aa2a !important;
  text-shadow: 0 0 12px #00882a44 !important;
}

body.theme-light .navbar-nav > li > a {
  color: #4a5a4a !important;
}

body.theme-light .navbar-nav > li > a:hover,
body.theme-light .navbar-nav > li > a:focus {
  color: #00882a !important;
  text-shadow: 0 0 8px #00882a33;
}

/* Headings */
body.theme-light h1, body.theme-light h2, body.theme-light h3,
body.theme-light h4, body.theme-light h5, body.theme-light h6 {
  color: #1a2a1a !important;
}

body.theme-light h1 a, body.theme-light h1 a:hover {
  color: #00882a !important;
  text-shadow: none;
}

body.theme-light h2 {
  color: #00772a !important;
  border-bottom: 1px solid #00882a22 !important;
}

body.theme-light h3 {
  color: #8b3a3a !important;
}

body.theme-light h4 {
  color: #8a7a22 !important;
}

/* Post title */
body.theme-light .post-title {
  color: #00882a !important;
}

body.theme-light .post-title a {
  color: #00882a !important;
}

/* Text */
body.theme-light p, body.theme-light li, body.theme-light td, body.theme-light th {
  color: #2a2a2a;
}

body.theme-light em {
  color: #8a7a22;
}

/* Links */
body.theme-light a {
  color: #00772a !important;
}

body.theme-light a:hover, body.theme-light a:focus {
  color: #00aa2a !important;
  text-shadow: none;
}

/* Code */
body.theme-light pre {
  background: #e8ece8 !important;
  border: 1px solid #c0d0c0 !important;
  border-left: 3px solid #00882a !important;
}

body.theme-light pre strong, body.theme-light pre code {
  color: #1a2a1a !important;
  background: transparent !important;
}

/* Avatar */
body.theme-light .avatar-image {
  border-color: #00882a !important;
  box-shadow: 0 0 15px #00882a11;
}

body.theme-light .avatar-description, body.theme-light #avatar-description-en {
  color: #5a6a5a !important;
}

/* Right pane */
body.theme-light .right-pane a {
  color: #4a5a4a !important;
}

body.theme-light .right-pane a:hover {
  color: #00882a !important;
}

body.theme-light .right-pane h4 {
  color: #00882a !important;
}

/* Labels */
body.theme-light .label-default { background: #dce8dc !important; color: #00772a !important; border: 1px solid #00882a33; }
body.theme-light .label-primary { background: #dce0ec !important; color: #3a5aaa !important; border: 1px solid #3a5aaa33; }
body.theme-light .label-success { background: #dcecdc !important; color: #00882a !important; border: 1px solid #00882a33; }
body.theme-light .label-info    { background: #dcecec !important; color: #2288aa !important; border: 1px solid #2288aa33; }
body.theme-light .label-warning { background: #ecead8 !important; color: #8a7a22 !important; border: 1px solid #8a7a2233; }
body.theme-light .label-danger  { background: #ecdcdc !important; color: #aa3a3a !important; border: 1px solid #aa3a3a33; }

/* Footer */
body.theme-light .page-footer {
  border-top: 1px solid #c0d0c0;
}

body.theme-light .page-footer center div div a i {
  color: #8a9a8a !important;
}

body.theme-light .page-footer center div div a i:hover {
  color: #00882a !important;
  text-shadow: 0 0 8px #00882a44;
}

/* Matrix text */
body.theme-light .matrix-text {
  color: #00882a !important;
  text-shadow: none;
}

/* Blog images */
body.theme-light .blog-image {
  border: 1px solid #c0d0c0;
}

/* HR */
body.theme-light hr {
  border-color: #c0d0c0 !important;
}

/* Blockquote */
body.theme-light blockquote {
  border-color: #00882a !important;
  background: #e8ece8;
}

/* Table */
body.theme-light .table-hover > tbody > tr:hover {
  background-color: #e0ece0 !important;
}

/* Social icons X logo for light */
body.theme-light .social-icons img[alt="X"] {
  filter: invert(0.15) !important;
}

/* Background layers */
body.theme-light .bgColor1 { stop-color: #00882a !important; }
body.theme-light .bgColor2 { stop-color: #8b3a3a !important; }
