.wrp-my-points {
    background: #f1f2f6;
    padding: 10px 15px;
    border-radius: 5px;
    display: inline-block;
    font-family: inherit;
    color: #2d3436;
    border: 1px solid #dfe6e9;
}

.wrp-my-points strong {
    color: var(--wrp-primary, #6c5ce7);
    font-weight: bold;
}

/* Toast Notifications */
.wrp-toast {
    visibility: hidden;
    min-width: 250px;
    background-color: #333;
    color: #fff;
    text-align: center;
    border-radius: 4px;
    padding: 16px;
    position: fixed;
    z-index: 9999;
    left: 50%;
    bottom: 30px;
    transform: translateX(-50%);
    font-size: 16px;
}

.wrp-toast.show {
    visibility: visible;
    -webkit-animation: fadein 0.5s, fadeout 0.5s 2.5s;
    animation: fadein 0.5s, fadeout 0.5s 2.5s;
}

@-webkit-keyframes fadein {
    from {
        bottom: 0;
        opacity: 0;
    }

    to {
        bottom: 30px;
        opacity: 1;
    }
}

@keyframes fadein {
    from {
        bottom: 0;
        opacity: 0;
    }

    to {
        bottom: 30px;
        opacity: 1;
    }
}

@-webkit-keyframes fadeout {
    from {
        bottom: 30px;
        opacity: 1;
    }

    to {
        bottom: 0;
        opacity: 0;
    }
}

@keyframes fadeout {
    from {
        bottom: 30px;
        opacity: 1;
    }

    to {
        bottom: 0;
        opacity: 0;
    }
}

/* My Account Dashboard */
.wrp-my-account-dashboard {
    margin-top: 20px;
}

.wrp-dashboard-header {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.wrp-balance-card,
.wrp-rank-card {
    background: #fff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    flex: 1;
    text-align: center;
    border: 1px solid #eee;
}

.wrp-points-big {
    font-size: 36px;
    font-weight: bold;
    color: var(--wrp-primary, #6c5ce7);
    margin-top: 10px;
}

.wrp-points-big span {
    font-size: 16px;
    color: #b2bec3;
}

.wrp-rank-badge {
    display: inline-block;
    padding: 5px 15px;
    border-radius: 20px;
    background: #dfe6e9;
    color: #2d3436;
    font-weight: bold;
    margin-top: 10px;
    text-transform: uppercase;
}

.wrp-rank-gold {
    background: #ffeaa7;
    color: #d35400;
}

.wrp-rank-silver {
    background: #dfe6e9;
    color: #2d3436;
}

.wrp-rank-bronze {
    background: #fab1a0;
    color: #c0392b;
}

.wrp-referral-section {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 30px;
    border: 1px dashed var(--wrp-primary, #6c5ce7);
}

.wrp-copy-link {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.wrp-copy-link input {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    width: 100%;
}

.wrp-history-section table {
    width: 100%;
    border-collapse: collapse;
}

.wrp-history-section th,
.wrp-history-section td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.wrp-positive {
    color: #00b894;
    font-weight: bold;
}

.wrp-negative {
    color: #d63031;
    font-weight: bold;
}

/* (Guest Notification Bar styles are defined once, further below.) */
.wrp-my-account-dashboard {
    margin-top: 20px;
}

.wrp-dashboard-header {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.wrp-balance-card,
.wrp-rank-card {
    background: #fff;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    flex: 1;
    text-align: center;
    border: 1px solid #eee;
}

.wrp-points-big {
    font-size: 36px;
    font-weight: bold;
    color: var(--wrp-primary, #6c5ce7);
    margin-top: 10px;
}

.wrp-points-big span {
    font-size: 16px;
    color: #b2bec3;
}

.wrp-rank-badge {
    display: inline-block;
    padding: 5px 15px;
    border-radius: 20px;
    background: #dfe6e9;
    color: #2d3436;
    font-weight: bold;
    margin-top: 10px;
    text-transform: uppercase;
}

.wrp-rank-gold {
    background: #ffeaa7;
    color: #d35400;
}

.wrp-rank-silver {
    background: #dfe6e9;
    color: #2d3436;
}

.wrp-rank-bronze {
    background: #fab1a0;
    color: #c0392b;
}

.wrp-referral-section {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 30px;
    border: 1px dashed var(--wrp-primary, #6c5ce7);
}

.wrp-copy-link {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.wrp-copy-link input {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    width: 100%;
}

.wrp-history-section table {
    width: 100%;
    border-collapse: collapse;
}

.wrp-history-section th,
.wrp-history-section td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.wrp-positive {
    color: #00b894;
    font-weight: bold;
}

.wrp-negative {
    color: #d63031;
    font-weight: bold;
}

/* Guest Notification Bar - Premium Redesign */
.wrp-guest-notification {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 600px;
    background: linear-gradient(135deg, #2d3436 0%, #000000 100%);
    color: #fff;
    padding: 15px 20px;
    z-index: 99999;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    border-radius: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    animation: wrpSlideUp 0.5s ease-out forwards;
}

@keyframes wrpSlideUp {
    from {
        bottom: -100px;
        opacity: 0;
    }

    to {
        bottom: 20px;
        opacity: 1;
    }
}

.wrp-notification-content {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

.wrp-notification-icon {
    background: rgba(255, 255, 255, 0.1);
    padding: 10px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffd700;
    /* Gold color for the gift icon */
}

.wrp-notification-message {
    flex: 1 1 auto;
    min-width: 0;            /* allow text to use available room instead of wrapping word-by-word */
    display: flex;
    flex-direction: column;
}

.wrp-notification-title {
    font-weight: bold;
    font-size: 14px;
    color: #ffd700;
    margin-bottom: 2px;
}

.wrp-notification-text {
    font-size: 13px;
    color: #dfe6e9;
    line-height: 1.3;
}

.wrp-notification-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 0 0 auto;          /* actions keep their size; text column flexes instead */
}

/* Defensive resets: stop the active theme's global button styles from
   inflating our notification buttons (oversized padding / radius / bg). */
.wrp-notification-button {
    background: linear-gradient(to right, var(--wrp-primary, #6c5ce7), #a29bfe) !important;
    color: #fff !important;
    padding: 9px 18px !important;
    margin: 0 !important;
    border: none !important;
    border-radius: 50px !important;
    text-decoration: none;
    font-weight: 700;
    font-size: 13px;
    line-height: 1.2;
    width: auto !important;
    transition: transform 0.2s, box-shadow 0.2s;
    white-space: nowrap;
    box-shadow: 0 4px 15px rgba(108, 92, 231, 0.3);
}

.wrp-notification-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(108, 92, 231, 0.4);
    color: #fff !important;
}

.wrp-dismiss-button {
    background: rgba(255, 255, 255, 0.12) !important;
    border: none !important;
    color: #fff;
    font-size: 18px;
    cursor: pointer;
    padding: 0 !important;
    margin: 0 !important;
    width: 34px;
    height: 34px;
    min-width: 34px;         /* keep a perfect circle even with theme button resets */
    border-radius: 50% !important;
    line-height: 1;
    transition: background 0.3s, color 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
}

.wrp-dismiss-button:hover {
    background: rgba(255, 255, 255, 0.25) !important;
    color: #fff;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .wrp-dashboard-header {
        flex-direction: column;
        gap: 15px;
    }
    
    .wrp-copy-link {
        flex-direction: column;
        gap: 10px;
    }
    
    .wrp-copy-link input,
    .wrp-copy-link button {
        width: 100%;
        text-align: center;
    }
}

@media (max-width: 600px) {
    .wrp-guest-notification {
        width: calc(100% - 20px);
        bottom: 10px;
        padding: 14px 16px;
    }

    .wrp-notification-content {
        flex-wrap: wrap;
        gap: 12px;
    }

    /* Icon + text share the top row; CTA + dismiss share the bottom row. */
    .wrp-notification-icon {
        flex: 0 0 auto;
    }

    .wrp-notification-message {
        flex: 1 1 0;
        min-width: 0;
        text-align: start;
    }

    .wrp-notification-title {
        font-size: 14px;
    }

    .wrp-notification-text {
        font-size: 12.5px;
    }

    .wrp-notification-actions {
        width: 100%;
        justify-content: flex-end;
        order: 3;              /* force actions onto their own row below the message */
    }

    .wrp-notification-button {
        flex: 1 1 auto;
        text-align: center;
    }
}

@media (max-width: 360px) {
    .wrp-notification-icon { display: none; }   /* reclaim space on very narrow phones */
}

/* Remove Discount Button */
.wrp-remove-discount {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    font-size: 24px;
    line-height: 1;
    font-weight: bold;
    color: #a00 !important;
    text-decoration: none !important;
    margin-left: 8px;
    border-radius: 50%;
    transition: all 0.2s ease;
    cursor: pointer;
    vertical-align: middle;
    background: rgba(170, 0, 0, 0.1);
    border: 1px solid #a00;
}

.wrp-remove-discount:hover {
    background-color: #a00;
    color: #fff !important;
    transform: scale(1.2);
    border-color: #a00;
}

.wrp-remove-discount:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(170, 0, 0, 0.3);
}

.wrp-remove-discount:active {
    transform: scale(1.1);
}
/* --- RTL Support --- */
body.rtl .wrp-history-section th, body.rtl .wrp-history-section td { text-align: right; }

body.rtl .wrp-redemption-form { border-left: none !important; border-right: 5px solid var(--wrp-primary, #6c5ce7); }

body.rtl .wrp-remove-discount { margin-left: 0; margin-right: 8px; }

body.rtl .wrp-dismiss-button { margin-left: 0; margin-right: 10px; }

/* --- Product earning message (replaces dashicons + inline style for LSC safety) --- */
.wrp-product-message {
    color: var(--wrp-primary, #6c5ce7);
    margin: 10px 0;
    font-weight: bold;
    display: block;
}
.wrp-product-message .wrp-product-icon {
    display: inline-block;
    margin-inline-end: 6px;
    vertical-align: middle;
}

/* --- Redemption Form (moved from inline <style> for cache-plugin compatibility) --- */
.wrp-redemption-form {
    border-left: 5px solid var(--wrp-primary, #6c5ce7) !important;
}

.wrp-redemption-form h3::before {
    color: var(--wrp-primary, #6c5ce7);
}

.wrp-redeem-input {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.wrp-redeem-input input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.wrp-redeem-input button {
    background: var(--wrp-primary, #6c5ce7) !important;
    color: #fff !important;
    border: none !important;
    cursor: pointer;
}

.wrp-redeem-input button:hover {
    opacity: 0.9;
}

.wrp-redeem-input button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

#wrp-redemption-message {
    margin-top: 10px;
    font-size: 14px;
}
#wrp-redemption-message .wrp-msg-success { color: #27ae60; }
#wrp-redemption-message .wrp-msg-error { color: #e74c3c; }

