/* Fulcrum-style theme for Material MkDocs */

/* Import fonts - Courier Prime for body, Inter for headers */
@import url('https://fonts.googleapis.com/css2?family=Courier+Prime:wght@400;700&family=Inter:wght@400;500;600&display=swap');

/* CSS Custom Properties */
:root,
[data-md-color-scheme="default"],
[data-md-color-scheme="slate"] {
    --md-primary-fg-color: #333;
    --md-primary-bg-color: #ded5bd;
    --md-accent-fg-color: #333;
    --md-default-bg-color: #ded5bd;
    --md-default-fg-color: #333;
    --md-default-fg-color--light: #555;
    --md-default-fg-color--lighter: #777;
    --md-default-fg-color--lightest: #999;

    /* Typography */
    --md-text-font: "Courier Prime", monospace;
    --md-code-font: "Courier Prime", monospace;

    /* Code block colors - from Fulcrum */
    --md-code-bg-color: #2d2d2d;
    --md-code-fg-color: #f8f8f2;

    /* Footer */
    --md-footer-bg-color: #333;
    --md-footer-fg-color: #ded5bd;

    /* Force beige everywhere */
    --md-typeset-table-color: #ded5bd;
}

/* Reset root font size to browser default (16px) */
html {
    font-size: 16px !important;
}

/* Global beige background */
html,
body,
.md-container,
.md-main,
.md-main__inner,
.md-content,
.md-sidebar,
.md-sidebar__scrollwrap,
.md-sidebar__inner,
.md-nav,
.md-tabs,
.md-header,
.md-typeset {
    background-color: #ded5bd !important;
}

/* Body and general typography */
body {
    font-family: "Courier Prime", monospace !important;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.6;
}

.md-content {
    max-width: 700px;
}

/* Headers - Inter font, normal weight */
.md-typeset h1,
.md-typeset h2,
.md-typeset h3,
.md-typeset h4,
.md-typeset h5,
.md-typeset h6 {
    font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
    font-weight: normal;
    color: #333;
    letter-spacing: -0.01em;
}

.md-typeset h1 {
    font-size: 1.6rem;
    margin-bottom: 1.5rem;
    line-height: 1.3;
    letter-spacing: 0.5px;
}

.md-typeset h2 {
    font-size: 1.4rem;
    margin-top: 2.5rem;
    margin-bottom: 1.25rem;
}

.md-typeset h3 {
    font-size: 1.2rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.md-typeset h4 {
    font-size: 1.05rem;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

/* Paragraphs - exact Fulcrum styling */
.md-typeset p {
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

/* Content text */
.md-typeset {
    font-size: 1rem;
    line-height: 1.6;
}

/* Links - dotted underline style */
.md-typeset a {
    color: #333;
    text-decoration: none;
    border-bottom: 1px dotted #333;
    transition: opacity 0.2s;
}

.md-typeset a:hover {
    opacity: 0.7;
}

/* Navigation links - no underline */
.md-nav__link,
.md-nav__link:hover {
    border-bottom: none !important;
}

.md-nav__link:hover {
    opacity: 0.7;
}

/* Header bar - black background */
.md-header,
.md-header *,
.md-header__inner,
.md-header__ellipsis,
.md-header__title,
.md-header__topic {
    background-color: #333 !important;
}

.md-header {
    color: #ded5bd !important;
    box-shadow: none;
    height: 60px;
}

.md-header__inner {
    height: 60px;
}

.md-header[data-md-state="shadow"] {
    box-shadow: none;
}

.md-header__title,
.md-header__button,
.md-header .md-ellipsis,
.md-header__topic {
    color: #ded5bd !important;
    font-size: 1.1rem !important;
}

/* Larger logo in header */
.md-header .md-logo img,
.md-header .md-logo svg {
    height: 36px !important;
    width: 36px !important;
}

/* Sign up link in header */
.md-header__signup {
    color: #ded5bd !important;
    font-family: "Courier Prime", monospace;
    font-size: 0.9rem;
    text-decoration: none !important;
    border-bottom: none !important;
    margin-left: 0.5rem;
}

.md-header__signup:hover {
    opacity: 0.7;
}



/* Hide nav title */
.md-nav__title {
    display: none !important;
}


/* Make title a clickable link via JavaScript injection */
.md-header__title {
    cursor: pointer;
}

/* Search in header */
.md-search,
.md-search__inner,
.md-search__form {
    background-color: #333 !important;
}

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

.md-search__input::placeholder {
    color: rgba(255, 255, 255, 0.6) !important;
}

.md-search__icon {
    color: #fff !important;
}


/* Sidebar and TOC */
.md-sidebar {
    background-color: #ded5bd !important;
}

.md-sidebar__scrollwrap {
    background-color: #ded5bd !important;
}

.md-nav__item .md-nav__link {
    font-family: "Courier Prime", monospace;
    font-size: 0.95rem;
}

.md-nav--primary .md-nav__title {
    font-size: 1rem;
}

/* Table of contents */
.md-nav--secondary,
.md-nav--secondary .md-nav__list {
    background-color: #ded5bd !important;
}

.md-nav--secondary .md-nav__link {
    font-size: 0.95rem;
}

.md-nav--secondary .md-nav__title {
    font-size: 1rem;
    font-weight: normal;
}

/* Code blocks - Gruvbox dark theme */
.md-typeset code {
    font-family: 'Courier Prime', 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 0.85rem;
    background-color: #282828;
    color: #ebdbb2;
    padding: 0.2em 0.4em;
    border-radius: 3px;
}

.md-typeset pre {
    background-color: #282828;
    color: #ebdbb2;
    padding: 1rem;
    border-radius: 5px;
    overflow-x: auto;
    margin: 1.5rem 0;
    line-height: 1.5;
}

.md-typeset pre code {
    background-color: transparent;
    padding: 0;
    font-size: 0.85rem;
    color: inherit;
}

/* Inline code - subtle background on beige */
.md-typeset :not(pre) > code {
    background-color: rgba(0, 0, 0, 0.08);
    color: #333;
}

/* mkdocstrings function signatures - subtle background, no syntax highlighting */
.doc-signature,
.doc-signature code,
.doc-signature .highlight,
.doc-signature .highlight pre,
.doc-signature .highlight code,
.doc-function code,
.doc-function .highlight,
.doc-function .highlight pre,
.doc-function .highlight code {
    background-color: rgba(0, 0, 0, 0.08) !important;
    color: #333 !important;
    font-family: "Courier Prime", monospace;
}

.doc-signature .highlight span,
.doc-function .highlight span,
.doc-function code span {
    color: #333 !important;
    font-style: normal !important;
    font-weight: normal !important;
}

/* Override highlight background specifically for doc-function */
.md-typeset .doc-function .highlight {
    background-color: rgba(0, 0, 0, 0.08) !important;
}

/* mkdocstrings example blocks - remove purple border */
.md-typeset details.example {
    border-color: #333 !important;
}

/* Syntax highlighting - Gruvbox dark */
.highlight,
.highlighttable,
.md-typeset .highlight {
    background-color: #282828 !important;
    border-radius: 5px;
    margin: 1.5rem 0;
}

.highlight pre,
.md-typeset .highlight pre {
    background-color: transparent !important;
    margin: 0;
}

.highlighttable {
    background-color: #282828 !important;
}

.highlighttable td {
    background-color: #282828 !important;
}

/* Gruvbox syntax highlighting colors */
.highlight .hll { background-color: #3c3836; }
.highlight .c { color: #928374; font-style: italic; } /* Comment */
.highlight .err { color: #fb4934; } /* Error */
.highlight .k { color: #fb4934; } /* Keyword */
.highlight .o { color: #ebdbb2; } /* Operator */
.highlight .ch { color: #928374; font-style: italic; } /* Comment.Hashbang */
.highlight .cm { color: #928374; font-style: italic; } /* Comment.Multiline */
.highlight .cp { color: #8ec07c; } /* Comment.Preproc */
.highlight .cpf { color: #928374; font-style: italic; } /* Comment.PreprocFile */
.highlight .c1 { color: #928374; font-style: italic; } /* Comment.Single */
.highlight .cs { color: #928374; font-style: italic; } /* Comment.Special */
.highlight .gd { color: #fb4934; } /* Generic.Deleted */
.highlight .ge { font-style: italic; } /* Generic.Emph */
.highlight .gr { color: #fb4934; } /* Generic.Error */
.highlight .gh { color: #b8bb26; font-weight: bold; } /* Generic.Heading */
.highlight .gi { color: #b8bb26; } /* Generic.Inserted */
.highlight .go { color: #928374; } /* Generic.Output */
.highlight .gp { color: #a89984; } /* Generic.Prompt */
.highlight .gs { font-weight: bold; } /* Generic.Strong */
.highlight .gu { color: #8ec07c; font-weight: bold; } /* Generic.Subheading */
.highlight .gt { color: #fb4934; } /* Generic.Traceback */
.highlight .kc { color: #fb4934; } /* Keyword.Constant */
.highlight .kd { color: #fb4934; } /* Keyword.Declaration */
.highlight .kn { color: #8ec07c; } /* Keyword.Namespace */
.highlight .kp { color: #fb4934; } /* Keyword.Pseudo */
.highlight .kr { color: #fb4934; } /* Keyword.Reserved */
.highlight .kt { color: #fabd2f; } /* Keyword.Type */
.highlight .ld { color: #b8bb26; } /* Literal.Date */
.highlight .m { color: #d3869b; } /* Literal.Number */
.highlight .s { color: #b8bb26; } /* Literal.String */
.highlight .na { color: #b8bb26; } /* Name.Attribute */
.highlight .nb { color: #fabd2f; } /* Name.Builtin */
.highlight .nc { color: #8ec07c; } /* Name.Class */
.highlight .no { color: #d3869b; } /* Name.Constant */
.highlight .nd { color: #8ec07c; } /* Name.Decorator */
.highlight .ni { color: #fabd2f; } /* Name.Entity */
.highlight .ne { color: #fb4934; } /* Name.Exception */
.highlight .nf { color: #b8bb26; } /* Name.Function */
.highlight .nl { color: #fb4934; } /* Name.Label */
.highlight .nn { color: #ebdbb2; } /* Name.Namespace */
.highlight .nx { color: #ebdbb2; } /* Name.Other */
.highlight .py { color: #ebdbb2; } /* Name.Property */
.highlight .nt { color: #fb4934; } /* Name.Tag */
.highlight .nv { color: #83a598; } /* Name.Variable */
.highlight .ow { color: #fe8019; } /* Operator.Word */
.highlight .w { color: #ebdbb2; } /* Text.Whitespace */
.highlight .mb { color: #d3869b; } /* Literal.Number.Bin */
.highlight .mf { color: #d3869b; } /* Literal.Number.Float */
.highlight .mh { color: #d3869b; } /* Literal.Number.Hex */
.highlight .mi { color: #d3869b; } /* Literal.Number.Integer */
.highlight .mo { color: #d3869b; } /* Literal.Number.Oct */
.highlight .sa { color: #b8bb26; } /* Literal.String.Affix */
.highlight .sb { color: #b8bb26; } /* Literal.String.Backtick */
.highlight .sc { color: #b8bb26; } /* Literal.String.Char */
.highlight .dl { color: #b8bb26; } /* Literal.String.Delimiter */
.highlight .sd { color: #b8bb26; } /* Literal.String.Doc */
.highlight .s2 { color: #b8bb26; } /* Literal.String.Double */
.highlight .se { color: #fe8019; } /* Literal.String.Escape */
.highlight .sh { color: #b8bb26; } /* Literal.String.Heredoc */
.highlight .si { color: #b8bb26; } /* Literal.String.Interpol */
.highlight .sx { color: #b8bb26; } /* Literal.String.Other */
.highlight .sr { color: #b8bb26; } /* Literal.String.Regex */
.highlight .s1 { color: #b8bb26; } /* Literal.String.Single */
.highlight .ss { color: #83a598; } /* Literal.String.Symbol */
.highlight .bp { color: #fabd2f; } /* Name.Builtin.Pseudo */
.highlight .fm { color: #b8bb26; } /* Name.Function.Magic */
.highlight .vc { color: #83a598; } /* Name.Variable.Class */
.highlight .vg { color: #83a598; } /* Name.Variable.Global */
.highlight .vi { color: #83a598; } /* Name.Variable.Instance */
.highlight .vm { color: #83a598; } /* Name.Variable.Magic */
.highlight .il { color: #d3869b; } /* Literal.Number.Integer.Long */

/* Code copy button */
.md-clipboard {
    color: #ebdbb2 !important;
}

.md-code__button {
    color: #ebdbb2 !important;
}

/* Tables - beige background */
.md-typeset table:not([class]) {
    font-size: 0.9rem;
    border: 1px dotted #333;
    background-color: #ded5bd !important;
}

.md-typeset table:not([class]) th {
    background-color: #ded5bd !important;
    font-family: "Inter", sans-serif;
    font-weight: 500;
    border-bottom: 1px dotted #333;
}

.md-typeset table:not([class]) td {
    background-color: #ded5bd !important;
    border-bottom: 1px dotted #777;
}

.md-typeset table:not([class]) tr {
    background-color: #ded5bd !important;
}

.md-typeset table:not([class]) tr:hover {
    background-color: rgba(0, 0, 0, 0.03) !important;
}

/* All tables */
.md-typeset__table {
    background-color: #ded5bd !important;
}

table, th, td, tr {
    background-color: #ded5bd !important;
}

/* Lists - exact Fulcrum styling */
.md-typeset ol,
.md-typeset ul {
    margin-left: 1.75rem;
    margin-bottom: 1.25rem;
}

.md-typeset li {
    margin-bottom: 0.6rem;
    line-height: 1.7;
}

.md-typeset strong {
    font-weight: bold;
}

/* Admonitions */
.md-typeset .admonition {
    border: 1px dotted #333;
    border-radius: 0;
    background-color: #ded5bd !important;
    box-shadow: none;
}

.md-typeset .admonition-title {
    font-family: "Inter", sans-serif;
    background-color: #ded5bd !important;
    border-bottom: 1px dotted #777;
    font-weight: 500;
}

.md-typeset .admonition-title::before {
    display: none;
}

/* Details/collapsible */
.md-typeset details {
    background-color: #ded5bd !important;
    border: 1px dotted #333;
}

.md-typeset details summary {
    background-color: #ded5bd !important;
}

/* Footer */
.md-footer {
    background-color: #333 !important;
    color: #ded5bd;
    border-top: 1px dotted #333;
}

.md-footer a {
    color: #ded5bd;
    border-bottom-color: #ded5bd;
}

.md-footer-meta {
    background-color: #333 !important;
}

.md-footer-nav {
    background-color: #333 !important;
}

/* Back to top button */
.md-top {
    background-color: #333 !important;
    color: #ded5bd !important;
    border: none;
}

.md-top:hover {
    background-color: #555 !important;
}

/* Tabs */
.md-typeset .tabbed-labels {
    background-color: #ded5bd !important;
}

.md-typeset .tabbed-labels > label {
    font-family: "Courier Prime", monospace;
    font-weight: 400;
    border-bottom: 1px dotted transparent;
    background-color: #ded5bd !important;
}

.md-typeset .tabbed-labels > label:hover {
    color: #333;
}

.md-typeset .tabbed-content {
    background-color: #ded5bd !important;
}

/* Content tabs indicator */
.md-typeset .tabbed-set > input:checked + label {
    border-color: #333;
}

/* TOC active state */
.md-nav__link--active {
    font-weight: 400;
}

/* Buttons */
.md-typeset .md-button {
    font-family: "Courier Prime", monospace;
    border: 1px solid #333;
    background-color: transparent;
    color: #333;
    border-radius: 0;
    transition: all 0.2s;
}

.md-typeset .md-button:hover {
    background-color: #333;
    color: #ded5bd;
}

/* Hide color scheme toggle */
.md-header__option {
    display: none;
}

/* Source code annotations */
.md-annotation__index {
    background-color: #333 !important;
    color: #ded5bd !important;
}

/* Version selector */
.md-version {
    font-family: "Courier Prime", monospace;
}

/* Scrollbar for code */
.md-typeset pre::-webkit-scrollbar {
    height: 6px;
}

.md-typeset pre::-webkit-scrollbar-thumb {
    background-color: #928374;
    border-radius: 3px;
}

.md-typeset pre::-webkit-scrollbar-track {
    background-color: #3c3836;
}

/* Dialog/modal backgrounds */
.md-dialog {
    background-color: #ded5bd !important;
}

/* Source view */
.md-source {
    background-color: transparent !important;
}

/* Instant loading progress bar */
.md-progress {
    background-color: #333 !important;
}

/* Navigation expansion */
.md-nav__toggle ~ .md-nav {
    background-color: #ded5bd !important;
}

/* Permalink anchors */
.md-typeset .headerlink {
    color: #777;
    border-bottom: none !important;
}

.md-typeset .headerlink:hover {
    color: #333;
    opacity: 1;
}

/* Content wrapper */
.md-content__inner {
    background-color: #ded5bd !important;
}

/* Ensure all Material components use beige */
[data-md-component] {
    background-color: #ded5bd;
}

/* Override any remaining whites */
.md-typeset__scrollwrap {
    background-color: #ded5bd !important;
}

.md-typeset__table {
    background-color: #ded5bd !important;
}
