/* AI Translate - Language Switcher */

.ait-lang-switcher {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 9999;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 14px;
}

.ait-lang-current {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.2s ease;
    font-size: 14px;
    line-height: 1.4;
    color: #333;
}

.ait-lang-current:hover {
    border-color: #999;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.ait-lang-current[aria-expanded="true"] {
    border-color: #0073aa;
    border-radius: 8px 8px 0 0;
}

.ait-lang-current[aria-expanded="true"] .ait-lang-arrow {
    transform: rotate(180deg);
}

.ait-lang-arrow {
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.ait-lang-dropdown {
    display: none;
    position: absolute;
    bottom: 100%;
    right: 0;
    left: 0;
    margin: 0;
    padding: 4px 0;
    list-style: none;
    background: #fff;
    border: 1px solid #0073aa;
    border-bottom: none;
    border-radius: 8px 8px 0 0;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.1);
    max-height: 300px;
    overflow-y: auto;
}

.ait-lang-dropdown.ait-open {
    display: block;
}

.ait-lang-item a {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    color: #333;
    text-decoration: none;
    transition: background 0.15s ease;
}

.ait-lang-item a:hover {
    background: #f0f6fc;
}

.ait-lang-item.ait-lang-active a {
    background: #f0f6fc;
    font-weight: 600;
    color: #0073aa;
}

.ait-lang-flag {
    font-size: 18px;
    line-height: 1;
}

.ait-lang-name {
    white-space: nowrap;
}

/* Shortcode inline style */
.ait-lang-switcher-inline {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.ait-lang-switcher-inline a {
    color: inherit;
    text-decoration: none;
    padding: 4px 8px;
    border-radius: 4px;
    transition: background 0.15s ease;
}

.ait-lang-switcher-inline a:hover {
    background: rgba(0, 0, 0, 0.05);
}

.ait-lang-switcher-inline a.ait-lang-active {
    font-weight: 700;
    color: #0073aa;
}

.ait-lang-sep {
    color: #ccc;
}

/* Shortcode dropdown style */
.ait-lang-switcher-shortcode {
    position: static;
    display: inline-block;
    box-shadow: none;
}

.ait-lang-select {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    background: #fff;
    cursor: pointer;
}

.ait-lang-select:hover {
    border-color: #999;
}

/* RTL support */
[dir="rtl"] .ait-lang-switcher {
    right: auto;
    left: 24px;
}

/* Responsive */
@media screen and (max-width: 480px) {
    .ait-lang-switcher {
        bottom: 12px;
        right: 12px;
    }

    .ait-lang-current {
        padding: 8px 12px;
        font-size: 13px;
    }
}
