/* =============================================
   HELP CENTER DESIGN SYSTEM
   Inspired by Stripe, Linear, Notion
   Turrell-Murch-Kidd Design Principles Applied
   ============================================= */

:root {
  /* Colors - Light & Airy with Cyan Accents */
  --hc-bg: #ffffff;
  --hc-bg-subtle: #f8fafc;
  --hc-bg-muted: #f1f5f9;
  --hc-border: #e2e8f0;
  --hc-border-hover: #cbd5e1;

  --hc-text: #0f172a;
  --hc-text-secondary: #475569;
  --hc-text-muted: #94a3b8;

  --hc-accent: #0891b2;
  --hc-accent-hover: #0e7490;
  --hc-accent-subtle: #ecfeff;
  --hc-accent-muted: #cffafe;

  --hc-success: #059669;
  --hc-warning: #d97706;
  --hc-error: #dc2626;

  /* Typography */
  --hc-font: 'Inter', system-ui, -apple-system, sans-serif;
  --hc-font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  /* Spacing */
  --hc-space-xs: 0.25rem;
  --hc-space-sm: 0.5rem;
  --hc-space-md: 1rem;
  --hc-space-lg: 1.5rem;
  --hc-space-xl: 2rem;
  --hc-space-2xl: 3rem;

  /* Shadows */
  --hc-shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --hc-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
  --hc-shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --hc-shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);

  /* Transitions */
  --hc-transition: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --hc-transition-slow: 300ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== BASE STYLES ===== */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--hc-font);
  background: var(--hc-bg);
  color: var(--hc-text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

:focus-visible {
  outline: 2px solid var(--hc-accent);
  outline-offset: 2px;
}

/* ===== LAYOUT ===== */
.hc-container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--hc-space-lg);
}

.hc-container-narrow {
  max-width: 900px;
}

/* ===== HEADER ===== */
.hc-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--hc-border);
}

.hc-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  gap: var(--hc-space-lg);
}

.hc-logo {
  display: flex;
  align-items: center;
  gap: var(--hc-space-sm);
  text-decoration: none;
  color: var(--hc-text);
  font-weight: 600;
}

.hc-logo img {
  height: 26px;
  width: auto;
}

@media (min-width: 640px) {
  .hc-logo img {
    height: 32px;
  }
}

.hc-logo-divider {
  width: 1px;
  height: 24px;
  background: var(--hc-border);
  margin: 0 var(--hc-space-sm);
  display: none;
}

.hc-logo-text {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--hc-text-secondary);
  display: none;
}

@media (min-width: 480px) {
  .hc-logo-divider,
  .hc-logo-text {
    display: block;
  }
}

/* ===== SEARCH BAR ===== */
.hc-search {
  flex: 1;
  max-width: 480px;
}

.hc-search-trigger {
  display: flex;
  align-items: center;
  gap: var(--hc-space-sm);
  width: 100%;
  padding: var(--hc-space-sm) var(--hc-space-md);
  background: var(--hc-bg-subtle);
  border: 1px solid var(--hc-border);
  border-radius: 8px;
  color: var(--hc-text-muted);
  font-size: 0.875rem;
  cursor: pointer;
  transition: all var(--hc-transition);
}

.hc-search-trigger:hover {
  border-color: var(--hc-border-hover);
  background: var(--hc-bg);
}

.hc-search-trigger:focus {
  outline: none;
  border-color: var(--hc-accent);
  box-shadow: 0 0 0 3px var(--hc-accent-subtle);
}

.hc-search-icon {
  width: 16px;
  height: 16px;
  opacity: 0.5;
}

.hc-search-placeholder {
  flex: 1;
  text-align: left;
}

.hc-search-shortcut {
  display: flex;
  align-items: center;
  gap: 2px;
  font-size: 0.75rem;
  color: var(--hc-text-muted);
  background: var(--hc-bg);
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid var(--hc-border);
}

/* ===== NAVIGATION (DESKTOP) ===== */
.hc-nav {
  display: flex;
  align-items: center;
  gap: var(--hc-space-md);
}

.hc-nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--hc-text-secondary);
  text-decoration: none;
  padding: var(--hc-space-sm) var(--hc-space-md);
  border-radius: 6px;
  transition: all var(--hc-transition);
  white-space: nowrap;
}

.hc-nav-link:hover {
  color: var(--hc-text);
  background: var(--hc-bg-subtle);
}

.hc-nav-cta {
  background: var(--hc-accent);
  color: white;
  font-weight: 600;
}

.hc-nav-cta:hover {
  background: var(--hc-accent-hover);
  color: white;
}

/* ===== MOBILE HEADER SYSTEM ===== */
.hc-mobile-actions {
  display: none;
  align-items: center;
  gap: var(--hc-space-xs);
}

.hc-mobile-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: none;
  background: transparent;
  color: var(--hc-text-secondary);
  border-radius: 10px;
  cursor: pointer;
  transition: all var(--hc-transition);
  -webkit-tap-highlight-color: transparent;
}

.hc-mobile-btn:hover {
  background: var(--hc-bg-muted);
  color: var(--hc-text);
}

.hc-mobile-btn:active {
  transform: scale(0.92);
}

.hc-hamburger .hc-hamburger-close {
  display: none;
}

.hc-hamburger[aria-expanded="true"] .hc-hamburger-open {
  display: none;
}

.hc-hamburger[aria-expanded="true"] .hc-hamburger-close {
  display: block;
}

/* Mobile Drawer */
.hc-mobile-menu {
  display: none;
  border-top: 1px solid var(--hc-border);
  background: var(--hc-bg);
  overflow: hidden;
}

.hc-mobile-menu.open {
  display: block;
  animation: hcDrawerSlide 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes hcDrawerSlide {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hc-mobile-search-row {
  padding: var(--hc-space-md) 0;
}

.hc-mobile-search-bar {
  display: flex;
  align-items: center;
  gap: var(--hc-space-sm);
  width: 100%;
  padding: 12px var(--hc-space-md);
  background: var(--hc-bg-subtle);
  border: 1px solid var(--hc-border);
  border-radius: 10px;
  color: var(--hc-text-muted);
  font-size: 0.9375rem;
  font-family: var(--hc-font);
  cursor: pointer;
  transition: all var(--hc-transition);
  -webkit-tap-highlight-color: transparent;
}

.hc-mobile-search-bar:hover {
  border-color: var(--hc-border-hover);
}

.hc-mobile-search-bar:active {
  border-color: var(--hc-accent);
  background: var(--hc-bg);
}

.hc-mobile-nav-links {
  display: flex;
  flex-direction: column;
  gap: var(--hc-space-xs);
  padding-bottom: var(--hc-space-lg);
}

.hc-mobile-nav-link {
  display: flex;
  align-items: center;
  gap: var(--hc-space-md);
  padding: 12px var(--hc-space-md);
  border-radius: 10px;
  text-decoration: none;
  color: var(--hc-text-secondary);
  font-size: 0.9375rem;
  font-weight: 500;
  transition: all var(--hc-transition);
  -webkit-tap-highlight-color: transparent;
}

.hc-mobile-nav-link:hover,
.hc-mobile-nav-link:active {
  background: var(--hc-bg-subtle);
  color: var(--hc-text);
}

.hc-mobile-nav-cta {
  color: var(--hc-accent);
  font-weight: 600;
}

.hc-mobile-nav-cta:hover,
.hc-mobile-nav-cta:active {
  color: var(--hc-accent-hover);
}

/* Desktop/Mobile visibility toggles */
@media (max-width: 768px) {
  .hc-desktop-only {
    display: none !important;
  }

  .hc-mobile-actions {
    display: flex;
  }

  .hc-header-inner {
    height: 56px;
  }
}

@media (min-width: 769px) {
  .hc-mobile-actions {
    display: none;
  }

  .hc-mobile-menu {
    display: none !important;
  }
}

/* ===== HERO SECTION ===== */
.hc-hero {
  background: linear-gradient(180deg, var(--hc-accent-subtle) 0%, var(--hc-bg) 100%);
  padding: var(--hc-space-2xl) 0;
  text-align: center;
}

.hc-hero h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin: 0 0 var(--hc-space-md);
  background: linear-gradient(135deg, var(--hc-text) 0%, var(--hc-accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hc-hero p {
  font-size: 1.125rem;
  color: var(--hc-text-secondary);
  margin: 0 0 var(--hc-space-xl);
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ===== SEARCH HERO ===== */
.hc-search-hero {
  max-width: 640px;
  margin: 0 auto;
}

.hc-search-input-wrap {
  position: relative;
}

.hc-search-input {
  width: 100%;
  padding: var(--hc-space-md) var(--hc-space-lg);
  padding-left: 48px;
  font-size: 1rem;
  border: 2px solid var(--hc-border);
  border-radius: 12px;
  background: var(--hc-bg);
  color: var(--hc-text);
  transition: all var(--hc-transition);
  box-shadow: var(--hc-shadow-md);
}

.hc-search-input:focus {
  outline: none;
  border-color: var(--hc-accent);
  box-shadow: var(--hc-shadow-lg), 0 0 0 4px var(--hc-accent-subtle);
}

.hc-search-input::placeholder {
  color: var(--hc-text-muted);
}

.hc-search-input-icon {
  position: absolute;
  left: var(--hc-space-md);
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  color: var(--hc-text-muted);
}

/* ===== CATEGORY CARDS ===== */
.hc-categories {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: var(--hc-space-lg);
  padding: var(--hc-space-2xl) 0;
}

.hc-category-card {
  display: block;
  padding: var(--hc-space-lg);
  background: var(--hc-bg);
  border: 1px solid var(--hc-border);
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  transition: all var(--hc-transition);
}

.hc-category-card:hover {
  border-color: var(--hc-accent);
  box-shadow: var(--hc-shadow-md);
  transform: translateY(-2px);
}

.hc-category-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--hc-accent-subtle);
  border-radius: 10px;
  margin-bottom: var(--hc-space-md);
  font-size: 1.5rem;
}

.hc-category-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0 0 var(--hc-space-xs);
  color: var(--hc-text);
}

.hc-category-desc {
  font-size: 0.875rem;
  color: var(--hc-text-secondary);
  margin: 0 0 var(--hc-space-md);
}

.hc-category-count {
  font-size: 0.75rem;
  color: var(--hc-text-muted);
}

/* ===== ARTICLE LIST ===== */
.hc-article-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.hc-article-item {
  border-bottom: 1px solid var(--hc-border);
}

.hc-article-link {
  display: flex;
  align-items: center;
  gap: var(--hc-space-md);
  padding: var(--hc-space-md) 0;
  text-decoration: none;
  color: inherit;
  transition: all var(--hc-transition);
}

.hc-article-link:hover {
  color: var(--hc-accent);
}

.hc-article-link:hover .hc-article-arrow {
  transform: translateX(4px);
  opacity: 1;
}

.hc-article-icon {
  width: 20px;
  height: 20px;
  color: var(--hc-text-muted);
  flex-shrink: 0;
}

.hc-article-content {
  flex: 1;
  min-width: 0;
}

.hc-article-title {
  font-weight: 500;
  margin: 0 0 2px;
}

.hc-article-meta {
  font-size: 0.75rem;
  color: var(--hc-text-muted);
  display: flex;
  align-items: center;
  gap: var(--hc-space-sm);
}

.hc-article-arrow {
  width: 16px;
  height: 16px;
  color: var(--hc-accent);
  flex-shrink: 0;
  opacity: 0;
  transform: translateX(0);
  transition: all var(--hc-transition);
}

/* ===== PROSE (ARTICLE CONTENT) ===== */
.hc-prose {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--hc-text);
  max-width: 65ch;
}

.hc-prose h1 {
  font-size: 2rem;
  font-weight: 700;
  margin: var(--hc-space-2xl) 0 var(--hc-space-lg);
  line-height: 1.25;
}

.hc-prose h2 {
  font-size: 1.5rem;
  font-weight: 600;
  margin: var(--hc-space-2xl) 0 var(--hc-space-md);
  padding-bottom: var(--hc-space-sm);
  border-bottom: 1px solid var(--hc-border);
}

.hc-prose h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin: var(--hc-space-xl) 0 var(--hc-space-sm);
}

.hc-prose h4 {
  font-size: 1rem;
  font-weight: 600;
  margin: var(--hc-space-lg) 0 var(--hc-space-sm);
}

.hc-prose h1, .hc-prose h2, .hc-prose h3, .hc-prose h4, .hc-prose h5, .hc-prose h6 {
  position: relative;
}

.hc-prose .anchor-link {
  opacity: 0;
  font-size: 0.75em;
  font-weight: 400;
  color: var(--hc-text-muted);
  text-decoration: none;
  transition: opacity 150ms ease;
  margin-left: 0.5em;
}

.hc-prose h1:hover .anchor-link,
.hc-prose h2:hover .anchor-link,
.hc-prose h3:hover .anchor-link,
.hc-prose h4:hover .anchor-link,
.hc-prose h5:hover .anchor-link,
.hc-prose h6:hover .anchor-link {
  opacity: 0.5;
}

.hc-prose .anchor-link:hover {
  opacity: 1 !important;
  color: var(--hc-accent);
}

.hc-prose p {
  margin: var(--hc-space-md) 0;
}

.hc-prose a {
  color: var(--hc-accent);
  text-decoration: none;
}

.hc-prose a:hover {
  text-decoration: underline;
}

.hc-prose strong {
  font-weight: 600;
}

.hc-prose ul, .hc-prose ol {
  margin: var(--hc-space-md) 0;
  padding-left: var(--hc-space-xl);
}

.hc-prose li {
  margin: var(--hc-space-sm) 0;
}

.hc-prose code {
  font-family: var(--hc-font-mono);
  font-size: 0.875em;
  background: var(--hc-bg-muted);
  padding: 2px 6px;
  border-radius: 4px;
  color: #e11d48;
}

.hc-prose pre {
  background: #1e293b;
  color: #e2e8f0;
  padding: var(--hc-space-lg);
  border-radius: 8px;
  overflow-x: auto;
  margin: var(--hc-space-lg) 0;
}

.hc-prose pre code {
  background: none;
  padding: 0;
  color: inherit;
  font-size: 0.875rem;
}

.hc-prose blockquote {
  border-left: 4px solid var(--hc-accent);
  margin: var(--hc-space-lg) 0;
  padding: var(--hc-space-md) var(--hc-space-lg);
  background: var(--hc-accent-subtle);
  border-radius: 0 8px 8px 0;
  color: var(--hc-text-secondary);
}

.hc-prose table {
  width: 100%;
  border-collapse: collapse;
  margin: var(--hc-space-lg) 0;
  font-size: 0.875rem;
}

.hc-prose th, .hc-prose td {
  border: 1px solid var(--hc-border);
  padding: var(--hc-space-sm) var(--hc-space-md);
  text-align: left;
}

.hc-prose th {
  background: var(--hc-bg-subtle);
  font-weight: 600;
}

.hc-prose img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  margin: var(--hc-space-lg) 0;
}

.hc-prose hr {
  border: none;
  border-top: 1px solid var(--hc-border);
  margin: var(--hc-space-2xl) 0;
}

/* ===== HEADING ANCHORS ===== */
.docs-heading {
  position: relative;
  scroll-margin-top: 80px;
}

.docs-heading-anchor {
  color: var(--hc-text-muted);
  text-decoration: none;
  font-weight: 400;
}

.docs-heading-anchor:hover {
  color: var(--hc-accent);
}

/* ===== TOC (Table of Contents) ===== */
.hc-toc {
  position: sticky;
  top: 80px;
}

.hc-toc-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--hc-text-muted);
  margin: 0 0 var(--hc-space-md);
}

.hc-toc-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.hc-toc-link {
  display: block;
  padding: var(--hc-space-xs) 0;
  padding-left: var(--hc-space-md);
  font-size: 0.875rem;
  color: var(--hc-text-secondary);
  text-decoration: none;
  border-left: 2px solid transparent;
  transition: all var(--hc-transition);
}

.hc-toc-link:hover {
  color: var(--hc-accent);
}

.hc-toc-link.active {
  color: var(--hc-accent);
  border-left-color: var(--hc-accent);
  font-weight: 500;
}

.hc-toc-link[data-level="3"] {
  padding-left: calc(var(--hc-space-md) + var(--hc-space-md));
  font-size: 0.8125rem;
}

/* ===== SIDEBAR ===== */
.hc-sidebar {
  width: 280px;
  flex-shrink: 0;
}

.hc-sidebar-section {
  margin-bottom: var(--hc-space-xl);
}

.hc-sidebar-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--hc-text-muted);
  margin: 0 0 var(--hc-space-sm);
}

/* ===== FEEDBACK ===== */
.hc-feedback {
  padding: var(--hc-space-xl);
  background: var(--hc-bg-subtle);
  border-radius: 12px;
  text-align: center;
  margin-top: var(--hc-space-2xl);
}

.hc-feedback-title {
  font-weight: 600;
  margin: 0 0 var(--hc-space-md);
}

.hc-feedback-buttons {
  display: flex;
  justify-content: center;
  gap: var(--hc-space-md);
}

.hc-feedback-btn {
  display: flex;
  align-items: center;
  gap: var(--hc-space-sm);
  padding: var(--hc-space-sm) var(--hc-space-lg);
  border: 1px solid var(--hc-border);
  border-radius: 8px;
  background: var(--hc-bg);
  color: var(--hc-text-secondary);
  font-size: 0.875rem;
  cursor: pointer;
  transition: all var(--hc-transition);
}

.hc-feedback-btn:hover {
  border-color: var(--hc-accent);
  color: var(--hc-accent);
}

/* ===== BREADCRUMBS ===== */
.hc-breadcrumbs {
  display: flex;
  align-items: center;
  gap: var(--hc-space-sm);
  font-size: 0.875rem;
  color: var(--hc-text-muted);
  margin-bottom: var(--hc-space-lg);
}

.hc-breadcrumbs a {
  color: var(--hc-text-secondary);
  text-decoration: none;
}

.hc-breadcrumbs a:hover {
  color: var(--hc-accent);
}

.hc-breadcrumbs-sep {
  color: var(--hc-border-hover);
}

/* ===== TAGS ===== */
.hc-tag {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  font-size: 0.75rem;
  font-weight: 500;
  background: var(--hc-bg-muted);
  color: var(--hc-text-secondary);
  border-radius: 4px;
}

.hc-tag-beginner { background: #dcfce7; color: #166534; }
.hc-tag-intermediate { background: #fef3c7; color: #92400e; }
.hc-tag-advanced { background: #fce7f3; color: #9d174d; }

/* ===== PREV/NEXT NAVIGATION ===== */
.hc-nav-footer {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--hc-space-lg);
  margin-top: var(--hc-space-2xl);
  padding-top: var(--hc-space-xl);
  border-top: 1px solid var(--hc-border);
}

.hc-nav-link-footer {
  display: block;
  padding: var(--hc-space-lg);
  background: var(--hc-bg-subtle);
  border: 1px solid var(--hc-border);
  border-radius: 12px;
  text-decoration: none;
  transition: all var(--hc-transition);
}

.hc-nav-link-footer:hover {
  border-color: var(--hc-accent);
  box-shadow: var(--hc-shadow);
}

.hc-nav-link-label {
  font-size: 0.75rem;
  color: var(--hc-text-muted);
  margin-bottom: var(--hc-space-xs);
}

.hc-nav-link-title {
  font-weight: 600;
  color: var(--hc-text);
}

.hc-nav-link-footer.next {
  text-align: right;
}

/* ===== COMMAND PALETTE ===== */
.hc-command-palette {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
}

.hc-command-palette.open {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 12vh var(--hc-space-md) var(--hc-space-md);
}

.hc-command-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
}

.hc-command-modal {
  position: relative;
  width: 100%;
  max-width: 640px;
  background: var(--hc-bg);
  border-radius: 16px;
  box-shadow: var(--hc-shadow-lg), 0 0 0 1px rgba(0,0,0,0.05);
  overflow: hidden;
  animation: commandSlideIn 200ms ease-out;
}

@keyframes commandSlideIn {
  from {
    opacity: 0;
    transform: scale(0.96) translateY(-10px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.hc-command-input-wrap {
  display: flex;
  align-items: center;
  padding: var(--hc-space-md) var(--hc-space-lg);
  border-bottom: 1px solid var(--hc-border);
}

.hc-command-input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 1rem;
  background: transparent;
  color: var(--hc-text);
}

.hc-command-results {
  max-height: 400px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.hc-command-result {
  display: flex;
  align-items: center;
  gap: var(--hc-space-md);
  padding: var(--hc-space-md) var(--hc-space-lg);
  cursor: pointer;
  transition: background var(--hc-transition);
  text-decoration: none;
  color: inherit;
}

.hc-command-result:hover,
.hc-command-result.active {
  background: var(--hc-bg-subtle);
}

.hc-command-result-icon {
  width: 24px;
  height: 24px;
  color: var(--hc-text-muted);
  flex-shrink: 0;
}

.hc-command-result-content {
  flex: 1;
  min-width: 0;
}

.hc-command-result-title {
  font-weight: 500;
}

.hc-command-result-desc {
  font-size: 0.75rem;
  color: var(--hc-text-muted);
}

/* Command palette — mobile full-screen takeover */
@media (max-width: 640px) {
  .hc-command-palette.open {
    padding: 0;
    align-items: stretch;
  }

  .hc-command-modal {
    max-width: none;
    border-radius: 0;
    min-height: 100dvh;
    animation: commandSlideUp 250ms cubic-bezier(0.4, 0, 0.2, 1);
  }

  @keyframes commandSlideUp {
    from {
      opacity: 0;
      transform: translateY(20px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }

  .hc-command-input-wrap {
    padding: var(--hc-space-md);
  }

  .hc-command-input {
    font-size: 1.0625rem;
  }

  .hc-command-results {
    max-height: calc(100dvh - 64px);
  }

  .hc-command-result {
    padding: 14px var(--hc-space-md);
    min-height: 56px;
  }
}

/* ===== FOOTER ===== */
.hc-footer {
  margin-top: var(--hc-space-2xl);
  padding: var(--hc-space-xl) 0;
  border-top: 1px solid var(--hc-border);
  background: var(--hc-bg-subtle);
}

.hc-footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.875rem;
  color: var(--hc-text-muted);
  text-align: center;
}

@media (min-width: 640px) {
  .hc-footer-inner {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
    gap: 0;
  }
}

.hc-footer a {
  color: var(--hc-text-secondary);
  text-decoration: none;
  padding: 4px 2px;
  transition: color var(--hc-transition);
}

.hc-footer a:hover {
  color: var(--hc-accent);
}

@media (max-width: 480px) {
  .hc-footer {
    padding: var(--hc-space-lg) 0;
  }

  .hc-footer-inner {
    font-size: 0.8125rem;
    gap: var(--hc-space-sm);
  }
}

/* ===== BADGES ===== */
.hc-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  font-size: 0.6875rem;
  font-weight: 600;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.hc-badge-new {
  background: var(--hc-accent-muted);
  color: var(--hc-accent);
}

.hc-badge-popular {
  background: #fef3c7;
  color: #92400e;
}

/* ===== SKIP LINK ===== */
.hc-skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  z-index: 9999;
  padding: 8px 16px;
  background: var(--hc-accent);
  color: white;
  border-radius: 8px;
  text-decoration: none;
  transition: top 150ms ease;
}
.hc-skip-link:focus {
  top: 16px;
  position: fixed;
}

/* ===== UTILITIES ===== */
.hc-visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .hc-hero h1 {
    font-size: 1.75rem;
  }

  .hc-categories {
    grid-template-columns: 1fr;
  }

  .hc-nav-footer {
    grid-template-columns: 1fr;
  }
}

/* ===== ANIMATIONS ===== */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-fade-in {
  animation: fadeIn 300ms ease-out;
}

.animate-slide-up {
  animation: slideUp 400ms ease-out;
}

.animate-stagger > * {
  animation: slideUp 400ms ease-out both;
}

.animate-stagger > *:nth-child(1) { animation-delay: 0ms; }
.animate-stagger > *:nth-child(2) { animation-delay: 50ms; }
.animate-stagger > *:nth-child(3) { animation-delay: 100ms; }
.animate-stagger > *:nth-child(4) { animation-delay: 150ms; }
.animate-stagger > *:nth-child(5) { animation-delay: 200ms; }
.animate-stagger > *:nth-child(6) { animation-delay: 250ms; }

/* ===== BACK TO TOP BUTTON ===== */
.hc-back-to-top {
  position: fixed;
  bottom: var(--hc-space-xl);
  right: var(--hc-space-xl);
  width: 44px;
  height: 44px;
  background: var(--hc-bg);
  border: 1px solid var(--hc-border);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: all var(--hc-transition);
  box-shadow: var(--hc-shadow-md);
  z-index: 100;
}

.hc-back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.hc-back-to-top:hover {
  background: var(--hc-accent);
  border-color: var(--hc-accent);
  transform: translateY(-2px);
}

.hc-back-to-top:hover svg {
  stroke: white;
}

.hc-back-to-top svg {
  width: 20px;
  height: 20px;
  stroke: var(--hc-text-secondary);
  transition: stroke var(--hc-transition);
}

/* ===== CODE BLOCK COPY BUTTON ===== */
.hc-prose pre {
  position: relative;
}

.hc-code-copy {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 6px 10px;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--hc-text-muted);
  background: var(--hc-bg-muted);
  border: 1px solid var(--hc-border);
  border-radius: 6px;
  cursor: pointer;
  opacity: 0;
  transition: all var(--hc-transition);
}

.hc-prose pre:hover .hc-code-copy {
  opacity: 1;
}

.hc-code-copy:hover {
  color: var(--hc-text);
  background: var(--hc-bg);
}

.hc-code-copy.copied {
  color: var(--hc-success);
  border-color: var(--hc-success);
}

/* ===== PRINT STYLES ===== */
@media print {
  .hc-header,
  .hc-footer,
  .hc-command-palette,
  .hc-back-to-top,
  .hc-feedback,
  .hc-nav-footer,
  .hc-code-copy,
  #reading-progress,
  #confetti-canvas {
    display: none !important;
  }

  body {
    background: white;
    color: black;
    font-size: 12pt;
    line-height: 1.5;
  }

  .hc-container {
    max-width: 100%;
    padding: 0;
  }

  .hc-prose {
    max-width: 100%;
  }

  .hc-prose h1, .hc-prose h2, .hc-prose h3 {
    page-break-after: avoid;
  }

  .hc-prose pre, .hc-prose code {
    background: #f5f5f5;
    border: 1px solid #ddd;
  }

  .hc-prose a {
    color: black;
    text-decoration: underline;
  }

  .hc-prose a[href^="http"]::after {
    content: " (" attr(href) ")";
    font-size: 0.8em;
    color: #666;
  }

  .hc-toc {
    position: static;
    border: 1px solid #ddd;
    padding: 16px;
    margin-bottom: 24px;
    page-break-inside: avoid;
  }
}

/* =============================================
   INDEX PAGE STYLES
   ============================================= */

.hc-main-content {
  padding-top: var(--hc-space-xl);
  padding-bottom: var(--hc-space-2xl);
}

.hc-section {
  margin-bottom: var(--hc-space-2xl);
}

.hc-section-header {
  margin-bottom: var(--hc-space-lg);
}

.hc-section-title {
  display: flex;
  align-items: center;
  font-size: 1.375rem;
  font-weight: 700;
  margin: 0;
  letter-spacing: -0.02em;
}

.hc-section-subtitle {
  font-size: 0.9375rem;
  color: var(--hc-text-secondary);
  margin: var(--hc-space-xs) 0 0;
}

/* Search Enhancements */
.hc-search-kbd {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  padding: 4px 8px;
  background: var(--hc-bg-subtle);
  border-radius: 4px;
  font-size: 0.75rem;
  font-family: system-ui;
  color: var(--hc-text-muted);
  pointer-events: none;
}

.hc-search-popular {
  font-size: 0.875rem;
  color: var(--hc-text-muted);
  margin-top: var(--hc-space-md);
}

.hc-search-popular a {
  color: var(--hc-accent);
  text-decoration: none;
}

.hc-search-popular a:hover {
  text-decoration: underline;
}

.hc-search-popular .dot {
  margin: 0 var(--hc-space-sm);
  opacity: 0.5;
}

/* Quick Start Banner */
.hc-quickstart-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--hc-space-lg);
  padding: var(--hc-space-lg) var(--hc-space-xl);
  background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 50%, #a7f3d0 100%);
  border-radius: 16px;
  margin-bottom: var(--hc-space-2xl);
  position: relative;
  overflow: hidden;
}

.hc-quickstart-banner::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(255,255,255,0.6) 0%, transparent 70%);
  pointer-events: none;
}

.hc-quickstart-content {
  display: flex;
  align-items: center;
  gap: var(--hc-space-lg);
  position: relative;
}

.hc-quickstart-icon {
  font-size: 2.5rem;
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.hc-quickstart-text h2 {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0 0 4px;
  color: #065f46;
}

.hc-quickstart-text p {
  font-size: 0.9375rem;
  color: #047857;
  margin: 0;
}

.hc-quickstart-cta {
  display: inline-flex;
  align-items: center;
  gap: var(--hc-space-sm);
  padding: var(--hc-space-sm) var(--hc-space-lg);
  background: #065f46;
  color: white;
  border-radius: 10px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9375rem;
  transition: all 200ms ease;
  white-space: nowrap;
  position: relative;
}

.hc-quickstart-cta:hover {
  background: #064e3b;
  transform: translateX(4px);
}

.hc-quickstart-cta svg {
  width: 18px;
  height: 18px;
  transition: transform 200ms ease;
}

.hc-quickstart-cta:hover svg {
  transform: translateX(4px);
}

/* Essentials - Large Cards */
.hc-essentials-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--hc-space-md);
}

.hc-essential-card {
  display: flex;
  align-items: center;
  gap: var(--hc-space-lg);
  padding: var(--hc-space-xl);
  background: var(--card-gradient);
  border: 1px solid rgba(0,0,0,0.05);
  border-radius: 16px;
  text-decoration: none;
  color: inherit;
  position: relative;
  overflow: hidden;
  transition: all 250ms cubic-bezier(0.4, 0, 0.2, 1);
}

.hc-essential-card::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 150px;
  height: 150px;
  background: radial-gradient(circle, rgba(255,255,255,0.8) 0%, transparent 70%);
  opacity: 0;
  transition: opacity 250ms ease;
}

.hc-essential-card:hover {
  transform: translateY(-4px) scale(1.01);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.1);
}

.hc-essential-card:hover::before {
  opacity: 1;
}

.hc-essential-icon {
  font-size: 3rem;
  flex-shrink: 0;
  transition: transform 300ms ease;
}

.hc-essential-card:hover .hc-essential-icon {
  transform: scale(1.15) rotate(-5deg);
}

.hc-essential-content {
  flex: 1;
}

.hc-essential-content h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0 0 4px;
  color: var(--hc-text);
}

.hc-essential-content p {
  font-size: 0.9375rem;
  color: var(--hc-text-secondary);
  margin: 0;
}

.hc-essential-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: var(--hc-space-sm);
}

.hc-essential-count {
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--card-color);
  background: white;
  padding: 4px 12px;
  border-radius: 20px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.hc-essential-arrow {
  width: 20px;
  height: 20px;
  color: var(--card-color);
  opacity: 0;
  transform: translateX(-8px);
  transition: all 200ms ease;
}

.hc-essential-card:hover .hc-essential-arrow {
  opacity: 1;
  transform: translateX(0);
}

.hc-badge-popular {
  position: absolute;
  top: var(--hc-space-md);
  right: var(--hc-space-md);
  padding: 4px 10px;
  background: #fef3c7;
  color: #92400e;
  font-size: 0.6875rem;
  font-weight: 600;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Topic Cards - Smaller Grid */
.hc-topic-grid-3 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: var(--hc-space-md);
}

.hc-topic-card {
  display: flex;
  flex-direction: column;
  padding: var(--hc-space-lg);
  background: var(--hc-bg);
  border: 1px solid var(--hc-border);
  border-radius: 14px;
  text-decoration: none;
  color: inherit;
  position: relative;
  transition: all 220ms cubic-bezier(0.4, 0, 0.2, 1);
}

.hc-topic-card:hover {
  border-color: var(--card-color, var(--hc-accent));
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  transform: translateY(-3px);
}

.hc-topic-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: var(--hc-space-md);
  transition: transform 250ms ease;
}

.hc-topic-card:hover .hc-topic-icon {
  transform: scale(1.1) rotate(-3deg);
}

.hc-topic-title {
  font-size: 1rem;
  font-weight: 600;
  margin: 0 0 var(--hc-space-xs);
}

.hc-topic-tagline {
  font-size: 0.8125rem;
  color: var(--hc-text-secondary);
  margin: 0 0 var(--hc-space-md);
  line-height: 1.5;
  flex: 1;
}

.hc-topic-count {
  font-size: 0.75rem;
  color: var(--hc-text-muted);
  padding-top: var(--hc-space-sm);
  border-top: 1px solid var(--hc-border);
}

.hc-badge-featured {
  position: absolute;
  top: var(--hc-space-md);
  right: var(--hc-space-md);
  padding: 3px 8px;
  background: var(--hc-accent);
  color: white;
  font-size: 0.625rem;
  font-weight: 600;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Popular Articles */
.hc-popular-section {
  background: var(--hc-bg-subtle);
  border-radius: 20px;
  padding: var(--hc-space-xl);
  margin-top: var(--hc-space-xl);
}

.hc-popular-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--hc-space-sm);
}

.hc-popular-card {
  display: flex;
  align-items: center;
  gap: var(--hc-space-md);
  padding: var(--hc-space-md);
  background: var(--hc-bg);
  border-radius: 10px;
  text-decoration: none;
  color: inherit;
  transition: all 150ms ease;
}

.hc-popular-card:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transform: translateX(4px);
}

.hc-popular-rank {
  width: 28px;
  height: 28px;
  background: var(--hc-bg-subtle);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--hc-text-muted);
  flex-shrink: 0;
  transition: all 150ms ease;
}

.hc-popular-card:hover .hc-popular-rank {
  background: var(--hc-accent);
  color: white;
}

.hc-popular-content h3 {
  font-size: 0.875rem;
  font-weight: 500;
  margin: 0 0 2px;
  color: var(--hc-text);
}

.hc-popular-content p {
  font-size: 0.75rem;
  color: var(--hc-text-muted);
  margin: 0;
}

/* Contact Section */
.hc-contact-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--hc-space-xl);
  padding: var(--hc-space-xl);
  background: var(--hc-bg);
  border: 2px solid var(--hc-border);
  border-radius: 16px;
}

.hc-contact-content h2 {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 0 0 var(--hc-space-xs);
}

.hc-contact-content p {
  font-size: 0.9375rem;
  color: var(--hc-text-secondary);
  margin: 0;
}

.hc-contact-actions {
  display: flex;
  gap: var(--hc-space-sm);
  flex-shrink: 0;
}

.hc-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--hc-space-sm);
  padding: var(--hc-space-sm) var(--hc-space-lg);
  border-radius: 10px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.875rem;
  transition: all 200ms ease;
}

.hc-btn svg {
  width: 18px;
  height: 18px;
}

.hc-btn-primary {
  background: var(--hc-accent);
  color: white;
}

.hc-btn-primary:hover {
  background: var(--hc-accent-dark, #0369a1);
  transform: translateY(-2px);
}

.hc-btn-ghost {
  color: var(--hc-text-secondary);
}

.hc-btn-ghost:hover {
  color: var(--hc-accent);
}

/* Index Responsive */
@media (max-width: 900px) {
  .hc-essentials-grid {
    grid-template-columns: 1fr;
  }

  .hc-popular-grid {
    grid-template-columns: 1fr;
  }

  .hc-contact-card {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 640px) {
  .hc-quickstart-banner {
    flex-direction: column;
    text-align: center;
  }

  .hc-quickstart-content {
    flex-direction: column;
  }

  .hc-topic-grid-3 {
    grid-template-columns: 1fr;
  }
}

/* =============================================
   SHOW (ARTICLE) PAGE STYLES
   ============================================= */

details[open] summary svg {
  transform: rotate(180deg);
}

details summary::-webkit-details-marker {
  display: none;
}

.hc-toc-link.active {
  color: var(--hc-accent);
  border-left-color: var(--hc-accent);
  font-weight: 500;
}

@media (max-width: 1024px) {
  .hc-container > div[style*="grid-template-columns: 1fr 280px"] {
    grid-template-columns: 1fr !important;
  }

  .hc-sidebar {
    display: none;
  }
}

/* Mobile responsive styles for article view */
@media (max-width: 1024px) {
  article {
    grid-column: 1 / -1 !important;
  }

  .hc-toc-sidebar {
    display: none;
  }
}

@media (max-width: 768px) {
  header h1 {
    font-size: 1.5rem !important;
  }

  .hc-nav-footer {
    grid-template-columns: 1fr !important;
  }

  .hc-nav-link-footer.prev {
    text-align: left;
  }

  .hc-nav-link-footer.next {
    text-align: left;
    border-top: 1px solid var(--hc-border);
    padding-top: var(--hc-space-md);
  }

  .hc-container {
    padding-left: var(--hc-space-md);
    padding-right: var(--hc-space-md);
  }
}

/* =============================================
   CATEGORY PAGE STYLES
   ============================================= */

.category-articles-list {
  display: flex;
  flex-direction: column;
  gap: var(--hc-space-sm);
}

.category-article-card {
  display: flex;
  align-items: flex-start;
  gap: var(--hc-space-md);
  padding: var(--hc-space-lg);
  background: var(--hc-bg);
  border: 1px solid var(--hc-border);
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
  transition: all 200ms cubic-bezier(0.4, 0, 0.2, 1);
}

.category-article-card:hover {
  border-color: var(--hc-accent);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transform: translateX(4px);
}

.category-article-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  background: var(--hc-bg-subtle);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--hc-text-muted);
  transition: all 200ms ease;
}

.category-article-icon svg {
  width: 20px;
  height: 20px;
}

.category-article-card:hover .category-article-icon {
  background: var(--hc-accent-subtle);
  color: var(--hc-accent);
}

.category-article-content {
  flex: 1;
  min-width: 0;
}

.category-article-title {
  font-size: 1rem;
  font-weight: 600;
  margin: 0 0 var(--hc-space-xs);
  color: var(--hc-text);
  line-height: 1.4;
}

.category-article-desc {
  font-size: 0.875rem;
  color: var(--hc-text-secondary);
  margin: 0 0 var(--hc-space-sm);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.category-article-meta {
  display: flex;
  align-items: center;
  gap: var(--hc-space-md);
}

.meta-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.75rem;
  color: var(--hc-text-muted);
}

.meta-badge {
  padding: 2px 8px;
  border-radius: 12px;
  font-weight: 500;
}

.meta-badge-beginner {
  background: #dcfce7;
  color: #166534;
}

.meta-badge-intermediate {
  background: #fef3c7;
  color: #92400e;
}

.meta-badge-advanced {
  background: #fee2e2;
  color: #991b1b;
}

.category-article-arrow {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--hc-text-muted);
  opacity: 0;
  transform: translateX(-8px);
  transition: all 200ms ease;
}

.category-article-arrow svg {
  width: 16px;
  height: 16px;
}

.category-article-card:hover .category-article-arrow {
  opacity: 1;
  transform: translateX(0);
  color: var(--hc-accent);
}

/* Category Responsive */
@media (max-width: 900px) {
  .hc-container > div[style*="grid-template-columns"] {
    grid-template-columns: 1fr !important;
  }

  aside {
    order: -1;
  }

  aside > div {
    position: static !important;
  }
}

/* =============================================
   SEARCH PAGE STYLES
   ============================================= */

mark {
  background: var(--hc-accent-muted);
  color: var(--hc-text);
  padding: 0 2px;
  border-radius: 2px;
}

/* =============================================
   ACCESSIBILITY: REDUCED MOTION
   ============================================= */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* =============================================
   HOVER UTILITY (replaces inline onmouseover)
   ============================================= */
.hc-hover-accent {
  transition: color 150ms ease;
}
.hc-hover-accent:hover,
.hc-hover-accent:focus-visible {
  color: var(--hc-accent);
}

.hc-hover-bg-accent {
  transition: all 150ms ease;
}
.hc-hover-bg-accent:hover,
.hc-hover-bg-accent:focus-visible {
  background: var(--hc-bg);
  color: var(--hc-text);
}

.hc-hover-chip {
  transition: all 150ms ease;
}
.hc-hover-chip:hover,
.hc-hover-chip:focus-visible {
  border-color: var(--hc-accent);
  color: var(--hc-accent);
}

.hc-hover-border-accent {
  transition: all 150ms ease;
}
.hc-hover-border-accent:hover,
.hc-hover-border-accent:focus-visible {
  border-color: var(--hc-accent);
  box-shadow: var(--hc-shadow);
}

/* =============================================
   STATS RIBBON
   ============================================= */
.hc-stats-ribbon {
  border-bottom: 1px solid var(--hc-border);
  background: var(--hc-bg);
}

.hc-stats-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--hc-space-xl);
  padding: var(--hc-space-md) 0;
}

.hc-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.hc-stat-number {
  font-size: 1rem;
  font-weight: 700;
  color: var(--hc-text);
  display: flex;
  align-items: center;
}

.hc-stat-label {
  font-size: 0.75rem;
  color: var(--hc-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 500;
}

.hc-stat-divider {
  width: 1px;
  height: 28px;
  background: var(--hc-border);
}

@media (max-width: 640px) {
  .hc-stats-inner {
    gap: var(--hc-space-md);
  }

  .hc-stat-number {
    font-size: 0.875rem;
  }

  .hc-stat-label {
    font-size: 0.6875rem;
  }

  .hc-stat-divider {
    height: 20px;
  }
}

/* =============================================
   LEARNING PATHS
   ============================================= */
.hc-learning-paths-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: var(--hc-space-lg);
}

.hc-learning-path-card {
  display: flex;
  flex-direction: column;
  padding: var(--hc-space-xl);
  background: var(--hc-bg);
  border: 1px solid var(--hc-border);
  border-radius: 16px;
  text-decoration: none;
  color: inherit;
  transition: all 250ms cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.hc-learning-path-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--hc-accent), #22d3ee);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 300ms ease;
}

.hc-learning-path-card:hover {
  border-color: var(--hc-accent);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
  transform: translateY(-4px);
}

.hc-learning-path-card:hover::after {
  transform: scaleX(1);
}

.hc-lp-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--hc-space-md);
}

.hc-lp-icon {
  font-size: 2rem;
}

.hc-lp-badge {
  font-size: 0.6875rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.hc-lp-title {
  font-size: 1.125rem;
  font-weight: 700;
  margin: 0 0 var(--hc-space-xs);
  color: var(--hc-text);
}

.hc-lp-desc {
  font-size: 0.875rem;
  color: var(--hc-text-secondary);
  margin: 0 0 var(--hc-space-lg);
  line-height: 1.5;
  flex: 1;
}

.hc-lp-progress-track {
  display: flex;
  align-items: center;
  gap: 0;
  margin-bottom: var(--hc-space-md);
  padding: 0 var(--hc-space-xs);
}

.hc-lp-step-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--hc-bg-muted);
  border: 2px solid var(--hc-border);
  flex-shrink: 0;
  transition: all 200ms ease;
}

.hc-learning-path-card:hover .hc-lp-step-dot {
  border-color: var(--hc-accent);
  background: var(--hc-accent-subtle);
}

.hc-lp-step-line {
  flex: 1;
  height: 2px;
  background: var(--hc-border);
  transition: background 200ms ease;
}

.hc-learning-path-card:hover .hc-lp-step-line {
  background: var(--hc-accent-muted);
}

.hc-lp-meta {
  font-size: 0.8125rem;
  color: var(--hc-text-muted);
  display: flex;
  align-items: center;
}

.hc-lp-meta-dot {
  margin: 0 var(--hc-space-sm);
}

@media (max-width: 640px) {
  .hc-learning-paths-grid {
    grid-template-columns: 1fr;
  }
}

/* =============================================
   QUICK GUIDES / JOURNEYS
   ============================================= */
.hc-journeys-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: var(--hc-space-lg);
}

.hc-journey-card {
  background: var(--hc-bg);
  border: 1px solid var(--hc-border);
  border-radius: 16px;
  overflow: hidden;
  transition: all 200ms ease;
}

.hc-journey-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}

.hc-journey-header {
  display: flex;
  align-items: flex-start;
  gap: var(--hc-space-md);
  padding: var(--hc-space-lg) var(--hc-space-lg) var(--hc-space-md);
}

.hc-journey-icon {
  font-size: 1.75rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.hc-journey-title {
  font-size: 1.0625rem;
  font-weight: 700;
  margin: 0 0 4px;
  color: var(--hc-text);
}

.hc-journey-desc {
  font-size: 0.8125rem;
  color: var(--hc-text-secondary);
  margin: 0;
  line-height: 1.5;
}

.hc-journey-steps {
  list-style: none;
  padding: 0;
  margin: 0;
}

.hc-journey-step {
  border-top: 1px solid var(--hc-border);
}

.hc-journey-step-link {
  display: flex;
  align-items: center;
  gap: var(--hc-space-md);
  padding: var(--hc-space-md) var(--hc-space-lg);
  text-decoration: none;
  color: inherit;
  transition: background 150ms ease;
}

.hc-journey-step-link:hover {
  background: var(--hc-bg-subtle);
}

.hc-journey-step-link:hover .hc-journey-step-arrow {
  opacity: 1;
  transform: translateX(0);
}

.hc-journey-step-link:hover .hc-journey-step-num {
  background: var(--hc-accent);
  color: white;
  border-color: var(--hc-accent);
}

.hc-journey-step-num {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2px solid var(--hc-border);
  background: var(--hc-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--hc-text-muted);
  flex-shrink: 0;
  transition: all 200ms ease;
}

.hc-journey-step-content {
  flex: 1;
  min-width: 0;
}

.hc-journey-step-title {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--hc-text);
}

.hc-journey-step-desc {
  display: block;
  font-size: 0.75rem;
  color: var(--hc-text-muted);
  margin-top: 1px;
}

.hc-journey-step-arrow {
  width: 16px;
  height: 16px;
  color: var(--hc-accent);
  flex-shrink: 0;
  opacity: 0;
  transform: translateX(-6px);
  transition: all 150ms ease;
}

@media (max-width: 640px) {
  .hc-journeys-grid {
    grid-template-columns: 1fr;
  }
}

/* =============================================
   TWO-COLUMN: RECENTLY UPDATED + POPULAR
   ============================================= */
.hc-two-col-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--hc-space-xl);
  margin-bottom: var(--hc-space-2xl);
}

.hc-recent-section,
.hc-popular-section-compact {
  background: var(--hc-bg-subtle);
  border-radius: 20px;
  padding: var(--hc-space-xl);
}

.hc-recent-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.hc-recent-item {
  display: flex;
  align-items: center;
  gap: var(--hc-space-md);
  padding: var(--hc-space-md) var(--hc-space-sm);
  text-decoration: none;
  color: inherit;
  border-radius: 10px;
  transition: all 150ms ease;
}

.hc-recent-item:hover {
  background: var(--hc-bg);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.hc-recent-item:hover .hc-recent-arrow {
  opacity: 1;
  transform: translateX(0);
}

.hc-recent-icon {
  font-size: 1.25rem;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--hc-bg);
  border-radius: 8px;
}

.hc-recent-content {
  flex: 1;
  min-width: 0;
}

.hc-recent-title {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--hc-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hc-recent-meta {
  display: block;
  font-size: 0.75rem;
  color: var(--hc-text-muted);
  margin-top: 1px;
}

.hc-recent-arrow {
  width: 14px;
  height: 14px;
  color: var(--hc-accent);
  flex-shrink: 0;
  opacity: 0;
  transform: translateX(-4px);
  transition: all 150ms ease;
}

.hc-popular-list {
  display: flex;
  flex-direction: column;
  gap: var(--hc-space-xs);
}

.hc-popular-section-compact .hc-popular-card {
  border-radius: 10px;
}

@media (max-width: 900px) {
  .hc-two-col-section {
    grid-template-columns: 1fr;
  }
}
