/* Minimal layout fixes for Quantillon Protocol documentation */
/* This CSS only fixes layout issues without changing the default mdBook color theme */

/* Fix header title cropping by ensuring proper spacing */
header.site {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 1001 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 14px 18px !important;
  border-bottom: 1px solid #e5e7eb !important;
  background: #0b0b0b !important;
}

/* Center the banner and title container */
header.site > div:first-child {
  display: flex !important;
  align-items: center !important;
  gap: 12px !important;
  justify-content: center !important;
  flex: 1 !important;
}

header.site img {
  height: 140px !important;
  width: auto !important;
  flex-shrink: 0 !important;
}

/* Hide only the title link, not navigation links */
header.site > div:first-child > a:first-child {
  display: none !important;
}

/* Fix navigation links to be clickable */
header.site nav {
  position: absolute !important;
  right: 18px !important;
  display: flex !important;
  gap: 16px !important;
  align-items: center !important;
  flex-shrink: 0 !important;
}

header.site nav a {
  color: #e7b563 !important;
  text-decoration: none !important;
  font-weight: 500 !important;
  cursor: pointer !important;
  pointer-events: auto !important;
  z-index: 1002 !important;
  position: relative !important;
}

header.site nav a:hover {
  color: #ffffff !important;
  text-decoration: underline !important;
}

/* Ensure proper spacing for the main content area */
.content {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

/* Fix sidebar to account for fixed header */
.sidebar {
  z-index: 1000 !important;
  margin-top: 168px !important;
}

/* Fix sidebar overlap issues */
.sidebar {
  z-index: 1000 !important;
}

/* Ensure the menu bar doesn't interfere with header */
.menu-bar {
  z-index: 999 !important;
  margin-top: 168px !important;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  header.site {
    flex-direction: column !important;
    gap: 10px !important;
    padding: 10px 15px !important;
  }
  
  header.site > div:first-child {
    max-width: 100% !important;
    justify-content: center !important;
  }
  
  header.site > div:first-child > a:first-child {
    max-width: 100% !important;
    text-align: center !important;
  }
  
  header.site nav {
    display: none !important;
  }
}
  