@font-face {
    font-family: "Inter";
    font-style: normal;
    font-weight: 400 500;
    font-display: swap;
    src: url("assets/fonts/inter.woff2") format("woff2");
}

:root {
    --color-bg: #fff;
    --color-text-primary: #000;
    --color-text-muted: #a9a9a9;
    --color-text-secondary: #a9a9a9;
    --color-card-bg: #f7f7f7;
    --font-family: "Inter", system-ui, -apple-system, sans-serif;
    --font-weight-medium: 500;
    --font-size-base: 15px;
    --line-height-base: 22px;
    --radius-card: 26px;
    --radius-pill: 100px;
    --content-left-padding: max(26px, calc(50% - 180px));
    --content-right-padding: 26px;
    --card-width: 420px;
    --card-image-height: 460px;
    --card-gap: 20px;
    --hero-padding-top: 226px;
    --project-padding-top: 240px;
    --hero-section-gap: 160px;
    --modal-card-height: 548px;
    --modal-content-gap: 42px;
    --modal-content-padding: 40px;
    --slider-pad-left: var(--content-left-padding);
    --slider-pad-right: 282px;
    --project-image-width: clamp(280px, var(--card-width), 420px);
    --project-image-height: clamp(300px, var(--card-image-height), 460px);
}

@media (max-width: 767px) {
    :root {
        --card-width: min(82vw, 300px);
        --modal-card-height: min(500px, calc(100dvh - 94px));
        --modal-content-gap: 32px;
        --modal-content-padding: clamp(24px, 6vw, 32px);
        --card-image-height: 360px;
        --card-gap: 16px;
        --content-left-padding: 26px;
        --content-right-padding: 26px;
        --hero-padding-top: 200px;
        --hero-section-gap: 200px;
        --project-padding-top: 124px;
        --slider-pad-left: 26px;
        --slider-pad-right: 26px;
        --project-image-width: calc(100vw - 52px);
        --project-image-height: 400px;
    }
}

@media (min-width: 768px) and (max-width: 1199px) {
    :root {
        --card-width: 360px;
        --card-image-height: 420px;
        --slider-pad-right: 26px;
    }
}

*,
::before,
::after {
    box-sizing: border-box;
}

html {
    font-size: var(--font-size-base);
    font-family: var(--font-family);
    font-weight: var(--font-weight-medium);
    line-height: var(--line-height-base);
    background: var(--color-bg);
    color: var(--color-text-primary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar,
.scrollbar-hide::-webkit-scrollbar {
    display: none;
}

body {
    min-height: 100dvh;
    margin: 0;
    padding-bottom: 125px;
    background: var(--color-bg);
    color: var(--color-text-primary);
    scrollbar-width: none;
    -ms-overflow-style: none;
}

body.modal-open {
    overflow: hidden;
}

h1,
p {
    margin: 0;
}

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

img,
svg {
    display: block;
}

img {
    max-width: 100%;
    height: auto;
}

button {
    font: inherit;
    color: inherit;
}

:focus-visible {
    outline: 2px solid var(--color-text-primary);
    outline-offset: 3px;
    border-radius: 4px;
}

.skip-link {
    position: absolute;
    top: -100%;
    left: 16px;
    z-index: 9999;
    padding: 8px 16px;
    border-radius: 0 0 8px 8px;
    background: var(--color-text-primary);
    color: var(--color-bg);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: top 0.15s ease;
}

.skip-link:focus {
    top: 0;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.page-loader {
    position: fixed;
    inset: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    pointer-events: none;
}

.page-loader-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--color-text-muted);
    animation: page-loader-pulse 1.1s ease-in-out infinite;
}

.page-loader-dot:nth-of-type(3) {
    animation-delay: 140ms;
}

.page-loader-dot:nth-of-type(4) {
    animation-delay: 280ms;
}

@keyframes page-loader-pulse {
    0%,
    60%,
    100% {
        opacity: 0.28;
        transform: translateY(0);
    }

    30% {
        opacity: 0.9;
        transform: translateY(-3px);
    }
}

.cms-load-error {
    display: flex;
    min-height: 100dvh;
    align-items: center;
    justify-content: center;
    padding: 26px;
    color: var(--color-text-muted);
    text-align: center;
}

.site-nav {
    position: fixed;
    top: 30px;
    left: 50%;
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 4px;
    background: rgba(242, 242, 242, 0.75);
    border: 0.5px solid rgba(255, 255, 255, 0.65);
    border-radius: var(--radius-pill);
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.07),
        inset 0 0.5px 0 rgba(255, 255, 255, 0.95);
    transform: translateX(-50%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
}

.nav-item {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 50px;
    padding: 15px 20px;
    overflow: hidden;
    border: 0;
    border-radius: var(--radius-pill);
    background: transparent;
    box-shadow: none;
    cursor: pointer;
    text-decoration: none;
    transition:
        background-color 400ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        box-shadow 400ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
    will-change: transform;
}

.nav-item::before {
    content: "";
    display: none;
}

.nav-item > span {
    position: absolute;
    inset: 0;
    border-radius: var(--radius-pill);
    pointer-events: none;
    background: radial-gradient(
        circle at var(--glow-x, 50%) var(--glow-y, 50%),
        rgba(255, 255, 255, 0.48) 0%,
        transparent 65%
    );
    opacity: 0;
    transition: opacity 240ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.nav-item.is-hovering > span {
    opacity: 1;
}

.nav-item path,
.nav-item circle {
    fill: #a9a9a9;
    transition: fill 400ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.home-page .nav-portfolio,
body.modal-open .nav-about {
    background-color: rgba(255, 255, 255, 0.88);
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.1),
        inset 0 0.5px 0 rgb(255, 255, 255);
}

.home-page .nav-portfolio path,
body.modal-open .nav-about path,
body.modal-open .nav-about circle {
    fill: #000;
}

.intro {
    position: relative;
}

.intro-copy {
    width: min(
        360px,
        calc(100% - var(--content-left-padding) - var(--content-right-padding))
    );
    margin-right: var(--content-right-padding);
    margin-left: var(--content-left-padding);
    padding-top: var(--hero-padding-top);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-medium);
    line-height: var(--line-height-base);
}

.intro-rich-text > :first-child {
    margin-top: 0;
}

.intro-rich-text > :last-child {
    margin-bottom: 0;
}

.intro-rich-text p,
.intro-rich-text blockquote,
.intro-rich-text ul,
.intro-rich-text ol,
.intro-rich-text h2,
.intro-rich-text h3,
.intro-rich-text h4 {
    margin-top: 0;
    margin-bottom: var(--line-height-base);
    font-size: inherit;
    line-height: inherit;
}

.intro-rich-text > :not(:first-child) {
    color: var(--color-text-muted);
}

.intro-rich-text ul,
.intro-rich-text ol {
    padding-left: 20px;
}

.intro-rich-text blockquote {
    margin-right: 0;
    margin-left: 0;
    padding-left: 16px;
    border-left: 1px solid var(--color-text-muted);
}

.intro-rich-text a {
    color: var(--color-text-primary);
    text-decoration: underline;
}

.muted {
    color: var(--color-text-muted);
}

.inline-underlined {
    color: #000;
    font-weight: 500;
    text-decoration: underline;
}

.work {
    margin-top: var(--hero-section-gap);
    padding-right: var(--content-right-padding);
    padding-left: var(--content-left-padding);
}

.work-heading,
.work-list {
    width: min(360px, 100%);
}

.work-heading {
    margin: 0 0 14px;
    color: var(--color-text-muted);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-medium);
    line-height: var(--line-height-base);
}

.work-list {
    display: grid;
    gap: 4px;
    margin: 0;
    padding: 4px;
    border: 0.5px solid rgba(255, 255, 255, 0.65);
    border-radius: var(--radius-card);
    /*background: rgba(242, 242, 242, 0.75);*/
    /*box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.035),
        inset 0 0.5px 0 rgba(255, 255, 255, 0.95);*/
    list-style: none;
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
}

.work-item {
    min-width: 0;
}

.work-link {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    align-items: start;
    gap: 0;
    min-height: 50px;
    padding: 14px 28px;
    overflow: hidden;
    border-radius: var(--radius-pill);
    background: transparent;
    box-shadow: none;
    color: inherit;
    text-decoration: none;
    -webkit-tap-highlight-color: transparent;
    transition:
        background-color 400ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        box-shadow 400ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.work-link:hover,
.work-link:focus-visible {
    background-color: rgba(255, 255, 255, 0.88);
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.1),
        inset 0 0.5px 0 rgb(255, 255, 255);
}

.work-link:focus-visible {
    outline: 2px solid var(--color-text-primary);
    outline-offset: 3px;
}

.work-title,
.work-kicker {
    position: relative;
    z-index: 1;
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-medium);
    line-height: var(--line-height-base);
}

.work-arrow {
    position: absolute;
    top: 50%;
    left: -2px;
    z-index: 1;
    color: var(--color-text-secondary);
    opacity: 1;
    transform: translateY(-50%);
    transition:
        opacity 180ms ease,
        transform 180ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.work-link:hover .work-arrow,
.work-link:focus-visible .work-arrow {
    opacity: 0;
    transform: translate(2px, -50%);
}

.work-glow {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    background: radial-gradient(
        circle at var(--glow-x, 50%) var(--glow-y, 50%),
        rgba(255, 255, 255, 0.48) 0%,
        transparent 65%
    );
    opacity: 0;
    transition: opacity 240ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.work-link.is-hovering .work-glow {
    opacity: 1;
}

.work-kicker {
    color: var(--color-text-secondary);
    text-align: left;
}

.contact-label,
.contact-link,
.contact-value {
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-medium);
    line-height: var(--line-height-base);
}

.contact-link,
.contact-value {
    color: var(--color-text-secondary);
}

@media (max-width: 767px) {
    .home-page .work {
        margin-top: 140px;
    }

    .work-heading {
        margin-bottom: 10px;
    }

    .work-link {
        padding: 13px 18px;
    }
}

.contact {
    margin-top: 160px;
    padding-right: var(--content-right-padding);
    padding-bottom: 120px;
    padding-left: var(--content-left-padding);
}

.contact-group {
    margin-bottom: 52px;
}

.contact-link,
.social-links a {
    display: block;
}

.social-links {
    margin: 0;
}

.about-overlay {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(225, 225, 225, 0.15);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition:
        opacity 250ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        visibility 250ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
    -webkit-backdrop-filter: blur(15px);
    backdrop-filter: blur(15px);
}

.about-overlay[hidden] {
    display: none;
}

.about-overlay.is-open {
    display: flex;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.about-shell {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    width: min(411px, 100%);
    opacity: 0;
    transform: translateY(10px) scale(0.985);
    transition:
        opacity 300ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        transform 300ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.about-overlay.is-open .about-shell {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.about-card {
    display: flex;
    flex-direction: column;
    width: 100%;
    height: var(--modal-card-height);
    overflow: hidden;
    background: #fff;
    border-radius: 30px;
    box-shadow:
        0 34.5px 20.25px rgba(0, 0, 0, 0.01),
        0 15px 15px rgba(0, 0, 0, 0.01),
        0 3.75px 8.25px rgba(0, 0, 0, 0.01);
    clip-path: inset(0% round 30px);
}

.about-content {
    display: flex;
    flex: 1 1 0%;
    flex-direction: column;
    gap: var(--modal-content-gap);
    overflow-y: auto;
    padding: var(--modal-content-padding) max(20px, calc(50% - 175px));
}

.about-section {
    display: flex;
    flex-direction: column;
    gap: 21px;
}

.about-subsection {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.about-text {
    margin: 0;
    font-size: clamp(14px, 3.6vw, 15px);
    font-weight: 500;
    line-height: 22px;
}

.services {
    margin-top: 0;
    border-top: 1px solid rgb(239, 239, 239);
}

.service-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: clamp(38px, 11vw, 46px);
    border-bottom: 1px solid rgb(239, 239, 239);
}

.about-close {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 50px;
    padding: 0;
    border: 0.5px solid rgba(255, 255, 255, 0.65);
    border-radius: var(--radius-pill);
    background: rgba(242, 242, 242, 0.75);
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.07),
        inset 0 0.5px 0 rgba(255, 255, 255, 0.95);
    cursor: pointer;
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
}

.about-close svg {
    transform: rotate(45deg);
}

.preview-access {
    position: fixed;
    top: 30px;
    right: 30px;
    z-index: 101;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    padding: 0;
    border: 0.5px solid transparent;
    border-radius: var(--radius-pill);
    background: transparent;
    box-shadow: none;
    cursor: pointer;
    transition:
        background-color 400ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        border-color 400ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        box-shadow 400ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
}

.preview-access:hover,
.preview-access:focus-visible {
    outline: none;
    border-color: rgba(255, 255, 255, 0.65);
    background-color: rgba(255, 255, 255, 0.88);
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.1),
        inset 0 0.5px 0 rgb(255, 255, 255);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
}

.preview-access:active {
    transform: scale(0.96);
}

.preview-access:disabled {
    cursor: wait;
}

.preview-access svg {
    flex: 0 0 auto;
    stroke: var(--color-text-muted);
    stroke-width: 1.25;
    opacity: 0;
    transition: opacity 240ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.preview-access:hover svg,
.preview-access:focus-visible svg {
    opacity: 1;
}

@media (hover: none) {
    .preview-access {
        top: 30px;
        right: 26px;
        -webkit-backdrop-filter: none;
        backdrop-filter: none;
    }

    .preview-access:hover,
    .preview-access:focus-visible {
        border-color: transparent;
        background: transparent;
        box-shadow: none;
    }

    .preview-access svg,
    .preview-access:hover svg,
    .preview-access:focus-visible svg {
        opacity: 0;
    }
}

.preview-login-overlay {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: grid;
    place-items: center;
    padding: 26px;
    background: rgba(255, 255, 255, 0.76);
    -webkit-backdrop-filter: blur(24px);
    backdrop-filter: blur(24px);
}

.preview-login-card {
    position: relative;
    display: flex;
    flex-direction: column;
    width: min(100%, 320px);
    padding: 24px;
    border: 0.5px solid rgba(255, 255, 255, 0.7);
    border-radius: 32px;
    background: rgba(242, 242, 242, 0.78);
    box-shadow:
        0 20px 70px rgba(0, 0, 0, 0.09),
        inset 0 0.5px 0 rgba(255, 255, 255, 0.95);
    animation: preview-login-enter 320ms cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
}

.preview-login-close {
    position: absolute;
    top: 16px;
    right: 16px;
    display: grid;
    width: 32px;
    height: 32px;
    padding: 0 0 2px;
    place-items: center;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.48);
    color: var(--color-text-muted);
    cursor: pointer;
}

.preview-login-close:hover,
.preview-login-close:focus-visible {
    outline: none;
    background: rgba(255, 255, 255, 0.9);
    color: var(--color-text-primary);
}

.preview-login-title,
.preview-login-copy,
.preview-login-error,
.preview-pin-input,
.preview-key {
    font: inherit;
}

.preview-login-title {
    margin-bottom: 4px;
}

.preview-login-copy {
    color: var(--color-text-muted);
}

.preview-pin-input {
    width: 100%;
    height: 54px;
    margin: 22px 0 12px;
    padding: 0 18px;
    border: 0.5px solid rgba(255, 255, 255, 0.75);
    border-radius: var(--radius-pill);
    outline: 0;
    background: rgba(255, 255, 255, 0.88);
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.08),
        inset 0 0.5px 0 rgb(255, 255, 255);
    color: var(--color-text-primary);
    font-size: 18px;
    letter-spacing: 10px;
    text-align: center;
    text-indent: 10px;
    caret-color: transparent;
    -webkit-text-security: disc;
}

.preview-pin-input::placeholder {
    color: #c7c7c7;
    opacity: 1;
}

.preview-pin-input:focus-visible {
    outline: none;
}

.preview-pin-input[aria-invalid="true"] {
    color: #b42318;
}

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

.preview-key {
    height: 58px;
    padding: 0;
    border: 0.5px solid rgba(255, 255, 255, 0.68);
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.48);
    box-shadow: inset 0 0.5px 0 rgba(255, 255, 255, 0.9);
    color: var(--color-text-primary);
    cursor: pointer;
    transition:
        background-color 240ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        box-shadow 240ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        transform 140ms ease,
        opacity 180ms ease;
}

.preview-key:hover,
.preview-key:focus-visible {
    outline: none;
    background-color: rgba(255, 255, 255, 0.92);
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.1),
        inset 0 0.5px 0 rgb(255, 255, 255);
}

.preview-key:active {
    transform: scale(0.96);
}

.preview-key-action {
    color: var(--color-text-muted);
}

.preview-key-submit {
    background: rgba(255, 255, 255, 0.88);
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.08),
        inset 0 0.5px 0 rgb(255, 255, 255);
}

.preview-key:disabled {
    cursor: default;
    opacity: 0.32;
}

@keyframes preview-login-enter {
    from {
        opacity: 0;
        transform: translateY(8px) scale(0.98);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@media (prefers-reduced-motion: reduce) {
    .preview-login-card {
        animation: none;
    }

    .preview-access,
    .preview-key {
        transition: none;
    }
}

.project-main {
    min-height: 100dvh;
    padding-bottom: 80px;
}

.project-title-lockup {
    display: flex;
    width: min(360px, var(--project-image-width));
    flex-direction: column;
    align-items: center;
    gap: 2px;
    text-align: center;
}

.project-title,
.project-subtitle {
    margin: 0;
}

.project-title {
    color: var(--color-text-primary);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-medium);
    line-height: var(--line-height-base);
}

.project-subtitle {
    color: var(--color-text-secondary);
    font-size: 13px;
    font-weight: 400;
    line-height: 18px;
}

.project-section-nav {
    position: fixed;
    top: 50%;
    left: 30px;
    z-index: 90;
    width: min(200px, calc(50vw - var(--project-image-width) / 2 - 60px));
    padding: 1px;
    border: 0.5px solid rgba(255, 255, 255, 0.65);
    border-radius: 24px;
    background: rgba(242, 242, 242, 0.75);
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.07),
        inset 0 0.5px 0 rgba(255, 255, 255, 0.95);
    transform: translateY(-50%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
}

.project-section-nav-list {
    display: grid;
    max-height: calc(100dvh - 180px);
    gap: 2px;
    margin: 0;
    padding: 3px;
    overflow: auto;
    list-style: none;
}

.project-section-nav-link {
    display: block;
    min-width: 0;
    padding: 11px 15px;
    overflow: hidden;
    border-radius: var(--radius-pill);
    color: var(--color-text-muted);
    font-size: 13px;
    font-weight: 500;
    line-height: 18px;
    text-overflow: ellipsis;
    white-space: nowrap;
    transition:
        color 300ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        background-color 300ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        box-shadow 300ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.project-section-nav-link:hover,
.project-section-nav-link:focus-visible,
.project-section-nav-link.is-current {
    background-color: rgba(255, 255, 255, 0.88);
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.1),
        inset 0 0.5px 0 rgb(255, 255, 255);
    color: var(--color-text-primary);
}

.project-section-nav-link:focus-visible {
    outline: 2px solid var(--color-text-primary);
    outline-offset: 2px;
}

.project-section {
    --project-notation-target-width: var(--project-image-width);
    --project-notation-center-y: 50%;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding-right: 26px;
    padding-left: 26px;
    scroll-margin-top: 110px;
}

.project-section:first-of-type {
    padding-top: var(--project-padding-top);
}

.project-section + .project-section {
    margin-top: 12px;
}

.project-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    margin-top: 160px;
    padding: 0 26px 40px;
    color: var(--color-text-muted);
    font-size: 13px;
    font-weight: 400;
    line-height: 18px;
    text-align: center;
}

.project-footer p {
    margin: 0;
}

.project-media-frame {
    position: relative;
    width: var(--project-image-width);
    height: var(--project-image-height);
    overflow: hidden;
    background: transparent;
    border-radius: var(--radius-card);
}

.project-video-frame {
    height: auto;
    background: #111;
}

.project-image-frame img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    color: transparent;
}

.project-gallery-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: var(--project-image-width);
}

.project-gallery-item {
    width: 100%;
    height: auto;
    margin: 0;
    overflow: hidden;
    border-radius: var(--radius-card);
    background: transparent;
}

.project-gallery-item img {
    display: block;
    width: 100%;
    height: auto;
    color: transparent;
    user-select: none;
    -webkit-user-drag: none;
}

@media (min-width: 601px) {
    .project-gallery-grid {
        display: block;
        column-count: 2;
        column-gap: 12px;
    }

    .project-gallery-grid[data-gallery-size="1"] {
        column-count: 1;
    }

    .project-gallery-item {
        margin-bottom: 12px;
        break-inside: avoid;
    }
}

.project-video-frame video,
.project-embed-frame iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
}

.project-video-frame video {
    height: auto;
    object-fit: contain;
    cursor: pointer;
}

.project-video-controls {
    position: absolute;
    bottom: 18px;
    left: 50%;
    z-index: 2;
    display: flex;
    gap: 4px;
    padding: 4px;
    border: 0.5px solid rgba(255, 255, 255, 0.38);
    border-radius: var(--radius-pill);
    background: rgba(242, 242, 242, 0.66);
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.08),
        inset 0 0.5px 0 rgba(255, 255, 255, 0.8);
    opacity: 0;
    pointer-events: none;
    transform: translate(-50%, 8px) scale(0.98);
    transition:
        opacity 280ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        transform 280ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
}

.project-video-frame:hover .project-video-controls,
.project-video-frame.is-controls-visible .project-video-controls,
.project-video-controls:focus-within {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(-50%) scale(1);
}

.project-video-control {
    display: grid;
    width: 42px;
    height: 42px;
    padding: 0;
    place-items: center;
    border: 0;
    border-radius: var(--radius-pill);
    background: transparent;
    color: var(--color-text-muted);
    cursor: pointer;
    transition:
        color 240ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        background-color 240ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        box-shadow 240ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        transform 140ms ease;
}

.project-video-control:hover,
.project-video-control:focus-visible {
    outline: none;
    background: rgba(255, 255, 255, 0.88);
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.08),
        inset 0 0.5px 0 #fff;
    color: var(--color-text-primary);
}

.project-video-control:active {
    transform: scale(0.94);
}

.project-player-icon {
    pointer-events: none;
}

.project-embed-frame iframe {
    background: #fff;
}

.project-html-frame iframe {
    max-width: none;
    transform-origin: top left;
}

.project-block-notation {
    position: absolute;
    top: var(--project-notation-center-y);
    left: calc(50% + var(--project-notation-target-width) / 2 + 40px);
    width: min(16rem, calc(50vw - var(--project-notation-target-width) / 2 - 72px));
    margin: 0;
    color: #4a4a4a;
    font-family: "Bradley Hand", "Segoe Print", "Comic Sans MS", cursive;
    font-size: 22px;
    font-weight: 400;
    line-height: 0.98;
    letter-spacing: -0.01em;
    text-wrap: balance;
    transform: translateY(-50%) rotate(-1deg);
    user-select: none;
    pointer-events: none;
}

.project-notation-copy {
    margin: 0;
}

.project-notation-mark {
    position: absolute;
    top: 50%;
    right: calc(100% + 12px);
    width: 24px;
    height: 64px;
    overflow: visible;
    color: currentColor;
    transform: translateY(-50%);
}

.project-notation-mark path {
    fill: none;
    stroke: currentColor;
    stroke-width: 1.35;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
}

.project-has-notation.is-notation-visible .project-notation-mark path {
    animation: project-notation-draw 800ms ease-out forwards;
}

.project-has-notation.is-notation-visible .project-notation-mark path:nth-child(2) {
    animation-delay: 110ms;
}

.project-has-notation.is-notation-visible .project-notation-mark path:nth-child(3) {
    animation-delay: 510ms;
}

@keyframes project-notation-draw {
    to {
        stroke-dashoffset: 0;
    }
}

.project-text-card,
.project-empty-copy {
    width: var(--project-image-width);
    margin: 0;
    padding: clamp(24px, 7vw, 34px);
    border-radius: var(--radius-card);
    background: var(--color-card-bg);
}

.project-text-card {
    background: transparent;
}

.project-rich-text {
    font-weight: 400;
}

.project-rich-text > :first-child {
    margin-top: 0;
}

.project-rich-text > :last-child {
    margin-bottom: 0;
}

.project-rich-text p,
.project-rich-text blockquote,
.project-rich-text ul,
.project-rich-text ol,
.project-rich-text h2,
.project-rich-text h3,
.project-rich-text h4 {
    margin-top: 0;
    margin-bottom: 16px;
    font-size: var(--font-size-base);
    line-height: var(--line-height-base);
}

.project-rich-text h2,
.project-rich-text h3,
.project-rich-text h4,
.project-rich-text strong,
.project-rich-text b {
    font-weight: var(--font-weight-medium);
}

.project-rich-text ul,
.project-rich-text ol {
    padding-left: 20px;
}

.project-rich-text blockquote {
    margin-right: 0;
    margin-left: 0;
    padding-left: 16px;
    border-left: 1px solid var(--color-text-muted);
    color: var(--color-text-muted);
}

.project-rich-text a {
    color: inherit;
    text-decoration: underline;
}

.project-annotated-link {
    display: inline;
}

.project-annotated-link-target {
    position: relative;
    display: inline-block;
    max-width: 100%;
    padding: 0 2px;
    white-space: normal;
}

.project-annotated-link-target > a {
    position: relative;
    z-index: 1;
}

.project-annotated-link-target > a[href] {
    text-decoration: underline;
}

.project-annotated-link-target > a:not([href]) {
    cursor: default;
    text-decoration: none;
}

.project-link-circle {
    position: absolute;
    top: 50%;
    left: 50%;
    width: calc(100% + 10px);
    height: calc(100% + 12px);
    overflow: visible;
    color: #4a4a4a;
    pointer-events: none;
    transform: translate(-50%, -50%) rotate(-1deg);
}

.project-link-arrow {
    position: absolute;
    top: var(--project-link-arrow-top, 50%);
    left: var(--project-link-arrow-left, 50%);
    z-index: 2;
    width: var(--project-link-arrow-width, 44px);
    height: 34px;
    overflow: visible;
    color: #4a4a4a;
    pointer-events: none;
}

.project-link-circle path,
.project-link-arrow path {
    fill: none;
    stroke: currentColor;
    stroke-width: 1.35;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
}

.project-link-note {
    position: absolute;
    top: var(--project-link-note-top, 50%);
    left: var(
        --project-link-note-left,
        calc(50% + var(--project-notation-target-width) / 2 + 40px)
    );
    z-index: 2;
    width: min(16rem, calc(50vw - var(--project-notation-target-width) / 2 - 72px));
    color: #4a4a4a;
    font-family: "Bradley Hand", "Segoe Print", "Comic Sans MS", cursive;
    font-size: 22px;
    font-weight: 400;
    line-height: 0.98;
    letter-spacing: -0.01em;
    opacity: 0;
    pointer-events: none;
    text-wrap: balance;
    transform: translateY(-50%) rotate(-1deg);
}

.intro .project-link-note {
    left: var(--project-link-note-left, calc(50% + 220px));
    width: min(16rem, calc(50vw - 252px));
}

.reveal-target.is-visible .project-link-circle path,
.reveal-target.is-visible .project-link-arrow path {
    animation: project-notation-draw 800ms ease-out forwards;
}

.reveal-target.is-visible .project-link-arrow path:first-child {
    animation-delay: 420ms;
}

.reveal-target.is-visible .project-link-arrow path:nth-child(2) {
    animation-delay: 660ms;
}

.reveal-target.is-visible .project-link-note {
    opacity: 1;
    transition: opacity 300ms ease 620ms;
}

.project-rich-text pre {
    margin: 24px 0;
    padding: 22px 24px;
    overflow-x: auto;
    border-radius: var(--radius-card);
    background: var(--color-card-bg);
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
    font-size: 13px;
    font-weight: 400;
    line-height: 20px;
    tab-size: 4;
    white-space: pre;
}

.project-rich-text pre code {
    font: inherit;
    color: inherit;
}

.project-rich-text .token.comment,
.project-rich-text .token.prolog,
.project-rich-text .token.doctype,
.project-rich-text .token.cdata {
    color: #9a9a9a;
}

.project-rich-text .token.punctuation {
    color: #777;
}

.project-rich-text .token.tag,
.project-rich-text .token.keyword,
.project-rich-text .token.selector,
.project-rich-text .token.important {
    color: #766584;
}

.project-rich-text .token.attr-name,
.project-rich-text .token.property,
.project-rich-text .token.constant,
.project-rich-text .token.symbol {
    color: #886b50;
}

.project-rich-text .token.string,
.project-rich-text .token.char,
.project-rich-text .token.attr-value {
    color: #5e7968;
}

.project-rich-text .token.boolean,
.project-rich-text .token.number,
.project-rich-text .token.function,
.project-rich-text .token.class-name {
    color: #55738a;
}

.project-rich-text .token.operator,
.project-rich-text .token.entity,
.project-rich-text .token.url {
    color: #7d6262;
}

.photos-main {
    width: min(100%, 1600px);
    min-height: 100dvh;
    margin: 0 auto;
    padding: 190px 26px 80px;
}

.photos-intro {
    width: min(360px, 100%);
    margin: 0 auto;
}

.photos-intro-copy {
    margin: 0;
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-medium);
    line-height: var(--line-height-base);
    white-space: pre-line;
}

.photos-intro ~ .photo-album.is-first-visible {
    margin-top: var(--hero-section-gap);
}

.photo-filter-region {
    position: fixed;
    bottom: 30px;
    left: 50%;
    z-index: 100;
    display: flex;
    justify-content: center;
    width: max-content;
    max-width: calc(100vw - 52px);
    margin: 0;
    transform: translateX(-50%);
}

.photo-filters {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px;
    border: 0.5px solid rgba(255, 255, 255, 0.65);
    border-radius: var(--radius-pill);
    background: rgba(242, 242, 242, 0.75);
    box-shadow:
        0 4px 24px rgba(0, 0, 0, 0.07),
        inset 0 0.5px 0 rgba(255, 255, 255, 0.95);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
}

.photo-filter-control {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: var(--radius-pill);
    transition:
        background-color 250ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        box-shadow 250ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.photo-filter-control::after {
    content: "";
    position: absolute;
    top: 50%;
    right: 18px;
    width: 6px;
    height: 6px;
    border-right: 1.5px solid var(--color-text-muted);
    border-bottom: 1.5px solid var(--color-text-muted);
    pointer-events: none;
    transform: translateY(-65%) rotate(45deg);
}

.photo-filter-control:hover,
.photo-filter-control.is-active {
    background: rgba(255, 255, 255, 0.88);
    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.08),
        inset 0 0.5px 0 #fff;
}

.photo-filter-select,
.photo-filter-reset {
    height: 50px;
    border: 0;
    border-radius: var(--radius-pill);
    font: inherit;
}

.photo-filter-select {
    min-width: 148px;
    padding: 0 42px 0 18px;
    appearance: none;
    background: transparent;
    color: var(--color-text-primary);
    cursor: pointer;
}

.photo-filter-select-album {
    min-width: 190px;
    max-width: min(300px, 36vw);
}

.photo-filter-select:focus-visible,
.photo-filter-reset:focus-visible {
    outline: none;
}

.photo-filter-reset {
    padding: 0 18px;
    background: #fff;
    color: var(--color-text-muted);
    cursor: pointer;
}

.photo-filter-empty {
    margin: 80px 0 0;
    text-align: center;
}

.photo-album + .photo-album {
    margin-top: 120px;
}

.photo-album.is-first-visible {
    margin-top: 0;
}

.photo-album-title {
    margin: 0 0 22px;
    font-size: var(--font-size-base);
    font-weight: 400;
    line-height: var(--line-height-base);
    text-align: center;
}

.photo-album-link {
    position: relative;
    padding: 0;
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    cursor: copy;
}

.photo-album-link-label,
.photo-album-copy-feedback {
    display: block;
    transition: opacity 180ms ease;
}

.photo-album-link-label {
    opacity: 1;
}

.photo-album-copy-feedback {
    position: absolute;
    top: 0;
    left: 50%;
    opacity: 0;
    white-space: nowrap;
    pointer-events: none;
    transform: translateX(-50%);
}

.photo-album-link:hover .photo-album-link-label {
    opacity: 0.55;
}

.photo-album-link.is-copied .photo-album-link-label {
    opacity: 0;
}

.photo-album-link.is-copied .photo-album-copy-feedback {
    opacity: 1;
}

.photo-grid {
    column-count: 3;
    column-gap: 12px;
}

.photo-item {
    width: 100%;
    margin: 0 0 12px;
    overflow: hidden;
    break-inside: avoid;
    border-radius: var(--radius-card);
    background: transparent;
}

.photo-item img {
    width: 100%;
    height: auto;
    color: transparent;
    user-select: none;
    -webkit-user-drag: none;
}

.photos-message {
    display: flex;
    min-height: calc(100dvh - 270px);
    align-items: center;
    justify-content: center;
    color: var(--color-text-muted);
    text-align: center;
}

.photos-message p {
    margin: 0;
}

@media (max-width: 1023px) {
    .photo-grid {
        column-count: 2;
    }
}

@media (max-width: 1199px) {
    .project-section-nav {
        top: auto;
        bottom: 26px;
        left: 50%;
        width: min(560px, calc(100% - 52px));
        max-width: none;
        border-radius: var(--radius-pill);
        transform: translateX(-50%);
    }

    .project-section-nav-list {
        display: flex;
        max-height: none;
        overflow-x: auto;
        overflow-y: hidden;
    }

    .project-section-nav-item {
        flex: 0 0 auto;
    }
}

@media (max-width: 600px) {
    .project-section + .project-block-text,
    .project-block-text + .project-section {
        margin-top: 24px;
    }

    .photos-main {
        padding-top: 140px;
    }

    .photo-album + .photo-album {
        margin-top: 84px;
    }

    .photos-intro ~ .photo-album.is-first-visible {
        margin-top: 140px;
    }

    .photo-filter-region {
        bottom: 26px;
        width: calc(100% - 52px);
        max-width: none;
    }

    .photo-filters {
        display: grid;
        width: 100%;
        grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr) auto;
        border-radius: var(--radius-pill);
    }

    .photo-filter-select,
    .photo-filter-select-album {
        min-width: 0;
        width: 100%;
        max-width: none;
        padding-right: 32px;
        padding-left: 14px;
        font-size: 13px;
    }

    .photo-filter-control::after {
        right: 14px;
    }

    .photo-filter-reset {
        width: 50px;
        padding: 0;
        overflow: hidden;
        font-size: 0;
    }

    .photo-filter-reset::after {
        content: "×";
        font-size: 18px;
        font-weight: 400;
    }

    .photo-grid {
        column-count: 1;
    }

    .photo-item {
        border-radius: 22px;
    }
}

@media (min-width: 1024px) {
    :root {
        --project-image-width: clamp(560px, 54vw, 760px);
        --project-image-height: clamp(613px, 59.14vw, 832px);
    }

    .project-text-card {
        width: clamp(420px, 38vw, 520px);
    }

    .project-block-text {
        --project-notation-target-width: clamp(420px, 38vw, 520px);
    }

    .project-section + .project-block-text,
    .project-block-text + .project-section,
    .project-section + .project-block-video,
    .project-block-video + .project-section {
        margin-top: 72px;
    }
}

@media (max-width: 1080px) {
    .project-block-notation {
        position: relative;
        top: auto;
        left: auto;
        width: var(--project-notation-target-width);
        margin: 30px auto 14px;
        padding-top: 18px;
        text-align: center;
        transform: rotate(-1deg);
    }

    .project-notation-mark {
        top: -25px;
        right: auto;
        left: 50%;
        width: 24px;
        height: 64px;
        transform: translateX(-50%) rotate(90deg);
    }

    .project-annotated-link {
        display: inline-grid;
        max-width: 100%;
        grid-template-columns: auto 44px minmax(0, 1fr);
        align-items: center;
        column-gap: 8px;
        margin: 5px 0;
        vertical-align: middle;
    }

    .project-link-arrow {
        position: static;
        width: 44px;
        height: 24px;
    }

    .project-link-note {
        position: static;
        min-width: 0;
        width: auto;
        font-size: 19px;
        transform: rotate(-1deg);
    }

    .intro .project-link-note {
        left: auto;
        width: auto;
    }
}

.reveal-target {
    opacity: 0;
    transform: translateY(10px);
    transition:
        opacity 650ms cubic-bezier(0.25, 0.46, 0.45, 0.94),
        transform 650ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
    transition-delay: var(--reveal-delay, 0ms);
    will-change: opacity, transform;
}

.reveal-target.is-visible {
    opacity: 1;
    transform: translateY(0);
    will-change: auto;
}

@media (prefers-reduced-motion: reduce) {
    *,
    ::before,
    ::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }

    .page-loader-dot {
        opacity: 0.55;
        animation: none;
    }
}
