/* Admin Core wiki (/wiki/admin-core). Builds on styles.css; gold accents match the in-game Admin Core menus. */
.wiki { --ac: #e0b040; --ac-soft: rgba(224, 176, 64, .14); --ac-line: rgba(224, 176, 64, .32); }
.wiki-glow { background: radial-gradient(circle, rgba(224, 176, 64, .35), rgba(109, 40, 217, .25) 40%, transparent 68%); }
.pix { image-rendering: pixelated; }

.wiki-layout {
  max-width: 1280px; margin: 0 auto; padding: 28px clamp(16px, 4vw, 48px) 60px;
  display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 40px; align-items: start;
}

/* ------------------------------------------------------------ sidebar */
.wiki-side { position: sticky; top: 84px; max-height: calc(100vh - 100px); overflow-y: auto; padding-right: 4px; }
.wiki-title { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.wiki-title img { image-rendering: pixelated; }
.wiki-title b { display: block; font: 700 18px var(--display); color: var(--ac); }
.wiki-title span { font-size: 13px; color: var(--muted); }
#wiki-search {
  width: 100%; padding: 9px 12px; margin-bottom: 14px; border-radius: 10px; border: 1px solid var(--line-strong);
  background: var(--panel-solid); color: var(--text); font: 14px var(--font);
}
#wiki-search:focus { outline: none; border-color: var(--ac-line); }
.toc { display: flex; flex-direction: column; gap: 1px; }
.toc-h { margin: 14px 0 4px; font: 600 11.5px var(--font); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.toc-h:first-child { margin-top: 0; }
.toc a { padding: 5px 10px; border-left: 2px solid transparent; border-radius: 0 8px 8px 0; color: #c9c7da; font-size: 14px; }
.toc a:hover { background: rgba(255, 255, 255, .04); color: var(--text); }
.toc a.on { border-left-color: var(--ac); background: var(--ac-soft); color: var(--ac); }
.toc a.dim { opacity: .3; }

/* ------------------------------------------------------------ content */
.wiki-main { min-width: 0; }
.wsec { padding: 30px 0 34px; border-bottom: 1px solid var(--line); }
.wsec:first-of-type { padding-top: 0; }
.wsec h2 { font-size: 28px; margin-bottom: 12px; display: flex; align-items: center; gap: 12px; }
.wsec.mod h2::before { content: ''; width: 6px; height: 26px; border-radius: 3px; background: var(--m, var(--ac)); }
.wsec h3 { font-size: 18px; margin: 24px 0 8px; color: #f1e3bf; }
.wsec p, .wsec li { color: #cfcde0; }
.wsec ul, .wsec ol { padding-left: 22px; }
.wsec li { margin: 4px 0; }
.wsec a:not(.btn) { color: var(--ac); }
.wsec a:not(.btn):hover { text-decoration: underline; }
.wsec code { font: 500 .88em var(--mono); background: rgba(255, 255, 255, .06); border: 1px solid var(--line); padding: 1px 6px; border-radius: 6px; color: #f3d892; white-space: nowrap; }
.wiki-empty { padding: 40px 0; color: var(--muted); }

.wiki-hero { display: flex; gap: 24px; align-items: center; margin-bottom: 18px; }
.wiki-hero h1 { font-size: clamp(32px, 5vw, 46px); }
.eyebrow-ac { margin: 0 0 4px; font: 600 12.5px var(--font); text-transform: uppercase; letter-spacing: .1em; color: var(--ac); }
.lead { font-size: 17px; margin: 8px 0 14px; }
.btn-ac { border-color: var(--ac-line) !important; background: var(--ac-soft) !important; }

figure { margin: 18px 0; }
figure img { display: block; width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--ac-line); background: #1a1d2b; }
figure.narrow { max-width: 440px; }
figcaption { margin-top: 8px; font-size: 13px; color: var(--muted); }

.callout { margin: 18px 0; padding: 14px 18px; border-radius: 12px; border: 1px solid var(--ac-line); background: var(--ac-soft); color: #eadfc4; }
.callout.warn { border-color: rgba(248, 113, 113, .4); background: rgba(248, 113, 113, .09); color: #f5d0d0; }

table.cmd { width: 100%; border-collapse: collapse; margin: 10px 0 6px; font-size: 14px; }
table.cmd td { padding: 9px 12px; border-bottom: 1px solid var(--line); vertical-align: top; color: #cfcde0; }
table.cmd td:first-child { width: 48%; }
table.cmd code { white-space: normal; }
table.cmd tr:hover td { background: rgba(255, 255, 255, .02); }
table.cmd tr.grp td { padding-top: 16px; font: 600 12px var(--font); text-transform: uppercase; letter-spacing: .08em; color: var(--ac); border-bottom-color: var(--ac-line); }
.tag { display: inline-block; margin-left: 4px; padding: 0 7px; border-radius: 99px; font: 600 11px/1.7 var(--font); vertical-align: 1px; }
.tag.staff { background: rgba(239, 83, 80, .15); color: #ff8a80; border: 1px solid rgba(239, 83, 80, .35); }

ul.cols { columns: 2; column-gap: 28px; }
.flags { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.flags > div { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: rgba(255, 255, 255, .015); }
.flags b { color: #f1e3bf; }
.flags p { margin: 6px 0 0; line-height: 2; }

details { border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; margin: 10px 0; background: rgba(255, 255, 255, .015); }
details summary { cursor: pointer; font-weight: 600; }
details[open] summary { margin-bottom: 6px; }

@media (max-width: 900px) {
  .wiki-layout { grid-template-columns: 1fr; gap: 20px; }
  .wiki-side { position: static; max-height: none; }
  .toc { flex-direction: row; flex-wrap: wrap; gap: 6px; }
  .toc-h { display: none; }
  .toc a { border: 1px solid var(--line); border-radius: 99px; padding: 4px 11px; font-size: 13px; }
  .toc a.on { border-color: var(--ac-line); }
  table.cmd td { display: block; width: auto !important; border-bottom: 0; padding: 4px 10px; }
  table.cmd tr { display: block; border-bottom: 1px solid var(--line); padding: 6px 0; }
  ul.cols { columns: 1; }
  .wsec code { white-space: normal; overflow-wrap: anywhere; }
  .flags { grid-template-columns: 1fr; }
  .wiki-hero { flex-direction: column; align-items: flex-start; gap: 12px; }
  .wiki-hero img { width: 72px; height: 72px; }
}
