/* Global Variables */
:root {
    --primary-color: #4CAF50;
    --primary-dark: #388E3C;
    --secondary-color: #FF9800;
    --secondary-dark: #F57C00;
    --acccent-color: #2196F3;
    --dark-bg: #121212;
    --card-bg: #1E1E1E;
    --light-text: #F5F5F5;
    --grey-text: #B0B0B0;
    --white: #FFFFFF;
    --transition: all 0.3s ease-in-out;
    --font-heading: 'Outfit', sans-serif;
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    --header-height: 90px;
    /* Increased header height */

    /* New Premium Backgrounds */
    --bg-light-green: #e8f5e9;
    /* Very subtled green for Services */
    --bg-ivory: #fdfbf7;
    /* Warm off-white for About */
}

/* --- DETAIL PAGE FIXES (Legacy Support) --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
    padding: 10px 0;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.row {
    display: flex;
    gap: 50px;
    align-items: center;
    margin-bottom: 60px;
}

.col {
    flex: 1;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.card {
    background: var(--white);
    padding: 30px;
    border-radius: 15px;
    box-shadow: var(--shadow);
    text-align: center;
}

.section-heading {
    font-size: 2.5rem;
    color: var(--dark-bg);
    margin-bottom: 20px;
}

.body-text {
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 20px;
    line-height: 1.8;
}

.feature-list li {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
}

.feature-list i {
    color: var(--primary-color);
}

@media(max-width: 768px) {
    .row {
        flex-direction: column;
    }

    .about-image {
        margin-bottom: 30px;
    }

    .experience-badge {
        bottom: 20px;
        right: 20px;
        padding: 20px;
        min-width: 130px;
    }

    .experience-badge .years {
        font-size: 2.2rem;
    }

    .experience-badge .text {
        font-size: 0.85rem;
    }
}

/* --- DETAIL PAGE SPECIFIC FIXES --- */
/* Fix Giant Logo on Detail Pages */
.logo-img {
    height: 60px;
    width: auto;
    object-fit: contain;
}

.logo-box {
    display: flex;
    align-items: center;
}

.btn-cta {
    background: var(--secondary-color);
    color: white;
    padding: 10px 20px;
    border-radius: 50px;
    /* Modern round */
    font-weight: 600;
}

/* Detail Page Footer */
.footer {
    background: #050a06;
    /* Match modern footer */
    color: #e0e0e0;
    padding: 80px 0 20px;
}

.footer-grid {
    display: flex;
    gap: 60px;
    flex-wrap: wrap;
}

.footer-col {
    flex: 1;
    min-width: 300px;
}

.footer-logo-box img {
    height: 70px;
    margin-bottom: 20px;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-links a {
    color: white;
    font-size: 1.2rem;
    transition: 0.3s;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.social-links a:hover {
    background: var(--primary-color);
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    overflow-x: hidden;
    /* Prevent horizontal scroll */
}

body {
    font-family: var(--font-heading);
    background-color: var(--white);
    color: #333;
    line-height: 1.6;
    overflow-x: hidden;
    /* Prevent horizontal scroll */
    width: 100%;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 20px;
}

h2 {
    font-size: 2.5rem;
    color: var(--dark-bg);
}

.sub-heading {
    font-size: 1.2rem;
    color: var(--primary-color);
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 600;
    margin-bottom: 10px;
}

p {
    margin-bottom: 20px;
    color: #666;
}

/* Utilities */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
    box-sizing: border-box;
}

.container-fluid {
    width: 100%;
    padding: 0;
    /* Full Width for Projects */
    overflow: hidden;
    /* Ensure content doesn't spill */
}

.section {
    padding: 100px 0;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    border: none;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(76, 175, 80, 0.4);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--white);
}

.btn-secondary:hover {
    background-color: var(--secondary-dark);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(255, 152, 0, 0.4);
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
    height: var(--header-height);
    /* Set fixed height to prevent collapse */
    display: flex;
    /* Flex to center content vertically */
    align-items: center;
    transition: var(--transition);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    height: 100%;
    /* Take full height of header */
}

.logo img {
    height: 65px;
    /* Slightly adjusted for better fit */
    object-fit: contain;
}

/* Desktop Navigation */
@media (min-width: 992px) {
    .nav-links {
        display: flex;
        gap: 30px;
        align-items: center;
        /* Ensure items center vertically */
    }
}

.nav-links a {
    font-weight: 600;
    color: var(--dark-bg);
    position: relative;
    padding: 5px 0;
    font-size: 1rem;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 3px;
    bottom: 0;
    left: 0;
    background-color: var(--primary-color);
    transition: width 0.3s cubic-bezier(0.19, 1, 0.22, 1);
    border-radius: 2px;
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.hamburger {
    display: none; /* Temporarily always visible for debugging */
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 10010;
    /* Higher Z-index */
    color: var(--dark-bg);
    position: relative;
    border: 0px;
    background-color: transparent !important;
}

.hamburger.active i::before {
    content: "\f00d"; /* fa-times icon */
}

.hamburger:not(.active) i::before {
    content: "\f0c9"; /* fa-bars icon */
}

/* Hero Section */
.hero {
    height: 100vh;
    width: 100%;
    position: relative;
    padding: 0;
    margin-top: 0;
}

.hero-swiper {
    width: 100%;
    height: 100%;
}

.swiper-slide {
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
    position: relative;
}

.hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
    z-index: -1;
}

.hero-overlay {
    background: rgba(0, 0, 0, 0.4);
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px;
}

.hero-content {
    color: var(--white);
    max-width: 900px;
}

.hero-content h1 {
    font-size: 4rem;
    margin-bottom: 20px;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    line-height: 1.1;
}

.hero-content p {
    font-size: 1.25rem;
    color: #f0f0f0;
    margin-bottom: 30px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* About Section */
.about {
    background: var(--bg-ivory);
    /* New Background */
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-image {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--shadow);
    margin-bottom: 0;
}

.about-image img {
    width: 100%;
    display: block;
}

.experience-badge {
    position: absolute;
    bottom: 30px;
    right: 30px;
    background: var(--primary-color);
    color: var(--white);
    padding: 25px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 10px 20px rgba(76, 175, 80, 0.3);
    min-width: 150px;
}

.experience-badge .years {
    display: block;
    font-size: 3rem;
    font-weight: 800;
    line-height: 1;
}

.experience-badge .text {
    font-size: 0.9rem;
    font-weight: 500;
}

.about-features {
    margin: 30px 0;
}

.about-features li {
    margin-bottom: 15px;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 15px;
}

.about-features i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

/* --- REDESIGNED SERVICES SECTION (Background Image Style) --- */
.services {
    background: var(--bg-light-green);
    padding: 100px 0;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    /* Force 4 columns */
    gap: 20px;
}

.service-card {
    position: relative;
    height: 450px;
    /* Tall vertical card */
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.4s ease;
    cursor: pointer;
}

.service-card:hover {
    transform: translateY(-10px);
}

.service-img-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.service-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover !important;
    /* Full Cover Background */
    transition: transform 0.6s ease;
}

.service-card:hover .service-img-wrapper img {
    transform: scale(1.1);
}

.service-info {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 10%, rgba(0, 0, 0, 0.3) 50%, transparent 100%);
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 30px;
    transition: all 0.4s ease;
}

.service-info h3 {
    color: var(--white);
    font-size: 1.5rem;
    margin-bottom: 10px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.service-info p {
    color: #e0e0e0;
    font-size: 0.95rem;
    margin-bottom: 20px;
    opacity: 0.9;
    line-height: 1.5;
    display: none;
    /* Hide description by default to keep it clean */
}

/* Show Description on Hover */
.service-card:hover .service-info p {
    display: block;
    animation: fadeInUp 0.4s ease;
}

.read-more-btn {
    display: inline-block;
    color: var(--primary-color);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 1px;
    margin-top: auto;
    /* Push to bottom if needed */
}

@media (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .services-grid {
        grid-template-columns: 1fr;
    }
}


/* --- MJODERN PROJECTS MOSAIC (No Filter, 100% Width) --- */
.projects-full {
    background: #000;
    /* Deep black for premium contrast */
    padding: 0;
    /* Full edge to edge vertical possible, or just padding */
    padding-top: 100px;
}

.projects-full .section-header {
    margin-bottom: 60px;
    color: white;
}

.projects-mosaic {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 350px;
    /* Base height for cells */
    gap: 5px;
    /* Tight gap for premium mosaic look */
    padding: 0 5px;
    /* Tiny edge padding */
}

/* Mosaic Item Sizes */
.mosaic-item {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    background: #111;
}

.mosaic-item.large {
    grid-column: span 2;
    grid-row: span 2;
}

.mosaic-item.wide {
    grid-column: span 2;
}

.mosaic-item.tall {
    grid-row: span 2;
}

.mosaic-media {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
    filter: brightness(0.85);
    /* Slightly dark by default */
}

.mosaic-item:hover .mosaic-media {
    transform: scale(1.1);
    filter: brightness(1);
    /* Bright on hover */
}

.mosaic-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, transparent 60%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 30px;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.mosaic-item:hover .mosaic-overlay {
    opacity: 1;
}

.mosaic-overlay h3 {
    color: white;
    font-size: 1.4rem;
    margin-bottom: 5px;
    transform: translateY(20px);
    transition: transform 0.4s ease;
}

.mosaic-overlay span {
    color: var(--primary-color);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 1px;
    transform: translateY(20px);
    transition: transform 0.4s ease 0.1s;
}

.mosaic-item:hover h3,
.mosaic-item:hover span {
    transform: translateY(0);
}

.play-icon-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 3rem;
    opacity: 0.8;
    z-index: 2;
    transition: 0.3s;
    pointer-events: none;
}

.mosaic-item:hover .play-icon-overlay {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8);
}

.view-btn-float {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: white;
    color: black;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    opacity: 0;
    transform: translateY(-20px);
    transition: all 0.4s ease;
}

.mosaic-item:hover .view-btn-float {
    opacity: 1;
    transform: translateY(0);
}

.view-btn-float:hover {
    background: var(--primary-color);
    color: white;
}

/* Contact Section */
.contact {
    background: #fff;
    padding-bottom: 0;
    /* Footer connects directly */
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    background: var(--white);
    border-radius: 30px;
    overflow: hidden;
    box-shadow: var(--shadow);
    margin-bottom: -50px;
    /* Overlap footer */
    position: relative;
    z-index: 10;
}

.contact-info {
    background: var(--dark-bg);
    padding: 60px;
    color: var(--white);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.contact-info h2 {
    color: var(--white);
    margin-bottom: 15px;
}

.contact-info p {
    color: #bbb;
}

.info-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 30px;
}

.info-item .icon {
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    font-size: 1.2rem;
    flex-shrink: 0;
}

.info-item .details {
    flex: 1;
    min-width: 0;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.info-item .details h5 {
    color: var(--white);
    margin-bottom: 8px;
    font-size: 1rem;
}

.info-item .details p {
    color: #bbb;
    font-size: 0.95rem;
    margin: 0;
    word-break: break-word;
}

.contact-form-container {
    padding: 60px;
}

.contact-form .form-group {
    margin-bottom: 25px;
    width: 100%;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 18px;
    background: #f4f4f4;
    border: 1px solid transparent;
    border-radius: 12px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
    box-sizing: border-box;
}

.contact-form input:focus,
.contact-form textarea:focus {
    background: var(--white);
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 5px 20px rgba(76, 175, 80, 0.1);
}

.full-width {
    width: 100%;
}

/* --- MODERN FOOTER --- */
.footer-modern {
    background-color: #050a06;
    color: #e0e0e0;
    padding: 120px 0 30px;
    /* Increased top padding for overlap */
    font-size: 0.95rem;
}

.footer-top {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
    gap: 40px;
    margin-bottom: 60px;
}

.footer-col h4 {
    color: var(--white);
    margin-bottom: 25px;
    font-size: 1.2rem;
    position: relative;
    padding-bottom: 10px;
}

.footer-col h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
}

.brand-col p {
    color: #aaa;
    margin: 20px 0;
    line-height: 1.8;
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s;
    color: var(--white);
}

.social-icons a:hover {
    background: var(--primary-color);
    transform: translateY(-3px);
}

.footer-col ul li {
    margin-bottom: 15px;
}

.footer-col ul li a {
    color: #bbb;
    transition: 0.3s;
    display: inline-block;
}

.footer-col ul li a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.contact-col-foot ul li {
    display: flex;
    gap: 15px;
    align-items: flex-start;
    color: #bbb;
}

.contact-col-foot i {
    color: var(--primary-color);
    margin-top: 5px;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 25px;
    text-align: center;
    color: #777;
}

/* Modal */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(5px);
}

.lightbox.active {
    display: flex;
    animation: fadeIn 0.4s ease;
}

.lightbox-content {
    position: relative;
    max-width: 90%;
    max-height: 90vh;
}

.close-lightbox {
    position: absolute;
    top: -50px;
    right: 0;
    color: var(--white);
    font-size: 2.5rem;
    cursor: pointer;
    transition: var(--transition);
}

.close-lightbox:hover {
    transform: rotate(90deg);
    color: var(--primary-color);
}

#lightbox-media img,
#lightbox-media video {
    max-width: 100%;
    max-height: 85vh;
    border-radius: 10px;
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.5);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.reveal-up {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.reveal-up.active {
    opacity: 1;
    transform: translateY(0);
}

/* New Process Section Styles */
.process-section {
    background: var(--white);
    position: relative;
    overflow: hidden;
}

.process-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-top: 50px;
    position: relative;
    padding: 0 20px;
}

.process-step {
    text-align: center;
    position: relative;
    z-index: 2;
}

.process-icon {
    width: 80px;
    height: 80px;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin: 0 auto 20px;
    box-shadow: 0 10px 20px rgba(76, 175, 80, 0.3);
    position: relative;
}

/* Connecting Line (Desktop Only) */
.process-grid::before {
    content: '';
    position: absolute;
    top: 40px;
    left: 12%;
    width: 76%;
    height: 3px;
    background: #eee;
    z-index: 1;
}

/* Stats Section Styles */
.stats-section {
    background: var(--primary-dark);
    color: white;
    padding: 80px 0;
    position: relative;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    text-align: center;
}

.stat-item h3 {
    font-size: 3rem;
    color: var(--secondary-color);
    margin-bottom: 5px;
}

.stat-item p {
    color: #ddd;
    font-size: 1.1rem;
    font-weight: 500;
}

/* Detail Page Restore */
.detail-gallery-section {
    background: #f9f9f9;
    padding: 80px 0;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.gallery-item {
    position: relative;
    height: 300px;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.gallery-item img,
.gallery-item video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-item:hover img,
.gallery-item:hover video {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
}

.gallery-item .play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2rem;
    color: white;
    z-index: 2;
    pointer-events: none;
}

/* Hero Scroll Arrow */
.scroll-down {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    color: var(--white);
    font-size: 2rem;
    animation: bounce 2s infinite;
    cursor: pointer;
    text-align: center;
}

.scroll-down p {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 5px;
    color: rgba(255, 255, 255, 0.8);
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateX(-50%) translateY(0);
    }

    40% {
        transform: translateX(-50%) translateY(-10px);
    }

    60% {
        transform: translateX(-50%) translateY(-5px);
    }
}

/* Responsive Fixes */
@media (max-width: 1024px) {
    .projects-mosaic {
        grid-template-columns: repeat(3, 1fr);
        grid-auto-rows: 300px;
    }

    .process-grid::before {
        display: none;
    }
}

@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }

    .projects-mosaic {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 250px;
    }

    .mosaic-item.large,
    .mosaic-item.wide {
        grid-column: span 2;
    }

    .process-grid,
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 40px;
    }

    .nav-container {
        padding: 0 15px;
    }

    /* Detail Page Mobile Footer */
    .footer-grid {
        flex-direction: column;
        gap: 40px;
    }

    .footer-top {
        grid-template-columns: 1fr 1fr;
        gap: 30px;
        padding: 0 20px;
    }

    .contact-info,
    .contact-form-container {
        padding: 40px 20px;
    }

    .contact-form input,
    .contact-form textarea {
        padding: 14px;
        font-size: 16px;
    }

    .contact-form .form-group {
        margin-bottom: 20px;
    }

    .contact-info h2 {
        font-size: 2rem;
        margin-bottom: 10px;
    }

    .contact-info > p {
        font-size: 0.9rem;
        margin-bottom: 25px;
    }

    .info-item {
        margin-bottom: 25px;
    }

    .info-item .details h5 {
        font-size: 0.95rem;
    }

    .info-item .details p {
        font-size: 0.85rem;
    }
    .reveal-up {
        opacity: 1;
    }
}

@media (max-width: 480px) {
    .projects-mosaic {
        grid-template-columns: 1fr;
        grid-auto-rows: 300px;
    }

    .mosaic-item.large,
    .mosaic-item.wide,
    .mosaic-item.tall {
        grid-column: span 1;
        grid-row: span 1;
    }

    .process-grid,
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .about-image {
        margin-bottom: 40px;
    }

    .experience-badge {
        bottom: 15px;
        right: 15px;
        padding: 15px;
        min-width: 110px;
    }

    .experience-badge .years {
        font-size: 1.8rem;
    }

    .experience-badge .text {
        font-size: 0.75rem;
    }

    .contact-wrapper {
        margin-bottom: 0px;
        border-radius: 0;
    }

    .contact-info,
    .contact-form-container {
        padding: 25px 16px;
    }

    .contact-form input,
    .contact-form textarea {
        padding: 12px;
        font-size: 16px;
        margin-bottom: 0;
    }

    .contact-form .form-group {
        margin-bottom: 15px;
        width: 100%;
    }

    .contact-form textarea {
        resize: vertical;
        max-height: 150px;
    }

    .contact-info h2 {
        font-size: 1.8rem;
        margin-bottom: 12px;
    }

    .contact-info > p {
        font-size: 0.85rem;
        margin-bottom: 20px;
        line-height: 1.5;
    }

    .info-item {
        margin-bottom: 20px;
        gap: 15px;
    }

    .info-item .icon {
        width: 50px;
        height: 50px;
        font-size: 1rem;
    }

    .info-item .details h5 {
        font-size: 0.9rem;
        margin-bottom: 5px;
    }

    .info-item .details p {
        font-size: 0.8rem;
        line-height: 1.4;
    }

    .footer-modern {
        padding-top: 50px;
        padding-left: 0;
        padding-right: 0;
    }

    .footer-top {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 0 20px;
    }

    .footer-col {
        min-width: auto;
    }
}

@media (max-width: 991px) {

    .about-grid,
    .contact-wrapper {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .contact-info,
    .contact-form-container {
        padding: 40px;
    }

    .nav-links {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: 0;
        right: -100%;
        width: 300px;
        height: 100vh;
        background: #ffffff;
        padding: 80px 30px;
        box-shadow: -5px 0 30px rgba(0, 0, 0, 0.1);
        transition: right 0.4s cubic-bezier(0.77, 0, 0.175, 1);
        z-index: 10005;
        /* When hidden ensure it doesn't intercept pointer events */
        pointer-events: none;
        gap: 20px;
        overflow-y: auto;
    }

    .nav-links.active {
        right: 0;
        pointer-events: auto;
    }

    .hamburger {
        display: block;
        z-index: 5003;
        position: relative;
    }

    .menu-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: transparent;
        /* Keep overlay behind the nav-links; nav-links has higher z-index */
        z-index: 1;
        opacity: 1;
        visibility: visible;
        transition: all 0.3s;
        pointer-events: none;
    }

    .menu-overlay.active {
        pointer-events: auto;
    }
}