/**
 * Jurisdiction Blocking Styles
 * 
 * CSS styles for the "Not available in your jurisdiction" message
 * that replaces join/prelaunch buttons when users are blocked.
 * 
 * @package Efforia
 * @since 1.0.0
 */

/* Main jurisdiction blocked container */
.jurisdiction-blocked {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 2px solid #dc3545;
    border-radius: 12px;
    margin: 15px 0;
    text-align: center;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.15);
    transition: all 0.3s ease;
}

.jurisdiction-blocked:hover {
    box-shadow: 0 6px 20px rgba(220, 53, 69, 0.2);
    transform: translateY(-2px);
}

/* Main blocked message */
.jurisdiction-blocked-message {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 8px;
}

.jurisdiction-blocked-message .blocked-text {
    font-size: 16px;
    font-weight: 600;
    color: #dc3545;
    letter-spacing: 0.5px;
}

.jurisdiction-blocked-message .blocked-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
}

.jurisdiction-blocked-message .blocked-icon svg {
    width: 20px;
    height: 20px;
    animation: pulse 2s infinite;
}

/* Info text */
.jurisdiction-info {
    margin-top: 5px;
}

.jurisdiction-info small {
    font-size: 13px;
    color: #6c757d;
    font-style: italic;
}

/* Mobile responsive styles */
@media (max-width: 768px) {
    .jurisdiction-blocked {
        padding: 15px;
        margin: 10px 0;
    }
    
    .jurisdiction-blocked-message .blocked-text {
        font-size: 14px;
    }
    
    .jurisdiction-info small {
        font-size: 12px;
    }
}

/* Mobile fixed button variant */
.jurisdiction-blocked.mobile.btn-fixed {
    position: fixed;
    bottom: 20px;
    left: 20px;
    right: 20px;
    z-index: 1000;
    margin: 0;
    border-radius: 8px;
    box-shadow: 0 8px 25px rgba(220, 53, 69, 0.3);
}

/* Animation for the blocked icon */
@keyframes pulse {
    0% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.1);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Alternative compact style for smaller spaces */
.jurisdiction-blocked.compact {
    padding: 12px 16px;
    flex-direction: row;
    background: #fff5f5;
    border: 1px solid #fecaca;
    border-radius: 6px;
    margin: 8px 0;
}

.jurisdiction-blocked.compact .jurisdiction-blocked-message {
    margin-bottom: 0;
    gap: 8px;
}

.jurisdiction-blocked.compact .blocked-text {
    font-size: 14px;
}

.jurisdiction-blocked.compact .jurisdiction-info {
    display: none;
}

/* Integration with existing button styles */
.btn-wrap.jurisdiction-blocked {
    /* Override any existing btn-wrap styles that might conflict */
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%) !important;
    border: 2px solid #dc3545 !important;
    cursor: not-allowed;
}

/* Dark theme support */
@media (prefers-color-scheme: dark) {
    .jurisdiction-blocked {
        background: linear-gradient(135deg, #2d3748 0%, #4a5568 100%);
        border-color: #e53e3e;
        color: #e53e3e;
    }
    
    .jurisdiction-blocked-message .blocked-text {
        color: #e53e3e;
    }
    
    .jurisdiction-info small {
        color: #a0aec0;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .jurisdiction-blocked {
        background: #ffffff;
        border: 3px solid #dc3545;
        color: #000000;
    }
    
    .jurisdiction-blocked-message .blocked-text {
        color: #dc3545;
        font-weight: 700;
    }
}

/* Print styles */
@media print {
    .jurisdiction-blocked {
        background: none !important;
        border: 2px solid #000 !important;
        box-shadow: none !important;
        color: #000 !important;
    }
    
    .jurisdiction-blocked-message .blocked-icon {
        display: none;
    }
}

/* RTL support */
[dir="rtl"] .jurisdiction-blocked-message {
    flex-direction: row-reverse;
}

/* Accessibility improvements */
.jurisdiction-blocked {
    /* Ensure proper focus management */
    outline: none;
}

.jurisdiction-blocked:focus-within {
    outline: 2px solid #0066cc;
    outline-offset: 2px;
}

/* Screen reader only text for better accessibility */
.jurisdiction-blocked .sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Loading state (if geolocation is being checked) */
.jurisdiction-blocked.loading {
    opacity: 0.7;
    pointer-events: none;
}

.jurisdiction-blocked.loading .blocked-icon svg {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}
