:root {
    /* Colors */
    --bg-color: #0a0a0a;
    --text-color: #e0e0e0;
    --accent-color: #00f2ff;
    /* Neon Cyan */
    --secondary-color: #7000ff;
    /* Neon Purple */
    --card-bg: #1a1a1a;
    --nav-bg: rgba(10, 10, 10, 0.9);

    /* Fonts */
    --font-main: 'Inter', sans-serif;
    --font-heading: 'Playfair Display', serif;

    /* Spacing */
    --section-padding: 100px 0;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: var(--section-padding);
}

/* Header & Nav */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--nav-bg);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 20px 0;
    transition: padding 0.3s ease;
}

.header.scrolled {
    padding: 15px 0;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.5);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--accent-color);
    text-decoration: none;
}

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-link {
    font-size: 1rem;
    font-weight: 500;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.hamburger {
    display: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    background-color: var(--text-color);
    transition: all 0.3s ease;
}

/* Footer */
.footer {
    background-color: #050505;
    padding: 50px 0 20px;
    border-top: 1px solid #222;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.footer-logo h2 {
    font-family: var(--font-heading);
    color: var(--accent-color);
}

.footer-socials {
    display: flex;
    gap: 20px;
}

.footer-socials a {
    font-size: 1.5rem;
    color: var(--text-color);
}

.footer-socials a:hover {
    color: var(--accent-color);
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    font-size: 0.9rem;
    color: #888;
    border-top: 1px solid #1a1a1a;
    padding-top: 20px;
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    background: radial-gradient(circle at 10% 20%, rgba(112, 0, 255, 0.2) 0%, rgba(10, 10, 10, 1) 40%),
        radial-gradient(circle at 90% 80%, rgba(0, 242, 255, 0.15) 0%, rgba(10, 10, 10, 1) 40%);
}

.hero::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: url('../images/noise.png');
    /* We can omit if no noise image, or use CSS noise */
    opacity: 0.05;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 10;
    max-width: 800px;
    opacity: 0;
    transform: translateY(30px);
    animation: fadeUp 1s ease forwards 0.5s;
}

.hero-title {
    font-family: var(--font-heading);
    font-size: 5rem;
    line-height: 1.1;
    margin-bottom: 20px;
    letter-spacing: -2px;
}

.hero-title .highlight {
    background: linear-gradient(135deg, var(--accent-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    position: relative;
    display: inline-block;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: #aaa;
    margin-bottom: 40px;
    font-weight: 300;
}

.btn {
    display: inline-block;
    padding: 15px 40px;
    border-radius: 50px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-primary {
    background: transparent;
    color: var(--text-color);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, var(--secondary-color), var(--accent-color));
    transition: width 0.4s ease;
    z-index: -1;
}

.btn-primary:hover::before {
    width: 100%;
}

/* About Section */
.about {
    background-color: #0f0f0f;
}

.section-title {
    font-family: var(--font-heading);
    font-size: 3rem;
    margin-bottom: 60px;
    text-align: center;
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: var(--accent-color);
    border-radius: 2px;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-text .lead {
    font-size: 1.2rem;
    color: var(--accent-color);
    margin-bottom: 20px;
    font-weight: 500;
}

.about-text p {
    color: #ccc;
    margin-bottom: 20px;
    font-size: 1.05rem;
}

.stats {
    display: flex;
    gap: 40px;
    margin-top: 40px;
}

.stat-item h3 {
    font-size: 2.5rem;
    color: var(--secondary-color);
    font-family: var(--font-heading);
    line-height: 1;
}

.stat-item p {
    font-size: 0.9rem;
    color: #888;
    margin-top: 5px;
}

.skills-container {
    background: var(--card-bg);
    padding: 40px;
    border-radius: 20px;
    border: 1px solid #333;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.skills-container h3 {
    margin-bottom: 30px;
    font-size: 1.5rem;
}

.skills-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.skill-tag {
    background: rgba(255, 255, 255, 0.05);
    padding: 10px 20px;
    border-radius: 30px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    cursor: default;
    border: 1px solid transparent;
}

.skill-tag:hover {
    background: rgba(0, 242, 255, 0.1);
    color: var(--accent-color);
    border-color: var(--accent-color);
    transform: translateY(-3px);
}

/* Projects Section */
.projects {
    background-color: var(--bg-color);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.project-card {
    background-color: var(--card-bg);
    border-radius: 15px;
    overflow: hidden;
    border: 1px solid #222;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    /* group: project-card; Removed invalid property */
}

.hero-title .highlight {
    background: linear-gradient(135deg, var(--accent-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    position: relative;
    display: inline-block;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    border-color: var(--accent-color);
}

.project-image {
    height: 200px;
    position: relative;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #111;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.project-card:hover .project-image img {
    transform: scale(1.1);
}

.project-image img.img-contain {
    object-fit: contain;
    background-color: #222;
    /* Optional: lighter background for contained images */
}

.img-placeholder {
    width: 100%;
    height: 100%;
}

.project-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.project-card:hover .project-overlay {
    opacity: 1;
}

.btn-icon {
    width: 50px;
    height: 50px;
    background: #fff;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #000;
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.btn-icon:hover {
    transform: scale(1.1);
    color: var(--secondary-color);
}

.project-info {
    padding: 25px;
}

.project-info h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #fff;
}

.project-info p {
    font-size: 0.95rem;
    color: #aaa;
    margin-bottom: 20px;
    line-height: 1.6;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.project-tags span {
    font-size: 0.8rem;
    color: var(--accent-color);
    background: rgba(0, 242, 255, 0.1);
    padding: 5px 15px;
    border-radius: 20px;
}

/* Contact Section */
.contact {
    background-color: #0c0c0c;
    position: relative;
    overflow: hidden;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 60px;
    margin-top: 50px;
}

.contact-info h3 {
    font-size: 2rem;
    color: var(--text-color);
    margin-bottom: 20px;
}

.contact-info p {
    color: #888;
    margin-bottom: 40px;
    font-size: 1.05rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    font-size: 1.1rem;
}

.contact-item i {
    color: var(--accent-color);
    font-size: 1.2rem;
}

.contact-form {
    background: var(--card-bg);
    padding: 40px;
    border-radius: 20px;
    border: 1px solid #222;
}

.form-group {
    position: relative;
    margin-bottom: 30px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 15px 0;
    font-size: 1rem;
    color: var(--text-color);
    background: transparent;
    border: none;
    border-bottom: 1px solid #444;
    outline: none;
    transition: border-color 0.3s ease;
    font-family: var(--font-main);
}

.form-group textarea {
    resize: vertical;
    max-height: 200px;
    min-height: 100px;
}

.form-group label {
    position: absolute;
    top: 15px;
    left: 0;
    font-size: 1rem;
    color: #888;
    pointer-events: none;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group input:valid,
.form-group textarea:valid {
    border-bottom-color: var(--accent-color);

    .hero-subtitle {
        font-size: 1.2rem;
    }
}

/* Custom Validation Styles */
.form-group {
    position: relative;
    margin-bottom: 30px;
}

.form-group.error input,
.form-group.error textarea {
    border-bottom-color: #ff3333;
}

.form-group.error label {
    color: #ff3333;
}

.error-message {
    position: absolute;
    bottom: -20px;
    left: 0;
    color: #ff3333;
    font-size: 0.8rem;
    opacity: 0;
    transform: translateY(-5px);
    transition: all 0.3s ease;
    pointer-events: none;
}

.form-group.error .error-message {
    opacity: 1;
    transform: translateY(0);
}

.form-group input:focus~label,
.form-group textarea:focus~label,
.form-group input:valid~label,
.form-group textarea:valid~label {
    top: -10px;
    font-size: 0.85rem;
    color: var(--accent-color);
}

/* Responsive Contact */
@media (max-width: 900px) {
    .contact-content {
        grid-template-columns: 1fr;
    }
}

/* Responsive Hero */
@media (max-width: 768px) {
    .hero-title {
        font-size: 3rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }
}