/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(to right, #fdfcfb, #e2d1c3);
    color: #2c3e50;
    transition: background 0.3s ease, color 0.3s ease;
    line-height: 1.6;
}

body.dark-mode {
    background: #121212;
    color: #e0e0e0;
}

/* Dark Mode Adjustments */
body.dark-mode nav,
body.dark-mode .footer {
    background: #1f1f1f;
}

body.dark-mode .section-title,
body.dark-mode .project-title {
    color: #f1f1f1;
}

body.dark-mode .skill-item,
body.dark-mode .portfolio-item,
body.dark-mode .education-card {
    background: #1e1e1e;
    box-shadow: 0 6px 12px rgba(255, 255, 255, 0.05);
}

body.dark-mode .portfolio-content {
    background: #252525;
}

body.dark-mode .project-link {
    background: #ff9800;
    color: #121212;
}

body.dark-mode .project-description,
body.dark-mode .project-tech {
    color: #ccc;
}

body.dark-mode .about-text,
body.dark-mode .year {
    color: #ddd;
}

a {
    color: #e67e22;
    text-decoration: none;
    transition: all 0.3s ease;
}

a:hover {
    text-decoration: underline;
    color: #d35400;
}

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

/* Theme Toggle */
.theme-toggle {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #ff9800;
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    z-index: 100;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease;
}

.theme-toggle:hover {
    transform: scale(1.1);
}

.theme-toggle i {
    transition: transform 0.3s ease;
}

body.dark-mode .theme-toggle {
    background: #e0e0e0;
    color: #121212;
}

/* Navigation */
nav {
    background-color: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
    transition: all 0.3s ease;
}

body.dark-mode nav {
    background: #1f1f1f;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    position: relative;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    color: #ff9800;
    cursor: default;
    user-select: none;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.nav-links li a {
    font-weight: 600;
    color: #333;
    transition: color 0.3s ease;
    font-size: 1rem;
}

body.dark-mode .nav-links li a {
    color: #e0e0e0;
}

.nav-links li a:hover,
.nav-links li a.active {
    color: #ff9800;
    text-decoration: none;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
    color: #ff9800;
    z-index: 110;
}

/* Hero Section */
.hero {
    padding: 6rem 0 8rem;
    text-align: center;
    background: linear-gradient(135deg, rgba(230, 126, 34, 0.1), rgba(241, 196, 15, 0.1));
}

.hero-title {
    font-size: 3rem;
    font-weight: 700;
    color: #ff9800;
    margin-bottom: 0.5rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.5rem;
    font-weight: 500;
    color: #666;
}

body.dark-mode .hero-subtitle {
    color: #aaa;
}

/* Section */
.section {
    padding: 5rem 0;
    position: relative;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #ff9800;
    margin-bottom: 3rem;
    text-align: center;
    position: relative;
    display: block;
    width: 100%;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: #ff9800;
    border-radius: 2px;
}

/* About Section */
.profile-photo {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    object-fit: cover;
    display: block;
    margin: 0 auto 2rem;
    border: 5px solid #ff9800;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.about-text {
    font-size: 1.15rem;
    font-weight: 400;
    max-width: 700px;
    margin: 0 auto;
    color: #444;
    line-height: 1.8;
}

/* Skills Grid */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 2rem;
    justify-items: center;
    margin-top: 3rem;
}

.skill-item {
    font-size: 3.5rem;
    color: #ff9800;
    transition: all 0.3s ease;
    cursor: default;
    user-select: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(255, 152, 0, 0.1);
}

.skill-item:hover {
    transform: scale(1.1);
    background: rgba(255, 152, 0, 0.2);
}

.skill-item::after {
    content: attr(title);
    position: absolute;
    bottom: -30px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.8rem;
    color: #333;
    font-weight: 500;
    opacity: 0;
    transition: opacity 0.3s ease;
}

body.dark-mode .skill-item::after {
    color: #eee;
}

.skill-item:hover::after {
    opacity: 1;
}

/* Education Card */
.education-card {
    background: #fff;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    max-width: 500px;
    margin: 0 auto;
    transition: all 0.3s ease;
}

body.dark-mode .education-card {
    background: #1e1e1e;
}

.education-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.15);
}

.school-name {
    font-size: 1.5rem;
    font-weight: 700;
    color: #ff9800;
    margin-bottom: 0.5rem;
}

.year {
    font-size: 1.15rem;
    font-weight: 500;
    color: #666;
}

/* Portfolio Grid */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.portfolio-item {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

body.dark-mode .portfolio-item {
    background: #1e1e1e;
}

.portfolio-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.portfolio-img-container {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.portfolio-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.portfolio-item:hover .portfolio-img {
    transform: scale(1.05);
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.project-link {
    padding: 10px 20px;
    background: white;
    color: #e67e22;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.project-link:hover {
    background: white;
    color: #d35400;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.portfolio-content {
    padding: 20px;
}

body.dark-mode .portfolio-content {
    background: #252525;
}

.project-title {
    font-size: 1.3rem;
    color: #2c3e50;
    margin-bottom: 10px;
}

body.dark-mode .project-title {
    color: #f1f1f1;
}

.project-description {
    color: #666;
    margin-bottom: 15px;
    font-size: 0.95rem;
}

body.dark-mode .project-description {
    color: #ccc;
}

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

.project-tech span {
    background: #f5f5f5;
    color: #e67e22;
    padding: 5px 10px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 500;
}

body.dark-mode .project-tech span {
    background: #333;
}

/* Contact Section */
.contact-info {
    max-width: 500px;
    margin: 0 auto;
    text-align: center;
    font-size: 1.1rem;
}

.contact-item {
    margin: 1.2rem 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2c3e50;
}

body.dark-mode .contact-item {
    color: #e0e0e0;
}

.contact-item i {
    margin-right: 1rem;
    color: #ff9800;
    font-size: 1.3rem;
    width: 30px;
}

.contact-item a {
    transition: all 0.3s ease;
}

.contact-item a:hover {
    color: #e67e22;
    text-decoration: none;
}

/* Footer */
.footer {
    background: #ff9800;
    text-align: center;
    padding: 2rem 0;
    color: #fff;
    font-weight: 600;
    margin-top: 3rem;
}

.copyright {
    font-size: 1rem;
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .portfolio-img-container {
        height: 300px;
    }
}

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

    .hamburger {
        display: block;
    }

    nav.active .nav-links {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 70px;
        right: 20px;
        background: #fff;
        border-radius: 8px;
        padding: 1.5rem;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
        width: 200px;
    }

    body.dark-mode nav.active .nav-links {
        background: #1e1e1e;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }

    .section {
        padding: 3rem 0;
    }

    .section-title {
        font-size: 2rem;
        margin-bottom: 2rem;
    }

    .portfolio-img-container {
        height: 250px;
    }

    .portfolio-content {
        padding: 1.5rem;
    }
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 2rem;
    }

    .profile-photo {
        width: 160px;
        height: 160px;
    }

    .skills-grid {
        grid-template-columns: repeat(auto-fit, minmax(70px, 1fr));
        gap: 1.5rem;
    }

    .skill-item {
        font-size: 3rem;
        width: 70px;
        height: 70px;
    }

    .portfolio-img-container {
        height: 200px;
    }

    .project-title {
        font-size: 1.3rem;
    }

    .project-description {
        font-size: 0.9rem;
    }
}