/**
 * Vision Research - Cart Page Styles
 * WordPress/Blocksy/WooCommerce Compatible
 * Tokens from variables.css (single source of truth)
 */

.woocommerce {
    width: 100% !important;
    max-width: 100% !important;
    box-sizing: border-box;
}

/* Prevent horizontal overflow on iOS */
.woocommerce-cart {
    overflow-x: hidden;
}

.woocommerce-cart .entry-content {
    overflow-x: hidden;
    max-width: 100vw;
}

.site-main {
    background-color: var(--vr-bg) !important;
}

/* ============================================
   BREADCRUMB
   ============================================ */
.vr-breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.vr-breadcrumb a {
    color: var(--vr-text-light);
    text-decoration: none;
    transition: color 0.2s;
}

.vr-breadcrumb a:hover {
    color: var(--vr-primary);
}

.vr-breadcrumb__sep {
    color: var(--vr-border-dark);
}

.vr-breadcrumb__current {
    color: var(--vr-text);
    font-weight: 500;
}

/* ============================================
   CART PAGE LAYOUT
   ============================================ */
.vr-cart-page {
    padding: 40px 0 0;
}

.ct-container-full {
    padding-top: 0 !important;
}

.vr-cart-page .vr-container {
    max-width: var(--vr-container-max);
    margin: 0 auto;
    padding: 0 24px;
    padding-left: max(24px, env(safe-area-inset-left, 0px));
    padding-right: max(24px, env(safe-area-inset-right, 0px));
    overflow-x: hidden;
}

/* Back Link */
.vr-cart__back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--vr-text);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
    transition: var(--vr-transition);
}

.vr-cart__back:hover {
    color: var(--vr-primary);
}

.vr-cart__back svg {
    width: 16px;
    height: 16px;
}

/* Page Title */
.vr-cart__title {
    font-size: 24px;
    font-weight: 600;
    color: var(--vr-primary);
    margin: 0 0 32px;
}

/* Main Layout - 2 columns */
.vr-cart__layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 32px;
    align-items: start;
}

/* ============================================
   CART ITEMS (Left Column)
   ============================================ */
.vr-cart__left-col {
    min-width: 0;
}

.vr-cart__items {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Single Cart Item */
.vr-cart-item {
    background: var(--vr-white);
    border: 1px solid var(--vr-border);
    border-radius: var(--vr-radius-lg);
    padding: 20px;
    transition: var(--vr-transition);
}

.vr-cart-item:hover {
    border-color: var(--vr-primary);
    box-shadow: var(--vr-shadow-sm);
}

.vr-cart-item__content {
    display: flex;
    gap: 20px;
}

.vr-cart-item__image-link {
    flex-shrink: 0;
    width: 100px;
    height: 100px;
    border-radius: var(--vr-radius-md);
    overflow: hidden;
    background: var(--vr-bg);
    display: flex;
    align-items: center;
    justify-content: center;
}

.vr-cart-item__image-link img,
.vr-cart-item__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    padding: 0;
}

.vr-cart-item__details {
    flex: 1;
    min-width: 0;
}

.vr-cart-item__header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.vr-cart-item__name {
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 4px;
}

.vr-item_name__link {
    color: var(--vr-text);
    text-decoration: none;
}

.vr-item_name__link:hover {
    color: var(--vr-primary);
}

.vr-cart-item__purity {
    font-size: 13px;
    color: var(--vr-primary);
    margin: 0 0 2px;
    font-weight: 500;
}

.vr-cart-item__remove {
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
    color: var(--vr-text-light);
    transition: var(--vr-transition);
    border-radius: var(--vr-radius-sm);
}

.vr-cart-item__remove:hover {
    color: var(--vr-red);
}

.vr-cart-item__remove svg {
    width: 18px;
    height: 18px;
}

.vr-cart-item__variant {
    font-size: 13px;
    color: var(--vr-primary);
    font-weight: 500;
    margin: 0 0 4px;
}

/* Quantity & Price Row */
.vr-cart-item__footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.quantity .ct-increase {
    display: none !important;
}

.quantity .ct-decrease {
    display: none !important;
}

/* Quantity Selector */
.vr-cart-item__quantity {
    display: flex;
    align-items: center;
    gap: 4px;
}

.vr-cart-item__quantity-label {
    font-size: 14px;
    color: var(--vr-text-light);
    margin-right: 8px;
}

.vr-cart-item__qty-btn {
    width: 36px;
    height: 36px;
    border: 1px solid var(--vr-border);
    border-radius: var(--vr-radius-sm);
    background: var(--vr-white);
    color: var(--vr-text);
    font-size: 18px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--vr-transition);
}

.vr-cart-item__qty-btn:hover {
    border-color: var(--vr-primary);
    color: var(--vr-primary);
    background: var(--vr-primary-light);
}

.vr-cart-item__qty-input {
    padding-inline: 0 !important;
    border: none !important;
    text-align: center;
    font-size: 15px;
    font-weight: 600;
    color: var(--vr-text);
    font-family: var(--vr-font-primary);
}

.quantity {
    width: 44px !important;
    height: 36px !important;
}

.vr-cart-item__qty-input:focus {
    outline: none;
}

/* Price */
.vr-cart-item__price {
    text-align: right;
}

.vr-cart-item__price-calc {
    font-size: 12px;
    color: var(--vr-text-light);
    margin: 0 0 2px;
}

.vr-cart-item__price-total {
    font-size: 18px;
    font-weight: 700;
    color: var(--vr-text);
    margin: 0;
}

/* ============================================
   FREE ITEM (Bacteriostatic Water)
   ============================================ */
.vr-cart-item--free {
    background: var(--vr-primary-light);
    border: 1px solid var(--vr-primary);
    border-left: 4px solid var(--vr-primary);
}

.vr-cart-item--free .vr-cart-item__name {
    font-weight: 400;
}

.vr-cart-item--free .vr-cart-item__badge {
    font-size: 12px;
    color: var(--vr-text-light);
    margin: 0 0 4px;
}

.vr-cart-item--free .vr-cart-item__price-total {
    color: var(--vr-green);
    font-weight: 700;
}

.vr-cart-item--free .vr-cart-item__remove {
    display: none;
}

.vr-cart-item--free .vr-cart-item__quantity {
    display: none;
}

.vr-cart-item--free .vr-cart-item__footer {
    justify-content: flex-end;
}

/* ============================================
   ORDER SUMMARY (Right Column)
   ============================================ */
.vr-cart__summary {
    background: var(--vr-white);
    border: 1px solid var(--vr-border);
    border-radius: var(--vr-radius-lg);
    padding: 28px;
    position: sticky;
    top: 100px;
}

.vr-cart__summary-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--vr-text);
    margin: 0 0 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--vr-border);
}

/* Summary Rows */
.vr-cart__summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
}

.vr-cart__summary-row--total {
    border-top: 1px solid var(--vr-border);
    margin-top: 12px;
    padding-top: 20px;
}

.vr-cart__summary-label {
    font-size: 15px;
    color: var(--vr-text);
}

.vr-cart__summary-value {
    font-size: 15px;
    font-weight: 600;
    color: var(--vr-text);
}

.vr-cart__summary-value--muted {
    color: var(--vr-text-light);
    font-weight: 400;
    font-size: 13px;
}

.vr-cart__summary-row--total .vr-cart__summary-label {
    font-size: 16px;
    font-weight: 600;
}

.vr-cart__summary-row--total .vr-cart__summary-value {
    font-size: 20px;
    font-weight: 700;
    color: var(--vr-primary);
}

/* Summary Free Badge */
.vr-cart__summary-free {
    display: flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, var(--vr-green-bg) 0%, var(--vr-green-light) 100%);
    border: 1px solid var(--vr-green-border);
    border-radius: var(--vr-radius-sm);
    padding: 12px 16px;
    margin: 16px 0;
}

.vr-cart__summary-free-icon {
    width: 22px;
    height: 22px;
    color: var(--vr-green);
    flex-shrink: 0;
}

.vr-cart__summary-free-text {
    font-size: 13px;
    color: var(--vr-text);
}

.vr-cart__summary-free-text strong {
    color: var(--vr-green);
    font-weight: 600;
}

/* Cart Disclaimer */
.vr-cart__disclaimer {
    font-size: 12px;
    color: var(--vr-text-light);
    text-align: center;
    margin: 12px 0 0;
}

/* Checkout Button */
.vr-cart__checkout-btn {
    width: 100%;
    padding: 16px 24px;
    background: var(--vr-primary);
    color: var(--vr-white);
    border: none;
    border-radius: var(--vr-radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--vr-transition);
    font-family: var(--vr-font-primary);
    margin-top: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.vr-cart__checkout-btn svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.vr-cart__checkout-btn:hover {
    background: var(--vr-primary-hover);
    transform: translateY(-1px);
    box-shadow: var(--vr-shadow-md);
    color: var(--vr-white);
}

.vr-cart__checkout-btn:disabled {
    background: var(--vr-border);
    color: var(--vr-text-light);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Trust Signals */
.vr-trust {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.vr-trust__item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: var(--vr-text-light);
}

.vr-trust__icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
    color: var(--vr-primary);
}

/* Continue Shopping Link */
.vr-cart__continue {
    display: block;
    text-align: center;
    margin-top: 16px;
    color: var(--vr-primary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: var(--vr-transition);
}

.vr-cart__continue:hover {
    text-decoration: underline;
}

/* ============================================
   EMPTY CART STATE
   ============================================ */
.vr-cart--empty {
    text-align: center;
    padding: 60px 24px 40px;
    background: var(--vr-white);
    border-radius: var(--vr-radius-lg);
    border: 1px solid var(--vr-border);
    max-width: 500px;
    margin: 0 auto 40px;
}

.vr-cart--empty__icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    color: var(--vr-primary);
    opacity: 0.6;
}

.vr-cart--empty__icon svg {
    width: 100%;
    height: 100%;
}

.vr-cart--empty__title {
    font-size: 22px;
    font-weight: 700;
    color: var(--vr-text);
    margin: 0 0 8px;
}

.vr-cart--empty__text {
    font-size: 15px;
    color: var(--vr-text-light);
    margin: 0 0 24px;
    line-height: 1.5;
}

.vr-cart--empty__btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    background: var(--vr-primary);
    color: var(--vr-white);
    text-decoration: none;
    border-radius: var(--vr-radius-md);
    font-size: 15px;
    font-weight: 600;
    transition: var(--vr-transition);
}

.vr-cart--empty__btn:hover {
    background: var(--vr-primary-hover);
    color: var(--vr-white);
    transform: translateY(-1px);
    box-shadow: var(--vr-shadow-md);
}

/* ============================================
   EMPTY CART - BESTSELLING PRODUCTS
   ============================================ */
.vr-empty-cart-products {
    margin-top: 0;
}

.vr-empty-cart-products__title {
    font-size: 18px;
    font-weight: 600;
    color: var(--vr-text);
    margin: 0 0 20px;
    text-align: center;
}

.vr-empty-cart-products__grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.vr-empty-cart-product {
    background: var(--vr-white);
    border: 1px solid var(--vr-border);
    border-radius: var(--vr-radius-lg);
    overflow: hidden;
    transition: var(--vr-transition);
}

.vr-empty-cart-product:hover {
    border-color: var(--vr-primary);
    box-shadow: var(--vr-shadow-md);
    transform: translateY(-2px);
}

.vr-empty-cart-product__image-link {
    display: block;
    aspect-ratio: 1;
    background: var(--vr-bg);
    overflow: hidden;
}

.vr-empty-cart-product__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    padding: 0;
    transition: transform 0.3s ease;
}

.vr-empty-cart-product:hover .vr-empty-cart-product__image {
    transform: scale(1.05);
}

.vr-empty-cart-product__placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--vr-text-light);
}

.vr-empty-cart-product__placeholder svg {
    width: 48px;
    height: 48px;
}

.vr-empty-cart-product__content {
    padding: 16px;
}

.vr-empty-cart-product__name {
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 12px;
    line-height: 1.3;
}

.vr-empty-cart-product__name a {
    color: var(--vr-text);
    text-decoration: none;
}

.vr-empty-cart-product__name a:hover {
    color: var(--vr-primary);
}

.vr-empty-cart-product__footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.vr-empty-cart-product__price {
    font-size: 15px;
    font-weight: 700;
    color: var(--vr-text);
}

.vr-empty-cart-product__price del {
    font-size: 12px;
    color: var(--vr-text-light);
    font-weight: 400;
}

.vr-empty-cart-product__price ins {
    text-decoration: none;
    color: var(--vr-primary);
}

.vr-empty-cart-product__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    background: var(--vr-primary);
    color: var(--vr-white);
    border-radius: var(--vr-radius-sm);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: var(--vr-transition);
    white-space: nowrap;
}

.vr-empty-cart-product__btn:hover {
    background: var(--vr-primary-hover);
    color: var(--vr-white);
}

/* Responsive - Empty Cart Products */
@media (max-width: 1024px) {
    .vr-empty-cart-products__grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 530px) {
    .vr-cart--empty {
        padding: 40px 20px 30px;
        margin-bottom: 30px;
    }

    .vr-cart--empty__icon {
        width: 60px;
        height: 60px;
        margin-bottom: 16px;
    }

    .vr-cart--empty__title {
        font-size: 18px;
    }

    .vr-cart--empty__text {
        font-size: 14px;
        margin-bottom: 20px;
    }

    .vr-cart--empty__btn {
        padding: 12px 24px;
        font-size: 14px;
    }

    .vr-empty-cart-products__title {
        font-size: 16px;
        margin-bottom: 16px;
    }

    .vr-empty-cart-products__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .vr-empty-cart-product__content {
        padding: 12px;
    }

    .vr-empty-cart-product__name {
        font-size: 13px;
        margin-bottom: 8px;
    }

    .vr-empty-cart-product__footer {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .vr-empty-cart-product__price {
        font-size: 14px;
    }

    .vr-empty-cart-product__btn {
        width: 100%;
        padding: 10px 12px;
        text-align: center;
    }
}

/* ============================================
   HIDE DEFAULT WOOCOMMERCE EMPTY CART NOTICE
   (We use our own custom template)
   ============================================ */
.woocommerce-cart .woocommerce-notices-wrapper .woocommerce-info,
.woocommerce-cart .woocommerce-message,
.woocommerce-cart .cart-empty.woocommerce-info,
.woocommerce-cart p.cart-empty,
.woocommerce-cart .return-to-shop {
    display: none !important;
}

/* Show only when our custom template is NOT loaded (fallback) */
.woocommerce-cart:not(:has(.vr-cart-page)) .woocommerce-notices-wrapper .woocommerce-info,
.woocommerce-cart:not(:has(.vr-cart-page)) p.cart-empty,
.woocommerce-cart:not(:has(.vr-cart-page)) .return-to-shop {
    display: block !important;
}

/* ============================================
   WOOCOMMERCE BLOCK CART - EMPTY STATE OVERRIDE
   ============================================ */
.wc-block-cart--is-empty,
.wc-block-cart-is-empty-container {
    max-width: var(--vr-container-max);
    margin: 0 auto;
    padding: 40px 24px;
}

.wc-block-cart__empty-cart__message,
.wc-block-cart--is-empty .wc-block-cart__empty-cart__title {
    text-align: center;
}

/* Override empty cart notice */
.woocommerce-info,
.wc-block-components-notice-banner.is-info {
    background: var(--vr-white) !important;
    border: 1px solid var(--vr-border) !important;
    border-radius: var(--vr-radius-md) !important;
    color: var(--vr-text) !important;
    padding: 20px 24px !important;
    margin: 0 auto 24px !important;
    max-width: 500px;
    text-align: center;
}

.woocommerce-info::before,
.wc-block-components-notice-banner.is-info::before {
    color: var(--vr-primary) !important;
}

/* Return to shop button */
.wc-block-cart--is-empty .wp-block-button__link,
.woocommerce .return-to-shop a.button,
a.button.wc-backward {
    display: inline-block !important;
    padding: 14px 32px !important;
    background: var(--vr-primary) !important;
    color: var(--vr-white) !important;
    border: none !important;
    border-radius: var(--vr-radius-md) !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    text-decoration: none !important;
    transition: var(--vr-transition) !important;
}

.wc-block-cart--is-empty .wp-block-button__link:hover,
.woocommerce .return-to-shop a.button:hover,
a.button.wc-backward:hover {
    background: var(--vr-primary-hover) !important;
    color: var(--vr-white) !important;
}

/* ============================================
   RESPONSIVE - TABLET
   ============================================ */
@media (max-width: 1024px) {
    .vr-cart__layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 24px;
    }

    .vr-cart__left-col {
        display: contents;
    }

    .vr-cart__items {
        order: 1;
        grid-row: 1;
        min-width: 0;
        max-width: 100%;
    }

    .vr-cart__summary {
        position: static;
        grid-row: 2;
        min-width: 0;
        max-width: 100%;
    }

    .vr-cross-sells {
        grid-row: 3;
        min-width: 0;
        max-width: 100%;
    }
}

/* ============================================
   RESPONSIVE - MOBILE
   ============================================ */
@media (max-width: 530px) {
    .vr-cart-page {
        padding: 24px 0 0;
    }

    .vr-cart-page .vr-container {
        padding: 0 16px;
        padding-left: max(16px, env(safe-area-inset-left, 0px));
        padding-right: max(16px, env(safe-area-inset-right, 0px));
    }

    .vr-cart__title {
        font-size: 20px;
        margin-bottom: 20px;
    }

    /* Cart item adjustments */
    .vr-cart-item {
        padding: 16px;
        position: relative;
    }

    .vr-cart-item__content {
        flex-direction: row;
        gap: 12px;
    }

    .vr-cart-item__image-link {
        width: 70px;
        height: 70px;
        flex-shrink: 0;
    }

    .vr-cart-item__details {
        flex: 1;
        min-width: 0;
    }

    .vr-cart-item__header {
        margin-bottom: 8px;
    }

    .vr-cart-item__name {
        font-size: 14px;
        padding-right: 30px;
    }

    .vr-cart-item__remove {
        position: absolute;
        top: 12px;
        right: 12px;
        padding: 4px;
    }

    .vr-cart-item__remove svg {
        width: 16px;
        height: 16px;
    }

    .vr-cart-item__footer {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .vr-cart-item__quantity-label {
        font-size: 13px;
        margin-right: 6px;
    }

    .vr-cart-item__qty-btn {
        width: 32px;
        height: 32px;
        font-size: 16px;
    }

    .quantity {
        width: 36px !important;
        height: 32px !important;
    }

    .vr-cart-item__qty-input {
        font-size: 14px;
    }

    .vr-cart-item__price {
        text-align: left;
        width: 100%;
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .vr-cart-item__price-calc {
        font-size: 11px;
    }

    .vr-cart-item__price-total {
        font-size: 16px;
    }

    /* Summary box */
    .vr-cart__summary {
        padding: 16px;
        position: static;
    }

    .vr-cart__summary-title {
        font-size: 16px;
        margin-bottom: 16px;
        padding-bottom: 12px;
    }

    .vr-cart__checkout-btn {
        padding: 12px 16px;
        font-size: 15px;
    }

    /* Cross-sells */
    .vr-cross-sells {
        padding: 24px 0;
        margin-top: 24px;
    }

    .vr-cross-sells__title {
        font-size: 16px;
    }

    .vr-cross-sells__header {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* ============================================
   WOOCOMMERCE OVERRIDES
   ============================================ */
.woocommerce-cart .woocommerce-notices-wrapper {
    max-width: var(--vr-container-max);
    margin: 0 auto 24px;
    padding: 0 24px;
}

/* Hide default WooCommerce cart if using custom */
.woocommerce-cart .woocommerce > .woocommerce-cart-form {
    display: none;
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.vr-cart-item {
    animation: fadeIn 0.3s ease forwards;
}

.vr-cart-item:nth-child(1) { animation-delay: 0s; }
.vr-cart-item:nth-child(2) { animation-delay: 0.05s; }
.vr-cart-item:nth-child(3) { animation-delay: 0.1s; }
.vr-cart-item:nth-child(4) { animation-delay: 0.15s; }
.vr-cart-item:nth-child(5) { animation-delay: 0.2s; }

/* Quantity update animation */
.vr-cart-item__price-total.updating {
    animation: pulse 0.3s ease;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* ============================================
   WATER ITEM - FREE STATE
   ============================================ */
.vr-cart-item--water-free {
    background: linear-gradient(135deg, var(--vr-green-bg) 0%, var(--vr-green-light) 100%);
    border-color: var(--vr-green-border);
}

.vr-cart-item--water-free:hover {
    border-color: var(--vr-green);
}

.vr-cart-item__badge {
    display: inline-block;
    font-size: 11px;
    background: var(--vr-green-light);
    color: var(--vr-green);
    padding: 3px 10px;
    border-radius: 4px;
    font-weight: 600;
    margin-top: 4px;
}

/* Free price styling */
.vr-free-price {
    color: var(--vr-green) !important;
    font-weight: 700 !important;
}

/* Hide price calc for free items */
.vr-cart-item--water-free .vr-cart-item__price-calc {
    display: none;
}

/* ============================================
   WATER ITEM - PAID STATE (no peptides)
   ============================================ */
.vr-cart-item[data-is-water="1"]:not(.vr-cart-item--water-free) {
    background: var(--vr-white);
    border-color: var(--vr-border);
}

.vr-cart-item[data-is-water="1"]:not(.vr-cart-item--water-free) .vr-cart-item__badge {
    display: none;
}

/* ============================================
   ANIMATION FOR STATUS CHANGE
   ============================================ */
@keyframes waterStatusChange {
    0% { transform: scale(1); }
    50% { transform: scale(1.02); }
    100% { transform: scale(1); }
}

.vr-cart-item[data-is-water="1"].status-changing {
    animation: waterStatusChange 0.3s ease;
}

/* ============================================
   FREE SHIPPING PROGRESS BAR
   ============================================ */
.vr-free-shipping {
    background: var(--vr-bg);
    border: 1px solid var(--vr-border);
    border-radius: var(--vr-radius-md);
    padding: 16px;
    margin-bottom: 20px;
    transition: all 0.4s ease;
}

/* Progress State (not yet achieved) */
.vr-free-shipping__progress {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.vr-free-shipping__icon {
    font-size: 24px;
    line-height: 1;
    flex-shrink: 0;
}

.vr-free-shipping__content {
    flex: 1;
}

.vr-free-shipping__title {
    display: block;
    font-size: 14px;
    color: var(--vr-text);
    font-weight: 500;
}

.vr-free-shipping__title strong {
    color: var(--vr-primary);
    font-weight: 700;
}

.vr-free-shipping__subtitle {
    display: block;
    font-size: 12px;
    color: var(--vr-text-light);
    margin-top: 2px;
}

/* Progress Bar */
.vr-free-shipping__bar {
    height: 6px;
    background: var(--vr-border);
    border-radius: 3px;
    overflow: hidden;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.vr-free-shipping__bar-fill {
    height: 100%;
    background: linear-gradient(
        90deg,
        var(--vr-primary) 0%,
        #3b82f6 25%,
        var(--vr-primary) 50%,
        #3b82f6 75%,
        var(--vr-primary) 100%
    );
    background-size: 200% 100%;
    border-radius: 3px;
    transition: width 0.5s ease;
    animation: shimmer 2s linear infinite;
}

/* Achieved State (free shipping unlocked) */
.vr-free-shipping--achieved {
    background: linear-gradient(135deg, var(--vr-green-bg) 0%, var(--vr-green-light) 100%);
    border-color: var(--vr-green-border);
}

.vr-free-shipping__achieved {
    display: flex;
    align-items: center;
    gap: 12px;
}

.vr-free-shipping__icon--success {
    font-size: 28px;
}

.vr-free-shipping__title--success {
    font-size: 15px;
    font-weight: 700;
    color: var(--vr-green);
}

/* Stop animation when achieved */
.vr-free-shipping--achieved .vr-free-shipping__bar-fill {
    animation: none;
    background: var(--vr-green);
}

/* Free shipping badge in summary */
.vr-free-shipping-badge {
    color: var(--vr-green);
    font-weight: 600;
    font-size: 14px;
}

/* Celebration animation when threshold reached */
@keyframes celebrate {
    0%, 100% { transform: scale(1); }
    25% { transform: scale(1.05); }
    50% { transform: scale(1); }
    75% { transform: scale(1.02); }
}

.vr-free-shipping--just-achieved {
    animation: celebrate 0.6s ease;
}

/* Free Shipping Responsive */
@media (max-width: 530px) {
    .vr-free-shipping {
        padding: 14px;
    }

    .vr-free-shipping__title {
        font-size: 13px;
    }

    .vr-free-shipping__icon {
        font-size: 20px;
    }

    .vr-free-shipping__subtitle {
        font-size: 11px;
    }
}

/* ============================================
   CROSS-SELLS SECTION
   ============================================ */
.vr-cross-sells {
    padding: 0;
    margin-top: 20px;
}

.vr-cross-sells__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    flex-wrap: wrap;
    gap: 8px;
}

.vr-cross-sells__title {
    font-size: 14px;
    font-weight: 600;
    color: var(--vr-text-light);
    margin: 0;
}

.vr-cross-sells__link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 500;
    color: var(--vr-text-light);
    text-decoration: none;
    transition: var(--vr-transition);
}

.vr-cross-sells__link:hover {
    color: var(--vr-primary-hover);
}

.vr-cross-sells__link svg {
    width: 16px;
    height: 16px;
}

.vr-cross-sells__grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
}

/* Single Cross-sell Item */
.vr-cross-sell-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
    border-bottom: 1px solid var(--vr-border);
}

.vr-cross-sell-item:last-child {
    border-bottom: none;
}

.vr-cross-sell-item:hover .vr-cross-sell-item__name a {
    color: var(--vr-primary);
}

.vr-cross-sell-item__image-link {
    display: block;
    width: 80px;
    height: 80px;
    background: var(--vr-bg);
    border-radius: var(--vr-radius-sm);
    overflow: hidden;
    flex-shrink: 0;
}

.vr-cross-sell-item__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    padding: 0;
}

.vr-cross-sell-item__content {
    flex: 1;
    min-width: 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.vr-cross-sell-item__info {
    flex: 1;
    min-width: 0;
}

.vr-cross-sell-item__name {
    font-size: 13px;
    font-weight: 600;
    margin: 0;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.vr-cross-sell-item__name a {
    color: var(--vr-text);
    text-decoration: none;
}

.vr-cross-sell-item__name a:hover {
    color: var(--vr-primary);
}

.vr-cross-sell-item__purity {
    display: none;
}

.vr-cross-sell-item__subtitle {
    font-size: 11px;
    color: var(--vr-text-light);
    margin: 2px 0 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.vr-cross-sell-item__footer {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.vr-cross-sell-item__price {
    font-size: 13px;
    font-weight: 700;
    color: var(--vr-text);
}

.vr-cross-sell-item__price del {
    font-size: 12px;
    color: var(--vr-text-light);
    font-weight: 400;
}

.vr-cross-sell-item__price ins {
    text-decoration: none;
    color: var(--vr-primary);
}

.vr-cross-sell-item__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 5px 14px;
    background: transparent;
    color: var(--vr-primary);
    border: 1px solid var(--vr-primary);
    border-radius: var(--vr-radius-sm);
    font-size: 12px;
    font-weight: 500;
    text-decoration: none;
    transition: var(--vr-transition);
    white-space: nowrap;
}

.vr-cross-sell-item__btn:hover {
    background: var(--vr-primary);
    color: var(--vr-white);
}

.vr-cross-sell-item__btn svg {
    width: 16px;
    height: 16px;
}

/* Cross-sells Responsive */
@media (max-width: 768px) {
    .vr-cross-sells {
        padding: 0;
    }

    .vr-cross-sell-item {
        gap: 10px;
    }

    .vr-cross-sell-item__image-link {
        width: 60px;
        height: 60px;
    }

    .vr-cross-sell-item__content {
        padding: 0;
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
        min-width: 0;
    }

    .vr-cross-sell-item__info {
        display: flex;
        align-items: baseline;
        gap: 6px;
        width: 100%;
    }

    .vr-cross-sell-item__name {
        font-size: 12px;
    }

    .vr-cross-sell-item__price {
        font-size: 12px;
        flex-shrink: 0;
    }

    .vr-cross-sell-item__footer {
        flex-shrink: 0;
    }

    .vr-cross-sell-item__btn {
        padding: 4px 10px;
        font-size: 11px;
        white-space: nowrap;
    }

    .vr-cross-sell-item__btn svg {
        width: 14px;
        height: 14px;
    }
}

.sale-price {
    justify-content: normal !important;
}

/* ============================================
   COUPON CODE SECTION
   ============================================ */
.vr-coupon-section {
    margin-bottom: 20px;
}

.vr-coupon-section--checkout {
    margin-bottom: 24px;
}

/* Coupon Form - Collapsed State */
.vr-coupon-form {
    background: var(--vr-bg);
    border: 1px solid var(--vr-border);
    border-radius: var(--vr-radius-md);
    overflow: hidden;
    transition: var(--vr-transition);
}

.vr-coupon-form:hover {
    border-color: var(--vr-primary);
}

.vr-coupon-form__header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
    cursor: pointer;
    user-select: none;
    transition: background 0.2s ease;
    background: none;
    border: none;
    width: 100%;
    font: inherit;
    color: inherit;
    text-align: left;
}

.vr-coupon-form__header:hover {
    background: var(--vr-bg-dark);
}

.vr-coupon-form__icon {
    font-size: 18px;
    line-height: 1;
}

.vr-coupon-form__label {
    flex: 1;
    font-size: 14px;
    font-weight: 500;
    color: var(--vr-text);
}

.vr-coupon-form__arrow {
    width: 18px;
    height: 18px;
    color: var(--vr-text-light);
    transition: transform 0.3s ease;
}

.vr-coupon-form--open .vr-coupon-form__arrow {
    transform: rotate(180deg);
}

/* Coupon Form - Expanded Body */
.vr-coupon-form__body {
    padding: 0 16px 16px;
}

.vr-coupon-form__form {
    margin: 0;
}

.vr-coupon-form__input-wrapper {
    display: flex;
    gap: 10px;
    align-items: stretch;
}

.vr-coupon-form__input {
    flex: 1;
    height: 44px;
    padding: 0 14px;
    border: 1px solid var(--vr-border);
    border-radius: var(--vr-radius-sm);
    font-size: 14px;
    font-family: var(--vr-font-primary);
    background: var(--vr-white);
    transition: var(--vr-transition);
    box-sizing: border-box;
}

.vr-coupon-form__input:focus {
    outline: none;
    border-color: var(--vr-primary);
    box-shadow: 0 0 0 3px rgba(26, 107, 154, 0.1);
}

.vr-coupon-form__input::placeholder {
    color: var(--vr-text-muted);
}

.vr-coupon-form__btn {
    height: 44px;
    padding: 0 20px;
    background: var(--vr-primary);
    color: var(--vr-white);
    border: none;
    border-radius: var(--vr-radius-sm);
    font-size: 14px;
    font-weight: 600;
    font-family: var(--vr-font-primary);
    cursor: pointer;
    transition: var(--vr-transition);
    white-space: nowrap;
    box-sizing: border-box;
}

.vr-coupon-form__btn:hover {
    background: var(--vr-primary-hover);
}

.vr-coupon-form__btn:disabled {
    background: var(--vr-border);
    color: var(--vr-text-light);
    cursor: not-allowed;
}

/* Coupon Message */
.vr-coupon-form__message {
    margin: 12px 0 0;
    padding: 10px 12px;
    border-radius: var(--vr-radius-sm);
    font-size: 13px;
}

.vr-coupon-form__message--error {
    background: var(--vr-red-light);
    color: var(--vr-red);
    border: 1px solid var(--vr-red-border);
}

.vr-coupon-form__message--success {
    background: var(--vr-green-bg);
    color: var(--vr-green);
    border: 1px solid var(--vr-green-border);
}

/* Applied Coupon Display */
.vr-coupon-applied {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.vr-coupon-applied__item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: linear-gradient(135deg, var(--vr-green-bg) 0%, var(--vr-green-light) 100%);
    border: 1px solid var(--vr-green-border);
    border-radius: var(--vr-radius-md);
}

.vr-coupon-applied__icon {
    font-size: 18px;
    line-height: 1;
    flex-shrink: 0;
}

.vr-coupon-applied__info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.vr-coupon-applied__code {
    font-size: 14px;
    font-weight: 600;
    color: var(--vr-green);
    letter-spacing: 0.5px;
}

.vr-coupon-applied__discount {
    font-size: 13px;
    font-weight: 600;
    color: var(--vr-green);
}

.vr-coupon-applied__remove {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: transparent;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    color: var(--vr-text-light);
    transition: var(--vr-transition);
    text-decoration: none;
}

.vr-coupon-applied__remove:hover {
    background: var(--vr-red-light);
    color: var(--vr-red);
}

.vr-coupon-applied__remove svg {
    width: 16px;
    height: 16px;
}

/* Discount Row in Summary */
.vr-cart__summary-row--discount .vr-cart__summary-value--discount {
    color: var(--vr-green);
    font-weight: 600;
}

/* Checkout discount row */
.vr-summary-item--discount .vr-summary-item__price--discount {
    color: var(--vr-green);
    font-weight: 600;
}

/* ============================================
   COUPON RESPONSIVE
   ============================================ */
@media (max-width: 530px) {
    .vr-coupon-form__input-wrapper {
        flex-direction: column !important;
        gap: 12px !important;
    }

    .vr-coupon-form__input,
    .vr-coupon-form .vr-coupon-form__input,
    input.vr-coupon-form__input {
        width: 100% !important;
        height: 50px !important;
        padding: 0 16px !important;
        font-size: 16px !important;
        -webkit-appearance: none !important;
        border-radius: 10px !important;
        box-sizing: border-box !important;
        min-height: 50px !important;
    }

    .vr-coupon-form__btn,
    .vr-coupon-form .vr-coupon-form__btn,
    button.vr-coupon-form__btn {
        width: 100% !important;
        height: 50px !important;
        font-size: 16px !important;
        text-align: center !important;
        border-radius: 10px !important;
        padding: 0 20px !important;
        min-height: 50px !important;
    }

    .vr-coupon-form__header {
        padding: 14px 16px !important;
    }

    .vr-coupon-form__label {
        font-size: 15px !important;
    }

    .vr-coupon-form__body {
        padding: 0 16px 16px !important;
    }

    .vr-coupon-applied__item {
        padding: 14px 16px !important;
    }

    .vr-coupon-applied__info {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 4px !important;
    }

    .vr-coupon-applied__code {
        font-size: 15px !important;
    }

    .vr-coupon-applied__discount {
        font-size: 14px !important;
    }
}

/* ============================================
   SHIPPING COUNTDOWN (cart page)
   ============================================ */

/* Base .vr-info-banner styles (from single-products.css) */
.vr-info-banner {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: linear-gradient(135deg, var(--vr-icon-bg-blue) 0%, #bfdbfe 100%);
    border-radius: var(--vr-radius-md);
}

.vr-info-banner svg {
    width: 24px;
    height: 24px;
    color: var(--vr-primary);
    flex-shrink: 0;
}

.vr-info-banner strong {
    display: block;
    font-size: 14px;
    color: var(--vr-text);
}

.vr-info-banner span {
    font-size: 13px;
    color: var(--vr-text-light);
}

/* Cart countdown wrapper */
.vr-cart-countdown {
    margin-top: 16px;
    margin-bottom: 16px;
}

.vr-cart-countdown .vr-info-banner {
    flex-direction: column;
    text-align: center;
    gap: 8px;
    padding: 14px 16px;
    border: 1px solid var(--vr-border);
}

.vr-cart-countdown .vr-info-banner--active {
    border-color: var(--vr-green-border) !important;
}

/* Hide subtitle on cart — too verbose for sidebar */
.vr-cart-countdown .vr-info-banner__content > span {
    display: none;
}

.vr-cart-countdown .vr-info-banner strong {
    font-size: 13px;
}

/* Ensure timer digit colors */
.vr-cart-countdown .vr-countdown-time,
.vr-cart-countdown .vr-countdown-sep {
    color: var(--vr-white) !important;
}

.vr-cart-countdown .vr-countdown-timer {
    margin-left: 0;
}

.vr-cart-countdown .vr-info-banner svg {
    width: 22px;
    height: 22px;
}

/* ============================================
   TOAST NOTIFICATIONS
   ============================================ */
.vr-toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: var(--vr-text);
    color: var(--vr-white);
    padding: 12px 24px;
    border-radius: 10px;
    font-size: 14px;
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    max-width: calc(100% - 32px);
    text-align: center;
    box-shadow: var(--vr-shadow-md);
}

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

/* ============================================
   STICKY CHECKOUT BAR (mobile)
   ============================================ */
.vr-sticky-checkout {
    display: none;
}

@media (max-width: 768px) {
    .vr-sticky-checkout {
        display: block;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 999;
        background: var(--vr-white);
        border-top: 1px solid var(--vr-border);
        box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.08);
        transform: translateY(100%);
        transition: transform 0.3s ease;
    }

    .vr-sticky-checkout--visible {
        transform: translateY(0);
    }

    .vr-sticky-checkout__inner {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 12px 16px;
        max-width: var(--vr-container-max);
        margin: 0 auto;
    }

    .vr-sticky-checkout__label {
        font-size: 12px;
        color: var(--vr-text-light);
        display: block;
    }

    .vr-sticky-checkout__price {
        font-size: 18px;
        font-weight: 700;
        color: var(--vr-text);
    }

    .vr-sticky-checkout__btn {
        display: inline-flex;
        align-items: center;
        gap: 6px;
        padding: 12px 28px;
        background: var(--vr-primary);
        color: var(--vr-white);
        border-radius: var(--vr-radius-md);
        font-size: 15px;
        font-weight: 600;
        text-decoration: none;
        white-space: nowrap;
    }

    .vr-sticky-checkout__btn svg {
        width: 16px;
        height: 16px;
    }

    .vr-sticky-checkout__btn:hover {
        background: var(--vr-primary-hover);
        color: var(--vr-white);
    }

    /* Prevent content from being hidden behind sticky bar */
    .woocommerce-cart {
        padding-bottom: 70px;
    }

    /* Move toast above sticky bar */
    .vr-toast {
        bottom: 80px;
    }
}
