:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --secondary: #8b5cf6;
    --accent: #ec489a;
    --dark: #0f172a;
    --light: #f8fafc;
    --gray: #64748b;
    --success: #10b981;
    --transition: all 0.3s 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: var(--light);
    color: var(--dark);
    overflow-x: hidden;
    transition: background 0.3s, color 0.3s;
}

body.dark {
    background: var(--dark);
    color: var(--light);
}

/* Custom Cursor */
.cursor {
    width: 8px;
    height: 8px;
    background: var(--primary);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    transition: transform 0.1s;
}

.cursor-follower {
    width: 30px;
    height: 30px;
    border: 2px solid var(--primary);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9998;
    transition: all 0.2s;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    transition: var(--transition);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

body.dark .navbar {
    background: rgba(15, 23, 42, 0.95);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

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

.logo {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -1px;
}

.logo-text {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.logo-dot {
    color: var(--primary);
}

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

.nav-link {
    text-decoration: none;
    color: inherit;
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: var(--transition);
}

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

.nav-controls {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0.5rem;
    border-radius: 50%;
    transition: var(--transition);
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--dark);
    margin: 3px 0;
    transition: var(--transition);
}

body.dark .hamburger span {
    background: var(--light);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 20% 50%, rgba(99, 102, 241, 0.1), transparent 50%);
    pointer-events: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    position: relative;
    z-index: 1;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    padding: 8rem 0 4rem;
}

.hero-text {
    animation: fadeInUp 1s ease;
}

.greeting {
    font-size: 1.1rem;
    color: var(--primary);
    margin-bottom: 1rem;
    font-weight: 500;
}

h1 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.glitch {
    position: relative;
    animation: glitch 3s infinite;
}

@keyframes glitch {
    0%, 100% { transform: skew(0deg, 0deg); }
    95% { transform: skew(0deg, 0deg); }
    96% { transform: skew(2deg, 1deg); }
    97% { transform: skew(-2deg, -1deg); }
    98% { transform: skew(0deg, 0deg); }
}

.typing-container {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.typing-text {
    color: var(--primary);
    font-weight: 600;
}

.cursor-blink {
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

.hero-description {
    font-size: 1.1rem;
    color: var(--gray);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    cursor: pointer;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border: none;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -5px rgba(99, 102, 241, 0.4);
}

.btn-secondary {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-secondary:hover {
    background: var(--primary);
    color: white;
}

.hero-stats {
    display: flex;
    gap: 3rem;
}

.stat {
    text-align: center;
}

.stat-number {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--gray);
}

.hero-visual {
    position: relative;
    height: 400px;
}

.floating-card {
    position: absolute;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem;
    border-radius: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    animation: float 6s ease-in-out infinite;
}

body.dark .floating-card {
    background: rgba(30, 41, 59, 0.95);
}

.floating-card:nth-child(1) {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.floating-card:nth-child(2) {
    top: 50%;
    right: 10%;
    animation-delay: 2s;
}

.floating-card:nth-child(3) {
    bottom: 20%;
    left: 30%;
    animation-delay: 4s;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

.code-icon {
    font-size: 2rem;
}

.code-text {
    font-family: monospace;
    font-size: 0.875rem;
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
}

.mouse {
    width: 30px;
    height: 50px;
    border: 2px solid var(--gray);
    border-radius: 15px;
    position: relative;
    margin: 0 auto;
}

.mouse::before {
    content: '';
    width: 4px;
    height: 8px;
    background: var(--gray);
    position: absolute;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 2px;
    animation: scroll 2s infinite;
}

@keyframes scroll {
    0% { opacity: 1; transform: translateX(-50%) translateY(0); }
    100% { opacity: 0; transform: translateX(-50%) translateY(20px); }
}

.scroll-text {
    font-size: 0.75rem;
    margin-top: 0.5rem;
    color: var(--gray);
}

/* Section Styles */
.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-tag {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    padding: 0.25rem 1rem;
    border-radius: 2rem;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 1rem;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.section-header p {
    color: var(--gray);
}

/* Projects Section */
.projects {
    padding: 6rem 0;
    background: rgba(99, 102, 241, 0.05);
}

.project-filter {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
}

.filter-btn {
    padding: 0.5rem 1.5rem;
    border: 2px solid var(--primary);
    background: transparent;
    color: var(--primary);
    border-radius: 2rem;
    cursor: pointer;
    transition: var(--transition);
}

.filter-btn.active,
.filter-btn:hover {
    background: var(--primary);
    color: white;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.project-card {
    background: white;
    border-radius: 1rem;
    overflow: hidden;
    transition: var(--transition);
    cursor: pointer;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

body.dark .project-card {
    background: rgba(30, 41, 59, 0.5);
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2);
}

.project-image {
    height: 200px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    position: relative;
    overflow: hidden;
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition);
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.project-links {
    display: flex;
    gap: 1rem;
}

.project-link {
    color: white;
    text-decoration: none;
    padding: 0.5rem 1rem;
    border: 2px solid white;
    border-radius: 0.5rem;
    transition: var(--transition);
}

.project-link:hover {
    background: white;
    color: var(--primary);
}

.project-info {
    padding: 1.5rem;
}

.project-category {
    font-size: 0.75rem;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.project-info h3 {
    margin-bottom: 0.5rem;
}

.project-info p {
    color: var(--gray);
    margin-bottom: 1rem;
    line-height: 1.5;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.project-tech span {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 0.25rem;
}

/* Skills Section */
.skills {
    padding: 6rem 0;
}

.skills-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
}

.skill-category h3 {
    margin-bottom: 1.5rem;
    font-size: 1.25rem;
}

.skill-items {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.skill-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.skill-bar {
    height: 8px;
    background: rgba(99, 102, 241, 0.2);
    border-radius: 4px;
    overflow: hidden;
}

.skill-progress {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    border-radius: 4px;
    animation: fillBar 1.5s ease;
}

@keyframes fillBar {
    from { width: 0; }
}

/* About Section */
.about {
    padding: 6rem 0;
    background: rgba(99, 102, 241, 0.05);
}

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

.about-text p {
    margin-bottom: 1rem;
    line-height: 1.6;
    color: var(--gray);
}

.about-info {
    margin: 2rem 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.info-item {
    display: flex;
    gap: 1rem;
}

.info-label {
    font-weight: 600;
    color: var(--primary);
}

.experience-card {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    padding: 2rem;
    border-radius: 1rem;
    text-align: center;
    color: white;
    animation: float 4s ease-in-out infinite;
}

.experience-number {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

/* Contact Section */
.contact {
    padding: 6rem 0;
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.contact-details {
    margin: 2rem 0;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-item {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: rgba(99, 102, 241, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.contact-text h4 {
    margin-bottom: 0.25rem;
    font-size: 0.875rem;
    color: var(--gray);
}

.contact-text a,
.contact-text span {
    text-decoration: none;
    color: inherit;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.social-link {
    padding: 0.5rem 1rem;
    border: 2px solid var(--primary);
    border-radius: 0.5rem;
    text-decoration: none;
    color: var(--primary);
    transition: var(--transition);
}

.social-link:hover {
    background: var(--primary);
    color: white;
}

/* Form Styles */
.contact-form {
    background: rgba(255, 255, 255, 0.95);
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

body.dark .contact-form {
    background: rgba(30, 41, 59, 0.95);
}

.form-group {
    position: relative;
    margin-bottom: 2rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid rgba(99, 102, 241, 0.2);
    background: transparent;
    border-radius: 0.5rem;
    font-size: 1rem;
    transition: var(--transition);
    color: inherit;
}

.form-group label {
    position: absolute;
    left: 0.75rem;
    top: 0.75rem;
    transition: var(--transition);
    pointer-events: none;
    color: var(--gray);
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--primary);
    outline: none;
}

.form-group input:focus ~ label,
.form-group textarea:focus ~ label,
.form-group input:valid ~ label,
.form-group textarea:valid ~ label {
    top: -0.5rem;
    left: 0.5rem;
    font-size: 0.75rem;
    background: var(--light);
    padding: 0 0.25rem;
}

body.dark .form-group input:focus ~ label,
body.dark .form-group textarea:focus ~ label {
    background: var(--dark);
}

.submit-btn {
    width: 100%;
    justify-content: center;
}

/* Footer */
.footer {
    background: var(--dark);
    color: white;
    padding: 3rem 0 1.5rem;
}

.footer-content {
    text-align: center;
}

.footer-logo {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 1rem;
}

.footer-text {
    color: var(--gray);
    margin-bottom: 2rem;
}

.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.875rem;
    color: var(--gray);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }
    
    .hamburger {
        display: flex;
    }
    
    .hero-content,
    .about-content,
    .contact-wrapper {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .hero-visual {
        height: 300px;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .typing-container {
        font-size: 1.2rem;
    }
    
    .hero-stats {
        gap: 1.5rem;
    }
    
    .project-filter {
        flex-wrap: wrap;
    }
    
    .section-header h2 {
        font-size: 2rem;
    }
    
    .floating-card {
        transform: scale(0.8);
    }
}

/* Scroll Reveal Animation */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

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