/* SOFI Feeds Enhancements - Lottie + Push + Live + DMs */
/* ====================================================== */

/* Notification Status Modal (Round Modal) */
.notif-status-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.notif-status-modal.active {
    opacity: 1;
}

.notif-status-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
}

.notif-status-content {
    position: relative;
    background: linear-gradient(135deg, #0a0e1a 0%, #11151f 100%);
    border-radius: 28px;
    padding: 32px 28px;
    max-width: 320px;
    text-align: center;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.notif-status-modal.active .notif-status-content {
    transform: scale(1);
}

.notif-status-content h3 {
    margin: 0 0 12px 0;
    font-size: 20px;
    font-weight: 700;
    color: #ffffff;
}

.notif-status-content p {
    margin: 0 0 24px 0;
    font-size: 14px;
    line-height: 1.6;
    color: #e0e0e0;
    white-space: pre-line;
}

.notif-status-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #00d09c, #01b88d);
    border: none;
    border-radius: 12px;
    color: #ffffff;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 16px rgba(0, 208, 156, 0.3);
}

.notif-status-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 208, 156, 0.5);
}

.notif-status-btn:active {
    transform: translateY(0);
}

/* Live Stream Modal */
.live-stream-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #000000;
    z-index: 999998;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.live-stream-modal.active {
    opacity: 1;
}

.live-stream-container {
    width: 100%;
    height: 100%;
    position: relative;
    display: flex;
    flex-direction: column;
}

.live-video-area {
    flex: 1;
    position: relative;
    background: #000;
}

.live-badge-pulse {
    position: absolute;
    top: 20px;
    left: 20px;
    display: flex;
    gap: 12px;
    align-items: center;
    z-index: 10;
}

.live-badge {
    background: #ff3b5c;
    color: white;
    padding: 6px 14px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 12px;
    letter-spacing: 1px;
    animation: livePulse 2s infinite;
    box-shadow: 0 0 20px rgba(255, 59, 92, 0.6);
}

@keyframes livePulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 20px rgba(255, 59, 92, 0.6);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 30px rgba(255, 59, 92, 0.9);
    }
}

.live-viewers {
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(12px);
    color: white;
    padding: 6px 12px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.live-close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(12px);
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.live-close-btn:hover {
    background: rgba(255, 59, 92, 0.9);
}

.live-comments-overlay {
    position: absolute;
    bottom: 80px;
    left: 16px;
    right: 16px;
    max-height: 300px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 8px;
    pointer-events: none;
}

.live-comment-item {
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(12px);
    padding: 8px 12px;
    border-radius: 12px;
    display: inline-flex;
    gap: 6px;
    align-self: flex-start;
    animation: slideInLeft 0.3s ease;
    max-width: 80%;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.live-comment-user {
    color: #00d09c;
    font-weight: 700;
    font-size: 13px;
}

.live-comment-text {
    color: white;
    font-size: 13px;
}

.live-actions-bar {
    position: absolute;
    bottom: 20px;
    left: 16px;
    right: 16px;
    display: flex;
    gap: 12px;
    align-items: center;
}

.live-comment-input {
    flex: 1;
    padding: 12px 16px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    color: white;
    font-size: 14px;
    outline: none;
}

.live-comment-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.live-send-btn,
.live-gift-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.live-send-btn {
    background: linear-gradient(135deg, #00d09c, #01b88d);
    color: white;
}

.live-gift-btn {
    background: linear-gradient(135deg, #ff3b5c, #ff1744);
    color: white;
}

.live-send-btn:active,
.live-gift-btn:active {
    transform: scale(0.95);
}

.gift-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    animation: popIn 0.5s ease;
    pointer-events: none;
    z-index: 100;
}

.gift-emoji {
    font-size: 80px;
    animation: bounce 0.5s ease;
}

.gift-text {
    font-size: 20px;
    font-weight: 700;
    color: #00d09c;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
    margin-top: 8px;
}

@keyframes bounce {
    0%, 100% { transform: scale(1) translateY(0); }
    50% { transform: scale(1.2) translateY(-20px); }
}

@keyframes popIn {
    from {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.5);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

/* DM Modal */
.dm-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #0a0e1a;
    z-index: 999997;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.dm-modal.active {
    transform: translateX(0);
}

.dm-container {
    max-width: 450px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    flex-direction: column;
    background: #0a0e1a;
}

.dm-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.dm-back-btn,
.dm-new-btn,
.dm-more-btn {
    background: none;
    border: none;
    color: #e0e0e0;
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
    transition: color 0.2s ease;
}

.dm-back-btn:hover,
.dm-new-btn:hover,
.dm-more-btn:hover {
    color: #00d09c;
}

.dm-header h3 {
    flex: 1;
    margin: 0;
    font-size: 20px;
    font-weight: 700;
    color: #ffffff;
}

.dm-list {
    flex: 1;
    overflow-y: auto;
}

.dm-item {
    display: flex;
    gap: 12px;
    padding: 16px;
    cursor: pointer;
    transition: background 0.2s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.dm-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.dm-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    object-fit: cover;
}

.dm-info {
    flex: 1;
}

.dm-name {
    font-size: 16px;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 4px;
}

.dm-last-message {
    font-size: 14px;
    color: #999;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dm-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
}

.dm-time {
    font-size: 12px;
    color: #999;
}

.dm-unread {
    background: #00d09c;
    color: white;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 12px;
    min-width: 20px;
    text-align: center;
}

.dm-empty {
    text-align: center;
    padding: 60px 20px;
    color: #999;
    font-size: 15px;
}

.dm-header-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
}

.dm-header-info {
    flex: 1;
}

.dm-header-name {
    font-size: 16px;
    font-weight: 600;
    color: #ffffff;
}

.dm-header-status {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: #999;
}

.dm-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #00d09c;
}

.dm-typing-text {
    color: #00d09c;
    font-style: italic;
}

.dm-messages {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.dm-date-divider {
    text-align: center;
    font-size: 12px;
    color: #999;
    margin: 12px 0;
}

.dm-message {
    display: flex;
    gap: 8px;
    align-items: flex-end;
}

.dm-message-mine {
    flex-direction: row-reverse;
}

.dm-message-bubble {
    max-width: 70%;
    padding: 12px 16px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.1);
    position: relative;
}

.dm-message-mine .dm-message-bubble {
    background: linear-gradient(135deg, #00d09c, #01b88d);
}

.dm-message-text {
    font-size: 14px;
    color: #ffffff;
    line-height: 1.5;
    margin-bottom: 4px;
}

.dm-message-time {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
}

.dm-message-status {
    font-size: 14px;
    color: #00d09c;
}

.dm-input-container {
    display: flex;
    gap: 12px;
    padding: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    align-items: center;
}

.dm-attach-btn {
    background: none;
    border: none;
    color: #e0e0e0;
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
}

.dm-input {
    flex: 1;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    color: #ffffff;
    font-size: 14px;
    outline: none;
}

.dm-input::placeholder {
    color: #999;
}

.dm-send-btn {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: #999;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.dm-send-btn.active {
    background: linear-gradient(135deg, #00d09c, #01b88d);
    color: white;
}

.dm-send-btn:active {
    transform: scale(0.95);
}

/* Lottie Loader */
#lottieLoader {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    z-index: 999999;
    display: none;
    align-items: center;
    justify-content: center;
}

/* Instagram Comment Modal (Enhanced with Lottie) */
.ig-comments-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    z-index: 999996;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.ig-comments-modal.active {
    opacity: 1;
}

.ig-comments-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.ig-comments-container {
    width: 100%;
    max-width: 450px;
    height: 70vh;
    max-height: 600px;
    background: #1a1f2e;
    border-radius: 20px 20px 0 0;
    display: flex;
    flex-direction: column;
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
}

.ig-comments-modal.active .ig-comments-container {
    transform: translateY(0);
}

.ig-comments-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.ig-comments-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
}

.ig-close-btn {
    background: none;
    border: none;
    color: #e0e0e0;
    cursor: pointer;
    padding: 4px;
    transition: color 0.2s ease;
}

.ig-close-btn:hover {
    color: #00d09c;
}

.ig-comments-list {
    flex: 1;
    overflow-y: auto;
    padding: 16px 20px;
    min-height: 200px;
}

.ig-comment-item {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    opacity: 0;
    animation: slideInComment 0.3s ease forwards;
}

@keyframes slideInComment {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.ig-comment-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.ig-comment-content {
    flex: 1;
}

.ig-comment-header {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 4px;
}

.ig-comment-user {
    font-size: 14px;
    font-weight: 600;
    color: #ffffff;
}

.ig-comment-time {
    font-size: 12px;
    color: #999;
}

.ig-comment-text {
    font-size: 14px;
    color: #e0e0e0;
    line-height: 1.5;
    margin-bottom: 6px;
}

.ig-comment-actions {
    display: flex;
    gap: 16px;
}

.ig-comment-action {
    background: none;
    border: none;
    color: #999;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: color 0.2s ease;
}

.ig-comment-action:hover {
    color: #00d09c;
}

.ig-comment-like-btn {
    background: none;
    border: none;
    color: #999;
    font-size: 20px;
    cursor: pointer;
    padding: 4px;
    transition: all 0.2s ease;
}

.ig-comment-like-btn:active {
    animation: heartPulse 0.3s ease;
}

.ig-no-comments {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.ig-no-comments i {
    display: block;
    margin: 0 auto 16px;
}

.ig-no-comments p {
    margin: 0 0 4px 0;
    font-size: 16px;
}

.ig-comment-input-container {
    padding: 16px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: #1a1f2e;
    min-height: 80px;
}

.ig-comment-input-box {
    display: flex;
    gap: 12px;
    align-items: center;
    position: relative;
}

.ig-comment-input {
    flex: 1;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 24px;
    color: #ffffff;
    font-size: 15px;
    outline: none;
    transition: all 0.2s ease;
    min-height: 48px;
}

.ig-comment-input:focus {
    background: rgba(255, 255, 255, 0.15);
    border-color: #00d09c;
    box-shadow: 0 0 0 3px rgba(0, 208, 156, 0.1);
}

.ig-comment-input::placeholder {
    color: #aaa;
}

.ig-emoji-btn {
    background: none;
    border: none;
    color: #e0e0e0;
    cursor: pointer;
    padding: 8px;
    transition: color 0.2s ease;
}

.ig-emoji-btn:hover {
    color: #00d09c;
}

.ig-send-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: #999;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.ig-send-btn.active {
    background: linear-gradient(135deg, #00d09c, #01b88d);
    color: white;
    animation: sendPulse 1s infinite;
}

@keyframes sendPulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(0, 208, 156, 0.7);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 0 10px rgba(0, 208, 156, 0);
    }
}

.ig-send-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.ig-emoji-picker {
    position: absolute;
    bottom: 60px;
    left: 0;
    background: #11151f;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 12px;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    animation: popIn 0.2s ease;
}

.ig-emoji-picker button {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.ig-emoji-picker button:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.2);
}

@keyframes fadeOut {
    to {
        opacity: 0;
    }
}
