.reference { max-width:1200px; margin:auto; }
.reference h1 { font:48px/1.15 Georgia,serif; color:var(--fg); margin:10px 0 14px; }
.reference-intro { max-width:75ch; font-size:17px; color:var(--muted); }
.reference-tabs { display:flex; flex-wrap:wrap; gap:20px; border-bottom:1px solid var(--line); padding:18px 0; margin-bottom:24px; }
.reference-tabs a { text-decoration:none; padding:8px 0; }
.reference-tabs a[aria-current=page] { border-bottom:2px solid var(--accent); color:var(--fg); }
.reference-controls { display:flex; flex-wrap:wrap; align-items:end; gap:14px; margin:20px 0; }
.reference-controls label { display:flex; flex-direction:column; gap:5px; font-size:13px; color:var(--muted); }
.reference-controls label:first-child { flex:1 1 220px; }
.reference input,.reference select,.reference button { font:inherit; padding:10px 12px; border:1px solid #62586d; border-radius:5px; background:var(--panel); color:var(--fg); }
.reference button { cursor:pointer; }
#reference-count { font-size:13px; color:var(--muted); padding:10px 0; }
.reference-layout { display:grid; grid-template-columns:260px minmax(0,1fr); gap:24px; align-items:start; }
#reference-list { max-height:75vh; overflow:auto; border:1px solid var(--line); border-radius:6px; position:sticky; top:80px; }
#reference-list a { display:block; color:var(--fg); text-decoration:none; padding:14px 18px; border-bottom:1px solid var(--line); }
#reference-list a:hover { background:#1d1923; }
#reference-list a[aria-current=true] { background:#251d30; box-shadow:inset 3px 0 var(--accent); }
#reference-list small { display:block; color:var(--muted); }
#reference-detail { min-width:0; background:var(--panel); border:1px solid var(--line); border-radius:6px; padding:24px; }
#reference-detail h2 { font:36px/1.2 Georgia,serif; margin:6px 0 20px; }
#reference-detail h3 { font-size:19px; margin:28px 0 12px; color:var(--fg); }
.reference-description { white-space:pre-line; max-width:68ch; overflow-wrap:anywhere; }
#reference-detail > p { max-width:68ch; }
#reference-title { width:fit-content; max-width:100%; }
.reference-facts { display:grid; grid-template-columns:repeat(3,1fr); gap:1px; max-width:48rem; background:var(--line); margin:20px 0; border:1px solid var(--line); }
.reference-facts div { padding:14px; background:var(--panel); }
.reference-facts dt { color:var(--muted); font-size:12px; }
.reference-facts dd { margin:5px 0 0; font-size:19px; }
.reference-table-wrap { overflow:auto; }
.reference table { width:auto; max-width:100%; border-collapse:collapse; }
.reference th,.reference td { text-align:left; padding:9px 28px 9px 0; border-bottom:1px solid var(--line); vertical-align:top; }
.reference th { font-size:12px; color:var(--muted); }
.reference th:last-child,.reference td:last-child { padding-right:0; }
.reference td { overflow-wrap:anywhere; }
.reference-footnote { color:var(--muted); font-size:13px; margin-top:28px; }
.reference-pills { display:flex; flex-wrap:wrap; gap:10px; }
.reference-pills a { border:1px solid #62586d; border-radius:4px; padding:6px 10px; text-decoration:none; }
.reference-back { font-size:13px; }
.reference [hidden] { display:none!important; }
@media(max-width:760px) { .reference-layout { grid-template-columns:1fr; } #reference-list { position:static; max-height:240px; } .reference h1 { font-size:36px; } #reference-detail { padding:20px; } .reference-facts { grid-template-columns:repeat(2,1fr); } .reference-controls label { flex:1 1 130px; } }
