/**
 * EMFootball Pool Global Modal System
 * FFLogin-style consistent modal styling for all popups
 */

.emfp-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.emfp-modal-content {
    background: #1D461A;
    border-radius: 8px;
    min-width: 300px;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    animation: emfpModalFadeIn 0.3s ease-out;
}

@keyframes emfpModalFadeIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(-10px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.emfp-modal-header {
    background: #1D461A;
    padding: 15px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 8px 8px 0 0;
}

.emfp-modal-header h3 {
    margin: 0;
    color: #ffffff;
    font-size: 18px;
    font-weight: 600;
}

.emfp-modal-close {
    background: none;
    border: none;
    color: #ffffff;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.emfp-modal-close:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.emfp-modal-body {
    padding: 20px;
    background: #ffffff;
}

.emfp-modal-body p {
    margin: 0;
    color: #333333;
    font-size: 16px;
    line-height: 1.5;
}

.emfp-modal-footer {
    padding: 15px 20px;
    background: #ffffff;
    border-top: 1px solid #e0e0e0;
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    border-radius: 0 0 8px 8px;
}

.emfp-modal-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 80px;
}

.emfp-modal-btn-primary {
    background-color: #B90A05;
    color: #ffffff;
}

.emfp-modal-btn-primary:hover {
    background-color: #9a0904;
}

.emfp-modal-btn-secondary {
    background-color: #6c757d;
    color: #ffffff;
}

.emfp-modal-btn-secondary:hover {
    background-color: #5a6268;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .emfp-modal-content {
        margin: 20px;
        min-width: auto;
        width: calc(100% - 40px);
    }
    
    .emfp-modal-header,
    .emfp-modal-body,
    .emfp-modal-footer {
        padding: 15px;
    }
    
    .emfp-modal-footer {
        flex-direction: column;
    }
    
    .emfp-modal-btn {
        width: 100%;
    }
}

/* Accessibility improvements */
.emfp-modal-overlay:focus {
    outline: none;
}

.emfp-modal-btn:focus {
    outline: 2px solid #ffffff;
    outline-offset: 2px;
}

.emfp-modal-close:focus {
    outline: 2px solid #ffffff;
    outline-offset: 2px;
}
