/* === Variables and Defaults === */
:root {
    /* Fallbacks if not injected by PHP */
    --wooboost-primary: #000000;
    --wooboost-urgency: #d63031;
    --wooboost-radius: 4px;
    --wooboost-tablet-bp: 1024px;
    --wooboost-mobile-bp: 767px;
}


/* === Sticky Bar === */
.wooboost-sticky-bar {
    position: fixed;
    left: 0;
    width: 100%;
    background: #353D4F;
    /* Updated background color */
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.08);
    z-index: 9999;
    padding: 12px 0;
    transition: transform 0.4s cubic-bezier(0.19, 1, 0.22, 1);
    color: #fff;
    /* Ensure text is visible on dark bg */
}

/* ... existing media queries ... */
/* Desktop: Top */
@media (min-width: 768px) {
    .wooboost-sticky-bar {
        top: 0;
        bottom: auto;
        border-bottom: 1px solid #4a5568;
        /* Darker border */
        transform: translateY(-100%);
    }
    .wooboost-sticky-bar.visible {
        transform: translateY(0);
    }

    /* ... */
}

/* Mobile: Bottom */
@media (max-width: 767px) {
    .wooboost-sticky-bar {
        bottom: 0;
        top: auto;
        border-top: 1px solid #4a5568;
        /* Darker border */
        transform: translateY(100%);
        padding: 10px 0;
    }
    .wooboost-sticky-bar.visible {
        transform: translateY(0);
    }

    /* ... */
}

.wooboost-sticky-title {
    color: #fff;
    /* White title on dark bg */
}

.wooboost-sticky-price {
    color: #e2e8f0;
    /* Light text for price */
}

.wooboost-sticky-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.wooboost-sticky-product {
    display: flex;
    align-items: center;
    gap: 15px;
    flex: 1;
    /* Allow it to take space */
}

.wooboost-sticky-variations {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.wooboost-sticky-variations .variations {
    border: none;
    margin: 0;
}

.wooboost-sticky-variations .variations td,
.wooboost-sticky-variations .variations th {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0;
    border: none;
    background: transparent !important;
}

.wooboost-sticky-variations label {
    color: inherit;
    /* Inherit from bar text color */
    margin: 0;
    font-size: 13px;
    font-weight: 600;
}

/* Compact variation styles for sticky bar */
.wooboost-sticky-variations table.variations {
    margin: 0;
    width: auto;
}

.wooboost-sticky-variations table.variations td,
.wooboost-sticky-variations table.variations th {
    padding: 0 5px;
    background: transparent;
    /* Remove table bg */
    border: none;
    color: #fff;
    display: block;
    /* Stack label and value for compactness if needed, or flex */
}

.wooboost-sticky-variations label {
    color: #ccc;
    font-size: 12px;
    margin-bottom: 2px;
}

/* Styling for the Buy Now button in sticky bar */
.wooboost-sticky-btn-buy {
    background: #fff;
    color: #353D4F;
    /* High contrast */
    border: none;
    padding: 12px 30px;
    border-radius: var(--wooboost-radius);
    cursor: pointer;
    font-weight: 700;
    font-size: 15px;
    text-transform: uppercase;
    transition: all 0.2s;
    white-space: nowrap;
}

.wooboost-sticky-btn-buy:hover {
    background: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

/* Disabled state */
.wooboost-sticky-btn-buy.disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* === Urgency Elements === */
.wooboost-stock-progress {
    margin: 20px 0;
    padding: 15px;
    background: #fff;
    /* Cleaner look */
    border: 1px solid #f0f0f0;
    border-radius: var(--wooboost-radius);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.stock-text {
    color: var(--wooboost-urgency);
    font-weight: 700;
    margin-bottom: 8px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.progress-bar {
    width: 100%;
    height: 10px;
    background: #f0f0f0;
    border-radius: 10px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--wooboost-urgency);
    transition: width 1s ease-out;
    border-radius: 10px;
    position: relative;
    overflow: hidden;
}

/* Shimmer effect for progress bar */
.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background-image: linear-gradient(-45deg,
            rgba(255, 255, 255, 0) 25%,
            rgba(255, 255, 255, 0.3) 50%,
            rgba(255, 255, 255, 0) 75%);
    background-size: 20px 20px;
    animation: move 2s linear infinite;
}

.wooboost-trust-badges {
    display: flex;
    gap: 20px;
    margin-top: 20px;
    flex-wrap: wrap;
    padding: 15px;
    background: #fafafa;
    border-radius: var(--wooboost-radius);
}

.badge-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 500;
    color: #444;
}

.wooboost-countdown {
    margin: 25px 0;
    background: #fff;
    padding: 20px;
    border-radius: var(--wooboost-radius);
    border: 1px solid #eee;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.03);
    border-left: 4px solid var(--wooboost-urgency);
}

.wooboost-countdown h5 {
    margin: 0 0 15px;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 1px;
    color: var(--wooboost-urgency);
}

.timer-display {
    display: flex;
    gap: 20px;
}

.time-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-weight: 800;
    font-size: 22px;
    color: #333;
    line-height: 1;
}

.time-block small {
    margin-top: 5px;
    font-weight: 600;
    font-size: 10px;
    text-transform: uppercase;
    color: #999;
}

/* === Upsell === */
.wooboost-tiered-pricing {
    margin: 25px 0;
    border-radius: var(--wooboost-radius);
    overflow: hidden;
    border: 1px solid #eee;
}

.wooboost-tiered-pricing table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.wooboost-tiered-pricing th,
.wooboost-tiered-pricing td {
    border-bottom: 1px solid #eee;
    padding: 12px;
    text-align: center;
}

.wooboost-tiered-pricing th {
    background: #f9f9f9;
    font-weight: 600;
    color: #333;
}

.wooboost-freq-bought {
    margin-top: 40px;
    padding: 25px;
    background: #fff;
    border: 1px solid #eee;
    border-radius: var(--wooboost-radius);
}

.wooboost-freq-bought h3 {
    margin-top: 0;
    font-size: 20px;
    margin-bottom: 25px;
    font-weight: 700;
    font-weight: 700;
}

.freq-list {
    display: flex;
    gap: 20px;
}

.freq-item {
    flex: 1;
    text-align: center;
    background: #fff;
    padding: 10px;
    border-radius: var(--wooboost-radius);
    transition: box-shadow 0.2s;
}

.freq-item:hover {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.freq-item img {
    margin-bottom: 15px;
    border-radius: var(--wooboost-radius);
    width: 100%;
}

.freq-item p {
    font-size: 14px;
    margin: 10px 0;
    height: 40px;
    overflow: hidden;
    line-height: 1.4;
    color: #444;
}

.freq-item .button {
    width: 100%;
    background: var(--wooboost-primary) !important;
    color: #fff !important;
    border-radius: var(--wooboost-radius) !important;
}

/* === Button Styling === */
/* Add to Cart */
.single_add_to_cart_button,
button.single_add_to_cart_button.button.alt {
    background-color: var(--wooboost-atc-bg, #000000) !important;
    color: var(--wooboost-atc-text, #ffffff) !important;
    border-radius: var(--wooboost-radius, 4px) !important;
    padding: 15px 30px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.single_add_to_cart_button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
    opacity: 0.95;
}

/* Buy Now */
.wooboost-buy-now-btn {
    background-color: var(--wooboost-bn-bg, #f1c40f) !important;
    color: var(--wooboost-bn-text, #000000) !important;
    border-radius: var(--wooboost-radius, 4px) !important;
    padding: 15px 30px;
    font-weight: 700;
    margin-left: 10px;
    /* Space between buttons */
    transition: all 0.3s ease;
    border: none;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    display: inline-block;
    vertical-align: middle;
}

.wooboost-buy-now-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
    opacity: 0.95;
}

/* Mobile Adjustments for Buttons */
@media (max-width: 767px) {
    .wooboost-buy-now-btn {
        margin-left: 0;
        margin-top: 10px;
        width: 100%;
        text-align: center;
        display: block;
    }

    .single_add_to_cart_button {
        width: 100%;
    }
}

/* === Sticky Bar Visibility === */
/* Desktop: > 1024px */
@media (min-width: 1025px) {
    .wooboost-hide-desktop {
        display: none !important;
    }
}

/* Tablet: 768px - 1024px */
@media (min-width: 768px) and (max-width: 1024px) {
    .wooboost-hide-tablet {
        display: none !important;
    }
}

/* Mobile: <= 767px */
@media (max-width: 767px) {
    .wooboost-hide-mobile {
        display: none !important;
    }
}

/* Override Table Row Background */
table tbody>tr:nth-child(odd)>td,
table tbody>tr:nth-child(odd)>th {
    background-color: white;
}
