
/* Latest Topics Section */
.latest-topics-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 20px 0;
    border-bottom: 2px solid #dee2e6;
    position: relative;
    z-index: 100;
}

.latest-topics-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.latest-topics-title {
    font-size: 18px;
    font-weight: 600;
    color: #495057;
    margin-bottom: 15px;
    text-align: center;
}

.latest-topics-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 400px;
    overflow: hidden;
}

.topic-item {
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 12px 16px;
    transition: all 0.3s ease;
    transform: translateY(0);
    opacity: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.topic-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
    border-color: #667eea;
}

.topic-item.slide-out {
    transform: translateY(-100%);
    opacity: 0;
    margin-bottom: -60px;
}

.topic-item.slide-in {
    transform: translateY(100%);
    opacity: 0;
    animation: slideIn 0.5s ease forwards;
}

@keyframes slideIn {
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.topic-content {
    flex: 1;
}

.topic-title {
    font-size: 14px;
    font-weight: 400;
    color: #333;
    margin: 0;
    line-height: 1.4;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
    display: inline;
}

.topic-meta {
    font-size: 12px;
    color: #666;
    display: inline;
    margin-left: 8px;
}

.topic-date, .topic-partner {
    display: flex;
    align-items: center;
    gap: 4px;
}

.topic-title-link {
    color: #333;
    text-decoration: none;
    transition: color 0.2s ease;
}

.topic-title-link:hover {
    color: #0056b3;
    text-decoration: underline;
}

.topic-title-link:hover .topic-title {
    color: #0056b3;
}

/* Responsive */
@media (max-width: 768px) {
    .latest-topics-title {
        font-size: 16px;
    }

    .topic-item {
        padding: 10px 12px;
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .topic-title {
        white-space: normal;
        overflow: visible;
        text-overflow: initial;
    }

    .topic-meta {
        align-self: flex-start;
    }
}

/* Modern Latest Topics Section */
.latest-topics-modern {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    border-radius: 20px;
    padding: 40px 30px;
    margin: 40px 0;
    box-shadow: 0 20px 40px rgba(15, 52, 96, 0.4);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.topics-header {
    text-align: center;
    margin-bottom: 30px;
    position: relative;
    z-index: 2;
}

.topics-header .latest-topics-title {
    color: white;
    font-size: 1.2rem;
    margin-bottom: 0;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
    font-weight: 600;
    text-align: center;
}

.topics-header .latest-topics-title .badge {
    background: rgba(255, 215, 0, 0.2);
    color: #ffd700;
    border: 1px solid rgba(255, 215, 0, 0.4);
    font-size: 0.6em;
    animation: glow 2s ease-in-out infinite alternate;
    margin-left: 8px;
    padding: 0.3em 0.6em;
    border-radius: 4px;
    display: inline-block;
    position: relative;
    top: -2px;
    font-weight: 500;
    letter-spacing: 0.5px;
    vertical-align: middle;
}

@keyframes glow {
    from { box-shadow: 0 0 5px rgba(255, 215, 0, 0.3); }
    to { box-shadow: 0 0 20px rgba(255, 215, 0, 0.6); }
}

/* Добавляем геометрические фигуры для стиля */
.latest-topics-modern::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(255,255,255,0.05) 0%, transparent 70%);
    border-radius: 50%;
    z-index: 1;
}

.latest-topics-modern::after {
    content: '';
    position: absolute;
    bottom: -20%;
    left: -5%;
    width: 200px;
    height: 200px;
    background: linear-gradient(45deg, rgba(0,123,255,0.1) 0%, transparent 70%);
    border-radius: 50%;
    z-index: 1;
}

.latest-topics-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
    z-index: 2;
    max-height: none;
}

.latest-topics-list .topic-item {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 12px 16px;
    transition: all 0.3s ease;
    transform: translateY(0);
    opacity: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    position: relative;
}

.latest-topics-list .topic-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
    background: rgba(255, 255, 255, 1);
    border-color: rgba(0, 123, 255, 0.3);
}

.latest-topics-list .topic-item.slide-out {
    transform: translateY(-20px);
    opacity: 0;
}

.latest-topics-list .topic-item.slide-in {
    transform: translateY(20px);
    opacity: 0;
    animation: slideInModern 0.5s ease forwards;
}

@keyframes slideInModern {
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Topic item content styling */
.latest-topics-list .topic-item .topic-content {
    flex: 1;
}

.latest-topics-list .topic-item .topic-title {
    font-size: 14px;
    font-weight: 400;
    color: #333;
    margin: 0;
    line-height: 1.4;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
    display: inline;
}

.latest-topics-list .topic-item .topic-meta {
    font-size: 12px;
    color: #666;
    display: inline;
    margin-left: 8px;
}

.latest-topics-list .topic-item .topic-title-link {
    color: #333;
    text-decoration: none;
    transition: color 0.2s ease;
}

.latest-topics-list .topic-item:hover .topic-title-link {
    color: #667eea;
}

.latest-topics-list .topic-item:hover .topic-title {
    color: #667eea;
}

/* Responsive for modern version */
@media (max-width: 768px) {
    .latest-topics-modern {
        margin: 20px 0;
        padding: 25px 20px;
        border-radius: 15px;
    }
    
    .topics-header .latest-topics-title {
        font-size: 1rem;
    }

    .latest-topics-list .topic-item {
        padding: 10px 12px;
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .latest-topics-list .topic-item:hover {
        transform: translateY(-2px);
    }
    
    .latest-topics-list .topic-item .topic-title {
        font-size: 13px;
    }
    
    .latest-topics-list .topic-item .topic-meta {
        font-size: 11px;
        align-self: flex-start;
    }
}
