/* 日期模块样式 */
/* 核心容器：减少不必要的样式 */
.festival-wrapper {
    position: relative;
    padding: 10px 0;
    min-height: 140px;
    margin: 5px 0;
    width: 100%;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 卡片容器：简化过渡效果，减少性能消耗 */
.festival-container { 
    display: flex; 
    gap: 10px;
    overflow-x: auto; 
    padding: 10px 0;
    min-height: 120px; 
    -webkit-overflow-scrolling: touch; 
    scroll-snap-type: x mandatory; 
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    -ms-overflow-style: none;
    width: calc(100% - 80px);
    max-width: 100%;
    transition: width 0.2s ease; /* 只保留必要过渡 */
}

/* 居中状态 */
.festival-container.centered {
    width: 100%;
    justify-content: center;
    overflow-x: visible;
}

/* 隐藏滚动条 */
.festival-container::-webkit-scrollbar {
    display: none;
}

/* 卡片样式：简化transform，减少GPU消耗 */
.festival-card { 
    background: #fff; 
    border-radius: 0;
    padding: 12px 16px; 
    min-width: 100px; 
    flex-shrink: 0; 
    cursor: pointer;
    font-family: "Microsoft Yahei", sans-serif;
    box-shadow: none;
    border: none;
    scroll-snap-align: start;
    text-align: center;
}

/* 今天卡片高亮 */
.festival-card.today {
    border: 2px solid #3B82F6;
    background-color: #EFF6FF;
}

/* 节气卡片标识 颜色修改为 #3B82F6 */
.festival-card.jieqi {
    border-left: 3px solid #3B82F6;
}

/* 卡片交互：简化hover效果 */
.festival-card:hover { 
    background-color: #fafafa; 
}

/* 文本样式 */
.festival-card h3 { 
    margin: 0 0 2px 0; 
    font-size: 14px; 
    font-weight: 500; 
    color: #333;
    line-height: 1.3;
}
.festival-card.today h3 {
    color: #3B82F6;
    font-weight: 600;
}
/* 节气标题颜色修改为 #3B82F6 */
.festival-card.jieqi h3 {
    color: #3B82F6;
}
.festival-card .date {
    font-size: 12px; 
    color: #999;
    margin: 2px 0;
}

/* 天数标签 */
.festival-card .days-left {
    display: inline-block;
    background: #F5F5F5;
    color: #FF6B00;
    font-size: 14px;
    font-weight: bold;
    width: 24px;
    height: 24px;
    line-height: 24px;
    border-radius: 50%;
    margin: 4px 0;
}
.festival-card.today .days-left {
    background: #3B82F6;
    color: #fff;
}
.festival-card .days-text {
    font-size: 12px;
    color: #999;
    margin-top: -4px;
}

/* 按钮样式：简化过渡 */
.festival-btn { 
    position: absolute; 
    top: 50%; 
    transform: translateY(-50%);
    width: 36px; 
    height: 36px; 
    border-radius: 50%; 
    background: #3B82F6; 
    color: white; 
    border: none; 
    cursor: pointer; 
    z-index: 10; 
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease; /* 只保留透明度过渡 */
}
.festival-btn.show {
    opacity: 1;
    pointer-events: auto;
}
.festival-btn:hover { 
    background: #2563eb; 
}
.prev-btn { left: 10px; }
.next-btn { right: 10px; }
