/*
Based on term.css of eshlox (MIT License)
https://github.com/eshlox/termcss
Huge shoutout <3
*/


@font-face {
  font-family: JetBrains Mono;
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("./fonts/JetBrainsMono-Regular.woff2") format("woff2");
}

@font-face {
  font-family: JetBrains Mono;
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("./fonts/JetBrainsMono-Italic.woff2") format("woff2");
}

@font-face {
  font-family: JetBrains Mono;
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("./fonts/JetBrainsMono-Bold.woff2") format("woff2");
}

*, :before, :after {
  box-sizing: border-box;
  line-height: inherit;
}

body, h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd, pre {
  margin: 0;
}

h1, h2, h3, h4, h5, h6, small, code, kbd, samp {
  font-size: inherit;
}

ul, ol {
  margin: 0;
  padding: 0;
  list-style-position: inside;
}

img, picture, video, canvas, svg, iframe {
  max-width: 100%;
  display: block;
}

input, button, textarea, select {
  font: inherit;
}

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

fieldset {
  border: 0;
  margin: 0;
  padding: 0;
}

:root {
  color-scheme: light dark;
  --t-bg: light-dark(oklch(100% 0 0), oklch(24% 0 0));
  --t-fg: light-dark(oklch(15% 0 0), oklch(93% 0 0));
  --t-muted: light-dark(oklch(55% .01 286), oklch(63% .01 286));
  --t-accent: light-dark(oklch(50% .17 255), oklch(63% .21 255));
  --t-accent2: light-dark(oklch(52% .19 312), oklch(66% .23 312));
  --t-surface: light-dark(oklch(96% 0 0), oklch(29% 0 0));
  --t-border: light-dark(oklch(85% .01 286), oklch(38% 0 0));
  --t-red: light-dark(oklch(55% .2 25), oklch(65% .2 25));
  --t-yellow: light-dark(oklch(55% .16 85), oklch(78% .16 85));
  --t-green: light-dark(oklch(50% .17 145), oklch(72% .19 145));
  --t-syntax-keyword: light-dark(oklch(52% .19 312), oklch(66% .23 312));
  --t-syntax-string: light-dark(oklch(50% .16 145), oklch(77% .22 145));
  --t-syntax-comment: light-dark(oklch(55% .01 286), oklch(50% .01 286));
  --t-syntax-function: light-dark(oklch(50% .14 95), oklch(80% .16 95));
  --t-syntax-number: light-dark(oklch(50% .19 28), oklch(66% .22 28));
  --t-syntax-operator: light-dark(oklch(50% .1 228), oklch(75% .1 228));
  --t-syntax-type: light-dark(oklch(50% .17 255), oklch(62% .21 255));
  --t-syntax-punctuation: var(--t-muted);
}

:root[data-theme="light"] {
  color-scheme: light;
}

:root[data-theme="dark"] {
  color-scheme: dark;
}

pre > code .line {
  display: inline;
}

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

.token.keyword, .token.tag, .token.boolean, .token.constant, .hljs-keyword, .hljs-selector-tag {
  color: var(--t-syntax-keyword);
}

.token.string, .token.char, .token.attr-value, .token.regex, .token.template-string, .hljs-string, .hljs-attr {
  color: var(--t-syntax-string);
}

.token.function, .token.class-name, .hljs-title, .hljs-section {
  color: var(--t-syntax-function);
}

.token.number, .hljs-number {
  color: var(--t-syntax-number);
}

.token.operator, .token.entity, .token.url, .hljs-operator {
  color: var(--t-syntax-operator);
}

.token.property, .token.attr-name, .token.namespace, .hljs-type, .hljs-built_in {
  color: var(--t-syntax-type);
}

.token.punctuation, .hljs-punctuation {
  color: var(--t-syntax-punctuation);
}

html {
  background-color: var(--t-bg);
  color: var(--t-fg);
  -moz-text-size-adjust: 100%;
  text-size-adjust: 100%;
  font-variant-numeric: tabular-nums;
  font-family: JetBrains Mono, ui-monospace, Cascadia Code, Source Code Pro, Menlo, Consolas, DejaVu Sans Mono, monospace;
  font-size: .875rem;
  line-height: 1.5;
}

body {
  flex-direction: column;
  min-height: 100dvh;
  padding-block: 0;
  padding-inline: 1em;
  display: flex;
}

header {
  margin-block-end: 0;
}

main, section, article {
  margin-block: 1lh;
}

main {
  flex-grow: 1;
  margin-block-start: 0;
}

footer {
  background-color: var(--t-surface);
  align-items: center;
  margin-block-start: auto;
  margin-inline: -1em;
  padding-block: .5lh;
  padding-inline: 1em;
  display: flex;
}

footer > :last-child:not(:first-child) {
  margin-inline-start: auto;
}

footer a {
  color: inherit;
  text-decoration: none;
}

footer > * + :before {
  content: "|";
  color: var(--t-muted);
  margin-inline: .75em;
}

nav {
  background-color: var(--t-surface);
  align-items: center;
  margin-block: 0;
  margin-inline: -1em;
  padding-block: .5lh;
  padding-inline: 1em;
  display: flex;
}

nav > :last-child:not(:first-child) {
  margin-inline-start: auto;
}

nav a {
  color: inherit;
  text-decoration: none;
}

nav > a:before, nav > ul:first-child > li:first-child a:before {
  content: "[";
}

nav > a:after, nav > ul:first-child > li:first-child a:after {
  content: "]";
}

nav > button[aria-expanded] {
  display: none;
}

nav ul {
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
}

nav > ul:not(:first-child) > li:first-child:before, nav li + li:before {
  content: "|";
  color: var(--t-muted);
  margin-inline: .75em;
}

nav a[aria-current="page"] {
  background-color: var(--t-accent);
  color: var(--t-bg);
  padding-inline: .25em;
}

h1 {
  margin-block: 1lh;
  font-weight: 700;
}

h2, h3, h4, h5, h6 {
  margin-block: 2lh 1lh;
  font-weight: 700;
}

p {
  margin-block: 1lh;
}

a {
  color: var(--t-accent);
  text-underline-offset: .15em;
}

a:hover {
  text-decoration: none;
}

strong {
  font-weight: 700;
}

small {
  color: var(--t-muted);
}

mark {
  background-color: var(--t-accent2);
  color: var(--t-bg);
  padding-inline: .25em;
}

h2 > a, h3 > a, h4 > a, h5 > a, h6 > a {
  color: inherit;
  text-decoration: none;
}

code {
  color: var(--t-accent2);
}

pre {
  background-color: var(--t-surface);
  margin-block: 1lh;
  padding: .25em .5em;
  overflow-x: auto;
}

.expressive-code {
  margin-block: 1lh;
}

pre > code {
  color: inherit;
}

blockquote {
  border-inline-start: 3px solid var(--t-accent);
  color: var(--t-muted);
  margin-block: 1lh;
  margin-inline: 0;
  padding-inline-start: 1em;
  font-style: italic;
}

blockquote > p {
  margin-block: 0;
}

ul, ol {
  margin-block: 1lh;
  padding-inline-start: 2em;
  list-style-position: outside;
}

li, li > ul, li > ol {
  margin-block: 0;
}

table {
  width: 100%;
  margin-block: 1lh;
  display: block;
  overflow-x: auto;
}

thead {
  border-bottom: 2px solid var(--t-border);
}

th {
  text-align: left;
  padding: .25em 1em;
  font-weight: 700;
}

td {
  border-bottom: 1px solid var(--t-border);
  padding: .25em 1em;
}

img {
  height: auto;
}

iframe {
  aspect-ratio: 16 / 9;
  border: 0;
  width: 100%;
}

figure {
  margin-block: 1lh;
  margin-inline: 0;
}

figcaption {
  color: var(--t-muted);
}

hr {
  border: 0;
  border-top: 1px solid var(--t-border);
  margin-block: 1lh;
}

time {
  color: var(--t-muted);
}

details {
  border-inline-start: 1px solid var(--t-border);
  margin-block: 1lh;
  padding-inline-start: 1em;
}

summary {
  cursor: pointer;
  font-weight: 700;
  list-style: none;
}

summary:before {
  content: "▸ ";
}

details[open] > summary:before {
  content: "▾ ";
}

summary::-webkit-details-marker {
  display: none;
}

details > :not(summary) {
  margin-block-start: .5lh;
}

label {
  font-weight: 700;
  display: block;
}

button, input, textarea, select {
  color: var(--t-fg);
  border: 1px solid var(--t-border);
  font-family: inherit;
  font-size: inherit;
  background: none;
  padding: .25em .5em;
}

input:not([type="checkbox"]):not([type="radio"]), textarea, select {
  box-sizing: border-box;
  width: 100%;
}

button {
  background-color: var(--t-accent);
  color: var(--t-bg);
  cursor: pointer;
  border: 0;
  width: auto;
  font-weight: 700;
}

textarea {
  resize: vertical;
  min-height: 4.5em;
}

ul:has( > li > input[type="checkbox"]) {
  padding-inline-start: 0;
}

li:has( > input[type="checkbox"]) {
  list-style: none;
}

li > input[type="checkbox"] {
  appearance: none;
  border: 1px solid var(--t-border);
  vertical-align: middle;
  cursor: pointer;
  background: none;
  place-content: center;
  width: 1em;
  height: 1em;
  margin-inline-end: .5em;
  display: inline-grid;
}

li > input[type="checkbox"]:checked {
  border-color: var(--t-accent);
  background-color: var(--t-accent);
}

li > input[type="checkbox"]:checked:after {
  content: "x";
  color: var(--t-bg);
  font-size: .75em;
  font-weight: 700;
  line-height: 1;
}

kbd {
  border: 1px solid var(--t-border);
  padding-inline: .25em;
  font-family: inherit;
}

samp {
  color: var(--t-muted);
}

abbr[title] {
  -webkit-text-decoration: underline dotted var(--t-muted);
  text-decoration: underline dotted var(--t-muted);
  cursor: help;
}

ol[type="I"], ol[type="i"] {
  list-style-type: upper-roman;
}

ol[type="A"] {
  list-style-type: upper-alpha;
}

ol[type="a"] {
  list-style-type: lower-alpha;
}

ol ::marker {
  color: var(--t-muted);
}

ul ::marker {
  color: var(--t-muted);
}

dl {
  margin-block: 1lh;
}

dt {
  margin-block-start: .5lh;
  font-weight: 700;
}

dt:first-child {
  margin-block-start: 0;
}

dd {
  margin-block: 0;
  margin-inline-start: 2em;
}

::selection {
  background-color: var(--t-accent);
  color: var(--t-bg);
}

@media (width <= 768px) {
  body {
    padding-inline: .75em;
  }

  nav, footer {
    margin-inline: -.75em;
    padding-inline: .75em;
  }

  nav {
    flex-wrap: wrap;
  }

  nav > button[aria-expanded] {
    text-align: end;
    cursor: pointer;
    color: inherit;
    font-weight: 700;
    font: inherit;
    background: none;
    border: none;
    flex-grow: 1;
    padding: 0;
    display: block;
  }

  nav > button[aria-expanded]:before {
    content: "▸ ";
  }

  nav > button[aria-expanded="true"]:before {
    content: "▾ ";
  }

  nav > button[aria-expanded="false"] + ul {
    display: none;
  }

  nav > button[aria-expanded="true"] + ul {
    flex-direction: column;
    flex-basis: 100%;
    align-items: flex-end;
    gap: .25lh;
    padding-block-start: .5lh;
    display: flex;
  }

  nav > button[aria-expanded] + ul > li:first-child:before, nav > button[aria-expanded] + ul > li + li:before {
    content: none;
  }
}

.t-card {
  background-color: var(--t-surface);
  border: 1px solid var(--t-card-border, var(--t-border));
  margin-block: 1lh;
  padding: .75em 1em;
}

.t-card > :first-child {
  margin-block-start: 0;
}

.t-card > :last-child {
  margin-block-end: 0;
}

.t-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 25ch), 1fr));
  gap: 1lh;
  margin-block: 1lh;
  display: grid;
}

.t-grid > .t-card {
  margin-block: 0;
}

.t-badge {
  background-color: var(--t-accent2);
  color: var(--t-bg);
  padding-inline: .5em;
  font-weight: 700;
}

.t-callout {
  background-color: var(--t-surface);
  border-inline-start: 3px solid var(--t-accent);
  margin-block: 1lh;
  padding: .75em 1em;
}

.t-callout > :first-child {
  margin-block-start: 0;
}

.t-callout > :last-child {
  margin-block-end: 0;
}

.t-callout > strong:first-child {
  color: var(--t-accent);
  display: block;
}

.t-table-bordered th, .t-table-bordered td {
  border: 1px solid var(--t-accent2);
}

.t-error {
  color: var(--t-red);
}

.t-warn {
  color: var(--t-yellow);
}

.t-success {
  color: var(--t-green);
}

.t-info {
  color: var(--t-accent);
}

.t-callout.t-error {
  border-color: var(--t-red);
  color: var(--t-fg);
}

.t-callout.t-error > strong:first-child {
  color: var(--t-red);
}

.t-callout.t-warn {
  border-color: var(--t-yellow);
  color: var(--t-fg);
}

.t-callout.t-warn > strong:first-child {
  color: var(--t-yellow);
}

.t-callout.t-success {
  border-color: var(--t-green);
  color: var(--t-fg);
}

.t-callout.t-success > strong:first-child {
  color: var(--t-green);
}

.t-callout.t-info {
  border-color: var(--t-accent);
  color: var(--t-fg);
}

.t-badge.t-error {
  background-color: var(--t-red);
  color: var(--t-bg);
}

.t-badge.t-warn {
  background-color: var(--t-yellow);
  color: var(--t-bg);
}

.t-badge.t-success {
  background-color: var(--t-green);
  color: var(--t-bg);
}

.t-badge.t-info {
  background-color: var(--t-accent);
  color: var(--t-bg);
}

:focus-visible {
  outline: 2px solid var(--t-accent);
  outline-offset: 2px;
}

:focus:not(:focus-visible) {
  outline: none;
}

.skip-link {
  background-color: var(--t-accent);
  color: var(--t-bg);
  z-index: 9999;
  padding: .5em 1em;
  font-weight: 700;
  text-decoration: none;
  position: absolute;
  top: -100%;
  left: 1rem;
}

.skip-link:focus {
  top: 1rem;
}

@media (prefers-reduced-motion: reduce) {
  *, :before, :after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
  }

  html {
    scroll-behavior: auto;
  }
}

@media (prefers-contrast: more) {
  :root {
    --t-muted: var(--t-fg);
    --t-surface: var(--t-bg);
    --t-border: var(--t-fg);
  }
}

h1, h2, h3, h4, h5, h6 {
  scroll-margin-top: 2rem;
}

* {
  scrollbar-width: thin;
  scrollbar-color: var(--t-border) transparent;
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: none;
}

::-webkit-scrollbar-thumb {
  background-color: var(--t-border);
}

::-webkit-scrollbar-thumb:hover {
  background-color: var(--t-muted);
}

@media print {
  :root {
    --t-bg: #fff;
    --t-fg: #000;
    --t-muted: #444;
    --t-accent: #000;
    --t-accent2: #666;
    --t-surface: #f5f5f5;
    --t-border: #ccc;
  }

  body {
    max-width: 100%;
    padding: 0;
  }

  h1 {
    color: var(--t-fg);
  }

  a {
    color: var(--t-fg);
    text-decoration: underline;
  }

  a[href^="http"]:after {
    content: " (" attr(href) ")";
    color: var(--t-muted);
  }

  a[href^="#"]:after {
    content: "";
  }

  pre {
    white-space: pre-wrap;
    border: 1px solid var(--t-border);
  }

  nav, .skip-link {
    display: none;
  }

  img {
    max-width: 100% !important;
  }
}

/*My Own Stuff*/
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-header h3 {
    margin: 0;
}

.button {
    display: inline-block;
    background-color: var(--t-accent);
    color: var(--t-bg);
    border: 0;
    padding: .25em .5em;
    font-family: inherit;
    font-size: inherit;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.button:hover {
    text-decoration: none;
}