/* ========================================== */
/* news.css — под хижиной (отступ ~70px)      */
/* ========================================== */

.news-section {
    max-width: 1000px;
    margin: 50px auto 28px;
    padding: 0 50px;
    box-sizing: border-box;
}

.news-section.is-collapsed {
    display: none;
}

.news-section__panel {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.1);
    animation: newsPanelIn 0.2s ease;
}

@keyframes newsPanelIn {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}

.news-section__topbar {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 16px 48px 8px 14px;
}

.news-section__title {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    color: #1a6b6d;
    letter-spacing: 0.02em;
}

.news-section__close {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.06);
    color: #666;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s, color 0.15s;
}

.news-section__close:hover {
    background: rgba(244, 67, 54, 0.15);
    color: #e53935;
}

.news-section__inner {
    padding: 8px 18px 18px;
}

.news-section__loading,
.news-section__error {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 28px 12px;
    color: #888;
    font-size: 13px;
}

.news-section__error {
    flex-direction: column;
    color: #c62828;
}

.news-section__spinner {
    width: 18px;
    height: 18px;
    border: 2px solid #e0e0e0;
    border-top-color: #1a6b6d;
    border-radius: 50%;
    animation: newsSpin 0.7s linear infinite;
}

@keyframes newsSpin {
    to { transform: rotate(360deg); }
}

.news-section__retry-btn {
    margin-top: 8px;
    padding: 6px 14px;
    border: 1px solid #1a6b6d;
    border-radius: 8px;
    background: #fff;
    color: #1a6b6d;
    font-size: 12px;
    font-family: inherit;
    cursor: pointer;
}

.news-section__retry-btn:hover {
    background: #1a6b6d;
    color: #fff;
}

.news-sources {
    display: flex;
    gap: 7px;
    margin-bottom: 14px;
    flex-wrap: wrap;
}

.news-source-btn {
    padding: 4px 11px;
    border: 1px solid #e0e0e0;
    background: #fafafa;
    color: #555;
    border-radius: 20px;
    font-size: 12px;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s ease;
}

.news-source-btn:hover {
    border-color: #455060;
    color: #455060;
}

.news-source-btn.active {
    background: #455060;
    border-color: #455060;
    color: #fff;
}

.news-legal {
    margin: 0 0 10px;
    padding: 0;
    font-size: 11px;
    line-height: 1.35;
    color: rgba(40, 65, 80, 0.45);
}

.news-date-header {
    font-size: 12px;
    font-weight: 600;
    color: rgba(40, 65, 80, 0.5);
    letter-spacing: 0.02em;
    padding: 6px 0 8px;
}

.news-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.news-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 9px 0;
    border-bottom: 1px solid #f5f5f5;
    text-decoration: none;
    color: inherit;
    transition: background 0.15s;
}

.news-item:last-child {
    border-bottom: none;
}

.news-item:hover {
    background: #fafafa;
    margin: 0 -8px;
    padding-left: 8px;
    padding-right: 8px;
    border-radius: 6px;
}

.news-item__num {
    font-size: 13px;
    color: #6b7a8d;
    font-weight: 700;
    min-width: 18px;
    flex-shrink: 0;
    padding-top: 1px;
}

.news-item__content {
    flex: 1;
}

.news-item__title {
    font-size: 13px;
    font-weight: 500;
    color: #222;
    line-height: 1.4;
    margin-bottom: 3px;
}

.news-item__excerpt {
    font-size: 12px;
    color: rgba(40, 65, 80, 0.55);
    line-height: 1.4;
    margin-top: 2px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-item__date {
    font-size: 11px;
    color: #aaa;
}

.news-source-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 0 4px;
    border-top: 1px solid rgba(40, 65, 80, 0.1);
    margin-top: 4px;
}

.news-source-footer__name {
    font-size: 12px;
    font-weight: 600;
    color: #455060;
}

.news-source-footer__link {
    font-size: 12px;
    color: #1a6b6d;
    text-decoration: none;
}

.news-source-footer__link:hover {
    text-decoration: underline;
}

.news-source-footer__save {
    margin-left: auto;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 1px solid #1a6b6d;
    background: #fff;
    color: #1a6b6d;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.news-source-footer__save:hover {
    background: #1a6b6d;
    color: #fff;
}

@media (max-width: 880px) {
    .news-section {
        padding: 0 12px;
        margin: 40px auto 20px;
    }
}

@media (max-width: 490px) {
    .news-section {
        padding: 0 8px;
        margin-top: 32px;
    }
    .news-section__inner {
        padding: 8px 12px 14px;
    }
    .news-item__title {
        font-size: 12px;
    }
}
