:root {
    --color-primary: #0A192F; /* Dark Blue */
    --color-secondary: #00C1FF; /* Electric Blue */
    --color-accent: #FF00FF; /* Bright Magenta */
    --color-text: #E6F0F6; /* Light Grey/Blue */
    --color-darker-bg: #06101D; /* Even darker blue */
    --color-white: #FFFFFF;

    --font-heading: 'Orbitron', sans-serif;
    --font-body: 'Poppins', sans-serif;

    --max-width: 1200px;
    --section-spacing: 100px; /* Default for larger screens */
    --border-radius-lg: 15px;
    --border-radius-md: 10px;
    --transition-speed: 0.4s ease-in-out;
}

/* Base Styles */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-primary);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: var(--color-secondary);
    text-decoration: none;
    transition: color var(--transition-speed);
}

a:hover {
    color: var(--color-accent);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--color-white);
    margin-bottom: 0.8em;
    line-height: 1.2;
}

h1 { font-size: 3.5rem; }
h2 { font-size: 2.8rem; }
h3 { font-size: 2.2rem; }
h4 { font-size: 1.8rem; }

p {
    margin-bottom: 1em;
}

/* Utility Classes */
.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
}

.section-padding {
    padding: var(--section-spacing) 0;
}

.bg-darker {
    background-color: var(--color-darker-bg);
}

.img-fluid {
    width: 100%;
    height: auto;
    border-radius: var(--border-radius-lg);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.section-title {
    text-align: center;
    font-size: 3rem;
    margin-bottom: 0.5em;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--color-secondary), var(--color-accent));
    margin: 15px auto 0;
    border-radius: 2px;
}

.section-subtitle {
    text-align: center;
    font-size: 1.2rem;
    color: var(--color-text);
    margin-bottom: 3em;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* Header & Navigation */
.header {
    background: rgba(10, 25, 47, 0.8); /* Semi-transparent dark blue */
    backdrop-filter: blur(10px);
    position: fixed;
    width: 100%;
    top: 0;
    left: 0;
    z-index: 1000;
    padding: 1rem 0;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
    color: var(--color-white);
    text-transform: uppercase;
    letter-spacing: 2px;
    background: linear-gradient(90deg, var(--color-secondary), var(--color-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

.nav-menu {
    display: flex;
    gap: 2.5rem;
}

.nav-link {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--color-text);
    position: relative;
    padding: 5px 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background: var(--color-accent);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.nav-toggle {
    display: none;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 10px;
    position: relative;
    z-index: 1100; /* Ensure it's above the menu when open */
}

.nav-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--color-white);
    margin: 5px 0;
    transition: all 0.3s ease-in-out;
    border-radius: 2px;
}

/* Mobile Nav Toggle Animation */
body.nav-open .nav-toggle span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}
body.nav-open .nav-toggle span:nth-child(2) {
    opacity: 1;
}
body.nav-open .nav-toggle span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* Hero Section */
.hero-section {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    color: var(--color-white);
}

.hero-bg-parallax {
    position: absolute;
    top: -50px; /* Adjust for parallax starting point */
    left: 0;
    width: 100%;
    height: calc(100% + 100px); /* Extend height for parallax movement */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 1;
    transform: translateY(0); /* Initial state for JS parallax */
}

.hero-bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(10, 25, 47, 0.8) 0%, rgba(6, 16, 29, 0.9) 100%);
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 3;
    max-width: 800px;
}

.hero-content h1 {
    font-size: 5rem;
    font-weight: 700;
    margin-bottom: 0.3em;
    text-shadow: 0 0 20px rgba(0, 193, 255, 0.7);
    animation: fadeInScale 1.5s ease-out forwards;
}

.hero-content p {
    font-size: 1.5rem;
    font-weight: 300;
    line-height: 1.5;
    opacity: 1;
    animation: fadeIn 1.5s ease-out 0.5s forwards;
}

@keyframes fadeInScale {
    from { opacity: 1; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes fadeIn {
    from { opacity: 1; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Grid Layouts */
.grid-2-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.grid-2-col-reverse {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}
.grid-2-col-reverse .community-content { order: 1; }
.grid-2-col-reverse .community-image { order: 2; }


/* About Section */
.about-image {
    position: relative;
}

.about-image img {
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
    transition: transform 0.6s ease;
}
.about-image:hover img {
    transform: translateY(-10px);
}

.about-content h2 {
    color: var(--color-secondary);
    font-size: 1.2rem;
    font-weight: 400;
    margin-bottom: 0.5em;
    text-transform: uppercase;
    letter-spacing: 2px;
}
.about-content h3 {
    font-size: 2.5rem;
    background: linear-gradient(90deg, var(--color-white), var(--color-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1em;
}

/* Portfolio Section */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.portfolio-item {
    position: relative;
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.portfolio-item:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 30px var(--color-secondary);
}

.portfolio-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.portfolio-item:hover img {
    transform: scale(1.1);
}

.item-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0.8) 100%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 20px;
    color: var(--color-white);
    opacity: 1;
    transition: opacity 0.4s ease;
}

.portfolio-item:hover .item-overlay {
    opacity: 1;
}

.item-overlay h3 {
    font-size: 1.8rem;
    margin-bottom: 0.5em;
    background: linear-gradient(90deg, var(--color-secondary), var(--color-white));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.item-overlay p {
    font-size: 1rem;
    margin-bottom: 0;
}

/* Community Section - similar to About, but maybe different emphasis */
.community-content h2 {
    color: var(--color-accent);
    font-size: 1.2rem;
    font-weight: 400;
    margin-bottom: 0.5em;
    text-transform: uppercase;
    letter-spacing: 2px;
}
.community-content h3 {
    font-size: 2.5rem;
    background: linear-gradient(90deg, var(--color-white), var(--color-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 1em;
}

.community-image img {
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
    transition: transform 0.6s ease;
}
.community-image:hover img {
    transform: translateY(10px);
}

/* Vision Section */
.vision-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-top: 50px;
}

.vision-item {
    text-align: center;
    background: rgba(0, 193, 255, 0.05); /* Very subtle transparent secondary color */
    padding: 30px;
    border-radius: var(--border-radius-lg);
    border: 1px solid rgba(0, 193, 255, 0.1);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
    transition: all 0.4s ease;
}

.vision-item:hover {
    background: rgba(0, 193, 255, 0.15);
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 10px 30px rgba(0, 193, 255, 0.2);
}

.vision-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    color: var(--color-accent);
    text-shadow: 0 0 10px var(--color-accent);
    transition: transform 0.3s ease;
}

.vision-item:hover .vision-icon {
    transform: scale(1.1) rotate(5deg);
}

.vision-item h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    background: linear-gradient(90deg, var(--color-white), var(--color-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Footer */
.footer {
    background-color: var(--color-darker-bg);
    color: var(--color-text);
    text-align: center;
    padding: 3rem 0;
    border-top: 1px solid rgba(0, 193, 255, 0.1);
}

.footer .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.footer-links {
    display: flex;
    gap: 30px;
}

.footer-links a {
    font-weight: 600;
    font-size: 1rem;
    position: relative;
}

.footer-links a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -5px;
    width: 0;
    height: 1px;
    background: var(--color-secondary);
    transition: width 0.3s ease;
}

.footer-links a:hover::after {
    width: 100%;
}


/* Scroll Reveal Animations */
.reveal, .reveal-left, .reveal-right, .reveal-bottom {
    opacity: 1;
    transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94), transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.reveal {
    transform: translateY(50px);
}

.reveal-left {
    transform: translateX(-50px);
}

.reveal-right {
    transform: translateX(50px);
}

.reveal-bottom {
    transform: translateY(30px);
}

.reveal.active, .reveal-left.active, .reveal-right.active, .reveal-bottom.active {
    opacity: 1;
    transform: translate(0, 0);
}

/* Staggered delays for children elements, applies only when parent .reveal is active */
.portfolio-item.delay-1 { transition-delay: 0.1s; }
.portfolio-item.delay-2 { transition-delay: 0.2s; }
.portfolio-item.delay-3 { transition-delay: 0.3s; }
.vision-item.delay-1 { transition-delay: 0.1s; }
.vision-item.delay-2 { transition-delay: 0.2s; }
.vision-item.delay-3 { transition-delay: 0.3s; }


/* Mobile Responsiveness */
@media (max-width: 992px) {
    h1 { font-size: 4rem; }
    h2 { font-size: 2.2rem; }
    h3 { font-size: 1.8rem; }
    .hero-content p { font-size: 1.2rem; }
    .section-title { font-size: 2.5rem; }
    .section-subtitle { font-size: 1rem; }
    .section-padding { padding: 80px 0; }
}

@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%; /* Start off-screen */
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background: var(--color-primary);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: right 0.4s ease-in-out;
        box-shadow: -5px 0 15px rgba(0, 0, 0, 0.4);
        z-index: 999;
    }

    body.nav-open .nav-menu {
        right: 0; /* Slide in */
    }

    .nav-toggle {
        display: block;
    }

    .nav-link {
        font-size: 1.5rem;
        margin-bottom: 25px;
        opacity: 1; /* Start hidden */
        transform: translateX(20px);
        transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
    }

    body.nav-open .nav-link {
        opacity: 1;
        transform: translateX(0);
    }
    body.nav-open .nav-link:nth-child(1) { transition-delay: 0.2s; }
    body.nav-open .nav-link:nth-child(2) { transition-delay: 0.3s; }
    body.nav-open .nav-link:nth-child(3) { transition-delay: 0.4s; }
    body.nav-open .nav-link:nth-child(4) { transition-delay: 0.5s; }
    body.nav-open .nav-link:nth-child(5) { transition-delay: 0.6s; }


    .grid-2-col, .grid-2-col-reverse {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .grid-2-col-reverse .community-content,
    .grid-2-col-reverse .community-image {
        order: unset; /* Reset order for mobile */
    }

    .about-image, .community-image {
        text-align: center;
    }

    .about-content, .community-content {
        text-align: center;
    }

    .hero-content h1 { font-size: 3rem; }
    .hero-content p { font-size: 1rem; }
    .section-padding { padding: 60px 0; }
    .vision-grid {
        grid-template-columns: 1fr;
    }
    .footer .container {
        flex-direction: column;
    }
    .footer-links {
        flex-direction: column;
        gap: 15px;
    }
}

@media (max-width: 480px) {
    h1 { font-size: 2.5rem; }
    h2 { font-size: 2rem; }
    h3 { font-size: 1.5rem; }
    .section-title { font-size: 2rem; }
    .logo { font-size: 1.8rem; }
    .hero-content p { font-size: 0.9rem; }
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
    .vision-item h3 { font-size: 1.3rem; }
}

/* Accessibility */
.nav-toggle:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
}
a:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
    border-radius: 2px;
}

/* Visible state helpers */
+ .animate-fade-in-up.visible,
+ .animate-fade-in-left.visible,
+ .animate-fade-in-right.visible,
+ .animate-bounce-y.visible,
+ .section-scroll-animate.visible,
+ .text-animate-up.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Safe visibility overrides (auto-added) */
:root, html, body, main, header, footer, section, .container, .content {
  opacity: 1 !important;
  visibility: visible !important;
}
