/* Fonts */
@import url('https://fonts.googleapis.com/css2?family=Libre+Baskerville:wght@400;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Cabin:wght@400;500;600&display=swap');
@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500;600&display=swap');

/* ===================================================================
   LFE theme (lfe-pdp)
   -------------------------------------------------------------------
   Previously lived in theme/css/variables.css, which forked all of
   mdBook's internal theme CSS and drifted out of sync with the
   element IDs/markup of newer mdBook releases. We now let mdBook ship
   its own (version-correct) internal theme files and layer only our
   customizations here, via `additional-css` in book.toml. This file
   loads AFTER mdBook's variables.css, so these values win.
   =================================================================== */

/* Layout overrides (design-critical widths) */
:root {
    --sidebar-target-width: 300px;
    --content-max-width: 750px;
}

/* Custom theme: set as default-theme / preferred-dark-theme in book.toml.
   mdBook applies the `lfe-pdp` class to <html>; these vars colour it. */
.lfe-pdp {
    --bg: #D9D8D4;
    --fg: #1E252B;

    --sidebar-bg: #16161A;
    --sidebar-fg: #ECE5C9;
    --sidebar-non-existant: #505254;
    --sidebar-active: #377CA2;
    --sidebar-spacer: #0B2D3F;

    --scrollbar: var(--sidebar-fg);

    --icons: #737480;
    --icons-hover: #1E252B;

    --links: #377CA2;

    --inline-code-color: #16455E;
    --inline-code-background-color: transparent;

    --theme-popup-bg: #DDD09C;
    --theme-popup-border: #b38f6b;
    --theme-hover: #B4BEC4;

    --quote-bg: hsl(60, 5%, 75%);
    --quote-border: hsl(60, 5%, 70%);

    --table-border-color: hsl(60, 9%, 82%);
    --table-header-bg: #b3a497;
    --table-alternate-bg: hsl(60, 9%, 84%);

    --searchbar-border-color: #aaa;
    --searchbar-bg: #fafafa;
    --searchbar-fg: #000;
    --searchbar-shadow-color: #aaa;
    --searchresults-header-fg: #666;
    --searchresults-border-color: #888;
    --searchresults-li-bg: #dec2a2;
    --search-mark-bg: #e69f67;

    /* Custom alert styles */
    --alert-primary-fg:  #1a3047;
    --alert-primary-bg: #325D88;
    --alert-primary-border:  #c6d2de;
    --alert-primary-hr:  #b6c5d5;
    --alert-primary-link: #0c1722;

    --alert-secondary-fg:  #4a4945;
    --alert-secondary-bg: #8E8C84;
    --alert-secondary-border:  #b4b465;
    --alert-secondary-hr:  #d3d3d0;
    --alert-secondary-link: #302f2c;

    --alert-success-fg:  #4c6627;
    --alert-success-bg: #93C54B;
    --alert-success-border:  #94b861;
    --alert-success-hr:  #d5e9ba;
    --alert-success-link: #314119;

    --alert-info-fg:  #155974;
    --alert-info-bg: #29ABE0;
    --alert-info-border:  #66a6c2;
    --alert-info-hr:  #addef3;
    --alert-info-link: #0d3849;

    --alert-warning-fg:  #7f401f;
    --alert-warning-bg: #F47C3C;
    --alert-warning-border:  #ce865f;
    --alert-warning-hr:  #fbcab0;
    --alert-warning-link: #562b15;

    --alert-danger-fg:  #712b29;
    --alert-danger-bg: #d9534f;
    --alert-danger-border:  #c07471;
    --alert-danger-hr:  #efbbb9;
    --alert-danger-link: #4c1d1b;

    --warning-border: #ff8e00;

    --color-scheme: light;

    --copy-button-filter: invert(45%) sepia(6%) saturate(621%) hue-rotate(198deg) brightness(99%) contrast(85%);
    --copy-button-filter-hover: invert(36%) sepia(70%) saturate(503%) hue-rotate(167deg) brightness(98%) contrast(89%);

    --footnote-highlight: #d3a17a;

    --overlay-bg: rgba(150, 150, 150, 0.25);
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Libre Baskerville', serif;
}

/* Body text */
body, p {
    font-family: 'Cabin', sans-serif;
    font-size: 16px;
    line-height: 2;
}

/* Code */
code, pre {
    font-family: 'IBM Plex Mono', monospace !important;
    font-size: 0.9em;
    line-height: 1.5;
}

code,
:not(pre):not(a)>.hljs {
    background-color: var(--inline-code-background-color);
    color: var(--inline-code-color);
}

blockquote {
    font-family: 'Libre Baskerville', serif;
    padding-left: 3em;
    padding-right: 3em;
    padding-top: 1em;
    padding-bottom: 1em;
}

.alert {
    position: relative;
    padding: 0.75rem 1.25rem;
    margin-bottom: 1rem;
    border: 1px solid transparent;
    border-radius: 6px;
    font-size: 18px;
    font-weight: 700;
}

.alert-heading {
    color: inherit;
    margin: 0;
    padding: 0;
}

.alert-link {
    font-weight: 700;
}

.alert-primary {
    color: #1a3047;
    background-color: #d6dfe7;
    border-color: #c6d2de;
}

.alert-primary hr {
    border-top-color: #b6c5d5;
}

.alert-primary .alert-link {
    color: #0c1722;
}

.alert-secondary {
    color: #4a4945;
    background-color: #e8e8e6;
    border-color: #b4b465;
}

.alert-secondary hr {
    border-top-color: #d3d3d0;
}

.alert-secondary .alert-link {
    color: #302f2c;
}

.alert-success {
    color: #4c6627;
    background-color: #e9f3db;
    border-color: #94b861;
}

.alert-success hr {
    border-top-color: #d5e9ba;
}

.alert-success .alert-link {
    color: #314119;
}

.alert-info {
    color: #155974;
    background-color: #d4eef9;
    border-color: #66a6c2;
}

.alert-info hr {
    border-top-color: #addef3;
}

.alert-info .alert-link {
    color: #0d3849;
}

.alert-warning {
    color: #7f401f;
    background-color: #fde5d8;
    border-color: #ce865f;
}

.alert-warning hr {
    border-top-color: #fbcab0;
}

.alert-warning .alert-link {
    color: #562b15;
}

.alert-danger {
    color: #712b29;
    background-color: #f7dddc;
    border-color: #c07471;
}

.alert-danger hr {
    border-top-color: #efbbb9;
}

.alert-danger .alert-link {
    color: #4c1d1b;
}

.alert-primary,
.alert-primary>th,
.alert-primary>td {
    background-color: #325D88;
}

.alert-secondary,
.alert-secondary>th,
.alert-secondary>td {
    background-color: #8E8C84;
}

.alert-success,
.alert-success>th,
.alert-success>td {
    background-color: #93C54B;
}

.alert-info,
.alert-info>th,
.alert-info>td {
    background-color: #29ABE0;
}

.alert-danger,
.alert-danger>th,
.alert-danger>td {
    background-color: #d9534f;
}

.alert-warning,
.alert-warning>th,
.alert-warning>td {
    background-color: #F47C3C;
}

img.liffy-bot-alert {
    opacity: 0.60 !important;
}

h4.alert-heading img.liffy-bot-alert {
    height: 18px !important;
}

img.liffy-bot-mascot {
    height: 100px;
    float: left;
}

.footnotes {
    font-size: 10pt;
    padding-top: 2em;
    margin-top: 2em;
    padding-left: 0;
    padding-right: 0;
    margin-left: 0;
    margin-right: 0;
}

.footnotes ol,
.footnotes ol li {
    padding-left: 0;
    padding-right: 0;
    margin-left: 0.6em;
    margin-right: 0;
}

.footnotes ol {
    /* margin-left: -1em; */
}

.footnotes hr {
    border: 0;
    border-bottom: solid 1px #666;
}
