/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    transition: background-color 0.3s, color 0.3s;
}

:root {
    /* Dark Theme Variables (Default) */
    --primary-color: #64ffda;
    --secondary-color: #8892b0;
    --bg-color: #0a192f;
    --bg-secondary: #112240;
    --text-color: #ccd6f6;
    --text-secondary: #8892b0;
    --nav-bg: rgba(10, 25, 47, 0.95);
    --card-bg: #112240;
    --card-hover-shadow: rgba(100, 255, 218, 0.1);
    --accent-color: #64ffda;
    --button-hover: #53d3b5;
}

/* Light Theme Variables */
[data-theme="light"] {
    --primary-color: #2563eb;
    --secondary-color: #4b5563;
    --bg-color: #f8fafc;
    --bg-secondary: #f1f5f9;
    --text-color: #1e293b;
    --text-secondary: #475569;
    --nav-bg: rgba(248, 250, 252, 0.95);
    --card-bg: #ffffff;
    --card-hover-shadow: rgba(37, 99, 235, 0.1);
    --accent-color: #2563eb;
    --button-hover: #1d4ed8;
}

/* Update specific light mode styles */
[data-theme="light"] .skill-item {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .skill-item:hover {
    border-color: var(--accent-color);
    box-shadow: 0 8px 16px rgba(37, 99, 235, 0.1);
}

[data-theme="light"] .project-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .project-card:hover {
    border-color: var(--accent-color);
    box-shadow: 0 8px 16px rgba(37, 99, 235, 0.1);
}

[data-theme="light"] .nav-links a:hover {
    background: #e8f0fe;
}

[data-theme="light"] .theme-toggle {
    background: #f8fafc;
    border-color: var(--accent-color);
}

[data-theme="light"] .theme-toggle:hover {
    background: #e8f0fe;
}

[data-theme="light"] input,
[data-theme="light"] textarea {
    background: #ffffff;
    border: 1px solid #e2e8f0;
}

[data-theme="light"] input:focus,
[data-theme="light"] textarea:focus {
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

[data-theme="light"] .project-tech span {
    background: #e8f0fe;
    color: var(--accent-color);
    border: none;
}

[data-theme="light"] .cta-button {
    background: transparent;
    border: 2px solid var(--accent-color);
    color: var(--accent-color);
}

[data-theme="light"] .cta-button:hover {
    background: var(--accent-color);
    color: #ffffff;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
    overflow-x: hidden;
}

/* Theme Toggle Button */
.theme-toggle {
    background: none;
    border: none;
    color: var(--accent-color);
    cursor: pointer;
    font-size: 1.2rem;
    padding: 8px;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border: 1px solid var(--accent-color);
    opacity: 0.9;
}

.theme-toggle:hover {
    background: var(--card-hover-shadow);
    opacity: 1;
    transform: translateY(-2px);
}

/* Particles Background */
#particles-js {
    position: fixed;
    width: 100%;
    height: 100%;
    background-color: var(--bg-color);
    z-index: -1;
    opacity: 0.7;
}

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

/* Navigation */
header {
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    background: var(--nav-bg);
    backdrop-filter: blur(10px);
}

nav {
    padding: 20px 0;
}

nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

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

.nav-links a {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s ease;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 5px 10px;
    border-radius: 4px;
}

.nav-links a:hover {
    color: var(--accent-color);
    background: var(--bg-secondary);
}

.logo {
    font-size: 24px;
    font-weight: 700;
    color: var(--accent-color);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    text-align: center;
    color: var(--text-color);
    padding-top: 120px;
    padding-bottom: 60px;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 25px;
    width: 100%;
}

.profile-image {
    margin-bottom: 15px;
    margin-top: 15px;
    position: relative;
    display: inline-block;
    z-index: 1;
    animation: float 6s ease-in-out infinite;
}

.image-container {
    width: 220px;
    height: 220px;
    border-radius: 50%;
    overflow: hidden;
    position: relative;
    margin: 0 auto;
    background: var(--bg-color);
    padding: 5px;
    z-index: 2;
}

.image-container::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, var(--accent-color), transparent, var(--accent-color));
    border-radius: 50%;
    z-index: 1;
    animation: rotate 4s linear infinite;
    box-shadow: 0 0 15px var(--accent-color);
}

.image-container::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--bg-color);
    border-radius: 50%;
    z-index: 1;
    margin: 2px;
}

#profile-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    position: relative;
    z-index: 2;
    display: block;
    transition: transform 0.3s ease;
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

@keyframes float {
    0% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
    100% {
        transform: translateY(0px);
    }
}

.image-container:hover #profile-img {
    transform: scale(1.1);
}

/* Responsive adjustments for profile image */
@media (max-width: 768px) {
    .image-container {
        width: 180px;
        height: 180px;
    }
}

@media (max-width: 480px) {
    .image-container {
        width: 150px;
        height: 150px;
    }
}

/* Update hero content spacing */
.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 2px;
}

.hero-content h2 {
    font-size: 2rem;
    color: var(--accent-color);
    margin-bottom: 2px;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: var(--text-secondary);
}

/* Sections */
section {
    padding: 100px 0;
    color: var(--text-color);
}

section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 50px;
}

/* About Section */
.about-content {
    display: flex;
    justify-content: center;
    gap: 50px;
}

.about-text {
    max-width: 600px;
    text-align: center;
}

/* Projects Section */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.project-card {
    background: var(--card-bg);
    border: 1px solid var(--bg-secondary);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    padding: 30px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

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

.project-content p {
    color: var(--text-secondary);
    margin-bottom: 20px;
    line-height: 1.6;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 15px;
}

.project-tech span {
    background: var(--bg-secondary);
    color: var(--accent-color);
    border: 1px solid var(--accent-color);
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.9rem;
}

/* Skills Section */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.skill-item {
    background: var(--card-bg);
    border: 1px solid var(--bg-secondary);
    padding: 30px 20px;
    border-radius: 10px;
    transition: all 0.3s ease;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.skill-item:hover {
    border-color: var(--accent-color);
    transform: translateY(-5px);
    box-shadow: 0 5px 15px var(--card-hover-shadow);
}

.skill-item i {
    font-size: 2.5rem;
    color: var(--accent-color);
    margin-bottom: 15px;
    transition: transform 0.3s ease;
}

.skill-item:hover i {
    transform: scale(1.1);
}

.skill-item h3 {
    font-size: 1.1rem;
    color: var(--text-color);
    margin-top: 10px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
        padding: 15px;
    }
}

@media (max-width: 480px) {
    .skills-grid {
        grid-template-columns: 1fr;
        padding: 10px;
    }
}

/* Contact Section */
.contact-content {
    max-width: 600px;
    margin: 0 auto;
}

form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

input, textarea {
    background: var(--bg-secondary);
    color: var(--text-color);
    border: 1px solid var(--text-secondary);
    border-radius: 4px;
    padding: 12px;
}

input::placeholder, textarea::placeholder {
    color: var(--text-secondary);
}

input:focus, textarea:focus {
    border-color: var(--accent-color);
    outline: none;
    box-shadow: 0 0 0 2px var(--card-hover-shadow);
}

.cta-button {
    display: inline-block;
    padding: 12px 28px;
    background: transparent;
    color: var(--accent-color);
    border: 2px solid var(--accent-color);
    border-radius: 4px;
    font-weight: 600;
    transition: all 0.3s ease;
    text-decoration: none;
    cursor: pointer;
}

.cta-button:hover {
    background: var(--accent-color);
    color: var(--bg-color);
    transform: translateY(-2px);
}

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

.social-links a {
    color: var(--text-color);
    font-size: 1.5rem;
    transition: color 0.3s ease;
}

.social-links a:hover {
    color: var(--accent-color);
}

/* Footer */
footer {
    background: var(--nav-bg);
    padding: 20px 0;
    text-align: center;
    color: var(--text-color);
}

/* Notification Styles */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 25px;
    border-radius: 5px;
    color: white;
    font-weight: 500;
    z-index: 1000;
    animation: slideIn 0.3s ease-out;
}

.notification.success {
    background-color: var(--accent-color);
}

.notification.error {
    background-color: #dc3545;
}

.notification.fade-out {
    animation: slideOut 0.3s ease-in forwards;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Loading spinner styles */
.fa-spinner {
    margin-right: 8px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-right {
        gap: 10px;
    }

    .nav-links {
        gap: 15px;
        margin-right: 5px;
    }

    .nav-links a {
        font-size: 0.9rem;
        padding: 5px 8px;
    }

    .theme-toggle {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }

    .nav-links {
        display: none;
    }
    
    .hero {
        padding-top: 100px;
    }
    
    .image-container {
        width: 180px;
        height: 180px;
    }
    
    .profile-image {
        margin-bottom: 25px;
        margin-top: 25px;
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .hero-content h2 {
        font-size: 1.5rem;
    }
    
    section {
        padding: 60px 0;
    }
    
    .about-content {
        flex-direction: column;
        text-align: center;
    }
    
    .project-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .nav-links {
        display: none;
    }
}

@media (max-width: 480px) {
    .hero {
        padding-top: 80px;
    }
    
    .image-container {
        width: 150px;
        height: 150px;
    }
    
    .profile-image {
        margin-bottom: 20px;
        margin-top: 20px;
    }
}
