/* Global Styles */
:root {
    --primary-bg: #141c2f; /* Deep Navy */
    --secondary-bg: #ffffff;
    --accent-green: #00d285; /* Bright Emerald Green */
    --text-white: #ffffff;
    --text-dark: #333333;
    --text-gray: #666666;
    --light-gray: #f9f9f9;
}

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

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--secondary-bg);
    scroll-behavior: smooth;
    overflow-x: hidden; /* Prevent horizontal scroll */
}

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

ul {
    list-style: none;
}

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

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

/* Typography */
h1, h2, h3, h4 {
    font-weight: 700;
}

h1 {
    font-size: 3.5rem; /* Responsive unit */
}

h2 {
    font-size: 2.25rem;
}

h3 {
    font-size: 1.8rem;
}

.tag {
    display: inline-block;
    color: var(--accent-green);
    background: rgba(0, 210, 133, 0.1);
    padding: 5px 15px;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 15px;
}

/* Buttons */
.btn {
    display: inline-block;
    background: linear-gradient(90deg, #00d285, #00e090);
    color: white;
    padding: 12px 35px;
    border-radius: 30px;
    font-weight: 600;
    box-shadow: 0 5px 15px rgba(0, 210, 133, 0.3);
    transition: transform 0.3s, box-shadow 0.3s;
    border: none;
    cursor: pointer;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 210, 133, 0.4);
}

.btn-green {
    background: var(--accent-green);
    padding: 10px 25px;
    border-radius: 5px;
}

/* Header */
header {
    background-color: var(--primary-bg);
    color: var(--text-white);
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

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

.logo {
    font-size: 24px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 1001;
}

.logo-icon {
    font-family: serif;
    font-style: italic;
    color: var(--text-gray);
    opacity: 0.5;
}

/* Desktop Nav */
.nav-menu ul {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-menu a {
    color: rgba(255,255,255,0.8);
    font-size: 15px;
    font-weight: 500;
}

.nav-menu a:hover, .nav-menu a.active {
    color: var(--text-white);
    position: relative;
}

.nav-menu a.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 20px;
    height: 2px;
    background-color: var(--accent-green);
}

/* Language Switcher (Segmented Control) */
.lang-switcher {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-left: 10px;
}

.lang-btn {
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-white);
    padding: 6px 12px;
    border: 1px solid rgba(255,255,255,0.3);
    border-radius: 6px;
    transition: all 0.3s ease;
    opacity: 0.7;
}

.lang-btn:hover {
    border-color: var(--accent-green);
    color: var(--accent-green);
    opacity: 1;
}

.lang-btn.active {
    background-color: var(--accent-green); /* Solid Green Background */
    border-color: var(--accent-green);
    color: white;
    opacity: 1;
    box-shadow: 0 4px 10px rgba(0, 210, 133, 0.3);
}

/* Mobile Toggle */
.mobile-toggle {
    display: none;
    font-size: 24px;
    cursor: pointer;
    z-index: 1001;
}

/* Hero Section */
.hero {
    background-color: var(--primary-bg);
    padding: 80px 0 100px;
    color: var(--text-white);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 60%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.03) 0%, transparent 100%);
    clip-path: polygon(20% 0, 100% 0, 100% 100%, 0% 100%);
    z-index: 0;
}

.hero .container {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 50px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero h1 {
    line-height: 1.2;
    margin-bottom: 25px;
}

.hero .underline {
    position: relative;
    display: inline-block;
}

.hero .underline::after {
    content: '';
    position: absolute;
    bottom: 5px;
    left: 0;
    width: 100%;
    height: 4px;
    background-color: var(--accent-green);
}

.hero p {
    font-size: 1.125rem;
    color: rgba(255,255,255,0.7);
    margin-bottom: 40px;
    max-width: 500px;
}

.hero .image img {
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.3));
    max-width: 90%;
    margin-left: auto;
}

/* Floating Animation */
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
    100% { transform: translateY(0px); }
}

.floating-img {
    animation: float 6s ease-in-out infinite;
}

/* About Section */
.about {
    padding: 100px 0;
    background-color: var(--secondary-bg);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    margin-bottom: 80px;
}

.about-text h2 {
    margin-bottom: 20px;
    color: var(--primary-bg);
}

.about-text p {
    color: var(--text-gray);
    margin-bottom: 30px;
    font-size: 1rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); /* Better responsiveness */
    gap: 25px;
}

.feature-card {
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: transform 0.3s;
}

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

.icon-box {
    width: 50px;
    height: 50px;
    background: rgba(0, 210, 133, 0.1);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-green);
    font-size: 20px;
    margin-bottom: 20px;
}

.feature-card h4 {
    font-size: 1.125rem;
    margin-bottom: 10px;
    color: var(--primary-bg);
}

.feature-card p {
    font-size: 0.875rem;
    color: var(--text-gray);
    line-height: 1.5;
}

.stats-container {
    display: flex;
    justify-content: space-around; /* Better spacing */
    flex-wrap: wrap; /* Allow wrapping */
    background: white;
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    gap: 30px;
}

.stat-item {
    text-align: center;
    flex: 1;
    min-width: 150px;
}

.stat-icon {
    font-size: 24px;
    color: var(--accent-green);
    margin-bottom: 10px;
    background: rgba(0, 210, 133, 0.1);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px;
}

.stat-item .number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-bg);
}

.stat-item .label {
    font-size: 0.875rem;
    color: var(--text-gray);
}

/* Services Section */
.services {
    padding: 100px 0;
    background-color: var(--secondary-bg);
}

.section-title {
    margin-bottom: 60px;
}

.section-title h2 {
    font-size: 2rem;
    color: var(--primary-bg);
    margin-top: 10px;
}

.section-title.center {
    text-align: center;
}

.service-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
    margin-bottom: 100px;
}

.service-row.reverse .service-image {
    order: 2;
}

.service-row.reverse .service-text {
    order: 1;
}

.service-text h3 {
    line-height: 1.3;
    margin-bottom: 20px;
    color: var(--primary-bg);
}

.service-text p {
    color: var(--text-gray);
    margin-bottom: 20px;
}

.service-text .subtitle {
    font-size: 1.125rem;
    font-weight: 500;
    color: var(--primary-bg);
    margin-bottom: 15px;
}

.check-list li {
    position: relative;
    padding-left: 30px;
    margin-bottom: 12px;
    color: var(--text-gray);
}

.check-list li::before {
    content: '\2713';
    position: absolute;
    left: 0;
    top: 2px;
    color: var(--accent-green);
    font-weight: bold;
}

/* Projects Grid */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* More fluid */
    gap: 30px;
}

.project-item {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.project-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.project-item:hover img {
    transform: scale(1.05);
}

/* Contact Section */
.contact {
    background-color: var(--light-gray);
    padding: 100px 0;
}

.contact-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.contact-card {
    background: white;
    padding: 40px;
    text-align: center;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.contact-card .icon-box {
    margin: 0 auto 20px;
    width: 60px;
    height: 60px;
    font-size: 24px;
}

.contact-card h4 {
    font-size: 1.25rem;
    margin-bottom: 10px;
    color: var(--primary-bg);
}

/* Footer */
footer {
    background-color: var(--primary-bg);
    color: rgba(255,255,255,0.6);
    text-align: center;
    padding: 30px 0;
    font-size: 14px;
}

footer strong {
    color: var(--text-white);
}

/* Animations CSS */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-up {
    transform: translateY(30px);
}

.fade-left {
    transform: translateX(30px);
}

.fade-right {
    transform: translateX(-30px);
}

/* RESPONSIVE DESIGN */

/* Tablet (max-width: 992px) */
@media (max-width: 992px) {
    .container {
        padding: 0 30px;
    }

    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 40px;
    }

    .hero h1 {
        font-size: 3rem;
    }
    
    .hero .underline::after {
        left: 0;
        right: 0;
        margin: auto;
        width: 200px;
    }

    .hero .image img {
        margin: 0 auto;
        max-width: 70%;
    }

    .about-grid {
        grid-template-columns: 1fr;
    }
    
    .service-row {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }

    .service-row.reverse .service-image {
        order: 0;
    }

    .service-row.reverse .service-text {
        order: 0;
    }
    
    .check-list li {
        text-align: left;
        display: inline-block;
    }

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

/* Mobile (max-width: 768px) */
@media (max-width: 768px) {
    .container {
        padding: 0 20px;
    }

    .mobile-toggle {
        display: block;
        color: white;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background-color: var(--primary-bg);
        padding-top: 80px;
        transition: 0.4s;
        box-shadow: -5px 0 15px rgba(0,0,0,0.2);
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-menu ul {
        flex-direction: column;
        align-items: center;
        gap: 40px;
    }

    .nav-menu a {
        font-size: 1.2rem;
    }

    .hero {
        padding: 60px 0 80px;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero p {
        font-size: 1rem;
    }

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

    .stats-container {
        flex-direction: column;
        gap: 40px;
    }
    
    .section-title h2 {
        font-size: 1.8rem;
    }
    
    .service-row {
        margin-bottom: 60px;
    }
    
    .projects-grid {
        grid-template-columns: 1fr; /* Stack projects on mobile */
    }
}
