/* TRACES-NT brand colors from the application */
/* Header: white top, dark blue nav (#002F67), breadcrumb (#004494) */
/* Body bg: #162935, Content bg: white fieldsets */
/* Font: Arial, 14px base */
/* Links: #004494, Headings: #0065A2 */
/* Buttons: EC blue #004494, orange/withdraw #d9534f, green #5cb85c */

:root {
  --md-primary-fg-color: #ffffff;
  --md-primary-fg-color--light: #ffffff;
  --md-primary-fg-color--dark: #f0f0f0;
  --md-primary-bg-color: #004494;
  --md-primary-bg-color--light: #336aaa;
  --md-accent-fg-color: #004494;
  --md-accent-fg-color--transparent: rgba(0, 68, 148, 0.1);
  --md-typeset-font-size: 0.82rem !important;
  --md-typeset-color: #333333;
  --md-typeset-a-color: #004494;
}

/* Ensure links are always visible */
.md-typeset a {
  color: #004494 !important;
}

.md-typeset a:hover {
  color: #002d6b !important;
}

/* Bigger logo in header */
.md-header__button.md-logo img,
.md-header__button.md-logo svg {
  height: 2rem !important;
  width: auto !important;
}

/* Subtle border to separate white header from content */
.md-header {
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1) !important;
}

/* Active sidebar item uses EC blue */
.md-nav__item--active > .md-nav__link,
.md-nav__link--active,
.md-nav__link:is([aria-current]) {
  color: #004494 !important;
  font-weight: 700 !important;
}

/* Compact content area */
.md-main__inner {
  margin-top: 0 !important;
}

.md-content__inner {
  padding-top: 0.5rem !important;
  padding-bottom: 0.5rem !important;
}

/* Headings match app style */
.md-typeset h1 {
  font-size: 1.5rem !important;
  margin: 0 0 0.4rem 0 !important;
  line-height: 1.3 !important;
  color: #0065A2 !important;
}

.md-typeset h2 {
  font-size: 1.2rem !important;
  margin: 0.8rem 0 0.3rem 0 !important;
  line-height: 1.3 !important;
  color: #254545 !important;
}

.md-typeset h3 {
  font-size: 1rem !important;
  margin: 0.6rem 0 0.2rem 0 !important;
  line-height: 1.3 !important;
  color: #444 !important;
}

/* Tighter paragraph and list spacing */
.md-typeset p {
  margin-top: 0.3em !important;
  margin-bottom: 0.3em !important;
}

.md-typeset ul,
.md-typeset ol {
  margin-top: 0.2em !important;
  margin-bottom: 0.2em !important;
}

.md-typeset li {
  margin-top: 0.1em !important;
  margin-bottom: 0.1em !important;
}

/* Compact horizontal rules */
.md-typeset hr {
  margin: 0.6rem 0 !important;
}

/* Reduce sidebar font */
.md-nav {
  font-size: 0.75rem !important;
}

/* Dark mode overrides */
[data-md-color-scheme="slate"] {
  --md-primary-fg-color: #002F67;
  --md-primary-fg-color--light: #004494;
  --md-primary-fg-color--dark: #001d3d;
  --md-primary-bg-color: #ffffff;
  --md-primary-bg-color--light: #cccccc;
  --md-accent-fg-color: #4da3ff;
  --md-accent-fg-color--transparent: rgba(77, 163, 255, 0.25);
}

/* PDF download button */
.pdf-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding-right: 0.5rem;
}

.pdf-actions a {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.3rem 0.7rem;
  font-size: 0.7rem;
  border-radius: 4px;
  text-decoration: none !important;
  cursor: pointer;
  white-space: nowrap;
}

.pdf-actions .btn-download {
  color: #fff !important;
  background: #004494;
  border: 1px solid #003a7a;
}

.pdf-actions .btn-download:hover {
  background: #003a7a;
}

/* Hide PDF button from mkdocs-with-pdf generated PDF */
@media print {
  .pdf-actions,
  .no-print {
    display: none !important;
  }
}


/* Hide admonition icons (e.g. pencil icon on notes) */
.md-typeset .admonition-title::before,
.md-typeset details summary::before {
  display: none !important;
}

.md-typeset .admonition-title,
.md-typeset details summary {
  padding-left: 0.6rem !important;
}

/* Make all admonition types use the same note color (blue) */
.md-typeset .admonition.tip,
.md-typeset details.tip {
  border-color: #448aff;
}

.md-typeset .admonition.tip .admonition-title,
.md-typeset details.tip summary {
  background-color: rgba(68, 138, 255, 0.1);
}

/* Full-width layout — push sidebar to the left edge */
.md-grid {
  max-width: 100% !important;
  margin: 0 !important;
  padding: 0 1rem !important;
}

/* Indent sub-menu items in left sidebar */
.md-nav--primary .md-nav__item .md-nav .md-nav__link {
  padding-left: 1rem !important;
}

/* Make parent section labels stand out */
.md-nav--primary > .md-nav__list > .md-nav__item > .md-nav__link,
.md-nav--primary > .md-nav__list > .md-nav__item > label {
  font-weight: 700 !important;
  text-transform: uppercase !important;
  font-size: 0.65rem !important;
  letter-spacing: 0.05em !important;
  color: #666 !important;
}

/* Hide site title from the top of the left sidebar nav */
.md-nav--primary > .md-nav__title {
  display: none !important;
}

/* Hide site title from the top of the left sidebar nav */
.md-nav--primary > .md-nav__title {
  display: none !important;
}

