/* Facebook Embed Modal Styles */
.content-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    align-items: center;
    justify-content: center;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.modal-container {
    position: relative;
    background: white;
    border-radius: 12px;
    max-width: 90vw;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        transform: scale(0.9) translateY(-20px);
        opacity: 0;
    }
    to {
        transform: scale(1) translateY(0);
        opacity: 1;
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #eee;
    background: #f8f9fa;
}

.modal-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
    padding: 8px;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: #e9ecef;
    color: #333;
}

.modal-body {
    padding: 0;
    min-height: 300px;
    position: relative;
}

/* Facebook Embed Containers */
.facebook-video-embed,
.facebook-post-embed {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 300px;
    padding: 20px;
}

.facebook-video-embed iframe,
.facebook-post-embed iframe {
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Loading Spinner */
.loading-spinner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    color: #666;
}

.loading-spinner ion-icon {
    font-size: 48px;
    margin-bottom: 16px;
    animation: spin 1s linear infinite;
    color: #1877F2;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Fallback Content */
.embed-fallback {
    min-height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fallback-content {
    text-align: center;
    padding: 40px;
    max-width: 400px;
}

.fallback-content ion-icon {
    font-size: 64px;
    color: #1877F2;
    margin-bottom: 20px;
    display: block;
}

.fallback-content h4 {
    margin: 0 0 12px 0;
    font-size: 20px;
    font-weight: 600;
    color: #333;
}

.fallback-content p {
    margin: 0 0 24px 0;
    color: #666;
    line-height: 1.5;
}

.fallback-content .btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: #1877F2;
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
    font-size: 14px;
}

.fallback-content .btn:hover {
    background: #166fe5;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(24, 119, 242, 0.3);
}

/* Content Cards Enhancement */
.content-card .video-container,
.content-card .image-container {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.content-card .video-container:hover,
.content-card .image-container:hover {
    transform: scale(1.02);
}

.content-card .play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(24, 119, 242, 0.9);
    color: white;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    transition: all 0.2s ease;
}

.content-card .play-button:hover {
    background: rgba(24, 119, 242, 1);
    transform: translate(-50%, -50%) scale(1.1);
}

.content-card .video-overlay,
.content-card .image-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
    color: white;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.content-card .video-container:hover .video-overlay,
.content-card .image-container:hover .image-overlay {
    opacity: 1;
}

.view-content-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
}

/* Responsive Design */
@media (max-width: 768px) {
    .modal-container {
        max-width: 95vw;
        max-height: 95vh;
        margin: 10px;
    }
    
    .facebook-video-embed,
    .facebook-post-embed {
        padding: 15px;
    }
    
    .facebook-video-embed iframe,
    .facebook-post-embed iframe {
        width: 100% !important;
        max-width: 100% !important;
    }
    
    .fallback-content {
        padding: 30px 20px;
    }
}

/* Facebook Elements Styling */
.fb-video,
.fb-post {
    margin: 0 auto;
    display: block;
}

/* Custom scrollbar for modal */
.modal-body::-webkit-scrollbar {
    width: 6px;
}

.modal-body::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.modal-body::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.modal-body::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}
