/* Legal Pages Stylesheet - Privacy Policy, Terms of Service, etc. */

/* Page Container */
.legal-page {
  min-height: 100vh;
  background: #f3f0ff;
  padding-top: 100px;
  display: block;
  position: relative;
}

/* Sidebar Navigation - Truly Fixed */
.legal-sidebar {
  position: fixed !important;
  left: 0 !important;
  top: 100px !important;
  width: 280px;
  height: calc(100vh - 100px);
  background: #f8f5ff;
  border-right: 1px solid rgba(167, 139, 250, 0.2);
  padding: 2rem 0;
  overflow-y: auto;
  overflow-x: hidden;
  z-index: 999;
}

/* Custom scrollbar for sidebar */
.legal-sidebar::-webkit-scrollbar {
  width: 6px;
}

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

.legal-sidebar::-webkit-scrollbar-thumb {
  background: rgba(167, 139, 250, 0.3);
  border-radius: 3px;
}

.legal-sidebar::-webkit-scrollbar-thumb:hover {
  background: rgba(167, 139, 250, 0.5);
}

.legal-sidebar h3 {
  color: rgba(0, 0, 0, 0.5);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 0 1.5rem;
  margin-bottom: 1rem;
}

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

.legal-sidebar nav li {
  margin: 0;
}

.legal-sidebar nav a {
  display: block;
  color: rgba(0, 0, 0, 0.7);
  text-decoration: none;
  padding: 0.75rem 1.5rem;
  font-size: 0.9rem;
  font-weight: 500;
  border-left: 3px solid transparent;
  transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
  position: relative;
  background: transparent;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.legal-sidebar nav a:hover {
  color: #A78BFA;
  background: rgba(167, 139, 250, 0.05);
  border-left-color: #A78BFA;
}

.legal-sidebar nav a.active {
  color: #A78BFA;
  background: rgba(167, 139, 250, 0.1);
  border-left-color: #A78BFA;
  font-weight: 600;
}

/* Main Content Area */
.legal-main {
  margin-left: 280px;
  width: calc(100% - 280px);
  min-height: 100vh;
  position: relative;
  background: #faf8ff;
}

/* Smooth scrolling for content */
.legal-main {
  scroll-behavior: smooth;
}

/* Header Section with Flowing Animation */
.legal-header {
  text-align: left;
  padding: 1rem 2rem;
  background: #faf8ff;
  border-bottom: 1px solid rgba(167, 139, 250, 0.15);
  position: relative;
  overflow: hidden;
}

.legal-header h1 {
  font-size: clamp(2rem, 5vw, 2.75rem);
  font-weight: 700;
  margin-bottom: 0.5rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: #1a1a1a;
  position: relative;
  z-index: 1;
}

/* Section number in header - styled as aurora gradient text with animation */
.legal-header h1 .section-number {
  display: inline;
  background: linear-gradient(135deg, #A78BFA 0%, #8B5CF6 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 700;
}

.legal-header .last-updated {
  font-size: 0.875rem;
  color: #666;
  font-style: normal;
  opacity: 0.85;
  font-weight: 400;
  position: relative;
  z-index: 1;
}

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

/* Content Container */
.legal-content {
  max-width: 100%;
  margin: 0;
  padding: 0;
  padding-bottom: 3rem;
}

.legal-content-card {
  background: transparent;
  border-radius: 0;
  box-shadow: none;
  padding: 1.5rem 2rem 3rem 2rem;
  margin-top: 0;
  border: none;
  max-width: 1400px;
}

/* Section Styling */
.legal-section {
  margin-bottom: 2rem;
}

.legal-section:last-of-type {
  margin-bottom: 2rem;
}

/* Section Headings */
.legal-section h2 {
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  font-weight: 600;
  color: #1a1a1a;
  margin-bottom: 0.75rem;
  line-height: 1.3;
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
}

.legal-section h2 .section-number {
  display: inline-block;
  background: linear-gradient(135deg, #A78BFA 0%, #8B5CF6 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 700;
  flex-shrink: 0;
}

.legal-section h3 {
  font-size: clamp(1.125rem, 2.5vw, 1.4rem);
  font-weight: 600;
  color: #1a1a1a;
  margin-top: 1.25rem;
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

.legal-section h3:first-child {
  margin-top: 0;
}

/* Paragraph Styling */
.legal-section p {
  color: #4a4a4a;
  line-height: 1.6;
  font-size: clamp(0.95rem, 2vw, 1.0625rem);
  margin-bottom: 0.75rem;
}

.legal-section p:last-child {
  margin-bottom: 0;
}

.legal-section p strong {
  color: #1a1a1a;
  font-weight: 600;
}

/* List Styling */
.legal-section ul,
.legal-section ol {
  color: #4a4a4a;
  line-height: 1.6;
  font-size: clamp(0.95rem, 2vw, 1.0625rem);
  padding-left: 2rem;
  margin-bottom: 0.75rem;
}

.legal-section li {
  margin-bottom: 0.5rem;
  padding-left: 0.5rem;
}

.legal-section li:last-child {
  margin-bottom: 0;
}

.legal-section li strong {
  color: #1a1a1a;
  font-weight: 600;
}

/* Custom bullet style */
.legal-section ul li {
  position: relative;
}

.legal-section ul li::marker {
  color: var(--color-primary, #A78BFA);
}

/* Links in content */
.legal-section a {
  color: var(--color-primary, #A78BFA);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.2s ease;
  border-bottom: 1px solid transparent;
}

.legal-section a:hover {
  color: #8B5CF6;
  border-bottom-color: currentColor;
}

.legal-section a:focus {
  outline: 2px solid var(--color-primary, #A78BFA);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Contact Information Block */
.contact-info {
  background: linear-gradient(135deg, rgba(167, 139, 250, 0.08) 0%, rgba(139, 92, 246, 0.05) 100%);
  padding: 1rem;
  border-radius: var(--radius-lg);
  border-left: 4px solid var(--color-primary, #A78BFA);
  margin-top: 0.75rem;
}

.contact-info p {
  color: #1a1a1a;
}

/* Back to Home Button */
.legal-actions {
  margin-top: 2rem;
  margin-bottom: 2rem;
  padding-top: 1.5rem;
  padding-bottom: 1rem;
  border-top: 1px solid rgba(0, 0, 0, 0.1);
  text-align: center;
}

/* Mobile Responsive */
@media (max-width: 1024px) {
  .legal-sidebar {
    transform: translateX(-100%);
    transition: transform 0.3s ease;
  }

  .legal-sidebar.active {
    transform: translateX(0);
  }

  .legal-main {
    margin-left: 0;
    width: 100%;
  }

  .legal-page {
    padding-top: 80px;
  }

  .legal-sidebar {
    top: 80px;
    height: calc(100vh - 80px);
  }
}

@media (max-width: 768px) {
  .legal-header {
    padding: var(--space-xl) 0 var(--space-lg);
  }

  .legal-header h1 {
    text-align: center;
    line-height: 1.3;
  }

  .legal-content {
    padding: 0 var(--space-md);
  }

  .legal-content-card {
    padding: clamp(1.5rem, 4vw, 2rem);
    margin-top: 1.5rem;
  }

  .legal-section {
    margin-bottom: 2.5rem;
  }

  .legal-section h2 {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }

  .legal-section ul,
  .legal-section ol {
    padding-left: 1.5rem;
  }

  .legal-sidebar {
    width: 260px;
  }
}

/* Print Styles */
@media print {
  .legal-page {
    padding-top: 0;
  }

  .legal-sidebar {
    display: none;
  }

  .legal-main {
    margin-left: 0;
    width: 100%;
  }

  .legal-header {
    background: none;
  }

  .legal-content-card {
    box-shadow: none;
    border: 1px solid #ddd;
  }

  .legal-section a {
    color: #000;
    text-decoration: underline;
  }
}

/* Dark Mode Support (if needed) */

/* Respect reduced motion preferences */
@media (prefers-reduced-motion: reduce) {
  .legal-header,
  .legal-header::before,
  .legal-header::after,
  .legal-header h1,
  .legal-header h1 .section-number,
  .legal-header .last-updated {
    animation: none !important;
  }
  
  .legal-header {
    background: linear-gradient(180deg, rgba(245, 245, 250, 0.95) 0%, rgba(237, 233, 254, 0.8) 100%);
  }
}
