/*
 * IMPORTANT: For editing rules and coding guidelines, see AI_documents/Rules/Rules_for_the_AI.txt
 * For project overview and details, see AI_documents/Project_Overview_Doc.txt
 *
 * Production Directory: http://ainspire.ai/css/services_listing_page.css
 * Development Directory: http://localhost:8000/css/services_listing_page.css
 *
 * Used in services listing page template
 * /templates/services_listing_page.php
 */

/* Services Listing Page Specific Styles */

.services-listing-main {
    position: relative;
    background: #000;
    color: #fff;
}

/* Services Listing Section */
.services-listing-section {
    padding: 4rem 0;
    background: #000;
}

.services-listing-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
}

/* Services Grid */
.services-grid {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

/* Service Card - Horizontal Layout */
.service-card {
    display: flex;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05) 0%, rgba(37, 99, 235, 0.05) 100%);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.service-card:hover::before,
.service-card.hovered::before {
    opacity: 1;
}

.service-card:hover,
.service-card.hovered {
    transform: translateY(-8px);
    border-color: rgba(59, 130, 246, 0.4);
    box-shadow: 0 20px 40px rgba(59, 130, 246, 0.2);
}

/* Service Card Image */
.service-card-image {
    flex: 0 0 400px;
    min-height: 300px;
    position: relative;
    overflow: hidden;
}

.service-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.service-card:hover .service-card-image img,
.service-card.hovered .service-card-image img {
    transform: scale(1.05);
}

/* Service Card Content */
.service-card-content {
    flex: 1;
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 2;
}

/* Service Label */
.service-label {
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 700;
    color: rgba(59, 130, 246, 0.9);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 1rem;
    padding: 0.5rem 1rem;
    background: rgba(59, 130, 246, 0.15);
    border-radius: 20px;
    border: 1px solid rgba(59, 130, 246, 0.3);
    width: fit-content;
}

/* Service Title */
.service-card-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: #fff;
    line-height: 1.2;
}

/* Service Description */
.service-card-description {
    font-size: 1.1rem;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 1.5rem;
    flex-grow: 1;
}

/* Focus Areas */
.service-focus-areas {
    margin-bottom: 2rem;
}

.focus-areas-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.focus-areas-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.focus-area-tag {
    background: rgba(59, 130, 246, 0.2);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid rgba(59, 130, 246, 0.3);
    transition: all 0.3s ease;
}

.service-card:hover .focus-area-tag,
.service-card.hovered .focus-area-tag {
    background: rgba(59, 130, 246, 0.3);
    color: #fff;
    border-color: rgba(59, 130, 246, 0.5);
}

/* Action Button */
.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    border: 2px solid rgba(59, 130, 246, 0.3);
    width: fit-content;
}

.action-btn:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    transform: translateX(4px);
    box-shadow: 0 8px 16px rgba(59, 130, 246, 0.3);
}

.action-btn svg {
    transition: transform 0.3s ease;
}

.action-btn:hover svg {
    transform: translateX(4px);
}

/* No Data Fallback */
.services-no-data {
    padding: 4rem 0;
    text-align: center;
}

.services-no-data h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: #fff;
}

.services-no-data p {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.7);
}

/* Responsive Design */

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

    .service-card-image {
        flex: 0 0 350px;
        min-height: 280px;
    }

    .service-card-content {
        padding: 2rem;
    }

    .service-card-title {
        font-size: 1.8rem;
    }

    .service-card-description {
        font-size: 1rem;
    }
}

@media (max-width: 992px) {
    .service-card-image {
        flex: 0 0 300px;
        min-height: 250px;
    }

    .service-card-content {
        padding: 1.75rem;
    }

    .service-card-title {
        font-size: 1.6rem;
    }
}

/* Mobile - Stack Vertically */
@media (max-width: 768px) {
    .services-listing-container {
        padding: 0 20px;
    }

    .services-listing-section {
        padding: 3rem 0;
    }

    .services-grid {
        gap: 2rem;
    }

    /* Stack card vertically on mobile */
    .service-card {
        flex-direction: column;
    }

    .service-card-image {
        flex: 0 0 auto;
        width: 100%;
        min-height: 200px;
        max-height: 250px;
    }

    .service-card-content {
        padding: 1.5rem;
    }

    .service-card-title {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }

    .service-card-description {
        font-size: 0.95rem;
        margin-bottom: 1rem;
    }

    .service-focus-areas {
        margin-bottom: 1.5rem;
    }

    .action-btn {
        width: 100%;
        justify-content: center;
        padding: 0.875rem 1.5rem;
        font-size: 0.95rem;
    }
}

@media (max-width: 480px) {
    .services-listing-container {
        padding: 0 15px;
    }

    .services-listing-section {
        padding: 2.5rem 0;
    }

    .services-grid {
        gap: 1.5rem;
    }

    .service-card-content {
        padding: 1.25rem;
    }

    .service-card-title {
        font-size: 1.35rem;
    }

    .service-card-description {
        font-size: 0.9rem;
        line-height: 1.6;
    }

    .service-label {
        font-size: 0.75rem;
        padding: 0.4rem 0.8rem;
    }

    .focus-area-tag {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }

    .action-btn {
        padding: 0.75rem 1.25rem;
        font-size: 0.9rem;
    }
}

/* Animation for loading */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.service-card {
    animation: fadeInUp 0.6s ease forwards;
}

.service-card:nth-child(1) { animation-delay: 0.1s; }
.service-card:nth-child(2) { animation-delay: 0.2s; }
.service-card:nth-child(3) { animation-delay: 0.3s; }
.service-card:nth-child(4) { animation-delay: 0.4s; }
.service-card:nth-child(5) { animation-delay: 0.5s; }
.service-card:nth-child(6) { animation-delay: 0.6s; }
