/* assets/css/newsletter-widget.css
   Styling für das Newsletter-Widget (Popup + Inline).
   Hintergrund-/Akzent-/Textfarbe werden je Formular per Inline-Style
   überschrieben (Backend: Newsletter > Formulare) -- Headline-, Sub-Headline-
   und Einwilligungs-Farben sind bewusst fest in dieser Datei definiert (feste
   visuelle Hierarchie), unabhängig von der frei wählbaren Box-Hintergrundfarbe. */

.nlw-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, .5);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    animation: nlw-fade-in .25s ease;
}

.nlw-overlay.nlw-popup_corner {
    align-items: flex-end;
    justify-content: flex-end;
    background: transparent;
    pointer-events: none;
}
.nlw-overlay.nlw-popup_corner .nlw-box {
    pointer-events: auto;
    margin: 0 1rem 1rem 0;
    box-shadow: 0 10px 30px rgba(0,0,0,.18);
}

.nlw-box {
    position: relative;
    max-width: 440px;
    width: 100%;
    border-radius: 12px;
    /* ca. +20% ggue. vorheriger Fassung, damit der Inhalt "atmen" kann */
    padding: 2.2rem 2rem 2rem;
    box-shadow: 0 20px 50px rgba(0,0,0,.25);
}

.nlw-inline-box .nlw-box {
    box-shadow: none;
    border: 1px solid #e2e8f0;
    max-width: 100%;
}
/* Inline-Platzierung hat keinen Close-Button -- reservierten Platz dafuer
   wieder freigeben. */
.nlw-inline-box .nlw-headline { margin-right: 0; }

/* Visueller Anker: dezentes Icon-Badge oben mittig */
.nlw-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    margin: 0 auto .9rem;
    border-radius: 50%;
    background: rgba(0,0,0,.05);
    font-size: 1.6rem;
    line-height: 1;
}

/* Bild-Icon statt Emoji: kein rundes Badge, eigene (freiere) Groesse,
   damit z.B. ein Logo im Originalseitenverhaeltnis dargestellt wird. */
.nlw-icon--image {
    width: auto;
    height: auto;
    max-width: 160px;
    background: none;
    border-radius: 0;
}
.nlw-icon--image img {
    display: block;
    width: auto;
    height: 70px;
    max-width: 100%;
    margin: 0 auto 20px;
    object-fit: contain;
}

.nlw-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    border-radius: 50%;
    font-size: 1.3rem;
    line-height: 1;
    cursor: pointer;
    color: #4b5563;
    transition: background-color .15s ease, color .15s ease;
}
.nlw-close:hover {
    color: #1f2937;
    background-color: rgba(0,0,0,.07);
}
.nlw-close:focus-visible {
    outline: 2px solid #4b5563;
    outline-offset: 2px;
}

.nlw-headline {
    font-size: 1.5rem;
    font-weight: 800;
    color: #1a1a1a;
    /* Rechter Rand reserviert Platz fuer den Close-Button (32px + Abstand),
       damit die Ueberschrift ihn nie ueberlappt -- auch bei zweizeiligem Text. */
    margin: 0 2.4rem .6rem 0;
    line-height: 1.3;
    overflow-wrap: break-word;
    text-align: center;
}

.nlw-body {
    font-size: 1rem;
    color: #666666;
    margin: 0 0 1rem;
    line-height: 1.5;
    text-align: center;
}

.nlw-social-proof {
    font-size: .85rem;
    font-weight: 700;
    color: #1a1a1a;
    text-align: center;
    margin: 0 0 .9rem;
}

.nlw-form { display: flex; flex-direction: column; gap: .8rem; }

.nlw-email {
    height: 48px;
    padding: 0 .9rem;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: .95rem;
    box-sizing: border-box;
    transition: border-color .15s ease, box-shadow .15s ease;
}
.nlw-email::placeholder { color: #94a3b8; }
.nlw-email:focus {
    outline: none;
    border-color: var(--nlw-focus-color, #0f4c8a);
    box-shadow: 0 0 0 3px rgba(15, 76, 138, .15);
}

.nlw-honeypot {
    position: absolute !important;
    left: -9999px !important;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.nlw-consent {
    display: flex;
    align-items: flex-start;
    gap: .55rem;
    font-size: 11px;
    line-height: 1.5;
    color: #888888;
}
.nlw-consent input {
    margin-top: .15rem;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}
.nlw-consent a {
    color: inherit;
    text-decoration: underline;
}
.nlw-consent input:focus-visible {
    outline: 2px solid #4b5563;
    outline-offset: 2px;
}

.nlw-submit {
    width: 100%;
    min-height: 50px;
    border: none;
    color: #fff;
    padding: .7rem 1rem;
    border-radius: 8px;
    font-weight: 700;
    font-size: .98rem;
    cursor: pointer;
    transition: filter .15s ease, box-shadow .15s ease;
}
.nlw-submit:hover {
    filter: brightness(.93);
    box-shadow: 0 4px 14px rgba(0,0,0,.18);
}
.nlw-submit:focus-visible {
    outline: 2px solid #1a1a1a;
    outline-offset: 2px;
}

.nlw-microcopy {
    font-size: 10px;
    color: #999999;
    text-align: center;
    margin: .6rem 0 0;
}

.nlw-feedback {
    font-size: .85rem;
    min-height: 1.2em;
    text-align: center;
}

.nlw-inline-slot:empty { display: none; }

@keyframes nlw-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Responsiveness: Mobile ~90% Breite, zentriert, bei Bedarf scrollbar */
@media (max-width: 480px) {
    .nlw-box {
        width: 90%;
        max-width: 90%;
        max-height: 85vh;
        overflow-y: auto;
        padding: 1.9rem 1.5rem 1.6rem;
    }
    .nlw-headline { font-size: 1.3rem; }
}
