/* Product to Pay Example Widget */
.wr-ptpe-app {
    position: relative;
    width: 100%;
    margin: 0 auto;
    padding: 24px 16px;
    min-height: 100vh;
    overflow: hidden;
}

.wr-ptpe-listings-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 16px;
    color: #fff;
    opacity: 0;
    transform: translateY(20px);
    animation: wrPtpeFadeInDown 0.6s ease forwards;
}

@keyframes wrPtpeFadeInDown {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.wr-ptpe-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

/* Card entrance animation */
.wr-ptpe-card {
    position: relative;
    border-radius: 16px;
    cursor: pointer;
    transition: transform 0.3s ease, opacity 0.4s ease;
    overflow: visible;
    opacity: 0;
    transform: translateY(100vh);
}

.wr-ptpe-card.entered {
    opacity: 1;
    transform: translateY(0);
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.6s ease, filter 0.4s ease;
}

.wr-ptpe-card-inner {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    background: #1a1a1a;
    z-index: 2;
}

.wr-ptpe-card-image {
    width: 100%;
    aspect-ratio: 1;
    overflow: hidden;
}

.wr-ptpe-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.wr-ptpe-card-image-placeholder {
    width: 100%;
    aspect-ratio: 1;
    background: linear-gradient(135deg, #2a2a2a, #1a1a1a);
}

.wr-ptpe-card-content {
    padding: 10px 12px 12px;
}

.wr-ptpe-card-title {
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 4px;
}

.wr-ptpe-card-subtitle {
    font-size: 12px;
    color: #888;
}

.wr-ptpe-card-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    color: #fff;
    font-size: 10px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 20px;
    z-index: 3;
    letter-spacing: 0.3px;
}

/* Animated Border */
.wr-ptpe-card-border {
    position: absolute;
    inset: -2px;
    border-radius: 18px;
    background: linear-gradient(90deg, #6366f1, #8b5cf6, #a855f7, #6366f1);
    background-size: 300% 100%;
    opacity: 0;
    z-index: 1;
    animation: wrPtpeBorderRotate 2s linear infinite;
    transition: opacity 0.3s ease;
}

@keyframes wrPtpeBorderRotate {
    0% { background-position: 0% 50%; }
    100% { background-position: 300% 50%; }
}

/* Selection States */
.wr-ptpe-grid.has-selection .wr-ptpe-card {
    opacity: 0.25;
    filter: grayscale(0.3);
    pointer-events: none;
}

.wr-ptpe-grid.has-selection .wr-ptpe-card.selected {
    opacity: 1;
    filter: none;
    pointer-events: auto;
    transform: scale(1.02);
}

.wr-ptpe-grid.has-selection .wr-ptpe-card.selected .wr-ptpe-card-border {
    opacity: 1;
}

/* Bottom Sheet Overlay - SCOPED to widget */
.wr-ptpe-bottom-sheet-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 90;
    border-radius: inherit;
}

.wr-ptpe-bottom-sheet-overlay.show {
    opacity: 1;
    pointer-events: auto;
}

/* Bottom Sheet - SCOPED to widget */
.wr-ptpe-bottom-sheet {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: #1a1a1a;
    border-radius: 24px 24px 0 0;
    padding: 16px 20px 32px;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 100;
    margin: 0 auto;
}

.wr-ptpe-bottom-sheet.show {
    transform: translateY(0);
}

.wr-ptpe-bottom-sheet-handle {
    width: 40px;
    height: 4px;
    background: #444;
    border-radius: 2px;
    margin: 0 auto 20px;
}

.wr-ptpe-payment-group {
    margin-bottom: 16px;
}

.wr-ptpe-payment-group-title {
    font-size: 13px;
    color: #888;
    margin-bottom: 10px;
    font-weight: 400;
}

.wr-ptpe-payment-options {
    background: #252525;
    border-radius: 12px;
    padding: 8px 0;
}

.wr-ptpe-payment-option {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    font-size: 14px;
    color: #ccc;
    border-bottom: 1px solid #333;
}

.wr-ptpe-payment-option:last-child {
    border-bottom: none;
}

.wr-ptpe-payment-dot {
    color: #888;
    font-size: 16px;
    line-height: 1;
}

.wr-ptpe-pay-button {
    width: 100%;
    padding: 16px;
    margin-top: 8px;
    background: #fff;
    color: #0d0d0d;
    border: none;
    border-radius: 28px;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 0.5px;
    cursor: pointer;
    transition: transform 0.1s ease, opacity 0.2s ease;
}

.wr-ptpe-pay-button:active {
    transform: scale(0.97);
    opacity: 0.9;
}

::-webkit-scrollbar {
    display: none;
}

/* Elementor editor preview fixes */
.elementor-editor-active .wr-ptpe-card {
    opacity: 1;
    transform: translateY(0);
}