:root {
    --grey: #979797;
    --black: #000000;
    --white: #ffffff;

    --font-size-small: 0.9rem;
    --font-size-medium: 1rem;
    --font-size-medium-large: 1.5rem;
    --font-size-h1: 6rem;
    --font-size--p1: clamp(1.25rem, 2.2vw, 1.75rem);

    --font-main: "Figtree", sans-serif;
    --font-second: "tt-commons-pro", sans-serif;

    --site-margin: 3%;
    --grid-gap: 1.5rem;
    --section-margin: 4rem;

    --slide-width: 550px;
    --slide-width-active: 850px;
    --slide-height: 44vh;
    --slide-height-active: 65vh;

    --nav-height: 60px;
    --carousel-pin-top: 60px;
    /* --index-bottom-inset: 4rem; */
    --index-bottom-inset:var(--site-margin);
    --carousel-index-gap: 1rem;
    --carousel-height-scale: 0.88;
    --footer-divider-gap: 1.25rem;

    --logo-min-width: 110px;
    --logo-min-top: 45px;
    --logo-expanded-width: calc(100vw - (var(--site-margin) * 2));
    --logo-nav-transition-duration: 0.9s;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-main);
    background-color: var(--white);
    color: var(--black);
    overflow-x: hidden;
}

#smooth-wrapper {
    position: relative;
    top: auto;
    left: auto;
    width: 100%;
    height: auto;
    overflow: visible;
}

body.is-subpage #smooth-wrapper {
    position: relative;
    top: auto;
    left: auto;
    width: 100%;
    height: auto;
    overflow: visible;
}

body.is-index {
    overscroll-behavior-y: none;
}

body.is-index #smooth-content,
body.is-subpage #smooth-content {
    min-height: calc(100dvh - var(--nav-height));
}

#smooth-content {
    width: 100%;
    position: relative;
    overflow: visible;
}

.smooth-scroll-tail {
    width: 100%;
    height: clamp(20rem, 68vh, 42rem);
    flex-shrink: 0;
    pointer-events: none;
}

.section-divider {
    background-color: var(--grey);
    grid-column: viewport-start / viewport-end;
    border: none;
    height: 1px;
    width: 100%;
    margin-top: 1rem;
    margin-bottom: 1rem;
}

.section-divider-footer {
    background-color: var(--grey);
    grid-column: viewport-start / viewport-end;
    border: none;
    height: 1px;
    width: 100%;
}

/* ==================== HEADER NAV ==================== */
.header-nav {
    position: fixed;
    top: 0;
    left: 0;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    width: 100%;
    height: var(--nav-height);
    padding: 0 var(--site-margin);
    z-index: 200;
    background-color: var(--white);
}

.header-nav ul,
.header-nav .nav-links {
    font-size: var(--font-size-small);
    font-family: var(--font-main);
    font-weight: 300;
    color: var(--grey);
    display: flex;
    gap: clamp(2rem, 7vw, 4.25rem);
    list-style: none;
}

.header-nav ul li a,
.header-nav .nav-links a {
    text-decoration: none;
    color: var(--grey);
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.header-nav .nav-links a.current-page {
    color: var(--black);
    text-shadow: 0.025ex 0 var(--black), -0.025ex 0 var(--black);
}

.header-nav ul li a:hover,
.header-nav .nav-links a:hover {
    color: var(--black);
    text-shadow: 0.025ex 0 var(--black), -0.025ex 0 var(--black);
}

/* Mobile menu elements live in the persistent header; hidden by default,
   revealed only by the index page's mobile styles. */
.mobile-menu-toggle,
.mobile-nav {
    display: none;
}

.transition-fade,
.swup-transition-main {
    opacity: 1;
}

html.is-changing .transition-fade,
html.is-changing .swup-transition-main {
    transition: opacity var(--swup-fade-theme-duration, 0.4s) ease-in-out;
    opacity: 1;
}

html.is-animating.is-leaving .transition-fade,
html.is-animating.is-leaving .swup-transition-main,
html.is-animating:not(.is-rendering) .transition-fade,
html.is-animating:not(.is-rendering) .swup-transition-main {
    opacity: 0;
}

/* ==================== LOGO ==================== */
.logo-container {
    position: fixed;
    left: var(--site-margin);
    transform: translateY(-50%);
    transform-origin: left center;
    pointer-events: none;
    z-index: 201;
}

body.is-subpage .logo-container {
    top: var(--logo-min-top);
    width: var(--logo-min-width);
    pointer-events: auto;
    transition: width var(--logo-nav-transition-duration) cubic-bezier(0.25, 1, 0.5, 1),
                top var(--logo-nav-transition-duration) cubic-bezier(0.25, 1, 0.5, 1);
}

body.logo-expand-pending .logo-container {
    top: var(--logo-min-top);
    width: var(--logo-min-width);
    max-width: none;
    transition: none;
}

.logo-svg {
    width: 100%;
    height: auto;
    display: block;
}

.logo-svg polygon,
.logo-container .logo-svg polygon {
    fill: var(--black);
}

/* Index home: logo starts expanded, scroll JS scrubs size/position */
body.is-index .logo-container {
    top: 50vh;
    width: var(--logo-expanded-width);
    max-width: none;
    transition: none;
}

body.is-index.logo-expand-pending .logo-container {
    top: var(--logo-min-top);
    width: var(--logo-min-width);
    max-width: none;
    transition: none;
}

body.is-index .logo-container.is-minimizing,
body.is-index .logo-container.is-expanding,
body.logo-expand-pending .logo-container.is-expanding {
    transition: width var(--logo-nav-transition-duration) cubic-bezier(0.25, 1, 0.5, 1),
                top var(--logo-nav-transition-duration) cubic-bezier(0.25, 1, 0.5, 1);
}

html.logo-enter-pending body.is-index .logo-container {
    top: var(--logo-min-top);
    width: var(--logo-min-width);
}

body.is-index .logo-container a,
body.is-subpage .logo-container a {
    display: block;
    pointer-events: auto;
}

/* Contact & Footer — logo pinned to bottom of footer block */



.contact-section {
    flex-shrink: 0;
}

.contact-section .section-divider {
    display: block;
    width: 100%;
    margin: 0;
}

.footer-scroll-stage {
    width: 100%;
    padding: 0 var(--site-margin);
    padding-bottom: calc((100vw - (var(--site-margin) * 2)) * 0.1874 + 1.5rem);
    box-sizing: border-box;
}

.footer {
    display: flex;
    flex-direction: column;
    width: 100%;
    padding: clamp(1.5rem, 4vh, 2.5rem) 0 0;
    box-sizing: border-box;
}

.contact {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    column-gap: var(--grid-gap);
    padding: clamp(2rem, 6vh, 4rem) var(--site-margin) 0;
    margin-bottom: 1rem;
    align-items: start;
}

.contact-content {
    grid-column: 1 / span 7;
    grid-row: 1;
    font-family: var(--font-main);
    font-size: var(--font-size--p1);
    font-weight: 350;
    line-height: 1.45;
    margin: 0;
    color: var(--grey);
}

.contact-link {
    grid-column: 9 / span 4;
    grid-row: 1;
    justify-self: end;
}

.contact-link a {
    font-family: var(--font-main);
    font-size: var(--font-size--p1);
    font-weight: 350;
    color: var(--grey);
    text-decoration: none;
    white-space: nowrap;
}

.contact-link a:hover {
    color: var(--black);
}



.footer-logo-spacer {
    display: none;
}

.footer-logo-area {
    position: absolute;
    left: var(--site-margin);
    bottom: 0;
    width: var(--logo-expanded-width);
    max-width: none;
    pointer-events: none;
}

.footer-logo {
    width: 100%;
    pointer-events: auto;
}

.footer-top-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-template-rows: auto auto;
    column-gap: var(--grid-gap);
    row-gap: 0.35rem;
    width: 100%;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.footer-hdr {
    grid-row: 1;
    font-family: var(--font-main);
    font-size: var(--font-size-small);
    font-weight: 400;
    color: var(--black);
    margin: 0;
}

.name-hdr    { grid-column: 1 / span 3; }
.nav-hdr     { grid-column: 4 / span 2; }
.contact-hdr { grid-column: 6 / span 3; }

.back-to-top {
    grid-column: 11 / span 2;
    grid-row: 1;
    justify-self: end;
    font-family: var(--font-main);
    font-size: var(--font-size-small);
    color: var(--black);
    text-decoration: none;
}

.footer-list {
    grid-row: 2;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin-bottom: 0;
}

.nav-list     { grid-column: 4 / span 2; }
.contact-list { grid-column: 6 / span 3; }

.footer-list a {
    font-family: var(--font-main);
    font-size: var(--font-size-small);
    color: var(--grey);
    text-decoration: none;
}
.footer-list a:hover {
    color: var(--black);
}

.skills-pill-row {
    /* Starts on Column 1 (Line 2) and spans cleanly to the end of Column 11 (Line 13) */
    grid-column: 3 / 12;
    display: flex;
    justify-content: space-between; /* Distributes them perfectly across the 11 columns */
    align-items: center;
    margin-bottom: var(--section-margin);
}

.skills-pill-row-2 {
    /* Starts on Column 1 (Line 2) and spans cleanly to the end of Column 11 (Line 13) */
    grid-column: 4 / 11;
    display: flex;
    justify-content: space-between; /* Distributes them perfectly across the 11 columns */
    align-items: center;
    margin-bottom: var(--section-margin);
}

.skill-pill {
    display: block; 
    width: auto 1rem;  
    
    /* Perfect Pill Shape */
    border-radius: 100px; 
    
    /* Typography & Core Styling */
    font-family: var(--font-main);
    font-size: var(--font-size-medium-large);
    font-weight: 500;
    color: var(--black, #000000);
    border: 1px solid #979797;
    text-decoration: none;
    
    /* This creates the inner breathing room around your text variables */
    padding: 0.75rem 3rem; 
    
    /* Visual Tints matching Screenshot 2026-06-27 at 4.00.58 PM.png */
    background-color: #FDFBFB; 
    white-space: nowrap; 
}

.skill-pill a{
    text-decoration: none;
    color: var(--black);
}

.custom-cursor {
    width: 40px;
    height: 40px;
    background-color: #fff;
    border-radius: 50%;
    position: fixed;
    top: 0;
    left: 0;
    pointer-events: none;
    mix-blend-mode: difference;
    z-index: 10000;
    visibility: hidden;
    transform: translate(-50%, -50%);
}

@media (pointer: fine) {
    body.has-custom-cursor,
    body.has-custom-cursor a,
    body.has-custom-cursor button,
    body.has-custom-cursor .project-list-nav li {
        cursor: none;
    }
}

/* project-footer */

.site-footer--project {
    width: 100%;
    padding: 0;
    box-sizing: border-box;
}

/* --- FOOTER TOP SECTION: 12-COLUMN SEAMLESS ALIGNMENT --- */
.site-footer--project .footer-top {
    display: grid;
    /* Replicating your exact layout rules */
    grid-template-columns: [viewport-start] var(--site-margin) repeat(12, 1fr) var(--site-margin) [viewport-end];
    column-gap: var(--grid-gap, 1.5rem);
    align-items: start;
}

/* Left Image Box: Spans across the first 5 columns of the grid */
.site-footer--project .footer-preview-wrapper {
    grid-column: viewport-start/ 8 ; /* Skips track 1 (the margin) and spans 5 columns */
    width: 100%;
    aspect-ratio: 18 / 9; /* Maintains standard presentation aspect ratio */
    overflow: hidden;
}

.site-footer--project .footer-preview-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Right Content Area: spans columns 7–12 */
.site-footer--project .footer-nav-group {
    grid-column: 8 / 14;
    display: grid;
    grid-template-columns: subgrid;
}

.site-footer--project .footer-heading {
    grid-column: 1 / -1;
    font-family: var(--font-main);
    font-size: var(--font-size-medium-large);
    font-weight: 500;
    margin: 0.5rem 0 9rem 1rem;
    color: #000;
}

/* Inner columns snap to the same 12-column grid as the nav row */
.site-footer--project .footer-columns-inner {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: subgrid;
}

.site-footer--project .footer-col:nth-child(1) {
    grid-column: 1 / 3;
}

.site-footer--project .footer-col:nth-child(2) {
    grid-column: 3 / 5;
}

.site-footer--project .footer-col:nth-child(3) {
    grid-column: 6 / 7;
}

/* Typography & List Resets */
.site-footer--project .footer-col h3 {
    font-family: var(--font-main);
    font-size: var(--font-size-medium);
    font-weight: 500;
    letter-spacing: 0.05em;
    margin: 0 0 1.5rem 1rem;
    color: #000;
}

.site-footer--project .footer-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.site-footer--project .footer-col li {
    margin: 0 0 0.25rem 1rem;
}

.site-footer--project .footer-col:nth-child(3) h3,
.site-footer--project .footer-col:nth-child(3) li {
    margin-left: 0;
}

.site-footer--project .footer-col a {
    text-decoration: none;
    color: #888;
    font-family: var(--font-main);
    font-size: var(--font-size-small);
    font-weight: 300;
    transition: color 0.2s ease;
}

.site-footer--project .footer-col a:hover,
.site-footer--project .footer-col a.active-project {
    color: #000;
    font-weight: 500;
}

.site-footer--project .footer-col a.active-project {
    text-decoration: underline;
    text-underline-offset: 4px;
    font-weight: 500;
}

.project-footer-logo-area {
    margin: 4.5rem var(--site-margin) var(--site-margin) var(--site-margin) ;
}

.project-footer-nav-row {
    display: grid;
    grid-template-columns: [viewport-start] var(--site-margin) repeat(12, 1fr) var(--site-margin) [viewport-end];
    column-gap: var(--grid-gap, 1.5rem);
    align-items: center;
    width: 100%;
}

.project-footer-nav {
    grid-column: 8 / 14;
    display: flex;
    justify-content: space-between;
    align-items: center;
    list-style: none;
    margin: 1rem 0 0 1rem;
    padding: 0;
}

.project-footer-nav li {
    margin: 0;
    font-weight: 500;
}

.project-footer-nav a {
    font-family: var(--font-main);
    font-size: var(--font-size-small);
    font-weight: 300;
    color: var(--grey);
    text-decoration: none;
}

.project-footer-nav a:hover{
    font-weight: 500;
    color: var(--black);
}

.project-footer-nav a.current-page {
    text-decoration: underline;
    text-underline-offset: 0.2em;
    font-weight: 500;
    color: var(--black);
}

/* ==================== INDEX MOBILE BREAKPOINT ==================== */
/* Scoped to body.is-index so subpages keep their current behavior. */
@media (max-width: 900px) {
    /* Nav: collapse links into a "Menu" toggle (per Figma).
       Applies to any header that opts in with .has-mobile-menu. */
    .header-nav.has-mobile-menu .nav-links {
        display: none;
    }

    .header-nav.has-mobile-menu .mobile-menu-toggle {
        display: block;
        appearance: none;
        background: none;
        border: 0;
        padding: 0;
        font-family: var(--font-main);
        font-size: var(--font-size-medium);
        font-weight: 300;
        color: var(--grey);
        cursor: pointer;
        transition: color 0.3s ease;
    }

    .header-nav.has-mobile-menu .mobile-menu-toggle:hover,
    .header-nav.has-mobile-menu .mobile-menu-toggle[aria-expanded="true"] {
        color: var(--grey);
    }

    .header-nav.has-mobile-menu:has(.mobile-menu-toggle[aria-expanded="true"]) {
        z-index: 202;
    }

    .header-nav.has-mobile-menu:has(.mobile-menu-toggle[aria-expanded="true"]) .logo-container {
        visibility: hidden;
        pointer-events: none;
    }

    .header-nav.has-mobile-menu ~ .mobile-nav:not([hidden]) {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        height: 100dvh;
        overflow-y: auto;
        z-index: 201;
        background-color: var(--white);
        padding: var(--nav-height) 0 0;
    }

    .mobile-nav ul {
        list-style: none;
        display: flex;
        flex-direction: column;
        gap: 0.85rem;
        margin: 0;
        flex-shrink: 0;
        padding: 0;
    }

    .mobile-nav li {
        border-bottom: 1px solid var(--grey);
        padding: 0.75rem var(--site-margin) 0; }

    .mobile-nav > ul a {
        font-family: var(--font-main);
        font-size: clamp(2.25rem, 10vw, 2.5rem);
        font-weight: 400;
        color: var(--black);
        text-decoration: none;
    }

    .mobile-nav ul a{
        line-height: 2;
    }

    .mobile-nav-footer {
        flex-shrink: 0;
        margin-top: auto;
        padding: 0 var(--site-margin) 1.5rem;
    }

    .mobile-nav-footer-links {
        display: flex;
        flex-wrap: wrap;
        gap: 1.5rem;
        margin-bottom: clamp(2rem, 8vh, 4rem);
    }

    .mobile-nav-footer-links a {
        font-family: var(--font-main);
        font-size: var(--font-size-medium);
        font-weight: 400;
        color: var(--black);
        text-decoration: none;
    }

    .mobile-nav-footer-logo {
        width: 100%;
    }

    .mobile-nav-footer-logo .logo-svg {
        display: block;
        width: 100%;
        height: auto;
    }

    /* Fixed scrubbing hero logo is desktop-only; mobile uses the in-flow logo */
    body.is-index .logo-container {
        display: none;
    }

    /* Contact: single stacked column, black 24px type (per Figma) */
    body.is-index .contact {
        display: block;
        padding: clamp(2rem, 6vh, 4rem) var(--site-margin) 0;
    }

    body.is-index .contact-content {
        font-size: clamp(1.25rem, 6vw, 1.5rem);
        color: var(--black);
        font-weight: 400;
    }

    body.is-index .contact-link {
        margin-top: clamp(3rem, 12vh, 6rem);
    }

    body.is-index .contact-link a {
        font-size: clamp(1.25rem, 6vw, 1.5rem);
        color: var(--black);
        font-weight: 400;
    }

    /* Footer: only the social links row above the big logo (per Figma) */
    body.is-index .site-footer-wrapper,
    body.is-about-page .site-footer-wrapper {
        min-height: 0;
    }

    body.is-index .footer,
    body.is-about-page .footer {
        padding-top: clamp(3rem, 14vh, 7rem);
    }

    body.is-index .footer-top-grid,
    body.is-about-page .footer-top-grid {
        display: flex;
    }

    body.is-index .name-hdr,
    body.is-index .nav-hdr,
    body.is-index .contact-hdr,
    body.is-index .back-to-top,
    body.is-index .nav-list,
    body.is-about-page .name-hdr,
    body.is-about-page .nav-hdr,
    body.is-about-page .contact-hdr,
    body.is-about-page .back-to-top,
    body.is-about-page .nav-list {
        display: none;
    }

    body.is-index .contact-list,
    body.is-about-page .contact-list {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 1.5rem;
    }

    body.is-index .contact-list a,
    body.is-about-page .contact-list a {
        font-size: var(--font-size-medium);
        color: var(--black);
    }

    /* Project-page footer: social links row + big logo only (per Figma) */
    body.is-subpage .section-divider-footer {
        display: none;
    }

    .site-footer--project .footer-top {
        display: block;
        padding: 0 var(--site-margin);
    }

    .site-footer--project .footer-preview-wrapper,
    .site-footer--project .footer-heading,
    .site-footer--project .footer-col:nth-child(1),
    .site-footer--project .footer-col:nth-child(2),
    .site-footer--project .footer-col:nth-child(3) h3,
    .project-footer-nav-row {
        display: none;
    }

    .site-footer--project .footer-nav-group,
    .site-footer--project .footer-columns-inner {
        display: block;
    }

    .site-footer--project .footer-col:nth-child(3) ul {
        display: flex;
        flex-wrap: wrap;
        gap: 1.5rem;
        margin-top: clamp(3rem, 10vh, 5rem);
    }

    .site-footer--project .footer-col:nth-child(3) li {
        margin: 0;
    }

    .site-footer--project .footer-col:nth-child(3) a {
        font-size: var(--font-size-medium);
        font-weight: 400;
        color: var(--black);
    }

    .project-footer-logo-area {
        margin: 2.5rem var(--site-margin) var(--site-margin);
    }
}

@media (hover: hover) and (pointer: fine) {
    .custom-cursor {
        width: 40px;
        height: 40px;
        background-color: #fff;
        border-radius: 50%;
        position: fixed;
        top: 0;
        left: 0;
        pointer-events: none;
        mix-blend-mode: difference;
        z-index: 10000;
        visibility: hidden;
        transform: translate(-50%, -50%);
    }
}

@media (hover: none) or (pointer: coarse) {
    .custom-cursor {
        display: none !important;
    }
}

