/* Equipment and bestiary: one title, one working toolbar, evidence on demand. */
body:is([data-page="items"],[data-page="enemies"]) .layout{display:block;max-width:1440px;margin:auto;padding:22px 28px}
body:is([data-page="items"],[data-page="enemies"]) .layout>main{min-width:0;padding:0}
body:is([data-page="items"],[data-page="enemies"]) .hero{display:block!important;padding:0!important;margin:12px 0 20px!important;min-height:0;background:none!important;border:0!important}
body:is([data-page="items"],[data-page="enemies"]) .hero h1{text-align:left!important;font-size:30px!important;margin:0 0 6px!important}
body:is([data-page="items"],[data-page="enemies"]) .hero>p:not(.eyebrow){text-align:left!important;margin:0;font-size:13px;color:var(--muted)}
body:is([data-page="items"],[data-page="enemies"]) .hero .eyebrow,body:is([data-page="items"],[data-page="enemies"]) .connections{display:none!important}
body:is([data-page="items"],[data-page="enemies"]) main>aside{position:static!important;width:100%!important;height:auto!important;min-height:0!important;max-height:none!important;padding:0!important;border:0!important;background:none!important;margin:0 0 18px!important}
body:is([data-page="items"],[data-page="enemies"]) main>aside>:not(#categories){display:none!important}
body:is([data-page="items"],[data-page="enemies"]) #categories{display:flex!important;gap:6px;flex-wrap:nowrap!important;overflow-x:auto;padding:0 0 8px;border-bottom:1px solid var(--line);scrollbar-width:thin}
body:is([data-page="items"],[data-page="enemies"]) #categories button{flex:0 0 auto;white-space:nowrap;width:auto!important;font-size:12px;padding:8px 12px;border-radius:4px;background:transparent;color:var(--muted);border:1px solid transparent}
body:is([data-page="items"],[data-page="enemies"]) #categories button.active{color:var(--accent);background:#eaf2f6;border-color:#c4d5df;font-weight:650}
#categories button>span{display:none}body:is([data-page="items"],[data-page="enemies"]) #categories small{margin-left:7px;color:inherit}
body:is([data-page="items"],[data-page="enemies"]) #catalog>.section-heading{display:none}
.catalog-toolbar{display:flex;align-items:flex-start;gap:10px;margin-bottom:10px;position:relative}
.catalog-toolbar #search-form{display:flex!important;gap:10px;flex:1;margin:0!important;min-width:0;padding:0!important;border:0!important}
.catalog-toolbar .search{flex:1;max-width:520px;min-width:0;background:#fff;border:1px solid var(--line);border-radius:4px;padding:8px 12px!important}
.catalog-toolbar .search input{font-size:14px!important;min-width:0}.catalog-toolbar #sort{font-size:12px;max-width:190px;min-width:130px;padding:8px}
.catalog-filter-panel{flex:0 0 auto}.catalog-filter-panel>summary{cursor:pointer;list-style:none;border:1px solid var(--line);border-radius:4px;background:white;font-size:13px;padding:9px 14px;white-space:nowrap}.catalog-filter-panel>summary::-webkit-details-marker{display:none}.catalog-filter-panel>summary:after{content:' ▾'}.catalog-filter-panel[open]>summary:after{content:' ▴'}
.catalog-filter-panel .filters{position:absolute;z-index:12;right:0;top:46px;display:flex;flex-wrap:wrap;gap:14px;width:min(640px,100%);padding:16px!important;background:#fff;box-shadow:0 8px 24px #19374720;border:1px solid var(--line);border-radius:5px;margin:0!important}
.catalog-filter-panel .filters label{display:grid;gap:5px;flex:1 1 160px;font-size:12px;color:var(--muted)}.catalog-filter-panel .filters select{width:100%;max-width:none;font-size:13px;min-height:35px}.catalog-filter-panel #reset{align-self:end;min-height:35px}
.active-filters{display:flex;flex-wrap:wrap;gap:6px;margin:10px 0}.active-filters[hidden]{display:none}.active-filters button{font-size:12px;color:var(--accent);background:#eaf2f6;border:1px solid #c4d5df;border-radius:4px;padding:5px 9px}.active-filters button span{margin-left:8px}
body:is([data-page="items"],[data-page="enemies"]) .result-bar{font-size:12px;margin:8px 0 12px;padding:0;color:var(--muted)}
.catalog-notes{border-top:1px solid var(--line);margin:24px 0 16px;padding:14px 0;font-size:12px;color:var(--muted)}.catalog-notes summary{cursor:pointer}.catalog-notes-body{padding-top:12px}.catalog-notes .hero-stats{display:flex!important;gap:22px;flex-wrap:wrap;margin:0 0 12px;padding:0;border:0}.catalog-notes .hero-stats strong{font-size:19px}.catalog-notes .hero-stats span{font-size:11px}.catalog-notes #coverage{margin:8px 0;padding:0;border:0}.catalog-notes #list-note{display:block;margin:8px 0}.catalog-notes a{color:var(--accent)}
/* Keep the familiar comparison columns, with more room for names and less visual noise. */
body[data-page="items"] .item-list-head,body[data-page="items"] .item-list-row{grid-template-columns:minmax(125px,1.05fr) 80px minmax(155px,1.4fr) minmax(140px,1fr) 110px minmax(140px,1.2fr) 48px!important;gap:12px!important}
body[data-page="items"] .item-list-row{padding:14px 12px!important}body[data-page="items"] .item-list-row h3{font-size:16px!important;font-weight:650!important;text-align:left!important;line-height:1.5}
body[data-page="items"] :is(.item-effect,.item-sources,.item-attributes){font-size:12px;line-height:1.7}.item-list-row:hover{background:#f3f7f9}
body[data-page="enemies"] .enemy-catalog-scroll{max-height:none!important;overflow:auto;border:1px solid var(--line);border-radius:4px}
body[data-page="enemies"] .enemy-catalog-table{min-width:1180px!important;table-layout:auto}
body[data-page="enemies"] .enemy-catalog-table :is(th,td){padding:12px 8px;font-size:12px;vertical-align:middle}
body[data-page="enemies"] .enemy-catalog-table th{font-weight:600;background:#edf3f6;color:var(--ink)}
body[data-page="enemies"] .enemy-catalog-table th:first-child{width:155px}
body[data-page="enemies"] .enemy-row-head{display:grid;grid-template-columns:42px minmax(78px,1fr);align-items:center;gap:5px 8px;min-width:135px;width:100%;text-decoration:none}
body[data-page="enemies"] .enemy-row-head .enemy-thumb{width:42px;height:42px;margin:0}
body[data-page="enemies"] .enemy-row-head h3{font-size:14px!important;white-space:normal!important;width:auto!important;max-width:none!important;line-height:1.5;margin:0;text-align:left!important}
body[data-page="enemies"] .enemy-row-head :is(small,.badge){grid-column:1/-1;width:auto!important}
body[data-page="enemies"] .enemy-catalog-table .enemy-traits p{font-size:12px;line-height:1.7}.enemy-catalog-table tbody tr:hover{background:#f3f7f9}.enemy-column-note{font-size:10px!important}
@media(max-width:700px){
 body:is([data-page="items"],[data-page="enemies"]) .layout{padding:16px}.catalog-toolbar{flex-wrap:wrap;gap:8px}.catalog-toolbar #search-form{flex-basis:100%;gap:7px}.catalog-toolbar .search{padding:8px!important}.catalog-toolbar #sort{min-width:100px;width:110px;font-size:11px}.catalog-filter-panel{width:100%}.catalog-filter-panel>summary{width:fit-content;padding:7px 12px}.catalog-filter-panel .filters{position:static;box-shadow:none;width:100%;margin-top:8px!important;padding:12px!important}.catalog-toolbar .search kbd{display:none}
 body[data-page="items"] .list-table{min-width:0!important;overflow:visible!important;border:0;background:none}
 body[data-page="items"] .item-list-head{display:none!important}
 body[data-page="items"] .item-list-row{display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;grid-template-areas:'name kind' 'effect effect' 'stats stats' 'price open' 'sources sources';gap:10px!important;margin-bottom:12px;border:1px solid var(--line);border-radius:5px;background:white;padding:14px!important;min-width:0!important}
 .item-list-row>.row-head{grid-area:name}.item-list-row>.item-kind{grid-area:kind}.item-list-row>.item-effect{grid-area:effect}.item-list-row>.item-attributes{grid-area:stats;display:flex!important;flex-wrap:wrap;gap:8px 12px}.item-list-row>.item-price{grid-area:price;display:flex;flex-wrap:wrap;gap:12px}.item-list-row>.item-sources{grid-area:sources;border-top:1px solid var(--line);padding-top:8px}.item-list-row>.item-open{grid-area:open;align-self:center}.item-list-row .item-effect:before{content:'效果 · ';color:var(--muted)}
 body[data-page="enemies"] .enemy-catalog-scroll{border:0;overflow:visible!important;background:none}
 body[data-page="enemies"] .enemy-catalog-table{display:block;min-width:0!important;width:100%!important}.enemy-catalog-table thead{display:none}body[data-page="enemies"] .enemy-catalog-table tbody{display:block}
 body[data-page="enemies"] .enemy-catalog-table tr{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-bottom:12px;padding:14px;border:1px solid var(--line);border-radius:5px;background:white}
 body[data-page="enemies"] .enemy-catalog-table td{display:block;padding:0;border:0;min-width:0;font-size:13px}body[data-page="enemies"] .enemy-catalog-table td:before{content:attr(data-label);display:block;font-size:11px;color:var(--muted);margin-bottom:4px}
 body[data-page="enemies"] .enemy-catalog-table td:first-child{grid-column:1/-1;padding-bottom:10px;border-bottom:1px solid var(--line)}body[data-page="enemies"] .enemy-catalog-table td:first-child:before{display:none}
 body[data-page="enemies"] .enemy-catalog-table td:is(:nth-child(6),:nth-child(10),:last-child){grid-column:1/-1}body[data-page="enemies"] .enemy-row-head{grid-template-columns:48px 1fr;min-width:0}body[data-page="enemies"] .enemy-row-head h3{font-size:17px!important}
 .enemy-catalog-table td:last-child a{display:block;text-align:center;padding:8px;background:#edf3f6;border-radius:4px}.enemy-catalog-table td:last-child:before{display:none!important}
}
.catalog-toolbar .catalog-filter-panel{margin:0;padding:0;border:0;min-height:0}.catalog-toolbar .catalog-filter-panel>summary{line-height:1.5}.catalog-toolbar:has(.catalog-filter-panel[open]){margin-bottom:140px}@media(max-width:700px){.catalog-toolbar:has(.catalog-filter-panel[open]){margin-bottom:10px}}
.catalog-toolbar:has(.catalog-filter-panel[open]){flex-wrap:wrap;margin-bottom:10px}.catalog-filter-panel[open]{flex-basis:100%}.catalog-filter-panel .filters{position:static;width:100%;max-width:none;box-shadow:none;margin-top:8px!important}.catalog-filter-panel[open]>summary{width:fit-content}
