/* ============================================================================
СТРАНИЦА ТОВАРА
============================================================================ */
.product-detail {
    text-align: left;
}

.product-breadcrumb {
    margin-bottom: 20px;
    font-size: 14px;
    color: #666;
}

.product-breadcrumb a {
    color: #555555;
    text-decoration: none;
}

.product-breadcrumb a:hover {
    text-decoration: underline;
}

.product-breadcrumb span {
    color: #999;
}

.product-main {
    display: flex;
    gap: 30px;
    margin-bottom: 40px;
}

.product-gallery {
    flex: 0 0 500px;
}

.carousel-container {
    position: relative;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    overflow: hidden;
    background: #fff;
}

.carousel-slides {
    position: relative;
    height: 500px;
}

.carousel-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-slide.active {
    opacity: 1;
}

.carousel-slide img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    padding: 10px 15px;
    cursor: pointer;
    font-size: 18px;
    z-index: 10;
    transition: background 0.3s;
}

.carousel-btn:hover {
    background: rgba(0, 0, 0, 0.8);
}

.carousel-btn.prev {
    left: 10px;
}

.carousel-btn.next {
    right: 10px;
}

.carousel-indicators {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 10;
}

.indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background 0.3s;
}

.indicator.active {
    background: white;
}

.indicator:hover {
    background: rgba(255, 255, 255, 0.8);
}

.no-image {
    height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f5;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
}

.no-image img {
    opacity: 0.5;
}

.product-info-block {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.product-short-info {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 4px;
}

.product-code-detail {
    font-size: 14px;
    color: #666;
    margin-bottom: 10px;
}

.product-original-name {
    font-size: 14px;
    color: #666;
    margin-bottom: 15px;
    font-style: italic;
}

.product-price-block {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 2px solid #e0e0e0;
}

.product-price-detail {
    font-size: 28px;
    font-weight: bold;
    color: #333;
    margin-right: 10px;
}

.product-unit-detail {
    font-size: 14px;
    color: #666;
}

.product-specs {
    margin-top: 15px;
}

.spec-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #e0e0e0;
}

.spec-row:last-child {
    border-bottom: none;
}

.spec-label {
    font-weight: bold;
    color: #555;
}

.spec-value {
    color: #333;
}

.product-cart-block {
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 4px;
    padding: 20px;
}

.cart-info {
    background: #e3f2fd;
    padding: 10px 15px;
    border-radius: 4px;
    margin-bottom: 15px;
    color: #1976d2;
}

.add-to-cart-section {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.quantity-selector {
    display: flex;
    align-items: center;
    gap: 15px;
}

.quantity-selector label {
    font-weight: bold;
    color: #333;
}

.quantity-control {
    display: flex;
    align-items: center;
    border: 1px solid #ccc;
    border-radius: 4px;
    overflow: hidden;
}

.qty-btn {
    width: 40px;
    height: 40px;
    border: none;
    background: #f5f5f5;
    color: #333;
    cursor: pointer;
    font-size: 20px;
    font-weight: bold;
    transition: background 0.2s;
}

.qty-btn:hover {
    background: #e0e0e0;
}

.qty-input {
    width: 80px;
    height: 40px;
    border: none;
    border-left: 1px solid #ccc;
    border-right: 1px solid #ccc;
    text-align: center;
    font-size: 16px;
    font-weight: bold;
    -moz-appearance: textfield;
}

.qty-input::-webkit-outer-spin-button,
.qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.btn-add-cart {
    padding: 15px 30px;
    background-color: #555555;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: background-color 0.2s;
}

.btn-add-cart:hover {
    background-color: #777777;
}

.product-description {
    background: #fff;
    padding: 30px;
    border-radius: 4px;
    border: 1px solid #e0e0e0;
}

.product-description h2 {
    margin-top: 0;
    margin-bottom: 20px;
    color: #333;
    font-size: 1.4em;
    border-bottom: 2px solid #555555;
    padding-bottom: 10px;
}

.description-content {
    line-height: 1.8;
    color: #555;
    white-space: pre-wrap;
}

@media screen and (max-width: 1024px) {
    .product-main {
        flex-direction: column;
    }
    
    .product-gallery {
        flex: none;
        width: 100%;
    }
    
    .carousel-slides {
        height: 400px;
    }
    
    .no-image {
        height: 400px;
    }
}

@media screen and (max-width: 768px) {
    .carousel-slides {
        height: 300px;
    }
    
    .no-image {
        height: 300px;
    }
    
    .product-price-detail {
        font-size: 24px;
    }
    
    .quantity-selector {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .btn-add-cart {
        width: 100%;
    }
}

.cart-info-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

.btn-remove-cart {
    padding: 6px 12px;
    background-color: #f8f9fa;
    color: #dc3545;
    border: 1px solid #dc3545;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s;
    white-space: nowrap;
}

.btn-remove-cart:hover {
    background-color: #dc3545;
    color: #ffffff;
}

.btn-remove-cart:disabled {
    background-color: #e9ecef;
    color: #999;
    border-color: #ccc;
    cursor: not-allowed;
}
