body {
    background: #222;
    color: #c5c8c6;
    font-family: arial, helvetica, sans-serif;
    font-size: 14px;
    margin: 1em;
}

a {
    color: #6699cc;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.board-title {
    text-align: center;
    margin-bottom: 1em;
}

.board-title h1 {
    color: #ffa07a;
    font-size: 1.6em;
    margin: 0.2em 0;
}

.new-thread table {
    margin: 0.5em 0;
}

.new-thread td {
    padding: 2px 6px;
    vertical-align: top;
}

.new-thread input[type="text"],
.new-thread textarea {
    background: #2d2c2b;
    color: #c5c8c6;
    border: 1px solid #444;
    padding: 2px 4px;
}

.thread {
    margin-bottom: 1em;
    overflow: hidden;
}

.post.op {
    padding: 0.5em;
    overflow: hidden;
}

.post-info,
.reply-header {
    font-size: 0.95em;
    margin-bottom: 0.3em;
}

.post-info .name,
.reply-header .name {
    color: #95e454;
}

.post-info .date,
.reply-header .date {
    color: #aaa;
}

.subject {
    color: #ebd667;
    font-size: 1.2em;
    margin-bottom: 0.3em;
}

.post-message {
    margin: 0.3em 0 0.3em 2em;
    padding: 0;
}

.post-message .body {
    padding: 10px 10px !important;
}

.replies {
    clear: both;
    margin-top: 0.3em;
}

.reply {
    background: #2d2c2b;
    padding: 0.5em;
    margin: 0.3em 0 0.3em 2em;
    border-left: 2px solid #444;
    overflow: hidden;
}

.reply .body {
    padding: 10px 10px !important;
}

.thread-image {
    float: left;
    margin: 0 1em 0.5em 0;
}

.thread-image-name {
    font-size: 0.85em;
    color: #aaa;
    margin-bottom: 2px;
}

.thread-image img.post-img {
    max-width: 250px;
    max-height: 250px;
    display: block;
    border: 1px solid #333;
    cursor: pointer;
}

.reply .thread-image img.post-img {
    max-width: 125px;
    max-height: 125px;
}

.thread-image img.post-img.expanded,
.reply .thread-image img.post-img.expanded {
    max-width: 100%;
    max-height: none;
}

.greentext {
    color: #789922;
}

.reply-link {
    color: #6699cc;
}

.reply-link:hover {
    color: #ffa07a;
}

.reply-box {
    background: #2d2c2b;
    border: 1px solid #444;
    padding: 0.5em;
    margin: 0.3em 0;
    max-width: 500px;
}

.reply-box textarea,
.reply-box input[type="text"] {
    background: #1d1f21;
    color: #c5c8c6;
    border: 1px solid #444;
    padding: 2px 4px;
    width: 100%;
    box-sizing: border-box;
}

.reply-title {
    margin-bottom: 0.3em;
    color: #aaa;
}

hr {
    border: none;
    border-top: 1px solid #444;
    margin: 1em 0;
}

.empty {
    color: #888;
    text-align: center;
    padding: 2em;
}

.delete-form {
    display: inline;
    margin: 0;
    padding: 0;
}

.delete-btn {
    background: transparent;
    color: #888;
    border: 1px solid transparent;
    font-size: 1.1em;
    line-height: 1;
    padding: 0 4px;
    margin-left: 0.4em;
    cursor: pointer;
    border-radius: 3px;
    vertical-align: baseline;
}

.delete-btn:hover {
    color: #ff6b6b;
    border-color: #ff6b6b;
    background: rgba(255, 107, 107, 0.08);
}

.delete-btn-armed,
.delete-btn-armed:hover {
    color: #fff;
    background: #c0392b;
    border-color: #e74c3c;
    font-size: 0.85em;
    padding: 1px 6px;
    font-weight: bold;
}

.post.op:target {
    background: #3a3540;
    outline: 1px solid #ffa07a;
}

.reply:target {
    background: #3a3540;
    border-left-color: #ffa07a;
    outline: 1px solid #ffa07a;
}

.post.op.cite-hover {
    background: #444038;
    outline: 1px solid #95e454;
}

.reply.cite-hover {
    background: #444038;
    border-left-color: #95e454;
    outline: 1px solid #95e454;
}

.post.op:target.cite-hover {
    background: #3a3540;
    outline: 1px solid #ffa07a;
}

.reply:target.cite-hover {
    background: #3a3540;
    border-left-color: #ffa07a;
    outline: 1px solid #ffa07a;
}

.board-nav {
    text-align: center;
    margin: 0.5em 0;
    font-size: 0.9em;
}

.catalog {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
    padding: 12px;
}

.catalog-tile {
    display: block;
    text-decoration: none;
    color: inherit;
    background: #302c29;
    padding: 6px;
    text-align: center;
    overflow: hidden;
    max-height: 360px;
}

.catalog-tile:hover {
    /*background: #4f4239;*/
}

.catalog-thumb {
    display: block;
    margin: 0 auto 6px;
    max-width: 100%;
    max-height: 180px;
    object-fit: contain;
}

.catalog-meta {
    color: #aaa;
    margin-bottom: 4px;
}

.catalog-subject {
    font-weight: bold;
    margin-bottom: 4px;
    word-wrap: break-word;
}

.catalog-body {
    line-height: 1.3;
    word-wrap: break-word;
    display: -webkit-box;
    -webkit-line-clamp: 8;
    -webkit-box-orient: vertical;
    overflow: hidden;
}