/* --- GLOBAL RESET --- */
    ::selection { background: #141414; color: #EAEAEA; }
    ::-moz-selection { background: #141414; color: #EAEAEA; }
    * { -webkit-tap-highlight-color: transparent; box-sizing: border-box; }

    body {
        margin: 0;
        padding: 0;
        background: #ffffff;
        font-family: 'Google Sans Flex', sans-serif;
        -webkit-font-smoothing: antialiased;
        color: #111;
        overflow-x: hidden;
    }
    
    img { display: block; max-width: 100%; height: auto; }

    img[src*=".jpg"],
    img[src*=".jpeg"],
    img[src*=".png"],
    img[src*=".webp"],
    img[src*=".avif"] {
        border-radius: 5px !important;
    }

    /* Header Container Placeholder */
    #header-container { width: 100%; position: relative; z-index: 999; }

    /* --- PROJECT DETAIL SPECIFIC STYLES --- */
    
    .page-project-detail {
        width: 100%;
        padding: 8rem clamp(1.5rem, 3.6vw, 2.75rem) 6rem;
        max-width: calc(1700px + (2 * clamp(1.5rem, 3.6vw, 2.75rem)));
        margin: 0 auto;
    }

    @media (min-width: 769px) and (max-width: 1024px) {
        .page-project-detail {
            padding-left: 1.7rem;
            padding-right: 1.7rem;
        }
    }

        /* --- TITLE SECTION --- */
    .work-page-header {
        padding-top: clamp(1rem, 2.2vw, 1.6rem);
    }

    .work-page-title {
        margin: 0;
        font-family: 'Nebulica', sans-serif;
        font-weight: 500;
        font-size: clamp(2.8rem, 6.8vw, 5.8rem);
        line-height: 0.9;
        letter-spacing: -0.03em;
        text-transform: capitalize;
        color: #111;
    }

    .work-page-title--reveal {
        max-width: max-content;
    }

    .work-page-title__stack {
        display: grid;
        grid-template-areas: "title";
        position: relative;
        max-width: 100%;
    }

    .work-page-title__layer {
        grid-area: title;
        display: block;
        opacity: 1;
        pointer-events: none;
        transform: translateZ(0);
    }

    .work-page-title__word {
        display: inline-block;
        opacity: 1;
        overflow: hidden;
        vertical-align: baseline;
        transform: translate3d(0, 1.05em, 0);
        transform-origin: 50% 100%;
        clip-path: inset(0 0 100% 0);
        animation: workTitleWordReveal 720ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
        animation-delay: var(--work-title-word-delay, 0ms);
        will-change: transform, clip-path;
    }

    .work-page-title__word + .work-page-title__word {
        margin-left: 0.16em;
    }

    .work-page-title__stack.is-intro-complete .work-page-title__word {
        animation: none;
        overflow: hidden;
        transform: translate3d(0, 0, 0);
        clip-path: inset(0 0 0 0);
        will-change: auto;
    }

    @keyframes workTitleWordReveal {
        0% {
            transform: translate3d(0, 1.05em, 0);
            clip-path: inset(0 0 100% 0);
        }

        100% {
            transform: translate3d(0, 0, 0);
            clip-path: inset(0 0 0 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: 0;
    }

    @media (prefers-reduced-motion: reduce) {
        .work-page-title__word {
            animation: none;
            transform: none;
            clip-path: inset(0 0 0 0);
        }
    }

    .work-page-subtitle {
        margin: 0.4rem 0 0;
        max-width: 44rem;
        font-family: 'Google Sans Flex', sans-serif;
        font-weight: 500;
        font-size: 1rem;
        line-height: 1;
        letter-spacing: -0.01em;
        color: #999;
    }

    .work-page-subtitle em {
        font-family: inherit;
        font-style: normal;
        font-weight: inherit;
        color: inherit;
    }

    /* --- META GRID (UPDATED) --- */
    .meta-separator {
        width: 100%;
        height: 1px;
        background-color: #000;
        margin-top: 1.1rem;
        margin-bottom: 1rem;
    }

    .meta-grid {
        display: grid;
        /* UPDATED: Auto sizing keeps columns close to their content width */
        grid-template-columns: auto auto auto auto; 
        /* UPDATED: Aligns the whole block to the left */
        justify-content: start;
        /* UPDATED: Gap between columns is now 4rem (adjustable) */
        gap: 2rem 8rem; 
        margin-bottom: 2rem;
        width: 100%;
    }

    .meta-column {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
    }

    .meta-column:nth-child(1) { --meta-delay: 0.08s; }
    .meta-column:nth-child(2) { --meta-delay: 0.16s; }
    .meta-column:nth-child(3) { --meta-delay: 0.24s; }
    .meta-column:nth-child(4) { --meta-delay: 0.32s; }

    /* UPDATED: Same small size and weight for label and value */
    .meta-label {
        font-family: 'Google Sans Flex', sans-serif;
        font-weight: 600; 
        font-size: 1rem; /* Smaller font */
        color: #999; 
        text-transform: capitalize;
    }

    .meta-value {
        font-family: 'Google Sans Flex', sans-serif;
        font-weight: 600; /* Regular weight, same as label */
        font-size: 1rem; /* Same size as label */
        color: #111;
    }

    .meta-list {
        display: flex;
        flex-direction: column;
    }

    .meta-label,
    .meta-value,
    .meta-list span {
        filter: blur(10px);
        opacity: 0;
        transform: translateY(8px);
        animation: metaWordReveal 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
        animation-delay: var(--meta-delay, 0s);
        will-change: filter, opacity, transform;
    }

    .meta-list span:nth-child(2) {
        animation-delay: calc(var(--meta-delay, 0s) + 0.08s);
    }

    .meta-list span:nth-child(3) {
        animation-delay: calc(var(--meta-delay, 0s) + 0.16s);
    }

    @keyframes metaWordReveal {
        from {
            filter: blur(10px);
            opacity: 0;
            transform: translateY(8px);
        }
        to {
            filter: blur(0);
            opacity: 1;
            transform: translateY(0);
        }
    }

    /* --- HERO IMAGE --- */
    .project-hero-media {
        width: 100%;
        height: auto;
        border-radius: 0; 
        overflow: hidden;
        margin-bottom: 4rem;
    }
    
    .project-hero-media img {
        width: 100%;
        height: auto;
        object-fit: cover;
    }

    .project-hero-media--extra {
        margin-top: 4rem;
        margin-bottom: 0;
    }

    .rubrum-gallery {
        width: 100%;
    }

    .rubrum-gallery img {
        width: 100%;
        height: auto;
        display: block;
        object-fit: cover;
    }

    .rubrum-gallery img + img {
        margin-top: 1rem;
    }

    /* --- STORY SECTOR --- */
    .project-story-section {
        padding: 2rem 0 1rem;
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .story-heading {
        margin: 0 auto;
        max-width: 18ch;
        font-family: 'Google Sans Flex', sans-serif;
        font-weight: 600;
        font-size: clamp(2.7rem, 7vw, 5.2rem);
        line-height: 0.95;
        letter-spacing: -0.05em;
        color: #111;
    }

    .story-readmore-btn {
        --press-stroke: 0.8px;
        margin-top: 2.4rem;
        width: 5rem;
        height: 5rem;
        border-radius: 999px;
        border: 1px solid transparent;
        background-color: #f3f3f3;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 0;
        padding: 0;
        cursor: pointer;
        position: relative;
        overflow: hidden;
        transition: width 0.35s ease, padding 0.35s ease, background-color 0.35s ease, gap 0.18s ease, transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
    }

    .story-readmore-btn::before {
        content: '';
        position: absolute;
        inset: 0;
        border-radius: inherit;
        z-index: 1;
        pointer-events: none;
        padding: var(--press-stroke);
        opacity: 0;
        background: linear-gradient(115deg, rgba(193, 210, 236, 0.7) 0%, rgba(255, 255, 255, 1) 42%, rgba(206, 224, 250, 0.95) 63%, rgba(255, 255, 255, 0.72) 100%);
        background-size: 280% 100%;
        background-position: -130% 50%;
        filter: drop-shadow(0 0 3px rgba(246, 250, 255, 0.95)) drop-shadow(0 0 8px rgba(188, 216, 255, 0.45));
        -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
        -webkit-mask-composite: xor;
        mask-composite: exclude;
    }

    .story-readmore-btn::after {
        content: '';
        position: absolute;
        inset: 0;
        border-radius: inherit;
        z-index: 1;
        pointer-events: none;
        background: linear-gradient(145deg, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0.08));
        opacity: 0;
        transition: opacity 0.18s ease;
    }

    .story-readmore-btn:focus-visible {
        outline: 2px solid #111;
        outline-offset: 4px;
    }

    .story-readmore-label {
        font-family: 'Google Sans Flex', sans-serif;
        font-weight: 700;
        font-size: 1.28rem;
        line-height: 1;
        white-space: nowrap;
        max-width: 0;
        opacity: 0;
        overflow: hidden;
        margin-right: 0;
        transform: translateX(8px);
        position: relative;
        z-index: 2;
        transition: max-width 0.35s ease, opacity 0.25s ease, transform 0.35s ease, margin-right 0.18s ease;
    }

    .story-readmore-icon {
        position: relative;
        width: 1.25rem;
        height: 1.25rem;
        flex-shrink: 0;
        z-index: 2;
        transition: transform 0.18s ease;
    }

    .story-readmore-icon::before,
    .story-readmore-icon::after {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        background-color: #111;
        border-radius: 2px;
        transform: translate(-50%, -50%);
    }

    .story-readmore-icon::before { width: 100%; height: 2px; }
    .story-readmore-icon::after { width: 2px; height: 100%; }

    .story-readmore-btn.is-pressing {
        gap: 0.75rem;
        transform: translateY(0);
        background: rgba(255, 255, 255, 0.22);
        border-color: rgba(236, 244, 255, 0.6);
        -webkit-backdrop-filter: blur(12px) saturate(165%);
        backdrop-filter: blur(12px) saturate(165%);
    }

    .story-readmore-btn.is-pressing::before {
        opacity: 1;
        animation: pressStrokeSweep 220ms ease-out forwards;
    }

    .story-readmore-btn.is-pressing::after {
        opacity: 1;
    }

    .story-readmore-btn.is-pressing .story-readmore-label {
        margin-right: 0.32rem;
    }

    .story-readmore-btn.is-pressing .story-readmore-icon {
        transform: translateX(0.22rem);
    }

    @keyframes pressStrokeSweep {
        0% {
            background-position: -130% 50%;
        }
        100% {
            background-position: 130% 50%;
        }
    }

    .story-modal-data {
        display: none;
    }

    @media (min-width: 769px) and (hover: hover) and (pointer: fine) {
        .project-story-section:hover .story-readmore-btn {
            width: 14rem;
            padding: 0 1.2rem 0 1.4rem;
            justify-content: space-between;
        }

        .project-story-section:hover .story-readmore-btn .story-readmore-label {
            max-width: 7.5rem;
            opacity: 1;
            transform: translateX(0);
        }
    }

    /* --- 2-COLUMN GRID SECTOR --- */
    .project-modules-grid {
        margin-top: 4rem;
        display: grid;
        grid-template-columns: 2fr 1fr;
        grid-template-rows: auto auto;
        align-items: start;
        gap: 1rem;
    }

    .module-card {
        position: relative;
        border-radius: 5px;
        overflow: hidden;
    }

    .module-card img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .module-big {
        border-radius: 5px;
        grid-column: 1;
        grid-row: 1 / span 2;
        min-height: 42rem;
        height: 100%;
        align-self: stretch;
        background-image: url('/assets/rubrum_Roma_concept.jpg');
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
    }

    .module-carousel {
        border-radius: 5px;
        grid-column: 2;
        grid-row: 1;
        min-height: 0;
        height: auto;
        aspect-ratio: 1 / 1;
        --carousel-duration: 4500ms;
    }

    .module-small {
        border-radius: 5px;
        grid-column: 2;
        grid-row: 2;
        min-height: clamp(26rem, 34vw, 36rem);
    }

    .module-small svg {
        width: 100%;
        height: 100%;
        display: block;
    }

    .project-modules-grid-clone .module-small img {
        width: 100%;
        height: 100%;
        object-fit: contain;
        display: block;
    }

    #projectStorySectionClone {
        margin-top: 4rem;
    }

    .module-carousel-track {
        width: 100%;
        height: 100%;
        display: flex;
        transition: transform 0.5s ease;
    }

    .module-carousel-slide {
        min-width: 100%;
        height: 100%;
    }

    .module-carousel-slide img {
        width: 100%;
        height: 100%;
        object-fit: contain;
    }

    .ssr-carousel-dots {
        --dot-size: 0.5rem;
        backdrop-filter: blur(2rem);
        -webkit-backdrop-filter: blur(2rem);
        background-color: rgba(0, 0, 0, 0.16);
        border-radius: 8px;
        bottom: 1rem;
        display: flex;
        gap: 0.6rem;
        justify-content: center;
        justify-self: center;
        left: 50%;
        margin-top: 0;
        padding: 0.75rem 0.55rem;
        pointer-events: none;
        position: absolute;
        transform: translateX(-50%);
        width: fit-content;
        z-index: 10;
    }

    .ssr-carousel-dot-button {
        border: none;
        background: transparent;
        padding: 0;
        margin: 0;
        width: var(--dot-size);
        height: var(--dot-size);
        cursor: pointer;
        pointer-events: auto;
        color: white;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-radius: 999px;
        transition: width 0.28s ease;
    }

    .ssr-carousel-dot-icon {
        position: relative;
        width: 100%;
        height: 100%;
        border-radius: 999px;
        background: #FFFFFF;
        opacity: 1;
        overflow: hidden;
        transition: opacity 0.28s ease, background-color 0.28s ease;
    }

    .ssr-carousel-dot-button:hover .ssr-carousel-dot-icon {
        opacity: 1;
    }

    .ssr-carousel-dot-icon::before {
        content: '';
        position: absolute;
        inset: 0;
        border-radius: inherit;
        background: #FFFFFF;
        transform: scaleX(0);
        transform-origin: left center;
    }

    .ssr-carousel-dot-button.is-active {
        width: 2.15rem;
    }

    .ssr-carousel-dot-button.is-active .ssr-carousel-dot-icon {
        background: rgba(255, 255, 255, 0.28);
        opacity: 1;
    }

    .ssr-carousel-dot-button.is-active .ssr-carousel-dot-icon::before {
        animation: carouselDotFill var(--carousel-duration, 4500ms) linear forwards;
    }

    .module-carousel.is-paused .ssr-carousel-dot-button.is-active .ssr-carousel-dot-icon::before {
        animation-play-state: paused;
    }

    @keyframes carouselDotFill {
        from { transform: scaleX(0); }
        to { transform: scaleX(1); }
    }

    /* --- MODULE PART OVERLAY --- */
    .modulePart-overlay {
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        background-color: rgba(0, 0, 0, 0.06);
        display: flex;
        height: 100%;
        justify-content: center;
        left: 0;
        overflow-y: auto;
        overscroll-behavior: none;
        padding: 5rem;
        position: fixed;
        top: 0;
        width: 100%;
        z-index: 1200;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.35s ease, visibility 0.35s ease;
    }

    .modulePart-overlay.is-open {
        opacity: 1;
        visibility: visible;
    }

        .modulePart-overlay-card {
        width: 30em;
        max-width: 51rem;
        margin: auto;
        background: #FFFFFF;
        border-radius: 1.6rem;
        position: relative;
        transform: translateY(1.25rem) scale(0.985);
        opacity: 0;
        transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.35s ease;
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
        overflow: hidden;
    }

    .modulePart-overlay-closeBtn {
        display: none;
    }

    @media (min-width: 769px) {
        .modulePart-overlay-card {
            overflow: visible;
        }

        .modulePart-overlay-closeBtn {
            position: absolute;
            top: 0;
            right: 0;
            transform: translate(120%, 0%);
            width: 3.5rem;
            height: 2.8rem;
            border: none;
            border-radius: 999px;
            background: #FFFFFF;
            color: #111111;
            display: flex;
            align-items: center;
            justify-content: center;
            font-family: 'Nebulica', sans-serif;
            font-size: 1.05rem;
            font-weight: 600;
            line-height: 1;
            cursor: pointer;
            box-shadow: none;
            z-index: 4;
            transition: transform 0.2s ease, background-color 0.2s ease;
        }

        .modulePart-overlay-closeBtn:hover {
            transform: translate(120%, 0%) scale(1.06);
            box-shadow: none;
            background: #f7f7f7;
        }

        .modulePart-overlay-closeBtn:focus-visible {
            outline: 2px solid #111111;
            outline-offset: 2px;
        }
    }

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

    .modulePart-overlay-dragHandle {
        display: flex;
        justify-content: center;
        align-items: center;
        height: 2.6rem;
        touch-action: none;
        cursor: grab;
        user-select: none;
        border-bottom: 1px solid rgba(0, 0, 0, 0.08);
    }

    .modulePart-overlay-dragHandle span {
        width: 2.6rem;
        height: 0.28rem;
        border-radius: 999px;
        background: rgba(0, 0, 0, 0.2);
        display: block;
    }

    .modulePart-overlay-card-inner {
        padding: 2.5em 1.5em;
    }

    .modulePart-overlay-card-inner .heading {

        font-family: 'Google Sans Flex', sans-serif;
        font-weight: 600;
        font-size: 0.9rem;
        color: #999;
        margin: 0 0 0.5rem 0;
        line-height: 1.2;
        max-width: 95%;

    }

    .modulePart-overlay-card-inner .headline {
    font-family: 'Google Sans Flex', sans-serif;
    font-weight: 600;
    font-size: 1.35rem;
    margin: 0 0 0rem 0;
    letter-spacing: -0.02em;
    line-height: 1.1;

    }

    .modulePart-overlay-card-inner .bodyText {
        font-family: 'Google Sans Flex', sans-serif;
        font-size: 0.9rem;
        line-height: 1.65;
        color: #333;
    }

    .modulePart-overlay-card-inner .bodyText p {
        margin: 0;
    }

    .modulePart-overlay-card-inner .modulePart-overlay-image {
        width: 100%;
        display: block;
        border-radius: 0;
        margin: 2rem 0 2.5rem 0;
        object-fit: cover;
    }

    /* --- RUBRUM FEATURE SECTION --- */
    .rubrum-feature-section {
        width: 100vw;
        margin-left: calc(50% - 50vw);
        margin-top: 4rem;
        padding: clamp(0.7rem, 1.2vw, 1.1rem) clamp(0.9rem, 1.8vw, 1.6rem) clamp(2rem, 3.4vw, 3.1rem);

        color: #fff;
    }

    .rubrum-feature-title {
        margin: clamp(1.2rem, 2.2vw, 2.2rem) 0 0 0;
        font-family: 'Google Sans Flex', sans-serif;
        font-size: clamp(2.7rem, 7vw, 5.2rem);
        line-height: 0.95;
        letter-spacing: -0.05em;
        font-weight: 900;
        text-transform: lowercase;
        color: #282828;
    }

    .rubrum-feature-gallery {
        margin-top: clamp(1.1rem, 2.2vw, 2.6rem);
        width: 100%;
        background: transparent;
        overflow: hidden;
        padding: clamp(1rem, 2vw, 2rem) clamp(0.6rem, 1.3vw, 1.2rem);
    }

    .hero__images {
        margin: 0 auto;
        width: min(100%, 88rem);
        min-height: clamp(10rem, 20vw, 18rem);
        display: flex;
        align-items: center;
        justify-content: center;
        pointer-events: none;
        position: relative;
    }

    .hero__image {
        --card-size: clamp(8.6rem, 16.4vw, 17rem);
        width: var(--card-size);
        aspect-ratio: 1 / 1;
        border-radius: clamp(1.2rem, 1.7vw, 1.8rem);
        overflow: hidden;
        position: relative;
        flex: 0 0 auto;
        margin-left: clamp(-2.6rem, -3.6vw, -2.1rem);
        box-shadow: 0 12px 34px rgba(0, 0, 0, 0.22), 0 4px 12px rgba(0, 0, 0, 0.16);
        transform: translate3d(calc(var(--offsetX, 0) * 1px), calc(var(--offsetY, 0) * 1px), 0);
        animation: heroCardFloat 8.5s ease-in-out infinite;
        animation-delay: calc(var(--delay, 0) * 120ms);
        will-change: transform;
    }

    .hero__image:first-child {
        margin-left: 0;
    }

    .hero__image .shadow {
        position: absolute;
        left: 50%;
        bottom: -8%;
        width: 68%;
        height: 16%;
        transform: translateX(-50%);
        border-radius: 999px;
        background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.34) 0%, rgba(0, 0, 0, 0) 72%);
        filter: blur(6px);
        pointer-events: none;
    }

    .hero__image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }

    @keyframes heroCardFloat {
        0%, 100% {
            transform: translate3d(calc(var(--offsetX, 0) * 1px), calc(var(--offsetY, 0) * 1px), 0);
        }
        50% {
            transform: translate3d(calc(var(--offsetX, 0) * 1px), calc((var(--offsetY, 0) - 8) * 1px), 0);
        }
    }

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

    .rubrum-feature-bottom {
        margin-bottom: clamp(1.2rem, 2.2vw, 2.2rem);
        display: flex;
        justify-content: flex-end;
        align-items: start;
    }

    .rubrum-feature-copy {
        margin: 0;
        width: min(72%, 64rem);
        margin-left: auto;
        font-family: 'Google Sans Flex', sans-serif;
        font-size: clamp(2rem, 3.4vw, 4.35rem);
        line-height: 1.03;
        letter-spacing: -0.02em;
        font-weight: 700;
        color: #282828;
    }

    /* --- PXM SIGNATURE MOSAIC --- */
    .pxm-sigmosaic-section {
        width: 100%;
        margin-left: 0;
        margin-top: clamp(2.2rem, 4vw, 4rem);
        overflow: hidden;
    }

    #pxmSigMosaicStrip {
        width: 100%;
    }

    #pxmSigMosaicStrip .pxm-sigmosaic-track {
        display: grid;
        grid-template-columns: repeat(4, minmax(0, 1fr));
        min-height: clamp(174px, 31.3vw, 614px);
    }

    #pxmSigMosaicStrip .pxm-sigmosaic-panel {
        --pxm-mosaic-bg: #ff7b02;
        position: relative;
        overflow: hidden;
        min-height: inherit;
        background: var(--pxm-mosaic-bg);
    }

    #pxmSigMosaicStrip .pxm-sigmosaic-panel--orange { --pxm-mosaic-bg: #FF835D; }
    #pxmSigMosaicStrip .pxm-sigmosaic-panel--blue { --pxm-mosaic-bg: #F7AF4A; }
    #pxmSigMosaicStrip .pxm-sigmosaic-panel--grey { --pxm-mosaic-bg: #78C8FF; }
    #pxmSigMosaicStrip .pxm-sigmosaic-panel--cream { --pxm-mosaic-bg: #188888; }

    #pxmSigMosaicStrip .pxm-sigmosaic-loop {
        position: absolute;
        inset: 0;
        display: flex;
        width: 100%;
        height: 100%;
        transform: translate3d(0, 0, 0);
        --pxm-scroll-speed: 0.36;
        will-change: transform;
    }

    #pxmSigMosaicStrip .pxm-sigmosaic-panel:nth-child(2) .pxm-sigmosaic-loop {
        --pxm-scroll-speed: 0.44;
    }

    #pxmSigMosaicStrip .pxm-sigmosaic-panel:nth-child(3) .pxm-sigmosaic-loop {
        --pxm-scroll-speed: 0.3;
    }

    #pxmSigMosaicStrip .pxm-sigmosaic-panel:nth-child(4) .pxm-sigmosaic-loop {
        --pxm-scroll-speed: 0.4;
    }

    #pxmSigMosaicStrip .pxm-sigmosaic-tile {
        flex: 0 0 150%;
        width: 100%;
        height: 100%;
    }

    #pxmSigMosaicStrip .pxm-sigmosaic-tile[aria-hidden="true"] {
        display: none;
    }

    #pxmSigMosaicStrip .pxm-sigmosaic-icon {
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: center;
        display: block;
        filter: brightness(0) saturate(100%) invert(100%);
        pointer-events: none;
        user-select: none;
    }

    .case-study-sector {
        margin-top: clamp(1rem, 2vw, 1.5rem);
    }

    .case__study__info {
        --br: 16px;
        --br2: 8px;
        --pd: 16px;
        --pd2: 8px;
        --color-gray10: rgba(0, 0, 0, 0.04);
        --color-gray20: rgba(0, 0, 0, 0.2);
        --color-black: #000;
        display: grid;
        gap: var(--pd2);
        grid-template-columns: 2fr 1fr;
        align-items: flex-start;
    }

    .case__study__info__left,
    .case__study__info__right {
        display: flex;
        flex-direction: column;
        gap: var(--pd2);
    }

    .case__study__info .page__card {
        background: var(--color-gray10);
        border-radius: var(--br);
        padding: clamp(1rem, 2vw, 1.5rem);
    }

    .case__study__info h2 {
        margin: 0 0 0.9rem;
        font-family: 'Google Sans Flex', sans-serif;
        font-size: clamp(1.2rem, 2vw, 1.8rem);
        font-weight: 500;
        line-height: 1.05;
        letter-spacing: -0.01em;
    }

    .case__study__info__project__information__text p,
    .case__study__info__credits p {
        margin: 0 0 1rem;
        font-family: 'Google Sans Flex', sans-serif;
        font-size: clamp(1rem, 1.4vw, 1.05rem);
        line-height: 1.3;
        color: var(--color-black);
    }

    .case__study__info__project__information__text p:last-child,
    .case__study__info__credits p:last-child {
        margin-bottom: 0;
    }

    .case__study__info__credits h2 {
        margin-top: 1.8rem;
    }

    .case__study__info__credits h2:first-child {
        margin-top: 0;
    }

    @media (max-width: 1024px) {
        .case__study__info {
            grid-template-columns: 1fr;
        }
    }

    /* --- RESPONSIVE --- */
    @media (max-width: 1024px) {
                .rubrum-feature-copy {
            width: min(76%, 52rem);
            font-size: clamp(1.8rem, 4.2vw, 3rem);
        }
    }

    @media (max-width: 768px) {
        /* CHANGED: Specific mobile padding request */
        .page-project-detail { 
            padding: 5rem 0.8rem 2rem; 
        }

        .project-hero-media {
            margin-bottom: 3rem;
        }

        .project-hero-media--extra {
            margin-top: 0.8rem;
            margin-bottom: 0;
        }

        .rubrum-gallery img + img {
            margin-top: 0.8rem;
        }
        
                
        .work-page-subtitle {
            font-size: 0.9rem;
            font-weight: 500;
            line-height: 1.2;
        }

        .work-page-title {
            font-size: 10vw;
        }

        .meta-separator {
            margin-top: 0.55rem;
        }

        /* Stack grid on mobile: 2 columns */
        .meta-grid {
            grid-template-columns: 1fr 1fr; 
            gap: 2rem;
            justify-content: stretch; /* Let them fill space on mobile */
        }

        .meta-label,
        .meta-value {
            font-size: 0.9rem;
            font-weight: 500;
            -webkit-text-stroke: 0.3px;
        }

        .project-story-section {
            padding: 1rem 0 0;
        }

        #projectStorySectionClone {
            margin-top: 3rem;
        }

        .story-heading {
            font-size: 8vw;
            max-width: 100%;
        }

        .story-readmore-btn {
        --press-stroke: 0.35px;
        margin-top: 2rem;
        width: auto;
        min-width: auto;
        height: 2.35rem;
        padding: 0 1.25rem 0 1.4rem;
        justify-content: space-between;
        gap: 0.7rem;
        }

        .story-readmore-label {
            max-width: 8rem;
            opacity: 1;
            transform: translateX(0);
            font-size: 3.5vw;
        }

        .story-readmore-icon {
            width: 0.7rem;
            height: 0.7rem;
        }

        .modulePart-overlay {
            padding: 0;
            align-items: flex-end;
            justify-content: center;
            overflow: hidden;
        }

        html.modulePart-overlay-open {
            overflow: hidden;
        }

        body.modulePart-overlay-open {
            position: fixed;
            left: 0;
            right: 0;
            width: 100%;
            overflow: hidden;
        }

        .modulePart-overlay-card {
            border-radius: 1.1rem 1.1rem 0 0;
            max-width: 100%;
            width: 100%;
            margin: 0;
            margin-top: auto;
            transform: translateY(100%);
        }

        .modulePart-overlay.is-open .modulePart-overlay-card {
            transform: translateY(0);
        }

        .modulePart-overlay-card-inner {
            padding: 1.3rem 1rem 1.5rem;
            max-height: 78vh;
            overflow-y: auto;
            -webkit-overflow-scrolling: touch;
        }

        .modulePart-overlay-card-inner .headline {
            font-size: 1.35rem;
        }

        .modulePart-overlay-card-inner .bodyText {
            font-size: 3.3vw;
        }

        .project-modules-grid {
            margin-top: 3rem;
            grid-template-columns: 1fr;
            grid-template-rows: auto;
            gap: 0.8rem;
        }

        .module-big,
        .module-carousel,
        .module-small {
            grid-column: auto;
            grid-row: auto;
            min-height: 22rem;
        }

        .module-carousel {
            min-height: 0;
            aspect-ratio: 1 / 1;
        }

        .module-big {
            min-height: 25rem;
        }

        .module-small {
            min-height: 28rem;
        }
        
        /* Discipline takes full width on last row if needed */
        .meta-column:nth-child(4) {
            grid-column: span 2;
        }

        .rubrum-feature-section {
            margin-top: 3rem;
            padding: 1rem 0.9rem 1rem;
        }

        .rubrum-feature-title {
            font-size: clamp(3.3rem, 17vw, 5.5rem);
            line-height: 0.84;
            margin-top: 1rem;
        }

        .rubrum-feature-gallery {
            margin-top: 0.9rem;
            padding: 0.9rem 0.45rem;
        }

        .hero__images {
            min-height: clamp(7.8rem, 36vw, 11rem);
        }

        .hero__image {
            --card-size: clamp(5rem, 24vw, 6.6rem);
            margin-left: clamp(-1.65rem, -5.2vw, -0.95rem);
            border-radius: 0.95rem;
        }

        .hero__image:first-child {
            margin-left: 0;
        }

        .rubrum-feature-bottom {
            margin-top: 1.1rem;
        margin-bottom: 1rem;
            justify-content: flex-start;
        }

        .rubrum-feature-copy {
            width: min(100%, 24rem);
            margin-left: 0;
            font-size: 6vw;
            line-height: 1.03;
            text-align: left;
        }

        .pxm-sigmosaic-section {
            margin-top: 2rem;
        }

        #pxmSigMosaicStrip .pxm-sigmosaic-track {
            min-height: clamp(124px, 30.7vw, 220px);
        }
    }


    @media (max-width: 767px) {
      main > .page-inner,
      main > .contact-inner {
        padding-left: 0 !important;
        padding-right: 0 !important;
      }

      main section {
        padding-left: 0.65rem !important;
        padding-right: 0.65rem !important;
        box-sizing: border-box;
      }

      .page-project-detail {
        padding-left: 0.65rem !important;
        padding-right: 0.65rem !important;
      }

      .page-project-detail .work-page-header {
        padding-left: 0 !important;
        padding-right: 0 !important;
      }

      .case-study-sector {
        padding-left: 0 !important;
        padding-right: 0 !important;
      }
    }
