:root {
    --page-background: #24242b;
    --alternate-background: #1d1d23;
    --card-background: #2d2d35;

    --text-primary: #f2f2f4;
    --text-secondary: #b7b7c2;
    --text-muted: #8f8f9b;

    --border-color: #41414c;
    --hover-background: #35353f;

    --timeline-left: 2rem;
    --timeline-width: 3px;
	
	--font-display: "Roboto Mono", monospace;
	--font-body: "Inter", sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 0;
}

body {
    margin: 0;
    overflow-x: hidden;
    background: var(--page-background);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
}

img,
video {
    display: block;
    max-width: 100%;
}

a {
    color: inherit;
}

h1,
h2,
h3,
h4,
p {
    margin-top: 0;
}

h1,
h2,
h3,
h4 {
    font-family: var(--font-display);
    line-height: 1.1;
    font-weight: 600;
}


button,
input,
textarea,
select {
    font: inherit;
}
.button,
.section__label,
.timeline-nav,
.tag-list,
.resume-entry__date,
.resume-entry__company,
.project-card__category {
    font-family: var(--font-display);
}
p,
li {
    font-family: var(--font-body);
}

ul {
    margin-top: 0;
}


/* ---Shared--- */

.container {
    width: min(1200px, calc(100% - 8rem));
    margin-inline: auto;
}

.section {
    padding: clamp(5rem, 9vw, 9rem) 0;
}

.section--alternate {
    background: var(--alternate-background);
}

.section__label {
    margin-bottom: 0.75rem;
    color: var(--text-muted);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.section h2 {
    max-width: 800px;
    margin-bottom: 2rem;
    font-size: clamp(2.5rem, 6vw, 5rem);
}

.section-heading {
    display: flex;
    gap: 2rem;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: clamp(3rem, 6vw, 6rem);
}

.section-heading h2 {
    margin-bottom: 0;
}


/* ---Hero banner--- */

.hero {
    position: relative;
    display: grid;
    min-height: 100vh;
    min-height: 100svh;
    overflow: hidden;
    background: var(--page-background);
    color: white;
    isolation: isolate;
    place-items: center;
}

.hero__video {
    position: absolute;
    z-index: -2;
    width: 100%;
    height: 100%;
    object-fit: cover;
    inset: 0;
}

.hero__overlay {
    position: absolute;
    z-index: -1;
    background:
        linear-gradient(
            180deg,
            rgba(10, 10, 14, 0.7),
            rgba(10, 10, 14, 0.8)
        );
    inset: 0;
}

.hero__content {
    width: min(900px, calc(100% - 4rem));
    padding: 4rem 0;
    text-align: center;
}

.hero__eyebrow {
    margin-bottom: 1rem;
    font-size: clamp(0.75rem, 2vw, 1rem);
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

.hero h1 {
    margin-bottom: 1rem;
    font-size: clamp(3.5rem, 12vw, 6rem);
	    letter-spacing: -0.08em;
    font-weight: 700;
	background-color:black;
	padding: 6px;
}


.hero__description {
    max-width: 650px;
    margin: 0 auto 2rem;
    color: rgba(255, 255, 255, 0.88);
    font-size: clamp(1rem, 2.5vw, 1.4rem);
}


/* ---Buttons--- */

.button {
    display: inline-flex;
    min-height: 3rem;
    padding: 0.8rem 1.4rem;
    border: 2px solid white;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
    text-decoration: none;
    transition:
        background-color 150ms ease,
        border-color 150ms ease,
        color 150ms ease,
        transform 150ms ease;
}

.button:hover,
.button:focus-visible {
    background: white;
    color: var(--page-background);
    transform: translateY(-2px);
}

.button--dark {
    border-color: var(--text-primary);
    color: var(--text-primary);
}

.button--dark:hover,
.button--dark:focus-visible {
    background: var(--text-primary);
    color: var(--page-background);
}


/* ---Leftside timeline thingie--- */

.timeline-nav {
    position: fixed;
    z-index: 100;
    top: 50%;
    left: var(--timeline-left);
    display: flex;
    width: 3rem;
    height: min(60vh, 520px);
    flex-direction: column;
    justify-content: space-between;
    color: var(--text-primary);
    transform: translateY(-50%);
}

.timeline-nav__track {
    position: absolute;
    top: 0.5rem;
    bottom: 0.5rem;
    left: 50%;
    width: var(--timeline-width);
    overflow: hidden;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    transform: translateX(-50%);
}

.timeline-nav__progress {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 0%;
    border-radius: inherit;
    background: currentColor;
    transition: height 80ms linear;
}

.timeline-nav__button {
    position: relative;
    z-index: 2;
    display: flex;
    width: 3rem;
    height: 3rem;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    text-decoration: none;
    transition:
        color 150ms ease,
        transform 150ms ease;
}

.timeline-nav__button:hover,
.timeline-nav__button:focus-visible,
.timeline-nav__button.is-active {
    color: var(--text-primary);
}

.timeline-nav__button:hover {
    transform: scale(1.08);
}

.timeline-nav__dot {
    display: block;
    width: 0.75rem;
    height: 0.75rem;
    border: 3px solid currentColor;
    border-radius: 50%;
    background: var(--page-background);
    transition:
        width 150ms ease,
        height 150ms ease,
        background-color 150ms ease;
}

.timeline-nav__button.is-active .timeline-nav__dot {
    width: 1rem;
    height: 1rem;
    background: currentColor;
}

.timeline-nav__label {
    position: absolute;
    left: calc(100% + 0.35rem);
    padding: 0.3rem 0.55rem;
    border: 1px solid var(--border-color);
    border-radius: 0.2rem;
    background: var(--card-background);
    color: var(--text-primary);
    font-size: 0.75rem;
    font-weight: 700;
    opacity: 0;
    pointer-events: none;
    transform: translateX(-0.5rem);
    transition:
        opacity 150ms ease,
        transform 150ms ease;
    white-space: nowrap;
}

.timeline-nav__button:hover .timeline-nav__label,
.timeline-nav__button:focus-visible .timeline-nav__label {
    opacity: 1;
    transform: translateX(0);
}

.timeline-nav.is-over-hero {
    color: white;
}

.timeline-nav.is-over-hero .timeline-nav__button {
    color: rgba(255, 255, 255, 0.65);
}

.timeline-nav.is-over-hero .timeline-nav__button:hover,
.timeline-nav.is-over-hero .timeline-nav__button:focus-visible,
.timeline-nav.is-over-hero .timeline-nav__button.is-active {
    color: white;
}

.timeline-nav.is-over-hero .timeline-nav__dot {
    background: #18181d;
}


/* ---Resume stuff--- */

.resume-layout {
    display: grid;
    grid-template-columns: minmax(220px, 0.7fr) minmax(0, 2fr);
    gap: clamp(3rem, 8vw, 7rem);
}

.resume-sidebar {
    align-self: start;
}

.resume-sidebar__section + .resume-sidebar__section {
    margin-top: 3rem;
}

.resume-sidebar h3 {
    margin-bottom: 1rem;
    font-size: 1rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.resume-sidebar p {
    color: var(--text-secondary);
}

.resume-sidebar__section .tag-list + h3 {
    margin-top: 2.5rem;
}

.tag-list,
.link-list {
    padding: 0;
    list-style: none;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag-list li {
    padding: 0.35rem 0.7rem;
    border: 1px solid var(--border-color);
    background: var(--card-background);
    color: var(--text-primary);
    font-size: 0.85rem;
}

.link-list li + li {
    margin-top: 0.5rem;
}

.link-list a {
    color: var(--text-primary);
    font-weight: 700;
    text-underline-offset: 0.25rem;
}

.resume-category + .resume-category {
    margin-top: 5rem;
}

.resume-category__title {
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--text-primary);
    font-size: clamp(1.4rem, 3vw, 2rem);
}

.resume-entry {
    padding: 0 0 3rem;
}

.resume-entry + .resume-entry {
    padding-top: 3rem;
    border-top: 1px solid var(--border-color);
}

.resume-entry__header {
    display: flex;
    gap: 2rem;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}

.resume-entry h4 {
    margin-bottom: 0.35rem;
    font-size: clamp(1.25rem, 3vw, 1.75rem);
}

.resume-entry__company {
    margin-bottom: 0;
    color: var(--text-secondary);
    font-weight: 700;
}

.resume-entry__date {
    margin-bottom: 0;
    color: var(--text-secondary);
    font-weight: 700;
    white-space: nowrap;
}

.resume-entry > p,
.resume-entry li {
    color: var(--text-secondary);
}

.resume-entry ul {
    padding-left: 1.25rem;
}


/* ---Portfolio and galleries--- */

.gallery {
    display: grid;
    grid-template-columns:
        repeat(
            auto-fit,
            minmax(min(100%, 280px), 1fr)
        );
    gap: clamp(1rem, 3vw, 2rem);
}

.project-card {
    overflow: hidden;
    border: 1px solid var(--border-color);
    background: var(--card-background);
    transition:
        background-color 150ms ease,
        border-color 150ms ease,
        transform 150ms ease;
}

.project-card:hover {
    border-color: #5a5a68;
    background: var(--hover-background);
    transform: translateY(-3px);
}

.project-card img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    transition: transform 250ms ease;
}

.project-card:hover img {
    transform: scale(1.025);
}

.project-card__content {
    padding: 1.5rem;
}

.project-card h3 {
    margin-bottom: 0.75rem;
    font-size: 1.5rem;
}

.project-card p {
    color: var(--text-secondary);
}

.project-card a {
    color: var(--text-primary);
    font-weight: 700;
    text-underline-offset: 0.25rem;
}

.portfolio-introduction {
    max-width: 760px;
    margin-bottom: clamp(2.5rem, 5vw, 4rem);
    color: var(--text-secondary);
    font-size: clamp(1rem, 2vw, 1.25rem);
}

.project-card__category {
    margin-bottom: 0.65rem;
    color: var(--text-muted);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}


/* ---Footer--- */

.footer {
    padding: 2rem 0;
    border-top: 1px solid var(--border-color);
    background: #18181d;
    color: var(--text-primary);
}

.footer__content {
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: space-between;
}

.footer p {
    margin: 0;
}


/* ---Responsive tablet stuff--- */

@media (max-width: 900px) {
    :root {
        --timeline-left: 0.6rem;
    }

    .container {
        width: min(100% - 5rem, 1200px);
        margin-left: 4rem;
        margin-right: 1rem;
    }

    .resume-layout {
        grid-template-columns: 1fr;
        gap: 4rem;
    }

    .resume-sidebar {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 2rem;
    }

    .resume-sidebar__section + .resume-sidebar__section {
        margin-top: 0;
    }
}


/* ---Small mobile screen stuff--- */

@media (max-width: 600px) {
    :root {
        --timeline-left: 0.15rem;
    }

    .container {
        width: calc(100% - 4.25rem);
        margin-left: 3.5rem;
        margin-right: 0.75rem;
    }

    .section {
        padding: 4rem 0;
    }

    .hero__content {
        width: calc(100% - 5rem);
        margin-left: 3rem;
    }

    .timeline-nav {
        width: 2.5rem;
        height: min(55vh, 400px);
    }

    .timeline-nav__button {
        width: 2.5rem;
        height: 2.5rem;
    }

    .timeline-nav__label {
        display: none;
    }

    .section-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .resume-sidebar {
        grid-template-columns: 1fr;
    }

    .resume-entry__header {
        flex-direction: column;
        gap: 0.5rem;
    }

    .contact {
        align-items: flex-start;
        flex-direction: column;
    }

    .footer__content {
        align-items: flex-start;
        flex-direction: column;
    }
}




@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }

    .hero__video {
        display: none;
    }

    .hero {
        background: var(--page-background);
    }
}

.scroll-indicator {
    display: flex;

    width: 3.75rem;
    height: 3.75rem;

    margin: 3rem auto 0;

    border: 2px solid rgba(255,255,255,.6);
    border-radius: 50%;

    align-items: center;
    justify-content: center;

    color: white;
    font-family: var(--font-display);
    font-size: 2rem;
    text-decoration: none;
	padding-bottom:22px;

    transition:
        transform .2s,
        background .2s,
        border-color .2s;
}

.scroll-indicator:hover {
    background: rgba(255,255,255,.12);
    border-color: white;
    transform: translateY(4px);
}
@keyframes floatArrow {

    0%,100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(6px);
    }

}

.scroll-indicator {
    animation: floatArrow 2s ease-in-out infinite;
}

/* ---Project cards and modal stuff--- */

.project-card {
    display: flex;
    flex-direction: column;
    cursor: pointer;
}

.project-card:focus-visible {
    outline: 3px solid var(--text-primary);
    outline-offset: 4px;
}

.project-card__content {
    display: flex;
    height: 100%;
    flex-direction: column;
    padding: 1.5rem;
}

.project-card p:last-of-type {
    flex-grow: 1;
}

.project-card__external-link {
    position: relative;
    z-index: 2;
    align-self: flex-start;
    margin-top: 1rem;
    color: var(--text-primary);
    font-weight: 700;
    text-decoration: none;
}

.project-card__external-link:hover,
.project-card__external-link:focus-visible {
    text-decoration: underline;
}


.media-modal {
    position: fixed;
    z-index: 1000;
    display: none;
    inset: 0;
}

.media-modal.is-open {
    display: grid;
    place-items: center;
}

.media-modal__backdrop {
    position: absolute;
    background: rgba(8, 8, 12, 0.88);
    backdrop-filter: blur(6px);
    inset: 0;
}

.media-modal__dialog {
    position: relative;
    z-index: 1;
    width: min(1100px, calc(100% - 3rem));
    max-height: calc(100vh - 3rem);
    overflow: auto;
    padding: clamp(1rem, 3vw, 2rem);
    border: 1px solid var(--border-color);
    background: var(--card-background);
    box-shadow: 0 2rem 6rem rgba(0, 0, 0, 0.55);
}

.media-modal__title {
    margin-bottom: 1.5rem;
    padding-right: 3rem;
    font-size: clamp(1.5rem, 4vw, 2.5rem);
}

.media-modal__close {
    position: absolute;
    top: 0.75rem;
    right: 1rem;
    width: 2.75rem;
    height: 2.75rem;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--text-primary);
    cursor: pointer;
    font-family: var(--font-display);
    font-size: 2.25rem;
    line-height: 1;
}

.media-modal__close:hover,
.media-modal__close:focus-visible {
    color: white;
    transform: scale(1.08);
}

.media-modal__content {
    display: grid;
    gap: 1rem;
}


.media-modal__gallery {
    display: grid;
    grid-template-columns:
        repeat(
            auto-fit,
            minmax(min(100%, 320px), 1fr)
        );
    gap: 1rem;
}

.media-modal__gallery img {
    width: 100%;
    border: 1px solid var(--border-color);
    background: var(--page-background);
    object-fit: contain;
}

.media-modal__video,
.media-modal__youtube {
    width: 100%;
    border: 0;
    background: black;
    aspect-ratio: 16 / 9;
}

body.modal-open {
    overflow: hidden;
}

/* ---modal gallery display--- */

.media-modal__gallery-viewer {
    display: grid;
    gap: 1rem;
}

.media-modal__featured-image {
    width: 100%;
    max-height: 50vh;
    border: 1px solid var(--border-color);
    background: var(--page-background);
    object-fit: contain;
}

.media-modal__thumbnails {
    display: grid;
    grid-template-columns:
        repeat(
            auto-fit,
            minmax(90px, 1fr)
        );
    gap: 0.75rem;
}

.media-modal__thumbnail {
    padding: 0;
    overflow: hidden;
    border: 2px solid transparent;
    background: transparent;
    cursor: pointer;
    opacity: 0.65;
    transition:
        border-color 150ms ease,
        opacity 150ms ease,
        transform 150ms ease;
}

.media-modal__thumbnail:hover,
.media-modal__thumbnail:focus-visible {
    opacity: 1;
    transform: translateY(-2px);
}

.media-modal__thumbnail.is-active {
    border-color: var(--text-primary);
    opacity: 1;
}

.media-modal__thumbnail img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

@media (max-width: 600px) {
    .media-modal__dialog {
        width: calc(100% - 1rem);
        max-height: calc(100vh - 1rem);
        padding: 1rem;
    }

    .media-modal__title {
        padding-right: 2.5rem;
    }
}