/* ============================================================
   Social Feed Styles
   ============================================================ */

/* ── Feed Page Layout ── */
.feed-page {
    max-width: 640px;
    margin: 0 auto;
    padding: 0 0 40px;
}

/* ── Header ── */
.feed-header {
    margin-bottom: 20px;
}
.feed-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 4px;
}
.feed-subtitle {
    font-size: 0.88rem;
    color: var(--text-muted);
    margin: 0;
}

/* ── Tabs ── */
.feed-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 16px;
    padding: 4px;
    background: var(--bg-secondary);
    border-radius: 10px;
    border: 1px solid var(--border-color);
}
.feed-tab {
    flex: 1;
    padding: 8px 14px;
    border: none;
    background: none;
    color: var(--text-muted);
    font-size: 0.82rem;
    font-weight: 600;
    border-radius: 7px;
    cursor: pointer;
    transition: all 0.2s;
}
.feed-tab:hover {
    color: var(--text-primary);
    background: rgba(255,255,255,0.04);
}
.feed-tab.active {
    background: rgba(255,255,255,0.08);
    color: var(--text-primary);
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

/* ── Feed List ── */
.feed-container {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* ── Empty State ── */
.feed-page .empty-state {
    text-align: center;
    padding: 60px 24px;
    color: var(--text-secondary);
}
.feed-page .empty-icon {
    color: var(--text-muted);
    opacity: 0.5;
    margin-bottom: 8px;
}
.feed-page .empty-state h3 {
    margin: 12px 0 8px;
    color: var(--text-primary);
    font-size: 1.1rem;
}
.feed-page .empty-state p {
    font-size: 0.88rem;
    color: var(--text-muted);
}
.feed-page .empty-state a {
    color: var(--accent-primary);
    font-weight: 600;
    text-decoration: none;
}
.feed-page .empty-state a:hover { text-decoration: underline; }

/* ── Load More ── */
.feed-load-more {
    text-align: center;
    padding: 16px;
}

/* ── Animations ── */
.feed-item-new {
    animation: feedSlideIn 0.4s ease-out;
}
@keyframes feedSlideIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ── Filter visibility ── */
.activity-card.feed-hidden {
    display: none !important;
}


/* ============================================================
   Activity Card
   ============================================================ */

/* ── Card Shell ── */
.activity-card {
    display: flex;
    gap: 12px;
    padding: 16px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    transition: background 0.15s;
}
.activity-card:first-child {
    border-radius: 12px 12px 0 0;
}
.activity-card:last-child,
.activity-card:last-of-type {
    border-bottom: none;
    border-radius: 0 0 12px 12px;
}
.activity-card:only-child,
.activity-card:first-child:last-of-type {
    border-radius: 12px;
}
.activity-card:hover {
    background: rgba(255,255,255,0.02);
}
.activity-card.card-win {
    border-left: 3px solid var(--accent-primary, #238636);
}
.activity-card.card-loss {
    border-left: 3px solid #ef4444;
}
.activity-card.card-streak {
    border-left: 3px solid #f59e0b;
}


/* ── Avatar ── */
.activity-avatar,
.activity-avatar-img {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    flex-shrink: 0;
    object-fit: cover;
}
.activity-avatar {
    background: linear-gradient(135deg, #238636 0%, #2ea043 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.95rem;
}
.activity-avatar.av-win {
    background: linear-gradient(135deg, #16a34a 0%, #22c55e 100%);
}
.activity-avatar.av-loss {
    background: linear-gradient(135deg, #b91c1c 0%, #ef4444 100%);
}
.activity-avatar.av-streak {
    background: linear-gradient(135deg, #d97706 0%, #f59e0b 100%);
}


/* ── Header ── */
.activity-body {
    flex: 1;
    min-width: 0;
}
.activity-header {
    margin-bottom: 6px;
}
.activity-user-row {
    display: flex;
    align-items: center;
    gap: 5px;
    flex-wrap: wrap;
}
.activity-user {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-primary);
    text-decoration: none;
}
.activity-user:hover { text-decoration: underline; }
.verified-badge { flex-shrink: 0; }
.activity-dot {
    color: var(--text-muted);
    font-size: 0.7rem;
    line-height: 1;
}
.activity-time {
    font-size: 0.78rem;
    color: var(--text-muted);
    white-space: nowrap;
}


/* ============================================================
   Bet Slip (placed pick)
   ============================================================ */
.activity-bet-slip {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.slip-header {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.sport-tag {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    padding: 2px 7px;
    border-radius: 4px;
    text-transform: uppercase;
    flex-shrink: 0;
}
.sport-nba  { background: rgba(200, 16, 46, 0.2); color: #f87171; }
.sport-ncaab { background: rgba(59, 130, 246, 0.2); color: #60a5fa; }
.sport-nfl  { background: rgba(0, 53, 148, 0.2); color: #93c5fd; }
.sport-nhl  { background: rgba(99, 102, 241, 0.2); color: #a5b4fc; }
.sport-mlb  { background: rgba(220, 38, 38, 0.2); color: #fca5a5; }
.sport-ufc  { background: rgba(220, 38, 38, 0.2); color: #fca5a5; }
.slip-game {
    font-size: 0.78rem;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
}
.slip-pick-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}
.slip-pick {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.slip-odds {
    font-family: var(--font-mono, monospace);
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--text-primary);
    background: rgba(255,255,255,0.06);
    padding: 3px 10px;
    border-radius: 6px;
    white-space: nowrap;
    flex-shrink: 0;
}
.slip-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.75rem;
    color: var(--text-muted);
}
.slip-type {
    background: rgba(255,255,255,0.06);
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    font-weight: 600;
}


/* ============================================================
   Result Slip (won/lost)
   ============================================================ */
.activity-result-slip {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 12px 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}
.activity-result-slip.won {
    border-color: rgba(34, 197, 94, 0.3);
    background: rgba(34, 197, 94, 0.06);
}
.activity-result-slip.lost {
    border-color: rgba(239, 68, 68, 0.25);
    background: rgba(239, 68, 68, 0.05);
}
.result-left {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 8px;
    flex: 1;
    min-width: 0;
}
.result-pick {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.result-score {
    width: 100%;
    font-size: 0.75rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.result-right {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}
.result-badge {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.72rem;
}
.result-badge.won {
    background: var(--accent-primary, #238636);
    color: white;
}
.result-badge.lost {
    background: #ef4444;
    color: white;
}
.result-pnl {
    font-family: var(--font-mono, monospace);
    font-weight: 700;
    font-size: 0.95rem;
}
.result-pnl.won { color: #22c55e; }
.result-pnl.lost { color: #ef4444; }


/* ============================================================
   Streak Banner
   ============================================================ */
.streak-banner {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.92rem;
}
.streak-banner.streak-hot {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.12) 0%, rgba(245, 158, 11, 0.08) 100%);
    color: #fbbf24;
    border: 1px solid rgba(251, 191, 36, 0.2);
}
.streak-banner.streak-cold {
    background: linear-gradient(135deg, rgba(147, 197, 253, 0.12) 0%, rgba(96, 165, 250, 0.08) 100%);
    color: #93c5fd;
    border: 1px solid rgba(147, 197, 253, 0.2);
}
.streak-icon {
    font-size: 1.2rem;
    line-height: 1;
}


/* ============================================================
   Follow / Group Events
   ============================================================ */
.follow-event {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.88rem;
    color: var(--text-secondary);
    padding: 4px 0;
}
.follow-event svg { color: var(--text-muted); flex-shrink: 0; }
.follow-event strong { color: var(--text-primary); }

.activity-action-text {
    font-size: 0.85rem;
    color: var(--text-secondary);
}


/* ============================================================
   Engagement Row
   ============================================================ */
.activity-engage {
    display: flex;
    align-items: center;
    gap: 2px;
    margin-top: 10px;
    padding-top: 8px;
    border-top: 1px solid rgba(255,255,255,0.05);
}
.engage-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 0.78rem;
    font-weight: 500;
    padding: 6px 10px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
}
.engage-btn:hover {
    background: rgba(255,255,255,0.06);
    color: var(--text-primary);
}
.engage-btn:hover svg { stroke: var(--text-primary); }
.engage-btn svg {
    flex-shrink: 0;
    width: 15px;
    height: 15px;
}
.engage-btn.active {
    color: var(--accent-primary);
}
.engage-btn.active svg {
    fill: var(--accent-primary);
    stroke: var(--accent-primary);
}

/* ── Tail active state ── */
.tail-btn.active {
    color: var(--accent-primary, #238636);
}
.tail-btn.active svg {
    fill: var(--accent-primary, #238636);
    stroke: var(--accent-primary, #238636);
}


/* ============================================================
   Reaction Picker
   ============================================================ */
.engage-react-wrap {
    position: relative;
}
.reaction-picker {
    display: none !important;
    position: absolute;
    bottom: calc(100% + 6px);
    left: 0;
    background: var(--bg-elevated, var(--bg-secondary));
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 4px 6px;
    gap: 2px;
    flex-direction: row;
    box-shadow: 0 4px 16px rgba(0,0,0,0.3);
    z-index: 50;
    white-space: nowrap;
}
.reaction-picker.open {
    display: flex !important;
}
.rp-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s, background 0.15s;
}
.rp-btn:hover {
    background: rgba(255,255,255,0.1);
    transform: scale(1.25);
}
.rp-btn.active {
    background: rgba(35, 134, 54, 0.2);
}


/* ============================================================
   Reaction Chips
   ============================================================ */
.reaction-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 8px;
}
.reaction-chips:empty {
    display: none;
}
.reaction-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 3px 10px;
    cursor: pointer;
    font-size: 0.75rem;
    transition: all 0.15s;
}
.reaction-chip:hover {
    border-color: rgba(255,255,255,0.15);
}
.reaction-chip.active {
    border-color: var(--accent-primary);
    background: rgba(35, 134, 54, 0.12);
}
.reaction-chip .rc-emoji { font-size: 0.85rem; }
.reaction-chip .rc-count {
    font-weight: 600;
    color: var(--text-muted);
}
.reaction-chip.active .rc-count {
    color: var(--accent-primary);
}


/* ============================================================
   Inline Comments
   ============================================================ */
.inline-comment-section {
    margin-top: 10px;
    padding-top: 8px;
    border-top: 1px solid rgba(255,255,255,0.05);
}
.inline-comments-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 8px;
    max-height: 200px;
    overflow-y: auto;
}
.inline-comment-item {
    display: flex;
    gap: 8px;
    align-items: baseline;
    padding: 5px 0;
    font-size: 0.82rem;
}
.inline-comment-author {
    font-weight: 600;
    color: var(--text-primary);
    flex-shrink: 0;
    font-size: 0.82rem;
}
.inline-comment-body {
    color: var(--text-secondary);
    word-break: break-word;
    flex: 1;
}
.inline-comment-time {
    color: var(--text-muted);
    font-size: 0.72rem;
    flex-shrink: 0;
}

/* ── Reply Banner ── */
.inline-comment-reply-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 4px 10px;
    margin-bottom: 4px;
    background: rgba(88, 166, 255, 0.08);
    border-left: 2px solid #58a6ff;
    border-radius: 4px;
    font-size: 0.75rem;
    color: #58a6ff;
}
.inline-reply-cancel {
    background: none;
    border: none;
    color: #58a6ff;
    cursor: pointer;
    font-size: 1rem;
    padding: 0 4px;
    line-height: 1;
}
.inline-comment-reply-link {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 0.7rem;
    cursor: pointer;
    padding: 0;
    margin-left: 8px;
}
.inline-comment-reply-link:hover {
    color: #58a6ff;
    text-decoration: underline;
}
.inline-comment-item.reply {
    padding-left: 20px;
    border-left: 2px solid rgba(255,255,255,0.06);
}

/* ── Comment Compose ── */
.inline-comment-compose {
    display: flex;
    gap: 6px;
    align-items: center;
}
.inline-comment-input {
    flex: 1;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    color: var(--text-primary);
    padding: 7px 14px;
    font-size: 0.82rem;
    font-family: inherit;
    outline: none;
    transition: border-color 0.2s;
}
.inline-comment-input:focus {
    border-color: var(--accent-primary);
}
.inline-comment-input::placeholder {
    color: var(--text-muted);
}
.inline-comment-send {
    background: none;
    border: none;
    color: var(--accent-primary);
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
}
.inline-comment-send:hover {
    background: rgba(255,255,255,0.06);
}


/* ============================================================
   @Mention Dropdown
   ============================================================ */
.mention-dropdown {
    position: absolute;
    bottom: 100%;
    left: 0;
    right: 0;
    background: var(--bg-elevated, var(--bg-secondary));
    border: 1px solid var(--border-color);
    border-radius: 8px;
    max-height: 160px;
    overflow-y: auto;
    margin-bottom: 4px;
    box-shadow: 0 -2px 12px rgba(0,0,0,0.2);
    z-index: 100;
}
.mention-dropdown-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 0.82rem;
    border-bottom: 1px solid rgba(255,255,255,0.04);
    transition: background 0.1s;
}
.mention-dropdown-item:hover {
    background: rgba(255,255,255,0.06);
}
.mention-dropdown-item:last-child {
    border-bottom: none;
}
.mention-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: linear-gradient(135deg, #238636 0%, #2ea043 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.68rem;
    flex-shrink: 0;
}
.mention-name {
    font-weight: 500;
    color: var(--text-primary);
    flex: 1;
}
.mention-verified {
    color: var(--accent-primary, #238636);
    font-size: 0.7rem;
}
.mention-highlight {
    font-weight: 600;
    color: var(--accent-link, #58a6ff);
}


/* ============================================================
   Mobile Responsive
   ============================================================ */
@media (max-width: 640px) {
    .feed-page {
        padding: 0 0 32px;
    }
    .feed-tabs {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .feed-tab {
        padding: 7px 10px;
        font-size: 0.78rem;
        white-space: nowrap;
    }
}

@media (max-width: 480px) {
    .activity-card {
        padding: 12px;
        gap: 10px;
    }
    .activity-avatar,
    .activity-avatar-img {
        width: 36px;
        height: 36px;
        font-size: 0.82rem;
    }
    .slip-pick { font-size: 0.88rem; }
    .slip-odds { font-size: 0.8rem; padding: 2px 8px; }
    .result-pnl { font-size: 0.88rem; }
    .engage-btn {
        padding: 5px 8px;
        font-size: 0.74rem;
        gap: 4px;
    }
    .engage-btn svg {
        width: 13px;
        height: 13px;
    }
}
