#resume {
    container-type: size;
    container-name: resume;
    flex-direction: row;
    width: 100%;
    height: 100%;
    color: var(--light-background);

    & > header {
        display: flex;
        height: 100%;
        font-size: clamp(1rem, 3cqh, 3rem);

        &:has(h1.display-summary.visible) {
            background-color: var(--purpose-color);
        }
        &:has(h1.display-education.visible) {
            background-color: var(--curiosity-color);
        }
        &:has(h1.display-relevant-experience.visible) {
            background-color: var(--creativity-color);
        }
        &:has(h1.display-professional-experience.visible) {
            background-color: var(--empathy-color);
        }

        & > nav {
            & > ul {
                display: flex;
                flex-direction: column;
                justify-content: space-between;
                width: 100%;
                height: 100%;

                & li {
                    flex: 1;
                    display: flex;
                    justify-content: center;
                    align-items: center;
                    padding: 0 0.5em;
                    text-align: center;
                    letter-spacing: 0.15em;
                    writing-mode: vertical-rl;
                    text-shadow: -2px -2px 2px rgba(255, 255, 255, 0.1), 2px 2px 2px rgba(0, 0, 0, 0.5);
                    border: 2.5px solid var(--dark-background);
                    border-left: 2px solid var(--dark-background);
                    transform: rotate(180deg);
                    cursor: pointer;

                    &:last-of-type {
                        border-top: 5px solid var(--dark-background);
                    }

                    &.selected-tab {
                        text-shadow: none;
                        border: 2.5px solid var(--dark-background);
                        border-left: none;
                        cursor: revert;
                    }

                    &#summary-tab {
                        background-color: var(--purpose-color);
                        border-bottom: 2px solid var(--dark-background);

                        &:hover:not(li.selected-tab) {
                            font-weight: bold;
                            background-color: var(--purpose-accent);
                        }
                    }
                    &#education-tab {
                        background-color: var(--curiosity-color);

                        &:hover:not(li.selected-tab) {
                            font-weight: bold;
                            background-color: var(--curiosity-accent);
                        }
                    }
                    &#relevant-experience-tab {
                        background-color: var(--creativity-color);

                        &:hover:not(li.selected-tab) {
                            font-weight: bold;
                            background-color: var(--creativity-accent);
                        }
                    }
                    &#professional-experience-tab {
                        background-color: var(--empathy-color);
                        border-top: 2px solid var(--dark-background);

                        &:hover:not(li.selected-tab) {
                            font-weight: bold;
                            background-color: var(--empathy-accent);
                        }
                    }

                    & .tab-icon {
                        transform: rotate(180deg);

                        & img {
                            /* width: clamp(2cqw, 5cqw, 10cqw); */
                            width: calc((5cqw + 7.55cqh) / 2);
                            height: auto;
                        }
                    }
                }
            }
        }

        & h1 {
            display: none;
            justify-content: center;
            align-items: center;
            width: 2.5em;
            height: 100%;
            padding: 0 clamp(1rem, 2cqw, 2rem);
            color: var(--light-background);
            font-size: calc((3cqw + 5.91cqh) / 2);
            letter-spacing: clamp(0.125em, 0.35em, 0.5em);
            text-align: center;
            text-transform: uppercase;
            writing-mode: vertical-rl;
            text-shadow: -2px -2px 2px rgba(255, 255, 255, 0.1), 2px 2px 2px rgba(0, 0, 0, 0.5);
            border-top: 2px solid var(--dark-background);
            border-bottom: 2px solid var(--dark-background);
            transform: rotate(180deg);

            &:has(span) {
                flex-direction: column;
            }

            &.visible {
                display: flex;
            }

            & div {
                display: flex;
                justify-content: center;
            }
        }
    }

    & > main {
        container-type: size;
        container-name: resume-main;
        flex: 5;
        height: 100%;
        font-family: "Petrona";

        & .resume-section {
            display: none;
            height: 100%;
            padding: clamp(0.25em, 0.5em, 1em);

            &.visible {
                display: block;
            }

            & > ul > li {
                margin-bottom: clamp(0.5em, 2em, 3em);

                & > details {
                    & > summary {
                        padding-bottom: clamp(0.075em, 0.125em, 0.25em);
                        font-weight: 900;
                        font-variation-settings: "wght" 900;
                        list-style: none;
                        pointer-events: none;

                        &::marker {
                            display: none;
                        }

                        &::-webkit-details-marker {
                            display: none;
                        }

                        &:hover {
                            cursor: pointer;
                        }
                    }
                }
            }

            &#summary {
                height: 100%;
                padding: 0;
                overflow-y: hidden;
                font-size: calc((3.5cqw + 4cqh) / 2);

                line-height: clamp(1.25em, 1.5em, 2em);

                &.visible {
                    display: flex;
                    justify-content: space-around;
                }

                & p {
                    align-self: center;
                    width: 60cqw;
                    padding-left: calc((1.5cqw + 2cqh) / 2);
                    font-weight: 200;

                    & span {
                        & em {
                            font-weight: 600;
                        }

                        &.web-technology-words {
                            font-weight: 800;
                        }
                        &.featured {
                            color: transparent;
                            background: linear-gradient(90deg, var(--light-background) 20%, var(--featured-web-tech-color) 40%, var(--light-background) 60%);
                            background-size: 200% 100%;
                            background-clip: text;
                            -webkit-background-clip: text;
                            animation: colorPass 2s linear;

                            &.mysql {
                                color: var(--featured-web-tech-color);
                                background: linear-gradient(90deg, var(--light-background) 20%, #409bac 40%, #f29111 60%, var(--light-background) 80%);
                                background-size: 200% 100%;
                                background-clip: text;
                                -webkit-background-clip: text;
                                color: transparent;
                                animation: colorPass 2s linear;
                            }
                        }
                    }
                    & em {
                        font-weight: 600;
                        & span {
                            font-weight: 600;
                        }
                    }
                }

                & .web-technology-logos {
                    display: flex;
                    flex-direction: column;
                    justify-content: center;
                    align-items: center;
                    overflow: hidden;
                    padding: 0 2.25em;

                    & .logos-list {
                        display: flex;
                        flex: 0 0 auto;
                        flex-direction: column;
                        justify-content: center;
                        align-items: flex-start;
                        animation: logos-ticker-vertical 15s linear infinite;

                        & > li {
                            display: flex;
                            justify-content: center;
                            align-items: center;
                            width: 100%;

                            & img {
                                width: auto;
                                height: 2.25em;
                                padding: 0.5em 0;
                                transition: transform 0.5s ease-in-out;
                                transform-origin: center center;

                                &.featured {
                                    transform: scale(2);

                                    &.git {
                                        height: 2em;
                                    }
                                }
                            }
                        }
                    }
                }
            }

            &#education {
                font-size: calc((3cqw + 4cqh) / 2);
                line-height: clamp(1.25em, 1.75em, 2em);

                & > ul {
                    display: flex;
                    flex-direction: column;
                    justify-content: space-between;

                    & > li.academics {
                        display: flex;
                        margin-bottom: clamp(0.5em, 1em, 2em);

                        & > details {
                            flex: 1 1 0;
                            display: flex;
                            flex-direction: column;

                            & > summary {
                                display: flex;
                                justify-content: space-between;
                                align-items: flex-end;
                                column-gap: calc((1cqw + 2cqh) / 2);
                                line-height: 1.15;

                                border-bottom: 2px solid var(--curiosity-color);

                                & .college {
                                    display: flex;
                                    flex-wrap: wrap;
                                    align-items: flex-end;
                                    font-weight: 800;

                                    & > .college-name {
                                        margin-right: 0.5em;
                                        font-weight: 900;
                                        white-space: nowrap;
                                    }

                                    & > .college-location {
                                        font-size: 0.75em;
                                        font-weight: 400;
                                        font-variation-settings: "wght" 400;
                                        white-space: nowrap;
                                    }
                                }

                                & > .graduation {
                                    display: flex;
                                    justify-content: flex-end;
                                    align-items: flex-end;
                                    padding-bottom: clamp(0.075em, 0.125em, 0.25em);
                                    font-size: 0.75em;
                                    line-height: 0.9em;
                                    text-align: right;
                                    white-space: nowrap;
                                }
                            }

                            & > ul.education-details {
                                display: grid;
                                grid-template-rows: repeat(4, max-content);
                                grid-template-columns: repeat(3, 1fr);
                                font-size: clamp(0.5em, 0.75em, 1em);

                                & > li {
                                    line-height: 1.25;

                                    &:not(.graduation) {
                                        padding: clamp(0.075em, 0.125em, 0.25em) 0;
                                    }

                                    &.academic-credential {
                                        grid-row: 1;
                                        grid-column: 1 / 3;
                                        display: flex;
                                        flex-wrap: wrap;
                                        font-weight: 700;
                                    }

                                    &.major {
                                        grid-row: 2;
                                        grid-column: 1 / 3;
                                        padding-left: 0.5em;
                                        font-weight: 500;
                                        font-style: italic;
                                    }

                                    &.gpa {
                                        grid-row: 1;
                                        grid-column: 3;
                                        display: flex;
                                        justify-content: flex-end;
                                        padding-top: 0.25em;
                                        font-size: 0.85em;
                                        text-align: right;
                                    }

                                    &.honors {
                                        grid-row: 2;
                                        grid-column: 3;
                                        display: flex;
                                        justify-content: flex-end;
                                        font-size: 0.85em;
                                        text-align: right;
                                    }

                                    &.membership {
                                        grid-row: 3;
                                        grid-column: 3;
                                        font-size: 0.85em;
                                        text-align: right;

                                        & > span {
                                            font-size: 0.75em;
                                            font-weight: 300;
                                            font-style: italic;
                                            white-space: nowrap;
                                        }
                                    }
                                }
                            }
                        }

                        & > img {
                            margin-left: calc((1cqw + 2cqh) / 2);
                            width: 10%;
                            height: 10%;
                        }

                        &:last-child > details > ul > li:nth-child(3) {
                            grid-row: 3;
                        }
                        &:last-child > details > ul > li:nth-child(4) {
                            grid-row: 4;
                        }
                    }
                }
            }

            &#relevant-experience {
                container-type: size;
                height: 100%;
                padding: calc((1cqw + 1.97cqh) / 2);

                & > ul {
                    display: grid;
                    grid-auto-flow: column;
                    grid-template-rows: repeat(3, min-content);
                    row-gap: 1cqh;
                    column-gap: 4cqw;
                    height: 100cqh;
                    font-size: calc((2cqw + 3.96cqh) / 2);

                    & > li {
                        margin-bottom: clamp(0.5em, 0.65em, 0.85em);

                        & details {
                            font-size: clamp(0.4em, 0.65em, 0.9em);
                            line-height: clamp(1em, 1.25em, 1.5em);

                            & summary {
                                display: flex;
                                justify-content: space-between;
                                align-items: flex-start;
                                font-size: clamp(1em, 1.125em, 1.25em);
                                border-bottom: 2px solid var(--creativity-color);

                                & span.project-name {
                                    font-weight: 800;
                                }

                                & > abbr {
                                    display: none;
                                }

                                & > span:last-of-type {
                                    font-size: 0.75em;
                                    font-weight: 300;
                                    font-style: italic;
                                    vertical-align: bottom;
                                }
                            }

                            &[name]:not([open]) summary {
                                color: var(--light-background);
                                border-bottom: none;
                                pointer-events: all;

                                &:hover {
                                    color: var(--creativity-color);
                                    cursor: pointer;
                                }

                                & > span:last-child {
                                    display: none;
                                }
                            }

                            & > div.project-details {
                                display: flex;

                                & ul {
                                    display: flex;
                                    flex-direction: column;
                                    padding: 0.5em 0.5em 0 0;

                                    & .web-technology-logo {
                                        height: 1.5em;
                                        margin-bottom: 0.5em;
                                    }
                                }

                                & p {
                                    overflow-y: auto;
                                    margin-top: clamp(0.25em, 0.5em, 0.75em);
                                    padding-left: clamp(0.25em, 0.5em, 0.75em);
                                    font-size: 0.8em;
                                    font-weight: 300;
                                    line-height: clamp(1.5em, 1.75em, 2em);
                                    border-left: 2px solid var(--creativity-color);

                                    & img.project-logo {
                                        float: right;
                                        width: clamp(2.5em, 6.5em, 8.5em);
                                        margin-left: 0.5em;
                                    }

                                    & a {
                                        color: var(--creativity-color);
                                        text-decoration-thickness: 2px;
                                        text-decoration-color: var(--creativity-color);

                                        &:hover,
                                        &:focus-within {
                                            color: #eda599;
                                            animation: glow 1s ease-in-out infinite alternate;
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }

            &#professional-experience {
                flex-direction: column;
                font-size: calc((2.5cqw + 4cqh) / 2);

                &.visible {
                    display: flex;
                }

                & > ul {
                    display: flex;
                    flex-direction: column;
                    justify-content: space-between;
                    height: 100%;

                    & > li.job {
                        display: flex;
                        justify-content: space-between;
                        align-items: flex-start;
                        flex: 1 1 auto;
                        height: fit-content;
                        margin-bottom: calc((1.5cqw + 2cqh) / 2);

                        & > details {
                            width: 90cqw;
                            height: 100%;

                            &[name][open] {
                                border-bottom: 2px solid var(--empathy-color);
                                padding-bottom: clamp(0.2em, 0.35em, 0.5em);
                            }

                            &[name][open] > summary {
                                color: var(--empathy-color);
                            }

                            &[name]:not([open]) {
                                height: max-content;

                                & > summary {
                                    color: var(--light-background);
                                    border-bottom: none;
                                    pointer-events: all;

                                    &:hover {
                                        color: var(--empathy-color);
                                        cursor: pointer;
                                    }

                                    & > span.job-title::before {
                                        content: "\25B6\FE0E";
                                        margin-right: 0.5em;
                                    }

                                    & > span.employment-dates {
                                        display: none;
                                    }
                                }
                            }

                            & > summary {
                                display: flex;
                                justify-content: space-between;
                                font-size: clamp(0.5em, 0.65em, 1em);
                                border-bottom: calc((0.25cqw + 0.49cqh) / 2) solid var(--empathy-color);

                                & > span.job-title {
                                    font-weight: 700;
                                }

                                & > span.employment-dates {
                                    padding-bottom: clamp(0.075em, 0.125em, 0.25em);
                                    font-size: 0.85em;
                                    text-align: right;
                                    vertical-align: bottom;
                                    font-size: 0.75em;
                                    font-weight: 300;
                                    font-variation-settings: "wght" 300;

                                    & > abbr {
                                        display: none;
                                    }
                                }
                            }

                            & > ul.job-details {
                                font-size: clamp(0.5em, 0.6em, 1em);
                                height: 100%;

                                & > li {
                                    line-height: 1.4;

                                    &:last-child {
                                        display: flex;
                                        align-items: center;
                                    }

                                    &.employer {
                                        display: flex;
                                        justify-content: space-between;
                                        margin: clamp(0.125em, 0.25em, 0.5em) 0;
                                        font-size: 1em;
                                        font-style: italic;

                                        & > span.employer-name {
                                            display: flex;
                                            flex-direction: column;
                                            font-weight: 800;
                                            font-style: italic;

                                            & > span.parent-company {
                                                font-weight: 500;
                                                font-style: italic;
                                            }
                                        }

                                        & > span.employer-location {
                                            font-weight: 300;
                                            font-style: italic;
                                        }
                                    }

                                    &.job-duties {
                                        & > ul {
                                            overflow-y: auto;
                                            column-count: 2;

                                            & > li {
                                                margin-left: 1em;
                                                font-size: clamp(0.5em, 0.75em, 1em);
                                                list-style-type: disc;
                                            }
                                        }
                                    }
                                }
                            }
                        }

                        & img {
                            display: block;
                            margin-left: clamp(0.5em, 1em, 2em);
                            width: 10%;
                            height: auto;
                            object-fit: contain;

                            &[src*="semihandmade"] {
                                border-radius: 15%;
                            }
                        }

                        &:has(details[name]:not([open])) > img {
                            visibility: hidden;
                        }
                    }
                }
            }
        }
    }
}

@keyframes logos-ticker-vertical {
    0% {
        transform: translateY(0%);
    }
    100% {
        transform: translateY(-100%);
    }
}

@keyframes logos-ticker-horizontal {
    0% {
        transform: translateX(0%);
    }
    100% {
        transform: translateX(-100%);
    }
}

@keyframes colorPass {
    0% {
        background-position: 100% 0;
    }
    100% {
        background-position: -100% 0;
    }
}

@keyframes glow {
    from {
        text-shadow: 0 0 10px var(--light-background), 0 0 20px var(--light-background), 0 0 30px #aa321e, 0 0 40px #aa321e, 0 0 50px #aa321e, 0 0 60px #aa321e, 0 0 70px #aa321e;
    }
    to {
        text-shadow: 0 0 20px var(--light-background), 0 0 30px #d53e25, 0 0 40px #d53e25, 0 0 50px #d53e25, 0 0 60px #d53e25, 0 0 70px #d53e25, 0 0 80px #d53e25;
    }
}
