/* ===== GuiLei List — SO s-post-summary ===== */

/* Constrain main content column to SO-like fixed width */
.gl-main-col {
    max-width: 728px;
}

.gl-summary {
    display: flex;
    flex-direction: column;
    padding: var(--su12);
    border-bottom: 1px solid var(--so-black-150);
    background: var(--so-white);
    position: relative;
}

.gl-summary:last-child {
    border-bottom: none;
}

/* ---- Stats column ---- */

.gl-summary--stats {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: var(--su4);
    flex-shrink: 0;
    margin-bottom: var(--su2);
    color: var(--fc-light);
}

.gl-stat {
    display: inline-flex;
    gap: var(--su6);
    align-items: baseline;
    white-space: nowrap;
}

.gl-stat--value {
    font-size: var(--fs-caption);
    font-weight: 600;
    color: var(--fc-medium);
}

/* 状态标签 — 对标 SO has-answers / has-accepted-answer */
.gl-stat--status {
    font-size: var(--fs-caption);
    font-weight: 600;
    padding: 1px var(--su4);
    border-radius: var(--br-sm);
    white-space: nowrap;
}

.gl-stat--status.is-open {
    background: var(--so-green-400);
    color: #fff;
}

.gl-stat--status {
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

.gl-stat--checkmark {
    flex-shrink: 0;
    fill: currentColor;
}

.gl-stat--status.is-closed {
    border: 1px solid var(--so-black-300);
    color: var(--fc-medium);
}

.gl-stat--status.is-expired {
    border: 1px solid var(--so-red-400);
    color: var(--so-red-400);
}

.gl-stat--status.is-paid {
    background: var(--so-yellow-200);
    color: var(--so-black-500);
}

.gl-stat--label {
    font-size: var(--fs-caption);
    color: var(--fc-light);
}

/* ---- Content column ---- */

.gl-summary--content {
    flex: 1;
    min-width: 0;
}

.gl-summary--content-title {
    font-size: var(--fs-body2);
    font-weight: 400;
    line-height: var(--lh-sm);
    margin: 0 0 var(--su4);
    padding-right: var(--su24);
}

.gl-summary--content-title a {
    color: var(--bs-link-color);
    text-decoration: none;
    word-break: break-word;
}

.gl-summary--content-title a:hover {
    color: var(--bs-link-hover-color);
}

/* ---- Excerpt ---- */

.gl-summary--content-excerpt {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    color: var(--fc-medium);
    margin: -var(--su2) 0 var(--su4);
    font-size: var(--fs-caption);
    line-height: var(--lh-sm);
}

/* ---- Meta row: tags 左 + user-card 右 — 对标 SO ---- */

.gl-summary--meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    column-gap: var(--su6);
    row-gap: var(--su4);
}

/* ---- Tags — 对标 SO s-tag ---- */

.gl-summary--tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--su4);
}

.gl-tag {
    display: inline-flex;
    align-items: center;
    font-size: var(--fs-caption);
    font-weight: 700;
    line-height: 1.846;
    color: var(--so-black-500);
    background-color: var(--so-black-150);
    border: 1px solid var(--so-black-200);
    border-radius: var(--br-sm);
    padding: 0 var(--su4);
    white-space: nowrap;
    text-decoration: none;
}

/* ---- User card — 对标 SO s-user-card__minimal (Flex) ---- */

.gl-user-card {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--su4);
    margin-left: auto;
    line-height: var(--lh-sm);
}

.gl-user-card--avatar {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    border-radius: var(--br-sm);
    object-fit: cover;
    font-size: 10px;
}

.gl-user-card--info {
    display: flex;
    align-items: center;
    gap: var(--su4);
}

.gl-user-card--name {
    font-size: var(--fs-caption);
    color: var(--bs-link-color);
}

.gl-user-card--time {
    font-size: var(--fs-caption);
    color: var(--fc-light);
    white-space: nowrap;
}

/* ---- Desktop ---- */

@media (min-width: 768px) {
    .gl-summary {
        flex-direction: row;
        align-items: baseline;
    }

    .gl-summary--stats {
        flex-direction: column;
        align-items: flex-end;
        width: calc(var(--su96) + var(--su12));
        margin-right: var(--su12);
        gap: var(--su4);
        margin-bottom: 0;
    }

}

/* ---- Empty state ---- */

.gl-empty {
    text-align: center;
    padding: var(--su32) var(--su16);
    color: var(--so-black-400);
    font-size: var(--fs-body1);
}
