/* ==========================================================================
   Sainfoxiya B2B — Landing Page Styles & Animation Engine
   (assets/css/b2bLanding.css)
   Depends on main.css for :root design tokens.
   ========================================================================== */

:root {
    --b2b-navy: #0b1020;
    --b2b-surface: rgba(255, 255, 255, 0.7);
    --b2b-blur: saturate(180%) blur(14px);
}

/* --------------------------------------------------------------------------
   Motion-safety: respect reduced motion
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }
}

body {
    background: var(--bg-page);
    overflow-x: hidden;
}

/* ==========================================================================
   1. Top Navigation (glass, sticky)
   ========================================================================== */
.b2b-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    width: 100%;
    background: rgba(248, 250, 252, 0.72);
    backdrop-filter: var(--b2b-blur);
    -webkit-backdrop-filter: var(--b2b-blur);
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}

.b2b-nav.is-scrolled {
    border-bottom-color: var(--border-color);
    box-shadow: var(--shadow-sm);
}

.b2b-nav__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
    gap: 1rem;
}

.b2b-nav__logo img {
    height: 40px;
    width: auto;
    display: block;
}

.b2b-nav__links {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.b2b-nav__links a {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-secondary);
    position: relative;
}

.b2b-nav__links a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -6px;
    width: 0;
    height: 2px;
    border-radius: 2px;
    background: var(--gradient-primary);
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.b2b-nav__links a:hover {
    color: var(--text-primary);
}

.b2b-nav__links a:hover::after {
    width: 100%;
}

.b2b-nav__cta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.b2b-nav__toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    padding: 8px;
}

.b2b-nav__toggle span {
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: var(--transition);
}

/* ==========================================================================
   2. Hero
   ========================================================================== */
.b2b-hero {
    position: relative;
    padding: 5.5rem 0 4rem;
    overflow: hidden;
    background: var(--gradient-hero-bg);
}

/* Floating gradient orbs */
.b2b-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.55;
    z-index: 0;
    pointer-events: none;
    will-change: transform;
}

.b2b-orb--1 {
    width: 420px;
    height: 420px;
    top: -120px;
    left: -100px;
    background: radial-gradient(circle at 30% 30%, #6366f1, transparent 70%);
    animation: orbFloat1 18s ease-in-out infinite;
}

.b2b-orb--2 {
    width: 360px;
    height: 360px;
    top: 40px;
    right: -120px;
    background: radial-gradient(circle at 70% 30%, #ec4899, transparent 70%);
    animation: orbFloat2 22s ease-in-out infinite;
}

.b2b-orb--3 {
    width: 300px;
    height: 300px;
    bottom: -140px;
    left: 40%;
    background: radial-gradient(circle at 50% 50%, #0ea5e9, transparent 70%);
    animation: orbFloat3 26s ease-in-out infinite;
}

@keyframes orbFloat1 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(60px, 40px) scale(1.12); }
}
@keyframes orbFloat2 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(-50px, 60px) scale(1.08); }
}
@keyframes orbFloat3 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(40px, -50px) scale(1.15); }
}

.b2b-hero__grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    gap: 3rem;
    align-items: center;
}

.b2b-hero__badge {
    margin-bottom: 1.25rem;
}

.b2b-hero h1 {
    font-size: clamp(2.4rem, 5vw, 3.6rem);
    line-height: 1.08;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    margin-bottom: 1.25rem;
}

.b2b-hero__sub {
    font-size: 1.15rem;
    color: var(--text-secondary);
    max-width: 34rem;
    margin-bottom: 2rem;
}

.b2b-hero__actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 2.25rem;
}

.b2b-hero__trust {
    display: flex;
    align-items: center;
    gap: 1.75rem;
    flex-wrap: wrap;
}

.b2b-hero__trust-item {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.b2b-hero__trust-item svg {
    width: 18px;
    height: 18px;
    color: var(--accent-emerald);
    flex-shrink: 0;
}

/* Hero visual — floating dashboard card */
.b2b-hero__visual {
    position: relative;
    perspective: 1400px;
}

.b2b-dash {
    position: relative;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 1.5rem;
    transform: rotateY(-9deg) rotateX(4deg);
    transform-style: preserve-3d;
    animation: dashFloat 6s ease-in-out infinite;
}

@keyframes dashFloat {
    0%, 100% { transform: rotateY(-9deg) rotateX(4deg) translateY(0); }
    50% { transform: rotateY(-6deg) rotateX(2deg) translateY(-14px); }
}

.b2b-dash__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 1.1rem;
}

.b2b-dash__title {
    font-weight: 800;
    font-size: 1rem;
}

.b2b-dash__pill {
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--accent-emerald);
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    padding: 0.25rem 0.6rem;
    border-radius: var(--radius-full);
}

.b2b-dash__stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.85rem;
    margin-bottom: 1.1rem;
}

.b2b-dash__stat {
    background: var(--bg-elevated);
    border-radius: var(--radius-md);
    padding: 0.9rem;
}

.b2b-dash__stat-label {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.b2b-dash__stat-value {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-top: 0.25rem;
}

.b2b-dash__bars {
    display: flex;
    align-items: flex-end;
    gap: 0.5rem;
    height: 90px;
    padding-top: 0.5rem;
}

.b2b-dash__bar {
    flex: 1;
    background: var(--gradient-primary);
    border-radius: 6px 6px 0 0;
    opacity: 0.85;
    transform-origin: bottom;
    animation: barGrow 1.4s cubic-bezier(0.22, 1, 0.36, 1) backwards;
}

@keyframes barGrow {
    from { transform: scaleY(0); }
    to { transform: scaleY(1); }
}

/* Floating mini-badges around dashboard */
.b2b-float-tag {
    position: absolute;
    background: #ffffff;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-md);
    border-radius: var(--radius-md);
    padding: 0.6rem 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 0.82rem;
    z-index: 3;
}

.b2b-float-tag svg { width: 18px; height: 18px; }

.b2b-float-tag--gst {
    top: 8%;
    left: -34px;
    color: var(--accent-emerald);
    animation: tagFloatA 5s ease-in-out infinite;
}

.b2b-float-tag--bulk {
    bottom: 12%;
    right: -30px;
    color: var(--primary);
    animation: tagFloatB 6.5s ease-in-out infinite;
}

@keyframes tagFloatA {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-16px); }
}
@keyframes tagFloatB {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(14px); }
}

/* ==========================================================================
   3. Brand marquee strip
   ========================================================================== */
.b2b-marquee {
    padding: 2rem 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    background: #ffffff;
    overflow: hidden;
}

.b2b-marquee__label {
    text-align: center;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 1.25rem;
}

.b2b-marquee__track {
    display: flex;
    gap: 3rem;
    width: max-content;
    animation: marquee 26s linear infinite;
}

.b2b-marquee:hover .b2b-marquee__track {
    animation-play-state: paused;
}

.b2b-marquee__item {
    font-size: 1.4rem;
    font-weight: 800;
    color: #94a3b8;
    letter-spacing: -0.02em;
    white-space: nowrap;
    transition: color 0.3s ease;
}

.b2b-marquee__item:hover { color: var(--primary); }

@keyframes marquee {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

/* ==========================================================================
   4. Section shells
   ========================================================================== */
.b2b-section {
    padding: 5rem 0;
}

.b2b-section--tint {
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
}

.b2b-section__head {
    max-width: 42rem;
    margin: 0 auto 3rem;
    text-align: center;
}

.b2b-section__eyebrow {
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.b2b-section__title {
    font-size: clamp(1.8rem, 3.5vw, 2.5rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.15;
    margin-bottom: 1rem;
}

.b2b-section__desc {
    font-size: 1.05rem;
    color: var(--text-secondary);
}

/* ==========================================================================
   5. Feature cards grid
   ========================================================================== */
.b2b-features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.b2b-feature {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.75rem;
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease, border-color 0.35s ease;
    position: relative;
    overflow: hidden;
}

.b2b-feature::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity 0.35s ease;
    z-index: 0;
}

.b2b-feature:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: transparent;
}

.b2b-feature > * { position: relative; z-index: 1; }

.b2b-feature__icon {
    width: 54px;
    height: 54px;
    border-radius: var(--radius-md);
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #eef2ff, #fae8ff);
    color: var(--primary);
    margin-bottom: 1.1rem;
    transition: transform 0.35s ease;
}

.b2b-feature__icon svg { width: 26px; height: 26px; }

.b2b-feature:hover .b2b-feature__icon {
    transform: scale(1.1) rotate(-6deg);
}

.b2b-feature h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 0.55rem;
}

.b2b-feature p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* ==========================================================================
   6. Stats band
   ========================================================================== */
.b2b-stats {
    background: var(--b2b-navy);
    background-image: radial-gradient(circle at 20% 20%, rgba(99,102,241,0.35), transparent 45%),
                      radial-gradient(circle at 80% 60%, rgba(236,72,153,0.3), transparent 45%);
    border-radius: var(--radius-lg);
    padding: 3rem 2rem;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    text-align: center;
}

.b2b-stat__num {
    font-size: clamp(2rem, 4vw, 2.8rem);
    font-weight: 800;
    color: #ffffff;
    line-height: 1;
}

.b2b-stat__num span { color: #fbbf24; }

.b2b-stat__label {
    margin-top: 0.6rem;
    color: #cbd5e1;
    font-size: 0.9rem;
    font-weight: 600;
}

/* ==========================================================================
   7. How it works — steps
   ========================================================================== */
.b2b-steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    counter-reset: step;
}

.b2b-step {
    position: relative;
    padding: 1.5rem;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
}

.b2b-step__num {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-full);
    background: var(--gradient-primary);
    color: #fff;
    font-weight: 800;
    display: grid;
    place-items: center;
    margin-bottom: 1rem;
    box-shadow: var(--shadow-glow);
}

.b2b-step h4 {
    font-size: 1.05rem;
    font-weight: 700;
    margin-bottom: 0.4rem;
}

.b2b-step p {
    color: var(--text-secondary);
    font-size: 0.92rem;
}

/* ==========================================================================
   8. Pricing tiers
   ========================================================================== */
.b2b-pricing {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    align-items: stretch;
}

.b2b-tier {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    display: flex;
    flex-direction: column;
    transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.b2b-tier:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }

.b2b-tier--featured {
    border: 2px solid var(--primary);
    box-shadow: var(--shadow-glow);
    position: relative;
}

.b2b-tier--featured::after {
    content: 'MOST POPULAR';
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--gradient-primary);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    padding: 0.3rem 0.9rem;
    border-radius: var(--radius-full);
}

.b2b-tier__name { font-weight: 800; font-size: 1.2rem; }
.b2b-tier__range { color: var(--text-muted); font-size: 0.88rem; margin-top: 0.2rem; }

.b2b-tier__discount {
    font-size: 2.6rem;
    font-weight: 800;
    margin: 1rem 0 0.25rem;
    line-height: 1;
}

.b2b-tier__discount small { font-size: 1rem; font-weight: 700; color: var(--text-muted); }

.b2b-tier__list {
    margin: 1.25rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
}

.b2b-tier__list li {
    display: flex;
    align-items: flex-start;
    gap: 0.55rem;
    font-size: 0.92rem;
    color: var(--text-secondary);
}

.b2b-tier__list svg { width: 18px; height: 18px; color: var(--accent-emerald); flex-shrink: 0; margin-top: 2px; }

.b2b-tier .btn { margin-top: auto; }

/* ==========================================================================
   9. Final CTA
   ========================================================================== */
.b2b-cta {
    position: relative;
    overflow: hidden;
    background: var(--gradient-primary);
    border-radius: var(--radius-lg);
    padding: 4rem 2rem;
    text-align: center;
    color: #fff;
}

.b2b-cta::before,
.b2b-cta::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    background: rgba(255,255,255,0.12);
    filter: blur(20px);
}
.b2b-cta::before { width: 260px; height: 260px; top: -80px; left: -60px; }
.b2b-cta::after { width: 320px; height: 320px; bottom: -120px; right: -80px; }

.b2b-cta__inner { position: relative; z-index: 1; }

.b2b-cta h2 {
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    font-weight: 800;
    margin-bottom: 0.85rem;
}

.b2b-cta p {
    font-size: 1.1rem;
    opacity: 0.92;
    max-width: 36rem;
    margin: 0 auto 2rem;
}

.b2b-cta .btn-glass { color: var(--primary); }

/* ==========================================================================
   10. Footer
   ========================================================================== */
.b2b-footer {
    background: var(--b2b-navy);
    color: #cbd5e1;
    padding: 3.5rem 0 2rem;
}

.b2b-footer__grid {
    display: grid;
    grid-template-columns: 1.5fr repeat(3, 1fr);
    gap: 2rem;
    margin-bottom: 2.5rem;
}

.b2b-footer__brand p {
    margin-top: 1rem;
    font-size: 0.9rem;
    max-width: 22rem;
    color: #94a3b8;
}

.b2b-footer h5 {
    color: #fff;
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.b2b-footer ul { display: flex; flex-direction: column; gap: 0.6rem; }
.b2b-footer a { font-size: 0.9rem; color: #94a3b8; }
.b2b-footer a:hover { color: #fff; }

.b2b-footer__bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 1.5rem;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    font-size: 0.85rem;
    color: #64748b;
}

/* ==========================================================================
   11. Scroll-reveal animation utility
   ========================================================================== */
[data-reveal] {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
                transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
    transition-delay: var(--reveal-delay, 0ms);
    will-change: opacity, transform;
}

[data-reveal].is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   12. Responsive
   ========================================================================== */
@media (max-width: 960px) {
    .b2b-hero__grid { grid-template-columns: 1fr; gap: 3.5rem; }
    .b2b-hero__visual { max-width: 460px; margin: 0 auto; }
    .b2b-features { grid-template-columns: repeat(2, 1fr); }
    .b2b-steps { grid-template-columns: repeat(2, 1fr); }
    .b2b-pricing { grid-template-columns: 1fr; max-width: 440px; margin: 0 auto; }
    .b2b-stats { grid-template-columns: repeat(2, 1fr); }
    .b2b-footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    .b2b-nav__links,
    .b2b-nav__cta .btn-outline-sm { display: none; }

    .b2b-nav__toggle { display: flex; }

    .b2b-nav__links.is-open {
        display: flex;
        position: absolute;
        top: 72px;
        left: 0;
        right: 0;
        flex-direction: column;
        gap: 0;
        background: #fff;
        border-bottom: 1px solid var(--border-color);
        box-shadow: var(--shadow-md);
        padding: 0.5rem 1.5rem 1rem;
    }

    .b2b-nav__links.is-open a {
        padding: 0.85rem 0;
        border-bottom: 1px solid var(--border-color);
    }
}

@media (max-width: 560px) {
    .b2b-features { grid-template-columns: 1fr; }
    .b2b-steps { grid-template-columns: 1fr; }
    .b2b-stats { grid-template-columns: 1fr; gap: 2rem; }
    .b2b-footer__grid { grid-template-columns: 1fr; }
    .b2b-float-tag--gst { left: -8px; }
    .b2b-float-tag--bulk { right: -6px; }
    .b2b-hero { padding-top: 3rem; }
}

/* ==========================================================================
   13. Currency switcher (nav)
   ========================================================================== */
.b2b-currency {
    position: relative;
}

.b2b-currency__btn {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.45rem 0.7rem;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--text-primary);
    transition: var(--transition);
}

.b2b-currency__btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.b2b-currency__btn svg { width: 16px; height: 16px; }

.b2b-currency__chev {
    transition: transform 0.25s ease;
}

.b2b-currency.is-open .b2b-currency__chev {
    transform: rotate(180deg);
}

.b2b-currency__menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    min-width: 220px;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    padding: 0.4rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
    z-index: 120;
    max-height: 320px;
    overflow-y: auto;
}

.b2b-currency.is-open .b2b-currency__menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.b2b-currency__menu li {
    padding: 0.6rem 0.7rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease;
}

.b2b-currency__menu li:hover {
    background: var(--bg-elevated);
    color: var(--text-primary);
}

.b2b-currency__menu li[aria-selected="true"] {
    background: #eef2ff;
    color: var(--primary);
}

@media (max-width: 768px) {
    .b2b-currency__menu { right: auto; left: 0; }
}

/* ==========================================================================
   14. Lead capture form
   ========================================================================== */
.b2b-lead {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 3rem;
    align-items: start;
}

.b2b-lead__intro .b2b-section__title { text-align: left; }
.b2b-lead__intro .b2b-section__desc { text-align: left; }

.b2b-lead__points {
    margin-top: 1.75rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.b2b-lead__points li {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.b2b-lead__points svg {
    width: 20px;
    height: 20px;
    color: var(--accent-emerald);
    flex-shrink: 0;
    margin-top: 2px;
}

.b2b-lead__card {
    position: relative;
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 2rem;
}

.b2b-form .control-group { margin-bottom: 1rem; }

.b2b-form__opt {
    font-weight: 500;
    color: var(--text-muted);
    font-size: 0.78rem;
}

.b2b-form__err {
    display: none;
    color: #dc2626;
    font-size: 0.78rem;
    font-weight: 600;
    margin-top: 0.35rem;
}

.b2b-form .is-invalid .b2b-form__err,
.b2b-form__err.is-shown { display: block; }

.b2b-form .is-invalid input,
.b2b-form .is-invalid select {
    border-color: #dc2626 !important;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.12) !important;
}

.b2b-form__consent {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin: 0.5rem 0 1.25rem;
    cursor: pointer;
}

.b2b-form__consent input {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    accent-color: var(--primary);
    flex-shrink: 0;
    cursor: pointer;
}

.b2b-form__consent a { color: var(--primary); font-weight: 600; }
.b2b-form__consent a:hover { text-decoration: underline; }

/* Submit button + spinner */
#b2bLeadSubmit {
    position: relative;
    margin-top: 0.25rem;
}

.b2b-form__spinner {
    display: none;
    width: 18px;
    height: 18px;
    border: 2.5px solid rgba(255, 255, 255, 0.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}

#b2bLeadSubmit.is-loading .b2b-form__btn-text { visibility: hidden; }
#b2bLeadSubmit.is-loading .b2b-form__spinner {
    display: block;
    position: absolute;
    top: 50%;
    left: 50%;
    margin: -9px 0 0 -9px;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* Success state */
.b2b-form__success {
    text-align: center;
    padding: 1.5rem 0.5rem;
    animation: successPop 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes successPop {
    0% { opacity: 0; transform: scale(0.94); }
    100% { opacity: 1; transform: scale(1); }
}

.b2b-form__success-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1.25rem;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: #ecfdf5;
    color: var(--accent-emerald);
    border: 2px solid #a7f3d0;
    animation: successRing 0.6s ease 0.1s backwards;
}

@keyframes successRing {
    0% { transform: scale(0); }
    60% { transform: scale(1.15); }
    100% { transform: scale(1); }
}

.b2b-form__success-icon svg { width: 30px; height: 30px; }

.b2b-form__success h3 {
    font-size: 1.3rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.b2b-form__success p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    max-width: 24rem;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 900px) {
    .b2b-lead { grid-template-columns: 1fr; gap: 2.5rem; }
}

/* ==========================================================================
   15. Mobile responsiveness — comprehensive fixes
   ========================================================================== */

/* Prevent any horizontal scroll from decorative/transformed elements */
html, body { max-width: 100%; overflow-x: hidden; }
.b2b-hero, .b2b-section, .b2b-marquee, .b2b-cta { max-width: 100vw; }

/* Tablet / small laptop */
@media (max-width: 960px) {
    /* keep the currency switcher visible but let Sign-in hide on smaller widths */
    .b2b-hero__visual { width: 100%; }
    .b2b-dash { transform: none; }          /* drop 3D tilt on touch for clean layout */
    .b2b-dash { animation: none; }
}

/* Phones */
@media (max-width: 768px) {
    .b2b-nav__inner { height: 64px; }

    /* On phones the currency switcher moves into the mobile menu area cleanly:
       keep only the register CTA + hamburger in the bar */
    .b2b-nav__cta { gap: 0.5rem; }
    .b2b-nav__cta .btn-primary {
        padding: 0.5rem 0.85rem;
        font-size: 0.82rem;
    }
    .b2b-currency__btn { padding: 0.4rem 0.55rem; font-size: 0.8rem; }
    .b2b-currency__menu { min-width: 190px; }

    /* Hero */
    .b2b-hero { padding: 2.5rem 0 3rem; }
    .b2b-hero h1 { font-size: clamp(2rem, 8vw, 2.6rem); }
    .b2b-hero__sub { font-size: 1rem; }
    .b2b-hero__actions { flex-direction: column; align-items: stretch; }
    .b2b-hero__actions .btn { width: 100%; }
    .b2b-hero__trust { gap: 1rem 1.25rem; }
    .b2b-hero__visual { max-width: 360px; }

    /* Float tags can push width on small screens — tuck them in */
    .b2b-float-tag { font-size: 0.72rem; padding: 0.45rem 0.7rem; }
    .b2b-float-tag--gst { left: 0; top: 4%; }
    .b2b-float-tag--bulk { right: 0; bottom: 8%; }

    /* Sections tighter */
    .b2b-section { padding: 3.25rem 0; }
    .b2b-section__title { font-size: clamp(1.6rem, 6vw, 2rem); }

    /* Lead form: single column, comfortable spacing */
    .b2b-lead { gap: 2rem; }
    .b2b-lead__card { padding: 1.5rem; }

    /* CTA buttons stack */
    .b2b-cta .b2b-hero__actions { flex-direction: column; }
    .b2b-cta .btn { width: 100%; }
}

/* Small phones */
@media (max-width: 480px) {
    .b2b-nav__logo img { height: 34px; }
    /* Give priority to the menu toggle; shrink the CTA to an icon-like size */
    .b2b-nav__cta .btn-primary { padding: 0.5rem 0.7rem; font-size: 0.78rem; }

    .b2b-hero__visual { max-width: 300px; }
    .b2b-dash__stats { grid-template-columns: 1fr 1fr; }
    .b2b-marquee__item { font-size: 1.15rem; }

    .b2b-feature, .b2b-step { padding: 1.35rem; }
    .b2b-lead__card { padding: 1.25rem; }
    .b2b-cta { padding: 2.5rem 1.25rem; }
}

/* Very small phones — stop the register button from overflowing the bar */
@media (max-width: 380px) {
    .b2b-nav__cta .btn-primary { display: none; }   /* Request account is inside the menu + hero CTA */
}
