:root,
::backdrop {
  /* Set sans-serif & mono fonts */
  --sans-font: -apple-system, BlinkMacSystemFont, "Avenir Next", Avenir,
    "Nimbus Sans L", Roboto, "Noto Sans", "Segoe UI", Arial, Helvetica,
    "Helvetica Neue", sans-serif;
  --mono-font: Consolas, Menlo, Monaco, "Andale Mono", "Ubuntu Mono", monospace;
  --standard-border-radius: 5px;

  /* Default (light) theme */
  --bg: #fff;
  --accent-bg: #f5f7ff;
  --text: #212121;
  --text-light: #585858;
  --border: #898EA4;
  --accent: #0d47a1;
  --accent-hover: #1266e2;
  --accent-text: var(--bg);
  --code: #d81b60;
  --preformatted: #444;
  --marked: #ffdd33;
  --disabled: #efefef;
}

/* Dark theme */
@media (prefers-color-scheme: dark) {
  :root,
  ::backdrop {
    color-scheme: dark;
    --bg: #212121;
    --accent-bg: #2b2b2b;
    --text: #dcdcdc;
    --text-light: #ababab;
    --accent: #ffb300;
    --accent-hover: #ffe099;
    --accent-text: var(--bg);
    --code: #f06292;
    --preformatted: #ccc;
    --disabled: #111;
  }
}

html {
    /* Set the font globally */
    font-family: var(--sans-font);
    scroll-behavior: smooth;
}

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

code {
    display: inline;
    font-family: var(--mono-font);
    background-color: var(--accent-bg);
    border-color: var(--border);
    border-radius: 0.25rem;
    overflow: auto;
    overflow-x: auto;

}
/* Catch case where we are using 'code' blocks in a paragraph */
pre > code {
  display: block;
}

pre {
  padding: 1rem 1.4rem;
}

footer {
    text-align: center;
    margin-top: 4rem;
    padding: 2rem 1rem 1.5rem 1rem;
    color: var(--text-light);
    font-size: 0.9rem;
}

body {
    background-color: var(--bg);
    max-width: 900px;
    margin-right: auto;
    margin-left: auto;
    display: flex;
    font-size: 1.15rem;
    line-height: 1.5;

    min-height: 100vh;
    flex-direction: column;
    flex: 1;
    margin: 0 auto;
    max-width: 45rem;
    padding: 0 0.5rem;
    overflow-x: hidden;
    word-break: break-word;
    overflow-wrap: break-word;
}

h1 {
    font-size: 3rem;
}
h2 {
    font-size: 2.6rem;
}
h3 {
    font-size: 2rem;
}
h4 {
    font-size: 1.44rem;
}
h5 {
    font-size: 1.15rem;
}
h6 {
    font-size: 0.96rem;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    margin: 10px 0;
}

#home {
    color: var(--text);
}

.article {
  margin-top: 2rem;
  margin-bottom: 2rem;
}

.article > h5 {
  margin: 0;
}

.light {
  color: var(--text-light);
}

a,
a:visited {
  color: var(--accent);
}

a:hover {
  text-decoration: none;
}

@media only screen and (max-width: 900px) {
  body {
    padding-right: 1rem;
    padding-left: 1rem;
  }
}