/* /pump/ - Yotsuba B + Yotsuba theme for the memecoin board */
:root, [data-theme="yotsuba-b"] {
  --bg: #eef2ff;
  --post-bg: #d6daf0;
  --border: #b7c5d9;
  --hr: #b7C5d9;
  --text: #000000;
  --link: #34345c;
  --link-visited: #0f0c5d;
  --subject: #0f0c5d;
  --name: #117743;
  --quote: #789922;
  --title: #af0a0f;
  --board-title: #af0a0f;
  --page-shadow: #98e;
  --thumb-border: #000;
  --input-bg: #fff;
  --input-border: #aaa;
  --button-bg: #d6daf0;
  --warn-bg: #f0e0d6;
  --warn-border: #d00;
  --demo-bg: #e00;
  --demo-fg: #fff;
  --local-bg: #0f0c5d;
  --bar-bg: #b7c5d9;
  --bar-fill: #117743;
  --omitted: #707070;
  --posteruid-fg: #fff;
  --footer: #34345c;
  --banner-bg: #d6daf0;
  --highlight: #d6bad0;
}

[data-theme="yotsuba"] {
  --bg: #ffffee;
  --post-bg: #f0e0d6;
  --border: #d9bfb7;
  --hr: #d9bfb7;
  --text: #800000;
  --link: #00e;
  --link-visited: #80c;
  --subject: #cc1105;
  --name: #117743;
  --quote: #789922;
  --title: #800000;
  --board-title: #af0a0f;
  --page-shadow: #ea8;
  --thumb-border: #800000;
  --input-bg: #fff;
  --input-border: #aaa;
  --button-bg: #f0e0d6;
  --warn-bg: #ffe;
  --warn-border: #800000;
  --demo-bg: #c00;
  --demo-fg: #fff;
  --local-bg: #800000;
  --bar-bg: #d9bfb7;
  --bar-fill: #117743;
  --omitted: #707070;
  --posteruid-fg: #fff;
  --footer: #800000;
  --banner-bg: #f0e0d6;
  --highlight: #f0c0b0;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Tahoma, Arial, sans-serif;
  font-size: 10pt;
  line-height: 1.4;
}

a { color: var(--link); text-decoration: none; }
a:visited { color: var(--link-visited); }
a:hover { color: var(--title); text-decoration: underline; }

/* Top board nav, 4chan-style */
.board-nav {
  background: var(--post-bg);
  border-bottom: 1px solid var(--border);
  padding: 3px 8px;
  font-size: 9pt;
  overflow-x: auto;
  white-space: nowrap;
}
.board-nav .nav-left, .board-nav .nav-right { display: inline; }
.board-nav .nav-right { float: right; }
.board-nav a { padding: 0 2px; }
.board-nav .sep { opacity: 0.5; }
.board-nav a.active { font-weight: bold; text-decoration: underline; }

.announcement {
  margin: 8px auto;
  max-width: 720px;
  background: var(--warn-bg);
  border: 2px solid var(--warn-border);
  color: var(--text);
  padding: 8px 12px;
  text-align: center;
  font-size: 10pt;
}
.announcement strong { color: var(--title); }

/* Header */
#board-header {
  text-align: center;
  margin: 10px 0 8px;
  clear: both;
}
#board-header .banner-wrap {
  display: inline-block;
  margin-bottom: 4px;
}
#board-header .banner-wrap svg,
#board-header .banner-wrap img {
  width: 300px;
  height: 100px;
  border: 1px solid var(--thumb-border);
  background: var(--banner-bg);
  display: block;
}
.board-title {
  font-size: 28px;
  font-weight: bold;
  color: var(--board-title);
  margin: 0;
  letter-spacing: -1px;
  font-family: Tahoma, Arial, sans-serif;
}
.board-subtitle {
  margin: 0 0 4px;
  font-size: 10pt;
}
.header-buttons {
  margin-top: 6px;
}
.header-buttons button,
.btn, input[type="submit"], input[type="button"], button.btn {
  font-family: Tahoma, Arial, sans-serif;
  font-size: 10pt;
  background: var(--button-bg);
  color: var(--text);
  border: 1px solid var(--border);
  padding: 2px 8px;
  cursor: pointer;
}
.header-buttons button:hover,
.btn:hover, input[type="submit"]:hover {
  border-color: var(--title);
}
button:disabled, .btn:disabled, input:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}
.btn-wallet {
  margin-left: 8px;
  font-style: italic;
}

hr.desktop {
  clear: both;
  border: none;
  border-top: 1px solid var(--hr);
  height: 0;
  margin: 8px 0;
}

/* Forms */
.post-form-wrap {
  width: 100%;
  max-width: 520px;
  margin: 12px auto 16px;
}
.post-form-wrap h3, .form-title {
  text-align: center;
  margin: 0 0 8px;
  color: var(--title);
  font-size: 11pt;
}
.postForm {
  border-spacing: 1px;
  margin: 0 auto;
  width: 100%;
}
.postForm td {
  padding: 0;
  vertical-align: top;
}
.postForm .label {
  background: var(--post-bg);
  border: 1px solid var(--border);
  font-weight: bold;
  padding: 2px 6px;
  width: 110px;
  white-space: nowrap;
}
.postForm .field {
  padding-left: 2px;
}
.postForm input[type="text"],
.postForm input[type="url"],
.postForm input[type="file"],
.postForm textarea {
  font-family: Tahoma, Arial, sans-serif;
  font-size: 10pt;
  background: var(--input-bg);
  color: #000;
  border: 1px solid var(--input-border);
  padding: 2px 4px;
}
.postForm input[type="text"],
.postForm input[type="url"] {
  width: 220px;
  max-width: calc(100% - 70px);
}
.postForm textarea {
  width: 340px;
  max-width: 100%;
  height: 90px;
  resize: vertical;
}
.postForm input[type="file"] { max-width: 100%; }
.postForm input[type="submit"] { margin-left: 4px; vertical-align: middle; }
.postForm .hint { font-size: 8pt; opacity: 0.8; display: block; }
.form-disclaimer {
  font-size: 9pt;
  color: var(--title);
  text-align: center;
  margin: 8px auto;
  max-width: 520px;
  font-weight: bold;
}
#img-preview, .img-preview {
  margin-top: 4px;
  max-width: 250px;
  max-height: 250px;
  border: 1px solid var(--thumb-border);
  display: none;
}
#img-preview[src], .img-preview[src] { display: inline-block; }

/* Threads / posts */
#content {
  padding: 0 10px 40px;
  min-height: 50vh;
}
.thread {
  margin: 4px 0 0;
  clear: both;
  position: relative;
}
.thread + hr, .thread-sep {
  clear: both;
  border: none;
  border-top: 1px solid var(--hr);
  margin: 10px 0 8px;
}

.post {
  margin: 4px 0;
}
.reply {
  background: var(--post-bg);
  border: 1px solid var(--border);
  display: table;
  padding: 2px 4px 4px 2px;
  margin: 4px 16px;
  max-width: 90%;
}
.reply.highlight { background: var(--highlight); }

.file { margin: 0 0 2px 4px; font-size: 9pt; }
.file .file-info { margin-left: 0; }
.fileThumb {
  float: left;
  margin: 3px 20px 8px 4px;
}
.fileThumb img, .fileThumb svg {
  display: block;
  max-width: 250px;
  max-height: 250px;
  width: auto;
  height: auto;
  border: 1px solid var(--thumb-border);
  background: #fff;
}
.reply .fileThumb { margin-left: 8px; }
.reply .fileThumb img, .reply .fileThumb svg {
  max-width: 125px;
  max-height: 125px;
}

.postInfo {
  overflow: hidden;
  padding: 2px 4px;
}
.subject { color: var(--subject); font-weight: bold; }
.name { color: var(--name); font-weight: bold; }
.posteruid {
  display: inline-block;
  font-size: 8pt;
  font-weight: bold;
  padding: 0 3px;
  border-radius: 2px;
  color: var(--posteruid-fg);
  margin-left: 2px;
  letter-spacing: 0.3px;
}
.date { margin-left: 2px; }
.postNum a { text-decoration: none; }
.postMenu { margin-left: 6px; font-size: 9pt; }
.badge {
  display: inline-block;
  font-size: 8pt;
  font-weight: bold;
  letter-spacing: 0.4px;
  padding: 0 4px;
  margin-left: 6px;
  vertical-align: middle;
  color: var(--demo-fg);
  background: var(--demo-bg);
  border-radius: 1px;
}
.badge.local { background: var(--local-bg); }
.ticker-tag {
  font-weight: bold;
  margin-left: 4px;
}

blockquote.postMessage {
  display: block;
  margin: 4px 0 8px 2.2em;
  overflow-wrap: anywhere;
  word-wrap: break-word;
}
.quote { color: var(--quote); }
.quotelink { color: var(--link); text-decoration: underline; }
.quotelink:hover { color: var(--title); }

.mcap-line, .stats-line {
  margin: 2px 0 0;
  font-size: 9pt;
}
.mcap-line strong { color: var(--subject); }
.omitted {
  color: var(--omitted);
  margin: 4px 0 4px 2.2em;
  font-size: 9pt;
}
.sideArrows {
  float: left;
  margin-right: 2px;
  margin-top: 2px;
  color: var(--omitted);
  font-weight: bold;
}

/* Thread page extras */
.thread-tools {
  margin: 6px 0 10px;
  font-size: 9pt;
}
.curve-box {
  background: var(--post-bg);
  border: 1px solid var(--border);
  display: table;
  padding: 8px 12px;
  margin: 8px 0 12px 4px;
  min-width: 280px;
  max-width: 520px;
}
.curve-box h4 {
  margin: 0 0 6px;
  color: var(--subject);
  font-size: 10pt;
}
.curve-bar {
  height: 20px;
  background: #fff;
  border: 1px solid var(--text);
  position: relative;
  margin: 6px 0;
  overflow: hidden;
}
.curve-bar .fill {
  height: 100%;
  background: var(--bar-fill);
  width: 0%;
}
.curve-bar .curve-pct {
  position: absolute;
  inset: 0;
  text-align: center;
  font-size: 9pt;
  font-weight: bold;
  line-height: 20px;
  color: #000;
  pointer-events: none;
  text-shadow: 0 0 3px #fff;
}
.curve-meta { font-size: 9pt; }
.socials a { margin-right: 10px; }

.reply-form-anchor { margin-top: 16px; }

/* Catalog */
.catalog-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  margin: 8px 4px 12px;
  font-size: 9pt;
}
.catalog-bar input[type="search"] {
  font-family: Tahoma, Arial, sans-serif;
  font-size: 10pt;
  padding: 2px 6px;
  border: 1px solid var(--input-border);
  background: var(--input-bg);
  min-width: 180px;
}
.catalog-bar .sorts a, .catalog-bar .sorts span {
  margin-right: 6px;
}
.catalog-bar .sorts a.active, .sort-link.active {
  font-weight: bold;
  text-decoration: underline;
}

#catalog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px 10px;
  padding: 4px;
}
.cat-thread {
  text-align: center;
  vertical-align: top;
  font-size: 9pt;
}
.cat-thread a.thumb-link {
  display: inline-block;
}
.cat-thread img, .cat-thread svg.thumb, .cat-thread .thumb-link img {
  max-width: 150px;
  max-height: 150px;
  width: auto;
  height: auto;
  border: 1px solid var(--thumb-border);
  background: #fff;
}
.cat-meta { margin: 3px 0 2px; }
.cat-teaser {
  margin: 0 auto;
  max-width: 160px;
  overflow: hidden;
  word-wrap: break-word;
  text-align: left;
  font-size: 9pt;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  line-clamp: 4;
}
.cat-teaser .subject { display: inline; }

/* Footer */
#board-footer {
  clear: both;
  text-align: center;
  padding: 18px 10px 30px;
  color: var(--footer);
  font-size: 9pt;
  border-top: 1px solid var(--hr);
  margin-top: 12px;
}
#board-footer .style-switcher { margin-bottom: 6px; }
#board-footer .style-switcher a.active { font-weight: bold; text-decoration: underline; }

.empty-state {
  text-align: center;
  padding: 30px 10px;
  color: var(--omitted);
}

/* Mobile */
@media (max-width: 600px) {
  .board-nav { white-space: normal; }
  .board-nav .nav-right { float: none; display: block; margin-top: 2px; }
  .board-title { font-size: 20px; letter-spacing: 0; }
  #board-header .banner-wrap svg,
  #board-header .banner-wrap img { width: 250px; height: 84px; }
  .fileThumb { margin: 3px 8px 4px 2px; }
  .fileThumb img, .fileThumb svg { max-width: 76px; max-height: 76px; }
  .reply .fileThumb img, .reply .fileThumb svg { max-width: 64px; max-height: 64px; }
  /* comments go full width under the thumb so lines are readable */
  blockquote.postMessage { margin-left: 0.6em; margin-right: 0.4em; clear: both; }
  .omitted { margin-left: 0.6em; }
  .reply { margin-left: 2px; margin-right: 0; max-width: 100%; }
  .post-form-wrap { padding: 0 4px; }
  .postForm { width: 100%; }
  .postForm .label { width: 72px; }
  .postForm input[type="text"],
  .postForm input[type="url"],
  .postForm textarea { width: 100%; max-width: 100%; }
  .postForm input[type="submit"] { display: inline-block; margin: 4px 0 0; }
  #content { padding: 0 4px 30px; }
  .curve-box { width: auto; max-width: 100%; margin-right: 4px; }
  .header-buttons .btn, .header-buttons button { margin: 2px; }
}
