@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    /* Colors */
    --bg-dark: #050505;
    --bg-surface: #111111;
    --bg-glass: rgba(17, 17, 17, 0.6);
    
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    
    --accent-blue: #00f0ff;
    --accent-purple: #8a2be2;
    --accent-gradient: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    
    /* Spacing & Layout */
    --max-width: 1200px;
    --section-padding: 100px 20px;
    
    /* Effects */
    --glass-border: 1px solid rgba(255, 255, 255, 0.08);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    --neon-glow: 0 0 15px rgba(0, 240, 255, 0.5), 0 0 30px rgba(138, 43, 226, 0.5);
    
    /* Typography */
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;
    
    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-smooth: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

body.light-mode {
    --bg-dark: #f0f4f8;
    --bg-surface: #ffffff;
    --bg-glass: rgba(255, 255, 255, 0.85);
    
    --text-primary: #1a1a2e;
    --text-secondary: #4a4a6a;
    
    --accent-blue: #0066ff;
    --accent-purple: #8a2be2;
    --accent-gradient: linear-gradient(135deg, var(--accent-blue), var(--accent-purple));
    
    --glass-border: 1px solid rgba(0, 0, 0, 0.08);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.1);
    --neon-glow: 0 0 15px rgba(0, 102, 255, 0.3), 0 0 30px rgba(138, 43, 226, 0.3);
}

/* === CSS Reset & Base === */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    background-color: var(--bg-dark);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

/* === Dynamic Background === */
.background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: 
        radial-gradient(circle at 15% 50%, rgba(0, 240, 255, 0.08), transparent 50%),
        radial-gradient(circle at 85% 30%, rgba(138, 43, 226, 0.08), transparent 50%);
}

#bg-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1; /* relative to .background */
    pointer-events: none;
}

body.light-mode .background {
    background: 
        radial-gradient(circle at 15% 50%, rgba(0, 102, 255, 0.05), transparent 50%),
        radial-gradient(circle at 85% 30%, rgba(138, 43, 226, 0.05), transparent 50%);
}

.background::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image: 
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 50px 50px;
    opacity: 0.5;
    z-index: -1;
    mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,0) 100%);
    -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,0) 100%);
}

body.light-mode .background::before {
    background-image: 
        linear-gradient(rgba(0,0,0,0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,0,0,0.04) 1px, transparent 1px);
}

/* Typography Base */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
}

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

/* Typography utilities */
.highlight {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    display: inline-block;
}

.section-title {
    font-size: clamp(2rem, 5vw, 3rem);
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
    display: inline-block;
    width: 100%;
}

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

/* === Navigation === */
header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 20px 0;
    transition: var(--transition-smooth);
}

header.scrolled {
    background: var(--bg-glass);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: var(--glass-border);
    padding: 15px 0;
    box-shadow: var(--glass-shadow);
}

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

.logo {
    font-size: 1.5rem;
    font-family: var(--font-heading);
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    background: var(--text-primary);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    transition: var(--transition-fast);
}

.logo:hover {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    text-shadow: 0 0 20px rgba(0, 240, 255, 0.4);
}

.nav-links {
    display: flex;
    gap: 30px;
    list-style: none;
}

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

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

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

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

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a,
.social-icons button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
    border: var(--glass-border);
    color: var(--text-secondary);
    font-size: 1.1rem;
    transition: var(--transition-smooth);
    cursor: pointer;
}

.social-icons a:hover,
.social-icons button:hover {
    background: rgba(255,255,255,0.1);
    color: var(--text-primary);
    transform: translateY(-3px);
    box-shadow: var(--neon-glow);
    border-color: rgba(255,255,255,0.2);
}

/* Hover specific colors based on social type */
.social-icons a.linkedin:hover { color: #0A66C2; border-color: #0A66C2; box-shadow: 0 0 15px rgba(10, 102, 194, 0.5); }
.social-icons a.github:hover { color: #ffffff; border-color: #ffffff; box-shadow: 0 0 15px rgba(255, 255, 255, 0.5); }
.social-icons a.leetcode:hover { color: #FFA116; border-color: #FFA116; box-shadow: 0 0 15px rgba(255, 161, 22, 0.5); }
.social-icons button.theme-toggle:hover { color: var(--accent-blue); border-color: var(--accent-blue); box-shadow: 0 0 15px rgba(0, 240, 255, 0.5); }

/* Custom Cursor Elements */
.cursor-dot {
    width: 24px;
    height: 24px;
    background-color: transparent;
    border-radius: 50%;
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-purple);
    font-size: 20px;
    filter: drop-shadow(0 0 5px var(--accent-purple));
    transition: width 0.2s, height 0.2s, color 0.2s, font-size 0.2s;
}

.cursor-outline {
    width: 40px;
    height: 40px;
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 9998;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-purple);
    font-size: 1.5rem;
    transition: top 0.15s ease-out, left 0.15s ease-out, transform 0.2s;
    filter: drop-shadow(0 0 8px rgba(138, 43, 226, 0.6));
}

@media (pointer: fine) {
    body {
        cursor: none;
    }
    body a, body button, body .btn {
        cursor: none;
    }
}

/* === Sections General === */
section {
    padding: var(--section-padding);
    max-width: var(--max-width);
    margin: 0 auto;
}

/* === Home / Hero === */
.home {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    padding-top: 120px;
    position: relative;
}

.home-left {
    flex: 1;
    max-width: 600px;
}

.hello {
    font-size: 1.2rem;
    color: var(--accent-blue);
    font-family: var(--font-heading);
    font-weight: 600;
    margin-bottom: 10px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.home-left h1 {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    margin-bottom: 15px;
    line-height: 1.1;
}

.home-left h3 {
    font-size: clamp(1.2rem, 3vw, 2rem);
    color: var(--text-secondary);
    margin-bottom: 30px;
    height: 40px;
}

.typing-text::after {
    content: '|';
    animation: blink 1s infinite;
    color: var(--accent-purple);
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* Buttons */
.home-buttons {
    display: flex;
    gap: 20px;
}

.btn {
    padding: 14px 32px;
    border-radius: 30px;
    font-weight: 600;
    font-family: var(--font-body);
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition-smooth);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-primary {
    background: var(--accent-gradient);
    color: #000;
    border: none;
    box-shadow: 0 4px 15px rgba(0, 240, 255, 0.3);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(135deg, var(--accent-purple), var(--accent-blue));
    opacity: 0;
    z-index: -1;
    transition: opacity var(--transition-smooth);
}

.btn-primary:hover::before {
    opacity: 1;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: var(--neon-glow);
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid rgba(255,255,255,0.3);
}

.btn-secondary:hover {
    border-color: var(--accent-blue);
    background: rgba(0, 240, 255, 0.05);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 240, 255, 0.1);
}

/* Profile Image */
.home-right {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.img-container {
    position: relative;
    width: 350px;
    height: 350px;
    border-radius: 50%;
    padding: 6px; 
    background: var(--accent-gradient);
    animation: float 6s ease-in-out infinite;
    box-shadow: var(--neon-glow);
}

.profile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    background-color: var(--bg-surface);
    border: 6px solid var(--bg-dark);
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
    100% { transform: translateY(0px); }
}

/* === About Section === */
.about-container {
    background: var(--bg-glass);
    border: var(--glass-border);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 50px 40px;
    box-shadow: var(--glass-shadow);
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.about-text {
    font-size: 1.1rem;
    color: var(--text-secondary);
    line-height: 1.8;
}

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

/* === Skills Section === */
.skills-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
    max-width: 1100px;
    margin: 0 auto;
}

.skill-card {
    flex: 1 1 300px;
    max-width: 340px;
    background: var(--bg-glass);
    border: var(--glass-border);
    border-radius: 20px;
    padding: 30px;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.skill-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 2px;
    background: var(--accent-gradient);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--transition-smooth);
}

.skill-card:hover {
    transform: translateY(-8px);
    border-color: rgba(255,255,255,0.2);
    box-shadow: 0 15px 30px rgba(0,0,0,0.4);
}

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

.skill-icon {
    font-size: 2.2rem;
    margin-bottom: 20px;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    display: inline-block;
}

.skill-card h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: var(--text-primary);
}

/* Skill Tags */
.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.skill-tag {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--text-secondary);
    transition: var(--transition-fast);
}

.skill-card:hover .skill-tag {
    background: rgba(0, 240, 255, 0.05);
    border-color: rgba(0, 240, 255, 0.3);
    color: var(--accent-blue);
}

/* === Timeline/Experience Section === */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 0;
    left: 20px;
    height: 100%;
    width: 2px;
    background: rgba(255,255,255,0.1);
}

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

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

.timeline-dot {
    position: absolute;
    left: 11px;
    top: 5px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--bg-dark);
    border: 2px solid var(--accent-blue);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.5);
    z-index: 2;
}

.timeline-content {
    background: var(--bg-glass);
    border: var(--glass-border);
    border-radius: 15px;
    padding: 25px 30px;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: var(--transition-smooth);
}

.timeline-content:hover {
    transform: translateX(8px);
    border-color: rgba(0, 240, 255, 0.3);
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}

.timeline-date {
    display: inline-block;
    padding: 4px 12px;
    background: rgba(138, 43, 226, 0.15);
    color: #ebb0ff;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 12px;
}

.timeline-title {
    font-size: 1.3rem;
    color: var(--text-primary);
    margin-bottom: 5px;
}

.timeline-subtitle {
    font-size: 1rem;
    color: var(--accent-blue);
    margin-bottom: 15px;
    font-weight: 500;
}

.timeline-desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* === Achievements Section === */
.achievements-section {
    padding: var(--section-padding);
    background: var(--bg-dark); /* Blend naturally with background */
}

.achievements-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    max-width: var(--max-width);
    margin: 0 auto;
}

/* Interactive Horizontal Certificates Carousel */
.certificates-carousel {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 20px;
    padding-top: 20px;
    scrollbar-width: none;
    cursor: grab;
}
.certificates-carousel::-webkit-scrollbar {
    display: none;
}
.certificates-carousel:active {
    cursor: grabbing;
}
.certificates-carousel > .carousel-item {
    scroll-snap-align: center;
    flex: 0 0 350px;
    display: block;
    perspective: 1000px;
}

@media (max-width: 768px) {
    .certificates-carousel > .carousel-item {
        flex: 0 0 85vw; /* Adjust for mobile gracefully */
    }
}

.achievement-card {
    background: var(--bg-glass);
    border: var(--glass-border);
    border-radius: 20px;
    padding: 35px 30px;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
    align-items: center; /* Center horizontally */
    text-align: center;  /* Center text */
    position: relative;
    /* Added for 3D Tilt Interaction */
    transform-style: preserve-3d;
    will-change: transform;
}

/* 3D Inner Content pops out */
.achievement-card > * {
    transform: translateZ(30px);
}

.achievement-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 3px;
    border-top-left-radius: 20px;
    border-top-right-radius: 20px;
    background: var(--accent-gradient);
    transform: scaleX(0);
    transform-origin: center;
    transition: transform var(--transition-smooth);
}

.achievement-card:hover {
    border-color: rgba(255,255,255,0.2);
    box-shadow: 0 15px 35px rgba(0,0,0,0.5);
    /* JS will handle 3D transform */
}

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

.achievement-icon {
    font-size: 3rem;
    margin-bottom: 25px;
    transition: var(--transition-fast);
}

.achievement-card:hover .achievement-icon {
    transform: scale(1.1);
    filter: drop-shadow(0 0 10px currentColor);
}

.achievement-text h3 {
    font-size: 1.4rem;
    color: var(--text-primary);
    margin-bottom: 12px;
}

.achievement-text p {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.6;
}

/* Inline Certificate Images */
.cert-image-container {
    width: 100%;
    margin-bottom: 20px;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

.cert-image-inline {
    width: 100%;
    height: 160px;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease;
}

.achievement-card:hover .cert-image-inline {
    transform: scale(1.05);
}

/* Glare overlay injected by JS */
.glare-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    border-radius: 20px;
    z-index: 10;
    pointer-events: none;
    /* Prevent glare from popping out in 3D */
    transform: translateZ(0);
}

.glare {
    position: absolute;
    top: 50%;
    left: 50%;
    pointer-events: none;
    background-image: linear-gradient(0deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 100%);
    width: 200%;
    height: 200%;
    transform: rotate(180deg) translate(-50%, -50%);
    transform-origin: 0% 0%;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.achievement-card:hover .glare {
    opacity: 1;
}

/* === Projects Section === */
.filter-container {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 40px;
}

.filter-btn {
    padding: 8px 20px;
    border-radius: 30px;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition-smooth);
    font-family: var(--font-body);
}

.filter-btn:hover, .filter-btn.active {
    background: var(--accent-gradient);
    color: #000;
    border-color: transparent;
    box-shadow: 0 4px 15px rgba(0, 240, 255, 0.3);
}

body.light-mode .filter-btn.active {
    color: #fff;
}

.project-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.project-card {
    background: var(--bg-surface);
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    transition: var(--transition-smooth);
    border: 1px solid rgba(255,255,255,0.05);
    display: flex;
    flex-direction: column;
}

.project-img-placeholder {
    height: 180px;
    background: linear-gradient(135deg, #151515, #222222);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: rgba(255,255,255,0.1);
    position: relative;
    overflow: hidden;
}

.project-img-placeholder i {
    z-index: 1;
}

.project-img-placeholder::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: var(--accent-gradient);
    opacity: 0.05;
    transition: var(--transition-smooth);
}

.project-card:hover .project-img-placeholder::after {
    opacity: 0.2;
}

.project-info {
    padding: 30px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.project-title {
    font-size: 1.25rem;
    margin-bottom: 10px;
    color: var(--text-primary);
    transition: var(--transition-fast);
}

.project-desc {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 25px;
    flex-grow: 1;
}

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

.tech-tag {
    font-size: 0.75rem;
    padding: 5px 12px;
    background: rgba(255,255,255,0.08);
    border-radius: 6px;
    color: #cecece;
}

.project-links {
    display: flex;
    gap: 20px;
    margin-top: auto;
}

.project-link {
    color: var(--accent-blue);
    font-size: 0.95rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

.project-link:hover {
    color: var(--accent-purple);
    text-shadow: 0 0 10px rgba(138, 43, 226, 0.4);
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.6);
    border-color: rgba(0, 240, 255, 0.3);
}

.project-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 20px;
    padding: 2px;
    background: var(--accent-gradient);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: var(--transition-smooth);
    pointer-events: none;
}

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

/* === Contact Section === */
.contact-container {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: center;
}

.contact-card {
    background: var(--bg-glass);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: var(--glass-border);
    border-radius: 20px;
    padding: 40px 30px;
    text-align: center;
    flex: 1;
    min-width: 280px;
    max-width: 350px;
    transition: var(--transition-smooth);
}

.contact-card:hover {
    transform: translateY(-8px);
    border-color: rgba(138, 43, 226, 0.3);
    box-shadow: 0 15px 35px rgba(0,0,0,0.4);
}

.contact-icon {
    width: 60px;
    height: 60px;
    background: rgba(255,255,255,0.05);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin: 0 auto 20px;
    color: var(--text-primary);
    transition: var(--transition-fast);
}

.contact-card:hover .contact-icon {
    background: var(--accent-gradient);
    color: #000;
    box-shadow: var(--neon-glow);
}

.contact-card h3 {
    font-size: 1.25rem;
    margin-bottom: 12px;
}

.contact-card p, .contact-card a {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: 5px;
    display: block;
}

.contact-card a:hover {
    color: var(--accent-blue);
}

/* === Hire Me Form Styles === */
.hire-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 100px 20px;
}

.hire-container {
    background: var(--bg-glass);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: var(--glass-border);
    border-radius: 20px;
    padding: 50px 40px;
    max-width: 500px;
    width: 100%;
    box-shadow: var(--glass-shadow);
    text-align: center;
}

.hire-container .logo {
    display: inline-block;
    margin-bottom: 30px;
}

.hire-form {
    text-align: left;
}

.input-box {
    margin-bottom: 20px;
}

.input-box input,
.input-box textarea {
    width: 100%;
    padding: 15px;
    background: rgba(0,0,0,0.6);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 10px;
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition-fast);
    outline: none;
}

.input-box textarea {
    height: 140px;
    resize: none;
}

.input-box input:focus,
.input-box textarea:focus {
    border-color: var(--accent-blue);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.2);
    background: rgba(0,0,0,0.8);
}

.hire-form .btn-primary {
    width: 100%;
    margin-top: 10px;
}

.back-link {
    display: inline-block;
    margin-top: 25px;
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.back-link:hover {
    color: var(--accent-blue);
}

/* === Footer === */
footer {
    text-align: center;
    padding: 30px 20px;
    border-top: 1px solid rgba(255,255,255,0.05);
    color: var(--text-secondary);
    font-size: 0.9rem;
    background: rgba(0,0,0,0.5);
}

/* === Animations (Intersection Observer) === */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Delay modifiers */
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.4s; }

/* === Mobile Menu Hamburger === */
.hamburger {
    display: none;
    cursor: pointer;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
}

/* === Responsive === */
@media (max-width: 900px) {
    .home {
        flex-direction: column-reverse;
        text-align: center;
        padding-top: 150px;
    }

    .home-left, .home-right {
        max-width: 100%;
    }

    .home-buttons {
        justify-content: center;
    }

    .img-container {
        width: 250px;
        height: 250px;
    }
    
    .timeline::before {
        left: 0;
    }
    .timeline-dot {
        left: -9px;
    }
    .timeline-item {
        padding-left: 30px;
    }
}

@media (max-width: 768px) {
    .hamburger {
        display: block;
    }

    .nav-links {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 70px);
        background: rgba(5, 5, 5, 0.98);
        backdrop-filter: blur(15px);
        -webkit-backdrop-filter: blur(15px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 30px;
        transition: 0.4s ease-in-out;
    }

    .nav-links.active {
        left: 0;
    }

    .nav-links a {
        font-size: 1.3rem;
    }

    .social-icons {
        display: none;
    }
    
    :root {
        --section-padding: 80px 20px;
    }
}

/* === AI Avatar in Home === */
.waving-robot-container {
    position: absolute; /* Anchor it to the home section only */
    bottom: 40px;
    right: -120px; /* Push it further out into the margin space */
    display: flex;
    flex-direction: column;
    align-items: flex-end; /* Align greeting to the right */
    gap: 12px;
    z-index: 10; /* Lower z-index since it stays in home */
    transition: transform 0.3s ease;
}

@media (max-width: 1500px) {
    .waving-robot-container {
        right: -60px;
    }
}

@media (max-width: 1300px) {
    .waving-robot-container {
        right: 0px;
    }
}

.robot-greeting {
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(0, 240, 255, 0.3);
    padding: 10px 20px;
    border-radius: 12px 12px 0 12px; /* Speech bubble pointing bottom right */
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--accent-blue);
    box-shadow: 0 8px 25px rgba(0, 240, 255, 0.15);
    position: relative;
    animation: fadeIn 1s ease-in-out forwards;
    white-space: nowrap;
    transition: all 0.3s ease;
    letter-spacing: 0.5px;
    font-family: var(--font-body);
}

.robot-greeting::after {
    content: '';
    position: absolute;
    bottom: -8px;
    right: 20px; /* Point to the AI core */
    border-width: 8px 8px 0 0;
    border-style: solid;
    border-color: rgba(0, 240, 255, 0.3) transparent transparent transparent;
    display: block;
    width: 0;
    transition: all 0.3s ease;
}

.waving-robot-container:hover .robot-greeting {
    border-color: rgba(138, 43, 226, 0.5);
    box-shadow: 0 10px 30px rgba(138, 43, 226, 0.25);
    transform: translateY(-5px);
}

.waving-robot-container:hover .robot-greeting::after {
    border-color: rgba(138, 43, 226, 0.5) transparent transparent transparent;
}

/* AI Avatar Animations */
.ai-avatar-svg {
    filter: drop-shadow(0 0 12px rgba(138, 43, 226, 0.4));
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), filter 0.4s ease;
    cursor: pointer;
}

.ai-avatar-svg:hover {
    transform: scale(1.15);
    filter: drop-shadow(0 0 25px rgba(0, 240, 255, 0.7));
}

.ring-slow {
    transform-origin: 50% 50%;
    animation: spinRotate 12s linear infinite;
}

.ring-fast {
    transform-origin: 50% 50%;
    animation: spinRotateReverse 8s linear infinite;
}

.visor-eye {
    animation: scanEye 3s ease-in-out infinite alternate;
}

.ai-avatar-svg:hover .visor-eye {
    fill: var(--accent-purple);
    animation-duration: 0.8s;
}

.wave {
    transform-origin: center;
    transform-box: fill-box;
    animation: voiceActive 0.8s ease-in-out infinite alternate;
}

.w1 { animation-delay: 0.1s; }
.w2 { animation-delay: 0.3s; }
.w3 { animation-delay: 0.2s; }

/* Speed up voice wave on hover */
.ai-avatar-svg:hover .wave {
    animation-duration: 0.3s;
    fill: var(--accent-blue);
}

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

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

@keyframes scanEye {
    0% { transform: translateX(0); }
    100% { transform: translateX(30px); }
}

@keyframes voiceActive {
    0%   { transform: scaleY(0.5); opacity: 0.6; }
    100% { transform: scaleY(1.5); opacity: 1; }
}

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

@media (max-width: 900px) {
    .waving-robot-container {
        bottom: 20px;
        right: 20px;
        transform: scale(0.85); /* shrink slightly so it doesn't block too much */
        transform-origin: bottom right;
    }
}
