/* ========================================
   RESEARCH ARCHIVE
======================================== */

.tms-research-archive {
    min-height: 70vh;
}


/* Hero */

.tms-research-hero {
    padding: 42px 0 34px;
    border-bottom: 1px solid var(--line);
}

.tms-research-kicker {
    margin: 0 0 12px;

    color: var(--blue);

    font-size: 11px;
    line-height: 1;
    font-weight: 800;

    letter-spacing: .12em;
}

.tms-research-hero h1 {
    margin: 0;

    color: var(--ink);

    font-size: 32px;
    line-height: 1.2;
    font-weight: 750;

    letter-spacing: -.035em;
}

.tms-research-intro {
    max-width: 680px;

    margin: 15px 0 0;

    color: var(--muted);

    font-size: 15px;
    line-height: 1.75;

    word-break: keep-all;
}


/* Filters */

.tms-research-filters {
    display: flex;
    flex-wrap: wrap;

    gap: 8px;

    margin-top: 25px;
}

.tms-research-filters a {
    display: inline-flex;
    align-items: center;

    min-height: 36px;

    padding: 8px 13px;

    border: 1px solid var(--line);
    border-radius: 8px;

    color: #475467;
    background: var(--white);

    font-size: 13px;
    font-weight: 650;
}

.tms-research-filters a:hover {
    color: var(--blue);
    border-color: #b9c9ed;
}

.tms-research-filters a.is-active {
    color: var(--white);
    border-color: var(--blue);
    background: var(--blue);
}


/* Results */

.tms-research-results {
    padding: 38px 0 64px;
}

.tms-research-grid {
    display: grid;

    grid-template-columns: 1fr;

    gap: 34px 20px;
}


/* Card */

.tms-research-card {
    min-width: 0;
}

.tms-research-card__media {
    display: flex;

    width: 100%;
    aspect-ratio: 16 / 10;

    overflow: hidden;

    align-items: center;
    justify-content: center;

    border: 1px solid var(--line);
    border-radius: 9px;

    background: var(--soft);
}

.tms-research-card__media img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: cover;

    transition: transform .2s ease;
}

.tms-research-card:hover
.tms-research-card__media img {
    transform: scale(1.015);
}

.tms-research-card__placeholder {
    color: #98a2b3;

    font-size: 12px;
    font-weight: 750;

    letter-spacing: .12em;
}

.tms-research-card__body {
    padding-top: 15px;
}

.tms-research-card__category {
    display: block;

    margin-bottom: 8px;

    color: var(--blue);

    font-size: 11px;
    font-weight: 750;

    letter-spacing: .02em;
}

.tms-research-card__title {
    margin: 0;

    color: var(--ink);

    font-size: 18px;
    line-height: 1.45;
    font-weight: 700;

    letter-spacing: -.025em;

    word-break: keep-all;
}

.tms-research-card__title a:hover {
    color: var(--blue);
}

.tms-research-card__date {
    display: block;

    margin-top: 9px;

    color: #98a2b3;

    font-size: 12px;
}

.tms-research-card__excerpt {
    margin: 11px 0 0;

    color: var(--muted);

    font-size: 13px;
    line-height: 1.7;

    word-break: keep-all;
}


/* Empty */

.tms-research-empty {
    padding: 65px 20px;

    border: 1px solid var(--line);
    border-radius: 8px;

    color: var(--muted);
    background: var(--soft);

    text-align: center;

    font-size: 14px;
}


/* Pagination */

.tms-pagination {
    margin-top: 52px;
}

.tms-pagination .nav-links,
.tms-pagination ul.page-numbers {
    display: flex;
    flex-wrap: wrap;

    justify-content: center;
    align-items: center;

    gap: 6px;

    margin: 0;
    padding: 0;

    list-style: none;
}

.tms-pagination ul.page-numbers li {
    margin: 0;
    padding: 0;
}

.tms-pagination a.page-numbers,
.tms-pagination span.page-numbers {
    display: inline-flex;

    width: auto;
    min-width: 38px;
    height: 38px;

    align-items: center;
    justify-content: center;

    padding: 0 11px;

    border: 1px solid var(--line);
    border-radius: 7px;

    color: #475467;
    background: var(--white);

    font-size: 13px;
    font-weight: 650;
}

.tms-pagination span.page-numbers.current {
    color: var(--white);

    border-color: var(--blue);
    background: var(--blue);
}

.tms-pagination a.page-numbers:hover {
    color: var(--blue);
    border-color: #b9c9ed;
}

/* Tablet */

@media (min-width: 700px) {

    .tms-research-hero {
        padding-top: 52px;
        padding-bottom: 42px;
    }

    .tms-research-hero h1 {
        font-size: 38px;
    }

    .tms-research-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));

        gap: 40px 24px;
    }
}


/* Desktop */

@media (min-width: 1000px) {

    .tms-research-hero {
        padding-top: 62px;
        padding-bottom: 48px;
    }

    .tms-research-hero h1 {
        font-size: 42px;
    }

    .tms-research-intro {
        font-size: 16px;
    }

    .tms-research-results {
        padding-top: 48px;
        padding-bottom: 78px;
    }

    .tms-research-grid {
        grid-template-columns:
            repeat(3, minmax(0, 1fr));

        gap: 48px 28px;
    }

    .tms-research-card__title {
        font-size: 19px;
    }
}


/* ==================================================
   TMS MOBILE ARCHIVE COMPACT V1
   Phone only. Desktop cards remain unchanged.
================================================== */

@media (max-width: 699px) {

    .tms-research-results {
        padding-top: 22px;
        padding-bottom: 52px;
    }

    .tms-research-grid {
        display: block;
    }


    /*
     * Compact horizontal research row.
     */
    .tms-research-card {
        display: grid;

        grid-template-columns:
            118px minmax(0, 1fr);

        gap: 14px;

        align-items: start;

        padding: 16px 0;

        border-bottom: 1px solid var(--line);
    }

    .tms-research-card:first-child {
        padding-top: 0;
    }

    .tms-research-card:last-child {
        border-bottom: 0;
    }


    /* Thumbnail */

    .tms-research-card__media {
        width: 118px;
        height: 82px;

        aspect-ratio: auto;

        border-radius: 7px;
    }

    .tms-research-card__media img {
        width: 100%;
        height: 100%;

        object-fit: cover;
    }

    .tms-research-card:hover
    .tms-research-card__media img {
        transform: none;
    }


    /* Text */

    .tms-research-card__body {
        min-width: 0;

        padding-top: 0;
    }

    .tms-research-card__category {
        margin-bottom: 5px;

        font-size: 10px;
        line-height: 1.25;
    }

    .tms-research-card__title {
        display: -webkit-box;

        margin: 0;

        overflow: hidden;

        font-size: 15px;
        line-height: 1.42;

        letter-spacing: -.025em;

        -webkit-box-orient: vertical;
        -webkit-line-clamp: 3;
    }

    .tms-research-card__date {
        margin-top: 7px;

        font-size: 11px;
    }


    /*
     * Archive is for discovery, not reading.
     * Hide long excerpt on phones.
     */
    .tms-research-card__excerpt {
        display: none;
    }


    /*
     * Keep pagination compact too.
     */
    .tms-pagination {
        margin-top: 34px;
    }

    .tms-pagination a.page-numbers,
    .tms-pagination span.page-numbers {
        min-width: 36px;
        height: 36px;

        padding: 0 9px;
    }
}


/*
 * Very narrow phones.
 */
@media (max-width: 380px) {

    .tms-research-card {
        grid-template-columns:
            104px minmax(0, 1fr);

        gap: 12px;
    }

    .tms-research-card__media {
        width: 104px;
        height: 74px;
    }

    .tms-research-card__title {
        font-size: 14px;

        -webkit-line-clamp: 3;
    }
}

/* === /TMS MOBILE ARCHIVE COMPACT V1 === */
