html, body {
  max-width: 100%;
  overflow-x: hidden;
}

body {
  background-color: white;
  background: var(--body-background-base-color) var(--body-background-pattern-image) top center repeat-x;
  font-size: var(--body-font-size);
  font-family: var(--body-font-family);
  color: var(--body-font-color);
}

body, div, dl, dt, dd, ul, ol, li, h1, h2, h3, h4, h5, h6, pre, code, form, fieldset, legend, input, textarea, p, th, td, iframe, blockquote {
  margin: 0;
  padding: 0;
}

hr {
  border: var(--hr-border, revert);
  border-top: var(--hr-border-top, revert);
  height: var(--hr-height, revert);
}

.greentext {
  color: var(--post-greentext-color);
}

.spoilertext {
  color: #000 !important;
  background: #000 !important;
  text-decoration: none;
}

.spoilertext:hover {
  color: #fff !important;
}

.capitalize {
  text-transform: capitalize;
}

.uppercase {
  text-transform: uppercase;
}

.red {
  color: red !important;
}

:root {
  color-scheme: dark;
}

[data-floating-ui-portal] {
  color-scheme: var(--color-scheme) !important;
}

.yellowOfflineIcon {
  background-image: url('/assets/icons/offline-blue.png');
}

.redOfflineIcon {
  background-image: url('/assets/icons/offline-red.png');
}

@media (max-width: 640px) {
  .button {
    font-size: var(--button-font-size-mobile);
    font-weight: var(--button-font-weight-mobile);
    font-family: var(--button-font-family-mobile);
    border-radius: 3px;
    padding: 5px 10px 5px;
    background-color: var(--button-background-color-mobile);
    color: var(--button-text-color-mobile);
    border: var(--button-border-mobile);
    background-image: var(--button-background-image-mobile);
    background-repeat: var(--button-background-repeat-mobile);
    text-decoration: var(--button-text-decoration-mobile);
    user-select: none;
    display: inline-block;
    cursor: pointer;
  }

  .highlight,
  .scroll-highlight {
    background: var(--reply-highlight-background-color) !important;
  }

  .double-highlight {
    background: var(--reply-double-highlight-background-color) !important;
  }
}

@media (min-width: 640px) {
  .button {
    all: unset;
    text-transform: capitalize;
    color: var(--button-desktop-text-color);
    text-decoration: var(--button-text-decoration);
  }

  .button:hover {
    color: var(--button-desktop-text-color-hover);
    cursor: pointer;
  }

  .highlight,
  .scroll-highlight {
    background: var(--reply-highlight-background-color) !important;
    border: var(--reply-highlight-border) !important;
    border-left: var(--reply-highlight-border-left, revert) !important;
    border-top: var(--reply-highlight-border-top, revert) !important;
  }

  .double-highlight {
    background: var(--reply-double-highlight-background-color) !important;
    border: var(--reply-double-highlight-border) !important;
    border-left: var(--reply-double-highlight-border-left, revert) !important;
    border-top: var(--reply-double-highlight-border-top, revert) !important;
  }
}
