/* ================================================================
   Wishlist Marketing — urgency toast, attention pulse, badges
   ================================================================ */

/* ── Live dot ──────────────────────────────────────────────────── */
@keyframes cwp-blink {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.4; transform: scale(0.7); }
}

.cwp-dot-live {
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #22c55e;
    margin-right: 5px;
    vertical-align: middle;
    animation: cwp-blink 1.4s ease-in-out infinite;
    flex-shrink: 0;
}

/* ── Urgency Toast ─────────────────────────────────────────────── */
/* Slides up from bottom-left. No borders, pure shadow + blur. */
.cwp-toast {
    position: fixed;
    bottom: 28px;
    left: 24px;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    gap: 0;
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(18px) saturate(180%);
    -webkit-backdrop-filter: blur(18px) saturate(180%);
    border: none;
    border-radius: 16px;
    padding: 0;
    width: 300px;
    box-shadow:
        0 2px 8px rgba(0,0,0,.06),
        0 12px 40px rgba(0,0,0,.12),
        0 0 0 0.5px rgba(0,0,0,.06);
    overflow: hidden;
    transform: translateY(20px);
    opacity: 0;
    transition:
        transform 0.45s cubic-bezier(0.34, 1.4, 0.64, 1),
        opacity 0.3s ease;
    pointer-events: none;
}

.cwp-toast--in {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.cwp-toast--out {
    transform: translateY(16px);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.28s ease, opacity 0.22s ease;
}

/* Progress bar — auto-dismisses visually */
.cwp-toast::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: #111;
    transform-origin: left;
    transform: scaleX(1);
    animation: cwp-toast-timer 8s linear forwards;
    border-radius: 0;
}

@keyframes cwp-toast-timer {
    from { transform: scaleX(1); }
    to   { transform: scaleX(0); }
}

/* Inner layout */
.cwp-toast-inner {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 14px 10px 14px;
}

.cwp-toast-img {
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    border-radius: 10px;
    overflow: hidden;
    background: #f0f0f0;
}

.cwp-toast-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.cwp-toast-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.cwp-toast-label {
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #999;
    margin-bottom: 1px;
}

.cwp-toast-name {
    font-size: 13px;
    font-weight: 700;
    color: #111;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2;
}

.cwp-toast-line {
    font-size: 11px;
    color: #555;
    display: flex;
    align-items: center;
    gap: 0;
    margin-top: 1px;
}

.cwp-toast-stock {
    font-size: 11px;
    color: #b45309;
    font-weight: 600;
    margin-top: 1px;
}

/* CTA row at bottom */
.cwp-toast-footer {
    display: flex;
    border-top: 1px solid rgba(0,0,0,.06);
    margin: 0;
}

.cwp-toast-cta {
    flex: 1;
    background: none;
    color: #111;
    border: none;
    padding: 11px 14px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    letter-spacing: 0.04em;
    text-align: center;
    transition: background 0.15s;
    white-space: nowrap;
}

.cwp-toast-cta:hover {
    background: rgba(0,0,0,.04);
}

.cwp-toast-dismiss {
    width: 44px;
    background: none;
    border: none;
    border-left: 1px solid rgba(0,0,0,.06);
    font-size: 13px;
    color: #bbb;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.15s, background 0.15s;
    flex-shrink: 0;
}

.cwp-toast-dismiss:hover {
    color: #555;
    background: rgba(0,0,0,.04);
}

/* Toggle jump animations removed — button stays still */

/* ── Live "X viewing" badge on panel items ─────────────────────── */
/* Sits inside .cwp-info, flows naturally below price */
.cwp-viewers {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 10px;
    color: #22c55e;
    font-weight: 600;
    letter-spacing: 0.02em;
    white-space: nowrap;
    margin-top: 2px;
    opacity: 0;
    animation: cwp-fadein 0.5s ease forwards;
}

@keyframes cwp-fadein {
    to { opacity: 1; }
}

/* ── "Items sell out fast" checkout bar ────────────────────────── */
#cwp-checkout-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 28px;
    height: 40px;
    background: #f9f9f6;
    border-top: 1px solid #f0f0f0;
    flex-shrink: 0;
    gap: 12px;
}

.cwp-bar-text {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    color: #666;
    letter-spacing: 0.02em;
}

.cwp-bar-text svg {
    flex-shrink: 0;
    color: #aaa;
}

.cwp-bar-cta {
    flex-shrink: 0;
    font-size: 11px;
    font-weight: 800;
    color: #111;
    text-decoration: none;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    border-bottom: 1px solid #111;
    padding-bottom: 1px;
    transition: opacity 0.15s;
}

.cwp-bar-cta:hover { opacity: 0.6; color: #111; }

/* ── Mobile adjustments ────────────────────────────────────────── */
@media (max-width: 600px) {
    .cwp-toast {
        left: 12px;
        right: 12px;
        max-width: none;
        bottom: 70px;
    }

    #cwp-checkout-bar {
        padding: 0 16px;
    }
}
