/**
 * Big Agency Theme - Main Stylesheet
 * Light. Airy. Refined. Animated.
 */

/* ============================================
   CSS CUSTOM PROPERTIES
   ============================================ */
:root {
    /* Alpine Color Palette */
    --color-sky: #4A90D9;
    --color-sky-dark: #3A7BC8;
    --color-sky-light: #7BB3E0;
    --color-sky-glow: rgba(74, 144, 217, 0.15);
    --color-lake: #2E8B8B;
    --color-lake-glow: rgba(46, 139, 139, 0.12);
    --color-stone: #8B9DAF;
    --color-pine: #5B8C5A;
    --color-pine-glow: rgba(91, 140, 90, 0.12);
    --color-sand: #D4956B;
    --color-sunset: #C97B4B;

    /* Neutrals */
    --color-black: #1A2332;
    --color-near-black: #243040;
    --color-dark: #2D3A4A;
    --color-white: #FFFFFF;
    --color-off-white: #EFF3F6;
    --color-gray: #6B7B8D;
    --color-light-gray: #E8ECF0;
    --color-subtle-gray: #F2F5F7;
    --color-warm-white: #FAFBFC;

    /* Typography */
    --font-display: 'Outfit', -apple-system, sans-serif;
    --font-body: 'Crimson Pro', Georgia, serif;

    /* Font Sizes */
    --text-xs: 0.75rem;
    --text-sm: 0.875rem;
    --text-base: 1rem;
    --text-lg: 1.125rem;
    --text-xl: 1.25rem;
    --text-2xl: 1.5rem;
    --text-3xl: 2rem;
    --text-4xl: 2.5rem;
    --text-5xl: 3.5rem;
    --text-6xl: 4.5rem;
    --text-7xl: 6rem;
    --text-8xl: 8rem;
    --text-9xl: 10rem;

    /* Spacing */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-24: 6rem;
    --space-32: 8rem;
    --space-40: 10rem;

    /* Layout */
    --container: 1400px;
    --radius: 0.5rem;
    --radius-lg: 1rem;
    --radius-xl: 1.5rem;

    /* Transitions */
    --ease-in: cubic-bezier(0.4, 0, 1, 1);
    --ease-out: cubic-bezier(0, 0, 0.2, 1);
    --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
    --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ============================================
   RESET & BASE
   ============================================ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-body);
    font-size: var(--text-lg);
    line-height: 1.7;
    color: var(--color-black);
    background-color: var(--color-white);
    overflow-x: hidden;
}

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

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

/* ============================================
   TYPOGRAPHY - ELEGANT SERIFS
   ============================================ */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: 1.1;
    letter-spacing: -0.01em;
    color: var(--color-black);
}

h1 { font-size: clamp(3rem, 8vw, var(--text-8xl)); }
h2 { font-size: clamp(2.5rem, 6vw, var(--text-7xl)); }
h3 { font-size: clamp(1.75rem, 3.5vw, var(--text-4xl)); }
h4 { font-size: var(--text-3xl); }
h5 { font-size: var(--text-2xl); }
h6 { font-size: var(--text-xl); }

.display-massive {
    font-size: clamp(3.5rem, 10vw, var(--text-9xl));
    font-weight: 700;
    line-height: 0.95;
    letter-spacing: -0.02em;
}

/* ============================================
   LAYOUT
   ============================================ */
.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--space-8);
}

.section {
    padding: var(--space-32) 0;
}

.section-xl {
    padding: var(--space-40) 0;
}

/* ============================================
   SECTION DIVIDERS
   ============================================ */
.section-divider {
    height: 1px;
    border: none;
    background: linear-gradient(90deg,
        transparent 0%,
        var(--color-sky-light) 20%,
        var(--color-sky) 50%,
        var(--color-sky-light) 80%,
        transparent 100%);
    opacity: 0.4;
    margin: 0;
}

.section-divider--subtle {
    height: 1px;
    border: none;
    background: linear-gradient(90deg,
        transparent 0%,
        var(--color-light-gray) 20%,
        var(--color-light-gray) 80%,
        transparent 100%);
    opacity: 1;
}

/* ============================================
   HEADER - CLEAN & TRANSPARENT
   ============================================ */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background-color: transparent;
    transition: all 0.4s var(--ease-out);
}

/* Hide logo while brand intro is animating */
.site-header .site-logo-img,
.site-header .custom-logo-link {
    transition: opacity 0.5s var(--ease-out), filter 0.4s var(--ease-out);
}

.site-header.brand-animating .site-logo-img,
.site-header.brand-animating .custom-logo-link {
    opacity: 0 !important;
    pointer-events: none;
}

.site-header.scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    box-shadow: 0 1px 0 var(--color-light-gray), 0 4px 20px rgba(26, 35, 50, 0.06);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-6) var(--space-8);
    max-width: var(--container);
    margin: 0 auto;
}

.site-branding {
    display: flex;
    align-items: center;
}

.site-logo {
    font-family: var(--font-display);
    font-size: var(--text-2xl);
    font-weight: 600;
    color: var(--color-black);
    letter-spacing: -0.01em;
}

.site-header.scrolled .site-logo {
    color: var(--color-black);
}

.site-logo-link {
    display: block;
    line-height: 0;
}

.site-logo-img {
    height: 50px;
    width: auto;
    max-width: 250px;
    display: block;
    filter: brightness(0);
    transition: opacity 0.5s var(--ease-out), filter 0.4s var(--ease-out);
}

.site-header.scrolled .site-logo-img,
.site-header.scrolled .custom-logo {
    filter: brightness(0);
}

.custom-logo {
    height: 50px;
    width: auto;
    max-width: 250px;
    filter: brightness(0);
    transition: opacity 0.5s var(--ease-out), filter 0.4s var(--ease-out);
}

.site-logo-img:hover {
    opacity: 0.7;
}

.custom-logo-link {
    display: block;
    line-height: 0;
}

.custom-logo {
    height: 50px;
    width: auto;
    max-width: 250px;
    display: block;
}

.primary-nav {
    display: flex;
    align-items: center;
}

.primary-nav ul {
    display: flex;
    list-style: none;
    gap: var(--space-8);
    align-items: center;
    margin: 0;
}

.primary-nav a {
    font-family: var(--font-body);
    font-weight: 500;
    font-size: var(--text-base);
    color: var(--color-black);
    transition: color 0.2s var(--ease-out);
    position: relative;
    letter-spacing: 0.02em;
}

.site-header.scrolled .primary-nav a {
    color: var(--color-black);
}

.primary-nav a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-sky);
    transition: width 0.3s var(--ease-out);
}

.primary-nav a:hover::after {
    width: 100%;
}

.primary-nav a:hover {
    color: var(--color-sky);
}

.site-header.scrolled .primary-nav a:hover {
    color: var(--color-sky);
}

/* Mobile Menu */
.menu-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    font-size: var(--text-3xl);
    cursor: pointer;
    color: var(--color-black);
}

.site-header.scrolled .menu-toggle {
    color: var(--color-black);
}

/* ============================================
   HERO - MOUNTAIN PHOTO WITH OVERLAY
   ============================================ */
.hero {
    min-height: 75vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    color: var(--color-white);
}

.hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center 40%;
    background-repeat: no-repeat;
    transition: transform 0.1s linear;
}

/* YouTube background video */
.hero-video-wrap {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.hero-video-wrap iframe {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100vw;
    height: 56.25vw; /* 16:9 */
    min-height: 100vh;
    min-width: 177.78vh; /* 16/9 * 100vh */
    transform: translate(-50%, -50%);
    border: 0;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(26, 35, 50, 0.35) 0%,
        rgba(26, 35, 50, 0.5) 50%,
        rgba(26, 35, 50, 0.7) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: var(--space-16);
    max-width: 1100px;
}

.hero h1 {
    color: var(--color-white);
    margin-bottom: var(--space-8);
    animation: fadeIn 1.2s var(--ease-out);
    text-shadow: 0 2px 40px rgba(0, 0, 0, 0.2);
}

.hero h1 .word {
    display: inline-block;
    animation: wordReveal 0.8s var(--ease-out) both;
}

@keyframes wordReveal {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.hero-tagline {
    font-family: var(--font-body);
    font-size: var(--text-2xl);
    font-weight: 300;
    margin-bottom: var(--space-12);
    opacity: 0.95;
    animation: slideUp 1s 0.3s var(--ease-out) both;
    letter-spacing: 0.01em;
}

.hero-cta {
    display: flex;
    gap: var(--space-6);
    justify-content: center;
    flex-wrap: wrap;
    animation: slideUp 1s 0.5s var(--ease-out) both;
}

/* ============================================
   BRAND INTRO — Ogilvy-style full-viewport brand
   ============================================ */
.brand-intro {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    background: var(--color-white);
}

.brand-intro__inner {
    text-align: center;
    padding: var(--space-8);
    position: relative;
    z-index: 2;
}

.brand-intro__name {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 9vw, 9rem);
    font-weight: 800;
    line-height: 0.92;
    letter-spacing: -0.04em;
    text-transform: uppercase;
    color: var(--color-black);
    margin: 0;
    max-width: 90vw;
    will-change: transform, opacity;
}

/* Fixed state during scroll animation */
.brand-intro__name.is-fixed {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1001;
    transform-origin: top left;
    pointer-events: none;
    margin: 0;
    padding: 0;
}

.brand-intro__tagline {
    font-family: var(--font-body);
    font-style: italic;
    font-size: clamp(1rem, 2vw, 1.5rem);
    font-weight: 300;
    color: var(--color-gray);
    margin-top: var(--space-6);
    letter-spacing: 0.02em;
    opacity: 1;
    transition: opacity 0.3s var(--ease-out);
}

/* Scroll hint at bottom */
.brand-intro__scroll-hint {
    position: absolute;
    bottom: var(--space-12);
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-3);
    animation: slideUp 1s 1.5s var(--ease-out) both;
    cursor: pointer;
}

.brand-intro__scroll-text {
    font-family: var(--font-body);
    font-size: var(--text-xs);
    color: var(--color-stone);
    text-transform: uppercase;
    letter-spacing: 0.2em;
    font-weight: 500;
}

.brand-intro__scroll-line {
    width: 1px;
    height: 40px;
    background: var(--color-light-gray);
    position: relative;
    overflow: hidden;
}

.brand-intro__scroll-line::after {
    content: '';
    position: absolute;
    top: -100%;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, transparent, var(--color-black), transparent);
    animation: scrollLineDown 2.2s ease-in-out infinite;
}

/* Spacer that holds the scroll distance for the animation */
.brand-intro__spacer {
    height: 100vh;
}

/* ============================================
   MANIFESTO — Fixed center, revealed during brand shrink,
   covered by work grid sliding up
   ============================================ */
.manifesto {
    height: 80vh;
    position: relative;
    background: var(--color-white);
}

.manifesto__inner {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    max-width: 800px;
    width: calc(100% - 4rem);
    text-align: center;
    z-index: 1;
    pointer-events: none;
    opacity: 0;
    will-change: opacity;
}

.manifesto__text {
    font-family: var(--font-body);
    font-style: italic;
    font-size: clamp(1.4rem, 2.8vw, 2.2rem);
    font-weight: 300;
    line-height: 1.65;
    color: var(--color-dark);
    letter-spacing: 0.01em;
    margin: 0;
}

/* ============================================
   WORK GRID — Portfolio masonry-like layout
   ============================================ */
.work-grid-section {
    padding: 0;
    background: transparent;
    position: relative;
    z-index: 2;
}

.work-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    max-width: 1800px;
    margin: 0 auto;
}

.work-grid__item {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    display: block;
    text-decoration: none;
    color: inherit;
    background: var(--color-near-black);
}

.work-grid__item img {
    width: 100%;
    display: block;
    transition: transform 0.7s var(--ease-out);
}

.work-grid__image--placeholder {
    width: 100%;
    aspect-ratio: 16 / 10;
}

.work-grid__item:hover img {
    transform: scale(1.06);
}

/* Overlay — hidden by default, reveals on hover */
.work-grid__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(26, 35, 50, 0.92) 0%,
        rgba(26, 35, 50, 0.4) 40%,
        transparent 70%
    );
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: var(--space-8);
    opacity: 0;
    transition: opacity 0.5s var(--ease-out);
}

.work-grid__item:hover .work-grid__overlay {
    opacity: 1;
}

.work-grid__category {
    font-family: var(--font-body);
    font-size: var(--text-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-sky-light);
    margin-bottom: var(--space-2);
    transform: translateY(12px);
    opacity: 0;
    transition: transform 0.5s 0.05s var(--ease-out), opacity 0.4s 0.05s var(--ease-out);
}

.work-grid__item:hover .work-grid__category {
    transform: translateY(0);
    opacity: 1;
}

.work-grid__title {
    font-family: var(--font-display);
    font-size: clamp(1.25rem, 2vw, 2rem);
    font-weight: 600;
    color: var(--color-white);
    line-height: 1.2;
    margin: 0;
    transform: translateY(16px);
    opacity: 0;
    transition: transform 0.5s 0.1s var(--ease-out), opacity 0.4s 0.1s var(--ease-out);
}

.work-grid__item:hover .work-grid__title {
    transform: translateY(0);
    opacity: 1;
}

/* ============================================
   BUTTONS - CLEAN & REFINED
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-4) var(--space-12);
    font-family: var(--font-body);
    font-size: var(--text-base);
    font-weight: 600;
    border-radius: var(--radius);
    transition: all 0.3s var(--ease-out);
    cursor: pointer;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
    letter-spacing: 0.02em;
}

.btn span {
    position: relative;
    z-index: 1;
}

.btn-primary {
    background: var(--color-sky);
    color: var(--color-white);
    border-color: var(--color-sky);
}

.btn-primary:hover {
    background: var(--color-sky-dark);
    border-color: var(--color-sky-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(74, 144, 217, 0.3);
}

.btn-secondary {
    background: transparent;
    color: var(--color-white);
    border-color: rgba(255, 255, 255, 0.5);
}

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

/* ============================================
   LOGO BAR
   ============================================ */
.logo-bar {
    background: transparent;
    border-top: none;
    border-bottom: none;
    padding: var(--space-8) 0;
    position: relative;
}

.logo-bar-label {
    text-align: center;
    font-size: var(--text-sm);
    color: var(--color-gray);
    font-weight: 400;
    margin-bottom: var(--space-6);
    text-transform: uppercase;
    letter-spacing: 0.15em;
}

.logo-bar-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: var(--space-4);
    align-items: center;
    max-width: var(--container);
    margin: 0 auto;
}

.logo-bar-item {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    opacity: 0.35;
    transition: all 0.4s var(--ease-out);
    padding: var(--space-2);
    filter: grayscale(100%) brightness(0);
}

.logo-bar-item:hover {
    opacity: 0.85;
    filter: grayscale(0%) brightness(0);
    transform: scale(1.05);
}

.client-logo-img {
    max-width: 100%;
    max-height: 50px;
    width: auto;
    height: auto;
    display: block;
    object-fit: contain;
}

/* ============================================
   WHY US SECTION
   ============================================ */
.why-us {
    background: var(--color-white);
    position: relative;
}

.section-title {
    text-align: center;
    margin-bottom: var(--space-24);
}

.section-subtitle {
    font-size: var(--text-xl);
    color: var(--color-gray);
    font-weight: 400;
    max-width: 750px;
    margin: var(--space-6) auto 0;
    line-height: 1.7;
}

.why-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--space-8);
    margin-top: var(--space-16);
    counter-reset: why-counter;
}

.why-card {
    padding: var(--space-12);
    padding-top: var(--space-16);
    background: var(--color-off-white);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-light-gray);
    transition: all 0.4s var(--ease-out);
    position: relative;
    overflow: hidden;
    counter-increment: why-counter;
}

.why-card::before {
    content: "0" counter(why-counter);
    position: absolute;
    top: -0.15em;
    right: var(--space-6);
    font-family: var(--font-display);
    font-size: 8rem;
    font-weight: 700;
    line-height: 1;
    color: var(--color-sky);
    opacity: 0.07;
    transition: opacity 0.4s var(--ease-out), transform 0.4s var(--ease-out);
    pointer-events: none;
}

.why-card:nth-child(2)::before { color: var(--color-lake); }
.why-card:nth-child(3)::before { color: var(--color-pine); }
.why-card:nth-child(4)::before { color: var(--color-sand); }
.why-card:nth-child(5)::before { color: var(--color-stone); }
.why-card:nth-child(6)::before { color: var(--color-sky); }

.why-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(26, 35, 50, 0.08);
    border-color: transparent;
}

.why-card:hover::before {
    opacity: 0.12;
    transform: scale(1.05);
}

.why-card h3 {
    margin-bottom: var(--space-4);
    font-size: var(--text-3xl);
    position: relative;
}

.why-card p {
    font-size: var(--text-base);
    line-height: 1.7;
    color: var(--color-gray);
    position: relative;
}

/* Experience callout */
.experience-callout {
    text-align: center;
    margin-top: var(--space-24);
    padding: var(--space-16);
    background: var(--color-off-white);
    border-radius: var(--radius-xl);
    border: 1px solid var(--color-light-gray);
}

.experience-callout h3 {
    font-size: var(--text-5xl);
    margin-bottom: var(--space-8);
    color: var(--color-black);
}

.experience-callout p {
    font-size: var(--text-xl);
    color: var(--color-gray);
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ============================================
   CASE STUDIES SECTION
   ============================================ */
.case-studies {
    background: var(--color-white);
    position: relative;
}

.case-studies-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-16);
    margin-top: var(--space-16);
}

.case-study-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-8);
    background: var(--color-off-white);
    border-radius: var(--radius-xl);
    overflow: hidden;
    transition: all 0.4s var(--ease-out);
    border: 1px solid var(--color-light-gray);
}

.case-study-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 48px rgba(26, 35, 50, 0.1);
    border-color: transparent;
}

/* Alternate layout for even items */
.case-study-card:nth-child(even) {
    grid-template-columns: 1fr 1fr;
}

.case-study-card:nth-child(even) .case-study-image {
    order: 2;
}

.case-study-card:nth-child(even) .case-study-content {
    order: 1;
}

.case-study-image {
    position: relative;
    min-height: 380px;
    background: var(--color-light-gray);
    overflow: hidden;
}

.case-study-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s var(--ease-out);
}

.case-study-card:hover .case-study-image img {
    transform: scale(1.05);
}

.case-study-content {
    padding: var(--space-12);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.case-study-content h3 {
    font-size: var(--text-4xl);
    margin-bottom: var(--space-3);
    color: var(--color-black);
}

.case-study-project {
    font-family: var(--font-body);
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--color-sky);
    margin-bottom: var(--space-6);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.case-study-content > p {
    font-size: var(--text-base);
    line-height: 1.7;
    color: var(--color-gray);
    margin-bottom: var(--space-8);
}

.case-study-results {
    list-style: none;
    margin: 0;
    padding: 0;
}

.case-study-results li {
    font-size: var(--text-base);
    line-height: 1.8;
    color: var(--color-black);
    margin-bottom: var(--space-3);
    padding-left: var(--space-8);
    position: relative;
}

.case-study-results li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.75em;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--color-sky);
}

.case-study-results strong {
    color: var(--color-black);
    font-weight: 600;
}

/* ============================================
   SERVICES - LIGHT GRAY BACKGROUND
   ============================================ */
.services {
    background: var(--color-off-white);
    position: relative;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
    gap: var(--space-8);
    margin-top: var(--space-16);
}

.service-card {
    padding: var(--space-12);
    background: var(--color-white);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-light-gray);
    transition: all 0.4s var(--ease-out);
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.service-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 48px rgba(26, 35, 50, 0.1);
    border-color: transparent;
    background: var(--color-white);
}

.service-tagline {
    display: inline-block;
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-weight: 600;
    margin-bottom: var(--space-6);
    padding: var(--space-1) var(--space-4);
    border-radius: 100px;
    background: rgba(74, 144, 217, 0.1);
    color: var(--color-sky);
}

.service-card:nth-child(2) .service-tagline {
    background: rgba(46, 139, 139, 0.1);
    color: var(--color-lake);
}
.service-card:nth-child(3) .service-tagline {
    background: rgba(91, 140, 90, 0.1);
    color: var(--color-pine);
}
.service-card:nth-child(4) .service-tagline {
    background: rgba(212, 149, 107, 0.12);
    color: var(--color-sand);
}
.service-card:nth-child(5) .service-tagline {
    background: rgba(139, 157, 175, 0.12);
    color: var(--color-stone);
}
.service-card:nth-child(6) .service-tagline {
    background: rgba(74, 144, 217, 0.1);
    color: var(--color-sky);
}

.service-card h3 {
    margin-bottom: var(--space-4);
    color: var(--color-black);
    font-size: var(--text-3xl);
    position: relative;
    display: inline-block;
}

.service-card p {
    font-size: var(--text-base);
    line-height: 1.7;
    color: var(--color-gray);
}

/* ============================================
   CLIENTS - WHITE BACKGROUND
   ============================================ */
.clients {
    background: var(--color-white);
    text-align: center;
}

.clients-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: var(--space-8);
    margin-top: var(--space-24);
    align-items: center;
}

.client-item {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.45;
    transition: all 0.4s var(--ease-out);
    filter: grayscale(100%);
}

.client-item:hover {
    opacity: 1;
    transform: scale(1.05);
    filter: grayscale(0%);
}

.client-item .client-logo-img {
    max-width: 220px;
    max-height: 80px;
}

/* ============================================
   PORTFOLIO - LIGHT GRAY BACKGROUND
   ============================================ */
.portfolio {
    background: var(--color-white);
    position: relative;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: var(--space-8);
    margin-top: var(--space-16);
}

.portfolio-item {
    position: relative;
    aspect-ratio: 16 / 10;
    border-radius: var(--radius-lg);
    overflow: hidden;
    cursor: pointer;
    transition: all 0.4s var(--ease-out);
    box-shadow: 0 2px 12px rgba(26, 35, 50, 0.06);
}

.portfolio-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 48px rgba(26, 35, 50, 0.12);
}

.portfolio-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s var(--ease-out);
}

.portfolio-item:hover .portfolio-image {
    transform: scale(1.08);
}

.portfolio-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top,
        rgba(26, 35, 50, 0.85) 0%,
        rgba(26, 35, 50, 0.25) 40%,
        transparent 70%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: var(--space-8);
    transition: background 0.5s var(--ease-out);
}

.portfolio-item:hover .portfolio-overlay {
    background: linear-gradient(to top,
        rgba(26, 35, 50, 0.92) 0%,
        rgba(26, 35, 50, 0.6) 50%,
        rgba(26, 35, 50, 0.2) 100%);
}

.portfolio-overlay h3 {
    display: inline-block;
    color: var(--color-white);
    font-size: var(--text-2xl);
    margin-bottom: 0;
    padding: var(--space-2) var(--space-4);
    background: rgba(74, 144, 217, 0.2);
    backdrop-filter: blur(8px);
    border-radius: 100px;
    transition: all 0.4s var(--ease-out);
    align-self: flex-start;
}

.portfolio-item:hover .portfolio-overlay h3 {
    background: rgba(74, 144, 217, 0.35);
    margin-bottom: var(--space-3);
}

.portfolio-overlay p {
    color: rgba(255, 255, 255, 0.9);
    font-size: var(--text-base);
    line-height: 1.6;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transform: translateY(12px);
    transition: max-height 0.5s var(--ease-out),
                opacity 0.4s 0.1s var(--ease-out),
                transform 0.4s 0.1s var(--ease-out);
}

.portfolio-item:hover .portfolio-overlay p {
    max-height: 6em;
    opacity: 1;
    transform: translateY(0);
}

/* ============================================
   FINAL PITCH - SOFT DARK SECTION
   ============================================ */
.final-pitch {
    background: var(--color-black);
    color: var(--color-white);
    text-align: center;
    position: relative;
}

.final-pitch h2 {
    color: var(--color-white);
    font-size: clamp(2.5rem, 6vw, var(--text-7xl));
    margin-bottom: var(--space-8);
}

.final-pitch-text {
    font-size: var(--text-xl);
    color: rgba(255, 255, 255, 0.7);
    max-width: 800px;
    margin: 0 auto var(--space-12);
    line-height: 1.7;
}

.final-pitch .btn-primary {
    background: var(--color-sky);
    color: var(--color-white);
    border-color: var(--color-sky);
    font-size: var(--text-xl);
    padding: var(--space-6) var(--space-16);
}

.final-pitch .btn-primary:hover {
    background: var(--color-sky-dark);
    border-color: var(--color-sky-dark);
}

/* ============================================
   CONTACT - SOFT BLUE GRADIENT
   ============================================ */
.contact {
    background: linear-gradient(135deg, var(--color-sky) 0%, var(--color-lake) 100%);
    color: var(--color-white);
    text-align: center;
    position: relative;
}

.contact h2 {
    color: var(--color-white);
    font-size: clamp(2.5rem, 6vw, var(--text-7xl));
    margin-bottom: var(--space-12);
}

.contact-intro {
    font-size: var(--text-xl);
    margin-bottom: var(--space-16);
    opacity: 0.9;
}

.contact-info {
    display: flex;
    justify-content: center;
    gap: var(--space-16);
    margin-top: var(--space-8);
    flex-wrap: wrap;
}

.contact-item {
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
}

.contact-item a {
    font-family: var(--font-display);
    font-size: clamp(var(--text-xl), 4vw, var(--text-4xl));
    font-weight: 600;
    color: var(--color-white);
    transition: all 0.3s var(--ease-out);
    display: inline-block;
    word-break: break-word;
}

.contact-item a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-white);
    transition: width 0.3s var(--ease-out);
}

.contact-item a:hover {
    opacity: 0.85;
}

/* Contact form wrapper */
.contact-form-wrapper {
    max-width: 700px;
    margin: var(--space-24) auto 0;
    background: rgba(255, 255, 255, 0.12);
    padding: var(--space-16);
    border-radius: var(--radius-xl);
    backdrop-filter: blur(20px);
}

.contact-form-wrapper h3 {
    color: var(--color-white);
    text-align: center;
    margin-bottom: var(--space-8);
    font-size: var(--text-3xl);
}

/* ============================================
   FOOTER - DARK & CLEAN
   ============================================ */
.site-footer {
    background: var(--color-black);
    color: rgba(255, 255, 255, 0.6);
    position: relative;
}

.site-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg,
        transparent 0%,
        var(--color-sky-light) 20%,
        var(--color-sky) 50%,
        var(--color-sky-light) 80%,
        transparent 100%);
    opacity: 0.4;
}

.footer-main {
    padding: var(--space-24) 0 var(--space-16);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: var(--space-16);
    align-items: start;
}

.footer-brand .footer-logo {
    font-family: var(--font-display);
    font-size: var(--text-3xl);
    font-weight: 600;
    color: var(--color-white);
    display: inline-block;
    margin-bottom: var(--space-6);
}

.footer-brand .footer-logo img {
    height: 40px;
    width: auto;
    filter: brightness(0) invert(1);
    opacity: 0.9;
}

.footer-brand p {
    font-size: var(--text-base);
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.5);
    max-width: 320px;
}

.footer-heading {
    font-family: var(--font-body);
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--color-white);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    margin-bottom: var(--space-6);
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: var(--space-3);
}

.footer-links a {
    font-size: var(--text-base);
    color: rgba(255, 255, 255, 0.5);
    transition: all 0.3s var(--ease-out);
}

.footer-links a:hover {
    color: var(--color-white);
    padding-left: var(--space-2);
}

.footer-contact-info p {
    font-size: var(--text-base);
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: var(--space-3);
}

.footer-contact-info a {
    color: rgba(255, 255, 255, 0.5);
    transition: color 0.3s var(--ease-out);
}

.footer-contact-info a:hover {
    color: var(--color-sky-light);
}

.footer-social {
    display: none;
}

.footer-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.6);
    font-size: var(--text-lg);
    transition: all 0.3s var(--ease-out);
}

.footer-social a:hover {
    border-color: var(--color-sky-light);
    color: var(--color-sky-light);
    transform: translateY(-2px);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: var(--space-8) 0;
}

.footer-bottom-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--space-4);
}

.footer-bottom p {
    margin: 0;
    font-size: var(--text-sm);
    color: rgba(255, 255, 255, 0.35);
}

.footer-bottom-tagline {
    font-size: var(--text-sm);
    color: rgba(255, 255, 255, 0.35);
    font-style: italic;
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.92);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes shimmer {
    0% { background-position: -200% center; }
    100% { background-position: 200% center; }
}

@keyframes gentleFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}

@keyframes drawLine {
    from { width: 0; }
    to { width: 100%; }
}

@keyframes pulseGlow {
    0%, 100% { box-shadow: 0 0 0 0 rgba(74, 144, 217, 0.15); }
    50% { box-shadow: 0 0 0 12px rgba(74, 144, 217, 0); }
}

/* Scroll reveal — multiple variants */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out), filter 0.8s var(--ease-out);
    filter: blur(2px);
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
}

/* Stagger children within revealed parents */
.scroll-reveal-stagger > * {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s var(--ease-out), transform 0.6s var(--ease-out);
}

.scroll-reveal-stagger.revealed > *:nth-child(1) { transition-delay: 0s; }
.scroll-reveal-stagger.revealed > *:nth-child(2) { transition-delay: 0.1s; }
.scroll-reveal-stagger.revealed > *:nth-child(3) { transition-delay: 0.2s; }
.scroll-reveal-stagger.revealed > *:nth-child(4) { transition-delay: 0.3s; }
.scroll-reveal-stagger.revealed > *:nth-child(5) { transition-delay: 0.4s; }
.scroll-reveal-stagger.revealed > *:nth-child(6) { transition-delay: 0.5s; }

.scroll-reveal-stagger.revealed > * {
    opacity: 1;
    transform: translateY(0);
}

/* Section title accent mark — fades in on reveal */
.section-title h2 {
    position: relative;
    display: inline-block;
}

.section-title h2::before {
    content: '';
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 2px;
    background: var(--color-sky);
    border-radius: 1px;
    opacity: 0;
    transition: opacity 0.6s 0.4s var(--ease-out);
}

.scroll-reveal.revealed .section-title h2::before,
.section-title.revealed h2::before {
    opacity: 1;
}

/* Subtle hover lift + glow for interactive cards */
.why-card,
.service-card,
.case-study-card {
    transition: transform 0.4s var(--ease-out),
                box-shadow 0.4s var(--ease-out),
                border-color 0.4s var(--ease-out);
}

/* Logo bar gentle infinite drift */
.logo-bar-item {
    transition: transform 0.4s var(--ease-spring), opacity 0.4s var(--ease-out);
}

.logo-bar-item:hover {
    transform: scale(1.08) translateY(-2px);
    opacity: 1 !important;
}

/* Button micro-interaction: slight press + shimmer */
.btn {
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    transition: left 0.5s ease;
}

.btn:hover::after {
    left: 100%;
}

.btn:active {
    transform: scale(0.97);
}

/* Hero scroll indicator */
.hero-scroll-hint {
    position: absolute;
    bottom: var(--space-12);
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-3);
    animation: slideUp 1s 1.8s var(--ease-out) both;
    cursor: pointer;
}

.hero-scroll-text {
    font-family: var(--font-body);
    font-size: var(--text-xs);
    color: rgba(255, 255, 255, 0.45);
    text-transform: uppercase;
    letter-spacing: 0.2em;
    font-weight: 500;
}

.hero-scroll-line {
    width: 1px;
    height: 40px;
    background: rgba(255, 255, 255, 0.15);
    position: relative;
    overflow: hidden;
}

.hero-scroll-line::after {
    content: '';
    position: absolute;
    top: -100%;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, 0.6), transparent);
    animation: scrollLineDown 2.2s ease-in-out infinite;
}

@keyframes scrollLineDown {
    0% { top: -100%; }
    50% { top: 100%; }
    100% { top: 100%; }
}

/* Experience callout gentle float */
.experience-callout {
    transition: transform 0.4s var(--ease-out), box-shadow 0.4s var(--ease-out);
}

.experience-callout:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(26, 35, 50, 0.1);
}

/* Final pitch section subtle gradient shift */
.final-pitch {
    background-size: 200% 200%;
    animation: gradientDrift 12s ease-in-out infinite;
}

@keyframes gradientDrift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* Contact section: animated divider between phone and email */
.contact-info::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 1px;
    height: 40px;
    background: rgba(255, 255, 255, 0.2);
    display: none;
}

@media (min-width: 769px) {
    .contact-info {
        position: relative;
    }
    .contact-info::before {
        display: block;
    }
}

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

    .scroll-reveal {
        opacity: 1;
        transform: none;
        filter: none;
    }

    .scroll-reveal-stagger > * {
        opacity: 1;
        transform: none;
    }

    .hero-scroll-line::after {
        animation: none;
    }
}

/* ============================================
   GRAVITY FORMS STYLING
   ============================================ */
.catalyst-bold-form input,
.catalyst-bold-form textarea,
.catalyst-bold-form select {
    font-family: var(--font-body);
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) and (min-width: 769px) {
    .logo-bar-grid {
        grid-template-columns: repeat(6, 1fr);
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-12);
    }
}

@media (max-width: 768px) {
    :root {
        --space-32: 4rem;
        --space-40: 6rem;
    }

    .menu-toggle {
        display: flex;
    }

    .primary-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        box-shadow: 0 4px 20px rgba(26, 35, 50, 0.08);
    }

    .primary-nav.active {
        display: block;
    }

    .primary-nav ul {
        flex-direction: column;
        padding: var(--space-6);
        gap: 0;
    }

    .primary-nav li {
        width: 100%;
        border-bottom: 1px solid var(--color-light-gray);
    }

    .primary-nav a {
        display: block;
        padding: var(--space-6);
        color: var(--color-black);
    }

    .services-grid,
    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    /* Brand intro: smaller text, no fixed animation */
    .brand-intro__name {
        font-size: clamp(2.5rem, 12vw, 5rem);
        white-space: normal;
    }

    .logo-bar-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: var(--space-3);
    }

    .client-logo-img {
        max-height: 40px;
    }

    .case-study-card {
        grid-template-columns: 1fr !important;
        gap: 0;
    }

    .case-study-card:nth-child(even) .case-study-image,
    .case-study-card:nth-child(even) .case-study-content {
        order: unset !important;
    }

    .case-study-image {
        min-height: 280px;
    }

    .case-study-content {
        padding: var(--space-8);
    }

    .case-study-content h3 {
        font-size: var(--text-3xl);
    }

    .why-grid {
        grid-template-columns: 1fr;
    }

    .btn {
        font-size: var(--text-base);
        padding: var(--space-4) var(--space-8);
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: var(--space-12);
    }

    .footer-bottom-inner {
        flex-direction: column;
        text-align: center;
    }

    .contact-info {
        flex-direction: column;
        gap: var(--space-8);
        align-items: center;
    }

    .contact-item a {
        font-size: var(--text-2xl);
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: var(--text-5xl);
    }

    .hero-tagline {
        font-size: var(--text-xl);
    }

    .contact-info {
        gap: var(--space-8);
    }

    .contact-item a {
        font-size: var(--text-lg);
    }
}

/* ============================================
   UTILITY CLASSES
   ============================================ */
.text-center { text-align: center; }
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* ============================================
   PORTFOLIO DETAIL PAGE
   ============================================ */

/* Detail Hero */
.portfolio-detail-hero {
    min-height: 60vh;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    position: relative;
    overflow: hidden;
    color: var(--color-white);
    padding-bottom: var(--space-16);
}

.portfolio-detail-hero .hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.portfolio-detail-hero .hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(26, 35, 50, 0.2) 0%,
        rgba(26, 35, 50, 0.55) 50%,
        rgba(26, 35, 50, 0.85) 100%
    );
}

.portfolio-detail-hero .hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: var(--space-16) var(--space-8) 0;
    max-width: 1000px;
    width: 100%;
}

.portfolio-detail-hero h1 {
    color: var(--color-white);
    font-size: clamp(2.5rem, 7vw, var(--text-7xl));
    margin-bottom: var(--space-6);
    animation: fadeIn 1s var(--ease-out);
    text-shadow: 0 2px 30px rgba(0, 0, 0, 0.2);
}

.portfolio-detail-hero .hero-tagline {
    font-family: var(--font-body);
    font-size: var(--text-xl);
    font-weight: 300;
    opacity: 0.9;
    margin-bottom: var(--space-8);
    animation: slideUp 0.8s 0.2s var(--ease-out) both;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.portfolio-detail-meta {
    display: flex;
    justify-content: center;
    gap: var(--space-8);
    font-family: var(--font-body);
    font-size: var(--text-sm);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    opacity: 0.75;
    animation: slideUp 0.8s 0.4s var(--ease-out) both;
    flex-wrap: wrap;
}

.portfolio-detail-meta span {
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

.portfolio-detail-meta .meta-divider {
    opacity: 0.4;
}

/* Overview Bar */
.portfolio-overview {
    background: var(--color-white);
    border-bottom: 1px solid var(--color-light-gray);
    padding: var(--space-16) 0;
}

.portfolio-highlights {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-8);
    max-width: 900px;
    margin: 0 auto;
    text-align: center;
}

.portfolio-highlight-item {
    padding: var(--space-6);
}

.portfolio-highlight-number {
    font-family: var(--font-display);
    font-size: var(--text-5xl);
    font-weight: 700;
    color: var(--color-sky);
    line-height: 1.1;
    margin-bottom: var(--space-2);
}

.portfolio-highlight-label {
    font-family: var(--font-body);
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--color-gray);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.portfolio-services-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--space-3);
    margin-top: var(--space-8);
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.portfolio-service-tag {
    display: inline-block;
    font-size: var(--text-xs);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 600;
    padding: var(--space-1) var(--space-4);
    border-radius: 100px;
    background: rgba(74, 144, 217, 0.1);
    color: var(--color-sky);
}

/* Content Area */
.portfolio-content {
    max-width: 900px;
    margin: 0 auto;
    padding: var(--space-24) var(--space-8);
}

.portfolio-content h2 {
    font-size: clamp(1.75rem, 4vw, var(--text-4xl));
    margin-top: var(--space-16);
    margin-bottom: var(--space-6);
    color: var(--color-black);
}

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

.portfolio-content h3 {
    font-size: clamp(1.4rem, 3vw, var(--text-3xl));
    margin-top: var(--space-12);
    margin-bottom: var(--space-4);
    color: var(--color-black);
}

.portfolio-content p {
    font-size: var(--text-lg);
    line-height: 1.8;
    color: var(--color-dark);
    margin-bottom: var(--space-6);
}

.portfolio-content ul,
.portfolio-content ol {
    font-size: var(--text-lg);
    line-height: 1.8;
    color: var(--color-dark);
    margin-bottom: var(--space-6);
    padding-left: var(--space-8);
}

.portfolio-content li {
    margin-bottom: var(--space-2);
}

.portfolio-content blockquote {
    border-left: 4px solid var(--color-sky);
    padding: var(--space-6) var(--space-8);
    margin: var(--space-8) 0;
    background: var(--color-white);
    border-radius: 0 var(--radius) var(--radius) 0;
    font-style: italic;
    color: var(--color-dark);
}

.portfolio-content img {
    border-radius: var(--radius-lg);
    margin: var(--space-8) 0;
}

/* Portfolio Carousel */
.portfolio-carousel {
    position: relative;
    max-width: var(--container);
    margin: 0 auto var(--space-8);
    padding: var(--space-8) var(--space-8) 0;
}

.portfolio-carousel-viewport {
    overflow: hidden;
    border-radius: var(--radius-lg);
    box-shadow: 0 4px 24px rgba(26, 35, 50, 0.08);
}

.portfolio-carousel-track {
    display: flex;
    transition: transform 0.5s var(--ease-out);
    will-change: transform;
}

.portfolio-carousel-slide {
    flex: 0 0 100%;
    aspect-ratio: 16 / 9;
    position: relative;
    background: var(--color-light-gray);
}

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

.portfolio-carousel-slide--video {
    background: var(--color-black);
}

.portfolio-carousel-slide--video iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

/* Carousel arrows */
.portfolio-carousel-prev,
.portfolio-carousel-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: rgba(26, 35, 50, 0.45);
    backdrop-filter: blur(8px);
    color: var(--color-white);
    font-size: 1.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.25s var(--ease-out);
    line-height: 1;
    padding: 0;
}

.portfolio-carousel-prev { left: calc(var(--space-8) + 8px); }
.portfolio-carousel-next { right: calc(var(--space-8) + 8px); }

.portfolio-carousel-prev:hover,
.portfolio-carousel-next:hover {
    background: rgba(26, 35, 50, 0.7);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-50%) scale(1.08);
}

/* Carousel dots */
.portfolio-carousel-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: var(--space-4);
    padding-bottom: var(--space-4);
}

.portfolio-carousel-dots button {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    border: none;
    background: var(--color-light-gray);
    cursor: pointer;
    padding: 0;
    transition: all 0.3s var(--ease-out);
}

.portfolio-carousel-dots button.active {
    background: var(--color-sky);
    width: 24px;
    border-radius: 4px;
}

/* Lightbox */
.portfolio-lightbox {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
}

.portfolio-lightbox.active {
    display: flex;
}

.portfolio-lightbox-overlay {
    position: absolute;
    inset: 0;
    background: rgba(26, 35, 50, 0.95);
    opacity: 0;
    transition: opacity 0.3s var(--ease-out);
}

.portfolio-lightbox.active .portfolio-lightbox-overlay {
    opacity: 1;
}

.portfolio-lightbox-content {
    position: relative;
    z-index: 2;
    max-width: 90vw;
    max-height: 85vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.portfolio-lightbox-content img {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: var(--radius);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    opacity: 0;
    transform: scale(0.95);
    transition: all 0.3s var(--ease-out);
}

.portfolio-lightbox.active .portfolio-lightbox-content img {
    opacity: 1;
    transform: scale(1);
}

.portfolio-lightbox-close {
    position: absolute;
    top: var(--space-6);
    right: var(--space-6);
    z-index: 3;
    background: none;
    border: none;
    color: var(--color-white);
    font-size: 2.5rem;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s var(--ease-out);
    line-height: 1;
    padding: var(--space-2);
}

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

.portfolio-lightbox-prev,
.portfolio-lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--color-white);
    font-size: 2rem;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s var(--ease-out);
    line-height: 1;
}

.portfolio-lightbox-prev { left: var(--space-6); }
.portfolio-lightbox-next { right: var(--space-6); }

.portfolio-lightbox-prev:hover,
.portfolio-lightbox-next:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
}

.portfolio-lightbox-counter {
    position: absolute;
    bottom: var(--space-6);
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    color: rgba(255, 255, 255, 0.6);
    font-family: var(--font-body);
    font-size: var(--text-sm);
    letter-spacing: 0.1em;
}

/* Category Tags on Detail Page */
.portfolio-categories {
    text-align: center;
    padding: var(--space-12) var(--space-8);
    border-top: 1px solid var(--color-light-gray);
}

.portfolio-categories-label {
    font-family: var(--font-body);
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--color-gray);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: var(--space-4);
}

.portfolio-category-tag {
    display: inline-block;
    margin: var(--space-1);
    padding: var(--space-2) var(--space-6);
    background: var(--color-white);
    border: 1px solid var(--color-light-gray);
    border-radius: var(--radius);
    font-weight: 600;
    font-size: var(--text-sm);
    color: var(--color-black);
    border: 1px solid var(--color-light-gray);
}

/* Next Project Navigation */
.portfolio-next {
    background: var(--color-black);
    padding: var(--space-16) 0;
    text-align: center;
}

.portfolio-next a {
    display: inline-block;
    text-decoration: none;
    color: var(--color-white);
    transition: all 0.3s var(--ease-out);
}

.portfolio-next a:hover {
    transform: translateY(-2px);
}

.portfolio-next-label {
    font-family: var(--font-body);
    font-size: var(--text-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: var(--space-4);
}

.portfolio-next-title {
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 4vw, var(--text-4xl));
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: var(--space-2);
    transition: color 0.3s var(--ease-out);
}

.portfolio-next a:hover .portfolio-next-title {
    color: var(--color-sky-light);
}

.portfolio-next-arrow {
    font-size: var(--text-2xl);
    opacity: 0.5;
    transition: all 0.3s var(--ease-out);
    display: inline-block;
}

.portfolio-next a:hover .portfolio-next-arrow {
    opacity: 1;
    transform: translateX(4px);
}

/* Back to Work Link */
.portfolio-back {
    text-align: center;
    padding: var(--space-12) 0;
    background: var(--color-white);
    border-top: 1px solid var(--color-light-gray);
}

.portfolio-back .btn {
    border-color: var(--color-black);
    color: var(--color-black);
}

.portfolio-back .btn:hover {
    background: var(--color-black);
    color: var(--color-white);
    border-color: var(--color-black);
}

/* Clickable portfolio items on front page */
a.portfolio-item {
    display: block;
    text-decoration: none;
    color: inherit;
}

/* ============================================
   PORTFOLIO DETAIL RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .portfolio-detail-hero {
        min-height: 50vh;
    }

    .portfolio-detail-meta {
        flex-direction: column;
        gap: var(--space-2);
    }

    .portfolio-detail-meta .meta-divider {
        display: none;
    }

    .portfolio-highlights {
        grid-template-columns: 1fr;
        gap: var(--space-4);
    }

    .portfolio-highlight-item {
        padding: var(--space-4);
        border-bottom: 1px solid var(--color-light-gray);
    }

    .portfolio-highlight-item:last-child {
        border-bottom: none;
    }

    .portfolio-carousel-prev,
    .portfolio-carousel-next {
        width: 36px;
        height: 36px;
        font-size: 1.2rem;
    }

    .portfolio-carousel-prev { left: calc(var(--space-4) + 6px); }
    .portfolio-carousel-next { right: calc(var(--space-4) + 6px); }

    .portfolio-lightbox-prev,
    .portfolio-lightbox-next {
        width: 40px;
        height: 40px;
        font-size: 1.5rem;
    }

    .portfolio-lightbox-prev { left: var(--space-3); }
    .portfolio-lightbox-next { right: var(--space-3); }

    .portfolio-content {
        padding: var(--space-16) var(--space-6);
    }
}

@media (max-width: 480px) {
    .portfolio-carousel {
        padding: var(--space-4) var(--space-4) 0;
    }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */
.user-is-tabbing *:focus {
    outline: 2px solid var(--color-sky);
    outline-offset: 2px;
}
