/*----------------------------------------Стилизация попапа----------------------------------------------------------------*/
.modal-content form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    margin-bottom: 5px;
    font-weight: bold;
    font-size: 14px;
}

.form-group input {
    padding: 8px;
    border-radius: 5px;
    border: 1px solid #ccc;
    font-size: 14px;
}

.profile-nav ul {
    list-style: none; /* убирает буллеты */
    margin: 0;
    padding: 0;
    display: flex;   /* горизонтально */
    gap: 20px;       /* расстояние между пунктами */
}

.profile-nav ul li a {
    text-decoration: none;
    color: #000;
}

.profile-nav ul li a.active {
    font-weight: bold;  /* выделяем активный пункт */
}

.profile-nav ul li a:hover {
    text-decoration: underline;
}

/*--------------------------------------------Стилизация главной страницы-------------------------------------------*/
html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    overflow-x: hidden; /* отключает горизонтальную прокрутку */
}
body {
    font-family: 'Roboto', sans-serif;
    color: rgb(44, 14, 3);
}
.button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #1a7df7;
    color: #fff;
    text-transform: uppercase;
    text-decoration: none;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.3s;
}

.hero {
    position: relative;
    width: 100vw;   /* 100% ширины экрана */
    height: 96vh;  /* оставляем место под меню */
    overflow: hidden;
    margin: 0;
    padding: 0;
}

.hero__image {
    width: 100%;
    height: 100%;
    object-fit: cover; /* растягивает изображение, сохраняя пропорции и заполняя экран */
    display: block;
}

.hero__overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: white;
    max-width: 90%;
}

.hero__overlay h1 {
    font-size: 3rem; /* можно увеличить */
    font-weight: 200;
    line-height: 1;
    
}

.hero__overlay .button {
    display: inline-block;
    margin-top: 20px;
    padding: 15px 30px;
    background-color: #1a7df7;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-size: 1.2rem;
}
@media (max-height: 700px) {
    .hero__overlay h1 {
        font-size: 2rem;
    }
    .hero__overlay .button {
        padding: 8px 16px;
        font-size: 1rem;
        margin-top: 10px;
    }
}
.hero__overlay .button {
    border-radius: 50px;
    width: 249px;
}
/*-------------------------------------------------------Стилизация блока с категориями--------------------------------*/
.categories {
    max-width: 1200px;
    margin: 0 auto 80px;
    padding: 0 20px;
}
.category__image {
    flex: 1;              /* занимает всю оставшуюся площадь карточки */
    width: 100%;
    overflow: hidden;      /* ключевое: картинка не выходит за пределы */
    border-radius: 10px 10px 0 0;  /* скругляем верх */
}
.category__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;

    /* плавная анимация для transform и brightness */
    transition: transform 0.5s ease, filter 0.5s ease;
}
.categories h2 {
    text-align: center;
    margin-bottom: 40px;
}

.categories__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;

}
.category__item {
    aspect-ratio: 1 / 1; /* ✅ квадрат */
    background: #f5f5f5;
    border-radius: 16px;

    display: flex;
    flex-direction: column;

    font-size: 20px;
    font-weight: 600;
    text-align: center;

    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.category__item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius:  10px 10px 0px 0px;
    overflow: hidden; /* обязательно, чтобы картинка не вылезала за пределы */
}
.category__item:hover .category__image img {
    transform: scale(1.05);  /* слегка увеличиваем */
    filter: brightness(0.95); /* немного затемняем, красиво смотрится на синем футере */
}
.category__footer {
    height: 64px;
    background: #1e5bfa;

    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 0 20px;
    font-size: 28px;
    font-weight: 200;
    color: white;
    border-radius: 0px 0px 10px 10px;
}
img.category__arrow {
    width: 56px;
    height: 47px;
    transform: rotate(-30deg);
    transition: transform ease;
    left: 12px;
    position: relative;
}
.reviews h2 {
    text-align: center !important;
}
section.contacts {
     border-radius: 10px;
}     
@media (max-width: 480px) {
    .hero__overlay h1 {
       font-size: 24px;       
        line-height: 1.25;
    }
 
   .categories__grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 19px;
        margin-left: -16px;
    
    }
   .category__item {
    width: 182px;
    height: 216px;
   }  
   .category__footer {
      font-size: 15px;
      height: 49px;
   }
   img.category__arrow {
      width: 48px;
      height: 38px;
   }
   .categories__grid .category__item:nth-child(5) .category__arrow {
    height: 37px;
    width: 36px;
    }   
    .new-products__grid {
        grid-template-columns: repeat(auto-fit, minmax(398px, 1fr)) !important;    
        padding: 0px;
        position: relative;
        left: -43px;
   }
   .advantages h2 {
        text-align: center;
    }
    .advantage__item {
        width: 100% !important;
        max-width: 100% !important;
        position: relative;
        left: -42px;
   }
    section.advantages {
        margin-top: 92px;
        text-align: center;
        width: 114%;
        padding: 0px;
    }
    .advantages h2 {
        text-align: center !important;
        position: relative;
        left: -13px;
    }  
    .review__item {
        width: 123%;
        margin-bottom: 20px;
        height: 134px;
    }
    .reviews__grid {
        width: 157%;
        position: relative;
        left: -70px;
    }
    section.contacts {
        position: relative;
        left: -33px;
        width: 110%;   
    }
    .contacts__info {
        padding-left: 43px;
        padding-right: 66px;
    }
}   
@media (min-width: 376px) and (max-width: 390px) {
    .categories__grid {
        margin-left: -21px;
    }
    .category__item {
        width: 169px;
        height: 236px;    
    }
    .category__footer {
        font-size: 14px;
        height: 49px;
    }
    img.category__arrow {
        width: 38px;
        height: 28px;
    }
    .categories__grid .category__item:nth-child(5) .category__arrow {
        width: 26px;
        height: 26px;
    }
    .new-products__item {
        width: 89% !important;
        height: 100% !important;
   }
   .reviews__grid {
        width: 163% !important;
     }
}
@media (max-width: 375px) {
     .categories__grid .category__item:nth-child(5) .category__arrow {
        height: 22px;
     }    
 
    img.category__arrow {
        width: 38px;
        height: 13px;
    }
    .category__item {
        width: 150px;
        height: 185px;
    }
    .new-products__item {
        width: 83% !important;
    }    
   .advantage__item {
        width: 105% !important;
        max-width: 105% !important;
    }
    .review__item {
        width: 92%  !important;
    }
    section.contacts {
        position: relative;
        left: -50px;
        width: 125%;
    }
    .contacts__info {
        padding-left: 61px;
        padding-right: 39px;
    }    
}
/*---------------------------------------------Стилизация блока новинок------------------------------------------------------------*/
.new-products__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    width: 100%;
    max-width: 100%;
    margin: 0;
    align-items: stretch; /* карточки тянутся по высоте ряда */
}

.new-products__item {
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    height: 100%; /* растягиваем на всю высоту ячейки grid */
}
.new-products {
    margin-top: 120px;
    margin-left: 20px;
    margin-right: 20px;
}
.new-products__photo {
    width: 100%;
    height: auto;
    max-height: 90%;      /* максимум для изображения */
    object-fit: cover;       /* изображение заполняет контейнер без искажений */
    border-radius: 10px;
    margin-bottom: 15px;
}

/* Текст под изображением растягивается, чтобы карточка имела одинаковую высоту */
.new-products__item h3,
.new-products__item .new-products__price {
    width: 100%;
    text-align: center;
    margin: 0;
}
.new-products__photo-container {
    position: relative;
    width: 100%;
    padding-top: 100%; /* соотношение 1:1 — квадрат */
    overflow: hidden;
    border-radius: 10px;
}

.new-products__photo-container img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.modal {
    display: none; /* Скрыто по умолчанию */
    position: fixed; 
    z-index: 1000; 
    left: 0;
    top: 0;
    width: 100%; 
    height: 100%;
    overflow: auto; 
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    background-color: #fff;
    margin: 10% auto;
    padding: 20px;
    border-radius: 10px;
    width: 300px;
}

.close {
    float: right;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
}












.button:hover {
    background-color: #973704;
    transform: translateY(-3px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.1);
}
.navbar {
    height: 60px;
    text-align: center;
    margin-bottom: 20px;
}
.header__logo {
    color: inherit;
    text-decoration: inherit;
    
    padding-left: 50px;
    font-weight: 700;
    font-size: 34px;
    margin-bottom: 30px;
}
.breadcrumbs {
    display: flex;
    align-items: center;
    font-size: 16px;
    margin-top: 20px;
    margin-bottom: 20px;
    position: relative;
}

.breadcrumbs a {
    text-decoration: none;
    color: #e45100;
}

.breadcrumbs a:hover {
    text-decoration: underline;
    color: #973704;
}

.breadcrumbs span {
    margin: 0 5px;
    color: #777;
}
.center {
    margin-top: 20px;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
}
.content__container {
    max-width: 100%;
    margin: auto;
    padding-left: 20px;
    padding-right: 20px;
    margin-top: 120px;
}


/* Catalog */
.catalog__container {
    margin: auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 120px;
}

.catalog__item {
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    background-color: #fff;
    padding: 30px;
    border-radius: 5px;
    transition: box-shadow 0.3s ease;
}

.catalog__item:hover {
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.2);
}


.catalog__item__photo {
     object-fit: contain;
}

.catalog__item__photo__container {
    border-radius: 10px;
    max-width: 588px !important;
}    

.product-item {
    text-align: center;
    display: grid;
}    
@media (max-width: 767px) {
    .catalog__container {
        grid-template-columns: 1fr;
    }
}
.catalog__item__header {
    color: inherit;
    text-decoration: inherit;
}
.catalog__item__header h2 {
    margin-top: 0;
}
.catalog__item__photo__container {
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    border-radius: 10px;
}
.catalog__item__photo {
    /* flex-shrink: 0; */
    min-width: 100%;
    min-height: 100%;
    object-fit: cover;
}
.catalog__item__price {
    font-size: 22px;
    padding-top: 20px;
    padding-bottom: 20px;
    font-weight: 500;
}
/* /Catalog */


/* Popular Products */
.popular-product__container {
    max-width: 800px;
    margin: auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
}

.popular-product__item {
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    background-color: #fff;
    padding: 30px;
    border-radius: 5px;
    transition: box-shadow 0.3s ease;
}

.popular-product__item:hover {
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.2);
}

.popular-product__item__header {
    color: inherit;
    text-decoration: inherit;
}
.popular-product__item__header h2 {
    margin-top: 0;
}
.popular-product__item__photo__container {
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    border-radius: 10px;
}
.popular-product__item__photo {
    min-width: 100%;
    min-height: 100%;
    object-fit: cover;
}
.popular-product__item__price {
    font-size: 18px;
    padding-top: 20px;
    /* padding-bottom: 20px; */
    font-weight: 500;
}
/* /Popular Products */


/* Sort */
.sort {
    position: absolute;
    right: 0;
}
.sort button[type="submit"] {
    border: none;
    padding:4px 8px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    margin: 4px 2px;
    cursor: pointer;
    border-radius: 5px;
}

.sort button[type="submit"]:hover {
    background-color: #bcbcbc;
    color: white;
}

img.advantage__icon {
    width: 56px;
}
/*----------------------------------------------------Стилизация блока Преимущества-------------------------------*/
section.advantages {
    margin-top: 100px;
    text-align: center;
}

.advantages h2 {
    margin-bottom: 40px;
    color: #2c0e03;
    text-align: left;
}

/* === Сетка карточек (Grid) === */
.advantages__grid {
    display: grid;
    /* теперь карточки растягиваются, заполняя пространство */
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 81px;

    width: 100%;
    max-width: 97%; /* ✅ ограничим максимум, чтобы не было растяжения до бесконечности */
}

/* === Карточка преимущества === */
.advantage__item {
    width: 100%; /* занимает всю ширину ячейки */
    height: 90%;
    border: 1px solid #ddd;
    padding: 50px 26px;
    border-radius: 10px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    background: #fff;
}


/* === Иконка === */
.advantage__icon {
    width: 40px;
    height: 40px;
    margin-bottom: 10px;
    object-fit: contain;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

/* === Заголовок и текст === */
.advantage__item h3 {
    margin: 10px 0;
    font-size: 18px;
    color: #1a7df7;
}

.advantage__item p {
    font-size: 14px;
    color: #2c0e03;
    line-height: 1.5;
}

/* === Адаптивность === */
@media (max-width: 768px) {
    .advantages h2 {
        font-size: 1.6rem;
    }

    .advantage__item {
        max-width: 90%;
    }
}

/*----------------------------------------------------Стилизация блока Отзывы----------------------------------------------*/
.reviews {
    max-width: 100%;
    text-align: center;
    padding: 0 20px;
    margin-top: 193px;
}

.reviews h2 {
    margin-bottom: 40px;
    text-align: left;
}

.reviews__grid {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 20px;
}

.review__item {
    background-color: #fff;
    padding: 20px 25px;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    width: 20%; /* три отзыва в ряд на десктопе */
    transition: transform 0.3s ease;
}

.review__item:hover {
    transform: translateY(-5px);
}

.review__text {
    font-size: 16px;
    margin-bottom: 15px;
    color: #2c0e03;
}

.review__author {
    font-weight: 600;
    color: #e45100;
}


@media (max-width: 1366px) {
.advantages__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(198px, 1fr));
    gap: 83px;
    width: 97%;
    max-width: 100%;
   }
}
/* Адаптивность */
@media (max-width: 1024px) {
    .review__item {
        width: 45%; /* 2 отзыва в ряд на планшете */
    }
}

@media (max-width: 768px) {
    .reviews__grid {
        flex-direction: column;
        align-items: center;
    }
    .review__item {
        width: 80%; /* 1 отзыв в ряд на мобильных */
        margin-bottom: 20px;
    }
}

/* --------------------------------------------Стилизация блока КОНТАКТЫ-------------------------------------------------- */
section.contacts {
    margin-top: 100px;
    padding: 60px 20px;
    background-color: #fafafa;
    text-align: center;
    margin-bottom: 60px;
}

.contacts h2 {
    text-align: left;
    margin-bottom: 40px;
    color: #2c0e03;
}

.contacts__container {
    display: flex;
    justify-content: center;
    align-items: stretch;
    gap: 26px;
    max-width: 100%;
    margin: 0 auto;
    flex-wrap: wrap;
}

.contacts__info {
    flex: 1 1 2px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 10px;
    text-align: left;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    padding-left: 35px;
}

.contacts__info h3 {
    font-size: 1.4rem;
    color: #1a7df7;
    margin-bottom: 15px;
}

.contacts__info p {
    font-size: 15px;
    color: #2c0e03;
    margin: 10px 0;
}

.contacts__info a {
    color: #1a7df7;
    text-decoration: none;
}

.contacts__info a:hover {
    text-decoration: underline;
}

/* === Карта === */
.contacts__map {
    flex: 2 1 500px;
    min-height: 350px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

/* === Адаптив === */
@media (max-width: 768px) {
    .contacts__container {
        flex-direction: column;
        align-items: center;
    }
    .contacts__map {
        width: 100%;
        min-height: 300px;
    }
}

/* === Футер === */
.site-footer {
    background-color: #fafafa;
    color: #000;
    padding: 60px 20px 30px;
    font-size: 14px;
}

/* Контейнер футера */
.footer__container {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    max-width: 100%;
    margin: 0 auto;
    gap: 30px;
}

/* Заголовки и текст */
.footer__section {
    line-height: 1.6;
}

.footer__section h3 {
    font-size: 30px;
    margin-bottom: 10px; /* добавляем отступ! */
}

.footer__section h4 {
    margin-bottom: 10px;
    font-size: 16px;
    color: #1a7df7;
}

.footer__section p,
.footer__section a,
.footer__section li {
    color: #000000;
    margin: 2px ;   
}


.footer__section a {
    text-decoration: none;
}

.footer__section a:hover {
    text-decoration: underline;
}

/* Меню футера */
.footer__nav ul {
    list-style: none;
    padding: 0;
}

.footer__nav li {
    margin-bottom: 10px;
}

/* Соцсети */
.footer__icons {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.footer__icons img {
    width: 24px;
    height: 24px;
}

/* Нижняя строка */
.footer__bottom {
    text-align: center;
    margin-top: 40px;
    font-size: 13px;
    color: #888;
}

/* Адаптив */
@media (max-width: 768px) {
    .footer__container {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .footer__section {
        width: 100%;
    }
    .footer__icons {
        justify-content: center;
    }
}

/* /Sort */