/* ============================================
   TWITTER / X SOCIAL FEED STYLES
   ============================================ */

/* Twitter feed no longer needs its own section styling - it's inside engagement grid */

.tweets-list-wrapper {
    max-height: 700px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 8px;
    scrollbar-width: thin;
    scrollbar-color: #FFB81C #e1e8ed;
}

.tweets-list-wrapper::-webkit-scrollbar {
    width: 8px;
}

.tweets-list-wrapper::-webkit-scrollbar-track {
    background: #e1e8ed;
    border-radius: 4px;
}

.tweets-list-wrapper::-webkit-scrollbar-thumb {
    background: #FFB81C;
    border-radius: 4px;
    transition: background 0.2s ease;
}

.tweets-list-wrapper::-webkit-scrollbar-thumb:hover {
    background: #e5a000;
}

.tweets-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.tweet-card {
    background: white;
    border: 1px solid #e1e8ed;
    border-radius: 12px;
    padding: 16px;
    transition: all 0.2s ease;
}

.tweet-card:hover {
    border-color: #cfd9de;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* Tweet Header */
.tweet-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
}

.tweet-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    flex-shrink: 0;
}

.tweet-author {
    flex: 1;
    min-width: 0;
}

.tweet-author-name {
    font-size: 15px;
    font-weight: 700;
    color: #0f1419;
    display: flex;
    align-items: center;
    gap: 4px;
}

.verified-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    background: #1d9bf0;
    color: white;
    border-radius: 50%;
    font-size: 12px;
    font-weight: bold;
}

.tweet-username {
    font-size: 15px;
    color: #536471;
    margin-top: 2px;
}

.tweet-time {
    font-size: 15px;
    color: #536471;
    white-space: nowrap;
    margin-left: auto;
}

/* Tweet Content */
.tweet-text {
    font-size: 15px;
    line-height: 1.5;
    color: #0f1419;
    margin-bottom: 12px;
    word-wrap: break-word;
}

.tweet-text a {
    color: #1d9bf0;
    text-decoration: none;
}

.tweet-text a:hover {
    text-decoration: underline;
}

/* Tweet Photos */
.tweet-photos {
    margin: 12px 0;
    border-radius: 12px;
    overflow: hidden;
}

.tweet-photos.single {
    max-height: 400px;
}

.tweet-photos.single .tweet-photo {
    width: 100%;
    height: auto;
    max-height: 400px;
    object-fit: cover;
    display: block;
}

.tweet-photos.grid {
    display: grid;
    gap: 2px;
    max-height: 280px;
}

.tweet-photos.grid.count-2 {
    grid-template-columns: 1fr 1fr;
}

.tweet-photos.grid.count-3 {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
}

.tweet-photos.grid.count-3 .tweet-photo:first-child {
    grid-row: span 2;
}

.tweet-photos.grid.count-4 {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
}

.tweet-photos.grid .tweet-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Tweet Footer */
.tweet-footer {
    display: flex;
    gap: 32px;
    padding-top: 12px;
    border-top: 1px solid #eff3f4;
}

.tweet-stat {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #536471;
}

.tweet-icon {
    font-size: 16px;
}

/* View on X Link */
.tweet-link {
    display: inline-block;
    margin-top: 12px;
    font-size: 13px;
    color: #1d9bf0;
    text-decoration: none;
    font-weight: 600;
}

.tweet-link:hover {
    text-decoration: underline;
}

/* Loading State */
.tweets-loading {
    text-align: center;
    padding: 40px 20px;
    color: #536471;
}

.tweets-loading .spinner {
    width: 40px;
    height: 40px;
    margin: 0 auto 16px;
    border: 3px solid #eff3f4;
    border-top-color: #1d9bf0;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Error State */
.tweets-error {
    text-align: center;
    padding: 40px 20px;
    color: #f4212e;
    background: #fff5f5;
    border-radius: 12px;
    border: 1px solid #fec7cb;
}

/* Empty State */
.tweets-empty {
    text-align: center;
    padding: 40px 20px;
    color: #536471;
    background: #f7f9f9;
    border-radius: 12px;
}

/* Responsive */
@media (max-width: 768px) {
    .tweets-list-wrapper {
        max-height: 600px;
    }

    .tweet-card {
        padding: 12px;
    }

    .tweet-avatar {
        width: 40px;
        height: 40px;
    }

    .tweet-author-name {
        font-size: 14px;
    }

    .tweet-username {
        font-size: 14px;
    }

    .tweet-time {
        font-size: 13px;
    }

    .tweet-text {
        font-size: 14px;
    }

    .tweet-footer {
        gap: 20px;
    }

    .tweet-stat {
        font-size: 13px;
    }

    /* Mobile photo adjustments */
    .tweet-photos.single {
        max-height: 300px;
    }

    .tweet-photos.single .tweet-photo {
        max-height: 300px;
    }

    .tweet-photos.grid {
        max-height: 220px;
    }
}
