/* Legal Auto-Update System Styles */

/* Update Notification */
.legal-update-notification {
    position: fixed;
    top: 100px;
    right: 20px;
    background: linear-gradient(135deg, var(--primary-green), var(--dark-green));
    color: var(--white);
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    z-index: 10002;
    max-width: 350px;
    animation: slideInRight 0.5s ease-out;
}

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

.update-content h4 {
    margin: 0 0 10px 0;
    font-size: 1.1rem;
    color: var(--bright-yellow);
}

.update-content p {
    margin: 0 0 15px 0;
    font-size: 0.9rem;
    line-height: 1.4;
}

.update-content button {
    background: var(--bright-yellow);
    color: var(--primary-green);
    border: none;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.update-content button:hover {
    background: var(--yellow);
    transform: translateY(-1px);
}

/* Auto-Update Status Indicator */
.legal-status-indicator {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: rgba(55, 109, 77, 0.9);
    color: var(--white);
    padding: 8px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    z-index: 1000;
    display: none;
    animation: fadeInOut 3s ease-in-out;
}

@keyframes fadeInOut {
    0%, 100% { opacity: 0; }
    50% { opacity: 1; }
}

.legal-status-indicator.checking {
    display: block;
    background: rgba(252, 190, 44, 0.9);
    color: var(--primary-green);
}

.legal-status-indicator.updated {
    display: block;
    background: rgba(76, 175, 80, 0.9);
}

.legal-status-indicator.error {
    display: block;
    background: rgba(244, 67, 54, 0.9);
}

/* Dynamic Content Placeholder */
.auto-update-content {
    transition: opacity 0.3s ease;
}

.auto-update-content.updating {
    opacity: 0.7;
    pointer-events: none;
}

/* Legal Document Version Badge */
.document-version {
    display: inline-block;
    background: var(--cream);
    color: var(--primary-green);
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
    margin-left: 10px;
    border: 1px solid var(--primary-green);
}

/* Auto-Generated Content Markers */
.auto-generated {
    position: relative;
}

.auto-generated::after {
    content: "🔄";
    position: absolute;
    top: -5px;
    right: -5px;
    font-size: 0.7rem;
    opacity: 0.6;
    pointer-events: none;
}

/* Update Schedule Display */
.update-schedule {
    background: rgba(55, 109, 77, 0.05);
    border: 1px solid rgba(55, 109, 77, 0.2);
    border-radius: 8px;
    padding: 15px;
    margin: 20px 0;
    font-size: 0.9rem;
}

.update-schedule h4 {
    margin: 0 0 10px 0;
    color: var(--primary-green);
    font-size: 1rem;
}

.update-schedule .schedule-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
}

.update-schedule .schedule-item:last-child {
    margin-bottom: 0;
}

/* Legal Compliance Badge */
.compliance-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: var(--primary-green);
    color: var(--white);
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 500;
    margin: 10px 0;
}

.compliance-badge::before {
    content: "✓";
    font-weight: bold;
}

/* Real-time Update Indicators */
.live-update {
    position: relative;
    overflow: hidden;
}

.live-update::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--bright-yellow), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* Mobile Responsive for Auto-Update Elements */
@media (max-width: 768px) {
    .legal-update-notification {
        right: 10px;
        left: 10px;
        max-width: none;
        top: 80px;
    }
    
    .legal-status-indicator {
        bottom: 10px;
        right: 10px;
        left: 10px;
        text-align: center;
    }
    
    .document-version {
        display: block;
        margin: 10px 0;
        text-align: center;
    }
    
    .update-schedule .schedule-item {
        flex-direction: column;
        gap: 5px;
    }
}

/* Accessibility Improvements */
@media (prefers-reduced-motion: reduce) {
    .legal-update-notification,
    .legal-status-indicator,
    .live-update::before {
        animation: none;
    }
    
    .auto-update-content.updating {
        opacity: 1;
    }
}

/* Print Styles - Hide auto-update elements when printing */
@media print {
    .legal-update-notification,
    .legal-status-indicator,
    .auto-generated::after,
    .live-update::before {
        display: none !important;
    }
}