/* Карточка товара (PDP) */

.product-pdp .product-thumbs {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-height: 420px;
    overflow-y: auto;
    flex-shrink: 0;
}

.product-pdp .product-thumb {
    width: 4rem;
    height: 4rem;
    border-radius: 0.5rem;
    overflow: hidden;
    border: 2px solid transparent;
    padding: 0;
    background: #f1f5f9;
    cursor: pointer;
    transition: border-color 0.15s;
}

.product-pdp .product-thumb:hover,
.product-pdp .product-thumb.is-active {
    border-color: #e53935;
}

.product-pdp .product-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-pdp .product-main-img {
    border-radius: 1rem;
    background: #f1f5f9;
    width: 100%;
    max-height: 420px;
    object-fit: contain;
}

.product-pdp .product-tabs-nav button {
    border: none;
    background: none;
    padding: 0.75rem 0;
    margin-right: 1.5rem;
    font-weight: 600;
    color: #64748b;
    border-bottom: 2px solid transparent;
    cursor: pointer;
}

.product-pdp .product-tabs-nav button.is-active {
    color: #e53935;
    border-bottom-color: #e53935;
}

.product-pdp .product-tab-panel {
    display: none;
}

.product-pdp .product-tab-panel.is-active {
    display: block;
}

.product-pdp .product-desc-collapsed {
    max-height: 8.5rem;
    overflow: hidden;
    position: relative;
}

.product-pdp .product-desc-collapsed::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3rem;
    background: linear-gradient(transparent, #f8fafc);
}

.product-pdp .product-desc-expanded .product-desc-collapsed::after {
    display: none;
}

.product-pdp .product-desc-expanded .product-desc-collapsed {
    max-height: none;
}

.product-pdp .product-buy {
    align-self: start;
}

.product-pdp .review-stars {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.product-pdp .review-star-btn {
    border: none;
    background: transparent;
    color: #1e293b;
    padding: 0.15rem;
    line-height: 1;
    cursor: pointer;
    border-radius: 0.35rem;
    transition: color 0.15s ease, transform 0.15s ease, background 0.15s ease;
}

.product-pdp .review-star-btn:hover {
    color: #f59e0b;
    background: #fffbeb;
    transform: translateY(-1px);
}

.product-pdp .review-star-btn.is-on {
    color: #f59e0b !important;
}

.product-pdp .review-star-btn.is-on svg {
    stroke: #f59e0b !important;
    fill: #fbbf24 !important;
}

.product-pdp .review-star-btn.is-on svg {
    fill: currentColor;
}

.product-pdp .review-star-btn svg.review-star-icon--on {
    fill: currentColor;
}


.product-pdp .product-short-specs {
    padding-top: 0.35rem;
}

.product-pdp .product-short-specs__title {
    margin: 0 0 1rem;
    color: #0f172a;
    font-size: 1rem;
    font-weight: 800;
    line-height: 1.25;
}

.product-pdp .product-short-specs__list {
    display: flex;
    flex-direction: column;
    gap: 0.72rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.product-pdp .product-short-specs__row {
    display: grid;
    grid-template-columns: minmax(12.5rem, 12.5rem) minmax(1rem, 1fr) minmax(8rem, 12rem);
    align-items: center;
    gap: 0.5rem;
    color: #64748b;
    font-size: 0.88rem;
    line-height: 1.25;
}

.product-pdp .product-short-specs__label {
    color: #64748b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.product-pdp .product-short-specs__dots {
    min-width: 1rem;
    height: 1px;
    border-bottom: 1px dashed #d8dee8;
    transform: translateY(0.08rem);
}

.product-pdp .product-short-specs__value {
    min-width: 0;
    color: #334155;
    font-weight: 700;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.product-pdp .product-short-specs__all {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    margin-top: 1rem;
    padding: 0.48rem 0.78rem;
    border: 0;
    border-radius: 0.65rem;
    background: #f8fafc;
    color: #0f172a;
    font-size: 0.88rem;
    font-weight: 800;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.product-pdp .product-short-specs__all:hover {
    background: #eef2f7;
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.08);
}

.product-pdp .product-short-specs__all span {
    font-size: 1.1rem;
    line-height: 1;
}

@media (max-width: 767px) {
    .product-pdp .product-short-specs__row {
        grid-template-columns: minmax(10rem, 10rem) minmax(1rem, 1fr) minmax(6rem, 1fr);
    }
}


@media (max-width: 420px) {
    .product-pdp .product-short-specs__row {
        grid-template-columns: minmax(8.5rem, 8.5rem) minmax(0.75rem, 1fr) minmax(5.5rem, 1fr);
        gap: 0.35rem;
        font-size: 0.82rem;
    }
}

@media (max-width: 1023px) {
    .product-pdp .product-thumbs {
        flex-direction: row;
        max-height: none;
        overflow-x: auto;
        width: 100%;
    }
}

/*
 * Калькулятор рассрочки: #tvonInstallmentRoot — высокая специфичность (перебивает Tailwind CDN),
 * стили страницы подключаются последними в shop_header.
 */
#tvonInstallmentRoot.tvon-inst-wrap {
    --tvon-inst-accent: #e53935;
    --tvon-inst-accent-dark: #b71c1c;
    --tvon-inst-accent-glow: rgba(229, 57, 53, 0.35);
    --tvon-inst-track: #cbd5e1;
    --tvon-inst-pct: 50%;
    position: relative;
    border-radius: 1.35rem;
    overflow: hidden;
    color-scheme: light;
    background: linear-gradient(165deg, #ffffff 0%, #f1f5f9 55%, #e8edf3 100%);
    border: 1px solid rgba(148, 163, 184, 0.45);
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.9) inset,
        0 28px 56px -32px rgba(15, 23, 42, 0.45),
        0 12px 24px -16px rgba(229, 57, 53, 0.12);
}

#tvonInstallmentRoot .tvon-inst-banner {
    position: relative;
    padding: 1.15rem 1.25rem 1.2rem;
    background: linear-gradient(125deg, #1e293b 0%, #334155 42%, #0f172a 100%);
    color: #f8fafc;
}

#tvonInstallmentRoot .tvon-inst-banner::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    background: linear-gradient(90deg, #ffab91 0%, var(--tvon-inst-accent) 50%, #c62828 100%);
    opacity: 0.95;
}

#tvonInstallmentRoot .tvon-inst-head {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
}

#tvonInstallmentRoot .tvon-inst-head-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.85rem;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.22);
    color: #fecaca;
    flex-shrink: 0;
    box-shadow: 0 8px 20px -8px rgba(0, 0, 0, 0.4);
}

#tvonInstallmentRoot .tvon-inst-head-ico {
    width: 1.2rem;
    height: 1.2rem;
    stroke-width: 2;
}

#tvonInstallmentRoot .tvon-inst-head-text {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

#tvonInstallmentRoot .tvon-inst-head-kicker {
    margin: 0;
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(252, 231, 243, 0.85);
}

#tvonInstallmentRoot .tvon-inst-head-title {
    margin: 0;
    font-size: 1.125rem;
    font-weight: 800;
    letter-spacing: -0.035em;
    line-height: 1.2;
    color: #fff;
}

#tvonInstallmentRoot .tvon-inst-head-sub {
    margin: 0;
    font-size: 0.8125rem;
    line-height: 1.5;
    font-weight: 400;
    color: rgba(226, 232, 240, 0.88);
    max-width: 26rem;
}

#tvonInstallmentRoot .tvon-inst-inner {
    padding: 1.15rem 1.2rem 1.3rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.55) 0%, rgba(248, 250, 252, 0.95) 100%);
}

#tvonInstallmentRoot .tvon-inst-hero {
    background: #fff;
    border-radius: 1.05rem;
    padding: 1rem 1.1rem 1.05rem;
    border: 1px solid rgba(226, 232, 240, 0.95);
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.8) inset,
        0 14px 32px -22px rgba(229, 57, 53, 0.25);
}

#tvonInstallmentRoot .tvon-inst-hero-label {
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #94a3b8;
    margin-bottom: 0.4rem;
}

#tvonInstallmentRoot .tvon-inst-hero-sum {
    font-size: clamp(1.85rem, 5.5vw, 2.35rem);
    font-weight: 800;
    letter-spacing: -0.045em;
    color: var(--tvon-inst-accent);
    line-height: 1.02;
    font-variant-numeric: tabular-nums;
    font-feature-settings: 'tnum' 1;
    transition: color 0.15s ease, transform 0.15s ease;
}

#tvonInstallmentRoot .tvon-inst-hero-foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.4rem 0.55rem;
    margin-top: 0.55rem;
    font-size: 0.8125rem;
    color: #475569;
}

#tvonInstallmentRoot .tvon-inst-hero-hint {
    font-weight: 500;
    color: #64748b;
}

#tvonInstallmentRoot .tvon-inst-hero-dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #cbd5e1;
    flex-shrink: 0;
}

#tvonInstallmentRoot .tvon-inst-hero-term {
    font-weight: 600;
    color: #334155;
}

#tvonInstallmentRoot .tvon-inst-panel {
    background: #fff;
    border-radius: 1.05rem;
    padding: 1rem 1.05rem 1.05rem;
    border: 1px solid #e2e8f0;
    box-shadow: 0 10px 28px -24px rgba(15, 23, 42, 0.2);
}

#tvonInstallmentRoot .tvon-inst-panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.65rem;
}

#tvonInstallmentRoot .tvon-inst-panel-title {
    font-size: 0.8125rem;
    font-weight: 700;
    color: #334155;
    letter-spacing: -0.015em;
}

#tvonInstallmentRoot .tvon-inst-month-pill {
    font-size: 0.75rem;
    font-weight: 500;
    color: #475569;
    padding: 0.3rem 0.7rem;
    border-radius: 9999px;
    background: linear-gradient(180deg, #f8fafc, #f1f5f9);
    border: 1px solid #e2e8f0;
    white-space: nowrap;
}

#tvonInstallmentRoot .tvon-inst-month-pill strong {
    font-weight: 800;
    color: var(--tvon-inst-accent);
    font-variant-numeric: tabular-nums;
}

#tvonInstallmentRoot .tvon-inst-slider-wrap {
    margin-top: 0.15rem;
}

#tvonInstallmentRoot .tvon-inst-slider-shell {
    padding: 0.35rem 0.1rem 0.15rem;
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range'] {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 2rem;
    margin: 0;
    background: transparent;
    cursor: pointer;
    accent-color: var(--tvon-inst-accent);
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range']:focus {
    outline: none;
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range']:focus-visible {
    outline: 2px solid var(--tvon-inst-accent);
    outline-offset: 4px;
    border-radius: 0.35rem;
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range']::-webkit-slider-runnable-track {
    height: 0.5rem;
    border-radius: 9999px;
    background: linear-gradient(
        to right,
        var(--tvon-inst-accent) 0%,
        var(--tvon-inst-accent) var(--tvon-inst-pct),
        var(--tvon-inst-track) var(--tvon-inst-pct),
        var(--tvon-inst-track) 100%
    );
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06) inset;
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range']::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 1.35rem;
    height: 1.35rem;
    margin-top: calc((0.5rem - 1.35rem) / 2);
    border-radius: 50%;
    background: linear-gradient(160deg, #ffffff 0%, #ffe8e6 100%);
    border: 2px solid var(--tvon-inst-accent);
    box-shadow:
        0 3px 12px var(--tvon-inst-accent-glow),
        0 0 0 1px rgba(255, 255, 255, 0.95) inset;
    transition: transform 0.12s ease, box-shadow 0.12s ease;
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range']:hover::-webkit-slider-thumb {
    transform: scale(1.08);
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range']::-moz-range-track {
    height: 0.5rem;
    border-radius: 9999px;
    background: var(--tvon-inst-track);
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06) inset;
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range']::-moz-range-progress {
    height: 0.5rem;
    border-radius: 9999px;
    background: var(--tvon-inst-accent);
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range']::-moz-range-thumb {
    width: 1.35rem;
    height: 1.35rem;
    border-radius: 50%;
    background: #fff;
    border: 2px solid var(--tvon-inst-accent);
    box-shadow: 0 3px 12px var(--tvon-inst-accent-glow);
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range']::-ms-track {
    height: 0.5rem;
    border-radius: 9999px;
    background: transparent;
    border-color: transparent;
    color: transparent;
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range']::-ms-fill-lower {
    background: var(--tvon-inst-accent);
    border-radius: 9999px;
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range']::-ms-fill-upper {
    background: var(--tvon-inst-track);
    border-radius: 9999px;
}

#tvonInstallmentRoot input.tvon-inst-slider[type='range']::-ms-thumb {
    width: 1.35rem;
    height: 1.35rem;
    border-radius: 50%;
    background: #fff;
    border: 2px solid var(--tvon-inst-accent);
    box-shadow: 0 3px 12px var(--tvon-inst-accent-glow);
}

#tvonInstallmentRoot .tvon-inst-ticks {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.35rem;
    margin-top: 0.5rem;
    padding: 0 0.05rem;
}

#tvonInstallmentRoot .tvon-inst-tick {
    flex: 1 1 auto;
    min-width: 2.25rem;
    padding: 0.35rem 0.4rem;
    border: 1px solid #e2e8f0;
    border-radius: 0.55rem;
    background: #f8fafc;
    color: #475569;
    font-size: 0.75rem;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    cursor: pointer;
    transition:
        background 0.12s ease,
        color 0.12s ease,
        border-color 0.12s ease,
        box-shadow 0.12s ease,
        transform 0.12s ease;
}

#tvonInstallmentRoot .tvon-inst-tick:hover {
    border-color: rgba(229, 57, 53, 0.35);
    background: #fff;
    color: var(--tvon-inst-accent);
}

#tvonInstallmentRoot .tvon-inst-tick.is-active {
    background: linear-gradient(165deg, #ef5350, var(--tvon-inst-accent));
    color: #fff;
    border-color: transparent;
    box-shadow: 0 6px 16px -6px var(--tvon-inst-accent-glow);
    transform: translateY(-1px);
}

#tvonInstallmentRoot .tvon-inst-range-foot {
    margin: 0.65rem 0 0;
    font-size: 0.75rem;
    line-height: 1.45;
    color: #64748b;
    text-align: center;
}

#tvonInstallmentRoot .tvon-inst-total-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 0.9rem;
    padding: 0.75rem 0.85rem;
    border-radius: 0.85rem;
    background: linear-gradient(135deg, rgba(241, 245, 249, 0.9) 0%, rgba(255, 255, 255, 0.95) 100%);
    border: 1px solid #e2e8f0;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.9) inset;
}

#tvonInstallmentRoot .tvon-inst-total-lbl {
    font-size: 0.8125rem;
    font-weight: 600;
    color: #64748b;
}

#tvonInstallmentRoot .tvon-inst-total-val {
    font-size: 1.0625rem;
    font-weight: 800;
    letter-spacing: -0.025em;
    color: #0f172a;
    font-variant-numeric: tabular-nums;
    font-feature-settings: 'tnum' 1;
}

#tvonInstallmentRoot .tvon-inst-rate-note {
    margin: 0;
    font-size: 0.75rem;
    line-height: 1.45;
    color: #92400e;
    padding: 0.55rem 0.7rem;
    border-radius: 0.65rem;
    background: linear-gradient(180deg, rgba(254, 243, 199, 0.75), rgba(253, 230, 138, 0.25));
    border: 1px solid rgba(251, 191, 36, 0.5);
}

#tvonInstallmentRoot .tvon-inst-form {
    margin: 0;
}

#tvonInstallmentRoot .tvon-inst-submit {
    width: 100%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin: 0;
    padding: 0.9rem 1.15rem;
    border-radius: 1rem;
    font-weight: 800;
    font-size: 0.9375rem;
    letter-spacing: -0.02em;
    color: #fff;
    background: linear-gradient(168deg, #ff7043 0%, var(--tvon-inst-accent) 38%, var(--tvon-inst-accent-dark) 100%);
    border: none;
    cursor: pointer;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.22) inset,
        0 14px 32px -12px rgba(183, 28, 28, 0.65);
    transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

#tvonInstallmentRoot .tvon-inst-submit-ico {
    width: 1.1rem;
    height: 1.1rem;
    stroke-width: 2.5;
}

#tvonInstallmentRoot .tvon-inst-submit:hover {
    filter: brightness(1.05);
    transform: translateY(-2px);
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.28) inset,
        0 18px 40px -12px rgba(183, 28, 28, 0.72);
}

#tvonInstallmentRoot .tvon-inst-submit:active {
    transform: translateY(0);
    filter: brightness(0.98);
}

.tvon-inst-paygrid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tvon-inst-paypill {
    font-size: 0.7rem;
    font-weight: 600;
    padding: 0.38rem 0.72rem;
    border-radius: 9999px;
    background: #f8fafc;
    border: 1px solid #e8ecf1;
    color: #475569;
    transition: border-color 0.12s ease, background 0.12s ease;
}

.tvon-inst-paypill:hover {
    border-color: rgba(229, 57, 53, 0.25);
    background: #fff;
}
