/* ====== VARIABLES ====== */
:root {
    /* Colors */
    --purple-primary: #8a2be2;
    --purple-secondary: #6a1b9a;
    --purple-dark: #4a148c;
    --purple-light: #9c4dff;
    --purple-glow: rgba(138, 43, 226, 0.6);
    --purple-faint: rgba(138, 43, 226, 0.1);
    --black: #0a0a0f;
    --dark-gray: #1a1a2e;
    --gray: #2d2d44;
    --light-gray: #4a4a6a;
    --white: #ffffff;
    --off-white: #f5f5f7;

    /* Gradients */
    --gradient-purple: linear-gradient(135deg, var(--purple-primary), var(--purple-light));
    --gradient-dark: linear-gradient(135deg, var(--black) 0%, var(--dark-gray) 100%);

    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.3);
    --glow-purple: 0 0 20px var(--purple-glow);

    /* Transitions */
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);

    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 50%;

    /* Fonts */
    --font-mono: 'JetBrains Mono', monospace;

    /* Spacing */
    --header-height: 80px;
    --section-spacing: 100px;
    --container-padding: 2rem;
}

/* ====== RESET & BASE ====== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-mono);
    background: var(--gradient-dark);
    color: var(--white);
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
    line-height: 1.6;
}

/* ====== BLINKING STARS BACKGROUND ====== */
.stars-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.stars {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        radial-gradient(1px 1px at 5% 15%, rgba(255, 255, 255, 0.8), transparent),
        radial-gradient(1px 1px at 10% 35%, rgba(255, 255, 255, 0.7), transparent),
        radial-gradient(1.5px 1.5px at 15% 65%, rgba(255, 255, 255, 0.9), transparent),
        radial-gradient(1px 1px at 20% 85%, rgba(255, 255, 255, 0.6), transparent),
        radial-gradient(1.5px 1.5px at 25% 25%, rgba(255, 255, 255, 0.8), transparent),
        radial-gradient(1px 1px at 30% 55%, rgba(255, 255, 255, 0.7), transparent),
        radial-gradient(2px 2px at 35% 75%, rgba(255, 255, 255, 0.9), transparent),
        radial-gradient(1px 1px at 40% 10%, rgba(255, 255, 255, 0.6), transparent),
        radial-gradient(1.5px 1.5px at 45% 45%, rgba(255, 255, 255, 0.8), transparent),
        radial-gradient(1px 1px at 50% 85%, rgba(255, 255, 255, 0.7), transparent),
        radial-gradient(2px 2px at 55% 25%, rgba(255, 255, 255, 0.9), transparent),
        radial-gradient(1px 1px at 60% 65%, rgba(255, 255, 255, 0.6), transparent),
        radial-gradient(1.5px 1.5px at 65% 40%, rgba(255, 255, 255, 0.8), transparent),
        radial-gradient(1px 1px at 70% 90%, rgba(255, 255, 255, 0.7), transparent),
        radial-gradient(2px 2px at 75% 15%, rgba(255, 255, 255, 0.9), transparent),
        radial-gradient(1px 1px at 80% 50%, rgba(255, 255, 255, 0.6), transparent),
        radial-gradient(1.5px 1.5px at 85% 70%, rgba(255, 255, 255, 0.8), transparent),
        radial-gradient(1px 1px at 90% 30%, rgba(255, 255, 255, 0.7), transparent),
        radial-gradient(2px 2px at 95% 80%, rgba(255, 255, 255, 0.9), transparent),
        radial-gradient(1px 1px at 98% 45%, rgba(255, 255, 255, 0.6), transparent);
    background-repeat: repeat;
    background-size: 100% 100%;
    opacity: 0.8;
}

.stars:nth-child(1) {
    animation: blink-slow 6s infinite;
}

.stars:nth-child(2) {
    animation: blink-medium 4s infinite 1s;
    opacity: 0.6;
}

.stars:nth-child(3) {
    animation: blink-fast 2s infinite 0.5s;
    opacity: 0.4;
}

/* Noise Overlay */
.noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.03'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 1;
}

/* ====== UTILITY CLASSES ====== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--container-padding);
    width: 100%;
    position: relative;
    z-index: 2;
}

.purple-text {
    color: var(--purple-primary);
    position: relative;
    display: inline-block;
}

.purple-text::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--gradient-purple);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--transition-normal);
}

.purple-text:hover::after {
    transform: scaleX(1);
}

.purple-dot {
    color: var(--purple-primary);
}

/* ====== NAVBAR ====== */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(10, 10, 15, 0.95);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    z-index: 1000;
    border-bottom: 1px solid rgba(138, 43, 226, 0.1);
    height: var(--header-height);
    transition: all var(--transition-normal);
}

.navbar.scrolled {
    background: rgba(10, 10, 15, 0.98);
    box-shadow: var(--shadow-lg);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    padding: 0 2rem;
    max-width: 1400px;
    margin: 0 auto;
}

.nav-logo .logo-text {
    font-size: 1.8rem;
    font-weight: 700;
    text-decoration: none;
    color: var(--white);
    letter-spacing: 1px;
    transition: all var(--transition-normal);
    position: relative;
    display: inline-block;
}

.nav-logo .logo-text:hover {
    color: var(--purple-light);
    transform: translateY(-2px);
}

.nav-logo .logo-text::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-purple);
    transition: width var(--transition-normal);
}

.nav-logo .logo-text:hover::after {
    width: 100%;
}

.nav-menu {
    flex-grow: 1;
    display: flex;
    justify-content: center;
}

.nav-list {
    display: flex;
    gap: 2.5rem;
    list-style: none;
}

.nav-item {
    position: relative;
}

.nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: var(--white);
    font-size: 0.9rem;
    transition: all var(--transition-normal);
    opacity: 0.7;
    padding: 0.5rem;
    min-width: 70px;
    position: relative;
    overflow: hidden;
}

.nav-link i {
    font-size: 1.3rem;
    margin-bottom: 0.4rem;
    transition: all var(--transition-normal);
    position: relative;
    z-index: 2;
}

.nav-link span {
    font-size: 0.8rem;
    letter-spacing: 0.5px;
    font-weight: 500;
    transition: all var(--transition-normal);
    position: relative;
    z-index: 2;
}

/* Hover effect for nav links */
.nav-link::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: var(--radius-full);
    background: var(--purple-faint);
    transform: translate(-50%, -50%);
    transition: all var(--transition-normal);
    z-index: 1;
}

.nav-link:hover::before,
.nav-link.active::before {
    width: 60px;
    height: 60px;
    background: rgba(138, 43, 226, 0.15);
}

.nav-link:hover,
.nav-link.active {
    opacity: 1;
    color: var(--purple-primary);
    transform: translateY(-2px);
}

.nav-link:hover i,
.nav-link.active i {
    color: var(--purple-primary);
    transform: scale(1.2);
    text-shadow: 0 0 10px var(--purple-glow);
}

.nav-link:hover span,
.nav-link.active span {
    color: var(--purple-light);
}

/* Active indicator */
.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 20px;
    height: 3px;
    background: var(--gradient-purple);
    border-radius: 2px;
    transition: transform var(--transition-normal);
}

.nav-link.active::after {
    transform: translateX(-50%) scaleX(1);
}

.cta-button {
    background: var(--gradient-purple);
    color: var(--white);
    border: none;
    padding: 0.8rem 1.8rem;
    border-radius: var(--radius-xl);
    font-family: var(--font-mono);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.8rem;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left var(--transition-slow);
    z-index: -1;
}

.cta-button:hover::before {
    left: 100%;
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: var(--glow-purple);
}

.hamburger {
    display: none;
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    transition: all var(--transition-normal);
    z-index: 1001;
}

.hamburger:hover {
    color: var(--purple-primary);
    transform: scale(1.1);
}

/* ====== HERO SECTION ====== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: var(--header-height);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    height: 80%;
    background: radial-gradient(circle, rgba(138, 43, 226, 0.1) 0%, transparent 70%);
    z-index: -1;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    width: 100%;
}

.hero-text {
    animation: fadeInLeft 1s ease;
}

.hero-greeting {
    font-size: 1.2rem;
    font-weight: 400;
    margin-bottom: 1rem;
    color: var(--purple-light);
    letter-spacing: 2px;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.2s forwards;
}

.hero-name {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    letter-spacing: 1px;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.4s forwards;
}

.hero-name .purple-text {
    background: var(--gradient-purple);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    position: relative;
}

.hero-subtitle {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
    font-size: clamp(1.2rem, 3vw, 1.5rem);
    margin-bottom: 2rem;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.6s forwards;
}

.typewriter {
    display: flex;
    align-items: center;
    min-height: 1.8em;
}

.type-text {
    color: var(--purple-primary);
    font-weight: 600;
    text-shadow: 0 0 10px var(--purple-glow);
}

.cursor {
    color: var(--purple-primary);
    animation: blink 1s infinite;
    margin-left: 2px;
    font-weight: 700;
}

.hero-description {
    font-size: clamp(1rem, 2vw, 1.1rem);
    line-height: 1.6;
    margin-bottom: 2.5rem;
    color: var(--off-white);
    opacity: 0.9;
    max-width: 500px;
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.8s forwards;
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    opacity: 0;
    animation: fadeInUp 0.8s ease 1s forwards;
}

.btn-primary,
.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.8rem;
    padding: 1rem 2rem;
    text-decoration: none;
    border-radius: var(--radius-md);
    font-weight: 600;
    transition: all var(--transition-normal);
    font-size: 1rem;
    text-align: center;
    min-width: fit-content;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-primary {
    background: var(--gradient-purple);
    color: var(--white);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left var(--transition-slow);
    z-index: -1;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: var(--glow-purple);
}

.btn-secondary {
    background: transparent;
    color: var(--white);
    border: 2px solid var(--purple-primary);
}

.btn-secondary:hover {
    background: rgba(138, 43, 226, 0.1);
    transform: translateY(-3px);
    border-color: var(--purple-light);
    box-shadow: 0 5px 15px rgba(138, 43, 226, 0.2);
}

/* Hover effect for buttons */
.btn-primary:hover .fas,
.btn-secondary:hover .fas {
    transform: translateX(5px);
}

.btn-primary .fas,
.btn-secondary .fas {
    transition: transform var(--transition-normal);
}

.hero-illustration {
    animation: fadeInRight 1s ease;
    position: relative;
}

.hero-illustration::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(138, 43, 226, 0.2) 0%, transparent 70%);
    z-index: -1;
    animation: pulse 4s infinite;
}

.illustration-container {
    position: relative;
    width: 100%;
    max-width: 500px;
    height: 400px;
    margin: 0 auto;
}

.code-window {
    position: absolute;
    top: 20px;
    right: 0;
    width: clamp(250px, 100%, 300px);
    background: rgba(26, 26, 46, 0.9);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid rgba(138, 43, 226, 0.3);
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(10px);
    z-index: 3;
    transition: all var(--transition-normal);
}

.code-window:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.4);
}

.window-header {
    background: rgba(20, 20, 35, 0.9);
    padding: 0.8rem 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    border-bottom: 1px solid rgba(138, 43, 226, 0.2);
}

.window-dots {
    display: flex;
    gap: 0.5rem;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: var(--radius-full);
    transition: transform var(--transition-fast);
}

.dot.red {
    background: #ff5f56;
}

.dot.yellow {
    background: #ffbd2e;
}

.dot.green {
    background: #27c93f;
}

.code-window:hover .dot {
    transform: scale(1.2);
}

.window-title {
    font-size: 0.85rem;
    opacity: 0.8;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.code-content {
    padding: 1.2rem;
    overflow-x: auto;
}

.code-content pre {
    margin: 0;
    font-size: 0.85rem;
    line-height: 1.4;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.code-content code {
    color: var(--purple-light);
    font-family: var(--font-mono);
    transition: all var(--transition-normal);
}

.code-window:hover code {
    text-shadow: 0 0 10px var(--purple-glow);
}

.developer-image {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    max-width: 400px;
    height: 300px;
    transition: all var(--transition-normal);
}

.desk,
.laptop,
.developer {
    position: absolute;
    background: var(--gray);
    transition: all var(--transition-normal);
}

.developer-image:hover .desk {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.developer-image:hover .laptop {
    transform: translateY(-10px) rotate(2deg);
    box-shadow: 0 15px 30px rgba(138, 43, 226, 0.3);
}

.developer-image:hover .developer {
    transform: translateY(-8px);
    animation: bounce 2s infinite;
}

.desk {
    width: 80%;
    max-width: 250px;
    height: 15px;
    bottom: 0;
    left: 10%;
    border-radius: var(--radius-sm);
    background: linear-gradient(90deg, var(--light-gray), var(--gray));
}

.laptop {
    width: 50%;
    max-width: 150px;
    height: 100px;
    bottom: 15px;
    left: 25%;
    border-radius: var(--radius-md);
    background: var(--dark-gray);
    border: 1px solid var(--purple-primary);
    box-shadow: 0 0 20px var(--purple-glow);
}

.laptop::before {
    content: '';
    position: absolute;
    top: 5px;
    left: 5px;
    right: 5px;
    bottom: 5px;
    background: var(--black);
    border-radius: 4px;
}

.developer {
    width: 30%;
    max-width: 80px;
    height: 120px;
    bottom: 15px;
    left: 35%;
    background: linear-gradient(135deg, var(--purple-dark), var(--purple-primary));
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
    box-shadow: 0 0 30px var(--purple-glow);
}

/* ====== ABOUT SECTION ====== */
.about {
    padding: var(--section-spacing) 0;
    position: relative;
}

.about::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--purple-primary), transparent);
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease forwards;
}

.section-title {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 1rem;
    line-height: 1.3;
}

.section-title .purple-text {
    background: var(--gradient-purple);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease 0.2s forwards;
}

.about-text {
    font-size: clamp(1rem, 2vw, 1.1rem);
    line-height: 1.8;
}

.about-text p {
    margin-bottom: 1.5rem;
    opacity: 0;
    transform: translateX(-20px);
    animation: fadeInRight 0.6s ease forwards;
}

.about-text p:nth-child(1) {
    animation-delay: 0.4s;
}

.about-text p:nth-child(2) {
    animation-delay: 0.6s;
}

.about-text p:nth-child(3) {
    animation-delay: 0.8s;
}

.about-text p:nth-child(4) {
    animation-delay: 1s;
}

.about-text .purple-text {
    font-weight: 600;
    position: relative;
    cursor: pointer;
}

.about-text .purple-text:hover {
    text-shadow: 0 0 10px var(--purple-glow);
}

.about-avatar {
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transform: scale(0.8);
    animation: fadeInScale 0.8s ease 0.4s forwards;
}

.avatar-container {
    position: relative;
    width: clamp(200px, 80%, 300px);
    height: clamp(200px, 80%, 300px);
    margin: 0 auto;
    cursor: pointer;
}

.avatar-container:hover .avatar-image {
    transform: rotate(5deg) scale(1.05);
    box-shadow: 0 0 60px var(--purple-glow);
}

.avatar-container:hover .orbit {
    animation-duration: 15s;
}

.avatar-image {
    width: 100%;
    height: 100%;
    border-radius: var(--radius-full);
    background: var(--gradient-purple);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 3;
    overflow: hidden;
    transition: all var(--transition-normal);
    box-shadow: 0 0 40px var(--purple-glow);
}

.avatar-image::before {
    content: '';
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    background: var(--gradient-purple);
    border-radius: var(--radius-full);
    z-index: -1;
    opacity: 0.5;
    filter: blur(20px);
}

.avatar-placeholder {
    font-size: clamp(4rem, 15vw, 8rem);
    color: white;
    opacity: 0.9;
    transition: all var(--transition-normal);
}

.avatar-container:hover .avatar-placeholder {
    transform: scale(1.1);
    filter: drop-shadow(0 0 10px white);
}

.avatar-decoration {
    position: absolute;
    top: -15px;
    left: -15px;
    right: -15px;
    bottom: -15px;
}

.orbit {
    position: absolute;
    border-radius: var(--radius-full);
    border: 1px solid rgba(138, 43, 226, 0.3);
    animation: rotate 20s linear infinite;
    transition: animation-duration var(--transition-normal);
}

.orbit-1 {
    top: 10%;
    left: 10%;
    right: 10%;
    bottom: 10%;
    animation-direction: reverse;
}

.orbit-2 {
    top: 5%;
    left: 5%;
    right: 5%;
    bottom: 5%;
}

.orbit-3 {
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    animation-duration: 30s;
}

/* ====== CONTACT SECTION ====== */
.contact {
    padding: var(--section-spacing) 0;
    text-align: center;
    position: relative;
}

.contact::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--purple-primary), transparent);
}

.section-subtitle {
    font-size: clamp(1rem, 2vw, 1.2rem);
    color: var(--off-white);
    opacity: 0.8;
    max-width: 600px;
    margin: 0 auto 3rem;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s ease 0.4s forwards;
}

.social-icons {
    display: flex;
    justify-content: center;
    gap: clamp(1rem, 3vw, 2rem);
    margin-top: 3rem;
    flex-wrap: wrap;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 0.8s ease 0.6s forwards;
}

.social-icon {
    width: clamp(50px, 10vw, 60px);
    height: clamp(50px, 10vw, 60px);
    border-radius: var(--radius-full);
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: clamp(1.2rem, 3vw, 1.5rem);
    text-decoration: none;
    transition: all var(--transition-normal);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.social-icon::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left var(--transition-slow);
    z-index: -1;
}

.social-icon:hover::before {
    left: 100%;
}

.social-icon:hover {
    background: var(--purple-primary);
    transform: translateY(-10px) scale(1.1);
    box-shadow: var(--glow-purple);
    border-color: var(--purple-primary);
}

/* Tooltip for social icons */
.social-icon::after {
    content: attr(aria-label);
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
    z-index: 100;
}

.social-icon:hover::after {
    opacity: 1;
    visibility: visible;
    bottom: -35px;
}

/* ====== FOOTER ====== */
.footer {
    background: rgba(10, 10, 15, 0.95);
    padding: 3rem 0 2rem;
    border-top: 1px solid rgba(138, 43, 226, 0.1);
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--purple-primary), transparent);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.5rem;
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

.footer-text {
    font-size: clamp(0.8rem, 2vw, 0.9rem);
    opacity: 0.8;
    text-align: center;
    flex: 1;
    min-width: 250px;
}

.footer-text .purple-text {
    font-weight: 600;
    position: relative;
}

.footer-text .purple-text:hover {
    text-shadow: 0 0 10px var(--purple-glow);
}

.copyright {
    margin-top: 0.5rem;
    font-size: clamp(0.7rem, 1.5vw, 0.8rem);
    opacity: 0.6;
}

.footer-social {
    display: flex;
    gap: clamp(0.8rem, 2vw, 1rem);
    justify-content: center;
    flex: 1;
    min-width: 150px;
}

.footer-icon {
    color: var(--white);
    font-size: clamp(1rem, 2vw, 1.2rem);
    opacity: 0.7;
    transition: all var(--transition-normal);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    position: relative;
}

.footer-icon:hover {
    opacity: 1;
    color: var(--purple-primary);
    transform: translateY(-3px) scale(1.2);
    text-shadow: 0 0 8px var(--purple-glow);
}

/* ====== ANIMATIONS ====== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.8);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-15px);
    }
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes blink-slow {

    0%,
    100% {
        opacity: 0.8;
    }

    50% {
        opacity: 0.3;
    }
}

@keyframes blink-medium {

    0%,
    100% {
        opacity: 0.6;
    }

    50% {
        opacity: 0.2;
    }
}

@keyframes blink-fast {

    0%,
    100% {
        opacity: 0.4;
    }

    50% {
        opacity: 0.1;
    }
}

@keyframes pulse {

    0%,
    100% {
        opacity: 0.5;
        transform: translate(-50%, -50%) scale(1);
    }

    50% {
        opacity: 0.8;
        transform: translate(-50%, -50%) scale(1.1);
    }
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

/* ====== RESPONSIVE DESIGN ====== */

/* Large Desktop (1440px and above) */
@media (min-width: 1440px) {
    .container {
        max-width: 1400px;
    }

    .hero-name {
        font-size: 4rem;
    }

    .hero-subtitle {
        font-size: 1.8rem;
    }
}

/* Desktop (1024px - 1439px) */
@media (max-width: 1024px) {
    .hero-content {
        gap: 3rem;
    }

    .about-content {
        gap: 3rem;
    }

    .nav-list {
        gap: 2rem;
    }
}

/* Tablet Landscape (768px - 1023px) */
@media (max-width: 1023px) {
    .hero-content {
        gap: 2.5rem;
    }

    .hero-name {
        font-size: 3rem;
    }

    .hero-subtitle {
        font-size: 1.3rem;
    }

    .illustration-container {
        height: 350px;
    }

    .developer-image {
        height: 250px;
    }

    .about-content {
        gap: 2.5rem;
    }

    .avatar-container {
        width: 250px;
        height: 250px;
    }
}

/* Tablet Portrait (600px - 767px) */
@media (max-width: 767px) {
    .nav-menu {
        position: fixed;
        top: var(--header-height);
        left: -100%;
        width: 100%;
        height: calc(100vh - var(--header-height));
        background: rgba(10, 10, 15, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        padding: 2rem;
        transition: all var(--transition-normal);
        display: block;
        overflow-y: auto;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-list {
        flex-direction: column;
        gap: 2rem;
        align-items: center;
        justify-content: center;
        height: 100%;
    }

    .nav-link {
        font-size: 1.1rem;
        padding: 1rem;
        min-width: 100px;
    }

    .nav-link i {
        font-size: 1.5rem;
        margin-bottom: 0.5rem;
    }

    .nav-link span {
        font-size: 1rem;
    }

    .nav-cta {
        display: none;
    }

    .hamburger {
        display: block;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }

    .hero-text {
        order: 2;
    }

    .hero-illustration {
        order: 1;
    }

    .hero-description {
        margin: 0 auto 2.5rem;
    }

    .hero-buttons {
        justify-content: center;
    }

    .illustration-container {
        height: 300px;
        max-width: 400px;
    }

    .developer-image {
        max-width: 350px;
        left: 50%;
        transform: translateX(-50%);
    }

    .about-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 3rem;
    }

    .about-text {
        padding: 0 1rem;
    }
}

/* Mobile Landscape (480px - 599px) */
@media (max-width: 599px) {
    :root {
        --container-padding: 1rem;
        --section-spacing: 80px;
    }

    .nav-container {
        padding: 0 1rem;
    }

    .hero-name {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        flex-direction: column;
        align-items: center;
        gap: 0.5rem;
        font-size: 1.2rem;
    }

    .hero-greeting {
        font-size: 1.1rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
        max-width: 250px;
        justify-content: center;
    }

    .illustration-container {
        height: 250px;
    }

    .code-window {
        width: 200px;
        top: 10px;
    }

    .code-content {
        padding: 1rem;
    }

    .code-content pre {
        font-size: 0.75rem;
    }

    .developer-image {
        height: 200px;
    }

    .desk {
        height: 12px;
    }

    .laptop {
        height: 80px;
    }

    .developer {
        height: 100px;
    }

    .section-title {
        font-size: 1.6rem;
        letter-spacing: 1px;
    }

    .avatar-container {
        width: 200px;
        height: 200px;
    }

    .social-icons {
        gap: 1rem;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
    }
}

/* Mobile Portrait (320px - 479px) */
@media (max-width: 479px) {
    html {
        font-size: 14px;
    }

    .container {
        padding: 0 0.75rem;
    }

    .nav-container {
        padding: 0 0.75rem;
    }

    .nav-logo .logo-text {
        font-size: 1.5rem;
    }

    .hamburger {
        font-size: 1.3rem;
    }

    .hero {
        min-height: calc(100vh - var(--header-height));
    }

    .hero-name {
        font-size: 2rem;
        line-height: 1.1;
    }

    .hero-greeting {
        font-size: 1rem;
        letter-spacing: 1px;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-description {
        font-size: 0.95rem;
        line-height: 1.5;
    }

    .btn-primary,
    .btn-secondary {
        padding: 0.8rem 1.5rem;
        font-size: 0.9rem;
    }

    .illustration-container {
        height: 220px;
    }

    .code-window {
        width: 180px;
    }

    .window-header {
        padding: 0.6rem 0.8rem;
    }

    .dot {
        width: 8px;
        height: 8px;
    }

    .window-title {
        font-size: 0.75rem;
    }

    .code-content {
        padding: 0.8rem;
    }

    .code-content pre {
        font-size: 0.7rem;
    }

    .developer-image {
        height: 180px;
    }

    .section-header {
        margin-bottom: 3rem;
    }

    .section-title {
        font-size: 1.4rem;
        letter-spacing: 0.5px;
    }

    .about-text p {
        margin-bottom: 1.2rem;
        font-size: 0.95rem;
    }

    .avatar-container {
        width: 180px;
        height: 180px;
    }

    .avatar-placeholder {
        font-size: 4rem;
    }

    .social-icon {
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }

    .footer {
        padding: 2rem 0 1.5rem;
    }

    .footer-text {
        min-width: 200px;
    }

    .footer-social {
        min-width: 120px;
    }
}

/* Small Mobile (below 320px) */
@media (max-width: 319px) {
    html {
        font-size: 13px;
    }

    .hero-name {
        font-size: 1.8rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .btn-primary,
    .btn-secondary {
        padding: 0.7rem 1.2rem;
        font-size: 0.85rem;
    }

    .illustration-container {
        height: 200px;
    }

    .code-window {
        width: 160px;
    }

    .developer-image {
        height: 160px;
    }

    .avatar-container {
        width: 150px;
        height: 150px;
    }

    .social-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}

/* Touch device optimizations */
@media (hover: none) and (pointer: coarse) {

    .nav-link:hover::before,
    .btn-primary:hover::before,
    .social-icon:hover::before {
        animation: none;
    }

    .nav-link:active,
    .btn-primary:active,
    .btn-secondary:active,
    .social-icon:active {
        transform: scale(0.95);
    }

    .cta-button:active {
        transform: scale(0.95);
    }
}

/* Reduced motion preferences */
@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }

    .hero-illustration::before,
    .avatar-image,
    .orbit,
    .cursor,
    .type-text,
    .stars {
        animation: none !important;
    }
}

/* Fix for iOS Safari 100vh issue */
@supports (-webkit-touch-callout: none) {
    .hero {
        min-height: -webkit-fill-available;
    }
}