/* Core Variables */
:root {
    --primary: #3955D6;
    --primary-dark: #2A41B8;
    --secondary: #18DCFF;
    --accent: #FF686B;
    --dark: #0F172A;
    --gray-dark: #1E293B;
    --gray: #64748B;
    --gray-light: #E2E8F0;
    --light: #F8FAFC;
    --success: #10B981;
    --warning: #F59E0B;
    --box-shadow: 0 4px 20px rgba(15, 23, 42, 0.08);
    --transition: all 0.3s ease;
}

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

/* Base Styles */
body {
    font-family: 'Inter', sans-serif;
    color: var(--dark);
    background-color: var(--light);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

section {
    padding: 3.5rem 0;
}

/* Typography */
h1, h2, h3, h4 {
    font-weight: 700;
    line-height: 1.2;
}

h1 {
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    letter-spacing: -0.03em;
}

h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    letter-spacing: -0.02em;
    margin-bottom: 1.5rem;
}

h3 {
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    letter-spacing: -0.01em;
    margin-bottom: 1rem;
}

p {
    margin-bottom: 1.5rem;
    font-size: 1.05rem;
}

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

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

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    padding: 0.8rem 1.8rem;
    border-radius: 0.5rem;
    font-weight: 500;
    font-size: 1rem;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    gap: 0.5rem;
}

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

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(57, 85, 214, 0.3);
}

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

.btn-outline:hover {
    background-color: var(--primary);
    color: white;
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: var(--light);
    color: var(--dark);
    border: 1.5px solid var(--gray-light);
}

.btn-secondary:hover {
    background-color: var(--gray-light);
    transform: translateY(-2px);
}

/* Header & Navigation */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background-color: rgba(248, 250, 252, 0.95);
    backdrop-filter: blur(12px);
    padding: 1rem 0;
    transition: var(--transition);
    border-bottom: 1px solid transparent;
}

.header.scrolled {
    border-bottom: 1px solid var(--gray-light);
    box-shadow: var(--box-shadow);
    padding: 0.75rem 0;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo img {
    height: 2.2rem;
    transition: transform 0.3s ease;
}

.logo img:hover {
    transform: scale(1.05);
}

.main-nav {
    display: none;
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.main-nav a {
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    transition: width 0.3s ease;
}

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

.nav-buttons {
    display: none;
    gap: 1rem;
}

/* Mobile Navigation */
.mobile-toggle {
    display: block;
    background: none;
    border: none;
    width: 2rem;
    height: 1.5rem;
    position: relative;
    cursor: pointer;
    z-index: 1001;
}

.mobile-toggle span {
    display: block;
    position: absolute;
    height: 2px;
    width: 100%;
    background: var(--dark);
    border-radius: 2px;
    opacity: 1;
    left: 0;
    transform: rotate(0deg);
    transition: .25s ease-in-out;
}

.mobile-toggle span:nth-child(1) {
    top: 0px;
}

.mobile-toggle span:nth-child(2), .mobile-toggle span:nth-child(3) {
    top: 8px;
}

.mobile-toggle span:nth-child(4) {
    top: 16px;
}

.mobile-toggle.open span:nth-child(1) {
    top: 8px;
    width: 0%;
    left: 50%;
}

.mobile-toggle.open span:nth-child(2) {
    transform: rotate(45deg);
}

.mobile-toggle.open span:nth-child(3) {
    transform: rotate(-45deg);
}

.mobile-toggle.open span:nth-child(4) {
    top: 8px;
    width: 0%;
    left: 50%;
}

.mobile-nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100vh;
    background-color: white;
    z-index: 1000;
    padding: 5rem 2rem 2rem;
    transition: right 0.3s ease;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

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

.mobile-nav ul {
    list-style: none;
    margin-bottom: 2rem;
}

.mobile-nav li {
    margin-bottom: 1.2rem;
}

.mobile-nav a {
    font-size: 1.5rem;
    font-weight: 600;
    display: block;
    padding: 0.5rem 0;
}

.mobile-nav-buttons {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

@media (min-width: 992px) {
    .main-nav, .nav-buttons {
        display: flex;
    }
    
    .mobile-toggle {
        display: none;
    }
}

/* Hero Section */
.hero-section {
    padding: 8rem 0 5rem;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(57, 85, 214, 0.05) 0%, rgba(24, 220, 255, 0.05) 100%);
}

/* Floating Ecommerce Icons */
.floating-icons {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 1;
}

.floating-icon {
    position: absolute;
    font-size: 2rem;
    opacity: 0.1;
    animation: floatAround 20s infinite ease-in-out;
}

@keyframes floatAround {
    0%, 100% {
        transform: translateY(0) translateX(0) rotate(0deg);
    }
    25% {
        transform: translateY(-20px) translateX(10px) rotate(5deg);
    }
    50% {
        transform: translateY(10px) translateX(-10px) rotate(-5deg);
    }
    75% {
        transform: translateY(-10px) translateX(5px) rotate(3deg);
    }
}

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

.company-intro {
    display: inline-block;
    background: linear-gradient(135deg, rgba(57, 85, 214, 0.1), rgba(24, 220, 255, 0.1));
    color: var(--primary);
    padding: 0.4rem 1rem;
    border-radius: 2rem;
    font-weight: 500;
    font-size: 0.95rem;
    margin-bottom: 1.5rem;
    animation: slideDown 0.6s ease;
}

.headline {
    margin-bottom: 1.5rem;
    animation: slideUp 0.8s ease;
}

.accent {
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-benefits {
    margin: 2rem 0;
}

.hero-benefit-item {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    align-items: flex-start;
    animation: fadeIn 1s ease;
    animation-fill-mode: both;
}

.hero-benefit-item:nth-child(1) { animation-delay: 0.2s; }
.hero-benefit-item:nth-child(2) { animation-delay: 0.4s; }
.hero-benefit-item:nth-child(3) { animation-delay: 0.6s; }

.benefit-icon {
    color: var(--primary);
    font-size: 1.2rem;
    background: linear-gradient(135deg, rgba(57, 85, 214, 0.15), rgba(24, 220, 255, 0.15));
    padding: 0.7rem;
    border-radius: 0.5rem;
    flex-shrink: 0;
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 0.5rem;
}

.cta-section {
    display: flex;
    gap: 1rem;
    margin: 2rem 0;
    flex-wrap: wrap;
    animation: fadeIn 1.2s ease;
}

.hero-badges {
    display: flex;
    flex-wrap: wrap;
    margin: 2rem 0;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    font-size: 0.85rem;
    font-weight: 500;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.7));
    border: 1px solid var(--gray-light);
    padding: 0.3rem 0.8rem;
    border-radius: 2rem;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
    transition: var(--transition);
}

.badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Hero Interactive Demo */
.hero-image {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.interactive-store-demo {
    width: 100%;
    max-width: 500px;
    animation: float 6s ease-in-out infinite;
}

.store-browser {
    background: white;
    border-radius: 1rem;
    box-shadow: 0 20px 60px rgba(15, 23, 42, 0.15);
    overflow: hidden;
    transform: perspective(1000px) rotateY(-5deg);
    transition: transform 0.3s ease;
}

.store-browser:hover {
    transform: perspective(1000px) rotateY(0deg);
}

.browser-header {
    background: linear-gradient(90deg, #f3f4f6, #e5e7eb);
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.browser-dots {
    display: flex;
    gap: 0.5rem;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red { background: #ef4444; }
.dot.yellow { background: #f59e0b; }
.dot.green { background: #10b981; }

.browser-url {
    flex: 1;
    background: white;
    padding: 0.3rem 0.8rem;
    border-radius: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--gray);
}

.store-preview {
    padding: 2rem;
    background: linear-gradient(135deg, #f8fafc, #e0e7ff);
    min-height: 300px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* Game Container */
.game-container {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    touch-action: none; /* Prevent scrolling while playing */
}

#gameCanvas {
    width: 100%;
    height: auto;
    border-radius: 0.5rem;
    background: linear-gradient(180deg, #87CEEB 0%, #98D8E8 100%);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    touch-action: none; /* Important for mobile gameplay */
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
}

/* Mobile-specific game styles */
@media (max-width: 768px) {
    .game-container {
        max-width: 100%;
        padding: 0 1rem;
    }
    
    #gameCanvas {
        border-radius: 0.5rem;
        margin-bottom: 1rem;
    }
    
    .game-controls {
        flex-wrap: wrap;
    }
    
    .game-btn {
        flex: 1;
        min-width: 120px;
    }
}

.game-controls {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 1rem;
}

.game-btn {
    padding: 0.5rem 1rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 0.9rem;
    transition: var(--transition);
}

.game-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

/* Code Animation */
.code-animation {
    font-family: 'Courier New', monospace;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.code-line {
    opacity: 0;
    transform: translateX(-20px);
    animation: codeType 0.5s ease forwards;
    color: var(--dark);
    font-size: 0.9rem;
}

.code-line:nth-child(1) { animation-delay: 0.2s; }
.code-line:nth-child(2) { animation-delay: 0.4s; }
.code-line:nth-child(3) { animation-delay: 0.6s; }
.code-line:nth-child(4) { animation-delay: 0.8s; }

/* Feature Grid */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    width: 100%;
}

.feature-tile {
    background: white;
    padding: 1.5rem;
    border-radius: 0.5rem;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    opacity: 0;
    transform: scale(0.9);
    animation: popIn 0.5s ease forwards;
}

.feature-tile:nth-child(1) { animation-delay: 1s; }
.feature-tile:nth-child(2) { animation-delay: 1.2s; }
.feature-tile:nth-child(3) { animation-delay: 1.4s; }
.feature-tile:nth-child(4) { animation-delay: 1.6s; }

.feature-tile i {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.feature-tile span {
    display: block;
    color: var(--gray);
    font-size: 0.9rem;
}

/* Store Stats */
.store-stats {
    position: absolute;
    top: 50%;
    left: -80px;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.stat-bubble {
    background: white;
    padding: 1rem;
    border-radius: 1rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    text-align: center;
    opacity: 0;
    transform: translateX(-20px);
    animation: slideInLeft 0.5s ease forwards;
}

.stat-bubble:nth-child(1) { animation-delay: 1.8s; }
.stat-bubble:nth-child(2) { animation-delay: 2s; }
.stat-bubble:nth-child(3) { animation-delay: 2.2s; }

.stat-value {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
}

.stat-label {
    display: block;
    font-size: 0.75rem;
    color: var(--gray);
    margin-top: 0.25rem;
}

@media (max-width: 768px) {
    .store-stats {
        position: static;
        flex-direction: row;
        justify-content: center;
        margin-top: 2rem;
        transform: none;
    }
}

/* Client Logos */
.client-logos {
    margin-top: 3rem;
    animation: fadeIn 1.5s ease;
}

.trusted-by {
    font-size: 0.9rem;
    color: var(--gray);
    margin-bottom: 1rem;
}

.logo-container {
    display: flex;
    gap: 2rem;
    align-items: center;
    flex-wrap: wrap;
}

.partner-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: white;
    border-radius: 0.5rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
}

.partner-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.partner-badge.featured {
    background: linear-gradient(135deg, white, #f8fafc);
    border: 2px solid var(--primary);
    padding: 0.6rem 1.2rem;
    font-weight: 600;
}

.partner-badge.shopify-badge.featured {
    border-color: #96BF48;
}

.partner-badge.gorgias-badge.featured {
    border-color: #FF6B6B;
}

@media (min-width: 992px) {
    .hero-content {
        grid-template-columns: 1fr 1fr;
    }
}

/* Cards */
.card {
    background-color: white;
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.08);
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

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

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(15, 23, 42, 0.15);
}

.card-icon {
    background: linear-gradient(135deg, rgba(57, 85, 214, 0.1), rgba(24, 220, 255, 0.1));
    color: var(--primary);
    width: 3rem;
    height: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.8rem;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    transition: var(--transition);
}

.card:hover .card-icon {
    transform: scale(1.1) rotate(5deg);
}

.featured-card {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
}

.featured-card .card-icon {
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
}

/* Sections */
.about-section,
.services-section {
    background: white;
    padding: 4rem 0;
}

.about-section {
    background: linear-gradient(135deg, rgba(248, 250, 252, 1) 0%, rgba(224, 231, 255, 0.3) 100%);
}

.services-section {
    background: linear-gradient(135deg, rgba(224, 231, 255, 0.2) 0%, rgba(248, 250, 252, 1) 100%);
}

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

.section-header h2 {
    position: relative;
    display: inline-block;
}

.section-header h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    border-radius: 2px;
}

.section-header p {
    color: var(--gray);
    font-size: 1.1rem;
    margin-top: 1rem;
}

/* Grid Layouts */
.grid {
    display: grid;
    gap: 2rem;
}

.two-column {
    grid-template-columns: 1fr;
}

.three-column {
    grid-template-columns: 1fr;
}

.four-column {
    grid-template-columns: 1fr;
}

@media (min-width: 768px) {
    .two-column {
        grid-template-columns: 1fr 1fr;
    }
    
    .three-column {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 992px) {
    .three-column {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .four-column {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Results Section */
.results-section {
    background: white;
    padding: 4rem 0;
}

/* Automations Section */
.automations-section {
    background: linear-gradient(135deg, #f8fafc 0%, #e0e7ff 50%, #f8fafc 100%);
    padding: 4rem 0;
}

.automations-section .card {
    height: 100%;
    position: relative;
    padding-bottom: 4rem;
}

.savings-badge {
    position: absolute;
    bottom: 1rem;
    left: 1rem;
    right: 1rem;
    background: linear-gradient(135deg, #10B981, #059669);
    color: white;
    padding: 0.5rem;
    border-radius: 0.5rem;
    text-align: center;
    font-weight: 600;
    font-size: 0.9rem;
}

/* Backend Showcase */
.backend-showcase-section {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color: white;
    padding: 5rem 0;
    position: relative;
    overflow: hidden;
}

.backend-showcase-section .section-header h2 {
    color: white;
}

.backend-showcase-section .section-header p {
    color: rgba(255, 255, 255, 0.7);
}

.tech-stack-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 2rem;
    margin: 3rem 0;
}

.tech-item {
    text-align: center;
    padding: 2rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 1rem;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.tech-item:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.tech-item h4 {
    margin: 1rem 0 0.5rem;
    color: white;
    opacity: 1 !important;
    visibility: visible !important;
}

.tech-item p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
    margin: 0;
    opacity: 1 !important;
    visibility: visible !important;
}

.tech-item i {
    opacity: 1 !important;
    visibility: visible !important;
}

/* Data Flow Animation */
.data-flow-container {
    position: relative;
    height: 100px;
    margin: 3rem 0;
    overflow: hidden;
}

.data-point {
    position: absolute;
    width: 8px;
    height: 8px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    border-radius: 50%;
    animation: dataFlow 3s linear infinite;
    box-shadow: 0 0 20px rgba(57, 85, 214, 0.5);
}

@keyframes dataFlow {
    0% {
        left: -10px;
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        left: 100%;
        opacity: 0;
    }
}

/* Code Showcase */
.code-showcase {
    background: #1e293b;
    border-radius: 1rem;
    overflow: hidden;
    margin: 3rem 0;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.code-header {
    background: #0f172a;
    padding: 1rem;
    display: flex;
    gap: 0.5rem;
}

.code-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
}

.code-content {
    padding: 2rem;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
    line-height: 1.6;
}

.code-content .code-line {
    opacity: 0;
    transform: translateX(-20px);
    animation: codeType 0.5s ease forwards;
}

/* Metrics Cards */
.metrics-card {
    background: white;
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.08);
    transition: all 0.3s ease;
}

.metrics-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(15, 23, 42, 0.15);
}

.metric-number {
    font-size: 3rem;
    font-weight: 700;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

/* Benefits List */
.benefits-list {
    list-style: none;
    margin: 2rem 0;
}

.benefits-list li {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    align-items: center;
}

.benefits-list i {
    color: var(--success);
    flex-shrink: 0;
}

/* FAQ Section */
.faq-section {
    background: linear-gradient(135deg, #f8fafc 0%, #e0e7ff 50%, #f8fafc 100%);
}

.faq-item {
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--gray-light);
    padding-bottom: 1.5rem;
}

.faq-question {
    display: flex;
    gap: 1rem;
    cursor: pointer;
    align-items: flex-start;
    margin-bottom: 1rem;
    font-weight: 600;
    transition: color 0.3s ease;
}

.faq-question:hover {
    color: var(--primary);
}

.faq-question i {
    color: var(--primary);
    font-size: 1.2rem;
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.faq-item.active .faq-question i {
    transform: rotate(45deg);
}

.faq-answer {
    padding-left: 2.2rem;
    color: var(--gray);
    display: none;
    animation: slideDown 0.3s ease;
}

.faq-item.active .faq-answer {
    display: block;
}

/* Contact Section */
.contact-section {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    padding: 5rem 0;
    position: relative;
    overflow: hidden;
}

.contact-section::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: rotate 30s linear infinite;
}

.contact-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.contact-content h2 {
    color: white;
    margin-bottom: 1rem;
}

.contact-content p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.2rem;
}

.contact-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
    flex-wrap: wrap;
}

/* Footer */
.footer {
    background-color: var(--dark);
    color: white;
    padding: 5rem 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
}

.footer-title {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    color: white;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: var(--gray-light);
    transition: var(--transition);
}

.footer-links a:hover {
    color: white;
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin: 2rem 0;
}

.social-link {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition);
}

.social-link:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

.newsletter-form {
    display: flex;
    margin-top: 1rem;
}

.newsletter-form input {
    flex-grow: 1;
    padding: 0.8rem 1rem;
    border: none;
    border-radius: 0.5rem 0 0 0.5rem;
    outline: none;
}

.newsletter-form button {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0 1.2rem;
    border-radius: 0 0.5rem 0.5rem 0;
    cursor: pointer;
    transition: var(--transition);
}

.newsletter-form button:hover {
    background: var(--primary-dark);
}

.footer-bottom {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-bottom-links {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.footer-bottom-links a {
    color: var(--gray-light);
}

.footer-bottom-links a:hover {
    color: white;
}

@media (min-width: 768px) {
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-bottom {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
}

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

/* Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(5px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: white;
    border-radius: 1rem;
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    transform: translateY(20px) scale(0.95);
    transition: transform 0.3s ease;
}

.modal-overlay.active .modal-content {
    transform: translateY(0) scale(1);
}

.modal-header {
    padding: 2rem 2rem 1rem;
}

.modal-body {
    padding: 1rem 2rem;
}

.modal-footer {
    padding: 1rem 2rem 2rem;
    text-align: center;
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--gray-light);
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    width: 2rem;
    height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--dark);
    transition: var(--transition);
}

.modal-close:hover {
    background: var(--primary);
    color: white;
    transform: rotate(90deg);
}

/* Form Elements */
.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

input, select, textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1.5px solid var(--gray-light);
    border-radius: 0.5rem;
    outline: none;
    transition: var(--transition);
    font-family: inherit;
    font-size: 1rem;
}

input:focus, select:focus, textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(57, 85, 214, 0.1);
}

.consent-checkbox {
    display: flex;
    gap: 0.5rem;
    align-items: flex-start;
    margin: 1.5rem 0;
}

.consent-checkbox input {
    width: auto;
    margin-top: 0.3rem;
}

/* Animations */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

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

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

@keyframes popIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

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

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes codeType {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Utility Classes */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-8 { margin-top: 2rem; }
.mb-0 { margin-bottom: 0; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-8 { margin-bottom: 2rem; }

/* Ensure visibility */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.active {
    opacity: 1 !important;
    transform: translateY(0);
}

.stagger-item {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.stagger-item.active {
    opacity: 1 !important;
    transform: translateY(0);
}

/* Ensure all sections are visible */
.about-section,
.services-section,
.results-section,
.backend-showcase-section,
.faq-section,
.contact-section {
    opacity: 1 !important;
    visibility: visible !important;
    display: block !important;
}

.features-grid {
    opacity: 1 !important;
    visibility: visible !important;
}

.features-grid .card {
    opacity: 1 !important;
    visibility: visible !important;
}

/* Ensure tech stack is visible */
.tech-stack-grid,
.tech-stack-grid *,
.code-showcase,
.code-showcase * {
    opacity: 1 !important;
    visibility: visible !important;
}

/* Carousel */
.carousel-container {
    position: relative;
    margin: 3rem 0;
}

.carousel-track {
    display: flex;
    gap: 1.5rem;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 1rem 0;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

.carousel-track::-webkit-scrollbar {
    height: 8px;
}

.carousel-track::-webkit-scrollbar-track {
    background: var(--gray-light);
    border-radius: 4px;
}

.carousel-track::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

.carousel-item {
    min-width: 300px;
    scroll-snap-align: start;
}

.swipe-hint {
    text-align: center;
    color: var(--gray);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    display: block;
}

@media (min-width: 768px) {
    .swipe-hint {
        display: none;
    }
}