/* ===== UIVERSE-INSPIRED MODERN DESIGN SYSTEM ===== */
:root {
    /* Advanced Color Palette */
    --primary: #667eea;
    --primary-dark: #764ba2;
    --primary-light: #f093fb;
    --secondary: #f6d365;
    --secondary-dark: #fda085;
    --accent: #a8edea;
    --accent-dark: #fed6e3;
    
    /* Neutral Scale */
    --white: #ffffff;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    
    /* Status Colors */
    --success: #10b981;
    --error: #ef4444;
    --warning: #f59e0b;
    --info: #3b82f6;
    
    /* Typography */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-display: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    
    /* Spacing Scale */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-20: 5rem;
    --space-24: 6rem;
    
    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --shadow-2xl: 0 25px 50px -12px rgb(0 0 0 / 0.25);
}

/* ===== PERFORMANCE OPTIMIZATIONS ===== */
/* Prevent layout shifts and improve rendering */
html {
    scroll-behavior: smooth;
}

/* Critical rendering path optimization */
.hero,
.app-section,
.tutorial-section,
.features-section,
.faq-section {
    contain: layout style paint;
}

/* Improve font loading */
body {
    font-display: swap;
}

/* GPU acceleration for animations */
.platform-item,
.feature-card,
.tutorial-card,
.download-btn,
.lang-toggle {
    transform: translateZ(0);
    will-change: transform;
}

/* Reduce paint complexity */
.hero-background,
.hero-overlay {
    will-change: opacity, transform;
}

/* ===== RESET & BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-primary);
    line-height: 1.6;
    color: var(--gray-800);
    background: var(--gray-50);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* Prevent layout shifts */
    min-height: 100vh;
}

/* ===== HERO SECTION ===== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(102, 126, 234, 0.8) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(168, 237, 234, 0.8) 0%, transparent 50%),
        radial-gradient(circle at 40% 80%, rgba(246, 211, 101, 0.6) 0%, transparent 50%),
        linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    animation: gradientShift 8s ease-in-out infinite;
}

.hero-background::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('https://images.unsplash.com/photo-1494790108755-2616b612b193?w=1920&h=1080&fit=crop');
    background-size: cover;
    background-position: center;
    opacity: 0.3;
    filter: blur(2px) brightness(1.2) saturate(1.5);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        135deg,
        rgba(99, 102, 241, 0.9) 0%,
        rgba(79, 70, 229, 0.8) 50%,
        rgba(139, 92, 246, 0.9) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 1200px;
    padding: var(--space-8);
    color: var(--white);
    animation: fadeInUp 1s ease-out;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: var(--space-2) var(--space-4);
    border-radius: var(--radius-2xl);
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: var(--space-6);
}

.badge-icon {
    font-size: 1rem;
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: var(--space-6);
}

.gradient-text {
    background: linear-gradient(135deg, #fbbf24, #f59e0b, #d97706);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: clamp(1.125rem, 2vw, 1.25rem);
    line-height: 1.6;
    margin-bottom: var(--space-12);
    opacity: 0.9;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* ===== PLATFORM SHOWCASE ===== */
.platform-showcase {
    margin-top: var(--space-16);
}

.platform-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: var(--space-4);
    max-width: 800px;
    margin: 0 auto var(--space-8);
}

.platform-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-4);
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-lg);
    transition: all 0.3s ease;
}

.platform-item:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.15);
}

.platform-item.featured {
    background: rgba(255, 255, 255, 0.15);
}

.platform-item img {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.platform-item.featured:hover img {
    transform: scale(1.1);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.platform-icon {
    font-size: 1.5rem;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    font-weight: bold;
    color: white;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
    background: rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease;
}

/* Platform icons in platform-item */
.platform-item .platform-icon.instagram {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
}

.platform-item .platform-icon.instagram::after {
    content: '';
    width: 14px;
    height: 14px;
    border: 2px solid white;
    border-radius: 4px;
    position: relative;
}

.platform-item .platform-icon.instagram::before {
    content: '';
    width: 4px;
    height: 4px;
    background: white;
    border-radius: 50%;
    position: absolute;
    top: 6px;
    right: 6px;
    z-index: 2;
}

.platform-item .platform-icon.facebook {
    background: linear-gradient(45deg, #1877f2, #42a5f5);
}

.platform-item .platform-icon.facebook::after {
    content: 'f';
    font-family: 'Arial', sans-serif;
    font-size: 18px;
    font-weight: bold;
    color: white;
}

.platform-item .platform-icon.twitter {
    background: linear-gradient(45deg, #1da1f2, #0d8bd9);
}

.platform-item .platform-icon.twitter::after {
    content: '𝕏';
    font-size: 14px;
    color: white;
    font-weight: bold;
}

.platform-item .platform-icon.reddit {
    background: linear-gradient(45deg, #ff4500, #e03d00);
}

.platform-item .platform-icon.reddit::after {
    content: 'r';
    font-size: 16px;
    color: white;
    font-weight: bold;
    font-style: italic;
}

.platform-item .platform-icon.tiktok {
    background: linear-gradient(45deg, #000000, #25f4ee, #fe2c55);
    background-size: 300% 300%;
    animation: tiktokGradient 3s ease infinite;
}

.platform-item .platform-icon.tiktok::after {
    content: '♪';
    font-size: 16px;
    color: white;
    text-shadow: 1px 1px 0 #fe2c55, -1px -1px 0 #25f4ee;
}

.platform-item .platform-icon.pinterest {
    background: linear-gradient(45deg, #e60023, #bd081c);
}

.platform-item .platform-icon.pinterest::after {
    content: 'P';
    font-size: 18px;
    color: white;
    font-weight: bold;
}

.platform-item .platform-icon.youtube {
    background: linear-gradient(45deg, #ff0000, #cc0000);
}

.platform-item .platform-icon.youtube::after {
    content: '▶';
    font-size: 14px;
    color: white;
    margin-left: 1px;
}

.platform-item .platform-icon.vimeo {
    background: linear-gradient(45deg, #1ab7ea, #0088cc);
}

.platform-item .platform-icon.vimeo::after {
    content: 'V';
    font-size: 18px;
    color: white;
    font-weight: bold;
}

.platform-item:hover .platform-icon {
    transform: scale(1.1);
}

/* Platform Showcase Icons - Professional Brand-Accurate Styling */
.platform-card .platform-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 24px;
    color: white;
    text-shadow: 0 1px 2px rgba(0,0,0,0.3);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.platform-card .platform-icon::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: inherit;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.platform-card:hover .platform-icon::before {
    opacity: 0.2;
    background: linear-gradient(45deg, rgba(255,255,255,0.3), transparent);
}

/* Instagram - Gradient Background */
.platform-card .platform-icon.instagram {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
}

.platform-card .platform-icon.instagram::after {
    content: '';
    width: 20px;
    height: 20px;
    border: 2.5px solid white;
    border-radius: 6px;
    position: relative;
}

.platform-card .platform-icon.instagram::before {
    content: '';
    width: 6px;
    height: 6px;
    background: white;
    border-radius: 50%;
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
}

/* TikTok - Black with White Logo */
.platform-card .platform-icon.tiktok {
    background: linear-gradient(45deg, #000000, #25f4ee, #fe2c55);
    background-size: 300% 300%;
    animation: tiktokGradient 3s ease infinite;
}

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

.platform-card .platform-icon.tiktok::after {
    content: '♪';
    font-size: 28px;
    color: white;
    text-shadow: 2px 2px 0 #fe2c55, -2px -2px 0 #25f4ee;
}

/* Facebook - Official Blue */
.platform-card .platform-icon.facebook {
    background: linear-gradient(45deg, #1877f2, #42a5f5);
}

.platform-card .platform-icon.facebook::after {
    content: 'f';
    font-family: 'Arial', sans-serif;
    font-size: 32px;
    font-weight: bold;
    color: white;
}

/* YouTube - Red Gradient */
.platform-card .platform-icon.youtube {
    background: linear-gradient(45deg, #ff0000, #cc0000);
}

.platform-card .platform-icon.youtube::after {
    content: '▶';
    font-size: 20px;
    color: white;
    margin-left: 2px;
}

/* Twitter/X - Gradient Blue */
.platform-card .platform-icon.twitter {
    background: linear-gradient(45deg, #1da1f2, #0d8bd9);
}

.platform-card .platform-icon.twitter::after {
    content: '𝕏';
    font-size: 24px;
    color: white;
    font-weight: bold;
}

/* Pinterest - Red Gradient */
.platform-card .platform-icon.pinterest {
    background: linear-gradient(45deg, #e60023, #bd081c);
}

.platform-card .platform-icon.pinterest::after {
    content: 'P';
    font-size: 28px;
    color: white;
    font-weight: bold;
}

/* Reddit - Orange */
.platform-card .platform-icon.reddit {
    background: linear-gradient(45deg, #ff4500, #e03d00);
}

.platform-card .platform-icon.reddit::after {
    content: 'r';
    font-size: 24px;
    color: white;
    font-weight: bold;
    font-style: italic;
}

/* Vimeo - Blue Gradient */
.platform-card .platform-icon.vimeo {
    background: linear-gradient(45deg, #1ab7ea, #0088cc);
}

.platform-card .platform-icon.vimeo::after {
    content: 'V';
    font-size: 28px;
    color: white;
    font-weight: bold;
}

/* Featured Platform Icons - Larger Size */
.featured-platforms .platform-card .platform-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    font-size: 28px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.2);
    transform: scale(1);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.featured-platforms .platform-card:hover .platform-icon {
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
}

/* Mobile Responsive Adjustments */
@media (max-width: 768px) {
    .platform-card .platform-icon {
        width: 40px;
        height: 40px;
        border-radius: 10px;
        font-size: 20px;
    }
    
    .featured-platforms .platform-card .platform-icon {
        width: 48px;
        height: 48px;
        border-radius: 12px;
        font-size: 24px;
    }
    
    .platform-card .platform-icon.instagram::after {
        width: 16px;
        height: 16px;
        border-width: 2px;
    }
    
    .platform-card .platform-icon.instagram::before {
        width: 4px;
        height: 4px;
        top: 8px;
        right: 8px;
    }
}

@media (max-width: 414px) {
    .platform-card .platform-icon {
        width: 36px;
        height: 36px;
        border-radius: 8px;
        font-size: 18px;
    }
    
    .platform-card .platform-icon.tiktok::after {
        font-size: 22px;
    }
    
    .platform-card .platform-icon.facebook::after {
        font-size: 24px;
    }
}

.platform-item span {
    font-size: 0.875rem;
    font-weight: 500;
    text-align: center;
}

.mobile-support {
    margin-top: var(--space-8);
}

.mobile-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-3);
    background: rgba(251, 191, 36, 0.2);
    border: 1px solid rgba(251, 191, 36, 0.3);
    padding: var(--space-3) var(--space-6);
    border-radius: var(--radius-2xl);
    font-size: 0.875rem;
    font-weight: 500;
}

.mobile-icon {
    font-size: 1.25rem;
}

/* ===== APP SECTION ===== */
.app-section {
    padding: var(--space-20) var(--space-4);
    background: var(--white);
}

.app-container {
    max-width: 800px;
    margin: 0 auto;
}

.app-header {
    text-align: center;
    margin-bottom: var(--space-12);
}

.app-header h2 {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 2.5rem);
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: var(--space-4);
}

.app-header p {
    font-size: 1.125rem;
    color: var(--gray-600);
}

/* ===== DOWNLOAD INTERFACE ===== */
.download-interface {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--radius-2xl);
    padding: var(--space-8);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.15),
        0 0 0 1px rgba(255, 255, 255, 0.2) inset,
        0 1px 0 rgba(255, 255, 255, 0.4) inset;
    animation: glassMorphIn 0.8s ease-out 0.3s both;
    position: relative;
    overflow: hidden;
}

.download-interface::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: shimmer 3s infinite;
}

.input-group {
    margin-bottom: var(--space-6);
}

.input-wrapper {
    position: relative;
    display: flex;
    gap: var(--space-3);
    align-items: center;
}

.input-icon {
    position: absolute;
    left: var(--space-4);
    z-index: 2;
    font-size: 1.25rem;
    color: var(--gray-400);
}

#video-url {
    flex: 1;
    padding: var(--space-4) var(--space-4) var(--space-4) var(--space-12);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-xl);
    font-size: 1rem;
    transition: all 0.2s ease;
    background: var(--gray-50);
}

#video-url:focus {
    outline: none;
    border-color: var(--primary);
    background: var(--white);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.download-btn {
    padding: var(--space-4) var(--space-6);
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: var(--white);
    border: none;
    border-radius: var(--radius-xl);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    display: flex;
    align-items: center;
    gap: var(--space-2);
    box-shadow: 
        0 4px 15px rgba(102, 126, 234, 0.4),
        0 0 0 1px rgba(255, 255, 255, 0.1) inset,
        0 1px 0 rgba(255, 255, 255, 0.2) inset;
    position: relative;
    overflow: hidden;
    transform: perspective(1000px) rotateX(0deg) rotateY(0deg);
}

.download-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: all 0.5s;
}

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

.download-btn:hover {
    transform: perspective(1000px) rotateX(-5deg) rotateY(5deg) translateY(-3px) scale(1.05);
    box-shadow: 
        0 8px 25px rgba(102, 126, 234, 0.6),
        0 0 0 1px rgba(255, 255, 255, 0.2) inset,
        0 2px 0 rgba(255, 255, 255, 0.3) inset;
    background: linear-gradient(135deg, #7c3aed 0%, #8b5cf6 100%);
}

.download-btn:active {
    transform: perspective(1000px) rotateX(0deg) rotateY(0deg) translateY(0px) scale(0.98);
    transition: all 0.1s ease;
}

.download-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

/* ===== OPTIONS ROW ===== */
.options-row {
    margin-bottom: var(--space-8);
}

.fast-mode-toggle {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    cursor: pointer;
    padding: var(--space-4);
    background: var(--gray-50);
    border-radius: var(--radius-lg);
    transition: background 0.2s ease;
}

.fast-mode-toggle:hover {
    background: var(--gray-100);
}

.fast-mode-toggle input {
    display: none;
}

.toggle-slider {
    width: 44px;
    height: 24px;
    background: var(--gray-300);
    border-radius: 12px;
    position: relative;
    transition: background 0.2s ease;
}

.toggle-slider::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 20px;
    height: 20px;
    background: var(--white);
    border-radius: 50%;
    transition: transform 0.2s ease;
    box-shadow: var(--shadow-sm);
}

.fast-mode-toggle input:checked + .toggle-slider {
    background: var(--primary);
}

.fast-mode-toggle input:checked + .toggle-slider::after {
    transform: translateX(20px);
}

.toggle-label {
    display: flex;
    flex-direction: column;
}

.toggle-title {
    font-weight: 600;
    color: var(--gray-900);
}

.toggle-desc {
    font-size: 0.875rem;
    color: var(--gray-600);
}

/* ===== PROGRESS & LOADING ===== */
.progress-container {
    margin: var(--space-6) 0;
    padding: var(--space-4);
    background: var(--gray-50);
    border-radius: var(--radius-lg);
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-3);
}

.progress-label {
    font-weight: 500;
    color: var(--gray-700);
}

.progress-percent {
    font-weight: 600;
    color: var(--primary);
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--gray-200);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    border-radius: 4px;
    transition: width 0.3s ease;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--gray-200);
    border-top: 4px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: var(--space-6) auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes gradientShift {
    0%, 100% { 
        background: 
            radial-gradient(circle at 20% 50%, rgba(102, 126, 234, 0.8) 0%, transparent 50%),
            radial-gradient(circle at 80% 20%, rgba(168, 237, 234, 0.8) 0%, transparent 50%),
            radial-gradient(circle at 40% 80%, rgba(246, 211, 101, 0.6) 0%, transparent 50%),
            linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    }
    25% { 
        background: 
            radial-gradient(circle at 40% 30%, rgba(168, 237, 234, 0.9) 0%, transparent 50%),
            radial-gradient(circle at 60% 70%, rgba(246, 211, 101, 0.7) 0%, transparent 50%),
            radial-gradient(circle at 80% 10%, rgba(102, 126, 234, 0.8) 0%, transparent 50%),
            linear-gradient(225deg, #764ba2 0%, #f093fb 50%, #667eea 100%);
    }
    50% { 
        background: 
            radial-gradient(circle at 70% 80%, rgba(246, 211, 101, 0.8) 0%, transparent 50%),
            radial-gradient(circle at 20% 20%, rgba(102, 126, 234, 0.9) 0%, transparent 50%),
            radial-gradient(circle at 90% 40%, rgba(168, 237, 234, 0.7) 0%, transparent 50%),
            linear-gradient(315deg, #f093fb 0%, #667eea 50%, #764ba2 100%);
    }
    75% { 
        background: 
            radial-gradient(circle at 10% 60%, rgba(168, 237, 234, 0.8) 0%, transparent 50%),
            radial-gradient(circle at 90% 90%, rgba(102, 126, 234, 0.7) 0%, transparent 50%),
            radial-gradient(circle at 50% 10%, rgba(246, 211, 101, 0.9) 0%, transparent 50%),
            linear-gradient(45deg, #764ba2 0%, #667eea 50%, #f093fb 100%);
    }
}

@keyframes glassMorphIn {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
        backdrop-filter: blur(0px);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        backdrop-filter: blur(20px);
    }
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* ===== FLOATING PARTICLES ===== */
.particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.particle {
    position: absolute;
    width: 8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    animation: float 20s infinite linear;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
}

.particle:nth-child(1) {
    left: 10%;
    animation-delay: -2s;
    animation-duration: 15s;
    width: 6px;
    height: 6px;
}

.particle:nth-child(2) {
    left: 20%;
    animation-delay: -4s;
    animation-duration: 25s;
    width: 10px;
    height: 10px;
}

.particle:nth-child(3) {
    left: 30%;
    animation-delay: -6s;
    animation-duration: 18s;
    width: 4px;
    height: 4px;
}

.particle:nth-child(4) {
    left: 50%;
    animation-delay: -8s;
    animation-duration: 22s;
    width: 12px;
    height: 12px;
}

.particle:nth-child(5) {
    left: 70%;
    animation-delay: -10s;
    animation-duration: 16s;
    width: 8px;
    height: 8px;
}

.particle:nth-child(6) {
    left: 80%;
    animation-delay: -12s;
    animation-duration: 20s;
    width: 5px;
    height: 5px;
}

.particle:nth-child(7) {
    left: 90%;
    animation-delay: -14s;
    animation-duration: 24s;
    width: 7px;
    height: 7px;
}

.particle:nth-child(8) {
    left: 95%;
    animation-delay: -16s;
    animation-duration: 19s;
    width: 9px;
    height: 9px;
}

@keyframes float {
    0% {
        transform: translateY(100vh) translateX(-50px) rotateZ(0deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100px) translateX(50px) rotateZ(360deg);
        opacity: 0;
    }
}

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

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

/* ===== MESSAGES ===== */
.message {
    margin: var(--space-4) 0;
    padding: var(--space-3) var(--space-4);
    border-radius: var(--radius-lg);
    font-weight: 500;
}

.message.success {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.message.error {
    background: rgba(239, 68, 68, 0.1);
    color: var(--error);
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.message.warning {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
    border: 1px solid rgba(245, 158, 11, 0.2);
}

.message.info {
    background: rgba(59, 130, 246, 0.1);
    color: var(--info);
    border: 1px solid rgba(59, 130, 246, 0.2);
}

/* ===== DOWNLOAD RESULT ===== */
.download-result {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    padding: var(--space-6);
    background: rgba(16, 185, 129, 0.05);
    border: 1px solid rgba(16, 185, 129, 0.2);
    border-radius: var(--radius-lg);
    margin: var(--space-6) 0;
}

.result-icon {
    font-size: 2rem;
}

.result-content {
    flex: 1;
}

.result-filename {
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: var(--space-2);
}

.result-download-btn {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-4);
    background: var(--success);
    color: var(--white);
    text-decoration: none;
    border-radius: var(--radius-md);
    font-weight: 500;
    transition: all 0.2s ease;
}

.result-download-btn:hover {
    background: #059669;
    transform: translateY(-1px);
}

/* ===== HELP SECTION ===== */
.help-section {
    text-align: center;
    margin-top: var(--space-8);
}

.help-btn {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-6);
    background: var(--gray-100);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-xl);
    color: var(--gray-700);
    text-decoration: none;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.help-btn:hover {
    background: var(--gray-200);
    transform: translateY(-1px);
}

/* ===== FEATURES SECTION ===== */
.features-section {
    padding: var(--space-20) var(--space-4);
    background: var(--gray-50);
}

.features-container {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.features-container h3 {
    font-family: var(--font-display);
    font-size: clamp(1.875rem, 4vw, 2.25rem);
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: var(--space-12);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-8);
}

.feature-card {
    background: var(--white);
    padding: var(--space-8);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-lg);
    transition: all 0.3s ease;
}

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

.feature-icon {
    font-size: 3rem;
    margin-bottom: var(--space-4);
}

.feature-card h4 {
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: var(--space-3);
}

.feature-card p {
    color: var(--gray-600);
    line-height: 1.6;
}

/* ===== FOOTER ===== */
.footer {
    background: var(--gray-900);
    color: var(--white);
    padding: var(--space-16) var(--space-4);
    text-align: center;
}

.footer-content {
    max-width: 800px;
    margin: 0 auto;
}

.footer-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-3);
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: var(--space-6);
}

.logo-icon {
    font-size: 2rem;
}

.footer-text {
    font-size: 1.125rem;
    margin-bottom: var(--space-6);
    opacity: 0.9;
}

.footer-disclaimer {
    font-size: 0.875rem;
    opacity: 0.7;
    line-height: 1.6;
}

/* ===== MODAL ===== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: var(--space-4);
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--white);
    border-radius: var(--radius-2xl);
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-2xl);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-6) var(--space-6) 0;
    margin-bottom: var(--space-6);
}

.modal-header h2 {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900);
}

.modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: var(--gray-100);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: var(--gray-600);
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: var(--gray-200);
}

.modal-body {
    padding: 0 var(--space-6) var(--space-6);
}

.instruction-steps {
    display: flex;
    flex-direction: column;
    gap: var(--space-6);
}

.step {
    display: flex;
    gap: var(--space-4);
    align-items: flex-start;
}

.step-number {
    width: 32px;
    height: 32px;
    background: var(--primary);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    flex-shrink: 0;
}

.step-content h4 {
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: var(--space-1);
}

.step-content p {
    color: var(--gray-600);
    line-height: 1.6;
}

/* ===== RESPONSIVE DESIGN ===== */
/* ===== MOBILE RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    /* Hero Section Mobile */
    .hero {
        min-height: 100vh;
        padding: 0;
    }
    
    .hero-content {
        padding: var(--space-8) var(--space-4);
        min-height: 100vh;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }
    
    .hero-background {
        background-attachment: scroll;
        background-image: 
            linear-gradient(135deg, rgba(99, 102, 241, 0.85) 0%, rgba(79, 70, 229, 0.9) 100%),
            url('top1.jpg');
        background-size: cover;
        background-position: center;
    }
    
    .hero-title {
        font-size: clamp(2rem, 8vw, 3rem);
        line-height: 1.2;
        margin-bottom: var(--space-4);
    }
    
    .hero-subtitle {
        font-size: clamp(1rem, 4vw, 1.125rem);
        margin-bottom: var(--space-8);
        padding: 0 var(--space-2);
    }
    
    .hero-badge {
        font-size: 0.75rem;
        padding: var(--space-2) var(--space-3);
        margin-bottom: var(--space-4);
    }
    
    /* Platform Grid Mobile */
    .platform-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--space-3);
        max-width: 300px;
        margin: 0 auto var(--space-6);
    }
    
    .platform-item {
        padding: var(--space-3);
        min-height: 80px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
    }
    
    .platform-item img {
        width: 32px;
        height: 32px;
        margin-bottom: var(--space-2);
    }
    
    .platform-item span {
        font-size: 0.75rem;
        font-weight: 600;
    }
    
    /* Mobile Support Text */
    .mobile-support {
        margin-top: var(--space-6);
        padding: 0 var(--space-4);
    }
    
    .mobile-badge {
        font-size: 0.875rem;
        padding: var(--space-2) var(--space-4);
        max-width: 100%;
        word-wrap: break-word;
        line-height: 1.4;
        text-align: center;
    }
    
    /* App Section Mobile */
    .app-section {
        padding: var(--space-12) var(--space-4);
    }
    
    .app-header h2 {
        font-size: clamp(1.5rem, 6vw, 2rem);
        margin-bottom: var(--space-4);
    }
    
    .app-header p {
        font-size: 1rem;
        margin-bottom: var(--space-8);
    }
    
    /* Download Interface Mobile */
    .download-interface {
        padding: var(--space-6) var(--space-4);
        margin: var(--space-8) var(--space-4);
    }
    
    .input-wrapper {
        flex-direction: column;
        align-items: stretch;
        gap: var(--space-4);
    }
    
    #video-url {
        padding: var(--space-4) var(--space-4) var(--space-4) var(--space-12);
        font-size: 16px; /* Prevent zoom on iOS */
        min-height: 56px;
    }
    
    .download-btn {
        justify-content: center;
        min-height: 56px;
        font-size: 1rem;
        font-weight: 600;
    }
    
    /* Features Grid Mobile */
    .features-section {
        padding: var(--space-12) var(--space-4);
    }
    
    .features-grid {
        grid-template-columns: 1fr;
        gap: var(--space-6);
    }
    
    .feature-card {
        padding: var(--space-6);
        text-align: center;
    }
    
    /* Language Selector Mobile */
    .language-selector {
        top: 16px;
        right: 16px;
    }
    
    .lang-toggle {
        padding: 6px 12px;
        border-radius: 8px;
    }
    
    .current-lang {
        font-size: 12px;
    }
    
    .lang-dropdown {
        right: 0;
        min-width: 140px;
    }
}

/* ===== HIGH-DPI DISPLAYS ===== */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .hero-background {
        background-image: 
            linear-gradient(135deg, rgba(99, 102, 241, 0.85) 0%, rgba(79, 70, 229, 0.9) 50%, rgba(139, 92, 246, 0.8) 100%),
            url('hero-modern.jpg');
    }
}

/* ===== PREFERS REDUCED MOTION ===== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .hero-background {
        background-attachment: scroll;
    }
}

/* ===== LANGUAGE SELECTOR ===== */
.language-selector {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}

.lang-toggle {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 8px 16px;
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.lang-toggle:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

.current-lang {
    color: white;
    font-weight: 500;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.lang-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    padding: 8px;
    min-width: 160px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.lang-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lang-option {
    padding: 10px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-700);
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.lang-option:hover {
    background: var(--primary);
    color: white;
}

/* ===== TUTORIAL SECTION ===== */
.tutorial-section {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

.tutorial-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.tutorial-section h2 {
    font-size: clamp(2rem, 4vw, 2.5rem);
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 16px;
}

.tutorial-section p {
    font-size: 1.125rem;
    color: var(--gray-600);
    margin-bottom: 48px;
}

.tutorial-tabs {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 48px;
}

.tutorial-tab {
    background: white;
    border: 2px solid var(--gray-200);
    border-radius: 12px;
    padding: 12px 24px;
    cursor: pointer;
    font-weight: 500;
    font-size: 16px;
    color: var(--gray-600);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tutorial-tab:hover {
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-2px);
}

.tutorial-tab.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
    transform: translateY(-2px);
}

.tutorial-content {
    position: relative;
}

.tutorial-panel {
    display: none;
    animation: fadeIn 0.3s ease;
}

.tutorial-panel.active {
    display: block;
}

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

.tutorial-card {
    background: white;
    border-radius: 16px;
    padding: 32px 24px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 1px solid var(--gray-200);
}

.tutorial-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

.tutorial-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin: 0 auto 20px;
    color: white;
}

/* Tutorial icons with platform branding */
.tutorial-icon.platform-icon {
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.tutorial-icon.platform-icon.instagram {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    box-shadow: 0 8px 32px rgba(225, 48, 108, 0.4);
}

.tutorial-icon.platform-icon.tiktok {
    background: linear-gradient(45deg, #000000, #25f4ee, #fe2c55);
    background-size: 300% 300%;
    animation: tiktokGradient 3s ease infinite;
    box-shadow: 0 8px 32px rgba(37, 244, 238, 0.4);
}

.tutorial-icon.platform-icon.pinterest {
    background: linear-gradient(45deg, #e60023, #bd081c);
    box-shadow: 0 8px 32px rgba(230, 0, 35, 0.4);
}

.tutorial-icon.platform-icon.facebook {
    background: linear-gradient(45deg, #1877f2, #42a5f5);
    box-shadow: 0 8px 32px rgba(24, 119, 242, 0.4);
}

.tutorial-icon.platform-icon.youtube {
    background: linear-gradient(45deg, #ff0000, #cc0000);
    box-shadow: 0 8px 32px rgba(255, 0, 0, 0.4);
}

.tutorial-icon.platform-icon.twitter {
    background: linear-gradient(45deg, #1da1f2, #0d8bd9);
    box-shadow: 0 8px 32px rgba(29, 161, 242, 0.4);
}

.tutorial-icon.platform-icon.reddit {
    background: linear-gradient(45deg, #ff4500, #e03d00);
    box-shadow: 0 8px 32px rgba(255, 69, 0, 0.4);
}

.tutorial-icon.platform-icon.vimeo {
    background: linear-gradient(45deg, #1ab7ea, #0088cc);
    box-shadow: 0 8px 32px rgba(26, 183, 234, 0.4);
}

/* Adjust sizing for tutorial icons */
.tutorial-icon.platform-icon.instagram::after {
    content: '';
    width: 24px;
    height: 24px;
    border: 3px solid white;
    border-radius: 6px;
    position: relative;
}

.tutorial-icon.platform-icon.instagram::before {
    content: '';
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 2;
}

.tutorial-icon.platform-icon.facebook::after {
    content: 'f';
    font-family: 'Arial', sans-serif;
    font-size: 36px;
    font-weight: bold;
    color: white;
}

.tutorial-icon.platform-icon.twitter::after {
    content: '𝕏';
    font-size: 28px;
    color: white;
    font-weight: bold;
}

.tutorial-icon.platform-icon.pinterest::after {
    content: 'P';
    font-size: 32px;
    color: white;
    font-weight: bold;
}

.tutorial-icon.platform-icon.youtube::after {
    content: '▶';
    font-size: 24px;
    color: white;
    margin-left: 2px;
}

.tutorial-icon.platform-icon.reddit::after {
    content: 'r';
    font-size: 28px;
    color: white;
    font-weight: bold;
    font-style: italic;
}

.tutorial-icon.platform-icon.vimeo::after {
    content: 'V';
    font-size: 32px;
    color: white;
    font-weight: bold;
}

.tutorial-icon.platform-icon.tiktok::after {
    content: '♪';
    font-size: 32px;
    color: white;
    text-shadow: 2px 2px 0 #fe2c55, -2px -2px 0 #25f4ee;
}

.tutorial-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 24px;
    text-align: center;
}

.tutorial-steps {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.tutorial-card .step {
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
    padding: 12px;
    background: var(--gray-50);
    border-radius: 10px;
    transition: all 0.2s ease;
}

.tutorial-card .step:hover {
    background: rgba(102, 126, 234, 0.1);
}

.tutorial-card .step-number {
    background: var(--primary);
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    flex-shrink: 0;
}

.tutorial-card .step span:last-child {
    color: var(--gray-700);
    font-weight: 500;
    font-size: 14px;
    line-height: 1.4;
}

/* ===== FAQ SECTION ===== */
.faq-section {
    padding: 80px 0;
    background: white;
}

.faq-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.faq-section h3 {
    font-size: clamp(2rem, 4vw, 2.5rem);
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 48px;
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 32px;
    text-align: left;
}

.faq-item {
    background: var(--gray-50);
    border-radius: 16px;
    padding: 32px;
    transition: all 0.3s ease;
    border: 1px solid var(--gray-200);
}

.faq-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.faq-item h4 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 16px;
    line-height: 1.4;
}

.faq-item p {
    color: var(--gray-600);
    line-height: 1.6;
    font-size: 14px;
}

/* ===== FOOTER ===== */
.footer {
    background: var(--gray-800);
    color: white;
    padding: 40px 0;
    text-align: center;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 24px;
}

.footer-brand h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 8px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

.footer-links {
    display: flex;
    gap: 32px;
    flex-wrap: wrap;
}

.footer-links a {
    color: var(--gray-400);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.3s ease;
}

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

/* ===== ADDITIONAL MOBILE ENHANCEMENTS ===== */
@media (max-width: 768px) {
    /* Tutorial Section Mobile */
    .tutorial-section {
        padding: var(--space-12) var(--space-4);
    }
    
    .tutorial-section h2 {
        font-size: clamp(1.75rem, 7vw, 2.25rem);
        margin-bottom: var(--space-4);
    }
    
    .tutorial-section p {
        font-size: 1rem;
        margin-bottom: var(--space-8);
        padding: 0 var(--space-2);
    }
    
    .tutorial-tabs {
        flex-direction: column;
        align-items: center;
        gap: var(--space-3);
        max-width: 280px;
        margin: 0 auto var(--space-8);
    }
    
    .tutorial-tab {
        width: 100%;
        justify-content: center;
        padding: var(--space-3) var(--space-4);
        font-size: 14px;
    }
    
    .tutorial-grid {
        grid-template-columns: 1fr;
        gap: var(--space-6);
        padding: 0 var(--space-2);
    }
    
    .tutorial-card {
        padding: var(--space-6) var(--space-4);
    }
    
    .tutorial-card h3 {
        font-size: 1.125rem;
        margin-bottom: var(--space-4);
    }
    
    .tutorial-card .step {
        padding: var(--space-3);
        font-size: 0.875rem;
    }
    
    .tutorial-card .step-number {
        width: 20px;
        height: 20px;
        font-size: 11px;
        min-width: 20px;
    }
    
    /* FAQ Section Mobile */
    .faq-section {
        padding: var(--space-12) var(--space-4);
    }
    
    .faq-section h3 {
        font-size: clamp(1.5rem, 6vw, 2rem);
        margin-bottom: var(--space-6);
    }
    
    .faq-grid {
        grid-template-columns: 1fr;
        gap: var(--space-4);
    }
    
    .faq-item {
        padding: var(--space-5) var(--space-4);
    }
    
    .faq-item h4 {
        font-size: 1rem;
        margin-bottom: var(--space-3);
    }
    
    .faq-item p {
        font-size: 0.875rem;
        line-height: 1.5;
    }
    
    /* Footer Mobile */
    .footer {
        padding: var(--space-12) var(--space-4) var(--space-8);
    }
    
    .footer-container {
        flex-direction: column;
        text-align: center;
        gap: var(--space-6);
    }
    
    .footer-brand h3 {
        font-size: 1.5rem;
        margin-bottom: var(--space-3);
    }
    
    .footer-brand p {
        font-size: 0.875rem;
        margin-bottom: var(--space-4);
    }
    
    .footer-links {
        justify-content: center;
        gap: var(--space-4);
        flex-wrap: wrap;
    }
    
    .footer-links a {
        font-size: 0.875rem;
        padding: var(--space-2) var(--space-3);
    }
    
    /* Language Selector Mobile Override */
    .language-selector {
        top: 12px;
        right: 12px;
        z-index: 1001;
    }
}

/* ===== IPHONE X AND SAFE AREA ===== */
@media (max-width: 414px) {
    /* iPhone X specific styles */
    .hero {
        padding-top: env(safe-area-inset-top);
        padding-bottom: env(safe-area-inset-bottom);
    }
    
    .hero-content {
        padding: calc(var(--space-8) + env(safe-area-inset-top)) var(--space-4) var(--space-8);
    }
    
    .hero-title {
        font-size: clamp(1.75rem, 7vw, 2.5rem);
        line-height: 1.15;
        margin-bottom: var(--space-3);
    }
    
    .hero-subtitle {
        font-size: clamp(0.875rem, 3.5vw, 1rem);
        margin-bottom: var(--space-6);
        padding: 0;
    }
    
    .hero-badge {
        font-size: 0.7rem;
        padding: var(--space-1) var(--space-2);
        margin-bottom: var(--space-3);
    }
    
    /* Platform Grid iPhone X */
    .platform-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--space-2);
        max-width: 280px;
        margin: 0 auto var(--space-4);
    }
    
    .platform-item {
        padding: var(--space-2);
        min-height: 70px;
    }
    
    .platform-item img {
        width: 28px;
        height: 28px;
        margin-bottom: var(--space-1);
    }
    
    .platform-item span {
        font-size: 0.7rem;
        font-weight: 600;
    }
    
    /* Mobile Support Badge iPhone X */
    .mobile-badge {
        font-size: 0.8rem;
        padding: var(--space-2) var(--space-3);
        margin: 0 var(--space-2);
        text-align: center;
        white-space: normal;
        word-wrap: break-word;
        hyphens: auto;
    }
    
    /* Language Selector iPhone X */
    .language-selector {
        top: calc(env(safe-area-inset-top) + 8px);
        right: calc(env(safe-area-inset-right) + 8px);
    }
    
    /* Safe area for footer */
    .footer {
        padding-bottom: calc(var(--space-8) + env(safe-area-inset-bottom));
    }
}

/* ===== SMALL MOBILE DEVICES ===== */
@media (max-width: 320px) {
    .hero-title {
        font-size: 1.5rem;
    }
    
    .hero-subtitle {
        font-size: 0.875rem;
    }
    
    .platform-grid {
        max-width: 240px;
        gap: var(--space-1);
    }
    
    .platform-item {
        padding: var(--space-1);
        min-height: 60px;
    }
    
    .platform-item img {
        width: 24px;
        height: 24px;
    }
    
    .platform-item span {
        font-size: 0.65rem;
    }
    
    .mobile-badge {
        font-size: 0.75rem;
        padding: var(--space-1) var(--space-2);
    }
}