/* Miyako community forum - base layer.
   Tokens, shared components, discussions, replies and dialogs.
   The portal shell (rail, topbar, hero, board directory, widgets) lives in
   forum-portal.css and only builds on the tokens defined here. */

:root{
  color-scheme:dark;

  /* Surfaces - a slightly blue-tinted charcoal so the purple accents read clean. */
  --bg:#0c0a12;
  --bg-glow:#3a2461;
  --surface:#151220;
  --surface-2:#1c1729;
  --panel:#191425;
  --panel-2:#211b31;

  /* Lines */
  --line:#2a2338;
  --line-strong:#3a3050;
  --border:#332a47;

  /* Brand */
  --brand:#ad8fff;
  --brand-soft:#c9b5ff;
  --brand-ink:#170f27;
  --brand-12:rgba(173,143,255,.12);
  --brand-20:rgba(173,143,255,.2);
  --brand-40:rgba(173,143,255,.4);

  /* Text */
  --text:#f5f1fc;
  --muted:#a99cbd;
  --muted-2:#867a99;

  /* States */
  --ok:#8ee0b4;
  --ok-bg:rgba(74,222,128,.1);
  --ok-line:rgba(74,222,128,.32);
  --warn:#f4c891;
  --warn-bg:rgba(244,200,145,.1);
  --warn-line:rgba(244,200,145,.32);
  --danger:#ff8fa0;

  /* Shape and depth */
  --radius-sm:8px;
  --radius:12px;
  --radius-lg:16px;
  --radius-xl:22px;
  --shadow-sm:0 1px 2px rgba(0,0,0,.4);
  --shadow:0 18px 44px rgba(0,0,0,.45);
  --shadow-lg:0 30px 80px rgba(0,0,0,.55);

  --ring:0 0 0 2px var(--bg), 0 0 0 4px var(--brand-40);

  font:15px/1.6 "Segoe UI",Inter,ui-sans-serif,system-ui,-apple-system,sans-serif;
  -webkit-text-size-adjust:100%;
}

*,*::before,*::after{box-sizing:border-box}
html{scroll-behavior:smooth}
body.forum-page{
  margin:0;
  min-width:320px;
  background:
    radial-gradient(ellipse 900px 520px at 82% -12%,rgba(122,86,196,.28),transparent 62%),
    radial-gradient(ellipse 700px 420px at 8% 4%,rgba(80,54,140,.16),transparent 60%),
    var(--bg);
  background-attachment:fixed;
  color:var(--text);
  font:inherit;
}
body.forum-page.no-scroll{overflow:hidden}
h1,h2,h3,h4{letter-spacing:-.02em;line-height:1.2;margin:0}
p{margin:0}
a{color:inherit}
img{max-width:100%}
button,input,select,textarea{font:inherit;color:inherit}
::selection{background:var(--brand-40);color:#fff}
:focus{outline:none}

.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}
.anchor-offset{scroll-margin-top:110px}
.muted{color:var(--muted);font-size:12.5px}
.forum-app [hidden],.forum-shell [hidden],.forum-dialog [hidden]{display:none!important}

/* ---------------------------------------------------------------- buttons -- */

.button{
  display:inline-flex;align-items:center;justify-content:center;gap:8px;
  min-height:42px;padding:10px 18px;
  border:1px solid transparent;border-radius:10px;
  background:linear-gradient(140deg,#b79cff,#8a63dd);
  color:var(--brand-ink);
  font-size:13px;font-weight:700;line-height:1;letter-spacing:.01em;
  text-decoration:none;white-space:nowrap;cursor:pointer;
  box-shadow:0 10px 26px rgba(138,99,221,.28);
  transition:transform .16s ease, box-shadow .16s ease, background .16s ease, border-color .16s ease, color .16s ease;
}
.button:hover:not(:disabled){transform:translateY(-1px);background:linear-gradient(140deg,#c8b2ff,#9d78ea);box-shadow:0 14px 30px rgba(138,99,221,.36)}
.button:active:not(:disabled){transform:translateY(0)}
.button:disabled{opacity:.5;cursor:not-allowed;box-shadow:none}

.button-outline{
  background:rgba(255,255,255,.03);
  border-color:var(--line-strong);
  color:var(--text);
  box-shadow:none;
}
.button-outline:hover:not(:disabled){background:var(--brand-12);border-color:var(--brand);color:#fff;box-shadow:none}

.forum-text-button{
  border:0;background:none;padding:0;
  color:var(--brand-soft);font:inherit;font-size:13px;font-weight:600;
  cursor:pointer;text-decoration:none;
  border-bottom:1px solid transparent;
  transition:color .16s ease,border-color .16s ease;
}
.forum-text-button:hover{color:#e2d6ff;border-bottom-color:currentColor}

:where(button,a,input,select,textarea,summary,[tabindex]):focus-visible{outline:2px solid var(--brand);outline-offset:3px;border-radius:8px}

/* ----------------------------------------------------------------- fields -- */

.forum-shell :where(input,select,textarea),
.forum-dialog :where(input,select,textarea){
  width:100%;padding:11px 14px;
  border:1px solid var(--border);border-radius:10px;
  background:#120f1c;color:var(--text);font-size:13.5px;
  transition:border-color .16s ease,box-shadow .16s ease,background .16s ease;
}
.forum-shell :where(input,select,textarea):hover{border-color:var(--line-strong)}
.forum-shell :where(input,select,textarea):focus,
.forum-dialog :where(input,select,textarea):focus{
  outline:none;border-color:var(--brand);background:#171227;
  box-shadow:0 0 0 3px var(--brand-12);
}
.forum-shell ::placeholder,.forum-dialog ::placeholder{color:var(--muted-2)}
.forum-shell textarea,.forum-dialog textarea{resize:vertical;min-height:120px;line-height:1.7}

/* ------------------------------------------------------------------ tags -- */

.forum-tag{
  display:inline-flex;align-items:center;gap:5px;
  padding:3px 9px;border-radius:999px;
  border:1px solid var(--brand-40);background:var(--brand-12);color:var(--brand-soft);
  font-size:10.5px;font-weight:650;letter-spacing:.04em;text-transform:uppercase;line-height:1.5;
  white-space:nowrap;
}
.forum-tag.problems{color:var(--warn);background:var(--warn-bg);border-color:var(--warn-line)}
.forum-tag.resolved{color:var(--ok);background:var(--ok-bg);border-color:var(--ok-line)}
.forum-tag.locked{color:var(--muted);background:rgba(255,255,255,.04);border-color:var(--line-strong)}

.forum-message{min-height:20px;margin:14px 0 0;color:var(--brand-soft);font-size:13px;line-height:1.7;overflow-wrap:anywhere}
.forum-message:empty{display:none}

/* ---------------------------------------------------------- topic listing -- */

.forum-toolbar{display:flex;align-items:flex-end;justify-content:space-between;gap:20px;margin-bottom:18px;flex-wrap:wrap}
.forum-toolbar h2{font-size:23px;font-weight:650;margin:10px 0 4px}
.forum-toolbar p{font-size:12.5px}
#board-actions{display:flex;align-items:center;gap:14px}

.forum-filters{display:flex;gap:10px;margin-bottom:18px;flex-wrap:wrap}
.forum-filters input{flex:1 1 260px;min-width:0}
.forum-filters select{flex:0 0 auto;width:170px;appearance:none;
  background-image:linear-gradient(45deg,transparent 50%,var(--muted) 50%),linear-gradient(135deg,var(--muted) 50%,transparent 50%);
  background-position:calc(100% - 19px) 19px,calc(100% - 13px) 19px;
  background-size:6px 6px,6px 6px;background-repeat:no-repeat;padding-right:38px}
.forum-filters button{flex:0 0 auto}

.topic-list{
  list-style:none;margin:0;padding:0;
  border:1px solid var(--border);border-radius:var(--radius-lg);
  background:linear-gradient(170deg,var(--surface-2),var(--surface) 70%);
  overflow:hidden;box-shadow:var(--shadow-sm);
}
.topic-card{
  display:grid;grid-template-columns:34px minmax(0,1fr) auto;
  gap:12px;align-items:center;padding:9px 16px;
  border-bottom:1px solid var(--line);
  transition:background .16s ease,box-shadow .16s ease;
}
.topic-card:last-child{border-bottom:0}
.topic-card:hover{background:rgba(173,143,255,.05)}
.topic-card:hover .topic-avatar{background:var(--brand-20);color:#efe6ff}

.topic-avatar{
  display:grid;place-items:center;width:32px;height:32px;border-radius:50%;
  background:#332348;color:var(--brand-soft);
  font-size:11px;font-weight:700;letter-spacing:.02em;
  transition:background .16s ease,color .16s ease;
}
.topic-card-body{display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-rows:auto auto;column-gap:10px;align-items:center;min-width:0}
.topic-card h3{grid-column:1;grid-row:1;min-width:0;margin:0;font-size:13.5px;font-weight:650;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.topic-card h3 a{display:block;overflow:hidden;color:var(--text);text-decoration:none;text-overflow:ellipsis;white-space:nowrap;transition:color .16s ease}
.topic-card h3 a:hover{color:var(--brand-soft)}
.topic-tags{grid-column:2;grid-row:1;display:flex;gap:4px;flex-wrap:nowrap;align-items:center;justify-content:flex-end;min-width:0}
.topic-card .topic-tags .forum-tag{padding:2px 7px;font-size:9px;line-height:1.25;white-space:nowrap}
.topic-meta{font-size:10px;color:var(--muted-2);line-height:1.3}
.topic-card .topic-meta{grid-column:1 / -1;grid-row:2;margin:2px 0 0}
.topic-meta strong{color:var(--muted);font-weight:600}

.reply-count{
  display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px;
  min-width:46px;padding:4px 8px;border-radius:10px;
  border:1px solid var(--line);background:rgba(255,255,255,.02);
  color:var(--text);font-size:17px;font-weight:650;font-variant-numeric:tabular-nums;
}
.reply-count small{font-size:10px;font-weight:600;color:var(--muted-2);letter-spacing:.06em;text-transform:uppercase}

.forum-pagination{display:flex;align-items:center;justify-content:center;gap:14px;padding:22px 0;font-size:12.5px;color:var(--muted)}
.forum-pagination #page-label{font-weight:600;color:var(--muted)}

/* ---------------------------------------------------------- type of state -- */

.forum-empty{
  display:flex;flex-direction:column;align-items:center;gap:8px;
  padding:56px 26px;text-align:center;
  color:var(--muted);font-size:14px;line-height:1.75;
}
.forum-empty::before{
  content:"";width:44px;height:44px;margin-bottom:6px;border-radius:14px;
  border:1px dashed var(--line-strong);background:var(--brand-12);
}

.forum-loading{padding:20px 22px;display:grid;gap:12px}
.forum-loading span{display:block;height:14px;border-radius:8px;
  background:linear-gradient(90deg,rgba(255,255,255,.04) 25%,rgba(255,255,255,.09) 50%,rgba(255,255,255,.04) 75%);
  background-size:200% 100%;animation:forum-shimmer 1.5s ease-in-out infinite}
.forum-loading span:nth-child(1){width:46%}
.forum-loading span:nth-child(2){width:82%}
.forum-loading span:nth-child(3){width:64%}
.forum-loading span:nth-child(4){width:74%}
@keyframes forum-shimmer{0%{background-position:150% 0}100%{background-position:-50% 0}}

/* ------------------------------------------------------- topic + replies -- */

.forum-post-card{
  display:grid;grid-template-columns:136px minmax(0,1fr);gap:24px;
  padding:20px;margin-bottom:12px;border:1px solid var(--line-strong);border-radius:var(--radius);
  background:linear-gradient(150deg,rgba(31,26,43,.88),rgba(19,16,27,.96));box-shadow:var(--shadow-sm);
}
.forum-topic{margin-top:20px}
.forum-post-author{display:flex;align-items:center;flex-direction:column;gap:6px;min-width:0;padding:5px 14px 8px 0;border-right:1px solid var(--line)}
.forum-author-avatar{display:grid;width:84px;height:84px;place-items:center;margin:0 0 3px;border:3px solid var(--brand-40);border-radius:50%;background:radial-gradient(circle at 35% 30%,var(--brand-40),var(--brand-12) 70%);color:var(--brand-soft);font-size:34px;font-weight:650;box-shadow:0 0 0 4px rgba(173,143,255,.07)}
.forum-author-name{max-width:100%;color:var(--text);font-size:14px;text-align:center;overflow-wrap:anywhere}
.forum-author-badges{display:flex;justify-content:center;flex-wrap:wrap;gap:4px}
.forum-author-badge{padding:2px 8px;border-radius:999px;background:var(--brand-12);color:var(--brand-soft);font-size:10px;font-weight:650}
.forum-author-badge.is-staff{background:rgba(142,224,180,.16);color:var(--ok)}
.forum-author-stat-label{align-self:flex-start;margin-top:4px;color:var(--muted-2);font-size:10px;line-height:1.3}
.forum-author-stat-value{align-self:flex-end;margin-top:-6px;color:var(--muted);font-size:10px;font-weight:500;text-align:right}
.forum-post-main{min-width:0}
.forum-post-head{display:flex;align-items:center;justify-content:space-between;gap:14px;min-height:24px;margin-bottom:16px;color:var(--muted);font-size:11px}
.forum-post-tools{display:flex;align-items:center;gap:10px}
.forum-icon-button{display:grid;width:25px;height:25px;place-items:center;border:0;border-radius:6px;background:transparent;color:var(--muted);font-size:15px;cursor:pointer}
.forum-icon-button:hover{background:var(--brand-12);color:var(--brand-soft)}
.forum-post-number{color:var(--brand-soft);font-size:11px}
.forum-topic h2{font-size:clamp(20px,2.4vw,28px);font-weight:700;margin:12px 0 10px;overflow-wrap:anywhere}
.forum-topic .topic-meta{margin-bottom:2px}
.forum-topic>button{margin-top:22px}
.forum-content p+p{margin-top:12px}
.forum-content h1,.forum-content h2,.forum-content h3{margin:14px 0 8px;color:var(--text);font-weight:700;line-height:1.3}
.forum-content h1{font-size:1.45em}.forum-content h2{font-size:1.25em}.forum-content h3{font-size:1.1em}
.forum-content ul{margin:10px 0;padding-left:24px}
.forum-content ol{margin:10px 0;padding-left:26px}
.forum-content blockquote{margin:10px 0;padding:8px 14px;border-left:2px solid var(--brand-40);color:var(--muted);background:var(--brand-12)}
.forum-content .forum-quoted-post,.composer-preview .forum-quoted-post{padding:0;border:1px solid var(--line-strong);border-left:2px solid var(--brand);border-radius:8px;background:rgba(8,7,13,.22);color:var(--text)}
.forum-quote-header{display:flex;align-items:center;gap:6px;padding:7px 10px;background:rgba(173,143,255,.08);color:var(--brand-soft);font-size:10px;letter-spacing:.035em;text-transform:uppercase}
.forum-quote-mark{font-size:14px;line-height:1}
.forum-quote-body{padding:8px 10px;overflow:hidden;transition:max-height .42s cubic-bezier(.2,.75,.25,1),opacity .24s ease;opacity:.96}
.forum-quote-expand{display:block;width:100%;padding:5px 10px;border:0;background:linear-gradient(transparent,rgba(8,7,13,.55));color:var(--brand-soft);font-size:10px;cursor:pointer}
.forum-quote-expand:hover{color:var(--text);text-decoration:underline}
.forum-quoted-post.is-expanded .forum-quote-expand{border-top:1px solid var(--line);background:transparent}
.forum-content a{color:var(--brand-soft);text-decoration:underline;text-underline-offset:3px}
.forum-content code{padding:2px 5px;border-radius:5px;background:rgba(0,0,0,.25);font-size:.92em}
.forum-content pre{max-width:100%;margin:12px 0;padding:12px 14px;overflow:auto;border:1px solid var(--line);border-radius:8px;background:rgba(8,7,13,.35);line-height:1.55}
.forum-content pre code{padding:0;background:transparent}
.forum-content{white-space:normal;overflow-wrap:anywhere;font-size:14.5px;line-height:1.9;color:#ded4ec;margin:20px 0 0}

.replies-heading{
  display:flex;align-items:center;gap:12px;
  margin:32px 0 16px;font-size:14px;font-weight:700;
  letter-spacing:.08em;text-transform:uppercase;color:var(--muted);
}
.replies-heading::after{content:"";flex:1;height:1px;background:var(--line)}

.forum-reply-card{border-color:var(--line)}
.forum-reply-card .forum-post-head{margin-bottom:12px}
.forum-reply-card .forum-content{min-height:40px;margin:0;padding:4px 0 18px}
.forum-post-actions{display:flex;align-items:center;gap:12px;margin-top:14px}
.forum-post-actions>div{display:flex;align-items:center;gap:14px}
.forum-post-actions-secondary{margin-left:auto}
.forum-post-edited{color:var(--muted-2);font-size:10px}
.news-reactions{display:flex;flex-wrap:wrap;gap:8px;margin:8px 0 16px}
.news-reaction{display:inline-flex;align-items:center;gap:7px;padding:7px 11px;border:1px solid var(--line-strong);border-radius:999px;background:rgba(255,255,255,.035);color:var(--text);cursor:pointer;transition:background .16s ease,border-color .16s ease,transform .16s ease}
.news-reaction:hover:not(:disabled),.news-reaction.is-selected{background:var(--brand-12);border-color:var(--brand-40)}
.news-reaction:hover:not(:disabled){transform:translateY(-1px)}
.news-reaction[aria-pressed="true"]{box-shadow:var(--ring)}
.reaction-emoji{font-size:16px;line-height:1}
.reaction-count{min-width:1ch;color:var(--muted);font-size:12px;font-weight:650}
.forum-reply-card .forum-post-actions{margin-top:10px}
.reply-edit-form textarea{width:100%;margin:0 0 12px}

.forum-composer{border:1px solid var(--border);border-radius:var(--radius-lg);background:linear-gradient(150deg,var(--surface-2),var(--surface));box-shadow:var(--shadow-sm)}
.forum-thread-composer{margin:0 0 22px;padding:22px}
.composer-breadcrumb{display:flex;align-items:center;gap:8px;margin-bottom:16px;color:var(--muted);font-size:12px}
.composer-breadcrumb strong{color:var(--brand-soft);font-weight:650}
.composer-board-field{max-width:280px;margin-bottom:12px}
.composer-board-field select{margin:0}
.forum-shell .composer-title{margin:0 0 12px;padding:13px 15px;background:rgba(173,143,255,.055);font-size:17px;font-weight:600}
.composer-toolbar{display:flex;align-items:center;gap:6px;min-height:46px;padding:5px 8px;border:1px solid var(--border);border-radius:10px 10px 0 0;background:rgba(255,255,255,.025);overflow-x:auto;scrollbar-width:thin;scrollbar-color:var(--line-strong) transparent}
.toolbar-group{display:flex;align-items:center;gap:2px;flex:none;padding:1px 3px;border:1px solid var(--line);border-radius:8px;background:rgba(8,7,13,.18)}
.composer-toolbar button{min-width:34px;height:30px;padding:0 9px;border:1px solid transparent;border-radius:7px;background:transparent;color:var(--muted);font:inherit;font-size:13px;cursor:pointer}
.composer-toolbar button:hover{border-color:var(--brand-40);background:var(--brand-12);color:var(--text)}
.composer-toolbar button:focus-visible,.toolbar-emoji-toggle:focus-visible,.emoji-picker button:focus-visible{outline:2px solid var(--brand)!important;outline-offset:1px}
.toolbar-emoji-wrap{display:inline-flex;flex:none}
.toolbar-emoji-toggle{width:36px;padding:0 4px!important;font-size:15px!important}
.emoji-picker{position:fixed;z-index:10000;width:192px;display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:5px;padding:9px;border:1px solid var(--line-strong);border-radius:12px;background:#171322;color:var(--text);box-shadow:0 16px 42px rgba(0,0,0,.58);opacity:0;transform:translateY(5px) scale(.98);transform-origin:top left;transition:opacity .14s ease,transform .14s ease}
.emoji-picker[hidden]{display:none!important}
.emoji-picker.is-open{opacity:1;transform:translateY(0) scale(1)}
.emoji-picker button{min-width:0!important;width:38px;height:38px!important;padding:0!important;border:1px solid transparent!important;border-radius:8px!important;background:rgba(255,255,255,.035)!important;color:var(--text)!important;font-size:20px!important;line-height:1;cursor:pointer}
.emoji-picker button:hover{border-color:var(--brand-40)!important;background:var(--brand-12)!important}
@media(prefers-reduced-motion:reduce){.emoji-picker{transition:none}}
.composer-toolbar button[data-preview]{padding:0 12px;border-color:var(--line-strong);font-size:11px;font-weight:650}
.composer-toolbar-spacer{flex:1;min-width:8px}
.forum-shell textarea.composer-editor{display:block;min-height:190px;margin:0;padding:16px;border-top:0;border-radius:0 0 10px 10px;background:rgba(8,7,13,.32);font-size:14px;line-height:1.75}
.forum-shell textarea.composer-editor[hidden]{display:none}
.composer-preview{min-height:190px;margin:0;padding:16px;border:1px solid var(--border);border-top:0;border-radius:0 0 10px 10px;color:var(--text);font:inherit;font-size:14px;line-height:1.75;white-space:pre-wrap;overflow-wrap:anywhere}
.composer-footer{display:flex;align-items:center;justify-content:space-between;gap:16px;padding-top:14px}
.composer-footer>div{display:flex;gap:9px}
.forum-reply{
  display:grid;grid-template-columns:64px minmax(0,1fr);gap:18px;
  margin-top:26px;padding:20px;
}
.reply-composer-avatar{display:grid;width:56px;height:56px;place-items:center;border-radius:50%;background:var(--brand-20);color:var(--brand-soft);font-size:23px;font-weight:650}
.reply-composer-main{min-width:0}
.forum-shell textarea#reply-body{min-height:128px;margin:0;border-top:0;border-radius:0 0 10px 10px;background:rgba(8,7,13,.32)}
.forum-shell textarea#reply-body[hidden]{display:none}
.reply-composer-footer{display:flex;align-items:center;justify-content:space-between;gap:14px;padding-top:10px}

#more-replies{margin-top:14px}

/* ------------------------------------------------------------- dialogs --- */

.forum-dialog{
  width:min(480px,calc(100% - 28px));max-height:90dvh;padding:32px;
  border:1px solid #6a4f96;border-radius:var(--radius-xl);
  background:radial-gradient(ellipse 120% 80% at 100% 0%,#3d2857 0%,transparent 58%),linear-gradient(160deg,#20182e,#150f20);
  color:var(--text);box-shadow:var(--shadow-lg);
  overflow:auto;font-family:inherit;
  animation:forum-dialog-in .18s ease-out;
}
.forum-dialog::backdrop{background:rgba(6,4,11,.72);backdrop-filter:blur(6px)}
@keyframes forum-dialog-in{from{opacity:0;transform:translateY(8px) scale(.98)}to{opacity:1;transform:none}}
.forum-dialog .eyebrow{
  display:inline-flex;align-items:center;gap:8px;margin:0;
  color:var(--brand-soft);font-size:10.5px;font-weight:750;letter-spacing:.2em;text-transform:uppercase;
}
.forum-dialog h2{font-size:27px;font-weight:700;margin:12px 0 22px}
.forum-dialog form label{display:block;margin-bottom:8px;font-size:12.5px;font-weight:600;color:var(--muted)}
.forum-dialog form>div{margin-bottom:16px}
.forum-dialog .button{width:100%;margin-top:4px}
.forum-dialog .forum-message{margin:0 0 14px}
.dialog-close{
  position:absolute;top:14px;right:14px;
  width:34px;height:34px;display:grid;place-items:center;
  border:1px solid transparent;border-radius:10px;background:transparent;
  color:var(--muted);font-size:22px;line-height:1;cursor:pointer;
  transition:background .16s ease,color .16s ease,border-color .16s ease;
}
.dialog-close:hover{background:rgba(255,255,255,.06);border-color:var(--line-strong);color:var(--text)}

.forum-auth-tabs{display:flex;gap:5px;padding:4px;margin-bottom:22px;border-radius:12px;background:#100c1a;border:1px solid var(--line)}
.forum-auth-tabs button{
  flex:1;padding:10px;border:0;border-radius:9px;background:transparent;
  color:var(--muted);font:inherit;font-size:12.5px;font-weight:650;cursor:pointer;
  transition:background .16s ease,color .16s ease;
}
.forum-auth-tabs button:hover{color:var(--text)}
.forum-auth-tabs button[aria-pressed=true]{background:linear-gradient(140deg,#5b3d85,#3b2a5c);color:#efe6ff;box-shadow:var(--shadow-sm)}

.forum-auth-links{display:flex;justify-content:space-between;gap:12px;margin-top:18px}
.forum-auth-links button{border:0;background:none;padding:0;color:var(--brand-soft);font-size:12px;font-weight:600;cursor:pointer}
.forum-auth-links button:hover{color:#e2d6ff;text-decoration:underline}

.topic-dialog{width:min(660px,calc(100% - 28px))}
.topic-dialog form>label{display:block;margin-bottom:8px;font-size:12.5px;font-weight:600;color:var(--muted)}
.topic-dialog select{margin-bottom:16px}
.topic-dialog input,.topic-dialog textarea{margin-bottom:16px}
.topic-dialog textarea{min-height:170px}
.topic-dialog .muted{margin-bottom:14px}

#bot-check{margin-bottom:16px}
#bot-check:empty{margin-bottom:0}

@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{animation-duration:.001ms!important;animation-iteration-count:1!important;transition-duration:.001ms!important}
}

@media (max-width:760px){
  .forum-post-card{grid-template-columns:74px minmax(0,1fr);gap:12px;padding:14px}
  .forum-post-author{gap:5px;padding:4px 8px 6px 0}
  .forum-author-avatar{width:52px;height:52px;border-width:2px;font-size:23px}
  .forum-author-name{font-size:11px}
  .forum-author-badge{padding:2px 5px;font-size:9px}
  .forum-author-stat-label,.forum-author-stat-value{font-size:9px}
  .forum-post-head{margin-bottom:11px}
  .forum-post-actions{align-items:flex-start;flex-wrap:wrap}
  .forum-post-actions>div{gap:9px}
  .forum-topic h2{font-size:20px}
  .topic-card{grid-template-columns:32px minmax(0,1fr) auto;gap:9px;padding:9px 12px}
  .topic-avatar{width:30px;height:30px;border-radius:50%;font-size:10px}
  .reply-count{grid-column:3;grid-row:1;flex-direction:column;justify-self:end;min-width:42px;padding:4px 6px;font-size:12px;gap:2px}
  .forum-toolbar{align-items:flex-start}
  .forum-filters select{width:100%}
  .forum-dialog{padding:26px 22px}
  .forum-thread-composer{padding:16px}
  .composer-breadcrumb{gap:5px;font-size:10.5px}
  .forum-reply{grid-template-columns:38px minmax(0,1fr);gap:10px;padding:14px}
  .reply-composer-avatar{width:36px;height:36px;font-size:17px}
  .composer-toolbar{gap:4px;padding:4px}
  .composer-toolbar button{min-width:29px;padding:0 6px}
  .toolbar-group{gap:1px;padding:1px 2px}
  .composer-footer,.reply-composer-footer{align-items:flex-start;flex-direction:column}
  .composer-footer>div{width:100%}
  .composer-footer>div .button{flex:1}
  .reply-composer-footer>.button{align-self:flex-end}
  .forum-topic{padding:22px 18px}
  .forum-reply-card{padding:17px}
}
