/* Custom styles for header */
#main-header {
    transition: all 0.3s ease;
    background-color: transparent;
}

#main-header.scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(5px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Dark text for transparent header */
#main-header .text-gray-800 {
    text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

/* Adjust text color when header is scrolled */
#main-header.scrolled .text-gray-800 {
    text-shadow: none;
}

.search-container {
    margin-top: 80px; /* Add space for fixed header */
}

/* Add a gradient overlay behind the transparent header for better text visibility */
#main-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0,0,0,0.2) 0%, rgba(0,0,0,0) 100%);
    pointer-events: none;
    transition: opacity 0.3s ease;
    opacity: 1;
}

#main-header.scrolled::before {
    opacity: 0;
}

/* Categories Section Styles */
.categories-section {
    max-width: 1152px;
    margin: 4rem auto 0;
    padding: 0 1rem;
}

.categories-header {
    text-align: center;
    margin-bottom: 2rem;
}

.categories-header h2 {
    font-size: 1.875rem;
    font-weight: 700;
    color: #15803d;
    margin-bottom: 0.5rem;
}

.categories-header p {
    color: #4b5563;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 1.5rem;
}

@media (min-width: 640px) {
    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .categories-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.category-item {
    position: relative;
    text-decoration: none;
}

.category-card {
    background: white;
    padding: 1.5rem;
    border-radius: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 1s ease;
}

.category-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    transition: all 1s ease;
}

.category-icon svg {
    width: 1.5rem;
    height: 1.5rem;
}

.education-icon {
    background-color: #dcfce7;
}

.education-icon svg {
    color: #16a34a;
}

.healthcare-icon {
    background-color: #fee2e2;
}

.healthcare-icon svg {
    color: #dc2626;
}

.hotels-icon {
    background-color: #dbeafe;
}

.hotels-icon svg {
    color: #2563eb;
}

.services-icon {
    background-color: #f3e8ff;
}

.services-icon svg {
    color: #9333ea;
}

.category-card h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
    margin-bottom: 0.5rem;
}

.category-card p {
    font-size: 0.875rem;
    color: #4b5563;
}

@keyframes categoryHighlight {
    0%, 100% {
        opacity: 0;
    }
    25% {
        opacity: 1;
    }
    75% {
        opacity: 1;
    }
}

.category-item::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: linear-gradient(
        45deg,
        rgba(34, 197, 94, 0.1),
        rgba(239, 68, 68, 0.1),
        rgba(59, 130, 246, 0.1),
        rgba(168, 85, 247, 0.1)
    );
    border-radius: 0.75rem;
    opacity: 0;
    transform: scale(1.02);
    transition: all 0.5s ease;
    animation: categoryHighlight 3s infinite;
    pointer-events: none;
}

.category-item:nth-child(1)::after {
    animation-delay: 0s;
}

.category-item:nth-child(2)::after {
    animation-delay: 0.75s;
}

.category-item:nth-child(3)::after {
    animation-delay: 1.5s;
}

.category-item:nth-child(4)::after {
    animation-delay: 2.25s;
}

.category-item:hover::after {
    opacity: 1;
    animation: none;
}

.category-item:hover .category-card {
    transform: translateY(-4px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
                0 2px 4px -1px rgba(0, 0, 0, 0.06);
}
