:root {
    --page-padding: 90px;
}

html {
    background-color: white;
    margin: 0;
    padding: 0;
}

body {
    font-family: Helvetica;
    margin: 0;
    padding: 0;
    height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
}

p {
    margin: 0;
    padding: 0;
}

a {
    color: black;
    text-decoration: none;
}

/* ── Nav ─────────────────────────────────── */

.header {
    position: fixed;
    inset: 0;
    pointer-events: none;
    background: none;
    z-index: 5000;
    transition: opacity 0.3s;
}

.header.dimmed {
    opacity: 0.25;
    pointer-events: none;
}

.name,
.about {
    position: absolute;
    pointer-events: all;
    font-size: 27.2px;
    font-weight: bold;
    letter-spacing: 0.544px;
    color: #000000;
}

.name {
    top: 30px;
    left: 30px;
}

.about {
    top: 30px;
    right: 30px;
}

.name:hover,
.about:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* ── Projects ────────────────────────────── */

.projects {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 0 var(--page-padding);
}

.projects-row {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 16px;
    width: 100%;
}

.project-card {
    flex: 1;
    position: relative;
}

.project-card img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    display: block;
}

.project-info {
    position: absolute;
    top: calc(100% + 14px);
    left: 0;
    width: 100%;
    opacity: 0;
    pointer-events: none;
}

.project-card:hover .project-info {
    opacity: 1;
    pointer-events: auto;
}

.project-title {
    font-weight: bold;
    font-size: 15px;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
    display: block;
    color: black;
    text-decoration: none;
    text-transform: uppercase;
    transition: color 0.3s;
}

.project-title:hover {
    color: #a9a9a9;
}

.project-desc {
    font-size: 13px;
    color: #bababa;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* ── Carousel (≤ 1100px) ─────────────────── */

@media (max-width: 1100px) {
    .projects {
        padding-left: 0;
        padding-right: 0;
    }

    .projects-row {
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        scrollbar-width: none;
        -ms-overflow-style: none;
        padding: 0 var(--page-padding);
        box-sizing: border-box;
        scroll-padding-left: var(--page-padding);
        mask-image: linear-gradient(
            to right,
            transparent,
            black var(--page-padding),
            black calc(100% - var(--page-padding)),
            transparent
        );
        -webkit-mask-image: linear-gradient(
            to right,
            transparent,
            black var(--page-padding),
            black calc(100% - var(--page-padding)),
            transparent
        );
    }

    .projects-row::-webkit-scrollbar {
        display: none;
    }

    .project-card {
        flex-shrink: 0;
        min-width: 300px;
        scroll-snap-align: start;
        display: flex;
        flex-direction: column;
    }

    .project-info {
        position: static;
        opacity: 1;
        transform: none;
        pointer-events: auto;
        padding-top: 10px;
    }
}

@media (max-width: 600px) {
    .projects-row {
        padding: 0 24px;
        scroll-padding-left: 24px;
        mask-image: linear-gradient(
            to right,
            transparent,
            black 24px,
            black calc(100% - 24px),
            transparent
        );
        -webkit-mask-image: linear-gradient(
            to right,
            transparent,
            black 24px,
            black calc(100% - 24px),
            transparent
        );
    }

    .project-card {
        min-width: 70vw;
    }
}

/* ── Password Entry ──────────────────────── */

.enter-wrap {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.enter-form {
    display: grid;
    grid-template-columns: auto 220px;
    column-gap: 12px;
    row-gap: 10px;
    align-items: baseline;
}

.enter-form input[type="hidden"] {
    display: none;
}

.enter-label {
    font-family: Helvetica;
    font-size: 20px;
    font-weight: 300;
    letter-spacing: 0.4px;
    white-space: nowrap;
    color: #000;
}

.enter-form input[type="password"] {
    border: none;
    border-bottom: 1px solid #000;
    outline: none;
    font-family: Helvetica;
    font-size: 20px;
    font-weight: 300;
    letter-spacing: 0.4px;
    padding: 8px 0;
    width: 220px;
    background: transparent;
}

.enter-hint {
    grid-column: 2;
    font-size: 13px;
    color: #bababa;
    letter-spacing: 0.3px;
    white-space: nowrap;
}

.enter-error {
    grid-column: 2;
    font-size: 13px;
    color: #bababa;
    letter-spacing: 0.3px;
}

/* ── Footer ──────────────────────────────── */

.footer {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 4999;
    mix-blend-mode: difference;
}

.footer-copy {
    position: absolute;
    bottom: 30px;
    left: 30px;
    font-size: 13px;
    letter-spacing: 0.3px;
    color: white;
}

.footer-link {
    position: absolute;
    bottom: 30px;
    right: 30px;
    pointer-events: all;
    font-size: 13px;
    letter-spacing: 0.544px;
    color: white;
}

.footer-link:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}
