/*
 * Lumaris brand alignment for Material for MkDocs.
 * Source: Lumaris Brand Guidelines v1.3 (May 2026).
 *
 * One palette only — the brand guide defines a single print/document
 * palette with no dark-mode variant, so the light/dark toggle is disabled
 * in mkdocs.yml rather than inventing unspecified dark colours.
 *
 * Fonts are system stacks, not web-font imports: Calibri and Georgia are
 * proprietary Microsoft/Apple faces with no licence to embed for web
 * delivery, so these rely on the fonts already installed on staff
 * machines and fall back gracefully where they aren't.
 */

:root {
  --lumaris-forest: #1f3a2e;
  --lumaris-forest-ink: #263a2d;
  --lumaris-bronze: #b89568;
  --lumaris-sapphire: #1c4b8a;
  --lumaris-sage: #5c6b5f;
  --lumaris-muted: #7b8a7e;
  --lumaris-paper: #ffffff;
  --lumaris-hairline: #c8d0c7;
  --lumaris-sidebar-tint: #dde1e0;

  --md-text-font: Calibri, Candara, "Segoe UI", Optima, Arial, sans-serif;
  --md-code-font: Consolas, "SF Mono", Menlo, Monaco, monospace;

  /* Nav bar / primary surfaces */
  --md-primary-fg-color: var(--lumaris-forest);
  --md-primary-fg-color--light: #2c4d3c;
  --md-primary-fg-color--dark: #16281f;
  --md-primary-bg-color: var(--lumaris-paper);
  --md-primary-bg-color--light: #ffffffb3;

  /* Accent (search box focus ring, misc UI accents) */
  --md-accent-fg-color: var(--lumaris-bronze);
  --md-accent-fg-color--transparent: #b895681a;
  --md-accent-bg-color: var(--lumaris-paper);
  --md-accent-bg-color--light: #ffffffb3;

  /* Body text — Forest Ink, with Material's alpha-layering convention
     preserved so hover/lighter states keep working as designed */
  --md-default-fg-color: #263a2dde;
  --md-default-fg-color--light: #263a2d8a;
  --md-default-fg-color--lighter: #263a2d52;
  --md-default-fg-color--lightest: #263a2d1f;

  /* Links — Bronze, decoupled from --md-primary-fg-color (Forest) */
  --md-typeset-a-color: var(--lumaris-bronze);

  /* Code / data — Forest text per guideline, Sidebar Tint background */
  --md-code-fg-color: var(--lumaris-forest);
  --md-code-bg-color: var(--lumaris-sidebar-tint);
  --md-code-bg-color--light: #dde1e0b3;
  --md-code-bg-color--lighter: #dde1e04d;

  /* Table borders */
  --md-typeset-table-color: var(--lumaris-hairline);
  --md-typeset-table-color--light: #c8d0c74d;
}

/*
 * Material ships its own colour CSS gated behind `[data-md-color-primary]` /
 * `[data-md-color-accent]` attribute selectors (defaulting to "indigo"),
 * which beats a plain `:root { --md-primary-fg-color: ... }` override on
 * specificity regardless of stylesheet load order. The `--lumaris-*` custom
 * properties above stay as the semantic source of truth; the rules below
 * apply them directly to the components Material's own CSS keeps re-winning.
 */
.md-header,
.md-tabs {
  background-color: var(--lumaris-forest) !important;
}

/* Mobile drawer brand panel + repo-source row — same var-cascade issue as
   .md-header above, just on selectors Material scopes to the drawer only */
.md-nav--primary .md-nav__title[for="__drawer"] {
  background-color: var(--lumaris-forest) !important;
  color: var(--lumaris-paper) !important;
}
.md-nav__source {
  background-color: var(--lumaris-forest) !important;
  color: var(--lumaris-paper) !important;
}

.md-typeset a,
.md-typeset a:visited,
.md-nav__link--active,
.md-nav__item .md-nav__link--active code {
  color: var(--lumaris-bronze) !important;
}

.md-typeset code {
  background-color: var(--lumaris-sidebar-tint) !important;
  color: var(--lumaris-forest) !important;
}

.md-search__input {
  background-color: #ffffff26 !important;
}

/* Headings — Georgia, Forest, per the display/heading job in the type ladder */
.md-typeset h1,
.md-typeset h2,
.md-typeset h3,
.md-typeset h4,
.md-typeset h5,
.md-typeset h6,
.md-nav__title {
  font-family: Georgia, "Times New Roman", serif;
  color: var(--lumaris-forest);
}

/* No `theme.logo` is set on purpose — the brand guide's icon mark must
   never appear paired with the wordmark on the same surface, and the header
   /drawer show the wordmark already. Material falls back to a generic book
   icon in that case, which isn't our mark either, so hide it outright. */
.md-header__button.md-logo,
.md-nav__title .md-nav__button.md-logo {
  display: none !important;
}
/* ...and reclaim the top padding Material reserves for that icon's space */
.md-nav--primary .md-nav__title[for="__drawer"] {
  padding-top: 0.8rem !important;
  height: auto !important;
}

/* Cover-style Bronze rule under the page H1 */
.md-typeset h1 {
  padding-bottom: 0.3rem;
  border-bottom: 0.1rem solid var(--lumaris-bronze);
}

/* Site title in the header — Georgia, Paper (the header bg is Forest, so
   this must NOT reuse the Forest heading colour above or it disappears) */
.md-header__topic {
  font-family: Georgia, "Times New Roman", serif;
  color: var(--lumaris-paper);
}

/* The two-line lockup needs more width than Material's default single-line
   title allots, so stop the site-name span from ellipsis-truncating it */
.md-header__title {
  flex-grow: 1;
}
.md-header__topic:not([data-md-component]) .md-ellipsis {
  overflow: visible;
  white-space: nowrap;
  text-overflow: clip;
}

/* Wordmark + service-offering strip (header lockup), CSS-only —
   avoids a template override for a two-line nav title */
.md-header__topic:not([data-md-component]) {
  flex-wrap: wrap;
  row-gap: 0.2rem;
}
.md-header__topic:not([data-md-component])::after {
  flex-basis: 100%;
  content: "AI · DATA · CYBER · CLOUD · CRITICAL INFRASTRUCTURE";
  font-family: Calibri, Candara, "Segoe UI", Optima, Arial, sans-serif;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--lumaris-bronze);
}

/* Bronze tick bullets (▪), never round bullets, per guideline */
.md-typeset ul {
  list-style: none;
}
.md-typeset ul > li {
  position: relative;
}
.md-typeset ul > li::before {
  content: "▪";
  position: absolute;
  left: -1.25em;
  color: var(--lumaris-bronze);
}

/* Table headers — Sapphire is reserved for data/UI surfaces, tables qualify */
.md-typeset table:not([class]) th {
  background-color: var(--lumaris-sapphire);
  color: var(--lumaris-paper);
}

/* Caption / utility text (footer, page source date, admonition titles) */
.md-typeset .md-annotation__index,
.md-source-file,
.md-footer-meta {
  color: var(--lumaris-muted) !important;
}

/* Sidebar Tint callouts — align admonitions to the brand's "tinted card" pattern */
.md-typeset .admonition,
.md-typeset details {
  background-color: var(--lumaris-sidebar-tint);
  border: 1px solid var(--lumaris-hairline);
  border-left: none;
}
