/* Buttons */
.btn-primary,
.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-12) var(--space-24);
    border-radius: var(--radius-8);
    font-weight: var(--text-body-lg-weight);
    font-size: var(--text-body-lg-size);
    cursor: pointer;
    transition: all var(--transition-fast);
    border: none;
}

.label-md.mb-4 {
    font-weight: 700;
}

.btn-primary {
    background-color: var(--color-primary);
    color: #fff;
}

.btn-primary:hover {
    background-color: var(--color-primary-light);
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: var(--color-surface);
    color: var(--color-text-primary);
    border: 1px solid var(--color-border);
}

.btn-secondary:hover {
    background-color: var(--color-surface-hover);
    border-color: var(--color-border-hover);
    transform: translateY(-2px);
}



/* Nav Links */
.nav-link {
    font-size: var(--text-body-md-size);
    font-weight: var(--text-body-md-weight);
    color: var(--color-text-secondary);
    transition: color var(--transition-fast);
}

.nav-link:hover,
.nav-link.active {
    color: var(--color-text-highlight);
    font-weight: 700;
}

/* Tags */
.tag {
    display: inline-flex;
    align-items: center;
    padding: var(--space-8) var(--space-16);
    border-radius: var(--radius-32);
    background-color: var(--color-white-alpha-08);
    color: var(--color-text-secondary);
    font-size: var(--text-label-md-size);
    font-weight: var(--text-label-md-weight);
    letter-spacing: var(--text-label-md-spacing);
    white-space: nowrap;
    flex-shrink: 0;
}

/* Cards */
.card {
    background-color: var(--color-surface);
    border-radius: var(--radius-12);
    padding: var(--space-32);
    border: 1px solid var(--color-white-alpha-04);
}

/* Project Cards */
.project-card {
    display: flex;
    flex-direction: column;
    gap: var(--space-24);
    transition: transform var(--transition-normal), background-color var(--transition-normal);
    border-radius: var(--radius-16);
    padding: var(--space-16);
    background-color: transparent;
}

.project-card:hover {
    transform: translateY(-4px);
    background-color: var(--color-white-alpha-04);
}

.project-card:hover .placeholder-frame {
    border-color: var(--color-border-hover);
    background-color: var(--color-surface-alt);
}

/* Placeholders Framework */
.placeholder-frame {
    background-color: var(--color-surface);
    border: 1px dashed var(--color-border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-muted);
    font-size: var(--text-label-md-size);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    overflow: hidden;
    transition: all var(--transition-normal);
}

.placeholder-profile {
    width: 200px;
    height: 200px;
    border-radius: 50%;
}

.placeholder-cover {
    width: 100%;
    aspect-ratio: 4/3;
    border-radius: var(--radius-12);
}

.placeholder-gallery {
    width: 100%;
    aspect-ratio: 1/1;
    border-radius: var(--radius-8);
}

.placeholder-single {
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: var(--radius-16);
    border: 1px solid var(--color-border);
}

.glass-reflection {
    position: relative;
    border-radius: var(--radius-16);
    overflow: hidden;
}

.glass-reflection::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: var(--radius-16);
    pointer-events: none;
    background: linear-gradient(135deg, rgba(238, 239, 255, 1) 0%, rgba(238, 239, 255, 0) 30%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    padding: 2px;
}

/* Forms */
.input-group {
    display: flex;
    flex-direction: column;
    gap: var(--space-8);
}

.input-label {
    font-size: var(--text-label-md-size);
    color: var(--color-text-secondary);
}

.input-field {
    background-color: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-8);
    padding: var(--space-12) var(--space-16);
    color: var(--color-text-primary);
    font-family: var(--font-primary);
    font-size: var(--text-body-md-size);
    transition: border-color var(--transition-fast);
}

.input-field:focus {
    outline: none;
    border-color: var(--color-primary-light);
}

textarea.input-field {
    resize: vertical;
    min-height: 120px;
}

/* Animations */
.fade-up {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

.fade-up.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* New Single Page Layout Classes */
.project-row {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-bottom: var(--space-96);
}

.project-row:last-child {
    margin-bottom: 0;
}

.project-row .placeholder-cover,
.project-row .placeholder-gallery {
    width: 100%;
    margin-bottom: var(--space-32);
    transition: transform var(--transition-slow), border-color var(--transition-slow);
}

.project-row:hover .placeholder-frame {
    transform: scale(1.02);
    border-color: var(--color-border-hover);
    background-color: var(--color-surface-alt);
}

/* Navigation Brand */
.nav-brand {
    display: flex;
    align-items: center;
    gap: var(--space-12);
    text-decoration: none;
    color: var(--color-text-primary);
    font-size: var(--text-body-md-size);
    font-weight: 500;
    transition: opacity var(--transition-fast);
}

.nav-brand:hover {
    opacity: 0.7;
}

.nav-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--color-white-alpha-08);
}

/* Hero Tagline */
/* Hero Section Styling */
.hero-fullscreen {
    min-height: calc(100vh - 120px);
    /* Full viewport minus header/footer space */
    display: flex;
    align-items: center;
    position: relative;
    padding: var(--space-80) 0;
}

.hero-content-wrapper {
    display: flex;
    align-items: center;
    gap: var(--space-80);
    width: 100%;
}

.hero-photo-container {
    flex-shrink: 0;
    position: relative;
    width: 280px;
    height: 280px;
}

.hero-main-photo {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    position: relative;
    z-index: 2;
    border: none;
}

.photo-glow-effect {
    position: absolute;
    inset: -30px;
    background: var(--gradient-primary);
    filter: blur(50px);
    opacity: 0.2;
    border-radius: 50%;
    z-index: 1;
}

.hero-text-container {
    flex: 1;
}

.hero-tagline {
    font-size: 24px;
    line-height: 1.5;
    color: var(--color-text-primary);
    max-width: 800px;
    font-weight: 400;
}

.hero-tagline em {
    font-family: "Playfair Display", serif;
    font-style: italic;
    font-weight: 900;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
}

.hero-footer {
    position: absolute;
    bottom: var(--space-32);
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
}

.btn-discover {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-12);
    color: var(--color-text-muted);
    text-decoration: none;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    transition: all var(--transition-fast);
}

.btn-discover:hover {
    color: var(--color-text-primary);
    transform: translateY(4px);
}

.icon-arrow-down {
    margin-top: 4px;
    animation: bounce 2s infinite;
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-6px);
    }

    60% {
        transform: translateY(-3px);
    }
}

@media (max-width: 992px) {
    .hero-content-wrapper {
        flex-direction: column;
        text-align: center;
        gap: var(--space-48);
    }

    .hero-photo-container {
        width: 200px;
        height: 200px;
    }

    .hero-tagline {
        font-size: 22px;
        margin: 0 auto;
    }

    .hero-fullscreen {
        min-height: auto;
        padding: var(--space-96) 0 var(--space-128);
    }

    .hero-footer {
        position: relative;
        bottom: 0;
        margin-top: var(--space-64);
    }
}

@media (max-width: 768px) {
    .hero-fullscreen {
        min-height: calc(100vh - 60px);
        min-height: calc(100svh - 60px);
        padding: var(--space-24) 0 var(--space-20);
        align-items: center;
    }

    .hero-fullscreen .fade-up {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .hero-fullscreen .container {
        min-height: calc(100vh - 104px);
        min-height: calc(100svh - 104px);
        display: flex;
        flex-direction: column;
        justify-content: center;
        position: relative;
    }

    .hero-content-wrapper {
        gap: var(--space-24);
        flex: 1 1 auto;
        justify-content: center;
        padding-bottom: var(--space-64);
    }

    .hero-photo-container {
        width: 140px;
        height: 140px;
    }

    .photo-glow-effect {
        inset: -18px;
        filter: blur(34px);
    }

    .hero-text-container .display-lg {
        font-size: 34px;
        line-height: 1.18;
        margin-bottom: var(--space-16);
    }

    .section-header .heading-xl.text-40,
    #about .heading-xl.text-40,
    #contact .display-lg {
        font-size: 34px !important;
        line-height: 1.18;
    }

    .hero-tagline {
        font-size: 17px;
        line-height: 1.45;
        max-width: 350px;
    }

    .hero-footer {
        position: absolute;
        right: var(--space-16);
        bottom: var(--space-64);
        left: var(--space-16);
        flex-shrink: 0;
        margin-top: 0;
        padding-top: 0;
    }

    .btn-discover {
        gap: var(--space-8);
        font-size: 10px;
    }
}

@media (max-width: 380px) {
    .hero-fullscreen {
        padding-top: var(--space-16);
        padding-bottom: var(--space-16);
    }

    .hero-fullscreen .container {
        min-height: calc(100vh - 91px);
        min-height: calc(100svh - 91px);
    }

    .hero-content-wrapper {
        gap: var(--space-16);
        padding-bottom: var(--space-48);
    }

    .hero-photo-container {
        width: 112px;
        height: 112px;
    }

    .hero-text-container .display-lg {
        font-size: 30px;
    }

    .section-header .heading-xl.text-40,
    #about .heading-xl.text-40,
    #contact .display-lg {
        font-size: 30px !important;
        line-height: 1.18;
    }

    .hero-tagline {
        font-size: 15px;
        line-height: 1.42;
    }

    .hero-footer {
        margin-top: var(--space-16);
    }
}

/* Glassmorphism */
.glass-card {
    background-color: var(--color-surface-glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: var(--radius-24);
    padding: var(--space-48);
    position: relative;
    transition: transform var(--transition-normal);
    transform: translateY(var(--parallax-y, 0px));
}

.glass-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: var(--radius-24);
    padding: 1px;
    background: linear-gradient(135deg, rgba(238, 239, 255, 0.4) 0%, rgba(238, 239, 255, 0) 30%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
}

.glass-card:hover {
    transform: translateY(calc(var(--parallax-y, 0px) - 4px));
}

/* Arrow Button Micro-interaction */
.btn-arrow {
    display: inline-flex;
    align-items: center;
    gap: var(--space-12);
    font-size: var(--text-body-md-size);
    font-weight: var(--text-body-md-weight);
    color: var(--color-text-primary);
    cursor: pointer;
    text-decoration: none;
}

.btn-arrow .icon-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--color-background);
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    border: none;
}

.btn-arrow .icon-circle::before {
    content: "";
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    background: var(--gradient-primary);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    padding: 2px;
    background-size: 200% auto;
    transition: background-position 0.5s ease;
}

.btn-arrow:hover .icon-circle {
    background-color: var(--color-background);
}

.btn-arrow:hover .icon-circle::before {
    background-position: right center;
}

.btn-arrow .icon-circle svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-arrow:hover .icon-circle svg {
    transform: rotate(-45deg);
}

.btn-arrow.back-arrow:hover .icon-circle svg {
    transform: translate(-3px, 0);
}

/* Header Profile Pic */
.header-logo-container {
    position: relative;
    display: inline-flex;
    align-items: center;
    margin-left: 130px;
}

.header-profile-pic {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    object-fit: cover;
    position: absolute;
    left: -130px;
    top: -14px;
    z-index: 101;
}

/* Custom Text utilities */
.text-40 {
    font-size: 40px !important;
}

.description-border {
    border-left: 2px solid var(--color-white-alpha-40);
    padding-left: var(--space-24);
}

.text-separator {
    font-weight: 300;
    opacity: 0.4;
    margin: 0 0.15em;
    display: inline-block;
    transform: translateY(-1px);
}

.timeline-logo-placeholder {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background-color: var(--color-surface-alt);
    flex-shrink: 0;
    overflow: hidden;
}

.profile-metric-context {
    font-family: var(--font-primary);
    font-weight: 400;
    margin-top: 4px;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-8);
}

/* Creative Separator Marquee */
.marquee-separator {
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
    position: relative;
    padding: var(--space-48) 0;
    display: flex;
    align-items: center;
    border-top: 1px solid var(--color-white-alpha-04);
    border-bottom: 1px solid var(--color-white-alpha-04);
}

.marquee-content {
    display: inline-block;
    animation: marquee 40s linear infinite;
    font-family: var(--font-display);
    font-size: 80px;
    color: var(--color-text-secondary);
    opacity: 0.1;
    letter-spacing: -0.02em;
    text-transform: uppercase;
}

@keyframes marquee {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

.divider {
    height: 1px;
    background-color: var(--color-white-alpha-16);
    width: 100%;
}

/* Case Study Utilities */
.caption {
    font-size: var(--text-body-md-size);
    color: var(--color-text-muted);
    line-height: var(--line-height-relaxed);
    margin-top: var(--space-16);
}

.metric-card {
    display: flex;
    flex-direction: column;
}

.highlight-box {
    display: inline-block;
    padding: var(--space-4) var(--space-12);
    background-color: var(--color-primary);
    color: #fff;
    border-radius: var(--radius-8);
    font-weight: 700;
}

.quote-card {
    padding: var(--space-32);
    background-color: var(--color-white-alpha-04);
    border-radius: var(--radius-16);
    position: relative;
}

.quote-card blockquote {
    border-left: none !important;
    padding-left: 0 !important;
    margin: 0;
}

@media (max-width: 768px) {
    .metric-card {
        flex-direction: row;
        align-items: baseline;
        gap: var(--space-12);
    }

    .metric-card h2 {
        margin-bottom: 0 !important;
    }
}

/* Premium Project Cards */
.project-card-premium {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    background-color: var(--color-surface-glass);
    background-image: url('../assets/images/card-background-top-right.png');
    background-repeat: no-repeat;
    background-position: top right;
    background-size: auto 100%;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-radius: var(--radius-24);
    position: relative;
    overflow: hidden;
    aspect-ratio: 2.35 / 1;
    height: auto;
    min-height: 320px;
    /* Safety minimum */
    transition: border-color var(--transition-normal), box-shadow var(--transition-normal), transform var(--transition-normal);
    border: 1px solid var(--color-white-alpha-04);
    text-decoration: none !important;
    isolation: isolate;
    box-shadow: 0 0 0 rgba(157, 87, 255, 0);
    will-change: border-color, box-shadow, transform;
}

.project-card-premium::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: var(--radius-24);
    padding: 1px;
    background: linear-gradient(135deg, rgba(238, 239, 255, 0.4) 0%, rgba(238, 239, 255, 0) 30%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    background-size: 200% auto;
    transition: background-position 0.5s ease;
}

.project-card-premium:hover {
    transform: translateY(-8px);
    border-color: var(--color-white-alpha-08);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3), 0 0 40px rgba(157, 87, 255, 0.15);
}

.project-card-premium::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 70% 50%, var(--color-primary-light), transparent 70%);
    opacity: 0;
    z-index: 0;
    transition: opacity 0.6s ease;
    pointer-events: none;
}

.project-card-premium:hover::after {
    opacity: 0.15;
}

.project-card-info {
    padding: var(--space-48);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    /* Stick button to bottom on desktop */
    min-height: 100%;
    z-index: 2;
    text-align: left;
}

.project-card-info-content {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.project-card-info-content .label-md {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--color-text-muted);
    margin-bottom: var(--space-8);
}

.project-card-info .btn-case-study {
    margin-top: 0;
    /* Handled by parent gap */
    flex-shrink: 0;
}

.project-card-visuals {
    position: relative;
    min-height: 100%;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    /* Anchor to bottom for consistent cropping */
    padding-bottom: 0;
    z-index: 1;
    pointer-events: none;
    transform-style: preserve-3d;
    backface-visibility: hidden;
    overflow: visible;
}

.iphone-mockup {
    position: absolute;
    height: auto;
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.6s ease;
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.4));
    will-change: transform, filter;
    transform: translateZ(0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    bottom: -40px;
    /* Intentional bottom crop across the system */
}

/* Composition: Dual Mobile */
.composition-dual-mobile .iphone-mockup {
    width: 200px;
    /* Standard mobile width */
}

.composition-dual-mobile .iphone-1 {
    z-index: 2;
    transform: rotate(-5deg) translateX(-20%) translateY(0) translateZ(0);
}

.composition-dual-mobile .iphone-2 {
    z-index: 1;
    opacity: 0.8;
    transform: rotate(10deg) translateX(50%) translateY(10%) translateZ(0);
}

.project-card-premium:hover .composition-dual-mobile .iphone-1 {
    transform: rotate(-8deg) translateX(-30%) translateY(-10%) scale(1.05) translateZ(0);
}

.project-card-premium:hover .composition-dual-mobile .iphone-2 {
    transform: rotate(15deg) translateX(80%) translateY(0%) scale(1.08) translateZ(0);
    opacity: 1;
}

/* Composition: Laptop + Mobile */
.composition-laptop-mobile .iphone-1 {
    /* Laptop */
    width: 350px;
    z-index: 1;
    transform: rotate(-2deg) translateX(-10%) translateY(5%) translateZ(0);
    bottom: -50px;
}

.composition-laptop-mobile .iphone-2 {
    /* Mobile */
    width: 180px;
    z-index: 2;
    transform: rotate(5deg) translateX(55%) translateY(5%) translateZ(0);
    /* Moved LEFT from 100% */
}

.project-card-premium:hover .composition-laptop-mobile .iphone-1 {
    transform: rotate(-4deg) translateX(-10%) translateY(-2%) scale(1.02) translateZ(0);
}

.project-card-premium:hover .composition-laptop-mobile .iphone-2 {
    transform: rotate(8deg) translateX(70%) translateY(-10%) scale(1.05) translateZ(0);
}

/* Composition: Single Laptop */
.composition-single-laptop .iphone-1 {
    width: 520px;
    /* Increased from 380px */
    bottom: -80px;
    transform: rotate(-2deg) translateX(15%) translateY(15%) translateZ(0);
}

.project-card-premium:hover .composition-single-laptop .iphone-1 {
    transform: rotate(-4deg) translateX(10%) translateY(0%) scale(1.03) translateZ(0);
}

/* Responsive Project Cards */
@media (max-width: 1024px) {
    .project-card-premium {
        aspect-ratio: unset !important;
        grid-template-columns: 1fr;
        height: auto;
        min-height: auto;
    }

    .project-card-info {
        padding: var(--space-32);
        order: 1;
        height: auto;
        min-height: auto;
        /* Reset desktop min-height */
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        gap: var(--space-32);
    }

    .project-card-info .btn-case-study {
        margin-top: 0 !important;
        /* Handled by parent gap */
    }

    /* Target the tags container specifically in mobile */
    .project-card-info .flex-wrap {
        margin-bottom: var(--space-16) !important;
        width: 100%;
        display: flex;
        flex-wrap: wrap;
        /* Re-enforce wrap */
    }

    .project-card-visuals {
        order: 2;
        height: 280px;
        /* Fixed height for consistency */
        min-height: 280px;
        padding: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        margin: 0;
        position: relative;
        /* Ensure it's a positioning parent */
    }

    .iphone-mockup {
        top: 55%;
        /* Slightly lower for better framing */
        left: 50%;
        bottom: auto;
    }

    /* Mobile Compositions */
    .composition-dual-mobile .iphone-mockup {
        width: 140px;
    }

    .composition-dual-mobile .iphone-1 {
        transform: translate(-70%, -50%) rotate(-5deg) translateZ(0);
    }

    .composition-dual-mobile .iphone-2 {
        transform: translate(-10%, -40%) rotate(10deg) translateZ(0);
    }

    .composition-laptop-mobile .iphone-1 {
        /* Laptop */
        width: 300px;
        transform: translate(-45%, -35%) rotate(-2deg) translateZ(0);
    }

    .composition-laptop-mobile .iphone-2 {
        /* Mobile */
        width: 120px;
        transform: translate(35%, -25%) rotate(5deg) translateZ(0);
    }

    .composition-single-laptop .iphone-1 {
        width: 320px;
        /* Increased from 240px */
        transform: translate(-50%, -35%) rotate(-2deg) translateZ(0);
    }

    .project-card-premium:hover .composition-dual-mobile .iphone-1 {
        transform: translate(-75%, -55%) rotate(-8deg) scale(1.05) translateZ(0);
    }

    .project-card-premium:hover .composition-dual-mobile .iphone-2 {
        transform: translate(0%, -35%) rotate(15deg) scale(1.08) translateZ(0);
    }

    .project-card-premium:hover .composition-laptop-mobile .iphone-1 {
        transform: translate(-55%, -45%) rotate(-4deg) scale(1.02) translateZ(0);
    }

    .project-card-premium:hover .composition-laptop-mobile .iphone-2 {
        transform: translate(70%, -40%) rotate(8deg) scale(1.05) translateZ(0);
    }

    /* Explicitly define transition out for Safari stability */
    .iphone-mockup {
        will-change: transform;
    }
}

@media (max-width: 768px) {
    .project-card-premium {
        min-height: auto;
    }

    .project-card-visuals {
        height: 240px;
        min-height: 240px;
        margin-top: 0;
    }

    .iphone-mockup {
        width: 150px;
    }
}

/* Case Study Button (combining Premium style + Arrow animation) */
.btn-case-study {
    position: relative;
    background-color: var(--color-background);
    color: var(--color-text-primary);
    border-radius: var(--radius-64);
    display: inline-flex;
    align-items: center;
    padding: var(--space-12) var(--space-24);
    font-weight: 500;
    font-size: var(--text-body-md-size);
    cursor: pointer;
    text-decoration: none;
    z-index: 1;
    border: none;
    transition: transform var(--transition-fast);
    gap: var(--space-12);
    width: fit-content;
    pointer-events: auto;
    /* Changed from none to enable interaction on standalone buttons */
    isolation: isolate;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.btn-case-study::before {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: calc(var(--radius-64) + 1px);
    background: var(--gradient-primary);
    z-index: -1;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    padding: 1px;
    background-size: 200% auto;
    transition: background-position 0.5s ease;
    transform: translateZ(0);
    backface-visibility: hidden;
}


.btn-case-study::after {
    content: "";
    position: absolute;
    inset: -1px;
    background: var(--gradient-primary);
    filter: blur(15px);
    opacity: 0;
    z-index: -2;
    transition: opacity 0.5s ease;
    border-radius: inherit;
    pointer-events: none;
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Hover effects triggered by card hover */
.project-card-premium:hover,
.project-card-premium:hover .heading-xl,
.project-card-premium:hover .body-lg {
    color: var(--color-text-primary);
}

.project-card-premium:hover .text-muted {
    color: var(--color-text-muted) !important;
}

.project-card-premium:hover .btn-case-study::after,
.personal-project-card:hover .btn-case-study::after,
.btn-case-study:hover::after {
    opacity: 0.4;
}

.project-card-premium:hover .btn-case-study::before,
.personal-project-card:hover .btn-case-study::before,
.btn-case-study:hover::before {
    background-position: right center;
}



.project-card-premium:hover .icon-arrow,
.personal-project-card:hover .icon-arrow,
.btn-case-study:hover .icon-arrow {
    transform: rotate(-45deg);
}

.btn-case-study .icon-circle {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--color-white-alpha-08);
    transition: background-color 0.3s ease;
    transform: translateZ(0);
}

.btn-case-study svg {
    width: 14px;
    height: 14px;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Personal Project Cards */
.personal-project-card {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    height: 100%;
}

.personal-card-content {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.personal-project-card:hover {
    transform: translateY(-8px);
    border-color: var(--color-white-alpha-16);
}

.personal-project-card .btn-case-study svg {
    transition: transform 0.3s ease;
}

/* Unified Profile Section (New structure: no card) */
.profile-unified-container {
    padding: var(--space-64) 0;
    max-width: 900px;
}

.profile-metrics-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-64);
}

.metric-item {
    display: flex;
    flex-direction: column;
}

.metric-item .heading-lg {
    line-height: 1.1;
    display: flex;
    flex-direction: column;
    margin-top: 4px;
}

/* Base style for Caps Labels */
.label-caps {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-text-muted);
}

.profile-section .label-caps {
    color: var(--color-text-muted);
    opacity: 0.8;
}

.timeline-item {
    position: relative;
    transition: transform 0.3s ease;
}

.timeline-logo-placeholder {
    width: 48px;
    height: 48px;
    background: var(--color-white-alpha-04);
    border-radius: var(--radius-12);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
    border: 1px solid var(--color-white-alpha-08);
}

.timeline-logo-placeholder.is-circle {
    border-radius: 50%;
}

.timeline-logo-placeholder img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.divider {
    height: 1px;
    background: var(--color-white-alpha-08);
    width: 100%;
}

/* Premium Link Button with Animated Underline */
.btn-premium-link {
    position: relative;
    text-decoration: none;
    color: var(--color-text-primary);
    font-size: 16px;
    font-weight: 500;
    padding: 8px 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: color 0.3s ease;
    width: fit-content;
}

.btn-premium-link .icon-arrow-sm {
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), color 0.3s ease;
    opacity: 0.8;
    transform: rotate(45deg);
    /* Horizontal East */
}

.btn-premium-link:hover .icon-arrow-sm {
    transform: rotate(0deg);
    /* Tilt Up North-East */
    color: var(--color-primary-light);
}

/* Back Link Modifier */
.btn-premium-link.btn-back .icon-arrow-sm {
    transform: rotate(225deg);
    /* Horizontal West */
}

.btn-premium-link.btn-back:hover .icon-arrow-sm {
    transform: rotate(270deg);
    /* Tilt (default back modifier) */
}

/* Case study header only: hover tilts arrow down, not up */
.site-header .btn-premium-link.btn-back:hover .icon-arrow-sm {
    transform: rotate(180deg);
}

.btn-premium-link:hover {
    color: var(--color-primary-light);
}

.btn-premium-link .underline {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-premium-link:hover .underline {
    transform: scaleX(1);
    transform-origin: left;
}

@media (max-width: 992px) {
    .profile-metrics-row {
        grid-template-columns: 1fr;
        gap: var(--space-40);
    }

    .timeline-item {
        flex-direction: column;
        gap: var(--space-16);
    }
}

/* Premium Section Divider */
.section-divider-premium {
    width: 100%;
    height: 1px;
    background: linear-gradient(to right,
            transparent 0%,
            var(--color-white-alpha-08) 20%,
            var(--color-white-alpha-16) 50%,
            var(--color-white-alpha-08) 80%,
            transparent 100%);
    margin: var(--space-96) 0;
}

/* Case Study Header Redesign */
/* .btn-back is now a modifier for .btn-premium-link */

.cs-header-title {
    font-family: var(--font-primary);
    font-size: var(--text-label-md-size);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text-muted);
    opacity: 0.8;
}

a.cs-header-title {
    display: inline-flex;
    align-items: center;
    gap: var(--space-8);
    color: var(--color-text-muted);
    text-decoration: none;
    cursor: pointer;
    transition: color 0.25s ease;
}

a.cs-header-title:hover {
    color: var(--color-text-primary);
}

a.cs-header-title .cs-header-arrow {
    width: 12px;
    height: 12px;
    flex-shrink: 0;
    opacity: 0;
    transform: translateY(3px);
    transition: opacity 0.3s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
}

a.cs-header-title.is-scrolled .cs-header-arrow {
    opacity: 0.85;
    transform: translateY(0);
}

a.cs-header-title:hover .cs-header-arrow {
    opacity: 1;
}

@media (max-width: 768px) {
    .btn-premium-link.btn-back .btn-text {
        display: none;
    }

    .cs-header-title {
        font-size: 10px;
        text-align: right;
    }
}

/* Case study pages — all main content images use 16px radius */
.case-study-doc main img {
    border-radius: var(--radius-16);
}

/* Case Study Styles */
.cs-hero {
    padding-top: var(--space-96);
    padding-bottom: var(--space-40);
}

.cs-hero-lede {
    font-weight: 500;
}

.cs-video-showcase {
    margin-bottom: var(--space-64);
}

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

/* Editorial case study hero constrained to prose width */
.case-study-editorial .cs-hero {
    max-width: var(--cs-prose-width, 600px);
    width: 100%;
}

.cs-meta-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-48);
    margin-top: var(--space-64);
    padding-top: var(--space-48);
    border-top: 1px solid var(--color-white-alpha-08);
}

.video-container {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: var(--color-white-alpha-04);
    border-radius: var(--radius-24);
    overflow: hidden;
    border: 1px solid var(--color-white-alpha-08);
    margin-bottom: var(--space-128);
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.zoomable {
    cursor: zoom-in;
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.zoomable:hover {
    transform: scale(1.02);
}

/* Lightbox Overlay */
.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(13, 24, 31, 0.95);
    backdrop-filter: blur(20px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
    padding: var(--space-64);
}

.lightbox.is-active {
    opacity: 1;
    pointer-events: auto;
}

.lightbox-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    border-radius: var(--radius-12);
    transform: scale(0.9);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.lightbox.is-active .lightbox-img {
    transform: scale(1);
}

.lightbox-close {
    position: absolute;
    top: var(--space-32);
    right: var(--space-32);
    background: none;
    border: none;
    color: var(--color-text-primary);
    cursor: pointer;
    padding: var(--space-16);
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.lightbox-close:hover {
    opacity: 1;
}

.cs-content-section {
    max-width: 900px;
}

.metric-grid-editorial {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-32);
}

.cs-metrics-section {
    padding-top: 0;
}

.metric-item-editorial {
    padding: var(--space-32);
    border-left: 1px solid var(--color-white-alpha-16);
}

.metric-item-editorial h4 {
    font-size: 48px;
    font-weight: 700;
    line-height: 1;
    margin-bottom: var(--space-12);
}

@media (max-width: 992px) {
    .cs-meta-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .metric-grid-editorial {
        grid-template-columns: 1fr;
    }
}

.personal-project-card .placeholder-single {
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.personal-card-image {
    object-fit: cover;
    border-radius: var(--radius-24);
}

.personal-project-card:hover .placeholder-single {
    transform: scale(1.02);
}

/* Editorial case study template */
.case-study-editorial .body-md,
.case-study-editorial .body-lg,
.case-study-editorial .body-sm {
    font-size: var(--text-body-lg-size);
    line-height: var(--text-body-lg-height);
    letter-spacing: var(--text-body-lg-spacing);
}

.case-study-editorial figcaption.caption,
.case-study-editorial .caption {
    font-size: var(--text-body-md-size);
    line-height: var(--line-height-relaxed);
    font-style: italic;
    text-align: center;
    margin: 0;
    display: block;
    width: 100%;
}

/* No global indent — width hierarchy is handled by .cs-prose vs .cs-media-rail */
.case-study-editorial section.cs-h2-section>h2.label-caps~* {
    padding-left: 0;
    box-sizing: border-box;
    min-width: 0;
}

/* Editorial case study — vertical rhythm */
.case-study-editorial {
    --cs-prose-width: 600px;
    --cs-gap-section: var(--space-80);
    --cs-gap-h2-body: var(--space-40);
    --cs-gap-h3-body: var(--space-20);
    --cs-gap-paragraphs: var(--space-24);
    --cs-gap-text-media: var(--space-40);
    --cs-gap-media-caption: var(--space-16);
    --cs-gap-blocks: var(--space-48);
    --cs-gap-blocks-compact: var(--space-40);
    --cs-gap-figures: var(--space-40);
    --cs-gap-pullquotes: var(--space-32);
    --cs-gap-media-grid: var(--space-32);
    --cs-gap-media-stack: var(--space-16);
    --cs-h2-indent: 40px;
}

/* Hero — Ma mission inline */
.case-study-editorial .cs-mission-row {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: var(--space-12) var(--space-16);
    margin-top: var(--space-48);

    padding-bottom: var(--space-48);

    border-bottom: 1px solid var(--color-white-alpha-08);
}

.case-study-editorial .cs-mission-row .label-caps {
    margin-bottom: 0;
    flex-shrink: 0;
}

.case-study-editorial .cs-mission-desc {
    flex: 1 1 auto;
    min-width: min(100%, 200px);
    margin: 0;
}

/* Main content wrapper — 1050px centered, replaces .container.cs-content-section */
.cs-sections-wrapper {
    width: 100%;
    max-width: 1050px;
    margin: 0 auto;
    padding: 0 var(--space-24);
    display: flex;
    flex-direction: column;
    gap: var(--cs-gap-section);
    padding-bottom: var(--space-128);
    box-sizing: border-box;
}

/* Prose text: 600px centered within the 1050px column */
.case-study-editorial .cs-prose {
    max-width: var(--cs-prose-width);
    margin-left: auto;
    margin-right: auto;
    width: 100%;
    box-sizing: border-box;
}

.case-study-editorial .cs-h2-body--text.cs-prose {
    max-width: var(--cs-prose-width);
    width: 100%;
}

/* Media rail: full 1050px — no constraint, no negative margin trick */
.case-study-editorial .cs-media-rail {
    padding-left: 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.case-study-editorial section.cs-h2-section>h2.label-caps {
    margin-bottom: var(--cs-gap-h2-body);
}

.case-study-editorial .cs-h2-body--text {
    display: flex;
    flex-direction: column;
    gap: var(--cs-gap-paragraphs);
}

.case-study-editorial .cs-block-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-80);
    /* 80px to match .cs-decisions-rail */
}

.case-study-editorial .cs-block-list--compact {
    gap: var(--cs-gap-blocks-compact);
}

.case-study-editorial .cs-h2-body--narrow {
    max-width: none;
}

/* Pullquotes — 3 columns, full media width */
.case-study-editorial .cs-pullquote-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-24);
    margin-top: 0;
}

.case-study-editorial .cs-pullquote-grid .cs-pullquote {
    padding: var(--space-20) var(--space-20) var(--space-20) var(--space-24);
    font-size: var(--text-body-md-size);
    line-height: var(--line-height-relaxed);
}

/* Décisions clés — stacked layout (text 600px centré → visuel full 1050px) */
.case-study-editorial .cs-decisions-rail {
    display: flex;
    flex-direction: column;
    gap: var(--space-80);
}

.case-study-editorial .cs-decision-row {
    display: flex;
    flex-direction: column;
    gap: var(--cs-gap-text-media);
}

/* --reverse and --full are kept in HTML but no visual difference in stacked layout */
.case-study-editorial .cs-decision-row--reverse,
.case-study-editorial .cs-decision-row--full {
    direction: ltr;
}

.case-study-editorial .cs-decision-row__text {
    /* .cs-prose handles the 600px centering */
    display: flex;
    flex-direction: column;
    gap: var(--cs-gap-h3-body);
}

.case-study-editorial .cs-decision-row__media,
.case-study-editorial .cs-decision-row > figure {
    display: flex;
    flex-direction: column;
    gap: var(--cs-gap-media-caption);
    width: 100%;
    margin-inline: auto;
    align-items: center;
}

.case-study-editorial .cs-media-grid {
    display: grid;
    gap: var(--space-24);
    width: 100%;
    margin-inline: auto;
    align-items: start;
    justify-items: center;
}

.case-study-editorial .cs-compare-grid figure,
.case-study-editorial .cs-compare-after figure {
    display: flex;
    flex-direction: column;
    gap: var(--cs-gap-media-caption);
    margin: 0;
}

.case-study-editorial .cs-media-grid--pair figure {
    display: flex;
    flex-direction: column;
    gap: var(--cs-gap-media-caption);
    margin: 0;
}

.case-study-editorial .cs-decision-row__text h3,
.case-study-editorial .cs-decision-row__text p {
    margin: 0;
}

.case-study-editorial .cs-decision-row__media img,
.case-study-editorial .cs-decision-row img {
    max-height: 400px;
    height: auto;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    display: block;
    border-radius: var(--radius-12);
    margin-inline: auto;
}

.case-study-editorial .cs-compare-grid {
    display: grid;
    grid-template-columns: auto auto;
    gap: var(--space-24) var(--space-64);
    align-items: start;
    margin-inline: auto;
    width: fit-content;
    max-width: 100%;
    justify-content: center;
}

.case-study-editorial .cs-compare-after {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-24);
}

.case-study-editorial .cs-decision-row__media .cs-sheets-compare {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-48);
}

.case-study-editorial .cs-decision-row__media .cs-media-grid--pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-32);
}

.case-study-editorial .cs-block {
    display: flex;
    flex-direction: column;
}

.case-study-editorial .cs-block figure {
    width: 100%;
    margin-inline: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.case-study-editorial .cs-block img {
    max-height: none;
    height: auto;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    display: block;
    border-radius: var(--radius-12);
    margin-inline: auto;
}

/* H3 inside a cs-block: add top breathing room when preceded by media (figure/div) */
.case-study-editorial .cs-block>figure+.cs-block-intro,
.case-study-editorial .cs-block>.cs-figure-stack+.cs-block-intro,
.case-study-editorial .cs-block>.grid+.cs-block-intro,
.case-study-editorial .cs-block>.cs-media-grid+.cs-block-intro,
.case-study-editorial .cs-block>.cs-media-stack+.cs-block-intro,
.case-study-editorial .cs-block>div+.cs-block-intro {
    margin-top: var(--cs-gap-blocks);
}

.case-study-editorial .cs-block-intro {
    display: flex;
    flex-direction: column;
    gap: var(--cs-gap-h3-body);
    margin-bottom: var(--cs-gap-text-media);
}

.case-study-editorial .cs-block-intro:last-child {
    margin-bottom: 0;
}

.case-study-editorial .cs-block>.cs-pullquote-grid {
    margin-top: 0;
}

.case-study-editorial .cs-takeaways-grid {
    gap: var(--cs-gap-media-grid);
}

.case-study-editorial .cs-media-grid figure>.label-caps,
.case-study-editorial .cs-media-grid figure>span.label-caps,
.case-study-editorial .cs-media-grid figure>figcaption {
    display: block;
    margin-bottom: var(--cs-gap-media-caption);
}

.case-study-editorial .cs-figure-stack {
    display: flex;
    flex-direction: column;
    gap: var(--cs-gap-figures);
}

.case-study-editorial figure {
    margin: 0;
}

.case-study-editorial figure figcaption.caption,
.case-study-editorial figure .caption {
    margin-top: var(--cs-gap-media-caption);
}

.case-study-editorial .cs-block>.caption {
    margin-top: var(--cs-gap-media-caption);
}

.case-study-editorial .cs-media-grid {
    gap: var(--cs-gap-media-grid);
}

.case-study-editorial .cs-media-stack {
    display: flex;
    flex-direction: column;
    gap: var(--cs-gap-media-stack);
}

.case-study-editorial .cs-media-grid figure,
.case-study-editorial .cs-media-grid .cs-media-stack {
    display: flex;
    flex-direction: column;
    gap: var(--cs-gap-media-stack);
}

.case-study-editorial .cs-media-grid .label-caps {
    margin-bottom: var(--cs-gap-media-caption);
}

.case-study-editorial h2.label-caps {
    display: flex;
    align-items: center;
    gap: var(--space-16);
    width: 100%;
}

.case-study-editorial h2.label-caps::after {
    content: "";
    flex: 1 1 auto;
    min-width: var(--space-32);
    height: 1px;
    background: linear-gradient(to right,
            var(--color-white-alpha-24),
            var(--color-white-alpha-08) 55%,
            transparent 100%);
    transform: scaleX(0);
    transform-origin: left center;
    will-change: transform;
}

.case-study-editorial h2.label-caps.is-rule-visible::after {
    /* Delay so the parent fade-up (0.8s) has time to complete before the rule draws */
    animation: cs-h2-rule-draw 0.7s cubic-bezier(0.16, 1, 0.3, 1) 0.55s forwards;
}

@keyframes cs-h2-rule-draw {
    from {
        transform: scaleX(0);
    }

    to {
        transform: scaleX(1);
    }
}

.case-study-editorial .cs-pullquote-group {
    display: flex;
    flex-direction: column;
    gap: var(--space-20);
    margin-top: 0;
}

.case-study-editorial blockquote.cs-pullquote {
    margin: 0;
    padding: var(--space-24) var(--space-28) var(--space-24) var(--space-32);
    font-size: var(--text-body-lg-size);
    line-height: var(--text-body-lg-height);
    font-style: italic;
    font-weight: 500;
    color: var(--color-text-primary);
    background: var(--color-white-alpha-04);
    border-radius: var(--radius-16);
    border: 1px solid var(--color-white-alpha-08);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.22);
}

.case-study-editorial .cs-placeholder-media {
    min-height: 260px;
    border: 1px dashed var(--color-white-alpha-24);
    border-radius: var(--radius-16);
    background: var(--color-white-alpha-04);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-32);
    text-align: center;
    color: var(--color-text-muted);
}

.case-study-editorial .cs-placeholder-media span {
    max-width: 360px;
}

.case-study-editorial .cs-results-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-24);
}

/* Next case study CTA */
.cs-next-case {
    padding-top: var(--space-64);
    padding-bottom: var(--space-96);
}

.cs-next-label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-text-muted);
    margin-bottom: var(--space-24);
}

.cs-next-case-hook {
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: var(--space-40);
    color: var(--color-text-secondary);
}

.cs-next-case-hook em {
    font-family: "Playfair Display", serif;
    font-style: italic;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
}

@media (max-width: 992px) {
    .cs-sections-wrapper {
        padding: 0 var(--space-16);
    }

    .case-study-editorial .cs-mission-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .case-study-editorial .cs-pullquote-grid {
        grid-template-columns: 1fr;
    }

    .case-study-editorial .cs-compare-grid {
        grid-template-columns: 1fr;
        gap: var(--space-32);
    }

    .case-study-editorial .cs-compare-after {
        grid-template-columns: 1fr 1fr;
    }

    .case-study-editorial .cs-decision-row__media .cs-sheets-compare {
        grid-template-columns: 1fr;
        gap: var(--space-32);
    }

    .case-study-editorial .cs-decisions-rail {
        gap: var(--space-64);
    }
}

@media (max-width: 768px) {
    .cs-sections-wrapper {
        padding: 0 var(--space-16);
        gap: var(--space-64);
    }

    .case-study-editorial .cs-h2-section.fade-up {
        opacity: 1;
        transform: none;
    }

    .case-study-editorial .cs-compare-grid,
    .case-study-editorial .cs-compare-after,
    .case-study-editorial .cs-decision-row__media .cs-sheets-compare,
    .case-study-editorial .cs-decision-row__media .cs-media-grid--pair {
        grid-template-columns: 1fr;
        gap: var(--space-24);
    }
}

/* Language Switcher */
.nav-and-lang-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.lang-switch {
    display: flex;
    gap: 8px;
    margin-left: 48px;
    align-items: center;
    color: var(--color-text-secondary);
    font-size: 14px;
    font-weight: 500;
}

.lang-switch .lang-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: inherit;
    padding: 0;
    font-family: inherit;
    font-weight: inherit;
    transition: color 0.2s ease;
}

.lang-switch .lang-separator {
    opacity: 0.3;
}

.lang-switch .lang-btn:hover,
.lang-switch .lang-btn.active {
    color: var(--color-text-highlight);
}

.lang-switch .lang-btn.active {
    font-weight: 700;
}

@media (max-width: 768px) {
    .nav-and-lang-container {
        flex-direction: column;
        gap: var(--space-16);
        width: 100%;
        justify-content: center;
    }
    
    .lang-switch {
        margin-left: 0;
    }
}
