/**
 * Facebook Authentication Styles
 * 
 * Styles for popup authentication and notifications
 */

/* Notifications */
.woppy-notification {
    position: fixed;
    top: 32px;
    right: 20px;
    z-index: 999999;
    max-width: 400px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border-radius: 4px;
    animation: slideInRight 0.3s ease-out;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.woppy-notification-content {
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.woppy-notification-message {
    flex: 1;
    margin-right: 10px;
    font-size: 14px;
    line-height: 1.4;
}

.woppy-notification-close {
    background: none;
    border: none;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    padding: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s;
}

.woppy-notification-close:hover {
    background-color: rgba(0, 0, 0, 0.1);
}

/* Notification Types */
.woppy-notification-success {
    background-color: #d4edda;
    border-left: 4px solid #28a745;
    color: #155724;
}

.woppy-notification-success .woppy-notification-close {
    color: #155724;
}

.woppy-notification-error {
    background-color: #f8d7da;
    border-left: 4px solid #dc3545;
    color: #721c24;
}

.woppy-notification-error .woppy-notification-close {
    color: #721c24;
}

.woppy-notification-warning {
    background-color: #fff3cd;
    border-left: 4px solid #ffc107;
    color: #856404;
}

.woppy-notification-warning .woppy-notification-close {
    color: #856404;
}

.woppy-notification-info {
    background-color: #d1ecf1;
    border-left: 4px solid #17a2b8;
    color: #0c5460;
}

.woppy-notification-info .woppy-notification-close {
    color: #0c5460;
}

/* Facebook Connect Button */
.woppy-facebook-connect {
    background-color: #1877f2 !important;
    border-color: #1877f2 !important;
    color: white !important;
    padding: 8px 16px !important;
    border-radius: 6px !important;
    font-weight: 500 !important;
    transition: all 0.2s ease !important;
}

.woppy-facebook-connect:hover {
    background-color: #166fe5 !important;
    border-color: #166fe5 !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 2px 8px rgba(24, 119, 242, 0.3) !important;
}

.woppy-facebook-connect:disabled {
    background-color: #6c757d !important;
    border-color: #6c757d !important;
    cursor: not-allowed !important;
    transform: none !important;
    box-shadow: none !important;
}

/* Connected Pages Display */
.woppy-connected-pages {
    margin-top: 20px;
}

.woppy-page-item {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 10px;
    transition: all 0.2s ease;
}

.woppy-page-item:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

.woppy-page-info h4 {
    margin: 0 0 5px 0;
    color: #495057;
    font-size: 16px;
}

.woppy-page-info p {
    margin: 0;
    color: #6c757d;
    font-size: 14px;
}

/* Loading States */
.woppy-loading {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #1877f2;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-right: 8px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Spin animation for dashicons */
.dashicons.spin {
    animation: spin 1s linear infinite;
    display: inline-block;
}

/* Status Indicators */
.woppy-status-connected {
    color: #28a745;
    font-weight: 500;
}

.woppy-status-disconnected {
    color: #dc3545;
    font-weight: 500;
}

.woppy-status-pending {
    color: #ffc107;
    font-weight: 500;
}

/* Responsive Design */
@media (max-width: 782px) {
    .woppy-notification {
        right: 10px;
        left: 10px;
        max-width: none;
        top: 46px;
    }
    
    .woppy-page-item {
        padding: 12px;
    }
    
    .woppy-page-info h4 {
        font-size: 14px;
    }
    
    .woppy-page-info p {
        font-size: 12px;
    }
}

/* WordPress Admin Integration */
.wp-admin .woppy-notification {
    top: 46px;
}

@media screen and (max-width: 782px) {
    .wp-admin .woppy-notification {
        top: 66px;
    }
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    .woppy-notification {
        border: 2px solid;
    }
    
    .woppy-page-item {
        border-width: 2px;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .woppy-notification {
        animation: none;
    }
    
    .woppy-facebook-connect {
        transition: none !important;
    }
    
    .woppy-facebook-connect:hover {
        transform: none !important;
    }
    
    .woppy-loading {
        animation: none;
    }
}





