body {
    font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #f8fafc 0%, #6ba8cc 100%);
    min-height: 100vh;
}

.cv-container {
    max-width: 900px;
    margin: 20px auto;
    background: white;
    box-shadow: 
        0 25px 80px rgba(0,0,0,0.1),
        0 0 0 1px rgba(0,0,0,0.05);
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.4s ease;
    animation: slideInUp 0.8s ease-out;
}

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

.cv-container:hover {
    box-shadow: 
        0 35px 100px rgba(0,0,0,0.15),
        0 0 0 1px rgba(0,0,0,0.08);
}

.header-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 50px 40px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.header-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 20%, rgba(255,255,255,0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255,255,255,0.05) 0%, transparent 50%);
    animation: headerFloat 15s ease-in-out infinite;
}

@keyframes headerFloat {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(180deg); }
}

.profile-img {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    border: 6px solid rgba(255,255,255,0.2);
    margin-bottom: 25px;
    object-fit: cover;
    transition: all 0.4s ease;
    box-shadow: 
        0 15px 35px rgba(0,0,0,0.3),
        0 0 0 3px rgba(255,255,255,0.1);
    position: relative;
    z-index: 1;
}

.profile-img:hover {
    transform: scale(1.05);
    border-color: rgba(255,255,255,0.4);
    box-shadow: 
        0 25px 50px rgba(0,0,0,0.4),
        0 0 0 3px rgba(255,255,255,0.2);
}

.section-title {
    color: #667eea;
    border-bottom: 3px solid transparent;
    background: linear-gradient(90deg, #667eea, #764ba2) no-repeat bottom;
    background-size: 60px 3px;
    padding-bottom: 15px;
    margin-bottom: 30px;
    font-weight: 700;
    font-size: 1.4rem;
    letter-spacing: -0.02em;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-title:hover {
    background-size: 100px 3px;
    color: #5a67d8;
}

.section-title i {
    font-size: 1.2rem;
    background: linear-gradient(135deg, #667eea, #764ba2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.experience-item, .education-item {
    border-left: 4px solid #667eea;
    padding: 25px 0 25px 30px;
    margin-bottom: 35px;
    position: relative;
    transition: all 0.3s ease;
    border-radius: 0 12px 12px 0;
    background: linear-gradient(90deg, rgba(102, 126, 234, 0.02) 0%, transparent 100%);
}

.experience-item:hover, .education-item:hover {
    background: linear-gradient(90deg, rgba(102, 126, 234, 0.05) 0%, transparent 100%);
    transform: translateX(5px);
    padding-left: 35px;
}

.experience-item::before, .education-item::before {
    content: '';
    position: absolute;
    left: -8px;
    top: 15px;
    width: 14px;
    height: 14px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 50%;
    box-shadow: 0 0 0 4px white, 0 0 15px rgba(102, 126, 234, 0.3);
    transition: all 0.3s ease;
}

.experience-item:hover::before, .education-item:hover::before {
    transform: scale(1.2);
    box-shadow: 0 0 0 4px white, 0 0 20px rgba(102, 126, 234, 0.5);
}

.date-range {
    color: #6c757d;
    font-size: 0.9em;
    font-weight: 600;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    padding: 6px 12px;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 8px;
    border: 1px solid #dee2e6;
}

.current-badge {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    padding: 4px 12px;
    border-radius: 15px;
    font-size: 0.75em;
    margin-left: 10px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(40, 167, 69, 0.3);
    animation: pulse 2s infinite;
}

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

.skill-category {
    margin-bottom: 30px;
    animation: fadeInUp 0.6s ease-out;
}

.skill-category h5 {
    color: #495057;
    margin-bottom: 15px;
    font-weight: 600;
    font-size: 1.1rem;
}

.skill-tag {
    display: inline-block;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    color: #495057;
    padding: 8px 16px;
    margin: 4px;
    border-radius: 25px;
    font-size: 0.85em;
    border: 2px solid transparent;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: default;
    position: relative;
    overflow: hidden;
}

.skill-tag::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(102, 126, 234, 0.1), transparent);
    transition: left 0.5s ease;
}

.skill-tag:hover {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
    border-color: rgba(255, 255, 255, 0.2);
}

.skill-tag:hover::before {
    left: 100%;
}

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

.contact-info {
    margin-bottom: 20px;
}

.contact-item {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    color: #495057;
}

.contact-item i {
    width: 20px;
    margin-right: 10px;
    color: #667eea;
}

.language-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    background: white;
    padding: 10px 15px;
    border-radius: 25px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    gap: 10px;
}

.toggle-switch {
    position: relative;
    width: 60px;
    height: 30px;
    background: #ccc;
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.toggle-switch.active {
    background: #667eea;
}

.toggle-slider {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 24px;
    height: 24px;
    background: white;
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.toggle-switch.active .toggle-slider {
    transform: translateX(30px);
}

.lang-label {
    font-weight: 600;
    font-size: 0.9em;
}

.lang-label.active {
    color: #667eea;
}

.print-button {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 18px;
    border-radius: 50%;
    box-shadow: 
        0 8px 25px rgba(102, 126, 234, 0.4),
        0 0 0 0 rgba(102, 126, 234, 0.5);
    cursor: pointer;
    font-size: 1.3em;
    z-index: 1000;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    animation: printFloat 3s ease-in-out infinite, printPulse 2s infinite;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.print-button:hover {
    background: linear-gradient(135deg, #5a67d8, #6b46c1);
    transform: scale(1.1) translateY(-3px);
    box-shadow: 
        0 15px 35px rgba(102, 126, 234, 0.6),
        0 0 0 10px rgba(102, 126, 234, 0.1);
}

.print-button:active {
    transform: scale(0.95);
}

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

@keyframes printPulse {
    0% { box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4), 0 0 0 0 rgba(102, 126, 234, 0.5); }
    70% { box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4), 0 0 0 15px rgba(102, 126, 234, 0); }
    100% { box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4), 0 0 0 0 rgba(102, 126, 234, 0); }
}

/* Hide elements based on language */
.lang-vi { display: block !important; }
.lang-en { display: none !important; }

body.english .lang-vi { display: none !important; }
body.english .lang-en { display: block !important; }

/* Print styles */
@media print {
    body {
        background: white !important;
        font-size: 12pt;
        line-height: 1.4;
    }
    
    .cv-container {
        box-shadow: none !important;
        border-radius: 0 !important;
        max-width: none !important;
        margin: 0 !important;
    }
    
    .header-section {
        background: #667eea !important;
        color: white !important;
        padding: 20px !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
    
    .language-toggle,
    .print-button {
        display: none !important;
    }
    
    .section-title {
        color: #667eea !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
    
    .experience-item,
    .education-item {
        page-break-inside: avoid;
        break-inside: avoid;
    }
    
    .experience-item::before,
    .education-item::before {
        background: #667eea !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
    
    .current-badge {
        background: #28a745 !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
    
    .contact-item i {
        color: #667eea !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
}

@media (max-width: 768px) {
    .cv-container {
        margin: 10px;
        border-radius: 0;
    }
    
    .header-section {
        padding: 30px 20px;
    }
    
    .language-toggle {
        top: 10px;
        right: 10px;
        padding: 8px 12px;
    }
    
    .print-button {
        bottom: 10px;
        right: 10px;
        padding: 12px;
    }
}
