.wrpf-news-page {
    padding: 10px 0 50px;
}

.wrpf-news-page__inner {
    width: 100%;
    margin: 0 auto;
}

.wrpf-news-toolbar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
    margin: 0 0 16px;
}

.wrpf-news-view-switcher {
    display: flex;
    gap: 8px;
}

.wrpf-news-view-button {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    min-height: 40px;
    padding: 0 14px !important;
    border: 1px solid #d8d4cc !important;
    border-radius: var(--wrpf-news-card-radius, 2px);
    background: #fff !important;
    color: #222 !important;
    font-family: "Oswald", "Arial Narrow", sans-serif !important;
    font-size: 12px !important;
    font-weight: 600;
    letter-spacing: .06em;
    line-height: 1;
    text-transform: uppercase;
    cursor: pointer;
}

.wrpf-news-view-button:hover,
.wrpf-news-view-button.is-active {
    border-color: var(--wrpf-red, #e63323) !important;
    background: var(--wrpf-red, #e63323) !important;
    color: #fff !important;
}

.wrpf-news-view-icon {
    position: relative;
    display: inline-grid;
    flex: 0 0 auto;
    width: 15px;
    height: 15px;
}

.wrpf-news-view-icon--grid {
    display: block;
}

.wrpf-news-view-icon--grid::before {
    content: "";
    position: absolute;
    top: 1px;
    left: 1px;
    width: 5px;
    height: 5px;
    background: currentColor;
    box-shadow: 8px 0 0 currentColor, 0 8px 0 currentColor, 8px 8px 0 currentColor;
}

.wrpf-news-view-icon--list::before {
    content: "";
    width: 15px;
    height: 3px;
    margin-top: 1px;
    background: currentColor;
    box-shadow: 0 5px 0 currentColor, 0 10px 0 currentColor;
}

.wrpf-news-filters-wrap {
    display: none;
}

.wrpf-news-year-picker {
    position: relative;
    z-index: 8;
}

.wrpf-news-year-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    min-width: 146px;
    min-height: 40px;
    padding: 0 14px !important;
    border: 1px solid #d8d4cc !important;
    border-radius: var(--wrpf-news-card-radius, 2px);
    background: #fff !important;
    color: #222 !important;
    font-family: var(--wrpf-font-menu, "Roboto Condensed", sans-serif) !important;
    font-size: 12px !important;
    font-weight: 600;
    letter-spacing: .06em;
    line-height: 1;
    text-transform: uppercase;
    cursor: pointer;
}

.wrpf-news-year-toggle:hover,
.wrpf-news-year-picker.is-open .wrpf-news-year-toggle {
    border-color: var(--wrpf-red, #e63323) !important;
}

.wrpf-news-year-caret {
    width: 7px;
    height: 7px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: translateY(-2px) rotate(45deg);
    transition: transform .18s ease;
}

.wrpf-news-year-picker.is-open .wrpf-news-year-caret {
    transform: translateY(2px) rotate(225deg);
}

.wrpf-news-year-menu {
    position: absolute;
    top: calc(100% + 7px);
    left: 0;
    display: none;
    width: 100%;
    max-height: 310px;
    padding: 7px;
    overflow-y: auto;
    border: 1px solid #d8d4cc;
    background: #fff;
    box-shadow: 0 18px 36px rgba(20, 20, 20, .16);
}

.wrpf-news-year-picker.is-open .wrpf-news-year-menu {
    display: block;
}

.wrpf-news-year-option {
    display: flex;
    align-items: center;
    gap: 9px;
    width: 100%;
    min-height: 35px;
    padding: 7px 9px !important;
    border: 0 !important;
    background: transparent !important;
    color: #222 !important;
    font-family: var(--wrpf-font-body, "Roboto Condensed", sans-serif) !important;
    font-size: 13px !important;
    font-weight: 600;
    text-align: left;
    cursor: pointer;
}

.wrpf-news-year-option:hover {
    background: #f3f1ed !important;
}

.wrpf-news-year-check {
    width: 14px;
    color: var(--wrpf-red, #e63323);
    font-size: 13px;
    opacity: 0;
}

.wrpf-news-year-option.is-active .wrpf-news-year-check {
    opacity: 1;
}

.wrpf-news-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
}

.wrpf-news-filter {
    appearance: none;
    border: 1px solid #d9d9d9;
    background: #fff;
    color: #111;
    padding: 11px 18px;
    border-radius: var(--wrpf-news-card-radius, 2px);
    font-family: var(--wrpf-font-body, "Roboto Condensed", sans-serif);
    font-size: 13px;
    line-height: 1;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.2s ease;
}

.wrpf-news-filter:hover {
    border-color: #c70016;
    color: #c70016;
    transform: translateY(-1px);
}

.wrpf-news-filter.is-active {
    background: #c70016;
    border-color: #c70016;
    color: #fff;
    box-shadow: 0 8px 20px rgba(199, 0, 22, 0.16);
}

.wrpf-news-content {
    position: relative;
    min-height: 180px;
}

.wrpf-news-content.is-loading::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.68);
    z-index: 2;
}

.wrpf-news-content.is-loading::before {
    content: "";
    position: absolute;
    top: 40px;
    left: 50%;
    width: 42px;
    height: 42px;
    margin-left: -21px;
    border: 3px solid rgba(199, 0, 22, 0.18);
    border-top-color: #c70016;
    border-radius: 50%;
    animation: wrpfNewsSpin 0.7s linear infinite;
    z-index: 3;
}

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

.wrpf-news-grid {
    display: grid;
    grid-template-columns: repeat(var(--wrpf-news-columns, 2), minmax(0, 1fr));
    gap: 28px;
}

.wrpf-news-page .wrpf-news-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid #dedad2;
    border-radius: var(--wrpf-news-card-radius, 2px);
    overflow: hidden;
    box-shadow: 0 14px 34px rgba(21, 22, 25, 0.07);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.wrpf-news-page .wrpf-news-card:hover {
    border-color: rgba(230, 51, 35, 0.42);
    transform: translateY(-4px);
    box-shadow: 0 20px 42px rgba(21, 22, 25, 0.12);
}

.wrpf-news-card__thumb-link {
    display: block;
    position: relative;
    height: auto;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: #ddd;
    line-height: 0;
}

.wrpf-news-card__thumb-link::after {
    content: none;
}

.wrpf-news-card__thumb-link img.wrpf-news-card__image,
.wrpf-news-card__thumb-link .wrpf-news-card__image {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    object-fit: cover !important;
    object-position: center center !important;
    transform: none;
}

.wrpf-news-card:hover .wrpf-news-card__thumb-link .wrpf-news-card__image {
    transform: none;
}

.wrpf-news-card__image--placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #1b1b1b 0%, #444 100%);
}

.wrpf-news-page .wrpf-news-card__body {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    flex: 1;
    padding: 20px 20px 22px;
}

.wrpf-content .wrpf-news-page .wrpf-news-card .wrpf-news-card__title {
    margin: 0 0 18px;
    font-family: var(--wrpf-font-h3, "Roboto Condensed", sans-serif);
    font-size: var(--wrpf-news-title-size, 16px);
    line-height: 1.45;
    font-weight: 700;
    letter-spacing: normal;
    text-transform: none;
}

.wrpf-news-page.is-list-view .wrpf-news-grid {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.wrpf-news-page.is-list-view .wrpf-news-card {
    display: grid;
    grid-template-columns: minmax(160px, var(--wrpf-news-list-image-width, 250px)) minmax(0, 1fr);
    min-height: 300px;
}

.wrpf-news-page.is-list-view .wrpf-news-card__thumb-link {
    width: 100%;
    height: auto;
    min-height: 300px;
    aspect-ratio: 3 / 4;
}

.wrpf-news-page.is-list-view .wrpf-news-card__body {
    justify-content: center;
    padding: clamp(24px, 4vw, 52px);
}

.wrpf-content .wrpf-news-page.is-list-view .wrpf-news-card .wrpf-news-card__title {
    max-width: 780px;
    font-size: clamp(var(--wrpf-news-title-size, 16px), 2.2vw, 28px);
    line-height: 1.3;
}

.wrpf-content .wrpf-news-page .wrpf-news-card .wrpf-news-card__title a {
    color: #111;
    text-decoration: none;
}

.wrpf-content .wrpf-news-page .wrpf-news-card .wrpf-news-card__title a:hover {
    color: #c70016;
}

.wrpf-news-page .wrpf-news-card__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    margin-top: auto;
    padding: 0 18px;
    border: 2px solid var(--wrpf-red, #e63323);
    border-radius: var(--wrpf-news-card-radius, 2px);
    background: var(--wrpf-red, #e63323);
    color: #fff;
    text-decoration: none;
    font-family: "Oswald", "Arial Narrow", sans-serif;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    transition: background 0.2s ease, transform 0.2s ease;
    align-self: flex-start;
}

.wrpf-news-page .wrpf-news-card__button:hover {
    border-color: var(--wrpf-red-dark, #b61f16);
    background: var(--wrpf-red-dark, #b61f16);
    color: #fff !important;
    transform: translateY(-1px);
}

.wrpf-content .wrpf-news-page .wrpf-news-card__button:hover,
.wrpf-content .wrpf-news-page .wrpf-news-card__button:focus {
    color: #fff !important;
}

.wrpf-news-pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-top: 34px;
}

.wrpf-page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    padding: 0 14px;
    border-radius: var(--wrpf-news-card-radius, 2px);
    background: #fff;
    color: #111;
    text-decoration: none;
    font-weight: 700;
    border: 1px solid #e2e2e2;
    transition: all 0.2s ease;
}

.wrpf-page-numbers:hover {
    border-color: #c70016;
    color: #c70016;
}

.wrpf-page-numbers.current {
    background: #c70016;
    border-color: #c70016;
    color: #fff;
}

.wrpf-news-empty {
    background: #fff;
    border-radius: var(--wrpf-news-card-radius, 2px);
    padding: 28px;
    text-align: center;
    color: #666;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
}

@media (max-width: 1199px) {
    .wrpf-news-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .wrpf-news-card__thumb-link { height: auto; }
}

@media (max-width: 767px) {
    .wrpf-news-page__inner {
        width: 100%;
    }

    .wrpf-news-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .wrpf-news-filter {
        padding: 10px 14px;
        font-size: 13px;
    }

    .wrpf-news-card__thumb-link { height: auto; }

    .wrpf-news-page .wrpf-news-card__body {
        padding: 16px;
    }

    .wrpf-content .wrpf-news-page .wrpf-news-card .wrpf-news-card__title {
        font-size: var(--wrpf-news-title-size, 16px);
        margin-bottom: 16px;
    }

    .wrpf-news-toolbar {
        justify-content: flex-start;
        flex-wrap: wrap;
    }

    .wrpf-news-page.is-list-view .wrpf-news-card {
        grid-template-columns: 112px minmax(0, 1fr);
        min-height: 168px;
    }

    .wrpf-news-page.is-list-view .wrpf-news-card__thumb-link {
        min-height: 168px;
        aspect-ratio: 3 / 4;
    }

    .wrpf-news-page.is-list-view .wrpf-news-card__body {
        padding: 16px;
    }

    .wrpf-content .wrpf-news-page.is-list-view .wrpf-news-card .wrpf-news-card__title {
        font-size: 15px;
        line-height: 1.35;
    }

    .wrpf-news-page.is-list-view .wrpf-news-card__button {
        min-height: 36px;
        padding-inline: 13px;
        font-size: 11px;
    }
}
