html.dark .article-list,
html.dark .article-list__title {
    color: #e0e0e0
}

html.dark .article-card,
html.dark .sidebar {
    background: #1a1a1a;
    border-color: rgba(255, 255, 255, .15)
}

.gallery-carousel__image-wrapper:hover .gallery-carousel__image,
.search-results__image a:hover img {
    transform: scale(1.05)
}

.article__category a:hover,
.search-results__item h3 a:hover,
.search-results__link:hover,
.simple-article-list__category a:hover {
    text-decoration: underline
}

.layout-container {
    display: grid;
    grid-template-columns: [sidebar-left-start] var(--sidebar-left-width, 250px) [sidebar-left-end content-start] minmax(0, 1fr) [content-end sidebar-right-start] var(--sidebar-right-width, 250px) [sidebar-right-end];
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem 1rem;
    align-items: start
}

.article-card__content,
.sidebar {
    padding: 1.5rem
}

.sidebar,
.sidebar--left {
    grid-column: sidebar-left-start/sidebar-left-end;
    height: fit-content
}

.sidebar--right {
    grid-column: sidebar-right-start/sidebar-right-end;
    height: fit-content
}

.main-content {
    grid-column: content-start/content-end;
    min-width: 0
}

.layout-container.no-left {
    grid-template-columns: [content-start] auto [content-end sidebar-right-start] var(--sidebar-right-width, 250px) [sidebar-right-end];
    gap: 50px;
    justify-content: start
}

.layout-container.no-right {
    grid-template-columns: [sidebar-left-start] var(--sidebar-left-width, 250px) [sidebar-left-end content-start] auto [content-end];
    gap: 50px;
    justify-content: start
}

.layout-container.no-sidebars {
    grid-template-columns: [content-start] minmax(0, 1fr) [content-end]
}

.layout-container.no-left .main-content,
.layout-container.no-right .main-content {
    max-width: calc(1400px - var(--sidebar-left-width, 250px) - var(--sidebar-right-width, 250px) - 50px - 4rem)
}

.layout-container.no-sidebars .main-content {
    max-width: none;
    width: 100%
}

.countdown-block {
	background: var(--countdown-block-bg, #ffffff);
	border: 1px solid #dfe3e8;
	box-shadow: 0 20px 50px rgba(17, 24, 39, 0.1);
	border-radius: 22px;
	padding: 28px;
	display: flex;
	flex-direction: column;
	gap: 22px;
	color: #0f172a;
}

.countdown-block--square {
	border-radius: 6px;
}

.countdown-block--pill {
	border-radius: 44px;
}

.countdown-block__meta {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.countdown-block__title {
	margin: 0;
	font-size: 1.38rem;
	font-weight: 600;
}

.countdown-block__description {
	font-size: 1rem;
	line-height: 1.6;
	color: #475569;
}

.countdown-block__timer {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(82px, 1fr));
	gap: 16px;
}

.countdown-block__item {
	background: var(--countdown-item-bg, #f8fafc);
	border-radius: 16px;
	padding: 10px 0;
	text-align: center;
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.countdown-block__value {
	font-size: 1.6rem;
	font-weight: 600;
	display: block;
}

.countdown-block__label {
	font-size: 0.85rem;
	color: #64748b;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}

html.dark .countdown-block {
	background: var(--countdown-block-dark-bg, #15202b);
	border-color: #1d2939;
	box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
	color: #f8fafc;
}

html.dark .countdown-block__description {
	color: #cfd6e5;
}

html.dark .countdown-block__item {
	background: var(--countdown-item-dark-bg, #1e2a3d);
	box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

html.dark .countdown-block__label {
	color: #9aa6c0;
}

.sidebar {
    background: #fff;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, .05);
    height: fit-content
}

.sidebar--sticky {
    position: sticky;
    top: 2.9rem;
    max-height: calc(100vh - 4rem);
    overflow-y: auto
}

html.dark .sidebar {
    box-shadow: 0 2px 4px rgba(0, 0, 0, .3);
    color: #e0e0e0
}

html.dark .search-results h2,
html.dark .sidebar h2,
html.dark .sidebar h3,
html.dark .sidebar h4 {
    color: #fff
}

html.dark .sidebar a {
    color: #4285f4
}

html.dark .sidebar a:hover {
    color: #5a95f5
}

.sidebar>*+* {
    margin-top: 2rem
}

@media (max-width:849px) {

    .layout-container,
    .layout-container.no-left,
    .layout-container.no-right,
    .layout-container.no-sidebars {
        grid-template-columns: [content-start] minmax(0, 1fr) [content-end] !important;
        gap: 1rem
    }

    .sidebar--left,
    .sidebar--right {
        display: none
    }

    .sidebar--sticky {
        position: static;
        max-height: none;
        overflow-y: visible
    }

    .main-content {
        grid-column: content-start/content-end !important
    }
}

.article-card__image,
.gallery-carousel,
.gallery-carousel__container,
.gallery-carousel__image-wrapper {
    position: relative;
    overflow: hidden
}

.article-list {
    display: grid;
    gap: 1.5rem;
    margin: 2rem 0;
    color: #333
}

.article-list--cards {
    grid-template-columns: 1fr
}

.article-list--grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr))
}

.article-list__title {
    font-size: 1.75rem;
    margin-bottom: 1rem;
    font-weight: 600;
    color: #333
}

.article-list p {
    color: #666
}

html.dark .article-list p {
    color: #999
}

html.dark .article-card__content,
html.dark .article-card__title a {
    color: #e0e0e0
}

.article-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    transition: box-shadow .3s
}

.article-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, .1)
}

html.dark .article-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, .3)
}

.article-card__image {
    width: 100%;
    aspect-ratio: 4/3;
    background-color: #f0f0f0
}

html.dark .article-card__image {
    background-color: #2a2a2a
}

.article-card__image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover
}

.article-card__title {
    margin: 0 0 .75rem;
    font-size: 1.25rem
}

.article-card__title a {
    color: #333;
    text-decoration: none
}

.article-card__title a:hover {
    color: #007bff
}

html.dark .article-card__title a:hover {
    color: #4da6ff
}

.article-card__excerpt {
    color: #666;
    margin-bottom: 1rem;
    line-height: 1.6
}

html.dark .article-card__excerpt {
    color: #bbb
}

.article-card__meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: .875rem;
    color: #999
}

html.dark .article-card__meta,
html.dark .article-card__meta time {
    color: #999
}

.article-card__category,
.article__category {
    background: #e9ecef;
    padding: .25rem .75rem;
    border-radius: 4px;
    font-size: .75rem
}

html.dark .article-card__category {
    background: #2a2a2a;
    color: #e0e0e0;
    border: 1px solid rgba(255, 255, 255, .15)
}

.article-card__badge,
html.dark .article-card__badge {
    background: #ffc107;
    color: #000
}

.article-card__badge,
.tag {
    border-radius: 4px;
    font-size: .75rem
}

.article-card__badge {
    padding: .25rem .75rem;
    font-weight: 600
}

html.dark .gallery-carousel__container,
html.dark .tag {
    background: #2a2a2a
}

.article-card__tags {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem
}

.tag {
    background: #e9ecef;
    padding: .25rem .5rem;
    color: #333;
    display: inline-block
}

.tag--link {
    text-decoration: none;
    transition: background-color .2s, color .2s
}

.tag--link:hover {
    background: #007bff;
    color: #fff
}

html.dark .tag {
    color: #e0e0e0;
    border: 1px solid rgba(255, 255, 255, .15)
}

html.dark .tag--link:hover {
    background: #4da6ff;
    color: #fff;
    border-color: #4da6ff
}

.article-card--featured {
    border-color: #ffc107;
    border-width: 2px
}

.gallery-carousel {
    margin: 2rem 0
}

.gallery__title {
    font-size: 1.75rem;
    margin-bottom: 1.5rem
}

.gallery-carousel__container {
    border-radius: 12px;
    background: #f5f5f5
}

.gallery-carousel__track {
    display: flex;
    transition: transform .4s cubic-bezier(.4, 0, .2, 1);
    will-change: transform
}

.gallery-carousel__slide {
    flex: 0 0 calc(100% / 3);
    min-width: 0;
    padding: .5rem;
    box-sizing: border-box
}

@media (max-width:768px) {
    .gallery-carousel__slide {
        flex: 0 0 100%
    }
}

@media (min-width:769px) and (max-width:1024px) {
    .gallery-carousel__slide {
        flex: 0 0 50%
    }
}

.gallery-carousel__image-wrapper {
    border-radius: 8px;
    cursor: pointer;
    aspect-ratio: 16/9;
    background: #000
}

.table-responsive,
.table-wrapper {
    overflow-x: auto
}

.gallery-carousel__image-wrapper:hover .gallery-carousel__zoom {
    opacity: 1
}

.gallery-carousel__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform .3s
}

.gallery-carousel__zoom {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, .7);
    border: none;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    cursor: pointer;
    opacity: 0;
    transition: opacity .3s, background .3s;
    z-index: 2
}

.gallery-carousel__indicator,
.gallery-carousel__nav {
    cursor: pointer;
    transition: background .3s, transform .2s
}

.gallery-carousel__zoom:hover {
    background: rgba(0, 0, 0, .9)
}

.gallery-carousel__zoom svg {
    width: 24px;
    height: 24px
}

.gallery-carousel__nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, .9);
    border: none;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .15)
}

html.dark .gallery-carousel__nav {
    background: rgba(42, 42, 42, .9);
    color: #fff
}

.gallery-carousel__nav:hover {
    background: #fff;
    transform: translateY(-50%) scale(1.1)
}

.gallery-lightbox__close:hover,
.gallery-lightbox__nav:hover,
html.dark .gallery-carousel__indicator {
    background: rgba(255, 255, 255, .2)
}

html.dark .gallery-carousel__nav:hover {
    background: #3c3c3c
}

.gallery-carousel__nav--prev {
    left: 1rem
}

.gallery-carousel__nav--next {
    right: 1rem
}

.gallery-carousel__nav:disabled {
    opacity: .3;
    cursor: not-allowed;
    transform: translateY(-50%)
}

.gallery-carousel__nav svg {
    width: 20px;
    height: 20px
}

.gallery-carousel__indicators {
    display: flex;
    justify-content: center;
    gap: .5rem;
    margin-top: 1rem;
    flex-wrap: wrap
}

.gallery-carousel__indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: none;
    background: rgba(0, 0, 0, .2);
    padding: 0
}

.gallery-carousel__indicator:hover {
    transform: scale(1.2)
}

.gallery-carousel__indicator--active {
    background: #007bff;
    transform: scale(1.2)
}

html.dark .gallery-carousel__indicator--active {
    background: #4285f4
}

.gallery-lightbox,
.main-image-lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity .3s
}

.gallery-lightbox[aria-hidden=false],
.main-image-lightbox[aria-hidden=false] {
    display: flex;
    opacity: 1
}

.gallery-lightbox__overlay,
.main-image-lightbox__overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, .95);
    backdrop-filter: blur(4px)
}

.gallery-lightbox__close,
.gallery-lightbox__nav {
    background: rgba(255, 255, 255, .1);
    transition: background .3s, transform .2s;
    display: flex;
    color: #fff;
    cursor: pointer
}

.gallery-lightbox__container,
.main-image-lightbox__container {
    position: relative;
    width: 90%;
    max-width: 1200px;
    max-height: 90vh;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center
}

.gallery-lightbox__image-container {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center
}

.gallery-lightbox__image {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, .5)
}

.gallery-lightbox__close {
    position: absolute;
    top: -50px;
    right: 0;
    border: none;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    align-items: center;
    justify-content: center;
    z-index: 10002
}

.gallery-lightbox__close:hover {
    transform: rotate(90deg)
}

.gallery-lightbox__nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    border-radius: 50%;
    width: 56px;
    height: 56px;
    align-items: center;
    justify-content: center;
    z-index: 10002
}

.gallery-lightbox__nav:hover {
    transform: translateY(-50%) scale(1.1)
}

.gallery-lightbox__nav--prev {
    left: -80px
}

.gallery-lightbox__nav--next {
    right: -80px
}

.gallery-lightbox__nav:disabled {
    opacity: .3;
    cursor: not-allowed;
    transform: translateY(-50%)
}

.gallery-lightbox__counter {
    position: absolute;
    bottom: -50px;
    left: 50%;
    transform: translateX(-50%);
    color: #fff;
    font-size: 1rem;
    font-weight: 500
}

.quote {
    border-left: 4px solid #007bff;
    padding: 1.5rem;
    margin: 2rem 0;
    background: #f8f9fa;
    border-radius: 4px
}

html.dark .quote {
    background: #2a2a2a;
    border-left-color: #4da6ff
}

.quote__text {
    font-size: 1.125rem;
    font-style: italic;
    margin: 0 0 1rem;
    color: #333
}

html.dark .quote__text {
    color: #e0e0e0
}

.quote__footer,
.sidebar-pages__minimal {
    display: flex;
    flex-direction: column;
    gap: .5rem
}

.quote__author {
    font-weight: 600;
    color: #666
}

html.dark .article__date,
html.dark .quote__author {
    color: #bbb
}

.quote__source {
    font-size: .875rem;
    color: #999
}

html.dark .quote__source {
    color: #888
}

html.dark .simple-article-list__item-title a,
html.dark .simple-article-list__title {
    color: #e0e0e0
}

.image-block,
.search-form,
.search-results,
.simple-article-list {
    margin: 2rem 0
}

.simple-article-list__title {
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    font-weight: 600;
    color: #333
}

.faq-accordion,
.sidebar-pages,
.simple-article-list--columns-1 {
    display: flex;
    flex-direction: column;
    gap: 1rem
}

.simple-article-list--columns-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem
}

.simple-article-list--columns-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem
}

.simple-article-list__item {
    padding: 1rem;
    border-bottom: 1px solid #e0e0e0;
    transition: background-color .2s
}

.simple-article-list--columns-2 .simple-article-list__item,
.simple-article-list--columns-3 .simple-article-list__item {
    border-bottom: none;
    border-left: 2px solid #e0e0e0;
    padding-left: 1.5rem
}

html.dark .simple-article-list__item {
    border-bottom-color: rgba(255, 255, 255, .15)
}

html.dark .simple-article-list--columns-2 .simple-article-list__item,
html.dark .simple-article-list--columns-3 .simple-article-list__item {
    border-left-color: rgba(255, 255, 255, .15)
}

.simple-article-list__item:hover {
    background-color: #f8f9fa
}

html.dark .simple-article-list__item:hover {
    background-color: #2a2a2a
}

.simple-article-list__item-title {
    margin: 0 0 .5rem;
    font-size: 1.125rem;
    font-weight: 600;
    line-height: 1.4
}

.simple-article-list__item-title a {
    color: #333;
    text-decoration: none;
    transition: color .2s
}

html.dark .search-results__item h3 a,
html.dark .simple-article-list__category a,
html.dark .simple-article-list__item-title a:hover {
    color: #4da6ff
}

.simple-article-list__item-title a:hover {
    color: #007bff;
    text-decoration: underline
}

html.dark .simple-article-list__category,
html.dark .simple-article-list__date,
html.dark .simple-article-list__item-meta {
    color: #999
}

.simple-article-list__item-meta {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
    align-items: center;
    font-size: .875rem;
    color: #666
}

.simple-article-list__category,
.simple-article-list__date {
    color: #666
}

.simple-article-list__category a {
    color: #007bff;
    text-decoration: none
}

.sidebar-tags,
.simple-article-list__tags {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem
}

.simple-article-list__tag {
    display: inline-block;
    padding: .25rem .5rem;
    background: #f0f0f0;
    color: #666;
    border-radius: 4px;
    font-size: .75rem;
    text-decoration: none;
    transition: background-color .2s, color .2s
}

html.dark .simple-article-list__tag {
    background: #2a2a2a;
    color: #bbb
}

.simple-article-list__tag:hover {
    background: #007bff;
    color: #fff
}

html.dark .simple-article-list__tag:hover {
    background: #4da6ff;
    color: #fff
}

html.dark .image-block--full .image-block__caption,
html.dark .image-block--left .image-block__caption,
html.dark .image-block--right .image-block__caption,
html.dark .simple-article-list__empty {
    color: #999
}

.simple-article-list__empty {
    padding: 2rem;
    text-align: center;
    color: #666;
    font-style: italic
}

@media (max-width:1024px) {
    .simple-article-list--columns-3 {
        grid-template-columns: repeat(2, 1fr)
    }
}

.search-form__input:focus,
.search-form__tag-select:focus,
.search-widget__input:focus {
    outline: 0;
    border-color: #007bff
}

.table-wrapper {
    margin: 2rem 0
}

.table__caption {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    font-weight: 600
}

.table-responsive table {
    width: 100%;
    border-collapse: collapse
}

.table-responsive table td,
.table-responsive table th {
    padding: .75rem;
    border: 1px solid #dee2e6;
    text-align: left
}

.image-block--full img,
.image-block--left .image-block__image img,
.image-block--right .image-block__image img {
    max-width: 100%;
    height: auto;
    border-radius: 8px
}

.table-responsive table th {
    background: #f8f9fa;
    font-weight: 600
}

.image-block--full {
    text-align: center
}

.image-block--full .image-block__image {
    width: 100%;
    position: relative
}

.image-block--full img {
    width: 100%;
    display: block
}

.image-block--full .image-block__caption {
    margin-top: .5rem;
    font-size: .875rem;
    color: #666;
    font-style: italic;
    text-align: center
}

.image-block--left .image-block__wrapper {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    margin: 2rem 0
}

.image-block--left .image-block__image {
    flex-shrink: 0;
    max-width: 400px;
    width: 100%
}

.image-block--left .image-block__caption {
    flex: 1;
    font-size: .875rem;
    color: #666;
    line-height: 1.6;
    margin: auto;
    text-align: center
}

.image-block--right .image-block__wrapper {
    display: flex;
    flex-direction: row-reverse;
    gap: 1.5rem;
    align-items: flex-start;
    margin: 2rem 0
}

.image-block--right .image-block__image {
    flex-shrink: 0;
    max-width: 400px;
    width: 100%
}

.image-block--right .image-block__caption {
    flex: 1;
    font-size: .875rem;
    color: #666;
    line-height: 1.6;
    margin: auto;
    text-align: center
}

.search-widget {
    margin-bottom: 1.5rem
}

.search-widget__input-wrapper {
    position: relative;
    display: flex;
    align-items: center
}

.search-widget__input {
    width: 100%;
    padding: .5rem 2.5rem .5rem .75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: .875rem;
    background: #fff;
    color: #333
}

html.dark .search-widget__input {
    background: #2a2a2a;
    border-color: rgba(255, 255, 255, .15);
    color: #fff
}

.search-widget__input:focus {
    box-shadow: 0 0 0 2px rgba(0, 123, 255, .1)
}

html.dark .search-widget__input:focus {
    border-color: #4285f4;
    box-shadow: 0 0 0 2px rgba(66, 133, 244, .2)
}

html.dark .search-form__input:focus,
html.dark .search-form__tag-select:focus {
    border-color: #4da6ff
}

.search-widget__input::placeholder {
    color: #999
}

html.dark .search-widget__input::placeholder {
    color: #666
}

.search-widget__button {
    position: absolute;
    right: .5rem;
    top: 50%;
    transform: translateY(-50%);
    width: 24px;
    height: 24px;
    padding: 0;
    background: 0 0;
    color: #666;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color .2s
}

html.dark .search-widget__button {
    color: #999
}

.search-widget__button:hover {
    color: #007bff
}

html.dark .search-widget__button:hover {
    color: #4285f4
}

.search-widget__button svg {
    width: 100%;
    height: 100%
}

.intro {
    font-size: 1.125rem;
    line-height: 1.8;
    margin-bottom: 2rem;
    color: #555
}

.search-form__input,
.search-form__tag-select {
    padding: 1rem;
    background: #fff;
    color: #111;
    font-size: 1rem
}

.search-form__input-wrapper {
    display: flex;
    gap: .5rem;
    max-width: 800px;
    align-items: stretch
}

.search-form__input {
    flex: 1;
    border: 2px solid #ddd;
    border-radius: 4px
}

html.dark .search-form__input {
    background: #1a1a1a;
    border-color: rgba(255, 255, 255, .15);
    color: #fff
}

.search-form__tag-select {
    border: 2px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    min-width: 180px;
    transition: border-color .3s
}

html.dark .search-form__tag-select {
    background: #1a1a1a;
    border-color: rgba(255, 255, 255, .15);
    color: #fff
}

.search-form__button {
    padding: 1rem 2rem;
    background: #007bff;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    transition: background .3s;
    white-space: nowrap
}

.search-form__button:hover {
    background: #0056b3
}

.search-tag-filter {
    margin: 2rem 0;
    padding: 1rem;
    background: #f8f9fa;
    border-left: 4px solid #007bff;
    border-radius: 4px;
    display: flex;
    justify-content: space-between;
    align-items: center
}

html.dark .search-tag-filter {
    background: #2a2a2a;
    border-left-color: #4da6ff;
    color: #e0e0e0
}

.search-tag-filter h2 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600
}

.search-tag-filter__clear {
    color: #666;
    text-decoration: none;
    font-size: .875rem;
    padding: .25rem .5rem;
    border-radius: 4px;
    transition: background-color .2s, color .2s
}

.search-tag-filter__clear:hover {
    background: #e9ecef;
    color: #333
}

html.dark .search-tag-filter__clear {
    color: #999
}

html.dark .search-tag-filter__clear:hover {
    background: #3a3a3a;
    color: #e0e0e0
}

.search-results h2 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: #333
}

.search-results__list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem
}

.search-results__item {
    padding: 1.5rem;
    margin-bottom: 0;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    transition: box-shadow .3s;
    display: flex;
    flex-direction: column;
    height: 100%
}

html.dark .search-results__item {
    background: #1a1a1a;
    border-color: rgba(255, 255, 255, .15)
}

.faq-item:hover,
.search-results__item:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, .1)
}

.article__rating-button--active,
.sidebar-tags__tag:hover {
    box-shadow: 0 2px 4px rgba(0, 123, 255, .2)
}

html.dark .faq-item:hover,
html.dark .search-results__item:hover {
    box-shadow: 0 2px 8px rgba(255, 255, 255, .1)
}

.search-results__content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    height: 100%
}

.search-results__image {
    width: 100%;
    aspect-ratio: 4/3;
    overflow: hidden;
    border-radius: 6px;
    flex-shrink: 0
}

.search-results__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .3s
}

.search-results__image a {
    display: block;
    width: 100%;
    height: 100%
}

.search-results__text {
    flex: 1;
    display: flex;
    flex-direction: column
}

.search-results__description {
    flex: 1;
    color: #666;
    margin: .5rem 0;
    line-height: 1.6
}

.search-results__item h3 {
    margin: 0 0 .5rem;
    font-size: 1.25rem
}

html.dark .search-results__item h3 {
    color: #fff
}

.search-results__item h3 a {
    color: #007bff;
    text-decoration: none
}

html.dark .search-results__description {
    color: #e0e0e0
}

html.dark .article-card__title--compact a:hover,
html.dark .article__edit-link:hover,
html.dark .search-results__link {
    color: #4da6ff
}

.search-results__link {
    display: inline-block;
    margin-top: .5rem;
    color: #007bff;
    text-decoration: none;
    font-weight: 500
}

.search-empty,
.search-no-results {
    margin: 2rem 0;
    padding: 2rem;
    background: #f8f9fa;
    border-radius: 8px;
    text-align: center;
    color: #666
}

html.dark .search-empty,
html.dark .search-no-results {
    background: #1a1a1a;
    color: #e0e0e0
}

.article {
    max-width: 800px;
    margin: 0 auto
}

.article__header {
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid #e0e0e0
}

.article__badge {
    display: inline-block;
    background: #ffc107;
    color: #000;
    padding: .25rem .75rem;
    border-radius: 4px;
    font-size: .75rem;
    font-weight: 600;
    margin-bottom: 1rem
}

.article__title {
    font-size: 2.5rem;
    margin: 0 0 1rem;
    line-height: 1.2;
    color: #333;
    display: flex;
    align-items: center;
    gap: .75rem
}

html.dark .article__title {
    color: #e0e0e0
}

.article__edit-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    color: #666;
    opacity: .6;
    transition: opacity .2s, color .2s;
    text-decoration: none;
    flex-shrink: 0
}

.article__edit-link:hover {
    opacity: 1;
    color: #007bff
}

html.dark .article__edit-link {
    color: #999
}

/* Компактный мета‑блок под заголовком статьи */
.article__meta--compact {
    justify-content: space-between;
    flex-wrap: wrap;
    row-gap: 0.5rem;
    margin-bottom: 0!important;
}

.article__meta-left,
.article__meta-right {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
}

/* Отдельные элементы: дата / категория / теги */
.article__meta-item {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
}

/* Подписи "Дата", "Категория", "Теги" */
.article__meta-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #999;
}

/* Категория визуально как яркий бейдж, отличающийся от тегов */
.article__meta-item--category .article__category {
    background: #e3f2fd;
    border-radius: 999px;
    padding: 0.15rem 0.7rem;
}

.article__meta-item--category .article__category a {
    color: #0d47a1;
    font-weight: 500;
    text-decoration: none;
}

/* Теги остаются "чипами", но собраны в одну компактную строку */
.article__meta-item--tags .article__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.article__meta-item--tags .tag {
    font-size: 0.75rem;
    padding: 0.2rem 0.5rem;
}

/* Тёмная тема: аккуратные цвета для бейджа категории и подписей */
html.dark .article__meta-label {
    color: #aaa;
}

html.dark .article__meta-item--category .article__category {
    background: #1f2a36;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

html.dark .article__meta-item--category .article__category a {
    color: #90caf9;
}

.article__meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: .875rem;
    color: #666
}

.article__date,
html.dark .article__meta {
    color: #999
}

html.dark .article-card__title--compact a,
html.dark .article__body h3,
html.dark .article__body li,
html.dark .article__body ol,
html.dark .article__body p,
html.dark .article__body ul,
html.dark .article__category a {
    color: #e0e0e0
}

html.dark .article__category {
    background: #2a2a2a;
    border: 1px solid rgba(255, 255, 255, .15)
}

.article__category a {
    color: #333;
    text-decoration: none
}

.article__tags {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
}

.article__header-content {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
    margin-bottom: 2rem
}

.article__excerpt {
    font-size: 1.125rem;
    line-height: 1.8;
    color: #555;
    font-style: italic;
    padding: 1.5rem;
    background: #f8f9fa;
    border-left: 4px solid #007bff;
    border-radius: 4px;
    flex: 1
}

html.dark .article__excerpt {
    background: #2a2a2a;
    color: #e0e0e0;
    border-left-color: #4da6ff
}

.article__image {
    margin: 2rem 0;
    text-align: center
}

.article__image--main {
    margin: 0;
    flex-shrink: 0;
    max-width: 200px;
    width: 100%;
    position: relative
}

.article__image--main img {
    max-width: 200px;
    width: 100%;
    height: auto;
    border-radius: 8px;
    display: block
}

.article__image img {
    max-width: 100%;
    height: auto;
    border-radius: 8px
}

.article__body {
    margin-top: 2rem;
    line-height: 1.8;
    color: #333
}

.article__body h2 {
    font-size: 2rem;
    margin: 2rem 0 1rem;
    color: #333
}

.article__body h3 {
    color: #333
}

.article__body p {
    margin-bottom: 1.5rem;
    color: #333;
    clear: both;
}

.article__body ol,
.article__body ul {
    margin: 1.5rem 0;
    padding-left: 2rem;
    color: #333
}

.article__body li {
    margin-bottom: .5rem;
    color: #333
}

.article-list--compact {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem
}

.article-card--compact {
    display: flex;
    flex-direction: column;
    padding: 0;
    border-radius: 8px;
    overflow: hidden;
    height: 100%
}

.article-card__image--compact {
    width: 100%;
    aspect-ratio: 1;
    overflow: hidden;
    flex-shrink: 0;
    min-height: 120px;
    background-color: #f0f0f0;
}

html.dark .article-card__image--compact {
    background-color: #2a2a2a;
}

.article-card__image--compact img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0;
    display: block;
}

.article-card__content--compact {
    padding: .75rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between
}

.article-card__title--compact {
    margin: 0 0 .5rem;
    font-size: 1.125rem;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis
}

.article-card__title--compact a {
    color: #333;
    text-decoration: none
}

.article-card__title--compact a:hover,
.faq-item__answer-content a {
    color: #007bff;
    text-decoration: underline
}

.article-card__meta--compact {
    font-size: .7rem;
    margin-top: auto;
    padding-top: .5rem;
    border-top: 1px solid rgba(0, 0, 0, .05)
}

html.dark .article-card__meta--compact {
    border-top-color: rgba(255, 255, 255, .1)
}

.article-card__text-preview {
    width: 100%;
    aspect-ratio: 4/3;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 6px;
    color: #666;
    font-size: .875rem;
    line-height: 1.5;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical
}

html.dark .article-card__text-preview {
    background: #2a2a2a;
    color: #999
}

html.dark .category-page__articles-title,
html.dark .category-page__description,
html.dark .category-page__title {
    color: #e0e0e0
}

.article-card__text-preview--compact {
    aspect-ratio: 1;
    font-size: .95rem;
    padding: .75rem;
    -webkit-line-clamp: 6;
    text-align: center;
    vertical-align: bottom;
    align-content: center;
    font-style: italic
}

.category-page {
    max-width: 1200px;
    margin: 0 auto
}

.category-page__header {
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 2px solid #e0e0e0
}

html.dark .category-page__header {
    border-bottom-color: rgba(255, 255, 255, .15)
}

.category-page__title {
    font-size: 3rem;
    margin: 0 0 1.5rem;
    color: #333
}

.category-page__header-content {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
    margin-bottom: 2rem
}

.category-page__description {
    font-size: 1.125rem;
    line-height: 1.8;
    color: #555;
    flex: 1
}

.category-page__image {
    flex-shrink: 0;
    margin: 0;
    width: 200px;
    height: 200px;
    min-width: 200px;
    min-height: 200px;
    aspect-ratio: 1 / 1;
}

.category-page__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: 8px;
}

.category-page__articles {
    min-height: 200px;
}

.category-page__articles-title {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: #333;
    min-height: 2.5rem;
}

.category-page__empty {
    padding: 3rem;
    text-align: center;
    color: #666;
    font-size: 1.125rem
}

html.dark .category-page__empty {
    color: #999
}

.article__rating,
.category-page__seo-text {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid #e0e0e0
}

html.dark .category-page__seo-text {
    border-top-color: rgba(255, 255, 255, .15);
    color: #e0e0e0
}

html.dark .faq-block__title,
html.dark .faq-item__question {
    color: #fff
}

.main-image-lightbox-trigger {
    cursor: pointer;
    display: block;
    transition: opacity .2s
}

.main-image-lightbox-trigger:hover {
    opacity: .9
}

.main-image-lightbox__image-container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center
}

.main-image-lightbox__image {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 4px
}

.main-image-lightbox__close {
    position: absolute;
    top: -50px;
    right: 0;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, .1);
    border: none;
    border-radius: 50%;
    color: #fff;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .2s;
    z-index: 10002
}

.main-image-lightbox__close:hover {
    background: rgba(255, 255, 255, .2)
}

.faq-block {
    margin: 3rem 0
}

.faq-block__title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 2rem;
    color: #111
}

.faq-item {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background: #fff;
    overflow: hidden;
    transition: .3s
}

html.dark .faq-item {
    border-color: rgba(255, 255, 255, .15);
    background: #1a1a1a
}

.faq-item__question {
    width: 100%;
    padding: 1.25rem 1.5rem;
    background: 0 0;
    border: none;
    text-align: left;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    font-size: 1.125rem;
    font-weight: 600;
    color: #111;
    transition: .2s
}

.faq-item__question:hover {
    background: #f8f9fa
}

html.dark .faq-item__question:hover {
    background: rgba(255, 255, 255, .05)
}

.faq-item__question-text {
    flex: 1
}

.faq-item__icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    transition: transform .3s
}

html.dark .faq-item__icon {
    color: #999
}

html.dark .error-page__code,
html.dark .error-page__title,
html.dark .faq-item__answer-content {
    color: #e0e0e0
}

.faq-item[aria-expanded=true] .faq-item__icon {
    transform: rotate(180deg)
}

.faq-item[aria-expanded=true] .faq-item__question {
    border-bottom: 1px solid #e0e0e0
}

html.dark .breadcrumbs,
html.dark .faq-item[aria-expanded=true] .faq-item__question {
    border-bottom-color: rgba(255, 255, 255, .15)
}

.faq-item__answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height .3s, padding .3s;
    padding: 0 1.5rem
}

.faq-item[aria-expanded=true] .faq-item__answer {
    max-height: 2000px;
    padding: 1.5rem
}

.faq-item__answer-content {
    color: #555;
    line-height: 1.7
}

.faq-item__answer-content p {
    margin: 0 0 1rem
}

.faq-item__answer-content p:last-child {
    margin-bottom: 0
}

.faq-item__answer-content ol,
.faq-item__answer-content ul {
    margin: 1rem 0;
    padding-left: 2rem
}

.breadcrumbs__link,
.error-page__button,
.faq-item__answer-content a:hover,
.pagination__link,
.sidebar-pages__title a {
    text-decoration: none
}

html.dark .faq-item__answer-content a {
    color: #4285f4
}

.error-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    padding: 2rem
}

.error-page__content {
    text-align: center;
    max-width: 600px
}

.error-page__code {
    font-size: 8rem;
    font-weight: 700;
    margin: 0;
    color: #333;
    line-height: 1
}

.error-page__title {
    font-size: 2rem;
    margin: 1rem 0;
    color: #333
}

.error-page__description {
    font-size: 1.125rem;
    color: #666;
    margin-bottom: 2rem;
    line-height: 1.6
}

html.dark .error-page__description {
    color: #999
}

.error-page__button {
    display: inline-block;
    padding: .75rem 2rem;
    background: #007bff;
    color: #fff;
    border-radius: 6px;
    font-weight: 500;
    transition: background .3s
}

.error-page__button:hover {
    background: #0056b3
}

html.dark .error-page__button {
    background: #4285f4
}

html.dark .error-page__button:hover {
    background: #3367d6
}

.breadcrumbs {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e0e0e0
}

.breadcrumbs__list {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: .5rem
}

.article__rating-buttons,
.breadcrumbs__item,
.pagination__item {
    align-items: center;
    display: flex
}

.breadcrumbs__link {
    color: #007bff;
    font-size: .9rem;
    transition: color .3s
}

.breadcrumbs__current,
.breadcrumbs__separator {
    color: #999;
    font-size: .9rem
}

.breadcrumbs__link:hover {
    color: #0056b3;
    text-decoration: underline
}

html.dark .breadcrumbs__link {
    color: #4285f4
}

html.dark .breadcrumbs__current,
html.dark .breadcrumbs__separator {
    color: #666
}

html.dark .breadcrumbs__link:hover {
    color: #3367d6
}

.breadcrumbs__separator {
    margin: 0 .25rem
}

html.dark .article__rating,
html.dark .pagination {
    border-top-color: rgba(255, 255, 255, .15)
}

.article__rating-title {
    font-size: 1.75rem;
    margin-bottom: 1rem;
    color: #333;
    font-weight: bold;
}

html.dark .article__rating-title {
    color: #e0e0e0
}

.article__rating-buttons {
    gap: 1rem
}

.article__rating-button,
.pagination__link {
    align-items: center;
    color: #333;
    transition: .3s
}

.article__rating-button {
    display: flex;
    gap: .5rem;
    padding: .75rem 1.5rem;
    border: 2px solid #e0e0e0;
    background: #fff;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem
}

.article__rating-button--active,
.article__rating-button:hover {
    background: #f0f7ff;
    border-color: #007bff
}

html.dark .article__rating-button {
    background: #1a1a1a;
    border-color: rgba(255, 255, 255, .15);
    color: #e0e0e0
}

html.dark .article__rating-button:hover {
    border-color: #4285f4;
    background: rgba(66, 133, 244, .1)
}

.article__rating-button:disabled {
    opacity: .6;
    cursor: not-allowed
}

.article__rating-button--like svg {
    color: #28a745
}

.article__rating-button--dislike svg {
    color: #dc3545
}

html.dark .article__rating-button--active {
    background: rgba(66, 133, 244, .2);
    border-color: #4285f4;
    box-shadow: 0 2px 4px rgba(66, 133, 244, .3)
}

.article__rating-button--like.article__rating-button--active {
    background: #e8f5e9;
    border-color: #28a745
}

html.dark .article__rating-button--like.article__rating-button--active {
    background: rgba(40, 167, 69, .2);
    border-color: #28a745
}

.article__rating-button--dislike.article__rating-button--active {
    background: #ffebee;
    border-color: #dc3545
}

html.dark .article__rating-button--dislike.article__rating-button--active {
    background: rgba(220, 53, 69, .2);
    border-color: #dc3545
}

.article__rating-count {
    font-weight: 600;
    font-size: 1rem
}

.pagination {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #e0e0e0
}

.pagination__list {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: .5rem;
    list-style: none;
    margin: 0;
    padding: 0;
    flex-wrap: wrap
}

.pagination__current,
.pagination__link {
    min-width: 2.5rem;
    height: 2.5rem;
    padding: 0 .75rem;
    font-size: .9rem;
    display: flex
}

.pagination__link {
    justify-content: center;
    border: 1px solid #e0e0e0;
    background: #fff;
    border-radius: 6px
}

html.dark .pagination__link {
    background: #1a1a1a;
    border-color: rgba(255, 255, 255, .15);
    color: #e0e0e0
}

.pagination__link:hover {
    border-color: #007bff;
    background: #f0f7ff;
    color: #007bff
}

html.dark .pagination__link:hover {
    border-color: #4285f4;
    background: rgba(66, 133, 244, .1);
    color: #4285f4
}

.pagination__current {
    align-items: center;
    justify-content: center;
    border: 1px solid #007bff;
    background: #007bff;
    color: #fff;
    border-radius: 6px;
    font-weight: 600
}

html.dark .pagination__current {
    border-color: #4285f4;
    background: #4285f4;
    color: #fff
}

html.dark .sidebar-block__title,
html.dark .sidebar-pages__title a {
    color: #e0e0e0
}

.pagination__link--next,
.pagination__link--prev {
    font-size: 1.25rem;
    font-weight: 700
}

@media (max-width:768px) {
    .gallery-lightbox__nav--prev {
        left: 1rem
    }

    .gallery-lightbox__nav--next {
        right: 1rem
    }

    .gallery-lightbox__close,
    .main-image-lightbox__close {
        top: 1rem;
        right: 1rem
    }

    .gallery-lightbox__counter {
        bottom: 1rem
    }

    .search-results__list,
    .simple-article-list--columns-2,
    .simple-article-list--columns-3 {
        grid-template-columns: 1fr
    }

    .simple-article-list--columns-2 .simple-article-list__item,
    .simple-article-list--columns-3 .simple-article-list__item {
        border-left: none;
        border-bottom: 1px solid #e0e0e0;
        padding-left: 1rem
    }

    html.dark .simple-article-list--columns-2 .simple-article-list__item,
    html.dark .simple-article-list--columns-3 .simple-article-list__item {
        border-left: none;
        border-bottom-color: rgba(255, 255, 255, .15)
    }

    .article__header-content,
    .category-page__header-content,
    .image-block--left .image-block__wrapper,
    .image-block--right .image-block__wrapper {
        flex-direction: column
    }

    .image-block--left .image-block__image,
    .image-block--right .image-block__image {
        max-width: 100%
    }

    .search-form__input-wrapper {
        flex-direction: column;
        max-width: 100%
    }

    .search-form__tag-select {
        min-width: 100%
    }

    .search-results__content {
        flex-direction: row;
        gap: 1rem
    }

    .search-results__image {
        width: 150px;
        flex-shrink: 0;
        aspect-ratio: 1
    }

    .article__image--main,
    .category-page__image {
        align-self: center
    }

    .article__title,
    .category-page__title {
        font-size: 2rem
    }

    .article__meta {
        flex-direction: column;
        align-items: flex-start;
        gap: .5rem
    }

    .article-list--compact {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: .75rem
    }

    .category-page__articles-title,
    .error-page__title {
        font-size: 1.5rem
    }

    .faq-block__title {
        font-size: 1.75rem
    }

    .faq-item__question {
        padding: 1rem;
        font-size: 1rem
    }

    .faq-item[aria-expanded=true] .faq-item__answer {
        padding: 1rem
    }

    .error-page__code {
        font-size: 5rem
    }

    .error-page__description {
        font-size: 1rem
    }

    .article__rating-buttons {
        flex-direction: column;
        align-items: stretch
    }

    .article__rating-button {
        justify-content: center
    }

    .pagination__list {
        gap: .25rem
    }

    .pagination__current,
    .pagination__link {
        min-width: 2rem;
        height: 2rem;
        padding: 0 .5rem;
        font-size: .85rem
    }
}

.sidebar-block__title {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #333
}

.sidebar-pages__item {
    border-bottom: 1px solid #e0e0e0;
    padding-bottom: 1rem
}

.sidebar-pages__item:last-child {
    border-bottom: none;
    padding-bottom: 0
}

html.dark .sidebar-pages__item {
    border-bottom-color: rgba(255, 255, 255, .15)
}

.sidebar-pages__extended,
.sidebar-pages__standard {
    display: flex;
    flex-direction: column;
    gap: .75rem
}

.sidebar-pages__image {
    width: 100%;
    overflow: hidden;
    border-radius: 6px
}

.sidebar-pages__image img {
    width: 100%;
    height: auto;
    display: block
}

.sidebar-pages__extended--overlay,
.sidebar-pages__standard--overlay {
    gap: 0
}

.sidebar-pages__image-wrapper {
    position: relative;
    width: 100%;
    border-radius: 6px;
    overflow: hidden;
    min-height: 150px
}

.sidebar-pages__image-wrapper .sidebar-pages__image,
.sidebar-pages__overlay {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%
}

.sidebar-pages__image-wrapper .sidebar-pages__image img {
    width: 100%;
    height: 100%;
    object-fit: cover
}

.sidebar-pages__overlay {
    background: linear-gradient(to bottom, rgba(0, 0, 0, .3), rgba(0, 0, 0, .6));
    z-index: 1
}

.sidebar-pages__content--overlay {
    position: relative;
    z-index: 2;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    min-height: 150px;
    gap: .75rem
}

.sidebar-pages__content--overlay .sidebar-pages__title {
    margin: 0
}

.sidebar-pages__content--overlay .sidebar-pages__title a {
    color: #fff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, .5)
}

.sidebar-pages__content--overlay .sidebar-pages__category a,
.sidebar-pages__content--overlay .sidebar-pages__meta {
    color: rgba(255, 255, 255, .9);
    text-shadow: 0 1px 2px rgba(0, 0, 0, .5)
}

.sidebar-pages__content--overlay .sidebar-pages__title a:hover {
    color: #fff;
    text-decoration: underline
}

.sidebar-pages__content--overlay .sidebar-pages__meta {
    justify-content: center
}

.sidebar-pages__content--overlay .sidebar-pages__category,
.sidebar-pages__content--overlay .sidebar-pages__date {
    color: rgba(255, 255, 255, .9)
}

.sidebar-pages__content--overlay .sidebar-pages__likes {
    color: #fff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, .5)
}

.sidebar-pages__content--overlay .sidebar-pages__category a:hover {
    color: #fff;
    text-decoration: underline
}

.sidebar-pages__link-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3;
    text-decoration: none
}

.sidebar-pages__title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
    line-height: 1.4
}

.sidebar-pages__title a {
    color: #333;
    transition: color .3s
}

.sidebar-pages__title a:hover {
    color: #007bff;
    text-decoration: underline
}

html.dark .sidebar-pages__date,
html.dark .sidebar-pages__meta {
    color: #999
}

html.dark .sidebar-pages__title a:hover {
    color: #4285f4
}

.sidebar-pages__content {
    display: flex;
    flex-direction: column;
    gap: .5rem
}

.sidebar-pages__meta {
    display: flex;
    flex-wrap: wrap;
    gap: .75rem;
    align-items: center;
    font-size: .875rem;
    color: #666
}

.custom-button,
.sidebar-tags__tag {
    display: inline-block;
    text-decoration: none;
    transition: .3s
}

.sidebar-pages__date {
    color: #666
}

.sidebar-pages__likes {
    color: #28a745;
    font-weight: 500
}

html.dark .sidebar-pages__likes {
    color: #4caf50
}

.sidebar-pages__category {
    color: #007bff
}

html.dark .sidebar-pages__category {
    color: #4285f4
}

.sidebar-pages__category a {
    color: inherit;
    text-decoration: none
}

.sidebar-pages__category a:hover {
    text-decoration: underline
}

.sidebar-pages__empty,
.sidebar-tags__empty {
    color: #999;
    font-size: .9rem;
    margin: 0
}

html.dark .sidebar-pages__empty {
    color: #666
}

.sidebar-tags__tag {
    padding: .375rem .75rem;
    background: #f0f0f0;
    color: #333;
    border-radius: 20px;
    font-size: .875rem;
    border: 1px solid transparent
}

html.dark .sidebar-tags__tag {
    background: rgba(255, 255, 255, .1);
    color: #e0e0e0;
    border-color: rgba(255, 255, 255, .15)
}

html.dark .custom-button--primary,
html.dark .sidebar-tags__tag:hover {
    background: #4285f4;
    border-color: #4285f4
}

.sidebar-tags__tag:hover {
    background: #007bff;
    color: #fff;
    border-color: #007bff;
    transform: translateY(-1px)
}

html.dark .sidebar-tags__tag:hover {
    box-shadow: 0 2px 4px rgba(66, 133, 244, .3)
}

html.dark .sidebar-tags__empty {
    color: #666
}

.custom-button {
    padding: .75rem 1.5rem;
    text-align: center;
    border-radius: 6px;
    font-weight: 500;
    border: 2px solid transparent;
    cursor: pointer;
    width: 100%;
    box-sizing: border-box
}

.custom-button--small {
    padding: .5rem 1rem;
    font-size: .875rem
}

.custom-button--medium {
    padding: .75rem 1.5rem;
    font-size: 1rem
}

.custom-button--large {
    padding: 1rem 2rem;
    font-size: 1.125rem
}

.custom-button--primary {
    background: #007bff;
    color: #fff;
    border-color: #007bff
}

.custom-button--primary:hover {
    background: #0056b3;
    border-color: #0056b3;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 123, 255, .3)
}

html.dark .custom-button--primary:hover {
    background: #3367d6;
    border-color: #3367d6
}

.custom-button--success {
    background: #28a745;
    color: #fff;
    border-color: #28a745
}

.custom-button--success:hover {
    background: #218838;
    border-color: #218838;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(40, 167, 69, .3)
}

html.dark .custom-button--success {
    background: #4caf50;
    border-color: #4caf50
}

html.dark .custom-button--success:hover {
    background: #45a049;
    border-color: #45a049
}

.custom-button--danger {
    background: #dc3545;
    color: #fff;
    border-color: #dc3545
}

.custom-button--danger:hover {
    background: #c82333;
    border-color: #c82333;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(220, 53, 69, .3)
}

html.dark .custom-button--danger {
    background: #f44336;
    border-color: #f44336
}

html.dark .custom-button--danger:hover {
    background: #e53935;
    border-color: #e53935
}

.custom-button--warning {
    background: #ffc107;
    color: #212529;
    border-color: #ffc107
}

.custom-button--warning:hover {
    background: #e0a800;
    border-color: #e0a800;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(255, 193, 7, .3)
}

html.dark .custom-button--warning {
    background: #ff9800;
    border-color: #ff9800;
    color: #fff
}

html.dark .custom-button--warning:hover {
    background: #f57c00;
    border-color: #f57c00
}

.custom-button--info {
    background: #17a2b8;
    color: #fff;
    border-color: #17a2b8
}

.custom-button--info:hover {
    background: #138496;
    border-color: #138496;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(23, 162, 184, .3)
}

html.dark .custom-button--info {
    background: #00bcd4;
    border-color: #00bcd4
}

html.dark .custom-button--info:hover {
    background: #00acc1;
    border-color: #00acc1
}

.custom-button--secondary {
    background: #6c757d;
    color: #fff;
    border-color: #6c757d
}

.custom-button--secondary:hover {
    background: #5a6268;
    border-color: #5a6268;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(108, 117, 125, .3)
}

html.dark .custom-button--secondary {
    background: #757575;
    border-color: #757575
}

html.dark .custom-button--secondary:hover {
    background: #616161;
    border-color: #616161
}

/* Стили для изображений в RichText блоках */
.richtext-image-wrapper {
    margin: 1rem 0;
    text-align: center;
}

.richtext-image-wrapper img {
    max-width: 100%;
    height: auto;
}

/* Стили для richtext изображений */
.richtext-image {
    max-width: 100%;
    height: auto;
    margin: 1rem 0;
}

.richtext-image.left {
    float: left;
    margin-right: 1rem;
    margin-bottom: 0.5rem;
}

.richtext-image.right {
    float: right;
    margin-left: 1rem;
    margin-bottom: 0.5rem;
}

.richtext-image.full-width {
    width: 100%;
    height: auto;
}

.richtext-element {
    /* Сброс стилей для richtext элементов */
}

.richtext-element img {
    max-width: 100%;
    height: auto;
}

/* Рекламные блоки в тексте не должны «залипать» к плавающим картинкам */
.ad-block {
    clear: both;
}