
/* ===================================================================
   BASE & RESET STYLES (SHARED)
   =================================================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: inherit;
  text-decoration: none;
  transition: all 0.2s ease;
}

img, svg {
  vertical-align: middle;
}

.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===================================================================
   CRITICAL: NAVBAR NO SCROLLBAR (STRICT ENFORCEMENT)
   =================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  gap: 16px;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  flex-shrink: 0;
}

.logo-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 24px;
  color: #fff;
  box-shadow: 0 4px 14px rgba(0,0,0,0.3);
}

.logo-text {
  display: flex;
  flex-direction: column;
}

.brand-name {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.3px;
  line-height: 1.2;
}

.brand-sub {
  font-size: 11px;
  font-weight: 600;
  opacity: 0.75;
  letter-spacing: 0.5px;
}

.brand-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 6px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  margin-left: 4px;
}

/* STRICT NAVBAR: NO HORIZONTAL SCROLLBAR */
.main-nav {
  display: flex !important;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap !important;
  overflow: visible !important;
  overflow-x: visible !important;
  overflow-y: visible !important;
  white-space: normal !important;
  -webkit-overflow-scrolling: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.main-nav::-webkit-scrollbar {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
}

.nav-item {
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.25s ease;
  border: 1px solid transparent;
  text-decoration: none;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 13px;
}

.btn-lg {
  padding: 14px 28px;
  font-size: 16px;
}

.btn-block {
  width: 100%;
}

/* ===================================================================
   FOOTER STYLES (SHARED 4-SITE MUTUAL INTERLINKS)
   =================================================================== */
.site-footer {
  margin-top: auto;
  padding-top: 60px;
  padding-bottom: 30px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-top {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 48px;
  margin-bottom: 40px;
}

.footer-summary {
  font-size: 14px;
  line-height: 1.8;
  margin: 16px 0;
}

.footer-features-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.footer-features-tags .tag {
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 20px;
}

.interlink-header {
  margin-bottom: 16px;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.footer-title {
  font-size: 17px;
  font-weight: 800;
}

.interlink-notice {
  font-size: 12px;
  opacity: 0.7;
}

.interlinks-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.interlink-card {
  border-radius: 10px;
  padding: 14px;
  transition: all 0.25s ease;
}

.interlink-anchor {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.interlink-title {
  font-weight: 700;
  font-size: 14px;
}

.interlink-desc {
  font-size: 12px;
  opacity: 0.75;
  line-height: 1.4;
}

.interlink-domain {
  font-size: 11px;
  font-weight: 600;
  margin-top: 4px;
}

.current-tag {
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 4px;
}

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.seo-keywords-line {
  font-size: 13px;
  margin-bottom: 12px;
  line-height: 1.8;
  opacity: 0.85;
}

.copyright-bar {
  font-size: 12px;
  opacity: 0.6;
}

/* Responsive */
@media (max-width: 900px) {
  .footer-top {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .interlinks-grid {
    grid-template-columns: 1fr;
  }
}

/* ===================================================================
   THEME 4: GEEK DOCUMENTATION & TECHNICAL WIKI (nexitally.blog)
   =================================================================== */
body.theme-geek {
  background-color: #111827;
  color: #E5E7EB;
}

.site-header {
  background: rgba(17, 24, 39, 0.95);
  border-bottom: 1px solid rgba(245, 158, 11, 0.25);
}

.logo-icon {
  background: linear-gradient(135deg, #F59E0B, #10B981);
}

.brand-badge.badge-geek {
  background: rgba(245, 158, 11, 0.15);
  color: #F59E0B;
  border: 1px solid #F59E0B;
}

.nav-item {
  color: #9CA3AF;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

.nav-item:hover, .nav-item.active {
  color: #F59E0B;
  background: rgba(245, 158, 11, 0.1);
}

.btn-primary {
  background: #F59E0B;
  color: #111827;
  font-weight: 800;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.35);
}
.btn-primary:hover {
  background: #D97706;
  transform: translateY(-2px);
}

.btn-secondary {
  background: #1F2937;
  color: #E5E7EB;
  border: 1px solid #374151;
}

/* Documentation Layout */
.docs-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 36px;
  margin: 40px 0;
}

.docs-sidebar {
  background: #1F2937;
  border: 1px solid #374151;
  border-radius: 12px;
  padding: 20px;
  height: fit-content;
  position: sticky;
  top: 90px;
}

.docs-sidebar h4 {
  font-size: 13px;
  text-transform: uppercase;
  color: #F59E0B;
  letter-spacing: 0.5px;
  margin-bottom: 12px;
}

.docs-menu {
  list-style: none;
  font-size: 14px;
}
.docs-menu li a {
  display: block;
  padding: 8px 12px;
  border-radius: 6px;
  color: #9CA3AF;
  margin-bottom: 4px;
}
.docs-menu li a:hover, .docs-menu li a.active {
  color: #FFFFFF;
  background: #374151;
}

.docs-content {
  background: #1F2937;
  border: 1px solid #374151;
  border-radius: 12px;
  padding: 36px;
  line-height: 1.8;
}

.docs-content h1 {
  font-size: 32px;
  margin-bottom: 16px;
  color: #FFFFFF;
}

.docs-content h2 {
  font-size: 24px;
  margin: 32px 0 16px;
  color: #F59E0B;
  border-bottom: 1px solid #374151;
  padding-bottom: 8px;
}

.docs-content h3 {
  font-size: 18px;
  margin: 24px 0 12px;
  color: #10B981;
}

.code-block {
  background: #030712;
  border: 1px solid #374151;
  border-radius: 8px;
  padding: 18px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 13px;
  color: #A7F3D0;
  overflow-x: visible;
  white-space: pre-wrap;
  word-break: break-all;
  margin: 18px 0;
}

.callout {
  padding: 16px 20px;
  border-radius: 8px;
  margin: 20px 0;
  font-size: 14px;
}
.callout.tip {
  background: rgba(16, 185, 129, 0.1);
  border-left: 4px solid #10B981;
  color: #D1FAE5;
}
.callout.warning {
  background: rgba(245, 158, 11, 0.1);
  border-left: 4px solid #F59E0B;
  color: #FEF3C7;
}

.interlink-card {
  background: #1F2937;
  border: 1px solid #374151;
}
.interlink-card:hover {
  border-color: #F59E0B;
}
.interlink-title { color: #F9FAFB; }
.interlink-domain { color: #F59E0B; }
.current-tag { background: #F59E0B; color: #111827; font-weight: 800; }
.footer-features-tags .tag { background: rgba(245, 158, 11, 0.15); color: #FCD34D; }

@media (max-width: 900px) {
  .docs-layout { grid-template-columns: 1fr; }
  .docs-sidebar { position: static; }
}
