/* MDgroup 多语言样式 */

/* 语言切换器 */
.product-language-switcher,
.archive-language-switcher {
    margin: 20px 0;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.language-switcher-frontend {
    display: inline-block;
}

.language-switcher-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 10px;
}

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

.language-switcher-list a {
    display: block;
    padding: 8px 16px;
    text-decoration: none;
    color: #495057;
    background-color: white;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.3s ease;
}

.language-switcher-list a:hover {
    background-color: #e9ecef;
    border-color: #007cba;
    color: #007cba;
}

.language-switcher-list .current-language a {
    background-color: #007cba;
    color: white;
    border-color: #007cba;
}

/* 语言徽章 */
.language-badge {
    display: inline-block;
    padding: 3px 8px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 3px;
    text-transform: uppercase;
    margin-right: 5px;
}

.language-zh {
    background-color: #e6f7ff;
    color: #0066cc;
    border: 1px solid #91d5ff;
}

.language-en {
    background-color: #fff2e8;
    color: #d4380d;
    border: 1px solid #ffbb96;
}

/* 翻译计数 */
.translation-count {
    font-size: 11px;
    color: #6c757d;
    margin-top: 2px;
    font-style: italic;
}

/* 产品基本信息样式 */
.product-basic-info {
    margin: 15px 0 25px;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 6px;
    border-left: 4px solid #007cba;
}

.product-model,
.product-certification,
.product-warranty {
    margin-bottom: 8px;
    font-size: 15px;
    line-height: 1.4;
}

.product-model strong,
.product-certification strong,
.product-warranty strong {
    color: #007cba;
    margin-right: 8px;
}

/* 产品图库缩略图 */
.gallery-thumbnails {
    display: flex;
    gap: 10px;
    margin-top: 15px;
    overflow-x: auto;
    padding: 10px 0;
}

.gallery-thumbnail {
    width: 80px;
    height: 80px;
    border: 2px solid transparent;
    border-radius: 4px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.gallery-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-thumbnail:hover {
    border-color: #007cba;
    transform: translateY(-2px);
}

.gallery-thumbnail.active {
    border-color: #007cba;
    box-shadow: 0 4px 8px rgba(0, 124, 186, 0.2);
}

/* RTL语言支持 */
[dir="rtl"] .language-switcher-list {
    flex-direction: row-reverse;
}

[dir="rtl"] .product-basic-info {
    border-left: none;
    border-right: 4px solid #007cba;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .language-switcher-list {
        flex-direction: column;
        gap: 8px;
    }
    
    .language-switcher-list a {
        width: 100%;
        text-align: center;
    }
    
    .gallery-thumbnails {
        gap: 8px;
    }
    
    .gallery-thumbnail {
        width: 60px;
        height: 60px;
    }
}

/* 管理界面样式 */
.language-switcher .current-language {
    background: #f0f0f0;
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 4px;
    font-weight: bold;
}

.language-switcher .translation-link {
    margin-bottom: 8px;
}

.language-switcher .button {
    width: 100%;
    text-align: center;
    margin-bottom: 5px;
}

/* 多语言面包屑 */
.product-breadcrumb {
    margin-bottom: 20px;
    font-size: 14px;
    color: #6c757d;
}

.product-breadcrumb a {
    color: #007cba;
    text-decoration: none;
}

.product-breadcrumb a:hover {
    text-decoration: underline;
}

.product-breadcrumb .breadcrumb-separator {
    margin: 0 8px;
    color: #adb5bd;
}

.product-breadcrumb .current {
    color: #495057;
    font-weight: 500;
}

/* 多语言表单元素 */
.multilingual-field {
    margin-bottom: 20px;
    padding: 15px;
    background-color: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #dee2e6;
}

.multilingual-field .language-tabs {
    display: flex;
    gap: 5px;
    margin-bottom: 15px;
    border-bottom: 1px solid #dee2e6;
}

.multilingual-field .language-tab {
    padding: 8px 16px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    font-size: 14px;
    font-weight: 500;
    color: #6c757d;
    cursor: pointer;
    transition: all 0.3s ease;
}

.multilingual-field .language-tab:hover {
    color: #007cba;
}

.multilingual-field .language-tab.active {
    color: #007cba;
    border-bottom-color: #007cba;
}

.multilingual-field .language-content {
    display: none;
}

.multilingual-field .language-content.active {
    display: block;
}

/* 多语言切换按钮 */
.language-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background-color: white;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    color: #495057;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.language-toggle:hover {
    background-color: #f8f9fa;
    border-color: #007cba;
    color: #007cba;
}

.language-toggle.active {
    background-color: #007cba;
    border-color: #007cba;
    color: white;
}

.language-toggle .language-flag {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    overflow: hidden;
}

.language-toggle .language-flag img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 多语言内容容器 */
.multilingual-content {
    position: relative;
}

.multilingual-content .content-wrapper {
    display: none;
}

.multilingual-content .content-wrapper.active {
    display: block;
}

/* 多语言SEO标签样式 */
.multilingual-seo {
    background-color: #e8f5e8;
    border: 1px solid #c3e6cb;
    border-radius: 4px;
    padding: 15px;
    margin: 20px 0;
}

.multilingual-seo h4 {
    margin-top: 0;
    color: #155724;
}

.multilingual-seo ul {
    margin: 10px 0 0 0;
    padding-left: 20px;
}

.multilingual-seo li {
    margin-bottom: 5px;
    color: #0c5460;
}

.multilingual-seo .language-badge {
    margin-right: 8px;
}