/* JMC - 04/13/2026 - Webpoint v2 homepage styles */
/* JMC - 04/14/2026 - Light/dark theme support */

/* ============================================================
   CSS Custom Properties — dark mode defaults
   ============================================================ */
:root {
    /* Brand (unchanged by theme) */
    --wp-navy:          #37517e;
    --wp-navy-dark:     #1e3a5f;
    --wp-teal:          #47b2e4;
    --wp-teal-light:    #73c5eb;
    --wp-text:          #444444;
    --wp-text-light:    #6c757d;

    /* Backgrounds */
    --bg-base:          #0d1e32;
    --bg-alt:           #0d1e32;
    --bg-card:          rgba(255, 255, 255, 0.04);
    --clients-right:    rgba(255, 255, 255, 0.04);

    /* Borders / rings */
    --ring:             rgba(255, 255, 255, 0.1);
    --ring-subtle:      rgba(255, 255, 255, 0.08);
    --divider:          rgba(255, 255, 255, 0.07);

    /* Text */
    --text-heading:     #fff;
    --text-body:        rgba(255, 255, 255, 0.6);
    --text-muted:       rgba(255, 255, 255, 0.45);

    /* Navigation */
    --nav-text:         rgba(255, 255, 255, 0.78);
    --nav-hover-bg:     rgba(255, 255, 255, 0.08);
    --nav-hover-text:   #fff;
    --mobile-nav-bg:    #0d1e32;
    --mobile-nav-bdr:   rgba(255, 255, 255, 0.1);

    /* Header */
    --hdr-scrolled-bg:  rgba(13, 30, 50, 0.96);
    --hdr-shadow:       rgba(255, 255, 255, 0.06);

    /* Hero */
    --hero-fade:        #0d1e32;
    --glow-opacity:     0.22;
    --badge-text:       rgba(255, 255, 255, 0.55);
    --badge-border:     rgba(255, 255, 255, 0.12);
    --hero-link:        rgba(255, 255, 255, 0.75);

    /* Dialog */
    --dlg-bg:           #0f1e30;
    --dlg-ring:         rgba(255, 255, 255, 0.08);
    --dlg-border:       rgba(255, 255, 255, 0.08);
    --dlg-heading:      #fff;
    --dlg-text:         rgba(255, 255, 255, 0.8);
    --dlg-label:        rgba(255, 255, 255, 0.88);
    --dlg-input-bg:     rgba(255, 255, 255, 0.06);
    --dlg-input-bdr:    rgba(255, 255, 255, 0.12);
    --dlg-input-text:   #fff;
    --dlg-ph:           rgba(255, 255, 255, 0.25);
    --dlg-focus-bg:     rgba(255, 255, 255, 0.09);
    --dlg-notice:       rgba(255, 255, 255, 0.72);
    --dlg-close-bdr:    rgba(255, 255, 255, 0.18);
    --dlg-close-text:   rgba(255, 255, 255, 0.6);
    --dlg-close-hbdr:   rgba(255, 255, 255, 0.4);
    --dlg-close-htxt:   #fff;

    /* Theme toggle */
    --toggle-color:     rgba(255, 255, 255, 0.65);
    --toggle-hover-bg:  rgba(255, 255, 255, 0.08);
    --toggle-hcolor:    #fff;
}

/* ============================================================
   Light mode overrides
   ============================================================ */
html[data-theme="light"] {
    --bg-base:          #ffffff;
    --bg-alt:           #f9fafb;
    --bg-card:          #ffffff;
    --clients-right:    rgba(0, 0, 0, 0.03);

    --ring:             rgba(0, 0, 0, 0.08);
    --ring-subtle:      rgba(0, 0, 0, 0.06);
    --divider:          rgba(0, 0, 0, 0.07);

    --text-heading:     #111827;
    --text-body:        #4b5563;
    --text-muted:       #6b7280;

    --nav-text:         #374151;
    --nav-hover-bg:     rgba(0, 0, 0, 0.05);
    --nav-hover-text:   #111827;
    --mobile-nav-bg:    #ffffff;
    --mobile-nav-bdr:   rgba(0, 0, 0, 0.08);

    --hdr-scrolled-bg:  rgba(255, 255, 255, 0.97);
    --hdr-shadow:       rgba(0, 0, 0, 0.08);

    --hero-fade:        #ffffff;
    --glow-opacity:     0.12;
    --badge-text:       #374151;
    --badge-border:     rgba(0, 0, 0, 0.12);
    --hero-link:        rgba(17, 24, 39, 0.6);

    --dlg-bg:           #ffffff;
    --dlg-ring:         rgba(0, 0, 0, 0.1);
    --dlg-border:       rgba(0, 0, 0, 0.08);
    --dlg-heading:      #111827;
    --dlg-text:         #374151;
    --dlg-label:        #374151;
    --dlg-input-bg:     rgba(0, 0, 0, 0.03);
    --dlg-input-bdr:    rgba(0, 0, 0, 0.12);
    --dlg-input-text:   #111827;
    --dlg-ph:           rgba(0, 0, 0, 0.3);
    --dlg-focus-bg:     rgba(71, 178, 228, 0.05);
    --dlg-notice:       #4b5563;
    --dlg-close-bdr:    rgba(0, 0, 0, 0.15);
    --dlg-close-text:   #374151;
    --dlg-close-hbdr:   rgba(0, 0, 0, 0.3);
    --dlg-close-htxt:   #111827;

    --toggle-color:     rgba(17, 24, 39, 0.55);
    --toggle-hover-bg:  rgba(0, 0, 0, 0.05);
    --toggle-hcolor:    #111827;
}

/* ============================================================
   Smooth transition — only while switching themes
   ============================================================ */
html.theme-transitioning *,
html.theme-transitioning *::before,
html.theme-transitioning *::after {
    transition: background-color 0.25s ease, border-color 0.25s ease,
                color 0.25s ease, box-shadow 0.25s ease, opacity 0.25s ease !important;
}

/* ============================================================
   Base
   ============================================================ */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
}

body {
    font-family: "Inter", sans-serif;
    color: var(--wp-text);
    background: var(--bg-base);
    overflow-x: hidden;
    margin: 0;
}

dialog:not([open]) {
    display: none !important;
}

h1, h2, h3, h4, h5, h6 {
    font-family: "Inter", sans-serif;
}

/* ============================================================
   Preloader
   ============================================================ */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    background: var(--wp-navy);
}

#preloader::before {
    content: "";
    position: fixed;
    top: calc(50% - 30px);
    left: calc(50% - 30px);
    border: 6px solid var(--wp-navy);
    border-top-color: #fff;
    border-bottom-color: #fff;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ============================================================
   Back to top
   ============================================================ */
.back-to-top {
    position: fixed;
    visibility: hidden;
    opacity: 0;
    right: 20px;
    bottom: 20px;
    z-index: 996;
    background: var(--wp-teal);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 20px;
    text-decoration: none;
}

.back-to-top.active {
    visibility: visible;
    opacity: 1;
}

.back-to-top:hover {
    background: var(--wp-teal-light);
    color: #fff;
}

/* ============================================================
   Container
   ============================================================ */
.container {
    width: 100%;
    max-width: 1320px;
    margin-right: auto;
    margin-left: auto;
    padding-right: 16px;
    padding-left: 16px;
}

/* ============================================================
   Header
   ============================================================ */
.header-v2 {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 999;
    background: transparent;
    padding: 20px 0;
    transition: background 0.4s ease, padding 0.35s ease, box-shadow 0.35s ease;
}

.header-v2.scrolled {
    background: var(--hdr-scrolled-bg);
    padding: 13px 0;
    box-shadow: 0 1px 0 var(--hdr-shadow);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.header-v2 .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 4px;
}

.header-v2 .logo img {
    height: 34px;
    width: auto;
}

/* JMC - 04/14/2026 - Logo swap for light/dark theme */
img.logo-light-only { display: none !important; }
html[data-theme="light"] img.logo-light-only { display: block !important; }
html[data-theme="light"] .header-v2 .logo img:not(.logo-light-only),
html[data-theme="light"] .footer-v2 .footer-logo:not(.logo-light-only),
html[data-theme="light"] .cdlg-logo:not(.logo-light-only) { display: none !important; }

.header-v2 .nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.header-v2 .nav-links a {
    color: var(--nav-text);
    font-size: 0.875rem;
    font-weight: 600;
    font-family: "Inter", sans-serif;
    padding: 6px 14px;
    border-radius: 6px;
    transition: all 0.2s;
    text-decoration: none;
}

.header-v2 .nav-links a:hover {
    color: var(--nav-hover-text);
    background: var(--nav-hover-bg);
}

.header-v2 .nav-links .btn-contact {
    background: var(--wp-teal);
    color: #fff !important;
    padding: 7px 18px;
    border-radius: 6px;
    margin-left: 4px;
}

.header-v2 .nav-links .btn-contact:hover {
    background: var(--wp-teal-light);
}

.mobile-nav-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--nav-text);
    font-size: 26px;
    cursor: pointer;
    line-height: 1;
    padding: 4px;
}

/* Theme toggle button */
.theme-toggle {
    background: none;
    border: none;
    color: var(--toggle-color);
    font-size: 17px;
    cursor: pointer;
    padding: 6px 8px;
    border-radius: 6px;
    transition: color 0.2s, background 0.2s;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-toggle:hover {
    color: var(--toggle-hcolor);
    background: var(--toggle-hover-bg);
}

/* ============================================================
   Hero Keyframes
   ============================================================ */
@keyframes heroFadeUp {
    from { opacity: 0; transform: translateY(22px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes glowDriftTop {
    0%, 100% { transform: translateX(-50%) translateY(0)     scale(1);    }
    40%       { transform: translateX(-48%) translateY(-28px) scale(1.06); }
    70%       { transform: translateX(-52%) translateY(18px)  scale(0.96); }
}

@keyframes glowDriftBottom {
    0%, 100% { transform: translateX(-50%) translateY(0)    scale(1);    }
    35%       { transform: translateX(-52%) translateY(22px) scale(1.05); }
    68%       { transform: translateX(-48%) translateY(-18px) scale(0.97); }
}

@keyframes mobileGlowPulse {
    0%, 100% { opacity: 0.14; }
    50%       { opacity: 0.24; }
}

/* ============================================================
   Hero
   ============================================================ */
.hero-v2 {
    background: var(--bg-base);
    padding: 160px 0 120px;
    text-align: center;
    position: relative;
    overflow: hidden;
    isolation: isolate;
}

.hero-v2::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 160px;
    background: linear-gradient(to bottom, transparent 0%, var(--hero-fade) 100%);
    pointer-events: none;
    z-index: 0;
}

.hero-glow {
    position: absolute;
    pointer-events: none;
    z-index: -1;
    border-radius: 50%;
    filter: blur(100px);
    opacity: var(--glow-opacity);
}

.hero-glow-top {
    top: -8rem;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 400px;
    background: #47b2e4;
    animation: glowDriftTop 14s ease-in-out infinite;
}

.hero-glow-bottom {
    bottom: -10rem;
    left: calc(50% + 10rem);
    transform: translateX(-50%);
    width: 500px;
    height: 360px;
    background: #2a628d;
    animation: glowDriftBottom 11s ease-in-out infinite;
    animation-delay: -4s;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 720px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--wp-teal);
    border: 1px solid var(--wp-teal);
    border-radius: 999px;
    padding: 5px 16px;
    margin-bottom: 28px;
    letter-spacing: 0.3px;
    animation: heroFadeUp 0.75s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.15s;
}

.hero-v2 h1 {
    font-size: clamp(2.4rem, 5.5vw, 4rem);
    font-weight: 700;
    color: var(--text-heading);
    line-height: 1.08;
    margin-bottom: 24px;
    letter-spacing: -0.5px;
    animation: heroFadeUp 0.75s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.32s;
}

.hero-v2 .hero-sub {
    font-size: 1.05rem;
    color: var(--text-body);
    max-width: 560px;
    margin: 0 auto 36px;
    line-height: 1.75;
    animation: heroFadeUp 0.75s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.48s;
}

.hero-v2 .hero-actions {
    animation: heroFadeUp 0.75s cubic-bezier(0.22, 1, 0.36, 1) both;
    animation-delay: 0.62s;
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.hero-learn-more {
    font-size: 0.9rem;
    font-weight: 600;
    font-family: "Inter", sans-serif;
    color: var(--hero-link);
    text-decoration: none;
    transition: color 0.2s;
}

.hero-learn-more:hover {
    color: var(--text-heading);
}

/* ============================================================
   Buttons
   ============================================================ */
.btn-wp-primary {
    background: var(--wp-teal);
    color: #fff;
    border: 2px solid var(--wp-teal);
    padding: 12px 30px;
    border-radius: 4px;
    font-size: 15px;
    font-weight: 600;
    font-family: "Inter", sans-serif;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-block;
    cursor: pointer;
}

.btn-wp-primary:hover {
    background: var(--wp-teal-light);
    border-color: var(--wp-teal-light);
    color: #fff;
    transform: translateY(-1px);
}

.btn-wp-outline {
    background: transparent;
    color: var(--text-heading);
    border: 2px solid var(--ring);
    padding: 12px 30px;
    border-radius: 4px;
    font-size: 15px;
    font-weight: 600;
    font-family: "Inter", sans-serif;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-block;
    cursor: pointer;
}

.btn-wp-outline:hover {
    border-color: var(--text-body);
    color: var(--text-heading);
    background: var(--nav-hover-bg);
}

.btn-wp-navy {
    background: transparent;
    color: var(--wp-navy);
    border: 2px solid var(--wp-navy);
    padding: 11px 30px;
    border-radius: 4px;
    font-size: 15px;
    font-weight: 600;
    font-family: "Inter", sans-serif;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-wp-navy:hover {
    background: var(--wp-navy);
    color: #fff;
}

/* ============================================================
   Clients Split
   ============================================================ */
.clients-section {
    background: var(--bg-alt);
    padding: 22px 0;
}

.clients-split {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: inset 0 0 0 1px var(--ring);
    max-width: 860px;
    margin: 0 auto;
}

.clients-split-left {
    background: #fff;
    padding: 18px 22px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.clients-logo-stack {
    display: flex;
    flex-wrap: nowrap;
    gap: 0 40px;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.clients-logo-stack img {
    max-height: 68px;
    max-width: 140px;
    width: auto;
    flex-shrink: 1;
}

.clients-split-right {
    background: var(--clients-right);
    padding: 18px 28px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.clients-heading {
    font-family: "Inter", sans-serif;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-heading);
    margin-top: 0;
    margin-bottom: 10px;
}

.clients-split-right p {
    font-size: 0.875rem;
    color: var(--text-body);
    line-height: 1.7;
    max-width: 420px;
    margin: 0;
}

/* ============================================================
   Features Section
   ============================================================ */
.features-section {
    padding: 56px 0 72px;
    background: var(--bg-base);
}

.features-intro {
    max-width: 580px;
    margin: 0 auto 60px;
    text-align: center;
}

.features-eyebrow {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--wp-teal);
    margin-bottom: 12px;
    letter-spacing: 0.4px;
}

.features-heading {
    font-size: clamp(1.8rem, 3.5vw, 2.6rem);
    font-weight: 700;
    color: var(--text-heading);
    line-height: 1.15;
    margin-bottom: 16px;
}

.features-sub {
    font-size: 1rem;
    color: var(--text-body);
    line-height: 1.7;
    margin: 0;
}

.feat-card-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.feat-card {
    background: var(--bg-card);
    border-radius: 16px;
    box-shadow: inset 0 0 0 1px var(--ring);
    padding: 28px 24px;
    display: flex;
    flex-direction: column;
}

.feat-card-icon {
    font-size: 2rem;
    color: var(--wp-teal);
    display: block;
    margin-bottom: 14px;
    line-height: 1;
}

.feat-card h4 {
    font-family: "Inter", sans-serif;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-heading);
    margin-bottom: 8px;
    line-height: 1.3;
}

.feat-card p {
    font-size: 0.825rem;
    color: var(--text-body);
    line-height: 1.65;
    margin: 0;
}

.features-cta {
    margin-top: 52px;
    text-align: center;
}

.btn-feat-all {
    display: inline-block;
    background: var(--wp-teal);
    color: #fff;
    font-size: 0.875rem;
    font-weight: 600;
    font-family: "Inter", sans-serif;
    padding: 10px 20px;
    border-radius: 6px;
    text-decoration: none;
    transition: background 0.2s;
}

.btn-feat-all:hover {
    background: var(--wp-teal-light);
    color: #fff;
}

/* ============================================================
   CTA Section — intentionally dark in both themes
   ============================================================ */
.cta-section {
    background: var(--bg-alt);
    padding: 56px 0 80px;
    text-align: center;
}

.cta-inner {
    position: relative;
    background: #1e3f60;
    border-radius: 24px;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.14), 0 24px 64px rgba(0, 0, 0, 0.45);
    padding: 80px 48px;
    overflow: hidden;
}

.cta-glow-svg {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 960px;
    height: 960px;
    pointer-events: none;
    mask-image: radial-gradient(closest-side, white, transparent);
    -webkit-mask-image: radial-gradient(closest-side, white, transparent);
    opacity: 0.5;
}

.cta-blob {
    position: absolute;
    pointer-events: none;
    border-radius: 50%;
    filter: blur(90px);
    opacity: 0.18;
    z-index: 0;
}

.cta-blob-1 {
    width: 420px;
    height: 420px;
    background: #47b2e4;
    top: -80px;
    left: -60px;
    animation: ctaBlobDrift1 16s ease-in-out infinite;
}

.cta-blob-2 {
    width: 340px;
    height: 340px;
    background: #7ec8e3;
    bottom: -60px;
    right: -40px;
    animation: ctaBlobDrift2 20s ease-in-out infinite;
}

@keyframes ctaBlobDrift1 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    35%       { transform: translate(40px, 30px) scale(1.07); }
    70%       { transform: translate(-20px, 50px) scale(0.95); }
}

@keyframes ctaBlobDrift2 {
    0%, 100% { transform: translate(0, 0) scale(1); }
    40%       { transform: translate(-50px, -30px) scale(1.05); }
    72%       { transform: translate(20px, -50px) scale(0.97); }
}

.cta-inner h2 {
    position: relative;
    font-size: clamp(1.8rem, 3.5vw, 2.8rem);
    font-weight: 700;
    color: #fff;
    margin-bottom: 20px;
    z-index: 1;
}

.cta-inner .cta-sub {
    position: relative;
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.65);
    max-width: 540px;
    margin: 0 auto 40px;
    line-height: 1.7;
    z-index: 1;
}

.cta-actions {
    position: relative;
    z-index: 1;
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
}

.btn-cta {
    display: inline-block;
    background: rgba(255, 255, 255, 0.1);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
    color: #fff;
    font-size: 0.875rem;
    font-weight: 600;
    font-family: "Inter", sans-serif;
    padding: 10px 22px;
    border-radius: 6px;
    text-decoration: none;
    transition: background 0.2s;
}

.btn-cta:hover {
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
}

.cta-link-secondary {
    font-size: 0.875rem;
    font-weight: 600;
    font-family: "Inter", sans-serif;
    color: #fff;
    text-decoration: none;
    transition: opacity 0.2s;
}

.cta-link-secondary:hover {
    opacity: 0.75;
    color: #fff;
}

/* ============================================================
   Footer
   ============================================================ */
.footer-v2 {
    background: var(--bg-alt);
    border-top: 1px solid var(--divider);
    padding: 40px 0;
    text-align: center;
}

.footer-v2 .footer-logo {
    height: 28px;
    margin-bottom: 16px;
    opacity: 0.9;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.footer-v2 .copyright {
    font-size: 0.8rem;
    line-height: 1.5;
    color: var(--text-muted);
}

/* ============================================================
   Contact Dialog
   ============================================================ */
#contactModal {
    padding: 0;
    border: none;
    background: transparent;
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    position: fixed;
    inset: 0;
    overflow: hidden;
    display: none;
    align-items: center;
    justify-content: center;
}

#contactModal[open] {
    display: flex;
}

#contactModal::backdrop {
    display: none;
}

.cdlg-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
}

.cdlg-panel {
    position: relative;
    background: var(--dlg-bg);
    border-radius: 12px;
    width: 100%;
    max-width: 460px;
    z-index: 1;
    outline: 1px solid var(--dlg-ring);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    margin: 16px;
}

@keyframes dlgPanelIn {
    from { opacity: 0; transform: translateY(-14px) scale(0.96); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes dlgPanelOut {
    from { opacity: 1; transform: translateY(0) scale(1); }
    to   { opacity: 0; transform: translateY(-10px) scale(0.97); }
}
@keyframes dlgBackdropIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes dlgBackdropOut {
    from { opacity: 1; }
    to   { opacity: 0; }
}

#contactModal[open] .cdlg-panel      { animation: dlgPanelIn     0.25s ease-out; }
#contactModal[open] .cdlg-backdrop   { animation: dlgBackdropIn  0.25s ease-out; }
#contactModal.closing .cdlg-panel    { animation: dlgPanelOut    0.2s ease-in forwards; }
#contactModal.closing .cdlg-backdrop { animation: dlgBackdropOut 0.2s ease-in forwards; }

.cdlg-header {
    padding: 28px 28px 20px;
    text-align: center;
    border-bottom: 1px solid var(--dlg-border);
}

.cdlg-logo {
    height: 34px;
    width: auto;
    margin: 0 auto 14px;
    display: block;
}

.cdlg-header h4 {
    font-family: "Inter", sans-serif;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--dlg-heading);
    margin: 0 0 6px;
}

.cdlg-header p {
    font-size: 0.85rem;
    color: var(--dlg-text);
    margin: 0;
}

.cdlg-body {
    padding: 24px 28px 8px;
}

.cdlg-field {
    margin-bottom: 16px;
}

.cdlg-field label {
    display: block;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--dlg-label);
    margin-bottom: 6px;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

.cdlg-field input,
.cdlg-field textarea {
    width: 100%;
    background: var(--dlg-input-bg);
    border: 1px solid var(--dlg-input-bdr);
    border-radius: 6px;
    padding: 9px 12px;
    font-size: 0.875rem;
    color: var(--dlg-input-text);
    transition: border-color 0.2s, background 0.2s;
    outline: none;
    font-family: "Inter", sans-serif;
    resize: vertical;
    box-sizing: border-box;
}

.cdlg-field input::placeholder,
.cdlg-field textarea::placeholder {
    color: var(--dlg-ph);
}

.cdlg-field input:focus,
.cdlg-field textarea:focus {
    border-color: rgba(71, 178, 228, 0.6);
    background: var(--dlg-focus-bg);
}

.cdlg-notice {
    font-size: 0.775rem;
    color: var(--dlg-notice);
    margin: 0 0 8px;
    line-height: 1.5;
}

.cdlg-footer {
    padding: 16px 28px 24px;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.cdlg-btn-close {
    background: transparent;
    border: 1px solid var(--dlg-close-bdr);
    color: var(--dlg-close-text);
    border-radius: 6px;
    padding: 9px 20px;
    font-size: 0.875rem;
    font-weight: 600;
    font-family: "Inter", sans-serif;
    cursor: pointer;
    transition: all 0.2s;
}

.cdlg-btn-close:hover {
    border-color: var(--dlg-close-hbdr);
    color: var(--dlg-close-htxt);
}

.cdlg-btn-submit {
    background: var(--wp-teal);
    border: 1px solid var(--wp-teal);
    color: #fff;
    border-radius: 6px;
    padding: 9px 22px;
    font-size: 0.875rem;
    font-weight: 600;
    font-family: "Inter", sans-serif;
    cursor: pointer;
    transition: all 0.2s;
}

.cdlg-btn-submit:hover {
    background: var(--wp-teal-light);
    border-color: var(--wp-teal-light);
}

.cdlg-btn-submit:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 1199px) {
    .feat-card-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 991px) {
    .header-v2 {
        transition: none;
    }

    .header-v2.scrolled {
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .hero-glow {
        filter: none;
        animation: mobileGlowPulse 8s ease-in-out infinite;
        /* Force GPU compositing layer — fixes Firefox Android flicker */
        backface-visibility: hidden;
        will-change: opacity;
    }

    .hero-glow-top {
        background: radial-gradient(circle, #47b2e4 0%, transparent 65%);
        transform: translateX(-50%) translateZ(0);
    }

    .hero-glow-bottom {
        background: radial-gradient(circle, #2a628d 0%, transparent 65%);
        transform: translateX(-50%) translateZ(0);
        animation-delay: 3s;
    }

    .cta-blob {
        filter: none;
        animation: mobileGlowPulse 10s ease-in-out infinite;
        backface-visibility: hidden;
        transform: translateZ(0);
        will-change: opacity;
    }

    .cta-blob-1 {
        background: radial-gradient(circle, #47b2e4 0%, transparent 65%);
    }

    .cta-blob-2 {
        background: radial-gradient(circle, #7ec8e3 0%, transparent 65%);
        animation-delay: 4s;
    }

    .mobile-nav-toggle {
        display: block;
    }

    .nav-links-wrap {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--mobile-nav-bg);
        padding: 12px 16px 16px;
        border-top: 1px solid var(--mobile-nav-bdr);
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    }

    .nav-links-wrap.open {
        display: block;
    }

    .header-v2 .nav-links {
        flex-direction: row;
        align-items: center;
        gap: 8px;
    }

    .header-v2 .nav-links .btn-contact {
        margin-left: 0;
        margin-top: 0;
        width: auto;
        text-align: center;
    }

    .hero-v2 {
        padding: 130px 0 80px;
    }
}

@media (max-width: 768px) {
    .clients-split {
        grid-template-columns: 1fr;
    }

    .clients-split-left {
        order: 1;
        padding: 18px 22px;
    }

    .clients-logo-stack {
        gap: 0 20px;
        flex-wrap: wrap;
        justify-content: center;
    }

    .clients-logo-stack img {
        max-height: 60px;
        max-width: 120px;
    }

    .clients-split-right {
        order: 2;
        padding: 18px 24px;
    }
}

@media (max-width: 575px) {
    .hero-v2 {
        padding: 110px 0 72px;
    }

    .hero-v2 .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .btn-wp-primary,
    .btn-wp-outline {
        text-align: center;
    }

    .features-section {
        padding: 60px 0 48px;
    }

    .cta-section {
        padding: 36px 0 52px;
    }

    .cta-inner {
        padding: 56px 28px;
        border-radius: 18px;
    }

    .feat-card-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
