/* Fear City Cycles - Enhanced Responsive Styles */

/* Enhanced Mobile Experience */
@media (max-width: 768px) {
    /* Touch-optimized interactions */
    * {
        -webkit-tap-highlight-color: rgba(139, 0, 0, 0.3);
        -webkit-touch-callout: none;
    }
    
    /* Improved touch targets */
    button, .btn, .add-to-cart, .nav-link, a {
        min-height: 44px;
        padding: 12px 16px;
        touch-action: manipulation;
    }
    
    /* Mobile typography */
    body {
        font-size: 16px;
        line-height: 1.6;
    }
    
    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    h3 { font-size: 1.5rem; }
    
    /* Mobile form improvements */
    input, select, textarea {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 14px 16px;
        border-radius: 8px;
        border: 2px solid #333;
        background: #1a1a1a;
        color: white;
        width: 100%;
        box-sizing: border-box;
    }
    
    input:focus, select:focus, textarea:focus {
        border-color: #8B0000;
        outline: none;
        box-shadow: 0 0 0 3px rgba(139, 0, 0, 0.2);
    }
    
    /* Mobile search enhancements */
    #product-search {
        width: 100%;
        margin-bottom: 10px;
        position: relative;
        z-index: 10;
    }
    
    .search-results {
        position: fixed !important;
        top: auto !important;
        bottom: 0 !important;
        left: 0 !important;
        right: 0 !important;
        max-height: 50vh !important;
        border-radius: 16px 16px 0 0 !important;
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.5) !important;
    }
    
    /* Mobile product cards */
    .product-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 0 10px;
    }
    
    .product-card {
        margin-bottom: 20px;
        padding: 20px;
        border-radius: 12px;
        transition: transform 0.2s ease, box-shadow 0.2s ease;
        position: relative;
        overflow: hidden;
    }
    
    .product-card:active {
        transform: scale(0.98);
    }
    
    .product-card::before {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(139, 0, 0, 0.1), transparent);
        transition: left 0.5s ease;
    }
    
    .product-card:hover::before {
        left: 100%;
    }
    
    /* Mobile gallery improvements */
    .product-gallery {
        margin-bottom: 30px;
    }
    
    .main-product-image {
        width: 100%;
        height: 300px;
        object-fit: cover;
        border-radius: 12px;
        cursor: pointer;
        transition: transform 0.3s ease;
    }
    
    .gallery-thumbs {
        display: flex;
        gap: 10px;
        margin-top: 15px;
        overflow-x: auto;
        padding: 10px 0;
        scrollbar-width: none;
        -ms-overflow-style: none;
    }
    
    .gallery-thumbs::-webkit-scrollbar {
        display: none;
    }
    
    .gallery-thumbs img {
        min-width: 80px;
        height: 80px;
        border-radius: 8px;
        cursor: pointer;
        transition: all 0.3s ease;
    }
    
    /* Mobile cart improvements */
    .cart-notification {
        bottom: 20px !important;
        left: 20px !important;
        right: 20px !important;
        top: auto !important;
        transform: translateY(100px) !important;
        border-radius: 12px !important;
        padding: 16px 20px !important;
        font-size: 16px !important;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3) !important;
    }
    
    .cart-notification.show {
        transform: translateY(0) !important;
    }
    
    /* Mobile navigation backdrop */
    .mobile-nav-backdrop {
        backdrop-filter: blur(4px);
        -webkit-backdrop-filter: blur(4px);
    }
    
    /* Mobile menu improvements */
    .nav-menu {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 70px);
        background-color: rgba(0, 0, 0, 0.95);
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        padding-top: 50px;
        transition: left 0.3s ease;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu .nav-link {
        font-size: 1.5rem;
        margin: 20px 0;
        display: block;
        width: 100%;
        text-align: center;
    }

    .mobile-menu-toggle.active span:nth-child(1) {
        transform: rotate(-45deg) translate(-5px, 6px);
    }

    .mobile-menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-toggle.active span:nth-child(3) {
        transform: rotate(45deg) translate(-5px, -6px);
    }
}

/* Tablet Styles */
@media (max-width: 1024px) {
    .container {
        padding: 0 30px;
    }

    .hero-title {
        font-size: 3rem;
    }

    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }

    .culture-content {
        gap: 40px;
    }
}

/* Large Mobile Styles */
@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .hero {
        padding: 50px 0;
        min-height: 80vh;
    }

    .hero-title {
        font-size: 2rem;
        line-height: 1.2;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }

    .product-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .product-card {
        padding: 15px;
    }

    .product-card img {
        height: 200px;
    }

    .section-title {
        font-size: 1.8rem;
        margin-bottom: 30px;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

/* Cart Notification Responsive */
@media (max-width: 768px) {
    .cart-notification {
        right: 15px !important;
        left: 15px !important;
        top: 80px !important;
    }
}

/* Product Page Responsive */
.product-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: start;
}

@media (max-width: 768px) {
    .product-details {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

/* Form Responsive */
.contact-form {
    max-width: 600px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 700;
    color: #8B0000;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 12px;
    background-color: #1a1a1a;
    border: 1px solid #333333;
    color: #ffffff;
    font-family: 'Roboto', sans-serif;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #8B0000;
    box-shadow: 0 0 5px rgba(139, 0, 0, 0.3);
}

@media (max-width: 480px) {
    .form-group input,
    .form-group textarea,
    .form-group select {
        padding: 10px;
    }
}

/* Loading States */
.loading {
    opacity: 0.7;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #8B0000;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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