/* ============================================================
   TheMoizKhan.com — Site stylesheet (Xtract-inspired design)
   Dark theme · violet accent · glass cards · scroll reveals
   ============================================================ */

:root {
    --bg: #07070d;
    --bg-soft: #0b0b14;
    --surface: rgba(255, 255, 255, 0.03);
    --surface-2: rgba(255, 255, 255, 0.055);
    --border: rgba(255, 255, 255, 0.09);
    --border-strong: rgba(255, 255, 255, 0.16);
    --text: #f4f4f8;
    --text-2: #a3a3b8;
    --text-3: #71718a;
    --accent: #8b5cf6;
    --accent-2: #a78bfa;
    --accent-deep: #6d28d9;
    --accent-glow: rgba(139, 92, 246, 0.35);
    --grad: linear-gradient(135deg, #a78bfa 0%, #8b5cf6 45%, #6d28d9 100%);
    --grad-text: linear-gradient(100deg, #c4b5fd 0%, #8b5cf6 50%, #7c3aed 100%);
    --radius: 16px;
    --radius-lg: 24px;
    --font: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --shadow-glow: 0 0 40px var(--accent-glow);
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --nav-h: 72px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    font-size: 16px;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

img, svg { display: inline-block; vertical-align: middle; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; }

::selection { background: var(--accent); color: #fff; }

h1, h2, h3, h4 { font-weight: 700; letter-spacing: -0.02em; line-height: 1.15; }

.container { width: min(1140px, 100% - 48px); margin-inline: auto; }

/* ---------- Accessibility ---------- */
.skip-link {
    position: absolute; left: -9999px; top: 0; z-index: 2000;
    background: var(--accent); color: #fff; padding: 10px 18px; border-radius: 0 0 8px 0;
}
.skip-link:focus { left: 0; }

:focus-visible { outline: 2px solid var(--accent-2); outline-offset: 3px; border-radius: 4px; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
    .reveal { opacity: 1 !important; transform: none !important; }
}

/* ---------- Ambient background ---------- */
.bg-ambient { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }

.bg-grid {
    position: absolute; inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: radial-gradient(ellipse 90% 60% at 50% 0%, #000 50%, transparent 100%);
    -webkit-mask-image: radial-gradient(ellipse 90% 60% at 50% 0%, #000 50%, transparent 100%);
}

.bg-glow { position: absolute; border-radius: 50%; filter: blur(120px); opacity: 0.5; }
.bg-glow-1 { width: 560px; height: 560px; top: -220px; left: 50%; transform: translateX(-50%); background: radial-gradient(circle, rgba(139, 92, 246, 0.45), transparent 70%); animation: drift 14s ease-in-out infinite alternate; }
.bg-glow-2 { width: 420px; height: 420px; bottom: -180px; right: -120px; background: radial-gradient(circle, rgba(109, 40, 217, 0.3), transparent 70%); animation: drift 18s ease-in-out infinite alternate-reverse; }

@keyframes drift {
    from { transform: translate(-50%, 0) scale(1); }
    to { transform: translate(-44%, 30px) scale(1.08); }
}
.bg-glow-2 { animation-name: drift2; }
@keyframes drift2 {
    from { transform: translate(0, 0) scale(1); }
    to { transform: translate(-40px, -30px) scale(1.1); }
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    font-weight: 600; font-size: 0.95rem; line-height: 1;
    padding: 14px 26px; border-radius: 12px; border: 1px solid transparent;
    transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), background 0.25s, border-color 0.25s;
    white-space: nowrap;
}
.btn svg { transition: transform 0.25s var(--ease); }
.btn:hover svg { transform: translateX(3px); }

.btn-primary {
    background: var(--grad); color: #fff;
    box-shadow: 0 4px 24px var(--accent-glow), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 32px var(--accent-glow), inset 0 1px 0 rgba(255, 255, 255, 0.25); }

.btn-ghost { background: var(--surface); border-color: var(--border); color: var(--text); }
.btn-ghost:hover { background: var(--surface-2); border-color: var(--border-strong); transform: translateY(-2px); }

.btn-sm { padding: 10px 18px; font-size: 0.88rem; border-radius: 10px; }
.btn-lg { padding: 16px 32px; font-size: 1rem; }
.btn-block { width: 100%; }

/* ---------- Badges ---------- */
.badge {
    display: inline-flex; align-items: center; gap: 8px;
    font-size: 0.82rem; font-weight: 500; color: var(--text-2);
    background: var(--surface); border: 1px solid var(--border);
    padding: 7px 16px; border-radius: 999px;
    backdrop-filter: blur(8px);
}
.badge-dot {
    width: 7px; height: 7px; border-radius: 50%; background: #4ade80;
    box-shadow: 0 0 8px rgba(74, 222, 128, 0.8);
    animation: pulse-dot 2s ease-in-out infinite;
}
@keyframes pulse-dot { 50% { opacity: 0.5; } }

.grad-text {
    background: var(--grad-text);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent;
}

/* ---------- Navbar ---------- */
.navbar {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    transition: background 0.3s, border-color 0.3s, backdrop-filter 0.3s;
    border-bottom: 1px solid transparent;
}
.navbar.scrolled {
    background: rgba(7, 7, 13, 0.78);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom-color: var(--border);
}

.nav-container {
    width: min(1140px, 100% - 48px); margin-inline: auto;
    height: var(--nav-h);
    display: flex; align-items: center; justify-content: space-between; gap: 24px;
}

.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.1rem; }
.logo-mark {
    display: inline-flex; align-items: center; justify-content: center;
    width: 34px; height: 34px; border-radius: 10px;
    background: var(--grad); color: #fff; font-size: 1rem; font-weight: 800;
    box-shadow: 0 2px 14px var(--accent-glow);
}
.logo-text span { color: var(--accent-2); }

.nav-menu { display: flex; align-items: center; gap: 4px; }
.nav-link {
    display: inline-block; padding: 9px 16px; border-radius: 10px;
    font-size: 0.92rem; font-weight: 500; color: var(--text-2);
    transition: color 0.2s, background 0.2s;
}
.nav-link:hover { color: var(--text); background: var(--surface); }
.nav-link.active { color: var(--text); background: var(--surface-2); }

.nav-actions { display: flex; align-items: center; gap: 12px; }
.nav-cta-mobile { display: none; }

.mobile-menu-btn {
    display: none; flex-direction: column; justify-content: center; gap: 5px;
    width: 42px; height: 42px; padding: 10px;
    background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
}
.mobile-menu-btn span { display: block; height: 2px; width: 100%; background: var(--text); border-radius: 2px; transition: transform 0.3s var(--ease), opacity 0.2s; }
.mobile-menu-btn[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.mobile-menu-btn[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.mobile-menu-btn[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
    position: relative;
    padding: calc(var(--nav-h) + 72px) 0 72px;
    text-align: center;
}
.hero .container { display: flex; flex-direction: column; align-items: center; gap: 24px; }

.hero h1 {
    font-size: clamp(2.4rem, 6vw, 4.2rem);
    font-weight: 800; letter-spacing: -0.035em;
    max-width: 880px;
}
.hero .lede {
    color: var(--text-2); font-size: clamp(1rem, 2vw, 1.18rem);
    max-width: 640px;
}

.cta-buttons { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }

.hero-trust { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 26px; margin-top: 14px; color: var(--text-3); font-size: 0.9rem; }
.hero-trust strong { color: var(--text); font-weight: 600; }
.hero-trust .sep { width: 4px; height: 4px; border-radius: 50%; background: var(--text-3); }

/* staggered hero entrance */
.hero-anim { opacity: 0; transform: translateY(24px); animation: hero-in 0.9s var(--ease) forwards; }
.hero-anim:nth-child(2) { animation-delay: 0.12s; }
.hero-anim:nth-child(3) { animation-delay: 0.24s; }
.hero-anim:nth-child(4) { animation-delay: 0.36s; }
.hero-anim:nth-child(5) { animation-delay: 0.48s; }
@keyframes hero-in { to { opacity: 1; transform: none; } }

/* ---------- Marquee ---------- */
.marquee-section { padding: 28px 0 56px; }
.marquee-label { text-align: center; color: var(--text-3); font-size: 0.85rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.12em; margin-bottom: 24px; }

.marquee {
    overflow: hidden; position: relative;
    mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.marquee-track { display: flex; gap: 14px; width: max-content; animation: marquee 36s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }

.marquee-item {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 10px 22px; border-radius: 999px;
    background: var(--surface); border: 1px solid var(--border);
    color: var(--text-2); font-size: 0.92rem; font-weight: 500; white-space: nowrap;
}
.marquee-item svg { color: var(--accent-2); }

/* ---------- Sections ---------- */
.section { padding: 88px 0; position: relative; }
.section-alt { background: linear-gradient(180deg, transparent, rgba(139, 92, 246, 0.035) 50%, transparent); }

.section-header { text-align: center; max-width: 680px; margin: 0 auto 56px; display: flex; flex-direction: column; align-items: center; gap: 16px; }
.section-header h2 { font-size: clamp(1.8rem, 4vw, 2.7rem); letter-spacing: -0.03em; }
.section-header p { color: var(--text-2); font-size: 1.05rem; }

/* ---------- Reveal animations ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.reveal.in-view { opacity: 1; transform: none; }
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* ---------- Stats band ---------- */
.stats-band {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px;
    background: var(--border); border: 1px solid var(--border); border-radius: var(--radius-lg);
    overflow: hidden;
}
.stat-cell { background: var(--bg-soft); padding: 36px 20px; text-align: center; }
.stat-num { font-size: clamp(1.9rem, 4vw, 2.6rem); font-weight: 800; letter-spacing: -0.03em; background: var(--grad-text); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.stat-label { color: var(--text-2); font-size: 0.92rem; margin-top: 6px; }

/* ---------- Cards ---------- */
.card {
    position: relative;
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 30px;
    transition: transform 0.35s var(--ease), border-color 0.35s, box-shadow 0.35s, background 0.35s;
    overflow: hidden;
}
.card::before {
    content: ''; position: absolute; inset: 0; pointer-events: none;
    background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 0%), rgba(139, 92, 246, 0.09), transparent 65%);
    opacity: 0; transition: opacity 0.35s;
}
.card:hover { transform: translateY(-5px); border-color: rgba(139, 92, 246, 0.4); box-shadow: 0 16px 48px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(139, 92, 246, 0.12); }
.card:hover::before { opacity: 1; }

.cards-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.cards-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px; }

.card-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 50px; height: 50px; border-radius: 14px; margin-bottom: 20px;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.18), rgba(109, 40, 217, 0.08));
    border: 1px solid rgba(139, 92, 246, 0.3);
    color: var(--accent-2);
}
.card h3 { font-size: 1.18rem; margin-bottom: 10px; }
.card > p { color: var(--text-2); font-size: 0.95rem; }

.card-list { margin-top: 18px; display: flex; flex-direction: column; gap: 9px; }
.card-list li { display: flex; align-items: flex-start; gap: 10px; color: var(--text-2); font-size: 0.92rem; }
.card-list li svg { flex-shrink: 0; margin-top: 4px; color: var(--accent-2); }

.card-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 20px; color: var(--accent-2); font-weight: 600; font-size: 0.92rem; }
.card-link svg { transition: transform 0.25s var(--ease); }
.card-link:hover svg { transform: translateX(4px); }

/* ---------- Process steps ---------- */
.process-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.process-step { position: relative; padding: 28px 24px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); transition: transform 0.35s var(--ease), border-color 0.35s; }
.process-step:hover { transform: translateY(-5px); border-color: rgba(139, 92, 246, 0.4); }
.process-num {
    font-size: 0.8rem; font-weight: 700; letter-spacing: 0.08em;
    color: var(--accent-2);
    display: inline-flex; align-items: center; gap: 10px; margin-bottom: 16px;
}
.process-num::after { content: ''; height: 1px; width: 36px; background: linear-gradient(90deg, var(--accent), transparent); }
.process-step h3 { font-size: 1.05rem; margin-bottom: 8px; }
.process-step p { color: var(--text-2); font-size: 0.9rem; }

/* ---------- Testimonials ---------- */
.testimonial-card { display: flex; flex-direction: column; gap: 18px; }
.testimonial-stars { display: flex; gap: 3px; color: #fbbf24; }
.testimonial-card blockquote { color: var(--text-2); font-size: 0.97rem; font-style: normal; }
.testimonial-author { display: flex; align-items: center; gap: 12px; margin-top: auto; }
.testimonial-avatar {
    width: 42px; height: 42px; border-radius: 50%; flex-shrink: 0;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--grad); color: #fff; font-weight: 700; font-size: 0.95rem;
}
.testimonial-author strong { display: block; font-size: 0.95rem; }
.testimonial-author span { color: var(--text-3); font-size: 0.84rem; }

/* ---------- Pricing ---------- */
.pricing-toggle {
    display: inline-flex; align-items: center; gap: 4px; padding: 5px;
    background: var(--surface); border: 1px solid var(--border); border-radius: 999px;
}
.pricing-toggle button {
    padding: 9px 22px; border-radius: 999px; border: none; background: transparent;
    color: var(--text-2); font-weight: 600; font-size: 0.9rem; transition: background 0.25s, color 0.25s;
}
.pricing-toggle button.active { background: var(--grad); color: #fff; box-shadow: 0 2px 12px var(--accent-glow); }

.pricing-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; align-items: stretch; }
.pricing-card { display: flex; flex-direction: column; padding: 34px 30px; }
.pricing-card.featured {
    border-color: rgba(139, 92, 246, 0.55);
    background: linear-gradient(180deg, rgba(139, 92, 246, 0.1), rgba(139, 92, 246, 0.02));
    box-shadow: 0 0 56px rgba(139, 92, 246, 0.16);
}
.pricing-tag {
    position: absolute; top: 18px; right: 18px;
    font-size: 0.72rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
    background: var(--grad); color: #fff; padding: 5px 12px; border-radius: 999px;
}
.pricing-name { font-size: 1.05rem; font-weight: 600; color: var(--text-2); }
.pricing-price { display: flex; align-items: baseline; gap: 8px; margin: 14px 0 6px; }
.pricing-price .amount { font-size: 2.6rem; font-weight: 800; letter-spacing: -0.03em; }
.pricing-price .period { color: var(--text-3); font-size: 0.92rem; }
.pricing-desc { color: var(--text-2); font-size: 0.92rem; margin-bottom: 22px; }
.pricing-card .card-list { margin: 0 0 28px; }
.pricing-card .btn { margin-top: auto; }

/* ---------- Comparison table ---------- */
.compare-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); }
.compare { width: 100%; border-collapse: collapse; min-width: 640px; font-size: 0.92rem; }
.compare th, .compare td { padding: 15px 20px; text-align: left; border-bottom: 1px solid var(--border); }
.compare thead th { background: var(--surface-2); font-weight: 600; }
.compare tbody tr:last-child td { border-bottom: none; }
.compare td { color: var(--text-2); }
.compare td:first-child { color: var(--text); font-weight: 500; }
.compare .yes { color: #4ade80; }
.compare .no { color: var(--text-3); }

/* ---------- FAQ ---------- */
.faq-list { max-width: 760px; margin: 0 auto; display: flex; flex-direction: column; gap: 12px; }
.faq-item { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: border-color 0.3s; }
.faq-item.open { border-color: rgba(139, 92, 246, 0.4); }
.faq-q {
    width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px;
    padding: 20px 24px; background: none; border: none; color: var(--text);
    font-size: 1rem; font-weight: 600; text-align: left;
}
.faq-q svg { flex-shrink: 0; color: var(--accent-2); transition: transform 0.3s var(--ease); }
.faq-item.open .faq-q svg { transform: rotate(45deg); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height 0.4s var(--ease); }
.faq-a-inner { padding: 0 24px 22px; color: var(--text-2); font-size: 0.95rem; }

/* ---------- CTA band ---------- */
.cta-band { padding: 48px 0 96px; }
.cta-card {
    position: relative; text-align: center; overflow: hidden;
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
    padding: clamp(48px, 7vw, 80px) 28px;
    display: flex; flex-direction: column; align-items: center; gap: 20px;
}
.cta-glow {
    position: absolute; top: -160px; left: 50%; transform: translateX(-50%);
    width: 480px; height: 320px; border-radius: 50%;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.35), transparent 70%);
    filter: blur(60px); pointer-events: none;
}
.cta-card h2 { font-size: clamp(1.9rem, 4.5vw, 3rem); letter-spacing: -0.03em; position: relative; }
.cta-card p { color: var(--text-2); max-width: 520px; position: relative; }
.cta-card .cta-buttons { position: relative; }

/* ---------- Page hero (inner pages) ---------- */
.page-hero { padding: calc(var(--nav-h) + 64px) 0 56px; text-align: center; }
.page-hero .container { display: flex; flex-direction: column; align-items: center; gap: 20px; }
.page-hero h1 { font-size: clamp(2.2rem, 5vw, 3.4rem); letter-spacing: -0.03em; max-width: 820px; }
.page-hero .lede { color: var(--text-2); font-size: clamp(1rem, 2vw, 1.15rem); max-width: 620px; }

/* ---------- About page ---------- */
.about-split { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: start; }
.about-prose { display: flex; flex-direction: column; gap: 18px; }
.about-prose h2 { font-size: clamp(1.6rem, 3.5vw, 2.2rem); margin-bottom: 4px; }
.about-prose p { color: var(--text-2); }
.about-prose strong { color: var(--text); }

.skills-list { display: flex; flex-direction: column; gap: 18px; }
.skill-row { display: flex; flex-direction: column; gap: 8px; }
.skill-row-top { display: flex; justify-content: space-between; font-size: 0.92rem; }
.skill-row-top .pct { color: var(--text-3); }
.skill-bar { height: 7px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.skill-bar i {
    display: block; height: 100%; width: 0; border-radius: 99px;
    background: var(--grad);
    box-shadow: 0 0 12px var(--accent-glow);
    transition: width 1.2s var(--ease);
}

.timeline { position: relative; max-width: 720px; margin: 0 auto; display: flex; flex-direction: column; gap: 28px; padding-left: 32px; }
.timeline::before { content: ''; position: absolute; left: 7px; top: 8px; bottom: 8px; width: 2px; background: linear-gradient(180deg, var(--accent), rgba(139, 92, 246, 0.05)); }
.timeline-item { position: relative; }
.timeline-item::before {
    content: ''; position: absolute; left: -32px; top: 6px;
    width: 16px; height: 16px; border-radius: 50%;
    background: var(--bg); border: 3px solid var(--accent);
    box-shadow: 0 0 12px var(--accent-glow);
}
.timeline-item .year { color: var(--accent-2); font-weight: 700; font-size: 0.85rem; letter-spacing: 0.06em; }
.timeline-item h3 { font-size: 1.1rem; margin: 4px 0 6px; }
.timeline-item p { color: var(--text-2); font-size: 0.94rem; }

/* ---------- Contact page ---------- */
.contact-split { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 40px; align-items: start; }
.contact-info-cards { display: flex; flex-direction: column; gap: 16px; }
.contact-info-card { display: flex; gap: 16px; align-items: flex-start; padding: 22px; }
.contact-info-card .card-icon { width: 44px; height: 44px; margin: 0; flex-shrink: 0; }
.contact-info-card h3 { font-size: 1rem; margin-bottom: 4px; }
.contact-info-card p { color: var(--text-2); font-size: 0.92rem; }
.contact-info-card a { color: var(--accent-2); }
.contact-info-card a:hover { text-decoration: underline; }

.contact-form { padding: 34px; display: flex; flex-direction: column; gap: 18px; }
.contact-form:hover { transform: none; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-group { display: flex; flex-direction: column; gap: 7px; }
.form-group label { font-size: 0.88rem; font-weight: 600; }
.form-group label .req { color: var(--accent-2); }

.form-group input, .form-group select, .form-group textarea {
    font-family: inherit; font-size: 0.95rem; color: var(--text);
    background: rgba(255, 255, 255, 0.04); border: 1px solid var(--border); border-radius: 10px;
    padding: 13px 16px; width: 100%;
    transition: border-color 0.25s, box-shadow 0.25s, background 0.25s;
}
.form-group select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23a3a3b8' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 40px; }
.form-group select option { background: var(--bg-soft); color: var(--text); }
.form-group textarea { resize: vertical; min-height: 130px; }

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none; border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.18);
    background: rgba(255, 255, 255, 0.06);
}
.form-group input.invalid, .form-group select.invalid, .form-group textarea.invalid { border-color: #f87171; }
.error-message { color: #f87171; font-size: 0.82rem; min-height: 0; }
.error-message:empty { display: none; }

.form-status { display: none; padding: 14px 18px; border-radius: 10px; font-size: 0.92rem; font-weight: 500; }
.form-status.success { display: block; background: rgba(74, 222, 128, 0.12); border: 1px solid rgba(74, 222, 128, 0.35); color: #4ade80; }
.form-status.error { display: block; background: rgba(248, 113, 113, 0.1); border: 1px solid rgba(248, 113, 113, 0.35); color: #f87171; }

.btn .spinner {
    width: 16px; height: 16px; border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.35); border-top-color: #fff;
    animation: spin 0.7s linear infinite; display: none;
}
.btn.loading .spinner { display: inline-block; }
.btn.loading svg { display: none; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Footer ---------- */
.footer { border-top: 1px solid var(--border); background: rgba(255, 255, 255, 0.015); padding: 64px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 48px; }
.footer-brand p { color: var(--text-2); font-size: 0.92rem; margin: 18px 0 22px; max-width: 340px; }

.social-links { display: flex; gap: 10px; }
.social-links a {
    display: inline-flex; align-items: center; justify-content: center;
    width: 40px; height: 40px; border-radius: 10px;
    background: var(--surface); border: 1px solid var(--border); color: var(--text-2);
    transition: color 0.25s, border-color 0.25s, transform 0.25s var(--ease), background 0.25s;
}
.social-links a:hover { color: #fff; border-color: var(--accent); background: rgba(139, 92, 246, 0.15); transform: translateY(-3px); }

.footer-col h3 { font-size: 0.95rem; margin-bottom: 18px; }
.footer-col ul { display: flex; flex-direction: column; gap: 11px; }
.footer-col a, .footer-muted { color: var(--text-2); font-size: 0.92rem; transition: color 0.2s; }
.footer-col a:hover { color: var(--text); }
.footer-link-accent { color: var(--accent-2) !important; font-weight: 600; }

.footer-bottom {
    border-top: 1px solid var(--border); padding-top: 26px;
    display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px;
    color: var(--text-3); font-size: 0.86rem;
}

/* ---------- Scroll top ---------- */
.scroll-top {
    position: fixed; bottom: 26px; right: 26px; z-index: 900;
    width: 46px; height: 46px; border-radius: 12px;
    background: var(--grad); border: none; color: #fff;
    box-shadow: 0 4px 20px var(--accent-glow);
    opacity: 0; visibility: hidden; transform: translateY(12px);
    transition: opacity 0.3s, visibility 0.3s, transform 0.3s var(--ease);
    display: inline-flex; align-items: center; justify-content: center;
}
.scroll-top.visible { opacity: 1; visibility: visible; transform: none; }
.scroll-top:hover { transform: translateY(-3px); }

/* ---------- AI Voice Bot ---------- */
.ai-voice-bot { position: fixed; bottom: 26px; left: 26px; z-index: 950; }

.voice-bot-toggle {
    width: 56px; height: 56px; border-radius: 50%; border: none;
    background: var(--grad); color: #fff;
    box-shadow: 0 4px 24px var(--accent-glow);
    display: inline-flex; align-items: center; justify-content: center;
    transition: transform 0.25s var(--ease), box-shadow 0.25s;
    animation: bot-pulse 3s ease-in-out infinite;
}
.voice-bot-toggle:hover { transform: scale(1.08); box-shadow: 0 8px 32px var(--accent-glow); }
.voice-bot-toggle.listening { animation: bot-listening 1s ease-in-out infinite; }
.voice-bot-toggle.speaking { animation: bot-listening 0.6s ease-in-out infinite; }

@keyframes bot-pulse {
    0%, 100% { box-shadow: 0 4px 24px var(--accent-glow); }
    50% { box-shadow: 0 4px 24px var(--accent-glow), 0 0 0 10px rgba(139, 92, 246, 0.08); }
}
@keyframes bot-listening {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); box-shadow: 0 0 0 14px rgba(139, 92, 246, 0.12); }
}

.voice-bot-panel {
    position: absolute; bottom: 70px; left: 0;
    width: min(370px, calc(100vw - 48px));
    background: rgba(13, 13, 22, 0.97);
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-strong); border-radius: var(--radius);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.6), 0 0 40px rgba(139, 92, 246, 0.1);
    display: flex; flex-direction: column; overflow: hidden;
    opacity: 0; visibility: hidden; transform: translateY(12px) scale(0.98);
    transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s;
}
.voice-bot-panel.active { opacity: 1; visibility: visible; transform: none; }

.voice-bot-header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 16px 18px; border-bottom: 1px solid var(--border);
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.14), transparent);
}
.voice-bot-header h3 { font-size: 1rem; display: flex; align-items: center; gap: 9px; }
.bot-dot { width: 8px; height: 8px; border-radius: 50%; background: #4ade80; box-shadow: 0 0 8px rgba(74, 222, 128, 0.8); animation: pulse-dot 2s ease-in-out infinite; }
.voice-bot-close {
    width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--border);
    background: var(--surface); color: var(--text-2);
    display: inline-flex; align-items: center; justify-content: center;
    transition: color 0.2s, border-color 0.2s;
}
.voice-bot-close:hover { color: #fff; border-color: var(--accent); }

.voice-bot-content {
    height: 300px; overflow-y: auto; padding: 16px;
    display: flex; flex-direction: column; gap: 10px;
    scrollbar-width: thin; scrollbar-color: var(--accent-deep) transparent;
}
.voice-bot-content::-webkit-scrollbar { width: 5px; }
.voice-bot-content::-webkit-scrollbar-thumb { background: var(--accent-deep); border-radius: 99px; }

.voice-bot-message {
    max-width: 88%; padding: 11px 14px; border-radius: 14px;
    font-size: 0.88rem; line-height: 1.5; white-space: pre-line; word-wrap: break-word;
    animation: msg-in 0.3s var(--ease);
}
@keyframes msg-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.voice-bot-message.bot {
    align-self: flex-start;
    background: var(--surface-2); border: 1px solid var(--border);
    border-bottom-left-radius: 4px; color: var(--text-2);
}
.voice-bot-message.bot strong { color: var(--accent-2); }
.voice-bot-message.user {
    align-self: flex-end;
    background: var(--grad); color: #fff;
    border-bottom-right-radius: 4px;
}

.voice-bot-typing { align-self: flex-start; display: flex; gap: 5px; padding: 12px 16px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 14px; border-bottom-left-radius: 4px; }
.voice-bot-typing span { width: 7px; height: 7px; border-radius: 50%; background: var(--accent-2); animation: typing 1.2s ease-in-out infinite; }
.voice-bot-typing span:nth-child(2) { animation-delay: 0.15s; }
.voice-bot-typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes typing { 0%, 60%, 100% { transform: translateY(0); opacity: 0.4; } 30% { transform: translateY(-5px); opacity: 1; } }

.voice-bot-status {
    padding: 8px 18px; font-size: 0.76rem; color: var(--text-3);
    border-top: 1px solid var(--border); background: rgba(255, 255, 255, 0.02);
}

.voice-bot-controls { display: flex; gap: 8px; padding: 10px 14px 0; }
.voice-control-btn {
    flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
    padding: 9px 8px; border-radius: 9px; font-size: 0.8rem; font-weight: 600;
    background: var(--surface); border: 1px solid var(--border); color: var(--text-2);
    transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.voice-control-btn:hover:not(:disabled) { color: #fff; border-color: var(--accent); }
.voice-control-btn.primary { background: rgba(139, 92, 246, 0.16); border-color: rgba(139, 92, 246, 0.4); color: var(--accent-2); }
.voice-control-btn:disabled { opacity: 0.4; cursor: not-allowed; }

.voice-bot-input-container { display: flex; gap: 8px; padding: 12px 14px 14px; }
.voice-bot-input-container input {
    flex: 1; font-family: inherit; font-size: 0.88rem; color: var(--text);
    background: rgba(255, 255, 255, 0.04); border: 1px solid var(--border); border-radius: 10px;
    padding: 11px 14px;
    transition: border-color 0.25s, box-shadow 0.25s;
}
.voice-bot-input-container input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.18); }
.voice-bot-input-container button {
    width: 44px; border-radius: 10px; border: none;
    background: var(--grad); color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    box-shadow: 0 2px 12px var(--accent-glow);
    transition: transform 0.2s var(--ease);
}
.voice-bot-input-container button:hover { transform: translateY(-2px); }

/* Welcome notification */
.welcome-voice-notification {
    position: fixed; bottom: 96px; left: 26px; z-index: 940;
    background: rgba(13, 13, 22, 0.97); border: 1px solid var(--border-strong);
    border-radius: var(--radius); padding: 14px 18px;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
    opacity: 0; visibility: hidden; transform: translateY(10px);
    transition: opacity 0.4s var(--ease), transform 0.4s var(--ease), visibility 0.4s;
    max-width: 280px;
}
.welcome-voice-notification.show { opacity: 1; visibility: visible; transform: none; }
.notification-content { display: flex; align-items: center; gap: 12px; }
.voice-icon {
    width: 38px; height: 38px; border-radius: 10px; flex-shrink: 0;
    display: inline-flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.18), rgba(109, 40, 217, 0.08));
    border: 1px solid rgba(139, 92, 246, 0.3); color: var(--accent-2);
}
.notification-text h4 { font-size: 0.88rem; }
.notification-text p { font-size: 0.78rem; color: var(--text-3); }

/* Chatbot responsive — fixed panel that always fits the viewport */
@media (max-width: 768px) {
    .ai-voice-bot { bottom: 20px; left: 18px; }
    .voice-bot-panel {
        position: fixed; left: 14px; right: 14px; bottom: 88px;
        width: auto;
        max-height: calc(100dvh - 110px);
    }
    .voice-bot-content { height: auto; flex: 1; min-height: 150px; max-height: 38dvh; }
    .welcome-voice-notification { left: 18px; bottom: 88px; max-width: calc(100vw - 36px); }
}
@media (max-height: 600px) {
    .voice-bot-content { max-height: 30dvh; min-height: 110px; }
}

/* ============================================================
   3D layer — particle canvas, floating shapes, card tilt
   ============================================================ */
#bg3d {
    position: absolute; inset: 0;
    width: 100%; height: 100%;
    opacity: 0.7;
}

/* Floating 3D scene injected into heroes */
.hero-3d { position: absolute; inset: 0; pointer-events: none; z-index: 0; perspective: 900px; overflow: hidden; }
.hero, .page-hero { position: relative; }
.hero .container, .page-hero .container { position: relative; z-index: 1; }

/* Dashed orbital ring (spinning in 3D) */
.shape-ring {
    position: absolute; border-radius: 50%;
    border: 1.5px dashed rgba(139, 92, 246, 0.35);
    transform-style: preserve-3d;
    animation: ring-spin 22s linear infinite;
    will-change: transform;
}
.shape-ring.r1 { width: 460px; height: 460px; top: 6%; left: -140px; }
.shape-ring.r2 { width: 300px; height: 300px; bottom: -60px; right: -80px; border-color: rgba(167, 139, 250, 0.25); animation-duration: 30s; animation-direction: reverse; }
@keyframes ring-spin {
    from { transform: rotateX(68deg) rotateZ(0deg); }
    to { transform: rotateX(68deg) rotateZ(360deg); }
}

/* Glass 3D cube */
.shape-cube {
    position: absolute; width: 64px; height: 64px;
    top: 18%; right: 9%;
    transform-style: preserve-3d;
    animation: cube-float 14s ease-in-out infinite;
    will-change: transform;
}
.shape-cube .face {
    position: absolute; inset: 0;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.16), rgba(109, 40, 217, 0.05));
    border: 1px solid rgba(167, 139, 250, 0.4);
    backdrop-filter: blur(2px);
}
.shape-cube .face.f-front { transform: translateZ(32px); }
.shape-cube .face.f-back { transform: translateZ(-32px); }
.shape-cube .face.f-right { transform: rotateY(90deg) translateZ(32px); }
.shape-cube .face.f-left { transform: rotateY(-90deg) translateZ(32px); }
.shape-cube .face.f-top { transform: rotateX(90deg) translateZ(32px); }
.shape-cube .face.f-bottom { transform: rotateX(-90deg) translateZ(32px); }
@keyframes cube-float {
    0%, 100% { transform: translateY(0) rotateX(-18deg) rotateY(24deg); }
    25% { transform: translateY(-18px) rotateX(-30deg) rotateY(110deg); }
    50% { transform: translateY(-6px) rotateX(-12deg) rotateY(200deg); }
    75% { transform: translateY(-22px) rotateX(-26deg) rotateY(290deg); }
}

/* Small cube variant bottom-left */
.shape-cube.c2 { width: 38px; height: 38px; top: auto; bottom: 16%; right: auto; left: 7%; animation-duration: 18s; animation-delay: -6s; }
.shape-cube.c2 .face.f-front { transform: translateZ(19px); }
.shape-cube.c2 .face.f-back { transform: translateZ(-19px); }
.shape-cube.c2 .face.f-right { transform: rotateY(90deg) translateZ(19px); }
.shape-cube.c2 .face.f-left { transform: rotateY(-90deg) translateZ(19px); }
.shape-cube.c2 .face.f-top { transform: rotateX(90deg) translateZ(19px); }
.shape-cube.c2 .face.f-bottom { transform: rotateX(-90deg) translateZ(19px); }

/* Glowing floating orbs */
.shape-orb {
    position: absolute; border-radius: 50%;
    background: radial-gradient(circle at 32% 30%, rgba(196, 181, 253, 0.85), rgba(139, 92, 246, 0.5) 45%, rgba(109, 40, 217, 0.12) 75%);
    box-shadow: 0 0 28px rgba(139, 92, 246, 0.45), inset -6px -8px 18px rgba(0, 0, 0, 0.35);
    animation: orb-float 11s ease-in-out infinite;
    will-change: transform;
}
.shape-orb.o1 { width: 22px; height: 22px; top: 30%; left: 14%; }
.shape-orb.o2 { width: 14px; height: 14px; top: 16%; right: 24%; animation-duration: 13s; animation-delay: -4s; }
@keyframes orb-float {
    0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
    33% { transform: translate3d(14px, -26px, 0) scale(1.12); }
    66% { transform: translate3d(-10px, -8px, 0) scale(0.94); }
}

/* Card tilt (transform driven by JS; smooth return) */
@media (hover: hover) {
    .card, .process-step { transform-style: preserve-3d; }
    .card.tilting, .process-step.tilting { transition: transform 0.1s linear; }
    .card > *, .process-step > * { transform: translateZ(1px); }
}

/* Logo mark 3D flip on hover */
.logo:hover .logo-mark { transform: rotateY(360deg); }
.logo-mark { transition: transform 0.8s var(--ease); transform-style: preserve-3d; }

/* Stat numbers pop slightly forward on hover */
.stat-cell { transition: transform 0.35s var(--ease); }
.stat-cell:hover { transform: translateY(-4px) scale(1.03); }

@media (prefers-reduced-motion: reduce) {
    .shape-ring, .shape-cube, .shape-orb { animation: none !important; }
    #bg3d { display: none; }
}

/* ---------- 404 ---------- */
.error-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; text-align: center; padding: 24px; }
.error-page .code { font-size: clamp(5rem, 18vw, 9rem); font-weight: 800; letter-spacing: -0.05em; background: var(--grad-text); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; line-height: 1; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 1024px) {
    .cards-grid, .process-grid { grid-template-columns: repeat(2, 1fr); }
    .pricing-grid { grid-template-columns: 1fr; max-width: 480px; margin-inline: auto; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .about-split, .contact-split { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .section { padding: 64px 0; }
    .nav-cta { display: none; }
    .mobile-menu-btn { display: flex; }

    .nav-menu {
        position: fixed; top: var(--nav-h); left: 0; right: 0;
        flex-direction: column; align-items: stretch; gap: 6px;
        background: rgba(7, 7, 13, 0.97);
        backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
        border-bottom: 1px solid var(--border);
        padding: 18px 24px 24px;
        transform: translateY(-12px); opacity: 0; visibility: hidden; pointer-events: none;
        transition: transform 0.3s var(--ease), opacity 0.3s, visibility 0.3s;
    }
    .nav-menu.open { transform: none; opacity: 1; visibility: visible; pointer-events: auto; }
    .nav-link { padding: 13px 16px; font-size: 1rem; }
    .nav-cta-mobile { display: block; margin-top: 10px; }
    .nav-cta-mobile .btn { width: 100%; }

    .stats-band { grid-template-columns: repeat(2, 1fr); }
    .cards-grid, .cards-grid-2, .process-grid, .form-row { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; gap: 32px; }
    .footer-bottom { flex-direction: column; text-align: center; }
    .hero { padding-top: calc(var(--nav-h) + 48px); }
}

@media (max-width: 560px) {
    .section { padding: 56px 0; }
    .hero { padding-bottom: 48px; }
    .hero-trust { flex-direction: column; gap: 8px; }
    .hero-trust .sep { display: none; }
    .marquee-item { padding: 8px 16px; font-size: 0.85rem; }
    .pricing-toggle { width: 100%; }
    .pricing-toggle button { flex: 1; padding: 9px 10px; font-size: 0.84rem; }
    .compare th, .compare td { padding: 12px 14px; font-size: 0.85rem; }
    .section-header { margin-bottom: 40px; }
    .faq-q { padding: 16px 18px; font-size: 0.95rem; }
    .faq-a-inner { padding: 0 18px 18px; }
    .contact-form { padding: 24px 20px; }
    .stat-cell { padding: 26px 14px; }
    .timeline { padding-left: 26px; }
    .timeline-item::before { left: -26px; width: 13px; height: 13px; }
    /* declutter 3D shapes on small screens — keep orbs only */
    .shape-cube, .shape-ring.r1 { display: none; }
    .shape-ring.r2 { width: 220px; height: 220px; }
}

@media (max-width: 420px) {
    .container { width: calc(100% - 36px); }
    .btn-lg { padding: 14px 24px; }
    .cta-buttons { width: 100%; }
    .cta-buttons .btn { flex: 1; min-width: 0; }
}

/* ===========================================================
   RTL support (Arabic) — targeted overrides, scoped under
   html[dir="rtl"] so LTR locales are untouched. Flex/grid rows
   already mirror for free; these cover the spots that don't.
   =========================================================== */
html[dir="rtl"] body { direction: rtl; }

html[dir="rtl"] .lede,
html[dir="rtl"] .section-header p,
html[dir="rtl"] .faq-a-inner,
html[dir="rtl"] blockquote,
html[dir="rtl"] .about-prose p {
    text-align: right;
}

html[dir="rtl"] .card-link svg,
html[dir="rtl"] .btn svg,
html[dir="rtl"] .process-step svg {
    transform: scaleX(-1);
}

html[dir="rtl"] .faq-q {
    text-align: right;
}

/* Voicebot, scroll-top, and welcome notification stay pinned bottom-right
   regardless of RTL — their content/logic isn't localized, so we don't
   mirror their position either. */
html[dir="rtl"] .ai-voice-bot,
html[dir="rtl"] .scroll-top,
html[dir="rtl"] .welcome-voice-notification {
    left: auto;
}
