/* 格式页面样式 */

.formats-hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 100px 0;
    text-align: center;
}

.formats-hero h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    font-weight: 700;
}

.formats-hero p {
    font-size: 1.3rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}


.formats-main {
    padding: 40px 0;
}

.page-header {
    text-align: center;
    margin-bottom: 60px;
}

.page-header h1 {
    font-size: 2.8rem;
    color: #2c3e50;
    margin-bottom: 20px;
}

.page-header p {
    font-size: 1.2rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

/* 格式分类导航（整合统计信息） */
.format-nav {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 50px;
    flex-wrap: wrap;
    padding: 0 20px;
    background: white;
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
}

.format-nav-btn {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border: 2px solid #dee2e6;
    padding: 24px 32px;
    border-radius: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 1.1rem;
    color: #495057;
    min-width: 180px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    backdrop-filter: blur(10px);
}

.format-nav-btn::before {
    display: none;
}



.format-nav-btn:hover {
    border-color: #3498db;
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
}

.format-nav-btn.active {
    border-color: #2980b9;
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
}

.format-nav-btn i {
    font-size: 2.5rem;
    color: #3498db;
}

.format-nav-btn:hover i,
.format-nav-btn.active i {
    color: #4b558b;
}

.nav-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 3px;
    position: relative;
    z-index: 1;
}

.nav-label {
    font-size: 1.2rem;
    font-weight: 600;
    letter-spacing: 0.3px;
}

.nav-count {
    font-size: 1rem;
    font-weight: 700;
    opacity: 0.75;

    padding: 4px 12px;
    border-radius: 14px;
    min-width: 28px;
    text-align: center; /* 左右居中 */
    width: 100%; /* 确保占据全部宽度 */
}

.format-nav-btn:hover .nav-count,
.format-nav-btn.active .nav-count {
    opacity: 1;
}

.format-nav-btn:not(.active):not(:hover) .nav-count {

    color: #6c757d;
}

/* 搜索框 */
.format-search {
    max-width: 500px;
    margin: 0 auto 60px;
}

.search-box {
    position: relative;
}

.search-box i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #bdc3c7;
}

.search-box input {
    width: 100%;
    padding: 15px 15px 15px 45px;
    border: 2px solid #ecf0f1;
    border-radius: 25px;
    font-size: 1rem;
}

.search-box input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

/* 格式内容区域 */
.formats-content {
    background: white;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.format-category {
    margin-bottom: 60px;
}

.format-category:last-child {
    margin-bottom: 0;
}

.format-category h2 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.format-category h2 i {
    color: #3498db;
}

/* 格式网格 */
.format-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

/* 格式项链接样式 */
.format-item-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.format-item-link:hover {
    text-decoration: none;
    color: inherit;
}

.format-item {
    background: #f8f9fa;
    border: 2px solid #ecf0f1;
    border-radius: 10px;
    padding: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 15px;
    position: relative;
    overflow: hidden;
}

.format-item::before {
    display: none;
}

.format-item:hover {
    border-color: #3498db;
    background: #ebf3fd;
}





.format-item .format-icon {
    font-size: 2.5rem;
    color: #3498db;
    min-width: 60px;
    text-align: center;
}

.format-item .format-icon i {
    display: inline-block;
}

.format-info {
    flex: 1;
}

.format-info h3 {
    font-size: 1.3rem;
    color: #2c3e50;
    margin-bottom: 8px;
}

.format-info p {
    color: #666;
    margin-bottom: 10px;
    font-size: 1rem;
    line-height: 1.4;
}

.format-ext {
    background: #3498db;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
    display: inline-block;
}

.format-ext-more {
    background: #95a5a6;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
    display: inline-block;
    margin-left: 5px;
}

/* 转换矩阵样式 */
.conversion-matrix {
    margin-top: 60px;
    text-align: center;
}

.conversion-matrix h2 {
    font-size: 1.8rem;
    color: #2c3e50;
    margin-bottom: 15px;
}

.conversion-matrix p {
    color: #666;
    margin-bottom: 20px;
}

/* 矩阵筛选器样式 */
.matrix-filter {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.matrix-filter label {
    font-weight: 600;
    color: #2c3e50;
    font-size: 1rem;
}

.matrix-filter select {
    padding: 10px 15px;
    border: 2px solid #ecf0f1;
    border-radius: 8px;
    background: white;
    color: #2c3e50;
    font-size: 1rem;
    cursor: pointer;
    min-width: 150px;
}

.matrix-filter select:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.matrix-filter select:hover {
    border-color: #3498db;
}

.matrix-container {
    overflow-x: auto;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.conversion-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 10px;
    overflow: hidden;
}

.conversion-table th,
.conversion-table td {
    padding: 15px;
    text-align: center;
    border-bottom: 1px solid #ecf0f1;
}

.conversion-table th {
    background: #3498db;
    color: white;
    font-weight: 600;
}

.conversion-table td:first-child {
    background: #f8f9fa;
    font-weight: 600;
    color: #2c3e50;
}

.supported {
    color: #27ae60;
    font-weight: bold;
    font-size: 1.2rem;
}

.not-supported {
    color: #e74c3c;
    font-weight: bold;
    font-size: 1.2rem;
}

/* 动画已禁用 */
.animate-in {
    /* 动画已禁用 */
}

/* 性能优化 */
.format-item,
.format-category,
.format-nav-btn {
    /* 性能优化属性已移除 */
}

/* 减少重绘和回流 */
.formats-content {
    /* contain属性已移除 */
}

/* 所有动画已全局禁用 */

/* 触摸设备优化 */
@media (hover: none) and (pointer: coarse) {
    .format-item:hover {
        /* 动画已禁用 */
    }
}

/* 响应式设计 */
@media (max-width: 768px) {

    .formats-hero h1 {
        font-size: 2.5rem;
    }

    .formats-main {
        padding: 20px 0;
    }
    
    .page-header h1 {
        font-size: 2.2rem;
    }
    
    .format-stats {
        gap: 15px;
    }
    
    .stat-card {
        padding: 20px;
        min-width: 120px;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .format-nav {
        gap: 15px;
        padding: 0 15px;
    }
    
    .format-nav-btn {
        padding: 15px 22px;
        font-size: 0.9rem;
        min-width: 140px;
        gap: 12px;
    }
    
    .format-nav-btn i {
        font-size: 1.1rem;
    }
    
    .nav-count {
        font-size: 0.75rem;
        padding: 1px 6px;
    }
    
    .formats-content {
        padding: 20px;
        border-radius: 15px;
    }
    
    .format-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .format-item {
        padding: 15px;
    }
    
    .format-item .format-icon {
        font-size: 2rem;
        min-width: 50px;
    }
    
    .format-info h3 {
        font-size: 1.1rem;
    }
    
    .format-info p {
        font-size: 0.9rem;
    }
    
    .conversion-table th,
    .conversion-table td {
        padding: 10px 8px;
        font-size: 0.9rem;
    }
    
    .matrix-filter {
        flex-direction: column;
        gap: 10px;
    }
    
    .matrix-filter select {
        min-width: 200px;
    }
}

@media (max-width: 480px) {
    .page-header h1 {
        font-size: 1.8rem;
    }
    
    .page-header p {
        font-size: 1rem;
    }
    
    .format-stats {
        flex-direction: column;
        align-items: center;
    }
    
    .stat-card {
        width: 100%;
        max-width: 200px;
    }
    
    .format-nav {
        flex-direction: column;
        align-items: center;
        gap: 12px;
        padding: 0 10px;
    }
    
    .format-nav-btn {
        width: 100%;
        max-width: 280px;
        justify-content: center;
        padding: 16px 24px;
        min-width: auto;
    }
    
    .format-nav-btn:hover {
        transform: translateY(-2px) scale(1.01);
    }
    
    .format-item {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .format-item .format-icon {
        min-width: auto;
    }
}