/* ============================================
   AGENTIC ASSIST — LANDING PAGE STYLES
   Dark Futuristic / Lovable-inspired
   ============================================ */

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

html {
    scroll-behavior: smooth;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img,
svg {
    display: block;
    max-width: 100%;
    height: auto;
}

img[loading="lazy"] {
    background-color: var(--bg-dark);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: fixed;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--purple);
    color: #fff;
    padding: 12px 24px;
    border-radius: 8px;
    z-index: 9999;
    font-weight: 600;
    text-decoration: none;
    transition: top 0.3s;
}

.skip-link:focus {
    top: 16px;
}

#benefits {
    scroll-margin-top: 80px;
}

.required-indicator {
    color: var(--orange);
}

:root {
    --purple: #7c3aed;
    --purple-glow: #a78bfa;
    --cyan: #22d3ee;
    --cyan-glow: #67e8f9;
    --emerald: #10b981;
    --orange: #f59e0b;
    --bg-dark: #0a0a0f;
    --bg-card: #12121a;
    --bg-card-hover: #1a1a2e;
    --text-primary: #f0f0f5;
    --text-secondary: #a1a1b5;
    --text-muted: #7a7a90;
    --border: #1e1e30;
    --gradient: linear-gradient(135deg, #7c3aed, #22d3ee);
    --gradient-text: linear-gradient(90deg, #a78bfa 0%, #67e8f9 50%, #a78bfa 100%);
    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

html {
    scroll-behavior: smooth;
}

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

/* ===== UTILITY ===== */
.container {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 24px;
}

.gradient-text {
    background: var(--gradient-text);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: shimmer 4s linear infinite;
}

@keyframes shimmer {
    0% { background-position: 0% center; }
    100% { background-position: 200% center; }
}

/* ===== NAVBAR ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 0;
    transition: padding 0.3s, background 0.3s, backdrop-filter 0.3s;
}

.navbar.scrolled {
    padding: 10px 0;
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 24px;
}

.nav-logo {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-logo .logo-icon {
    color: var(--purple-glow);
    font-size: 14px;
}

.nav-logo .logo-img {
    width: 28px;
    height: 28px;
    margin-right: 4px;
}

nav.nav-links,
.nav-links {
    display: flex;
    align-items: center;
    gap: 28px;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s;
}

.nav-links a:hover {
    color: var(--text-primary);
}

.nav-cta-btn {
    background: var(--gradient);
    padding: 8px 20px;
    border-radius: 8px;
    color: #fff !important;
    font-weight: 600;
    font-size: 13px;
    transition: transform 0.2s, box-shadow 0.2s !important;
}

.nav-cta-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 20px rgba(124, 58, 237, 0.4);
}

.nav-links a:focus-visible,
.nav-cta-btn:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 2px;
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: transform 0.3s, opacity 0.3s;
}

.hamburger:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 4px;
    border-radius: 4px;
}

/* ===== HERO ===== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

#particleCanvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.hero-glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.15;
    pointer-events: none;
}

.hero-glow-1 {
    width: 600px;
    height: 600px;
    background: var(--purple);
    top: -10%;
    left: -10%;
}

.hero-glow-2 {
    width: 500px;
    height: 500px;
    background: var(--cyan);
    bottom: -10%;
    right: -10%;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 780px;
    padding: 0 24px;
}

/* Animate-in for hero elements */
.animate-in {
    opacity: 0;
    transform: translateY(24px);
    animation: fadeUp 0.7s ease forwards;
    animation-delay: var(--delay, 0s);
    will-change: opacity, transform;
}

@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(124, 58, 237, 0.1);
    border: 1px solid rgba(124, 58, 237, 0.25);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 13px;
    color: var(--purple-glow);
    font-weight: 500;
    margin-bottom: 28px;
}

.pill-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--emerald);
    box-shadow: 0 0 8px var(--emerald);
    animation: pulse-dot 2s ease infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.hero-title {
    font-size: clamp(38px, 6vw, 64px);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -2px;
    margin-bottom: 24px;
    color: var(--text-primary);
}

.hero-desc {
    font-size: 17px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 36px;
    line-height: 1.7;
}

.hero-desc strong {
    color: var(--text-primary);
}

.hero-actions {
    display: flex;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
    margin-bottom: 48px;
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: transform 0.2s, box-shadow 0.2s;
    text-decoration: none;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 2px;
}

.btn-primary {
    background: var(--gradient);
    color: #fff;
    box-shadow: 0 4px 16px rgba(124, 58, 237, 0.3);
}

.btn-primary:hover {
    box-shadow: 0 6px 30px rgba(124, 58, 237, 0.5);
}

.btn-glow {
    animation: btn-pulse 3s ease infinite;
}

@keyframes btn-pulse {
    0%, 100% { box-shadow: 0 4px 16px rgba(124, 58, 237, 0.3); }
    50% { box-shadow: 0 4px 32px rgba(124, 58, 237, 0.6); }
}

.btn-ghost {
    background: rgba(255,255,255,0.04);
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.btn-ghost:hover {
    background: rgba(255,255,255,0.08);
    color: var(--text-primary);
    border-color: rgba(255,255,255,0.15);
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-outline:hover {
    border-color: var(--purple-glow);
    color: var(--purple-glow);
}

.btn-replay {
    background: rgba(124, 58, 237, 0.1);
    color: var(--purple-glow);
    border: 1px solid rgba(124, 58, 237, 0.2);
    padding: 10px 22px;
    font-size: 13px;
    width: 100%;
    justify-content: center;
    margin-top: 16px;
    transition: background 0.2s, transform 0.2s;
}

.btn-replay:hover {
    background: rgba(124, 58, 237, 0.2);
}

.btn-icon {
    font-size: 12px;
}

/* ===== HERO SOCIAL PROOF ===== */
.hero-social-proof {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.proof-avatars {
    display: flex;
}

.avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    border: 2px solid var(--bg-dark);
    margin-left: -8px;
}

.avatar:first-child { margin-left: 0; }
.av1 { background: #7c3aed; color: #fff; }
.av2 { background: #22d3ee; color: #0a0a0f; }
.av3 { background: #10b981; color: #fff; }
.av4 { background: #f59e0b; color: #0a0a0f; }

.proof-text {
    font-size: 13px;
    color: var(--text-secondary);
}

.proof-text strong {
    color: var(--text-primary);
}

/* ===== SCROLL CUE ===== */
.scroll-cue {
    position: absolute;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.scroll-line {
    width: 1px;
    height: 48px;
    background: linear-gradient(to bottom, var(--purple-glow), transparent);
    margin: 0 auto;
    animation: scroll-down 2s ease infinite;
}

@keyframes scroll-down {
    0% { opacity: 1; transform: scaleY(0); transform-origin: top; }
    100% { opacity: 0; transform: scaleY(1); transform-origin: top; }
}

/* ===== SECTIONS COMMON ===== */
.benefits,
.how-it-works,
.demo-section {
    padding: 120px 0;
}

.section-label {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 20px;
}

.label-line {
    width: 40px;
    height: 1px;
    background: var(--border);
}

.section-label span:not(.label-line) {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--purple-glow);
    font-weight: 600;
}

.section-heading {
    font-size: clamp(28px, 4vw, 42px);
    font-weight: 800;
    text-align: center;
    line-height: 1.15;
    letter-spacing: -1px;
    margin-bottom: 16px;
}

.section-desc {
    text-align: center;
    color: var(--text-secondary);
    font-size: 16px;
    max-width: 580px;
    margin: 0 auto 56px;
}

/* ===== SCROLL REVEAL ===== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
    transition-delay: var(--delay, 0s);
    will-change: opacity, transform;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
    will-change: auto;
}

/* ===== BENEFITS GRID ===== */
.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.benefit-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 32px 28px;
    transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.benefit-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(124,58,237,0.03), transparent);
    pointer-events: none;
}

.benefit-card:hover {
    border-color: rgba(124, 58, 237, 0.3);
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(124, 58, 237, 0.1);
}

.benefit-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.benefit-icon-purple { background: rgba(124, 58, 237, 0.12); color: var(--purple-glow); }
.benefit-icon-cyan { background: rgba(34, 211, 238, 0.12); color: var(--cyan-glow); }
.benefit-icon-emerald { background: rgba(16, 185, 129, 0.12); color: var(--emerald); }
.benefit-icon-orange { background: rgba(245, 158, 11, 0.12); color: var(--orange); }

.benefit-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--text-primary);
}

.benefit-text {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 20px;
    flex-grow: 1;
}

.benefit-text strong {
    color: var(--text-primary);
}

.benefit-metric {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
    margin-top: auto;
}

.metric-number {
    font-size: 28px;
    font-weight: 800;
    background: var(--gradient-text);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
    display: block;
}

.metric-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-muted);
    line-height: 1.4;
    display: block;
}

/* ===== AUTOMATION FLOW DIAGRAM ===== */
.automation-flow {
    background: var(--bg-section);
    padding: 120px 0;
    position: relative;
    overflow: hidden;
}

.section-subtitle {
    text-align: center;
    font-size: 16px;
    color: var(--text-secondary);
    margin-top: -16px;
    margin-bottom: 64px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.flow-diagram {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin: 64px auto;
    max-width: 1200px;
    padding: 48px 24px;
    position: relative;
}

.flow-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
    padding: 24px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    min-width: 140px;
    position: relative;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    animation: fadeInUp 0.6s ease-out backwards;
    animation-delay: calc(var(--step, 0) * 0.1s);
}

.flow-node[data-step="1"] { --step: 1; }
.flow-node[data-step="2"] { --step: 2; }
.flow-node[data-step="3"] { --step: 3; }
.flow-node[data-step="4"] { --step: 4; }
.flow-node[data-step="5"] { --step: 5; }
.flow-node[data-step="6"] { --step: 6; }

.flow-node:hover {
    transform: translateY(-8px);
    border-color: var(--purple);
    box-shadow: 0 12px 40px rgba(124, 58, 237, 0.25);
}

.flow-node-final {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.1), rgba(6, 182, 212, 0.1));
    border-color: var(--purple);
    box-shadow: 0 0 30px rgba(124, 58, 237, 0.3);
}

.node-icon {
    width: 64px;
    height: 64px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.15), rgba(6, 182, 212, 0.15));
    border: 1px solid rgba(124, 58, 237, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.flow-node:hover .node-icon {
    transform: scale(1.1);
    box-shadow: 0 0 20px rgba(124, 58, 237, 0.5);
}

.node-icon svg {
    color: var(--cyan);
}

.flow-node h4 {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

.flow-node p {
    font-size: 12px;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.4;
}

.flow-arrow {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 -8px;
}

.flow-arrow svg {
    display: block;
}

.flow-particle {
    position: absolute;
    width: 8px;
    height: 8px;
    background: var(--cyan);
    border-radius: 50%;
    box-shadow: 0 0 12px var(--cyan);
    animation: flowParticle 2.5s ease-in-out infinite;
    opacity: 0;
}

@keyframes flowParticle {
    0% {
        left: 0;
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        left: 100%;
        opacity: 0;
    }
}

.flow-stats {
    display: flex;
    justify-content: center;
    gap: 64px;
    margin: 64px auto 48px;
    flex-wrap: wrap;
}

.flow-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.stat-value {
    font-size: 36px;
    font-weight: 800;
    background: var(--gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
}

.stat-label {
    font-size: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.steps-cta {
    text-align: center;
}

/* ===== AI CAPABILITIES SECTION ===== */
.ai-capabilities-section {
    padding: 120px 0;
    background: linear-gradient(180deg, rgba(124, 58, 237, 0.03) 0%, transparent 100%);
}

.capabilities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 32px;
    margin-top: 64px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.capability-card {
    background: rgba(17, 24, 39, 0.5);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 40px 32px;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.capability-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--gradient-text);
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.capability-card:hover::before {
    transform: scaleX(1);
}

.capability-card:hover {
    transform: translateY(-8px);
    border-color: rgba(124, 58, 237, 0.5);
    box-shadow:
        0 20px 40px rgba(0, 0, 0, 0.4),
        0 0 40px rgba(124, 58, 237, 0.2);
}

.capability-icon {
    font-size: 48px;
    margin-bottom: 20px;
    display: inline-block;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.capability-stat {
    font-size: 48px;
    font-weight: 900;
    margin-bottom: 12px;
    display: block;
    line-height: 1;
}

.capability-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.capability-desc {
    font-size: 14px;
    line-height: 1.6;
    color: var(--text-secondary);
    margin: 0;
}

@media (max-width: 1024px) {
    .flow-diagram {
        flex-wrap: wrap;
        gap: 32px;
        justify-content: center;
    }

    .flow-arrow {
        display: none;
    }

    .flow-node {
        min-width: 160px;
    }
}

@media (max-width: 640px) {
    .flow-node {
        min-width: 130px;
        padding: 20px 16px;
    }

    .node-icon {
        width: 56px;
        height: 56px;
    }

    .node-icon svg {
        width: 28px;
        height: 28px;
    }

    .flow-stats {
        gap: 32px;
    }

    .stat-value {
        font-size: 28px;
    }

    .capabilities-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .capability-card {
        padding: 32px 24px;
    }

    .capability-stat {
        font-size: 40px;
    }

    .capability-icon {
        font-size: 40px;
    }
}

/* ===== DEMO SECTION ===== */
.demo-layout {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 40px;
    align-items: stretch;
}

.chat-container {
    position: relative;
}

.chat-window {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 24px 60px rgba(0,0,0,0.4);
}

.chat-head {
    display: flex;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    background: rgba(255,255,255,0.02);
}

.chat-avatar-wrap {
    margin-right: 12px;
    position: relative;
}

.chat-avatar-main {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.chat-avatar-letter {
    font-size: 16px;
    font-weight: 800;
    color: #fff;
}

.chat-avatar-pulse {
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    border: 2px solid var(--purple);
    animation: avatar-pulse 2.5s ease infinite;
}

@keyframes avatar-pulse {
    0% { transform: scale(1); opacity: 0.6; }
    100% { transform: scale(1.3); opacity: 0; }
}

.chat-head-info {
    flex: 1;
}

.chat-head-name {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.chat-head-status {
    font-size: 12px;
    color: var(--text-muted);
}

.online-dot {
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--emerald);
    margin-right: 4px;
    box-shadow: 0 0 6px var(--emerald);
}

.chat-head-actions {
    display: flex;
    gap: 6px;
}

.chat-action-btn {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: rgba(255,255,255,0.04);
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    transition: background 0.2s;
}

.chat-action-btn:hover {
    background: rgba(255,255,255,0.1);
}

.chat-action-btn:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 2px;
}

.chat-messages {
    padding: 20px;
    min-height: 320px;
    max-height: 420px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.chat-messages::-webkit-scrollbar {
    width: 4px;
}

.chat-messages::-webkit-scrollbar-track {
    background: transparent;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 2px;
}

.chat-msg {
    display: flex;
    gap: 10px;
    animation: msg-appear 0.4s ease;
}

@keyframes msg-appear {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.chat-msg.ai {
    align-self: flex-start;
}

.chat-msg.user {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.msg-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    flex-shrink: 0;
}

.msg-avatar.ai {
    background: var(--gradient);
    color: #fff;
}

.msg-avatar.user {
    background: rgba(124, 58, 237, 0.15);
    color: var(--purple-glow);
}

.msg-bubble {
    max-width: 280px;
    padding: 12px 16px;
    border-radius: 14px;
    font-size: 14px;
    line-height: 1.6;
}

.msg-bubble.ai {
    background: rgba(255,255,255,0.05);
    color: var(--text-primary);
    border-radius: 14px 14px 14px 4px;
}

.msg-bubble.user {
    background: var(--gradient);
    color: #fff;
    border-radius: 14px 14px 4px 14px;
}

.msg-bubble strong {
    color: var(--cyan-glow);
}

/* Chat footer */
.chat-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--border);
}

.typing-wrap {
    display: none;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.typing-wrap.active {
    display: flex;
}

.typing-dots {
    display: flex;
    gap: 4px;
    align-items: center;
}

.typing-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--text-muted);
    animation: typing-bounce 1.4s ease infinite;
}

.typing-dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes typing-bounce {
    0%, 60%, 100% { transform: translateY(0); }
    30% { transform: translateY(-5px); }
}

.typing-label {
    font-size: 12px;
    color: var(--text-muted);
    font-style: italic;
}

.chat-input-wrap {
    display: flex;
    gap: 8px;
    align-items: center;
}

.chat-input {
    flex: 1;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 10px 16px;
    color: var(--text-muted);
    font-size: 13px;
    outline: none;
    font-family: inherit;
}

.chat-send {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: rgba(124, 58, 237, 0.15);
    border: none;
    color: var(--purple-glow);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.chat-send:hover {
    background: rgba(124, 58, 237, 0.3);
}

.chat-send:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 2px;
}

.chat-input:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 2px;
}

.chat-disclaimer {
    font-size: 11px;
    color: var(--text-muted);
    text-align: center;
    margin-top: 10px;
}

/* ===== DEMO PANEL ===== */
.demo-panel {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 28px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.demo-panel-header {
    margin-bottom: 24px;
}

.demo-live-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--emerald);
    margin-bottom: 10px;
}

.live-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--emerald);
    box-shadow: 0 0 8px var(--emerald);
    animation: pulse-dot 1.5s ease infinite;
}

.demo-panel-header h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
}

.demo-features {
    display: flex;
    flex-direction: column;
    gap: 14px;
    flex: 1;
}

.demo-feat {
    display: flex;
    gap: 14px;
    align-items: center;
    padding: 16px;
    border-radius: 12px;
    background: rgba(255,255,255,0.02);
    border: 1px solid transparent;
    transition: all 0.4s ease;
    height: 80px;
}

.demo-feat.active {
    background: rgba(124, 58, 237, 0.08);
    border-color: rgba(124, 58, 237, 0.2);
    box-shadow: 0 4px 20px rgba(124, 58, 237, 0.1);
}

.feat-check {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    flex-shrink: 0;
    transition: all 0.4s ease;
}

.demo-feat.active .feat-check {
    background: var(--emerald);
    color: #fff;
    box-shadow: 0 0 12px rgba(16, 185, 129, 0.4);
}

.feat-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
    min-height: 0;
}

.feat-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
    transition: color 0.3s;
}

.demo-feat.active .feat-title {
    color: var(--text-primary);
}

.feat-desc {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* ===== PROOF BAR ===== */
.proof-bar {
    padding: 48px 0;
    background: rgba(255,255,255,0.015);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.proof-grid {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0;
    flex-wrap: wrap;
}

.proof-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 0 40px;
}

.proof-num {
    font-size: 28px;
    font-weight: 800;
    background: var(--gradient-text);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.proof-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-muted);
}

.proof-divider {
    width: 1px;
    height: 40px;
    background: var(--border);
}

/* ===== FINAL CTA ===== */
.final-cta {
    padding: 120px 0;
    position: relative;
    overflow: hidden;
}

.cta-bg-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    pointer-events: none;
}

.cta-orb-1 {
    width: 400px;
    height: 400px;
    background: var(--purple);
    opacity: 0.12;
    top: -100px;
    left: -100px;
}

.cta-orb-2 {
    width: 350px;
    height: 350px;
    background: var(--cyan);
    opacity: 0.08;
    bottom: -80px;
    right: -80px;
}

/* CTA two-column layout */
.cta-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 2;
    max-width: 1060px;
    margin: 0 auto;
}

.cta-copy {
    text-align: left;
}

.cta-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.2);
    padding: 6px 18px;
    border-radius: 50px;
    font-size: 13px;
    color: var(--emerald);
    font-weight: 500;
    margin-bottom: 28px;
}

.cta-pill-dot {
    background: var(--emerald);
    box-shadow: 0 0 6px var(--emerald);
}

.cta-heading {
    font-size: clamp(32px, 4.5vw, 46px);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -1px;
    margin-bottom: 18px;
}

.cta-desc {
    font-size: 15px;
    color: var(--text-secondary);
    margin-bottom: 32px;
    line-height: 1.7;
}

.cta-trust-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.cta-trust-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: var(--text-secondary);
}

.cta-trust-check {
    color: var(--emerald);
    font-weight: 700;
    font-size: 13px;
}

/* CTA Form */
.cta-form-wrap {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 36px 32px;
    box-shadow: 0 24px 60px rgba(0,0,0,0.3);
}

.cta-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-label {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--text-muted);
}

.form-input {
    padding: 12px 16px;
    border-radius: 10px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    color: var(--text-primary);
    font-size: 14px;
    font-family: inherit;
    outline: none;
    transition: border-color 0.2s, background 0.2s;
    appearance: none;
    -webkit-appearance: none;
}

.form-input::placeholder {
    color: var(--text-muted);
}

.form-input:focus {
    border-color: var(--purple);
    background: rgba(124, 58, 237, 0.04);
    outline: none;
}

.form-input:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 2px;
}

.form-select {
    background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L6 6L11 1' stroke='%23555570' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 40px;
    cursor: pointer;
}

.form-select option {
    background: var(--bg-card);
    color: var(--text-primary);
}

.form-textarea {
    resize: none;
    min-height: 80px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.cta-submit {
    width: 100%;
    justify-content: center;
    padding: 15px 28px;
    font-size: 15px;
    margin-top: 4px;
}

.cta-guarantee {
    font-size: 11px;
    color: var(--text-muted);
    text-align: center;
}

.guarantee-icon {
    margin-right: 4px;
}

/* ===== FOOTER ===== */
.footer {
    padding: 60px 0 40px;
    border-top: 1px solid var(--border);
}

.footer-minimal {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px 48px;
    margin-bottom: 40px;
    align-items: start;
}

.footer-brand {
    grid-column: 1;
}

.footer-address-wrap {
    grid-column: 2;
}

.footer-logo {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-logo .logo-img {
    width: 32px;
    height: 32px;
}

.footer-tagline {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.7;
    margin: 0;
}


.footer-email {
    font-size: 15px;
    color: var(--text-primary);
    text-decoration: none;
    padding: 12px 24px;
    border: 1px solid var(--border);
    border-radius: 8px;
    transition: all 0.3s ease;
    background: rgba(124, 58, 237, 0.05);
}

.footer-email:hover {
    border-color: var(--purple-glow);
    background: rgba(124, 58, 237, 0.1);
    color: var(--purple-glow);
}

.footer-address {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.6;
    text-align: right;
    margin: 0;
    font-style: normal;
}

.footer-social {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    align-items: center;
    margin: 0;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: rgba(124, 58, 237, 0.1);
    border: 1px solid var(--border);
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.social-link:hover {
    background: rgba(124, 58, 237, 0.2);
    border-color: var(--purple-glow);
    color: var(--purple-glow);
    transform: translateY(-2px);
}

.social-link:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 2px;
}

.footer-bottom {
    border-top: 1px solid var(--border);
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-bottom p {
    font-size: 13px;
    color: var(--text-muted);
    margin: 0;
}

.footer-bottom .footer-social {
    margin: 0;
}

/* ===== MODAL ===== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(8px);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
}

.modal-overlay.active {
    display: flex;
}

.modal-box {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 48px 40px 40px;
    text-align: center;
    max-width: 460px;
    width: 90%;
    position: relative;
    animation: modal-pop 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes modal-pop {
    from { transform: scale(0.85); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(255,255,255,0.06);
    border: none;
    color: var(--text-muted);
    width: 30px;
    height: 30px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.modal-close:hover {
    background: rgba(255,255,255,0.12);
}

.modal-close:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 2px;
}

.modal-icon {
    font-size: 48px;
    margin-bottom: 20px;
}

.modal-title {
    font-size: 24px;
    font-weight: 800;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.modal-text {
    font-size: 15px;
    color: var(--text-secondary);
    margin-bottom: 28px;
    line-height: 1.6;
}

.modal-box .btn {
    width: 100%;
    justify-content: center;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
    .demo-layout {
        grid-template-columns: 1fr;
    }

    .cta-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .steps {
        flex-direction: column;
        align-items: center;
        gap: 16px;
    }

    .step-connector {
        width: 1px;
        height: 40px;
        flex: none;
        margin: 0;
        align-self: center;
    }

    .step-connector::after {
        width: 1px;
        height: 100%;
        background: linear-gradient(to bottom, var(--purple), var(--cyan));
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 680px) {
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 260px;
        height: 100vh;
        background: var(--bg-card);
        flex-direction: column;
        padding: 80px 32px 32px;
        gap: 20px;
        align-items: flex-start;
        border-left: 1px solid var(--border);
        transition: right 0.3s ease;
        z-index: 999;
    }

    .nav-links.open {
        right: 0;
    }

    .hamburger {
        display: flex;
        z-index: 1001;
    }

    .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .benefits-grid {
        grid-template-columns: 1fr;
    }

    .proof-grid {
        flex-direction: column;
        gap: 24px;
    }

    .proof-divider {
        width: 40px;
        height: 1px;
    }

    .footer-minimal {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .footer-brand {
        grid-column: 1;
    }

    .footer-address-wrap {
        grid-column: 1;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }

    .footer-bottom .footer-social {
        justify-content: center;
    }

    .benefits, .how-it-works, .demo-section {
        padding: 80px 0;
    }

    .cta-layout {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .cta-copy {
        text-align: center;
    }

    .cta-trust-list {
        align-items: center;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .cta-form-wrap {
        padding: 28px 20px;
    }
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--bg-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 3px;
}

/* ===== VOICE TEST SECTION ===== */
.voice-test-section {
    padding: 120px 0 140px;
    background: linear-gradient(180deg, var(--bg-dark) 0%, rgba(124, 58, 237, 0.02) 50%, var(--bg-dark) 100%);
    position: relative;
}

.voice-control-panel {
    max-width: 600px;
    margin: 48px auto 0;
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 48px 40px;
    position: relative;
}

.voice-panel-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
}

/* Siri-like Orb Display */
.siri-orb-container {
    position: relative;
    width: 280px;
    height: 280px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.siri-orb {
    position: relative;
    width: 200px;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(124, 58, 237, 0.15), rgba(34, 211, 238, 0.1), transparent);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.siri-orb.active {
    background: radial-gradient(circle, rgba(124, 58, 237, 0.3), rgba(34, 211, 238, 0.2), transparent);
    box-shadow: 0 0 60px rgba(124, 58, 237, 0.4), 0 0 120px rgba(34, 211, 238, 0.3);
}

.orb-wave {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    opacity: 0;
    transition: all 0.3s ease;
}

.siri-orb.active .orb-wave {
    opacity: 1;
    animation: orbWave 3s ease-in-out infinite;
}

.orb-wave:nth-child(1) {
    background: radial-gradient(circle, rgba(167, 139, 250, 0.4), transparent 50%);
    animation-delay: 0s;
}

.orb-wave:nth-child(2) {
    background: radial-gradient(circle, rgba(103, 232, 249, 0.3), transparent 50%);
    animation-delay: 0.6s;
}

.orb-wave:nth-child(3) {
    background: radial-gradient(circle, rgba(124, 58, 237, 0.35), transparent 50%);
    animation-delay: 1.2s;
}

.orb-wave:nth-child(4) {
    background: radial-gradient(circle, rgba(34, 211, 238, 0.25), transparent 50%);
    animation-delay: 1.8s;
}

.orb-wave:nth-child(5) {
    background: radial-gradient(circle, rgba(167, 139, 250, 0.3), transparent 50%);
    animation-delay: 2.4s;
}

@keyframes orbWave {
    0%, 100% {
        transform: scale(0.8);
        opacity: 0;
    }
    50% {
        transform: scale(1.2);
        opacity: 0.6;
    }
}

.siri-orb.speaking .orb-wave {
    animation: orbSpeaking 0.8s ease-in-out infinite;
}

@keyframes orbSpeaking {
    0%, 100% {
        transform: scale(0.9);
        opacity: 0.3;
    }
    25% {
        transform: scale(1.1);
        opacity: 0.7;
    }
    50% {
        transform: scale(0.95);
        opacity: 0.5;
    }
    75% {
        transform: scale(1.05);
        opacity: 0.6;
    }
}

/* Voice Status Info */
.voice-status-info {
    text-align: center;
    margin: 32px 0 24px;
}

.voice-status-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.voice-status-desc {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Voice Buttons Container */
.voice-buttons {
    display: flex;
    gap: 16px;
    align-items: center;
    justify-content: center;
    margin-top: 24px;
}

/* Main Voice Button - Siri Style */
.btn-voice-main {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--purple), var(--cyan));
    border: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow:
        0 10px 40px rgba(124, 58, 237, 0.3),
        0 0 0 0 rgba(124, 58, 237, 0);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    position: relative;
}

.btn-voice-main:hover {
    transform: scale(1.05);
    box-shadow:
        0 15px 50px rgba(124, 58, 237, 0.4),
        0 0 60px rgba(34, 211, 238, 0.3);
}

.btn-voice-main:active {
    transform: scale(0.95);
}

.btn-voice-main.active {
    animation: buttonPulse 2s ease-in-out infinite;
}

@keyframes buttonPulse {
    0%, 100% {
        box-shadow:
            0 10px 40px rgba(124, 58, 237, 0.4),
            0 0 0 0 rgba(124, 58, 237, 0.3);
    }
    50% {
        box-shadow:
            0 15px 50px rgba(124, 58, 237, 0.6),
            0 0 80px rgba(34, 211, 238, 0.4),
            0 0 0 20px rgba(124, 58, 237, 0);
    }
}

.voice-btn-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.voice-btn-icon svg {
    width: 32px;
    height: 32px;
}

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

    .animate-in {
        opacity: 1;
        transform: none;
        animation: none;
    }

    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .btn-glow {
        animation: none;
    }

    .gradient-text {
        animation: none;
    }

    .pill-dot,
    .live-dot,
    .online-dot {
        animation: none;
    }

    .chat-avatar-pulse {
        animation: none;
    }

    .flow-particle {
        display: none;
    }

    .capability-icon {
        animation: none;
    }

    .scroll-line {
        animation: none;
    }

    .typing-dot {
        animation: none;
    }
}

@media (max-width: 768px) {
    .voice-test-section {
        padding: 80px 0 100px;
    }

    .voice-control-panel {
        padding: 36px 24px;
    }

    .siri-orb-container {
        width: 220px;
        height: 220px;
    }

    .siri-orb {
        width: 160px;
        height: 160px;
    }

    .voice-status-title {
        font-size: 24px;
    }

    .voice-status-desc {
        font-size: 15px;
    }

    .btn-voice-main {
        width: 70px;
        height: 70px;
    }

    .voice-btn-icon svg {
        width: 28px;
        height: 28px;
    }
}
