/**
 * Homepage Filter Tiles Fix
 * Restores colored backgrounds to "Find Your Perfect Trail" section
 * Fixes production styling issues
 */

/* Quick Filter Section - Ensure proper styling */
.quick-filter-section {
    padding: 5rem 0;
    background-color: #ffffff;
}

.quick-filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

/* Filter Cards with colored backgrounds */
.filter-card {
    display: block;
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    text-decoration: none;
    color: #333;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: relative;
    overflow: hidden;
}

/* Specific colored backgrounds for each filter type */
.filter-card[href*="easy"] {
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
}

.filter-card[href*="moderate"] {
    background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%);
}

.filter-card[href*="challenging"] {
    background: linear-gradient(135deg, #ffebee 0%, #ffcdd2 100%);
}

.filter-card[href*="cycling"] {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
}

/* Hover effects */
.filter-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

/* Filter Icons with matching colors */
.filter-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.8);
}

.filter-icon svg {
    width: 40px;
    height: 40px;
}

/* Icon colors to match card themes */
.filter-card[href*="easy"] .filter-icon {
    color: #4CAF50;
}

.filter-card[href*="moderate"] .filter-icon {
    color: #FF9800;
}

.filter-card[href*="challenging"] .filter-icon {
    color: #F44336;
}

.filter-card[href*="cycling"] .filter-icon {
    color: #2196F3;
}

/* Typography for filter cards */
.filter-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #1a1a1a;
}

.filter-card p {
    color: #666;
    font-size: 0.875rem;
    margin: 0;
}

/* Alternative styling using nth-child for better specificity */
.quick-filter-grid .filter-card:nth-child(1) {
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
}

.quick-filter-grid .filter-card:nth-child(2) {
    background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%);
}

.quick-filter-grid .filter-card:nth-child(3) {
    background: linear-gradient(135deg, #ffebee 0%, #ffcdd2 100%);
}

.quick-filter-grid .filter-card:nth-child(4) {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
}

/* Ensure colors work on both front-page.php and template-homepage-enhanced.php */
.enhanced-homepage .filter-card[href*="easy"],
.site-main .filter-card[href*="easy"] {
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%) !important;
}

.enhanced-homepage .filter-card[href*="moderate"],
.site-main .filter-card[href*="moderate"] {
    background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%) !important;
}

.enhanced-homepage .filter-card[href*="challenging"],
.site-main .filter-card[href*="challenging"] {
    background: linear-gradient(135deg, #ffebee 0%, #ffcdd2 100%) !important;
}

.enhanced-homepage .filter-card[href*="cycling"],
.site-main .filter-card[href*="cycling"] {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%) !important;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .quick-filter-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .filter-card {
        padding: 1.5rem;
    }
    
    .filter-icon {
        width: 60px;
        height: 60px;
    }
    
    .filter-icon svg {
        width: 30px;
        height: 30px;
    }
}