/**
 * Enhanced Logout Styles
 * Provides visual feedback during logout process
 */

.auth-button {
    display: inline-block;
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 4px;
    font-weight: bold;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    font-size: 14px;
}

.logout-button {
    background-color: #dc3545;
    color: white;
    border: 2px solid #dc3545;
}

.logout-button:hover {
    background-color: #c82333;
    border-color: #bd2130;
    color: white;
    text-decoration: none;
}

.logout-button:disabled,
.logout-button.logging-out {
    background-color: #6c757d;
    border-color: #6c757d;
    cursor: not-allowed;
    opacity: 0.7;
}

.login-button {
    background-color: #007bff;
    color: white;
    border: 2px solid #007bff;
}

.login-button:hover {
    background-color: #0056b3;
    border-color: #004085;
    color: white;
    text-decoration: none;
}

/* Loading spinner for logout button */
.logout-button.logging-out::after {
    content: "";
    display: inline-block;
    width: 12px;
    height: 12px;
    margin-left: 8px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Cache clearing notification */
.cache-clearing-notice {
    position: fixed;
    top: 20px;
    right: 20px;
    background-color: #17a2b8;
    color: white;
    padding: 15px 20px;
    border-radius: 4px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    z-index: 9999;
    font-size: 14px;
    max-width: 300px;
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
}

.cache-clearing-notice.show {
    opacity: 1;
    transform: translateX(0);
}

.cache-clearing-notice .close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 18px;
    font-weight: bold;
    float: right;
    cursor: pointer;
    margin-left: 10px;
    line-height: 1;
}

.cache-clearing-notice .close-btn:hover {
    opacity: 0.7;
}

/* Responsive design */
@media (max-width: 768px) {
    .auth-button {
        padding: 8px 16px;
        font-size: 13px;
    }
    
    .cache-clearing-notice {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .logout-button {
        border-width: 3px;
    }
    
    .login-button {
        border-width: 3px;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .auth-button,
    .cache-clearing-notice {
        transition: none;
    }
    
    @keyframes spin {
        0% { transform: rotate(0deg); }
        100% { transform: rotate(360deg); }
    }
}
