/* Mobile Responsiveness Enhancements */

/* Poojas Listing Page */
@media (max-width: 1024px) {
    .poojas-container {
        grid-template-columns: 1fr !important;
    }
    
    .filter-sidebar {
        position: fixed;
        left: -100%;
        top: 0;
        height: 100vh;
        width: 280px;
        background: white;
        z-index: 1000;
        transition: left 0.3s ease;
        overflow-y: auto;
    }
    
    .filter-sidebar.active {
        left: 0;
    }
    
    .mobile-filter-toggle {
        display: block !important;
        position: fixed;
        bottom: 20px;
        right: 20px;
        z-index: 999;
        background: var(--primary);
        color: white;
        padding: 1rem;
        border-radius: 50%;
        box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    }
}

@media (max-width: 768px) {
    /* Pooja Cards */
    .pooja-card {
        margin-bottom: 1rem;
    }
    
    .pooja-grid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }
    
    /* Dashboard */
    .dashboard-container {
        grid-template-columns: 1fr !important;
    }
    
    .dashboard-sidebar {
        position: relative;
        margin-bottom: 2rem;
    }
    
    .dashboard-stats {
        grid-template-columns: repeat(2, 1fr) !important;
    }
    
    /* Admin Tables */
    .admin-table {
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    /* Header Navigation */
    .nav-links {
        display: none;
    }
    
    .mobile-menu {
        display: block !important;
    }
    
    /* Hero Sections */
    .hero-section {
        padding: 2rem 1rem !important;
    }
    
    .hero-section h1 {
        font-size: 1.75rem !important;
    }
    
    /* Forms */
    .form-row {
        flex-direction: column !important;
    }
    
    .form-row > * {
        width: 100% !important;
    }
}

@media (max-width: 480px) {
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    .dashboard-stats {
        grid-template-columns: 1fr !important;
    }
    
    .btn {
        width: 100%;
        text-align: center;
    }
    
    .modal {
        padding: 1rem;
    }
    
    .modal-content {
        width: 100% !important;
        margin: 0;
    }
}

/* Touch-friendly improvements */
@media (hover: none) and (pointer: coarse) {
    .btn, .menu-item, a {
        min-height: 44px;
        display: flex;
        align-items: center;
    }
    
    input, select, textarea {
        font-size: 16px; /* Prevents zoom on iOS */
    }
}

/* Landscape mode adjustments */
@media (max-width: 768px) and (orientation: landscape) {
    .hero-section {
        min-height: auto !important;
        padding: 1.5rem 1rem !important;
    }
}

/* Print styles */
@media print {
    .no-print, .sidebar, .header, .footer, .btn {
        display: none !important;
    }
    
    .container {
        max-width: 100% !important;
    }
}
