﻿:root {
    --sidebar-width: 240px;
    --min-main-width: 500px;
    --header-height: 15px;
}

@media (max-width: 1280px) {
    .hide-right {
        display: none !important;
    }
}

@media (max-width: 960px) {
    .hide-left {
        display: none !important;
    }
}

html, body {
    height: 100%;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

.layout-wrapper {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
    box-sizing: border-box;
}

.left-nav, .right-nav {
    width: var(--sidebar-width);
    flex-shrink: 0;
    max-height: calc(80vh - var(--header-height));
    overflow-y: auto;
    position: sticky;
    top: var(--header-height);
    word-break: break-word;
    overflow-wrap: break-word;
    text-overflow: ellipsis;
    white-space: normal;
    z-index: 1;
}

.left-nav {
    padding-top: 35px;
    padding-left: 5px;
}

.right-nav {
    padding-right: 5px;
}

.main-and-right {
    display: flex;
    flex-grow: 1;
    min-width: var(--min-main-width);
}

.main-content {
    flex-grow: 1;
    padding: 24px;
    min-width: var(--min-main-width);
    box-sizing: border-box;
}

.right-nav ol li {
    margin-bottom: 7px; /* or whatever spacing you want */
}

.right-nav ol {
    list-style: none;
    padding-left: 0;
}

.right-nav li::marker {
    display: none;
}
/* Inline code (NOT inside pre) */
.markdown-rendered-content code:not(pre code) {
    background-color: #0D1117; /* no boxy background */
    padding: 0.15rem 0.3rem;
    font-family: Consolas, monospace;
    border-radius: 4px;
    font-size: 0.95rem;
    color: #e5e7eb; /* light text for dark backgrounds */
}

/* Block code (fenced) */
.markdown-rendered-content pre code {
    background: #0D1117; /* let the codeblock container / hljs theme shine */
    padding: 0;
    font-family: Consolas, monospace;
    font-size: 0.95rem;
    color: #e5e7eb; /* hljs / Prism will apply syntax colors */
}

/* Optional: make inline code adapt to light/dark themes */
@media (prefers-color-scheme: light) {
    .markdown-rendered-content code:not(pre code) {
        color: #222; /* dark text for light themes */
    }
}

@media (prefers-color-scheme: dark) {
    .markdown-rendered-content code:not(pre code) {
        color: #eaeaea; /* light text for dark themes */
    }
}




.active-section-link {
    font-weight: bold;
    color: var(--mud-palette-primary);
}

.mud-treeview-item-content.hovering {
    background-color: rgba(0, 0, 0, 0.04);
}

.magic-paragraph {
    padding-top: 10px;
    padding-bottom: 10px;
}
.magic-muddrawer-navMenu {
    min-height: 100vh;
}

.magic-drawer-Open {
    width: 320px !important;
}

.magic-navMenu-wrap {
    position: fixed;
    top: 0;
    left: 0;
    padding-top: 68px;
}

.styled-quote {
    border-left: 4px solid #00E3C0;
    padding-left: 1em;
    margin-left: 0;
    padding-top: 5px;
    padding-bottom: 5px;
    margin-top: 5px;
    margin-bottom: 5px;
}

.magic-div {
    margin-top:40px;
    margin-bottom:20px;
}

/* Fullscreen popup overlay */
#disconnect-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8); /* Black background with opacity */
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100000 !important; /* Ensure it's above everything */
    visibility: hidden;
}

/* Popup content */
#disconnect-popup-content {
    text-align: center;
    color: white;
    background-color: #333;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* Refresh button style */
#refresh-button {
    margin-top: 20px;
    padding: 10px 20px;
    font-size: 16px;
    background-color: #007BFF;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

    #refresh-button:hover {
        background-color: #0056b3;
    }

/* Image div styling */
#disconnect-image-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 20px;
    width: 100%;
    height: auto; /* Ensure the image resizes with the screen */
}

/* Ensure the image is hidden by default */
#disconnect-image {
    display: none;
    max-width: 100%;
    height: auto;
}

.magic-paragraph ul {
    list-style-type: disc; /* Adds bullet points */
    padding-left: 1.5rem; /* Indents the list for better readability */
    margin: 1rem 0; /* Adds spacing above and below the list */
}

.magic-paragraph ul li {
    margin-bottom: 0.5rem; /* Adds spacing between each list item */
}


.markdown-table-container {
    overflow-x: auto;
    margin-top: 1rem;
    margin-bottom: 1rem;
    border: 1px solid #444;
    border-radius: 6px;
}

.markdown-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

    .markdown-table th,
    .markdown-table td {
        border: 1px solid #444;
        padding: 12px 16px;
        text-align: left;
        vertical-align: top;
        background-color: #111;
        color: #eee;
    }

    .markdown-table th {
        background-color: #1c1c1c;
        font-weight: 600;
    }

    .markdown-table code {
        background-color: #1e1e1e;
        padding: 2px 6px;
        border-radius: 4px;
        font-family: Consolas, Monaco, monospace;
        font-size: 0.95em;
        color: #c5c8c6;
    }

a.anchor-invisible-link {
    display: none !important;
}

.codeblock {
    position: relative;
    margin: 1rem 0;
    border: 1px solid var(--cborder, #e5e7eb);
    border-radius: 12px;
    overflow: hidden;
    background: #0d1117; /* dark bg pairs with github hl style nicely */
}

.codeblock-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: .5rem .75rem;
    background: #111827;
    color: #e5e7eb;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: .85rem;
}

.codeblock-title, .codeblock-lang {
    opacity: .9;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.codeblock-copy {
    border: 1px solid rgba(255,255,255,.15);
    background: transparent;
    color: #e5e7eb;
    border-radius: 8px;
    padding: .25rem .5rem;
    cursor: pointer;
}

    .codeblock-copy:hover {
        background: rgba(255,255,255,.06);
    }

.codeblock pre {
    margin: 0;
    overflow: auto;
    padding: .9rem 1rem;
}

/* line numbers plugin uses a table-like gutter; make it blend */
.hljs-ln-numbers {
    opacity: .55;
    text-align: right;
    user-select: none;
    padding-right: .75rem !important;
    border-right: 1px solid rgba(255,255,255,.08);
}

.codeblock-mermaid .codeblock-title {
    background: #0b1320;
}
