

/* Start:/local/templates/main-page/components/bitrix/news.list/unit-list/style.css?17615000881725*/
/* Обеспечиваем квадратную форму */
.square-tile {
    position: relative;
    width: 100%;
    padding-bottom: 100%; /* Это создаёт квадрат (aspect ratio 1:1) */
    overflow: hidden;
    background: #fff;
}

.square-tile .unit-image-wrapper,
.square-tile .unit-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transition: opacity 0.3s ease;
}

.square-tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* По умолчанию — видно изображение, скрыт оверлей */
.square-tile .unit-overlay {
    background: #fff;
    display: flex;
    align-items: start;
    /*justify-content: center;*/
    text-align: left;
    padding: 1rem;
    opacity: 0;
    pointer-events: none;
}

/* При наведении — изображение исчезает, появляется текст */
.square-tile:hover .unit-image-wrapper {
    opacity: 0;
}
.square-tile:hover .unit-overlay {
    opacity: 1;
    pointer-events: auto;
}

/* Стили текста внутри оверлея */
.unit-overlay-content > * {
    margin: 0.3rem 0;
    font-size: 0.9rem;
    color: #000;
}
.unit-overlay-content a {
    color: #007bff;
    display: block;
    text-decoration: none;
}
.unit-overlay-content a:hover {
    text-decoration: underline;
}

.unit-post-main {
    position: absolute;
    bottom: 0;
    padding: 4px 7px 7px;
    color: #ffffff;
    /* font-size: 12px !important; */
    margin: 5px;
    background: #000000;
}

.unit-post-main strong {
    font-size: 12px !important;
}
/* End */
/* /local/templates/main-page/components/bitrix/news.list/unit-list/style.css?17615000881725 */
