
/* вывод новостей */

h1 {
    line-height: 100%;
}

.news_section {
    max-width: 1360px;
    width: calc(100% - 32px);
    margin: 0 auto;
    padding: 0;
    box-sizing: border-box;
}

.news_grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    column-gap: 1.35vw;
    row-gap: 40px;
    width: 100%;
    align-items: stretch;
}

.news_card {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    padding: 0;
    gap: 24px;
    width: 100%;
    box-sizing: border-box;
    height: 100%;
    overflow: hidden;
}

.news_card_img {
    flex: 1 1 0%;
    aspect-ratio: 1.8;
    min-height: 200px;
    overflow: hidden;
    position: relative;
    background-color: #f0f0f0;
}

.news_card_img a {
    display: block;
    width: 100%;
    height: 100%;
}

.news_card_img img {
    object-fit: contain;
    display: block;
}

.news_card_info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    padding: 0;
    gap: 16px;
    flex: 1 1 0%;
    min-width: 0;
}

.news_card_meta {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 0;
    gap: 8px;
    align-self: stretch;
    flex-grow: 1;
    justify-content: space-between;
}

.news_card_meta p, .news_card_meta span {
    margin: 0;
}

.news_card_title {
    margin: 0;
    font-family: "Ony One";
    font-weight: 500;
    font-size: 18px;
    line-height: 114.9%;
    display: flex;
    align-items: center;
    color: #313332;
    width: 100%;
    line-clamp: 3;
    text-overflow: ellipsis;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.news_card_title a{
    font-weight: 500;
}

.news_card_title a {
    text-decoration: none;
    color: #313332;
    overflow: hidden;
    transition: color 0.3s ease-in-out;
}

.news_card_title a:hover {
    color: #AD83FF;
}

.news_card_date {
    font-family: "Ony One";
    font-weight: 400;
    font-size: 15px;
    line-height: 100%;
    display: flex;
    align-items: center;
    color: #AD83FF;
}

.news_card_text {
    font-family: "Ony One";
    font-weight: 400;
    font-size: 18px;
    line-height: 115%;
    color: #313332;
    width: 100%;
    margin: 0;
    line-clamp: 3;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
}

.news_load_more {
    display: flex;
    justify-content: center;
    margin-top: 24px;
    width: 100%;
    clear: both;
}

.btn_load_more {
    background-color: #ECECEC;
    color: #313332;
    border: none;
    padding: 14px 27px;
    font-family: "Ony One";
    font-weight: 500;
    font-size: 15px;
    line-height: 110%;
    cursor: pointer;
}

@media (max-width: 1199px) {
    .news_section {
        padding: 0 16px;
    }
    
    .news_grid {
        row-gap: 16px;
    }

    .news_card {
        gap: 16px;
    }

    .news_card_img {
        flex: 2;
        align-self: center;
    }
    
    .news_card_title {
        line-clamp: 5;
        -webkit-line-clamp: 5;
    }

    .news_card_info {
        flex: 3;
    }

    .news_card_text {
        display: none;
    }
}

@media (max-width: 767px) {
    .news_section {
        margin: 0;
        padding: 0 16px;
        width: 100%;
    }

    .news_grid {
        column-grid: 4px;
        row-gap: 24px;
    }

    .news_card {
        flex-direction: column;
        height: auto;
        gap: 8px;
        min-width: 0;
    }

    .news_card_img {
        align-self: stretch;
        aspect-ratio: 1.22;
    }

    .news_card_info {
        height: auto;
        gap: 16px;
        align-self: stretch;
    }

    .news_card_meta {
        display: flex;
        flex-direction: column-reverse;
        flex-grow: 0;
        justify-content: flex-start;
    }

    .news_card_title {
        order: 2;
    }
    
    .news_card_title a{
        font-size: 18px;
    }

    .news_card_date {
        order: 1;
        margin-bottom: 4px;
    }

    .news_card_text {
        display: none;
    }
}

@media(max-width: 500px){
    h1 {
        font-size: 20px;
        text-align: left;
        padding: 0;
    }
    
    .news_card_meta {
        flex-direction: column;
    }
    
    .news_card_title a{
        font-size: 16px;
    }
}

/* вроде стили отдельной новости (хз, не я стили писал)*/

.single-news-article {
    max-width: 1245px;
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
    font-family: "Ony One";
    font-weight: 400;
    color: #313332;
}

.single-news-article * {
    box-sizing: border-box;
}

.news-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin: 0 24.9px 32px 24.9px;
}

.news-header p {
    margin: 0;
}

.news-title {
    margin: 0;
    line-height: 100%;
}

.news-date {
    font-weight: 400;
    font-size: 15px;
    line-height: 100%;
    color: #AD83FF;
}

.news-body {
    display: flow-root;
}

/* Блок с изображением вместо коллажа */
.news-image {
    float: left;
    width: calc(56.39% - 32px);
    margin: 0 32px 24px 0;
    aspect-ratio: 1.33 / 1;
    overflow: hidden;
}

.news-image img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    object-position: center;
}

.news-content {
    font-weight: 400;
    font-size: 18px;
    line-height: 114.9%;
    color: #313332;
}

.single-news-article .news-content p {
    margin: 0 0 1em 0;
    font-size: 18px;
}

.news-content p:last-child {
    margin-bottom: 0;
}

.news-content a {
    color: #AD83FF;
    text-decoration: none;
}

.news-content a:hover {
    text-decoration: underline;
}

.news-sidebar {
    font-weight: 400;
    font-size: 18px;
    line-height: 114.9%;
    color: #313332;
    min-width: 0;
}

.news-sidebar p {
    margin: 0 0 1em 0;
}

.news-sidebar p:last-child {
    margin-bottom: 0;
}

.news-sidebar a {
    color: #AD83FF;
    text-decoration: none;
}

.news-sidebar a:hover {
    text-decoration: underline;
}

@media (max-width: 700px) {
    .single-news-article {
        padding: 0 16px;
    }

    .single-news-article .news-header {
        align-items: flex-start;
        margin: 0 0 24px 0;
    }

    .single-news-article .news-title {
        font-size: 20px;
        text-align: left;
    }

    .single-news-article .news-body {
        display: block;
    }

    .single-news-article .news-image {
        float: none;
        width: 100%;
        margin: 0 0 16px 0;
    }

    .single-news-article .news-sidebar,
    .single-news-article .news-content {
        width: 100%;
        display: block;
    }
    .single-news-article .news-content p {
        font-size: 16px;
    }
}

/*.news-content p.clear-text {*/
/*    clear: left;*/
/*    display: block;*/
/*    width: 100%;*/
/*    margin-top: 1em;*/
/*}*/

.news-content p {
    margin: 0 0 1em 0;
}