/**
 * GLightbox 自定义样式
 * 符合 MTO Moving 设计系统
 * 
 * @package MTO Moving
 * @since 1.0.0
 */

/* ====================================
   灯箱覆盖层
   ==================================== */
.goverlay {
    background: rgba(0, 0, 0, 0.95) !important;
}

/* ====================================
   灯箱容器
   ==================================== */
.gcontainer {
    width: 100%;
    height: 100%;
}

/* ====================================
   图片容器
   ==================================== */
.gslide-image img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

/* ====================================
   描述文字
   ==================================== */
.gslide-description {
    background: rgba(26, 54, 93, 0.95) !important;
    color: #ffffff;
    padding: 16px 24px;
    border-radius: 8px;
    font-family: 'Noto Sans SC', sans-serif;
    font-size: 14px;
    line-height: 1.6;
    margin-top: 20px;
}

/* ====================================
   导航按钮
   ==================================== */
.gnext,
.gprev {
    background: rgba(26, 54, 93, 0.8) !important;
    color: #ffffff !important;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.gnext:hover,
.gprev:hover {
    background: rgba(230, 126, 34, 0.9) !important;
    transform: scale(1.1);
}

.gnext svg,
.gprev svg {
    width: 24px;
    height: 24px;
}

/* ====================================
   关闭按钮
   ==================================== */
.gclose {
    background: rgba(26, 54, 93, 0.8) !important;
    color: #ffffff !important;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    transition: all 0.3s ease;
    top: 20px;
    right: 20px;
}

.gclose:hover {
    background: rgba(231, 76, 60, 0.9) !important;
    transform: rotate(90deg) scale(1.1);
}

.gclose svg {
    width: 22px;
    height: 22px;
}

/* ====================================
   计数器
   ==================================== */
.gslide-count {
    background: rgba(26, 54, 93, 0.8);
    color: #ffffff;
    padding: 8px 16px;
    border-radius: 20px;
    font-family: 'Poppins', sans-serif;
    font-size: 13px;
    font-weight: 500;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
}

/* ====================================
   加载动画
   ==================================== */
.gloader {
    border: 4px solid rgba(255, 255, 255, 0.2);
    border-top: 4px solid #e67e22;
    border-radius: 50%;
    width: 50px;
    height: 50px;
}

/* ====================================
   响应式设计 - 移动端
   ==================================== */
@media (max-width: 768px) {
    .gslide-image img {
        max-width: 95vw;
        max-height: 85vh;
        border-radius: 4px;
    }
    
    .gnext,
    .gprev {
        width: 40px;
        height: 40px;
    }
    
    .gnext svg,
    .gprev svg {
        width: 20px;
        height: 20px;
    }
    
    .gclose {
        width: 36px;
        height: 36px;
        top: 10px;
        right: 10px;
    }
    
    .gclose svg {
        width: 18px;
        height: 18px;
    }
    
    .gslide-description {
        padding: 12px 16px;
        font-size: 13px;
        margin-top: 12px;
    }
    
    .gslide-count {
        padding: 6px 12px;
        font-size: 12px;
        top: 10px;
    }
}

/* ====================================
   画廊图片网格优化
   ==================================== */
.wp-block-gallery.has-nested-images {
    gap: 12px;
}

.wp-block-gallery .wp-block-image {
    margin: 0;
}

.wp-block-gallery .wp-block-image img {
    border-radius: 8px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.wp-block-gallery .wp-block-image img:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

/* ====================================
   单张图片优化
   ==================================== */
.wp-block-image a {
    display: block;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
}

.wp-block-image a::after {
    content: '🔍';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    background: rgba(26, 54, 93, 0.9);
    color: #ffffff;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    transition: all 0.3s ease;
    opacity: 0;
    pointer-events: none;
}

.wp-block-image a:hover::after {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
}

.wp-block-image a:hover img {
    opacity: 0.9;
    transform: scale(1.05);
}

