/* Community Message Board */
:root {
  --ink: #1f2933; --muted: #5d6b76; --line: #dde4e9; --paper: #fff; --bg: #f4f6f8;
  --accent: #2c6e8f; --accent-dark: #1d5069; --accent-soft: #e3f0f6; --gold: #8b5a14; --warn-bg: #fdf3df; --warn: #7a5200;
  --field: #75848e;   /* form and control borders: at least 3:1 against white (WCAG 1.4.11) */
  --focus: #b35c00;
  --radius: 12px;
}
* { box-sizing: border-box; }
body { margin: 0; font-family: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; color: var(--ink); background: var(--bg); line-height: 1.55; -webkit-font-smoothing: antialiased; }
/* Links in text are underlined, so they don't rely on colour alone (WCAG 1.4.1) */
a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.nav a, .btn, .brand, .board-card, .post-card, .thread-row, .alert-row, .board-name, a.badge, .person .grow a, .by a { text-decoration: none; }
.board-card:hover strong, .post-card:hover .title, .thread-row:hover strong, .person .grow a:hover, .by a:hover { text-decoration: underline; }
/* A clear keyboard focus ring everywhere (WCAG 2.4.7) */
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.site-header :focus-visible { outline-color: #fff; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 8px; top: -60px; background: #fff; color: var(--accent-dark); padding: 8px 14px; border-radius: 8px; z-index: 50; font-weight: 600; }
.skip:focus { top: 8px; }
fieldset { border: 0; padding: 0; margin: 0 0 15px; min-width: 0; } legend { font-weight: 600; font-size: .9rem; margin-bottom: 5px; padding: 0; }
.table-wrap { overflow-x: auto; }
img { max-width: 100%; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }
.site-header { background: var(--accent-dark); color: #fff; }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 58px; flex-wrap: wrap; }
.brand { color: #fff; font-weight: 700; font-size: 1.08rem; } .brand:hover { text-decoration: none; }
.nav { display: flex; gap: 2px; flex-wrap: wrap; align-items: center; }
.nav a { color: rgba(255,255,255,.9); padding: 7px 10px; border-radius: 8px; font-size: .92rem; font-weight: 500; }
.nav a:hover, .nav a.active { background: rgba(255,255,255,.15); text-decoration: none; }
.nav a.cta { background: var(--gold); color: #fff; font-weight: 600; }
.board-bar { background: #fff; border-bottom: 1px solid var(--line); }
.board-bar .bar { min-height: 50px; }
.board-name { font-weight: 700; color: var(--ink); display: flex; align-items: center; gap: 8px; }
.nav.sub a { color: var(--muted); } .nav.sub a:hover, .nav.sub a.active { background: var(--accent-soft); color: var(--accent-dark); }
.pill { display: inline-block; background: var(--gold); color: #fff; border-radius: 999px; padding: 0 7px; font-size: .75rem; margin-left: 3px; font-weight: 600; }
main.wrap { padding-top: 22px; padding-bottom: 48px; }
h1 { font-size: 1.7rem; margin: 0 0 10px; line-height: 1.2; } h2 { font-size: 1.22rem; margin: 0 0 12px; } h3 { font-size: 1.05rem; margin: 14px 0 6px; }
.tight { margin-top: 0; margin-bottom: 4px; } .spaced { margin-top: 28px; }
.muted { color: var(--muted); } .small { font-size: .87rem; } .center { text-align: center; } .nowrap { white-space: nowrap; }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; margin-bottom: 16px; }
.card.narrow { max-width: 560px; margin-left: auto; margin-right: auto; }
.grid { display: grid; gap: 16px; } .grid.two { grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); } .grid.three { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.grid.tight { gap: 0 16px; }
.row { display: flex; align-items: center; } .row.gap { gap: 10px; flex-wrap: wrap; } .row.between { justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.wrap-gap { flex-wrap: wrap; gap: 10px; margin-bottom: 14px; } .grow { flex: 1; min-width: 0; }
.flash { background: var(--accent-soft); border: 1px solid #b8d8e6; color: var(--accent-dark); border-radius: 10px; padding: 11px 15px; margin-bottom: 16px; font-weight: 500; }
.flash.error, .alert.error { background: #fbe7e4; color: #8a2c1f; border: 1px solid #f0bdb4; }
.alert { padding: 11px 15px; border-radius: 10px; margin-bottom: 16px; font-weight: 500; }
.alert.success { background: #e5f6e9; color: #1e6b34; border: 1px solid #b9e3c4; }
.alert.warn { background: var(--warn-bg); color: var(--warn); border: 1px solid #f0d9a8; }
.btn { display: inline-block; background: var(--accent); color: #fff; border: 2px solid var(--accent); padding: 8px 17px; border-radius: 999px; font-weight: 600; font-size: .93rem; cursor: pointer; font-family: inherit; line-height: 1.3; }
.btn:hover { background: var(--accent-dark); border-color: var(--accent-dark); text-decoration: none; }
.btn.outline { background: transparent; color: var(--accent); } .btn.outline:hover { background: var(--accent-soft); }
.btn.outline.light { color: #fff; border-color: rgba(255,255,255,.7); } .btn.outline.light:hover { background: rgba(255,255,255,.12); }
.btn.small { padding: 4px 12px; font-size: .84rem; min-height: 28px; } .btn.wide { width: 100%; }
.btn.danger { background: #a33; border-color: #a33; } .danger-text { color: #a33 !important; border-color: #e3b5b5 !important; }
.btn:disabled { opacity: .55; cursor: default; }
button.link { background: none; border: 0; padding: 2px 0; min-height: 24px; color: var(--accent); cursor: pointer; font: inherit; text-decoration: underline; text-underline-offset: 2px; }
form { margin: 0; }
.field { margin-bottom: 15px; } .field > label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: 5px; }
input[type=text], input[type=email], input[type=search], input[type=datetime-local], select, textarea { width: 100%; padding: 9px 11px; border: 1px solid var(--field); border-radius: 8px; font: inherit; background: #fff; color: var(--ink); }
input[type=search] { width: auto; min-width: 180px; } .filters select { width: auto; }
textarea { min-height: 90px; resize: vertical; } .hint { color: var(--muted); font-size: .84rem; margin: 5px 0 0; }
.color-pick { display: inline-flex; gap: 8px; align-items: center; font-weight: 400; } .color-pick input { width: 44px; height: 32px; padding: 0 2px; border: 1px solid var(--field); border-radius: 6px; background: #fff; cursor: pointer; }
label.check { display: flex; gap: 8px; align-items: baseline; font-weight: 400; margin: 4px 0; font-size: .94rem; } label.check input { width: auto; }
.prefix-input { display: flex; align-items: center; border: 1px solid var(--field); border-radius: 8px; overflow: hidden; background: #fff; }
.prefix-input span { padding: 9px 4px 9px 11px; color: var(--muted); background: #f1f4f6; white-space: nowrap; } .prefix-input input { border: 0; border-radius: 0; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.badge { display: inline-block; padding: 1px 9px; border-radius: 999px; font-size: .76rem; font-weight: 600; background: var(--accent-soft); color: var(--accent-dark); vertical-align: middle; }
.badge.warn { background: var(--warn-bg); color: var(--warn); } .badge.off { background: #eceff1; color: #5f6b73; }
.badge.hot { background: #b3261e; color: #fff; } .hot-card { border-color: #e7a19b; background: #fffaf9; }
.badge.public { background: #e6f4ea; color: #1e6b34; } .badge.private { background: #eef0f6; color: #4a5378; }
a.badge:hover { text-decoration: none; filter: brightness(.96); }
.avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; flex: none; vertical-align: middle; font-size: .95rem; }
.avatar.small { width: 32px; height: 32px; font-size: .78rem; } .avatar.tiny { width: 22px; height: 22px; font-size: .62rem; } .avatar.large { width: 96px; height: 96px; font-size: 1.8rem; }
.clout { display: inline-block; vertical-align: middle; font-size: .95em; } .clout span { font-size: .8rem; font-weight: 600; color: var(--muted); }
.board-photo { width: 56px; height: 56px; border-radius: 12px; object-fit: cover; flex: none; background: var(--accent-soft); display: inline-flex; align-items: center; justify-content: center; font-size: 1.6rem; }
.board-photo.small { width: 30px; height: 30px; border-radius: 7px; font-size: 1rem; } .board-photo.large { width: 120px; height: 120px; border-radius: 16px; font-size: 3rem; }
.board-photo.flyer { width: 100%; max-width: 420px; height: auto; max-height: 260px; border-radius: 16px; font-size: 5rem; aspect-ratio: auto; }
.board-photo.flyer.none { height: 140px; }
/* Home: boards */
.boards { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.board-card { display: flex; gap: 14px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; color: var(--ink); }
.board-card:hover { text-decoration: none; border-color: var(--accent); }
.board-card .body { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.hero { background: linear-gradient(135deg, var(--accent-dark), var(--accent)); color: #fff; border-radius: var(--radius); padding: 38px 28px; margin-bottom: 20px; }
.hero h1 { font-size: 2.1rem; } .hero p { font-size: 1.06rem; max-width: 42em; } .hero .btn:not(.outline) { background: var(--gold); border-color: var(--gold); }
/* Board */
.board-head { display: flex; gap: 20px; align-items: flex-start; } .board-head .body { flex: 1; min-width: 0; } .board-head .desc { margin: 6px 0 10px; }
.share code { background: #f1f4f6; padding: 2px 6px; border-radius: 5px; font-size: .84rem; word-break: break-all; }
.join { border-color: var(--accent); background: #f8fcfe; }
.posts { display: flex; flex-direction: column; gap: 10px; }
.post-card { display: flex; gap: 14px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; color: var(--ink); }
.post-card:hover { text-decoration: none; border-color: var(--accent); }
.post-card.pinned { border-left: 4px solid var(--gold); } .post-card.closed { background: #f7f8f9; }
.post-card .thumb { width: 96px; height: 96px; border-radius: 10px; object-fit: cover; flex: none; }
.post-card .body { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.post-card .title { font-size: 1.04rem; } .post-card .snippet { color: #3c4851; font-size: .93rem; overflow-wrap: anywhere; }
.meta { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin: 0 0 4px; } .kind span[aria-hidden] { margin-right: 3px; } .kind { font-size: .8rem; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; }
.price { color: #1e6b34; font-weight: 700; font-size: .95em; margin-left: 4px; white-space: nowrap; }
.biz { margin: 4px 0 10px; } .biz-badge { background: #fdf3df; color: #6e4a00; } .market .biz-name { font-weight: 700; font-size: .9rem; }
.event-when { color: var(--accent-dark); }
.by { display: flex; gap: 8px; align-items: center; } .by a { color: var(--ink); }
.pager { display: flex; gap: 10px; align-items: center; justify-content: center; margin-top: 16px; }
/* Board home: cards of posts */
.view-tabs { margin: 4px 0 14px; }
.board-cards { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); align-items: start; }
.board-cards .wide { grid-column: 1 / -1; } .mini-card { margin-bottom: 0; } .mini-card h2 { font-size: 1.08rem; }
.mini { list-style: none; margin: 10px 0 0; padding: 0; } .mini li { border-top: 1px solid var(--line); } .mini li:first-child { border-top: 0; }
.mini a { display: flex; gap: 10px; align-items: center; padding: 9px 0; color: var(--ink); text-decoration: none; min-height: 44px; }
.mini a:hover .title { text-decoration: underline; } .mini .body { display: flex; flex-direction: column; gap: 1px; min-width: 0; flex: 1; }
.mini .title { font-weight: 600; overflow-wrap: anywhere; } .mini img, .mini .noimg { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; flex: none; }
.mini .noimg { display: flex; align-items: center; justify-content: center; background: var(--accent-soft); font-size: 1.2rem; }
.mini .price { margin-left: 0; font-size: .9rem; } .list-title { margin-top: 4px; }
/* Marketplace */
.tabs { display: flex; gap: 4px; flex-wrap: wrap; } .tabs a { padding: 5px 12px; border-radius: 999px; border: 1px solid var(--field); text-decoration: none; color: var(--ink); font-size: .9rem; min-height: 28px; }
.tabs a span[aria-hidden] { margin-right: 4px; }
.tabs a[aria-current="page"] { background: var(--accent); color: #fff; border-color: var(--accent); }
.market { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }
.market .item { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; color: var(--ink); text-decoration: none; }
.market .item:hover { border-color: var(--accent); } .market .item:hover .title { text-decoration: underline; }
.market .item img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; display: block; background: #f1f4f6; }
.market .noimg { width: 100%; aspect-ratio: 1 / 1; display: flex; align-items: center; justify-content: center; background: var(--accent-soft); font-size: 2.6rem; }
.market .body { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 3px; } .market .price { margin-left: 0; } .market .item.closed { background: #f7f8f9; }
@media (max-width: 420px) { .market { grid-template-columns: repeat(2, 1fr); gap: 8px; } }
/* Post */
.post h1 { font-size: 1.55rem; margin-top: 4px; } .post .text, .reply .text { overflow-wrap: anywhere; margin: 10px 0; }
.gallery { display: grid; gap: 8px; margin: 12px 0; grid-template-columns: repeat(2, 1fr); } .gallery.n1 { grid-template-columns: 1fr; max-width: 640px; }
.gallery img { width: 100%; height: 100%; max-height: 420px; object-fit: cover; border-radius: 10px; display: block; } .gallery.n1 img { object-fit: contain; background: #f1f4f6; }
.gallery:not(.n1):not(.small) img { aspect-ratio: 4 / 3; height: auto; }
.gallery.small { grid-template-columns: repeat(auto-fill, minmax(110px, 140px)); } .gallery.small img { height: 110px; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 12px; }
.votes { display: inline-flex; gap: 4px; align-items: center; }
.vote { background: #f1f4f6; border: 1px solid var(--field); border-radius: 999px; padding: 3px 10px; min-height: 28px; font: inherit; font-size: .88rem; cursor: pointer; color: var(--ink); }
span.vote { cursor: default; } button.vote:hover { border-color: var(--accent); } .vote.on { background: var(--accent-soft); border-color: var(--accent); font-weight: 600; }
.mod-box { margin-top: 14px; padding: 12px; background: #fbf7ee; border: 1px dashed #e2cfa2; border-radius: 10px; display: flex; flex-direction: column; gap: 8px; }
.reply { padding: 14px 16px; } .reply.removed { background: #f8f8f8; border-style: dashed; } .reply .actions { margin-top: 6px; }
.reply-form textarea { margin: 6px 0 8px; } .add-photos { margin-bottom: 10px; }
details.report summary, details.add-photos summary { list-style: none; cursor: pointer; display: inline; } details.report summary::-webkit-details-marker, details.add-photos summary::-webkit-details-marker { display: none; }
details.report form { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; } details.report input { flex: 1; min-width: 200px; } details.report.inline { display: inline; }
.photo-preview, .thumbs, .photo-edit { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0; }
.photo-preview img, .thumbs img { width: 84px; height: 84px; object-fit: cover; border-radius: 8px; }
.photo-edit label { display: flex; flex-direction: column; gap: 4px; font-size: .84rem; } .photo-edit img { width: 110px; height: 110px; object-fit: cover; border-radius: 8px; }
.kinds { display: flex; flex-wrap: wrap; gap: 6px; } .kind-opt input { position: absolute; opacity: 0; }
.kind-opt span { display: inline-block; padding: 6px 12px; border: 1px solid var(--field); border-radius: 999px; cursor: pointer; font-size: .9rem; background: #fff; }
.kind-opt input:checked + span { background: var(--accent); color: #fff; border-color: var(--accent); } .kind-opt input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
/* Members, moderation, lists */
.person { display: flex; gap: 12px; align-items: center; padding: 11px 0; border-top: 1px solid var(--line); flex-wrap: wrap; } .person:first-of-type { border-top: 0; }
.person .grow a { color: var(--ink); } .answer { margin: 4px 0 0; background: #f6f8f9; padding: 6px 9px; border-radius: 7px; }
.person select { width: auto; }
.mod-item { padding: 14px 0; border-top: 1px solid var(--line); } .mod-item:first-of-type { border-top: 0; padding-top: 0; }
blockquote { margin: 8px 0; padding: 8px 12px; background: #f6f8f9; border-left: 3px solid var(--gold); border-radius: 4px; font-size: .92rem; }
.list { padding: 6px 0; } .thread-row, .alert-row { display: flex; gap: 12px; align-items: center; padding: 11px 18px; color: var(--ink); border-top: 1px solid var(--line); }
.thread-row:first-child, .alert-row:first-child { border-top: 0; } .thread-row:hover, .alert-row:hover { background: #f8fafb; text-decoration: none; }
.thread-row.unread, .alert-row.unread { background: #f3f9fc; font-weight: 600; } .alert-row .icon { font-size: 1.3rem; }
.thread { display: flex; flex-direction: column; gap: 12px; } .msg { max-width: 82%; } .msg.me { align-self: flex-end; text-align: right; } .msg.them { align-self: flex-start; }
.msg .bubble { display: inline-block; text-align: left; padding: 9px 13px; border-radius: 14px; background: #eef2f5; overflow-wrap: anywhere; }
.msg.me .bubble { background: var(--accent); color: #fff; } .msg.me .bubble a { color: #fff; text-decoration: underline; }
.msg .meta, .msg .about { font-size: .76rem; color: var(--muted); margin: 3px 0 0; display: block; }
table { width: 100%; border-collapse: collapse; } th, td { text-align: left; padding: 8px 9px; border-bottom: 1px solid var(--line); vertical-align: top; font-size: .92rem; }
th { color: var(--muted); font-size: .76rem; text-transform: uppercase; letter-spacing: .04em; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; margin-bottom: 14px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; } .stat strong { display: block; font-size: 1.5rem; } .stat span { color: var(--muted); font-size: .85rem; }
.profile-head { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; }
.ladder { margin: 0; padding-left: 22px; columns: 2; } .ladder li { margin: 3px 0; color: var(--muted); } .ladder li.past { color: var(--ink); } .ladder li.here { color: var(--accent-dark); font-weight: 700; }
.danger-zone summary { cursor: pointer; color: #a33; }
.site-footer { border-top: 1px solid var(--line); padding: 20px 0 34px; color: var(--muted); font-size: .88rem; }
.site-footer p { margin: 4px 0; }
/* Post history */
.history { list-style: none; padding: 0; margin: 0; } .history .card { margin-bottom: 12px; }
dl.diff { margin: 8px 0 0; } dl.diff dt { font-weight: 600; font-size: .88rem; margin-top: 8px; } dl.diff dd { margin: 2px 0 0; overflow-wrap: anywhere; }
dl.diff .text { margin: 4px 0; padding: 8px 10px; background: #f6f8f9; border-radius: 6px; }
/* QR flyer */
.flyer { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 34px 24px; text-align: center; max-width: 620px; margin: 18px auto; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.flyer-title { font-size: 2.1rem; margin: 14px 0 0; } .flyer-line { font-size: 1.1rem; color: var(--muted); margin: 0; }
.flyer-ask { font-size: 1.4rem; font-weight: 700; color: var(--accent-dark); margin: 16px 0 6px; } .qr { padding: 12px; background: #fff; } .qr img, .qr canvas { display: block; margin: 0 auto; }
.flyer-url { font-size: 1.15rem; font-weight: 700; margin: 8px 0 2px; letter-spacing: .01em; } .flyer-how { max-width: 30em; color: var(--muted); font-size: .95rem; margin: 6px 0 0; }
@media print {
  .site-header, .board-bar, .site-footer, .no-print, .flash, .alert { display: none !important; }
  body { background: #fff; } main.wrap { padding: 0; } .flyer { border: 0; margin: 0 auto; padding-top: 0; }
}
@media (max-width: 640px) {
  .board-head { flex-direction: column; } .board-photo.large { width: 84px; height: 84px; }
  .post-card .thumb { width: 72px; height: 72px; } .hero { padding: 26px 18px; } .hero h1 { font-size: 1.7rem; }
  .msg { max-width: 92%; } .ladder { columns: 1; } th, td { padding: 7px 5px; } .nav a { padding: 6px 8px; }
}
