/**
 * Footer newsletter subscription form -- functional layer only.
 *
 * All existing layout, typography, colours and spacing for
 * .email-subscription-form, .es-form-field-container, .gjs-row/.gjs-cell
 * and .es_subscription_message live in css/style.css and are completely
 * untouched by this file. This stylesheet only adds the two small rules
 * needed to make the (previously static) form usable:
 *
 * 1. Hide the honeypot field from real visitors (it was not needed
 *    before because the form did not submit anywhere).
 * 2. Colour the error state of the existing .es_subscription_message
 *    span -- only its success colour previously existed in style.css.
 */

.ibox-newsletter-honeypot {
	position: absolute;
	left: -9999px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.es_subscription_message.error {
	color: #C0392B !important;
}

.ibox-newsletter-submit[disabled] {
	opacity: 0.6;
	cursor: not-allowed;
}



/* iBOX Newsletter Popup */
.ibox-popup {
    display: none;
    position: fixed;
    z-index: 999999;
    right: 20px;
    top: 20px;
    width: min(420px, calc(100% - 32px));
    box-sizing: border-box;
    font-family: inherit;
}

.ibox-popup.is-visible {
    display: block;
    animation: iboxPopupAppear 0.3s ease-out;
}

.ibox-popup-card {
    position: relative;
    box-sizing: border-box;
    padding: 28px;
    background: #ffffff;
    color: #222222;
    border: 1px solid #eeeeee;
    border-radius: 12px;
    box-shadow: 0 8px 35px rgba(0, 0, 0, 0.18);
}

/* iBOX Logo */
.ibox-popup-brand {
    margin-bottom: 14px;
}

.ibox-popup-brand img {
    display: block;
    width: 115px;
    max-width: 100%;
    height: auto;
}

.ibox-popup-card h2 {
    margin: 0 25px 10px 0;
    font-size: 24px;
    line-height: 1.3;
}

.ibox-popup-card p {
    font-size: 15px;
    line-height: 1.6;
}

.ibox-popup-close {
    position: absolute;
    top: 8px;
    right: 12px;
    border: 0;
    background: transparent;
    color: #555555;
    font-size: 28px;
    cursor: pointer;
}

.ibox-popup-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.ibox-popup-actions button,
#ibox-popup-submit {
    min-height: 44px;
    padding: 11px 18px;
    border: 1px solid #FF9E1B;
    border-radius: 4px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

#ibox-popup-later {
    flex: 1;
    background: #ffffff;
    color: #333333;
    border-color: #FF9E1B;
}

#ibox-popup-subscribe,
#ibox-popup-submit {
    flex: 1;
    background: #FF9E1B;
    color: #ffffff;
    border-color: #FF9E1B;
}

/* Button hover colours */
#ibox-popup-later:hover {
    background: #FFF4E3;
}

#ibox-popup-subscribe:hover,
#ibox-popup-submit:hover {
    background: #F28C00;
    border-color: #F28C00;
}

#ibox-popup-email {
    display: block;
    box-sizing: border-box;
    width: 100%;
    min-height: 46px;
    margin: 10px 0;
    padding: 12px;
    border: 1px solid #cccccc;
    border-radius: 4px;
    font-size: 16px;
}

#ibox-popup-submit {
    width: 100%;
}

#ibox-popup-submit:disabled {
    opacity: 0.6;
    cursor: wait;
}

#ibox-popup-message.success {
    color: #176b36;
}

#ibox-popup-message.error {
    color: #b51e27;
}

@keyframes iboxPopupAppear {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 480px) {
    .ibox-popup {
        top: 12px;
        right: 12px;
        width: calc(100% - 24px);
    }

    .ibox-popup-card {
        padding: 22px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .ibox-popup.is-visible {
        animation: none;
    }
}