/*
 * EMPOLAS Promo Timer. Every visual value comes from per-campaign CSS variables
 * (set inline on .ept-promo) with safe fallbacks. Rules are scoped to plugin elements
 * and reset common theme/Divi inheritance so they never alter the product layout.
 */
.ept-promos {
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    /* Own full row inside block, flex (wrapping) or grid cart layouts. */
    flex: 0 0 100%;
    grid-column: 1 / -1;
    float: none;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    margin: 0;
    padding: 0;
    color: inherit;
    font-family: inherit;
}
.ept-promos[hidden], .ept-promos .ept-promo[hidden], .ept-promos .ept-promo__timer[hidden] { display: none !important; }

/* A flex cart row must wrap so the notice gets its own line above quantity + button. */
:has(> .ept-promos--single:not([hidden])) { flex-wrap: wrap !important; }

.ept-promos .ept-promo {
    --ept-fs: var(--ept-fs-loop, 12px);
    --ept-scale: 1;
    box-sizing: border-box;
    display: block;
    position: static;
    float: none;
    /* A narrower block follows the text alignment. */
    align-self: var(--ept-self, flex-start);
    width: var(--ept-width, 100%);
    max-width: 100%;
    min-width: 0;
    margin: var(--ept-mt, 4px) 0 var(--ept-mb, 8px);
    padding: calc(var(--ept-py, 5px) * var(--ept-scale)) calc(var(--ept-px, 8px) * var(--ept-scale));
    border-style: var(--ept-bs, none);
    border-width: var(--ept-bw, 1px);
    border-color: var(--ept-bc, currentColor);
    border-radius: var(--ept-radius, 3px);
    background: var(--ept-bg, #e8f0fa);
    box-shadow: none;
    color: var(--ept-color, #0f4596);
    font-family: var(--ept-font, inherit);
    font-size: var(--ept-fs);
    font-style: normal;
    font-weight: var(--ept-weight, 400);
    line-height: var(--ept-lh, 1.35);
    letter-spacing: normal;
    text-align: var(--ept-align, left);
    text-transform: var(--ept-transform, none);
    text-decoration: none;
    overflow-wrap: anywhere;
    word-break: normal;
}
.ept-promos--single .ept-promo { --ept-fs: var(--ept-fs-single, 14px); }

.ept-promos .ept-promo .ept-promo__text,
.ept-promos .ept-promo .ept-promo__text p,
.ept-promos .ept-promo .ept-promo__text div,
.ept-promos .ept-promo .ept-promo__text ul,
.ept-promos .ept-promo .ept-promo__text ol,
.ept-promos .ept-promo .ept-promo__text li {
    color: inherit;
    font-family: inherit;
    font-size: inherit;
    font-weight: inherit;
    line-height: inherit;
    letter-spacing: inherit;
    text-transform: inherit;
    background: none;
    border: 0;
}
.ept-promos .ept-promo .ept-promo__text { display: block; margin: 0; padding: 0; }
.ept-promos .ept-promo .ept-promo__text p { margin: 0 0 .35em; padding: 0; }
.ept-promos .ept-promo .ept-promo__text > :last-child { margin-bottom: 0; }
.ept-promos .ept-promo .ept-promo__text strong, .ept-promos .ept-promo .ept-promo__text b { font-weight: 700; }
.ept-promos .ept-promo .ept-promo__text ul, .ept-promos .ept-promo .ept-promo__text ol { margin: 0 0 .35em; padding: 0 0 0 1.25em; list-style-position: outside; }
.ept-promos .ept-promo .ept-promo__text ul { list-style-type: disc; }
.ept-promos .ept-promo .ept-promo__text ol { list-style-type: decimal; }
.ept-promos .ept-promo .ept-promo__text li { display: list-item; width: auto; float: none; margin: 0; padding: 0; }

.ept-promos .ept-promo .ept-promo__timer {
    display: block;
    margin: .2em 0 0;
    padding: 0;
    border: 0;
    background: none;
    color: var(--ept-timer-color, currentColor);
    font-family: inherit;
    font-size: var(--ept-timer-size, 100%);
    font-weight: var(--ept-timer-weight, 600);
    line-height: 1.3;
    font-variant-numeric: tabular-nums;
    white-space: normal;
}

/* Coupon chip from [kod]: follows the notice colours and resets theme button styles. */
.ept-promos .ept-promo .ept-code {
    all: unset;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    gap: .35em;
    max-width: 100%;
    margin: 0 .1em;
    padding: .1em .45em;
    border: 1px dashed currentColor;
    border-radius: 4px;
    background: transparent;
    background: color-mix(in srgb, currentColor 10%, transparent);
    color: inherit;
    font: inherit;
    font-weight: 700;
    letter-spacing: .03em;
    line-height: inherit;
    /* Shown exactly as it is copied. */
    text-transform: none;
    vertical-align: baseline;
    cursor: pointer;
    transition: background-color .15s, border-color .15s, color .15s;
    -webkit-tap-highlight-color: transparent;
}
.ept-promos .ept-promo .ept-code:hover { background: color-mix(in srgb, currentColor 18%, transparent); }
.ept-promos .ept-promo .ept-code:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
.ept-promos .ept-promo .ept-code__value { min-width: 0; overflow-wrap: anywhere; -webkit-user-select: text; user-select: text; }
.ept-promos .ept-promo .ept-code__icon { display: inline-flex; flex: none; }
.ept-promos .ept-promo .ept-code svg { width: 1em; height: 1em; }
.ept-promos .ept-promo .ept-code .ept-code__copy { display: block; }
.ept-promos .ept-promo .ept-code .ept-code__check { display: none; }
.ept-promos .ept-promo .ept-code.is-copied { border-style: solid; border-color: #2e7d32; background: #e8f5e9; color: #1b5e20; }
.ept-promos .ept-promo .ept-code.is-copied .ept-code__copy { display: none; }
.ept-promos .ept-promo .ept-code.is-copied .ept-code__check { display: block; }
/* Larger invisible tap area on touch screens, without changing the line height. */
@media (pointer: coarse) {
    .ept-promos .ept-promo .ept-code { position: relative; }
    .ept-promos .ept-promo .ept-code::after { content: ""; position: absolute; inset: -8px -6px; }
}
.ept-sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

@media (max-width: 767px) {
    .ept-promos .ept-promo { --ept-fs: var(--ept-fs-loop-m, 11px); --ept-scale: .75; }
    .ept-promos--single .ept-promo { --ept-fs: var(--ept-fs-single-m, 13px); }
}
