/* Responsive Design - Mobile First Approach */

/* Mobile Styles (320px - 767px) */
@media (max-width: 767px) {
    .container {
        padding: 0 15px;
    }
    
    /* Header Mobile */
    .header-content {
        flex-wrap: wrap;
        justify-content: space-between;
        align-items: center;
    }
    
    /* Main Logo Mobile */
    .main-logo {
        padding: 1rem 0 0.5rem 0;
    }
    
    .centered-logo {
        height: 80px;
    }
    
    /* Mobile Navigation */
    .menu-toggle {
        display: block;
        padding: 8px;
        border-radius: 4px;
        transition: background-color 0.3s ease;
    }
    
    .menu-toggle:hover {
        background-color: rgba(255, 107, 107, 0.1);
    }
    
    .menu-toggle:focus-visible {
        background-color: rgba(255, 107, 107, 0.1);
        outline: 2px solid #ff6b6b;
        outline-offset: 2px;
    }
    
    .menu-toggle:focus:not(:focus-visible) {
        outline: none;
    }
    
    nav {
        display: none;
        width: 100%;
        order: 3;
        background: rgba(255, 255, 255, 0.98);
        border-radius: 8px;
        margin-top: 1rem;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
        animation: slideDown 0.3s ease-out;
    }
    
    nav.active {
        display: block;
    }
    
    nav ul {
        flex-direction: column;
        gap: 0;
        padding: 1rem 0;
    }
    
    nav li {
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    }
    
    nav li:last-child {
        border-bottom: none;
    }
    
    nav a {
        display: block;
        padding: 1rem 1.5rem;
        transition: all 0.3s ease;
    }
    
    nav a:hover,
    nav a:focus {
        background-color: rgba(255, 107, 107, 0.1);
        color: #ff6b6b;
        transform: translateX(5px);
    }
    
    @keyframes slideDown {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
    
    /* Hero Mobile */
    .hero {
        padding: 2rem 0;
        margin: 0.5rem 0 1rem 0;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1.1rem;
        padding: 0 1rem;
    }
    
    /* Download Buttons Mobile */
    .download-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .download-btn {
        width: 250px;
        justify-content: center;
    }
    
    /* Features Mobile */
    .features {
        padding: 2rem 0;
    }
    
    .features h2 {
        font-size: 2rem;
        margin-bottom: 2rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .feature-card {
        padding: 1.5rem;
    }
    
    /* Screenshots Mobile */
    .screenshots {
        padding: 2rem 0;
    }
    
    .screenshots h2 {
        font-size: 2rem;
        margin-bottom: 2rem;
    }
    
    .screenshot-gallery {
        flex-direction: column;
        align-items: center;
    }
    
    .screenshot {
        max-width: 250px;
    }
    
    /* Footer Mobile */
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-links {
        flex-direction: column;
        gap: 1rem;
    }
}

/* Tablet Styles (768px - 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .screenshot-gallery {
        gap: 1.5rem;
    }
    
    .screenshot {
        max-width: 250px;
    }
}

/* Desktop Styles (1024px+) */
@media (min-width: 1024px) {
    .hero {
        padding: 6rem 0;
    }
    
    .hero h1 {
        font-size: 3.5rem;
    }
    
    .features {
        padding: 6rem 0;
    }
    
    .screenshots {
        padding: 6rem 0;
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    .download-btn,
    .feature-card,
    .screenshot,
    nav a {
        /* Larger touch targets for mobile */
        min-height: 44px;
    }
    
    .download-btn:active {
        transform: scale(0.95);
    }
    
    .feature-card:active {
        transform: translateY(-2px);
    }
}

/* High DPI Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .centered-logo,
    .screenshot img {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}

/* Landscape Mobile Optimization */
@media (max-width: 767px) and (orientation: landscape) {
    .hero {
        padding: 2rem 0;
    }
    
    .hero h1 {
        font-size: 1.8rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    .main-logo {
        padding: 0.5rem 0;
    }
    
    .centered-logo {
        height: 60px;
    }
}

/* Reduced Motion Preferences */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    /* Disable transform animations that might cause visual issues */
    .feature-card:hover,
    .download-btn:hover,
    .screenshot:hover {
        transform: none !important;
    }
}

/* Dark Mode Support - Removed to maintain consistent paper texture background */

/* Print Styles */
@media print {
    .header, .footer, .download-buttons {
        display: none;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    .hero, .feature-card {
        background: white !important;
        box-shadow: none !important;
    }
}