/* Widok Recenzja produktu — wg projektu (scoped .product-page) */
.product-page {
    --pp-brand: #f4991a;
    --pp-navy: #303e4b;
    --pp-text: #111;
    --pp-body: #333;
    --pp-muted: #5f6b76;
    --pp-line: #e7e4df;
    --pp-alt: #faf9f7;
    --pp-media: #f3f2ef;
    --pp-pro: #15803d;
    --pp-con: #b91c1c;
    --pp-w: 1600px;
    background: #fff;
    color: var(--pp-body);
}

.product-page ::selection { background: rgba(244, 153, 26, .25); }

/* Sekcje: tło na całą szerokość, treść wyśrodkowana */
.product-page .pp-hero__grid,
.product-page .pp-section,
.product-page .pp-lead {
    padding-left: max(24px, calc((100% - var(--pp-w)) / 2 + 24px));
    padding-right: max(24px, calc((100% - var(--pp-w)) / 2 + 24px));
}

/* ---------- Hero ---------- */
.product-page .pp-hero { border-bottom: 1px solid var(--pp-line); }
.product-page .pp-hero__grid {
    padding-top: 40px;
    padding-bottom: 56px;
    display: flex;
    flex-wrap: wrap;
    gap: 48px;
    align-items: center;
}
.product-page .pp-hero__copy { flex: 1 1 420px; min-width: 0; }
.product-page .pp-tags {
    margin: 0 0 16px;
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    font-size: 13px;
    color: var(--pp-muted);
}
.product-page .pp-tags a { color: var(--pp-muted); }
.product-page .pp-tags a:hover { color: var(--pp-brand); }
.product-page .pp-tags a:not(:last-child)::after { content: ' ·'; }
.product-page .pp-title {
    font-family: 'Roboto', sans-serif;
    font-weight: 700;
    font-size: clamp(34px, 4vw, 52px);
    line-height: 1.1;
    letter-spacing: -.03em;
    margin: 0 0 28px;
    color: var(--pp-text);
    text-wrap: balance;
}
.product-page .pp-score { display: flex; align-items: center; gap: 18px; margin-bottom: 28px; }
.product-page .pp-score__value {
    width: 104px;
    height: 104px;
    flex: 0 0 104px;
    background: var(--pp-brand);
    color: var(--pp-navy);
    font-family: 'Roboto', sans-serif;
    font-weight: 900;
    font-size: 44px;
    letter-spacing: -.02em;
    display: flex;
    align-items: center;
    justify-content: center;
}
.product-page .pp-score__meta { display: flex; flex-direction: column; }
.product-page .pp-score__max { font-family: 'Roboto', sans-serif; font-size: 18px; font-weight: 700; color: var(--pp-navy); }
.product-page .pp-score__label { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--pp-muted); }

.product-page .buy-panel { padding-top: 20px; border-top: 1px solid var(--pp-line); }
.product-page .buy-panel__row { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.product-page .buy-panel__logo { display: flex; align-items: center; }
.product-page .buy-panel__logo svg { width: 80px; height: auto; }
.product-page .buy-panel-price { font-family: 'Roboto', sans-serif; font-size: 28px; font-weight: 700; color: var(--pp-text); }
.product-page .btn-buy-promoted {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 26px;
    background: var(--pp-brand);
    color: var(--pp-navy);
    font-family: 'Roboto', sans-serif;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: .04em;
    text-transform: uppercase;
}
.product-page .btn-buy-promoted:hover { background: var(--pp-navy); color: #fff; }

.product-page .pp-hero__media {
    flex: 1 1 420px;
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
}
.product-page .pp-hero__img { width: 100%; height: 100%; object-fit: contain; }
.product-page .pp-hero__placeholder { color: #c9c6c0; width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; background: var(--pp-media); }

/* ---------- Werdykt ---------- */
.product-page .pp-lead { padding-top: 64px; padding-bottom: 64px; }
.product-page .pp-opinion { max-width: 832px; margin: 0 auto; }
.product-page .pp-opinion__quote { margin: 0; position: relative; padding-top: 36px; }
.product-page .pp-opinion__quote::before {
    content: '“';
    position: absolute;
    top: -8px;
    left: 0;
    font-family: 'Roboto', sans-serif;
    font-weight: 900;
    font-size: 80px;
    line-height: 1;
    color: var(--pp-brand);
}
.product-page .pp-opinion__quote p {
    margin: 0;
    font-family: 'Roboto', sans-serif;
    font-size: clamp(22px, 2.4vw, 28px);
    font-weight: 500;
    line-height: 1.45;
    color: var(--pp-text);
}
.product-page .pp-opinion__by { margin-top: 24px; display: flex; flex-direction: column; }
.product-page .pp-opinion__name { font-style: normal; font-weight: 700; color: var(--pp-navy); }
.product-page .pp-opinion__role { font-size: 14px; color: var(--pp-muted); }

/* ---------- Sekcje ---------- */
.product-page .pp-section { padding-top: 56px; padding-bottom: 56px; }
.product-page .pp-section--alt { background: var(--pp-alt); border-top: 1px solid var(--pp-line); border-bottom: 1px solid var(--pp-line); }
.product-page .pp-section--alt + .pp-section--alt { border-top: 0; }
.product-page .pp-section__title {
    font-family: 'Roboto', sans-serif;
    font-weight: 700;
    font-size: 28px;
    margin: 0 0 28px;
    color: var(--pp-text);
}

.product-page .pp-keygrid { margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.product-page .pp-keygrid__cell { padding: 20px; background: #fff; border: 1px solid var(--pp-line); }
.product-page .pp-keygrid__key { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--pp-muted); margin-bottom: 6px; }
.product-page .pp-keygrid__val { margin: 0; font-family: 'Roboto', sans-serif; font-size: 19px; font-weight: 700; color: var(--pp-text); }

.product-page .pp-split { display: flex; flex-wrap: wrap; gap: 24px; }
.product-page .pp-split__col { flex: 1 1 400px; padding: 28px; border: 1px solid var(--pp-line); }
.product-page .pp-split__col--pro { border-top: 3px solid var(--pp-pro); }
.product-page .pp-split__col--con { border-top: 3px solid var(--pp-con); }
.product-page .pp-split__title { display: flex; align-items: center; gap: 8px; margin: 0 0 16px; font-family: 'Roboto', sans-serif; font-size: 20px; font-weight: 700; }
.product-page .pp-split__col--pro .pp-split__title { color: var(--pp-pro); }
.product-page .pp-split__col--con .pp-split__title { color: var(--pp-con); }
.product-page .pp-split__list { margin: 0; padding: 0 0 0 18px; display: flex; flex-direction: column; gap: 10px; color: var(--pp-body); }

.product-page .pp-article { max-width: 1200px; margin: 0 auto; font-size: 17px; line-height: 1.75; color: var(--pp-body); overflow-wrap: break-word; }
.product-page .pp-article h2 { font-family: 'Roboto', sans-serif; font-weight: 700; font-size: 28px; line-height: 1.2; margin: 40px 0 14px; color: var(--pp-text); }
.product-page .pp-article h2:first-child { margin-top: 0; }
.product-page .pp-article h3 { font-family: 'Roboto', sans-serif; font-weight: 700; font-size: 21px; margin: 32px 0 10px; color: var(--pp-text); }
.product-page .pp-article p { margin: 0 0 20px; }
.product-page .pp-article a { color: var(--pp-brand); text-decoration: underline; }
.product-page .pp-article img { max-width: 100%; height: auto; }
.product-page .pp-article table { width: 100%; border-collapse: collapse; margin: 0 0 24px; background: #fff; border: 1px solid var(--pp-line); font-size: 15px; line-height: 1.5; }
.product-page .pp-article th,
.product-page .pp-article td { padding: 12px 16px; border: 1px solid var(--pp-line); text-align: left; vertical-align: top; }
.product-page .pp-article th,
.product-page .pp-article thead td { background: #fcfbfa; font-weight: 600; color: var(--pp-text); }
.product-page .pp-article .table-wrap,
.product-page .pp-article figure.table { overflow-x: auto; margin: 0 0 24px; }

.product-page .pp-spec-table { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--pp-line); font-size: 15px; }
.product-page .pp-spec-table tr { border-bottom: 1px solid var(--pp-line); }
.product-page .pp-spec-table th { text-align: left; font-weight: 600; color: var(--pp-muted); padding: 14px 20px; width: 40%; background: #fcfbfa; }
.product-page .pp-spec-table td { padding: 14px 20px; color: var(--pp-text); }

/* FAQ */
.product-page #faq > * { max-width: 832px; margin-left: auto; margin-right: auto; }
.product-page .faq-list { display: flex; flex-direction: column; gap: 10px; }
.product-page .faq-item { border: 1px solid var(--pp-line); background: #fff; }
.product-page .faq-button {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 18px 20px;
    background: transparent;
    border: 0;
    cursor: pointer;
    text-align: left;
    font-family: 'Roboto', sans-serif;
    font-size: 17px;
    font-weight: 700;
    color: var(--pp-text);
}
.product-page .faq-chevron {
    flex: 0 0 28px;
    width: 28px;
    height: 28px;
    padding: 6px;
    background: #f1f3f5;
    color: var(--pp-navy);
    transition: transform .2s, background .2s;
}
.product-page .faq-button[aria-expanded="true"] .faq-chevron { background: var(--pp-brand); transform: rotate(180deg); }
.product-page .faq-answer { padding: 0 20px 20px; color: var(--pp-muted); }
.product-page .faq-answer p { margin: 0; }

/* Podobne */
.product-page .pp-related { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
@media (max-width: 1023px) { .product-page .pp-related { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; } }
@media (max-width: 479px) { .product-page .pp-related { grid-template-columns: 1fr; } }
.product-page .pp-related__card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--pp-line); color: var(--pp-text); transition: box-shadow .25s; }
.product-page .pp-related__card:hover { box-shadow: 0 12px 30px rgba(17, 17, 17, .08); color: var(--pp-text); }
.product-page .pp-related__thumb { aspect-ratio: 4 / 3; background: #fff; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.product-page .pp-related__thumb img { width: 100%; height: 100%; object-fit: contain; }
.product-page .pp-related__body { padding: 18px; display: flex; flex-direction: column; gap: 6px; }
.product-page .pp-related__name { margin: 0; font-family: 'Roboto', sans-serif; font-weight: 700; font-size: 16px; color: var(--pp-text); }
.product-page .pp-related__score { margin: 0; align-self: flex-start; padding: 2px 8px; background: var(--pp-brand); color: var(--pp-navy); font-family: 'Roboto', sans-serif; font-weight: 900; font-size: 14px; }
.product-page .pp-related__excerpt { margin: 0; font-size: 14px; color: var(--pp-muted); }

.product-page a:focus-visible,
.product-page button:focus-visible { outline: 2px solid var(--pp-brand); outline-offset: 3px; }

/* Mobile: przyklejony pasek zakupu */
@media (max-width: 768px) {
    .product-page.has-mobile-buy { padding-bottom: 88px; }
    .product-page .pp-hero__grid { padding-top: 24px; padding-bottom: 32px; gap: 24px; }
    .product-page .pp-hero__media { order: -1; flex-basis: 100%; }
    .product-page .buy-panel {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 100;
        margin: 0;
        padding: 12px 16px;
        padding-bottom: max(12px, env(safe-area-inset-bottom));
        background: #fff;
        border-top: 1px solid var(--pp-line);
        box-shadow: 0 -4px 20px rgba(0, 0, 0, .06);
    }
    .product-page .buy-panel__row { flex-wrap: nowrap; gap: 12px; }
    .product-page .buy-panel__logo svg { width: 64px; }
    .product-page .buy-panel-price { font-size: 20px; }
    .product-page .btn-buy-promoted { flex: 1; min-height: 44px; margin-left: 0; padding: 10px 16px; }
    .product-page .pp-section { padding-top: 40px; padding-bottom: 40px; }
    .product-page .pp-lead { padding-top: 40px; padding-bottom: 40px; }
}

/* Ramki zdjęć o stałych proporcjach — obrazek nie może rozpychać ramki na mobile */
.product-page .pp-hero__media,
.product-page .pp-related__thumb { position: relative; overflow: hidden; min-height: 0; }
.product-page .pp-hero__img,
.product-page .pp-related__thumb img { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; }
@media (max-width: 768px) {
    .product-page .pp-hero__media { max-height: 320px; aspect-ratio: auto; height: 320px; }
}
