/* ===== DESIGN SYSTEM - LIGHT PREMIUM THEME ===== */
:root {
    --bg-primary: #ffffff;
    --bg-secondary: #f7f8fc;
    --bg-tertiary: #eef0f7;
    --text-primary: #1a1a2e;
    --text-secondary: #4a4a6a;
    --text-muted: #8888a0;
    --accent-1: #6c63ff;
    --accent-2: #00b894;
    --accent-gradient: linear-gradient(135deg, #6c63ff 0%, #00b894 100%);
    --accent-gradient-hover: linear-gradient(135deg, #7c73ff 0%, #10c8a4 100%);
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(0, 0, 0, 0.06);
    --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    --card-bg: #ffffff;
    --card-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    --card-shadow-hover: 0 12px 40px rgba(108, 99, 255, 0.12);
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-smooth: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ===== RESET & BASE ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.7;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

::selection {
    background: rgba(108, 99, 255, 0.15);
    color: var(--text-primary);
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
    display: block;
}

/* ===== NAVIGATION ===== */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1rem 2.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    transition: var(--transition-smooth);
    background: transparent;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid var(--glass-border);
    padding: 0.7rem 2.5rem;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.04);
}

.logo {
    font-size: 1.4rem;
    font-weight: 700;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 0.5rem;
}

.nav-links li a {
    color: var(--text-secondary);
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    transition: var(--transition-fast);
    font-size: 0.9rem;
    font-weight: 500;
    position: relative;
}

.nav-links li a::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 20px;
    height: 2px;
    background: var(--accent-gradient);
    border-radius: 2px;
    transition: transform var(--transition-fast);
}

.nav-links li a:hover,
.nav-links li a.active {
    color: var(--text-primary);
}

.nav-links li a:hover::after,
.nav-links li a.active::after {
    transform: translateX(-50%) scaleX(1);
}

/* Burger Menu */
.burger {
    display: none;
    cursor: pointer;
    z-index: 1001;
    padding: 4px;
}

.burger div {
    width: 25px;
    height: 2px;
    background-color: var(--text-primary);
    margin: 6px 0;
    transition: var(--transition-smooth);
    border-radius: 2px;
}

/* ===== HERO / HOME SECTION ===== */
.home-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6rem 2rem 4rem;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #f5f7ff 0%, #e8ecf8 50%, #f0f4ff 100%);
}

.home-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle at 30% 40%, rgba(108, 99, 255, 0.06) 0%, transparent 50%),
                radial-gradient(circle at 70% 60%, rgba(0, 184, 148, 0.05) 0%, transparent 50%);
    animation: gradientShift 15s ease-in-out infinite;
    pointer-events: none;
}

@keyframes gradientShift {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    33% { transform: translate(2%, -2%) rotate(1deg); }
    66% { transform: translate(-1%, 1%) rotate(-1deg); }
}

#particles-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.profile-container {
    display: flex;
    align-items: center;
    gap: 4rem;
    max-width: 1100px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.profile-image {
    width: 280px;
    height: 280px;
    border-radius: 50%;
    overflow: hidden;
    position: relative;
    flex-shrink: 0;
}

.profile-image::before {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    background: var(--accent-gradient);
    z-index: -1;
    animation: rotateGlow 6s linear infinite;
}

@keyframes rotateGlow {
    to { transform: rotate(360deg); }
}

.profile-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid #fff;
}

.profile-text {
    text-align: left;
}

.profile-text h1 {
    font-size: 3rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.1;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.profile-subtitle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    min-height: 1.8em;
}

.profile-subtitle .typing-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 600;
}

.profile-subtitle .cursor {
    display: inline-block;
    width: 2px;
    height: 1.2em;
    background: var(--accent-1);
    animation: blink 1s step-end infinite;
    vertical-align: middle;
}

@keyframes blink {
    50% { opacity: 0; }
}

.social-links {
    display: flex;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid var(--glass-border);
    color: var(--text-secondary);
    font-size: 1.2rem;
    transition: var(--transition-bounce);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.social-links a:hover {
    color: #fff;
    background: var(--accent-gradient);
    border-color: transparent;
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(108, 99, 255, 0.25);
}

.hero-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 2rem;
    padding: 0.8rem 1.8rem;
    border-radius: 50px;
    background: var(--accent-gradient);
    color: #fff;
    font-weight: 600;
    font-size: 0.95rem;
    transition: var(--transition-bounce);
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(108, 99, 255, 0.25);
}

.hero-cta:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(108, 99, 255, 0.3);
}

.hero-cta i {
    transition: transform var(--transition-fast);
}

.hero-cta:hover i {
    transform: translateX(4px);
}

/* ===== SECTION COMMON ===== */
section {
    padding: 6rem 2rem;
    position: relative;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.section-header p {
    color: var(--text-muted);
    font-size: 1.05rem;
    max-width: 500px;
    margin: 0 auto;
}

.section-divider {
    width: 60px;
    height: 3px;
    background: var(--accent-gradient);
    border-radius: 3px;
    margin: 1rem auto 0;
}

/* Reveal animation */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

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

/* ===== ABOUT SECTION ===== */
.about-section {
    background: var(--bg-primary);
}

.about-content {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.about-text {
    padding: 2rem;
    background: var(--card-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--card-shadow);
}

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

.about-text p:last-child {
    margin-bottom: 0;
}

/* Timeline */
.education h3 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

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

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(to bottom, var(--accent-1), var(--accent-2));
    border-radius: 2px;
}

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

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -2rem;
    top: 6px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--accent-gradient);
    border: 2px solid var(--bg-primary);
    transform: translateX(calc(2rem - 5px));
    box-shadow: 0 0 10px rgba(108, 99, 255, 0.3);
}

.timeline-item h4 {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.2rem;
}

.timeline-item .timeline-year {
    font-size: 0.8rem;
    color: var(--accent-2);
    font-weight: 600;
}

/* ===== PROJECTS SECTION ===== */
.projects-section {
    background: var(--bg-secondary);
}

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

.project-card {
    background: var(--card-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: var(--transition-smooth);
    box-shadow: var(--card-shadow);
}

.project-card:hover {
    transform: translateY(-8px);
    border-color: rgba(108, 99, 255, 0.15);
    box-shadow: var(--card-shadow-hover);
}

.project-card .card-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.project-card .card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-smooth);
}

.project-card:hover .card-image img {
    transform: scale(1.08);
}

.card-body {
    padding: 1.5rem;
}

.card-body h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.card-body p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.7;
    margin-bottom: 1rem;
}

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

.project-tech span {
    background: rgba(108, 99, 255, 0.08);
    color: var(--accent-1);
    padding: 0.3rem 0.85rem;
    border-radius: 50px;
    font-size: 0.78rem;
    font-weight: 600;
    border: 1px solid rgba(108, 99, 255, 0.12);
    transition: var(--transition-fast);
}

.project-tech span:hover {
    background: var(--accent-1);
    color: #fff;
    border-color: var(--accent-1);
}

/* ===== SKILLS SECTION ===== */
.skills-section {
    background: var(--bg-primary);
}

.skills-container {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
}

.skill-category {
    background: var(--card-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--card-shadow);
    transition: var(--transition-smooth);
}

.skill-category:hover {
    box-shadow: var(--card-shadow-hover);
}

.skill-category h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.skill-category h3 i {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.skill-item {
    margin-bottom: 1.25rem;
}

.skill-item:last-child {
    margin-bottom: 0;
}

.skill-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.skill-info span {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.skill-info .skill-percent {
    font-size: 0.8rem;
    font-weight: 700;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: 10px;
    overflow: hidden;
}

.progress {
    height: 100%;
    background: var(--accent-gradient);
    border-radius: 10px;
    width: 0;
    transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.progress::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    background: var(--accent-2);
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0 0 8px rgba(0, 184, 148, 0.3);
}

/* ===== CONTACT SECTION ===== */
.contact-section {
    background: var(--bg-secondary);
}

.contact-container {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 3rem;
    align-items: start;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem 1.5rem;
    background: var(--card-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    box-shadow: var(--card-shadow);
    transition: var(--transition-smooth);
}

.contact-item:hover {
    border-color: rgba(108, 99, 255, 0.15);
    transform: translateX(6px);
    box-shadow: var(--card-shadow-hover);
}

.contact-item i {
    font-size: 1.3rem;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    flex-shrink: 0;
}

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

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-form input,
.contact-form textarea {
    padding: 1rem 1.2rem;
    background: var(--card-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    transition: var(--transition-fast);
    outline: none;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: var(--text-muted);
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: var(--accent-1);
    box-shadow: 0 0 0 3px rgba(108, 99, 255, 0.08);
}

.contact-form textarea {
    height: 150px;
    resize: vertical;
}

.contact-form button {
    padding: 1rem 2rem;
    background: var(--accent-gradient);
    color: #fff;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.95rem;
    transition: var(--transition-bounce);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    box-shadow: 0 4px 15px rgba(108, 99, 255, 0.2);
}

.contact-form button:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(108, 99, 255, 0.25);
}

/* ===== FOOTER ===== */
footer {
    text-align: center;
    padding: 3rem 2rem;
    background: var(--text-primary);
    border-top: 1px solid var(--glass-border);
}

.footer-content {
    max-width: 1100px;
    margin: 0 auto;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
    transition: var(--transition-fast);
}

.footer-links a:hover {
    color: #fff;
}

.footer-divider {
    width: 60px;
    height: 2px;
    background: rgba(255, 255, 255, 0.15);
    margin: 1.5rem auto;
    border-radius: 2px;
}

footer p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
}

footer p .heart {
    color: #ff4757;
    display: inline;
}

/* ===== SCROLL TO TOP ===== */
.scroll-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--accent-gradient);
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(20px);
    transition: var(--transition-smooth);
    z-index: 999;
    box-shadow: 0 4px 15px rgba(108, 99, 255, 0.25);
}

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

.scroll-top:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(108, 99, 255, 0.35);
}

/* ===== RESPONSIVE DESIGN ===== */
@media screen and (max-width: 992px) {
    .profile-text h1 {
        font-size: 2.2rem;
    }

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

    .contact-container {
        grid-template-columns: 1fr;
    }

    .section-header h2 {
        font-size: 2rem;
    }
}

@media screen and (max-width: 768px) {
    .nav-links {
        display: none;
        position: fixed;
        top: 0;
        right: 0;
        width: 100%;
        height: 100vh;
        background: rgba(255, 255, 255, 0.97);
        backdrop-filter: blur(20px);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 1rem;
    }

    .nav-links.nav-active {
        display: flex;
    }

    .nav-links li a {
        font-size: 1.3rem;
        padding: 0.8rem 2rem;
        color: var(--text-primary);
    }

    .nav-links li a::after {
        display: none;
    }

    .burger {
        display: block;
    }

    .profile-container {
        flex-direction: column;
        text-align: center;
        gap: 2rem;
    }

    .profile-text {
        text-align: center;
    }

    .profile-text h1 {
        font-size: 2rem;
    }

    .profile-subtitle {
        justify-content: center;
    }

    .social-links {
        justify-content: center;
    }

    .hero-cta {
        margin-left: auto;
        margin-right: auto;
    }

    .profile-image {
        width: 200px;
        height: 200px;
    }

    .section-header h2 {
        font-size: 1.8rem;
    }

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

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

@media screen and (max-width: 480px) {
    section {
        padding: 4rem 1.2rem;
    }

    .navbar {
        padding: 1rem 1.2rem;
    }

    .navbar.scrolled {
        padding: 0.7rem 1.2rem;
    }

    .profile-text h1 {
        font-size: 1.6rem;
    }

    .profile-subtitle {
        font-size: 1rem;
    }
}

/* ===== BURGER ANIMATION ===== */
.toggle .line1 {
    transform: rotate(-45deg) translate(-6px, 6px);
}

.toggle .line2 {
    opacity: 0;
}

.toggle .line3 {
    transform: rotate(45deg) translate(-6px, -6px);
}

/* ===== NAV LINK ANIMATION ===== */
@keyframes navLinkFade {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
