/* Legal Modal Styles - Shared across all projects */

.legal-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.legal-modal.active {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
}

.legal-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
}

.legal-modal-content {
    position: relative;
    background: white;
    border-radius: 16px;
    width: 90%;
    max-width: 900px;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateY(-30px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.legal-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 30px;
    border-bottom: 2px solid #e0e0e0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 16px 16px 0 0;
}

.legal-modal-header h2 {
    margin: 0;
    font-size: 24px;
    font-weight: 700;
}

.legal-modal-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

#legalLangSelector {
    padding: 8px 12px;
    border: 2px solid rgba(255, 255, 255, 0.5);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

#legalLangSelector:hover {
    background: rgba(255, 255, 255, 0.25);
}

#legalLangSelector option {
    color: #333;
    background: white;
}

.legal-modal-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    font-size: 32px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s;
    line-height: 1;
    padding: 0;
}

.legal-modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.legal-modal-body {
    padding: 30px;
    overflow-y: auto;
    flex: 1;
    line-height: 1.8;
}

.legal-modal-body h1 {
    color: #667eea;
    margin-top: 0;
    margin-bottom: 10px;
}

.legal-modal-body h2 {
    color: #764ba2;
    margin-top: 30px;
    margin-bottom: 15px;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 8px;
}

.legal-modal-body h3 {
    color: #555;
    margin-top: 20px;
    margin-bottom: 10px;
}

.legal-modal-body p {
    margin-bottom: 15px;
    color: #333;
}

.legal-modal-body ul,
.legal-modal-body ol {
    margin-left: 25px;
    margin-bottom: 15px;
}

.legal-modal-body li {
    margin-bottom: 8px;
}

.legal-modal-body strong {
    color: #764ba2;
    font-weight: 600;
}

.legal-modal-body a {
    color: #667eea;
    text-decoration: none;
    border-bottom: 1px solid #667eea;
}

.legal-modal-body a:hover {
    color: #764ba2;
    border-bottom-color: #764ba2;
}

.legal-modal-body hr {
    border: none;
    border-top: 2px solid #e0e0e0;
    margin: 30px 0;
}

.legal-loading {
    text-align: center;
    padding: 60px 20px;
    font-size: 18px;
    color: #999;
}

.legal-error {
    text-align: center;
    padding: 60px 20px;
}

.legal-error p {
    color: #dc3545;
    font-size: 16px;
}

/* Legal Disclaimer */
.legal-disclaimer {
    margin-top: 15px;
    padding: 12px;
    background: rgba(0, 0, 0, 0.05);
    border-radius: 8px;
    text-align: center;
}

.legal-disclaimer p {
    margin: 0;
    font-size: 12px;
    color: #666;
    line-height: 1.6;
}

.legal-disclaimer a {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
}

.legal-disclaimer a:hover {
    color: #764ba2;
    text-decoration: underline;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .legal-modal-content {
        width: 95%;
        max-height: 90vh;
    }

    .legal-modal-header {
        padding: 20px;
        flex-direction: column;
        gap: 15px;
    }

    .legal-modal-header h2 {
        font-size: 20px;
    }

    .legal-modal-body {
        padding: 20px;
    }

    .legal-modal-actions {
        width: 100%;
        justify-content: space-between;
    }
}