/* ── Contributions v2 - Design: newswire-redesign (7)/css/contributions-v2.css ── */

.contributions-container {
    width: 100%;
}

/* Toolbar */
.contrib-toolbar {
    background: #fff;
    border-radius: 8px;
    border: 1px solid #cbd1e2;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.4vw;
    margin-bottom: 0.8vw;
}

.contrib-toolbar-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.contrib-toolbar-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.contrib-count {
    font-size: 13px;
    color: #667085;
}

.contrib-count strong {
    color: #4f6ef7;
}

.contrib-divider {
    width: 1px;
    height: 18px;
    background: #cbd1e2;
}

/* Filter Chips */
.contrib-chip {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
}

.contrib-chip:hover {
    transform: translateY(-0.05vw);
}

.contrib-chip[data-active="true"] {
    border-color: var(--chip-color-light);
    background: var(--chip-color-bg);
    color: var(--chip-color);
}

.contrib-chip[data-active="false"] {
    border: 1px solid #cbd1e2;
    background: #f0f1f3;
    color: #a0a5b2;
}

/* Sort Button */
.contrib-sort-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 6px;
    border: 1px solid #cbd1e2;
    background: transparent;
    font-size: 0.75vw;
    font-weight: 600;
    color: #667085;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
}

.contrib-sort-btn:hover {
    background: rgba(79,110,247,0.06);
}

.contrib-sort-btn svg {
    width: 16px;
    height: 16px;
}

/* List Card */
.contrib-list-card {
    background: #fff;
    border-radius: 8px;
    border: 1px solid #cbd1e2;
    overflow: hidden;
}

/* Rows */
.contrib-row {
    padding: 10px 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid #eef0f3;
    transition: all 0.2s;
    animation: contribFadeIn 0.3s ease both;
}

.contrib-row:last-child {
    border-bottom: none;
}

.contrib-row:hover {
    background: rgba(79,110,247,0.02);
}

.contrib-row:hover .contrib-link {
    color: #4f6ef7;
}

/* Row Icon */
.contrib-row-icon {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    border-radius: 8px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contrib-row-icon svg {
    width: 18px;
    height: 18px;
}

.contrib-row-icon-edit {
    background: rgba(79,110,247,0.1);
}
.contrib-row-icon-edit svg { color: #4f6ef7; }

.contrib-row-icon-article {
    background: rgba(236,72,153,0.1);
}
.contrib-row-icon-article svg { color: #ec4899; }

.contrib-row-icon-comment {
    background: rgba(139,92,246,0.1);
}
.contrib-row-icon-comment svg { color: #8b5cf6; }

/* Row Body */
.contrib-row-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0;
}

.contrib-row-text {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.2vw;
    overflow: hidden;
    min-width: 0;
}

.contrib-row-date-line {
    display: none;
    font-size: 13px;
    color: #667085;
    margin-top: 6px;
}

.contrib-username {
    font-size: 14px;
    font-weight: 700;
    color: #111318;
    flex-shrink: 0;
}

.contrib-action {
    font-size: 13px;
    color: #667085;
    flex-shrink: 0;
}

.contrib-link {
    font-size: 14px;
    font-weight: 600;
    color: #4f6ef7;
    text-decoration: none;
    transition: color 0.2s;
    flex: 1 1 0;
    min-width: 0;
    max-width: 60%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.contrib-link:hover {
    text-decoration: underline;
    color: #3d5ed9;
}

.contrib-row-chevron {
    display: none;
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    padding: 0;
    border: none;
    background: transparent;
    cursor: pointer;
    color: #a0a5b2;
    align-items: center;
    justify-content: center;
    transition: color 0.2s, transform 0.2s;
}

.contrib-row-chevron:hover {
    color: #4f6ef7;
}

.contrib-row-chevron svg {
    width: 18px;
    height: 18px;
}

.contrib-date,
.contrib-date-desktop {
    font-size: 12px;
    color: #a0a5b2;
    flex-shrink: 0;
    white-space: nowrap;
}

/* Restriction Row */
.contrib-restriction {
    border-left: 3px solid #ef4444;
    background: rgba(239,68,68,0.02);
    border-bottom: 1px solid #cbd1e2;
}

.contrib-restriction:last-child {
    border-bottom: none;
}

.contrib-restriction-main {
    padding: 0.55vw 0.75vw;
    display: flex;
    align-items: center;
    gap: 0.55vw;
    cursor: pointer;
}

.contrib-restriction-icon {
    width: 28px;
    height: 28px;
    min-width: 28px;
    min-height: 28px;
    border-radius: 0.35vw;
    flex-shrink: 0;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0.1vw 0.3vw rgba(239,68,68,0.2);
}

.contrib-restriction-icon svg {
    width: 16px;
    height: 16px;
    color: #fff;
}

.contrib-restriction-info {
    flex: 1;
    min-width: 0;
}

.contrib-restriction-label {
    font-size: 13px;
    font-weight: 700;
    color: #ef4444;
}

.contrib-restriction-name {
    font-size: 12px;
    font-weight: 600;
    color: #ef4444;
    background: rgba(239,68,68,0.08);
    padding: 0.08vw 0.3vw;
    border-radius: 0.2vw;
    margin-left: 0.3vw;
}

.contrib-restriction-date {
    font-size: 12px;
    color: rgba(239,68,68,0.55);
    flex-shrink: 0;
}

.contrib-restriction-chevron {
    width: 18px;
    height: 18px;
    color: #ef4444;
    flex-shrink: 0;
    transition: transform 0.3s;
}

.contrib-restriction-chevron.expanded {
    transform: rotate(180deg);
}

.contrib-restriction-details {
    padding: 0 14px 12px 36px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    border-top: 1px solid rgba(239,68,68,0.2);
    animation: contribFadeIn 0.3s ease;
}

.contrib-restriction-detail {
    display: flex;
    gap: 8px;
    font-size: 13px;
}

.contrib-restriction-detail-label {
    font-weight: 600;
    color: rgba(239,68,68,0.65);
    flex-shrink: 0;
}

.contrib-restriction-detail-value {
    color: rgba(239,68,68,0.8);
}

/* Empty */
.contrib-empty {
    padding: 4vw 2vw;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5vw;
}

.contrib-empty svg {
    width: 40px;
    height: 40px;
    color: #d0d3da;
}

.contrib-empty-title {
    font-size: 14px;
    font-weight: 600;
    color: #667085;
    margin: 0;
}

.contrib-empty-sub {
    font-size: 12px;
    color: #a0a5b2;
    margin: 0;
}

@keyframes contribFadeIn {
    from { opacity: 0; transform: translateY(0.2vw); }
    to { opacity: 1; transform: translateY(0); }
}

/* Pagination */
.contributions-pagination {
    margin-top: 1vw;
    display: flex;
    justify-content: center;
}

.contributions-pagination .pagination {
    display: flex;
    align-items: center;
    gap: 0.2vw;
}

.contributions-pagination .page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 8px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #667085;
    text-decoration: none;
    border: 1px solid #cbd1e2;
    background: #fff;
    transition: all 0.2s;
}

.contributions-pagination .page-btn:hover:not(.disabled):not(.active) {
    background: rgba(79,110,247,0.06);
    color: #4f6ef7;
}

.contributions-pagination .page-btn.active {
    background: #4f6ef7;
    color: #fff;
    border-color: #4f6ef7;
}

.contributions-pagination .page-btn.disabled {
    opacity: 0.5;
    cursor: default;
}

.contributions-pagination .page-btn svg {
    width: 18px;
    height: 18px;
}

.contributions-pagination .page-dots {
    padding: 0 0.2vw;
    font-size: 0.8vw;
    color: #a0a5b2;
}
