/* ReductrAI Docs - Light Theme */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

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

:root {
  /* Light theme colors */
  --bg-primary: #ffffff;
  --bg-secondary: #fafafa;
  --bg-tertiary: #f4f4f5;
  --bg-code: #1e1e2e;

  --text-primary: #18181b;
  --text-secondary: #52525b;
  --text-muted: #a1a1aa;

  --border-light: #e4e4e7;
  --border-medium: #d4d4d8;

  --accent-primary: #7c3aed;
  --accent-primary-dark: #6d28d9;
  --accent-primary-light: #a78bfa;
  --accent-primary-glow: rgba(124, 58, 237, 0.1);

  --accent-teal: #14b8a6;

  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);

  --font-sans: "Inter", -apple-system, system-ui, sans-serif;
  --font-mono: "SF Mono", "Monaco", "Inconsolata", "Roboto Mono", monospace;
}

body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-secondary);
  line-height: 1.6;
  min-height: 100vh;
}

a {
  color: var(--accent-primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 16px 0;
  background: rgba(15, 15, 18, 0.97);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.25rem;
  font-weight: 600;
  color: #ffffff;
  text-decoration: none;
}

.logo:hover {
  text-decoration: none;
}

.logo-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

.nav {
  display: flex;
  gap: 32px;
  font-size: 0.9375rem;
  font-weight: 500;
}

.nav a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.2s;
}

.nav a:hover,
.nav a.active {
  color: #ffffff;
  text-decoration: none;
}

.header-cta {
  display: flex;
  gap: 12px;
}

.btn {
  padding: 10px 20px;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: var(--radius-md);
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s;
  border: none;
}

.btn:hover {
  text-decoration: none;
}

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

.btn-primary:hover {
  background: var(--accent-primary-dark);
}

.btn-secondary {
  background: transparent;
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover {
  border-color: rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.05);
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 120px 24px 80px;
}

/* Hero */
.hero {
  text-align: center;
  margin-bottom: 48px;
}

.hero h1 {
  font-size: 2.5rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.hero p {
  font-size: 1.125rem;
  color: var(--text-secondary);
  max-width: 500px;
  margin: 0 auto;
  line-height: 1.7;
}

/* Quick Start */
.quick-start {
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  padding: 32px;
  margin-bottom: 48px;
}

.quick-start h2 {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--accent-primary);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.quick-start h2 i {
  font-size: 16px;
}

.code-block {
  background: var(--bg-code);
  border-radius: var(--radius-lg);
  padding: 24px;
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  line-height: 1.8;
  overflow-x: auto;
  color: #e4e4e7;
}

.code-block .comment {
  color: #6b7280;
}

.code-block .command {
  color: var(--accent-primary-light);
}

.code-block .var {
  color: #67e8f9;
}

/* Docs Grid */
.docs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.doc-card {
  background: var(--bg-primary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-xl);
  padding: 28px;
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease;
}

.doc-card:hover {
  border-color: var(--border-medium);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
  text-decoration: none;
}

.doc-card .icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  font-size: 1.25rem;
  background: var(--accent-primary-glow);
  color: var(--accent-primary);
}

.doc-card h3 {
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.doc-card p {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Section Title */
.section-title {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.section-title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-light);
}

/* Content page styles */
.content {
  max-width: 800px;
  margin: 0 auto;
}

.content h1 {
  font-size: 2.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.content h2 {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-top: 48px;
  margin-bottom: 16px;
}

.content h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-top: 32px;
  margin-bottom: 12px;
}

.content p {
  margin-bottom: 16px;
  color: var(--text-secondary);
  line-height: 1.7;
}

.content ul,
.content ol {
  margin-bottom: 16px;
  padding-left: 24px;
  color: var(--text-secondary);
}

.content li {
  margin-bottom: 8px;
  line-height: 1.6;
}

.content code {
  font-family: var(--font-mono);
  font-size: 0.875em;
  background: var(--bg-tertiary);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--accent-primary);
}

.content pre {
  background: var(--bg-code);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
  overflow-x: auto;
}

.content pre code {
  background: none;
  padding: 0;
  color: #e4e4e7;
  font-size: 0.8125rem;
  line-height: 1.7;
}

.content table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 24px;
}

.content th,
.content td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-light);
}

.content th {
  font-weight: 600;
  color: var(--text-primary);
  background: var(--bg-secondary);
}

.content td {
  color: var(--text-secondary);
}

/* Sidebar navigation */
.docs-layout {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 48px;
  max-width: 1200px;
  margin: 0 auto;
}

.sidebar {
  position: sticky;
  top: 100px;
  height: fit-content;
}

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

.sidebar-nav li {
  margin-bottom: 4px;
}

.sidebar-nav a {
  display: block;
  padding: 8px 12px;
  color: var(--text-secondary);
  border-radius: var(--radius-md);
  font-size: 0.9375rem;
  transition: all 0.2s;
}

.sidebar-nav a:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  text-decoration: none;
}

.sidebar-nav a.active {
  background: var(--accent-primary-glow);
  color: var(--accent-primary);
}

/* Footer */
.footer {
  padding: 40px 24px;
  text-align: center;
  border-top: 1px solid var(--border-light);
  margin-top: 60px;
  background: var(--bg-secondary);
}

.footer p {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.footer a {
  color: var(--accent-primary);
  text-decoration: none;
}

.footer a:hover {
  text-decoration: underline;
}

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.badge-purple {
  background: var(--accent-primary-glow);
  color: var(--accent-primary);
}

.badge-teal {
  background: rgba(20, 184, 166, 0.1);
  color: var(--accent-teal);
}

/* Info boxes */
.success-box {
  background: rgba(20, 184, 166, 0.1);
  border: 1px solid rgba(20, 184, 166, 0.2);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin: 24px 0;
  display: flex;
  gap: 12px;
}

.success-box i {
  color: var(--accent-teal);
  margin-top: 3px;
}

.success-box p {
  margin: 0;
  font-size: 0.875rem;
}

.warning-box {
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.2);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin: 24px 0;
  display: flex;
  gap: 12px;
}

.warning-box i {
  color: #f59e0b;
  margin-top: 3px;
}

.warning-box p {
  margin: 0;
  font-size: 0.875rem;
}

/* Tier cards */
.tier-card {
  background: var(--bg-primary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 20px 24px;
  margin: 16px 0;
  transition: all 0.2s;
}

.tier-card:hover {
  border-color: var(--border-medium);
  box-shadow: var(--shadow-sm);
}

.tier-card h4 {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.tier-card p {
  margin-bottom: 0;
  font-size: 0.875rem;
}

.tier-hot {
  border-left: 3px solid #ef4444;
}

.tier-warm {
  border-left: 3px solid #f59e0b;
}

.tier-cold {
  border-left: 3px solid #3b82f6;
}

/* Compression stat badge */
.compression-stat {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent-primary-glow);
  color: var(--accent-primary);
  padding: 4px 10px;
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
}

/* Flow diagram */
.flow-diagram {
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 32px;
  margin: 24px 0;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  line-height: 2;
  color: var(--text-secondary);
  overflow-x: auto;
}

.flow-diagram .highlight {
  color: var(--accent-primary);
  font-weight: 600;
}

.flow-diagram .arrow {
  color: var(--text-muted);
}

/* Table badges */
.required {
  color: var(--accent-primary);
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
}

.optional {
  color: var(--text-muted);
  font-size: 0.6875rem;
  text-transform: uppercase;
}

.default {
  color: var(--accent-primary);
  font-family: var(--font-mono);
  font-size: 0.75rem;
}

/* Code block value highlighting */
.code-block .value {
  color: var(--accent-teal);
}

.code-block .string {
  color: #f59e0b;
}

/* Layout with sidebar */
.layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  max-width: 1400px;
  margin: 0 auto;
  padding-top: 80px;
  min-height: 100vh;
}

/* Sidebar */
.sidebar {
  background: var(--bg-secondary);
  border-right: 1px solid var(--border-light);
  padding: 32px 24px;
  position: sticky;
  top: 80px;
  height: calc(100vh - 80px);
  overflow-y: auto;
}

.sidebar h4 {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 16px;
}

.sidebar ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar li {
  margin-bottom: 4px;
}

.sidebar a {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  text-decoration: none;
  display: block;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  transition: all 0.2s;
  border-left: 2px solid transparent;
}

.sidebar a:hover {
  background: var(--bg-tertiary);
  color: var(--text-primary);
  text-decoration: none;
}

.sidebar a.active {
  background: var(--accent-primary-glow);
  color: var(--accent-primary);
  border-left-color: var(--accent-primary);
}

.sidebar-section {
  margin-bottom: 32px;
}

/* Doc content page */
.doc-content {
  padding: 48px 64px;
  max-width: 900px;
}

.breadcrumb {
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.breadcrumb a {
  color: var(--accent-primary);
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

.doc-content h1 {
  font-size: 2.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.subtitle {
  font-size: 1.0625rem;
  color: var(--text-secondary);
  margin-bottom: 48px;
  line-height: 1.7;
}

.doc-content h2 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 48px 0 16px;
  padding-top: 32px;
  border-top: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  gap: 10px;
}

.doc-content h2:first-of-type {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

.doc-content h3 {
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 32px 0 12px;
}

.doc-content p {
  font-size: 0.9375rem;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.doc-content code {
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  background: var(--bg-tertiary);
  padding: 2px 8px;
  border-radius: 4px;
  color: var(--accent-primary);
}

.doc-content .code-block {
  margin: 16px 0 24px;
}

/* Info box */
.info-box {
  background: var(--accent-primary-glow);
  border: 1px solid rgba(124, 58, 237, 0.2);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin: 24px 0;
  display: flex;
  gap: 12px;
}

.info-box i {
  color: var(--accent-primary);
  margin-top: 3px;
}

.info-box p {
  margin: 0;
  font-size: 0.875rem;
}

/* Tables in doc content */
.doc-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
}

.doc-content th,
.doc-content td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-light);
  font-size: 0.875rem;
}

.doc-content th {
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: var(--bg-secondary);
}

.doc-content ul {
  margin-left: 24px;
  margin-bottom: 24px;
  color: var(--text-secondary);
}

.doc-content li {
  margin-bottom: 8px;
  font-size: 0.9375rem;
}

/* Platform grid */
.platform-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin: 24px 0;
}

.platform-card {
  background: var(--bg-primary);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 20px;
  transition: all 0.2s;
}

.platform-card:hover {
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-md);
}

.platform-card h4 {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.platform-card h4 i {
  color: var(--accent-primary);
}

.platform-card p {
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin: 0;
}

/* Responsive */
@media (max-width: 1024px) {
  .docs-layout {
    grid-template-columns: 1fr;
  }

  .layout {
    grid-template-columns: 1fr;
  }

  .sidebar {
    display: none;
  }
}

@media (max-width: 900px) {
  .docs-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 900px) {
  .platform-grid {
    grid-template-columns: 1fr;
  }

  .doc-content {
    padding: 32px 24px;
  }
}

@media (max-width: 640px) {
  .header-inner {
    padding: 0 16px;
  }

  .nav {
    display: none;
  }

  .header-cta {
    display: none;
  }

  .container {
    padding: 100px 16px 48px;
  }

  .docs-grid {
    grid-template-columns: 1fr;
  }

  .hero h1 {
    font-size: 1.875rem;
  }

  .content h1,
  .doc-content h1 {
    font-size: 1.75rem;
  }
}
