/**
 * SOWL Visual Indicators Styles
 *
 * CSS styles for SSO link visual indicators.
 *
 * @package SOWL
 * @since 1.9.0
 */

/* Link styling */
.sowl-destination-link {
    position: relative;
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

.sowl-destination-link:hover {
    text-decoration: underline;
}

/* Icon styling */
.sowl-icon {
    display: inline-block;
    width: 1em;
    height: 1em;
    margin: 0 0.3em;
    fill: currentColor;
    flex-shrink: 0;
}

/* Tooltip styling */
.sowl-destination-link[data-tooltip] {
    cursor: pointer;
}

.sowl-destination-link[data-tooltip]:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: #333;
    color: white;
    text-align: center;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 14px;
    white-space: nowrap;
    z-index: 1000;
    opacity: 0.9;
    pointer-events: none;
    margin-bottom: 6px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    transition: opacity 0.2s ease-in-out;
}

.sowl-destination-link[data-tooltip]:hover::before {
    content: "";
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: #333;
    z-index: 1001;
    pointer-events: none;
    margin-bottom: 0;
}

/* Loading state */
.sowl-destination-link.sowl-loading {
    opacity: 0.5;
    cursor: wait;
    pointer-events: none;
}

/* Focus state for accessibility */
.sowl-destination-link:focus {
    outline: 2px solid #0078d7;
    outline-offset: 3px;
}

/* Icon animation */
@keyframes sowl-pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.sowl-destination-link:hover .sowl-icon {
    animation: sowl-pulse 1s infinite;
}

/* Responsive adjustments */
@media (max-width: 480px) {
    .sowl-destination-link[data-tooltip]:hover::after {
        white-space: normal;
        width: 160px;
        margin-left: -80px;
        left: 50%;
    }
}