/*-----------------------------------------
* Newsletter signup (Klaviyo)
* Form (footer + popup variants), promo popup and top bar.
-------------------------------------------*/

/*-----------------------------------------
* Top announcement bar
-------------------------------------------*/
.sf-nl-bar {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #EDDAC1;
    color: #252525;
    padding: 10px 48px;
    text-align: center;
}

.sf-nl-bar[hidden] {
    display: none;
}

.sf-nl-bar__link {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    justify-content: center;
    color: #252525;
    text-decoration: none;
    border: none;
    background: transparent;
    padding: 0;
    margin: 0;
    font: inherit;
    cursor: pointer;
}

.sf-nl-bar__text {
    font-family: "Inter", sans-serif;
    font-size: 14px;
    font-weight: 500;
    line-height: 130%;
}

.sf-nl-bar__cta {
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    text-decoration: underline;
    text-underline-offset: 3px;
    white-space: nowrap;
}

.sf-nl-bar__link:hover .sf-nl-bar__cta {
    color: #714F30;
}

.sf-nl-bar__close {
    position: absolute;
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    font-size: 22px;
    line-height: 1;
    color: #714F30;
    cursor: pointer;
    opacity: 0.7;
}

.sf-nl-bar__close:hover {
    opacity: 1;
}

@media (max-width: 600px) {
    .sf-nl-bar {
        padding: 8px 40px;
    }

    .sf-nl-bar__text {
        font-size: 13px;
    }

    .sf-nl-bar__link {
        gap: 8px;
    }
}

.sf-newsletter {
    max-width: 520px;
    scroll-margin-top: 120px;
}

/* Mobile: form spans the full footer width, field and button stacked. */
@media (max-width: 767px) {
    .sf-newsletter--footer {
        max-width: 100%;
    }

    .sf-newsletter--footer .sf-newsletter__row {
        flex-direction: column;
    }

    .sf-newsletter--footer .sf-newsletter__input,
    .sf-newsletter--footer .sf-newsletter__submit {
        width: 100%;
    }
}

.sf-newsletter__title {
    font-size: 20px;
    line-height: 130%;
    margin: 0 0 8px;
}

.sf-newsletter__text {
    font-size: 14px;
    line-height: 150%;
    margin: 0 0 20px;
}

.sf-newsletter__row {
    display: flex;
    gap: 12px;
    align-items: stretch;
}

.sf-newsletter__input {
    flex: 1 1 auto;
    min-width: 0;
    font-family: "Raleway", sans-serif;
    font-size: 16px;
    font-weight: 500;
    letter-spacing: 0.02em;
    padding: 12px 16px;
    border: 1px solid #878686;
    border-radius: 4px;
    background-color: transparent;
}

.sf-newsletter__input:focus {
    outline: none;
    border-color: #EDDAC1;
}

/* Light by default (sitewide button color), dark on hover/press.
   !important guards against Blocksy footer button palette overrides. */
.sf-newsletter .sf-newsletter__submit {
    flex: 0 0 auto;
    font-size: 14px;
    text-transform: uppercase;
    line-height: 120%;
    padding: 14px 28px;
    border: 1px solid #EDDAC1;
    border-radius: 4px;
    background-color: #EDDAC1 !important;
    color: #252525 !important;
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.sf-newsletter .sf-newsletter__submit:hover,
.sf-newsletter .sf-newsletter__submit:focus-visible,
.sf-newsletter .sf-newsletter__submit:active {
    background-color: #252525 !important;
    color: #EDDAC1 !important;
}

.sf-newsletter__submit[disabled] {
    opacity: 0.6;
    cursor: wait;
}

/* Honeypot - visually removed, still in the DOM for bots */
.sf-newsletter__hp {
    position: absolute !important;
    left: -9999px !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.sf-newsletter__consent,
.sf-newsletter__finePrint {
    font-family: "Inter", sans-serif;
    font-size: 12px;
    line-height: 150%;
    color: #878686;
    margin: 12px 0 0;
}

.sf-newsletter__consent a {
    color: inherit;
    text-decoration: underline;
}

.sf-newsletter__status {
    font-size: 14px;
    line-height: 150%;
    margin-top: 12px;
    display: none;
}

.sf-newsletter__status.is-success {
    display: block;
    color: #4F7F4F;
}

.sf-newsletter__status.is-error {
    display: block;
    color: #B3554D;
}

/* Brief highlight after anchor scroll from the promo CTA */
.sf-newsletter.is-highlighted .sf-newsletter__input {
    border-color: #EDDAC1;
    box-shadow: 0 0 0 3px rgba(237, 218, 193, 0.35);
    transition: box-shadow 0.4s ease;
}

/* Footer variant: dark background (#201c1c gradient) */
.sf-newsletter--footer .sf-newsletter__title {
    color: #EDDAC1;
}

.sf-newsletter--footer .sf-newsletter__text {
    color: #ffffff;
}

.sf-newsletter--footer .sf-newsletter__input,
.sf-newsletter--footer .sf-newsletter__input:focus,
.sf-newsletter--footer .sf-newsletter__input:active {
    color: #ffffff;
    -webkit-text-fill-color: #ffffff; /* Safari/Chrome keep text visible while typing */
    caret-color: #ffffff;
}

.sf-newsletter--footer .sf-newsletter__input::placeholder {
    color: #878686;
}

/* Chrome autofill: stop the dark fill text from turning invisible on dark bg */
.sf-newsletter--footer .sf-newsletter__input:-webkit-autofill,
.sf-newsletter--footer .sf-newsletter__input:-webkit-autofill:focus {
    -webkit-text-fill-color: #ffffff;
    caret-color: #ffffff;
    transition: background-color 9999s ease-out 0s; /* defer the white autofill bg */
}

.sf-newsletter--footer .sf-newsletter__status.is-success {
    color: #BFD8BF;
}

.sf-newsletter--footer .sf-newsletter__status.is-error {
    color: #E0A8A2;
}

/* Popup variant: light dialog - text stays dark on the light background */
.sf-newsletter--popup .sf-newsletter__input,
.sf-newsletter--popup .sf-newsletter__input:focus,
.sf-newsletter--popup .sf-newsletter__input:active {
    color: #252525;
    -webkit-text-fill-color: #252525;
    caret-color: #252525;
    background-color: #FAF7F4;
}

.sf-newsletter--popup .sf-newsletter__input:-webkit-autofill,
.sf-newsletter--popup .sf-newsletter__input:-webkit-autofill:focus {
    -webkit-text-fill-color: #252525;
    caret-color: #252525;
}

/* CTA link (top promo bar) */
.sf-nl-cta {
    text-decoration: underline;
    font-weight: 600;
    color: inherit;
}

/*-----------------------------------------
* Promo popup
-------------------------------------------*/
.sf-nl-popup {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.sf-nl-popup[hidden] {
    display: none;
}

.sf-nl-popup__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    opacity: 0;
    transition: opacity 0.4s ease-out;
}

.sf-nl-popup.is-open .sf-nl-popup__overlay {
    opacity: 1;
}

.sf-nl-popup__dialog {
    position: relative;
    display: flex;
    width: 100%;
    max-width: 920px;
    max-height: 90vh;
    overflow: hidden;
    background: #ffffff;
    border-radius: 4px;
    transform: translateY(16px);
    opacity: 0;
    transition: transform 0.4s ease-out, opacity 0.4s ease-out;
}

.sf-nl-popup.is-open .sf-nl-popup__dialog {
    transform: translateY(0);
    opacity: 1;
}

/* Split layout: image left, content right (reference design) */
.sf-nl-popup__media {
    flex: 0 0 45%;
    background-size: cover;
    background-position: center;
}

.sf-nl-popup__content {
    flex: 1 1 auto;
    padding: 56px 48px 32px;
    overflow-y: auto;
}

.sf-nl-popup__dismiss {
    display: block;
    margin: 20px auto 0;
    border: none;
    background: transparent;
    font-family: "Inter", sans-serif;
    font-size: 13px;
    color: #878686;
    text-decoration: underline;
    cursor: pointer;
}

.sf-nl-popup__dismiss:hover {
    color: #252525;
}

@media (max-width: 834px) {
    .sf-nl-popup__media {
        display: none;
    }

    .sf-nl-popup__content {
        padding: 48px 24px 24px;
    }
}

.sf-nl-popup__close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    font-size: 28px;
    line-height: 1;
    color: #878686;
    cursor: pointer;
}

.sf-nl-popup__close:hover {
    color: #252525;
}

.sf-nl-popup__badge {
    display: inline-block;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #714F30;
    background-color: #EDDAC1;
    border-radius: 4px;
    padding: 6px 12px;
    margin-bottom: 16px;
}

.sf-nl-popup__title {
    font-size: 26px;
    line-height: 130%;
    color: #252525;
    margin: 0 0 28px;
}

/* Breathing room between the title and the form (popup only) */
.sf-newsletter--popup {
    margin-top: 8px;
}

.sf-nl-popup__text {
    font-size: 15px;
    line-height: 150%;
    color: #555555;
    margin: 0 0 24px;
}
