@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800&display=swap');

:root {
  --bg-color: #fafbfc;
  --surface-color: #ffffff;
  --primary-color: #0fa37f; /* Beautiful Emerald/Teal brand color */
  --primary-hover: #0c8c6d;
  --primary-light: #e6f7f3;
  --primary-glow: rgba(15, 163, 127, 0.12);
  --text-primary: #111827; /* Dark slate */
  --text-secondary: #4b5563; /* Cool gray */
  --text-light: #9ca3af; /* Light gray */
  --border-color: #e5e7eb;
  --border-hover: #d1d5db;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.04), 0 4px 6px -2px rgba(0, 0, 0, 0.02);
  --radius-lg: 16px;
  --radius-md: 12px;
  --radius-sm: 8px;
  --font-sans: "Inter", sans-serif;
  --font-heading: "Outfit", sans-serif;
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s ease;
}

/* Reset & Global */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-color);
  color: var(--text-primary);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Scroll Progress Bar */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-color), #34d399);
  z-index: 1100;
  width: 0%;
  transition: width 0.1s ease-out;
}

/* Sticky Header */
.sticky-header {
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  z-index: 1000;
  padding: 0.85rem 0;
  transition: all var(--transition-normal);
}

.sticky-header.scrolled {
  background: rgba(255, 255, 255, 0.95);
  box-shadow: var(--shadow-sm);
  padding: 0.75rem 0;
}

.header-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--text-primary);
  transition: opacity var(--transition-fast);
}

.logo-container:hover {
  opacity: 0.9;
}

.logo-text {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.01em;
  background: linear-gradient(135deg, var(--text-primary) 30%, var(--primary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.logo-badge {
  background-color: var(--primary-light);
  color: var(--primary-color);
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.15rem 0.45rem;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-left: 0.25rem;
}

.sticky-header nav {
  display: flex;
  gap: 0.5rem;
  background: #f3f4f6;
  padding: 0.25rem;
  border-radius: 9999px;
}

.sticky-header nav a {
  text-decoration: none;
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.875rem;
  padding: 0.5rem 1.25rem;
  border-radius: 9999px;
  transition: all var(--transition-normal);
}

.sticky-header nav a:hover {
  color: var(--text-primary);
}

.sticky-header nav a.active {
  background: var(--surface-color);
  color: var(--primary-color);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
  font-weight: 600;
}

/* Page Layout */
.page-layout {
  max-width: 1200px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 4rem;
  position: relative;
}

/* Sidebar Table of Contents */
.sidebar-toc {
  display: none;
}

@media (min-width: 1024px) {
  .sidebar-toc {
    display: block;
    position: sticky;
    top: 6rem;
    height: fit-content;
    max-height: calc(100vh - 8rem);
    overflow-y: auto;
    padding-right: 1rem;
  }
}

.sidebar-toc::-webkit-scrollbar {
  width: 4px;
}

.sidebar-toc::-webkit-scrollbar-thumb {
  background-color: var(--border-color);
  border-radius: 4px;
}

.sidebar-toc h3 {
  font-family: var(--font-heading);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-light);
  margin-bottom: 1.25rem;
  font-weight: 700;
}

.sidebar-toc ul {
  list-style: none;
  border-left: 1.5px solid var(--border-color);
}

.sidebar-toc li a {
  display: block;
  padding: 0.55rem 0 0.55rem 1.25rem;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.875rem;
  border-left: 2.5px solid transparent;
  margin-left: -2px;
  transition: all var(--transition-normal);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-toc li a:hover {
  color: var(--text-primary);
  padding-left: 1.4rem;
}

.sidebar-toc li a.active {
  color: var(--primary-color);
  border-left-color: var(--primary-color);
  font-weight: 600;
  background: linear-gradient(90deg, var(--primary-glow) 0%, transparent 100%);
  border-top-right-radius: 6px;
  border-bottom-right-radius: 6px;
}

/* Main Content */
.main-content {
  max-width: 800px;
}

@media (max-width: 1023px) {
  .page-layout {
    display: block;
  }
  .main-content {
    margin: 0 auto;
    padding-top: 1rem;
  }
}

/* Hero Page Header */
.page-header {
  margin-bottom: 3.5rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 2.5rem;
}

.last-updated {
  font-size: 0.85rem;
  color: var(--primary-color);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.last-updated::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  background-color: var(--primary-color);
  border-radius: 50%;
}

h1 {
  font-family: var(--font-heading);
  font-size: 2.75rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 1.25rem;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.intro-text {
  font-size: 1.125rem;
  color: var(--text-secondary);
  max-width: 68ch;
  line-height: 1.75;
}

/* Document Sections */
section {
  margin-bottom: 3.5rem;
  scroll-margin-top: 7rem;
}

h2 {
  font-family: var(--font-heading);
  font-size: 1.625rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 1.25rem;
  letter-spacing: -0.025em;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

h3 {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 1.75rem 0 0.85rem;
}

p {
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
  font-size: 1rem;
}

/* Bullet list and specific visual updates */
.bullet-list {
  list-style: none;
  padding-left: 0;
  margin-bottom: 1.5rem;
}

.bullet-list li {
  position: relative;
  padding-left: 1.75rem;
  margin-bottom: 0.85rem;
  color: var(--text-secondary);
}

.bullet-list li::before {
  content: "";
  position: absolute;
  left: 0.35rem;
  top: 0.65rem;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--primary-color);
  box-shadow: 0 0 8px var(--primary-color);
}

.definition-list {
  list-style: none;
  padding-left: 0;
  margin-bottom: 1.5rem;
  display: grid;
  gap: 1.25rem;
}

.definition-list li {
  margin-bottom: 0;
  background-color: #ffffff;
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--primary-color);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-fast);
}

.definition-list li:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-hover);
}

.definition-list li strong {
  display: inline-block;
  color: var(--text-primary);
  margin-bottom: 0.35rem;
  font-family: var(--font-heading);
  font-size: 1.05rem;
}

.subsection {
  margin-left: 0;
  padding-left: 1.25rem;
  border-left: 2px solid var(--border-color);
  margin-bottom: 1.5rem;
  margin-top: 1rem;
}

.note {
  font-size: 0.95rem;
  background-color: var(--primary-light);
  color: var(--primary-hover);
  padding: 1rem 1.25rem;
  border-radius: var(--radius-md);
  border-left: 4px solid var(--primary-color);
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
  font-weight: 500;
}

/* Contact Card Section */
.contact-section {
  margin-top: 5rem;
  margin-bottom: 2rem;
}

.contact-box {
  background: linear-gradient(135deg, #ffffff 0%, #f6fdfb 100%);
  border: 1px solid #cceee5;
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  display: grid;
  gap: 1.5rem;
}

.contact-box::after {
  content: "";
  position: absolute;
  top: -50px;
  right: -50px;
  width: 150px;
  height: 150px;
  background: radial-gradient(circle, var(--primary-glow) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.contact-box p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  margin-bottom: 0.5rem;
}

.contact-details {
  display: grid;
  gap: 1.5rem;
}

.contact-item {
  display: flex;
  flex-direction: column;
}

.contact-item .label {
  font-family: var(--font-heading);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-light);
  margin-bottom: 0.4rem;
  font-weight: 700;
}

.contact-item .value {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  color: var(--text-primary);
  font-weight: 700;
  text-decoration: none;
  transition: color var(--transition-fast);
}

.contact-item a.value {
  color: var(--primary-color);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  width: fit-content;
}

.contact-item a.value:hover {
  color: var(--primary-hover);
}

.contact-item a.value::after {
  content: "→";
  display: inline-block;
  transition: transform var(--transition-fast);
}

.contact-item a.value:hover::after {
  transform: translateX(4px);
}

/* Footer Section */
footer {
  margin-top: 6rem;
  padding: 3rem 1.5rem;
  border-top: 1px solid var(--border-color);
  text-align: center;
  background-color: var(--surface-color);
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
}

.footer-links a {
  text-decoration: none;
  color: var(--text-light);
  font-size: 0.875rem;
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: var(--primary-color);
}

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

/* Responsive details */
@media (max-width: 768px) {
  h1 {
    font-size: 2.25rem;
  }
  
  .page-layout {
    padding: 2rem 1rem;
  }
  
  .contact-box {
    padding: 1.75rem;
  }

  .contact-item .value {
    font-size: 1.15rem;
  }
}

@media (max-width: 640px) {
  .sticky-header nav {
    gap: 0.25rem;
  }
  
  .sticky-header nav a {
    padding: 0.4rem 0.85rem;
    font-size: 0.8rem;
  }
  
  .logo-text {
    font-size: 1.1rem;
  }
}
