/**
 * Stack Overflow-inspired Theme for Prism.js
 * Theme variation: Light
 * @author Belle B. Cooper <belle@bellebcooper.com>
 * @homepage https://github.com/bellebethcooper/prism-stack-overflow
 * @license MIT
 */

/* Light mode */
:root {
    --orange: #B75301;
    --pink: #8E5572;
    --blue: #015493;
    --second-blue: #0B4F79;
    --teal: #087E6E;
    --green: #567A0D;
    --bg: #F6F6F6;
    --grey: #8F878E;
    --highlight: #EBEBEB;
    --toolbar-button-bg: #E6E8E8;
    --toolbar-button-hover-bg: #7883AD;
    --text-color: #000;
}

/* Dark mode */
@media (prefers-color-scheme: dark) {
    :root {
        --orange: #F69D50;
        --pink: #E55AA3;
        --blue: #6CB6FF;
        --second-blue: #96D0FF;
        --teal: #F46157;
        --green: #DCBDFB;
        --bg: #10131A;
        --grey: #768390;
        --highlight: #272D34;
        --toolbar-button-bg: #1E2329;
        --toolbar-button-hover-bg: #7883AD;
        --text-color: #C3D2E0;
    }
}

code[class*="language-"],
pre[class*="language-"] {
    color: var(--text-color);
    background: none;
    font-family: 'SF Mono', SFMono-Regular, ui-monospace, monospace;
    text-align: left;
    white-space: pre;
    word-spacing: normal;
    word-break: normal;
    word-wrap: normal;
    line-height: 1.5;
    -moz-tab-size: 4;
    -o-tab-size: 4;
    tab-size: 4;
    -webkit-hyphens: none;
    -moz-hyphens: none;
    -ms-hyphens: none;
    hyphens: none;
    padding: 0 60px 0 0;
}

pre[class*="language-"]::-moz-selection,
pre[class*="language-"] ::-moz-selection,
code[class*="language-"]::-moz-selection,
code[class*="language-"] ::-moz-selection {
    background-color: var(--highlight);
}

pre[class*="language-"]::selection,
pre[class*="language-"] ::selection,
code[class*="language-"]::selection,
code[class*="language-"] ::selection {
    background-color: var(--highlight);
}

/* Code blocks */
pre[class*="language-"] {
    padding: 1em;
    margin: 0.5em 0;
    overflow: auto;
}

:not(pre) > code[class*="language-"],
pre[class*="language-"] {
    background-color: var(--bg);
    border-radius: 6px;
}

/* Inline code */
:not(pre) > code[class*="language-"] {
    padding: 0.1em 0.3em;
    border-radius: 0.3em;
    white-space: normal;
}

.token.comment,
.token.prolog,
.token.doctype,
.token.cdata {
    color: var(--grey);
}

.token.punctuation {
    color: var(--grey);
}

.token.delimiter.important,
.token.selector .parent,
.token.tag,
.token.tag .token.punctuation {
    color: var(--pink);
}

.token.attr-name,
.token.boolean,
.token.boolean.important,
.token.number,
.token.constant,
.token.selector .token.attribute {
    color: var(--orange);
}

.token.class-name,
.token.key,
.token.parameter,
.token.property,
.token.property-access,
.token.variable {
    color: var(--blue);
}

.token.attr-value,
.token.inserted,
.token.color,
.token.selector .token.value,
.token.string,
.token.string .token.url-link {
    color: var(--green);
}

.token.builtin,
.token.keyword-array,
.token.package,
.token.regex {
    color: var(--teal);
}

.token.function,
.token.selector .token.class,
.token.selector .token.id {
    color: var(--green);
}

.token.atrule .token.rule,
.token.combinator,
.token.keyword,
.token.operator,
.token.pseudo-class,
.token.pseudo-element,
.token.selector,
.token.unit {
    color: var(--orange);
}

.token.deleted,
.token.important {
    color: var(--orange);
}

.token.keyword-this,
.token.this {
    color: var(--blue);
}

.token.important,
.token.keyword-this,
.token.this,
.token.bold {
    font-weight: bold;
}

.token.delimiter.important {
    font-weight: inherit;
}

.token.italic {
    font-style: italic;
}

.token.entity {
    cursor: help;
}

.language-markdown .token.title,
.language-markdown .token.title .token.punctuation {
    color: var(--blue);
    font-weight: bold;
}

.language-markdown .token.blockquote.punctuation {
    color: var(--pink);
}

.language-markdown .token.code {
    color: var(--teal);
}

.language-markdown .token.hr.punctuation {
    color: var(--blue);
}

.language-markdown .token.url .token.content {
    color: var(--green);
}

.language-markdown .token.url-link {
    color: var(--orange);
}

.language-markdown .token.list.punctuation {
    color: var(--pink);
}

.language-markdown .token.table-header {
    color: var(--bg);
}

.language-json .token.operator {
    color: var(--bg);
}

.language-scss .token.variable {
    color: var(--second-blue);
}

/* overrides color-values for the Show Invisibles plugin
 * https://prismjs.com/plugins/show-invisibles/
 */
.token.token.tab:not(:empty):before,
.token.token.cr:before,
.token.token.lf:before,
.token.token.space:before {
    color: var(--grey);
}

/* overrides color-values for the Toolbar plugin
 * https://prismjs.com/plugins/toolbar/
 */
div.code-toolbar {
    position: relative;
}

div.code-toolbar > .toolbar.toolbar {
    position: absolute;
    right: 10px;
    top: 10px;
    z-index: 10;
}

div.code-toolbar > .toolbar.toolbar > .toolbar-item > a,
div.code-toolbar > .toolbar.toolbar > .toolbar-item > button {
    color: var(--second-blue);
    background: var(--toolbar-button-bg);
    padding: 4px;
    border: 0;
    border-radius: 4px;
}

div.code-toolbar > .toolbar.toolbar > .toolbar-item > a:hover,
div.code-toolbar > .toolbar.toolbar > .toolbar-item > a:focus,
div.code-toolbar > .toolbar.toolbar > .toolbar-item > button:hover,
div.code-toolbar > .toolbar.toolbar > .toolbar-item > button:focus {
    color: var(--bg);
    background: var(--toolbar-button-hover-bg);
    text-decoration: none;
}

div.code-toolbar > .toolbar.toolbar > .toolbar-item > span,
div.code-toolbar > .toolbar.toolbar > .toolbar-item > span:hover,
div.code-toolbar > .toolbar.toolbar > .toolbar-item > span:focus {
    color: var(--bg);
    background: var(--toolbar-button-hover-bg);
}

div.code-toolbar > .toolbar.toolbar > .toolbar-item > button > span {
    font-family: monospace;
    font-weight: 500;
    font-size: 13px;
}

/* overrides color-values for the Line Highlight plugin
 * http://prismjs.com/plugins/line-highlight/
 */
.line-highlight.line-highlight {
    background: var(--highlight);
    background: linear-gradient(to right, #3c526d5f 70%, #3c526d55);
}

.line-highlight.line-highlight:before,
.line-highlight.line-highlight[data-end]:after {
    background-color: #8da1b9;
    color: #111b27;
    box-shadow: 0 1px #3c526d;
}

pre[id].linkable-line-numbers.linkable-line-numbers span.line-numbers-rows > span:hover:before {
    background-color: #8da1b918;
}

/* overrides color-values for the Line Numbers plugin
 * http://prismjs.com/plugins/line-numbers/
 */
.line-numbers.line-numbers .line-numbers-rows {
    border-right: 1px solid #0b121b;
    background: #0b121b7a;
}

.line-numbers .line-numbers-rows > span:before {
    color: #8da1b9da;
}

/* overrides color-values for the Match Braces plugin
 * https://prismjs.com/plugins/match-braces/
 */
.rainbow-braces .token.token.punctuation.brace-level-1,
.rainbow-braces .token.token.punctuation.brace-level-5,
.rainbow-braces .token.token.punctuation.brace-level-9 {
    color: #e6d37a;
}

.rainbow-braces .token.token.punctuation.brace-level-2,
.rainbow-braces .token.token.punctuation.brace-level-6,
.rainbow-braces .token.token.punctuation.brace-level-10 {
    color: #f4adf4;
}

.rainbow-braces .token.token.punctuation.brace-level-3,
.rainbow-braces .token.token.punctuation.brace-level-7,
.rainbow-braces .token.token.punctuation.brace-level-11 {
    color: #6cb8e6;
}

.rainbow-braces .token.token.punctuation.brace-level-4,
.rainbow-braces .token.token.punctuation.brace-level-8,
.rainbow-braces .token.token.punctuation.brace-level-12 {
    color: #c699e3;
}

/* overrides color-values for the Diff Highlight plugin
 * https://prismjs.com/plugins/diff-highlight/
 */
pre.diff-highlight > code .token.token.deleted:not(.prefix),
pre > code.diff-highlight .token.token.deleted:not(.prefix) {
    background-color: #cd66601f;
}

pre.diff-highlight > code .token.token.inserted:not(.prefix),
pre > code.diff-highlight .token.token.inserted:not(.prefix) {
    background-color: #91d0761f;
}

/* overrides color-values for the Command Line plugin
 * https://prismjs.com/plugins/command-line/
 */
.command-line .command-line-prompt {
    border-right: 1px solid #0b121b;
}

.command-line .command-line-prompt > span:before {
    color: #8da1b9da;
}