/* ==========================================================================
   SISTEMA DE TRADUCCIÓN MULTILINGÜE - ESTILOS CÓSMICOS DORADOS
   Idiomas: Español (ES), Inglés (EN), Francés (FR), Italiano (IT), Portugués (PT), Alemán (DE)
   ========================================================================== */

.lang-selector-wrapper {
    position: relative;
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
    z-index: 1000;
}

.lang-btn-current {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    background: linear-gradient(135deg, rgba(20, 27, 45, 0.95) 0%, rgba(10, 15, 30, 0.95) 100%);
    border: 1px solid rgba(245, 158, 11, 0.45);
    border-radius: 30px;
    padding: 0.38rem 0.75rem;
    color: #FDE68A;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5), inset 0 0 10px rgba(245, 158, 11, 0.15);
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    outline: none;
    user-select: none;
}

.lang-btn-current:hover,
.lang-btn-current.active {
    border-color: #F59E0B;
    color: #FFFFFF;
    background: linear-gradient(135deg, rgba(30, 42, 70, 0.95) 0%, rgba(15, 23, 42, 0.95) 100%);
    box-shadow: 0 0 18px rgba(245, 158, 11, 0.45), inset 0 0 12px rgba(245, 158, 11, 0.25);
    transform: translateY(-1px);
}

.lang-flag-current {
    font-size: 1.1rem;
    line-height: 1;
    filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.5));
}

.lang-code-current {
    font-family: 'Cinzel', 'Outfit', sans-serif;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.lang-arrow-icon {
    width: 12px;
    height: 12px;
    fill: #F59E0B;
    transition: transform 0.25s ease;
}

.lang-btn-current.active .lang-arrow-icon {
    transform: rotate(180deg);
}

/* Menú Desplegable */
.lang-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 185px;
    background: rgba(8, 14, 28, 0.98);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1.5px solid rgba(245, 158, 11, 0.5);
    border-radius: 12px;
    padding: 0.45rem;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.9), 0 0 30px rgba(245, 158, 11, 0.3);
    display: none;
    flex-direction: column;
    gap: 0.25rem;
    z-index: 99999;
    transform-origin: top right;
    animation: langDropdownFade 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.lang-dropdown-menu.show {
    display: flex !important;
}

@keyframes langDropdownFade {
    0% {
        opacity: 0;
        transform: translateY(-6px) scale(0.96);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.lang-option {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    width: 100%;
    padding: 0.45rem 0.65rem;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 8px;
    color: #CBD5E1;
    font-size: 0.82rem;
    font-weight: 500;
    text-align: left;
    cursor: pointer;
    transition: all 0.18s ease;
    outline: none;
}

.lang-option:hover {
    background: rgba(245, 158, 11, 0.15);
    border-color: rgba(245, 158, 11, 0.3);
    color: #FDE68A;
    padding-left: 0.85rem;
}

.lang-option.selected {
    background: linear-gradient(90deg, rgba(245, 158, 11, 0.25) 0%, rgba(245, 158, 11, 0.08) 100%);
    border-color: #F59E0B;
    color: #FFFFFF;
    font-weight: 700;
}

.lang-option-flag {
    font-size: 1.15rem;
    line-height: 1;
}

.lang-option-name {
    flex: 1;
}

.lang-option-code {
    font-size: 0.72rem;
    color: #94A3B8;
    font-weight: 700;
    letter-spacing: 0.05em;
    padding: 0.1rem 0.3rem;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.05);
}

.lang-option.selected .lang-option-code {
    color: #FCD34D;
    background: rgba(245, 158, 11, 0.2);
}

/* ==========================================================================
   OCULTAR ELEMENTOS INVASIVOS DE GOOGLE TRANSLATE
   Preservar el diseño cósmico sin barras superiores ni banners
   ========================================================================== */
body {
    top: 0px !important;
    position: relative !important;
}

.goog-te-banner-frame,
.goog-te-banner-frame.skiptranslate,
iframe.goog-te-banner-frame {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    width: 0 !important;
    opacity: 0 !important;
}

#google_translate_element {
    position: absolute;
    top: -9999px;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
}

.goog-tooltip,
.goog-tooltip:hover,
.goog-text-highlight {
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

#goog-gt-tt,
.goog-te-balloon-frame {
    display: none !important;
    visibility: hidden !important;
}

/* Animación sutil de pulso al cambiar de idioma */
.lang-translating-pulse {
    animation: langPulse 0.6s ease-in-out;
}

@keyframes langPulse {
    0% { opacity: 0.85; filter: blur(1px); }
    50% { opacity: 0.7; filter: blur(2px); }
    100% { opacity: 1; filter: blur(0px); }
}

@media (max-width: 680px) {
    .lang-btn-current {
        padding: 0.3rem 0.55rem;
        font-size: 0.75rem;
    }
    .lang-code-current {
        display: none;
    }
}
