* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #6366f1;
    --secondary-color: #8b5cf6;
    --accent-color: #ec4899;
    --dark-bg: #0a0a0f;
    --dark-card: #141420;
    --dark-card-hover: #1a1a2e;
    --text-primary: #ffffff;
    --text-secondary: #a0a0b8;
    --electric-border-color: #6366f1;
    --electric-light-color: #8b5cf6;
    --gradient-color: rgba(99, 102, 241, 0.4);
    --gradient-1: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #ec4899 100%);
    --gradient-2: linear-gradient(135deg, #ec4899 0%, #8b5cf6 50%, #6366f1 100%);
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background-color: var(--dark-bg);
    color: var(--text-primary);
    overflow-x: hidden;
    line-height: 1.6;
    cursor: none;
}

body.loaded {
    cursor: none;
}

/* Loading Screen */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--dark-bg);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-content {
    text-align: center;
}

.loader-logo {
    font-size: 4rem;
    font-weight: 900;
    font-family: 'Space Grotesk', sans-serif;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 2rem;
    animation: pulse-logo 2s ease-in-out infinite;
}

@keyframes pulse-logo {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

.loader-progress {
    width: 300px;
    height: 4px;
    background: rgba(99, 102, 241, 0.2);
    border-radius: 10px;
    overflow: hidden;
    margin: 0 auto 1rem;
}

.loader-bar {
    height: 100%;
    background: var(--gradient-1);
    border-radius: 10px;
    width: 0%;
    animation: loading 2s ease-in-out forwards;
}

@keyframes loading {
    0% {
        width: 0%;
    }
    100% {
        width: 100%;
    }
}

.loader-text {
    color: var(--text-secondary);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    animation: fade-in-out 1.5s ease-in-out infinite;
}

@keyframes fade-in-out {
    0%, 100% {
        opacity: 0.5;
    }
    50% {
        opacity: 1;
    }
}

/* Custom Cursor */
.cursor-follower {
    width: 20px;
    height: 20px;
    border: 2px solid var(--primary-color);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    transition: width 0.3s, height 0.3s, border-color 0.3s;
    mix-blend-mode: difference;
}

.cursor-follower.active {
    width: 60px;
    height: 60px;
    border-color: var(--accent-color);
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(10, 10, 15, 0.7);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1000;
    padding: 1.5rem 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-bottom: 1px solid rgba(99, 102, 241, 0.1);
}

.navbar.scrolled {
    background: rgba(10, 10, 15, 0.95);
    padding: 1rem 0;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 3rem;
}

.logo {
    position: relative;
    font-size: 1.8rem;
    font-weight: 900;
    font-family: 'Space Grotesk', sans-serif;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    z-index: 1;
}

.logo-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.4), transparent);
    border-radius: 50%;
    filter: blur(20px);
    z-index: -1;
    animation: pulse 3s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 1; transform: translate(-50%, -50%) scale(1.2); }
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 3rem;
    align-items: center;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
    transition: color 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.nav-link::before {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-1);
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-link:hover {
    color: var(--text-primary);
}

.nav-link:hover::before {
    width: 100%;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}

.nav-toggle span {
    width: 25px;
    height: 2px;
    background: var(--text-primary);
    transition: all 0.3s ease;
}

/* Hero Section */
.hero-container {
    position: relative;
    height: 100vh;
    overflow: hidden;
}

.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero__background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero__bg-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #0a0a0f 0%, #141420 50%, #1a1a2e 100%);
    opacity: 0.8;
}

.hero__particles {
    position: absolute;
    width: 100%;
    height: 100%;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--primary-color);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--primary-color);
    animation: float-particle 20s infinite ease-in-out;
}

.particle:nth-child(1) {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.particle:nth-child(2) {
    top: 60%;
    left: 80%;
    animation-delay: 2s;
}

.particle:nth-child(3) {
    top: 80%;
    left: 30%;
    animation-delay: 4s;
}

.particle:nth-child(4) {
    top: 40%;
    left: 60%;
    animation-delay: 6s;
}

.particle:nth-child(5) {
    top: 10%;
    left: 50%;
    animation-delay: 8s;
}

@keyframes float-particle {
    0%, 100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.3;
    }
    50% {
        transform: translate(100px, -100px) scale(1.5);
        opacity: 1;
    }
}

.hero__content {
    position: relative;
    z-index: 10;
    text-align: center;
    width: 100%;
    max-width: 1200px;
    padding: 0 2rem;
}

.hero__text {
    position: relative;
}

.hero__greeting {
    font-size: clamp(1rem, 2vw, 1.5rem);
    color: var(--text-secondary);
    margin-bottom: 1rem;
    font-weight: 300;
    letter-spacing: 3px;
    text-transform: uppercase;
}

.greeting-char {
    display: inline-block;
    will-change: transform, opacity;
}

.hero__title {
    font-size: clamp(3rem, 10vw, 10rem);
    font-weight: 900;
    font-family: 'Space Grotesk', sans-serif;
    line-height: 1.1;
    margin-bottom: 2rem;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.title-line {
    display: block;
    overflow: hidden;
}

.title-char {
    display: inline-block;
    will-change: transform, opacity;
    backface-visibility: hidden;
}

.hero__subtitle {
    font-size: clamp(1.2rem, 3vw, 2rem);
    color: var(--text-secondary);
    margin-bottom: 3rem;
    font-weight: 300;
    letter-spacing: 2px;
}

.subtitle-word {
    display: inline-block;
    margin-right: 0.5em;
    will-change: transform, opacity;
}

.hero__buttons {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    position: relative;
    padding: 1.2rem 2.5rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: none;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn span {
    position: relative;
    z-index: 2;
}

.btn-primary {
    background: var(--gradient-1);
    color: white;
    box-shadow: 0 10px 40px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 60px rgba(99, 102, 241, 0.5);
}

.btn-shine {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.btn-primary:hover .btn-shine {
    left: 100%;
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    transform: translateY(-5px);
    box-shadow: 0 20px 60px rgba(99, 102, 241, 0.3);
}

.hero__cover {
    --overlay-opacity: 1;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

.hero__cover-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(
        circle,
        rgba(0, 0, 0, 0) 20%,
        rgba(0, 0, 0, 0.8) 90%
    );
    opacity: var(--overlay-opacity);
    transition: opacity 0.3s ease;
    z-index: 2;
}

.hero__cover-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    will-change: transform;
}

.scroll-indicator {
    position: absolute;
    bottom: 3rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    color: var(--text-secondary);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.scroll-line {
    width: 2px;
    height: 40px;
    background: var(--gradient-1);
    animation: scroll-line 2s ease-in-out infinite;
}

@keyframes scroll-line {
    0%, 100% {
        transform: translateY(0);
        opacity: 0.3;
    }
    50% {
        transform: translateY(10px);
        opacity: 1;
    }
}

/* About Section */
.section-stick {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8rem 2rem;
}

.about-section {
    background: var(--dark-bg);
}

.about-container {
    max-width: 1200px;
    width: 100%;
}

.about-content {
    text-align: center;
}

.about-title {
    font-size: clamp(3rem, 8vw, 6rem);
    font-weight: 900;
    font-family: 'Space Grotesk', sans-serif;
    margin-bottom: 4rem;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.about-title .title-char {
    display: inline-block;
    will-change: transform, opacity;
}

.about-text-wrapper {
    max-width: 900px;
    margin: 0 auto;
}

.about-text {
    font-size: clamp(1.2rem, 3vw, 2rem);
    line-height: 1.8;
    color: var(--text-secondary);
    font-weight: 300;
}

.opacity-reveal .word {
    display: inline-block;
    margin-right: 0.3em;
    will-change: transform, opacity;
    backface-visibility: hidden;
    transform-style: preserve-3d;
}

/* About Image Section */
.about-image-section {
    position: relative;
    height: 100vh;
    overflow: hidden;
}

.image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(
        circle,
        rgba(0, 0, 0, 0) 40%,
        rgba(0, 0, 0, 0.8) 90%
    );
    z-index: 1;
}

.about-image-full {
    width: 100%;
    height: 100%;
    object-fit: cover;
    will-change: transform;
}

/* Projects Section */
.projects-section {
    padding: 8rem 0;
    background: rgba(20, 20, 32, 0.5);
    position: relative;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 3rem;
}

.section-title {
    font-size: clamp(3rem, 8vw, 6rem);
    font-weight: 900;
    font-family: 'Space Grotesk', sans-serif;
    text-align: center;
    margin-bottom: 5rem;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-title .title-char {
    display: inline-block;
    will-change: transform, opacity;
    backface-visibility: hidden;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 3rem;
}

/* Electric Border Cards */
.electric-card-container {
    padding: 2px;
    border-radius: 24px;
    position: relative;
    background: linear-gradient(
        -30deg,
        var(--gradient-color),
        transparent,
        var(--gradient-color)
    ),
    linear-gradient(
        to bottom,
        var(--dark-card),
        var(--dark-card)
    );
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.electric-inner-container {
    position: relative;
}

.electric-border-outer {
    border: 2px solid rgba(99, 102, 241, 0.5);
    border-radius: 24px;
    padding-right: 4px;
    padding-bottom: 4px;
}

.electric-main-card {
    width: 100%;
    min-height: 100%;
    border-radius: 24px;
    border: 2px solid var(--electric-border-color);
    margin-top: -4px;
    margin-left: -4px;
    filter: url(#turbulent-displace);
    background: var(--dark-card);
    overflow: hidden;
    position: relative;
    z-index: 1;
    transition: background 0.3s ease;
}

.electric-main-card:hover {
    background: var(--dark-card-hover);
}

.electric-glow-layer-1 {
    border: 2px solid rgba(99, 102, 241, 0.6);
    border-radius: 24px;
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    filter: blur(1px);
    pointer-events: none;
}

.electric-glow-layer-2 {
    border: 2px solid var(--electric-light-color);
    border-radius: 24px;
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    filter: blur(4px);
    pointer-events: none;
}

.electric-overlay-1 {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    border-radius: 24px;
    opacity: 1;
    mix-blend-mode: overlay;
    transform: scale(1.1);
    filter: blur(16px);
    background: linear-gradient(
        -30deg,
        white,
        transparent 30%,
        transparent 70%,
        white
    );
    pointer-events: none;
}

.electric-overlay-2 {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    border-radius: 24px;
    opacity: 0.5;
    mix-blend-mode: overlay;
    transform: scale(1.1);
    filter: blur(16px);
    background: linear-gradient(
        -30deg,
        white,
        transparent 30%,
        transparent 70%,
        white
    );
    pointer-events: none;
}

.electric-background-glow {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    border-radius: 24px;
    filter: blur(32px);
    transform: scale(1.1);
    opacity: 0.3;
    z-index: -1;
    background: linear-gradient(
        -30deg,
        var(--electric-light-color),
        transparent,
        var(--electric-border-color)
    );
    pointer-events: none;
}

.project-card {
    background: transparent;
    border: none;
    margin: 0;
    filter: none;
}

.project-image {
    width: 100%;
    height: 280px;
    overflow: hidden;
    position: relative;
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.7) 100%);
    z-index: 1;
    transition: opacity 0.3s ease;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-card-wrapper:hover .project-image img {
    transform: scale(1.15) rotate(2deg);
}

.project-info {
    padding: 2.5rem;
    position: relative;
}

.project-number {
    position: absolute;
    top: -20px;
    right: 2.5rem;
    font-size: 8rem;
    font-weight: 900;
    font-family: 'Space Grotesk', sans-serif;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    opacity: 0.1;
    line-height: 1;
}

.project-info h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-weight: 700;
}

.project-info p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.project-tags span {
    background: rgba(99, 102, 241, 0.15);
    color: var(--primary-color);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid rgba(99, 102, 241, 0.3);
    transition: all 0.3s ease;
}

.project-tags span:hover {
    background: rgba(99, 102, 241, 0.3);
    transform: translateY(-2px);
}

/* Skills Section */
.skills-section {
    padding: 8rem 0;
    background: var(--dark-bg);
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 3rem;
}

.skill-card {
    min-height: 300px;
}

.skill-card .electric-main-card {
    filter: url(#turbulent-displace-2);
    padding: 3rem 2rem;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: 300px;
}

.skill-item {
    background: transparent;
    padding: 0;
    border: none;
    width: 100%;
    height: 100%;
}

.skill-icon {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    filter: drop-shadow(0 0 20px rgba(99, 102, 241, 0.5));
    animation: float-icon 3s ease-in-out infinite;
}

@keyframes float-icon {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-10px) rotate(5deg);
    }
}

.skill-item h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
    font-weight: 700;
}

.skill-item p {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.6;
}

/* Contact Section */
.contact-section {
    padding: 8rem 0;
    background: rgba(20, 20, 32, 0.5);
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    align-items: start;
}

.contact-info h3 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-weight: 700;
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.contact-info p {
    color: var(--text-secondary);
    margin-bottom: 3rem;
    font-size: 1.1rem;
    line-height: 1.8;
}

.contact-links {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-link {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    color: var(--text-secondary);
    text-decoration: none;
    padding: 1.5rem;
    background: var(--dark-card);
    border-radius: 15px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(99, 102, 241, 0.1);
}

.contact-link:hover {
    background: var(--dark-card-hover);
    transform: translateX(10px);
    color: var(--text-primary);
    border-color: rgba(99, 102, 241, 0.5);
    box-shadow: 0 10px 30px rgba(99, 102, 241, 0.2);
}

.contact-icon {
    font-size: 2rem;
    filter: drop-shadow(0 0 10px rgba(99, 102, 241, 0.5));
}

.contact-form {
    background: var(--dark-card);
    padding: 3rem;
    border-radius: 20px;
    border: 1px solid rgba(99, 102, 241, 0.1);
}

.form-group {
    margin-bottom: 1.5rem;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 1.2rem;
    background: rgba(20, 20, 32, 0.5);
    border: 2px solid rgba(99, 102, 241, 0.2);
    border-radius: 10px;
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.3);
    background: rgba(20, 20, 32, 0.8);
}

.contact-form textarea {
    resize: vertical;
    min-height: 150px;
}

/* Footer */
.footer {
    text-align: center;
    padding: 3rem 0;
    background: var(--dark-bg);
    color: var(--text-secondary);
    border-top: 1px solid rgba(99, 102, 241, 0.1);
}

/* SVG Container */
.svg-container {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .hero__title {
        font-size: clamp(2.5rem, 12vw, 5rem);
    }
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .skills-grid {
        grid-template-columns: 1fr;
    }
    
    .about-text {
        font-size: 1.2rem;
    }
    
    body {
        cursor: auto;
    }
    
    .cursor-follower {
        display: none;
    }
}