/* ========== ОБЩИЕ СТИЛИ ========== */
:root {
    --primary: #dd6b20;
    --primary-dark: #c15e1c;
    --secondary: #cf3033;
    --text-dark: #27241d;
    --text-light: #504a40;
    --bg-light: #faf9f7;
    --white: #ffffff;
    --gray: #e8e6e1;
    --shadow: 0 10px 30px rgba(0,0,0,0.05);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Montserrat', sans-serif;
    color: var(--text-light);
    background: var(--bg-light);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ========== ШАПКА ========== */
.header {
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0,0,0,0.03);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header__inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-dark);
    text-decoration: none;
    letter-spacing: 1px;
}

.logo i {
    color: var(--primary);
    margin-right: 8px;
}

.nav__list {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav__list a {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav__list a:hover {
    color: var(--primary);
}

.header__icons a {
    color: var(--text-light);
    margin-left: 20px;
    font-size: 20px;
    transition: var(--transition);
}

.header__icons a:hover {
    color: var(--primary);
}

/* ========== HERO ========== */
.hero {
    padding: 100px 0;
    background: linear-gradient(rgba(11,12,16,0.8), rgba(11,12,16,0.8)),
                url('https://images.unsplash.com/photo-1467810563316-b5476525c0f9?ixlib=rb-4.0.3&auto=format&fit=crop&w=1350&q=80') center/cover no-repeat;
    text-align: center;
    color: white;
}

.hero__title {
    font-size: 56px;
    font-weight: 700;
    margin-bottom: 20px;
    text-shadow: 0 0 20px rgba(102,252,241,0.5);
}

.hero__subtitle {
    font-size: 20px;
    max-width: 600px;
    margin: 0 auto;
}

/* ========== ЗАГОЛОВКИ СЕКЦИЙ ========== */
.section-title {
    font-size: 36px;
    font-weight: 600;
    color: var(--text-dark);
    margin: 60px 0 40px;
    text-align: center;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--primary);
    margin: 15px auto 0;
    border-radius: 2px;
}

/* ========== ФИЛЬТРЫ ========== */
.filters {
    background: var(--white);
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 30px;
    box-shadow: var(--shadow);
}

.filters__row {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    align-items: flex-end;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.filter-group label {
    font-weight: 600;
    font-size: 14px;
    color: var(--text-dark);
}

.filter-group select,
.filter-group input[type="checkbox"] {
    padding: 8px 12px;
    border: 1px solid var(--gray);
    border-radius: 8px;
    background: var(--white);
    font-family: inherit;
}

.filter-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-right: 5px;
    vertical-align: middle;
}

.btn--filter {
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn--filter:hover {
    background: var(--primary-dark);
}

.btn--reset {
    background: transparent;
    color: var(--text-light);
    border: 1px solid var(--gray);
    padding: 10px 20px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    display: inline-block;
}

.btn--reset:hover {
    background: var(--gray);
}

/* ========== СЕТКА ТОВАРОВ ========== */
.products__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

/* Карточка товара */
.product-card {
    background: var(--white);
    border-radius: 20px;
    overflow: hidden;
    transition: var(--transition);
    position: relative;
    border: 1px solid var(--gray);
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 30px rgba(0,0,0,0.1);
    border-color: var(--primary);
}

.product-card__sale {
    position: absolute;
    top: 15px;
    right: 15px;
    background: var(--secondary);
    color: var(--white);
    padding: 5px 15px;
    border-radius: 25px;
    font-weight: 700;
    font-size: 14px;
    z-index: 2;
}

.product-card__image {
    height: 200px;
    overflow: hidden;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-card__image img {
    transform: scale(1.05);
}

.product-card__info {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-card__title {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
}

.product-card__category {
    font-size: 14px;
    color: var(--primary);
    margin-bottom: 10px;
}

.product-card__category i {
    margin-right: 5px;
}

.product-card__description {
    font-size: 14px;
    margin-bottom: 15px;
    flex-grow: 1;
    color: var(--text-light);
}

.product-card__price {
    margin-bottom: 20px;
    display: flex;
    align-items: baseline;
    gap: 10px;
}

.price {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-dark);
}

.price.old {
    font-size: 16px;
    color: #8a8f99;
    text-decoration: line-through;
}

.price.sale {
    color: var(--secondary);
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 30px;
    font-weight: 600;
    text-decoration: none;
    text-align: center;
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.btn--primary {
    background: var(--primary);
    color: var(--white);
}

.btn--primary:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
}

.no-products {
    grid-column: 1 / -1;
    text-align: center;
    padding: 50px;
}

/* Пагинация */
.pagination {
    margin-top: 40px;
    margin-bottom: 40px;  /* отступ снизу */
    text-align: center;
}

.pagination__info {
    margin-bottom: 15px;
    font-size: 14px;
    color: var(--text-light);
}

.pagination__pages {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}

.page-link {
    display: inline-block;
    padding: 8px 12px;
    background: var(--white);
    border: 1px solid var(--gray);
    border-radius: 8px;
    color: var(--text-dark);
    text-decoration: none;
    transition: var(--transition);
    font-size: 14px;
    min-width: 36px;
    text-align: center;
}

.page-link:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.page-link.current {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    font-weight: 600;
    cursor: default;
}

/* ========== ФУТЕР ========== */
.footer {
    background: #000;
    color: #aaa;
    padding: 30px 0;
    border-top: 1px solid rgba(102,252,241,0.1);
}

.footer__inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer__social a {
    color: #aaa;
    font-size: 24px;
    margin-left: 15px;
    transition: var(--transition);
}

.footer__social a:hover {
    color: var(--primary);
}

/* ========== АДАПТИВНОСТЬ ========== */
@media (max-width: 768px) {
    .hero__title {
        font-size: 36px;
    }
    .header__inner {
        flex-direction: column;
        height: auto;
        padding: 15px 0;
    }
    .nav__list {
        flex-wrap: wrap;
        justify-content: center;
        margin: 10px 0;
    }
    .header__icons {
        margin-top: 10px;
    }
    .products__grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: 20px;
    }
    .filters__row {
        flex-direction: column;
        align-items: stretch;
    }
    .filter-group select,
    .filter-group input[type="checkbox"] {
        width: 100%;
    }
}
/* Стили для страницы каталога */
.page-header {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    color: white;
    padding: 60px 0;
    text-align: center;
    margin-bottom: 40px;
}

.page-title {
    font-size: 48px;
    font-weight: 700;
    margin: 0;
}

.catalog-section {
    padding: 0 0 80px;
}

.categories__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
}

.category-card {
    display: block;
    text-decoration: none;
    background: var(--white);
    border-radius: 16px;
    padding: 30px 10px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
    border: 1px solid var(--gray);
}

.category-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 30px rgba(0,0,0,0.1);
    border-color: var(--primary);
}

.category-card__icon i {
    font-size: 48px;
    color: var(--primary);
    margin-bottom: 20px;
}

.category-card img {
    max-width: 100%;       /* картинка не будет шире карточки */
    height: auto;          /* сохраняем пропорции */
    display: block;
    margin: 0 auto 20px;   /* центрируем и добавляем отступ снизу */
}

.category-card__title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.category-card__link {
    color: var(--primary);
    font-weight: 500;
    font-size: 14px;
}

.no-categories {
    grid-column: 1 / -1;
    text-align: center;
    padding: 50px;
    color: var(--text-light);
}

/* Адаптивность для мобильных устройств */
@media (max-width: 768px) {
    .page-title {
        font-size: 32px;
    }
    .categories__grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
}

/* Форма поиска в шапке */
.search-form {
    display: flex;
    align-items: center;
    background: var(--bg-light);
    border-radius: 30px;
    border: 1px solid var(--gray);
    overflow: hidden;
    transition: var(--transition);
    margin-right: 15px;
}

.search-form:hover,
.search-form:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(221, 107, 32, 0.1);
}

.search-form input {
    border: none;
    background: transparent;
    padding: 8px 15px;
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    width: 180px;
    outline: none;
    color: var(--text-dark);
}

.search-form input::placeholder {
    color: var(--text-light);
    opacity: 0.7;
}

.search-form button {
    background: transparent;
    border: none;
    padding: 8px 15px;
    cursor: pointer;
    color: var(--text-light);
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.search-form button:hover {
    color: var(--primary);
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .search-form input {
        width: 120px;
    }
}

@media (max-width: 480px) {
    .search-form {
        margin-right: 5px;
    }
    .search-form input {
        width: 80px;
    }
}

/* Корректировка шапки: поиск и корзина в ряд */
.header__icons {
    display: flex;
    align-items: center;
    flex-direction: row;      /* гарантируем горизонтальное расположение */
    gap: 15px;                 /* отступ между поиском и корзиной */
}

.search-form {
    width: auto;               /* форма занимает столько, сколько нужно */
    min-width: 200px;          /* можно задать минимальную ширину */
    flex-shrink: 0;            /* запрещаем сжиматься */
}

.cart__count {
    position: absolute;
    top: -8px;
    right: -15px;        /* отрегулируйте по вкусу */
    background: var(--primary);
    color: white;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 50%;
    min-width: 18px;
    text-align: center;
    line-height: 1;
}

.cart-link {
    position: relative;
    display: inline-block;
    color: var(--text-light);
    font-size: 20px;
}

/* Верхняя полоска с контактами */
.header__top {
    background: #000;
    color: var(--white);
    font-size: 13px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(102,252,241,0.1);
}

.header__top-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    padding-left: 230px;    /* добавьте отступы */
    padding-right: 20px;   /* чтобы текст не прилипал к краям */
}

.header__info i {
    margin-right: 5px;
    margin-left: 15px;
    color: var(--primary);
}

.header__info i:first-child {
    margin-left: 0;
}

.header__social a {
    color: var(--white);
    margin-left: 15px;
    font-size: 16px;
    transition: var(--transition);
}

.header__social a:hover {
    color: var(--primary);
}

/* Адаптивность для мобильных */
@media (max-width: 768px) {
    .header__top-inner {
        flex-direction: column;
        text-align: center;
    }
    .header__info i {
        margin-left: 5px;
    }
}