/* ===== UX ENHANCEMENTS: Wishlist, Recently Viewed, Quick Variant, Price Filter, Checkout Autofill ===== */

/* ── 1. Wishlist heart button on product cards ── */
.pg-img-wrap,
.single-product-wrap .product-image {
    position: relative;
}

.sh-wish-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 6;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    border: 1px solid rgba(248, 14, 99, 0.16);
    background: rgba(255, 255, 255, 0.92);
    color: #94a3b8;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 13px;
    transition: transform .18s, color .18s, background .18s, border-color .18s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    padding: 0;
}

.sh-wish-btn:hover {
    transform: scale(1.1);
    color: #f80e63;
    border-color: #f80e63;
}

.sh-wish-btn.is-liked {
    background: #fff0f5;
    color: #f80e63;
    border-color: #f80e63;
}

/* Detail page wishlist button */
.sh-wish-detail-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: 50px;
    border: 1.5px solid #f9b8d0;
    background: #fff;
    color: #f80e63;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all .18s;
    margin-top: 10px;
}

.sh-wish-detail-btn.is-liked,
.sh-wish-detail-btn:hover {
    background: #fff0f5;
    border-color: #f80e63;
}

/* Floating Wishlist Trigger (left bottom, compact, shown when count > 0) */
.sh-wish-fab {
    position: fixed;
    left: 16px;
    bottom: 20px;
    z-index: 9990;
    display: none;
    align-items: center;
    gap: 6px;
    padding: 9px 14px;
    border-radius: 50px;
    background: #fff;
    border: 1.5px solid #f9b8d0;
    color: #f80e63;
    font-size: 13px;
    font-weight: 700;
    box-shadow: 0 4px 16px rgba(248, 14, 99, 0.18);
    cursor: pointer;
    transition: transform .2s, box-shadow .2s;
}

.sh-wish-fab.has-items {
    display: inline-flex;
}

.sh-wish-fab:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(248, 14, 99, 0.28);
}

.sh-wish-fab-count {
    background: #f80e63;
    color: #fff;
    border-radius: 50px;
    padding: 1px 7px;
    font-size: 11px;
    font-weight: 800;
}

@media (max-width: 991px) {
    .sh-wish-fab {
        bottom: 76px;
        left: 12px;
        padding: 7px 12px;
        font-size: 12px;
    }
}

/* ── 2. Wishlist & Variant Modal / Drawer ── */
.sh-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    z-index: 10040;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

.sh-overlay.open {
    display: flex;
}

.sh-drawer {
    position: fixed;
    top: 0;
    right: -380px;
    width: 100%;
    max-width: 360px;
    height: 100vh;
    background: #fff;
    z-index: 10050;
    box-shadow: -8px 0 30px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    transition: right .25s ease;
}

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

.sh-drawer-head {
    padding: 16px 18px;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sh-drawer-head h5 {
    margin: 0;
    font-size: 16px;
    font-weight: 800;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 8px;
}

.sh-drawer-close {
    background: none;
    border: none;
    font-size: 22px;
    line-height: 1;
    color: #64748b;
    cursor: pointer;
    padding: 4px 8px;
}

.sh-drawer-body {
    flex: 1;
    overflow-y: auto;
    padding: 12px 16px;
}

.sh-wish-row {
    display: flex;
    gap: 10px;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #f1f5f9;
}

.sh-wish-row img {
    width: 58px;
    height: 58px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
    border: 1px solid #f1f5f9;
}

.sh-wish-info {
    flex: 1;
    min-width: 0;
}

.sh-wish-name {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #1e293b;
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sh-wish-price {
    font-size: 13px;
    font-weight: 700;
    color: #f80e63;
    margin-top: 2px;
}

.sh-wish-actions {
    display: flex;
    gap: 6px;
    margin-top: 6px;
}

.sh-btn-sm {
    border: none;
    border-radius: 6px;
    padding: 4px 10px;
    font-size: 11.5px;
    font-weight: 600;
    cursor: pointer;
}

.sh-btn-add {
    background: #f80e63;
    color: #fff;
}

.sh-btn-del {
    background: #f1f5f9;
    color: #64748b;
}

/* Quick-select Variant Modal */
.sh-variant-card {
    background: #fff;
    border-radius: 16px;
    width: 100%;
    max-width: 420px;
    padding: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
    position: relative;
}

.sh-variant-prod {
    display: flex;
    gap: 12px;
    align-items: center;
    padding-right: 32px;
    padding-bottom: 14px;
    border-bottom: 1px solid #f1f5f9;
}

.sh-variant-prod img {
    width: 68px;
    height: 68px;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid #f1f5f9;
}

.sh-variant-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 12px 0 16px;
}

.sh-variant-chip {
    border: 1.5px solid #e2e8f0;
    background: #fff;
    border-radius: 8px;
    padding: 7px 12px;
    font-size: 13px;
    font-weight: 600;
    color: #334155;
    cursor: pointer;
    transition: all .15s;
}

.sh-variant-chip.active {
    border-color: #f80e63;
    background: #fff0f5;
    color: #f80e63;
}

.sh-variant-actions {
    display: flex;
    gap: 10px;
    align-items: stretch;
    margin-top: 4px;
}

.sh-variant-detail {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 11px 10px;
    border-radius: 50px;
    border: 1.5px solid #cbd5e1;
    background: #fff;
    color: #334155 !important;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none !important;
    white-space: nowrap;
    transition: all .15s;
}

.sh-variant-detail:hover {
    border-color: #f80e63;
    color: #f80e63 !important;
    background: #fff5f8;
}

.sh-variant-submit {
    flex: 2;
    padding: 12px 14px;
    border: none;
    border-radius: 50px;
    background: linear-gradient(135deg, #f80e63, #ff4d8d);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
}

/* ── 3. Recently Viewed Strip ── */
.sh-recent-section {
    margin: 24px 0 12px;
}

.sh-recent-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 12px;
}

.sh-recent-card {
    background: #fff;
    border: 1px solid #f1f5f9;
    border-radius: 12px;
    padding: 10px;
    text-decoration: none !important;
    transition: transform .18s, box-shadow .18s;
    display: block;
}

.sh-recent-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.07);
}

.sh-recent-card img {
    width: 100%;
    aspect-ratio: 1/1;
    object-fit: contain;
    border-radius: 8px;
    margin-bottom: 8px;
}

.sh-recent-name {
    font-size: 12.5px;
    font-weight: 600;
    color: #1e293b;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.35;
    min-height: 34px;
}

.sh-recent-price {
    font-size: 13.5px;
    font-weight: 800;
    color: #f80e63;
    margin-top: 4px;
}

@media (max-width: 575px) {
    .sh-recent-grid {
        display: flex;
        overflow-x: auto;
        gap: 10px;
        padding-bottom: 6px;
        scroll-snap-type: x mandatory;
    }
    .sh-recent-card {
        flex: 0 0 135px;
        scroll-snap-align: start;
    }
}

/* ── 4. Price Filter Chips on Category Page ── */
.sh-price-filter-bar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px dashed #e2e8f0;
}

.sh-price-chip {
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #334155;
    border-radius: 50px;
    padding: 5px 13px;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all .15s;
}

.sh-price-chip:hover {
    border-color: #f80e63;
    color: #f80e63;
}

.sh-price-chip.active {
    background: #f80e63;
    border-color: #f80e63;
    color: #fff;
}

.sh-filter-count {
    margin-left: auto;
    font-size: 12px;
    color: #64748b;
    font-weight: 600;
}

/* ── 5. Delivery Estimate & Discreet Checkout UI ── */
.sh-delivery-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fff5f8;
    border: 1px solid #fbcfe8;
    border-radius: 10px;
    padding: 9px 12px;
    font-size: 12.5px;
    color: #831843;
    margin-top: 12px;
}

.sh-autofill-bar {
    display: none;
    align-items: center;
    justify-content: space-between;
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    color: #065f46;
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 12.5px;
    margin-bottom: 12px;
}

.sh-autofill-clear {
    background: none;
    border: none;
    color: #dc2626;
    font-weight: 700;
    font-size: 12px;
    cursor: pointer;
    text-decoration: underline;
}

.sh-discreet-box {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: #fff5f8;
    border: 1.5px solid #f9a8d4;
    border-radius: 12px;
    padding: 11px 14px;
    margin-top: 12px;
    cursor: pointer;
}

.sh-discreet-box input {
    margin-top: 3px;
    accent-color: #f80e63;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.sh-discreet-title {
    font-size: 13px;
    font-weight: 700;
    color: #831843;
}

.sh-discreet-sub {
    font-size: 11.5px;
    color: #9d174d;
    margin-top: 2px;
}
