/* ── content.css ─────────────────────────────────────────────────────────── */

:root {
    --profile-width: 375px;
    --content-min-width: 550px;
    --nav-bar-height: 3rem;
    --margin-right: 2rem;
    --margin-left: var(--margin-right);
    --page-break: 1040px;
    box-sizing: content-box;
}

html {
    scroll-padding-top: var(--nav-bar-height);
}

* {
    margin: 0;
    padding: 0;
}

body {
    background-color: #181818;
    color: #ffffff;
    font-size: 1rem;
    font-family: "Noto Sans", serif;
    font-optical-sizing: auto;
    font-weight: 350;
    font-style: normal;
}

/* ── Profile sidebar ─────────────────────────────────────────────────────── */
/* Sidebar sits below the nav bar (which is now full-width) */
#contact {
    top: var(--nav-bar-height);
    /* push below the full-width nav */
}

/* ── Right section: main area ────────────────────────────────────────────── */
#main {
    flex-direction: column;
    background-color: #181818;
    margin-left: calc(var(--profile-width) + var(--margin-left));
    min-width: var(--content-min-width);
    line-height: 1.4rem;
    padding-right: var(--margin-right);
    position: relative;
}

#main p {
    padding-top: 1rem;
    color: #aaa;
}

#main p.no-top {
    padding-top: initial;
}

#main .bold {
    font-weight: bold;
}

#main #content {
    padding-left: 2rem;
    padding-top: var(--nav-bar-height);
    animation: fadeUp 0.4s 0.05s ease both;
}

#main #content h1 {
    color: #ffffff;
    font-size: 1.6rem;
    margin-bottom: 1rem;
}

#main #content h2 {
    margin-bottom: .8rem;
}

#main #content table {
    width: 100%;
}

#work-experience table:not(:last-child),
#projects table:not(:last-child) {
    margin-bottom: 1rem;
}

#main ul li {
    margin: 1rem 0;
}

#main .aligned-list {
    list-style-position: inside;
    margin: 0;
    padding: 0;
}

#main .aligned-list li {
    padding-left: 1.5rem;
    text-indent: -1.5rem;
}

#main .section {
    scroll-margin-top: 2rem;
    margin-top: 2rem;
}

#main .right {
    text-align: right;
}

#main h1,
#main h2,
#main h3,
#main h4 {
    font-family: "Lexend", sans-serif;
    font-optical-sizing: auto;
}

#main a {
    color: #ffffff;
    text-decoration: underline;
}

#main h3 {
    font-weight: normal;
}

.project-image {
    border-radius: 6px;
    border: 1px solid #181818;
}

.project-image:not(:last-child) {
    margin-bottom: 1rem;
}

.project-description {
    padding-top: 1rem;
}

.project-images {
    display: flex;
    flex-wrap: nowrap;
    flex-direction: column;
    margin-left: 1.5rem;
}

#accomplishments {
    display: block;
    margin-top: 1em;
    margin-bottom: 1em;
    margin-left: 0;
    margin-right: 0;
}

#accomplishments dt {
    margin-top: 1rem;
}

#accomplishments dd {
    display: block;
    margin-left: 40px;
}

/* ── Back to top ─────────────────────────────────────────────────────────── */
#back-to-top {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: #202020;
    border: 1px solid #303030;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #555555;
    font-size: 14px;
    text-decoration: none;
    cursor: pointer;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s, border-color 0.15s, color 0.15s, background-color 0.15s;
    z-index: 199;
}

.fancybox__container {
    z-index: 10003 !important; /* Navbar is 10001, so this ensures the lightbox appears above it */
}

#back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
}

#back-to-top:hover {
    border-color: #505050;
    color: #ffffff;
    background-color: #2a2a2a;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
    .project-image {
        max-width: 90%;
    }
}

@media (min-width: 768px) and (max-width: 1032px) {
    .project-image {
        max-width: 90%;
    }
}

@media (min-width: 992px) and (max-width: 1200px) {
    .project-image {
        max-width: 55%;
    }
}

@media (min-width: 1200px) {
    .project-image {
        max-width: min(70%, 800px);
    }
}

@media (max-width: 1040px) {
    #main {
        width: 100%;
        margin-left: 0;
    }

    #welcome {
        margin-top: 0 !important;
    }

    #main #content {
        padding: 0;
    }
}