/* Modern Design System - Sai Balusu Portfolio */
:root {
    /* Color Palette - Deep Space & Neon Accents */
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-tertiary: #1a1a24;
    --text-primary: #ffffff;
    --text-secondary: #a0a0b0;
    --accent-primary: #6d28d9;
    /* Deep Purple */
    --accent-secondary: #3b82f6;
    /* Bright Blue */
    --accent-glow: rgba(109, 40, 217, 0.5);

    /* Gradients */
    --gradient-main: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    --gradient-dark: linear-gradient(to bottom, var(--bg-primary), var(--bg-secondary));
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);

    /* Spacing & Layout */
    --container-width: 1200px;
    --header-height: 80px;
    --border-radius-sm: 8px;
    --border-radius-md: 16px;
    --border-radius-lg: 24px;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-smooth: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
    scroll-behavior: smooth;
}

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

/* Canvas Background */
#particles-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0.6;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 {
    font-size: 4.5rem;
    letter-spacing: -2px;
    line-height: 1.1;
}

h2 {
    font-size: 2.5rem;
}

h3 {
    font-size: 1.75rem;
}

.text-gradient {
    background: var(--gradient-main);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Utility Classes */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 2rem;
}

.section {
    padding: 6rem 0;
}

.grid {
    display: grid;
    gap: 2rem;
}

.flex {
    display: flex;
    gap: 1rem;
}

/* Enhanced Glass Card with Shimmer */
.glass-card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
    border-radius: var(--border-radius-md);
    padding: 2.5rem;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent,
            rgba(255, 255, 255, 0.05),
            transparent);
    transition: 0.5s;
}

.glass-card:hover::before {
    left: 100%;
}

.glass-card:hover {
    transform: translateY(-5px) scale(1.01);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 20px 40px -20px rgba(0, 0, 0, 0.6);
    background: rgba(255, 255, 255, 0.05);
}

/* Header & Navigation */
header {
    position: fixed;
    top: 0;
    width: 100%;
    height: var(--header-height);
    background: rgba(10, 10, 15, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--glass-border);
    z-index: 1000;
    display: flex;
    align-items: center;
    padding: 0 2rem;
    /* Direct padding instead of container */
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 100%;
    /* Ensure full width */
}

/* Chatbot Styles */
.chat-widget {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 1000;
    font-family: 'Inter', sans-serif;
}

.chat-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--gradient-main);
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(109, 40, 217, 0.4);
    transition: var(--transition-smooth);
    display: flex;
    align-items: center;
    justify-content: center;
}

.chat-toggle:hover {
    transform: scale(1.1);
}

.chat-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 500px;
    background: rgba(18, 18, 26, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius-md);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform-origin: bottom right;
    transform: scale(0);
    opacity: 0;
    transition: var(--transition-smooth);
    pointer-events: none;
    /* Prevent clicks when hidden */
}

.chat-window.active {
    transform: scale(1);
    opacity: 1;
    pointer-events: all;
}

.chat-header {
    background: var(--gradient-main);
    padding: 1rem;
    color: white;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-header h3 {
    font-size: 1rem;
    margin: 0;
}

.chat-close {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 1.1rem;
}

.chat-messages {
    flex: 1;
    padding: 1rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.message {
    max-width: 80%;
    padding: 0.8rem 1rem;
    border-radius: 12px;
    font-size: 0.9rem;
    line-height: 1.4;
}

.bot-message {
    background: rgba(255, 255, 255, 0.1);
    align-self: flex-start;
    border-bottom-left-radius: 2px;
}

.user-message {
    background: var(--accent-secondary);
    align-self: flex-end;
    border-bottom-right-radius: 2px;
}

.chat-input-area {
    padding: 1rem;
    border-top: 1px solid var(--glass-border);
    display: flex;
    gap: 0.5rem;
}

.chat-input {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    padding: 0.8rem;
    border-radius: 20px;
    color: white;
    outline: none;
}

.chat-send {
    background: var(--accent-primary);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-fast);
}

.chat-send:hover {
    background: var(--accent-secondary);
}

/* Scrollbar for chat */
.chat-messages::-webkit-scrollbar {
    width: 6px;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    text-decoration: none;
}

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

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition-fast);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text-primary);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: var(--header-height);
}

.hero-content {
    max-width: 800px;
    position: relative;
    z-index: 1;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--accent-secondary);
    margin-bottom: 1rem;
    font-weight: 600;
}

.hero-description {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    max-width: 600px;
}

.btn {
    display: inline-block;
    padding: 1rem 2rem;
    border-radius: var(--border-radius-sm);
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition-fast);
}

.btn-primary {
    background: var(--gradient-main);
    color: white;
    border: none;
}

.btn-primary:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--accent-secondary);
    color: var(--text-primary);
    margin-left: 1rem;
}

.btn-outline:hover {
    background: rgba(59, 130, 246, 0.1);
}

/* Background Effects */
.glow-orb {
    position: absolute;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--accent-glow), transparent 70%);
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.4;
    z-index: 0;
    animation: float 10s infinite ease-in-out;
}

.orb-1 {
    top: 10%;
    right: 10%;
}

.orb-2 {
    bottom: 10%;
    left: 10%;
    animation-delay: -5s;
}

@keyframes float {

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

    50% {
        transform: translate(30px, -30px);
    }
}

/* About Section */
.section-title {
    font-size: 3rem;
    margin-bottom: 4rem;
    text-align: center;
    position: relative;
    display: inline-block;
    width: 100%;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--gradient-main);
    margin: 1rem auto 0;
    border-radius: 2px;
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 4rem;
    align-items: center;
}

.about-text p {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
}

/* Improved Timeline */
.timeline {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 2px;
    background: linear-gradient(to bottom, transparent, var(--accent-secondary), transparent);
}

.timeline-item {
    padding-left: 3rem;
    position: relative;
    margin-bottom: 4rem;
}

.timeline-dot {
    position: absolute;
    left: -8px;
    top: 24px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--bg-primary);
    border: 2px solid var(--accent-secondary);
    box-shadow: 0 0 15px var(--accent-secondary);
    z-index: 2;
    transition: var(--transition-fast);
}

.timeline-item:hover .timeline-dot {
    background: var(--accent-secondary);
    transform: scale(1.3);
}

.experience-card {
    position: relative;
}

.role-title {
    color: var(--text-primary);
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.company-name {
    color: var(--accent-secondary);
    font-weight: 600;
}

.duration {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    display: block;
}

.exp-list {
    list-style-position: inside;
    color: var(--text-secondary);
}

.exp-list li {
    margin-bottom: 0.8rem;
    padding-left: 0.5rem;
}

/* Projects Grid */
.projects-grid {
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0;
}

.tag {
    font-size: 0.8rem;
    padding: 0.25rem 0.75rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    color: var(--text-secondary);
}

.project-links {
    margin-top: 1.5rem;
}

.project-link {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* Skills */
.skills-grid {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.skill-category {
    margin-bottom: 1rem;
    font-size: 1.1rem;
    color: var(--accent-secondary);
}

.skill-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.skill-item {
    background: rgba(109, 40, 217, 0.1);
    border: 1px solid rgba(109, 40, 217, 0.2);
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius-sm);
    font-size: 0.9rem;
    transition: 0.2s;
}

.skill-item:hover {
    background: rgba(109, 40, 217, 0.2);
    transform: scale(1.05);
}

/* Contact */
.contact-container {
    max-width: 600px;
    margin: 0 auto;
    text-align: center;
}

.contact-info {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.contact-button {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius-sm);
    color: var(--text-primary);
    text-decoration: none;
    transition: var(--transition-fast);
}

.contact-button:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

/* Clients Marquee */
.clients-container {
    overflow: hidden;
    padding: 2rem 0;
    position: relative;
    background: rgba(255, 255, 255, 0.02);
    backdrop-filter: blur(10px);
    border-top: 1px solid var(--glass-border);
    border-bottom: 1px solid var(--glass-border);
}

.clients-container::before,
.clients-container::after {
    content: "";
    position: absolute;
    top: 0;
    width: 150px;
    height: 100%;
    z-index: 2;
}

.clients-container::before {
    left: 0;
    background: linear-gradient(to right, var(--bg-primary), transparent);
}

.clients-container::after {
    right: 0;
    background: linear-gradient(to left, var(--bg-primary), transparent);
}

/* Clients Marquee */
.clients-container {
    overflow: hidden;
    padding: 2rem 0;
    position: relative;
    background: rgba(255, 255, 255, 0.02);
    backdrop-filter: blur(10px);
    border-top: 1px solid var(--glass-border);
    border-bottom: 1px solid var(--glass-border);
}

/* ... (existing styles) ... */

.client-track {
    display: flex;
    gap: 4rem;
    width: max-content;
    animation: scroll 30s linear infinite;
}

.client-slide {
    display: flex;
    align-items: center;
    justify-content: center;
    /* SVGs are white by default, just opacity */
    transition: var(--transition-fast);
    opacity: 0.7;
}

.client-slide:hover {
    opacity: 1;
    transform: scale(1.1);
}

.client-slide img {
    height: 50px;
    width: auto;
    max-width: 150px;
    object-fit: contain;
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* Footer */
footer {
    padding: 2rem 0;
    text-align: center;
    border-top: 1px solid var(--glass-border);
    color: var(--text-secondary);
    margin-top: 4rem;
}

/* Responsive */
@media (max-width: 768px) {
    h1 {
        font-size: 2.8rem;
    }

    .glass-card {
        padding: 1.5rem;
    }

    .nav-links {
        display: none;
        /* Add mobile menu later */
    }

    .about-grid {
        grid-template-columns: 1fr;
    }

    .timeline::before {
        left: 0;
    }

    .timeline-item {
        padding-left: 2rem;
    }
}