/* ==========================================================================
   ARCHIE DURRANT - STRATEGIC COMMUNICATION DESIGNER PORTFOLIO
   Design System & Styles - Enhanced Edition
   ========================================================================== */

/* --------------------------------------------------------------------------
   CSS CUSTOM PROPERTIES (Design Tokens)
   -------------------------------------------------------------------------- */
:root {
    /* Colors */
    --color-primary: #83b49d;
    --color-secondary: #a8d5c2;
    --color-cta: #06B6D4;
    --color-background: #FAFAFA;
    --color-surface: #FFFFFF;
    --color-text: #0A0A0A;
    --color-muted: #71717A;
    --color-border: #E4E4E7;
    --color-dark: #18181B;

    /* Typography */
    --font-heading: 'Archivo', sans-serif;
    --font-body: 'Space Grotesk', sans-serif;

    /* Spacing - Premium Breathing Room */
    --space-xs: 0.25rem;
    --space-sm: 0.5rem;
    --space-md: 1rem;
    --space-lg: 1.5rem;
    --space-xl: 2.5rem;
    --space-2xl: 4rem;
    --space-3xl: 6rem;
    --space-4xl: 8rem;
    --space-5xl: 12rem;
    --space-6xl: 16rem;
    --space-7xl: 20rem;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 12px 24px rgba(0, 0, 0, 0.08);
    --shadow-xl: 0 24px 48px rgba(0, 0, 0, 0.12);
    --shadow-glow: 0 0 60px rgba(131, 180, 157, 0.15);

    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-2xl: 32px;

    /* Transitions */
    --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
    --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
    --ease-out-expo: cubic-bezier(0.19, 1, 0.22, 1);
    --transition-fast: 150ms var(--ease-smooth);
    --transition-base: 300ms var(--ease-smooth);
    --transition-slow: 500ms var(--ease-out-expo);
    --transition-slower: 800ms var(--ease-out-expo);

    /* Layout */
    --max-width: 1400px;
    --header-height: 80px;
}

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

html {
    font-size: 16px;
    /* Premium smooth scrolling for deliberate user experience */
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
    /* Account for fixed header */
}

/* Lenis Smooth Scroll Styles */
html.lenis,
html.lenis body {
    height: auto;
}

.lenis.lenis-smooth {
    scroll-behavior: auto !important;
}

.lenis.lenis-smooth [data-lenis-prevent] {
    overscroll-behavior: contain;
}

.lenis.lenis-stopped {
    overflow: hidden;
}

/* Enhanced smooth scrolling for premium feel */
html {
    scroll-timeline: --scroll-y block;
}

/* Smooth transitions for all interactive elements */
a[href^="#"] {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Smooth page transitions */
.page-transition {
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Enhanced scroll indicators */
.hero-scroll {
    animation: scrollHint 3s ease-in-out infinite;
}

@keyframes scrollHint {

    0%,
    100% {
        opacity: 0.3;
        transform: translateY(0);
    }

    50% {
        opacity: 0.8;
        transform: translateY(10px);
    }
}

/* Premium smooth scrolling enhancement */
@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
        scroll-padding-top: 80px;
    }

    /* Smooth transitions for all anchor links */
    a[href^="#"] {
        scroll-behavior: smooth;
        transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    }

    /* Enhanced scroll feel */
    * {
        scroll-behavior: smooth !important;
    }
}

/* Subtle parallax for depth during scroll */
/* Body style cleaner - removed perspective to fix custom cursor context */
body {
    overflow-x: hidden;
}

/* Scroll-based animations */
.reveal {
    transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Smooth scroll bars for webkit browsers */
::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: var(--color-background);
}

::-webkit-scrollbar-thumb {
    background: var(--color-primary);
    border-radius: 6px;
    transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-secondary);
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

body {
    font-family: var(--font-body);
    font-size: 1.125rem;
    line-height: 1.7;
    color: var(--color-text);
    background-color: var(--color-background);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
    cursor: none;
}

/* Custom Cursor - Elegant Dual Circle */
.cursor-dot {
    position: fixed;
    top: 0;
    left: 0;
    width: 20px;
    height: 20px;
    background: white;
    border-radius: 50%;
    pointer-events: none;
    z-index: 10001;
    transform: translate(-50%, -50%);
    /* transform handled by JS for performance */
    transition: opacity 0.2s ease;
    will-change: transform;
    mix-blend-mode: difference;
    filter: grayscale(1) contrast(100);
}

/* Projects Grid - Dense Layout */
.projects-grid-dense {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-lg);
    margin-bottom: var(--space-4xl);
}

@media (min-width: 640px) {
    .projects-grid-dense {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-xl);
    }
}

@media (min-width: 1024px) {
    .projects-grid-dense {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--space-xl);
    }
}

@media (min-width: 1400px) {
    .projects-grid-dense {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--space-2xl);
    }
}

/* Vertical Project Card (Grid Layout) */
.project-card-vertical {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
    position: relative;
    text-decoration: none;
    cursor: pointer;
}

.project-card-vertical .project-image-wrapper {
    position: relative;
    aspect-ratio: 4/3;
    width: 100%;
    margin-bottom: var(--space-xs);
    overflow: hidden;
    border-radius: var(--radius-xl);
    background: var(--color-background);
}

/* Re-implement hover effects for new class */
.project-card-vertical .project-image-wrapper::before {
    content: '';
    position: absolute;
    inset: 0;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    z-index: 2;
    pointer-events: none;
    transition: border-color var(--transition-base);
}

.project-card-vertical:hover .project-image-wrapper::before {
    border-color: var(--color-primary);
}

.project-card-vertical .project-image-wrapper::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(131, 180, 157, 0.1) 0%, rgba(6, 182, 212, 0.1) 100%);
    opacity: 0;
    transition: opacity var(--transition-base);
    z-index: 1;
}

.project-card-vertical:hover .project-image-wrapper::after {
    opacity: 1;
}

.project-card-vertical .project-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slower);
    /* Prevent layout shift during loading */
    background: var(--color-surface);
}

.project-card-vertical:hover .project-image {
    transform: scale(1.05);
}

.project-card-vertical .project-content {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
    padding: 0;
}

.project-card-vertical .project-title {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--color-text);
    line-height: 1.1;
    margin: 0;
    transition: color var(--transition-fast);
}

.project-card-vertical:hover .project-title {
    color: var(--color-primary);
}

.project-card-vertical .project-meta {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: 0.875rem;
    margin: 0;
}

.project-card-vertical .project-link {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--color-text);
    transition: all var(--transition-fast);
    margin: 0;
}

.project-card-vertical .project-link::after {
    content: '';
    display: block;
    width: 24px;
    height: 1px;
    background: var(--color-text);
    transition: all var(--transition-base);
}

.project-card-vertical:hover .project-link {
    color: var(--color-primary);
}

.project-card-vertical:hover .project-link::after {
    width: 40px;
    background: var(--color-primary);
}

/* Arrow indicator for vertical card */
.project-card-vertical .project-arrow {
    position: absolute;
    bottom: var(--space-md);
    right: var(--space-md);
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 50%;
    transform: scale(0.8);
    opacity: 0;
    transition: all var(--transition-base);
    z-index: 3;
    box-shadow: var(--shadow-lg);
}

.project-card-vertical:hover .project-arrow {
    transform: scale(1);
    opacity: 1;
}

.project-card-vertical .project-arrow svg {
    width: 20px;
    height: 20px;
    stroke: var(--color-text);
    stroke-width: 2;
    transition: all var(--transition-fast);
}

.project-card-vertical:hover .project-arrow svg {
    stroke: var(--color-primary);
}

.cursor-ring {
    position: fixed;
    top: 0;
    left: 0;
    width: 20px;
    height: 20px;
    border: 0px solid white;
    border-radius: 50%;
    pointer-events: none;
    z-index: 10000;
    transform: translate(-50%, -50%);
    transition: width 0.3s var(--ease-out-expo),
        height 0.3s var(--ease-out-expo),
        border-color 0.3s ease,
        background 0.3s ease,
        opacity 0.2s ease;
    mix-blend-mode: difference;
    filter: grayscale(1) contrast(100);
    opacity: 0;
}

/* Cursor states */
.cursor-dot.hidden,
.cursor-ring.hidden {
    opacity: 0;
}

/* Hover state - ring hidden to keep solid cursor feel */
.cursor-ring.hover {
    width: 60px;
    height: 60px;
    background: transparent;
    opacity: 0;
}

.cursor-dot.hover {
    transform: translate(-50%, -50%) scale(1.3);
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
} 

/* Click state */
.cursor-ring.clicking {
    width: 20px;
    height: 20px;
    border-width: 0px;
    opacity: 0;
}

.cursor-dot.clicking {
    transform: translate(-50%, -50%) scale(0.85);
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 3px 8px rgba(0,0,0,0.09) inset;
}

/* Cling state - larger and stronger shadow when attached to elements */
.cursor-dot.cling {
    transform: translate(-50%, -50%) scale(1.6);
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
}

.cursor-cling-target {
    transition: box-shadow 220ms ease, transform 220ms ease;
    box-shadow: 0 10px 28px rgba(6, 182, 212, 0.06);
    transform: translateZ(0);
}

/* Text hover - becomes line */
.cursor-ring.text {
    width: 4px;
    height: 24px;
    border-radius: 2px;
    background: white;
    border: none;
}

.cursor-dot.text {
    opacity: 0;
}

/* Force no cursor on interactive elements (override pointer) */
@media (hover: hover) and (pointer: fine) {
    a, button, .btn, .project-card, .contact-social, [role="button"], .nav-link, .project-card-vertical, input, textarea {
        cursor: none !important;
    }

    /* If keyboard navigation is used, show the system cursor for accessibility */
    body.show-system-cursor a,
    body.show-system-cursor button,
    body.show-system-cursor .btn,
    body.show-system-cursor [role="button"],
    body.show-system-cursor .nav-link {
        cursor: auto !important;
    }
}

/* Hide on touch devices */
@media (hover: none) and (pointer: coarse) {

    .cursor-dot,
    .cursor-ring {
        display: none !important;
    }

    body {
        cursor: auto;
    }
}

/* Hide cursor on interactive elements in normal mode */
a,
button,
input,
textarea,
select,
.project-card,
.contact-social,
.btn {
    cursor: none;
}

/* Page transition overlay */
.page-transition {
    position: fixed;
    inset: 0;
    background: var(--color-dark);
    z-index: 9999;
    transform: scaleY(0);
    transform-origin: bottom;
    pointer-events: none;
}

.page-transition.active {
    animation: pageTransition 0.8s var(--ease-out-expo) forwards;
}

@keyframes pageTransition {
    0% {
        transform: scaleY(0);
        transform-origin: bottom;
    }

    50% {
        transform: scaleY(1);
        transform-origin: bottom;
    }

    50.001% {
        transform-origin: top;
    }

    100% {
        transform: scaleY(0);
        transform-origin: top;
    }
}

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

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

button {
    font-family: inherit;
    font-size: inherit;
    border: none;
    background: none;
    cursor: pointer;
}

ul,
ol {
    list-style: none;
}

/* Focus styles */
:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 4px;
    border-radius: var(--radius-sm);
}

::selection {
    background: var(--color-primary);
    color: white;
}

/* --------------------------------------------------------------------------
   TYPOGRAPHY
   -------------------------------------------------------------------------- */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.03em;
}

.heading-display {
    font-size: clamp(4rem, 15vw, 12rem);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.04em;
    line-height: 0.85;
}

.heading-hero {
    font-size: clamp(3rem, 12vw, 9rem);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.03em;
    line-height: 0.9;
}

.heading-section {
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    font-weight: 800;
}

.heading-project {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
}

.heading-subsection {
    font-size: 1.5rem;
    font-weight: 600;
}

.text-body {
    font-size: 1.125rem;
    line-height: 1.8;
}

.text-large {
    font-size: clamp(1.25rem, 2.5vw, 1.75rem);
    line-height: 1.6;
}

.text-small {
    font-size: 0.875rem;
}

.text-caption {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-weight: 600;
}

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

.text-gradient {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-cta) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* --------------------------------------------------------------------------
   LAYOUT UTILITIES
   -------------------------------------------------------------------------- */
.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--space-lg);
}

.container-narrow {
    max-width: 1100px;
}

.container-wide {
    max-width: 1600px;
}

/* Project page specific widths */
.project-text-width {
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.project-full-width {
    max-width: 100%;
    margin-left: calc(-1 * var(--space-lg));
    margin-right: calc(-1 * var(--space-lg));
}

@media (min-width: 768px) {
    .project-full-width {
        margin-left: calc(-1 * var(--space-xl));
        margin-right: calc(-1 * var(--space-xl));
    }
}

@media (min-width: 1024px) {
    .project-full-width {
        margin-left: calc(-1 * var(--space-2xl));
        margin-right: calc(-1 * var(--space-2xl));
    }
}

@media (min-width: 1440px) {
    .project-full-width {
        margin-left: calc(50% - 50vw);
        margin-right: calc(50% - 50vw);
    }
}

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

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

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

/* Horizontal scroll container */
.horizontal-scroll {
    display: flex;
    gap: var(--space-lg);
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: var(--space-md);
    scrollbar-width: none;
}

.horizontal-scroll::-webkit-scrollbar {
    display: none;
}

.horizontal-scroll>* {
    scroll-snap-align: start;
    flex-shrink: 0;
}

/* --------------------------------------------------------------------------
   HEADER & NAVIGATION
   -------------------------------------------------------------------------- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: var(--space-lg) 0;
    transition: all var(--transition-slow);
}

.header.scrolled {
    padding: var(--space-md) 0;
    background: rgba(250, 250, 250, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: inline-flex;
    align-items: center;
    position: relative;
    height: 32px;
    transition: transform var(--transition-base);
}

.logo img {
    height: 100%;
    width: auto;
    display: block;
    opacity: 0.3;
}

/* Green logo for hover state */
.logo::after {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('../images/logo/PNG/TransparentBg-Green.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0;
    transition: opacity var(--transition-base);
    pointer-events: none;
}

.logo:hover {
    transform: scale(1.05);
}

.logo:hover img {
    opacity: 0;
}

.logo:hover::after {
    opacity: 0.65;
}

/* Decorative dot - only show if logo has text (fallback) */
.logo:not(:has(img))::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--color-primary);
    border-radius: 50%;
    margin-right: var(--space-sm);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.5;
        transform: scale(0.8);
    }
}

.nav {
    display: flex;
    align-items: center;
    gap: var(--space-xl);
}

.nav-link {
    position: relative;
    padding: var(--space-sm) 0;
    font-weight: 500;
    font-size: 0.9375rem;
    transition: color var(--transition-fast);
    cursor: pointer;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-cta));
    transition: width var(--transition-base);
}

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

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

.nav-cta {
    padding: var(--space-sm) var(--space-lg);
    background: var(--color-dark);
    color: white;
    border-radius: 100px;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all var(--transition-base);
}

.nav-cta:hover {
    background: var(--color-primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* --------------------------------------------------------------------------
   BURGER MENU (Mobile Navigation)
   -------------------------------------------------------------------------- */

/* Burger Menu Button */
.burger-menu {
    display: none;
    /* Hidden by default, shown on mobile via media query */
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 48px;
    height: 48px;
    padding: 0;
    background: transparent;
    border: none;
    cursor: none;
    position: relative;
    z-index: 200;
    transition: transform var(--transition-base);
}

.burger-menu:hover {
    transform: scale(1.05);
}

.burger-line {
    display: block;
    width: 28px;
    height: 2px;
    background: var(--color-text);
    border-radius: 2px;
    transition: all var(--transition-base);
    position: relative;
}

.burger-line:nth-child(1) {
    transform: translateY(-8px);
}

.burger-line:nth-child(3) {
    transform: translateY(8px);
}

/* Burger animation when menu is open */
.burger-menu.active .burger-line:nth-child(1) {
    transform: translateY(0) rotate(45deg);
}

.burger-menu.active .burger-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.burger-menu.active .burger-line:nth-child(3) {
    transform: translateY(0) rotate(-45deg);
}

/* Mobile Navigation Overlay */
.mobile-nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100vh;
    z-index: 1000;
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--transition-slow), visibility var(--transition-slow);
}

.mobile-nav-overlay.active {
    pointer-events: auto;
    opacity: 1;
    visibility: visible;
}

/* Backdrop with blur effect */
.mobile-nav-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    opacity: 0;
    transition: opacity var(--transition-slow);
}

.mobile-nav-overlay.active .mobile-nav-backdrop {
    opacity: 1;
}

/* Mobile navigation panel */
.mobile-nav {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(85vw, 400px);
    height: 100%;
    background: var(--color-surface);
    box-shadow: var(--shadow-xl);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: var(--space-xl);
    padding: var(--space-3xl) var(--space-xl);
    transform: translateX(100%);
    transition: transform var(--transition-slower);
}

.mobile-nav-overlay.active .mobile-nav {
    transform: translateX(0);
}

/* Mobile navigation links */
.mobile-nav-link {
    font-family: var(--font-heading);
    font-size: clamp(1.5rem, 5vw, 2.5rem);
    font-weight: 700;
    color: var(--color-text);
    text-decoration: none;
    position: relative;
    opacity: 0;
    transform: translateX(30px);
    transition: all var(--transition-base);
    cursor: none;
}

/* Staggered animation for links */
.mobile-nav-overlay.active .mobile-nav-link {
    opacity: 1;
    transform: translateX(0);
}

.mobile-nav-overlay.active .mobile-nav-link:nth-child(1) {
    transition-delay: 0.1s;
}

.mobile-nav-overlay.active .mobile-nav-link:nth-child(2) {
    transition-delay: 0.2s;
}

.mobile-nav-overlay.active .mobile-nav-link:nth-child(3) {
    transition-delay: 0.3s;
}

/* Underline hover effect */
.mobile-nav-link::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-cta));
    transition: width var(--transition-base);
}

.mobile-nav-link:hover {
    color: var(--color-primary);
}

.mobile-nav-link:hover::after {
    width: 100%;
}

/* Responsive: Show burger menu on mobile, hide desktop nav */
@media (max-width: 768px) {
    .burger-menu {
        display: flex;
    }

    .nav {
        display: none;
    }
}

/* Ensure desktop nav is visible and burger is hidden on larger screens */
@media (min-width: 769px) {
    .burger-menu {
        display: none !important;
    }

    .mobile-nav-overlay {
        display: none !important;
    }

    .nav {
        display: flex;
    }
}

/* Prevent body scroll when mobile menu is open */
body.mobile-menu-open {
    overflow: hidden;
}

/* --------------------------------------------------------------------------
   HERO SECTION
   -------------------------------------------------------------------------- */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    padding-top: var(--header-height);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -25%;
    width: 80vw;
    height: 80vw;
    background: radial-gradient(circle, rgba(131, 180, 157, 0.08) 0%, transparent 70%);
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -20%;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.06) 0%, transparent 70%);
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-eyebrow {
    display: block;
    margin-bottom: var(--space-xl);
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--color-muted);
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s var(--ease-out-expo) 0.2s forwards;
}

.hero-name {
    display: block;
    position: relative;
}

.hero-name-line {
    display: block;
    overflow: hidden;
    margin: 0;
    padding: 0;
}

.hero-name-line span {
    display: block;
    transform: translateY(110%);
    animation: slideUp 1.2s var(--ease-out-expo) forwards;
    margin: 0;
    padding: 0;
    will-change: transform;
}

.hero-name-line:nth-child(2) {
    margin-left: -0.06em;
}

.hero-name-line:nth-child(2) span {
    animation-delay: 0.1s;
}

.hero-role {
    margin-top: var(--space-2xl);
    font-size: clamp(1rem, 2vw, 1.25rem);
    font-weight: 500;
    color: var(--color-muted);
    max-width: 500px;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s var(--ease-out-expo) 0.6s forwards;
}

.hero-role strong {
    color: var(--color-text);
    font-weight: 600;
}

.hero-cta {
    margin-top: var(--space-2xl);
    display: flex;
    gap: var(--space-md);
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s var(--ease-out-expo) 0.8s forwards;
}

.hero-scroll {
    position: absolute;
    bottom: var(--space-2xl);
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-sm);
    opacity: 0;
    animation: fadeIn 1s var(--ease-out-expo) 1.2s forwards;
    cursor: pointer;
}

.hero-scroll-text {
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--color-muted);
}

.hero-scroll-line {
    width: 1px;
    height: 60px;
    position: relative;
    overflow: hidden;
}

.hero-scroll-line::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, var(--color-primary), transparent);
    animation: scrollLine 2s var(--ease-smooth) infinite;
}

@keyframes scrollLine {
    0% {
        transform: translateY(-100%);
    }

    100% {
        transform: translateY(100%);
    }
}

/* --------------------------------------------------------------------------
   BUTTONS
   -------------------------------------------------------------------------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
    padding: var(--space-md) var(--space-xl);
    font-weight: 600;
    font-size: 0.9375rem;
    border-radius: 100px;
    transition: all var(--transition-base);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), transparent);
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.btn:hover::before {
    opacity: 1;
}

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

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-xl);
}

.btn-secondary {
    background: transparent;
    color: var(--color-text);
    border: 2px solid var(--color-border);
}

.btn-secondary:hover {
    border-color: var(--color-dark);
    transform: translateY(-3px);
}

.btn-icon {
    width: 20px;
    height: 20px;
    transition: transform var(--transition-fast);
}



.btn:hover .btn-icon {
    transform: translateX(4px);
}

/* --------------------------------------------------------------------------
   ABOUT SECTION
   -------------------------------------------------------------------------- */
.about {
    background: var(--color-surface);
    overflow: hidden;
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-3xl);
    align-items: center;
}

@media (min-width: 1024px) {
    .about-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-4xl);
    }
}

.about-content {
    max-width: 600px;
}

.about-label {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    margin-bottom: var(--space-lg);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-primary);
}

.about-label::before {
    content: '';
    width: 24px;
    height: 2px;
    background: var(--color-primary);
}

.about-text {
    font-size: clamp(1.25rem, 2.5vw, 1.75rem);
    line-height: 1.6;
    font-weight: 400;
}

.about-text strong {
    font-weight: 600;
    color: var(--color-primary);
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-xl);
    margin-top: var(--space-3xl);
    padding-top: var(--space-2xl);
    border-top: 1px solid var(--color-border);
}

.about-stat {
    text-align: center;
}

.about-stat-number {
    display: block;
    font-family: var(--font-heading);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    color: var(--color-text);
    line-height: 1;
}

.about-stat-label {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-muted);
    margin-top: var(--space-sm);
    line-height: 1.4;
}

.about-visual {
    position: relative;
}

.about-image-wrapper {
    position: relative;
    border-radius: var(--radius-xl);
    overflow: hidden;
    aspect-ratio: 4/5;
}

.about-image-wrapper::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--color-primary), var(--color-cta));
    opacity: 0.1;
    z-index: 2;
}

.about-image {
    user-select: none;
    -webkit-user-drag: none;
    pointer-events: none;
}

.about-decoration {
    position: absolute;
    width: 200px;
    height: 200px;
    border: 2px solid var(--color-border);
    border-radius: var(--radius-xl);
    bottom: -30px;
    right: -30px;
    z-index: -1;
}

/* --------------------------------------------------------------------------
   PROJECTS SECTION - Refined Elegant Design
   -------------------------------------------------------------------------- */
.projects {
    background: var(--color-surface);
    position: relative;
}

.projects::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--color-border), transparent);
}

.projects-header {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    margin-bottom: var(--space-4xl);
    text-align: center;
}

.projects-header>div {
    margin: 0 auto;
}

.projects-label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-md);
    margin-bottom: var(--space-lg);
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--color-primary);
}

.projects-label::before,
.projects-label::after {
    content: '';
    width: 40px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--color-primary));
}

.projects-label::after {
    background: linear-gradient(90deg, var(--color-primary), transparent);
}

.projects-subtitle {
    font-size: 1.125rem;
    color: var(--color-muted);
    max-width: 500px;
    margin: var(--space-lg) auto 0;
    line-height: 1.6;
}

/* Refined Grid Layout */
.projects-grid {
    display: flex;
    flex-direction: column;
    gap: var(--space-1xl);
}

/* Project Card - Clean, Elegant Style */
.project-card {
    position: relative;
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-xl);
    align-items: center;
    text-decoration: none;
    cursor: pointer;
}

@media (min-width: 768px) {
    .project-card {
        grid-template-columns: 1.2fr 1fr;
        gap: var(--space-3xl);
    }

    .project-card:nth-child(even) {
        grid-template-columns: 1fr 1.2fr;
    }

    .project-card:nth-child(even) .project-image-wrapper {
        order: 2;
    }

    .project-card:nth-child(even) .project-content {
        order: 1;
        text-align: right;
    }

    .project-card:nth-child(even) .project-meta {
        justify-content: flex-end;
    }
}

.project-image-wrapper {
    position: relative;
    aspect-ratio: 4/3;
    overflow: hidden;
    border-radius: var(--radius-xl);
    background: var(--color-background);
}

.project-image-wrapper::before {
    content: '';
    position: absolute;
    inset: 0;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    z-index: 2;
    pointer-events: none;
    transition: border-color var(--transition-base);
}

.project-card:hover .project-image-wrapper::before {
    border-color: var(--color-primary);
}

.project-image-wrapper::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(131, 180, 157, 0.1) 0%, rgba(6, 182, 212, 0.1) 100%);
    opacity: 0;
    transition: opacity var(--transition-base);
    z-index: 1;
}

.project-card:hover .project-image-wrapper::after {
    opacity: 1;
}

.project-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slower);
}

.project-card:hover .project-image {
    transform: scale(1.05);
}

/* Project Number Badge */
.project-number {
    position: absolute;
    top: var(--space-lg);
    left: var(--space-lg);
    font-family: var(--font-heading);
    font-size: 0.6875rem;
    font-weight: 800;
    color: var(--color-text);
    background: var(--color-surface);
    padding: var(--space-xs) var(--space-md);
    border-radius: 100px;
    z-index: 3;
    box-shadow: var(--shadow-md);
    letter-spacing: 0.05em;
}

/* Hide old overlay styles */
.project-overlay {
    display: none;
}

/* Project Content */
.project-content {
    padding: var(--space-md) 0;
}

.project-meta {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    margin-bottom: var(--space-lg);
}

.project-category {
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-primary);
    padding: var(--space-xs) var(--space-sm);
    background: rgba(131, 180, 157, 0.08);
    border-radius: var(--radius-sm);
}

.project-year {
    font-size: 0.75rem;
    color: var(--color-muted);
    font-weight: 500;
}

.project-title {
    font-family: var(--font-heading);
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    font-weight: 800;
    color: var(--color-text);
    margin-bottom: var(--space-md);
    line-height: 1.1;
    letter-spacing: -0.02em;
    transition: color var(--transition-fast);
}

.project-card:hover .project-title {
    color: var(--color-primary);
}

.project-description {
    font-size: 1rem;
    color: var(--color-muted);
    line-height: 1.7;
    margin-bottom: var(--space-xl);
    max-width: 450px;
}

.project-card:nth-child(even) .project-description {
    margin-left: auto;
}

/* View Project Link */
.project-link {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--color-text);
    transition: all var(--transition-fast);
}

.project-link::after {
    content: '';
    display: block;
    width: 24px;
    height: 1px;
    background: var(--color-text);
    transition: all var(--transition-base);
}

.project-card:hover .project-link {
    color: var(--color-primary);
}

.project-card:hover .project-link::after {
    width: 40px;
    background: var(--color-primary);
}

/* Arrow indicator */
.project-arrow {
    position: absolute;
    bottom: var(--space-lg);
    right: var(--space-lg);
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 50%;
    transform: scale(0.8);
    opacity: 0;
    transition: all var(--transition-base);
    z-index: 3;
    box-shadow: var(--shadow-lg);
}

.project-card:hover .project-arrow {
    transform: scale(1);
    opacity: 1;
}

.project-arrow svg {
    width: 20px;
    height: 20px;
    stroke: var(--color-text);
    stroke-width: 2;
    transition: all var(--transition-fast);
}

.project-card:hover .project-arrow svg {
    stroke: var(--color-primary);
    transform: translate(2px, -2px);
}

/* Divider between projects */
.project-card:not(:last-child)::after {
    content: '';
    position: absolute;
    bottom: calc(var(--space-3xl) * -0.5);
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--color-border), transparent);
}

/* Remove old info styles */
.project-info {
    display: none;
}

/* Mobile adjustments */
@media (max-width: 767px) {
    .projects-grid {
        gap: var(--space-4xl);
    }

    .project-content {
        text-align: center;
    }

    .project-meta {
        justify-content: center;
    }

    .project-description {
        margin: 0 auto var(--space-xl);
    }

    .project-link {
        justify-content: center;
    }

    .project-arrow {
        bottom: var(--space-md);
        right: var(--space-md);
        width: 48px;
        height: 48px;
    }
}

/* --------------------------------------------------------------------------
   MARQUEE / TICKER
   -------------------------------------------------------------------------- */
.marquee {
    overflow: hidden;
    padding: var(--space-3xl) 0;
    background: var(--color-dark);
    position: relative;
}

.marquee::before,
.marquee::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 100px;
    z-index: 2;
}

.marquee::before {
    left: 0;
    background: linear-gradient(to right, var(--color-dark), transparent);
}

.marquee::after {
    right: 0;
    background: linear-gradient(to left, var(--color-dark), transparent);
}

.marquee-track {
    display: flex;
    gap: var(--space-2xl);
    animation: marquee 30s linear infinite;
}

.marquee-item {
    flex-shrink: 0;
    font-family: var(--font-heading);
    font-size: clamp(2rem, 5vw, 4rem);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: -0.02em;
    color: transparent;
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.3);
    white-space: nowrap;
}

.marquee-item.filled {
    color: white;
    -webkit-text-stroke: none;
}

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

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

/* --------------------------------------------------------------------------
   CONTACT SECTION
   -------------------------------------------------------------------------- */
.contact {
    background: var(--color-dark);
    color: white;
    position: relative;
    overflow: hidden;
}

.contact::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 150vw;
    height: 150vw;
    background: radial-gradient(circle, rgba(131, 180, 157, 0.15) 0%, transparent 50%);
    pointer-events: none;
}

.contact-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 700px;
    margin: 0 auto;
}

.contact-label {
    display: inline-flex;
    align-items: center;
    gap: var(--space-sm);
    margin-bottom: var(--space-lg);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-cta);
}

.contact-title {
    margin-bottom: var(--space-lg);
}

.contact-text {
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: var(--space-2xl);
    font-size: 1.125rem;
}

.contact-email {
    display: inline-flex;
    align-items: center;
    gap: var(--space-md);
    font-size: clamp(1.5rem, 4vw, 2.5rem);
    font-weight: 700;
    font-family: var(--font-heading);
    color: white;
    transition: all var(--transition-base);
    position: relative;
}

.contact-email::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-cta));
    transform: scaleX(0);
    transform-origin: right;
    transition: transform var(--transition-base);
}

.contact-email:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

.contact-email:hover {
    color: var(--color-primary);
}

.contact-email svg {
    width: 32px;
    height: 32px;
    stroke: currentColor;
    stroke-width: 1.5;
}

.contact-socials {
    display: flex;
    justify-content: center;
    gap: var(--space-lg);
    margin-top: var(--space-3xl);
}

.contact-social {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transition: all var(--transition-base);
    cursor: pointer;
}

.contact-social:hover {
    background: white;
    border-color: white;
}

.contact-social svg {
    width: 20px;
    height: 20px;
    fill: white;
    transition: fill var(--transition-fast);
}

.contact-social:hover svg {
    fill: var(--color-dark);
}

/* --------------------------------------------------------------------------
   FOOTER
   -------------------------------------------------------------------------- */
.footer {
    background: var(--color-dark);
    color: rgba(255, 255, 255, 0.4);
    padding: var(--space-xl) 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-inner {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
    align-items: center;
    text-align: center;
}

@media (min-width: 768px) {
    .footer-inner {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
    }
}

.footer-copyright {
    font-size: 0.875rem;
}

.footer-links {
    display: flex;
    gap: var(--space-lg);
}

.footer-link {
    font-size: 0.875rem;
    transition: color var(--transition-fast);
}

.footer-link:hover {
    color: white;
}

/* --------------------------------------------------------------------------
   ANIMATIONS
   -------------------------------------------------------------------------- */
@keyframes slideUp {
    to {
        transform: translateY(0);
    }
}

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

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

/* Scroll-triggered animations */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s var(--ease-out-expo), transform 0.8s var(--ease-out-expo);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.8s var(--ease-out-expo), transform 0.8s var(--ease-out-expo);
}

.reveal-left.visible {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity 0.8s var(--ease-out-expo), transform 0.8s var(--ease-out-expo);
}

.reveal-right.visible {
    opacity: 1;
    transform: translateX(0);
}

.reveal-scale {
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.8s var(--ease-out-expo), transform 0.8s var(--ease-out-expo);
}

.reveal-scale.visible {
    opacity: 1;
    transform: scale(1);
}

/* Stagger delays */
.delay-1 {
    transition-delay: 0.1s;
}

.delay-2 {
    transition-delay: 0.2s;
}

.delay-3 {
    transition-delay: 0.3s;
}

.delay-4 {
    transition-delay: 0.4s;
}

.delay-5 {
    transition-delay: 0.5s;
}

/* Parallax */
[data-parallax] {
    will-change: transform;
}

/* --------------------------------------------------------------------------
   PROJECT PAGE STYLES
   -------------------------------------------------------------------------- */
.project-hero {
    min-height: 70vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: var(--space-4xl) 0;
    padding-top: calc(var(--header-height) + var(--space-3xl));
    position: relative;
    background: var(--color-dark);
    color: white;
    overflow: hidden;
}

.project-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, var(--color-dark) 0%, transparent 100%);
    z-index: 1;
}

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

.project-hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-hero-content {
    position: relative;
    z-index: 2;
}

.project-meta {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-xl);
    margin-top: var(--space-2xl);
}

.project-meta-item {
    min-width: 150px;
}

.project-meta-label {
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: var(--space-xs);
}

.project-meta-value {
    font-weight: 600;
}

.project-content {
    padding: var(--space-5xl) 0;
}

.project-section {
    margin-bottom: var(--space-4xl);
}

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

.project-section-title {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-primary);
    margin-bottom: var(--space-lg);
}

.project-text {
    font-size: 1.25rem;
    line-height: 1.8;
    color: var(--color-muted);
}

.project-text p {
    margin-bottom: var(--space-lg);
}

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

.project-images {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-lg);
    margin: var(--space-3xl) 0;
}

@media (min-width: 768px) {
    .project-images {
        grid-template-columns: repeat(2, 1fr);
    }

    .project-images.single {
        grid-template-columns: 1fr;
    }
}

.project-image {
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
}

/* For side-by-side images, enforce aspect ratio */
.project-images:not(.single) .project-image {
    aspect-ratio: 4/3;
}

.project-images:not(.single) .project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: var(--radius-lg);
}

.project-image img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: var(--radius-lg);
}

/* Project image layout variations */
.project-images-full {
    display: block;
    margin: var(--space-4xl) 0;
}

.project-images-full .project-image {
    border-radius: var(--radius-lg);
    overflow: hidden;
}

/* Offset/asymmetric layout */
.project-images-offset {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-lg);
    margin: var(--space-3xl) 0;
}

@media (min-width: 768px) {
    .project-images-offset {
        grid-template-columns: 1.5fr 1fr;
        gap: var(--space-xl);
        align-items: start;
    }
}

.project-images-offset .project-image {
    border-radius: var(--radius-lg);
    overflow: hidden;
    aspect-ratio: 4/3;
}

.project-images-offset .project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.project-images-offset .project-image:first-child {
    grid-column: 1;
}

.project-images-offset .project-image:last-child {
    grid-column: 2;
    margin-top: var(--space-3xl);
}

@media (max-width: 767px) {
    .project-images-offset .project-image:last-child {
        margin-top: 0;
    }
}

/* Featured single image */
.project-images-feature {
    margin: var(--space-4xl) 0;
}

.project-images-feature .project-image {
    border-radius: var(--radius-lg);
    overflow: hidden;
}

/* Inline imagery - smaller images that flow with text */
.project-images-inline {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--space-lg);
    margin: var(--space-xl) 0;
}

@media (min-width: 768px) {
    .project-images-inline {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--space-lg);
    }
}

.project-images-inline .project-image {
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.project-nav {
    padding: var(--space-3xl) 0;
    border-top: 1px solid var(--color-border);
}

.project-nav-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.project-nav-link {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    font-weight: 600;
    transition: color var(--transition-fast);
}

.project-nav-link:hover {
    color: var(--color-primary);
}

.project-nav-link svg {
    width: 24px;
    height: 24px;
    stroke: currentColor;
    stroke-width: 2;
    transition: transform var(--transition-fast);
}

.project-nav-link:hover svg {
    transform: translateX(-4px);
}

.project-nav-link.next:hover svg {
    transform: translateX(4px);
}

.project-nav-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-muted);
}

.project-nav-title {
    font-size: 1rem;
}

/* --------------------------------------------------------------------------
   RESPONSIVE STYLES
   -------------------------------------------------------------------------- */

/* Mobile (375px+) */
@media (max-width: 767px) {

    /* ===== SPACING ADJUSTMENTS ===== */
    /* Reduce massive section padding for mobile screens */
    .section {
        padding: var(--space-4xl) 0;
        /* Changed from 20rem to 8rem */
    }

    .section-sm {
        padding: var(--space-3xl) 0;
        /* Changed from 12rem to 6rem */
    }

    .section-lg {
        padding: var(--space-5xl) 0;
        /* Changed from 20rem to 12rem */
    }

    /* Container adjustments */
    .container {
        padding: 0 var(--space-md);
        /* Reduced from 1.5rem to 1rem */
    }

    /* ===== HEADER & NAVIGATION ===== */
    .header {
        padding: var(--space-md) 0;
    }

    .header.scrolled {
        padding: var(--space-sm) 0;
    }

    .logo {
        height: 28px;
        /* Slightly smaller for mobile */
    }

    .nav {
        gap: var(--space-sm);
    }

    /* Keep only the CTA visible with proper touch target */
    .nav-link {
        display: none;
    }

    .nav-cta {
        padding: var(--space-sm) var(--space-md);
        font-size: 0.8125rem;
        min-height: 44px;
        /* Touch-friendly minimum */
        display: flex;
        align-items: center;
    }

    /* ===== HERO SECTION ===== */
    .hero {
        min-height: 90vh;
        /* Slightly shorter for mobile */
        padding-top: calc(var(--header-height) + var(--space-xl));
        padding-left: var(--space-md);
        padding-right: var(--space-md);
    }

    .hero-content {
        padding: 0;
    }

    .hero-eyebrow {
        font-size: 0.6875rem;
        margin-bottom: var(--space-md);
    }

    .hero-name {
        margin-bottom: var(--space-lg);
    }

    .hero-role {
        font-size: 1rem;
        line-height: 1.6;
        margin-bottom: var(--space-xl);
    }

    .hero-cta {
        flex-direction: column;
        gap: var(--space-md);
        width: 100%;
    }

    .hero-cta .btn {
        width: 100%;
        justify-content: center;
        min-height: 48px;
        /* Touch-friendly */
        padding: var(--space-md) var(--space-lg);
    }

    .hero-scroll {
        bottom: var(--space-xl);
    }

    /* ===== BUTTONS - TOUCH TARGETS ===== */
    .btn {
        min-height: 48px;
        /* Ensure all buttons meet touch target */
        padding: var(--space-md) var(--space-xl);
        font-size: 0.9375rem;
    }

    .btn-secondary {
        min-height: 48px;
    }

    /* ===== ABOUT SECTION ===== */
    .about-grid {
        gap: var(--space-2xl);
    }

    .about-label {
        font-size: 0.6875rem;
        margin-bottom: var(--space-md);
    }

    .about-text {
        font-size: 1.125rem;
        /* Ensure readable on mobile */
    }

    .about-stats {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
        margin-top: var(--space-2xl);
        padding-top: var(--space-xl);
    }

    .about-stat {
        display: flex;
        justify-content: space-between;
        align-items: center;
        text-align: left;
        padding: var(--space-md) 0;
        border-bottom: 1px solid var(--color-border);
    }

    .about-stat:last-child {
        border-bottom: none;
    }

    .about-stat-number {
        order: 2;
    }

    .about-stat-label {
        order: 1;
        margin-top: 0;
    }

    .about-decoration {
        display: none;
        /* Hide decorative element on mobile */
    }

    /* ===== MARQUEE ===== */
    .marquee {
        padding: var(--space-xl) 0;
    }

    .marquee-item {
        font-size: 1.5rem;
        /* Smaller for mobile */
        padding: 0 var(--space-lg);
    }

    /* ===== PROJECTS SECTION ===== */
    .projects-header {
        margin-bottom: var(--space-2xl);
        gap: var(--space-sm);
    }

    .projects-label {
        font-size: 0.625rem;
        letter-spacing: 0.15em;
    }

    .projects-label::before,
    .projects-label::after {
        width: 24px;
    }

    .projects-subtitle {
        font-size: 1rem;
        margin-top: var(--space-md);
    }

    /* Projects grid - already responsive via min-width queries */
    .projects-grid {
        gap: var(--space-2xl);
    }

    /* Project cards - reduce excessive white space */
    .project-card {
        gap: var(--space-md);
        /* Reduced from xl */
        min-height: 44px;
    }

    .project-card-vertical {
        min-height: 44px;
    }

    .project-image-wrapper {
        margin-bottom: var(--space-sm);
        /* Reduced from md */
    }

    /* Tighten up project content spacing */
    .project-content {
        padding: 0;
    }

    .project-title {
        font-size: 1.25rem;
        margin-bottom: var(--space-xs);
    }

    .project-meta {
        font-size: 0.8125rem;
        gap: var(--space-xs);
    }

    .project-description {
        font-size: 0.9375rem;
        line-height: 1.6;
    }

    /* Show arrows by default on mobile since no hover */
    .project-arrow {
        transform: translate(0, 0);
        opacity: 1;
        width: 40px;
        height: 40px;
    }

    .project-overlay {
        opacity: 1;
    }

    /* ===== CONTACT SECTION ===== */
    .contact-content {
        text-align: center;
    }

    .contact-label {
        font-size: 0.6875rem;
        margin-bottom: var(--space-md);
    }

    .contact-title {
        margin-bottom: var(--space-lg);
    }

    .contact-text {
        font-size: 1.125rem;
        margin-bottom: var(--space-xl);
    }

    .contact-email {
        font-size: 1.125rem;
        padding: var(--space-md);
        min-height: 48px;
        /* Touch-friendly */
        display: inline-flex;
        align-items: center;
        gap: var(--space-sm);
    }

    .contact-email svg {
        width: 20px;
        height: 20px;
    }

    .contact-socials {
        gap: var(--space-md);
        margin-top: var(--space-xl);
    }

    .contact-social {
        width: 48px;
        /* Touch-friendly size */
        height: 48px;
        padding: var(--space-sm);
    }

    /* ===== FOOTER ===== */
    .footer-inner {
        flex-direction: column;
        gap: var(--space-md);
        text-align: center;
        padding: var(--space-xl) 0;
    }

    .footer-copyright {
        font-size: 0.875rem;
    }

    .footer-links {
        gap: var(--space-lg);
    }

    .footer-link {
        font-size: 0.875rem;
        min-height: 44px;
        /* Touch-friendly */
        display: inline-flex;
        align-items: center;
    }

    /* ===== PROJECT PAGES ===== */
    .project-hero {
        min-height: 60vh;
        /* Shorter on mobile */
        padding: var(--space-2xl) 0;
        /* Reduced padding */
        padding-top: calc(var(--header-height) + var(--space-xl));
        margin-bottom: var(--space-xl);
        /* Add spacing below hero */
    }

    .project-meta {
        flex-direction: column;
        gap: var(--space-sm);
        /* Tighter spacing */
        align-items: flex-start;
        margin-top: var(--space-lg);
        /* Reduced from 2xl */
    }

    .project-meta-item {
        width: 100%;
        min-width: 0;
        /* Remove min-width constraint */
    }

    .project-meta-label {
        margin-bottom: var(--space-xs);
        /* Reduced spacing */
        font-size: 0.625rem;
    }

    .project-section {
        margin-bottom: var(--space-2xl);
    }

    .project-section-title {
        font-size: 1.75rem;
        margin-bottom: var(--space-lg);
    }

    .project-text {
        font-size: 1rem;
    }

    .project-text p {
        margin-bottom: var(--space-lg);
    }

    .project-images {
        gap: var(--space-lg);
        margin: var(--space-2xl) 0;
    }

    .project-images-feature {
        margin: var(--space-2xl) 0;
    }

    .project-nav {
        padding: var(--space-2xl) 0;
    }

    .project-nav-inner {
        flex-direction: column;
        gap: var(--space-lg);
    }

    .project-nav-link {
        width: 100%;
        padding: var(--space-md);
        min-height: 44px;
        /* Touch-friendly */
    }

    .project-nav-link svg {
        width: 20px;
        height: 20px;
    }

    /* ===== PAGE HEADER (Projects page) ===== */
    .page-header {
        padding-top: calc(var(--header-height) + var(--space-2xl));
        padding-bottom: var(--space-xl);
    }

    /* ===== PREVENT HORIZONTAL SCROLL ===== */
    body {
        overflow-x: hidden;
    }

    /* Ensure images don't overflow */
    img {
        max-width: 100%;
        height: auto;
        /* Performance optimizations */
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }

    /* Fix any potential overflow from full-width elements */
    .project-full-width {
        margin-left: calc(-1 * var(--space-md));
        margin-right: calc(-1 * var(--space-md));
    }

    /* ===== TYPOGRAPHY - ENSURE READABILITY ===== */
    /* Base font size already 16px in root, ensure it stays */
    body {
        font-size: 1rem;
        /* 16px minimum for mobile readability */
        line-height: 1.6;
    }

    /* Adjust heading sizes for mobile if needed */
    h1 {
        font-size: clamp(2rem, 8vw, 3rem);
    }

    h2 {
        font-size: clamp(1.75rem, 6vw, 2.5rem);
    }

    h3 {
        font-size: clamp(1.25rem, 4vw, 1.75rem);
    }
}

/* Tablet (768px+) */
@media (min-width: 768px) {
    .container {
        padding: 0 var(--space-xl);
    }
}

/* Desktop (1024px+) */
@media (min-width: 1024px) {
    .container {
        padding: 0 var(--space-2xl);
    }
}

/* Large Desktop (1440px+) */
@media (min-width: 1440px) {
    :root {
        --max-width: 1400px;
    }
}

/* Ultra Wide (1920px+) */
@media (min-width: 1920px) {
    :root {
        font-size: 18px;
    }
}

/* ==========================================================================
   BEFORE/AFTER SLIDER COMPONENT
   ========================================================================== */

.before-after-container {
    width: 100%;
    margin: var(--space-2xl) 0;
}

.before-after-slider {
    position: relative;
    width: 100%;
    max-width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: var(--radius-xl);
    user-select: none;
    touch-action: pan-y;
    box-shadow: var(--shadow-lg);
}

.before-image,
.after-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.before-image img,
.after-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    pointer-events: none;
}

.after-image {
    clip-path: inset(0 50% 0 0);
}

.slider-handle {
    position: absolute;
    top: 0;
    left: 50%;
    width: 4px;
    height: 100%;
    background: white;
    transform: translateX(-50%);
    cursor: ew-resize;
    z-index: 10;
}

.slider-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    pointer-events: none;
    transition: all var(--transition-base);
}

.slider-button svg {
    width: 24px;
    height: 24px;
    stroke: var(--color-text);
}

.slider-handle:hover .slider-button,
.slider-handle:active .slider-button {
    transform: translate(-50%, -50%) scale(1.1);
    box-shadow: var(--shadow-xl);
}

.slider-labels {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
}

.slider-label {
    position: absolute;
    top: var(--space-lg);
    padding: var(--space-sm) var(--space-lg);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 100px;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text);
    box-shadow: var(--shadow-sm);
}

.slider-label-before {
    left: var(--space-lg);
}

.slider-label-after {
    right: var(--space-lg);
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .before-after-slider {
        aspect-ratio: 4 / 3;
    }

    .slider-button {
        width: 48px;
        height: 48px;
    }

    .slider-button svg {
        width: 20px;
        height: 20px;
    }

    .slider-label {
        font-size: 0.75rem;
        padding: var(--space-xs) var(--space-md);
    }
}

/* Tablet */
@media (min-width: 769px) and (max-width: 1024px) {
    .before-after-slider {
        aspect-ratio: 3 / 2;
    }
}