/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

/* Light Theme Variables */
:root {
    --bg-color: #ffffff;
    --text-color: #222;
    --accent-color: #007bff;
    --card-bg: #f5f5f5;
}

/* Dark Theme Variables */
body.dark {
    --bg-color: #121212;
    --text-color: #f5f5f5;
    --accent-color: #00bcd4;
    --card-bg: #1e1e1e;
}

/* Global Styles */
body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    transition: background 0.3s, color 0.3s;
}

h1 { font-size: clamp(1.8rem, 5vw, 3rem); }
p { font-size: clamp(0.9rem, 3vw, 1.1rem); }
/* Header */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 50px;
    background: var(--card-bg);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
}
.logo span {
    color: var(--accent-color);
}

nav ul {
    display: flex;
    gap: 20px;
}
nav a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
}
nav a:hover{
    color: var(--accent-color);
}

.theme-btn {
    background: none;
    border: none;
    color: var(--text-color);
    font-size: 1.3rem;
    cursor: pointer;
}

/* Sections */
section {
    padding: 60px 20%;
    text-align: center;
}

img.profile-pic {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  object-fit: cover;
}

@media (max-width: 768px) {
  img.profile-pic {
    width: 100px;
    height: 100px;
  }
}


.profile-pic {
    width: 150px;
    height: 150px;
    border-radius: 50%; /* makes it circular */
    object-fit: cover;  /* ensures the image fits nicely */
    border: 4px solid var(--accent-color);
    margin-bottom: 20px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.profile-pic:hover {
    transform: scale(1.05);
    box-shadow: 0 0 20px var(--accent-color);
}

.hero {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background: linear-gradient(to right, var(--accent-color), transparent);
}
.hero h1 span {
    color: var(--accent-color);
}
.hero .btn {
    display: inline-block;
    margin-top: 20px;
    background: var(--accent-color);
    color: white;
    padding: 10px 20px;
    border-radius: 30px;
    text-decoration: none;
}

/* About */
.about p {
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.8;
}

h2 {
    margin-bottom: 20px;
    color: var(--accent-color);
}

/* Skills */
.skill-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
}
.skill {
    background: var(--card-bg);
    padding: 10px 20px;
    border-radius: 25px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.568);
}

/* Projects */
.projects {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

.project-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 25px;
}
.project-card {
    background: var(--card-bg);
    padding: 25px;
    border-radius: 20px;
    width: 300px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.364);
}
.project-card h3 {
    color: var(--accent-color);
    margin-bottom: 10px;
}
.project-card p {
    margin-bottom: 15px;
}
.project-card .btn {
    text-decoration: none;
    color: white;
    background: var(--accent-color);
    padding: 8px 16px;
    border-radius: 20px;
}

/* Contact */
.contact {
    text-align: center;
    padding: 50px 20px;
}

.contact-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
}

.contact-links a {
    font-size: 2rem;
    color: var(--text-color);
    cursor: pointer;
    transition: color 0.3s ease, transform 0.3s ease, text-shadow 0.3s ease;
}

.contact-links a:hover {
    transform: scale(1.2);
    animation: glow 1s ease-in-out infinite alternate;
}

/* Brand-specific hover colors */
.contact-links a.email:hover {
    color: #d44638; /* Gmail red */
}
.contact-links a.github:hover {
    color: #333333; /* GitHub black */
}
.contact-links a.linkedin:hover {
    color: #0077b5; /* LinkedIn blue */
}

/* Dark mode brand hover */
body.dark .contact-links a.email:hover {
    color: #d44638;
}
body.dark .contact-links a.github:hover {
    color: #333333;
}
body.dark .contact-links a.linkedin:hover {
    color: #0077b5;
}

/* Glow animation */
@keyframes glow {
    from { text-shadow: 0 0 10px currentColor; }
    to { text-shadow: 0 0 20px currentColor; }
}

.contact-form {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}
.contact-form input,
.contact-form textarea {
    width: 80%;
    max-width: 500px;
    padding: 12px;
    border: 1px solid var(--accent-color);
    border-radius: 8px;
    background: var(--card-bg);
    color: var(--text-color);
    font-size: 1rem;
    transition: all 0.3s ease;
}
.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    box-shadow: 0 0 5px var(--accent-color);
}

.contact-form .btn {
    border: none;
    cursor: pointer;
    font-weight: 600;
    color: white;
    background: var(--accent-color);
    padding: 5px 10px;
    border-radius: 30px;
}
.contact-form .btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px var(--accent-color);
}

/* Fade-in Animation */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s ease-out, transform 1s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Footer */
footer {
    text-align: center;
    padding: 20px;
    background: var(--card-bg);
    color: var(--text-color);
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 10px;
    }
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
    }
    .hero {
        flex-direction: column;
        text-align: center;
    }
}
