:root {
    --primary-color: #9c27b0; /* A nice purple */
    --secondary-color: #00bcd4; /* A nice cyan */
    --text-color: #f0f0f0;
    --bg-color: #000000;
    --surface-color: #1a1a1a;
}

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

html {
    scroll-behavior: smooth;
}



#particle-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
}

#app {
    position: relative;
    z-index: 1;
}

/* Navbar */
#navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    z-index: 1000;
    transition: background-color 0.3s ease-in-out;
    background-color: rgba(12, 12, 12, 0.5);
    backdrop-filter: blur(5px);
}

#navbar.scrolled {
    background-color: var(--surface-color);
    box-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

.nav-logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--text-color);
    font-weight: 600;
}

.nav-logo {
    height: 40px;
    width: 40px;
    margin-right: 10px;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-links a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 400;
    position: relative;
    padding-bottom: 5px;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    cursor: pointer;
}

.hamburger .line {
    width: 25px;
    height: 3px;
    background-color: var(--text-color);
    margin: 5px 0;
    transition: all 0.3s ease;
}

/* PWA Install Button */
.install-button {
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    cursor: pointer;
    font-family: 'Poppins', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    transition: transform 0.3s, box-shadow 0.3s;
    text-decoration: none;
    display: inline-block;
}

.install-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(156, 39, 176, 0.4);
}

header#hero {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 2rem;
}

.logo {
    max-width: 300px;
    width: 80%;
    margin-bottom: 1.5rem;
    animation: fadeInLogo 2s ease-in-out;
}

@keyframes fadeInLogo {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.hero-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 300;
    letter-spacing: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: fadeInText 2s ease-in-out 0.5s backwards;
}

@keyframes fadeInText {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

h2 {
    font-size: 2.5rem;
    font-weight: 600;
    text-align: center;
    margin-bottom: 3rem;
    background: linear-gradient(90deg, var(--secondary-color), var(--primary-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}


/* About Section */
#about p {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    font-size: 1.1rem;
    color: #ccc;
}

/* Coming Soon Section */
#coming-soon p {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    font-size: 1.1rem;
    color: #ccc;
}

#contact > p {
    max-width: 600px;
    margin: 0 auto 1.5rem auto;
    text-align: left;
    color: #ccc;
}

/* Contact Section */
.contact-form {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 1rem;
    background-color: var(--surface-color);
    border: 1px solid #333;
    border-radius: 5px;
    color: var(--text-color);
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 10px rgba(156, 39, 176, 0.5);
}

.cta-button {
    padding: 1rem 2rem;
    background: linear-gradient(270deg, var(--primary-color), var(--secondary-color), #ff6b35, #f7931e, var(--primary-color));
    background-size: 400% 400%;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    transition: transform 0.3s, box-shadow 0.3s;
    animation: colorFluctuate 3s ease-in-out infinite;
    position: relative;
    overflow: hidden;
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(156, 39, 176, 0.4);
    animation-duration: 1.5s;
}

@keyframes colorFluctuate {
    0% {
        background-position: 0% 50%;
    }
    25% {
        background-position: 100% 50%;
    }
    50% {
        background-position: 200% 50%;
    }
    75% {
        background-position: 300% 50%;
    }
    100% {
        background-position: 400% 50%;
    }
}

/* Draggable Avatar */
.avatar-container {
    position: fixed;
    top: 100px;
    right: 30px;
    width: 120px;
    height: 192px;
    cursor: move;
    transition: background-color 0.2s ease, border-color 0.2s ease;
    z-index: 999;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 8px;
    will-change: left, top;
    transform: translateZ(0);
    backface-visibility: hidden;
    padding: 8px;
    touch-action: none; /* Prevent default touch behaviors */
}

.avatar-container:hover {
    background: rgba(156, 39, 176, 0.15);
    border-color: rgba(156, 39, 176, 0.4);
    backdrop-filter: blur(5px);
}

.avatar-container.dragging {
    z-index: 1000;
    background: rgba(156, 39, 176, 0.2);
    transition: none;
}

.avatar-image {
    width: calc(100% - 16px);
    height: calc(100% - 16px);
    object-fit: cover;
    user-select: none;
    pointer-events: none;
    border-radius: 4px;
}

.resize-handle {
    position: absolute;
    bottom: -5px;
    right: -5px;
    width: 16px;
    height: 16px;
    background: rgba(156, 39, 176, 0.8);
    cursor: se-resize;
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.3s ease;
    touch-action: none; /* Prevent scrolling on touch */
}

.avatar-container:hover .resize-handle,
.avatar-container.dragging .resize-handle {
    opacity: 1;
}

.resize-handle::before {
    content: '';
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 0;
    height: 0;
    border-style: solid;
    border-width: 0 0 6px 6px;
    border-color: transparent transparent white transparent;
}

/* Mobile specific styles */
@media (max-width: 768px) {
    .avatar-container {
        top: 80px;
        right: 15px;
        width: 80px;
        height: 128px;
        padding: 4px;
    }

    .resize-handle {
        width: 20px;
        height: 20px;
        bottom: -8px;
        right: -8px;
        opacity: 0.7; /* Always visible on mobile for easier interaction */
        background: rgba(156, 39, 176, 0.9);
    }

    .resize-handle::before {
        bottom: 3px;
        right: 3px;
        border-width: 0 0 8px 8px;
    }

    /* Make avatar always show resize handle on mobile when active */
    .avatar-container:active .resize-handle,
    .avatar-container.dragging .resize-handle {
        opacity: 1;
    }
}

@media (max-width: 480px) {
    .avatar-container {
        top: 70px;
        right: 10px;
        width: 70px;
        height: 112px;
        padding: 3px;
    }

    .resize-handle {
        width: 24px;
        height: 24px;
        bottom: -10px;
        right: -10px;
        opacity: 0.8;
    }
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem;
    margin-top: 2rem;
    background-color: var(--surface-color);
    color: #888;
}

.footer-links {
    margin-bottom: 1rem;
}

.footer-links a {
    color: #aaa;
    text-decoration: none;
    margin: 0 1rem;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--secondary-color);
}

/* Scroll Fade Animation */
.scroll-fade {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.scroll-fade.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Tablet/small desktop horizontal scroll */
@media (min-width: 769px) and (max-width: 1200px) {
    .nav-links {
        max-width: calc(100vw - 300px); /* Leave space for logo and some padding */
        overflow-x: auto;
        overflow-y: hidden;
        scrollbar-width: none;
        -ms-overflow-style: none;
        position: relative;
        padding: 0 100px; /* Always maintain 100px padding on left and right */
        /* Add subtle gradient to indicate scrollable content */
        mask-image: linear-gradient(to right, transparent 0%, black 20px, black calc(100% - 20px), transparent 100%);
        -webkit-mask-image: linear-gradient(to right, transparent 0%, black 20px, black calc(100% - 20px), transparent 100%);
    }

    .nav-links::-webkit-scrollbar {
        display: none;
    }

    .nav-links li {
        flex-shrink: 0;
        white-space: nowrap;
    }

    /* Add scroll indicators */
    .nav-links::before,
    .nav-links::after {
        content: '';
        position: absolute;
        top: 0;
        bottom: 0;
        width: 20px;
        pointer-events: none;
        z-index: 1;
    }

    .nav-links::before {
        left: 0;
        background: linear-gradient(to right, var(--bg-color), transparent);
    }

    .nav-links::after {
        right: 0;
        background: linear-gradient(to left, var(--bg-color), transparent);
    }
}

@media (max-width: 768px) {
    #navbar {
        padding: 1rem;
    }

    .nav-logo-link span {
        display: none;
    }

    .nav-links {
        position: fixed;
        top: 64px; /* Match navbar height */
        right: -100%;
        width: 100%;
        height: calc(100vh - 64px);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 2rem;
        background-color: rgba(0,0,0,0.95);
        backdrop-filter: blur(10px);
        transition: right 0.4s ease-in-out;
        /* Reset horizontal scroll properties for mobile */
        overflow-x: visible;
        overflow-y: visible;
        white-space: normal;
        max-width: none;
        padding: 0;
    }

    .nav-links.nav-active {
        right: 0;
    }

    .nav-links li {
        opacity: 0;
    }

    .install-button {
        margin-top: 1rem;
    }

    .hamburger {
        display: block;
    }

    .toggle .line:nth-child(1) {
        transform: rotate(-45deg) translate(-5px, 6px);
    }
    .toggle .line:nth-child(2) {
        opacity: 0;
    }
    .toggle .line:nth-child(3) {
        transform: rotate(45deg) translate(-5px, -6px);
    }

    @keyframes navLinkFade {
        from {
            opacity: 0;
            transform: translateX(50px);
        }
        to {
            opacity: 1;
            transform: translateX(0);
        }
    }

    main > section {
        padding: 4rem 1.5rem;
    }

    h2 {
        font-size: 2rem;
    }


}