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

:root {
    --bg-color: #fff9f0;
    --text-color: #000000;
    --font-main: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    --space-md: 2rem;
    --space-sm: 1rem;
    --header-height: 80px;
    /* Reduced from 120px */
}

html,
body {
    height: 100%;
    width: 100%;
    margin: 0;
    padding: 0;
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    overflow: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Typography */
a {
    color: inherit;
    text-decoration: none;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.1em;
    cursor: pointer;
    font-family: inherit;
}

a:hover {
    opacity: 0.6;
}

/* Navigation - Top Fixed Header */
.nav-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    z-index: 1000;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    padding: 0 var(--space-md);
    background-color: var(--bg-color);
    color: #000;
}

.nav-left {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    line-height: 1.3;
    flex: 1;
}

.nav-left .name {
    font-weight: bold;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: #000;
}

.nav-left .title {
    font-weight: normal;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #555;
}

.nav-center {
    position: absolute;
    left: 50%;
    top: 72%;
    /* Logo lowered to 72% */
    transform: translate(-50%, -50%);
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-center img {
    height: 80px;
    /* Auto adjust with header but keep slightly smaller */
    width: auto;
    object-fit: contain;
}

.nav-right {
    display: flex;
    flex-direction: row;
    gap: 2.5rem;
    justify-content: flex-end;
    flex: 1;
}

.nav-right a {
    font-size: 0.85rem;
    color: #333;
    font-weight: 500;
    letter-spacing: 0.15em;
}

.nav-right a.active {
    color: #000;
    font-weight: 600;
}

/* Page Wrapper for Vertical Scroll */
.page-wrapper {
    height: 100vh;
    width: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    padding-top: var(--header-height);
}

/* GENERAL PAGE CONTAINERS (Clients, Contact, About) */
.content-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 4rem 2rem;
    min-height: 80vh;
}

/* CLIENTS PAGE STYLES */
.clients-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4rem;
}

.clients-column h2 {
    font-size: 0.9rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    margin-bottom: 2rem;
    color: #888;
    font-weight: normal;
}

.clients-column ul {
    list-style: none;
    padding: 0;
}

.clients-column li {
    /* Matched Title Styling */
    font-size: 0.85rem;
    font-weight: normal;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    line-height: 1.6;
    margin-bottom: 0.5rem;
    color: #000;
}

/* CONTACT PAGE STYLES */
.contact-layout {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    max-width: 600px;
}

.contact-item {
    font-size: 0.85rem;
    font-weight: normal;
    letter-spacing: 0.1em;
    /* Matched Title Styling */
    line-height: 1.6;
    font-family: inherit;
    text-transform: uppercase;
    color: #000;
}

.contact-label {
    display: block;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: #888;
    margin-bottom: 0.5rem;
}

/* Horizontal Sections (Homepage) */
.horizontal-scroll-section {
    display: flex;
    flex-wrap: nowrap;
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    padding: 2rem var(--space-md) 0;
    align-items: flex-start;
    min-height: 60vh;
}

/* Project Item */
.project-item {
    flex: 0 0 auto;
    height: 85%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 1.5vw;
}

.project-item img {
    height: 100%;
    width: auto;
    max-width: none;
    /* Ensure tall portrait images don't overflow the container height */
    max-height: 100%;
    object-fit: contain;
    display: block;
}

.project-info {
    display: none;
}

/* Section Headings */
.section-heading {
    padding: 1rem 2rem 0.5rem 2rem;
    font-size: 0.9rem;
    font-weight: normal;
    letter-spacing: 0.2em;
    color: #888;
    text-transform: uppercase;
}

/* ABOUT PAGE Specifics */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    align-items: start;
}

.about-image img {
    width: 100%;
    height: auto;
    display: block;
}

.about-text h1 {
    font-size: 1.05rem;
    /* ~10% larger than 0.95rem */
    margin-bottom: 2rem;
    /* Increased from 0.5rem */
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.15em;
}

.about-title {
    font-size: 1.05rem;
    /* ~10% larger than 0.95rem */
    font-weight: bold;
    text-transform: uppercase;
    margin-bottom: 1rem;
    white-space: nowrap;
}

.about-text .role-title {
    display: block;
    margin-bottom: 2rem;
    font-size: 1rem;
    color: #555;
}

.bio-paragraph {
    margin-bottom: 1.5rem;
    /* Matched Title Styling */
    font-size: 0.75rem;
    font-weight: normal;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    line-height: 1.8;
    /* Increased line height for readability at small size */
    max-width: 550px;
    color: #000;
}

.client-link {
    display: inline-block;
    margin-top: 1rem;
    font-size: 0.9rem;
    border-bottom: 1px solid #000;
    padding-bottom: 2px;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    :root {
        --header-height: 130px;
    }

    .nav-container {
        flex-direction: column;
        justify-content: center;
        padding: 1rem;
        height: auto;
        position: relative;
    }

    .page-wrapper {
        padding-top: 0;
    }

    .nav-left {
        align-items: center;
        text-align: center;
        margin-bottom: 1rem;
    }

    .nav-center {
        position: relative;
        left: auto;
        transform: none;
        top: auto;
        margin-bottom: 1rem;
    }

    .nav-center img {
        height: 60px;
    }

    .nav-right {
        justify-content: center;
        width: 100%;
        gap: 1.5rem;
    }

    .clients-grid,
    .about-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .horizontal-scroll-section {
        display: block;
        height: auto !important;
        padding-bottom: 2rem;
    }

    .project-item {
        display: block;
        width: 100%;
        height: auto;
        padding: 0 0 2rem 0;
    }

    .project-item img {
        width: 100%;
        height: auto;
        max-height: none;
    }
}

/* Image Hover Interaction - Bottom Bar Redesign */
.image-wrapper {
    position: relative;
    height: 100%;
    width: auto;
    display: inline-block;
    overflow: hidden;
    /* Ensure slide-up doesn't show outside */
}

/* Ensure image fills the wrapper */
.image-wrapper img {
    display: block;
    height: 100%;
    width: auto;
}

.overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: auto;
    /* Allow height to fit content, min-height defined by padding/text */
    min-height: 50px;
    background-color: rgba(0, 0, 0, 0.7);
    /* Background: rgba(0,0,0,0.7) */
    transform: translateY(100%);
    /* Start hidden below */
    transition: transform 0.3s ease-out;
    /* Smooth slide up */
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    /* Allow clicks to pass through to image if needed */
    padding: 0.5rem 1rem;
    z-index: 10;
}

.project-item:hover .overlay {
    transform: translateY(0);
    /* Slide up to visible */
}

/* Mobile Interaction: Touch to toggle */
/* We will use a class '.active-overlay' toggled via JS for better mobile experience than :active */
.project-item.active-overlay .overlay {
    transform: translateY(0);
}

.overlay-text {
    color: #fff;
    font-family: var(--font-main);
    font-size: 0.85rem;
    /* Clean sans-serif, slightly smaller for bar */
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    text-align: center;
    line-height: 1.2;
}

/* Mobile Responsiveness for Overlay */
@media (max-width: 768px) {
    .overlay {
        position: relative;
        /* On mobile stack below or stay? User said tap to reveal. */
        /* Revert to absolute for tap interaction */
        position: absolute;
        transform: translateY(100%);
        min-height: 50px;
    }

    /* Ensure wrapper handles tap correctly */
    .image-wrapper {
        cursor: pointer;
    }
}