.news-page {
    --news-bg: #121212;
    --news-surface: #1e1e1e;
    --news-surface-raised: #262626;
    --news-border: rgba(255, 255, 255, 0.1);
    --news-accent: #ff9e44;
    --news-accent-soft: rgba(255, 158, 68, 0.12);
    --news-text: #f5f5f5;
    --news-muted: #aaaaaa;
    min-width: 320px;
    min-height: 100vh;
    margin: 0;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    background: var(--news-bg);
    color: var(--news-text);
    font-family: "Nunito", sans-serif;
    line-height: 1.65;
}

.news-page .news-page__main,
.news-page .news-page__main * {
    box-sizing: border-box;
}

.news-page .news-page__main {
    width: min(100% - 2rem, 1040px);
    margin: 0 auto;
    padding: 2.25rem 0 calc(4.5rem + env(safe-area-inset-bottom, 0px));
    flex: 1 0 auto;
}

.news-page .news-page__back {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    padding: 0.35rem 0;
    color: var(--news-muted);
    font-weight: 700;
    text-decoration: none;
    transition: color 0.28s cubic-bezier(0.22, 1, 0.36, 1), transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.news-page .news-page__back:hover,
.news-page .news-page__back:focus-visible {
    outline: none;
    color: var(--news-accent);
    transform: translateX(-2px);
}

.news-list-page .news-list-page__heading {
    max-width: 720px;
    margin-bottom: 2.25rem;
}

.news-list-page .news-list-page__heading h1 {
    margin: 0;
    font-family: "Ysabeau SC", sans-serif;
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    letter-spacing: 0.025em;
    line-height: 1;
}

.news-list-page .news-list-page__heading p {
    margin: 0.55rem 0 0;
    color: var(--news-muted);
    font-size: clamp(0.95rem, 1.8vw, 1.05rem);
}

.news-list-page .news-list-page__archive {
    display: grid;
    gap: 2.5rem;
}

.news-list-page .news-list-page__year {
    min-width: 0;
}

.news-list-page .news-list-page__year-heading {
    display: grid;
    grid-template-columns: auto minmax(2rem, 1fr);
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.65rem;
}

.news-list-page .news-list-page__year-heading h2 {
    margin: 0;
    color: var(--news-accent);
    font-family: "Ysabeau SC", sans-serif;
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: 0.06em;
}

.news-list-page .news-list-page__year-heading span {
    height: 1px;
    background: linear-gradient(90deg, rgba(255, 158, 68, 0.58), rgba(255, 158, 68, 0));
}

.news-list-page .news-list-page__items {
    display: grid;
}

.news-list-page .news-list-page__item {
    display: grid;
    grid-template-columns: 8.25rem minmax(0, 1fr) auto;
    align-items: center;
    gap: 1.15rem;
    min-width: 0;
    min-height: 104px;
    padding: 1rem 0.9rem;
    border-top: 1px solid var(--news-border);
    color: var(--news-text);
    text-decoration: none;
    transition: background-color 0.32s cubic-bezier(0.22, 1, 0.36, 1), transform 0.32s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.news-list-page .news-list-page__item:last-child {
    border-bottom: 1px solid var(--news-border);
}

.news-list-page .news-list-page__item:hover,
.news-list-page .news-list-page__item:focus-visible {
    outline: none;
    border-color: rgba(255, 158, 68, 0.28);
    background: var(--news-accent-soft);
    transform: translateX(3px);
}

.news-list-page .news-list-page__item time {
    align-self: start;
    padding-top: 0.12rem;
    color: var(--news-muted);
    font-size: 0.88rem;
    white-space: nowrap;
}

.news-list-page .news-list-page__item-copy {
    display: grid;
    min-width: 0;
    gap: 0.28rem;
}

.news-list-page .news-list-page__item-title {
    margin: 0;
    font-family: "Ysabeau SC", sans-serif;
    font-size: clamp(1.1rem, 2.1vw, 1.34rem);
    font-weight: 700;
    letter-spacing: 0.015em;
    line-height: 1.22;
    overflow-wrap: anywhere;
}

.news-list-page .news-list-page__excerpt {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    color: var(--news-muted);
    font-size: 0.92rem;
    line-height: 1.5;
    overflow-wrap: anywhere;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.news-list-page .news-list-page__reaction-total {
    display: inline-flex;
    width: max-content;
    align-items: center;
    gap: 0.3rem;
    margin-top: 0.12rem;
    color: var(--news-muted);
    font-size: 0.78rem;
    font-weight: 700;
    line-height: 1.3;
}

.news-list-page .news-list-page__arrow {
    color: var(--news-accent);
    font-size: 1.15rem;
    transition: transform 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

.news-list-page .news-list-page__item:hover .news-list-page__arrow,
.news-list-page .news-list-page__item:focus-visible .news-list-page__arrow {
    transform: translateX(4px);
}

.news-page .news-pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.4rem;
    margin: 2.25rem 0 1rem;
}

.news-page .news-pagination a,
.news-page .news-pagination span {
    display: inline-flex;
    min-width: 38px;
    min-height: 38px;
    align-items: center;
    justify-content: center;
    padding: 0.4rem 0.65rem;
    border-radius: 7px;
    color: var(--news-muted);
    font-weight: 800;
    text-decoration: none;
}

.news-page .news-pagination a {
    border: 1px solid var(--news-border);
    transition: border-color 0.28s cubic-bezier(0.22, 1, 0.36, 1), color 0.28s cubic-bezier(0.22, 1, 0.36, 1), background-color 0.28s cubic-bezier(0.22, 1, 0.36, 1), transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.news-page .news-pagination a:hover,
.news-page .news-pagination a:focus-visible {
    outline: none;
    border-color: rgba(255, 158, 68, 0.5);
    background: var(--news-accent-soft);
    color: var(--news-accent);
    transform: translateY(-1px);
}

.news-page .news-pagination .news-pagination__current {
    background: var(--news-accent);
    color: var(--news-bg);
}

.news-page .news-pagination .news-pagination__ellipsis {
    min-width: 26px;
    padding-inline: 0.2rem;
}

.news-page .news-page__empty,
.news-page .news-page__not-found {
    padding: 1.25rem;
    border: 1px solid var(--news-border);
    border-radius: 10px;
    background: var(--news-surface);
}

.news-page .news-page__empty {
    margin: 0 0 1.5rem;
    color: var(--news-muted);
}

.news-page .news-page__not-found {
    max-width: 720px;
    margin: 0 auto;
}

.news-page .news-page__not-found h1 {
    margin: 0;
    font-family: "Ysabeau SC", sans-serif;
    font-size: clamp(1.7rem, 4vw, 2.3rem);
}

.news-page .news-page__not-found p {
    margin: 0.45rem 0 1rem;
    color: var(--news-muted);
}

.news-article-page .news-article-page__main {
    width: min(100% - 2rem, 820px);
}

.news-article-page .news-article {
    min-width: 0;
}

.news-article-page .news-article > .news-page__back {
    margin-bottom: 1.2rem;
}

.news-article-page .news-article__heading {
    padding-bottom: 1.65rem;
    border-bottom: 1px solid var(--news-border);
}

.news-article-page .news-article__heading time {
    display: block;
    margin-bottom: 0.55rem;
    color: var(--news-muted);
    font-size: 0.92rem;
}

.news-article-page .news-article__heading h1 {
    margin: 0;
    color: var(--news-text);
    font-family: "Ysabeau SC", sans-serif;
    font-size: clamp(2rem, 6vw, 3.55rem);
    font-weight: 700;
    letter-spacing: 0.01em;
    line-height: 1.05;
    overflow-wrap: anywhere;
}

.news-article-page .news-article__content {
    padding: 1.8rem 0 0.6rem;
    color: var(--news-text);
    font-size: clamp(1rem, 1.6vw, 1.08rem);
    line-height: 1.78;
    overflow-wrap: anywhere;
}

.news-article-page .news-article__content p,
.news-article-page .news-article__content div {
    margin: 0 0 1.15rem;
}

.news-article-page .news-article__content h2,
.news-article-page .news-article__content h3,
.news-article-page .news-article__content h4 {
    margin: 2rem 0 0.75rem;
    color: var(--news-text);
    font-family: "Ysabeau SC", sans-serif;
    font-weight: 700;
    line-height: 1.2;
    overflow-wrap: anywhere;
}

.news-article-page .news-article__content h2 {
    font-size: clamp(1.45rem, 3vw, 1.9rem);
}

.news-article-page .news-article__content h3 {
    font-size: clamp(1.25rem, 2.5vw, 1.55rem);
}

.news-article-page .news-article__content h4 {
    font-size: 1.12rem;
}

.news-article-page .news-article__content ul,
.news-article-page .news-article__content ol {
    margin: 1rem 0 1.25rem;
    padding-left: clamp(1.35rem, 4vw, 2rem);
}

.news-article-page .news-article__content li + li {
    margin-top: 0.38rem;
}

.news-article-page .news-article__content a {
    color: var(--news-accent);
    text-decoration: underline;
    text-decoration-color: rgba(255, 158, 68, 0.45);
    text-underline-offset: 0.18em;
    transition: color 0.28s cubic-bezier(0.22, 1, 0.36, 1), text-decoration-color 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.news-article-page .news-article__content a:hover,
.news-article-page .news-article__content a:focus-visible {
    outline: none;
    color: #ffae5d;
    text-decoration-color: currentColor;
}

.news-article-page .news-reactions {
    margin-top: 1.35rem;
    padding: 1.2rem 0 1.3rem;
    border-top: 1px solid var(--news-border);
    border-bottom: 1px solid var(--news-border);
}

.news-article-page .news-reactions h2 {
    margin: 0 0 0.75rem;
    color: var(--news-muted);
    font-family: "Nunito", sans-serif;
    font-size: 0.92rem;
    font-weight: 700;
    letter-spacing: 0.01em;
}

.news-article-page .news-reactions__options {
    display: flex;
    flex-wrap: wrap;
    gap: 0.48rem;
}

.news-article-page .news-reactions__button {
    display: inline-flex;
    min-width: 48px;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    gap: 0.38rem;
    padding: 0.42rem 0.62rem;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 9px;
    outline: none;
    background: var(--news-surface);
    color: var(--news-muted);
    font: inherit;
    cursor: pointer;
    transition: border-color 0.24s cubic-bezier(0.22, 1, 0.36, 1), background-color 0.24s cubic-bezier(0.22, 1, 0.36, 1), color 0.24s cubic-bezier(0.22, 1, 0.36, 1), transform 0.24s cubic-bezier(0.22, 1, 0.36, 1);
}

.news-article-page .news-reactions__button:hover,
.news-article-page .news-reactions__button:focus-visible {
    border-color: rgba(255, 158, 68, 0.55);
    background: var(--news-accent-soft);
    color: var(--news-text);
}

.news-article-page .news-reactions__button:focus-visible {
    box-shadow: 0 0 0 3px rgba(255, 158, 68, 0.13);
}

.news-article-page .news-reactions__button:active {
    transform: scale(0.96);
}

.news-article-page .news-reactions__button.is-active {
    border-color: rgba(255, 158, 68, 0.72);
    background: rgba(255, 158, 68, 0.14);
    color: var(--news-accent);
}

.news-article-page .news-reactions__button:disabled {
    cursor: wait;
    opacity: 0.72;
}

.news-article-page .news-reactions__button.is-pending .news-reactions__emoji {
    transform: scale(0.9);
}

.news-article-page .news-reactions__button.is-confirmed {
    animation: news-reaction-confirm 0.34s cubic-bezier(0.22, 1, 0.36, 1);
}

.news-article-page .news-reactions__emoji {
    font-size: 1.18rem;
    line-height: 1;
    transition: transform 0.24s cubic-bezier(0.22, 1, 0.36, 1);
}

.news-article-page .news-reactions__count {
    min-width: 0.7em;
    font-size: 0.78rem;
    font-weight: 800;
    line-height: 1;
}

.news-article-page .news-reactions__count[hidden],
.news-article-page .news-reactions__status[hidden] {
    display: none;
}

.news-article-page .news-reactions__status {
    margin: 0.7rem 0 0;
    color: #ff9ca3;
    font-size: 0.84rem;
}

.news-article-page .news-article__navigation {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding-top: 1.1rem;
    border-top: 1px solid var(--news-border);
}

.news-article-page .news-article__navigation a {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    color: var(--news-muted);
    font-weight: 700;
    text-decoration: none;
    transition: color 0.28s cubic-bezier(0.22, 1, 0.36, 1), transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

.news-article-page .news-article__navigation a:hover,
.news-article-page .news-article__navigation a:focus-visible {
    outline: none;
    color: var(--news-accent);
}

.news-article-page .news-article__navigation a:first-child:hover,
.news-article-page .news-article__navigation a:first-child:focus-visible {
    transform: translateX(-2px);
}

@keyframes news-rise {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes news-reaction-confirm {
    0% { transform: scale(1); }
    45% { transform: scale(1.08); }
    100% { transform: scale(1); }
}

.news-page .news-motion {
    opacity: 0;
    animation: news-rise 0.56s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    animation-delay: var(--news-delay, 0s);
}

@media (max-width: 600px) {
    .news-page .news-page__main {
        width: min(100% - 1rem, 1040px);
        padding-top: 1.25rem;
    }

    .news-list-page .news-list-page__heading {
        margin-bottom: 1.65rem;
        padding-inline: 0.35rem;
    }

    .news-list-page .news-list-page__archive {
        gap: 2rem;
    }

    .news-list-page .news-list-page__year-heading {
        padding-inline: 0.35rem;
    }

    .news-list-page .news-list-page__item {
        grid-template-columns: minmax(0, 1fr) auto;
        gap: 0.35rem 0.75rem;
        min-height: 116px;
        padding: 0.95rem 0.7rem;
    }

    .news-list-page .news-list-page__item time {
        grid-column: 1;
        padding: 0;
        font-size: 0.82rem;
    }

    .news-list-page .news-list-page__item-copy {
        grid-column: 1;
    }

    .news-list-page .news-list-page__arrow {
        grid-column: 2;
        grid-row: 1 / span 2;
        align-self: center;
    }

    .news-article-page .news-article-page__main {
        width: min(100% - 1.25rem, 820px);
    }

    .news-article-page .news-article__heading {
        padding-bottom: 1.25rem;
    }

    .news-article-page .news-article__content {
        padding-top: 1.35rem;
        line-height: 1.72;
    }

    .news-article-page .news-article__navigation {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 360px) {
    .news-article-page .news-reactions__options {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .news-article-page .news-reactions__button {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .news-page .news-motion {
        opacity: 1;
        animation: none;
        transform: none;
    }

    .news-page .news-page__main *,
    .news-page .news-page__main *::before,
    .news-page .news-page__main *::after {
        scroll-behavior: auto;
        transition-duration: 0.01ms;
    }

    .news-article-page .news-reactions__button.is-confirmed {
        animation: none;
    }
}
