/**
 * Site footer — compact, theme-aware (minimal vertical footprint)
 */

.site-footer {
    background: var(--current-bg-secondary, var(--current-card-bg, #12151f));
    border-top: 1px solid var(--current-border, rgba(255, 255, 255, 0.08));
    margin-top: 1.5rem;
    padding: 0.9rem 0;
    width: 100%;
    box-sizing: border-box;
    flex-shrink: 0;
}

.site-footer .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    box-sizing: border-box;
}

.site-footer-inner {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.site-footer-main {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.65rem 1rem;
}

.site-footer-lead {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    min-width: 0;
    flex: 0 1 auto;
}

.site-footer-kicker {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--current-text-secondary, rgba(148, 163, 184, 0.9));
    margin: 0;
    line-height: 1.2;
}

.site-footer-blurb {
    font-size: 0.8rem;
    color: var(--current-text-secondary, rgba(148, 163, 184, 0.85));
    margin: 0;
    line-height: 1.35;
    max-width: 16rem;
}

.footer-newsletter-form {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
    flex: 1 1 auto;
    justify-content: center;
    min-width: min(100%, 16rem);
}

.footer-newsletter-form input[type="email"] {
    flex: 1 1 10rem;
    min-width: 0;
    max-width: 250px;
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--current-border, rgba(255, 255, 255, 0.12));
    border-radius: 8px;
    font-size: 0.84rem;
    background: var(--current-bg, rgba(15, 23, 42, 0.5));
    color: var(--current-text, #f1f5f9);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    box-sizing: border-box;
    height: 2.2rem;
}

.footer-newsletter-form input[type="email"]::placeholder {
    color: var(--current-text-secondary, rgba(148, 163, 184, 0.7));
    opacity: 1;
}

.footer-newsletter-form input[type="email"]:focus {
    outline: none;
    border-color: rgba(99, 102, 241, 0.65);
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.2);
}

.footer-newsletter-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.5rem 1rem;
    height: 2.2rem;
    box-sizing: border-box;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #fff;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.28);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    white-space: nowrap;
}

.footer-newsletter-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
}

.footer-newsletter-btn:focus-visible {
    outline: 2px solid #a5b4fc;
    outline-offset: 2px;
}

.footer-newsletter-btn i {
    font-size: 0.7rem;
    opacity: 0.95;
}

.site-footer-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.45rem 0.85rem;
    font-size: 0.76rem;
    color: var(--current-text-secondary, rgba(148, 163, 184, 0.85));
    flex: 0 1 auto;
}

.footer-copyright {
    margin: 0;
    white-space: nowrap;
}

.footer-legal {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.footer-legal li {
    display: inline-flex;
    align-items: center;
}

.footer-legal li:not(:last-child)::after {
    content: '·';
    margin-left: 0.35rem;
    color: var(--current-text-secondary, rgba(148, 163, 184, 0.45));
    font-weight: 700;
}

.footer-legal a {
    color: var(--current-primary, #818cf8);
    text-decoration: none;
    font-weight: 600;
}

.footer-legal a:hover {
    text-decoration: underline;
    color: var(--current-text, #e2e8f0);
}

.footer-newsletter-message {
    font-size: 0.76rem;
    min-height: 0;
    margin: 0;
    padding: 0 0.15rem;
    line-height: 1.35;
}

.footer-newsletter-message:empty {
    display: none;
}

.footer-newsletter-message.success {
    color: #34d399;
}

.footer-newsletter-message.error {
    color: #f87171;
}

@media (max-width: 768px) {
    .site-footer {
        padding: 0.7rem 0;
        margin-top: 0.85rem;
    }

    .site-footer-main {
        flex-direction: column;
        align-items: stretch;
        gap: 0.6rem;
    }

    .site-footer-lead {
        text-align: center;
        max-width: none;
    }

    .site-footer-blurb {
        max-width: none;
    }

    .footer-newsletter-form {
        justify-content: stretch;
        max-width: 100%;
    }

    .footer-newsletter-form input[type="email"] {
        max-width: none;
        flex: 1 1 100%;
    }

    .footer-newsletter-btn {
        width: 100%;
    }

    .site-footer-meta {
        justify-content: center;
        flex-direction: column;
        gap: 0.25rem;
    }

    .footer-copyright {
        white-space: normal;
        text-align: center;
    }
}
