.bestiary-page {min-width:0;--bestiary-line:#63543a;--bestiary-text:#ebdbc0;}
.bestiary-hero {
    padding:clamp(16px,3vw,32px);margin-bottom:16px;border:1px solid var(--bestiary-line);
    background:linear-gradient(112deg,#242e22,#111a16 73%);color:var(--bestiary-text);
}
.bestiary-hero h1 {margin:0 0 8px;color:#fae7bf;font:600 clamp(31px,4.8vw,56px)/1.08 var(--serif,Georgia,serif);}
.bestiary-hero p {margin:0 0 14px;color:#d3c6ad;max-width:65ch;}
.bestiary-filters,.bestiary-actions,.bestiary-pagination {display:flex;flex-wrap:wrap;align-items:end;gap:10px;}
.bestiary-filters label {display:grid;gap:5px;flex:1 1 220px;min-width:0;color:#ecd3a2;font-weight:650;}
.bestiary-filters :is(input,select) {
    box-sizing:border-box;width:100%;min-width:0;min-height:44px;padding:7px 10px;border:1px solid #91774d;
    border-radius:4px;color:#f7e7c6;background:#171e18;font:inherit;
}
.bestiary-primary,.bestiary-button {
    display:inline-flex;align-items:center;justify-content:center;min-height:44px;padding:6px 13px;border:1px solid #937749;
    border-radius:4px;background:#23271c;color:#f0d9ad;text-decoration:none;cursor:pointer;font:inherit;
}
.bestiary-primary {background:#e1c18a;color:#241c10;border-color:#e1c18a;font-weight:700;}
.bestiary-primary:hover,.bestiary-button:hover {border-color:#f4d299;text-decoration:underline;text-underline-offset:.16em;}
.bestiary-page :is(a,button,input,select,summary):focus-visible {outline:3px solid #f4cb89;outline-offset:2px;}
.bestiary-status {color:#ccbea1;}
.bestiary-grid {display:grid;grid-template-columns:repeat(auto-fill,minmax(min(250px,100%),1fr));gap:10px;align-items:stretch;}
.bestiary-tile {
    display:flex;align-items:flex-start;gap:12px;min-width:0;padding:12px;color:var(--bestiary-text);
    border:1px solid var(--bestiary-line);border-radius:5px;background:#16201a;overflow-wrap:anywhere;
}
.bestiary-tile img {width:54px;height:79px;flex:none;object-fit:contain;background:#242b20;border-radius:4px;}
.bestiary-tile h2 {font-size:1.17rem;line-height:1.25;margin:0 0 3px;}
.bestiary-tile h2 a {display:block;padding:2px 0 6px;color:#f4ddb0;text-underline-offset:.18em;}
.bestiary-dungeon {color:#d8bf8e;text-underline-offset:.17em;}
.bestiary-tile p {margin:5px 0 0;color:#d9ccae;font-size:.9rem;}
.bestiary-tile p.bestiary-drop-preview {color:#bab49e;}
.bestiary-pagination {justify-content:center;align-items:center;margin:20px 0 6px;color:#dcceb3;}
.bestiary-profile {display:flex;align-items:center;gap:24px;overflow-wrap:anywhere;}
.bestiary-profile > img {width:clamp(62px,15vw,138px);max-height:190px;object-fit:contain;flex:none;background:#252c22;border-radius:4px;}
.bestiary-actions {align-items:center;}
.bestiary-section {min-width:0;margin:0 0 16px;padding:clamp(13px,2.25vw,23px);border:1px solid var(--bestiary-line);background:#151e18;color:var(--bestiary-text);scroll-margin-top:90px;}
.bestiary-section h2 {margin:0 0 11px;}
.bestiary-section p {margin:0 0 9px;color:#d8cdb6;}
.bestiary-details {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;}
.bestiary-combat-grid > div:only-child {grid-column:1 / -1;}
.bestiary-combat-grid h3 {margin:4px 0 9px;color:#f5dbab;}
.bestiary-combat-grid :is(ul,ol) {margin:0 0 10px;padding-inline-start:22px;overflow-wrap:anywhere;}
.bestiary-combat-grid li + li {margin-top:7px;}
.bestiary-area {padding:10px 0;border-top:1px solid var(--bestiary-line);}
.bestiary-area header {display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 12px;margin-bottom:8px;}
.bestiary-area h3 {margin:0;}
.bestiary-area header span {padding:2px 7px;border-radius:4px;background:#383327;color:#f5d8a3;font-size:.9rem;}
.bestiary-area summary {padding:6px 0;color:#edcf97;cursor:pointer;}
@media (max-width:640px) {
    .bestiary-profile {align-items:flex-start;gap:12px;flex-wrap:wrap;}
    .bestiary-details {grid-template-columns:minmax(0,1fr);gap:0;}
    .bestiary-filters label {flex-basis:100%;}
}
