/* Styles for dashboard page */
.stats {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
}
.stat {
    background: #fff;
    border: 1px solid #eaeaea;
    padding: 1rem;
    border-radius: 4px;
    flex: 1;
    text-align: center;
}
.recent {
    background: #fff;
    border: 1px solid #eaeaea;
    border-radius: 4px;
    padding: 1rem;
}
.recent ul {
    list-style: none;
    padding: 0;
    margin: 0;
}
.recent li {
    padding: 0;
    border-bottom: 1px solid #f1f1f1;
}

.recent li:last-child {
    border-bottom: 0;
}

.recent a {
    display: grid;
    grid-template-columns: 6rem 1fr;
    gap: 0.35rem 0.75rem;
    padding: 0.75rem 0;
    color: inherit;
    text-decoration: none;
}

.recent a:hover strong {
    color: #005fcc;
}

.activity-type {
    grid-row: span 2;
    align-self: start;
    width: fit-content;
    min-width: 4.6rem;
    padding: 0.18rem 0.45rem;
    border: 1px solid #d8dee9;
    border-radius: 999px;
    color: #475569;
    font-size: 0.8rem;
    font-weight: 700;
    text-align: center;
}

.recent strong {
    display: block;
}

.recent small {
    color: #5f6b7a;
}

.literature-feed {
    margin-bottom: 1.25rem;
    padding: 1rem;
    overflow: hidden;
    border: 1px solid #dce5ef;
    border-radius: 6px;
    background: #fff;
}

.literature-header {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: flex-start;
    margin-bottom: 0.9rem;
}

.literature-header h2,
.literature-header p {
    margin: 0;
}

.literature-header #literatureContext {
    margin-top: 0.25rem;
    color: #64748b;
}

.literature-header .literature-privacy {
    margin-top: 0.3rem;
    color: #7c8798;
    font-size: 0.75rem;
}

.section-kicker {
    color: #0f766e;
    font-size: 0.74rem;
    font-weight: 800;
    text-transform: uppercase;
}

.literature-controls {
    display: flex;
    gap: 0.45rem;
    align-items: flex-end;
    flex-wrap: wrap;
}

.literature-controls label {
    display: grid;
    gap: 0.2rem;
    margin: 0;
    color: #64748b;
    font-size: 0.75rem;
}

.literature-controls select {
    min-width: 9rem;
}

.icon-control {
    width: 2.5rem;
    min-width: 2.5rem;
    padding-inline: 0;
    font-size: 1.1rem;
}

.literature-track {
    display: grid;
    grid-auto-columns: minmax(18rem, 25rem);
    grid-auto-flow: column;
    gap: 0.8rem;
    overflow-x: auto;
    padding: 0.1rem 0 0.55rem;
    scroll-behavior: smooth;
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
}

.paper-card {
    display: grid;
    grid-template-rows: auto auto 1fr auto;
    gap: 0.55rem;
    min-height: 13rem;
    padding: 0.9rem;
    border: 1px solid #dce5ef;
    border-top: 3px solid #2f7f9f;
    border-radius: 6px;
    background: #fbfdff;
    color: inherit;
    text-decoration: none;
    scroll-snap-align: start;
}

.paper-card:hover {
    border-color: #2f7f9f;
    background: #fff;
}

.paper-card h3,
.paper-card p {
    margin: 0;
}

.paper-card h3 {
    font-size: 1rem;
    line-height: 1.35;
}

.paper-meta,
.paper-source {
    color: #64748b;
    font-size: 0.78rem;
}

.paper-summary {
    display: -webkit-box;
    overflow: hidden;
    color: #334155;
    line-height: 1.5;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 5;
}

.literature-empty {
    padding: 1rem;
    color: #64748b;
}

@media (max-width: 760px) {
    .stats,
    .literature-header {
        flex-direction: column;
    }

    .literature-controls {
        width: 100%;
    }

    .literature-track {
        grid-auto-columns: minmax(16rem, 88vw);
    }
}
