/* --- Google Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Lato:wght@400;700&family=Montserrat:wght@700&family=Open+Sans:wght@400;600&family=Poppins:wght@600;700&display=swap');

/* Table of Contents
--------------------
1.  Global Styles & Variables
2.  Reusable Components (Navbar, Buttons, Preloader, Page Headers)
3.  Homepage Sections (Hero, About, Services, Stats, Features, Testimonials)
4.  Page-Specific Sections (Portfolio, Contact)
5.  Footer & Back-to-Top
6.  Responsive Media Queries
-------------------- */

/* 1. Global Styles & Variables
----------------------------------- */
:root {
    --primary-color: #0a2540; /* Navy Blue */
    --secondary-color: #ff7b00; /* Orange */
    --white-color: #ffffff;
    --light-gray-color: #f8f9fa; /* Lighter gray for backgrounds */
    --dark-gray-color: #333;
    --text-color: #495057;
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Open Sans', sans-serif;
    --font-special: 'Poppins', sans-serif;
    --font-accent: 'Lato', sans-serif;
    --transition: all 0.3s ease-in-out;
    --navbar-height: 70px;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    line-height: 1.6;
    color: var(--text-color);
    background-color: #f8fafc; /* Set a clean, near-white base for the whole site */
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 2rem;
}

h1, h2, h3 {
    font-family: var(--font-heading);
    color: var(--primary-color); /* Titles default to primary color */
}

a {
    text-decoration: none;
    color: var(--secondary-color);
}

/* 2. Reusable Components
----------------------------------- */

/* Splash Screen / Preloader */
.splash-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--primary-color);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.8s ease-out, visibility 0.8s ease-out;
    visibility: visible;
    opacity: 1;
}

.splash-screen.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.splash-content {
    text-align: center;
    color: var(--white-color);
}

.splash-img {
    width: 80px;
    height: auto;
    margin: 0 auto 1rem auto;
    display: block;
    opacity: 0;
    transform: translateY(20px);
    animation: splashFadeInUp 1s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.splash-logo {
    font-family: var(--font-heading);
    font-size: 3rem;
    color: var(--white-color);
    margin-bottom: 0.75rem;
    opacity: 0;
    transform: translateY(20px);
    /* Delay to animate after logo */
    animation: splashFadeInUp 1s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0.2s forwards;
}

.splash-tagline {
    font-family: var(--font-body);
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.8);
    opacity: 0;
    /* Delay to animate after heading */
    animation: splashFadeIn 1s ease-in 0.6s forwards;
}

@keyframes splashFadeInUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes splashFadeIn { from { opacity: 0; } to { opacity: 1; } }

/* Keyframes for slide-in animation */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Keyframes for hero image float animation */
@keyframes floatLeftRight {
    0% {
        transform: translateX(0px);
    }
    50% {
        transform: translateX(-15px);
    }
    100% {
        transform: translateX(0px);
    }
}

/* Navbar */
.navbar {
    background-color: var(--white-color);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    transition: background-color 0.4s ease, box-shadow 0.4s ease;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: var(--navbar-height);
    transition: height 0.4s ease;
}

.nav-logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--primary-color);
    font-weight: 700;
    transition: font-size 0.4s ease;
}

.nav-menu {
    display: flex;
    list-style: none;
}

.nav-item {
    margin-left: 1.5rem;
}

.nav-link {
    color: var(--text-color);
    font-weight: 600;
    transition: color 0.3s ease;
    position: relative;
    padding: 5px 0; /* Add some padding for the underline effect */
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--secondary-color);
    transition: width 0.3s ease-in-out;
}

.nav-link:hover {
    color: var(--secondary-color);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link.active {
    color: var(--secondary-color);
}

.navbar.scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px); /* For Safari support */
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.navbar.scrolled .container {
    height: 65px;
}

.navbar.scrolled .nav-logo {
    font-size: 1.3rem;
}

.hamburger {
    display: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    transition: all 0.3s ease-in-out;
    background-color: var(--primary-color);
}

/* CTA Button */
.cta-button {
    display: inline-block;
    background-color: var(--secondary-color);
    color: var(--white-color);
    padding: 12px 24px;
    border-radius: 5px;
    font-weight: 600;
    transition: background-color 0.3s ease, transform 0.3s ease;
    border: none;
    cursor: pointer;
}

.cta-button:hover {
    background-color: #e66a00;
    transform: translateY(-3px);
}

/* Page Header (for sub-pages) */
.page-header {
    padding: 4rem 0;
    background-color: var(--light-gray-color);
    text-align: center;
    padding-top: calc(var(--navbar-height) + 4rem);
    position: relative; /* For containing transformed children */
    overflow: hidden; /* Add this to contain the parallax element */
}

.page-header h1 {
    font-size: 2.8rem;
    margin-bottom: 0.5rem;
    /* A subtle gradient to make the title pop on all sub-pages */
    background: linear-gradient(45deg, var(--secondary-color), #e66a00);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    /* Fallback for browsers that don't support text clipping */
    color: var(--secondary-color);
}

.page-header p {
    font-size: 1.2rem;
    color: var(--text-color);
    max-width: 600px;
    margin: 0 auto;
}

/* 3. Homepage Sections
----------------------------------- */
/* About Section (Homepage) */
.about-home-section {
    padding: 4rem 0;
}

.about-home-layout {
    display: grid;
    grid-template-columns: 1fr 1.2fr; /* Adjusted ratio */
    align-items: center;
    gap: 3rem;
}

.about-home-layout {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.about-home-layout.visible {
    opacity: 1;
    transform: translateY(0);
}

.about-home-image img {
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    width: 100%;
}

.about-home-content .section-title {
    text-align: left;
    margin-bottom: 1rem;
}

.about-home-content > p {
    color: var(--text-color); /* Already correct, but good to confirm */
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    max-width: 600px;
}

.about-highlights {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0;
}

.about-highlights li {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1rem;
    font-size: 1rem;
    color: var(--dark-gray-color);
}

.highlight-icon {
    font-size: 1.2rem;
    margin-right: 0.75rem;
    color: var(--secondary-color);
    line-height: 1.6;
}

.about-home-content .cta-button {
    margin-top: 1rem;
}

/* Services Section */
.services-section {
    padding: 4rem 0;
    background-color: var(--light-gray-color);
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 2.5rem;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.service-card {
    background: var(--white-color);
    padding: 1.5rem;
    border-radius: 24px; /* Squircle design */
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    text-align: center;
    transition: transform 0.4s ease, box-shadow 0.4s ease, filter 0.4s ease;
    opacity: 0;
    transform: translateY(30px);
}

.service-card.visible {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out, filter 0.4s ease;
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 25px rgba(0,0,0,0.15);
    filter: drop-shadow(0 0 15px rgba(0, 170, 255, 0.6));
}

.service-icon-home {
    font-size: 3rem;
    display: inline-flex; /* Changed for better centering */
    justify-content: center; /* Center icon horizontally */
    align-items: center; /* Center icon vertically */
    margin-bottom: 1.5rem;
    transition: transform 0.4s ease;
    width: 60px; /* Give a consistent size */
    height: 60px; /* Give a consistent size */
}

.service-icon-home img {
    height: 3rem; /* Match the font-size of other icons */
    width: auto;  /* Maintain aspect ratio */
}

.service-card:hover .service-icon-home {
    transform: scale(1.1) rotate(5deg);
}

/* Colorful Service Icons */
.services-grid .service-card:nth-child(1) .service-icon-home { color: #4A90E2; } /* Web Development - Blue */
.services-grid .service-card:nth-child(2) .service-icon-home { color: #9013FE; } /* App Development - Deep Purple */
.services-grid .service-card:nth-child(3) .service-icon-home { color: #50E3C2; } /* Social Media - Teal */
.services-grid .service-card:nth-child(4) .service-icon-home { color: #FF3B30; } /* Video Editing - Red */
.services-grid .service-card:nth-child(5) .service-icon-home { color: #F5A623; } /* Graphic Design - Orange */
.services-grid .service-card:nth-child(6) .service-icon-home { color: #E94E77; } /* GST & ITR - Pink */
.services-grid .service-card:nth-child(7) .service-icon-home { color: #7ED321; } /* Product Listing - Green */
.services-grid .service-card:nth-child(8) .service-icon-home { color: #25D366; } /* WhatsApp - WhatsApp Green */
.services-grid .service-card:nth-child(9) .service-icon-home { color: #BD10E0; } /* ERP - Magenta */

.service-card h3 {
    margin-bottom: 1rem;
}

.learn-more {
    font-weight: 600;
    color: var(--secondary-color);
    opacity: 0.8;
    transition: opacity 0.3s ease;
    font-size: 0.9rem;
}

.service-card:hover .learn-more {
    opacity: 1;
}

.services-section.services-compact {
    padding-top: 0;
}

.services-compact .services-grid {
    grid-template-columns: repeat(3, 1fr);
}

/* Stats Section */
.stats-section {
    padding: 4rem 0;
    background-color: var(--primary-color);
}

.stats-section .section-title {
    color: var(--white-color);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
}

.stat-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1.5rem;
    text-align: center;
    border-radius: 24px;
    aspect-ratio: 1 / 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: background-color 0.3s ease, transform 0.6s ease-out, opacity 0.6s ease-out;
    opacity: 0;
    transform: translateY(30px);
}

.stat-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.stat-card:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-5px);
}

.stat-card h3 {
    font-size: 4rem;
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.stat-card p {
    font-size: 1.1rem;
    color: var(--white-color);
    font-weight: 600;
}

/* Team Section */
.team-section {
    padding: 4rem 0;
    background-color: var(--light-gray-color);
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    justify-items: center;
}

.team-member {
    text-align: center;
    /* Animation properties for scroll effect */
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.team-member.visible {
    opacity: 1;
    transform: translateY(0);
}

.team-member img {
    width: 130px;
    height: 130px;
    border-radius: 30px;
    object-fit: cover;
    margin-bottom: 1rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    border: 3px solid transparent;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.team-member:hover img {
    transform: scale(1.05);
    box-shadow: 0 8px 25px rgba(255, 123, 0, 0.25);
    border-color: var(--secondary-color);
}

.team-member h4 {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin-bottom: 0.25rem;
}

.team-member p {
    color: #777;
}

.team-socials {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 0.75rem;
}

.team-socials a {
    color: var(--dark-gray-color);
    font-size: 1rem;
    transition: color 0.3s ease, transform 0.3s ease;
}

.team-socials a:hover {
    color: var(--secondary-color);
    transform: translateY(-2px);
}

/* Homepage Hero Section */
.ecommerce-hero {
    background-color: #b2ebf2; /* A deeper, more saturated cyan */
    padding: 60px 0;
    width: 100%;
    overflow: hidden;
    min-height: 100vh; /* Use min-height for better flexibility */
    display: flex;
    padding-top: var(--navbar-height);
    align-items: center;
}

.e-hero-layout {
    display: flex;
    align-items: center;
    gap: 4rem;
}

.e-hero-content {
    flex: 1;
}

.e-hero-content h1 {
    font-family: var(--font-accent);
    font-weight: 700;
    color: var(--primary-color);
    font-size: 48px;
    line-height: 1.3;
    margin-bottom: 1.5rem;
}

.e-hero-content p {
    font-family: var(--font-accent);
    font-size: 20px;
    color: var(--text-color);
    line-height: 1.7;
    margin-bottom: 2rem;
    max-width: 600px; /* Constrain line length for readability */
}

.e-hero-stats {
    display: flex;
    gap: 2rem;
    margin-bottom: 2.5rem;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-color);
}

.stat-icon {
    font-size: 1.2rem;
    color: var(--primary-color);
}

.stat-item strong {
    font-weight: 700;
}

.e-hero-cta {
    display: inline-block;
    background-color: var(--primary-color);
    color: #ffffff;
    padding: 14px 28px; /* Slightly larger button */
    border-radius: 8px;
    font-family: var(--font-accent);
    font-weight: 700;
    text-decoration: none;
    transition: transform 0.3s ease, background-color 0.3s ease, box-shadow 0.3s ease;
}

.e-hero-cta:hover {
    background-color: var(--secondary-color);
    transform: scale(1.05);
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.2);
}

.e-hero-image {
    flex: 1;
    text-align: center;
}

.e-hero-image img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.1);
    opacity: 0; /* Start hidden, animation will make it visible */
}

.e-hero-image.visible img {
    /* Chain two animations: one for slide-in, one for floating. */
    animation: slideIn 0.8s ease-out forwards, 
               floatLeftRight 4s ease-in-out infinite 0.8s;
}

/* Homepage Features Section */
.features-section {
    background-color: var(--light-gray-color); /* Add a subtle background color */
    padding: 4rem 0; /* Standardized padding */
}

.features-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 2.5rem auto;
}

.features-header h2 {
    font-family: var(--font-special);
    font-size: 36px;
    color: var(--primary-color);
    margin-bottom: 1rem;
    position: relative;
    padding-bottom: 0.75rem;
}

.features-header h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--secondary-color);
}

.features-header p {
    font-family: var(--font-special);
    font-size: 18px;
    color: var(--text-color);
    line-height: 1.6;
}

.feature-pills {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 3rem;
}

.pill-btn {
    font-family: var(--font-special);
    background-color: #f1f5f9;
    color: var(--primary-color);
    border: 2px solid transparent;
    border-radius: 50px;
    padding: 10px 20px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease; /* Transition all properties */
}

.pill-btn:hover {
    background-color: #e2e8f0;
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.pill-btn.active {
    background-color: var(--secondary-color);
    color: var(--white-color);
    font-weight: 700;
    box-shadow: 0 5px 15px rgba(255, 123, 0, 0.4); /* Add a glow effect */
    transform: translateY(-3px);
}

.features-content-wrapper {
    position: relative;
    margin-top: 0;
    min-height: 400px; /* Adjusted min-height */
}

.features-content-layout {
    display: none; /* Hide all content blocks by default */
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 4rem;
    animation: contentFadeIn 0.6s ease-out forwards;
}

.features-content-layout.active {
    display: grid; /* Show only the active content block */
}

@keyframes contentFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.features-text-content h3 {
    font-family: var(--font-special);
    font-size: 28px;
    color: var(--primary-color);
    line-height: 1.3;
    margin-bottom: 1.5rem;
}

.features-text-content p {
    font-family: var(--font-special);
    font-size: 16px;
    color: var(--text-color);
    line-height: 1.6;
    margin-bottom: 2rem;
}

.cta-button-features {
    display: inline-block;
    background-color: var(--primary-color);
    color: #ffffff;
    padding: 14px 28px;
    border-radius: 8px;
    font-family: var(--font-special);
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.cta-button-features:hover {
    background-color: var(--secondary-color);
    transform: scale(1.05);
}

.features-image-content img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 15px 30px rgba(10, 37, 64, 0.15); /* Add depth to images */
}

/* Homepage Testimonials Section */
.testimonials-section {
    padding: 64px 0; /* 4rem */
    background: linear-gradient(135deg, var(--primary-color) 0%, #1d3c5e 100%);
    position: relative;
    overflow: hidden;
}

.testimonials-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px auto; /* Adjusted bottom margin */
}

.testimonials-header h2 {
    font-family: var(--font-special);
    font-size: 36px;
    color: var(--white-color);
    margin-bottom: 1rem;
    position: relative;
    padding-bottom: 0.75rem;
}

.testimonials-header h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: var(--secondary-color);
}

.testimonials-header p {
    font-family: var(--font-special);
    font-size: 18px;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
}

.testimonial-slider {
    text-align: center;
    margin-bottom: 5rem; /* Adjusted margin to move logos down */
    overflow: hidden;
    position: relative;
    min-height: 200px; /* Increased height for new card design */
}

.testimonial-slide {
    position: absolute;
    width: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.testimonial-slide.active {
    opacity: 1;
}

.testimonial-slide blockquote {
    font-family: var(--font-special);
    font-size: 20px;
    font-style: italic;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.9);
    max-width: 700px;
    margin: 0 auto 1.5rem auto;
    border: none;
    background: rgba(255, 255, 255, 0.05);
    padding: 2rem 2.5rem;
    border-radius: 12px;
    position: relative;
    border-left: 4px solid var(--secondary-color);
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

.testimonial-slide blockquote::before {
    content: '“';
    font-family: 'Georgia', serif;
    font-size: 6rem;
    color: rgba(255, 123, 0, 0.15);
    position: absolute;
    top: 0.5rem;
    left: 1rem;
    line-height: 1;
    z-index: 0;
}

.testimonial-slide cite {
    font-family: var(--font-special);
    font-weight: 700;
    color: var(--secondary-color);
    font-style: normal;
    display: block;
    font-size: 1.1rem;
}

.client-logos {
    width: 100%;
    overflow: hidden;
    padding: 2rem 0;
    position: relative;
    -webkit-mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
    mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
}

.logos-track {
    display: flex;
    /* Adjust width: (avg logo width + margin) * (number of logos * 2) */
    /* (110px + 80px) * 16 logos = 3040px */
    width: calc(190px * 16);
    animation: scroll 30s linear infinite;
}

@keyframes scroll {
    from { transform: translateX(0); }
    /* Adjust to: -(avg logo width + margin) * (number of original logos) */
    /* -190px * 8 logos = -1520px */
    to { transform: translateX(calc(-190px * 8)); }
}

.logos-track:hover {
    animation-play-state: paused;
}

.logos-track img {
    height: 110px;
    width: auto;
    margin: 0 40px;
    opacity: 0.6;
    filter: grayscale(100%) brightness(1.5);
    transition: opacity 0.3s ease, filter 0.3s ease;
}

.logos-track img:hover {
    opacity: 1;
    filter: grayscale(0%) brightness(1);
}

/* Reusable CTA Section */
.cta-section {
    padding: 4rem 0;
    background: var(--primary-color);
    color: var(--white-color);
    text-align: center;
}

.cta-section h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--secondary-color);
}

.cta-section p {
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto 2rem auto;
    opacity: 0.9;
}

.cta-section .cta-button {
    background-color: var(--secondary-color);
    color: var(--white-color);
    font-weight: 700;
    padding: 15px 35px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    transition: var(--transition);
}

.cta-section .cta-button:hover {
    background-color: #e66a00; /* Darker orange */
    transform: translateY(-3px);
}

/* 4. Page-Specific Sections
----------------------------------- */
/* Services Page */
.services-page-section {
    padding: 1rem 0 4rem;
}

.section-header {
    text-align: center;
    margin-bottom: 2.5rem;
}
.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}
.section-header p {
    font-size: 1.1rem;
    max-width: 700px;
    margin: 0 auto;
}

/* Flip-card animation for Services Page */
.services-page-section .service-card.clickable-flip {
    /* Override existing styles to prepare for flip */
    padding: 0;
    background: transparent;
    box-shadow: none;
    cursor: pointer;
    height: 300px; /* Give it a fixed height */
    opacity: 1; /* Override scroll animation opacity */
    transform: none; /* Override scroll animation transform */
    transition: transform 0.4s ease, filter 0.4s ease; /* Re-enable transitions for hover */
    perspective: 1000px;
}

/* Style for the non-flipping, clickable card */
#web-dev-service-card {
    cursor: pointer;
}

.services-page-section .service-card.clickable-flip:hover {
    transform: translateY(-8px); /* Restore lift effect */
    filter: drop-shadow(0 0 15px rgba(0, 170, 255, 0.6)); /* Restore glow effect */
}

.service-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.7s, box-shadow 0.4s ease; /* Add shadow transition */
    transform-style: preserve-3d;
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
    border-radius: 24px; /* Match original squircle */
}

.services-page-section .service-card.clickable-flip:hover .service-card-inner {
    box-shadow: 0 12px 25px rgba(0,0,0,0.15); /* Add hover shadow to inner card */
}

.services-page-section .service-card.clickable-flip.is-flipped .service-card-inner {
    transform: rotateY(180deg);
    box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}

.service-card-front,
.service-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 24px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.service-card-front {
    background-color: var(--white-color);
}

.service-card-back {
    background: var(--primary-color);
    color: var(--white-color);
    transform: rotateY(180deg);
}

.service-card-back h3,
.service-card-back p {
    color: var(--white-color);
}

.service-card-back .card-back-cta {
    margin-top: 1.5rem;
    background-color: var(--secondary-color);
    font-size: 0.9rem;
    padding: 10px 20px;
}

.service-card-back .card-back-cta:hover {
    background-color: #e66a00;
    transform: translateY(-2px);
}

/* Ensure original service-card icons/text are not affected on other pages */
.services-page-section .service-card h3 {
    margin-bottom: 1rem;
}

.services-page-section .service-card p {
    font-size: 1rem; /* Adjust font size for better fit */
    line-height: 1.5;
}

.services-page-section .service-card .service-icon-home {
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.services-page-section .service-card:hover .service-icon-home {
    transform: scale(1.1) rotate(5deg); /* Restore icon hover effect */
}

/* Service Popup Modal */
.service-popup {
    display: none; /* Hidden by default */
    position: fixed;
    z-index: 3000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(10, 37, 64, 0.9);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    justify-content: center;
    align-items: center;
}

.service-popup.active {
    display: flex;
    animation: lightboxFadeIn 0.4s ease;
}

.service-popup-content {
    background-color: var(--white-color);
    color: var(--text-color);
    padding: 2.5rem 3rem;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    width: 90%;
    max-width: 600px;
    position: relative;
    text-align: center;
    animation: lightboxZoomIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.service-popup-close {
    position: absolute;
    top: 15px;
    right: 20px;
    color: #aaa;
    font-size: 30px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.service-popup-close:hover {
    color: var(--primary-color);
}

.service-popup-content h2 {
    font-size: 2rem;
    margin-bottom: 2rem;
    color: var(--primary-color);
}

.service-popup-content ul {
    list-style: none;
    padding: 0;
    margin-bottom: 2.5rem;
    text-align: left;
}

.service-popup-content ul li {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

.service-popup-content ul li i {
    color: var(--secondary-color);
    margin-right: 1rem;
    font-size: 1.2rem;
}

.service-popup-content .cta-button {
    background-color: var(--secondary-color);
}

/* Portfolio Page */
.portfolio-section {
    padding: 2.5rem 0 4rem; /* Reduced top padding as filters are now in header */
}

.page-header .portfolio-filters {
    margin-top: 2rem;
}

.portfolio-filters {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    /* margin-bottom is removed as spacing is now handled by portfolio-section padding-top */
}

.filter-btn {
    background-color: transparent;
    border: 1px solid #ddd;
    color: var(--dark-gray-color);
    padding: 10px 20px;
    border-radius: 50px;
    cursor: pointer;
    font-family: var(--font-heading);
    font-weight: 600;
    transition: var(--transition);
}

.filter-btn:hover {
    background-color: #f1f1f1;
    border-color: #ccc;
}

.filter-btn.active {
    background-color: var(--secondary-color);
    color: var(--white-color);
    border-color: var(--secondary-color);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    display: block; /* To make the link a block container */
    text-decoration: none;
    /* Use a more fluid cubic-bezier for a smoother feel */
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.portfolio-item-hidden {
    transform: scale(0.95);
    opacity: 0;
    /* Prevent interaction with hidden items during transition */
    pointer-events: none;
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(15, 23, 42, 0.85), rgba(15, 23, 42, 0.4));
    color: var(--white-color);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 1.5rem;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-overlay h3 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    margin-bottom: 0.25rem;
    transform: translateY(15px);
    transition: transform 0.4s ease 0.1s, color 0.3s ease;
    color: var(--white-color);
}

.portfolio-overlay p {
    font-family: var(--font-body);
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 600;
    transform: translateY(15px);
    transition: transform 0.4s ease 0.15s, color 0.3s ease;
    margin: 0;
}

.portfolio-item:hover .portfolio-overlay h3,
.portfolio-item:hover .portfolio-overlay p {
    transform: translateY(0);
}

.portfolio-item:hover .portfolio-overlay h3 {
    color: var(--secondary-color);
}

.portfolio-item:hover .portfolio-overlay p {
    color: var(--white-color);
}

/* Load More Button for Portfolio */
.load-more-container {
    text-align: center;
    margin-top: 3rem;
}

#loadMoreBtn {
    border: none;
    cursor: pointer;
    display: none; /* Hidden by default, shown by JS */
}

/* Lightbox for Portfolio */
.lightbox {
    display: none; /* Hidden by default */
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(10, 37, 64, 0.95); /* Using a dark blue from the palette */
    justify-content: center;
    align-items: center;
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
}

.lightbox.active {
    display: flex; /* Use flexbox for centering */
    animation: lightboxFadeIn 0.4s ease;
}

@keyframes lightboxFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 85vh;
    text-align: center; /* Center the link below the image */
}

.lightbox-image {
    max-width: 100%;
    max-height: 85vh;
    display: block;
    margin: auto;
    border-radius: 8px;
    animation: lightboxZoomIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

@keyframes lightboxZoomIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.lightbox-visit-site {
    display: none; /* Controlled by JS */
    margin-top: 1rem;
    padding: 10px 20px;
    background-color: var(--secondary-color);
    color: var(--white-color);
    border-radius: 5px;
    font-weight: 700; /* Bold */
    text-decoration: none;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.lightbox-visit-site:hover {
    background-color: #e66a00;
    transform: translateY(-2px);
}

.lightbox-close {
    position: absolute;
    top: -40px;
    right: 0;
    color: #fff;
    font-size: 45px;
    font-weight: 300;
    transition: 0.3s;
    cursor: pointer;
    z-index: 2001;
}
.lightbox-close:hover { color: #ccc; }

.lightbox-prev,
.lightbox-next {
    cursor: pointer;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: auto;
    padding: 16px;
    color: white;
    font-weight: bold;
    font-size: 24px;
    transition: 0.3s ease;
    user-select: none;
    -webkit-user-select: none;
    background-color: rgba(0, 0, 0, 0.3);
}

.lightbox-next {
    right: -60px;
    border-radius: 5px 0 0 5px;
}

.lightbox-prev {
    left: -60px;
    border-radius: 0 5px 5px 0;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background-color: rgba(0, 0, 0, 0.6);
}

/* Contact Page - Revamped */
.contact-section {
    padding: 4rem 0;
    background-color: var(--light-gray-color);
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 3rem;
    background-color: var(--white-color);
    padding: 3rem;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.08);
    overflow: hidden;
}

.contact-info-column h2 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.contact-info-column p {
    margin-bottom: 2rem;
    line-height: 1.7;
}

.contact-details-list {
    list-style: none;
    margin-bottom: 2rem;
    padding: 0;
}

.contact-details-list li {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.5rem;
    font-size: 1rem;
}

.contact-details-list i {
    font-size: 1.2rem;
    color: var(--secondary-color);
    margin-top: 4px;
}

.contact-details-list a {
    color: var(--text-color);
    font-weight: 600;
    transition: color 0.3s ease;
}

.contact-details-list a:hover {
    color: var(--secondary-color);
}

.contact-form .form-row {
    display: flex;
    gap: 1.5rem;
    width: 100%;
}

.contact-form .form-row .form-group {
    flex: 1;
}

.contact-socials {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.contact-socials a {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 45px;
    height: 45px;
    background-color: var(--light-gray-color);
    color: var(--primary-color);
    border-radius: 50%;
    text-decoration: none;
    transition: var(--transition);
    box-shadow: 0 2px 5px rgba(0,0,0,0.08);
    font-size: 1.1rem;
}

.contact-socials a:hover {
    background-color: var(--primary-color);
    color: var(--white-color);
    transform: translateY(-3px);
    box-shadow: 0 5px 10px rgba(0,0,0,0.12);
}

.contact-form .form-group {
    margin-bottom: 1.5rem;
    text-align: left;
}

.contact-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--dark-gray-color);
    font-size: 0.9rem;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 14px;
    border: 1px solid #e2e8f0; /* Lighter border */
    border-radius: 8px; /* Softer radius */
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
    background-color: #f8fafc; /* Very light background */
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: #94a3b8;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(255, 123, 0, 0.2);
}

.contact-form .cta-button {
    width: 100%;
    border: none;
    cursor: pointer;
    margin-top: 1rem;
    padding: 15px;
    font-size: 1.1rem;
}

.whatsapp-icon:hover {
    background-color: #25D366; /* WhatsApp Green */
    color: var(--white-color);
}

.map-section {
    line-height: 0; /* Removes bottom space from iframe */
}

/* Thank You Page Animations */
.thank-you-animation-container {
    margin-bottom: 2rem;
}

.checkmark {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    display: block;
    stroke-width: 3;
    stroke: var(--white-color);
    stroke-miterlimit: 10;
    margin: 0 auto;
    box-shadow: inset 0px 0px 0px #7ac142; /* Success Green */
    animation: fill .4s ease-in-out .4s forwards, scale .3s ease-in-out .9s both;
}

.checkmark__circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 3;
    stroke-miterlimit: 10;
    stroke: #7ac142; /* Success Green */
    fill: none;
    animation: stroke 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.checkmark__check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    animation: stroke 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.8s forwards;
}

@keyframes stroke {
    100% { stroke-dashoffset: 0; }
}
@keyframes scale {
    0%, 100% { transform: none; }
    50% { transform: scale3d(1.1, 1.1, 1); }
}
@keyframes fill {
    100% { box-shadow: inset 0px 0px 0px 50px #7ac142; } /* Success Green */
}

.thank-you-heading,
.thank-you-text,
.thank-you-share,
.thank-you-button {
    opacity: 0;
    animation: fadeInUp 0.8s ease-out forwards;
}

.thank-you-heading { animation-delay: 1.2s; }
.thank-you-text { animation-delay: 1.4s; }
.thank-you-share { animation-delay: 1.6s; }
.thank-you-button { animation-delay: 1.8s; }

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Share Section on Thank You Page */
.share-section {
    margin: 4rem auto 3rem;
    max-width: 600px;
}

.share-prompt {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--dark-gray-color);
    margin-bottom: 1.5rem;
}

.share-buttons {
    display: flex;
    justify-content: center;
    gap: 1.25rem;
}

.share-btn {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    text-decoration: none;
    font-size: 1.2rem;
    color: var(--white-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: none;
    cursor: pointer;
}

.share-btn:hover {
    transform: translateY(-4px) scale(1.1);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.share-btn.facebook { background-color: #1877F2; }
.share-btn.x { background-color: #000000; }
.share-btn.linkedin { background-color: #0A66C2; }
.share-btn.whatsapp { background-color: #25D366; }
.share-btn.copy-link { background-color: #6c757d; position: relative; }

/* Tooltip for copy link button */
.copy-tooltip {
    position: absolute;
    bottom: 115%;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--primary-color);
    color: var(--white-color);
    padding: 6px 12px;
    border-radius: 5px;
    font-size: 0.85rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    pointer-events: none;
    z-index: 1001;
}

.share-btn.copy-link:hover .copy-tooltip,
.share-btn.copy-link:focus .copy-tooltip {
    opacity: 1;
    visibility: visible;
}

/* Careers Page - Restructured */
.perks-section {
    padding: 4rem 0;
    background-color: var(--white-color); /* To contrast with the section below */
}

.perks-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

/* Flip-card animation for perks */
.perk-card {
    background-color: transparent;
    height: 260px; /* Fixed height for consistent flipping */
    perspective: 1000px; /* 3D space for the flip */
    border: none;
}

.perk-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.7s;
    transform-style: preserve-3d;
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
    border-radius: 24px; /* Apply radius to inner to clip children */
}

.perk-card:hover .perk-card-inner {
    transform: rotateY(180deg);
    box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}

.perk-card-front,
.perk-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden; /* Hide the back of the card */
    backface-visibility: hidden;
    border-radius: 16px;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.perk-card-front {
    background-color: var(--white-color);
}

.perk-card-back {
    background: var(--primary-color);
    color: var(--white-color);
    transform: rotateY(180deg);
}

.perk-icon {
    font-size: 2.5rem;
    color: var(--secondary-color);
    margin-bottom: 1.5rem;
    display: inline-block;
}

.perk-card-back h3,
.perk-card-back p {
    color: var(--white-color);
}

.perk-card h3 {
    font-size: 1.2rem; /* Slightly smaller to fit back content */
    margin-bottom: 0.75rem;
}

/* Original careers section adjustments */
.careers-section {
    padding: 4rem 0; /* Standardized padding */
    background-color: var(--light-gray-color); /* Restore alternating background color */
}

.agency-logo-container {
    display: none; /* Hiding this as it's redundant with the new structure */
}

.careers-form-container {
    max-width: 900px; /* A bit wider for the form */
    margin: 0 auto;
    padding: 3rem;
    background-color: var(--white-color); /* Form container is now white on gray bg */
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.08);
}

.careers-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.careers-header h2 {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
}

.careers-header p {
    color: var(--text-color);
    font-size: 1.1rem;
}

.careers-header .email-link {
    font-weight: 600;
    color: var(--secondary-color);
}

.careers-form .form-row {
    display: flex;
    gap: 1.5rem;
    width: 100%;
}

.careers-form .form-row .form-group {
    flex: 1;
}

.careers-form .form-group {
    margin-bottom: 1.5rem;
    text-align: left;
}

.careers-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--dark-gray-color);
    font-size: 0.9rem;
}

.careers-form input[type="text"],
.careers-form input[type="email"],
.careers-form input[type="tel"],
.careers-form select,
.careers-form textarea {
    width: 100%;
    padding: 14px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
    background-color: #f8fafc;
    -webkit-appearance: none; /* Removes default select styling */
    -moz-appearance: none;
    appearance: none;
}

.careers-form select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 0.5rem center;
    background-repeat: no-repeat;
    background-size: 1.5em 1.5em;
    padding-right: 2.5rem;
}

.careers-form input::placeholder,
.careers-form textarea::placeholder {
    color: #94a3b8;
}

.careers-form input:focus,
.careers-form select:focus,
.careers-form textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(255, 123, 0, 0.2);
}

.careers-form .file-input {
    font-size: 0.9rem;
    padding: 10px;
}

.careers-form .file-input::file-selector-button {
    background-color: var(--primary-color);
    color: var(--white-color);
    border: none;
    padding: 10px 15px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    margin-right: 1rem;
    transition: background-color 0.3s ease;
}

.careers-form .file-input::file-selector-button:hover {
    background-color: var(--secondary-color);
}

.careers-form .cta-button {
    width: 100%;
    border: none;
    cursor: pointer;
    margin-top: 1rem;
    font-size: 1.1rem;
    padding: 15px;
}

/* Blog Page */
.blog-section {
    padding: 2rem 0 2rem;
}

.blog-controls {
    margin-bottom: 2.5rem;
}

.search-bar-container {
    position: relative;
    max-width: 600px;
    margin: 0 auto;
}

.search-icon {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    z-index: 1;
}

#blogSearchInput {
    width: 100%;
    padding: 15px 20px 15px 50px; /* Left padding for icon */
    border-radius: 50px;
    border: 1px solid #e2e8f0;
    font-size: 1rem;
    font-family: var(--font-body);
    transition: border-color 0.3s, box-shadow 0.3s;
}

#blogSearchInput:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(255, 123, 0, 0.2);
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 2rem;
}

.blog-post-card {
    background-color: var(--white-color);
    border-radius: 24px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.07);
    overflow: hidden;
    text-decoration: none;
    color: var(--text-color);
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-post-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}

.blog-card-image img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.blog-post-card:hover .blog-card-image img {
    transform: scale(1.05);
}

.blog-card-content {
    padding: 1.25rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.blog-card-category {
    display: inline-block;
    background-color: var(--light-gray-color);
    color: var(--secondary-color);
    padding: 5px 12px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 1rem;
    align-self: flex-start;
}

.blog-card-content h3 {
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
    color: var(--primary-color);
    line-height: 1.4;
    transition: color 0.3s ease;
}

.blog-post-card:hover .blog-card-content h3 {
    color: var(--secondary-color);
}

.blog-card-content p {
    margin-bottom: 1rem;
    flex-grow: 1;
}

.blog-card-meta {
    font-size: 0.85rem;
    color: #777;
    border-top: 1px solid #eee;
    padding-top: 1rem;
    margin-top: auto;
}

.no-results-message {
    text-align: center;
    padding: 4rem 0;
    display: none; /* Controlled by JS */
}

.no-results-message h3 {
    font-size: 1.8rem;
    margin-bottom: 0.5rem;
}


/* Single Blog Post Page */
.blog-post-container {
    background-color: var(--white-color);
    padding-bottom: 4rem;
}

.blog-post-header {
    padding: 4rem 0 2rem 0;
    text-align: center;
    padding-top: calc(var(--navbar-height) + 4rem);
}

.blog-post-header h1 {
    font-size: 3rem;
    max-width: 800px;
    margin: 1rem auto;
    line-height: 1.3;
}

.article-meta {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    margin-top: 1.5rem;
    color: var(--text-color);
}

.author-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.blog-post-featured-image {
    max-width: 1000px;
    margin: 0 auto 3rem auto;
}

.blog-post-featured-image img {
    width: 100%;
    height: auto;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.blog-post-content {
    max-width: 750px;
    margin: 0 auto;
}

.blog-post-content p,
.blog-post-content li {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.blog-post-content h2,
.blog-post-content h3 {
    margin: 2rem 0 1rem 0;
    line-height: 1.4;
}

.blog-post-content h2 { font-size: 2rem; }
.blog-post-content h3 { font-size: 1.6rem; }

.blog-post-content blockquote {
    margin: 2rem 0;
    padding: 1.5rem;
    background-color: var(--light-gray-color);
    border-left: 5px solid var(--secondary-color);
    font-size: 1.2rem;
    font-style: italic;
    color: var(--primary-color);
}

.blog-post-content a {
    text-decoration: underline;
    font-weight: 600;
}

/* Related Posts Section */
.related-posts-section {
    padding: 4rem 0;
    background-color: var(--light-gray-color);
    border-top: 1px solid #e2e8f0;
}

.related-posts-section .section-title {
    margin-bottom: 2.5rem;
}

/* Make related post cards slightly more compact */
.related-posts-section .blog-post-card h3 {
    font-size: 1.1rem;
}

.related-posts-section .blog-card-content p {
    display: none; /* Hide the paragraph for a more compact look */
}

.related-posts-section .blog-card-meta {
    border-top: none;
    padding-top: 0;
    margin-top: 1rem;
}
/* 5. Footer & Back-to-Top
----------------------------------- */
/* Enhanced Footer */
footer {
    background-color: var(--primary-color);
    color: rgba(255, 255, 255, 0.8);
    padding-top: 3rem;
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2.5rem;
    padding-bottom: 3rem;
}

.footer-column h4 {
    font-family: var(--font-heading);
    color: var(--white-color);
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.5rem;
}

.footer-column h4::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 2px;
    background-color: var(--secondary-color);
}

.footer-logo {
    display: inline-block;
    font-family: var(--font-heading);
    font-size: 1.8rem;
    color: var(--white-color);
    font-weight: 700;
    margin-bottom: 1rem;
}

.footer-column p {
    line-height: 1.7;
    margin-bottom: 1rem;
}

.footer-column ul {
    list-style: none;
}

.footer-column ul li {
    margin-bottom: 0.75rem;
}

.footer-column ul a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease, padding-left 0.3s ease;
}

.footer-column ul a:hover {
    color: var(--secondary-color);
    padding-left: 5px;
}

.footer-column .contact-info li {
    display: flex;
    align-items: center;
}

.footer-column .contact-info i {
    margin-right: 0.75rem;
    color: var(--secondary-color);
}

.footer-socials {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.footer-socials a {
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--white-color);
    text-decoration: none;
    font-size: 2rem; /* Even larger icons */
    /* Initial state for animation */
    opacity: 0;
    transform: translateY(20px);
    transition: transform 0.3s ease, opacity 0.4s ease, color 0.3s ease, text-shadow 0.3s ease;
}

.footer-socials a:nth-child(1) { transition-delay: 0.3s; }
.footer-socials a:nth-child(2) { transition-delay: 0.4s; }
.footer-socials a:nth-child(3) { transition-delay: 0.5s; }
.footer-socials a:nth-child(4) { transition-delay: 0.6s; }

.footer-socials.visible a {
    opacity: 1;
    transform: translateY(0);
}

.footer-socials a:hover {
    transform: translateY(-3px);
    transition-delay: 0s; /* Ensure hover effect is immediate */
}

.footer-socials a[href*="facebook.com"]:hover {
    color: #1877F2; /* Facebook Blue */
    text-shadow: 0 0 15px rgba(24, 119, 242, 0.8);
}

.footer-socials a[href*="youtube.com"]:hover {
    color: #FF0000; /* YouTube Red */
    text-shadow: 0 0 15px rgba(255, 0, 0, 0.8);
}

.footer-socials a[href*="linkedin.com"]:hover {
    color: #0A66C2; /* LinkedIn Blue */
    text-shadow: 0 0 15px rgba(10, 102, 194, 0.8);
}

.footer-socials a[href*="instagram.com"]:hover {
    color: #E1306C; /* Instagram Pink */
    text-shadow: 0 0 15px rgba(225, 48, 108, 0.8);
}

.footer-bottom {
    background-color: rgba(0,0,0,0.2);
    text-align: center;
    padding: 1.5rem 0;
    font-size: 0.9rem;
}

/* Floating Action Buttons */
.floating-actions {
    position: fixed;
    top: 55%; /* Position relative to the top */
    left: 20px;
    transform: translateY(-50%); /* Center vertically relative to the new top position */
    z-index: 1000;
    display: flex;
    flex-direction: column;
    gap: 1rem; /* Gap between main icons */
    /* Initial state for animation */
    opacity: 0;
    transform: translateY(-50%) scale(0.8);
    transition: opacity 0.4s ease, visibility 0.4s ease, transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Container for a single icon and its options */
.fab-container {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* The main, always-visible icon button */
.fab.fab-main {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--white-color);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 28px;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    z-index: 2;
}

.fab.fab-main i {
    transition: text-shadow 0.3s ease;
}

.fab.fab-main:hover {
    transform: scale(1.1);
}

/* Container for the hidden option buttons */
.fab-options {
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    gap: 15px;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 1;
    pointer-events: none;
}

/* Show options when container has 'show-options' class (controlled by JS) */
.fab-container.show-options .fab-options {
    opacity: 1;
    visibility: visible;
    transform: translate(calc(60px + 15px), -50%); /* Move to the right of the main button */
    pointer-events: auto;
}

/* Individual option button */
.fab-option {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background-color: var(--white-color);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    display: flex;
    justify-content: center;
    align-items: center;
    text-decoration: none;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative; /* For tooltip */
}

.fab-option:hover {
    transform: scale(1.15);
    box-shadow: 0 6px 20px rgba(0,0,0,0.2);
}

/* Text inside the option button (HI/EN) */
.fab-text {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1rem;
    color: var(--primary-color);
}

/* Tooltip for options */
.fab-option[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 120%; /* Position tooltip above the option */
    left: 50%;
    transform: translateX(-50%) scale(0.8);
    background-color: var(--primary-color);
    color: var(--white-color);
    padding: 6px 12px;
    border-radius: 5px;
    font-size: 0.85rem;
    font-family: var(--font-body);
    font-weight: 600;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, transform 0.2s ease;
    pointer-events: none;
    z-index: 1001;
}

.fab-option[data-tooltip]:hover::after {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) scale(1);
    transition-delay: 0.1s;
}

.fab-call {
    color: #007bff; /* Call icon blue */
}
.fab-call:hover i {
    /* Add a blue glow effect on hover */
    text-shadow: 0 0 25px rgba(0, 123, 255, 0.8), 0 0 10px rgba(0, 123, 255, 0.6);
}
.fab-whatsapp {
    color: #25D366; /* WhatsApp Green */
}
.fab-whatsapp:hover i {
    /* Add a green glow effect on hover */
    text-shadow: 0 0 25px rgba(37, 211, 102, 0.8), 0 0 10px rgba(37, 211, 102, 0.6);
}

/* Hide floating buttons when footer is visible */
.floating-actions.hidden-by-footer {
    opacity: 0;
    visibility: hidden;
    pointer-events: none; /* Prevent interaction when hidden */
}

.floating-actions.show {
    opacity: 1;
    transform: translateY(-50%) scale(1);
}

/* Back to Top Button */
.back-to-top-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: var(--secondary-color);
    color: var(--white-color);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 24px;
    text-decoration: none;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transform: translateY(100px);
    transition: opacity 0.4s ease, visibility 0.4s ease, transform 0.4s ease, background-color 0.3s ease;
    overflow: hidden; /* Important for the rocket effect */

}

.back-to-top-btn.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top-btn:hover {
    background-color: #e66a00; /* Darker orange */
    /* Hover transform is handled by the .show class to avoid conflicts */
}

.back-to-top-btn.show:hover {
    transform: translateY(-3px);
}

.btt-arrow {
    transition: transform 0.5s cubic-bezier(0.68, -0.55, 0.27, 1.55), opacity 0.4s ease;
}

.btt-rocket {
    position: absolute;
    /* The rocket's position is now fully controlled by the animation */
}

/* State when rocket is launching */
.back-to-top-btn.launching .btt-arrow {
    transform: translateY(-60px); /* Move arrow up and out */
    opacity: 0;
}

.back-to-top-btn.launching .btt-rocket {
    animation: launch-and-fly 1.5s ease-in-out forwards;
}

@keyframes launch-and-fly {
    0% {
        transform: translateY(50px);
        opacity: 0;
    }
    25% {
        transform: translateY(0);
        opacity: 1;
    }
    100% {
        transform: translateY(-100vh); /* Fly to the top of the viewport */
        opacity: 0;
    }
}

/* 6. Responsive Media Queries
----------------------------------- */
@media(max-width: 992px) {
    .page-header { padding-top: calc(var(--navbar-height) + 2rem); }
    .page-header h1 { font-size: 2.5rem; }

    .about-home-layout {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    .about-home-image {
        order: -1; /* Image on top on mobile */
    }
    .about-home-content {
        text-align: center;
    }
    .about-home-content .section-title {
        text-align: center;
    }
    .about-home-content > p {
        margin-left: auto;
        margin-right: auto;
    }

    .e-hero-layout {
        gap: 2rem;
    }
    .e-hero-content h1 { font-size: 36px; }
    .e-hero-content p { font-size: 18px; }

    .features-content-layout { gap: 2rem; }
    .features-header h2 { font-size: 30px; }
    .features-header p { font-size: 16px; }
    .features-text-content h3 { font-size: 24px; }

    .contact-wrapper {
        grid-template-columns: 1fr;
        padding: 2rem;
    }

    .contact-form .form-row {
        flex-direction: column;
        gap: 0; /* Remove gap as they are stacked */
    }

    .careers-form .form-row {
        flex-direction: column;
        gap: 0;
    }
    .careers-form-container {
        padding: 2rem;
    }
}

@media(max-width: 768px) {
    .about-highlights {
        display: inline-block;
        text-align: left;
    }

    /* Testimonial adjustments for mobile */
    .testimonial-slider {
        min-height: 280px; /* Give more space for text wrapping */
        margin-bottom: 3rem;
    }
    .testimonial-slide blockquote {
        font-size: 1rem; /* 16px, more readable on small screens */
        padding: 1.5rem;
    }
    .testimonial-slide blockquote::before {
        font-size: 4rem; /* Scale down the large quote mark */
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 65px; /* Match scrolled navbar height */
        flex-direction: column;
        background-color: var(--white-color);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
    }
    .nav-menu.active { left: 0; }
    .nav-item { margin: 1.5rem 0; }
    .hamburger { display: block; }
    .hamburger.active .bar:nth-child(2) { opacity: 0; }
    .hamburger.active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .hamburger.active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }

    .lightbox-prev { left: 10px; }
    .lightbox-next { right: 10px; }
    .lightbox-close {
        top: 10px;
        right: 15px;
        font-size: 35px;
        color: #ddd;
        background-color: rgba(0,0,0,0.3);
        border-radius: 50%;
        width: 40px;
        height: 40px;
        display: flex;
        align-items: center;
        justify-content: center;
        line-height: 1;
    }

    /* Reposition Floating Action Buttons on mobile to avoid content overlap */
    .floating-actions {
        top: auto; /* Unset top positioning */
        left: auto; /* Unset left positioning */
        bottom: 80px; /* Position above the back-to-top button */
        right: 20px;
        transform: none; /* Reset desktop transform */
    }

    /* Make FAB options expand to the left on mobile */
    .fab-options {
        left: auto; /* Unset left anchor */
        right: 0;   /* Anchor to the right of the container */
    }

    .fab-container.show-options .fab-options {
        transform: translate(calc(-100% - 15px), -50%); /* Move left */
    }

    .ecommerce-hero { 
        padding: calc(var(--navbar-height) + 20px) 0 30px; /* Adjust top padding for navbar on mobile */
        height: auto; /* Let content define height on mobile */
        min-height: 100vh;
    }
    .e-hero-layout { flex-direction: column; text-align: center; }
    .e-hero-stats { justify-content: center; gap: 1.5rem; }
    .e-hero-image { margin-top: 2rem; }
    .e-hero-content h1 { font-size: 28px; }
    .e-hero-content p { font-size: 16px; max-width: 100%; }

    .services-compact .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media(max-width: 480px) {
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
    .stats-grid {
        grid-template-columns: 1fr;
    }
    .services-compact .services-grid {
        grid-template-columns: 1fr;
    }
}
