* {
  box-sizing: border-box;
}
html {
	padding-bottom: 300px;
  min-width: 100%;
  min-height: 100%;
  margin: 0;
  padding: 0;
  margin-bottom: 150px;
}
body {
  min-width: 100%;
  min-height: 100%;
  background-color: #e6f0f0;
  transition: background-color 100ms;
	color: #111111;
	font-size: 10px;
	font-family: Trebuchet MS, Helvetica, Arial, sans-serif;
  margin: 0;
	padding: 20px 30px 30px 30px;
	transition: opacity 100ms;
}
body.loading {
  opacity: 0;
}
body.black {
  background: #211;
  color: #eee;
}
small {
	font-size: 10px;
}
label {
  display: inline-block;
  min-width: 100px;
  text-align: right;
  padding-right: 5px;
}
button, input[type=submit] {
	font-size: 10px;
	font-family: Trebuchet MS, Helvetica, Arial, sans-serif;
	font-weight: bold;
	color: #140A0A;
	border: 2px #140A0A solid;
	padding: 2px;
	margin: 3px;
	background-color: #c8d0dc;
	text-transform: uppercase;
	cursor: pointer;
}
.desktop button:hover,
.desktop input[type=submit] {
  color: #040a0a;
  background-color: #d8ece0;
}
.hidden {
  visibility: hidden;
}
h1 {
  font-size: 30px;
  font-weight: bold;
  margin: 0;
}
.subtitle {
  margin-bottom: 10px;
  line-height: 1.5;
}
.subtitle:empty {
  display: none;
}
.bluebox {
	background-color: #d8e0ec;
	color: #000000;
	text-align: center;
	border: 1px solid #321;
	padding: 3px;
	margin: 0 0 5px 0;
}
.bluebox input[type=text] {
  border: 1px solid #000;
  font-size: 12px;
  position: relative;
  top: 1px;
  margin-bottom: 5px;
}
.bluebox big {
  display: block;
  text-align: center;
  margin-top: 2px;
  margin-bottom: 4px;
}
.bluebox.alert {
	display: none;
	background-color: #ff6666;
}
.bluebox.alert a {
	font-family: georgia, garamond, serif;
	font-weight: bold;
	color: #000;
	display: block;
	padding: 10px;
	font-size: 12px;
}
.desktop .bluebox.alert a:hover {
	color: #000;
}
.bluebox.countdown {
  border-width: 2px;
}
a.headline:link,
a.headline:visited { color: #111; text-decoration: none; }
a.headline h1 { text-decoration: none; }
.desktop a.headline:hover { color: #654; text-decoration: none; }
a:link    { color: #2050ca; text-decoration: underline; }
a:visited { color: #1030aa; text-decoration: none; }
a:active  { color: #a0a0c7; text-decoration: underline; }
.desktop a:hover   { color: #2040f0; text-decoration: underline; }
hr {
  border-color: #000;
  opacity: 0.6;
  height: 2px;
}
input[type=text],
input[type=password] {
  font-family: 'Trebuchet MS', sans-serif;
  font-size: 10px;
  border: 1px solid #888;
  padding: 3px;
}
input[type=file] {
  cursor: pointer;
}
#menu {
  margin: 7px 0 14px;
}

table, tr {
  margin: 0; padding: 0;
  border-spacing: 0;
}

.lastlog {
  float: right;
  width: 100%;
  padding: 5px 5px;
}

#sidebar, #content {
  float: left;
}
#sidebar {
  width: 300px;
  margin-left: 10px;
}
#content {
  width: -webkit-calc(100% - 310px);
  width: calc(100% - 310px);
  max-width: 814px;
}

#content .ledger {
  width: 100%;
}
#details .ledger {
  width: auto;
}

#searchbox.bluebox {
  text-align: left;
  padding: 3px 2px 3px 4px;
}
#searchbox input[type=text] {
  width: 225px;
  margin-left: 3px;
}

#hootbox.bluebox {
  text-align: left;
  padding: 0;
}
#hootbox form {
  padding: 4px;
}
#hootbox input[type=text] {
  width: calc(100% - 57px);
  margin-left: 3px;
}
#hootbox button {
  width: 44px;
}
#hoots {
  width: 100%;
}
#hoots, #hoots tr {
  margin: 0;
  padding: 0;
  border-spacing: 0;
}
#hoots td {
  margin: 0;
  padding: 0;
  border-top: 1px solid #321;
}
#hoots td:nth-child(1){
  border-right: 1px solid #321;
  width: 40px;
  height: 40px;
  background-size: cover;
  background-position: center center;
}
#hoots .avatar a {
  display: block;
  width: 100%;
  height: 100%;
}
#hoots td:nth-child(2) {
  text-align: left;
  padding: 5px;
}
#hoots td:nth-child(2).image {
  padding: 0;
}
#hoots img {
  max-width: 100%;
}
#hoots tr:nth-child(odd) td:nth-child(2) { background-color: #f3f1f2; }
#hoots tr:nth-child(even) td:nth-child(2) { background-color: #e3e8e3; }

#threads .keyword td {
  vertical-align: top;
  font-weight: normal;
  padding-right: 4px;
  line-height: 15px;
  padding-top: 10px;
  padding-bottom: 4px;
}
#threads .keyword:first-child td {
  padding-top: 5px;
}
#threads .keyword td:first-child {
  text-align: right;
}
#threads .keyword td b {
  font-weight: bold;
  font-size: 14px;
}
#threads .keyword td b a {
  color: #211;
  text-decoration: none;
}
.desktop #threads .keyword td b a:hover {
  color: black;
  text-decoration: underline;
}
#threads .keyword:first-child td:nth-child(2) {
  border-top: 0;
}
.row.first td:nth-child(2) {
  border-top: 1px solid #876;
}
.row.last td:nth-child(2),
#threads .row:last-child td:nth-child(2) {
  border-bottom: 1px solid #876;
}

.ledger {
}
.ledger .row td {
  text-align: right;
  padding-left: 4px;
  padding-right: 4px;
}
.ledger .row td:nth-child(1) a {
  color: #444;
  text-decoration: none;
}
.desktop .ledger .row td:nth-child(1) a:hover {
  text-decoration: underline;
}
.ledger .row td:nth-child(2) {
  text-align: left;
  font-family: Georgia, serif;
  font-size: 120%;
  border-left: 1px solid #876;
  border-right: 1px solid #876;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 30vw;
  white-space: nowrap;
  padding: 0;
}
.ledger .row td:nth-child(2) a {
  display: block;
  padding: 4px 5px;
  text-decoration: none;
  color: #222;
}
#threads td:nth-child(6) {
  text-align: center;
}

tr:nth-child(odd).file	td { background-color: #e6f0f0; }
.desktop tr:nth-child(odd).file:hover	td { background-color: #d8e0ec; color: #000000; }
tr:nth-child(even).file td { background-color: #e0e8e8; }
.desktop tr:nth-child(even).file:hover td { background-color: #d8e0ec; color: #000000; }

tr:nth-child(odd).file.checked  td { background-color: #c6d0d0; }
.desktop tr:nth-child(odd).file.checked:hover td { background-color: #c8d0dc; color: #000000; }
tr:nth-child(even).file.checked td { background-color: #c0c8c8; }
.desktop tr:nth-child(even).file.checked:hover td { background-color: #b8c0cc; color: #000000; }


tr:nth-child(odd) td.row	{ background-color: #e6f0f0; }
.desktop tr:nth-child(odd) td.row:hover	{ background-color: #d8e0ec; color: #000000; }
tr:nth-child(even) td.row { background-color: #e0e8e8; }
.desktop tr:nth-child(even) td.row:hover	{ background-color: #d8e0ec; color: #000000; }

tr:nth-child(odd) td.plain{ background-color: #d0dBe8; border-bottom: 1px solid #d3d3d0; }
.desktop tr:nth-child(odd) td.plain:hover	{ background-color: #d7e4f0; color: #000000; border-bottom-color: #d3d3d0; }
tr:nth-child(even) td.plain { background-color: #edf8f6; border-bottom-color: #d3d3d0; }
.desktop tr:nth-child(even) td.plain:hover	{ background-color: #f3fafa; color: #000000; border-bottom-color: #ded2dd; }

tr:nth-child(odd) td.ivory{ background-color: #e0e0d8; border-bottom-color: #d3d3d0; }
.desktop tr:nth-child(odd) td.ivory:hover	{ background-color: #f8f0e9; color: #000000; border-bottom-color: #d3d3d0; }
tr:nth-child(even) td.ivory { background-color: #f0f0ea; border-bottom-color: #d3d3d0; }
.desktop tr:nth-child(even) td.ivory:hover	{ background-color: #f8f0e9; color: #000000; border-bottom-color: #d3d3d0; }

tr:nth-child(odd) td.tan	{ background-color: #e1e1bf; border-bottom-color: #ced2cd; }
.desktop tr:nth-child(odd) td.tan:hover	{ background-color: #f7f6ed; color: #000000; border-bottom-color: #ced2cd; }
tr:nth-child(even) td.tan { background-color: #f0eddf; border-bottom-color: #ced2cd; }
.desktop tr:nth-child(even) td.tan:hover	{ background-color: #f7f6ed; color: #000000; border-bottom-color: #ced2cd; }

tr:nth-child(odd) td.red	{ background-color: #fcc7c2; border-bottom-color: #E8B1AC; }
.desktop tr:nth-child(odd) td.red:hover	{ background-color: #FFACB2; color: #000000; border-bottom-color: #E8B1AC; }
tr:nth-child(even) td.red { background-color: #fde1df; border-bottom-color: #E8B1AC; }
.desktop tr:nth-child(even) td.red:hover	{ background-color: #FFACB2; color: #000000; border-bottom-color: #E8B1AC; }

tr:nth-child(odd) td.orange     { background-color: #F8E0C6; border-bottom-color: #F5D1AA; }
.desktop tr:nth-child(odd) td.orange:hover{ background-color: #FFD799; color: #000000; border-bottom-color: #F5D1AA; }
tr:nth-child(even) td.orange     { background-color: #FBEEE1; border-bottom-color: #F5D1AA; }
.desktop tr:nth-child(even) td.orange:hover{ background-color: #FFD799; color: #000000; border-bottom-color: #F5D1AA; }

tr:nth-child(odd) td.yellow     { background-color: #FAFDC2; border-bottom-color: #CED3D2; }
.desktop tr:nth-child(odd) td.yellow:hover{ background-color: #FFF7A8; color: #000000; border-bottom-color: #CED3D2; }
tr:nth-child(even) td.yellow     { background-color: #FDFEDF; border-bottom-color: #CED3D2; }
.desktop tr:nth-child(even) td.yellow:hover{ background-color: #FFF7A8; color: #000000; border-bottom-color: #CED3D2; }

tr:nth-child(odd) td.green      { background-color: #E6FFCC; border-bottom-color: #AFD8AB; }
.desktop tr:nth-child(odd) td.green:hover { background-color: #d8F4b4; color: #000000; border-bottom-color: #AFD8AB; }
tr:nth-child(even) td.green      { background-color: #F0FFE2; border-bottom-color: #AFD8AB; }
.desktop tr:nth-child(even) td.green:hover { background-color: #d4eeb0; color: #000000; border-bottom-color: #AFD8AB; }

tr:nth-child(odd) td.blue       { background-color: #ddE2FF; border-bottom-color: #c9c9F5; }
.desktop tr:nth-child(odd) td.blue:hover  { background-color: #cac8fe; color: #000000; border-bottom-color: #c9c9F5; }
tr:nth-child(even) td.blue       { background-color: #ebefff; border-bottom-color: #c9c9F5; }
.desktop tr:nth-child(even) td.blue:hover  { background-color: #cac8fe; color: #000000; border-bottom-color: #c9c9F5; }

tr:nth-child(odd) td.purple     { background-color: #E0CBF4; border-bottom-color: #D6A9EA; }
.desktop tr:nth-child(odd) td.purple:hover{ background-color: #DDB1FF; color: #000000; border-bottom-color: #D6A9EA; }
tr:nth-child(even) td.purple     { background-color: #EFE4F9; border-bottom-color: #D6A9EA; }
.desktop tr:nth-child(even) td.purple:hover{ background-color: #DDB1FF; color: #000000; border-bottom-color: #D6A9EA; }

tr:nth-child(odd) td.pink       { background-color: #F1CDE4; border-bottom-color: #E8ABD2; }
.desktop tr:nth-child(odd) td.pink:hover  { background-color: #FFAECD; color: #000000; border-bottom-color: #E8ABD2; }
tr:nth-child(even) td.pink       { background-color: #F8E5F1; border-bottom-color: #E8ABD2; }
.desktop tr:nth-child(even) td.pink:hover  { background-color: #FFAECD; color: #000000; border-bottom-color: #E8ABD2; }

tr:nth-child(odd) td.black       { background-color: #ccc; border-bottom-color: #aaa; }
.desktop tr:nth-child(odd) td.black:hover  { background-color: #f8f8f8; color: #000000; border-bottom-color: #aaa; }
tr:nth-child(even) td.black       { background-color: #eee; border-bottom-color: #aaa; }
.desktop tr:nth-child(even) td.black:hover  { background-color: #f8f8f8; color: #000000; border-bottom-color: #aaa; }

.new    { color: #000000; font-weight: bold; }
.recent { color: #001111; }
.med    { color: #203838; }
.old    { color: #425050; }
.older  { color: #5D6464; }
.quiet  { color: #787878; }

#profile_rapper,
#details_rapper {
  width: 100%;
  text-align: center;
}
#profile .r,
#details {
  display: flex;
  flex-direction: row;
  text-align: left;
  width: 100%;
}
#details .left {
  vertical-align: top;
}
#details .right {
  vertical-align: top;
  width: 50%;
}
.r .left {
  padding-right: 20px;
  padding-bottom: 20px;
}
.r .right {
  padding-bottom: 20px;
}

#comments {
  width: 100%;
  max-width: 600px;
  padding-right: 20px;
}
#comments tr .user {
  margin: 0;
  padding: 2px 2px 4px 0;
  text-align: center;
  font-size: 10px;
  opacity: 0.9;
  vertical-align: top;
}
#comments .avatar {
  box-shadow: 0 1px 0.5px rgba(32,16,16,0.4);
  width: 40px;
  height: 40px;
  background-size: cover;
  margin: 0 auto;
  margin-bottom: 2px;
  background-position: center center;
}
#comments tr#comment_form + tr .comment,
#comments tr:first-child .comment {
  border-top: 1px solid #ccc;
}
.comment {
  padding: 10px;
  border-bottom: 1px solid #ccc;
  border-left: 1px solid #ccc;
  border-right: 1px solid #ccc;
  position: relative;
  vertical-align: top;
  padding-right: 110px;
  color: #111111;
}
.comment .body {
  font-size: 12px;
  line-height: 1.3;
  width: 100%;
  padding-bottom: 3px;
  margin-right: 110px;
}
.contents {
  white-space: pre-wrap;
}
.comment .date {
  position: absolute;
  bottom: 12px;
  right: 8px;
  display: inline-block;
  text-align: right;
}
.comment .edit-links {
  position: absolute;
  top: 12px;
  right: 8px;
  display: inline-block;
}
.comment .date,
.comment .edit-links {
  color: #444;
  font-size: 9px;
  opacity: 0.8;
  transition: opacity 0.1s;
}
.desktop .comment:hover .date,
.mobile .date,
.desktop .comment:hover .edit-links,
.mobile .edit-links {
  opacity: 1;
}
.edit-links {
}
.comment .edit-links a {
  color: #8f8ff8;
}
.desktop .comment .edit-links:hover { opacity: 1.0; }
.desktop .comment .edit-links a:hover { color: #11f; }
.comment img {
  max-width: 100%;
}
tr:nth-child(2n) td.comment { background-color: #f3f1f2; }
tr:nth-child(2n+1) td.comment { background-color: #fcf8f8; }

code,
pre {
  display: block;
  white-space: pre;
  width: 100%;
  overflow-x: auto;
  background: #fefefe;
  margin: 2px;
  padding: 5px;
  border: 1px solid #ddd;
  max-width: 580px;
  font-family: Menlo, monospace;
  font-size: 11px;
}
code br,
pre br {
  display: none;
}
tt, kbd {
  max-width: 580px;
  display: inline-block;
  font-family: Menlo, monospace;
  background: #fefefe;
  border: 1px solid #ddd;
  padding: 2px;
  font-size: 11px;
}

#thread_form form {
  width: 530px;
}
#thread_form input[name=title] {
  width: 100%;
  padding: 5px;
  font-size: 15px;
  margin-top: 10px;
}
#compose textarea,
#thread_form textarea {
  width: 100%;
  height: 240px;
  font-family: 'Trebuchet MS', sans-serif;
  padding: 5px;
  font-size: 15px;
  margin: 10px 0;
}
#compose {
  width: 530px;
}
#compose input[type=text] {
  font-size: 15px;
}
#compose label {
  min-width: 50px;
}
#compose textarea {
  margin-top: 5px;
  margin-left: 50px;
}
#compose input[name=subject] {
  width: 400px;
}
#compose .buttons {
  position: relative;
  text-align: right;
  left: 50px;
}
.inputs {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  width: 100%;
  padding: 5px;
}
#thread_form input[type=submit] {
  margin: 0;
}
.settings_link {
  font-weight: normal;
}

#comment_form {
  width: 100%;
  max-width: 600px;
  text-align: right;
}
#comment_form form {
  width: 100%;
  max-width: 530px;
  padding-top: 5px;
  padding-right: 20px;
}
#comment_form textarea {
  width: 100%;
  font-family: 'Trebuchet MS', sans-serif;
  padding: 5px;
  font-size: 13px;
  background: white;
  border-color: #ddd;
  height: 240px;
}
#comment_form textarea.empty {
  background: transparent;
  border-color: transparent;
  border-bottom: 1px solid #333;
  height: 24px;
  opacity: 0.5;
  padding: 5px 5px 0 0px;
}
#comment_form textarea.empty::placeholder {
  color: black;
}
#comment_form.focused textarea.empty::placeholder {
  color: #888;
}
.black #comment_form textarea.empty::placeholder {
  color: #fff;
  padding-bottom: 4px;
  border-bottom: 1px solid #fff;
}
#comment_form.focused textarea {
  background: white;
  height: 240px;
  transition: height 100ms cubic-bezier(0,0,0,1);
  opacity: 1;
}
#comment_form .inputs {
  opacity: 0.5;
}
#comment_form input[type=submit] {
  display: none;
}
#comment_form.focused .inputs {
  opacity: 1;
}
#comment_form.focused input[type=submit] {
  display: block;
}

/* FILES */

.files,
.files tr {
  margin: 0; padding: 0;
  border-spacing: 0;
}
.files {
  border: 1px solid #ccc;
  margin-bottom: 10px;
}
.files td {
  padding: 5px;
  font-size: 11px;
}
.files td.name {
  padding: 0;
}
.files td.name a {
  display: block;
  padding: 5px 0 5px 4px;
  text-overflow: ellipsis;
}
.files .user a {
  text-decoration: none;
  color: #333;
}
.desktop .files user a:hover {
  text-decoration: underline;
}
.files td.name {
  text-align: left;
}
.files td {
  text-align: right;
}
.files .total td {
  text-align: right;
  border-top: 1px dotted #888;
}
.files .playing:before {
  content: "> ";
}
.files tr.total td:first-child {
  padding: 5px;
}
.bold {
  font-weight: bold;
}
.italic {
  font-style: italic;
}
.total div {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
}
.files .total td a {
  display: inline;
}
#gallery {
  width: 100%;
}
#gallery div {
  display: inline-block;
  text-align: center;
  padding: 0 0 12px 0;
}
#gallery div a:first-child .thumb {
  max-width: 100%;
  max-height: 450px;
}
#profile #gallery div a:first-child .thumb {
  max-width: 200px; max-height: 200px;
}
#gallery .thumb {
  max-width: 150px;
}

.modal {
  position: fixed;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.2);
  opacity: 0;
  transition: opacity 200ms;
  pointer-events: none;
}
.modal.visible {
  opacity: 1;
  pointer-events: auto;
}
.modal .inner {
  position: absolute;
  top: 30%;
  left: 50%;
  transform: translate3d(-50%,-20%,0);
  background: white;
  color: #333;
  border: 1px solid #ddd;
  box-shadow: 0 1px 1px rgba(0,0,0,0.1);
}

/* SETTINGS */
#thread_settings h2 {
  font-size: 16px;
  margin: 0;
}
#thread_settings .inner {
  padding: 20px;
  text-align: left;
}
#thread_controls {
  margin-top: 10px;
  display: flex;
  flex-direction: row;
}
#thread_controls > div {
  max-width: 60%;
}
#thread_fields {
  text-align: left;
}
.thread_field,
#thread_fields > div {
  display: flex;
  flex-direction: row;
  margin-top: 5px;
}
#thread_controls label {
  margin-top: 4px;
  padding-right: 5px;
}
#thread_fields input[type=text] {
  font-size: 13px;
  width: 200px;
  transform: translateY(-2px);
}
#thread_settings .close_link {
  position: absolute;
  top: 23px;
  right: 10px;
}
#thread_fields label {
  display: block;
  width: 80px;
}
.desktop button.thread_delete:hover {
  background: #ff8288;
}
.allowed_field_container,
.allowed_names {
  display: none;
}
#thread_controls .allowed_names div {
  display: inline-block;
  white-space: nowrap;
  margin-right: 10px;
}
#thread_controls .allowed_names label {
  min-width: auto;
  padding-right: 2px;
  width: auto;
  display: inline-block;
}
#thread_settings #right_side {
  margin-left: 10px;
  max-height: 70vh;
  overflow: auto;
}
#thread_settings .files td.name a {
  width: 130px;
  overflow: hidden;
}
.move_files_select {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
}
.move_files_select select {
  flex: 1;
}

/* SEARCH */

#search {
  padding: 5px;
  color: #333;
}
#search b {
  color: #000;
}
#search a b {
  color: #000;
}
#search .preamble {
  font-size: 14px;
  margin: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid #ddd;
}
#search .result {
  display: flex;
  flex-direction: row;
  margin: 10px 0 20px;
}
#search .image {
  flex: 0 0 100px;
  width: 100px;
  height: 50px;
  background-size: cover;
  display: block;
}
#search .desc {
  display: block;
  width: 500px;
  padding-left: 10px;
}
#search .meta {
  margin-top: 5px;
  font-size: 10px;
  color: #444;
}
#search .search_hit {
  font-size: 15px;
  display: block;
}
#search .snippet {
  font-size: 13px;
  margin: 10px;
}
#search .file a {
  border: 1px solid #bbb;
  background: #eee;
  padding: 5px;
  margin: 10px 0;
}
.next_page {
  font-size: 14px;
  display: block;
  padding: 10px;
}
.search_form {
  margin-bottom: 10px;
}
.search_form .button {
  background-image: url("data:image/svg+xml,%3C%3Fxml version=%221.0%22 encoding=%22UTF-8%22%3F%3E%0A%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 width=%2212%22 height=%2213%22%3E%0A%09%3Cg fill=%22none%22 stroke=%22%2354595d%22 stroke-width=%222%22%3E%0A%09%09%3Cpath d=%22M11.29 11.71l-4-4%22/%3E%0A%09%09%3Ccircle cx=%225%22 cy=%225%22 r=%224%22/%3E%0A%09%3C/g%3E%0A%3C/svg%3E%0A");
  background-position: center center;
  background-repeat: no-repeat;
  width: 16px; height: 16px;
  position: relative;
  top: 3px;
  display: inline-block;
}
.search_form input[type='text'] {
  border-top: 0;
  border-left: 0;
  border-right: 0;
  border-bottom: 1px solid #888;
  padding-bottom: 3px;
  font-size: 14px;
  font-family: 'Trebuchet MS', sans-serif;
  background: transparent;
  outline: 0;
  width: 270px;
  transition: background 200ms;
  background: white;
}
.search_form input[type='text']:invalid {
  background: transparent;
}
.search_form input[type='text']:focus {
  border-bottom: 1px solid #211;
  border-radius: 2px 2px 0 0;
  color: #211;
}

#no_messages {
	display: none;
}
#messages {
  width: 100%;
}
#messages .unread {
	font-weight: bold;
	text-decoration: underline;
}
#messages tr td:nth-child(1) {
  text-align: right;
  padding-right: 3px;
}
#messages tr td:nth-child(3) {
  text-align: center;
  padding-left: 3px;
}
#boxes table {
  width: 200px;
  font-size: 13px;
  margin: 0 auto;
}
#boxes td {
  padding: 3px;
}

#message {
  text-align: left;
  max-width: 500px;
  margin-top: 20px;
  margin-left: 40px;
}
#message .av {
  float: left;
  margin: 4px 8px 4px 4px;
  width: 40px;
  height: 40px;
  background: #fff;
  background-size: cover;
}
#message > span {
  display: inline-block;
  line-height: 14px;
  margin-top: 7px;
}
#message .subject {
  font-weight: bold;
  font-size: 15px;
  display: block;
}
#message hr {
  clear: both;
}
#message .body {
  font-size: 12px;
  line-height: 15px;
  padding: 20px;
}
.login header .search_form,
.signup header .search_form,
.search header .search_form,
.index header .search_form {
  display: none;
}
header {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
}
header .search_form {
  margin-top: 10px;
  white-space: nowrap;
}
.index header .search_form input[type=text] {
  width: 250px;
}

/* PROFILE */

#profile img {
  max-width: 300px;
  max-height: 300px;
}
.profile_meta td {
  padding: 4px;
  font-size: 13px;
  color: #211;
}
.profile_meta td:first-child {
  font-weight: bold;
  padding-right: 20px;
  color: #322;
}

/* LOGIN */

#login form > div,
#signup form > div,
#profile_form form > div {
  margin: 2px;
  display: flex;
  flex-direction: row;
}
#login .errors {
  display: inline-block;
}
#login label,
#signup label,
#profile_form label {
  margin-top: 4px;
}
#profile_form #profile-pic-embed {
  display: block;
  margin-bottom: 5px;
  max-width: 100px;
}
#profile_form input[type=text] {
  width: 200px;
}
#profile_form form > div.oldpassword {
  margin-top: 12px;
  display: none;
}
#profile_form #profile-avatar-embed {
  max-width: 250px;
  display: block;
  margin-bottom: 5px;
}
.save_field a {
  margin-top: 7px;
  margin-left: 7px;
}

/* ADMIN */

.admin {
  height: 100%;
  background-image: linear-gradient(to bottom, rgba(255,254,248,0.5) 0%,rgba(0,0,0,0) 100%);
  background-position: fixed;
}
.admin h1, big {
  text-shadow: 0 2px 4px #fff;
}
.admin #content {
  padding-top: 10px;
}

/* 404 */

#error_404 {
  display: none;
  margin: 10px 0;
}
#error_404 a {
  font-size: 16px;
}

/* loader */

.sending input[type=submit],
.sending button {
  display: none !important;
}
.sending input[type=submit] + .loader,
.sending button + .loader {
  display: block;
}
.loader {
  display: none;
  position: relative;
  width: 19px;
  height: 19px;
  margin-left: 13px;
  color: #987;
}
.loader:after {
  position: absolute;
  margin: auto;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  content: " ";
  display: inline-block;
  border-radius: 50%;
  border-style: solid;
  border-width: 0.15em;
  -webkit-background-clip: padding-box;
  border-color: currentColor currentColor currentColor transparent;
  box-sizing: border-box;
  -webkit-animation: ld-cycle 0.8s infinite linear;
  animation: ld-cycle 0.8s infinite linear;
}
@-webkit-keyframes ld-cycle {
  0%, 50%, 100% {
    animation-timing-function: cubic-bezier(0.5, 0.5, 0.5, 0.5);
  }
  0% {
    -webkit-transform: rotate(0);
    transform: rotate(0);
  }
  50% {
    -webkit-transform: rotate(180deg);
    transform: rotate(180deg);
  }
  100% {
    -webkit-transform: rotate(360deg);
    transform: rotate(360deg);
  }
}
@keyframes ld-cycle {
  0%, 50%, 100% {
    animation-timing-function: cubic-bezier(0.5, 0.5, 0.5, 0.5);
  }
  0% {
    -webkit-transform: rotate(0);
    transform: rotate(0);
  }
  50% {
    -webkit-transform: rotate(180deg);
    transform: rotate(180deg);
  }
  100% {
    -webkit-transform: rotate(360deg);
    transform: rotate(360deg);
  }
}
audio {
  width: 100%;
}


/* mobile css and errata */

@media (min-width: 700px) and (max-width: 1025px) {
  #sidebar {
    display: none;
  }
  #content {
    width: 100%;
  }
  .admin #sidebar {
    display: block;
  }
  .index header .search_form {
    display: block;
  }
}
@media (max-width: 1025px) {
  html {
    padding-bottom: 0px;
  }
  body {
    padding: 0;
  }
  header {
    flex-direction: column;
    justify-content: flex-start;
  }
  h1 {
    font-size: 20px;
    margin-bottom: 10px;
  }
  #sidebar, #content {
    float: none;
  }
  #content {
    width: 100%;
  }
  #sidebar {
    width: 100%;
    margin-top: 20px;
    margin-left: 0px;
  }
  #sidebar .search_form {
    display: none;
  }
  header .search_form,
  .index header .search_form {
    float: none;
    display: block;
    margin-top: 0;
  }
  #threads td:nth-child(1) {
    display: none;
  }
  #threads td:nth-child(2) {
    min-width: 180px;
  }
  #threads td:nth-child(3) small {
    display: none;
  }
  #threads td:nth-child(4) {
    display: none;
  }
  #threads .size {
    display: none;
  }
  .file td:nth-child(3) {
    display: none;
  }
  #details {
    flex-direction: column;
  }
  #comments {
    padding-right: 0px;
  }
  #comments .avatar {
    width: 30px;
    height: 30px;
  }
  .comment {
    padding-right: 10px;
  }
  .comment .body {
    max-width: 80vw;
    margin: 0;
  }
  .comment .date,
  .comment .edit-links {
    display: block;
    position: static;
    text-align: left;
    margin-top: 5px;
    margin: 0;
  }
  .comment .date {
    margin-top: 10px;
  }
  .comment .edit-links {
    margin-top: 5px;
  }
  #details .right {
    width: 100%;
  }
  input[type=file] {
    width: 150px;
  }
  .ledger .row td {
    padding-left: 2px;
    padding-right: 2px;
  }
}
@media (prefers-color-scheme: dark) {
  body {
    background: #180808;
    color: #f8f8f8;
  }
  button:not(.hoot), input[type=submit] {
    color: #f8f8f8;
    border: 2px #eee solid;
    padding: 2px;
    margin: 3px;
    background-color: #18202c;
    text-transform: uppercase;
    cursor: pointer;
  }
  .desktop button:not(.hoot):hover,
  .desktop input[type=submit] {
    color: #fff;
    background-color: #28303c;
  }
  hr {
    border-color: #fff;
  }
  a.headline:link,
  a.headline:visited { color: #eee; text-decoration: none; }
  .desktop a.headline:hover { color: #fff; text-decoration: none; }
  .ledger .row td:nth-child(1) a { color: #ddd; }
  #threads .keyword td a { color: #ddd; text-decoration: none; }
  .desktop #threads .keyword td a:hover { color: #fff; text-decoration: underline; }
  #threads .keyword td b a { color: #ddd; }
  .desktop #threads .keyword td b a:hover { color: #fff; }
  .subtitle a { color: #eee; text-decoration: none; }
  .desktop.subtitle a:hover { color: #fff; text-decoration: underline; }
  .ledger .new    { color: #ffffff; font-weight: bold; }
  .ledger .recent { color: #f8f0f0; }
  .ledger .med    { color: #e8e0e0; }
  .ledger .old    { color: #d8d0d0; }
  .ledger .older  { color: #b8b0b0; }
  .ledger .quiet  { color: #a7a4a4; }
  
  .files .new    { color: #000000; }
  .files .recent { color: #001111; }
  .files .med    { color: #203838; }
  .files .old    { color: #425050; }
  .files .older  { color: #5D6464; }
  .files .quiet  { color: #787878; }
  .files .total a { color: #fff; }

  .bluebox { box-shadow: 0 0px 1.5px rgba(238,238,255,1.0), 0 0px 1.5px rgba(238,238,255,1.0); }
  .search_form input[type='text']:focus {
    border-bottom-color: #888;
  }
  .search_form input[type='text']:invalid {
    caret-color: #888;
  }
  #comment_form textarea.empty {
    border-bottom-color: #fff;
  }
  #comment_form textarea.empty::placeholder {
    color: #fff;
  }
  #search {
    color: #eee;
  }
  #search b {
    color: #fff;
  }
}
