/* Enciclopédia pública (páginas estáticas geradas por tools/wiki/build.js).
 * Folha própria e leve: não carrega style.css do jogo. Sem glow/neon, sem faixa lateral, sem pílulas (CLAUDE.md). */
:root {
  --bg: #100b0c; --panel: #1d1416; --panel2: #261a1b; --line: #d99a5940; --line2: #d99a5926;
  --text: #f4e6cf; --muted: #cdb79c; --gold: #efb773; --gold2: #f7d5a3; --link: #f0ba6e;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; color: var(--text);
  background: radial-gradient(ellipse at 50% 0%, #2a1715, var(--bg) 60%) fixed, var(--bg);
  font: 1.05rem/1.6 Georgia, 'Times New Roman', serif;
}
a { color: var(--link); text-underline-offset: .18em; }
a:hover { color: #ffd39a; }
:focus-visible { outline: 2px solid #ffcd88; outline-offset: 3px; }
img { max-width: 100%; height: auto; }
h1, h2, h3 { font-family: Cinzel, Georgia, serif; line-height: 1.15; color: var(--gold2); }
h1 { margin: 0 0 12px; font-size: clamp(1.9rem, 5vw, 3rem); }
h2 { margin: 40px 0 14px; font-size: clamp(1.3rem, 3vw, 1.75rem); }
h2 small { font: .9rem Georgia, serif; color: var(--muted); margin-left: 6px; }
h2 a { color: inherit; }
h3 { margin: 0 0 4px; font-size: 1.05rem; }

.wk-skip { position: absolute; left: -9999px; top: 8px; z-index: 10; padding: 8px 12px; background: var(--gold); color: #231208; }
.wk-skip:focus { left: 16px; }

.wk-header, .wk-main, .wk-footer { width: min(1180px, 100%); margin: 0 auto; padding-inline: clamp(16px, 4vw, 48px); }
.wk-header { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 22px; padding-block: 14px; border-bottom: 1px solid var(--line); }
.wk-header a { color: var(--text); text-decoration: none; }
.wk-header a:hover { color: var(--link); }
.wk-brand { margin-right: auto; font: 700 1.1rem Cinzel, Georgia, serif; }
.wk-brand span { color: #e3a55b; }
.wk-header nav { display: flex; flex-wrap: wrap; gap: 6px clamp(12px, 2.6vw, 26px); }
.wk-header nav [aria-current="page"] { color: var(--link); text-decoration: underline; text-underline-offset: 4px; }
.wk-lang { font-family: "IM Fell English", serif; font-size: 15px; background: #0e0a0c; color: #e6d6b4; border: 1px solid #5a4528; padding: 5px; border-radius: 3px; outline: none; }
.wk-play {
  display: inline-flex; align-items: center; justify-content: center; min-height: 40px; padding: 6px 16px;
  border: 1px solid #e4a65d; border-radius: 3px; background: #eab370; color: #231208 !important;
  font: 700 .82rem Cinzel, Georgia, serif; text-decoration: none;
}
.wk-play:hover { background: #ffcb86; }
.wk-play.big { min-height: 46px; padding-inline: 24px; font-size: .95rem; }

.wk-main { padding-block: 22px 40px; }
.wk-crumbs ol { display: flex; flex-wrap: wrap; gap: 4px; margin: 0 0 18px; padding: 0; list-style: none; font-size: .9rem; color: var(--muted); }
.wk-crumbs li + li::before { content: '›'; margin-right: 6px; color: #8d735a; }
.wk-crumbs a { color: var(--muted); }
.wk-lead { max-width: 70ch; margin: 0 0 18px; color: #e2cdb2; font-size: 1.12rem; }
.wk-hero { padding-block: 12px 18px; }

/* grade de cartões */
.wk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin: 0; padding: 0; list-style: none; }
.wk-grid-md { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); margin-block: 18px; }
.wk-grid-sm { grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); }
.wk-card { min-width: 0; border: 1px solid var(--line); background: var(--panel); }
.wk-card > a, .wk-card { display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; text-decoration: none; color: var(--text); }
.wk-card > a { width: 100%; height: 100%; padding: 8px 8px 10px; }
.wk-card:not(:has(> a)) { padding: 8px 8px 10px; }
.wk-card > a:hover { background: var(--panel2); }
.wk-card > a:hover .wk-card-name { color: var(--link); }
.wk-card img { width: 100%; max-width: 150px; aspect-ratio: 1; object-fit: contain; background: radial-gradient(circle at 50% 60%, #2e1f1d, transparent 70%); }
.wk-grid-sm .wk-card img { max-width: 72px; }
.wk-card-name { font: 700 .92rem/1.25 Cinzel, Georgia, serif; overflow-wrap: anywhere; }
.wk-card-sub { font-size: .82rem; color: var(--muted); }

/* página de entidade */
.wk-entity-grid { display: grid; grid-template-columns: minmax(0, 380px) minmax(0, 1fr); gap: 22px; align-items: start; }
.wk-entity-grid > section h2 { margin-top: 0; }
.wk-figure { margin: 0; border: 1px solid var(--line); background: radial-gradient(ellipse at 50% 65%, #3a2320, #160f11 72%); }
.wk-figure img { display: block; width: 100%; aspect-ratio: 1; object-fit: contain; }
.wk-figure figcaption { padding: 8px 12px; border-top: 1px solid var(--line2); color: var(--muted); font-size: .92rem; }
.wk-figure-sm { max-width: 220px; }
.wk-facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 0; margin: 0; border: 1px solid var(--line); background: var(--panel); }
.wk-facts div { padding: 9px 12px; border-bottom: 1px solid var(--line2); border-right: 1px solid var(--line2); }
.wk-facts dt { font: 700 .74rem Cinzel, Georgia, serif; letter-spacing: .06em; color: var(--gold); text-transform: uppercase; }
.wk-facts dd { margin: 2px 0 0; }
.wk-list { margin: 0; padding-left: 1.2em; }
.wk-list li + li { margin-top: 6px; }
.wk-cols { columns: 2 180px; }
.wk-row { display: flex; gap: 14px; align-items: flex-start; }
.wk-row img { flex: none; }
.wk-row p { margin: 0; }
.wk-pager { display: flex; justify-content: space-between; gap: 12px; margin-top: 34px; padding-top: 14px; border-top: 1px solid var(--line); }
.wk-pager a { text-decoration: none; }

/* listas de habilidades e móveis */
.wk-skills { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 10px; margin: 0; padding: 0; list-style: none; }
.wk-skills li { display: flex; gap: 12px; padding: 12px; border: 1px solid var(--line); background: var(--panel); scroll-margin-top: 12px; }
.wk-skills li:target { border-color: #e4a65d; }
.wk-skills img { flex: none; width: 56px; height: 56px; }
.wk-furn img { width: 96px; height: 96px; object-fit: contain; }
.wk-skills p { margin: 0; font-size: .96rem; }
.wk-meta { margin-top: 4px !important; color: var(--muted); font-size: .86rem !important; }
.wk-houses { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.wk-houses li { display: grid; grid-template-columns: minmax(0, 270px) minmax(0, 1fr); gap: 16px; align-items: center; padding: 12px; border: 1px solid var(--line); background: var(--panel); }
.wk-houses h3 { font-size: 1.25rem; margin-bottom: 8px; }

/* tabelas */
.wk-table-wrap { overflow-x: auto; margin-block: 14px; border: 1px solid var(--line); }
.wk-table { width: 100%; border-collapse: collapse; font-size: .96rem; }
.wk-table caption { padding: 10px 12px; text-align: left; font: 700 .95rem Cinzel, Georgia, serif; color: var(--gold); background: var(--panel2); }
.wk-table th, .wk-table td { padding: 8px 12px; text-align: left; border-top: 1px solid var(--line2); white-space: nowrap; }
.wk-table thead th { font: 700 .74rem Cinzel, Georgia, serif; letter-spacing: .05em; color: var(--muted); text-transform: uppercase; background: var(--panel); }
.wk-table tbody tr:nth-child(odd) { background: #ffffff05; }
.wk-table tbody th { font-weight: 700; }
.wk-rar { display: inline-flex; align-items: center; gap: 8px; color: var(--rc); }

/* índice e busca */
.wk-toc ol { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 0 0 8px; padding: 0; list-style: none; font-size: .92rem; }
.wk-search { position: relative; max-width: 620px; margin-top: 18px; }
.wk-search label { display: block; margin-bottom: 6px; color: var(--muted); }
.wk-search input { width: 100%; min-height: 46px; padding: 8px 12px; border: 1px solid #966a45; border-radius: 3px; background: #150f11; color: var(--text); font: 16px Georgia, serif; }
.wk-results { margin: 6px 0 0; padding: 0; list-style: none; border: 1px solid var(--line); background: var(--panel); }
.wk-results:empty { display: none; }
.wk-results a { display: flex; align-items: center; gap: 10px; padding: 6px 10px; text-decoration: none; color: var(--text); border-top: 1px solid var(--line2); }
.wk-results li:first-child a { border-top: 0; }
.wk-results a:hover, .wk-results a:focus-visible { background: var(--panel2); }
.wk-results img { width: 40px; height: 40px; object-fit: contain; flex: none; }
.wk-results small { display: block; color: var(--muted); }
.wk-results .wk-empty { padding: 8px 10px; color: var(--muted); }
.wk-faq { border: 1px solid var(--line); background: var(--panel); padding: 10px 14px; }
.wk-faq + .wk-faq { border-top: 0; }
.wk-faq summary { cursor: pointer; font-weight: 700; color: var(--gold2); }
.wk-faq p { margin: 8px 0 2px; color: #e2cdb2; }

/* rodapé */
.wk-footer { padding-block: 20px 34px; border-top: 1px solid var(--line); }
.wk-cta { padding: 22px; margin-bottom: 20px; border: 1px solid var(--line); background: var(--panel); text-align: center; }
.wk-cta h2 { margin-top: 0; }
.wk-cta p { color: var(--muted); }
.wk-footer nav { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: .92rem; }
.wk-small { color: #a99076; font-size: .85rem; }

@media (max-width: 760px) {
  .wk-header { gap: 8px 10px; }
  .wk-brand { font-size: 1rem; }
  .wk-play { padding-inline: 10px; }
  .wk-header nav { order: 5; width: 100%; }
  .wk-entity-grid { grid-template-columns: 1fr; }
  .wk-figure { max-width: 420px; }
  .wk-houses li { grid-template-columns: 1fr; }
  .wk-grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
  .wk-grid-sm { grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); }
}
