/* ─── Email Capture Popup (shared across all pages) ──────────────────── */
.ebook-popup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(42, 24, 69, 0.72);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 16px;
    backdrop-filter: blur(4px);
}

.ebook-popup-overlay.active {
    display: flex;
}

.ebook-popup {
    background: var(--cream);
    border-radius: 20px;
    padding: 40px 36px;
    max-width: 480px;
    width: 100%;
    position: relative;
    box-shadow: 0 24px 60px rgba(42, 24, 69, 0.28);
    text-align: center;
}

.ebook-popup-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: var(--sage);
    color: white;
    font-size: 18px;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.ebook-popup-close:hover {
    background: var(--moss);
}

.ebook-popup-icon {
    width: 56px;
    height: 56px;
    background: var(--sage);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 4px;
    font-size: 28px;
}

.ebook-popup-tag {
    font-family: 'Outfit', sans-serif;
    font-size: 11px;
    font-weight: 600;
    color: var(--orange);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 20px;
}

.ebook-popup-title {
    font-family: 'Instrument Serif', serif;
    font-size: 26px;
    color: var(--bark);
    margin-top: 10px;
    line-height: 1.25;
}

.ebook-popup-desc {
    font-size: 15px;
    color: var(--sage-light);
    margin-top: 10px;
    line-height: 1.65;
}

.ebook-popup-form {
    margin-top: 28px;
}

.ebook-popup-email {
    width: 100%;
    padding: 14px 18px;
    border: 1px solid rgba(42, 24, 69, 0.15);
    border-radius: 10px;
    font-size: 15px;
    font-family: 'Outfit', sans-serif;
    background: white;
    color: var(--bark);
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

.ebook-popup-email::placeholder {
    color: rgba(42, 24, 69, 0.4);
}

.ebook-popup-email:focus {
    border-color: var(--sage);
    box-shadow: 0 0 0 3px rgba(74, 103, 65, 0.12);
}

.ebook-popup-btn {
    margin-top: 12px;
    width: 100%;
    padding: 16px;
    background: var(--orange);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    font-family: 'Outfit', sans-serif;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

.ebook-popup-btn:hover {
    background: var(--orange-light);
}

.ebook-popup-btn:active {
    transform: scale(0.98);
}

.ebook-popup-btn:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.ebook-popup-note {
    margin-top: 10px;
    font-size: 12px;
    color: var(--sage-light);
}

.ebook-popup-dismiss {
    margin-top: 18px;
    font-size: 13px;
    color: rgba(42, 24, 69, 0.5);
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
}

.ebook-popup-dismiss:hover {
    color: var(--bark);
    text-decoration: underline;
}

.ebook-popup-msg {
    margin-top: 10px;
    font-size: 13px;
    color: var(--orange);
    display: none;
}

.ebook-popup-msg.active {
    display: block;
}

@media (max-width: 480px) {
    .ebook-popup {
        padding: 32px 24px;
    }

    .ebook-popup-title {
        font-size: 22px;
    }

    .ebook-popup-desc {
        font-size: 14px;
    }
}
