
:root {
    
    --black-primary: #000000;
    --black-secondary: #111111;
    --white: #ffffff;
    --red-primary: #E63946;
    --red-secondary: #D90429;
    --red-accent: #FF1744;
    --gray-light: #f5f5f5;
    --gray-dark: #333333;
    --gray-medium: #666666;
    
    
    --dark-bg: #000000;
    --card-bg: #111111;
    --text-primary: #ffffff;
    --text-secondary: #cccccc;
    --light-bg: #ffffff;
    --dark-text: #000000;
    --dark-text-secondary: #333333;
    
    
    --font-primary: 'Inter', sans-serif;
    --font-size-base: 16px;
    --font-size-h1: 3.5rem;
    --font-size-h2: 2.5rem;
    --font-size-h3: 1.8rem;
    --font-size-h4: 1.4rem;
    
    
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 8rem;
    
    
    --mobile: 480px;
    --tablet: 768px;
    --desktop: 1024px;
    
    
    --transition-fast: 0.3s ease;
    --transition-medium: 0.5s ease;
    --transition-slow: 0.8s ease;
    
    
    --shadow-light: 0 2px 10px rgba(0, 0, 0, 0.1);
    --shadow-medium: 0 4px 20px rgba(0, 0, 0, 0.15);
    --shadow-heavy: 0 8px 30px rgba(0, 0, 0, 0.2);
    --shadow-red: 0 0 20px rgba(230, 57, 70, 0.3);
}


[data-theme="light"] {
    --black-primary: #ffffff;
    --black-secondary: #f5f5f5;
    --white: #000000;
    --gray-light: #333333;
    --gray-dark: #f5f5f5;
    --gray-medium: #999999;
    
    
    --dark-bg: #ffffff;
    --card-bg: #f5f5f5;
    --text-primary: #000000;
    --text-secondary: #333333;
    --light-bg: #ffffff;
    --dark-text: #000000;
    --dark-text-secondary: #333333;
}


[data-theme="light"] .project-card {
    background: #ffffff;
    border-color: rgba(230, 57, 70, 0.3);
}

[data-theme="light"] .project-content h3 {
    color: #000000;
    text-shadow: none;
}

[data-theme="light"] .project-overlay p {
    color: #000000;
    text-shadow: none;
}

[data-theme="light"] .project-overlay {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0.95) 100%);
    border-color: rgba(230, 57, 70, 0.3);
}

[data-theme="light"] .project-card:hover .project-overlay {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(255, 255, 255, 1) 100%);
    border-color: rgba(230, 57, 70, 0.5);
}


[data-theme="light"] .project-image {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
}

[data-theme="light"] .project-icon {
    background: linear-gradient(135deg, rgba(230, 57, 70, 0.1), rgba(217, 4, 41, 0.05));
    box-shadow: 0 8px 32px rgba(230, 57, 70, 0.15);
}

[data-theme="light"] .project-icon i {
    color: rgba(230, 57, 70, 0.6);
    text-shadow: 0 0 20px rgba(230, 57, 70, 0.3);
}

[data-theme="light"] .project-card:hover .project-icon {
    background: linear-gradient(135deg, rgba(230, 57, 70, 0.15), rgba(217, 4, 41, 0.08));
    box-shadow: 0 12px 48px rgba(230, 57, 70, 0.25);
}

[data-theme="light"] .project-card:hover .project-icon i {
    color: rgba(230, 57, 70, 0.8);
    text-shadow: 0 0 30px rgba(230, 57, 70, 0.5);
}


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

html {
    scroll-behavior: smooth;
    font-size: var(--font-size-base);
}

body {
    font-family: var(--font-primary);
    background-color: var(--black-primary);
    color: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color var(--transition-medium), color var(--transition-medium);
}


.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
}


h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: var(--spacing-sm);
}

h1 { font-size: var(--font-size-h1); }
h2 { font-size: var(--font-size-h2); }
h3 { font-size: var(--font-size-h3); }
h4 { font-size: var(--font-size-h4); }

p {
    margin-bottom: var(--spacing-sm);
    font-size: 1.1rem;
}


.btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all var(--transition-fast);
    position: relative;
    overflow: hidden;
    will-change: transform;
}

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

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(230, 57, 70, 0.5);
}

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

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

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

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


.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    transition: all var(--transition-fast);
    will-change: transform;
    transform: translateY(0);
}


.navbar.navbar-hidden {
    transform: translateY(-100%);
}

.navbar.navbar-visible {
    transform: translateY(0);
}


[data-theme="light"] .navbar {
    background: #ffffff !important;
    color: #333333 !important;
}


[data-theme="light"] .navbar.navbar-hidden {
    transform: translateY(-100%);
}

[data-theme="light"] .navbar.navbar-visible {
    transform: translateY(0);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-logo a {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--red-primary);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.nav-logo a:hover {
    color: var(--red-secondary);
}

.nav-menu {
    display: flex;
    gap: var(--spacing-md);
}

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

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

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

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

.bar {
    width: 25px;
    height: 3px;
    background: var(--white);
    margin: 3px 0;
    transition: var(--transition-fast);
}


.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    padding-top: 70px; 
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.red-gradient {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, 
        rgba(230, 57, 70, 0.1) 0%, 
        rgba(217, 4, 41, 0.05) 50%, 
        rgba(0, 0, 0, 0) 100%);
    animation: gradientShift 8s ease-in-out infinite;
}

@keyframes gradientShift {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.6; }
}

.particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(230, 57, 70, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(217, 4, 41, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(230, 57, 70, 0.05) 0%, transparent 50%);
    animation: particleDrift 20s linear infinite;
}

@keyframes particleDrift {
    0% { transform: translateY(0px) rotate(0deg); }
    100% { transform: translateY(-100px) rotate(360deg); }
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-lg);
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
}

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

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: var(--spacing-sm);
    background: linear-gradient(135deg, var(--white), var(--red-primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: titleGlow 2s ease-in-out infinite alternate;
}

@keyframes titleGlow {
    0% { filter: drop-shadow(0 0 5px rgba(230, 57, 70, 0.3)); }
    100% { filter: drop-shadow(0 0 20px rgba(230, 57, 70, 0.6)); }
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--red-primary);
    margin-bottom: var(--spacing-sm);
    animation: fadeInUp 1s ease-out 0.2s both;
}

.hero-description {
    font-size: 1.2rem;
    color: var(--white);
    margin-bottom: var(--spacing-md);
    animation: fadeInUp 1s ease-out 0.6s both;
}

.hero-description p {
    margin-bottom: 0.5rem;
    line-height: 1.6;
    color: var(--white);
    white-space: nowrap;
}

.hero-buttons {
    display: flex;
    gap: var(--spacing-sm);
    animation: fadeInUp 1s ease-out 0.6s both;
}

.hero-image {
    display: flex;
    justify-content: center;
    align-items: center;
    animation: fadeInRight 1s ease-out 0.3s both;
}

.profile-img {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--red-primary);
    box-shadow: var(--shadow-red);
    transition: transform var(--transition-fast);
}

.profile-img:hover {
    transform: scale(1.05);
}

.scroll-cue {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    color: var(--red-primary);
    font-size: 1.5rem;
    animation: bounce 2s infinite;
    cursor: pointer;
    transition: color var(--transition-fast);
}

.scroll-cue:hover {
    color: var(--red-secondary);
}

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


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

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}


section {
    padding: var(--spacing-lg) 0;
}

.section-title {
    text-align: center;
    margin-bottom: var(--spacing-lg);
    position: relative;
}

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


.about {
    background: var(--black-secondary);
}

.about-content {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: var(--spacing-lg);
    align-items: start;
}

.about-text p {
    margin-bottom: var(--spacing-md);
    font-size: 1.1rem;
    line-height: 1.8;
    text-align: justify;
}

.highlight {
    color: var(--red-primary);
    font-weight: 600;
    position: relative;
}

.highlight::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--red-primary);
    animation: underlineExpand 0.8s ease-out 0.5s forwards;
}

@keyframes underlineExpand {
    to { width: 100%; }
}

.about-stats {
    display: grid;
    gap: var(--spacing-md);
}

.stat {
    text-align: center;
    padding: var(--spacing-md);
    background: rgba(230, 57, 70, 0.1);
    border-radius: 12px;
    border: 1px solid rgba(230, 57, 70, 0.2);
    transition: transform var(--transition-fast);
}

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

.stat h3 {
    font-size: 2.5rem;
    color: var(--red-primary);
    margin-bottom: var(--spacing-xs);
}

.stat p {
    color: var(--gray-medium);
    font-weight: 500;
}


.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: var(--spacing-lg);
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
    width: 100%;
}

.project-card {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    background: var(--black-secondary);
    border: 2px solid rgba(230, 57, 70, 0.2);
    transition: all var(--transition-medium);
    will-change: transform;
    cursor: pointer;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
    min-height: 300px;
    width: 100%;
    margin: 0;
    backdrop-filter: blur(10px);
    opacity: 1;
    transform: translateY(0);
    
    animation: none;
}


.project-card:nth-child(1),
.project-card:nth-child(2),
.project-card:nth-child(3),
.project-card:nth-child(4),
.project-card:nth-child(5),
.project-card:nth-child(6) {
    animation: none;
}


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

.project-card:hover {
    transform: translateY(-10px) scale(1.02);
    border-color: var(--red-primary);
    box-shadow: 0 15px 40px rgba(230, 57, 70, 0.4), 0 0 30px rgba(230, 57, 70, 0.2);
    animation: none;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, transparent, rgba(230, 57, 70, 0.05), transparent);
    opacity: 0;
    transition: opacity var(--transition-medium);
    pointer-events: none;
    z-index: 1;
}

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

.project-image {
    position: relative;
    overflow: hidden;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--black-secondary), var(--black-primary));
}

.project-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, rgba(230, 57, 70, 0.1), rgba(217, 4, 41, 0.05));
    transition: all var(--transition-medium);
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: var(--spacing-lg);
    box-sizing: border-box;
    border-radius: 50%;
    box-shadow: 0 8px 32px rgba(230, 57, 70, 0.1);
    z-index: 1;
    opacity: 0.6;
}

.project-icon::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at center, rgba(230, 57, 70, 0.15) 0%, transparent 70%);
    opacity: 0;
    transition: opacity var(--transition-medium);
    border-radius: 50%;
}

.project-card:hover .project-icon::before {
    opacity: 1;
}

.project-icon i {
    font-size: 3rem;
    color: rgba(230, 57, 70, 0.4);
    transition: all var(--transition-medium);
    text-shadow: 0 0 20px rgba(230, 57, 70, 0.3);
    z-index: 1;
    position: relative;
    max-width: 80%;
    max-height: 80%;
    display: flex;
    align-items: center;
    justify-content: center;
    filter: drop-shadow(0 2px 4px rgba(230, 57, 70, 0.2));
}

.project-card:hover .project-icon {
    background: linear-gradient(135deg, rgba(230, 57, 70, 0.15), rgba(217, 4, 41, 0.08));
    box-shadow: 0 12px 48px rgba(230, 57, 70, 0.2);
    transform: translate(-50%, -50%) scale(1.1);
    opacity: 0.8;
}

.project-card:hover .project-icon i {
    transform: scale(1.2) rotate(5deg);
    color: rgba(230, 57, 70, 0.6);
    text-shadow: 0 0 30px rgba(230, 57, 70, 0.5);
    filter: drop-shadow(0 4px 8px rgba(230, 57, 70, 0.3));
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0.85) 100%);
    padding: var(--spacing-md);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    text-align: center;
    transition: all var(--transition-medium);
    border: 1px solid rgba(230, 57, 70, 0.2);
    z-index: 2;
}

.project-card:hover .project-overlay {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.9) 100%);
    border-color: rgba(230, 57, 70, 0.4);
}

.project-content h3 {
    color: var(--white);
    margin-bottom: var(--spacing-sm);
    font-size: 1.3rem;
    font-weight: 700;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.9);
    letter-spacing: 0.3px;
    line-height: 1.2;
    max-width: 100%;
    word-wrap: break-word;
    hyphens: auto;
    overflow-wrap: break-word;
}

.project-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    flex-grow: 1;
    justify-content: center;
}

.project-overlay p {
    color: var(--white);
    margin-bottom: 0;
    font-size: 0.95rem;
    line-height: 1.4;
    text-shadow: 0 1px 6px rgba(0, 0, 0, 0.9);
    opacity: 0.9;
    max-width: 100%;
    word-wrap: break-word;
}

.project-overlay .btn {
    margin-top: var(--spacing-xs);
    font-size: 0.9rem;
    padding: 10px 18px;
    border-radius: 6px;
    transition: all var(--transition-fast);
    background: rgba(230, 57, 70, 0.9);
    color: var(--white);
    border: 1px solid rgba(230, 57, 70, 0.8);
    flex-shrink: 0;
}

.project-overlay .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(230, 57, 70, 0.6);
    background: var(--red-primary);
    border-color: var(--red-primary);
}




.blog-posts-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-lg);
    max-width: 800px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.upload-form {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
    text-align: left;
}

.upload-form .form-group {
    position: relative;
    margin-bottom: var(--spacing-md);
}

.upload-form .form-group input,
.upload-form .form-group textarea {
    width: 100%;
    padding: var(--spacing-sm);
    background: var(--black-primary);
    border: 1px solid rgba(230, 57, 70, 0.3);
    border-radius: 8px;
    color: var(--white);
    font-size: 1rem;
    font-family: var(--font-primary);
    transition: all var(--transition-fast);
}

.upload-form .form-group input:focus,
.upload-form .form-group textarea:focus {
    outline: none;
    border-color: var(--red-primary);
    box-shadow: 0 0 10px rgba(230, 57, 70, 0.3);
}

.upload-form .form-group label {
    position: absolute;
    top: -10px;
    left: var(--spacing-sm);
    background: var(--black-secondary);
    padding: 0 var(--spacing-xs);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.file-upload-wrapper {
    position: relative;
}

.file-upload-wrapper input[type="file"] {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
}

.file-upload-label {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md);
    background: var(--black-primary);
    border: 2px dashed rgba(230, 57, 70, 0.3);
    border-radius: 8px;
    color: var(--white);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.file-upload-label:hover {
    border-color: var(--red-primary);
    background: rgba(230, 57, 70, 0.1);
}

.file-upload-label i {
    font-size: 1.5rem;
    color: var(--red-primary);
}

.file-name {
    color: var(--text-secondary);
    font-style: italic;
    margin-left: auto;
}

.upload-success-message {
    background: rgba(230, 57, 70, 0.2);
    border: 1px solid var(--red-primary);
    border-radius: 8px;
    padding: var(--spacing-sm);
    color: var(--white);
    text-align: center;
    margin-top: var(--spacing-sm);
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}


.blog-post-preview {
    background: var(--black-secondary);
    border: 1px solid rgba(230, 57, 70, 0.2);
    border-radius: 12px;
    padding: var(--spacing-lg);
    transition: all var(--transition-medium);
    cursor: pointer;
}

.blog-post-preview:hover {
    border-color: var(--red-primary);
    transform: translateY(-3px);
    box-shadow: var(--shadow-red);
}

.blog-post-preview-header {
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-md);
    border-bottom: 1px solid rgba(230, 57, 70, 0.1);
}

.blog-post-preview-title {
    color: var(--white);
    font-size: 1.8rem;
    margin-bottom: var(--spacing-sm);
    font-weight: 600;
}

.blog-post-preview-date {
    color: var(--text-secondary);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.blog-post-preview-date i {
    color: var(--red-primary);
}

.blog-post-preview-excerpt {
    margin-bottom: var(--spacing-md);
    text-align: center;
}

.blog-post-preview-excerpt p {
    color: var(--text-secondary);
    line-height: 1.8;
    font-size: 1.05rem;
}

.read-more-btn {
    margin-top: var(--spacing-sm);
    display: inline-block;
}

.blog-post-preview { text-align: center; }


.blog-post-preview.mgm-intro .blog-post-preview-title { text-align: center; }
.mgm-issued { text-align: center; color: var(--text-secondary); margin-top: 4px; }
.mgm-meta-row {
    display: flex;
    justify-content: space-between;
    margin: 10px 0 0 0;
    color: var(--text-secondary);
    font-size: 0.9rem;
}
.blog-post-preview.mgm-intro .blog-post-preview-title { color: var(--red-primary); }
.blog-post-preview.mgm-intro .read-more-btn { margin-top: 12px; }
.blog-post-preview.mgm-intro .mgm-meta-row { margin-bottom: 8px; }


.blog-window {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh; 
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch; 
    touch-action: pan-y; 
    backdrop-filter: blur(10px);
    animation: fadeIn 0.3s ease;
    padding-bottom: 160px; 
}

.blog-window-header {
    position: sticky;
    top: 0;
    background: rgba(0,0,0,0.4); 
    border-bottom: 1px solid rgba(230,57,70,0.35);
    padding: 6px 12px; 
    z-index: 10;
    box-shadow: none;
    transition: transform var(--transition-fast), opacity var(--transition-fast);
}

.blog-window-nav {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    max-width: 1400px;
    margin: 0 auto;
    justify-content: center;
}


.blog-header-auto-hide-active .blog-window-header {
    transform: translateY(-100%);
    opacity: 0;
}

.blog-header-auto-hide-active:hover .blog-window-header,
.blog-window-header:hover {
    transform: translateY(0);
    opacity: 1;
}


.blog-header-hover-zone {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 24px;
    z-index: 10001;
}

.blog-top-hint {
    position: fixed;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(230,57,70,0.12);
    color: var(--white);
    border: 1px solid rgba(230,57,70,0.35);
    border-radius: 999px;
    padding: 4px 10px;
    font-size: 0.85rem;
    z-index: 10002;
    opacity: 0;
    transition: opacity var(--transition-fast);
    pointer-events: none;
}

.blog-header-auto-hide-active .blog-top-hint { opacity: 0.85; }
.blog-header-auto-hide-active:hover .blog-top-hint,
.blog-window-header:hover ~ .blog-top-hint { opacity: 0; }

.blog-close-btn {
    background: transparent;
    border: 1px solid rgba(230, 57, 70, 0.3);
    border-radius: 8px;
    color: var(--white);
    padding: var(--spacing-xs) var(--spacing-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
}

.blog-close-btn:hover {
    border-color: var(--red-primary);
    background: rgba(230, 57, 70, 0.1);
    transform: rotate(90deg);
}

.blog-window-title {
    color: var(--white);
    margin: 0;
    font-size: 1.25rem;
    font-weight: 600;
}

.blog-list-view-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: var(--spacing-lg);
}

.blog-list-content {
    padding-top: var(--spacing-md);
}


.blog-post-view-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: var(--spacing-lg);
}

.blog-post-container {
    padding-top: var(--spacing-md);
}

.blog-back-btn {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm) var(--spacing-md);
    background: var(--black-secondary);
    border: 1px solid rgba(230, 57, 70, 0.3);
    border-radius: 8px;
    color: var(--white);
    cursor: pointer;
    margin-bottom: var(--spacing-lg);
    transition: all var(--transition-fast);
    font-size: 1rem;
    font-family: var(--font-primary);
}

.blog-back-btn:hover {
    border-color: var(--red-primary);
    background: rgba(230, 57, 70, 0.1);
    transform: translateX(-5px);
}

.blog-back-btn i {
    color: var(--red-primary);
}

.blog-post-content {
    background: var(--black-secondary);
    border-radius: 12px;
    padding: var(--spacing-lg);
    
    padding-bottom: calc(var(--spacing-lg) + 72px);
    color: var(--white);
    line-height: 1.8;
}

.blog-post-content * {
    max-width: 100%;
}

.blog-post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: var(--spacing-md) 0;
}

.blog-post-content h1,
.blog-post-content h2,
.blog-post-content h3,
.blog-post-content h4,
.blog-post-content h5,
.blog-post-content h6 {
    color: var(--white);
    margin-top: var(--spacing-md);
    margin-bottom: var(--spacing-sm);
}

.blog-post-content p {
    margin-bottom: var(--spacing-md);
    color: var(--text-secondary);
}

.blog-post-content a {
    color: var(--red-primary);
    text-decoration: none;
}

.blog-post-content a:hover {
    text-decoration: underline;
}

.blog-post-content code {
    background: rgba(230, 57, 70, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Courier New', monospace;
    color: var(--red-primary);
}

.blog-post-content pre {
    background: var(--black-primary);
    padding: var(--spacing-md);
    border-radius: 8px;
    overflow-x: auto;
    margin: var(--spacing-md) 0;
}

.blog-post-content pre code {
    background: none;
    padding: 0;
    color: var(--white);
}


.blog-post-iframe {
    width: 100%;
    height: 80vh;
    border: 0;
    border-radius: 12px;
    background: var(--black-primary);
}


.blog-deck {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.blog-card {
    background: var(--black-primary);
    border: 1px solid rgba(230, 57, 70, 0.25);
    border-radius: 14px;
    padding: clamp(18px, 2.6vw, 32px);
    position: relative; 
    
    padding-bottom: calc(clamp(18px, 2.6vw, 32px) + 74px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.35);
}


.blog-card.is-first h1,
.blog-card.is-first h2,
.blog-card.is-first h3 { text-align: center; }

.deck-issued {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 8px;
}


.deck-meta-row {
    position: absolute;
    left: clamp(18px, 2.6vw, 32px);
    right: clamp(18px, 2.6vw, 32px);
    bottom: calc(clamp(12px, 1.8vw, 20px) + 54px);
    display: flex;
    justify-content: space-between;
    gap: 12px;
    color: var(--text-secondary);
    font-size: 0.9rem;
}
.deck-slide > *:first-child { margin-top: 0; }
.deck-slide > *:last-child { margin-bottom: 0; }
.deck-slide img, .deck-slide table { border-radius: 8px; overflow: hidden; }
.deck-slide table { width: 100%; }
.deck-slide .key-point, .deck-slide .metric-box, .deck-slide .comparison-card {
    margin: 1.25rem 0;
    padding: clamp(14px, 2vw, 20px); 
    border-radius: 10px;
}

.blog-card-title {
    margin: 0 0 var(--spacing-md) 0;
    font-size: clamp(1.25rem, 2.4vw, 1.8rem);
    color: var(--white);
}
.deck-slide h1, .deck-slide h2, .deck-slide h3, .deck-slide h4 {
    color: var(--red-primary);
}
.deck-slide p, .deck-slide li, .deck-slide td, .deck-slide th {
    color: var(--text-secondary);
    text-align: justify;
}
.deck-slide .key-point, .deck-slide .metric-box, .deck-slide .comparison-card {
    background: rgba(230, 57, 70, 0.1);
    border: 1px solid rgba(230, 57, 70, 0.25);
}
.deck-slide .comparison-card h4,
.deck-slide .key-point h4 { margin-top: 0; }


.mgm-steps p { margin: 0 0 12px 0; }
.mgm-steps .mgm-step-gap { margin-top: 10px; }


.deck-slide .comparison-card ul,
.deck-slide .comparison-card ol,
.deck-slide .key-point ul,
.deck-slide .key-point ol,
.deck-slide .metric-box ul,
.deck-slide .metric-box ol {
    list-style-position: inside;
    padding-left: 0.75rem;
    margin-left: 0;
}
.deck-slide table th {
    background: rgba(230, 57, 70, 0.25);
}

.blog-card-body p {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.85;
}

.blog-deck-controls {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: var(--spacing-md);
    position: absolute; 
    left: clamp(18px, 2.6vw, 32px);
    right: clamp(18px, 2.6vw, 32px);
    bottom: clamp(12px, 1.8vw, 20px);
    background: rgba(10,10,10,0.75);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(230,57,70,0.25);
    border-radius: 12px;
    padding: 10px 12px;
    z-index: 1;
}


.deck-fab {
    position: fixed; 
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(10,10,10,0.8);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(230,57,70,0.35);
    color: var(--white);
    display: flex; 
    align-items: center;
    justify-content: center;
    z-index: 100000; 
    opacity: 1;
    pointer-events: auto;
    cursor: pointer;
}
.deck-fab:hover { background: rgba(230,57,70,0.15); }
.deck-fab-prev { left: 12px; }
.deck-fab-next { right: 12px; }


.blog-window .deck-fab { display: flex; }


@media (max-height: 900px) {
    .blog-deck-controls {
        position: static;
        transform: none;
        width: 100%;
        max-width: none;
        background: transparent;
        border: 0;
        border-radius: 0;
        padding: var(--spacing-md) 0 0 0;
    }
    .blog-window { padding-bottom: var(--spacing-lg); }
}

.deck-progress {
    position: relative;
    height: 8px;
    background: rgba(255,255,255,0.08);
    border-radius: 999px;
    overflow: hidden;
    min-width: 200px;
}

.deck-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--red-primary), #ff6b6b);
    width: 0%;
    transition: width 250ms ease;
}


.admin-panel {
    position: fixed;
    top: 0;
    right: 0;
    width: 100%;
    max-width: 500px;
    height: 100vh;
    background: var(--black-secondary);
    border-left: 2px solid var(--red-primary);
    z-index: 10000;
    overflow-y: auto;
    box-shadow: -5px 0 20px rgba(0, 0, 0, 0.5);
}

.admin-panel-content {
    padding: var(--spacing-lg);
}

.admin-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-lg);
    padding-bottom: var(--spacing-md);
    border-bottom: 1px solid rgba(230, 57, 70, 0.2);
}

.admin-panel-header h3 {
    color: var(--white);
    margin: 0;
}

.admin-close-btn {
    background: transparent;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
    padding: var(--spacing-xs);
    transition: all var(--transition-fast);
}

.admin-close-btn:hover {
    color: var(--red-primary);
    transform: rotate(90deg);
}

.admin-toggle {
    background: var(--black-secondary);
    border: 1px solid rgba(230, 57, 70, 0.3);
    border-radius: 8px;
    color: var(--white);
    padding: var(--spacing-xs) var(--spacing-sm);
    cursor: pointer;
    transition: all var(--transition-fast);
    margin-left: var(--spacing-sm);
}

.admin-toggle:hover {
    border-color: var(--red-primary);
    background: rgba(230, 57, 70, 0.1);
}

.admin-toggle i {
    color: var(--red-primary);
}

.no-posts {
    text-align: center;
    color: var(--text-secondary);
    padding: var(--spacing-lg);
    font-style: italic;
}

.text-viewer {
    background: var(--black-primary);
    padding: var(--spacing-md);
    border-radius: 8px;
    max-height: 600px;
    overflow-y: auto;
}

.text-viewer pre {
    color: var(--white);
    white-space: pre-wrap;
    word-wrap: break-word;
    font-family: 'Courier New', monospace;
}


[data-theme="light"] .blog {
    background: var(--light-bg);
}

[data-theme="light"] .upload-card,
[data-theme="light"] .blog-post-card {
    background: var(--card-bg);
    border-color: rgba(230, 57, 70, 0.2);
}

[data-theme="light"] .upload-card h3,
[data-theme="light"] .blog-post-content h4,
[data-theme="light"] .blog-posts-section h3 {
    color: var(--dark-text);
}

[data-theme="light"] .upload-form .form-group input,
[data-theme="light"] .upload-form .form-group textarea,
[data-theme="light"] .file-upload-label {
    background: var(--light-bg);
    border-color: rgba(230, 57, 70, 0.3);
    color: var(--dark-text);
}

[data-theme="light"] .blog-post-content p,
[data-theme="light"] .blog-post-meta span,
[data-theme="light"] .no-posts {
    color: var(--dark-text-secondary);
}

[data-theme="light"] .text-viewer {
    background: var(--light-bg);
}

[data-theme="light"] .text-viewer pre {
    color: var(--dark-text);
}


[data-theme="light"] .blog-post-preview,
[data-theme="light"] .blog-post-content,
[data-theme="light"] .admin-panel {
    background: var(--card-bg);
    border-color: rgba(230, 57, 70, 0.2);
}

[data-theme="light"] .blog-post-preview-title,
[data-theme="light"] .blog-post-content h1,
[data-theme="light"] .blog-post-content h2,
[data-theme="light"] .blog-post-content h3,
[data-theme="light"] .admin-panel-header h3 {
    color: var(--dark-text);
}

[data-theme="light"] .blog-post-preview-excerpt p,
[data-theme="light"] .blog-post-content p,
[data-theme="light"] .blog-post-preview-date {
    color: var(--dark-text-secondary);
}

[data-theme="light"] .blog-back-btn,
[data-theme="light"] .admin-toggle {
    background: var(--card-bg);
    border-color: rgba(230, 57, 70, 0.3);
    color: var(--dark-text);
}

[data-theme="light"] .upload-form .form-group input,
[data-theme="light"] .upload-form .form-group textarea,
[data-theme="light"] .file-upload-label {
    background: var(--light-bg);
    border-color: rgba(230, 57, 70, 0.3);
    color: var(--dark-text);
}

[data-theme="light"] .no-posts {
    color: var(--dark-text-secondary);
}


[data-theme="light"] .blog-window {
    background: rgba(255, 255, 255, 0.95);
}

[data-theme="light"] .blog-window-header {
    background: var(--card-bg);
    border-bottom-color: var(--red-primary);
}

[data-theme="light"] .blog-window-title {
    color: var(--dark-text);
}

[data-theme="light"] .blog-close-btn {
    border-color: rgba(230, 57, 70, 0.3);
    color: var(--dark-text);
}

[data-theme="light"] .blog-close-btn:hover {
    border-color: var(--red-primary);
    background: rgba(230, 57, 70, 0.1);
}


@media (max-width: 768px) {
    .blog-window-header {
        padding: var(--spacing-sm) var(--spacing-md);
    }
    
    .blog-window-title {
        font-size: 1.5rem;
    }
    
    .blog-list-view-container,
    .blog-post-view-container {
        padding: var(--spacing-md);
    }
    
    .blog-posts-grid {
        padding: 0;
    }
    
    .blog-post-preview {
        padding: var(--spacing-md);
    }
    
    .blog-post-preview-title {
        font-size: 1.5rem;
    }
    
    .blog-post-container {
        padding: var(--spacing-md) 0;
    }
    
    .admin-panel {
        max-width: 100%;
    }
}


@media (max-width: 480px) {
    .blog-window-title { font-size: 1.1rem; }
    .blog-list-view-container,
    .blog-post-view-container { padding: var(--spacing-md); }
    .blog-posts-grid { gap: var(--spacing-md); }
    .blog-post-preview { padding: var(--spacing-md); }
    .mgm-meta-row { flex-direction: column; gap: 4px; align-items: center; }
    .blog-card {
        padding: 14px;
        padding-bottom: calc(14px + 120px); 
    }
    .deck-slide p,
    .deck-slide li,
    .blog-post-preview-excerpt p { font-size: 0.95rem; line-height: 1.7; }
    .blog-post-content,
    .blog-post-preview-excerpt p { word-break: break-word; overflow-wrap: anywhere; }
    .blog-post-content img { max-width: 100%; height: auto; }
    .blog-deck-controls {
        left: 12px; right: 12px; bottom: 12px;
        padding: 8px 10px;
        box-sizing: border-box;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    .deck-progress { min-width: 0; width: 100%; height: 6px; }
    .deck-fab { width: 36px; height: 36px; }
    .blog-deck-controls .deck-prev,
    .blog-deck-controls .deck-next {
        padding: 10px 12px;
        font-size: 0.95rem;
        min-width: 0;
        width: 100%;
        white-space: nowrap; 
    }
}


.skills {
    background: var(--black-secondary);
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--spacing-md);
}

.skill-card {
    position: relative;
    height: 200px;
    perspective: 1000px;
    cursor: pointer;
}

.skill-front,
.skill-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-md);
    transition: transform var(--transition-medium);
}

.skill-front {
    background: var(--black-primary);
    border: 2px solid rgba(230, 57, 70, 0.2);
}

.skill-back {
    background: var(--red-primary);
    transform: rotateY(180deg);
}

.skill-card:hover .skill-front {
    transform: rotateY(180deg);
}

.skill-card:hover .skill-back {
    transform: rotateY(0);
}

.skill-front i {
    font-size: 3rem;
    color: var(--red-primary);
    margin-bottom: var(--spacing-sm);
    transition: color var(--transition-fast);
}

.skill-card:hover .skill-front i {
    color: var(--red-secondary);
}

.skill-front h3 {
    color: var(--white);
    text-align: center;
}

.skill-back h3 {
    color: var(--white);
    text-align: center;
    margin-bottom: var(--spacing-xs);
}

.skill-back p {
    color: rgba(255, 255, 255, 0.8);
    text-align: center;
    font-size: 0.9rem;
    margin-bottom: var(--spacing-sm);
}




.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-lg);
}

.contact-info h3 {
    color: var(--red-primary);
    margin-bottom: var(--spacing-sm);
}

.contact-connect-description {
    margin-bottom: var(--spacing-sm);
}

.contact-connect-description p {
    margin-bottom: var(--spacing-xs);
}

.contact-details {
    margin: var(--spacing-md) 0;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-sm);
    padding: var(--spacing-sm);
    background: rgba(230, 57, 70, 0.1);
    border-radius: 8px;
    transition: transform var(--transition-fast);
}

.contact-item:hover {
    transform: translateX(10px);
}

.contact-item i {
    color: var(--red-primary);
    font-size: 1.2rem;
    width: 20px;
}

.social-links {
    display: flex;
    gap: var(--spacing-sm);
    margin-top: var(--spacing-md);
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background: rgba(230, 57, 70, 0.1);
    border-radius: 50%;
    color: var(--white);
    text-decoration: none;
    transition: all var(--transition-fast);
}

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

.social-link i {
    font-size: 1.2rem;
}


.contact-form {
    background: var(--black-secondary);
    padding: var(--spacing-md);
    border-radius: 12px;
    border: 1px solid rgba(230, 57, 70, 0.2);
}

.form-group {
    position: relative;
    margin-bottom: var(--spacing-md);
}


.form-group textarea {
    position: relative;
    min-height: 120px;
    resize: vertical;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 15px;
    background: transparent;
    border: 2px solid rgba(230, 57, 70, 0.3);
    border-radius: 8px;
    color: var(--white);
    font-size: 1rem;
    transition: all var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--red-primary);
    box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.1);
}

.form-group label {
    position: absolute;
    top: 15px;
    left: 15px;
    color: var(--gray-medium);
    transition: all var(--transition-fast);
    pointer-events: none;
    background: transparent;
    padding: 0 5px;
}

.form-group input:focus + label,
.form-group input:valid + label,
.form-group textarea:focus + label,
.form-group textarea:valid + label {
    opacity: 0;
    visibility: hidden;
}


.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

.modal-content {
    background-color: var(--black-secondary);
    margin: 5% auto;
    padding: var(--spacing-md);
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    position: relative;
    border: 2px solid var(--red-primary);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.8) translateY(-50px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 2rem;
    color: var(--red-primary);
    cursor: pointer;
    transition: transform var(--transition-fast);
}

.modal-close:hover {
    transform: rotate(90deg);
}

.modal-body h2 {
    color: var(--red-primary);
    margin-bottom: var(--spacing-sm);
}

.modal-tech {
    margin: var(--spacing-md) 0;
}

.modal-tech h3 {
    color: var(--white);
    margin-bottom: var(--spacing-sm);
}

.modal-links {
    margin-top: var(--spacing-md);
}

.modal-links a {
    display: inline-block;
    text-decoration: none;
    cursor: pointer;
    z-index: 1001;
    position: relative;
}


.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--red-primary);
    color: var(--white);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all var(--transition-fast);
    z-index: 1000;
    will-change: transform;
}

.back-to-top:hover {
    background: var(--red-secondary);
    transform: scale(1.1);
}

.back-to-top.show {
    display: flex;
    animation: slideInUp 0.3s ease-out;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}


.theme-toggle {
    position: fixed;
    top: 100px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--red-primary);
    color: var(--white);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all var(--transition-fast);
    z-index: 1000;
}

.theme-toggle:hover {
    background: var(--red-secondary);
    transform: scale(1.1);
}


.experience {
    padding: var(--spacing-xl) 0;
    background: linear-gradient(135deg, var(--black-secondary) 0%, var(--black-primary) 100%);
}

.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 20px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 30px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, var(--red-primary) 0%, var(--red-secondary) 100%);
    border-radius: 1px;
}

.timeline-item {
    position: relative;
    margin-bottom: 60px;
    padding-left: 80px;
}

.timeline-marker {
    position: absolute;
    left: 0;
    top: 0;
    width: 60px;
    height: 60px;
    background: var(--black-primary);
    border: 3px solid var(--red-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
    transition: all var(--transition-medium);
    transform: translateX(-1px);
}

.timeline-marker:hover {
    transform: scale(1.1);
    box-shadow: 0 0 20px rgba(230, 57, 70, 0.5);
}

.timeline-icon {
    color: var(--red-primary);
    font-size: 1.2rem;
}

.timeline-content {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(230, 57, 70, 0.2);
    border-radius: 15px;
    padding: 30px;
    backdrop-filter: blur(10px);
    transition: all var(--transition-medium);
}

.timeline-content:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(230, 57, 70, 0.4);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.timeline-header h3 {
    color: var(--white);
    font-size: 1.4rem;
    margin-bottom: 15px;
    font-weight: 600;
}

.company-info {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}

.company-logo {
    flex-shrink: 0;
}

.logo-placeholder {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9rem;
    color: var(--white);
}

.company-logo-img {
    width: 50px;
    height: 50px;
    object-fit: contain;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    padding: 5px;
    transition: all var(--transition-fast);
}

.company-logo-img:hover {
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(230, 57, 70, 0.3);
}

.logo-placeholder.ntt-data {
    background: linear-gradient(135deg, #1e3a8a, #3b82f6);
}

.logo-placeholder.bitdefender {
    background: linear-gradient(135deg, #dc2626, #ef4444);
}

.company-details h4 {
    color: var(--red-primary);
    font-size: 1.2rem;
    margin-bottom: 5px;
    font-weight: 600;
}

.company-details p {
    color: var(--gray-medium);
    font-size: 0.9rem;
    margin: 2px 0;
}

.employment-type {
    color: var(--red-secondary) !important;
    font-weight: 500;
}

.timeline-skills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 15px;
}

.skill-tag {
    background: rgba(230, 57, 70, 0.2);
    color: var(--red-primary);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    border: 1px solid rgba(230, 57, 70, 0.3);
    transition: all var(--transition-fast);
}

.skill-tag:hover {
    background: rgba(230, 57, 70, 0.3);
    transform: translateY(-2px);
}


.education {
    padding: var(--spacing-xl) 0;
    background: linear-gradient(135deg, var(--black-primary) 0%, var(--black-secondary) 100%);
}

.education-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.education-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(230, 57, 70, 0.2);
    border-radius: 20px;
    padding: 30px;
    backdrop-filter: blur(10px);
    transition: all var(--transition-medium);
    position: relative;
    overflow: hidden;
}

.education-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--red-primary), var(--red-secondary));
    transform: scaleX(0);
    transition: transform var(--transition-medium);
}

.education-card:hover::before {
    transform: scaleX(1);
}

.education-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(230, 57, 70, 0.4);
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.education-header {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 20px;
}

.university-logo {
    flex-shrink: 0;
}

.university-logo-img {
    width: 60px;
    height: 60px;
    object-fit: contain;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    padding: 5px;
    transition: all var(--transition-fast);
}

.university-logo-img:hover {
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(230, 57, 70, 0.3);
}

.logo-placeholder.tu-cluj {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #dc2626, #991b1b);
    border-radius: 12px;
    font-size: 1.2rem;
    font-weight: bold;
}

.education-details h3 {
    color: var(--white);
    font-size: 1.3rem;
    margin-bottom: 8px;
    font-weight: 600;
    line-height: 1.3;
}

.education-details h4 {
    color: var(--red-primary);
    font-size: 1.1rem;
    margin-bottom: 8px;
    font-weight: 500;
}

.education-details p {
    color: var(--gray-medium);
    font-size: 0.9rem;
    margin: 3px 0;
}

.education-grade {
    color: #10b981 !important;
    font-weight: 600;
}

.education-status {
    color: var(--red-secondary) !important;
    font-weight: 500;
}

.education-content {
    color: var(--gray-medium);
    line-height: 1.6;
}

.education-content p {
    margin-bottom: 15px;
}

.education-achievements h5 {
    color: var(--white);
    font-size: 1rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.education-achievements ul {
    list-style: none;
    padding: 0;
}

.education-achievements li {
    color: var(--gray-medium);
    margin-bottom: 8px;
    padding-left: 20px;
    position: relative;
}

.education-achievements li::before {
    content: '▸';
    color: var(--red-primary);
    position: absolute;
    left: 0;
    font-weight: bold;
}


[data-theme="light"] .timeline-content {
    background: rgba(0, 0, 0, 0.05);
    border-color: rgba(230, 57, 70, 0.3);
}

[data-theme="light"] .timeline-content:hover {
    background: rgba(0, 0, 0, 0.08);
    border-color: rgba(230, 57, 70, 0.5);
}

[data-theme="light"] .education-card {
    background: rgba(0, 0, 0, 0.05);
    border-color: rgba(230, 57, 70, 0.3);
}

[data-theme="light"] .education-card:hover {
    background: rgba(0, 0, 0, 0.08);
    border-color: rgba(230, 57, 70, 0.5);
}

[data-theme="light"] .timeline-header h3,
[data-theme="light"] .education-details h3 {
    color: #000000;
}

[data-theme="light"] .education-content,
[data-theme="light"] .education-achievements li {
    color: #333333;
}


[data-theme="light"] .navbar {
    background: #ffffff !important;
    backdrop-filter: blur(10px);
    border-bottom: 2px solid rgba(230, 57, 70, 0.1);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .nav-link {
    color: #333333 !important;
    font-weight: 600 !important;
    text-shadow: none !important;
    opacity: 1 !important;
}

[data-theme="light"] .nav-link:hover {
    color: var(--red-primary) !important;
    text-shadow: none !important;
    opacity: 1 !important;
}

[data-theme="light"] .bar {
    background: #333333;
}

[data-theme="light"] .nav-toggle.active .bar:nth-child(2) {
    background: #333333;
}

[data-theme="light"] .nav-toggle.active .bar:nth-child(1) {
    background: #333333;
}

[data-theme="light"] .nav-toggle.active .bar:nth-child(3) {
    background: #333333;
}


.nav-link {
    color: #ffffff !important;
    font-weight: 600 !important;
    text-shadow: 0 0 2px rgba(0, 0, 0, 0.3) !important;
}

.nav-link:hover {
    color: var(--red-primary) !important;
    text-shadow: 0 0 4px rgba(0, 0, 0, 0.5) !important;
}


[data-theme="light"] .nav-menu {
    background: transparent !important;
}

[data-theme="light"] .nav-menu .nav-link {
    color: #333333 !important;
    text-shadow: none !important;
    font-weight: 600 !important;
    opacity: 1 !important;
}

[data-theme="light"] .nav-menu .nav-link:hover {
    color: var(--red-primary) !important;
    text-shadow: none !important;
    opacity: 1 !important;
}


@media (max-width: 768px) {
    .timeline {
        padding: 0 10px;
    }
    
    .timeline::before {
        left: 20px;
    }
    
    .timeline-item {
        padding-left: 60px;
        margin-bottom: 40px;
    }
    
    .timeline-marker {
        width: 40px;
        height: 40px;
        transform: translateX(-1px);
    }
    
    .timeline-content {
        padding: 20px;
    }
    
    .company-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .company-logo-img {
        width: 40px;
        height: 40px;
    }
    
    .education-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .education-card {
        padding: 20px;
    }
    
    .education-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .university-logo-img {
        width: 50px;
        height: 50px;
    }
}

@media (max-width: 480px) {
    .timeline-item {
        padding-left: 50px;
    }
    
    .timeline-marker {
        width: 35px;
        height: 35px;
        transform: translateX(-1px);
    }
    
    .timeline-icon {
        font-size: 1rem;
    }
    
    .timeline-content {
        padding: 15px;
    }
    
    .timeline-header h3 {
        font-size: 1.2rem;
    }
    
    .company-logo-img {
        width: 35px;
        height: 35px;
    }
    
    .education-card {
        padding: 15px;
    }
    
    .education-details h3 {
        font-size: 1.1rem;
    }
    
    .university-logo-img {
        width: 45px;
        height: 45px;
    }
}


@media (max-width: 1200px) {
    .container {
        max-width: 95%;
        padding: 0 var(--spacing-sm);
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: var(--spacing-md);
        padding: 0 var(--spacing-sm);
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .about-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
    
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
        gap: var(--spacing-md);
        padding: 0 var(--spacing-sm);
    }
    
    .project-card {
        min-height: 320px;
        width: 100%;
    }
    
    .project-content h3 {
        font-size: 1.3rem;
    }
    
    .project-overlay p {
        font-size: 0.95rem;
    }
    
    .project-icon {
        width: 110px;
        height: 110px;
    }
    
    .project-icon i {
        font-size: 2.8rem;
    }
    
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
        gap: var(--spacing-sm);
    }
    
    .education-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
    
    .research-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
}

@media (max-width: 768px) {
    
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: var(--black-primary) !important;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.3);
        padding: var(--spacing-md) 0;
        backdrop-filter: none;
        border-top: 2px solid rgba(230, 57, 70, 0.3);
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    
    .nav-menu .nav-link {
        color: var(--white) !important;
        font-weight: 600 !important;
        text-shadow: none !important;
        opacity: 1 !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        padding: 15px 20px;
        transition: all 0.3s ease;
        display: block;
        width: 100%;
        text-align: center;
    }
    
    .nav-menu .nav-link:hover {
        color: var(--red-primary) !important;
        background-color: rgba(230, 57, 70, 0.1);
        text-shadow: none !important;
        opacity: 1 !important;
    }
    
    .nav-menu .nav-link:last-child {
        border-bottom: none;
    }
    
    
    [data-theme="light"] .nav-menu {
        background-color: #ffffff !important;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.15);
        border-top: 2px solid rgba(230, 57, 70, 0.2);
        backdrop-filter: none;
    }
    
    [data-theme="light"] .nav-menu .nav-link {
        color: #333333 !important;
        font-weight: 600 !important;
        text-shadow: none !important;
        opacity: 1 !important;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
        padding: 15px 20px;
        transition: all 0.3s ease;
    }
    
    [data-theme="light"] .nav-menu .nav-link:hover {
        color: var(--red-primary) !important;
        background-color: rgba(230, 57, 70, 0.1);
        text-shadow: none !important;
        opacity: 1 !important;
    }
    
    [data-theme="light"] .nav-menu .nav-link:last-child {
        border-bottom: none;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .nav-toggle.active .bar:nth-child(2) {
        opacity: 0;
    }
    
    .nav-toggle.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    
    .nav-toggle.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
    
    
    .hero {
        padding-top: 80px; 
    }
    
    .hero-title {
        font-size: 2.8rem;
        line-height: 1.1;
    }
    
    .hero-subtitle {
        font-size: 1.3rem;
    }
    
    .hero-description {
        font-size: 1.1rem;
    }
    
    .hero-description p {
        white-space: normal;
        line-height: 1.6;
    }
    
    .profile-img {
        width: 280px;
        height: 280px;
    }
    
    
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: var(--spacing-md);
        padding: 0 var(--spacing-sm);
    }
    
    .project-card {
        min-height: 300px;
        width: 100%;
        margin: 0;
    }
    
    .project-image {
        height: 160px;
    }
    
    .project-icon {
        width: 90px;
        height: 90px;
    }
    
    .project-icon i {
        font-size: 2.4rem;
    }
    
    .project-overlay {
        padding: var(--spacing-md);
    }
    
    .project-content h3 {
        font-size: 1.2rem;
        margin-bottom: var(--spacing-sm);
    }
    
    .project-overlay p {
        font-size: 0.9rem;
        margin-bottom: var(--spacing-sm);
    }
    
    
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
        gap: var(--spacing-sm);
    }
    
    .skill-card {
        height: 180px;
    }
    
    .skill-front i {
        font-size: 2.5rem;
    }
    
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }
    
    .contact-form {
        padding: var(--spacing-lg);
    }

    .contact-connect-description p {
        text-align: justify;
    }
    
    
    .hero-buttons {
        flex-direction: row;
        justify-content: center;
        gap: var(--spacing-md);
    }
    
    .btn {
        padding: 14px 28px;
        font-size: 1rem;
    }
    
    
    .section-title {
        font-size: 2.2rem;
    }
    
    
    .timeline-item {
        padding-left: 70px;
        margin-bottom: 50px;
    }
    
    .timeline-marker {
        width: 50px;
        height: 50px;
        transform: translateX(-1px);
    }
    
    .timeline-content {
        padding: 25px;
    }
    
    .company-info {
        flex-direction: row;
        align-items: center;
        gap: 15px;
    }
    
    
    .education-card {
        padding: 25px;
    }
    
    .education-header {
        flex-direction: row;
        align-items: flex-start;
        gap: 20px;
    }
    
    
    .research-card {
        padding: 25px;
    }
    
    .research-header {
        flex-direction: row;
        align-items: center;
        gap: 20px;
    }
    
    
    .nav-controls {
        gap: 12px;
        justify-content: flex-end;
    }
    
    
    .theme-toggle {
        position: static;
        width: 40px;
        height: 40px;
        font-size: 1rem;
        top: auto;
        right: auto;
    }
    
    .lang-dropdown-btn {
        padding: 6px 10px;
        font-size: 0.85rem;
    }
    
    .lang-dropdown-menu {
        right: -15px;
        min-width: 150px;
    }
}

@media (max-width: 480px) {
    
    .container {
        padding: 0 var(--spacing-xs);
        max-width: 100%;
    }
    
    
    .hero {
        min-height: 100vh;
        padding: 20px 0;
        padding-top: 85px; 
    }
    
    .hero-content {
        padding: 0 var(--spacing-xs);
        gap: var(--spacing-sm);
    }
    
    .hero-title {
        font-size: 2.2rem;
        line-height: 1.1;
        margin-bottom: var(--spacing-sm);
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
        margin-bottom: var(--spacing-sm);
    }
    
    .hero-description {
        font-size: 1rem;
        margin-bottom: var(--spacing-md);
    }
    
    .hero-description p {
        white-space: normal;
        line-height: 1.5;
        margin-bottom: 0.5rem;
    }
    
    .profile-img {
        width: 220px;
        height: 220px;
        border-width: 3px;
    }
    
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: var(--spacing-sm);
    }
    
    .btn {
        padding: 12px 24px;
        font-size: 0.95rem;
        width: 100%;
        max-width: 250px;
    }
    
    
    .nav-container {
        padding: 0 var(--spacing-xs);
        height: 65px;
    }
    
    .nav-logo a {
        font-size: 1.3rem;
    }
    
    .nav-controls {
        gap: 8px;
        justify-content: flex-end;
    }
    
    
    .theme-toggle {
        position: static;
        width: 40px;
        height: 40px;
        font-size: 1rem;
        top: auto;
        right: auto;
    }
    
    .lang-dropdown-btn {
        padding: 5px 8px;
        font-size: 0.8rem;
    }
    
    .lang-dropdown-menu {
        right: -10px;
        min-width: 130px;
    }
    
    .lang-option {
        padding: 8px 10px;
        font-size: 0.8rem;
    }
    
    
    .section-title {
        font-size: 1.9rem;
        margin-bottom: var(--spacing-md);
    }
    
    
    .projects-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-sm);
        padding: 0 var(--spacing-xs);
    }
    
    .project-card {
        min-height: 260px;
        margin: 0;
    }
    
    .project-image {
        height: 140px;
    }
    
    .project-icon {
        width: 70px;
        height: 70px;
    }
    
    .project-icon i {
        font-size: 2rem;
    }
    
    .project-overlay {
        padding: var(--spacing-sm);
    }
    
    .project-content h3 {
        font-size: 1rem;
        margin-bottom: var(--spacing-xs);
    }
    
    .project-overlay p {
        font-size: 0.8rem;
        margin-bottom: var(--spacing-sm);
    }
    
    
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
        gap: var(--spacing-xs);
    }
    
    .skill-card {
        height: 150px;
    }
    
    .skill-front i {
        font-size: 2rem;
    }
    
    .skill-front h3 {
        font-size: 1rem;
    }
    
    .skill-back h3 {
        font-size: 1rem;
    }
    
    .skill-back p {
        font-size: 0.8rem;
    }
    
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
    
    .contact-form {
        padding: var(--spacing-md);
    }

    .contact-connect-description p {
        text-align: justify;
    }
    
    .form-group input,
    .form-group textarea {
        padding: 12px;
        font-size: 0.95rem;
    }
    
    .contact-item {
        padding: var(--spacing-xs);
        margin-bottom: var(--spacing-xs);
    }
    
    .social-links {
        gap: var(--spacing-xs);
    }
    
    .social-link {
        width: 45px;
        height: 45px;
    }
    
    
    .timeline-item {
        padding-left: 45px;
        margin-bottom: 35px;
    }
    
    .timeline-marker {
        width: 35px;
        height: 35px;
        transform: translateX(-1px);
    }
    
    .timeline-icon {
        font-size: 0.9rem;
    }
    
    .timeline-content {
        padding: 15px;
    }
    
    .timeline-header h3 {
        font-size: 1.1rem;
        margin-bottom: 10px;
    }
    
    .company-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .company-logo-img {
        width: 35px;
        height: 35px;
    }
    
    .company-details h4 {
        font-size: 1rem;
    }
    
    .company-details p {
        font-size: 0.8rem;
    }
    
    
    .education-card {
        padding: 15px;
    }
    
    .education-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .university-logo-img {
        width: 45px;
        height: 45px;
    }
    
    .education-details h3 {
        font-size: 1rem;
        line-height: 1.2;
    }
    
    .education-details h4 {
        font-size: 0.9rem;
    }
    
    .education-details p {
        font-size: 0.8rem;
    }
    
    
    .research-card {
        padding: 15px;
    }
    
    .research-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .research-icon {
        width: 45px;
        height: 45px;
        font-size: 1.2rem;
    }
    
    .research-details h3 {
        font-size: 1rem;
        line-height: 1.2;
    }
    
    .research-abstract p {
        font-size: 0.85rem;
        line-height: 1.5;
    }
    
    .keyword-tags {
        gap: 6px;
    }
    
    .keyword-tag {
        padding: 4px 8px;
        font-size: 0.75rem;
    }
    
    
    .modal-content {
        width: 95%;
        margin: 5% auto;
        padding: var(--spacing-sm);
    }
    
    .cv-modal-content {
        width: 95vw;
        height: 90vh;
        max-width: 95vw;
        max-height: 90vh;
    }
    
    .cv-modal-content .modal-header {
        padding: 10px 15px;
        flex-direction: column;
        gap: 10px;
    }
    
    .cv-actions {
        flex-direction: column;
        gap: 8px;
    }
    
    .cv-actions .btn {
        flex: 1;
        text-align: center;
        padding: 8px 12px;
        font-size: 0.85rem;
    }
    
    
    .back-to-top {
        width: 45px;
        height: 45px;
        font-size: 1rem;
        bottom: 20px;
        right: 20px;
    }
    
    
    .about-text p {
        font-size: 1rem;
        line-height: 1.6;
        text-align: justify;
    }
    
    .about-stats {
        grid-template-columns: 1fr;
        gap: var(--spacing-sm);
    }
    
    .stat {
        padding: var(--spacing-sm);
    }
    
    .stat h3 {
        font-size: 2rem;
    }
    
    .stat p {
        font-size: 0.9rem;
    }
    
    
    .scroll-cue {
        bottom: 20px;
        font-size: 1.2rem;
    }
    
    
    .loading-spinner {
        width: 40px;
        height: 40px;
        border-width: 2px;
    }
    
    
    .install-prompt {
        bottom: 15px;
        left: 10px;
        right: 10px;
        transform: none;
        padding: 12px 15px;
        font-size: 0.85rem;
    }
    
    .install-prompt button {
        padding: 6px 12px;
        font-size: 0.8rem;
        margin-left: 8px;
    }
    
    
    .offline-indicator {
        top: 15px;
        right: 15px;
        padding: 8px 12px;
        font-size: 0.75rem;
    }
}


@media (max-width: 360px) {
    .hero-title {
        font-size: 1.9rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .profile-img {
        width: 180px;
        height: 180px;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
        max-width: 200px;
    }
    
    .section-title {
        font-size: 1.7rem;
    }
    
    .project-card {
        min-height: 240px;
    }
    
    .project-image {
        height: 120px;
    }
    
    .project-icon {
        width: 60px;
        height: 60px;
    }
    
    .project-icon i {
        font-size: 1.8rem;
    }
    
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    }
    
    .skill-card {
        height: 130px;
    }
    
    .skill-front i {
        font-size: 1.8rem;
    }
    
    .skill-front h3,
    .skill-back h3 {
        font-size: 0.9rem;
    }
    
    .skill-back p {
        font-size: 0.75rem;
    }
    
    .timeline-item {
        padding-left: 40px;
    }
    
    .timeline-marker {
        width: 30px;
        height: 30px;
        transform: translateX(-1px);
    }
    
    .timeline-icon {
        font-size: 0.8rem;
    }
    
    .company-logo-img {
        width: 30px;
        height: 30px;
    }
    
    .university-logo-img {
        width: 40px;
        height: 40px;
    }
    
    .research-icon {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
    }
}


@media (max-width: 768px) and (orientation: landscape) {
    .hero {
        min-height: 100vh;
        padding: 10px 0;
    }
    
    .hero-content {
        grid-template-columns: 1fr 1fr;
        gap: var(--spacing-sm);
        align-items: center;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-description {
        font-size: 0.9rem;
    }
    
    .profile-img {
        width: 150px;
        height: 150px;
    }
    
    .hero-buttons {
        flex-direction: row;
        gap: var(--spacing-sm);
    }
    
    .btn {
        padding: 8px 16px;
        font-size: 0.85rem;
        max-width: none;
    }
    
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
    
    .project-card {
        min-height: 200px;
    }
    
    .project-image {
        height: 100px;
    }
    
    .project-icon {
        width: 50px;
        height: 50px;
    }
    
    .project-icon i {
        font-size: 1.5rem;
    }
    
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    }
    
    .skill-card {
        height: 120px;
    }
    
    .skill-front i {
        font-size: 1.8rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .nav-container {
        height: 60px;
    }
    
    .back-to-top {
        width: 40px;
        height: 40px;
        font-size: 0.9rem;
    }
}


@media (min-width: 481px) and (max-width: 767px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .profile-img {
        width: 240px;
        height: 240px;
    }
    
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
    
    .project-card {
        min-height: 280px;
    }
    
    .project-image {
        height: 150px;
    }
    
    .project-icon {
        width: 80px;
        height: 80px;
    }
    
    .project-icon i {
        font-size: 2.2rem;
    }
    
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
    
    .skill-card {
        height: 160px;
    }
    
    .skill-front i {
        font-size: 2.2rem;
    }
    
    .btn {
        padding: 14px 26px;
        font-size: 1rem;
        max-width: 280px;
    }
    
    .section-title {
        font-size: 2.1rem;
    }
}


@media (min-width: 769px) and (max-width: 1024px) and (orientation: landscape) {
    .hero-content {
        grid-template-columns: 1fr 1fr;
        gap: var(--spacing-lg);
    }
    
    .hero-title {
        font-size: 3.2rem;
    }
    
    .hero-subtitle {
        font-size: 1.4rem;
    }
    
    .profile-img {
        width: 300px;
        height: 300px;
    }
    
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    }
    
    .project-card {
        min-height: 320px;
    }
    
    .project-image {
        height: 180px;
    }
    
    .project-icon {
        width: 100px;
        height: 100px;
    }
    
    .project-icon i {
        font-size: 2.8rem;
    }
    
    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    }
    
    .skill-card {
        height: 190px;
    }
    
    .skill-front i {
        font-size: 2.8rem;
    }
}


@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .profile-img {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
    
    .company-logo-img,
    .university-logo-img {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}


@media (prefers-reduced-motion: reduce) {
    .project-card,
    .skill-card,
    .timeline-item,
    .education-card,
    .research-card {
        transition: none;
        animation: none;
    }
    
    .project-card:hover,
    .skill-card:hover,
    .timeline-content:hover,
    .education-card:hover,
    .research-card:hover {
        transform: none;
    }
    
    .btn:hover {
        transform: none;
    }
    
    .nav-link::after {
        transition: none;
    }
}


@media (prefers-contrast: high) {
    .project-card,
    .skill-card,
    .timeline-content,
    .education-card,
    .research-card {
        border-width: 2px;
        border-color: var(--red-primary);
    }
    
    .btn {
        border-width: 2px;
    }
    
    .nav-link::after {
        height: 3px;
    }
}


.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: var(--spacing-xs); }
.mb-2 { margin-bottom: var(--spacing-sm); }
.mb-3 { margin-bottom: var(--spacing-md); }
.mb-4 { margin-bottom: var(--spacing-lg); }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: var(--spacing-xs); }
.mt-2 { margin-top: var(--spacing-sm); }
.mt-3 { margin-top: var(--spacing-md); }
.mt-4 { margin-top: var(--spacing-lg); }


*:focus {
    outline: 2px solid var(--red-primary);
    outline-offset: 2px;
}


html {
    scroll-behavior: smooth;
}


section, .hero {
    opacity: 1;
    transform: translateY(0);
    transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    will-change: transform, opacity;
}

.section-hidden {
    opacity: 0.3;
    transform: translateY(50px);
}

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

.scroll-down {
    animation: sectionSlideInUp 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.scroll-up {
    animation: sectionSlideInDown 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes sectionSlideInUp {
    from {
        opacity: 0;
        transform: translateY(60px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes sectionSlideInDown {
    from {
        opacity: 0;
        transform: translateY(-60px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}


.animate-in-up {
    animation: elementSlideInUp 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.animate-in-down {
    animation: elementSlideInDown 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

.animate-out {
    animation: elementSlideOut 0.4s cubic-bezier(0.55, 0.085, 0.68, 0.53) forwards;
}

@keyframes elementSlideInUp {
    from {
        opacity: 0;
        transform: translateY(40px) scale(0.9);
        filter: blur(5px);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

@keyframes elementSlideInDown {
    from {
        opacity: 0;
        transform: translateY(-40px) scale(0.9);
        filter: blur(5px);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

@keyframes elementSlideOut {
    from {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
    to {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
        filter: blur(3px);
    }
}


.project-card {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
    transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.project-card.animate-in-up,
.project-card.animate-in-down {
    opacity: 1;
    transform: translateY(0) scale(1);
}


.skill-card {
    opacity: 0;
    transform: translateY(30px) rotateY(10deg);
    transition: all 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.skill-card.animate-in-up,
.skill-card.animate-in-down {
    opacity: 1;
    transform: translateY(0) rotateY(0deg);
}


.stat {
    opacity: 0;
    transform: translateY(20px) scale(0.8);
    transition: all 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.stat.animate-in-up,
.stat.animate-in-down {
    opacity: 1;
    transform: translateY(0) scale(1);
}


.about-text p,
.hero-text > * {
    opacity: 0;
    transform: translateX(-30px);
    transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.about-text p.animate-in-up,
.about-text p.animate-in-down,
.hero-text > *.animate-in-up,
.hero-text > *.animate-in-down {
    opacity: 1;
    transform: translateX(0);
}


.section-title {
    opacity: 0;
    transform: translateY(-20px) scale(0.9);
    transition: all 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.section-title.animate-in-up,
.section-title.animate-in-down {
    opacity: 1;
    transform: translateY(0) scale(1);
}


.contact-item {
    opacity: 0;
    transform: translateX(-40px);
    transition: all 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.contact-item.animate-in-up,
.contact-item.animate-in-down {
    opacity: 1;
    transform: translateX(0);
}


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

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


.btn-primary {
    animation: breathing 3s ease-in-out infinite;
}

@keyframes breathing {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}


.tech-tag {
    display: inline-block;
    background: var(--red-primary);
    color: var(--white);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    margin: 5px;
    transition: all var(--transition-fast);
}

.tech-tag:hover {
    background: var(--red-secondary);
    transform: translateY(-2px);
}


.skill-card.flipped .skill-front {
    transform: rotateY(180deg);
}

.skill-card.flipped .skill-back {
    transform: rotateY(0);
}


body {
    opacity: 1;
    transition: opacity 0.5s ease-in-out;
}

body.loaded {
    opacity: 1;
}


body.smooth-scrolling section {
    transition-duration: 0.3s;
}


@media (prefers-reduced-motion: reduce) {
    section, .hero {
        transition: none;
        animation: none;
    }
    
    .animate-in-up,
    .animate-in-down,
    .animate-out {
        animation: none;
        opacity: 1;
        transform: none;
        filter: none;
    }
    
    .project-card,
    .skill-card,
    .stat,
    .about-text p,
    .hero-text > *,
    .section-title,
    .contact-item {
        opacity: 1;
        transform: none;
        transition: none;
    }
}


@media (max-width: 768px) {
    .section-hidden {
        transform: translateY(30px);
    }
    
    @keyframes sectionSlideInUp {
        from {
            opacity: 0;
            transform: translateY(30px) scale(0.98);
        }
        to {
            opacity: 1;
            transform: translateY(0) scale(1);
        }
    }
    
    @keyframes sectionSlideInDown {
        from {
            opacity: 0;
            transform: translateY(-30px) scale(0.98);
        }
        to {
            opacity: 1;
            transform: translateY(0) scale(1);
        }
    }
    
    @keyframes elementSlideInUp {
        from {
            opacity: 0;
            transform: translateY(20px) scale(0.95);
            filter: blur(2px);
        }
        to {
            opacity: 1;
            transform: translateY(0) scale(1);
            filter: blur(0);
        }
    }
    
    @keyframes elementSlideInDown {
        from {
            opacity: 0;
            transform: translateY(-20px) scale(0.95);
            filter: blur(2px);
        }
        to {
            opacity: 1;
            transform: translateY(0) scale(1);
            filter: blur(0);
        }
    }
}


.mobile-optimized .project-card {
    animation: none !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.mobile-optimized .project-card:hover {
    transform: translateY(-5px) scale(1.01);
}

.mobile-optimized .project-icon {
    transition: transform 0.3s ease;
}

.mobile-optimized .project-card:hover .project-icon {
    transform: translate(-50%, -50%) scale(1.05);
}


.projects-grid {
    transition: none;
}

.projects-grid * {
    transition: transform 0.3s ease, box-shadow 0.3s ease, opacity 0.3s ease;
}


@media (max-width: 768px) {
    .project-card {
        will-change: transform;
        backface-visibility: hidden;
        transform: translateZ(0);
    }
    
    .project-overlay {
        backface-visibility: hidden;
        transform: translateZ(0);
    }
    
    .project-icon {
        backface-visibility: hidden;
        transform: translateZ(0) translate(-50%, -50%);
    }
}


img {
    opacity: 1;
    transition: opacity 0.3s ease-in-out;
}

img.loaded {
    opacity: 1;
} 


.page-transition {
  opacity: 0;
  animation: fadeIn 0.8s ease-in-out forwards;
}

.transitioning {
  pointer-events: none;
}

.transitioning * {
  transition: all 0.3s ease-in-out;
}


html {
  scroll-behavior: smooth;
}


section {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease-in-out;
}

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


.section-animate {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s ease-in-out;
}

.section-animate.animate-in {
  opacity: 1;
  transform: translateY(0);
}


.btn {
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.btn:hover::before {
  left: 100%;
}


.nav-link {
  position: relative;
  transition: all 0.3s ease;
}

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

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


.project-card {
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-card:hover {
  transform: translateY(-10px) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}


.skill-card {
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.skill-card:hover {
  transform: translateY(-5px) scale(1.05);
}


.timeline-item {
  opacity: 0;
  transform: translateX(-50px);
  transition: all 0.6s ease-in-out;
}

.timeline-item.animate-in {
  opacity: 1;
  transform: translateX(0);
}


.education-card {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease-in-out;
}

.education-card.animate-in {
  opacity: 1;
  transform: translateY(0);
}


.loading {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--black-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  transition: opacity 0.5s ease;
}

.loading.hidden {
  opacity: 0;
  pointer-events: none;
}

.loading-spinner {
  width: 50px;
  height: 50px;
  border: 3px solid rgba(230, 57, 70, 0.3);
  border-top: 3px solid var(--red-primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}


.install-prompt {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--black-primary);
  border: 1px solid var(--red-primary);
  border-radius: 10px;
  padding: 15px 20px;
  color: var(--white);
  font-size: 0.9rem;
  z-index: 1000;
  display: none;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

.install-prompt.show {
  display: block;
  animation: slideInUp 0.3s ease;
}

.install-prompt button {
  background: var(--red-primary);
  color: var(--white);
  border: none;
  padding: 8px 15px;
  border-radius: 5px;
  margin-left: 10px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.install-prompt button:hover {
  background: var(--red-secondary);
  transform: translateY(-2px);
}


.offline-indicator {
  position: fixed;
  top: 20px;
  right: 20px;
  background: #dc2626;
  color: white;
  padding: 10px 15px;
  border-radius: 5px;
  font-size: 0.8rem;
  z-index: 1000;
  display: none;
}

.offline-indicator.show {
  display: block;
  animation: slideInRight 0.3s ease;
}


@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  
  .page-transition {
    opacity: 1;
    animation: none;
  }
  
  section {
    opacity: 1;
    transform: none;
  }
}


@media (prefers-contrast: high) {
  :root {
    --red-primary: #ff0000;
    --red-secondary: #cc0000;
  }
  
  .btn {
    border: 2px solid currentColor;
  }
  
  .nav-link::after {
    height: 3px;
  }
}


.cv-modal-content {
    max-width: 90vw;
    max-height: 90vh;
    width: 1000px;
    height: 80vh;
    display: flex;
    flex-direction: column;
}

.cv-modal-content .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 30px;
    border-bottom: 1px solid rgba(230, 57, 70, 0.2);
    background: rgba(255, 255, 255, 0.05);
}

.cv-modal-content .modal-header h2 {
    margin: 0;
    color: var(--white);
    font-size: 1.5rem;
}

.cv-actions {
    display: flex;
    gap: 10px;
}

.cv-actions .btn {
    padding: 8px 15px;
    font-size: 0.9rem;
}

.cv-modal-body {
    flex: 1;
    padding: 0;
    overflow: hidden;
}

#cv-iframe {
    border: none;
    width: 100%;
    height: 100%;
    background: white;
    border-radius: 0 0 15px 15px;
}


@media (max-width: 768px) {
    .cv-modal-content {
        max-width: 95vw;
        max-height: 95vh;
        width: 95vw;
        height: 90vh;
    }
    
    .cv-modal-content .modal-header {
        padding: 15px 20px;
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }
    
    .cv-actions {
        width: 100%;
        justify-content: space-between;
    }
    
    .cv-actions .btn {
        flex: 1;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .cv-modal-content {
        width: 100vw;
        height: 100vh;
        max-width: 100vw;
        max-height: 100vh;
        border-radius: 0;
    }
    
    .cv-modal-content .modal-header {
        padding: 10px 15px;
    }
    
    .cv-actions {
        flex-direction: column;
        gap: 8px;
    }
}


@media print {
    .navbar,
    .back-to-top,
    .theme-toggle,
    .install-prompt,
    .offline-indicator {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    .hero {
        background: white !important;
    }
    
    section {
        page-break-inside: avoid;
    }
} 


.stat {
    position: relative;
    overflow: hidden;
}

.counter {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--red-primary);
    transition: all 0.3s ease;
    display: inline-block;
}

.counter.animate {
    animation: counterPulse 0.6s ease-out;
}

@keyframes counterPulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
} 


.research {
    padding: 80px 0;
    background: var(--dark-bg);
}

.research-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.research-card {
    background: var(--card-bg);
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.research-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--red-primary), #ff6b6b);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.research-card:hover::before {
    transform: scaleX(1);
}

.research-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
}

.research-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 25px;
}

.research-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--red-primary), #ff6b6b);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.5rem;
    box-shadow: 0 4px 15px rgba(230, 57, 70, 0.3);
}

.research-details h3 {
    color: var(--white);
    font-size: 1.2rem;
    font-weight: 600;
    margin: 0 0 8px 0;
    line-height: 1.3;
    word-wrap: break-word;
    hyphens: auto;
}

.research-date {
    color: var(--red-primary);
    font-weight: 600;
    margin: 0 0 5px 0;
    font-size: 0.9rem;
}

.research-institution {
    color: var(--text-secondary);
    margin: 0 0 5px 0;
    font-size: 0.9rem;
}

.research-type {
    color: var(--text-secondary);
    margin: 0;
    font-size: 0.9rem;
    font-style: italic;
}

.research-authors {
    color: var(--text-secondary);
    margin: 0 0 5px 0;
    font-size: 0.9rem;
    font-style: italic;
}

.research-content p {
    color: var(--text-primary);
    line-height: 1.6;
    margin-bottom: 20px;
}

.research-abstract {
    margin-bottom: 25px;
}

.research-abstract h4 {
    color: var(--white);
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 15px 0;
}

.research-abstract p {
    color: var(--text-primary);
    line-height: 1.7;
    margin-bottom: 12px;
    text-align: justify;
    font-size: 0.95rem;
    letter-spacing: 0.01em;
}

.research-keywords {
    margin-bottom: 25px;
}

.research-keywords h4 {
    color: var(--white);
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 15px 0;
}

.keyword-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.keyword-tag {
    background: var(--red-primary);
    color: var(--white);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.keyword-tag:hover {
    background: var(--red-secondary);
    transform: translateY(-1px);
}

.research-highlights {
    margin-bottom: 25px;
}

.research-highlights h4 {
    color: var(--white);
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0 0 15px 0;
}

.research-highlights ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.research-highlights li {
    color: var(--text-primary);
    padding: 8px 0;
    position: relative;
    padding-left: 20px;
    line-height: 1.5;
}

.research-highlights li::before {
    content: '•';
    color: var(--red-primary);
    font-weight: bold;
    position: absolute;
    left: 0;
    top: 8px;
}

.research-actions {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.research-actions .btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: 0.9rem;
    font-weight: 500;
}


[data-theme="light"] .research {
    background: #ffffff;
}

[data-theme="light"] .research-card {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .research-details h3 {
    color: #000000;
}

[data-theme="light"] .research-content p {
    color: #333333;
}

[data-theme="light"] .research-highlights h4 {
    color: #000000;
}

[data-theme="light"] .research-highlights li {
    color: #333333;
}

[data-theme="light"] .research-authors {
    color: #333333;
}

[data-theme="light"] .research-abstract h4 {
    color: #000000;
}

[data-theme="light"] .research-abstract p {
    color: #333333;
}

[data-theme="light"] .research-keywords h4 {
    color: #000000;
}

[data-theme="light"] .keyword-tag {
    background: var(--red-primary);
    color: var(--white);
}

[data-theme="light"] .keyword-tag:hover {
    background: var(--red-secondary);
}


[data-theme="light"] .research .section-title {
    color: #000000;
}

[data-theme="light"] .research .section-title::after {
    background: var(--red-primary);
}


[data-theme="light"] .research-date {
    color: var(--red-primary);
}

[data-theme="light"] .research-institution {
    color: #666666;
}

[data-theme="light"] .research-type {
    color: #666666;
}

[data-theme="light"] .research-card:hover {
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
    transform: translateY(-5px);
}

[data-theme="light"] .research-actions .btn-outline {
    border-color: var(--red-primary);
    color: var(--red-primary);
}

[data-theme="light"] .research-actions .btn-outline:hover {
    background: var(--red-primary);
    color: var(--white);
}

[data-theme="light"] .research-actions .btn-primary {
    background: var(--red-primary);
    color: var(--white);
}

[data-theme="light"] .research-actions .btn-primary:hover {
    background: var(--red-secondary);
}


@media (max-width: 768px) {
    .research-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .research-card {
        padding: 25px;
    }
    
    .research-header {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .research-actions {
        flex-direction: column;
    }
    
    .research-actions .btn {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .research-card {
        padding: 20px;
    }
    
    .research-icon {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .research-details h3 {
        font-size: 1rem;
        line-height: 1.2;
        word-wrap: break-word;
        hyphens: auto;
    }
    
    .research-abstract p {
        font-size: 0.9rem;
        line-height: 1.6;
    }
} 


.language-dropdown {
    position: relative;
    display: inline-block;
}

.lang-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 20px;
    color: var(--white);
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    font-weight: 500;
    backdrop-filter: blur(10px);
}

.lang-dropdown-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.lang-dropdown-btn.active {
    background: var(--red-primary);
    color: var(--white);
    box-shadow: 0 2px 8px rgba(230, 57, 70, 0.3);
}

.lang-dropdown-btn .flag {
    font-size: 1.1rem;
}

.lang-dropdown-btn .lang-text {
    font-weight: 600;
}

.lang-dropdown-btn i {
    font-size: 0.8rem;
    transition: transform 0.3s ease;
}

.lang-dropdown-btn.active i {
    transform: rotate(180deg);
}

.lang-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    min-width: 160px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
    margin-top: 8px;
}

.lang-dropdown-menu.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.lang-option {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 12px 16px;
    border: none;
    background: transparent;
    color: var(--white);
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.9rem;
    text-align: left;
}

.lang-option:first-child {
    border-radius: 12px 12px 0 0;
}

.lang-option:last-child {
    border-radius: 0 0 12px 12px;
}

.lang-option:hover {
    background: rgba(255, 255, 255, 0.1);
}

.lang-option.active {
    background: var(--red-primary);
    color: var(--white);
}

.lang-option .flag {
    font-size: 1.1rem;
    min-width: 20px;
}

.lang-option .lang-text {
    font-weight: 500;
}


[data-theme="light"] .lang-dropdown-btn {
    background: rgba(0, 0, 0, 0.1) !important;
    color: #333333 !important;
    border: 1px solid rgba(0, 0, 0, 0.2) !important;
    opacity: 1 !important;
}

[data-theme="light"] .lang-dropdown-btn:hover {
    background: rgba(0, 0, 0, 0.15) !important;
    color: #000000 !important;
    opacity: 1 !important;
}

[data-theme="light"] .lang-dropdown-menu {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

[data-theme="light"] .lang-option {
    color: #000000;
}

[data-theme="light"] .lang-option:hover {
    background: rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .lang-option.active {
    background: var(--red-primary);
    color: var(--white);
}


@media (max-width: 768px) {
    .lang-dropdown-menu {
        right: -20px;
        min-width: 140px;
    }
    
    .lang-option {
        padding: 10px 12px;
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .lang-dropdown-btn {
        padding: 6px 10px;
        font-size: 0.8rem;
    }
    
    .lang-dropdown-menu {
        right: -10px;
        min-width: 120px;
    }
    
    .lang-option {
        padding: 8px 10px;
        font-size: 0.8rem;
    }
}


.nav-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    justify-content: flex-end;
}

.language-dropdown {
    margin-right: auto;
}


[data-theme="light"] .nav-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    justify-content: flex-end;
}

[data-theme="light"] .nav-controls .language-dropdown,
[data-theme="light"] .nav-controls .theme-toggle {
    visibility: visible;
    opacity: 1;
}


[data-theme="light"] .nav-logo a {
    color: var(--red-primary) !important;
}

[data-theme="light"] .nav-logo a:hover {
    color: var(--red-secondary) !important;
}


[data-theme="light"] .nav-container {
    background: transparent;
}


@media (hover: none) and (pointer: coarse) {
    .project-card:hover {
        transform: none;
        box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
    }
    
    .skill-card:hover .skill-front {
        transform: none;
    }
    
    .skill-card:hover .skill-back {
        transform: rotateY(180deg);
    }
    
    .btn:hover {
        transform: none;
    }
    
    .nav-link:hover::after {
        width: 0;
    }
    
    
    .nav-link {
        padding: 12px 8px;
        min-height: 44px;
        display: flex;
        align-items: center;
    }
    
    .btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    .social-link {
        min-width: 44px;
        min-height: 44px;
    }
    
    .lang-dropdown-btn {
        min-height: 44px;
        padding: 12px 16px;
    }
    
    .lang-option {
        min-height: 44px;
        padding: 12px 16px;
    }
    
    .back-to-top {
        min-width: 48px;
        min-height: 48px;
    }
    
    .theme-toggle {
        min-width: 40px;
        min-height: 40px;
    }
    
    .modal-close {
        min-width: 44px;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    
    .hero,
    section {
        -webkit-overflow-scrolling: touch;
    }
    
    
    .form-group input,
    .form-group textarea {
        font-size: 16px;
    }
}


@supports (-webkit-touch-callout: none) {
    .hero {
        min-height: -webkit-fill-available;
    }
    
    .nav-container {
        padding-top: env(safe-area-inset-top);
    }
    
    .back-to-top {
        bottom: calc(20px + env(safe-area-inset-bottom));
    }
    
    .install-prompt {
        bottom: calc(15px + env(safe-area-inset-bottom));
    }
}


@media screen and (-webkit-min-device-pixel-ratio: 0) {
    .project-card {
        will-change: transform;
        backface-visibility: hidden;
        transform: translateZ(0);
    }
    
    .skill-card {
        will-change: transform;
        backface-visibility: hidden;
        transform: translateZ(0);
    }
}


@media screen and (max-width: 480px) {
    .hero {
        min-height: 100vh;
        min-height: 100dvh;
    }
    
    .nav-container {
        height: 70px;
        height: calc(70px + env(safe-area-inset-top));
    }
    
    .nav-menu {
        top: 70px;
        top: calc(70px + env(safe-area-inset-top));
    }
}


@media (prefers-color-scheme: dark) {
    .project-card,
    .skill-card,
    .timeline-content,
    .education-card,
    .research-card {
        background: rgba(255, 255, 255, 0.05);
    }
}


@media (prefers-color-scheme: light) {
    [data-theme="light"] .project-card,
    [data-theme="light"] .skill-card,
    [data-theme="light"] .timeline-content,
    [data-theme="light"] .education-card,
    [data-theme="light"] .research-card {
        background: rgba(0, 0, 0, 0.05);
    }
}


.touch-device .project-card:hover {
    transform: none;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

.touch-device .skill-card:hover .skill-front {
    transform: none;
}

.touch-device .skill-card:hover .skill-back {
    transform: rotateY(180deg);
}

.touch-device .btn:hover {
    transform: none;
}

.touch-device .nav-link:hover::after {
    width: 0;
}


.mobile-safari .hero {
    min-height: -webkit-fill-available;
}

.mobile-safari .nav-container {
    padding-top: env(safe-area-inset-top);
}

.mobile-safari .back-to-top {
    bottom: calc(20px + env(safe-area-inset-bottom));
}

.mobile-safari .install-prompt {
    bottom: calc(15px + env(safe-area-inset-bottom));
}


.mobile-optimized .project-card {
    will-change: transform;
    backface-visibility: hidden;
    transform: translateZ(0);
}

.mobile-optimized .skill-card {
    will-change: transform;
    backface-visibility: hidden;
    transform: translateZ(0);
}

.mobile-optimized .timeline-content,
.mobile-optimized .education-card,
.mobile-optimized .research-card {
    will-change: transform;
    backface-visibility: hidden;
    transform: translateZ(0);
}


@media (max-width: 768px) {
    .project-card,
    .skill-card,
    .btn,
    .nav-link {
        -webkit-user-select: none;
        -moz-user-select: none;
        -ms-user-select: none;
        user-select: none;
    }
    
    
    .about-text,
    .research-content,
    .education-content {
        -webkit-user-select: text;
        -moz-user-select: text;
        -ms-user-select: text;
        user-select: text;
    }
}


@media (max-width: 768px) {
    .loading {
        background: var(--black-primary);
        backdrop-filter: blur(10px);
    }
    
    .loading-spinner {
        width: 40px;
        height: 40px;
        border-width: 2px;
    }
}


@media (max-width: 768px) {
    .btn:focus,
    .nav-link:focus,
    .project-card:focus,
    .skill-card:focus {
        outline: 2px solid var(--red-primary);
        outline-offset: 2px;
    }
    
    
    .project-image:focus,
    .skill-front:focus,
    .skill-back:focus {
        outline: none;
    }
}


.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    max-width: 400px;
    background: var(--card-bg);
    border: 1px solid var(--red-primary);
    border-radius: 8px;
    box-shadow: var(--shadow-heavy);
    animation: slideInRight 0.3s ease-out;
    backdrop-filter: blur(10px);
}

.notification-content {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    color: var(--text-primary);
}

.notification-content i {
    font-size: 18px;
    flex-shrink: 0;
}

.notification-success .notification-content i {
    color: #4CAF50;
}

.notification-error .notification-content i {
    color: var(--red-primary);
}

.notification-info .notification-content i {
    color: #2196F3;
}

.notification-close {
    position: absolute;
    top: 8px;
    right: 8px;
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: var(--transition-fast);
}

.notification-close:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.1);
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}


@media (max-width: 768px) {
    .notification {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
        animation: slideInTop 0.3s ease-out;
    }
    
    @keyframes slideInTop {
        from {
            transform: translateY(-100%);
            opacity: 0;
        }
        to {
            transform: translateY(0);
            opacity: 1;
        }
    }
}


@media (max-width: 768px) {
    .char-counter {
        right: 8px;
        bottom: 8px;
        font-size: 0.75rem;
        padding: 3px 6px;
    }
}


.char-counter {
    position: absolute;
    right: 12px;
    bottom: 12px;
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 400;
    transition: all var(--transition-fast);
    pointer-events: none;
    z-index: 1;
    animation: fadeIn 0.3s ease-out;
    transform: scale(1);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-group {
    position: relative;
}




.btn:disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

.btn i.fa-spinner {
    margin-right: 8px;
}