/**
 * Casa Vogue Luxury Language Switcher Styles
 */

.cv-lang-switcher {
    position: relative;
    display: inline-block;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 13px;
    z-index: 1000;
}

.cv-switcher-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(17, 20, 26, 0.05);
    border: 1px solid rgba(197, 160, 89, 0.3);
    border-radius: 20px;
    padding: 5px 12px;
    cursor: pointer;
    color: #1a1a1a;
    font-weight: 600;
    font-size: 12px;
    letter-spacing: 0.5px;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.cv-switcher-btn:hover,
.cv-lang-switcher.is-open .cv-switcher-btn {
    background: #11141a;
    color: #c5a059;
    border-color: #c5a059;
    box-shadow: 0 4px 12px rgba(197, 160, 89, 0.2);
}

.cv-flag {
    font-size: 15px;
    line-height: 1;
    display: inline-block;
}

.cv-lang-code {
    font-weight: 700;
    letter-spacing: 0.5px;
}

.cv-chevron {
    transition: transform 0.25s ease;
}

.cv-lang-switcher.is-open .cv-chevron {
    transform: rotate(180deg);
}

/* Dropdown Menu */
.cv-switcher-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 170px;
    background: #11141a;
    border: 1px solid rgba(197, 160, 89, 0.35);
    border-radius: 10px;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
    padding: 6px 0;
    margin: 0;
    list-style: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 10001;
}

/* Open state */
.cv-lang-switcher.is-open .cv-switcher-menu,
.cv-lang-switcher:hover .cv-switcher-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.cv-switcher-item {
    margin: 0;
    padding: 0;
}

.cv-switcher-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 14px;
    color: #e2e8f0;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.15s ease;
}

.cv-switcher-link:hover {
    background: rgba(197, 160, 89, 0.15);
    color: #c5a059;
    padding-left: 18px;
}

.cv-switcher-item.is-active .cv-switcher-link {
    color: #c5a059;
    font-weight: 700;
    background: rgba(197, 160, 89, 0.08);
}

.cv-native-name {
    flex-grow: 1;
    font-size: 13px;
}

.cv-code-pill {
    font-size: 10px;
    padding: 2px 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    color: #94a3b8;
    font-weight: 600;
}

.cv-switcher-item.is-active .cv-code-pill {
    background: rgba(197, 160, 89, 0.2);
    color: #c5a059;
}

/* RTL Adjustments for Switcher */
body[dir="rtl"] .cv-switcher-menu,
.cv-lang-ar .cv-switcher-menu {
    right: auto;
    left: 0;
}

body[dir="rtl"] .cv-switcher-link:hover,
.cv-lang-ar .cv-switcher-link:hover {
    padding-left: 14px;
    padding-right: 18px;
}

/* Top bar integration styling */
#cv-topbar-switcher {
    margin-left: 16px;
}

body[dir="rtl"] #cv-topbar-switcher,
.cv-lang-ar #cv-topbar-switcher {
    margin-left: 0;
    margin-right: 16px;
}

/* Mobile Nav Drawer Switcher */
#cv-mobile-switcher {
    padding: 12px 16px;
}

#cv-mobile-switcher .cv-switcher-btn {
    width: 100%;
    justify-content: space-between;
    padding: 8px 14px;
}

#cv-mobile-switcher .cv-switcher-menu {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    border: none;
    background: transparent;
    padding-top: 10px;
}

#cv-mobile-switcher .cv-switcher-link {
    padding: 8px 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}
