:root {
    --bg-dark: #020617;
    --bg-deep: #070b14;
    --surface: rgba(15, 23, 42, 0.6);
    --cyan: #22d3ee;
    --cyan-glow: rgba(34, 211, 238, 0.3);
    --pink: #f472b6;
    --violet: #8b5cf6;
    --white: #f8fafc;
    --text-dim: #94a3b8;
    --border: rgba(255, 255, 255, 0.08);
    --glass-border: rgba(255, 255, 255, 0.1);
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-dark);
    color: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--cyan);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--violet);
}

/* Canvas Background */
#canvas-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    pointer-events: none;
}

/* Ambient Background Grid */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(var(--border) 1px, transparent 1px),
        linear-gradient(90deg, var(--border) 1px, transparent 1px);
    background-size: 50px 50px;
    mask-image: radial-gradient(ellipse at center, black, transparent 80%);
    z-index: -1;
    opacity: 0.5;
}

.noise {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://grainy-gradients.vercel.app/noise.svg');
    opacity: 0.05;
    pointer-events: none;
    z-index: 100;
}

h1,
h2,
h3,
h4,
.logo {
    font-family: 'Poppins', sans-serif;
    letter-spacing: -0.02em;
}

.gradient-text {
    background: linear-gradient(135deg, #fff 0%, var(--cyan) 50%, var(--pink) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-size: 200% auto;
    animation: gradientMove 5s linear infinite;
}

@keyframes gradientMove {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

h1,
h2,
h3 {
    line-height: 1.1;
    letter-spacing: -1px;
}

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

section {
    padding: 100px 0;
    border-bottom: 1px solid var(--border);
}

/* --- NAVIGATION --- */
nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(2, 6, 23, 0.7);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: 12px 0;
    transition: all 0.3s ease;
}

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

.logo {
    font-weight: 800;
    font-size: 1.2rem;
    text-decoration: none;
    color: var(--white);
    display: flex;
    align-items: center;
    gap: 6px;
    line-height: 1;
    letter-spacing: -0.5px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 35px;
}

.nav-links a:not(.btn-primary) {
    color: var(--text-dim);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: 0.3s;
}

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

/* --- HERO SECTION --- */
.hero {
    padding: 6rem 20px 4rem;
    /* Adjusted padding for better fit */
    text-align: left;
    overflow: visible;
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
}

.hero-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 60px;
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
}

.hero-content {
    z-index: 10;
    position: relative;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(34, 211, 238, 0.1);
    border: 1px solid rgba(34, 211, 238, 0.3);
    border-radius: 8px;
    /* Slightly softer radius */
    color: var(--cyan);
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 2rem;
    backdrop-filter: blur(5px);
}

.hero h1 {
    font-size: 3.5rem;
    /* Matched demo size */
    line-height: 1.1;
    margin-bottom: 1.5rem;
    font-weight: 800;
}

.hero p {
    font-size: 1.15rem;
    color: var(--text-dim);
    max-width: 550px;
    margin: 0 0 2.5rem;
    line-height: 1.6;
}

.hero-bg-blob {
    position: absolute;
    top: -10%;
    right: -5%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(34, 211, 238, 0.15) 0%, transparent 70%);
    filter: blur(80px);
    z-index: 0;
    pointer-events: none;
    animation: blobFloat 10s infinite alternate;
}

.hero-bg-blob.secondary {
    top: auto;
    bottom: -10%;
    left: -10%;
    right: auto;
    background: radial-gradient(circle, rgba(139, 92, 246, 0.15) 0%, transparent 70%);
    animation-delay: -5s;
}

@keyframes blobFloat {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(30px, 50px) scale(1.1);
    }
}

/* TECH STACK FLOATERS - HERO RIGHT SIDE */
.tech-visuals {
    position: relative;
    height: 500px;
    /* Increased height */
    display: flex;
    align-items: center;
    justify-content: center;
}

.tech-floater {
    position: absolute;
    width: 80px;
    /* Slightly larger */
    height: 80px;
    background: rgba(23, 23, 33, 0.6);
    /* Darker semi-transparent base */
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    animation: techFloat 8s ease-in-out infinite;
    z-index: 2;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.tech-floater::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 1px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2) 0%, rgba(255, 255, 255, 0) 100%);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

.tech-floater:hover {
    transform: scale(1.15) translateY(-5px);
    background: rgba(20, 30, 50, 0.8);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4), 0 0 20px var(--glow-color);
}

.tech-floater img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.2));
}

/* Gemini - Blue Glow */
.tf-1 {
    top: 10%;
    right: 40%;
    animation-delay: 0s;
    --glow-color: rgba(34, 211, 238, 0.4);
}

/* Veo (Video) - Pink Glow */
.tf-2 {
    top: 50%;
    right: 10%;
    animation-delay: 1.5s;
    --glow-color: rgba(244, 114, 182, 0.4);
}

/* Python - Blue/Yellow Glow */
.tf-3 {
    bottom: 20%;
    right: 50%;
    animation-delay: 2s;
    --glow-color: rgba(56, 189, 248, 0.4);
}

/* JS - Yellow Glow */
.tf-4 {
    top: 30%;
    left: 10%;
    animation-delay: 1s;
    --glow-color: rgba(250, 204, 21, 0.4);
}

/* OpenCV (RGB/Shapes) - Green/Red/Blue Glow */
.tf-5 {
    bottom: 10%;
    right: 15%;
    animation-delay: 0.5s;
    --glow-color: rgba(168, 85, 247, 0.4);
}

@keyframes techFloat {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-20px);
    }
}

/* NEW UI SHOWCASE SECTION */
.ui-showcase {
    padding-bottom: 100px;
    perspective: 2000px;
    text-align: center;
}

.main-ui-panel {
    max-width: 1000px;
    width: 90%;
    margin: 0 auto;
    border-radius: 20px;
    border: 1px solid var(--glass-border);
    box-shadow: 0 0 80px rgba(34, 211, 238, 0.15), 0 30px 60px rgba(0, 0, 0, 0.5);
    transform: rotateX(10deg);
    transition: transform 0.5s ease-out;
    background: rgba(2, 6, 23, 0.8);
    backdrop-filter: blur(10px);
    display: block;
}

.main-ui-panel:hover {
    transform: rotateX(0deg) scale(1.02);
    box-shadow: 0 0 100px rgba(34, 211, 238, 0.25), 0 40px 80px rgba(0, 0, 0, 0.6);
}

.mock-line {
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    margin-bottom: 6px;
}

.social-proof {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-top: 30px;
    font-size: 0.9rem;
    color: var(--text-dim);
}

.avatars {
    display: flex;
}

.avatars img {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    border: 2px solid var(--bg-dark);
    margin-left: -10px;
}

.avatars img:first-child {
    margin-left: 0;
}

@media (max-width: 900px) {
    .hero-layout {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .tech-visuals {
        display: none;
    }

    /* Simplify on mobile */
    .main-ui-panel {
        transform: none;
        width: 100%;
    }

    .hero {
        padding-top: 120px;
    }

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

/* --- REVEAL ANIMATION --- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.17, 0.55, 0.55, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
    margin-top: 60px;
}

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

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

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    padding: 40px;
    border-radius: 24px;
    position: relative;
    overflow: hidden;
    transition: 0.4s;
    backdrop-filter: blur(10px);
}

/* Mouse tracking spotlight effect */
.card::after {
    content: "";
    position: absolute;
    top: var(--mouse-y);
    left: var(--mouse-x);
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--cyan-glow), transparent 70%);
    transform: translate(-50%, -50%);
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
    z-index: 0;
}

.card:hover::after {
    opacity: 1;
}

.card * {
    position: relative;
    z-index: 1;
}

.card i {
    color: var(--cyan);
    margin-bottom: 20px;
    display: block;
    filter: drop-shadow(0 0 8px var(--cyan-glow));
    transition: 0.3s;
}

.card:hover i {
    transform: scale(1.1) rotate(5deg);
    color: var(--white);
}

.card h3 {
    margin-bottom: 12px;
    font-size: 1.25rem;
    font-weight: 700;
}

.card p {
    color: var(--text-dim);
    font-size: 0.95rem;
    line-height: 1.7;
}

.card:hover {
    border-color: rgba(34, 211, 238, 0.3);
    transform: translateY(-8px);
    box-shadow: 0 20px 40px -10px rgba(2, 6, 23, 0.5), 0 0 20px rgba(34, 211, 238, 0.1);
}

/* --- Documentation Specific Styles --- */
.doc-section {
    margin-bottom: 60px;
}

.doc-header {
    font-family: 'Poppins', sans-serif;
    color: var(--white);
    margin-bottom: 20px;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.doc-card {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 25px;
    margin-bottom: 25px;
    backdrop-filter: blur(10px);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.doc-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    border-color: rgba(34, 211, 238, 0.3);
}

.doc-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 768px) {
    .doc-grid-2 {
        grid-template-columns: 1fr;
    }
}

/* Custom Tables */
.doc-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
    font-size: 0.95rem;
}

.doc-table th {
    text-align: left;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--pink);
    font-weight: 600;
    border-bottom: 1px solid var(--glass-border);
}

.doc-table td {
    padding: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-dim);
}

.doc-table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
    color: var(--white);
}

/* Workflow Steps */
.step-list {
    list-style: none;
    padding: 0;
    counter-reset: step-counter;
}

.step-item {
    position: relative;
    padding-left: 50px;
    margin-bottom: 20px;
}

.step-item::before {
    counter-increment: step-counter;
    content: counter(step-counter);
    position: absolute;
    left: 0;
    top: 0;
    width: 35px;
    height: 35px;
    background: linear-gradient(135deg, var(--cyan), var(--violet));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: var(--white);
    box-shadow: 0 4px 10px rgba(6, 182, 212, 0.3);
}

.info-box {
    background: rgba(6, 182, 212, 0.1);
    border-left: 4px solid var(--cyan);
    padding: 15px;
    border-radius: 0 8px 8px 0;
    margin: 15px 0;
    font-size: 0.9rem;
}

.badge {
    padding: 6px 14px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    border: 1px solid currentColor;
    letter-spacing: 0.05em;
}

.doc-layout {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 60px;
}

.sidebar {
    position: sticky;
    top: 100px;
    height: fit-content;
}

.sidebar h4 {
    font-size: 0.8rem;
    text-transform: uppercase;
    color: var(--cyan);
    letter-spacing: 2px;
    margin-bottom: 20px;
}

.sidebar ul {
    list-style: none;
}

.sidebar li {
    margin-bottom: 12px;
}

.sidebar li a {
    color: var(--text-dim);
    text-decoration: none;
    font-size: 0.95rem;
    transition: 0.2s;
}

.sidebar li a:hover {
    color: var(--white);
    padding-left: 5px;
}

.sidebar li a.active {
    color: var(--cyan);
    padding-left: 10px;
    border-left: 2px solid var(--cyan);
    font-weight: 600;
}

@media (max-width: 900px) {
    .doc-layout {
        grid-template-columns: 1fr;
    }

    .sidebar {
        display: none;
    }
}

/* Typewriter Cursor */
.cursor {
    display: inline-block;
    width: 3px;
    background-color: var(--cyan);
    animation: blink 1s infinite;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* Developer Card */
.dev-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    padding: 40px;
    display: flex;
    align-items: center;
    gap: 40px;
    max-width: 900px;
    margin: 0 auto;
    backdrop-filter: blur(10px);
    box-shadow: 0 20px 50px -20px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
}

.dev-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--cyan), var(--violet));
}

/* Footer Styles */
.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 60px;
    border-bottom: 1px solid var(--glass-border);
    margin-bottom: 30px;
    text-align: left;
}

.footer-col h4 {
    color: var(--white);
    margin-bottom: 20px;
    font-size: 1rem;
}

.footer-col ul {
    list-style: none;
    padding: 0;
}

.footer-col li {
    margin-bottom: 12px;
}

.footer-col a {
    color: var(--text-dim);
    text-decoration: none;
    transition: 0.3s;
    font-size: 0.9rem;
}

.footer-col a:hover {
    color: var(--cyan);
    padding-left: 5px;
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-dim);
    font-size: 0.85rem;
}

footer {
    padding: 80px 0 40px;
    border-top: 1px solid var(--glass-border);
    background: linear-gradient(to bottom, var(--bg-dark), var(--bg-deep));
}

.btn-primary {
    background: linear-gradient(90deg, var(--cyan), var(--violet));
    color: #fff;
    padding: 10px 24px;
    /* Reduced from 16px 40px to look thinner/less bulky */
    border-radius: 100px;
    font-weight: 700;
    text-decoration: none;
    display: inline-flex;
    /* Use inline-flex for better centering */
    align-items: center;
    justify-content: center;
    gap: 8px;
    /* Add gap for icon */
    transition: all 0.3s ease;
    box-shadow: 0 10px 20px -5px rgba(34, 211, 238, 0.4);
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
    /* Slightly smaller font for sleek look */
}

.btn-primary:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 20px 30px -10px rgba(34, 211, 238, 0.6);
    filter: brightness(1.1);
}

@media (max-width: 768px) {
    .dev-card {
        flex-direction: column;
        text-align: center;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 15px;
    }
}