/* Generated database pages (items, places, monsters, enchants) and search */
.database-page .crumbs { margin: 0 0 8px; font-size: 14px; color: var(--lp-muted); }
.database-page .lead { font-size: 18px; margin-bottom: 14px; }
.database-page .muted { color: var(--lp-muted); font-size: 14px; }
.database-page code { font-size: 14px; color: var(--lp-muted); }
.database-page .provenance { margin-top: 28px; padding-top: 12px; border-top: 1px solid var(--lp-border); font-size: 14px; color: var(--lp-muted); }

.facts { border-collapse: collapse; margin: 10px 0 18px; width: 100%; }
.facts th, .facts td { padding: 6px 12px 6px 0; text-align: left; vertical-align: top; border-bottom: 1px solid var(--lp-border); }
.facts th { width: 11em; color: var(--lp-gold); font-weight: 600; white-space: nowrap; }

.live-box { margin: 8px 0 12px; padding: 12px 14px; background: var(--lp-surface); border: 1px solid var(--lp-border); border-radius: 8px; }
.stat-row { display: flex; flex-wrap: wrap; gap: 8px 28px; margin: 0 0 8px; }
.stat-row div { min-width: 7em; }
.stat-row dt { font-size: 13px; color: var(--lp-muted); }
.stat-row dd { margin: 0; font-size: 20px; font-weight: 700; color: var(--lp-gold); }

.link-list, .columns { list-style: none; padding: 0; margin: 8px 0 16px; }
.link-list li { padding: 3px 0; }
.columns { column-width: 15em; column-gap: 24px; }
.columns li { break-inside: avoid; padding: 2px 0; }

.button-link { display: inline-block; padding: 10px 18px; background: var(--lp-gold); color: #1a1a1a; font-weight: 700; border-radius: 6px; }
.button-link:hover { background: #f5c76d; color: #1a1a1a; }


.db-search, .search-form { display: flex; gap: 8px; margin: 14px 0 20px; }
.db-search input, .search-form input { flex: 1; min-width: 0; min-height: 44px; padding: 0 14px; font: inherit; color: var(--lp-text); background: var(--lp-surface); border: 1px solid var(--lp-border); border-radius: 6px; }
.db-search button, .search-form button { min-height: 44px; padding: 0 20px; font: inherit; font-weight: 700; color: #1a1a1a; background: var(--lp-gold); border: none; border-radius: 6px; cursor: pointer; }

.db-tiles { list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; padding: 0; margin: 16px 0; }
.db-tiles a { display: block; padding: 16px; background: var(--lp-surface); border: 1px solid var(--lp-border); border-radius: 8px; }
.db-tiles a:hover { border-color: var(--lp-gold); }
.db-tiles strong { display: block; font-size: 28px; color: var(--lp-gold); }
.db-tiles span { display: block; font-size: 13px; color: var(--lp-muted); }

/* search page */
.facet-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; }
.facet-chips button { min-height: 36px; padding: 0 14px; font: inherit; font-size: 14px; color: var(--lp-text); background: var(--lp-surface); border: 1px solid var(--lp-border); border-radius: 999px; cursor: pointer; }
.facet-chips button[aria-pressed="true"] { color: #1a1a1a; background: var(--lp-gold); border-color: var(--lp-gold); }
.results { list-style: none; padding: 0; margin: 0; }
.results li { padding: 10px 0; border-bottom: 1px solid var(--lp-border); }
.results .type { display: inline-block; min-width: 4.5em; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--lp-muted); }
.results mark { background: none; color: var(--lp-gold); font-weight: 700; }
.results-note { color: var(--lp-muted); font-size: 14px; margin: 8px 0; }

@media (max-width: 600px) { .facts th { width: 8em; white-space: normal; } }

/* guides */
.database-page .asof { margin: -4px 0 6px; font-size: 13px; color: var(--lp-muted); }
.guide-tiles a strong { font-size: 18px; }
.guide-tiles a span { margin-top: 4px; }

/* tools + help wanted */
.tool-field { display: block; margin: 8px 0 14px; color: var(--lp-muted); font-size: 14px; }
.tool-field input, .tool-form input:not([type="checkbox"]), .tool-form select { display: block; margin-top: 4px; min-height: 40px; padding: 0 10px; font: inherit; color: var(--lp-text); background: var(--lp-surface); border: 1px solid var(--lp-border); border-radius: 6px; }
.tool-form { display: flex; flex-wrap: wrap; gap: 12px 18px; align-items: end; margin: 8px 0 16px; }
.tool-form label { color: var(--lp-muted); font-size: 14px; }
.tool-form label.inline { display: flex; align-items: center; gap: 8px; }
.tool-columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.plain-list { list-style: none; padding: 0; margin: 0; max-height: 480px; overflow-y: auto; }
.plain-list li { padding: 4px 0; }
.task-list { list-style: none; padding: 0; }
.task-list li { margin: 0 0 18px; padding: 14px 16px; background: var(--lp-surface); border: 1px solid var(--lp-border); border-radius: 8px; }
.task-list h2 { margin: 0 0 6px; font-size: 18px; }
.recipe { margin: 0 0 14px; }
.sources-table tfoot th { text-align: left; }
