/**
 * Block: Hero Slider
 */
.my-corp-hero-slider {
    position: relative;
    width: 100%;
    /* 【终极修复 1】：必须给最外层一个绝对高度！否则绝对定位会导致高度塌陷为 0 */
    height: 800px; /* 默认高度 */
    height: 100vh; /* 推荐：撑满整个屏幕可视区域 (Viewport Height) */
    min-height: 600px; 
    background-color: #111 !important; 
    overflow: hidden;
}

/* 【终极修复 2】：强制 Swiper 的所有层级继承 100% 高度 */
.my-corp-hero-slider .swiper,
.my-corp-hero-slider .swiper-container,
.my-corp-hero-slider .swiper-wrapper,
.my-corp-hero-slider .swiper-slide {
    width: 100%;
    height: 100% !important; 
}

.my-corp-hero-slider .swiper-slide {
    position: relative;
    overflow: hidden;
    background-color: #111 !important;
    z-index: 0;
}

.my-corp-hero-slider .swiper-slide-active {
    z-index: 1;
}

/* 【终极修复 3】：强制内部 Cover 区块撑满 Slide */
.my-corp-hero-slider .wp-block-cover,
.my-corp-hero-slider .wp-block-cover__image-background {
    width: 100% !important;
    height: 100% !important;
    min-height: 100% !important;
    margin: 0 !important;
    object-fit: cover !important;
    vertical-align: bottom;
    background-color: #111 !important;
}

/* 解决 JS 加载前的白屏闪烁 (FOUC) */
.my-corp-hero-slider .swiper:not(.swiper-initialized) .swiper-wrapper {
    display: block;
}
.my-corp-hero-slider .swiper:not(.swiper-initialized) .swiper-slide:not(:first-child) {
    display: none !important;
}

/* 黑色渐变遮罩 (让文字更清晰) */
.my-corp-hero-slider .swiper-slide::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.6) 0%, rgba(0,0,0,0) 40%);
    z-index: 1;
    pointer-events: none;
}

/* 内部文字容器 (Cover 区块内容) */
.my-corp-hero-slider .wp-block-cover__inner-container {
    position: absolute;
    bottom: 15%;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1200px;
    z-index: 2;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

/* 文字进场动画 */
.my-corp-hero-slider h1, 
.my-corp-hero-slider h2, 
.my-corp-hero-slider p {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.8s ease-out;
}

.my-corp-hero-slider .swiper-slide-active h1, 
.my-corp-hero-slider .swiper-slide-active h2,
.my-corp-hero-slider .swiper-slide-active p {
    opacity: 1;
    transform: translateY(0);
}

.my-corp-hero-slider .swiper-slide-active p {
    transition-delay: 0.2s;
}

/* 导航按钮 */
.my-corp-hero-slider .swiper-button-next, 
.my-corp-hero-slider .swiper-button-prev {
    color: #fff;
    background: rgba(0,0,0,0.2);
    width: 50px; height: 50px;
    border-radius: 50%;
    transition: background 0.3s;
}
.my-corp-hero-slider .swiper-button-next:hover, 
.my-corp-hero-slider .swiper-button-prev:hover {
    background: var(--mc-primary);
}
.my-corp-hero-slider .swiper-button-next::after, 
.my-corp-hero-slider .swiper-button-prev::after {
    font-size: 20px; font-weight: bold;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .my-corp-hero-slider { 
        height: 500px; 
    }
}