/* Shitchan — классическая вёрстка имиджборда.
   Стили: yotsuba (кремовый), yotsuba-b (голубой), night («Ночной горшок»), plumbing («Сантехника»). */

/* ------------------------------------------------------------------ палитры */

:root,
[data-style="yotsuba"] {
  --bg: #ffffee;
  --bg-fade: #fed6af;
  --text: #800000;
  --link: #0000ee;
  --link-hover: #dd0000;
  --title: #800000;
  --post-bg: #f0e0d6;
  --post-border: #d9bfb7;
  --label-bg: #eeaa88;
  --label-border: #800000;
  --label-text: #800000;
  --subject: #cc1105;
  --name: #117743;
  --quote: #000080;
  --gt: #789922;
  --hr: #d9bfb7;
  --arrow: #e0bfb7;
  --muted: #707070;
  --hl-bg: #f0c0b0;
  --hl-border: #d99f91;
  --mode-bg: #e04000;
  --mode-text: #ffffff;
  --box-border: #800000;
  --boxbar-bg: #ffccaa;
  --boxbar-text: #800000;
  --box-bg: #ffffff;
  --input-bg: #ffffff;
  --input-border: #aaaaaa;
  --input-text: #000000;
  --capcode: #ff0000;
  --tiles: none;
}

[data-style="yotsuba-b"] {
  --bg: #eef2ff;
  --bg-fade: #d1d5ee;
  --text: #000000;
  --link: #34345c;
  --link-hover: #dd0000;
  --title: #af0a0f;
  --post-bg: #d6daf0;
  --post-border: #b7c5d9;
  --label-bg: #9988ee;
  --label-border: #000000;
  --label-text: #000000;
  --subject: #0f0c5d;
  --name: #117743;
  --quote: #34345c;
  --gt: #789922;
  --hr: #b7c5d9;
  --arrow: #b7c5d9;
  --muted: #707070;
  --hl-bg: #d6bad0;
  --hl-border: #ba9dbf;
  --mode-bg: #0040e0;
  --mode-text: #ffffff;
  --box-border: #34345c;
  --boxbar-bg: #9988ee;
  --boxbar-text: #000000;
  --box-bg: #ffffff;
}

/* «Ночной горшок» */
[data-style="night"] {
  --bg: #1d1f21;
  --bg-fade: #1d1f21;
  --text: #c5c8c6;
  --link: #81a2be;
  --link-hover: #a8c3db;
  --title: #c5c8c6;
  --post-bg: #282a2e;
  --post-border: #282a2e;
  --label-bg: #282a2e;
  --label-border: #111111;
  --label-text: #c5c8c6;
  --subject: #b294bb;
  --name: #c5c8c6;
  --quote: #5f89ac;
  --gt: #b5bd68;
  --hr: #2f3236;
  --arrow: #3c3f44;
  --muted: #8b8f91;
  --hl-bg: #1d1d21;
  --hl-border: #111111;
  --mode-bg: #282a2e;
  --mode-text: #c5c8c6;
  --box-border: #282a2e;
  --boxbar-bg: #282a2e;
  --boxbar-text: #c5c8c6;
  --box-bg: #1d1f21;
  --input-bg: #282a2e;
  --input-border: #515151;
  --input-text: #c5c8c6;
  --capcode: #ff5555;
  color-scheme: dark;
}

/* «Сантехника»: кафель и масляная краска */
[data-style="plumbing"] {
  --bg: #e8edea;
  --bg-fade: #e8edea;
  --text: #1c2522;
  --link: #234079;
  --link-hover: #9b4a1c;
  --title: #234079;
  --post-bg: #f7f9f8;
  --post-border: #cdd8d2;
  --label-bg: #2f5c4e;
  --label-border: #234a3e;
  --label-text: #ffffff;
  --subject: #9b4a1c;
  --name: #2b6a45;
  --quote: #234079;
  --gt: #5a8418;
  --hr: #b9c6bf;
  --arrow: #b9c6bf;
  --muted: #5d6c66;
  --hl-bg: #fff4c9;
  --hl-border: #c9a04a;
  --mode-bg: #2f5c4e;
  --mode-text: #ffffff;
  --box-border: #2f5c4e;
  --boxbar-bg: #2f5c4e;
  --boxbar-text: #ffffff;
  --box-bg: #f7f9f8;
  --tiles: linear-gradient(#d7e0db 1px, transparent 1px), linear-gradient(90deg, #d7e0db 1px, transparent 1px);
}

/* ------------------------------------------------------------------ основа */

html { background: var(--bg); }
body {
  margin: 0;
  padding: 0 8px;
  font: 10pt arial, helvetica, sans-serif;
  color: var(--text);
  background: linear-gradient(var(--bg-fade), var(--bg) 220px) no-repeat, var(--bg);
}
[data-style="plumbing"] body {
  background: var(--bg);
  background-image: var(--tiles);
  background-size: 34px 34px;
}
a { color: var(--link); }
a:hover { color: var(--link-hover); }
:focus-visible { outline: 2px solid var(--link); outline-offset: 1px; }
img { border: 0; }
hr { border: 0; border-top: 1px solid var(--hr); height: 0; margin: 6px 0; clear: both; }
hr.hr-head, hr.hr-form { width: 90%; margin: 6px auto; }
.skip { position: absolute; left: 8px; top: -60px; z-index: 100; background: var(--post-bg); padding: 4px 8px; }
.skip:focus { top: 4px; }
.muted, .hint { color: var(--muted); }
.hint { font-size: 9pt; }
.chk { white-space: nowrap; cursor: pointer; }
.chk input { vertical-align: -2px; margin: 0 2px 0 0; }
[hidden] { display: none !important; }
code { font-family: monospace; font-size: 10pt; }
input, textarea, select, button { font: 10pt arial, helvetica, sans-serif; }
input[type="text"], input[type="password"], input[type="search"], textarea, select {
  color: var(--input-text);
  background: var(--input-bg);
  border: 1px solid var(--input-border);
  padding: 2px 4px;
}
[data-style="night"] button {
  color: var(--text); background: #373b41; border: 1px solid #515151; padding: 2px 8px;
}

/* ------------------------------------------------------------------ список досок */

.boardlist { font-size: 9pt; padding: 3px 0; color: var(--text); }
.boardlist-top { overflow: hidden; }
.boardlist a { text-decoration: none; }
.boardlist a:hover { text-decoration: underline; }
.boardlist a[aria-current] { font-weight: bold; }
.bl-group { margin-right: 4px; white-space: nowrap; }
.bl-right { float: right; }
.style-form { display: inline; margin: 0 0 0 4px; }
.style-form select { font-size: 9pt; padding: 0 2px; }
.boardlist-bottom { margin-top: 6px; }

/* ------------------------------------------------------------------ шапка доски */

.board-header { text-align: center; margin-top: 4px; }
.banner { display: block; margin: 0 auto 4px; width: auto; height: auto; max-width: 300px; max-height: 100px; border: 1px solid var(--hr); cursor: pointer; }
.board-title {
  margin: 4px 0 0; font: bold 28px Tahoma, "Segoe UI", sans-serif; letter-spacing: -2px; color: var(--title);
}
.board-title a { color: inherit; text-decoration: none; }
.board-subtitle { margin: 2px 0 6px; font-size: 10px; }

/* ------------------------------------------------------------------ форма постинга */

.posting-mode {
  width: fit-content; min-width: 360px; max-width: 100%; margin: 6px auto 4px; padding: 2px 8px;
  text-align: center; font-weight: bold; font-size: 11pt;
  color: var(--mode-text); background: var(--mode-bg);
}
.pf-toggle { text-align: center; font-size: 13pt; font-weight: bold; margin: 8px 0; }
.pf-wrap { margin: 4px auto; }
.postform { position: relative; width: fit-content; max-width: 100%; margin: 0 auto; }
.pf-table { border-spacing: 1px; margin: 0 auto; }
.pf-table th {
  min-width: 80px; padding: 0 5px; text-align: left; vertical-align: middle;
  font-weight: bold; font-size: 10pt;
  color: var(--label-text); background: var(--label-bg); border: 1px solid var(--label-border);
}
.pf-table td { padding: 0; }
.pf-table input[type="text"], .pf-table input[type="password"] { width: 244px; box-sizing: border-box; }
.pf-table textarea { width: 300px; height: 90px; box-sizing: border-box; resize: both; }
.row-submit { white-space: nowrap; }
.row-submit input { vertical-align: middle; }
.pf-submit { margin-left: 2px; vertical-align: middle; }
.cap-row { display: flex; align-items: center; gap: 4px; margin: 2px 0; }
.cap-img { display: block; width: 168px; height: 56px; border: 1px solid var(--input-border); background: #f4f7f5; cursor: pointer; }
.cap-refresh { padding: 2px 6px; cursor: pointer; }
.pf-table .cap-in { width: 168px; letter-spacing: .1em; }
.pf-table .cap-in::placeholder { letter-spacing: 0; }
.pf-table input[type="file"] { max-width: 230px; }
.bad { outline: 2px solid var(--capcode); }
.pf-status { margin: 3px 0 0; min-height: 0; text-align: center; font-weight: bold; }
.pf-status:empty { display: none; }
.pf-status.err { color: var(--capcode); }
.rules { width: 380px; max-width: 100%; margin: 4px auto 0; padding: 0 0 0 18px; font-size: 9pt; box-sizing: border-box; }
.rules li { margin: 1px 0; }
.pf-help summary { cursor: pointer; color: var(--link); }
.markup-table { border-collapse: collapse; margin: 2px 0 0; }
.markup-table td { padding: 0 10px 0 0; }
.qr-head {
  display: flex; justify-content: space-between; align-items: center; gap: 8px;
  padding: 1px 4px; margin: 0 0 1px; font-weight: bold;
  color: var(--mode-text); background: var(--mode-bg);
}
.qr-close { background: none; border: 0; color: inherit; font-size: 14pt; line-height: 1; cursor: pointer; padding: 0 2px; }
.pf-wrap.qr { margin: 4px 0 6px 24px; }
.pf-wrap.qr .postform { margin: 0; padding: 2px; background: var(--post-bg); border: 1px solid var(--post-border); }
.pf-wrap.qr .rules, .pf-wrap.qr + hr { display: none; }

/* ------------------------------------------------------------------ навигация */

.navlinks { margin: 4px 0; font-size: 10pt; }
.navlinks a { text-decoration: none; }
.navlinks a:hover { text-decoration: underline; }
.upd-status { color: var(--muted); margin-left: 4px; }
.note { text-align: center; font-weight: bold; font-size: 11pt; color: var(--capcode); margin: 10px 0; }
.empty { color: var(--muted); font-size: 11pt; margin: 12px 0; }

/* ------------------------------------------------------------------ посты */

.thread { clear: both; }
.post { position: relative; }
.post::after { content: ""; display: block; clear: both; }
.post.op { margin: 4px 0 2px; }
.post.reply {
  display: block; width: fit-content; max-width: calc(100% - 26px); box-sizing: border-box;
  margin: 4px 0 4px 24px; padding: 2px 6px 2px 2px;
  background: var(--post-bg); border: 1px solid var(--post-border); border-top: 0; border-left: 0;
}
.post.reply::before { content: ">>"; position: absolute; left: -20px; top: 3px; color: var(--arrow); }
.post.reply:target, .post.reply.hl { background: var(--hl-bg); border: 1px solid var(--hl-border); }
.post.op:target .pb, .post.op.hl .pb { background: var(--hl-bg); }
.post.to-you { border-left: 2px solid var(--capcode) !important; }
.post.fresh-in { animation: arrive 1.4s ease-out; }
@keyframes arrive { from { background: var(--hl-bg); } }

.ph { margin: 0; padding: 0 0 0 2px; line-height: 1.5; }
.post.op .ph { display: block; }
.delbox { margin: 0 2px 0 0; vertical-align: -2px; }
.subj { color: var(--subject); font-weight: bold; }
.name { color: var(--name); font-weight: bold; }
.trip { color: var(--name); }
.cap { color: var(--capcode); font-weight: bold; }
.capcoded .name { color: var(--capcode); }
.you { color: var(--capcode); font-weight: bold; font-size: 9pt; margin-left: 2px; }
.sage { color: var(--muted); font-size: 9pt; }
.ph time { white-space: nowrap; }
.post-num { white-space: nowrap; }
.post-num a { color: inherit; text-decoration: none; }
.post-num a:hover { color: var(--link-hover); }
.replylink a { text-decoration: none; }
.badge { font-weight: bold; font-size: 9pt; }
.badge.stuck { color: var(--title); }
.badge.clog { color: var(--capcode); }
.badge.full { color: var(--muted); }
.pm {
  background: none; border: 0; padding: 0 3px; margin: 0; cursor: pointer;
  color: var(--muted); font-size: 8pt; line-height: 1; vertical-align: 1px;
}
.pm:hover, .pm[aria-expanded="true"] { color: var(--text); }
[data-style="night"] .pm { background: none; border: 0; }
.nojs .pm { display: none; }
.bl { font-size: 8pt; }
.bl .ql { margin-right: 3px; }

.file { margin: 2px 0; }
.file-text { margin: 2px 0 2px 20px; font-size: 10pt; }
.post.reply .file-text { margin-left: 10px; }
.thumb-link { float: left; margin: 3px 20px 5px 20px; position: relative; line-height: 0; }
.post.reply .thumb-link { margin: 3px 12px 5px 10px; }
.thumb { display: block; }
.is-video::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: 30px; height: 30px; margin: -15px 0 0 -15px;
  border-radius: 50%; background: rgba(0, 0, 0, .55)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3E%3Cpath d='M12 9l10 6-10 6z' fill='%23fff'/%3E%3C/svg%3E") center/100% no-repeat;
}
.file.open .thumb-link { float: none; }
.file .full { display: block; float: left; max-width: calc(100% - 40px); max-height: 95vh; height: auto; margin: 3px 20px 5px 20px; cursor: zoom-out; }
.file video.full { cursor: auto; background: #000; }
.file .collapse { margin-left: 6px; }
.file.open + .ph, .file.open ~ .pb { clear: both; }
.file-gone { margin: 2px 0 0 20px; color: var(--muted); font-style: italic; }

.pb { margin: 1em 40px; overflow-wrap: anywhere; }
.post.reply .pb { margin: .8em 24px .8em 20px; }
.gt { color: var(--gt); }
.ql { color: var(--quote); }
.ql:hover { color: var(--link-hover); }
.ql.dead { color: var(--muted); text-decoration: line-through; }
.sp { background: #000; color: #000; }
.sp:hover, .sp.open { color: #fff; }
.sp a { color: inherit; }
.banmsg { color: var(--capcode); }
.omitted { margin: 2px 0 2px 24px; color: var(--muted); }

.preview { position: absolute; z-index: 60; max-width: min(640px, calc(100vw - 20px)); }
.preview .post.reply, .preview .post.op {
  display: block; width: auto; max-width: none; margin: 0; padding: 3px 6px 4px 3px;
  background: var(--post-bg); border: 1px solid var(--post-border);
  box-shadow: 1px 1px 3px rgba(0, 0, 0, .35);
}
.preview .post.reply::before { content: none; }
.preview .pm, .preview .mt, .preview .delbox { display: none; }
.preview-msg { padding: 4px 8px; background: var(--post-bg); border: 1px solid var(--post-border); color: var(--muted); }

.post-menu {
  position: absolute; z-index: 70; min-width: 170px; margin: 0; padding: 0;
  background: var(--post-bg); border: 1px solid var(--post-border); box-shadow: 1px 1px 3px rgba(0, 0, 0, .35);
}
.post-menu button {
  display: block; width: 100%; margin: 0; padding: 3px 8px; text-align: left; cursor: pointer;
  font: 10pt arial, helvetica, sans-serif; color: var(--text); background: none; border: 0;
}
[data-style="night"] .post-menu button { background: none; border: 0; }
.post-menu button + button { border-top: 1px solid var(--post-border); }
.post-menu button:hover, .post-menu button:focus-visible { background: var(--hl-bg); }

.toast {
  position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); z-index: 90;
  padding: 4px 12px; font-weight: bold;
  color: var(--text); background: var(--post-bg); border: 1px solid var(--post-border);
  box-shadow: 1px 1px 3px rgba(0, 0, 0, .35);
}

/* ------------------------------------------------------------------ низ страницы */

.bottom-ctrl { overflow: hidden; margin: 4px 0; }
.delform { float: right; text-align: right; font-size: 9pt; }
.delform input[type="password"] { width: 90px; }
.delform-label { font-weight: bold; }
.pagelist {
  display: table; margin: 6px 0; padding: 4px;
  background: var(--post-bg); border: 1px solid var(--post-border); border-top: 0; border-left: 0;
}
.pagelist > div { display: table-cell; padding: 0 6px; vertical-align: middle; }
.pl-pages strong { font-weight: bold; }
.pl-btn { display: inline-block; padding: 1px 8px; border: 1px solid var(--input-border); background: var(--input-bg); color: var(--input-text); text-decoration: none; }
.pl-btn.disabled { opacity: .45; }
.pl-catalog a { font-weight: bold; }
.footer { clear: both; margin: 10px 0 16px; text-align: center; font-size: 9pt; }
.footer p { margin: 2px 0; }
.disclaimer { color: var(--muted); font-size: 8pt; }

/* ------------------------------------------------------------------ каталог */

.catalog-ctrl { overflow: hidden; }
.cat-search { float: right; width: 200px; }
.catalog { list-style: none; margin: 0; padding: 0; text-align: center; }
.cat-item {
  display: inline-block; vertical-align: top; width: 165px; max-height: 330px; overflow: hidden;
  margin: 6px 4px; font-size: 9pt; text-align: center;
}
.cat-link { display: inline-block; line-height: 0; text-decoration: none; }
.cat-link img { max-width: 150px; max-height: 150px; width: auto; height: auto; box-shadow: 0 0 4px rgba(0, 0, 0, .35); }
.cat-nofile {
  display: inline-block; padding: 30px 10px; min-width: 100px; line-height: 1.2; font-weight: bold;
  color: var(--muted); background: var(--post-bg); border: 1px solid var(--post-border);
}
.cat-meta { margin: 3px 0 1px; font-size: 8pt; }
.cat-text { overflow-wrap: anywhere; }

/* ------------------------------------------------------------------ главная и коробки */

.frontpage { max-width: 760px; margin: 0 auto; }
.frontpage.narrow { max-width: 420px; }
.fp-head { text-align: center; margin: 10px 0 8px; }
.fp-logo { margin: 0; line-height: 0; }
.fp-head img, .logo-img { max-width: min(380px, 100%); max-height: 150px; width: auto; height: auto; }
.tagline { margin: 6px 0 0; font-style: italic; font-size: 10pt; }
.box { margin: 0 0 10px; border: 1px solid var(--box-border); background: var(--box-bg); }
.boxbar {
  margin: 0; padding: 3px 7px; font: bold 11pt arial, helvetica, sans-serif;
  color: var(--boxbar-text); background: var(--boxbar-bg); border-bottom: 1px solid var(--box-border);
}
.boxcontent { padding: 6px 10px 8px; }
.boxcontent p { margin: 4px 0; line-height: 1.45; }
.fp-boards { columns: 2; column-gap: 20px; margin: 0; padding: 0; list-style: none; }
.fp-boards li { break-inside: avoid; margin: 0 0 8px; }
.fp-board { font-weight: bold; }
.fp-bid { color: var(--muted); }
.fp-busy { color: var(--capcode); font-weight: bold; font-size: 9pt; }
.fp-desc { display: block; font-size: 9pt; color: var(--muted); }
.fp-threads {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px 10px; text-align: center;
}
.fp-tboard { font-weight: bold; margin-bottom: 3px; }
.fp-tlink { display: inline-block; line-height: 0; text-decoration: none; }
.fp-tlink img { max-width: 150px; max-height: 150px; width: auto; height: auto; }
.fp-ttext { margin: 3px 0 0; font-size: 9pt; overflow-wrap: anywhere; }
.fp-stats { display: flex; flex-wrap: wrap; gap: 4px 24px; }
.rules-list { margin: 4px 0; padding-left: 22px; }
.rules-list li { margin: 4px 0; line-height: 1.45; }
.sign-off { text-align: right; font-style: italic; color: var(--muted); }
.faq dt { font-weight: bold; margin-top: 8px; }
.faq dd { margin: 2px 0 0 0; line-height: 1.45; }

/* ------------------------------------------------------------------ ошибки, бан, сообщения */

.errbox { text-align: center; margin: 20px 0; }
.errmsg { color: #ff0000; font-size: 16pt; margin: 10px 0; }
.errmsg.small { font-size: 10pt; text-align: left; margin: 6px 0 0; }
.okmsg { color: var(--title); font-size: 16pt; margin: 10px 0; }
.err-links { margin: 8px 0; }
.banned .boxbar { color: #ff0000; }
.ban-facts th { text-align: left; padding: 2px 10px 2px 0; vertical-align: top; }
.ban-facts td { padding: 2px 0; overflow-wrap: anywhere; }

/* ------------------------------------------------------------------ сантехническая */

.mod-login { display: grid; gap: 6px; }
.mod-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.mod-head .board-title { text-align: left; }
.mod-h { font-size: 13pt; margin: 6px 0; color: var(--title); }
.mod-item { margin: 6px 0 10px; }
.mod-where { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin: 0 0 2px; }
.mod-reasons { color: var(--capcode); }
.mod-item .post.reply { margin-left: 0; }
.mod-item .post.reply::before { content: none; }
.mt { clear: both; margin: 2px 0 2px 20px; font-size: 9pt; }
.mt summary { cursor: pointer; color: var(--capcode); font-weight: bold; }
.mt-body { display: grid; gap: 4px; margin: 3px 0; padding: 4px 6px; border: 1px dashed var(--post-border); background: var(--bg); }
.mt-row { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin: 0; }
.mt-ip { color: var(--muted); }
.mod-ok { color: var(--name); font-weight: bold; }
.mod-banners { list-style: none; margin: 4px 0 8px; padding: 0; display: flex; flex-wrap: wrap; gap: 10px 14px; }
.mod-banners li { display: flex; flex-direction: column; align-items: flex-start; gap: 3px; }
.mod-banners img { display: block; max-width: 300px; max-height: 100px; border: 1px solid var(--hr); }
.mod-banner-form { margin: 4px 0; }
.mod-site-form { margin: 4px 0 8px; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; }
.mod-site-form input[type=text] { width: min(300px, 100%); }
.mod-sub { margin: 6px 0 3px; font-weight: bold; }
.mod-logo-preview { display: block; max-width: min(380px, 100%); max-height: 150px; width: auto; height: auto; border: 1px dashed var(--hr); }
.ban-table { border-collapse: collapse; width: 100%; }
.ban-table th, .ban-table td { border: 1px solid var(--post-border); padding: 3px 6px; text-align: left; vertical-align: top; }
.ban-table th { background: var(--label-bg); color: var(--label-text); }

/* ------------------------------------------------------------------ узкие экраны */

@media (max-width: 720px) {
  body { padding: 0 5px; font-size: 10.5pt; }
  .bl-right { float: none; display: block; margin-top: 3px; }
  .board-title { font-size: 22px; letter-spacing: -1px; }
  .banner { max-width: min(300px, 100%); }
  .posting-mode { min-width: 0; width: auto; }
  .postform { width: 100%; }
  .pf-table, .pf-table tbody, .pf-table tr, .pf-table th, .pf-table td { display: block; width: 100%; box-sizing: border-box; }
  .pf-table th { padding: 1px 5px; }
  .pf-table td { margin-bottom: 3px; }
  .pf-table input[type="text"], .pf-table input[type="password"], .pf-table textarea { width: 100%; }
  .row-submit { display: flex !important; gap: 3px; }
  .row-submit input { flex: 1; min-width: 0; }
  .pf-table .cap-in { width: 100%; }
  .rules { width: 100%; }
  .pf-wrap.qr { margin-left: 0; }
  .post.reply { width: 100%; max-width: 100%; margin-left: 0; }
  .post.reply::before { content: none; }
  .omitted { margin-left: 0; }
  .pb { margin: .7em 8px .7em 12px; }
  .post.reply .pb { margin: .7em 6px .7em 8px; }
  .thumb-link { margin: 3px 10px 5px 4px; }
  .thumb { max-width: 38vw; height: auto; }
  .file-text { margin-left: 4px; overflow-wrap: anywhere; }
  .file .full { max-width: 100%; margin: 3px 0 5px; }
  .delform { float: none; text-align: left; }
  .pagelist { display: block; }
  .pagelist > div { display: inline-block; margin: 2px 0; }
  .fp-boards { columns: 1; }
  .cat-search { float: none; display: block; width: 100%; margin-top: 4px; box-sizing: border-box; }
  .cat-item { width: 46%; }
}

@media (prefers-reduced-motion: reduce) {
  .post.fresh-in { animation: none; }
}

@media print {
  .boardlist, .pf-wrap, .posting-mode, .pm, .bottom-ctrl, .pagelist, .navlinks { display: none; }
}
