/* ==========================================================================
   SplitTrip Docs Page Styles
   ========================================================================== */

/* Layout */
.docs-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  max-width: 1280px;
  margin: 0 auto;
  padding-top: calc(var(--nav-height) + 40px);
  padding-bottom: 80px;
  min-height: 100vh;
  gap: 0;
  position: relative;
  z-index: 5;
}

/* Sidebar */
.docs-sidebar {
  position: sticky;
  top: calc(var(--nav-height) + 24px);
  height: fit-content;
  padding: 0 24px 40px 24px;
  border-right: 1px solid var(--border-light);
}

.sidebar-inner {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.sidebar-section {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.sidebar-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-light);
  margin-bottom: 8px;
  display: block;
}

.sidebar-link {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.875rem;
  font-weight: 500;
  padding: 5px 10px;
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
  display: block;
}

.sidebar-link:hover {
  color: var(--text-main);
  background-color: var(--bg-secondary);
}

.sidebar-link.active {
  color: var(--text-main);
  background-color: var(--bg-secondary);
  font-weight: 600;
}

/* Main Content Area */
.docs-content {
  padding: 0 48px 60px 48px;
  max-width: 820px;
}

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

.docs-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.docs-breadcrumb a {
  text-decoration: none;
  color: var(--text-muted);
  transition: color 0.2s ease;
}

.docs-breadcrumb a:hover {
  color: var(--text-main);
}

.docs-title {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--text-main);
  margin-bottom: 12px;
  line-height: 1.15;
}

.docs-lead {
  font-size: 1.1rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 20px;
}

.docs-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
  color: var(--text-light);
}

.docs-meta-divider {
  opacity: 0.5;
}

.docs-version-tag {
  background-color: var(--bg-accent-light);
  border: 1px solid rgba(86, 171, 131, 0.25);
  color: var(--accent-hover);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
}

/* Divider */
.docs-divider {
  border: none;
  border-top: 1px solid var(--border-light);
  margin: 48px 0;
}

/* Sections */
.docs-section {
  margin-bottom: 0;
}

.docs-section > h2 {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 12px;
  color: var(--text-main);
}

.docs-section > p {
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 28px;
}

/* Cards */
.docs-card {
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-bottom: 20px;
  background-color: #ffffff;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.3s ease;
}

.docs-card:hover {
  box-shadow: var(--shadow-md);
}

.docs-card-header {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 20px;
}

.docs-card-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--text-muted);
}

.docs-card-header h3 {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
  color: var(--text-main);
}

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

/* Ordered steps inside cards */
.docs-steps {
  padding-left: 20px;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.docs-steps li {
  font-size: 0.9rem;
  color: var(--text-main);
  line-height: 1.55;
}

.docs-steps a {
  color: var(--accent-hover);
  text-decoration: none;
  font-weight: 600;
}

.docs-steps a:hover {
  text-decoration: underline;
}

/* Callouts */
.docs-callout {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-left: 3px solid var(--accent-color);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  font-size: 0.875rem;
  color: var(--text-main);
  line-height: 1.55;
  margin-bottom: 20px;
}

.docs-callout-warning {
  border-left-color: #f59e0b;
  background-color: #fffbeb;
}

.docs-callout a {
  color: var(--accent-hover);
  font-weight: 600;
  text-decoration: none;
}

/* Download button inside docs */
.docs-btn-download {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  background-color: var(--dark-btn-bg);
  color: #ffffff;
  font-size: 0.875rem;
  font-weight: 700;
  padding: 10px 20px;
  border-radius: var(--radius-pill);
  transition: all 0.2s ease;
}

.docs-btn-download:hover {
  background-color: var(--dark-btn-hover);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.docs-btn-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  border: 1.5px solid var(--text-main);
  color: var(--text-main);
  font-size: 0.875rem;
  font-weight: 700;
  padding: 10px 20px;
  border-radius: var(--radius-pill);
  transition: all 0.2s ease;
}

.docs-btn-outline:hover {
  background-color: var(--bg-secondary);
  transform: translateY(-1px);
}

/* Code inline */
code {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: 5px;
  padding: 2px 7px;
  font-size: 0.85em;
  font-family: 'Courier New', monospace;
  color: var(--text-main);
}

/* Feature Blocks */
.docs-feature-block {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  padding: 24px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
  margin-bottom: 12px;
  background-color: #ffffff;
  transition: box-shadow 0.2s ease;
}

.docs-feature-block:hover {
  box-shadow: var(--shadow-sm);
}

.docs-feature-icon {
  font-size: 1.6rem;
  flex-shrink: 0;
  width: 44px;
  text-align: center;
}

.docs-feature-block h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 6px;
  color: var(--text-main);
  letter-spacing: -0.02em;
}

.docs-feature-block p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* How It Works Steps Table */
.docs-steps-table {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.docs-step-row {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-light);
}

.docs-step-row:last-child {
  border-bottom: none;
}

.docs-step-row:hover {
  background-color: var(--bg-secondary);
}

.docs-step-badge {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--accent-color) 0%, var(--accent-hover) 100%);
  color: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.85rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.docs-step-row strong {
  display: block;
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--text-main);
}

.docs-step-row p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin: 0;
}

/* Security Grid */
.docs-security-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 28px;
}

.docs-security-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 18px 20px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  background-color: #ffffff;
}

.docs-security-icon {
  font-size: 1.3rem;
  flex-shrink: 0;
}

.docs-security-item strong {
  display: block;
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--text-main);
}

.docs-security-item p {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin: 0;
}

/* Specs Table */
.docs-specs-table {
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.docs-spec-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 20px;
  font-size: 0.875rem;
  border-bottom: 1px solid var(--border-light);
}

.docs-spec-row:last-child {
  border-bottom: none;
}

.docs-spec-row span:first-child {
  color: var(--text-muted);
  font-weight: 500;
}

.docs-spec-row span:last-child {
  color: var(--text-main);
  font-weight: 700;
}

.docs-spec-highlight {
  color: var(--accent-hover) !important;
  background-color: var(--bg-accent-light);
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(86, 171, 131, 0.2);
}

/* Changelog */
.docs-changelog-entry {
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 28px;
  background-color: #ffffff;
}

.docs-changelog-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}

.docs-changelog-date {
  font-size: 0.85rem;
  color: var(--text-light);
}

.docs-changelog-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 24px;
}

.docs-changelog-list li {
  font-size: 0.9rem;
  color: var(--text-main);
  padding-left: 4px;
}

.docs-release-link {
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--accent-hover);
  transition: color 0.2s ease;
}

.docs-release-link:hover {
  color: var(--accent-color);
}

/* Responsive */
@media (max-width: 1024px) {
  .docs-layout {
    grid-template-columns: 1fr;
    padding-top: calc(var(--nav-height) + 24px);
  }

  .docs-sidebar {
    display: none;
  }

  .docs-content {
    padding: 0 24px 60px 24px;
    max-width: 100%;
  }

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

@media (max-width: 768px) {
  .docs-title {
    font-size: 1.8rem;
  }

  .docs-meta {
    flex-wrap: wrap;
    gap: 6px;
  }

  .docs-feature-block {
    flex-direction: column;
    gap: 12px;
  }
}
