/* /mystery/ — Yotsuba-style 4chan skin */

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 0;
  background: #ffffee;
  color: #800000;
  font-family: arial, helvetica, sans-serif;
  font-size: 10pt;
  line-height: 1.35;
}

a {
  color: #00e;
  text-decoration: none;
}

a:hover {
  color: #d00;
  text-decoration: underline;
}

.board-nav {
  background: #f0e0d6;
  border-bottom: 1px solid #d9bfb7;
  padding: 4px 8px;
  font-size: 9pt;
  color: #b86;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.board-nav a {
  color: #800000;
}

.board-nav .nav-logo {
  vertical-align: middle;
  image-rendering: auto;
}

.board-nav .nav-right {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  float: none;
}

.board-nav::after {
  content: none;
}

.btn-connect {
  background: #eeaa88 !important;
  border: 2px solid #800000 !important;
  color: #800000 !important;
  font-weight: bold !important;
  padding: 4px 10px !important;
  font-size: 10pt !important;
}

.btn-connect:hover {
  background: #ffccaa !important;
}

.wallet-chip {
  color: #800000;
}

.board-head {
  text-align: center;
  padding: 10px 8px 4px;
}

.board-banner {
  display: inline-block;
  border: 1px solid #800000;
  background: #f0e0d6;
  width: min(300px, 90vw);
  height: 100px;
  margin-bottom: 2px;
  overflow: hidden;
  cursor: pointer;
  line-height: 0;
}

.board-banner-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

.banner-rotate-hint {
  font-size: 8pt;
  color: #b86;
  margin-bottom: 6px;
}

.board-logo,
.title-logo {
  display: inline-block;
  vertical-align: middle;
  margin-right: 6px;
}

.board-title {
  font-family: tahoma, arial, sans-serif;
  font-size: 28px;
  font-weight: bold;
  color: #af0a0f;
  letter-spacing: -1px;
}

.board-subtitle {
  color: #800000;
  font-size: 9pt;
  margin-top: 2px;
}

.blotter {
  max-width: 480px;
  margin: 8px auto;
  padding: 6px 8px;
  background: #f0e0d6;
  border: 1px solid #d9bfb7;
  font-size: 9pt;
  text-align: left;
  color: #000;
}

.blotter b {
  color: #800000;
}

hr {
  border: none;
  border-top: 1px solid #d9bfb7;
  height: 0;
  margin: 10px 0;
}

.thread {
  max-width: 920px;
  margin: 0 auto;
  padding: 0 8px 24px;
}

.postContainer {
  margin: 4px 0;
}

.opContainer .op {
  background: transparent;
}

.replyContainer {
  display: table;
  margin-left: 12px;
}

.sideArrows {
  display: table-cell;
  vertical-align: top;
  color: #b86;
  padding-right: 4px;
  font-size: 10pt;
}

.post.reply {
  display: table-cell;
  background: #f0e0d6;
  border: 1px solid #d9bfb7;
  padding: 2px 6px 4px;
  max-width: 860px;
}

.postInfo {
  color: #800000;
  font-size: 10pt;
  padding: 2px 0;
}

.postInfo .subject {
  color: #cc1105;
  font-weight: bold;
}

.postInfo .name {
  color: #117743;
  font-weight: bold;
}

.postInfo .dateTime,
.postInfo .postNum {
  color: #800000;
}

.postInfo .postNum a {
  color: #800000;
  text-decoration: none;
}

.postInfo .postNum a:hover {
  color: #d00;
}

.fileText {
  font-size: 9pt;
  margin: 2px 0 2px 12px;
  color: #800000;
}

.fileThumb {
  float: left;
  margin: 4px 10px 8px 12px;
}

.fileThumb-second {
  margin-left: 0;
}

.fileThumb img,
.op-thumb {
  display: block;
  border: 1px solid #d9bfb7;
  max-width: 125px;
  height: auto;
  background: #ffffee;
}

.anime-thumb {
  object-fit: cover;
  width: 125px;
  height: 125px;
}

.waifu-corner {
  position: fixed;
  right: 8px;
  bottom: 8px;
  z-index: 40;
  width: 110px;
  pointer-events: none;
  opacity: 0.92;
}

.waifu-corner img {
  width: 100%;
  height: auto;
  display: block;
  filter: drop-shadow(1px 1px 0 #800000);
}

@media (max-width: 700px) {
  .waifu-corner {
    width: 72px;
    opacity: 0.75;
  }

  .board-nav .nav-right {
    width: 100%;
    margin-left: 0;
    justify-content: flex-start;
  }
}

.post.op::after {
  content: "";
  display: block;
  clear: both;
}

.postMessage {
  display: block;
  margin: 4px 0 0 12px;
  padding: 0 0 6px;
  color: #800000;
  font-size: 10pt;
  overflow-wrap: anywhere;
}

.quote {
  color: #789922;
}

.quotelink {
  color: #d00 !important;
}

.quotelink:hover {
  text-decoration: underline;
}

/* Buttons — ugly old form controls */
.btn {
  font-family: arial, helvetica, sans-serif;
  font-size: 10pt;
  background: #f0e0d6;
  border: 1px solid #800000;
  color: #800000;
  padding: 2px 8px;
  cursor: pointer;
  margin: 1px 2px;
}

.btn:hover {
  background: #ffffee;
}

.btn-solid {
  background: #eeaa88;
  border-color: #800000;
  font-weight: bold;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Tables like post form / file info */
.postForm,
.stats-table,
.stats-grid,
.fileText {
  border-spacing: 1px;
  margin-top: 4px;
  color: #800000;
}

.postForm td.label {
  background: #ea8;
  font-weight: bold;
  padding: 2px 6px;
  border: 1px solid #800000;
  white-space: nowrap;
  vertical-align: top;
}

.postForm td:last-child {
  background: #f0e0d6;
  padding: 2px 6px;
  border: 1px solid #d9bfb7;
  min-width: 220px;
}

.stats-table td,
.stats-grid td,
.fileText td {
  padding: 2px 6px;
  border: 1px solid #d9bfb7;
  background: #ffffee;
  vertical-align: top;
}

.stats-table td.posteruid,
.stats-grid td:first-child,
.fileText td:first-child {
  background: #f0e0d6;
  font-weight: bold;
  white-space: nowrap;
}

.ok {
  color: #117743 !important;
  font-weight: bold;
}

.warn {
  color: #cc1105 !important;
  font-weight: bold;
}

.rank-badge {
  display: inline-block;
  background: #eeaa88;
  border: 1px solid #800000;
  padding: 1px 6px;
  font-weight: bold;
  color: #800000;
}

.settle-log {
  margin: 0;
  max-width: 100%;
  max-height: 160px;
  overflow: auto;
  background: #ffffee;
  border: 1px solid #d9bfb7;
  padding: 4px;
  font-family: consolas, "courier new", monospace;
  font-size: 9pt;
  color: #800000;
  white-space: pre-wrap;
}

/* Case pager as imageboard replies strip */
.pager-shell {
  margin-top: 8px;
}

.pager {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
  scroll-snap-type: x mandatory;
  cursor: grab;
}

.case-file {
  flex: 0 0 min(260px, 78vw);
  scroll-snap-align: start;
  background: #ffffee;
  border: 1px solid #d9bfb7;
  padding: 8px;
  min-height: 160px;
  position: relative;
}

.case-file.locked {
  opacity: 0.65;
}

.case-file.locked::after {
  content: "(FILE DELETED — HOLD $MYSTERY)";
  display: block;
  margin-top: 8px;
  color: #cc1105;
  font-size: 9pt;
  font-weight: bold;
}

.case-stamp {
  display: inline-block;
  color: #cc1105;
  border: 1px solid #cc1105;
  font-size: 8pt;
  font-weight: bold;
  padding: 0 4px;
  margin-bottom: 4px;
  text-transform: uppercase;
}

.case-file h3 {
  margin: 0 0 4px;
  color: #cc1105;
  font-size: 11pt;
}

.case-file p {
  margin: 0;
  color: #800000;
}

.pager-controls {
  margin-top: 4px;
}

.dot-row {
  display: inline-block;
  margin-left: 8px;
  vertical-align: middle;
}

.dot {
  width: 8px;
  height: 8px;
  border: 1px solid #800000;
  background: #ffffee;
  display: inline-block;
  margin: 0 2px;
  padding: 0;
  cursor: pointer;
}

.dot.active {
  background: #eeaa88;
}

/* Evidence catalog */
.ticker {
  border: 1px solid #d9bfb7;
  background: #ffffee;
}

.ticker-head {
  background: #f0e0d6;
  border-bottom: 1px solid #d9bfb7;
  padding: 3px 6px;
  font-size: 9pt;
  font-weight: bold;
  color: #800000;
}

.live-pip {
  float: right;
  color: #117743;
}

.ticker-body {
  max-height: 180px;
  overflow: auto;
  font-family: consolas, "courier new", monospace;
  font-size: 9pt;
}

.tick {
  display: grid;
  grid-template-columns: 70px 1fr auto;
  gap: 6px;
  padding: 2px 6px;
  border-bottom: 1px solid #f0e0d6;
  color: #800000;
}

.tick .kind {
  color: #cc1105;
  font-weight: bold;
}

.tick .hash {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Sources list */
.attr-list {
  margin-top: 6px;
}

.attr-item {
  background: #ffffee;
  border: 1px solid #d9bfb7;
  padding: 4px 6px;
  margin: 4px 0;
}

.attr-item a {
  font-weight: bold;
}

.attr-item p {
  margin: 2px 0 0;
  color: #800000;
}

.board-footer {
  text-align: center;
  padding: 8px;
  font-size: 9pt;
  color: #b86;
}

.mint-chip {
  display: inline-block;
  margin-top: 4px;
  padding: 2px 6px;
  background: #f0e0d6;
  border: 1px solid #d9bfb7;
  color: #800000;
  word-break: break-all;
  max-width: 95vw;
}

/* Modal as reply box */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(128, 0, 0, 0.35);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 12px;
}

.modal-backdrop.open {
  display: flex;
}

.modal {
  background: #f0e0d6 !important;
  border: 1px solid #800000 !important;
  padding: 10px !important;
  max-width: 420px;
  width: 100%;
}

.envelope {
  color: #789922;
  font-family: consolas, monospace;
  margin-bottom: 6px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* —— /forum/ (isolated from flywheel UI) —— */
.forum-wrap {
  max-width: 920px;
}

.forum-form {
  margin: 0 auto 12px;
  max-width: 520px;
}

.forum-form input,
.forum-form textarea {
  width: 100%;
  max-width: 400px;
  font-family: arial, helvetica, sans-serif;
  font-size: 10pt;
  border: 1px solid #aaa;
  background: #fff;
  color: #000;
  padding: 3px;
}

.forum-form textarea {
  min-height: 110px;
  resize: vertical;
}

.forum-status {
  margin-left: 8px;
  color: #800000;
  font-size: 9pt;
}

.forum-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 9pt;
  color: #800000;
}

.forum-posts .postContainer {
  margin-bottom: 6px;
}

.forum-empty {
  display: block !important;
  max-width: 100%;
}

.forum-hint {
  font-size: 8pt;
  color: #b86;
  margin-top: 3px;
}

.forum-preview-wrap {
  margin-top: 6px;
}

.forum-preview {
  max-width: 180px;
  max-height: 180px;
  border: 1px solid #d9bfb7;
  display: block;
}

.forum-thumb {
  max-width: 125px;
  max-height: 125px;
  border: 1px solid #d9bfb7;
  display: block;
  background: #ffffee;
}

.forum-posts .post.reply::after {
  content: "";
  display: block;
  clear: both;
}

.drop-summary {
  background: #ffffee;
  border: 1px solid #d9bfb7;
  padding: 6px 8px;
  font-size: 9pt;
}

.drop-log-body {
  max-height: 320px;
}

.drop-run {
  border-bottom: 1px solid #f0e0d6;
  padding: 6px 8px;
  font-size: 9pt;
  color: #800000;
}

.drop-run .drop-head {
  font-weight: bold;
  color: #cc1105;
  margin-bottom: 4px;
}

.drop-run .drop-recip {
  font-family: consolas, "courier new", monospace;
  font-size: 8pt;
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 4px 8px;
  padding: 1px 0;
}

.drop-run a {
  color: #00e;
}

@media (max-width: 600px) {
  .board-nav .nav-right {
    float: none;
    display: flex;
    margin-top: 4px;
  }

  .replyContainer {
    margin-left: 0;
    display: block;
  }

  .sideArrows {
    display: none;
  }

  .post.reply {
    display: block;
  }

  .postMessage {
    margin-left: 0;
  }

  .tick {
    grid-template-columns: 1fr;
  }
}
