/* ============================================
   MOBILE-OPTIMIZED STYLES
   This file will be loaded on mobile devices
============================================ */

/* Mobile Device Class */
body.mobile-device {
    font-size: 14px;
}

/* Mobile Header */
.mobile-header {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    z-index: 1001;
    padding: 15px 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    align-items: center;
    justify-content: space-between;
}

body.mobile-device .mobile-header {
    display: flex;
}

body.mobile-device .navbar {
    display: none;
}

.mobile-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    color: #4361ee;
}

.mobile-logo i {
    font-size: 1.8rem;
}

.mobile-menu-toggle {
    width: 40px;
    height: 40px;
    background: #4361ee;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
}

/* Mobile Navigation Menu */
.mobile-nav-menu {
    position: fixed;
    top: 0;
    left: -100%;
    width: 85%;
    height: 100vh;
    background: white;
    z-index: 1002;
    transition: left 0.3s ease;
    box-shadow: 5px 0 30px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
}

.mobile-nav-menu.active {
    left: 0;
}

.mobile-nav-header {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #eee;
}

.mobile-close-menu {
    width: 40px;
    height: 40px;
    background: #f5f5f5;
    border: none;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: #333;
}

.mobile-nav-links {
    flex: 1;
    list-style: none;
    padding: 20px 0;
}

.mobile-nav-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 18px 25px;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    border-left: 4px solid transparent;
    transition: all 0.3s ease;
}

.mobile-nav-link.active,
.mobile-nav-link:hover {
    background: rgba(67, 97, 238, 0.05);
    border-left-color: #4361ee;
    color: #4361ee;
}

.mobile-nav-link i {
    width: 24px;
    text-align: center;
    font-size: 1.2rem;
}

.mobile-nav-footer {
    padding: 20px;
    border-top: 1px solid #eee;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

.mobile-contact-info {
    margin-top: 20px;
    font-size: 0.9rem;
    color: #666;
}

.mobile-contact-info p {
    margin: 8px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Mobile Specific Adjustments */
body.mobile-device .hero {
    padding: 100px 0 60px;
    margin-top: 60px;
}

body.mobile-device .hero-title {
    font-size: 2.2rem;
    line-height: 1.3;
}

body.mobile-device .hero-description {
    font-size: 1rem;
    margin-bottom: 25px;
}

body.mobile-device .hero-buttons {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    margin-bottom: 30px;
}

body.mobile-device .hero-buttons .btn {
    width: 100%;
    justify-content: center;
}

body.mobile-device .hero-stats {
    justify-content: space-around;
    gap: 15px;
}

body.mobile-device .stat-number {
    font-size: 2rem;
}

body.mobile-device .hero-image {
    margin-top: 40px;
}

body.mobile-device .dashboard-screen {
    height: 250px;
    padding: 20px;
}

body.mobile-device .dashboard-widgets {
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

body.mobile-device .chart-area {
    grid-column: span 2;
    margin-top: 15px;
}

/* Applications Grid - Mobile */
body.mobile-device .apps-grid {
    grid-template-columns: 1fr;
    gap: 20px;
}

body.mobile-device .app-card {
    padding: 25px 20px;
    margin: 0;
}

body.mobile-device .app-icon {
    width: 80px;
    height: 80px;
    font-size: 2.2rem;
    margin-bottom: 20px;
}

body.mobile-device .app-card h3 {
    font-size: 1.3rem;
}

body.mobile-device .app-features span {
    font-size: 0.85rem;
    justify-content: flex-start;
}

/* Features Grid - Mobile */
body.mobile-device .features-grid {
    grid-template-columns: 1fr;
    gap: 20px;
}

body.mobile-device .feature-card {
    padding: 25px 20px;
}

body.mobile-device .feature-icon {
    width: 70px;
    height: 70px;
    font-size: 1.8rem;
    margin-bottom: 20px;
}

/* Testimonials - Mobile */
body.mobile-device .testimonials-slider {
    flex-direction: column;
    gap: 20px;
    padding: 10px;
}

body.mobile-device .testimonial-card {
    min-width: 100%;
    padding: 25px;
}

/* Contact - Mobile */
body.mobile-device .contact-grid {
    grid-template-columns: 1fr;
    gap: 30px;
    padding: 25px;
}

body.mobile-device .contact-info h2 {
    font-size: 1.8rem;
}

/* Footer - Mobile */
body.mobile-device .footer-content {
    grid-template-columns: 1fr;
    gap: 30px;
    text-align: center;
}

body.mobile-device .footer-logo .logo {
    justify-content: center;
}

body.mobile-device .footer-bottom {
    flex-direction: column;
    gap: 15px;
}

/* Mobile Floating Action Button */
.mobile-fab {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #4361ee, #3a0ca3);
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    box-shadow: 0 4px 20px rgba(67, 97, 238, 0.3);
    z-index: 999;
    cursor: pointer;
    transition: all 0.3s ease;
}

body.mobile-device .mobile-fab {
    display: flex;
}

.mobile-fab:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 25px rgba(67, 97, 238, 0.4);
}

/* Mobile Contact Modal */
.mobile-contact-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1003;
    padding: 20px;
}

.mobile-contact-modal.active {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 20px;
    width: 100%;
    max-width: 400px;
    animation: modalSlideUp 0.3s ease;
}

@keyframes modalSlideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    color: #333;
}

.modal-close {
    width: 40px;
    height: 40px;
    background: #f5f5f5;
    border: none;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #333;
    font-size: 1.2rem;
}

.modal-body {
    padding: 20px;
}

.contact-options {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-top: 20px;
}

.contact-option {
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    text-decoration: none;
    color: #333;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
}

.contact-option:hover {
    background: #4361ee;
    color: white;
    border-color: #4361ee;
    transform: translateY(-3px);
}

.contact-option i {
    font-size: 1.8rem;
}

/* Touch-friendly improvements */
body.mobile-device .btn,
body.mobile-device .app-card,
body.mobile-device .feature-card,
body.mobile-device .contact-option {
    min-height: 44px;
    touch-action: manipulation;
}

body.mobile-device input,
body.mobile-device select,
body.mobile-device textarea,
body.mobile-device button {
    font-size: 16px; /* Prevents zoom on iOS */
}

/* Improved scrolling for mobile */
body.mobile-device {
    -webkit-overflow-scrolling: touch;
}

body.mobile-device .container {
    padding: 0 15px;
}

/* Hide unnecessary elements on mobile */
body.mobile-device .nav-buttons {
    display: none;
}

/* Optimize spacing for mobile */
body.mobile-device section {
    padding: 60px 0;
}

body.mobile-device .section-title {
    font-size: 2rem;
    margin-bottom: 10px;
}

body.mobile-device .section-subtitle {
    font-size: 1rem;
    margin-bottom: 30px;
}

/* Better tap targets */
body.mobile-device .app-footer,
body.mobile-device .feature-card {
    cursor: pointer;
}

/* Swipe to close for modal */
.modal-content {
    touch-action: pan-y;
}

/* Back to top button positioning */
body.mobile-device .back-to-top {
    bottom: 90px;
    right: 20px;
    width: 50px;
    height: 50px;
}

/* Newsletter form mobile optimization */
body.mobile-device .newsletter-form {
    flex-direction: column;
}

body.mobile-device .newsletter-form input {
    width: 100%;
    margin-bottom: 10px;
}

body.mobile-device .newsletter-form button {
    width: 100%;
}