/* CSS RESET & VARIABLES */
:root {
    --bg-primary: #050508;
    --bg-surface: rgba(18, 18, 26, 0.6);
    --border-glass: rgba(255, 255, 255, 0.08);
    --accent-cyan: #00f0ff;
    --accent-purple: #7000ff;
    --accent-pink: #ff007f;
    --text-main: #f0f2f5;
    --text-muted: #8c92a4;
    --font-heading: 'Syncopate', sans-serif;
    --font-body: 'Space Grotesk', sans-serif;
    --transition-smooth: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--bg-primary);
    color: var(--text-main);
    font-family: var(--font-body);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

body.no-scroll {
    overflow: hidden;
}

/* CUSTOM SCROLLBAR */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
    background: #1a1a24;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--accent-purple);
}

/* LOADING SCREEN */
#loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: var(--bg-primary);
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

.loader-content {
    text-align: center;
    width: 300px;
}

.loader-logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    letter-spacing: 4px;
    margin-bottom: 10px;
    background: linear-gradient(135deg, #fff, var(--text-muted));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.loader-status {
    font-size: 0.75rem;
    color: var(--text-muted);
    letter-spacing: 2px;
    margin-bottom: 25px;
}

.loader-progress-bar {
    width: 100%;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
    position: relative;
}

.loader-progress-fill {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--accent-purple), var(--accent-cyan));
    transition: width 0.2s ease;
}

.loader-percentage {
    margin-top: 15px;
    font-size: 0.9rem;
    font-family: var(--font-heading);
    color: var(--accent-cyan);
}

/* CUSTOM CURSOR */
@media (hover: hover) and (pointer: fine) {
    body {
        cursor: none;
    }
    .custom-cursor {
        position: fixed;
        top: 0;
        left: 0;
        width: 8px;
        height: 8px;
        background: #fff;
        border-radius: 50%;
        pointer-events: none;
        z-index: 9999;
        transform: translate(-50%, -50%);
        transition: transform 0.1s ease, width 0.2s ease, height 0.2s ease, background 0.2s ease;
    }
    .cursor-follower {
        position: fixed;
        top: 0;
        left: 0;
        width: 36px;
        height: 36px;
        border: 1px solid rgba(0, 240, 255, 0.4);
        border-radius: 50%;
        pointer-events: none;
        z-index: 9998;
        transform: translate(-50%, -50%);
        transition: transform 0.15s ease-out, width 0.2s ease, height 0.2s ease, border-color 0.2s ease;
    }
    body:hover .custom-cursor {
        opacity: 1;
    }
}

/* NAVIGATION */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 20px 0;
    transition: background 0.3s ease, backdrop-filter 0.3s ease, padding 0.3s ease;
}

header.scrolled {
    background: rgba(5, 5, 8, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-glass);
    padding: 15px 0;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    gap: 10px;
}

.logo-icon {
    width: 12px;
    height: 12px;
    background: var(--accent-cyan);
    box-shadow: 0 0 12px var(--accent-cyan);
    transform: rotate(45deg);
}

.logo-text {
    font-family: var(--font-heading);
    font-weight: 700;
    letter-spacing: 3px;
    color: #fff;
    font-size: 1.1rem;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 40px;
}

.nav-link {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-family: var(--font-heading);
    letter-spacing: 2px;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-cyan);
    transition: width 0.3s var(--transition-smooth);
}

.nav-link:hover, .nav-link.active {
    color: #fff;
}

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 28px;
    height: 20px;
    cursor: pointer;
    z-index: 1001;
}

.hamburger span {
    display: block;
    width: 100%;
    height: 2px;
    background: #fff;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* CANVAS CONTAINERS */
.canvas-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

#heroCanvasContainer, #envCanvasContainer, #ctaCanvasContainer {
    pointer-events: auto;
}

/* SECTION COMMON STYLES */
section {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 100px 0;
    overflow: hidden;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    width: 100%;
    position: relative;
    z-index: 2;
}

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

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

.section-tag {
    display: inline-block;
    font-family: var(--font-heading);
    font-size: 0.75rem;
    letter-spacing: 3px;
    color: var(--accent-cyan);
    margin-bottom: 15px;
}

.section-title {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: 700;
    letter-spacing: 2px;
    line-height: 1.1;
    margin-bottom: 20px;
}

.section-desc {
    color: var(--text-muted);
    font-size: 1.05rem;
    max-width: 600px;
    line-height: 1.6;
}

/* GLASSMORPHISM CARD */
.glass-card {
    background: var(--bg-surface);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-glass);
    border-radius: 16px;
    padding: 30px;
    transition: transform 0.4s var(--transition-smooth), border-color 0.4s ease, box-shadow 0.4s ease;
}

.glass-card:hover {
    border-color: rgba(0, 240, 255, 0.3);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 0 0 20px rgba(0, 240, 255, 0.1);
}

/* HERO SECTION */
.hero-section {
    height: 100vh;
    padding: 0;
}

.hero-content {
    max-width: 800px;
}

.hero-badge {
    display: inline-block;
    padding: 6px 14px;
    background: rgba(0, 240, 255, 0.08);
    border: 1px solid rgba(0, 240, 255, 0.2);
    border-radius: 50px;
    font-family: var(--font-heading);
    font-size: 0.7rem;
    letter-spacing: 2px;
    color: var(--accent-cyan);
    margin-bottom: 25px;
}

.hero-title {
    font-family: var(--font-heading);
    font-size: clamp(3rem, 7vw, 6rem);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: 2px;
    margin-bottom: 20px;
}

.gradient-text {
    background: linear-gradient(135deg, var(--accent-cyan), var(--accent-purple), var(--accent-pink));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    font-size: clamp(1rem, 1.5vw, 1.25rem);
    color: var(--text-muted);
    margin-bottom: 40px;
    line-height: 1.5;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

/* BUTTONS */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 16px 32px;
    border-radius: 50px;
    font-family: var(--font-heading);
    font-size: 0.8rem;
    letter-spacing: 2px;
    text-decoration: none;
    font-weight: 700;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: #fff;
    color: var(--bg-primary);
}

.btn-primary:hover {
    background: var(--accent-cyan);
    box-shadow: 0 0 30px rgba(0, 240, 255, 0.5);
    transform: translateY(-2px);
}

.btn-secondary {
    background: transparent;
    color: #fff;
    border: 1px solid var(--border-glass);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    border-color: #fff;
    background: rgba(255, 255, 255, 0.05);
    transform: translateY(-2px);
}

.btn-large {
    padding: 20px 45px;
    font-size: 0.9rem;
}

/* SCROLL INDICATOR */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    z-index: 3;
    opacity: 0.7;
}

.mouse {
    width: 24px;
    height: 40px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    display: flex;
    justify-content: center;
    padding-top: 6px;
}

.wheel {
    width: 3px;
    height: 8px;
    background: var(--accent-cyan);
    border-radius: 2px;
    animation: scrollWheel 2s infinite;
}

@keyframes scrollWheel {
    0% { transform: translateY(0); opacity: 1; }
    100% { transform: translateY(12px); opacity: 0; }
}

.scroll-indicator span {
    font-family: var(--font-heading);
    font-size: 0.6rem;
    letter-spacing: 2px;
    color: var(--text-muted);
}

/* FEATURES SECTION */
.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.feature-card {
    position: relative;
    height: 380px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    overflow: hidden;
}

.feature-canvas-wrap {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 70%;
}

.feature-info {
    position: relative;
    z-index: 2;
}

.feature-info h3 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.feature-info p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* ENVIRONMENT SECTION */
.environment-section {
    min-height: 100vh;
    padding: 0;
}

.env-overlay-content {
    display: flex;
    justify-content: flex-start;
}

.env-text-box {
    max-width: 500px;
}

.env-text-box h2 {
    font-family: var(--font-heading);
    font-size: 2rem;
    letter-spacing: 1px;
    margin: 15px 0;
}

.env-text-box p {
    color: var(--text-muted);
    line-height: 1.6;
}

/* CARDS SECTION */
.interactive-cards-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.glass-card-3d {
    background: var(--bg-surface);
    backdrop-filter: blur(16px);
    border: 1px solid var(--border-glass);
    border-radius: 20px;
    padding: 40px 30px;
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.glass-card-3d:hover {
    border-color: var(--accent-cyan);
}

.card-num {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.05);
    margin-bottom: 20px;
}

.glass-card-3d h3 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    margin-bottom: 15px;
    letter-spacing: 1px;
}

.glass-card-3d p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* TECH SECTION */
.tech-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

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

.tech-val {
    display: block;
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--accent-cyan);
    margin-bottom: 10px;
    letter-spacing: 1px;
}

.tech-item p {
    color: var(--text-muted);
    font-size: 0.85rem;
    line-height: 1.5;
}

/* CTA SECTION */
.cta-section {
    min-height: 80vh;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cta-content {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.cta-content h2 {
    font-family: var(--font-heading);
    font-size: clamp(2.2rem, 4.5vw, 4rem);
    letter-spacing: 2px;
    margin: 15px 0 20px;
    max-width: 900px;
    line-height: 1.1;
}

.cta-content p {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 40px;
}

/* FOOTER */
footer {
    padding: 40px 0;
    border-top: 1px solid var(--border-glass);
    background: var(--bg-primary);
}

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

.footer-logo {
    font-family: var(--font-heading);
    font-size: 0.9rem;
    letter-spacing: 3px;
    color: #fff;
}

footer p {
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* MOBILE RESPONSIVE STYLING */
@media (max-width: 1024px) {
    .features-grid {
        grid-template-columns: 1fr;
    }
    .tech-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .interactive-cards-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 100%;
        height: 100vh;
        background: rgba(5, 5, 8, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 30px;
        transition: right 0.4s var(--transition-smooth);
        z-index: 1000;
    }
    .nav-links.active {
        right: 0;
    }
    .nav-link {
        font-size: 1.2rem;
    }
    .hamburger {
        display: flex;
    }
    .hamburger.active span:nth-child(1) {
        transform: translateY(9px) rotate(45deg);
    }
    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }
    .hamburger.active span:nth-child(3) {
        transform: translateY(-9px) rotate(-45deg);
    }
    .container {
        padding: 0 20px;
    }
    .tech-grid {
        grid-template-columns: 1fr;
    }
    .footer-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
}