/* Product detail — layout row */
.pd-detail-row {
    align-items: flex-start;
    row-gap: 28px;
}

/* Product detail — gallery panel */
.pd-gallery {
    margin-right: 0 !important;
    position: sticky;
    top: 110px;
}

.pd-gallery__card {
    background: var(--tds-white);
    border: 1px solid var(--tds-gray-100);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 8px 30px rgba(15, 23, 42, 0.04);
}

.pd-gallery__stage {
    border-radius: 10px;
    overflow: hidden;
    background: #f8fafc;
    border: 1px solid var(--tds-gray-100);
}

.pd-gallery__swiper {
    width: 100%;
}

.pd-gallery__stage .product-details__img {
    margin: 0;
}

.pd-gallery__stage .product-gallery-link {
    display: block;
    position: relative;
    cursor: zoom-in;
}

.pd-gallery__stage .product-gallery-link img {
    width: 100%;
    display: block;
    /* aspect-ratio: 1 / 1; */
    object-fit: contain;
    background: #fff;
    border: 0;
    border-radius: 0;
}

.product-gallery-link__zoom {
    position: absolute;
    right: 14px;
    bottom: 14px;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(17, 17, 17, 0.72);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    pointer-events: none;
    transition: background 0.2s ease;
}

.product-gallery-link:hover .product-gallery-link__zoom {
    background: var(--tds-red);
}

.pd-gallery__thumbs-wrap {
    max-width: 100% !important;
    margin-top: 14px !important;
}

.pd-gallery__thumbs .swiper-slide {
    width: auto;
}

.pd-gallery__thumbs .product-details__thumb-img {
    width: 76px !important;
    height: 76px;
    border-radius: 10px;
    border: 2px solid transparent;
    overflow: hidden;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.pd-gallery__thumbs .product-details__thumb-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.pd-gallery__thumbs .swiper-slide-thumb-active .product-details__thumb-img {
    border-color: var(--tds-red);
    box-shadow: 0 0 0 1px var(--tds-red);
}

.pd-gallery__thumbs .product-details__thumb-img::before {
    display: none;
}

/* Product detail — summary panel */
.pd-summary {
    padding: 0;
    margin-top: 0 !important;
}

.pd-summary__title {
    font-size: clamp(24px, 3vw, 32px);
    font-weight: 700;
    line-height: 1.3;
    color: var(--tds-navy);
    margin: 0 0 14px;
    letter-spacing: -0.02em;
}

.pd-summary__review {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    font-size: 14px;
    color: var(--tds-gray-500);
}

.pd-summary__review i {
    color: #f59e0b;
    font-size: 13px;
}

.pd-summary__meta {
    list-style: none;
    margin: 0 0 20px;
    padding: 16px 18px;
    background: #f8fafc;
    border: 1px solid var(--tds-gray-100);
    border-radius: 12px;
    display: grid;
    gap: 10px;
}

.pd-summary__meta li {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 6px 10px;
    font-size: 14px;
    line-height: 1.5;
    color: var(--tds-navy);
}

.pd-summary__meta-label {
    font-weight: 600;
    color: var(--tds-gray-500);
    min-width: 88px;
}

.pd-summary__meta-value {
    font-weight: 500;
}

.pd-summary__excerpt {
    font-size: 15px;
    line-height: 1.7;
    color: #4b5563;
    margin: 0 0 22px;
}

.pd-summary__price-box {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 16px;
    margin-bottom: 24px;
    padding-bottom: 22px;
    border-bottom: 1px solid var(--tds-gray-100);
}

.pd-summary__price-current {
    font-size: clamp(26px, 3.5vw, 34px);
    font-weight: 700;
    color: var(--tds-red);
    line-height: 1.1;
}

.pd-summary__price-old {
    font-size: 18px;
    color: #9ca3af;
    text-decoration: line-through;
}

.pd-summary__price-contact {
    font-size: 22px;
    font-weight: 700;
    color: var(--tds-red);
}

.pd-summary__stock {
    font-size: 13px;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: 999px;
    background: #ecfdf5;
    color: #047857;
}

.pd-summary__stock.is-out {
    background: #fef2f2;
    color: #b91c1c;
}

.pd-summary__variants {
    display: grid;
    gap: 18px;
    margin-bottom: 26px;
}

.pd-variant-row__label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--tds-navy);
    margin-bottom: 10px;
}

.pd-variant-row__options {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pd-variant-option {
    position: relative;
}

.pd-variant-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.pd-variant-option label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 8px 16px;
    border: 1.5px solid var(--tds-gray-300);
    border-radius: 10px;
    background: #fff;
    font-size: 14px;
    font-weight: 500;
    color: var(--tds-navy);
    cursor: pointer;
    transition:
        border-color 0.2s ease,
        background 0.2s ease,
        color 0.2s ease,
        box-shadow 0.2s ease;
    margin: 0;
    user-select: none;
}

.pd-variant-option label:hover {
    border-color: var(--tds-red);
}

.pd-variant-option input:checked + label {
    border-color: var(--tds-red);
    background: rgba(180, 4, 20, 0.06);
    color: var(--tds-red);
    box-shadow: 0 0 0 1px var(--tds-red);
}

.pd-variant-option.is-disabled label {
    opacity: 0.45;
    cursor: not-allowed;
    text-decoration: line-through;
}

.pd-summary__qty-row {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 18px;
}

.pd-summary__qty-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--tds-navy);
}

.pd-qty-control {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--tds-gray-300);
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
}

.pd-qty-control button {
    width: 40px;
    height: 40px;
    border: 0;
    background: #f9fafb;
    color: var(--tds-navy);
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    transition: background 0.2s ease;
}

.pd-qty-control button:hover {
    background: #f3f4f6;
}

.pd-qty-control input {
    width: 52px;
    height: 40px;
    border: 0;
    border-left: 1px solid var(--tds-gray-100);
    border-right: 1px solid var(--tds-gray-100);
    text-align: center;
    font-size: 15px;
    font-weight: 600;
    color: var(--tds-navy);
    -moz-appearance: textfield;
}

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

.pd-summary__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.pd-summary__actions .tds-btn {
    flex: 1 1 180px;
    min-height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 600;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        opacity 0.2s ease;
}

.pd-summary__actions .tds-btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.pd-summary__toast {
    margin-top: 14px;
    font-size: 14px;
    font-weight: 500;
    color: #047857;
    min-height: 20px;
}

.pd-summary__toast.is-error {
    color: #b91c1c;
}

/* Product reviews */
.pd-reviews {
    display: grid;
    gap: 28px;
}

.pd-reviews__summary {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 28px;
    padding: 22px;
    border: 1px solid var(--tds-gray-100);
    border-radius: 12px;
    background: #f8fafc;
}

.pd-reviews__score {
    font-size: 42px;
    font-weight: 700;
    line-height: 1;
    color: var(--tds-navy);
}

.pd-reviews__score-stars i {
    color: #f59e0b;
    font-size: 14px;
}

.pd-reviews__score-count {
    margin: 8px 0 0;
    font-size: 14px;
    color: var(--tds-gray-500);
}

.pd-reviews__bar-row {
    display: grid;
    grid-template-columns: 52px 1fr 28px;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.pd-reviews__bar-label {
    font-size: 13px;
    color: #4b5563;
}

.pd-reviews__bar-label i {
    color: #f59e0b;
    font-size: 11px;
}

.pd-reviews__bar-track {
    height: 8px;
    border-radius: 999px;
    background: #e5e7eb;
    overflow: hidden;
}

.pd-reviews__bar-fill {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--tds-red);
}

.pd-reviews__bar-count {
    font-size: 13px;
    color: #6b7280;
    text-align: right;
}

.pd-reviews__list {
    display: grid;
    gap: 16px;
}

.pd-review-card {
    border: 1px solid var(--tds-gray-100);
    border-radius: 12px;
    padding: 18px 20px;
    background: #fff;
}

.pd-review-card__head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 12px;
}

.pd-review-card__avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(180, 4, 20, 0.1);
    color: var(--tds-red);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
    flex-shrink: 0;
}

.pd-review-card__name {
    margin: 0 0 4px;
    font-size: 16px;
    font-weight: 700;
    color: var(--tds-navy);
}

.pd-review-card__stars {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #6b7280;
}

.pd-review-card__stars i {
    color: #f59e0b;
    font-size: 12px;
}

.pd-review-card__title {
    margin: 0 0 8px;
    font-size: 15px;
    font-weight: 600;
    color: var(--tds-navy);
}

.pd-review-card__content {
    margin: 0;
    font-size: 14px;
    line-height: 1.7;
    color: #4b5563;
}

.pd-review-card__images {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}

.pd-review-card__image-link {
    display: block;
    width: 72px;
    height: 72px;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid var(--tds-gray-100);
}

.pd-review-card__image-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

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

@media (max-width: 991px) {
    .pd-gallery {
        position: static;
    }

    .pd-gallery__card {
        max-width: 560px;
        margin: 0 auto;
    }
}

@media (max-width: 575px) {
    .pd-gallery__card {
        padding: 12px;
    }

    .pd-gallery__thumbs .product-details__thumb-img {
        width: 64px !important;
        height: 64px;
    }

    .pd-summary__actions .tds-btn {
        flex: 1 1 100%;
    }
}
