/* Thundera Models — page-specific styles only. Chrome, type, buttons, cards, code and docs
   layout come from Thundera Shell v2 (https://thundera.eu/shell/v2/). */

/* alias cards */
.alias-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: var(--th-space-4); }
.alias-card { display: flex; flex-direction: column; gap: 8px; padding: 18px; }
.alias-card header { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.alias-card h3 { color: var(--brand-accent); }
.alias-card p { margin: 0; }
.alias-now strong { display: block; font-size: .9375rem; }
.alias-chain { list-style: none; margin: auto 0 0; padding: 10px 0 0; border-top: 1px solid var(--th-border); display: grid; gap: 3px; font-size: .75rem; color: var(--th-text-3); counter-reset: c; }
.alias-chain li { counter-increment: c; display: flex; gap: 8px; }
.alias-chain li::before { content: counter(c); flex: none; width: 16px; height: 16px; border-radius: 50%; background: var(--th-surface-3); color: var(--th-text-2); font-size: .625rem; font-weight: 700; display: grid; place-items: center; margin-top: 1px; }
.alias-chain li:first-child { color: var(--th-text-2); }
.catalog-head { margin: 56px 0 18px; max-width: none; }
.catalog-head p { margin: 6px 0 0; }

/* model tables (landing + docs) */
.table-tools { display: flex; align-items: center; gap: 14px; margin: 14px 0; flex-wrap: wrap; }
.filter-input { width: min(100%, 380px); height: 40px; padding: 0 14px; border-radius: var(--th-radius-sm); border: 1px solid var(--th-border-2); background: var(--th-surface-1); color: var(--th-text); font: .9375rem var(--th-font-sans); }
.filter-input:focus { outline: none; border-color: var(--brand-accent); box-shadow: 0 0 0 3px var(--brand-soft); }
.tbl { overflow: auto; max-width: 100%; max-height: 640px; border: 1px solid var(--th-border); border-radius: var(--th-radius-md); background: var(--th-surface-1); -webkit-overflow-scrolling: touch; }
.tbl-tall { max-height: 560px; }
.tbl table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: .875rem; display: table; margin: 0; }
.tbl th, .tbl td { padding: 10px 14px; text-align: left; vertical-align: top; border: 0; border-bottom: 1px solid var(--th-border); }
.tbl thead th { position: sticky; top: 0; z-index: 1; background: var(--th-surface-2); font-size: .75rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--th-text-2); white-space: nowrap; }
.tbl tbody tr:last-child > * { border-bottom: 0; }
.tbl tbody tr:hover { background: var(--th-hover); }
.tbl tbody th { font-weight: 600; }
.tbl .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tbl tr[hidden] { display: none; }
#model-table td code, #model-table th code { white-space: nowrap; }
.tbl-wide td, .tbl-wide th { overflow-wrap: anywhere; }
.mname { display: block; font-weight: 600; }
.mid { display: block; font-size: .75rem; font-weight: 400; color: var(--th-text-3); overflow-wrap: anywhere; }
.health { font-size: .8125rem; font-weight: 600; }
.health-ok { color: var(--th-success-text); } .health-degraded { color: var(--th-danger-text); } .health-unknown { color: var(--th-text-3); }
.th-prose .tbl { margin: 16px 0; }
.th-prose .tbl th, .th-prose .tbl td { color: var(--th-text-2); }
.th-prose .tbl tbody th { color: var(--th-text); }
.tbl table { min-width: 520px; }

/* landing */
.code-pair { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; }
.code-pair > * { min-width: 0; }
.th-hero-grid > * { min-width: 0; }
.th-media pre { font-size: 12.5px; }
@media (max-width: 899px) { .code-pair { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 560px) { .th-hero-actions .th-btn { flex: 1 1 100%; } .tbl th, .tbl td { padding: 9px 10px; } }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.feat-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 640px) { .feat-4 { grid-template-columns: minmax(0, 1fr); } }
.th-prose .tbl-wide td code, .th-prose .tbl-wide tbody th { white-space: normal; }
.th-prose .tbl-wide tbody th { background: none; }
.tbl-wide table { min-width: 0; }
.tbl-wide td, .tbl-wide th { padding: 10px 12px; }
@media (max-width: 640px) { .tbl-wide table { min-width: 560px; } }
.th-prose .tbl-wide tbody th code { white-space: nowrap; }

/* Docs: tables whose cells are mostly inline code wrap instead of clipping on phones. */
.wrap-codes td:first-child code { white-space: nowrap; }
.wrap-codes td:first-child .th-small { display: inline-block; margin-top: 4px; }
.wrap-codes td + td code { white-space: normal; overflow-wrap: anywhere; }
/* 404 page */
.nf { min-height: 60vh; display: flex; align-items: center; }
.nf .th-lede { margin-inline: auto; }
.nf img { display: block; margin: 0 auto; }
.nf-actions { justify-content: center; }
