html {
    scroll-behavior: smooth;
}

/* Technologies used in each project */
.tech-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    list-style: none;
    padding: 0;
    margin-top: 1rem;
    margin-bottom: 0;
}

.tech-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.3rem 0.8rem 0.3rem 0.6rem;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    color: #cfe0e3;
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1;
}

.tech-chip img {
    width: 20px;
    height: 20px;
}

body {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
    background: linear-gradient(#19464A, #162124);
    background-repeat: no-repeat;
    background-attachment: fixed;
}

.container {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding-left: 50px;
    padding-right: 50px;
}

.navbar {
    display: flex;
    justify-content: center;
    align-items: center;
}

.nav-link {
    display: inline-block;
    color: #f4bf06;
    font-family: Verdana, Geneva, Tahoma, sans-serif;
    position: relative;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #f4bf06;
}

.nav-link::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0.25rem;
    width: 0;
    height: 2px;
    background-color: currentColor;
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
    color: #f4bf06;
}

.navbar-collapse {
    justify-content: center;
}

.navbar-nav {
    align-items: center;
    justify-content: center;
    width: 100%;
}

.navbar-toggler {
    margin-right: auto;
    color: #f4bf06;
    border: 1px solid #f4bf06;
    border-radius: 10px;
    padding: 10px 14px;
    font-size: 1.3rem;
}

.navbar-toggler:focus {
    outline: none;
    box-shadow: none;
}

.lang-switch {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.3rem 0.45rem 0.3rem 0.75rem;
    background: transparent;
    color: #f4bf06;
    border: 1px solid #f4bf06;
    border-radius: 999px;
    font-family: Verdana, Geneva, Tahoma, sans-serif;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    cursor: pointer;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.lang-switch:hover {
    background-color: rgba(244, 191, 6, 0.12);
}

.lang-switch:focus {
    outline: none;
}

.lang-switch:focus-visible {
    box-shadow: 0 0 0 3px #f4bf06;
}

/* Desktop: 3-column grid so the menu is centered regardless of the switch width */
@media (min-width: 768px) {
    .navbar {
        display: grid;
        grid-template-columns: 1fr auto 1fr;
    }

    .navbar-collapse {
        grid-column: 2;
        grid-row: 1;
    }

    .lang-switch {
        grid-column: 3;
        grid-row: 1;
        justify-self: end;
    }
}

.lang-opt {
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    opacity: 0.65;
    transition: background-color 0.3s ease, color 0.3s ease, opacity 0.3s ease;
}

.lang-opt.active {
    background-color: #f4bf06;
    color: #194549;
    opacity: 1;
}

.img {
    width: 220px;
    max-width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 50%;
}

.txt {
    color: #d7e8eb;
}

.ed-title {
    margin: 0 0 0.75rem;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #8fa3a8;
}

.common-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 2rem;
    color: #cfe0e3;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    margin-top: 0.75rem;
    margin-bottom: 0.75rem;
}

.common-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 16px 24px rgba(0, 0, 0, 0.2);
}

ul.work-details li {
    margin-bottom: 0.5rem;
}

.facts {
    list-style: none;
    margin: 0;
    padding: 0;
}

.fact {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.fact i {
    width: 1rem;
    text-align: center;
    color: #f4bf06;
}

.fact p {
    margin: 0;
    overflow-wrap: anywhere;
}

.timeline {
    position: relative;
    list-style: none;
    margin: 0;
    padding: 0 0 0 2rem;
}

.timeline::before {
    content: "";
    position: absolute;
    left: 0.5rem;
    top: 0;
    bottom: 0;
    width: 2px;
    background: rgba(255, 255, 255, 0.15);
    background-color: #f4bf06;
}

.timeline-item {
    position: relative;
    padding-bottom: 1rem;
}

.timeline-item::before {
    content: "";
    position: absolute;
    left: -1.85rem;
    top: 0.3rem;
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 50%;
    margin-top: 0.5rem;
    background: rgba(255, 255, 255, 0.3);
    background-color: #f4bf06;
}

.timeline-role {
    padding-top: 0.4rem;
}

.timeline-role {
    padding-top: 0.4rem;
    font-weight: 700;
}

.timeline-company {
    color: #CFE0E3;
}

a.timeline-company {
    display: inline-block;
    color: #85ccc3;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.3s ease;
}

a.timeline-company:hover,
a.timeline-company:focus-visible {
    color: #f4bf06;
}

a.timeline-company i {
    margin-left: 0.35rem;
    font-size: 0.5em;
    opacity: 0.7;
}

.timeline-date {
    margin: 0.25rem 0 0;
    font-size: 0.85rem;
    color: #8fa3a8;
}

.timeline-date i {
    margin-right: 0.4rem;
}

.btn {
    color: #f4bf06;
    margin: 0.5rem;
    padding: 0.5rem 1rem;
    border: 1px solid #f4bf06;
    border-radius: 10px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
}

/* Zoom effect on project images */
.zoom {
    position: relative;
    z-index: 2;
    cursor: zoom-in;
    transition: transform 0.2s ease;
}

.zoom:hover {
    transform: scale(1.03);
}

/* Lightbox overlay */
#lightbox {
    display: none;
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;

    justify-content: center;
    align-items: center;

    cursor: zoom-out;
    padding: 20px;
}

/* Show lightbox */
#lightbox.open {
    display: flex;
}

/* Enlarged image */
#lightbox-img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    cursor: default;
    border-radius: 5px;
}

/* Close button */
#lightbox-close {
    position: absolute;
    top: 20px;
    right: 35px;

    background: transparent;
    border: none;
    color: white;

    font-size: 45px;
    cursor: pointer;
    line-height: 1;
}

#lightbox-close:hover {
    color: #ccc;
}

/* Back to top button */
#back-to-top {
    position: fixed;
    right: 1.5rem;
    bottom: 1.5rem;
    z-index: 1000;
    width: 3rem;
    height: 3rem;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #f4bf06;
    color: #162124;
    border: none;
    border-radius: 50%;
    font-size: 1.1rem;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease, background-color 0.3s ease;
}

#back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

#back-to-top:hover {
    background-color: #ffd23f;
}

#back-to-top:focus {
    outline: none;
}

#back-to-top:focus-visible {
    box-shadow: 0 0 0 3px rgba(244, 191, 6, 0.45);
}

.skills-card {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    text-align: center;
    height: 100%;
    min-height: 7rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: #cfe0e3;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.skills-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 16px 24px rgba(0, 0, 0, 0.2);
}

.skill-icon {
    width: 100%;
    max-width: 50px;
    height: auto;
    line-height: 1;
    margin-bottom: 0.75rem;
}

.skill-name {
    margin: 0;
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1.2;
}

.skill-icon-fa {
    font-size: 2.8rem;
    line-height: 1;
    margin-bottom: 0.75rem;
    color: #7fd3c9;
}

footer {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 1.75rem 50px;

    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;

    box-sizing: border-box;
    color: #cfe0e3;
}

.footer-copyright p {
    margin: 0;
}

.footer-socials {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 15px;
}

.footer-icons {
    color: #cfe0e3;
    transition: color 0.3s ease;
}

.footer-icons:hover {
    color: #f4bf06;
}

.more-projects {
    display: inline-flex;
    align-items: center;
    gap: .6rem;
    color: inherit;
    text-decoration: none;
    font-size: 1.1rem;
    color: #cfe0e3;
}

.more-projects img {
    filter: invert(1);
}

.more-projects:hover {
    color: #85CCC3;
    text-decoration: none;
}

.more-projects span {
    transition: transform .2s;
}