:root {
    color-scheme: dark;

    --code-font: 'Fira Code', 'Roboto Mono', monospace;
    --md-linear-progress-track-color: transparent
}

@keyframes flash {
    0% {
        background-color: var(--md-sys-color-surface);
    }

    50% {
        background-color: var(--md-sys-color-secondary-container);
    }

    100% {
        background-color: var(--md-sys-color-surface);
    }
}

.version-header {
    display: flex;
    align-items: center;
    gap: 10px;
}

.table-icon {
    fill: var(--md-sys-color-primary)
}

.header-svg {
    width: 48px;
    height: 48px;
    fill: var(--md-sys-color-on-surface);
}

/* @media (min-width: 900px) {
    .toc {
        top: 96px;
        float: right;
        width: 280px;
        margin-left: 32px;
        max-height: calc(100vh - 120px);
        overflow-y: auto;
    }

    .doc-page {
        display: block;
    }
} */

#loading-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 999;
    margin-bottom: 10px;

    transition: opacity 0.3s ease, transform 0.3s ease;
    opacity: 0;
    transform: translateY(-5px);
    pointer-events: none;
}

#loading-bar.visible {
    opacity: 1;
    transform: translateY(0);
    /* Slide down into view */
    pointer-events: auto;
}

h2:hover,
h3:hover,
h4:hover {
    background: var(--md-sys-color-surface-container-highest) !important;
    border-radius: 8px;
    cursor: default;
}

.version-badge {
    height: 22px;
    margin-left: auto;
    border-radius: 6px;
}

.toc {
    margin: 16px 0;
    padding: 20px;
    border-radius: 16px;
    background: var(--md-sys-color-surface-container-low) !important;
    border: 1px solid var(--md-sys-color-outline-variant);
}

.toc h2 {
    margin-top: 0px;
    color: var(--md-sys-color-on-primary-container);
}

.toc a:link {
    color: var(--md-sys-color-primary);
}

.toc a:visited {
    color: var(--md-sys-color-primary);
}

.toc a:hover {
    text-decoration: underline;
    font-weight: bold;
}

.toc ul {
    list-style-type: none;
    padding-left: 0;
    margin: 0;
}

.toc li {
    margin-bottom: 0.4rem;
}

.toc li a {
    display: block;
    padding: 0.35rem 0.5rem;
    text-decoration: none;
    border-radius: 8px;
}

.toc ul ul {
    padding-left: 2rem;
}

.toc ul ul ul {
    padding-left: 2rem;
}

.toc li a.active {
    font-weight: 600;
    color: var(--md-sys-color-on-surface);
}

#to-top {
    position: fixed;
    right: 1.5rem;
    bottom: 1.5rem;
    z-index: 1000;

    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);

    transition:
        opacity 0.25s ease,
        transform 0.25s ease;
}

#to-top.visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}


.code-block {
    background: var(--md-sys-color-surface-container-high) !important;
    color: var(--md-sys-color-on-surface);

    padding: 16px;
    border-radius: 16px;
    overflow-x: auto;
    font-family: var(--code-font);
    font-size: clamp(13px, 0.9rem, 15px);

    border: 1px solid var(--md-sys-color-outline-variant);

    scrollbar-width: thin;
    scrollbar-color: var(--md-sys-color-outline-variant) transparent;
}

pre[class*="language-"],
code[class*="language-"],
code {
    background: var(--md-sys-color-surface-container) !important;
    border-radius: 10px;
    padding: 1.5px;
}

.code-block code {
    display: block;
    white-space: pre;
    background: transparent !important;
    padding: 0;
    border-radius: 0;
}

:not(pre)>code {
    background: var(--md-sys-color-surface-container) !important;
    color: var(--md-sys-color-primary);
    padding: 2px 6px;
    border-radius: 6px;
    font-family: var(--code-font);
    font-size: 0.9em;
    border: 1px solid var(--md-sys-color-outline-variant);
}

.toc ul ul {
    padding-left: 16px;
    border-left: 1px solid var(--md-sys-color-outline-variant);
    margin-left: 8px;
}

.banner {
    position: relative;
    width: 100%;
}

.header-copy-btn {
    display: inline-flex;
    vertical-align: middle;
    margin-right: 8px;
    width: 24px;
    height: 24px;
    padding: 0;
}

.header-copy-btn md-icon {
    width: 20px;
    height: 20px;
}

.header-tabs-phone-div {
    bottom: 0;
    position: fixed;
    z-index: 99;
    width: 100%;
    padding: 0;
}

.header-tabs {
    top: 0;
    position: sticky;
    z-index: 99;
    width: 100%;
    padding: 0;
}

@media (max-width: 600px) {
    .header-image {
        max-height: 200px;
        border-radius: 15px;
    }

    #to-top {
        bottom: 5rem;
    }

    .header-tabs {
        display: none
    }

    .header-tabs-phone-div {
        display: block
    }
}

@media (min-width: 600px) {
    .header-tabs {
        display: block
    }

    .header-tabs-phone-div {
        display: none
    }
}

.profile-pic {
    position: absolute;
    bottom: 45px;
    width: clamp(125px, 30%, 225px);
    height: auto;
    border-radius: 50%;
    object-fit: cover;
    background-color: #fff;
    left: 50%;
    transform: translateX(-50%);
    box-shadow: 0 4px 10px #0000004d;
}

@media (min-width: 600px) {
    .header-tabs {
        display: block
    }

    .header-tabs-phone-div {
        display: none
    }

    .profile-pic {
        width: clamp(80px, 25%, 175px);

    }
}



.header-image {
    height: 250px;
    width: 100%;
    aspect-ratio: 16 / 6;
    flex-shrink: 0;
    object-fit: cover;
    border-radius: 30px;
}

body {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    padding: 20px;
    overflow-x: hidden;
    min-height: 100vh;
    background: var(--md-sys-color-background);
    color: var(--md-sys-color-on-background);
    font-family: 'Roboto', sans-serif;
}

.center {
    text-align: center;
    width: 100%;
    /* max-width: 800px; */
    padding: 0 20px;
    box-sizing: border-box;
    margin: 0 auto;
}

md-divider {
    width: 100%;
    max-width: 100%;
    width: 100%;
}

.page-content p,
.body-div {
    font-size: clamp(14px, 4vw, 18px);
    width: 100%;
}

.button-row {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin-bottom: 2.5%;
}

@media (max-width: 600px) {
    .button-row {
        flex-direction: column;
        gap: 8px;
    }
}

.page-content {
    margin-top: 2.5%;
    margin-bottom: 2.5%;
}

.page-content table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.icon {
    height: 40px;
    display: block;
    margin: auto;
    width: 50%;
}

.table-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 16px;
    border: 1px solid var(--md-sys-color-outline-variant);
}

table {
    width: 100%;
    border-collapse: collapse;
    background: var(--md-sys-color-surface-container-low) !important;
    font-family: var(--md-sys-typescale-body-medium-font);
    letter-spacing: var(--md-sys-typescale-body-medium-tracking);
}

th {
    background: var(--md-sys-color-surface-container-high) !important;
    color: var(--md-sys-color-on-surface-variant);
    font-weight: 500;
    text-align: left;
    padding: 12px 16px;
    border-bottom: 1px solid var(--md-sys-color-outline-variant);
}

td {
    padding: 16px;
    color: var(--md-sys-color-on-surface);
    border-bottom: 1px solid var(--md-sys-color-outline-variant);
}

tr:last-of-type td {
    border-bottom: none;
}

tr:hover td {
    background-color: var(--md-sys-color-surface-container-low);
}

body {
    font-size: 16px;
    line-height: 1.5;
    letter-spacing: 0.5px;
    font-weight: 400;
    -webkit-font-smoothing: antialiased;
}

p {
    margin-bottom: 16px;
    color: var(--md-sys-color-on-surface);
}

small,
.text-label {
    font-size: 0.875rem;
    /* 14px */
    line-height: 1.4;
    color: var(--md-sys-color-on-surface-variant);
}

a {
    color: var(--md-sys-color-primary);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    transition: var(--md-transition);
    padding: 2px 4px;
    margin: -2px -4px;
    border-radius: 4px;
}

a:hover {
    background-color: var(--md-sys-color-surface-container-high);
    color: var(--md-sys-color-primary);
    text-decoration: underline;
    text-underline-offset: 4px;
}

a:active {
    background-color: color-mix(in srgb, var(--md-sys-color-primary) 12%, transparent);
}

a:visited {
    color: var(--md-sys-color-secondary);
}

a[target="_blank"]::after {
    content: ' \2197';
    font-size: 0.8em;
    opacity: 0.7;
}

.doc-page {
    text-align: left;
    justify-content: left;
}

.header {
    display: flex;
    gap: 12px;
    justify-content: center;
    width: 100%;
    height: 100%;
    background-color: var(--md-sys-color-surface);
    padding: 10px;
    border-radius: 20px;
}

@media (max-width: 600px) {
    .header {
        flex-direction: column;
        align-items: center;
        gap: 8px;
        padding: 10px 5px;
    }

    .header-left,
    .header-right {
        margin: 0;
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 8px;
        width: 100%;
    }
}


.header-left {
    margin-right: auto;
    gap: 12px;
}

.header-right {
    margin-left: auto;
}

.centered-list {
    list-style-position: inside;
    text-align: center;
    padding: 0;
    margin: 0;
}

.arrow {
    margin-bottom: 2.5%;
}

.welcome-text {
    font-weight: bold;
    margin-bottom: 0px;
}

.divider {
    margin-bottom: 2.5%;
}

.subpage img {
    max-width: 100%;
    max-height: 300px;
    width: auto;
    height: auto;
    display: block;
    margin: 10px auto;
}