/* ==========================================================================
   Akarra Technologies - Light Theme
   ========================================================================== */

:root {
    /* Brand - Akarra Red stays constant */
    --color-accent: #CE1513;
    --color-accent-glow: rgba(206, 21, 19, 0.25);
    --color-accent-soft: rgba(206, 21, 19, 0.08);

    /* Light theme palette */
    --color-bg: #F8F9FA;
    --color-bg-elevated: #FFFFFF;
    --color-bg-subtle: #F1F3F5;

    /* Text hierarchy - dark on light */
    --text-primary: rgba(15, 23, 42, 0.95);
    --text-secondary: rgba(15, 23, 42, 0.7);
    --text-tertiary: rgba(15, 23, 42, 0.5);
    --text-muted: rgba(15, 23, 42, 0.35);

    /* Surface effects */
    --surface-bg: rgba(255, 255, 255, 0.8);
    --surface-border: rgba(15, 23, 42, 0.08);
    --surface-border-strong: rgba(15, 23, 42, 0.12);
    --surface-shadow: rgba(15, 23, 42, 0.06);

    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

    /* Spacing */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 2rem;
    --space-xl: 3rem;
    --space-2xl: 4rem;
    --space-3xl: 6rem;

    /* Layout */
    --container-max: 1200px;
    --container-padding: 1.5rem;

    /* Motion */
    --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-out-back: cubic-bezier(0.34, 1.56, 0.64, 1);
    --duration-fast: 150ms;
    --duration-normal: 300ms;
    --duration-slow: 500ms;
}

/* ==========================================================================
   Dark Mode (prefers-color-scheme fallback + manual override)
   ========================================================================== */

/* System preference: dark mode (fallback when no manual choice) */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        /* Dark theme palette */
        --color-bg: #0a0a0f;
        --color-bg-elevated: #141419;
        --color-bg-subtle: #1a1a22;

        /* Text hierarchy - light on dark */
        --text-primary: rgba(255, 255, 255, 0.95);
        --text-secondary: rgba(255, 255, 255, 0.72);
        --text-tertiary: rgba(255, 255, 255, 0.5);
        --text-muted: rgba(255, 255, 255, 0.35);

        /* Surface effects */
        --surface-bg: rgba(255, 255, 255, 0.05);
        --surface-border: rgba(255, 255, 255, 0.08);
        --surface-border-strong: rgba(255, 255, 255, 0.12);
        --surface-shadow: rgba(0, 0, 0, 0.4);

        /* Accent adjustments for dark */
        --color-accent-soft: rgba(206, 21, 19, 0.15);
        --color-accent-glow: rgba(206, 21, 19, 0.4);
    }
}

/* Manual override: user explicitly chose dark */
:root[data-theme="dark"] {
    /* Dark theme palette */
    --color-bg: #0a0a0f;
    --color-bg-elevated: #141419;
    --color-bg-subtle: #1a1a22;

    /* Text hierarchy - light on dark */
    --text-primary: rgba(255, 255, 255, 0.95);
    --text-secondary: rgba(255, 255, 255, 0.72);
    --text-tertiary: rgba(255, 255, 255, 0.5);
    --text-muted: rgba(255, 255, 255, 0.35);

    /* Surface effects */
    --surface-bg: rgba(255, 255, 255, 0.05);
    --surface-border: rgba(255, 255, 255, 0.08);
    --surface-border-strong: rgba(255, 255, 255, 0.12);
    --surface-shadow: rgba(0, 0, 0, 0.4);

    /* Accent adjustments for dark */
    --color-accent-soft: rgba(206, 21, 19, 0.15);
    --color-accent-glow: rgba(206, 21, 19, 0.4);
}

/* ==========================================================================
   Reset & Base
   ========================================================================== */

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

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    color-scheme: light dark;
}

body {
    font-family: var(--font-family);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--color-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

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

a {
    color: inherit;
    text-decoration: none;
}

h1,
h2,
h3 {
    line-height: 1.1;
    font-weight: 500;
    letter-spacing: -0.02em;
    color: var(--text-primary);
}

/* ==========================================================================
   Layout
   ========================================================================== */

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

section {
    padding: var(--space-2xl) 0;
    position: relative;
}

/* ==========================================================================
   Header
   ========================================================================== */

.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: var(--space-md) var(--space-md);
    transition: all 500ms var(--ease-out-expo);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0.5rem 1rem;
    background: transparent;
    border-radius: 100px;
    border: 1px solid transparent;
    transition: all 500ms var(--ease-out-expo);
}

.scrolled .header {
    padding: var(--space-sm) var(--space-md);
}

.scrolled .header-inner {
    max-width: 600px;
    padding: 0.375rem 0.5rem 0.375rem 1rem;
    background: var(--surface-bg);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-color: var(--surface-border);
    box-shadow:
        0 0 0 1px var(--surface-border),
        0 2px 4px var(--surface-shadow),
        0 8px 16px var(--surface-shadow);
}

.scrolled .logo img {
    width: 28px;
    height: 28px;
}

.scrolled .logo-text {
    font-size: 1rem;
}

.scrolled .nav-links a {
    font-size: 0.8125rem;
    padding: 0.375rem 0.75rem;
}

.scrolled .btn-primary {
    padding: 0.5rem 1rem;
    font-size: 0.8125rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: opacity 200ms ease;
}

.logo:hover {
    opacity: 0.8;
}

.logo img {
    width: 32px;
    height: 32px;
    transition: all 300ms ease;
}

.logo-text {
    font-size: 1.125rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    transition: all 400ms var(--ease-out-expo);
}

.nav {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.nav-links a {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    padding: 0.5rem 0.875rem;
    border-radius: 8px;
    transition: all 300ms var(--ease-out-expo);
}

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

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem 1.25rem;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    border-radius: 100px;
    border: none;
    cursor: pointer;
    overflow: hidden;
    transition: all 250ms var(--ease-out-expo);
}

.btn-primary {
    background: linear-gradient(135deg, #CE1513 0%, #E63946 100%);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow:
        0 2px 8px rgba(206, 21, 19, 0.25),
        0 1px 0 rgba(255, 255, 255, 0.1) inset;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    transition: left 500ms ease;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow:
        0 4px 16px rgba(206, 21, 19, 0.35),
        0 1px 0 rgba(255, 255, 255, 0.15) inset;
}

.btn-primary:hover::before {
    left: 100%;
}

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

.btn-large {
    padding: 0.875rem 1.75rem;
    font-size: 0.875rem;
    border-radius: 12px;
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
    min-height: auto;
    display: flex;
    flex-direction: column;
    padding-top: 160px;
    padding-bottom: var(--space-xl);
    background: var(--color-bg);
    position: relative;
    overflow: hidden;
}

.hero .container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--container-padding);
    text-align: left;
}

.hero-teaser {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-secondary);
    padding: 0.5rem 0;
    white-space: nowrap;
    flex-shrink: 0;
    transition: color var(--duration-normal) ease;
}

.hero-teaser:hover {
    color: var(--text-primary);
}

.teaser-dot {
    width: 8px;
    height: 8px;
    background: var(--color-accent);
    border-radius: 50%;
    box-shadow: 0 0 8px var(--color-accent-glow);
}

.teaser-arrow {
    transition: transform var(--duration-normal) ease;
}

.hero-teaser:hover .teaser-arrow {
    transform: translateX(3px);
}

.hero h1 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 500;
    max-width: 720px;
    margin-bottom: var(--space-md);
    margin-left: 0;
    margin-right: auto;
    line-height: 1.15;
    letter-spacing: -0.025em;
    color: var(--text-primary);
}

.hero-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-xl);
    margin-top: var(--space-lg);
}

.hero-subtitle {
    font-size: 1rem;
    font-weight: 400;
    color: var(--text-tertiary);
    max-width: 420px;
    margin: 0;
    line-height: 1.6;
}

/* Hero Mockup - Light theme version */
.hero-mockup {
    position: relative;
    width: 100%;
    max-width: 900px;
    margin: var(--space-2xl) auto 0;
    padding: 0 var(--container-padding);
    transform: perspective(1500px) rotateX(5deg);
    transform-style: preserve-3d;
    opacity: 0.9;
    pointer-events: none;
}

.mockup-dashboard {
    background: var(--color-bg-elevated);
    border-radius: 12px;
    border: 1px solid var(--surface-border-strong);
    display: flex;
    overflow: hidden;
    box-shadow:
        0 25px 50px -12px rgba(0, 0, 0, 0.15),
        0 0 0 1px rgba(0, 0, 0, 0.03);
}

.mock-sidebar {
    width: 140px;
    background: var(--color-bg-subtle);
    border-right: 1px solid var(--surface-border);
    padding: 12px 8px;
    flex-shrink: 0;
}

.mock-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px;
    margin-bottom: 16px;
}

.mock-logo-icon {
    width: 20px;
    height: 20px;
    background: linear-gradient(135deg, #CE1513 0%, #E63946 100%);
    border-radius: 5px;
}

.mock-logo-text {
    height: 8px;
    width: 45px;
    background: var(--text-tertiary);
    border-radius: 3px;
}

.mock-nav-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    border-radius: 6px;
    margin-bottom: 4px;
}

.mock-nav-item.active {
    background: var(--color-accent-soft);
    border: 1px solid rgba(206, 21, 19, 0.15);
}

.mock-nav-icon {
    width: 12px;
    height: 12px;
    background: var(--text-muted);
    border-radius: 3px;
}

.mock-nav-item.active .mock-nav-icon {
    background: var(--color-accent);
}

.mock-nav-text {
    height: 6px;
    width: 50px;
    background: var(--text-muted);
    border-radius: 2px;
}

.mock-nav-item.active .mock-nav-text {
    background: var(--text-secondary);
}

.mock-main {
    flex: 1;
    padding: 14px;
    background: var(--color-bg-elevated);
}

.mock-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--surface-border);
}

.mock-title {
    height: 10px;
    width: 70px;
    background: var(--text-tertiary);
    border-radius: 3px;
}

.mock-search {
    width: 100px;
    height: 22px;
    background: var(--color-bg-subtle);
    border: 1px solid var(--surface-border);
    border-radius: 6px;
}

.mock-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin-bottom: 14px;
}

.mock-stat-card {
    background: var(--color-bg-subtle);
    border: 1px solid var(--surface-border);
    border-radius: 8px;
    padding: 10px;
}

.mock-stat-value {
    height: 14px;
    width: 28px;
    background: var(--text-tertiary);
    border-radius: 3px;
    margin-bottom: 6px;
}

.mock-stat-trend {
    height: 4px;
    width: 40px;
    background: var(--text-muted);
    border-radius: 2px;
}

.mock-stat-trend.green {
    background: #22c55e;
}

.mock-stat-trend.red {
    background: var(--color-accent);
}

.mock-content {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 12px;
}

.mock-panel {
    background: var(--color-bg-subtle);
    border: 1px solid var(--surface-border);
    border-radius: 8px;
    padding: 10px;
}

.mock-panel-header {
    height: 8px;
    width: 60px;
    background: var(--text-tertiary);
    border-radius: 3px;
    margin-bottom: 10px;
}

.mock-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    background: var(--color-bg-elevated);
    border-radius: 6px;
    margin-bottom: 6px;
}

.mock-row-status {
    width: 3px;
    height: 24px;
    border-radius: 2px;
    background: var(--text-muted);
}

.mock-row-status.green {
    background: #22c55e;
}

.mock-row-status.amber {
    background: #f59e0b;
}

.mock-row-status.red {
    background: var(--color-accent);
}

.mock-row-text {
    flex: 1;
    height: 6px;
    background: var(--text-muted);
    border-radius: 2px;
}

.mock-row-value {
    width: 24px;
    height: 12px;
    background: var(--color-accent-soft);
    border-radius: 3px;
}

.mock-panel-small {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.mock-alert {
    padding: 10px;
    border-radius: 6px;
    height: 36px;
}

.mock-alert.amber {
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.2);
}

.mock-alert.red {
    background: var(--color-accent-soft);
    border: 1px solid rgba(206, 21, 19, 0.15);
}

@media (max-width: 1024px) {
    .hero {
        padding-top: 140px;
    }

    .hero-bottom {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--space-md);
    }

    .hero-mockup {
        margin-top: var(--space-lg);
        transform: none;
        opacity: 0.85;
    }
}

@media (max-width: 600px) {
    .hero-mockup {
        margin-top: var(--space-lg);
        opacity: 0.75;
    }

    .mock-sidebar {
        display: none;
    }

    .mockup-dashboard {
        border-radius: 8px;
    }
}

/* ==========================================================================
   Services / Track Record
   ========================================================================== */

.services {
    background: var(--color-bg);
    position: relative;
    padding: var(--space-2xl) 0;
}

.section-header {
    margin-bottom: var(--space-xl);
}

.section-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-accent);
    margin-bottom: var(--space-sm);
}

.services h2,
.services-section h2,
.approach h2,
.visual-story h2,
.about h2,
.contact h2 {
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    font-weight: 500;
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: var(--text-primary);
}

.section-subtitle {
    font-size: 1rem;
    font-weight: 400;
    color: var(--text-secondary);
    margin-top: var(--space-sm);
    max-width: 480px;
}

.section-note {
    font-size: 0.875rem;
    font-weight: 400;
    color: var(--text-tertiary);
    margin-top: var(--space-xs);
    max-width: 480px;
    font-style: italic;
}

.track-record-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--space-xl);
}

.track-record-item {
    background: var(--color-bg-elevated);
    border: 1px solid var(--surface-border-strong);
    border-radius: 12px;
    padding: var(--space-lg);
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    box-shadow: 0 2px 8px var(--surface-shadow);
}

.track-record-badge {
    display: inline-flex;
    align-self: flex-start;
    padding: 0.25rem 0.75rem;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: rgba(34, 197, 94, 0.1);
    color: #16a34a;
    border: 1px solid rgba(34, 197, 94, 0.2);
    border-radius: 100px;
}

.track-record-badge.secondary {
    background: var(--color-accent-soft);
    color: var(--color-accent);
    border-color: rgba(206, 21, 19, 0.2);
}

.track-record-item h3 {
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--text-primary);
    margin: 0;
}

.track-record-context {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.5;
    margin: 0;
}

.track-record-features {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.track-record-features li {
    color: var(--text-secondary);
    font-size: 0.875rem;
    line-height: 1.5;
    padding-left: 1.25rem;
    position: relative;
}

.track-record-features li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.5rem;
    width: 6px;
    height: 6px;
    background: var(--color-accent);
    border-radius: 50%;
    opacity: 0.6;
}

.track-record-proof {
    color: var(--text-tertiary);
    font-size: 0.8125rem;
    font-style: italic;
    line-height: 1.5;
    margin: 0;
    padding-top: var(--space-sm);
    border-top: 1px solid var(--surface-border);
}

@media (max-width: 900px) {
    .track-record-grid {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }
}

/* ==========================================================================
   Services Section - Bento Grid
   ========================================================================== */

.services-section {
    background: var(--color-bg-subtle);
    padding: var(--space-2xl) 0;
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-template-rows: auto auto auto;
    gap: var(--space-md);
    margin-bottom: var(--space-xl);
}

.bento-card {
    background: var(--color-bg-elevated);
    border: 1px solid var(--surface-border-strong);
    border-radius: 16px;
    padding: var(--space-lg);
    position: relative;
    overflow: hidden;
    transition: all var(--duration-normal) var(--ease-out-expo);
}

/* Hero card - spans 8 columns, 2 rows */
.bento-card.bento-hero {
    grid-column: span 8;
    grid-row: span 2;
    display: flex;
    flex-direction: column;
    min-height: 320px;
    padding-right: 340px;
}

.bento-card.bento-hero:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px var(--surface-shadow);
    border-color: rgba(206, 21, 19, 0.3);
}

/* Secondary cards */
.bento-card.bento-secondary {
    grid-column: span 4;
    min-height: 150px;
    --mouse-x: 50%;
    --mouse-y: 50%;
}

/* Tertiary cards */
.bento-card.bento-tertiary {
    grid-column: span 4;
    min-height: 140px;
    --mouse-x: 50%;
    --mouse-y: 50%;
}

/* Cursor-following gradient for secondary/tertiary cards */
.bento-card.bento-secondary::before,
.bento-card.bento-tertiary::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(
        circle 150px at var(--mouse-x) var(--mouse-y),
        rgba(206, 21, 19, 0.15) 0%,
        rgba(206, 21, 19, 0.05) 40%,
        transparent 70%
    );
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 0;
    border-radius: 16px;
    pointer-events: none;
}

.bento-card.bento-secondary:hover,
.bento-card.bento-tertiary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px var(--surface-shadow);
    border-color: rgba(206, 21, 19, 0.2);
}

.bento-card.bento-secondary:hover::before,
.bento-card.bento-tertiary:hover::before {
    opacity: 1;
}

/* Card content */
.bento-card h3 {
    font-size: 1.125rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    color: var(--text-primary);
    margin-bottom: var(--space-xs);
    position: relative;
    z-index: 1;
}

.bento-card.bento-hero h3 {
    font-size: 1.5rem;
    margin-bottom: var(--space-sm);
}

.bento-card p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 0;
    position: relative;
    z-index: 1;
}

.bento-card.bento-hero p {
    font-size: 1rem;
    max-width: 380px;
}

.bento-card .card-label {
    display: inline-block;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--color-accent);
    background: var(--color-accent-soft);
    padding: 0.25rem 0.625rem;
    border-radius: 100px;
    margin-bottom: var(--space-sm);
    position: relative;
    z-index: 1;
}

/* Hero card animation */
.bento-hero-visual {
    position: absolute;
    top: 50%;
    right: 20px;
    transform: translateY(-50%);
    width: 320px;
    height: 220px;
    opacity: 0.95;
    pointer-events: none;
}

.bento-hero-visual .flow-container {
    position: relative;
    width: 100%;
    height: 100%;
}

/* Floating task cards */
.bento-hero-visual .task-card {
    position: absolute;
    background: linear-gradient(135deg, var(--color-bg-elevated) 0%, var(--color-bg-subtle) 100%);
    border: 1px solid var(--surface-border-strong);
    border-radius: 10px;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 12px var(--surface-shadow);
    animation: floatOrganize 7s var(--ease-out-expo) infinite;
}

.bento-hero-visual .task-card .status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.bento-hero-visual .task-card .status-dot.green {
    background: #22c55e;
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.5);
}
.bento-hero-visual .task-card .status-dot.amber {
    background: #f59e0b;
    box-shadow: 0 0 8px rgba(245, 158, 11, 0.5);
}
.bento-hero-visual .task-card .status-dot.red {
    background: var(--color-accent);
    box-shadow: 0 0 8px var(--color-accent-glow);
}

.bento-hero-visual .task-card .task-line {
    height: 6px;
    background: linear-gradient(90deg, var(--text-muted) 0%, var(--text-tertiary) 100%);
    border-radius: 3px;
}

.bento-hero-visual .task-card .task-line-short {
    height: 6px;
    width: 30px;
    background: var(--text-muted);
    border-radius: 3px;
    opacity: 0.5;
    margin-left: auto;
}

.bento-hero-visual .task-card:nth-child(1) {
    --start-x: 200px; --start-y: 10px;
    --end-x: 50px; --end-y: 25px;
    animation-delay: 0s;
}
.bento-hero-visual .task-card:nth-child(1) .task-line { width: 70px; }

.bento-hero-visual .task-card:nth-child(2) {
    --start-x: 20px; --start-y: 160px;
    --end-x: 50px; --end-y: 72px;
    animation-delay: 0.2s;
}
.bento-hero-visual .task-card:nth-child(2) .task-line { width: 55px; }

.bento-hero-visual .task-card:nth-child(3) {
    --start-x: 240px; --start-y: 120px;
    --end-x: 50px; --end-y: 119px;
    animation-delay: 0.4s;
}
.bento-hero-visual .task-card:nth-child(3) .task-line { width: 65px; }

.bento-hero-visual .task-card:nth-child(4) {
    --start-x: 80px; --start-y: 190px;
    --end-x: 50px; --end-y: 166px;
    animation-delay: 0.6s;
}
.bento-hero-visual .task-card:nth-child(4) .task-line { width: 50px; }

@keyframes floatOrganize {
    0%, 12% {
        left: var(--start-x);
        top: var(--start-y);
        opacity: 0.3;
        transform: rotate(calc((var(--start-x) - 120px) * 0.08deg)) scale(0.9);
    }
    35%, 70% {
        left: var(--end-x);
        top: var(--end-y);
        opacity: 1;
        transform: rotate(0deg) scale(1);
    }
    88%, 100% {
        left: var(--start-x);
        top: var(--start-y);
        opacity: 0.3;
        transform: rotate(calc((var(--start-x) - 120px) * 0.08deg)) scale(0.9);
    }
}

/* Organized list container */
.bento-hero-visual .organized-list {
    position: absolute;
    left: 30px;
    top: 15px;
    width: 160px;
    height: 195px;
    border: 2px dashed var(--surface-border-strong);
    border-radius: 14px;
    opacity: 0;
    animation: fadeInList 7s var(--ease-out-expo) infinite;
    background: linear-gradient(135deg, transparent 0%, rgba(206, 21, 19, 0.02) 100%);
}

.bento-hero-visual .organized-list::before {
    content: 'Tasks';
    position: absolute;
    top: -10px;
    left: 12px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-accent);
    background: var(--color-bg-elevated);
    padding: 2px 8px;
    border-radius: 4px;
    opacity: 0;
    animation: labelFade 7s var(--ease-out-expo) infinite;
}

@keyframes fadeInList {
    0%, 20% { opacity: 0; border-color: var(--surface-border); }
    40%, 65% { opacity: 1; border-color: rgba(206, 21, 19, 0.4); }
    82%, 100% { opacity: 0; border-color: var(--surface-border); }
}

@keyframes labelFade {
    0%, 35% { opacity: 0; }
    45%, 60% { opacity: 1; }
    75%, 100% { opacity: 0; }
}

.services-cta-text {
    text-align: center;
    font-size: 1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* Bento grid responsive */
@media (max-width: 1024px) {
    .bento-grid {
        grid-template-columns: repeat(6, 1fr);
    }

    .bento-card.bento-hero {
        grid-column: span 6;
        grid-row: span 1;
        min-height: 280px;
        padding-right: 260px;
    }

    .bento-card.bento-secondary {
        grid-column: span 3;
    }

    .bento-card.bento-tertiary {
        grid-column: span 3;
    }

    .bento-hero-visual {
        width: 240px;
        height: 160px;
        opacity: 0.7;
    }
}

@media (max-width: 600px) {
    .bento-grid {
        grid-template-columns: 1fr;
        gap: var(--space-sm);
    }

    .bento-card.bento-hero,
    .bento-card.bento-secondary,
    .bento-card.bento-tertiary {
        grid-column: span 1;
        min-height: auto;
        padding: var(--space-md);
        padding-right: var(--space-md);
    }

    /* Hero card stacks vertically on mobile */
    .bento-card.bento-hero {
        min-height: auto;
        padding-bottom: 200px;
    }

    .bento-hero-visual {
        top: auto;
        bottom: 10px;
        left: 50%;
        right: auto;
        transform: translateX(-50%) scale(0.75);
        width: 320px;
        height: 180px;
        opacity: 0.85;
    }
}

/* ==========================================================================
   Bento Animated Cards - Living Animations
   ========================================================================== */

/* Animated card base */
.bento-card.bento-animated {
    grid-column: span 4;
    min-height: 220px;
    display: flex;
    flex-direction: column;
    --mouse-x: 50%;
    --mouse-y: 50%;
}

.bento-card.bento-animated::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(
        circle 150px at var(--mouse-x) var(--mouse-y),
        rgba(206, 21, 19, 0.15) 0%,
        rgba(206, 21, 19, 0.05) 40%,
        transparent 70%
    );
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 0;
    border-radius: 16px;
    pointer-events: none;
}

.bento-card.bento-animated:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px var(--surface-shadow);
    border-color: rgba(206, 21, 19, 0.2);
}

.bento-card.bento-animated:hover::before {
    opacity: 1;
}

/* Animation container */
.card-animation {
    height: 140px;
    margin-bottom: var(--space-sm);
    position: relative;
    background: var(--color-bg-subtle);
    border-radius: 8px;
    overflow: hidden;
}

.bento-card.bento-animated .card-label-text {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    position: relative;
    z-index: 1;
}

/* ===================
   Notifications Animation
   =================== */
.notif-animation {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 14px;
}

.notif-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    background: var(--color-bg-elevated);
    border-radius: 6px;
    border-left: 3px solid #f59e0b;
    animation: notifClear 6s ease-in-out infinite;
}

.notif-item:nth-child(1) { animation-delay: 0s; }
.notif-item:nth-child(2) { animation-delay: 0.5s; }
.notif-item:nth-child(3) { animation-delay: 1s; }

.notif-dot {
    width: 6px;
    height: 6px;
    background: #f59e0b;
    border-radius: 50%;
}

.notif-line {
    height: 5px;
    background: var(--text-muted);
    border-radius: 3px;
    flex: 1;
}

.notif-check {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #22c55e;
    opacity: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.notif-check::after {
    content: '';
    width: 5px;
    height: 3px;
    border-left: 2px solid white;
    border-bottom: 2px solid white;
    transform: rotate(-45deg) translateY(-1px);
}

@keyframes notifClear {
    0%, 30% { border-left-color: #f59e0b; opacity: 1; }
    40% { border-left-color: #22c55e; }
    50%, 70% { border-left-color: #22c55e; opacity: 1; }
    80%, 100% { opacity: 0.3; border-left-color: var(--surface-border); }
}

.notif-item:nth-child(1) .notif-check { animation: checkAppear 6s ease-in-out infinite 0s; }
.notif-item:nth-child(2) .notif-check { animation: checkAppear 6s ease-in-out infinite 0.5s; }
.notif-item:nth-child(3) .notif-check { animation: checkAppear 6s ease-in-out infinite 1s; }

@keyframes checkAppear {
    0%, 40% { opacity: 0; transform: scale(0); }
    50%, 70% { opacity: 1; transform: scale(1); }
    80%, 100% { opacity: 0; transform: scale(0); }
}

/* ===================
   Progress Animation
   =================== */
.progress-animation {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 14px;
}

.progress-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.progress-icon {
    width: 20px;
    height: 20px;
    background: var(--color-bg-elevated);
    border-radius: 4px;
    border: 1px solid var(--surface-border);
}

.progress-bar-container {
    flex: 1;
    height: 6px;
    background: var(--surface-border);
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: var(--color-accent);
    border-radius: 4px;
    animation: progressFill 4s ease-in-out infinite;
}

.progress-row:nth-child(1) .progress-bar { animation-delay: 0s; }
.progress-row:nth-child(2) .progress-bar { animation-delay: 0.3s; }
.progress-row:nth-child(3) .progress-bar { animation-delay: 0.6s; }
.progress-row:nth-child(4) .progress-bar { animation-delay: 0.9s; }

@keyframes progressFill {
    0%, 10% { width: 0%; }
    50%, 70% { width: 100%; background: #22c55e; }
    90%, 100% { width: 0%; }
}

/* ===================
   Dashboard Animation
   =================== */
.dashboard-animation {
    position: relative;
    height: 100%;
}

.mini-dashboard {
    position: absolute;
    right: 12px;
    top: 12px;
    width: 55%;
    height: calc(100% - 24px);
    background: var(--color-bg-elevated);
    border-radius: 6px;
    border: 1px solid var(--surface-border-strong);
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dash-metric {
    display: flex;
    align-items: center;
    gap: 8px;
}

.dash-metric-bar {
    flex: 1;
    height: 4px;
    background: var(--surface-border);
    border-radius: 2px;
    overflow: hidden;
}

.dash-metric-fill {
    height: 100%;
    background: var(--color-accent);
    animation: metricFill 5s ease-out infinite;
}

.dash-metric:nth-child(1) .dash-metric-fill { animation-delay: 0.5s; }
.dash-metric:nth-child(2) .dash-metric-fill { animation-delay: 1s; }
.dash-metric:nth-child(3) .dash-metric-fill { animation-delay: 1.5s; }

@keyframes metricFill {
    0%, 15% { width: 0%; }
    40%, 80% { width: 75%; }
    95%, 100% { width: 0%; }
}

.data-stream {
    position: absolute;
    left: 8px;
    width: 30%;
    display: flex;
    flex-direction: column;
    gap: 10px;
    top: 50%;
    transform: translateY(-50%);
}

.stream-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.stream-dot {
    width: 5px;
    height: 5px;
    background: var(--text-muted);
    border-radius: 50%;
    animation: streamPulse 5s ease-in-out infinite;
}

.stream-item:nth-child(1) .stream-dot { animation-delay: 0s; }
.stream-item:nth-child(2) .stream-dot { animation-delay: 0.3s; }
.stream-item:nth-child(3) .stream-dot { animation-delay: 0.6s; }

.stream-line {
    width: 100%;
    height: 2px;
    background: var(--surface-border);
    position: relative;
    overflow: hidden;
}

.stream-line::after {
    content: '';
    position: absolute;
    left: -50%;
    top: 0;
    width: 50%;
    height: 100%;
    background: linear-gradient(90deg, transparent, var(--color-accent), transparent);
    animation: streamFlow 2s linear infinite;
}

@keyframes streamPulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; background: var(--color-accent); }
}

@keyframes streamFlow {
    0% { left: -50%; }
    100% { left: 150%; }
}

/* ===================
   Network Animation
   =================== */
.network-animation {
    position: relative;
    height: 100%;
}

.network-node {
    position: absolute;
    width: 28px;
    height: 28px;
    background: var(--color-bg-elevated);
    border: 2px solid var(--surface-border-strong);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.network-node::after {
    content: '';
    width: 10px;
    height: 10px;
    background: var(--text-muted);
    border-radius: 3px;
}

.network-node:nth-child(2) { top: 15%; left: 10%; }
.network-node:nth-child(3) { top: 55%; left: 8%; }
.network-node:nth-child(4) { top: 35%; left: 50%; transform: translateX(-50%); }
.network-node:nth-child(5) { top: 15%; right: 10%; }
.network-node:nth-child(6) { top: 55%; right: 8%; }

.network-node.center {
    border-color: var(--color-accent);
    box-shadow: 0 0 16px var(--color-accent-glow);
}

.network-node.center::after {
    background: var(--color-accent);
}

.network-lines {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.network-lines svg {
    width: 100%;
    height: 100%;
}

.network-lines line {
    stroke: var(--surface-border-strong);
    stroke-width: 2;
    stroke-dasharray: 100;
    stroke-dashoffset: 100;
    animation: networkConnect 4s ease-out infinite;
}

.network-lines line:nth-child(1) { animation-delay: 0s; }
.network-lines line:nth-child(2) { animation-delay: 0.3s; }
.network-lines line:nth-child(3) { animation-delay: 0.6s; }
.network-lines line:nth-child(4) { animation-delay: 0.9s; }

@keyframes networkConnect {
    0%, 10% { stroke-dashoffset: 100; stroke: var(--surface-border-strong); }
    40%, 70% { stroke-dashoffset: 0; stroke: var(--color-accent); }
    90%, 100% { stroke-dashoffset: 100; stroke: var(--surface-border-strong); }
}

/* ===================
   Checklist Animation
   =================== */
.checklist-animation {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 14px;
}

.check-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.check-box {
    width: 16px;
    height: 16px;
    border: 2px solid var(--surface-border-strong);
    border-radius: 4px;
    position: relative;
    transition: all 0.3s ease;
}

.check-box::after {
    content: '';
    position: absolute;
    left: 4px;
    top: 1px;
    width: 4px;
    height: 7px;
    border-right: 2px solid white;
    border-bottom: 2px solid white;
    transform: rotate(45deg) scale(0);
    opacity: 0;
}

.check-line {
    height: 5px;
    background: var(--text-muted);
    border-radius: 3px;
    flex: 1;
}

.check-item:nth-child(1) .check-box { animation: checkBox 6s ease-in-out infinite 0s; }
.check-item:nth-child(2) .check-box { animation: checkBox 6s ease-in-out infinite 0.5s; }
.check-item:nth-child(3) .check-box { animation: checkBox 6s ease-in-out infinite 1s; }
.check-item:nth-child(4) .check-box { animation: checkBox 6s ease-in-out infinite 1.5s; }

.check-item:nth-child(1) .check-box::after { animation: checkMark 6s ease-in-out infinite 0s; }
.check-item:nth-child(2) .check-box::after { animation: checkMark 6s ease-in-out infinite 0.5s; }
.check-item:nth-child(3) .check-box::after { animation: checkMark 6s ease-in-out infinite 1s; }
.check-item:nth-child(4) .check-box::after { animation: checkMark 6s ease-in-out infinite 1.5s; }

@keyframes checkBox {
    0%, 30% { background: transparent; border-color: var(--surface-border-strong); }
    40%, 70% { background: #22c55e; border-color: #22c55e; }
    85%, 100% { background: transparent; border-color: var(--surface-border-strong); }
}

@keyframes checkMark {
    0%, 35% { transform: rotate(45deg) scale(0); opacity: 0; }
    45%, 70% { transform: rotate(45deg) scale(1); opacity: 1; }
    85%, 100% { transform: rotate(45deg) scale(0); opacity: 0; }
}

/* ===================
   Communication Animation
   =================== */
.comms-animation {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.comms-hub {
    width: 40px;
    height: 40px;
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
}

.comms-hub svg {
    position: absolute;
    width: 40px;
    height: 40px;
    top: 0;
    left: 0;
}

.comms-hub svg path {
    fill: var(--color-accent);
}

.comms-dots {
    position: relative;
    z-index: 1;
    display: flex;
    gap: 4px;
    margin-top: -4px;
}

.comms-dots span {
    width: 5px;
    height: 5px;
    background: white;
    border-radius: 50%;
}

.msg-bubble {
    position: absolute;
    width: 22px;
    height: 16px;
    opacity: 0;
}

.msg-bubble::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--color-bg-elevated);
    border: 2px solid var(--surface-border-strong);
    border-radius: 8px;
}

.msg-bubble::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 3px;
    height: 3px;
    background: var(--text-muted);
    border-radius: 50%;
    box-shadow: -4px 0 0 var(--text-muted), 4px 0 0 var(--text-muted);
}

.msg-bubble:nth-child(2) { top: 15%; left: 10%; animation: msgSendFallback1 4s ease-out infinite 0s; }
.msg-bubble:nth-child(3) { top: 30%; left: 5%; animation: msgSendFallback2 4s ease-out infinite 0.3s; }
.msg-bubble:nth-child(4) { top: 55%; left: 8%; animation: msgSendFallback3 4s ease-out infinite 0.6s; }
.msg-bubble:nth-child(5) { top: 15%; right: 10%; animation: msgSendFallback4 4s ease-out infinite 0.15s; }
.msg-bubble:nth-child(6) { top: 35%; right: 5%; animation: msgSendFallback5 4s ease-out infinite 0.45s; }
.msg-bubble:nth-child(7) { top: 55%; right: 8%; animation: msgSendFallback6 4s ease-out infinite 0.75s; }

@keyframes msgSendFallback1 {
    0%, 10% { opacity: 0; transform: translate(50px, 25px) scale(0.5); }
    30%, 60% { opacity: 1; transform: translate(0, 0) scale(1); }
    80%, 100% { opacity: 0; transform: translate(0, 0) scale(0.8); }
}
@keyframes msgSendFallback2 {
    0%, 10% { opacity: 0; transform: translate(60px, 15px) scale(0.5); }
    30%, 60% { opacity: 1; transform: translate(0, 0) scale(1); }
    80%, 100% { opacity: 0; transform: translate(0, 0) scale(0.8); }
}
@keyframes msgSendFallback3 {
    0%, 10% { opacity: 0; transform: translate(55px, -15px) scale(0.5); }
    30%, 60% { opacity: 1; transform: translate(0, 0) scale(1); }
    80%, 100% { opacity: 0; transform: translate(0, 0) scale(0.8); }
}
@keyframes msgSendFallback4 {
    0%, 10% { opacity: 0; transform: translate(-50px, 25px) scale(0.5); }
    30%, 60% { opacity: 1; transform: translate(0, 0) scale(1); }
    80%, 100% { opacity: 0; transform: translate(0, 0) scale(0.8); }
}
@keyframes msgSendFallback5 {
    0%, 10% { opacity: 0; transform: translate(-60px, 10px) scale(0.5); }
    30%, 60% { opacity: 1; transform: translate(0, 0) scale(1); }
    80%, 100% { opacity: 0; transform: translate(0, 0) scale(0.8); }
}
@keyframes msgSendFallback6 {
    0%, 10% { opacity: 0; transform: translate(-50px, -15px) scale(0.5); }
    30%, 60% { opacity: 1; transform: translate(0, 0) scale(1); }
    80%, 100% { opacity: 0; transform: translate(0, 0) scale(0.8); }
}

/* ===================
   Inventory Animation
   =================== */
.inventory-animation {
    display: flex;
    gap: 10px;
    padding: 14px;
    height: 100%;
    align-items: flex-end;
}

.inv-bar-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.inv-bar-container {
    width: 100%;
    height: 85px;
    background: var(--surface-border);
    border-radius: 4px;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
}

.inv-bar {
    width: 100%;
    background: var(--text-muted);
    border-radius: 4px 4px 0 0;
}

.inv-bar-group:nth-child(1) .inv-bar { animation: invLevel1 6s ease-in-out infinite; }
.inv-bar-group:nth-child(2) .inv-bar { animation: invLevel2 6s ease-in-out infinite 0.5s; }
.inv-bar-group:nth-child(3) .inv-bar { animation: invLevel3 6s ease-in-out infinite 1s; }
.inv-bar-group:nth-child(4) .inv-bar { animation: invLevel4 6s ease-in-out infinite 1.5s; }

.inv-label {
    width: 20px;
    height: 3px;
    background: var(--surface-border);
    border-radius: 2px;
}

.inv-alert {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 6px;
    height: 6px;
    background: #f59e0b;
    border-radius: 50%;
    opacity: 0;
}

.inv-bar-group:nth-child(2) .inv-alert { animation: invAlert 6s ease-in-out infinite 0.5s; }

@keyframes invLevel1 {
    0%, 100% { height: 70%; background: #22c55e; }
    50% { height: 80%; background: #22c55e; }
}

@keyframes invLevel2 {
    0%, 20% { height: 60%; background: var(--text-muted); }
    30%, 40% { height: 25%; background: #f59e0b; }
    60%, 100% { height: 85%; background: #22c55e; }
}

@keyframes invLevel3 {
    0%, 100% { height: 45%; background: var(--text-muted); }
    50% { height: 55%; background: var(--text-muted); }
}

@keyframes invLevel4 {
    0%, 100% { height: 90%; background: #22c55e; }
    50% { height: 75%; background: #22c55e; }
}

@keyframes invAlert {
    0%, 25% { opacity: 0; }
    30%, 55% { opacity: 1; }
    60%, 100% { opacity: 0; }
}

/* ===================
   Website Animation
   =================== */
.website-animation {
    padding: 10px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.browser-frame {
    flex: 1;
    background: var(--color-bg-elevated);
    border: 1px solid var(--surface-border-strong);
    border-radius: 6px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.browser-bar {
    height: 18px;
    background: var(--color-bg-subtle);
    border-bottom: 1px solid var(--surface-border);
    display: flex;
    align-items: center;
    padding: 0 8px;
    gap: 4px;
}

.browser-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--surface-border-strong);
}

.browser-dot:nth-child(1) { background: #f87171; }
.browser-dot:nth-child(2) { background: #fbbf24; }
.browser-dot:nth-child(3) { background: #34d399; }

.browser-content {
    flex: 1;
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.web-header {
    height: 12px;
    background: var(--color-accent);
    border-radius: 3px;
    opacity: 0;
    animation: webBuild 5s ease-out infinite;
}

.web-hero {
    height: 24px;
    background: var(--surface-border);
    border-radius: 3px;
    opacity: 0;
    animation: webBuild 5s ease-out infinite 0.2s;
}

.web-content-row {
    display: flex;
    gap: 5px;
}

.web-block {
    flex: 1;
    height: 16px;
    background: var(--surface-border);
    border-radius: 3px;
    opacity: 0;
}

.web-content-row:nth-child(3) .web-block:nth-child(1) { animation: webBuild 5s ease-out infinite 0.4s; }
.web-content-row:nth-child(3) .web-block:nth-child(2) { animation: webBuild 5s ease-out infinite 0.5s; }
.web-content-row:nth-child(3) .web-block:nth-child(3) { animation: webBuild 5s ease-out infinite 0.6s; }

.web-content-row:nth-child(4) .web-block:nth-child(1) { animation: webBuild 5s ease-out infinite 0.7s; }
.web-content-row:nth-child(4) .web-block:nth-child(2) { animation: webBuild 5s ease-out infinite 0.8s; }

@keyframes webBuild {
    0%, 10% { opacity: 0; transform: translateY(4px); }
    25%, 75% { opacity: 1; transform: translateY(0); }
    90%, 100% { opacity: 0; transform: translateY(-4px); }
}

/* Bento animated responsive */
@media (max-width: 1024px) {
    .bento-card.bento-animated {
        grid-column: span 3;
        min-height: 200px;
    }

    .card-animation {
        height: 120px;
    }
}

@media (max-width: 600px) {
    .bento-card.bento-animated {
        grid-column: span 1;
        min-height: 180px;
    }

    .card-animation {
        height: 110px;
    }
}

/* ==========================================================================
   Approach - Timeline
   ========================================================================== */

.approach {
    background: var(--color-bg);
}

.approach-timeline {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-xl);
    position: relative;
}

.timeline-track {
    position: absolute;
    top: 5px;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--surface-border-strong);
}

.approach-step {
    position: relative;
    padding-top: var(--space-2xl);
}

.timeline-dot {
    position: absolute;
    top: 0;
    left: 0;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--color-bg);
    border: 1px solid var(--text-muted);
    z-index: 1;
}

.approach-step h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: var(--space-xs);
    letter-spacing: -0.01em;
    color: var(--text-primary);
}

.approach-step p {
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 400;
    line-height: 1.6;
}

/* ==========================================================================
   Visual Story Section
   ========================================================================== */

.visual-story {
    background: var(--color-bg-subtle);
    padding: var(--space-2xl) 0;
}

.visual-story .container {
    overflow: visible;
}

.visual-story-grid {
    display: flex;
    flex-direction: column;
    gap: var(--space-2xl);
    max-width: 100%;
}

.visual-story-item {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-2xl);
    align-items: center;
    max-width: 100%;
}

/* Alternate layout: second item has text on left, animation on right */
.visual-story-item:nth-child(even) {
    direction: rtl;
}

.visual-story-item:nth-child(even) > * {
    direction: ltr;
}

.visual-story-content {
    padding-top: var(--space-lg);
}

.visual-story-animation {
    position: relative;
    height: 450px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
}

.visual-story-content {
    display: flex;
    flex-direction: column;
}

.visual-story-item h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: var(--space-sm);
    letter-spacing: -0.02em;
    color: var(--text-primary);
}

.visual-story-item p {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.7;
}

/* Left Animation - Light Theme Adjustments */
.anim-left {
    position: relative;
    width: 520px;
    height: 450px;
    flex-shrink: 0;
}

.anim-left .data-field {
    position: relative;
    width: 100%;
    height: 100%;
}

.anim-left .data-point {
    position: absolute;
    width: 8px;
    height: 8px;
    background: var(--text-muted);
    border-radius: 2px;
    left: -100px;
    top: -100px;
    animation: organizePoint 8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

.anim-left .data-point.accent {
    background: var(--color-accent);
    box-shadow: 0 0 10px var(--color-accent-glow);
}

.anim-left .data-point.large {
    width: 12px;
    height: 12px;
}

.anim-left .data-point.bar {
    width: 40px;
    height: 6px;
    border-radius: 3px;
}

/* Data point positions - keeping from original */
.anim-left .data-point:nth-child(1) { --start-x: 20px; --start-y: 280px; --end-x: 50px; --end-y: 45px; }
.anim-left .data-point:nth-child(2) { --start-x: 380px; --start-y: 30px; --end-x: 95px; --end-y: 45px; animation-delay: 0.05s; }
.anim-left .data-point:nth-child(3) { --start-x: 150px; --start-y: 310px; --end-x: 140px; --end-y: 45px; animation-delay: 0.1s; }
.anim-left .data-point:nth-child(4) { --start-x: 420px; --start-y: 180px; --end-x: 185px; --end-y: 45px; animation-delay: 0.15s; }
.anim-left .data-point:nth-child(5) { --start-x: 60px; --start-y: 60px; --end-x: 230px; --end-y: 45px; animation-delay: 0.2s; }
.anim-left .data-point:nth-child(6) { --start-x: 300px; --start-y: 290px; --end-x: 50px; --end-y: 75px; animation-delay: 0.25s; }
.anim-left .data-point:nth-child(7) { --start-x: 40px; --start-y: 200px; --end-x: 95px; --end-y: 75px; animation-delay: 0.3s; }
.anim-left .data-point:nth-child(8) { --start-x: 400px; --start-y: 100px; --end-x: 140px; --end-y: 75px; animation-delay: 0.35s; }
.anim-left .data-point:nth-child(9) { --start-x: 200px; --start-y: 20px; --end-x: 185px; --end-y: 75px; animation-delay: 0.4s; }
.anim-left .data-point:nth-child(10) { --start-x: 100px; --start-y: 270px; --end-x: 230px; --end-y: 75px; animation-delay: 0.45s; }
.anim-left .data-point:nth-child(11) { --start-x: 350px; --start-y: 150px; --end-x: 50px; --end-y: 105px; animation-delay: 0.5s; }
.anim-left .data-point:nth-child(12) { --start-x: 25px; --start-y: 120px; --end-x: 95px; --end-y: 105px; animation-delay: 0.55s; }
.anim-left .data-point:nth-child(13) { --start-x: 430px; --start-y: 250px; --end-x: 140px; --end-y: 105px; animation-delay: 0.6s; }
.anim-left .data-point:nth-child(14) { --start-x: 180px; --start-y: 300px; --end-x: 185px; --end-y: 105px; animation-delay: 0.65s; }
.anim-left .data-point:nth-child(15) { --start-x: 280px; --start-y: 40px; --end-x: 230px; --end-y: 105px; animation-delay: 0.7s; }
.anim-left .data-point:nth-child(16) { --start-x: 380px; --start-y: 300px; --end-x: 50px; --end-y: 135px; animation-delay: 0.75s; }
.anim-left .data-point:nth-child(17) { --start-x: 70px; --start-y: 160px; --end-x: 95px; --end-y: 135px; animation-delay: 0.8s; }
.anim-left .data-point:nth-child(18) { --start-x: 320px; --start-y: 80px; --end-x: 140px; --end-y: 135px; animation-delay: 0.85s; }
.anim-left .data-point:nth-child(19) { --start-x: 130px; --start-y: 240px; --end-x: 185px; --end-y: 135px; animation-delay: 0.9s; }
.anim-left .data-point:nth-child(20) { --start-x: 450px; --start-y: 130px; --end-x: 230px; --end-y: 135px; animation-delay: 0.95s; }
.anim-left .data-point:nth-child(21) { --start-x: 250px; --start-y: 280px; --end-x: 50px; --end-y: 165px; animation-delay: 1s; }
.anim-left .data-point:nth-child(22) { --start-x: 15px; --start-y: 80px; --end-x: 95px; --end-y: 165px; animation-delay: 1.05s; }
.anim-left .data-point:nth-child(23) { --start-x: 360px; --start-y: 200px; --end-x: 140px; --end-y: 165px; animation-delay: 1.1s; }
.anim-left .data-point:nth-child(24) { --start-x: 90px; --start-y: 320px; --end-x: 185px; --end-y: 165px; animation-delay: 1.15s; }
.anim-left .data-point:nth-child(25) { --start-x: 410px; --start-y: 60px; --end-x: 230px; --end-y: 165px; animation-delay: 1.2s; }
.anim-left .data-point:nth-child(26) { --start-x: 320px; --start-y: 210px; --end-x: 435px; --end-y: 45px; animation-delay: 0.5s; }
.anim-left .data-point:nth-child(27) { --start-x: 40px; --start-y: 40px; --end-x: 435px; --end-y: 80px; animation-delay: 0.7s; }
.anim-left .data-point:nth-child(28) { --start-x: 170px; --start-y: 250px; --end-x: 435px; --end-y: 115px; animation-delay: 0.9s; }
.anim-left .data-point:nth-child(29) { --start-x: 280px; --start-y: 120px; --end-x: 435px; --end-y: 150px; animation-delay: 1.1s; }
.anim-left .data-point:nth-child(30) { --start-x: 210px; --start-y: 170px; --end-x: 485px; --end-y: 45px; animation-delay: 0.4s; }
.anim-left .data-point:nth-child(31) { --start-x: 85px; --start-y: 125px; --end-x: 485px; --end-y: 80px; animation-delay: 0.6s; }
.anim-left .data-point:nth-child(32) { --start-x: 340px; --start-y: 260px; --end-x: 485px; --end-y: 115px; animation-delay: 0.8s; }
.anim-left .data-point:nth-child(33) { --start-x: 150px; --start-y: 300px; --end-x: 485px; --end-y: 150px; animation-delay: 1.0s; }

@keyframes organizePoint {
    0%, 15% { left: var(--start-x); top: var(--start-y); opacity: 0.3; transform: scale(0.8); }
    20% { opacity: 0.6; }
    50%, 85% { left: var(--end-x); top: var(--end-y); opacity: 1; transform: scale(1); }
    90% { opacity: 0.6; }
    100% { left: var(--start-x); top: var(--start-y); opacity: 0.3; transform: scale(0.8); }
}

.anim-left .grid-overlay {
    position: absolute;
    top: 30px;
    left: 30px;
    width: 240px;
    height: 165px;
    border: 1px solid var(--surface-border-strong);
    border-radius: 8px;
    opacity: 0;
    animation: fadeGridOverlay 8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

.anim-left .chart-area {
    position: absolute;
    top: 30px;
    left: 425px;
    width: 85px;
    height: 165px;
    border: 1px solid var(--surface-border-strong);
    border-radius: 8px;
    opacity: 0;
    animation: fadeGridOverlay 8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
    animation-delay: 0.3s;
}

@keyframes fadeGridOverlay {
    0%, 30% { opacity: 0; }
    45%, 80% { opacity: 1; }
    95%, 100% { opacity: 0; }
}

.anim-left .scan-line {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent 0%, var(--color-accent) 50%, transparent 100%);
    opacity: 0;
    animation: scanDown 8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

@keyframes scanDown {
    0%, 5% { top: 0; opacity: 0; }
    10% { opacity: 0.6; }
    40% { top: 100%; opacity: 0.6; }
    45%, 100% { top: 100%; opacity: 0; }
}

/* Right Animation - Workflow */
.anim-right {
    position: relative;
    width: 480px;
    height: 450px;
    flex-shrink: 0;
}

.anim-right .workflow-diagram {
    position: relative;
    width: 480px;
    height: 340px;
}

.anim-right .node {
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-bg-elevated);
    border: 1px solid var(--surface-border-strong);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.anim-right .node-terminal {
    width: 70px;
    height: 32px;
    background: linear-gradient(135deg, #CE1513 0%, #E63946 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    box-shadow: 0 2px 12px var(--color-accent-glow);
}

.anim-right .node-terminal .node-inner {
    width: 38px;
    height: 4px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 2px;
}

.anim-right .node-process {
    width: 80px;
    height: 44px;
    background: var(--color-bg-elevated);
    border: 1px solid var(--surface-border-strong);
    border-radius: 6px;
}

.anim-right .node-process .node-inner {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
}

.anim-right .node-process .node-inner::before,
.anim-right .node-process .node-inner::after {
    content: '';
    display: block;
    height: 3px;
    background: var(--text-muted);
    border-radius: 1.5px;
}

.anim-right .node-process .node-inner::before { width: 44px; }
.anim-right .node-process .node-inner::after { width: 30px; }

.anim-right .node-decision {
    width: 36px;
    height: 36px;
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-accent);
    border-radius: 4px;
    transform: rotate(45deg);
    box-shadow: 0 2px 8px var(--color-accent-glow);
}

.anim-right .node-decision .node-inner {
    width: 3px;
    height: 10px;
    background: var(--color-accent);
    border-radius: 1.5px;
    transform: rotate(-45deg);
    opacity: 0.8;
}

/* Node positions */
.anim-right .node-1 { top: 25px; left: 30px; }
.anim-right .node-2 { top: 18px; left: 130px; }
.anim-right .node-3 { top: 18px; left: 245px; }
.anim-right .node-4 { top: 85px; left: 295px; }
.anim-right .node-5 { top: 75px; left: 380px; }
.anim-right .node-6 { top: 150px; left: 390px; }
.anim-right .node-7 { top: 150px; left: 260px; }
.anim-right .node-8 { top: 225px; left: 210px; }
.anim-right .node-9 { top: 285px; left: 130px; }
.anim-right .node-10 { top: 235px; left: 380px; }

.anim-right .connections {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.anim-right .connections path {
    stroke: var(--surface-border-strong);
    stroke-width: 1;
    fill: none;
    stroke-linecap: round;
}

.anim-right .connections marker polygon {
    fill: var(--text-muted);
}

/* Magnifier */
.anim-right .magnifier {
    position: absolute;
    width: 85px;
    height: 85px;
    pointer-events: none;
    z-index: 10;
    animation: scanWorkflowRight 10s cubic-bezier(0.16, 1, 0.3, 1) infinite;
}

.anim-right .magnifier-glass {
    position: relative;
    width: 50px;
    height: 50px;
}

.anim-right .magnifier-lens {
    position: absolute;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    border: 2px solid var(--surface-border-strong);
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.1);
}

.anim-right .magnifier-lens::before {
    content: '';
    position: absolute;
    top: 4px;
    left: 8px;
    width: 16px;
    height: 6px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.5) 0%, transparent 100%);
    border-radius: 50%;
    transform: rotate(-20deg);
}

.anim-right .magnifier-handle {
    position: absolute;
    bottom: 4px;
    right: -8px;
    width: 26px;
    height: 6px;
    background: linear-gradient(180deg, var(--text-muted) 0%, var(--text-tertiary) 100%);
    border: 1px solid var(--surface-border);
    border-radius: 3px;
    transform: rotate(45deg);
    transform-origin: left center;
}

.anim-right .magnifier-glow {
    position: absolute;
    top: -4px;
    left: -4px;
    width: 58px;
    height: 58px;
    border: 1px solid rgba(206, 21, 19, 0.2);
    border-radius: 50%;
    animation: pulseGlowRight 2s ease-in-out infinite;
}

@keyframes pulseGlowRight {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.04); opacity: 0.8; }
}

@keyframes scanWorkflowRight {
    0%, 3% { top: 8px; left: 0px; opacity: 0; }
    6% { opacity: 1; }
    10%, 16% { top: 5px; left: 100px; }
    22%, 28% { top: 5px; left: 210px; }
    34%, 40% { top: 62px; left: 260px; }
    46%, 52% { top: 128px; left: 225px; }
    58%, 64% { top: 200px; left: 175px; }
    70%, 76% { top: 260px; left: 100px; }
    85% { opacity: 1; }
    92%, 100% { top: 260px; left: 100px; opacity: 0; }
}

.anim-right .data-dot {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--color-accent);
    border-radius: 50%;
    box-shadow: 0 0 8px var(--color-accent-glow);
    opacity: 0;
    z-index: 5;
    left: -100px;
    top: -100px;
}

.anim-right .workflow-diagram>.data-dot:nth-child(12) { animation: flowDotR1 5s linear infinite; }
.anim-right .workflow-diagram>.data-dot:nth-child(13) { animation: flowDotR2 5s linear infinite; animation-delay: 1.6s; }
.anim-right .workflow-diagram>.data-dot:nth-child(14) { animation: flowDotR3 5s linear infinite; animation-delay: 3.2s; }

@keyframes flowDotR1 {
    0% { top: 41px; left: 100px; opacity: 0; }
    5% { opacity: 1; }
    20% { top: 40px; left: 130px; }
    40% { top: 40px; left: 245px; }
    60% { top: 103px; left: 313px; }
    80% { top: 97px; left: 380px; }
    95% { opacity: 1; }
    100% { top: 150px; left: 390px; opacity: 0; }
}

@keyframes flowDotR2 {
    0% { top: 103px; left: 313px; opacity: 0; }
    5% { opacity: 1; }
    50% { top: 172px; left: 300px; }
    95% { opacity: 1; }
    100% { top: 247px; left: 250px; opacity: 0; }
}

@keyframes flowDotR3 {
    0% { top: 172px; left: 300px; opacity: 0; }
    5% { opacity: 1; }
    50% { top: 247px; left: 210px; }
    95% { opacity: 1; }
    100% { top: 301px; left: 165px; opacity: 0; }
}

@media (max-width: 1100px) {
    .visual-story-item {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
        text-align: center;
    }
    .visual-story-item:nth-child(even) {
        direction: ltr;
    }
    .visual-story-content {
        padding-top: 0;
    }
    .visual-story-animation { height: 380px; }
    .anim-left, .anim-right { transform: scale(0.85); }
}

@media (max-width: 700px) {
    .visual-story-animation { height: 340px; }
    .anim-left, .anim-right { transform: scale(0.75); }
}

@media (max-width: 550px) {
    .visual-story { padding: var(--space-2xl) 0; }
    .visual-story-animation { height: 280px; }
    .anim-left, .anim-right { transform: scale(0.6); }
}

@media (max-width: 450px) {
    .visual-story-grid { gap: var(--space-xl); }
    .visual-story-animation { height: 240px; }
    .anim-left, .anim-right { transform: scale(0.5); }
}

/* ==========================================================================
   About
   ========================================================================== */

.about {
    background: var(--color-bg);
}

.about-content {
    max-width: 640px;
}

.about-content p {
    color: var(--text-secondary);
    margin-bottom: var(--space-md);
    font-size: 1.125rem;
    font-weight: 400;
    line-height: 1.7;
}

.about-lead {
    color: var(--text-primary) !important;
    font-size: 1.5rem !important;
    font-weight: 500 !important;
    letter-spacing: -0.02em;
    margin-bottom: var(--space-lg) !important;
}

.about-tagline {
    color: var(--text-primary) !important;
    font-weight: 500;
    font-size: 1.125rem;
    letter-spacing: -0.01em;
}

/* ==========================================================================
   Contact
   ========================================================================== */

.contact {
    background:
        radial-gradient(ellipse 60% 60% at 50% 100%, rgba(206, 21, 19, 0.06) 0%, transparent 50%),
        var(--color-bg-subtle);
}

.contact-content {
    margin-top: var(--space-xl);
}

.contact-options {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-xl);
    margin-top: var(--space-lg);
    max-width: 600px;
}

.contact-option {
    background: var(--color-bg-elevated);
    border: 1px solid var(--surface-border-strong);
    border-radius: 12px;
    padding: var(--space-lg);
}

.contact-option h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: var(--space-sm);
    color: var(--text-primary);
}

.contact-option p {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-bottom: var(--space-md);
    line-height: 1.5;
}

/* Contact Form */
.contact-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-sm);
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.form-group label {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 0.75rem 1rem;
    font-size: 0.9375rem;
    font-family: inherit;
    background: var(--color-bg);
    border: 1px solid var(--surface-border-strong);
    border-radius: 8px;
    color: var(--text-primary);
    transition: all var(--duration-fast) ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px var(--color-accent-soft);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

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

/* Honeypot - hidden from humans */
.ohnohoney {
    position: absolute;
    left: -9999px;
    opacity: 0;
    height: 0;
    width: 0;
}

.btn-submit {
    align-self: flex-start;
    margin-top: var(--space-xs);
}

.btn-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Form success state */
.form-success {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: var(--space-xl) var(--space-lg);
    gap: var(--space-sm);
    color: var(--text-primary);
}

.form-success svg {
    color: var(--color-accent);
}

.form-success h4 {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.form-success p {
    color: var(--text-secondary);
    margin: 0;
}

/* Form error state */
.form-error {
    color: #dc2626;
    font-size: 0.875rem;
    margin: var(--space-xs) 0;
}

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

/* Direct email option */
.contact-email {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    font-size: clamp(0.9375rem, 2vw, 1.125rem);
    font-weight: 500;
    letter-spacing: -0.01em;
    color: var(--text-primary);
    padding: var(--space-sm) var(--space-lg);
    background: var(--color-bg);
    border: 1px solid var(--surface-border-strong);
    border-radius: 12px;
    transition: all var(--duration-normal) var(--ease-out-expo);
}

.contact-email:hover {
    background: var(--color-bg-subtle);
    border-color: var(--color-accent);
    box-shadow: 0 0 20px -10px var(--color-accent-glow);
}

.contact-note {
    margin-top: var(--space-md);
    font-size: 0.8125rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-tertiary);
}

@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer {
    background: var(--color-bg);
    padding: var(--space-lg) 0;
    border-top: 1px solid var(--surface-border);
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: var(--space-sm);
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.footer-brand img {
    width: 24px;
    height: 24px;
    opacity: 0.7;
}

.footer-copyright {
    font-size: 0.8125rem;
    color: var(--text-tertiary);
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 900px) {
    .approach-timeline {
        grid-template-columns: 1fr;
        gap: 0;
        position: relative;
        padding-left: var(--space-lg);
    }

    .timeline-track {
        position: absolute;
        top: 0;
        bottom: 0;
        left: 5px;
        width: 1px;
        height: 100%;
    }

    .approach-step {
        padding-top: 0;
        padding-bottom: var(--space-xl);
        position: relative;
    }

    .approach-step:last-child {
        padding-bottom: 0;
    }

    .timeline-dot {
        position: absolute;
        left: calc(-1 * var(--space-lg) + -1px);
        top: 0.25rem;
    }
}

@media (max-width: 768px) {
    :root {
        --container-padding: 1rem;
    }

    section {
        padding: var(--space-2xl) 0;
    }

    .header {
        padding: var(--space-sm);
    }

    .header-inner {
        padding: 0.5rem 1rem;
    }

    .scrolled .header-inner {
        max-width: 100%;
        border-radius: 16px;
    }

    .nav-links {
        display: none;
    }

    .hero {
        padding-top: 120px;
    }

    .hero h1 {
        font-size: 1.5rem;
    }

    .typing {
        font-size: 0.8em;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 420px) {
    .typing {
        font-size: 0.75em;
    }
}

/* ==========================================================================
   Animations
   ========================================================================== */

@keyframes fadeInUp {
    from { opacity: 0; filter: blur(8px); transform: translateY(30px); }
    to { opacity: 1; filter: blur(0); transform: translateY(0); }
}

@keyframes typing {
    0%, 5% { max-width: 0; }
    35% { max-width: 800px; }
    65% { max-width: 800px; }
    95%, 100% { max-width: 0; }
}

@keyframes cursorBlink {
    0%, 50% { visibility: visible; }
    51%, 100% { visibility: hidden; }
}

@keyframes cursorShow {
    0%, 5% { opacity: 0; }
    6%, 65% { opacity: 0.4; }
    66%, 100% { opacity: 0; }
}

.hero h1 {
    animation: fadeInUp 0.8s var(--ease-out-expo) 0.2s both;
}

.typing-wrapper {
    display: block;
    margin-top: 0.1em;
}

.typing {
    display: inline-block;
    max-width: 0;
    overflow: hidden;
    white-space: nowrap;
    vertical-align: bottom;
    font-weight: 400;
    animation: typing 6s steps(30, end) 0.4s infinite;
}

.cursor {
    display: inline-block;
    width: 0.6em;
    height: 3px;
    background: var(--color-accent);
    opacity: 0.1;
    vertical-align: baseline;
    margin-left: 2px;
    border-radius: 1px;
    position: relative;
    top: 0.15em;
    animation: cursorShow 6s ease 0.4s infinite, cursorBlink 0.5s step-end infinite;
}

.hero-bottom {
    animation: fadeInUp 0.8s var(--ease-out-expo) 0.2s both;
}

/* Timeline dot animations */
@keyframes dotCycle1 {
    0%, 3% { background: var(--color-bg); border-color: var(--text-muted); box-shadow: none; }
    8%, 20% { background: var(--color-accent); border-color: var(--color-accent); box-shadow: 0 0 12px var(--color-accent-glow); }
    25%, 100% { background: var(--color-bg); border-color: var(--text-muted); box-shadow: none; }
}

@keyframes dotCycle2 {
    0%, 25% { background: var(--color-bg); border-color: var(--text-muted); box-shadow: none; }
    30%, 45% { background: var(--color-accent); border-color: var(--color-accent); box-shadow: 0 0 12px var(--color-accent-glow); }
    50%, 100% { background: var(--color-bg); border-color: var(--text-muted); box-shadow: none; }
}

@keyframes dotCycle3 {
    0%, 50% { background: var(--color-bg); border-color: var(--text-muted); box-shadow: none; }
    55%, 70% { background: var(--color-accent); border-color: var(--color-accent); box-shadow: 0 0 12px var(--color-accent-glow); }
    75%, 100% { background: var(--color-bg); border-color: var(--text-muted); box-shadow: none; }
}

@keyframes dotCycle4 {
    0%, 75% { background: var(--color-bg); border-color: var(--text-muted); box-shadow: none; }
    80%, 95% { background: var(--color-accent); border-color: var(--color-accent); box-shadow: 0 0 12px var(--color-accent-glow); }
    100% { background: var(--color-bg); border-color: var(--text-muted); box-shadow: none; }
}

.approach-step:nth-child(2) .timeline-dot { animation: dotCycle1 6s ease-in-out infinite; }
.approach-step:nth-child(3) .timeline-dot { animation: dotCycle2 6s ease-in-out infinite; }
.approach-step:nth-child(4) .timeline-dot { animation: dotCycle3 6s ease-in-out infinite; }
.approach-step:nth-child(5) .timeline-dot { animation: dotCycle4 6s ease-in-out infinite; }

/* Mockup animations */
@keyframes trendFill1 { 0%, 100% { width: 20px; } 50% { width: 45px; } }
@keyframes trendFill2 { 0%, 100% { width: 35px; } 50% { width: 25px; } }
@keyframes trendFill3 { 0%, 100% { width: 28px; } 50% { width: 42px; } }

.mock-stat-card:nth-child(1) .mock-stat-trend { animation: trendFill1 3s ease-in-out infinite; }
.mock-stat-card:nth-child(2) .mock-stat-trend { animation: trendFill2 3.5s ease-in-out infinite; }
.mock-stat-card:nth-child(3) .mock-stat-trend { animation: trendFill3 4s ease-in-out infinite; }
.mock-stat-card:nth-child(4) .mock-stat-trend { animation: trendFill1 2.8s ease-in-out infinite; animation-delay: 0.5s; }

@keyframes valuePulse {
    0%, 100% { opacity: 0.6; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.05); }
}

.mock-row-value { animation: valuePulse 2s ease-in-out infinite; }
.mock-row:nth-child(2) .mock-row-value { animation-delay: 0.7s; }
.mock-row:nth-child(3) .mock-row-value { animation-delay: 1.4s; }

@keyframes rowAppear {
    0%, 5% { opacity: 0; transform: translateY(8px); }
    20%, 60% { opacity: 1; transform: translateY(0); }
    75%, 100% { opacity: 0; transform: translateY(0); }
}

.mock-row { opacity: 0; animation: rowAppear 4s ease-out infinite; }
.mock-row:nth-child(2) { animation-delay: 0s; }
.mock-row:nth-child(3) { animation-delay: 0.25s; }
.mock-row:nth-child(4) { animation-delay: 0.5s; }
.mock-row:nth-child(5) { animation-delay: 0.75s; }

@keyframes alertPulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

.mock-alert { animation: alertPulse 3s ease-in-out infinite; }
.mock-alert:nth-child(2) { animation-delay: 1s; }
.mock-alert:nth-child(3) { animation-delay: 2s; }

/* ==========================================================================
   Theme Toggle
   ========================================================================== */

.theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--text-secondary);
    transition: color var(--duration-normal) ease, transform var(--duration-fast) ease;
}

.theme-toggle:hover {
    color: var(--text-primary);
}

.theme-toggle:active {
    transform: scale(0.95);
}

/* Icon visibility based on current theme */
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }

/* Dark mode: show sun, hide moon */
:root[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

/* System dark mode (no manual choice): show sun, hide moon */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) .theme-toggle .icon-sun { display: block; }
    :root:not([data-theme="light"]) .theme-toggle .icon-moon { display: none; }
}

/* Nav bar toggle */
.theme-toggle-nav {
    padding: 0.5rem;
    border-radius: 8px;
    margin-right: 0.5rem;
}

.theme-toggle-nav:hover {
    background: var(--color-accent-soft);
}

/* Smooth color transitions when theme changes */
body {
    transition: background-color var(--duration-slow) ease, color var(--duration-slow) ease;
}

.header-inner,
.track-record-item,
.contact-option,
.mockup-dashboard,
.visual-story-animation {
    transition: background-color var(--duration-slow) ease,
                border-color var(--duration-slow) ease,
                box-shadow var(--duration-slow) ease;
}
