/* ChatNord — landing page styles
   Mobile-first, no framework, WCAG-AA, performance-budget <100KB.
   ------------------------------------------------------------ */

:root {
    --primary: #0F1F3D;
    --primary-700: #0a1530;
    --accent: #00C4D9;
    --accent-700: #00a4b6;
    --bg: #ffffff;
    --bg-alt: #F6F8FB;
    --bg-dark: #0F1F3D;
    --text: #1A2333;
    --text-muted: #6B7785;
    --border: #E4E8EF;
    --shadow-sm: 0 1px 2px rgba(15, 31, 61, 0.04), 0 1px 3px rgba(15, 31, 61, 0.06);
    --shadow-md: 0 4px 6px rgba(15, 31, 61, 0.05), 0 10px 25px rgba(15, 31, 61, 0.08);
    --shadow-lg: 0 12px 24px rgba(15, 31, 61, 0.08), 0 25px 50px rgba(15, 31, 61, 0.12);
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 20px;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-head: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --container: 1180px;
    --transition: 200ms ease;
}

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

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

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

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

a {
    color: var(--primary);
    text-decoration: none;
    transition: color var(--transition);
}

a:hover,
a:focus-visible {
    color: var(--accent-700);
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

input,
textarea,
select {
    font-family: inherit;
    font-size: inherit;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-head);
    color: var(--primary);
    line-height: 1.2;
    letter-spacing: -0.01em;
}

h1 { font-size: clamp(2rem, 5vw, 3.25rem); font-weight: 800; }
h2 { font-size: clamp(1.625rem, 3.5vw, 2.25rem); font-weight: 700; margin-bottom: 0.5rem; }
h3 { font-size: 1.25rem; font-weight: 700; }
h4 { font-size: 1.0625rem; font-weight: 600; }

p {
    color: var(--text);
}

ul {
    list-style: none;
}

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

.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: absolute;
    top: -100px;
    left: 1rem;
    background: var(--primary);
    color: #fff;
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
    z-index: 1000;
    transition: top var(--transition);
}

.skip-link:focus {
    top: 1rem;
    color: #fff;
}

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 1.25rem;
}

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

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.9375rem;
    text-decoration: none;
    transition: all var(--transition);
    border: 2px solid transparent;
    cursor: pointer;
    white-space: nowrap;
}

.btn-primary {
    background: var(--primary);
    color: #fff;
}

.btn-primary:hover,
.btn-primary:focus-visible {
    background: var(--primary-700);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--bg-alt);
    color: var(--primary);
    border-color: var(--border);
}

.btn-secondary:hover,
.btn-secondary:focus-visible {
    background: #fff;
    border-color: var(--primary);
    color: var(--primary);
}

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

.btn-outline:hover,
.btn-outline:focus-visible {
    background: var(--primary);
    color: #fff;
}

.btn-block {
    width: 100%;
}

/* ---------- Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: saturate(180%) blur(12px);
    -webkit-backdrop-filter: saturate(180%) blur(12px);
    border-bottom: 1px solid var(--border);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 0.875rem;
    padding-bottom: 0.875rem;
    gap: 1rem;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
    font-family: var(--font-head);
    font-weight: 800;
    font-size: 1.25rem;
    color: var(--primary);
    text-decoration: none;
    letter-spacing: -0.02em;
}

.logo:hover,
.logo:focus-visible {
    color: var(--primary);
}

.logo-light {
    color: #fff;
}

.main-nav ul {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.main-nav a {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--text);
}

.main-nav a:hover,
.main-nav a:focus-visible {
    color: var(--primary);
}

.nav-cta {
    background: var(--primary);
    color: #fff !important;
    padding: 0.625rem 1.125rem;
    border-radius: var(--radius-sm);
    transition: background var(--transition);
}

.nav-cta:hover,
.nav-cta:focus-visible {
    background: var(--primary-700);
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 0.5rem;
}

.menu-toggle span {
    width: 24px;
    height: 2px;
    background: var(--primary);
    border-radius: 2px;
    transition: transform var(--transition);
}

@media (max-width: 860px) {
    .main-nav { display: none; }
    .main-nav.open {
        display: block;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #fff;
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow-md);
        padding: 1rem 1.25rem;
    }
    .main-nav.open ul {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
    }
    .main-nav.open li {
        border-bottom: 1px solid var(--border);
    }
    .main-nav.open li:last-child {
        border-bottom: none;
    }
    .main-nav.open a {
        display: block;
        padding: 0.875rem 0;
    }
    .main-nav.open .nav-cta {
        margin-top: 0.5rem;
        text-align: center;
    }
    .menu-toggle { display: flex; }
}

/* ---------- Hero ---------- */
.hero {
    padding: 4rem 0 5rem;
    background:
        radial-gradient(ellipse 80% 50% at 50% -10%, rgba(0, 196, 217, 0.12), transparent 60%),
        linear-gradient(180deg, #FAFBFD 0%, #ffffff 100%);
    overflow: hidden;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    align-items: center;
}

@media (min-width: 960px) {
    .hero { padding: 6rem 0 7rem; }
    .hero-grid { grid-template-columns: 1.1fr 1fr; gap: 4rem; }
}

.eyebrow {
    display: inline-block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--accent-700);
    background: rgba(0, 196, 217, 0.12);
    padding: 0.375rem 0.875rem;
    border-radius: 999px;
    letter-spacing: 0.02em;
    margin-bottom: 1.25rem;
}

.eyebrow-light {
    color: #fff;
    background: rgba(255, 255, 255, 0.15);
}

.hero h1 {
    margin-bottom: 1.25rem;
    color: var(--primary);
}

.hero-sub {
    font-size: 1.125rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
    max-width: 540px;
}

.hero-cta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.875rem;
    margin-bottom: 2rem;
}

.hero-bullets {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    color: var(--text-muted);
    font-size: 0.9375rem;
}

.hero-bullets li::before {
    content: "✓";
    color: var(--accent);
    font-weight: 700;
    margin-right: 0.5rem;
}

/* Hero chat-mockup */
.hero-visual {
    display: flex;
    justify-content: center;
}

.chat-mockup {
    width: 100%;
    max-width: 420px;
    background: #fff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    border: 1px solid var(--border);
    transform: rotate(-1deg);
    transition: transform var(--transition);
}

.chat-mockup:hover {
    transform: rotate(0);
}

.chat-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 1.25rem;
    background: var(--primary);
    color: #fff;
}

.chat-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--accent);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.875rem;
    font-family: var(--font-head);
}

.chat-header strong {
    display: block;
    font-size: 0.9375rem;
    font-family: var(--font-head);
}

.chat-header small {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.75rem;
    opacity: 0.85;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #4ade80;
    box-shadow: 0 0 0 2px rgba(74, 222, 128, 0.3);
}

.chat-close {
    margin-left: auto;
    font-size: 1.5rem;
    line-height: 1;
    color: #fff;
    padding: 0.25rem 0.5rem;
}

.chat-body {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-height: 260px;
    max-height: 340px;
    overflow-y: auto;
    background: var(--bg-alt);
}

.msg {
    max-width: 80%;
    padding: 0.625rem 0.875rem;
    border-radius: var(--radius);
    font-size: 0.875rem;
    line-height: 1.45;
    animation: msgIn 320ms ease-out;
}

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

.msg-bot {
    background: #fff;
    color: var(--text);
    border-bottom-left-radius: 4px;
    align-self: flex-start;
    box-shadow: var(--shadow-sm);
}

.msg-user {
    background: var(--primary);
    color: #fff;
    border-bottom-right-radius: 4px;
    align-self: flex-end;
}

.msg.typing {
    display: inline-flex;
    gap: 4px;
    padding: 0.875rem;
}

.msg.typing span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--text-muted);
    animation: typing 1.2s ease-in-out infinite;
}

.msg.typing span:nth-child(2) { animation-delay: 0.15s; }
.msg.typing span:nth-child(3) { animation-delay: 0.3s; }

@keyframes typing {
    0%, 60%, 100% { opacity: 0.3; transform: translateY(0); }
    30% { opacity: 1; transform: translateY(-3px); }
}

.chat-input {
    display: flex;
    gap: 0.5rem;
    padding: 0.875rem 1rem;
    background: #fff;
    border-top: 1px solid var(--border);
}

.chat-input input {
    flex: 1;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 0.625rem 0.875rem;
    font-size: 0.875rem;
    outline: none;
    transition: border-color var(--transition);
}

.chat-input input:focus {
    border-color: var(--accent);
}

.chat-input button {
    background: var(--primary);
    border-radius: var(--radius-sm);
    padding: 0.625rem 0.875rem;
    display: flex;
    align-items: center;
    transition: background var(--transition);
}

.chat-input button:hover {
    background: var(--primary-700);
}

/* ---------- Trust bar ---------- */
.trust-bar {
    background: var(--bg-alt);
    padding: 1.75rem 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.trust-inner {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 1rem 2.5rem;
}

.trust-item {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 500;
}

.trust-item strong {
    color: var(--primary);
}

/* ---------- Sections (general) ---------- */
section {
    padding: 5rem 0;
}

@media (min-width: 768px) {
    section { padding: 6rem 0; }
}

.section-head {
    text-align: center;
    max-width: 720px;
    margin: 0 auto 3rem;
}

.section-head p {
    color: var(--text-muted);
    font-size: 1.0625rem;
    margin-top: 0.75rem;
}

.cards-grid {
    display: grid;
    gap: 1.5rem;
}

.cards-3 { grid-template-columns: 1fr; }
.cards-4 { grid-template-columns: 1fr; }

@media (min-width: 640px) {
    .cards-3 { grid-template-columns: repeat(2, 1fr); }
    .cards-4 { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 960px) {
    .cards-3 { grid-template-columns: repeat(3, 1fr); }
    .cards-4 { grid-template-columns: repeat(4, 1fr); }
}

.card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2rem 1.75rem;
    transition: transform var(--transition), box-shadow var(--transition);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.card h3 {
    margin-bottom: 0.625rem;
}

.card p {
    color: var(--text-muted);
    font-size: 0.9375rem;
}

/* ---------- Problem ---------- */
.problem {
    background: var(--bg);
}

.card-stat {
    font-family: var(--font-head);
    font-size: 2rem;
    font-weight: 800;
    color: var(--accent-700);
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
}

/* ---------- Solution ---------- */
.solution {
    background: var(--bg-alt);
}

.steps {
    display: grid;
    gap: 1.5rem;
    margin-bottom: 4rem;
    counter-reset: step;
}

@media (min-width: 768px) {
    .steps {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }
}

.step {
    background: #fff;
    border-radius: var(--radius);
    padding: 2rem;
    border: 1px solid var(--border);
    position: relative;
}

.step-number {
    width: 40px;
    height: 40px;
    background: var(--primary);
    color: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 1.125rem;
    margin-bottom: 1.25rem;
}

.step h3 {
    margin-bottom: 0.625rem;
}

.step p {
    color: var(--text-muted);
    font-size: 0.9375rem;
}

.features-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
}

@media (min-width: 640px) {
    .features-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 960px) {
    .features-grid { grid-template-columns: repeat(3, 1fr); }
}

.feature {
    padding: 1.25rem 0;
}

.feature h4 {
    margin-bottom: 0.375rem;
    color: var(--primary);
}

.feature p {
    color: var(--text-muted);
    font-size: 0.9375rem;
}

/* ---------- Verticals ---------- */
.verticals {
    background: var(--bg);
}

.card-vertical {
    text-align: left;
}

.vert-icon {
    width: 48px;
    height: 48px;
    background: rgba(0, 196, 217, 0.1);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.vert-tag {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--accent-700);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
}

.card-custom {
    border-style: dashed;
    background: var(--bg-alt);
}

/* ---------- Multilingual ---------- */
.multilingual {
    background: var(--bg-alt);
}

.multi-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    align-items: center;
}

@media (min-width: 960px) {
    .multi-grid { grid-template-columns: 1fr 1fr; }
}

.multilingual .lead {
    font-size: 1.0625rem;
    margin: 1rem 0 1.5rem;
    color: var(--text);
}

.lang-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.lang-list li {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 0.75rem;
    background: #fff;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    font-size: 0.9375rem;
}

.flag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 24px;
    border-radius: 4px;
    background: var(--primary);
    color: var(--accent);
    font-size: 0.6875rem;
    font-weight: 700;
    font-family: var(--font-head);
    letter-spacing: 0.05em;
}

.muted {
    color: var(--text-muted);
    font-size: 0.9375rem;
}

.muted.small {
    font-size: 0.8125rem;
    margin-top: 1rem;
    text-align: center;
}

.multi-visual {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.lang-card {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 1rem 1.25rem;
    background: #fff;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
    animation: slideRight 600ms ease-out backwards;
}

.lang-card:nth-child(1) { animation-delay: 100ms; }
.lang-card:nth-child(2) { animation-delay: 200ms; margin-left: 1.5rem; }
.lang-card:nth-child(3) { animation-delay: 300ms; margin-left: 3rem; }
.lang-card:nth-child(4) { animation-delay: 400ms; margin-left: 4.5rem; }

@keyframes slideRight {
    from { opacity: 0; transform: translateX(-16px); }
    to { opacity: 1; transform: translateX(0); }
}

.lang-flag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 28px;
    border-radius: 4px;
    background: var(--accent);
    color: var(--primary);
    font-size: 0.75rem;
    font-weight: 700;
    font-family: var(--font-head);
}

.lang-bubble {
    font-size: 0.9375rem;
    color: var(--text);
}

/* ---------- Pricing ---------- */
.pricing {
    background: var(--bg);
}

.pricing-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    max-width: 1100px;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .pricing-grid { grid-template-columns: repeat(3, 1fr); align-items: stretch; }
}

.price-card {
    background: #fff;
    border: 2px solid var(--border);
    border-radius: var(--radius);
    padding: 2.25rem 1.875rem;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: transform var(--transition), box-shadow var(--transition);
}

.price-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.price-featured {
    border-color: var(--primary);
    background: var(--primary);
    color: #fff;
    transform: scale(1.02);
}

.price-featured h3,
.price-featured .price-amount,
.price-featured .price-period {
    color: #fff;
}

.price-featured .price-features li {
    color: rgba(255, 255, 255, 0.9);
}

.price-featured .price-features li::before {
    color: var(--accent);
}

.price-featured .price-tag {
    color: rgba(255, 255, 255, 0.75);
}

.price-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--accent);
    color: var(--primary);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.375rem 0.875rem;
    border-radius: 999px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.price-card h3 {
    font-size: 1.375rem;
    margin-bottom: 0.5rem;
}

.price-tag {
    color: var(--text-muted);
    font-size: 0.875rem;
    margin-bottom: 1.5rem;
}

.price {
    display: flex;
    align-items: baseline;
    gap: 0.375rem;
    margin-bottom: 1.5rem;
}

.price-amount {
    font-family: var(--font-head);
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary);
    letter-spacing: -0.02em;
}

.price-period {
    font-size: 0.9375rem;
    color: var(--text-muted);
    font-weight: 500;
}

.price-features {
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
    margin-bottom: 2rem;
    flex-grow: 1;
}

.price-features li {
    display: flex;
    align-items: flex-start;
    gap: 0.625rem;
    font-size: 0.9375rem;
    color: var(--text);
}

.price-features li::before {
    content: "✓";
    color: var(--accent-700);
    font-weight: 700;
    flex-shrink: 0;
    margin-top: 1px;
}

.pricing-footnote {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.875rem;
    margin-top: 2rem;
}

/* ---------- Comparison ---------- */
.comparison {
    background: var(--bg-alt);
}

.table-wrap {
    overflow-x: auto;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.compare-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9375rem;
    min-width: 720px;
}

.compare-table th,
.compare-table td {
    padding: 1rem 1.25rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.compare-table thead th {
    background: var(--primary);
    color: #fff;
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 0.9375rem;
}

.compare-table thead th.us {
    background: var(--accent);
    color: var(--primary);
}

.compare-table tbody th {
    font-weight: 600;
    color: var(--primary);
    background: var(--bg-alt);
}

.compare-table td.us {
    background: rgba(0, 196, 217, 0.08);
    font-weight: 600;
    color: var(--primary);
}

.compare-table tbody tr:last-child th,
.compare-table tbody tr:last-child td {
    border-bottom: none;
}

/* ---------- Testimonials ---------- */
.testimonials {
    background: var(--bg);
}

.testimonial {
    background: #fff;
    padding: 2rem;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    position: relative;
}

.testimonial::before {
    content: """;
    position: absolute;
    top: -10px;
    left: 1.5rem;
    font-family: Georgia, serif;
    font-size: 4rem;
    color: var(--accent);
    line-height: 1;
}

.testimonial p {
    color: var(--text);
    font-size: 1rem;
    margin-bottom: 1.25rem;
    font-style: italic;
}

.testimonial footer {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.testimonial footer strong {
    color: var(--primary);
    font-style: normal;
}

/* ---------- FAQ ---------- */
.faq {
    background: var(--bg-alt);
}

.faq-list {
    max-width: 820px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 0.875rem;
}

.faq-item {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: box-shadow var(--transition);
}

.faq-item[open] {
    box-shadow: var(--shadow-md);
}

.faq-item summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    cursor: pointer;
    list-style: none;
    user-select: none;
    gap: 1rem;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary h3 {
    font-size: 1.0625rem;
    margin: 0;
    color: var(--primary);
    flex: 1;
    font-weight: 600;
}

.faq-toggle {
    font-size: 1.5rem;
    color: var(--accent-700);
    font-weight: 300;
    transition: transform var(--transition);
    flex-shrink: 0;
    line-height: 1;
}

.faq-item[open] .faq-toggle {
    transform: rotate(45deg);
}

.faq-answer {
    padding: 0 1.5rem 1.5rem;
    color: var(--text);
    font-size: 0.9375rem;
}

.faq-answer p {
    color: var(--text);
}

.faq-answer p + p {
    margin-top: 0.75rem;
}

/* ---------- Final CTA ---------- */
.cta-final {
    background: var(--primary);
    color: #fff;
    overflow: hidden;
    position: relative;
}

.cta-final::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 10% 90%, rgba(0, 196, 217, 0.18), transparent 40%),
        radial-gradient(circle at 90% 10%, rgba(0, 196, 217, 0.12), transparent 40%);
    pointer-events: none;
}

.cta-final h2 {
    color: #fff;
}

.cta-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    align-items: start;
    position: relative;
}

@media (min-width: 960px) {
    .cta-grid { grid-template-columns: 1.1fr 1fr; gap: 4rem; }
}

.cta-text p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.0625rem;
    margin: 0.75rem 0 1.5rem;
}

.cta-bullets {
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}

.cta-bullets li {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9375rem;
    display: flex;
    align-items: center;
    gap: 0.625rem;
}

.cta-bullets li::before {
    content: "✓";
    color: var(--accent);
    font-weight: 700;
}

/* form */
.cta-form {
    background: #fff;
    padding: 2.25rem 2rem;
    border-radius: var(--radius);
    color: var(--text);
    box-shadow: var(--shadow-lg);
}

.form-title {
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
}

.form-row {
    margin-bottom: 1.125rem;
}

.form-row label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 0.375rem;
}

.form-row input {
    width: 100%;
    padding: 0.75rem 0.875rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 0.9375rem;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.form-row input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(0, 196, 217, 0.18);
}

.form-row input[aria-invalid="true"] {
    border-color: #DC2626;
}

.form-error {
    display: block;
    font-size: 0.8125rem;
    color: #DC2626;
    margin-top: 0.375rem;
    min-height: 1em;
}

.form-disclaimer {
    color: var(--text-muted);
    font-size: 0.8125rem;
    margin-top: 1rem;
    text-align: center;
}

.form-disclaimer a {
    color: var(--accent-700);
    text-decoration: underline;
}

.form-success {
    margin-top: 1rem;
    padding: 1rem;
    background: rgba(0, 196, 217, 0.12);
    border: 1px solid var(--accent);
    border-radius: var(--radius-sm);
    color: var(--primary);
    text-align: center;
    font-size: 0.9375rem;
}

/* ---------- Footer ---------- */
.site-footer {
    background: var(--bg-dark);
    color: rgba(255, 255, 255, 0.8);
    padding: 4rem 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.5rem;
    padding-bottom: 3rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

@media (min-width: 640px) {
    .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; gap: 2rem; }
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.65);
    font-size: 0.9375rem;
    margin-top: 1rem;
    max-width: 320px;
}

.footer-col h4 {
    color: #fff;
    font-size: 0.875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1rem;
}

.footer-col ul {
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}

.footer-col a {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9375rem;
    transition: color var(--transition);
}

.footer-col a:hover,
.footer-col a:focus-visible {
    color: var(--accent);
}

.footer-bottom {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 0.5rem;
    padding-top: 2rem;
    color: rgba(255, 255, 255, 0.55);
    font-size: 0.8125rem;
}

.footer-meta {
    color: rgba(255, 255, 255, 0.5);
}

/* ---------- Chat widget (floating) ---------- */
.chat-widget {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 90;
}

.chat-widget-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
    background: var(--primary);
    color: #fff;
    padding: 0.875rem 1.25rem;
    border-radius: 999px;
    box-shadow: var(--shadow-lg);
    font-family: var(--font-head);
    font-weight: 600;
    font-size: 0.9375rem;
    transition: transform var(--transition), background var(--transition);
    animation: widgetEntry 700ms ease-out 1.4s backwards;
}

.chat-widget-toggle:hover {
    background: var(--primary-700);
    transform: translateY(-2px);
}

.chat-widget-pill {
    display: inline-block;
}

@keyframes widgetEntry {
    from { opacity: 0; transform: translateY(20px) scale(0.9); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.chat-widget-panel {
    position: absolute;
    bottom: calc(100% + 1rem);
    right: 0;
    width: min(360px, calc(100vw - 3rem));
    background: #fff;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    border: 1px solid var(--border);
    animation: panelOpen 240ms ease-out;
}

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

.chat-widget-panel .chat-body {
    min-height: 260px;
    max-height: 360px;
}

@media (max-width: 640px) {
    .chat-widget { bottom: 1rem; right: 1rem; }
    .chat-widget-pill { display: none; }
    .chat-widget-toggle { padding: 0.875rem; }
}

/* v6.1: floating FAB stays visible on all viewports — Mammon handles z-index + sticky-fix. */

/* ---------- Modal ---------- */
.modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: modalFadeIn 0.28s ease-out;
}

.modal[hidden] {
    display: none;
}

@keyframes modalFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes modalContentIn {
    from { opacity: 0; transform: translateY(12px) scale(0.98); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 31, 61, 0.78);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    cursor: pointer;
}

.modal-content {
    position: relative;
    background: #fff;
    border-radius: var(--radius);
    padding: 2rem;
    max-width: 720px;
    width: calc(100% - 2rem);
    box-shadow: var(--shadow-lg);
    animation: modalContentIn 0.32s cubic-bezier(.2,.9,.3,1.05);
}

.modal-close {
    position: absolute;
    top: 0.75rem;
    right: 1rem;
    font-size: 1.75rem;
    line-height: 1;
    color: var(--text-muted);
    padding: 0.5rem;
    z-index: 2;
}

.video-placeholder {
    background: var(--bg-alt);
    aspect-ratio: 16 / 9;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-size: 0.9375rem;
}

/* ---------- 60-sek demo modal (3-scenario chat-loop) ---------- */
.demo-modal .modal-content {
    max-width: 880px;
    width: calc(100% - 2rem);
    padding: 1.25rem 1.25rem 1.5rem;
    background: linear-gradient(180deg, #f7f9fc 0%, #eef2f8 100%);
    border-radius: 16px;
}

.demo-modal .modal-close {
    background: rgba(255,255,255,0.94);
    border: 1px solid #e5e8ed;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    top: 0.75rem;
    right: 0.75rem;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    font-size: 1.4rem;
}

.demo-modal .modal-close:hover {
    background: #fff;
    color: var(--text);
}

.demo-modal-head {
    text-align: center;
    margin: 0.25rem 0 1rem;
}

.demo-modal-eyebrow {
    display: inline-block;
    background: rgba(0,196,217,0.12);
    color: #008595;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    margin-bottom: 0.5rem;
}

.demo-modal-title {
    font-family: var(--font-display);
    font-size: 1.35rem;
    color: var(--text);
    margin: 0 0 0.25rem;
    line-height: 1.25;
}

.demo-modal-sub {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin: 0;
}

.demo-modal-stage {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 28px rgba(15,31,61,0.10);
    border: 1px solid #e5e8ed;
    position: relative;
    height: 440px;
}

.demo-modal-scenarios {
    position: relative;
    height: 100%;
}

.demo-scenario {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    opacity: 0;
    animation-duration: 60s;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
}

/* 3 scenarios x 20s each in a 60s loop */
.demo-scenario-1 { animation-name: scenarioFade1; }
.demo-scenario-2 { animation-name: scenarioFade2; }
.demo-scenario-3 { animation-name: scenarioFade3; }

@keyframes scenarioFade1 {
    0%, 1%    { opacity: 0; }
    2%, 31%   { opacity: 1; }
    33%, 100% { opacity: 0; }
}
@keyframes scenarioFade2 {
    0%, 33%   { opacity: 0; }
    35%, 64%  { opacity: 1; }
    66%, 100% { opacity: 0; }
}
@keyframes scenarioFade3 {
    0%, 66%   { opacity: 0; }
    68%, 97%  { opacity: 1; }
    99%, 100% { opacity: 0; }
}

.demo-scenario-head {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #eef0f4;
    background: #fff;
}

.demo-scenario-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgba(0,196,217,0.14);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #008595;
    flex-shrink: 0;
}

.demo-scenario-titles {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.demo-scenario-titles strong {
    font-size: 0.95rem;
    color: var(--text);
}

.demo-scenario-titles small {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.demo-scenario-counter {
    margin-left: auto;
    font-size: 0.72rem;
    color: var(--text-muted);
    font-variant-numeric: tabular-nums;
}

.demo-scenario-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    padding: 1.25rem;
    background: var(--bg-alt);
    overflow: hidden;
}

.demo-scenario-body .loop-msg {
    font-size: 0.95rem;
    line-height: 1.5;
    max-width: 78%;
    padding: 0.7rem 1rem;
}

/* Per-scenario message-step timings. Each scenario = 20s.
   Same fade-pattern as hero chat-loop, stretched to 20s. */
.demo-scenario .ds-step-1 { animation: dsStep1 20s linear infinite; }
.demo-scenario .ds-step-2 { animation: dsStep2 20s linear infinite; }
.demo-scenario .ds-step-3 { animation: dsStep3 20s linear infinite; }
.demo-scenario .ds-step-4 { animation: dsStep4 20s linear infinite; }
.demo-scenario .ds-step-5 { animation: dsStep5 20s linear infinite; }
.demo-scenario .ds-step-6 { animation: dsStep6 20s linear infinite; }

@keyframes dsStep1 {
    0%        { opacity: 0; transform: translateY(8px); }
    3%        { opacity: 1; transform: translateY(0); }
    88%       { opacity: 1; transform: translateY(0); }
    93%, 100% { opacity: 0; transform: translateY(0); }
}
@keyframes dsStep2 {
    0%, 6%    { opacity: 0; transform: translateY(8px); }
    10%       { opacity: 1; transform: translateY(0); }
    16%       { opacity: 1; transform: translateY(0); }
    18%, 100% { opacity: 0; transform: translateY(0); }
}
@keyframes dsStep3 {
    0%, 16%   { opacity: 0; transform: translateY(8px); }
    20%       { opacity: 1; transform: translateY(0); }
    88%       { opacity: 1; transform: translateY(0); }
    93%, 100% { opacity: 0; transform: translateY(0); }
}
@keyframes dsStep4 {
    0%, 36%   { opacity: 0; transform: translateY(8px); }
    40%       { opacity: 1; transform: translateY(0); }
    88%       { opacity: 1; transform: translateY(0); }
    93%, 100% { opacity: 0; transform: translateY(0); }
}
@keyframes dsStep5 {
    0%, 46%   { opacity: 0; transform: translateY(8px); }
    50%       { opacity: 1; transform: translateY(0); }
    56%       { opacity: 1; transform: translateY(0); }
    58%, 100% { opacity: 0; transform: translateY(0); }
}
@keyframes dsStep6 {
    0%, 56%   { opacity: 0; transform: translateY(8px); }
    60%       { opacity: 1; transform: translateY(0); }
    88%       { opacity: 1; transform: translateY(0); }
    93%, 100% { opacity: 0; transform: translateY(0); }
}

.demo-scenario-foot {
    padding: 0.6rem 1rem 0.9rem;
    border-top: 1px solid #eef0f4;
    background: #fff;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.demo-scenario-foot .ds-input {
    flex: 1;
    background: var(--bg-alt);
    border-radius: 999px;
    padding: 0.55rem 0.875rem;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.demo-scenario-foot .ds-send {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    flex-shrink: 0;
}

.demo-modal-progress {
    display: flex;
    gap: 0.4rem;
    justify-content: center;
    margin-top: 0.9rem;
}

.demo-modal-progress span {
    display: block;
    width: 28px;
    height: 4px;
    border-radius: 999px;
    background: rgba(15,31,61,0.14);
    overflow: hidden;
    position: relative;
}

.demo-modal-progress span::after {
    content: "";
    position: absolute;
    inset: 0;
    background: var(--accent);
    transform: translateX(-100%);
    animation-duration: 60s;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
}

.demo-modal-progress span:nth-child(1)::after { animation-name: progressFill1; }
.demo-modal-progress span:nth-child(2)::after { animation-name: progressFill2; }
.demo-modal-progress span:nth-child(3)::after { animation-name: progressFill3; }

@keyframes progressFill1 {
    0%        { transform: translateX(-100%); }
    33%       { transform: translateX(0); }
    34%, 100% { transform: translateX(0); opacity: 0.35; }
}
@keyframes progressFill2 {
    0%, 33%   { transform: translateX(-100%); opacity: 1; }
    66%       { transform: translateX(0); }
    67%, 100% { transform: translateX(0); opacity: 0.35; }
}
@keyframes progressFill3 {
    0%, 66%   { transform: translateX(-100%); opacity: 1; }
    99.9%     { transform: translateX(0); }
    100%      { transform: translateX(0); }
}

/* Body lock while modal open */
body.modal-open {
    overflow: hidden;
}

/* Mobile: full-screen modal */
@media (max-width: 720px) {
    .demo-modal {
        align-items: stretch;
        justify-content: stretch;
    }
    .demo-modal .modal-content {
        max-width: 100%;
        width: 100%;
        height: 100%;
        max-height: 100vh;
        border-radius: 0;
        padding: 1rem 0.875rem 1rem;
        display: flex;
        flex-direction: column;
    }
    .demo-modal-stage {
        flex: 1;
        height: auto;
        min-height: 0;
    }
    .demo-modal-head {
        margin: 0.5rem 0 0.875rem;
    }
    .demo-modal-title {
        font-size: 1.1rem;
    }
    .demo-modal-sub {
        font-size: 0.8rem;
    }
    .demo-scenario-body {
        padding: 1rem;
    }
    .demo-scenario-body .loop-msg {
        font-size: 0.875rem;
        padding: 0.6rem 0.85rem;
    }
}

@media (max-width: 480px) {
    .demo-scenario-head {
        padding: 0.6rem 0.75rem;
    }
    .demo-scenario-icon {
        width: 28px;
        height: 28px;
    }
    .demo-scenario-titles strong {
        font-size: 0.85rem;
    }
    .demo-scenario-titles small {
        font-size: 0.7rem;
    }
    .demo-scenario-body .loop-msg {
        font-size: 0.82rem;
        max-width: 85%;
    }
}

/* Reduced motion: kill rotation, show scenario 1 statically */
@media (prefers-reduced-motion: reduce) {
    .demo-scenario,
    .demo-scenario .ds-step-1, .demo-scenario .ds-step-2,
    .demo-scenario .ds-step-3, .demo-scenario .ds-step-4,
    .demo-scenario .ds-step-5, .demo-scenario .ds-step-6,
    .demo-modal-progress span::after,
    .modal,
    .modal-content {
        animation: none !important;
    }
    .demo-scenario { opacity: 0 !important; }
    .demo-scenario-1 { opacity: 1 !important; }
    .demo-scenario-1 .loop-msg { opacity: 1 !important; transform: none !important; }
}

/* ---------- Misc ---------- */
@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;
    }
}


/* Deployment timeline cards */
.step-card {
    background: white;
    border-radius: 12px;
    padding: 28px 24px;
    border: 1px solid #e5e8ed;
    transition: transform 0.2s, box-shadow 0.2s;
}
.step-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(15, 31, 61, 0.08);
}
.step-num {
    display: inline-block;
    background: #00C4D9;
    color: #0F1F3D;
    padding: 4px 12px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 13px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    margin-bottom: 16px;
}
.step-card h3 {
    margin: 0 0 12px;
    color: #0F1F3D;
    font-size: 19px;
}
.step-card p {
    margin: 0;
    color: #6B7785;
    line-height: 1.6;
}

/* ============================================================
   v5 UPGRADES
   ============================================================ */

/* ---------- 1. Animated hero chat-loop ---------- */
/* Total loop = 12s. Each step appears, holds, then resets.
   Steps sequence (with cumulative time):
     0.0s   step1 customer-bubble fades in
     1.0s   step2 typing-dots fade in
     2.5s   step2 fades out, step3 ai-bubble fades in
     4.5s   step4 customer-bubble fades in
     5.5s   step5 typing-dots fade in
     6.5s   step5 fades out, step6 ai-bubble fades in
     10.0s  hold (read time)
     11.0s  fade everything out
     12.0s  loop restarts                                       */

.chat-mockup-animated {
    transform: rotate(-1deg);
}
.chat-mockup-animated:hover {
    transform: rotate(0);
}

.chat-loop {
    position: relative;
    min-height: 320px;
    max-height: 360px;
    overflow: hidden;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    background: var(--bg-alt);
}

.loop-msg {
    max-width: 80%;
    padding: 0.625rem 0.875rem;
    border-radius: var(--radius);
    font-size: 0.875rem;
    line-height: 1.45;
    opacity: 0;
    transform: translateY(8px);
    animation-fill-mode: both;
    will-change: opacity, transform;
}

.loop-bot {
    background: #fff;
    color: var(--text);
    border-bottom-left-radius: 4px;
    align-self: flex-start;
    box-shadow: var(--shadow-sm);
}

.loop-user {
    background: var(--primary);
    color: #fff;
    border-bottom-right-radius: 4px;
    align-self: flex-end;
}

.loop-typing {
    background: #fff;
    align-self: flex-start;
    border-bottom-left-radius: 4px;
    box-shadow: var(--shadow-sm);
    display: inline-flex;
    gap: 4px;
    padding: 0.875rem 1rem;
    max-width: max-content;
}

.loop-typing span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--text-muted);
    display: inline-block;
}

/* Step-keyframes — shared 20s per-scenario clock (v6.2).
   Each scenario shows for 20s within a 60s 3-scenario cycle.
   Within its own 20s window, the message-sequence plays:
     0.0s  step1 customer-bubble fades in        ( 0%)
     1.6s  step2 typing-dots fade in             ( 8%)
     4.2s  step3 ai-bubble fades in, step2 out   (21%)
     7.6s  step4 customer-bubble fades in        (38%)
     9.2s  step5 typing-dots fade in             (46%)
    10.8s  step6 ai-bubble fades in, step5 out   (54%)
   10.8s-16.6s hold (read-time)
    16.6s  fade everything                       (83%)
    20.0s  reset → loop restarts                (100%)             */

.hero-step-1 { animation: heroStep1 20s linear infinite; }
.hero-step-2 { animation: heroStep2 20s linear infinite; }
.hero-step-3 { animation: heroStep3 20s linear infinite; }
.hero-step-4 { animation: heroStep4 20s linear infinite; }
.hero-step-5 { animation: heroStep5 20s linear infinite; }
.hero-step-6 { animation: heroStep6 20s linear infinite; }

@keyframes heroStep1 {
    0%   { opacity: 0; transform: translateY(8px); }
    4%   { opacity: 1; transform: translateY(0); }
    83%  { opacity: 1; transform: translateY(0); }
    88%  { opacity: 0; transform: translateY(0); }
    100% { opacity: 0; transform: translateY(0); }
}
@keyframes heroStep2 {
    0%, 8%   { opacity: 0; transform: translateY(8px); }
    12%      { opacity: 1; transform: translateY(0); }
    20%      { opacity: 1; transform: translateY(0); }
    21%, 100%{ opacity: 0; transform: translateY(0); }
}
@keyframes heroStep3 {
    0%, 20%  { opacity: 0; transform: translateY(8px); }
    24%      { opacity: 1; transform: translateY(0); }
    83%      { opacity: 1; transform: translateY(0); }
    88%, 100%{ opacity: 0; transform: translateY(0); }
}
@keyframes heroStep4 {
    0%, 36%  { opacity: 0; transform: translateY(8px); }
    40%      { opacity: 1; transform: translateY(0); }
    83%      { opacity: 1; transform: translateY(0); }
    88%, 100%{ opacity: 0; transform: translateY(0); }
}
@keyframes heroStep5 {
    0%, 44%  { opacity: 0; transform: translateY(8px); }
    48%      { opacity: 1; transform: translateY(0); }
    53%      { opacity: 1; transform: translateY(0); }
    54%, 100%{ opacity: 0; transform: translateY(0); }
}
@keyframes heroStep6 {
    0%, 53%  { opacity: 0; transform: translateY(8px); }
    57%      { opacity: 1; transform: translateY(0); }
    83%      { opacity: 1; transform: translateY(0); }
    88%, 100%{ opacity: 0; transform: translateY(0); }
}

/* Typing-dots are only animated while their bubble is visible.
   Approximate visible-window via animation-delay + paused fallback. */
.loop-typing span {
    animation: typing 1.2s ease-in-out infinite;
}
.loop-typing span:nth-child(2) { animation-delay: 0.15s; }
.loop-typing span:nth-child(3) { animation-delay: 0.3s; }

/* ---------- 2. Stats section with counter ---------- */
.stats {
    background: var(--bg);
    padding: 3rem 0;
}

@media (min-width: 768px) {
    .stats { padding: 4rem 0; }
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    max-width: 1100px;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 1.5rem;
    }
}

.stat-card {
    background: linear-gradient(160deg, #ffffff 0%, #F6F8FB 100%);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.75rem 1.25rem;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), box-shadow var(--transition);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent), var(--primary));
    opacity: 0.85;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.stat-number {
    font-family: var(--font-head);
    font-size: clamp(2.75rem, 6vw, 4.5rem);
    font-weight: 800;
    color: var(--primary);
    line-height: 1;
    letter-spacing: -0.03em;
    margin-bottom: 0.625rem;
}

.stat-label {
    color: var(--text-muted);
    font-size: 0.9375rem;
    font-weight: 500;
    line-height: 1.4;
}

/* ---------- 3. Glass-morphism pricing-cards ---------- */
.pricing {
    background:
        radial-gradient(ellipse 60% 40% at 50% 0%, rgba(0, 196, 217, 0.08), transparent 60%),
        linear-gradient(180deg, #FAFBFD 0%, #ffffff 100%);
}

.glass-card {
    background: rgba(255, 255, 255, 0.65);
    backdrop-filter: blur(14px) saturate(140%);
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow:
        0 1px 2px rgba(15, 31, 61, 0.04),
        0 10px 30px rgba(15, 31, 61, 0.06);
    position: relative;
    transition: transform 280ms ease, box-shadow 280ms ease, border-color 280ms ease;
}

.glass-card::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, rgba(0, 196, 217, 0.25), rgba(15, 31, 61, 0.08));
    -webkit-mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    mask-composite: exclude;
    pointer-events: none;
    opacity: 0.65;
}

.glass-card:hover {
    transform: translateY(-6px);
    box-shadow:
        0 4px 8px rgba(15, 31, 61, 0.06),
        0 24px 50px rgba(15, 31, 61, 0.14);
    border-color: rgba(0, 196, 217, 0.35);
}

/* Override featured-card to keep premium look but glassy */
.glass-card.price-featured {
    background: linear-gradient(160deg, #0F1F3D 0%, #1a2f5a 100%);
    color: #fff;
    transform: scale(1.03);
    border: 1px solid rgba(0, 196, 217, 0.5);
    box-shadow:
        0 4px 12px rgba(15, 31, 61, 0.12),
        0 20px 48px rgba(15, 31, 61, 0.22),
        0 0 0 4px rgba(0, 196, 217, 0.06);
}

.glass-card.price-featured:hover {
    transform: scale(1.03) translateY(-6px);
    box-shadow:
        0 4px 12px rgba(15, 31, 61, 0.12),
        0 32px 64px rgba(15, 31, 61, 0.28),
        0 0 0 4px rgba(0, 196, 217, 0.12);
}

.glass-card.price-featured::after {
    background: linear-gradient(135deg, rgba(0, 196, 217, 0.6), rgba(0, 196, 217, 0.1));
    opacity: 1;
}

/* Pricing currency superscript */
.price-currency {
    font-family: var(--font-head);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-muted);
    margin-left: 0.25rem;
    align-self: flex-start;
    margin-top: 0.4rem;
}

.price-featured .price-currency {
    color: rgba(255, 255, 255, 0.85);
}

.price {
    align-items: flex-start;
}

/* Bigger price-amount on glass-cards */
.glass-card .price-amount {
    font-size: clamp(2.75rem, 5vw, 3.5rem);
}

/* ---------- 4. Sticky bottom-CTA ---------- */
.sticky-cta {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 95;
    transform: translateY(100%);
    transition: transform 380ms cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
}

.sticky-cta[hidden] {
    display: none;
}

.sticky-cta.is-visible {
    transform: translateY(0);
    pointer-events: auto;
}

.sticky-cta-inner {
    display: flex;
    align-items: center;
    gap: 1rem;
    max-width: var(--container);
    margin: 0 auto 1rem;
    padding: 0.875rem 1.25rem;
    background: linear-gradient(135deg, #0F1F3D 0%, #1a2f5a 100%);
    border: 1px solid rgba(0, 196, 217, 0.3);
    border-radius: var(--radius);
    box-shadow:
        0 10px 30px rgba(15, 31, 61, 0.25),
        0 0 0 1px rgba(255, 255, 255, 0.04) inset;
    color: #fff;
}

.sticky-cta-text {
    color: #fff;
    font-family: var(--font-head);
    font-weight: 600;
    font-size: 0.9375rem;
    flex: 1;
    margin: 0;
    line-height: 1.3;
}

.sticky-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    background: var(--accent);
    color: var(--primary);
    padding: 0.625rem 1.125rem;
    border-radius: var(--radius-sm);
    font-family: var(--font-head);
    font-weight: 700;
    font-size: 0.9375rem;
    text-decoration: none;
    white-space: nowrap;
    transition: background var(--transition), transform var(--transition);
}

.sticky-cta-btn:hover,
.sticky-cta-btn:focus-visible {
    background: #1ad6ea;
    color: var(--primary);
    transform: translateY(-1px);
}

.sticky-cta-close {
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.5rem;
    line-height: 1;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    transition: color var(--transition), background var(--transition);
}

.sticky-cta-close:hover,
.sticky-cta-close:focus-visible {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

@media (max-width: 640px) {
    .sticky-cta-inner {
        margin: 0;
        border-radius: 0;
        border-left: none;
        border-right: none;
        border-bottom: none;
        padding: 0.75rem 1rem;
        gap: 0.625rem;
    }
    .sticky-cta-text {
        font-size: 0.875rem;
    }
    .sticky-cta-btn {
        padding: 0.5rem 0.875rem;
        font-size: 0.8125rem;
    }
}

/* Lift floating chat-widget above sticky-cta when both visible */
.sticky-cta.is-visible ~ .chat-widget {
    bottom: 5.5rem;
}

@media (max-width: 640px) {
    .sticky-cta.is-visible ~ .chat-widget {
        bottom: 4.5rem;
    }
}

/* ---------- Reduced motion respect ---------- */
@media (prefers-reduced-motion: reduce) {
    .hero-step-1, .hero-step-2, .hero-step-3,
    .hero-step-4, .hero-step-5, .hero-step-6 {
        animation: none !important;
    }
    .loop-typing span { animation: none !important; }
    .sticky-cta {
        transition: none !important;
    }
}

/* ============================================================
   v6 UPGRADES — Cinematic browser-mockup demo
   ============================================================ */

/* ---------- Demo stage (background + container) ---------- */
.demo-stage {
    position: relative;
    width: 100%;
    max-width: 560px;
    margin: 0 auto;
    isolation: isolate;
}

.demo-bg {
    position: absolute;
    inset: -8% -10%;
    z-index: 0;
    border-radius: 32px;
    overflow: hidden;
    background:
        radial-gradient(ellipse 60% 55% at 25% 30%, rgba(0, 196, 217, 0.22), transparent 70%),
        radial-gradient(ellipse 55% 50% at 80% 70%, rgba(15, 31, 61, 0.55), transparent 70%),
        linear-gradient(135deg, #0F1F3D 0%, #142a55 60%, #0a3a4a 100%);
    filter: blur(28px) saturate(120%);
    opacity: 0.65;
    animation: demoBgShift 18s ease-in-out infinite alternate;
}

@keyframes demoBgShift {
    0%   { background-position: 0% 0%, 100% 100%, 0% 0%; transform: scale(1); }
    100% { background-position: 30% 20%, 70% 80%, 100% 100%; transform: scale(1.05); }
}

.demo-particle {
    position: absolute;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(0, 196, 217, 0.55);
    box-shadow: 0 0 12px rgba(0, 196, 217, 0.7);
    opacity: 0.4;
    z-index: 0;
    pointer-events: none;
    animation: particleFloat 14s ease-in-out infinite;
}

.demo-particle.p1 { top: 12%; left: 8%;  animation-delay: 0s;   }
.demo-particle.p2 { top: 78%; left: 14%; animation-delay: 3s; width: 4px; height: 4px; }
.demo-particle.p3 { top: 22%; left: 88%; animation-delay: 6s; width: 5px; height: 5px; }
.demo-particle.p4 { top: 65%; left: 92%; animation-delay: 9s; }
.demo-particle.p5 { top: 48%; left: 50%; animation-delay: 4.5s; width: 3px; height: 3px; opacity: 0.3; }

@keyframes particleFloat {
    0%, 100% { transform: translate3d(0, 0, 0); opacity: 0.25; }
    50%      { transform: translate3d(8px, -12px, 0); opacity: 0.55; }
}

/* ---------- Browser frame ---------- */
.browser-frame {
    position: relative;
    z-index: 1;
    width: 100%;
    background: #ffffff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow:
        0 1px 2px rgba(15, 31, 61, 0.10),
        0 12px 28px rgba(15, 31, 61, 0.18),
        0 32px 80px rgba(15, 31, 61, 0.28);
    border: 1px solid rgba(15, 31, 61, 0.12);
    transform: perspective(1200px) rotateX(2deg) rotateY(-1deg);
    transition: transform 400ms ease;
}

.browser-frame:hover {
    transform: perspective(1200px) rotateX(0deg) rotateY(0deg);
}

.browser-bar {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.5rem 0.75rem;
    background: linear-gradient(180deg, #ECEEF3 0%, #DDE1E8 100%);
    border-bottom: 1px solid rgba(15, 31, 61, 0.12);
    min-height: 36px;
}

.browser-lights {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.bl {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.08);
}

.bl-red    { background: #ff5f57; }
.bl-yellow { background: #febc2e; }
.bl-green  { background: #28c840; }

.browser-tabs {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    margin-left: 0.5rem;
    flex-shrink: 1;
    min-width: 0;
}

.browser-tab {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.7rem;
    background: #ffffff;
    border-radius: 8px 8px 0 0;
    font-size: 0.72rem;
    color: #1A2333;
    border: 1px solid rgba(15, 31, 61, 0.10);
    border-bottom: none;
    margin-bottom: -1px;
    max-width: 180px;
    overflow: hidden;
}

.browser-tab .tab-title {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
}

.browser-tab.active {
    background: #ffffff;
    color: var(--primary);
}

.tab-icon {
    flex-shrink: 0;
}

.browser-url {
    flex: 1;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.3rem 0.75rem;
    background: #ffffff;
    border-radius: 6px;
    font-size: 0.75rem;
    color: var(--text-muted);
    border: 1px solid rgba(15, 31, 61, 0.08);
    margin-left: 0.5rem;
    min-width: 0;
    max-width: 60%;
}

.browser-url span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: var(--font-body);
}

.url-lock {
    flex-shrink: 0;
}

.browser-actions {
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 3px;
    margin-left: auto;
    padding: 0.25rem 0.5rem;
    flex-shrink: 0;
}

.ba-dot {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #6B7785;
}

/* ---------- Browser viewport (the fake company-site) ---------- */
.browser-viewport {
    position: relative;
    background: #fdfdfd;
    aspect-ratio: 4 / 3.1;
    min-height: 420px;
    overflow: hidden;
}

.fake-site {
    position: absolute;
    inset: 0;
    padding: 0;
    overflow: hidden;
    animation: fakeScroll 20s ease-in-out infinite;
}

@keyframes fakeScroll {
    0%, 30%    { transform: translateY(0); }
    55%, 85%   { transform: translateY(-18px); }
    100%       { transform: translateY(0); }
}

.fake-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.875rem 1.25rem;
    border-bottom: 1px solid #EFF1F5;
    background: #ffffff;
}

.fake-logo {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.fake-logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 5px;
    background: #8B1A1A;
    color: #fff;
    font-family: var(--font-head);
    font-size: 0.7rem;
    font-weight: 800;
}

.fake-logo-text {
    font-family: Georgia, 'Times New Roman', serif;
    font-style: italic;
    font-size: 0.95rem;
    color: #2B2B2B;
    font-weight: 600;
}

.fake-nav-links {
    display: inline-flex;
    align-items: center;
    gap: 0.875rem;
    font-size: 0.7rem;
    color: #5a5a5a;
}

.fake-nav-cta {
    background: #8B1A1A;
    color: #fff;
    padding: 0.25rem 0.625rem;
    border-radius: 4px;
}

.fake-hero {
    padding: 1.25rem 1.5rem 1rem;
    background: linear-gradient(135deg, #FAF5EE 0%, #F4ECDD 100%);
}

.fake-eyebrow {
    font-size: 0.65rem;
    color: #8B1A1A;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.fake-h1 {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1.05rem;
    font-weight: 700;
    color: #2B2B2B;
    line-height: 1.3;
    margin-bottom: 0.75rem;
    max-width: 70%;
}

.fake-sub-lines {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 0.875rem;
}

.fake-line {
    height: 6px;
    background: linear-gradient(90deg, #E2D9C8 0%, #EDE5D4 100%);
    border-radius: 3px;
}

.fake-line.w90 { width: 90%; }
.fake-line.w80 { width: 80%; }
.fake-line.w75 { width: 75%; }
.fake-line.w70 { width: 70%; }
.fake-line.w60 { width: 60%; }
.fake-line.w50 { width: 50%; }

.fake-btn-row {
    display: inline-flex;
    gap: 0.5rem;
}

.fake-btn {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.75rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
}

.fake-btn-primary {
    background: #8B1A1A;
    color: #fff;
}

.fake-btn-outline {
    background: transparent;
    border: 1px solid #8B1A1A;
    color: #8B1A1A;
}

.fake-content {
    padding: 1rem 1.5rem 1.5rem;
    background: #ffffff;
}

.fake-card-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
}

.fake-mini-card {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 0.625rem;
    background: #F8F6F1;
    border-radius: 6px;
    border: 1px solid #EDE5D4;
}

.fake-mini-title {
    height: 8px;
    width: 60%;
    background: #8B1A1A;
    border-radius: 2px;
    opacity: 0.7;
    margin-bottom: 2px;
}

/* ---------- Chat-mockup positioned inside viewport (bottom-right) ---------- */
.browser-viewport .chat-mockup {
    position: absolute;
    bottom: 12px;
    right: 12px;
    width: min(280px, 70%);
    max-width: 280px;
    transform: none;
    border-radius: 12px;
    z-index: 5;
    box-shadow:
        0 4px 12px rgba(15, 31, 61, 0.15),
        0 16px 40px rgba(15, 31, 61, 0.25);
    animation: widgetPop 700ms cubic-bezier(0.16, 1, 0.3, 1) 0.4s backwards;
}

.browser-viewport .chat-mockup:hover {
    transform: none;
}

@keyframes widgetPop {
    from { opacity: 0; transform: translateY(20px) scale(0.92); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

.browser-viewport .chat-header {
    padding: 0.625rem 0.875rem;
    gap: 0.5rem;
}

.browser-viewport .chat-avatar {
    width: 28px;
    height: 28px;
    font-size: 0.7rem;
}

.browser-viewport .chat-header strong {
    font-size: 0.8rem;
}

.browser-viewport .chat-header small {
    font-size: 0.65rem;
}

.browser-viewport .chat-loop {
    min-height: 180px;
    max-height: 200px;
    padding: 0.75rem;
    gap: 0.4rem;
}

.browser-viewport .loop-msg {
    font-size: 0.72rem;
    padding: 0.45rem 0.65rem;
    line-height: 1.35;
}

.browser-viewport .loop-typing {
    padding: 0.6rem 0.75rem;
}

.browser-viewport .chat-input {
    padding: 0.5rem 0.625rem;
}

.browser-viewport .chat-input input {
    padding: 0.4rem 0.625rem;
    font-size: 0.72rem;
}

.browser-viewport .chat-input button {
    padding: 0.4rem 0.625rem;
}

.loop-cta {
    display: inline-block;
    background: var(--accent);
    color: var(--primary);
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.7rem;
    margin-left: 4px;
    position: relative;
}

/* ---------- Simulated cursor ---------- */
.demo-cursor {
    position: absolute;
    z-index: 10;
    width: 20px;
    height: 22px;
    top: 0;
    left: 0;
    pointer-events: none;
    /* v6.2: 60s clock — 3 scenarios x 20s. Within each 20s slot the cursor
       moves from idle → chat-input → CTA button, clicking each. Resets
       between scenarios (the chat-widget visually fades anyway). */
    animation: cursorPath 60s cubic-bezier(0.4, 0, 0.2, 1) infinite;
    will-change: transform;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.35));
}

@keyframes cursorPath {
    /* Scenario A — 0–33% */
    0%   { transform: translate3d(120px, 90px, 0); }
    4%   { transform: translate3d(140px, 110px, 0); }
    7%   { transform: translate3d(330px, 240px, 0); }
    8.3% { transform: translate3d(360px, 280px, 0); }
    10%  { transform: translate3d(340px, 360px, 0); }
    17%  { transform: translate3d(345px, 365px, 0); }
    22%  { transform: translate3d(345px, 365px, 0); }
    24%  { transform: translate3d(395px, 335px, 0); }
    26%  { transform: translate3d(395px, 335px, 0); }
    30%  { transform: translate3d(220px, 200px, 0); }
    33%  { transform: translate3d(120px, 90px, 0); }
    /* Scenario B — 33–66% */
    37%  { transform: translate3d(140px, 110px, 0); }
    40%  { transform: translate3d(330px, 240px, 0); }
    41.3%{ transform: translate3d(360px, 280px, 0); }
    43%  { transform: translate3d(340px, 360px, 0); }
    50%  { transform: translate3d(345px, 365px, 0); }
    55%  { transform: translate3d(345px, 365px, 0); }
    57%  { transform: translate3d(395px, 335px, 0); }
    59%  { transform: translate3d(395px, 335px, 0); }
    63%  { transform: translate3d(220px, 200px, 0); }
    66%  { transform: translate3d(120px, 90px, 0); }
    /* Scenario C — 66–100% */
    70%  { transform: translate3d(140px, 110px, 0); }
    73%  { transform: translate3d(330px, 240px, 0); }
    74.3%{ transform: translate3d(360px, 280px, 0); }
    76%  { transform: translate3d(340px, 360px, 0); }
    83%  { transform: translate3d(345px, 365px, 0); }
    88%  { transform: translate3d(345px, 365px, 0); }
    90%  { transform: translate3d(395px, 335px, 0); }
    92%  { transform: translate3d(395px, 335px, 0); }
    96%  { transform: translate3d(220px, 200px, 0); }
    100% { transform: translate3d(120px, 90px, 0); }
}

.cursor-pulse {
    position: absolute;
    top: 0;
    left: 0;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid rgba(0, 196, 217, 0.85);
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.4);
    animation: cursorClick 60s ease-out infinite;
    will-change: opacity, transform;
}

@keyframes cursorClick {
    /* Scenario A clicks */
    0%, 7.3%   { opacity: 0; transform: translate(-50%, -50%) scale(0.4); }
    8.3%       { opacity: 0.9; transform: translate(-50%, -50%) scale(0.6); }
    10.6%      { opacity: 0; transform: translate(-50%, -50%) scale(1.8); }
    11%, 24.3% { opacity: 0; transform: translate(-50%, -50%) scale(0.4); }
    25.3%      { opacity: 0.9; transform: translate(-50%, -50%) scale(0.6); }
    27.3%      { opacity: 0; transform: translate(-50%, -50%) scale(1.8); }
    /* Scenario B clicks */
    28%, 40.3% { opacity: 0; transform: translate(-50%, -50%) scale(0.4); }
    41.3%      { opacity: 0.9; transform: translate(-50%, -50%) scale(0.6); }
    43.6%      { opacity: 0; transform: translate(-50%, -50%) scale(1.8); }
    44%, 57.3% { opacity: 0; transform: translate(-50%, -50%) scale(0.4); }
    58.3%      { opacity: 0.9; transform: translate(-50%, -50%) scale(0.6); }
    60.3%      { opacity: 0; transform: translate(-50%, -50%) scale(1.8); }
    /* Scenario C clicks */
    61%, 73.3% { opacity: 0; transform: translate(-50%, -50%) scale(0.4); }
    74.3%      { opacity: 0.9; transform: translate(-50%, -50%) scale(0.6); }
    76.6%      { opacity: 0; transform: translate(-50%, -50%) scale(1.8); }
    77%, 90.3% { opacity: 0; transform: translate(-50%, -50%) scale(0.4); }
    91.3%      { opacity: 0.9; transform: translate(-50%, -50%) scale(0.6); }
    93.6%      { opacity: 0; transform: translate(-50%, -50%) scale(1.8); }
    94%, 100%  { opacity: 0; transform: translate(-50%, -50%) scale(0.4); }
}

/* ============================================================
   v6.2 — Hero browser-frame: 3 rotating scenarios (60s cycle)
   ============================================================ */

/* Stacked scenarios fill the viewport; only one is visible per slot. */
.hero-scenario {
    position: absolute;
    inset: 0;
    opacity: 0;
    animation: heroScenarioFadeA 60s linear infinite;
    will-change: opacity;
}

/* Each scenario contains its own .fake-site + .chat-mockup; both need to
   anchor to the scenario's box (not the outer viewport). */
.hero-scenario .fake-site {
    position: absolute;
    inset: 0;
}

.hero-scenario .chat-mockup {
    position: absolute;
    bottom: 12px;
    right: 12px;
    width: min(280px, 70%);
    max-width: 280px;
    border-radius: 12px;
    z-index: 5;
    box-shadow:
        0 4px 12px rgba(15, 31, 61, 0.15),
        0 16px 40px rgba(15, 31, 61, 0.25);
    transform: rotate(-1deg);
    animation: widgetPop 700ms cubic-bezier(0.16, 1, 0.3, 1) backwards;
}
.hero-scenario .chat-mockup:hover {
    transform: rotate(0);
}

.hero-scenario-a { animation-name: heroScenarioFadeA; }
.hero-scenario-b { animation-name: heroScenarioFadeB; }
.hero-scenario-c { animation-name: heroScenarioFadeC; }

@keyframes heroScenarioFadeA {
    0%, 1%    { opacity: 0; }
    2%, 31%   { opacity: 1; }
    33%, 100% { opacity: 0; }
}
@keyframes heroScenarioFadeB {
    0%, 33%   { opacity: 0; }
    35%, 64%  { opacity: 1; }
    66%, 100% { opacity: 0; }
}
@keyframes heroScenarioFadeC {
    0%, 66%   { opacity: 0; }
    68%, 97%  { opacity: 1; }
    99%, 100% { opacity: 0; }
}

/* Browser-bar URL + tab cycle synced to the 60s scenario clock. */
.hero-url, .hero-tab {
    opacity: 0;
    animation-duration: 60s;
    animation-timing-function: linear;
    animation-iteration-count: infinite;
    animation-fill-mode: both;
}
.hero-url-a, .hero-tab-a { animation-name: heroScenarioFadeA; }
.hero-url-b, .hero-tab-b { animation-name: heroScenarioFadeB; }
.hero-url-c, .hero-tab-c { animation-name: heroScenarioFadeC; }

/* Stack URL spans so only one occupies the bar at a time. */
.browser-url {
    position: relative;
    min-height: 18px;
    min-width: 140px;
}
.browser-url .hero-url {
    position: absolute;
    left: 1.85rem;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: var(--font-body);
}

/* Stack tabs the same way. */
.browser-tabs {
    position: relative;
    min-width: 160px;
    height: 28px;
}
.browser-tabs .hero-tab {
    position: absolute;
    left: 0;
    top: 0;
}

/* ---------- Scenario A: Bilverkstad Pulsen (red-orange + steel) ---------- */
.fake-site-auto .fake-nav-auto {
    background: #ffffff;
    border-bottom: 1px solid #E5E8EE;
}
.fake-logo-mark-auto {
    background: #C0392B;
    font-family: var(--font-head);
}
.fake-logo-text-auto {
    font-family: var(--font-head);
    font-style: normal;
    color: #1A1F2A;
    letter-spacing: -0.01em;
}
.fake-nav-cta-auto {
    background: #C0392B;
    color: #fff;
}
.fake-hero-auto {
    background: linear-gradient(135deg, #F4F6F9 0%, #E6EBF1 100%);
}
.fake-eyebrow-auto {
    color: #C0392B;
}
.fake-h1-auto {
    font-family: var(--font-head);
    font-style: normal;
    color: #1A1F2A;
}
.fake-line-auto {
    background: linear-gradient(90deg, #D2D8E0 0%, #DDE3EB 100%);
}
.fake-btn-auto-primary {
    background: #C0392B;
    color: #fff;
}
.fake-btn-auto-outline {
    background: transparent;
    border: 1px solid #C0392B;
    color: #C0392B;
}
.fake-mini-card-auto {
    background: #F4F6F9;
    border: 1px solid #E1E6EE;
}
.fake-mini-title-auto {
    background: #C0392B;
}

/* ---------- Scenario C: NordicStyle Shop (black + cream + product cards) ---------- */
.fake-site-shop .fake-nav-shop {
    background: #ffffff;
    border-bottom: 1px solid #ECECEC;
}
.fake-logo-mark-shop {
    background: #111;
    font-family: var(--font-head);
}
.fake-logo-text-shop {
    font-family: var(--font-head);
    font-style: normal;
    color: #111;
    letter-spacing: -0.01em;
    font-weight: 700;
}
.fake-nav-cta-shop {
    background: #111;
    color: #fff;
}
.fake-hero-shop {
    background: linear-gradient(135deg, #FAF7F2 0%, #F0EBE2 100%);
}
.fake-eyebrow-shop {
    color: #6B5A3E;
}
.fake-h1-shop {
    font-family: var(--font-head);
    font-style: normal;
    color: #111;
}
.fake-line-shop {
    background: linear-gradient(90deg, #E8E3DA 0%, #F0EBE2 100%);
}
.fake-btn-shop-primary {
    background: #111;
    color: #fff;
}
.fake-btn-shop-outline {
    background: transparent;
    border: 1px solid #111;
    color: #111;
}
.fake-mini-card-shop {
    background: #FAFAFA;
    border: 1px solid #ECECEC;
    padding: 0.5rem;
}
.fake-shop-thumb {
    display: block;
    width: 100%;
    height: 32px;
    background: linear-gradient(135deg, #D9D2C5 0%, #EAE3D4 100%);
    border-radius: 4px;
    margin-bottom: 4px;
}
.fake-shop-price {
    font-size: 0.65rem;
    font-weight: 700;
    color: #111;
    margin-top: 2px;
}

/* ---------- Responsive: mobile simplification ---------- */
@media (max-width: 720px) {
    .demo-stage {
        max-width: 100%;
    }
    .browser-frame {
        transform: none;
        border-radius: 10px;
    }
    .browser-frame:hover {
        transform: none;
    }
    .browser-lights {
        display: none;
    }
    .browser-tabs {
        display: none;
    }
    .browser-url {
        max-width: 100%;
        margin-left: 0;
        font-size: 0.7rem;
        min-height: 22px;
    }
    .browser-url .hero-url {
        left: 1.6rem;
        right: 0.5rem;
    }
    /* v6.2: mobile — only show scenario A's content area decoration tweaks
       (all 3 scenarios still cycle, just simplified) */
    .browser-viewport .hero-scenario .chat-mockup {
        width: calc(100% - 24px);
        max-width: 260px;
        right: 12px;
        left: auto;
        box-sizing: border-box;
    }
    .browser-actions {
        padding: 0.25rem 0.25rem;
    }
    .browser-viewport {
        min-height: 360px;
        aspect-ratio: 4 / 3.4;
    }
    /* v6.1: prevent embedded chat-widget overflow on mobile */
    .browser-viewport .chat-mockup {
        width: calc(100% - 24px);
        max-width: 260px;
        right: 12px;
        left: auto;
        box-sizing: border-box;
    }
    .browser-viewport .chat-mockup * {
        box-sizing: border-box;
    }
    .browser-viewport .chat-input {
        padding: 0.45rem 0.5rem;
        gap: 0.35rem;
    }
    .browser-viewport .chat-input input {
        min-width: 0;
        padding: 0.4rem 0.5rem;
        font-size: 0.7rem;
    }
    .browser-viewport .chat-input button {
        padding: 0.35rem 0.5rem;
        flex-shrink: 0;
    }
    .browser-viewport .loop-msg {
        max-width: 92%;
        word-wrap: break-word;
        overflow-wrap: break-word;
        font-size: 0.72rem;
        padding: 0.45rem 0.6rem;
    }
    /* Tighter chat-loop body height on mobile so the widget doesn't blow up
       vertically and overflow the browser-frame. */
    .browser-viewport .chat-loop {
        min-height: 175px;
        max-height: 195px;
        padding: 0.7rem;
        gap: 0.4rem;
    }
    .browser-viewport .chat-header {
        padding: 0.55rem 0.7rem;
    }
    .demo-cursor {
        display: none;
    }
    .demo-particle {
        display: none;
    }
    .demo-bg {
        filter: blur(16px);
        opacity: 0.4;
    }
    .fake-h1 {
        max-width: 85%;
        font-size: 0.95rem;
    }
    /* v6.1: keep Casanova fake CTAs readable */
    .fake-btn { font-size: 0.68rem; padding: 0.35rem 0.7rem; }
    .browser-frame { margin-left: 0; margin-right: 0; }
}

@media (max-width: 480px) {
    .browser-viewport {
        min-height: 320px;
    }
    /* v6.1: scale embedded widget on small screens */
    .browser-viewport .chat-mockup {
        width: calc(100% - 20px);
        max-width: 230px;
        right: 10px;
        transform: scale(0.92);
        transform-origin: bottom right;
    }
    .browser-viewport .chat-mockup:hover {
        transform: scale(0.92);
    }
    .browser-viewport .chat-loop {
        min-height: 150px;
        max-height: 170px;
        padding: 0.6rem;
    }
    .browser-viewport .chat-header {
        padding: 0.5rem 0.625rem;
        gap: 0.4rem;
    }
    .browser-viewport .chat-input {
        padding: 0.4rem 0.45rem;
        gap: 0.3rem;
    }
    .browser-viewport .chat-input input {
        padding: 0.35rem 0.45rem;
        font-size: 0.68rem;
    }
    .browser-viewport .chat-input button {
        padding: 0.3rem 0.45rem;
    }
    .browser-viewport .chat-input button svg {
        width: 14px;
        height: 14px;
    }
    .browser-viewport .loop-msg {
        font-size: 0.68rem;
        padding: 0.4rem 0.55rem;
    }
    .fake-nav-links span:nth-child(1),
    .fake-nav-links span:nth-child(3) {
        display: none;
    }
    .fake-card-row {
        grid-template-columns: repeat(2, 1fr);
    }
    .fake-mini-card:nth-child(3) {
        display: none;
    }
}

/* v6.1: extra-small phones (~360px) */
@media (max-width: 380px) {
    .browser-viewport .chat-mockup {
        max-width: 210px;
        transform: scale(0.85);
        transform-origin: bottom right;
    }
    .browser-viewport .chat-mockup:hover {
        transform: scale(0.85);
    }
    .browser-viewport {
        min-height: 300px;
    }
    .fake-h1 {
        font-size: 0.85rem;
        max-width: 95%;
    }
}

/* ---------- Reduced-motion: kill all v6/v6.2 animations ---------- */
@media (prefers-reduced-motion: reduce) {
    .demo-bg,
    .demo-particle,
    .fake-site,
    .browser-viewport .chat-mockup,
    .demo-cursor,
    .cursor-pulse,
    .hero-scenario,
    .hero-url,
    .hero-tab,
    .hero-step-1, .hero-step-2, .hero-step-3,
    .hero-step-4, .hero-step-5, .hero-step-6 {
        animation: none !important;
    }
    /* Freeze on scenario A — hide B and C completely. */
    .hero-scenario { opacity: 0 !important; }
    .hero-scenario-a { opacity: 1 !important; }
    .hero-url, .hero-tab { opacity: 0 !important; }
    .hero-url-a, .hero-tab-a { opacity: 1 !important; }
    /* Show scenario A's full final-state message-thread (skip typing-dots). */
    .hero-scenario-a .hero-step-1,
    .hero-scenario-a .hero-step-3,
    .hero-scenario-a .hero-step-4,
    .hero-scenario-a .hero-step-6 {
        opacity: 1 !important;
        transform: none !important;
    }
    .hero-scenario-a .hero-step-2,
    .hero-scenario-a .hero-step-5 {
        display: none !important;
    }
    .demo-cursor {
        transform: translate3d(120px, 90px, 0) !important;
    }
    .browser-frame {
        transform: none !important;
    }
}
