:root {
    --bg-main: #121315;   
    --bg-main-header:#121315d9;  

    --bg-card: #1a1b1e;         
    --bg-tag: #22242a;          
    --text-primary: #e4e5e7;    
    --text-muted: #9a9b9e;      
    --border-subtle: #2b2d33;   
    --border-accent: #3b3d45;  
    --accent-blue: #7EA1C4;
    --accent-blue-hover: #98B8DB;
    --bg-btn-hover: #2a2c34;
    --border-btn-hover: var(--text-muted);

    --border-radius-card: 16px;
    --border-radius-tag: 12px;
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
}

body.light-mode {
    --bg-main: #f8f9fa;
    --bg-main-header:#f8f9fad9;  

    --bg-card: #ffffff;
    --bg-tag: #e9ecef;
    --text-primary: #1a1b1e;
    --text-muted: #6c757d;
    --border-subtle: #dee2e6;
    --border-accent: #ced4da;
    
    --bg-btn-hover: #e2e8f0;
    --border-btn-hover: var(--border-accent);
    
    --accent-blue: #7da5d3;
    --accent-blue-hover: #9bbbe2;
}


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

html {
    scroll-behavior: smooth;
    scroll-padding-top: 180px;
}

body {
    width: 100%;
    background-color: var(--bg-main);
    color: var(--text-primary);
    font-family: var(--font-main);
    line-height: 1.6;   
     position: relative;
}

html, body {
    max-width: 100%;
}

h2 {
    font-size: 1.85rem;
    line-height: 1.25;
    margin-bottom: 0.5rem;
}

h3 {
    margin-bottom: 0.5rem;
}


section {
    padding: 3rem 1rem;
    text-align: center;
}

.main-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background-color: var(--bg-main-header);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.menu-toggle-btn {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    width: 26px;
    height: 20px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    position: relative;
    z-index: 101;
}

.menu-toggle-btn span {
    width: 100%;
    height: 2px;
    background-color: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s ease;
    pointer-events: none;
}

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


.nav-links {
    display: none;
    position: absolute;
    top:100%;
    left: 0;
    width: 100%;
    background-color: var(--bg-main); 
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    padding: 1.5rem 0;
    border-bottom: 1px solid var(--border-subtle);
}

.nav-links.active {
    display: flex;
}

.nav-links a {
    text-decoration: none;   
    font-size: 1rem;
    color: var(--text-muted);
    transition: color 0.2s ease;
}

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


.hero-container {
    width: 90%;
    max-width: 1100px;
    margin: 0px auto;
    padding: 2rem 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    text-align: center;
}

.hero-info {
    width: 100%;
}

.hero-container h1 {
    font-size: 2.5rem;
    margin-bottom: 0.25rem;
}

.hero-container h3 {
    color: var(--accent-blue);
    font-weight: 500;
}

.hero-container p {
    color: var(--text-muted);
}

.hero-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 1.5rem;
    gap: 0.5rem;
}

.hero-img {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
    margin-bottom: -2rem;
}

.hero-img img {
    width: 220px;
    height: 220px;
    object-fit: cover;
    object-position: top center;
    border-radius: 50%;
    border: 1px solid var(--border-subtle);
    flex-shrink: 0;
}


.btn, .location-tag, .project-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.6rem 1rem;
    background-color: var(--bg-tag);
    color: var(--text-primary);
    border: 1px solid var(--border-subtle);
    border-radius: var(--border-radius-tag);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    line-height: 1;
    transition: all 0.2s ease;
}

.project-card {
    display: flex;
    flex-direction: column;
}

.project-link {
    background-color: var(--accent-blue);
    color: #121315;
    border: 1px solid transparent;
    font-weight: 600;
    align-self: flex-start;
    margin-top: 0;
}

.project-link:hover {
    background-color: var(--accent-blue-hover);
    border-color: transparent;
    transition: all 0.2s ease;
}

.section-badge {
    display: inline-block;
    align-items: center;
    justify-content: center;
    padding: 0.3rem 0.5rem;
    background-color: transparent;
    color: var(--accent-blue);
    border: 1px solid var(--border-subtle);
    border-color: rgba(126, 161, 196, 0.3);
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1;
    cursor: default;
}

.location-tag {
    cursor: default;
    color: var(--text-muted);
}

.location-icon {
     display: block;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    background-color: var(--text-muted);
    mask: url('../icons/location.svg') no-repeat center;
    -webkit-mask: url('../icons/location.svg') no-repeat center;
    mask-size: contain;
}

.github-icon {
    display: block;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    background-color: var(--text-primary);
    mask: url('../icons/github.svg') no-repeat center;
    -webkit-mask: url('../icons/github.svg') no-repeat center;
    mask-size: contain;
}

.linkedIn-icon {
    display: block;
    width: 14px;
    height: 14px;
    flex-shrink: 0;
    background-color: var(--text-primary);
    mask: url('../icons/linkedIn.svg') no-repeat center;
    -webkit-mask: url('../icons/linkedIn.svg') no-repeat center;
    mask-size: contain;
}

.mail-icon {
       display: block;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    background-color: var(--text-primary);
    mask: url('../icons/mail.svg') no-repeat center;
     -webkit-mask: url('../icons/mail.svg') no-repeat center;
    mask-size: contain;
}

.btn:hover {
    border-color: var(--border-btn-hover);
    background-color: var(--bg-btn-hover);
    transition: all 0.2s ease;
}


.about-grid, .project-grid, .contact-container {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr;
    text-align: left;
    gap: 1.5rem;
}

.about-container, .project-card, .contact-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-subtle);
    padding: 1.25rem;
    border-radius: var(--border-radius-card);
    width: 100%;
}

.about-container h3:not(:first-child) {
    margin-top: 2rem;
}

.contact-card {
    display: flex;
    flex-direction: column;
}

.contact-card h3 {
    color: var(--text-primary);
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}


.about-card p, .contact-card p {
     color: var(--text-muted);
     margin-bottom: 1.5rem;
}


.project-card p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    flex-grow: 1;
   
}

.project-card .tag-list {
    margin-top: auto;
    margin-bottom: 1.5rem;

}

.skill-category {
    background-color: transparent;
    border: 1px solid var(--border-subtle);
    border-radius: var(--border-radius-card);
    padding: 1.25rem;
    margin-bottom: 1rem; 
}

.skill-category h4 {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--text-muted);
    margin-bottom: 1rem;
    font-weight: 600;
}

.skill-category:hover, .education-card:hover, .work-card:hover, .project-card:hover {
    border-color: var(--text-muted);
    transition: all 0.2s ease;
}

.tag-list {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag-list li {
    background-color: var(--bg-tag);
    color: var(--text-primary);
    border: 1px solid var(--border-subtle);
    padding: 0.35rem 0.85rem;
    border-radius: var(--border-radius-tag);
    font-size: 0.85rem;
    font-weight: 500;
}



.education-wrapper h3 {
    margin-bottom: 1.25rem;
}

.education-card, .work-card {
    background-color: transparent;
    border: 1px solid var(--border-subtle);
    border-radius: var(--border-radius-card);
    padding: 1.25rem;
    margin-bottom: 1.25rem;
}


.education-card:last-child,
.work-card:last-child {
    margin-bottom: 0;
}

.education-card h4, .work-card h4 {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-weight: 600;
}


.education-title, .work-desc {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem; 
    line-height: 1.5;  
}

.education-desc {
    font-size: 0.95rem;
     color: var(--text-muted);
    margin-bottom: 1rem; 
    line-height: 1.5;
}

.work-item {
    margin-bottom: 1rem;
}

.work-item:last-child {
    margin-bottom: 0;
}

.education-card:hover .education-title,
.work-card:hover .work-desc {
    color: var(--accent-blue);
    transition: color 0.2s ease;
}

.project-image-card {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: var(--border-radius-tag);
    overflow: hidden;
    background-color: var(--bg-tag);
    margin-bottom: 1.5rem;
}

.project-image-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    display: block;
}


.form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 1.25rem;
    text-align: left;
}

.info-container {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background-color: transparent;
    border: 1px solid var(--border-subtle);
    border-radius: var(--border-radius-card);
    padding: 0.85rem 0.75rem;
    margin-bottom: 1.25rem;
    color: var(--text-primary);
    text-decoration: none;
    transition: 0.2s ease;
    font-size: 0.85rem;

    max-width: 100%;
    min-width: 0;
    overflow-wrap: anywhere;
}

.info-container span, 
.info-container p {
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.info-container:hover {
    border-color: var(--text-muted);
}

.info-container:hover .mail-icon {
    background-color: var(--accent-blue);
    transition: background-color 0.2s ease;
}

.contact-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 1.5rem;
    gap: 0.5rem;
}


.form-group label {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.contact-form input {
    width: 100%;
    background-color: var(--bg-tag);
    border: 1px solid var(--border-subtle);
    border-radius: var(--border-radius-tag);
    padding: 0.75rem 1rem;
    color: var(--text-primary);
    font-family: inherit;
    font-size: 0.95rem;
    outline: none;
    transition: border-color 0.2s ease;
}

.contact-form textarea {
     width: 100%;
    background-color: var(--bg-tag);
    border: 1px solid var(--border-subtle);
    border-radius: var(--border-radius-tag);
    padding: 0.75rem 1rem;
    color: var(--text-primary);
    font-family: inherit;
    font-size: 0.95rem;
    outline: none;
    transition: border-color 0.2s ease;

    resize: vertical;
    min-height: 120px;

}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: var(--accent-blue);
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: var(--text-muted);
    opacity: 0.7;
}

.contact-form .btn {
    background-color: var(--accent-blue);
    color: #121315;
    border: none;
    font-weight: 600;
    width: 100%;
    padding: 0.75rem;
    cursor: pointer;
    margin-top: 0.5rem;
}

.contact-form .btn:hover {
    background-color: var(--accent-blue-hover);
}

.error-message {
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
    margin-top: 1rem;
    text-align: left;

}

.success-message {
    color: var(--accent-blue);
    font-size: 0.9rem;
    font-weight: 500;
    margin-top: 1rem;
    text-align: center;
}


footer {
    text-align: center;
    padding: 3rem 0;
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* Tablet */
@media screen and (min-width: 768px) {
    html {
        scroll-padding-top: 60px;
    }

    h2 {
    font-size: 2.25rem;
    margin-bottom: 10px;
}

    .menu-toggle-btn {
        display: none;
    }

    .nav-container {
        justify-content: center;
        padding: 0; 
        width: 100%;
        max-width: 1100px;
        margin: 0 auto;
    }

    .nav-links {
        display: flex;
        position: static;
        flex-direction: row;
        justify-content: center;
        border-bottom: none;
        width: 100%;
        padding: 1.5rem 0;
        gap: 2rem;

        background-color: transparent; 
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .hero-container {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        gap: 2rem;
        padding: 4rem 0;
        text-align: left;
        width: 85%;
        max-width: 800px;
    }

    .hero-info {
        flex: 1;
        max-width: none;
    }

    .hero-img img {
        width: 280px;
        height: 280px;
    }

    .hero-links {
        justify-content: flex-start;
    }

    .about-grid, .project-grid, .contact-container  {
        width: 85%;
        max-width: 800px;
    }

    .skills-wrapper {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }

    
}

/* Desktop */
@media screen and (min-width: 1024px) {

    .hero-container {
        justify-content: center;
        gap: 4rem;
    }

    .hero-container h1 {
        font-size: 3.75rem;
        line-height: 1.1;
        margin-bottom: 0.5rem;
        white-space: nowrap;
    }

    .hero-container h3 {
        font-size: 1.35rem;
    }

    .hero-container p {
        font-size: 1.05rem;
    }

    .hero-info {
        flex: 0 1 auto;
        max-width: 500px;
    }

    .hero-img img {
        width: 320px;
        height: 320px;
    }

    .about-grid, .project-grid, .contact-container  {
        width: 100%;
        max-width: 1100px;
    }

    .about-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .project-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .contact-container {
        grid-template-columns: repeat(2, 1fr);

    }
}