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

:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --accent-color: #3b82f6;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --text-light: #9ca3af;
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-accent: #f1f5f9;
    --border-color: #e5e7eb;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

[data-theme="dark"] {
    --primary-color: #3b82f6;
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-accent: #1e40af;
    --text-primary: #f1f5f9;
    --text-secondary: #cbd5e1;
    --text-light: #64748b;
    --border-color: #334155;
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.3);
}

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

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


.header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 3rem 0;
    position: relative;
    overflow: hidden;
}

.controls {
    position: fixed;
    top: 1rem;
    left: 1rem;
    display: flex;
    gap: 0.5rem;
    z-index: 1000;
    padding: 0.5rem;
}

.control-btn {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.4);
    color: white;
    padding: 0.3rem 0.6rem;
    border-radius: 1rem;
    cursor: pointer;
    font-size: 0.75rem;
    font-weight: 600;
    backdrop-filter: blur(10px);
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 0.2rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.control-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.header-content {
    display: flex;
    align-items: center;
    gap: 2rem;
    position: relative;
    z-index: 1;
}

.profile-image {
    flex-shrink: 0;
}

.profile-image img {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid rgba(255, 255, 255, 0.2);
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
}

.profile-image img:hover {
    transform: scale(1.05);
    border-color: rgba(255, 255, 255, 0.4);
}

.header-info {
    flex: 1;
}

.name {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    letter-spacing: -0.025em;
}

.title {
    font-size: 1.25rem;
    font-weight: 500;
    margin-bottom: 0.25rem;
    opacity: 0.9;
}

.subtitle {
    font-size: 1rem;
    margin-bottom: 1.5rem;
    opacity: 0.8;
    font-weight: 500;
    background: rgba(255, 255, 255, 0.1);
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 2rem;
}

.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 0.75rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.contact-item i {
    width: 18px;
    opacity: 0.8;
}

.contact-item a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

.contact-item a:hover {
    opacity: 0.8;
    text-decoration: underline;
}


.download-cv-top {
    position: absolute;
    top: 2rem;
    right: 2rem;
    z-index: 10;
}

.download-cv-mobile-fixed {
    display: none;
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    background: var(--primary-color);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 2rem;
    text-decoration: none;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    align-items: center;
    gap: 0.5rem;
}



.btn-download {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    text-decoration: none;
    padding: 0.75rem 1.5rem;
    border-radius: 2rem;
    font-weight: 600;
    font-size: 0.95rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.btn-download:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
    color: white;
    text-decoration: none;
}

.btn-download:active {
    transform: translateY(0);
}

.btn-download i {
    font-size: 1rem;
    animation: bounce 2s infinite;
}

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


.navbar {
    background: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    padding: 1rem 0;
    justify-content: center;
    flex-wrap: wrap;
}

.nav-link {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    transition: var(--transition);
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-color);
    background: var(--bg-accent);
}


.main-content {
    padding: 3rem 0;
}

.section {
    margin-bottom: 4rem;
    scroll-margin-top: 100px;
}

.section-title {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 2rem;
    position: relative;
    padding-bottom: 0.5rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
}


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

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

.about-content p {
    margin-bottom: 1rem;
    color: var(--text-secondary);
    line-height: 1.7;
}


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

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

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

.timeline-item::before {
    content: '';
    position: absolute;
    left: -1.375rem;
    top: 0.5rem;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--primary-color);
    border: 3px solid var(--bg-primary);
    box-shadow: 0 0 0 2px var(--primary-color);
}

.timeline-date {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.timeline-content h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.timeline-content h4 {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.timeline-content p {
    color: var(--text-secondary);
    line-height: 1.6;
}


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

.experience-card {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.experience-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

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

.card-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
}

.period {
    font-size: 0.85rem;
    color: var(--text-light);
    font-weight: 500;
    background: var(--bg-accent);
    padding: 0.25rem 0.5rem;
    border-radius: 1rem;
}

.company {
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

.experience-card p:last-child {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.95rem;
}


.project-categories {
    margin-bottom: 2rem;
}

.category-title {
    font-size: 1.3rem;
    font-weight: 600;
    margin: 2rem 0 1rem 0;
    color: var(--text-primary);
}

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

.project-card {
    background: var(--bg-primary);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    transition: var(--transition);
    position: relative;
}

.project-card {
    border: 2px solid var(--primary-color);
}

.project-card.featured {
    background: linear-gradient(135deg, var(--bg-primary), var(--bg-secondary));
}



.project-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

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

.project-title-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.project-logo {
    width: 32px;
    height: 32px;
    object-fit: contain;
    border-radius: 6px;
    flex-shrink: 0;
}

.project-header h4 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0;
}

.project-link {
    color: var(--text-light);
    font-size: 1.1rem;
    transition: var(--transition);
}

.project-link:hover {
    color: var(--primary-color);
    transform: scale(1.1);
}

.project-desc {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

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

.tech {
    background: var(--bg-accent);
    color: var(--primary-color);
    padding: 0.25rem 0.75rem;
    border-radius: 1rem;
    font-size: 0.8rem;
    font-weight: 500;
}


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

.skills-category {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
}

.skills-category h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.skill {
    background: var(--bg-primary);
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

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

.soft-skills .skill {
    background: var(--accent-color);
    color: white;
    border: none;
}

.languages {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.language {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--border-color);
}

.lang-flag {
    font-size: 1.2rem;
    margin-right: 0.5rem;
}

.lang-name {
    font-weight: 500;
}

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


.interests {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
    max-width: 900px;
    margin: 0 auto;
}

.interest-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--bg-secondary);
    padding: 1rem 1.5rem;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

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

.interest-item i {
    font-size: 1.2rem;
}


.footer {
    background: var(--bg-secondary);
    padding: 2rem 0;
    border-top: 1px solid var(--border-color);
    text-align: center;
    color: var(--text-secondary);
}

.footer p {
    margin-bottom: 0.5rem;
}


@media (max-width: 768px) {
    body {
        padding-bottom: 6rem;
    }
    
    .controls {
        display: flex;
        position: fixed;
        top: 0.5rem;
        left: 0.5rem;
        z-index: 1000;
        gap: 0.3rem;
    }
    
    .control-btn {
        padding: 0.25rem 0.5rem;
        font-size: 0.7rem;
        gap: 0.1rem;
    }
    
    .header-content {
        flex-direction: column;
        text-align: center;
    }
    
    .name {
        font-size: 2rem;
    }
    
    .nav-menu {
        justify-content: flex-start;
        overflow-x: auto;
        padding-bottom: 1rem;
    }
    
    .contact-info {
        grid-template-columns: 1fr;
    }
    
    .download-cv-top {
        display: none;
    }
    
    .download-cv-mobile-fixed {
        display: flex;
    }
    
    .btn-download {
        font-size: 0.85rem;
        padding: 0.75rem 1.25rem;
        gap: 0.4rem;
        box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4), 0 4px 15px rgba(0, 0, 0, 0.1);
        border: 2px solid rgba(255, 255, 255, 0.4);
        backdrop-filter: blur(15px);
    }
    
    .btn-download:hover {
        box-shadow: 0 12px 35px rgba(59, 130, 246, 0.5), 0 6px 20px rgba(0, 0, 0, 0.15);
        transform: translateY(-3px);
    }
    
    .timeline {
        padding-left: 1.5rem;
    }
    
    .timeline-item::before {
        left: -1.125rem;
    }
    
    .projects-grid,
    .experience-grid {
        grid-template-columns: 1fr;
    }
    
    .skills-container {
        grid-template-columns: 1fr;
    }
    
    .interests {
        justify-content: flex-start;
        max-width: 100%;
    }
    
    .container {
        padding: 0 0.75rem;
    }
}

@media (max-width: 480px) {
    .profile-image img {
        width: 120px;
        height: 120px;
    }
    
    .name {
        font-size: 1.75rem;
    }
    
    .title {
        font-size: 1.1rem;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .nav-menu {
        gap: 1rem;
    }
    
    .project-card,
    .experience-card,
    .skills-category {
        padding: 1rem;
    }

    .project-logo {
        width: 28px;
        height: 28px;
    }
    
    .project-title-logo {
        gap: 0.5rem;
    }
}


html {
    scroll-behavior: smooth;
}


@media print {
    .navbar,
    .footer {
        display: none;
    }
    
    .header {
        background: white !important;
        color: black !important;
        box-shadow: none;
    }
    
    .project-card,
    .experience-card,
    .skills-category {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid #ccc;
    }
}


@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}


.nav-link:focus,
.contact-item a:focus,
.project-link:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
    border-radius: 4px;
}


.profile-image img {
    opacity: 0;
    animation: fadeIn 0.5s ease-in-out forwards;
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}