/* Cart gift — linear progress */
.ck-gift {
    --cg-brand: #6fbf3a;
    --cg-brand-dark: #4f9a22;
    --cg-ink: #1f2a1a;
    --cg-muted: #5f6d58;
    --cg-line: #d9e8c8;
    --cg-gold: #d4a017;
    position: relative;
    margin-top: 1.15rem;
    overflow: hidden;
    border-radius: 16px;
    border: 1px solid var(--cg-line);
    background: linear-gradient(145deg, #f7fbf2, #eef7e4 55%, #fff9e8);
    box-shadow: 0 8px 22px rgba(50, 80, 30, .06);
    padding: .9rem 1rem;
    transition: border-color .25s ease, box-shadow .25s ease, transform .25s ease;
}

.ck-gift.is-unlocked {
    border-color: #b8e08a;
    box-shadow: 0 12px 28px rgba(79, 154, 34, .12);
    background: linear-gradient(145deg, #f3faea, #e8f6d8 50%, #fff6d4);
}

.ck-gift.is-pop {
    animation: ckGiftPop .55s ease;
}

@keyframes ckGiftPop {
    0% { transform: scale(.985); }
    45% { transform: scale(1.012); }
    100% { transform: scale(1); }
}

.ck-gift.is-linear {
    display: block;
}

.ck-gift-line {
    position: relative;
    z-index: 1;
}

.ck-gift-line-top {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: .75rem;
    margin-bottom: .55rem;
}

.ck-gift-line-pct {
    font-size: 1.05rem;
    font-weight: 900;
    color: var(--cg-ink);
    font-variant-numeric: tabular-nums;
    line-height: 1;
}

.ck-gift-line-goal {
    font-size: .78rem;
    font-weight: 800;
    color: var(--cg-muted);
}

.ck-gift-track-line {
    position: relative;
    height: 12px;
    border-radius: 999px;
    background: rgba(79, 154, 34, .12);
    overflow: visible;
}

.ck-gift-fill {
    display: block;
    height: 100%;
    width: 0;
    border-radius: inherit;
    background: linear-gradient(90deg, #8ed557 0%, #4f9a22 65%, #d4a017 100%);
    background-size: 200% 100%;
    box-shadow: 0 0 12px rgba(111, 191, 58, .35);
    transition: width .75s cubic-bezier(.22, 1, .36, 1);
    animation: ckGiftShimmer 2.4s linear infinite;
}

.ck-gift.is-unlocked .ck-gift-fill {
    background: linear-gradient(90deg, #d4a017, #6fbf3a);
    animation: none;
}

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

.ck-gift-thumb {
    position: absolute;
    top: 50%;
    width: 18px;
    height: 18px;
    margin-inline-start: -9px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid #6fbf3a;
    box-shadow: 0 2px 8px rgba(50, 80, 30, .18);
    transform: translateY(-50%);
    transition: inset-inline-start .75s cubic-bezier(.22, 1, .36, 1), border-color .25s ease;
    pointer-events: none;
}

.ck-gift.is-unlocked .ck-gift-thumb {
    border-color: #d4a017;
    background: #fff8df;
}

.ck-gift-marks {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: .35rem;
    margin-top: .55rem;
}

.ck-gift-marks span {
    text-align: center;
    font-size: .68rem;
    font-weight: 800;
    color: #7a8b70;
    position: relative;
    padding-top: .45rem;
}

.ck-gift-marks span::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    transform: translateX(-50%);
    background: #c5d6b6;
    transition: background .25s ease, box-shadow .25s ease;
}

.ck-gift-marks span.is-on {
    color: var(--cg-brand-dark);
}

.ck-gift-marks span.is-on::before {
    background: var(--cg-brand);
    box-shadow: 0 0 0 3px rgba(111, 191, 58, .22);
}

.ck-gift-marks span.is-done::before {
    background: var(--cg-gold);
    box-shadow: 0 0 0 3px rgba(212, 160, 23, .2);
}

.ck-gift-sr {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}

.ck-gift-burst {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
}

.ck-gift-burst i {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #ffe9a0, #d4a017);
    animation: ckGiftCoin .95s ease forwards;
}

@keyframes ckGiftCoin {
    0% { opacity: 0; transform: translateY(12px) scale(.4); }
    20% { opacity: 1; }
    100% { opacity: 0; transform: translateY(-48px) scale(1); }
}

/* Mini — header dropdown */
.ck-gift.is-mini {
    margin: 0;
    padding: .55rem .75rem .65rem;
    border-radius: 0;
    border: 0;
    border-bottom: 1px solid #eef1f4;
    box-shadow: none;
}

.ck-gift.is-mini .ck-gift-line-pct {
    font-size: .86rem;
}

.ck-gift.is-mini .ck-gift-track-line {
    height: 8px;
}

.ck-gift.is-mini .ck-gift-thumb {
    width: 14px;
    height: 14px;
    margin-inline-start: -7px;
    border-width: 2px;
}

.mc-gift-slot {
    background: #fff;
}

/* Header cart icon ring (compact) */
.mc-trigger.has-gift-ring {
    width: 46px;
    height: 46px;
}

.mc-gift-ring {
    position: absolute;
    inset: -4px;
    pointer-events: none;
    z-index: 1;
}

.mc-gift-ring svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.mc-gift-ring-track {
    fill: none;
    stroke: rgba(127, 201, 69, .18);
    stroke-width: 3;
}

.mc-gift-ring-arc {
    fill: none;
    stroke: #6fbf3a;
    stroke-width: 3;
    stroke-linecap: round;
    transition: stroke-dashoffset .7s cubic-bezier(.22, 1, .36, 1), stroke .25s ease;
}

.mc-gift-ring.is-unlocked .mc-gift-ring-arc {
    stroke: #d4a017;
}

.mc-gift-ring em {
    position: absolute;
    left: 50%;
    top: -2px;
    transform: translateX(-50%);
    min-width: 18px;
    height: 14px;
    padding: 0 3px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid #cfe6b4;
    color: #4f9a22;
    font-size: .58rem;
    font-weight: 900;
    font-style: normal;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    box-shadow: 0 2px 6px rgba(79, 154, 34, .12);
}

.mc-gift-ring.is-unlocked em {
    border-color: #f0d57a;
    color: #9a6b00;
    background: #fff8df;
}

.mc-trigger .mc-cart-ico {
    position: relative;
    z-index: 2;
}

.ck-page > .container > .ck-gift {
    margin-top: 0;
    margin-bottom: 1rem;
}

@media (max-width: 720px) {
    .ck-gift {
        padding: .8rem .85rem;
    }
    .ck-gift-line-pct {
        font-size: .95rem;
    }
}
