/* --
   Lumiere Popup - Minimalist Black & White
   RTL-first design (Hebrew / Arabic sites)
   -- */

.lmp-overlay {
    display: none;
    position: fixed;
    top: 0; right: 0; bottom: 0; left: 0;
    background: rgba(0, 0, 0, 0.78);
    z-index: 999999;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
    direction: rtl;
}

.lmp-overlay.lmp-visible {
    display: flex;
}

/* animate in */
.lmp-popup {
    position: relative;
    background: #ffffff;
    color: #000000;
    max-width: 540px;
    width: 100%;
    padding: 54px 50px 48px;
    box-sizing: border-box;
    font-family: inherit;
    direction: rtl;
    text-align: right;
    animation: lmpSlideIn 0.38s cubic-bezier(0.22, 0.61, 0.36, 1) both;
}

@keyframes lmpSlideIn {
    from { opacity: 0; transform: translateY(-18px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* -- Content areas inherit RTL -- */
.lmp-content,
.lmp-html-content {
    direction: rtl;
    text-align: right;
    line-height: 1.7;
}

/* -- Title -- */
.lmp-title {
    font-size: 20px;
    font-weight: 600;
    letter-spacing: 0.04em;
    margin: 0 0 14px;
    color: #000;
    line-height: 1.3;
    direction: rtl;
    text-align: right;
}

/* -- Message area --
   direction and text-align are always overridden by the dynamic
   inline <style id="lmp-design"> from admin settings.
   Rules here are fallbacks. */
.lmp-message {
    font-size: 15px;
    line-height: 1.75;
    color: #333;
    margin: 0 0 30px;
    direction: rtl;
    text-align: right;
}

/* Paragraph spacing from TinyMCE Enter key.
   Many themes reset p{margin:0} globally - we restore it here
   so Enter key creates visible breaks in the popup. */
.lmp-message p {
    margin: 0 0 0.85em;
    direction: rtl;
    text-align: inherit;
}
.lmp-message p:last-child {
    margin-bottom: 0;
}

/* Force RTL on inline spans TinyMCE might emit */
.lmp-message span,
.lmp-message div {
    unicode-bidi: plaintext;
}

/* -- Close button --
   Positioned on physical-left = logical-start for RTL content */
.lmp-close {
    position: absolute;
    top: 14px;
    left: 18px;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 26px;
    line-height: 1;
    color: #000;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.35;
    transition: opacity 0.2s;
}
.lmp-close:hover { opacity: 1; }

/* -- Image -- */
.lmp-image {
    margin-bottom: 28px;
    overflow: hidden;
}
.lmp-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* -- CTA Button area --
   flex-start in RTL flex container = right side of popup */
.lmp-actions {
    display: flex;
    justify-content: flex-start;
    direction: rtl;
}

.lmp-btn {
    display: inline-block;
    background: #000;
    color: #fff;
    border: 1px solid #000;
    padding: 13px 40px;
    font-size: 13px;
    letter-spacing: 0.06em;
    cursor: pointer;
    text-decoration: none;
    font-family: inherit;
    transition: background 0.22s ease, color 0.22s ease;
    line-height: 1;
}
.lmp-btn:hover {
    background: #fff;
    color: #000;
}

/* -- HTML mode -- */
.lmp-html-content {
    direction: rtl;
    text-align: right;
}

/* -- Body lock -- */
body.lmp-locked {
    overflow: hidden;
}

/* -- Responsive -- */
@media (max-width: 600px) {
    .lmp-popup {
        padding: 44px 24px 36px;
    }
    .lmp-title {
        font-size: 17px;
    }
    .lmp-message {
        font-size: 14px;
    }
}
