:root {
    --dark-main-color : #df733d;
    --light-main-color : #cc6633;
}


body {
    -ms-text-size-adjust: 100%;
    -webkit-text-size-adjust: 100%;
    line-height: 1.5;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
    font-size: 16px;
    line-height: 1.5;
    word-wrap: break-word;
    background-attachment: fixed;
    background-repeat: no-repeat;
    background-size: cover;
    -webkit-background-size: cover;
    -o-background-size: cover;
    background-position: center 0;
}

.octicon {
    display: inline-block;
    vertical-align: text-top;
    fill: currentColor;
}

a {
    background-color: transparent;
    -webkit-text-decoration-skip: objects;
}

#wrapper {
    justify-content: center;
    display: flex;
}

#write {
    padding: 15px 30px;
    width: 1000px;
}

.ImgCaption {
    padding-top: 0;
    margin-top: 7px;
    width: fit-content;
}

.vscode-dark .ImgCaption {
    /* border-bottom: 2px solid var(--dark-main-color); */
    color: white;
}

.vscode-light .ImgCaption {
    /* border-bottom: 2px solid var(--light-main-color); */
    color: black;
}

a:active,
a:hover {
    outline-width: 0;
}

strong {
    font-weight: inherit;
}

strong {
    font-weight: bolder;
}

h1 {
    font-size: 2em;
    margin: 0.67em 0;
}

.error-out {
    display: flex;
    justify-content: center;
    align-items: center;
}

.error {
    color: rgb(227, 60, 60);
    border-radius: 1em;
    border: 1.5px solid rgb(227, 60, 60);
    padding: 10px 20px;
}

code,
kbd,
pre {
    font-family: monospace, monospace;
}

hr {
    box-sizing: content-box;
    height: 0;
    overflow: visible;
}

input {
    font: inherit;
    margin: 0;
}

input {
    overflow: visible;
}

[type="checkbox"] {
    box-sizing: border-box;
    padding: 0;
}

* {
    box-sizing: border-box;
}

input {
    font-family: inherit;
    font-size: inherit;
    line-height: inherit;
}

a {
    text-decoration: none;
}

a:hover,
a:active {
    text-decoration: underline;
}

strong {
    font-weight: 600;
}

hr {
    height: 0;
    margin: 15px 0;
    overflow: hidden;
    background: transparent;
    border: 0;
    border-bottom: 1px solid;
}

hr::before {
    display: table;
    content: "";
}

hr::after {
    display: table;
    clear: both;
    content: "";
}

table {
    border-spacing: 0;
    border-collapse: collapse;
}

td,
th {
    padding: 0;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    margin-top: 0;
    margin-bottom: 0;
}

h1 {
    font-size: 32px;
    font-weight: 600;
}

h2 {
    font-size: 24px;
    font-weight: 600;
}

h3 {
    font-size: 20px;
    font-weight: 600;
}

h4 {
    font-size: 16px;
    font-weight: 600;
}

h5 {
    font-size: 14px;
    font-weight: 600;
}

h6 {
    font-size: 12px;
    font-weight: 600;
}

p {
    margin-top: 0;
    margin-bottom: 10px;
}

blockquote {
    margin: 0;
}

ul,
ol {
    padding-left: 0;
    margin-top: 0;
    margin-bottom: 0;
}

ol ol,
ul ol {
    list-style-type: lower-roman;
}

ul ul ol,
ul ol ol,
ol ul ol,
ol ol ol {
    list-style-type: lower-alpha;
}

dd {
    margin-left: 0;
}

code {
    font-family: Consolas, "Liberation Mono", Menlo, Courier, monospace;
}

pre {
    margin-top: 0;
    margin-bottom: 0;
    font: 12px Consolas, "Liberation Mono", Menlo, Courier, monospace;
}

.octicon {
    vertical-align: text-bottom;
}

input {
    -webkit-font-feature-settings: "liga" 0;
    font-feature-settings: "liga" 0;
}

.markdown-body::before {
    display: table;
    content: "";
}

.markdown-body::after {
    display: table;
    clear: both;
    content: "";
}

.markdown-body>*:first-child {
    margin-top: 0 !important;
}

.markdown-body>*:last-child {
    margin-bottom: 0 !important;
}

a:not([href]) {
    color: inherit;
    text-decoration: none;
}

.anchor {
    float: left;
    padding-right: 4px;
    margin-left: -20px;
    line-height: 1;
}

.anchor:focus {
    outline: none;
}

p,
blockquote,
ul,
ol,
dl,
table,
pre {
    margin-top: 0;
    margin-bottom: 16px;
}

hr {
    height: 0.25em;
    padding: 0;
    margin: 24px 0;
    border: 0;
}

blockquote {
    padding: 0 1em;
}

blockquote>:first-child {
    margin-top: 0;
}

blockquote>:last-child {
    margin-bottom: 0;
}

kbd {
    display: inline-block;
    padding: 3px 5px;
    font-size: 11px;
    line-height: 10px;
    vertical-align: middle;
    border-radius: 3px;
}

#write h1,
#write h2,
#write h3,
#write h4,
#write h5,
#write h6 {
    margin-top: 24px;
    margin-bottom: 16px;
    font-weight: 600;
    line-height: 1.25;
}

.vscode-dark h1 {
    color: #eee;
    /* border-bottom: 3px solid #df733d; */
    width: fit-content;
    margin: 0 0 1.0em 0;
    line-height: 1.3;
}

.vscode-dark h2 {
    color: #eee;
}

/* .vscode-dark h2::before {
    content: 'H2';
    border-radius: .3em;
    font-size: .8em;
    padding: 3px 7px;
    margin-right: 15px;
    color: #eee;
    background-color: #df733d;
} */

.vscode-light h1 {
    color: #000;
    /* border-bottom: 3px solid #cc6633; */
    width: fit-content;
    margin: 0 0 1.0em 0;
    line-height: 1.3; 
}

.vscode-light h2 {
    color: #000;
}

/* .vscode-light h2::before {
    content: 'H2';
    border-radius: .3em;
    font-size: .8em;
    padding: 3px 7px;
    margin-right: 15px;
    color: #eee;
    background-color: #cc6633;
} */

h1 {
    padding-bottom: 0.3em;
    font-size: 2em;
}

h2 {
    padding-bottom: 0.3em;
    font-size: 1.5em;
}

h3 {
    font-size: 1.25em;
}

h4 {
    font-size: 1em;
}

h5 {
    font-size: 0.875em;
}

h6 {
    font-size: 0.85em;
}

ul,
ol {
    padding-left: 2em;
}

ul ul,
ul ol,
ol ol,
ol ul {
    margin-top: 0;
    margin-bottom: 0;
}

li>p {
    margin-top: 16px;
}

li+li {
    margin-top: 0.25em;
}

/* 
table {
    display: block;
    width: 100%;
    overflow: auto;
}

table th {
    font-weight: bold;
}

table th,
table td {
    padding: 6px 13px;
    border: .7px solid;
}

table tr {
    border-top: .7px solid;
} */


img {
    max-width: 100%;
    box-sizing: content-box;
}

#write table {
    width: 95%;
    border-collapse: collapse;
    text-align: center;
    margin: 20px;
    max-width: 750px;
}

#write table td, table th {
    border: 1px solid;
    padding: 12px 10px;
    /* border-radius: .5em; */
    word-wrap: break-word;
}

#write table thead th {
    /* background-color: var(--dark-main-color); */
    font-size: 20px;
    font-weight: bolder;
    width: 100px;
    text-align: center;
    vertical-align: middle;
    padding: 10px;
}

.vscode-dark table {
    color: #F0F0F0;
}

.vscode-light table {
    color: #1F2329;
}


.vscode-dark #write table thead th {
    background-color: rgb(76, 55, 114);
}

.vscode-light #write table thead th {
    background-color: rgb(236, 226, 254);
}

.vscode-dark table tr:nth-child(even) {
    background: #232323;
}

.vscode-light table tr:nth-child(even) {
    background: #F6F7F8;
}


/* TODO: Diagram CSS */
.diagram-container {
    width: 100%;
    display: flex;
    justify-content: center;
}

.diagram-container .diagram-ports-wrapper {
    display: flex;
}

.diagram-container .diagram-params {
    display: flex;
    justify-content: space-between;
    border-radius: 0.7em;
    padding: 15px;
    margin: 10px 60px;
    width: 350px;
    text-align: right;
}

.diagram-container .diagram-ports {
    border-radius: 0.7em;
    padding: 20px 0px;
    margin: 10px 0px 10px 0px;
    width: 350px;
}

.vscode-dark .diagram-params {
    background-color: rgba(53,59,140);
    border: solid 4.5px rgb(83,88,157);
}

.vscode-light .diagram-params {
    background-color: rgba(180,185,243);
    border: solid 4.5px rgb(153,157,207);
}

.vscode-dark .diagram-ports {
    background-color: rgba(35,102,93);
    border: solid 4.5px rgb(68,125,117);
}

.vscode-light .diagram-ports {
    background-color: rgb(169,239,230);
    border: solid 4.5px rgb(144,203,196);
}


.diagram-container .digrame-port-item {
    display: flex;
    justify-content: space-between;
    height: 40px;
}

.diagram-container .i-port-name {
    font-size: 18px;
    padding: 3px 8px;
}

.diagram-container .o-port-name {
    font-size: 18px;
    padding: 3px 8px;
}

.diagram-container .io-port-name {
    font-size: 18px;
    padding: 3px 8px;

}

.diagram-container .left-direction {
    padding-right: 0;
    padding: 20px 0px;
    margin: 10px 0 0 10px;
    width: 105px;
}

.diagram-container .right-direction {
    padding-left: 0;
    padding: 20px 0px;
    margin: 10px 0 10px 0px;
    width: 105px;
}

.diagram-container .arrow-wrapper {
    height: 40px;
}

.diagram-container .port-width-left-caption {
    position: absolute;
    margin: -5px 10px;
    font-size: 14px;
}

.diagram-container .port-width-right-caption {
    position: absolute;
    margin: -5px 10px;
    font-size: 14px;
}

.vscode-dark .diagram-container {
    color: white;
}

.vscode-light .diagram-container {
    color: black;
}