* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}
a { 
    text-decoration: none; /* Отменяем подчеркивание у ссылки */
   } 

body {
    background-color: #f9f5f0;
    color: #333;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Верхняя часть */
.header {
    background: linear-gradient(135deg, #9f0400 0%, #600b04 100%);
    color: white;
    padding: 0.5rem 1rem;
    box-shadow: 0 4px 12px rgba(139, 69, 19, 0.2);
    position: relative;
    z-index: 10;
}
#nado{
	width: 100%;
    height: 10px;
    background-color: #f9f5f0;
	}
.header-content {
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    flex-wrap: wrap;
}

.logo-left h1 {
	font-size: calc(25px + 16 * (100vw / 1280));
    color: #ffff00;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
	text-align: center;
}

.logo-center {
    flex-grow: 1;
    text-align: center;
}

.logo-img {
    height: 80px;
    width: auto;
    filter: drop-shadow(0 0 8px rgba(255, 215, 0, 0.5));
    transition: transform 0.3s ease;
	position:absolute;
top:6%;
right:6%;
}
.logo-img:hover {
    transform: scale(1.1);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.cart-icon-container {
    position: relative;
}

.cart-link {
    color: white;
    font-size: 1.5rem;
    text-decoration: none;
    position: relative;
    transition: color 0.3s ease;
}

.cart-link:hover {
    color: #FFD700;
}

.cart-count {
    position: absolute;
    top: -10px;
    right: -10px;
    background: #FFD700;
    color: #8B4513;
    border-radius: 50%;
    width: 22px;
    height: 22px;
    font-size: 0.8rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
}
.inp {
  width: 100%;
  height:50px;
}

.back-to-shop {
    color: white;
    text-decoration: none;
    font-size: 0.9rem;
    padding: 8px 15px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    transition: all 0.3s ease;
}

.back-to-shop:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #FFD700;
}

/* Основная часть */
.main {
    flex: 1;
    padding: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
}

.container {
    width: 100%;
}

.section-title {
    text-align: center;
    margin-bottom: 2rem;
    color: #dd0601;
    font-size: 2.2rem;
    position: relative;
    padding-bottom: 10px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 85%;
    height: 3px;
    background: linear-gradient(135deg, #ff0a04 0%, #ffff00 100%);
}

/* Карточки товаров */
.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.product-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 12px 25px rgba(139, 69, 19, 0.2);
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-bottom: 2px solid #f0e6d6;
}

.product-info {
    padding: 0.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0rem;
    color: #5D4037;
    flex-grow: 1;
}

.product-price {
    font-size: 1.3rem;
    font-weight: 700;
    color: #8B4513;
    margin-bottom: 1rem;
}

.product-actions {
    display: flex;
    gap: 10px;
    margin-top: auto;
}

.btn-details {
    flex: 1;
    padding: 8px 15px;
    background: #FFD700;
    color: #dd0601;
    text-decoration: none;
    border-radius: 4px;
    text-align: center;
    font-size: 0.9rem;
    transition: background 0.3s ease;
}

.btn-details:hover {
    background: #FFC107;
}

.btn-add-to-cart {
    flex: 1;
    padding: 8px 15px;
    background: #FFD700;
    color: #8B4513;
    border: none;
    border-radius: 4px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    font-weight: 600;
}

.btn-add-to-cart:hover {
    background: #FFC107;
    transform: scale(1.05);
}

/* Страница товара */
.product-main {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    margin: 2rem auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.product-detail {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.product-gallery {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.main-image {
    width: 100%;
    border-radius: 10px;
    overflow: hidden;
    border: 2px solid #f0e6d6;
}

.main-image img {
    width: 100%;

    object-fit: cover;
    transition: transform 0.3s ease;
}

.main-image img:hover {
    transform: scale(1.02);
}

.thumbnail-images {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.thumbnail {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 5px;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.3s ease;
}

.thumbnail:hover,
.thumbnail.active {
    border-color: #8B4513;
    transform: scale(1.05);
}

.product-info-detail {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.product-title-detail {
    font-size: 2.2rem;
    color: #5D4037;
    margin-bottom: 0.5rem;
}

.product-price-detail {
    font-size: 2rem;
    color: #8B4513;
    font-weight: 700;
    margin-bottom: 1rem;
}

.product-description {
    background: #f9f5f0;
    padding: 1.5rem;
    border-radius: 10px;
    border-left: 4px solid #8B4513;
}

.product-description h3 {
    color: #5D4037;
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.product-description p {
    line-height: 1.8;
    color: #666;
}

.product-actions-detail {
    display: flex;
    gap: 15px;
    margin-top: 1rem;
}

.btn-add-to-cart-detail {
    flex: 1;
    padding: 15px 25px;
    background: #9f0400;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-add-to-cart-detail:hover {
    background: #A0522D;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(139, 69, 19, 0.3);
}

.btn-go-to-cart {
    flex: 1;
    padding: 15px 25px;
    background: #FFD700;
    color: #8B4513;
    text-decoration: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    text-align: center;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-go-to-cart:hover {
    background: #FFC107;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 193, 7, 0.3);
}

.product-features {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #eee;
}

.feature {
    display: flex;
    align-items: center;
    gap: 15px;
    color: #666;
    font-size: 1rem;
}

.feature i {
    color: #8B4513;
    font-size: 1.2rem;
}

/* Страница корзины */
.cart-main {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    margin: 2rem auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.empty-cart {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-cart i {
    font-size: 4rem;
    color: #ddd;
    margin-bottom: 1.5rem;
}

.empty-cart h3 {
    color: #666;
    margin-bottom: 1rem;
    font-size: 1.8rem;
}

.empty-cart p {
    color: #888;
    margin-bottom: 2rem;
}

.btn-continue-shopping {
    display: inline-block;
    padding: 12px 30px;
    background: #8B4513;
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-continue-shopping:hover {
    background: #A0522D;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(139, 69, 19, 0.3);
}

.cart-items {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.cart-item {
    display: grid;
    grid-template-columns: 100px 2fr 150px 150px 50px;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    background: #f9f5f0;
    border-radius: 10px;
    border: 1px solid #eee;
}

.cart-item-image img {
    width: 100%;
    height: 100px;
    object-fit: cover;
    border-radius: 5px;
}

.cart-item-info h3 {
    color: #5D4037;
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.cart-item-price {
    color: #8B4513;
    font-weight: 600;
    font-size: 1.1rem;
}

.quantity-input {
    width: 70px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-align: center;
    font-size: 1rem;
}

.cart-item-total {
    font-weight: 700;
    color: #8B4513;
    font-size: 1.2rem;
}

.remove-btn {
    color: #dc3545;
    text-decoration: none;
    font-size: 1.2rem;
    transition: color 0.3s ease;
}

.remove-btn:hover {
    color: #c82333;
}

.cart-summary {
    background: #f9f5f0;
    padding: 2rem;
    border-radius: 10px;
    border: 1px solid #eee;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
}

.total-price {
    font-weight: 700;
    color: #8B4513;
    font-size: 1.8rem;
}

.summary-actions {
    display: flex;
    gap: 15px;
    margin-top: 2rem;
}

.btn-update-cart {
    flex: 1;
    padding: 15px 25px;
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-update-cart:hover {
    background: #5a6268;
    transform: translateY(-2px);
}

.btn-checkout {
    flex: 1;
    padding: 15px 25px;
    background: #28a745;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-checkout:hover {
    background: #218838;
    transform: translateY(-2px);
}

.continue-shopping {
    text-align: center;
    margin-top: 2rem;
}

/* Модальное окно */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: white;
    margin: 15% auto;
    padding: 0.5rem;
    border-radius: 10px;
    width: 94%;
    max-width: 400px;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.close-modal {
    position: absolute;
    right: 15px;
    top: 10px;
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close-modal:hover {
    color: #000;
}

/* Нижняя часть */
.footer {
    background: linear-gradient(135deg, #600b04 0%, #9f0400 100%);
    color: white;
    padding: 0.5rem 1rem 1rem;
    margin-top: auto;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto 2rem;
}

.footer-section h3 {
    font-size: 1.3rem;
    margin-bottom: 1.2rem;
    color: #FFD700;
    position: relative;
    padding-bottom: 8px;
}

.footer-section h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: #FFD700;
}

.footer-section p {
    margin-bottom: 0.7rem;
    display: flex;
    align-items: center;
}

.footer-section i {
    margin-right: 10px;
    color: #FFD700;
}

.social-icons {
    display: flex;
    gap: 1rem;
}

.social-icons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.social-icons a:hover {
    background: #FFD700;
    color: #8B4513;
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
	color: #ffff00;
}

/* Адаптивность */
@media (max-width: 1200px) {
    .product-detail {
        grid-template-columns: 1fr;
    }
    
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .cart-item {
        grid-template-columns: 80px 1fr;
        grid-template-rows: auto auto auto;
    }
    
    .cart-item-image {
        grid-row: 1;
        grid-column: 1;
    }
    
    .cart-item-info {
        grid-row: 1;
        grid-column: 2;
    }
    
    .cart-item-quantity {
        grid-row: 2;
        grid-column: 1 / span 2;
    }
    
    .cart-item-total {
        grid-row: 3;
        grid-column: 1;
    }
    
    .cart-item-remove {
        grid-row: 3;
        grid-column: 2;
        text-align: right;
    }
}

@media (max-width: 992px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }
}

@media (max-width: 768px) {
.cart-icon-container{display:none;}
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .product-actions-detail {
        flex-direction: column;
    }
    
    .summary-actions {
        flex-direction: column;
    }
    
    .header-right {
        flex-direction: column;
        gap: 10px;
        width: 100%;
    }
    
    .back-to-shop {
        width: 100%;
        text-align: center;
    }
}

@media (max-width: 576px) {
	.cart-icon-container{display:none;}
    .footer-content {
        grid-template-columns: 1fr;
    }
    
    .header, .main, .cart-main, .product-main {
        padding: 1rem;
    }
    
    .logo-left h1 {
        font-size: 1.5rem;
    }
    
    .logo-img {
        display:none;
    }
    
    .section-title {
        font-size: 1rem;
    }
    .product-title-detail {
    font-size: 1.5rem;
    }
}