/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f9f9f9;
}

/* Header */
header {
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: #333;
}

nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin-left: 2rem;
}

nav ul li a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
}

/* Main content */
main {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 2rem;
}

.product-container {
    display: flex;
    gap: 2rem;
    background-color: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.product-image {
    flex: 1;
}

.product-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.thumbnail-images {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}

.thumbnail-images img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    cursor: pointer;
    border: 2px solid transparent;
    transition: border-color 0.3s;
}

.thumbnail-images img:hover,
.thumbnail-images img.active {
    border-color: #3498db;
}

.product-details {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-details h1 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: #333;
}

.price {
    font-size: 1.5rem;
    font-weight: bold;
    color: #e74c3c;
    margin-bottom: 1rem;
}

.description {
    margin-bottom: 1.5rem;
    color: #666;
}

.options {
    margin-bottom: 1rem;
}

.options label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.options select {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
}

.add-to-cart {
    background-color: #3498db;
    color: #fff;
    border: none;
    padding: 1rem 2rem;
    font-size: 1rem;
    border-radius: 4px;
    cursor: pointer;
    margin-bottom: 2rem;
    transition: background-color 0.3s;
}

.add-to-cart:hover {
    background-color: #2980b9;
}

.additional-info h3 {
    margin-bottom: 1rem;
    color: #333;
}

.additional-info ul {
    list-style: none;
}

.additional-info ul li {
    margin-bottom: 0.5rem;
    color: #666;
}

/* Footer */
footer {
    background-color: #333;
    color: #fff;
    text-align: center;
    padding: 1rem;
    margin-top: 2rem;
}

/* Бейдж "ХИТ ПРОДАЖ" */
.product-badge {
    display: inline-block;
    background: linear-gradient(135deg, #ff6b35, #f7931e);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: bold;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Детали продукта под изображением */
.product-details-sidebar {
    margin-top: 2rem;
    padding: 1.5rem;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
}

.product-details-sidebar h3 {
    margin: 0 0 1rem 0;
    color: #333;
    font-size: 1.2rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.product-details-sidebar ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.product-details-sidebar li {
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #555;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.product-details-sidebar li:hover {
    background: rgba(0, 123, 255, 0.05);
    padding-left: 0.5rem;
    border-radius: 8px;
    color: #007bff;
}

.product-details-sidebar li:last-child {
    border-bottom: none;
}

/* Палитра цветов */
.color-palette {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin-top: 0.5rem;
}

.color-option {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    border: 3px solid transparent;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.color-option:hover {
    transform: scale(1.2);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.color-option.active {
    border-color: #333;
    transform: scale(1.1);
}

/* Информация о платежах и доставке */
.payment-delivery-info {
    margin-top: 2rem;
    padding: 1.5rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.info-section {
    margin-bottom: 2rem;
}

.info-section:last-child {
    margin-bottom: 0;
}

.info-section h4 {
    margin: 0 0 1rem 0;
    color: #333;
    font-size: 1.1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.payment-methods {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.payment-method {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.payment-method:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.payment-method img {
    filter: grayscale(100%);
    transition: filter 0.3s ease;
}

.payment-method:hover img {
    filter: grayscale(0%);
}

.delivery-info, .guarantees {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.delivery-item, .guarantee-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.delivery-item:hover, .guarantee-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.delivery-item .icon, .guarantee-item .icon {
    font-size: 1.5rem;
    width: 40px;
    text-align: center;
}

.delivery-item strong, .guarantee-item strong {
    display: block;
    color: #333;
    margin-bottom: 0.25rem;
}

.delivery-item p, .guarantee-item p {
    margin: 0;
    color: #666;
    font-size: 0.9rem;
}

/* Responsive design */
@media (max-width: 768px) {
    .product-container {
        flex-direction: column;
    }

    nav {
        flex-direction: column;
        padding: 1rem;
    }

    nav ul {
        margin-top: 1rem;
    }

    nav ul li {
        margin-left: 0;
        margin-right: 1rem;
    }

    .thumbnail-container {
        justify-content: center;
        gap: 0.5rem;
    }

    .thumbnail {
        width: 60px;
        height: 60px;
    }

    .payment-delivery-info {
        padding: 1rem;
    }

    .payment-methods {
        gap: 0.5rem;
    }

    .payment-method {
        padding: 0.5rem 0.75rem;
        font-size: 0.9rem;
    }

    .delivery-item, .guarantee-item {
        padding: 0.75rem;
        gap: 0.75rem;
    }
}

@media (max-width: 480px) {
    main {
        padding: 0 1rem;
    }

    .product-container {
        padding: 1rem;
    }

    .product-details h1 {
        font-size: 1.5rem;
    }

    .price {
        font-size: 1.25rem;
    }

    .add-to-cart {
        padding: 0.75rem 1.5rem;
        font-size: 0.9rem;
    }

    .payment-methods {
        flex-direction: column;
        align-items: stretch;
    }

    .payment-method {
        justify-content: center;
    }

    .delivery-info, .guarantees {
        gap: 0.5rem;
    }
}