:root {
    --primary-color: #0c1a30;
    /* Deep Blue */
    --secondary-color: #d4af37;
    /* Gold */
    --accent-color: #f4f4f4;
    --text-color: #333;
    --light-text: #fff;
    --transition: all 0.3s ease;
}

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

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #f9f9f9;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

/* Header */
header {
    background: var(--primary-color);
    color: var(--light-text);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

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

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

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--secondary-color);
}

.nav-links {
    display: flex;
    gap: 20px;
}

.nav-links a {
    color: var(--light-text);
    font-weight: 500;
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--secondary-color);
}

.hamburger {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
}

/* Hero Section */
/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--light-text);
    position: relative;
    overflow: hidden;
    background: #000;
    /* Fallback */
}

/* Optimized Performance Background */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 200%;
    /* Double width to allow sliding */
    height: 100%;
    background: linear-gradient(rgba(12, 26, 48, 0.7), rgba(12, 26, 48, 0.7)), url('images/earth_night.jpg');
    background-size: auto 100%;
    /* Ensure image fits height, let width overflow */
    background-repeat: repeat-x;
    will-change: transform;
    animation: rotateEarth 60s linear infinite;
    z-index: 1;
}

@media (max-width: 768px) {
    .hero::before {
        background-size: auto 100%;
        width: 1000%;
        /* Extra width for horizontal scrolling animation on narrow screens */
        animation: rotateEarthMobile 90s linear infinite;
    }
}

@keyframes rotateEarthMobile {
    from {
        transform: translate3d(0, 0, 0);
    }

    to {
        transform: translate3d(-50%, 0, 0);
    }
}

.hero-content {
    position: relative;
    z-index: 2;
    /* Ensure content is above background */
}

@keyframes rotateEarth {
    from {
        transform: translate3d(0, 0, 0);
    }

    to {
        transform: translate3d(-50%, 0, 0);
        /* Slide by 50% (one full screen width) */
    }
}

.hero-content h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: var(--secondary-color);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-content p {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    font-weight: 300;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    background: var(--secondary-color);
    color: var(--primary-color);
    border: none;
    border-radius: 5px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.btn:hover {
    background: #e5bd1a;
    transform: translateY(-2px);
}

/* About Section */
.about {
    padding: 80px 0;
    background: #fff;
}

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

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

.section-title span {
    display: block;
    width: 60px;
    height: 3px;
    background: var(--secondary-color);
    margin: 0 auto;
}

.about-content {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 40px;
}

.about-text {
    flex: 1;
    min-width: 300px;
}

.about-text p {
    margin-bottom: 20px;
    color: #555;
    font-size: 1.1rem;
}

.about-image {
    flex: 1;
    min-width: 300px;
    text-align: center;
}

.about-image img {
    max-width: 100%;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Products Section */
.products {
    padding: 80px 0;
    background: #f4f4f4;
}

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

.product-card {
    background: #fff;
    padding: 0;
    border-radius: 10px;
    overflow: hidden;
    text-align: center;
    transition: var(--transition);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

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

.product-card h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

/* Legacy Section */
.legacy {
    padding: 80px 0;
    background: var(--primary-color);
    color: var(--light-text);
    text-align: center;
}

.legacy .section-title h2 {
    color: var(--light-text);
}

.legacy-stats {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    margin-top: 50px;
}

.stat-item {
    margin: 20px;
}

.stat-number {
    font-size: 3rem;
    font-weight: bold;
    color: var(--secondary-color);
    display: block;
}

.stat-label {
    font-size: 1.2rem;
    opacity: 0.9;
}

/* Why Choose Us */
.why-choose {
    padding: 80px 0;
}

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

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

.feature-item i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.feature-item h3 {
    margin-bottom: 10px;
}

/* Client Testimonials */
.testimonials {
    padding: 80px 0;
    background: #f9f9f9;
}

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

.testimonial-card {
    background: #fff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease;
}

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

.testimonial-card i {
    font-size: 2rem;
    color: var(--secondary-color);
    margin-bottom: 20px;
}

.client-quote {
    font-style: italic;
    margin-bottom: 20px;
    color: #555;
}

.client-name {
    font-weight: 600;
    color: var(--primary-color);
}

/* Certificates Section */
.certificates {
    padding: 80px 0;
    background: #fff;
}

.certificates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 40px;
    justify-items: center;
}

.certificate-item {
    background: #fff;
    padding: 10px;
    border-radius: 5px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    width: 100%;
    max-width: 280px;
    cursor: pointer;
    position: relative;
    border: 1px solid #eee;
    text-align: center;
}

.certificate-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.certificate-img-container {
    width: 100%;
    height: 350px;
    /* Fixed height for uniformity (approx A4 ratio) */
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fdfdfd;
    margin-bottom: 15px;
    position: relative;
}

.certificate-img-container img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    /* Ensures the whole certificate is visible */
}

/* Zoom Icon Overlay */
.zoom-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 ease;
}

.certificate-item:hover .zoom-overlay {
    opacity: 1;
}

.zoom-overlay i {
    color: #fff;
    font-size: 2rem;
}

.certificate-item p {
    font-weight: 500;
    color: var(--primary-color);
    margin: 0;
    padding-bottom: 10px;
}

/* Lightbox */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 2000;
    display: none;
    /* Hidden by default */
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lightbox.active {
    display: flex;
    opacity: 1;
}

.lightbox-content {
    max-width: 90%;
    max-height: 90vh;
    border-radius: 5px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

.close-lightbox {
    position: absolute;
    top: 20px;
    right: 30px;
    color: #fff;
    font-size: 3rem;
    cursor: pointer;
    transition: color 0.3s;
}

.close-lightbox:hover {
    color: var(--secondary-color);
}

/* Contact Section */
.contact {
    padding: 80px 0;
    background: #fff;
}

.contact-container {
    display: flex;
    flex-wrap: wrap;
    gap: 50px;
}

.contact-info {
    flex: 1;
    min-width: 300px;
}

.info-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 25px;
}

.info-item i {
    font-size: 1.5rem;
    color: var(--secondary-color);
    margin-right: 15px;
    margin-top: 5px;
}

.contact-form-container {
    flex: 1;
    min-width: 300px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.contact-form input,
.contact-form textarea {
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: inherit;
}

.contact-form textarea {
    height: 150px;
    resize: vertical;
}

/* Footer */
footer {
    background: #050d1a;
    color: #aaa;
    padding: 40px 0 20px;
    text-align: center;
}

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

.footer-bottom {
    border-top: 1px solid #222;
    padding-top: 20px;
    font-size: 0.9rem;
}

.spec-item {
    margin-bottom: 12px;
    border-bottom: 1px solid #ddd;
    padding-bottom: 8px;
    align-items: flex-start;
}

.spec-label {
    margin-bottom: 4px;
    color: var(--primary-color);
    font-size: 0.9rem;
}

@media (max-width: 480px) {
    .spec-item {
        flex-direction: column;
        text-align: center;
        /* Added text alignment for mobile */
    }
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(12, 26, 48, 0.85);
        backdrop-filter: blur(15px);
        -webkit-backdrop-filter: blur(15px);
        padding: 40px 0;
        text-align: center;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .nav-links li {
        margin: 15px 0;
    }

    .nav-links.active {
        display: flex;
        animation: slideDown 0.3s ease forwards;
    }

    @keyframes slideDown {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }

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

    .hamburger {
        display: block;
        color: var(--light-text);
    }

    .hero-content h1 {
        font-size: 2rem;
    }


    .hero-content p {
        font-size: 1.1rem;
    }
}

/* Product Card Images */
.product-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    margin-bottom: 0;
}

.product-info {
    padding: 20px 25px 30px;
}

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

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.product-icon {
    font-size: 2rem;
    color: var(--secondary-color);
    margin-bottom: 10px;
}


.legacy-content-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 80px;
    flex-wrap: wrap;
    margin-bottom: 40px;
    margin-top: 20px;
}

.legacy-stats {
    display: flex;
    flex-direction: row;
    gap: 60px;
}

.stat-item {
    margin: 0;
    text-align: center;
}

/* Legacy Section Styles */
.country-tag {
    background: rgba(255, 255, 255, 0.15);
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: inline-block;
    margin-right: 15px;
    /* Spacing between tags in marquee */
}

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

.marquee-content {
    display: inline-block;
    white-space: nowrap;
    animation: marquee 20s linear infinite;
}

@keyframes marquee {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
        /* Move half the length since we duplicated the content */
    }
}

/* Pause on hover for better UX */
.marquee-content:hover {
    animation-play-state: paused;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .legacy-content-wrapper {
        flex-direction: column-reverse;
    }

    .legacy-image {
        width: 100%;
        display: flex;
        justify-content: center;
    }

    .legacy-image img {
        max-width: 100% !important;
        height: auto !important;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    }

    .about-text {
        text-align: center;
    }

    .about-text .btn {
        display: block;
        width: fit-content;
        margin: 20px auto 0;
    }

    .legacy-text {
        text-align: center;
    }

    .legacy-content-wrapper {
        gap: 20px;
        margin-bottom: 20px;
    }

    .legacy-stats {
        flex-direction: column;
        gap: 20px;
    }
}

.legacy-content-wrapper .section-title {
    text-align: center !important;
}

.legacy-content-wrapper .section-title span {
    margin: 0 auto !important;
}

.legacy-stats {
    justify-content: center !important;
}

.legacy-text .legacy-stats+div {
    text-align: center;
}

.legacy-text .legacy-stats+div>div {
    justify-content: center;
}

.ship-animation-container {
    height: 100px;
}

.moving-ship {
    width: 100px;
    bottom: 10px;
}

/* Form Success Message */
.form-success {
    background: #4caf50;
    color: white;
    padding: 15px;
    border-radius: 5px;
    margin-top: 20px;
    text-align: center;
    font-weight: 500;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.4s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.form-success.show {
    opacity: 1;
    transform: translateY(0);
}

.form-success i {
    font-size: 1.2rem;
}

/* Animations */
.aos-init {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.aos-init.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Product Detail Pages */
.product-hero {
    height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    margin-bottom: 50px;
}

.product-hero h1 {
    font-size: 3.5rem;
    color: var(--secondary-color);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.product-detail-content {
    padding: 0 20px 80px;
}

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

.detail-text h2 {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 2rem;
}

.detail-text p {
    margin-bottom: 15px;
    font-size: 1.1rem;
    color: #555;
}

.detail-specs {
    background: #f9f9f9;
    padding: 30px;
    border-radius: 10px;
    border-left: 5px solid var(--secondary-color);
}

.detail-specs h3 {
    margin-bottom: 20px;
    color: var(--primary-color);
}

.product-actions {
    text-align: center;
    margin-top: 40px;
    display: flex;
    justify-content: center;
    gap: 15px;
}

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

@media (max-width: 768px) {
    .product-hero h1 {
        font-size: 2.5rem;
    }

    .detail-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .detail-text {
        text-align: center;
    }

    .product-actions {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }

    .product-actions .btn {
        width: 100%;
        max-width: 300px;
        margin: 0 !important;
    }
}