
    /* --- 1. 基础容器与标题 ---   材料切片版块 */
    .materials-container {
        max-width: 1600px;
        /* 设置上下内边距为 20px，左右为 20px */
        padding: 20px 20px; 
        margin: 0 auto;
        font-family: Arial, sans-serif;
        text-align: center;
        color: #333;
        background-color: #f5f5f5;
        box-sizing: border-box;
    }

    .materials-container .main-title {
        font-size: 28px;
        color: #0f403f;
        font-weight: bold;
        margin-bottom: 25px;
    }

    /* --- 2. 导航标签样式 --- */
    .material-tabs {
        display: flex;
        justify-content: center;
        gap: 40px;
        margin-bottom: 30px;
        border-bottom: 1px solid #e5e5e5;
    }

    .tab-btn {
        padding: 12px 5px;
        cursor: pointer;
        font-size: 16px;
        color: #666;
        position: relative;
        transition: all 0.3s ease;
        background: none;
        border: none;
        outline: none;
    }

    .tab-btn:hover {
        color: #0f403f;
    }

    .tab-btn.active {
        color: #0f403f;
        font-weight: bold;
    }

    .tab-btn.active::after {
        content: '';
        position: absolute;
        bottom: -1px;
        left: 0;
        width: 100%;
        height: 3px;
        background-color: #0f403f;
    }

    /* --- 3. 网格布局与交互内容 --- */
    .tab-content {
        display: none; 
        grid-template-columns: repeat(5, 1fr); 
        gap: 15px;
        animation: fadeIn 0.5s ease;
    }

    .tab-content.active {
        display: grid; 
    }

    @keyframes fadeIn {
        from { opacity: 0; transform: translateY(10px); }
        to { opacity: 1; transform: translateY(0); }
    }

    /* --- 4. 单个材料卡片与悬停效果 --- */
    .material-item {
        position: relative;
        aspect-ratio: 1 / 1; 
        overflow: hidden;
        border-radius: 4px;
        background-color: #f5f5f5;
        cursor: pointer;
    }

    .material-item img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
        transition: transform 0.5s ease;
    }

    .material-hover-overlay {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        /* 稍微加深了背景色 (0.5)，确保白色文字更清晰 */
        background-color: rgba(0, 0, 0, 0.5) !important; 
        display: flex;
        align-items: center;
        justify-content: center;
        opacity: 0; 
        transition: opacity 0.3s ease;
        padding: 10px;
        box-sizing: border-box;
    }

    .material-item:hover .material-hover-overlay {
        opacity: 1; 
    }

    .material-item:hover img {
        transform: scale(1.1); 
    }

    .material-name-text {
    color: #ffffff !important;       /* 强制使用纯白色 */
    font-size: 18px !important;    /* 增大字号 */
    font-weight: bold !important;  /* 加粗 */
    line-height: 1.4;
    opacity: 1 !important;         /* 确保透明度是 100% */
    display: inline-block;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.5); /* 增加微弱阴影，让白色在亮色图片上更清晰 */
}

    /* --- 5. 移动端兼容性调整 --- */
    @media (max-width: 768px) {
        .material-tabs {
            gap: 15px;
            overflow-x: auto;
            white-space: nowrap;
            justify-content: flex-start;
            padding-bottom: 5px;
        }
        
        .tab-btn {
            font-size: 14px;
            padding: 10px 5px;
        }

        .tab-content {
            grid-template-columns: repeat(2, 1fr); 
            gap: 10px;
        }

        .material-name-text {
            font-size: 15px; /* 移动端文字也同步稍微加大 */
        }
    }
