/* ===== 长师校史 · 时光轴样式 ===== */

/* ===== 时光轴容器（嵌入 s4 区域） ===== */
.s4-timeline-section {
    position: relative;
    width: 100%;
    margin: 0 auto 0.4rem;
    padding: 0 clamp(8px, 2vw, 40px);
    user-select: none;
}

/* ===== 时间轴主线 ===== */
.s4-timeline-section .tl-rail {
    position: absolute;
    left: clamp(16px, 4vw, 80px);
    right: clamp(16px, 4vw, 80px);
    bottom: clamp(18px, 2.5vw, 40px);
    height: 2px;
    background: linear-gradient(90deg,
        transparent 0%, rgba(183,148,110,0.10) 5%,
        rgba(183,148,110,0.35) 15%, rgba(183,148,110,0.60) 50%,
        rgba(183,148,110,0.35) 85%, rgba(183,148,110,0.10) 95%, transparent 100%);
    pointer-events: none;
}
.s4-timeline-section .tl-rail::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: -6px;
    height: 13px;
    background: radial-gradient(ellipse at center, rgba(183,148,110,0.10) 0%, transparent 70%);
    filter: blur(4px);
}

/* ===== 年份节点 ===== */
.s4-timeline-section .tl-nodes {
    position: absolute;
    left: clamp(22px, 4.5vw, 90px);
    right: clamp(22px, 4.5vw, 90px);
    bottom: clamp(13px, 2vw, 34px);
    height: 10px;
    pointer-events: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.s4-timeline-section .tl-nodes .node {
    width: clamp(3px, 0.4vw, 6px);
    height: clamp(3px, 0.4vw, 6px);
    border-radius: 50%;
    background: rgba(183,148,110,0.20);
    border: 1px solid rgba(183,148,110,0.10);
    transition: all .6s ease;
    flex-shrink: 0;
}
.s4-timeline-section .tl-nodes .node.active,
.s4-timeline-section .tl-nodes .node.decade.active {
    width: clamp(7px, 0.8vw, 12px);
    height: clamp(7px, 0.8vw, 12px);
    background: #b8946e;
    box-shadow: 0 0 12px rgba(183,148,110,0.35);
    border-color: rgba(183,148,110,0.3);
}
.s4-timeline-section .tl-nodes .node.decade {
    width: clamp(4px, 0.5vw, 8px);
    height: clamp(4px, 0.5vw, 8px);
    background: rgba(183,148,110,0.35);
    border-color: rgba(183,148,110,0.15);
}

/* ===== 滚动轨道 ===== */
.s4-timeline-section .tl-track {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: clamp(8px, 1.5vw, 20px) clamp(8px, 1.5vw, 20px) clamp(52px, 6vw, 100px);
    scrollbar-width: none;
    -ms-overflow-style: none;
    cursor: grab;
    mask-image: linear-gradient(90deg, transparent 0%, #000 3%, #000 97%, transparent 100%);
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 3%, #000 97%, transparent 100%);
}
.s4-timeline-section .tl-track::-webkit-scrollbar { display: none; }
.s4-timeline-section .tl-track.dragging { cursor: grabbing; scroll-behavior: auto; }

/* ===== 卡片 ===== */
.s4-timeline-section .tl-card {
    flex: 0 0 auto;
    width: 4.62rem;
    border-radius: 0.12rem;
    overflow: hidden;
    position: relative;
    transition: transform .6s cubic-bezier(.34,1.56,.64,1), box-shadow .6s ease;
    opacity: 0;
    transform: translateY(40px) scale(0.94);
    perspective: 800px;
    margin: 0 0.2rem;
}
.s4-timeline-section .tl-card.visible { opacity: 1; transform: translateY(0) scale(1); }
.s4-timeline-section .tl-card::before {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: clamp(11px, 1.1vw, 17px);
    padding: 1px;
    background: linear-gradient(150deg,
        rgba(183,148,110,0.25), rgba(200,185,165,0.08) 35%,
        rgba(220,210,195,0.08) 65%, rgba(183,148,110,0.20));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
    transition: opacity .6s ease;
}
.s4-timeline-section .tl-card:hover::before {
    background: linear-gradient(150deg,
        rgba(183,148,110,0.45), rgba(200,185,165,0.20) 35%,
        rgba(230,220,205,0.12) 65%, rgba(183,148,110,0.30));
}
.s4-timeline-section .tl-card-inner {
    background: #ffffff;
    border-radius: clamp(10px, 1vw, 16px);
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,.08), 0 1px 3px rgba(0,0,0,.05);
    transition: box-shadow .5s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}
.s4-timeline-section .tl-card:hover .tl-card-inner {
    box-shadow: 0 12px 40px rgba(0,0,0,.12), 0 0 0 1px rgba(183,148,110,0.15);
}

/* ===== 图片区域 ===== */
.s4-timeline-section .tl-img-wrap {
    width: 100%;
    padding-top: 56%;
    overflow: hidden;
    background: #f0ebe3;
    position: relative;
}
.s4-timeline-section .tl-img-wrap::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, transparent 60%, rgba(245,240,232,0.5) 90%, rgba(245,240,232,1) 100%);
    pointer-events: none;
    opacity: 0.4;
    transition: opacity .5s ease;
    z-index: 3;
}
.s4-timeline-section .tl-card:hover .tl-img-wrap::after { opacity: 0.2; }
.s4-timeline-section .tl-img-wrap img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    z-index: 2;
    transition: transform .8s cubic-bezier(.34,1.56,.64,1);
}
.s4-timeline-section .tl-card:hover .tl-img-wrap img { transform: scale(1.08); }

/* ===== 年份徽章 ===== */
.s4-timeline-section .tl-year-badge {
    position: absolute;
    top: clamp(8px, 1.2vw, 18px);
    left: clamp(8px, 1.2vw, 18px);
    z-index: 3;
    background: rgba(90,62,43,0.80);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: #f5f0e8;
    font-size: clamp(12px, 1.1vw, 17px);
    font-weight: 700;
    padding: clamp(3px, 0.4vw, 6px) clamp(10px, 1.2vw, 18px) clamp(3px, 0.4vw, 6px) clamp(8px, 1vw, 14px);
    border-radius: 30px;
    border: 1px solid rgba(183,148,110,0.20);
    box-shadow: 0 2px 12px rgba(0,0,0,.15);
    display: inline-flex;
    align-items: center;
    gap: clamp(3px, 0.4vw, 6px);
    pointer-events: none;
    line-height: 1.2;
}
.s4-timeline-section .tl-year-badge i {
    font-size: clamp(11px, 0.9vw, 14px);
    opacity: 0.7;
    color: #c9b896;
}

/* ===== 骨架屏 ===== */
.s4-timeline-section .tl-skeleton {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(110deg, #e8e0d5 30%, #f0ebe3 50%, #e8e0d5 70%);
    background-size: 200% 100%;
    animation: tlShimmer 1.8s ease-in-out infinite;
    z-index: 1;
    transition: opacity .6s ease;
}
.s4-timeline-section .tl-skeleton.loaded { opacity: 0; }
@keyframes tlShimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* ===== 导航按钮 ===== */
.s4-timeline-section .tl-nav-btn {
    position: absolute;
    top: 42%;
    transform: translateY(-50%);
    z-index: 10;
    width: clamp(32px, 3.5vw, 60px);
    height: clamp(32px, 3.5vw, 60px);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all .4s cubic-bezier(.34,1.56,.64,1);
    color: #5a3e2b;
    font-size: clamp(13px, 1.5vw, 24px);
    background: rgba(255,255,255,0.80);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid rgba(183,148,110,0.15);
    box-shadow: 0 4px 20px rgba(0,0,0,.06), inset 0 1px 0 rgba(255,255,255,0.9);
}
.s4-timeline-section .tl-nav-btn:hover {
    background: rgba(255,255,255,0.95);
    border-color: rgba(183,148,110,0.35);
    box-shadow: 0 8px 32px rgba(0,0,0,.10);
    transform: translateY(-50%) scale(1.08);
}
.s4-timeline-section .tl-nav-btn:active { transform: translateY(-50%) scale(.90); }
.s4-timeline-section .tl-nav-btn.prev { left: clamp(-4px, 0.5vw, 60px); }
.s4-timeline-section .tl-nav-btn.next { right: clamp(-4px, 0.5vw, 60px); }

/* ===== 入场动画 ===== */
@keyframes tlCardIn {
    0%   { opacity: 0; transform: translateY(50px) scale(0.92) rotateX(4deg); }
    80%  { transform: translateY(-4px) scale(1.01); }
    100% { opacity: 1; transform: translateY(0) scale(1) rotateX(0); }
}
.s4-timeline-section .tl-card.animating {
    animation: tlCardIn .7s cubic-bezier(.34,1.56,.64,1) forwards;
}

/* ===== 4K 超大屏适配 ===== */
@media (min-width: 2000px) {
    .s4-timeline-section .tl-card { width: 4.62rem; }
}

