/*andrew-hp用*/
.page-template-andrewplus-hp-block .site-main {
    width: 100% !important;
    float: none !important;
    margin-right: 0 !important;
/*    padding:0 10%;*/
}
.page-template-andrewplus-hp-block #sidebar,
.page-template-andrewplus-hp-block .sidebar,
.page-template-andrewplus-hp-block aside.widget-area,
.page-template-andrewplus-hp-block .andre-highlight-wrapper{
    display: none !important; /* 强制隐藏任何可能的侧边栏容器 */
}



/* ===== 纯CSS轮播 - 作用域限定在 .site-main 内 ===== */
.site-main .pure-css-slider {
    --slider-height: 56.25vw;
    --slider-max-height: 60vh;
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: min(var(--slider-height), var(--slider-max-height));
    overflow: hidden;
    background: #fcfcfc;
}
/* 鼠标悬停暂停 */
.site-main .pure-css-slider:hover .slide,
.site-main .pure-css-slider:hover .slide-content,
.site-main .pure-css-slider:hover .slider-dots .dot {
    animation-play-state: paused;
}

/* ===== 幻灯片主体 ===== */
.site-main .pure-css-slider .slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* 核心修改：使用 visibility 和 opacity 共同控制 */
    visibility: hidden; /* 隐藏时彻底移除渲染树，解决事件问题 */
    opacity: 0;
    background-size: cover;
   /* background-position:50% 20% ;*/
    background-repeat: no-repeat;
    /* 新动画：控制 visibility 和 opacity */
    animation: slide-fade 15s infinite;
    z-index: 1;
}
/* 幻灯片延迟 */
.site-main .pure-css-slider .slide:nth-child(1) { animation-delay: 0s; }
.site-main .pure-css-slider .slide:nth-child(2) { animation-delay: 3s; }
.site-main .pure-css-slider .slide:nth-child(3) { animation-delay: 6s; }
.site-main .pure-css-slider .slide:nth-child(4) { animation-delay: 9s; }
.site-main .pure-css-slider .slide:nth-child(5) { animation-delay: 12s; }

/* ===== 幻灯片内容区域 ===== */
.site-main .pure-css-slider .slide-content {
    position: absolute;
    top: 10%;
    left: 7%;
    align-content: center;
    /*right: 5%;*/
    max-width: 35%;
    max-height:80%;
    background: rgba(0, 0, 0, 0.3);
    color: #fff;
    padding: 1em;
    border-radius: 8px;
    /* 内容保持自己的透明度动画，确保在父级显示期间出现 */
    opacity: 0;
    animation: content-fade 15s infinite;
    /* 悬停过渡效果 */
    transition: background-color 0.3s ease,
                transform 0.3s ease;
    z-index: 2;
    /* 关键：始终允许指针事件 */
    pointer-events: auto;
}
/* 内容区域动画延迟与幻灯片同步 */
.site-main .pure-css-slider .slide:nth-child(1) .slide-content { animation-delay: 0s; }
.site-main .pure-css-slider .slide:nth-child(2) .slide-content { animation-delay: 3s; }
.site-main .pure-css-slider .slide:nth-child(3) .slide-content { animation-delay: 6s; }
.site-main .pure-css-slider .slide:nth-child(4) .slide-content { animation-delay: 9s; }
.site-main .pure-css-slider .slide:nth-child(5) .slide-content { animation-delay: 12s; }

/* ===== 悬停效果 ===== */
.site-main .pure-css-slider .slide-content:hover {
    background-color: rgba(0,0,0, 0.6);
    transform: translate(2px, 2px);
}

/* ===== 按钮样式 ===== */
.site-main .pure-css-slider .slide-more-btn {
    display: inline-block;
    margin-top: 1rem;
    padding: 0.8rem 1.8rem;
    background: #3498db;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-weight: bold;
    transition: background 0.3s;
}
.site-main .pure-css-slider .slide-more-btn:hover {
    background: #2980b9;
}

/* ===== 指示点样式 ===== */
.site-main .pure-css-slider .slider-dots {
    position: absolute;
    bottom: 20px;
    left: 0;
    right: 0;
    text-align: center;
    z-index: 3;
}
.site-main .pure-css-slider .slider-dots .dot {
    display: inline-block;
    width: 14px;
    height: 14px;
    margin: 0 6px;
    border-radius: 50%;
    border:solid 3px #fff ;
    background: rgba(255, 255, 255, 0.3);
    cursor: default;
    animation: dot-fade 15s infinite;
}
.site-main .pure-css-slider .slider-dots .dot:nth-child(1) { animation-delay: 0s; }
.site-main .pure-css-slider .slider-dots .dot:nth-child(2) { animation-delay: 3s; }
.site-main .pure-css-slider .slider-dots .dot:nth-child(3) { animation-delay: 6s; }
.site-main .pure-css-slider .slider-dots .dot:nth-child(4) { animation-delay: 9s; }
.site-main .pure-css-slider .slider-dots .dot:nth-child(5) { animation-delay: 12s; }

/* ===== 关键帧动画定义 ===== */
/* 1. 幻灯片动画：控制 visibility 和 opacity */
@keyframes slide-fade {
    0% {
        visibility: visible;
        opacity: 0.3;
    }
   /* 1% {
        visibility: visible; /* 提前一帧变为可见，为淡入做准备 */
    /*    opacity: 0.5;
    }*/
    0.5% {
        visibility: visible;
        opacity: 1;
    }
    19% {
        visibility: visible;
        opacity: 1;
    }
    19.5% {
        visibility: visible; /* 淡出后立即隐藏，彻底移除 */
        opacity: 0.3;
    }
    20%{
        visibility: hidden; /* 淡出后立即隐藏，彻底移除 */
        opacity: 0;
    }
    100% {
        visibility: hidden;
        opacity: 0;
    }
}
/* 2. 内容淡入淡出动画 (与幻灯片同步但独立) */
@keyframes content-fade {
    0% { opacity: 0; }
    2% { opacity: 1; }
    19.5% { opacity: 1; }
    20% { opacity: 0; }
    100% { opacity: 0; }
}
/* 3. 指示点高亮动画 */
@keyframes dot-fade {
    0% { background: rgba(255, 255, 255, 0.5); box-shadow: none; }
    2% { background: #fff; box-shadow: 0 0 5px #fff; }
    19.5% { background: #fff; box-shadow: 0 0 5px #fff; }
    20% { background: rgba(255, 255, 255, 0.5); box-shadow: none; }
    100% { background: rgba(255, 255, 255, 0.5); box-shadow: none; }
}

.site-main .pure-css-slider .slide-title{
    color:#ffff6f;
    font-size:1.4em;
}

@media (max-width: 768px) {
    .site-main .pure-css-slider .slide-content p{
        display: -webkit-box;
        -webkit-line-clamp: 2; /* 最多显示2行 */
        -webkit-box-orient: vertical;
        overflow: hidden;
        line-height: 1.4;
    }
    .site-main .pure-css-slider .slide-title{
    color:#fff;
    font-size:1em;
    }  
    .site-main .pure-css-slider .slide-more-btn {
    padding: 4px 6px;
    text-decoration: none;
    font-weight: 500;
    font-size:0.9em;
    transition: background 0.3s;
    }	
    .site-main .pure-css-slider .slide-desc {
    display:none !important;
    }
}

/*andrew-hp-content區塊*/
.andrew-hp-content{
   max-width:1160px;
   margin:0 auto;
}

.andrew-hp-content [class*="wp-container-core-group-is-layout-"] {
  gap:0 !important;
  border: 1px solid #ddd;
  border-radius:15px;
}

.andrew-hp-content .wp-block-post-featured-image img{
  border-radius:15px 15px 0 0;
}
.andrew-hp-content .wp-block-post-title{
   font-size:1.2em;
   font-weight:500;
   padding:10px;
}

.andrew-hp-content .wp-block-post-excerpt{
  padding:10px;
}
.andrew-hp-content .wp-block-post-excerpt__more-text{
  margin:0 auto;
  padding:2px;
  width:100px;
  text-align:center;
  border:solid 1px #ddd; 
}

