/* 
    THEME: The Neural Shadow
    AUTHOR: Saran K
*/

:root {
    --bg-color: #050505;
    --neon-pink: #FF007F;
    --neon-violet: #7F00FF;
    --text-white: #FFFFFF;
    --text-grey: #AAAAAA;
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Inter', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

/* --- Particles Background --- */
#particles-js {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: -1;
    opacity: 0.6;
}

/* --- Mouse Glow --- */
#cursor-glow {
    position: fixed;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(127, 0, 255, 0.15), transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    transform: translate(-50%, -50%);
    z-index: 9999;
    transition: transform 0.1s ease-out;
    mix-blend-mode: screen;
}

/* --- Typography & Layout --- */
h1,
h2,
h3 {
    font-family: var(--font-heading);
    font-weight: 800;
    text-transform: uppercase;
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 100px 0;
    position: relative;
}

/* --- Navigation --- */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 50px;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 100;
    background: rgba(5, 5, 5, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 2px;
}

.dot {
    color: var(--neon-pink);
}

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

.nav-links a {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--text-grey);
}

.nav-links a:hover {
    color: var(--neon-pink);
    text-shadow: 0 0 10px var(--neon-pink);
}

/* --- Hero Section --- */
#hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 10%;
    overflow: hidden;
}

.hero-content {
    flex: 1;
    z-index: 2;
}

.glitch-text {
    font-size: 5rem;
    line-height: 1;
    background: linear-gradient(90deg, var(--neon-pink), var(--neon-violet));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    position: relative;
    margin-bottom: 20px;
}

/* Terminal Typing Effect */
.terminal-wrapper {
    font-family: var(--font-mono);
    font-size: 1.2rem;
    color: var(--neon-violet);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
}

.terminal-prompt {
    margin-right: 10px;
    color: var(--neon-pink);
}

.cursor {
    animation: blink 1s infinite;
    color: var(--neon-pink);
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

.hero-sub {
    color: var(--text-grey);
    font-size: 1.2rem;
    margin-bottom: 40px;
    max-width: 500px;
}

/* Buttons */
.cta-group {
    display: flex;
    gap: 20px;
}

.btn {
    padding: 12px 30px;
    font-family: var(--font-mono);
    font-weight: 700;
    text-transform: uppercase;
    border-radius: 2px;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: 0.3s;
}

.btn-primary {
    background: var(--neon-violet);
    color: white;
    box-shadow: 0 0 20px rgba(127, 0, 255, 0.4);
    border: none;
}

.btn-primary:hover {
    background: var(--neon-pink);
    box-shadow: 0 0 30px rgba(255, 0, 127, 0.6);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--neon-pink);
    color: var(--neon-pink);
}

.btn-outline:hover {
    background: rgba(255, 0, 127, 0.1);
    box-shadow: 0 0 15px rgba(255, 0, 127, 0.3);
}

/* Hero Image */
.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
    position: relative;
    z-index: 2;
}

.img-container {
    position: relative;
    width: 350px;
    height: 450px;
}

.img-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%) contrast(1.2) brightness(0.8);
    position: relative;
    z-index: 2;
    border-radius: 4px;
    transition: 0.5s;
}

.img-container:hover img {
    filter: grayscale(0%) contrast(1.1);
}

.glow-ring {
    position: absolute;
    top: -20px;
    left: -20px;
    width: 100%;
    height: 100%;
    border: 2px solid var(--neon-violet);
    z-index: 1;
    box-shadow: 0 0 30px var(--neon-violet);
    animation: float 6s ease-in-out infinite;
}

@keyframes float {

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

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

/* --- Section Titles --- */
.section-title {
    font-size: 8rem;
    color: rgba(255, 255, 255, 0.03);
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
    z-index: 0;
    pointer-events: none;
}

/* --- About Section --- */
#about .container {
    position: relative;
    z-index: 2;
}

.about-text {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.about-text h3 {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.highlight {
    color: var(--neon-pink);
}

.about-text p {
    font-size: 1.1rem;
    color: var(--text-grey);
    margin-bottom: 20px;
}

.degree {
    font-family: var(--font-mono);
    color: var(--neon-violet) !important;
}

/* --- Skills Section --- */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    margin-top: 50px;
    position: relative;
    z-index: 2;
}

.skill-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 20px;
    text-align: center;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    transition: 0.3s;
    cursor: default;
    position: relative;
    overflow: hidden;
}

.skill-card:hover {
    border-color: var(--neon-pink);
    box-shadow: 0 0 15px rgba(255, 0, 127, 0.3);
    transform: translateY(-5px);
    color: var(--neon-pink);
}

.skill-card::before {
    content: attr(data-glitch);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-color);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: 0.1s;
    z-index: 2;
    color: var(--neon-violet);
    transform: translateX(-10px);
}

.skill-card:hover::before {
    opacity: 0.5;
    animation: glitch-anim 0.3s infinite linear alternate-reverse;
}

@keyframes glitch-anim {
    0% {
        clip-path: inset(10% 0 80% 0);
        transform: translate(-2px, 2px);
    }

    20% {
        clip-path: inset(80% 0 10% 0);
        transform: translate(2px, -2px);
    }

    40% {
        clip-path: inset(40% 0 50% 0);
        transform: translate(-2px, 2px);
    }

    60% {
        clip-path: inset(20% 0 60% 0);
        transform: translate(2px, -2px);
    }

    80% {
        clip-path: inset(60% 0 20% 0);
        transform: translate(-2px, 2px);
    }

    100% {
        clip-path: inset(10% 0 40% 0);
        transform: translate(2px, -2px);
    }
}

/* --- Projects Section --- */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
    position: relative;
    z-index: 2;
}

.project-card {
    background: rgba(10, 10, 10, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 30px;
    border-radius: 4px;
    transition: 0.4s;
    position: relative;
}

.project-card:hover {
    border-color: var(--neon-violet);
    box-shadow: 0 0 20px rgba(127, 0, 255, 0.2);
    transform: translateY(-10px);
}

.project-card h3 {
    color: var(--text-white);
    margin-bottom: 15px;
    font-size: 1.5rem;
}

.project-card p {
    color: var(--text-grey);
    font-size: 0.95rem;
    margin-bottom: 20px;
}

.tech-stack {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.tech-stack span {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--neon-pink);
    background: rgba(255, 0, 127, 0.1);
    padding: 5px 10px;
    border-radius: 2px;
}

.btn-small {
    display: inline-block;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--text-white);
    border-bottom: 1px solid var(--neon-violet);
    padding-bottom: 2px;
}

.btn-small:hover {
    color: var(--neon-violet);
}

/* --- Contact Section --- */
.contact-container {
    text-align: center;
    position: relative;
    z-index: 2;
}

.contact-container p {
    font-size: 1.5rem;
    margin-bottom: 40px;
    color: var(--text-grey);
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 30px;
}

.social-btn {
    font-family: var(--font-mono);
    font-size: 1.2rem;
    color: var(--text-white);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 15px 30px;
    transition: 0.3s;
}

.social-btn:hover {
    background: var(--neon-pink);
    border-color: var(--neon-pink);
    box-shadow: 0 0 20px rgba(255, 0, 127, 0.5);
    transform: scale(1.05);
}

/* --- Footer --- */
footer {
    padding: 50px 0;
    text-align: center;
    background: black;
    position: relative;
    z-index: 2;
}

.footer-content p {
    color: var(--text-grey);
    font-family: var(--font-mono);
    font-size: 0.9rem;
    margin-bottom: 20px;
}

.footer-line {
    width: 100px;
    height: 2px;
    background: linear-gradient(90deg, var(--neon-pink), var(--neon-violet));
    margin: 0 auto;
}

/* --- Responsive Design --- */
@media (max-width: 768px) {
    #hero {
        flex-direction: column-reverse;
        justify-content: center;
        text-align: center;
        padding-top: 100px;
    }

    .hero-content {
        margin-top: 40px;
    }

    .glitch-text {
        font-size: 3rem;
    }

    .terminal-wrapper {
        justify-content: center;
    }

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

    .img-container {
        width: 280px;
        height: 350px;
    }

    .section-title {
        font-size: 4rem;
        top: 20px;
    }

    .nav-links {
        display: none;
        /* Simple hide for mobile for now, or could add hamburger */
    }

    nav {
        justify-content: center;
    }
}
