/* 学习资源页面 - 置顶新闻样式 */
/* 深色科技风格主题 */

.sticky-news-container {
    background: linear-gradient(135deg, rgba(15, 15, 35, 0.9), rgba(26, 26, 58, 0.9));
    border: 1px solid rgba(102, 126, 234, 0.4);
    border-radius: 15px;
    padding: 25px;
    margin: 25px 0;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(15px);
}

.sticky-news-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        linear-gradient(45deg, transparent 30%, rgba(102, 126, 234, 0.05) 50%, transparent 70%),
        radial-gradient(circle at 30% 70%, rgba(240, 147, 251, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 70% 30%, rgba(102, 126, 234, 0.1) 0%, transparent 50%);
    animation: matrix 10s linear infinite;
    pointer-events: none;
}

.sticky-news-container::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, #667eea, #f093fb, transparent);
    animation: scan 4s linear infinite;
}

.sticky-news-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
    position: relative;
    z-index: 2;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(102, 126, 234, 0.2);
}

.sticky-news-icon {
    font-size: 24px;
    color: #667eea;
    animation: digitalPulse 3s ease-in-out infinite;
    text-shadow: 0 0 10px rgba(102, 126, 234, 0.5);
}

.sticky-news-label {
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 18px;
    font-weight: 600;
    color: #ffffff;
    text-shadow: 0 0 15px rgba(102, 126, 234, 0.6);
    letter-spacing: 2px;
    text-transform: uppercase;
}

.sticky-news-content {
    display: flex;
    gap: 25px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(102, 126, 234, 0.2);
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 20px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: 2;
    backdrop-filter: blur(10px);
}

.sticky-news-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(240, 147, 251, 0.1));
    opacity: 0;
    transition: all 0.3s ease;
    border-radius: 12px;
}

.sticky-news-content::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 3px;
    height: 100%;
    background: linear-gradient(180deg, #667eea, #f093fb);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.sticky-news-content:hover::before {
    opacity: 1;
}

.sticky-news-content:hover::after {
    opacity: 1;
}

.sticky-news-content:hover {
    transform: translateY(-5px) translateX(5px);
    box-shadow: 
        0 15px 40px rgba(102, 126, 234, 0.3),
        -5px 0 20px rgba(240, 147, 251, 0.2);
    border-color: rgba(102, 126, 234, 0.6);
}

.sticky-news-image {
    flex-shrink: 0;
    width: 140px;
    height: 105px;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(102, 126, 234, 0.4);
    position: relative;
}

.sticky-news-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        linear-gradient(45deg, transparent 30%, rgba(102, 126, 234, 0.2) 50%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
}

.sticky-news-content:hover .sticky-news-image::before {
    opacity: 1;
    animation: scan-image 1s ease-in-out;
}

.sticky-news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.4s ease;
    filter: brightness(0.8) contrast(1.2) saturate(1.1);
}

.sticky-news-content:hover .sticky-news-image img {
    transform: scale(1.05);
    filter: brightness(1) contrast(1.3) saturate(1.2);
}

.sticky-news-image-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #0f0f23, #1a1a3a);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #667eea;
    font-size: 28px;
    position: relative;
    border: 1px solid rgba(102, 126, 234, 0.3);
}

.sticky-news-image-placeholder::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent, rgba(102, 126, 234, 0.1), transparent);
    animation: matrix-scan 3s infinite;
}

.sticky-news-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
    z-index: 1;
}

.sticky-news-badge {
    display: inline-block;
    background: linear-gradient(135deg, #667eea, #f093fb);
    color: white;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    align-self: flex-start;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.5);
    animation: neonGlow 2s ease-in-out infinite alternate;
    letter-spacing: 1px;
    text-transform: uppercase;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
}

.sticky-news-badge::before {
    content: '>>> ';
    font-size: 9px;
    opacity: 0.8;
}

.sticky-news-title {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 17px;
    font-weight: 600;
    color: #ffffff;
    margin: 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

.sticky-news-summary {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.sticky-news-meta {
    display: flex;
    gap: 20px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    margin-top: auto;
    align-items: center;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
}

.sticky-news-category {
    background: linear-gradient(135deg, rgba(15, 15, 35, 0.8), rgba(26, 26, 58, 0.8));
    color: #667eea;
    padding: 4px 12px;
    border-radius: 12px;
    font-weight: 600;
    border: 1px solid rgba(102, 126, 234, 0.4);
    backdrop-filter: blur(5px);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sticky-news-category::before {
    content: '[TAG] ';
    font-size: 9px;
    opacity: 0.7;
}

.sticky-news-date {
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
}

.sticky-news-date::before {
    content: '[TIME] ';
    font-size: 9px;
    opacity: 0.7;
}

.sticky-news-loading {
    text-align: center;
    padding: 50px;
    color: #667eea;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 16px;
    font-weight: 600;
    position: relative;
    z-index: 2;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.sticky-news-loading::before {
    content: '[LOADING] ';
    font-size: 14px;
    animation: blink 1s infinite;
}

.sticky-news-error {
    text-align: center;
    padding: 50px;
    color: #f093fb;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 16px;
    font-weight: 600;
    position: relative;
    z-index: 2;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.sticky-news-error::before {
    content: '[ERROR] ';
    font-size: 14px;
    animation: blink 0.5s infinite;
}

/* 动画效果 */
@keyframes matrix {
    0% {
        transform: translateY(0);
    }
    100% {
        transform: translateY(-100px);
    }
}

@keyframes scan {
    0% {
        transform: translateX(-100%);
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        transform: translateX(100%);
        opacity: 0;
    }
}

@keyframes digitalPulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
        text-shadow: 0 0 10px rgba(102, 126, 234, 0.5);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.05);
        text-shadow: 0 0 20px rgba(102, 126, 234, 0.8);
    }
}

@keyframes neonGlow {
    from {
        box-shadow: 0 4px 15px rgba(102, 126, 234, 0.5);
        text-shadow: 0 0 5px rgba(255, 255, 255, 0.5);
    }
    to {
        box-shadow: 0 6px 25px rgba(102, 126, 234, 0.8);
        text-shadow: 0 0 10px rgba(255, 255, 255, 0.8);
    }
}

@keyframes scan-image {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

@keyframes matrix-scan {
    0% {
        transform: translateX(-100%) translateY(-100%);
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        transform: translateX(100%) translateY(100%);
        opacity: 0;
    }
}

@keyframes blink {
    0%, 50% {
        opacity: 1;
    }
    51%, 100% {
        opacity: 0.3;
    }
}

/* 响应式设计 */
@media (max-width: 768px) {
    .sticky-news-content {
        flex-direction: column;
        gap: 20px;
    }
    
    .sticky-news-image {
        width: 100%;
        height: 140px;
    }
    
    .sticky-news-meta {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
}

@media (max-width: 480px) {
    .sticky-news-container {
        padding: 20px;
        margin: 20px 0;
    }
    
    .sticky-news-content {
        padding: 20px;
    }
    
    .sticky-news-image {
        height: 120px;
    }
    
    .sticky-news-title {
        font-size: 16px;
    }
    
    .sticky-news-summary {
        font-size: 13px;
    }
    
    .sticky-news-label {
        font-size: 16px;
        letter-spacing: 1px;
    }
}