:root {
    --primary: #0ff0fc;
    --secondary: #ff2a6d;
    --accent: #f5d300;
    --dark: #050a10;
    --darker: #01040a;
    --light: #d1f7ff;
    --cyber-dark: #0d1b2a;
    --cyber-light: #e0e1dd;
    --neon-pink: #ff2a6d;
    --neon-blue: #05d9e8;
    --neon-yellow: #f5d300;
    font-family: 'Kanit', sans-serif; }

@import url('https://fonts.googleapis.com/css2?family=Kanit:wght@400;500;600;700&family=Share+Tech&display=swap');




* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    font-family: 'Kanit', sans-serif;
    background-color: var(--dark);
    color: var(--light);
    overflow-x: hidden;
    line-height: 1.6;
    font-weight: 600;
}

.cyberpunk-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--darker), var(--dark));
    z-index: -3;
}

.grid-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(5, 10, 16, 0.7) 1px, transparent 1px),
        linear-gradient(90deg, rgba(5, 10, 16, 0.7) 1px, transparent 1px);
    background-size: 30px 30px;
    z-index: -2;
    opacity: 0.5;
}

.particles-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.cyber-header {
    text-align: center;
    padding: 3rem 1rem;
    position: relative;
    margin-bottom: 2rem;
}

.glitch-container {
    position: relative;
    margin-bottom: 1.5rem;
}

.glitch {
    position: relative;
    font-size: 4rem;
    font-family: 'Kanit', 'Be Vietnam Pro', sans-serif; /* Đổi từ Kanit */
    font-weight: 700;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 3px;
    text-shadow: 0 0 10px var(--primary), 0 0 20px var(--primary);
    margin-bottom: 0.5rem;
}

/* Xóa toàn bộ các @keyframes glitch-effect, glitch-anim, glitch-anim2 */

.glitch::before {
    content: attr(data-text);
    position: absolute;
    left: -2px;
    text-shadow: -2px 0 #ff00c1;
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim 5s infinite linear alternate-reverse;
}

.glitch::after {
    content: attr(data-text);
    position: absolute;
    left: 2px;
    text-shadow: -2px 0 #00fff9;
    clip: rect(44px, 450px, 56px, 0);
    animation: glitch-anim2 5s infinite linear alternate-reverse;
}

.cyber-subtitle {
    font-family: 'Kanit', sans-serif;
    color: var(--secondary);
    font-size: 1.5rem;
    letter-spacing: 2px;
    text-shadow: 0 0 10px var(--secondary);
    margin-top: -0.5rem;
}

.cyber-avatar {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 3rem auto; /* Tăng khoảng cách */
    width: 100%;
    position: relative;
}

.avatar-frame {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    border: 3px solid var(--primary);
    box-shadow: 0 0 20px var(--primary), inset 0 0 20px var(--primary);
    padding: 5px;
    animation: pulse 4s infinite;
    overflow: hidden;
    display: block; /* Thêm dòng này */
    margin: 0 auto; /* Canh giữa */
}

.avatar-frame img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.cyber-nav {
    display: flex;
    justify-content: center;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.cyber-nav ul {
    display: flex;
    list-style: none;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

.neon-btn {
    position: relative;
    display: inline-block;
    padding: 12px 24px;
    color: var(--light);
    text-decoration: none;
    text-transform: uppercase;
    font-family: 'Kanit', sans-serif;
    font-size: 1rem;
    letter-spacing: 2px;
    overflow: hidden;
    transition: 0.5s;
    border: none;
    background: transparent;
    cursor: pointer;
}

.neon-btn:hover {
    color: var(--dark);
    background: var(--primary);
    box-shadow: 0 0 10px var(--primary), 0 0 40px var(--primary), 0 0 80px var(--primary);
    transition-delay: 0.5s;
}

.neon-btn span {
    position: absolute;
    display: block;
}

.neon-btn span:nth-child(1) {
    top: 0;
    left: -100%;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--primary));
}

.neon-btn:hover span:nth-child(1) {
    left: 100%;
    transition: 0.5s;
}

.neon-btn span:nth-child(2) {
    top: -100%;
    right: 0;
    width: 2px;
    height: 100%;
    background: linear-gradient(180deg, transparent, var(--primary));
}

.neon-btn:hover span:nth-child(2) {
    top: 100%;
    transition: 0.5s;
    transition-delay: 0.125s;
}

.neon-btn span:nth-child(3) {
    bottom: 0;
    right: -100%;
    width: 100%;
    height: 2px;
    background: linear-gradient(270deg, transparent, var(--primary));
}

.neon-btn:hover span:nth-child(3) {
    right: 100%;
    transition: 0.5s;
    transition-delay: 0.25s;
}

.neon-btn span:nth-child(4) {
    bottom: -100%;
    left: 0;
    width: 2px;
    height: 100%;
    background: linear-gradient(360deg, transparent, var(--primary));
}

.neon-btn:hover span:nth-child(4) {
    bottom: 100%;
    transition: 0.5s;
    transition-delay: 0.375s;
}

.neon-btn.small {
    padding: 8px 16px;
    font-size: 0.8rem;
}

.cyber-main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.cyber-section {
    margin-bottom: 4rem;
    position: relative;
}

.section-header {
    margin-bottom: 2rem;
    text-align: center;
}

.section-header h2 {
    font-family: 'Kanit', sans-serif;
    color: var(--primary);
    font-size: 2rem;
    letter-spacing: 2px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.header-line {
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    width: 50%;
    margin: 0 auto;
}

.cyber-card {
    background: rgba(13, 27, 42, 0.7);
    border: 1px solid rgba(5, 217, 232, 0.3);
    border-radius: 10px;
    padding: 2rem;
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.cyber-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(5, 217, 232, 0.2);
}

/* Hiệu ứng avatar cực mượt - màu xanh neon */
.avatar-frame {
    transition: all 0.7s cubic-bezier(0.19, 1, 0.22, 1);
    position: relative;
    overflow: visible;
    z-index: 1;
}

.avatar-frame::before {
    content: '';
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    border-radius: 50%;
    background: radial-gradient(circle at center, 
                rgba(5, 217, 232, 0.8) 0%, 
                rgba(5, 217, 232, 0.1) 70%);
    opacity: 0;
    z-index: -1;
    filter: blur(15px);
    transition: all 0.7s cubic-bezier(0.19, 1, 0.22, 1);
}

.avatar-frame:hover {
    transform: scale(1.03);
}

.avatar-frame:hover::before {
    opacity: 1;
    top: -15px;
    left: -15px;
    right: -15px;
    bottom: -15px;
    animation: neon-pulse 2.5s infinite ease-in-out;
}

@keyframes neon-pulse {
    0%, 100% {
        box-shadow: 0 0 15px rgba(5, 217, 232, 0.7),
                    0 0 30px rgba(5, 217, 232, 0.5),
                    0 0 45px rgba(5, 217, 232, 0.3);
    }
    50% {
        box-shadow: 0 0 25px rgba(5, 217, 232, 0.9),
                    0 0 50px rgba(5, 217, 232, 0.7),
                    0 0 75px rgba(5, 217, 232, 0.5);
    }
}

/* Hiệu ứng ánh sáng tỏa đều từ tâm */
.avatar-frame::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 50%;
    background: radial-gradient(circle at center, 
                rgba(5, 217, 232, 0.4) 0%, 
                transparent 70%);
    opacity: 0;
    transition: opacity 0.7s ease;
    z-index: -1;
}

.avatar-frame:hover::after {
    opacity: 1;
    animation: light-expand 2s infinite alternate;
}

@keyframes light-expand {
    0% {
        transform: scale(1);
        opacity: 0.4;
    }
    100% {
        transform: scale(1.2);
        opacity: 0.8;
    }
}
.holographic-effect {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        135deg,
        rgba(5, 217, 232, 0.1) 0%,
        rgba(255, 42, 109, 0.1) 50%,
        rgba(245, 211, 0, 0.1) 100%
    );
    opacity: 0.5;
    z-index: 0;
}

.card-content {
    position: relative;
    z-index: 1;
}

.cyber-list {
    list-style: none;
    margin: 1.5rem 0;
}

.cyber-list li {
    margin-bottom: 1rem;
    padding-left: 2rem;
    position: relative;
    line-height: 1.6;
}

.cyber-list li i {
    position: absolute;
    left: 0;
    top: 0.2rem;
    color: var(--primary);
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 2rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    border-left: 2px solid var(--primary);
}

.contact-item i {
    color: var(--primary);
    font-size: 1.2rem;
}

.contact-item a {
    color: var(--light);
    text-decoration: none;
    transition: color 0.3s;
}

.contact-item a:hover {
    color: var(--primary);
    text-decoration: underline;
}

.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    width: 4px;
    height: 100%;
    background: linear-gradient(to bottom, var(--primary), var(--secondary));
    transform: translateX(-50%);
}

.timeline-item {
    position: relative;
    margin-bottom: 3rem;
    width: 100%;
}
.timeline-item:last-child {
    margin-bottom: 4rem; /* Tăng khoảng cách dưới cùng của timeline */
}

/* Đảm bảo section kinh nghiệm có khoảng cách đủ */
#experience {
    padding-top: 2rem;
}

.timeline-item:nth-child(odd) .timeline-content {
    margin-left: auto;
}

.timeline-date {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary);
    color: var(--dark);
    padding: 0.5rem 1.5rem;
    border-radius: 20px;
    font-weight: bold;
    font-family: 'Kanit', sans-serif;
    box-shadow: 0 0 10px var(--primary);
    z-index: 1;
}

.timeline-content {
    width: calc(50% - 2rem);
    padding: 2rem;
    position: relative;
}

.timeline-content h3 {
    color: var(--primary);
    font-family: 'Kanit', sans-serif;
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
}

.cyber-badge {
    display: inline-block;
    background: rgba(5, 217, 232, 0.2);
    color: var(--primary);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
    border: 1px solid var(--primary);
}

.cyber-badge.accent {
    background: rgba(255, 42, 109, 0.2);
    color: var(--secondary);
    border-color: var(--secondary);
}

.cyber-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.card-header {
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(5, 217, 232, 0.3);
}

.card-header h3 {
    color: var(--primary);
    font-family: 'Kanit', sans-serif;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.company {
    color: var(--secondary);
    font-weight: bold;
    margin: 0.3rem 0;
}

.duration {
    color: var(--light);
    opacity: 0.8;
    font-size: 0.9rem;
}

.skill-item {
    margin-bottom: 1.5rem;
}

.skill-item p {
    margin-bottom: 0.5rem;
    color: var(--light);
}

.cyber-bar {
    height: 10px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    overflow: hidden;
    position: relative;
}

.bar-level {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    border-radius: 5px;
    position: relative;
    transition: width 1.5s ease;
}

.bar-level span {
    display: none; /* Thêm dòng này để ẩn phần trăm */

    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--dark);
    font-size: 0.7rem;
    font-weight: bold;
}

.project-card {
    padding: 0;
}

.project-image {
    height: 200px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.project-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1.5rem;
    background: linear-gradient(to top, rgba(5, 10, 16, 0.9), transparent);
}

.project-overlay h3 {
    color: var(--primary);
    font-family: 'Kanit', sans-serif;
    font-size: 1.5rem;
    margin-bottom: 0.3rem;
}

.project-overlay p {
    color: var(--light);
    opacity: 0.9;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0;
}

.project-tech span {
    background: rgba(5, 217, 232, 0.2);
    color: var(--primary);
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    border: 1px solid var(--primary);
}

.cyber-footer {
    background: rgba(5, 10, 16, 0.8);
    padding: 2rem 1rem;
    text-align: center;
    margin-top: 4rem;
    border-top: 1px solid rgba(5, 217, 232, 0.3);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.social-icon {
    color: var(--light);
    font-size: 1.2rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border: 1px solid var(--primary);
}

.social-icon:hover {
    background: var(--primary);
    color: var(--dark);
    transform: translateY(-5px);
    box-shadow: 0 0 15px var(--primary);
}

/* Animations */
@keyframes glitch-effect {
    0%, 100% { transform: translate(0); }
    20% { transform: translate(-3px, 3px); }
    40% { transform: translate(-3px, -3px); }
    60% { transform: translate(3px, 3px); }
    80% { transform: translate(3px, -3px); }
}

@keyframes glitch-anim {
    0% { clip: rect(31px, 9999px, 94px, 0); }
    10% { clip: rect(112px, 9999px, 76px, 0); }
    20% { clip: rect(85px, 9999px, 77px, 0); }
    30% { clip: rect(27px, 9999px, 97px, 0); }
    40% { clip: rect(64px, 9999px, 98px, 0); }
    50% { clip: rect(61px, 9999px, 85px, 0); }
    60% { clip: rect(99px, 9999px, 114px, 0); }
    70% { clip: rect(34px, 9999px, 115px, 0); }
    80% { clip: rect(98px, 9999px, 129px, 0); }
    90% { clip: rect(43px, 9999px, 96px, 0); }
    100% { clip: rect(82px, 9999px, 64px, 0); }
}

@keyframes glitch-anim2 {
    0% { clip: rect(65px, 9999px, 119px, 0); }
    10% { clip: rect(79px, 9999px, 66px, 0); }
    20% { clip: rect(37px, 9999px, 52px, 0); }
    30% { clip: rect(38px, 9999px, 104px, 0); }
    40% { clip: rect(109px, 9999px, 110px, 0); }
    50% { clip: rect(114px, 9999px, 44px, 0); }
    60% { clip: rect(18px, 9999px, 69px, 0); }
    70% { clip: rect(73px, 9999px, 61px, 0); }
    80% { clip: rect(105px, 9999px, 13px, 0); }
    90% { clip: rect(47px, 9999px, 120px, 0); }
    100% { clip: rect(106px, 9999px, 74px, 0); }
}

@keyframes pulse {
    0% { box-shadow: 0 0 10px var(--primary), inset 0 0 10px var(--primary); }
    50% { box-shadow: 0 0 20px var(--primary), inset 0 0 20px var(--primary); }
    100% { box-shadow: 0 0 10px var(--primary), inset 0 0 10px var(--primary); }
}

/* Responsive */
@media (max-width: 768px) {
    .avatar-frame {
        width: 250px;
        height: 250px;
    }
    .glitch {
        font-size: 2.5rem;
    }
  
    .cyber-subtitle {
        font-size: 1.2rem;
    }
    
    .timeline::before {
        left: 31px;
    }
    
    .timeline-item {
        padding-left: 70px;
    }
    
    .timeline-item:nth-child(odd) .timeline-content {
        margin-left: 0;
    }
    
    .timeline-date {
        left: 0;
        transform: none;
    }
    
    .timeline-content {
        width: 100%;
    }
    
    .cyber-grid {
        grid-template-columns: 1fr;
    }
    
    .section-header h2 {
        font-size: 1.5rem;
    }
}

/* Thêm vào cuối file */
.project-card .card-content {
    padding: 1.5rem 1.5rem 1.5rem 2rem; /* Tăng lề trái */
}

.project-tech {
    margin-left: -0.5rem; /* Dịch các tag sang phải */
}

.neon-btn.small {
    margin-left: -0.5rem; /* Dịch nút sang phải */
}