* { box-sizing: border-box; margin: 0; padding: 0; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; }
body { background-color: #ffffff; color: #333; font-size: 14px; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

/* --- ШАПКА --- */
.header { border-bottom: 1px solid #e5e5e5; width: 100%; background: #fff; }
.header-main { display: flex; align-items: center; padding: 15px 20px; gap: 20px; max-width: 1300px; margin: 0 auto; }
.logo { display: flex; align-items: center; gap: 10px; }
.logo-text { font-size: 26px; font-weight: 900; letter-spacing: -0.5px; }
.header-contacts { display: flex; flex-direction: column; font-size: 13px; }
.header-contacts .city { display: flex; align-items: center; gap: 5px; }
.header-contacts .phone { font-weight: bold; font-size: 14px; margin-top: 2px; }
.header-top-menu { display: flex; gap: 15px; font-size: 13px; margin-left: auto; }
.header-top-menu a:hover { color: var(--site-color); }

.header-bottom { display: flex; align-items: center; gap: 20px; padding: 0 20px 15px; max-width: 1300px; margin: 0 auto; }
.catalog-btn { border: 1px solid var(--site-color); color: var(--site-color); padding: 10px 20px; border-radius: 8px; font-weight: bold; display: flex; align-items: center; gap: 10px; }
.catalog-btn svg { width: 18px; height: 18px; }
.search-bar { flex-grow: 1; position: relative; }
.search-bar input { width: 100%; padding: 12px 20px 12px 45px; border: 1px solid #e5e5e5; border-radius: 30px; font-size: 14px; background: #f9f9f9; outline: none; }
.search-bar svg { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; fill: #999; }
.header-actions { display: flex; gap: 20px; font-size: 12px; }
.action-item { display: flex; flex-direction: column; align-items: center; gap: 4px; color: #666; position: relative; background: none; border: none; }
.action-item:hover { color: var(--site-color); }
.action-item svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.cart-badge { position: absolute; top: -5px; right: -5px; color: white; font-size: 10px; font-weight: bold; padding: 2px 6px; border-radius: 10px; }

/* --- КОНТЕНТ --- */
.container { max-width: 1300px; margin: 0 auto; padding: 0 20px; }
.breadcrumbs { font-size: 12px; color: #888; margin: 20px 0 10px; }
.page-title { font-size: 28px; font-weight: bold; margin-bottom: 20px; display: flex; align-items: baseline; gap: 10px; }
.page-title span { font-size: 18px; color: #888; font-weight: normal; }
.layout { display: flex; gap: 30px; align-items: flex-start; margin-bottom: 40px; }

/* --- САЙДБАР --- */
.sidebar { width: 280px; flex-shrink: 0; }
.filters-block { background: #f4f4f4; border-radius: 12px; padding: 20px; }
.filter-header { font-weight: bold; font-size: 18px; margin-bottom: 20px; }
.filter-group { margin-bottom: 20px; }
.filter-input { width: 100%; padding: 10px; border: none; border-radius: 6px; font-size: 14px; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,0.05); outline: none; }

/* --- ТОВАРЫ --- */
.products-area { flex-grow: 1; min-width: 0; }
.sort-panel { display: flex; justify-content: space-between; margin-bottom: 20px; }
.sort-list { display: flex; gap: 15px; color: #888; font-size: 13px; }
.sort-list span.active { color: #000; border-bottom: 1px dashed #000; }
.products-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }

.product-card { border: 1px solid #e5e5e5; border-radius: 8px; padding: 15px; display: flex; flex-direction: column; transition: box-shadow 0.2s; background: #fff; }
.product-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.1); }
.product-img-wrapper { height: 180px; display: flex; justify-content: center; align-items: center; margin-bottom: 15px; background: #f8f8f8; border-radius: 8px; overflow: hidden; }
.product-img { max-width: 100%; max-height: 100%; object-fit: contain; }
.price-row { display: flex; align-items: center; gap: 10px; margin-bottom: 5px; color: var(--site-color); font-size: 12px; font-weight: bold; }
.current-price { font-size: 22px; font-weight: bold; margin-bottom: 10px; }
.product-title { font-size: 14px; margin-bottom: 15px; flex-grow: 1; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.btn-add-cart { width: 100%; color: white; padding: 12px; border-radius: 4px; font-weight: bold; font-size: 14px; display: flex; justify-content: center; align-items: center; gap: 8px; }
.btn-add-cart svg { width: 16px; height: 16px; fill: currentColor; }

/* --- ПОДВАЛ --- */
.footer { border-top: 1px solid #e5e5e5; margin-top: 50px; padding: 30px 0; }
.footer-links { display: flex; gap: 30px; padding-bottom: 30px; border-bottom: 1px solid #e5e5e5; }
.footer-col { flex: 1; }
.footer-col h4 { font-size: 16px; margin-bottom: 15px; }
.footer-col ul li { margin-bottom: 10px; }
.footer-col ul li a { color: #666; font-size: 13px; }
.footer-col ul li a:hover { color: #000; text-decoration: underline; }
.footer-contacts .phone { font-size: 16px; font-weight: bold; margin-bottom: 15px; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 25px; }
.footer-payments { display: flex; gap: 20px; }
.footer-legal { padding-top: 20px; font-size: 12px; color: #888; }

/* --- АДАПТИВНОСТЬ --- */
@media (max-width: 1024px) { .products-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 900px) {
    .header-top-menu, .header-contacts { display: none; }
    .sidebar { display: none; }
    .products-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .product-card { padding: 10px; }
    .product-img-wrapper { height: 140px; }
    .product-title { font-size: 12px; }
    .current-price { font-size: 18px; }
    .footer-links { display: grid; grid-template-columns: 1fr 1fr; }
}
