/* ============================================================
   fonts
   ============================================================ */

@font-face {
  font-family: 'Press Start 2P';
  src: url('../fonts/press-start-2p.woff2') format('woff2');
  font-weight: normal;
  font-style: normal;
}

@font-face {
  font-family: 'PxPlus IBM VGA8';
  src: url('../fonts/PxPlusIBM-VGA8.woff') format('woff');
  font-weight: normal;
  font-style: normal;
}

/* ============================================================
   light mode
   ============================================================ */

body {
  background: #003b7a;
  color: #fff;
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  margin: 0;
  padding: 0;
}

.titlebar {
  background: #003b7a;
  color: #fff;
  font-weight: bold;
  text-align: center;
  padding: 6px;
  border-bottom: 2px solid #fff;
}

.menubar {
  background: #003b7a;
  border-bottom: 2px solid #fff;
  padding: 4px 0;
  text-align: center;
}

.menubar a {
  color: #fff !important;
  text-decoration: none !important;
  margin: 0 20px;
  font-weight: bold;
}

.menubar a:hover {
  text-decoration: underline !important;
}

.menubar a.active {
  color: #ffff00 !important;
  text-decoration: underline !important;
}

.screen {
  display: grid;
  grid-template-columns: 40% 60%;
  background: #c0c0c0;
  border: 2px solid #fff;
  border-bottom: none;
  box-shadow: none;
  color: #000;
  align-items: stretch;
  overflow: hidden;
  min-height: 90vh;
  height: auto;
  position: relative;
}

.screen::before {
  content: "";
  position: absolute;
  left: 40%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #fff;
  z-index: 2;
}

.left-pane {
  padding: 10px;
  background: #c0c0c0;
  height: 100%;
  box-sizing: border-box;
  border-right: none;
}

.left-pane h2,
.left-pane ul {
  background: transparent !important;
  border: none !important;
}

.right-pane {
  padding: 10px;
  background: #c0c0c0;
  box-sizing: border-box;
}

.screen h1,
.screen h2,
.screen h3 {
  color: #fff;
}

.statusbar {
  background: #003b7a;
  color: #fff;
  font-size: 12px;
  text-align: center;
  padding: 4px;
  border-top: 1px solid #fff !important;
}

.screen a:link {
  color: #ffff00;
  text-decoration: none;
}

.screen a:visited {
  color: #ffff00;
}

.screen a:hover,
.screen a:focus {
  color: #ffff00;
  text-decoration: underline;
  background: none;
}

.screen a:active {
  color: #ffff00;
}

.post-link {
  color: #000000;
}

.post-link:hover {
  color: #ffff00;
  text-decoration: none;
  padding: 2px 4px;
  background: none;
}

a:link {
  color: #ffff00;
  text-decoration: none;
}

a:visited {
  color: #ffffff;
}

a:hover,
a:focus {
  color: #ffff00;
  text-decoration: underline;
  background: none;
}

a:active {
  color: #ffff00;
}

.screen ul,
.screen li {
  list-style: none !important;
}

.screen li::marker {
  content: "" !important;
}

.screen ul li::before {
  content: ">" !important;
  color: #ffff00;
  margin-right: 6px;
}

ul, li {
  list-style: none;
}

li::marker {
  content: "";
}

ul li::before {
  content: ">";
  color: #ffff00;
  margin-right: 6px;
}

.post-content ul,
.post-content li {
  list-style: none !important;
}

.post-content li::marker {
  content: "" !important;
}

.post-content ul li::before {
  content: ">" !important;
  color: #ffff00;
  margin-right: 6px;
}

.separator {
  height: 1px;
  background: #ffffff;
  width: 100%;
}

/* bios style input box */

input#search {
  all: unset !important;
  display: inline-block !important;
  background: #c0c0c0 !important;
  color: #ffff00 !important;
  font-family: 'Press Start 2P', monospace !important;
  font-size: 10px !important;
  border: 2px solid #9e9e9e !important;
  padding: 4px 6px !important;
  width: 200px !important;
  box-sizing: border-box !important;
}

input#search:focus {
  border-color: #ffff00 !important;
  background: #b0b0b0 !important;
}

label[for="search"] {
  color: #ffff00 !important;
  font-family: 'Press Start 2P', monospace !important;
  font-size: 10px !important;
  margin-right: 6px !important;
}

#results,
#results li,
#results li a {
  color: #ffff00 !important;
  font-family: 'Press Start 2P', monospace !important;
  text-decoration: none !important;
}

.post-content img {
  max-width: 100%;
  height: auto;
  display: block;
  margin-left: 5px;
  border: none;
  padding: 1px;
  background: transparent;
}

.highlighter-rouge,
.highlight,
.language-bash,
.language-rust,
.language-c,
.language-cpp,
.language-lua {
  background: transparent !important;
  border: none !important;
  padding: 0 !important;
}

.highlighter-rouge pre,
.highlight pre,
pre {
  color: #ffff00  !important;
  font-family: 'PxPlus IBM VGA8' !important;
  padding: 8px !important;
  margin: 0 0 1rem 0 !important;
  letter-spacing: 1px;
  font-size: 14px;
}

code {
  color: #ffff00  !important;
  padding: 2px 4px !important;
  font-family: 'PxPlus IBM VGA8' !important;
  letter-spacing: 1px;
  font-size: 14px;
}

.bios-dropdown {
    background: #000;
    color: #fff;
    border: 1px solid #ffff00;
    padding: 10px;
    font-family: 'PxPlus IBM VGA8', monospace;
    margin-top: 10px;
}

.bios-toggle {
    cursor: pointer;
    color: #ffff00;
}

.bios-dropdown a {
    color: #ffff00;
    text-decoration: none;
}

.bios-dropdown a:hover {
    text-decoration: underline;
}

/* status bar fix for mobile */

.statusbar {
    display: block;
    white-space: nowrap;      
    overflow-x: auto;          
    box-sizing: border-box;
    text-align: center;        
    padding: 1 0.5ch;           
    line-height: 1.2;           
}

/* blinking cursor */

.cursor {
  display: inline-block;
  width: 2px;
  height: 1em;
  background: #000 !important;
  position: relative;
  z-index: 9999;
  animation: blink 0.7s steps(1) infinite;
}

@keyframes blink {
  50% { opacity: 0; }
}

/* ============================================================
   dark mode
   ============================================================ */

.theme-dark body {
  background: #000;
  color: #c0c0c0;
  font-family: 'Press Start 2P', monospace;
  font-size: 10px;
  margin: 0;
  padding: 0;
}

.theme-dark .titlebar {
  background: #000;
  color: #c0c0c0;
  font-weight: bold;
  text-align: center;
  padding: 6px;
  border-bottom: 2px solid #808080;
}

.theme-dark .menubar {
  background: #000;
  border-bottom: 2px solid #808080;
  padding: 4px 0;
  text-align: center;
}

.theme-dark .menubar a {
  color: #c0c0c0 !important;
  text-decoration: none !important;
  margin: 0 20px;
  font-weight: bold;
}

.theme-dark .menubar a:hover {
  text-decoration: underline !important;
}

.theme-dark .menubar a.active {
  color: #ffff00 !important;
  text-decoration: underline !important;
}

.theme-dark .screen {
  display: grid;
  grid-template-columns: 40% 60%;
  background: #000;
  border: 2px solid #808080;
  border-bottom: none;
  box-shadow: none;
  color: #c0c0c0;
  align-items: stretch;
  overflow: hidden;
  min-height: 90vh;
  height: auto;
  position: relative;
}

.theme-dark .screen::before {
  content: "";
  position: absolute;
  left: 40%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #808080;
  z-index: 2;
}

.theme-dark .left-pane {
  padding: 10px;
  background: #000;
  height: 100%;
  box-sizing: border-box;
  border-right: none;
}

.theme-dark .left-pane h2,
.theme-dark .left-pane ul {
  background: transparent !important;
  border: none !important;
}

.theme-dark .right-pane {
  padding: 10px;
  background: #000;
  box-sizing: border-box;
}

.theme-dark .screen h1,
.theme-dark .screen h2,
.theme-dark .screen h3 {
  color: #e0e0e0;
}

.theme-dark .statusbar {
  background: #000;
  color: #c0c0c0;
  font-size: 12px;
  text-align: center;
  padding: 4px;
  border-top: 1px solid #808080 !important;
}

.theme-dark .screen a:link,
.theme-dark .screen a:visited,
.theme-dark .screen a:hover,
.theme-dark .screen a:focus,
.theme-dark .screen a:active {
  color: #ffff00;
  text-decoration: none;
}

.theme-dark .screen a:hover {
  text-decoration: underline;
}

.theme-dark .post-link {
  color: #c0c0c0;
}

.theme-dark .post-link:hover {
  color: #ffff00;
  text-decoration: none;
  padding: 2px 4px;
  background: none;
}

.theme-dark .screen ul,
.theme-dark .screen li,
.theme-dark ul,
.theme-dark li,
.theme-dark .post-content ul,
.theme-dark .post-content li {
  list-style: none !important;
}

.theme-dark li::marker,
.theme-dark .post-content li::marker {
  content: "" !important;
}

.theme-dark .screen ul li::before,
.theme-dark ul li::before,
.theme-dark .post-content ul li::before {
  content: ">";
  color: #ffff00;
  margin-right: 6px;
}

.theme-dark .separator {
  height: 1px;
  background: #808080;
  width: 100%;
}

.theme-dark input#search {
  all: unset !important;
  display: inline-block !important;
  background: #000 !important;
  color: #ffff00 !important;
  font-family: 'Press Start 2P', monospace !important;
  font-size: 10px !important;
  border: 2px solid #808080 !important;
  padding: 4px 6px !important;
  width: 200px !important;
  box-sizing: border-box !important;
}

.theme-dark input#search:focus {
  border-color: #ffff00 !important;
  background: #111 !important;
}

.theme-dark label[for="search"] {
  color: #ffff00 !important;
  font-family: 'Press Start 2P', monospace !important;
  font-size: 10px !important;
  margin-right: 6px !important;
}

.theme-dark #results,
.theme-dark #results li,
.theme-dark #results li a {
  color: #ffff00 !important;
  font-family: 'Press Start 2P', monospace !important;
  text-decoration: none !important;
}

.theme-dark .post-content img {
  max-width: 100%;
  height: auto;
  display: block;
  margin-left: 5px;
  border: none;
  padding: 1px; 
  background: transparent;
}

.theme-dark .statusbar {
  border-top: 1px solid #fff !important;
}

.theme-dark .bios-dropdown {
    background: #000;
    border-color: #ffff00;
}

.theme-dark .bios-item {
    color: #fff;
}


.theme-dark .cursor {
  display: inline-block;
  width: 2px;
  height: 1em;
  background: #c0c0c0 !important;
  position: relative;
  z-index: 9999;
  animation: blink 0.7s steps(1) infinite;
}

/* ============================================================
   mobile 
   ============================================================ */

@media (max-width: 900px) {

  .screen,
  .theme-dark .screen {
    grid-template-columns: 100% !important;
  }

  .screen::before,
  .theme-dark .screen::before {
    display: none !important;
  }

  .left-pane,
  .right-pane,
  .theme-dark .left-pane,
  .theme-dark .right-pane {
    width: 100% !important;
    padding: 6px !important;
  }

  body,
  .theme-dark body {
    font-size: 8px !important;
  }

  .left-pane li,
  .right-pane li,
  .post-content li,
  .theme-dark .left-pane li,
  .theme-dark .right-pane li,
  .theme-dark .post-content li {
    font-size: inherit !important;
  }

  .menubar,
  .theme-dark .menubar {
    padding: 2px 0 !important;
  }

  .menubar a,
  .theme-dark .menubar a {
    margin: 0 8px !important;
    font-size: 8px !important;
  }

  .statusbar,
  .theme-dark .statusbar {
    font-size: 8px !important;
    padding: 2px 0 !important;
    white-space: nowrap !important;
    overflow-x: auto; 
    overflow-y: hidden;
    line-height: 1.2 !important;
    text-align: center !important;
    font-size: 2.2vw;
  }


  .post-content img,
  .theme-dark .post-content img {
    width: 100% !important;
    height: auto !important;
    max-width: 480px !important;
    max-height: auto !important;
    display: block;
    margin-left: auto;
    margin-right: auto;
    border: none;
  }

  .highlighter-rouge pre,
  .highlight pre,
    pre {
    color: #ffff00  !important;
    font-family: 'PxPlus IBM VGA8' !important;
    padding: 8px !important;
    margin: 0 0 1rem 0 !important;
    letter-spacing: 1px;
    font-size: 10px; 
    white-space: pre-wrap;
    word-wrap: break-word;
    overflow-x: auto;
}

  code {
    color: #ffff00  !important;
    padding: 2px 4px !important;
    font-family: 'PxPlus IBM VGA8' !important;
    letter-spacing: 1px;
    font-size: 10px;
    white-space: pre-wrap;
    word-wrap: break-word;
    overflow-x: auto;
}

}

@media (max-width: 900px) {
  .sb-select,
  .sb-info,
  .sb-exit,
  .sb-copy {
    display: none;
  }
}

@media (max-width: 900px) {
  .theme-dark .left-pane {
    border-bottom: 1px solid #444; 
    margin-bottom: 6px;
    padding-bottom: 6px;
  }
}

@media (max-width: 900px) {
  .left-pane {
    border-bottom: 1px solid #FFF; 
    margin-bottom: 6px;
    padding-bottom: 6px;
  }
}

