:root {
    color-scheme: light;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

#projects a {
    color: inherit;
    text-decoration: none;
}

#projects a:hover {
    color: var(--accent-dark);
}

#projects a:focus-visible {
    outline: 3px solid var(--accent);
    outline-offset: 5px;
}

main.container {
    width: min(1170px, calc(100% - 48px));
    max-width: none;
    padding-inline: 0;
    margin-inline: auto;
}

main {
    flex: 1;
    padding-top: 64px;
    scroll-margin-top: 64px;
}

.intro {
    padding: 65px 0 48px;
    text-align: center;
}

#projects .eyebrow {
    margin: 0 0 10px;
    color: var(--accent);
    text-transform: uppercase;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 2px;
}

#projects h1 {
    margin: 0 0 16px;
    font-size: clamp(36px, 5vw, 48px);
    font-weight: 800;
    line-height: 1.2;
}

#projects h1 span {
    color: var(--accent);
}

.intro>p:last-child {
    margin: 0;
    color: var(--muted);
    font-size: 16px;
}

.project-section {
    padding-bottom: 72px;
}

.section-heading {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
    margin-bottom: 22px;
    border-bottom: 1px solid var(--line);
    padding-bottom: 14px;
}

#projects .section-heading h2 {
    margin: 0;
    font-size: 19px;
    font-weight: 800;
}

.section-heading>span {
    color: var(--muted);
    font-size: 12px;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 25px;
}

.project-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 3px;
    box-shadow: 0 2px 4px #15203305;
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.project-card:hover {
    transform: translateY(-4px);
    border-color: var(--accent);
    box-shadow: 0 10px 24px #15203310;
}

.card-visual {
    height: 200px;
    display: grid;
    place-items: center;
    position: relative;
    overflow: hidden;
    color: var(--accent);
    background: var(--soft);
    border-bottom: 1px solid var(--line);
}

.project-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.card-content {
    padding: 21px 22px 24px;
    flex: 1;
}

.card-category {
    margin: 0 0 6px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent);
    font-size: 10px;
    font-weight: 800;
}

#projects .card-content h3 {
    margin: 0 0 10px;
    font-size: 20px;
    font-weight: 800;
}

.card-content>p:last-child {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.75;
}

.card-footer {
    background: transparent;
    padding: 13px 22px;
    border-top: 1px solid var(--line);
}

.status {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--muted);
    font-size: 11px;
}

.status::before {
    content: "";
    width: 5px;
    height: 5px;
    flex-shrink: 0;
    border-radius: 50%;
    background: var(--accent);
}

.skip-link {
    position: absolute;
    top: 8px;
    left: 8px;
    transform: translateY(-160%);
    background: var(--surface);
    padding: 10px 16px;
    z-index: 1040;
}

.skip-link:focus {
    transform: translateY(0);
}

@media (max-width: 1000px) {
    .project-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 580px) {
    main.container {
        width: calc(100% - 32px);
    }

    .intro {
        padding: 42px 0 35px;
    }

    .project-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 20px;
    }

    .project-image {
        position: absolute;
        inset: 0;
        object-position: center top;
    }

    .project-section {
        padding-bottom: 40px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .project-card {
        transition: none;
    }

    .project-card:hover {
        transform: none;
    }
}