/* Role Access Denied Modal Styles */

/* Modal overlay - ensure it's visible and properly layered */
#roleAccessDeniedModal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background: rgba(0, 0, 0, 0.6) !important;
    backdrop-filter: blur(8px) !important;
    -webkit-backdrop-filter: blur(8px) !important;
    z-index: 99999 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 20px !important;
    opacity: 1 !important;
    visibility: visible !important;
}

#roleAccessDeniedModal.hidden {
    display: none !important;
    opacity: 0 !important;
    visibility: hidden !important;
}

/* Modal container */
#roleAccessDeniedModal > .modal-container {
    background: white !important;
    border-radius: 1rem !important;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25) !important;
    max-width: 28rem !important;
    width: 90% !important;
    max-height: 90vh !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    animation: roleAccessDeniedSlideUp 0.3s ease-out !important;
    position: relative !important;
    display: flex !important;
    flex-direction: column !important;
}

/* Dark mode support */
.dark #roleAccessDeniedModal > .modal-container {
    background: var(--bg-secondary, #1f2937) !important;
}

/* Modal header */
#roleAccessDeniedModal > .modal-container > .modal-header {
    position: relative !important;
    padding: 1.25rem 1.5rem !important;
    border-radius: 1rem 1rem 0 0 !important;
    flex-shrink: 0 !important;
}

/* Modal body */
#roleAccessDeniedModal > .modal-container > .modal-body {
    flex: 1 !important;
    overflow-y: auto !important;
}

/* Modal footer */
#roleAccessDeniedModal > .modal-container > .modal-footer {
    flex-shrink: 0 !important;
    border-radius: 0 0 1rem 1rem !important;
}

/* Dark mode for details section */
.dark #roleAccessDeniedDetails {
    background: rgba(251, 146, 60, 0.1) !important;
    border-color: rgba(251, 146, 60, 0.3) !important;
}

.dark #roleAccessDeniedDetails p {
    color: rgba(251, 146, 60, 0.9) !important;
}

/* Dark mode for benefits section */
.dark #roleAccessDeniedModal .bg-gray-50 {
    background: rgba(255, 255, 255, 0.05) !important;
}

.dark #roleAccessDeniedModal .text-gray-700 {
    color: rgba(255, 255, 255, 0.9) !important;
}

.dark #roleAccessDeniedModal .text-gray-600 {
    color: rgba(255, 255, 255, 0.7) !important;
}

/* Slide up animation */
@keyframes roleAccessDeniedSlideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Button styles */
#roleAccessDeniedActions button {
    transition: all 0.2s ease-in-out;
}

#roleAccessDeniedActions button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

#roleAccessDeniedActions button:active {
    transform: translateY(0);
}

/* Primary action button */
#roleAccessDeniedActions .bg-gradient-to-r {
    background: linear-gradient(135deg, #f97316 0%, #ea580c 100%) !important;
}

#roleAccessDeniedActions .bg-gradient-to-r:hover {
    background: linear-gradient(135deg, #ea580c 0%, #dc2626 100%) !important;
}

/* Secondary action button (blue for switch role) */
#roleAccessDeniedActions .bg-blue-500 {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%) !important;
}

#roleAccessDeniedActions .bg-blue-500:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%) !important;
}

/* Responsive */
@media (max-width: 640px) {
    #roleAccessDeniedModal > .modal-container {
        width: 95% !important;
        max-height: 95vh !important;
    }

    #roleAccessDeniedActions {
        flex-direction: column !important;
    }

    #roleAccessDeniedActions button {
        width: 100% !important;
    }
}
