/* ============================================
   TERMS PAGE - OPTIMIZED CSS
   Following 2026 Best Practices
   ============================================ */

/* CSS Variables for Consistency */
:root {
  --terms-bg: #F5F7FA;
  --card-bg: #FFFFFF;
  --hero-gradient: linear-gradient(135deg, var(--primary-color) 0%, #16A085 100%);
  --highlight-bg: #FFF9E6;
  --highlight-border: #F39C12;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
  --transition-speed: 0.3s;
  --border-radius: 12px;
  --spacing-sm: 1rem;
  --spacing-md: 1.5rem;
  --spacing-lg: 2.5rem;
  --max-content-width: 900px;
}

/* Hero Section */
.terms-hero {
  background: var(--hero-gradient);
  padding: 4rem 0 3rem;
  color: white;
  text-align: center;
}

.terms-hero h1 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: var(--spacing-sm);
  font-family: 'Poppins', sans-serif;
}

.terms-hero p {
  font-size: clamp(1rem, 2vw, 1.1rem);
  opacity: 0.95;
  margin-bottom: 0.5rem;
}

.terms-hero .last-updated {
  font-size: 0.9rem;
  opacity: 0.8;
  margin-top: var(--spacing-sm);
}

/* Content Area */
.terms-content {
  padding: 4rem 0;
  background: var(--terms-bg);
}

.terms-wrapper {
  max-width: var(--max-content-width);
  margin: 0 auto;
}

/* Section Cards - Optimized Performance */
.terms-section {
  background: var(--card-bg);
  border-radius: var(--border-radius);
  padding: var(--spacing-lg);
  margin-bottom: 2rem;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-speed) ease, 
              box-shadow var(--transition-speed) ease;
  will-change: transform;
}

.terms-section:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Typography */
.terms-section h2 {
  color: var(--primary-color);
  font-size: clamp(1.3rem, 2.5vw, 1.5rem);
  font-weight: 600;
  margin-bottom: var(--spacing-md);
  font-family: 'Poppins', sans-serif;
  border-bottom: 2px solid var(--accent-color);
  padding-bottom: 0.75rem;
}

.terms-section h3 {
  color: var(--text-dark);
  font-size: 1.1rem;
  font-weight: 600;
  margin-top: var(--spacing-md);
  margin-bottom: var(--spacing-sm);
}

.terms-section p {
  color: var(--text-dark);
  line-height: 1.8;
  margin-bottom: var(--spacing-sm);
  font-size: 1rem;
}

/* Lists - DRY Principle */
.terms-section ul {
  margin-left: 1.5rem;
  margin-bottom: var(--spacing-sm);
}

.terms-section ul li {
  color: var(--text-dark);
  line-height: 1.8;
  margin-bottom: 0.5rem;
  position: relative;
  padding-left: 0.5rem;
}

.terms-section ul li::marker {
  color: var(--accent-color);
}

/* Links */
.terms-section a {
  color: var(--secondary-color);
  text-decoration: none;
  transition: opacity var(--transition-speed) ease;
}

.terms-section a:hover {
  opacity: 0.8;
  text-decoration: underline;
}

/* Strong Text */
.terms-section strong {
  color: var(--primary-color);
  font-weight: 600;
}

/* Code Blocks */
.terms-section code {
  background: var(--terms-bg);
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  font-family: 'Courier New', monospace;
  color: var(--secondary-color);
  font-size: 0.9rem;
}

/* Highlight Box - Reusable Component */
.highlight-box {
  background: var(--highlight-bg);
  border-left: 4px solid var(--highlight-border);
  padding: var(--spacing-md);
  border-radius: 8px;
  margin: var(--spacing-md) 0;
}

.highlight-box p {
  margin-bottom: 0;
}

.highlight-box strong {
  color: var(--highlight-border);
}

/* Contact Box - Fixed Color Issue */
.contact-box {
    background: linear-gradient(135deg, #1F3C88 0%, #16A085 100%);
    color: white;
    padding: 2rem;
    border-radius: var(--border-radius);
    margin-top: 2rem;
  }
  
  .contact-box h3 {
    color: white !important;
    margin-bottom: var(--spacing-sm);
    font-size: 1.3rem;
  }
  
  .contact-box ul {
    list-style: none;
    margin-left: 0;
  }
  
  .contact-box ul li {
    color: white !important;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
  }
  
  .contact-box ul li strong {
    color: white !important;
    font-weight: 600;
  }
  
  .contact-box svg {
    flex-shrink: 0;
    fill: white;
  }
  
  .contact-box a {
    color: #FFD93D !important;
    text-decoration: none;
    transition: opacity var(--transition-speed) ease;
    font-weight: 500;
  }
  
  .contact-box a:hover {
    opacity: 0.85;
    text-decoration: underline;
  }
  
  /* Mobile responsiveness for contact box */
  @media (max-width: 768px) {
    .contact-box ul li {
      flex-direction: row;
      align-items: center;
      gap: 0.75rem;
    }
  }
  
/* Acknowledgment Banner - Fixed Color Issue */
.acknowledgment-banner {
    background: linear-gradient(135deg, #16A085 0%, #1F3C88 100%);
    color: white;
    padding: 2rem;
    border-radius: var(--border-radius);
    text-align: center;
    margin-top: 2rem;
  }
  
  .acknowledgment-banner svg {
    margin-bottom: var(--spacing-sm);
    fill: white;
  }
  
  .acknowledgment-banner h4 {
    color: white !important;
    margin-bottom: var(--spacing-sm);
    font-size: 1.3rem;
    font-weight: 600;
  }
  
  .acknowledgment-banner p {
    color: white !important;
    margin-bottom: 0;
    font-size: 1rem;
    opacity: 0.95;
    line-height: 1.8;
  }
  

/* Responsive Design - Mobile First Approach */
@media (max-width: 768px) {
  .terms-hero {
    padding: 3rem 0 2rem;
  }

  .terms-section {
    padding: var(--spacing-md);
  }

  .terms-content {
    padding: 2rem 0;
  }

  .contact-box ul li {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
}

/* Performance Optimizations */
@media (prefers-reduced-motion: reduce) {
  .terms-section {
    transition: none;
  }
  
  .terms-section a {
    transition: none;
  }
}

/* Print Styles */
@media print {
  .terms-hero {
    background: white;
    color: black;
    padding: 1rem 0;
  }

  .terms-section {
    box-shadow: none;
    page-break-inside: avoid;
  }

  .contact-box {
    background: white;
    color: black;
    border: 1px solid #ccc;
  }
}
