/* ===== GLOBAL STYLES ===== */
:root {
    /* Color variables for easy theming */
    --primary-color: #04517e;       /* Main blue color */
    --secondary-color: #2c3e50;     /* Dark blue for headings */
    --text-color: #333;             /* Default text color */
    --light-color: #f5f5f5;         /* Light gray for backgrounds */
    --dark-color: #343a40;          /* Dark gray */
}

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

/* Base body styling */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #0c6eb8;
}

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

/* Typography */
h1, h2, h3, h4 {
    margin-bottom: 1rem;
    color: var(--secondary-color);
}

p {
    margin-bottom: 1rem;
}

/* Link styling */
a {
    text-decoration: none;
    color: var(--primary-color);
    transition: color 0.3s;
}

a:hover {
    color: #2980b9;
}

/* ===== HEADER STYLES ===== */
header {
    background: var(--secondary-color);
    color: #fff;
    padding: 15px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Logo styling */
.logo h1 {
    font-size: 1.5rem;
    margin: 0;
}

.logo p {
    font-size: 0.9rem;
    margin: 0;
    opacity: 0.8;
}

/* Mobile menu toggle (hidden on desktop) */

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #fff;
    font-size: 1.5rem;
    cursor: pointer;
    }

/* Navigation styling */
nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin-left: 20px;
}

nav ul li a {
    color: #fff;
    padding: 5px 0;
    position: relative;
}

/* Animated underline effect */
nav ul li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--primary-color);
    transition: width 0.3s;
}

nav ul li a:hover::after,
nav ul li a.active::after {
    width: 100%;
}

/* ===== HERO SECTION ===== */
#hero {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: #fff;
    text-align: center;
    padding: 150px 0 100px;
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

#hero .container {
    max-width: 800px;
}

#hero h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    color: #fff;
}

#hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* Button styles */
.btn {
    display: inline-block;
    background: var(--primary-color);
    color: #fff;
    padding: 12px 25px;
    border-radius: 5px;
    font-weight: 500;
    transition: all 0.3s;
    border: 2px solid transparent;
}

.btn:hover {
    background: transparent;
    border-color: #fff;
    color: #fff;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.btn-outline {
    background: transparent;
    border: 2px solid #fff;
    margin-left: 15px;
}

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

/* ===== SECTION STYLES ===== */
.section {
    padding: 80px 0;
    background: #fff;
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
    position: relative;
}

/* Section title underline effect */
.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--primary-color);
    margin: 15px auto 0;
}

/* ===== ABOUT SECTION ===== */
.about-content {
    display: flex;
    align-items: center;
    gap: 40px;
}

.about-text {
    flex: 1;
}

.profile-img {
    width: 250px;
    height: 250px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid var(--primary-color);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

/* ===== SKILLS SECTION ===== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.skill-category {
    background: var(--light-color);
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s;
}
.skill-category .fa-html5 { color: #E34F26; }
.skill-category .fa-css3-alt { color: #1572B6; }
.skill-category .fa-js-square { color: #F7DF1E; }
.skill-category .fa-react { color: #61DAFB; }
.skill-category .fa-python { color: #3776AB; }
.skill-category .fa-node { color: #339933; }

.skill-category:hover {
    transform: translateY(-5px);
}

.skill-category h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.skill-category ul {
    list-style: none;
}

.skill-category li {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
}

.skill-category i {
    margin-right: 10px;
    color: var(--primary-color);
}

/* ===== PROJECTS SECTION ===== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.project-card {
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s;
    background: #fff;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.project-img {
    height: 200px;
    background: #eee;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
}

.project-content {
    padding: 20px;
}

.project-content h3 {
    margin-bottom: 10px;
    color: var(--secondary-color);
}

.project-content p {
    margin-bottom: 15px;
    font-size: 0.95rem;
}

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

.tech-tag {
    background: var(--light-color);
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    color: var(--secondary-color);
}

.project-links {
    display: flex;
    gap: 10px;
}

/* ===== CV SECTION ===== */
#cv {
    background: var(--light-color);
}


/* Download CV Button */
.download-cv {
    margin: 15px 0;
    text-align: center;
    width: 100%; 
}

.download-btn {
    display: inline-block;
    padding: 10px 20px;
    background-color: #4CAF50;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background-color 0.3s;
    justify-content: center;
    text-align: center;
}

.download-btn:hover {
    background-color: #45a049;
}

.download-btn i {
    justify-content: center;
    text-align: center;
}

.project-item {
    margin-bottom: 20px;
}

.project-item h4 {
    margin-bottom: 5px;
}

.project-item a {
    word-break: break-all;
}

/* ===== LEARNING SECTION ===== */
.learning-items {
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
}

.learning-item {
    text-align: center;
    font-size: 2rem;
    color: var(--primary-color);
    transition: transform 0.3s;
}

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

.learning-item p {
    font-size: 1rem;
    margin-top: 10px;
    color: var(--secondary-color);
}

/* ===== CONTACT SECTION ===== */
.contact-methods {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.contact-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary-color);
    padding: 10px 20px;
    border: 2px solid var(--primary-color);
    border-radius: 5px;
    transition: all 0.3s;
}

.contact-link:hover {
    background: var(--primary-color);
    color: #fff;
    transform: translateY(-3px);
}

/* ===== FOOTER ===== */
footer {
    background: var(--secondary-color);
    color: #fff;
    text-align: center;
    padding: 20px 0;
}

footer p {
    margin: 5px 0;
    opacity: 0.8;
    font-size: 0.9rem;
}

/* ===== BACK TO TOP BUTTON ===== */
.back-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 999;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.back-to-top.active {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: #2980b9;
    transform: translateY(-3px);
}

/* ===== RESPONSIVE STYLES ===== */
@media (max-width: 992px) {
    /* Stack about section content on tablets */
    .about-content {
        flex-direction: column;
        text-align: center;
    }
    
    .profile-img {
        margin-bottom: 30px;
    }
}

@media (max-width: 768px) {
    /* Mobile menu styles */
    header .container {
        flex-direction: column;
        text-align: center;
    }
    
    .logo {
        margin-bottom: 15px;
    }
    
    .menu-toggle {
        display: block;
        position: absolute;
        top: 20px;
        right: 20px;
    }
    
    nav {
        width: 100%;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s;
    }
    
    nav.active {
        max-height: 500px;
        margin-top: 15px;
    }
    
    nav ul {
        flex-direction: column;
        align-items: center;
    }
    
    nav ul li {
        margin: 10px 0;
    }
    
    /* Adjust hero text size */
    #hero h2 {
        font-size: 2rem;
    }
    
    #hero p {
        font-size: 1rem;
    }
    
    /* Stack buttons vertically on mobile */
    .btn-container {
        display: flex;
        flex-direction: column;
        gap: 15px;
    }
    
    .btn-outline {
        margin-left: 0;
    }
    
    /* Adjust section padding */
    .section {
        padding: 60px 0;
    }
    
    /* Make profile image smaller */
    .profile-img {
        width: 200px;
        height: 200px;
    }
}

@media (max-width: 576px) {
    /* Further adjustments for small screens */
    .container {
        width: 95%;
    }
    
    #hero h2 {
        font-size: 1.8rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    /* Stack contact info vertically */
    .cv-contact {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
}