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

html {
    scroll-behavior: smooth;
}

body {
    display: flex;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    color: #333;
    background-color: #f5f5f5;
}

/* Sidebar */
.sidebar {
    padding: 2em;
    flex: 0 1 20%;
    align-self: flex-start;
    background-color: #1a1a1a;
    color: white;
    min-height: 100vh;
    position: sticky;
    top: 0;
    transition: transform 0.3s ease-in-out;
}

.sidebar-header h1 {
    font-size: 3em;
    margin-bottom: 0.2em;
}

.sidebar-header p {
    font-size: 1em;
    margin: 0 0 2em 0;
}

.sidebar-nav {
    overflow-y: scroll;
}

.sidebar-nav a {
    display: block;
    color: white;
    text-decoration: none;
    margin: 1em 0;
}

.sidebar-nav a:hover {
    color: #6495ED;
}

/*contact*/
.contact-list {
    list-style: none;
    padding-left: 0;
}

.contact-list li {
    margin-bottom: 0.5em;
}

.contact-list a {
    color: #777;
    text-decoration: none;
}

.contact-list a:hover {
    text-decoration: underline;
}

/* Main content */
.main-content {
    flex: 1;
    padding: 1.5em;
}

section {
    margin-bottom: 2.5em;
}

section h2 {
    margin-bottom: 0.5em;
    font-size: 1.7em;
}

.edu-item, 
.lang-item,
.exp-item,
.cert-item,
.proj-item {
    margin-bottom: 1em;
    padding: 1em;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.proj-item.upcoming {
    opacity: 0.7;
    font-style: italic;
}

.edu-item h3, 
.lang-item h3,
.exp-item h3,
.cert-item h3,
.proj-item h3{
    margin-bottom: 0.2em;
    font-size: 1.2em;
}

.edu-item h4,
.lang-item h4,
.exp-item h4,
.cert-item h4,
.proj-item h4{
    margin-bottom: 0.2em;
    font-style:italic;
    font-size: 1em;
    color: #555;
}

.edu-item p,
.lang-item p,
.exp-item p,
.cert-item p,
.proj-item p{
    margin-bottom: 0.2em;
    font-style: italic;
    font-size: 0.9em;
    color: #777;
}

/*links*/
.edu-item a,
.lang-item a,
.exp-item a,
.cert-item a,
.proj-item a{
    margin-top: 0.5em;
    padding: 0.3em 0.6em;
    display: inline-block;
    font-size: 0.8em;
    border: 1px solid #555;
    border-radius: 4px;
    text-decoration: none;
    color: #555;
}

.edu-item a:hover,
.lang-item a:hover,
.exp-item a:hover,
.cert-item a:hover,
.proj-item a:hover{
    background-color: #555;
    color: white;
}

/*lists*/
.exp-item ul,
.proj-item ul {
    padding: 1.2em 0 0 1.2em;
    list-style-type: disc;
    font-size: 0.9em;
}

.exp-item ul li,
.proj-item ul li {
    margin-bottom: 0.3em;
}

.cert-content,
.proj-content {
    display: flex;
    align-items: flex-start;
    gap: 1.5em;
}

.cert-text,
.proj-text {
    flex: 2;
}

.proj-image{
    flex: 1;
    padding-top: 1.2em;
}

.cert-image img{
    width: 100%;
    max-width: 180px;
    border-radius: 4px;
    box-shadow: 0 0 6px rgba(0,0,0,0.1);
    transition: transform 0.2s;
}

.proj-image img {
    width: 100%;    
    max-width: 420px;
    min-width: 200px;
    border-radius: 4px;
    box-shadow: 0 0 6px rgba(0,0,0,0.1);
    transition: transform 0.2s;
}

.cert-image img:hover,
.proj-image img:hover {
    transform: scale(1.05);
}

.hamburger {
    display: none;
}

.hamburger svg{
    display: block;
}

@media (max-width: 850px) {
    .cert-content,
    .proj-content {
        flex-direction: column;
    }

    .cert-image img,
    .proj-image img {
        width: 100%;
        max-width: 100%;
        min-width: auto;
        margin-top: 0.5em;
    }

    .sidebar {
        padding-top: 4em;
        position: fixed;
        transform: translateX(-100%);
        z-index: 1000; /* above content, below hamburger */
    }

    .sidebar.active {
        transform: translateX(0);
    }

    .main-content {
        flex: 1 1 100%;
        padding: 5em 1em 1em 1em;
    }

    .hamburger {
        display: block;
        position: fixed;
        top: 1em;
        left: 1em;
        z-index: 1100; /* above sidebar */
        background: #555;
        border-radius: 4px;
        border: none;
    }
}