:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --secondary: #0d9488;
    --text: #1a1a1a;
    --text-light: #666666;
    --bg: #ffffff;
    --bg-alt: #f3f4f6;
    --border: #e5e7eb;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.dark {
    --text: #ffffff;
    --text-light: #9ca3af;
    --bg: #111827;
    --bg-alt: #1f2937;
    --border: #374151;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
    transition: background-color 0.3s, color 0.3s;
}

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

/* Header */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 1rem 0;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    transition: all 0.3s;
}

header.scrolled {
    background: var(--bg);
    box-shadow: var(--shadow);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

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

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

nav a {
    color: var(--text);
    text-decoration: none;
    transition: color 0.3s;
}

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

#theme-toggle, #mobile-menu {
    background: none;
    border: none;
    color: var(--text);
    cursor: pointer;
    padding: 0.5rem;
}

#mobile-menu {
    display: none;
}

/* Hero Section */
#hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 6rem 0;
    position: relative;
    overflow: hidden;
}

.animated-bg {
    background: linear-gradient(-45deg, #1a365d, #2563eb, #0d9488, #1e3a8a);
    background-size: 400% 400%;
    animation: gradient 15s ease infinite;
}

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

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    color: white;
}

.hero-content h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.gradient-text {
    background: linear-gradient(to right, #60a5fa, #2dd4bf);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-content h2 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
}

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

@keyframes blink {
    from, to { opacity: 1; }
    50% { opacity: 0; }
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0;
}

.social-links a {
    color: white;
    padding: 0.5rem;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transition: all 0.3s;
}

.social-links a:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

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

.btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.scroll-down {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-20px); }
    60% { transform: translateY(-10px); }
}

/* About Section */
#about {
    padding: 6rem 0;
    background: var(--bg-alt);
}

.section-title {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 3rem;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -0.5rem;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 3px;
    background: var(--primary);
    border-radius: 3px;
}

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

.about-image {
    position: relative;
}

.about-image::before {
    content: '';
    position: absolute;
    top: 1rem;
    left: 1rem;
    right: -1rem;
    bottom: -1rem;
    background: var(--primary);
    border-radius: 0.5rem;
    z-index: 0;
}

.about-image img {
    position: relative;
    width: 100%;
    height: auto;
    border-radius: 0.5rem;
    z-index: 1;
}

.about-text h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.contact-info {
    margin-top: 2rem;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.info-item i {
    color: var(--primary);
}

.info-item a {
    color: var(--text);
    text-decoration: none;
    transition: color 0.3s;
}

.info-item a:hover {
    color: var(--primary);
}

/* Resume Section */
#resume {
    padding: 6rem 0;
}

.resume-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.timeline {
    position: relative;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border);
}

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

.timeline-item::before {
    content: '';
    position: absolute;
    left: -4px;
    top: 0;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--primary);
}

.timeline-item h4 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.timeline-date {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

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

.skill-category {
    background: var(--bg);
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: var(--shadow);
    transition: transform 0.3s, box-shadow 0.3s;
}

.skill-category:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.skill-category h4 {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    color: var(--primary);
}

.skill-category h4 i {
    padding: 0.75rem;
    background: var(--bg-alt);
    border-radius: 0.75rem;
}

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

.skill-tag {
    padding: 0.5rem 1rem;
    background: var(--bg-alt);
    border-radius: 2rem;
    font-size: 0.9rem;
    transition: all 0.3s;
    cursor: default;
}

.skill-tag:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
}

/* Projects Section */
#projects {
    padding: 6rem 0;
    background: var(--bg-alt);
}

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

.filter-btn {
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 2rem;
    background: var(--bg);
    color: var(--text);
    cursor: pointer;
    transition: all 0.3s;
}

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

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

.project-card {
    background: var(--bg);
    border-radius: 0.5rem;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: all 0.3s;
}

.project-card:hover {
    transform: translateY(-5px);
}

.project-image {
    height: 200px;
    background: var(--bg-alt);
}

.project-content {
    padding: 1.5rem;
}

.project-title {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

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

.project-tag {
    padding: 0.25rem 0.75rem;
    background: var(--primary);
    color: white;
    border-radius: 1rem;
    font-size: 0.8rem;
}

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

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

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.contact-info h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.info-list {
    margin-top: 2rem;
}

.contact-form {
    background: var(--bg-alt);
    padding: 2rem;
    border-radius: 0.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    background: var(--bg);
    color: var(--text);
    transition: all 0.3s;
}

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

.form-group textarea {
    height: 150px;
    resize: none;
}

/* Footer */
footer {
    background: var(--bg-alt);
    padding: 3rem 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-logo h2 {
    font-size: 2rem;
}

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

.footer-social {
    text-align: right;
}

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

    #mobile-menu {
        display: block;
    }

    .about-content,
    .resume-content,
    .contact-content {
        grid-template-columns: 1fr;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

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

@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 2rem;
    }

    .hero-content h2 {
        font-size: 1.2rem;
    }

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