/* ========================================
   CSS Variables & Reset
   ======================================== */
:root {
    --color-primary: #6366f1;
    --color-primary-dark: #4f46e5;
    --color-primary-light: #818cf8;
    --color-secondary: #10b981;
    --color-secondary-dark: #059669;
    --color-dark: #0f172a;
    --color-dark-light: #1e293b;
    --color-gray: #64748b;
    --color-gray-light: #cbd5e1;
    --color-gray-lighter: #f1f5f9;
    --color-white: #ffffff;
    --color-error: #ef4444;
    --color-success: #10b981;
    
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
}

body {
    font-family: var(--font-family);
    color: var(--color-dark);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    -webkit-tap-highlight-color: transparent; /* Remove tap highlight on mobile */
    overflow-x: hidden; /* Prevent horizontal scroll */
}

/* Prevent text size adjustment on orientation change */
html, body {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ========================================
   Header
   ======================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    z-index: 1000;
    transition: var(--transition);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
}

.logo {
    font-size: 28px;
    font-weight: 800;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.language-switcher {
    display: flex;
    gap: 8px;
    background: var(--color-gray-lighter);
    padding: 4px;
    border-radius: var(--radius-md);
}

.lang-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border: none;
    background: transparent;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: var(--transition);
    font-size: 14px;
    font-weight: 600;
    color: var(--color-gray);
}

.lang-btn .flag {
    font-size: 20px;
}

.lang-btn:hover {
    background: rgba(99, 102, 241, 0.1);
}

.lang-btn.active {
    background: var(--color-white);
    color: var(--color-primary);
    box-shadow: var(--shadow-sm);
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
    padding: 140px 0 80px;
    background: linear-gradient(135deg, #f8fafc 0%, #e0e7ff 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
}

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

.hero-headline {
    font-size: 56px;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 24px;
    color: var(--color-dark);
    background: linear-gradient(135deg, var(--color-dark), var(--color-primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subheadline {
    font-size: 20px;
    color: var(--color-gray);
    margin-bottom: 40px;
    line-height: 1.7;
}

.hero-form {
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 16px;
}

.form-input {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid var(--color-gray-light);
    border-radius: var(--radius-md);
    font-size: 16px;
    font-family: var(--font-family);
    transition: var(--transition);
    background: var(--color-white);
}

.form-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.btn {
    width: 100%;
    padding: 18px 32px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 700;
    font-family: var(--font-family);
    cursor: pointer;
    transition: var(--transition);
    text-transform: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark));
    color: var(--color-white);
    box-shadow: var(--shadow-lg);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
}

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

.hero-microcopy {
    font-size: 14px;
    color: var(--color-gray);
    text-align: center;
}

.form-error {
    color: var(--color-error);
    font-size: 14px;
    margin-top: 12px;
    display: none;
}

.form-error.show {
    display: block;
}

.form-success {
    color: var(--color-success);
    font-size: 16px;
    font-weight: 600;
    margin-top: 12px;
    padding: 16px;
    background: rgba(16, 185, 129, 0.1);
    border-radius: var(--radius-md);
    display: none;
}

.form-success.show {
    display: block;
}

/* Phone Mockup */
.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.phone-mockup {
    width: 300px;
    height: 600px;
    background: linear-gradient(135deg, var(--color-dark), var(--color-dark-light));
    border-radius: 40px;
    padding: 12px;
    box-shadow: var(--shadow-xl);
    position: relative;
    animation: float 6s ease-in-out infinite;
}

.phone-screen {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #6366f1, #8b5cf6, #ec4899);
    border-radius: 32px;
    position: relative;
    overflow: hidden;
}

.phone-screen::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 25px;
    background: var(--color-dark);
    border-radius: 0 0 20px 20px;
}

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

/* ========================================
   Problems Section
   ======================================== */
.problems {
    padding: 100px 0;
    background: var(--color-white);
}

.section-title {
    font-size: 42px;
    font-weight: 800;
    text-align: center;
    margin-bottom: 60px;
    color: var(--color-dark);
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 32px;
}

.card {
    background: var(--color-white);
    padding: 40px 32px;
    border-radius: var(--radius-lg);
    transition: var(--transition);
}

.problem-card {
    border: 2px solid var(--color-gray-lighter);
}

.problem-card:hover {
    border-color: var(--color-primary);
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

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

.card-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--color-dark);
}

.card-text {
    font-size: 16px;
    color: var(--color-gray);
    line-height: 1.7;
}

/* ========================================
   Benefits Section
   ======================================== */
.benefits {
    padding: 100px 0;
    background: linear-gradient(135deg, #f8fafc 0%, #e0e7ff 100%);
}

.cards-grid-4 {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.benefit-card {
    background: var(--color-white);
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(99, 102, 241, 0.1);
}

.benefit-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--color-primary);
}

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

/* ========================================
   Demo Section
   ======================================== */
.demo {
    padding: 100px 0;
    background: var(--color-white);
}

.demo-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.demo-text .section-title {
    text-align: left;
    margin-bottom: 24px;
}

.demo-description {
    font-size: 18px;
    color: var(--color-gray);
    line-height: 1.8;
}

.dashboard-mockup {
    width: 100%;
    height: 400px;
    background: linear-gradient(135deg, var(--color-dark), var(--color-dark-light));
    border-radius: var(--radius-xl);
    padding: 20px;
    box-shadow: var(--shadow-xl);
}

.dashboard-screen {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border-radius: var(--radius-lg);
}

/* ========================================
   Testimonials Section
   ======================================== */
.testimonials {
    padding: 100px 0;
    background: linear-gradient(135deg, #f8fafc 0%, #e0e7ff 100%);
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 40px;
    max-width: 1000px;
    margin: 0 auto;
}

.testimonial-card {
    background: var(--color-white);
    padding: 40px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    position: relative;
}

.testimonial-avatar {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    color: var(--color-white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
}

.testimonial-text {
    font-size: 16px;
    color: var(--color-dark);
    line-height: 1.7;
    margin-bottom: 16px;
    font-style: italic;
}

.testimonial-author {
    font-size: 14px;
    color: var(--color-gray);
    font-weight: 600;
}

/* ========================================
   Final CTA Section
   ======================================== */
.final-cta {
    padding: 100px 0;
    background: linear-gradient(135deg, var(--color-dark), var(--color-dark-light));
    color: var(--color-white);
}

.cta-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.cta-title {
    font-size: 42px;
    font-weight: 800;
    margin-bottom: 20px;
    color: var(--color-white);
}

.cta-subtitle {
    font-size: 18px;
    color: var(--color-gray-light);
    margin-bottom: 40px;
}

.cta-form {
    max-width: 100%;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    gap: 16px;
    margin-bottom: 16px;
}

.form-input-light {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    color: var(--color-white);
}

.form-input-light::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.form-input-light:focus {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--color-primary-light);
}

.btn-secondary {
    background: var(--color-secondary);
    color: var(--color-white);
    box-shadow: var(--shadow-lg);
    white-space: nowrap;
}

.btn-secondary:hover {
    background: var(--color-secondary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
}

.form-success-light {
    background: rgba(16, 185, 129, 0.2);
    color: var(--color-white);
}

/* ========================================
   Footer
   ======================================== */
.footer {
    padding: 40px 0;
    background: var(--color-dark);
    color: var(--color-gray-light);
}

.footer-content {
    text-align: center;
}

.footer-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.footer-link {
    color: var(--color-gray-light);
    text-decoration: none;
    transition: var(--transition);
    font-size: 14px;
}

.footer-link:hover {
    color: var(--color-white);
}

.footer-separator {
    color: var(--color-gray);
}

.footer-copyright {
    font-size: 14px;
    color: var(--color-gray);
}

/* ========================================
   Responsive Design
   ======================================== */
@media (max-width: 968px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .hero-headline {
        font-size: 42px;
    }
    
    .hero-image {
        order: 2;
    }
    
    .demo-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .testimonials-grid {
        grid-template-columns: 1fr;
    }
    
    .container {
        padding: 0 20px;
    }
}

@media (max-width: 640px) {
    /* Container & Spacing */
    .container {
        padding: 0 16px;
    }
    
    /* Header */
    .header-content {
        padding: 16px 0;
    }
    
    .logo {
        font-size: 24px;
    }
    
    .language-switcher {
        gap: 6px;
        padding: 3px;
    }
    
    .lang-btn {
        padding: 6px 12px;
        font-size: 13px;
    }
    
    .lang-btn .flag {
        font-size: 18px;
    }
    
    /* Hero Section */
    .hero {
        padding: 100px 0 50px;
        min-height: auto;
    }
    
    .hero-headline {
        font-size: 32px;
        line-height: 1.2;
        margin-bottom: 20px;
    }
    
    .hero-subheadline {
        font-size: 16px;
        margin-bottom: 32px;
        line-height: 1.6;
    }
    
    .hero-microcopy {
        font-size: 13px;
        line-height: 1.5;
    }
    
    /* Forms - Better Touch Targets */
    .form-input {
        padding: 14px 16px;
        font-size: 16px; /* Prevents zoom on iOS */
        border-radius: var(--radius-sm);
    }
    
    .btn {
        padding: 16px 24px;
        font-size: 16px;
        border-radius: var(--radius-sm);
        min-height: 48px; /* Better touch target */
    }
    
    .form-group {
        margin-bottom: 14px;
    }
    
    /* Phone Mockup */
    .phone-mockup {
        width: 220px;
        height: 440px;
        border-radius: 32px;
        padding: 10px;
    }
    
    .phone-screen {
        border-radius: 26px;
    }
    
    .phone-screen::before {
        width: 80px;
        height: 20px;
        top: 15px;
    }
    
    /* Sections */
    .problems,
    .benefits,
    .demo,
    .testimonials {
        padding: 60px 0;
    }
    
    .final-cta {
        padding: 60px 0;
    }
    
    .section-title {
        font-size: 28px;
        line-height: 1.3;
        margin-bottom: 40px;
    }
    
    /* Cards */
    .cards-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .cards-grid-4 {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .card {
        padding: 32px 24px;
    }
    
    .card-icon {
        font-size: 40px;
        margin-bottom: 16px;
    }
    
    .card-title {
        font-size: 20px;
        margin-bottom: 12px;
    }
    
    .card-text {
        font-size: 15px;
        line-height: 1.6;
    }
    
    /* Demo Section */
    .demo-description {
        font-size: 16px;
        line-height: 1.7;
    }
    
    .dashboard-mockup {
        height: 300px;
        border-radius: var(--radius-lg);
        padding: 16px;
    }
    
    .dashboard-screen {
        border-radius: var(--radius-md);
    }
    
    /* Testimonials */
    .testimonials-grid {
        gap: 24px;
        grid-template-columns: 1fr;
    }
    
    .testimonial-card {
        padding: 28px 24px;
    }
    
    .testimonial-avatar {
        width: 50px;
        height: 50px;
        font-size: 20px;
        margin-bottom: 16px;
    }
    
    .testimonial-text {
        font-size: 15px;
        line-height: 1.6;
        margin-bottom: 12px;
    }
    
    .testimonial-author {
        font-size: 13px;
    }
    
    /* Final CTA */
    .cta-title {
        font-size: 28px;
        line-height: 1.3;
        margin-bottom: 16px;
    }
    
    .cta-subtitle {
        font-size: 16px;
        margin-bottom: 32px;
        line-height: 1.6;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 14px;
    }
    
    /* Footer */
    .footer {
        padding: 32px 0;
    }
    
    .footer-links {
        gap: 12px;
        margin-bottom: 12px;
    }
    
    .footer-link {
        font-size: 13px;
    }
    
    .footer-copyright {
        font-size: 13px;
    }
}

/* Extra small devices (very small phones) */
@media (max-width: 375px) {
    .hero-headline {
        font-size: 28px;
    }
    
    .section-title {
        font-size: 24px;
    }
    
    .cta-title {
        font-size: 24px;
    }
    
    .phone-mockup {
        width: 200px;
        height: 400px;
    }
    
    .card {
        padding: 24px 20px;
    }
}

/* Landscape mobile optimization */
@media (max-width: 968px) and (orientation: landscape) {
    .hero {
        min-height: auto;
        padding: 100px 0 60px;
    }
    
    .hero-content {
        grid-template-columns: 1fr 1fr;
        gap: 40px;
    }
    
    .hero-image {
        order: 1;
    }
}

/* Tablet optimization */
@media (min-width: 641px) and (max-width: 968px) {
    .cards-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .cards-grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .testimonials-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {
    .btn {
        min-height: 48px; /* Ensure touch targets are at least 48px */
    }
    
    .lang-btn {
        min-height: 44px;
        min-width: 60px;
    }
    
    .footer-link {
        padding: 8px 4px; /* Larger touch area */
    }
}
