/* bbs-mobile.css  */

html, body { margin: 0; }
body.bbs-m { padding: 0; }

/* ---------------------------------------------------------------- header */
.m-header {
    background: #ece9d8;
    border-bottom: 1px solid #808080;
    font-family: Tahoma, sans-serif;
    position: -webkit-sticky;
    position: sticky;
    top: 0;
    z-index: 100;
}
.m-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 8px;
    min-height: 34px;
}
.m-menu-btn {
    font-size: 18px;
    line-height: 1;
    color: #000080;
    cursor: pointer;
    padding: 4px 8px;
    border: 1px solid #808080;
    background: #f5f4ea;
    -webkit-user-select: none;
    user-select: none;
}
.m-brandwrap {
    flex: 1 1 auto;
    min-width: 0;
    text-align: center;
    line-height: 1.05;
}
.m-brand {
    display: block;
    font-size: 17px;
    font-weight: bold;
    color: #000080 !important;
    text-decoration: none !important;
}
.m-tagline {
    display: block;
    font-size: 9px;
    font-style: italic;
    color: #555;
    white-space: nowrap;
}
.m-desktop {
    font-size: 10px;
    color: #555 !important;
    border: 1px solid #808080;
    background: #f5f4ea;
    padding: 3px 6px;
    text-decoration: none !important;
    white-space: nowrap;
}

/* nav toggle */
.m-nav-cb { position: absolute; left: -9999px; }
.m-nav { display: none; border-top: 1px solid #808080; }
.m-nav-cb:checked ~ .m-header .m-nav { display: block; }
.m-nav a {
    display: block;
    padding: 10px 10px;
    font-size: 13px;
    color: #000080 !important;
    text-decoration: none !important;
    border-bottom: 1px solid #d8d5c4;
}
.m-nav a:active { background: #ffffff; }
.m-nav-alt { color: #555 !important; }

.m-stats {
    padding: 4px 8px;
    font-size: 10px;
    color: #444;
    border-top: 1px solid #d8d5c4;
}
.m-stat { margin-right: 10px; white-space: nowrap; }

/* ---------------------------------------------------------------- shell */
.m-content { padding: 6px 8px; }
.m-footer {
    text-align: center;
    font-size: 10px;
    color: #777;
    padding: 12px 8px 20px;
    border-top: 1px solid #ccc;
    margin-top: 10px;
}
.m-footer-sub { font-style: italic; margin-top: 2px; }

/* banners */
.global-message {
    margin: 6px 8px;
    padding: 8px 10px;
    font-size: 13px;
    border: 1px solid #c0c080;
    background: #ffffc0;
    color: #443;
}
.global-message.status-success { background: #e6ffe6; border-color: #4a4; color: #060; }
.global-message.status-error   { background: #ffe6e6; border-color: #c44; color: #900; }
.global-message.status-warning { background: #ffffc0; border-color: #c0c080; color: #650; }
.global-message.status-info    { background: #e6f0ff; border-color: #88b; color: #135; }
body.theme-dark .global-message { background: #302800; border-color: #806000; color: #e8c898; }
body.theme-dark .global-message.status-success { background: #0a2010; border-color: #2a6; color: #7d9; }
body.theme-dark .global-message.status-error   { background: #3a1010; border-color: #933; color: #f88; }
body.theme-dark .global-message.status-warning { background: #302800; border-color: #806000; color: #e8c898; }
body.theme-dark .global-message.status-info    { background: #0e1830; border-color: #46a; color: #9ac; }

.m-crumb { font-size: 11px; color: #555; margin: 2px 0 6px; }
.m-crumb a { color: #0000cc; }

/* ---- reflow ---- */
/* give me he fucking broccoli */
.bbs-m .thread-list { font-size: 13px; line-height: 1.5; }
.bbs-m .thread-list .tl-branch { display: none; }
.bbs-m .thread-list th, .bbs-m .thread-list td { padding: 3px 4px 3px 0; }
.bbs-m .tl-icons { width: 22px; }
.bbs-m .tl-date { width: 48px; }
.bbs-m .tl-r { width: 34px; }
.bbs-m .tl-by { width: 26%; }

/* board tree */
.bbs-m pre.tree { font-size: 13px; line-height: 1.7; white-space: pre-wrap; word-wrap: break-word; }

/* section titles */
.bbs-m .pane-title { font-size: 14px; margin: 6px 0 6px; }
.tl-pin  { color: #b8860b; font-size: 11px; }
.tl-lock { color: #990000; font-size: 11px; }

/* buttons + pager */
.bbs-m .m-page-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.bbs-m .m-page-title { font-size: 15px; margin: 4px 0; }
.button, .bbs-m button, .bbs-m input[type="submit"] {
    display: inline-block;
    border: 1px solid #808080;
    background: #ece9d8;
    color: #000 !important;
    padding: 7px 12px;
    font-size: 13px;
    text-decoration: none !important;
    cursor: pointer;
    line-height: 1.3;
}
.button:active, .bbs-m button:active { background: #fff; }
.pagination-container { margin: 8px 0; }
.pane-pages a.active { font-weight: bold; }
.page-indicator { font-size: 11px; color: #555; }

/* forms: 16px inputs stop itoddler zoom */
.bbs-m .post-form p, .bbs-m .form-card p { margin: 6px 0; }
.bbs-m input[type="text"], .bbs-m input[type="password"],
.bbs-m input[type="email"], .bbs-m select, .bbs-m textarea {
    width: 100%;
    font-size: 16px;
    padding: 8px;
    border: 1px solid #808080;
    background: #fff;
    font-family: Tahoma, sans-serif;
    box-sizing: border-box;
}
.bbs-m textarea { min-height: 130px; resize: vertical; }
.bbs-m input[type="file"] { font-size: 13px; }
.hp-field { display: none !important; position: absolute; left: -9999px; }
.content-page.status-warning { background: #ffffc0; border: 1px solid #c0c080; padding: 6px 8px; }

/* ---- dark chrome ---- */
body.theme-dark .m-header { background: #3e2414; border-bottom-color: #6b3818; }
body.theme-dark .m-menu-btn { background: #2a1608; border-color: #6b3818; color: #e8c898; }
body.theme-dark .m-brand { color: #e8c898 !important; }
body.theme-dark .m-tagline { color: #9a8272; }
body.theme-dark .m-desktop { background: #2a1608; border-color: #6b3818; color: #9a8272 !important; }
body.theme-dark .m-nav { border-top-color: #6b3818; }
body.theme-dark .m-nav a { color: #e8c898 !important; border-bottom-color: #3e2414; }
body.theme-dark .m-nav a:active { background: #6a4828; }
body.theme-dark .m-nav-alt { color: #9a8272 !important; }
body.theme-dark .m-stats { color: #9a8272; border-top-color: #3e2414; }
body.theme-dark .m-footer { color: #6a4828; border-top-color: #3e2414; }
body.theme-dark .m-crumb { color: #9a8272; }
body.theme-dark .m-crumb a { color: #e8c898; }
body.theme-dark .button, body.theme-dark.bbs-m button, body.theme-dark.bbs-m input[type="submit"] {
    background: #3e2414; border-color: #6b3818; color: #e8c898 !important;
}
body.theme-dark.bbs-m input[type="text"], body.theme-dark.bbs-m input[type="password"],
body.theme-dark.bbs-m input[type="email"], body.theme-dark.bbs-m select, body.theme-dark.bbs-m textarea {
    background: #2a1608; border-color: #6b3818; color: #f0dfc0;
}
body.theme-dark .tl-lock { color: #f0a0a0; }
body.theme-dark .content-page.status-warning { background: #302800; border-color: #806000; color: #e8c898; }
body.theme-dark .page-indicator { color: #9a8272; }

/* ---- chat + mod chrome (NOT in pane css) ---- */
.chat-active-bar { font-size: 11px; color: #555; margin: 0 0 4px; }
.chat-log {
    margin-bottom: 6px;
    border: 1px solid #808080;
    background: #ffffff;
    padding: 4px 6px;
    max-height: 60vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}
.chat-form-row { display: flex; gap: 4px; align-items: center; flex-wrap: wrap; }
.chat-handle-input { flex: 0 0 90px; width: 90px; font-size: 16px; padding: 6px; border: 1px solid #808080; }
.chat-msg-input { flex: 1 1 auto; min-width: 0; font-size: 16px; padding: 6px; border: 1px solid #808080; }
.chat-send-bar {
    position: sticky; bottom: 0;
    background: #ece9d8; border-top: 1px solid #808080;
    padding: 6px; margin: 8px -8px -8px;
}
/* 4chan panes which have theirown padding */
body.bbs-m.pane-list, body.bbs-m.pane-post { padding: 8px 10px; }
body.bbs-m.pane-list .m-header, body.bbs-m.pane-post .m-header { margin: -8px -10px 8px; }

.chat-modf { display: inline; margin: 0 0 0 2px; }
.bbs-m .wchat-mod-toolbar { padding: 5px 6px; margin-bottom: 6px; }
.bbs-m .chat-del { font-size: 11px; padding: 3px 7px; line-height: 1.3; margin-left: 3px; }
.mod-nav-list { list-style: none; margin: 0 0 10px; padding: 0; }
.mod-nav-list li { border-bottom: 1px solid #d8d5c4; }
.mod-nav-list li a { display: block; padding: 11px 6px; color: #000080; font-size: 14px; text-decoration: none; }
.mod-nav-list li a:active { background: #eef; }

body.theme-dark .chat-log { background: #241206; border-color: #6b3818; }
body.theme-dark .chat-active-bar { color: #9a8272; }
body.theme-dark .chat-handle-input, body.theme-dark .chat-msg-input { background: #2a1608; border-color: #6b3818; color: #f0dfc0; }
body.theme-dark .chat-send-bar { background: #3e2414; border-top-color: #6b3818; }
body.theme-dark .mod-nav-list li { border-bottom-color: #3e2414; }
body.theme-dark .mod-nav-list li a { color: #e8c898; }
body.theme-dark .mod-nav-list li a:active { background: #3e2414; }

/* ---- connect/donate/mod/auth boxes (also NOT in pane css) ---- */
.card, .content-box, .form-card {
    border: 1px solid #c0c0b8;
    background: #fbfbf8;
    padding: 10px;
    margin-bottom: 10px;
}
.card.status-error   { background: #ffe6e6; border-color: #c44; }
.card.status-warning { background: #ffffc0; border-color: #c0c080; }
.card.status-info    { background: #e6f0ff; border-color: #88b; }
.card.status-success { background: #e6ffe6; border-color: #4a4; }
.form-group { margin-bottom: 12px; }
.form-group > label { display: block; font-size: 13px; font-weight: bold; margin-bottom: 4px; }
.small-text { font-size: 12px; color: #555; }
.mt-0 { margin-top: 0; }
.divider { border: 0; border-top: 1px solid #d8d5c4; margin: 8px 0; }
.section-divider { padding: 4px 0; font-size: 12px; color: #555; }
body.theme-dark .section-divider { color: #9a8272; }
.data-table-wrapper { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.data-table th, .data-table td { border: 1px solid #c0c0b8; padding: 5px 7px; text-align: left; }
.data-table th { background: #ece9d8; font-weight: bold; }
.ban-banner { background: #ffe6e6; border: 1px solid #c44; color: #900; padding: 8px 10px; margin-bottom: 10px; }
.stealth-warning { background: #ffffc0; border: 1px solid #c0c080; color: #650; padding: 8px 10px; margin-bottom: 10px; }

body.theme-dark .card, body.theme-dark .content-box, body.theme-dark .form-card {
    background: #241206; border-color: #6b3818;
}
body.theme-dark .card.status-error   { background: #3a1010; border-color: #933; }
body.theme-dark .card.status-warning { background: #302800; border-color: #806000; }
body.theme-dark .card.status-info    { background: #0e1830; border-color: #46a; }
body.theme-dark .card.status-success { background: #0a2010; border-color: #2a6; }
body.theme-dark .small-text { color: #9a8272; }
body.theme-dark .divider { border-top-color: #3e2414; }
body.theme-dark .data-table th { background: #3e2414; }
body.theme-dark .data-table th, body.theme-dark .data-table td { border-color: #6b3818; }
body.theme-dark .ban-banner { background: #3a1010; border-color: #933; color: #f88; }
body.theme-dark .stealth-warning { background: #302800; border-color: #806000; color: #e8c898; }
