/* CSS Custom Variables for Light & Dusky Dark Mode */
:root {
  --bg-primary: #f8fafc;
  --bg-card: #ffffff;
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --accent-color: #6366f1;
  --accent-gradient: linear-gradient(135deg, #6366f1 0%, #a855f7 100%);
  --accent-glow: rgba(99, 102, 241, 0.15);
  --border-color: #e2e8f0;
  --header-bg: rgba(255, 255, 255, 0.8);
  --mark-bg: rgba(253, 224, 71, 0.4);
  --mark-text: #0f172a;
  --blob-1-color: rgba(99, 102, 241, 0.08);
  --blob-2-color: rgba(168, 85, 247, 0.08);
  --shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.04);
  --card-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.05);
}

body.dark-mode {
  --bg-primary: #090d16;
  --bg-card: #121824;
  --text-primary: #f8fafc;
  --text-secondary: #94a3b8;
  --accent-color: #818cf8;
  --accent-gradient: linear-gradient(135deg, #818cf8 0%, #c084fc 100%);
  --accent-glow: rgba(129, 140, 248, 0.25);
  --border-color: #1e293b;
  --header-bg: rgba(18, 24, 36, 0.8);
  --mark-bg: rgba(129, 140, 248, 0.35);
  --mark-text: #ffffff;
  --blob-1-color: rgba(129, 140, 248, 0.15);
  --blob-2-color: rgba(192, 132, 252, 0.12);
  --shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.3);
  --card-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.45);
}

/* Core Settings */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Poppins', 'Outfit', sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-size: 15px;
  line-height: 1.7;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* Background Blobs for Visual Interest */
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  z-index: -1;
  pointer-events: none;
  transition: background-color 0.3s ease;
}

.blob-1 {
  width: 500px;
  height: 500px;
  background-color: var(--blob-1-color);
  top: -100px;
  right: -100px;
}

.blob-2 {
  width: 450px;
  height: 450px;
  background-color: var(--blob-2-color);
  top: 600px;
  left: -150px;
}

/* Glassmorphic Sticky Header */
.glass-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: var(--header-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  padding: 12px 0;
  transition: background 0.3s ease, border-bottom 0.3s ease;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-link {
  display: flex;
  align-items: center;
  text-decoration: none;
  transition: transform 0.2s ease;
}

.logo-link:hover {
  transform: scale(1.02);
}

.brand-logo {
  height: 60px;
  width: auto;
  border-radius: 4px;
  object-fit: contain;
  transition: filter 0.3s ease;
}

/* Logo inversion for dark mode to make the black logo readable on dark backgrounds */
body.dark-mode .brand-logo {
  filter: invert(1) brightness(1.8);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

/* Search Box Styling */
.search-box {
  position: relative;
  display: flex;
  align-items: center;
}

.search-box input {
  padding: 8px 16px 8px 36px;
  border-radius: 30px;
  border: 1px solid var(--border-color);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
  width: 220px;
  transition: all 0.3s ease;
}

.search-box input:focus {
  border-color: var(--accent-color);
  box-shadow: 0 0 0 3px var(--accent-glow);
  width: 280px;
}

.search-icon {
  position: absolute;
  left: 12px;
  color: var(--text-secondary);
  pointer-events: none;
}

/* Theme Button Toggler */
.theme-btn {
  background: none;
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  transition: all 0.2s ease;
}

.theme-btn:hover {
  background-color: var(--border-color);
  transform: scale(1.05);
}

/* Switch visible icons depending on class */
body.light-mode .sun-icon {
  display: none;
}
body.dark-mode .moon-icon {
  display: none;
}

/* Hero Section */
.hero-section {
  padding-top: 170px;
  padding-bottom: 50px;
  position: relative;
}

.badge-pill {
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--accent-color);
  background-color: var(--accent-glow);
  padding: 6px 16px;
  border-radius: 20px;
  display: inline-block;
  margin-bottom: 16px;
}

.hero-title {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  font-size: 48px;
  letter-spacing: -1px;
  margin-bottom: 8px;
}

.hero-subtitle {
  color: var(--text-secondary);
  font-size: 16px;
}

/* Layout & Columns */
.main-content {
  padding-bottom: 100px;
}

.sticky-sidebar {
  position: sticky;
  top: 130px;
}

.toc-title {
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 1.5px;
  color: var(--text-secondary);
  margin-bottom: 15px;
  text-transform: uppercase;
}

.toc-nav {
  display: flex;
  flex-direction: column;
  border-left: 2px solid var(--border-color);
  padding-left: 0;
}

.toc-link {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 16px;
  border-left: 2px solid transparent;
  margin-left: -2px;
  transition: all 0.2s ease;
}

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

.toc-link.active {
  color: var(--accent-color);
  font-weight: 600;
  border-left-color: var(--accent-color);
  background-color: var(--accent-glow);
  border-top-right-radius: 6px;
  border-bottom-right-radius: 6px;
}

/* Policy Content Card */
.content-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 40px;
  box-shadow: var(--card-shadow);
  transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.lead-text {
  font-size: 18px;
  line-height: 1.8;
  color: var(--text-primary);
}

.section-divider {
  border-color: var(--border-color);
  opacity: 1;
  margin: 35px 0;
}

.policy-section {
  scroll-margin-top: 170px;
}

.section-heading {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 26px;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
}

.subsection-heading {
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 18px;
  margin-top: 25px;
  margin-bottom: 15px;
  color: var(--accent-color);
}

/* Info Cards for Lists */
.info-box {
  display: flex;
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 20px;
  gap: 18px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.info-box:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: var(--accent-color);
}

.info-box-icon {
  background-color: var(--accent-glow);
  color: var(--accent-color);
  border-radius: 10px;
  padding: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  flex-shrink: 0;
}

.info-box-content h5 {
  font-weight: 600;
  font-size: 16px;
  margin-bottom: 6px;
}

.info-box-content p {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 0;
}

/* Custom Bullet List */
.custom-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 15px;
}

.custom-list li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.bullet-point {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--accent-color);
  flex-shrink: 0;
  margin-top: 10px;
}

/* Contact inner styles */
.contact-card-inner {
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 24px;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 16px;
}

.contact-icon {
  background-color: var(--accent-glow);
  color: var(--accent-color);
  border-radius: 50%;
  width: 42px;
  height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-details h6 {
  font-weight: 600;
  font-size: 15px;
  margin-bottom: 3px;
}

.contact-details a {
  color: var(--accent-color);
  text-decoration: none;
  font-weight: 500;
  font-size: 14px;
}

.contact-details a:hover {
  text-decoration: underline;
}

/* Footer style */
.footer {
  border-top: 1px solid var(--border-color);
  padding: 30px 0;
  background-color: var(--bg-card);
  color: var(--text-secondary);
  font-size: 14px;
}

/* Search Highlight style */
mark.search-highlight {
  background-color: var(--mark-bg);
  color: var(--mark-text);
  border-radius: 3px;
  padding: 0 4px;
}

/* Back to Top button */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background-color: var(--accent-color);
  color: #fff;
  border: none;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.3);
  transition: all 0.3s ease;
  z-index: 99;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background-color: #4f46e5;
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(99, 102, 241, 0.4);
}

/* Scrollbar styles */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-secondary);
}

/* Responsive adjustments */
@media (max-width: 991.98px) {
  .hero-title {
    font-size: 38px;
  }
  .content-card {
    padding: 30px;
  }
}

@media (max-width: 767.98px) {
  .hero-section {
    padding-top: 150px;
    padding-bottom: 30px;
  }
  .hero-title {
    font-size: 32px;
  }
  .search-box input {
    width: 150px;
  }
  .search-box input:focus {
    width: 180px;
  }
  .content-card {
    padding: 20px;
    border-radius: 12px;
  }
}
