/* HEADER */
html, body {
    overflow-x: hidden;
    width: 100%;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
#paysystem-yandex-form{
    width:200px;
}

#panel {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10000;
    background: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    padding: 5px 10px;
    transform: translateY(-100%);
    transition: transform 0.3s ease;
}

#panel.visible {
    transform: translateY(0);
}

body.panel-visible {
    padding-top: 40px;
}

header {
    position: sticky !important;
    top: 0 !important;
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: minmax(20px, 1fr) repeat(8, minmax(auto, 160px)) minmax(20px, 1fr);
    align-items: center;
    gap: 15px;
    padding: 15px 0;
}

.logo {
    grid-column: 3;
    width: 170px;
    max-width: 180px;
    justify-self: center;
}

.catalog-button {
    width: 240px;
    height: 40px;
    grid-column: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding-left: 30px;
    background-color: #000004;
    border: none;
    border-radius: 3px;
    font-size: 14px;
    color: white;
    cursor: pointer;
}

.kataloge {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 26.4px;
    height: 13.64px;
}

/* Стили поиска */
.search-container {
    grid-column: 4 / 8;
    height: 40px;
    position: relative;
}

.search-form {
    display: flex;
    width: 100%;
    height: 100%;
}

.search {
    flex: 1;
    height: 100%;
    border: 2px solid #FFBF04;
    border-right: none;
    border-radius: 5px 0 0 5px;
    font-size: 14px;
    outline: none;
    transition: all 0.3s;
}

.search:focus {
    border-color: #FFA000;
    box-shadow: 0 0 5px rgba(255, 191, 4, 0.5);
}

.searchbtn {
    height: 100%;
    padding: 0 20px;
    border: 2px solid #FFBF04;
    border-left: none;
    border-radius: 0 5px 5px 0;
    background-color: #FFBF04;
    color: black;
    cursor: pointer;
    transition: background-color 0.3s;
    white-space: nowrap;
}

.searchbtn:hover {
    background-color: #FFC832;
}

.search-container .btn-mob {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Основное меню */
.navtolog {
    grid-column: 3 / 9;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #eee;
}

.contacts {
    grid-column: 4 / 8;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 25px;
    align-self: center;
    margin-top: 40px;
    height: 10px;
}

/* Мобильное меню (нижняя панель) */
.nav-phone {
    position: fixed;
    margin-top: 20px;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    padding: 10px;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    z-index: 9999;
    display: none;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.nav-phone a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 5px;
    border-radius: 8px;
    transition: all 0.2s ease;
    text-decoration: none;
    color: #333;
}

.nav-phone .icon-container {
    width: 24px;
    height: 24px;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-phone .icon-container svg {
    width: 100%;
    height: 100%;
    fill: currentColor;
}

.nav-phone span {
    font-size: 10px;
    line-height: 1.2;
}

.nav-phone a.active,
.nav-phone a.active span,
.nav-phone a.active .icon-container svg {
    color: #FFBF04;
    fill: #FFBF04;
}

/* Дополнительное мобильное меню */
.navtolog-phone {
    display: none;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    padding: 10px;
}

.navtolog-phone a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8px 5px;
    text-align: center;
    font-size: 12px;
    border-radius: 5px;
}

.navtolog-phone a .icon-container {
    width: 70px;
    height: 70px;
    border-radius: 4px;
    background: #f8f8f8;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Адаптация для мобильных (до 767px) */
@media (max-width: 767px) {
    body {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr);
    }
    
    header {
        grid-template-columns: minmax(0, 1fr);
        gap: 10px;
        padding: 10px;
    }
    
    .logo {
        grid-column: 1;
        max-width: 150px;
    }
    
    .katalog {
        display: none;
    }
    
    .search-container {
        grid-column: 1;
        width: 100%;
        padding: 0 10px;
        margin-bottom: 10px;
    }
    
    .search {
        border-radius: 20px;
        border-right: 2px solid #FFBF04;
        padding-left: 45px;
    }
    
    .searchbtn {
        display: none;
    }
    
    .search-container .btn-mob {
        visibility: visible;
    }
    
    .navtolog, .contacts {
        display: none;
    }
    
    .nav-phone {
        z-index: 9999;
        display: grid;
        margin-top: 20px;
    }
    
    .navtolog-phone {
        display: grid;
    }
    
    .header-icons {
        display: none !important;
    }
}

/* Адаптация для планшетов (768px - 1199px) */
@media (min-width: 768px) and (max-width: 1199px) {
    body {
        grid-template-columns: minmax(10px, 1fr) repeat(6, minmax(auto, 120px)) minmax(10px, 1fr);
    }
    
    .logo {
        grid-column: 2;
    }
    
    .katalog {
        grid-column: 2;
        width: 180px;
    }
    
    .search-container {
        grid-column: 3 / 7;
    }
    
    .navtolog {
        grid-column: 2 / 7;
    }
    
    .contacts {
        grid-column: 3 / 8;
        gap: 10px;
        font-size: 11px;
    }
    
    .nav-phone {
        z-index: 9999;
        display: grid;
        padding: 8px 15px;
    }
    
    .nav-phone .icon-container {
        width: 28px;
        height: 28px;
    }
    
    .nav-phone span {
        font-size: 11px;
    }
    
    .header-icons {
        display: none !important;
    }
}

/* Десктопная версия (от 1200px) */
@media (min-width: 1200px) {
    body {
        grid-template-columns: minmax(20px, 1fr) repeat(8, minmax(auto, 180px)) minmax(20px, 1fr);
    }
    
    .nav-phone, .navtolog-phone {
        display: none;
    }
}

/* Шрифты */
@font-face {
    font-family: Roboto;
    src: url(../fonts/JetBrainsSans[wght]-VF.ttf);
}

* {
    font-family: Roboto;
    box-sizing: border-box;
}

/* Футер */
.site-footer {
    flex-shrink: 0;
    background: #f5f5f5;
    padding: 20px 0;
    margin-top: 40px;
    width: 100%;
}

@media (max-width: 768px) {
    .site-footer {
        padding: 15px 0;
    }
}

.search-title-dropdown {
    width: 100% !important;
    max-height: 70vh !important;
    overflow-y: auto !important;
    border: 1px solid #FFBF04 !important;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1) !important;
}

.search-item-image {
    width: 50px !important;
    height: 50px !important;
    object-fit: contain !important;
    margin-right: 10px !important;
}

.search-item-all {
    padding: 10px !important;
    font-weight: bold !important;
    background: #f8f8f8 !important;
}

.search-item-history {
    color: #666 !important;
    font-style: italic !important;
    padding-left: 20px !important;
}

.search-title-input {
    padding-right: 40px !important;
    background-image: none !important;
}

.search-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.search-form {
    display: flex;
    margin-bottom: 30px;
}

.search-input {
    flex-grow: 1;
    padding: 12px 15px;
    border: 2px solid #FFBF04;
    border-radius: 4px 0 0 4px;
    font-size: 16px;
    outline: none;
}

.search-button {
    padding: 12px 20px;
    background-color: #FFBF04;
    color: #000;
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
}

.search-button:hover {
    background-color: #FFA500;
}

.search-results {
    margin-top: 20px;
}

.search-item {
    margin-bottom: 25px;
    padding-bottom: 25px;
    border-bottom: 1px solid #eee;
}

.search-item-title {
    color: #0066cc;
    font-size: 18px;
    font-weight: bold;
    text-decoration: none;
    display: block;
    margin-bottom: 5px;
}

.search-item-title:hover {
    text-decoration: underline;
}

.search-item-text {
    color: #333;
    margin-bottom: 5px;
}

.search-item-section {
    color: #666;
    font-size: 14px;
}

.search-no-results {
    color: #666;
    font-size: 16px;
    text-align: center;
    padding: 40px 0;
}

.header-icons {
    grid-column: 8 / 9;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 15px;
    height: 40px;
    margin-left: 0;
}

.header-icon {
    position: relative;
    display: flex;
    align-items: center;
    color: #333;
    text-decoration: none;
    font-size: 20px;
    transition: color 0.3s;
}

.header-icon:hover {
    color: #FFBF04;
}

.cart-info {
    margin-left: 5px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    line-height: 1.2;
}

.cart-count {
    background-color: #FFBF04;
    color: #000;
    border-radius: 10px;
    padding: 0 5px;
    font-size: 12px;
    font-weight: bold;
    min-width: 18px;
    text-align: center;
    display: inline-block;
}

.cart-total {
    font-size: 14px;
    color: #333;
    white-space: nowrap;
}

/* Стили для профиля */
.profile-wrapper {
    position: relative;
}

.profile-trigger {
    cursor: pointer;
    position: relative;
    display: flex;
    align-items: center;
}

.profile-trigger i {
    font-size: 24px;
    color: #333;
    transition: color 0.3s;
}

.profile-trigger:hover i {
    color: #FFBF04;
}

.profile-popover {
    position: absolute;
    top: 100%;
    right: 0;
    width: 250px;
    background: #fff;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border-radius: 5px;
    padding: 15px;
    z-index: 1000;
    display: none;
    margin-top: 10px;
}

.profile-trigger:hover .profile-popover {
    display: block;
}

.profile-popover:before {
    content: '';
    position: absolute;
    bottom: 100%;
    right: 15px;
    border-width: 8px;
    border-style: solid;
    border-color: transparent transparent #fff transparent;
}

.profile-header {
    padding-bottom: 10px;
    margin-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.profile-header span {
    display: block;
}

.profile-email {
    font-size: 12px;
    color: #666;
}

.profile-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.profile-menu li {
    margin-bottom: 8px;
}

.profile-menu a {
    display: flex;
    align-items: center;
    color: #333;
    text-decoration: none;
    padding: 5px 0;
    transition: color 0.3s;
}

.profile-menu a:hover {
    color: #FFBF04;
}

.profile-menu i {
    margin-right: 10px;
    width: 20px;
    text-align: center;
}

.auth-link {
    color: #333;
    font-size: 24px;
    transition: color 0.3s;
}

.auth-link:hover {
    color: #FFBF04;
}

/* Стили для корзины с popover */
.cart-wrapper {
    position: relative;
}

/* Основные стили каталога */
.catalog-section {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    justify-content: center;
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.catalog-item {
    display: block;
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    position: relative;
}

.catalog-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

/* Стили для изображений товаров */
.catalog-item-image {
    width: 100%;
    height: 200px;
    object-fit: contain;
    padding: 15px;
    box-sizing: border-box;
}

.catalog-item-content {
    padding: 15px;
}

.catalog-item-title {
    font-size: 16px;
    margin: 0 0 10px;
    height: 40px;
    overflow: hidden;
    line-height: 1.3;
}

.catalog-item-price {
    font-weight: bold;
    font-size: 18px;
    color: #e74c3c;
    margin-bottom: 15px;
}

.catalog-item-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.catalog-item-buy-btn {
    background: #3498db;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s;
}

.catalog-item-buy-btn:hover {
    background: #2980b9;
}

/* Стили для горизонтального расположения товаров */
.product-detail-horizontal {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 20px !important;
    margin: 30px 0 !important;
    justify-content: center !important;
}

.product-item-horizontal {
    flex: 0 0 calc(33.333% - 20px) !important;
    box-sizing: border-box !important;
    border: 1px solid #e1e1e1 !important;
    padding: 15px !important;
    border-radius: 8px !important;
    transition: all 0.3s ease !important;
    background: #fff !important;
}

.product-item-horizontal:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1) !important;
    transform: translateY(-5px) !important;
}

.product-image-horizontal {
    width: 100% !important;
    height: 180px !important;
    object-fit: contain !important;
    margin-bottom: 15px !important;
}

.product-title-horizontal {
    font-size: 16px !important;
    margin-bottom: 10px !important;
    height: 40px !important;
    overflow: hidden !important;
    line-height: 1.3 !important;
}

.product-price-horizontal {
    font-weight: bold !important;
    font-size: 18px !important;
    color: #e74c3c !important;
    margin-bottom: 15px !important;
}

.product-actions-horizontal {
    display: flex !important;
    justify-content: space-between !important;
}

.buy-btn-horizontal {
    background: #3498db !important;
    color: white !important;
    border: none !important;
    padding: 8px 15px !important;
    border-radius: 4px !important;
    cursor: pointer !important;
    transition: background 0.3s !important;
}

.buy-btn-horizontal:hover {
    background: #2980b9 !important;
}

/* Дополнительные эффекты */
.catalog-item-badge {
    position: absolute !important;
    top: 10px !important;
    right: 10px !important;
    background: #e74c3c !important;
    color: white !important;
    padding: 3px 8px !important;
    border-radius: 12px !important;
    font-size: 12px !important;
    font-weight: bold !important;
}

.catalog-item-wishlist {
    background: none !important;
    border: none !important;
    color: #ccc !important;
    font-size: 20px !important;
    cursor: pointer !important;
    transition: color 0.3s !important;
}

.catalog-item-wishlist.active,
.catalog-item-wishlist:hover {
    color: #e74c3c !important;
}

.product-card {
    width: 227px;
    background-color: white;
    padding: 16px;
    box-sizing: border-box;
    margin: 10px;
    border: 1px solid #eaeaea;
}

.product-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
}

.friendly-prices {
    color: #FF3333;
    font-size: 12px;
    font-weight: bold;
}

.installation {
    color: #666666;
    font-size: 12px;
}

.product-code {
    color: #999999;
    font-size: 11px;
    margin-bottom: 12px;
}

.availability {
    color: #00B200;
    font-size: 12px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
}

.availability:before {
    content: "";
    display: inline-block;
    width: 6px;
    height: 6px;
    background-color: #00B200;
    border-radius: 50%;
    margin-right: 6px;
}

.product-title {
    font-size: 14px;
    color: #333333;
    margin-bottom: 16px;
    line-height: 1.4;
    height: 40px;
    overflow: hidden;
}

.price-label {
    color: #999999;
    font-size: 12px;
    margin-bottom: 4px;
}

.product-price {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 16px;
}

.quantity-controls {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
}

.quantity-btn {
    width: 30px;
    height: 30px;
    background-color: #f0f0f0;
    border: 1px solid #ddd;
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    user-select: none;
}

.quantity-btn:hover {
    background-color: #e0e0e0;
}

.quantity-input {
    width: 40px;
    height: 28px;
    text-align: center;
    border: 1px solid #ddd;
    border-left: none;
    border-right: none;
    font-size: 14px;
}

.add-to-cart {
    width: 100%;
    background-color: #FFCC33;
    color: black;
    border: none;
    padding: 10px 0;
    border-radius: 4px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s;
}

.add-to-cart:hover {
    background-color: #FFD700;
}

.add-to-cart[disabled] {
    background-color: #cccccc;
    cursor: not-allowed;
}
.bx_sitemap{
    display: none !important;
}
#bx_incl_area_6_1{
    display: none !important;
}