/* =========================================================
   PERFECTO THEME - PREMIUM CART CSS (2026 OPTIMIZED)
========================================================= */

:root {
    --pf-primary: #0a0a0a;
    --pf-primary-hover: #333333;
    --pf-accent-danger: #ef4444;
    --pf-accent-danger-bg: #fef2f2;
    --pf-bg-light: #f9fafb;
    --pf-border: #e5e7eb;
    --pf-text-main: #111827;
    --pf-text-muted: #6b7280;
    --pf-radius-lg: 16px;
    --pf-radius: 10px;
    --pf-radius-sm: 6px;
    --pf-shadow-soft: 0 10px 40px -10px rgba(0,0,0,0.08);
    --pf-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- GLOBAL CONTAINER --- */
/* Note: max-width is omitted here as it's dynamically set by Redux via PHP inline style */
.pf-cart-container { margin: 40px auto; padding: 0 20px; font-family: inherit; color: var(--pf-text-main); }
.pf-cart-header-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.pf-cart-title { font-size: 24px; font-weight: 800; margin: 0; letter-spacing: -0.02em; }
.desktop-only { display: block; }

/* Clear Cart Button */
.pf-clear-cart-btn {
    background: var(--pf-accent-danger-bg); border: 1px solid rgba(239, 68, 68, 0.2); 
    color: var(--pf-accent-danger); padding: 10px 18px; border-radius: var(--pf-radius-sm); cursor: pointer;
    font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 8px; transition: var(--pf-transition);
}
.pf-clear-cart-btn:hover { background: var(--pf-accent-danger); color: #fff; transform: translateY(-2px); box-shadow: 0 4px 12px rgba(239, 68, 68, 0.2); }

/* --- APP FEATURE: SHIPPING PROGRESS --- */
.pf-shipping-progress { background: #fff; padding: 20px; border-radius: 12px; margin-bottom: 25px; border: 1px solid var(--pf-border); box-shadow: 0 4px 15px rgba(0,0,0,0.03); }
.pf-shipping-label p { margin: 0 0 10px; font-size: 14px; color: #111; }
.pf-shipping-label strong { color: #059669; }
.pf-progress-track { background: var(--pf-bg-light); height: 8px; border-radius: 10px; overflow: hidden; }
.pf-progress-fill { background: #059669; height: 100%; border-radius: 10px; transition: width 0.5s ease; }
.pf-shipping-unlocked { background: #ecfdf5; border: 1px solid #a7f3d0; padding: 15px; border-radius: 12px; margin-bottom: 25px; display: flex; align-items: center; gap: 10px; color: #065f46; font-weight: 600; }

/* --- GRID LAYOUT --- */
.pf-cart-grid { display: grid; grid-template-columns: 1fr 400px; gap: 60px; align-items: start; }
.pf-cart-items-wrapper { transition: opacity 0.3s ease; }
.pf-cart-items-wrapper.is-loading, .pf-cart-summary.is-loading { opacity: 0.5; pointer-events: none; }

/* --- CART ITEMS TABLE (DESKTOP) --- */
.pf-cart-items { border: 1px solid var(--pf-border); border-radius: var(--pf-radius-lg); overflow: hidden; background: #fff; box-shadow: 0 2px 10px rgba(0,0,0,0.02); }
.pf-cart-table-header { padding: 12px 20px; background: var(--pf-bg-light); border-bottom: 1px solid var(--pf-border); font-weight: 600; font-size: 11px; color: var(--pf-text-muted); text-transform: uppercase; letter-spacing: 0.05em; }
/* Align Headers with Numbers for Desktop UI */
@media (min-width: 769px) {
   
  
    .pf-cart-table-header .col-total {
        text-align: right;
        display: block;
        padding-right: 0; /* Ensures it pushes all the way to the edge of the numbers */
    }
}


.pf-cart-row { padding: 16px 20px; border-bottom: 1px solid var(--pf-border); transition: background 0.2s ease; }
.pf-cart-row:hover { background: #fafafa; }
.pf-cart-row:last-child { border-bottom: none; }

@media (min-width: 769px) {
    .pf-cart-table-header, .pf-cart-row { display: grid; grid-template-columns: 3fr 1fr 1.5fr 1fr 50px; align-items: center; gap: 15px; }
    .pf-col-remove { display: flex; justify-content: flex-end; }
}

/* Product Info */
.pf-col-product { display: flex; align-items: center; gap: 20px; }
.pf-prod-img { width: 64px; height: 64px; flex-shrink: 0; border-radius: var(--pf-radius); overflow: hidden; }
.pf-prod-img img { width: 100%; height: 100%; object-fit: cover; border: 1px solid var(--pf-border); transition: transform 0.5s ease; }
.pf-cart-row:hover .pf-prod-img img { transform: scale(1.05); }
.pf-prod-details h3 { font-size: 15px; margin: 0 0 4px; font-weight: 600; line-height: 1.4; }
.pf-prod-details h3 a { color: var(--pf-text-main); text-decoration: none; transition: color 0.2s; }
.pf-prod-details h3 a:hover { color: var(--pf-text-muted); }
.pf-mobile-price { display: none; font-size: 14px; color: var(--pf-text-muted); font-weight: 500; margin-top: 4px; }

/* Quantity Inputs */
.pf-qty-wrapper { display: inline-flex; align-items: center; border: 1px solid var(--pf-border); border-radius: var(--pf-radius-sm); height: 34px; background: #fff; overflow: hidden; transition: border-color 0.2s; }
.pf-qty-wrapper:hover { border-color: #d1d5db; }
.pf-qty-btn { width: 36px; height: 100%; background: var(--pf-bg-light); border: none; color: var(--pf-text-main); cursor: pointer; display: flex; align-items: center; justify-content: center; transition: background 0.2s; }
.pf-qty-btn:hover { background: var(--pf-border); }
.pf-qty-wrapper input { width: 44px; height: 100%; border: none; border-left: 1px solid var(--pf-border); border-right: 1px solid var(--pf-border); text-align: center; font-size: 14px; font-weight: 600; color: var(--pf-text-main); padding: 0; -moz-appearance: textfield; }
.pf-qty-wrapper input:focus { outline: none; }
.pf-qty-wrapper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* Columns */
.pf-col-price { font-size: 15px; color: var(--pf-text-muted); font-weight: 500; }
.pf-col-total { font-size: 16px; color: var(--pf-text-main); font-weight: 700; padding-left: 20px; text-align: right; }
.pf-remove-link { color: #9ca3af; text-decoration: none; display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%; background: var(--pf-bg-light); transition: var(--pf-transition); }
.pf-remove-link:hover { background: var(--pf-accent-danger-bg); color: var(--pf-accent-danger); transform: rotate(90deg); }

/* --- SIDEBAR SUMMARY --- */
.pf-cart-summary { position: sticky; top: 40px; z-index: 10; }
.pf-summary-box { background: #fff; border: 1px solid var(--pf-border); border-radius: var(--pf-radius-lg); padding: 24px; box-shadow: var(--pf-shadow-soft); }
.pf-summary-box h2 { font-size: 17px; font-weight: 700; margin: 0 0 16px; padding-bottom: 12px; border-bottom: 1px solid var(--pf-border); }
.pf-row { display: flex; justify-content: space-between; margin-bottom: 10px; font-size: 14px; color: var(--pf-text-muted); }
.pf-summary-val { font-weight: 500; color: var(--pf-text-main); }
.pf-discount { color: #059669; }
.pf-discount .pf-summary-val { color: #059669; }

/* Sleek Coupon Layout */
.pf-app-coupon { display: flex; border: 1px solid var(--pf-border); border-radius: 8px; overflow: hidden; margin: 24px 0; background: #fff; }
.pf-app-coupon input { flex: 1; border: none; padding: 14px 16px; background: transparent; font-size: 14px; box-shadow: none; outline: none; color: #111; }
.pf-app-coupon button { background: var(--pf-primary); color: #fff; border: none; padding: 0 24px; font-weight: 600; font-size: 14px; border-radius: 0; cursor: pointer; transition: background 0.2s; }
.pf-app-coupon button:hover { background: var(--pf-primary-hover); }

/* Totals & Buttons */
.pf-summary-total { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; padding-top: 16px; border-top: 2px solid var(--pf-border); font-size: 15px; font-weight: 800; color: var(--pf-text-main); }
.pf-total-val { font-size: 20px; }
.pf-btn-primary { display: flex; justify-content: center; align-items: center; gap: 10px; width: 100%; background: var(--pf-primary); color: #fff; padding: 14px; border-radius: var(--pf-radius-sm); font-weight: 600; font-size: 15px; text-decoration: none; border: none; cursor: pointer; margin-top: 24px; transition: var(--pf-transition); }
.pf-btn-primary:hover { background: var(--pf-primary-hover); transform: translateY(-2px); box-shadow: 0 8px 20px rgba(0,0,0,0.15); }
.pf-trust-strip { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 20px; color: var(--pf-text-muted); font-size: 12px; font-weight: 500; }

/* Sticky Footer (Hidden on Desktop) */
.pf-mobile-sticky-footer { display: none; }

/* =========================================================
   MOBILE RESPONSIVE OVERHAUL (NATIVE APP VIEW)
========================================================= */
@media (max-width: 991px) {
    .pf-cart-grid { grid-template-columns: 1fr; gap: 30px; }
    .pf-cart-summary { position: static; }
}

@media (max-width: 768px) {
    /* Container Resets */
    .pf-cart-container.pf-app-mode { padding: 0 15px !important; margin-top: 20px !important; }
    .pf-cart-header-row { padding: 0; margin-bottom: 15px; }
    .pf-cart-title { font-size: 22px; }
    .pf-cart-title span { color: #9ca3af; font-size: 18px; }
    .desktop-only { display: none !important; }

    /* Clean Card Layout */
    .pf-cart-items { border: none; box-shadow: none; background: transparent; }
    .app-card { display: flex; flex-direction: row; align-items: center; padding: 10px; gap: 12px; background: #fff; border-radius: 10px; margin-bottom: 10px; border: 1px solid var(--pf-border); box-shadow: 0 2px 8px rgba(0,0,0,0.02); }
    
    /* Product Info (Left) */
    .pf-col-product { display: flex; align-items: center; gap: 12px; margin: 0; padding: 0; flex: 1; min-width: 0; }
    .pf-prod-img { width: 55px; height: 55px; border-radius: 6px; flex-shrink: 0; }
    .pf-prod-details { padding: 0; width: 100%; display: flex; flex-direction: column; justify-content: center; }
    .pf-prod-title { font-size: 14px; margin: 0 0 2px 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .app-price { font-size: 14px; color: var(--pf-text-muted); font-weight: 600; }

    /* Quantity (Middle) */
    .pf-col-qty.app-qty { width: auto; margin: 0; flex-shrink: 0; display: block; }
    .pf-qty-wrapper { width: 76px; height: 30px; border-radius: 6px; }
    .pf-qty-btn { width: 24px; font-size: 14px; }
    .pf-qty-wrapper input { width: 28px; font-size: 13px; }

    /* Remove (Right) */
    .pf-col-remove.app-remove { position: static; flex-shrink: 0; width: auto; height: auto; background: transparent; margin: 0; }
    .pf-remove-link { width: 28px; height: 28px; display: flex; align-items: center; justify-content: center; background: var(--pf-bg-light); border-radius: 50%; }
    .pf-remove-link svg { width: 14px; height: 14px; stroke: #9ca3af; }

    /* Summary & Coupon Tweaks */
    .app-summary { border: none; box-shadow: 0 4px 12px rgba(0,0,0,0.04); padding: 16px; border-radius: 12px; margin-top: 10px; }
    .pf-app-coupon { margin: 15px 0; }
    .pf-app-coupon input { padding: 12px 15px; font-size: 14px; }
    .pf-app-coupon button { padding: 0 16px; font-size: 14px; }

    /* =======================================
       THE STICKY FOOTER (GLASSMORPHISM) — 64px standard height
    ======================================== */
    .pf-mobile-sticky-footer {
        display: flex; position: fixed; bottom: 0; left: 0; width: 100%; z-index: 99999;
        gap: 10px; align-items: center;
        background: rgba(255, 255, 255, 0.96);
        backdrop-filter: blur(30px) saturate(180%); -webkit-backdrop-filter: blur(30px) saturate(180%);
        box-shadow: 0 -1px 0 rgba(255, 255, 255, 0.9) inset, 0 -4px 30px rgba(0, 0, 0, 0.08);
        border-top: 0.5px solid rgba(0, 0, 0, 0.06);
        padding: 8px 16px;
        padding-bottom: max(8px, env(safe-area-inset-bottom));
        min-height: 64px;
        box-sizing: border-box;
    }
    .pf-sticky-icon {
        flex: 0 0 52px; width: 52px; height: 48px;
        background: var(--pf-bg-light); border: 1.5px solid rgba(0,0,0,0.09);
        border-radius: 12px; display: flex; align-items: center; justify-content: center;
        color: #111; cursor: pointer; text-decoration: none;
        transition: transform 0.18s cubic-bezier(.4,0,.2,1), border-color 0.18s;
        flex-shrink: 0;
        -webkit-tap-highlight-color: transparent;
    }
    .pf-sticky-icon svg { width: 22px; height: 22px; stroke-width: 2; display: block; }
    .pf-sticky-icon:active { transform: scale(0.94); }
    .pf-sticky-icon:hover { border-color: rgba(0,0,0,0.2); }
    
    .pf-sticky-checkout {
        flex: 1; height: 48px;
        background: var(--pf-primary, #0a0a0a); color: #fff;
        border-radius: 12px; display: flex; align-items: center;
        justify-content: space-between; padding: 0 18px;
        text-decoration: none; font-weight: 700; font-size: 15px;
        transition: transform 0.18s cubic-bezier(.4,0,.2,1), filter 0.18s;
        -webkit-tap-highlight-color: transparent;
        touch-action: manipulation;
        min-width: 0;
    }
    .pf-sticky-checkout:active { transform: scale(0.98); }
    .pf-sticky-checkout:hover { filter: brightness(1.12); color: #fff; }
    .pf-sticky-checkout .sticky-total {
        background: rgba(255,255,255,0.15); padding: 4px 10px;
        border-radius: 6px; font-size: 13px; white-space: nowrap;
    }
}



/* =========================================================
   EMPTY CART STATE (PREMIUM UI)
========================================================= */

.pf-empty-cart {
    text-align: center;
    padding: 80px 20px;
    max-width: 600px;
    margin: 0 auto;
    /* Smooth entrance animation */
    animation: pfFadeInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes pfFadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Floating Illustration */
.pf-empty-illustration {
    margin-bottom: 30px;
    animation: pfFloat 6s ease-in-out infinite;
}

.pf-empty-illustration svg {
    max-width: 100%;
    height: auto;
    /* Soft luxury drop shadow on the SVG shapes */
    filter: drop-shadow(0 15px 25px rgba(0,0,0,0.04));
}

@keyframes pfFloat {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-12px); }
    100% { transform: translateY(0px); }
}

/* Typography */
.pf-empty-title {
    font-size: 28px;
    font-weight: 800;
    color: var(--pf-text-main, #111);
    margin: 0 0 12px;
    letter-spacing: -0.02em;
}

.pf-empty-text {
    font-size: 16px;
    color: var(--pf-text-muted, #6b7280);
    line-height: 1.6;
    margin: 0 0 32px;
}

/* Shop Now Button */
.pf-btn-shop-now {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: var(--pf-primary, #0a0a0a);
    color: #fff;
    padding: 16px 36px;
    border-radius: var(--pf-radius-sm, 8px); 
    font-weight: 600;
    font-size: 16px;
    text-decoration: none;
    transition: var(--pf-transition, all 0.3s ease);
}

.pf-btn-shop-now:hover {
    background: var(--pf-primary-hover, #333);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

/* Arrow sliding animation on hover */
.pf-btn-shop-now svg {
    transition: transform 0.3s ease;
}

.pf-btn-shop-now:hover svg {
    transform: translateX(5px);
}


/* =========================================================
   MOBILE RESPONSIVE (COMPACT APP FEEL)
========================================================= */
@media (max-width: 768px) {
    .pf-empty-cart {
        padding: 40px 15px; /* Tighter top/bottom padding */
    }
    
    .pf-empty-illustration {
        margin-bottom: 20px;
    }
    
    .pf-empty-illustration svg {
        width: 140px; /* Scaled down for mobile */
        height: 140px;
    }
    
    .pf-empty-title {
        font-size: 22px;
    }
    
    .pf-empty-text {
        font-size: 14px;
        margin-bottom: 24px;
    }
    
    .pf-btn-shop-now {
        padding: 14px 20px;
        font-size: 15px;
        width: 100%; /* Full width button like native apps */
        max-width: 320px; /* Stops it from getting too stretched on tablets */
    }
}


/* ===============================
   EMPTY CART SPACING FIX
================================ */
/* 1. Global / Desktop Spacing */
.pf-empty-cart .pf-empty-title {
    margin-bottom: 16px !important; 
}

.pf-empty-cart .pf-empty-text {
    margin-bottom: 40px !important; /* Massive breathing room above the button */
    line-height: 1.6 !important; 
}

/* 2. Mobile Proportions */
@media (max-width: 768px) {
    .pf-empty-cart .pf-empty-text {
        margin-bottom: 25px !important; /* Slightly tighter so it doesn't look disconnected on phones */
    }
}


/* Make WooCommerce Meta Data Sleek & Inline */
.pf-cart-item-meta dl.variation {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 8px;
    margin: 4px 0 0 0;
    font-size: 13px;
    color: var(--pf-text-muted);
}
.pf-cart-item-meta dl.variation dt { font-weight: 600; margin: 0; }
.pf-cart-item-meta dl.variation dd { margin: 0; }
.pf-cart-item-meta dl.variation p { margin: 0 !important; display: inline-block; }

/* ===============================
   REMOVE DUPLICATE VARIATIONS
================================ */
/* Hides the redundant variation data since it's already in the product title */
.pf-prod-details dl.variation,
.pf-cart-item-meta dl.variation {
    display: none !important;
}


/* =========================================================
   MOBILE RESPONSIVE (AMAZON / NATIVE APP STYLE)
========================================================= */
@media (max-width: 768px) {
    
    /* 1. Reset Card for Absolute Positioning */
    .app-card { 
        display: block !important; /* Remove the 1-row flex restriction */
        position: relative !important; 
        padding: 16px !important; 
        background: #fff; 
        border-radius: 12px; 
        margin-bottom: 12px; 
        border: 1px solid var(--pf-border); 
        box-shadow: 0 2px 8px rgba(0,0,0,0.02); 
    }
    
    /* 2. Product Info Layout */
    .pf-col-product { 
        display: flex; 
        align-items: flex-start; /* Align to top */
        gap: 15px; 
        width: 100%; 
        margin: 0; 
        padding: 0; 
    }
    
    /* Slightly bigger image to balance the height */
    .pf-prod-img { 
        width: 76px !important; 
        height: 76px !important; 
        border-radius: 8px !important; 
        flex-shrink: 0; 
    }
    
    /* Pushes the price down to the bottom */
    .pf-prod-details { 
        flex: 1 1 0% !important; 
        min-width: 0 !important; 
        padding-right: 25px !important; /* Keeps text away from the X button */
        display: flex; 
        flex-direction: column; 
        min-height: 76px; /* Matches image height */
    }

    /* Allow title to wrap to 2 lines max, then truncate */
    .pf-prod-title, .pf-prod-title a { 
        font-size: 14px !important; 
        margin: 0 0 4px 0 !important; 
        white-space: normal !important; 
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
        line-height: 1.3 !important;
    }

    /* Price pinned to the bottom left */
    .pf-mobile-price-row {
        margin-top: auto !important; /* Magic trick to push price to the bottom */
        padding-top: 10px;
    }

    .app-price { 
        font-size: 15px !important; 
        color: #111; 
        font-weight: 700; 
    }

    /* =========================================================
       THE MAGIC POSITIONS (Top Right & Bottom Right)
    ========================================================= */

    /* 3. Remove Button (Top Right Corner) */
    .pf-col-remove.app-remove { 
        position: absolute !important; 
        top: 16px !important; 
        right: 16px !important; 
        margin: 0 !important; 
        width: auto; 
        height: auto; 
    }

    .pf-remove-link { 
        width: 24px !important; 
        height: 24px !important; 
        display: flex; 
        align-items: center; 
        justify-content: center; 
        background: transparent !important; /* Cleaner without the gray circle */
    }

    .pf-remove-link svg { width: 16px !important; height: 16px !important; stroke: #9ca3af; }
    
    /* 4. Quantity Button (Bottom Right Corner) */
    .pf-col-qty.app-qty { 
        position: absolute !important; 
        bottom: 16px !important; 
        right: 16px !important; 
        margin: 0 !important; 
        width: auto !important; 
        display: block !important; 
    }

    .pf-qty-wrapper { 
        width: 80px !important; 
        height: 32px !important; 
        border-radius: 6px !important; 
        background: #fff;
        border: 1px solid #e5e7eb;
    }

    .pf-qty-btn { width: 26px !important; font-size: 15px; background: transparent; }
    .pf-qty-wrapper input { width: 28px !important; font-size: 13px !important; }

}


/* =========================================================
   HIDE REDUNDANT CHECKOUT BUTTON ON MOBILE
========================================================= */
@media (max-width: 768px) {
    .pf-summary-box .pf-checkout-btn {
        display: none !important;
    }
    
   
}



/* =========================================================
   MOBILE HEADER COMPACT FIX
========================================================= */
@media (max-width: 768px) {
    /* 1. Shrink the main title and the item count (1) */
    .pf-cart-title { 
        font-size: 18px !important; 
    }
    .pf-cart-title span { 
        font-size: 15px !important; 
    }

    /* 2. Shrink the Clear Cart button padding, text, and icon */
    .pf-clear-cart-btn {
        padding: 6px 10px !important;
        font-size: 11px !important;
        gap: 4px !important;
        border-radius: 6px !important;
    }
    .pf-clear-cart-btn svg {
        width: 14px !important;
        height: 14px !important;
    }
}


/* =========================================================
   MODERN WOOCOMMERCE NOTICES (TOAST NOTIFICATIONS)
========================================================= */

/* 1. The Wrapper: Pin it to the bottom right */
.woocommerce-notices-wrapper {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 999999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none; /* Lets users click 'through' the invisible wrapper area */
    width: auto;
    max-width: 400px;
}

/* 2. The Toast Cards */
.woocommerce-message,
.woocommerce-error,
.woocommerce-info {
    pointer-events: auto; /* Re-enable clicks on the actual toast */
    background: #111827; /* Sleek dark mode look */
    color: #fff;
    padding: 16px 20px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15), 0 1px 3px rgba(0,0,0,0.1);
    margin: 0 !important;
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border: none !important; /* Overrides default Woo borders */
    
    /* Smooth entrance animation */
    animation: pfToastSlideUp 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Remove default WooCommerce list styling for errors */
.woocommerce-error li { list-style: none; margin: 0; padding: 0; }
.woocommerce-error ul { margin: 0; padding: 0; }

/* Status Colors (Optional: you can keep them all dark, or color-code them) */
.woocommerce-error { background: #ef4444; color: #fff; } /* Premium Red */
.woocommerce-info { background: #3b82f6; color: #fff; } /* Premium Blue */

/* 3. Style the "Undo" or "View Cart" Buttons inside the toast */
.woocommerce-message .button,
.woocommerce-error .button,
.woocommerce-info .button {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    border: none;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s ease;
    white-space: nowrap;
}

.woocommerce-message .button:hover,
.woocommerce-error .button:hover,
.woocommerce-info .button:hover {
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
}

/* 4. The Animation */
@keyframes pfToastSlideUp {
    from { transform: translateY(100px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* =========================================================
   MODERN WOOCOMMERCE NOTICES (PF-TOAST DESIGN)
========================================================= */

/* The Wrapper (Handles centering) */
.woocommerce-notices-wrapper {
    position: fixed;
    bottom: 24px;
    left: 50%;
    z-index: 100001;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    transform: translateX(-50%);
    pointer-events: none;
    width: 100%;
    max-width: 320px;
}

/* The Notification Pill */
.woocommerce-message,
.woocommerce-error,
.woocommerce-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 12px 18px;
    background: #0a0a0a; /* Fallback */
    color: #fff;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.18);
    min-width: 200px;
    width: 100%;
    pointer-events: auto; /* Re-enable clicks */
    margin: 0 !important;
    border: none !important;
    
    /* Your sleek entrance physics */
    animation: pfToastEntrance 0.38s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

/* Strip default WooCommerce list styles */
.woocommerce-error li { list-style: none; margin: 0; padding: 0; }
.woocommerce-error ul { margin: 0; padding: 0; }

/* Match Your Colors */
.woocommerce-message { background: #059669; } /* Success */
.woocommerce-error   { background: #c62828; } /* Error */
.woocommerce-info    { background: #2563eb; } /* Info */

/* Style buttons inside (like "Undo") */
.woocommerce-message .button,
.woocommerce-error .button,
.woocommerce-info .button {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    border: none;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    text-decoration: none;
    margin-left: auto;
    white-space: nowrap;
    transition: background 0.2s ease;
}

.woocommerce-message .button:hover,
.woocommerce-error .button:hover,
.woocommerce-info .button:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* JS Exit Animation Class */
.pf-toast-exit {
    animation: pfToastExit 0.3s ease forwards !important;
}

@keyframes pfToastEntrance {
    from { transform: translateY(calc(100% + 30px)); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes pfToastExit {
    from { transform: translateY(0); opacity: 1; }
    to { transform: translateY(calc(100% + 30px)); opacity: 0; }
}

/* Mobile Alignment */
@media (max-width: 480px) {
    .woocommerce-notices-wrapper {
        bottom: 80px; /* Above your mobile bar */
        right: 12px;
        left: 12px;
        transform: none; /* Remove centering shift */
        max-width: none;
        width: auto;
    }
}