/* ===================================
   CSS Variables & Theme System
   =================================== */
:root {
    /* Colors - Dark Theme (Default) */
    --bg-primary: #0A0A0A;
    --bg-secondary: #141414;
    --bg-tertiary: #1F1F1F;
    --text-primary: #FFFFFF;
    --text-secondary: #A3A3A3;
    --text-muted: #737373;
    --accent-primary: #FFFFFF;
    --accent-secondary: #D4D4D4;
    --accent-gradient: linear-gradient(135deg, #FFFFFF 0%, #A3A3A3 100%);
    --border-color: rgba(255, 255, 255, 0.1);
    --card-bg: rgba(20, 20, 20, 0.9);
    --glass-bg: rgba(10, 10, 10, 0.9);
    --shadow-color: rgba(0, 0, 0, 0.5);

    /* Spacing */
    --section-padding: 100px;
    --container-width: 1200px;

    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;

    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-full: 9999px;
}

/* Light Theme */
[data-theme="light"] {
    --bg-primary: #FFFFFF;
    --bg-secondary: #F5F5F5;
    --bg-tertiary: #E5E5E5;
    --text-primary: #0A0A0A;
    --text-secondary: #525252;
    --text-muted: #737373;
    --accent-primary: #0A0A0A;
    --accent-secondary: #404040;
    --accent-gradient: linear-gradient(135deg, #0A0A0A 0%, #525252 100%);
    --border-color: rgba(0, 0, 0, 0.1);
    --card-bg: rgba(255, 255, 255, 0.95);
    --glass-bg: rgba(255, 255, 255, 0.9);
    --shadow-color: rgba(0, 0, 0, 0.08);
}

/* ===================================
   Reset & Base Styles
   =================================== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    font-family: var(--font-family);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
    transition: background-color var(--transition-normal), color var(--transition-normal);
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-fast);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
}

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

.section {
    padding: var(--section-padding) 0;
}

.section-title {
    font-size: clamp(2rem, 5vw, 2.5rem);
    font-weight: 700;
    text-align: center;
    margin-bottom: 60px;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: var(--accent-gradient);
    border-radius: var(--radius-full);
}

/* ===================================
   Buttons
   =================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--radius-full);
    cursor: pointer;
    border: none;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: rotate(45deg);
    transition: transform 0.6s;
    opacity: 0;
}

.btn:hover::after {
    transform: rotate(45deg) translate(50%, 50%);
    opacity: 1;
}

.btn-primary {
    background: var(--accent-gradient);
    color: var(--bg-primary);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
}

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

.btn-secondary:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
    transform: translateY(-3px);
}

/* ===================================
   Navigation
   =================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 0;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    transition: all var(--transition-normal);
}

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

.nav-logo {
    display: flex;
    align-items: center;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-link {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-secondary);
    position: relative;
    padding: 8px 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-gradient);
    transition: width var(--transition-normal);
}

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

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

.nav-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: var(--radius-full);
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    cursor: pointer;
    color: var(--text-primary);
    transition: all var(--transition-normal);
}

.theme-toggle:hover {
    background: var(--bg-tertiary);
    transform: rotate(15deg);
}

[data-theme="dark"] .sun-icon {
    display: block;
}

[data-theme="dark"] .moon-icon {
    display: none;
}

[data-theme="light"] .sun-icon {
    display: none;
}

[data-theme="light"] .moon-icon {
    display: block;
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    background: transparent;
    border: none;
    cursor: pointer;
}

.hamburger {
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    position: relative;
    transition: all var(--transition-normal);
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: all var(--transition-normal);
}

.hamburger::before {
    top: -8px;
}

.hamburger::after {
    bottom: -8px;
}

.mobile-menu-btn.active .hamburger {
    background: transparent;
}

.mobile-menu-btn.active .hamburger::before {
    top: 0;
    transform: rotate(45deg);
}

.mobile-menu-btn.active .hamburger::after {
    bottom: 0;
    transform: rotate(-45deg);
}

/* ===================================
   Hero Section
   =================================== */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 120px 0 60px;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 70%);
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.03) 0%, transparent 70%);
    pointer-events: none;
}

.hero-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-greeting {
    font-size: 1.125rem;
    color: var(--accent-primary);
    font-weight: 500;
    margin-bottom: 12px;
}

.hero-title {
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 16px;
    background: linear-gradient(135deg, var(--text-primary) 0%, var(--text-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-subtitle {
    font-size: clamp(1.25rem, 3vw, 1.75rem);
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.typing-text {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 500px;
    margin-bottom: 32px;
    line-height: 1.8;
}

.highlight {
    color: var(--accent-primary);
    font-weight: 600;
}

.hero-cta {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

/* Code Block Visual */
.hero-visual {
    display: flex;
    justify-content: center;
}

.code-block {
    background: var(--bg-secondary);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: 0 25px 50px -12px var(--shadow-color);
    width: 100%;
    max-width: 450px;
    animation: float 6s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-15px);
    }
}

.code-header {
    display: flex;
    gap: 8px;
    padding: 16px 20px;
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-color);
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red {
    background: #EF4444;
}

.dot.yellow {
    background: #F59E0B;
}

.dot.green {
    background: #22C55E;
}

.code-content {
    padding: 24px;
    font-family: 'Fira Code', 'Monaco', monospace;
    font-size: 0.9rem;
    line-height: 1.8;
    overflow-x: auto;
}

.code-content code {
    color: var(--text-secondary);
}

.code-keyword {
    color: #A3A3A3;
}

.code-property {
    color: #D4D4D4;
}

.code-string {
    color: #FFFFFF;
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: var(--text-muted);
    font-size: 0.875rem;
    animation: bounce 2s infinite;
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateX(-50%) translateY(0);
    }

    40% {
        transform: translateX(-50%) translateY(-10px);
    }

    60% {
        transform: translateX(-50%) translateY(-5px);
    }
}

.mouse {
    width: 26px;
    height: 40px;
    border: 2px solid var(--text-muted);
    border-radius: 20px;
    position: relative;
}

.wheel {
    width: 4px;
    height: 8px;
    background: var(--text-muted);
    border-radius: var(--radius-full);
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll 2s infinite;
}

@keyframes scroll {
    0% {
        opacity: 1;
        top: 8px;
    }

    100% {
        opacity: 0;
        top: 24px;
    }
}

/* ===================================
   About Section
   =================================== */
.about {
    background: var(--bg-secondary);
}

.about-content {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-intro {
    font-size: 1.25rem;
    color: var(--text-primary);
    margin-bottom: 20px;
    line-height: 1.8;
}

.about-text p {
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.8;
}

.about-text strong {
    color: var(--accent-primary);
}

.about-stats {
    display: flex;
    gap: 40px;
    margin-top: 40px;
    padding-top: 40px;
    border-top: 1px solid var(--border-color);
}

.stat {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin-top: 4px;
}

.about-image {
    display: flex;
    justify-content: center;
}

.image-frame {
    position: relative;
    width: 280px;
    height: 280px;
}

.image-frame::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 20px;
    right: -20px;
    bottom: -20px;
    background: var(--accent-gradient);
    border-radius: var(--radius-lg);
    z-index: 0;
}

.profile-placeholder {
    position: relative;
    width: 100%;
    height: 100%;
    background: var(--bg-tertiary);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
    border: 4px solid var(--bg-primary);
}

.profile-placeholder span {
    font-size: 4rem;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ===================================
   Skills Section
   =================================== */
.skills-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}

.skills-category {
    background: var(--card-bg);
    padding: 32px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.skills-category:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px var(--shadow-color);
}

.category-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 24px;
}

.category-title svg {
    color: var(--accent-primary);
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 16px;
}

.skill-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 16px 12px;
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
    transition: all var(--transition-normal);
}

.skill-card:hover {
    background: var(--bg-tertiary);
    transform: translateY(-3px);
    border-color: var(--accent-primary);
}

.skill-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
}

/* Technology Icons with Colors */
.skill-icon.nodejs {
    background: linear-gradient(135deg, #339933 0%, #43853d 100%);
    color: white;
}

.skill-icon.nodejs::after {
    content: 'N';
}

.skill-icon.express {
    background: linear-gradient(135deg, #333 0%, #000 100%);
    color: white;
}

.skill-icon.express::after {
    content: 'Ex';
    font-size: 1rem;
}

.skill-icon.nestjs {
    background: linear-gradient(135deg, #E0234E 0%, #a4133c 100%);
    color: white;
}

.skill-icon.nestjs::after {
    content: 'Ns';
    font-size: 1rem;
}

.skill-icon.typescript {
    background: linear-gradient(135deg, #3178C6 0%, #235a9e 100%);
    color: white;
}

.skill-icon.typescript::after {
    content: 'TS';
    font-size: 1rem;
}

.skill-icon.socketio {
    background: linear-gradient(135deg, #010101 0%, #333 100%);
    color: white;
}

.skill-icon.socketio::after {
    content: 'S';
}

.skill-icon.redis {
    background: linear-gradient(135deg, #DC382D 0%, #A41F16 100%);
    color: white;
}

.skill-icon.redis::after {
    content: 'Re';
    font-size: 1rem;
}

.skill-icon.docker {
    background: linear-gradient(135deg, #0db7ed 0%, #0066cc 100%);
    color: white;
}

.skill-icon.docker::after {
    content: 'Dk';
    font-size: 1rem;
}

/* ===================================
   Experience Section
   =================================== */


.skill-icon.mongodb {
    background: linear-gradient(135deg, #47A248 0%, #3a8a3c 100%);
    color: white;
}

.skill-icon.mongodb::after {
    content: 'M';
}

.skill-icon.postgresql {
    background: linear-gradient(135deg, #336791 0%, #264d73 100%);
    color: white;
}

.skill-icon.postgresql::after {
    content: 'Pg';
    font-size: 1rem;
}

.skill-icon.mysql {
    background: linear-gradient(135deg, #4479A1 0%, #336384 100%);
    color: white;
}

.skill-icon.mysql::after {
    content: 'My';
    font-size: 1rem;
}

.skill-icon.lambda {
    background: linear-gradient(135deg, #FF9900 0%, #ec8c00 100%);
    color: white;
}

.skill-icon.lambda::after {
    content: 'λ';
}

.skill-icon.apigateway {
    background: linear-gradient(135deg, #FF4F8B 0%, #e64578 100%);
    color: white;
}

.skill-icon.apigateway::after {
    content: 'AG';
    font-size: 1rem;
}

.skill-icon.sqs {
    background: linear-gradient(135deg, #FF4F8B 0%, #e64578 100%);
    color: white;
}

.skill-icon.sqs::after {
    content: 'SQ';
    font-size: 1rem;
}

.skill-icon.sns {
    background: linear-gradient(135deg, #D9327E 0%, #b3296a 100%);
    color: white;
}

.skill-icon.sns::after {
    content: 'SN';
    font-size: 1rem;
}

.skill-icon.react {
    background: linear-gradient(135deg, #61DAFB 0%, #4fc3e4 100%);
    color: #282c34;
}

.skill-icon.react::after {
    content: 'Re';
    font-size: 1rem;
}

.skill-icon.git {
    background: linear-gradient(135deg, #F05032 0%, #d9462b 100%);
    color: white;
}

.skill-icon.git::after {
    content: 'G';
}

.skill-icon.bitbucket {
    background: linear-gradient(135deg, #0052CC 0%, #0747a6 100%);
    color: white;
}

.skill-icon.bitbucket::after {
    content: 'Bb';
    font-size: 1rem;
}

.skill-icon.jira {
    background: linear-gradient(135deg, #0052CC 0%, #0747a6 100%);
    color: white;
}

.skill-icon.jira::after {
    content: 'Ji';
    font-size: 1rem;
}

.skill-name {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-align: center;
}

/* ===================================
   Experience Section
   =================================== */
.experience {
    background: var(--bg-secondary);
}

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

.timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--accent-gradient);
    border-radius: var(--radius-full);
}

.timeline-item {
    position: relative;
    padding-left: 40px;
    padding-bottom: 50px;
}

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

.timeline-marker {
    position: absolute;
    left: -6px;
    top: 0;
    width: 15px;
    height: 15px;
    background: var(--accent-primary);
    border-radius: 50%;
    border: 3px solid var(--bg-secondary);
    box-shadow: 0 0 0 3px var(--accent-primary);
}

.timeline-content {
    background: var(--card-bg);
    padding: 28px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
    transition: transform var(--transition-normal), box-shadow var(--transition-normal);
}

.timeline-content:hover {
    transform: translateX(10px);
    box-shadow: 0 15px 35px var(--shadow-color);
}

.timeline-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 12px;
}

.job-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
}

.job-period {
    font-size: 0.875rem;
    color: var(--accent-primary);
    font-weight: 600;
    background: rgba(59, 130, 246, 0.1);
    padding: 6px 14px;
    border-radius: var(--radius-full);
}

.job-company {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 1rem;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.job-company svg {
    color: var(--accent-secondary);
}

.job-description {
    margin-bottom: 20px;
    padding-left: 20px;
}

.job-description li {
    position: relative;
    color: var(--text-secondary);
    margin-bottom: 10px;
    line-height: 1.7;
}

.job-description li::before {
    content: '▹';
    position: absolute;
    left: -20px;
    color: var(--accent-primary);
}

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

.tag {
    font-size: 0.75rem;
    font-weight: 500;
    padding: 6px 12px;
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    border-radius: var(--radius-full);
    border: 1px solid var(--border-color);
}

/* ===================================
   Projects Section
   =================================== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.project-card {
    background: var(--card-bg);
    padding: 32px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--accent-gradient);
    transform: scaleX(0);
    transition: transform var(--transition-normal);
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 50px var(--shadow-color);
}

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

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

.project-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    background: var(--accent-gradient);
    border-radius: var(--radius-md);
    color: white;
    flex-shrink: 0;
}

.project-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-top: 8px;
}

.project-description {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 20px;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.project-tech span {
    font-size: 0.75rem;
    font-weight: 500;
    padding: 6px 12px;
    background: rgba(59, 130, 246, 0.1);
    color: var(--accent-primary);
    border-radius: var(--radius-full);
    border: 1px solid rgba(59, 130, 246, 0.2);
}

/* ===================================
   Education Section
   =================================== */
.education {
    background: var(--bg-secondary);
}

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

.education-card {
    display: flex;
    gap: 20px;
    padding: 32px;
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
    transition: all var(--transition-normal);
}

.education-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px var(--shadow-color);
}

.education-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    background: var(--accent-gradient);
    border-radius: var(--radius-md);
    color: white;
    flex-shrink: 0;
}

.education-content {
    flex: 1;
}

.degree {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.institution {
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.period {
    font-size: 0.875rem;
    color: var(--accent-primary);
    font-weight: 600;
}

/* ===================================
   Contact Section
   =================================== */
.contact-content {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
}

.contact-intro {
    font-size: 1.125rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.8;
}

.contact-methods {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 40px;
}

.contact-method {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px;
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    text-align: left;
    transition: all var(--transition-normal);
}

.contact-method:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px var(--shadow-color);
    border-color: var(--accent-primary);
}

.contact-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    background: rgba(59, 130, 246, 0.1);
    border-radius: var(--radius-md);
    color: var(--accent-primary);
    flex-shrink: 0;
}

.contact-details {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.contact-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
}

.contact-value {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.95rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.download-resume {
    margin-top: 20px;
}

/* ===================================
   Footer
   =================================== */
.footer {
    padding: 40px 0;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
}

.footer-content {
    text-align: center;
}

.footer-text {
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.footer-text strong {
    color: var(--text-primary);
}

.footer-copyright {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* ===================================
   Scroll Reveal Animation
   =================================== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

/* ===================================
   Responsive Design
   =================================== */
@media (max-width: 1024px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

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

    .hero-cta {
        justify-content: center;
    }

    .hero-visual {
        order: -1;
    }

    .code-block {
        max-width: 400px;
    }

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

    .about-image {
        order: -1;
    }

    .about-stats {
        justify-content: center;
    }

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

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

@media (max-width: 768px) {
    :root {
        --section-padding: 70px;
    }

    .nav-menu {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: var(--bg-primary);
        flex-direction: column;
        padding: 30px;
        gap: 0;
        transform: translateY(-150%);
        opacity: 0;
        transition: all var(--transition-normal);
        border-bottom: 1px solid var(--border-color);
    }

    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
    }

    .nav-item {
        width: 100%;
    }

    .nav-link {
        display: block;
        padding: 16px 0;
        border-bottom: 1px solid var(--border-color);
    }

    .mobile-menu-btn {
        display: flex;
    }

    .hero-title {
        font-size: 2.25rem;
    }

    .code-block {
        max-width: 100%;
    }

    .code-content {
        font-size: 0.75rem;
        padding: 16px;
    }

    .scroll-indicator {
        display: none;
    }

    .about-stats {
        flex-direction: column;
        align-items: center;
        gap: 30px;
    }

    .stat {
        text-align: center;
    }

    .timeline::before {
        left: 0;
    }

    .timeline-item {
        padding-left: 30px;
    }

    .timeline-marker {
        left: -6px;
    }

    .timeline-header {
        flex-direction: column;
    }

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

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

    .image-frame::before {
        top: 15px;
        left: 15px;
        right: -15px;
        bottom: -15px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .section-title {
        font-size: 1.75rem;
    }

    .hero-title {
        font-size: 1.875rem;
    }

    .hero-subtitle {
        font-size: 1.125rem;
    }

    .btn {
        padding: 12px 24px;
        font-size: 0.9rem;
    }

    .skills-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 10px;
    }

    .skill-card {
        padding: 12px 8px;
    }

    .skill-icon {
        width: 36px;
        height: 36px;
        font-size: 1.25rem;
    }

    .project-card,
    .timeline-content,
    .education-card {
        padding: 20px;
    }

    .education-card {
        flex-direction: column;
        text-align: center;
    }

    .education-icon {
        margin: 0 auto;
    }
}

/* ===================================
   Chatbot Widget
   =================================== */
.chat-widget {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.chat-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--text-primary);
    color: var(--bg-primary);
    border: none;
    box-shadow: 0 4px 20px var(--shadow-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform var(--transition-normal);
}

.chat-toggle:hover {
    transform: scale(1.1);
}

.chat-toggle svg {
    width: 28px;
    height: 28px;
    transition: all var(--transition-fast);
}

.chat-toggle .close-icon {
    display: none;
}

.chat-toggle.active .chat-icon {
    display: none;
}

.chat-toggle.active .close-icon {
    display: block;
}

.chat-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 500px;
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 40px var(--shadow-color);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    opacity: 0;
    transform: translateY(20px) scale(0.95);
    pointer-events: none;
    transition: all var(--transition-normal);
    transform-origin: bottom right;
}

.chat-window.active {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: all;
}

.chat-header {
    padding: 16px 20px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-title {
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-dot {
    width: 8px;
    height: 8px;
    background: #22C55E;
    border-radius: 50%;
    box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.2);
}

.chat-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.chat-close {
    background: transparent;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.chat-close:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.message {
    max-width: 80%;
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 0.9rem;
    line-height: 1.5;
    animation: fadeIn 0.3s ease;
}

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

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.bot-message {
    align-self: flex-start;
    background: var(--bg-secondary);
    color: var(--text-primary);
    border-bottom-left-radius: 4px;
    border: 1px solid var(--border-color);
}

.user-message {
    align-self: flex-end;
    background: var(--text-primary);
    color: var(--bg-primary);
    border-bottom-right-radius: 4px;
}

.chat-input-area {
    padding: 16px;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 10px;
}

#chat-input {
    flex: 1;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 10px 16px;
    font-family: inherit;
    font-size: 0.9rem;
    color: var(--text-primary);
    outline: none;
    transition: border-color var(--transition-fast);
}

#chat-input:focus {
    border-color: var(--text-muted);
}

.chat-send {
    background: transparent;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    padding: 8px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.chat-send:hover {
    background: var(--bg-tertiary);
}

.typing-indicator {
    display: inline-flex;
    gap: 4px;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    border-bottom-left-radius: 4px;
    width: fit-content;
}

.typing-dot {
    width: 6px;
    height: 6px;
    background: var(--text-muted);
    border-radius: 50%;
    animation: typing 1.4s infinite ease-in-out both;
}

.typing-dot:nth-child(1) {
    animation-delay: -0.32s;
}

.typing-dot:nth-child(2) {
    animation-delay: -0.16s;
}

@keyframes typing {

    0%,
    80%,
    100% {
        transform: scale(0);
    }

    40% {
        transform: scale(1);
    }
}

@media (max-width: 480px) {
    .chat-window {
        width: calc(100vw - 40px);
        bottom: 80px;
        right: 20px;
    }

    .chat-widget {
        right: 20px;
        bottom: 20px;
    }
}

/* Chat Enhancements */
.chat-subtitle {
    font-size: 0.7rem;
    color: var(--text-muted);
    margin: 2px 0 0 0;
    font-weight: 400;
}

.suggested-questions {
    margin-top: 8px;
}

.suggestions-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.suggestions-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.suggestion-chip {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    padding: 6px 12px;
    font-size: 0.75rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
    font-family: inherit;
}

.suggestion-chip:hover {
    background: var(--text-primary);
    color: var(--bg-primary);
    border-color: var(--text-primary);
}

.suggestion-chip:active {
    transform: scale(0.95);
}

/* Hide suggestions after messages are sent */
.suggested-questions.hidden {
    display: none;
}

/* Improved bot message formatting */
.bot-message {
    white-space: pre-wrap;
    word-wrap: break-word;
}

.bot-message ul,
.bot-message ol {
    margin: 8px 0;
    padding-left: 20px;
}

.bot-message li {
    margin: 4px 0;
}

.bot-message strong {
    color: var(--accent-primary);
}

/* Error message styling */
.error-message {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #EF4444;
}

/* ===================================
   Flashy UI Updates & Chat Widget
   =================================== */

/* Chat Widget Positioning & Pulse */
.chat-widget {
    position: fixed;
    bottom: 40px;
    right: 40px;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.chat-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--accent-gradient);
    border: none;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--bg-primary);
    transition: all var(--transition-normal);
    position: relative;
    z-index: 20;
    /* Pulse Animation */
    animation: pulse-glow 2s infinite;
}

@keyframes pulse-glow {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.4);
    }

    70% {
        box-shadow: 0 0 0 15px rgba(255, 255, 255, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(255, 255, 255, 0);
    }
}

.chat-toggle:hover {
    transform: scale(1.1);
}

/* Glassmorphism Chat Window */
.chat-window {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 380px;
    height: 600px;
    max-height: 80vh;
    background: rgba(20, 20, 20, 0.85);
    /* Darker glass base */
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    opacity: 0;
    transform: translateY(20px) scale(0.95);
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    transform-origin: bottom right;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Gradient Border Animation */
.chat-window::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 2px;
    background: linear-gradient(45deg, #ff00cc, #3333ff, #00ccff, #ff00cc);
    background-size: 400% 400%;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    animation: border-gradient 4s ease infinite;
    pointer-events: none;
    opacity: 0.6;
}

@keyframes border-gradient {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.chat-window.active {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: all;
}

/* Hero CTA Bubble */
.hero-chat-bubble {
    position: absolute;
    bottom: 80px;
    /* Positioned above chat button */
    right: 0;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 12px 20px;
    border-radius: 20px;
    border-bottom-right-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-primary);
    font-size: 0.9rem;
    font-weight: 500;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    animation: bubble-pop 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
    opacity: 0;
    transform: translateY(10px) scale(0.8);
    display: none;
    /* JS will toggle */
    cursor: pointer;
    z-index: 15;
    white-space: nowrap;
    margin-bottom: 10px;
}

.hero-chat-bubble::after {
    content: '';
    position: absolute;
    bottom: -6px;
    right: 24px;
    width: 12px;
    height: 12px;
    background: inherit;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    border-right: 1px solid rgba(255, 255, 255, 0.2);
    transform: rotate(45deg);
}

.hero-chat-bubble:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px) scale(1);
}

@keyframes bubble-pop {
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}