/* Preloader Styles */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #141619 0%, #1a1d21 50%, #242830 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 99999;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

.preloader.fade-out {
    opacity: 0;
    visibility: hidden;
}

.preloader-logo {
    width: 120px;
    height: 120px;
    margin-bottom: 2rem;
    animation: logoZoom 2s ease-in-out infinite;
    filter: drop-shadow(0 10px 20px rgba(255, 107, 107, 0.3));
}

@keyframes logoZoom {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.loading-text {
    font-family: 'Brush Script MT', cursive, 'Comic Sans MS', sans-serif;
    font-size: 2.5rem;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4, #667eea);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: textGlow 3s ease-in-out infinite, gradientShift 4s ease-in-out infinite;
    text-shadow: 0 0 30px rgba(255, 107, 107, 0.5);
    font-weight: bold;
    letter-spacing: 3px;
}

@keyframes textGlow {
    0%, 100% {
        filter: brightness(1);
        transform: translateY(0);
    }
    50% {
        filter: brightness(1.3);
        transform: translateY(-5px);
    }
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.loading-dots {
    display: inline-block;
    animation: dots 1.5s infinite;
}

@keyframes dots {
    0%, 20% {
        color: transparent;
        text-shadow: .25em 0 0 transparent, .5em 0 0 transparent;
    }
    40% {
        color: #ff6b6b;
        text-shadow: .25em 0 0 transparent, .5em 0 0 transparent;
    }
    60% {
        text-shadow: .25em 0 0 #4ecdc4, .5em 0 0 transparent;
    }
    80%, 100% {
        text-shadow: .25em 0 0 #4ecdc4, .5em 0 0 #667eea;
    }
}

/* Common Page Styles */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #141619 0%, #1a1d21 50%, #242830 100%);
    color: white;
    margin: 0;
    padding: 0;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-y;
}

.page-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.page-header {
    text-align: center;
    margin-bottom: 4rem;
    padding: 2rem 0;
}

.page-title {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.page-subtitle {
    font-size: 1.2rem;
    color: #b0b0b0;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.back-btn {
    position: fixed;
    top: 2rem;
    left: 2rem;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    color: white;
    border: none;
    padding: 1rem 1.5rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    z-index: 1000;
}

.back-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(255, 107, 107, 0.3);
    color: white;
    text-decoration: none;
}

/* Common Button Styles */
.primary-btn {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(79, 172, 254, 0.3);
    color: white;
    text-decoration: none;
}

.secondary-btn {
    background: transparent;
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
    padding: 1rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.secondary-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: white;
    color: white;
    text-decoration: none;
    transform: translateY(-2px);
}

/* Page Hero Styles */
.page-hero {
    background: linear-gradient(135deg, #141619 0%, #1e2328 50%, #2a2f36 100%);
    min-height: 80vh;
    display: flex;
    align-items: center;
    padding: 6rem 0 4rem;
    position: relative;
    overflow: hidden;
}

.page-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
    z-index: 2;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-text {
    color: white;
}

.hero-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: white;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.highlight {
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.2rem;
    line-height: 1.6;
    opacity: 0.9;
    margin-bottom: 2rem;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* App Showcase Mockup */
.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.app-showcase {
    position: relative;
}

.phone-mockup {
    width: 250px;
    height: 500px;
    background: linear-gradient(145deg, #2a2f36, #1e2328);
    border-radius: 25px;
    padding: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    position: relative;
}

.screen {
    width: 100%;
    height: 100%;
    background: #fff;
    border-radius: 15px;
    overflow: hidden;
    position: relative;
}

.app-interface {
    padding: 20px;
    height: 100%;
}

.app-header {
    height: 60px;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    border-radius: 8px;
    margin-bottom: 20px;
}

.app-content {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.feature-item {
    height: 40px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #ff6b6b;
}

/* Featured Project Section */
.featured-project-section {
    padding: 5rem 0;
    background: #f8f9fa;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #141619;
    margin-bottom: 1rem;
}

.section-header p {
    font-size: 1.1rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

.project-showcase {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.project-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    color: white;
    border-radius: 25px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.project-info h3 {
    font-size: 2rem;
    font-weight: 700;
    color: #141619;
    margin-bottom: 1rem;
}

.project-description {
    font-size: 1.1rem;
    line-height: 1.6;
    color: #666;
    margin-bottom: 2rem;
}

.project-features h4 {
    font-size: 1.2rem;
    font-weight: 600;
    color: #141619;
    margin-bottom: 1rem;
}

.project-features ul {
    list-style: none;
    padding: 0;
    margin-bottom: 2rem;
}

.project-features li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: #666;
}

.project-features li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #4ecdc4;
    font-weight: bold;
}

.project-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.project-visual {
    display: flex;
    justify-content: center;
}

.project-image {
    position: relative;
    overflow: hidden;
    border-radius: 15px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.featured-logo {
    width: 300px;
    height: 200px;
    object-fit: contain;
    background: white;
    padding: 2rem;
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 107, 107, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    color: white;
    font-weight: 600;
}

.project-image:hover .project-overlay {
    opacity: 1;
}

.overlay-content {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

/* Services Section - Unified Styles */
.app-services-section, #services {
    padding: 4rem 0;
    background: white;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    scroll-margin-top: 100px;
    position: relative;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}

.service-card {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
    width: 100%;
    box-sizing: border-box;
    position: relative;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.12);
}

.service-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    flex-shrink: 0;
}

.service-icon i {
    font-size: 1.8rem;
    color: white;
}

.service-card h3 {
    font-size: 1.4rem;
    font-weight: 600;
    color: #141619;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.service-card p {
    color: #666;
    line-height: 1.6;
    font-size: 0.95rem;
    margin: 0;
}

/* Mobile Responsive Adjustments */
@media (max-width: 768px) {
    .app-services-section, #services {
        padding: 3rem 0;
        touch-action: pan-y;
        -webkit-overflow-scrolling: touch;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        padding: 0 15px;
    }
    
    .service-card {
        padding: 1.5rem;
        margin: 0;
        min-height: auto;
    }
    
    .service-card:hover {
        transform: translateY(-3px); /* Reduced for mobile */
    }
    
    .service-icon {
        width: 60px;
        height: 60px;
        margin-bottom: 1rem;
    }
    
    .service-icon i {
        font-size: 1.5rem;
    }
    
    .service-card h3 {
        font-size: 1.2rem;
        margin-bottom: 0.8rem;
    }
    
    .service-card p {
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .app-services-section, #services {
        padding: 2rem 0;
    }
    
    .services-grid {
        padding: 0 10px;
        gap: 1rem;
    }
    
    .service-card {
        padding: 1rem;
    }
    
    .service-icon {
        width: 50px;
        height: 50px;
    }
    
    .service-icon i {
        font-size: 1.3rem;
    }
}



/* Responsive Design */
@media (max-width: 768px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .project-showcase {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .phone-mockup {
        width: 200px;
        height: 400px;
    }
    
    .hero-actions,
    .project-actions,
    .cta-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
        max-width: 300px;
        justify-content: center;
    }
    
    .featured-logo {
        width: 250px;
        height: 150px;
    }
    
    .container {
        padding: 0 15px;
    }
    
    .section-header {
        margin-bottom: 30px;
    }
    
    .section-header h2 {
        font-size: 1.8rem;
    }
    
    .section-header p {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .section-header h2 {
        font-size: 1.6rem;
    }
    
    .cta-content h2 {
        font-size: 2rem;
    }
    
    .phone-mockup {
        width: 180px;
        height: 360px;
    }
    
    .featured-logo {
        width: 200px;
        height: 120px;
    }
    
    .hero-container,
    .container {
        padding: 0 10px;
    }
}

/* Container and Section Fixes */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    box-sizing: border-box;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--text-primary, #333);
}

.section-header p {
    font-size: 1.1rem;
    color: var(--text-secondary, #666);
    max-width: 600px;
    margin: 0 auto;
}

/* Smooth scrolling for all sections */
html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    overflow-x: hidden;
}

/* Touch scrolling and mobile optimization */
body {
    -webkit-overflow-scrolling: touch;
    touch-action: pan-y;
}

/* Ensure services section has proper ID targeting */
#services {
    scroll-margin-top: 80px; /* Account for fixed nav */
}