/* =========================================
   VARIABLES & GLOBAL STYLES
   ========================================= */
:root {
    --primary: #1E3A8A;
    /* Deep Blue */
    --secondary: #3B82F6;
    /* Sky Blue */
    --accent: #06B6D4;
    /* Cyan */
    --bg-light: #F9FAFB;
    /* Light Gray */
    --bg-dark: #0F172A;
    /* Navy */
    --text-primary: #111827;
    /* Dark Gray */
    --text-secondary: #6B7280;
    /* Gray */
    --btn-primary: #2563EB;
    /* Bright Blue */
    --btn-hover: #1D4ED8;
    /* Darker Blue */
    --btn-cta: #10B981;
    /* Green */
    --btn-cta-hover: #059669;
    /* Darker Green */
    --white: #FFFFFF;

    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Inter', sans-serif;

    --transition: all 0.3s ease-in-out;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

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

body {
    font-family: var(--font-body);
    color: var(--text-primary);
    background-color: var(--bg-light);
    line-height: 1.6;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6,
.logo {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

.section {
    padding: 100px 0;
}

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

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

.section-header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

.bg-gray {
    background-color: var(--white);
    /* Toggled specific sections for contrast */
}

/* =========================================
   BUTTONS
   ========================================= */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    text-align: center;
    border: 2px solid transparent;
}

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

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

.btn-cta {
    background-color: var(--btn-cta);
    color: var(--white);
}

.btn-cta:hover {
    background-color: var(--btn-cta-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.btn-outline {
    background-color: transparent;
    color: var(--white);
    border-color: var(--white);
}

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

.btn-block {
    display: block;
    width: 100%;
}

/* =========================================
   NAVBAR
   ========================================= */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--bg-dark);
    padding: 20px 0;
    z-index: 1000;
    transition: var(--transition);
}

.navbar.scrolled {
    padding: 12px 0;
    background-color: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    color: var(--white);
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-img {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid transparent;
    transition: var(--transition);
}

.logo:hover .logo-img {
    border-color: var(--accent);
    transform: scale(1.05);
}

.footer-logo {
    margin-bottom: 20px;
}

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

.nav-links a {
    color: var(--white);
    font-weight: 500;
    position: relative;
    padding-bottom: 5px;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent);
    transition: var(--transition);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
}

/* =========================================
   HERO SECTION
   ========================================= */
.hero {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    padding: 160px 0 100px;
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.hero-content {
    color: var(--white);
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
}

.hero-content p {
    font-size: 1.25rem;
    margin-bottom: 40px;
    opacity: 0.9;
}

.hero-buttons {
    display: flex;
    gap: 20px;
}

.hero-image img {
    border-radius: 12px;
    box-shadow: var(--shadow-hover);
    transform: perspective(1000px) rotateY(-5deg);
    transition: transform 0.5s ease;
}

.hero-image img:hover {
    transform: perspective(1000px) rotateY(0deg) scale(1.02);
}

/* =========================================
   SERVICES SECTION
   ========================================= */
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.service-card {
    background-color: var(--white);
    padding: 40px 30px;
    border-radius: 12px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    border-top: 4px solid transparent;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-hover);
    border-top-color: var(--accent);
}

.service-icon {
    width: 60px;
    height: 60px;
    background-color: rgba(6, 182, 212, 0.1);
    color: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 25px;
}

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

.service-card p {
    color: var(--text-secondary);
    margin-bottom: 25px;
}

.service-card ul li {
    margin-bottom: 10px;
    color: var(--text-primary);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 10px;
}

.service-card ul li i {
    color: var(--accent);
    font-size: 0.9rem;
}

/* =========================================
   BENEFITS SECTION
   ========================================= */
.benefits-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.benefit-item {
    text-align: center;
    padding: 20px;
}

.benefit-icon {
    color: var(--accent);
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.benefit-item h4 {
    font-size: 1.25rem;
    margin-bottom: 15px;
    color: var(--primary);
}

.benefit-item p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* =========================================
   PORTFOLIO SECTION
   ========================================= */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.portfolio-item {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: var(--shadow);
}

.portfolio-item img {
    width: 100%;
    height: 350px;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(15, 23, 42, 0.95) 10%, rgba(15, 23, 42, 0.4) 50%, rgba(15, 23, 42, 0.1) 100%);
    display: flex;
    align-items: flex-end;
    padding: 40px 30px;
    opacity: 0;
    transition: all 0.4s ease;
}

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

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-content {
    color: var(--white);
    transform: translateY(30px);
    transition: all 0.4s ease;
    width: 100%;
}

.portfolio-item:hover .portfolio-content {
    transform: translateY(0);
}

.portfolio-content h3 {
    font-size: 1.6rem;
    margin-bottom: 8px;
    font-weight: 700;
}

.portfolio-content p {
    color: var(--white);
    font-weight: 500;
    margin-bottom: 20px;
    font-size: 1rem;
}

.portfolio-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 24px;
    font-size: 0.95rem;
    border-radius: 50px;
    background-color: var(--primary);
    color: var(--white);
    border: none;
    font-weight: 600;
    transition: var(--transition);
}

.portfolio-btn i {
    font-size: 0.85rem;
    transition: transform 0.3s ease;
}

.portfolio-btn:hover {
    background-color: var(--accent);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(6, 182, 212, 0.3);
}

.portfolio-btn:hover i {
    transform: translateX(4px) translateY(-4px);
}

/* =========================================
   CONTACT SECTION
   ========================================= */
.contact-wrapper {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 50px;
    background-color: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow);
    overflow: hidden;
}

.contact-form-container {
    padding: 50px;
}

.contact-form-container h2 {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 10px;
}

.contact-form-container>p {
    color: var(--text-secondary);
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 20px;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #E5E7EB;
    border-radius: 6px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
    background-color: #F9FAFB;
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--secondary);
    background-color: var(--white);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.contact-info {
    background-color: var(--bg-dark);
    color: var(--white);
    padding: 50px;
}

.contact-info h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
}

.contact-info>p {
    color: #9CA3AF;
    margin-bottom: 40px;
}

.info-item {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.info-icon {
    color: var(--accent);
    font-size: 1.5rem;
}

.info-item h4 {
    margin-bottom: 5px;
}

.info-item p,
.info-item a {
    color: #9CA3AF;
}

.info-item a:hover {
    color: var(--accent);
}

/* =========================================
   FOOTER
   ========================================= */
.footer {
    background-color: var(--bg-dark);
    color: var(--white);
    padding: 80px 0 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 40px;
    margin-bottom: 60px;
}

.footer-about h3 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--white);
}

.footer-about p {
    color: #9CA3AF;
    margin-bottom: 25px;
}

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

.social-icons a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: var(--white);
}

.social-icons a:hover {
    background-color: var(--accent);
    transform: translateY(-3px);
}

.footer h4 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 30px;
    height: 2px;
    background-color: var(--accent);
}

.footer-links ul li,
.footer-services ul li {
    margin-bottom: 12px;
}

.footer-links ul li a,
.footer-services ul li a {
    color: #9CA3AF;
}

.footer-links ul li a:hover,
.footer-services ul li a:hover {
    color: var(--accent);
    padding-left: 5px;
}

.footer-contact p {
    color: #9CA3AF;
    margin-bottom: 15px;
}

.footer-email {
    display: inline-block;
    color: var(--white);
    font-weight: 500;
}

.footer-email i {
    color: var(--accent);
    margin-right: 8px;
}

.footer-email:hover {
    color: var(--accent);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #9CA3AF;
}

/* =========================================
   ANIMATIONS (Intersection Observer)
   ========================================= */
.fade-in {
    opacity: 0;
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.fade-in.appear {
    opacity: 1;
}

.slide-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.slide-up.appear {
    opacity: 1;
    transform: translateY(0);
}

.slide-in-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.slide-in-left.appear {
    opacity: 1;
    transform: translateX(0);
}

.slide-in-right {
    opacity: 0;
    transform: translateX(50px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.slide-in-right.appear {
    opacity: 1;
    transform: translateX(0);
}

/* =========================================
   RESPONSIVE DESIGN
   ========================================= */
@media (max-width: 1024px) {
    .benefits-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 900px) {
    .hero-content h1 {
        font-size: 2.8rem;
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .contact-wrapper {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .menu-btn {
        display: block;
    }

    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--bg-dark);
        flex-direction: column;
        gap: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease-in-out;
    }

    .nav-links.active {
        max-height: 300px;
    }

    .nav-links li {
        text-align: center;
        width: 100%;
    }

    .nav-links a {
        display: block;
        padding: 15px 0;
        border-top: 1px solid rgba(255, 255, 255, 0.05);
    }

    .navbar .btn-cta {
        display: none;
        /* Hidden on mobile navbar to save space */
    }

    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
        padding-top: 60px;
    }

    .hero-buttons {
        justify-content: center;
    }

    .hero-image {
        margin-top: 40px;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .portfolio-item img {
        height: 250px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer h4::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .social-icons {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 2.2rem;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .benefits-grid {
        grid-template-columns: 1fr;
    }

    .contact-form-container {
        padding: 30px 20px;
    }

    .contact-info {
        padding: 40px 20px;
    }
}