/* ==========================================================================
   SERVICES PAGE SPECIFIC STYLES
   ========================================================================== */

/* Hero Section Custom Styles */
.services-hero {
    position: relative;
    background-image: url('images/about_hero_bg.png'); /* Fallback to existing corporate visual asset */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    color: var(--bg-white);
    padding: 10rem 0 8rem 0;
    display: flex;
    align-items: center;
    min-height: 50vh;
    overflow: hidden;
}

/* Fallback background if image is not present */
.services-hero::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: var(--blue-gradient);
    z-index: 0;
}

.services-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 27, 51, 0.94) 0%, rgba(0, 75, 135, 0.80) 100%);
    z-index: 1;
}

.services-hero-container {
    position: relative;
    z-index: 2;
}

.services-hero-content {
    max-width: 700px;
}

.services-hero-tag {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 1rem;
    display: inline-block;
}

.services-hero-title {
    font-size: 3.5rem;
    color: var(--bg-white);
    margin-bottom: 1rem;
    line-height: 1.15;
}

.services-gold-line {
    width: 60px;
    height: 4px;
    background: var(--gold-gradient);
    border-radius: 2px;
    margin-bottom: 1.5rem;
}

.services-hero-subtitle {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 2.5rem;
    line-height: 1.6;
}

.services-hero-actions {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

/* Services Main Grid Section */
.services-section-wrapper {
    padding: 8rem 0;
    background-color: var(--bg-light);
    position: relative;
}

/* 4-column Grid for desktop */
.services-page-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    width: 100%;
}

/* Service Detail Cards styling */
.service-detail-card {
    background: var(--bg-white);
    border: 1px solid rgba(0, 75, 135, 0.06);
    border-radius: var(--border-radius-md);
    padding: 3rem 2rem;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: transform 0.4s var(--transition-smooth), 
                box-shadow 0.4s var(--transition-smooth), 
                border-color 0.4s var(--transition-smooth);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    z-index: 1;
}

/* Saffron top accent line */
.service-card-top-accent {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gold-gradient);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s var(--transition-smooth);
    z-index: 3;
}

.service-detail-card:hover .service-card-top-accent {
    transform: scaleX(1);
}

.service-detail-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(244, 123, 32, 0.25);
}

/* Icon Container */
.service-card-icon-container {
    width: 65px;
    height: 65px;
    background: rgba(0, 75, 135, 0.05);
    border-radius: var(--border-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    transition: background 0.4s var(--transition-smooth), transform 0.4s var(--transition-smooth);
    position: relative;
    z-index: 2;
}

.service-card-icon-container svg {
    width: 32px;
    height: 32px;
    fill: var(--primary);
    transition: fill 0.4s var(--transition-smooth), transform 0.4s var(--transition-smooth);
}

.service-detail-card:hover .service-card-icon-container {
    background: var(--gold-light);
    transform: rotate(5deg) scale(1.05);
}

.service-detail-card:hover .service-card-icon-container svg {
    fill: var(--gold-dark);
}

/* Card titles and description */
.service-card-title {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 1rem;
    font-family: var(--font-heading);
    transition: color 0.3s var(--transition-fast);
    z-index: 2;
}

.service-detail-card:hover .service-card-title {
    color: var(--primary-light);
}

.service-card-text {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 2rem;
    flex-grow: 1;
    z-index: 2;
}

/* "Read More" button */
.service-card-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--gold-dark);
    cursor: pointer;
    background: none;
    border: none;
    align-self: flex-start;
    transition: color 0.3s var(--transition-fast);
    z-index: 2;
    padding: 0.25rem 0;
}

.service-card-btn span {
    position: relative;
}

.service-card-btn span::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1.5px;
    background: var(--gold-dark);
    transition: width 0.3s var(--transition-fast);
}

.service-card-btn:hover span::after {
    width: 100%;
}

.arrow-icon {
    width: 16px;
    height: 16px;
    fill: var(--gold-dark);
    transition: transform 0.3s var(--transition-fast);
}

.service-card-btn:hover .arrow-icon {
    transform: translateX(4px);
}

/* Card Radial Glow Layer */
.card-glow-layer {
    position: absolute;
    bottom: -60px;
    right: -60px;
    width: 150px;
    height: 150px;
    background: radial-gradient(circle, rgba(244, 123, 32, 0.05) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    transition: transform 0.4s var(--transition-smooth), opacity 0.4s var(--transition-smooth);
    opacity: 0.6;
    z-index: 0;
}

.service-detail-card:hover .card-glow-layer {
    transform: scale(1.6);
    background: radial-gradient(circle, rgba(244, 123, 32, 0.12) 0%, transparent 70%);
    opacity: 1;
}

/* ==========================================================================
   INTERACTIVE MODAL STYLING
   ========================================================================== */
.service-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 27, 51, 0.65);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 1050;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s var(--transition-smooth);
    padding: 2rem;
}

.service-modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.service-modal-card {
    background: var(--bg-white);
    border-radius: var(--border-radius-lg);
    border: 1px solid rgba(244, 123, 32, 0.15);
    box-shadow: 0 25px 50px -12px rgba(0, 27, 51, 0.25);
    width: 100%;
    max-width: 800px;
    max-height: 85vh;
    overflow-y: auto;
    position: relative;
    transform: translateY(30px) scale(0.95);
    transition: transform 0.4s var(--transition-smooth);
    padding: 3.5rem 3rem;
}

.service-modal-overlay.active .service-modal-card {
    transform: translateY(0) scale(1);
}

/* Modal Close Button */
.modal-close-btn {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    font-size: 2.2rem;
    color: var(--text-muted);
    cursor: pointer;
    background: none;
    border: none;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s, color 0.2s;
    line-height: 1;
}

.modal-close-btn:hover {
    background-color: var(--bg-light);
    color: var(--primary-dark);
}

/* Modal Layout */
.modal-header-section {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid rgba(0, 75, 135, 0.08);
    padding-bottom: 1.5rem;
}

.modal-icon-wrapper {
    width: 60px;
    height: 60px;
    background: var(--gold-light);
    border-radius: var(--border-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.modal-icon-wrapper svg {
    width: 32px;
    height: 32px;
    fill: var(--gold-dark);
}

.modal-heading-text {
    flex-grow: 1;
}

.modal-tag {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--gold-dark);
    text-transform: uppercase;
    letter-spacing: 2px;
    display: block;
    margin-bottom: 0.25rem;
}

#modalTitle {
    font-size: 2rem;
    color: var(--primary-dark);
    margin: 0;
}

.modal-desc-section {
    margin-bottom: 2.5rem;
}

.modal-desc-section h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.75rem;
}

#modalDescription {
    font-size: 1.05rem;
    color: var(--text-dark);
    line-height: 1.7;
}

/* Modal Details Grid */
.modal-details-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
    margin-bottom: 3rem;
}

.modal-subheading {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
}

.marker-bullet {
    font-size: 1.1rem;
    flex-shrink: 0;
}

.modal-subheading h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin: 0;
}

/* Lists styling */
.modal-list {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.modal-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.4;
}

.modal-list li::before {
    content: '•';
    color: var(--gold);
    font-weight: bold;
    font-size: 1.1rem;
    line-height: 1;
    margin-top: 0.1rem;
}

.benefits-list li::before {
    content: '✓';
    color: var(--accent-green);
    font-weight: 700;
    font-size: 0.95rem;
}

/* Modal Actions */
.modal-actions-section {
    display: flex;
    gap: 1.5rem;
    border-top: 1px solid rgba(0, 75, 135, 0.08);
    padding-top: 2rem;
    flex-wrap: wrap;
}

/* Scroll Animation Base Classes */
.anim-fade-in-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s var(--transition-smooth), transform 0.8s var(--transition-smooth);
}

.anim-fade-in-up.active {
    opacity: 1;
    transform: translateY(0);
}

/* Mount animation for hero content */
.animate-fade-in-up {
    animation: fadeInUpS 1s var(--transition-smooth) forwards;
}

@keyframes fadeInUpS {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================================
   RESPONSIVE DESIGN (MEDIA QUERIES)
   ========================================================================== */

/* Large screens (Tablet landscape / smaller desktops) */
@media (max-width: 1200px) {
    .services-page-grid {
        grid-template-columns: repeat(2, 1fr); /* 2-column tablet layout */
        gap: 2rem;
    }
    
    .services-hero {
        padding: 8rem 0 6rem 0;
    }
    
    .services-hero-title {
        font-size: 3rem;
    }
    
    .services-section-wrapper {
        padding: 6rem 0;
    }
}

/* Medium screens (Tablets) */
@media (max-width: 992px) {
    .service-modal-card {
        padding: 3rem 2rem;
    }
    
    .modal-details-grid {
        grid-template-columns: 1fr; /* Stack columns on tablets */
        gap: 2rem;
    }
}

/* Mobile screens */
@media (max-width: 640px) {
    .services-page-grid {
        grid-template-columns: 1fr; /* 1-column mobile layout */
        gap: 1.5rem;
    }
    
    .service-detail-card {
        padding: 2.5rem 1.5rem;
    }
    
    .services-hero {
        padding: 7rem 0 5rem 0;
        text-align: center;
    }
    
    .services-gold-line {
        margin: 0 auto 1.5rem auto;
    }
    
    .services-hero-actions {
        justify-content: center;
    }
    
    .services-hero-actions .btn {
        width: 100%;
    }
    
    .services-hero-title {
        font-size: 2.2rem;
    }
    
    .services-hero-subtitle {
        font-size: 1.1rem;
    }
    
    .service-modal-overlay {
        padding: 1rem;
    }
    
    .service-modal-card {
        padding: 2rem 1.5rem;
    }
    
    #modalTitle {
        font-size: 1.5rem;
    }
    
    .modal-header-section {
        gap: 1rem;
    }
    
    .modal-actions-section .btn {
        width: 100%;
    }
}
