/* ─── Heart Button on Product Cards ───────────────────────── */

.woaly-wishlist-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 3;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    cursor: pointer;
    color: #242638;
    transition: background 0.2s, transform 0.15s;
    padding: 0;
}

.woaly-wishlist-btn:hover {
    background: rgba(255, 255, 255, 1);
    transform: scale(1.08);
}

.woaly-wishlist-btn svg {
    width: 18px;
    height: 18px;
    transition: fill 0.2s, stroke 0.2s;
    fill: none;
}

.woaly-wishlist-btn:hover svg path {
    fill: rgba(231, 76, 60, 0.15);
}

.woaly-wishlist-btn.is-wishlisted svg path {
    fill: #e74c3c;
    stroke: #e74c3c;
}

.woaly-wishlist-btn.is-wishlisted:hover svg path {
    fill: #c0392b;
    stroke: #c0392b;
}

/* ─── Heart on Single Product ─────────────────────────────── */

.woaly-wishlist-single {
    display: inline-block;
    margin-bottom: 8px;
}

.woaly-wishlist-single .woaly-wishlist-btn {
    position: relative;
    top: auto;
    right: auto;
    width: 40px;
    height: 40px;
    background: #F2F4F8;
    backdrop-filter: none;
}

.woaly-wishlist-single .woaly-wishlist-btn:hover {
    background: #E8EBF0;
}

.woaly-wishlist-single .woaly-wishlist-btn svg {
    width: 20px;
    height: 20px;
}

/* ─── Wishlist Count Badge ────────────────────────────────── */

.woaly-wishlist-link {
    position: relative;
}

.woaly-wishlist-count {
    display: flex;
    position: absolute;
    left: -2px;
    top: 1px;
    border-radius: 40px;
    border: 1.6px solid #fff;
    background: var(--primary-color, #242638);
    color: white;
    width: 18px;
    height: 18px;
    justify-content: center;
    align-items: center;
    font-size: 11px;
    font-weight: bold;
}

/* ─── Heart Pop Animation ─────────────────────────────────── */

@keyframes woaly-heart-pop {
    0%   { transform: scale(1); }
    30%  { transform: scale(1.3); }
    60%  { transform: scale(0.9); }
    100% { transform: scale(1); }
}

.woaly-heart-pop {
    animation: woaly-heart-pop 0.4s ease;
}

/* ─── Toast Notification ──────────────────────────────────── */

.woaly-wishlist-toast {
    position: fixed;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: #242638;
    color: #fff;
    padding: 12px 24px;
    border-radius: 100px;
    font-size: 14px;
    font-weight: 500;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s, transform 0.3s;
    pointer-events: none;
    white-space: nowrap;
}

.woaly-wishlist-toast.is-visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ─── Login Modal ─────────────────────────────────────────── */

.woaly-wishlist-login-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.woaly-wishlist-login-modal.is-visible {
    opacity: 1;
}

.woaly-wishlist-login-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.woaly-wishlist-login-card {
    position: relative;
    background: #fff;
    border-radius: 20px;
    padding: 40px 32px 32px;
    max-width: 380px;
    width: 90%;
    text-align: center;
    transform: translateY(20px);
    transition: transform 0.3s;
}

.woaly-wishlist-login-modal.is-visible .woaly-wishlist-login-card {
    transform: translateY(0);
}

.woaly-wishlist-login-card svg {
    margin-bottom: 16px;
}

.woaly-wishlist-login-card h3 {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 8px;
    color: #242638;
}

.woaly-wishlist-login-card p {
    font-size: 14px;
    color: #666;
    margin: 0 0 24px;
    line-height: 1.5;
}

.woaly-wishlist-login-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.woaly-wishlist-login-btn {
    display: block;
    background: #242638;
    color: #fff;
    padding: 14px 24px;
    border-radius: 100px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s;
}

.woaly-wishlist-login-btn:hover {
    background: #3a3c52;
    color: #fff;
}

.woaly-wishlist-login-dismiss {
    background: none;
    border: none;
    color: #999;
    font-size: 14px;
    cursor: pointer;
    padding: 8px;
}

.woaly-wishlist-login-dismiss:hover {
    color: #666;
}

/* ─── Wishlist Page ───────────────────────────────────────── */

.woaly-wishlist-page h2 {
    font-size: 22px;
    font-weight: 600;
    margin-bottom: 24px;
}

.woaly-wishlist-empty {
    text-align: center;
    padding: 60px 20px;
}

.woaly-wishlist-empty svg {
    margin-bottom: 16px;
    opacity: 0.4;
}

.woaly-wishlist-empty p {
    font-size: 16px;
    color: #999;
    margin: 0 0 24px;
}

.woaly-wishlist-cta {
    display: inline-block;
    background: #242638;
    color: #fff;
    padding: 14px 32px;
    border-radius: 100px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s;
}

.woaly-wishlist-cta:hover {
    background: #3a3c52;
    color: #fff;
}

/* ─── Responsive ──────────────────────────────────────────── */

@media (max-width: 768px) {
    .woaly-wishlist-btn {
        width: 32px;
        height: 32px;
        top: 8px;
        right: 8px;
    }

    .woaly-wishlist-btn svg {
        width: 16px;
        height: 16px;
    }

    .woaly-wishlist-toast {
        bottom: 80px;
    }

    .woaly-wishlist-single .woaly-wishlist-btn {
        width: 36px;
        height: 36px;
    }
}

/* ─── Tapbar badge position override ──────────────────────── */

.tapbar-mobile .woaly-wishlist-count {
    left: 22px !important;
}
