/* ============================================
   KWICKBLOCKS.AI - Design System
   Modern, AI-Focused Dark Theme
   ============================================ */

/* --- Custom Properties --- */
:root {
    --kb-bg-primary: #030712;
    --kb-bg-secondary: #0f172a;
    --kb-bg-surface: #1e293b;
    --kb-bg-card: rgba(15, 23, 42, 0.5);

    --kb-border: rgba(148, 163, 184, 0.08);
    --kb-border-hover: rgba(148, 163, 184, 0.15);

    --kb-text-primary: #f8fafc;
    --kb-text-secondary: #cbd5e1;
    --kb-text-muted: #7c8aa1;

    --kb-accent-indigo: #3498db;
    --kb-accent-violet: #2dd4bf;
    --kb-accent-cyan: #06b6d4;
    --kb-accent-blue: #2980b9;
    --kb-accent-emerald: #10b981;

    --kb-gradient-primary: linear-gradient(135deg, #3498db, #2dd4bf);
    --kb-gradient-secondary: linear-gradient(135deg, #3498db, #06b6d4);
    --kb-gradient-accent: linear-gradient(135deg, #2dd4bf, #06b6d4);
    --kb-gradient-hero: linear-gradient(135deg, #3498db, #2dd4bf, #06b6d4);

    --kb-font-heading: 'Space Grotesk', system-ui, sans-serif;
    --kb-font-body: 'Inter', system-ui, sans-serif;
    --kb-font-mono: 'JetBrains Mono', ui-monospace, monospace;

    --kb-section-padding: 120px;
    --kb-container-width: 1200px;
    --kb-container-padding: 24px;

    --kb-radius-sm: 8px;
    --kb-radius-md: 12px;
    --kb-radius-lg: 16px;
    --kb-radius-xl: 24px;
    --kb-radius-full: 9999px;

    --kb-transition-fast: 150ms ease;
    --kb-transition-base: 300ms ease;
    --kb-transition-slow: 500ms ease;

    --kb-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --kb-shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --kb-shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    --kb-shadow-glow-indigo: 0 0 40px rgba(52, 152, 219, 0.15);
    --kb-shadow-glow-cyan: 0 0 40px rgba(6, 182, 212, 0.15);

    --kb-font-size-display: clamp(56px, 8vw, 120px);
    --kb-font-size-headline: clamp(40px, 6vw, 80px);
}

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

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

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

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

a {
    color: inherit;
    text-decoration: none;
    transition: color var(--kb-transition-fast);
}

ul, ol {
    list-style: none;
}

input, button, textarea {
    font-family: inherit;
    font-size: inherit;
    border: none;
    outline: none;
    background: none;
    color: inherit;
}

::selection {
    background: rgba(52, 152, 219, 0.3);
    color: var(--kb-text-primary);
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--kb-font-heading);
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

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

.gradient-text-animated {
    background: linear-gradient(270deg, #3498db, #2dd4bf, #06b6d4, #3498db);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 6s ease infinite;
}

/* --- Container & Layout --- */
.container {
    width: 100%;
    max-width: var(--kb-container-width);
    margin: 0 auto;
    padding: 0 var(--kb-container-padding);
}

.main-content {
    min-height: 100vh;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    font-family: var(--kb-font-body);
    font-size: 15px;
    font-weight: 600;
    line-height: 1;
    border-radius: var(--kb-radius-full);
    cursor: pointer;
    transition: all var(--kb-transition-base);
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.btn svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.btn-primary {
    background: var(--kb-gradient-primary);
    color: #fff;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-lg {
    padding: 18px 36px;
    font-size: 17px;
}

/* --- Navigation --- */
.nav-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 16px 0;
    transition: all var(--kb-transition-base);
}

.nav-bar.nav-scrolled {
    background: rgba(3, 7, 18, 0.85);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid var(--kb-border);
    padding: 12px 0;
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: var(--kb-container-width);
    margin: 0 auto;
    padding: 0 var(--kb-container-padding);
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--kb-font-heading);
    font-size: 22px;
    font-weight: 700;
    color: var(--kb-text-primary);
    z-index: 110;
}

.nav-logo svg {
    width: 36px;
    height: 36px;
}

.logo-accent {
    background: var(--kb-gradient-secondary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

.nav-links a {
    font-size: 14px;
    font-weight: 500;
    color: var(--kb-text-secondary);
    transition: color var(--kb-transition-fast);
    position: relative;
}

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

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--kb-gradient-secondary);
    border-radius: 1px;
    transition: width var(--kb-transition-base);
}

.nav-links a:hover::after {
    width: 100%;
}

.nav-cta {
    padding: 10px 22px !important;
    background: var(--kb-gradient-primary);
    border: none;
    border-radius: var(--kb-radius-full) !important;
    color: #fff !important;
    font-family: var(--kb-font-body);
    font-size: 14px;
    font-weight: 600 !important;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(52, 152, 219, 0.25);
    transition: all var(--kb-transition-base) !important;
}

.nav-cta::after {
    display: none !important;
}

.nav-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.35);
}

/* Mobile Nav Toggle */
.nav-toggle-input {
    display: none;
}

.nav-toggle-label {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 28px;
    height: 28px;
    cursor: pointer;
    z-index: 110;
}

.nav-toggle-label span,
.nav-toggle-label::before,
.nav-toggle-label::after {
    content: '';
    display: block;
    width: 100%;
    height: 2px;
    background: var(--kb-text-primary);
    border-radius: 2px;
    transition: all var(--kb-transition-base);
}

@media (max-width: 768px) {
    .nav-toggle-label {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        flex-direction: column;
        justify-content: center;
        gap: 24px;
        background: rgba(3, 7, 18, 0.98);
        backdrop-filter: blur(30px);
        opacity: 0;
        visibility: hidden;
        transition: all var(--kb-transition-base);
    }

    .nav-links a {
        font-size: 24px;
        font-weight: 600;
    }

    .nav-toggle-input:checked ~ .nav-links {
        opacity: 1;
        visibility: visible;
    }

    .nav-toggle-input:checked ~ .nav-toggle-label span {
        opacity: 0;
    }

    .nav-toggle-input:checked ~ .nav-toggle-label::before {
        transform: translateY(7px) rotate(45deg);
    }

    .nav-toggle-input:checked ~ .nav-toggle-label::after {
        transform: translateY(-7px) rotate(-45deg);
    }

    .nav-cta {
        margin-top: 16px;
    }
}

/* --- Hero Section --- */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    padding: 120px 0 80px;
    overflow: hidden;
}

/* Hero Visual */

@media (max-width: 640px) {
    .hero {
        padding: 100px 0 60px;
    }

}

/* --- Section Common --- */
.section {
    padding: var(--kb-section-padding) 0;
    position: relative;
    /* Content-driven height with generous padding, rather than forcing every
       section to a full viewport (which left large blank gaps on light sections). */
    min-height: auto;
    display: flex;
    align-items: center;
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 64px;
}

.section-label {
    display: inline-block;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--kb-accent-indigo);
    margin-bottom: 16px;
    padding: 6px 14px;
    background: rgba(52, 152, 219, 0.1);
    border-radius: var(--kb-radius-full);
}

.section-title {
    font-size: clamp(36px, 5vw, 64px);
    font-weight: 800;
    margin-bottom: 20px;
    letter-spacing: -0.03em;
}

.section-description {
    font-size: 18px;
    line-height: 1.7;
    color: var(--kb-text-secondary);
}

/* --- How It Works Section --- */
.how-section {
    background: var(--kb-bg-secondary);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    position: relative;
}

.steps-grid::before {
    content: '';
    position: absolute;
    top: 48px;
    left: calc(16.666% + 24px);
    right: calc(16.666% + 24px);
    height: 2px;
    background: linear-gradient(90deg, var(--kb-accent-indigo), var(--kb-accent-cyan));
    opacity: 0.2;
}

.step-card {
    text-align: center;
    position: relative;
    padding: 0 16px;
}

.step-desc {
    font-size: 15px;
    line-height: 1.6;
    color: var(--kb-text-secondary);
    max-width: 300px;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .steps-grid {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .steps-grid::before {
        display: none;
    }
}

/* --- CTA Section --- */
.cta-section {
    background: var(--kb-bg-primary);
    padding: 100px 0;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    width: 800px;
    height: 800px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(52, 152, 219, 0.06) 0%, transparent 70%);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.cta-content {
    text-align: center;
    position: relative;
    z-index: 2;
    max-width: 600px;
    margin: 0 auto;
}

.cta-title {
    font-size: clamp(32px, 4vw, 48px);
    font-weight: 800;
    margin-bottom: 16px;
    letter-spacing: -0.03em;
}

.cta-description {
    font-size: 18px;
    color: var(--kb-text-secondary);
    margin-bottom: 36px;
    line-height: 1.7;
}

/* --- Footer --- */
.footer {
    background: var(--kb-bg-secondary);
    border-top: 1px solid var(--kb-border);
    padding: 80px 0 0;
}

.footer-top {
    display: grid;
    grid-template-columns: 1.5fr 2fr;
    gap: 64px;
    padding-bottom: 48px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--kb-font-heading);
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 16px;
}

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

.footer-tagline {
    font-size: 15px;
    color: var(--kb-text-secondary);
    line-height: 1.6;
    margin-bottom: 24px;
    max-width: 300px;
}

.footer-social {
    display: flex;
    gap: 12px;
}

.footer-social a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--kb-radius-sm);
    background: rgba(255, 255, 255, 0.05);
    color: var(--kb-text-muted);
    transition: all var(--kb-transition-fast);
}

.footer-social a:hover {
    background: rgba(52, 152, 219, 0.1);
    color: var(--kb-accent-indigo);
}

.footer-social a svg {
    width: 18px;
    height: 18px;
}

.footer-links-group {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.footer-links h4 {
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--kb-text-primary);
    margin-bottom: 20px;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links a {
    font-size: 14px;
    color: var(--kb-text-muted);
    transition: color var(--kb-transition-fast);
}

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

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

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

.footer-legal {
    display: flex;
    gap: 24px;
}

.footer-legal a {
    font-size: 13px;
    color: var(--kb-text-muted);
}

.footer-legal a:hover {
    color: var(--kb-text-primary);
}

@media (max-width: 768px) {
    .footer-top {
        grid-template-columns: 1fr;
        gap: 48px;
    }

    .footer-links-group {
        grid-template-columns: repeat(2, 1fr);
    }

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

@media (max-width: 480px) {
    .footer-links-group {
        grid-template-columns: 1fr;
    }
}

/* --- Animations & Keyframes --- */

@keyframes gradient-shift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes fade-in-up {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* --- Scroll Animations --- */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.animate-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.animate-on-scroll.delay-1 { transition-delay: 100ms; }
.animate-on-scroll.delay-2 { transition-delay: 200ms; }
.animate-on-scroll.delay-3 { transition-delay: 300ms; }
.animate-on-scroll.delay-4 { transition-delay: 400ms; }
.animate-on-scroll.delay-5 { transition-delay: 500ms; }

/* --- Scroll Animation Infrastructure --- */
[data-scroll-animation],
[data-parallax-speed] {
    will-change: transform, opacity;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

.reveal-word {
    display: inline-block;
}

/* Nav hide/show on scroll */
.nav-bar.nav-hidden {
    transform: translateY(-100%);
}

/* Nav progress bar */
.nav-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 2px;
    width: 0;
    background: var(--kb-gradient-primary);
}

/* Display heading utility */

/* Hero entrance animations */

@keyframes hero-enter {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Reduced motion overrides */
@media (prefers-reduced-motion: reduce) {
    [data-scroll-animation],
    [data-parallax-speed],
    .reveal-word {
        opacity: 1 !important;
        transform: none !important;
        filter: none !important;
        transition: none !important;
        animation: none !important;
    }

    .scroll-track {
        height: auto !important;
    }

    /* Hero letters begin at opacity:0 for the reveal; show them fully when motion is off */
    .hero-name .hl {
        opacity: 1 !important;
        transform: none !important;
        filter: none !important;
        animation: none !important;
    }
}

/* Mobile: simplify sticky sections */

/* --- Blazor Error UI --- */
#blazor-error-ui {
    color-scheme: dark only;
    background: var(--kb-bg-surface);
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.4);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
    color: var(--kb-text-primary);
    border-top: 1px solid var(--kb-border);
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

#blazor-error-ui .reload {
    color: var(--kb-accent-indigo);
    text-decoration: underline;
}

/* Blazor error boundary */
.blazor-error-boundary {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    padding: 1rem;
    color: #ef4444;
    border-radius: var(--kb-radius-md);
}

.blazor-error-boundary::after {
    content: "An error has occurred.";
}

/* --- Utility Classes --- */
.text-center { text-align: center; }
.text-muted { color: var(--kb-text-muted); }
.mt-4 { margin-top: 16px; }
.mb-4 { margin-bottom: 16px; }

/* =================================================================
   ░░  REBUILD: logo-derived theme + video hero + name reveal  ░░
   Palette taken from the KwickBlocks hexagon logo:
   deep navy background, green→cyan→blue hexagon gradient.
   ================================================================= */
:root {
    --kb-bg-primary: #0a1722;
    --kb-bg-secondary: #0e202e;
    --kb-bg-surface: #14293a;
    --kb-bg-card: rgba(18, 38, 53, 0.55);

    --kb-accent-indigo: #21c7e6;   /* cyan  */
    --kb-accent-violet: #2ee6a6;   /* green */
    --kb-accent-cyan: #21c7e6;
    --kb-accent-blue: #2f9fe0;
    --kb-accent-emerald: #2ee6a6;

    --kb-gradient-primary: linear-gradient(135deg, #2ee6a6, #21c7e6);
    --kb-gradient-secondary: linear-gradient(135deg, #2ee6a6, #2f9fe0);
    --kb-gradient-accent: linear-gradient(135deg, #21c7e6, #2f9fe0);
    --kb-gradient-hero: linear-gradient(120deg, #2ee6a6, #21c7e6, #2f9fe0);

    --kb-font-display: 'Raleway', system-ui, sans-serif;
}

.gradient-text-animated {
    background: linear-gradient(270deg, #2ee6a6, #21c7e6, #2f9fe0, #2ee6a6);
    background-size: 300% 300%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift 6s ease infinite;
}

/* Brand name inside headings/titles uses the Raleway display font,
   matching the hero wordmark. */
.brand {
    font-family: var(--kb-font-display);
    font-weight: 800;
    letter-spacing: 0.01em;
}

/* ----------  HERO  ---------- */
.hero {
    position: relative;
    height: 100vh;
    min-height: 640px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 0;
    overflow: hidden;
    background: var(--kb-bg-primary);
}

.hero-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    pointer-events: none;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        radial-gradient(ellipse 90% 80% at 50% 40%, rgba(10, 23, 34, 0.35) 0%, rgba(10, 23, 34, 0.78) 70%, rgba(10, 23, 34, 0.95) 100%),
        linear-gradient(180deg, rgba(10, 23, 34, 0.55) 0%, rgba(10, 23, 34, 0.25) 45%, rgba(10, 23, 34, 0.92) 100%);
}

.hero-inner {
    position: relative;
    z-index: 2;
    padding: 0 var(--kb-container-padding);
    width: 100%;
}

/* Pause/play control for the auto-looping background video (WCAG 2.2.2) */
.hero-video-toggle {
    position: absolute;
    right: 20px;
    bottom: 20px;
    z-index: 6;
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--kb-radius-full);
    background: rgba(3, 7, 18, 0.55);
    border: 1px solid rgba(248, 250, 252, 0.35);
    color: #f8fafc;
    cursor: pointer;
    backdrop-filter: blur(4px);
    transition: background var(--kb-transition-fast), border-color var(--kb-transition-fast);
}

.hero-video-toggle:hover {
    background: rgba(3, 7, 18, 0.8);
    border-color: rgba(248, 250, 252, 0.6);
}

.hero-video-toggle svg {
    width: 16px;
    height: 16px;
}

.hero-video-toggle .icon-play {
    display: none;
}

.hero-video-toggle[data-state="paused"] .icon-pause {
    display: none;
}

.hero-video-toggle[data-state="paused"] .icon-play {
    display: inline-block;
}

.hero-name {
    font-family: var(--kb-font-display);
    font-weight: 800;
    font-size: clamp(46px, 10.5vw, 160px);
    line-height: 0.98;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: #fff;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0 0.28em;
    text-shadow: 0 10px 60px rgba(0, 0, 0, 0.55);
}

.hero-word {
    display: inline-block;
    white-space: nowrap;
}

.hero-word.is-gradient .hl {
    background: var(--kb-gradient-hero);
    background-size: 100% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
}

.hero-name .hl {
    display: inline-block;
    opacity: 0;
    transform: translateY(0.5em) scale(0.9);
    filter: blur(8px);
    animation: name-letter-in 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
    animation-delay: calc(0.35s + var(--i) * 0.07s);
}

@keyframes name-letter-in {
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

.hero-tagline {
    margin: 28px auto 0;
    max-width: 640px;
    font-family: var(--kb-font-body);
    font-weight: 300;
    font-size: clamp(16px, 2.2vw, 24px);
    line-height: 1.6;
    color: rgba(248, 250, 252, 0.88);
    letter-spacing: 0.01em;
    opacity: 0;
    animation: hero-enter 1s ease forwards;
    animation-delay: 1.45s;
}

.hero-cta {
    margin-top: 30px;
    opacity: 0;
    animation: hero-enter 1s ease forwards;
    animation-delay: 1.55s;
}

.hero-usps {
    list-style: none;
    margin: 26px auto 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px 22px;
    width: 100%;
    max-width: 1120px;
    opacity: 0;
    animation: hero-enter 1s ease forwards;
    animation-delay: 1.65s;
}

.hero-usp {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: var(--kb-font-body);
    font-size: 16.5px;
    font-weight: 500;
    color: rgba(248, 250, 252, 0.85);
}

.hero-usp svg {
    width: 19px;
    height: 19px;
    color: var(--kb-accent-violet);
    flex-shrink: 0;
}

@media (max-width: 640px) {
    .hero-usps {
        flex-direction: column;
        align-items: center;
        gap: 12px;
    }
}

.hero-scroll {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    margin-top: 56px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.22em;
    color: rgba(248, 250, 252, 0.65);
    opacity: 0;
    animation: hero-enter 1s ease forwards;
    animation-delay: 1.8s;
    transition: color var(--kb-transition-fast);
}

.hero-scroll:hover { color: #fff; }

.hero-scroll-arrow {
    display: flex;
    width: 38px;
    height: 38px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 1px solid rgba(248, 250, 252, 0.25);
    animation: scroll-bob 2s ease-in-out infinite;
}

.hero-scroll-arrow svg { width: 18px; height: 18px; }

@keyframes scroll-bob {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(6px); }
}

/* ----------  WHO WE ARE  ---------- */
.who-section { background: var(--kb-bg-primary); }

.who-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.who-card {
    padding: 36px;
    background: var(--kb-bg-card);
    border: 1px solid var(--kb-border);
    border-radius: var(--kb-radius-lg);
    transition: all var(--kb-transition-base);
    backdrop-filter: blur(8px);
}

.who-card:hover {
    border-color: var(--kb-border-hover);
    transform: translateY(-4px);
    box-shadow: 0 0 40px rgba(46, 230, 166, 0.12);
}

.who-icon {
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--kb-radius-md);
    background: rgba(46, 230, 166, 0.12);
    color: var(--kb-accent-violet);
    margin-bottom: 22px;
}

.who-icon svg { width: 26px; height: 26px; }

.who-card:nth-child(2) .who-icon { background: rgba(33, 199, 230, 0.12); color: var(--kb-accent-cyan); }
.who-card:nth-child(3) .who-icon { background: rgba(47, 159, 224, 0.12); color: var(--kb-accent-blue); }

.who-card-title {
    font-size: 21px;
    font-weight: 700;
    margin-bottom: 12px;
}

.who-card-desc {
    font-size: 15px;
    line-height: 1.65;
    color: var(--kb-text-secondary);
}

.who-statement {
    margin: 72px auto 0;
    max-width: 860px;
    text-align: center;
}

.who-statement-text {
    font-family: var(--kb-font-heading);
    font-size: clamp(22px, 3.2vw, 34px);
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: -0.01em;
}

.who-statement-note {
    margin-top: 18px;
    font-size: 13px;
    font-family: var(--kb-font-mono);
    color: var(--kb-text-muted);
    letter-spacing: 0.02em;
}

/* ----------  MEET THE TEAM  ---------- */
.team-block { margin-top: 96px; }

.team-header { margin-bottom: 48px; }

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

.team-card {
    display: flex;
    flex-direction: column;
    padding: 32px;
    background: var(--kb-bg-card);
    border: 1px solid var(--kb-border);
    border-radius: var(--kb-radius-lg);
    transition: all var(--kb-transition-base);
    backdrop-filter: blur(8px);
}

.team-card:hover {
    border-color: var(--kb-border-hover);
    transform: translateY(-4px);
    box-shadow: 0 0 40px rgba(46, 230, 166, 0.12);
}

.team-photo {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    border-radius: var(--kb-radius-md);
    margin-bottom: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    overflow: hidden;
    background:
        radial-gradient(circle at 30% 25%, rgba(46, 230, 166, 0.18), transparent 60%),
        radial-gradient(circle at 75% 80%, rgba(47, 159, 224, 0.18), transparent 60%),
        var(--kb-bg-primary);
    border: 1px dashed var(--kb-border-hover);
}

.team-photo-initials {
    font-family: var(--kb-font-heading);
    font-size: 56px;
    font-weight: 700;
    letter-spacing: 0.02em;
    background: var(--kb-gradient-accent, linear-gradient(135deg, var(--kb-accent-violet), var(--kb-accent-blue)));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: var(--kb-accent-violet);
}

.team-photo-tag {
    font-size: 12px;
    font-family: var(--kb-font-mono);
    color: var(--kb-text-muted);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

/* Circular headshot floating on the gradient panel */
.team-photo--photo {
    border-style: solid;
    border-color: var(--kb-border);
}

.team-photo--photo img {
    position: absolute;
    inset: 12%;
    width: 76%;
    height: 76%;
    object-fit: cover;
    border-radius: var(--kb-radius-full);
    box-shadow: 0 10px 34px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(148, 163, 184, 0.14);
}

.team-linkedin {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 18px;
    font-size: 14px;
    font-family: var(--kb-font-mono);
    color: var(--kb-accent-cyan);
    text-decoration: none;
    transition: color var(--kb-transition-fast);
}

.team-linkedin svg {
    width: 18px;
    height: 18px;
}

.team-linkedin:hover {
    color: var(--kb-text-primary);
}

.team-photo img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.team-name {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 4px;
}

.team-role {
    font-size: 14px;
    font-family: var(--kb-font-mono);
    color: var(--kb-accent-cyan);
    letter-spacing: 0.02em;
    margin-bottom: 16px;
}

.team-bio {
    font-size: 15px;
    line-height: 1.7;
    color: var(--kb-text-secondary);
}

.team-bio em {
    color: var(--kb-text-muted);
    font-style: italic;
}

@media (max-width: 900px) {
    .who-grid { grid-template-columns: 1fr; }
    .team-grid { grid-template-columns: 1fr; }
    .team-block { margin-top: 72px; }
}

/* ----------  HOW IT WORKS (4 steps)  ---------- */
.how-section {
    background: var(--kb-bg-secondary);
}

.how-section .steps-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.how-section .steps-grid::before { display: none; }

.how-section .step-card {
    text-align: left;
    padding: 32px 28px;
    background: var(--kb-bg-card);
    border: 1px solid var(--kb-border);
    border-radius: var(--kb-radius-lg);
    position: relative;
    overflow: hidden;
    transition: all var(--kb-transition-base);
    backdrop-filter: blur(8px);
}

.how-section .step-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--kb-gradient-hero);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--kb-transition-base);
}

.how-section .step-card:hover {
    border-color: var(--kb-border-hover);
    transform: translateY(-4px);
}

.how-section .step-card:hover::before { transform: scaleX(1); }

.how-section .step-index {
    display: block;
    font-family: var(--kb-font-mono);
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    background: var(--kb-gradient-hero);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 16px;
}

.how-section .step-name {
    font-size: 21px;
    font-weight: 700;
    margin-bottom: 12px;
    letter-spacing: -0.01em;
}

.how-section .step-desc {
    font-size: 15px;
    line-height: 1.65;
    color: var(--kb-text-secondary);
    max-width: none;
    margin: 0;
}

@media (max-width: 1024px) {
    .how-section .steps-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
    .how-section .steps-grid { grid-template-columns: 1fr; }
}

/* ----------  CTA  ---------- */
.cta-section {
    background:
        radial-gradient(ellipse 70% 90% at 50% 50%, rgba(33, 199, 230, 0.08), transparent 70%),
        var(--kb-bg-primary);
    text-align: center;
}

.cta-content { max-width: 720px; margin: 0 auto; }

.cta-title {
    font-size: clamp(34px, 5vw, 60px);
    font-weight: 800;
    letter-spacing: -0.03em;
    margin-bottom: 20px;
}

.cta-description {
    font-size: 18px;
    line-height: 1.7;
    color: var(--kb-text-secondary);
    margin-bottom: 36px;
}

.cta-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
}

/* ----------  Reduced motion: reveal name immediately  ---------- */
@media (prefers-reduced-motion: reduce) {
    .hero-name .hl,
    .hero-tagline,
    .hero-cta,
    .hero-usps,
    .hero-scroll {
        opacity: 1 !important;
        transform: none !important;
        filter: none !important;
        animation: none !important;
    }
    .hero-scroll-arrow { animation: none !important; }

    /* Dashboard: show final state, no growth/pulse/typing. */
    .dash-chart span,
    .dash.is-armed .dash-chart span,
    .dash.is-armed.is-live .dash-chart span {
        height: var(--h, 50%) !important;
        transition: none !important;
    }
    .dash-live-dot,
    .dash.is-live .dash-live-dot,
    .dash-caret,
    .dash.is-live .dash-caret {
        animation: none !important;
    }
    .dash-caret { opacity: 0 !important; }
}

/* =================================================================
   ░░  ALTERNATING SECTION BANDS  ░░
   Hero + Who-We-Are stay dark (they merge); sections after that
   alternate with a light band so the page isn't uniformly dark.
   ================================================================= */
.section--light {
    background:
        radial-gradient(ellipse 60% 50% at 50% 0%, rgba(33, 199, 230, 0.06), transparent 70%),
        #eef3f9;
}

/* Headings + copy flip to dark ink on the light band */
.section--light .section-title,
.section--light .step-name {
    color: #0a1722;
}

.section--light .section-description,
.section--light .step-desc {
    color: #475569;
}

/* Eyebrow pill: light tint with deeper teal text for contrast */
.section--light .section-label {
    background: rgba(33, 199, 230, 0.14);
    color: #0a6576;
}

/* Cards become solid white with a soft lifted shadow */
.section--light .step-card {
    background: #ffffff;
    border: 1px solid rgba(15, 23, 42, 0.08);
    box-shadow: 0 6px 24px rgba(2, 8, 23, 0.06);
    backdrop-filter: none;
}

.section--light .step-card:hover {
    border-color: rgba(15, 23, 42, 0.14);
    box-shadow: 0 12px 32px rgba(2, 8, 23, 0.1);
}

/* Light band: emphasis words, step labels and eyebrows use a solid deep teal
   that meets WCAG AA on the white/lavender surface. The bright green→cyan→blue
   gradient is reserved for the dark bands, where it has the contrast to carry. */
.section--light .gradient-text,
.section--light .gradient-text-animated,
.section--light .step-index {
    background: none;
    -webkit-text-fill-color: #0a6576;
    color: #0a6576;
    animation: none;
}

/* CTA on a light band: flip its title + copy to dark ink */
.section--light .cta-title { color: #0a1722; }
.section--light .cta-description { color: #475569; }

/* Inline text links (used in Who We Are copy) */
.inline-link {
    color: var(--kb-accent-cyan);
    font-weight: 600;
    border-bottom: 1px solid rgba(33, 199, 230, 0.4);
    transition: color var(--kb-transition-fast), border-color var(--kb-transition-fast);
}
.inline-link:hover { color: #2ee6a6; border-bottom-color: #2ee6a6; }

/* =================================================================
   ░░  OUR AI PRODUCTS  ░░  (dark band — brand cards + link chips)
   ================================================================= */
.products-section { background: var(--kb-bg-primary); }

/* Five cards over two rows: let the section grow to fit rather than force-centring
   a taller-than-viewport grid (which hid the second row on arrival). */
.products-section {
    min-height: auto;
    align-items: flex-start;
}

/* "More products" cue: shows while the products section is in view but the last
   cards are still below the fold, so visitors know to keep scrolling. */
.scroll-more {
    position: fixed;
    left: 50%;
    bottom: 24px;
    transform: translateX(-50%) translateY(8px);
    z-index: 40;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 18px;
    border-radius: var(--kb-radius-full);
    background: rgba(3, 7, 18, 0.72);
    border: 1px solid rgba(33, 199, 230, 0.45);
    color: var(--kb-text-primary);
    font-family: var(--kb-font-mono);
    font-size: 13px;
    letter-spacing: 0.02em;
    cursor: pointer;
    backdrop-filter: blur(8px);
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.4);
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--kb-transition-base), transform var(--kb-transition-base), visibility var(--kb-transition-base);
}

.scroll-more.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.scroll-more:hover {
    border-color: rgba(33, 199, 230, 0.8);
    background: rgba(3, 7, 18, 0.88);
}

.scroll-more svg {
    width: 16px;
    height: 16px;
    color: var(--kb-accent-cyan);
    animation: scroll-more-nudge 1.6s ease-in-out infinite;
}

@keyframes scroll-more-nudge {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(3px); }
}

@media (prefers-reduced-motion: reduce) {
    .scroll-more svg { animation: none; }
    .scroll-more { transition: opacity var(--kb-transition-base), visibility var(--kb-transition-base); }
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

/* =================================================================
   ░░  LUCY — FLAGSHIP FEATURE CARD  ░░  (full-width, sits above grid)
   ================================================================= */
.product-featured {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    padding: 30px 34px;
    margin-bottom: 24px;
    background:
        radial-gradient(120% 160% at 100% 0%, rgba(33, 199, 230, 0.12), transparent 60%),
        var(--kb-bg-card);
    border: 1px solid var(--kb-border-hover);
    border-radius: var(--kb-radius-lg);
    backdrop-filter: blur(8px);
    transition: border-color var(--kb-transition-base), box-shadow var(--kb-transition-base);
}

.product-featured:hover {
    border-color: rgba(33, 199, 230, 0.55);
    box-shadow: 0 0 46px rgba(33, 199, 230, 0.14);
}

.product-featured-head {
    display: flex;
    align-items: center;
    gap: 16px;
}

.product-featured .product-desc {
    margin-bottom: 4px;
    max-width: 62ch;
}

/* =================================================================
   ░░  MEDIA PRODUCT CARDS  ░░  photo-led (name over the picture)
   ================================================================= */
.product-card--media {
    padding: 0;
    overflow: hidden;
}

.product-card--media:hover {
    border-color: color-mix(in srgb, var(--pc-accent, var(--kb-accent-cyan)) 65%, transparent);
    box-shadow: 0 18px 44px -18px color-mix(in srgb, var(--pc-accent, var(--kb-accent-cyan)) 60%, transparent);
}

.product-media {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
}

.product-media > img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s var(--kb-ease, ease);
}

.product-card--media:hover .product-media > img {
    transform: scale(1.05);
}

.product-media::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(3, 7, 18, 0.92) 4%, rgba(3, 7, 18, 0.35) 42%, rgba(3, 7, 18, 0.05) 72%);
}

.product-media-tag {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 2;
    font-family: var(--kb-font-mono);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #fff;
    padding: 6px 12px;
    border-radius: var(--kb-radius-full);
    background: color-mix(in srgb, var(--pc-accent, #21c7e6) 82%, rgba(0, 0, 0, 0.4));
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
}

.product-media-name {
    position: absolute;
    left: 20px;
    bottom: 16px;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 12px;
}

.product-media-logo {
    width: 40px;
    height: 40px;
    object-fit: contain;
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.5));
}

.product-media-name .product-brand {
    font-size: 30px;
    background: none;
    -webkit-text-fill-color: #fff;
    color: #fff;
    text-shadow: 0 2px 16px rgba(0, 0, 0, 0.55);
}

.product-body {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    padding: 22px 26px 26px;
}

.product-card--media .product-desc {
    margin-bottom: 20px;
}

.product-card {
    display: flex;
    flex-direction: column;
    padding: 32px 28px;
    background: var(--kb-bg-card);
    border: 1px solid var(--kb-border);
    border-radius: var(--kb-radius-lg);
    backdrop-filter: blur(8px);
    transition: all var(--kb-transition-base);
}

.product-card:hover {
    border-color: var(--kb-border-hover);
    transform: translateY(-4px);
    box-shadow: 0 0 40px rgba(33, 199, 230, 0.12);
}

.product-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
}

.product-logo {
    width: 46px;
    height: 46px;
    object-fit: contain;
    flex-shrink: 0;
}

.product-head-text {
    display: flex;
    flex-direction: column;
    gap: 5px;
    min-width: 0;
}

.product-brand {
    font-family: var(--kb-font-display);
    font-size: 26px;
    font-weight: 800;
    letter-spacing: 0.01em;
    line-height: 1;
    background: var(--kb-gradient-hero);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.product-tag {
    font-family: var(--kb-font-mono);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--kb-text-muted);
}

.product-desc {
    font-size: 15px;
    line-height: 1.65;
    color: var(--kb-text-secondary);
    margin-bottom: 24px;
    flex-grow: 1;
}

.product-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.product-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 16px;
    font-size: 14px;
    font-weight: 600;
    border-radius: var(--kb-radius-full);
    background: rgba(33, 199, 230, 0.07);
    border: 1px solid rgba(33, 199, 230, 0.3);
    color: var(--kb-text-primary);
    cursor: pointer;
    transition: all var(--kb-transition-base);
}

.product-link:hover {
    color: #fff;
    border-color: rgba(33, 199, 230, 0.75);
    background: rgba(33, 199, 230, 0.16);
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(33, 199, 230, 0.18);
}

.product-link svg { width: 15px; height: 15px; }

/* Sub-site links carry an "opens a page" arrow so they read as clickable at rest */
.product-link:not(.product-link-primary)::after {
    content: "\2197";
    font-size: 13px;
    line-height: 1;
    color: var(--kb-accent-cyan);
    opacity: 0.75;
    transition: transform var(--kb-transition-fast), opacity var(--kb-transition-fast);
}

.product-link:not(.product-link-primary):hover::after {
    transform: translate(1px, -1px);
    opacity: 1;
}

.product-link-primary {
    background: var(--kb-gradient-primary);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 4px 15px rgba(33, 199, 230, 0.25);
}
.product-link-primary:hover { color: #fff; background: var(--kb-gradient-primary); }

/* Not-yet-live sub-sites: muted, non-interactive (URL kept in data-href) */
.product-link-soon {
    color: var(--kb-text-muted);
    background: transparent;
    border-style: dashed;
    border-color: var(--kb-border-hover);
    cursor: default;
}
.product-link-soon:hover {
    color: var(--kb-text-muted);
    background: transparent;
    border-color: var(--kb-border-hover);
    transform: none;
}

@media (max-width: 1024px) {
    .products-grid { gap: 18px; }
}

/* =================================================================
   ░░  AI OPERATIONS LAYER  ░░  (dark band — copy + dashboard mockup)
   ================================================================= */
.ops-section { background: var(--kb-bg-secondary); }

.ops-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 56px;
    align-items: center;
}

.ops-copy { max-width: 540px; }
.ops-copy .section-title { font-size: clamp(30px, 4vw, 50px); margin-bottom: 16px; }
.ops-copy .section-description { margin-bottom: 30px; }

.ops-points { display: flex; flex-direction: column; gap: 18px; }

.ops-point { display: flex; align-items: flex-start; gap: 14px; }

.ops-point-icon {
    flex-shrink: 0;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--kb-radius-md);
    background: rgba(46, 230, 166, 0.12);
    color: var(--kb-accent-violet);
}
.ops-point:nth-child(2) .ops-point-icon { background: rgba(33, 199, 230, 0.12); color: var(--kb-accent-cyan); }
.ops-point:nth-child(3) .ops-point-icon { background: rgba(47, 159, 224, 0.12); color: var(--kb-accent-blue); }
.ops-point-icon svg { width: 20px; height: 20px; }

.ops-point h3 { font-size: 16px; font-weight: 700; margin-bottom: 3px; }
.ops-point p { font-size: 14px; line-height: 1.5; color: var(--kb-text-secondary); }

/* Dashboard mockup */
.ops-visual { display: flex; justify-content: center; }

.dash {
    width: 100%;
    max-width: 460px;
    padding: 20px;
    background: var(--kb-bg-card);
    border: 1px solid var(--kb-border-hover);
    border-radius: var(--kb-radius-lg);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.4), 0 0 50px rgba(33, 199, 230, 0.08);
    backdrop-filter: blur(8px);
    --ease-quint: cubic-bezier(0.22, 1, 0.36, 1);
}

.dash-bar { display: flex; align-items: center; gap: 8px; margin-bottom: 18px; }
.dash-dot { width: 10px; height: 10px; border-radius: 50%; background: rgba(255, 255, 255, 0.15); }
.dash-dot:nth-child(1) { background: #2ee6a6; }
.dash-dot:nth-child(2) { background: #21c7e6; }
.dash-dot:nth-child(3) { background: #2f9fe0; }

/* Live indicator */
.dash-live-badge {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: var(--kb-font-mono);
    font-size: 10px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--kb-accent-violet);
}
.dash-live-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #2ee6a6;
    box-shadow: 0 0 0 0 rgba(46, 230, 166, 0.5);
}
.dash.is-live .dash-live-dot { animation: dash-pulse 2.6s var(--ease-quint) infinite; }
@keyframes dash-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(46, 230, 166, 0.45); }
    70%  { box-shadow: 0 0 0 7px rgba(46, 230, 166, 0); }
    100% { box-shadow: 0 0 0 0 rgba(46, 230, 166, 0); }
}

.dash-title {
    font-family: var(--kb-font-mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--kb-text-muted);
}

.dash-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 18px; }
.dash-stat {
    padding: 12px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--kb-border);
    border-radius: var(--kb-radius-md);
}
.dash-stat-label { display: block; font-size: 11px; color: var(--kb-text-muted); margin-bottom: 6px; }
.dash-stat-val {
    font-family: var(--kb-font-heading);
    font-size: 20px;
    font-weight: 700;
    background: var(--kb-gradient-hero);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.dash-chart { display: flex; align-items: flex-end; gap: 8px; height: 92px; margin-bottom: 18px; padding: 0 2px; }
.dash-chart span {
    flex: 1;
    border-radius: 4px 4px 0 0;
    background: linear-gradient(180deg, #2ee6a6, #21c7e6);
    opacity: 0.85;
    height: var(--h, 50%);
    transition: height 0.85s var(--ease-quint);
}
/* Armed: collapsed, ready to grow once the dashboard scrolls into view. */
.dash.is-armed .dash-chart span { height: 0; }
.dash.is-armed.is-live .dash-chart span { height: var(--h, 50%); }
.dash.is-armed.is-live .dash-chart span:nth-child(1) { transition-delay: 0.04s; }
.dash.is-armed.is-live .dash-chart span:nth-child(2) { transition-delay: 0.10s; }
.dash.is-armed.is-live .dash-chart span:nth-child(3) { transition-delay: 0.16s; }
.dash.is-armed.is-live .dash-chart span:nth-child(4) { transition-delay: 0.22s; }
.dash.is-armed.is-live .dash-chart span:nth-child(5) { transition-delay: 0.28s; }
.dash.is-armed.is-live .dash-chart span:nth-child(6) { transition-delay: 0.34s; }
.dash.is-armed.is-live .dash-chart span:nth-child(7) { transition-delay: 0.40s; }

.dash-caret {
    display: inline-block;
    width: 2px;
    height: 1em;
    margin-left: 1px;
    vertical-align: text-bottom;
    background: var(--kb-accent-cyan);
    opacity: 0;
}
.dash.is-live .dash-caret { animation: dash-blink 1s steps(1) infinite; }
@keyframes dash-blink {
    0%, 50%      { opacity: 1; }
    50.01%, 100% { opacity: 0; }
}

.dash-query {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: var(--kb-radius-full);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--kb-border-hover);
    color: var(--kb-text-muted);
    font-size: 14px;
}
.dash-query svg { width: 16px; height: 16px; color: var(--kb-accent-cyan); flex-shrink: 0; }

@media (max-width: 900px) {
    .ops-layout { grid-template-columns: 1fr; gap: 40px; }
    .ops-copy { max-width: none; }
    .ops-visual { order: -1; }
}

/* =================================================================
   ░░  POLISH PASS  ░░  accessibility, focus, motion, contrast, targets
   ================================================================= */

/* Muted text was #64748b (~3.7:1 on the navy band, below AA). Lift it so
   eyebrows, product tags and dashboard labels clear AA on dark surfaces. */
:root { --kb-text-muted: #8a98ac; }

/* Visible keyboard focus. The reset strips outline with no replacement;
   restore it for keyboard users only (:focus-visible), on every surface.
   Cyan reads on the dark bands; a deeper teal is used on the light bands so
   the ring keeps a >=3:1 indicator contrast. */
a:focus-visible,
button:focus-visible,
.btn:focus-visible,
.nav-cta:focus-visible,
.product-link:focus-visible,
.inline-link:focus-visible,
.hero-scroll:focus-visible,
.skip-link:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--kb-accent-cyan);
    outline-offset: 3px;
    border-radius: 4px;
}
.section--light a:focus-visible,
.section--light button:focus-visible,
.section--light .btn:focus-visible {
    outline-color: #0e7490;
}

/* Skip link: hidden until focused, then anchored top-left on a solid chip. */
.skip-link {
    position: absolute;
    left: 12px;
    top: -64px;
    z-index: 200;
    padding: 10px 16px;
    border-radius: var(--kb-radius-md);
    background: var(--kb-bg-surface);
    color: var(--kb-text-primary);
    font-size: 14px;
    font-weight: 600;
    border: 1px solid var(--kb-border-hover);
    transition: top var(--kb-transition-base);
}
.skip-link:focus { top: 12px; }

/* Comfortable touch targets on coarse pointers. */
@media (pointer: coarse) {
    .product-link { min-height: 44px; }
    .nav-links a { min-height: 44px; display: inline-flex; align-items: center; }
}

/* Reduced motion: also kill smooth scrolling and the looping gradient shift
   that the earlier reduced-motion blocks don't cover. */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .gradient-text-animated { animation: none; }
}

/* =================================================================
   ░░  LEGAL / CONTENT PAGES  ░░
   ================================================================= */
.legal-section {
    padding: 140px 0 100px;
    min-height: 60vh;
}

.legal-content {
    max-width: 760px;
    margin: 0 auto;
}

.legal-content .section-label {
    margin-bottom: 16px;
}

.legal-content h1 {
    font-size: clamp(32px, 5vw, 52px);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 10px;
}

.legal-updated {
    font-family: var(--kb-font-mono);
    font-size: 13px;
    color: var(--kb-text-muted);
    margin-bottom: 40px;
}

.legal-content h2 {
    font-family: var(--kb-font-heading);
    font-size: 22px;
    font-weight: 700;
    margin: 36px 0 12px;
}

.legal-content p,
.legal-content li {
    font-size: 16px;
    line-height: 1.75;
    color: var(--kb-text-secondary);
}

.legal-content p {
    margin-bottom: 16px;
}

.legal-content ul {
    margin: 0 0 16px;
    padding-left: 22px;
    list-style: disc;
}

.legal-content li {
    margin-bottom: 8px;
}

.legal-content a {
    color: var(--kb-accent-indigo);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.legal-content a:hover {
    color: var(--kb-text-primary);
}

/* =================================================================
   ░░  LET'S CHAT  ░░  nav trigger, ghost button, and modal form
   ================================================================= */

/* Nav trigger, styled to sit among the text nav links */
.nav-chat {
    background: none;
    border: none;
    font-family: var(--kb-font-body);
    font-size: 14px;
    font-weight: 500;
    color: var(--kb-text-secondary);
    cursor: pointer;
    padding: 0;
    transition: color var(--kb-transition-fast);
}

.nav-chat:hover { color: var(--kb-text-primary); }

/* Ghost button for the closing section (works on the light band too) */
.btn-ghost {
    background: rgba(255, 255, 255, 0.06);
    color: var(--kb-text-primary);
    border: 1px solid var(--kb-border-hover);
}

.btn-ghost:hover {
    transform: translateY(-2px);
    border-color: rgba(33, 199, 230, 0.6);
    background: rgba(33, 199, 230, 0.1);
}

.section--light .btn-ghost {
    background: rgba(15, 23, 42, 0.04);
    color: #0a1722;
    border-color: rgba(15, 23, 42, 0.18);
}

.section--light .btn-ghost:hover {
    border-color: #0e7490;
    background: rgba(14, 116, 144, 0.08);
}

/* Modal */
.chat-modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.chat-modal[hidden] { display: none; }

.chat-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(3, 7, 18, 0.75);
    backdrop-filter: blur(6px);
    animation: chat-fade 0.25s ease;
}

.chat-modal-panel {
    position: relative;
    width: 100%;
    max-width: 460px;
    max-height: calc(100vh - 48px);
    overflow-y: auto;
    background: var(--kb-bg-secondary);
    border: 1px solid var(--kb-border-hover);
    border-radius: var(--kb-radius-lg);
    padding: 34px 32px 32px;
    box-shadow: var(--kb-shadow-lg);
    animation: chat-pop 0.28s cubic-bezier(0.2, 0.7, 0.2, 1);
}

@keyframes chat-fade { from { opacity: 0; } }
@keyframes chat-pop { from { opacity: 0; transform: translateY(12px) scale(0.98); } }

.chat-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--kb-radius-full);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--kb-border-hover);
    color: var(--kb-text-secondary);
    cursor: pointer;
    transition: all var(--kb-transition-fast);
}

.chat-modal-close:hover { color: #fff; background: rgba(255, 255, 255, 0.1); }
.chat-modal-close svg { width: 18px; height: 18px; }

.chat-modal-title { font-size: 26px; font-weight: 800; letter-spacing: -0.01em; margin: 6px 0 6px; }
.chat-modal-desc { font-size: 15px; color: var(--kb-text-secondary); line-height: 1.6; margin: 0 0 22px; }

.chat-form { display: flex; flex-direction: column; gap: 15px; }
.chat-field { display: flex; flex-direction: column; gap: 6px; }
.chat-field label { font-size: 13px; font-weight: 600; color: var(--kb-text-secondary); }

/* Day + time sit side by side */
.chat-field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.chat-field input,
.chat-field select {
    width: 100%;
    font-family: var(--kb-font-body);
    font-size: 15px;
    padding: 11px 14px;
    border-radius: var(--kb-radius-sm);
    background: var(--kb-bg-primary);
    border: 1px solid var(--kb-border-hover);
    color: var(--kb-text-primary);
    transition: border-color var(--kb-transition-fast);
    /* Dark-theme the native calendar/time controls and their icons */
    color-scheme: dark;
}

.chat-field input:focus,
.chat-field select:focus { border-color: var(--kb-accent-cyan); }
.chat-field input::placeholder { color: var(--kb-text-muted); }

/* Custom caret for the time selector */
.chat-field select {
    -webkit-appearance: none;
    appearance: none;
    padding-right: 38px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237c8aa1' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px 16px;
}

.chat-field select option { background: var(--kb-bg-secondary); color: var(--kb-text-primary); }

.chat-form-error { color: #ef6a5e; font-size: 13px; margin: 2px 0 0; }
.chat-submit { margin-top: 8px; width: 100%; }

.chat-success { text-align: center; padding: 12px 4px 6px; }
.chat-success svg { width: 46px; height: 46px; color: var(--kb-accent-violet); margin-bottom: 12px; }
.chat-success h3 { font-size: 20px; font-weight: 700; margin: 0 0 8px; }
.chat-success p { font-size: 15px; color: var(--kb-text-secondary); line-height: 1.6; margin: 0 0 20px; }

@media (max-width: 768px) {
    .nav-links .nav-chat { font-size: 24px; font-weight: 600; }
}

@media (prefers-reduced-motion: reduce) {
    .chat-modal-backdrop, .chat-modal-panel { animation: none; }
}

/* =================================================================
   ░░  MOBILE CAROUSELS  ░░  small-panel grids become swipeable rows
   ================================================================= */
@media (max-width: 768px) {
    .who-grid,
    .how-section .steps-grid,
    .products-grid,
    .team-grid {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        overflow-y: visible;
        scroll-snap-type: x mandatory;
        gap: 16px;
        max-width: none;
        /* Full-bleed to the screen edges (the container has 24px side padding) */
        margin: 0 -24px;
        padding: 6px 24px 20px;
        scroll-padding-left: 24px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        -ms-overflow-style: none;
    }

    .who-grid::-webkit-scrollbar,
    .how-section .steps-grid::-webkit-scrollbar,
    .products-grid::-webkit-scrollbar,
    .team-grid::-webkit-scrollbar { display: none; }

    .how-section .steps-grid::before { display: none; }

    .who-card,
    .step-card,
    .product-card,
    .team-card {
        flex: 0 0 84%;
        scroll-snap-align: center;
    }

    /* A touch narrower for the two-up team cards so both peek nicely */
    .team-card { flex-basis: 86%; }
}

/* =================================================================
   ░░  CAROUSEL CONTROLS  ░░  arrows + position dots (mobile only)
   ================================================================= */
.carousel-controls { display: none; }

@media (max-width: 768px) {
    .carousel-controls {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 14px;
        margin-top: 20px;
    }

    .carousel-arrow {
        width: 40px;
        height: 40px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-radius: var(--kb-radius-full);
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid var(--kb-border-hover);
        color: var(--kb-text-primary);
        cursor: pointer;
        flex-shrink: 0;
        transition: background var(--kb-transition-fast), border-color var(--kb-transition-fast), opacity var(--kb-transition-fast);
    }

    .carousel-arrow svg { width: 18px; height: 18px; }

    .carousel-arrow:hover {
        border-color: rgba(33, 199, 230, 0.6);
        background: rgba(33, 199, 230, 0.1);
    }

    .carousel-arrow:disabled {
        opacity: 0.3;
        cursor: default;
    }

    .carousel-arrow:disabled:hover {
        border-color: var(--kb-border-hover);
        background: rgba(255, 255, 255, 0.05);
    }

    .carousel-dots {
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .carousel-dot {
        width: 8px;
        height: 8px;
        padding: 0;
        border: none;
        border-radius: var(--kb-radius-full);
        background: rgba(148, 163, 184, 0.35);
        cursor: pointer;
        transition: width var(--kb-transition-base), background var(--kb-transition-fast);
    }

    .carousel-dot.is-active {
        width: 24px;
        background: var(--kb-accent-cyan);
    }

    /* Light band (Getting Started steps) contrast */
    .section--light .carousel-arrow {
        background: rgba(15, 23, 42, 0.05);
        color: #0a1722;
        border-color: rgba(15, 23, 42, 0.18);
    }
    .section--light .carousel-arrow:hover {
        border-color: #0e7490;
        background: rgba(14, 116, 144, 0.08);
    }
    .section--light .carousel-dot { background: rgba(15, 23, 42, 0.25); }
    .section--light .carousel-dot.is-active { background: #0e7490; }
}
