/* Reset and Base Styles */
:root {
    --primary-color: #0a192f;
    /* Deep Navy */
    --secondary-color: #64ffda;
    /* Cyan/Teal Accent */
    --text-color: #8892b0;
    /* Muted Blue/Grey */
    --heading-color: #ccd6f6;
    /* Light Grey/White */
    --bg-color: #020c1b;
    /* Very Dark Navy */
    --card-bg: #112240;
    /* Lighter Navy for cards */
    --white: #ffffff;
    --steel-grey: #e6e6e6;
    --transition: all 0.3s ease-in-out;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Typography */
h1,
h2,
h3 {
    font-family: 'Oswald', sans-serif;
    color: var(--heading-color);
    text-transform: uppercase;
    letter-spacing: 1px;
}

h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 20px;
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--white);
}

p {
    margin-bottom: 20px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 4px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: var(--transition);
    border: 1px solid transparent;
}

.btn-primary {
    background-color: transparent;
    color: var(--secondary-color);
    border-color: var(--secondary-color);
}

.btn-primary:hover {
    background-color: rgba(100, 255, 218, 0.1);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(10, 25, 47, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 20px 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: 'Oswald', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--secondary-color);
    letter-spacing: 2px;
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links a {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--heading-color);
}

.nav-links a:hover {
    color: var(--secondary-color);
}

.hamburger {
    display: none;
    cursor: pointer;
}

/* Hero Section */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding-top: 80px;
    /* Navbar height */
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.4;
    /* Darken image for text readability */
    filter: brightness(0.6) contrast(1.2);
}

.hero-content {
    text-align: center;
    max-width: 800px;
    z-index: 1;
    animation: fadeInUp 1s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Sections General */
.section {
    padding: 100px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.line {
    width: 60px;
    height: 4px;
    background-color: var(--secondary-color);
    margin: 0 auto;
}

/* About Section */
.about {
    background-color: var(--bg-color);
}

.about-content {
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.feature-card {
    background-color: var(--card-bg);
    padding: 30px;
    border-radius: 4px;
    transition: var(--transition);
    border: 1px solid transparent;
}

.feature-card:hover {
    transform: translateY(-5px);
    border-color: var(--secondary-color);
}

/* Products Section */
.products {
    background-color: #0a192f;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.product-card {
    background-color: var(--card-bg);
    border-radius: 8px;
    overflow: hidden;
    transition: var(--transition);
    box-shadow: 0 10px 30px -15px rgba(2, 12, 27, 0.7);
}

.product-card:hover {
    transform: translateY(-10px);
}

.product-image {
    height: 250px;
    overflow: hidden;
    background-color: #fff;
    /* White bg for product shots */
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 20px;
    transition: transform 0.5s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-info {
    padding: 30px;
}

.specs-list {
    margin-top: 15px;
    font-size: 0.9rem;
}

.specs-list li {
    margin-bottom: 8px;
    border-bottom: 1px solid rgba(136, 146, 176, 0.1);
    padding-bottom: 8px;
}

.specs-list li:last-child {
    border-bottom: none;
}

.specs-list strong {
    color: var(--secondary-color);
    margin-right: 5px;
}

.text-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
    border: 1px solid var(--secondary-color);
    background-color: transparent;
}

/* Specs Table Section */
.specs {
    background-color: var(--bg-color);
}

.table-responsive {
    overflow-x: auto;
}

.tech-table {
    width: 100%;
    border-collapse: collapse;
    background-color: var(--card-bg);
    border-radius: 8px;
    overflow: hidden;
}

.tech-table th,
.tech-table td {
    padding: 20px;
    text-align: left;
    border-bottom: 1px solid rgba(136, 146, 176, 0.1);
}

.tech-table th {
    background-color: rgba(100, 255, 218, 0.1);
    color: var(--secondary-color);
    font-family: 'Oswald', sans-serif;
    font-weight: 500;
    text-transform: uppercase;
}

.tech-table tr:last-child td {
    border-bottom: none;
}

.tech-table tr:hover {
    background-color: rgba(136, 146, 176, 0.05);
}

/* Contact Section */
.contact {
    background-color: #0a192f;
    text-align: center;
}

.contact-wrapper {
    max-width: 600px;
    margin: 0 auto;
}

.contact-details {
    margin-top: 40px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.contact-item {
    background-color: var(--card-bg);
    padding: 20px;
    border-radius: 4px;
    color: var(--heading-color);
}

.contact-item strong {
    color: var(--secondary-color);
    display: block;
    margin-bottom: 5px;
    font-family: 'Oswald', sans-serif;
}

/* Footer */
footer {
    background-color: var(--bg-color);
    padding: 30px 0;
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-color);
    border-top: 1px solid rgba(136, 146, 176, 0.1);
}

/* Responsive */
@media (max-width: 768px) {
    h1 {
        font-size: 2.5rem;
    }

    .nav-links {
        display: none;
        /* Mobile menu implementation omitted for simplicity, can be added if needed */
    }

    .hamburger {
        display: block;
    }

    .hero-content {
        padding: 0 20px;
    }
}

/* Technology Modal */
.tech-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(2, 12, 27, 0.95);
    backdrop-filter: blur(10px);
    animation: fadeIn 0.5s ease;
}

.tech-modal-content {
    position: relative;
    margin: 5% auto;
    padding: 40px;
    width: 90%;
    max-width: 1200px;
    border: 1px solid var(--secondary-color);
    box-shadow: 0 0 20px rgba(100, 255, 218, 0.2), inset 0 0 20px rgba(100, 255, 218, 0.1);
    background: linear-gradient(135deg, rgba(10, 25, 47, 0.9) 0%, rgba(2, 12, 27, 0.95) 100%);
    border-radius: 8px;
    overflow: hidden;
}

/* Scanline Effect */
.tech-modal-content::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, transparent 50%, rgba(100, 255, 218, 0.05) 50%);
    background-size: 100% 4px;
    pointer-events: none;
    z-index: 10;
}

.tech-modal-content::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background-color: rgba(100, 255, 218, 0.5);
    box-shadow: 0 0 10px var(--secondary-color);
    animation: scanline 3s linear infinite;
    opacity: 0.5;
    pointer-events: none;
    z-index: 11;
}

@keyframes scanline {
    0% {
        top: -5%;
        opacity: 0;
    }

    10% {
        opacity: 0.5;
    }

    90% {
        opacity: 0.5;
    }

    100% {
        top: 105%;
        opacity: 0;
    }
}

.close-tech {
    color: var(--secondary-color);
    float: right;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    opacity: 0.5;
    pointer-events: none;
    z-index: 11;
}

@keyframes scanline {
    0% {
        top: -5%;
        opacity: 0;
    }

    10% {
        opacity: 0.5;
    }

    90% {
        opacity: 0.5;
    }

    100% {
        top: 105%;
        opacity: 0;
    }
}

.close-tech {
    color: var(--secondary-color);
    float: right;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    transition: var(--transition);
    z-index: 20;
    position: relative;
    text-shadow: 0 0 10px var(--secondary-color);
}

.close-tech:hover {
    color: var(--white);
    text-shadow: 0 0 20px var(--secondary-color);
}

.tech-header {
    text-align: center;
    margin-bottom: 40px;
    position: relative;
    z-index: 2;
}

.tech-header h2 {
    color: var(--secondary-color);
    text-shadow: 0 0 10px rgba(100, 255, 218, 0.5);
    letter-spacing: 4px;
    animation: flicker 2s infinite alternate;
}

.tech-line {
    width: 100px;
    height: 2px;
    background-color: var(--secondary-color);
    margin: 10px auto;
    box-shadow: 0 0 10px var(--secondary-color);
}

@keyframes flicker {

    0%,
    19%,
    21%,
    23%,
    25%,
    54%,
    56%,
    100% {
        opacity: 1;
        text-shadow: 0 0 10px rgba(100, 255, 218, 0.5);
    }

    20%,
    24%,
    55% {
        opacity: 0.5;
        text-shadow: none;
    }
}

.tech-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 40px;
    position: relative;
    z-index: 2;
}

.tech-item {
    position: relative;
    border: 1px solid rgba(100, 255, 218, 0.3);
    padding: 10px;
    background: rgba(10, 25, 47, 0.5);
    overflow: hidden;
    transition: var(--transition);
    animation: slideUp 0.8s ease-out backwards;
}

.tech-item:nth-child(1) {
    animation-delay: 0.2s;
}

.tech-item:nth-child(2) {
    animation-delay: 0.4s;
}

.tech-item:hover {
    border-color: var(--secondary-color);
    box-shadow: 0 0 30px rgba(100, 255, 218, 0.2);
    transform: scale(1.02);
}

.tech-item img {
    width: 100%;
    height: auto;
    display: block;
    filter: contrast(1.1) brightness(1.1);
}

.tech-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, transparent 60%, rgba(10, 25, 47, 0.8) 100%);
    pointer-events: none;
    box-shadow: inset 0 0 20px rgba(100, 255, 218, 0.1);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .tech-modal-content {
        margin: 10% auto;
        padding: 20px;
        width: 95%;
    }

    .tech-gallery {
        grid-template-columns: 1fr;
    }
}

/* Welcome Modal Styles */
.welcome-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(10, 25, 47, 0.95);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    z-index: 2;
}

.tech-header h2 {
    color: var(--secondary-color);
    text-shadow: 0 0 10px rgba(100, 255, 218, 0.5);
    letter-spacing: 4px;
    animation: flicker 2s infinite alternate;
}

.tech-line {
    width: 100px;
    height: 2px;
    background-color: var(--secondary-color);
    margin: 10px auto;
    box-shadow: 0 0 10px var(--secondary-color);
}

@keyframes flicker {

    0%,
    19%,
    21%,
    23%,
    25%,
    54%,
    56%,
    100% {
        opacity: 1;
        text-shadow: 0 0 10px rgba(100, 255, 218, 0.5);
    }

    20%,
    24%,
    55% {
        opacity: 0.5;
        text-shadow: none;
    }
}

.tech-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 40px;
    position: relative;
    z-index: 2;
}

.tech-item {
    position: relative;
    border: 1px solid rgba(100, 255, 218, 0.3);
    padding: 10px;
    background: rgba(10, 25, 47, 0.5);
    overflow: hidden;
    transition: var(--transition);
    animation: slideUp 0.8s ease-out backwards;
}

.tech-item:nth-child(1) {
    animation-delay: 0.2s;
}

.tech-item:nth-child(2) {
    animation-delay: 0.4s;
}

.tech-item:hover {
    border-color: var(--secondary-color);
    box-shadow: 0 0 30px rgba(100, 255, 218, 0.2);
    transform: scale(1.02);
}

.tech-item img {
    width: 100%;
    height: auto;
    display: block;
    filter: contrast(1.1) brightness(1.1);
}

.tech-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, transparent 60%, rgba(10, 25, 47, 0.8) 100%);
    pointer-events: none;
    box-shadow: inset 0 0 20px rgba(100, 255, 218, 0.1);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .tech-modal-content {
        margin: 10% auto;
        padding: 20px;
        width: 95%;
    }

    .tech-gallery {
        grid-template-columns: 1fr;
    }
}

.tech-item:nth-child(1) {
    animation-delay: 0.2s;
}

.tech-item:nth-child(2) {
    animation-delay: 0.4s;
}

.tech-item:nth-child(3) {
    animation-delay: 0.6s;
}

.tech-item:nth-child(4) {
    animation-delay: 0.8s;
}

.tech-item:hover {
    border-color: var(--secondary-color);
    box-shadow: 0 0 30px rgba(100, 255, 218, 0.2);
    transform: scale(1.02);
}

.tech-item img {
    width: 100%;
    height: auto;
    display: block;
    filter: contrast(1.1) brightness(1.1);
}

.tech-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, transparent 60%, rgba(10, 25, 47, 0.8) 100%);
    pointer-events: none;
    box-shadow: inset 0 0 20px rgba(100, 255, 218, 0.1);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .tech-modal-content {
        margin: 10% auto;
        padding: 20px;
        width: 95%;
    }

    .tech-gallery {
        grid-template-columns: 1fr;
    }
}

/* Welcome Modal Styles */
.welcome-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(10, 25, 47, 0.95);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    z-index: 2;
}

.tech-header h2 {
    color: var(--secondary-color);
    text-shadow: 0 0 10px rgba(100, 255, 218, 0.5);
    letter-spacing: 4px;
    animation: flicker 2s infinite alternate;
}

.tech-line {
    width: 100px;
    height: 2px;
    background-color: var(--secondary-color);
    margin: 10px auto;
    box-shadow: 0 0 10px var(--secondary-color);
}

@keyframes flicker {

    0%,
    19%,
    21%,
    23%,
    25%,
    54%,
    56%,
    100% {
        opacity: 1;
        text-shadow: 0 0 10px rgba(100, 255, 218, 0.5);
    }

    20%,
    24%,
    55% {
        opacity: 0.5;
        text-shadow: none;
    }
}

.tech-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 40px;
    position: relative;
    z-index: 2;
}

.tech-item {
    position: relative;
    border: 1px solid rgba(100, 255, 218, 0.3);
    padding: 10px;
    background: rgba(10, 25, 47, 0.5);
    overflow: hidden;
    transition: var(--transition);
    animation: slideUp 0.8s ease-out backwards;
}

.tech-item:nth-child(1) {
    animation-delay: 0.2s;
}

.tech-item:nth-child(2) {
    animation-delay: 0.4s;
}

.tech-item:hover {
    border-color: var(--secondary-color);
    box-shadow: 0 0 30px rgba(100, 255, 218, 0.2);
    transform: scale(1.02);
}

.tech-item img {
    width: 100%;
    height: auto;
    display: block;
    filter: contrast(1.1) brightness(1.1);
}

.tech-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, transparent 60%, rgba(10, 25, 47, 0.8) 100%);
    pointer-events: none;
    box-shadow: inset 0 0 20px rgba(100, 255, 218, 0.1);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .tech-modal-content {
        margin: 10% auto;
        padding: 20px;
        width: 95%;
    }

    .tech-gallery {
        grid-template-columns: 1fr;
    }
}

/* Welcome Modal Styles */
.welcome-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(10, 25, 47, 0.95);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.welcome-modal.show {
    opacity: 1;
    visibility: visible;
}

.welcome-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 600px;
    padding: 2rem;
    text-align: center;
}

.robot-container {
    margin-bottom: 2rem;
    /* animation: float 3s ease-in-out infinite; */
}

.robot-video {
    width: 400px;
    height: 400px;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid #ffffff;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
}

.speech-bubble {
    background: #ffffff;
    color: #0a192f;
    padding: 2rem;
    border-radius: 20px;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    max-width: 100%;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease 0.5s, transform 0.5s ease 0.5s;
}

.welcome-modal.show .speech-bubble {
    opacity: 1;
    transform: translateY(0);
}

.speech-bubble::after {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 0 10px 10px;
    border-style: solid;
    border-color: transparent transparent #ffffff;
}

.speech-bubble h3 {
    margin-bottom: 1rem;
    color: #0a192f;
    font-family: 'Oswald', sans-serif;
}

.speech-bubble p {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    min-height: 80px;
    /* Reserve space for typing text */
}

@keyframes float {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-15px);
    }

    100% {
        transform: translateY(0px);
    }
}

/* Robot container glow animation */
@keyframes pulse-glow {

    0%,
    100% {
        box-shadow: 0 0 40px rgba(100, 255, 218, 0.6), 0 0 80px rgba(100, 255, 218, 0.3);
    }

    50% {
        box-shadow: 0 0 60px rgba(100, 255, 218, 0.8), 0 0 120px rgba(100, 255, 218, 0.5);
    }
}

/* Welcome Modal Styles */
.welcome-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(10, 25, 47, 0.95);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.welcome-modal.show {
    opacity: 1;
    visibility: visible;
}

.welcome-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 600px;
    padding: 2rem;
    text-align: center;
}

.robot-container {
    margin-bottom: 2rem;
    width: 400px;
    height: 350px;
    border-radius: 175px 175px 0 0;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    background: transparent;
    position: relative;
    mask-image: radial-gradient(circle 220px at center 45%, black 60%, transparent 100%);
    -webkit-mask-image: radial-gradient(circle 220px at center 45%, black 60%, transparent 100%);
}

.robot-video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center center;
}

.speech-bubble {
    background: #ffffff;
    color: #0a192f;
    padding: 2rem;
    border-radius: 20px;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    max-width: 100%;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease 0.5s, transform 0.5s ease 0.5s;
}

.welcome-modal.show .speech-bubble {
    opacity: 1;
    transform: translateY(0);
}

.speech-bubble::after {
    content: '';
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 0 10px 10px;
    border-style: solid;
    border-color: transparent transparent #ffffff;
}

.speech-bubble h3 {
    margin-bottom: 1rem;
    color: #0a192f;
    font-family: 'Oswald', sans-serif;
}

.speech-bubble p {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    min-height: 80px;
}

/* Full-width tech item for featured R&D images */
.tech-item-full {
    grid-column: 1 / -1;
}