.wrapper {
    max-width: 1200px;
    margin: 10px auto 0;
    padding: 0;
    display: grid;
    grid-gap: 1em;
}

@media (min-width: 800px) {
    .wrapper {
        grid-template-columns: 5fr 2fr;
        grid-template-areas: "content sidebar";
    }
    .content-area {
        grid-area: content;
    }

    #sidebar {
        grid-area: sidebar;
    }
}

@media (max-width: 799px) {
    .wrapper {
        grid-template-columns: 1fr;
    }
}


.cat-h1 {
    margin: 5px;
}

#sidebar {
    border: 1px solid var(--bd-color);
    padding: 14px 18px;
}

.wp-post-image, article img {
    width: 100%;
    height: auto;
    vertical-align: middle;
}




/*product category list*/

.cat-wrapper {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.prod-item {
    display: flex;
    border-bottom: 1px solid var(--bd-color);
    margin-bottom: 12px;
    padding-bottom: 6px;
}

.prod-item:last-child {
    margin-bottom: 0;
}

.prod-txt {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 100%;
}

.prod-txt .pm-excerpt {
    max-width: 70%;
    margin: 0;
}

.prod-thumb img {
    max-width: 100px;
    margin-right: 10px;
}

.prod-head {
    text-decoration: none;
}

.prod-title {
    margin: 0;
}

.popup-with-form {
    padding: 5px 20px;
    font-size: 12px;
    text-decoration: none;
    float: right;
    align-self: flex-end;
    margin-top: -30px;
}


/*sidebar*/


.widget-title {
    margin: 0;
    text-align: center;
}

.textwidget p, .textwidget ul li {
    font-size: 12px;
    line-height: 17px;
}

#sidebar ul {
    padding: 0;
    margin: 2px 0 2px 16px;
}

#sidebar ul li {
    margin: 3px 0;
}


@media screen and (max-width: 1200px) {
    .cat-h1 {
        font-size: 24px;
    }
    .cat-ben-item {
        padding: 0 30px;
        line-height: 20px;
    }
}

@media screen and (max-width: 1000px) {
    .cat-h1 {
        font-size: 22px;
    }
    .cat-ben-item {
        padding: 0 20px;
        line-height: 18px;
    }
    .cat-descr p {
        margin: 15px 0 10px;
        font-size: 14px;
        line-height: 20px;
    }
}

@media screen and (max-width: 800px) {
    .cat-h1 {
        font-size: 18px;
        line-height: 24px;
    }
    .cat-ben {
        flex-wrap: wrap;
    }
    .cat-ben-item {
        padding: 0 10px;
        line-height: 16px;
    }
    .prod-title {
        font-size: 18px;
        line-height: 22px;
    }
    .popup-with-form {
        width: initial;
        margin-top: -30px;
    }
    .prod-txt .pm-excerpt {
        max-width: 75%;
        margin: 0;
    }
}

@media screen and (max-width: 600px) {
    .prod-thumb {
        display: none;
    }
    .prod-title {
        font-size: 16px;
        line-height: 20px;
    }
    .prod-txt .pm-excerpt {
        max-width: 60%;
        margin: 0;
    }
}

@media screen and (max-width: 480px) {
    .prod-txt .pm-excerpt {
        max-width: 100%;
    }
    .prod-descr {
        display: flex;
        flex-direction: column;
        align-content: flex-start;
    }
    .popup-with-form {
        margin-top: 0;
        align-self: flex-start;
        margin-top: 5px;
    }

}

/*lists of subcategories such as in list and truba kruglaya*/

.cat-list-wrap {
    display: flex;
    justify-content: space-between;
}

.cat-list-item {

}

.cat-list-item a {
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.cat-list-item a h3 {
    display: inline-block;
    border-bottom: 2px solid transparent;
}

.cat-list-item a h3:hover {
    border-bottom: 2px solid var(--header-color);
}

.cat-list-item-a {
    margin-top: 4px;
    line-height: 15px;
    display: block;
    text-decoration: none;
    color: var(--font-color);
    font-size: 13px;
}

.cat-list-item-a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

@media screen and (max-width: 800px) {
    .cat-list-item img {
        max-width: 100px;
    }
}

@media screen and (max-width: 800px) {
    .cat-list-wrap {
        flex-direction: column;
        justify-content: space-around;
    }
    .cat-list-item img {
        max-width: 100%;
    }
}

/*profnastil and metallocherepitsa*/

.proflist-wrapper {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    grid-gap: 1em;
    align-items: center;
}

.proflist-thumb {
    display: block;
    text-align: center;
    transition: all .2s ease;
    text-decoration: none;
    border-bottom: 1px solid #e5e9e7;
}

.proflist-title {
    font-size: 16px;
    font-family: var(--header-font);
    color: var(--header-color);
    font-weight: bold;

}

.proflist-thumb:hover img {
    transition: all .2s ease;
    filter: hue-rotate(150deg);
}


/*справочник handbook*/

.handbook .cat-list-wrap {
   
}

.tv-wrapper {
    display: flex;
    flex-direction: column;
}

.tv-item-wrap {
    margin-bottom: 10px;
}

.tv-item {
    font-size: 18x;
    color: var(--header-color);
    font-family: var(--header-font);
    font-weight: bold;
    text-decoration: none;
}

.tv-wrapper .wp-post-image {
    max-width: 70px;
    -webkit-border-radius: 10px;
    -moz-border-radius: 10px;
    border-radius: 10px;
}