/* Product - Modern Layout inspired by Altex */

.product {
    margin: 0 auto;
    background: #fff;
}

/* Box styling for breadcrumb in product */
.product-breadcrumb-box {
    margin-bottom: 15px;
    background: transparent;
    border: none;
    padding: 0;
}

.product-breadcrumb {
    padding: 10px 0;
    background: transparent;
    border: none;
    font-size: 14px;
    color: #666;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 10px;
    position: relative;
}


.product-edit {
    margin-left: auto;
    position: absolute;
    right: 0;
}
.box.related-category-products .product-grid .product{
    margin: 0 2px 0 2px;
};

.product-edit a {
    color: #fff !important;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 12px;
    text-decoration: none;
    display: inline-block;
    transition: background 0.3s;
}

.product-edit a:hover {
    text-decoration: none;
}

/* Mini Header - Title Only */
.product-header {
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e0e0e0;
}

.product-header .product-title {
    font-size: 28px;
    font-weight: 600;
    color: #333;
    margin-bottom: 0;
    line-height: 1.3;
}

/* First Row - 2 Columns Layout */
.product-row-1 {
    display: flex;
    gap: 30px;
    margin-bottom: 5px;
    flex-wrap: wrap;
}

/* Left Column - Images */
.product-images {
    flex: 0 0 55%;
    min-width: 350px;
}

.product-main-image {
    border: 1px solid #e0e0e0;
    border-radius: 0.2rem;
    padding: 5px;
    background: #fff;
    margin-bottom: 15px;
    text-align: center;
}

.product-main-image img {
    
    max-width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}

.product-thumbnails {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    min-height: 0;
}

/* Hide thumbnails container when empty (only hidden main image) */
.product-thumbnails-empty {
    display: none;
}

.product-thumbnails a {
    border: 2px solid #e0e0e0;
        border-radius: 0.2rem;
    padding: 5px;
    display: inline-block;
    transition: border-color 0.3s;
    position: relative;
}

.product-thumbnails a:hover {
    border-color: #da0000;
}

.product-thumbnails img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    display: block;
}

/* Video thumbnail with play icon */
.product-video-thumbnail {
    position: relative;
}

.product-video-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 70px !important;
    height: 45px !important;
    z-index: 10;
    pointer-events: none;
    opacity: 0.9;
    transition: opacity 0.3s, transform 0.3s;
}

.product-video-thumbnail:hover .product-video-play-icon {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.1);
}

/* Right Column - Product Info */
.product-info {
    flex: 0 0 40%;
    min-width: 280px;
    max-width: 450px;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    font-size: 14px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e0e0e0;
}

.product-rating .rating-row {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #333;
}
.product-rating .rating-row .stars {
    position: relative;
    display: inline-block;
    font-size: 20px;
    line-height: 1;
    letter-spacing: 2px;
    color: #d9d9d9;
}
.product-rating .rating-row .stars::before { content: '\2605\2605\2605\2605\2605'; }
.product-rating .rating-row .stars-fill {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    overflow: hidden;
    color: #f5a623;
    white-space: nowrap;
}
.product-rating .rating-row .stars-fill::before { content: '\2605\2605\2605\2605\2605'; }
.product-rating .rating-row .rating-value { font-weight: 600; color: #333; }
.product-rating .rating-row .rating-count { color: #555; }

.product-rating a {
    color: #da0000;
    text-decoration: none;
    margin-left: 5px;
}

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

.product-price-section {
    margin-bottom: 25px;
}

.product-price-wrapper {
    margin-bottom: 15px;
}

.product-price-row {
    display: flex;
    align-items: baseline;
    gap: 15px;
    margin-bottom: 5px;
}

.product-price-row-top {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.product-price-row-bottom {
    display: flex;
    align-items: baseline;
    gap: 5px;
}

.product-price {
    font-size: 36px;
    font-weight: 700;
    color: #da0000;
    line-height: 1.2;
}

.product-old-price {
    font-size: 20px;
    color: #333;
    text-decoration: line-through;
    font-weight: 400;
}

.product-discount-badge {
    display: inline-block;
    background: #ffc107;
    color: #000;
    font-size: 14px;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 4px;
    line-height: 1.2;
}

.product-new-price {
    font-size: 36px;
    font-weight: 700;
    color: #da0000;
    line-height: 1.2;
}

.product-currency {
    font-size: 24px;
    font-weight: 400;
    color: #da0000;
    line-height: 1.2;
}

.product-weee-tax {
    font-size: 13px;
    color: #555;
    margin-top: 6px;
    font-style: italic;
}

.product-unit-price {
    font-size: 14px;
    color: #666;
    margin-top: 5px;
}

.product-stock-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 15px;
}

.product-stock-icon {
    font-size: 16px;
    line-height: 1;
}

.product-stock-icon.in-stock {
    color: #28a745;
}

.product-stock-icon.out-of-stock {
    color: #dc3545;
}

.product-stock-text {
    font-size: 14px;
    font-weight: 500;
}

.product-stock-text.in-stock {
    color: #28a745;
}

.product-stock-text.out-of-stock {
    color: #dc3545;
}

/* Product Code */
.product-code {
    margin-bottom: 20px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 6px;
    font-size: 14px;
    color: #333;
}

.product-code strong {
    color: #555;
    margin-right: 5px;
}

.product-badges {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.product-badge {
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.product-badge.new {
    background: #da0000;
    color: #fff;
}

.product-badge.discount {
    background: #ffc107;
    color: #000;
    font-weight: 700;
    border-radius: 6px;
}

.product-add-to-cart {
    margin-top: 25px;
}

.product-add-to-cart-button {
    width: 100%;
    padding: 13px 30px;
    background: #da0000;
    color: #fff;
    border: none;
    border-radius: 0.2rem;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    text-transform: uppercase;
    background: url('/img/cart-button-background.png') top left repeat-x;
}

.product-add-to-cart-button:hover {
    background: #b80000;
}

.product-add-to-cart-button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Delivery Information */
.product-delivery {
    margin: 20px 0;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 6px;
}

.product-delivery-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 12px;
    font-size: 14px;
    color: #333;
}

.product-delivery-item:last-child {
    margin-bottom: 0;
}

.product-delivery-icon {
    font-size: 18px;
    line-height: 1.4;
    flex-shrink: 0;
}

.product-delivery-text {
    line-height: 1.5;
}

/* Second Row - Specifications and Description */
.product-row-2 {
    margin-bottom: 40px;
}

.product-specs-section {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 0.2rem;
    padding: 20px;
    margin-bottom: 30px;
}

.product-specs-title {
    font-size: 20px;
    font-weight: 600;
    color: #333;
    margin-bottom: 15px;
    padding-bottom: 8px;
    border-bottom: 2px solid #da0000;
}

.product-specs-table {
    width: 100%;
    border-collapse: collapse;
}

.product-specs-table tr {
    border-bottom: none;
}

.product-specs-table tr:nth-child(even) {
    background: #f8f9fa;
}

.product-specs-table tr:nth-child(odd) {
    background: #fff;
}

.product-specs-table td {
    padding: 8px 12px;
    font-size: 14px;
    line-height: 1.4;
}

.product-specs-table td:first-child {
    font-weight: 600;
    color: #555;
    width: 180px;
}

.product-specs-table td:last-child {
    color: #333;
}

.product-description-section {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 0.2rem;
    padding: 25px;
}

.product-description-title {
    font-size: 22px;
    font-weight: 600;
    color: #333;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #da0000;
}

.product-description {
    font-size: 14px;
    line-height: 1.8;
    color: #555;
}

.product-description p {
    margin-bottom: 15px;
}

.product-description ul,
.product-description ol {
    margin-left: 20px;
    margin-bottom: 15px;
}

/* Link-uri in descrierea produsului — acelasi stil ca in corpul articolelor
   (vezi articles.css): rosu brand, semibold, subliniat; produs/categorie bold + sageata.
   :link/:visited explicit: globalul din stylesheet.css (a:link,a:visited{color:#333})
   are aceeasi specificitate ca ".product-description a" si vine mai tarziu in bundle,
   deci fara ele link-urile ies negre. */
.product-description a,
.product-description a:link,
.product-description a:visited {
    color: #cb0108;
    font-weight: 600;
    text-decoration: underline;
}
.product-description a:hover {
    color: #a00000;
}
.product-description a[href*="/product/"],
.product-description a[href*="/category/"] {
    font-weight: 700;
}
.product-description a[href*="/product/"]::after,
.product-description a[href*="/category/"]::after {
    content: " \203A";
    font-weight: 700;
    display: inline-block;
    font-size: 1.25em;
    line-height: 0;
    vertical-align: -0.08em;
    text-decoration: none;
}

/* Reviews Section */
.product-reviews {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid #e0e0e0;
}

/* Manufacturer Logo */
.product-manufacturer {
    margin-bottom: 5px;
    padding-bottom: 5px;

}

.product-manufacturer img {
    max-height: 60px;
    width: auto;
}

/* Related Products */
.product-related {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
}

.product-related-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 15px;
}

.product-related {
    margin-bottom: 20px;
}

.product-related .related_product {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    padding: 4px 8px;
    border: 1px solid #e0e0e07a;
    border-radius: 4px;
    background: #f8f9fa12;
    height: 40px;
    max-height: 40px;
    overflow: hidden;
    cursor: pointer;
    user-select: none;
}

.product-related .related_product:hover {
    background: #fff;
    border-color: #da000026;
}

.product-related .related_product img.product-image {
    width: 32px;
    height: 32px;
    object-fit: cover;
    border-radius: 4px;
    flex-shrink: 0;
}

.product-related .related_product a {
    display: inline;
    font-size: 13px;
    color: #333;
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 150px;
}

.product-related .related_product a:hover {
    color: #da0000;
    text-decoration: underline;
}

.product-related .related_product .product-price {
    margin-left: auto;
    font-size: 12px;
    color: #666;
    white-space: nowrap;
}
.product-breadcrumb {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    position: relative;
}

/* Responsive */
@media (max-width: 768px) {
    .product-header .product-title {
        font-size: 22px;
    }
    
    .product-row-1 {
        flex-direction: column;
    }
    
    .product-images,
    .product-info {
        flex: 1 1 100%;
    }
    
    .product-price {
        font-size: 28px;
    }
    
    .product-new-price {
        font-size: 28px;
    }
}
.pswp--custom-bg {
    background: #ffffff;
}

/* Wishlist toggle button */
.product-images {
    position: relative;
}

.wishlist-toggle {
    position: absolute;
    top: 15px;
    right: 15px;
    z-index: 100;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
    padding: 0;
}

.wishlist-toggle:hover {
    background: rgba(255, 255, 255, 1);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    transform: scale(1.08);
}

.wishlist-toggle:active {
    transform: scale(0.95);
}

.wishlist-toggle:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.wishlist-toggle .heart-icon {
    width: 26px;
    height: 26px;
    position: relative;
}

.wishlist-toggle .heart-outline {
    fill: none;
    stroke: #cb0108;
    stroke-width: 2;
    transition: all 0.3s ease;
}

.wishlist-toggle .heart-filled {
    fill: #cb0108;
    opacity: 0;
    transition: all 0.3s ease;
    position: absolute;
    top: 0;
    left: 0;
}

/* When product is in wishlist */
.wishlist-toggle.in-wishlist .heart-outline {
    opacity: 0;
}

.wishlist-toggle.in-wishlist .heart-filled {
    opacity: 1;
}

/* Animation on click */
@keyframes heartBeat {
    0%, 100% {
        transform: scale(1);
    }
    25% {
        transform: scale(1.3);
    }
    50% {
        transform: scale(1.15);
    }
}

.wishlist-toggle.animating .heart-icon {
    animation: heartBeat 0.5s ease;
}

/* Responsive adjustments for wishlist button */
@media (max-width: 768px) {
    .wishlist-toggle {
        width: 44px;
        height: 44px;
        top: 10px;
        right: 10px;
    }
    
    .wishlist-toggle .heart-icon {
        width: 24px;
        height: 24px;
    }
}