/* Auto-scrolling for ALL code blocks - Maximum specificity */
.md-typeset .highlight,
.md-typeset .highlight pre,
.md-typeset .highlight pre code,
.md-typeset pre,
.md-typeset pre code {
  max-height: 800px !important;
  overflow-y: auto !important;
  overflow-x: auto !important;
  display: block !important;
}

/* For tabbed content specifically */
.md-typeset .tabbed-content .highlight,
.md-typeset .tabbed-content .highlight pre,
.md-typeset .tabbed-content .highlight pre code,
.md-typeset .tabbed-content pre,
.md-typeset .tabbed-content pre code {
  max-height: 800px !important;
  overflow-y: auto !important;
  overflow-x: auto !important;
  display: block !important;
}

/* Target the code element directly inside pre */
.md-typeset pre code {
  max-height: 800px !important;
  overflow-y: auto !important;
  overflow-x: auto !important;
  display: block !important;
}

/* Ensure the parent container allows scrolling */
.md-typeset .highlight {
  position: relative !important;
  max-height: 800px !important;
  overflow: hidden !important;
}

.md-typeset .highlight pre {
  margin: 0 !important;
  max-height: 800px !important;
  overflow-y: auto !important;
  overflow-x: auto !important;
}

/* Smooth scrolling */
.md-typeset .highlight pre,
.md-typeset pre code {
  scroll-behavior: smooth;
}

/* Custom scrollbar */
.md-typeset .highlight pre::-webkit-scrollbar,
.md-typeset pre::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

.md-typeset .highlight pre::-webkit-scrollbar-track,
.md-typeset pre::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.1);
  border-radius: 5px;
}

.md-typeset .highlight pre::-webkit-scrollbar-thumb,
.md-typeset pre::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.3);
  border-radius: 5px;
}

.md-typeset .highlight pre::-webkit-scrollbar-thumb:hover,
.md-typeset pre::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 0, 0, 0.5);
}

/* Ensure admonitions use the same font as regular text */
.md-typeset .admonition {
  font-size: inherit;
  font-weight: inherit;
}

.md-typeset .admonition p {
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
}

/* Custom primary color */
:root {
  --md-primary-fg-color: #064469;
  --md-primary-fg-color--light: #064469;
  --md-primary-fg-color--dark: #032A3F;
  --md-accent-fg-color: #064469;
  --md-accent-fg-color--transparent: rgba(6, 68, 105, 0.1);
}

[data-md-color-scheme="slate"] {
  --md-primary-fg-color: #064469;
  --md-primary-fg-color--light: #064469;
  --md-primary-fg-color--dark: #032A3F;
  --md-accent-fg-color: #064469;
  --md-accent-fg-color--transparent: rgba(6, 68, 105, 0.1);
}