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

:root {
    --primary: #3b82f6;
    --dark: #141a2d;
    --light: #f9fafb;

    /* Light Theme Variation */
    --body-bg: linear-gradient(135deg, #f0f2f5, #e4e7f0);
    --text-color: #111827;
}
html{
    scroll-behavior: smooth;
}

body.dark-mode {
    --body-bg: linear-gradient(135deg, #1f2937, #1a1a1a);
    --text-color: #e5ebf1;
}

body {
    margin: 0;
    font-family: 'Poppins', sans-serif;
    background: var(--body-bg);
    color: var(--text-color);
    transition: background 0.3s ease, color 0.3s ease;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    background: transparent;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
}

nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

nav a {
    text-decoration: none;
    color: inherit;
    font-weight: 500;
}

.theme-toggle {
    height: 30px;
    width: 32px;
    padding: 0.4rem 0.8rem;
    border: none;
    background: transparent;
    border-radius: 6px;
    color: var(--primary);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    background: var(--primary);
    color: white;
}
.theme-toggle i{
    transition: transform 0.4s ease;
}
body.dark-mode .theme-toggle i {
    transform: rotate(180deg); 
}

.fa-moon {
    margin-left: -0.5rem;
}

.hero {
    text-align: center;
    padding: 5rem 2rem 4rem;
    max-width: 700px;
    margin: auto;
}

.hero h1 {
    font-size: 2.8rem;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    color: #6b7280;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    align-items: center;
}

.btn {
    padding: 0.75rem 1.25rem;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn.primary {
    background: var(--primary);
    color: white;
}

.btn.primary:hover {
    background: #2563eb;
}

.btn.outline {
    border: 2px solid var(--primary);
    color: var(--primary);
    background: transparent;
}

.btn.outline:hover {
    background: var(--primary);
    color: white;
}

.fa-angle-double-down {
    margin-left: 0.2rem;
}

/* About setion */

.about-section {
    padding: 5rem 2rem;
}

.about-inner {
    max-width: 1100px;
    margin: auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 3rem;
}

.profile-card {
    flex: 1 1 250px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.profile-card img {
    width: 100%;
    max-width: 240px;
    height: auto;
    object-fit: cover;
    border-radius: 12px;
    border: 6px solid white;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    transition: transform 0.4s ease;
}

.profile-card img:hover {
    transform: scale(1.05);
}

.about-details {
    flex: 2 1 500px;
}

.about-details h2 {
    font-size: 2.2rem;
    margin-bottom: 1rem;
    color: var(--primary);
}

.about-details p {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--text-color);
    margin-bottom: 2rem;
}

.skills-list {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.skills-list span {
    background: #3b82f6;
    color: white;
    padding: 0.2rem 1rem;
    border-radius: 50px;
    font-size: 0.75rem;
    text-align: center;
    transition: background 0.3s;
}

.skills-list span:hover {
    background: #2563eb;
}

/* Project */
.projects-section {
    padding: 5rem 2rem;
    background: inherit;
}

.projects-container {
    max-width: 1140px;
    margin: auto;
}

.projects-container h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 2.5rem;
    color: var(--primary);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.project-card {
    background: var(--light);
    border-radius: 12px;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
}

.project-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.project-info {
    padding: 1.2rem;
    flex: 1;
}

.project-info h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--dark);
}

.project-info p {
    font-size: 0.95rem;
    color: var(--dark);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.project-tags span {
    background: var(--primary);
    color: white;
    font-size: 0.7rem;
    padding: 0.15rem 0.7rem;
    border-radius: 50px;
}

.project-links a {
    text-decoration: none;
    font-weight: 600;
    color: var(--primary);
    margin-right: 1rem;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.project-links a:hover {
    color: #1d4ed8;
    border-bottom: 2px solid var(--primary);
}

/* contact section */
.contact-section {
    padding: 5rem 2rem;
    max-width: 1100px;
    margin: auto;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    background: var(--light);
    border-radius: 12px;
    box-shadow: 0 4px 10px var(--shadow);
    padding: 3rem;
}

.contact-info h3,
.contact-form-wrapper h3 {
    color: var(--dark);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}


.contact-info p {
    font-size: 1rem;
    color: var(--dark);
    margin-bottom: 1.5rem;
}

.contact-socials {
    list-style: none;
    padding: 0;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.contact-socials li {
    margin-bottom: 0.8rem;
}

.contact-socials i {
    margin-right: 0.5rem;
}

.contact-socials a {
    color: var(--dark);
    text-decoration: none;
    font-weight: 600;
    display: inline-block;
    transition: color 0.3s;
}

nav a:hover,
.contact-socials a:hover {
    color: var(--primary);
}

form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}
label{
    font-size: 0.8rem;
    padding-left: 1rem;
    color: var(--dark);
}
input,
textarea {
    width: 100%;
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    background: var(--light);
    color: var(--dark);
    font-size: 1rem;
}

input:focus,
textarea:focus {
    border-color: var(--primary);
    outline: none;
}

.hidden {
    display: none;
}

.submit-btn {
    background: var(--primary);
    color: white;
    padding: 0.9rem 1.5rem;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.submit-btn:hover {
    background: #2563eb;
}

/* FOOTER */
.site-footer {
    text-align: center;
    color: var(--gray);
    font-size: 0.95rem;
    padding: 2rem 1rem;
    margin-top: 4rem;
}

/* Responsive Design (Media Query) */
@media screen and (max-width: 861px) {
    .about-details h2{
        text-align: center;
        font-size: 1.8rem;
    }
}
@media screen and (max-width: 640px) {
    header {
        flex-direction: column;
        gap: 0.8rem;
        padding: 1.5rem 1rem;
    }

    .logo {
        font-size: 1.3rem;
    }

    .hero {
        padding: 6rem 1rem;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .btn {
        padding: 0.5rem 0.8rem;
        font-size: 0.8rem;
    }

    .projects-grid,
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .contact-grid {
        padding: 1.5rem;
    }
    .contact-info h3,
    .contact-form-wrapper h3 {
        font-size: 1.3rem;
    }
}
@media screen and (max-width:499px) {
    .about-section,
    .projects-section,
    .contact-section{
        padding: 5rem 1rem;
    }
}
@media screen and (max-width: 320px){
    nav{
        gap: 0.5rem;
    }
    .btn{
        flex-grow: 1;
    }
}