/* =============================================================================
   NEEDIBI SERVE — PREMIUM UI LAYER
   Site-wide polish for all website files: refined cards, buttons, gradients,
   spacing, motion. Loaded after public-theme.css so it can elevate defaults
   without rewriting every page. Uses the splash-blue brand.
   ============================================================================= */

/* ─────────────────────────────────────────────────────────────────────────────
   DASHBOARD TOKEN COMPATIBILITY LAYER
   Several authenticated Needer pages (my-contracts, booked-deals, my-needs,
   need-tracking, request-need, manage-need, offers, categories …) reference a
   generic token set (--text0, --card, --border, --bg2, --text-primary, …) that
   was never defined anywhere, so those pages fell back to raw browser defaults
   (black text on transparent). Define the whole set here, mapped onto the real
   --ns-* brand palette, so every page renders with the premium look. Light +
   dark are both provided; the site currently ships light, dark auto-applies for
   users whose OS prefers it.
   ───────────────────────────────────────────────────────────────────────────── */
:root {
    /* Surfaces */
    --card: #ffffff;
    --bg-card: #ffffff;
    --bg: #f8fafc;
    --bg-main: #f8fafc;
    --bg2: #f1f5f9;

    /* Text */
    --text0: #0f172a;
    --text1: #334155;
    --text2: #64748b;
    --text-primary: #0f172a;
    --text-secondary: #64748b;

    /* Lines & accents */
    --border: #e2e8f0;
    --border-color: #e2e8f0;
    --icon-active: #2058e6;
    --link-color: #2058e6;
}



:root {
    --nsp-blue: #2058e6;
    --nsp-blue-2: #2f6bf6;
    --nsp-blue-dark: #1e46c8;
    --nsp-gold: #F5B042;
    --nsp-gold-dark: #e09a2c;
    --nsp-ink: #0f1c3f;
    --nsp-muted: #64748b;
    --nsp-ring: rgba(32, 88, 230, 0.14);
    --nsp-shadow-sm: 0 8px 24px -14px rgba(20, 40, 90, 0.35);
    --nsp-shadow-md: 0 18px 40px -22px rgba(20, 40, 90, 0.45);
    --nsp-shadow-lg: 0 30px 70px -30px rgba(32, 88, 230, 0.55);
    --nsp-radius: 20px;
    --nsp-radius-lg: 28px;
    --nsp-ease: cubic-bezier(.16, 1, .3, 1);
}

/* ---- Typography rhythm: keep headings tight & confident ------------------- */
.na-page-content h1 {
    letter-spacing: -0.03em;
}

.na-page-content h2 {
    letter-spacing: -0.02em;
}

/* ---- Section titles: short brand underline (shared across all pages) ------ */
.ns-sec-title {
    position: relative;
    padding-bottom: 16px;
}

.ns-sec-title::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 46px;
    height: 4px;
    border-radius: 999px;
    background: var(--nsp-blue);
}

.ns-sec-title-light::after {
    background: var(--nsp-gold);
}

/* left-aligned variant (page headers that aren't centered) */
.ns-sec-title-left::after {
    left: 0;
    transform: none;
}

/* ---- Fixed header -----------------------------------------------------------
   The header is now fully styled by its own CSS in headersite.php
   (.ns-hdr-row, .ns-nav-link, .ns-btn-solid/.ns-btn-ghost, .ns-mnav-*).
   Keep this layer free of header overrides so headersite.php stays the single
   source of truth for the header design. ------------------------------------- */

/* ---- Smooth in-page scrolling (motion-safe) -------------------------------- */
@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }
}

/* ---- Button ripple (spawned by needibi-motion.js) --------------------------- */
.nsp-btn,
.ns-btn,
.cta-button,
.landing-action-btn,
.needs-load-more-btn,
.btn-primary-need-landing,
.modal-btn {
    position: relative;
    overflow: hidden;
}

.na-ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.35);
    transform: scale(0);
    animation: naRippleGrow 0.6s ease-out forwards;
    pointer-events: none;
}

@keyframes naRippleGrow {
    to {
        transform: scale(1);
        opacity: 0;
    }
}

/* ---- CSS fallback for [data-float] when GSAP is unavailable ----------------- */
.na-float-css {
    animation: naFloatY 3s ease-in-out infinite;
}

@keyframes naFloatY {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-14px);
    }
}

@media (prefers-reduced-motion: reduce) {
    .na-float-css {
        animation: none;
    }

    .na-ripple {
        display: none;
    }
}

/* ---- Accessibility: visible focus ring on every interactive element ------- */
.na-page-content a:focus-visible,
.na-page-content button:focus-visible,
header.fixed-header a:focus-visible,
header.fixed-header button:focus-visible,
footer a:focus-visible,
footer button:focus-visible {
    outline: 3px solid rgba(32, 88, 230, 0.5);
    outline-offset: 2px;
    border-radius: 6px;
}

footer a:focus-visible {
    outline-color: rgba(245, 176, 66, 0.7);
}

/* ---- Premium primary buttons (progressive; won't fight existing classes) -- */
.na-page-content .btn-primary,
.na-page-content .ns-btn-primary {
    box-shadow: 0 14px 30px -12px rgba(32, 88, 230, 0.55);
    transition: transform .25s var(--nsp-ease), box-shadow .25s var(--nsp-ease), background .25s ease;
}

.na-page-content .btn-primary:hover,
.na-page-content .ns-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 38px -12px rgba(32, 88, 230, 0.6);
}

/* ---- Generic card lift for common card classes across pages --------------- */
.na-page-content .card:not(.no-lift),
.na-page-content .ns-card:not(.no-lift),
.na-page-content .offer-card,
.na-page-content .need-card,
.na-page-content .category-card {
    transition: transform .3s var(--nsp-ease), box-shadow .3s var(--nsp-ease);
}

.na-page-content .card:not(.no-lift):hover,
.na-page-content .ns-card:not(.no-lift):hover,
.na-page-content .offer-card:hover,
.na-page-content .need-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--nsp-shadow-md);
}

/* ---- Section eyebrow pill (reusable) -------------------------------------- */
.nsp-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.42rem 1rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.nsp-pill-blue {
    background: var(--nsp-ring);
    color: var(--nsp-blue);
}

.nsp-pill-ghost {
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.25);
}

.nsp-pill i {
    font-size: 0.85em;
}

/* =============================================================================
   HOW IT WORKS — premium blue band with glass step cards (reference design)
   ============================================================================= */
.nsp-hiw {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, var(--nsp-blue-2) 0%, var(--nsp-blue) 55%, var(--nsp-blue-dark) 100%);
    color: #fff;
}

/* subtle dotted texture + corner glow */
.nsp-hiw::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.10) 1px, transparent 1px);
    background-size: 22px 22px;
    opacity: 0.5;
    pointer-events: none;
}

/* (corner glow circle removed — bands share one flat gradient look) */
.nsp-hiw>* {
    position: relative;
    z-index: 1;
}

.nsp-hiw-title {
    position: relative;
    font-size: clamp(1.875rem, 3.2vw, 2.25rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #fff;
    margin: 1rem 0 0.75rem;
    padding-bottom: 16px;
}

.nsp-hiw-title::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 46px;
    height: 4px;
    border-radius: 999px;
    background: #f5b042;
}

.nsp-hiw-sub {
    color: rgba(255, 255, 255, 0.85);
    max-width: 620px;
    margin: 0 auto;
    font-size: 1.05rem;
}

.nsp-hiw-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 1rem;
    margin-top: 3rem;
}

@media (max-width: 1200px) {
    .nsp-hiw-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 820px) {
    .nsp-hiw-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .nsp-hiw-grid {
        grid-template-columns: 1fr;
    }
}

.nsp-hiw-card {
    position: relative;
    background: rgba(255, 255, 255, 0.10);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: var(--nsp-radius);
    padding: 1.5rem 1.25rem;
    backdrop-filter: blur(6px);
    transition: transform .35s var(--nsp-ease), background .35s ease, border-color .35s ease;
}

.nsp-hiw-card:hover {
    transform: translateY(-6px);
    background: rgba(255, 255, 255, 0.16);
    border-color: rgba(255, 255, 255, 0.32);
}

.nsp-hiw-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nsp-hiw-ic {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.14);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: #fff;
}

.nsp-hiw-ic i {
    color: #fff !important;
}

.nsp-hiw-n {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--nsp-gold);
}

.nsp-hiw-card h4 {
    margin: 1.15rem 0 0.3rem;
    font-size: 1.1rem;
    font-weight: 800;
    color: #fff;
}

.nsp-hiw-card p {
    margin: 0;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.78);
}

/* =============================================================================
   APP DOWNLOAD — polished store buttons (used on landing + any page)
   ============================================================================= */
.nsp-store-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    background: #0b1220;
    color: #fff;
    border-radius: 14px;
    padding: 0.75rem 1.1rem;
    text-decoration: none;
    transition: transform .22s var(--nsp-ease), background .22s ease, box-shadow .22s ease;
    box-shadow: 0 12px 26px -16px rgba(0, 0, 0, 0.6);
}

.nsp-store-btn:hover {
    transform: translateY(-3px);
    background: #111a2e;
}

.nsp-store-btn i {
    font-size: 1.5rem;
    color: var(--nsp-gold);
}

.nsp-store-btn .nsp-store-txt small {
    display: block;
    font-size: 0.62rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.7);
}

.nsp-store-btn .nsp-store-txt b {
    display: block;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.15;
}

/* =============================================================================
   SITE-WIDE SCROLL REVEAL (paired with footer JS: .na-scroll-reveal)
   Slightly richer default so inner pages feel alive.
   ============================================================================= */
.na-scroll-reveal {
    will-change: opacity, transform;
}

/* directional reveal variants (optional, opt-in via data attribute) */
[data-reveal="left"] {
    transform: translateX(-28px);
}

[data-reveal="right"] {
    transform: translateX(28px);
}

[data-reveal="zoom"] {
    transform: scale(.96);
}

[data-reveal].na-shown {
    transform: none;
}

@media (prefers-reduced-motion: reduce) {

    .nsp-hiw-card,
    .nsp-store-btn,
    .na-page-content .card,
    .na-page-content .ns-card,
    .na-page-content .offer-card,
    .na-page-content .need-card {
        transition: none !important;
    }
}

/* =============================================================================
   PREMIUM COMPONENT LIBRARY (.nsp-*) — reusable across all website pages.
   Consistent radius, shadow, and focus. Corporate/trust SaaS tone.
   ============================================================================= */

/* ---- Buttons -------------------------------------------------------------- */
.nsp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 0.95rem;
    line-height: 1;
    padding: 0.8rem 1.4rem;
    border-radius: 12px;
    border: 1px solid transparent;
    cursor: pointer;
    text-decoration: none;
    white-space: nowrap;
    transition: transform .22s var(--nsp-ease), box-shadow .22s var(--nsp-ease),
        background .22s ease, color .22s ease, border-color .22s ease;
}

.nsp-btn:focus-visible {
    outline: 3px solid rgba(32, 88, 230, 0.45);
    outline-offset: 2px;
}

.nsp-btn i {
    font-size: 0.9em;
}

.nsp-btn-sm {
    padding: 0.55rem 1rem;
    font-size: 0.85rem;
    border-radius: 10px;
}

.nsp-btn-lg {
    padding: 1rem 1.7rem;
    font-size: 1.02rem;
    border-radius: 14px;
}

.nsp-btn-block {
    width: 100%;
}

.nsp-btn-primary {
    background: var(--nsp-blue);
    color: #fff;
    box-shadow: 0 14px 30px -12px rgba(32, 88, 230, 0.55);
}

.nsp-btn-primary:hover {
    background: var(--nsp-blue-dark);
    transform: translateY(-2px);
    box-shadow: 0 20px 38px -12px rgba(32, 88, 230, 0.6);
    color: #fff;
}

.nsp-btn-accent {
    background: var(--nsp-gold);
    color: #1a1a2e;
    box-shadow: 0 14px 30px -12px rgba(245, 176, 66, 0.5);
}

.nsp-btn-accent:hover {
    background: var(--nsp-gold-dark);
    transform: translateY(-2px);
    color: #1a1a2e;
}

.nsp-btn-outline {
    background: transparent;
    color: var(--nsp-blue);
    border-color: var(--nsp-blue);
}

.nsp-btn-outline:hover {
    background: var(--nsp-blue);
    color: #fff;
    transform: translateY(-2px);
}

.nsp-btn-white {
    background: #fff;
    color: var(--nsp-blue);
    border-color: rgba(255, 255, 255, 0.6);
    box-shadow: var(--nsp-shadow-sm);
}

.nsp-btn-white:hover {
    background: var(--nsp-blue);
    color: #fff;
    transform: translateY(-2px);
}

.nsp-btn-ghost {
    background: transparent;
    color: var(--nsp-ink);
    border-color: var(--nsp-ring);
}

.nsp-btn-ghost:hover {
    background: #eaf0ff;
    color: var(--nsp-blue);
}

/* ---- Inputs / forms ------------------------------------------------------- */
.nsp-field {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

.nsp-label {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--nsp-ink);
}

.nsp-input,
.nsp-select,
.nsp-textarea {
    width: 100%;
    font-size: 0.95rem;
    color: var(--nsp-ink);
    background: #fff;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    padding: 0.75rem 0.95rem;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

.nsp-input::placeholder,
.nsp-textarea::placeholder {
    color: #94a3b8;
}

.nsp-input:focus,
.nsp-select:focus,
.nsp-textarea:focus {
    outline: none;
    border-color: var(--nsp-blue);
    box-shadow: 0 0 0 4px rgba(32, 88, 230, 0.14);
    background: #fff;
}

.nsp-textarea {
    min-height: 120px;
    resize: vertical;
}

/* Bridge: legacy page-local form classes (request-need, deal-book, manage-bundle)
   inherit the same brand focus ring so every form on the site matches. */
.na-page-content .form-input:focus,
.na-page-content .form-select:focus,
.na-page-content .form-textarea:focus {
    border-color: var(--nsp-blue) !important;
    box-shadow: 0 0 0 4px rgba(32, 88, 230, 0.14) !important;
}

.nsp-help {
    font-size: 0.8rem;
    color: var(--nsp-muted);
}

.nsp-input-group {
    position: relative;
}

.nsp-input-group .nsp-input {
    padding-left: 2.6rem;
}

.nsp-input-group>i {
    position: absolute;
    left: 0.95rem;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    pointer-events: none;
}

/* ---- Cards ---------------------------------------------------------------- */
.nsp-card {
    background: #fff;
    border: 1px solid #eef2fb;
    border-radius: var(--nsp-radius);
    box-shadow: var(--nsp-shadow-sm);
    padding: 1.5rem;
    transition: transform .3s var(--nsp-ease), box-shadow .3s var(--nsp-ease), border-color .3s ease;
}

.nsp-card-hover:hover {
    transform: translateY(-6px);
    box-shadow: var(--nsp-shadow-md);
    border-color: rgba(32, 88, 230, 0.3);
}

.nsp-card-pad-lg {
    padding: 2rem;
}

.nsp-card-icon {
    width: 54px;
    height: 54px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eaf0ff;
    color: var(--nsp-blue);
    font-size: 1.35rem;
}

/* ---- Badges / chips ------------------------------------------------------- */
.nsp-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
}

.nsp-badge-blue {
    background: #eaf0ff;
    color: var(--nsp-blue);
}

.nsp-badge-gold {
    background: var(--nsp-gold-soft, #fef6e7);
    color: var(--nsp-gold-dark);
}

.nsp-badge-success {
    background: #dcfce7;
    color: #16a34a;
}

.nsp-badge-warning {
    background: #fef3c7;
    color: #d97706;
}

.nsp-badge-danger {
    background: #fee2e2;
    color: #dc2626;
}

.nsp-badge-neutral {
    background: #f1f5f9;
    color: #475569;
}

/* ---- Filter chips (clickable pills, e.g. category/status filters) --------- */
.nsp-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 1rem;
    border-radius: 999px;
    font-size: 0.85rem;
    font-weight: 600;
    background: #fff;
    color: var(--nsp-muted);
    border: 1px solid #e2e8f0;
    cursor: pointer;
    transition: transform .2s var(--nsp-ease), background .2s ease, border-color .2s ease, color .2s ease;
}

.nsp-chip:hover {
    border-color: var(--nsp-blue);
    color: var(--nsp-blue);
    transform: translateY(-2px);
}

.nsp-chip-active,
.nsp-chip-active:hover {
    background: var(--nsp-blue);
    border-color: var(--nsp-blue);
    color: #fff;
}

/* ---- White-outline button (for use on brand-blue backgrounds) ------------- */
.nsp-btn-outline-white {
    background: transparent;
    color: #fff;
    border-color: rgba(255, 255, 255, 0.7);
}

.nsp-btn-outline-white:hover {
    background: #fff;
    color: var(--nsp-blue);
    transform: translateY(-2px);
}

/* ---- Tables --------------------------------------------------------------- */
.nsp-table-wrap {
    width: 100%;
    overflow-x: auto;
    border-radius: var(--nsp-radius);
    border: 1px solid #eef2fb;
}

.nsp-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.92rem;
    background: #fff;
}

.nsp-table thead th {
    text-align: left;
    font-weight: 700;
    color: var(--nsp-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    font-size: 0.72rem;
    padding: 0.85rem 1rem;
    background: #f8fafc;
    border-bottom: 1px solid #eef2fb;
}

.nsp-table tbody td {
    padding: 0.9rem 1rem;
    border-bottom: 1px solid #f1f5f9;
    color: var(--nsp-ink);
}

.nsp-table tbody tr:last-child td {
    border-bottom: none;
}

.nsp-table tbody tr {
    transition: background .15s ease;
}

.nsp-table tbody tr:hover {
    background: #f8faff;
}

/* ---- Alerts --------------------------------------------------------------- */
.nsp-alert {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    padding: 0.9rem 1.1rem;
    border-radius: 14px;
    border: 1px solid transparent;
    font-size: 0.9rem;
}

.nsp-alert i {
    margin-top: 0.15rem;
}

.nsp-alert-info {
    background: #eaf0ff;
    border-color: #d3e0ff;
    color: #1c3ba0;
}

.nsp-alert-success {
    background: #dcfce7;
    border-color: #bbf7d0;
    color: #166534;
}

.nsp-alert-warning {
    background: #fef3c7;
    border-color: #fde68a;
    color: #92400e;
}

.nsp-alert-danger {
    background: #fee2e2;
    border-color: #fecaca;
    color: #991b1b;
}

/* ---- Section helpers ------------------------------------------------------ */
.nsp-section {
    padding: clamp(3rem, 7vw, 5rem) 0;
}

.nsp-container {
    max-width: 80rem;
    margin: 0 auto;
    padding: 0 1.25rem;
}

@media (min-width: 768px) {
    .nsp-container {
        padding: 0 2rem;
    }
}

.nsp-heading {
    font-size: clamp(1.9rem, 4vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--nsp-ink);
    line-height: 1.1;
}

.nsp-subheading {
    color: var(--nsp-muted);
    font-size: 1.05rem;
    line-height: 1.6;
    max-width: 40rem;
}

/* ---- Interactive step-viewer (how-it-works.php paginated step widget) ----
   JS toggles `.nsp-step-item.active` / `.nsp-step-dot.active` — these
   selectors express the dynamic state that static Tailwind utility
   classes can't cover. Layout/spacing/color otherwise lives in markup. */
.nsp-step-item.active {
    background: linear-gradient(135deg, rgba(32, 88, 230, 0.08), rgba(32, 88, 230, 0.03));
    border-left-color: var(--nsp-blue);
}

.nsp-step-item:hover:not(.active) {
    background: #f8fafc;
}

.nsp-step-item.active .nsp-step-number {
    background: linear-gradient(135deg, var(--nsp-blue), #1a46b8);
    border-color: var(--nsp-blue);
    color: #fff;
    transform: scale(1.05);
}

.nsp-step-dot.active {
    width: 1.5rem;
    background: var(--nsp-blue);
}

.nsp-step-detail {
    animation: nspStepSlideIn 0.3s ease forwards;
    opacity: 0;
}

@keyframes nspStepSlideIn {
    from {
        opacity: 0;
        transform: translateX(-10px);
    }

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

@media (min-width: 1024px) {
    .nsp-step-sticky {
        position: sticky;
        top: 100px;
        height: fit-content;
    }
}

/* ============================================================
   SOCIAL CARD ENGAGEMENT — Like, Serve The Need, Save, Share
   Shared by Need & Deal cards (landing.php, needs.php).
   ============================================================ */
.ns-eng-bar {
    display: flex;
    align-items: center;
    gap: .375rem;
    margin-top: .625rem;
    padding-top: .625rem;
    border-top: 1px solid #eef1f8;
}

.ns-eng-btn {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    border: 1px solid #e3e9f4;
    background: #f8faff;
    color: #56607a;
    font-size: .78rem;
    font-weight: 600;
    line-height: 1;
    padding: .5rem .7rem;
    border-radius: 999px;
    cursor: pointer;
    transition: transform .18s cubic-bezier(.34,1.56,.64,1), background-color .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.ns-eng-btn:hover {
    background: #eef3ff;
    border-color: #cddaf9;
    color: #2058e6;
    transform: translateY(-1px);
}

.ns-eng-btn:active {
    transform: translateY(0) scale(.96);
}

.ns-eng-btn.ns-eng-icon {
    padding: .5rem .6rem;
}

.ns-eng-btn i {
    font-size: .85rem;
    transition: transform .22s ease;
}

.ns-eng-like.is-active {
    background: #fff0f2;
    border-color: #ffd1d8;
    color: #e11d48;
}

.ns-eng-like.is-active i {
    color: #e11d48;
}

.ns-eng-save.is-active {
    background: #eef3ff;
    border-color: #b9caf7;
    color: #2058e6;
}

.ns-eng-save.is-active i {
    color: #2058e6;
}

.ns-eng-serve {
    background: linear-gradient(135deg, #2f6bf6, #2058e6);
    border-color: transparent;
    color: #fff;
}

.ns-eng-trailing-cta {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .5rem 1rem;
    border-radius: 999px;
    background: linear-gradient(135deg, #2f6bf6, #2058e6);
    color: #fff !important;
    font-size: .78rem;
    font-weight: 700;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: box-shadow .18s ease, transform .18s ease;
    white-space: nowrap;
}

.ns-eng-trailing-cta:hover {
    box-shadow: 0 6px 16px rgba(32, 88, 230, .3);
    transform: translateY(-1px);
    color: #fff;
}

.ns-eng-serve:hover {
    background: linear-gradient(135deg, #3a74f8, #1e46c8);
    color: #fff;
    box-shadow: 0 6px 16px rgba(32, 88, 230, .28);
}

.ns-eng-count {
    font-variant-numeric: tabular-nums;
}

@keyframes nsEngPulse {
    0% { transform: scale(1); }
    35% { transform: scale(1.35); }
    60% { transform: scale(.92); }
    100% { transform: scale(1); }
}

.ns-eng-pulse i {
    animation: nsEngPulse .45s cubic-bezier(.34,1.56,.64,1);
}

.ns-eng-comments {
    margin-top: .5rem;
    padding-top: .625rem;
    border-top: 1px dashed #e3e9f4;
}

.ns-eng-comments[hidden] {
    display: none;
}

.ns-eng-comments-list {
    max-height: 180px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: .4rem;
    margin-bottom: .5rem;
}

.ns-eng-comment-item {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: .35rem;
    background: #f8faff;
    border: 1px solid #eef1f8;
    border-radius: 10px;
    padding: .45rem .6rem;
    font-size: .8rem;
    line-height: 1.35;
}

.ns-eng-comment-author {
    font-weight: 700;
    color: #1c2534;
}

.ns-eng-comment-text {
    color: #414c63;
    flex: 1 1 auto;
    word-break: break-word;
}

.ns-eng-comment-time {
    color: #9aa4bb;
    font-size: .7rem;
    white-space: nowrap;
}

.ns-eng-comments-loading,
.ns-eng-comments-empty {
    color: #9aa4bb;
    font-size: .8rem;
    padding: .4rem 0;
}

.ns-eng-comment-form {
    display: flex;
    gap: .4rem;
}

.ns-eng-comment-form input {
    flex: 1 1 auto;
    border: 1px solid #e3e9f4;
    border-radius: 999px;
    padding: .5rem .85rem;
    font-size: .8rem;
    outline: none;
    transition: border-color .18s ease, box-shadow .18s ease;
}

.ns-eng-comment-form input:focus {
    border-color: #2058e6;
    box-shadow: 0 0 0 3px rgba(32, 88, 230, .12);
}

.ns-eng-comment-form button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 50%;
    background: linear-gradient(135deg, #2f6bf6, #2058e6);
    color: #fff;
    cursor: pointer;
    flex: 0 0 auto;
}

.ns-eng-comment-form button:disabled {
    opacity: .6;
    cursor: default;
}

/* Card meta chips — verification badge, status, view/inquiry counts */
.ns-card-chip {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    font-size: .72rem;
    font-weight: 600;
    color: #6b7690;
}

.ns-card-chip i {
    font-size: .72rem;
}

.ns-verified-chip {
    color: #2058e6;
}

.ns-verified-chip i {
    color: #2058e6;
}

.ns-trust-badge-chip {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    font-size: .68rem;
    font-weight: 700;
    padding: .2rem .55rem;
    border-radius: 999px;
    background: rgba(32, 88, 230, .08);
    white-space: nowrap;
}

/* ============================================================
   SOCIAL CARD — shared header/poster/media-gallery/stats-grid
   layout used by Need & Deal cards (needs.php, offers.php,
   landing.php). Keeps the outer .need-card/.deal-card wrapper
   and existing engagement-bar wiring; only restyles the inside.
   ============================================================ */
.sc-badges-row {
    display: flex;
    align-items: center;
    gap: .5rem;
    margin-bottom: .85rem;
}

.sc-role-badge {
    display: inline-flex;
    align-items: center;
    padding: .25rem .65rem;
    border-radius: .5rem;
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .04em;
    color: #fff;
}

.sc-role-badge.sc-role-need {
    background: #2058e6;
}

.sc-role-badge.sc-role-deal {
    background: #16a34a;
}

.sc-verified-badge {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    font-size: .72rem;
    font-weight: 700;
    color: #16a34a;
}

.sc-verified-badge i {
    color: #16a34a;
}

.sc-menu-wrap {
    margin-left: auto;
    position: relative;
}

.sc-menu-btn {
    background: transparent;
    border: none;
    color: #9aa4bb;
    cursor: pointer;
    padding: .25rem .4rem;
    border-radius: .4rem;
    font-size: .9rem;
    line-height: 1;
}

.sc-menu-btn:hover,
.sc-menu-btn[aria-expanded="true"] {
    background: #f1f4fb;
    color: #4b5568;
}

.sc-menu-dropdown {
    display: none;
    flex-direction: column;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 200px;
    background: #fff;
    border: 1px solid #e5e9f2;
    border-radius: .65rem;
    box-shadow: 0 12px 28px -8px rgba(15, 23, 42, .18);
    padding: .35rem;
    z-index: 20;
}

.sc-menu-dropdown:not([hidden]) {
    display: flex;
}

.sc-menu-stats {
    padding: .3rem .6rem .1rem;
    display: flex;
    flex-direction: column;
    gap: .32rem;
}

.sc-menu-stat {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .6rem;
    font-size: .76rem;
}

.sc-menu-stat span {
    color: #9aa4bb;
    font-weight: 600;
}

.sc-menu-stat strong {
    color: #374151;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 110px;
}

.sc-menu-divider {
    height: 1px;
    background: #eef1f8;
    margin: .4rem 0;
}

.sc-menu-item {
    display: flex;
    align-items: center;
    gap: .55rem;
    width: 100%;
    background: transparent;
    border: none;
    text-align: left;
    padding: .5rem .6rem;
    border-radius: .45rem;
    font-size: .82rem;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
}

.sc-menu-item:hover {
    background: #f1f4fb;
    color: #2058e6;
}

.sc-menu-item i {
    width: 14px;
    text-align: center;
    color: #6b7280;
}

.sc-menu-item:hover i {
    color: #2058e6;
}

.sc-poster-row {
    display: flex;
    align-items: flex-start;
    gap: .65rem;
    margin-bottom: .6rem;
}

.sc-avatar {
    flex: 0 0 auto;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-size: .85rem;
    overflow: hidden;
}

.sc-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sc-avatar-anon {
    background: #9aa4bb !important;
}

.sc-poster-info {
    flex: 1 1 auto;
    min-width: 0;
}

.sc-poster-name {
    font-size: .88rem;
    font-weight: 700;
    color: #1c2534;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sc-poster-sub {
    font-size: .74rem;
    color: #8892a6;
}

.sc-poster-category {
    color: #2058e6;
    font-weight: 600;
}

.sc-poster-time {
    flex: 0 0 auto;
    font-size: .72rem;
    color: #9aa4bb;
    white-space: nowrap;
}

.sc-location-row {
    display: flex;
    align-items: center;
    gap: .35rem;
    font-size: .76rem;
    color: #6b7690;
    margin-bottom: .6rem;
}

.sc-media-carousel {
    position: relative;
    border-radius: .65rem;
    overflow: hidden;
    height: 150px;
    background: #eef2ff;
    margin: .75rem 0;
}

.sc-media-carousel.sc-media-carousel-hero {
    height: 190px;
}

.sc-media-track {
    display: flex;
    height: 100%;
    transition: transform .35s cubic-bezier(0.22, 1, 0.36, 1);
}

.sc-media-slide {
    position: relative;
    flex: 0 0 100%;
    height: 100%;
}

.sc-media-slide img,
.sc-media-slide video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.sc-media-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(15, 23, 42, .55);
    color: #fff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: .75rem;
    z-index: 2;
}

.sc-media-arrow:hover { background: rgba(15, 23, 42, .78); }
.sc-media-arrow-prev { left: 8px; }
.sc-media-arrow-next { right: 8px; }

.sc-media-dots {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 5px;
    z-index: 2;
}

.sc-media-dot {
    width: 6px;
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, .55);
    transition: width .2s ease, background .2s ease;
}

.sc-media-dot.is-active {
    width: 16px;
    background: #fff;
}

.sc-media-slide[data-media-video-slide],
.sc-media-slide[data-media-image-slide] {
    cursor: pointer;
}

.sc-media-play-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: opacity .18s ease;
}

.sc-media-slide.is-playing .sc-media-play-overlay {
    opacity: 0;
    pointer-events: none;
}

.sc-media-play-overlay i {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .92);
    color: #2058e6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    transition: transform .18s ease;
}

.sc-media-slide[data-media-video-slide]:hover .sc-media-play-overlay i {
    transform: scale(1.08);
}

/* Full-size image lightbox (media-gallery / modal image click) */
.ns-lightbox-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10, 14, 26, .88);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 2rem;
}

.ns-lightbox-overlay.is-open {
    display: flex;
}

.ns-lightbox-img {
    max-width: 100%;
    max-height: 100%;
    border-radius: .5rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, .45);
    object-fit: contain;
}

.ns-lightbox-close {
    position: fixed;
    top: 18px;
    right: 22px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: rgba(255, 255, 255, .12);
    color: #fff;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    transition: background-color .16s ease;
}

.ns-lightbox-close:hover {
    background: rgba(255, 255, 255, .22);
}

.sc-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: .5rem;
    margin: .85rem 0;
}

.sc-stat {
    background: #f6f8fd;
    border-radius: .65rem;
    padding: .5rem .6rem;
    display: flex;
    flex-direction: column;
    gap: .15rem;
    min-width: 0;
}

.sc-stat-label {
    font-size: .65rem;
    font-weight: 700;
    color: #9aa4bb;
    text-transform: uppercase;
    letter-spacing: .03em;
    display: flex;
    align-items: center;
    gap: .3rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sc-stat-value {
    font-size: .82rem;
    font-weight: 700;
    color: #1c2534;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sc-stat-value.sc-v-green { color: #16a34a; }
.sc-stat-value.sc-v-orange { color: #d97706; }
.sc-stat-value.sc-v-blue { color: #2058e6; }
.sc-stat-value.sc-v-amber { color: #d97706; }

@media (max-width: 420px) {
    .sc-stats-grid { grid-template-columns: repeat(2, 1fr); }
    .sc-media-carousel { height: 130px; }
    .sc-media-carousel.sc-media-carousel-hero { height: 160px; }
}

/* Inline "please log in" notice — shown directly under the card's action bar,
   no popup / no scrolling to find it. */
.ns-eng-inline-error {
    display: none;
    align-items: center;
    gap: .4rem;
    margin: .5rem .25rem 0;
    padding: .55rem .8rem;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 10px;
    color: #dc2626;
    font-size: .78rem;
    font-weight: 600;
    line-height: 1.35;
}

.ns-eng-inline-error.is-visible {
    display: flex;
    flex-wrap: wrap;
}

.ns-eng-inline-error a {
    color: #dc2626;
    text-decoration: underline;
    font-weight: 800;
}

/* Serve The Need — quick-message modal */
.ns-eng-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, .55);
    backdrop-filter: blur(2px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease;
    padding: 1rem;
}

.ns-eng-modal-overlay.is-open {
    opacity: 1;
    pointer-events: auto;
}

.ns-eng-modal {
    background: #fff;
    border-radius: 18px;
    padding: 1.5rem;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, .3);
    position: relative;
    transform: translateY(14px) scale(.98);
    transition: transform .22s cubic-bezier(.34,1.56,.64,1);
}

.ns-eng-modal-overlay.is-open .ns-eng-modal {
    transform: translateY(0) scale(1);
}

.ns-eng-modal h3 {
    font-size: 1.05rem;
    font-weight: 800;
    color: #14213d;
    margin: 0 0 .35rem;
    display: flex;
    align-items: center;
    gap: .5rem;
}

.ns-eng-modal h3 i {
    color: #2058e6;
}

.ns-eng-modal-sub {
    font-size: .82rem;
    color: #6b7690;
    margin: 0 0 1rem;
}

.ns-eng-modal textarea,
.ns-eng-modal input {
    width: 100%;
    border: 1px solid #e3e9f4;
    border-radius: 12px;
    padding: .65rem .8rem;
    font-size: .85rem;
    margin-bottom: .65rem;
    font-family: inherit;
    resize: vertical;
}

.ns-eng-modal textarea:focus,
.ns-eng-modal input:focus {
    outline: none;
    border-color: #2058e6;
    box-shadow: 0 0 0 3px rgba(32, 88, 230, .14);
}

.ns-eng-modal-submit {
    width: 100%;
    border: none;
    border-radius: 12px;
    padding: .75rem 1rem;
    background: linear-gradient(135deg, #2f6bf6, #2058e6);
    color: #fff;
    font-weight: 700;
    font-size: .88rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    transition: transform .16s ease, box-shadow .16s ease;
}

.ns-eng-modal-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 24px rgba(32, 88, 230, .3);
}

.ns-eng-modal-submit:disabled {
    opacity: .6;
    cursor: not-allowed;
    transform: none;
}

.ns-eng-modal-close {
    position: absolute;
    top: .75rem;
    right: .85rem;
    border: none;
    background: #f1f4fa;
    color: #56607a;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    font-size: 1.1rem;
    line-height: 1;
    cursor: pointer;
    transition: background-color .16s ease;
}

.ns-eng-modal-close:hover {
    background: #e3e9f4;
}

/* Share preview modal — thumbnail + title + link before committing to a channel */
.ns-share-preview-card {
    display: flex;
    gap: .85rem;
    align-items: center;
    background: #f8faff;
    border: 1px solid #eef1f8;
    border-radius: .9rem;
    padding: .75rem;
    margin: .25rem 0 1.1rem;
}

.ns-share-preview-img {
    flex: 0 0 auto;
    width: 64px;
    height: 64px;
    border-radius: .65rem;
    overflow: hidden;
    background: #eef2ff;
}

.ns-share-preview-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ns-share-preview-img-fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #b9c4de;
    font-size: 1.4rem;
}

.ns-share-preview-body {
    min-width: 0;
    flex: 1 1 auto;
}

.ns-share-preview-title {
    font-weight: 700;
    font-size: .92rem;
    color: #1c2534;
    line-height: 1.35;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.ns-share-preview-url {
    margin-top: .25rem;
    font-size: .74rem;
    color: #8b95ab;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ns-share-preview-location {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    margin-top: .45rem;
    font-size: .78rem;
    font-weight: 600;
    color: #2058e6;
    text-decoration: none;
}

.ns-share-preview-location:hover {
    text-decoration: underline;
}

.ns-share-actions {
    display: flex;
    flex-direction: column;
    gap: .55rem;
}

.ns-share-action-btn {
    display: flex;
    align-items: center;
    gap: .6rem;
    width: 100%;
    padding: .75rem 1rem;
    border-radius: .75rem;
    border: 1px solid #e3e9f4;
    background: #fff;
    color: #2b3448;
    font-weight: 700;
    font-size: .85rem;
    cursor: pointer;
    text-decoration: none;
    transition: border-color .16s ease, background-color .16s ease, transform .16s ease;
}

.ns-share-action-btn:hover {
    border-color: #cddaf9;
    background: #f8faff;
    transform: translateY(-1px);
    color: #2058e6;
}

.ns-share-action-primary {
    background: linear-gradient(135deg, #2f6bf6, #2058e6);
    border-color: transparent;
    color: #fff !important;
}

.ns-share-action-primary:hover {
    color: #fff !important;
    box-shadow: 0 8px 20px rgba(32, 88, 230, .28);
}

.ns-share-action-btn i {
    width: 18px;
    text-align: center;
}

.ns-share-action-btn[data-share-whatsapp] i {
    color: #25d366;
}

/* Lightweight toast for engagement feedback */
.ns-eng-toast {
    position: fixed;
    left: 50%;
    bottom: 28px;
    transform: translateX(-50%) translateY(12px);
    background: #14213d;
    color: #fff;
    font-size: .85rem;
    font-weight: 600;
    padding: .7rem 1.1rem;
    border-radius: 999px;
    box-shadow: 0 14px 30px rgba(15, 23, 42, .35);
    z-index: 10000;
    opacity: 0;
    transition: opacity .25s ease, transform .25s ease;
    pointer-events: none;
}

.ns-eng-toast.is-visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* On small screens, anchor the toast just below the fixed site header instead
   of the viewport bottom — bottom placement gets hidden behind mobile browser
   toolbars / thumb area and is easy to miss. */
@media (max-width: 640px) {
    .ns-eng-toast {
        top: 78px;
        bottom: auto;
        left: 16px;
        right: 16px;
        width: auto;
        max-width: none;
        text-align: center;
        transform: translateY(-12px);
    }

    .ns-eng-toast.is-visible {
        transform: translateY(0);
    }
}

@media (prefers-color-scheme: dark) {
    .ns-eng-bar {
        border-top-color: rgba(255, 255, 255, .08);
    }

    .ns-eng-btn {
        background: rgba(255, 255, 255, .04);
        border-color: rgba(255, 255, 255, .1);
        color: #b7c0d8;
    }

    .ns-eng-btn:hover {
        background: rgba(47, 107, 246, .16);
        border-color: rgba(47, 107, 246, .4);
        color: #8fb0ff;
    }

    .ns-eng-modal {
        background: #111a30;
    }

    .ns-eng-modal h3 {
        color: #f4f6fb;
    }

    .ns-eng-modal textarea,
    .ns-eng-modal input {
        background: rgba(255, 255, 255, .04);
        border-color: rgba(255, 255, 255, .12);
        color: #e7ebf5;
    }
}

@media (prefers-reduced-motion: reduce) {
    .ns-eng-pulse i {
        animation: none;
    }

    .ns-eng-btn,
    .ns-eng-modal,
    .ns-eng-toast {
        transition: none;
    }
}
