
/* ==========================================================================
   Cart Progress Bar
   ========================================================================== */

/*
 * Color tokens — override these to theme the bar.
 * On block themes, FreebieTierProgressListener injects values from the
 * theme's global color palette via wp_add_inline_style().
 */
.cart-progress {
    --nuclii-progress-accent:   #cb5024;
    --nuclii-progress-complete: #3d7b3c;
    --nuclii-progress-track:    #dfe3e4;
    --nuclii-progress-pending:  #999;
    --nuclii-progress-bg:       #fff;
}

.cart-progress {
    position: relative;
    display: flex;
    margin-bottom: 32px;
    padding-top: 22px; /* space for the track + dots above labels */
}

.cart-progress .progress-track {
    position: absolute;
    top: 11px; /* centers on the 22px-tall dot (14px + 4px*2 border) */
    left: 0;
    width: 100%;
    height: 5px;
    background-color: var(--nuclii-progress-track);
    border-radius: 3px;
    overflow: hidden;
}

.cart-progress .progress-fill {
    height: 100%;
    background: var(--nuclii-progress-accent);
    border-radius: 3px;
    transition: width 0.8s ease-in-out;
}

.cart-progress .progress-step {
    position: relative;
    flex: 1;
    font-size: 11px;
    text-align: center;
    z-index: 1;
}

.cart-progress .progress-step img {
    width: 40px;
    margin: 0 auto;
    display: block;
    margin-top: 8px;
}

/* Dot marker */
.cart-progress .progress-step:before {
    content: "\2713";
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto;
    margin-bottom: 6px;
    width: 14px;
    height: 14px;
    background: var(--nuclii-progress-bg);
    border: 4px solid var(--nuclii-progress-track);
    border-radius: 100%;
    color: transparent;
    font-size: 9px;
    position: relative;
    z-index: 2;
}

/* Active step — pulsing border */
.cart-progress .progress-step.is-active:before {
    border: 4px solid var(--nuclii-progress-accent);
    animation: nuclii-pulse 2s infinite;
}

/* Pending steps */
.cart-progress .progress-step.is-pending:before {
    border: 4px solid var(--nuclii-progress-track);
}

/* Complete step — green dot with checkmark */
.cart-progress .progress-step.is-complete:before {
    font-size: 9px;
    color: var(--nuclii-progress-bg);
    background: var(--nuclii-progress-complete);
    border: 4px solid transparent;
}

@keyframes nuclii-pulse {
    0%   { box-shadow: 0 0 0 0   rgba(0, 0, 0, 0.25); }
    70%  { box-shadow: 0 0 0 8px rgba(0, 0, 0, 0); }
    100% { box-shadow: 0 0 0 0   rgba(0, 0, 0, 0); }
}

/* ==========================================================================
   Mini Cart context overrides
   ========================================================================== */

.nuclii-freebie-mini-cart-bar {
    border-top: 1px solid #e0e0e0;
    background: #fff;
}

.nuclii-freebie-mini-cart-bar .cart-progress {
    margin-bottom: 16px;
    padding: 16px 16px 0;
    font-size: 10px;
}

.nuclii-freebie-mini-cart-bar .cart-progress .progress-step img {
    width: 28px;
    margin-top: 6px;
}

.nuclii-freebie-mini-cart-bar .cart-progress .tier-text {
    font-size: 10px;
    line-height: 1.3;
}
