/* ============================================================================
   LCD — home page

   The mockup's home is a lean hero + stat strip + one table. The live home also
   carries the agent directory, ~40 category links and the benchmark lists,
   which are the crawl-distribution surface for 15k model pages. Those stay
   (plan D5); the hero sits above them.
   ========================================================================= */

.lcd-hero {
    padding: 8px 0 30px;
    box-shadow: inset 0 -1px 0 var(--lcd-border);
    margin-bottom: 0;
}

.lcd-hero__eyebrow {
    font-family: var(--lcd-font-data);
    font-size: var(--fs-micro);
    letter-spacing: .28em;
    text-transform: uppercase;
    color: var(--lcd-fg-faint);
    margin: 0 0 12px;
}

/* The H1 string is unchanged from the pre-redesign page: it is the primary
   organic landing target and is not replaced by the mockup's question line. */
.lcd-hero__title {
    font-size: 26px !important;
    font-weight: 600;
    line-height: 1.15;
    letter-spacing: -.01em;
    max-width: 940px;
    margin: 0 0 14px;
}

/* Small caption inviting the visitor to use the search form below it. */
.lcd-hero__prompt {
    font-family: var(--lcd-font-data);
    font-size: var(--fs-key);
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--lcd-fg-dim);
    margin: 0 0 8px;
}

.lcd-hero__sub {
    font-size: var(--fs-body);
    line-height: 1.55;
    color: var(--lcd-fg-dim);
    max-width: 800px;
    margin: 0 0 20px;
}

.lcd-hero__quick {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 16px;
}

@media (max-width: 768px) {
    .lcd-hero__title {
        font-size: 21px !important;
    }
}

/* The search box component lives in lcd-components.css: the same form is
   rendered on the home, list and model pages. */

/* ------------------------------------------------------------ stat strip */

.lcd-statstrip {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    background: var(--lcd-panel);
    box-shadow: inset 0 -1px 0 var(--lcd-border);
    margin: 0 -28px 30px;
    padding: 0 28px;
}

.lcd-statstrip__item {
    display: block;
    padding: 16px 18px 16px 0;
    color: var(--lcd-fg);
    text-decoration: none !important;
}

.lcd-statstrip__item:hover {
    color: var(--lcd-fg);
}

.lcd-statstrip__item:hover .lcd-num {
    color: var(--lcd-accent-bright);
}

.lcd-statstrip__label {
    display: block;
    margin-top: 5px;
    font-family: var(--lcd-font-data);
    font-size: var(--fs-micro);
    letter-spacing: .2em;
    text-transform: uppercase;
    color: var(--lcd-fg-faint);
}

@media (max-width: 768px) {
    .lcd-statstrip {
        grid-template-columns: repeat(2, 1fr);
        margin: 0 -14px 24px;
        padding: 0 14px;
    }
}

/* ------------------------------------------------------------- subscribe */

.lcd-subscribe {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px 14px;
    margin-bottom: 36px;
}

.lcd-subscribe form {
    display: flex;
    gap: 8px;
    margin: 0;
}

#email_subscribe {
    width: 240px !important;
    margin: 0 !important;
}

/* ------------------------------------------------- top tables / pillows */

.pillow_container {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.toptable_container {
    display: block;   /* llm.css makes this a flex row, which gaps the header off the table */
    /* Fluid tier instead of a 33% floor with a cliff at 1120px: a panel needs
       ~430px for its columns to stay readable, so the row wraps 3 -> 2 -> 1
       as the viewport narrows instead of crushing the cells to "33…". */
    flex: 1 1 430px;
    max-width: 100%;
    min-width: 0;
    margin-bottom: 26px;
    border: 1px solid var(--lcd-border);
    background: var(--lcd-panel);
    padding: 0;
    overflow: hidden;
}

.toptable_container > h2 {
    margin: 0;
    padding: 9px 12px;
    background: var(--lcd-well);
    box-shadow: inset 0 -1px 0 var(--lcd-border);
    font-family: var(--lcd-font-data);
    font-size: var(--fs-micro) !important;
    font-weight: 500;
    letter-spacing: .18em;
    text-transform: uppercase;
    color: var(--lcd-fg-dim) !important;
    flex: 0 0 100%;
}

.toptable_container > table {
    margin: 0;
}

/* Five columns share ~500px here; one step down from the global header size
   keeps the bold style without truncating "Downloads" to "Downloa…". */
.toptable_container .table thead th {
    font-size: var(--fs-micro);
    letter-spacing: .05em;
}

/* Numbers must never truncate ("334,2…"): llm.css pins these tables to
   table-layout:fixed with % columns, which crushes cells at narrow panel
   widths. Auto layout instead — data columns size to their content and the
   name column absorbs all the slack; it is the only cell allowed to
   ellipsize (width:99% + max-width:0). */
.toptable_container > .table,
.toptable_container .table {
    table-layout: auto !important;
}

.toptable_container .table th,
.toptable_container .table td {
    width: auto !important;
    white-space: nowrap;
}

.toptable_container .table th:first-child,
.toptable_container .table td:first-child {
    width: 99% !important;
    max-width: 0;            /* enables ellipsis inside auto table layout */
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Long SPDX ids ("GPL-3.0-or-later") get a modest cap so they don't squeeze
   the name column to nothing. */
.toptable_container .table th:last-child,
.toptable_container .table td:last-child {
    max-width: 92px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.toptable_container > .back_button,
.toptable_container > a.back_button {
    margin: 10px 12px 12px;
}

/* --------------------------------------------------------- summary stats */

.lcd-summary {
    max-width: 460px;
    margin-bottom: 40px;
}

.lcd-summary .table {
    margin: 0;
}

.lcd-summary .table td:last-child {
    text-align: right;
}

/* Category tiles */
.pill_bench {
    min-width: 280px;
    flex: 0 1 auto;
}

.model_list_pillow {
    width: 240px;
    height: 88px;
}

/* Benchmark category links carry a second line of small print. */
.pill_bench .font_small {
    display: block;
    margin-top: 3px;
    font-size: var(--fs-micro);
    letter-spacing: .04em;
    color: var(--lcd-fg-faint);
    text-transform: none;
}
