/* ===========================
   CASCADE VENTURE PARTNERS
   V2 — Dynamic Redesign
   =========================== */

:root {
    --color-bg: #0a0a0a;
    --color-bg-alt: #111111;
    --color-surface: #1a1a1a;
    --color-border: rgba(255, 255, 255, 0.08);
    --color-text: #ede9e5;
    --color-text-muted: #a59e97;
    --color-gold: #c9a84c;
    --color-gold-light: #dbb960;
    --color-white: #ffffff;
    --font-display: 'Cormorant Garamond', Georgia, serif;
    --font-serif: 'Playfair Display', Georgia, serif;
    --font-sans: 'Inter', -apple-system, sans-serif;
    --container-max: 1280px;
    --section-padding: 140px;
}

/* Reset */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; font-size: 16px; }

body {
    font-family: var(--font-sans);
    background-color: var(--color-bg);
    color: var(--color-text);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 60px;
}

/* ===========================
   NAVIGATION
   =========================== */

.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 1000;
    padding: 24px 0;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.navbar.scrolled {
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 16px 0;
    border-bottom: 1px solid var(--color-border);
}

.nav-container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo { display: flex; align-items: center; gap: 12px; }
.logo-mark { color: var(--color-gold); }

.logo-text {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 400;
    letter-spacing: 0.04em;
    color: var(--color-white);
}

.nav-links { display: flex; align-items: center; gap: 36px; }

.nav-links a {
    font-size: 0.78rem;
    font-weight: 400;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.6);
    transition: color 0.3s ease;
    position: relative;
}

.nav-links a:hover { color: var(--color-white); }
.nav-links a::after {
    content: ''; position: absolute; bottom: -4px; left: 0;
    width: 0; height: 1px; background: var(--color-gold);
    transition: width 0.3s ease;
}
.nav-links a:hover::after { width: 100%; }

.nav-cta {
    border: 1px solid var(--color-gold) !important;
    padding: 10px 24px !important;
    color: var(--color-gold) !important;
    transition: all 0.3s ease !important;
}
.nav-cta:hover { background: var(--color-gold) !important; color: var(--color-bg) !important; }
.nav-cta::after { display: none !important; }

.menu-toggle {
    display: none; background: none; border: none; cursor: pointer;
    width: 28px; height: 20px; position: relative; z-index: 1001;
}
.menu-toggle span {
    display: block; width: 100%; height: 1.5px;
    background: var(--color-white); transition: all 0.3s ease;
}
.menu-toggle span:first-child { margin-bottom: 8px; }
.menu-toggle.active span:first-child { transform: rotate(45deg) translate(3px, 3px); }
.menu-toggle.active span:last-child { transform: rotate(-45deg) translate(3px, -3px); }

/* Mobile Menu */
.mobile-menu {
    position: fixed; inset: 0; background: var(--color-bg); z-index: 999;
    display: flex; align-items: center; justify-content: center;
    opacity: 0; pointer-events: none; transition: opacity 0.4s ease;
}
.mobile-menu.active { opacity: 1; pointer-events: all; }
.mobile-menu-links { display: flex; flex-direction: column; gap: 32px; text-align: center; }
.mobile-menu-links a {
    font-family: var(--font-display); font-size: 2.5rem; font-weight: 300;
    color: var(--color-text); transition: color 0.3s ease;
}
.mobile-menu-links a:hover { color: var(--color-gold); }

/* ===========================
   HERO — Full-bleed image
   =========================== */

.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: flex-end;
    padding-bottom: 80px;
    overflow: hidden;
}

.hero-bg {
    position: absolute; inset: 0;
}

.hero-bg-img {
    width: 100%; height: 100%;
    object-fit: cover;
    object-position: center 30%;
    transform: scale(1.1);
    transition: transform 8s ease-out;
}

.hero-bg-img.loaded { transform: scale(1); }

.hero-overlay {
    position: absolute; inset: 0;
    background:
        linear-gradient(180deg, rgba(10,10,10,0.5) 0%, rgba(10,10,10,0.3) 40%, rgba(10,10,10,0.7) 80%, rgba(10,10,10,1) 100%),
        linear-gradient(90deg, rgba(10,10,10,0.6) 0%, transparent 50%);
}

.hero-content {
    position: relative; z-index: 2;
    max-width: var(--container-max);
    margin: 0 auto; padding: 0 60px; width: 100%;
}

.hero-label {
    font-size: 0.72rem; font-weight: 500;
    letter-spacing: 0.25em; text-transform: uppercase;
    color: var(--color-gold);
    margin-bottom: 28px;
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(3.5rem, 8vw, 7rem);
    font-weight: 300;
    line-height: 1.18;
    color: var(--color-white);
    margin-bottom: 32px;
    padding-bottom: 0.15em;
}

.title-line {
    display: block;
    /* removed overflow: hidden — was clipping descenders like g, y */
    padding-bottom: 0.05em;
}

.hero-subtitle {
    font-size: 1.1rem; font-weight: 300;
    color: var(--color-text-muted);
    max-width: 520px; line-height: 1.8;
    margin-bottom: 56px;
}

.hero-stats {
    display: flex; align-items: center; gap: 40px;
}

.stat { display: flex; flex-direction: column; gap: 4px; }

.stat-number {
    font-family: var(--font-display);
    font-size: 1.8rem; font-weight: 400;
    color: var(--color-gold);
}

.stat-label {
    font-size: 0.7rem; font-weight: 400;
    letter-spacing: 0.12em; text-transform: uppercase;
    color: var(--color-text-muted);
}

.stat-divider { width: 1px; height: 40px; background: rgba(255,255,255,0.15); }

.scroll-indicator {
    position: absolute; bottom: 40px; right: 60px;
    display: flex; flex-direction: column; align-items: center; gap: 8px;
}

.scroll-text {
    font-size: 0.65rem; letter-spacing: 0.2em;
    text-transform: uppercase; color: var(--color-text-muted);
    writing-mode: vertical-lr;
}

.scroll-line {
    width: 1px; height: 50px;
    background: linear-gradient(to bottom, var(--color-gold), transparent);
    animation: scrollPulse 2s infinite;
}

/* Hero entrance animations */
[data-animate-hero] {
    opacity: 0;
    transform: translateY(40px);
    animation: heroFadeIn 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

[data-animate-hero]:nth-child(1) { animation-delay: 0.6s; }
[data-animate-hero]:nth-child(2) { animation-delay: 0.8s; }
[data-animate-hero]:nth-child(3) { animation-delay: 1.0s; }
[data-animate-hero]:nth-child(4) { animation-delay: 1.2s; }

.hero-label {
    opacity: 0; transform: translateY(20px);
    animation: heroFadeIn 0.8s 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes heroFadeIn {
    to { opacity: 1; transform: translateY(0); }
}

/* ===========================
   MARQUEE TICKER
   =========================== */

.marquee-band {
    padding: 36px 0;
    background: var(--color-bg-alt);
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
    overflow: hidden;
    white-space: nowrap;
}

.marquee-track {
    display: flex;
    width: max-content;
    gap: 0;
    align-items: center;
    /* Hardware acceleration to eliminate sub-pixel flicker at the wrap-around point */
    will-change: transform;
    backface-visibility: hidden;
    transform: translate3d(0, 0, 0);
    /* Animation starts only when JS adds .marquee-ready (after all images loaded) */
}

.marquee-track.marquee-ready {
    /* 4 sets total, animation moves -25% per loop = exactly one set's distance.
       Duration scaled so per-logo speed feels the same as the old 32s/2-set version. */
    animation: marquee 24s linear infinite;
}

.marquee-logo img {
    /* Force a separate compositor layer per logo so sub-pixel re-rasterization
       at the loop seam doesn't cause cross-image flicker */
    transform: translate3d(0, 0, 0);
    backface-visibility: hidden;
}

.marquee-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 40px;
    flex-shrink: 0;
    /* Fixed-size slot — every logo occupies an identical 196x56 box */
    width: 196px;
    height: 56px;
    box-sizing: content-box;
}

.marquee-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    opacity: 0.85;
    transition: opacity 0.3s ease;
    /* Invert dark logos to white for the dark marquee band */
    filter: invert(1) hue-rotate(180deg);
}

.marquee-logo:hover img {
    opacity: 1;
}

.marquee-logo:hover img {
    opacity: 1;
}

@keyframes marquee {
    0% { transform: translate3d(0, 0, 0); }
    100% { transform: translate3d(-25%, 0, 0); }
}

/* ===========================
   TEXT UTILITIES
   =========================== */

.text-gold { color: var(--color-gold); }
.italic { font-style: italic; }

.text-link {
    display: inline-block;
    margin-top: 24px;
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    color: var(--color-gold);
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s ease;
}
.text-link:hover { border-bottom-color: var(--color-gold); }

/* ===========================
   SECTIONS — SHARED
   =========================== */

.section {
    padding: var(--section-padding) 0;
    position: relative;
}

.section-grid {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 60px;
    margin-bottom: 80px;
}

.section-label-col { display: flex; flex-direction: column; gap: 8px; }

.section-label {
    font-size: 0.72rem; font-weight: 500;
    letter-spacing: 0.2em; text-transform: uppercase;
    color: var(--color-gold);
}

.section-number {
    font-family: var(--font-display); font-size: 0.9rem;
    color: var(--color-text-muted); opacity: 0.4;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3.2rem);
    font-weight: 300;
    line-height: 1.25;
    color: var(--color-white);
    margin-bottom: 32px;
}

.section-intro {
    font-size: 1.05rem;
    color: var(--color-text-muted);
    max-width: 520px;
}

.section-body { max-width: 600px; }
.section-body p {
    color: var(--color-text-muted);
    margin-bottom: 20px;
    font-size: 1rem; line-height: 1.85;
}

/* ===========================
   ABOUT
   =========================== */

.section-about {
    border-bottom: 1px solid var(--color-border);
    /* Tighter bottom padding since the "Learn about our approach" link was removed —
       no need for trailing whitespace before the next section */
    padding-bottom: calc(var(--section-padding) * 0.55);
}

.section-about .section-grid { margin-bottom: 0; }

/* ===========================
   METRICS BAND
   =========================== */

.metrics-band {
    padding: 80px 0;
    background: var(--color-bg-alt);
    border-bottom: 1px solid var(--color-border);
}

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px; text-align: center;
}

.metric { display: flex; flex-direction: column; gap: 8px; }

.metric-value {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 4vw, 3.5rem);
    font-weight: 300;
    color: var(--color-gold);
}

.metric-description {
    font-size: 0.75rem; font-weight: 400;
    letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--color-text-muted);
}

/* ===========================
   PARALLAX DIVIDER
   =========================== */

.parallax-divider {
    position: relative;
    height: 60vh;
    min-height: 400px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.parallax-img {
    position: absolute; inset: -20% 0;
    width: 100%; height: 140%;
    object-fit: cover;
    object-position: center;
    will-change: transform;
}

.parallax-overlay {
    position: absolute; inset: 0;
    background: rgba(10, 10, 10, 0.65);
}

.parallax-content {
    position: relative; z-index: 2;
    max-width: 700px;
    text-align: center;
    padding: 0 40px;
}

.parallax-quote { border: none; }

.quote-text {
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 3vw, 2.2rem);
    font-weight: 300;
    font-style: italic;
    color: var(--color-white);
    line-height: 1.5;
    display: block;
    margin-bottom: 24px;
}

.parallax-quote cite {
    font-family: var(--font-sans);
    font-size: 0.78rem;
    font-style: normal;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--color-gold);
}

/* ===========================
   APPROACH
   =========================== */

.section-approach { border-bottom: 1px solid var(--color-border); }

.approach-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2px;
    background: var(--color-border);
}

.approach-card {
    background: var(--color-bg);
    padding: 48px;
    transition: background 0.4s ease;
    position: relative;
}

.approach-card:hover { background: var(--color-surface); }

.card-icon {
    color: var(--color-gold);
    margin-bottom: 20px;
    opacity: 0.6;
}

.card-number {
    font-family: var(--font-display); font-size: 0.85rem;
    color: var(--color-gold); margin-bottom: 16px; opacity: 0.4;
}

.approach-card h3 {
    font-family: var(--font-display);
    font-size: 1.6rem; font-weight: 400;
    color: var(--color-white); margin-bottom: 16px;
}

.approach-card p {
    font-size: 0.92rem; color: var(--color-text-muted); line-height: 1.75;
}

/* Hover line reveal */
.approach-card::after {
    content: ''; position: absolute;
    top: 0; left: 0; width: 0; height: 2px;
    background: var(--color-gold);
    transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.approach-card:hover::after { width: 100%; }

/* ===========================
   PORTFOLIO
   =========================== */

.section-portfolio {
    background: var(--color-bg-alt);
    border-bottom: 1px solid var(--color-border);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2px;
    background: var(--color-border);
    margin-bottom: 60px;
}

.portfolio-card {
    background: var(--color-bg-alt);
    padding: 48px 36px;
    text-align: center;
    transition: all 0.4s ease;
}

.portfolio-card:hover {
    background: var(--color-surface);
    transform: translateY(-2px);
}

.portfolio-logo {
    width: 80px; height: 80px; border-radius: 50%;
    background: var(--color-surface); border: 1px solid var(--color-border);
    margin: 0 auto 20px;
    display: flex; align-items: center; justify-content: center;
    font-size: 0.7rem; color: var(--color-text-muted);
    transition: border-color 0.3s ease;
}

.portfolio-card:hover .portfolio-logo { border-color: var(--color-gold); }

.portfolio-card h4 {
    font-family: var(--font-display);
    font-size: 1.2rem; font-weight: 400;
    color: var(--color-white); margin-bottom: 8px;
}

.portfolio-tag {
    font-size: 0.7rem; letter-spacing: 0.12em;
    text-transform: uppercase; color: var(--color-gold); opacity: 0.7;
}

.portfolio-cta { text-align: center; }

.btn-outline {
    display: inline-block;
    padding: 14px 40px;
    border: 1px solid var(--color-gold);
    color: var(--color-gold);
    font-size: 0.78rem; font-weight: 500;
    letter-spacing: 0.14em; text-transform: uppercase;
    transition: all 0.3s ease;
}

.btn-outline:hover { background: var(--color-gold); color: var(--color-bg); }

/* ===========================
   TEAM
   =========================== */

.section-team { border-bottom: 1px solid var(--color-border); }

.team-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 36px;
}

.team-card { text-align: center; }

/* Old dark-section .team-photo rule removed — team section is now always light */

.team-card:hover .team-photo { border-color: rgba(201, 168, 76, 0.3); }

/* no ::after on team-photo */

.team-card h4 {
    font-family: var(--font-display);
    font-size: 1.2rem; font-weight: 400;
    color: var(--color-white); margin-bottom: 4px;
}

.team-role {
    font-size: 0.75rem; letter-spacing: 0.1em;
    text-transform: uppercase; color: var(--color-gold);
    display: block; margin-bottom: 12px;
}

.team-bio { font-size: 0.88rem; color: var(--color-text-muted); line-height: 1.7; }

/* ===========================
   INSIGHTS
   =========================== */

.section-insights {
    background: var(--color-bg-alt);
    border-bottom: 1px solid var(--color-border);
}

.insights-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.insight-card {
    display: block; background: var(--color-bg);
    border: 1px solid var(--color-border);
    transition: all 0.4s ease; overflow: hidden;
}

.insight-card:hover {
    border-color: rgba(201, 168, 76, 0.3);
    transform: translateY(-4px);
}

.insight-image {
    width: 100%; height: 200px;
    background: var(--color-surface);
    position: relative;
    overflow: hidden;
}

.insight-image::after {
    content: 'Image'; position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    font-size: 0.75rem; color: var(--color-text-muted);
    letter-spacing: 0.1em; text-transform: uppercase;
}

.insight-content { padding: 28px; }

.insight-date {
    font-size: 0.7rem; letter-spacing: 0.12em;
    text-transform: uppercase; color: var(--color-text-muted);
    display: block; margin-bottom: 12px;
}

.insight-card h4 {
    font-family: var(--font-display);
    font-size: 1.2rem; font-weight: 400;
    color: var(--color-white); margin-bottom: 12px; line-height: 1.4;
}

.insight-card p {
    font-size: 0.9rem; color: var(--color-text-muted);
    line-height: 1.7; margin-bottom: 16px;
}

.insight-link {
    font-size: 0.75rem; letter-spacing: 0.1em;
    text-transform: uppercase; color: var(--color-gold);
    transition: opacity 0.3s ease;
}
.insight-card:hover .insight-link { opacity: 0.8; }

/* ===========================
   PORTFOLIO LOGO GRID
   =========================== */

.portfolio-logo-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: 60px;
}

.portfolio-logo-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
    background: var(--color-bg-alt);
    transition: background 0.4s ease, transform 0.4s ease, border-color 0.4s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border-radius: 4px;
    border: 1px solid var(--color-border);
    text-decoration: none;
    color: inherit;
}

.portfolio-logo-item:hover {
    background: var(--color-surface);
    transform: translateY(-4px);
    border-color: rgba(201, 168, 76, 0.35);
}

.portfolio-logo-wrap {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px;
}

.portfolio-logo-img {
    /* Fixed display envelope — every logo renders at the same size since all
       source PNGs are now padded to 3.5:1 aspect ratio (840x240) */
    width: 80%;
    max-width: 220px;
    height: auto;
    aspect-ratio: 3.5 / 1;
    object-fit: contain;
    transition: transform 0.4s ease, opacity 0.4s ease;
    opacity: 0.85;
    /* Invert dark logos for visibility on dark cards */
    filter: invert(1) hue-rotate(180deg);
}

.portfolio-logo-item:hover .portfolio-logo-img {
    opacity: 1;
}

.portfolio-logo-item:hover .portfolio-logo-img {
    transform: scale(1.05);
    opacity: 1;
}

.portfolio-logo-name {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    text-align: center;
    font-family: var(--font-sans);
    font-size: 0.6rem;
    font-weight: 500;
    color: var(--color-gold);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    padding: 9px 0;
    background: rgba(0,0,0,0.5);
    transform: translateY(100%);
    transition: transform 0.4s ease;
    border-top: 1px solid rgba(201, 168, 76, 0.15);
}

.portfolio-logo-item:hover .portfolio-logo-name {
    transform: translateY(0);
}

/* ===========================
   CONNECT (LinkedIn)
   =========================== */

.section-connect {
    padding: var(--section-padding) 0;
    text-align: center;
}

.connect-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 32px;
}

.connect-inner .section-label {
    display: block;
}

.connect-inner .section-title {
    margin: 0;
}

.linkedin-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 16px 40px;
    border: 1px solid var(--color-gold);
    color: var(--color-gold);
    font-family: var(--font-sans);
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    transition: background 0.3s ease, color 0.3s ease;
    text-decoration: none;
}

.linkedin-cta-btn:hover {
    background: var(--color-gold);
    color: var(--color-bg);
}

/* ===========================
   FOOTER
   =========================== */

.footer {
    padding: 80px 0 40px;
    border-top: 1px solid var(--color-border);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 60px; margin-bottom: 60px;
}

.footer-tagline { margin-top: 16px; font-size: 0.9rem; color: var(--color-text-muted); max-width: 280px; }

.footer-links-group h5 {
    font-size: 0.7rem; font-weight: 500;
    letter-spacing: 0.15em; text-transform: uppercase;
    color: var(--color-text-muted); margin-bottom: 20px;
}

.footer-links-group a {
    display: block; font-size: 0.9rem;
    color: var(--color-text-muted); margin-bottom: 10px;
    transition: color 0.3s ease;
}
.footer-links-group a:hover { color: var(--color-white); }

.footer-bottom { padding-top: 32px; border-top: 1px solid var(--color-border); }
.footer-bottom p { font-size: 0.78rem; color: var(--color-text-muted); opacity: 0.6; }
.footer-disclaimer { margin-top: 12px; font-size: 0.72rem !important; line-height: 1.6; }

/* ===========================
   ANIMATIONS
   =========================== */

@keyframes scrollPulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 1; }
}

/* ============================================
   SCROLL ANIMATIONS — RESILIENT VERSION
   Default state: VISIBLE (so content always shows
   even if JS fails). Only animate-from-hidden
   when body has .js-anim class added by JavaScript.
   ============================================ */

[data-animate] {
    transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Hidden initial state ONLY applies when JS confirms anim is enabled */
.js-anim [data-animate="fade-up"]:not(.visible) {
    opacity: 0;
    transform: translateY(50px);
}
.js-anim [data-animate="fade-left"]:not(.visible) {
    opacity: 0;
    transform: translateX(60px);
}
.js-anim [data-animate="fade-right"]:not(.visible) {
    opacity: 0;
    transform: translateX(-60px);
}
.js-anim [data-animate="scale"]:not(.visible) {
    opacity: 0;
    transform: scale(0.85);
}
.js-anim [data-animate="clip-up"]:not(.visible) {
    opacity: 0;
    transform: translateY(50px);
}

/* Visible state explicitly resets transforms */
[data-animate].visible {
    opacity: 1;
    transform: none;
}

/* Reduced motion: skip all animations */
@media (prefers-reduced-motion: reduce) {
    [data-animate],
    [data-animate-hero] {
        opacity: 1 !important;
        transform: none !important;
    }
}

/* --- Parallax quote text animation --- */
.parallax-content {
    opacity: 0;
    transform: translateY(30px) scale(0.97);
    transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1),
                transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.parallax-content.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* --- Gold line draw animation for section labels --- */
.section-label {
    position: relative;
    padding-bottom: 12px;
}
.section-label::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0;
    width: 0; height: 1px;
    background: var(--color-gold);
    transition: width 0.8s 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
.visible .section-label::after,
[data-animate].visible .section-label::after {
    width: 40px;
}

/* ===========================
   LIGHT SECTIONS (White screens)
   =========================== */

.section-light {
    background: #ffffff;
    color: #0a0a0a;
}

.section-light .section-label {
    color: var(--color-gold);
}

.section-light .section-number {
    color: rgba(0,0,0,0.15);
}

.section-light .section-title {
    color: #0a0a0a;
}

.section-light .section-intro,
.section-light .section-body p {
    color: #555;
}

.section-light .text-gold { color: var(--color-gold); }

.dark-link {
    color: #0a0a0a;
    border-bottom-color: rgba(0,0,0,0.2);
}
.dark-link:hover { border-bottom-color: var(--color-gold); color: var(--color-gold); }

/* Light approach cards */
.light-cards {
    background: #f2f1ee;
}

.light-cards .approach-card {
    background: #ffffff;
}

.light-cards .approach-card:hover {
    background: #f8f7f5;
}

.light-cards .approach-card h3 {
    color: #0a0a0a;
}

.light-cards .approach-card p {
    color: #555;
}

/* ===========================
   PORTFOLIO TABLE
   =========================== */

.portfolio-table {
    width: 100%;
    margin-top: 0;
}

.portfolio-table-header {
    display: grid;
    grid-template-columns: 2fr 1.5fr 1fr 0.8fr 1fr;
    gap: 20px;
    padding: 14px 0;
    border-bottom: 1px solid var(--color-border);
    margin-bottom: 4px;
}

.portfolio-table-header span {
    font-size: 0.68rem;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--color-text-muted);
    opacity: 0.6;
}

.portfolio-row {
    display: grid;
    grid-template-columns: 2fr 1.5fr 1fr 0.8fr 1fr;
    gap: 20px;
    align-items: center;
    padding: 22px 0;
    border-bottom: 1px solid var(--color-border);
    transition: background 0.3s ease;
    cursor: default;
}

.portfolio-row:hover {
    background: rgba(255,255,255,0.03);
    padding-left: 12px;
    padding-right: 12px;
    margin-left: -12px;
    margin-right: -12px;
}

.portfolio-company {
    display: flex;
    align-items: center;
    gap: 16px;
}

.company-name {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 400;
    color: var(--color-white);
}

.portfolio-sector {
    font-size: 0.82rem;
    color: var(--color-text-muted);
}

.portfolio-status {
    display: inline-block;
    font-size: 0.65rem;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding: 4px 10px;
    border-radius: 2px;
}

.portfolio-status.active {
    background: rgba(201, 168, 76, 0.1);
    color: var(--color-gold);
    border: 1px solid rgba(201, 168, 76, 0.3);
}

.portfolio-status.exited {
    background: rgba(255,255,255,0.05);
    color: var(--color-text-muted);
    border: 1px solid rgba(255,255,255,0.1);
}

.portfolio-moic {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 400;
    color: var(--color-white);
}

.portfolio-irr {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 400;
}

/* ===========================
   TEAM (LIGHT) — Vertical centered cards
   =========================== */

.section-light .team-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    margin-top: 60px;
}

.section-light .team-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0;
}

.section-light .team-card .team-photo {
    width: 200px !important;
    height: 200px !important;
    min-width: 200px !important;
    border-radius: 50%;
    overflow: hidden;
    background-color: #e8e7e4;
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center top;
    border: 3px solid rgba(201, 168, 76, 0.25);
    aspect-ratio: unset !important;
    flex-shrink: 0;
    margin-bottom: 24px;
    transition: border-color 0.3s ease, transform 0.4s ease;
    position: relative;
}

.section-light .team-card:hover .team-photo {
    border-color: rgba(201, 168, 76, 0.6);
    transform: scale(1.03);
}

/* Hidden img tag fallback (kept for backward compat - no longer rendered) */
.team-photo-img { display: none; }

.team-initials {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 400;
    color: var(--color-gold);
    letter-spacing: 0.05em;
}

.team-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.section-light .team-card h4 {
    font-family: var(--font-display);
    font-size: 1.35rem;
    font-weight: 500;
    color: #0a0a0a;
    margin-bottom: 6px;
}

.section-light .team-role {
    color: var(--color-gold);
    font-size: 0.72rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    display: block;
    margin-bottom: 14px;
}

.section-light .team-bio {
    color: #666;
    font-size: 0.86rem;
    line-height: 1.75;
    margin-bottom: 18px;
}

.team-linkedin {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-size: 0.72rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #0a0a0a;
    border: 1px solid rgba(0,0,0,0.15);
    padding: 8px 16px;
    transition: border-color 0.3s ease, color 0.3s ease, background 0.3s ease;
    text-decoration: none;
    margin-top: auto;
}

.team-linkedin:hover {
    border-color: var(--color-gold);
    color: var(--color-gold);
    background: rgba(201,168,76,0.05);
}

/* ===========================
   MARKET SECTION (DARK)
   =========================== */

.section-market {
    background: var(--color-bg-alt);
    border-bottom: 1px solid var(--color-border);
}

.market-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2px;
    background: var(--color-border);
}

.market-card {
    background: var(--color-bg-alt);
    padding: 48px 40px;
    position: relative;
    transition: background 0.3s ease;
}

.market-card:hover { background: var(--color-surface); }

.market-stat {
    font-family: var(--font-display);
    font-size: 3rem;
    font-weight: 300;
    color: var(--color-gold);
    margin-bottom: 16px;
    line-height: 1;
}

.market-card h3 {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 400;
    color: var(--color-white);
    margin-bottom: 16px;
}

.market-card p {
    font-size: 0.9rem;
    color: var(--color-text-muted);
    line-height: 1.8;
    margin-bottom: 20px;
}

.market-source {
    font-size: 0.65rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--color-text-muted);
    opacity: 0.5;
}

/* ===========================
   SOURCING SECTION (LIGHT)
   =========================== */

.section-sourcing {
    border-bottom: 1px solid #e0deda;
}

.sourcing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2px;
    background: #e8e7e4;
}

.sourcing-card {
    background: #ffffff;
    padding: 48px 40px;
    position: relative;
    transition: background 0.3s ease;
}

.sourcing-card:hover { background: #f8f7f5; }

.featured-sourcing {
    background: #0a0a0a !important;
    color: #ffffff;
}

.featured-sourcing:hover { background: #111 !important; }

.sourcing-badge {
    display: inline-block;
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: #0a0a0a;
    background: var(--color-gold);
    padding: 4px 10px;
    margin-bottom: 20px;
}

.sourcing-number {
    font-family: var(--font-display);
    font-size: 0.85rem;
    color: var(--color-gold);
    margin-bottom: 16px;
    opacity: 0.6;
    letter-spacing: 0.1em;
}

.sourcing-card h3 {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 400;
    color: #0a0a0a;
    margin-bottom: 16px;
}

.featured-sourcing h3 {
    color: #ffffff;
}

.sourcing-card p {
    font-size: 0.9rem;
    color: #555;
    line-height: 1.8;
}

.featured-sourcing p {
    color: rgba(255,255,255,0.65);
}

/* ===========================
   RESPONSIVE
   =========================== */

@media (max-width: 1024px) {
    :root { --section-padding: 100px; }
    .container, .nav-container, .hero-content { padding: 0 40px; }
    .section-grid { grid-template-columns: 1fr; gap: 24px; }
    .section-light .team-grid { grid-template-columns: repeat(2, 1fr); gap: 32px; }
    .portfolio-logo-grid { grid-template-columns: repeat(3, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 40px; }
    .market-grid { grid-template-columns: 1fr; }
    .sourcing-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    :root { --section-padding: 80px; }
    .container, .nav-container, .hero-content { padding: 0 24px; }
    .nav-links { display: none; }
    .menu-toggle { display: flex; flex-direction: column; justify-content: center; }
    .hero {
        min-height: 88vh;
        align-items: center;
        padding-bottom: 0;
        padding-top: 80px;
    }
    .hero-title { font-size: 2.8rem; }
    .hero-stats { flex-direction: column; align-items: flex-start; gap: 24px; }
    .stat-divider { width: 40px; height: 1px; }
    .metrics-grid { grid-template-columns: repeat(2, 1fr); gap: 32px; }
    .approach-cards { grid-template-columns: 1fr; }
    .insights-grid { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; gap: 32px; }
    .scroll-indicator { display: none; }
    .parallax-divider { height: 50vh; }
    .portfolio-logo-grid { grid-template-columns: repeat(2, 1fr); }
    .section-light .team-grid { grid-template-columns: repeat(2, 1fr); gap: 28px; }
    .section-light .team-card .team-photo { width: 150px !important; height: 150px !important; min-width: 150px !important; }
}

@media (max-width: 480px) {
    .hero {
        min-height: 78vh;
        padding-bottom: 0;
        padding-top: 90px;
    }
    .hero-title { font-size: 2.2rem; }
    .section-light .team-grid { grid-template-columns: 1fr; gap: 48px; }
    .section-light .team-card { padding: 0; }
    .section-light .team-card .team-photo {
        width: 160px !important;
        height: 160px !important;
        min-width: 160px !important;
    }
    .portfolio-logo-grid { grid-template-columns: 1fr; }
}
