/* ===========================================
   Multilingual Press - 前端样式
   =========================================== */

/* --- 文章内语言切换器 --- */
.mlp-language-switcher {
    background: linear-gradient(135deg, #f8f9ff 0%, #f0f4ff 100%);
    border: 1px solid #e0e7ff;
    border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 24px;
    box-shadow: 0 2px 8px rgba(94, 114, 228, 0.08);
}

.mlp-switcher-label {
    font-size: 13px;
    font-weight: 600;
    color: #5e72e4;
    margin-bottom: 10px;
    letter-spacing: 0.5px;
}

.mlp-switcher-items {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.mlp-switcher-item {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 20px;
    border: 1.5px solid #e0e7ff;
    background: #fff;
    color: #525f7f;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none !important;
    transition: all 0.25s ease;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}

.mlp-switcher-item:hover {
    border-color: #5e72e4;
    color: #5e72e4;
    background: #f8f9ff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(94, 114, 228, 0.15);
}

.mlp-switcher-item.mlp-switcher-active {
    background: #5e72e4;
    border-color: #5e72e4;
    color: #fff;
    box-shadow: 0 4px 12px rgba(94, 114, 228, 0.25);
}

.mlp-switcher-item.mlp-switcher-active:hover {
    background: #4a5fd4;
    border-color: #4a5fd4;
}

.mlp-flag {
    font-size: 16px;
    line-height: 1;
}

.mlp-lang-name {
    line-height: 1;
}

.mlp-ai-badge {
    font-size: 10px;
    font-weight: 700;
    background: #f0c674;
    color: #5a3e00;
    padding: 2px 6px;
    border-radius: 8px;
    line-height: 1.2;
    letter-spacing: 0.3px;
}

.mlp-switcher-item.mlp-switcher-active .mlp-ai-badge {
    background: rgba(255,255,255,0.25);
    color: #fff;
}

/* --- 导航栏语言切换器 --- */
.mlp-nav-switcher {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-left: 12px;
    padding: 4px 6px;
    background: rgba(255,255,255,0.1);
    border-radius: 8px;
}

.mlp-nav-item {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    font-size: 18px;
    text-decoration: none !important;
    transition: all 0.2s ease;
    opacity: 0.6;
    filter: grayscale(0.5);
}

.mlp-nav-item:hover {
    opacity: 1;
    filter: grayscale(0);
    background: rgba(255,255,255,0.15);
    transform: scale(1.1);
}

.mlp-nav-item.mlp-nav-active {
    opacity: 1;
    filter: grayscale(0);
    background: rgba(255,255,255,0.2);
    box-shadow: 0 0 0 2px rgba(255,255,255,0.3);
}

/* --- 暗色模式适配 --- */
@media (prefers-color-scheme: dark) {
    .mlp-language-switcher {
        background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
        border-color: #2a2a4a;
    }
    
    .mlp-switcher-label {
        color: #7c8cf0;
    }
    
    .mlp-switcher-item {
        background: #1e1e3a;
        border-color: #2a2a4a;
        color: #b0b8d0;
    }
    
    .mlp-switcher-item:hover {
        border-color: #5e72e4;
        color: #7c8cf0;
        background: #252550;
    }
    
    .mlp-nav-switcher {
        background: rgba(0,0,0,0.2);
    }
}

/* --- 响应式 --- */
@media (max-width: 768px) {
    .mlp-switcher-items {
        gap: 6px;
    }
    
    .mlp-switcher-item {
        padding: 6px 12px;
        font-size: 13px;
    }
    
    .mlp-nav-switcher {
        margin-left: 6px;
        padding: 3px 4px;
    }
    
    .mlp-nav-item {
        width: 28px;
        height: 28px;
        font-size: 16px;
    }
}
