/* Reset & Base Styles */
:root {
    --primary-color: #BF253A;
    --secondary-color: #EF416E;
    --text-color: #333333;
    --bg-color: #FFFFFF;
    --light-gray: #f4f4f4;
    --footer-bg: #1a1a1a;
    --footer-text: #e0e0e0;
    --font-main: 'DM Sans', sans-serif;
    --radius-card: 16px;
    --shadow-soft: 0 6px 18px rgba(0,0,0,0.06);
    --shadow-hover: 0 12px 28px rgba(0,0,0,0.10);
    --transition-fast: 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}

@font-face {
    font-family: 'DM Sans';
    src: url('../assets/DM_Sans/DMSans-VariableFont_opsz,wght.ttf') format('truetype');
    font-weight: 100 900;
    font-style: normal;
}

@font-face {
    font-family: 'DM Sans';
    src: url('../assets/DM_Sans/DMSans-Italic-VariableFont_opsz,wght.ttf') format('truetype');
    font-weight: 100 900;
    font-style: italic;
}

@font-face {
  font-family: 'Libre Baskerville';
  src: url('../admin/Libre_Baskerville/LibreBaskerville-VariableFont_wght.ttf') format('truetype');
  font-weight: 400 700;
  font-style: normal;
}

@font-face {
  font-family: 'Libre Baskerville';
  src: url('../admin/Libre_Baskerville/LibreBaskerville-Italic-VariableFont_wght.ttf') format('truetype');
  font-weight: 400 700;
  font-style: italic;
}

@font-face {
  font-family: 'Roboto';
  src: url('../admin/Roboto/Roboto-VariableFont_wdth,wght.ttf') format('truetype');
  font-weight: 100 900;
  font-style: normal;
}

@font-face {
  font-family: 'Roboto';
  src: url('../admin/Roboto/Roboto-Italic-VariableFont_wdth,wght.ttf') format('truetype');
  font-weight: 100 900;
  font-style: italic;
}

@font-face {
  font-family: 'Science Gothic';
  src: url('../admin/Science_Gothic/ScienceGothic-VariableFont_CTRS,slnt,wdth,wght.ttf') format('truetype');
  font-weight: 100 900;
  font-style: normal;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Custom Slim Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #555;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: hidden;
    width: 100%;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

ul {
    list-style: none;
}

/* Header Styles */
header {
    background-color: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(0,0,0,0.03);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 1rem 0;
}

.header-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 50px;
    width: auto;
}

.nav-menu {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-link {
    font-weight: 500;
    color: #333;
    font-size: 1rem;
}

.nav-link:hover, .nav-link.active {
    color: var(--primary-color);
}

.cta-button {
    background-color: var(--primary-color);
    color: #fff;
    padding: 10px 25px;
    border-radius: 50px;
    font-weight: 700;
    transition: background-color 0.3s ease, transform 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.cta-button:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
    color: #fff;
}

.mobile-menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Main Content Wrapper */
main {
    width: 100%;
    flex: 1 0 auto;
}

/* General Layout & Utilities */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 80px 0;
}

/* Smooth Animations */

/* Update transitions to be smoother globally where applicable */
a, button, .card, .btn, .hover-raise, .hover-smooth, .service-card, .value-prop-card, .portfolio-item {
    transition-timing-function: cubic-bezier(0.2, 0.8, 0.2, 1); /* Ease-out-cubic / smooth feel */
    transition-duration: 0.4s; /* Slightly longer than default 0.25s/0.3s */
}

/* Premium Card System */
.card {
    background: #fff;
    border-radius: var(--radius-card);
    border: 1px solid #eaeaea;
    box-shadow: var(--shadow-soft);
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), border-color 0.4s ease;
    will-change: transform;
}

.card:hover {
    transform: translateY(-8px); /* Increased lift for better feel */
    box-shadow: 0 20px 40px rgba(0,0,0,0.12); /* Softer, larger shadow */
    border-color: #ddd;
}

.card--tech {
    background: linear-gradient(#ffffff, #ffffff) padding-box,
                linear-gradient(135deg, rgba(191,37,58,0.35), rgba(239,65,110,0.35)) border-box;
    border: 1px solid transparent;
}

.hover-raise {
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}
.hover-raise:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }

.text-center { text-align: center; }
.bg-light { background-color: var(--light-gray); }
.text-white { color: #fff; }
.mt-4 { margin-top: 1.5rem; }

.section-header {
    margin-bottom: 60px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: var(--text-color);
}

/* Clients & Partners Section Styles */
.clients-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.client-card {
    background: #fff;
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-soft);
    overflow: hidden;
    position: relative;
    height: 220px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: all 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    cursor: default;
    border: 1px solid #eee;
}

.client-logo-wrapper {
    padding: 30px;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.4s ease;
    z-index: 1;
}

.client-logo-wrapper img {
    max-width: 80%;
    max-height: 80px;
    object-fit: contain;
    filter: grayscale(100%);
    transition: filter 0.3s ease, opacity 0.3s ease;
    opacity: 0.7;
}

.client-details {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.6) 50%, rgba(0,0,0,0.1) 100%);
    padding: 20px;
    color: #fff;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    z-index: 2;
    pointer-events: none; /* Let clicks pass through if needed, though no links requested */
}

.client-details h3 {
    font-size: 1.2rem;
    margin-bottom: 5px;
    color: #fff;
    font-weight: 700;
    transform: translateY(10px);
    transition: transform 0.4s ease 0.1s;
}

.client-details p {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.9);
    margin: 0;
    transform: translateY(10px);
    transition: transform 0.4s ease 0.2s;
}

/* Hover Effects */
.client-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    border-color: transparent;
}

.client-card:hover .client-logo-wrapper {
    transform: scale(0.9) translateY(-15px);
}

.client-card:hover .client-logo-wrapper img {
    filter: grayscale(0%);
    opacity: 1;
}

.client-card:hover .client-details {
    opacity: 1;
    transform: translateY(0);
}

/* Hero Process Section Styles (New) */
.hero-process-section {
    width: 100%;
    background-color: var(--bg-color);
    padding: 80px 0;
    overflow: hidden; /* Prevent overflow from hover effects */
}

@media (min-width: 768px) {
    .hero-process-section {
        padding: 100px 0;
    }
}

.hero-grid-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 48px;
    padding: 0 20px;
    max-width: 1200px;
    margin: 0 auto;
}

@media (min-width: 768px) {
    .hero-grid-layout {
        grid-template-columns: 1fr 2fr;
        gap: 32px;
        align-items: center; /* Vertically center content */
    }
}

@media (min-width: 1024px) {
    .hero-grid-layout {
        gap: 64px;
    }
}

/* Left Content */
.hero-intro {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    text-align: left;
}

.hero-subtitle {
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--primary-color);
    
    /* Typewriter Effect */
    display: inline-block;
    overflow: hidden;
    border-right: 2px solid var(--primary-color); /* Slimmer cursor */
    line-height: 1.2; /* Match text height */
    padding-right: 4px; /* Space from text */
    white-space: nowrap;
    width: 0;
    animation: 
        typing 2.5s steps(30, end) forwards,
        blink-caret 0.75s step-end infinite;
    max-width: fit-content;
}

/* Typewriter Keyframes */
@keyframes typing {
    from { width: 0; }
    to { width: 15ch; } /* Approx width for "Our Expertise" */
}

@keyframes blink-caret {
    from, to { border-color: transparent; }
    50% { border-color: var(--primary-color); }
}

.hero-intro .hero-title {
    margin-bottom: 1rem;
    font-size: 4rem; /* Doubled from 2rem */
    font-weight: 700;
    line-height: 1.1; /* Tighter line height for large text */
    letter-spacing: -0.02em;
    color: var(--text-color);
    margin-left: 0;
    margin-right: 0;
    text-align: left;
}

@media (min-width: 768px) {
    .hero-intro .hero-title {
        font-size: 5rem; /* Doubled from 2.5rem */
    }
}

.hero-intro .hero-description {
    margin-bottom: 1.5rem; /* Standard gap for mobile */
    font-size: 1rem;
    color: #666; /* muted foreground */
    line-height: 1.6;
    margin-left: 0;
    margin-right: 0;
    text-align: left;
    max-width: 600px;
}

.hero-intro .cta-button {
    margin-top: 0;
}

@media (min-width: 768px) {
    .hero-intro .hero-description {
        margin-bottom: 1rem; /* Reduced bottom margin for tighter fit */
    }
    .hero-intro .cta-button {
        margin-top: 0.5rem; /* Minimal gap for desktop */
    }
}

/* Right Content - Cards Grid */
.hero-cards-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* 2 columns on mobile */
    column-gap: 8px; /* Minimal gap for mobile */
    row-gap: 8px;
}

@media (min-width: 640px) {
    .hero-cards-grid {
        grid-template-columns: repeat(2, 1fr);
        column-gap: 32px;
        row-gap: 48px;
    }
}

/* Hero Card */
.hero-card {
    position: relative;
    width: 100%;
    border-radius: var(--radius-card);
    border: 1px solid #eaeaea; /* border-border */
    background-color: #fff; /* bg-card */
    padding: 24px;
    transition: all 0.3s ease;
    cursor: pointer;
}

/* Compact Card Styles for Mobile */
@media (max-width: 640px) {
    .hero-card {
        padding: 6px; /* Ultra tight padding */
        border-radius: 8px; /* Smaller radius */
    }
    .hero-card-icon {
        width: 20px; /* Nano icon box */
        height: 20px;
        margin-bottom: 0.2rem;
        border-radius: 3px;
        border-width: 0.5px;
    }
    .hero-card-icon svg {
        width: 10px; /* Nano icon */
        height: 10px;
    }
    .hero-card-title {
        font-size: 0.65rem; /* Nano title */
        margin-bottom: 0;
        line-height: 1;
        font-weight: 700;
    }
    .hero-card-desc {
        font-size: 0.55rem; /* Nano desc */
        line-height: 1.1;
        margin-top: 2px;
        display: -webkit-box;
        -webkit-line-clamp: 2; /* Limit to 2 lines */
        line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
    /* Hide lines on mobile for cleaner look */
    .hero-card-line-h, .hero-card-line-v {
        display: none;
    }
}

.hero-card:hover {
    border-color: rgba(191, 37, 58, 0.6); /* primary/60 */
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05); /* shadow-lg */
}

/* Decorative Line */
.hero-card-line-h {
    position: absolute;
    left: 50%;
    top: 0;
    height: 1px;
    width: 50%;
    transform: translateX(-50%);
    background-color: #eaeaea; /* border */
    transition: background-color 0.3s ease;
}

.hero-card:hover .hero-card-line-h {
    background-color: rgba(191, 37, 58, 0.6);
}

/* For larger screens, side line */
.hero-card-line-v {
    display: none;
    position: absolute;
    left: -1px;
    top: 50%;
    height: 50%;
    width: 1px;
    transform: translateY(-50%);
    background-color: #eaeaea;
    transition: background-color 0.3s ease;
}

@media (min-width: 768px) {
    .hero-card-line-v {
        display: block;
    }
    .hero-card-line-h {
        display: none;
    }
}

.hero-card:hover .hero-card-line-v {
    background-color: rgba(191, 37, 58, 0.6);
}

/* Icon Container */
.hero-card-icon {
    margin-bottom: 1rem;
    display: flex;
    height: 48px;
    width: 48px;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    border: 1px solid #eaeaea;
    background-color: var(--bg-color);
    color: var(--primary-color);
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.hero-card:hover .hero-card-icon {
    background-color: var(--primary-color);
    color: #fff; /* primary-foreground */
}

.hero-card-icon svg {
    height: 24px;
    width: 24px;
}

/* Card Content */
.hero-card-content {
    display: flex;
    flex-direction: column;
}

.hero-card-title {
    margin-bottom: 0.25rem;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-color);
}

.hero-card-desc {
    font-size: 0.875rem;
    color: #666; /* muted-foreground */
}

.client-card:hover .client-details h3,
.client-card:hover .client-details p {
    transform: translateY(0);
}

.section-header p {
    font-size: 1.1rem;
    color: #666;
}

/* Scroll Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* --- New Component Styles --- */

/* Utility & Animation Extensions */
.overflow-hidden { overflow: hidden; }
.mb-4 { margin-bottom: 1.5rem; }
.mb-5 { margin-bottom: 3rem; }
.lead { font-size: 1.25rem; font-weight: 400; line-height: 1.7; color: #555; }
.shadow-lg { box-shadow: 0 20px 50px rgba(0,0,0,0.15); }

.reveal.from-left { transform: translateX(-50px); }
.reveal.from-right { transform: translateX(50px); }
.reveal.active.from-left, .reveal.active.from-right { transform: translateX(0); }

/* Carousel Component */
.carousel-wrapper {
    position: relative;
    width: 100%;
    max-width: 1000px;
    margin: 40px auto 0;
    overflow: hidden;
    padding: 20px 0;
}

.carousel-track-container {
    overflow: hidden;
    width: 100%;
}

.carousel-track {
    display: flex;
    transition: transform 0.5s ease-in-out;
    width: 100%;
}

.carousel-slide {
    min-width: 100%;
    padding: 0 15px;
    box-sizing: border-box;
    display: flex;
    justify-content: center;
}

/* Carousel Navigation Buttons */
.carousel-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: #fff;
    border: 1px solid #eee;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    z-index: 10;
    transition: all 0.3s ease;
    color: var(--primary-color);
}

.carousel-button:hover {
    background: var(--primary-color);
    color: #fff;
    transform: translateY(-50%) scale(1.1);
}

.carousel-button--left { left: 10px; }
.carousel-button--right { right: 10px; }

/* Carousel Indicators */
.carousel-nav {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

/* Rich Text Content Styles (Quill Support) */
.benefit-content ul, .popup-text ul,
.benefit-content ol, .popup-text ol {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
    padding-left: 1rem;
}

.benefit-content ul, .popup-text ul {
    list-style-type: disc;
}

.benefit-content ol, .popup-text ol {
    list-style-type: decimal;
}

.benefit-content li, .popup-text li {
    margin-bottom: 0.25rem;
}

.benefit-content p, .popup-text p {
    margin-bottom: 1rem;
}

.benefit-content h1, .benefit-content h2, .benefit-content h3,
.popup-text h1, .popup-text h2, .popup-text h3 {
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

/* Quill Alignment Classes */
.ql-align-center { text-align: center; }
.ql-align-right { text-align: right; }
.ql-align-justify { text-align: justify; }

/* Quill Indent Classes */
.ql-indent-1 { padding-left: 3em; }
.ql-indent-2 { padding-left: 6em; }
.ql-indent-3 { padding-left: 9em; }

.carousel-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: none;
    background: #ddd;
    cursor: pointer;
    transition: all 0.3s ease;
}

.carousel-indicator.current-slide {
    background: var(--primary-color);
    transform: scale(1.2);
}

/* Carousel Card Styling Override */
.carousel-slide .value-prop-card {
    width: 100%;
    max-width: 600px;
    padding: 40px;
    text-align: center;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    border: 1px solid #f0f0f0;
}

.card-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    display: inline-block;
    background: rgba(191, 37, 58, 0.1);
    padding: 15px;
    border-radius: 50%;
}

.card-image-wrapper {
    width: 100%;
    height: 240px;
    margin-bottom: 25px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}

.card-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.value-prop-card:hover .card-image-wrapper img {
    transform: scale(1.08);
}

/* About Section Enhancements */
.about-image-container {
    position: relative;
    padding: 40px; /* More space for pop-outs */
    z-index: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Remove Blur Effect on Services Card */
#blur-overlay, .hero-overlay {
    display: none !important; /* Force remove if they were doing full screen blur */
}

/* Ensure no blur on card hover */
.service-card:hover, .service-card-small:hover, .card:hover {
    filter: none !important;
    backdrop-filter: none !important;
}

.about-img-hover {
    width: 100%;
    display: block;
    position: relative;
    z-index: 1;
}

/* Pop-out Animation on Web Hover */
.pop-out-image {
    position: absolute;
    width: 180px; /* Fixed nice size */
    height: 120px;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.2);
    transition: all 0.8s cubic-bezier(0.34, 1.56, 0.64, 1); /* Bouncy/Smooth pop */
    opacity: 0;
    z-index: 2;
    border: 4px solid #fff;
}

.pop-1 {
    bottom: 20px;
    left: 0;
    transform: translateX(-40px) translateY(40px) rotate(-10deg) scale(0.8);
}

.pop-2 {
    top: 20px;
    right: 0;
    transform: translateX(40px) translateY(-40px) rotate(10deg) scale(0.8);
}

.about-image-container:hover .pop-1 {
    opacity: 1;
    transform: translateX(-20px) translateY(10px) rotate(-5deg) scale(1);
}

.about-image-container:hover .pop-2 {
    opacity: 1;
    transform: translateX(20px) translateY(-10px) rotate(5deg) scale(1);
}

/* Testimonials Grid Alignment */
.testimonials-slider {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    align-items: stretch;
}

.testimonial-card {
    height: 100%;
}



.btn-animated {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.btn-animated .arrow {
    transition: transform 0.3s ease;
}

.btn-animated:hover .arrow {
    transform: translateX(5px);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .carousel-button {
        width: 36px;
        height: 36px;
    }
    .carousel-slide .value-prop-card {
        padding: 25px;
    }
    .carousel-wrapper {
        margin-top: 20px;
    }
}

/* --- Expertise Tabs Section --- */
.expertise-tabs-container {
    display: flex;
    gap: 30px;
    margin-top: 40px;
    align-items: stretch; /* Ensure equal height */
}

.expertise-tabs-list {
    flex: 0 0 35%; /* Reduced width */
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* 2 Columns */
    gap: 10px; /* Tighter gap for bento feel */
    align-content: start; /* Keep tabs at top */
}

.expertise-tab {
    background: #f8f9fa; /* Light background for bento tile */
    border: 1px solid transparent; /* Cleaner look */
    padding: 10px 20px; /* Adjusted padding */
    text-align: left; /* Align text left */
    cursor: pointer;
    border-radius: 10px; /* Slightly more rounded */
    font-size: 0.8rem; /* Smaller font */
    font-weight: 600;
    color: #555;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: flex-start; /* Align content start */
    height: 100%; /* Fill grid cell */
    min-height: 50px; /* Compact height */
    box-shadow: 0 2px 5px rgba(0,0,0,0.03); /* Subtle initial shadow */
}

.expertise-tab:hover {
    background-color: #fff;
    color: var(--primary-color);
    border-color: rgba(191, 37, 58, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.expertise-tab.active {
    background-color: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(191, 37, 58, 0.25);
}

.expertise-content-area {
    flex: 1;
    background: #000; /* Fallback */
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-soft);
    border: 1px solid #eaeaea;
    min-height: 410px; /* Reduced height to match tabs */
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Push content to top/bottom */
    position: relative;
    overflow: hidden; /* For image zoom */
    color: #fff; /* Text white on image */
    padding: 0; /* Remove padding from container, handle in inner */
}

.expertise-bg-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: opacity 0.5s ease, transform 0.5s ease; /* Changed to opacity fade as per JS logic */
    z-index: 0;
}

.expertise-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.7) 50%, rgba(0,0,0,0.3) 100%);
    z-index: 1;
}

.expertise-content-display {
    position: relative;
    z-index: 2;
    padding: 40px;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.expertise-content-display h3 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 20px;
    line-height: 1.2;
}

.typing-container {
    min-height: 100px; /* Reserve space for text */
}

.typing-container p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
    max-width: 600px;
}

/* Pop-up Button Styles */
.expertise-cta {
    position: absolute;
    bottom: 10px !important; /* Force bottom more */
    left: 10px !important; /* Force left */
    right: auto !important; /* Override any potential right alignment */
    opacity: 0;
    transform: translateY(20px);
    transition: background-color 0.3s ease, transform 0.2s ease, opacity 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 4px 10px; /* Kept small but readable */
    font-size: 0.7rem; /* Small font */
    font-weight: 700;
    border-radius: 50px;
    box-shadow: 0 5px 15px rgba(191, 37, 58, 0.3);
    background-color: var(--primary-color);
    color: #fff;
    border: none;
    text-decoration: none;
    cursor: pointer;
    z-index: 10;
}

.expertise-cta:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px) !important; /* Ensure hover effect works over parent hover */
    color: #fff;
}

.expertise-content-area:hover .expertise-cta {
    opacity: 1;
    transform: translateY(0);
}

.expertise-cta .arrow {
    transition: transform 0.3s ease;
}

.expertise-cta:hover .arrow {
    transform: translateX(4px);
}

/* Responsive Expertise */
@media (max-width: 992px) {
    .expertise-tabs-container {
        flex-direction: column;
    }
    .expertise-tabs-list {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    }
    .expertise-content-area {
        min-height: 350px;
    }
    .expertise-content-display h3 {
        font-size: 2rem;
    }
    /* Show button always on touch devices or small screens if hover isn't reliable */
    .expertise-cta {
        opacity: 1; 
        transform: translateY(0);
        position: static;
        margin-top: 20px;
        align-self: flex-start;
    }
}

.expertise-content-area:hover .expertise-bg-image {
    transform: scale(1.05); /* Zoom effect */
}

.expertise-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0,0,0,0.6) 0%, rgba(0,0,0,0.3) 50%, rgba(0,0,0,0.8) 100%);
    z-index: 2;
    pointer-events: none;
}

.expertise-content-display {
    position: relative;
    z-index: 3;
    padding: 40px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.expertise-content-display h3 {
    font-size: 2.2rem; /* Smaller head text */
    margin-bottom: 20px;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    line-height: 1.1;
}

.typing-container {
    font-size: 1rem; /* Smaller description text */
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
    position: relative;
    display: inline-block;
    max-width: 800px;
}

/* Bottom Cards Styles */
.expertise-cards-container {
    display: flex;
    gap: 8px;
    margin-top: auto; /* Push to bottom */
    padding-top: 30px;
    flex-wrap: wrap;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.5s cubic-bezier(0.19, 1, 0.22, 1);
}

.expertise-content-area:hover .expertise-cards-container {
    opacity: 1;
    transform: translateY(0);
}

.expertise-card-small {
    background: rgba(0, 0, 0, 0.4); /* Darker glass for white text */
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 5px 12px; /* Smaller padding */
    border-radius: 15px; /* More rounded/pill shape */
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    cursor: default;
    color: #fff;
    font-size: 0.75rem; /* Smaller font */
    font-weight: 500;
    white-space: nowrap;
}

.expertise-card-small:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-3px) scale(1.05);
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* Removed blinking cursor CSS */

/* Hero Typing Cursor - Removed */
.typing-cursor-bar-hero {
    display: none; 
}

/* Responsive Styles for Expertise Tabs */
@media (max-width: 992px) {
    .expertise-tabs-container {
        flex-direction: column;
        gap: 30px;
    }

    .expertise-tabs-list {
        display: flex; /* Override grid layout for mobile scroll */
        flex: none;
        width: 100%;
        flex-direction: row;
        overflow-x: auto;
        padding-bottom: 10px;
        gap: 15px;
        scrollbar-width: none; /* Firefox */
    }

    .expertise-tabs-list::-webkit-scrollbar {
        display: none; /* Chrome/Safari */
    }

    .expertise-tab {
        flex: 0 0 auto;
        white-space: nowrap;
        padding: 12px 20px;
    }
    
    .expertise-tab:hover, .expertise-tab.active {
        transform: translateY(-3px);
        transform: translateX(0); /* Reset horizontal shift */
    }
}

@media (max-width: 768px) {
    .expertise-content-area {
        padding: 25px;
        min-height: 250px;
    }

    .expertise-content-display h3 {
        font-size: 1.5rem;
    }
}

/* --- Clean Clients/Partners Grid Styles --- */
.clients-section, .partners-section {
    padding: 80px 0;
    background-color: #fff;
}

.partners-section.bg-light {
    background-color: #f9f9f9; /* Keep alternate background */
}

.section-header-dynamic {
    text-align: center;
    margin-bottom: 50px;
}

.section-header-dynamic h2 {
    font-size: 1.1rem; /* Reduced from 1.5rem */
    color: #666;
    font-weight: 500;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.typing-header-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 3rem;
    font-weight: 700;
    color: #333;
    min-height: 1.2em; /* Prevent layout shift */
}

.typing-cursor-bar {
    display: inline-block;
    width: 4px;
    height: 1em;
    background-color: var(--primary-color);
    margin-left: 5px;
    animation: blinkBar 1s step-end infinite;
}

@keyframes blinkBar {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.clients-grid-clean {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 columns as per request */
    gap: 0; /* Connected borders style */
    border: 1px solid #eaeaea;
    border-radius: 20px;
    overflow: hidden;
    background: #fff;
}

.client-logo-box {
    border: 1px solid #eaeaea;
    margin: -1px 0 0 -1px; /* Overlap borders */
    padding: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 180px;
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
}

.client-logo-box:hover {
    z-index: 2; /* Bring to front */
    /* Removed box hover effects as requested */
}

.client-logo-box img {
    max-width: 80%;
    max-height: 60px;
    object-fit: contain;
    /* Removed grayscale and opacity for full color */
    transition: all 0.3s ease;
}

.client-logo-box:hover img {
    transform: scale(1.1); /* Little zoom on hover */
}

/* Reduce height for Strategic Partners and style as separate cards */
.partners-section .client-logo-box {
    height: 140px; /* Increased height as requested */
    padding: 20px;
    margin: 0; /* Reset negative margin */
    border-radius: 12px;
    border: 1px solid #eaeaea;
    background: #fff;
}

.partners-section .client-logo-box img {
    max-height: 50px; /* Reduced image size */
    max-width: 60%;   /* Reduced image width */
}

/* Force 4 columns with spacing for Strategic Partners */
.partners-section .clients-grid-clean {
    grid-template-columns: repeat(4, 1fr);
    gap: 20px; /* Add spacing */
    border: none; /* Remove container border */
    background: transparent;
    overflow: visible;
    border-radius: 0;
}

/* Highlight specific partners */
.partners-section .client-logo-box.partner-highlight {
    background-color: #fff;
    border-color: #eaeaea;
}

.partners-section .client-logo-box.partner-highlight img {
    filter: none; /* Remove any filters (grayscale, brightness, invert) */
    opacity: 1; /* Ensure full opacity */
    box-shadow: none; /* Explicitly remove box-shadow if applied directly to img */
}

/* Responsive adjustments for Clients/Partners */
@media (max-width: 992px) {
    .typing-header-wrapper {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    .clients-grid-clean {
        grid-template-columns: repeat(2, 1fr);
    }
    /* Ensure Partners grid also drops to 2 columns on mobile */
    .partners-section .clients-grid-clean {
        grid-template-columns: repeat(2, 1fr);
    }

    .typing-header-wrapper {
        font-size: 2rem;
    }
    .client-logo-box {
        height: 150px;
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .clients-grid-clean {
        grid-template-columns: repeat(2, 1fr);
    }
    .typing-header-wrapper {
        font-size: 1.5rem;
    }
}


/* Button Styles */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.6s cubic-bezier(0.25, 1, 0.5, 1) !important;
    cursor: pointer;
    border: 2px solid transparent;
}

.btn-primary {
    background-color: var(--primary-color);
    color: #fff;
}

.btn-primary:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(191, 37, 58, 0.3);
}

.btn-outline {
    background-color: transparent;
    border-color: #ddd;
    color: var(--text-color);
}

.btn-outline:hover {
    border-color: var(--text-color);
    background-color: rgba(0,0,0,0.05);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: #fff;
}

.btn-secondary:hover {
    background-color: var(--primary-color);
    transform: translateY(-2px);
}

/* Hero Section Styles */
.hero-section {
    position: relative;
    padding: 100px 0 80px;
    overflow: hidden;
    /* Gradient starts white, goes to pinkish, then fades back to white to mix with next section */
    background: linear-gradient(180deg, #ffffff 0%, #fff0f3 60%, #ffffff 100%);
}

#hero-dots-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
    /* Fade top, bottom, and center */
    mask-image: 
        linear-gradient(to bottom, transparent 0%, black 20%, black 80%, transparent 100%),
        radial-gradient(circle at center, transparent 20%, black 60%);
    -webkit-mask-image: 
        linear-gradient(to bottom, transparent 0%, black 20%, black 80%, transparent 100%),
        radial-gradient(circle at center, transparent 20%, black 60%);
    mask-composite: intersect;
    -webkit-mask-composite: source-in; /* source-in behaves like intersect in webkit */
}

/* Fallback/Alternative composite logic if browser support varies:
   Actually, combining a linear gradient (vertical fade) and radial gradient (center fade) 
   where we want BOTH fades to apply (AND logic) requires 'intersect' or 'source-in'.
   However, radial-gradient(transparent center) means "show nothing in center".
   linear-gradient(transparent ends) means "show nothing at ends".
   So we want to show only where BOTH are black.
   
   Let's simplify. A single radial gradient can handle center fade.
   A linear gradient handles top/bottom.
   
   Wait, "fade in the center also".
   User said: "fade both at top and bottom to look mixed with the other sections & fade in the center also"
   
   If I make the center transparent, the text is readable.
   If I make top/bottom transparent, it blends.
   
   So yes, transparent at top, bottom, and center.
   
   Mask 1: Linear Gradient (Vertical): Transparent -> Black -> Transparent
   Mask 2: Radial Gradient (Center): Transparent -> Black
   
   Composite: We want the intersection of the visible parts.
   Visible parts are (Middle Vertical) AND (Outer Radial).
   
   -webkit-mask-composite: source-in; works for intersection.
*/

.hero-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 16px;
    background-color: rgba(0,0,0,0.05);
    border-radius: 50px;
    font-size: 0.9rem;
    border: 1px solid rgba(0,0,0,0.1);
}

.badge-text {
    font-weight: 500;
    color: #666;
}

.badge-link {
    font-weight: 600;
    color: var(--primary-color);
    display: flex;
    align-items: center;
    gap: 5px;
}

.hero-title {
    font-size: 3.5rem;
    line-height: 1.2;
    font-weight: 800;
    max-width: 900px;
    margin: 0 auto;
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.25rem;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

.hero-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 5px;
}

.hero-actions .btn {
    padding: 10px 24px;
    font-size: 0.95rem;
}

.hero-image-container {
    margin-top: 60px;
    position: relative;
    width: 100%;
    max-width: 1000px;
}

.mockup-frame {
    background: #fff;
    padding: 10px;
    border-radius: 10px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.1);
    position: relative;
    z-index: 2;
    border: 1px solid rgba(0,0,0,0.05);
}

.hero-img {
    width: 100%;
    height: auto;
    border-radius: 5px;
    display: block;
}

.glow-effect {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120%;
    height: 120%;
    background: radial-gradient(circle, rgba(191, 37, 58, 0.15) 0%, rgba(239, 65, 110, 0.05) 40%, transparent 70%);
    z-index: 1;
    pointer-events: none;
}

.hero--premium {
    position: relative;
    background: linear-gradient(to bottom, #fff, rgba(180, 157, 224, 0.25) 40%, rgba(164, 110, 219, 0.20) 88%);
}

.hero--premium::before,
.hero--premium::after {
    content: "";
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 50%;
    pointer-events: none;
    filter: blur(80px);
}

.hero--premium::before {
    top: calc(100% - 150px);
    width: min(1000px, 90vw);
    height: 550px;
    background: radial-gradient(closest-side, rgba(0,0,0,0.85) 82%, rgba(149, 96, 235, 0.75));
    opacity: 0.35;
}

.hero--premium::after {
    top: 64px;
    width: min(32vw, 420px);
    height: min(32vw, 420px);
    background: radial-gradient(circle, rgba(239, 65, 110, 0.35), transparent 60%);
    left: 6vw;
    opacity: 0.5;
}

.premium-cta {
    position: relative;
    background: linear-gradient(135deg, #fafafa 0%, #ffffff 60%);
}
.premium-cta::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(600px 200px at top center, rgba(191, 37, 58, 0.15), transparent 60%);
    pointer-events: none;
}

.premium-intro .value-prop-card {
    border: 1px solid #eaeaea;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.06);
}

.premium-intro .value-prop-card:hover {
    box-shadow: 0 16px 36px rgba(0,0,0,0.08);
}

.premium-services-list .services-list-grid li {
    border-radius: 16px;
    background: linear-gradient(180deg, #ffffff, #fbfbfb);
    border: 1px solid #ececec;
    box-shadow: 0 6px 18px rgba(0,0,0,0.06);
}

.premium-services-list .services-list-grid li:hover {
    border-color: rgba(191, 37, 58, 0.55);
}

.premium-about {
    position: relative;
}
.premium-about::before {
    content: "";
    position: absolute;
    right: 7vw;
    bottom: -50px;
    width: min(30vw, 360px);
    height: min(30vw, 360px);
    background: radial-gradient(circle, rgba(239, 65, 110, 0.25), transparent 60%);
    filter: blur(100px);
}

/* About Section Layout */
.row {
    display: flex;
    gap: 40px;
    align-items: center;
    flex-wrap: wrap;
}

.col-md-6 {
    flex: 1 1 480px;
}

.img-fluid {
    width: 100%;
    height: auto;
}

.rounded { border-radius: 12px; }
.shadow { box-shadow: 0 12px 32px rgba(0,0,0,0.08); }

.about-brief-section .col-md-6:first-child {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.about-brief-section img {
    max-height: 320px;
    object-fit: cover;
}

/* Animations */
.animate-appear {
    animation: appear 0.8s ease-out forwards;
    opacity: 0;
    transform: translateY(20px);
}

.animate-appear-zoom {
    animation: appearZoom 1s ease-out forwards;
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8);
}

.delay-100 { animation-delay: 0.1s; }
.delay-300 { animation-delay: 0.3s; }
.delay-700 { animation-delay: 0.7s; }
.delay-1000 { animation-delay: 1s; }

@keyframes appear {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes appearZoom {
    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

/* Value Props Grid */
.value-props-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.value-prop-card {
    padding: 30px;
    background: #fff;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    text-align: center;
    transition: transform 0.3s ease;
}

.value-prop-card:hover {
    transform: translateY(-5px);
}

.value-prop-card .icon {
    font-size: 3rem;
    margin-bottom: 20px;
}

.value-prop-card h3 {
    margin-bottom: 15px;
    color: var(--text-color);
}

/* Services Grid */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-card { overflow: hidden; }

.service-card:hover {
    transform: translateY(-5px);
}

.service-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.service-content {
    padding: 25px;
}

.service-content h3 {
    margin-bottom: 10px;
    color: var(--text-color);
}

.service-content p {
    color: #666;
    margin-bottom: 20px;
}

.learn-more {
    color: var(--primary-color);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
}

.learn-more:hover {
    color: var(--secondary-color);
}


/* Marquee / Infinite Scroll Section */
.marquee-section {
    overflow: hidden;
    padding: 80px 0;
    background-color: #fafafa;
}

.container-fluid {
    width: 100%;
    padding: 0;
    overflow: hidden;
}

.marquee-wrapper {
    position: relative;
    width: 100%;
    overflow: hidden;
    padding: 20px 0;
    /* Fade mask on edges */
    mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}


/* Popup Styles */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    backdrop-filter: blur(4px);
}

.popup-overlay.active {
    opacity: 1;
    visibility: visible;
}

.popup-content {
    background: #fff;
    width: 95%; /* Wider */
    max-width: 1000px; /* Wider max width */
    max-height: 80vh; /* Reduced height, won't touch top/bottom edges too much */
    margin: 5vh auto; /* Center vertically with margin */
    overflow-y: auto;
    border-radius: 12px;
    padding: 2rem;
    position: relative;
    transform: scale(0.9);
    transition: transform 0.3s ease;
    box-shadow: 0 20px 50px rgba(0,0,0,0.2);
}

.popup-overlay.active .popup-content {
    transform: scale(1);
}

.popup-close-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
}

.popup-body-loading {
    text-align: center;
    padding: 2rem;
}

.popup-title {
    margin-top: 0;
    color: #333;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 1rem;
}

.popup-text {
    font-size: 1rem;
    color: #444;
    line-height: 1.7;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.popup-error {
    text-align: center;
    padding: 2rem;
    color: #d9534f;
}

/* Career Popup Specifics */
.career-sections {
    margin-top: 2rem;
    text-align: left;
    border-top: 1px solid #eee;
    padding-top: 1.5rem;
}

.career-section {
    margin-bottom: 1.5rem;
}

.career-section-title {
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
    color: #BF253A;
    font-weight: 700;
}

.career-meta {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    color: #666;
    font-size: 0.95rem;
}

.career-apply-area {
    margin-top: 2rem;
}

.career-apply-area-bottom {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid #eee;
    text-align: center;
}




/* --- Hover Preview Hero Styles --- */
.services-hero-preview {
    position: relative;
    min-height: 85vh;
    background: linear-gradient(180deg, #ffffff 0%, #fff0f3 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 80px 20px;
}

.services-hero-preview .ambient-glow {
    position: absolute;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(191, 37, 58, 0.08) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    animation: pulse 8s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 0.8; transform: translate(-50%, -50%) scale(1.1); }
}

.services-hero-preview .content-container {
    position: relative;
    z-index: 2;
    max-width: 1000px;
    width: 100%;
    text-align: center;
}

.text-block {
    font-size: clamp(2rem, 5vw, 3.5rem);
    line-height: 1.4;
    color: #888; /* Light gray for non-active text */
    font-weight: 500;
    letter-spacing: -0.02em;
}

.text-block p {
    margin-bottom: 1em;
    opacity: 0;
    animation: fadeUp 0.8s ease forwards;
}

.text-block p:nth-child(1) { animation-delay: 0.2s; }
.text-block p:nth-child(2) { animation-delay: 0.4s; }

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

.hover-link-preview {
    color: var(--text-color); /* Dark text for important words */
    font-weight: 700;
    cursor: pointer;
    position: relative;
    display: inline-block;
    transition: color 0.3s ease;
}

.hover-link-preview::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transition: width 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.hover-link-preview:hover {
    color: var(--primary-color);
}

.hover-link-preview:hover::after {
    width: 100%;
}

/* Preview Card */
.preview-card {
    position: fixed; /* Fixed to viewport to follow mouse easily */
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 9999;
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.25s ease, transform 0.1s linear; /* Fast transform for tracking */
    will-change: transform, opacity;
}

.preview-card.visible {
    opacity: 1;
}

.preview-card-inner {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 16px;
    padding: 10px;
    box-shadow: 
      0 25px 50px -12px rgba(0, 0, 0, 0.25),
      0 0 0 1px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    backdrop-filter: blur(10px);
    width: 300px;
}

.preview-card img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    border-radius: 10px;
    display: block;
    margin-bottom: 10px;
}

.preview-card-title {
    padding: 0 8px 4px;
    font-size: 1rem;
    color: var(--text-color);
    font-weight: 700;
}

.preview-card-subtitle {
    padding: 0 8px 8px;
    font-size: 0.85rem;
    color: #666;
    line-height: 1.4;
}

.marquee-track {
    display: flex;
    width: max-content;
    gap: 30px;
    /* Move from 0 to -50% because we duplicated the items once. 
       The track contains [Set1][Set2]. We slide until Set2 takes Set1's place. */
    animation: marquee-scroll 80s linear infinite;
}

/* Pause on hover */
.marquee-wrapper:hover .marquee-track {
    animation-play-state: paused;
}

@keyframes marquee-scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

/* Premium Service Card (Bento/Section05 Style) */
.service-premium-card {
    flex: 0 0 300px;
    background: #fff;
    border: 1px solid #e4e4e7; /* zinc-200 equivalent */
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.6s ease; /* Smoother transition */
    display: flex;
    flex-direction: column;
    justify-content: flex-start; /* Align to top for consistency */
    height: 220px;
    /* Make it unselectable to prevent text selection while dragging if we added drag */
    user-select: none;
    backface-visibility: hidden; /* Fix for text glitching */
    -webkit-font-smoothing: subpixel-antialiased; /* Better text rendering */
    transform: translateZ(0); /* Hardware acceleration */
    will-change: transform; /* Hint to browser to optimize for transform */
}

/* Pop effect on hover */
.service-premium-card:hover {
    transform: scale(1.05) translateZ(0); /* Maintain hardware acceleration */
    box-shadow: 0 12px 24px rgba(0,0,0,0.1);
    border-color: #d4d4d8;
    z-index: 10;
}

/* Smooth Hover Effect (Too Smooth) */
.hover-smooth {
    transition: transform 0.7s cubic-bezier(0.19, 1, 0.22, 1), box-shadow 0.7s cubic-bezier(0.19, 1, 0.22, 1);
}
.hover-smooth:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.card-header {
    display: flex;
    justify-content: flex-end; /* Align tag to right since icon is gone */
    align-items: center;
    margin-bottom: 16px;
    min-height: 40px; /* Maintain height consistency */
}

/* Icon removed, class kept for legacy or future use if needed, but effectively unused now */
.service-icon {
    display: none;
}

.service-tag {
    font-size: 0.75rem;
    font-weight: 600;
    color: #71717a; /* zinc-500 */
    background: #fff;
    border: 1px solid #e4e4e7;
    padding: 4px 8px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.service-premium-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #18181b; /* zinc-900 */
    margin-bottom: 8px;
}

.service-premium-card p {
    font-size: 0.95rem;
    color: #71717a; /* zinc-500 */
    line-height: 1.5;
}

/* Update Portfolio Grid to avoid conflict if needed, though styles are specific enough */


/* Portfolio Grid */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

/* Blog Grid - Ensure alignment */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.blog-card {
    height: 100%;
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.blog-content h3 {
    margin-bottom: 15px;
    font-size: 1.4rem;
}

.blog-content p {
    margin-bottom: 20px;
    color: #666;
}

.read-more {
    color: var(--primary-color);
    font-weight: 600;
    margin-top: auto;
    display: inline-block;
}

/* CTA Section Alignment */
.cta-section {
    text-align: center;
    padding: 100px 0;
}

/* =========================================
   Mobile Responsiveness & Media Queries
   ========================================= */

/* Large Tablets and Small Desktops (Navigation Breakpoint) */
@media (max-width: 1024px) {
    .hero-title {
        font-size: 3rem;
    }
    
    .section-header h2 {
        font-size: 2.25rem;
    }

    .carousel-wrapper {
        max-width: 90%;
    }

    /* Mobile Navigation Trigger */
    .header-container {
        position: relative;
        justify-content: space-between;
        padding: 10px 20px; /* Reduced padding */
    }

    .logo img {
        height: 35px; /* Reduced logo size */
    }

    .nav-menu {
        position: absolute;
        top: 100%; /* Position directly below header */
        left: 0;
        width: 100%;
        background: #fff;
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 10px 20px rgba(0,0,0,0.1);
        transform-origin: top center;
        transform: scaleY(0); /* Start collapsed vertically */
        opacity: 0;
        transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.3s ease;
        z-index: 999;
        pointer-events: none;
    }

    .nav-menu.active {
        transform: scaleY(1); /* Expand downwards */
        opacity: 1;
        pointer-events: all;
    }

    .mobile-menu-toggle {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 24px;
        height: 18px;
        cursor: pointer;
        z-index: 1001;
        order: 2; 
    }
    
    .mobile-menu-toggle span {
        display: block;
        width: 100%;
        height: 2px;
        background-color: #333;
        border-radius: 2px;
        transition: all 0.3s ease;
        transform-origin: center;
    }
    
    /* Hamburger Animation */
    .mobile-menu-toggle.active span:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    
    .mobile-menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .mobile-menu-toggle.active span:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
    
    .logo {
        order: 1;
    }

    /* Header Adjustments */
    /* Ensure nav doesn't interfere with flex spacing */
    header nav {
        display: contents;
    }
}

/* Tablets and Large Phones */
@media (max-width: 768px) {
    /* Typography adjustments */
    html {
        font-size: 15px; /* Slightly smaller base size */
    }

    .hero-title {
        font-size: 2.25rem;
    }

    .hero-description {
        font-size: 1.1rem;
    }

    .section-header h2 {
        font-size: 2rem;
    }

    /* Layout Adjustments */
    .section {
        padding: 50px 0;
    }
    
    .hero-section {
        padding: 60px 0 40px;
    }

    /* Carousel */
    .carousel-button {
        width: 36px;
        height: 36px;
        background: rgba(255,255,255,0.9);
    }

    .carousel-slide .value-prop-card {
        padding: 25px 20px;
    }
    
    .card-image-wrapper {
        height: 180px;
    }

    /* Marquee Section */
    /* Sizing handled in specific override below */

    


    /* About Section Split Layout */
    .row {
        flex-direction: column;
        gap: 30px;
    }
    
    .col-md-6 {
        flex: 1 1 100%;
        width: 100%;
    }
    
    .about-image-container {
        margin-top: 20px;
    }

    /* Stats Grid */
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .stat-item h3 {
        font-size: 3rem;
    }

    /* Footer */
    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-links, .contact-info {
        align-items: center;
    }
    
    .contact-info li {
        justify-content: center;
    }
    
    /* Reduce View All Services button size 3x on mobile */
    .services-overview-section .btn {
        padding: 6px 16px !important;
        font-size: 0.8rem !important;
        border-radius: 25px;
    }
    
    /* Ensure gaps/padding for full width sections */
    .container-fluid {
        padding: 0 20px;
    }
}

/* Small Phones */
@media (max-width: 480px) {
    .hero-title {
        font-size: 1.85rem;
    }

    /* Header Adjustments for Mobile */
    .header-container {
        padding: 5px 12px; /* Further reduced header size */
        align-items: center; /* Ensure logo and hamburger are straight in same row */
    }

    .logo img {
        height: 28px; /* Further reduced logo size */
    }
    
    /* Hero Buttons - Reduced Size on Mobile (2x smaller feel) */
    .hero-actions .btn {
        padding: 5px 12px;
        font-size: 0.7rem;
        border-radius: 20px;
    }
    
    .service-premium-card {
        flex: 0 0 240px;
        height: auto;
        min-height: 180px;
    }
    
    .carousel-button {
        display: none;
    }

    /* Compact gaps */
    .services-grid,
    .blog-grid,
    .testimonials-slider,
    .services-list-grid,
    .portfolio-grid { 
        gap: 20px; 
    }
}

/* Portfolio Section Redesign */
.portfolio-item {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    height: 400px; /* Taller for better display */
    box-shadow: var(--shadow-soft);
    border: 1px solid #eaeaea;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
    display: flex;
    flex-direction: column;
}

.portfolio-image {
    height: 60%;
    overflow: hidden;
}

.portfolio-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.portfolio-item:hover .portfolio-image img {
    transform: scale(1.1);
}

.portfolio-content {
    padding: 25px;
    background: #fff;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    z-index: 2;
}

.portfolio-content h3 {
    font-size: 1.4rem;
    margin-bottom: 8px;
    color: var(--text-color);
}

.portfolio-content p {
    color: #666;
    font-size: 0.95rem;
    margin-bottom: 15px;
}

.project-tag {
    display: inline-block;
    padding: 6px 14px;
    background: rgba(191, 37, 58, 0.08);
    color: var(--primary-color);
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    width: fit-content;
}

/* Testimonials Redesign */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.testimonial-card {
    padding: 40px;
    border-radius: 20px;
    background: #fff;
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.quote-icon {
    font-size: 4rem;
    color: var(--primary-color);
    font-family: serif;
    line-height: 1;
    margin-bottom: 20px;
}

/* Typing Effect Styles */
.highlight-text {
    color: var(--primary-color);
    position: relative;
    display: inline-block;
}

/* Removed .highlight-text::after cursor */

.stats-section .stat-number.typing::after {
    content: '';
    display: none;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.testimonial-text {
    font-size: 1.1rem;
    color: #444;
    line-height: 1.6;
    font-style: italic;
    margin-bottom: 30px;
    flex: 1;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 15px;
}

.author-avatar {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-size: 1.1rem;
}

.author-info strong {
    display: block;
    font-size: 1rem;
    color: var(--text-color);
}

.author-info span {
    font-size: 0.85rem;
    color: #888;
}

/* Stats Section Redesign */
.stats-section {
    background: linear-gradient(rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.8)), url('../assets/images/page_images/417399617_3105e27a-536a-41c9-81b2-c55916a8d1a8.jpg');
    background-attachment: fixed;
    background-size: cover;
    background-position: center;
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}

.stats-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, rgba(191, 37, 58, 0.1), transparent 70%);
    pointer-events: none;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    text-align: center;
}

.stat-item {
    padding: 20px;
    position: relative;
}

.stat-number {
    font-size: 4rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 10px;
    line-height: 1;
}

.stats-section .stat-item .stat-number {
    background: none;
    /* -webkit-background-clip: border-box; */
    /* background-clip: border-box; */
    -webkit-text-fill-color: initial !important;
    color: #ffffff !important;
}

.stat-label {
    font-size: 1.1rem;
    color: #ffffff !important;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* CTA Section Redesign */
.cta-section {
    padding: 120px 0;
    background: linear-gradient(135deg, #fafafa 0%, #ffffff 100%);
    position: relative;
}

.cta-title {
    font-size: 3rem;
    margin-bottom: 20px;
    color: var(--text-color);
}

.cta-subtitle {
    font-size: 1.25rem;
    color: #666;
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-btn {
    padding: 16px 40px;
    font-size: 1.1rem;
    box-shadow: 0 10px 30px rgba(191, 37, 58, 0.25);
}

/* Responsive Adjustments for New Sections */
@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .cta-title {
        font-size: 2rem;
    }
    
    .portfolio-item {
        height: auto;
    }
    
    .portfolio-image {
        height: 200px;
    }
}

/* =========================================
   About Section Image Handling
   ========================================= */
/* Hide on Mobile */
@media (max-width: 768px) {
    .about-brief-section .about-image-container {
        display: none !important;
    }
}

/* Remove Background Blob */
.image-backdrop {
    display: none !important;
}

/* Pop-out Animation on Web Hover */
.pop-out-image {
    position: absolute;
    top: 0;
}

/* =========================================
   Footer Styles
   ========================================= */
footer {
    background-color: var(--footer-bg);
    color: var(--footer-text);
    padding: 60px 0 20px;
    font-size: 0.9rem;
}

.footer-container {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-column h3 {
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: 20px;
    font-weight: 600;
}

.footer-column p {
    color: #aaa;
    line-height: 1.6;
    margin-bottom: 20px;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: #aaa;
    display: inline-block;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.footer-links a:hover {
    color: var(--primary-color);
    transform: translateX(5px);
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    color: #fff;
    transition: all 0.3s ease;
}

.social-icon:hover {
    background: var(--primary-color);
    transform: translateY(-3px);
}

.social-icon svg {
    width: 18px;
    height: 18px;
}

.newsletter-form {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.newsletter-form input {
    flex: 1;
    padding: 10px;
    border-radius: 5px;
    border: none;
    font-family: inherit;
}

.newsletter-form button {
    padding: 10px 20px;
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.6s cubic-bezier(0.23, 1, 0.32, 1); /* Smooth hover */
}

.newsletter-form button:hover {
    background: var(--secondary-color);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 10px 20px rgba(191, 37, 58, 0.3);
}

.footer-bottom {
    max-width: 1200px;
    margin: 40px auto 0;
    padding: 20px 20px 0;
    border-top: 1px solid rgba(255,255,255,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #777;
}

.legal-links a {
    color: #777;
    margin: 0 10px;
}

.legal-links a:hover {
    color: #fff;
}

@media (max-width: 1024px) {
    .footer-container {
        grid-template-columns: 1fr 1fr;
        gap: 30px;
    }
}

@media (max-width: 768px) {
    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-links a:hover {
        transform: none;
    }
    
    .social-links {
        justify-content: flex-start !important;
    }
    
    .newsletter-form {
        flex-direction: column;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
}

/* --- Mobile Hero Adjustments (User Requested) --- */
@media (max-width: 768px) {
    /* Reduce badge size */
    .hero-badge {
        padding: 4px 10px;
        font-size: 0.6rem;
        gap: 5px;
    }
    
    .badge-text {
        font-size: 0.6rem;
    }

    .badge-link {
        font-size: 0.6rem;
    }
    
    /* Adjust gaps */
    .hero-content {
        gap: 5px; /* Significantly reduced gap (2x tighter) */
    }

    .hero-title {
        margin-bottom: 0;
    }

    .hero-description {
        margin-bottom: 0;
        font-size: 0.9rem;
    }

    .hero-actions {
        margin-top: 5px; /* Minimal space */
        gap: 10px;
    }

    /* Reduce stars container size */
    .sparkles-display-container {
        height: 1.25rem;
        width: 100%;
        max-width: none;
    }
}

/* =========================================
   Contact Hero Section (Wave Design)
   ========================================= */
.contact-hero {
    position: relative;
    width: 100%;
    min-height: 60vh;
    background-color: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 6rem 2rem 2rem;
    overflow: visible;
}

.wave-hero-container {
    width: 100%;
    max-width: 1000px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.contact-hero-content {
    position: relative;
    z-index: 20;
    text-align: center;
    margin-bottom: 3rem;
    width: 100%;
}

/* Gooey Text Styles */
.gooey-text-container {
    position: relative;
    height: 150px; /* Space for large text */
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.gooey-filter-svg {
    position: absolute;
    width: 0;
    height: 0;
    pointer-events: none;
}

.gooey-text-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.gooey-text {
    position: absolute;
    display: block;
    font-size: clamp(3.5rem, 8vw, 6rem);
    font-weight: 800;
    color: #111;
    white-space: nowrap;
    opacity: 0;
    text-align: center;
    line-height: 1.1;
    letter-spacing: -0.02em;
    will-change: transform, opacity, filter;
}

/* Wave Path Styles */
.wave-path-wrapper {
    position: relative;
    width: 100%;
    height: 1px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
}

.wave-trigger {
    position: absolute;
    top: -20px;
    z-index: 10;
    height: 40px;
    width: 100%;
    /* Expand interaction area on hover */
}

.wave-trigger:hover {
    top: -150px;
    height: 300px;
}

.wave-svg {
    position: absolute;
    top: -150px;
    left: 0;
    width: 100%;
    height: 300px;
    overflow: visible;
    pointer-events: none;
}

.wave-path-line {
    stroke: var(--primary-color);
    stroke-width: 2px;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* Hero Sub Content */
.hero-sub-content {
    margin-top: 3rem;
    width: 100%;
    max-width: 1000px;
    padding: 0 1rem;
}

.sub-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    text-align: right;
    margin-bottom: 0.5rem;
    display: inline-block;
    width: 100%;
    padding-right: 2rem;
}

.sub-text {
    font-size: clamp(1.5rem, 3.5vw, 2.5rem);
    font-weight: 400;
    color: #111;
    line-height: 1.3;
}

/* Layout Grid for Sub Content */
@media (min-width: 768px) {
    .hero-sub-content {
        display: grid;
        grid-template-columns: 1fr 3fr;
        gap: 2rem;
        align-items: start;
    }
}

@media (max-width: 767px) {
    .sub-label {
        text-align: left;
        padding-right: 0;
    }
}

/* --- Services Page Styles --- */

/* Hero Services */
.hero-services {
    position: relative;
    background: linear-gradient(180deg, #ffffff 0%, #ffffff 40%, #f4f4f4 100%);
    padding: 160px 0 120px;
    color: #fff;
    overflow: hidden;
}

#services-hero-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    /* Fade top and bottom for smooth blending */
    mask-image: linear-gradient(to bottom, transparent 0%, black 15%, black 85%, transparent 100%);
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 15%, black 85%, transparent 100%);
}

.hero-services::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* White gradient overlay to fade out background for text readability */
    /* Adjusted to be more transparent at bottom to reveal the fade-to-gray effect */
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 0.8) 50%, rgba(255, 255, 255, 0.0) 100%);
    z-index: 1;
    pointer-events: none;
    backdrop-filter: blur(2px);
}

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

.hero-title {
    color: #222; /* Dark text for readability on light background */
    text-shadow: none;
}

.hero-description {
    font-size: 1.25rem;
    color: #444; /* Darker grey */
    max-width: 600px;
    margin: 0 auto;
}

/* Specific overrides for Services Hero to ensure contrast */
.hero-services .hero-title {
    color: #1a1a1a;
    text-shadow: none;
    font-weight: 900;
}

.hero-services .hero-description {
    color: #333;
    font-weight: 500;
}

.hero-services .gradient-text {
    background: linear-gradient(135deg, #BF253A 0%, #EF416E 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: none; /* Remove drop shadow that might look muddy */
}

/* Services Intro Section (Stats & Quote) */
.services-intro-grid {
    display: grid;
    gap: 40px;
    margin-top: 20px;
}

@media (min-width: 768px) {
    .services-intro-grid {
        grid-template-columns: 1fr 1fr;
        gap: 60px;
        align-items: start;
    }
}

.intro-text-col p {
    font-size: 1.1rem;
    color: #555;
    margin-bottom: 40px;
}

.intro-stats-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* Force black labels only within Services intro stats */
.services-intro-grid .stat-item .stat-label {
    color: #000000 !important;
}

.stat-item .stat-number {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 5px;
    background: linear-gradient(135deg, #BF253A 0%, #EF416E 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-item .stat-label {
    font-weight: 800 !important;
    color: #ffffff !important; /* Force White */
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-top: 10px;
    opacity: 1 !important;
    visibility: visible !important;
}

.intro-quote-col blockquote {
    border-left: 4px solid var(--primary-color);
    padding-left: 30px;
    background: #fff;
    padding: 40px;
    border-radius: 0 16px 16px 0;
    box-shadow: var(--shadow-soft);
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.4s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.intro-quote-col blockquote:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-hover);
}

.intro-quote-col p {
    font-size: 1.25rem;
    font-style: italic;
    color: #333;
    margin-bottom: 25px;
    line-height: 1.6;
}

.quote-author cite {
    display: block;
    font-weight: 700;
    font-style: normal;
    color: var(--text-color);
    font-size: 1.1rem;
}

.quote-author .company-name {
    font-size: 0.95rem;
    color: #666;
}

.package-desc { color: #777; margin-bottom: 25px; font-style: italic; }
.package-features {
    margin-bottom: 30px;
    text-align: left;
}

.package-features li {
    padding: 10px 0;
    border-bottom: 1px solid #f5f5f5;
    color: #555;
    display: flex;
    align-items: center;
}

.package-features li::before {
    content: "✓";
    color: var(--primary-color);
    margin-right: 10px;
    font-weight: bold;
}

.full-width { width: 100%; display: block; text-align: center; }

/* Hidden utility */
.hidden { display: none !important; }

@media (max-width: 768px) {
    .package-card.featured-package { transform: none; }
    .modal-container { width: 95%; padding: 20px; }
}


/* Text Animations */
.slide-in-down {
    animation: slideInDown 0.8s ease-out forwards;
    opacity: 0;
}

.fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
    opacity: 0;
}

/* Premium Newsletter Redesign - Refined */
.newsletter-section.premium-newsletter {
    padding: 100px 0;
    background-color: #fff;
}

.newsletter-container {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: 24px;
    padding: 60px 40px;
    position: relative;
    overflow: hidden;
    text-align: center;
    box-shadow: 0 20px 40px rgba(191, 37, 58, 0.2);
    color: #fff;
    max-width: 1000px;
    margin: 0 auto;
}

/* Background overlay effect */
.newsletter-overlay {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(268.24deg, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0.05) 80%, transparent 100%);
    pointer-events: none;
    z-index: 1;
}

.newsletter-content-wrapper {
    position: relative;
    z-index: 10;
    max-width: 600px;
    margin: 0 auto;
}

.newsletter-text h2 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 15px;
}

.newsletter-text p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 40px;
}

/* Form Container - White box */
.newsletter-form-inline {
    display: flex;
    align-items: center;
    background: #fff;
    padding: 6px;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    max-width: 500px;
    margin: 0 auto 20px;
}

.newsletter-input {
    flex: 1;
    border: none;
    outline: none;
    padding: 12px 20px;
    font-size: 1rem;
    color: #333;
    background: transparent;
    width: 100%;
}

.newsletter-input::placeholder {
    color: #9ca3af;
}

.newsletter-btn {
    background: var(--primary-color);
    color: #fff;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.newsletter-btn:hover {
    background: var(--secondary-color);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(191, 37, 58, 0.3);
}

.newsletter-btn:active {
    transform: translateY(0);
}

.newsletter-privacy {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 15px;
}

.privacy-link {
    color: #fff;
    text-decoration: underline;
    font-weight: 500;
    transition: opacity 0.2s;
}

.privacy-link:hover {
    opacity: 0.8;
}

@media (max-width: 768px) {
    .newsletter-form-inline {
        flex-direction: column;
        background: transparent;
        box-shadow: none;
        padding: 0;
    }
    
    .newsletter-input {
        background: #fff;
        border-radius: 12px;
        margin-bottom: 10px;
        width: 100%;
        box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    }
    
    .newsletter-btn {
        width: 100%;
        padding: 14px;
        border-radius: 12px;
    }
    
    .newsletter-container {
        padding: 40px 20px;
    }
    
    .newsletter-text h2 {
        font-size: 2rem;
    }
}

.delay-200 { animation-delay: 0.2s; }
.delay-400 { animation-delay: 0.4s; }

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

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

/* --- Testimonials Marquee Styles --- */
.testimonials-section {
    overflow: hidden;
    padding: 80px 0;
    background: none;
}

.testimonials-scroller {
    width: 100%;
    overflow-x: auto; /* Allows manual scroll */
    overflow-y: hidden;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none;  /* IE 10+ */
    padding: 20px 0;
    cursor: grab;
}

.testimonials-scroller::-webkit-scrollbar {
    display: none; /* Chrome/Safari/Opera */
}

.testimonials-scroller:active {
    cursor: grabbing;
}

.testimonials-track {
    display: inline-flex;
    gap: 20px;
    padding-left: 20px; /* Initial offset */
}

.testimonial-card-small {
    flex: 0 0 300px; /* Fixed width */
    background: #fff;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    border: 1px solid #eee;
    white-space: normal; /* Allow text to wrap inside card */
    transition: transform 0.3s ease;
    user-select: none; /* Prevent text selection while dragging */
}

.testimonial-card-small:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

.testimonial-quote {
    font-size: 0.95rem;
    color: #555;
    margin-bottom: 15px;
    font-style: italic;
    line-height: 1.5;
}

.testimonial-author strong {
    display: block;
    font-size: 1rem;
    color: var(--text-color);
}

.testimonial-author span {
    font-size: 0.85rem;
    color: #888;
}

/* --- Vertical Scrolling Testimonials (Hero) --- */
.testimonials-hero-section {
    position: relative;
    padding: 100px 0;
    background: #fff;
    overflow: hidden;
}

.testimonials-hero-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.testimonials-hero-header {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 60px;
}

.testimonials-hero-header h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 20px;
    color: var(--text-color);
}

.testimonials-hero-header p {
    font-size: 1.1rem;
    color: #666;
}

/* Marquee Grid Container */
.testimonials-marquee-grid {
    display: flex;
    justify-content: center;
    gap: 24px;
    height: 800px; /* Fixed height for the visible area */
    overflow: hidden;
    /* Fade mask for top and bottom */
    mask-image: linear-gradient(to bottom, transparent, black 15%, black 85%, transparent);
    -webkit-mask-image: linear-gradient(to bottom, transparent, black 15%, black 85%, transparent);
}

/* Individual Columns */
.marquee-column {
    flex: 1;
    max-width: 350px;
    display: flex;
    flex-direction: column;
    gap: 24px;
    /* Ensure content doesn't shrink */
    min-width: 280px;
}

/* Scrolling Animation Wrapper */
.marquee-scroll-wrapper {
    display: flex;
    flex-direction: column;
    gap: 24px;
    animation: scroll-vertical linear infinite;
}

/* Animation Durations for Parallax Effect */
.col-duration-slow { animation-duration: 25s; }
.col-duration-medium { animation-duration: 20s; }
.col-duration-fast { animation-duration: 22s; }

@keyframes scroll-vertical {
    0% { transform: translateY(0); }
    100% { transform: translateY(-50%); }
}

/* Testimonial Card Styles */
.testimonial-hero-card {
    background: #fff;
    border-radius: 24px;
    padding: 30px;
    border: 1px solid #eaeaea;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05); /* Soft shadow from reference */
    transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.testimonial-hero-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    border-color: rgba(191, 37, 58, 0.2); /* Brand hint on hover */
}

.t-card-text {
    font-size: 1rem;
    line-height: 1.6;
    color: #444;
    margin-bottom: 20px;
}

.t-card-user {
    display: flex;
    align-items: center;
    gap: 12px;
}

.t-user-img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.t-user-info {
    display: flex;
    flex-direction: column;
}

.t-user-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-color);
}

.t-user-role {
    font-size: 0.85rem;
    color: #888;
}

/* Responsive Visibility */
@media (max-width: 1024px) {
    .marquee-column:nth-child(3) {
        display: none; /* Hide 3rd column on tablets */
    }
}

@media (max-width: 768px) {
    .testimonials-marquee-grid {
        height: 600px;
    }
    .marquee-column:nth-child(2) {
        display: none; /* Hide 2nd column on mobile, show only 1 */
    }
    .testimonials-hero-header h1 {
        font-size: 2.5rem;
    }
}

/* Emergency Restore for Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* Force single row on desktop */
    gap: 30px;
    margin-top: 40px;
}

@media (max-width: 1024px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .features-grid {
        grid-template-columns: 1fr;
    }
}

.feature-item {
    text-align: center;
    padding: 30px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.feature-icon {
    width: 60px;
    height: 60px;
    background: rgba(191, 37, 58, 0.1);
    border-radius: 50%;
    margin: 0 auto 20px;
    /* Placeholder for icon */
}

/* --- Services Page Specifics --- */

/* --- Blur Overlay --- */
#blur-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(0px);
    -webkit-backdrop-filter: blur(0px);
    pointer-events: none;
    opacity: 0;
    z-index: 1500; /* High but below hovered card */
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

body:has(.service-card-small:hover) #blur-overlay {
    display: none;
}

/* Core Services - Small Grid */
.services-grid-small {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 24px;
    margin-top: 40px;
    position: relative;
    z-index: 1; /* Ensure grid has context */
}

@media (max-width: 640px) {
    .services-grid-small {
        grid-template-columns: repeat(2, 1fr) !important; /* Force 2 columns */
        gap: 12px; /* Match mobile hero card gap */
    }
}

.service-card-small {
    background: rgba(255, 255, 255, 0.15); /* Glass background */
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 30px; /* Button-like shape */
    padding: 30px 24px;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 140px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    position: relative;
    z-index: 1; /* Base z-index */
}

@media (max-width: 640px) {
    .service-card-small {
        padding: 15px 10px; /* Adjust padding */
        border-radius: 12px;
        min-height: 80px; /* Significantly reduced height */
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .service-card-small h3 {
        font-size: 0.8rem;
        line-height: 1.2;
        margin: 0;
    }
}

.service-card-small:hover {
    transform: scale(1.1) translateY(-5px);
    box-shadow: 0 25px 50px rgba(0,0,0,0.25); /* "shadow little big" */
    background: #ffffff; /* Solid white to be fully visible */
    z-index: 2000; /* Super high z-index to pop over overlay */
    border-color: var(--primary-color);
}

.service-card-small h3 {
    font-size: 1.1rem;
    margin: 0;
    color: var(--text-color);
    font-weight: 700;
}

/* --- About Us Tabbed Hero Section --- */
.about-hero-section {
    padding: 60px 0;
    background: #fff;
}

.about-hero-header {
    text-align: center;
    margin-bottom: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.about-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: 9999px;
    border: 1px solid #eaeaea;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-color);
    background-color: #fff;
}

.about-hero-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-color);
    max-width: 800px;
    line-height: 1.2;
}

.about-hero-desc {
    font-size: 1.1rem;
    color: #666;
    max-width: 600px;
}

/* Tabs Navigation */
.about-tabs-list {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.about-tab-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 12px;
    border: none;
    background: transparent;
    font-size: 0.95rem;
    font-weight: 600;
    color: #666;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.about-tab-btn:hover {
    background: rgba(0,0,0,0.03);
    color: var(--primary-color);
}

.about-tab-btn.active {
    background: #f4f4f4;
    color: var(--primary-color);
}

.about-tab-btn svg {
    width: 16px;
    height: 16px;
}

/* Tabs Content */
.about-tabs-content-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    background: #f9f9f9; /* Muted/70 equivalent */
    border-radius: 24px;
    padding: 40px;
    position: relative;
    overflow: hidden;
}

@media (min-width: 992px) {
    .about-tabs-content-wrapper {
        padding: 64px;
    }
}

.about-tab-content {
    display: none; /* Hidden by default */
    grid-template-columns: 1fr;
    gap: 40px;
    align-items: stretch; /* Changed to stretch for equal height */
}

.about-tab-content.active {
    display: grid;
    animation: slideInRight 0.6s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@media (min-width: 992px) {
    .about-tab-content {
        grid-template-columns: 1fr 1fr;
        gap: 80px;
    }
}

@keyframes slideInRight {
    from { opacity: 0; transform: translateX(-60px); }
    to { opacity: 1; transform: translateX(0); }
}

.tab-content-text {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: flex-start;
    justify-content: center; /* Center text vertically if needed */
}

.tab-badge {
    display: inline-flex;
    padding: 4px 12px;
    border-radius: 9999px;
    border: 1px solid #eaeaea;
    font-size: 0.75rem;
    font-weight: 600;
    background: #fff;
    color: var(--text-color);
}

.tab-title {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.1;
    color: var(--text-color);
}

@media (min-width: 992px) {
    .tab-title {
        font-size: 3rem;
    }
}

.tab-desc {
    font-size: 1.1rem;
    color: #666;
    line-height: 1.6;
}

.tab-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 32px;
    border-radius: 8px;
    background: var(--primary-color);
    color: #fff;
    font-weight: 500;
    font-size: 1rem;
    border: none;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.2s ease;
}

.tab-btn:hover {
    background: var(--secondary-color);
    transform: translateY(-2px);
}

.tab-image-wrapper {
    width: 100%;
    height: 100%; /* Changed to 100% */
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    position: relative;
}

.tab-image-wrapper img {
    width: 100%;
    height: 100%; /* Changed to 100% */
    object-fit: cover; /* Added object-fit cover */
    display: block;
    transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.about-tab-content:hover .tab-image-wrapper img {
    transform: scale(1.02);
}

/* Enhanced Hero Text Coloring */
.hero-title {
    font-size: 3.5rem;
    line-height: 1.2;
    font-weight: 800;
    max-width: 900px;
    margin: 0 auto;
    color: #222; /* Darker for index.html */
}

.hero-services .hero-title {
    color: #fff;
    text-shadow: 0 4px 20px rgba(0,0,0,0.5); /* Stronger shadow for contrast */
}

.hero-services .gradient-text {
    background: linear-gradient(135deg, #FF4D6D 0%, #FF8FA3 100%);
    -webkit-background-clip: text;
    background-clip: text;
    filter: drop-shadow(0 0 20px rgba(255, 77, 109, 0.6));
}

.gradient-text {
    background: linear-gradient(135deg, #D90429 0%, #EF233C 50%, #8D99AE 100%); /* More vibrant gradient */
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 900;
    text-shadow: none; /* Text shadow doesn't work well with background-clip: text */
    filter: drop-shadow(0 2px 10px rgba(217, 4, 41, 0.3)); /* Use filter instead */
}

/* How It Works */
.process-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.step-card {
    position: relative;
    padding: 30px 20px;
    text-align: center;
}

.step-number {
    font-size: 4rem;
    font-weight: 900;
    color: rgba(191, 37, 58, 0.08);
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    z-index: 0;
    line-height: 1;
}

.step-card h3 {
    position: relative;
    z-index: 1;
    margin-top: 20px;
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.step-card p {
    position: relative;
    z-index: 1;
    color: #666;
    font-size: 0.95rem;
}

/* Testimonials Grid */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.testimonial-card {
    padding: 30px;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* Service Packages */
.packages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
    /* Cards will stretch to equal height by default in grid */
}

.package-card {
    padding: 40px 30px;
    text-align: center;
    position: relative;
    background: #fff;
    border: 1px solid #eee;
    border-radius: 16px;
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.package-features {
    margin-bottom: 30px;
    text-align: left;
    flex: 1; /* Pushes the button to the bottom for alignment */
}

.package-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.package-card.featured-package {
    border: 2px solid var(--primary-color);
    transform: scale(1.05);
    z-index: 1;
    box-shadow: 0 10px 30px rgba(191, 37, 58, 0.1);
}

.package-card.featured-package:hover {
    transform: scale(1.05) translateY(-8px);
}

.badge-popular {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-color);
    color: #fff;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
}

.package-card h3 {
    font-size: 1.8rem;
    margin-bottom: 10px;
}


/* =========================================
   Global Mobile Responsiveness Enhancements
   ========================================= */

@media (max-width: 991px) {
    html {
        font-size: 15px;
    }
    
    section {
        padding: 60px 0;
    }
    
    .hero-title {
        font-size: 2.8rem;
    }
    
    .hero-description {
        font-size: 1.1rem;
    }
}

@media (max-width: 768px) {
    html {
        font-size: 14px;
    }

    /* Typography adjustments */
    h1, .h1 { font-size: 2.2rem !important; }
    h2, .h2 { font-size: 1.8rem !important; }
    h3, .h3 { font-size: 1.4rem !important; }
    p, .lead { font-size: 1rem !important; }

    /* Section spacing */
    section {
        padding: 40px 0 !important;
    }
    
    .container {
        padding-left: 20px;
        padding-right: 20px;
    }

    /* Hero Section */
    .hero-section {
        padding-top: 90px; /* Reduced padding */
        padding-bottom: 90px; /* Reduced padding */
        min-height: 50vh; /* Reduced height */
        display: flex;
        align-items: center; /* Vertically align content */
    }
    
    .hero-content {
        text-align: center;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .hero-badge {
        margin-left: auto !important;
        margin-right: auto !important;
    }
    
    .hero-title {
        font-size: 1.8rem !important; /* Slightly smaller title for better fit */
        line-height: 1.2;
        text-align: center;
    }
    
    .hero-description {
        font-size: 0.95rem; /* Slightly smaller description */
        margin-bottom: 10px; /* Reduced gap */
        text-align: center;
    }
    
    .hero-actions {
        flex-direction: row;
        gap: 10px; /* Reduced gap between buttons */
        margin-top: 5px; /* Reduced gap from content above */
        justify-content: center; /* Center buttons */
        width: 100%;
    }
    
    .hero-actions .btn {
        width: auto;
        flex: 0 1 auto; /* Prevent stretching */
        padding: 6px 14px; /* Smaller padding */
        font-size: 0.75rem; /* Smaller text */
        white-space: nowrap;
        display: flex;
        align-items: center;
        justify-content: center;
        min-width: 90px; /* Smaller min-width */
    }

    /* Grids to single column */
    .testimonials-grid,
    .packages-grid,
    .clients-grid,
    .about-tab-content {
        grid-template-columns: 1fr !important;
        gap: 30px;
    }
    
    /* Infinite Swiping Services Grid for Mobile (Applied to Services, Portfolio, Blog) */
    .services-grid,
    .portfolio-grid,
    .blog-grid {
        display: flex !important;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 15px;
        padding-bottom: 20px;
        scrollbar-width: none;
        -ms-overflow-style: none;
        grid-template-columns: none !important;
    }

    .services-grid::-webkit-scrollbar,
    .portfolio-grid::-webkit-scrollbar,
    .blog-grid::-webkit-scrollbar {
        display: none;
    }

    .services-grid .service-card,
    .portfolio-grid .portfolio-item,
    .blog-grid .blog-card {
        flex: 0 0 80%;
        width: 80%;
        scroll-snap-align: center;
        margin: 0;
        padding: 0 !important; /* Removed padding to let image fill full width */
        transform: scale(1) !important;
        transition: transform 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
        animation: none !important;
        opacity: 1 !important;
        -webkit-tap-highlight-color: transparent;
        overflow: hidden; /* Clip image corners */
        display: flex;
        flex-direction: column;
    }
    
    /* Disable hover/focus effects, but allow Active (Click) effect */
    .services-grid .service-card:hover,
    .services-grid .service-card:focus,
    .services-grid .service-card.reveal,
    .portfolio-grid .portfolio-item:hover,
    .portfolio-grid .portfolio-item:focus,
    .blog-grid .blog-card:hover,
    .blog-grid .blog-card:focus {
        transform: scale(1) !important;
        box-shadow: var(--shadow-soft) !important;
        opacity: 1 !important;
    }

    /* Click/Tap Animation - Scale Down "Un-zoom" */
    .services-grid .service-card:active,
    .portfolio-grid .portfolio-item:active,
    .blog-grid .blog-card:active {
        transform: scale(0.96) !important;
        transition: transform 0.1s ease !important; /* Fast press */
    }

    /* Full Width Images */
    .services-grid .service-card img,
    .services-grid .service-card:hover img,
    .portfolio-grid .portfolio-item img,
    .portfolio-grid .portfolio-item:hover img,
    .blog-grid .blog-card img,
    .blog-grid .blog-card:hover img {
        width: 100% !important;
        height: 250px; /* Increased height significantly ("more below") */
        border-radius: 0 !important;
        transform: none !important;
        transition: none !important;
        object-fit: cover;
        margin: 0 !important;
        display: block;
    }
    
    /* Reset Portfolio Image Wrapper */
    .portfolio-grid .portfolio-item .portfolio-image {
        width: 100%;
        padding: 0;
        margin: 0;
        border-radius: 0;
    }

    /* Restore Padding for Text Content */
    .services-grid .service-card .service-content,
    .portfolio-grid .portfolio-item .portfolio-content,
    .blog-grid .blog-card .blog-content {
        padding: 20px;
        width: 100%;
        text-align: left;
    }

    .services-grid .service-card h3,
    .portfolio-grid .portfolio-item h3,
    .blog-grid .blog-card h3 {
        font-size: 1.1rem;
        margin-bottom: 8px;
        margin-top: 0;
    }

    .services-grid .service-card p,
    .portfolio-grid .portfolio-item p,
    .blog-grid .blog-card p {
        font-size: 0.8rem;
        line-height: 1.3;
        margin-bottom: 10px;
    }
    
    .services-grid .service-card .learn-more,
    .blog-grid .blog-card .read-more {
        font-size: 0.85rem;
    }

    /* Swipeable sections REMOVED for Mobile - Changed to 2x2 Grid */
    /* .process-steps,
    .features-grid {
        display: flex !important;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        padding-bottom: 20px;
        gap: 20px;
        scrollbar-width: none;
        -ms-overflow-style: none;
        grid-template-columns: none !important;
    }

    .process-steps::-webkit-scrollbar,
    .features-grid::-webkit-scrollbar {
        display: none;
    }

    .process-steps .step-card,
    .features-grid .feature-item {
        flex: 0 0 85%;
        scroll-snap-align: center;
        width: 85%;
        margin: 0;
    } */
    
    /* Force 2x2 Grid for Mobile (overriding any potential flex inheritance) */
    .process-steps,
    .features-grid {
        display: grid !important;
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 15px;
        overflow-x: visible; /* Ensure no scroll */
        padding-bottom: 0;
    }
    
    .process-steps .step-card,
    .features-grid .feature-item {
        width: 100%;
        margin: 0;
        flex: none; /* Reset flex */
    }

    /* Careers Grid - 1 by 1 on Mobile (No Swipe) */
    #careers-grid {
        display: grid !important;
        grid-template-columns: 1fr !important;
        overflow-x: visible;
        scroll-snap-type: none;
        padding-bottom: 0;
        gap: 20px;
    }

    #careers-grid .service-card {
        flex: none;
        width: 100%;
        scroll-snap-align: none;
        margin-bottom: 10px;
    }

    /* Career Popup Meta - Column on Mobile */
    .career-popup-meta {
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 5px !important;
        margin-top: 10px;
    }
    
    .career-popup-meta span {
        display: block;
        margin-right: 0 !important;
        font-size: 0.9rem;
    }

    /* Specific Card Adjustments */
    .testimonial-card,
    .package-card,
    .client-card {
        width: 100%;
        margin: 0 auto;
    }
    
    /* Marquee Text */
    .marquee-tag {
        font-size: 1.5rem;
    }
    
    .cta-content-wrapper h2 {
        font-size: 1.8rem;
    }
    
    /* Stats */
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .stat-number {
        font-size: 2.5rem;
    }

    /* Navigation */
    .nav-menu {
        padding-top: 80px;
    }
    
    /* Footer */
    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }
    
    .footer-column {
        align-items: center;
    }
    
    /* CTA Buttons in Footer/Marquee */
    .cta-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .btn-cta {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 1.8rem !important;
    }
    
    .section-header h2 {
        font-size: 1.6rem !important;
    }
    
    .btn {
        padding: 12px 20px;
        font-size: 0.95rem;
    }
}


/* --- Fixed & Added Styles --- */

/* Modal Styles (Fix for Popup) */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-overlay.hidden {
    display: none;
}

.modal-container {
    background: #fff;
    padding: 40px;
    border-radius: 16px;
    max-width: 600px;
    width: 90%;
    position: relative;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
    transform: translateY(20px);
    transition: transform 0.3s ease;
    text-align: left; /* Ensure all content is left aligned */
}

.modal-overlay.active .modal-container {
    transform: translateY(0);
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 2rem;
    background: none;
    border: none;
    cursor: pointer;
    color: #666;
}

.close-modal:hover {
    color: #333;
}

.modal-body {
    text-align: left;
}

.modal-body h3 {
    margin-bottom: 15px;
    color: var(--primary-color);
    font-size: 1.8rem;
    text-align: left;
}

.modal-body p {
    margin-bottom: 20px;
    color: #555;
    line-height: 1.6;
    text-align: left;
}

.modal-benefits-section h4 {
    margin-bottom: 10px;
    font-size: 1.1rem;
    font-weight: 700;
    text-align: left;
}

.modal-benefits-section ul {
    list-style: none;
    padding-left: 0;
    margin-bottom: 25px;
    text-align: left;
}

.modal-actions {
    text-align: left;
    margin-top: 20px;
}

.modal-actions .cta-button {
    display: inline-flex;
    align-items: center;
    background-color: var(--primary-color);
    color: #fff;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    transition: background-color 0.3s ease;
    text-decoration: none;
}

.modal-actions .cta-button:hover {
    background-color: var(--secondary-color);
}

/* About Page Redesign Styles */
.about-card {
    background: #fff;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    border: 1px solid #eee;
    position: relative;
    overflow: hidden;
    z-index: 1;
    display: flex;
    flex-direction: column;
}

/* Hover Animation for all cards */
.about-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.15);
}

.about-card[data-bg] {
    color: #fff;
    border: none;
    background: transparent;
}

.about-card-bg-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    z-index: 0;
}

.about-card-bg-img.about-bg-185 { background-image: url('../assets/images/page_images/185.jpg'); }
.about-card-bg-img.about-bg-2475697 { background-image: url('../assets/images/page_images/2475697.jpg'); }
.about-card-bg-img.about-bg-2431 { background-image: url('../assets/images/page_images/2431.jpg'); }
.about-card-bg-img.about-bg-1333 { background-image: url('../assets/images/page_images/1333.jpg'); }

.about-card:hover .about-card-bg-img {
    transform: scale(1.1);
}

.about-card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.65);
    z-index: 1;
    transition: background 0.3s ease;
}

.about-card:hover .about-card-overlay {
    background: rgba(0, 0, 0, 0.55);
}

.about-card[data-bg] h3,
.about-card[data-bg] p {
    color: #fff;
    position: relative;
    z-index: 2;
}

.about-section-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.about-grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-top: 40px;
}

.about-card h3 {
    font-size: 1.8rem; /* Increased size (was 1.5rem) */
    margin-bottom: 15px;
    color: var(--text-color);
}

.about-card p {
    color: #666;
    line-height: 1.6;
    font-size: 0.95rem; /* Base size */
    flex-grow: 1; /* Push CTA to bottom */
}

/* Web-only description text size reduction */
@media (min-width: 1025px) {
    .about-card p {
        font-size: 0.85rem; /* Reduced for web interface as requested */
    }
}

/* Staggered Card Animation */
@keyframes staggeredFadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Initial hidden state for cards within the grid */
.about-grid-4 .about-card {
    opacity: 0;
    transform: translateY(30px);
}

/* Trigger animation when parent has .active (added by JS scroll observer) */
.about-grid-4.active .about-card {
    animation: staggeredFadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

/* Stagger delays */
.about-grid-4.active .about-card:nth-child(1) { animation-delay: 0.1s; }
.about-grid-4.active .about-card:nth-child(2) { animation-delay: 0.2s; }
.about-grid-4.active .about-card:nth-child(3) { animation-delay: 0.3s; }
.about-grid-4.active .about-card:nth-child(4) { animation-delay: 0.4s; }


/* CTA Button Styles */
.btn-card-cta {
    display: inline-block;
    margin-top: 20px;
    padding: 10px 20px;
    background-color: var(--primary-color);
    color: #fff;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: background 0.3s ease, transform 0.2s ease;
    align-self: flex-start;
    position: relative;
    z-index: 2;
    border: 1px solid transparent;
}

.btn-card-cta:hover {
    background-color: var(--secondary-color);
    transform: translateY(-2px);
    color: #fff;
}

/* Adjust CTA for data-bg cards */
.about-card[data-bg] .btn-card-cta {
    background-color: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(4px);
}

.about-card[data-bg] .btn-card-cta:hover {
    background-color: #fff;
    color: var(--primary-color);
    border-color: #fff;
}

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

@media (max-width: 480px) {
    .about-grid-4 {
        grid-template-columns: repeat(2, 1fr); /* Force 2x2 on mobile */
        gap: 10px; /* Reduced gap for mobile */
    }
    
    .about-card {
        padding: 15px; /* Reduced padding */
    }
    
    .about-card h3 {
        font-size: 0.9rem !important; /* ~2x smaller than 1.8rem */
        margin-bottom: 8px;
    }
    
    .about-card p {
        font-size: 0.55rem !important; /* ~2x smaller than ~1rem */
        line-height: 1.4;
    }

    .about-card-icon svg {
        width: 24px;
        height: 24px;
    }

    .btn-card-cta {
        padding: 6px 12px;
        font-size: 0.6rem; /* Smaller CTA text */
        margin-top: 10px;
    }

    /* Hero Tabs Mobile Fix */
    .about-tabs-list {
        display: flex;
        flex-direction: row; /* Ensure row layout */
        flex-wrap: nowrap; /* Prevent wrapping */
        overflow-x: auto; /* Allow scrolling if needed */
        justify-content: space-between;
        padding-bottom: 10px; /* Space for scrollbar if any */
        -webkit-overflow-scrolling: touch;
    }
    
    .about-tab-btn {
        flex: 1;
        min-width: auto;
        padding: 10px;
        font-size: 0.9rem;
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    
    .about-tab-btn svg {
        margin-right: 0;
        margin-bottom: 5px;
    }

    /* Hide Hero Image on Mobile */
    .about-tab-content .tab-image-wrapper {
        display: none;
    }
}

/* Typing Container Smoothness */
.typing-container {
    min-height: 3em; /* Base height */
    transition: height 0.3s ease-out;
    overflow: hidden;
}

/* Strategic Partners Logo Bg - Force Override */
.partners-section .client-logo-box,
.partners-section .client-logo-box.partner-highlight {
    background-color: #E8E8E8 !important;
    border: 1px solid transparent; /* Optional cleanup */
}

.about-card-icon {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.about-card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--text-color);
}

.about-card p {
    color: #666;
    line-height: 1.6;
}

/* Refactored Inline Styles */
.map-container {
    width: 100%;
    height: 450px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
}

.map-container iframe {
    border: 0;
    width: 100%;
    height: 100%;
}

.cta-icon {
    margin-left: 8px;
    display: inline-block;
    vertical-align: text-bottom;
}

.reach-out-btn-link {
    text-decoration: none;
    color: inherit;
}

.stat-label-white {
    color: #fff;
}

.modal-benefits-section li {
    margin-bottom: 8px;
    color: #666;
    position: relative;
    padding-left: 20px;
}

.modal-benefits-section li::before {
    content: "✓";
    color: var(--primary-color);
    position: absolute;
    left: 0;
    font-weight: bold;
}

.modal-actions {
    display: flex;
    gap: 15px;
}

/* Hover Pop + Zoom + Shadow Effects */
.service-card-small,
.step-card,
.feature-item,
.testimonial-card,
.package-card {
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 6px 18px rgba(0,0,0,0.06);
    border: 1px solid #eee; /* Ensure border exists for effect */
    background: #fff; /* Ensure background is white */
    border-radius: 16px; /* Consistent radius */
    overflow: hidden; /* For zoom effect if images are present */
}

.service-card-small:hover,
.step-card:hover,
.feature-item:hover,
.testimonial-card:hover,
.package-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    z-index: 10;
}

/* Adjust Spacing in Final CTA Section */
.final-cta-section {
    padding: 100px 0;
}

.final-cta-section h2 {
    margin-bottom: 25px;
}

.final-cta-section p {
    margin-bottom: 40px;
    font-size: 1.2rem;
    color: #555;
}

/* Remove Icons from Why Choose IT KeySource (Styling backup if HTML removal isn't enough) */
.feature-icon {
    display: none !important;
}

/* Specific fix for Service Card Small Layout */
.services-grid-small {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 40px;
}

.service-card-small {
    padding: 30px;
    text-align: center;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 120px;
    flex-direction: column;
}

.service-card-small h3 {
    font-size: 1.2rem;
    margin: 0;
    color: var(--text-color);
}

.service-card-small:hover h3 {
    color: var(--primary-color);
}

/* Process Steps (How It Works) Styling */
.process-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.step-card {
    padding: 30px;
    text-align: center;
    position: relative;
}

.step-number {
    font-size: 3rem;
    font-weight: 900;
    color: rgba(191, 37, 58, 0.1);
    margin-bottom: 15px;
    line-height: 1;
}

.step-card h3 {
    margin-bottom: 15px;
}

/* --- Refined Service Packages (Alignment) --- */
.package-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 40px 30px;
    text-align: center;
    height: 100%; /* Uniform height */
    overflow: visible; /* Allow badge to pop out */
    position: relative; /* For badge positioning */
}

/* Ensure hover effect doesn't clip badge either */
.package-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    z-index: 10;
    overflow: visible;
}

.package-features {
    width: 100%;
    margin: 25px 0 35px;
    padding: 0 10px; /* Add internal padding */
    text-align: left; /* Align list text to left */
}

.package-features li {
    margin-bottom: 12px;
    display: flex;
    align-items: flex-start;
    gap: 10px; /* Tighter gap */
    font-size: 1rem;
    color: #555;
    line-height: 1.4;
}

.package-features li::before {
    content: "✓";
    color: var(--primary-color);
    font-weight: bold;
    flex-shrink: 0; /* Prevent icon shrinking */
    width: 16px; /* Fixed width for alignment */
}

.package-card .btn {
    margin-top: auto; /* Push button to bottom */
    width: 100%;
    padding: 12px 20px; /* Adjust padding if needed */
}

/* Fix Badge Position */
.badge-popular {
    top: -18px; /* Slightly higher to clear border */
    padding: 6px 20px;
    font-size: 0.85rem;
    box-shadow: 0 4px 10px rgba(191, 37, 58, 0.3); /* Add shadow to badge */
    z-index: 2;
}

/* --- Refined Testimonials & Why Choose Us (Card Design) --- */
.testimonial-card, 
.feature-item {
    background: #ffffff;
    border: 1px solid rgba(0,0,0,0.04);
    border-radius: 24px; /* Modern rounded corners */
    padding: 40px 30px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03); /* Subtle start */
    transition: all 0.5s cubic-bezier(0.2, 0.8, 0.2, 1); /* Smooth physics */
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.testimonial-card::before,
.feature-item::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.testimonial-card:hover, 
.feature-item:hover {
    transform: translateY(-12px) scale(1.02);
    box-shadow: 0 20px 50px rgba(0,0,0,0.12);
    border-color: rgba(191, 37, 58, 0.1);
}

.testimonial-card:hover::before,
.feature-item:hover::before {
    opacity: 1;
}

.testimonial-card .quote {
    font-style: italic;
    font-size: 1.1rem;
    color: #444;
    margin-bottom: 25px;
    position: relative;
    z-index: 2;
}

.testimonial-card .author strong {
    display: block;
    color: var(--primary-color);
    font-size: 1.1rem;
}

.testimonial-card .author span {
    font-size: 0.9rem;
    color: #888;
}

/* --- How It Works (Step Card Image Animation) --- */
.step-card {
    position: relative;
    border-radius: 20px;
    padding: 50px 30px 40px;
    text-align: center;
    border: 1px solid rgba(0,0,0,0.1);
    overflow: hidden;
    transition: all 0.4s ease;
    z-index: 1;
    min-height: 320px; /* Ensure height for image visibility */
    display: flex;
    flex-direction: column;
    justify-content: flex-end; /* Align content to bottom like a card */
    isolation: isolate;
    box-shadow: var(--shadow-soft);
}

.step-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
    z-index: -1;
}

.step-bg.step-bg-1 { background-image: url('../assets/images/page_images/conducting-keyword-research-effective-seo-content-strategy.jpg'); }
.step-bg.step-bg-2 { background-image: url('../assets/images/page_images/business-team-collaboration-discussing-working-analyzing-with-financial-data-marketing-growth-report-graph-team-presentation-brainstorming-strategy-planning-making-profit-company.jpg'); }
.step-bg.step-bg-3 { background-image: url('../assets/images/page_images/hands-drawing-software-scrum-agile-board-with-paper-task-closeup.jpg'); }
.step-bg.step-bg-4 { background-image: url('../assets/images/page_images/close-up-businessman-hand-holding-smartphone-with-creative-big-data-transfer-digital-transformation-hologram-blue-background.jpg'); }

/* Dark Overlay */
.step-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.4) 60%, rgba(0,0,0,0.2) 100%);
    transition: background 0.4s ease;
}

.step-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 50px rgba(0,0,0,0.2);
    border-color: transparent;
}

.step-card:hover .step-bg {
    transform: scale(1.1);
}

.step-card:hover .step-bg::before {
    background: linear-gradient(to top, rgba(191, 37, 58, 0.9) 0%, rgba(191, 37, 58, 0.5) 100%);
}

.step-content {
    position: relative;
    z-index: 2;
    color: #fff;
    transform: translateY(0);
    transition: transform 0.4s ease;
}

.step-card:hover .step-content {
    transform: translateY(-5px);
}

.step-card h3 {
    margin-top: 0;
    font-size: 1.5rem;
    color: #fff;
    margin-bottom: 15px;
    font-weight: 700;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.step-card p {
    color: rgba(255, 255, 255, 0.95);
    font-size: 1rem;
    line-height: 1.6;
    text-shadow: 0 1px 4px rgba(0,0,0,0.3);
}

/* Smooth Scrolling Effect for Testimonials (Marquee feel without JS) */
/* Note: The user asked for "smooth scrolling effect" in this section. 
   If they meant the page scroll, it's handled by 'html { scroll-behavior: smooth; }'.
   If they meant a horizontal scroll for testimonials: */
.testimonials-grid {
    /* Optional: If we want to enforce a grid that looks good */
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}


/* =========================================
   Blog Hero Section Styles (New Addition)
   ========================================= */

.blog-hero-section {
    padding: 40px 0;
    background-color: var(--bg-color);
}

.blog-hero-header {
    margin-bottom: 24px;
}

.blog-hero-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text-color);
    /* Smooth entry animation */
    animation: fadeInUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.blog-hero-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
}

/* Desktop Layout */
@media (min-width: 992px) {
    .blog-hero-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* First item spans 2 columns (full width or split featured) */
    .blog-hero-card.featured {
        grid-column: span 2;
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 32px;
        align-items: center;
        height: 420px; /* Increased height by 1.5x */
    }

    .blog-hero-card.featured .blog-card-image-wrapper {
        height: 100%;
        min-height: auto;
        height: 420px; /* Increased height */
        aspect-ratio: auto; 
    }
    
    .blog-hero-card.featured .blog-card-content {
        padding: 0; /* Remove padding as it's side-by-side */
        padding-right: 20px;
        gap: 10px;
    }
    
    .blog-hero-card.featured .blog-card-title {
        font-size: 1.75rem; /* Larger title for featured */
        line-height: 1.2;
    }
    
    .blog-hero-card.featured .blog-card-desc {
        line-clamp: 4;
        -webkit-line-clamp: 4; /* Increased lines for taller card */
        font-size: 1rem;
    }
}

.blog-hero-card {
    background: #fff;
    /* No border for cleaner look, or subtle border */
    border: 1px solid rgba(0,0,0,0.05);
    border-radius: var(--radius-card);
    overflow: hidden;
    position: relative;
    transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), 
                box-shadow 0.4s cubic-bezier(0.22, 1, 0.36, 1);
    
    /* Animation on load */
    animation: fadeInUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) forwards;
    opacity: 0;
    animation-delay: 0.2s;
    display: flex;
    flex-direction: column;
}

/* Stagger animation delays */
.blog-hero-card:nth-child(2) { animation-delay: 0.4s; }
.blog-hero-card:nth-child(3) { animation-delay: 0.6s; }
.blog-hero-card:nth-child(4) { animation-delay: 0.8s; }

.blog-hero-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-hover);
}

.blog-card-image-wrapper {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/9;
    background-color: #f0f0f0;
}

.blog-card-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.blog-hero-card:hover .blog-card-image-wrapper img {
    transform: scale(1.08);
}

.blog-card-content {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.blog-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 4px;
}

.blog-badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 14px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background-color: rgba(191, 37, 58, 0.1); /* Primary with opacity */
    color: var(--primary-color);
}

.blog-author {
    display: flex;
    align-items: center;
    gap: 10px;
}

.author-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.author-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-color);
}

.author-label {
    font-size: 0.875rem;
    color: #888;
}

.blog-card-title {
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1.3;
    color: var(--text-color);
    margin: 0;
    transition: color 0.3s ease;
}

.blog-hero-card:hover .blog-card-title {
    color: var(--primary-color);
}

.blog-card-desc {
    font-size: 1rem;
    color: #666;
    line-height: 1.6;
    display: -webkit-box;
    line-clamp: 3;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .blog-hero-title {
        font-size: 2rem;
    }
    
    .blog-hero-card.featured {
        grid-column: span 1;
        display: block;
    }
    
    .blog-hero-card.featured .blog-card-image-wrapper {
        aspect-ratio: 16/9;
        min-height: auto;
    }
    
    .blog-hero-card.featured .blog-card-content {
        padding: 24px;
    }
    
    .blog-hero-card.featured .blog-card-title {
        font-size: 1.5rem;
    }
}
/* Horizontal Card Layout for Bottom Cards */
@media (min-width: 992px) {
    .blog-hero-card.horizontal {
        display: grid;
        grid-template-columns: 1.5fr 1fr; /* Text left (wider), Image right */
        gap: 24px;
        align-items: center;
        height: 100%; /* Match height of adjacent cards if needed */
        min-height: 240px;
    }

    .blog-hero-card.horizontal .blog-card-content {
        padding: 24px;
        padding-right: 0; /* Remove right padding to hug image */
        order: 1; /* Text first (left) */
    }

    .blog-hero-card.horizontal .blog-card-image-wrapper {
        order: 2; /* Image second (right) */
        height: 100%;
        min-height: 100%;
        aspect-ratio: auto;
    }

    .blog-hero-card.horizontal .blog-card-title {
        font-size: 1.5rem;
        line-height: 1.3;
    }
    
    .blog-hero-card.horizontal .blog-card-desc {
         line-clamp: 3;
         -webkit-line-clamp: 3;
    }
}

    /* Reversed Layout for Bottom Featured Card */
    .blog-hero-card.featured.reversed {
        grid-template-columns: 1fr 1fr; /* Keep 50/50 split */
    }

    .blog-hero-card.featured.reversed .blog-card-image-wrapper {
        order: 2; /* Image moves to right */
    }

    .blog-hero-card.featured.reversed .blog-card-content {
        order: 1; /* Content moves to left */
        padding-right: 0;
        padding-left: 20px; /* Swap padding */
    }

/* CTA Marquee Section Styles */
.cta-marquee-section {
    padding: 100px 0 60px;
    background: #fff;
    overflow: hidden;
}

.cta-content-wrapper {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 60px;
}

.cta-content-wrapper h2 {
    font-size: 3.5rem;
    font-weight: 600;
    color: #333;
    margin-bottom: 20px;
    line-height: 1.2;
}

.cta-content-wrapper p {
    font-size: 1.25rem;
    color: #666;
    margin-bottom: 40px;
    line-height: 1.6;
}

.cta-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.btn-cta {
    position: relative;
    padding: 16px 32px;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    font-size: 1rem;
    letter-spacing: 0.5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-cta.primary {
    background: var(--primary-color); 
    color: #fff;
    border: none;
}

.btn-cta.secondary {
    background: transparent;
    border: 1px solid #e5e5e5;
    color: #333;
}

.btn-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.btn-cta.primary:hover {
     background: var(--secondary-color);
     box-shadow: 0 10px 20px rgba(191, 37, 58, 0.3);
}

.btn-cta.secondary:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

/* Shine Effect */
.btn-shine {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, transparent, rgba(255,255,255,0.2), transparent);
    transform: translateX(-100%);
    transition: transform 0.5s;
    pointer-events: none;
}

.btn-cta:hover .btn-shine {
    transform: translateX(100%);
    transition: transform 0.7s;
}

/* Marquee */
.cta-marquee-wrapper {
    position: relative;
    width: 100%;
    overflow: hidden;
    padding: 40px 0;
}

.cta-marquee {
    display: flex;
    overflow: hidden;
    user-select: none;
}

.marquee-content {
    display: flex;
    gap: 4rem;
    animation: marqueeScroll 40s linear infinite;
    flex-shrink: 0;
    padding-right: 4rem;
    min-width: 100%;
    justify-content: space-around;
}

.marquee-tag {
    font-size: 3rem;
    font-weight: 300;
    color: #333;
    white-space: nowrap;
    opacity: 0.8;
}

@keyframes marqueeScroll {
    from { transform: translateX(0); }
    to { transform: translateX(-100%); }
}

/* Vignettes */
.marquee-fade-left, .marquee-fade-right {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 150px;
    z-index: 2;
    pointer-events: none;
}

.marquee-fade-left {
    left: 0;
    background: linear-gradient(to right, #fff, transparent);
}

.marquee-fade-right {
    right: 0;
    background: linear-gradient(to left, #fff, transparent);
}

@media (max-width: 768px) {
    .cta-content-wrapper h2 {
        font-size: 2.5rem;
    }
    .marquee-tag {
        font-size: 2rem;
    }
    .cta-buttons {
        flex-direction: column;
        align-items: stretch;
    }
    .btn-cta {
        text-align: center;
        width: 100%;
    }
}



/* --- Career Card Styles (Removed Inline) --- */
.career-card-content {
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.career-card-title {
    margin-bottom: 1rem;
}

.career-card-meta {
    margin-bottom: 1.5rem;
    color: #666;
    font-size: 0.9rem;
}

.career-card-btn {
    margin-top: auto;
}

.no-openings-msg {
    grid-column: 1/-1;
    text-align: center;
    padding: 2rem;
}

/* --- Popup Styles --- */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    backdrop-filter: blur(4px);
}

.popup-overlay.active {
    opacity: 1;
    visibility: visible;
}

.popup-content {
    background: #fff;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 12px;
    padding: 2rem;
    position: relative;
    transform: scale(0.9);
    transition: transform 0.3s ease;
    box-shadow: 0 20px 50px rgba(0,0,0,0.2);
}

.popup-overlay.active .popup-content {
    transform: scale(1);
}

.popup-close-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: #666;
    line-height: 1;
    z-index: 10;
}

.popup-close-btn:hover {
    color: #000;
}

.popup-title {
    margin-bottom: 1rem;
    font-size: 1.8rem;
    color: #333;
}

.popup-text {
    line-height: 1.6;
    color: #555;
}

.career-sections {
    margin-top: 20px;
}

.career-section {
    margin-bottom: 20px;
}

.career-section-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
}

.career-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    color: #666;
    font-size: 0.9rem;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
}

.career-apply-area-bottom {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    text-align: center;
}

.career-apply-area-bottom.left-aligned {
    text-align: left;
}

.popup-body-loading {
    text-align: center;
    padding: 40px;
    color: #666;
    font-style: italic;
}

.popup-error {
    text-align: center;
    padding: 20px;
    color: #d32f2f;
    background: #ffebee;
    border-radius: 8px;
}

/* --- Updated Service Card Small Styles (Added by Assistant) --- */
.service-card-small {
    display: flex;
    flex-direction: column;
    padding: 10px;
    min-height: 60px;
    text-align: center;
    justify-content: center;
}

.card-image-wrapper-small {
    width: 100%;
    height: 180px; /* Adjusted height */
    margin-bottom: 15px;
    border-radius: 12px;
    overflow: hidden;
    background: #f0f0f0;
    flex-shrink: 0;
}

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

.service-card-small:hover .card-image-wrapper-small img {
    transform: scale(1.1);
}

/* Modal Image Styles */
.modal-image-container {
    width: 100%;
    height: 300px;
    margin-bottom: 20px;
    border-radius: 12px;
    overflow: hidden;
    background: #f4f4f4;
}

.modal-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.modal-image-container.hidden {
    display: none;
}

/* About Us New Sections Styles */
.about-content-block {
    max-width: 900px;
    margin: 0 auto;
}

.row-split {
    display: flex;
    align-items: center;
    gap: 50px;
    margin-bottom: 40px;
}

.col-text {
    flex: 1;
}

.col-image {
    flex: 1;
}

.rounded-image {
    width: 100%;
    border-radius: 20px;
    object-fit: cover;
}

.expertise-list {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    margin-top: 25px;
}

.expertise-list li {
    position: relative;
    padding-left: 25px;
    font-weight: 500;
    color: #444;
    font-size: 1.05rem;
}

.expertise-list li::before {
    content: '✓';
    color: var(--primary-color);
    position: absolute;
    left: 0;
    font-weight: bold;
}

.growth-content {
    background: #fff;
    padding: 60px;
    border-radius: 20px;
    text-align: center;
    box-shadow: var(--shadow-soft);
    border: 1px solid #eaeaea;
}

.growth-text {
    max-width: 800px;
    margin: 0 auto;
}

.growth-text h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--text-color);
}

.growth-text p {
    font-size: 1.2rem;
    color: #555;
    line-height: 1.8;
}

/* Responsive */
@media (max-width: 768px) {
    .row-split {
        flex-direction: column;
    }
    .growth-content {
        padding: 30px;
    }
    .card-image-wrapper-small {
        height: 150px;
    }
    .modal-image-container {
        height: 200px;
    }
}


/* Benefits Page Styles */
.benefits-list {
    display: grid;
    gap: 2rem;
    margin-top: 2rem;
}

.benefit-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-card);
    box-shadow: var(--shadow-soft);
    transition: var(--transition-fast);
}

.benefit-card:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-2px);
}

.benefit-card h3 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 1.8rem;
    border-bottom: 2px solid var(--light-gray);
    padding-bottom: 0.5rem;
}

.benefit-section {
    margin-bottom: 1.5rem;
}

.benefit-section h4 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--text-color);
    font-weight: 700;
}

.benefit-content {
    color: #555;
}


/* Benefits Page Styles */
.loading-container {
    padding: 2rem;
}

.error-text {
    color: red;
}

/* Careers Page Styles */
.careers-loading {
    text-align: center;
    width: 100%;
    grid-column: 1 / -1;
    padding: 40px;
}

/* --- Updated Modal / Popup Styles --- */

/* Modal Container (Services Page) & Universal Popup */
.modal-container, .popup-content {
    background: #fff;
    width: 95%;
    max-width: 1000px;
    max-height: 80vh; /* Reduced height to not touch top/bottom */
    margin: 5vh auto; /* Center vertically with margin */
    overflow-y: auto;
    border-radius: 16px;
    position: relative;
    box-shadow: 0 25px 50px rgba(0,0,0,0.25);
    display: flex;
    flex-direction: column;
}

/* Ensure header is removed from flow when image is present for overlay effect */
.modal-body {
    position: relative;
    padding: 0;
    display: flex;
    flex-direction: column;
}

.modal-image-container {
    width: 100%;
    height: 300px; /* Fixed height for header image */
    overflow: hidden;
    position: relative;
    flex-shrink: 0;
}

.modal-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Dark gradient overlay on image */
.modal-image-container::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.4) 60%, rgba(0,0,0,0.8) 100%);
    pointer-events: none;
}

/* Text Overlay Logic */
/* When image is NOT hidden, style title/desc to be over the image */
.modal-image-container:not(.hidden) ~ #modal-title {
    margin-top: -80px; /* Pull up over image */
    margin-bottom: 5px;
    margin-left: 30px;
    margin-right: 30px;
    position: relative;
    z-index: 10;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
    font-size: 2.5rem;
}

.modal-image-container:not(.hidden) ~ #modal-description {
    margin-top: 0;
    margin-bottom: 20px;
    margin-left: 30px;
    margin-right: 30px;
    position: relative;
    z-index: 10;
    color: rgba(255, 255, 255, 0.9);
    text-shadow: 0 1px 3px rgba(0,0,0,0.5);
    font-size: 1.1rem;
    font-weight: 500;
}

/* When image IS hidden or missing, revert to normal */
.modal-image-container.hidden ~ #modal-title {
    margin: 30px 30px 10px;
    color: #333;
}
.modal-image-container.hidden ~ #modal-description {
    margin: 0 30px 20px;
    color: #666;
}

.modal-benefits-section {
    padding: 30px;
}

.modal-actions {
    padding: 0 30px 30px;
    margin-top: auto;
}

/* Close button style update for visibility on image */
.close-modal, .popup-close-btn {
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    color: #333;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    top: 20px;
    right: 20px;
    border: 1px solid rgba(255,255,255,0.4);
    cursor: pointer;
    z-index: 20;
    font-size: 1.5rem;
    line-height: 1;
    transition: all 0.3s ease;
}

.modal-image-container:not(.hidden) ~ .close-modal {
    color: #fff;
    background: rgba(0,0,0,0.3);
    border-color: rgba(255,255,255,0.2);
}

.close-modal:hover, .popup-close-btn:hover {
    background: rgba(255,255,255,0.9);
    color: #000;
    transform: rotate(90deg);
}

/* --- New Contact Page Styles (Refactored) --- */

/* Reach Out Section (Cards) */
.reach-out-section {
    padding: 60px 0;
    background-color: #fff;
    text-align: center;
}

.reach-out-label {
    display: inline-block;
    padding: 6px 14px;
    border: 1px solid #e5e7eb;
    border-radius: 9999px;
    font-size: 0.8rem;
    color: #4b5563;
    margin-bottom: 1rem;
    font-weight: 500;
}

.reach-out-header {
    margin-bottom: 3rem;
}

.reach-out-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1rem;
}

.reach-out-header p {
    color: #4b5563;
    font-size: 1rem;
}

.reach-out-grid {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 2rem;
    margin-top: 3rem;
}

@media (min-width: 768px) {
    .reach-out-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.reach-out-card {
    display: flex;
    flex-direction: column;
    align-items: center; /* Center content like reference.txt */
    text-align: center; /* Center text */
    padding: 20px;
}

/* Reference has text-left, but centered grid usually looks better centered. 
   Let's stick to the visual flow of the provided snippet which has items-center */

.reach-out-icon-wrapper {
    width: 48px;
    height: 48px;
    background-color: rgba(191, 37, 58, 0.1);
    color: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

.reach-out-icon-wrapper svg {
    width: 24px;
    height: 24px;
}

.reach-out-card h3 {
    font-size: 1.125rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.5rem;
}

.reach-out-card p {
    color: #6b7280;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

.reach-out-link {
    color: var(--primary-color);
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s;
}

.reach-out-link:hover {
    color: var(--secondary-color);
}

/* Contact Form Section (Split Layout) */
.contact-split-section {
    padding: 80px 0;
    padding-top: 100px; /* Added gap at top inside section */
    background-color: #f9fafb; /* Light gray bg */
}

.contact-split-container {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

@media (min-width: 1024px) {
    .contact-split-container {
        flex-direction: row;
        justify-content: space-between;
        gap: 4rem;
    }
}

.contact-info-col {
    flex: 1;
    max-width: 100%;
}

@media (min-width: 1024px) {
    .contact-info-col {
        max-width: 450px;
    }
}

.contact-info-header h3 {
    color: var(--primary-color);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.contact-info-header h2 {
    font-size: 2.25rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.contact-info-desc {
    color: #4b5563;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.contact-methods-list {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.contact-method-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.contact-method-icon {
    color: #9ca3af; /* gray-400 */
    flex-shrink: 0;
}

.contact-method-icon svg {
    width: 24px;
    height: 24px;
}

.contact-method-text {
    color: #1f2937;
    font-weight: 500;
}

.contact-form-col {
    flex: 1;
    background: #fff;
    padding: 2rem;
    border-radius: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    border: 1px solid #e5e7eb;
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-label {
    display: block;
    font-weight: 500;
    color: #374151;
    margin-bottom: 0.5rem;
}

.form-input, .form-textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    border: 1px solid #d1d5db;
    background-color: transparent;
    color: #374151;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    font-family: inherit;
}

.form-input:focus, .form-textarea:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(191, 37, 58, 0.1);
}

.form-textarea {
    resize: vertical;
    min-height: 120px;
}

.checkbox-group {
    margin-bottom: 1.5rem;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.9rem;
    color: #4b5563;
}

.form-checkbox {
    margin-top: 0.25rem; /* Align with first line of text */
    accent-color: var(--primary-color);
    width: 16px;
    height: 16px;
}

.checkbox-text a {
    color: var(--primary-color);
    text-decoration: underline;
}

.checkbox-text a:hover {
    color: var(--secondary-color);
}

.form-submit-btn {
    width: 100%;
    padding: 0.75rem 1.5rem;
    background-color: var(--primary-color);
    color: #fff;
    font-weight: 600;
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: background-color 0.2s;
}

.form-submit-btn:hover {
    background-color: var(--secondary-color);
}

.form-submit-btn:active {
    background-color: var(--primary-color);
}


/* --- Recreated Perfect Service Cards & Popup (Final V2) --- */

/* 1. Global Reset for Modals/Cards */
body:has(.service-card-small:hover) #blur-overlay {
    display: none !important;
}

/* 2. Unified Modal / Popup Container */
.modal-container, .popup-content {
    background: #ffffff !important;
    width: 90% !important;
    max-width: 900px !important;
    max-height: 85vh !important;
    margin: 5vh auto !important;
    padding: 40px !important;
    border-radius: 12px !important;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3) !important;
    position: relative;
    overflow-y: auto;
    color: #333333 !important;
    transform: scale(0.95);
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.active .modal-container, 
.popup-overlay.active .popup-content {
    transform: scale(1);
}

/* Slim Scrollbar for Modal */
.modal-container::-webkit-scrollbar, 
.popup-content::-webkit-scrollbar {
    width: 6px;
}
.modal-container::-webkit-scrollbar-track, 
.popup-content::-webkit-scrollbar-track {
    background: transparent;
}
.modal-container::-webkit-scrollbar-thumb, 
.popup-content::-webkit-scrollbar-thumb {
    background-color: #d1d5db;
    border-radius: 3px;
}
.modal-container::-webkit-scrollbar-thumb:hover, 
.popup-content::-webkit-scrollbar-thumb:hover {
    background-color: #9ca3af;
}

/* Modal Close Button */
.close-modal, .popup-close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 36px;
    height: 36px;
    background: rgba(0, 0, 0, 0.05) !important;
    border-radius: 50%;
    border: none;
    color: #555 !important;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 50;
}
.close-modal:hover, .popup-close-btn:hover {
    background: var(--primary-color) !important;
    color: #ffffff !important;
    transform: rotate(90deg);
}

/* Modal Typography */
.career-popup-meta {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 15px;
    margin-bottom: 20px;
}

.career-popup-meta span {
    display: block;
    font-size: 0.95rem;
    color: #555;
}

.modal-body h3, #modal-title, .popup-title {
    font-size: 2rem;
    font-weight: 700;
    color: #111827 !important; /* Almost black */
    margin-bottom: 1rem;
    margin-top: 0;
    line-height: 1.2;
}
.modal-body p, #modal-description, .popup-text {
    font-size: 1.05rem;
    line-height: 1.6;
    color: #374151 !important; /* Dark gray */
    margin-bottom: 1.5rem;
}
.modal-benefits-section h4 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 1rem;
    border-bottom: 2px solid #f3f4f6;
    padding-bottom: 0.5rem;
}
#modal-benefits-list li {
    font-size: 1rem;
    color: #4b5563 !important;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}
#modal-benefits-list li::before {
    content: '✓';
    color: var(--secondary-color);
    font-weight: 800;
    flex-shrink: 0;
    margin-top: 2px;
}

/* Modal Image Handling */
.modal-image-container {
    display: none !important; /* Hide image in modal for cleaner text focus as requested by 'recreate perfectly' usually implies cleaner UI, or I can style it better. Let's keep it but make it smaller if present. */
}
/* Wait, user liked images in cards. Let's keep images in modal but style them well if they exist. */
.modal-image-container:not(.hidden) {
    display: block !important;
    width: 100%;
    height: 250px;
    margin-bottom: 1.5rem;
    border-radius: 8px;
    overflow: hidden;
}
.modal-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* 3. Service Cards (Recreated) */
.services-grid-small {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.service-card-small {
    background: #ffffff !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 12px !important;
    padding: 24px !important;
    display: flex;
    flex-direction: column;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05) !important;
    cursor: pointer;
    overflow: hidden;
    position: relative;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    height: 100%;
}

.service-card-small:hover {
    transform: translateY(-5px) !important;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04) !important;
    border-color: var(--primary-color) !important;
}

.card-image-wrapper-small {
    width: 100%;
    height: 160px;
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 20px;
    background-color: #f3f4f6;
}

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

.service-card-small:hover .card-image-wrapper-small img {
    transform: scale(1.08);
}

.service-card-small h3 {
    font-size: 1.25rem !important;
    font-weight: 700;
    color: #111827 !important;
    margin-top: auto; /* Push to bottom if content varies, or just flow */
    margin-bottom: 0;
    text-align: center;
}

/* Updated Service Cards - Aesthetic Simple Text Cards */
.services-grid-small {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    margin-top: 40px;
}

.service-card-small {
    background: #ffffff !important;
    border: 1px solid #eaeaea !important;
    border-radius: 16px !important;
    padding: 32px 24px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    min-height: 160px !important;
    box-shadow: 0 4px 6px rgba(0,0,0,0.02) !important;
    transition: all 0.4s cubic-bezier(0.2, 0.8, 0.2, 1) !important;
    cursor: pointer !important;
    text-align: center !important;
    position: relative !important;
    overflow: hidden !important;
    height: auto !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

.service-card-small:hover {
    transform: translateY(-5px) !important;
    box-shadow: 0 12px 24px rgba(0,0,0,0.08) !important;
    border-color: var(--primary-color) !important;
    background: #fff !important;
}

.service-card-small h3 {
    font-size: 1.15rem !important;
    font-weight: 600 !important;
    color: #333 !important;
    margin: 0 !important;
    line-height: 1.4 !important;
    letter-spacing: -0.01em !important;
    transition: color 0.3s ease !important;
}

.service-card-small:hover h3 {
    color: var(--primary-color) !important;
}

/* --- New Services Layout System --- */
.layout-toggle-container {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
}

.layout-toggle-btn {
    background: #fff;
    border: 1px solid #eaeaea;
    border-radius: 12px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #888;
    transition: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
    box-shadow: 0 2px 5px rgba(0,0,0,0.03);
}

.layout-toggle-btn:hover {
    background: #f9f9f9;
    color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
}

.layout-toggle-btn.active {
    background: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
    box-shadow: 0 8px 20px rgba(191, 37, 58, 0.25);
}

.services-stack-wrapper {
    width: 100%;
    transition: height 0.5s ease;
}

.service-card-stack {
    background: #fff;
    border-radius: 20px;
    border: 1px solid #eaeaea;
    padding: 30px;
    transition: transform 0.4s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.4s ease, box-shadow 0.4s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    background: linear-gradient(145deg, #ffffff 0%, #fcfcfc 100%);
    will-change: transform, opacity;
}

.service-card-stack:hover {
    border-color: rgba(191, 37, 58, 0.3);
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
    transform: translateY(-5px);
}

.card-icon-placeholder {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: rgba(191, 37, 58, 0.05);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    transition: all 0.3s ease;
}

.service-card-stack:hover .card-icon-placeholder {
    background: var(--primary-color);
    color: #fff;
    transform: scale(1.1) rotate(-5deg);
}

.card-content h3 {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-color);
}

.stack-desc {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.6;
    margin: 0 0 8px 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Layout: Stack (Morphing Swipable Stack) */
.services-stack-wrapper {
    position: relative;
    width: 100%;
    min-height: 400px; /* Space for the stack */
    display: flex;
    justify-content: center;
    perspective: 1000px;
    margin-top: 2rem;
}

.services-stack-wrapper.layout-stack {
    display: block; /* Override flex from potential previous styles */
}

.services-stack-wrapper.layout-stack .service-card-stack {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%); /* Start centered */
    width: 320px;
    height: auto;
    min-height: 300px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    border: 1px solid rgba(0,0,0,0.05);
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    transition: transform 0.3s cubic-bezier(0.4, 0.0, 0.2, 1), opacity 0.3s ease, box-shadow 0.3s ease;
    transform-origin: center center;
    will-change: transform;
    cursor: grab;
    user-select: none;
    z-index: 1; /* Default z-index */
}

.services-stack-wrapper.layout-stack .service-card-stack:active {
    cursor: grabbing;
}

.services-stack-wrapper.layout-stack .card-icon-placeholder {
    width: 48px;
    height: 48px;
    background: #f8f9fa;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    margin-bottom: 0;
    flex-shrink: 0;
}

.services-stack-wrapper.layout-stack .card-content {
    width: 100%;
}

.services-stack-wrapper.layout-stack h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: #1a1a1a;
}

.services-stack-wrapper.layout-stack p.stack-desc {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.5;
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Button View Details */
.btn-view-details {
    display: inline-block;
    padding: 8px 16px;
    background-color: transparent;
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 8px;
}

.btn-view-details:hover {
    background-color: var(--primary-color);
    color: #fff;
}

/* Layout: Grid */
.services-stack-wrapper.layout-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 30px;
    padding-bottom: 2rem;
}

.services-stack-wrapper.layout-grid .service-card-stack {
    position: relative !important;
    top: auto !important;
    left: auto !important;
    transform: none !important;
    width: 100% !important;
    opacity: 1 !important;
    display: flex;
    flex-direction: column;
    height: 100%;
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
    border: 1px solid rgba(0,0,0,0.05);
}

.services-stack-wrapper.layout-grid .card-icon-placeholder {
    width: 50px;
    height: 50px;
    margin-bottom: 15px;
    background: #f4f4f4;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Fix for icon color mixing in Grid view on hover */
.services-stack-wrapper.layout-grid .service-card-stack:hover .card-icon-placeholder {
    background: rgba(191, 37, 58, 0.1) !important;
    color: var(--primary-color) !important;
}

/* Mobile Responsiveness for Layouts */
@media (max-width: 768px) {
    .services-stack-wrapper.layout-stack .service-card-stack {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    /* Mobile Grid 2 Columns */
    .services-stack-wrapper.layout-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .services-stack-wrapper.layout-grid .service-card-stack {
        padding: 12px;
        border-radius: 12px;
    }

    .services-stack-wrapper.layout-grid .card-icon-placeholder {
        width: 32px;
        height: 32px;
        margin-bottom: 8px;
        border-radius: 8px;
    }
    
    .services-stack-wrapper.layout-grid .card-icon-placeholder svg {
        width: 16px;
        height: 16px;
    }

    .services-stack-wrapper.layout-grid h3 {
        font-size: 0.7rem;
        margin-bottom: 3px;
        line-height: 1.2;
    }
    
    .services-stack-wrapper.layout-grid .stack-desc {
        font-size: 0.6rem;
        line-height: 1.2;
        margin-bottom: 5px;
        -webkit-line-clamp: 3;
        line-clamp: 3;
    }
    
    .services-stack-wrapper.layout-grid .btn-view-details {
        font-size: 0.6rem;
        padding: 3px 6px;
        margin-top: 3px;
        width: 100%;
        text-align: center;
    }
}

/* Moved from inline style in contact.html */
.gooey-text-wrapper {
    filter: url(#gooey-threshold);
}

/* Mobile View Optimizations for Services Page */
@media (max-width: 768px) {
    /* Our Methodology Section - 2x2 Grid */
    .services-page .process-steps,
    .how-it-works-section .process-steps {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    /* Why Partner With IT KeySource Section - 2x2 Grid */
    .services-page .features-grid,
    .why-choose-us-section .features-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }

    /* Staggered Animation for Mobile Grid Items */
    .process-steps .step-card,
    .features-grid .feature-item {
        opacity: 0;
        transform: translateY(20px);
    }

    .process-steps.active .step-card,
    .features-grid.active .feature-item {
        animation: staggeredFadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
    }

    /* Increased delay as requested (0.3s steps) */
    .process-steps.active .step-card:nth-child(1),
    .features-grid.active .feature-item:nth-child(1) { animation-delay: 0.3s; }
    
    .process-steps.active .step-card:nth-child(2),
    .features-grid.active .feature-item:nth-child(2) { animation-delay: 0.6s; }
    
    .process-steps.active .step-card:nth-child(3),
    .features-grid.active .feature-item:nth-child(3) { animation-delay: 0.9s; }
    
    .process-steps.active .step-card:nth-child(4),
    .features-grid.active .feature-item:nth-child(4) { animation-delay: 1.2s; }

    /* Reduce card size and text for mobile grid */
    .step-card, .feature-item {
        padding: 15px; /* Reduced from 30px */
    }
    
    .step-card {
        min-height: 180px; /* Reduced height for mobile 2x2 grid */
    }
    
    .step-card h3, .feature-item h3 {
        font-size: 1rem !important; /* Force smaller title */
        margin-top: 10px;
        margin-bottom: 8px;
    }
    
    .step-card p, .feature-item p {
        font-size: 0.8rem !important; /* Force smaller text */
        line-height: 1.3;
    }
}

/* Web Interface Optimization (min-width: 1025px) */
@media (min-width: 1025px) {
    /* "Why Partner With IT KeySource?" Section */
    .about-why-us .btn-card-cta {
        display: none;
    }
    
    .about-why-us .about-card {
        min-height: auto;
        height: auto;
        padding-bottom: 30px; /* Reduce height visual */
    }

    /* "Who We Are" Section */
    .about-who-we-are .about-card {
        min-height: auto;
        height: auto;
        padding-bottom: 30px;
    }

    /* Staggered Animation for Clients & Partners */
    .clients-grid-clean .client-logo-box {
        opacity: 0;
        transform: translateY(30px);
    }

    .clients-grid-clean.active .client-logo-box {
        animation: staggeredFadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
    }

    .clients-grid-clean.active .client-logo-box:nth-child(1) { animation-delay: 0.1s; }
    .clients-grid-clean.active .client-logo-box:nth-child(2) { animation-delay: 0.2s; }
    .clients-grid-clean.active .client-logo-box:nth-child(3) { animation-delay: 0.3s; }
    .clients-grid-clean.active .client-logo-box:nth-child(4) { animation-delay: 0.4s; }
    .clients-grid-clean.active .client-logo-box:nth-child(5) { animation-delay: 0.5s; }
    .clients-grid-clean.active .client-logo-box:nth-child(6) { animation-delay: 0.6s; }
    .clients-grid-clean.active .client-logo-box:nth-child(7) { animation-delay: 0.7s; }
    .clients-grid-clean.active .client-logo-box:nth-child(8) { animation-delay: 0.8s; }

    /* Services Hero Animation moved to global */
}

/* =========================================
   Global Hero Card Animation (Web & Mobile)
   ========================================= */
.hero-cards-grid .hero-card {
    opacity: 0;
    transform: translateY(30px);
}

.hero-cards-grid.active .hero-card {
    animation: staggeredFadeInUp 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

/* Increased delays for smoother staggered effect */
.hero-cards-grid.active .hero-card:nth-child(1) { animation-delay: 0.2s; }
.hero-cards-grid.active .hero-card:nth-child(2) { animation-delay: 0.4s; }
.hero-cards-grid.active .hero-card:nth-child(3) { animation-delay: 0.6s; }
.hero-cards-grid.active .hero-card:nth-child(4) { animation-delay: 0.8s; }
.hero-cards-grid.active .hero-card:nth-child(5) { animation-delay: 1.0s; }
.hero-cards-grid.active .hero-card:nth-child(6) { animation-delay: 1.2s; }


/* =========================================
   Mobile Animation Overrides (Max-width: 768px)
   Target: Our Core Expertise, Comprehensive IT Services, Our Success Stories
   ========================================= */
@media (max-width: 768px) {
    
    /* Global override for entrance animations in these sections */
    .featured-services-section .reveal,
    .services-overview-section .reveal,
    .portfolio-section .reveal {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }

    /* 1. Our Core Expertise (.featured-services-section) */
    .featured-services-section .service-card,
    .featured-services-section .service-card:hover,
    .featured-services-section .service-card.hover-smooth,
    .featured-services-section .service-card.hover-smooth:hover {
        transform: none !important;
        transition: none !important;
        box-shadow: var(--shadow-soft) !important; /* Keep base shadow, remove hover shadow */
    }

    /* 2. Comprehensive IT Services (.services-overview-section) */
    .services-overview-section .marquee-track {
        /* Restore animation for mobile auto-scrolling */
        animation: marquee-scroll 200s linear infinite !important; /* Significantly slower speed for mobile */
        width: max-content !important;
        flex-wrap: nowrap !important;
        overflow-x: hidden !important;
        transform: none; /* Allow animation transform */
        padding-bottom: 0 !important;
        will-change: transform; /* Performance optimization */
        pointer-events: none; /* Prevent interaction interfering with animation */
        user-select: none;
        -webkit-user-select: none;
    }

    /* Disable pause on hover/click for mobile to ensure constant movement */
    .services-overview-section .marquee-wrapper:hover .marquee-track,
    .services-overview-section .marquee-wrapper:active .marquee-track,
    .services-overview-section .marquee-wrapper:focus-within .marquee-track {
        animation-play-state: running !important;
    }


    
    .services-overview-section .marquee-wrapper {
        mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent) !important;
        -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent) !important;
        overflow-x: hidden !important;
        -webkit-overflow-scrolling: auto;
    }

    /* Remove hover effects on premium cards */
    .services-overview-section .service-premium-card,
    .services-overview-section .service-premium-card:hover {
        transform: translateZ(0) !important; /* Keep flat but accelerated */
        transition: none !important;
        box-shadow: 0 2px 8px rgba(0,0,0,0.04) !important; /* Reset to base shadow */
    }

    /* 3. Our Success Stories (.portfolio-section) */
    .portfolio-section .portfolio-item,
    .portfolio-section .portfolio-item:hover,
    .portfolio-section .portfolio-item.hover-raise,
    .portfolio-section .portfolio-item.hover-raise:hover {
        transform: none !important;
        transition: none !important;
        box-shadow: var(--shadow-soft) !important;
    }
    
    /* Ensure images inside don't zoom on hover if they have effects */
    .featured-services-section .service-card:hover img,
    .portfolio-section .portfolio-item:hover img {
        transform: none !important;
    }

    /* Premium Service Card Sizing for Mobile */
    .services-overview-section .service-premium-card {
        flex: 0 0 240px !important;
        height: 180px !important;
        padding: 16px !important;
    }
    .services-overview-section .service-premium-card h3 {
        font-size: 1.1rem !important;
    }
    .services-overview-section .service-premium-card p {
        font-size: 0.85rem !important;
    }
}

/* --- Updates for Mobile Footer, About Hero, Expertise, etc. --- */

/* Footer Mobile Alignment */
@media (max-width: 768px) {
    .footer-column, .footer-bottom {
        text-align: left !important;
        align-items: flex-start !important;
    }
    
    .footer-container {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 15px;
    }
}

/* Footer Button Hover Smoothness */
.social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255,255,255,0.1);
    color: #fff;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.social-icon:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

/* About Page - Hero Section Image Consistency */
.about-tab-content .tab-image-wrapper img {
    width: 100%;
    height: 400px; /* Fixed height for consistency */
    object-fit: cover;
    border-radius: var(--radius-card);
}

/* About Page - AI Strategy & Consulting Title Size */
#expertise-title {
    font-size: 2.5rem; /* Increased size */
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
}

@media (max-width: 768px) {
    #expertise-title {
        font-size: 2rem;
    }
}

/* Mobile Delayed CTA Visibility Helper */
@media (max-width: 768px) {
    .expertise-cta.mobile-hidden {
        opacity: 0;
        visibility: hidden;
        transform: translateY(10px);
        transition: opacity 0.5s ease, transform 0.5s ease;
    }
    
    .expertise-cta.mobile-visible {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }
}

/* --- Marketing Popup Styles --- */
.marketing-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 2000000000; /* High z-index but below cookie consent (2147483647) */
    display: none;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(5px);
}

.marketing-popup-overlay.active {
    display: flex;
    animation: fadeIn 0.5s ease;
}

.marketing-popup-content {
    position: relative;
    max-width: 90%;
    max-height: 90vh;
    width: auto;
    background: transparent;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.marketing-popup-overlay.active .marketing-popup-content {
    transform: scale(1);
}

.marketing-popup-image {
    display: block;
    max-width: 100%;
    max-height: 80vh;
    height: auto;
    object-fit: contain;
}

.marketing-close-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.marketing-close-btn:hover {
    background: rgba(191, 37, 58, 0.9); /* Primary color */
}

@media (max-width: 768px) {
    .marketing-popup-content {
        max-width: 95%;
    }
}

/* --- Cookie Consent Popup (Dark Theme - Compact) --- */
.cookie-consent-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9); /* Darker blocking overlay */
    z-index: 2147483647; /* Maximum z-index */
    display: none; /* Hidden by default */
    justify-content: center;
    align-items: flex-end; /* Show at bottom */
    backdrop-filter: blur(15px);
    padding: 15px;
}

.cookie-consent-overlay.active {
    display: flex;
    animation: fadeIn 0.4s ease-out;
}

.cookie-consent-popup {
    width: 100%;
    max-width: 800px;
    background: #1a1a1a; /* Dark background matching footer */
    color: #e0e0e0;
    border-radius: 12px;
    padding: 15px 20px; /* Reduced padding */
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.6);
    transform: translateY(50px);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.19, 1, 0.22, 1);
    border: 1px solid #333;
    display: flex;
    flex-direction: column;
    gap: 10px; /* Reduced gap */
}

.cookie-consent-overlay.active .cookie-consent-popup {
    transform: translateY(0);
    opacity: 1;
}

.cookie-consent-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 0;
}

.cookie-consent-title {
    font-size: 1rem; /* Smaller title */
    font-weight: 700;
    color: #fff;
    margin: 0;
    font-family: 'DM Sans', sans-serif;
}

.cookie-consent-text {
    font-size: 0.8rem; /* Smaller text */
    color: #ccc;
    line-height: 1.4;
    margin: 0;
}

.cookie-consent-text p {
    margin-bottom: 4px; /* Tighter spacing */
}

.cookie-consent-text p:last-child {
    margin-bottom: 0;
}

.cookie-link {
    color: #BF253A; /* Primary color */
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.cookie-link:hover {
    color: #EF416E; /* Secondary color */
    text-decoration: underline;
}

.cookie-consent-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 5px;
}

.btn-accept-cookies {
    background: #BF253A; /* Primary color */
    color: #fff;
    border: none;
    padding: 8px 20px; /* Smaller button */
    border-radius: 6px;
    font-size: 0.85rem; /* Smaller button text */
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(191, 37, 58, 0.3);
    font-family: 'DM Sans', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-accept-cookies:hover {
    background: #EF416E;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(191, 37, 58, 0.4);
}

.btn-accept-cookies:active {
    transform: translateY(0);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@media (max-width: 768px) {
    .cookie-consent-popup {
        padding: 15px;
        border-radius: 12px 12px 0 0;
        margin-bottom: 0;
        max-width: 100%;
    }
    .cookie-consent-actions {
        width: 100%;
    }
    .btn-accept-cookies {
        width: 100%;
        text-align: center;
        padding: 10px;
    }
}

/* Allow viewing content on policy pages */
.cookie-consent-overlay.allow-view {
    background: transparent;
    pointer-events: none; /* Let clicks pass through to the page */
    backdrop-filter: none; /* Remove blur on policy pages */
}

.cookie-consent-overlay.allow-view .cookie-consent-popup {
    pointer-events: auto; /* Keep the popup interactive */
    background: rgba(26, 26, 26, 0.95); /* Ensure popup is readable */
    box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.2);
}
