/* ==========================================================================
   PRODUCT VIEW — Modern Card (pv- prefix)
   standardy.pl — 2026-01-31
   Layout: 9+3 (panel+photo | tabs) + banner sidebar
   ========================================================================== */

:root {
    --pv-blue: #3f72b4;
    --pv-blue-dark: #2c5a8f;
    --pv-green: #9bc53d;
    --pv-green-dark: #7da32e;
    --pv-orange: #FA8231;
    --pv-dark: #212529;
    --pv-muted: #6c757d;
    --pv-light: #f8f9fa;
    --pv-border: #e9ecef;
    --pv-radius: 12px;
    --pv-radius-sm: 8px;
    --pv-shadow: 0 2px 16px rgba(0, 0, 0, 0.08);
    --pv-shadow-hover: 0 6px 24px rgba(0, 0, 0, 0.12);
    --pv-transition: all 0.25s ease;
}

/* ---------- BREADCRUMBS (product page only) ---------- */

.pv-breadcrumbs {
    background: transparent !important;
    margin-bottom: 8px !important;
    padding: 8px 0 0 0;
}

.pv-breadcrumbs .breadcrumb {
    background: transparent;
    margin-bottom: 0;
    padding: 0;
}

.pv-breadcrumbs .breadcrumb li a,
.pv-breadcrumbs .breadcrumb li a span {
    font-size: 13px;
    color: var(--pv-muted);
    text-decoration: none;
}

.pv-breadcrumbs .breadcrumb li a:hover span {
    color: var(--pv-blue);
    text-decoration: underline;
}

.pv-breadcrumbs .breadcrumb li.active a,
.pv-breadcrumbs .breadcrumb li.active a span {
    color: var(--pv-dark);
    font-weight: 600;
}

.pv-breadcrumbs .breadcrumbs-line {
    font-size: 9px;
    color: var(--pv-muted);
}

.pv-breadcrumbs .breadcrumbs-line i {
    font-size: 9px;
}

/* ---------- IMAGE SECTION ---------- */

.pv-image-wrapper {
    text-align: center;
    padding: 12px;
    background: transparent;
    border-radius: var(--pv-radius);
}

.pv-image {
    border-radius: var(--pv-radius);
    max-height: 560px;
    object-fit: contain;
    cursor: zoom-in;
    transition: var(--pv-transition);
}

.pv-image:hover {
    transform: scale(1.03);
}

.pv-image--placeholder {
    cursor: default;
    max-width: 280px;
}

.pv-image--placeholder:hover {
    transform: none;
}

/* ---------- BADGES ---------- */

.pv-badges {
    position: absolute;
    top: 28px;
    left: 28px;
    z-index: 2;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.pv-badge {
    display: inline-block;
    padding: 4px 12px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #fff;
    border-radius: 20px;
}

.pv-badge--new {
    background: linear-gradient(135deg, #FA8231, #f76b1c);
}

.pv-badge--promo {
    background: linear-gradient(135deg, #3f72b4, #2c5a8f);
}

.pv-badge--online {
    background: linear-gradient(135deg, #9bc53d, #7da32e);
}

.pv-badge--preview {
    background: linear-gradient(135deg, #6c757d, #555);
}

/* ---------- CATEGORY BADGE ---------- */

.pv-category-badge {
    display: inline-block;
    padding: 4px 14px;
    font-size: 12px;
    font-weight: 700;
    color: #fff;
    background: var(--pv-green);
    border-radius: 20px;
    text-transform: none;
    letter-spacing: 0.3px;
    margin-bottom: 10px;
}

/* ---------- PURCHASE PANEL ---------- */

.pv-purchase-panel {
    background: #fff;
    padding: 0;
}

/* ---------- PRODUCT CONTAINER ---------- */

.pv-product-container {
    background: #fff;
    border-radius: var(--pv-radius);
    padding: 24px;
    box-shadow: var(--pv-shadow);
    border: 1px solid var(--pv-border);
}

/* Navy dash inline with title */
.pv-title-dash {
    display: inline-block;
    width: 32px;
    height: 4px;
    background: #1a3a5c;
    border-radius: 2px;
    vertical-align: middle;
    margin-right: 10px;
}

/* Title: dark color (not blue) */
.pv-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--pv-dark);
    line-height: 1.3;
    margin-bottom: 4px;
}

/* Authors */
.pv-authors {
    margin-bottom: 12px;
}

.pv-author-link {
    color: var(--pv-muted);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: var(--pv-transition);
}

.pv-author-link:hover {
    color: var(--pv-blue);
    text-decoration: underline;
}

/* Pipe separator */
.pv-author-sep {
    color: var(--pv-border);
    margin: 0 6px;
    font-weight: 400;
}

.pv-divider {
    border-color: var(--pv-border);
    margin: 16px 0;
}

/* ---------- PRICE ---------- */

.pv-price-block {
    display: flex;
    align-items: baseline;
    gap: 12px;
    margin-bottom: 4px;
}

.pv-price {
    font-size: 36px;
    font-weight: 800;
    color: var(--pv-green);
    line-height: 1.2;
}

.pv-price-old {
    font-size: 18px;
    color: var(--pv-muted);
    text-decoration: line-through;
}

.pv-omnibus {
    font-size: 11px;
    color: var(--pv-muted);
    margin-bottom: 16px;
}

/* ---------- BUY ROW ---------- */

.pv-buy-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 16px;
    margin-bottom: 12px;
}

.pv-quantity {
    display: flex;
    align-items: center;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius-sm);
    overflow: hidden;
    flex-shrink: 0;
}

.pv-qty-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 42px;
    background: var(--pv-light);
    color: var(--pv-dark);
    cursor: pointer;
    transition: var(--pv-transition);
    text-decoration: none;
}

.pv-qty-btn:hover {
    background: var(--pv-border);
    color: var(--pv-dark);
}

.pv-qty-input {
    width: 44px;
    height: 42px;
    text-align: center;
    border: none;
    border-left: 1px solid var(--pv-border);
    border-right: 1px solid var(--pv-border);
    font-size: 15px;
    font-weight: 600;
    background: #fff;
    -moz-appearance: textfield;
}

.pv-qty-input::-webkit-outer-spin-button,
.pv-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* ---------- CTA BUTTON — BLUE ---------- */

.pv-cta-btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    background: var(--pv-blue);
    border: none;
    border-radius: var(--pv-radius-sm);
    cursor: pointer;
    transition: var(--pv-transition);
    text-transform: none;
    letter-spacing: 0.3px;
}

.pv-cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(63, 114, 180, 0.4);
    background: var(--pv-blue-dark);
}

.pv-cta-btn:active {
    transform: translateY(0);
}

.pv-cta-btn--disabled {
    background: linear-gradient(135deg, #adb5bd, #868e96);
    cursor: not-allowed;
}

.pv-cta-btn--disabled:hover {
    transform: none;
    box-shadow: none;
}

/* ---------- SHARE LINK (text, not icon buttons) ---------- */

.pv-share-link {
    display: inline-flex;
    align-items: center;
    font-size: 13px;
    font-weight: 600;
    color: var(--pv-muted);
    text-decoration: none;
    margin-top: 4px;
    transition: var(--pv-transition);
}

.pv-share-link:hover {
    color: var(--pv-blue);
    text-decoration: underline;
}

/* ---------- QUICK INFO ---------- */

.pv-quick-info {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.pv-info-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: var(--pv-muted);
}

.pv-info-item i {
    width: 18px;
    text-align: center;
    color: var(--pv-green);
    font-size: 14px;
}

/* ---------- PREV/NEXT BOOK NAV ---------- */

.pv-book-nav {
    display: flex;
    justify-content: space-between;
    gap: 12px;
}

.pv-book-nav-item {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex: 1;
    padding: 8px;
    border-radius: var(--pv-radius-sm);
    transition: var(--pv-transition);
}

.pv-book-nav-item:hover {
    background: var(--pv-light);
    text-decoration: none;
}

.pv-book-nav-item--next {
    justify-content: flex-end;
}

.pv-book-nav-item--empty {
    flex: 1;
}

.pv-book-nav-thumb {
    width: 44px;
    height: 58px;
    flex-shrink: 0;
    overflow: hidden;
    border-radius: 4px;
    border: 1px solid var(--pv-border);
    background: #fff;
}

.pv-book-nav-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pv-book-nav-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.pv-book-nav-arrow {
    font-size: 11px;
    font-weight: 700;
    color: var(--pv-blue);
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.pv-book-nav-name {
    font-size: 12px;
    font-weight: 600;
    color: var(--pv-dark);
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ---------- BANNER SIDEBAR ---------- */

.pv-banner-sidebar img {
    border-radius: var(--pv-radius-sm);
}

@media (min-width: 992px) {
    .pv-banner-sidebar {
        position: sticky;
        top: 30px; /* fallback, overridden by JS */
    }
}

/* ---------- TABS — full width, blue active ---------- */

.pv-tabs-section {
    border-top: none;
    margin-top: 24px;
}

.pv-nav-tabs {
    display: flex;
    gap: 0;
    border-bottom: 2px solid var(--pv-border);
    flex-wrap: nowrap;
    overflow-x: auto;
}

.pv-nav-tabs .nav-item {
    flex: 1;
    text-align: center;
}

.pv-tab-btn {
    width: 100%;
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 600;
    color: var(--pv-muted);
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    transition: var(--pv-transition);
    white-space: nowrap;
}

.pv-tab-btn:hover {
    color: var(--pv-dark);
}

.pv-tab-btn.active {
    color: var(--pv-blue);
    border-bottom-color: var(--pv-blue);
}

.pv-tab-content {
    min-height: 0;
}

/* Tab card — rounded container with border */
.pv-tab-card {
    background: #fff;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius);
    padding: 4px;
    margin-top: 16px;
}

.pv-tab-body {
    padding: 16px 20px;
    font-size: 15px;
    line-height: 1.7;
    color: var(--pv-dark);
}

/* ---------- DETAILS TABLE ---------- */

.pv-details-table {
    width: 100%;
    max-width: 100%;
    border-collapse: collapse;
}

.pv-details-table tr:nth-child(even) {
    background: var(--pv-light);
}

.pv-details-table td {
    padding: 10px 16px;
    font-size: 14px;
    border-bottom: 1px solid var(--pv-border);
}

.pv-dt-label {
    font-weight: 600;
    color: var(--pv-muted);
    width: 180px;
}

.pv-dt-value {
    color: var(--pv-dark);
}

/* ---------- SIMILAR PRODUCTS ---------- */

.pv-similar-section {
    border-top: 1px solid var(--pv-border);
    padding-top: 12px;
}

.pv-section-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--pv-dark);
    margin-bottom: 12px;
}

.pv-similar-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius);
    overflow: hidden;
    transition: var(--pv-transition);
    height: 100%;
}

.pv-similar-card:hover {
    box-shadow: var(--pv-shadow-hover);
    transform: translateY(-4px);
}

.pv-similar-card-link {
    text-decoration: none;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.pv-similar-card-link:hover {
    text-decoration: none;
}

.pv-similar-img-wrap {
    padding: 16px;
    text-align: center;
    background: var(--pv-light);
}

.pv-similar-img-wrap img {
    max-height: 180px;
    object-fit: contain;
}

.pv-similar-info {
    padding: 12px 14px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.pv-similar-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--pv-dark);
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.pv-similar-price {
    font-size: 15px;
    font-weight: 700;
    color: var(--pv-blue);
}

/* Hidden similar items (beyond first 4) */
.pv-similar-hidden {
    display: none;
}

/* "Pokaż więcej" button */
.pv-show-more-btn {
    display: inline-flex;
    align-items: center;
    padding: 10px 28px;
    font-size: 14px;
    font-weight: 600;
    color: var(--pv-blue);
    background: #fff;
    border: 2px solid var(--pv-blue);
    border-radius: var(--pv-radius-sm);
    cursor: pointer;
    transition: var(--pv-transition);
}

.pv-show-more-btn:hover {
    background: var(--pv-blue);
    color: #fff;
}

/* "Zobacz produkt" link */
.pv-similar-action {
    padding: 0 14px 14px;
    margin-top: auto;
}

.pv-similar-view-link {
    display: inline-flex;
    align-items: center;
    font-size: 13px;
    font-weight: 600;
    color: var(--pv-blue);
    text-decoration: none;
    transition: var(--pv-transition);
}

.pv-similar-view-link:hover {
    color: var(--pv-blue-dark);
    text-decoration: underline;
}

/* ---------- PAGINATION ---------- */

.pv-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    padding: 16px 0;
}

.pv-pagination-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 6px 14px;
    font-size: 14px;
    font-weight: 600;
    color: var(--pv-muted);
    background: #fff;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius-sm);
    text-decoration: none;
    transition: var(--pv-transition);
    cursor: pointer;
}

a.pv-pagination-btn:hover {
    color: var(--pv-blue);
    border-color: var(--pv-blue);
    background: rgba(63, 114, 180, 0.04);
    text-decoration: none;
}

.pv-pagination-btn--active {
    color: #fff;
    background: var(--pv-blue);
    border-color: var(--pv-blue);
    cursor: default;
}

.pv-pagination-btn--disabled {
    color: #ccc;
    cursor: default;
    border-color: var(--pv-border);
}

/* ---------- MODALS ---------- */

.pv-modal-content {
    border-radius: var(--pv-radius);
    border: none;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.2);
}

.pv-modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 10;
    background: #fff;
    border-radius: 50%;
    padding: 8px;
    opacity: 0.8;
}

/* ---------- SHARE ---------- */

.pv-share-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.pv-share-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 16px 8px;
    background: var(--pv-light);
    border-radius: var(--pv-radius-sm);
    text-decoration: none;
    color: var(--pv-dark);
    font-size: 12px;
    font-weight: 600;
    transition: var(--pv-transition);
}

.pv-share-btn i {
    font-size: 20px;
}

.pv-share-btn:hover {
    background: var(--pv-border);
    color: var(--pv-blue);
    text-decoration: none;
}

.pv-share-copy {
    display: flex;
    gap: 0;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius-sm);
    overflow: hidden;
}

.pv-share-input {
    flex: 1;
    border: none;
    padding: 8px 12px;
    font-size: 12px;
    color: var(--pv-muted);
    background: var(--pv-light);
    outline: none;
    min-width: 0;
}

.pv-share-copy-btn {
    padding: 8px 14px;
    font-size: 12px;
    font-weight: 600;
    color: var(--pv-blue);
    background: #fff;
    border: none;
    border-left: 1px solid var(--pv-border);
    cursor: pointer;
    white-space: nowrap;
    transition: var(--pv-transition);
}

.pv-share-copy-btn:hover {
    background: var(--pv-light);
}

/* ---------- RESPONSIVE ---------- */

@media (max-width: 991px) {
    .pv-title {
        font-size: 20px;
    }

    .pv-price {
        font-size: 28px;
    }

    .pv-purchase-panel {
        padding: 20px;
    }

    .pv-image {
        max-height: 400px;
    }

    .pv-nav-tabs .nav-item {
        flex: none;
    }
}

@media (max-width: 767px) {
    .pv-badges {
        top: 16px;
        left: 16px;
    }

    .pv-buy-row {
        flex-direction: column;
    }

    .pv-cta-btn {
        width: 100%;
    }

    .pv-quantity {
        align-self: flex-start;
    }

    .pv-pagination {
        flex-wrap: wrap;
    }

    .pv-details-table td {
        display: block;
        width: 100%;
    }

    .pv-dt-label {
        width: 100%;
        padding-bottom: 2px;
        border-bottom: none;
    }

    .pv-dt-value {
        padding-top: 0;
    }

    .pv-similar-img-wrap img {
        max-height: 140px;
    }

    .pv-book-nav {
        flex-direction: column;
        gap: 8px;
    }

    .pv-book-nav-item--next {
        flex-direction: row-reverse;
        justify-content: flex-end;
    }

    .pv-book-nav-item--next .pv-book-nav-text {
        text-align: left;
    }

    .pv-book-nav-name {
        white-space: normal;
        -webkit-line-clamp: 2;
        display: -webkit-box;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
}

/* ---------- PRINT ---------- */

@media print {
    .pv-share-link,
    .pv-pagination,
    .pv-similar-section,
    .pv-banner-sidebar,
    .pv-cta-btn,
    .pv-quantity {
        display: none !important;
    }

    .pv-purchase-panel {
        position: static;
        box-shadow: none;
        border: 1px solid #ccc;
    }
}

/* ==========================================================================
   PRODUCT LISTING — Cards Grid (pv-listing- prefix)
   /produkty page
   ========================================================================== */

/* ---------- HEADER ---------- */

.pv-listing-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
}

.pv-listing-header .pv-section-title {
    margin-bottom: 0;
}

.pv-listing-filters {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.pv-listing-filter-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.pv-listing-filter-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--pv-muted);
    margin-bottom: 0;
    white-space: nowrap;
}

.pv-listing-select {
    appearance: none;
    -webkit-appearance: none;
    padding: 7px 32px 7px 12px;
    font-size: 13px;
    font-weight: 500;
    color: var(--pv-dark);
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%236c757d'/%3E%3C/svg%3E") no-repeat right 10px center;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius-sm);
    cursor: pointer;
    transition: var(--pv-transition);
}

.pv-listing-select:focus {
    outline: none;
    border-color: var(--pv-blue);
    box-shadow: 0 0 0 3px rgba(63, 114, 180, 0.12);
}

/* ---------- CARD ---------- */

.pv-listing-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius);
    overflow: hidden;
    transition: var(--pv-transition);
    height: 100%;
}

.pv-listing-card:hover {
    box-shadow: var(--pv-shadow-hover);
    transform: translateY(-4px);
}

.pv-listing-card-link {
    text-decoration: none;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.pv-listing-card-link:hover {
    text-decoration: none;
}

/* ---------- IMAGE WRAP ---------- */

.pv-listing-img-wrap {
    position: relative;
    padding: 20px 16px;
    text-align: center;
    background: var(--pv-light);
}

.pv-listing-img-wrap img {
    max-height: 200px;
    object-fit: contain;
    transition: var(--pv-transition);
}

.pv-listing-card:hover .pv-listing-img-wrap img {
    transform: scale(1.03);
}

.pv-listing-badges {
    position: absolute;
    top: 12px;
    left: 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    z-index: 2;
}

/* ---------- INFO ---------- */

.pv-listing-info {
    padding: 14px 16px 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}

.pv-listing-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--pv-dark);
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.pv-listing-title-dash {
    display: inline-block;
    width: 20px;
    height: 3px;
    background: #1a3a5c;
    border-radius: 2px;
    vertical-align: middle;
    margin-right: 6px;
    flex-shrink: 0;
}

.pv-listing-authors {
    font-size: 12px;
    color: var(--pv-muted);
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.pv-listing-omnibus {
    font-size: 11px;
    color: var(--pv-muted);
    margin-top: 2px;
}

/* ---------- FOOTER (price + button) ---------- */

.pv-listing-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 12px 16px 16px;
    margin-top: auto;
}

.pv-listing-prices {
    display: flex;
    align-items: baseline;
    gap: 6px;
}

.pv-listing-price {
    font-size: 16px;
    font-weight: 700;
    color: var(--pv-green);
}

.pv-listing-price-old {
    font-size: 12px;
    color: var(--pv-muted);
    text-decoration: line-through;
}

.pv-listing-buy-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 16px;
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    background: var(--pv-blue);
    border: none;
    border-radius: var(--pv-radius-sm);
    cursor: pointer;
    transition: var(--pv-transition);
    white-space: nowrap;
}

.pv-listing-buy-btn:hover {
    background: var(--pv-blue-dark);
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(63, 114, 180, 0.3);
}

.pv-listing-buy-btn:active {
    transform: translateY(0);
}

.pv-listing-buy-btn--disabled {
    background: linear-gradient(135deg, #adb5bd, #868e96);
    cursor: not-allowed;
}

.pv-listing-buy-btn--disabled:hover {
    transform: none;
    box-shadow: none;
    background: linear-gradient(135deg, #adb5bd, #868e96);
}

.pv-listing-buy-btn .cart-mini-svg {
    width: 14px;
    height: 14px;
    fill: #fff;
}

/* ---------- GRID ---------- */

.pv-listing-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.pv-listing-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px 0;
}

@media (max-width: 1199px) {
    .pv-listing-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 991px) {
    .pv-listing-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 575px) {
    .pv-listing-grid {
        grid-template-columns: 1fr;
    }
}

/* ---------- BOTTOM PAGINATION ---------- */

.pv-listing-bottom-pagination {
    margin-top: 32px;
    margin-bottom: 24px;
}

/* ---------- LISTING RESPONSIVE ---------- */

@media (max-width: 991px) {
    .pv-listing-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .pv-listing-filters {
        width: 100%;
    }
}

@media (max-width: 575px) {
    .pv-listing-filters {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .pv-listing-img-wrap img {
        max-height: 160px;
    }

    .pv-listing-footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .pv-listing-buy-btn {
        width: 100%;
        justify-content: center;
    }
}

/* ---------- LISTING PRINT ---------- */

@media print {
    .pv-listing-buy-btn,
    .pv-listing-filters {
        display: none !important;
    }
}

/* ==========================================================================
   AUTHOR LISTING — Cards Grid (pv-author- prefix)
   /nasi-autorzy page
   ========================================================================== */

/* ---------- AUTHOR GRID ---------- */

.pv-author-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

@media (max-width: 1199px) {
    .pv-author-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 991px) {
    .pv-author-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 575px) {
    .pv-author-grid {
        grid-template-columns: 1fr;
    }
}

/* ---------- AUTHOR CARD ---------- */

.pv-author-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius);
    overflow: hidden;
    transition: var(--pv-transition);
    height: 100%;
    width: 100%;
}

.pv-author-card:hover {
    box-shadow: var(--pv-shadow-hover);
    transform: translateY(-4px);
}

.pv-author-card-link {
    text-decoration: none;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.pv-author-card-link:hover {
    text-decoration: none;
}

/* ---------- AUTHOR IMAGE ---------- */

.pv-author-img-wrap {
    padding: 0;
    text-align: center;
    background: var(--pv-light);
    height: 200px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pv-author-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--pv-transition);
}

.pv-author-card:hover .pv-author-img {
    transform: scale(1.03);
}

/* ---------- AUTHOR INFO ---------- */

.pv-author-info {
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
}

.pv-author-name-dash {
    display: inline-block;
    width: 20px;
    height: 3px;
    background: #1a3a5c;
    border-radius: 2px;
    vertical-align: middle;
    margin-right: 6px;
    flex-shrink: 0;
}

.pv-author-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--pv-dark);
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pv-author-pubs {
    font-size: 13px;
    color: var(--pv-muted);
}

.pv-author-cta {
    font-size: 13px;
    font-weight: 600;
    color: var(--pv-blue);
    text-decoration: none;
    margin-top: auto;
    transition: var(--pv-transition);
}

.pv-author-cta:hover {
    color: var(--pv-blue-dark);
    text-decoration: underline;
}

/* ---------- AUTHOR SIDEBAR ---------- */

.pv-author-sidebar {
    /* sticky on desktop handled in media query */
}

@media (min-width: 1200px) {
    .pv-author-sidebar {
        position: sticky;
        top: 30px;
    }
}

/* ---------- AUTHOR SEARCH ---------- */

.pv-author-search-wrap {
    position: relative;
    margin-bottom: 12px;
}

.pv-author-search {
    width: 100%;
    padding: 9px 42px 9px 14px;
    font-size: 13px;
    color: var(--pv-dark);
    background: #fff;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius-sm);
    transition: var(--pv-transition);
}

.pv-author-search:focus {
    outline: none;
    border-color: var(--pv-blue);
    box-shadow: 0 0 0 3px rgba(63, 114, 180, 0.12);
}

.pv-author-search-btn {
    position: absolute;
    top: 50%;
    right: 8px;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 4px 6px;
    cursor: pointer;
    color: var(--pv-muted);
    transition: var(--pv-transition);
}

.pv-author-search-btn:hover {
    color: var(--pv-blue);
}

.pv-author-search-btn .search-svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

/* ==========================================================================
   CART — pv-cart-* prefix
   /koszyk/koszyk1 → koszyk4 pages
   ========================================================================== */

/* ---------- STEPPER ---------- */

.pv-cart-stepper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 32px;
    padding: 20px 0;
    border-bottom: 1px solid var(--pv-border);
}

.pv-cart-step {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--pv-muted);
}

.pv-cart-step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 2px solid var(--pv-border);
    font-size: 13px;
    font-weight: 700;
    color: var(--pv-muted);
    background: #fff;
    flex-shrink: 0;
}

.pv-cart-step--active {
    color: var(--pv-blue);
}

.pv-cart-step--active .pv-cart-step-number {
    border-color: var(--pv-blue);
    background: var(--pv-blue);
    color: #fff;
}

.pv-cart-step--done {
    color: var(--pv-green);
}

.pv-cart-step--done .pv-cart-step-number {
    border-color: var(--pv-green);
    background: var(--pv-green);
    color: #fff;
}

.pv-cart-step-line {
    width: 40px;
    height: 2px;
    background: var(--pv-border);
    margin: 0 12px;
    flex-shrink: 0;
}

.pv-cart-step--done + .pv-cart-step-line {
    background: var(--pv-green);
}

/* ---------- CART ITEM ---------- */

.pv-cart-item {
    display: flex;
    align-items: center;
    gap: 16px;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius);
    padding: 16px;
    margin-bottom: 12px;
    background: #fff;
    transition: var(--pv-transition);
}

.pv-cart-item:hover {
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.pv-cart-item-img {
    width: 72px;
    height: 100px;
    flex-shrink: 0;
    background: var(--pv-light);
    border-radius: var(--pv-radius-sm);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pv-cart-item-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.pv-cart-item-name {
    flex: 1;
    min-width: 0;
}

.pv-cart-item-name a {
    font-weight: 600;
    font-size: 14px;
    color: var(--pv-dark);
    text-decoration: none;
    display: block;
    line-height: 1.4;
}

.pv-cart-item-name a:hover {
    color: var(--pv-blue);
}

.pv-cart-item-name .pv-cart-item-details {
    font-size: 12px;
    color: var(--pv-muted);
    margin-top: 4px;
}

/* ---------- QUANTITY SELECTOR ---------- */

.pv-cart-qty {
    display: flex;
    align-items: center;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius-sm);
    overflow: hidden;
    flex-shrink: 0;
}

.pv-cart-qty-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 36px;
    background: var(--pv-light);
    color: var(--pv-dark);
    cursor: pointer;
    transition: var(--pv-transition);
    text-decoration: none;
    border: none;
    font-size: 12px;
}

.pv-cart-qty-btn:hover {
    background: var(--pv-border);
    color: var(--pv-dark);
    text-decoration: none;
}

.pv-cart-qty-btn[disabled] {
    opacity: 0.4;
    cursor: not-allowed;
}

.pv-cart-qty-input {
    width: 40px;
    height: 36px;
    text-align: center;
    border: none;
    border-left: 1px solid var(--pv-border);
    border-right: 1px solid var(--pv-border);
    font-size: 14px;
    font-weight: 600;
    background: #fff;
    -moz-appearance: textfield;
}

.pv-cart-qty-input::-webkit-outer-spin-button,
.pv-cart-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* ---------- PRICE & SUBTOTAL ---------- */

.pv-cart-price {
    font-weight: 700;
    color: var(--pv-dark);
    white-space: nowrap;
    font-size: 14px;
}

.pv-cart-subtotal {
    font-weight: 700;
    color: var(--pv-dark);
    white-space: nowrap;
    font-size: 15px;
}

/* ---------- REMOVE BUTTON ---------- */

.pv-cart-remove {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    color: var(--pv-muted);
    cursor: pointer;
    transition: var(--pv-transition);
    text-decoration: none;
    border-radius: 50%;
    flex-shrink: 0;
}

.pv-cart-remove:hover {
    color: #dc3545;
    background: rgba(220, 53, 69, 0.08);
    text-decoration: none;
}

/* ---------- COUPON ---------- */

.pv-cart-coupon {
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius);
    padding: 16px;
    margin-bottom: 16px;
}

.pv-cart-coupon label {
    font-weight: 600;
    font-size: 14px;
    color: var(--pv-dark);
    margin-bottom: 8px;
    display: block;
}

/* ---------- SUMMARY ---------- */

.pv-cart-summary {
    background: var(--pv-light);
    border-radius: var(--pv-radius);
    padding: 20px;
    text-align: right;
}

.pv-cart-summary-row {
    display: flex;
    justify-content: flex-end;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 4px;
    font-size: 14px;
    color: var(--pv-muted);
}

.pv-cart-summary-total {
    font-size: 28px;
    font-weight: 800;
    color: var(--pv-dark);
    line-height: 1.2;
}

.pv-cart-summary-discount {
    color: var(--pv-green);
    font-weight: 700;
}

/* ---------- OPTION CARD (payment/delivery radio) ---------- */

.pv-cart-option {
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius);
    padding: 12px 16px;
    cursor: pointer;
    margin-bottom: 8px;
    transition: var(--pv-transition);
    display: flex;
    align-items: center;
    gap: 10px;
}

.pv-cart-option:hover {
    border-color: var(--pv-blue);
    background: rgba(63, 114, 180, 0.02);
}

.pv-cart-option--selected {
    border-color: var(--pv-blue);
    background: rgba(63, 114, 180, 0.03);
}

.pv-cart-option-detail {
    background: var(--pv-light);
    border-radius: var(--pv-radius-sm);
    padding: 12px;
    margin-top: 8px;
    font-size: 14px;
    color: var(--pv-muted);
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ---------- FORM INPUTS ---------- */

.pv-cart-input {
    display: block;
    width: 100%;
    padding: 9px 14px;
    font-size: 14px;
    color: var(--pv-dark);
    background: #fff;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius-sm);
    transition: var(--pv-transition);
}

.pv-cart-input:focus {
    outline: none;
    border-color: var(--pv-blue);
    box-shadow: 0 0 0 3px rgba(63, 114, 180, 0.12);
}

textarea.pv-cart-input {
    min-height: 80px;
    resize: vertical;
}

.pv-cart-select {
    appearance: none;
    -webkit-appearance: none;
    display: block;
    width: 100%;
    padding: 9px 32px 9px 14px;
    font-size: 14px;
    color: var(--pv-dark);
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%236c757d'/%3E%3C/svg%3E") no-repeat right 10px center;
    border: 1px solid var(--pv-border);
    border-radius: var(--pv-radius-sm);
    transition: var(--pv-transition);
}

.pv-cart-select:focus {
    outline: none;
    border-color: var(--pv-blue);
    box-shadow: 0 0 0 3px rgba(63, 114, 180, 0.12);
}

.pv-cart-label {
    font-weight: 600;
    font-size: 13px;
    color: var(--pv-muted);
    margin-bottom: 4px;
    display: block;
}

/* ---------- CHECKBOX ---------- */

.pv-cart-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 12px;
}

.pv-cart-checkbox input[type="checkbox"] {
    margin-top: 3px;
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    accent-color: var(--pv-blue);
}

.pv-cart-checkbox label {
    font-size: 13px;
    color: var(--pv-dark);
    line-height: 1.5;
    cursor: pointer;
    margin-bottom: 0;
}

/* ---------- DATA ROWS (koszyk3 customer info) ---------- */

.pv-cart-data-section {
    margin-bottom: 24px;
}

.pv-cart-data-row {
    display: flex;
    align-items: baseline;
    padding: 10px 0;
    border-bottom: 1px solid var(--pv-border);
}

.pv-cart-data-row:nth-child(even) {
    background: var(--pv-light);
    padding-left: 12px;
    padding-right: 12px;
    border-radius: 4px;
}

.pv-cart-data-label {
    width: 180px;
    flex-shrink: 0;
    font-weight: 600;
    font-size: 13px;
    color: var(--pv-muted);
}

.pv-cart-data-value {
    font-weight: 700;
    font-size: 14px;
    color: var(--pv-dark);
}

/* ---------- ACTIONS (buttons row) ---------- */

.pv-cart-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 24px;
}

.pv-cta-btn--outline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: 700;
    color: var(--pv-blue);
    background: transparent;
    border: 2px solid var(--pv-blue);
    border-radius: var(--pv-radius-sm);
    cursor: pointer;
    transition: var(--pv-transition);
    text-decoration: none;
    text-transform: none;
    letter-spacing: 0.3px;
}

.pv-cta-btn--outline:hover {
    background: var(--pv-blue);
    color: #fff;
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(63, 114, 180, 0.4);
}

.pv-cta-btn--outline:active {
    transform: translateY(0);
}

/* ---------- SUCCESS PAGE (koszyk4) ---------- */

.pv-cart-success {
    text-align: center;
    padding: 40px 0;
}

.pv-cart-success-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--pv-green);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    margin-bottom: 16px;
}

.pv-cart-success-message {
    max-width: 600px;
    margin: 0 auto;
    font-size: 15px;
    line-height: 1.7;
    color: var(--pv-dark);
}

.pv-cart-success-message p {
    margin-bottom: 16px;
}

/* ---------- EMPTY CART ---------- */

.pv-cart-empty {
    text-align: center;
    padding: 48px 0;
}

.pv-cart-empty h5 {
    color: var(--pv-muted);
    font-weight: 600;
    margin-bottom: 20px;
}

/* ---------- CART RESPONSIVE ---------- */

@media (max-width: 767px) {
    .pv-cart-stepper {
        gap: 0;
        padding: 12px 0;
        flex-wrap: wrap;
        justify-content: center;
    }

    .pv-cart-step {
        font-size: 11px;
    }

    .pv-cart-step-number {
        width: 24px;
        height: 24px;
        font-size: 11px;
    }

    .pv-cart-step-line {
        width: 20px;
        margin: 0 6px;
    }

    .pv-cart-step-label {
        display: none;
    }

    .pv-cart-item {
        flex-wrap: wrap;
        gap: 12px;
    }

    .pv-cart-item-img {
        width: 56px;
        height: 78px;
    }

    .pv-cart-item-name {
        flex: 1 1 calc(100% - 76px);
    }

    .pv-cart-item-values {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        gap: 12px;
    }

    .pv-cart-actions {
        flex-direction: column;
        gap: 12px;
    }

    .pv-cart-actions .pv-cta-btn,
    .pv-cart-actions .pv-cta-btn--outline {
        width: 100%;
        text-align: center;
        justify-content: center;
    }

    .pv-cart-data-row {
        flex-direction: column;
        gap: 2px;
    }

    .pv-cart-data-label {
        width: 100%;
    }

    .pv-cart-summary-total {
        font-size: 22px;
    }
}

@media (max-width: 575px) {
    .pv-cart-option {
        padding: 10px 12px;
    }
}

/* ---------- CART PRINT ---------- */

@media print {
    .pv-cart-stepper,
    .pv-cart-actions,
    .pv-cart-coupon,
    .pv-cart-remove {
        display: none !important;
    }
}

/* ==========================================================================
   TOAST NOTIFICATION — pv-toast-* prefix
   "Dodano do koszyka" bottom-right toast with product thumbnail
   ========================================================================== */

.pv-toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 380px;
    max-width: calc(100vw - 32px);
    background: #fff;
    border-radius: var(--pv-radius);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18);
    z-index: 9999;
    overflow: hidden;
    animation: pvToastSlideIn 0.35s ease forwards;
}

.pv-toast--hiding {
    animation: pvToastSlideOut 0.3s ease forwards;
}

/* --- Header --- */
.pv-toast-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-bottom: 1px solid var(--pv-border);
}

.pv-toast-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 700;
    color: var(--pv-green-dark);
}

.pv-toast-header-left i {
    font-size: 16px;
}

.pv-toast--error .pv-toast-header-left {
    color: #dc3545;
}

.pv-toast--info .pv-toast-header-left {
    color: var(--pv-blue);
}

.pv-toast--remove .pv-toast-header-left {
    color: var(--pv-muted);
}

.pv-toast-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: none;
    background: transparent;
    color: var(--pv-muted);
    font-size: 18px;
    cursor: pointer;
    border-radius: 50%;
    transition: var(--pv-transition);
    line-height: 1;
}

.pv-toast-close:hover {
    background: var(--pv-light);
    color: var(--pv-dark);
}

/* --- Body (product info) --- */
.pv-toast-body {
    display: flex;
    gap: 12px;
    padding: 14px 16px;
}

.pv-toast-img {
    width: 64px;
    height: 90px;
    flex-shrink: 0;
    border-radius: var(--pv-radius-sm);
    overflow: hidden;
    background: var(--pv-light);
    display: flex;
    align-items: center;
    justify-content: center;
}

.pv-toast-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.pv-toast-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    min-width: 0;
}

.pv-toast-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--pv-dark);
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.pv-toast-price {
    font-size: 13px;
    font-weight: 700;
    color: var(--pv-muted);
}

/* --- Actions --- */
.pv-toast-actions {
    padding: 0 16px 14px;
}

.pv-toast-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 9px 20px;
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    background: var(--pv-blue);
    border: none;
    border-radius: var(--pv-radius-sm);
    cursor: pointer;
    transition: var(--pv-transition);
    text-decoration: none;
}

.pv-toast-btn:hover {
    background: var(--pv-blue-dark);
    color: #fff;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(63, 114, 180, 0.3);
}

/* --- Simple text toast (errors/info) --- */
.pv-toast-text {
    padding: 14px 16px;
    font-size: 14px;
    color: var(--pv-dark);
    line-height: 1.5;
}

/* --- Progress bar --- */
.pv-toast-progress {
    height: 3px;
    background: var(--pv-green);
    animation: pvToastProgress 5s linear forwards;
}

.pv-toast--error .pv-toast-progress {
    background: #dc3545;
}

.pv-toast--info .pv-toast-progress {
    background: var(--pv-blue);
}

.pv-toast--remove .pv-toast-progress {
    background: var(--pv-muted);
}

/* --- Animations --- */
@keyframes pvToastSlideIn {
    from { transform: translateY(calc(100% + 24px)); opacity: 0; }
    to   { transform: translateY(0); opacity: 1; }
}

@keyframes pvToastSlideOut {
    from { transform: translateY(0); opacity: 1; }
    to   { transform: translateY(calc(100% + 24px)); opacity: 0; }
}

@keyframes pvToastProgress {
    from { width: 100%; }
    to   { width: 0%; }
}

/* --- Responsive --- */
@media (max-width: 575px) {
    .pv-toast {
        bottom: 0;
        right: 0;
        left: 0;
        width: 100%;
        max-width: 100%;
        border-radius: var(--pv-radius) var(--pv-radius) 0 0;
    }
}

/* --- Print --- */
@media print {
    .pv-toast { display: none !important; }
}
