/**
 * Hydori Language Auto-detect — suggestion banner.
 * Fixed to the very top of the viewport, above theme chrome. Scoped to
 * .hydori-autodetect-banner so it can never leak into theme styles.
 *
 * @since 2.12.0
 */

.hydori-autodetect-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    padding: 10px 44px 10px 16px;
    background: #106AD8;
    color: #ffffff;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.4;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
    transform: translateY(-100%);
    transition: transform 0.35s ease;
}

.hydori-autodetect-banner.hydori-autodetect-visible {
    transform: translateY(0);
}

.hydori-autodetect-flag {
    font-size: 16px;
    line-height: 1;
}

.hydori-autodetect-text {
    opacity: 0.95;
}

.hydori-autodetect-view {
    display: inline-flex;
    align-items: center;
    padding: 5px 14px;
    border-radius: 999px;
    background: #ffffff;
    color: #106AD8;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: opacity 0.15s ease;
}

.hydori-autodetect-view:hover,
.hydori-autodetect-view:focus {
    opacity: 0.85;
    color: #106AD8;
}

.hydori-autodetect-dismiss {
    position: absolute;
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    border-radius: 50%;
    color: #ffffff;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    padding: 0;
}

.hydori-autodetect-dismiss:hover,
.hydori-autodetect-dismiss:focus {
    background: rgba(255, 255, 255, 0.3);
}

@media (max-width: 600px) {
    .hydori-autodetect-banner {
        justify-content: flex-start;
        font-size: 13px;
        padding-right: 40px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hydori-autodetect-banner {
        transition: none;
    }
}
