/* CSS Variables for Dark Theme */
:root {
    --bg-primary: #0a192f;
    --bg-secondary: #112240;
    --bg-tertiary: #1e3a5f;
    --text-primary: #ccd6f6;
    --text-secondary: #8892b0;
    --text-accent: #64ffda;
    --nav-bg: rgba(10, 25, 47, 0.85);
    --border-color: #233554;
    --shadow: rgba(0, 0, 0, 0.3);
    --btn-hover: rgba(100, 255, 218, 0.1);
    --section-spacing: 100px;
}

/* Light Theme */
[data-theme="light"] {
    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --bg-tertiary: #e9ecef;
    --text-primary: #172a45;
    --text-secondary: #495057;
    --text-accent: #0d6efd;
    --nav-bg: rgba(255, 255, 255, 0.85);
    --border-color: #dee2e6;
    --shadow: rgba(0, 0, 0, 0.1);
    --btn-hover: rgba(13, 110, 253, 0.1);
    --section-spacing: 100px;
}

/* Reset & Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
}

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

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background-color: var(--nav-bg);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    transition: all 0.3s ease;
}

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

.nav-logo a {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-accent);
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.nav-logo a:hover {
    opacity: 0.8;
}

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

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
    position: relative;
}

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

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

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

.theme-toggle {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    padding: 0.5rem;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    margin-left: 1rem;
}

.theme-toggle:hover {
    background-color: var(--btn-hover);
    border-color: var(--text-accent);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    gap: 4px;
}

.nav-toggle span {
    width: 25px;
    height: 2px;
    background-color: var(--text-primary);
    transition: all 0.3s ease;
}

/* Hero Section */
.hero {
    display: flex;
    align-items: center;
    padding-top: 120px;
    padding-bottom: 40px;
    animation: fadeInUp 0.8s ease;
}

.hero-wrapper {
    display: flex;
    align-items: center;
    gap: 3rem;
    justify-content: center;
    max-width: 1200px;
    margin: 0 auto;
}

.hero-avatar {
    flex-shrink: 0;
}

.avatar-img {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--text-accent);
    filter: grayscale(100%);
    transition: filter 0.3s ease;
}

.avatar-img:hover {
    filter: grayscale(0%);
}

.hero-content {
    max-width: 600px;
    flex: 1;
}

.hero-greeting {
    color: var(--text-accent);
    font-size: 1.1rem;
    margin-bottom: 1rem;
    font-weight: 400;
}

.hero-name {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    line-height: 1.1;
}

.hero-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.hero-description {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    max-width: 540px;
    line-height: 1.7;
}

/* Buttons */
.btn {
    padding: 0.875rem 1.5rem;
    border-radius: 5px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    display: inline-block;
    border: 1px solid var(--text-accent);
}

.btn-primary {
    background-color: transparent;
    color: var(--text-accent);
    border-color: var(--text-accent);
}

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

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

.btn-secondary:hover {
    background-color: var(--btn-hover);
    border-color: var(--text-accent);
    transform: translateY(-2px);
}

/* Section Styles */
section {
    padding: var(--section-spacing) 0;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

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

.section-title {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 3rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    white-space: nowrap;
}

.section-title::after {
    content: '';
    display: block;
    height: 1px;
    width: 300px;
    background-color: var(--border-color);
    margin-left: 1rem;
}

.section-number {
    color: var(--text-accent);
    font-family: 'Courier New', monospace;
    font-size: 1.2rem;
}

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

.about-text p {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.8;
}

.tech-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
    list-style: none;
    margin-top: 1rem;
}

.tech-list li {
    color: var(--text-secondary);
    font-size: 0.9rem;
    position: relative;
    padding-left: 1.5rem;
}

.tech-list li::before {
    content: '▹';
    color: var(--text-accent);
    position: absolute;
    left: 0;
}

.about-image {
    display: flex;
    justify-content: center;
    align-items: center;
}

.image-wrapper {
    position: relative;
    width: 300px;
    height: 300px;
    border-radius: 5px;
    overflow: hidden;
    border: 2px solid var(--text-accent);
}

.profile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    transition: filter 0.3s ease;
}

.image-wrapper:hover .profile-img {
    filter: grayscale(0%);
}

/* Experience Section */
.experience-content {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 2rem;
    align-items: start;
}

.experience-tabs {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.tab-btn {
    background: none;
    border: none;
    border-left: 2px solid var(--border-color);
    padding: 1rem 1.5rem;
    text-align: left;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.tab-btn:hover {
    background-color: var(--bg-secondary);
    color: var(--text-accent);
}

.tab-btn.active {
    border-left-color: var(--text-accent);
    color: var(--text-accent);
    background-color: var(--bg-secondary);
}

.tab-content {
    display: none;
    animation: fadeIn 0.5s ease;
}

.tab-content.active {
    display: block;
}

.job-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.company {
    color: var(--text-accent);
}

.job-period {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.job-description {
    list-style: none;
    color: var(--text-secondary);
}

.job-description li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.75rem;
    line-height: 1.7;
}

.job-description li::before {
    content: '▹';
    color: var(--text-accent);
    position: absolute;
    left: 0;
}

.job-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
}

.tech-tag {
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-family: 'Courier New', monospace;
}

.resume-link-wrapper {
    margin-top: 3rem;
    text-align: center;
}

.resume-link {
    color: var(--text-accent);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    display: inline-block;
    padding: 0.5rem 1rem;
    border: 1px solid var(--text-accent);
    border-radius: 5px;
}

.resume-link:hover {
    background-color: var(--btn-hover);
    transform: translateY(-2px);
}


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

.contact-intro {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 3rem;
    line-height: 1.8;
}

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

.contact-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem;
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.3s ease;
    text-align: left;
}

.contact-item:hover {
    border-color: var(--text-accent);
    background-color: var(--btn-hover);
    transform: translateY(-3px);
}

.contact-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.contact-label {
    color: var(--text-secondary);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.contact-value {
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 500;
}

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

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

.footer-text {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

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

.social-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.social-link:hover {
    color: var(--text-accent);
}

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

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

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .about-content {
        grid-template-columns: 1fr;
    }

    .about-image {
        justify-self: center;
    }

    .section-title::after {
        width: 200px;
    }
}

@media (max-width: 768px) {
    .hero-wrapper {
        flex-direction: column;
        gap: 2rem;
        text-align: center;
    }

    .avatar-img {
        width: 150px;
        height: 150px;
    }

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

    .nav-menu {
        position: fixed;
        top: 70px;
        left: -100%;
        flex-direction: column;
        background-color: var(--bg-secondary);
        width: 100%;
        padding: 2rem;
        transition: left 0.3s ease;
        border-top: 1px solid var(--border-color);
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-toggle {
        display: flex;
    }

    .experience-content {
        grid-template-columns: 1fr;
    }

    .experience-tabs {
        flex-direction: row;
        overflow-x: auto;
        padding-bottom: 1rem;
    }

    .tab-btn {
        border-left: none;
        border-bottom: 2px solid var(--border-color);
        white-space: nowrap;
    }

    .tab-btn.active {
        border-left: none;
        border-bottom-color: var(--text-accent);
    }

    .section-title::after {
        width: 100px;
    }

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

    .contact-methods {
        gap: 1rem;
    }

    .contact-item {
        padding: 1.25rem;
        gap: 1rem;
    }

    .contact-icon {
        font-size: 1.5rem;
    }

}

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

    .hero-name {
        font-size: 2rem;
    }

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

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

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

/* Ultrawide Support */
@media (min-width: 1920px) {
    .container {
        max-width: 1400px;
    }

    .hero-content {
        max-width: 800px;
    }
}