/**
 * Wishlist Styles
 * Heart icons, wishlist drawer, and related UI
 *
 * @package Qatarshoes
 * @since 2.1.0
 */

/* ========================================
   WISHLIST HEART ICON (on product cards)
   ======================================== */
.wishlist-heart {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.wishlist-heart:hover {
    background: #fff;
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.wishlist-heart svg {
    width: 18px;
    height: 18px;
    stroke: #666;
    stroke-width: 1.5;
    fill: none;
    transition: all 0.2s ease;
}

.wishlist-heart:hover svg {
    stroke: #e91e63;
}

.wishlist-heart.active svg {
    fill: #e91e63;
    stroke: #e91e63;
}

/* Animation on add */
.wishlist-heart.active {
    animation: heartPop 0.3s ease;
}

@keyframes heartPop {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}

/* ========================================
   WISHLIST DRAWER
   ======================================== */
.wishlist-drawer {
    position: fixed;
    top: 0;
    right: -420px;
    width: 420px;
    max-width: 90vw;
    height: 100vh;
    background: #fff;
    z-index: 99998;
    transition: right 0.3s ease;
    display: flex;
    flex-direction: column;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
}

.wishlist-drawer.open {
    right: 0;
}

.wishlist-drawer-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 99997;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.wishlist-drawer.open + .wishlist-drawer-backdrop,
.wishlist-drawer-backdrop.open {
    opacity: 1;
    visibility: visible;
}

/* Drawer Header */
.wishlist-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid #eee;
}

.wishlist-drawer-header h3 {
    font-family: 'Canela Text', Georgia, serif;
    font-size: 20px;
    font-weight: 400;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.wishlist-drawer-header h3 svg {
    width: 22px;
    height: 22px;
    fill: #e91e63;
    stroke: none;
}

.wishlist-drawer-close {
    width: 36px;
    height: 36px;
    background: none;
    border: none;
    cursor: pointer;
    color: #666;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s;
}

.wishlist-drawer-close:hover {
    background: #f5f5f5;
    color: #1a1a1a;
}

/* Drawer Items */
.wishlist-drawer-items {
    flex: 1;
    overflow-y: auto;
    padding: 0;
}

.wishlist-drawer-item {
    display: flex;
    gap: 16px;
    padding: 20px 24px;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s;
}

.wishlist-drawer-item:hover {
    background: #fafafa;
}

.wishlist-item-image {
    width: 80px;
    height: 100px;
    flex-shrink: 0;
    overflow: hidden;
    background: #f5f5f5;
}

.wishlist-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.wishlist-item-image a {
    display: block;
}

.wishlist-item-details {
    flex: 1;
    min-width: 0;
}

.wishlist-item-vendor {
    font-size: 11px;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.wishlist-item-title {
    font-size: 14px;
    font-weight: 500;
    color: #1a1a1a;
    margin-bottom: 6px;
    line-height: 1.4;
}

.wishlist-item-title a {
    color: inherit;
    text-decoration: none;
}

.wishlist-item-title a:hover {
    text-decoration: underline;
}

.wishlist-item-price {
    font-size: 14px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 12px;
}

.wishlist-item-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.wishlist-add-to-cart-btn {
    padding: 8px 16px;
    background: #1a1a1a;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

.wishlist-add-to-cart-btn:hover {
    background: #333;
}

.wishlist-item-remove {
    background: none;
    border: none;
    color: #999;
    font-size: 12px;
    cursor: pointer;
    text-decoration: underline;
    padding: 0;
}

.wishlist-item-remove:hover {
    color: #e53935;
}

/* Empty State */
.wishlist-drawer-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 24px;
    text-align: center;
    color: #666;
}

.wishlist-drawer-empty svg {
    width: 64px;
    height: 64px;
    stroke: #ccc;
    fill: none;
    margin-bottom: 20px;
}

.wishlist-drawer-empty h4 {
    font-family: 'Canela Text', Georgia, serif;
    font-size: 18px;
    font-weight: 400;
    margin: 0 0 8px 0;
    color: #1a1a1a;
}

.wishlist-drawer-empty p {
    font-size: 14px;
    margin: 0;
    color: #888;
}

/* Drawer Footer */
.wishlist-drawer-footer {
    padding: 20px 24px;
    border-top: 1px solid #eee;
    background: #fafafa;
}

.wishlist-view-all-btn {
    display: block;
    /* width: 100%; */
    padding: 14px 24px;
    background: #1a1a1a;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    transition: background 0.2s;
}

.wishlist-view-all-btn:hover {
    background: #333;
    color: #fff;
}

/* ========================================
   WISHLIST COUNT BADGE
   ======================================== */
.wishlist-count {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 18px;
    height: 18px;
    background: #e91e63;
    color: #fff;
    font-size: 10px;
    font-weight: 600;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}

/* ========================================
   MOBILE ADJUSTMENTS
   ======================================== */
@media (max-width: 480px) {
    .wishlist-drawer {
        width: 85vw;
        right: -100vw;
    }

    .wishlist-drawer.open {
        right: 0;
    }

    .wishlist-heart {
        width: 32px;
        height: 32px;
        top: 8px;
        right: 8px;
    }

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

    .wishlist-drawer-item {
        padding: 16px 20px;
    }

    .wishlist-item-image {
        width: 70px;
        height: 90px;
    }
}

/* ========================================
   HEADER WISHLIST ICON
   ======================================== */
.header-wishlist-btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: none;
    border: none;
    cursor: pointer;
    color: inherit;
}

.header-wishlist-btn svg {
    width: 22px;
    height: 22px;
    stroke: currentColor;
    stroke-width: 1.5;
    fill: none;
}

.header-wishlist-btn .wishlist-count {
    top: 2px;
    right: 2px;
}

/* Desktop nav wishlist link */
.desktop-wishlist-link {
    display: flex;
    align-items: center;
    gap: 6px;
    position: relative;
    cursor: pointer;
    color: inherit;
    text-decoration: none;
}

.desktop-wishlist-link svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    stroke-width: 1.5;
    fill: none;
}

.desktop-wishlist-link span {
    font-size: 14px;
}
