/* ==========================================================================
   PRODUCT DETAIL — RedParts Industrial Aesthetic
   Autoricambi Adriatica · 2026
   ========================================================================== */

/* ── Page Shell ── */
.product-page {
    background: #fff;
    padding-bottom: 3rem;
}

/* ── Full-width container (no sidebar) ── */
.product-page-container {
    max-width: 1380px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Layout with left sidebar (RedParts product-sidebar style) */
.product-layout {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 20px;
    align-items: start;
}

.product-layout__sidebar {
    position: sticky;
    top: 15px;
}

@media (max-width: 1199px) {
    .product-layout {
        grid-template-columns: 280px minmax(0, 1fr);
    }
}

@media (max-width: 991px) {
    .product-layout {
        grid-template-columns: 1fr;
    }

    .product-layout__sidebar {
        position: static;
        top: auto;
    }
}

/* ── Single main column (replaces catalogue-layout + catalogue-main) ── */
.pdp-main-col {
    width: 100%;
}

/* ==========================================================================
   Sidebar skin alignment with RedParts widgets (keep existing functionality)
   ========================================================================== */
.product-layout__sidebar .tech-sidebar {
    background: transparent;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.product-layout__sidebar .tech-sb-section {
    background: #fff;
    border: 1px solid #ebebeb;
    border-radius: 2px;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.product-layout__sidebar .tech-sb-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    padding: 14px 16px;
    border-bottom: 1px solid #ebebeb;
    background: #fff;
    color: #1a1a1a;
    text-transform: uppercase;
    letter-spacing: .03em;
    font-size: 13px;
    font-weight: 700;
}

.product-layout__sidebar .tech-sb-title i {
    color: var(--primary, #e02020);
}

.product-layout__sidebar .tech-sb-section > :not(.tech-sb-title) {
    padding: 14px 16px;
}

.product-layout__sidebar .tech-text-input,
.product-layout__sidebar .tech-select {
    border: 1px solid #e5e7eb;
    border-radius: 2px;
    background: #fff;
    color: #111827;
}

.product-layout__sidebar .tech-search-wrap {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 2px;
}

.product-layout__sidebar .tech-btn-submit {
    border-radius: 2px;
    background: var(--primary, #e02020);
    border: 1px solid var(--primary, #e02020);
}

.product-layout__sidebar .tech-btn-clear {
    border-radius: 2px;
}

.product-layout__sidebar .tech-cat-item {
    border-radius: 2px;
}

.product-layout__sidebar .tech-cat-item.active {
    background: var(--primary, #e02020);
    color: #fff;
}

/* ==========================================================================
   RedParts parity tune (detail page + sidebar)
   ========================================================================== */
.product-page {
    background: #fff;
}

.product-page-container {
    max-width: 1680px;
}

/* Desktop-only: sidebar + main layout — MUST be inside min-width to not override mobile collapse */
@media (min-width: 992px) {
    .product-layout {
        grid-template-columns: 320px minmax(0, 1fr);
        gap: 26px;
    }
}

.product-layout__sidebar .tech-sidebar {
    gap: 18px;
}

.product-layout__sidebar .tech-sb-section {
    border: 1px solid #e3e3e3;
    border-radius: 16px;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.02);
}

.product-layout__sidebar .tech-sb-title {
    padding: 18px 22px;
    font-size: 15px;
    font-weight: 800;
    letter-spacing: .02em;
    border-bottom: 1px solid #e7e7e7;
}

.product-layout__sidebar .tech-sb-section > :not(.tech-sb-title) {
    padding: 18px 20px;
}

.product-layout__sidebar .tech-cat-item {
    min-height: 54px;
    padding: 0 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-weight: 700;
    border: 1px solid #e4e4e4;
    background: #fff;
    border-radius: 8px;
}

.product-layout__sidebar .tech-cat-item.active {
    background: #ef1d24;
    border-color: #ef1d24;
    color: #fff;
}

.product-layout__sidebar .tech-cat-toggle-expand {
    width: 100%;
    min-height: 58px;
    border: 2px solid var(--primary);
    border-radius: 8px;
    background: #fff;
    color: #000000;
    text-transform: uppercase;
    box-shadow: inset 20px 0 20px -20px rgba(224, 32, 32, 0.3);
    letter-spacing: .06em;
    font-weight: 800;
}

.product-layout__sidebar .tech-search-wrap {
    min-height: 46px;
    border-radius: 6px;
}

.product-layout__sidebar .tech-btn-submit {
    min-height: 48px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 800;
}

.product-block {
    border: 1px solid #dfdfdf;
    box-shadow: none;
}

.product-block__inner {
    grid-template-columns: 260px minmax(0, 1fr) 500px;
}

.product-block__left {
    grid-template-columns: 260px minmax(0, 1fr);
}

.product-gallery {
    padding: 24px 20px;
    border-right: 1px solid #ebebeb;
}

.product-info {
    border-left: none;
    padding: 22px 28px;
}

.product-info__title {
    font-size: 20px;
    line-height: 1.25;
    font-weight: 600;
}

.product-sidebar-col {
    border-left: 1px solid #e7e7e7;
    background: #f8f8f8;
}

.product-purchase {
    padding: 22px;
}

.product-purchase__price {
    font-size: 28px;
    font-weight: 700;
    color: #ef1d24;
}

.product-purchase__actions {
    gap: 10px;
}

.product-purchase__qty {
    border-radius: 0;
}

.product-purchase__cart-btn {
    border-radius: 2px;
    font-size: 37px;
    font-size: 36px;
    font-size: 35px;
    font-size: 34px;
    font-size: 33px;
    font-size: 32px;
    font-size: 31px;
    font-size: 30px;
    font-size: 29px;
    font-size: 28px;
    font-size: 27px;
    font-size: 26px;
    font-size: 25px;
    font-size: 24px;
    font-size: 23px;
    font-size: 22px;
    font-size: 21px;
    font-size: 20px;
    font-size: 19px;
    font-size: 18px;
    font-size: 17px;
    font-size: 16px;
    font-size: 15px;
    font-size: 14px;
    font-size: 13px;
    font-weight: 800;
}

@media (min-width: 992px) and (max-width: 1400px) {
    .product-layout {
        grid-template-columns: 280px minmax(0, 1fr);
    }
}

@media (max-width: 1400px) {
    .product-block__inner {
        grid-template-columns: 230px minmax(0, 1fr) 420px;
    }
}

@media (max-width: 991px) {
    .product-block__inner,
    .product-block__left {
        grid-template-columns: 1fr;
    }

    .product-gallery {
        border-right: none;
        border-bottom: 1px solid #ebebeb;
    }

    .product-sidebar-col {
        border-left: none;
    }
}

/* ── Breadcrumb ── */
.product-breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 16px 0;
    font-size: 13px;
    color: #6b7280;
    flex-wrap: wrap;
}

.product-breadcrumb a {
    color: #6b7280;
    text-decoration: none;
    transition: color 0.2s;
}

.product-breadcrumb a:hover {
    color: var(--primary, #e02020);
}

.product-breadcrumb .bc-sep {
    color: #d1d5db;
    font-size: 10px;
}

.product-breadcrumb .bc-current {
    color: #111827;
    font-weight: 600;
}

/* ── Main Product Block ── */
.product-block {
    background: #fff;
    border-radius: 2px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    margin-bottom: 24px;
    overflow: hidden;
}

.product-block__inner {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
}

@media (min-width: 992px) {
    .product-block__inner {
        grid-template-columns: minmax(0, 1fr) 400px;
    }
}

/* ── Left Column: Gallery + Info ── */
.product-block__left {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
}

@media (min-width: 992px) {
    .product-block__left {
        grid-template-columns: minmax(0, 1fr) minmax(280px, 380px);
    }
}

/* ── Image Gallery ── */
.product-gallery {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.product-gallery__main {
    position: relative;
    aspect-ratio: 1 / 1;
    background: #fff;
    border-radius: 2px;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: center;
    overflow: hidden;
}

.product-gallery__zoom {
    position: relative;
    flex: 1;
    width: 100%;
    min-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    touch-action: pan-y pinch-zoom;
}

.product-gallery__zoom #product-main-lightbox-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    cursor: zoom-in;
}

.product-gallery__main img,
.product-gallery__zoom img {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
    transition: transform 0.15s ease-out;
    transform-origin: center center;
    will-change: transform;
}

.product-gallery__main.pg-lens-enabled .product-gallery__zoom img {
    transition: none;
}

.product-gallery__zoom.is-pinch-zoomed #product-main-lightbox-link {
    cursor: grab;
}

.product-gallery__lens {
    position: absolute;
    border: 2px solid rgba(220, 38, 38, 0.75);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.5) inset;
    pointer-events: none;
    z-index: 4;
    border-radius: 2px;
}

.product-gallery__magnifier {
    position: absolute;
    top: 0;
    right: 0;
    width: 46%;
    height: 100%;
    background: #fff;
    border-left: 1px solid #ebebeb;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    z-index: 3;
    transition: opacity 0.18s ease, visibility 0.18s ease;
}

.product-gallery__main.is-lens-active .product-gallery__magnifier {
    opacity: 1;
    visibility: visible;
}

.product-gallery__magnifier img {
    position: absolute;
    top: 0;
    left: 0;
    max-width: none;
    max-height: none;
    object-fit: cover;
    transform-origin: top left;
}

.product-gallery__hint {
    margin: 0;
    padding: 8px 4px 0;
    font-size: 0.72rem;
    color: #9ca3af;
    text-align: center;
    line-height: 1.3;
}

.product-gallery__hint i {
    margin-right: 4px;
    color: #dc2626;
}

.product-gallery__hint-desktop {
    display: none;
}

.product-gallery__hint-mobile {
    display: inline;
}

@media (min-width: 768px) {
    .product-gallery__hint-desktop {
        display: inline;
    }

    .product-gallery__hint-mobile {
        display: none;
    }

    .product-gallery__main.pg-lens-enabled.is-lens-active .product-gallery__zoom img {
        max-width: 52%;
        margin-right: auto;
        margin-left: 0;
        padding-left: 3%;
    }
}

/* Stock / Discount Badges on gallery */
.product-gallery__badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 5;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.badge--stock {
    background: #16a34a;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 2px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge--discount {
    background: var(--primary, #e02020);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 2px;
}

/* Thumbnail Strip */
.product-gallery__thumbs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: thin;
    padding-bottom: 4px;
}

.product-gallery__thumb {
    flex-shrink: 0;
    width: 70px;
    height: 70px;
    border: 2px solid #ebebeb;
    border-radius: 2px;
    background: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color 0.2s;
    overflow: hidden;
}

.product-gallery__thumb:hover,
.product-gallery__thumb.is-active {
    border-color: var(--primary, #e02020);
}

.product-gallery__thumb img {
    max-width: 85%;
    max-height: 85%;
    object-fit: contain;
}

/* ── Product Info Column ── */
.product-info {
    padding: 28px 28px 28px 24px;
    border-left: 1px solid #ebebeb;
    display: flex;
    flex-direction: column;
}

@media (max-width: 767px) {
    .product-info {
        border-left: none;
        border-top: 1px solid #ebebeb;
        padding: 24px;
    }
}

.product-info__title {
    font-size: 22px;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.3;
    margin: 0 0 12px 0;
    letter-spacing: -0.3px;
}

/* Rating row */
.product-info__rating {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid #ebebeb;
}

.product-info__stars {
    display: flex;
    gap: 2px;
}

.product-info__stars i {
    font-size: 13px;
    color: #fbbf24;
}

.product-info__stars i.empty {
    color: #d1d5db;
}

.product-info__review-count {
    font-size: 13px;
    color: #999;
    font-weight: 400;
}

/* Quick Specs List */
.product-info__quick-specs {
    list-style: none;
    margin: 0 0 16px 0;
    padding: 0;
}

.product-info__quick-specs li {
    display: flex;
    align-items: baseline;
    gap: 8px;
    font-size: 14px;
    color: #333;
    padding: 5px 0;
    line-height: 1.5;
}

.product-info__quick-specs li::before {
    content: '•';
    color: #d1d5db;
    font-weight: 700;
    flex-shrink: 0;
}

.product-info__quick-specs .qs-label {
    color: #999;
    font-weight: 400;
}

.product-info__quick-specs .qs-value {
    color: #333;
    font-weight: 500;
}

.product-info__see-full {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--primary, #e02020);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    margin-bottom: 20px;
    transition: gap 0.2s;
}

.product-info__see-full:hover {
    gap: 10px;
}

/* Meta tags (brand, category) */
.product-info__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 16px;
    padding-bottom: 14px;
    border-bottom: 1px solid #ebebeb;
}

.product-info__meta-tag {
    font-size: 12px;
    font-weight: 600;
    padding: 5px 12px;
    border: 1px solid #e5e7eb;
    border-radius: 2px;
    color: #555;
    background: #f9fafb;
    text-decoration: none;
    transition: all 0.2s;
}

.product-info__meta-tag:hover {
    border-color: var(--primary, #e02020);
    color: var(--primary, #e02020);
    background: #fff;
}

/* Social share links */
.product-info__share {
    display: flex;
    gap: 6px;
    margin-top: auto;
    padding-top: 14px;
}

.product-info__share-btn {
    font-size: 11px;
    font-weight: 700;
    padding: 5px 12px;
    border-radius: 2px;
    color: #fff;
    text-decoration: none;
    transition: opacity 0.2s;
}

.product-info__share-btn:hover {
    opacity: 0.85;
    color: #fff;
}

.product-info__share-btn.--fb { background: #3b5998; }
.product-info__share-btn.--tw { background: #1da1f2; }
.product-info__share-btn.--wa { background: #25d366; }

/* ── Right Sidebar Column (purchase + trust) ── */
.product-sidebar-col {
    border-left: 1px solid #ebebeb;
    display: flex;
    flex-direction: column;
}

@media (max-width: 991px) {
    .product-sidebar-col {
        border-left: none;
        border-top: 1px solid #ebebeb;
    }
}

/* Purchase Box */
.product-purchase {
    padding: 24px 12px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Price */
.product-purchase__price-row {
    display: flex;
    align-items: baseline;
    gap: 12px;
    flex-wrap: wrap;
}

.product-purchase__price {
    font-size: 30px;
    font-weight: 700;
    color: #1a1a1a;
    letter-spacing: -0.5px;
    line-height: 1;
}

.product-purchase__price.--discounted {
    color: var(--primary, #e02020);
}

.product-purchase__old-price {
    font-size: 16px;
    color: #999;
    text-decoration: line-through;
    font-weight: 400;
}

.product-purchase__tax {
    font-size: 12px;
    color: #999;
    font-weight: 400;
}

/* Stock */
.product-purchase__stock {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
}

.product-purchase__stock .stock-urgency-block--inline {
    width: 100%;
}

.product-purchase__stock.--in-stock,
.product-purchase__stock .stock-urgency.--available {
    color: #16a34a;
}

.product-purchase__stock.--available-soon,
.product-purchase__stock .stock-urgency.--out {
    color: #d97706;
}

.product-purchase__stock .stock-urgency.--critical {
    color: #e02020;
}

.product-purchase__stock .stock-urgency.--low {
    color: #ea580c;
}

.product-purchase__stock-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
    animation: rp-pulse 2s infinite;
}

@keyframes rp-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.75); }
}

/* Stock alert (out of stock) */
.product-stock-alert {
    border: 1px solid #e5e7eb;
    border-radius: 3px;
    background: #fff;
    padding: 16px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.product-stock-alert__header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 14px;
}

.product-stock-alert__icon {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(224, 32, 32, 0.08);
    color: var(--primary, #e02020);
    font-size: 15px;
}

.product-stock-alert__title {
    margin: 0 0 4px;
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.3;
}

.product-stock-alert__subtitle {
    margin: 0;
    font-size: 13px;
    color: #6b7280;
    line-height: 1.45;
}

.product-stock-alert__subtitle strong {
    color: #1a1a1a;
    font-weight: 600;
}

.product-stock-alert__field {
    margin-bottom: 12px;
}

.product-stock-alert__label {
    display: block;
    margin-bottom: 6px;
    font-size: 12px;
    font-weight: 600;
    color: #4b5563;
}

.product-stock-alert__input {
    width: 100%;
    height: 42px;
    padding: 0 12px;
    border: 1px solid #e5e7eb;
    border-radius: 2px;
    background: #fff;
    font-size: 14px;
    color: #1a1a1a;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.product-stock-alert__input:focus {
    outline: none;
    border-color: rgba(224, 32, 32, 0.45);
    box-shadow: 0 0 0 3px rgba(224, 32, 32, 0.1);
}

.product-stock-alert__input:disabled {
    background: #f9fafb;
    cursor: not-allowed;
}

.product-stock-alert__btn {
    width: 100%;
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 0 16px;
    border: none;
    border-radius: 3px;
    background: var(--primary, #e02020);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s, box-shadow 0.2s, opacity 0.2s;
}

.product-stock-alert__btn:hover:not(:disabled) {
    background: #c81a1a;
    box-shadow: 0 2px 8px rgba(224, 32, 32, 0.3);
}

.product-stock-alert__btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.product-stock-alert__error {
    margin: 10px 0 0;
    font-size: 13px;
    font-weight: 600;
    color: #dc2626;
    line-height: 1.4;
}

.product-stock-alert__success {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 3px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #166534;
    font-size: 13px;
    line-height: 1.45;
}

.product-stock-alert__success i {
    flex-shrink: 0;
    margin-top: 2px;
    color: #16a34a;
    font-size: 15px;
}

.product-stock-alert__success strong {
    font-weight: 700;
    color: #14532d;
}

.product-stock-alert__privacy {
    margin: 12px 0 0;
    font-size: 12px;
    color: #9ca3af;
    line-height: 1.45;
}

.product-stock-alert__privacy a {
    color: #6b7280;
    text-decoration: underline;
}

.product-stock-alert__privacy a:hover {
    color: #1a1a1a;
}

/* Quantity + Cart */
.product-purchase__actions {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.product-purchase__actions--out-of-stock {
    justify-content: flex-end;
    margin-top: 4px;
}

.product-purchase__qty {
    display: flex;
    align-items: center;
    border: 1px solid #e5e7eb;
    border-radius: 2px;
    overflow: hidden;
    flex-shrink: 0;
}

.product-purchase__qty-btn {
    width: 33px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f9fafb;
    border: none;
    color: #333;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.15s;
}

.product-purchase__qty-btn:hover {
    background: #f3f4f6;
    font-weight: 700;
}

.product-purchase__qty-input {
    width: 46px;
    height: 100%;
    text-align: center;
    border: none;
    border-left: 1px solid #e5e7eb;
    border-right: 1px solid #e5e7eb;
    background: #fff;
    font-weight: 600;
    font-size: 15px;
    color: #333;
    -moz-appearance: textfield;
    appearance: textfield;
}

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

.product-purchase__cart-btn {
    flex: 1;
    height: 42px;
    background: var(--primary, #e02020);
    color: #fff;
    border: none;
    border-radius: 3px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;

    /* EFFETTO UNDERLINE DA NON CANCELLARE O MODIFICARE */
    text-decoration: underline;
    text-underline-offset: 20px;
    text-decoration-thickness: 1px;
    text-decoration-color: transparent;
    transition:
        background 0.2s,
        background-color 0.5s,
        box-shadow 0.2s,
        text-decoration-color 0.4s ease,
        text-decoration-thickness 0.4s ease,
        text-underline-offset 0.4s ease;
}

/* EFFETTO UNDERLINE DA NON CANCELLARE O MODIFICARE */
.product-purchase__cart-btn:hover {
    background: #0a970d;/*var(--primary-hover, #c81a1a);*/
    box-shadow: 0 2px 8px rgba(224, 32, 32, 0.35);
    text-decoration-color: currentColor;
    text-decoration-thickness: 1px;
    text-underline-offset: 4px;
}

/* Wishlist inline icon button — sits next to the cart button */
.product-purchase__wishlist-btn {
    flex-shrink: 0;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 2px;
    color: #333;/*#9ca3af;*/
    font-size: 16px;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s, background 0.2s;
    position: static;
    padding: 0;
}

.product-purchase__wishlist-btn.btn-compare{
    color: #444;
}

.product-purchase__wishlist-btn:hover {
    color: #e02020;
    border-color: rgba(224, 32, 32, 0.4);
    background: #fff5f5;
}

.product-purchase__wishlist-btn.active {
    color: #e02020;
    border-color: rgba(224, 32, 32, 0.5);
    background: #fff5f5;
}

/* Heart icon switching */
.product-purchase__wishlist-btn .heart-filled { display: none; }
.product-purchase__wishlist-btn.active .heart-empty { display: none; }
.product-purchase__wishlist-btn.active .heart-filled {
    display: inline;
    color: #e02020;
}

/* ── Trust Features (right col, bottom) ── */
.product-trust {
    border-top: 1px solid #ebebeb;
    padding: 20px 24px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: auto;
}

.product-trust__item {
    display: flex;
    align-items: center;
    gap: 14px;
}

.product-trust__icon {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 18px;
}

.product-trust__icon.--shipping {
   /* background: rgba(37, 99, 235, 0.08);
    color: #2563eb;*/
    background: rgb(255 255 255);
    color: #dc2626;
    border: 1px solid #ccc;
    padding: 5px;
    box-shadow: 0 0 5px -1px rgba(0, 0, 0, 0.3);
}

.product-trust__icon.--support {
    /*background: rgba(234, 88, 12, 0.08);
    color: #ea580c;*/
    background: rgb(255 255 255);
    color: #dc2626;
    border: 1px solid #ccc;
    padding: 4px;
    box-shadow: 0 0 5px -1px rgba(0, 0, 0, 0.3);
}

.product-trust__icon.--safety {
   /* background: rgba(22, 163, 74, 0.08);
    color: #16a34a;*/
    background: rgb(255 255 255);
    color: #dc2626;
    border: 1px solid #ccc;
    padding: 6px;
    box-shadow: 0 0 5px -1px rgba(0, 0, 0, 0.3);
}

.product-trust__icon.--offers {
    /*background: rgba(220, 38, 38, 0.08);
    color: #dc2626;*/
    background: rgb(255 255 255);
    color: #dc2626;
    border: 1px solid #ccc;
    padding: 5px 7px 4px 4px;
    box-shadow: 0 0 5px -1px rgba(0, 0, 0, 0.3);
}

.product-trust__text strong {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.3;
}

.product-trust__text span {
    font-size: 13px;
    color: #999;
    font-weight: 400;
}

/* ==========================================================================
   TABS SECTION
   ========================================================================== */
.product-tabs {
    background: #fff;
    border-radius: 2px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    margin-bottom: 24px;
    overflow: hidden;
}

.product-tabs__nav {
    display: flex;
    border-bottom: 1px solid #ebebeb;
    overflow-x: auto;
    scrollbar-width: none;
}

.product-tabs__nav::-webkit-scrollbar {
    display: none;
}

.product-tabs__tab {
    padding: 16px 28px;
    font-size: 15px;
    font-weight: 600;
    color: #999;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    cursor: pointer;
    white-space: nowrap;
    transition: color 0.2s, border-color 0.2s;
    margin-bottom: -1px;
}

.product-tabs__tab:hover {
    color: #333;
}

.product-tabs__tab.is-active {
    color: #1a1a1a;
    border-bottom-color: var(--primary, #e02020);
}

.product-tabs__tab .tab-badge {
    font-size: 11px;
    font-weight: 700;
    color: var(--primary, #e02020);
    vertical-align: super;
    margin-left: 2px;
}

/* Tab Content */
.product-tabs__panel {
    display: none;
    padding: 28px 32px;
}

.product-tabs__panel.is-active {
    display: block;
}

/* Description Tab */
.product-tabs__description {
    font-size: 15px;
    line-height: 1.75;
    color: #333;
}

.product-tabs__description h4 {
    font-size: 18px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 28px 0 12px;
}

.product-tabs__description p {
    margin-bottom: 16px;
}

/* Specification Tab */
.product-tabs__spec-group {
    margin-bottom: 24px;
}

.product-tabs__spec-group:last-child {
    margin-bottom: 0;
}

.product-tabs__spec-title {
    font-size: 16px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 12px;
}

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

.product-tabs__spec-table tr {
    border-bottom: 1px solid #ebebeb;
}

.product-tabs__spec-table tr:last-child {
    border-bottom: none;
}

.product-tabs__spec-table th {
    text-align: left;
    padding: 10px 16px 10px 0;
    font-size: 14px;
    font-weight: 500;
    color: #999;
    width: 40%;
    vertical-align: top;
}

.product-tabs__spec-table td {
    padding: 10px 0;
    font-size: 14px;
    font-weight: 500;
    color: #333;
}

/* OEM Codes (inside specs tab) */
.product-tabs__oem-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 8px;
    margin-top: 8px;
}

.product-tabs__oem-item {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 2px;
    padding: 8px 12px;
    display: flex;
    flex-direction: column;
    transition: all 0.2s;
}

.product-tabs__oem-item:hover {
    border-color: var(--primary, #e02020);
    background: #fff;
}

.product-tabs__oem-brand {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #999;
}

.product-tabs__oem-code {
    font-size: 13px;
    font-weight: 600;
    color: #333;
    font-family: 'JetBrains Mono', monospace;
}

/* Compatibility Table */
.product-tabs__compat-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 8px;
}

.product-tabs__compat-table th {
    text-align: left;
    padding: 10px 16px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #999;
    background: #f9fafb;
    border-bottom: 2px solid #ebebeb;
}

.product-tabs__compat-table td {
    padding: 10px 16px;
    font-size: 14px;
    color: #333;
    border-bottom: 1px solid #f3f4f6;
}

.product-tabs__compat-table td:first-child {
    font-weight: 600;
    color: #1a1a1a;
}

.product-tabs__compat-table tr:last-child td {
    border-bottom: none;
}

.product-tabs__disclaimer {
    font-size: 12px;
    color: #999;
    font-style: italic;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #f3f4f6;
}

/* Accordion triggers: visibili solo su mobile (product-detail-mobile.css) */
.product-tabs__accordion-trigger {
    display: none;
}

.product-tabs__accordion-body {
    display: block;
}

/* Sub-accordion: su desktop sempre espansi, trigger come titoli */
.pdp-sub-accordion__trigger {
    display: block;
    width: 100%;
    text-align: left;
    padding: 0;
    margin: 0 0 12px;
    font-size: 16px;
    font-weight: 700;
    color: #1a1a1a;
    background: none;
    border: none;
    cursor: default;
    pointer-events: none;
}

.pdp-sub-accordion__chevron,
.pdp-sub-accordion__meta {
    display: none;
}

.pdp-sub-accordion__body {
    display: block;
    margin-bottom: 24px;
}

.pdp-sub-accordion__item:last-child .pdp-sub-accordion__body {
    margin-bottom: 0;
}

.pdp-compat-mobile {
    display: none;
}

.pdp-compat-desktop {
    display: block;
}

.pdp-compat-models {
    font-size: 14px;
    line-height: 1.6;
    color: #333;
    margin: 0;
}

/* ==========================================================================
   RELATED PRODUCTS
   ========================================================================== */
.product-related {
    margin-bottom: 3rem;
}

.product-related__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.product-related__title {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
    position: relative;
    padding-left: 16px;
}

.product-related__title::before {
    content: '';
    position: absolute;
    left: 0;
    top: 2px;
    bottom: 2px;
    width: 3px;
    background: var(--primary, #e02020);
    border-radius: 2px;
}

.product-related__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

@media (min-width: 768px) {
    .product-related__grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1024px) {
    .product-related__grid {
        grid-template-columns: repeat(5, 1fr);
        gap: 6px;
    }
}

/* ==========================================================================
   SIDEBAR RESTYLE — RedParts Widget Blocks
   ========================================================================== */
.widget-sidebar {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.widget {
    background: #fff;
    border-radius: 2px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    overflow: hidden;
}

.widget__title {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 20px;
    margin: 0;
    font-size: 14px;
    font-weight: 700;
    color: #1a1a1a;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    border-bottom: 1px solid #ebebeb;
    background: #fff;
}

.widget__title i {
    color: var(--primary, #e02020);
    font-size: 14px;
}

.widget__body {
    padding: 16px 20px;
}

/* Search input inside widget */
.widget__search-row {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 2px;
    padding: 0 12px;
    margin-bottom: 12px;
    transition: border-color 0.2s;
}

.widget__search-row:focus-within {
    border-color: var(--primary, #e02020);
}

.widget__search-row i {
    color: #9ca3af;
    font-size: 13px;
    flex-shrink: 0;
}

.widget__search-input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 10px 0;
    font-size: 13px;
    color: #333;
    outline: none;
    font-family: inherit;
}

.widget__search-input::placeholder {
    color: #9ca3af;
}

/* Filter checkbox */
.widget__checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 0;
    cursor: pointer;
    font-size: 13px;
    color: #555;
    transition: color 0.15s;
}

.widget__checkbox:hover {
    color: #1a1a1a;
}

.widget__checkbox input[type="checkbox"] {
    accent-color: var(--primary, #e02020);
    width: 15px;
    height: 15px;
    cursor: pointer;
}

/* Price slider area */
.widget__slider-label {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    margin-top: 8px;
}

/* Sort select */
.widget__select-wrap {
    position: relative;
}

.widget__select {
    width: 100%;
    padding: 10px 36px 10px 12px;
    border: 1px solid #e5e7eb;
    border-radius: 2px;
    background: #f9fafb;
    font-size: 13px;
    font-weight: 500;
    color: #333;
    appearance: none;
    cursor: pointer;
    font-family: inherit;
}

.widget__select-wrap i {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 10px;
    color: #9ca3af;
    pointer-events: none;
}

/* Apply / Reset buttons */
.widget__btn-apply {
    width: 100%;
    padding: 10px;
    background: var(--primary, #e02020);
    color: #fff;
    border: none;
    border-radius: 2px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: background 0.2s;
}

.widget__btn-apply:hover {
    background: var(--primary-hover, #c81a1a);
}

.widget__btn-reset {
    width: 100%;
    padding: 8px;
    background: none;
    border: none;
    color: #999;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 6px;
    transition: color 0.2s;
    text-align: center;
    display: block;
    text-decoration: none;
}

.widget__btn-reset:hover {
    color: var(--primary, #e02020);
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 991px) {
    .product-block__inner {
        grid-template-columns: 1fr;
    }

    .product-sidebar-col {
        border-left: none;
        border-top: 1px solid #ebebeb;
    }

    .product-trust {
        flex-direction: row;
        flex-wrap: wrap;
    }

    .product-trust__item {
        flex: 1 1 45%;
        min-width: 200px;
    }
}

@media (max-width: 767px) {
    .product-block__left {
        grid-template-columns: 1fr;
    }

    .product-info {
        border-left: none;
        border-top: 1px solid #ebebeb;
    }

    .product-info__title {
        font-size: 18px;
    }

    .product-purchase__price {
        font-size: 24px;
    }

    .product-tabs__panel {
        padding: 20px 16px;
    }

    .product-tabs__tab {
        padding: 14px 18px;
        font-size: 14px;
    }
}

/* Gallery placeholder for missing images */
.product-gallery__main img.is-placeholder {
    max-width: 60%;
    opacity: 0.4;
    filter: grayscale(1);
    justify-self: center;
}

/* ==========================================================================
   REVIEWS STYLES
   ========================================================================== */

.product-reviews {
    padding: 12px 0 0;
}

.product-reviews__title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 20px;
    color: #1a1a1a;
    display: flex;
    align-items: center;
    gap: 12px;
    letter-spacing: -0.2px;
}

/* Red accent bar like mobile for visual consistency */
.product-reviews__title::before {
    content: "";
    width: 5px;
    height: 24px;
    background: #e02020;
    border-radius: 2px;
    flex-shrink: 0;
}

.product-reviews__summary {
    margin-bottom: 28px;
}

.product-reviews__stats {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-top: 8px;
    background: #fafafa;
    border: 1px solid #ececec;
    padding: 14px 18px;
    border-radius: 4px;
}

.product-reviews__rating {
    display: flex;
    align-items: center;
    gap: 10px;
}

.product-reviews__stars {
    display: flex;
    gap: 2px;
}

.product-reviews__stars .fa-star {
    color: #fbbf24;
    font-size: 17px;
}

.product-reviews__stars .fa-star.empty {
    color: #d1d5db;
}

.product-reviews__score {
    font-weight: 700;
    font-size: 19px;
    color: #1a1a1a;
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.product-reviews__count {
    color: #6b7280;
    font-size: 13.5px;
}

.product-reviews__empty {
    text-align: center;
    padding: 42px 28px;
    background: #fafafa;
    border: 1px dashed #d8d8d8;
    border-radius: 6px;
    color: #6b7280;
    position: relative;
}

/* Star icon like on mobile, scaled for desktop */
.product-reviews__empty::before {
    content: "\f005";                       /* fa-star */
    font-family: "Font Awesome 6 Free", "Font Awesome 5 Free", FontAwesome;
    font-weight: 400;
    display: block;
    font-size: 32px;
    color: #d1d5db;
    margin-bottom: 14px;
    line-height: 1;
}

.product-reviews__empty p {
    margin: 0 0 8px 0;
    font-size: 15.5px;
    line-height: 1.5;
}

.product-reviews__empty p:first-of-type {
    font-weight: 700;
    color: #1f2937;
    font-size: 16px;
}

.product-reviews__empty p:last-child {
    margin-bottom: 0;
    font-size: 14px;
    color: #6b7280;
}

/* Review Actions */
.product-reviews__actions {
    margin-bottom: 28px;
}

/* Clean primary button for reviews section (no red halo/glow) */
.product-reviews .btn-primary {
    background: #e02020;
    color: #fff;
    border: none;
    padding: 13px 26px;
    font-size: 14px;
    font-weight: 700;
    border-radius: 4px;
    text-transform: none;
    letter-spacing: normal;
    box-shadow: none;
    transition: background 0.15s ease, transform 0.1s ease;
}

.product-reviews .btn-primary:hover,
.product-reviews .btn-primary:focus-visible {
    background: #c81a1a;
    box-shadow: none;
    transform: none;
}

.product-reviews .btn-primary:active {
    transform: translateY(1px);
}

.product-reviews .btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Secondary button consistency */
.product-reviews .btn-secondary {
    background: #fff;
    color: #374151;
    border: 1px solid #d1d5db;
    padding: 13px 20px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 4px;
    box-shadow: none;
}

.product-reviews .btn-secondary:hover {
    border-color: #374151;
    background: #f9fafb;
}

/* Review Form */
.product-reviews__form {
    background: #fafafa;
    padding: 26px;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    margin-bottom: 28px;
}

.product-reviews__form h4 {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 18px;
    color: #1a1a1a;
    letter-spacing: -0.1px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 8px;
    color: #374151;
}

.rating-input {
    display: flex;
    gap: 4px;
}

.rating-star {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    transition: transform 0.2s;
}

.rating-star:hover {
    transform: scale(1.1);
}

.rating-star .fa-star {
    font-size: 24px;
    color: #d1d5db;
    transition: color 0.2s;
}

.rating-star:hover .fa-star,
.rating-star .fa-solid.fa-star {
    color: #fbbf24;
}

.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #d1d5db;
    border-radius: 6px;
    font-family: inherit;
    font-size: 14px;
    resize: vertical;
    transition: border-color 0.2s;
}

.form-group textarea:focus {
    outline: none;
    border-color: #e02020;
}

.form-help {
    font-size: 12px;
    color: #6b7280;
    margin-top: 4px;
}

.form-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

/* Reviews List */
.product-reviews__list {
    margin-top: 30px;
}

.reviews-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.review-item {
    padding: 20px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.review-author {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.review-author strong {
    font-weight: 600;
    color: #1a1a1a;
}

.review-rating {
    display: flex;
    gap: 2px;
}

.review-rating .fa-star {
    font-size: 14px;
    color: #fbbf24;
}

.review-rating .fa-regular.fa-star {
    color: #d1d5db;
}

.review-date {
    font-size: 12px;
    color: #6b7280;
}

.review-content {
    color: #374151;
    line-height: 1.5;
}

/* Reviews Pagination */
.reviews-pagination {
    text-align: center;
    margin-top: 24px;
}

/* Responsive */
@media (max-width: 768px) {
    .product-reviews__stats {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .review-header {
        flex-direction: column;
        gap: 8px;
    }

    .form-actions {
        flex-direction: column;
    }

    .form-actions .btn-primary,
    .form-actions .btn-secondary {
        width: 100%;
    }
}

/* ════════════════════════════════════════════════
   IMAGE LIGHTBOX (overlay galleria immagine)
   ════════════════════════════════════════════════ */
.pd-lightbox {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
}

.pd-lightbox--open {
    display: flex;
}

html.pd-lightbox-open,
html.pd-lightbox-open body {
    overflow: hidden;
}

.pd-lightbox__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
    cursor: zoom-out;
}

.pd-lightbox__stage {
    position: relative;
    z-index: 1;
    margin: 0;
    width: 92vw;
    max-width: 92vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    pointer-events: none;
}

.pd-lightbox__viewport {
    width: 100%;
    max-height: 82vh;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    touch-action: pinch-zoom pan-y;
    pointer-events: auto;
    border-radius: 8px;
}

.pd-lightbox__viewport.is-zoomed {
    cursor: grab;
    touch-action: none;
}

.pd-lightbox__img {
    max-width: 92vw;
    max-height: 82vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
    background: #fff;
    transform-origin: center center;
    transition: transform 0.12s ease-out;
    will-change: transform;
}

.pd-lightbox__counter {
    color: #fff;
    font-size: 14px;
    font-variant-numeric: tabular-nums;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.pd-lightbox__btn {
    position: absolute;
    z-index: 2;
    background: rgba(255, 255, 255, 0.92);
    color: #111;
    border: none;
    border-radius: 999px;
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    transition: transform .15s ease, background .15s ease;
}

.pd-lightbox__btn:hover {
    background: #fff;
    transform: scale(1.05);
}

.pd-lightbox__btn--close {
    top: 16px;
    right: 16px;
}

.pd-lightbox__btn--prev {
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
}

.pd-lightbox__btn--prev:hover {
    transform: translateY(-50%) scale(1.05);
}

.pd-lightbox__btn--next {
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
}

.pd-lightbox__btn--next:hover {
    transform: translateY(-50%) scale(1.05);
}

/* Cursore zoom-in sull'immagine principale */
#product-main-lightbox-link {
    display: block;
    cursor: zoom-in;
}

@media (max-width: 768px) {
    .pd-lightbox__btn {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    .pd-lightbox__btn--close { top: 12px; right: 12px; }
    .pd-lightbox__btn--prev { left: 8px; }
    .pd-lightbox__btn--next { right: 8px; }
}
