/* Base Styles and Variables */
:root {
    --primary-color: #f78c2a; /* Orange */
    --primary-dark: #e67300;
    --primary-light: #ff9f4d;
    --primary-color-rgb: 247, 140, 42; /* RGB values for primary color */
    --dark-bg: #131927; /* Dark navy background */
    --dark-surface: #1e2235;
    --darker-surface: #0f111d; /* Even darker for alternating sections */
    --dark-text: #ffffff;
    --dark-text-secondary: rgba(255, 255, 255, 0.8);
    --dark-text-muted: rgba(255, 255, 255, 0.6);
    --light-bg: #f5f5f5;
    --light-surface: #ffffff;
    --light-text: #333333;
    --transition: all 0.3s ease;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
    --border-radius: 8px;
    --section-spacing: 80px 0;
  }
  
  /* Dark Mode Defaults */
  .dark-mode {
    --bg-color: var(--dark-bg);
    --surface-color: var(--dark-surface);
    --alternate-bg: var(--darker-surface);
    --text-color: var(--dark-text);
    --text-color-secondary: var(--dark-text-secondary);
    --text-color-muted: var(--dark-text-muted);
    --card-bg: #1e2235;
    --card-border: #2d3348;
  }
  
  /* Light Mode */
  .light-mode {
    --bg-color: var(--light-bg);
    --surface-color: var(--light-surface);
    --alternate-bg: #eaeaea; /* New lighter alternate background */
    --text-color: var(--light-text);
    --text-color-secondary: rgba(51, 51, 51, 0.8);
    --text-color-muted: rgba(51, 51, 51, 0.6);
    --card-bg: #ffffff;
    --card-border: #e0e0e0;
  }
  
  /* Global Styles */
  * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
  }
  
  body {
    font-family: 'Montserrat', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    transition: var(--transition);
  }
  
  .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px;
  }
  
  a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
  }
  
  a:hover {
    color: var(--primary-dark);
  }
  
  h1, h2, h3, h4, h5, h6 {
    margin-bottom: 20px;
    line-height: 1.2;
  }
  
  button {
    cursor: pointer;
    border: none;
    outline: none;
    background: none;
    transition: var(--transition);
  }
  
  /* Header Styles */
  #site-header {
    position: sticky;
    top: 0;
    background-color: var(--dark-bg);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    padding: 15px 0;
  }
  
  .header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-direction: row;
  }
  
  .logo {
    flex: 0 0 auto;
  }
  
  .search-container {
    position: relative;
    flex: 0 1 500px;
    margin: 0 20px;
  }
  
  .theme-toggle {
    flex: 0 0 auto;
  }
  
  /* Modern Search Input */
  #search-bar {
    width: 100%;
    padding: 12px 20px;
    padding-right: 45px; /* Space for the search icon */
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 30px;
    background-color: rgba(30, 34, 53, 0.6);
    color: var(--dark-text);
    font-size: 0.95rem;
    outline: none;
    transition: var(--transition);
    backdrop-filter: blur(5px);
  }
  
  #search-bar::placeholder {
    color: rgba(255, 255, 255, 0.4);
    font-weight: 400;
  }
  
  #search-bar:focus {
    border-color: var(--primary-color);
    background-color: rgba(30, 34, 53, 0.8);
    box-shadow: 0 0 0 3px rgba(247, 140, 42, 0.2);
  }
  
  /* Search Button */
  #search-button {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    color: var(--primary-color);
    padding: 8px;
    font-size: 1rem;
    transition: var(--transition);
  }
  
  #search-button:hover {
    color: var(--primary-light);
    transform: translateY(-50%) scale(1.1);
  }
  
  #theme-toggle-btn {
    font-size: 1.2rem;
    color: var(--text-color);
    padding: 8px;
    border: 2px solid var(--card-border);
    border-radius: var(--border-radius);
    background-color: var(--card-bg);
    transition: var(--transition);
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
  #theme-toggle-btn:hover {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
  }
  
  #theme-toggle-btn i {
    transition: var(--transition);
  }
  
  /* Hero Section with darker background */
  #hero {
    padding: 100px 0 60px;
    text-align: left;
    background-color: var(--alternate-bg);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }
  
  .hero-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
  }
  
  .hero-text {
    max-width: 600px;
  }
  
  .profile {
    margin-bottom: 40px;
  }
  
  .profile-img-container {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    border: 4px solid var(--primary-color);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #2d3348;
  }
  
  .profile-img {
    width: 80%;
    height: 80%;
    object-fit: cover;
    border-radius: 0;
    border: none;
  }
  
  .profile h1 {
    font-size: 3.5rem;
    color: var(--primary-color);
    margin-bottom: 10px;
  }
  
  .tagline {
    font-size: 1.3rem;
    color: var(--text-color-secondary);
    margin-bottom: 20px;
    font-weight: 500;
  }
  
  .hero-description {
    font-size: 1.1rem;
    margin-bottom: 30px;
    color: var(--text-color-muted);
    line-height: 1.7;
  }
  
  /* Section headers styled like in screenshot */
  .section-header {
    text-align: center;
    margin-bottom: 50px;
  }
  
  .section-header h2 {
    font-size: 2.5rem;
    display: inline-block;
    position: relative;
    padding-bottom: 10px;
    font-weight: 700;
    color: var(--text-color);
  }
  
  .section-header h2:after {
    content: '';
    position: absolute;
    width: 80px;
    height: 3px;
    background-color: var(--primary-color);
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
  }
  
  /* About Section with primary background */
  #about {
    padding: var(--section-spacing);
    background-color: var(--bg-color);
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  }
  
  #about p {
    max-width: 800px;
    margin: 0 auto 30px;
    font-size: 1.1rem;
    color: var(--text-color-secondary);
    line-height: 1.8;
  }
  
  /* Skills */
  .skills-container {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 40px;
    justify-content: center;
  }
  
  .skill-tag {
    background-color: var(--primary-color);
    color: white;
    padding: 10px 20px;
    border-radius: 30px;
    font-size: 1rem;
    font-weight: 500;
    transition: var(--transition);
  }
  
  .skill-tag:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
  }
  
  /* Knowledge Base Section with darker background */
  #knowledge-base {
    padding: var(--section-spacing);
    background-color: var(--alternate-bg);
  }
  
  #knowledge-base p {
    color: var(--text-color-secondary);
    line-height: 1.7;
    max-width: 800px;
    margin: 0 auto 30px;
    text-align: center;
  }
  
  .kb-navigation {
    display: flex;
    flex-wrap: wrap;
    margin: 40px 0;
    gap: 10px;
  }
  
  .kb-tab {
    padding: 10px 20px;
    background-color: var(--card-bg);
    border-radius: var(--border-radius);
    color: var(--text-color);
    font-weight: 500;
    border: 1px solid var(--card-border);
  }
  
  .kb-tab.active {
    background-color: var(--primary-color);
    color: white;
  }
  
  /* Knowledge Base Content */
  .kb-tab-content {
    display: none;
  }
  
  .kb-tab-content.active {
    display: block;
  }
  
  /* Knowledge Base Cards */
  .kb-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
  }
  
  .kb-card {
    background-color: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius);
    padding: 20px;
    transition: var(--transition);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  }
  
  .kb-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
  }
  
  .kb-card h3 {
    color: var(--primary-color);
    margin-bottom: 10px;
    font-weight: 600;
    letter-spacing: 0.3px;
  }
  
  .kb-card p {
    color: var(--text-color-muted);
    text-align: left;
  }
  
  .read-more-btn {
    display: inline-block;
    margin-top: 15px;
    padding: 8px 16px;
    background-color: var(--primary-color);
    color: white;
    border-radius: var(--border-radius);
    font-weight: 500;
  }
  
  .read-more-btn:hover {
    background-color: var(--primary-dark);
  }
  
  /* Knowledge Base List */
  .kb-list-container {
    max-height: 600px;
    overflow-y: auto;
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius);
  }
  
  .kb-list {
    list-style: none;
  }
  
  .kb-list-item {
    padding: 15px 20px;
    border-bottom: 1px solid var(--card-border);
  }
  
  .kb-list-item:last-child {
    border-bottom: none;
  }
  
  .kb-list-item h4 {
    color: var(--primary-color);
    margin-bottom: 5px;
  }
  
  /* Article Container */
  #article-container {
    padding: 60px 0;
    background-color: var(--bg-color);
  }
  
  #article-container.hidden {
    display: none;
  }
  
  .back-button {
    display: inline-flex;
    align-items: center;
    padding: 10px 15px;
    background-color: var(--card-bg);
    color: var(--text-color);
    border-radius: var(--border-radius);
    margin-bottom: 30px;
  }
  
  .back-button i {
    margin-right: 8px;
  }
  
  #article-content {
    background-color: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius);
    padding: 30px;
  }
  
  /* In Progress Section */
  #in-progress {
    padding: 60px 0;
    background-color: var(--surface-color);
    text-align: center;
  }
  
  /* Footer */
  footer {
    padding: 40px 0;
    background-color: var(--alternate-bg);
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
  }
  
  .social-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
  }
  
  .social-link {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 45px;
    height: 45px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 50%;
    font-size: 1.2rem;
    transition: var(--transition);
  }
  
  .social-link:hover {
    background-color: var(--primary-dark);
    transform: translateY(-3px);
  }
  
  .copyright {
    font-size: 0.9rem;
    opacity: 0.8;
  }
  
  /* Responsive Design */
  @media (max-width: 992px) {
    .hero-content {
      flex-direction: column-reverse;
      text-align: center;
    }
    
    .profile h1 {
      font-size: 2.8rem;
    }
    
    .section-header h2 {
      font-size: 2rem;
    }

    /* Knowledge Base Cards */
    .kb-cards {
      grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
      gap: 15px;
    }

    /* Search suggestions */
    .search-suggestions {
      max-width: 90%;
    }
    
    /* Article Layout for tablets and smaller devices */
    .article-layout {
      flex-direction: column;
      gap: 1.5rem;
    }
    
    .article-nav {
      flex: 0 0 auto;
      position: relative;
      top: 0;
      width: 100%;
      max-height: none;
    }
    
    .article-section {
      padding: 1.875rem;
    }
    
    .article-header h1 {
      font-size: 2.2rem;
    }
    
    .article-section h2 {
      font-size: 1.7rem;
    }
    
    /* Server requirement card on smaller screens */
    .requirement-header {
      flex-direction: column;
      align-items: flex-start;
      gap: 1rem;
    }
    
    .doc-link {
      align-self: flex-start;
    }
}

@media (max-width: 768px) {
    .header-content {
      gap: 15px;
      flex-wrap: wrap;
      justify-content: center;
    }
    
    .logo {
      order: 1;
      width: 100%;
      text-align: center;
      margin-bottom: 10px;
    }
    
    .search-container {
      order: 3;
      width: 100%;
      margin: 10px 0 0;
    }
    
    .theme-toggle {
      order: 2;
    }
    
    .profile h1 {
      font-size: 2.2rem;
    }
    
    .hero-description {
      font-size: 1rem;
    }
    
    /* EDR buttons stack on mobile */
    .edr-selection {
      flex-direction: column;
      align-items: center;
      gap: 15px;
    }
    
    .edr-btn {
      width: 100%;
      max-width: 300px;
      padding: 12px 20px;
      font-size: 1rem;
      justify-content: center;
    }
    
    /* KB tabs scroll horizontally */
    .kb-navigation {
      display: flex;
      flex-wrap: nowrap;
      overflow-x: auto;
      padding-bottom: 10px;
      -webkit-overflow-scrolling: touch;
      margin: 30px -15px;
      padding: 0 15px 10px;
    }
    
    .kb-tab {
      padding: 8px 15px;
      font-size: 0.9rem;
      white-space: nowrap;
    }
    
    /* Knowledge Base list */
    .kb-list-container {
      max-height: 450px;
    }
    
    .kb-list-item {
      padding: 12px 15px;
    }
    
    .kb-list-item-header {
      flex-wrap: wrap;
    }
    
    /* Search suggestions take full width */
    .search-suggestions {
      width: 100%;
      max-width: 100%;
      left: 0;
    }
    
    /* Article styling for mobile phones */
    .article-layout {
      font-size: 1rem;
    }
    
    .article-section {
      padding: 1.5rem;
      margin-bottom: 1.5rem;
    }
    
    .article-header h1 {
      font-size: 1.8rem;
      margin-bottom: 1rem;
    }
    
    .article-section h2 {
      font-size: 1.5rem;
    }
    
    .info-note {
      padding: 1rem;
      margin: 1.25rem 0;
      gap: 0.75rem;
    }
    
    .info-note i {
      font-size: 1.25rem;
    }
    
    /* Navigation for mobile */
    .nav-header {
      padding: 1rem;
      display: flex;
      justify-content: space-between;
      align-items: center;
      cursor: pointer;
    }
    
    .nav-header:after {
      content: '\f107'; /* Font Awesome down arrow */
      font-family: 'Font Awesome 5 Free';
      font-weight: 900;
      font-size: 1.25rem;
      transition: transform 0.3s ease;
    }
    
    .nav-header.expanded:after {
      transform: rotate(180deg);
    }
    
    /* Collapsible navigation menu for mobile */
    .nav-items {
      max-height: 0;
      overflow: hidden;
      transition: max-height 0.5s ease;
    }
    
    .nav-items.expanded {
      max-height: 500px;
    }
    
    /* Make nav items easier to tap on mobile */
    .nav-items li a {
      padding: 0.875rem 1rem;
      font-size: 1rem;
    }
    
    /* Article metadata on mobile */
    .article-metadata {
      flex-direction: column;
      gap: 0.5rem;
      align-items: flex-start;
    }
    
    .article-metadata span {
      font-size: 0.9rem;
      display: inline-block;
      margin-bottom: 5px;
    }
    
    /* Back button styling for mobile */
    .back-button {
      padding: 0.625rem 1rem;
      font-size: 0.9375rem;
      margin-bottom: 1.25rem;
    }
}

@media (max-width: 480px) {
    .kb-tab {
        padding: 8px 12px;
        font-size: 0.85rem;
    }
    
    .profile-img-container {
        width: 150px;
        height: 150px;
    }
    
    h2 {
        font-size: 1.5rem;
    }

    /* Smaller card padding */
    .kb-card {
        padding: 15px;
    }
    
    /* Category headers */
    .kb-category-header {
        padding: 10px 15px;
        font-size: 0.85rem;
    }
    
    /* Extreme small screen adjustments */
    .article-section {
      padding: 1.25rem;
      margin-bottom: 1.25rem;
    }
    
    .article-header h1 {
      font-size: 1.6rem;
    }
    
    .article-section h2 {
      font-size: 1.3rem;
    }
    
    .server-requirement-card {
      padding: 1.25rem;
    }
    
    .server-icon {
      width: 40px;
      height: 40px;
      font-size: 1.25rem;
    }
    
    /* Improve search on very small screens */
    #search-bar {
      padding: 10px 16px;
      padding-right: 40px;
      font-size: 0.9rem;
    }
    
    #search-button {
      right: 6px;
      font-size: 0.9rem;
    }
    
    /* Smaller nav items for better tap targets */
    .nav-items li a {
      padding: 0.75rem 0.875rem;
    }
}

/* Add spacing above footer on mobile */
@media (max-width: 768px) {
    footer {
        margin-top: 30px;
    }
}

/* Knowledge Base Cards - Add icon styles */
.kb-card-header {
  display: flex;
  align-items: center;
  margin-bottom: 15px;
}

.kb-card-icon {
  font-size: 1.5rem;
  color: var(--primary-color);
  margin-right: 15px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(255, 117, 24, 0.1);
  border-radius: 50%;
}

.kb-list-item-header {
  display: flex;
  align-items: center;
}

.kb-list-icon {
  font-size: 1.2rem;
  color: var(--primary-color);
  margin-right: 10px;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(255, 117, 24, 0.1);
  border-radius: 50%;
}

/* Search Results */
.search-results {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.search-result-item {
  background-color: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--border-radius);
  padding: 18px;
  transition: var(--transition);
}

.search-result-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.search-result-btn {
  margin-top: 12px;
  background-color: transparent;
  border: 1px solid var(--primary-color);
  color: var(--primary-color);
}

.search-result-btn:hover {
  background-color: var(--primary-color);
  color: white;
}

/* Category headers for ALL list */
.kb-category-header {
  background-color: var(--primary-color);
  color: white;
  padding: 12px 20px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
}

.kb-category-header i {
  margin-right: 10px;
}

/* Update list container to show borders better */
.kb-list-container {
  max-height: 600px;
  overflow-y: auto;
  background-color: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--border-radius);
}

.kb-list-item:hover {
  background-color: rgba(255, 117, 24, 0.05);
}

/* Improved Search Suggestions Dropdown */
.search-suggestions {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 5px;
  background-color: rgba(30, 34, 53, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, opacity 0.3s ease;
  z-index: 1001;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
  opacity: 0;
  backdrop-filter: blur(10px);
  width: 100%;
  max-width: 500px;
}

.search-suggestions.active {
  max-height: 400px;
  overflow-y: auto;
  opacity: 1;
}

.search-suggestion-item {
  padding: 14px 18px;
  cursor: pointer;
  display: flex;
  align-items: flex-start;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  transition: var(--transition);
}

.search-suggestion-item:last-child {
  border-bottom: none;
}

.search-suggestion-item:hover {
  background-color: rgba(255, 255, 255, 0.05);
}

.suggestion-icon {
  color: var(--primary-color);
  font-size: 1.1rem;
  margin-right: 12px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  width: 32px;
  padding-top: 3px;
}

.suggestion-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  width: 100%;
}

.suggestion-title {
  font-weight: 500;
  margin-bottom: 5px;
  color: var(--text-color);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
}

.suggestion-contexts {
  font-size: 0.85rem;
  color: var(--text-color-muted);
  max-height: 5.6em; /* Limit total height to ~4 lines */
  overflow: hidden;
  margin-bottom: 3px;
}

/* Only show 2 snippets maximum */
.context-snippet:nth-child(n+3) {
  display: none;
}

/* Add ellipsis after the second snippet if there are more */
.suggestion-contexts:has(.context-snippet:nth-child(3))::after {
  content: "...";
  color: var(--primary-color);
  opacity: 0.8;
  display: block;
  margin-top: 2px;
}

/* Ensure clean line breaks for context snippets */
.context-snippet {
  margin-bottom: 6px;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  line-height: 1.4;
  white-space: normal;
  display: block;
  font-size: 0.85rem;
  max-height: 2.8em; /* Limit to about 2 lines */
  word-wrap: break-word;
}

/* Style for ellipses to make them distinct */
.context-snippet::before,
.context-snippet::after {
  color: var(--primary-color);
  opacity: 0.8;
}

/* Make the matched text even more visible */
.matched-text, .highlighted-term {
  font-weight: 600;
  color: var(--primary-color);
  background-color: rgba(247, 140, 42, 0.15);
  padding: 1px 4px;
  border-radius: 3px;
  display: inline-block;
  box-shadow: 0 0 0 1px rgba(247, 140, 42, 0.2);
}

/* Custom scrollbar for search suggestions */
.search-suggestions::-webkit-scrollbar {
  width: 6px;
}

.search-suggestions::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.1);
  border-radius: 0 10px 10px 0;
}

.search-suggestions::-webkit-scrollbar-thumb {
  background: rgba(247, 140, 42, 0.5);
  border-radius: 10px;
}

.search-suggestions::-webkit-scrollbar-thumb:hover {
  background: rgba(247, 140, 42, 0.7);
}

/* EDR Selection Buttons */
.edr-selection {
  display: flex;
  gap: 20px;
  margin: 40px 0;
  justify-content: center;
  flex-wrap: wrap;
}

.edr-btn {
  padding: 15px 30px;
  background-color: transparent;
  color: var(--text-color);
  border: 2px solid var(--primary-color);
  border-radius: 30px;
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 15px;
  transition: var(--transition);
}

.edr-btn:hover {
  background-color: rgba(247, 140, 42, 0.1);
  transform: translateY(-3px);
}

.edr-btn.active {
  background-color: var(--primary-color);
  color: white;
  box-shadow: 0 4px 12px rgba(247, 140, 42, 0.3);
}

.edr-content {
  display: none;
  animation: fadeIn 0.5s ease;
}

.edr-content.active {
  display: block;
}

.edr-content h3 {
  color: var(--primary-color);
  margin-bottom: 15px;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Responsive adjustments for EDR buttons */
@media (max-width: 768px) {
  .edr-selection {
    flex-direction: column;
    align-items: center;
    gap: 10px;
  }
  
  .edr-btn {
    width: 100%;
    max-width: 300px;
    justify-content: center;
  }
}

/* Update logo/home button styling */
.logo a {
  font-size: 1.8rem;
  color: var(--primary-color);
  font-weight: 700;
  text-decoration: none;
  transition: var(--transition);
  display: inline-block;
}

.logo a:hover {
  color: var(--primary-light);
  transform: translateY(-2px);
}

/* Typography enhancements */
h1 {
  font-weight: 700;
  letter-spacing: -0.5px;
}

/* Progress bar under main section headers */
.progress-bar {
  height: 4px;
  width: 80px;
  background-color: var(--primary-color);
  margin: 0 auto 40px;
  border-radius: 2px;
}

/* Additional styles for light mode search elements */
.light-mode .search-suggestions {
  background-color: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.light-mode .search-suggestion-item {
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.light-mode .search-suggestion-item:hover {
  background-color: rgba(247, 140, 42, 0.05);
}

.light-mode .suggestion-title {
  color: var(--text-color);
}

.light-mode .suggestion-contexts {
  color: var(--text-color-muted);
}

/* Enhance visibility of matched text in light mode */
.light-mode .matched-text, 
.light-mode .highlighted-term {
  background-color: rgba(247, 140, 42, 0.12);
  box-shadow: 0 0 0 1px rgba(247, 140, 42, 0.25);
}

/* Improve search bar in light mode */
.light-mode #search-bar {
  background-color: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(0, 0, 0, 0.15);
  color: var(--light-text);
}

.light-mode #search-bar::placeholder {
  color: rgba(0, 0, 0, 0.4);
}

.light-mode #search-bar:focus {
  border-color: var(--primary-color);
  background-color: #ffffff;
  box-shadow: 0 0 0 3px rgba(247, 140, 42, 0.15);
}

/* Article Layout Styles - 125% Size */
.article-layout {
  display: flex;
  gap: 2rem;
  min-height: 600px;
  font-size: 1.125rem; /* 125% of base font size */
}

.article-nav {
  flex: 0 0 280px; /* Slightly wider */
  background: var(--dark-surface);
  border-radius: 8px;
  overflow: hidden;
  position: sticky;
  top: 90px;
  align-self: flex-start;
  max-height: calc(100vh - 120px);
}

/* Light mode styling for article navigation */
.light-mode .article-nav {
  background: #f0f0f0;
  border: 1px solid #e0e0e0;
}

.nav-section {
  border-left: 4px solid transparent;
}

.nav-section.active {
  border-left-color: var(--primary-color);
}

.nav-header {
  padding: 1.25rem;
  font-size: 1.125rem;
  background: rgba(247, 140, 42, 0.1);
  color: var(--primary-color);
  font-weight: 600;
}

/* Light mode styling for nav header */
.light-mode .nav-header {
  background: rgba(247, 140, 42, 0.1);
  color: var(--primary-dark);
}

.nav-items {
  list-style: none;
  padding: 0;
  margin: 0;
}

.nav-items li {
  border-left: 4px solid transparent;
  margin-left: -4px;
  transition: all 0.3s ease;
  cursor: pointer;
}

.nav-items li a {
  padding: 0.9375rem 1.25rem;
  font-size: 1.0625rem;
  display: block;
  color: var(--text-color-secondary);
  text-decoration: none;
  transition: all 0.3s ease;
  cursor: pointer;
}

/* Light mode styling for nav items */
.light-mode .nav-items li a {
  color: #555;
}

.nav-items li:hover {
  border-left-color: rgba(247, 140, 42, 0.5);
}

.nav-items li:hover a {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-color);
  transform: translateX(5px);
}

/* Light mode styling for nav item hover */
.light-mode .nav-items li:hover a {
  background: rgba(247, 140, 42, 0.05);
  color: #333;
}

.nav-items li.active {
  border-left-color: var(--primary-color);
}

.nav-items li.active a {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-color);
  font-weight: 500;
}

/* Light mode styling for active nav items */
.light-mode .nav-items li.active a {
  background: rgba(247, 140, 42, 0.1);
  color: var(--primary-dark);
}

.article-content {
  flex: 1;
}

.article-section {
  padding: 2.5rem;
  margin-bottom: 2.5rem;
  background: var(--card-bg);
  border-radius: 8px;
  transition: opacity 0.3s ease, transform 0.3s ease;
  opacity: 0;
  transform: translateY(10px);
  display: none;
}

/* Light mode styling for article sections */
.light-mode .article-section {
  background: #fff;
  border: 1px solid #e0e0e0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.article-section.active {
  display: block;
  opacity: 1;
  transform: translateY(0);
  animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.article-header h1 {
  font-size: 2.5rem;
  margin-bottom: 1.25rem;
}

/* Light mode styling for headings */
.light-mode .article-header h1,
.light-mode .article-section h2 {
  color: #333;
}

.article-section h2 {
  font-size: 1.875rem;
  margin-bottom: 1.25rem;
}

.light-mode .article-section h2 {
  color: var(--primary-dark);
}

.article-section p {
  line-height: 1.7;
}

.info-note {
  padding: 1.25rem;
  margin: 1.875rem 0;
  gap: 1.25rem;
  display: flex;
  background: rgba(247, 140, 42, 0.1);
  border-left: 4px solid var(--primary-color);
  border-radius: 4px;
}

/* Light mode styling for info notes */
.light-mode .info-note {
  background: rgba(247, 140, 42, 0.08);
  border-left: 4px solid var(--primary-color);
}

.info-note i {
  font-size: 1.5rem;
  color: var(--primary-color);
}

.server-requirement-card {
  background: var(--alternate-bg);
  border: 1px solid var(--card-border);
  border-radius: 8px;
  padding: 1.5rem;
  margin: 1.5rem 0;
}

/* Light mode styling for requirement cards */
.light-mode .server-requirement-card {
  background: #f8f8f8;
  border: 1px solid #e0e0e0;
}

.requirement-header {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.server-icon {
  background: rgba(247, 140, 42, 0.1);
  color: var(--primary-color);
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-size: 1.5rem;
}

/* Light mode styling for server icons */
.light-mode .server-icon {
  background: rgba(247, 140, 42, 0.1);
  color: var(--primary-dark);
}

.server-info {
  flex: 1;
}

/* Light mode styling for server info */
.light-mode .server-info h3 {
  color: #333;
}

.server-meta {
  display: flex;
  gap: 1rem;
  margin-top: 0.5rem;
}

.tag {
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
  font-size: 0.875rem;
  font-weight: 500;
}

.tag.recommended {
  background: rgba(0, 200, 83, 0.1);
  color: #00c853;
}

.tag.critical {
  background: rgba(255, 82, 82, 0.1);
  color: #ff5252;
}

.doc-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: var(--primary-color);
  color: white;
  border-radius: 6px;
  text-decoration: none;
  transition: all 0.3s ease;
  cursor: pointer;
}

.doc-link:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
}

/* Adjust article container width */
#article-container .container {
  max-width: 1300px;
}

/* Make back button larger */
.back-button {
  padding: 0.75rem 1.25rem;
  font-size: 1.0625rem;
}

/* Light mode styling for back button */
.light-mode .back-button {
  background: #f0f0f0;
  color: #555;
  border: 1px solid #e0e0e0;
}

.light-mode .back-button:hover {
  background: #e6e6e6;
}

/* Light mode styling for article metadata */
.light-mode .article-metadata span {
  background: rgba(247, 140, 42, 0.1);
  color: var(--primary-dark);
}

/* JavaScript for mobile navigation toggle */
.mobile-nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--primary-color);
  font-size: 1.5rem;
  padding: 0.5rem;
  cursor: pointer;
}

@media (max-width: 768px) {
  .mobile-nav-toggle {
    display: block;
  }
}
