/* ============================================================
   首页样式 - 覆盖插件默认值 + 移动端响应式
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; }

body {
    background: #1a1a2e;
    font-family: 'Microsoft YaHei', 'trebuchet MS', sans-serif;
}

/* ---- 移动端：降级为网格列表 ---- */
@media (max-width: 860px) {
    /* 重置插件的绝对定位布局 */
    .content-part.part-tese {
        height: auto !important;
        position: static !important;
        padding: 1.5em 16px 3em;
    }

    .page-title {
        font-size: 1.4em !important;
        padding: 0 0 1em !important;
    }

    .part-tese .gallery_container {
        position: static !important;
        width: 100% !important;
        height: auto !important;
        margin: 0 !important;
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }

    .part-tese .gallery_container .gallery_wrap,
    .gallery_wrap.threeD_gallery_wrap {
        position: static !important;
        width: 100% !important;
        height: auto !important;
        margin: 0 !important;
        perspective: none !important;
        display: grid !important;
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
    }

    /* 所有卡片统一显示 */
    .threeD_gallery_item {
        position: relative !important;
        width: 100% !important;
        height: 0 !important;
        padding-bottom: 120% !important;
        transform: none !important;
        opacity: 1 !important;
        pointer-events: auto !important;
        z-index: auto !important;
        border-radius: 10px;
        overflow: hidden;
        box-shadow: 0 4px 12px rgba(0,0,0,0.5);
    }

    .threeD_gallery_item img {
        position: absolute !important;
        top: 0; left: 0;
        width: 100% !important;
        height: 100% !important;
        object-fit: cover;
        visibility: visible !important;
    }

    .item-label {
        position: absolute !important;
        font-size: 1em !important;
    }

    /* 隐藏轮播左右按钮 */
    .gallery_container .prev,
    .gallery_container .next {
        display: none !important;
    }

    /* 线条装饰隐藏 */
    .line-t, .line-r, .line-b, .line-l {
        display: none !important;
    }
}

@media (max-width: 480px) {
    .part-tese .gallery_container .gallery_wrap,
    .gallery_wrap.threeD_gallery_wrap {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px;
    }

    .page-title {
        font-size: 1.2em !important;
    }
}
