.nt-language-switcher {
    align-items: center;
    display: inline-flex;
    gap: 8px;
}

.nt-language-switcher select {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 6px;
    color: #333;
    font: inherit;
    font-size: 14px;
    font-weight: 500;
    min-height: 36px;
    padding: 6px 32px 6px 12px;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 14px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.nt-language-switcher select:focus {
    border-color: #007cba;
    box-shadow: 0 0 0 1px #007cba;
    outline: none;
}

.nt-language-switcher--links {
    display: inline-flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    font-size: 14px;
    font-weight: 500;
}

.nt-language-switcher__link {
    color: #666;
    text-decoration: none;
    transition: color 0.2s ease, border-bottom-color 0.2s ease;
    padding-bottom: 2px;
    border-bottom: 2px solid transparent;
}

.nt-language-switcher__link:hover {
    color: #111;
}

.nt-language-switcher__link.is-active {
    color: #111;
    font-weight: 700;
    border-bottom-color: currentColor;
}

/* ==========================================================================
   WordPress Widget Area / Theme Compatibility
   ========================================================================== */

/* Centering and alignment inside header widget area */
[data-id="widget-area-1"]:has(.nt-language-switcher),
.ct-widget:has(.nt-language-switcher),
.widget_block:has(.nt-language-switcher) {
    display: flex !important;
    align-items: center !important;
    align-self: center !important;
    justify-content: center !important;
    height: 100% !important;
}

/* Hide empty <p> elements injected by wpautop in widgets containing our switcher */
.ct-widget:has(.nt-language-switcher) > p:empty,
.widget_block:has(.nt-language-switcher) > p:empty {
    display: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* ==========================================================================
   Mobile Off-Canvas Panel Theme Compatibility (Green Background Support)
   ========================================================================== */

/* Change link switcher text to white inside the mobile panel */
.ct-panel-content[data-device="mobile"] .nt-language-switcher__link {
    color: rgba(255, 255, 255, 0.75) !important;
    font-size: 15px !important;
}

.ct-panel-content[data-device="mobile"] .nt-language-switcher__link:hover {
    color: #ffffff !important;
}

.ct-panel-content[data-device="mobile"] .nt-language-switcher__link.is-active {
    color: #ffffff !important;
    border-bottom-color: #ffffff !important;
}

/* Support select box design in green mobile panel */
.ct-panel-content[data-device="mobile"] .nt-language-switcher select {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
    color: #ffffff !important;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e") !important;
}

.ct-panel-content[data-device="mobile"] .nt-language-switcher select:focus {
    border-color: rgba(255, 255, 255, 0.5) !important;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.3) !important;
}
