/* ============================================================
   WC Simple Wishlist — wishlist.css
   ============================================================ */

/* ── Variables ── */
:root {
    --wcswl-red:        #27473A;
    --wcswl-red-light:  #fdecea;
    --wcswl-green:      #27ae60;
    --wcswl-gray:       #6c757d;
    --wcswl-border:     #e0e0e0;
    --wcswl-radius:     6px;
    --wcswl-shadow:     0 4px 20px rgba(0,0,0,0.12);
    --wcswl-primary:    #2c3e50;
    --wcswl-font:       inherit;
}

/* ============================================================
   Heart Button
   ============================================================ */
.wcswl-heart-btn {
    display:          inline-flex;
    align-items:      center;
    gap:              5px;
    background:       transparent;
    border:           1.5px solid var(--wcswl-border);
    border-radius:    var(--wcswl-radius);
    padding:          7px 12px;
    cursor:           pointer;
    font-size:        14px;
    color:            var(--wcswl-gray);
    transition:       all 0.25s ease;
    margin-top:       8px;
    line-height:      1;
}

.wcswl-heart-btn:hover {
    border-color: var(--wcswl-red);
    color:        var(--wcswl-red);
    background:   var(--wcswl-red-light);
}

/* Active (in wishlist) */
.wcswl-heart-btn.wcswl-active {
    border-color: var(--wcswl-red);
    color:        var(--wcswl-red);
    background:   var(--wcswl-red-light);
}

/* Heart icon */
.wcswl-heart-icon {
    font-size:   18px;
    line-height: 1;
    transition:  transform 0.2s ease;
}

.wcswl-heart-btn.wcswl-active .wcswl-heart-icon {
    content:   "♥";
    font-size: 18px;
}

/* Replace outline heart with filled when active */
.wcswl-heart-btn.wcswl-active .wcswl-heart-icon::before {
    content: "♥";
}

.wcswl-heart-btn:not(.wcswl-active) .wcswl-heart-icon::before {
    content: "♡ ";
}

.wcswl-heart-icon {
    font-size: 0; /* hide the HTML entity, use CSS pseudo */
}

/* Pulse animation on click */
@keyframes wcswl-pulse {
    0%   { transform: scale(1); }
    40%  { transform: scale(1.35); }
    100% { transform: scale(1); }
}
.wcswl-heart-btn.wcswl-pulse .wcswl-heart-icon {
    animation: wcswl-pulse 0.35s ease;
}

/* ============================================================
   Custom HTML Popup Modal
   ============================================================ */

/* ── Overlay / Backdrop ── */
#wcswl-modal-overlay {
    position:   fixed;
    inset:      0;
    background: rgba(0, 0, 0, 0.45);
    z-index:    99998;
    opacity:    0;
    transition: opacity 0.25s ease;
    pointer-events: none;
}

#wcswl-modal-overlay.wcswl-modal-visible {
    opacity:        1;
    pointer-events: auto;
}

/* ── Modal Box ── */
#wcswl-modal {
    position:      fixed;
    top:           50%;
    left:          50%;
    transform:     translate(-50%, -42%) scale(0.95);
    z-index:       99999;
    background:    #fff;
    border-radius: 14px;
    padding:       36px 32px 28px;
    width:         min(380px, calc(100vw - 32px));
    box-shadow:    0 20px 60px rgba(0,0,0,0.18);
    text-align:    center;
    opacity:       0;
    transition:    opacity 0.28s ease, transform 0.28s ease;
    pointer-events: none;
}

#wcswl-modal.wcswl-modal-visible {
    opacity:        1;
    transform:      translate(-50%, -50%) scale(1);
    pointer-events: auto;
}

/* ── Close (×) button ── */
#wcswl-modal-close {
    position:   absolute;
    top:        14px;
    right:      14px;
    background: #f0f0f0;
    border:     none;
    border-radius: 50%;
    width:      30px;
    height:     30px;
    display:    flex;
    align-items: center;
    justify-content: center;
    cursor:     pointer;
    padding:    0;
    color:      #666;
    transition: background 0.2s, color 0.2s;
    flex-shrink: 0;
}

#wcswl-modal-close:hover {
    background: #e0e0e0;
    color:      #222;
}

#wcswl-modal-close svg {
    width:  14px;
    height: 14px;
    display: block;
}

/* ── Icon circle ── */
#wcswl-modal-icon {
    width:         62px;
    height:        62px;
    border-radius: 50%;
    display:       flex;
    align-items:   center;
    justify-content: center;
    margin:        0 auto 18px;
    transition:    background 0.2s;
}

#wcswl-modal-icon svg {
    width:  30px;
    height: 30px;
    display: block;
}

/* ── Colour themes per type ── */

/* added — warm red (heart filled) */
#wcswl-modal[data-type="added"] #wcswl-modal-icon {
    background: #27473a36;
    color:      #27473A;
}
#wcswl-modal[data-type="added"] .wcswl-modal-action-btn {
    background: #27473A;
    color:      #fff !important;
}
#wcswl-modal[data-type="added"] .wcswl-modal-action-btn:hover {
    background: #103325;
}

/* removed — cool gray (heart outline) */
#wcswl-modal[data-type="removed"] #wcswl-modal-icon {
    background: #f0f0f0;
    color:      #6c757d;
}
#wcswl-modal[data-type="removed"] .wcswl-modal-action-btn {
    background: #6c757d;
    color:      #fff !important;
}

/* login — amber (lock) */
#wcswl-modal[data-type="login"] #wcswl-modal-icon {
    background: #103F3C30;
    color:      #103F3C;
}
#wcswl-modal[data-type="login"] .wcswl-modal-action-btn {
    background: #103F3C;
    color:      #fff !important;
}
#wcswl-modal[data-type="login"] .wcswl-modal-action-btn:hover {
    background: #103F3C;
}

/* info — blue */
#wcswl-modal[data-type="info"] #wcswl-modal-icon {
    background: rgb(39 71 58 / 30%);
    color:      #27473A;
}
#wcswl-modal[data-type="info"] .wcswl-modal-action-btn {
    background: #27473A;
    color:      #fff !important;
}
#wcswl-modal[data-type="info"] .wcswl-modal-action-btn:hover {
    background: #27473A;
}

/* error — deep red */
#wcswl-modal[data-type="error"] #wcswl-modal-icon {
    background: #fdecea;
    color:      #103325;
}
#wcswl-modal[data-type="error"] .wcswl-modal-action-btn {
    background: #103325;
    color:      #fff !important;
}

/* ── Message text ── */
#wcswl-modal-msg {
    font-size:   15px;
    line-height: 1.55;
    color:       #333;
    margin:      0 0 22px;
}

/* ── Action area ── */
#wcswl-modal-actions {
    display:    flex;
    gap:        10px;
    justify-content: center;
    flex-wrap:  wrap;
}

/* Primary action (e.g. View Wishlist / Login) */
.wcswl-modal-action-btn {
    display:       inline-block;
    padding:       10px 22px;
    border-radius: var(--wcswl-radius);
    font-size:     14px;
    font-weight:   600;
    text-decoration: none;
    border:        none;
    cursor:        pointer;
    transition:    background 0.2s, opacity 0.2s;
    white-space:   nowrap;
}

.wcswl-modal-action-btn:hover {
    opacity: 0.9;
}

/* Dismiss button */
.wcswl-modal-dismiss-btn {
    background: #DD2C2C !important;
    border: 1.5px solid #ddd;
    color: #fff;
    padding: 10px 20px;
    border-radius: var(--wcswl-radius);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: border-color 0.2s, color 0.2s;
    white-space: nowrap;
}

/*.wcswl-modal-dismiss-btn:hover {*/
/*    border-color: #aaa;*/
/*    color:        #333;*/
/*}*/

/* ── Mobile ── */
@media (max-width: 480px) {
    #wcswl-modal {
        padding: 28px 20px 22px;
    }

    #wcswl-modal-actions {
        flex-direction: column;
    }

    .wcswl-modal-action-btn,
    .wcswl-modal-dismiss-btn {
        width:      100%;
        text-align: center;
    }
}

/* ============================================================
   Login Notice
   ============================================================ */
.wcswl-login-notice {
    text-align:   center;
    padding:      40px 20px;
}

.wcswl-login-notice p {
    font-size: 16px;
    color:     var(--wcswl-gray);
}

/* ============================================================
   Empty Wishlist
   ============================================================ */
.wcswl-empty {
    text-align: center;
    padding:    50px 20px;
}

.wcswl-empty p {
    font-size:   18px;
    color:       var(--wcswl-gray);
    margin-bottom: 16px;
}

/* ============================================================
   Wishlist Page — Wrapper & Actions
   ============================================================ */
.wcswl-page-wrap {
    max-width: 100%;
    overflow-x: auto;
    background: #fff;
    padding: 30px; 
    border-radius: 9px;
}

.wcswl-actions-top {
    display:         flex;
    align-items:     center;
    justify-content: space-between;
    flex-wrap:       wrap;
    gap:             10px;
}

.wcswl-select-all-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
    cursor: pointer;
    color: #000;
}

.wcswl-bulk-actions {
    display: flex;
    gap:     10px;
    flex-wrap: wrap;
}

/* ============================================================
   Wishlist Table
   ============================================================ */
.wcswl-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    margin-bottom: 0px;
}

.wcswl-table th,
.wcswl-table td {
    padding:      12px 14px;
    border-bottom: 1px solid var(--wcswl-border);
    text-align:   left;
    vertical-align: middle;
}

.wcswl-table th {
    background:  #f8f9fa;
    font-weight: 600;
    font-size:   13px;
    color:       var(--wcswl-gray);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.wcswl-table thead{
    height: 40px;
}
.wcswl-table thead th{
    padding: 0px !important;
    text-align: center;
}

.wcswl-table tr:last-child td {
    border-bottom: none;
}

.wcswl-table tr.wcswl-item-row:hover td {
    background: #fafafa;
}

.wcswl-table tbody .wcswl-item-row td{
    padding-top: 7px !important;
    padding-bottom: 7px !important;
}
.wcswl-table tbody .wcswl-item-row:nth-child(even) {
    background: rgb(16 63 60 / 3%);
}
.wcswl-table tbody .wcswl-item-row:hover {
    background: rgb(16 63 60 / 5%);
}

.wcswl_table_warper{
    border: 1px solid #103f3c;
    border-radius: 7px;
    overflow: hidden;
    margin-bottom: 20px;
}

/* Image column */
.wcswl-col-image img {
    width: 40px !important;
    height: 40px !important;
    object-fit: cover;
    border-radius: var(--wcswl-radius);
    display: block;
}

.wcswl-col-title a {
    font-weight:     600;
    color:           var(--wcswl-primary);
    text-decoration: none;
}

.wcswl-col-title a:hover {
    color: var(--wcswl-red);
}

/* Quantity input */
.wcswl-qty-input {
    width: 65px !important;
    padding: 5px 5px !important;
    border: 1.5px solid var(--wcswl-border);
    border-radius: var(--wcswl-radius);
    font-size: 14px;
    text-align: center;
}

.wcswl-qty-input:focus {
    outline:      none;
    border-color: var(--wcswl-red);
}

/* Stock badges */
.wcswl-instock {
    color: #000;
    font-weight: 600;
    font-size:   12px;
}

.wcswl-outstock {
    color:       var(--wcswl-red);
    font-weight: 600;
    font-size:   12px;
}

/* Checkbox */
.wcswl-item-check {
    width:  17px;
    height: 17px;
    cursor: pointer;
    accent-color: var(--wcswl-red);
}

/* ============================================================
   Buttons
   ============================================================ */
.wcswl-btn-primary {
    background:    var(--wcswl-red);
    color:         #fff !important;
    border:        none;
    padding:       9px 18px;
    border-radius: var(--wcswl-radius);
    font-size:     13px;
    font-weight:   600;
    cursor:        pointer;
    transition:    background 0.2s ease;
    text-decoration: none;
    display:       inline-block;
}

.wcswl-btn-primary:hover:not(:disabled) {
    background: #103325;
}

.wcswl-btn-primary:disabled {
    background: #103f3c7a;
    cursor: not-allowed;
}

.wcswl-btn-secondary {
    background: #fff;
    color: #27473a;
    border: 1.5px solid #27473a;
    padding: 9px 18px;
    border-radius: var(--wcswl-radius);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.wcswl-btn-secondary:hover,
.wcswl-btn-secondary:focus{
    border-color: #103f3c;
    background: #103f3c;
    color: #fff;
}

/* Remove button (✕) */
.wcswl-remove-btn {
    background:    none;
    border:        1.5px solid var(--wcswl-border);
    color:         var(--wcswl-gray);
    width:         32px;
    height:        32px;
    border-radius: 50%;
    cursor:        pointer;
    font-size:     13px;
    transition:    all 0.3s ease;
}

.wcswl-remove-btn:hover {
    background:   var(--wcswl-red);
    border-color: var(--wcswl-red);
    color:        #fff;
}

/* Add to cart in table */
.wcswl-add-cart-btn {
    font-size: 12px;
    padding:   7px 12px;
}

/* Col actions — keep buttons on one line */
.wcswl-col-actions {
    white-space: nowrap;
}
.wcswl-col-actions .wcswl-remove-btn{
    padding: 0px !important;
}

/* ============================================================
   Share Row
   ============================================================ */
.wcswl-share {
    margin-top:  20px;
    font-size:   13px;
    color:       var(--wcswl-gray);
    display:     flex;
    align-items: center;
    gap:         10px;
    flex-wrap:   wrap;
}

.wcswl-share-link {
    color:           var(--wcswl-primary);
    text-decoration: underline;
    font-weight:     600;
}

#wcswl-copy-link {
    background:    none;
    border:        1px solid var(--wcswl-border);
    border-radius: var(--wcswl-radius);
    padding:       4px 10px;
    cursor:        pointer;
    font-size:     12px;
}

#wcswl-copy-link:hover {
    background: #f0f0f0;
}

/* ============================================================
   Row removal animation
   ============================================================ */
.wcswl-item-row.wcswl-removing {
    opacity:    0;
    transform:  translateX(30px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

/* ============================================================
   Wishlist link (shortcode)
   ============================================================ */
.wcswl-link {
    text-decoration: none;
}

.wcswl-count {
    font-weight: 700;
}

.wcswl-col-check{
    width: 20px;
    padding: 0px;
}


/* ============================================================
   Responsive
   ============================================================ */
@media ( max-width: 640px ) {
    .wcswl-table thead {
        display: none;
    }

    .wcswl-table tr {
        display:       block;
        border-bottom: 2px solid var(--wcswl-border);
        padding:       12px 0;
    }

    .wcswl-table td {
        display:    block;
        padding:    6px 14px;
        border:     none;
        text-align: left;
    }

    .wcswl-col-check { display: inline-block; }

    .wcswl-actions-top {
        flex-direction: column;
        align-items:    flex-start;
    }
}
