/* The D-Modem sites: brand's neutrals and type, the repository's Rainbow Book
   (--suite-accent, set in main.html) as the theme's primary and accent. */
@font-face {
  font-family: "Sauce Code Pro";
  src: local("SauceCodePro Nerd Font Mono"), local("SauceCodePro Nerd Font"), local("Source Code Pro");
}
:root {
  --md-text-font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --md-code-font: "Sauce Code Pro", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --suite-bg: #0a0f1c;
  --suite-panel: #121a2e;
  --suite-text: #e8f0ff;
  --suite-muted: #7f8bab;
}
[data-md-color-primary="custom"] {
  --md-primary-fg-color: var(--suite-panel);
  --md-primary-fg-color--light: var(--suite-panel);
  --md-primary-fg-color--dark: var(--suite-bg);
  --md-primary-bg-color: var(--suite-text);
  --md-primary-bg-color--light: var(--suite-muted);
}
[data-md-color-accent="custom"] {
  --md-accent-fg-color: var(--suite-accent);
  --md-accent-fg-color--transparent: color-mix(in srgb, var(--suite-accent) 12%, transparent);
}
[data-md-color-scheme="slate"] {
  --md-default-bg-color: var(--suite-bg);
  --md-code-bg-color: var(--suite-panel);
  --md-default-fg-color: var(--suite-text);
  --md-typeset-a-color: var(--suite-accent);
}
[data-md-color-scheme="default"] {
  --md-typeset-a-color: color-mix(in srgb, var(--suite-accent) 70%, #000);
}
.md-header { border-bottom: 3px solid var(--suite-accent); }
.md-tabs { background-color: var(--suite-panel); }

/* the suite's bar */
.suite-bar {
  display: flex; align-items: center; gap: 1rem; overflow-x: auto;
  padding: 0 1rem; min-height: 1.8rem;
  background: var(--suite-bg); color: var(--suite-muted);
  font-family: var(--md-code-font); font-size: 0.65rem; white-space: nowrap;
}
.suite-bar ul { display: flex; gap: 0.9rem; margin: 0; padding: 0; list-style: none; }
.suite-bar a { color: var(--suite-muted); }
.suite-bar a:hover, .suite-bar a:focus { color: var(--suite-text); }
.suite-bar__home { font-weight: 700; color: var(--suite-text) !important; }
.suite-bar a[aria-current="page"] { color: var(--suite-text); border-bottom: 2px solid var(--suite-accent); }
.suite-bar a[data-repo="D-Modem"]:hover { color: #ff4d5e; }
.suite-bar a[data-repo="hardware"]:hover { color: #ff8a3d; }
.suite-bar a[data-repo="app"]:hover { color: #ffd23d; }
.suite-bar a[data-repo="menu"]:hover { color: #3ddc84; }
.suite-bar a[data-repo="bbs"]:hover { color: #3d8bff; }
.suite-bar a[data-repo="go3270"]:hover { color: #a66bff; }
/* on the suite's own site the bar shows every repository in its colour */
.suite-bar--rainbow a[data-repo="D-Modem"] { color: #ff4d5e; }
.suite-bar--rainbow a[data-repo="hardware"] { color: #ff8a3d; }
.suite-bar--rainbow a[data-repo="app"] { color: #ffd23d; }
.suite-bar--rainbow a[data-repo="menu"] { color: #3ddc84; }
.suite-bar--rainbow a[data-repo="bbs"] { color: #3d8bff; }
.suite-bar--rainbow a[data-repo="go3270"] { color: #a66bff; }
.suite-bar--rainbow a[data-repo="brand"] { color: #f2f4fa; }

/* landing pages: a grid of cards (<div class="grid cards" markdown>) */
.md-typeset .grid.cards > ul > li { border-left: 3px solid var(--suite-accent); }
.md-typeset .suite-hero { display: flex; gap: 1.5rem; align-items: center; margin-bottom: 1rem; }
.md-typeset .suite-hero img { width: 6rem; height: 6rem; flex: none; }
@media (max-width: 30em) { .md-typeset .suite-hero { flex-direction: column; align-items: flex-start; } }

.md-typeset h1 { color: var(--md-default-fg-color); font-weight: 600; }
[data-md-color-scheme="slate"] .md-footer,
[data-md-color-scheme="slate"] .md-footer-meta { background-color: var(--suite-panel); }

/* reference tables: an option or key in the first column on one line */
.md-typeset td:first-child code { white-space: nowrap; }

/* a colour's sample, beside its value (brand's docs/reference.md) */
.md-typeset .suite-swatch {
  display: inline-block;
  width: 0.9em;
  height: 0.9em;
  margin-right: 0.3em;
  vertical-align: -0.1em;
  border-radius: 0.15em;
  box-shadow: 0 0 0 1px var(--md-default-fg-color--lighter);
}

/* the suite's home page (<div class="suite-home" markdown> around it): each
   repository's card and links in its own Rainbow Book */
.md-typeset .suite-home a[href^="https://github.com/D-Modem/D-Modem"], .md-typeset .suite-home a[href^="https://d-modem.github.io/D-Modem/"] { color: #ff4d5e; }
.md-typeset .suite-home .grid.cards > ul > li:has(> p:first-child a[href^="https://github.com/D-Modem/D-Modem"]) { border-left-color: #ff4d5e; }
.md-typeset .suite-home a[href^="https://github.com/D-Modem/hardware"], .md-typeset .suite-home a[href^="https://d-modem.github.io/hardware/"] { color: #ff8a3d; }
.md-typeset .suite-home .grid.cards > ul > li:has(> p:first-child a[href^="https://github.com/D-Modem/hardware"]) { border-left-color: #ff8a3d; }
.md-typeset .suite-home a[href^="https://github.com/D-Modem/app"], .md-typeset .suite-home a[href^="https://d-modem.github.io/app/"] { color: #ffd23d; }
.md-typeset .suite-home .grid.cards > ul > li:has(> p:first-child a[href^="https://github.com/D-Modem/app"]) { border-left-color: #ffd23d; }
.md-typeset .suite-home a[href^="https://github.com/D-Modem/menu"], .md-typeset .suite-home a[href^="https://d-modem.github.io/menu/"] { color: #3ddc84; }
.md-typeset .suite-home .grid.cards > ul > li:has(> p:first-child a[href^="https://github.com/D-Modem/menu"]) { border-left-color: #3ddc84; }
.md-typeset .suite-home a[href^="https://github.com/D-Modem/bbs"], .md-typeset .suite-home a[href^="https://d-modem.github.io/bbs/"] { color: #3d8bff; }
.md-typeset .suite-home .grid.cards > ul > li:has(> p:first-child a[href^="https://github.com/D-Modem/bbs"]) { border-left-color: #3d8bff; }
.md-typeset .suite-home a[href^="https://github.com/D-Modem/go3270"], .md-typeset .suite-home a[href^="https://d-modem.github.io/go3270/"] { color: #a66bff; }
.md-typeset .suite-home .grid.cards > ul > li:has(> p:first-child a[href^="https://github.com/D-Modem/go3270"]) { border-left-color: #a66bff; }
.md-typeset .suite-home a[href^="https://github.com/D-Modem/gui"], .md-typeset .suite-home a[href^="https://d-modem.github.io/gui/"] { color: #c8102e; }
.md-typeset .suite-home .grid.cards > ul > li:has(> p:first-child a[href^="https://github.com/D-Modem/gui"]) { border-left-color: #c8102e; }
.md-typeset .suite-home a[href^="https://github.com/D-Modem/brand"], .md-typeset .suite-home a[href^="https://d-modem.github.io/brand/"] { color: #f2f4fa; }
.md-typeset .suite-home .grid.cards > ul > li:has(> p:first-child a[href^="https://github.com/D-Modem/brand"]) { border-left-color: #f2f4fa; }
[data-md-color-scheme="default"] .md-typeset .suite-home a[href^="https://github.com/D-Modem/brand"] { color: #5a6380; }
[data-md-color-scheme="default"] .md-typeset .suite-home a { filter: brightness(0.75); }
