/* Hiraeth community forum. Shares the landing page's colours and type. */
:root {
  --ground: #f4f6fa; --surface: #fff; --tint: #eef4fe; --tint-2: #d2e3fc;
  --ink: #202124; --muted: #5f6368; --accent: #1a73e8; --accent-dark: #1558b0; --accent-lite: #8ab4f8;
  --night: #0a1a33; --night-2: #12305c; --line: #dfe5ee; --danger: #b3261e;
  --m: clamp(20px, 4vw, 48px);
  --display: "Barlow Condensed", "Arial Narrow", system-ui, sans-serif;
  --text: "Barlow", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--ground); color: var(--ink); font: 400 1.0625rem/1.55 var(--text); -webkit-font-smoothing: antialiased; }
h1, h2, p, ul, ol { margin: 0; padding: 0; }
ul, ol { list-style: none; }
a { color: var(--accent-dark); }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
h1, h2, .t-n { font-family: var(--display); font-weight: 700; letter-spacing: -0.01em; line-height: 1; }

.fbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px var(--m); background: var(--night); color: #f4f6fa; }
.fbar a { color: inherit; text-decoration: none; }
.fbar .brand { display: inline-flex; align-items: center; gap: 10px; font: 700 1.5rem/1 var(--display); }
.fbar nav { display: flex; gap: clamp(14px, 2.4vw, 30px); font-size: .9rem; font-weight: 500; }
.fbar nav a:hover, .fbar nav a[aria-current] { text-decoration: underline; text-underline-offset: 6px; }

.fwrap { max-width: 920px; margin: 0 auto; padding: 0 var(--m) 72px; }
.fhero { margin: 0 calc(var(--m) * -1) 28px; padding: clamp(40px, 7vw, 80px) var(--m); background: var(--night); color: #f4f6fa; }
.fhero > * { max-width: 920px; margin-left: auto; margin-right: auto; }
.fhero h1 { font-size: clamp(2.4rem, 1.2rem + 5vw, 4.5rem); max-width: 16ch; margin-bottom: 18px; }
.eyebrow { font: 500 .8rem/1 var(--text); letter-spacing: .14em; text-transform: uppercase; color: var(--accent-lite); margin-bottom: 16px; }
.lead { max-width: 52ch; font-size: 1.25rem; line-height: 1.4; color: var(--tint-2); margin-bottom: 26px; }

.fbtn { display: inline-block; padding: 13px 22px; background: var(--accent); color: #fff; font: 500 1rem/1 var(--text); text-decoration: none; border: 0; border-radius: 0; cursor: pointer; transition: background .2s, transform .2s; }
.fbtn:hover { background: var(--accent-dark); transform: translateY(-2px); }
.fhero .fbtn:hover { background: #fff; color: var(--night); }
.fbtn.alt { background: var(--night); }
.fbtn.alt:hover { background: var(--night-2); }

.fsearch { display: flex; gap: 8px; margin-bottom: 16px; }
.fsearch input { flex: 1; min-width: 0; }
input, select, textarea { width: 100%; padding: 12px 14px; font: inherit; color: var(--ink); background: var(--surface); border: 1.5px solid var(--line); border-radius: 0; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(26,115,232,.2); }
textarea { resize: vertical; min-height: 120px; }

.cats { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.cats a { padding: 7px 14px; background: var(--surface); border: 1.5px solid var(--line); color: var(--ink); text-decoration: none; font-size: .9rem; font-weight: 500; }
.cats a:hover { border-color: var(--accent); }
.cats a[aria-current] { background: var(--night); border-color: var(--night); color: #fff; }
.count { color: var(--muted); margin-bottom: 14px; }
.empty { padding: 28px; background: var(--surface); border: 1.5px dashed var(--line); color: var(--muted); text-align: center; }

.threads { display: grid; gap: 10px; }
.thread { display: flex; justify-content: space-between; gap: 20px; padding: 18px 20px; background: var(--surface); border: 1.5px solid var(--line); transition: border-color .2s, transform .2s; }
.thread:hover { border-color: var(--accent-lite); transform: translateY(-1px); }
.thread.pinned { border-left: 5px solid var(--accent); }
.t-main { min-width: 0; }
.thread h2 { font-size: 1.65rem; margin: 8px 0 6px; overflow-wrap: anywhere; }
.thread h2 a { color: var(--night); text-decoration: none; }
.thread h2 a:hover { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 4px; }
.t-meta { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { padding: 3px 9px; background: var(--tint); color: var(--accent-dark); font: 600 .72rem/1.3 var(--text); letter-spacing: .06em; text-transform: uppercase; }
.tag.pin { background: var(--accent); color: #fff; }
.tag.lock { background: #fde8e6; color: var(--danger); }
.t-by { color: var(--muted); font-size: .92rem; }
.t-by strong { color: var(--ink); }
.fb { padding: 1px 7px; font: 600 .68rem/1.4 var(--text); letter-spacing: .06em; text-transform: uppercase; }
.fb-artist { background: var(--tint-2); color: var(--accent-dark); }
.fb-admin { background: var(--night); color: #fff; }
.t-stats { display: flex; flex-direction: column; align-items: flex-end; justify-content: center; min-width: 96px; text-align: right; }
.t-n { font-size: 2.2rem; color: var(--accent-dark); }
.t-l { font-size: .85rem; color: var(--muted); }
.t-last { margin-top: 6px; font-size: .78rem; color: var(--muted); }

.pager { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 22px 0; font-size: .95rem; }
.pager span { color: var(--muted); }

.newthread { margin-top: 44px; padding: clamp(20px, 4vw, 36px); background: var(--surface); border: 1.5px solid var(--line); }
.newthread h2 { font-size: 2.2rem; margin-bottom: 18px; }
.fform { display: grid; gap: 16px; }
.fform label { display: grid; gap: 6px; font-weight: 500; font-size: .95rem; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: end; }
.postas { color: var(--muted); padding-bottom: 12px; }
.hint { color: var(--muted); font-size: .88rem; }
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.fform .fbtn { justify-self: start; }

.notice { padding: 12px 16px; margin-bottom: 12px; border-left: 4px solid; }
.notice.err { background: #fde8e6; border-color: var(--danger); color: #7a1610; }
.notice.ok { background: #e6f4ea; border-color: #1e8e3e; color: #14562a; }

.crumbs { margin: 22px 0 14px; font-size: .9rem; color: var(--muted); }
.op { padding: clamp(20px, 4vw, 34px); background: var(--surface); border: 1.5px solid var(--line); border-top: 5px solid var(--accent); }
.op h1 { font-size: clamp(2rem, 1.2rem + 3vw, 3.2rem); margin: 10px 0; overflow-wrap: anywhere; }
.body { margin-top: 16px; overflow-wrap: anywhere; }
.body a { color: var(--accent-dark); }
.acts { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; margin-top: 16px; font-size: .85rem; }
.inline { display: inline; margin: 0; }
.linkbtn { padding: 0; background: none; border: 0; font: inherit; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.linkbtn:hover { color: var(--accent-dark); }
.linkbtn.danger:hover { color: var(--danger); }
.rep { color: var(--danger); font-weight: 600; }
.is-hidden { opacity: .55; }
.rh { font-size: 1.8rem; margin: 34px 0 14px; }
.posts { display: grid; gap: 10px; }
.post { padding: 18px 22px; background: var(--surface); border: 1.5px solid var(--line); scroll-margin-top: 20px; }
.post:target { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(26,115,232,.18); }
.post .body { margin-top: 8px; }

.ffoot { display: flex; justify-content: space-between; gap: 12px; padding: 20px var(--m); background: var(--night); color: #f4f6fa; font-size: .9rem; }
.ffoot a { color: inherit; }

@media (max-width: 640px) {
  .thread { flex-direction: column; gap: 8px; }
  .t-stats { flex-direction: row; align-items: baseline; justify-content: flex-start; gap: 6px; text-align: left; }
  .t-last { margin: 0 0 0 auto; }
  .row2 { grid-template-columns: 1fr; }
  .fbar nav { gap: 12px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
