/* AI Content Translator - Frontend Styles */

/* ========================================
   MENU LANGUAGE SWITCHER
   ======================================== */

.aict-menu-language-switcher {
    position: relative;
}

.aict-menu-language-switcher .aict-menu-toggle {
    display: flex;
    align-items: center;
    gap: 5px;
}

.aict-menu-language-switcher .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
    margin-top: -2px;
}

.aict-menu-language-switcher .aict-lang-submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border-radius: 4px;
    min-width: 200px;
    z-index: 9999;
    padding: 8px 0;
    list-style: none;
    margin: 0;
}

.aict-menu-language-switcher:hover .aict-lang-submenu {
    display: block;
}

.aict-menu-language-switcher .aict-lang-submenu li {
    margin: 0;
    padding: 0;
    list-style: none;
}

.aict-menu-language-switcher .aict-lang-submenu a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    color: #333 !important;
    text-decoration: none;
    transition: background 0.2s;
}

.aict-menu-language-switcher .aict-lang-submenu a:hover {
    background: #f5f5f5;
}

.aict-menu-language-switcher .aict-lang-submenu .current-lang a {
    background: #e8f3f8;
    color: #2271b1 !important;
    font-weight: 600;
}

.aict-menu-language-switcher .aict-lang-submenu .dashicons-yes {
    color: #46b450;
    font-size: 16px;
    width: 16px;
    height: 16px;
}

/* ========================================
   FOOTER LANGUAGE SWITCHER (Bottom-Right)
   ======================================== */

.aict-footer-switcher.aict-language-switcher {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

.aict-switcher-toggle {
    background: #2271b1;
    color: #fff;
    padding: 12px 20px;
    border-radius: 25px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    font-size: 14px;
    font-weight: 500;
}

.aict-switcher-toggle:hover {
    background: #135e96;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
    transform: translateY(-2px);
}

.aict-switcher-toggle .dashicons {
    font-size: 20px;
    width: 20px;
    height: 20px;
}

.aict-current-lang {
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.aict-switcher-dropdown {
    position: absolute;
    bottom: 60px;
    right: 0;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    min-width: 250px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.aict-language-switcher:hover .aict-switcher-dropdown,
.aict-language-switcher.active .aict-switcher-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.aict-switcher-header {
    padding: 12px 16px;
    border-bottom: 1px solid #e0e0e0;
    font-weight: 600;
    font-size: 13px;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.aict-language-list {
    list-style: none;
    margin: 0;
    padding: 8px 0;
    max-height: 300px;
    overflow-y: auto;
}

.aict-language-list li {
    margin: 0;
}

.aict-language-list a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    color: #333;
    text-decoration: none;
    transition: background 0.2s ease;
}

.aict-language-list a:hover {
    background: #f5f5f5;
}

.aict-language-list li.active a {
    background: #e8f3f8;
    color: #2271b1;
    font-weight: 600;
}

.aict-lang-code {
    text-transform: uppercase;
    font-weight: 600;
    font-size: 12px;
    color: #666;
    min-width: 50px;
}

.aict-language-list li.active .aict-lang-code {
    color: #2271b1;
}

.aict-lang-name {
    flex: 1;
    font-size: 14px;
}

.aict-language-list .dashicons {
    color: #46b450;
    font-size: 18px;
    width: 18px;
    height: 18px;
}

/* Scrollbar Styling */
.aict-language-list::-webkit-scrollbar {
    width: 6px;
}

.aict-language-list::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.aict-language-list::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 3px;
}

.aict-language-list::-webkit-scrollbar-thumb:hover {
    background: #999;
}

/* Animation for dropdown arrow */
.aict-switcher-dropdown::before {
    content: '';
    position: absolute;
    bottom: -8px;
    right: 20px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 8px solid #fff;
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 768px) {
    .aict-footer-switcher.aict-language-switcher {
        bottom: 15px;
        right: 15px;
    }
    
    .aict-switcher-toggle {
        padding: 10px 16px;
        font-size: 13px;
    }
    
    .aict-switcher-dropdown {
        right: 0;
        min-width: 220px;
    }
    
    .aict-lang-name {
        font-size: 13px;
    }
    
    /* Menu adjustments */
    .aict-menu-language-switcher .aict-lang-submenu {
        position: static;
        box-shadow: none;
        background: transparent;
        padding-left: 20px;
    }
}

@media (max-width: 480px) {
    .aict-footer-switcher.aict-language-switcher {
        bottom: 10px;
        right: 10px;
    }
    
    .aict-switcher-toggle {
        padding: 8px 14px;
        font-size: 12px;
    }
    
    .aict-switcher-dropdown {
        min-width: 200px;
        bottom: 50px;
    }
    
    .aict-current-lang-text {
        display: none;
    }
}
