:root {
  --sidebar-width: 260px;
}

.main-wrapper {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 24px 60px;
  display: flex;
  gap: 48px;
  position: relative;
}

.sidebar {
  width: var(--sidebar-width);
  flex-shrink: 0;
  position: sticky;
  top: 80px;
  height: fit-content;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  display: none;
}

@media (min-width: 1024px) {
  .sidebar { display: block; }
}

.sidebar::-webkit-scrollbar { width: 3px; }
.sidebar::-webkit-scrollbar-thumb { background: var(--border); border-radius: 10px; }

.content { flex: 1; min-width: 0; max-width: 800px; }

/* --- TOC Navigation --- */
.toc-sticky { padding: 20px 0; }

.toc-title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  font-weight: 700;
  margin-bottom: 20px;
  opacity: 0.6;
}

.toc-list {
  list-style: none;
  border-left: 2px solid var(--border);
}

.toc-item a {
  display: block;
  padding: 7px 0 7px 20px;
  font-size: 13.5px;
  font-weight: 450;
  color: var(--text-muted);
  margin-left: -2px;
  border-left: 2px solid transparent;
  transition: all 0.25s ease;
  text-decoration: none;
  line-height: 1.5;
}

.toc-item a:hover { color: var(--primary); border-left-color: rgba(59, 130, 246, 0.3); }
.toc-item a.active { color: var(--primary); border-left-color: var(--primary); font-weight: 600; }

/* --- Page Header --- */
.page-header {
  margin-bottom: 48px;
}

.page-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--primary);
  margin-bottom: 12px;
}

.page-label::before {
  content: '';
  width: 20px;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
}

.page-title {
  font-family: 'Outfit', sans-serif;
  font-size: 2.0rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--primary) !important;
  margin-bottom: 12px;
  line-height: 1.2;
}

.page-desc {
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 640px;
}

/* --- Section Blocks --- */
.section-block {
  margin-bottom: 40px;
  scroll-margin-top: 100px;
}

.section-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.3;
  margin-bottom: 16px;
}

.section-content {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.8;
}

.section-content p { margin-bottom: 20px; }
.section-content p:last-child { margin-bottom: 0; }

.section-content h3 {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-main);
  margin-top: 24px;
  margin-bottom: 10px;
}

/* --- Info Cards --- */
.info-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  padding: 20px 24px;
  border-radius: 10px;
  margin: 20px 0;
}

.info-card.highlight {
  border-left: 3px solid var(--primary);
  background: rgba(59, 130, 246, 0.04);
}

.dark-mode .info-card.highlight { background: rgba(59, 130, 246, 0.06); }

.info-card.warning {
  border-left: 3px solid #ef4444;
  background: rgba(239, 68, 68, 0.04);
}

.dark-mode .info-card.warning { background: rgba(239, 68, 68, 0.08); }

.info-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.7;
  margin-bottom: 6px !important;
}

.info-card p:last-child { margin-bottom: 0 !important; }
.info-card a { color: var(--primary); }
.info-card a:hover { text-decoration: underline; }

/* --- Last Updated --- */
.last-updated {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  color: var(--text-muted);
  opacity: 0.7;
}

/* --- Responsive --- */
@media (max-width: 1024px) {
  .main-wrapper { flex-direction: column; gap: 0; padding: 24px 16px 40px; }
  .content { width: 100%; max-width: 100%; }
  .sidebar { display: none; }
  .page-title { font-size: 2.0rem !important; }
  .section-header { gap: 12px; }
  .section-icon { width: 34px; height: 34px; font-size: 0.85rem; }
  .section-title { font-size: 1.15rem; }
}

@media (max-width: 480px) {
  .page-title { font-size: 2.0rem !important; }
}
