/* ---------- Reset & base ---------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #4f46e5;
    --primary-dark: #4338ca;
    --accent: #06b6d4;
    --text: #0f172a;
    --text-light: #64748b;
    --border: #e2e8f0;
    --bg: #ffffff;
    --bg-soft: #f8faff;
}

html {
    scroll-behavior: smooth;
}

body {
    position: relative;
    font-family: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.5;
}

/* Single continuous backdrop behind the navbar + hero + trust line, so there's
   no seam where two separately-computed gradients would otherwise meet. */
.ambient-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1100px;
    z-index: -1;
    pointer-events: none;
    background:
        radial-gradient(1000px 700px at 0% 0%, rgba(79, 70, 229, 0.14), transparent 60%),
        radial-gradient(900px 600px at 100% 0%, rgba(6, 182, 212, 0.10), transparent 55%),
        linear-gradient(160deg, #f5f4ff 0%, #ffffff 55%);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------- Scroll reveal ---------- */
/* Gated behind .js-enabled (set by an inline script in <head>) so content
   stays fully visible if JavaScript is unavailable. */
.js-enabled [data-reveal],
.js-enabled [data-reveal-item] {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.js-enabled [data-reveal].is-visible,
.js-enabled [data-reveal-item].is-visible {
    opacity: 1;
    transform: none;
}

@media (prefers-reduced-motion: reduce) {
    [data-reveal],
    [data-reveal-item] {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }
}

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

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 14px 28px;
    border-radius: 5px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    box-shadow: 0 8px 20px rgba(79, 70, 229, 0.25);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 24px rgba(79, 70, 229, 0.32);
}

.btn-outline {
    background: transparent;
    color: var(--text);
    border: 1.5px solid var(--border);
}

.btn-outline:hover {
    border-color: var(--primary);
    color: var(--primary);
}

/* ---------- Navbar ---------- */
.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    background: transparent;
    border-bottom: 1px solid transparent;
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.04);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 76px;
    gap: 24px;
}

.logo {
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text);
    flex-shrink: 0;
}

.logo span {
    color: var(--primary);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
    margin-left: auto;
}

.nav-links a {
    font-weight: 500;
    font-size: 0.95rem;
    color: var(--text-light);
    transition: color 0.15s ease;
}

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

.nav-cta {
    padding: 10px 22px;
    flex-shrink: 0;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    background: none;
    border: none;
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

/* ---------- Hero ---------- */
.hero {
    padding: 90px 0 110px;
}

.hero-inner {
    display: grid;
    grid-template-columns: 1.05fr 0.95fr;
    align-items: center;
    gap: 64px;
    position: relative;
    z-index: 1;
}

/* ---------- Hero content (left) ---------- */
.eyebrow {
    display: inline-block;
    padding: 7px 16px;
    border-radius: 999px;
    background: rgba(79, 70, 229, 0.08);
    color: var(--primary);
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 0.02em;
    margin-bottom: 20px;
}

.hero-content h1 {
    font-size: clamp(2.2rem, 4vw, 3.25rem);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.02em;
    color: var(--text);
    margin-bottom: 20px;
}

.hero-content h1 .highlight {
    color: var(--primary);
}

.hero-sub {
    font-size: 1.08rem;
    color: var(--text-light);
    max-width: 520px;
    margin-bottom: 34px;
}

.hero-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 48px;
    flex-wrap: wrap;
}

.hero-stats {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
}

.stat {
    display: flex;
    flex-direction: column;
}

.stat strong {
    font-size: 1.6rem;
    font-weight: 800;
    color: var(--text);
}

.stat span {
    font-size: 0.88rem;
    color: var(--text-light);
}

/* ---------- Hero media (right) ---------- */
.hero-media {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-image-wrap {
    position: relative;
    width: 100%;
    max-width: 460px;
    overflow: hidden;
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.hero-placeholder-text {
    display: none;
    position: absolute;
    inset: 0;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 24px;
    color: var(--text-light);
    font-size: 0.9rem;
}

.hero-placeholder-text code {
    display: block;
    margin-top: 8px;
    font-size: 0.82rem;
    color: var(--primary-dark);
    background: rgba(79, 70, 229, 0.08);
    padding: 4px 10px;
    border-radius: 6px;
}

/* Shown via JS when the hero image fails to load */
.hero-image-wrap.img-missing .hero-image {
    display: none;
}

.hero-image-wrap.img-missing .hero-placeholder-text {
    display: flex;
}

.floating-card {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 10px;
    background: #fff;
    padding: 14px 18px;
    border-radius: 16px;
    box-shadow: 0 16px 32px -12px rgba(15, 23, 42, 0.18);
    font-weight: 600;
    font-size: 0.9rem;
    z-index: 2;
    animation: float 5s ease-in-out infinite;
}

.card-icon {
    font-size: 1.2rem;
}

.card-top {
    top: 8%;
    left: -8%;
    animation-delay: 0s;
}

.card-bottom {
    bottom: 10%;
    right: -6%;
    animation-delay: 2.5s;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/* ---------- Trust line ---------- */
.trust-line {
    padding: 8px 0 56px;
    text-align: center;
}

.trust-card {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid var(--border);
    box-shadow: 0 8px 20px -12px rgba(15, 23, 42, 0.15);
}

.trust-flag {
    font-size: 1.15rem;
    line-height: 1;
}

.trust-line p {
    font-size: 0.9rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: var(--text-light);
}

/* ---------- Services ---------- */
.services {
    padding: 80px 0 120px;
    background: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%);
}

.services .eyebrow {
    background: rgba(255, 255, 255, 0.08);
    color: #a5b4fc;
}

.services .section-head h2 {
    color: #fff;
}

.services .section-head h2 .highlight {
    color: #818cf8;
}

.services .section-head p {
    color: #94a3b8;
}

.services .service-card {
    background-color: rgba(255, 255, 255, 0.04);
    background-image: radial-gradient(rgba(255, 255, 255, 0.15) 1px, transparent 1px);
    background-size: 16px 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.services .service-card:hover {
    border-color: rgba(255, 255, 255, 0.18);
    box-shadow: 0 20px 40px -16px rgba(0, 0, 0, 0.45);
}

.services .service-icon {
    background: linear-gradient(135deg, rgba(129, 140, 248, 0.18), rgba(34, 211, 238, 0.18));
}

.services .service-card h3 {
    color: #fff;
}

.services .service-card p {
    color: #94a3b8;
}

.section-head {
    max-width: 620px;
    margin: 0 auto 56px;
    text-align: center;
}

.section-head .eyebrow {
    margin-bottom: 16px;
}

.section-head h2 {
    font-size: clamp(1.8rem, 3vw, 2.4rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.2;
    margin-bottom: 16px;
}

.section-head h2 .highlight {
    color: var(--primary);
}

.section-head p {
    color: var(--text-light);
    font-size: 1.05rem;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.service-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 32px 24px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.service-card:hover {
    transform: translateY(-4px);
    border-color: transparent;
    box-shadow: 0 20px 40px -16px rgba(15, 23, 42, 0.15);
}

.service-icon {
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.12), rgba(6, 182, 212, 0.12));
    margin-bottom: 20px;
}

.service-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.service-card p {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.55;
}

/* ---------- About ---------- */
.about {
    padding: 120px 0;
}

.about-inner {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    align-items: center;
    gap: 64px;
}

.about-image-wrap {
    position: relative;
    width: 100%;
    overflow: hidden;
}

.about-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.about-image-wrap.img-missing .about-image {
    display: none;
}

.about-image-wrap.img-missing .hero-placeholder-text {
    display: flex;
}

.about-content .eyebrow {
    margin-bottom: 20px;
}

.about-content h2 {
    font-size: clamp(1.8rem, 3vw, 2.4rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.2;
    margin-bottom: 20px;
}

.about-content h2 .highlight {
    color: var(--primary);
}

.about-content p {
    color: var(--text-light);
    font-size: 1.05rem;
    margin-bottom: 18px;
}

.about-pillars {
    margin-top: 28px;
}

.about-pillar {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 20px 0;
    border-top: 1px solid var(--border);
}

.about-pillar strong {
    font-size: 1.05rem;
    font-weight: 700;
}

.about-pillar span {
    color: var(--text-light);
    font-size: 0.92rem;
}

/* ---------- Why Choose Us ---------- */
.why-choose {
    padding: 40px 0 120px;
    background: var(--bg-soft);
}

.why-choose-media {
    max-width: 1200px;
    margin: 0 auto 64px;
    padding: 0 24px;
}

.why-choose-image-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 21 / 9;
    border-radius: 16px;
    overflow: hidden;
}

.why-choose-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.why-choose-image-wrap.img-missing .why-choose-image {
    display: none;
}

.why-choose-image-wrap.img-missing .hero-placeholder-text {
    display: flex;
}

.why-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px 32px;
}

.why-item {
    display: flex;
    flex-direction: column;
}

.why-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.12), rgba(6, 182, 212, 0.12));
    margin-bottom: 18px;
}

.why-item h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.why-item p {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.55;
}

/* ---------- Robotics ---------- */
.robotics {
    padding: 40px 0 120px;
}

.robotics-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 48px;
}

.robotics-card {
    position: relative;
}

.robotics-image-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    border-radius: 16px;
    overflow: hidden;
}

.robotics-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.robotics-image-wrap.img-missing .robotics-image {
    display: none;
}

.robotics-image-wrap.img-missing .hero-placeholder-text {
    display: flex;
}

.robotics-label {
    display: inline-block;
    margin-top: 14px;
    font-weight: 700;
    font-size: 1rem;
}

.robotics-cta {
    text-align: center;
}

/* ---------- Apps ---------- */
.apps {
    padding: 40px 0 120px;
    background-color: var(--bg-soft);
    background-image:
        linear-gradient(to right, rgba(15, 23, 42, 0.05) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(15, 23, 42, 0.05) 1px, transparent 1px);
    background-size: 32px 32px;
}

.apps-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px;
}

.app-badge {
    padding: 12px 24px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: #fff;
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text);
    transition: transform 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.app-badge:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
    color: var(--primary);
}

/* ---------- Contact ---------- */
.contact {
    padding: 40px 0 0;
}

.contact-info {
    display: flex;
    justify-content: center;
    gap: 56px;
    flex-wrap: wrap;
    margin-bottom: 56px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 16px;
}

.contact-icon {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.12), rgba(6, 182, 212, 0.12));
}

.contact-item strong {
    display: block;
    font-size: 1rem;
    margin-bottom: 2px;
}

.contact-item span {
    color: var(--text-light);
    font-size: 0.92rem;
}

.contact-map {
    width: 100%;
    height: 380px;
    overflow: hidden;
}

.contact-map-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* ---------- Footer ---------- */
.footer {
    background: #0f172a;
    color: #94a3b8;
    padding: 64px 0 0;
}

.footer-inner {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 48px;
    padding-bottom: 48px;
}

.footer-brand .logo {
    color: #fff;
}

.footer-brand p {
    margin-top: 14px;
    font-size: 0.92rem;
    line-height: 1.6;
    max-width: 320px;
}

.footer-links h4,
.footer-contact h4 {
    color: #fff;
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 18px;
}

.footer-links {
    display: flex;
    flex-direction: column;
}

.footer-links a {
    font-size: 0.92rem;
    padding: 6px 0;
    transition: color 0.15s ease;
}

.footer-links a:hover {
    color: #fff;
}

.footer-contact {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-contact span {
    font-size: 0.92rem;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 24px 0;
}

.footer-bottom p {
    text-align: center;
    font-size: 0.85rem;
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

    .about-inner {
        grid-template-columns: 1fr;
        gap: 48px;
        text-align: center;
    }

    .about-image-wrap {
        max-width: 420px;
        margin: 0 auto;
    }

    .about-pillar {
        text-align: left;
    }

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

    .contact-map {
        height: 260px;
    }

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

    .hero-sub {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-actions,
    .hero-stats {
        justify-content: center;
    }

    .hero-media {
        order: -1;
    }

    .hero-image-wrap {
        max-width: 380px;
    }

    .card-top { left: 0; }
    .card-bottom { right: 0; }
}

@media (max-width: 720px) {
    .services-grid {
        grid-template-columns: 1fr;
    }

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

    .robotics-gallery {
        grid-template-columns: 1fr;
    }

    .contact-info {
        flex-direction: column;
        align-items: center;
        gap: 24px;
    }

    .footer-inner {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 36px;
    }

    .footer-brand p {
        margin-left: auto;
        margin-right: auto;
    }

    .footer-contact {
        align-items: center;
    }

    .nav-links {
        position: absolute;
        top: 76px;
        left: 0;
        right: 0;
        background: #fff;
        border-bottom: 1px solid var(--border);
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
        padding: 8px 24px 16px;
        transform: translateY(-8px);
        opacity: 0;
        pointer-events: none;
        transition: transform 0.2s ease, opacity 0.2s ease;
    }

    .nav-links.open {
        transform: translateY(0);
        opacity: 1;
        pointer-events: auto;
    }

    .nav-links a {
        padding: 12px 0;
        width: 100%;
        border-bottom: 1px solid var(--border);
    }

    .nav-cta {
        display: none;
    }

    .menu-toggle {
        display: flex;
    }

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