/* NBKB B2B Wholesale Pro - Modern Offline Documentation Styling */
:root {
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-light: #eff6ff;
  --text-main: #1e293b;
  --text-muted: #64748b;
  --bg-body: #f8fafc;
  --bg-card: #ffffff;
  --border: #e2e8f0;
  --sidebar-w: 280px;
  --header-h: 65px;
  --accent-green: #10b981;
  --accent-amber: #f59e0b;
  --accent-purple: #8b5cf6;
  --font-stack: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  --mono-stack: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier, monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 24px);
  overflow-x: hidden;
}

body {
  font-family: var(--font-stack);
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-main);
  background-color: var(--bg-body);
  display: flex;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Top Navigation Header (Matching Storefront nbkblabs.com) */
.nbkb-docs-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-h);
  background: #ffffff;
  border-bottom: 1px solid var(--border);
  z-index: 1000;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.04);
}

.nbkb-docs-header-inner {
  max-width: 1400px;
  height: 100%;
  padding: 0 32px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nbkb-logo-area {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none !important;
}

.nbkb-logo-icon {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: #ffffff;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 18px;
  box-shadow: 0 3px 8px rgba(37, 99, 235, 0.28);
}

.nbkb-logo-text {
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.4px;
}

.nbkb-logo-text span {
  color: #2563eb;
}

.nbkb-nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
}

.nbkb-nav-link {
  color: #475569;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none !important;
  transition: color 0.15s;
  position: relative;
}

.nbkb-nav-link:hover {
  color: #2563eb;
}

.nbkb-nav-link.active {
  color: #2563eb;
  font-weight: 700;
}

.nbkb-nav-link.active::after {
  content: "";
  position: absolute;
  bottom: -22px;
  left: 0;
  right: 0;
  height: 2px;
  background: #2563eb;
  border-radius: 2px;
}

.nbkb-nav-cta {
  background: #2563eb;
  color: #ffffff !important;
  font-size: 13.5px;
  font-weight: 700;
  padding: 8px 18px;
  border-radius: 7px;
  text-decoration: none !important;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
  transition: all 0.2s;
}

.nbkb-nav-cta:hover {
  background: #1d4ed8;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35);
}

/* Sidebar Navigation (Matching Storefront Light Theme) */
.doc-sidebar {
  width: var(--sidebar-w);
  background: #ffffff;
  border-right: 1px solid var(--border);
  color: #334155;
  position: fixed;
  top: var(--header-h);
  bottom: 0;
  left: 0;
  height: calc(100vh - var(--header-h));
  overflow-y: auto;
  padding: 24px 16px 40px 16px;
  display: flex;
  flex-direction: column;
  z-index: 100;
}

.doc-sidebar::-webkit-scrollbar {
  width: 5px;
}
.doc-sidebar::-webkit-scrollbar-track {
  background: transparent;
}
.doc-sidebar::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 10px;
}
.doc-sidebar::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

.brand-header {
  padding: 4px 8px 18px 8px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 16px;
}

.brand-title {
  font-size: 16px;
  font-weight: 800;
  color: #0f172a;
  display: flex;
  align-items: center;
  gap: 8px;
  letter-spacing: -0.3px;
}

.badge-pro {
  background: #eff6ff;
  color: #2563eb;
  border: 1px solid #bfdbfe;
  font-size: 10.5px;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 5px;
  text-transform: uppercase;
}

.brand-subtitle {
  font-size: 12px;
  color: #64748b;
  margin-top: 4px;
}

.nav-section-title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: #94a3b8;
  font-weight: 800;
  margin: 18px 0 6px 8px;
}

.doc-nav {
  list-style: none;
}

.doc-nav li {
  margin-bottom: 2px;
}

.doc-nav a {
  display: flex;
  align-items: center;
  padding: 7px 12px;
  color: #475569;
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 500;
  border-radius: 7px;
  transition: all 0.15s ease-in-out;
  border-left: 3px solid transparent;
}

.doc-nav a:hover {
  color: #0f172a;
  background: #f1f5f9;
}

.doc-nav a.active {
  color: #2563eb;
  background: #eff6ff;
  font-weight: 700;
  border-left-color: #2563eb;
}

/* Main Content Area */
.doc-main {
  margin-left: var(--sidebar-w);
  margin-top: var(--header-h);
  flex: 1;
  max-width: 1040px;
  padding: 36px 48px 100px 48px;
}

/* Hero Header (Light Theme) */
.hero-banner {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 36px 40px;
  margin-bottom: 32px;
  box-shadow: 0 4px 20px -4px rgba(15, 23, 42, 0.05);
}

.hero-banner .nbkb-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #eff6ff;
  color: #2563eb;
  font-weight: 700;
  font-size: 11.5px;
  padding: 4px 12px;
  border-radius: 50px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: 1px solid #bfdbfe;
  margin-bottom: 14px;
}

.hero-banner .nbkb-pill-dot {
  width: 6px;
  height: 6px;
  background: #2563eb;
  border-radius: 50%;
}

.hero-banner h1 {
  font-size: 28px;
  font-weight: 900;
  color: #0f172a;
  letter-spacing: -0.6px;
  line-height: 1.25;
  margin-bottom: 10px;
}

.hero-banner .subtitle {
  font-size: 15px;
  color: #64748b;
  max-width: 760px;
  line-height: 1.6;
}

.hero-meta {
  margin-top: 20px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.hero-badge {
  background: #f8fafc;
  color: #334155;
  padding: 5px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid #e2e8f0;
}

/* Content Sections */
.doc-section {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 36px 40px;
  margin-bottom: 32px;
  box-shadow: 0 4px 20px -4px rgba(15, 23, 42, 0.05);
}

.doc-section h2 {
  font-size: 21px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.4px;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
}

.doc-section h3 {
  font-size: 16.5px;
  font-weight: 700;
  color: #1e293b;
  margin: 24px 0 10px 0;
  letter-spacing: -0.2px;
}

.doc-section h4 {
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 6px;
}

.doc-section p {
  color: #334155;
  margin-bottom: 14px;
  font-size: 14.5px;
  line-height: 1.65;
}

.doc-section ul, .doc-section ol {
  margin: 10px 0 18px 24px;
  color: #334155;
  font-size: 14.5px;
  line-height: 1.65;
}

.doc-section li {
  margin-bottom: 6px;
}

/* Callout Boxes */
.callout {
  padding: 16px 20px;
  border-radius: 10px;
  margin: 20px 0;
  display: flex;
  gap: 14px;
  align-items: flex-start;
  font-size: 14px;
  line-height: 1.55;
}

.callout-icon {
  font-size: 18px;
  line-height: 1.3;
}

.callout.info {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-left: 4px solid #2563eb;
  color: #1e40af;
}

.callout.warning {
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-left: 4px solid #f59e0b;
  color: #92400e;
}

.callout.success {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-left: 4px solid #10b981;
  color: #166534;
}

.callout.tip {
  background: #faf5ff;
  border: 1px solid #e9d5ff;
  border-left: 4px solid #8b5cf6;
  color: #6b21a8;
}

/* Tables (matches comparison styling) */
.doc-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin: 22px 0;
  font-size: 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}

.doc-table th {
  background: #f8fafc;
  color: #1e293b;
  font-weight: 700;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 12px 18px;
  border-bottom: 1px solid var(--border);
  border-right: 1px solid var(--border);
  text-align: left;
}

.doc-table th:last-child {
  border-right: none;
}

.doc-table td {
  padding: 12px 18px;
  border-bottom: 1px solid #f1f5f9;
  border-right: 1px solid #f1f5f9;
  color: #334155;
  text-align: left;
}

.doc-table td:last-child {
  border-right: none;
}

.doc-table tr:last-child td {
  border-bottom: none;
}

.doc-table tbody tr:hover {
  background: #f8fafc;
}

/* Code Blocks & Inlines */
pre {
  background: #0f172a;
  color: #f1f5f9;
  padding: 18px 22px;
  border-radius: 10px;
  overflow-x: auto;
  font-family: var(--mono-stack);
  font-size: 13px;
  line-height: 1.6;
  margin: 18px 0;
  border: 1px solid #1e293b;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
}

code {
  font-family: var(--mono-stack);
  font-size: 12.5px;
  background: #eff6ff;
  color: #2563eb;
  padding: 2px 7px;
  border-radius: 5px;
  border: 1px solid #dbeafe;
  font-weight: 600;
}

pre code {
  background: transparent;
  color: inherit;
  padding: 0;
  border: none;
  font-weight: normal;
}

/* Key Features Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
  margin: 22px 0;
}

.feature-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 20px;
  transition: all 0.2s ease;
}

.feature-card:hover {
  background: #ffffff;
  border-color: #2563eb;
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -5px rgba(37, 99, 235, 0.1);
}

.feature-card-icon {
  font-size: 22px;
  margin-bottom: 12px;
  width: 42px;
  height: 42px;
  background: #eff6ff;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-card h4 {
  font-size: 15.5px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 6px;
}

.feature-card p {
  font-size: 13.5px;
  color: #64748b;
  line-height: 1.55;
  margin-bottom: 0;
}

/* Steps Item */
.step-list {
  list-style: none !important;
  list-style-type: none !important;
  counter-reset: step-counter;
  padding-left: 0 !important;
  margin: 24px 0 24px 0 !important;
}

.step-item {
  list-style: none !important;
  list-style-type: none !important;
  position: relative;
  padding-left: 52px;
  margin-bottom: 24px;
}

.step-item::before {
  content: counter(step-counter);
  counter-increment: step-counter;
  position: absolute;
  left: 0;
  top: 0;
  width: 34px;
  height: 34px;
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 14px;
  box-shadow: 0 3px 8px rgba(37, 99, 235, 0.28);
}

.step-title {
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 6px;
}

/* Responsive */
@media (max-width: 900px) {
  body {
    flex-direction: column;
  }
  .nbkb-docs-header {
    position: relative;
    height: auto;
    padding: 14px 16px;
  }
  .nbkb-docs-header-inner {
    flex-direction: column;
    gap: 14px;
    padding: 0;
    text-align: center;
  }
  .nbkb-nav-links {
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px;
  }
  .nbkb-nav-link.active::after {
    display: none;
  }
  .doc-sidebar {
    width: 100%;
    position: relative;
    top: 0;
    height: auto;
    border-right: none;
    border-bottom: 1px solid var(--border);
    padding: 20px;
  }
  .doc-main {
    margin-left: 0;
    margin-top: 0;
    padding: 24px 16px 60px 16px;
    max-width: 100%;
  }
  .doc-section {
    padding: 24px 20px;
    border-radius: 12px;
  }
  .hero-banner {
    padding: 24px 20px;
    border-radius: 12px;
  }
}

@media print {
  .nbkb-docs-header,
  .doc-sidebar {
    display: none;
  }
  .doc-main {
    margin-left: 0;
    margin-top: 0;
    padding: 0;
    max-width: 100%;
  }
  .doc-section {
    border: none;
    box-shadow: none;
    padding: 20px 0;
    page-break-inside: avoid;
  }
}
