/* ============================================
   MONTPC LEGAL PAGES - PREMIUM DESIGN
   Matching main site's elegant aesthetic
   ============================================ */

body {
  font-family: var(--font-primary);
  background: linear-gradient(180deg, var(--grey-50) 0%, var(--white) 100%);
  color: var(--grey-900);
  line-height: var(--line-height-relaxed);
  margin: 0;
  padding: 0;
  min-height: 100vh;
}

/* ===== HEADER - MATCHING MAIN SITE ===== */

.header {
  background: var(--white);
  border-bottom: 1px solid var(--grey-200);
  padding: 20px 0;
  position: sticky;
  top: 0;
  z-index: var(--z-sticky);
  backdrop-filter: blur(8px);
  background: rgba(255, 255, 255, 0.95);
}

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

.logo {
  font-size: 22px;
  font-weight: 600;
  color: var(--grey-900);
  text-decoration: none;
  letter-spacing: var(--letter-spacing-tight);
  transition: opacity 0.2s ease;
}

.logo:hover {
  opacity: 0.8;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--grey-600);
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  padding: 10px 16px;
  border-radius: 8px;
  transition: all 0.2s ease;
  position: relative;
}

.back-link::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--grey-100);
  border-radius: 8px;
  opacity: 0;
  transition: opacity 0.2s ease;
  z-index: -1;
}

.back-link:hover::before {
  opacity: 1;
}

.back-link:hover {
  color: var(--orange-500);
  transform: translateX(-2px);
}

/* ===== MAIN CONTENT - ELEGANT LAYOUT ===== */

.legal-container {
  max-width: 800px;
  margin: 80px auto 120px;
  padding: 0 24px;
}

.legal-header {
  text-align: center;
  margin-bottom: 64px;
  padding-bottom: 32px;
  position: relative;
}

.legal-header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--orange-500), transparent);
  border-radius: 2px;
}

.legal-header h1 {
  font-size: 48px;
  font-weight: 600;
  color: var(--grey-900);
  margin-bottom: 16px;
  line-height: var(--line-height-tight);
  letter-spacing: var(--letter-spacing-tight);
}

.last-updated {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--grey-600);
  background: var(--grey-100);
  padding: 8px 16px;
  border-radius: 20px;
  margin-top: 16px;
}

.last-updated::before {
  content: '📅';
  font-size: 16px;
}

/* ===== SECTION STYLING ===== */

.legal-section {
  margin-bottom: 48px;
  padding: 32px;
  background: var(--white);
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
  border: 1px solid var(--grey-200);
  transition: all 0.3s ease;
}

.legal-section:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
  transform: translateY(-2px);
}

/* Typography - SCOPED to legal content only */

.legal-container h2 {
  font-size: 28px;
  font-weight: 600;
  color: var(--grey-900);
  margin-top: 0;
  margin-bottom: 20px;
  line-height: var(--line-height-tight);
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
  gap: 12px;
}

.legal-container h2::before {
  content: '';
  width: 4px;
  height: 28px;
  background: var(--orange-500);
  border-radius: 2px;
  flex-shrink: 0;
}

.legal-container h3 {
  font-size: 20px;
  font-weight: 600;
  color: var(--grey-900);
  margin-top: 28px;
  margin-bottom: 12px;
  line-height: 1.3;
}

.legal-container p {
  margin-bottom: 20px;
  color: var(--grey-600);
  font-size: 16px;
  line-height: 1.7;
}

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

/* Lists - SCOPED to legal content only */

.legal-container ul {
  margin: 20px 0;
  padding-left: 0;
  list-style: none;
}

.legal-container li {
  margin-bottom: 12px;
  color: var(--grey-600);
  font-size: 16px;
  line-height: 1.6;
  padding-left: 28px;
  position: relative;
}

.legal-container li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--orange-500);
  font-weight: 600;
  font-size: 18px;
}

/* Links - SCOPED to legal content only */

.legal-container a {
  color: var(--orange-500);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.2s ease;
  position: relative;
}

.legal-container a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--orange-500);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.legal-container a:hover {
  color: var(--orange-600);
}

.legal-container a:hover::after {
  opacity: 1;
}

/* Strong text - SCOPED to legal content only */

.legal-container strong {
  color: var(--grey-900);
  font-weight: 600;
}

/* ===== SPECIAL BOXES ===== */

.highlight-box {
  background: linear-gradient(135deg, var(--orange-50) 0%, #FFF7F5 100%);
  border: 1px solid var(--orange-500);
  border-left: 4px solid var(--orange-500);
  padding: 24px;
  margin: 32px 0;
  border-radius: 12px;
  position: relative;
  overflow: hidden;
}

.highlight-box::before {
  content: '💡';
  position: absolute;
  top: 16px;
  right: 16px;
  font-size: 32px;
  opacity: 0.3;
}

.highlight-box p {
  margin-bottom: 12px;
}

.highlight-box p:last-child {
  margin-bottom: 0;
}

.warning-box {
  background: linear-gradient(135deg, #FFF7F5 0%, #FFE5DF 100%);
  border: 1px solid var(--orange-500);
  border-left: 4px solid var(--orange-600);
  padding: 24px;
  margin: 32px 0;
  border-radius: 12px;
  position: relative;
  overflow: hidden;
}

.warning-box::before {
  content: '⚠️';
  position: absolute;
  top: 16px;
  right: 16px;
  font-size: 32px;
  opacity: 0.3;
}

.warning-box p {
  margin-bottom: 12px;
}

.warning-box p:last-child {
  margin-bottom: 0;
}

.warning-box strong {
  color: var(--orange-600);
}

/* ===== FOOTER ===== */
/* Footer styles loaded from footer.css - no need to duplicate here */

#footer-placeholder {
  margin-top: 80px;
}

/* ===== TABLE OF CONTENTS (Optional Enhancement) ===== */

.toc {
  background: var(--white);
  border: 1px solid var(--grey-200);
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 48px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.toc-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--grey-900);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.toc-title::before {
  content: '📋';
}

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

.toc li {
  padding-left: 0;
  margin-bottom: 8px;
}

.toc li::before {
  display: none;
}

.toc a {
  color: var(--grey-600);
  font-size: 15px;
  font-weight: 500;
}

.toc a:hover {
  color: var(--orange-500);
}

/* ===== RESPONSIVE ===== */

@media (max-width: 768px) {
  .legal-header h1 {
    font-size: 36px;
  }

  .legal-container h2 {
    font-size: 24px;
  }

  .legal-container h3 {
    font-size: 18px;
  }

  .legal-container {
    margin: 48px auto 80px;
    padding: 0 20px;
  }

  .legal-header {
    margin-bottom: 48px;
    padding-bottom: 24px;
  }

  .legal-section {
    padding: 24px 20px;
    margin-bottom: 32px;
  }

  .highlight-box,
  .warning-box {
    padding: 20px;
    margin: 24px 0;
  }

  .highlight-box::before,
  .warning-box::before {
    font-size: 24px;
    top: 12px;
    right: 12px;
  }
}

/* ===== PRINT STYLES ===== */

@media print {
  .header,
  .footer,
  .back-link {
    display: none;
  }

  .legal-section {
    box-shadow: none;
    border: 1px solid var(--grey-300);
    page-break-inside: avoid;
  }

  body {
    background: white;
  }
}
