/* Mobile Responsive Fixes for Portfolio */

/* Mobile Navigation Menu */
.mobile-menu {
    display: none;
    position: fixed;
    top: 5rem;
    left: 0;
    right:  0;
    background: rgba(17, 24, 39, 0.98);
    backdrop-filter: blur(12px);
    border-top: 1px solid #374151;
    z-index: 40;
    animation: slideDown 0.3s ease-out;
}

.mobile-menu.active {
    display: block;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile-specific responsive improvements */
@media (max-width: 768px) {
    /* Reduce section padding on mobile */
    section {
        padding-top: 3rem !important;
        padding-bottom: 3rem !important;
    }

    /* Reduce large margins on mobile */
    .mb-16 {
        margin-bottom: 2rem !important;
    }

    .mb-12 {
        margin-bottom: 1.5rem !important;
    }

    .mb-10 {
        margin-bottom: 1.25rem !important;
    }

    .mb-6 {
        margin-bottom: 1rem !important;
    }

    .mt-10 {
        margin-top: 1.5rem !important;
    }

    .mt-12 {
        margin-top: 1.5rem !important;
    }

    /* Reduce gap spacing in grids */
    .gap-12 {
        gap: 1.5rem !important;
    }

    .gap-8 {
        gap: 1rem !important;
    }

    /* Fix sticky cards on mobile - make them non-sticky */
    .sticky-card {
        position: relative !important;
        top: auto !important;
        margin-bottom: 2rem !important;
    }

    /* Better mobile text sizes */
    h1 {
        font-size: 2.5rem !important;
        line-height: 1.1 !important;
    }

    h2 {
        font-size: 2rem !important;
    }

    /* Safer padding for mobile */
    .max-w-7xl {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }

    /* Ensure touch-friendly targets */
    nav a, button {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    /* Disable parallax effects on mobile for performance */
    .parallax-image {
        transform: none !important;
    }

    /* Better mobile image heights */
    .parallax-wrapper {
        height: 200px !important;
    }

    /* Mobile project cards - better spacing */
    .sticky-card {
        padding: 1rem !important;
    }

    /* Small text on mobile for better readability */
    p {
        font-size: 0.95rem;
        line-height: 1.6;
    }

    /* Override pt-24 on mobile */
    .pt-24 {
        padding-top: 1.5rem !important;
    }

    /* Hero section adjustments */
    #home {
        padding-top: 1.5rem !important;
        min-height: auto !important;
    }

    /* Footer spacing */
    footer {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }
}

/* Small mobile devices */
@media (max-width: 480px) {
    /* Even smaller section padding for very small screens */
    section {
        padding-top: 2rem !important;
        padding-bottom: 2rem !important;
    }

    h1 {
        font-size: 2rem !important;
    }

    h2 {
        font-size: 1.75rem !important;
    }

    .text-5xl, .text-4xl {
        font-size: 1.75rem !important;
    }

    .text-3xl {
        font-size: 1.5rem !important;
    }
}
