/* ==========================================
   KAMAL DEV - Portfolio Stylesheet
   Modern Dark Theme - Indigo & Cyan Palette
   Version: 2.0
   ========================================== */

/* ===== CSS Variables - Design System ===== */
:root {
    /* Primary Palette - Indigo */
    --primary-50:  #eef2ff;
    --primary-100: #e0e7ff;
    --primary-200: #c7d2fe;
    --primary-300: #a5b4fc;
    --primary-400: #818cf8;
    --primary-500: #6366f1;
    --primary-600: #4f46e5;
    --primary-700: #4338ca;
    --primary-800: #3730a3;
    --primary-900: #312e81;

    /* Secondary Palette - Cyan */
    --secondary-400: #22d3ee;
    --secondary-500: #06b6d4;
    --secondary-600: #0891b2;

    /* Semantic Colors */
    --success:       #10b981;
    --success-light: #34d399;
    --success-dark:  #059669;
    --warning:       #f59e0b;
    --error:         #ef4444;
    --info:          #3b82f6;

    /* Background Colors - Better Contrast Hierarchy */
    --bg-primary:    #0a0a12;
    --bg-secondary:  #12121f;
    --bg-tertiary:   #1a1a2e;
    --bg-card:       #151528;
    --bg-card-hover: #1e1e3a;
    --bg-input:      #0f0f1e;

    /* Text Colors - Slate Scale */
    --text-primary:   #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted:     #64748b;
    --text-disabled:  #475569;

    /* Border Colors */
    --border:         rgba(99, 102, 241, 0.06);
    --border-hover:   rgba(99, 102, 241, 0.2);
    --border-focus:   rgba(99, 102, 241, 0.5);

    /* Gradients */
    --gradient-primary: linear-gradient(135deg, var(--primary-500) 0%, var(--secondary-500) 100%);
    --gradient-primary-soft: linear-gradient(135deg, rgba(99,102,241,0.12) 0%, rgba(6,182,212,0.08) 100%);
    --gradient-radial: radial-gradient(circle at 50% 50%, rgba(99,102,241,0.06) 0%, transparent 60%);
    --gradient-glow: radial-gradient(circle at 50% 0%, rgba(99,102,241,0.15) 0%, transparent 50%);

    /* Typography */
    --font-main: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

    /* Spacing Scale */
    --space-1: 0.25rem;   /* 4px */
    --space-2: 0.5rem;    /* 8px */
    --space-3: 0.75rem;   /* 12px */
    --space-4: 1rem;      /* 16px */
    --space-5: 1.25rem;   /* 20px */
    --space-6: 1.5rem;    /* 24px */
    --space-8: 2rem;      /* 32px */
    --space-10: 2.5rem;   /* 40px */
    --space-12: 3rem;     /* 48px */
    --space-16: 4rem;     /* 64px */
    --space-20: 5rem;     /* 80px */
    --space-24: 6rem;     /* 96px */

    /* Layout */
    --container-max: 1200px;
    --container-padding: 1.5rem;
    --section-padding: 6rem;

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 300ms ease;
    --transition-slow: 500ms ease;
    --transition-bounce: 400ms cubic-bezier(0.34, 1.56, 0.64, 1);

    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-2xl: 24px;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4), 0 1px 2px rgba(0, 0, 0, 0.24);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.3), 0 2px 4px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.4), 0 4px 10px rgba(0, 0, 0, 0.2);
    --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.5), 0 8px 16px rgba(0, 0, 0, 0.3);
    --shadow-glow: 0 0 30px rgba(99, 102, 241, 0.2), 0 4px 20px rgba(99, 102, 241, 0.1);
    --shadow-glow-hover: 0 0 40px rgba(99, 102, 241, 0.3), 0 8px 30px rgba(99, 102, 241, 0.15);
}

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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    cursor: none;
}

::selection {
    background: rgba(99, 102, 241, 0.3);
    color: var(--text-primary);
}

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

ul {
    list-style: none;
}

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

/* ===== Scrollbar Styling ===== */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-500);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-400);
}

/* ===== Focus Visible - Accessibility ===== */
:focus-visible {
    outline: 2px solid var(--primary-400);
    outline-offset: 2px;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--primary-400);
    outline-offset: 2px;
    border-radius: var(--radius-sm);
}

/* ===== Custom Cursor ===== */
.cursor-dot,
.cursor-outline {
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    z-index: 9999;
    pointer-events: none;
    will-change: transform;
}

.cursor-dot {
    width: 6px;
    height: 6px;
    background: var(--primary-400);
    transition: width 150ms, height 150ms, background 150ms;
}

.cursor-outline {
    width: 32px;
    height: 32px;
    border: 1.5px solid var(--primary-500);
    transition: width 200ms, height 200ms, border-color 200ms, opacity 200ms;
    opacity: 0.5;
}

body:hover .cursor-outline {
    opacity: 0.5;
}

/* Hide custom cursor on touch devices */
@media (hover: none) and (pointer: coarse) {
    .cursor-dot,
    .cursor-outline {
        display: none;
    }
    
    body {
        cursor: auto;
    }
}

/* ===== Particles Canvas ===== */
.particles-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

/* ===== Container ===== */
.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--container-padding);
}

/* ===== Section Styles ===== */
.section {
    padding: var(--section-padding) 0;
    position: relative;
    z-index: 1;
}

.section__header {
    text-align: center;
    margin-bottom: var(--space-12);
}

.section__subtitle {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--primary-400);
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: var(--space-3);
    padding: var(--space-2) var(--space-4);
    background: var(--gradient-primary-soft);
    border-radius: var(--radius-full);
    border: 1px solid var(--border-hover);
}

.section__title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: var(--space-4);
    letter-spacing: -1px;
    line-height: 1.2;
}

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

.section__line {
    width: 60px;
    height: 3px;
    background: var(--gradient-primary);
    margin: 0 auto;
    border-radius: var(--radius-full);
}

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding: 14px 28px;
    font-family: var(--font-main);
    font-size: 0.95rem;
    font-weight: 600;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
    white-space: nowrap;
}

.btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.1), transparent);
    opacity: 0;
    transition: opacity var(--transition-base);
}

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

.btn--primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow-glow);
}

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

.btn--primary:active {
    transform: translateY(0);
}

.btn--outline {
    background: transparent;
    color: var(--text-primary);
    border: 1.5px solid var(--border);
    box-shadow: none;
}

.btn--outline:hover {
    border-color: var(--primary-500);
    color: var(--primary-400);
    background: rgba(99, 102, 241, 0.08);
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.1);
}

.btn--full {
    width: 100%;
}

/* ===== Header & Navigation ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    padding: var(--space-4) 0;
    transition: all var(--transition-base);
    background: transparent;
}

.header.scrolled {
    background: rgba(10, 10, 18, 0.85);
    backdrop-filter: blur(20px) saturate(1.5);
    -webkit-backdrop-filter: blur(20px) saturate(1.5);
    border-bottom: 1px solid var(--border);
    padding: var(--space-3) 0;
}

.header.scrolled .nav__logo svg {
    max-height: 40px;
}

.nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav__logo {
    display: flex;
    align-items: center;
    max-width: 200px;
    transition: all var(--transition-base);
}

.nav__logo svg {
    width: 100%;
    height: auto;
    max-height: 50px;
    transition: max-height var(--transition-base);
}

.nav__logo:hover {
    opacity: 0.85;
}

.nav__menu {
    display: flex;
    align-items: center;
    gap: var(--space-1);
}

.nav__link {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    padding: var(--space-2) var(--space-4);
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
    position: relative;
}

.nav__link:hover,
.nav__link.active {
    color: var(--text-primary);
    background: rgba(99, 102, 241, 0.1);
}

.nav__link.active::after {
    content: '';
    position: absolute;
    bottom: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 2px;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
}

.nav__toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: var(--space-2);
    z-index: 101;
    background: none;
    border: none;
}

.nav__toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    border-radius: var(--radius-full);
    transition: all var(--transition-base);
}

.nav__toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav__toggle.active span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.nav__toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ===== Hero Section ===== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    z-index: 1;
    padding-top: 130px;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 800px;
    height: 800px;
    background: var(--gradient-radial);
    pointer-events: none;
    z-index: -1;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.05) 0%, transparent 60%);
    pointer-events: none;
    z-index: -1;
}

.hero__content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-16);
    align-items: center;
    width: 100%;
}

.hero__text {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
}

.hero__greeting {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    margin-bottom: var(--space-2);
}

.hero__greeting-line {
    width: 40px;
    height: 2px;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
}

.hero__greeting-text {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--primary-400);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.hero__title {
    font-size: clamp(3rem, 8vw, 5.5rem);
    font-weight: 900;
    line-height: 1.05;
    letter-spacing: -3px;
    margin-bottom: var(--space-3);
}

.hero__title-line {
    display: block;
}

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

.hero__role {
    font-family: var(--font-mono);
    font-size: clamp(1rem, 2.5vw, 1.3rem);
    color: var(--text-secondary);
    margin-bottom: var(--space-4);
    display: flex;
    align-items: center;
    gap: var(--space-1);
}

.hero__role-prefix {
    color: var(--primary-500);
}

.hero__role-text {
    display: inline-block;
}

.hero__role-cursor {
    color: var(--primary-400);
    animation: blink 1s step-end infinite;
}

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

.hero__description {
    font-size: 1.05rem;
    color: var(--text-secondary);
    max-width: 480px;
    margin-bottom: var(--space-8);
    line-height: 1.7;
}

.hero__cta {
    display: flex;
    gap: var(--space-4);
    margin-bottom: var(--space-10);
    flex-wrap: wrap;
}

.hero__socials {
    display: flex;
    gap: var(--space-3);
}

.hero__social-link {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    border: 1px solid var(--border);
    transition: all var(--transition-base);
}

.hero__social-link:hover {
    background: var(--primary-500);
    color: white;
    border-color: var(--primary-500);
    transform: translateY(-3px);
    box-shadow: var(--shadow-glow);
}

/* Hero Code Block */
.hero__visual {
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero__code-block {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    overflow: hidden;
    width: 100%;
    max-width: 420px;
    box-shadow: var(--shadow-lg);
    transition: transform var(--transition-slow), box-shadow var(--transition-slow);
}

.hero__code-block:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl), 0 0 30px rgba(99, 102, 241, 0.08);
    border-color: var(--border-hover);
}

.hero__code-header {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-3) var(--space-5);
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid var(--border);
}

.hero__code-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    transition: opacity var(--transition-fast);
}

.hero__code-dot--red { background: #ef4444; }
.hero__code-dot--yellow { background: #eab308; }
.hero__code-dot--green { background: #22c55e; }

.hero__code-dot:hover {
    opacity: 0.7;
}

.hero__code-filename {
    margin-left: var(--space-2);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
}

.hero__code-content {
    padding: var(--space-5) var(--space-6);
    font-family: var(--font-mono);
    font-size: 0.82rem;
    line-height: 1.8;
    overflow-x: auto;
    white-space: pre-wrap;
}

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

.token-keyword { color: #c084fc; }
.token-var { color: #60a5fa; }
.token-op { color: var(--text-muted); }
.token-prop { color: #93c5fd; }
.token-string { color: #86efac; }
.token-bool { color: #f472b6; }
.token-cursor {
    color: var(--primary-400);
    animation: blink 1s step-end infinite;
}

/* Scroll Indicator */
.hero__scroll-indicator {
    position: absolute;
    bottom: var(--space-10);
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-2);
    opacity: 0.5;
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(-8px); }
}

.hero__scroll-mouse {
    width: 22px;
    height: 34px;
    border: 2px solid var(--text-muted);
    border-radius: 12px;
    display: flex;
    justify-content: center;
    padding-top: 6px;
}

.hero__scroll-wheel {
    width: 3px;
    height: 7px;
    background: var(--primary-500);
    border-radius: var(--radius-full);
    animation: scroll 1.5s ease-in-out infinite;
}

@keyframes scroll {
    0% { transform: translateY(0); opacity: 1; }
    100% { transform: translateY(10px); opacity: 0; }
}

.hero__scroll-text {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 2px;
}

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

.about::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-hover), transparent);
}

.about__grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: var(--space-16);
    align-items: center;
}

.about__image-wrapper {
    position: relative;
}

.about__image-bg {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 100%;
    height: 100%;
    background: var(--gradient-primary);
    border-radius: var(--radius-2xl);
    opacity: 0.15;
    transition: all var(--transition-slow);
}

.about__image-wrapper:hover .about__image-bg {
    opacity: 0.25;
    transform: scale(1.02);
}

.about__image {
    position: relative;
    background: var(--bg-card);
    border-radius: var(--radius-2xl);
    overflow: hidden;
    border: 1px solid var(--border);
    aspect-ratio: 3/4;
    max-width: 380px;
    margin: 0 auto;
}

.about__image-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    display: block;
    transition: transform var(--transition-slow);
}

.about__image:hover .about__image-img {
    transform: scale(1.05);
}

.about__experience {
    position: absolute;
    bottom: -15px;
    right: -15px;
    background: var(--gradient-primary);
    color: white;
    padding: var(--space-5) var(--space-6);
    border-radius: var(--radius-lg);
    text-align: center;
    box-shadow: var(--shadow-glow);
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 100px;
}

.about__experience-number {
    font-size: 2rem;
    font-weight: 800;
    line-height: 1;
}

.about__experience-text {
    font-size: 0.75rem;
    font-weight: 500;
    opacity: 0.9;
    margin-top: var(--space-1);
}

.about__title {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: var(--space-5);
    color: var(--text-primary);
    line-height: 1.3;
}

.about__text {
    color: var(--text-secondary);
    margin-bottom: var(--space-4);
    line-height: 1.7;
}

.about__stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-5);
    margin: var(--space-8) 0;
    padding: var(--space-6);
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
}

.about__stat {
    text-align: center;
    position: relative;
}

.about__stat:not(:last-child)::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    height: 40px;
    width: 1px;
    background: var(--border);
}

.about__stat-number {
    display: block;
    font-size: 1.8rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.about__stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: var(--space-1);
}

.about__btn {
    margin-top: var(--space-2);
}

/* ===== Skills Section ===== */
.skills {
    background: var(--bg-primary);
    position: relative;
}

.skills__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-8);
}

.skills__category {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: var(--space-8);
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
}

.skills__category::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity var(--transition-base);
}

.skills__category:hover {
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.skills__category:hover::before {
    opacity: 1;
}

.skills__category-header {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    margin-bottom: var(--space-8);
}

.skills__category-icon {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
}

.skills__category-icon--frontend {
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary-400);
}

.skills__category-icon--backend {
    background: rgba(6, 182, 212, 0.1);
    color: var(--secondary-400);
}

.skills__category-icon--tools {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success-light);
}

.skills__category:hover .skills__category-icon--frontend {
    background: rgba(99, 102, 241, 0.2);
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.15);
}

.skills__category:hover .skills__category-icon--backend {
    background: rgba(6, 182, 212, 0.2);
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.15);
}

.skills__category:hover .skills__category-icon--tools {
    background: rgba(16, 185, 129, 0.2);
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.15);
}

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

.skill__item {
    margin-bottom: var(--space-5);
}

.skill__item:last-child {
    margin-bottom: 0;
}

.skill__info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--space-2);
}

.skill__name {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-primary);
}

.skill__percent {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
}

.skill__bar {
    width: 100%;
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
    position: relative;
}

.skill__bar::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-full);
    box-shadow: inset 0 1px 2px rgba(0,0,0,0.3);
}

.skill__progress {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    width: 0;
    position: relative;
    transition: width 1.2s cubic-bezier(0.22, 1, 0.36, 1);
}

.skill__progress::after {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 20px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2));
    border-radius: var(--radius-full);
}

/* ===== Projects Section ===== */
.projects {
    background: var(--bg-secondary);
    position: relative;
}

.projects::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-hover), transparent);
}

.projects__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-8);
}

.project-card {
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all var(--transition-base);
    border: 1px solid var(--border);
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--border-hover);
}

.project-card__image {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 10;
}

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

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

.project-card__overlay {
    position: absolute;
    inset: 0;
    background: rgba(10, 10, 18, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity var(--transition-base);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

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

.project-card__link {
    width: 50px;
    height: 50px;
    background: var(--gradient-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transform: translateY(20px) scale(0.8);
    opacity: 0;
    transition: all var(--transition-bounce);
    box-shadow: var(--shadow-glow);
}

.project-card:hover .project-card__link {
    transform: translateY(0) scale(1);
    opacity: 1;
}

.project-card__link:hover {
    transform: scale(1.1);
    box-shadow: var(--shadow-glow-hover);
}

.project-card__content {
    padding: var(--space-6);
}

.project-card__title {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: var(--space-3);
    color: var(--text-primary);
}

.project-card__description {
    font-size: 0.9rem;
    line-height: 1.6;
    color: var(--text-secondary);
    margin-bottom: var(--space-4);
}

.project-card__tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-2);
}

/* Technology-specific tag colors */
.tag {
    font-family: var(--font-mono);
    font-size: 0.72rem;
    font-weight: 500;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    border: 1px solid transparent;
    transition: all var(--transition-fast);
}

.tag:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

/* React */
.tag--react {
    color: #61dafb;
    background: rgba(97, 218, 251, 0.1);
    border-color: rgba(97, 218, 251, 0.2);
}

/* Node.js */
.tag--node {
    color: #68a063;
    background: rgba(104, 160, 99, 0.1);
    border-color: rgba(104, 160, 99, 0.2);
}

/* MongoDB */
.tag--mongo {
    color: #4db33d;
    background: rgba(77, 179, 61, 0.1);
    border-color: rgba(77, 179, 61, 0.2);
}

/* Next.js */
.tag--next {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.15);
}

/* TypeScript */
.tag--ts {
    color: #3178c6;
    background: rgba(49, 120, 198, 0.1);
    border-color: rgba(49, 120, 198, 0.2);
}

/* PostgreSQL */
.tag--pg {
    color: #336791;
    background: rgba(51, 103, 145, 0.1);
    border-color: rgba(51, 103, 145, 0.2);
}

/* React Native */
.tag--rn {
    color: #61dafb;
    background: rgba(97, 218, 251, 0.1);
    border-color: rgba(97, 218, 251, 0.2);
}

/* Firebase */
.tag--firebase {
    color: #ffca28;
    background: rgba(255, 202, 40, 0.1);
    border-color: rgba(255, 202, 40, 0.2);
}

/* Redux */
.tag--redux {
    color: #764abc;
    background: rgba(118, 74, 188, 0.1);
    border-color: rgba(118, 74, 188, 0.2);
}

/* Figma */
.tag--figma {
    color: #f24e1e;
    background: rgba(242, 78, 30, 0.1);
    border-color: rgba(242, 78, 30, 0.2);
}

/* Storybook */
.tag--sb {
    color: #ff4785;
    background: rgba(255, 71, 133, 0.1);
    border-color: rgba(255, 71, 133, 0.2);
}

/* CSS */
.tag--css {
    color: #264de4;
    background: rgba(38, 77, 228, 0.1);
    border-color: rgba(38, 77, 228, 0.2);
}

/* Vue.js */
.tag--vue {
    color: #42b883;
    background: rgba(66, 184, 131, 0.1);
    border-color: rgba(66, 184, 131, 0.2);
}

/* Django */
.tag--django {
    color: #44b78b;
    background: rgba(9, 46, 32, 0.3);
    border-color: rgba(9, 46, 32, 0.4);
}

/* Chart.js */
.tag--chart {
    color: #ff6384;
    background: rgba(255, 99, 132, 0.1);
    border-color: rgba(255, 99, 132, 0.2);
}

/* Socket.io */
.tag--socket {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.15);
}

/* WebRTC */
.tag--webrtc {
    color: #ff6600;
    background: rgba(255, 102, 0, 0.1);
    border-color: rgba(255, 102, 0, 0.2);
}

/* Express */
.tag--express {
    color: var(--text-secondary);
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.12);
}

/* ===== Contact Section ===== */
.contact {
    background: var(--bg-primary);
    position: relative;
}

.contact__grid {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: var(--space-16);
    align-items: start;
}

.contact__title {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: var(--space-4);
    color: var(--text-primary);
}

.contact__text {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: var(--space-8);
}

.contact__details {
    display: flex;
    flex-direction: column;
    gap: var(--space-5);
    margin-bottom: var(--space-8);
}

.contact__item {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    padding: var(--space-3);
    border-radius: var(--radius-md);
    transition: background var(--transition-fast);
}

.contact__item:hover {
    background: rgba(99, 102, 241, 0.05);
}

.contact__icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    color: var(--primary-400);
    flex-shrink: 0;
    transition: all var(--transition-base);
}

.contact__item:hover .contact__icon {
    background: var(--primary-500);
    color: white;
    border-color: var(--primary-500);
    box-shadow: var(--shadow-glow);
}

.contact__label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 2px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.contact__value {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-primary);
    transition: color var(--transition-fast);
}

.contact__value:hover {
    color: var(--primary-400);
}

.contact__socials {
    display: flex;
    gap: var(--space-3);
}

.contact__social-link {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-card);
    color: var(--text-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
}

.contact__social-link:hover {
    background: var(--primary-500);
    color: white;
    border-color: var(--primary-500);
    transform: translateY(-3px);
    box-shadow: var(--shadow-glow);
}

/* Contact Form */
.contact__form {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: var(--space-8);
    position: relative;
    overflow: hidden;
}

.contact__form::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--gradient-primary);
    opacity: 0.5;
}

.form__group {
    position: relative;
    margin-bottom: var(--space-6);
}

.form__input,
.form__textarea {
    width: 100%;
    padding: var(--space-4) var(--space-5);
    font-family: var(--font-main);
    font-size: 0.95rem;
    color: var(--text-primary);
    background: var(--bg-input);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-md);
    outline: none;
    transition: all var(--transition-base);
}

.form__input:focus,
.form__textarea:focus {
    border-color: var(--primary-500);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15), 0 0 20px rgba(99, 102, 241, 0.05);
}

.form__input.error,
.form__textarea.error {
    border-color: var(--error);
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15);
}

.form__input.success,
.form__textarea.success {
    border-color: var(--success);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
}

.form__textarea {
    min-height: 130px;
    resize: vertical;
}

.form__label {
    position: absolute;
    left: var(--space-5);
    top: 14px;
    font-size: 0.95rem;
    color: var(--text-muted);
    pointer-events: none;
    transition: all var(--transition-base);
    background: var(--bg-input);
    padding: 0 var(--space-1);
}

.form__input:focus ~ .form__label,
.form__input:not(:placeholder-shown) ~ .form__label,
.form__textarea:focus ~ .form__label,
.form__textarea:not(:placeholder-shown) ~ .form__label {
    top: -9px;
    font-size: 0.78rem;
    color: var(--primary-400);
}

.form__input:focus ~ .form__label {
    color: var(--primary-400);
}

.form__success {
    display: none;
    align-items: center;
    gap: var(--space-3);
    margin-top: var(--space-4);
    padding: var(--space-4) var(--space-5);
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
    border: 1px solid rgba(16, 185, 129, 0.2);
    border-radius: var(--radius-md);
    font-size: 0.9rem;
    font-weight: 500;
}

.form__success.show {
    display: flex;
    animation: fadeInUp 0.4s ease;
}

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

/* ===== Footer ===== */
.footer {
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    padding: var(--space-12) 0 var(--space-6);
    position: relative;
    z-index: 1;
}

.footer__content {
    text-align: center;
    margin-bottom: var(--space-8);
}

.footer__content svg {
    max-width: 280px;
    height: auto;
    margin: 0 auto var(--space-4);
    display: block;
}

.footer__text {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: var(--space-6);
}

.footer__nav {
    display: flex;
    justify-content: center;
    gap: var(--space-8);
    flex-wrap: wrap;
}

.footer__link {
    font-size: 0.9rem;
    color: var(--text-secondary);
    transition: all var(--transition-fast);
    position: relative;
}

.footer__link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--primary-400);
    transition: width var(--transition-base);
}

.footer__link:hover {
    color: var(--primary-400);
}

.footer__link:hover::after {
    width: 100%;
}

.footer__bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: var(--space-6);
    border-top: 1px solid var(--border);
    flex-wrap: wrap;
    gap: var(--space-3);
}

.footer__copyright,
.footer__credit {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.footer__credit {
    font-family: var(--font-mono);
}

/* ===== Back to Top ===== */
.back-to-top {
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-500);
    color: white;
    border-radius: 50%;
    z-index: 99;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all var(--transition-base);
    box-shadow: var(--shadow-glow);
    border: none;
    cursor: pointer;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    background: var(--primary-400);
    transform: translateY(-4px);
    box-shadow: var(--shadow-glow-hover);
}

/* ===== WhatsApp Float Button ===== */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 56px;
    height: 56px;
    background: var(--success);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
    z-index: 99;
    transition: all var(--transition-base);
    text-decoration: none;
}

.whatsapp-float:hover {
    transform: scale(1.1) translateY(-2px);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.5);
    background: var(--success-light);
}

.whatsapp-float:active {
    transform: scale(0.95);
}

/* ===== Scroll Reveal Animations ===== */
.reveal-bottom {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal-right.visible {
    opacity: 1;
    transform: translateX(0);
}

.reveal-scale {
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal-scale.visible {
    opacity: 1;
    transform: scale(1);
}

/* Stagger delay support via data-delay attribute */
.reveal-bottom[data-delay="100"],
.reveal-left[data-delay="100"],
.reveal-right[data-delay="100"],
.reveal-scale[data-delay="100"] {
    transition-delay: 0.1s;
}

.reveal-bottom[data-delay="200"],
.reveal-left[data-delay="200"],
.reveal-right[data-delay="200"],
.reveal-scale[data-delay="200"] {
    transition-delay: 0.2s;
}

.reveal-bottom[data-delay="300"],
.reveal-left[data-delay="300"],
.reveal-right[data-delay="300"],
.reveal-scale[data-delay="300"] {
    transition-delay: 0.3s;
}

.reveal-bottom[data-delay="400"],
.reveal-left[data-delay="400"],
.reveal-right[data-delay="400"],
.reveal-scale[data-delay="400"] {
    transition-delay: 0.4s;
}

.reveal-bottom[data-delay="500"],
.reveal-left[data-delay="500"],
.reveal-right[data-delay="500"],
.reveal-scale[data-delay="500"] {
    transition-delay: 0.5s;
}

/* ===== Responsive Design ===== */

/* Tablets & Small Laptops */
@media (max-width: 1024px) {
    :root {
        --section-padding: 4rem;
    }

    .skills__grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .projects__grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .hero__content {
        gap: var(--space-10);
    }
}

/* Mobile Devices */
@media (max-width: 768px) {
    :root {
        --section-padding: 3rem;
        --container-padding: 1rem;
    }

    /* Navigation */
    .nav__menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 75%;
        max-width: 320px;
        height: 100vh;
        background: var(--bg-secondary);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: var(--space-2);
        transition: right var(--transition-slow);
        border-left: 1px solid var(--border);
        z-index: 100;
        padding: var(--space-8) 0;
    }

    .nav__menu.active {
        right: 0;
    }

    /* Menu overlay */
    .nav__menu.active::before {
        content: '';
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: -1;
        animation: fadeIn 0.3s ease;
    }

    @keyframes fadeIn {
        from { opacity: 0; }
        to { opacity: 1; }
    }

    .nav__link {
        font-size: 1.1rem;
        padding: var(--space-3) var(--space-6);
        width: 80%;
        text-align: center;
    }

    .nav__toggle {
        display: flex;
    }

    .nav__logo svg {
        max-height: 40px;
    }

    /* Hero */
    .hero__content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: var(--space-10);
    }

    .hero__greeting {
        justify-content: center;
    }

    .hero__description {
        margin-left: auto;
        margin-right: auto;
    }

    .hero__cta {
        justify-content: center;
    }

    .hero__socials {
        justify-content: center;
    }

    .hero__visual {
        order: -1;
    }

    .hero__code-block {
        max-width: 340px;
        margin: 0 auto;
    }

    .hero__scroll-indicator {
        display: none;
    }

    /* About */
    .about__grid {
        grid-template-columns: 1fr;
        gap: var(--space-12);
    }

    .about__image-wrapper {
        display: flex;
        justify-content: center;
    }

    .about__image {
        max-width: 300px;
    }

    .about__experience {
        right: 10px;
        bottom: -10px;
        padding: var(--space-4) var(--space-5);
        min-width: 80px;
    }

    .about__experience-number {
        font-size: 1.5rem;
    }

    .about__stats {
        grid-template-columns: 1fr;
        gap: var(--space-4);
    }

    .about__stat:not(:last-child)::after {
        display: none;
    }

    /* Skills */
    .skills__grid {
        grid-template-columns: 1fr;
        max-width: 500px;
        margin: 0 auto;
    }

    /* Projects */
    .projects__grid {
        grid-template-columns: 1fr;
        max-width: 450px;
        margin: 0 auto;
    }

    /* Contact */
    .contact__grid {
        grid-template-columns: 1fr;
        gap: var(--space-10);
    }

    .contact__form {
        padding: var(--space-6);
    }

    /* Footer */
    .footer__nav {
        gap: var(--space-4);
    }

    .footer__bottom {
        flex-direction: column;
        text-align: center;
        gap: var(--space-2);
    }

    /* Floating Buttons */
    .back-to-top {
        bottom: 90px;
        right: 20px;
        width: 44px;
        height: 44px;
    }

    .whatsapp-float {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
    }
}

/* Small Mobile Devices */
@media (max-width: 480px) {
    .hero__title {
        letter-spacing: -1px;
    }

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

    .hero__cta {
        flex-direction: column;
        align-items: center;
    }

    .btn--outline,
    .btn--primary {
        width: 100%;
        max-width: 260px;
        justify-content: center;
    }

    .hero__code-block {
        max-width: 280px;
    }

    .hero__code-content {
        font-size: 0.7rem;
        padding: var(--space-4);
    }

    .section__title {
        font-size: 1.8rem;
    }

    .contact__form {
        padding: var(--space-4);
    }

    .footer__content svg {
        max-width: 200px;
    }
}

/* ===== Reduced Motion ===== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    html {
        scroll-behavior: auto;
    }

    .reveal-bottom,
    .reveal-left,
    .reveal-right,
    .reveal-scale {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }

    .hero__scroll-indicator {
        animation: none !important;
    }

    .hero__scroll-wheel {
        animation: none !important;
    }
}

/* ===== Dark Mode Support (System) ===== */
@media (prefers-color-scheme: light) {
    :root {
        --bg-primary: #f8fafc;
        --bg-secondary: #f1f5f9;
        --bg-tertiary: #e2e8f0;
        --bg-card: #ffffff;
        --bg-card-hover: #f8fafc;
        --bg-input: #f1f5f9;
        
        --text-primary: #0f172a;
        --text-secondary: #475569;
        --text-muted: #64748b;
        
        --border: rgba(99, 102, 241, 0.12);
        --border-hover: rgba(99, 102, 241, 0.25);
    }

    .hero__code-block {
        background: #ffffff;
        border-color: var(--border);
    }

    .hero__code-header {
        background: rgba(0, 0, 0, 0.02);
    }

    .contact__form {
        background: #ffffff;
    }

    .form__input,
    .form__textarea {
        background: var(--bg-input);
    }

    .skills__category {
        background: #ffffff;
    }

    .project-card {
        background: #ffffff;
    }

    .about__image {
        background: #ffffff;
    }
}

/* ===== Print Styles ===== */
@media print {
    .header,
    .hero__scroll-indicator,
    .back-to-top,
    .whatsapp-float,
    .particles-canvas,
    .cursor-dot,
    .cursor-outline {
        display: none !important;
    }

    body {
        background: white !important;
        color: black !important;
        cursor: auto !important;
    }

    .section {
        padding: 2rem 0 !important;
        page-break-inside: avoid;
    }

    .hero {
        min-height: auto !important;
        padding: 4rem 0 !important;
    }

    .container {
        max-width: 100% !important;
    }

    .btn {
        border: 1px solid #000 !important;
        background: transparent !important;
        color: #000 !important;
        box-shadow: none !important;
    }

    .text-accent {
        -webkit-text-fill-color: var(--primary-600) !important;
        color: var(--primary-600) !important;
        background: none !important;
    }

    .hero__title-line--accent {
        -webkit-text-fill-color: var(--primary-600) !important;
        color: var(--primary-600) !important;
        background: none !important;
    }

    .about__stat-number {
        -webkit-text-fill-color: var(--primary-600) !important;
        color: var(--primary-600) !important;
        background: none !important;
    }

    .skill__progress {
        background: var(--primary-600) !important;
    }
}