/* Promotional block on the product page. Deliberately quiet: no popups, no countdowns. */

.mypointi-cpr-promo {
    /* Single source of the promotional colour, so a child theme can match the brand with
       one declaration instead of overriding every rule below. */
    --mypointi-cpr-accent: #2e7d32;
    /* The deadline runs on its own colour: it is urgency, not the offer. */
    --mypointi-cpr-deadline: #f07c1d;
    /* The top margin is not decoration: without it the block glues itself to whatever the
       theme prints above (price, rating) and stops reading as a separate notice. */
    margin: 1.5em 0 1.25em;
    padding: .9em 1em;
    border: 1px solid rgba(0, 0, 0, .12);
    border-left: 3px solid var(--mypointi-cpr-accent);
    border-radius: 4px;
    background: rgba(0, 0, 0, .02);
    font-size: .95em;
    line-height: 1.45;
}

.mypointi-cpr-promo__title {
    margin: 0 0 .35em;
    color: var(--mypointi-cpr-accent);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .02em;
    font-size: .9em;
}

/* Free copy from the admin: the one paragraph nobody derives. */
.mypointi-cpr-promo__text {
    margin: 0 0 .7em;
}

/* The mechanics, plain. No ticks: with the box down to one line of them, a checklist of
   one read as decoration rather than as a list. */
.mypointi-cpr-promo__list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.mypointi-cpr-promo__line {
    margin: 0 0 .3em;
}

.mypointi-cpr-promo__line:last-child {
    margin-bottom: 0;
}

.mypointi-cpr-promo__gift {
    display: flex;
    align-items: center;
    gap: .85em;
}

.mypointi-cpr-promo__image {
    flex: 0 0 auto;
    width: 72px;
    height: 72px;
    object-fit: cover;
    border-radius: 4px;
}

.mypointi-cpr-promo__body {
    min-width: 0;
}

.mypointi-cpr-promo__link {
    display: inline-block;
    margin-top: .2em;
    font-size: .9em;
    text-decoration: underline;
}

.mypointi-cpr-promo__state {
    margin: .5em 0 0;
    font-size: .88em;
    opacity: .8;
}

.mypointi-cpr-promo.is-applied .mypointi-cpr-promo__state {
    font-weight: 600;
    opacity: 1;
}

/* Reassurance, not argument — small and quiet at the foot of the box. Dimmed by opacity
   rather than a fixed grey, so it stays readable on a dark theme too. */
.mypointi-cpr-promo__footnote {
    margin: .8em 0 0;
    font-size: .85em;
    opacity: .7;
}

/* Deadline. The date carries the colour; the last-days badge still raises its voice. */
/* The deadline is the loudest thing in the box after the headline: it is the only part
   that stops being true, so it is the only part with a reason to shout. */
.mypointi-cpr-promo__deadline {
    margin: .8em 0 0;
    padding-left: 1.5em;
    position: relative;
    color: var(--mypointi-cpr-deadline);
    font-size: 1.15em;
    font-weight: 700;
}

.mypointi-cpr-promo__deadline::before {
    content: "\23F0";
    position: absolute;
    left: 0;
}

.mypointi-cpr-promo__urgency {
    display: inline-block;
    margin-left: .35em;
    padding: .1em .5em;
    border-radius: 3px;
    background: #b3261e;
    color: #fff;
    font-size: .85em;
    text-transform: uppercase;
    letter-spacing: .03em;
    vertical-align: middle;
}

/* Gift line in the cart. */
.mypointi-cpr-gift-badge {
    display: inline-block;
    margin-left: .4em;
    padding: .1em .5em;
    border-radius: 3px;
    background: #2e7d32;
    color: #fff;
    font-size: .75em;
    text-transform: uppercase;
    letter-spacing: .03em;
    vertical-align: middle;
}

/* The saving, on the product's own line in the cart (classic template and Cart block). */
.mypointi-cpr-cart-saving,
.mypointi-cpr-cart-saving .amount,
.mypointi-cpr-cart-saving .woocommerce-Price-amount {
    color: #2e7d32;
    font-weight: 600;
}

@media (max-width: 480px) {
    .mypointi-cpr-promo__gift {
        gap: .6em;
    }

    .mypointi-cpr-promo__image {
        width: 56px;
        height: 56px;
    }
}
