/* CSS Variables for theming */
:root {
    --primary-color: #00ff88;
    --secondary-color: #0066cc;
    --accent-color: #ff6b35;
    --bg-primary: #0a0a0f;
    --bg-secondary: #1a1a2e;
    --bg-tertiary: #16213e;
    --text-primary: #ffffff;
    --text-secondary: #b3b3b3;
    --text-accent: #00ff88;
    --border-color: #333;
    --shadow: rgba(0, 255, 136, 0.2);
    --code-bg: #1e1e1e;
    --terminal-bg: #0c0c0c;
    --font-mono: 'Fira Code', monospace;
    --font-primary: 'Inter', sans-serif;
}

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

html {
    scroll-behavior: smooth;
    height: 100%;
    width: 100%;
}

body {
    font-family: var(--font-primary);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* Matrix Background Effect */
.matrix-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: linear-gradient(45deg,
            rgba(0, 255, 136, 0.03) 0%,
            rgba(0, 102, 204, 0.03) 50%,
            rgba(255, 107, 53, 0.03) 100%);
    animation: matrixFlow 20s ease-in-out infinite;
}

@keyframes matrixFlow {

    0%,
    100% {
        opacity: 0.3;
    }

    50% {
        opacity: 0.1;
    }
}

/* Navigation */
.nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(10, 10, 15, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: all 0.3s ease;
}

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

.nav-logo {
    font-family: var(--font-mono);
    font-size: 1.2rem;
    color: var(--primary-color);
    font-weight: 600;
}

.terminal-prompt {
    color: var(--primary-color);
}

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

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover {
    color: var(--primary-color);
}

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

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

.theme-toggle {
    cursor: pointer;
    color: var(--text-secondary);
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    color: var(--primary-color);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 2rem;
    background: radial-gradient(circle at center,
            rgba(0, 255, 136, 0.1) 0%,
            transparent 70%);
}

.hero-content {
    max-width: 1000px;
    width: 100%;
}

.terminal-window {
    background: var(--terminal-bg);
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 255, 136, 0.1);
    border: 1px solid var(--border-color);
    overflow: hidden;
}

.terminal-header {
    background: var(--bg-secondary);
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-color);
}

.terminal-buttons {
    display: flex;
    gap: 8px;
}

.btn {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.btn.close {
    background: #ff5f56;
}

.btn.minimize {
    background: #ffbd2e;
}

.btn.maximize {
    background: #27ca3f;
}

.terminal-title {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.terminal-body {
    padding: 2rem;
    font-family: var(--font-mono);
}

.terminal-line {
    margin-bottom: 1rem;
}

.prompt {
    color: var(--primary-color);
    margin-right: 8px;
}

.command {
    color: var(--text-primary);
}

.cursor {
    color: var(--primary-color);
    animation: blink 1s infinite;
}

@keyframes blink {

    0%,
    50% {
        opacity: 1;
    }

    51%,
    100% {
        opacity: 0;
    }
}

.ascii-art {
    color: var(--primary-color);
    font-size: 0.6rem;
    line-height: 1;
    margin: 1rem 0;
    white-space: pre;
    text-align: center;
}

.hero-description {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin: 1.5rem 0;
    line-height: 1.8;
    text-align: center;
}

.hero-stats {
    display: flex;
    gap: 3rem;
    margin-top: 2rem;
    justify-content: center;
}

.stat {
    text-align: center;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    display: block;
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

/* Sections */
section {
    padding: 100px 0;
}

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

.section-title {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 4rem;
    font-family: var(--font-mono);
}

.code-bracket {
    color: var(--primary-color);
}

/* About Section */
.about {
    background: var(--bg-secondary);
}

.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.code-block {
    background: var(--code-bg);
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.code-header {
    background: var(--bg-tertiary);
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
}

.file-name {
    color: var(--text-secondary);
    font-family: var(--font-mono);
    font-size: 0.9rem;
}

.code-buttons {
    display: flex;
    gap: 8px;
}

.code-btn {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--border-color);
}

.code-content {
    padding: 2rem;
    overflow-x: auto;
}

.code-content pre {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    line-height: 1.6;
}

.keyword {
    color: #569cd6;
}

.class-name {
    color: #4ec9b0;
}

.interface {
    color: #b8d7a3;
}

.string {
    color: #ce9178;
}

/* Skills Section */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 3rem;
}

.skill-category h3 {
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-bottom: 2rem;
    font-family: var(--font-mono);
}

.skill-item {
    margin-bottom: 1.5rem;
}

.skill-name {
    display: block;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.skill-bar {
    height: 8px;
    background: var(--bg-secondary);
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}

.skill-progress {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 4px;
    width: 0;
    transition: width 2s ease-in-out;
    position: relative;
}

.skill-progress::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }

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

/* Projects Section */
.projects {
    background: var(--bg-secondary);
}

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

.project-card {
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 2rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 255, 136, 0.1);
}

.project-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.project-card h3 {
    color: var(--text-primary);
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

.project-tech {
    background: var(--primary-color);
    color: var(--bg-primary);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.project-card p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

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

.tag {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    border: 1px solid var(--border-color);
}

/* Contact Section */
.contact-content {
    max-width: 600px;
    margin: 0 auto;
}

.terminal-contact {
    background: var(--terminal-bg);
    border-radius: 12px;
    border: 1px solid var(--border-color);
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 255, 136, 0.1);
}

.contact-item {
    padding: 1rem 0;
    font-family: var(--font-mono);
    border-bottom: 1px solid var(--border-color);
}

.contact-item:last-child {
    border-bottom: none;
}

.contact-link {
    margin-left: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.contact-link:hover {
    color: var(--primary-color);
}

.contact-link i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.contact-link a {
    color: inherit;
    text-decoration: none;
    transition: all 0.3s ease;
}

.contact-link a:hover {
    color: var(--primary-color);
}

.output-text {
    margin-left: 2rem;
    color: var(--primary-color);
    font-style: italic;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }

    .hero-stats {
        flex-direction: column;
        gap: 1.5rem;
        text-align: center;
    }

    .section-title {
        font-size: 2rem;
    }

    .ascii-art {
        font-size: 0.4rem;
    }

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

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

@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }

    .terminal-body {
        padding: 1rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .ascii-art {
        display: none;
    }
}

/* Scroll animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeInUp 0.6s ease-out;
}

/* Interactive hover effects */
.project-card:hover .project-tech {
    background: var(--accent-color);
    transform: scale(1.05);
}

.skill-item:hover .skill-name {
    color: var(--primary-color);
}

/* Loading animations */
.loading {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease;
}

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