/**
 * VentureGenius Documentation Styles
 * Contains all styles for documentation pages, including index, getting started, and other guides
 */

/* Base Typography */
.doc-content h2 {
  font-size: 1.875rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  margin-top: 2.5rem;
  color: var(--text-primary);
}

.doc-content h3 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1rem;
  margin-top: 2rem;
  color: var(--text-primary);
}

.doc-content h4 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1rem;
  margin-top: 1.5rem;
  color: var(--text-primary);
}

.doc-content p {
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 1.25rem;
}

.doc-content ul, 
.doc-content ol {
  padding-left: 1.5rem;
  margin-bottom: 1.5rem;
  color: var(--text-secondary);
}

.doc-content ul {
  list-style-type: disc;
}

.doc-content ol {
  list-style-type: decimal;
}

.doc-content a:not(.doc-card):not(.doc-link) {
  color: var(--primary);
  text-decoration: none;
  border-bottom: 1px dotted var(--primary-light);
  transition: all 0.2s;
}

.doc-content a:hover:not(.doc-card):not(.doc-link) {
  color: var(--primary-dark);
  border-bottom: 1px solid var(--primary);
}

.doc-content code:not([class*="language-"]) {
  background-color: var(--code-bg);
  color: var(--code-color);
  padding: 0.2rem 0.4rem;
  border-radius: 0.25rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.875em;
}

.doc-content pre {
  background-color: var(--code-block-bg);
  color: var(--code-block-color);
  padding: 1rem;
  border-radius: 0.5rem;
  overflow-x: auto;
  margin-bottom: 1.5rem;
  border: 1px solid var(--border-light);
}

.doc-content pre code {
  background-color: transparent;
  padding: 0;
  font-size: 0.875rem;
  line-height: 1.6;
}

/* Doc Card Components */
.doc-card {
  background-color: var(--bg-card);
  border-radius: 0.75rem;
  padding: 1.5rem;
  border: 1px solid var(--border-light);
  transition: all 0.3s ease;
  display: block;
  text-decoration: none;
  color: var(--text-primary);
}

.doc-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  border-color: var(--primary-light);
}

.doc-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.doc-icon i {
  font-size: 1.5rem;
}

.doc-card h3 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.doc-card p {
  color: var(--text-secondary);
  margin-bottom: 1rem;
}

/* Sidebar Navigation */
.doc-sidebar {
  position: sticky;
  top: 5rem;
  height: calc(100vh - 10rem);
  overflow-y: auto;
  padding-right: 1rem;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}

.doc-sidebar::-webkit-scrollbar {
  width: 0.25rem;
}

.doc-sidebar::-webkit-scrollbar-track {
  background: transparent;
}

.doc-sidebar::-webkit-scrollbar-thumb {
  background-color: var(--border);
  border-radius: 0.25rem;
}

.doc-link {
  display: flex;
  align-items: center;
  padding: 0.5rem 0.75rem;
  border-radius: 0.375rem;
  color: var(--text-secondary);
  text-decoration: none;
  transition: all 0.2s ease;
  margin-bottom: 0.25rem;
}

.doc-link i {
  margin-inline-end: 0.75rem;
  font-size: 0.875rem;
}

.doc-link:hover {
  background-color: var(--hover-bg);
  color: var(--primary);
}

.doc-link.active {
  background-color: var(--primary-bg);
  color: var(--primary);
  font-weight: 500;
}

/* Search Component */
.doc-search-container {
  position: relative;
  margin-bottom: 2rem;
}

.doc-search-input {
  width: 100%;
  padding: 0.75rem 1rem 0.75rem 2.5rem;
  border-radius: 0.5rem;
  border: 1px solid var(--border);
  background-color: var(--bg-input);
  color: var(--text-primary);
  outline: none;
  transition: all 0.2s ease;
}

.doc-search-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 2px var(--primary-light);
}

.doc-search-icon {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-tertiary);
  pointer-events: none;
}

/* Doc Callouts */
.doc-note,
.doc-warning,
.doc-tip,
.doc-caution {
  padding: 1rem 1.25rem;
  margin-bottom: 1.5rem;
  border-radius: 0.5rem;
  position: relative;
}

.doc-note {
  background-color: var(--note-bg);
  border-left: 4px solid var(--note-border);
}

.doc-warning {
  background-color: var(--warning-bg);
  border-left: 4px solid var(--warning-border);
}

.doc-tip {
  background-color: var(--tip-bg);
  border-left: 4px solid var(--tip-border);
}

.doc-caution {
  background-color: var(--caution-bg);
  border-left: 4px solid var(--caution-border);
}

.doc-note::before,
.doc-warning::before,
.doc-tip::before,
.doc-caution::before {
  font-weight: 600;
  display: block;
  margin-bottom: 0.5rem;
}

.doc-note::before {
  content: "Note";
  color: var(--note-border);
}

.doc-warning::before {
  content: "Warning";
  color: var(--warning-border);
}

.doc-tip::before {
  content: "Tip";
  color: var(--tip-border);
}

.doc-caution::before {
  content: "Caution";
  color: var(--caution-border);
}

/* Steps and Progress */
.doc-step {
  display: flex;
  align-items: flex-start;
  margin-bottom: 2rem;
}

.doc-step-number {
  width: 2rem;
  height: 2rem;
  border-radius: 9999px;
  background-color: var(--primary-bg);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  flex-shrink: 0;
  margin-right: 1rem;
}

.doc-progress-bar {
  height: 0.5rem;
  background-color: var(--border-light);
  border-radius: 9999px;
  overflow: hidden;
  margin: 2rem 0;
}

.doc-progress-bar-fill {
  height: 100%;
  background-color: var(--primary);
  border-radius: 9999px;
}

/* Documentation Tabs */
.doc-tabs {
  margin-bottom: 2rem;
}

.doc-tab-buttons {
  display: flex;
  border-bottom: 1px solid var(--border);
  margin-bottom: 1rem;
}

.doc-tab-button {
  padding: 0.5rem 1rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-right: 1rem;
}

.doc-tab-button:hover {
  color: var(--primary);
}

.doc-tab-button.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.doc-tab-content {
  display: none;
  padding: 1rem;
  border: 1px solid var(--border-light);
  border-radius: 0.5rem;
}

.doc-tab-content.active {
  display: block;
}

/* Search Results */
.search-result-item {
  padding: 1rem;
  border-bottom: 1px solid var(--border-light);
  transition: background-color 0.2s ease;
}

.search-result-item:hover {
  background-color: var(--hover-bg);
}

.search-result-item:last-child {
  border-bottom: none;
}

.search-result-title {
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.search-result-path {
  font-size: 0.75rem;
  color: var(--text-tertiary);
  margin-bottom: 0.5rem;
}

.search-result-snippet {
  color: var(--text-secondary);
  font-size: 0.875rem;
}

.search-highlight {
  background-color: var(--highlight-bg);
  padding: 0.125rem 0.25rem;
  border-radius: 0.25rem;
}

/* Pagination */
.doc-pagination {
  display: flex;
  justify-content: space-between;
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-light);
}

.doc-pagination-link {
  display: flex;
  align-items: center;
  color: var(--text-secondary);
  text-decoration: none;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  border: 1px solid var(--border-light);
  transition: all 0.2s ease;
}

.doc-pagination-link:hover {
  background-color: var(--hover-bg);
  color: var(--primary);
}

.doc-pagination-link.prev i {
  margin-right: 0.5rem;
}

.doc-pagination-link.next i {
  margin-left: 0.5rem;
}

/* Content Table of Contents */
.doc-toc {
  position: sticky;
  top: 5rem;
  max-height: calc(100vh - 10rem);
  overflow-y: auto;
  padding: 1rem;
  border-radius: 0.5rem;
  background-color: var(--bg-card);
  border: 1px solid var(--border-light);
}

.doc-toc-title {
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.doc-toc ul {
  list-style-type: none;
  padding-left: 0;
}

.doc-toc ul ul {
  padding-left: 1rem;
}

.doc-toc li {
  margin-bottom: 0.5rem;
}

.doc-toc a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.875rem;
  display: block;
  padding: 0.25rem 0;
  transition: color 0.2s ease;
}

.doc-toc a:hover {
  color: var(--primary);
}

.doc-toc a.active {
  color: var(--primary);
  font-weight: 500;
}

/* Code Highlighting */
.language-js, .language-javascript { color: #07a; }
.language-html { color: #170; }
.language-css { color: #905; }
.language-python { color: #549; }
.language-bash { color: #54a; }

/* Mobile Adjustments */
@media (max-width: 1024px) {
  .doc-sidebar {
    position: static;
    height: auto;
    margin-bottom: 2rem;
  }
  
  .doc-toc {
    position: static;
    margin-top: 2rem;
  }
}

@media (max-width: 768px) {
  .doc-step {
    flex-direction: column;
  }
  
  .doc-step-number {
    margin-bottom: 0.5rem;
  }
  
  .doc-tab-buttons {
    flex-wrap: wrap;
  }
  
  .doc-tab-button {
    margin-bottom: 0.5rem;
  }
}

/* CSS Variables for Theme Support */
:root {
  --primary: #5046e5; /* Main brand color */
  --primary-dark: #3c34b9;
  --primary-light: rgba(80, 70, 229, 0.2);
  --primary-bg: rgba(80, 70, 229, 0.1);
  
  --text-primary: #111827;
  --text-secondary: #4b5563;
  --text-tertiary: #9ca3af;
  
  --bg-card: #ffffff;
  --bg-input: #ffffff;
  --hover-bg: #f3f4f6;
  --border: #d1d5db;
  --border-light: #e5e7eb;
  
  --code-bg: #f1f5f9;
  --code-color: #0f172a;
  --code-block-bg: #f8fafc;
  --code-block-color: #334155;
  
  --note-bg: #eff6ff;
  --note-border: #3b82f6;
  --warning-bg: #fff7ed;
  --warning-border: #f97316;
  --tip-bg: #ecfdf5;
  --tip-border: #10b981;
  --caution-bg: #fef2f2;
  --caution-border: #ef4444;
  
  --highlight-bg: rgba(250, 204, 21, 0.2);
}

/* Dark mode variables */
.dark-theme {
  --primary: #818cf8; /* Adjusted for better visibility in dark mode */
  --primary-dark: #6366f1;
  --primary-light: rgba(129, 140, 248, 0.2);
  --primary-bg: rgba(129, 140, 248, 0.15);
  
  --text-primary: #f9fafb;
  --text-secondary: #d1d5db;
  --text-tertiary: #9ca3af;
  
  --bg-card: #1f2937;
  --bg-input: #374151;
  --hover-bg: #374151;
  --border: #4b5563;
  --border-light: #374151;
  
  --code-bg: #1e293b;
  --code-color: #e2e8f0;
  --code-block-bg: #111827;
  --code-block-color: #cbd5e1;
  
  --note-bg: rgba(59, 130, 246, 0.15);
  --note-border: #3b82f6;
  --warning-bg: rgba(249, 115, 22, 0.15);
  --warning-border: #f97316;
  --tip-bg: rgba(16, 185, 129, 0.15);
  --tip-border: #10b981;
  --caution-bg: rgba(239, 68, 68, 0.15);
  --caution-border: #ef4444;
  
  --highlight-bg: rgba(250, 204, 21, 0.15);
}

/* Print Styles */
@media print {
  .doc-sidebar, 
  .doc-toc,
  .doc-search-container {
    display: none;
  }
  
  .doc-content {
    width: 100% !important;
  }
  
  .doc-content a {
    text-decoration: underline;
    color: #000 !important;
  }
  
  .doc-note,
  .doc-warning,
  .doc-tip,
  .doc-caution {
    break-inside: avoid;
    border: 1px solid #000;
    background-color: transparent !important;
  }
  
  .doc-card {
    break-inside: avoid;
    border: 1px solid #000;
    box-shadow: none;
  }
}

/* Getting Started Page Specific Styles */
.doc-step {
  display: flex;
  align-items: flex-start;
  margin-bottom: 2rem;
  position: relative;
}

.doc-step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 2rem;
  left: 1rem;
  bottom: -1rem;
  width: 2px;
  background: var(--border-light);
  z-index: 0;
}

.doc-step-number {
  width: 2rem;
  height: 2rem;
  border-radius: 9999px;
  background-color: var(--primary-bg);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  flex-shrink: 0;
  margin-right: 1rem;
  position: relative;
  z-index: 1;
}

.doc-step-content {
  flex-grow: 1;
}

.doc-step-content h4 {
  margin-top: 0;
}

.doc-timeline {
  position: relative;
  margin: 2rem 0;
  padding-left: 1.5rem;
}

.doc-timeline::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, var(--primary), var(--primary-light));
  border-radius: 999px;
}

.doc-timeline-item {
  position: relative;
  padding-bottom: 2rem;
}

.doc-timeline-item::before {
  content: '';
  position: absolute;
  left: -1.5rem;
  top: 0.5rem;
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  background-color: var(--primary);
  border: 2px solid var(--bg-card);
}

.doc-timeline-item:last-child {
  padding-bottom: 0;
}

.doc-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.doc-feature-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: 0.75rem;
  padding: 1.5rem;
  transition: all 0.3s ease;
}

.doc-feature-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.doc-feature-card-icon {
  width: 3rem;
  height: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
  margin-bottom: 1rem;
}

.doc-feature-card h4 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
}

.doc-progress {
  height: 0.5rem;
  background-color: var(--border-light);
  border-radius: 9999px;
  margin: 2rem 0;
}

.doc-progress-fill {
  height: 100%;
  background-color: var(--primary);
  border-radius: 9999px;
  transition: width 0.5s ease;
}

.doc-tabs-wrapper {
  margin: 2rem 0;
}

.doc-tabs-navigation {
  display: flex;
  border-bottom: 1px solid var(--border);
  margin-bottom: 1rem;
  overflow-x: auto;
  scrollbar-width: none;
}

.doc-tabs-navigation::-webkit-scrollbar {
  display: none;
}

.doc-tab {
  padding: 0.75rem 1.25rem;
  font-weight: 500;
  color: var(--text-secondary);
  border-bottom: 2px solid transparent;
  cursor: pointer;
  white-space: nowrap;
}

.doc-tab:hover {
  color: var(--primary);
}

.doc-tab.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.doc-tab-content {
  display: none;
  animation: fadeIn 0.5s ease forwards;
}

.doc-tab-content.active {
  display: block;
}

.doc-screenshot {
  border-radius: 0.5rem;
  border: 1px solid var(--border-light);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  margin: 1.5rem 0;
  max-width: 100%;
  height: auto;
}

.doc-video {
  border-radius: 0.5rem;
  overflow: hidden;
  margin: 1.5rem 0;
}

.doc-checklist {
  list-style: none;
  padding-left: 0;
  margin-bottom: 1.5rem;
}

.doc-checklist li {
  position: relative;
  padding-left: 2rem;
  margin-bottom: 0.5rem;
}

.doc-checklist li::before {
  content: '\f00c';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  position: absolute;
  left: 0;
  color: var(--primary);
}

.doc-callout {
  border-radius: 0.5rem;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
  border-left-width: 4px;
  border-left-style: solid;
}

.doc-callout.tip {
  background-color: var(--tip-bg);
  border-left-color: var(--tip-border);
}

.doc-callout.note {
  background-color: var(--note-bg);
  border-left-color: var(--note-border);
}

.doc-callout.warning {
  background-color: var(--warning-bg);
  border-left-color: var(--warning-border);
}

.doc-callout.important {
  background-color: var(--caution-bg);
  border-left-color: var(--caution-border);
}

.doc-callout-title {
  font-weight: 600;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
}

.doc-callout-title i {
  margin-right: 0.5rem;
}

/* Next/Previous Navigation */
.doc-next-prev {
  display: flex;
  justify-content: space-between;
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-light);
}

.doc-next-prev a {
  display: flex;
  align-items: center;
  color: var(--primary);
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
}

.doc-next-prev a:hover {
  color: var(--primary-dark);
}

.doc-next-prev .prev i {
  margin-right: 0.5rem;
}

.doc-next-prev .next i {
  margin-left: 0.5rem;
}

/* Getting started sections */
.gs-section {
  margin-bottom: 3rem;
  padding: 1.5rem;
  background-color: var(--bg-card);
  border-radius: 0.75rem;
  border: 1px solid var(--border-light);
}

.gs-section h2 {
  border-bottom: 1px solid var(--border-light);
  padding-bottom: 0.75rem;
  margin-bottom: 1.5rem;
}

.gs-tutorial-container {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.gs-tutorial-step {
  background-color: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: 0.5rem;
  padding: 1.5rem;
  transition: all 0.2s ease;
}

.gs-tutorial-step:hover {
  border-color: var(--primary-light);
  box-shadow: 0 5px 15px -3px rgba(0, 0, 0, 0.1);
}

.gs-tutorial-step-header {
  display: flex;
  margin-bottom: 1rem;
}

.gs-tutorial-step-number {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background-color: var(--primary-bg);
  color: var(--primary);
  font-weight: bold;
  margin-right: 1rem;
  flex-shrink: 0;
}

.gs-tutorial-step-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.gs-tutorial-step-subtitle {
  font-size: 0.875rem;
  color: var(--text-tertiary);
}

/* Responsive adjustments for Getting Started page */
@media (max-width: 768px) {
  .doc-step {
    flex-direction: column;
  }
  
  .doc-step-number {
    margin-bottom: 0.5rem;
  }
  
  .doc-step:not(:last-child)::after {
    left: 1rem;
    top: 2rem;
  }
  
  .gs-tutorial-step-header {
    flex-direction: column;
  }
  
  .gs-tutorial-step-number {
    margin-bottom: 0.5rem;
  }
  
  .doc-card-grid {
    grid-template-columns: 1fr;
  }
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Enhanced Code Syntax Highlighting for Getting Started */
.doc-code-wrapper {
  position: relative;
  margin: 1.5rem 0;
}

.doc-code-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 1rem;
  background-color: var(--code-bg);
  border: 1px solid var(--border);
  border-bottom: none;
  border-top-left-radius: 0.5rem;
  border-top-right-radius: 0.5rem;
  font-family: monospace;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.doc-code-actions {
  display: flex;
  gap: 0.5rem;
}

.doc-code-action {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-tertiary);
  transition: color 0.2s;
  padding: 0.25rem;
}

.doc-code-action:hover {
  color: var(--primary);
}

pre.doc-code {
  margin-top: 0;
  border-top-left-radius: 0;
  border-top-right-radius: 0;
}

.doc-code-copied {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  background-color: var(--bg-card);
  color: var(--primary);
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.3s, transform 0.3s;
}

.doc-code-copied.show {
  opacity: 1;
  transform: translateY(0);
}

/* Enhanced Image Layouts */
.doc-image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin: 1.5rem 0;
}

.doc-image-caption {
  text-align: center;
  font-size: 0.875rem;
  color: var(--text-tertiary);
  margin-top: 0.5rem;
}

/* Enhanced Interactive Elements */
.doc-interactive-demo {
  border: 1px solid var(--border-light);
  border-radius: 0.5rem;
  overflow: hidden;
  margin: 1.5rem 0;
}

.doc-interactive-demo-header {
  background-color: var(--bg-card);
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.doc-interactive-demo-title {
  font-weight: 600;
}

.doc-interactive-demo-content {
  padding: 1.5rem;
}
